@databricks/design-system 2.0.3 → 2.0.5

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 (45) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/dist/RHFControlledTypeaheadComboboxV2-DsH-nIEk.js +172 -0
  3. package/dist/RHFControlledTypeaheadComboboxV2-DsH-nIEk.js.map +1 -0
  4. package/dist/{WizardStepContentWrapper-DsAS2ZAT.js → WizardStepContentWrapper-Bq1wm0V7.js} +669 -435
  5. package/dist/WizardStepContentWrapper-Bq1wm0V7.js.map +1 -0
  6. package/dist/index-BRAVZg-S.js +8308 -0
  7. package/dist/index-BRAVZg-S.js.map +1 -0
  8. package/dist/index-dark.css +395 -128
  9. package/dist/index-dark.mitigated.css +398 -131
  10. package/dist/index.css +844 -277
  11. package/dist/index.js +25 -8119
  12. package/dist/index.js.map +1 -1
  13. package/dist/index.mitigated.css +848 -281
  14. package/dist/patterns.js +1 -1
  15. package/dist/test-utils/rtl.js +1 -1
  16. package/dist/test-utils/rtl.js.map +1 -1
  17. package/dist-types/design-system/Alert/Alert.d.ts +1 -1
  18. package/dist-types/design-system/Breadcrumb/Breadcrumb.d.ts +10 -3
  19. package/dist-types/design-system/Button/AntDButtonInternal.d.ts +21 -0
  20. package/dist-types/design-system/Button/Button.d.ts +3 -19
  21. package/dist-types/design-system/Button/NativeButton.d.ts +3 -0
  22. package/dist-types/design-system/Button/getBtnClassName.d.ts +17 -0
  23. package/dist-types/design-system/Button/index.d.ts +1 -0
  24. package/dist-types/design-system/DesignSystemProvider/DesignSystemProvider.d.ts +28 -6
  25. package/dist-types/design-system/DesignSystemProvider/DesignTokenScopeWithEmotionTheme.d.ts +23 -0
  26. package/dist-types/design-system/DesignSystemProvider/index.d.ts +1 -0
  27. package/dist-types/design-system/FormV2/RHFAdapters.d.ts +8 -0
  28. package/dist-types/design-system/FormV2/RHFControlledTypeaheadComboboxV2.d.ts +58 -0
  29. package/dist-types/design-system/Icon/Icon.d.ts +2 -2
  30. package/dist-types/design-system/Icon/__generated/icons/ColorMappingEditIcon.d.ts +4 -0
  31. package/dist-types/design-system/Icon/__generated/icons/ColorMappingIcon.d.ts +4 -0
  32. package/dist-types/design-system/Icon/__generated/icons/MicrophoneIcon.d.ts +4 -0
  33. package/dist-types/design-system/Icon/__generated/icons/MicrophoneOffIcon.d.ts +4 -0
  34. package/dist-types/design-system/Icon/__generated/icons/OperatorIcon.d.ts +4 -0
  35. package/dist-types/design-system/Icon/__generated/icons/VoiceModeIcon.d.ts +4 -0
  36. package/dist-types/design-system/Icon/__generated/icons/index.d.ts +6 -0
  37. package/dist-types/design-system/Overflow/Overflow.d.ts +3 -1
  38. package/dist-types/design-system/Overflow/OverflowPopover.d.ts +2 -1
  39. package/dist-types/design-system/TypeaheadComboboxV2/TypeaheadComboboxMenu.d.ts +2 -0
  40. package/dist-types/design-system/shape-tokens.d.ts +1 -1
  41. package/dist-types/test-utils/rtl/buttonVariants.d.ts +11 -0
  42. package/dist-types/~patterns/Wizard/WizardStepNavigation.d.ts +9 -0
  43. package/dist-types/~patterns/Wizard/index.d.ts +1 -0
  44. package/package.json +12 -4
  45. package/dist/WizardStepContentWrapper-DsAS2ZAT.js.map +0 -1
@@ -120,6 +120,8 @@ export { default as CloudOffIcon } from "./CloudOffIcon";
120
120
  export { default as CloudUploadIcon } from "./CloudUploadIcon";
121
121
  export { default as CodeIcon } from "./CodeIcon";
122
122
  export { default as ColorFillIcon } from "./ColorFillIcon";
123
+ export { default as ColorMappingEditIcon } from "./ColorMappingEditIcon";
124
+ export { default as ColorMappingIcon } from "./ColorMappingIcon";
123
125
  export { default as ColumnIcon } from "./ColumnIcon";
124
126
  export { default as ColumnSplitIcon } from "./ColumnSplitIcon";
125
127
  export { default as ColumnTagIcon } from "./ColumnTagIcon";
@@ -276,6 +278,8 @@ export { default as McpIcon } from "./McpIcon";
276
278
  export { default as MeasureIcon } from "./MeasureIcon";
277
279
  export { default as MegaphoneIcon } from "./MegaphoneIcon";
