Releases: getkirby/kql
Releases · getkirby/kql
2.2.0
2.1.0
🎉 Features
- KQL is now compatible with Kirby 4 thanks to @johannschopplich
✨ Enhancements
- All doc examples are now pure fetch without dependencies
- Added 11ty kit to the readme
2.0.0
🚀 Features
- Optional chaining (with Kirby 3.8.3) #40
- New playground: https://kql.getkirby.com
✨ Enhancements
- KQL is now based on the new
Kirby\Query
classes, profiting from all their enhancements Help
class now also supports objects without interceptor that have been explicitly allowed via config- Added unit tests and CI
♻️ Refactoring
Kirby\Kql\Interceptors\Interceptor
got merged intoKirby\Kql\Interceptor
. A class alias for the old name has been added.- General clean-up of code and improvements to consistent code style
🚨 Breaking changes
- Requires Kirby 3.8.2
1.3.0-rc.1
🚀 Features
- Optional chaining (with Kirby 3.8.3) #40
✨ Enhancements
- KQL is now based on the new
Kirby\Query
classes, profiting from all their enhancements Help
class now also supports objects without interceptor that have been explicitly allowed via config- Added unit tests and CI
♻️ Refactoring
Kirby\Kql\Interceptors\Interceptor
got merged intoKirby\Kql\Interceptor
. A class alias for the old name has been added.- General clean-up of code and improvements to consistent code style
1.2.0
Features
- Support for the new UUIDs in 3.8
- Support for plugin update checks in 3.8
Enhancements
- Updated CS Fixer rules
1.1.0
Features
Support for field method aliases #33
{
"query": "site.description.kt"
}
New option to switch off authentication for KQL
<?php
return [
'kql' => [
'auth' => false
]
];
Allow and block lists for custom methods and classes
<?php
return [
'kql' => [
'classes' => [
'blocked' => [
'Kirby\Cms\User'
]
],
'methods' => [
'allowed' => [
'AlbumPage::cover'
],
'blocked' => [
'Kirby\Cms\App::version'
]
]
]
];
You can also use doc block comments in custom model methods, custom page methods, etc. to allow a method in KQL
class AlbumPage extends Page
{
/**
* @kql-allowed
*/
public function cover()
{
return $this->images()->findBy('name', 'cover') ?? $this->image();
}
}
Custom interceptor support
<?php
return [
'kql' => [
'interceptors' => [
'Kirby\Cms\System' => 'SystemInterceptor'
]
]
];
New collection shortcut
{
"query": "collection('notes')"
}
Enhancements
- Improved README #36 (thanks @johannschopplich)
- Switches from spaces to tabs
Fixes
- Fixed pagination issue #28
- Throw proper permission exception in interceptors
- Fixed issue in license
- Fixed test setup in sandbox
1.1.0-rc.1
Features
Support for field method aliases #33
{
"query": "site.description.kt"
}
New option to switch off authentication for KQL
<?php
return [
'kql' => [
'auth' => false
]
];
Allow and block lists for custom methods and classes
<?php
return [
'kql' => [
'classes' => [
'blocked' => [
'Kirby\Cms\User'
]
],
'methods' => [
'allowed' => [
'AlbumPage::cover'
],
'blocked' => [
'Kirby\Cms\App::version'
]
]
]
];
You can also use doc block comments in custom model methods, custom page methods, etc. to allow a method in KQL
class AlbumPage extends Page
{
/**
* @kql-allowed
*/
public function cover()
{
return $this->images()->findBy('name', 'cover') ?? $this->image();
}
}
Custom interceptor support
<?php
return [
'kql' => [
'interceptors' => [
'Kirby\Cms\System' => 'SystemInterceptor'
]
]
];
New collection shortcut
{
"query": "collection('notes')"
}
Fixes
- Fixed pagination issue #28
- Throw proper permission exception in interceptors
- Fixed issue in license
- Fixed test setup in sandbox
1.0.0
It's time to make it official. With the latest changes, KQL is ready to be used with the latest Kirby version and has now full support for the new Blocks and Layouts.
Have fun :)