Wix Blocks allows you to design stunning apps with simple drag-and-drop abilities, with little code, in a similar way to how you build Wix websites. This article explains how to make your app widgets behave responsively and adapt to any screen size, blend beautifully with Wix sites, and offer as many design styles and layouts as you want.
The Blocks Elements Figma kit gives you full access to Blocks widget, dashboard & panel elements, text styles and icons. If you want to start in Figma before designing in Blocks, make sure to use the kit to align with our visual standards.
Blocks allows you to build responsive apps and install them on all Wix editors. Designers can build fully fluid and functional widgets that support viewport/widget size change and customized content. This is why, before you begin to work on Blocks, it’s important to know the basics of responsive and fluid design.
Building with layout elements such as flexbox, grid, stack and repeater will help you create responsive behaviors.
Tip: plan ahead! Defining your responsive behaviors and desired customizations before you start to build. This will help you decide on the structure and layout tools that you should use. For example, it will help you determine in advance how many columns you need in your grid.
When you build an application in Blocks, you should take into consideration that it can be customized in the Wix editors and should support this customizable content. For example, a user who installs your app in the editor can delete some of the elements. Therefore, it’s important to adjust the design of your app to different kinds of edge-cases scenarios, such as how it will look when one of the sections is deleted. For example, look at this widget:
Here you can see the same widget after the user chose to delete the image:
To make sure that your content stays customizable:
Design presets allow you to create a variety of designs for one app. Design across breakpoints and reorganize the same elements to create multiple layouts for your widget (e.g. desktop and mobile). Note that all presets contain the same elements - reordered, but not re-parented. Everything is connected with the same logic. For example, grids in all presets must have the same number of cells.
Learn more about creating and managing design presets.
You can make some changes in a preset that only impact the current preset. Other changes impact all of them. Read more about changes that impact your current preset, versus changes that affect all of them.
Keep your widget as fluid as possible in all presets, even if using different presets for different breakpoints. Fluidity will allow the user who installs your application on a site to get a better behavior when they resize their app on a specific breakpoint. This is because different websites might have different breakpoints and you cannot predict the breakpoint of every website.
Use the Blocks option to insert one widget into another widget when you build a complex composition. This gives you the ability to suggest inner-widget presets. This allows more customization combinations for your user. It also simplifies the structure and the work on stage. Learn more about Nested Widgets in Blocks.
Since your widget does not stand alone but will be installed in a site, it is important to make sure when you build it, that it connects to the site theme.
Connect your colors to a theme:
Make sure to connect your elements to the site's color palette in order to:
Connecting Text themes:
Make sure your text elements are connected to the text theme in order to:
Note: You can disconnect the font size from the theme. This maintains the look of the typography when the user changes their theme from the Theme Panel.
Tip: Test your theme in Preview When you finish connecting all the elements to site themes, go to Preview in Blocks and click Test Theme. This will help you make sure that you didn't miss any element in your widget and that everything is connected perfectly.
Make sure that:
After you finish designing your widget, we recommend that you install your app to make sure it works properly.