Releases: medienbaecker/kirby-modules
Kirby Modules 2.8.4
Kirby Modules 2.8.3
The change in this release allows modules to be moved to other modules containers.
Kirby Modules 2.8.2
Fixes #46.
Kirby Modules 2.8.1
The status texts are now hidden because they had the word "page" in them.
Kirby Modules 2.8.0
- The
autopublish
option is now using the Kirby 4.0.0 feature. - I also automatically set the
redirect
option tofalse
now and added an option to set it totrue
again. - The modules container page's title is now automatically translated.
Kirby Modules 2.7.0
🚀 Automatic Slugs
The slug field can now be hidden in the page creation dialog for streamlined entry, thanks to a new feature of Kirby 4.1.0.
For that I introduced a new page method, uniqueModuleSlug(), that ensures slugs are unique by appending a number to duplicates. This feature activates when the medienbaecker.modules.autoslug
option is set to true
.
Technical Insights:
I had to use a page method instead of a model function because the page isn't recognised as a module at that stage. In the method, $this
refers to a temporary page in new/tmp
. To effectively check for siblings, I have to go up two levels. I don't know if there's a better approach.
🔄 Template Switching Ease
The plugin now automatically populates the changeTemplate option. This allows easy switching between different module templates.
🔧 Other fixes
- I've fixed the section headline to be non-clickable following a class name change in a recent Kirby update.
- The
moduleId()
function has been updated to use proper BEM syntax, such asmodule--text
instead ofmodule__text
.
Kirby Modules 2.6.0
Along with the changes tested in 2.5.1 and 2.5.2 (for a very long time) I made sure Kirby Modules is compatible with Kirby 4.
Kirby Modules 2.5.2
It's now possible to pass variables to the renderModules()
method.
Kirby Modules 2.5.1
Kirby Modules 2.5.0
After a great discussion with @nilshoerrmann I decided to allow an additional folder structure for modules blueprints and templates:
Blueprint in site/blueprints/modules/example.yml
Template in site/snippets/modules/example.php
Before you had to use this folder structure:
Blueprint in site/modules/example/example.yml
Template in site/modules/example/example.php
And there's also the legacy way of doing it:
Blueprint in site/blueprints/pages/module.example.yml
Template in site/snippets/modules/module.example.php
The latter now throws a deprecation message.