2026-01-15 01:13:44 +00:00
|
|
|
<script setup lang="ts">
|
|
|
|
|
import { usePage } from '@inertiajs/vue3';
|
2026-07-18 17:34:15 +00:00
|
|
|
import { IconChevronRight, IconSelector } from '@tabler/icons-vue';
|
2026-03-30 02:01:08 +00:00
|
|
|
import { computed } from 'vue';
|
2026-01-15 01:13:44 +00:00
|
|
|
|
2026-03-31 13:26:44 +00:00
|
|
|
import NotificationBell from '@/components/NotificationBell.vue';
|
2026-01-15 01:13:44 +00:00
|
|
|
import {
|
|
|
|
|
DropdownMenu,
|
|
|
|
|
DropdownMenuContent,
|
|
|
|
|
DropdownMenuTrigger,
|
|
|
|
|
} from '@/components/ui/dropdown-menu';
|
|
|
|
|
import {
|
|
|
|
|
SidebarMenu,
|
|
|
|
|
SidebarMenuButton,
|
|
|
|
|
SidebarMenuItem,
|
|
|
|
|
useSidebar,
|
|
|
|
|
} from '@/components/ui/sidebar';
|
|
|
|
|
import UserInfo from '@/components/UserInfo.vue';
|
|
|
|
|
|
|
|
|
|
import UserMenuContent from './UserMenuContent.vue';
|
|
|
|
|
|
|
|
|
|
const page = usePage();
|
2026-03-30 02:01:08 +00:00
|
|
|
const user = computed(() => page.props.auth.user);
|
2026-03-31 00:18:07 +00:00
|
|
|
const currentWorkspace = computed(() => page.props.auth.currentWorkspace);
|
refactor: in-page page headers, indies tabs, and post details polish
- Replace global AppHeader slots with in-page headers on Calendar, Edit,
and Show pages — full-width canvas with the page-specific controls
living in their own ink-bordered bar.
- Remove sidebar collapse mechanism: drop Cmd+B keyboard shortcut, force
defaultOpen=true (ignore persisted cookie), make toggleSidebar a no-op
on desktop. Sidebar is permanent on desktop, sheet behavior preserved
on mobile.
- Redesign Tabs to match the design system: each TabsTrigger renders as
a standalone sticker button (border-2 + rounded-md + shadow-xs), with
amber-200 active state mirroring the "POST" badge from post-templates.
- Show page layout: cap preview Card to max-w-xl, preserve natural
aspect for single-image posts (object-contain, max-h-[480px]), drop
redundant stats grid, swap header sides (Back button left, status +
date right with date first).
- Assets: bump GalleryBrowser search inputs to h-12 for comfortable
browsing across uploads, Unsplash, and Giphy tabs.
- Fix PostPlatformMetrics loading-forever bug: hoist useHttp out of the
onMounted callback into setup, and read the response array directly
(backend returns the array at root, not under .data).
- i18n: rename posts.show.back_to_posts → posts.show.back; remove unused
posts.show.summary.* keys.
2026-05-06 19:22:55 +00:00
|
|
|
const { isMobile } = useSidebar();
|
2026-01-15 01:13:44 +00:00
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<template>
|
|
|
|
|
<SidebarMenu>
|
|
|
|
|
<SidebarMenuItem>
|
2026-03-31 00:18:07 +00:00
|
|
|
<div class="flex items-center gap-1">
|
refactor: in-page page headers, indies tabs, and post details polish
- Replace global AppHeader slots with in-page headers on Calendar, Edit,
and Show pages — full-width canvas with the page-specific controls
living in their own ink-bordered bar.
- Remove sidebar collapse mechanism: drop Cmd+B keyboard shortcut, force
defaultOpen=true (ignore persisted cookie), make toggleSidebar a no-op
on desktop. Sidebar is permanent on desktop, sheet behavior preserved
on mobile.
- Redesign Tabs to match the design system: each TabsTrigger renders as
a standalone sticker button (border-2 + rounded-md + shadow-xs), with
amber-200 active state mirroring the "POST" badge from post-templates.
- Show page layout: cap preview Card to max-w-xl, preserve natural
aspect for single-image posts (object-contain, max-h-[480px]), drop
redundant stats grid, swap header sides (Back button left, status +
date right with date first).
- Assets: bump GalleryBrowser search inputs to h-12 for comfortable
browsing across uploads, Unsplash, and Giphy tabs.
- Fix PostPlatformMetrics loading-forever bug: hoist useHttp out of the
onMounted callback into setup, and read the response array directly
(backend returns the array at root, not under .data).
- i18n: rename posts.show.back_to_posts → posts.show.back; remove unused
posts.show.summary.* keys.
2026-05-06 19:22:55 +00:00
|
|
|
<NotificationBell v-if="currentWorkspace" />
|
2026-01-15 01:13:44 +00:00
|
|
|
<DropdownMenu>
|
|
|
|
|
<DropdownMenuTrigger as-child>
|
|
|
|
|
<SidebarMenuButton
|
|
|
|
|
size="lg"
|
|
|
|
|
class="data-[state=open]:bg-sidebar-accent data-[state=open]:text-sidebar-accent-foreground"
|
|
|
|
|
data-test="sidebar-menu-button"
|
|
|
|
|
>
|
|
|
|
|
<UserInfo :user="user" />
|
2026-07-18 17:34:15 +00:00
|
|
|
<component :is="isMobile ? IconSelector : IconChevronRight" class="ml-auto size-4" />
|
2026-01-15 01:13:44 +00:00
|
|
|
</SidebarMenuButton>
|
|
|
|
|
</DropdownMenuTrigger>
|
|
|
|
|
<DropdownMenuContent
|
2026-05-06 17:26:18 +00:00
|
|
|
class="w-(--reka-dropdown-menu-trigger-width) min-w-56"
|
2026-03-30 00:37:11 +00:00
|
|
|
:side="isMobile ? 'bottom' : 'right'"
|
2026-01-15 01:13:44 +00:00
|
|
|
align="end"
|
|
|
|
|
:side-offset="4"
|
|
|
|
|
>
|
|
|
|
|
<UserMenuContent :user="user" />
|
|
|
|
|
</DropdownMenuContent>
|
|
|
|
|
</DropdownMenu>
|
2026-03-31 00:18:07 +00:00
|
|
|
</div>
|
2026-01-15 01:13:44 +00:00
|
|
|
</SidebarMenuItem>
|
|
|
|
|
</SidebarMenu>
|
|
|
|
|
</template>
|