Note: Some of the methods in this article involve the use of plug-ins. It is recommended that you first install Sketch Toolbox, a great plugin management tool, and make sure that your Sketch version is up to date (currently 3.2.2).
Automatic isometric copying of elements
The way we are familiar is by holding down ALT and dragging elements to replicate. But for a large number of repetitive replication tasks, this manual approach is still too time-consuming.
One of the more typical repetitive requirements that we often encounter is to copy an element multiple times and arrange it equidistant. For this typical task, sketch provides a very convenient way to implement it. First, we still need to copy it by "ALT + drag", and refer to the dynamically displayed spacing values to place the new elements in place, and then use the shortcut "Cmd+d" to replicate, each copy of the new elements and the distance between the previous element is the first time we manually drag and drop the copy of the value set. You just hold down the CMD key and press the D key until you copy the quantity you need.
Note: If you find that "cmd+d" does not achieve automatic isometric replication, then go to sketch preferences, find "Layers" under "offset pasted & duplicated objects" and cancel the check.
Second, layer sorting
Imagine that you are designing an application like Dropbox, which requires a list of files by default sorted by upload date, but the user can switch to alphabetical order by file name. You're serious. Each sample file has a different name in the design, and everything is fine; but to illustrate the alphabetical list of files, you find yourself having to manually drag and drop the layers to reorder them.
Farewell to Manual troubles, we use the sketch mate Plug-ins to achieve acceleration.
Open the Sketch Toolbox tool
Search for "Sketch Mate"
Sketch Mate integrates a lot of utility functions, and the sort we need to use now is just one of them. In the following demo, each file list item corresponds to a group named "File."
Select all groups that need to be sorted, click Plugin > Sketch Mate > Sort > Sort Layers in the menu bar, and select Text (A > Z) in the pop-up dialog box. Because each group in our example contains more than one text object, we then need to choose which text to sort by. When you click OK, your list will be sorted in an instant.
You can also try several other sorts of ways.
Third, the layer and artboard batch rename
Good and orderly layer and artboard structure is a good design of the logo one of the signs, their own happy, collaborative up everyone also happy. It must be acknowledged, however, that in many cases, it is tedious and time-consuming to rename layers and artboard with more reasonable standards. Fortunately, there is a plug-in named Renameit can save us from fire and fire.
Open the Sketch Toolbox tool
Search for "Renameit"
In sketch, select the layer or artboard you want to rename (at least two selected), press "Ctrl+cmd+r", call out the Renameit dialog box, and enter "prefix + parameter". Where the prefix is the word we need to have a specific meaning, such as "icon." The parameters are divided into three categories:
%N: Number. For example, in the dialog box, enter "icon%N", click OK, the selected layer or artboard will be renamed "Icon 1", "Icon 2", "Icon 3" and so on.
%w: Width. For example, in the dialog box, enter "icon%w", click OK, the selected layer or artboard will be renamed "icon 24", "icon 36", "icon 48" and so on, where the width value is automatically obtained by the actual width of the object.
%H: Height. Same with%w.
Four, dynamic button
Copying an existing button and setting a different button caption is a very repetitive task that requires precise operation because we need to do more than just copy and adjust the width of the button depending on the length of the headings. The famous dynamic button plugin is designed to solve this problem. So far, this is my personal favorite plug-ins.
Open the Sketch Toolbox tool
Search for "Dynamic Button"
First, we need to create the initial button through the DB plugin. Create a new text object and enter the button caption we want. Select the text object and press "Cmd+j", and you will find that the text is packaged with an automatically generated background shape in a group named "Flex Button", and that the text layer is automatically renamed to "0:0:0:0". These 4 digits represent the distance of the text object from the top, right, bottom, and left edges of the rectangular background.
For example, depending on the actual requirements, we will set the top and bottom two values to 12, the left and right two values to 20, then you can rename the text layer to "12:20:12:20", and then select the text object, press "Cmd+j", The size of the button background will automatically be adjusted according to the specifications we set.
Next, whether it is to modify the title copy of the button, or copy a new button and change the title, as long as you select the text object again and click "Cmd+j", the button background size will automatically be adjusted according to the size of the new copy.
Five, symbols nesting
At present, sketch has not yet "officially" supported symbols nesting, but we can do it with some tricks, but we suggest you be careful when you use it.
To embed symbol A in symbol B:
Select Symbol A and set it to ' No Symbol ' in the right inspector to revert to a normal group or object
In the left layer list, move a to symbol B
Keep a selected state and reset it to the original Symbol A in the right inspector
For me personally, this approach is useful when editing an interface with a pop-up layer. I can create the initial interface as a whole as a parent symbol that contains the child symbol for various controls, then copies the entire artboard and designs the float or frame style. If some elements of the initial interface need to change, then the artboard containing the floating layer will be automatically updated without the need to manually remove the floating layer and do repetitive work.
Six, make artboard according to the content automatically adjust the size
The artboard system in sketch can help us to stand in the overall view of the design plan, which is different from other competing products, an important feature. Think of the past with PS condition, feel like a nightmare.
Imagine you need to always add or remove content from artboard-if artboard can resize it automatically, how good would that be? The sketch mate we introduced earlier can help, making sure you have it installed.
For example, the actual content in the current artboard has exceeded the artboard size, and you cannot see more entries in the list. By "Ctrl+shift+a", artboard can be accurately adjusted to the actual height of the existing content to resize itself, it is so simple.