Update Composer packages
This commit is contained in:
parent
0320235f6c
commit
a8b68fb61b
378 changed files with 28466 additions and 28852 deletions
|
@ -3,7 +3,6 @@
|
|||
namespace Kirby\Panel;
|
||||
|
||||
use Kirby\Cms\App;
|
||||
use Kirby\Cms\Helpers;
|
||||
use Kirby\Exception\Exception;
|
||||
use Kirby\Exception\InvalidArgumentException;
|
||||
use Kirby\Filesystem\Asset;
|
||||
|
@ -31,8 +30,6 @@ class Document
|
|||
/**
|
||||
* Generates an array with all assets
|
||||
* that need to be loaded for the panel (js, css, icons)
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function assets(): array
|
||||
{
|
||||
|
@ -137,9 +134,8 @@ class Document
|
|||
* @since 3.7.0
|
||||
*
|
||||
* @param string $option asset option name
|
||||
* @return string|null
|
||||
*/
|
||||
public static function customAsset(string $option): ?string
|
||||
public static function customAsset(string $option): string|null
|
||||
{
|
||||
if ($path = App::instance()->option($option)) {
|
||||
$asset = new Asset($path);
|
||||
|
@ -153,34 +149,12 @@ class Document
|
|||
}
|
||||
|
||||
/**
|
||||
* @deprecated 3.7.0 Use `Document::customAsset('panel.css)` instead
|
||||
* @todo remove in 3.8.0
|
||||
* @codeCoverageIgnore
|
||||
*/
|
||||
public static function customCss(): ?string
|
||||
{
|
||||
Helpers::deprecated('Panel\Document::customCss() has been deprecated and will be removed in Kirby 3.8.0. Use Panel\Document::customAsset(\'panel.css\') instead.');
|
||||
return static::customAsset('panel.css');
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated 3.7.0 Use `Document::customAsset('panel.js)` instead
|
||||
* @todo remove in 3.8.0
|
||||
* @codeCoverageIgnore
|
||||
*/
|
||||
public static function customJs(): ?string
|
||||
{
|
||||
Helpers::deprecated('Panel\Document::customJs() has been deprecated and will be removed in Kirby 3.8.0. Use Panel\Document::customAsset(\'panel.js\') instead.');
|
||||
return static::customAsset('panel.js');
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns array of favion icons
|
||||
* Returns array of favicon icons
|
||||
* based on config option
|
||||
* @since 3.7.0
|
||||
*
|
||||
* @param string $url URL prefix for default icons
|
||||
* @return array
|
||||
* @throws \Kirby\Exception\InvalidArgumentException
|
||||
*/
|
||||
public static function favicon(string $url = ''): array
|
||||
{
|
||||
|
@ -190,13 +164,13 @@ class Document
|
|||
'type' => 'image/png',
|
||||
'url' => $url . '/apple-touch-icon.png',
|
||||
],
|
||||
'shortcut icon' => [
|
||||
'type' => 'image/svg+xml',
|
||||
'url' => $url . '/favicon.svg',
|
||||
],
|
||||
'alternate icon' => [
|
||||
'type' => 'image/png',
|
||||
'url' => $url . '/favicon.png',
|
||||
],
|
||||
'shortcut icon' => [
|
||||
'type' => 'image/svg+xml',
|
||||
'url' => $url . '/favicon.svg',
|
||||
]
|
||||
]);
|
||||
|
||||
|
@ -221,8 +195,6 @@ class Document
|
|||
* Load the SVG icon sprite
|
||||
* This will be injected in the
|
||||
* initial HTML document for the Panel
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public static function icons(): string
|
||||
{
|
||||
|
@ -233,7 +205,6 @@ class Document
|
|||
* Links all dist files in the media folder
|
||||
* and returns the link to the requested asset
|
||||
*
|
||||
* @return bool
|
||||
* @throws \Kirby\Exception\Exception If Panel assets could not be moved to the public directory
|
||||
*/
|
||||
public static function link(): bool
|
||||
|
@ -265,11 +236,8 @@ class Document
|
|||
|
||||
/**
|
||||
* Renders the panel document
|
||||
*
|
||||
* @param array $fiber
|
||||
* @return \Kirby\Http\Response
|
||||
*/
|
||||
public static function response(array $fiber)
|
||||
public static function response(array $fiber): Response
|
||||
{
|
||||
$kirby = App::instance();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue