react-reason-editor-sidebar 0.1.121 → 0.1.123

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.
@@ -4,4 +4,4 @@ import './split-pane.css';
4
4
  * Renders the enabled panels for one side of the layout, stacked in a
5
5
  * resizable vertical split when more than one panel is active.
6
6
  */
7
- export declare const SidebarContent: ({ panels, persistenceKey, activeDocuments, activeId, activeDocument, headings, isMobile, onSelect, onAdd, onDelete, onDuplicate, onMove, onManageTags, onRename, onOpenChange, treeRef, onExpandStateChange, onSetExpandedFolders, outlineRef, editorRef, openTabs, activeTab, onTabChange, onTabClose, onTabsClose, onTabRename, onSplitRight, onReopenLastClosed, canReopenLastClosed, onNavigate, aiProps, tipsProps, topicsProps, tabItems, onNewChat, onFileManagerOpen, deletedDocs, onRestore, }: SidebarContentProps) => import("react").JSX.Element;
7
+ export declare const SidebarContent: ({ panels, persistenceKey, activeDocuments, activeId, activeDocument, headings, isMobile, onSelect, onAdd, onDelete, onDuplicate, onMove, onManageTags, onRename, onOpenChange, treeRef, onExpandStateChange, onSetExpandedFolders, outlineRef, editorRef, openTabs, activeTab, onTabChange, onTabClose, onTabsClose, onTabRename, onSplitRight, onReopenLastClosed, canReopenLastClosed, onNavigate, aiProps, tipsProps, topicsProps, tabItems, onNewChat, onFileManagerOpen, deletedDocs, onRestore, sources, activeSource, activeFileSourceId, onSourceSelect, onFileSourceChange, }: SidebarContentProps) => import("react").JSX.Element;
@@ -31,8 +31,8 @@ interface SidebarFooterProps {
31
31
  onFileSourceChange?: (sourceId: string) => void;
32
32
  }
33
33
  /**
34
- * Compact icon row pinned to the bottom of the sidebar. Includes the storage
35
- * source switcher, a trash dropdown (restore deleted docs), a settings link
34
+ * Compact icon row pinned to the bottom of the sidebar. Includes a storage
35
+ * source switcher (only when the Files panel is hidden), a trash dropdown (restore deleted docs), a settings link
36
36
  * to the settings page, and a panel view dropdown.
37
37
  */
38
38
  export declare const SidebarFooter: ({ leftPanels, onLeftPanelsChange, rightPanels, onRightPanelsChange, deletedDocs, onRestore, settingsHref, sources, activeSource, activeFileSourceId, onSourceSelect, onFileSourceChange, }: SidebarFooterProps) => import("react").JSX.Element;
@@ -2,7 +2,7 @@
2
2
  * @module SidebarToolbar
3
3
  * @description Compact icon toolbar rendered at the top of the sidebar. Shows
4
4
  * context-sensitive controls based on `leftPanels`: search and expand/collapse
5
- * buttons. The storage-source switcher lives in the sidebar footer. The
5
+ * buttons. The storage-source switcher lives in the "Files" panel header. The
6
6
  * file-tree actions (new file/folder, trash, file manager) render here only
7
7
  * when the "Files" panel — which hosts them in its own header — is hidden.
8
8
  */
@@ -0,0 +1,27 @@
1
+ /**
2
+ * @module StorageSourceMenu
3
+ * @description Dropdown for switching the active storage (file) source. Shown
4
+ * in the "Files" panel header, with a fallback in the sidebar footer when the
5
+ * Files panel isn't on screen.
6
+ */
7
+ import type { ReactNode } from 'react';
8
+ import type { AnyFileSource } from './app-types/fileSource';
9
+ /** Props for the {@link StorageSourceMenu} component. */
10
+ export interface StorageSourceMenuProps {
11
+ /** Available file source configurations. */
12
+ sources: AnyFileSource[];
13
+ /** The currently active file source object, or `null` if none selected. */
14
+ activeSource?: AnyFileSource | null;
15
+ /** ID of the currently active file source. */
16
+ activeFileSourceId?: string;
17
+ /** Selects a source by ID. */
18
+ onSourceSelect?: (sourceId: string) => void;
19
+ /** Wraps the trigger icon in the host's button (receives the source icon). */
20
+ renderTrigger: (icon: ReactNode, label: string) => ReactNode;
21
+ /** Side the menu opens toward. */
22
+ side?: 'top' | 'bottom';
23
+ /** Alignment of the menu relative to the trigger. */
24
+ align?: 'start' | 'end';
25
+ }
26
+ /** Storage-source switcher dropdown with a host-supplied trigger button. */
27
+ export declare const StorageSourceMenu: ({ sources, activeSource, activeFileSourceId, onSourceSelect, renderTrigger, side, align, }: StorageSourceMenuProps) => import("react").JSX.Element;