@openwebf/react-cupertino-ui 0.3.11 → 0.3.12

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.mts CHANGED
@@ -1688,6 +1688,123 @@ declare const FlutterCupertinoIcon: React.ForwardRefExoticComponent<FlutterCuper
1688
1688
  children?: React.ReactNode;
1689
1689
  } & React.RefAttributes<FlutterCupertinoIconElement>>;
1690
1690
 
1691
+ /**
1692
+ * Properties for <flutter-cupertino-context-menu>.
1693
+ * Wraps Flutter's CupertinoContextMenu.
1694
+ */
1695
+ interface ContextMenuAction {
1696
+ /**
1697
+ * Button label text.
1698
+ */
1699
+ text: string;
1700
+ /**
1701
+ * Optional trailing icon name (Cupertino icon key).
1702
+ */
1703
+ icon?: string;
1704
+ /**
1705
+ * Marks this action as destructive (red).
1706
+ */
1707
+ destructive?: boolean;
1708
+ /**
1709
+ * Marks this action as the default action.
1710
+ */
1711
+ default?: boolean;
1712
+ /**
1713
+ * Optional event name associated with this action.
1714
+ * If omitted, a name may be derived from the text.
1715
+ */
1716
+ event?: string;
1717
+ }
1718
+ interface FlutterCupertinoContextMenuSelectDetail {
1719
+ /**
1720
+ * Zero-based index of the selected action.
1721
+ */
1722
+ index: number;
1723
+ /**
1724
+ * Action text.
1725
+ */
1726
+ text: string;
1727
+ /**
1728
+ * Event name for this action.
1729
+ */
1730
+ event: string;
1731
+ /**
1732
+ * Whether the action is destructive.
1733
+ */
1734
+ destructive: boolean;
1735
+ /**
1736
+ * Whether the action is the default one.
1737
+ */
1738
+ default: boolean;
1739
+ }
1740
+ interface FlutterCupertinoContextMenuProps {
1741
+ /**
1742
+ * Whether to enable haptic feedback when the menu is opened.
1743
+ * Default: false.
1744
+ */
1745
+ enableHapticFeedback?: boolean;
1746
+ /**
1747
+ * Fired when an action is selected.
1748
+ * detail contains metadata about the selected action.
1749
+ */
1750
+ onSelect?: (event: CustomEvent<FlutterCupertinoContextMenuSelectDetail>) => void;
1751
+ /**
1752
+ * HTML id attribute
1753
+ */
1754
+ id?: string;
1755
+ /**
1756
+ * Additional CSS styles
1757
+ */
1758
+ style?: React.CSSProperties;
1759
+ /**
1760
+ * Children elements
1761
+ */
1762
+ children?: React.ReactNode;
1763
+ /**
1764
+ * Additional CSS class names
1765
+ */
1766
+ className?: string;
1767
+ }
1768
+ /**
1769
+ * Element interface with methods accessible via ref
1770
+ * @example
1771
+ * ```tsx
1772
+ * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
1773
+ * // Call methods on the element
1774
+ * ref.current?.finishRefresh('success');
1775
+ * ```
1776
+ */
1777
+ interface FlutterCupertinoContextMenuElement extends WebFElementWithMethods<{
1778
+ /**
1779
+ * Set the list of actions displayed in the context menu.
1780
+ */
1781
+ setActions(actions: ContextMenuAction[]): void;
1782
+ }> {
1783
+ }
1784
+ /**
1785
+ * FlutterCupertinoContextMenu - WebF FlutterCupertinoContextMenu component
1786
+ *
1787
+ * @example
1788
+ * ```tsx
1789
+ * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
1790
+ *
1791
+ * <FlutterCupertinoContextMenu
1792
+ * ref={ref}
1793
+ * // Add props here
1794
+ * >
1795
+ * Content
1796
+ * </FlutterCupertinoContextMenu>
1797
+ *
1798
+ * // Call methods on the element
1799
+ * ref.current?.finishRefresh('success');
1800
+ * ```
1801
+ */
1802
+ declare const FlutterCupertinoContextMenu: React.ForwardRefExoticComponent<FlutterCupertinoContextMenuProps & {
1803
+ className?: string;
1804
+ style?: React.CSSProperties;
1805
+ children?: React.ReactNode;
1806
+ } & React.RefAttributes<FlutterCupertinoContextMenuElement>>;
1807
+
1691
1808
  interface FlutterCupertinoButtonProps {
1692
1809
  /**
1693
1810
  * Visual variant of the button.
@@ -3789,84 +3906,6 @@ declare const FlutterCupertinoDatePicker: React.ForwardRefExoticComponent<Flutte
3789
3906
  children?: React.ReactNode;
3790
3907
  } & React.RefAttributes<FlutterCupertinoDatePickerElement>>;
3791
3908
 
3792
- interface ContextMenuAction {
3793
- text: string;
3794
- icon?: string;
3795
- destructive?: boolean;
3796
- default?: boolean;
3797
- event?: string;
3798
- }
3799
- interface FlutterCupertinoContextMenuSelectDetail {
3800
- index: number;
3801
- text: string;
3802
- event: string;
3803
- destructive: boolean;
3804
- default: boolean;
3805
- }
3806
- interface FlutterCupertinoContextMenuProps {
3807
- /**
3808
- * enableHapticFeedback property
3809
- * @default undefined
3810
- */
3811
- enableHapticFeedback?: boolean;
3812
- /**
3813
- * select event handler
3814
- */
3815
- onSelect?: (event: CustomEvent<FlutterCupertinoContextMenuSelectDetail>) => void;
3816
- /**
3817
- * HTML id attribute
3818
- */
3819
- id?: string;
3820
- /**
3821
- * Additional CSS styles
3822
- */
3823
- style?: React.CSSProperties;
3824
- /**
3825
- * Children elements
3826
- */
3827
- children?: React.ReactNode;
3828
- /**
3829
- * Additional CSS class names
3830
- */
3831
- className?: string;
3832
- }
3833
- /**
3834
- * Element interface with methods accessible via ref
3835
- * @example
3836
- * ```tsx
3837
- * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
3838
- * // Call methods on the element
3839
- * ref.current?.finishRefresh('success');
3840
- * ```
3841
- */
3842
- interface FlutterCupertinoContextMenuElement extends WebFElementWithMethods<{
3843
- setActions(actions: ContextMenuAction[]): void;
3844
- }> {
3845
- }
3846
- /**
3847
- * FlutterCupertinoContextMenu - WebF FlutterCupertinoContextMenu component
3848
- *
3849
- * @example
3850
- * ```tsx
3851
- * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
3852
- *
3853
- * <FlutterCupertinoContextMenu
3854
- * ref={ref}
3855
- * // Add props here
3856
- * >
3857
- * Content
3858
- * </FlutterCupertinoContextMenu>
3859
- *
3860
- * // Call methods on the element
3861
- * ref.current?.finishRefresh('success');
3862
- * ```
3863
- */
3864
- declare const FlutterCupertinoContextMenu: React.ForwardRefExoticComponent<FlutterCupertinoContextMenuProps & {
3865
- className?: string;
3866
- style?: React.CSSProperties;
3867
- children?: React.ReactNode;
3868
- } & React.RefAttributes<FlutterCupertinoContextMenuElement>>;
3869
-
3870
3909
  interface FlutterCupertinoCheckboxProps {
3871
3910
  /**
3872
3911
  * val property
package/dist/index.d.ts CHANGED
@@ -1688,6 +1688,123 @@ declare const FlutterCupertinoIcon: React.ForwardRefExoticComponent<FlutterCuper
1688
1688
  children?: React.ReactNode;
1689
1689
  } & React.RefAttributes<FlutterCupertinoIconElement>>;
1690
1690
 
1691
+ /**
1692
+ * Properties for <flutter-cupertino-context-menu>.
1693
+ * Wraps Flutter's CupertinoContextMenu.
1694
+ */
1695
+ interface ContextMenuAction {
1696
+ /**
1697
+ * Button label text.
1698
+ */
1699
+ text: string;
1700
+ /**
1701
+ * Optional trailing icon name (Cupertino icon key).
1702
+ */
1703
+ icon?: string;
1704
+ /**
1705
+ * Marks this action as destructive (red).
1706
+ */
1707
+ destructive?: boolean;
1708
+ /**
1709
+ * Marks this action as the default action.
1710
+ */
1711
+ default?: boolean;
1712
+ /**
1713
+ * Optional event name associated with this action.
1714
+ * If omitted, a name may be derived from the text.
1715
+ */
1716
+ event?: string;
1717
+ }
1718
+ interface FlutterCupertinoContextMenuSelectDetail {
1719
+ /**
1720
+ * Zero-based index of the selected action.
1721
+ */
1722
+ index: number;
1723
+ /**
1724
+ * Action text.
1725
+ */
1726
+ text: string;
1727
+ /**
1728
+ * Event name for this action.
1729
+ */
1730
+ event: string;
1731
+ /**
1732
+ * Whether the action is destructive.
1733
+ */
1734
+ destructive: boolean;
1735
+ /**
1736
+ * Whether the action is the default one.
1737
+ */
1738
+ default: boolean;
1739
+ }
1740
+ interface FlutterCupertinoContextMenuProps {
1741
+ /**
1742
+ * Whether to enable haptic feedback when the menu is opened.
1743
+ * Default: false.
1744
+ */
1745
+ enableHapticFeedback?: boolean;
1746
+ /**
1747
+ * Fired when an action is selected.
1748
+ * detail contains metadata about the selected action.
1749
+ */
1750
+ onSelect?: (event: CustomEvent<FlutterCupertinoContextMenuSelectDetail>) => void;
1751
+ /**
1752
+ * HTML id attribute
1753
+ */
1754
+ id?: string;
1755
+ /**
1756
+ * Additional CSS styles
1757
+ */
1758
+ style?: React.CSSProperties;
1759
+ /**
1760
+ * Children elements
1761
+ */
1762
+ children?: React.ReactNode;
1763
+ /**
1764
+ * Additional CSS class names
1765
+ */
1766
+ className?: string;
1767
+ }
1768
+ /**
1769
+ * Element interface with methods accessible via ref
1770
+ * @example
1771
+ * ```tsx
1772
+ * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
1773
+ * // Call methods on the element
1774
+ * ref.current?.finishRefresh('success');
1775
+ * ```
1776
+ */
1777
+ interface FlutterCupertinoContextMenuElement extends WebFElementWithMethods<{
1778
+ /**
1779
+ * Set the list of actions displayed in the context menu.
1780
+ */
1781
+ setActions(actions: ContextMenuAction[]): void;
1782
+ }> {
1783
+ }
1784
+ /**
1785
+ * FlutterCupertinoContextMenu - WebF FlutterCupertinoContextMenu component
1786
+ *
1787
+ * @example
1788
+ * ```tsx
1789
+ * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
1790
+ *
1791
+ * <FlutterCupertinoContextMenu
1792
+ * ref={ref}
1793
+ * // Add props here
1794
+ * >
1795
+ * Content
1796
+ * </FlutterCupertinoContextMenu>
1797
+ *
1798
+ * // Call methods on the element
1799
+ * ref.current?.finishRefresh('success');
1800
+ * ```
1801
+ */
1802
+ declare const FlutterCupertinoContextMenu: React.ForwardRefExoticComponent<FlutterCupertinoContextMenuProps & {
1803
+ className?: string;
1804
+ style?: React.CSSProperties;
1805
+ children?: React.ReactNode;
1806
+ } & React.RefAttributes<FlutterCupertinoContextMenuElement>>;
1807
+
1691
1808
  interface FlutterCupertinoButtonProps {
1692
1809
  /**
1693
1810
  * Visual variant of the button.
@@ -3789,84 +3906,6 @@ declare const FlutterCupertinoDatePicker: React.ForwardRefExoticComponent<Flutte
3789
3906
  children?: React.ReactNode;
3790
3907
  } & React.RefAttributes<FlutterCupertinoDatePickerElement>>;
3791
3908
 
3792
- interface ContextMenuAction {
3793
- text: string;
3794
- icon?: string;
3795
- destructive?: boolean;
3796
- default?: boolean;
3797
- event?: string;
3798
- }
3799
- interface FlutterCupertinoContextMenuSelectDetail {
3800
- index: number;
3801
- text: string;
3802
- event: string;
3803
- destructive: boolean;
3804
- default: boolean;
3805
- }
3806
- interface FlutterCupertinoContextMenuProps {
3807
- /**
3808
- * enableHapticFeedback property
3809
- * @default undefined
3810
- */
3811
- enableHapticFeedback?: boolean;
3812
- /**
3813
- * select event handler
3814
- */
3815
- onSelect?: (event: CustomEvent<FlutterCupertinoContextMenuSelectDetail>) => void;
3816
- /**
3817
- * HTML id attribute
3818
- */
3819
- id?: string;
3820
- /**
3821
- * Additional CSS styles
3822
- */
3823
- style?: React.CSSProperties;
3824
- /**
3825
- * Children elements
3826
- */
3827
- children?: React.ReactNode;
3828
- /**
3829
- * Additional CSS class names
3830
- */
3831
- className?: string;
3832
- }
3833
- /**
3834
- * Element interface with methods accessible via ref
3835
- * @example
3836
- * ```tsx
3837
- * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
3838
- * // Call methods on the element
3839
- * ref.current?.finishRefresh('success');
3840
- * ```
3841
- */
3842
- interface FlutterCupertinoContextMenuElement extends WebFElementWithMethods<{
3843
- setActions(actions: ContextMenuAction[]): void;
3844
- }> {
3845
- }
3846
- /**
3847
- * FlutterCupertinoContextMenu - WebF FlutterCupertinoContextMenu component
3848
- *
3849
- * @example
3850
- * ```tsx
3851
- * const ref = useRef<FlutterCupertinoContextMenuElement>(null);
3852
- *
3853
- * <FlutterCupertinoContextMenu
3854
- * ref={ref}
3855
- * // Add props here
3856
- * >
3857
- * Content
3858
- * </FlutterCupertinoContextMenu>
3859
- *
3860
- * // Call methods on the element
3861
- * ref.current?.finishRefresh('success');
3862
- * ```
3863
- */
3864
- declare const FlutterCupertinoContextMenu: React.ForwardRefExoticComponent<FlutterCupertinoContextMenuProps & {
3865
- className?: string;
3866
- style?: React.CSSProperties;
3867
- children?: React.ReactNode;
3868
- } & React.RefAttributes<FlutterCupertinoContextMenuElement>>;
3869
-
3870
3909
  interface FlutterCupertinoCheckboxProps {
3871
3910
  /**
3872
3911
  * val property