@medalsocial/meda 2.7.2 → 2.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (164) hide show
  1. package/README.md +65 -1
  2. package/dist/auth/auth-message.d.ts +3 -3
  3. package/dist/auth/auth-provider-button.d.ts +1 -1
  4. package/dist/auth/auth-provider-list.d.ts +1 -1
  5. package/dist/auth/better-auth.d.ts +3 -3
  6. package/dist/brand/medal-social-mark.d.ts +1 -1
  7. package/dist/calendar/calendar-toolbar.d.ts +1 -1
  8. package/dist/calendar/calendar.d.ts +1 -1
  9. package/dist/calendar/day-view.d.ts +1 -1
  10. package/dist/calendar/internal/day-cell.d.ts +1 -1
  11. package/dist/calendar/internal/event-pill.d.ts +1 -1
  12. package/dist/calendar/internal/time-slot.d.ts +1 -1
  13. package/dist/calendar/month-view.d.ts +1 -1
  14. package/dist/calendar/week-view.d.ts +1 -1
  15. package/dist/chat/latency-badge.d.ts +1 -1
  16. package/dist/chat/latency-breakdown.d.ts +1 -1
  17. package/dist/chat/tool-call-block.d.ts +1 -1
  18. package/dist/chat/transcript-stream.d.ts +1 -1
  19. package/dist/chat/turn-card.d.ts +1 -1
  20. package/dist/components/ui/checkbox.d.ts +1 -1
  21. package/dist/components/ui/collapsible.d.ts +3 -3
  22. package/dist/components/ui/command.d.ts +9 -9
  23. package/dist/components/ui/dialog.d.ts +10 -10
  24. package/dist/components/ui/drawer.d.ts +10 -10
  25. package/dist/components/ui/dropdown-menu.d.ts +15 -15
  26. package/dist/components/ui/tooltip.d.ts +4 -4
  27. package/dist/email-builder/block-palette.d.ts +1 -1
  28. package/dist/email-builder/block-renderer.d.ts +1 -1
  29. package/dist/email-builder/block-renderers/button.d.ts +1 -1
  30. package/dist/email-builder/block-renderers/columns.d.ts +1 -1
  31. package/dist/email-builder/block-renderers/divider.d.ts +1 -1
  32. package/dist/email-builder/block-renderers/footer.d.ts +1 -1
  33. package/dist/email-builder/block-renderers/heading.d.ts +1 -1
  34. package/dist/email-builder/block-renderers/image.d.ts +1 -1
  35. package/dist/email-builder/block-renderers/social.d.ts +1 -1
  36. package/dist/email-builder/block-renderers/spacer.d.ts +1 -1
  37. package/dist/email-builder/block-renderers/text.d.ts +1 -1
  38. package/dist/email-builder/builder-canvas.d.ts +1 -1
  39. package/dist/email-builder/builder-header.d.ts +1 -1
  40. package/dist/email-builder/builder-left-tabs.d.ts +1 -1
  41. package/dist/email-builder/email-builder.d.ts +1 -1
  42. package/dist/email-builder/envelope-card.d.ts +1 -1
  43. package/dist/email-builder/floating-bar.d.ts +1 -1
  44. package/dist/email-builder/internal/dnd-wrapper.d.ts +1 -1
  45. package/dist/email-builder/mobile-drawers.d.ts +1 -1
  46. package/dist/email-builder/mobile-tab-bar.d.ts +1 -1
  47. package/dist/email-builder/property-editors/_shared.d.ts +8 -8
  48. package/dist/email-builder/property-editors/button-editor.d.ts +1 -1
  49. package/dist/email-builder/property-editors/columns-editor.d.ts +1 -1
  50. package/dist/email-builder/property-editors/divider-editor.d.ts +1 -1
  51. package/dist/email-builder/property-editors/footer-editor.d.ts +1 -1
  52. package/dist/email-builder/property-editors/heading-editor.d.ts +1 -1
  53. package/dist/email-builder/property-editors/image-editor.d.ts +1 -1
  54. package/dist/email-builder/property-editors/social-editor.d.ts +1 -1
  55. package/dist/email-builder/property-editors/spacer-editor.d.ts +1 -1
  56. package/dist/email-builder/property-editors/text-editor.d.ts +1 -1
  57. package/dist/email-builder/property-inspector.d.ts +1 -1
  58. package/dist/email-builder/view-controls.d.ts +1 -1
  59. package/dist/kanban/kanban-board.d.ts +1 -1
  60. package/dist/kanban/kanban-card-wrapper.d.ts +1 -1
  61. package/dist/kanban/kanban-column.d.ts +1 -1
  62. package/dist/list/list-row.d.ts +2 -2
  63. package/dist/marketing/marketing-announcement-bar.d.ts +1 -1
  64. package/dist/marketing/marketing-bento-card.d.ts +1 -1
  65. package/dist/marketing/marketing-bento-grid.d.ts +1 -1
  66. package/dist/marketing/marketing-callout.d.ts +1 -1
  67. package/dist/marketing/marketing-contact.d.ts +1 -1
  68. package/dist/marketing/marketing-cta-list.d.ts +1 -1
  69. package/dist/marketing/marketing-cta.d.ts +1 -1
  70. package/dist/marketing/marketing-faq.d.ts +1 -1
  71. package/dist/marketing/marketing-footer.d.ts +1 -1
  72. package/dist/marketing/marketing-header-logo.d.ts +1 -1
  73. package/dist/marketing/marketing-header.d.ts +1 -1
  74. package/dist/marketing/marketing-hero.d.ts +1 -1
  75. package/dist/marketing/marketing-lead-magnet.d.ts +1 -1
  76. package/dist/marketing/marketing-mega-menu.d.ts +1 -1
  77. package/dist/marketing/marketing-nav-item.d.ts +1 -1
  78. package/dist/marketing/marketing-numbered-features.d.ts +1 -1
  79. package/dist/marketing/marketing-shell.d.ts +1 -1
  80. package/dist/marketing/marketing-trust-bar.d.ts +1 -1
  81. package/dist/panel/inspector-field.d.ts +1 -1
  82. package/dist/panel/inspector-json.d.ts +1 -1
  83. package/dist/panel/inspector.d.ts +1 -1
  84. package/dist/post-preview/internal/avatar.d.ts +1 -1
  85. package/dist/post-preview/platforms/bluesky.d.ts +1 -1
  86. package/dist/post-preview/platforms/discord.d.ts +1 -1
  87. package/dist/post-preview/platforms/facebook.d.ts +1 -1
  88. package/dist/post-preview/platforms/generic.d.ts +1 -1
  89. package/dist/post-preview/platforms/google-business.d.ts +1 -1
  90. package/dist/post-preview/platforms/instagram.d.ts +1 -1
  91. package/dist/post-preview/platforms/linkedin.d.ts +1 -1
  92. package/dist/post-preview/platforms/telegram.d.ts +1 -1
  93. package/dist/post-preview/platforms/threads.d.ts +1 -1
  94. package/dist/post-preview/platforms/tiktok.d.ts +1 -1
  95. package/dist/post-preview/platforms/twitter.d.ts +1 -1
  96. package/dist/post-preview/platforms/youtube.d.ts +1 -1
  97. package/dist/primitives/card.d.ts +4 -4
  98. package/dist/primitives/empty-state.d.ts +1 -1
  99. package/dist/primitives/filter-rail.d.ts +2 -2
  100. package/dist/primitives/markdown-view.d.ts +1 -1
  101. package/dist/primitives/skeleton.d.ts +1 -1
  102. package/dist/primitives/status-pill.d.ts +1 -1
  103. package/dist/shell/app-shell-auth.d.ts +1 -1
  104. package/dist/shell/app-shell-chat.d.ts +1 -1
  105. package/dist/shell/app-shell-workspace.d.ts +8 -2
  106. package/dist/shell/app-shell-workspace.js +7 -3
  107. package/dist/shell/app-shell.d.ts +14 -4
  108. package/dist/shell/app-shell.js +1 -1
  109. package/dist/shell/command-palette.d.ts +1 -1
  110. package/dist/shell/context-rail.d.ts +1 -1
  111. package/dist/shell/drag-mode-banner.d.ts +1 -1
  112. package/dist/shell/extras/shell-desktop-panel-dock.d.ts +1 -1
  113. package/dist/shell/extras/shell-scrollable-content.d.ts +1 -1
  114. package/dist/shell/extras/shell-tab-bar.d.ts +1 -1
  115. package/dist/shell/extras/workbench-layout.d.ts +1 -1
  116. package/dist/shell/icon-rail.d.ts +2 -2
  117. package/dist/shell/index.d.ts +2 -2
  118. package/dist/shell/internal/mobile-bottom-nav.d.ts +1 -1
  119. package/dist/shell/internal/mobile-dock.d.ts +7 -1
  120. package/dist/shell/internal/mobile-dock.js +26 -11
  121. package/dist/shell/internal/mobile-drawers.d.ts +1 -1
  122. package/dist/shell/internal/mobile-header.d.ts +1 -1
  123. package/dist/shell/internal/mobile-workspace-sheet.d.ts +15 -1
  124. package/dist/shell/internal/mobile-workspace-sheet.js +70 -3
  125. package/dist/shell/panel-views-provider.d.ts +1 -1
  126. package/dist/shell/rail-drop-slot.d.ts +1 -1
  127. package/dist/shell/rail-drop-zones.d.ts +1 -1
  128. package/dist/shell/resizable-shell.d.ts +3 -3
  129. package/dist/shell/right-panel.d.ts +1 -1
  130. package/dist/shell/shell-header.d.ts +43 -6
  131. package/dist/shell/shell-header.js +29 -5
  132. package/dist/shell/shell-main.d.ts +1 -1
  133. package/dist/shell/shell-provider.d.ts +1 -1
  134. package/dist/shell/theme-next-themes.d.ts +1 -1
  135. package/dist/shell/theme.d.ts +2 -2
  136. package/dist/shell/types.d.ts +38 -0
  137. package/dist/shell/use-shell-viewport.js +3 -1
  138. package/dist/timeline/date-switcher.d.ts +1 -1
  139. package/dist/timeline/event-card.d.ts +1 -1
  140. package/dist/timeline/lane-timeline.d.ts +1 -1
  141. package/dist/timeline/lane.d.ts +1 -1
  142. package/dist/timeline/live-indicator.d.ts +1 -1
  143. package/dist/timeline/scrub-bar.d.ts +1 -1
  144. package/dist/timeline/time-axis.d.ts +1 -1
  145. package/dist/timeline/timeline-rail.d.ts +1 -1
  146. package/dist/timeline/timeline-tape.d.ts +1 -1
  147. package/dist/voice/voice-level.d.ts +2 -1
  148. package/dist/voice/voice-orb-scene.d.ts +2 -1
  149. package/dist/voice/voice-status-pill.d.ts +1 -1
  150. package/dist/workflow-builder/edges/default-edge.d.ts +1 -1
  151. package/dist/workflow-builder/nodes/action-node.d.ts +1 -1
  152. package/dist/workflow-builder/nodes/base-node.d.ts +1 -1
  153. package/dist/workflow-builder/nodes/condition-node.d.ts +1 -1
  154. package/dist/workflow-builder/nodes/delay-node.d.ts +1 -1
  155. package/dist/workflow-builder/nodes/end-node.d.ts +1 -1
  156. package/dist/workflow-builder/nodes/trigger-node.d.ts +1 -1
  157. package/dist/workflow-builder/workflow-builder.d.ts +1 -1
  158. package/dist/workflow-builder/workflow-canvas.d.ts +1 -1
  159. package/dist/workflow-builder/workflow-card-compact.d.ts +1 -1
  160. package/dist/workflow-builder/workflow-card.d.ts +1 -1
  161. package/dist/workflow-builder/workflow-header.d.ts +1 -1
  162. package/dist/workflow-builder/workflow-toolbox.d.ts +1 -1
  163. package/package.json +42 -41
  164. package/skills/shell/SKILL.md +86 -1
