diff --git a/app/Language/en/Admin.php b/app/Language/en/Admin.php new file mode 100644 index 0000000000000000000000000000000000000000..62a75a8e29f98d1d574642e57df110d3726b25c4 --- /dev/null +++ b/app/Language/en/Admin.php @@ -0,0 +1,12 @@ +<?php + +/** + * @copyright 2020 Podlibre + * @license https://www.gnu.org/licenses/agpl-3.0.en.html AGPL3 + * @link https://castopod.org/ + */ + +return [ + 'dashboard' => 'Admin dashboard', + 'welcome_message' => 'Welcome to the admin area!', +]; diff --git a/app/Language/en/AdminNavigation.php b/app/Language/en/AdminNavigation.php index 212863f5d14fc7e6f01e2c83ab50ffd82651e91a..d9c2ada029b5d50c3d98ea26814e3b339a873fba 100644 --- a/app/Language/en/AdminNavigation.php +++ b/app/Language/en/AdminNavigation.php @@ -20,4 +20,9 @@ return [ 'pages' => 'Pages', 'page-list' => 'All pages', 'page-create' => 'New Page', + 'account' => [ + 'my-account' => 'My account', + 'change-password' => 'Change password', + 'logout' => 'Logout', + ], ]; diff --git a/app/Views/_assets/styles/radioBtn.css b/app/Views/_assets/styles/radioBtn.css index 7e6045d6f4679201e5df9ec34d94407815f04cd4..1007c673332115ab6d24a534f6600c98cc49b7e9 100644 --- a/app/Views/_assets/styles/radioBtn.css +++ b/app/Views/_assets/styles/radioBtn.css @@ -7,7 +7,7 @@ } .form-radio-btn + label { - @apply px-2 py-1 text-sm text-black bg-white border rounded cursor-pointer; + @apply inline-block px-2 py-1 text-sm text-black bg-white border rounded cursor-pointer; &:hover { @apply bg-green-100; diff --git a/app/Views/admin/_layout.php b/app/Views/admin/_layout.php index d18c245949f167592308d8061db669c1911f76b7..d04edd4e19c58e22d3ff2e3e00028ca0207eac20 100644 --- a/app/Views/admin/_layout.php +++ b/app/Views/admin/_layout.php @@ -30,7 +30,7 @@ 'pageTitle' ) ?></h1> </div> - <div class="flex flex-wrap gap-y-2"><?= $this->renderSection( + <div class="flex flex-wrap"><?= $this->renderSection( 'headerRight' ) ?></div> </div> diff --git a/app/Views/admin/_sidebar.php b/app/Views/admin/_sidebar.php index d6e1bf49d751fff870c339a4a0a1fd977d690e04..b57cccfe2b7dfd38d293292d4212ee028b7c9ef3 100644 --- a/app/Views/admin/_sidebar.php +++ b/app/Views/admin/_sidebar.php @@ -52,13 +52,12 @@ $navigation = [ <nav class="absolute z-50 flex-col hidden py-2 text-black whitespace-no-wrap bg-white border rounded shadow" aria-labelledby="my-accountDropdown" data-popper="menu" data-popper-placement="right-end"> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'my-account' - ) ?>">My Account</a> + ) ?>"><?= lang('AdminNavigation.account.my-account') ?></a> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'change-password' - ) ?>">Change password</a> + ) ?>"><?= lang('AdminNavigation.account.change-password') ?></a> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'logout' - ) ?>">Logout</a> + ) ?>"><?= lang('AdminNavigation.account.logout') ?></a> </nav> </div> - diff --git a/app/Views/admin/dashboard.php b/app/Views/admin/dashboard.php index 214ccaaf7a8fc2b9df7707f5a50056cbe13f289b..58bc0229f5d74a3bc18ed3b872fe4806ea74da5e 100644 --- a/app/Views/admin/dashboard.php +++ b/app/Views/admin/dashboard.php @@ -2,13 +2,13 @@ <?= $this->extend('admin/_layout') ?> <?= $this->section('title') ?> -Dashboard +<?= lang('Admin.dashboard') ?> <?= $this->endSection() ?> <?= $this->section('pageTitle') ?> -Admin dashboard +<?= lang('Admin.dashboard') ?> <?= $this->endSection() ?> <?= $this->section('content') ?> -Welcome to the admin area! +<?= lang('Admin.welcome_message') ?> <?= $this->endsection() ?> diff --git a/app/Views/admin/episode/create.php b/app/Views/admin/episode/create.php index 30bf7fc1e534766bf3a8b9870ddda93a98965f02..e983158e9d2e0f3d3db770624984371641f437bf 100644 --- a/app/Views/admin/episode/create.php +++ b/app/Views/admin/episode/create.php @@ -108,7 +108,7 @@ </div> -<?= form_fieldset('', ['class' => 'flex mb-4 gap-1']) ?> +<?= form_fieldset('', ['class' => 'mb-4']) ?> <legend> <?= lang('Episode.form.type.label') . hint_tooltip(lang('Episode.form.type.hint'), 'ml-1') ?> diff --git a/app/Views/admin/episode/edit.php b/app/Views/admin/episode/edit.php index 155013db42611d68874d7ae55ce16b54a49c4456..3048e1776f7aad7d583b33a6b639c21dc914c3da 100644 --- a/app/Views/admin/episode/edit.php +++ b/app/Views/admin/episode/edit.php @@ -233,7 +233,7 @@ <?= form_fieldset_close() ?> -<?= form_fieldset('', ['class' => 'flex mb-6 gap-1']) ?> +<?= form_fieldset('', ['class' => 'mb-6']) ?> <legend> <?= lang('Episode.form.parental_advisory.label') . hint_tooltip(lang('Episode.form.type.hint'), 'ml-1') ?> @@ -287,11 +287,7 @@ hint_tooltip(lang('Episode.form.block_hint'), 'ml-1'), ['id' => 'block', 'name' => 'block'], 'yes', - old( - 'block', - - $episode->block - ) + old('block', $episode->block) ) ?> <?= form_section_close() ?> diff --git a/app/Views/admin/my_account/change_password.php b/app/Views/admin/my_account/change_password.php index 9ae867b6a71e4331dac121d95efd2d28e7505f2d..3c34726ba43269c896cd81a039fdce6d6382ec47 100644 --- a/app/Views/admin/my_account/change_password.php +++ b/app/Views/admin/my_account/change_password.php @@ -4,6 +4,10 @@ <?= lang('MyAccount.changePassword') ?> <?= $this->endSection() ?> +<?= $this->section('pageTitle') ?> +<?= lang('MyAccount.changePassword') ?> +<?= $this->endSection() ?> + <?= $this->section('content') ?> diff --git a/app/Views/admin/my_account/view.php b/app/Views/admin/my_account/view.php index 556876d561d73b3cc7d4447f1973f841ce7410bc..6dc6b8d93254f3c327c1548fbe809de878e843c4 100644 --- a/app/Views/admin/my_account/view.php +++ b/app/Views/admin/my_account/view.php @@ -4,6 +4,10 @@ <?= lang('MyAccount.info') ?> <?= $this->endSection() ?> +<?= $this->section('pageTitle') ?> +<?= lang('MyAccount.info') ?> +<?= $this->endSection() ?> + <?= $this->section('content') ?> diff --git a/app/Views/admin/podcast/_sidebar.php b/app/Views/admin/podcast/_sidebar.php index 570008cc875bf1167db5c071985d3a7d0a0063a4..1f4957831605f52f777e0f03f99c434eb3bdda10 100644 --- a/app/Views/admin/podcast/_sidebar.php +++ b/app/Views/admin/podcast/_sidebar.php @@ -83,12 +83,12 @@ $podcastNavigation = [ <nav class="absolute z-50 flex-col hidden py-2 text-black whitespace-no-wrap bg-white border rounded shadow" aria-labelledby="my-accountDropdown" data-popper="menu" data-popper-placement="right-end"> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'my-account' - ) ?>">My Account</a> + ) ?>"><?= lang('AdminNavigation.account.my-account') ?></a> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'change-password' - ) ?>">Change password</a> + ) ?>"><?= lang('AdminNavigation.account.change-password') ?></a> <a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to( 'logout' - ) ?>">Logout</a> + ) ?>"><?= lang('AdminNavigation.account.logout') ?></a> </nav> </div> diff --git a/app/Views/admin/podcast/create.php b/app/Views/admin/podcast/create.php index e5bd33a065b391665a8703af84d26059fdaf49da..006dd61a87f490c6689f1e2c3dc06845ebdebb1a 100644 --- a/app/Views/admin/podcast/create.php +++ b/app/Views/admin/podcast/create.php @@ -58,7 +58,9 @@ 'required' => 'required', ]) ?> -<?= form_fieldset('', ['class' => 'flex mb-4 gap-1']) ?> +<?= form_fieldset('', [ + 'class' => 'mb-4', +]) ?> <legend> <?= lang('Podcast.form.type.label') . hint_tooltip(lang('Podcast.form.type.hint'), 'ml-1') ?> @@ -131,7 +133,7 @@ ] ) ?> -<?= form_fieldset('', ['class' => 'flex mb-4 gap-1']) ?> +<?= form_fieldset('', ['class' => 'mb-4']) ?> <legend> <?= lang('Podcast.form.parental_advisory.label') . hint_tooltip(lang('Podcast.form.parental_advisory.hint'), 'ml-1') ?> diff --git a/app/Views/admin/podcast/edit.php b/app/Views/admin/podcast/edit.php index 8b6b1c6c06c200acd84d6518ba5f69382ec955e5..2a3933b719ea59c40e98ba0c771592a94e5e5c1e 100644 --- a/app/Views/admin/podcast/edit.php +++ b/app/Views/admin/podcast/edit.php @@ -61,7 +61,7 @@ 'required' => 'required', ]) ?> -<?= form_fieldset('', ['class' => 'flex mb-4 gap-1']) ?> +<?= form_fieldset('', ['class' => 'mb-4']) ?> <legend><?= lang('Podcast.form.type.label') . hint_tooltip(lang('Podcast.form.type.hint'), 'ml-1') ?> </legend> @@ -143,7 +143,7 @@ ] ) ?> -<?= form_fieldset('', ['class' => 'flex mb-4 gap-1']) ?> +<?= form_fieldset('', ['class' => 'mb-4']) ?> <legend><?= lang('Podcast.form.parental_advisory.label') . hint_tooltip(lang('Podcast.form.parental_advisory.hint'), 'ml-1') ?> </legend>