diff --git a/app/Resources/js/vite-env.d.ts b/app/Resources/js/vite-env.d.ts index 11f02fe2..ff39e4c2 100644 --- a/app/Resources/js/vite-env.d.ts +++ b/app/Resources/js/vite-env.d.ts @@ -1 +1,2 @@ /// +declare module "*"; diff --git a/app/Views/Components/Heading.php b/app/Views/Components/Heading.php new file mode 100644 index 00000000..8333be2c --- /dev/null +++ b/app/Views/Components/Heading.php @@ -0,0 +1,38 @@ +level === '') { + throw new Exception('level property must be set for Heading component.'); + } + + $sizeClasses = [ + 'small' => 'tracking-wide text-base', + 'base' => 'text-xl', + 'large' => 'text-3xl', + ]; + + $class = 'relative z-10 font-bold text-pine-800 font-display before:w-full before:absolute before:h-1/2 before:left-0 before:bottom-0 before:rounded-full before:bg-pine-100 before:-z-10 ' . $sizeClasses[$this->size]; + $level = $this->level; + + return <<{$this->slot} + HTML; + } +} diff --git a/app/Views/_message_block.php b/app/Views/_message_block.php index 692baf70..1c6fd67b 100644 --- a/app/Views/_message_block.php +++ b/app/Views/_message_block.php @@ -1,4 +1,6 @@ -has('message')): ?> +has('message')): ?>
diff --git a/app/Views/errors/cli/error_404.php b/app/Views/errors/cli/error_404.php index 456ea3e8..452a86d5 100644 --- a/app/Views/errors/cli/error_404.php +++ b/app/Views/errors/cli/error_404.php @@ -1,5 +1,7 @@ getFile()) . ':' . $exception->getLine(), - 'green', - ), -); +CLI::write('at ' . CLI::color(clean_path($exception->getFile()) . ':' . $exception->getLine(), 'green', ), ); CLI::newLine(); // The backtrace if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE) { @@ -24,8 +21,7 @@ if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE) { } foreach ($backtraces as $i => $error) { - $padFile = ' '; // 4 spaces - $padClass = ' '; // 7 spaces + $padFile = ' '; $c = str_pad($i + 1, 3, ' ', STR_PAD_LEFT); if (isset($error['file'])) { @@ -33,9 +29,7 @@ if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE) { CLI::write($c . $padFile . CLI::color($filepath, 'yellow')); } else { - CLI::write( - $c . $padFile . CLI::color('[internal function]', 'yellow'), - ); + CLI::write($c . $padFile . CLI::color('[internal function]', 'yellow'), ); } $function = ''; @@ -47,7 +41,7 @@ if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE) { : $error['type']; $function .= $padClass . $error['class'] . $type . $error['function']; - } elseif (!isset($error['class']) && isset($error['function'])) { + } elseif (! isset($error['class']) && isset($error['function'])) { $function .= $padClass . $error['function']; } @@ -57,7 +51,7 @@ if (defined('SHOW_DEBUG_BACKTRACE') && SHOW_DEBUG_BACKTRACE) { return match (true) { is_object($value) => 'Object(' . $value::class . ')', is_array($value) => $value !== [] ? '[...]' : '[]', - is_null($value) => 'null', + $value === null => 'null', default => var_export($value, true), }; }, array_values($error['args'] ?? [])), diff --git a/app/Views/errors/cli/production.php b/app/Views/errors/cli/production.php index 7db744ec..f1dacf1b 100644 --- a/app/Views/errors/cli/production.php +++ b/app/Views/errors/cli/production.php @@ -1,5 +1,7 @@ @@ -82,7 +82,7 @@ $errorId = uniqid('error', true); ?>   —   - + ( arguments )
@@ -91,9 +91,9 @@ $errorId = uniqid('error', true); ?> getParameters(); + if (! str_ends_with($row['function'], '}')) { + $mirror = isset($row['class']) ? new ReflectionMethod($row['class'], $row['function']) : new ReflectionFunction($row['function']); + $params = $mirror->getParameters(); } foreach ($row['args'] as $key => $value): ?> @@ -111,7 +111,7 @@ $errorId = uniqid('error', true); ?> - +   —   ()

@@ -132,9 +132,9 @@ $errorId = uniqid('error', true); ?>
- +

$

@@ -165,7 +165,7 @@ $errorId = uniqid('error', true); ?> - +

Constants

@@ -234,9 +234,9 @@ $errorId = uniqid('error', true); ?> - + @@ -276,7 +276,7 @@ $errorId = uniqid('error', true); ?> getHeaders(); ?> - +

Headers

@@ -290,11 +290,11 @@ $errorId = uniqid('error', true); ?> - + continue; + } ?> + @@ -389,7 +389,7 @@ $errorId = uniqid('error', true); ?>

Displayed at — - PHP: — + PHP: — CodeIgniter:

