Skip to content

4.0.0-alpha.4

Pre-release
Pre-release
Compare
Choose a tag to compare
@distantnative distantnative released this 03 Jul 08:55
1206ff5

🎉 Features

  • Custom methods for structure and structure object
  • New templatesIgnore for pages section - https://kirby.nolt.io/130 #5322
  • Link field
    • New anchor type for the link field
      screenshot of the anchor type
    • New custom type for the link field
      screenshot of the custom type
    • Allows selecting which types (url, email, tel...) to include #5278
  • New anchor icon

✨ Enhancements

  • Add field preview for color field #5282
  • Uploader: allow to add more files via drop #5304
  • Users field: set default: true to always use the currently logged in user as default
  • New focus option for file blueprints to enable/disable setting focus point in the Panel (defaults to true for all viewable images, false for all other files) #5316
  • New App::models() method that returns a generator for each model (site, files, pages and users) of the site [#5337]#5337

🐛 Bug fixes

  • PageCreateDialog: make title label translatable #5286
  • Disable changing layout if only one layout available #5288
  • Writer: preserve whitespace #5295
  • Fixed block keydown propagation #5272
  • Users field does not anymore use a default if none set #5284
  • An outside click will now collapse the link field #5204
  • Removes conflicting block keyboard shortcuts with Cmd key (instead use variants with Ctrl key) #5268
  • Fixed block collapsing inside layouts #5289
  • Fixed styling of color field options
  • Fixed link field selecting files type

♻️ Refactored

  • Made k-bubble more flexible #5305
  • Kirby\Cms\Structure extends Kirby\Cms\Items and Kirby\Cms\StructureObject extends Kirby\Cms\Item
  • Use Page::isAccessible instead of Page::isReadable #5220
  • Adds query endpoint for Kql plugin to core
  • New Content namespace
    • Moved the Content, ContentTranslation and Field classes (compatibility aliases are provided for now) #5283
    • New internal ContentStorage class that currently holds more of the storage related business logic
    • New internal ContentStorageHandler interface and internal PlainTextContentStorageHandler class to bundle all low-level content logic in one place #5283
    • Improve code quality and tests in the Content namespace #5283

☠️ Deprecated

  • query should not be used anymore for custom API endpoints, it will be used for the Kql plugin/core implementation
  • Internal $model->contentFile(), $model->contentFiles(), $model->contentFileDirectory(), $model->contentFileExtension() and $model->contentFileName() methods have been deprecated and will be removed in Kirby 5.

🚨 Breaking changes

  • Registering a default block model now needs to be done with the key default, not Kirby\Cms\Block. #5299
  • new Structure()/new StructureObject() don't work anymore as before. Use Structure::factory()/StructureObject::factory() instead
  • Structure object IDs aren't simply their collection index numbers anymore but receive a Str::uuid() as blocks do
  • Items::factory() and all inheriting classes throw an exception now if malformed data is passed
  • Users field doesn't automatically uses the current user as default, add default: true to keep this functionality
  • Remove keyboard shortcut to move block focus up/down
  • Extending the internal $model->contentFile(), $model->contentFiles(), $model->contentFileDirectory(), $model->contentFileExtension(), $model->contentFileName(), $model->readContent() and $model->writeContent() methods in a page model will no longer have an effect as these methods are no longer called by the core. Please extend the new Kirby\\Content\\PlainTextContentStorage class instead and return an instance of your custom class from $model->storage(). However please note that the interface of PlainTextContentStorage is internal and may change in the future.
  • The $translations->start() and $translations->stop() methods were no longer in use and have been removed. Content files are automatically converted by the Language class.
  • $languages->codes() now returns ['default'] for single language installations #5339