Add blueprints and fake content
This commit is contained in:
parent
1ff19bf38f
commit
8235816462
592 changed files with 22385 additions and 31535 deletions
40
kirby/config/areas/account/views.php
Normal file
40
kirby/config/areas/account/views.php
Normal file
|
@ -0,0 +1,40 @@
|
|||
<?php
|
||||
|
||||
use Kirby\Cms\Find;
|
||||
use Kirby\Panel\Panel;
|
||||
|
||||
return [
|
||||
'account' => [
|
||||
'pattern' => 'account',
|
||||
'action' => function () {
|
||||
return [
|
||||
'component' => 'k-account-view',
|
||||
'props' => kirby()->user()->panel()->props(),
|
||||
];
|
||||
},
|
||||
],
|
||||
'account.file' => [
|
||||
'pattern' => 'account/files/(:any)',
|
||||
'action' => function (string $filename) {
|
||||
return Find::file('account', $filename)->panel()->view();
|
||||
}
|
||||
],
|
||||
'account.logout' => [
|
||||
'pattern' => 'logout',
|
||||
'auth' => false,
|
||||
'action' => function () {
|
||||
if ($user = kirby()->user()) {
|
||||
$user->logout();
|
||||
}
|
||||
Panel::go('login');
|
||||
},
|
||||
],
|
||||
'account.password' => [
|
||||
'pattern' => 'reset-password',
|
||||
'action' => function () {
|
||||
return [
|
||||
'component' => 'k-reset-password-view',
|
||||
];
|
||||
}
|
||||
]
|
||||
];
|
Loading…
Add table
Add a link
Reference in a new issue