@wordpress/components 25.9.1 → 25.10.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/CHANGELOG.md +32 -0
- package/build/alignment-matrix-control/cell.js +8 -5
- package/build/alignment-matrix-control/cell.js.map +1 -1
- package/build/alignment-matrix-control/index.js +27 -43
- package/build/alignment-matrix-control/index.js.map +1 -1
- package/build/alignment-matrix-control/utils.js +29 -9
- package/build/alignment-matrix-control/utils.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker-option.js +20 -39
- package/build/circular-option-picker/circular-option-picker-option.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker.js +11 -32
- package/build/circular-option-picker/circular-option-picker.js.map +1 -1
- package/build/circular-option-picker/types.js.map +1 -1
- package/build/color-palette/index.js +7 -2
- package/build/color-palette/index.js.map +1 -1
- package/build/color-picker/component.js +12 -2
- package/build/color-picker/component.js.map +1 -1
- package/build/color-picker/picker.js +77 -1
- package/build/color-picker/picker.js.map +1 -1
- package/build/color-picker/styles.js +8 -8
- package/build/color-picker/styles.js.map +1 -1
- package/build/color-picker/types.js.map +1 -1
- package/build/composite/v2.js +43 -0
- package/build/composite/v2.js.map +1 -0
- package/build/confirm-dialog/component.js +74 -8
- package/build/confirm-dialog/component.js.map +1 -1
- package/build/confirm-dialog/types.js.map +1 -1
- package/build/custom-gradient-picker/gradient-bar/control-points.js +13 -4
- package/build/custom-gradient-picker/gradient-bar/control-points.js.map +1 -1
- package/build/font-size-picker/utils.js +1 -1
- package/build/font-size-picker/utils.js.map +1 -1
- package/build/modal/index.js +45 -16
- package/build/modal/index.js.map +1 -1
- package/build/palette-edit/index.js +4 -0
- package/build/palette-edit/index.js.map +1 -1
- package/build/popover/index.js +34 -6
- package/build/popover/index.js.map +1 -1
- package/build/private-apis.js +9 -1
- package/build/private-apis.js.map +1 -1
- package/build/progress-bar/styles.js +5 -5
- package/build/progress-bar/styles.js.map +1 -1
- package/build/sandbox/index.js +1 -1
- package/build/sandbox/index.js.map +1 -1
- package/build/sandbox/index.native.js +1 -1
- package/build/sandbox/index.native.js.map +1 -1
- package/build/tabs/context.js +16 -0
- package/build/tabs/context.js.map +1 -0
- package/build/tabs/index.js +147 -0
- package/build/tabs/index.js.map +1 -0
- package/build/tabs/styles.js +38 -0
- package/build/tabs/styles.js.map +1 -0
- package/build/tabs/tab.js +46 -0
- package/build/tabs/tab.js.map +1 -0
- package/build/tabs/tablist.js +47 -0
- package/build/tabs/tablist.js.map +1 -0
- package/build/tabs/tabpanel.js +48 -0
- package/build/tabs/tabpanel.js.map +1 -0
- package/build/tabs/types.js +6 -0
- package/build/tabs/types.js.map +1 -0
- package/build/text/component.js +7 -6
- package/build/text/component.js.map +1 -1
- package/build/text/hook.js +6 -15
- package/build/text/hook.js.map +1 -1
- package/build/text/index.js.map +1 -1
- package/build/text/styles.js +7 -7
- package/build/text/styles.js.map +1 -1
- package/build/text/types.js.map +1 -1
- package/build/text/utils.js +17 -33
- package/build/text/utils.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-base/component.js +1 -0
- package/build/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
- package/build/toolbar/toolbar/index.js +17 -10
- package/build/toolbar/toolbar/index.js.map +1 -1
- package/build/toolbar/toolbar/types.js.map +1 -1
- package/build/tools-panel/tools-panel-item/hook.js +2 -2
- package/build/tools-panel/tools-panel-item/hook.js.map +1 -1
- package/build/tools-panel/types.js.map +1 -1
- package/build/unit-control/utils.js +108 -0
- package/build/unit-control/utils.js.map +1 -1
- package/build/utils/unit-values.js +1 -1
- package/build/utils/unit-values.js.map +1 -1
- package/build-module/alignment-matrix-control/cell.js +7 -4
- package/build-module/alignment-matrix-control/cell.js.map +1 -1
- package/build-module/alignment-matrix-control/index.js +27 -43
- package/build-module/alignment-matrix-control/index.js.map +1 -1
- package/build-module/alignment-matrix-control/utils.js +29 -8
- package/build-module/alignment-matrix-control/utils.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker-option.js +20 -39
- package/build-module/circular-option-picker/circular-option-picker-option.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker.js +10 -31
- package/build-module/circular-option-picker/circular-option-picker.js.map +1 -1
- package/build-module/circular-option-picker/types.js.map +1 -1
- package/build-module/color-palette/index.js +7 -2
- package/build-module/color-palette/index.js.map +1 -1
- package/build-module/color-picker/component.js +13 -3
- package/build-module/color-picker/component.js.map +1 -1
- package/build-module/color-picker/picker.js +78 -2
- package/build-module/color-picker/picker.js.map +1 -1
- package/build-module/color-picker/styles.js +8 -8
- package/build-module/color-picker/styles.js.map +1 -1
- package/build-module/color-picker/types.js.map +1 -1
- package/build-module/composite/v2.js +15 -0
- package/build-module/composite/v2.js.map +1 -0
- package/build-module/confirm-dialog/component.js +72 -7
- package/build-module/confirm-dialog/component.js.map +1 -1
- package/build-module/confirm-dialog/types.js.map +1 -1
- package/build-module/custom-gradient-picker/gradient-bar/control-points.js +13 -4
- package/build-module/custom-gradient-picker/gradient-bar/control-points.js.map +1 -1
- package/build-module/font-size-picker/utils.js +1 -1
- package/build-module/font-size-picker/utils.js.map +1 -1
- package/build-module/modal/index.js +47 -18
- package/build-module/modal/index.js.map +1 -1
- package/build-module/palette-edit/index.js +4 -0
- package/build-module/palette-edit/index.js.map +1 -1
- package/build-module/popover/index.js +34 -6
- package/build-module/popover/index.js.map +1 -1
- package/build-module/private-apis.js +9 -1
- package/build-module/private-apis.js.map +1 -1
- package/build-module/progress-bar/styles.js +5 -5
- package/build-module/progress-bar/styles.js.map +1 -1
- package/build-module/sandbox/index.js +1 -1
- package/build-module/sandbox/index.js.map +1 -1
- package/build-module/sandbox/index.native.js +1 -1
- package/build-module/sandbox/index.native.js.map +1 -1
- package/build-module/tabs/context.js +12 -0
- package/build-module/tabs/context.js.map +1 -0
- package/build-module/tabs/index.js +142 -0
- package/build-module/tabs/index.js.map +1 -0
- package/build-module/tabs/styles.js +36 -0
- package/build-module/tabs/styles.js.map +1 -0
- package/build-module/tabs/tab.js +43 -0
- package/build-module/tabs/tab.js.map +1 -0
- package/build-module/tabs/tablist.js +41 -0
- package/build-module/tabs/tablist.js.map +1 -0
- package/build-module/tabs/tabpanel.js +43 -0
- package/build-module/tabs/tabpanel.js.map +1 -0
- package/build-module/tabs/types.js +2 -0
- package/build-module/tabs/types.js.map +1 -0
- package/build-module/text/component.js +6 -6
- package/build-module/text/component.js.map +1 -1
- package/build-module/text/hook.js +11 -19
- package/build-module/text/hook.js.map +1 -1
- package/build-module/text/index.js.map +1 -1
- package/build-module/text/styles.js +7 -7
- package/build-module/text/styles.js.map +1 -1
- package/build-module/text/types.js.map +1 -1
- package/build-module/text/utils.js +17 -10
- package/build-module/text/utils.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-base/component.js +1 -0
- package/build-module/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
- package/build-module/toolbar/toolbar/index.js +18 -11
- package/build-module/toolbar/toolbar/index.js.map +1 -1
- package/build-module/toolbar/toolbar/types.js.map +1 -1
- package/build-module/tools-panel/tools-panel-item/hook.js +2 -2
- package/build-module/tools-panel/tools-panel-item/hook.js.map +1 -1
- package/build-module/tools-panel/types.js.map +1 -1
- package/build-module/unit-control/utils.js +108 -0
- package/build-module/unit-control/utils.js.map +1 -1
- package/build-module/utils/unit-values.js +1 -1
- package/build-module/utils/unit-values.js.map +1 -1
- package/build-style/style-rtl.css +16 -4
- package/build-style/style.css +16 -4
- package/build-types/alignment-matrix-control/cell.d.ts +1 -1
- package/build-types/alignment-matrix-control/cell.d.ts.map +1 -1
- package/build-types/alignment-matrix-control/index.d.ts.map +1 -1
- package/build-types/alignment-matrix-control/stories/index.story.d.ts.map +1 -1
- package/build-types/alignment-matrix-control/utils.d.ts +9 -9
- package/build-types/alignment-matrix-control/utils.d.ts.map +1 -1
- package/build-types/circular-option-picker/circular-option-picker-option.d.ts.map +1 -1
- package/build-types/circular-option-picker/circular-option-picker.d.ts.map +1 -1
- package/build-types/circular-option-picker/types.d.ts +4 -6
- package/build-types/circular-option-picker/types.d.ts.map +1 -1
- package/build-types/color-palette/index.d.ts.map +1 -1
- package/build-types/color-picker/component.d.ts.map +1 -1
- package/build-types/color-picker/picker.d.ts +1 -1
- package/build-types/color-picker/picker.d.ts.map +1 -1
- package/build-types/color-picker/styles.d.ts.map +1 -1
- package/build-types/color-picker/types.d.ts +3 -0
- package/build-types/color-picker/types.d.ts.map +1 -1
- package/build-types/composite/v2.d.ts +12 -0
- package/build-types/composite/v2.d.ts.map +1 -0
- package/build-types/confirm-dialog/component.d.ts +70 -29
- package/build-types/confirm-dialog/component.d.ts.map +1 -1
- package/build-types/confirm-dialog/stories/index.story.d.ts +11 -0
- package/build-types/confirm-dialog/stories/index.story.d.ts.map +1 -0
- package/build-types/confirm-dialog/test/index.d.ts +2 -0
- package/build-types/confirm-dialog/test/index.d.ts.map +1 -0
- package/build-types/confirm-dialog/types.d.ts +32 -10
- package/build-types/confirm-dialog/types.d.ts.map +1 -1
- package/build-types/custom-gradient-picker/gradient-bar/control-points.d.ts.map +1 -1
- package/build-types/font-size-picker/utils.d.ts.map +1 -1
- package/build-types/heading/stories/index.story.d.ts.map +1 -1
- package/build-types/modal/index.d.ts.map +1 -1
- package/build-types/palette-edit/index.d.ts.map +1 -1
- package/build-types/popover/index.d.ts +1 -1
- package/build-types/popover/index.d.ts.map +1 -1
- package/build-types/popover/stories/e2e/index.story.d.ts +1 -1
- package/build-types/private-apis.d.ts.map +1 -1
- package/build-types/progress-bar/styles.d.ts.map +1 -1
- package/build-types/sandbox/index.d.ts.map +1 -1
- package/build-types/tabs/context.d.ts +8 -0
- package/build-types/tabs/context.d.ts.map +1 -0
- package/build-types/tabs/index.d.ts +13 -0
- package/build-types/tabs/index.d.ts.map +1 -0
- package/build-types/tabs/stories/index.story.d.ts +20 -0
- package/build-types/tabs/stories/index.story.d.ts.map +1 -0
- package/build-types/tabs/styles.d.ts +17 -0
- package/build-types/tabs/styles.d.ts.map +1 -0
- package/build-types/tabs/tab.d.ts +10 -0
- package/build-types/tabs/tab.d.ts.map +1 -0
- package/build-types/tabs/tablist.d.ts +7 -0
- package/build-types/tabs/tablist.d.ts.map +1 -0
- package/build-types/tabs/tabpanel.d.ts +7 -0
- package/build-types/tabs/tabpanel.d.ts.map +1 -0
- package/build-types/tabs/test/index.d.ts +2 -0
- package/build-types/tabs/test/index.d.ts.map +1 -0
- package/build-types/tabs/types.d.ts +134 -0
- package/build-types/tabs/types.d.ts.map +1 -0
- package/build-types/text/component.d.ts +4 -2
- package/build-types/text/component.d.ts.map +1 -1
- package/build-types/text/hook.d.ts +171 -165
- package/build-types/text/hook.d.ts.map +1 -1
- package/build-types/text/index.d.ts +2 -2
- package/build-types/text/index.d.ts.map +1 -1
- package/build-types/text/stories/index.story.d.ts +21 -0
- package/build-types/text/stories/index.story.d.ts.map +1 -0
- package/build-types/text/styles.d.ts +7 -7
- package/build-types/text/styles.d.ts.map +1 -1
- package/build-types/text/types.d.ts +1 -1
- package/build-types/text/types.d.ts.map +1 -1
- package/build-types/text/utils.d.ts +56 -61
- package/build-types/text/utils.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control-option-base/component.d.ts.map +1 -1
- package/build-types/toolbar/stories/index.story.d.ts +5 -0
- package/build-types/toolbar/stories/index.story.d.ts.map +1 -1
- package/build-types/toolbar/toolbar/index.d.ts.map +1 -1
- package/build-types/toolbar/toolbar/types.d.ts +10 -0
- package/build-types/toolbar/toolbar/types.d.ts.map +1 -1
- package/build-types/tools-panel/tools-panel-item/hook.d.ts.map +1 -1
- package/build-types/tools-panel/types.d.ts +2 -0
- package/build-types/tools-panel/types.d.ts.map +1 -1
- package/build-types/unit-control/utils.d.ts.map +1 -1
- package/package.json +19 -19
- package/src/alignment-matrix-control/cell.tsx +6 -2
- package/src/alignment-matrix-control/index.tsx +31 -54
- package/src/alignment-matrix-control/stories/index.story.tsx +3 -7
- package/src/alignment-matrix-control/test/index.tsx +117 -18
- package/src/alignment-matrix-control/utils.tsx +33 -9
- package/src/button/style.scss +1 -2
- package/src/circular-option-picker/circular-option-picker-option.tsx +24 -38
- package/src/circular-option-picker/circular-option-picker.tsx +11 -28
- package/src/circular-option-picker/types.ts +6 -5
- package/src/color-palette/index.tsx +6 -1
- package/src/color-picker/component.tsx +25 -3
- package/src/color-picker/picker.tsx +96 -2
- package/src/color-picker/styles.ts +0 -1
- package/src/color-picker/types.ts +3 -0
- package/src/composite/v2.ts +22 -0
- package/src/confirm-dialog/README.md +1 -1
- package/src/confirm-dialog/component.tsx +79 -13
- package/src/confirm-dialog/stories/{index.story.js → index.story.tsx} +26 -24
- package/src/confirm-dialog/test/{index.js → index.tsx} +3 -3
- package/src/confirm-dialog/types.ts +32 -12
- package/src/custom-gradient-picker/gradient-bar/control-points.tsx +32 -25
- package/src/font-size-picker/utils.ts +2 -1
- package/src/heading/stories/index.story.tsx +2 -4
- package/src/modal/index.tsx +58 -22
- package/src/modal/test/index.tsx +29 -0
- package/src/notice/style.scss +0 -1
- package/src/palette-edit/index.tsx +4 -0
- package/src/popover/index.tsx +99 -57
- package/src/popover/style.scss +9 -0
- package/src/private-apis.ts +15 -1
- package/src/progress-bar/styles.ts +19 -4
- package/src/sandbox/index.native.js +1 -1
- package/src/sandbox/index.tsx +3 -1
- package/src/tabs/README.md +242 -0
- package/src/tabs/context.ts +13 -0
- package/src/tabs/index.tsx +167 -0
- package/src/tabs/stories/index.story.tsx +352 -0
- package/src/tabs/styles.ts +103 -0
- package/src/tabs/tab.tsx +39 -0
- package/src/tabs/tablist.tsx +40 -0
- package/src/tabs/tabpanel.tsx +42 -0
- package/src/tabs/test/index.tsx +1124 -0
- package/src/tabs/types.ts +142 -0
- package/src/text/README.md +2 -2
- package/src/text/{component.js → component.tsx} +10 -6
- package/src/text/{hook.js → hook.ts} +12 -15
- package/src/text/stories/index.story.tsx +80 -0
- package/src/text/types.ts +1 -6
- package/src/text/{utils.js → utils.ts} +40 -14
- package/src/toggle-group-control/test/__snapshots__/index.tsx.snap +8 -0
- package/src/toggle-group-control/toggle-group-control-option-base/component.tsx +1 -0
- package/src/toolbar/stories/index.story.tsx +15 -0
- package/src/toolbar/test/index.tsx +8 -0
- package/src/toolbar/toolbar/README.md +9 -0
- package/src/toolbar/toolbar/index.tsx +21 -12
- package/src/toolbar/toolbar/style.scss +9 -0
- package/src/toolbar/toolbar/types.ts +10 -0
- package/src/tools-panel/tools-panel/README.md +3 -0
- package/src/tools-panel/tools-panel-item/hook.ts +4 -6
- package/src/tools-panel/types.ts +2 -0
- package/src/unit-control/utils.ts +124 -0
- package/src/utils/unit-values.ts +1 -1
- package/tsconfig.tsbuildinfo +1 -1
- package/src/text/stories/index.story.js +0 -53
- /package/src/text/{index.js → index.ts} +0 -0
- /package/src/text/{styles.js → styles.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/cell.tsx"],"names":[],"mappings":";AAeA,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAE1D,MAAM,CAAC,OAAO,UAAU,IAAI,CAAE,EAC7B,QAAgB,EAChB,KAAK,EACL,GAAG,KAAK,EACR,EAAE,uBAAuB,CAAE,+BAA+B,EAAE,MAAM,EAAE,KAAK,CAAE,
|
|
1
|
+
{"version":3,"file":"cell.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/cell.tsx"],"names":[],"mappings":";AAeA,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAE1D,MAAM,CAAC,OAAO,UAAU,IAAI,CAAE,EAC7B,EAAE,EACF,QAAgB,EAChB,KAAK,EACL,GAAG,KAAK,EACR,EAAE,uBAAuB,CAAE,+BAA+B,EAAE,MAAM,EAAE,KAAK,CAAE,eAiB3E"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/index.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/index.tsx"],"names":[],"mappings":";AAiBA,OAAO,0BAA0B,MAAM,QAAQ,CAAC;AAEhD,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAC1D,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,SAAS,CAAC;AAE3D;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,sBAAsB,CAAE,EACvC,SAAS,EACT,EAAE,EACF,KAAwC,EACxC,YAA8B,EAC9B,KAAK,EACL,QAAQ,EACR,KAAU,EACV,GAAG,KAAK,EACR,EAAE,uBAAuB,CAAE,2BAA2B,EAAE,KAAK,EAAE,KAAK,CAAE,eAyDtE;yBAlEe,sBAAsB;;;AAsEtC,eAAe,sBAAsB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/alignment-matrix-control/stories/index.story.tsx"],"names":[],"mappings":";AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAW,MAAM,kBAAkB,CAAC;AAQtD;;GAEG;AACH,OAAO,sBAAsB,MAAM,IAAI,CAAC;AAExC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,UAAU,CAAC;AAE5D,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,sBAAsB,
|
|
1
|
+
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/alignment-matrix-control/stories/index.story.tsx"],"names":[],"mappings":";AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAW,MAAM,kBAAkB,CAAC;AAQtD;;GAEG;AACH,OAAO,sBAAsB,MAAM,IAAI,CAAC;AAExC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,UAAU,CAAC;AAE5D,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,sBAAsB,CAgB9C,CAAC;AACF,eAAe,IAAI,CAAC;AAqBpB,eAAO,MAAM,OAAO,iWAAsB,CAAC;AAE3C,eAAO,MAAM,gBAAgB,mBAkB5B,CAAC"}
|
|
@@ -5,14 +5,6 @@ import type { AlignmentMatrixControlValue } from './types';
|
|
|
5
5
|
export declare const GRID: AlignmentMatrixControlValue[][];
|
|
6
6
|
export declare const ALIGNMENT_LABEL: Record<AlignmentMatrixControlValue, string>;
|
|
7
7
|
export declare const ALIGNMENTS: AlignmentMatrixControlValue[];
|
|
8
|
-
/**
|
|
9
|
-
* Parses and transforms an incoming value to better match the alignment values
|
|
10
|
-
*
|
|
11
|
-
* @param value An alignment value to parse.
|
|
12
|
-
*
|
|
13
|
-
* @return The parsed value.
|
|
14
|
-
*/
|
|
15
|
-
export declare function transformValue(value: AlignmentMatrixControlValue): AlignmentMatrixControlValue;
|
|
16
8
|
/**
|
|
17
9
|
* Creates an item ID based on a prefix ID and an alignment value.
|
|
18
10
|
*
|
|
@@ -21,7 +13,15 @@ export declare function transformValue(value: AlignmentMatrixControlValue): Alig
|
|
|
21
13
|
*
|
|
22
14
|
* @return The item id.
|
|
23
15
|
*/
|
|
24
|
-
export declare function getItemId(prefixId: string, value
|
|
16
|
+
export declare function getItemId(prefixId: string, value?: AlignmentMatrixControlValue): string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* Extracts an item value from its ID
|
|
19
|
+
*
|
|
20
|
+
* @param prefixId An ID prefix to remove
|
|
21
|
+
* @param id An item ID
|
|
22
|
+
* @return The item value
|
|
23
|
+
*/
|
|
24
|
+
export declare function getItemValue(prefixId: string, id?: string | null): AlignmentMatrixControlValue | undefined;
|
|
25
25
|
/**
|
|
26
26
|
* Retrieves the alignment index from a value.
|
|
27
27
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/utils.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/alignment-matrix-control/utils.tsx"],"names":[],"mappings":"AAKA;;GAEG;AACH,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,SAAS,CAAC;AAE3D,eAAO,MAAM,IAAI,EAAE,2BAA2B,EAAE,EAI/C,CAAC;AAGF,eAAO,MAAM,eAAe,EAAE,MAAM,CAAE,2BAA2B,EAAE,MAAM,CAWxE,CAAC;AAGF,eAAO,MAAM,UAAU,+BAAc,CAAC;AAuBtC;;;;;;;GAOG;AACH,wBAAgB,SAAS,CACxB,QAAQ,EAAE,MAAM,EAChB,KAAK,CAAC,EAAE,2BAA2B,sBAOnC;AAED;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,CAAC,EAAE,MAAM,GAAG,IAAI,2CAGjE;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAChC,SAAS,GAAE,2BAAsC,sBAOjD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"circular-option-picker-option.d.ts","sourceRoot":"","sources":["../../src/circular-option-picker/circular-option-picker-option.tsx"],"names":[],"mappings":";AAoBA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"circular-option-picker-option.d.ts","sourceRoot":"","sources":["../../src/circular-option-picker/circular-option-picker-option.tsx"],"names":[],"mappings":";AAoBA,OAAO,KAAK,EAAE,WAAW,EAAsC,MAAM,SAAS,CAAC;AAwD/E,wBAAgB,MAAM,CAAE,EACvB,SAAS,EACT,UAAU,EACV,iBAAsB,EACtB,WAAW,EACX,GAAG,eAAe,EAClB,EAAE,WAAW,eAwCb"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"circular-option-picker.d.ts","sourceRoot":"","sources":["../../src/circular-option-picker/circular-option-picker.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"circular-option-picker.d.ts","sourceRoot":"","sources":["../../src/circular-option-picker/circular-option-picker.tsx"],"names":[],"mappings":";AAgBA,OAAO,KAAK,EACX,yBAAyB,EAGzB,MAAM,SAAS,CAAC;AA+GjB,iBAAS,oBAAoB,CAAE,KAAK,EAAE,yBAAyB,eA8C9D;kBA9CQ,oBAAoB;;;;;;AAqD7B,eAAe,oBAAoB,CAAC"}
|
|
@@ -12,7 +12,7 @@ import type { Icon } from '@wordpress/icons';
|
|
|
12
12
|
import type { ButtonAsButtonProps } from '../button/types';
|
|
13
13
|
import type { DropdownProps } from '../dropdown/types';
|
|
14
14
|
import type { WordPressComponentProps } from '../context';
|
|
15
|
-
import type {
|
|
15
|
+
import type { CompositeStore } from '../composite/v2';
|
|
16
16
|
type CommonCircularOptionPickerProps = {
|
|
17
17
|
/**
|
|
18
18
|
* An ID to apply to the component.
|
|
@@ -90,12 +90,10 @@ export type OptionProps = Omit<WordPressComponentProps<ButtonAsButtonProps, 'but
|
|
|
90
90
|
isSelected?: boolean;
|
|
91
91
|
selectedIconProps?: Omit<React.ComponentProps<typeof Icon>, 'icon' | 'size'>;
|
|
92
92
|
};
|
|
93
|
-
export type
|
|
93
|
+
export type CircularOptionPickerCompositeStore = CompositeStore;
|
|
94
94
|
export type CircularOptionPickerContextProps = {
|
|
95
|
-
isComposite?: false;
|
|
96
95
|
baseId?: string;
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
} & CircularOptionPickerCompositeState);
|
|
96
|
+
compositeStore?: CircularOptionPickerCompositeStore;
|
|
97
|
+
};
|
|
100
98
|
export {};
|
|
101
99
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/circular-option-picker/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC;;GAEG;AACH,O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E,OAAO,IAAI,CAAE,EACnC,MAAM,GAAG,MAAM,CACf,CAAC;CACF,CAAC;AAEF,MAAM,MAAM,kCAAkC,GAAG,cAAc,CAAC;AAChE,MAAM,MAAM,gCAAgC,GAAG;IAC9C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,cAAc,CAAC,EAAE,kCAAkC,CAAC;CACpD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/color-palette/index.tsx"],"names":[],"mappings":";AA0BA,OAAO,KAAK,EAEX,iBAAiB,EACjB,8BAA8B,EAI9B,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AA2G1D,wBAAgB,yBAAyB,CAAE,EAC1C,mBAAmB,EACnB,YAAY,EAAE,oBAAoB,EAClC,GAAG,KAAK,EACR,EAAE,8BAA8B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/color-palette/index.tsx"],"names":[],"mappings":";AA0BA,OAAO,KAAK,EAEX,iBAAiB,EACjB,8BAA8B,EAI9B,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AA2G1D,wBAAgB,yBAAyB,CAAE,EAC1C,mBAAmB,EACnB,YAAY,EAAE,oBAAoB,EAClC,GAAG,KAAK,EACR,EAAE,8BAA8B,eAgChC;AAwLD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,eAAO,MAAM,YAAY,mIAAwC,CAAC;AAElE,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/color-picker/component.tsx"],"names":[],"mappings":";AA+BA,OAAO,KAAK,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/color-picker/component.tsx"],"names":[],"mappings":";AA+BA,OAAO,KAAK,EAAoB,SAAS,EAAE,MAAM,SAAS,CAAC;AA0G3D,eAAO,MAAM,WAAW;;;;;;wTAGvB,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -3,5 +3,5 @@
|
|
|
3
3
|
* Internal dependencies
|
|
4
4
|
*/
|
|
5
5
|
import type { PickerProps } from './types';
|
|
6
|
-
export declare const Picker: ({ color, enableAlpha, onChange }: PickerProps) => JSX.Element;
|
|
6
|
+
export declare const Picker: ({ color, enableAlpha, onChange, onDragStart, onDragEnd, containerEl, }: PickerProps) => JSX.Element;
|
|
7
7
|
//# sourceMappingURL=picker.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"picker.d.ts","sourceRoot":"","sources":["../../src/color-picker/picker.tsx"],"names":[],"mappings":";AAUA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"picker.d.ts","sourceRoot":"","sources":["../../src/color-picker/picker.tsx"],"names":[],"mappings":";AAUA;;GAEG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAuF3C,eAAO,MAAM,MAAM,2EAOhB,WAAW,gBAgBb,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../src/color-picker/styles.ts"],"names":[],"mappings":";AAsBA,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;UAIhC,CAAC;AAEF,eAAO,MAAM,aAAa;;UAWzB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAGxB,CAAC;AASF,eAAO,MAAM,6BAA6B;;;yGAKzC,CAAC;AAEF,eAAO,MAAM,kCAAkC;;;;;;;UAG9C,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;UAK7B,CAAC;AAEF,eAAO,MAAM,eAAe;;;
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../src/color-picker/styles.ts"],"names":[],"mappings":";AAsBA,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;UAIhC,CAAC;AAEF,eAAO,MAAM,aAAa;;UAWzB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAGxB,CAAC;AASF,eAAO,MAAM,6BAA6B;;;yGAKzC,CAAC;AAEF,eAAO,MAAM,kCAAkC;;;;;;;UAG9C,CAAC;AAEF,eAAO,MAAM,iBAAiB;;;;UAK7B,CAAC;AAEF,eAAO,MAAM,eAAe;;;yGA4C3B,CAAC;AAEF,eAAO,MAAM,UAAU;;UAStB,CAAC"}
|
|
@@ -44,6 +44,9 @@ export interface PickerProps {
|
|
|
44
44
|
color: Colord;
|
|
45
45
|
enableAlpha: boolean;
|
|
46
46
|
onChange: (nextColor: Colord) => void;
|
|
47
|
+
containerEl: HTMLElement | null;
|
|
48
|
+
onDragStart?: (event: MouseEvent) => void;
|
|
49
|
+
onDragEnd?: (event: MouseEvent) => void;
|
|
47
50
|
}
|
|
48
51
|
export interface ColorInputProps {
|
|
49
52
|
colorType: 'hsl' | 'hex' | 'rgb';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/color-picker/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EACX,MAAM,EACN,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,MAAM,QAAQ,CAAC;AAChB,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAChD;;GAEG;AACH,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAC1D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE,MAAM,MAAM,SAAS,GAAG,KAAK,GA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CAAE,KAAK,EAAE,MAAM,KAAM,IAAI,CAAC;CACpC;AAED,MAAM,WAAW,aAAa;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAE,SAAS,EAAE,MAAM,KAAM,IAAI,CAAC;IACxC,WAAW,EAAE,OAAO,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAE,SAAS,EAAE,MAAM,KAAM,IAAI,CAAC;IACxC,WAAW,EAAE,OAAO,CAAC;CACrB;AAED,MAAM,WAAW,aAAa;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAE,SAAS,EAAE,MAAM,KAAM,IAAI,CAAC;IACxC,WAAW,EAAE,OAAO,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,MAAM,WAAW,GACpB,MAAM,GACN;IACA,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC1B,GAAG,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC1B,GAAG,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC1B;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,MAAM,EAAE,KAAK,CAAC;CACb,CAAC;AAEL;;GAEG;AACH,MAAM,WAAW,WAAW;IAC3B,KAAK,CAAC,EAAE,WAAW,CAAC;IACpB;;OAEG;IACH,gBAAgB,EAAE,CAAE,MAAM,EAAE,WAAW,KAAM,IAAI,CAAC;IAClD;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,YAAY,EAAE,OAAO,CAAC;IACtB,QAAQ,CAAC,EAAE,KAAK,CAAC;CACjB"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Composite is a component that may contain navigable items represented by
|
|
3
|
+
* CompositeItem. It's inspired by the WAI-ARIA Composite Role and implements
|
|
4
|
+
* all the keyboard navigation mechanisms to ensure that there's only one
|
|
5
|
+
* tab stop for the whole Composite element. This means that it can behave as
|
|
6
|
+
* a roving tabindex or aria-activedescendant container.
|
|
7
|
+
*
|
|
8
|
+
* @see https://ariakit.org/components/composite
|
|
9
|
+
*/
|
|
10
|
+
export { Composite, CompositeGroup, CompositeGroupLabel, CompositeItem, CompositeRow, useCompositeStore, } from '@ariakit/react';
|
|
11
|
+
export type { CompositeStore } from '@ariakit/react';
|
|
12
|
+
//# sourceMappingURL=v2.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"v2.d.ts","sourceRoot":"","sources":["../../src/composite/v2.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EACN,SAAS,EACT,cAAc,EACd,mBAAmB,EACnB,aAAa,EACb,YAAY,EACZ,iBAAiB,GACjB,MAAM,gBAAgB,CAAC;AAGxB,YAAY,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -1,31 +1,72 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
2
|
+
import type { ConfirmDialogProps } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* `ConfirmDialog` is built of top of [`Modal`](/packages/components/src/modal/README.md)
|
|
5
|
+
* and displays a confirmation dialog, with _confirm_ and _cancel_ buttons.
|
|
6
|
+
* The dialog is confirmed by clicking the _confirm_ button or by pressing the `Enter` key.
|
|
7
|
+
* It is cancelled (closed) by clicking the _cancel_ button, by pressing the `ESC` key, or by
|
|
8
|
+
* clicking outside the dialog focus (i.e, the overlay).
|
|
9
|
+
*
|
|
10
|
+
* `ConfirmDialog` has two main implicit modes: controlled and uncontrolled.
|
|
11
|
+
*
|
|
12
|
+
* UnControlled:
|
|
13
|
+
*
|
|
14
|
+
* Allows the component to be used standalone, just by declaring it as part of another React's component render method:
|
|
15
|
+
* - It will be automatically open (displayed) upon mounting;
|
|
16
|
+
* - It will be automatically closed when clicking the _cancel_ button, by pressing the `ESC` key, or by clicking outside the dialog focus (i.e, the overlay);
|
|
17
|
+
* - `onCancel` is not mandatory but can be passed. Even if passed, the dialog will still be able to close itself.
|
|
18
|
+
*
|
|
19
|
+
* Activating this mode is as simple as omitting the `isOpen` prop. The only mandatory prop, in this case, is the `onConfirm` callback. The message is passed as the `children`. You can pass any JSX you'd like, which allows to further format the message or include sub-component if you'd like:
|
|
20
|
+
*
|
|
21
|
+
* ```jsx
|
|
22
|
+
* import { __experimentalConfirmDialog as ConfirmDialog } from '@wordpress/components';
|
|
23
|
+
*
|
|
24
|
+
* function Example() {
|
|
25
|
+
* return (
|
|
26
|
+
* <ConfirmDialog onConfirm={ () => console.debug( ' Confirmed! ' ) }>
|
|
27
|
+
* Are you sure? <strong>This action cannot be undone!</strong>
|
|
28
|
+
* </ConfirmDialog>
|
|
29
|
+
* );
|
|
30
|
+
* }
|
|
31
|
+
* ```
|
|
32
|
+
*
|
|
33
|
+
*
|
|
34
|
+
* Controlled mode:
|
|
35
|
+
* Let the parent component control when the dialog is open/closed. It's activated when a
|
|
36
|
+
* boolean value is passed to `isOpen`:
|
|
37
|
+
* - It will not be automatically closed. You need to let it know when to open/close by updating the value of the `isOpen` prop;
|
|
38
|
+
* - Both `onConfirm` and the `onCancel` callbacks are mandatory props in this mode;
|
|
39
|
+
* - You'll want to update the state that controls `isOpen` by updating it from the `onCancel` and `onConfirm` callbacks.
|
|
40
|
+
*
|
|
41
|
+
*```jsx
|
|
42
|
+
* import { __experimentalConfirmDialog as ConfirmDialog } from '@wordpress/components';
|
|
43
|
+
* import { useState } from '@wordpress/element';
|
|
44
|
+
*
|
|
45
|
+
* function Example() {
|
|
46
|
+
* const [ isOpen, setIsOpen ] = useState( true );
|
|
47
|
+
*
|
|
48
|
+
* const handleConfirm = () => {
|
|
49
|
+
* console.debug( 'Confirmed!' );
|
|
50
|
+
* setIsOpen( false );
|
|
51
|
+
* };
|
|
52
|
+
*
|
|
53
|
+
* const handleCancel = () => {
|
|
54
|
+
* console.debug( 'Cancelled!' );
|
|
55
|
+
* setIsOpen( false );
|
|
56
|
+
* };
|
|
57
|
+
*
|
|
58
|
+
* return (
|
|
59
|
+
* <ConfirmDialog
|
|
60
|
+
* isOpen={ isOpen }
|
|
61
|
+
* onConfirm={ handleConfirm }
|
|
62
|
+
* onCancel={ handleCancel }
|
|
63
|
+
* >
|
|
64
|
+
* Are you sure? <strong>This action cannot be undone!</strong>
|
|
65
|
+
* </ConfirmDialog>
|
|
66
|
+
* );
|
|
67
|
+
* }
|
|
68
|
+
* ```
|
|
69
|
+
*/
|
|
70
|
+
export declare const ConfirmDialog: import("../context").WordPressComponent<"div", ConfirmDialogProps & import("react").RefAttributes<any>, false>;
|
|
71
|
+
export default ConfirmDialog;
|
|
31
72
|
//# sourceMappingURL=component.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/confirm-dialog/component.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/confirm-dialog/component.tsx"],"names":[],"mappings":";AAUA,OAAO,KAAK,EAAE,kBAAkB,EAAoB,MAAM,SAAS,CAAC;AA6GpE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkEG;AACH,eAAO,MAAM,aAAa,gHAGzB,CAAC;AACF,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* External dependencies
|
|
4
|
+
*/
|
|
5
|
+
import type { Meta } from '@storybook/react';
|
|
6
|
+
import { ConfirmDialog } from '../component';
|
|
7
|
+
declare const meta: Meta<typeof ConfirmDialog>;
|
|
8
|
+
export default meta;
|
|
9
|
+
export declare const Default: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").ConfirmDialogProps & import("react").RefAttributes<any> & Omit<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>>, "as" | keyof import("react").RefAttributes<any> | keyof import("../types").ConfirmDialogProps>>;
|
|
10
|
+
export declare const WithCustomButtonLabels: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").ConfirmDialogProps & import("react").RefAttributes<any> & Omit<Pick<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof import("react").HTMLAttributes<HTMLDivElement>>, "as" | keyof import("react").RefAttributes<any> | keyof import("../types").ConfirmDialogProps>>;
|
|
11
|
+
//# sourceMappingURL=index.story.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/confirm-dialog/stories/index.story.tsx"],"names":[],"mappings":";AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAW,MAAM,kBAAkB,CAAC;AAWtD,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE7C,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,aAAa,CAerC,CAAC;AAEF,eAAe,IAAI,CAAC;AAsCpB,eAAO,MAAM,OAAO,wbAAsB,CAAC;AA+C3C,eAAO,MAAM,sBAAsB,wbAAsB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/confirm-dialog/test/index.tsx"],"names":[],"mappings":""}
|
|
@@ -7,20 +7,42 @@ import type { MouseEvent, KeyboardEvent, ReactNode } from 'react';
|
|
|
7
7
|
*/
|
|
8
8
|
import type { ModalProps } from '../modal/types';
|
|
9
9
|
export type DialogInputEvent = Parameters<ModalProps['onRequestClose']>[0] | KeyboardEvent<HTMLDivElement> | MouseEvent<HTMLButtonElement>;
|
|
10
|
-
type
|
|
10
|
+
export type ConfirmDialogProps = {
|
|
11
|
+
/**
|
|
12
|
+
* The actual message for the dialog. It's passed as children and any valid `ReactNode` is accepted.
|
|
13
|
+
*/
|
|
11
14
|
children: ReactNode;
|
|
15
|
+
/**
|
|
16
|
+
* The callback that's called when the user confirms.
|
|
17
|
+
* A confirmation can happen when the `OK` button is clicked or when `Enter` is pressed.
|
|
18
|
+
*/
|
|
12
19
|
onConfirm: (event: DialogInputEvent) => void;
|
|
20
|
+
/**
|
|
21
|
+
* The optional custom text to display as the confirmation button's label.
|
|
22
|
+
*/
|
|
13
23
|
confirmButtonText?: string;
|
|
24
|
+
/**
|
|
25
|
+
* The optional custom text to display as the cancellation button's label.
|
|
26
|
+
*/
|
|
14
27
|
cancelButtonText?: string;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
28
|
+
/**
|
|
29
|
+
* The callback that's called when the user cancels. A cancellation can happen
|
|
30
|
+
* when the `Cancel` button is clicked, when the `ESC` key is pressed, or when
|
|
31
|
+
* a click outside of the dialog focus is detected (i.e. in the overlay).
|
|
32
|
+
*
|
|
33
|
+
* It's not required if `isOpen` is not set (uncontrolled mode), as the component
|
|
34
|
+
* will take care of closing itself, but you can still pass a callback if something
|
|
35
|
+
* must be done upon cancelling (the component will still close itself in this case).
|
|
36
|
+
*
|
|
37
|
+
* If `isOpen` is set (controlled mode), then it's required, and you need to set
|
|
38
|
+
* the state that defines `isOpen` to `false` as part of this callback if you want the
|
|
39
|
+
* dialog to close when the user cancels.
|
|
40
|
+
*/
|
|
21
41
|
onCancel?: (event: DialogInputEvent) => void;
|
|
22
|
-
|
|
42
|
+
/**
|
|
43
|
+
* Defines if the dialog is open (displayed) or closed (not rendered/displayed).
|
|
44
|
+
* It also implicitly toggles the controlled mode if set or the uncontrolled mode if it's not set.
|
|
45
|
+
*/
|
|
46
|
+
isOpen?: boolean;
|
|
23
47
|
};
|
|
24
|
-
export type OwnProps = ControlledProps | UncontrolledProps;
|
|
25
|
-
export {};
|
|
26
48
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/confirm-dialog/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElE;;GAEG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAEjD,MAAM,MAAM,gBAAgB,GACzB,UAAU,CAAE,UAAU,CAAE,gBAAgB,CAAE,CAAE,CAAE,CAAC,CAAE,GACjD,aAAa,CAAE,cAAc,CAAE,GAC/B,UAAU,CAAE,iBAAiB,CAAE,CAAC;AAEnC,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/confirm-dialog/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElE;;GAEG;AACH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAEjD,MAAM,MAAM,gBAAgB,GACzB,UAAU,CAAE,UAAU,CAAE,gBAAgB,CAAE,CAAE,CAAE,CAAC,CAAE,GACjD,aAAa,CAAE,cAAc,CAAE,GAC/B,UAAU,CAAE,iBAAiB,CAAE,CAAC;AAEnC,MAAM,MAAM,kBAAkB,GAAG;IAChC;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IACpB;;;OAGG;IACH,SAAS,EAAE,CAAE,KAAK,EAAE,gBAAgB,KAAM,IAAI,CAAC;IAC/C;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;;;;;;;;;OAYG;IACH,QAAQ,CAAC,EAAE,CAAE,KAAK,EAAE,gBAAgB,KAAM,IAAI,CAAC;IAC/C;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"control-points.d.ts","sourceRoot":"","sources":["../../../src/custom-gradient-picker/gradient-bar/control-points.tsx"],"names":[],"mappings":";AAqCA,OAAO,KAAK,EAGX,kBAAkB,EAClB,gBAAgB,EAChB,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"control-points.d.ts","sourceRoot":"","sources":["../../../src/custom-gradient-picker/gradient-bar/control-points.tsx"],"names":[],"mappings":";AAqCA,OAAO,KAAK,EAGX,kBAAkB,EAClB,gBAAgB,EAChB,MAAM,UAAU,CAAC;AA6ElB,iBAAS,aAAa,CAAE,EACvB,aAAa,EACb,YAAY,EACZ,oBAAoB,EACpB,oBAAoB,EACpB,KAAK,EAAE,aAAa,EACpB,QAAQ,EACR,yBAAyB,EACzB,wBAAwB,EACxB,iCAAiC,GACjC,EAAE,kBAAkB,eAyMpB;kBAnNQ,aAAa;;;AA+RtB,eAAe,aAAa,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/font-size-picker/utils.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,OAAO,KAAK,EAAE,mBAAmB,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAG7D;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAC/B,KAAK,EAAE,WAAW,CAAE,mBAAmB,CAAE,OAAO,CAAE,CAAE,
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/font-size-picker/utils.ts"],"names":[],"mappings":"AAKA;;GAEG;AACH,OAAO,KAAK,EAAE,mBAAmB,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAG7D;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAC/B,KAAK,EAAE,WAAW,CAAE,mBAAmB,CAAE,OAAO,CAAE,CAAE,WAKpD;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAE,SAAS,EAAE,QAAQ,EAAE,6BAavD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/heading/stories/index.story.tsx"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAEtD;;GAEG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC;AAE7B,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,OAAO,
|
|
1
|
+
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/heading/stories/index.story.tsx"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAEtD;;GAEG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC;AAE7B,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,OAAO,CAoB/B,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,eAAO,MAAM,OAAO,EAAE,OAAO,CAAE,OAAO,OAAO,CAE5C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/modal/index.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/modal/index.tsx"],"names":[],"mappings":";AA0CA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAiU1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,eAAO,MAAM,KAAK,uGAAiC,CAAC;AAEpD,eAAe,KAAK,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/palette-edit/index.tsx"],"names":[],"mappings":";AAmDA,OAAO,KAAK,EAOX,gBAAgB,EAChB,cAAc,EACd,MAAM,SAAS,CAAC;AAejB;;;;;;;;;;GAUG;AACH,wBAAgB,kBAAkB,CACjC,QAAQ,EAAE,cAAc,EAAE,EAC1B,UAAU,EAAE,MAAM,UAqBlB;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/palette-edit/index.tsx"],"names":[],"mappings":";AAmDA,OAAO,KAAK,EAOX,gBAAgB,EAChB,cAAc,EACd,MAAM,SAAS,CAAC;AAejB;;;;;;;;;;GAUG;AACH,wBAAgB,kBAAkB,CACjC,QAAQ,EAAE,cAAc,EAAE,EAC1B,UAAU,EAAE,MAAM,UAqBlB;AAkQD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,WAAW,CAAE,EAC5B,SAAS,EACT,MAAoB,EACpB,QAAQ,EACR,YAAY,EACZ,wBAA4B,EAC5B,YAAY,EACZ,mBAAmB,EACnB,QAAQ,EACR,UAAe,EACf,YAAY,GACZ,EAAE,gBAAgB,eA8OlB;AAED,eAAe,WAAW,CAAC"}
|
|
@@ -30,6 +30,6 @@ export declare const SLOT_NAME = "Popover";
|
|
|
30
30
|
* ```
|
|
31
31
|
*
|
|
32
32
|
*/
|
|
33
|
-
export declare const Popover: import("react").
|
|
33
|
+
export declare const Popover: import("../context").WordPressComponent<import("react").ElementType<any>, Omit<WordPressComponentProps<PopoverProps, "div", false>, "style" | "transition" | "inherit" | "initial" | "onDrag" | "onDragEnd" | "onDragStart" | "onAnimationStart" | "layout" | "drag" | "exit" | "custom" | "viewport" | "transformTemplate" | "transformValues" | "variants" | "onBeforeLayoutMeasure" | "onLayoutMeasure" | "onUpdate" | "onAnimationComplete" | "onPan" | "onPanStart" | "onPanSessionStart" | "onPanEnd" | "onTap" | "onTapStart" | "onTapCancel" | "whileTap" | "whileHover" | "onHoverStart" | "onHoverEnd" | "whileFocus" | "whileInView" | "onViewportEnter" | "onViewportLeave" | "whileDrag" | "dragDirectionLock" | "dragPropagation" | "dragConstraints" | "dragElastic" | "dragMomentum" | "dragTransition" | "dragControls" | "dragSnapToOrigin" | "dragListener" | "onMeasureDragConstraints" | "_dragX" | "_dragY" | "onDirectionLock" | "onDragTransitionEnd" | "layoutId" | "onLayoutAnimationStart" | "onLayoutAnimationComplete" | "layoutDependency" | "layoutScroll" | "layoutRoot" | "ignoreStrict"> & import("react").RefAttributes<any>, boolean>;
|
|
34
34
|
export default Popover;
|
|
35
35
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/popover/index.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/popover/index.tsx"],"names":[],"mappings":";AA4DA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAC1D,OAAO,KAAK,EACX,YAAY,EAGZ,MAAM,SAAS,CAAC;AAIjB;;;;GAIG;AACH,eAAO,MAAM,SAAS,YAAY,CAAC;AAobnC;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,OAAO,2mCAAkD,CAAC;AAqBvE,eAAe,OAAO,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
declare const _default: {
|
|
3
3
|
title: string;
|
|
4
|
-
component: import("react").
|
|
4
|
+
component: import("../../../context").WordPressComponent<import("react").ElementType<any>, Omit<import("../../../context").WordPressComponentProps<import("../../types").PopoverProps, "div", false>, "style" | "transition" | "inherit" | "initial" | "onDrag" | "onDragEnd" | "onDragStart" | "onAnimationStart" | "layout" | "drag" | "exit" | "custom" | "viewport" | "transformTemplate" | "transformValues" | "variants" | "onBeforeLayoutMeasure" | "onLayoutMeasure" | "onUpdate" | "onAnimationComplete" | "onPan" | "onPanStart" | "onPanSessionStart" | "onPanEnd" | "onTap" | "onTapStart" | "onTapCancel" | "whileTap" | "whileHover" | "onHoverStart" | "onHoverEnd" | "whileFocus" | "whileInView" | "onViewportEnter" | "onViewportLeave" | "whileDrag" | "dragDirectionLock" | "dragPropagation" | "dragConstraints" | "dragElastic" | "dragMomentum" | "dragTransition" | "dragControls" | "dragSnapToOrigin" | "dragListener" | "onMeasureDragConstraints" | "_dragX" | "_dragY" | "onDirectionLock" | "onDragTransitionEnd" | "layoutId" | "onLayoutAnimationStart" | "onLayoutAnimationComplete" | "layoutDependency" | "layoutScroll" | "layoutRoot" | "ignoreStrict"> & import("react").RefAttributes<any>, boolean>;
|
|
5
5
|
};
|
|
6
6
|
export default _default;
|
|
7
7
|
export declare const Default: () => JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"private-apis.d.ts","sourceRoot":"","sources":["../src/private-apis.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"private-apis.d.ts","sourceRoot":"","sources":["../src/private-apis.ts"],"names":[],"mappings":"AAmCA,eAAO,MAAQ,IAAI,2CAAE,MAAM,sBAIzB,CAAC;AAEH,eAAO,MAAM,WAAW,IAAK,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../src/progress-bar/styles.ts"],"names":[],"mappings":";AAqBA,eAAO,MAAM,yBAAyB,KAAK,CAAC;AAE5C,eAAO,MAAM,KAAK;;;
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../src/progress-bar/styles.ts"],"names":[],"mappings":";AAqBA,eAAO,MAAM,yBAAyB,KAAK,CAAC;AAE5C,eAAO,MAAM,KAAK;;;yGAiBjB,CAAC;AAEF,eAAO,MAAM,SAAS;;;;qBACJ,OAAO;;yGAgCxB,CAAC;AAEF,eAAO,MAAM,eAAe;;;2HAO3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/sandbox/index.tsx"],"names":[],"mappings":";AAWA;;GAEG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/sandbox/index.tsx"],"names":[],"mappings":";AAWA;;GAEG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAsG5C;;;;;;;;;;GAUG;AACH,iBAAS,OAAO,CAAE,EACjB,IAAS,EACT,KAAU,EACV,IAAI,EACJ,MAAW,EACX,OAAY,EACZ,OAAO,EACP,QAAQ,GACR,EAAE,YAAY,eAgKd;AAED,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* Internal dependencies
|
|
4
|
+
*/
|
|
5
|
+
import type { TabsContextProps } from './types';
|
|
6
|
+
export declare const TabsContext: import("react").Context<TabsContextProps>;
|
|
7
|
+
export declare const useTabsContext: () => TabsContextProps;
|
|
8
|
+
//# sourceMappingURL=context.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../src/tabs/context.ts"],"names":[],"mappings":";AAKA;;GAEG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,eAAO,MAAM,WAAW,2CAAiD,CAAC;AAE1E,eAAO,MAAM,cAAc,wBAAkC,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* Internal dependencies
|
|
4
|
+
*/
|
|
5
|
+
import type { TabsProps } from './types';
|
|
6
|
+
declare function Tabs({ selectOnMove, initialTabId, orientation, onSelect, children, selectedTabId, }: TabsProps): JSX.Element;
|
|
7
|
+
declare namespace Tabs {
|
|
8
|
+
var TabList: import("react").ForwardRefExoticComponent<import("./types").TabListProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
9
|
+
var Tab: import("react").ForwardRefExoticComponent<import("./types").TabProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
10
|
+
var TabPanel: import("react").ForwardRefExoticComponent<import("./types").TabPanelProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
11
|
+
}
|
|
12
|
+
export default Tabs;
|
|
13
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tabs/index.tsx"],"names":[],"mappings":";AAYA;;GAEG;AACH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAMzC,iBAAS,IAAI,CAAE,EACd,YAAmB,EACnB,YAAY,EACZ,WAA0B,EAC1B,QAAQ,EACR,QAAQ,EACR,aAAa,GACb,EAAE,SAAS,eAqIX;kBA5IQ,IAAI;;;;;AAiJb,eAAe,IAAI,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* External dependencies
|
|
3
|
+
*/
|
|
4
|
+
import type { Meta } from '@storybook/react';
|
|
5
|
+
/**
|
|
6
|
+
* Internal dependencies
|
|
7
|
+
*/
|
|
8
|
+
import Tabs from '..';
|
|
9
|
+
declare const meta: Meta<typeof Tabs>;
|
|
10
|
+
export default meta;
|
|
11
|
+
export declare const Default: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
12
|
+
export declare const DisabledTab: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
13
|
+
export declare const WithTabIconsAndTooltips: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
14
|
+
export declare const ManualActivation: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
15
|
+
export declare const UsingSlotFill: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
16
|
+
export declare const InsertCustomElements: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
17
|
+
export declare const ControlledMode: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
18
|
+
export declare const TabBecomesDisabled: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
19
|
+
export declare const TabGetsRemoved: import("@storybook/types").AnnotatedStoryFn<import("@storybook/react/dist/types-0a347bb9").R, import("../types").TabsProps>;
|
|
20
|
+
//# sourceMappingURL=index.story.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.story.d.ts","sourceRoot":"","sources":["../../../src/tabs/stories/index.story.tsx"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,IAAI,EAAW,MAAM,kBAAkB,CAAC;AAQtD;;GAEG;AACH,OAAO,IAAI,MAAM,IAAI,CAAC;AAKtB,QAAA,MAAM,IAAI,EAAE,IAAI,CAAE,OAAO,IAAI,CAQ5B,CAAC;AACF,eAAe,IAAI,CAAC;AAuBpB,eAAO,MAAM,OAAO,6HAAsB,CAAC;AAwB3C,eAAO,MAAM,WAAW,6HAAiC,CAAC;AAqC1D,eAAO,MAAM,uBAAuB,6HAEnC,CAAC;AAEF,eAAO,MAAM,gBAAgB,6HAAsB,CAAC;AA0CpD,eAAO,MAAM,aAAa,6HAAmC,CAAC;AA6D9D,eAAO,MAAM,oBAAoB,6HAAiC,CAAC;AA+DnE,eAAO,MAAM,cAAc,6HAAoC,CAAC;AAqChE,eAAO,MAAM,kBAAkB,6HAAwC,CAAC;AAgCxE,eAAO,MAAM,cAAc,6HAAoC,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import * as Ariakit from '@ariakit/react';
|
|
3
|
+
export declare const TabListWrapper: import("@emotion/styled").StyledComponent<{
|
|
4
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
5
|
+
as?: import("react").ElementType<any> | undefined;
|
|
6
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
|
+
export declare const Tab: import("@emotion/styled").StyledComponent<Ariakit.TabOptions<"button"> & {
|
|
8
|
+
[index: `data-${string}`]: unknown;
|
|
9
|
+
wrapElement?: import("@ariakit/react-core/cjs/utils/types").WrapElement | undefined;
|
|
10
|
+
children?: import("@ariakit/react-core/cjs/utils/types").Children<any>;
|
|
11
|
+
render?: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | import("@ariakit/react-core/cjs/utils/types").RenderProp<import("react").HTMLAttributes<any> & import("react").RefAttributes<any>> | undefined;
|
|
12
|
+
} & Omit<Pick<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "key" | keyof import("react").ButtonHTMLAttributes<HTMLButtonElement>> & {
|
|
13
|
+
ref?: ((instance: HTMLButtonElement | null) => void) | import("react").RefObject<HTMLButtonElement> | null | undefined;
|
|
14
|
+
}, "children" | keyof Ariakit.TabOptions<"button">> & {
|
|
15
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
16
|
+
}, {}, {}>;
|
|
17
|
+
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../src/tabs/styles.ts"],"names":[],"mappings":";AAKA,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAC;AAS1C,eAAO,MAAM,cAAc;;;yGAO1B,CAAC;AAEF,eAAO,MAAM,GAAG;;;;;;;;;UA+Ef,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WordPress dependencies
|
|
3
|
+
*/
|
|
4
|
+
/// <reference types="react" />
|
|
5
|
+
/**
|
|
6
|
+
* Internal dependencies
|
|
7
|
+
*/
|
|
8
|
+
import type { TabProps } from './types';
|
|
9
|
+
export declare const Tab: import("react").ForwardRefExoticComponent<TabProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
10
|
+
//# sourceMappingURL=tab.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tab.d.ts","sourceRoot":"","sources":["../../src/tabs/tab.tsx"],"names":[],"mappings":"AAAA;;GAEG;;AAIH;;GAEG;AACH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAKxC,eAAO,MAAM,GAAG,wGAwBb,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* Internal dependencies
|
|
4
|
+
*/
|
|
5
|
+
import type { TabListProps } from './types';
|
|
6
|
+
export declare const TabList: import("react").ForwardRefExoticComponent<TabListProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
7
|
+
//# sourceMappingURL=tablist.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tablist.d.ts","sourceRoot":"","sources":["../../src/tabs/tablist.tsx"],"names":[],"mappings":";AAYA;;GAEG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAI5C,eAAO,MAAM,OAAO,yGAoBnB,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* Internal dependencies
|
|
4
|
+
*/
|
|
5
|
+
import type { TabPanelProps } from './types';
|
|
6
|
+
export declare const TabPanel: import("react").ForwardRefExoticComponent<TabPanelProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
7
|
+
//# sourceMappingURL=tabpanel.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tabpanel.d.ts","sourceRoot":"","sources":["../../src/tabs/tabpanel.tsx"],"names":[],"mappings":";AAYA;;GAEG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAK7C,eAAO,MAAM,QAAQ,0GAqBpB,CAAC"}
|