Hey everyone, here is the first beta of Blocs 4.4. This release contains a nice range of new features I think most of you are going to love.
Dark Theming
Blocs 4.4 introduces a range of improvements to aid the workflow of creating a website that supports dark and light theme modes.
The class dark-theme is added to the body tag when a Blocs site is run on a device that is running a dark OS theme.
Within Blocs you can emulate this using the canvas dark site mode option to switch the dark-theme class on and off within Blocs, this is also applied to in-app preview, but not preview in browser (that is depended on your Macs own theme option).
In the Class Manager if you right click a class you can also now opt to create a dark theme version of a class. Any changes made to this will only effect the site when run in dark mode. Notice it’s just a duplicated class with the leading dark-theme class before it.
Thats basically how you target dark theme .dark-theme .yourclass
The video below is a quick example of setting a Bloc background dark for dark mode.
Missing Font Manager
The Missing Font Manager will be shown if a missing font is detected when opening projects, adding custom Blocs and page templates. At this early stage of testing, it may be triggered without reason so keep an eye out for that.
Localisation
Kon’nichiwa! Our Japanese speaking users will be happy to hear Blocs now speaks Japanese. You may notice a bad translation, some text cropping or another little interface oddity. Please let me know if you spot something and it’ll be fixed up in no time!
New Wordpress short codes
Some new short codes for Wordpress.
- %WP_singleCatTitle% = <?php echo single_cat_title();?>
- %WP_singleCatIdVar% = get_cat_ID(single_term_title("", false))
- %WP_postCatIdArray% = wp_get_post_categories( get_the_ID(), array( ‘fields’ => ‘ids’ ) )
- %WP_getPostArchiveLink(PostArchiveNameGoesHere)% = <?php echo get_post_type_archive_link('PostArchiveNameGoesHere'); ?>
- %WP_categoryURL(categoryGoesNameHere)%) = <?php echo get_category_link(get_cat_ID('categoryGoesNameHere')); ?>
Have a great weekend and happy testing!
Download Blocs 4.4 Beta Build 1
Don’t forget to hard reload your browser, if the beta doesn’t show!
Additional
Im still working on a few other outstanding issues such as scroll speed and missing background images so please sit tight those will be addressed soon.