@@ -1,5 +1,5 @@
1
1
  import type { ReactNode } from 'react';
2
- import type { AppShellAppTabsConfig, AppShellAuthBranding, AppShellAuthConfig, AppShellContextRailConfig, AppShellIconRailConfig, AppShellMobileNavConfig, AppShellRightPanelConfig, AppShellWorkspaceConfig, ShellMainLayout } from './types.js';
2
+ import type { AppShellAppTabsConfig, AppShellAuthBranding, AppShellAuthConfig, AppShellContextRailConfig, AppShellIconRailConfig, AppShellMobileNavConfig, AppShellRightPanelConfig, AppShellWorkspaceConfig, ShellHeaderLayout, ShellMainLayout } from './types.js';
3
3
  interface AppShellBaseProps {
4
4
  children: ReactNode;
5
5
  className?: string;
@@ -29,14 +29,24 @@ export type AppShellProps = AppShellBaseProps & ({
29
29
  globalActions?: ReactNode;
30
30
  /**
31
31
  * Optional center-region header content. Replaces the default
32
- * application tabs when provided.
32
+ * application tabs when provided. Ignored when
33
+ * `headerLayout="rail"` — that layout has no centre column.
33
34
  */
34
35
  headerCenter?: ReactNode;
35
36
  /**
36
37
  * Optional leading content rendered in the LEFT header region immediately
37
38
  * after the workspace switcher. On mobile, surfaced inside the menu drawer.
39
+ * Under `headerLayout="rail"` it owns the header's whole fill column.
38
40
  */
39
41
  headerLeading?: ReactNode;
42
+ /**
43
+ * Desktop header grid. `split` (the default) is the pre-2.8 layout,
44
+ * byte-for-byte unchanged. `rail` switches to
45
+ * `[rail column | fill | actions]`: the workspace switcher renders as a
46
+ * tile the width of the icon rail, and `headerLeading` gets every
47
+ * remaining pixel. See `ShellHeaderLayout`.
48
+ */
49
+ headerLayout?: ShellHeaderLayout;
40
50
  /**
41
51
  * Optional chrome-level content rendered below the header and above
42
52
  * the workspace rail row.
@@ -67,9 +77,9 @@ export type AppShellProps = AppShellBaseProps & ({
67
77
  variant: 'chat';
68
78
  globalActions?: ReactNode;
69
79
  });
70
- export declare function AppShell(props: AppShellProps): import("react/jsx-runtime").JSX.Element;
80
+ export declare function AppShell(props: AppShellProps): import("react").JSX.Element;
71
81
  export declare function AppShellBody({ children, className }: {
72
82
  children: ReactNode;
73
83
  className?: string;
74
- }): import("react/jsx-runtime").JSX.Element;
84
+ }): import("react").JSX.Element;
75
85
  export {};
@@ -16,7 +16,7 @@ export function AppShell(props) {
16
16
  case 'auth':
17
17
  return wrapper(_jsx(AppShellAuth, { ...resolveAuthConfig(props), children: props.children }));
18
18
  case 'workspace':
19
- return wrapper(_jsx(AppShellWorkspace, { iconRail: props.iconRail, contextRail: props.contextRail, rightPanel: props.rightPanel, workspace: props.workspace, appTabs: props.appTabs, globalActions: props.globalActions, headerCenter: props.headerCenter, headerLeading: props.headerLeading, banners: props.banners, mainLayout: props.mainLayout, mainClassName: props.mainClassName, builtInCommandPalette: props.builtInCommandPalette, mobileNav: props.mobileNav, children: props.children }));
19
+ return wrapper(_jsx(AppShellWorkspace, { iconRail: props.iconRail, contextRail: props.contextRail, rightPanel: props.rightPanel, workspace: props.workspace, appTabs: props.appTabs, globalActions: props.globalActions, headerCenter: props.headerCenter, headerLeading: props.headerLeading, headerLayout: props.headerLayout, banners: props.banners, mainLayout: props.mainLayout, mainClassName: props.mainClassName, builtInCommandPalette: props.builtInCommandPalette, mobileNav: props.mobileNav, children: props.children }));
20
20
  case 'chat':
21
21
  return wrapper(_jsx(AppShellChat, { globalActions: props.globalActions, children: props.children }));
22
22
  }
@@ -17,7 +17,7 @@ export declare function matchesHotkey(e: KeyboardEvent, spec: string): boolean;
17
17
  export interface CommandPaletteProps {
18
18
  children?: ReactNode;
19
19
  }
20
- export declare function CommandPalette({ children }: CommandPaletteProps): import("react/jsx-runtime").JSX.Element;
20
+ export declare function CommandPalette({ children }: CommandPaletteProps): import("react").JSX.Element;
21
21
  export declare function useCommands(commands: CommandDefinition[]): void;
22
22
  export declare function useCommandGroup(group: CommandGroupDefinition): void;
23
23
  export {};
@@ -16,4 +16,4 @@ export interface ContextRailProps {
16
16
  scroll?: ContextRailScroll;
17
17
  className?: string;
18
18
  }
19
- export declare function ContextRail({ appId, module, hidden, collapsible, activeItemId, renderLink, header, scroll, className, }: ContextRailProps): import("react/jsx-runtime").JSX.Element | null;
19
+ export declare function ContextRail({ appId, module, hidden, collapsible, activeItemId, renderLink, header, scroll, className, }: ContextRailProps): import("react").JSX.Element | null;
@@ -25,7 +25,7 @@ export interface DragModeBannerProps {
25
25
  isActive?: (activeId: string | number) => boolean;
26
26
  className?: string;
27
27
  }
28
- export declare function DragModeBanner({ message, cancelKey, isActive, className }: DragModeBannerProps): import("react/jsx-runtime").JSX.Element | null;
28
+ export declare function DragModeBanner({ message, cancelKey, isActive, className }: DragModeBannerProps): import("react").JSX.Element | null;
29
29
  export declare namespace DragModeBanner {
30
30
  var displayName: string;
31
31
  }
@@ -11,4 +11,4 @@ export declare function ShellDesktopPanelDock({ defaultView, panelOpen, viewIds,
11
11
  className?: string;
12
12
  }) => React.ReactNode;
13
13
  className?: string;
14
- }): import("react/jsx-runtime").JSX.Element;
14
+ }): React.JSX.Element;
@@ -6,4 +6,4 @@ export interface ShellScrollableContentProps {
6
6
  layout: ShellContentLayout;
7
7
  maxWidth?: number;
8
8
  }
9
- export declare function ShellScrollableContent({ children, desktopDockOffset, layout, maxWidth, }: ShellScrollableContentProps): import("react/jsx-runtime").JSX.Element;
9
+ export declare function ShellScrollableContent({ children, desktopDockOffset, layout, maxWidth, }: ShellScrollableContentProps): import("react").JSX.Element;
@@ -14,5 +14,5 @@ export interface ShellTabBarProps {
14
14
  ariaLabel?: string;
15
15
  renderLink?: (args: ShellTabBarRenderArgs) => ReactNode;
16
16
  }
17
- export declare function ShellTabBar({ tabs, activeTab, onTabChange, className, ariaLabel, renderLink, }: ShellTabBarProps): import("react/jsx-runtime").JSX.Element | null;
17
+ export declare function ShellTabBar({ tabs, activeTab, onTabChange, className, ariaLabel, renderLink, }: ShellTabBarProps): import("react").JSX.Element | null;
18
18
  export {};
@@ -7,4 +7,4 @@ export interface WorkbenchLayoutProps {
7
7
  toolbar?: ReactNode;
8
8
  className?: string;
9
9
  }
10
- export declare function WorkbenchLayout({ viewportBand, main, aside, toolbar, className, }: WorkbenchLayoutProps): import("react/jsx-runtime").JSX.Element;
10
+ export declare function WorkbenchLayout({ viewportBand, main, aside, toolbar, className, }: WorkbenchLayoutProps): import("react").JSX.Element;
@@ -28,5 +28,5 @@ export interface RailDividerProps {
28
28
  pinnedBottom: boolean;
29
29
  onToggle: () => void;
30
30
  }
31
- export declare function RailDivider({ pinnedBottom, onToggle }: RailDividerProps): import("react/jsx-runtime").JSX.Element;
32
- export declare function IconRail({ mainItems, utilityItems, footer, activeId, renderLink, labelVisibility, className, }: IconRailProps): import("react/jsx-runtime").JSX.Element | null;
31
+ export declare function RailDivider({ pinnedBottom, onToggle }: RailDividerProps): import("react").JSX.Element;
32
+ export declare function IconRail({ mainItems, utilityItems, footer, activeId, renderLink, labelVisibility, className, }: IconRailProps): import("react").JSX.Element | null;
@@ -20,12 +20,12 @@ export type { RailDropZonesProps } from './rail-drop-zones.js';
20
20
  export { RailDropZones } from './rail-drop-zones.js';
21
21
  export { ResizableHandle, ResizableShell, ResizableShellPanel } from './resizable-shell.js';
22
22
  export { RightPanel } from './right-panel.js';
23
- export type { AppTabsProps, PanelToggleProps } from './shell-header.js';
23
+ export type { AppTabsProps, PanelToggleProps, ShellHeaderProps, WorkspaceSwitcherProps, WorkspaceSwitcherVariant, } from './shell-header.js';
24
24
  export { AppTabs, PanelToggle, ShellHeader, WorkspaceSwitcher } from './shell-header.js';
25
25
  export { ShellMain } from './shell-main.js';
26
26
  export type { MedaShellProviderProps } from './shell-provider.js';
27
27
  export { MedaShellProvider, useMedaShell, useShellSelection } from './shell-provider.js';
28
28
  export { DefaultThemeProvider, ThemeToggle, useTheme } from './theme.js';
29
29
  export { NextThemesAdapter } from './theme-next-themes.js';
30
- export type { AppDefinition, AppShellAppTabsConfig, AppShellAuthBranding, AppShellAuthConfig, AppShellContextRailConfig, AppShellIconRailConfig, AppShellMobileNavConfig, AppShellRightPanelConfig, AppShellVariant, AppShellWorkspaceConfig, AppTabRenderLinkArgs, CommandDefinition, ContextItem, ContextModule, ContextRailHeader, ContextRailScroll, MobileBottomNavItem, MobileDockItem, MobileNavGroup, MobileNavItem, MobileNavLinkArgs, MobileNavTree, MobileNavView, PanelMode, PanelView, ShellLinkRenderArgs, ShellMainLayout, ShellRenderContext, ShellViewport, ThemeAdapter, WorkspaceDefinition, WorkspaceMenuItem, } from './types.js';
30
+ export type { AppDefinition, AppShellAppTabsConfig, AppShellAuthBranding, AppShellAuthConfig, AppShellContextRailConfig, AppShellIconRailConfig, AppShellMobileNavConfig, AppShellRightPanelConfig, AppShellVariant, AppShellWorkspaceConfig, AppTabRenderLinkArgs, CommandDefinition, ContextItem, ContextModule, ContextRailHeader, ContextRailScroll, MobileBottomNavItem, MobileDockItem, MobileNavGroup, MobileNavItem, MobileNavLinkArgs, MobileNavTree, MobileNavView, PanelMode, PanelView, ShellHeaderLayout, ShellLinkRenderArgs, ShellMainLayout, ShellRenderContext, ShellViewport, ThemeAdapter, WorkspaceDefinition, WorkspaceMenuItem, } from './types.js';
31
31
  export { useShellViewport } from './use-shell-viewport.js';
@@ -20,4 +20,4 @@ export interface MobileBottomNavProps {
20
20
  *
21
21
  * Hidden on non-mobile viewports and when the right panel is in fullscreen mode.
22
22
  */
23
- export declare function MobileBottomNav({ items, className }: MobileBottomNavProps): import("react/jsx-runtime").JSX.Element | null;
23
+ export declare function MobileBottomNav({ items, className }: MobileBottomNavProps): import("react").JSX.Element | null;
@@ -5,6 +5,12 @@ export declare const WORKSPACE_SHEET_KEY = "workspace-sheet";
5
5
  export interface MobileDockProps {
6
6
  items: MobileDockItem[];
7
7
  activeTo?: string;
8
+ /**
9
+ * The active APP's id. When set, a slot is active iff `item.id === activeId`
10
+ * — so the dock stays lit everywhere inside that app, not only on the exact
11
+ * address in `activeTo`. Omit to keep the `to === activeTo` comparison.
12
+ */
13
+ activeId?: string;
8
14
  renderLink?: (args: MobileNavLinkArgs) => ReactNode;
9
15
  className?: string;
10
16
  /** `pill` (default) floating dock, or `bar` full-width labeled bottom bar. */
@@ -21,4 +27,4 @@ export interface MobileDockProps {
21
27
  *
22
28
  * Hidden on non-mobile viewports and when the right panel is fullscreen.
23
29
  */
24
- export declare function MobileDock({ items, activeTo, renderLink, className, variant, }: MobileDockProps): import("react/jsx-runtime").JSX.Element | null;
30
+ export declare function MobileDock({ items, activeTo, activeId, renderLink, className, variant, }: MobileDockProps): import("react").JSX.Element | null;
@@ -28,7 +28,7 @@ function renderIcon(icon, size) {
28
28
  *
29
29
  * Hidden on non-mobile viewports and when the right panel is fullscreen.
30
30
  */
31
- export function MobileDock({ items, activeTo, renderLink, className, variant = 'pill', }) {
31
+ export function MobileDock({ items, activeTo, activeId, renderLink, className, variant = 'pill', }) {
32
32
  const ctx = useMedaShell();
33
33
  const band = useShellViewport();
34
34
  if (band !== 'mobile')
@@ -37,6 +37,9 @@ export function MobileDock({ items, activeTo, renderLink, className, variant = '
37
37
  return null;
38
38
  if (items.length === 0)
39
39
  return null;
40
+ // `activeId` wins when supplied; otherwise fall back to the exact-address
41
+ // comparison the dock has always used.
42
+ const isItemActive = (item) => activeId != null ? item.id === activeId : Boolean(item.to && activeTo && item.to === activeTo);
40
43
  const runAction = (item) => {
41
44
  if (item.action === 'open-sheet')
42
45
  ctx.mobileDrawer.setOpen(WORKSPACE_SHEET_KEY);
@@ -49,14 +52,17 @@ export function MobileDock({ items, activeTo, renderLink, className, variant = '
49
52
  if (variant === 'bar') {
50
53
  const renderBarSlot = (item) => {
51
54
  const label = typeof item.label === 'function' ? item.label() : item.label;
52
- const isActive = Boolean(item.to && activeTo && item.to === activeTo);
55
+ const isActive = isItemActive(item);
53
56
  const isBrand = item.emphasis === 'brand';
54
- const iconEl = isBrand ? (_jsx("span", { className: "flex size-8 items-center justify-center rounded-full bg-[#5B2D8C] text-white", children: renderIcon(item.icon, 20) })) : (renderIcon(item.icon, 25));
57
+ const iconEl = isBrand ? (_jsx("span", { className: cn('flex size-8 items-center justify-center rounded-full bg-[var(--color-brand-600)] text-white', isActive && 'ring-2 ring-primary ring-offset-2 ring-offset-card'), children: renderIcon(item.icon, 20) })) : (renderIcon(item.icon, 25));
58
+ // Active wins over brand: a slot carrying `aria-current="page"` must
59
+ // have a visible treatment too. The label goes primary; the glyph in the
60
+ // disc stays white because the disc sets its own colour.
55
61
  let toneClass = 'text-muted-foreground hover:text-foreground';
56
- if (isBrand)
57
- toneClass = 'text-muted-foreground';
58
- else if (isActive)
62
+ if (isActive)
59
63
  toneClass = 'font-medium text-primary';
64
+ else if (isBrand)
65
+ toneClass = 'text-muted-foreground';
60
66
  const slotClass = cn('flex w-full flex-col items-center justify-center gap-1 py-2 text-[11px] leading-none transition-colors', toneClass);
61
67
  const children = (_jsxs(_Fragment, { children: [_jsxs("span", { className: "relative flex items-center justify-center", children: [iconEl, item.badge ? (_jsx("span", { className: "absolute -top-0.5 -right-1 size-2 rounded-full bg-primary ring-2 ring-card" })) : null] }), _jsx("span", { children: label })] }));
62
68
  if (item.to && !item.action) {
@@ -86,12 +92,18 @@ export function MobileDock({ items, activeTo, renderLink, className, variant = '
86
92
  const brandItems = items.filter((item) => item.emphasis === 'brand');
87
93
  const renderSlot = (item, size) => {
88
94
  const label = typeof item.label === 'function' ? item.label() : item.label;
89
- const isActive = Boolean(item.to && activeTo && item.to === activeTo);
95
+ const isActive = isItemActive(item);
90
96
  const icon = renderIcon(item.icon, size);
91
97
  const badge = item.badge ? (_jsx("span", { className: "absolute top-0 right-0 size-2 rounded-full bg-primary ring-2 ring-card" })) : null;
92
98
  // Route link
93
99
  if (item.to && !item.action) {
94
- const className = cn('relative flex items-center justify-center rounded-full p-1 transition-colors', isActive ? 'text-foreground' : 'text-muted-foreground hover:text-foreground');
100
+ const className = cn('relative flex items-center justify-center rounded-full p-1 transition-colors',
101
+ // A brand slot is rendered inside a filled brand disc that already
102
+ // sets `text-white`; a colour class here would override it and paint
103
+ // the glyph muted-grey on purple. Inherit instead, and let the disc
104
+ // itself carry the active ring (see the brandItems map below).
105
+ item.emphasis === 'brand' && 'text-inherit', item.emphasis !== 'brand' &&
106
+ (isActive ? 'text-foreground' : 'text-muted-foreground hover:text-foreground'));
95
107
  const children = (_jsxs(_Fragment, { children: [icon, badge] }));
96
108
  if (renderLink) {
97
109
  return renderLink({
@@ -110,8 +122,11 @@ export function MobileDock({ items, activeTo, renderLink, className, variant = '
110
122
  }
111
123
  return (_jsx("a", { href: item.to, className: className, "aria-label": label, "aria-current": isActive ? 'page' : undefined, children: children }));
112
124
  }
113
- // Action slot
114
- return (_jsxs("button", { type: "button", onClick: () => runAction(item), "aria-label": label, className: "relative flex items-center justify-center rounded-full p-1 text-muted-foreground transition-colors hover:text-foreground", children: [icon, badge] }));
125
+ // Action slot. Before `activeId` these never carried an active state, so
126
+ // the `activeTo` fallback deliberately does NOT light them only an
127
+ // explicit `activeId` match does.
128
+ const actionActive = activeId != null && item.id === activeId;
129
+ return (_jsxs("button", { type: "button", onClick: () => runAction(item), "aria-label": label, className: cn('relative flex items-center justify-center rounded-full p-1 transition-colors', actionActive ? 'text-foreground' : 'text-muted-foreground hover:text-foreground'), children: [icon, badge] }));
115
130
  };
116
- return (_jsxs("div", { "data-testid": "mobile-dock", className: cn('pointer-events-none absolute inset-x-0 bottom-0 z-30 flex items-center justify-center gap-2.5 pb-[calc(env(safe-area-inset-bottom)+12px)] pt-2', className), children: [_jsx("nav", { "aria-label": "Dock", className: "pointer-events-auto flex items-center gap-[18px] rounded-full border border-border bg-card px-4 py-2.5 shadow-[0_6px_20px_rgba(20,18,60,0.14)]", children: pillItems.map((item) => (_jsx("span", { className: "flex", children: renderSlot(item, 22) }, item.id))) }), brandItems.map((item) => (_jsx("span", { className: "pointer-events-auto flex size-11 items-center justify-center rounded-full bg-[#5B2D8C] text-white shadow-[0_6px_20px_rgba(91,45,140,0.35)]", children: renderSlot(item, 22) }, item.id)))] }));
131
+ return (_jsxs("div", { "data-testid": "mobile-dock", className: cn('pointer-events-none absolute inset-x-0 bottom-0 z-30 flex items-center justify-center gap-2.5 pb-[calc(env(safe-area-inset-bottom)+12px)] pt-2', className), children: [_jsx("nav", { "aria-label": "Dock", className: "pointer-events-auto flex items-center gap-[18px] rounded-full border border-border bg-card px-4 py-2.5 shadow-[0_6px_20px_rgba(20,18,60,0.14)]", children: pillItems.map((item) => (_jsx("span", { className: "flex", children: renderSlot(item, 22) }, item.id))) }), brandItems.map((item) => (_jsx("span", { className: cn('pointer-events-auto flex size-11 items-center justify-center rounded-full bg-[var(--color-brand-600)] text-white shadow-[0_6px_20px_rgba(91,45,140,0.35)]', isItemActive(item) && 'ring-2 ring-primary ring-offset-2 ring-offset-background'), children: renderSlot(item, 22) }, item.id)))] }));
117
132
  }
@@ -47,4 +47,4 @@ export interface MobileDrawersProps {
47
47
  * any custom-content drawers. Mount once near the AppShell root; drawers
48
48
  * open/close via `ctx.mobileDrawer.open` provider state.
49
49
  */
50
- export declare function MobileDrawers({ menuItems, menuActiveId, menuRenderLink, workspaceMenuItems, workspaceMenuFooter, module, moduleAppId, moduleActiveItemId, moduleRenderLink, moduleHeader, moduleScroll, sectionTabs, panelViews, defaultView, customContent, }: MobileDrawersProps): import("react/jsx-runtime").JSX.Element;
50
+ export declare function MobileDrawers({ menuItems, menuActiveId, menuRenderLink, workspaceMenuItems, workspaceMenuFooter, module, moduleAppId, moduleActiveItemId, moduleRenderLink, moduleHeader, moduleScroll, sectionTabs, panelViews, defaultView, customContent, }: MobileDrawersProps): import("react").JSX.Element;
@@ -22,4 +22,4 @@ export interface MobileHeaderProps {
22
22
  *
23
23
  * Renders nothing on non-mobile viewports.
24
24
  */
25
- export declare function MobileHeader({ parentLabel, parentTo: _parentTo, title, onBack, globalActions, headerCenter, className, }: MobileHeaderProps): import("react/jsx-runtime").JSX.Element | null;
25
+ export declare function MobileHeader({ parentLabel, parentTo: _parentTo, title, onBack, globalActions, headerCenter, className, }: MobileHeaderProps): import("react").JSX.Element | null;
@@ -3,6 +3,16 @@ import type { MobileNavLinkArgs, MobileNavTree, WorkspaceMenuItem } from '../typ
3
3
  export interface MobileWorkspaceSheetProps {
4
4
  tree: MobileNavTree;
5
5
  activeTo?: string;
6
+ /**
7
+ * The active APP's id — a row id in `tree`. When supplied it, not
8
+ * `activeTo`, decides which row the sheet opens on.
9
+ */
10
+ activeId?: string;
11
+ /**
12
+ * Render the current row first inside its group. Defaults to `false`, i.e.
13
+ * the tree's own order.
14
+ */
15
+ currentFirst?: boolean;
6
16
  renderLink?: (args: MobileNavLinkArgs) => ReactNode;
7
17
  workspaceMenuItems?: WorkspaceMenuItem[];
8
18
  workspaceMenuFooter?: ReactNode;
@@ -14,5 +24,9 @@ export interface MobileWorkspaceSheetProps {
14
24
  * preset views (accordion, one open at a time). Filters, layout, and saved
15
25
  * views deliberately stay on the page, not here. Opened from the dock's
16
26
  * workspace-selector slot; a workspace header on top surfaces the account menu.
27
+ *
28
+ * The sheet opens WHERE YOU ARE: the current row (see `activeId` / `activeTo`)
29
+ * is expanded and scrolled into view on every open, and the user can still
30
+ * collapse it.
17
31
  */
18
- export declare function MobileWorkspaceSheet({ tree, activeTo, renderLink, workspaceMenuItems, workspaceMenuFooter, }: MobileWorkspaceSheetProps): import("react/jsx-runtime").JSX.Element;
32
+ export declare function MobileWorkspaceSheet({ tree, activeTo, activeId, currentFirst, renderLink, workspaceMenuItems, workspaceMenuFooter, }: MobileWorkspaceSheetProps): import("react").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  'use client';
2
2
  import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
3
3
  import { ChevronDown, ChevronRight, ChevronUp, Monitor, Moon, Search, Sun, } from 'lucide-react';
4
- import { createElement, Fragment, isValidElement, useState } from 'react';
4
+ import { createElement, Fragment, isValidElement, useEffect, useRef, useState, } from 'react';
5
5
  import { Drawer, DrawerContent, DrawerDescription, DrawerHeader, DrawerTitle, } from '../../components/ui/drawer.js';
6
6
  import { cn } from '../../lib/utils.js';
7
7
  import { useMedaShell } from '../shell-provider.js';
@@ -18,6 +18,36 @@ function renderIcon(icon, size) {
18
18
  return null;
19
19
  }
20
20
  const rowClass = 'flex w-full items-center gap-3 rounded-[10px] px-2 py-2.5 text-left text-[13.5px] transition-colors hover:bg-accent';
21
+ /** Every row in the tree, groups first then footer rows, in render order. */
22
+ function allNavItems(tree) {
23
+ return [...tree.groups.flatMap((group) => group.items), ...(tree.footerItems ?? [])];
24
+ }
25
+ /**
26
+ * The row the user is currently "in".
27
+ *
28
+ * `activeId` is authoritative when supplied. Otherwise the row is derived from
29
+ * `activeTo`: an exact `to` match first, then the row that owns `activeTo`
30
+ * among its preset `views`.
31
+ */
32
+ function resolveCurrentItem(tree, activeId, activeTo) {
33
+ const items = allNavItems(tree);
34
+ if (activeId != null)
35
+ return items.find((item) => item.id === activeId) ?? null;
36
+ if (activeTo == null)
37
+ return null;
38
+ return (items.find((item) => item.to === activeTo) ??
39
+ items.find((item) => (item.views ?? []).some((view) => view.to === activeTo)) ??
40
+ null);
41
+ }
42
+ /** Move `currentId` to the front of `items` (used by `currentFirst`). */
43
+ function withCurrentFirst(items, currentId) {
44
+ if (currentId == null)
45
+ return items;
46
+ const index = items.findIndex((item) => item.id === currentId);
47
+ if (index <= 0)
48
+ return items;
49
+ return [items[index], ...items.slice(0, index), ...items.slice(index + 1)];
50
+ }
21
51
  /**
22
52
  * The one mobile workspace sheet — a calm, scannable list of the whole nav
23
53
  * tree that replaces the four drawers. Modules are light group labels,
@@ -25,13 +55,50 @@ const rowClass = 'flex w-full items-center gap-3 rounded-[10px] px-2 py-2.5 text
25
55
  * preset views (accordion, one open at a time). Filters, layout, and saved
26
56
  * views deliberately stay on the page, not here. Opened from the dock's
27
57
  * workspace-selector slot; a workspace header on top surfaces the account menu.
58
+ *
59
+ * The sheet opens WHERE YOU ARE: the current row (see `activeId` / `activeTo`)
60
+ * is expanded and scrolled into view on every open, and the user can still
61
+ * collapse it.
28
62
  */
29
- export function MobileWorkspaceSheet({ tree, activeTo, renderLink, workspaceMenuItems, workspaceMenuFooter, }) {
63
+ export function MobileWorkspaceSheet({ tree, activeTo, activeId, currentFirst = false, renderLink, workspaceMenuItems, workspaceMenuFooter, }) {
30
64
  const ctx = useMedaShell();
31
65
  const open = ctx.mobileDrawer.open === WORKSPACE_SHEET_KEY;
32
66
  const close = () => ctx.mobileDrawer.setOpen(null);
33
67
  const [expandedId, setExpandedId] = useState(null);
34
68
  const [accountOpen, setAccountOpen] = useState(false);
69
+ // Which row we have already scrolled to for the CURRENT open session, so a
70
+ // re-render does not keep yanking a sheet the user has scrolled by hand.
71
+ const scrolledToRef = useRef(null);
72
+ const currentItem = resolveCurrentItem(tree, activeId, activeTo);
73
+ const currentItemId = currentItem?.id ?? null;
74
+ const currentHasViews = (currentItem?.views ?? []).length > 0;
75
+ // Reset the accordion to the current row on every open. Primitive deps, so
76
+ // a re-render with the same current row does not fight a manual collapse.
77
+ useEffect(() => {
78
+ if (!open)
79
+ return;
80
+ setExpandedId(currentHasViews ? currentItemId : null);
81
+ }, [open, currentItemId, currentHasViews]);
82
+ useEffect(() => {
83
+ if (!open)
84
+ scrolledToRef.current = null;
85
+ }, [open]);
86
+ // Bring the current row into view as soon as it is in the DOM, so a long
87
+ // tree never opens scrolled away from where the user actually is. Done from
88
+ // the ref callback rather than an effect because the drawer portals its
89
+ // content in a later commit than the one that flips `open`.
90
+ const registerRow = (id) => (el) => {
91
+ if (el == null)
92
+ return;
93
+ if (!open || id !== currentItemId || scrolledToRef.current === id)
94
+ return;
95
+ scrolledToRef.current = id;
96
+ // `scrollIntoView` is absent in some non-browser DOM implementations.
97
+ if (typeof el.scrollIntoView === 'function') {
98
+ el.scrollIntoView({ block: 'center' });
99
+ }
100
+ };
101
+ const orderItems = (items) => currentFirst ? withCurrentFirst(items, currentItemId) : items;
35
102
  const navLink = (to, label, className, children, isActive) => {
36
103
  if (renderLink) {
37
104
  return renderLink({
@@ -72,7 +139,7 @@ export function MobileWorkspaceSheet({ tree, activeTo, renderLink, workspaceMenu
72
139
  return (_jsx(Drawer, { open: open, onOpenChange: (o) => !o && close(), direction: "bottom", children: _jsxs(DrawerContent, { showOverlay: true, className: "max-h-[86vh] rounded-t-[22px] p-0 data-[vaul-drawer-direction=bottom]:mt-0 data-[vaul-drawer-direction=bottom]:max-h-[86vh]", children: [_jsxs(DrawerHeader, { className: "sr-only", children: [_jsx(DrawerTitle, { children: "Navigation" }), _jsx(DrawerDescription, { children: "Jump to any area of the workspace." })] }), _jsxs("div", { className: "min-h-0 flex-1 overflow-y-auto px-3 pt-1 pb-[calc(env(safe-area-inset-bottom)+12px)]", children: [_jsxs("button", { type: "button", onClick: () => setAccountOpen((v) => !v), "aria-expanded": accountOpen, className: "flex w-full items-center gap-2.5 rounded-[10px] px-1.5 py-2 text-left hover:bg-accent", children: [_jsx("span", { className: "inline-flex size-7 shrink-0 items-center justify-center overflow-hidden rounded-lg bg-muted ring-1 ring-border/70", children: ctx.workspace.icon }), _jsx("span", { className: "min-w-0 flex-1 truncate font-medium text-sm", children: ctx.workspace.name }), accountOpen ? (_jsx(ChevronUp, { className: "size-4 text-muted-foreground", "aria-hidden": "true" })) : (_jsx(ChevronDown, { className: "size-4 text-muted-foreground", "aria-hidden": "true" }))] }), accountOpen ? (_jsxs("div", { className: "mb-1 flex flex-col gap-0.5 border-b pb-2", children: [workspaceMenuItems?.map((item) => (_jsxs(Fragment, { children: [_jsx(WorkspaceMenuRow, { item: item, onClose: close }), item.separatorAfter ? _jsx("div", { className: "my-1 h-px bg-border" }) : null] }, item.id))), _jsx(ThemeRow, {}), workspaceMenuFooter] })) : null, _jsxs("button", { type: "button", onClick: () => {
73
140
  close();
74
141
  ctx.commandPalette.setOpen(true);
75
- }, className: "my-2 flex w-full items-center gap-2 rounded-[10px] border px-3 py-2.5 text-left text-muted-foreground text-sm", children: [_jsx(Search, { className: "size-4", "aria-hidden": "true" }), "Search\u2026"] }), tree.groups.map((group) => (_jsxs("section", { "aria-label": group.label, children: [_jsx("p", { className: "px-2 pt-3 pb-1 text-[11px] text-muted-foreground", children: group.label }), _jsx("div", { className: "flex flex-col gap-0.5", children: group.items.map((item) => (_jsx(Fragment, { children: renderRow(item) }, item.id))) })] }, group.id))), tree.footerItems && tree.footerItems.length > 0 ? (_jsxs(_Fragment, { children: [_jsx("div", { className: "mx-2 my-2 h-px bg-border" }), _jsx("div", { className: "flex flex-col gap-0.5", children: tree.footerItems.map((item) => (_jsx(Fragment, { children: renderRow(item) }, item.id))) })] })) : null] })] }) }));
142
+ }, className: "my-2 flex w-full items-center gap-2 rounded-[10px] border px-3 py-2.5 text-left text-muted-foreground text-sm", children: [_jsx(Search, { className: "size-4", "aria-hidden": "true" }), "Search\u2026"] }), tree.groups.map((group) => (_jsxs("section", { "aria-label": group.label, children: [_jsx("p", { className: "px-2 pt-3 pb-1 text-[11px] text-muted-foreground", children: group.label }), _jsx("div", { className: "flex flex-col gap-0.5", children: orderItems(group.items).map((item) => (_jsx("div", { ref: registerRow(item.id), "data-meda-nav-item": item.id, children: renderRow(item) }, item.id))) })] }, group.id))), tree.footerItems && tree.footerItems.length > 0 ? (_jsxs(_Fragment, { children: [_jsx("div", { className: "mx-2 my-2 h-px bg-border" }), _jsx("div", { className: "flex flex-col gap-0.5", children: orderItems(tree.footerItems).map((item) => (_jsx("div", { ref: registerRow(item.id), "data-meda-nav-item": item.id, children: renderRow(item) }, item.id))) })] })) : null] })] }) }));
76
143
  }
77
144
  function WorkspaceMenuRow({ item, onClose }) {
78
145
  const icon = renderIcon(item.icon, 16);
@@ -12,4 +12,4 @@ export interface ResolvedPanelViews {
12
12
  }
13
13
  export declare function mergePanelViews(staticViews: PanelView[] | undefined, registrations: PanelViewRegistration[], staticDefaultView?: string): ResolvedPanelViews;
14
14
  export declare function useResolvedPanelViews(staticViews?: PanelView[], staticDefaultView?: string): ResolvedPanelViews;
15
- export declare function PanelViewsProvider({ views, defaultView, children }: PanelViewsProviderProps): import("react/jsx-runtime").JSX.Element;
15
+ export declare function PanelViewsProvider({ views, defaultView, children }: PanelViewsProviderProps): import("react").JSX.Element;
@@ -35,7 +35,7 @@ export interface RailDropSlotProps {
35
35
  ariaLabel?: string;
36
36
  ref?: Ref<HTMLElement>;
37
37
  }
38
- export declare function RailDropSlot({ id, accepts, disabled, children, render, className, ariaLabel, ref, }: RailDropSlotProps): import("react/jsx-runtime").JSX.Element;
38
+ export declare function RailDropSlot({ id, accepts, disabled, children, render, className, ariaLabel, ref, }: RailDropSlotProps): import("react").JSX.Element;
39
39
  export declare namespace RailDropSlot {
40
40
  var displayName: string;
41
41
  }
@@ -22,7 +22,7 @@ export interface RailDropZonesProps {
22
22
  children: ReactNode;
23
23
  className?: string;
24
24
  }
25
- export declare function RailDropZones({ title, subtitle, count, icon, forceActive, isActive, children, className, }: RailDropZonesProps): import("react/jsx-runtime").JSX.Element;
25
+ export declare function RailDropZones({ title, subtitle, count, icon, forceActive, isActive, children, className, }: RailDropZonesProps): import("react").JSX.Element;
26
26
  export declare namespace RailDropZones {
27
27
  var displayName: string;
28
28
  }
@@ -20,7 +20,7 @@ export interface ResizableShellProps {
20
20
  className?: string;
21
21
  children: ReactNode;
22
22
  }
23
- export declare function ResizableShell({ orientation, className, children, }: ResizableShellProps): import("react/jsx-runtime").JSX.Element;
23
+ export declare function ResizableShell({ orientation, className, children, }: ResizableShellProps): import("react").JSX.Element;
24
24
  export interface ResizableShellPanelProps {
25
25
  /** Percent (0–100). */
26
26
  defaultSize?: number;
@@ -36,10 +36,10 @@ export interface ResizableShellPanelProps {
36
36
  className?: string;
37
37
  children: ReactNode;
38
38
  }
39
- export declare function ResizableShellPanel({ className, children, onResize, ...props }: ResizableShellPanelProps): import("react/jsx-runtime").JSX.Element;
39
+ export declare function ResizableShellPanel({ className, children, onResize, ...props }: ResizableShellPanelProps): import("react").JSX.Element;
40
40
  export interface ResizableHandleProps {
41
41
  className?: string;
42
42
  /** When true, renders a visible drag-indicator bar inside the handle. */
43
43
  withHandle?: boolean;
44
44
  }
45
- export declare function ResizableHandle({ className, withHandle }: ResizableHandleProps): import("react/jsx-runtime").JSX.Element;
45
+ export declare function ResizableHandle({ className, withHandle }: ResizableHandleProps): import("react").JSX.Element;
@@ -23,4 +23,4 @@ export interface RightPanelTabRenderArgs {
23
23
  export type RightPanelTabButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & {
24
24
  'data-active'?: boolean;
25
25
  };
26
- export declare function RightPanel({ panelViews, defaultView, modes, renderTab, className, }: RightPanelProps): import("react/jsx-runtime").JSX.Element | null;
26
+ export declare function RightPanel({ panelViews, defaultView, modes, renderTab, className, }: RightPanelProps): import("react").JSX.Element | null;
@@ -1,5 +1,15 @@
1
1
  import { type ReactNode } from 'react';
2
- import type { AppShellAppTabsConfig, PanelView, WorkspaceMenuItem } from './types.js';
2
+ import type { IconRailLabelVisibility } from './icon-rail.js';
3
+ import type { AppShellAppTabsConfig, PanelView, ShellHeaderLayout, WorkspaceMenuItem } from './types.js';
4
+ /**
5
+ * WorkspaceSwitcher trigger shape.
6
+ *
7
+ * - `chip` (default, unchanged) — a horizontal button: mark · name · chevron.
8
+ * - `tile` — a full-width, rail-column button: the mark centred on the rail's
9
+ * axis with the workspace name beneath it in the icon-rail label type. Used
10
+ * by `<ShellHeader headerLayout="rail">`.
11
+ */
12
+ export type WorkspaceSwitcherVariant = 'chip' | 'tile';
3
13
  export interface WorkspaceSwitcherProps {
4
14
  /**
5
15
  * Configurable dropdown items. When provided, REPLACES the default
@@ -17,21 +27,34 @@ export interface WorkspaceSwitcherProps {
17
27
  menuFooter?: ReactNode;
18
28
  /** @deprecated Use `menuFooter` instead. */
19
29
  workspaceMenuFooter?: ReactNode;
30
+ /**
31
+ * Trigger presentation. Defaults to `chip` — the 1.x/2.x horizontal button.
32
+ * The dropdown content and behaviour are identical in both variants.
33
+ */
34
+ variant?: WorkspaceSwitcherVariant;
35
+ /**
36
+ * `tile` variant only — render the workspace name under the mark. Pass
37
+ * `false` when the icon rail is icon-only (`labelVisibility: 'tooltip'`) so
38
+ * the tile matches the narrow rail. Ignored by the `chip` variant, whose
39
+ * name is never hidden. Defaults to `true`.
40
+ */
41
+ showLabel?: boolean;
20
42
  }
21
- export declare function WorkspaceSwitcher({ menuItems, menuFooter, workspaceMenuFooter, }?: WorkspaceSwitcherProps): import("react/jsx-runtime").JSX.Element;
43
+ export declare function WorkspaceSwitcher({ menuItems, menuFooter, workspaceMenuFooter, variant, showLabel, }?: WorkspaceSwitcherProps): import("react").JSX.Element;
22
44
  export interface AppTabsProps extends AppShellAppTabsConfig {
23
45
  }
24
- export declare function AppTabs({ renderLink }?: AppTabsProps): import("react/jsx-runtime").JSX.Element;
46
+ export declare function AppTabs({ renderLink }?: AppTabsProps): import("react").JSX.Element;
25
47
  export interface PanelToggleProps {
26
48
  /** Panel views surfaced in the chevron dropdown. Empty → plain toggle. */
27
49
  panelViews?: PanelView[];
28
50
  }
29
- export declare function PanelToggle({ panelViews }?: PanelToggleProps): import("react/jsx-runtime").JSX.Element;
51
+ export declare function PanelToggle({ panelViews }?: PanelToggleProps): import("react").JSX.Element;
30
52
  export interface ShellHeaderProps {
31
53
  globalActions?: ReactNode;
32
54
  /**
33
55
  * Optional center-region content. Replaces the default application tabs when
34
- * provided.
56
+ * provided. IGNORED when `headerLayout="rail"` — that layout has no centre
57
+ * column; put the content in `headerLeading` instead.
35
58
  */
36
59
  headerCenter?: ReactNode;
37
60
  /**
@@ -50,5 +73,19 @@ export interface ShellHeaderProps {
50
73
  showPanelToggle?: boolean;
51
74
  /** Panel views forwarded to the header `<PanelToggle>` dropdown. */
52
75
  panelViews?: PanelView[];
76
+ /**
77
+ * Header grid. `split` (default) is the pre-2.8 markup, unchanged. `rail`
78
+ * switches to `[rail column | fill | actions]` — see `ShellHeaderLayout`.
79
+ */
80
+ headerLayout?: ShellHeaderLayout;
81
+ /**
82
+ * The icon rail's label mode, so the `rail` layout can size its first column
83
+ * to the rail below it (`--shell-rail-label-width` when the rail shows
84
+ * labels, `--shell-rail-width` when it does not) and hide the tile's
85
+ * workspace name in icon-only mode. Mirror `iconRail.labelVisibility`.
86
+ * Defaults to `tooltip`, matching `IconRail`'s own default. Unused by the
87
+ * `split` layout.
88
+ */
89
+ railLabelVisibility?: IconRailLabelVisibility;
53
90
  }
54
- export declare function ShellHeader({ globalActions, headerCenter, headerLeading, appTabsRenderLink, className, workspaceMenuItems, workspaceMenuFooter, showPanelToggle, panelViews, }?: ShellHeaderProps): import("react/jsx-runtime").JSX.Element | null;
91
+ export declare function ShellHeader({ globalActions, headerCenter, headerLeading, appTabsRenderLink, className, workspaceMenuItems, workspaceMenuFooter, showPanelToggle, panelViews, headerLayout, railLabelVisibility, }?: ShellHeaderProps): import("react").JSX.Element | null;