diff --git a/app/Views/pager/default_full.php b/app/Views/pager/default_full.php index 2f002792..55685ef7 100644 --- a/app/Views/pager/default_full.php +++ b/app/Views/pager/default_full.php @@ -1,10 +1,8 @@ -setSurroundCount(2); ?> @@ -23,8 +21,8 @@ $pager->setSurroundCount(2); 'Pager.previous', ) ?>" class="block px-3 py-2 text-gray-700 hover:bg-gray-200 hover:text-black"> + 'Pager.previous', +) ?> @@ -48,15 +46,15 @@ $pager->setSurroundCount(2); hasNextPage()): ?>
  • + 'Pager.next', + ) ?>" class="block px-3 py-2 text-gray-700 hover:bg-gray-200 hover:text-black">
  • + 'Pager.last', + ) ?>" class="block px-3 py-2 text-gray-700 hover:bg-gray-200 hover:text-black">
  • diff --git a/ecs.php b/ecs.php index c60598aa..939cae29 100644 --- a/ecs.php +++ b/ecs.php @@ -1,9 +1,11 @@ parameters(); @@ -12,21 +14,32 @@ return static function (ContainerConfigurator $containerConfigurator): void { $parameters->set(Option::PATHS, [ __DIR__ . '/app', __DIR__ . '/modules', + __DIR__ . '/themes', __DIR__ . '/tests', __DIR__ . '/public', + __DIR__ . '/public', ]); $parameters->set(Option::SKIP, [ - // TODO: restrict some rules for views? - __DIR__ . '/app/Views/*', - __DIR__ . '/modules/**/Views/*', - // skip specific generated files __DIR__ . '/modules/Admin/Language/*/PersonsTaxonomy.php', StandardizeHereNowDocKeywordFixer::class => [ - __DIR__ . '/app/View/Components', - __DIR__ . '/modules/**/View/Components', + __DIR__ . '/app/Views/Components/*', + __DIR__ . '/modules/**/Views/Components/*', + __DIR__ . '/themes/**/Views/Components/*', + ], + + LineLengthFixer::class => [ + __DIR__ . '/app/Views/*', + __DIR__ . '/modules/**/Views/*', + __DIR__ . '/themes/*', + ], + + IndentationTypeFixer::class => [ + __DIR__ . '/app/Views/*', + __DIR__ . '/modules/**/Views/*', + __DIR__ . '/themes/*', ] ]); diff --git a/tailwind.config.js b/tailwind.config.js index c9a7ffab..b7cad2d8 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -4,7 +4,6 @@ module.exports = { mode: "jit", purge: [ "./app/Views/**/*.php", - "./app/View/Components/**/*.php", "./modules/**/Views/**/*.php", "./themes/**/*.php", "./app/Helpers/*.php", @@ -49,6 +48,9 @@ module.exports = { gridTemplateColumns: { podcasts: "repeat(auto-fill, minmax(14rem, 1fr))", }, + zIndex: { + "-10": "-10", + }, }, }, variants: {}, diff --git a/themes/cp_admin/_layout.php b/themes/cp_admin/_layout.php index 7b9e6acf..29f81156 100644 --- a/themes/cp_admin/_layout.php +++ b/themes/cp_admin/_layout.php @@ -1,5 +1,6 @@ - + @@ -8,9 +9,12 @@ - asset('styles/index.css', 'css') ?> - asset('js/admin.ts', 'js') ?> - asset('js/audio-player.ts', 'js') ?> + asset('styles/index.css', 'css') ?> + asset('js/admin.ts', 'js') ?> + asset('js/audio-player.ts', 'js') ?> @@ -18,13 +22,13 @@
    + 'admin', + ) ?>" class="inline-flex items-center h-full px-2 border-r border-pine-900"> + 'home', + ) ?>" class="inline-flex items-center h-full px-6 text-sm font-semibold outline-none hover:underline focus:ring"> @@ -38,7 +42,8 @@ aria-haspopup="true" aria-expanded="false"> - username ?> + username ?>
    + lang('Episode.soundbites_form.start_time'), + 'start_time', + [], + lang('Episode.soundbites_form.start_time_hint'), +) ?> + lang('Episode.soundbites_form.duration'), + 'duration', + [], + lang('Episode.soundbites_form.duration_hint'), +) ?> + lang('Episode.soundbites_form.label'), + 'label', + [], + lang('Episode.soundbites_form.label_hint'), + true, +) ?> @@ -52,124 +55,130 @@ soundbites as $soundbite): ?> + [ + 'type' => 'number', + 'min' => 0, + 'max' => $episode->audio_file_duration, + 'step' => 'any', + 'id' => "soundbites[{$soundbite->id}][start_time]", + 'name' => "soundbites[{$soundbite->id}][start_time]", + 'class' => 'form-input w-full border-none text-center', + 'value' => $soundbite->start_time, + 'data-type' => 'soundbite-field', + 'data-field-type' => 'start-time', + 'data-soundbite-id' => $soundbite->id, + 'required' => 'required', + ], +) ?> + [ + 'type' => 'number', + 'min' => 0, + 'max' => $episode->audio_file_duration, + 'step' => 'any', + 'id' => "soundbites[{$soundbite->id}][duration]", + 'name' => "soundbites[{$soundbite->id}][duration]", + 'class' => 'form-input w-full border-none text-center', + 'value' => $soundbite->duration, + 'data-type' => 'soundbite-field', + 'data-field-type' => 'duration', + 'data-soundbite-id' => $soundbite->id, + 'required' => 'required', + ], +) ?> + [ + 'id' => "soundbites[{$soundbite->id}][label]", + 'name' => "soundbites[{$soundbite->id}][label]", + 'class' => 'form-input w-full border-none', + 'value' => $soundbite->label, + ], +) ?> + [ + 'type' => 'number', + 'min' => 0, + 'max' => $episode->audio_file_duration, + 'step' => 'any', + 'id' => 'soundbites[0][start_time]', + 'name' => 'soundbites[0][start_time]', + 'class' => 'form-input w-full border-none text-center', + 'value' => old('start_time'), + 'data-soundbite-id' => '0', + 'data-type' => 'soundbite-field', + 'data-field-type' => 'start-time', + ], +) ?> + [ + 'type' => 'number', + 'min' => 0, + 'max' => $episode->audio_file_duration, + 'step' => 'any', + 'id' => 'soundbites[0][duration]', + 'name' => 'soundbites[0][duration]', + 'class' => 'form-input w-full border-none text-center', + 'value' => old('duration'), + 'data-soundbite-id' => '0', + 'data-type' => 'soundbite-field', + 'data-field-type' => 'duration', + ], +) ?> + [ + 'id' => 'soundbites[0][label]', + 'name' => 'soundbites[0][label]', + 'class' => 'form-input w-full border-none', + 'value' => old('label'), + ], +) ?> @@ -180,16 +189,18 @@ Your browser does not support the audio tag. + 'timer', + lang('Episode.soundbites_form.bookmark'), + '', + [ + 'variant' => 'info', + ], + [ + 'data-type' => 'get-soundbite', + 'data-start-time-field-name' => 'soundbites[0][start_time]', + 'data-duration-field-name' => 'soundbites[0][duration]', + ], +) ?>
    getName(), 'html') ?>
    'number', - 'min' => 0, - 'max' => $episode->audio_file_duration, - 'step' => 'any', - 'id' => "soundbites[{$soundbite->id}][start_time]", - 'name' => "soundbites[{$soundbite->id}][start_time]", - 'class' => 'form-input w-full border-none text-center', - 'value' => $soundbite->start_time, - 'data-type' => 'soundbite-field', - 'data-field-type' => 'start-time', - 'data-soundbite-id' => $soundbite->id, - 'required' => 'required', - ], - ) ?> 'number', - 'min' => 0, - 'max' => $episode->audio_file_duration, - 'step' => 'any', - 'id' => "soundbites[{$soundbite->id}][duration]", - 'name' => "soundbites[{$soundbite->id}][duration]", - 'class' => 'form-input w-full border-none text-center', - 'value' => $soundbite->duration, - 'data-type' => 'soundbite-field', - 'data-field-type' => 'duration', - 'data-soundbite-id' => $soundbite->id, - 'required' => 'required', - ], - ) ?> "soundbites[{$soundbite->id}][label]", - 'name' => "soundbites[{$soundbite->id}][label]", - 'class' => 'form-input w-full border-none', - 'value' => $soundbite->label, - ], - ) ?> 'primary'], - [ - 'class' => 'mb-1 mr-1', - 'data-type' => 'play-soundbite', - 'data-soundbite-id' => $soundbite->id, - 'data-soundbite-start-time' => $soundbite->start_time, - 'data-soundbite-duration' => $soundbite->duration, - ], - ) ?> + 'play', + lang('Episode.soundbites_form.play'), + '', + [ + 'variant' => 'primary', + ], + [ + 'class' => 'mb-1 mr-1', + 'data-type' => 'play-soundbite', + 'data-soundbite-id' => $soundbite->id, + 'data-soundbite-start-time' => $soundbite->start_time, + 'data-soundbite-duration' => $soundbite->duration, + ], +) ?> id, - $episode->id, - $soundbite->id, - ), - ['variant' => 'danger'], - [], - ) ?> + 'delete-bin', + lang('Episode.soundbites_form.delete'), + route_to( + 'soundbite-delete', + $podcast->id, + $episode->id, + $soundbite->id, + ), + [ + 'variant' => 'danger', + ], + [], +) ?>
    'number', - 'min' => 0, - 'max' => $episode->audio_file_duration, - 'step' => 'any', - 'id' => 'soundbites[0][start_time]', - 'name' => 'soundbites[0][start_time]', - 'class' => 'form-input w-full border-none text-center', - 'value' => old('start_time'), - 'data-soundbite-id' => '0', - 'data-type' => 'soundbite-field', - 'data-field-type' => 'start-time', - ], - ) ?> 'number', - 'min' => 0, - 'max' => $episode->audio_file_duration, - 'step' => 'any', - 'id' => 'soundbites[0][duration]', - 'name' => 'soundbites[0][duration]', - 'class' => 'form-input w-full border-none text-center', - 'value' => old('duration'), - 'data-soundbite-id' => '0', - 'data-type' => 'soundbite-field', - 'data-field-type' => 'duration', - ], - ) ?> 'soundbites[0][label]', - 'name' => 'soundbites[0][label]', - 'class' => 'form-input w-full border-none', - 'value' => old('label'), - ], - ) ?> 'primary'], - [ - 'data-type' => 'play-soundbite', - 'data-soundbite-id' => 0, - 'data-soundbite-start-time' => 0, - 'data-soundbite-duration' => 0, - ], - ) ?> + 'play', + lang('Episode.soundbites_form.play'), + '', + [ + 'variant' => 'primary', + ], + [ + 'data-type' => 'play-soundbite', + 'data-soundbite-id' => 0, + 'data-soundbite-start-time' => 0, + 'data-soundbite-duration' => 0, + ], +) ?> 'info'], - [ - 'data-type' => 'get-soundbite', - 'data-start-time-field-name' => 'soundbites[0][start_time]', - 'data-duration-field-name' => 'soundbites[0][duration]', - ], - ) ?>
    @@ -199,8 +210,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/episode/unpublish.php b/themes/cp_admin/episode/unpublish.php index 17fe5db3..ab5d44eb 100644 --- a/themes/cp_admin/episode/unpublish.php +++ b/themes/cp_admin/episode/unpublish.php @@ -21,15 +21,15 @@ @@ -42,8 +42,12 @@ 'danger'], - ['type' => 'submit'], + [ + 'variant' => 'danger', + ], + [ + 'type' => 'submit', + ], ) ?>
    diff --git a/themes/cp_admin/episode/view.php b/themes/cp_admin/episode/view.php index 9f49d541..394b4211 100644 --- a/themes/cp_admin/episode/view.php +++ b/themes/cp_admin/episode/view.php @@ -33,22 +33,23 @@
    + 'analytics-filtered-data', + $podcast->id, + 'PodcastByEpisode', + 'ByDay', + $episode->id, +) ?>"/> + 'analytics-filtered-data', + $podcast->id, + 'PodcastByEpisode', + 'ByMonth', + $episode->id, +) ?>"/>
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/fediverse/blocked_actors.php b/themes/cp_admin/fediverse/blocked_actors.php index af2bab9e..b785349b 100644 --- a/themes/cp_admin/fediverse/blocked_actors.php +++ b/themes/cp_admin/fediverse/blocked_actors.php @@ -35,8 +35,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> @@ -66,7 +71,10 @@ 'fediverse-unblock-actor', $blockedActor->username, ), - ['variant' => 'info', 'size' => 'small'], + [ + 'variant' => 'info', + 'size' => 'small', + ], [ 'class' => 'mr-2', 'type' => 'submit', diff --git a/themes/cp_admin/fediverse/blocked_domains.php b/themes/cp_admin/fediverse/blocked_domains.php index 77ef604e..de8f4fd9 100644 --- a/themes/cp_admin/fediverse/blocked_domains.php +++ b/themes/cp_admin/fediverse/blocked_domains.php @@ -34,8 +34,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> @@ -64,7 +69,10 @@ 'fediverse-unblock-domain', $blockedDomain->name, ), - ['variant' => 'info', 'size' => 'small'], + [ + 'variant' => 'info', + 'size' => 'small', + ], [ 'class' => 'mr-2', 'type' => 'submit', diff --git a/themes/cp_admin/my_account/change_password.php b/themes/cp_admin/my_account/change_password.php index 0cbbe9be..7ebdd3e4 100644 --- a/themes/cp_admin/my_account/change_password.php +++ b/themes/cp_admin/my_account/change_password.php @@ -39,8 +39,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/my_account/view.php b/themes/cp_admin/my_account/view.php index fc866674..c329ea71 100644 --- a/themes/cp_admin/my_account/view.php +++ b/themes/cp_admin/my_account/view.php @@ -11,6 +11,8 @@ section('content') ?> - user()]) ?> + user(), +]) ?> endSection() ?> diff --git a/themes/cp_admin/page/create.php b/themes/cp_admin/page/create.php index 4e22306c..d1dd679c 100644 --- a/themes/cp_admin/page/create.php +++ b/themes/cp_admin/page/create.php @@ -16,7 +16,9 @@ ]) ?> - 'max-w-sm']) ?> + 'max-w-sm', +]) ?> 'title', 'name' => 'title', @@ -32,7 +34,7 @@ [], ) ?> - + 'slug', 'name' => 'slug', @@ -53,8 +55,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/page/edit.php b/themes/cp_admin/page/edit.php index b23f2e75..43bb8016 100644 --- a/themes/cp_admin/page/edit.php +++ b/themes/cp_admin/page/edit.php @@ -16,7 +16,9 @@ ]) ?> - 'max-w-sm']) ?> + 'max-w-sm', +]) ?> 'title', 'name' => 'title', @@ -52,8 +54,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/page/list.php b/themes/cp_admin/page/list.php index a780e042..60cd46fb 100644 --- a/themes/cp_admin/page/list.php +++ b/themes/cp_admin/page/list.php @@ -40,18 +40,28 @@ 'variant' => 'secondary', 'size' => 'small', ], - ['class' => 'mr-2'], + [ + 'class' => 'mr-2', + ], ) . button( lang('Page.edit'), route_to('page-edit', $page->id), - ['variant' => 'info', 'size' => 'small'], - ['class' => 'mr-2'], + [ + 'variant' => 'info', + 'size' => 'small', + ], + [ + 'class' => 'mr-2', + ], ) . button( lang('Page.delete'), route_to('page-delete', $page->id), - ['variant' => 'danger', 'size' => 'small'], + [ + 'variant' => 'danger', + 'size' => 'small', + ], ); }, ], diff --git a/themes/cp_admin/person/create.php b/themes/cp_admin/person/create.php index 4eee7be1..29c6359e 100644 --- a/themes/cp_admin/person/create.php +++ b/themes/cp_admin/person/create.php @@ -83,8 +83,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/person/edit.php b/themes/cp_admin/person/edit.php index e7bd273a..9fef817f 100644 --- a/themes/cp_admin/person/edit.php +++ b/themes/cp_admin/person/edit.php @@ -84,8 +84,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/person/list.php b/themes/cp_admin/person/list.php index 0da3d289..e3761f33 100644 --- a/themes/cp_admin/person/list.php +++ b/themes/cp_admin/person/list.php @@ -12,8 +12,13 @@ 'primary', 'iconLeft' => 'add'], - ['class' => 'mr-2'], + [ + 'variant' => 'primary', + 'iconLeft' => 'add', + ], + [ + 'class' => 'mr-2', + ], ) ?> endSection() ?> @@ -26,34 +31,34 @@ <?= $person->full_name ?> + ->thumbnail_url ?>" class="object-cover w-full" />
    + 'person-edit', + $person->id, + ) ?>" data-toggle="tooltip" data-placement="bottom" title=""> + 'person-delete', + $person->id, + ) ?>" data-toggle="tooltip" data-placement="bottom" title=""> + 'person-view', + $person->id, + ) ?>" data-toggle="tooltip" data-placement="bottom" title="">
    diff --git a/themes/cp_admin/person/view.php b/themes/cp_admin/person/view.php index 94d7c9b7..859b0db1 100644 --- a/themes/cp_admin/person/view.php +++ b/themes/cp_admin/person/view.php @@ -13,8 +13,13 @@ id), - ['variant' => 'secondary', 'iconLeft' => 'edit'], - ['class' => 'mr-2'], + [ + 'variant' => 'secondary', + 'iconLeft' => 'edit', + ], + [ + 'class' => 'mr-2', + ], ) ?> endSection() ?> diff --git a/themes/cp_admin/podcast/_sidebar.php b/themes/cp_admin/podcast/_sidebar.php index ecd2d9d4..69904732 100644 --- a/themes/cp_admin/podcast/_sidebar.php +++ b/themes/cp_admin/podcast/_sidebar.php @@ -1,4 +1,5 @@ - [ 'icon' => 'dashboard', @@ -43,12 +44,12 @@ $podcastNavigation = [ @@ -67,9 +68,9 @@ $podcastNavigation = [ + $item, + $podcast->id, + ) ?>"> diff --git a/themes/cp_admin/podcast/analytics/index.php b/themes/cp_admin/podcast/analytics/index.php index 3fea6b28..cf207790 100644 --- a/themes/cp_admin/podcast/analytics/index.php +++ b/themes/cp_admin/podcast/analytics/index.php @@ -12,26 +12,27 @@
    + 'analytics-data', + $podcast->id, + 'Podcast', + 'ByDay', +) ?>"/> + 'analytics-data', + $podcast->id, + 'Podcast', + 'ByMonth', +) ?>"/> + 'analytics-data', + $podcast->id, + 'Podcast', + 'BandwidthByDay', +) ?>"/>
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/listening_time.php b/themes/cp_admin/podcast/analytics/listening_time.php index 223ec84c..6a6e45c6 100644 --- a/themes/cp_admin/podcast/analytics/listening_time.php +++ b/themes/cp_admin/podcast/analytics/listening_time.php @@ -12,19 +12,20 @@
    + 'analytics-data', + $podcast->id, + 'Podcast', + 'TotalListeningTimeByDay', +) ?>"/> + 'analytics-data', + $podcast->id, + 'Podcast', + 'TotalListeningTimeByMonth', +) ?>"/>
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/locations.php b/themes/cp_admin/podcast/analytics/locations.php index eaa7d1c7..76ddd8bf 100644 --- a/themes/cp_admin/podcast/analytics/locations.php +++ b/themes/cp_admin/podcast/analytics/locations.php @@ -12,24 +12,25 @@
    + 'analytics-data', + $podcast->id, + 'PodcastByCountry', + 'Weekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'PodcastByCountry', + 'Yearly', +) ?>" /> + 'analytics-full-data', + $podcast->id, + 'PodcastByRegion', +) ?>" />
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/players.php b/themes/cp_admin/podcast/analytics/players.php index faa249bd..d3eba784 100644 --- a/themes/cp_admin/podcast/analytics/players.php +++ b/themes/cp_admin/podcast/analytics/players.php @@ -12,36 +12,37 @@
    + 'analytics-data', + $podcast->id, + 'PodcastByPlayer', + 'ByAppWeekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'PodcastByService', + 'ByServiceWeekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'PodcastByPlayer', + 'ByDeviceWeekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'PodcastByPlayer', + 'ByOsWeekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'PodcastByPlayer', + 'Bots', +) ?>" />
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/time_periods.php b/themes/cp_admin/podcast/analytics/time_periods.php index bf492fce..00d37795 100644 --- a/themes/cp_admin/podcast/analytics/time_periods.php +++ b/themes/cp_admin/podcast/analytics/time_periods.php @@ -12,17 +12,18 @@
    + 'analytics-data', + $podcast->id, + 'Podcast', + 'ByWeekday', +) ?>" /> + 'analytics-full-data', + $podcast->id, + 'PodcastByHour', +) ?>" />
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/unique_listeners.php b/themes/cp_admin/podcast/analytics/unique_listeners.php index f7129e56..088c396f 100644 --- a/themes/cp_admin/podcast/analytics/unique_listeners.php +++ b/themes/cp_admin/podcast/analytics/unique_listeners.php @@ -12,19 +12,20 @@
    + 'analytics-data', + $podcast->id, + 'Podcast', + 'UniqueListenersByDay', +) ?>"/> + 'analytics-data', + $podcast->id, + 'Podcast', + 'UniqueListenersByMonth', +) ?>"/>
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/analytics/webpages.php b/themes/cp_admin/podcast/analytics/webpages.php index dfa0ae21..3f203357 100644 --- a/themes/cp_admin/podcast/analytics/webpages.php +++ b/themes/cp_admin/podcast/analytics/webpages.php @@ -12,30 +12,31 @@
    + 'analytics-data', + $podcast->id, + 'WebsiteByReferer', + 'ByDomainWeekly', +) ?>" /> + 'analytics-data', + $podcast->id, + 'WebsiteByReferer', + 'ByDomainYearly', +) ?>" /> + 'analytics-full-data', + $podcast->id, + 'WebsiteByEntryPage', +) ?>" /> + 'analytics-full-data', + $podcast->id, + 'WebsiteByBrowser', +) ?>" />
    -asset('js/charts.ts', 'js') ?> +asset('js/charts.ts', 'js') ?> endSection() ?> diff --git a/themes/cp_admin/podcast/create.php b/themes/cp_admin/podcast/create.php index fbc89310..cbac3575 100644 --- a/themes/cp_admin/podcast/create.php +++ b/themes/cp_admin/podcast/create.php @@ -1,4 +1,5 @@ - extend('_layout') ?> @@ -61,25 +62,35 @@ 'class' => 'form-input w-full pl-8', 'value' => old('handle'), 'required' => 'required', - ]) ?> + ]) ?>
    - 'mb-4']) ?> + 'mb-4', +]) ?> 'episodic', 'name' => 'type', 'class' => 'form-radio-btn'], - 'episodic', - old('type') ? old('type') == 'episodic' : true, - ) ?> + [ + 'id' => 'episodic', + 'name' => 'type', + 'class' => 'form-radio-btn', + ], + 'episodic', + old('type') ? old('type') === 'episodic' : true, + ) ?> 'serial', 'name' => 'type', 'class' => 'form-radio-btn'], - 'serial', - old('type') && old('type') == 'serial', - ) ?> + [ + 'id' => 'serial', + 'name' => 'type', + 'class' => 'form-radio-btn', + ], + 'serial', + old('type') && old('type') === 'serial', + ) ?> @@ -92,9 +103,9 @@ + lang('Podcast.form.classification_section_title'), + lang('Podcast.form.classification_section_subtitle'), + ) ?> 'category', 'class' => 'form-select mb-4', 'required' => 'required', - 'placeholder' => lang('Podcast.form.category_placeholder') + 'placeholder' => lang('Podcast.form.category_placeholder'), ]) ?> " options="" /> - 'mb-4']) ?> + 'mb-4', +]) ?> 'undefined', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', - ], - 'undefined', - old('parental_advisory') + [ + 'id' => 'undefined', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'undefined', + old('parental_advisory') ? old('parental_advisory') === 'undefined' : true, - ) ?> + ) ?> + 'Podcast.form.parental_advisory.undefined', + ) ?> 'clean', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', - ], - 'clean', - old('parental_advisory') && old('parental_advisory') === 'clean', - ) ?> + [ + 'id' => 'clean', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'clean', + old('parental_advisory') && old('parental_advisory') === 'clean', + ) ?> + 'Podcast.form.parental_advisory.clean', + ) ?> 'explicit', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', - ], - 'explicit', - old('parental_advisory') && old('parental_advisory') === 'explicit', - ) ?> + [ + 'id' => 'explicit', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'explicit', + old('parental_advisory') && old('parental_advisory') === 'explicit', + ) ?> + 'Podcast.form.parental_advisory.explicit', + ) ?> + lang('Podcast.form.author_section_title'), + lang('Podcast.form.author_section_subtitle'), + ) ?> + lang('Podcast.form.owner_name'), + 'owner_name', + [], + lang('Podcast.form.owner_name_hint'), + ) ?> 'owner_name', - 'name' => 'owner_name', - 'class' => 'form-input mb-4', - 'value' => old('owner_name'), - 'required' => 'required', -]) ?> + 'id' => 'owner_name', + 'name' => 'owner_name', + 'class' => 'form-input mb-4', + 'value' => old('owner_name'), + 'required' => 'required', + ]) ?> + lang('Podcast.form.owner_email'), + 'owner_email', + [], + lang('Podcast.form.owner_email_hint'), + ) ?> 'owner_email', - 'name' => 'owner_email', - 'class' => 'form-input mb-4', - 'value' => old('owner_email'), - 'type' => 'email', - 'required' => 'required', -]) ?> + 'id' => 'owner_email', + 'name' => 'owner_email', + 'class' => 'form-input mb-4', + 'value' => old('owner_email'), + 'type' => 'email', + 'required' => 'required', + ]) ?> + lang('Podcast.form.publisher'), + 'publisher', + [], + lang('Podcast.form.publisher_hint'), + true, + ) ?> 'publisher', - 'name' => 'publisher', - 'class' => 'form-input mb-4', - 'value' => old('publisher'), -]) ?> + 'id' => 'publisher', + 'name' => 'publisher', + 'class' => 'form-input mb-4', + 'value' => old('publisher'), + ]) ?>
    'text-sm'], - lang('Podcast.form.partner_id_hint'), - true, - ) ?> + lang('Podcast.form.partner_id'), + 'partner_id', + [ + 'class' => 'text-sm', + ], + lang('Podcast.form.partner_id_hint'), + true, +) ?> 'partner_id', 'name' => 'partner_id', @@ -292,7 +307,9 @@ 'text-sm'], + [ + 'class' => 'text-sm', + ], lang('Podcast.form.partner_link_url_hint'), true, ) ?> @@ -307,7 +324,9 @@ 'text-sm'], + [ + 'class' => 'text-sm', + ], lang('Podcast.form.partner_image_url_hint'), true, ) ?> @@ -323,24 +342,24 @@ + lang('Podcast.form.advanced_section_title'), + lang('Podcast.form.advanced_section_subtitle'), + ) ?> + lang('Podcast.form.custom_rss'), + 'custom_rss', + [], + lang('Podcast.form.custom_rss_hint'), + true, + ) ?> + lang('Podcast.form.status_section_title'), + lang('Podcast.form.status_section_subtitle'), + ) ?> @@ -355,11 +374,16 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], -) ?> + lang('Podcast.form.submit_create'), + '', + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], + ) ?> diff --git a/themes/cp_admin/podcast/edit.php b/themes/cp_admin/podcast/edit.php index 618b6c47..9fc00099 100644 --- a/themes/cp_admin/podcast/edit.php +++ b/themes/cp_admin/podcast/edit.php @@ -1,4 +1,5 @@ - extend('_layout') ?> @@ -38,8 +39,8 @@ + 'Common.forms.image_size_hint', +) ?> @@ -53,22 +54,32 @@ link ?> - 'mb-4']) ?> + 'mb-4', +]) ?> 'episodic', 'name' => 'type', 'class' => 'form-radio-btn'], - 'episodic', - old('type') ? old('type') == 'episodic' : $podcast->type == 'episodic', -) ?> + [ + 'id' => 'episodic', + 'name' => 'type', + 'class' => 'form-radio-btn', + ], + 'episodic', + old('type') ? old('type') === 'episodic' : $podcast->type === 'episodic', + ) ?> 'serial', 'name' => 'type', 'class' => 'form-radio-btn'], - 'serial', - old('type') ? old('type') == 'serial' : $podcast->type == 'serial', -) ?> + [ + 'id' => 'serial', + 'name' => 'type', + 'class' => 'form-radio-btn', + ], + 'serial', + old('type') ? old('type') === 'serial' : $podcast->type === 'serial', + ) ?> @@ -80,42 +91,42 @@ + lang('Podcast.form.classification_section_title'), + lang('Podcast.form.classification_section_subtitle'), + ) ?> language_code)], - [ - 'id' => 'language', - 'class' => 'form-select mb-4', - 'required' => 'required', - ], -) ?> + 'language', + $languageOptions, + [old('language', $podcast->language_code)], + [ + 'id' => 'language', + 'class' => 'form-select mb-4', + 'required' => 'required', + ], + ) ?> category_id)], - [ - 'id' => 'category', - 'class' => 'form-select mb-4', - 'required' => 'required', - ], -) ?> + 'category', + $categoryOptions, + [old('category', $podcast->category_id)], + [ + 'id' => 'category', + 'class' => 'form-select mb-4', + 'required' => 'required', + ], + ) ?> + lang('Podcast.form.other_categories'), + 'other_categories', + [], + '', + true, + ) ?> - 'mb-4']) ?> + 'mb-4', +]) ?> 'undefined', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', -], - 'undefined', - old('parental_advisory') + [ + 'id' => 'undefined', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'undefined', + old('parental_advisory') ? old('parental_advisory') === 'undefined' : $podcast->parental_advisory === null, -) ?> + ) ?> + 'Podcast.form.parental_advisory.undefined', + ) ?> 'clean', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', -], - 'clean', - old('parental_advisory') + [ + 'id' => 'clean', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'clean', + old('parental_advisory') ? old('parental_advisory') === 'clean' : $podcast->parental_advisory === 'clean', -) ?> + ) ?> + 'Podcast.form.parental_advisory.clean', + ) ?> 'explicit', - 'name' => 'parental_advisory', - 'class' => 'form-radio-btn', -], - 'explicit', - old('parental_advisory') + [ + 'id' => 'explicit', + 'name' => 'parental_advisory', + 'class' => 'form-radio-btn', + ], + 'explicit', + old('parental_advisory') ? old('parental_advisory') === 'explicit' : $podcast->parental_advisory === 'explicit', -) ?> + ) ?> + 'Podcast.form.parental_advisory.explicit', + ) ?> + lang('Podcast.form.author_section_title'), + lang('Podcast.form.author_section_subtitle'), + ) ?> + lang('Podcast.form.owner_name'), + 'owner_name', + [], + lang('Podcast.form.owner_name_hint'), + ) ?> 'owner_name', @@ -284,72 +297,72 @@ lang('Podcast.form.classification_section_subtitle'),
    + 'partner_id', + 'name' => 'partner_id', + 'class' => 'form-input w-full', + 'value' => old('partner_id', $podcast->partner_id), + ]) ?> +
    +
    + 'partner_id', - 'name' => 'partner_id', - 'class' => 'form-input w-full', - 'value' => old('partner_id', $podcast->partner_id), -]) ?> + 'id' => 'partner_link_url', + 'name' => 'partner_link_url', + 'class' => 'form-input w-full', + 'value' => old('partner_link_url', $podcast->partner_link_url), + ]) ?>
    - 'partner_link_url', - 'name' => 'partner_link_url', - 'class' => 'form-input w-full', - 'value' => old('partner_link_url', $podcast->partner_link_url), -]) ?> -
    -
    - + lang('Podcast.form.partner_image_url'), + 'partner_image_url', + [], + lang('Podcast.form.partner_image_url_hint'), + true, + ) ?> 'partner_image_url', - 'name' => 'partner_image_url', - 'class' => 'form-input w-full', - 'value' => old('partner_image_url', $podcast->partner_image_url), -]) ?> + 'id' => 'partner_image_url', + 'name' => 'partner_image_url', + 'class' => 'form-input w-full', + 'value' => old('partner_image_url', $podcast->partner_image_url), + ]) ?>
    + lang('Podcast.form.advanced_section_title'), + lang('Podcast.form.advanced_section_subtitle'), + ) ?> + lang('Podcast.form.custom_rss'), + 'custom_rss', + [], + lang('Podcast.form.custom_rss_hint'), + true, + ) ?> custom_rss_string, false) ?> + lang('Podcast.form.status_section_title'), + lang('Podcast.form.status_section_subtitle'), + ) ?> diff --git a/themes/cp_admin/podcast/import.php b/themes/cp_admin/podcast/import.php index 7d279a93..cc74371e 100644 --- a/themes/cp_admin/podcast/import.php +++ b/themes/cp_admin/podcast/import.php @@ -22,28 +22,28 @@
    + [], + 'inline-flex text-xs p-2 text-blue-800 font-semibold bg-blue-100 border border-blue-300 rounded', + ) ?> + lang('PodcastImport.imported_feed_url'), + 'imported_feed_url', + [], + lang('PodcastImport.imported_feed_url_hint'), + ) ?> 'imported_feed_url', - 'name' => 'imported_feed_url', - 'class' => 'form-input', - 'value' => old('imported_feed_url'), - 'placeholder' => 'https://...', - 'type' => 'url', - 'required' => 'required', -]) ?> + 'id' => 'imported_feed_url', + 'name' => 'imported_feed_url', + 'class' => 'form-input', + 'value' => old('imported_feed_url'), + 'placeholder' => 'https://...', + 'type' => 'url', + 'required' => 'required', + ]) ?> @@ -51,11 +51,11 @@ + lang('Podcast.form.handle'), + 'handle', + [], + lang('Podcast.form.handle_hint'), + ) ?>
    'category', 'class' => 'form-select mb-4', 'required' => 'required', - 'placeholder' => lang('Podcast.form.category_placeholder') + 'placeholder' => lang('Podcast.form.category_placeholder'), ]) ?> @@ -90,85 +90,89 @@ lang('PodcastImport.advanced_params_section_subtitle'), ) ?> - 'flex flex-col mb-4']) ?> + 'flex flex-col mb-4', +]) ?> - + - 'flex flex-col mb-4']) ?> + 'flex flex-col mb-4', +]) ?> @@ -176,14 +180,14 @@ @@ -221,8 +225,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/podcast/latest_episodes.php b/themes/cp_admin/podcast/latest_episodes.php index f7985df7..bd4c78c5 100644 --- a/themes/cp_admin/podcast/latest_episodes.php +++ b/themes/cp_admin/podcast/latest_episodes.php @@ -1,10 +1,10 @@
    -

    + + 'episode-list', + $podcast->id, +) ?>" class="inline-flex items-center text-sm underline hover:no-underline"> @@ -15,10 +15,10 @@
    published_at, - $episode->publication_status, - 'absolute top-2 right-2 text-sm' - ); ?> + $episode->published_at, + $episode->publication_status, + 'absolute top-2 right-2 text-sm' +); ?> <?= $episode->title ?> @@ -26,18 +26,18 @@
    id, + $episode->id, +) ?>" class="text-sm font-semibold truncate hover:underline" > number, - $episode->season_number, - 'font-semibold text-gray-600', - true, - ) ?> + $episode->number, + $episode->season_number, + 'font-semibold text-gray-600', + true, +) ?> - title ?> @@ -59,33 +59,33 @@ data-dropdown="menu" data-dropdown-placement="bottom"> + 'episode-edit', + $podcast->id, + $episode->id, +) ?>"> id, + $episode->id, +) ?>"> + 'episode-persons-manage', + $podcast->id, + $episode->id, +) ?>"> + 'episode', + $podcast->handle, + $episode->slug, +) ?>">
    + 'episode-delete', + $podcast->id, + $episode->id, +) ?>">
    diff --git a/themes/cp_admin/podcast/list.php b/themes/cp_admin/podcast/list.php index 075b2c45..91504658 100644 --- a/themes/cp_admin/podcast/list.php +++ b/themes/cp_admin/podcast/list.php @@ -12,8 +12,13 @@ 'accent', 'iconLeft' => 'add'], - ['class' => 'mr-2'], + [ + 'variant' => 'accent', + 'iconLeft' => 'add', + ], + [ + 'class' => 'mr-2', + ], ) ?> 'primary', @@ -31,27 +36,27 @@ <?= $podcast->title ?> + ->medium_url ?>" class="object-cover w-full h-48" /> + 'podcast-view', + $podcast->id, + ) ?>" class="flex flex-col p-2 hover:underline">

    title ?>

    @handle ?>

    + 'podcast-edit', + $podcast->id, + ) ?>" data-toggle="tooltip" data-placement="bottom" title=""> + 'podcast-view', + $podcast->id, + ) ?>" data-toggle="tooltip" data-placement="bottom" title="">
    diff --git a/themes/cp_admin/podcast/persons.php b/themes/cp_admin/podcast/persons.php index 719e6020..39de64a4 100644 --- a/themes/cp_admin/podcast/persons.php +++ b/themes/cp_admin/podcast/persons.php @@ -12,8 +12,13 @@ 'primary', 'iconLeft' => 'add'], - ['class' => 'mr-2'], + [ + 'variant' => 'primary', + 'iconLeft' => 'add', + ], + [ + 'class' => 'mr-2', + ], ) ?> endSection() ?> @@ -114,8 +119,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/podcast/platforms.php b/themes/cp_admin/podcast/platforms.php index a6376785..001546d0 100644 --- a/themes/cp_admin/podcast/platforms.php +++ b/themes/cp_admin/podcast/platforms.php @@ -20,22 +20,22 @@
    submit_url, - icon( - $platform->type . '/' . $platform->slug, - 'text-gray-600 text-4xl', - ), - [ - 'class' => 'mb-1 text-gray-600 hover:text-gray-900', - 'target' => '_blank', - 'rel' => 'noopener noreferrer', - 'data-toggle' => 'tooltip', - 'data-placement' => 'bottom', - 'title' => lang('Platforms.submit_url', [ - 'platformName' => $platform->label, - ]), - ], - ) ?> + $platform->submit_url, + icon( + $platform->type . '/' . $platform->slug, + 'text-gray-600 text-4xl', + ), + [ + 'class' => 'mb-1 text-gray-600 hover:text-gray-900', + 'target' => '_blank', + 'rel' => 'noopener noreferrer', + 'data-toggle' => 'tooltip', + 'data-placement' => 'bottom', + 'title' => lang('Platforms.submit_url', [ + 'platformName' => $platform->label, + ]), + ], +) ?>
    home_url, icon('external-link', 'mx-auto'), [ 'class' => 'flex-1 text-gray-600 hover:text-gray-900', @@ -103,19 +103,24 @@ 'type' => 'text', 'placeholder' => lang("Platforms.description.{$platform->type}"), ]) ?> - - + +
    'primary'], - ['type' => 'submit', 'class' => 'self-end'], -) ?> + lang('Platforms.submit'), + '', + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], + ) ?> diff --git a/themes/cp_admin/podcast/view.php b/themes/cp_admin/podcast/view.php index 9658af48..53bf6dcd 100644 --- a/themes/cp_admin/podcast/view.php +++ b/themes/cp_admin/podcast/view.php @@ -12,8 +12,13 @@ id), - ['variant' => 'primary', 'iconLeft' => 'edit'], - ['class' => 'mr-2'], + [ + 'variant' => 'primary', + 'iconLeft' => 'edit', + ], + [ + 'class' => 'mr-2', + ], ) ?> id), [ 'variant' => 'accent', diff --git a/themes/cp_admin/user/create.php b/themes/cp_admin/user/create.php index 47967cc8..ce2af3a5 100644 --- a/themes/cp_admin/user/create.php +++ b/themes/cp_admin/user/create.php @@ -11,7 +11,9 @@ section('content') ?> - 'flex flex-col max-w-sm']) ?> + 'flex flex-col max-w-sm', +]) ?> @@ -43,8 +45,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/user/edit.php b/themes/cp_admin/user/edit.php index 0db5f0e4..b5cb7fe1 100644 --- a/themes/cp_admin/user/edit.php +++ b/themes/cp_admin/user/edit.php @@ -1,11 +1,15 @@ extend('_layout') ?> section('title') ?> - $user->username]) ?> + $user->username, +]) ?> endSection() ?> section('pageTitle') ?> - $user->username]) ?> + $user->username, +]) ?> endSection() ?> @@ -22,8 +26,13 @@ 'primary'], - ['type' => 'submit', 'class' => 'self-end'], + [ + 'variant' => 'primary', + ], + [ + 'type' => 'submit', + 'class' => 'self-end', + ], ) ?> diff --git a/themes/cp_admin/user/list.php b/themes/cp_admin/user/list.php index 3ae8e41c..c5895513 100644 --- a/themes/cp_admin/user/list.php +++ b/themes/cp_admin/user/list.php @@ -40,8 +40,12 @@ 'username' => $user->username, ]), route_to('user-edit', $user->id), - ['variant' => 'info'], - ['class' => 'ml-2'], + [ + 'variant' => 'info', + ], + [ + 'class' => 'ml-2', + ], ); }, ], @@ -63,7 +67,9 @@ 'variant' => 'secondary', 'size' => 'small', ], - ['class' => 'mr-2'], + [ + 'class' => 'mr-2', + ], ) . button( lang('User.' . ($user->isBanned() ? 'unban' : 'ban')), @@ -71,13 +77,21 @@ $user->isBanned() ? 'user-unban' : 'user-ban', $user->id, ), - ['variant' => 'warning', 'size' => 'small'], - ['class' => 'mr-2'], + [ + 'variant' => 'warning', + 'size' => 'small', + ], + [ + 'class' => 'mr-2', + ], ) . button( lang('User.delete'), route_to('user-delete', $user->id), - ['variant' => 'danger', 'size' => 'small'], + [ + 'variant' => 'danger', + 'size' => 'small', + ], ); }, ], diff --git a/themes/cp_admin/user/view.php b/themes/cp_admin/user/view.php index 020bd587..402fe327 100644 --- a/themes/cp_admin/user/view.php +++ b/themes/cp_admin/user/view.php @@ -1,12 +1,16 @@ extend('_layout') ?> section('title') ?> - $user->username]) ?> + $user->username, +]) ?> endSection() ?> section('content') ?> - $user]) ?> + $user, +]) ?> endSection() ?> diff --git a/themes/cp_app/_layout.php b/themes/cp_app/_layout.php index 5782c039..12839a5b 100644 --- a/themes/cp_app/_layout.php +++ b/themes/cp_app/_layout.php @@ -1,6 +1,7 @@ - + @@ -9,8 +10,10 @@ - asset('styles/index.css', 'css') ?> - asset('js/audio-player.ts', 'js') ?> + asset('styles/index.css', 'css') ?> + asset('js/audio-player.ts', 'js') ?> diff --git a/themes/cp_app/embeddable_player.php b/themes/cp_app/embeddable_player.php index 3d287363..755b5960 100644 --- a/themes/cp_app/embeddable_player.php +++ b/themes/cp_app/embeddable_player.php @@ -1,5 +1,6 @@ - + @@ -9,31 +10,33 @@ ) ?>" /> - asset('styles/index.css', 'css') ?> - asset('js/embed.ts', 'js') ?> + asset('styles/index.css', 'css') ?> + asset('js/embed.ts', 'js') ?> <?= $episode->title ?> + ->thumbnail_url ?>" alt="title ?>" class="flex-shrink w-36 h-36" />
    @@ -44,11 +47,11 @@ title ?> number, - $episode->season_number, - 'text-xs', - true, - ) ?> + $episode->number, + $episode->season_number, + 'text-xs', + true, +) ?> - + @@ -8,22 +9,23 @@ - asset('styles/index.css', 'css') ?> + asset('styles/index.css', 'css') ?>

    ()

    + $podcasts, + ) ?>)
    diff --git a/themes/cp_app/page.php b/themes/cp_app/page.php index 98317ebe..60143b2e 100644 --- a/themes/cp_app/page.php +++ b/themes/cp_app/page.php @@ -1,13 +1,15 @@ - + <?= $page->title ?> - asset('styles/index.css', 'css') ?> + asset('styles/index.css', 'css') ?> @@ -15,9 +17,9 @@
    + 'arrow-left', + 'mr-2', + ) . lang('Page.back_to_home') ?>

    title ?>

    diff --git a/themes/cp_app/podcast/_layout.php b/themes/cp_app/podcast/_layout.php index f6480bab..a37e77b4 100644 --- a/themes/cp_app/podcast/_layout.php +++ b/themes/cp_app/podcast/_layout.php @@ -1,7 +1,8 @@ - + @@ -13,9 +14,12 @@ - asset('styles/index.css', 'css') ?> - asset('js/podcast.ts', 'js') ?> - asset('js/audio-player.ts', 'js') ?> + asset('styles/index.css', 'css') ?> + asset('js/podcast.ts', 'js') ?> + asset('js/audio-player.ts', 'js') ?> @@ -28,32 +32,32 @@ data-toggle-class="sticky -translate-x-full" class="flex-shrink-0 mr-3 overflow-hidden rounded-full focus:ring-2 focus:outline-none focus:ring-pine-50"> <?= $podcast->title ?> + ->thumbnail_url ?>" alt="title ?>" class="h-10"/>

    title ?> @handle ?>

    handle), - icon( - 'social/castopod', - 'mr-2 text-xl text-pink-200 group-hover:text-pink-50', - ) . lang('Podcast.follow'), - [ - 'width' => 420, - 'height' => 620, - 'class' => - 'group inline-flex mr-2 items-center px-3 py-1 text-xs tracking-wider font-semibold text-white uppercase rounded-full shadow focus:outline-none focus:ring bg-rose-600', - ], - ) ?> + route_to('follow', $podcast->handle), + icon( + 'social/castopod', + 'mr-2 text-xl text-pink-200 group-hover:text-pink-50', + ) . lang('Podcast.follow'), + [ + 'width' => 420, + 'height' => 620, + 'class' => + 'group inline-flex mr-2 items-center px-3 py-1 text-xs tracking-wider font-semibold text-white uppercase rounded-full shadow focus:outline-none focus:ring bg-rose-600', + ], + ) ?> + 'menu', + ) ?> renderSection('content') ?> @@ -65,10 +69,10 @@ data-toggle-class="translate-x-full" data-toggle-body-class="-ml-64" class="fixed z-40 hidden p-4 text-xl rounded-full shadow-2xl sm:block lg:hidden bottom-4 left-4 bg-pine-800 focus:outline-none focus:ring-2 focus:ring-pine-600 text-pine-200 hover:text-pine-50"> + 'menu', + ) ?>