@opencxh/ui-kit 3.94.0 → 3.98.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.
@@ -4,6 +4,8 @@ export interface SplitButtonOption {
4
4
  label: string;
5
5
  onClick: () => void;
6
6
  variant?: "default" | "destructive";
7
+ /** Optioneel icoon vóór het label in het menu. */
8
+ icon?: React.ReactNode;
7
9
  }
8
10
  export interface SplitButtonProps {
9
11
  label: string;
@@ -13,8 +15,22 @@ export interface SplitButtonProps {
13
15
  icon?: React.ReactNode;
14
16
  options: SplitButtonOption[];
15
17
  disabled?: boolean;
18
+ /** Spinner in de primaire helft; blokkeert beide helften. */
19
+ loading?: boolean;
20
+ /**
21
+ * Waar het optie-menu opent. Gebruik een `top-*` placement wanneer de knop
22
+ * onderaan zijn container staat (bv. een sticky verzendbalk).
23
+ */
24
+ menuPlacement?: "bottom-end" | "bottom-start" | "top-end" | "top-start";
25
+ /** Accessible naam voor de chevron-knop. */
26
+ menuLabel?: string;
16
27
  }
17
28
  /**
18
- * SplitButton component with theme integration and accessibility features
29
+ * Knop met een primaire actie plus een chevron-menu voor varianten daarvan.
30
+ * De primaire helft is een gewone `Button` (zelfde varianten/loading-gedrag);
31
+ * het menu loopt via `Popover`, dus het is `position: fixed` en wordt niet
32
+ * geklipt door een scrollende of overflow-hidden voorouder.
33
+ *
34
+ * Zonder opties rendert dit precies een `Button` — geen chevron.
19
35
  */
20
- export declare function SplitButton({ label, onClick, variant, size, icon, options, disabled, }: SplitButtonProps): React.JSX.Element;
36
+ export declare function SplitButton({ label, onClick, variant, size, icon, options, disabled, loading, menuPlacement, menuLabel, }: SplitButtonProps): React.JSX.Element;
@@ -13,6 +13,11 @@ export interface PopoverProps {
13
13
  className?: string;
14
14
  /** Whether the trigger is disabled */
15
15
  disabled?: boolean;
16
+ /**
17
+ * Accessible name for the trigger button. Needed when the trigger is
18
+ * icon-only, since the panel content is not announced by the trigger.
19
+ */
20
+ triggerLabel?: string;
16
21
  }
17
22
  /**
18
23
  * Generic popover with click-outside / Escape dismissal. The panel is
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencxh/ui-kit",
3
- "version": "3.94.0",
3
+ "version": "3.98.0",
4
4
  "description": "Theme-aware UI component library for OpenCXH platform",
5
5
  "type": "module",
6
6
  "exports": {