worker: preview and print function;
layout: fix a js duplicate issue;