2020-10-02 15:38:16 +00:00
|
|
|
<?php
|
|
|
|
$podcastNavigation = [
|
|
|
|
'dashboard' => [
|
|
|
|
'icon' => 'dashboard',
|
|
|
|
'items' => ['podcast-view', 'podcast-edit'],
|
|
|
|
],
|
|
|
|
'episodes' => [
|
|
|
|
'icon' => 'mic',
|
|
|
|
'items' => ['episode-list', 'episode-create'],
|
|
|
|
],
|
2021-02-10 16:20:01 +00:00
|
|
|
'persons' => [
|
|
|
|
'icon' => 'folder-user',
|
|
|
|
'items' => ['podcast-person-manage'],
|
|
|
|
],
|
2020-10-02 15:38:16 +00:00
|
|
|
'analytics' => [
|
|
|
|
'icon' => 'line-chart',
|
2020-10-14 10:38:48 +00:00
|
|
|
'items' => [
|
|
|
|
'podcast-analytics',
|
|
|
|
'podcast-analytics-unique-listeners',
|
2020-10-19 10:33:23 +00:00
|
|
|
'podcast-analytics-listening-time',
|
2020-10-14 10:38:48 +00:00
|
|
|
'podcast-analytics-players',
|
|
|
|
'podcast-analytics-locations',
|
2020-11-02 18:15:19 +00:00
|
|
|
'podcast-analytics-time-periods',
|
2020-10-14 10:38:48 +00:00
|
|
|
'podcast-analytics-webpages',
|
|
|
|
],
|
2020-10-02 15:38:16 +00:00
|
|
|
],
|
|
|
|
'contributors' => [
|
|
|
|
'icon' => 'group',
|
|
|
|
'items' => ['contributor-list', 'contributor-add'],
|
|
|
|
],
|
2020-11-18 17:17:56 +00:00
|
|
|
'platforms' => [
|
2021-04-02 17:20:02 +00:00
|
|
|
'icon' => 'link',
|
2020-11-18 17:17:56 +00:00
|
|
|
'items' => [
|
|
|
|
'platforms-podcasting',
|
|
|
|
'platforms-social',
|
|
|
|
'platforms-funding',
|
|
|
|
],
|
2020-10-02 15:38:16 +00:00
|
|
|
],
|
|
|
|
]; ?>
|
|
|
|
|
|
|
|
<a href="<?= route_to(
|
2021-04-02 17:20:02 +00:00
|
|
|
'admin',
|
2020-10-02 15:38:16 +00:00
|
|
|
) ?>" class="inline-flex items-center px-4 py-2 border-b">
|
2021-04-02 17:20:02 +00:00
|
|
|
<?= icon('arrow-left', 'mr-4 text-xl') ?>
|
|
|
|
<span class="inline-flex items-baseline text-2xl font-semibold font-display text-pine-700"> <?= 'castopod' .
|
|
|
|
svg('castopod-logo', 'h-5 ml-1') ?></span>
|
|
|
|
|
2020-10-02 15:38:16 +00:00
|
|
|
</a>
|
|
|
|
<div class="flex items-center border-b">
|
|
|
|
<img
|
|
|
|
src="<?= $podcast->image->thumbnail_url ?>"
|
|
|
|
alt="<?= $podcast->title ?>"
|
2020-10-14 16:03:42 +00:00
|
|
|
class="object-cover w-16 h-16"
|
2020-10-02 15:38:16 +00:00
|
|
|
/>
|
2020-10-14 16:03:42 +00:00
|
|
|
<div class="flex flex-col items-start flex-1 w-48 px-2">
|
|
|
|
<span class="w-40 text-sm font-semibold truncate" title="<?= $podcast->title ?>"><?= $podcast->title ?></span>
|
2020-10-02 15:38:16 +00:00
|
|
|
<a href="<?= route_to(
|
2021-04-02 17:20:02 +00:00
|
|
|
'podcast-activity',
|
|
|
|
$podcast->name,
|
|
|
|
) ?>" class="inline-flex items-center text-xs underline outline-none hover:no-underline focus:ring"
|
2020-10-02 15:38:16 +00:00
|
|
|
data-toggle="tooltip" data-placement="bottom" title="<?= lang(
|
2021-04-02 17:20:02 +00:00
|
|
|
'PodcastNavigation.go_to_page',
|
2020-10-02 15:38:16 +00:00
|
|
|
) ?>">@<?= $podcast->name ?>
|
|
|
|
<?= icon('external-link', 'ml-1 text-gray-500') ?>
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<nav class="flex flex-col flex-1 py-6 overflow-y-auto">
|
|
|
|
<?php foreach ($podcastNavigation as $section => $data): ?>
|
|
|
|
<div class="mb-4">
|
2021-04-02 17:20:02 +00:00
|
|
|
<button class="inline-flex items-center w-full px-6 py-1 outline-none focus:ring" type="button">
|
|
|
|
<?= icon($data['icon'], 'text-gray-400 text-xl mr-3') .
|
|
|
|
lang('PodcastNavigation.' . $section) ?>
|
2020-10-02 15:38:16 +00:00
|
|
|
</button>
|
2021-04-02 17:20:02 +00:00
|
|
|
<ul class="flex flex-col">
|
2020-10-02 15:38:16 +00:00
|
|
|
<?php foreach ($data['items'] as $item): ?>
|
2021-04-02 17:20:02 +00:00
|
|
|
<?php $isActive = url_is(route_to($item, $podcast->id)); ?>
|
|
|
|
<li class="inline-flex">
|
|
|
|
<a class="w-full py-1 pl-14 pr-2 text-sm text-gray-600 outline-none hover:text-gray-900 focus:ring <?= $isActive
|
2020-10-02 15:38:16 +00:00
|
|
|
? 'font-semibold text-gray-900'
|
|
|
|
: '' ?>" href="<?= route_to(
|
|
|
|
$item,
|
2021-04-02 17:20:02 +00:00
|
|
|
$podcast->id,
|
2020-10-02 15:38:16 +00:00
|
|
|
) ?>"><?= lang('PodcastNavigation.' . $item) ?></a>
|
|
|
|
</li>
|
|
|
|
<?php endforeach; ?>
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
<?php endforeach; ?>
|
|
|
|
</nav>
|
2021-04-02 17:20:02 +00:00
|
|
|
<button
|
|
|
|
type="button"
|
|
|
|
class="inline-flex items-center w-full px-6 py-2 mt-auto border-t outline-none focus:ring"
|
|
|
|
id="my-account-dropdown"
|
|
|
|
data-dropdown="button"
|
|
|
|
data-dropdown-target="my-account-dropdown-menu"
|
|
|
|
aria-haspopup="true"
|
|
|
|
aria-expanded="false">
|
2020-10-02 15:38:16 +00:00
|
|
|
<?= icon('user', 'text-gray-500 mr-2') ?>
|
|
|
|
<?= user()->username ?>
|
|
|
|
<?= icon('caret-right', 'ml-auto') ?>
|
|
|
|
</button>
|
2021-04-02 17:20:02 +00:00
|
|
|
<nav
|
|
|
|
id="my-account-dropdown-menu"
|
|
|
|
class="flex flex-col py-2 text-black whitespace-no-wrap bg-white border rounded shadow"
|
|
|
|
aria-labelledby="my-account-dropdown"
|
|
|
|
data-dropdown="menu"
|
|
|
|
data-dropdown-placement="right-end">
|
2020-10-02 15:38:16 +00:00
|
|
|
<a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to(
|
2021-04-02 17:20:02 +00:00
|
|
|
'my-account',
|
2020-10-13 16:16:45 +00:00
|
|
|
) ?>"><?= lang('AdminNavigation.account.my-account') ?></a>
|
2020-10-02 15:38:16 +00:00
|
|
|
<a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to(
|
2021-04-02 17:20:02 +00:00
|
|
|
'change-password',
|
2020-10-13 16:16:45 +00:00
|
|
|
) ?>"><?= lang('AdminNavigation.account.change-password') ?></a>
|
2020-10-02 15:38:16 +00:00
|
|
|
<a class="px-4 py-1 hover:bg-gray-100" href="<?= route_to(
|
2021-04-02 17:20:02 +00:00
|
|
|
'logout',
|
2020-10-13 16:16:45 +00:00
|
|
|
) ?>"><?= lang('AdminNavigation.account.logout') ?></a>
|
2020-10-02 15:38:16 +00:00
|
|
|
</nav>
|
|
|
|
</div>
|