lucent-ui 0.17.0 → 0.18.0

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.
package/dist/index.d.ts CHANGED
@@ -772,6 +772,67 @@ export declare function makeLibraryCSS(tokens: LucentTokens, selector?: string):
772
772
 
773
773
  export declare const MANIFEST_SPEC_VERSION = "1.0";
774
774
 
775
+ export declare function Menu({ trigger, children, placement, size, open: controlledOpen, onOpenChange, style, }: MenuProps): JSX_2.Element;
776
+
777
+ export declare function MenuGroup({ label, children, style }: MenuGroupProps): JSX_2.Element;
778
+
779
+ export declare interface MenuGroupProps {
780
+ /** Label shown above the group. */
781
+ label: string;
782
+ children: ReactNode;
783
+ style?: CSSProperties;
784
+ }
785
+
786
+ export declare function MenuItem({ onSelect, children, icon, shortcut, disabled, danger, selected, style, }: MenuItemProps): JSX_2.Element;
787
+
788
+ export declare interface MenuItemProps {
789
+ /** Fires when item is selected (click or Enter). */
790
+ onSelect: () => void;
791
+ /** Label content. */
792
+ children: ReactNode;
793
+ /** Leading icon. */
794
+ icon?: ReactNode;
795
+ /** Trailing shortcut hint text. */
796
+ shortcut?: string;
797
+ /** Disables selection and grays out. */
798
+ disabled?: boolean;
799
+ /** Renders in danger color. */
800
+ danger?: boolean;
801
+ /** Marks the item as currently selected (shows checkmark). */
802
+ selected?: boolean;
803
+ /** Style overrides. */
804
+ style?: CSSProperties;
805
+ }
806
+
807
+ export declare const MenuManifest: ComponentManifest;
808
+
809
+ export declare type MenuPlacement = 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'right';
810
+
811
+ export declare interface MenuProps {
812
+ /** Element that toggles the menu on click. */
813
+ trigger: ReactNode;
814
+ /** MenuItem, MenuSeparator, or MenuGroup elements. */
815
+ children: ReactNode;
816
+ /** Preferred placement relative to the trigger. */
817
+ placement?: MenuPlacement;
818
+ /** Size of the menu items. */
819
+ size?: MenuSize;
820
+ /** Controlled open state. */
821
+ open?: boolean;
822
+ /** Callback when open state changes. */
823
+ onOpenChange?: (open: boolean) => void;
824
+ /** Style overrides for the popover panel. */
825
+ style?: CSSProperties;
826
+ }
827
+
828
+ export declare function MenuSeparator({ style }: MenuSeparatorProps): JSX_2.Element;
829
+
830
+ export declare interface MenuSeparatorProps {
831
+ style?: CSSProperties;
832
+ }
833
+
834
+ export declare type MenuSize = 'sm' | 'md' | 'lg';
835
+
775
836
  export declare const modernPreset: DesignPreset;
776
837
 
777
838
  declare interface MotionTokens {