278
280
  export { default as MenuIcon } from "./MenuIcon";
281
+ export { default as MicrophoneIcon } from "./MicrophoneIcon";
282
+ export { default as MicrophoneOffIcon } from "./MicrophoneOffIcon";
279
283
  export { default as MinusCircleFillIcon } from "./MinusCircleFillIcon";
280
284
  export { default as MinusCircleIcon } from "./MinusCircleIcon";
281
285
  export { default as MinusCircleSmallIcon } from "./MinusCircleSmallIcon";
@@ -297,6 +301,7 @@ export { default as NumberFormatIcon } from "./NumberFormatIcon";
297
301
  export { default as NumbersIcon } from "./NumbersIcon";
298
302
  export { default as OfficeIcon } from "./OfficeIcon";
299
303
  export { default as OntologyIcon } from "./OntologyIcon";
304
+ export { default as OperatorIcon } from "./OperatorIcon";
300
305
  export { default as OverflowHorizontalIcon } from "./OverflowHorizontalIcon";
301
306
  export { default as OverflowIcon } from "./OverflowIcon";
302
307
  export { default as PageBottomIcon } from "./PageBottomIcon";
@@ -469,6 +474,7 @@ export { default as UserTeamIcon } from "./UserTeamIcon";
469
474
  export { default as VisibleFillIcon } from "./VisibleFillIcon";
470
475
  export { default as VisibleIcon } from "./VisibleIcon";
471
476
  export { default as VisibleOffIcon } from "./VisibleOffIcon";
477
+ export { default as VoiceModeIcon } from "./VoiceModeIcon";
472
478
  export { default as WarningFillIcon } from "./WarningFillIcon";
473
479
  export { default as WarningIcon } from "./WarningIcon";
474
480
  export { default as WorkflowCodeIcon } from "./WorkflowCodeIcon";
@@ -8,6 +8,8 @@ export interface OverflowProps extends PopoverProps {
8
8
  * @default 1
9
9
  */
10
10
  visibleItemsCount?: number;
11
+ /** Opens the overflow menu on mount; passed through to the underlying Popover. */
12
+ defaultOpen?: boolean;
11
13
  children: React.ReactNode;
12
14
  }
13
- export declare const Overflow: ({ children, noMargin, visibleItemsCount, ...props }: OverflowProps) => React.ReactElement;
15
+ export declare const Overflow: ({ children, noMargin, visibleItemsCount, defaultOpen, ...props }: OverflowProps) => React.ReactElement;
@@ -4,6 +4,7 @@ interface OverflowPopoverProps extends PopoverProps {
4
4
  renderLabel?: (label: string) => React.ReactNode;
5
5
  tooltipText?: string;
6
6
  ariaLabel?: string;
7
+ defaultOpen?: boolean;
7
8
  }
8
- export declare const OverflowPopover: ({ items, renderLabel, tooltipText, ariaLabel, ...props }: OverflowPopoverProps) => JSX.Element;
9
+ export declare const OverflowPopover: ({ items, renderLabel, tooltipText, ariaLabel, defaultOpen, ...props }: OverflowPopoverProps) => JSX.Element;
9
10
  export {};
@@ -13,5 +13,7 @@ export interface TypeaheadComboboxMenuProps extends HTMLAttributes<HTMLUListElem
13
13
  virtualizerRef?: Ref<HTMLUListElement>;
14
14
  children?: ReactNode;
15
15
  matchTriggerWidth?: boolean;
16
+ /** Gap in px between the trigger and the menu. */
17
+ offset?: number;
16
18
  }
17
19
  export declare const TypeaheadComboboxMenu: ForwardRefExoticComponent<TypeaheadComboboxMenuProps & RefAttributes<HTMLElement | null>>;
@@ -2,6 +2,6 @@ export declare enum ShapeTokens {
2
2
  ACTION_BORDER_RADIUS = "--action-border-radius",
3
3
  INPUT_BORDER_RADIUS = "--input-border-radius",
4
4
  LIST_ITEM_BORDER_RADIUS = "--list-item-border-radius",
5
- POPOVER_BORDER_RADIUS = "--popover-border-radius",
5
+ POPUP_BORDER_RADIUS = "--popup-border-radius",
6
6
  INFO_CONTAINER_BORDER_RADIUS = "--info-container-border-radius"
7
7
  }
