Upgrade to 3.1.0

This commit is contained in:
Bastian Allgeier
2019-03-19 11:07:14 +01:00
parent 418db4b09b
commit 6e074142f1
98 changed files with 1266 additions and 299 deletions

View File

@@ -12,10 +12,10 @@ use Kirby\Toolkit\Str;
use Throwable;
/**
* The Page class is the heart and soul of
* Kirby. It is used to construct pages and
* all their dependencies like children,
* files, content, etc.
* The `$page` object is the heart and
* soul of Kirby. It is used to construct
* pages and all their dependencies like
* children, files, content, etc.
*
* @package Kirby Cms
* @author Bastian Allgeier <bastian@getkirby.com>
@@ -207,6 +207,7 @@ class Page extends ModelWithContent
/**
* Returns the url to the api endpoint
*
* @internal
* @param bool $relative
* @return string
*/
@@ -295,6 +296,7 @@ class Page extends ModelWithContent
/**
* Prepares the content for the write method
*
* @internal
* @return array
*/
public function contentFileData(array $data, string $languageCode = null): array
@@ -309,6 +311,7 @@ class Page extends ModelWithContent
* Returns the content text file
* which is found by the inventory method
*
* @internal
* @param string $languageCode
* @return string
*/
@@ -320,6 +323,7 @@ class Page extends ModelWithContent
/**
* Call the page controller
*
* @internal
* @param array $data
* @param string $contentType
* @return array
@@ -397,6 +401,7 @@ class Page extends ModelWithContent
* used in the panel, when the page
* gets dragged onto a textarea
*
* @internal
* @return string
*/
public function dragText($type = 'kirbytext'): string
@@ -423,6 +428,7 @@ class Page extends ModelWithContent
* Constructs a Page object and also
* takes page models into account.
*
* @internal
* @return self
*/
public static function factory($props): self
@@ -483,6 +489,7 @@ class Page extends ModelWithContent
* Returns the inventory of files
* children and content files
*
* @internal
* @return array
*/
public function inventory(): array
@@ -703,8 +710,7 @@ class Page extends ModelWithContent
}
/**
* Checks if the page is invisible
*
* @deprecated 3.0.0 Use `Page::isUnlisted()` intead
* @return bool
*/
public function isInvisible(): bool
@@ -768,6 +774,7 @@ class Page extends ModelWithContent
* Checks if the page access is verified.
* This is only used for drafts so far.
*
* @internal
* @param string $token
* @return boolean
*/
@@ -785,8 +792,7 @@ class Page extends ModelWithContent
}
/**
* Checks if the page is visible
*
* @deprecated 3.0.0 Use `Page::isListed()` intead
* @return bool
*/
public function isVisible(): bool
@@ -797,6 +803,7 @@ class Page extends ModelWithContent
/**
* Returns the root to the media folder for the page
*
* @internal
* @return string
*/
public function mediaRoot(): string
@@ -805,8 +812,9 @@ class Page extends ModelWithContent
}
/**
* The page's base url for any files
* The page's base URL for any files
*
* @internal
* @return string
*/
public function mediaUrl(): string
@@ -815,8 +823,9 @@ class Page extends ModelWithContent
}
/**
* Creates a Page model if it has been registered
* Creates a page model if it has been registered
*
* @internal
* @param string $name
* @param array $props
* @return Page
@@ -860,7 +869,8 @@ class Page extends ModelWithContent
* Returns the panel icon definition
* according to the blueprint settings
*
* @params array $params
* @internal
* @param array $params
* @return array
*/
public function panelIcon(array $params = null): array
@@ -896,6 +906,7 @@ class Page extends ModelWithContent
* Returns the escaped Id, which is
* used in the panel to make routing work properly
*
* @internal
* @return string
*/
public function panelId(): string
@@ -904,6 +915,7 @@ class Page extends ModelWithContent
}
/**
* @internal
* @param string|array|false $settings
* @param array|null $thumbSettings
* @return array|null
@@ -939,6 +951,7 @@ class Page extends ModelWithContent
/**
* Returns the full path without leading slash
*
* @internal
* @return string
*/
public function panelPath(): string
@@ -950,6 +963,7 @@ class Page extends ModelWithContent
* Returns the url to the editing view
* in the panel
*
* @internal
* @return string
*/
public function panelUrl(bool $relative = false): string
@@ -974,6 +988,7 @@ class Page extends ModelWithContent
/**
* Returns the parent id, if a parent exists
*
* @internal
* @return string|null
*/
public function parentId(): ?string
@@ -990,6 +1005,7 @@ class Page extends ModelWithContent
* which can either be another Page
* or the Site
*
* @internal
* @return Page|Site
*/
public function parentModel()
@@ -1028,6 +1044,7 @@ class Page extends ModelWithContent
/**
* Draft preview Url
*
* @internal
* @return string|null
*/
public function previewUrl(): ?string
@@ -1054,6 +1071,7 @@ class Page extends ModelWithContent
/**
* Creates a string query, starting from the model
*
* @internal
* @param string|null $query
* @param string|null $expect
* @return mixed
@@ -1143,6 +1161,7 @@ class Page extends ModelWithContent
}
/**
* @internal
* @return Template
*/
public function representation($type)
@@ -1514,6 +1533,7 @@ class Page extends ModelWithContent
/**
* Builds the Url for a specific language
*
* @internal
* @param string $language
* @param array $options
* @return string