@wordpress/components 28.11.0 → 28.13.1-next.082ed6819.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 +68 -0
- package/build/autocomplete/autocompleter-ui.js +1 -0
- package/build/autocomplete/autocompleter-ui.js.map +1 -1
- package/build/border-box-control/border-box-control/component.js +1 -0
- package/build/border-box-control/border-box-control/component.js.map +1 -1
- package/build/border-box-control/border-box-control-split-controls/component.js +2 -1
- package/build/border-box-control/border-box-control-split-controls/component.js.map +1 -1
- package/build/border-control/border-control/component.js +2 -1
- package/build/border-control/border-control/component.js.map +1 -1
- package/build/border-control/border-control/hook.js +3 -1
- package/build/border-control/border-control/hook.js.map +1 -1
- package/build/border-control/border-control-dropdown/component.js +1 -1
- package/build/border-control/border-control-dropdown/component.js.map +1 -1
- package/build/border-control/types.js.map +1 -1
- package/build/box-control/all-input-control.js +1 -0
- package/build/box-control/all-input-control.js.map +1 -1
- package/build/box-control/axial-input-controls.js +1 -0
- package/build/box-control/axial-input-controls.js.map +1 -1
- package/build/box-control/input-controls.js +1 -0
- package/build/box-control/input-controls.js.map +1 -1
- package/build/color-palette/index.js +2 -0
- package/build/color-palette/index.js.map +1 -1
- package/build/color-picker/color-copy-button.js +6 -4
- package/build/color-picker/color-copy-button.js.map +1 -1
- package/build/color-picker/component.js +1 -0
- package/build/color-picker/component.js.map +1 -1
- package/build/color-picker/styles.js +21 -28
- package/build/color-picker/styles.js.map +1 -1
- package/build/combobox-control/index.js +17 -12
- package/build/combobox-control/index.js.map +1 -1
- package/build/composite/hover.js +1 -1
- package/build/composite/hover.js.map +1 -1
- package/build/composite/typeahead.js +1 -1
- package/build/composite/typeahead.js.map +1 -1
- package/build/dashicon/types.js.map +1 -1
- package/build/dimension-control/index.js +7 -0
- package/build/dimension-control/index.js.map +1 -1
- package/build/disabled/index.js +8 -1
- package/build/disabled/index.js.map +1 -1
- package/build/duotone-picker/duotone-picker.js +2 -0
- package/build/duotone-picker/duotone-picker.js.map +1 -1
- package/build/font-size-picker/font-size-picker-toggle-group.js +1 -0
- package/build/font-size-picker/font-size-picker-toggle-group.js.map +1 -1
- package/build/font-size-picker/index.js +7 -0
- package/build/font-size-picker/index.js.map +1 -1
- package/build/form-file-upload/index.js +7 -1
- package/build/form-file-upload/index.js.map +1 -1
- package/build/form-token-field/token.js +1 -0
- package/build/form-token-field/token.js.map +1 -1
- package/build/gradient-picker/index.js +34 -32
- package/build/gradient-picker/index.js.map +1 -1
- package/build/gradient-picker/types.js.map +1 -1
- package/build/guide/page-control.js +1 -0
- package/build/guide/page-control.js.map +1 -1
- package/build/menu/styles.js +16 -16
- package/build/menu/styles.js.map +1 -1
- package/build/menu-item/index.js +1 -0
- package/build/menu-item/index.js.map +1 -1
- package/build/modal/index.js +2 -2
- package/build/modal/index.js.map +1 -1
- package/build/notice/index.js +2 -0
- package/build/notice/index.js.map +1 -1
- package/build/palette-edit/index.js +5 -0
- package/build/palette-edit/index.js.map +1 -1
- package/build/panel/body.js +1 -0
- package/build/panel/body.js.map +1 -1
- package/build/popover/index.js +4 -1
- package/build/popover/index.js.map +1 -1
- package/build/private-apis.js +0 -2
- package/build/private-apis.js.map +1 -1
- package/build/radio-group/radio.js +6 -0
- package/build/radio-group/radio.js.map +1 -1
- package/build/radio-group/types.js.map +1 -1
- package/build/range-control/index.js +11 -0
- package/build/range-control/index.js.map +1 -1
- package/build/range-control/types.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/fill.js +14 -31
- package/build/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js +13 -4
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/slot.js +11 -9
- package/build/slot-fill/bubbles-virtually/slot.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/use-slot.js +1 -8
- package/build/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build/slot-fill/fill.js +7 -24
- package/build/slot-fill/fill.js.map +1 -1
- package/build/slot-fill/index.js +5 -10
- package/build/slot-fill/index.js.map +1 -1
- package/build/slot-fill/provider.js +2 -2
- package/build/slot-fill/provider.js.map +1 -1
- package/build/slot-fill/slot.js +37 -77
- package/build/slot-fill/slot.js.map +1 -1
- package/build/slot-fill/types.js.map +1 -1
- package/build/snackbar/index.js +2 -1
- package/build/snackbar/index.js.map +1 -1
- package/build/tabs/tablist.js +13 -2
- package/build/tabs/tablist.js.map +1 -1
- package/build/text-control/index.js +7 -0
- package/build/text-control/index.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/component.js +10 -1
- package/build/toggle-group-control/toggle-group-control/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option/component.js +1 -0
- package/build/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-icon/component.js +1 -1
- package/build/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
- package/build/toggle-group-control/types.js.map +1 -1
- package/build/utils/deprecated-36px-size.js +3 -2
- package/build/utils/deprecated-36px-size.js.map +1 -1
- package/build-module/autocomplete/autocompleter-ui.js +1 -0
- package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
- package/build-module/border-box-control/border-box-control/component.js +1 -0
- package/build-module/border-box-control/border-box-control/component.js.map +1 -1
- package/build-module/border-box-control/border-box-control-split-controls/component.js +2 -1
- package/build-module/border-box-control/border-box-control-split-controls/component.js.map +1 -1
- package/build-module/border-control/border-control/component.js +2 -1
- package/build-module/border-control/border-control/component.js.map +1 -1
- package/build-module/border-control/border-control/hook.js +3 -1
- package/build-module/border-control/border-control/hook.js.map +1 -1
- package/build-module/border-control/border-control-dropdown/component.js +1 -1
- package/build-module/border-control/border-control-dropdown/component.js.map +1 -1
- package/build-module/border-control/types.js.map +1 -1
- package/build-module/box-control/all-input-control.js +1 -0
- package/build-module/box-control/all-input-control.js.map +1 -1
- package/build-module/box-control/axial-input-controls.js +1 -0
- package/build-module/box-control/axial-input-controls.js.map +1 -1
- package/build-module/box-control/input-controls.js +1 -0
- package/build-module/box-control/input-controls.js.map +1 -1
- package/build-module/color-palette/index.js +2 -0
- package/build-module/color-palette/index.js.map +1 -1
- package/build-module/color-picker/color-copy-button.js +6 -4
- package/build-module/color-picker/color-copy-button.js.map +1 -1
- package/build-module/color-picker/component.js +1 -0
- package/build-module/color-picker/component.js.map +1 -1
- package/build-module/color-picker/styles.js +20 -27
- package/build-module/color-picker/styles.js.map +1 -1
- package/build-module/combobox-control/index.js +18 -13
- package/build-module/combobox-control/index.js.map +1 -1
- package/build-module/composite/hover.js +1 -1
- package/build-module/composite/hover.js.map +1 -1
- package/build-module/composite/typeahead.js +1 -1
- package/build-module/composite/typeahead.js.map +1 -1
- package/build-module/dashicon/types.js.map +1 -1
- package/build-module/dimension-control/index.js +7 -0
- package/build-module/dimension-control/index.js.map +1 -1
- package/build-module/disabled/index.js +8 -1
- package/build-module/disabled/index.js.map +1 -1
- package/build-module/duotone-picker/duotone-picker.js +2 -0
- package/build-module/duotone-picker/duotone-picker.js.map +1 -1
- package/build-module/font-size-picker/font-size-picker-toggle-group.js +1 -0
- package/build-module/font-size-picker/font-size-picker-toggle-group.js.map +1 -1
- package/build-module/font-size-picker/index.js +7 -0
- package/build-module/font-size-picker/index.js.map +1 -1
- package/build-module/form-file-upload/index.js +7 -1
- package/build-module/form-file-upload/index.js.map +1 -1
- package/build-module/form-token-field/token.js +1 -0
- package/build-module/form-token-field/token.js.map +1 -1
- package/build-module/gradient-picker/index.js +34 -32
- package/build-module/gradient-picker/index.js.map +1 -1
- package/build-module/gradient-picker/types.js.map +1 -1
- package/build-module/guide/page-control.js +1 -0
- package/build-module/guide/page-control.js.map +1 -1
- package/build-module/menu/styles.js +16 -16
- package/build-module/menu/styles.js.map +1 -1
- package/build-module/menu-item/index.js +1 -0
- package/build-module/menu-item/index.js.map +1 -1
- package/build-module/modal/index.js +2 -2
- package/build-module/modal/index.js.map +1 -1
- package/build-module/notice/index.js +2 -0
- package/build-module/notice/index.js.map +1 -1
- package/build-module/palette-edit/index.js +5 -0
- package/build-module/palette-edit/index.js.map +1 -1
- package/build-module/panel/body.js +1 -0
- package/build-module/panel/body.js.map +1 -1
- package/build-module/popover/index.js +4 -1
- package/build-module/popover/index.js.map +1 -1
- package/build-module/private-apis.js +0 -2
- package/build-module/private-apis.js.map +1 -1
- package/build-module/radio-group/radio.js +6 -0
- package/build-module/radio-group/radio.js.map +1 -1
- package/build-module/radio-group/types.js.map +1 -1
- package/build-module/range-control/index.js +11 -0
- package/build-module/range-control/index.js.map +1 -1
- package/build-module/range-control/types.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/fill.js +15 -32
- package/build-module/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js +13 -4
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/slot.js +11 -9
- package/build-module/slot-fill/bubbles-virtually/slot.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/use-slot.js +2 -9
- package/build-module/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build-module/slot-fill/fill.js +7 -24
- package/build-module/slot-fill/fill.js.map +1 -1
- package/build-module/slot-fill/index.js +5 -8
- package/build-module/slot-fill/index.js.map +1 -1
- package/build-module/slot-fill/provider.js +2 -3
- package/build-module/slot-fill/provider.js.map +1 -1
- package/build-module/slot-fill/slot.js +38 -78
- package/build-module/slot-fill/slot.js.map +1 -1
- package/build-module/slot-fill/types.js.map +1 -1
- package/build-module/snackbar/index.js +2 -1
- package/build-module/snackbar/index.js.map +1 -1
- package/build-module/tabs/tablist.js +13 -2
- package/build-module/tabs/tablist.js.map +1 -1
- package/build-module/text-control/index.js +7 -0
- package/build-module/text-control/index.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/component.js +10 -1
- package/build-module/toggle-group-control/toggle-group-control/component.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option/component.js +1 -0
- package/build-module/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-icon/component.js +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
- package/build-module/toggle-group-control/types.js.map +1 -1
- package/build-module/utils/deprecated-36px-size.js +3 -2
- package/build-module/utils/deprecated-36px-size.js.map +1 -1
- package/build-style/style-rtl.css +15 -36
- package/build-style/style.css +15 -36
- package/build-types/autocomplete/autocompleter-ui.d.ts.map +1 -1
- package/build-types/base-control/stories/index.story.d.ts.map +1 -1
- package/build-types/border-box-control/border-box-control/component.d.ts.map +1 -1
- package/build-types/border-box-control/border-box-control-split-controls/component.d.ts.map +1 -1
- package/build-types/border-control/border-control/component.d.ts +1 -0
- package/build-types/border-control/border-control/component.d.ts.map +1 -1
- package/build-types/border-control/border-control/hook.d.ts.map +1 -1
- package/build-types/border-control/border-control-dropdown/component.d.ts.map +1 -1
- package/build-types/border-control/border-control-style-picker/component.d.ts.map +1 -1
- package/build-types/border-control/stories/index.story.d.ts +10 -5
- package/build-types/border-control/stories/index.story.d.ts.map +1 -1
- package/build-types/border-control/types.d.ts +7 -0
- package/build-types/border-control/types.d.ts.map +1 -1
- package/build-types/box-control/all-input-control.d.ts.map +1 -1
- package/build-types/box-control/axial-input-controls.d.ts.map +1 -1
- package/build-types/box-control/input-controls.d.ts.map +1 -1
- package/build-types/box-control/styles/box-control-styles.d.ts +2 -1
- package/build-types/box-control/styles/box-control-styles.d.ts.map +1 -1
- package/build-types/checkbox-control/stories/index.story.d.ts.map +1 -1
- package/build-types/circular-option-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/color-indicator/stories/index.story.d.ts.map +1 -1
- package/build-types/color-palette/index.d.ts.map +1 -1
- package/build-types/color-palette/stories/index.story.d.ts.map +1 -1
- package/build-types/color-picker/color-copy-button.d.ts.map +1 -1
- package/build-types/color-picker/component.d.ts.map +1 -1
- package/build-types/color-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/color-picker/styles.d.ts +2 -4
- package/build-types/color-picker/styles.d.ts.map +1 -1
- package/build-types/combobox-control/index.d.ts +1 -0
- package/build-types/combobox-control/index.d.ts.map +1 -1
- package/build-types/combobox-control/stories/index.story.d.ts.map +1 -1
- package/build-types/composite/typeahead.d.ts.map +1 -1
- package/build-types/confirm-dialog/stories/index.story.d.ts.map +1 -1
- package/build-types/custom-gradient-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/custom-select-control/stories/index.story.d.ts.map +1 -1
- package/build-types/custom-select-control-v2/stories/index.story.d.ts.map +1 -1
- package/build-types/dashicon/types.d.ts +1 -1
- package/build-types/dashicon/types.d.ts.map +1 -1
- package/build-types/date-time/stories/date-time.story.d.ts.map +1 -1
- package/build-types/date-time/stories/date.story.d.ts.map +1 -1
- package/build-types/date-time/stories/time.story.d.ts.map +1 -1
- package/build-types/dimension-control/index.d.ts +1 -0
- package/build-types/dimension-control/index.d.ts.map +1 -1
- package/build-types/disabled/index.d.ts +8 -1
- package/build-types/disabled/index.d.ts.map +1 -1
- package/build-types/disabled/stories/index.story.d.ts.map +1 -1
- package/build-types/drop-zone/stories/index.story.d.ts.map +1 -1
- package/build-types/dropdown/stories/index.story.d.ts.map +1 -1
- package/build-types/dropdown-menu/stories/index.story.d.ts.map +1 -1
- package/build-types/duotone-picker/duotone-picker.d.ts.map +1 -1
- package/build-types/external-link/stories/index.story.d.ts.map +1 -1
- package/build-types/font-size-picker/font-size-picker-toggle-group.d.ts.map +1 -1
- package/build-types/font-size-picker/index.d.ts.map +1 -1
- package/build-types/font-size-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/form-file-upload/index.d.ts.map +1 -1
- package/build-types/form-file-upload/stories/index.story.d.ts.map +1 -1
- package/build-types/form-token-field/stories/index.story.d.ts.map +1 -1
- package/build-types/form-token-field/token.d.ts.map +1 -1
- package/build-types/gradient-picker/index.d.ts +32 -32
- package/build-types/gradient-picker/index.d.ts.map +1 -1
- package/build-types/gradient-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/gradient-picker/types.d.ts +1 -5
- package/build-types/gradient-picker/types.d.ts.map +1 -1
- package/build-types/guide/page-control.d.ts.map +1 -1
- package/build-types/h-stack/stories/index.story.d.ts.map +1 -1
- package/build-types/heading/stories/index.story.d.ts.map +1 -1
- package/build-types/input-control/stories/index.story.d.ts.map +1 -1
- package/build-types/lock-unlock.d.ts +2 -2
- package/build-types/menu/stories/index.story.d.ts.map +1 -1
- package/build-types/menu-group/stories/index.story.d.ts.map +1 -1
- package/build-types/menu-item/index.d.ts.map +1 -1
- package/build-types/menu-item/stories/index.story.d.ts.map +1 -1
- package/build-types/menu-items-choice/stories/index.story.d.ts.map +1 -1
- package/build-types/modal/stories/index.story.d.ts.map +1 -1
- package/build-types/navigator/stories/index.story.d.ts.map +1 -1
- package/build-types/notice/index.d.ts.map +1 -1
- package/build-types/notice/stories/index.story.d.ts.map +1 -1
- package/build-types/number-control/stories/index.story.d.ts.map +1 -1
- package/build-types/palette-edit/index.d.ts.map +1 -1
- package/build-types/panel/body.d.ts.map +1 -1
- package/build-types/placeholder/stories/index.story.d.ts.map +1 -1
- package/build-types/popover/index.d.ts.map +1 -1
- package/build-types/popover/stories/index.story.d.ts.map +1 -1
- package/build-types/private-apis.d.ts.map +1 -1
- package/build-types/progress-bar/stories/index.story.d.ts.map +1 -1
- package/build-types/radio-control/stories/index.story.d.ts.map +1 -1
- package/build-types/radio-group/radio.d.ts +4 -2
- package/build-types/radio-group/radio.d.ts.map +1 -1
- package/build-types/radio-group/stories/index.story.d.ts.map +1 -1
- package/build-types/radio-group/types.d.ts +5 -1
- package/build-types/radio-group/types.d.ts.map +1 -1
- package/build-types/range-control/index.d.ts +3 -1
- package/build-types/range-control/index.d.ts.map +1 -1
- package/build-types/range-control/stories/index.story.d.ts.map +1 -1
- package/build-types/range-control/types.d.ts +7 -0
- package/build-types/range-control/types.d.ts.map +1 -1
- package/build-types/responsive-wrapper/stories/index.story.d.ts.map +1 -1
- package/build-types/search-control/stories/index.story.d.ts.map +1 -1
- package/build-types/select-control/stories/index.story.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/fill.d.ts +1 -1
- package/build-types/slot-fill/bubbles-virtually/fill.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/slot-fill-provider.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/slot.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/use-slot-fills.d.ts +1 -1
- package/build-types/slot-fill/bubbles-virtually/use-slot-fills.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/use-slot.d.ts +3 -7
- package/build-types/slot-fill/bubbles-virtually/use-slot.d.ts.map +1 -1
- package/build-types/slot-fill/fill.d.ts.map +1 -1
- package/build-types/slot-fill/index.d.ts +5 -12
- package/build-types/slot-fill/index.d.ts.map +1 -1
- package/build-types/slot-fill/provider.d.ts.map +1 -1
- package/build-types/slot-fill/slot.d.ts +1 -1
- package/build-types/slot-fill/slot.d.ts.map +1 -1
- package/build-types/slot-fill/types.d.ts +15 -18
- package/build-types/slot-fill/types.d.ts.map +1 -1
- package/build-types/slot-fill/use-slot.d.ts +1 -1
- package/build-types/slot-fill/use-slot.d.ts.map +1 -1
- package/build-types/snackbar/index.d.ts.map +1 -1
- package/build-types/snackbar/stories/index.story.d.ts.map +1 -1
- package/build-types/snackbar/stories/list.story.d.ts.map +1 -1
- package/build-types/spinner/stories/index.story.d.ts.map +1 -1
- package/build-types/tabs/tablist.d.ts.map +1 -1
- package/build-types/text/stories/index.story.d.ts.map +1 -1
- package/build-types/text-control/index.d.ts +1 -0
- package/build-types/text-control/index.d.ts.map +1 -1
- package/build-types/text-control/stories/index.story.d.ts.map +1 -1
- package/build-types/text-highlight/stories/index.story.d.ts.map +1 -1
- package/build-types/textarea-control/stories/index.story.d.ts.map +1 -1
- package/build-types/tip/stories/index.story.d.ts.map +1 -1
- package/build-types/toggle-control/stories/index.story.d.ts.map +1 -1
- package/build-types/toggle-group-control/stories/index.story.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control/component.d.ts +2 -0
- package/build-types/toggle-group-control/toggle-group-control/component.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control-option/component.d.ts +1 -0
- package/build-types/toggle-group-control/toggle-group-control-option/component.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control-option-icon/component.d.ts +1 -1
- package/build-types/toggle-group-control/types.d.ts +7 -0
- package/build-types/toggle-group-control/types.d.ts.map +1 -1
- package/build-types/tools-panel/stories/index.story.d.ts.map +1 -1
- package/build-types/tooltip/stories/index.story.d.ts.map +1 -1
- package/build-types/tree-grid/stories/index.story.d.ts.map +1 -1
- package/build-types/tree-select/stories/index.story.d.ts.map +1 -1
- package/build-types/truncate/stories/index.story.d.ts.map +1 -1
- package/build-types/unit-control/stories/index.story.d.ts.map +1 -1
- package/build-types/utils/deprecated-36px-size.d.ts +3 -2
- package/build-types/utils/deprecated-36px-size.d.ts.map +1 -1
- package/build-types/v-stack/stories/index.story.d.ts.map +1 -1
- package/package.json +21 -21
- package/src/autocomplete/autocompleter-ui.tsx +1 -0
- package/src/base-control/stories/index.story.tsx +2 -1
- package/src/border-box-control/border-box-control/component.tsx +1 -0
- package/src/border-box-control/border-box-control-split-controls/component.tsx +1 -0
- package/src/border-control/border-control/component.tsx +1 -0
- package/src/border-control/border-control/hook.ts +2 -0
- package/src/border-control/border-control-dropdown/component.tsx +1 -1
- package/src/border-control/types.ts +7 -0
- package/src/box-control/all-input-control.tsx +1 -0
- package/src/box-control/axial-input-controls.tsx +1 -0
- package/src/box-control/input-controls.tsx +1 -0
- package/src/checkbox-control/stories/index.story.tsx +2 -1
- package/src/circular-option-picker/stories/index.story.tsx +2 -1
- package/src/color-indicator/stories/index.story.tsx +2 -1
- package/src/color-palette/index.tsx +5 -1
- package/src/color-palette/stories/index.story.tsx +2 -1
- package/src/color-picker/color-copy-button.tsx +8 -10
- package/src/color-picker/component.tsx +1 -0
- package/src/color-picker/stories/index.story.tsx +2 -1
- package/src/color-picker/styles.ts +0 -13
- package/src/combobox-control/README.md +1 -0
- package/src/combobox-control/index.tsx +19 -13
- package/src/combobox-control/stories/index.story.tsx +3 -1
- package/src/combobox-control/style.scss +0 -6
- package/src/combobox-control/test/index.tsx +7 -1
- package/src/composite/hover.tsx +1 -1
- package/src/composite/typeahead.tsx +3 -1
- package/src/confirm-dialog/stories/index.story.tsx +2 -1
- package/src/custom-gradient-picker/stories/index.story.tsx +2 -1
- package/src/custom-select-control/stories/index.story.tsx +2 -1
- package/src/custom-select-control-v2/stories/index.story.tsx +2 -1
- package/src/dashicon/types.ts +0 -2
- package/src/date-time/stories/date-time.story.tsx +2 -1
- package/src/date-time/stories/date.story.tsx +2 -1
- package/src/date-time/stories/time.story.tsx +2 -1
- package/src/dimension-control/README.md +1 -0
- package/src/dimension-control/index.tsx +8 -0
- package/src/dimension-control/stories/index.story.tsx +1 -0
- package/src/dimension-control/test/__snapshots__/index.test.js.snap +24 -24
- package/src/dimension-control/test/index.test.js +7 -1
- package/src/disabled/README.md +9 -7
- package/src/disabled/index.tsx +8 -1
- package/src/disabled/stories/index.story.tsx +1 -0
- package/src/drop-zone/stories/index.story.tsx +2 -1
- package/src/dropdown/stories/index.story.tsx +2 -1
- package/src/dropdown-menu/stories/index.story.tsx +2 -1
- package/src/duotone-picker/duotone-picker.tsx +2 -0
- package/src/external-link/stories/index.story.tsx +2 -1
- package/src/font-size-picker/README.md +1 -0
- package/src/font-size-picker/font-size-picker-toggle-group.tsx +1 -0
- package/src/font-size-picker/index.tsx +8 -0
- package/src/font-size-picker/stories/index.story.tsx +1 -0
- package/src/font-size-picker/test/index.tsx +5 -1
- package/src/form-file-upload/index.tsx +13 -1
- package/src/form-file-upload/stories/index.story.tsx +2 -1
- package/src/form-token-field/stories/index.story.tsx +2 -1
- package/src/form-token-field/style.scss +8 -12
- package/src/form-token-field/token.tsx +1 -0
- package/src/gradient-picker/README.md +107 -69
- package/src/gradient-picker/docs-manifest.json +5 -0
- package/src/gradient-picker/index.tsx +34 -32
- package/src/gradient-picker/stories/index.story.tsx +2 -1
- package/src/gradient-picker/types.ts +3 -5
- package/src/guide/page-control.tsx +1 -0
- package/src/guide/style.scss +4 -6
- package/src/h-stack/stories/index.story.tsx +2 -1
- package/src/heading/stories/index.story.tsx +2 -1
- package/src/higher-order/with-constrained-tabbing/README.md +13 -3
- package/src/higher-order/with-focus-return/README.md +9 -2
- package/src/input-control/stories/index.story.tsx +2 -1
- package/src/menu/stories/index.story.tsx +2 -1
- package/src/menu/styles.ts +1 -1
- package/src/menu-group/stories/index.story.tsx +2 -1
- package/src/menu-item/index.tsx +1 -0
- package/src/menu-item/stories/index.story.tsx +2 -1
- package/src/menu-item/test/__snapshots__/index.js.snap +4 -4
- package/src/menu-items-choice/stories/index.story.tsx +2 -1
- package/src/modal/index.tsx +2 -2
- package/src/modal/stories/index.story.tsx +3 -2
- package/src/navigator/stories/index.story.tsx +2 -1
- package/src/notice/index.tsx +2 -0
- package/src/notice/stories/index.story.tsx +7 -2
- package/src/notice/test/__snapshots__/index.tsx.snap +4 -4
- package/src/number-control/stories/index.story.tsx +2 -1
- package/src/palette-edit/index.tsx +5 -0
- package/src/panel/body.tsx +1 -0
- package/src/placeholder/stories/index.story.tsx +1 -0
- package/src/popover/index.tsx +3 -0
- package/src/popover/stories/index.story.tsx +2 -1
- package/src/private-apis.ts +0 -2
- package/src/progress-bar/stories/index.story.tsx +2 -1
- package/src/radio-control/stories/index.story.tsx +2 -1
- package/src/radio-group/README.md +8 -8
- package/src/radio-group/radio.tsx +7 -0
- package/src/radio-group/stories/index.story.tsx +16 -4
- package/src/radio-group/types.ts +6 -1
- package/src/range-control/README.md +4 -3
- package/src/range-control/index.tsx +11 -0
- package/src/range-control/stories/index.story.tsx +9 -1
- package/src/range-control/test/index.tsx +7 -1
- package/src/range-control/types.ts +7 -0
- package/src/responsive-wrapper/stories/index.story.tsx +2 -1
- package/src/search-control/stories/index.story.tsx +2 -1
- package/src/select-control/stories/index.story.tsx +2 -1
- package/src/slot-fill/README.md +26 -15
- package/src/slot-fill/bubbles-virtually/fill.tsx +18 -28
- package/src/slot-fill/bubbles-virtually/slot-fill-provider.tsx +26 -16
- package/src/slot-fill/bubbles-virtually/slot.tsx +13 -9
- package/src/slot-fill/bubbles-virtually/use-slot.ts +3 -26
- package/src/slot-fill/fill.ts +7 -22
- package/src/slot-fill/index.tsx +5 -7
- package/src/slot-fill/provider.tsx +8 -17
- package/src/slot-fill/slot.tsx +48 -85
- package/src/slot-fill/types.ts +14 -51
- package/src/snackbar/index.tsx +2 -1
- package/src/snackbar/stories/index.story.tsx +2 -1
- package/src/snackbar/stories/list.story.tsx +2 -1
- package/src/snackbar/style.scss +7 -16
- package/src/spinner/stories/index.story.tsx +2 -1
- package/src/tabs/tablist.tsx +13 -2
- package/src/text/stories/index.story.tsx +2 -1
- package/src/text-control/README.md +1 -0
- package/src/text-control/index.tsx +8 -0
- package/src/text-control/stories/index.story.tsx +3 -1
- package/src/text-control/test/text-control.tsx +7 -1
- package/src/text-highlight/stories/index.story.tsx +2 -1
- package/src/textarea-control/stories/index.story.tsx +2 -1
- package/src/tip/stories/index.story.tsx +2 -1
- package/src/toggle-control/stories/index.story.tsx +2 -1
- package/src/toggle-group-control/stories/index.story.tsx +3 -1
- package/src/toggle-group-control/test/__snapshots__/index.tsx.snap +12 -12
- package/src/toggle-group-control/test/index.tsx +7 -1
- package/src/toggle-group-control/toggle-group-control/README.md +2 -1
- package/src/toggle-group-control/toggle-group-control/component.tsx +11 -1
- package/src/toggle-group-control/toggle-group-control-option/README.md +1 -1
- package/src/toggle-group-control/toggle-group-control-option/component.tsx +1 -0
- package/src/toggle-group-control/toggle-group-control-option-icon/README.md +1 -1
- package/src/toggle-group-control/toggle-group-control-option-icon/component.tsx +1 -1
- package/src/toggle-group-control/types.ts +7 -0
- package/src/tools-panel/stories/index.story.tsx +3 -0
- package/src/tooltip/stories/index.story.tsx +2 -1
- package/src/tree-grid/stories/index.story.tsx +2 -1
- package/src/tree-select/stories/index.story.tsx +2 -1
- package/src/truncate/stories/index.story.tsx +2 -1
- package/src/unit-control/stories/index.story.tsx +2 -1
- package/src/utils/deprecated-36px-size.ts +8 -2
- package/src/v-stack/stories/index.story.tsx +2 -1
- package/src/visually-hidden/stories/index.story.tsx +1 -1
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -17,7 +17,8 @@ import Shortcut from '../../shortcut';
|
|
|
17
17
|
|
|
18
18
|
const meta: Meta< typeof MenuItem > = {
|
|
19
19
|
component: MenuItem,
|
|
20
|
-
title: 'Components/MenuItem',
|
|
20
|
+
title: 'Components/Actions/MenuItem',
|
|
21
|
+
id: 'components-menuitem',
|
|
21
22
|
argTypes: {
|
|
22
23
|
children: { control: { type: null } },
|
|
23
24
|
icon: {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
exports[`MenuItem should match snapshot when all props provided 1`] = `
|
|
4
4
|
<button
|
|
5
5
|
aria-checked="true"
|
|
6
|
-
class="components-button components-menu-item__button my-class"
|
|
6
|
+
class="components-button components-menu-item__button my-class is-next-40px-default-size"
|
|
7
7
|
role="menuitemcheckbox"
|
|
8
8
|
type="button"
|
|
9
9
|
>
|
|
@@ -35,7 +35,7 @@ exports[`MenuItem should match snapshot when all props provided 1`] = `
|
|
|
35
35
|
|
|
36
36
|
exports[`MenuItem should match snapshot when info is provided 1`] = `
|
|
37
37
|
<button
|
|
38
|
-
class="components-button components-menu-item__button"
|
|
38
|
+
class="components-button components-menu-item__button is-next-40px-default-size"
|
|
39
39
|
role="menuitem"
|
|
40
40
|
type="button"
|
|
41
41
|
>
|
|
@@ -62,7 +62,7 @@ exports[`MenuItem should match snapshot when info is provided 1`] = `
|
|
|
62
62
|
|
|
63
63
|
exports[`MenuItem should match snapshot when isSelected and role are optionally provided 1`] = `
|
|
64
64
|
<button
|
|
65
|
-
class="components-button components-menu-item__button my-class"
|
|
65
|
+
class="components-button components-menu-item__button my-class is-next-40px-default-size"
|
|
66
66
|
role="menuitem"
|
|
67
67
|
type="button"
|
|
68
68
|
>
|
|
@@ -94,7 +94,7 @@ exports[`MenuItem should match snapshot when isSelected and role are optionally
|
|
|
94
94
|
|
|
95
95
|
exports[`MenuItem should match snapshot when only label provided 1`] = `
|
|
96
96
|
<button
|
|
97
|
-
class="components-button components-menu-item__button"
|
|
97
|
+
class="components-button components-menu-item__button is-next-40px-default-size"
|
|
98
98
|
role="menuitem"
|
|
99
99
|
type="button"
|
|
100
100
|
>
|
|
@@ -16,7 +16,8 @@ import MenuGroup from '../../menu-group';
|
|
|
16
16
|
|
|
17
17
|
const meta: Meta< typeof MenuItemsChoice > = {
|
|
18
18
|
component: MenuItemsChoice,
|
|
19
|
-
title: 'Components/MenuItemsChoice',
|
|
19
|
+
title: 'Components/Actions/MenuItemsChoice',
|
|
20
|
+
id: 'components-menuitemschoice',
|
|
20
21
|
argTypes: {
|
|
21
22
|
onHover: { action: 'onHover' },
|
|
22
23
|
onSelect: { action: 'onSelect' },
|
package/src/modal/index.tsx
CHANGED
|
@@ -335,10 +335,10 @@ function UnforwardedModal(
|
|
|
335
335
|
<>
|
|
336
336
|
<Spacer
|
|
337
337
|
marginBottom={ 0 }
|
|
338
|
-
marginLeft={
|
|
338
|
+
marginLeft={ 2 }
|
|
339
339
|
/>
|
|
340
340
|
<Button
|
|
341
|
-
size="
|
|
341
|
+
size="compact"
|
|
342
342
|
onClick={ (
|
|
343
343
|
event: React.MouseEvent< HTMLButtonElement >
|
|
344
344
|
) =>
|
|
@@ -19,7 +19,8 @@ import type { ModalProps } from '../types';
|
|
|
19
19
|
|
|
20
20
|
const meta: Meta< typeof Modal > = {
|
|
21
21
|
component: Modal,
|
|
22
|
-
title: 'Components/Modal',
|
|
22
|
+
title: 'Components/Overlays/Modal',
|
|
23
|
+
id: 'components-modal',
|
|
23
24
|
argTypes: {
|
|
24
25
|
children: {
|
|
25
26
|
control: { type: null },
|
|
@@ -110,7 +111,7 @@ export const WithHeaderActions: StoryFn< typeof Modal > = Template.bind( {} );
|
|
|
110
111
|
WithHeaderActions.args = {
|
|
111
112
|
...Default.args,
|
|
112
113
|
headerActions: (
|
|
113
|
-
<Button icon={ fullscreen } label="Fullscreen mode" size="
|
|
114
|
+
<Button icon={ fullscreen } label="Fullscreen mode" size="compact" />
|
|
114
115
|
),
|
|
115
116
|
children: <div style={ { height: '200px' } } />,
|
|
116
117
|
};
|
|
@@ -21,7 +21,8 @@ const meta: Meta< typeof Navigator > = {
|
|
|
21
21
|
// @ts-expect-error - See https://github.com/storybookjs/storybook/issues/23170
|
|
22
22
|
BackButton: Navigator.BackButton,
|
|
23
23
|
},
|
|
24
|
-
title: 'Components/Navigator',
|
|
24
|
+
title: 'Components/Navigation/Navigator',
|
|
25
|
+
id: 'components-navigator',
|
|
25
26
|
argTypes: {
|
|
26
27
|
as: { control: { type: null } },
|
|
27
28
|
children: { control: { type: null } },
|
package/src/notice/index.tsx
CHANGED
|
@@ -142,6 +142,7 @@ function Notice( {
|
|
|
142
142
|
|
|
143
143
|
return (
|
|
144
144
|
<Button
|
|
145
|
+
__next40pxDefaultSize
|
|
145
146
|
key={ index }
|
|
146
147
|
href={ url }
|
|
147
148
|
variant={ computedVariant }
|
|
@@ -160,6 +161,7 @@ function Notice( {
|
|
|
160
161
|
</div>
|
|
161
162
|
{ isDismissible && (
|
|
162
163
|
<Button
|
|
164
|
+
size="small"
|
|
163
165
|
className="components-notice__dismiss"
|
|
164
166
|
icon={ close }
|
|
165
167
|
label={ __( 'Close' ) }
|
|
@@ -17,7 +17,8 @@ import NoticeList from '../list';
|
|
|
17
17
|
import type { NoticeListProps } from '../types';
|
|
18
18
|
|
|
19
19
|
const meta: Meta< typeof Notice > = {
|
|
20
|
-
title: 'Components/Notice',
|
|
20
|
+
title: 'Components/Feedback/Notice',
|
|
21
|
+
id: 'components-notice',
|
|
21
22
|
component: Notice,
|
|
22
23
|
// @ts-expect-error - See https://github.com/storybookjs/storybook/issues/23170
|
|
23
24
|
subcomponents: { NoticeList },
|
|
@@ -109,7 +110,11 @@ export const NoticeListSubcomponent: StoryFn< typeof NoticeList > = () => {
|
|
|
109
110
|
return (
|
|
110
111
|
<>
|
|
111
112
|
<NoticeList notices={ notices } onRemove={ removeNotice } />
|
|
112
|
-
<Button
|
|
113
|
+
<Button
|
|
114
|
+
__next40pxDefaultSize
|
|
115
|
+
variant="primary"
|
|
116
|
+
onClick={ resetNotices }
|
|
117
|
+
>
|
|
113
118
|
Reset Notices
|
|
114
119
|
</Button>
|
|
115
120
|
</>
|
|
@@ -21,19 +21,19 @@ exports[`Notice should match snapshot 1`] = `
|
|
|
21
21
|
class="components-notice__actions"
|
|
22
22
|
>
|
|
23
23
|
<a
|
|
24
|
-
class="components-button components-notice__action is-link"
|
|
24
|
+
class="components-button components-notice__action is-next-40px-default-size is-link"
|
|
25
25
|
href="https://example.com"
|
|
26
26
|
>
|
|
27
27
|
More information
|
|
28
28
|
</a>
|
|
29
29
|
<button
|
|
30
|
-
class="components-button components-notice__action is-secondary"
|
|
30
|
+
class="components-button components-notice__action is-next-40px-default-size is-secondary"
|
|
31
31
|
type="button"
|
|
32
32
|
>
|
|
33
33
|
Cancel
|
|
34
34
|
</button>
|
|
35
35
|
<button
|
|
36
|
-
class="components-button components-notice__action is-primary"
|
|
36
|
+
class="components-button components-notice__action is-next-40px-default-size is-primary"
|
|
37
37
|
type="button"
|
|
38
38
|
>
|
|
39
39
|
Submit
|
|
@@ -42,7 +42,7 @@ exports[`Notice should match snapshot 1`] = `
|
|
|
42
42
|
</div>
|
|
43
43
|
<button
|
|
44
44
|
aria-label="Close"
|
|
45
|
-
class="components-button components-notice__dismiss has-icon"
|
|
45
|
+
class="components-button components-notice__dismiss is-small has-icon"
|
|
46
46
|
type="button"
|
|
47
47
|
>
|
|
48
48
|
<svg
|
|
@@ -14,7 +14,8 @@ import { useState } from '@wordpress/element';
|
|
|
14
14
|
import NumberControl from '..';
|
|
15
15
|
|
|
16
16
|
const meta: Meta< typeof NumberControl > = {
|
|
17
|
-
title: 'Components (Experimental)/NumberControl',
|
|
17
|
+
title: 'Components (Experimental)/Selection & Input/NumberControl',
|
|
18
|
+
id: 'components-experimental-numbercontrol',
|
|
18
19
|
component: NumberControl,
|
|
19
20
|
argTypes: {
|
|
20
21
|
onChange: { action: 'onChange' },
|
|
@@ -215,6 +215,7 @@ function Option< T extends PaletteElement >( {
|
|
|
215
215
|
<Item ref={ setPopoverAnchor } size="small">
|
|
216
216
|
<HStack justify="flex-start">
|
|
217
217
|
<Button
|
|
218
|
+
size="small"
|
|
218
219
|
onClick={ () => {
|
|
219
220
|
setIsEditingColor( true );
|
|
220
221
|
} }
|
|
@@ -501,6 +502,7 @@ export function PaletteEdit( {
|
|
|
501
502
|
<NavigableMenu role="menu">
|
|
502
503
|
{ ! isEditing && (
|
|
503
504
|
<Button
|
|
505
|
+
__next40pxDefaultSize
|
|
504
506
|
variant="tertiary"
|
|
505
507
|
onClick={ () => {
|
|
506
508
|
setIsEditing( true );
|
|
@@ -513,6 +515,7 @@ export function PaletteEdit( {
|
|
|
513
515
|
) }
|
|
514
516
|
{ ! canOnlyChangeValues && (
|
|
515
517
|
<Button
|
|
518
|
+
__next40pxDefaultSize
|
|
516
519
|
variant="tertiary"
|
|
517
520
|
onClick={ () => {
|
|
518
521
|
setEditingElement(
|
|
@@ -535,6 +538,8 @@ export function PaletteEdit( {
|
|
|
535
538
|
) }
|
|
536
539
|
{ canReset && (
|
|
537
540
|
<Button
|
|
541
|
+
__next40pxDefaultSize
|
|
542
|
+
className="components-palette-edit__menu-button"
|
|
538
543
|
variant="tertiary"
|
|
539
544
|
onClick={ () => {
|
|
540
545
|
setEditingElement(
|
package/src/panel/body.tsx
CHANGED
package/src/popover/index.tsx
CHANGED
|
@@ -39,6 +39,7 @@ import {
|
|
|
39
39
|
import { close } from '@wordpress/icons';
|
|
40
40
|
import deprecated from '@wordpress/deprecated';
|
|
41
41
|
import { Path, SVG } from '@wordpress/primitives';
|
|
42
|
+
import { __ } from '@wordpress/i18n';
|
|
42
43
|
|
|
43
44
|
/**
|
|
44
45
|
* Internal dependencies
|
|
@@ -419,8 +420,10 @@ const UnforwardedPopover = (
|
|
|
419
420
|
</span>
|
|
420
421
|
<Button
|
|
421
422
|
className="components-popover__close"
|
|
423
|
+
size="small"
|
|
422
424
|
icon={ close }
|
|
423
425
|
onClick={ onClose }
|
|
426
|
+
label={ __( 'Close' ) }
|
|
424
427
|
/>
|
|
425
428
|
</div>
|
|
426
429
|
) }
|
|
@@ -33,7 +33,8 @@ const AVAILABLE_PLACEMENTS: PopoverProps[ 'placement' ][] = [
|
|
|
33
33
|
];
|
|
34
34
|
|
|
35
35
|
const meta: Meta< typeof Popover > = {
|
|
36
|
-
title: 'Components/Popover',
|
|
36
|
+
title: 'Components/Overlays/Popover',
|
|
37
|
+
id: 'components-popover',
|
|
37
38
|
component: Popover,
|
|
38
39
|
argTypes: {
|
|
39
40
|
anchor: { control: { type: null } },
|
package/src/private-apis.ts
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Internal dependencies
|
|
3
3
|
*/
|
|
4
4
|
import { positionToPlacement as __experimentalPopoverLegacyPositionToPlacement } from './popover/utils';
|
|
5
|
-
import { createPrivateSlotFill } from './slot-fill';
|
|
6
5
|
import { Menu } from './menu';
|
|
7
6
|
import { ComponentsContext } from './context/context-system-provider';
|
|
8
7
|
import Theme from './theme';
|
|
@@ -13,7 +12,6 @@ import { lock } from './lock-unlock';
|
|
|
13
12
|
export const privateApis = {};
|
|
14
13
|
lock( privateApis, {
|
|
15
14
|
__experimentalPopoverLegacyPositionToPlacement,
|
|
16
|
-
createPrivateSlotFill,
|
|
17
15
|
ComponentsContext,
|
|
18
16
|
Tabs,
|
|
19
17
|
Theme,
|
|
@@ -10,7 +10,8 @@ import { ProgressBar } from '..';
|
|
|
10
10
|
|
|
11
11
|
const meta: Meta< typeof ProgressBar > = {
|
|
12
12
|
component: ProgressBar,
|
|
13
|
-
title: 'Components/ProgressBar',
|
|
13
|
+
title: 'Components/Feedback/ProgressBar',
|
|
14
|
+
id: 'components-progressbar',
|
|
14
15
|
argTypes: {
|
|
15
16
|
value: { control: { type: 'number', min: 0, max: 100, step: 1 } },
|
|
16
17
|
},
|
|
@@ -15,7 +15,8 @@ import RadioControl from '..';
|
|
|
15
15
|
|
|
16
16
|
const meta: Meta< typeof RadioControl > = {
|
|
17
17
|
component: RadioControl,
|
|
18
|
-
title: 'Components/RadioControl',
|
|
18
|
+
title: 'Components/Selection & Input/Common/RadioControl',
|
|
19
|
+
id: 'components-radiocontrol',
|
|
19
20
|
argTypes: {
|
|
20
21
|
onChange: {
|
|
21
22
|
action: 'onChange',
|
|
@@ -57,10 +57,10 @@ const MyControlledRadioRadioGroup = () => {
|
|
|
57
57
|
const [ checked, setChecked ] = useState( '25' );
|
|
58
58
|
return (
|
|
59
59
|
<RadioGroup label="Width" onChange={ setChecked } checked={ checked }>
|
|
60
|
-
<Radio value="25">25%</Radio>
|
|
61
|
-
<Radio value="50">50%</Radio>
|
|
62
|
-
<Radio value="75">75%</Radio>
|
|
63
|
-
<Radio value="100">100%</Radio>
|
|
60
|
+
<Radio __next40pxDefaultSize value="25">25%</Radio>
|
|
61
|
+
<Radio __next40pxDefaultSize value="50">50%</Radio>
|
|
62
|
+
<Radio __next40pxDefaultSize value="75">75%</Radio>
|
|
63
|
+
<Radio __next40pxDefaultSize value="100">100%</Radio>
|
|
64
64
|
</RadioGroup>
|
|
65
65
|
);
|
|
66
66
|
};
|
|
@@ -80,10 +80,10 @@ import {
|
|
|
80
80
|
const MyUncontrolledRadioRadioGroup = () => {
|
|
81
81
|
return (
|
|
82
82
|
<RadioGroup label="Width" defaultChecked="25">
|
|
83
|
-
<Radio value="25">25%</Radio>
|
|
84
|
-
<Radio value="50">50%</Radio>
|
|
85
|
-
<Radio value="75">75%</Radio>
|
|
86
|
-
<Radio value="100">100%</Radio>
|
|
83
|
+
<Radio __next40pxDefaultSize value="25">25%</Radio>
|
|
84
|
+
<Radio __next40pxDefaultSize value="50">50%</Radio>
|
|
85
|
+
<Radio __next40pxDefaultSize value="75">75%</Radio>
|
|
86
|
+
<Radio __next40pxDefaultSize value="100">100%</Radio>
|
|
87
87
|
</RadioGroup>
|
|
88
88
|
);
|
|
89
89
|
};
|
|
@@ -16,6 +16,7 @@ import Button from '../button';
|
|
|
16
16
|
import { RadioGroupContext } from './context';
|
|
17
17
|
import type { WordPressComponentProps } from '../context';
|
|
18
18
|
import type { RadioProps } from './types';
|
|
19
|
+
import { maybeWarnDeprecated36pxSize } from '../utils/deprecated-36px-size';
|
|
19
20
|
|
|
20
21
|
function UnforwardedRadio(
|
|
21
22
|
{
|
|
@@ -30,6 +31,12 @@ function UnforwardedRadio(
|
|
|
30
31
|
const selectedValue = useStoreState( store, 'value' );
|
|
31
32
|
const isChecked = selectedValue !== undefined && selectedValue === value;
|
|
32
33
|
|
|
34
|
+
maybeWarnDeprecated36pxSize( {
|
|
35
|
+
componentName: 'Radio',
|
|
36
|
+
size: undefined,
|
|
37
|
+
__next40pxDefaultSize: props.__next40pxDefaultSize,
|
|
38
|
+
} );
|
|
39
|
+
|
|
33
40
|
return (
|
|
34
41
|
<Ariakit.Radio
|
|
35
42
|
disabled={ disabled }
|
|
@@ -28,7 +28,13 @@ const meta: Meta< typeof RadioGroup > = {
|
|
|
28
28
|
parameters: {
|
|
29
29
|
actions: { argTypesRegex: '^on.*' },
|
|
30
30
|
controls: { expanded: true },
|
|
31
|
-
docs: {
|
|
31
|
+
docs: {
|
|
32
|
+
canvas: { sourceState: 'shown' },
|
|
33
|
+
description: {
|
|
34
|
+
component:
|
|
35
|
+
'This component is deprecated. Use `RadioControl` or `ToggleGroupControl` instead.',
|
|
36
|
+
},
|
|
37
|
+
},
|
|
32
38
|
},
|
|
33
39
|
};
|
|
34
40
|
export default meta;
|
|
@@ -44,9 +50,15 @@ Default.args = {
|
|
|
44
50
|
defaultChecked: 'option2',
|
|
45
51
|
children: (
|
|
46
52
|
<>
|
|
47
|
-
<Radio value="option1">
|
|
48
|
-
|
|
49
|
-
|
|
53
|
+
<Radio __next40pxDefaultSize value="option1">
|
|
54
|
+
Option 1
|
|
55
|
+
</Radio>
|
|
56
|
+
<Radio __next40pxDefaultSize value="option2">
|
|
57
|
+
Option 2
|
|
58
|
+
</Radio>
|
|
59
|
+
<Radio __next40pxDefaultSize value="option3">
|
|
60
|
+
Option 3
|
|
61
|
+
</Radio>
|
|
50
62
|
</>
|
|
51
63
|
),
|
|
52
64
|
};
|
package/src/radio-group/types.ts
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Internal dependencies
|
|
3
|
+
*/
|
|
4
|
+
import type { ButtonProps } from '../button/types';
|
|
5
|
+
|
|
1
6
|
export type RadioGroupProps = {
|
|
2
7
|
/**
|
|
3
8
|
* Accessible label for the radio group
|
|
@@ -27,7 +32,7 @@ export type RadioGroupProps = {
|
|
|
27
32
|
children: React.ReactNode;
|
|
28
33
|
};
|
|
29
34
|
|
|
30
|
-
export type RadioProps = {
|
|
35
|
+
export type RadioProps = Pick< ButtonProps, '__next40pxDefaultSize' > & {
|
|
31
36
|
/**
|
|
32
37
|
* The actual value of the radio element.
|
|
33
38
|
*/
|
|
@@ -88,9 +88,10 @@ import { RangeControl } from '@wordpress/components';
|
|
|
88
88
|
const MyRangeControl = () => {
|
|
89
89
|
const [ columns, setColumns ] = useState( 2 );
|
|
90
90
|
|
|
91
|
-
return(
|
|
91
|
+
return (
|
|
92
92
|
<RangeControl
|
|
93
93
|
__nextHasNoMarginBottom
|
|
94
|
+
__next40pxDefaultSize
|
|
94
95
|
label="Columns"
|
|
95
96
|
value={ columns }
|
|
96
97
|
onChange={ ( value ) => setColumns( value ) }
|
|
@@ -153,7 +154,6 @@ Disables the `input`, preventing new values from being applied.
|
|
|
153
154
|
- Required: No
|
|
154
155
|
- Platform: Web
|
|
155
156
|
|
|
156
|
-
|
|
157
157
|
### `help`: `string|Element`
|
|
158
158
|
|
|
159
159
|
If this property is added, a help text will be generated using help property as the content.
|
|
@@ -165,7 +165,7 @@ If this property is added, a help text will be generated using help property as
|
|
|
165
165
|
|
|
166
166
|
Provides control over whether the label will only be visible to screen readers.
|
|
167
167
|
|
|
168
|
-
-
|
|
168
|
+
- Required: No
|
|
169
169
|
|
|
170
170
|
### `icon`: `string`
|
|
171
171
|
|
|
@@ -334,6 +334,7 @@ The minimum amount by which `value` changes. It is also a factor in validation a
|
|
|
334
334
|
|
|
335
335
|
- Required: No
|
|
336
336
|
- Platform: Web
|
|
337
|
+
|
|
337
338
|
### `trackColor`: `CSSProperties[ 'color' ]`
|
|
338
339
|
|
|
339
340
|
CSS color string to customize the track element's background.
|
|
@@ -38,6 +38,7 @@ import {
|
|
|
38
38
|
import type { RangeControlProps } from './types';
|
|
39
39
|
import type { WordPressComponentProps } from '../context';
|
|
40
40
|
import { space } from '../utils/space';
|
|
41
|
+
import { maybeWarnDeprecated36pxSize } from '../utils/deprecated-36px-size';
|
|
41
42
|
|
|
42
43
|
const noop = () => {};
|
|
43
44
|
|
|
@@ -96,6 +97,7 @@ function UnforwardedRangeControl(
|
|
|
96
97
|
trackColor,
|
|
97
98
|
value: valueProp,
|
|
98
99
|
withInputField = true,
|
|
100
|
+
__shouldNotWarnDeprecated36pxSize,
|
|
99
101
|
...otherProps
|
|
100
102
|
} = props;
|
|
101
103
|
|
|
@@ -229,6 +231,14 @@ function UnforwardedRangeControl(
|
|
|
229
231
|
[ isRTL() ? 'right' : 'left' ]: fillValueOffset,
|
|
230
232
|
};
|
|
231
233
|
|
|
234
|
+
// Add default size deprecation warning.
|
|
235
|
+
maybeWarnDeprecated36pxSize( {
|
|
236
|
+
componentName: 'RangeControl',
|
|
237
|
+
__next40pxDefaultSize,
|
|
238
|
+
size: undefined,
|
|
239
|
+
__shouldNotWarnDeprecated36pxSize,
|
|
240
|
+
} );
|
|
241
|
+
|
|
232
242
|
return (
|
|
233
243
|
<BaseControl
|
|
234
244
|
__nextHasNoMarginBottom={ __nextHasNoMarginBottom }
|
|
@@ -384,6 +394,7 @@ function UnforwardedRangeControl(
|
|
|
384
394
|
* return (
|
|
385
395
|
* <RangeControl
|
|
386
396
|
* __nextHasNoMarginBottom
|
|
397
|
+
* __next40pxDefaultSize
|
|
387
398
|
* help="Please select how transparent you would like this."
|
|
388
399
|
* initialPosition={50}
|
|
389
400
|
* label="Opacity"
|
|
@@ -18,7 +18,8 @@ const ICONS = { starEmpty, starFilled, styles, wordpress };
|
|
|
18
18
|
|
|
19
19
|
const meta: Meta< typeof RangeControl > = {
|
|
20
20
|
component: RangeControl,
|
|
21
|
-
title: 'Components/RangeControl',
|
|
21
|
+
title: 'Components/Selection & Input/Common/RangeControl',
|
|
22
|
+
id: 'components-rangecontrol',
|
|
22
23
|
argTypes: {
|
|
23
24
|
afterIcon: {
|
|
24
25
|
control: { type: 'select' },
|
|
@@ -71,6 +72,7 @@ const Template: StoryFn< typeof RangeControl > = ( { onChange, ...args } ) => {
|
|
|
71
72
|
export const Default: StoryFn< typeof RangeControl > = Template.bind( {} );
|
|
72
73
|
Default.args = {
|
|
73
74
|
__nextHasNoMarginBottom: true,
|
|
75
|
+
__next40pxDefaultSize: true,
|
|
74
76
|
help: 'Please select how transparent you would like this.',
|
|
75
77
|
initialPosition: 50,
|
|
76
78
|
label: 'Opacity',
|
|
@@ -106,6 +108,7 @@ export const WithAnyStep: StoryFn< typeof RangeControl > = ( {
|
|
|
106
108
|
};
|
|
107
109
|
WithAnyStep.args = {
|
|
108
110
|
__nextHasNoMarginBottom: true,
|
|
111
|
+
__next40pxDefaultSize: true,
|
|
109
112
|
label: 'Brightness',
|
|
110
113
|
step: 'any',
|
|
111
114
|
};
|
|
@@ -170,6 +173,7 @@ export const WithIntegerStepAndMarks: StoryFn< typeof RangeControl > =
|
|
|
170
173
|
|
|
171
174
|
WithIntegerStepAndMarks.args = {
|
|
172
175
|
__nextHasNoMarginBottom: true,
|
|
176
|
+
__next40pxDefaultSize: true,
|
|
173
177
|
label: 'Integer Step',
|
|
174
178
|
marks: marksBase,
|
|
175
179
|
max: 10,
|
|
@@ -187,6 +191,7 @@ export const WithDecimalStepAndMarks: StoryFn< typeof RangeControl > =
|
|
|
187
191
|
|
|
188
192
|
WithDecimalStepAndMarks.args = {
|
|
189
193
|
__nextHasNoMarginBottom: true,
|
|
194
|
+
__next40pxDefaultSize: true,
|
|
190
195
|
marks: [
|
|
191
196
|
...marksBase,
|
|
192
197
|
{ value: 3.5, label: '3.5' },
|
|
@@ -207,6 +212,7 @@ export const WithNegativeMinimumAndMarks: StoryFn< typeof RangeControl > =
|
|
|
207
212
|
|
|
208
213
|
WithNegativeMinimumAndMarks.args = {
|
|
209
214
|
__nextHasNoMarginBottom: true,
|
|
215
|
+
__next40pxDefaultSize: true,
|
|
210
216
|
marks: marksWithNegatives,
|
|
211
217
|
max: 10,
|
|
212
218
|
min: -10,
|
|
@@ -223,6 +229,7 @@ export const WithNegativeRangeAndMarks: StoryFn< typeof RangeControl > =
|
|
|
223
229
|
|
|
224
230
|
WithNegativeRangeAndMarks.args = {
|
|
225
231
|
__nextHasNoMarginBottom: true,
|
|
232
|
+
__next40pxDefaultSize: true,
|
|
226
233
|
marks: marksWithNegatives,
|
|
227
234
|
max: -1,
|
|
228
235
|
min: -10,
|
|
@@ -239,6 +246,7 @@ export const WithAnyStepAndMarks: StoryFn< typeof RangeControl > =
|
|
|
239
246
|
|
|
240
247
|
WithAnyStepAndMarks.args = {
|
|
241
248
|
__nextHasNoMarginBottom: true,
|
|
249
|
+
__next40pxDefaultSize: true,
|
|
242
250
|
marks: marksBase,
|
|
243
251
|
max: 10,
|
|
244
252
|
min: 0,
|
|
@@ -18,7 +18,13 @@ const fireChangeEvent = ( input: HTMLInputElement, value?: number | string ) =>
|
|
|
18
18
|
const RangeControl = (
|
|
19
19
|
props: React.ComponentProps< typeof _RangeControl >
|
|
20
20
|
) => {
|
|
21
|
-
return
|
|
21
|
+
return (
|
|
22
|
+
<_RangeControl
|
|
23
|
+
{ ...props }
|
|
24
|
+
__nextHasNoMarginBottom
|
|
25
|
+
__next40pxDefaultSize
|
|
26
|
+
/>
|
|
27
|
+
);
|
|
22
28
|
};
|
|
23
29
|
|
|
24
30
|
describe( 'RangeControl', () => {
|
|
@@ -233,6 +233,13 @@ export type RangeControlProps = Pick<
|
|
|
233
233
|
* @default true
|
|
234
234
|
*/
|
|
235
235
|
withInputField?: boolean;
|
|
236
|
+
/**
|
|
237
|
+
* Do not throw a warning for the deprecated 36px default size.
|
|
238
|
+
* For internal components of other components that already throw the warning.
|
|
239
|
+
*
|
|
240
|
+
* @ignore
|
|
241
|
+
*/
|
|
242
|
+
__shouldNotWarnDeprecated36pxSize?: boolean;
|
|
236
243
|
};
|
|
237
244
|
|
|
238
245
|
export type RailProps = MarksProps & {
|
|
@@ -10,7 +10,8 @@ import ResponsiveWrapper from '..';
|
|
|
10
10
|
|
|
11
11
|
const meta: Meta< typeof ResponsiveWrapper > = {
|
|
12
12
|
component: ResponsiveWrapper,
|
|
13
|
-
title: 'Components/ResponsiveWrapper',
|
|
13
|
+
title: 'Components/Layout/ResponsiveWrapper',
|
|
14
|
+
id: 'components-responsivewrapper',
|
|
14
15
|
argTypes: {
|
|
15
16
|
children: { control: { type: null } },
|
|
16
17
|
},
|
|
@@ -14,7 +14,8 @@ import { useState } from '@wordpress/element';
|
|
|
14
14
|
import SearchControl from '..';
|
|
15
15
|
|
|
16
16
|
const meta: Meta< typeof SearchControl > = {
|
|
17
|
-
title: 'Components/SearchControl',
|
|
17
|
+
title: 'Components/Selection & Input/Common/SearchControl',
|
|
18
|
+
id: 'components-searchcontrol',
|
|
18
19
|
component: SearchControl,
|
|
19
20
|
argTypes: {
|
|
20
21
|
onChange: { action: 'onChange' },
|
|
@@ -15,7 +15,8 @@ import SelectControl from '../';
|
|
|
15
15
|
import { InputControlPrefixWrapper } from '../../input-control/input-prefix-wrapper';
|
|
16
16
|
|
|
17
17
|
const meta: Meta< typeof SelectControl > = {
|
|
18
|
-
title: 'Components/SelectControl',
|
|
18
|
+
title: 'Components/Selection & Input/Common/SelectControl',
|
|
19
|
+
id: 'components-selectcontrol',
|
|
19
20
|
component: SelectControl,
|
|
20
21
|
argTypes: {
|
|
21
22
|
help: { control: { type: 'text' } },
|