@@ -0,0 +1,11 @@
1
+ export declare const BUTTON_VARIANT_CLASS_TOKENS: {
2
+ readonly primary: readonly ["du-bois-light-btn-primary", "du-bois-dark-btn-primary", "ant-btn-primary", "db-btn-primary"];
3
+ readonly dangerous: readonly ["du-bois-light-btn-dangerous", "du-bois-dark-btn-dangerous", "ant-btn-dangerous", "db-btn-danger"];
4
+ readonly block: readonly ["du-bois-light-btn-block", "du-bois-dark-btn-block", "ant-btn-block", "db-btn-block"];
5
+ readonly link: readonly ["du-bois-light-btn-link", "du-bois-dark-btn-link", "ant-btn-link", "db-btn-link"];
6
+ };
7
+ export type ButtonVariant = keyof typeof BUTTON_VARIANT_CLASS_TOKENS;
8
+ export declare const isPrimaryButton: (button: Element) => boolean;
9
+ export declare const isDangerousButton: (button: Element) => boolean;
10
+ export declare const isBlockButton: (button: Element) => boolean;
11
+ export declare const isLinkButton: (button: Element) => boolean;
@@ -0,0 +1,9 @@
1
+ import type { ReactNode } from "react";
2
+ export interface WizardStepNavigation {
3
+ goToStep: (step: number) => void;
4
+ currentStepIndex: number;
5
+ }
6
+ export declare function useWizardStepNavigation(): WizardStepNavigation | undefined;
7
+ export declare function WizardStepNavigationProvider({ goToStep, currentStepIndex, children }: WizardStepNavigation & {
8
+ children: ReactNode;
9
+ }): JSX.Element;
@@ -2,6 +2,7 @@ export * from "./Wizard";
2
2
  export * from "./WizardProps";
3
3
  export * from "./useWizardCurrentStep";
4
4
  export type { WizardStep } from "./WizardStep";
5
+ export * from "./WizardStepNavigation";
5
6
  export * from "./WizardModal";
6
7
  export * from "./DocumentationSidebar";
7
8
  export * from "./WizardStepContentWrapper";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@databricks/design-system",
3
- "version": "2.0.3",
3
+ "version": "2.0.5",
4
4
  "description": "DuBois Design System",
5
5
  "keywords": [],
6
6
  "license": "ISC",
@@ -26,6 +26,11 @@
26
26
  "import": "./dist/patterns.js",
27
27
  "require": "./dist/patterns.js"
28
28
  },
29
+ "./test-utils/rtl/buttonVariants": {
30
+ "types": "./dist-types/test-utils/rtl/buttonVariants.d.ts",
31
+ "import": "./dist/test-utils/rtl/buttonVariants.js",
32
+ "require": "./dist/test-utils/rtl/buttonVariants.js"
33
+ },
29
34
  "./test-utils/*": {
30
35
  "types": "./dist-types/test-utils/*/index.d.ts",
31
36
  "import": "./dist/test-utils/*",
@@ -79,6 +84,8 @@
79
84
  "test:watch": "yarn test --watch",
80
85
  "type-check": "tsc --noEmit --project ./tsconfig.json",
81
86
  "type-check:watch": "yarn type-check --watch",
87
+ "figma:publish": "figma connect publish",
88
+ "figma:unpublish": "figma connect unpublish",
82
89
  "check-all": "yarn type-check && yarn format:check && yarn lint",
83
90
  "fix-all": "yarn generate && yarn format && yarn indexes-regenerate && yarn lint:fix && yarn type-check",
84
91
  "prep-deps": ": # magic task to allow yarn ensure-deps plugin prepare dependencies of this package"
@@ -94,6 +101,7 @@
94
101
  "@emotion/cache": "^11.11.0",
95
102
  "@emotion/react": "^11.11.3",
96
103
  "@faker-js/faker": "^9.8.0",
104
+ "@figma/code-connect": "^2.0.0",
97
105
  "@jest/globals": "^30.0.2",
98
106
  "@svgr/cli": "^8.1.0",
99
107
  "@swc/core": "^1.15.47",
@@ -105,8 +113,8 @@
105
113
  "@types/jscodeshift": "^0.11.2",
106
114
  "@types/lodash": "^4.17.14",
107
115
  "@types/node": "24.12.0",
108
- "@types/react": "^17.0.50",
109
- "@types/react-dom": "^17.0.17",
116
+ "@types/react": "^18.3.31",
117
+ "@types/react-dom": "^18.3.7",
110
118
  "@types/react-resizable": "^3.0.3",
111
119
  "eslint-import-resolver-typescript": "^3.6.1",
112
120
  "glob": "^8.0.1",
@@ -132,6 +140,7 @@
132
140
  },
133
141
  "dependencies": {
134
142
  "@ant-design/icons": "^4.7.0",
143
+ "@databricks/testing-library": "1.0.0",
135
144
  "@emotion/unitless": "^0.8.1",
136
145
  "@floating-ui/dom": "^1.6.12",
137
146
  "@floating-ui/react": "^0.26.25",
@@ -163,7 +172,6 @@
163
172
  "@testing-library/dom": "^10.4.0",
164
173
  "@testing-library/react": "^16.1.0",
165
174
  "@testing-library/user-event": "^14.5.2",
166
- "@types/use-sync-external-store": "^1.5.0",
167
175
  "antd": "4.16.8",
168
176
  "chroma-js": "^2.4.2",
169
177
  "classnames": "^2.3.1",