Upgrade to 3.0.1

This commit is contained in:
Bastian Allgeier
2019-02-05 11:26:42 +01:00
parent 1dc0eeb768
commit f76ee1bb14
39 changed files with 4217 additions and 65 deletions

View File

@@ -72,7 +72,7 @@ return [
/**
* Query for the files to be included
*/
'query' => function (string $query = 'page.files') {
'query' => function (string $query = null) {
return $query;
},
@@ -105,6 +105,9 @@ return [
'parent' => function () {
return $this->parentModel->apiUrl(true);
},
'query' => function () {
return $this->query ?? $this->parentModel::CLASS_ALIAS . '.files';
},
'default' => function () {
return $this->toFiles($this->default);
},

View File

@@ -702,7 +702,7 @@ function twitter(string $username, string $text = null, string $title = null, st
* Shortcut for url()
*
* @param string $path
* @param array|null $options
* @param array|string|null $options
* @return string
*/
function u(string $path = null, $options = null): string
@@ -714,7 +714,7 @@ function u(string $path = null, $options = null): string
* Builds an absolute URL for a given path
*
* @param string $path
* @param array $options
* @param array|string|null $options
* @return string
*/
function url(string $path = null, $options = null): string

View File

@@ -136,6 +136,7 @@ return [
'link' => [
'attr' => [
'class',
'lang',
'rel',
'role',
'target',
@@ -143,6 +144,10 @@ return [
'text',
],
'html' => function ($tag) {
if (empty($tag->lang) === false) {
$tag->value = Url::to($tag->value, $tag->lang);
}
return Html::a($tag->value, $tag->text, [
'rel' => $tag->rel,
'class' => $tag->class,