@wordpress/components 27.3.0 → 27.4.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 +39 -4
- package/build/alignment-matrix-control/cell.js.map +1 -1
- package/build/alignment-matrix-control/icon.js.map +1 -1
- package/build/alignment-matrix-control/index.js.map +1 -1
- package/build/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.js +8 -4
- package/build/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.js.map +1 -1
- package/build/alignment-matrix-control/styles/alignment-matrix-control-styles.js +9 -5
- package/build/alignment-matrix-control/styles/alignment-matrix-control-styles.js.map +1 -1
- package/build/alignment-matrix-control/types.js.map +1 -1
- package/build/alignment-matrix-control/utils.js +4 -0
- package/build/alignment-matrix-control/utils.js.map +1 -1
- package/build/angle-picker-control/angle-circle.js.map +1 -1
- package/build/angle-picker-control/index.js.map +1 -1
- package/build/angle-picker-control/styles/angle-picker-control-styles.js +9 -5
- package/build/angle-picker-control/styles/angle-picker-control-styles.js.map +1 -1
- package/build/angle-picker-control/types.js.map +1 -1
- package/build/animate/index.js +4 -0
- package/build/animate/index.js.map +1 -1
- package/build/animate/types.js.map +1 -1
- package/build/animation/index.js.map +1 -1
- package/build/autocomplete/autocompleter-ui.js.map +1 -1
- package/build/autocomplete/autocompleter-ui.native.js.map +1 -1
- package/build/autocomplete/background-view.android.js.map +1 -1
- package/build/autocomplete/background-view.ios.js.map +1 -1
- package/build/autocomplete/get-default-use-items.js.map +1 -1
- package/build/autocomplete/index.js.map +1 -1
- package/build/autocomplete/types.js.map +1 -1
- package/build/base-control/hooks.js.map +1 -1
- package/build/base-control/index.js.map +1 -1
- package/build/base-control/index.native.js.map +1 -1
- package/build/base-control/styles/base-control-styles.js +10 -6
- package/build/base-control/styles/base-control-styles.js.map +1 -1
- package/build/base-control/types.js.map +1 -1
- package/build/border-box-control/border-box-control/component.js.map +1 -1
- package/build/border-box-control/border-box-control/hook.js +1 -1
- package/build/border-box-control/border-box-control/hook.js.map +1 -1
- package/build/border-box-control/border-box-control/index.js.map +1 -1
- package/build/border-box-control/border-box-control-linked-button/component.js.map +1 -1
- package/build/border-box-control/border-box-control-linked-button/hook.js +1 -1
- package/build/border-box-control/border-box-control-linked-button/hook.js.map +1 -1
- package/build/border-box-control/border-box-control-linked-button/index.js.map +1 -1
- package/build/border-box-control/border-box-control-split-controls/component.js.map +1 -1
- package/build/border-box-control/border-box-control-split-controls/hook.js +1 -1
- package/build/border-box-control/border-box-control-split-controls/hook.js.map +1 -1
- package/build/border-box-control/border-box-control-split-controls/index.js.map +1 -1
- package/build/border-box-control/border-box-control-visualizer/component.js.map +1 -1
- package/build/border-box-control/border-box-control-visualizer/hook.js +1 -1
- package/build/border-box-control/border-box-control-visualizer/hook.js.map +1 -1
- package/build/border-box-control/border-box-control-visualizer/index.js.map +1 -1
- package/build/border-box-control/index.js.map +1 -1
- package/build/border-box-control/styles.js +5 -1
- package/build/border-box-control/styles.js.map +1 -1
- package/build/border-box-control/types.js.map +1 -1
- package/build/border-box-control/utils.js.map +1 -1
- package/build/border-control/border-control/component.js.map +1 -1
- package/build/border-control/border-control/hook.js +1 -1
- package/build/border-control/border-control/hook.js.map +1 -1
- package/build/border-control/border-control/index.js.map +1 -1
- package/build/border-control/border-control-dropdown/component.js.map +1 -1
- package/build/border-control/border-control-dropdown/hook.js +1 -1
- package/build/border-control/border-control-dropdown/hook.js.map +1 -1
- package/build/border-control/border-control-dropdown/index.js.map +1 -1
- package/build/border-control/border-control-style-picker/component.js.map +1 -1
- package/build/border-control/border-control-style-picker/index.js.map +1 -1
- package/build/border-control/index.js.map +1 -1
- package/build/border-control/styles.js +5 -1
- package/build/border-control/styles.js.map +1 -1
- package/build/border-control/types.js.map +1 -1
- package/build/box-control/all-input-control.js +4 -0
- package/build/box-control/all-input-control.js.map +1 -1
- package/build/box-control/axial-input-controls.js.map +1 -1
- package/build/box-control/icon.js.map +1 -1
- package/build/box-control/index.js.map +1 -1
- package/build/box-control/input-controls.js.map +1 -1
- package/build/box-control/linked-button.js.map +1 -1
- package/build/box-control/styles/box-control-icon-styles.js +12 -10
- package/build/box-control/styles/box-control-icon-styles.js.map +1 -1
- package/build/box-control/styles/box-control-styles.js +11 -7
- package/build/box-control/styles/box-control-styles.js.map +1 -1
- package/build/box-control/types.js.map +1 -1
- package/build/box-control/utils.js.map +1 -1
- package/build/button/deprecated.js.map +1 -1
- package/build/button/index.js.map +1 -1
- package/build/button/index.native.js.map +1 -1
- package/build/button/types.js.map +1 -1
- package/build/button-group/index.js +4 -0
- package/build/button-group/index.js.map +1 -1
- package/build/button-group/types.js.map +1 -1
- package/build/card/card/component.js +5 -1
- package/build/card/card/component.js.map +1 -1
- package/build/card/card/hook.js +5 -1
- package/build/card/card/hook.js.map +1 -1
- package/build/card/card/index.js.map +1 -1
- package/build/card/card-body/component.js.map +1 -1
- package/build/card/card-body/hook.js +5 -1
- package/build/card/card-body/hook.js.map +1 -1
- package/build/card/card-body/index.js.map +1 -1
- package/build/card/card-divider/component.js.map +1 -1
- package/build/card/card-divider/hook.js +5 -1
- package/build/card/card-divider/hook.js.map +1 -1
- package/build/card/card-divider/index.js.map +1 -1
- package/build/card/card-footer/component.js.map +1 -1
- package/build/card/card-footer/hook.js +5 -1
- package/build/card/card-footer/hook.js.map +1 -1
- package/build/card/card-footer/index.js.map +1 -1
- package/build/card/card-header/component.js.map +1 -1
- package/build/card/card-header/hook.js +5 -1
- package/build/card/card-header/hook.js.map +1 -1
- package/build/card/card-header/index.js.map +1 -1
- package/build/card/card-media/component.js.map +1 -1
- package/build/card/card-media/hook.js +5 -1
- package/build/card/card-media/hook.js.map +1 -1
- package/build/card/card-media/index.js.map +1 -1
- package/build/card/context.js.map +1 -1
- package/build/card/index.js +1 -1
- package/build/card/index.js.map +1 -1
- package/build/card/styles.js +5 -1
- package/build/card/styles.js.map +1 -1
- package/build/card/types.js.map +1 -1
- package/build/checkbox-control/index.js.map +1 -1
- package/build/checkbox-control/types.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker-actions.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker-context.js +4 -0
- package/build/circular-option-picker/circular-option-picker-context.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker-option-group.js +4 -0
- package/build/circular-option-picker/circular-option-picker-option-group.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker-option.js.map +1 -1
- package/build/circular-option-picker/circular-option-picker.js.map +1 -1
- package/build/circular-option-picker/index.js.map +1 -1
- package/build/circular-option-picker/types.js.map +1 -1
- package/build/clipboard-button/index.js.map +1 -1
- package/build/clipboard-button/types.js.map +1 -1
- package/build/color-control/index.native.js.map +1 -1
- package/build/color-indicator/index.js +4 -0
- package/build/color-indicator/index.js.map +1 -1
- package/build/color-indicator/index.native.js.map +1 -1
- package/build/color-indicator/types.js.map +1 -1
- package/build/color-palette/index.js.map +1 -1
- package/build/color-palette/index.native.js +4 -3
- package/build/color-palette/index.native.js.map +1 -1
- package/build/color-palette/styles.js +6 -2
- package/build/color-palette/styles.js.map +1 -1
- package/build/color-palette/types.js.map +1 -1
- package/build/color-palette/utils.js +4 -0
- package/build/color-palette/utils.js.map +1 -1
- package/build/color-picker/color-copy-button.js.map +1 -1
- package/build/color-picker/color-input.js.map +1 -1
- package/build/color-picker/component.js.map +1 -1
- package/build/color-picker/hex-input.js.map +1 -1
- package/build/color-picker/hsl-input.js.map +1 -1
- package/build/color-picker/hsv-color-picker.native.js.map +1 -1
- package/build/color-picker/hue-picker.native.js +1 -1
- package/build/color-picker/hue-picker.native.js.map +1 -1
- package/build/color-picker/index.js.map +1 -1
- package/build/color-picker/index.native.js.map +1 -1
- package/build/color-picker/input-with-slider.js.map +1 -1
- package/build/color-picker/legacy-adapter.js.map +1 -1
- package/build/color-picker/picker.js +4 -0
- package/build/color-picker/picker.js.map +1 -1
- package/build/color-picker/rgb-input.js.map +1 -1
- package/build/color-picker/saturation-picker.native.js +1 -1
- package/build/color-picker/saturation-picker.native.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/color-picker/use-deprecated-props.js +4 -0
- package/build/color-picker/use-deprecated-props.js.map +1 -1
- package/build/combobox-control/index.js.map +1 -1
- package/build/combobox-control/styles.js +1 -1
- package/build/combobox-control/styles.js.map +1 -1
- package/build/combobox-control/types.js.map +1 -1
- package/build/composite/current/index.js.map +1 -1
- package/build/composite/index.js.map +1 -1
- package/build/composite/legacy/index.js +6 -1
- package/build/composite/legacy/index.js.map +1 -1
- package/build/composite/v2.js.map +1 -1
- package/build/confirm-dialog/component.js +1 -1
- package/build/confirm-dialog/component.js.map +1 -1
- package/build/confirm-dialog/index.js.map +1 -1
- package/build/confirm-dialog/styles.js +3 -1
- package/build/confirm-dialog/styles.js.map +1 -1
- package/build/confirm-dialog/types.js.map +1 -1
- package/build/context/constants.js.map +1 -1
- package/build/context/context-connect.js.map +1 -1
- package/build/context/context-system-provider.js.map +1 -1
- package/build/context/get-styled-class-name-from-key.js.map +1 -1
- package/build/context/index.js.map +1 -1
- package/build/context/use-context-system.js.map +1 -1
- package/build/context/utils.js.map +1 -1
- package/build/context/wordpress-component.js.map +1 -1
- package/build/custom-gradient-picker/constants.js.map +1 -1
- package/build/custom-gradient-picker/gradient-bar/constants.js.map +1 -1
- package/build/custom-gradient-picker/gradient-bar/control-points.js.map +1 -1
- package/build/custom-gradient-picker/gradient-bar/index.js.map +1 -1
- package/build/custom-gradient-picker/gradient-bar/utils.js.map +1 -1
- package/build/custom-gradient-picker/index.js.map +1 -1
- package/build/custom-gradient-picker/index.native.js.map +1 -1
- package/build/custom-gradient-picker/serializer.js.map +1 -1
- package/build/custom-gradient-picker/styles/custom-gradient-picker-styles.js +7 -3
- package/build/custom-gradient-picker/styles/custom-gradient-picker-styles.js.map +1 -1
- package/build/custom-gradient-picker/types.js.map +1 -1
- package/build/custom-gradient-picker/utils.js.map +1 -1
- package/build/custom-select-control/index.js +6 -14
- package/build/custom-select-control/index.js.map +1 -1
- package/build/custom-select-control-v2/custom-select.js +1 -1
- package/build/custom-select-control-v2/custom-select.js.map +1 -1
- package/build/custom-select-control-v2/default-component/index.js +1 -1
- package/build/custom-select-control-v2/default-component/index.js.map +1 -1
- package/build/custom-select-control-v2/index.js.map +1 -1
- package/build/custom-select-control-v2/item.js +5 -1
- package/build/custom-select-control-v2/item.js.map +1 -1
- package/build/custom-select-control-v2/legacy-component/index.js +1 -1
- package/build/custom-select-control-v2/legacy-component/index.js.map +1 -1
- package/build/custom-select-control-v2/styles.js +15 -10
- package/build/custom-select-control-v2/styles.js.map +1 -1
- package/build/custom-select-control-v2/types.js.map +1 -1
- package/build/dashicon/index.js.map +1 -1
- package/build/dashicon/index.native.js +1 -1
- package/build/dashicon/index.native.js.map +1 -1
- package/build/dashicon/types.js.map +1 -1
- package/build/date-time/constants.js.map +1 -1
- package/build/date-time/date/index.js +4 -0
- package/build/date-time/date/index.js.map +1 -1
- package/build/date-time/date/styles.js +11 -7
- package/build/date-time/date/styles.js.map +1 -1
- package/build/date-time/date-time/index.js.map +1 -1
- package/build/date-time/date-time/styles.js +6 -2
- package/build/date-time/date-time/styles.js.map +1 -1
- package/build/date-time/index.js.map +1 -1
- package/build/date-time/time/index.js.map +1 -1
- package/build/date-time/time/styles.js +15 -11
- package/build/date-time/time/styles.js.map +1 -1
- package/build/date-time/time/timezone.js.map +1 -1
- package/build/date-time/types.js.map +1 -1
- package/build/date-time/utils.js.map +1 -1
- package/build/dimension-control/index.js +1 -1
- package/build/dimension-control/index.js.map +1 -1
- package/build/dimension-control/sizes.js +4 -0
- package/build/dimension-control/sizes.js.map +1 -1
- package/build/dimension-control/types.js.map +1 -1
- package/build/disabled/index.js.map +1 -1
- package/build/disabled/index.native.js.map +1 -1
- package/build/disabled/styles/disabled-styles.js +3 -1
- package/build/disabled/styles/disabled-styles.js.map +1 -1
- package/build/disabled/types.js.map +1 -1
- package/build/disclosure/index.js +5 -1
- package/build/disclosure/index.js.map +1 -1
- package/build/disclosure/types.js.map +1 -1
- package/build/divider/component.js +5 -1
- package/build/divider/component.js.map +1 -1
- package/build/divider/index.js.map +1 -1
- package/build/divider/styles.js +6 -2
- package/build/divider/styles.js.map +1 -1
- package/build/divider/types.js.map +1 -1
- package/build/draggable/index.js +4 -0
- package/build/draggable/index.js.map +1 -1
- package/build/draggable/index.native.js +1 -1
- package/build/draggable/index.native.js.map +1 -1
- package/build/draggable/types.js.map +1 -1
- package/build/drop-zone/index.js.map +1 -1
- package/build/drop-zone/provider.js.map +1 -1
- package/build/drop-zone/types.js.map +1 -1
- package/build/dropdown/dropdown-content-wrapper.js.map +1 -1
- package/build/dropdown/index.js.map +1 -1
- package/build/dropdown/index.native.js.map +1 -1
- package/build/dropdown/styles.js +1 -1
- package/build/dropdown/styles.js.map +1 -1
- package/build/dropdown/types.js.map +1 -1
- package/build/dropdown-menu/index.js.map +1 -1
- package/build/dropdown-menu/index.native.js.map +1 -1
- package/build/dropdown-menu/types.js.map +1 -1
- package/build/dropdown-menu-v2/index.js +1 -1
- package/build/dropdown-menu-v2/index.js.map +1 -1
- package/build/dropdown-menu-v2/styles.js +20 -15
- package/build/dropdown-menu-v2/styles.js.map +1 -1
- package/build/dropdown-menu-v2/types.js.map +1 -1
- package/build/duotone-picker/color-list-picker/index.js.map +1 -1
- package/build/duotone-picker/color-list-picker/types.js.map +1 -1
- package/build/duotone-picker/custom-duotone-bar.js.map +1 -1
- package/build/duotone-picker/duotone-picker.js.map +1 -1
- package/build/duotone-picker/duotone-swatch.js.map +1 -1
- package/build/duotone-picker/index.js.map +1 -1
- package/build/duotone-picker/types.js.map +1 -1
- package/build/duotone-picker/utils.js +4 -0
- package/build/duotone-picker/utils.js.map +1 -1
- package/build/elevation/component.js.map +1 -1
- package/build/elevation/hook.js +5 -1
- package/build/elevation/hook.js.map +1 -1
- package/build/elevation/index.js.map +1 -1
- package/build/elevation/styles.js +3 -1
- package/build/elevation/styles.js.map +1 -1
- package/build/elevation/types.js.map +1 -1
- package/build/external-link/index.js +7 -10
- package/build/external-link/index.js.map +1 -1
- package/build/external-link/index.native.js.map +1 -1
- package/build/external-link/types.js.map +1 -1
- package/build/flex/context.js.map +1 -1
- package/build/flex/flex/component.js.map +1 -1
- package/build/flex/flex/hook.js +5 -1
- package/build/flex/flex/hook.js.map +1 -1
- package/build/flex/flex/index.js.map +1 -1
- package/build/flex/flex-block/component.js.map +1 -1
- package/build/flex/flex-block/hook.js.map +1 -1
- package/build/flex/flex-block/index.js.map +1 -1
- package/build/flex/flex-item/component.js.map +1 -1
- package/build/flex/flex-item/hook.js +5 -1
- package/build/flex/flex-item/hook.js.map +1 -1
- package/build/flex/flex-item/index.js.map +1 -1
- package/build/flex/index.js +1 -1
- package/build/flex/index.js.map +1 -1
- package/build/flex/styles.js +3 -1
- package/build/flex/styles.js.map +1 -1
- package/build/flex/types.js.map +1 -1
- package/build/focal-point-picker/controls.js.map +1 -1
- package/build/focal-point-picker/focal-point.js.map +1 -1
- package/build/focal-point-picker/focal-point.native.js.map +1 -1
- package/build/focal-point-picker/grid.js.map +1 -1
- package/build/focal-point-picker/index.js.map +1 -1
- package/build/focal-point-picker/index.native.js.map +1 -1
- package/build/focal-point-picker/media.js.map +1 -1
- package/build/focal-point-picker/styles/focal-point-picker-style.js +14 -10
- package/build/focal-point-picker/styles/focal-point-picker-style.js.map +1 -1
- package/build/focal-point-picker/styles/focal-point-style.js +1 -1
- package/build/focal-point-picker/styles/focal-point-style.js.map +1 -1
- package/build/focal-point-picker/tooltip/index.native.js.map +1 -1
- package/build/focal-point-picker/types.js.map +1 -1
- package/build/focal-point-picker/utils.js.map +1 -1
- package/build/focusable-iframe/index.js +4 -0
- package/build/focusable-iframe/index.js.map +1 -1
- package/build/focusable-iframe/types.js.map +1 -1
- package/build/font-size-picker/constants.js.map +1 -1
- package/build/font-size-picker/font-size-picker-select.js.map +1 -1
- package/build/font-size-picker/font-size-picker-toggle-group.js.map +1 -1
- package/build/font-size-picker/index.js +1 -1
- package/build/font-size-picker/index.js.map +1 -1
- package/build/font-size-picker/index.native.js +1 -1
- package/build/font-size-picker/index.native.js.map +1 -1
- package/build/font-size-picker/styles.js +10 -6
- package/build/font-size-picker/styles.js.map +1 -1
- package/build/font-size-picker/types.js.map +1 -1
- package/build/font-size-picker/utils.js.map +1 -1
- package/build/footer-message-control/index.native.js.map +1 -1
- package/build/form-file-upload/index.js.map +1 -1
- package/build/form-file-upload/types.js.map +1 -1
- package/build/form-toggle/index.js +13 -3
- package/build/form-toggle/index.js.map +1 -1
- package/build/form-toggle/types.js.map +1 -1
- package/build/form-token-field/index.js.map +1 -1
- package/build/form-token-field/styles.js +1 -1
- package/build/form-token-field/styles.js.map +1 -1
- package/build/form-token-field/suggestions-list.js +4 -0
- package/build/form-token-field/suggestions-list.js.map +1 -1
- package/build/form-token-field/token-input.js +4 -0
- package/build/form-token-field/token-input.js.map +1 -1
- package/build/form-token-field/token.js.map +1 -1
- package/build/form-token-field/types.js.map +1 -1
- package/build/gradient-picker/index.js.map +1 -1
- package/build/gradient-picker/types.js.map +1 -1
- package/build/grid/component.js.map +1 -1
- package/build/grid/hook.js +4 -0
- package/build/grid/hook.js.map +1 -1
- package/build/grid/index.js.map +1 -1
- package/build/grid/types.js.map +1 -1
- package/build/grid/utils.js.map +1 -1
- package/build/guide/icons.js.map +1 -1
- package/build/guide/index.js.map +1 -1
- package/build/guide/page-control.js.map +1 -1
- package/build/guide/page.js +4 -0
- package/build/guide/page.js.map +1 -1
- package/build/guide/types.js.map +1 -1
- package/build/h-stack/component.js.map +1 -1
- package/build/h-stack/hook.js.map +1 -1
- package/build/h-stack/index.js.map +1 -1
- package/build/h-stack/types.js.map +1 -1
- package/build/h-stack/utils.js.map +1 -1
- package/build/heading/component.js.map +1 -1
- package/build/heading/hook.js.map +1 -1
- package/build/heading/index.js.map +1 -1
- package/build/heading/types.js.map +1 -1
- package/build/higher-order/navigate-regions/index.js.map +1 -1
- package/build/higher-order/with-constrained-tabbing/index.js.map +1 -1
- package/build/higher-order/with-fallback-styles/index.js.map +1 -1
- package/build/higher-order/with-filters/index.js.map +1 -1
- package/build/higher-order/with-focus-outside/index.js.map +1 -1
- package/build/higher-order/with-focus-outside/index.native.js.map +1 -1
- package/build/higher-order/with-focus-return/index.js.map +1 -1
- package/build/higher-order/with-notices/index.js.map +1 -1
- package/build/higher-order/with-notices/types.js.map +1 -1
- package/build/higher-order/with-spoken-messages/index.js.map +1 -1
- package/build/icon/index.js.map +1 -1
- package/build/index.js +1 -1
- package/build/index.js.map +1 -1
- package/build/index.native.js +1 -1
- package/build/index.native.js.map +1 -1
- package/build/input-control/backdrop.js +2 -4
- package/build/input-control/backdrop.js.map +1 -1
- package/build/input-control/index.js +0 -4
- package/build/input-control/index.js.map +1 -1
- package/build/input-control/input-base.js +1 -5
- package/build/input-control/input-base.js.map +1 -1
- package/build/input-control/input-field.js +4 -9
- package/build/input-control/input-field.js.map +1 -1
- package/build/input-control/input-prefix-wrapper.js.map +1 -1
- package/build/input-control/input-suffix-wrapper.js.map +1 -1
- package/build/input-control/label.js.map +1 -1
- package/build/input-control/reducer/actions.js.map +1 -1
- package/build/input-control/reducer/reducer.js +5 -1
- package/build/input-control/reducer/reducer.js.map +1 -1
- package/build/input-control/reducer/state.js.map +1 -1
- package/build/input-control/styles/input-control-styles.js +80 -107
- package/build/input-control/styles/input-control-styles.js.map +1 -1
- package/build/input-control/types.js.map +1 -1
- package/build/input-control/utils.js +4 -0
- package/build/input-control/utils.js.map +1 -1
- package/build/isolated-event-container/index.js.map +1 -1
- package/build/item-group/context.js +4 -0
- package/build/item-group/context.js.map +1 -1
- package/build/item-group/index.js.map +1 -1
- package/build/item-group/item/component.js.map +1 -1
- package/build/item-group/item/hook.js +5 -1
- package/build/item-group/item/hook.js.map +1 -1
- package/build/item-group/item/index.js.map +1 -1
- package/build/item-group/item-group/component.js.map +1 -1
- package/build/item-group/item-group/hook.js +1 -1
- package/build/item-group/item-group/hook.js.map +1 -1
- package/build/item-group/item-group/index.js.map +1 -1
- package/build/item-group/styles.js +5 -1
- package/build/item-group/styles.js.map +1 -1
- package/build/item-group/types.js.map +1 -1
- package/build/keyboard-shortcuts/index.js +4 -0
- package/build/keyboard-shortcuts/index.js.map +1 -1
- package/build/keyboard-shortcuts/index.native.js.map +1 -1
- package/build/keyboard-shortcuts/types.js.map +1 -1
- package/build/lock-unlock.js.map +1 -1
- package/build/menu-group/index.js +4 -0
- package/build/menu-group/index.js.map +1 -1
- package/build/menu-group/types.js.map +1 -1
- package/build/menu-item/index.js.map +1 -1
- package/build/menu-item/types.js.map +1 -1
- package/build/menu-items-choice/index.js.map +1 -1
- package/build/menu-items-choice/types.js.map +1 -1
- package/build/mobile/audio-player/audio-url-parser.native.js.map +1 -1
- package/build/mobile/audio-player/index.native.js.map +1 -1
- package/build/mobile/autocompletion-items.native.js.map +1 -1
- package/build/mobile/badge/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/bottom-sheet-context.native.js.map +1 -1
- package/build/mobile/bottom-sheet/bottom-sheet-navigation/bottom-sheet-navigation-context.native.js.map +1 -1
- package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-container.native.js +1 -1
- package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-container.native.js.map +1 -1
- package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
- package/build/mobile/bottom-sheet/button.native.js.map +1 -1
- package/build/mobile/bottom-sheet/cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/chevron-back.native.js.map +1 -1
- package/build/mobile/bottom-sheet/color-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/footer-message-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/footer-message-link/footer-message-link.native.js.map +1 -1
- package/build/mobile/bottom-sheet/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
- package/build/mobile/bottom-sheet/link-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/link-suggestion-item-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/lock-icon/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/nav-bar/action-button.native.js.map +1 -1
- package/build/mobile/bottom-sheet/nav-bar/apply-button.native.js.map +1 -1
- package/build/mobile/bottom-sheet/nav-bar/back-button.native.js.map +1 -1
- package/build/mobile/bottom-sheet/nav-bar/heading.native.js.map +1 -1
- package/build/mobile/bottom-sheet/nav-bar/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/radio-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/range-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet/range-text-input.native.js.map +1 -1
- package/build/mobile/bottom-sheet/ripple.native.js.map +1 -1
- package/build/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/stepper-cell/stepper.android.js.map +1 -1
- package/build/mobile/bottom-sheet/stepper-cell/stepper.ios.js.map +1 -1
- package/build/mobile/bottom-sheet/sub-sheet/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet/switch-cell.native.js.map +1 -1
- package/build/mobile/bottom-sheet-select-control/index.native.js +5 -1
- package/build/mobile/bottom-sheet-select-control/index.native.js.map +1 -1
- package/build/mobile/bottom-sheet-text-control/index.native.js.map +1 -1
- package/build/mobile/clipboard/index.native.js.map +1 -1
- package/build/mobile/color-settings/gradient-picker-screen.native.js.map +1 -1
- package/build/mobile/color-settings/index.native.js.map +1 -1
- package/build/mobile/color-settings/palette.screen.native.js.map +1 -1
- package/build/mobile/color-settings/picker-screen.native.js.map +1 -1
- package/build/mobile/color-settings/utils.native.js.map +1 -1
- package/build/mobile/cycle-select-control/index.native.js.map +1 -1
- package/build/mobile/dashicons/index.native.js.map +1 -1
- package/build/mobile/focal-point-settings-panel/index.native.js.map +1 -1
- package/build/mobile/global-styles-context/index.native.js.map +1 -1
- package/build/mobile/global-styles-context/utils.native.js.map +1 -1
- package/build/mobile/gradient/index.native.js.map +1 -1
- package/build/mobile/gridicons/index.native.js.map +1 -1
- package/build/mobile/html-text-input/index.native.js.map +1 -1
- package/build/mobile/image/constants.js.map +1 -1
- package/build/mobile/image/icon-customize.native.js.map +1 -1
- package/build/mobile/image/icon-retry.native.js.map +1 -1
- package/build/mobile/image/image-editing-button.native.js.map +1 -1
- package/build/mobile/image/index.native.js.map +1 -1
- package/build/mobile/image/utils/index.native.js.map +1 -1
- package/build/mobile/keyboard-avoiding-view/index.android.js.map +1 -1
- package/build/mobile/keyboard-avoiding-view/index.ios.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/index.android.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/index.ios.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-keyboard-offset.native.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-scroll-to-element.native.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-scroll-to-section.native.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-scroll.native.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-text-input-caret-position.native.js.map +1 -1
- package/build/mobile/keyboard-aware-flat-list/use-text-input-offset.native.js.map +1 -1
- package/build/mobile/layout-animation/index.native.js.map +1 -1
- package/build/mobile/link-picker/index.native.js.map +1 -1
- package/build/mobile/link-picker/link-picker-results.native.js.map +1 -1
- package/build/mobile/link-picker/link-picker-screen.native.js.map +1 -1
- package/build/mobile/link-settings/index.native.js.map +1 -1
- package/build/mobile/link-settings/link-rel.native.js.map +1 -1
- package/build/mobile/link-settings/link-settings-navigation.native.js.map +1 -1
- package/build/mobile/link-settings/link-settings-screen.native.js.map +1 -1
- package/build/mobile/media-edit/index.native.js.map +1 -1
- package/build/mobile/picker/index.android.js.map +1 -1
- package/build/mobile/picker/index.ios.js.map +1 -1
- package/build/mobile/segmented-control/index.native.js.map +1 -1
- package/build/mobile/utils/alignments.native.js.map +1 -1
- package/build/mobile/utils/get-px-from-css-unit.native.js.map +1 -1
- package/build/mobile/utils/index.native.js.map +1 -1
- package/build/mobile/utils/use-is-floating-keyboard.native.js.map +1 -1
- package/build/mobile/utils/use-unit-converter-to-mobile.native.js.map +1 -1
- package/build/modal/aria-helper.js.map +1 -1
- package/build/modal/index.js +1 -1
- package/build/modal/index.js.map +1 -1
- package/build/modal/types.js.map +1 -1
- package/build/navigable-container/container.js +4 -0
- package/build/navigable-container/container.js.map +1 -1
- package/build/navigable-container/index.js.map +1 -1
- package/build/navigable-container/menu.js.map +1 -1
- package/build/navigable-container/tabbable.js.map +1 -1
- package/build/navigable-container/types.js.map +1 -1
- package/build/navigation/back-button/index.js +4 -0
- package/build/navigation/back-button/index.js.map +1 -1
- package/build/navigation/constants.js.map +1 -1
- package/build/navigation/context.js.map +1 -1
- package/build/navigation/group/context.js +4 -0
- package/build/navigation/group/context.js.map +1 -1
- package/build/navigation/group/index.js +4 -0
- package/build/navigation/group/index.js.map +1 -1
- package/build/navigation/index.js +2 -0
- package/build/navigation/index.js.map +1 -1
- package/build/navigation/item/base-content.js.map +1 -1
- package/build/navigation/item/base.js.map +1 -1
- package/build/navigation/item/index.js +4 -0
- package/build/navigation/item/index.js.map +1 -1
- package/build/navigation/item/use-navigation-tree-item.js.map +1 -1
- package/build/navigation/menu/context.js +4 -0
- package/build/navigation/menu/context.js.map +1 -1
- package/build/navigation/menu/index.js +3 -0
- package/build/navigation/menu/index.js.map +1 -1
- package/build/navigation/menu/menu-title-search.js.map +1 -1
- package/build/navigation/menu/menu-title.js.map +1 -1
- package/build/navigation/menu/search-no-results-found.js.map +1 -1
- package/build/navigation/menu/use-navigation-tree-menu.js.map +1 -1
- package/build/navigation/styles/navigation-styles.js +19 -13
- package/build/navigation/styles/navigation-styles.js.map +1 -1
- package/build/navigation/types.js.map +1 -1
- package/build/navigation/use-create-navigation-tree.js.map +1 -1
- package/build/navigation/use-navigation-tree-nodes.js.map +1 -1
- package/build/navigation/utils.js.map +1 -1
- package/build/navigator/context.js +4 -0
- package/build/navigator/context.js.map +1 -1
- package/build/navigator/index.js.map +1 -1
- package/build/navigator/navigator-back-button/component.js.map +1 -1
- package/build/navigator/navigator-back-button/hook.js +4 -0
- package/build/navigator/navigator-back-button/hook.js.map +1 -1
- package/build/navigator/navigator-back-button/index.js.map +1 -1
- package/build/navigator/navigator-button/component.js.map +1 -1
- package/build/navigator/navigator-button/hook.js +4 -0
- package/build/navigator/navigator-button/hook.js.map +1 -1
- package/build/navigator/navigator-button/index.js.map +1 -1
- package/build/navigator/navigator-provider/component.js +9 -1
- package/build/navigator/navigator-provider/component.js.map +1 -1
- package/build/navigator/navigator-provider/index.js.map +1 -1
- package/build/navigator/navigator-screen/component.js +5 -1
- package/build/navigator/navigator-screen/component.js.map +1 -1
- package/build/navigator/navigator-screen/index.js.map +1 -1
- package/build/navigator/navigator-to-parent-button/component.js.map +1 -1
- package/build/navigator/navigator-to-parent-button/index.js.map +1 -1
- package/build/navigator/styles.js +3 -1
- package/build/navigator/styles.js.map +1 -1
- package/build/navigator/types.js.map +1 -1
- package/build/navigator/use-navigator.js.map +1 -1
- package/build/navigator/utils/router.js +4 -0
- package/build/navigator/utils/router.js.map +1 -1
- package/build/notice/index.js.map +1 -1
- package/build/notice/index.native.js.map +1 -1
- package/build/notice/list.js.map +1 -1
- package/build/notice/list.native.js.map +1 -1
- package/build/notice/types.js.map +1 -1
- package/build/number-control/index.js +1 -1
- package/build/number-control/index.js.map +1 -1
- package/build/number-control/styles/number-control-styles.js +7 -3
- package/build/number-control/styles/number-control-styles.js.map +1 -1
- package/build/number-control/types.js.map +1 -1
- package/build/palette-edit/index.js.map +1 -1
- package/build/palette-edit/styles.js +15 -11
- package/build/palette-edit/styles.js.map +1 -1
- package/build/palette-edit/types.js.map +1 -1
- package/build/panel/actions.native.js.map +1 -1
- package/build/panel/body.js +4 -0
- package/build/panel/body.js.map +1 -1
- package/build/panel/body.native.js.map +1 -1
- package/build/panel/bottom-separator-cover.native.js.map +1 -1
- package/build/panel/header.js.map +1 -1
- package/build/panel/index.js.map +1 -1
- package/build/panel/row.js +4 -0
- package/build/panel/row.js.map +1 -1
- package/build/panel/types.js.map +1 -1
- package/build/placeholder/index.js.map +1 -1
- package/build/placeholder/types.js.map +1 -1
- package/build/popover/index.js +2 -0
- package/build/popover/index.js.map +1 -1
- package/build/popover/overlay-middlewares.js.map +1 -1
- package/build/popover/types.js.map +1 -1
- package/build/popover/utils.js.map +1 -1
- package/build/private-apis.js.map +1 -1
- package/build/private-apis.native.js.map +1 -1
- package/build/progress-bar/index.js +5 -3
- package/build/progress-bar/index.js.map +1 -1
- package/build/progress-bar/styles.js +21 -12
- package/build/progress-bar/styles.js.map +1 -1
- package/build/progress-bar/types.js.map +1 -1
- package/build/query-controls/author-select.js.map +1 -1
- package/build/query-controls/category-select.js.map +1 -1
- package/build/query-controls/index.js.map +1 -1
- package/build/query-controls/index.native.js.map +1 -1
- package/build/query-controls/terms.js.map +1 -1
- package/build/query-controls/types.js.map +1 -1
- package/build/radio-control/index.js.map +1 -1
- package/build/radio-control/index.native.js.map +1 -1
- package/build/radio-control/types.js.map +1 -1
- package/build/radio-group/context.js.map +1 -1
- package/build/radio-group/index.js +1 -1
- package/build/radio-group/index.js.map +1 -1
- package/build/radio-group/radio.js +1 -1
- package/build/radio-group/radio.js.map +1 -1
- package/build/radio-group/types.js.map +1 -1
- package/build/range-control/index.js.map +1 -1
- package/build/range-control/index.native.js.map +1 -1
- package/build/range-control/input-range.js.map +1 -1
- package/build/range-control/mark.js.map +1 -1
- package/build/range-control/rail.js.map +1 -1
- package/build/range-control/styles/range-control-styles.js +20 -16
- package/build/range-control/styles/range-control-styles.js.map +1 -1
- package/build/range-control/tooltip.js.map +1 -1
- package/build/range-control/types.js.map +1 -1
- package/build/range-control/utils.js.map +1 -1
- package/build/resizable-box/index.js.map +1 -1
- package/build/resizable-box/index.native.js.map +1 -1
- package/build/resizable-box/resize-tooltip/index.js.map +1 -1
- package/build/resizable-box/resize-tooltip/label.js +4 -0
- package/build/resizable-box/resize-tooltip/label.js.map +1 -1
- package/build/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js +9 -5
- package/build/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js.map +1 -1
- package/build/resizable-box/resize-tooltip/utils.js.map +1 -1
- package/build/responsive-wrapper/index.js +4 -0
- package/build/responsive-wrapper/index.js.map +1 -1
- package/build/responsive-wrapper/types.js.map +1 -1
- package/build/sandbox/index.js +4 -0
- package/build/sandbox/index.js.map +1 -1
- package/build/sandbox/index.native.js.map +1 -1
- package/build/sandbox/types.js.map +1 -1
- package/build/scroll-lock/index.js.map +1 -1
- package/build/scrollable/component.js.map +1 -1
- package/build/scrollable/hook.js +5 -1
- package/build/scrollable/hook.js.map +1 -1
- package/build/scrollable/index.js.map +1 -1
- package/build/scrollable/styles.js +5 -1
- package/build/scrollable/styles.js.map +1 -1
- package/build/scrollable/types.js.map +1 -1
- package/build/search-control/index.js.map +1 -1
- package/build/search-control/index.native.js.map +1 -1
- package/build/search-control/styles.js +2 -2
- package/build/search-control/styles.js.map +1 -1
- package/build/search-control/types.js.map +1 -1
- package/build/select-control/chevron-down.js.map +1 -1
- package/build/select-control/index.js +0 -15
- package/build/select-control/index.js.map +1 -1
- package/build/select-control/index.native.js.map +1 -1
- package/build/select-control/styles/select-control-styles.js +3 -3
- package/build/select-control/styles/select-control-styles.js.map +1 -1
- package/build/select-control/types.js.map +1 -1
- package/build/shortcut/index.js.map +1 -1
- package/build/shortcut/types.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/observable-map.js +68 -0
- package/build/slot-fill/bubbles-virtually/observable-map.js.map +1 -0
- package/build/slot-fill/bubbles-virtually/slot-fill-context.js +5 -5
- package/build/slot-fill/bubbles-virtually/slot-fill-context.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js +7 -12
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/slot.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/use-slot-fills.js +2 -12
- package/build/slot-fill/bubbles-virtually/use-slot-fills.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/use-slot.js +2 -12
- package/build/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build/slot-fill/context.js +4 -0
- package/build/slot-fill/context.js.map +1 -1
- package/build/slot-fill/fill.js.map +1 -1
- package/build/slot-fill/index.js.map +1 -1
- package/build/slot-fill/index.native.js.map +1 -1
- package/build/slot-fill/provider.js.map +1 -1
- package/build/slot-fill/slot.js.map +1 -1
- package/build/slot-fill/types.js.map +1 -1
- package/build/slot-fill/use-slot.js.map +1 -1
- package/build/snackbar/index.js +1 -1
- package/build/snackbar/index.js.map +1 -1
- package/build/snackbar/list.js.map +1 -1
- package/build/snackbar/types.js.map +1 -1
- package/build/spacer/component.js.map +1 -1
- package/build/spacer/hook.js +4 -0
- package/build/spacer/hook.js.map +1 -1
- package/build/spacer/index.js.map +1 -1
- package/build/spacer/types.js.map +1 -1
- package/build/spinner/index.js.map +1 -1
- package/build/spinner/index.native.js.map +1 -1
- package/build/spinner/styles.js +8 -4
- package/build/spinner/styles.js.map +1 -1
- package/build/style-provider/index.js +5 -1
- package/build/style-provider/index.js.map +1 -1
- package/build/style-provider/index.native.js.map +1 -1
- package/build/style-provider/types.js.map +1 -1
- package/build/surface/component.js.map +1 -1
- package/build/surface/hook.js +1 -1
- package/build/surface/hook.js.map +1 -1
- package/build/surface/index.js.map +1 -1
- package/build/surface/styles.js.map +1 -1
- package/build/surface/types.js.map +1 -1
- package/build/tab-panel/index.js +1 -1
- package/build/tab-panel/index.js.map +1 -1
- package/build/tab-panel/types.js.map +1 -1
- package/build/tabs/context.js +4 -0
- package/build/tabs/context.js.map +1 -1
- package/build/tabs/index.js +12 -1
- package/build/tabs/index.js.map +1 -1
- package/build/tabs/styles.js +10 -5
- package/build/tabs/styles.js.map +1 -1
- package/build/tabs/tab.js +4 -0
- package/build/tabs/tab.js.map +1 -1
- package/build/tabs/tablist.js +5 -1
- package/build/tabs/tablist.js.map +1 -1
- package/build/tabs/tabpanel.js +4 -0
- package/build/tabs/tabpanel.js.map +1 -1
- package/build/tabs/types.js.map +1 -1
- package/build/text/component.js.map +1 -1
- package/build/text/get-line-height.js.map +1 -1
- package/build/text/hook.js +8 -2
- package/build/text/hook.js.map +1 -1
- package/build/text/index.js.map +1 -1
- package/build/text/index.native.js.map +1 -1
- package/build/text/styles/emotion-css.native.js.map +1 -1
- package/build/text/styles/font-family.native.js.map +1 -1
- package/build/text/styles/text-mixins.native.js.map +1 -1
- package/build/text/styles.js +12 -8
- package/build/text/styles.js.map +1 -1
- package/build/text/types.js.map +1 -1
- package/build/text/utils.js +23 -0
- package/build/text/utils.js.map +1 -1
- package/build/text-control/index.js.map +1 -1
- package/build/text-control/index.native.js.map +1 -1
- package/build/text-control/types.js.map +1 -1
- package/build/text-highlight/index.js.map +1 -1
- package/build/text-highlight/types.js.map +1 -1
- package/build/textarea-control/index.js.map +1 -1
- package/build/textarea-control/index.native.js.map +1 -1
- package/build/textarea-control/styles/textarea-control-styles.js +1 -1
- package/build/textarea-control/styles/textarea-control-styles.js.map +1 -1
- package/build/textarea-control/types.js.map +1 -1
- package/build/theme/color-algorithms.js +4 -0
- package/build/theme/color-algorithms.js.map +1 -1
- package/build/theme/index.js +4 -0
- package/build/theme/index.js.map +1 -1
- package/build/theme/styles.js +8 -2
- package/build/theme/styles.js.map +1 -1
- package/build/theme/types.js.map +1 -1
- package/build/tip/index.js +4 -0
- package/build/tip/index.js.map +1 -1
- package/build/tip/types.js.map +1 -1
- package/build/toggle-control/index.js +6 -4
- package/build/toggle-control/index.js.map +1 -1
- package/build/toggle-control/index.native.js.map +1 -1
- package/build/toggle-control/types.js.map +1 -1
- package/build/toggle-group-control/context.js +4 -0
- package/build/toggle-group-control/context.js.map +1 -1
- package/build/toggle-group-control/index.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/as-button-group.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/as-radio-group.js +1 -1
- package/build/toggle-group-control/toggle-group-control/as-radio-group.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/component.js +5 -1
- package/build/toggle-group-control/toggle-group-control/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/index.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/styles.js +6 -2
- package/build/toggle-group-control/toggle-group-control/styles.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control/utils.js +4 -0
- package/build/toggle-group-control/toggle-group-control/utils.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option/component.js +4 -0
- package/build/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option/index.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-base/component.js +5 -1
- package/build/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-base/index.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-base/styles.js +7 -3
- package/build/toggle-group-control/toggle-group-control-option-base/styles.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-icon/component.js +4 -0
- package/build/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
- package/build/toggle-group-control/toggle-group-control-option-icon/index.js.map +1 -1
- package/build/toggle-group-control/types.js.map +1 -1
- package/build/toolbar/index.js.map +1 -1
- package/build/toolbar/toolbar/index.js.map +1 -1
- package/build/toolbar/toolbar/toolbar-container.js +1 -1
- package/build/toolbar/toolbar/toolbar-container.js.map +1 -1
- package/build/toolbar/toolbar/toolbar-container.native.js.map +1 -1
- package/build/toolbar/toolbar/types.js.map +1 -1
- package/build/toolbar/toolbar-button/index.js.map +1 -1
- package/build/toolbar/toolbar-button/toolbar-button-container.js.map +1 -1
- package/build/toolbar/toolbar-button/toolbar-button-container.native.js.map +1 -1
- package/build/toolbar/toolbar-button/types.js.map +1 -1
- package/build/toolbar/toolbar-context/index.js.map +1 -1
- package/build/toolbar/toolbar-dropdown-menu/index.js +4 -0
- package/build/toolbar/toolbar-dropdown-menu/index.js.map +1 -1
- package/build/toolbar/toolbar-group/index.js.map +1 -1
- package/build/toolbar/toolbar-group/toolbar-group-collapsed.js.map +1 -1
- package/build/toolbar/toolbar-group/toolbar-group-collapsed.native.js.map +1 -1
- package/build/toolbar/toolbar-group/toolbar-group-container.js.map +1 -1
- package/build/toolbar/toolbar-group/toolbar-group-container.native.js.map +1 -1
- package/build/toolbar/toolbar-group/types.js.map +1 -1
- package/build/toolbar/toolbar-item/index.js +1 -1
- package/build/toolbar/toolbar-item/index.js.map +1 -1
- package/build/toolbar/toolbar-item/index.native.js.map +1 -1
- package/build/toolbar/toolbar-item/types.js.map +1 -1
- package/build/tools-panel/context.js +4 -0
- package/build/tools-panel/context.js.map +1 -1
- package/build/tools-panel/index.js.map +1 -1
- package/build/tools-panel/styles.js +7 -3
- package/build/tools-panel/styles.js.map +1 -1
- package/build/tools-panel/tools-panel/component.js.map +1 -1
- package/build/tools-panel/tools-panel/hook.js +1 -1
- package/build/tools-panel/tools-panel/hook.js.map +1 -1
- package/build/tools-panel/tools-panel/index.js.map +1 -1
- package/build/tools-panel/tools-panel-header/component.js.map +1 -1
- package/build/tools-panel/tools-panel-header/hook.js +1 -1
- package/build/tools-panel/tools-panel-header/hook.js.map +1 -1
- package/build/tools-panel/tools-panel-header/index.js.map +1 -1
- package/build/tools-panel/tools-panel-item/component.js.map +1 -1
- package/build/tools-panel/tools-panel-item/hook.js +1 -1
- package/build/tools-panel/tools-panel-item/hook.js.map +1 -1
- package/build/tools-panel/tools-panel-item/index.js.map +1 -1
- package/build/tools-panel/types.js.map +1 -1
- package/build/tooltip/index.js +5 -1
- package/build/tooltip/index.js.map +1 -1
- package/build/tooltip/index.native.js.map +1 -1
- package/build/tooltip/types.js.map +1 -1
- package/build/tree-grid/cell.js.map +1 -1
- package/build/tree-grid/index.js.map +1 -1
- package/build/tree-grid/item.js.map +1 -1
- package/build/tree-grid/roving-tab-index-context.js.map +1 -1
- package/build/tree-grid/roving-tab-index-item.js.map +1 -1
- package/build/tree-grid/roving-tab-index.js.map +1 -1
- package/build/tree-grid/row.js +4 -0
- package/build/tree-grid/row.js.map +1 -1
- package/build/tree-grid/types.js.map +1 -1
- package/build/tree-select/index.js.map +1 -1
- package/build/tree-select/types.js.map +1 -1
- package/build/truncate/component.js.map +1 -1
- package/build/truncate/hook.js +9 -2
- package/build/truncate/hook.js.map +1 -1
- package/build/truncate/index.js.map +1 -1
- package/build/truncate/styles.js +3 -1
- package/build/truncate/styles.js.map +1 -1
- package/build/truncate/types.js.map +1 -1
- package/build/truncate/utils.js.map +1 -1
- package/build/unit-control/index.js +4 -0
- package/build/unit-control/index.js.map +1 -1
- package/build/unit-control/index.native.js.map +1 -1
- package/build/unit-control/styles/unit-control-styles.js +6 -3
- package/build/unit-control/styles/unit-control-styles.js.map +1 -1
- package/build/unit-control/types.js.map +1 -1
- package/build/unit-control/unit-select-control.js +4 -0
- package/build/unit-control/unit-select-control.js.map +1 -1
- package/build/unit-control/utils.js +4 -0
- package/build/unit-control/utils.js.map +1 -1
- package/build/utils/base-label.js +3 -1
- package/build/utils/base-label.js.map +1 -1
- package/build/utils/box-sizing.js +3 -1
- package/build/utils/box-sizing.js.map +1 -1
- package/build/utils/breakpoint-values.js.map +1 -1
- package/build/utils/breakpoint.js.map +1 -1
- package/build/utils/colors-values.js.map +1 -1
- package/build/utils/colors.js.map +1 -1
- package/build/utils/config-values.js.map +1 -1
- package/build/utils/font-size.js.map +1 -1
- package/build/utils/font-values.js.map +1 -1
- package/build/utils/font.js.map +1 -1
- package/build/utils/get-valid-children.js.map +1 -1
- package/build/utils/hooks/emotion.d.js.map +1 -1
- package/build/utils/hooks/index.js.map +1 -1
- package/build/utils/hooks/use-controlled-state.js.map +1 -1
- package/build/utils/hooks/use-controlled-value.js.map +1 -1
- package/build/utils/hooks/use-cx.js +2 -0
- package/build/utils/hooks/use-cx.js.map +1 -1
- package/build/utils/hooks/use-update-effect.js.map +1 -1
- package/build/utils/index.js.map +1 -1
- package/build/utils/input/base.js.map +1 -1
- package/build/utils/input/index.js.map +1 -1
- package/build/utils/input/input-control.js.map +1 -1
- package/build/utils/math.js.map +1 -1
- package/build/utils/reduce-motion.js +4 -0
- package/build/utils/reduce-motion.js.map +1 -1
- package/build/utils/rtl.js +2 -2
- package/build/utils/rtl.js.map +1 -1
- package/build/utils/space.js.map +1 -1
- package/build/utils/strings.js.map +1 -1
- package/build/utils/style-mixins.js.map +1 -1
- package/build/utils/types.js.map +1 -1
- package/build/utils/unit-values.js.map +1 -1
- package/build/utils/use-deprecated-props.js.map +1 -1
- package/build/utils/use-responsive-value.js.map +1 -1
- package/build/utils/values.js.map +1 -1
- package/build/utils/with-ignore-ime-events.js.map +1 -1
- package/build/v-stack/component.js.map +1 -1
- package/build/v-stack/hook.js.map +1 -1
- package/build/v-stack/index.js.map +1 -1
- package/build/v-stack/types.js.map +1 -1
- package/build/view/component.js +5 -1
- package/build/view/component.js.map +1 -1
- package/build/view/index.js.map +1 -1
- package/build/view/types.js.map +1 -1
- package/build/visually-hidden/component.js.map +1 -1
- package/build/visually-hidden/index.js.map +1 -1
- package/build/visually-hidden/styles.js.map +1 -1
- package/build/visually-hidden/types.js.map +1 -1
- package/build/z-stack/component.js.map +1 -1
- package/build/z-stack/index.js.map +1 -1
- package/build/z-stack/styles.js +5 -3
- package/build/z-stack/styles.js.map +1 -1
- package/build/z-stack/types.js.map +1 -1
- package/build-module/alignment-matrix-control/cell.js.map +1 -1
- package/build-module/alignment-matrix-control/icon.js.map +1 -1
- package/build-module/alignment-matrix-control/index.js.map +1 -1
- package/build-module/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.js +3 -3
- package/build-module/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.js.map +1 -1
- package/build-module/alignment-matrix-control/styles/alignment-matrix-control-styles.js +4 -4
- package/build-module/alignment-matrix-control/styles/alignment-matrix-control-styles.js.map +1 -1
- package/build-module/alignment-matrix-control/types.js.map +1 -1
- package/build-module/alignment-matrix-control/utils.js.map +1 -1
- package/build-module/angle-picker-control/angle-circle.js.map +1 -1
- package/build-module/angle-picker-control/index.js.map +1 -1
- package/build-module/angle-picker-control/styles/angle-picker-control-styles.js +3 -3
- package/build-module/angle-picker-control/styles/angle-picker-control-styles.js.map +1 -1
- package/build-module/angle-picker-control/types.js.map +1 -1
- package/build-module/animate/index.js.map +1 -1
- package/build-module/animate/types.js.map +1 -1
- package/build-module/animation/index.js.map +1 -1
- package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
- package/build-module/autocomplete/autocompleter-ui.native.js.map +1 -1
- package/build-module/autocomplete/background-view.android.js.map +1 -1
- package/build-module/autocomplete/background-view.ios.js.map +1 -1
- package/build-module/autocomplete/get-default-use-items.js.map +1 -1
- package/build-module/autocomplete/index.js.map +1 -1
- package/build-module/autocomplete/types.js.map +1 -1
- package/build-module/base-control/hooks.js.map +1 -1
- package/build-module/base-control/index.js.map +1 -1
- package/build-module/base-control/index.native.js.map +1 -1
- package/build-module/base-control/styles/base-control-styles.js +5 -5
- package/build-module/base-control/styles/base-control-styles.js.map +1 -1
- package/build-module/base-control/types.js.map +1 -1
- package/build-module/border-box-control/border-box-control/component.js.map +1 -1
- package/build-module/border-box-control/border-box-control/hook.js.map +1 -1
- package/build-module/border-box-control/border-box-control/index.js.map +1 -1
- package/build-module/border-box-control/border-box-control-linked-button/component.js.map +1 -1
- package/build-module/border-box-control/border-box-control-linked-button/hook.js.map +1 -1
- package/build-module/border-box-control/border-box-control-linked-button/index.js.map +1 -1
- package/build-module/border-box-control/border-box-control-split-controls/component.js.map +1 -1
- package/build-module/border-box-control/border-box-control-split-controls/hook.js.map +1 -1
- package/build-module/border-box-control/border-box-control-split-controls/index.js.map +1 -1
- package/build-module/border-box-control/border-box-control-visualizer/component.js.map +1 -1
- package/build-module/border-box-control/border-box-control-visualizer/hook.js.map +1 -1
- package/build-module/border-box-control/border-box-control-visualizer/index.js.map +1 -1
- package/build-module/border-box-control/index.js.map +1 -1
- package/build-module/border-box-control/styles.js.map +1 -1
- package/build-module/border-box-control/types.js.map +1 -1
- package/build-module/border-box-control/utils.js.map +1 -1
- package/build-module/border-control/border-control/component.js.map +1 -1
- package/build-module/border-control/border-control/hook.js.map +1 -1
- package/build-module/border-control/border-control/index.js.map +1 -1
- package/build-module/border-control/border-control-dropdown/component.js.map +1 -1
- package/build-module/border-control/border-control-dropdown/hook.js.map +1 -1
- package/build-module/border-control/border-control-dropdown/index.js.map +1 -1
- package/build-module/border-control/border-control-style-picker/component.js.map +1 -1
- package/build-module/border-control/border-control-style-picker/index.js.map +1 -1
- package/build-module/border-control/index.js.map +1 -1
- package/build-module/border-control/styles.js.map +1 -1
- package/build-module/border-control/types.js.map +1 -1
- package/build-module/box-control/all-input-control.js.map +1 -1
- package/build-module/box-control/axial-input-controls.js.map +1 -1
- package/build-module/box-control/icon.js.map +1 -1
- package/build-module/box-control/index.js.map +1 -1
- package/build-module/box-control/input-controls.js.map +1 -1
- package/build-module/box-control/linked-button.js.map +1 -1
- package/build-module/box-control/styles/box-control-icon-styles.js +3 -3
- package/build-module/box-control/styles/box-control-icon-styles.js.map +1 -1
- package/build-module/box-control/styles/box-control-styles.js +1 -1
- package/build-module/box-control/styles/box-control-styles.js.map +1 -1
- package/build-module/box-control/types.js.map +1 -1
- package/build-module/box-control/utils.js.map +1 -1
- package/build-module/button/deprecated.js.map +1 -1
- package/build-module/button/index.js.map +1 -1
- package/build-module/button/index.native.js.map +1 -1
- package/build-module/button/types.js.map +1 -1
- package/build-module/button-group/index.js.map +1 -1
- package/build-module/button-group/types.js.map +1 -1
- package/build-module/card/card/component.js.map +1 -1
- package/build-module/card/card/hook.js.map +1 -1
- package/build-module/card/card/index.js.map +1 -1
- package/build-module/card/card-body/component.js.map +1 -1
- package/build-module/card/card-body/hook.js.map +1 -1
- package/build-module/card/card-body/index.js.map +1 -1
- package/build-module/card/card-divider/component.js.map +1 -1
- package/build-module/card/card-divider/hook.js.map +1 -1
- package/build-module/card/card-divider/index.js.map +1 -1
- package/build-module/card/card-footer/component.js.map +1 -1
- package/build-module/card/card-footer/hook.js.map +1 -1
- package/build-module/card/card-footer/index.js.map +1 -1
- package/build-module/card/card-header/component.js.map +1 -1
- package/build-module/card/card-header/hook.js.map +1 -1
- package/build-module/card/card-header/index.js.map +1 -1
- package/build-module/card/card-media/component.js.map +1 -1
- package/build-module/card/card-media/hook.js.map +1 -1
- package/build-module/card/card-media/index.js.map +1 -1
- package/build-module/card/context.js.map +1 -1
- package/build-module/card/index.js.map +1 -1
- package/build-module/card/styles.js.map +1 -1
- package/build-module/card/types.js.map +1 -1
- package/build-module/checkbox-control/index.js.map +1 -1
- package/build-module/checkbox-control/types.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker-actions.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker-context.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker-option-group.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker-option.js.map +1 -1
- package/build-module/circular-option-picker/circular-option-picker.js.map +1 -1
- package/build-module/circular-option-picker/index.js.map +1 -1
- package/build-module/circular-option-picker/types.js.map +1 -1
- package/build-module/clipboard-button/index.js.map +1 -1
- package/build-module/clipboard-button/types.js.map +1 -1
- package/build-module/color-control/index.native.js.map +1 -1
- package/build-module/color-indicator/index.js.map +1 -1
- package/build-module/color-indicator/index.native.js.map +1 -1
- package/build-module/color-indicator/types.js.map +1 -1
- package/build-module/color-palette/index.js.map +1 -1
- package/build-module/color-palette/index.native.js +4 -3
- package/build-module/color-palette/index.native.js.map +1 -1
- package/build-module/color-palette/styles.js.map +1 -1
- package/build-module/color-palette/types.js.map +1 -1
- package/build-module/color-palette/utils.js.map +1 -1
- package/build-module/color-picker/color-copy-button.js.map +1 -1
- package/build-module/color-picker/color-input.js.map +1 -1
- package/build-module/color-picker/component.js.map +1 -1
- package/build-module/color-picker/hex-input.js.map +1 -1
- package/build-module/color-picker/hsl-input.js.map +1 -1
- package/build-module/color-picker/hsv-color-picker.native.js.map +1 -1
- package/build-module/color-picker/hue-picker.native.js.map +1 -1
- package/build-module/color-picker/index.js.map +1 -1
- package/build-module/color-picker/index.native.js.map +1 -1
- package/build-module/color-picker/input-with-slider.js.map +1 -1
- package/build-module/color-picker/legacy-adapter.js.map +1 -1
- package/build-module/color-picker/picker.js.map +1 -1
- package/build-module/color-picker/rgb-input.js.map +1 -1
- package/build-module/color-picker/saturation-picker.native.js.map +1 -1
- package/build-module/color-picker/styles.js +2 -2
- package/build-module/color-picker/styles.js.map +1 -1
- package/build-module/color-picker/types.js.map +1 -1
- package/build-module/color-picker/use-deprecated-props.js.map +1 -1
- package/build-module/combobox-control/index.js.map +1 -1
- package/build-module/combobox-control/styles.js.map +1 -1
- package/build-module/combobox-control/types.js.map +1 -1
- package/build-module/composite/current/index.js.map +1 -1
- package/build-module/composite/index.js.map +1 -1
- package/build-module/composite/legacy/index.js +6 -0
- package/build-module/composite/legacy/index.js.map +1 -1
- package/build-module/composite/v2.js.map +1 -1
- package/build-module/confirm-dialog/component.js.map +1 -1
- package/build-module/confirm-dialog/index.js.map +1 -1
- package/build-module/confirm-dialog/styles.js.map +1 -1
- package/build-module/confirm-dialog/types.js.map +1 -1
- package/build-module/context/constants.js.map +1 -1
- package/build-module/context/context-connect.js.map +1 -1
- package/build-module/context/context-system-provider.js.map +1 -1
- package/build-module/context/get-styled-class-name-from-key.js.map +1 -1
- package/build-module/context/index.js.map +1 -1
- package/build-module/context/use-context-system.js.map +1 -1
- package/build-module/context/utils.js.map +1 -1
- package/build-module/context/wordpress-component.js.map +1 -1
- package/build-module/custom-gradient-picker/constants.js.map +1 -1
- package/build-module/custom-gradient-picker/gradient-bar/constants.js.map +1 -1
- package/build-module/custom-gradient-picker/gradient-bar/control-points.js.map +1 -1
- package/build-module/custom-gradient-picker/gradient-bar/index.js.map +1 -1
- package/build-module/custom-gradient-picker/gradient-bar/utils.js.map +1 -1
- package/build-module/custom-gradient-picker/index.js.map +1 -1
- package/build-module/custom-gradient-picker/index.native.js.map +1 -1
- package/build-module/custom-gradient-picker/serializer.js.map +1 -1
- package/build-module/custom-gradient-picker/styles/custom-gradient-picker-styles.js.map +1 -1
- package/build-module/custom-gradient-picker/types.js.map +1 -1
- package/build-module/custom-gradient-picker/utils.js.map +1 -1
- package/build-module/custom-select-control/index.js +7 -15
- package/build-module/custom-select-control/index.js.map +1 -1
- package/build-module/custom-select-control-v2/custom-select.js.map +1 -1
- package/build-module/custom-select-control-v2/default-component/index.js.map +1 -1
- package/build-module/custom-select-control-v2/index.js.map +1 -1
- package/build-module/custom-select-control-v2/item.js.map +1 -1
- package/build-module/custom-select-control-v2/legacy-component/index.js.map +1 -1
- package/build-module/custom-select-control-v2/styles.js +3 -3
- package/build-module/custom-select-control-v2/styles.js.map +1 -1
- package/build-module/custom-select-control-v2/types.js.map +1 -1
- package/build-module/dashicon/index.js.map +1 -1
- package/build-module/dashicon/index.native.js.map +1 -1
- package/build-module/dashicon/types.js.map +1 -1
- package/build-module/date-time/constants.js.map +1 -1
- package/build-module/date-time/date/index.js.map +1 -1
- package/build-module/date-time/date/styles.js +3 -3
- package/build-module/date-time/date/styles.js.map +1 -1
- package/build-module/date-time/date-time/index.js.map +1 -1
- package/build-module/date-time/date-time/styles.js.map +1 -1
- package/build-module/date-time/index.js.map +1 -1
- package/build-module/date-time/time/index.js.map +1 -1
- package/build-module/date-time/time/styles.js +6 -6
- package/build-module/date-time/time/styles.js.map +1 -1
- package/build-module/date-time/time/timezone.js.map +1 -1
- package/build-module/date-time/types.js.map +1 -1
- package/build-module/date-time/utils.js.map +1 -1
- package/build-module/dimension-control/index.js.map +1 -1
- package/build-module/dimension-control/sizes.js.map +1 -1
- package/build-module/dimension-control/types.js.map +1 -1
- package/build-module/disabled/index.js.map +1 -1
- package/build-module/disabled/index.native.js.map +1 -1
- package/build-module/disabled/styles/disabled-styles.js.map +1 -1
- package/build-module/disabled/types.js.map +1 -1
- package/build-module/disclosure/index.js.map +1 -1
- package/build-module/disclosure/types.js.map +1 -1
- package/build-module/divider/component.js +5 -0
- package/build-module/divider/component.js.map +1 -1
- package/build-module/divider/index.js.map +1 -1
- package/build-module/divider/styles.js +1 -1
- package/build-module/divider/styles.js.map +1 -1
- package/build-module/divider/types.js.map +1 -1
- package/build-module/draggable/index.js.map +1 -1
- package/build-module/draggable/index.native.js.map +1 -1
- package/build-module/draggable/types.js.map +1 -1
- package/build-module/drop-zone/index.js.map +1 -1
- package/build-module/drop-zone/provider.js.map +1 -1
- package/build-module/drop-zone/types.js.map +1 -1
- package/build-module/dropdown/dropdown-content-wrapper.js.map +1 -1
- package/build-module/dropdown/index.js.map +1 -1
- package/build-module/dropdown/index.native.js.map +1 -1
- package/build-module/dropdown/styles.js +1 -1
- package/build-module/dropdown/styles.js.map +1 -1
- package/build-module/dropdown/types.js.map +1 -1
- package/build-module/dropdown-menu/index.js.map +1 -1
- package/build-module/dropdown-menu/index.native.js.map +1 -1
- package/build-module/dropdown-menu/types.js.map +1 -1
- package/build-module/dropdown-menu-v2/index.js.map +1 -1
- package/build-module/dropdown-menu-v2/styles.js +4 -4
- package/build-module/dropdown-menu-v2/styles.js.map +1 -1
- package/build-module/dropdown-menu-v2/types.js.map +1 -1
- package/build-module/duotone-picker/color-list-picker/index.js.map +1 -1
- package/build-module/duotone-picker/color-list-picker/types.js.map +1 -1
- package/build-module/duotone-picker/custom-duotone-bar.js.map +1 -1
- package/build-module/duotone-picker/duotone-picker.js.map +1 -1
- package/build-module/duotone-picker/duotone-swatch.js.map +1 -1
- package/build-module/duotone-picker/index.js.map +1 -1
- package/build-module/duotone-picker/types.js.map +1 -1
- package/build-module/duotone-picker/utils.js.map +1 -1
- package/build-module/elevation/component.js.map +1 -1
- package/build-module/elevation/hook.js.map +1 -1
- package/build-module/elevation/index.js.map +1 -1
- package/build-module/elevation/styles.js.map +1 -1
- package/build-module/elevation/types.js.map +1 -1
- package/build-module/external-link/index.js +8 -10
- package/build-module/external-link/index.js.map +1 -1
- package/build-module/external-link/index.native.js.map +1 -1
- package/build-module/external-link/types.js.map +1 -1
- package/build-module/flex/context.js.map +1 -1
- package/build-module/flex/flex/component.js.map +1 -1
- package/build-module/flex/flex/hook.js.map +1 -1
- package/build-module/flex/flex/index.js.map +1 -1
- package/build-module/flex/flex-block/component.js.map +1 -1
- package/build-module/flex/flex-block/hook.js.map +1 -1
- package/build-module/flex/flex-block/index.js.map +1 -1
- package/build-module/flex/flex-item/component.js.map +1 -1
- package/build-module/flex/flex-item/hook.js.map +1 -1
- package/build-module/flex/flex-item/index.js.map +1 -1
- package/build-module/flex/index.js.map +1 -1
- package/build-module/flex/styles.js.map +1 -1
- package/build-module/flex/types.js.map +1 -1
- package/build-module/focal-point-picker/controls.js.map +1 -1
- package/build-module/focal-point-picker/focal-point.js.map +1 -1
- package/build-module/focal-point-picker/focal-point.native.js.map +1 -1
- package/build-module/focal-point-picker/grid.js.map +1 -1
- package/build-module/focal-point-picker/index.js.map +1 -1
- package/build-module/focal-point-picker/index.native.js.map +1 -1
- package/build-module/focal-point-picker/media.js.map +1 -1
- package/build-module/focal-point-picker/styles/focal-point-picker-style.js +5 -5
- package/build-module/focal-point-picker/styles/focal-point-picker-style.js.map +1 -1
- package/build-module/focal-point-picker/styles/focal-point-style.js +1 -1
- package/build-module/focal-point-picker/styles/focal-point-style.js.map +1 -1
- package/build-module/focal-point-picker/tooltip/index.native.js.map +1 -1
- package/build-module/focal-point-picker/types.js.map +1 -1
- package/build-module/focal-point-picker/utils.js.map +1 -1
- package/build-module/focusable-iframe/index.js.map +1 -1
- package/build-module/focusable-iframe/types.js.map +1 -1
- package/build-module/font-size-picker/constants.js.map +1 -1
- package/build-module/font-size-picker/font-size-picker-select.js.map +1 -1
- package/build-module/font-size-picker/font-size-picker-toggle-group.js.map +1 -1
- package/build-module/font-size-picker/index.js.map +1 -1
- package/build-module/font-size-picker/index.native.js.map +1 -1
- package/build-module/font-size-picker/styles.js +2 -2
- package/build-module/font-size-picker/styles.js.map +1 -1
- package/build-module/font-size-picker/types.js.map +1 -1
- package/build-module/font-size-picker/utils.js.map +1 -1
- package/build-module/footer-message-control/index.native.js.map +1 -1
- package/build-module/form-file-upload/index.js.map +1 -1
- package/build-module/form-file-upload/types.js.map +1 -1
- package/build-module/form-toggle/index.js +8 -3
- package/build-module/form-toggle/index.js.map +1 -1
- package/build-module/form-toggle/types.js.map +1 -1
- package/build-module/form-token-field/index.js.map +1 -1
- package/build-module/form-token-field/styles.js.map +1 -1
- package/build-module/form-token-field/suggestions-list.js.map +1 -1
- package/build-module/form-token-field/token-input.js.map +1 -1
- package/build-module/form-token-field/token.js.map +1 -1
- package/build-module/form-token-field/types.js.map +1 -1
- package/build-module/gradient-picker/index.js.map +1 -1
- package/build-module/gradient-picker/types.js.map +1 -1
- package/build-module/grid/component.js.map +1 -1
- package/build-module/grid/hook.js.map +1 -1
- package/build-module/grid/index.js.map +1 -1
- package/build-module/grid/types.js.map +1 -1
- package/build-module/grid/utils.js.map +1 -1
- package/build-module/guide/icons.js.map +1 -1
- package/build-module/guide/index.js.map +1 -1
- package/build-module/guide/page-control.js.map +1 -1
- package/build-module/guide/page.js.map +1 -1
- package/build-module/guide/types.js.map +1 -1
- package/build-module/h-stack/component.js.map +1 -1
- package/build-module/h-stack/hook.js.map +1 -1
- package/build-module/h-stack/index.js.map +1 -1
- package/build-module/h-stack/types.js.map +1 -1
- package/build-module/h-stack/utils.js.map +1 -1
- package/build-module/heading/component.js.map +1 -1
- package/build-module/heading/hook.js.map +1 -1
- package/build-module/heading/index.js.map +1 -1
- package/build-module/heading/types.js.map +1 -1
- package/build-module/higher-order/navigate-regions/index.js.map +1 -1
- package/build-module/higher-order/with-constrained-tabbing/index.js.map +1 -1
- package/build-module/higher-order/with-fallback-styles/index.js.map +1 -1
- package/build-module/higher-order/with-filters/index.js.map +1 -1
- package/build-module/higher-order/with-focus-outside/index.js.map +1 -1
- package/build-module/higher-order/with-focus-outside/index.native.js.map +1 -1
- package/build-module/higher-order/with-focus-return/index.js.map +1 -1
- package/build-module/higher-order/with-notices/index.js.map +1 -1
- package/build-module/higher-order/with-notices/types.js.map +1 -1
- package/build-module/higher-order/with-spoken-messages/index.js.map +1 -1
- package/build-module/icon/index.js.map +1 -1
- package/build-module/index.js.map +1 -1
- package/build-module/index.native.js.map +1 -1
- package/build-module/input-control/backdrop.js +2 -4
- package/build-module/input-control/backdrop.js.map +1 -1
- package/build-module/input-control/index.js +1 -5
- package/build-module/input-control/index.js.map +1 -1
- package/build-module/input-control/input-base.js +1 -5
- package/build-module/input-control/input-base.js.map +1 -1
- package/build-module/input-control/input-field.js +0 -9
- package/build-module/input-control/input-field.js.map +1 -1
- package/build-module/input-control/input-prefix-wrapper.js.map +1 -1
- package/build-module/input-control/input-suffix-wrapper.js.map +1 -1
- package/build-module/input-control/label.js.map +1 -1
- package/build-module/input-control/reducer/actions.js.map +1 -1
- package/build-module/input-control/reducer/reducer.js.map +1 -1
- package/build-module/input-control/reducer/state.js.map +1 -1
- package/build-module/input-control/styles/input-control-styles.js +76 -103
- package/build-module/input-control/styles/input-control-styles.js.map +1 -1
- package/build-module/input-control/types.js.map +1 -1
- package/build-module/input-control/utils.js.map +1 -1
- package/build-module/isolated-event-container/index.js.map +1 -1
- package/build-module/item-group/context.js.map +1 -1
- package/build-module/item-group/index.js.map +1 -1
- package/build-module/item-group/item/component.js.map +1 -1
- package/build-module/item-group/item/hook.js.map +1 -1
- package/build-module/item-group/item/index.js.map +1 -1
- package/build-module/item-group/item-group/component.js.map +1 -1
- package/build-module/item-group/item-group/hook.js.map +1 -1
- package/build-module/item-group/item-group/index.js.map +1 -1
- package/build-module/item-group/styles.js.map +1 -1
- package/build-module/item-group/types.js.map +1 -1
- package/build-module/keyboard-shortcuts/index.js.map +1 -1
- package/build-module/keyboard-shortcuts/index.native.js.map +1 -1
- package/build-module/keyboard-shortcuts/types.js.map +1 -1
- package/build-module/lock-unlock.js.map +1 -1
- package/build-module/menu-group/index.js.map +1 -1
- package/build-module/menu-group/types.js.map +1 -1
- package/build-module/menu-item/index.js.map +1 -1
- package/build-module/menu-item/types.js.map +1 -1
- package/build-module/menu-items-choice/index.js.map +1 -1
- package/build-module/menu-items-choice/types.js.map +1 -1
- package/build-module/mobile/audio-player/audio-url-parser.native.js.map +1 -1
- package/build-module/mobile/audio-player/index.native.js.map +1 -1
- package/build-module/mobile/autocompletion-items.native.js.map +1 -1
- package/build-module/mobile/badge/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/bottom-sheet-context.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/bottom-sheet-navigation-context.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-container.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/button.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/chevron-back.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/color-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/footer-message-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/footer-message-link/footer-message-link.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/link-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/link-suggestion-item-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/lock-icon/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/nav-bar/action-button.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/nav-bar/apply-button.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/nav-bar/back-button.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/nav-bar/heading.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/nav-bar/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/radio-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/range-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/range-text-input.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/ripple.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/stepper-cell/stepper.android.js.map +1 -1
- package/build-module/mobile/bottom-sheet/stepper-cell/stepper.ios.js.map +1 -1
- package/build-module/mobile/bottom-sheet/sub-sheet/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet/switch-cell.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet-select-control/index.native.js +5 -1
- package/build-module/mobile/bottom-sheet-select-control/index.native.js.map +1 -1
- package/build-module/mobile/bottom-sheet-text-control/index.native.js.map +1 -1
- package/build-module/mobile/clipboard/index.native.js.map +1 -1
- package/build-module/mobile/color-settings/gradient-picker-screen.native.js.map +1 -1
- package/build-module/mobile/color-settings/index.native.js.map +1 -1
- package/build-module/mobile/color-settings/palette.screen.native.js.map +1 -1
- package/build-module/mobile/color-settings/picker-screen.native.js.map +1 -1
- package/build-module/mobile/color-settings/utils.native.js.map +1 -1
- package/build-module/mobile/cycle-select-control/index.native.js.map +1 -1
- package/build-module/mobile/dashicons/index.native.js.map +1 -1
- package/build-module/mobile/focal-point-settings-panel/index.native.js.map +1 -1
- package/build-module/mobile/global-styles-context/index.native.js.map +1 -1
- package/build-module/mobile/global-styles-context/utils.native.js.map +1 -1
- package/build-module/mobile/gradient/index.native.js.map +1 -1
- package/build-module/mobile/gridicons/index.native.js.map +1 -1
- package/build-module/mobile/html-text-input/index.native.js.map +1 -1
- package/build-module/mobile/image/constants.js.map +1 -1
- package/build-module/mobile/image/icon-customize.native.js.map +1 -1
- package/build-module/mobile/image/icon-retry.native.js.map +1 -1
- package/build-module/mobile/image/image-editing-button.native.js.map +1 -1
- package/build-module/mobile/image/index.native.js.map +1 -1
- package/build-module/mobile/image/utils/index.native.js.map +1 -1
- package/build-module/mobile/keyboard-avoiding-view/index.android.js.map +1 -1
- package/build-module/mobile/keyboard-avoiding-view/index.ios.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/index.android.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/index.ios.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-keyboard-offset.native.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-scroll-to-element.native.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-scroll-to-section.native.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-scroll.native.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-text-input-caret-position.native.js.map +1 -1
- package/build-module/mobile/keyboard-aware-flat-list/use-text-input-offset.native.js.map +1 -1
- package/build-module/mobile/layout-animation/index.native.js.map +1 -1
- package/build-module/mobile/link-picker/index.native.js.map +1 -1
- package/build-module/mobile/link-picker/link-picker-results.native.js.map +1 -1
- package/build-module/mobile/link-picker/link-picker-screen.native.js.map +1 -1
- package/build-module/mobile/link-settings/index.native.js.map +1 -1
- package/build-module/mobile/link-settings/link-rel.native.js.map +1 -1
- package/build-module/mobile/link-settings/link-settings-navigation.native.js.map +1 -1
- package/build-module/mobile/link-settings/link-settings-screen.native.js.map +1 -1
- package/build-module/mobile/media-edit/index.native.js.map +1 -1
- package/build-module/mobile/picker/index.android.js.map +1 -1
- package/build-module/mobile/picker/index.ios.js.map +1 -1
- package/build-module/mobile/segmented-control/index.native.js.map +1 -1
- package/build-module/mobile/utils/alignments.native.js.map +1 -1
- package/build-module/mobile/utils/get-px-from-css-unit.native.js.map +1 -1
- package/build-module/mobile/utils/index.native.js.map +1 -1
- package/build-module/mobile/utils/use-is-floating-keyboard.native.js.map +1 -1
- package/build-module/mobile/utils/use-unit-converter-to-mobile.native.js.map +1 -1
- package/build-module/modal/aria-helper.js.map +1 -1
- package/build-module/modal/index.js.map +1 -1
- package/build-module/modal/types.js.map +1 -1
- package/build-module/navigable-container/container.js.map +1 -1
- package/build-module/navigable-container/index.js.map +1 -1
- package/build-module/navigable-container/menu.js.map +1 -1
- package/build-module/navigable-container/tabbable.js.map +1 -1
- package/build-module/navigable-container/types.js.map +1 -1
- package/build-module/navigation/back-button/index.js +4 -0
- package/build-module/navigation/back-button/index.js.map +1 -1
- package/build-module/navigation/constants.js.map +1 -1
- package/build-module/navigation/context.js.map +1 -1
- package/build-module/navigation/group/context.js.map +1 -1
- package/build-module/navigation/group/index.js +4 -0
- package/build-module/navigation/group/index.js.map +1 -1
- package/build-module/navigation/index.js +2 -0
- package/build-module/navigation/index.js.map +1 -1
- package/build-module/navigation/item/base-content.js.map +1 -1
- package/build-module/navigation/item/base.js.map +1 -1
- package/build-module/navigation/item/index.js +4 -0
- package/build-module/navigation/item/index.js.map +1 -1
- package/build-module/navigation/item/use-navigation-tree-item.js.map +1 -1
- package/build-module/navigation/menu/context.js.map +1 -1
- package/build-module/navigation/menu/index.js +3 -0
- package/build-module/navigation/menu/index.js.map +1 -1
- package/build-module/navigation/menu/menu-title-search.js.map +1 -1
- package/build-module/navigation/menu/menu-title.js.map +1 -1
- package/build-module/navigation/menu/search-no-results-found.js.map +1 -1
- package/build-module/navigation/menu/use-navigation-tree-menu.js.map +1 -1
- package/build-module/navigation/styles/navigation-styles.js +9 -9
- package/build-module/navigation/styles/navigation-styles.js.map +1 -1
- package/build-module/navigation/types.js.map +1 -1
- package/build-module/navigation/use-create-navigation-tree.js.map +1 -1
- package/build-module/navigation/use-navigation-tree-nodes.js.map +1 -1
- package/build-module/navigation/utils.js.map +1 -1
- package/build-module/navigator/context.js.map +1 -1
- package/build-module/navigator/index.js.map +1 -1
- package/build-module/navigator/navigator-back-button/component.js.map +1 -1
- package/build-module/navigator/navigator-back-button/hook.js.map +1 -1
- package/build-module/navigator/navigator-back-button/index.js.map +1 -1
- package/build-module/navigator/navigator-button/component.js.map +1 -1
- package/build-module/navigator/navigator-button/hook.js.map +1 -1
- package/build-module/navigator/navigator-button/index.js.map +1 -1
- package/build-module/navigator/navigator-provider/component.js +4 -0
- package/build-module/navigator/navigator-provider/component.js.map +1 -1
- package/build-module/navigator/navigator-provider/index.js.map +1 -1
- package/build-module/navigator/navigator-screen/component.js.map +1 -1
- package/build-module/navigator/navigator-screen/index.js.map +1 -1
- package/build-module/navigator/navigator-to-parent-button/component.js.map +1 -1
- package/build-module/navigator/navigator-to-parent-button/index.js.map +1 -1
- package/build-module/navigator/styles.js.map +1 -1
- package/build-module/navigator/types.js.map +1 -1
- package/build-module/navigator/use-navigator.js.map +1 -1
- package/build-module/navigator/utils/router.js.map +1 -1
- package/build-module/notice/index.js.map +1 -1
- package/build-module/notice/index.native.js.map +1 -1
- package/build-module/notice/list.js.map +1 -1
- package/build-module/notice/list.native.js.map +1 -1
- package/build-module/notice/types.js.map +1 -1
- package/build-module/number-control/index.js.map +1 -1
- package/build-module/number-control/styles/number-control-styles.js.map +1 -1
- package/build-module/number-control/types.js.map +1 -1
- package/build-module/palette-edit/index.js.map +1 -1
- package/build-module/palette-edit/styles.js +1 -1
- package/build-module/palette-edit/styles.js.map +1 -1
- package/build-module/palette-edit/types.js.map +1 -1
- package/build-module/panel/actions.native.js.map +1 -1
- package/build-module/panel/body.js.map +1 -1
- package/build-module/panel/body.native.js.map +1 -1
- package/build-module/panel/bottom-separator-cover.native.js.map +1 -1
- package/build-module/panel/header.js.map +1 -1
- package/build-module/panel/index.js.map +1 -1
- package/build-module/panel/row.js +5 -0
- package/build-module/panel/row.js.map +1 -1
- package/build-module/panel/types.js.map +1 -1
- package/build-module/placeholder/index.js.map +1 -1
- package/build-module/placeholder/types.js.map +1 -1
- package/build-module/popover/index.js.map +1 -1
- package/build-module/popover/overlay-middlewares.js.map +1 -1
- package/build-module/popover/types.js.map +1 -1
- package/build-module/popover/utils.js.map +1 -1
- package/build-module/private-apis.js.map +1 -1
- package/build-module/private-apis.native.js.map +1 -1
- package/build-module/progress-bar/index.js +4 -2
- package/build-module/progress-bar/index.js.map +1 -1
- package/build-module/progress-bar/styles.js +16 -11
- package/build-module/progress-bar/styles.js.map +1 -1
- package/build-module/progress-bar/types.js.map +1 -1
- package/build-module/query-controls/author-select.js.map +1 -1
- package/build-module/query-controls/category-select.js.map +1 -1
- package/build-module/query-controls/index.js.map +1 -1
- package/build-module/query-controls/index.native.js.map +1 -1
- package/build-module/query-controls/terms.js.map +1 -1
- package/build-module/query-controls/types.js.map +1 -1
- package/build-module/radio-control/index.js.map +1 -1
- package/build-module/radio-control/index.native.js.map +1 -1
- package/build-module/radio-control/types.js.map +1 -1
- package/build-module/radio-group/context.js.map +1 -1
- package/build-module/radio-group/index.js.map +1 -1
- 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.map +1 -1
- package/build-module/range-control/index.native.js.map +1 -1
- package/build-module/range-control/input-range.js.map +1 -1
- package/build-module/range-control/mark.js.map +1 -1
- package/build-module/range-control/rail.js.map +1 -1
- package/build-module/range-control/styles/range-control-styles.js +14 -14
- package/build-module/range-control/styles/range-control-styles.js.map +1 -1
- package/build-module/range-control/tooltip.js.map +1 -1
- package/build-module/range-control/types.js.map +1 -1
- package/build-module/range-control/utils.js.map +1 -1
- package/build-module/resizable-box/index.js.map +1 -1
- package/build-module/resizable-box/index.native.js.map +1 -1
- package/build-module/resizable-box/resize-tooltip/index.js.map +1 -1
- package/build-module/resizable-box/resize-tooltip/label.js.map +1 -1
- package/build-module/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js +3 -3
- package/build-module/resizable-box/resize-tooltip/styles/resize-tooltip.styles.js.map +1 -1
- package/build-module/resizable-box/resize-tooltip/utils.js.map +1 -1
- package/build-module/responsive-wrapper/index.js.map +1 -1
- package/build-module/responsive-wrapper/types.js.map +1 -1
- package/build-module/sandbox/index.js.map +1 -1
- package/build-module/sandbox/index.native.js.map +1 -1
- package/build-module/sandbox/types.js.map +1 -1
- package/build-module/scroll-lock/index.js.map +1 -1
- package/build-module/scrollable/component.js.map +1 -1
- package/build-module/scrollable/hook.js.map +1 -1
- package/build-module/scrollable/index.js.map +1 -1
- package/build-module/scrollable/styles.js.map +1 -1
- package/build-module/scrollable/types.js.map +1 -1
- package/build-module/search-control/index.js.map +1 -1
- package/build-module/search-control/index.native.js.map +1 -1
- package/build-module/search-control/styles.js +1 -1
- package/build-module/search-control/styles.js.map +1 -1
- package/build-module/search-control/types.js.map +1 -1
- package/build-module/select-control/chevron-down.js.map +1 -1
- package/build-module/select-control/index.js +1 -16
- package/build-module/select-control/index.js.map +1 -1
- package/build-module/select-control/index.native.js.map +1 -1
- package/build-module/select-control/styles/select-control-styles.js +2 -2
- package/build-module/select-control/styles/select-control-styles.js.map +1 -1
- package/build-module/select-control/types.js.map +1 -1
- package/build-module/shortcut/index.js.map +1 -1
- package/build-module/shortcut/types.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/observable-map.js +60 -0
- package/build-module/slot-fill/bubbles-virtually/observable-map.js.map +1 -0
- package/build-module/slot-fill/bubbles-virtually/slot-fill-context.js +3 -6
- package/build-module/slot-fill/bubbles-virtually/slot-fill-context.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js +7 -12
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/slot.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/use-slot-fills.js +2 -12
- package/build-module/slot-fill/bubbles-virtually/use-slot-fills.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/use-slot.js +2 -12
- package/build-module/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build-module/slot-fill/context.js.map +1 -1
- package/build-module/slot-fill/fill.js.map +1 -1
- package/build-module/slot-fill/index.js.map +1 -1
- package/build-module/slot-fill/index.native.js.map +1 -1
- package/build-module/slot-fill/provider.js.map +1 -1
- package/build-module/slot-fill/slot.js.map +1 -1
- package/build-module/slot-fill/types.js.map +1 -1
- package/build-module/slot-fill/use-slot.js.map +1 -1
- package/build-module/snackbar/index.js +1 -1
- package/build-module/snackbar/index.js.map +1 -1
- package/build-module/snackbar/list.js.map +1 -1
- package/build-module/snackbar/types.js.map +1 -1
- package/build-module/spacer/component.js.map +1 -1
- package/build-module/spacer/hook.js.map +1 -1
- package/build-module/spacer/index.js.map +1 -1
- package/build-module/spacer/types.js.map +1 -1
- package/build-module/spinner/index.js.map +1 -1
- package/build-module/spinner/index.native.js.map +1 -1
- package/build-module/spinner/styles.js +3 -3
- package/build-module/spinner/styles.js.map +1 -1
- package/build-module/style-provider/index.js.map +1 -1
- package/build-module/style-provider/index.native.js.map +1 -1
- package/build-module/style-provider/types.js.map +1 -1
- package/build-module/surface/component.js.map +1 -1
- package/build-module/surface/hook.js.map +1 -1
- package/build-module/surface/index.js.map +1 -1
- package/build-module/surface/styles.js.map +1 -1
- package/build-module/surface/types.js.map +1 -1
- package/build-module/tab-panel/index.js.map +1 -1
- package/build-module/tab-panel/types.js.map +1 -1
- package/build-module/tabs/context.js.map +1 -1
- package/build-module/tabs/index.js +7 -0
- package/build-module/tabs/index.js.map +1 -1
- package/build-module/tabs/styles.js +1 -1
- package/build-module/tabs/styles.js.map +1 -1
- package/build-module/tabs/tab.js.map +1 -1
- package/build-module/tabs/tablist.js.map +1 -1
- package/build-module/tabs/tabpanel.js.map +1 -1
- package/build-module/tabs/types.js.map +1 -1
- package/build-module/text/component.js.map +1 -1
- package/build-module/text/get-line-height.js.map +1 -1
- package/build-module/text/hook.js.map +1 -1
- package/build-module/text/index.js.map +1 -1
- package/build-module/text/index.native.js.map +1 -1
- package/build-module/text/styles/emotion-css.native.js.map +1 -1
- package/build-module/text/styles/font-family.native.js.map +1 -1
- package/build-module/text/styles/text-mixins.native.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.map +1 -1
- package/build-module/text-control/index.js.map +1 -1
- package/build-module/text-control/index.native.js.map +1 -1
- package/build-module/text-control/types.js.map +1 -1
- package/build-module/text-highlight/index.js.map +1 -1
- package/build-module/text-highlight/types.js.map +1 -1
- package/build-module/textarea-control/index.js.map +1 -1
- package/build-module/textarea-control/index.native.js.map +1 -1
- package/build-module/textarea-control/styles/textarea-control-styles.js +1 -1
- package/build-module/textarea-control/styles/textarea-control-styles.js.map +1 -1
- package/build-module/textarea-control/types.js.map +1 -1
- package/build-module/theme/color-algorithms.js.map +1 -1
- package/build-module/theme/index.js.map +1 -1
- package/build-module/theme/styles.js +1 -1
- package/build-module/theme/styles.js.map +1 -1
- package/build-module/theme/types.js.map +1 -1
- package/build-module/tip/index.js.map +1 -1
- package/build-module/tip/types.js.map +1 -1
- package/build-module/toggle-control/index.js +6 -4
- package/build-module/toggle-control/index.js.map +1 -1
- package/build-module/toggle-control/index.native.js.map +1 -1
- package/build-module/toggle-control/types.js.map +1 -1
- package/build-module/toggle-group-control/context.js.map +1 -1
- package/build-module/toggle-group-control/index.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/as-button-group.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/as-radio-group.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/component.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/index.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/styles.js +1 -1
- package/build-module/toggle-group-control/toggle-group-control/styles.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control/utils.js.map +1 -1
- 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/index.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-base/index.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-base/styles.js +2 -2
- package/build-module/toggle-group-control/toggle-group-control-option-base/styles.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
- package/build-module/toggle-group-control/toggle-group-control-option-icon/index.js.map +1 -1
- package/build-module/toggle-group-control/types.js.map +1 -1
- package/build-module/toolbar/index.js.map +1 -1
- package/build-module/toolbar/toolbar/index.js.map +1 -1
- package/build-module/toolbar/toolbar/toolbar-container.js.map +1 -1
- package/build-module/toolbar/toolbar/toolbar-container.native.js.map +1 -1
- package/build-module/toolbar/toolbar/types.js.map +1 -1
- package/build-module/toolbar/toolbar-button/index.js.map +1 -1
- package/build-module/toolbar/toolbar-button/toolbar-button-container.js.map +1 -1
- package/build-module/toolbar/toolbar-button/toolbar-button-container.native.js.map +1 -1
- package/build-module/toolbar/toolbar-button/types.js.map +1 -1
- package/build-module/toolbar/toolbar-context/index.js.map +1 -1
- package/build-module/toolbar/toolbar-dropdown-menu/index.js.map +1 -1
- package/build-module/toolbar/toolbar-group/index.js.map +1 -1
- package/build-module/toolbar/toolbar-group/toolbar-group-collapsed.js.map +1 -1
- package/build-module/toolbar/toolbar-group/toolbar-group-collapsed.native.js.map +1 -1
- package/build-module/toolbar/toolbar-group/toolbar-group-container.js.map +1 -1
- package/build-module/toolbar/toolbar-group/toolbar-group-container.native.js.map +1 -1
- package/build-module/toolbar/toolbar-group/types.js.map +1 -1
- package/build-module/toolbar/toolbar-item/index.js.map +1 -1
- package/build-module/toolbar/toolbar-item/index.native.js.map +1 -1
- package/build-module/toolbar/toolbar-item/types.js.map +1 -1
- package/build-module/tools-panel/context.js.map +1 -1
- package/build-module/tools-panel/index.js.map +1 -1
- package/build-module/tools-panel/styles.js +2 -2
- package/build-module/tools-panel/styles.js.map +1 -1
- package/build-module/tools-panel/tools-panel/component.js.map +1 -1
- package/build-module/tools-panel/tools-panel/hook.js.map +1 -1
- package/build-module/tools-panel/tools-panel/index.js.map +1 -1
- package/build-module/tools-panel/tools-panel-header/component.js.map +1 -1
- package/build-module/tools-panel/tools-panel-header/hook.js.map +1 -1
- package/build-module/tools-panel/tools-panel-header/index.js.map +1 -1
- package/build-module/tools-panel/tools-panel-item/component.js.map +1 -1
- package/build-module/tools-panel/tools-panel-item/hook.js.map +1 -1
- package/build-module/tools-panel/tools-panel-item/index.js.map +1 -1
- package/build-module/tools-panel/types.js.map +1 -1
- package/build-module/tooltip/index.js.map +1 -1
- package/build-module/tooltip/index.native.js.map +1 -1
- package/build-module/tooltip/types.js.map +1 -1
- package/build-module/tree-grid/cell.js.map +1 -1
- package/build-module/tree-grid/index.js.map +1 -1
- package/build-module/tree-grid/item.js.map +1 -1
- package/build-module/tree-grid/roving-tab-index-context.js.map +1 -1
- package/build-module/tree-grid/roving-tab-index-item.js.map +1 -1
- package/build-module/tree-grid/roving-tab-index.js.map +1 -1
- package/build-module/tree-grid/row.js.map +1 -1
- package/build-module/tree-grid/types.js.map +1 -1
- package/build-module/tree-select/index.js.map +1 -1
- package/build-module/tree-select/types.js.map +1 -1
- package/build-module/truncate/component.js.map +1 -1
- package/build-module/truncate/hook.js +4 -1
- package/build-module/truncate/hook.js.map +1 -1
- package/build-module/truncate/index.js.map +1 -1
- package/build-module/truncate/styles.js.map +1 -1
- package/build-module/truncate/types.js.map +1 -1
- package/build-module/truncate/utils.js.map +1 -1
- package/build-module/unit-control/index.js.map +1 -1
- package/build-module/unit-control/index.native.js.map +1 -1
- package/build-module/unit-control/styles/unit-control-styles.js +2 -2
- package/build-module/unit-control/styles/unit-control-styles.js.map +1 -1
- package/build-module/unit-control/types.js.map +1 -1
- package/build-module/unit-control/unit-select-control.js.map +1 -1
- package/build-module/unit-control/utils.js.map +1 -1
- package/build-module/utils/base-label.js.map +1 -1
- package/build-module/utils/box-sizing.js.map +1 -1
- package/build-module/utils/breakpoint-values.js.map +1 -1
- package/build-module/utils/breakpoint.js.map +1 -1
- package/build-module/utils/colors-values.js.map +1 -1
- package/build-module/utils/colors.js.map +1 -1
- package/build-module/utils/config-values.js.map +1 -1
- package/build-module/utils/font-size.js.map +1 -1
- package/build-module/utils/font-values.js.map +1 -1
- package/build-module/utils/font.js.map +1 -1
- package/build-module/utils/get-valid-children.js.map +1 -1
- package/build-module/utils/hooks/emotion.d.js.map +1 -1
- package/build-module/utils/hooks/index.js.map +1 -1
- package/build-module/utils/hooks/use-controlled-state.js.map +1 -1
- package/build-module/utils/hooks/use-controlled-value.js.map +1 -1
- package/build-module/utils/hooks/use-cx.js.map +1 -1
- package/build-module/utils/hooks/use-update-effect.js.map +1 -1
- package/build-module/utils/index.js.map +1 -1
- package/build-module/utils/input/base.js.map +1 -1
- package/build-module/utils/input/index.js.map +1 -1
- package/build-module/utils/input/input-control.js.map +1 -1
- package/build-module/utils/math.js.map +1 -1
- package/build-module/utils/reduce-motion.js +4 -0
- package/build-module/utils/reduce-motion.js.map +1 -1
- package/build-module/utils/rtl.js +2 -2
- package/build-module/utils/rtl.js.map +1 -1
- package/build-module/utils/space.js.map +1 -1
- package/build-module/utils/strings.js.map +1 -1
- package/build-module/utils/style-mixins.js.map +1 -1
- package/build-module/utils/types.js.map +1 -1
- package/build-module/utils/unit-values.js.map +1 -1
- package/build-module/utils/use-deprecated-props.js.map +1 -1
- package/build-module/utils/use-responsive-value.js.map +1 -1
- package/build-module/utils/values.js.map +1 -1
- package/build-module/utils/with-ignore-ime-events.js.map +1 -1
- package/build-module/v-stack/component.js.map +1 -1
- package/build-module/v-stack/hook.js.map +1 -1
- package/build-module/v-stack/index.js.map +1 -1
- package/build-module/v-stack/types.js.map +1 -1
- package/build-module/view/component.js +5 -1
- package/build-module/view/component.js.map +1 -1
- package/build-module/view/index.js.map +1 -1
- package/build-module/view/types.js.map +1 -1
- package/build-module/visually-hidden/component.js.map +1 -1
- package/build-module/visually-hidden/index.js.map +1 -1
- package/build-module/visually-hidden/styles.js.map +1 -1
- package/build-module/visually-hidden/types.js.map +1 -1
- package/build-module/z-stack/component.js.map +1 -1
- package/build-module/z-stack/index.js.map +1 -1
- package/build-module/z-stack/styles.js +2 -2
- package/build-module/z-stack/styles.js.map +1 -1
- package/build-module/z-stack/types.js.map +1 -1
- package/build-style/style-rtl.css +43 -36
- package/build-style/style.css +43 -36
- package/build-types/alignment-matrix-control/stories/index.story.d.ts +1 -1
- package/build-types/alignment-matrix-control/stories/index.story.d.ts.map +1 -1
- package/build-types/angle-picker-control/stories/index.story.d.ts +1 -1
- package/build-types/animate/stories/index.story.d.ts +7 -7
- package/build-types/animate/stories/index.story.d.ts.map +1 -1
- package/build-types/base-control/stories/index.story.d.ts +1 -1
- package/build-types/border-box-control/stories/index.story.d.ts +1 -1
- package/build-types/border-control/stories/index.story.d.ts +6 -6
- package/build-types/box-control/stories/index.story.d.ts +6 -6
- package/build-types/button/stories/e2e/index.story.d.ts +1 -1
- package/build-types/button/stories/e2e/index.story.d.ts.map +1 -1
- package/build-types/button/stories/index.story.d.ts +7 -7
- package/build-types/button/stories/index.story.d.ts.map +1 -1
- package/build-types/card/stories/index.story.d.ts +2 -2
- package/build-types/circular-option-picker/stories/index.story.d.ts +5 -5
- package/build-types/circular-option-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/color-palette/stories/index.story.d.ts +3 -3
- package/build-types/color-palette/stories/index.story.d.ts.map +1 -1
- package/build-types/color-picker/stories/index.story.d.ts +1 -1
- package/build-types/color-picker/styles.d.ts +1 -1
- package/build-types/combobox-control/stories/index.story.d.ts +2 -2
- package/build-types/confirm-dialog/stories/index.story.d.ts +2 -2
- package/build-types/confirm-dialog/stories/index.story.d.ts.map +1 -1
- package/build-types/custom-gradient-picker/stories/index.story.d.ts +1 -1
- package/build-types/custom-gradient-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/custom-select-control/index.d.ts.map +1 -1
- package/build-types/custom-select-control-v2/stories/default.story.d.ts +3 -3
- package/build-types/custom-select-control-v2/stories/legacy.story.d.ts +3 -3
- package/build-types/custom-select-control-v2/stories/legacy.story.d.ts.map +1 -1
- package/build-types/custom-select-control-v2/types.d.ts +7 -0
- package/build-types/custom-select-control-v2/types.d.ts.map +1 -1
- package/build-types/date-time/time/styles.d.ts +4 -4
- package/build-types/dimension-control/stories/index.story.d.ts +2 -2
- package/build-types/dimension-control/stories/index.story.d.ts.map +1 -1
- package/build-types/drop-zone/stories/index.story.d.ts +1 -1
- package/build-types/drop-zone/stories/index.story.d.ts.map +1 -1
- package/build-types/dropdown/stories/index.story.d.ts +4 -4
- package/build-types/dropdown/stories/index.story.d.ts.map +1 -1
- package/build-types/dropdown-menu/stories/index.story.d.ts +2 -2
- package/build-types/dropdown-menu/stories/index.story.d.ts.map +1 -1
- package/build-types/duotone-picker/stories/duotone-picker.story.d.ts +1 -1
- package/build-types/duotone-picker/stories/duotone-picker.story.d.ts.map +1 -1
- package/build-types/duotone-picker/stories/duotone-swatch.story.d.ts +3 -3
- package/build-types/duotone-picker/stories/duotone-swatch.story.d.ts.map +1 -1
- package/build-types/external-link/index.d.ts +3 -0
- package/build-types/external-link/index.d.ts.map +1 -1
- package/build-types/focal-point-picker/stories/index.story.d.ts +4 -4
- package/build-types/form-file-upload/stories/index.story.d.ts +5 -5
- package/build-types/form-file-upload/stories/index.story.d.ts.map +1 -1
- package/build-types/form-toggle/index.d.ts +4 -3
- package/build-types/form-toggle/index.d.ts.map +1 -1
- package/build-types/form-toggle/stories/index.story.d.ts +1 -1
- package/build-types/form-toggle/stories/index.story.d.ts.map +1 -1
- package/build-types/gradient-picker/stories/index.story.d.ts +3 -3
- package/build-types/gradient-picker/stories/index.story.d.ts.map +1 -1
- package/build-types/guide/stories/index.story.d.ts +1 -1
- package/build-types/guide/stories/index.story.d.ts.map +1 -1
- package/build-types/higher-order/with-fallback-styles/index.d.ts.map +1 -1
- package/build-types/higher-order/with-filters/index.d.ts.map +1 -1
- package/build-types/higher-order/with-focus-return/index.d.ts.map +1 -1
- package/build-types/higher-order/with-notices/index.d.ts.map +1 -1
- package/build-types/icon/stories/index.story.d.ts +4 -4
- package/build-types/icon/stories/index.story.d.ts.map +1 -1
- package/build-types/input-control/backdrop.d.ts +1 -2
- package/build-types/input-control/backdrop.d.ts.map +1 -1
- package/build-types/input-control/index.d.ts.map +1 -1
- package/build-types/input-control/input-base.d.ts.map +1 -1
- package/build-types/input-control/input-field.d.ts.map +1 -1
- package/build-types/input-control/stories/index.story.d.ts +6 -6
- package/build-types/input-control/stories/index.story.d.ts.map +1 -1
- package/build-types/input-control/styles/input-control-styles.d.ts +16 -21
- package/build-types/input-control/styles/input-control-styles.d.ts.map +1 -1
- package/build-types/input-control/types.d.ts +3 -12
- package/build-types/input-control/types.d.ts.map +1 -1
- package/build-types/keyboard-shortcuts/stories/index.story.d.ts +1 -1
- package/build-types/keyboard-shortcuts/stories/index.story.d.ts.map +1 -1
- package/build-types/menu-group/stories/index.story.d.ts +1 -1
- package/build-types/menu-group/stories/index.story.d.ts.map +1 -1
- package/build-types/menu-item/stories/index.story.d.ts +4 -4
- package/build-types/navigation/back-button/index.d.ts +3 -0
- package/build-types/navigation/back-button/index.d.ts.map +1 -1
- package/build-types/navigation/group/index.d.ts +3 -0
- package/build-types/navigation/group/index.d.ts.map +1 -1
- package/build-types/navigation/index.d.ts +2 -0
- package/build-types/navigation/index.d.ts.map +1 -1
- package/build-types/navigation/item/index.d.ts +3 -0
- package/build-types/navigation/item/index.d.ts.map +1 -1
- package/build-types/navigation/menu/index.d.ts +3 -0
- package/build-types/navigation/menu/index.d.ts.map +1 -1
- package/build-types/navigation/stories/index.story.d.ts +11 -6
- package/build-types/navigation/stories/index.story.d.ts.map +1 -1
- package/build-types/navigator/navigator-provider/component.d.ts.map +1 -1
- package/build-types/notice/stories/index.story.d.ts +4 -4
- package/build-types/notice/stories/index.story.d.ts.map +1 -1
- package/build-types/number-control/index.d.ts +1 -1
- package/build-types/number-control/stories/index.story.d.ts +2 -2
- package/build-types/palette-edit/stories/index.story.d.ts +2 -2
- package/build-types/palette-edit/stories/index.story.d.ts.map +1 -1
- package/build-types/popover/utils.d.ts +1 -1
- package/build-types/popover/utils.d.ts.map +1 -1
- package/build-types/progress-bar/index.d.ts.map +1 -1
- package/build-types/progress-bar/styles.d.ts +0 -1
- package/build-types/progress-bar/styles.d.ts.map +1 -1
- package/build-types/query-controls/stories/index.story.d.ts +1 -1
- package/build-types/query-controls/stories/index.story.d.ts.map +1 -1
- package/build-types/range-control/styles/range-control-styles.d.ts +1 -1
- package/build-types/resizable-box/stories/index.story.d.ts +2 -2
- package/build-types/responsive-wrapper/stories/index.story.d.ts +1 -1
- package/build-types/responsive-wrapper/stories/index.story.d.ts.map +1 -1
- package/build-types/sandbox/stories/index.story.d.ts +1 -1
- package/build-types/sandbox/stories/index.story.d.ts.map +1 -1
- package/build-types/search-control/stories/index.story.d.ts +2 -2
- package/build-types/search-control/stories/index.story.d.ts.map +1 -1
- package/build-types/select-control/index.d.ts.map +1 -1
- package/build-types/select-control/stories/index.story.d.ts +2 -2
- package/build-types/select-control/stories/index.story.d.ts.map +1 -1
- package/build-types/shortcut/stories/index.story.d.ts +1 -1
- package/build-types/shortcut/stories/index.story.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/observable-map.d.ts +19 -0
- package/build-types/slot-fill/bubbles-virtually/observable-map.d.ts.map +1 -0
- package/build-types/slot-fill/bubbles-virtually/slot-fill-context.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/use-slot-fills.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/use-slot.d.ts.map +1 -1
- package/build-types/slot-fill/types.d.ts +6 -2
- package/build-types/slot-fill/types.d.ts.map +1 -1
- package/build-types/tab-panel/stories/index.story.d.ts +4 -4
- package/build-types/tab-panel/stories/index.story.d.ts.map +1 -1
- package/build-types/tabs/index.d.ts.map +1 -1
- package/build-types/tabs/stories/index.story.d.ts +9 -9
- package/build-types/tabs/stories/index.story.d.ts.map +1 -1
- package/build-types/text/stories/index.story.d.ts +3 -3
- package/build-types/text/styles.d.ts.map +1 -1
- package/build-types/theme/stories/index.story.d.ts +1 -1
- package/build-types/toggle-control/index.d.ts +11 -3
- package/build-types/toggle-control/index.d.ts.map +1 -1
- package/build-types/toggle-control/stories/index.story.d.ts +4 -4
- package/build-types/toggle-control/stories/index.story.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control/styles.d.ts +1 -1
- package/build-types/toggle-group-control/toggle-group-control/styles.d.ts.map +1 -1
- package/build-types/toggle-group-control/toggle-group-control-option-base/styles.d.ts +2 -2
- package/build-types/toggle-group-control/toggle-group-control-option-base/styles.d.ts.map +1 -1
- package/build-types/toolbar/stories/index.story.d.ts +3 -3
- package/build-types/toolbar/stories/index.story.d.ts.map +1 -1
- package/build-types/tooltip/stories/index.story.d.ts +1 -1
- package/build-types/tooltip/stories/index.story.d.ts.map +1 -1
- package/build-types/tree-grid/stories/index.story.d.ts +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 +1 -1
- package/build-types/tree-select/stories/index.story.d.ts.map +1 -1
- package/build-types/truncate/hook.d.ts.map +1 -1
- package/build-types/unit-control/styles/unit-control-styles.d.ts +1 -1
- package/build-types/unit-control/utils.d.ts +3 -3
- package/build-types/unit-control/utils.d.ts.map +1 -1
- package/build-types/utils/reduce-motion.d.ts +4 -0
- package/build-types/utils/reduce-motion.d.ts.map +1 -1
- package/build-types/v-stack/stories/index.story.d.ts +1 -1
- package/package.json +20 -21
- package/src/checkbox-control/style.scss +22 -24
- package/src/color-palette/index.native.js +4 -3
- package/src/combobox-control/README.md +4 -4
- package/src/custom-select-control/index.js +45 -55
- package/src/custom-select-control/style.scss +6 -0
- package/src/custom-select-control-v2/types.ts +7 -0
- package/src/dimension-control/stories/index.story.tsx +4 -4
- package/src/dimension-control/test/__snapshots__/index.test.js.snap +60 -12
- package/src/external-link/index.tsx +9 -11
- package/src/external-link/style.scss +12 -0
- package/src/form-toggle/index.tsx +10 -2
- package/src/form-toggle/stories/index.story.tsx +1 -1
- package/src/heading/test/__snapshots__/index.tsx.snap +5 -2
- package/src/input-control/backdrop.tsx +1 -6
- package/src/input-control/index.tsx +1 -6
- package/src/input-control/input-base.tsx +1 -8
- package/src/input-control/input-field.tsx +0 -10
- package/src/input-control/styles/input-control-styles.tsx +61 -77
- package/src/input-control/types.ts +2 -13
- package/src/mobile/bottom-sheet-select-control/index.native.js +7 -3
- package/src/navigation/README.md +4 -0
- package/src/navigation/back-button/index.tsx +3 -0
- package/src/navigation/group/index.tsx +3 -0
- package/src/navigation/index.tsx +2 -0
- package/src/navigation/item/index.tsx +3 -0
- package/src/navigation/menu/index.tsx +3 -0
- package/src/navigation/stories/index.story.tsx +7 -1
- package/src/navigator/navigator-provider/component.tsx +7 -1
- package/src/placeholder/style.scss +3 -7
- package/src/progress-bar/index.tsx +8 -2
- package/src/progress-bar/styles.ts +2 -3
- package/src/progress-bar/test/index.tsx +4 -1
- package/src/select-control/index.tsx +1 -19
- package/src/slot-fill/bubbles-virtually/observable-map.ts +79 -0
- package/src/slot-fill/bubbles-virtually/slot-fill-context.ts +3 -6
- package/src/slot-fill/bubbles-virtually/slot-fill-provider.tsx +10 -18
- package/src/slot-fill/bubbles-virtually/use-slot-fills.ts +2 -10
- package/src/slot-fill/bubbles-virtually/use-slot.ts +2 -10
- package/src/slot-fill/test/observable-map.js +83 -0
- package/src/slot-fill/types.ts +7 -2
- package/src/snackbar/index.tsx +1 -1
- package/src/style.scss +1 -0
- package/src/tabs/index.tsx +8 -0
- package/src/tabs/test/index.tsx +38 -0
- package/src/text/styles.ts +1 -0
- package/src/text/test/__snapshots__/index.tsx.snap +4 -1
- package/src/toggle-control/index.tsx +16 -11
- package/src/toolbar/toolbar-group/style.scss +1 -6
- package/src/tooltip/test/index.tsx +5 -8
- package/src/truncate/hook.ts +4 -0
- package/src/utils/reduce-motion.js +4 -0
- package/tsconfig.tsbuildinfo +1 -1
- package/build/external-link/styles/external-link-styles.js +0 -25
- package/build/external-link/styles/external-link-styles.js.map +0 -1
- package/build-module/external-link/styles/external-link-styles.js +0 -25
- package/build-module/external-link/styles/external-link-styles.js.map +0 -1
- package/build-types/external-link/styles/external-link-styles.d.ts +0 -10
- package/build-types/external-link/styles/external-link-styles.d.ts.map +0 -1
- package/src/external-link/styles/external-link-styles.ts +0 -17
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Path","SVG","createElement","xmlns","viewBox","d","fill"],"sources":["@wordpress/components/src/mobile/image/icon-retry.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { Path, SVG } from '@wordpress/components';\n\nexport default (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z\" />\n\t\t<Path d=\"M0 0h24v24H0z\" fill={ 'none' } />\n\t</SVG>\n);\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,IAAI,EAAEC,GAAG,QAAQ,uBAAuB;AAEjD,eACCC,aAAA,CAACD,GAAG;EAACE,KAAK,EAAC,4BAA4B;EAACC,OAAO,EAAC;AAAW,GAC1DF,aAAA,CAACF,IAAI;EAACK,CAAC,EAAC;AAA4M,CAAE,CAAC,EACvNH,aAAA,CAACF,IAAI;EAACK,CAAC,EAAC,eAAe;EAACC,IAAI,EAAG;AAAQ,CAAE,CACrC,CAAC"}
|
|
1
|
+
{"version":3,"names":["Path","SVG","createElement","xmlns","viewBox","d","fill"],"sources":["@wordpress/components/src/mobile/image/icon-retry.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { Path, SVG } from '@wordpress/components';\n\nexport default (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Path d=\"M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z\" />\n\t\t<Path d=\"M0 0h24v24H0z\" fill={ 'none' } />\n\t</SVG>\n);\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,IAAI,EAAEC,GAAG,QAAQ,uBAAuB;AAEjD,eACCC,aAAA,CAACD,GAAG;EAACE,KAAK,EAAC,4BAA4B;EAACC,OAAO,EAAC;AAAW,GAC1DF,aAAA,CAACF,IAAI;EAACK,CAAC,EAAC;AAA4M,CAAE,CAAC,EACvNH,aAAA,CAACF,IAAI;EAACK,CAAC,EAAC,eAAe;EAACC,IAAI,EAAG;AAAQ,CAAE,CACrC,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["TouchableWithoutFeedback","View","Platform","Icon","__","MediaEdit","SvgIconCustomize","styles","accessibilityHint","OS","ImageEditingButton","onSelectMediaUploadOption","openMediaOptions","pickerOptions","url","createElement","onSelect","source","uri","openReplaceMediaOptions","render","open","mediaOptions","accessibilityLabel","accessibilityRole","onPress","style","editContainer","edit","size","icon","iconCustomise"],"sources":["@wordpress/components/src/mobile/image/image-editing-button.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { TouchableWithoutFeedback, View, Platform } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Icon } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { MediaEdit } from '../media-edit';\nimport SvgIconCustomize from './icon-customize';\nimport styles from './style.scss';\n\nconst accessibilityHint =\n\tPlatform.OS === 'ios'\n\t\t? __(\n\t\t\t\t'Double tap to open Action Sheet to edit, replace, or clear the image'\n\t\t )\n\t\t: __(\n\t\t\t\t'Double tap to open Bottom Sheet to edit, replace, or clear the image'\n\t\t );\n\nconst ImageEditingButton = ( {\n\tonSelectMediaUploadOption,\n\topenMediaOptions,\n\tpickerOptions,\n\turl,\n} ) => {\n\treturn (\n\t\t<MediaEdit\n\t\t\tonSelect={ onSelectMediaUploadOption }\n\t\t\tsource={ { uri: url } }\n\t\t\topenReplaceMediaOptions={ openMediaOptions }\n\t\t\trender={ ( { open, mediaOptions } ) => (\n\t\t\t\t<TouchableWithoutFeedback\n\t\t\t\t\taccessibilityHint={ accessibilityHint }\n\t\t\t\t\taccessibilityLabel={ __( 'Edit image' ) }\n\t\t\t\t\taccessibilityRole={ 'button' }\n\t\t\t\t\tonPress={ open }\n\t\t\t\t>\n\t\t\t\t\t<View style={ styles.editContainer }>\n\t\t\t\t\t\t<View style={ styles.edit }>\n\t\t\t\t\t\t\t{ mediaOptions() }\n\t\t\t\t\t\t\t<Icon\n\t\t\t\t\t\t\t\tsize={ 16 }\n\t\t\t\t\t\t\t\ticon={ SvgIconCustomize }\n\t\t\t\t\t\t\t\t{ ...styles.iconCustomise }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</View>\n\t\t\t\t</TouchableWithoutFeedback>\n\t\t\t) }\n\t\t\tpickerOptions={ pickerOptions }\n\t\t/>\n\t);\n};\n\nexport default ImageEditingButton;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,wBAAwB,EAAEC,IAAI,EAAEC,QAAQ,QAAQ,cAAc;;AAEvE;AACA;AACA;AACA,SAASC,IAAI,QAAQ,uBAAuB;AAC5C,SAASC,EAAE,QAAQ,iBAAiB;;AAEpC;AACA;AACA;AACA,SAASC,SAAS,QAAQ,eAAe;AACzC,OAAOC,gBAAgB,MAAM,kBAAkB;AAC/C,OAAOC,MAAM,MAAM,cAAc;AAEjC,MAAMC,iBAAiB,GACtBN,QAAQ,CAACO,EAAE,KAAK,KAAK,GAClBL,EAAE,CACF,sEACA,CAAC,GACDA,EAAE,CACF,sEACA,CAAC;AAEL,MAAMM,kBAAkB,GAAGA,CAAE;EAC5BC,yBAAyB;EACzBC,gBAAgB;EAChBC,aAAa;EACbC;AACD,CAAC,KAAM;EACN,OACCC,aAAA,CAACV,SAAS;IACTW,QAAQ,EAAGL,yBAA2B;IACtCM,MAAM,EAAG;MAAEC,GAAG,EAAEJ;IAAI,CAAG;IACvBK,uBAAuB,EAAGP,gBAAkB;IAC5CQ,MAAM,EAAGA,CAAE;MAAEC,IAAI;MAAEC;IAAa,CAAC,KAChCP,aAAA,CAACf,wBAAwB;MACxBQ,iBAAiB,EAAGA,iBAAmB;MACvCe,kBAAkB,EAAGnB,EAAE,CAAE,YAAa,CAAG;MACzCoB,iBAAiB,EAAG,QAAU;MAC9BC,OAAO,EAAGJ;IAAM,GAEhBN,aAAA,CAACd,IAAI;MAACyB,KAAK,EAAGnB,MAAM,CAACoB;IAAe,GACnCZ,aAAA,CAACd,IAAI;MAACyB,KAAK,EAAGnB,MAAM,CAACqB;IAAM,GACxBN,YAAY,CAAC,CAAC,EAChBP,aAAA,CAACZ,IAAI;MACJ0B,IAAI,EAAG,EAAI;MACXC,IAAI,EAAGxB,gBAAkB;MAAA,GACpBC,MAAM,CAACwB;IAAa,CACzB,CACI,CACD,CACmB,CACxB;IACHlB,aAAa,EAAGA;EAAe,CAC/B,CAAC;AAEJ,CAAC;AAED,eAAeH,kBAAkB"}
|
|
1
|
+
{"version":3,"names":["TouchableWithoutFeedback","View","Platform","Icon","__","MediaEdit","SvgIconCustomize","styles","accessibilityHint","OS","ImageEditingButton","onSelectMediaUploadOption","openMediaOptions","pickerOptions","url","createElement","onSelect","source","uri","openReplaceMediaOptions","render","open","mediaOptions","accessibilityLabel","accessibilityRole","onPress","style","editContainer","edit","size","icon","iconCustomise"],"sources":["@wordpress/components/src/mobile/image/image-editing-button.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { TouchableWithoutFeedback, View, Platform } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Icon } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { MediaEdit } from '../media-edit';\nimport SvgIconCustomize from './icon-customize';\nimport styles from './style.scss';\n\nconst accessibilityHint =\n\tPlatform.OS === 'ios'\n\t\t? __(\n\t\t\t\t'Double tap to open Action Sheet to edit, replace, or clear the image'\n\t\t )\n\t\t: __(\n\t\t\t\t'Double tap to open Bottom Sheet to edit, replace, or clear the image'\n\t\t );\n\nconst ImageEditingButton = ( {\n\tonSelectMediaUploadOption,\n\topenMediaOptions,\n\tpickerOptions,\n\turl,\n} ) => {\n\treturn (\n\t\t<MediaEdit\n\t\t\tonSelect={ onSelectMediaUploadOption }\n\t\t\tsource={ { uri: url } }\n\t\t\topenReplaceMediaOptions={ openMediaOptions }\n\t\t\trender={ ( { open, mediaOptions } ) => (\n\t\t\t\t<TouchableWithoutFeedback\n\t\t\t\t\taccessibilityHint={ accessibilityHint }\n\t\t\t\t\taccessibilityLabel={ __( 'Edit image' ) }\n\t\t\t\t\taccessibilityRole={ 'button' }\n\t\t\t\t\tonPress={ open }\n\t\t\t\t>\n\t\t\t\t\t<View style={ styles.editContainer }>\n\t\t\t\t\t\t<View style={ styles.edit }>\n\t\t\t\t\t\t\t{ mediaOptions() }\n\t\t\t\t\t\t\t<Icon\n\t\t\t\t\t\t\t\tsize={ 16 }\n\t\t\t\t\t\t\t\ticon={ SvgIconCustomize }\n\t\t\t\t\t\t\t\t{ ...styles.iconCustomise }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</View>\n\t\t\t\t</TouchableWithoutFeedback>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Aa,CACzB,CACI,CACD,CACmB,CACxB;IACHlB,aAAa,EAAGA;EAAe,CAC/B,CAAC;AAEJ,CAAC;AAED,eAAeH,kBAAkB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Image","RNImage","Text","View","FastImage","__","Icon","image","offline","usePreferredColorSchemeStyle","useEffect","useState","Platform","getImageWithFocalPointStyles","styles","SvgIconRetry","ImageEditingButton","ICON_TYPE","OFFLINE","PLACEHOLDER","RETRY","UPLOAD","ImageComponent","align","alt","editButton","focalPoint","height","imageHeight","highlightSelected","isSelected","shouldUseFastImage","isUploadFailed","isUploadPaused","isUploadInProgress","mediaPickerOptions","onImageDataLoad","onSelectMediaUploadOption","openMediaOptions","resizeMode","retryMessage","retryIcon","url","shapeStyle","style","width","imageWidth","imageData","setImageData","containerSize","setContainerSize","localURL","setLocalURL","networkURL","setNetworkURL","networkImageLoaded","setNetworkImageLoaded","isAndroid","imageResizeMode","isCurrent","getSize","imgWidth","imgHeight","metaData","aspectRatio","startsWith","isIOS","prefetch","then","onContainerLayout","event","nativeEvent","layout","getIcon","iconType","icon","iconStyle","iconRetryStyles","iconOfflineStyles","iconPlaceholderStyles","iconUploadStyles","createElement","iconPlaceholder","iconPlaceholderDark","iconUpload","iconUploadDark","iconOffline","iconOfflineDark","retryIconStyles","retryIconDark","iconRetry","iconRetryDark","retryContainerStyles","retryContainer","retryContainerDark","uploadFailedTextStyles","uploadFailedText","uploadFailedTextDark","placeholderStyles","imageContainerUpload","imageContainerUploadDark","imageContainerUploadWithFocalpoint","customWidth","wide","imageContainerStyles","imageContent","focalPointContainer","imageStyles","undefined","calculatedSelectedHeight","isNaN","imageSelectedStyles","imageBorder","imageBorderDark","container","alignItems","onLayout","accessible","disabled","accessibilityLabel","accessibilityHint","accessibilityRole","key","imageUploadingIconContainer","focalPointContent","Fragment","fadeDuration","source","uri","resizeMethod","testID","nonVisibleImage","onLoad","imageContainer","customRetryIcon","pickerOptions"],"sources":["@wordpress/components/src/mobile/image/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Image as RNImage, Text, View } from 'react-native';\nimport FastImage from 'react-native-fast-image';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { Icon } from '@wordpress/components';\nimport { image, offline } from '@wordpress/icons';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\nimport { useEffect, useState, Platform } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { getImageWithFocalPointStyles } from './utils';\nimport styles from './style.scss';\nimport SvgIconRetry from './icon-retry';\nimport ImageEditingButton from './image-editing-button';\n\nconst ICON_TYPE = {\n\tOFFLINE: 'offline',\n\tPLACEHOLDER: 'placeholder',\n\tRETRY: 'retry',\n\tUPLOAD: 'upload',\n};\n\nconst ImageComponent = ( {\n\talign,\n\talt,\n\teditButton = true,\n\tfocalPoint,\n\theight: imageHeight,\n\thighlightSelected = true,\n\tisSelected,\n\tshouldUseFastImage,\n\tisUploadFailed,\n\tisUploadPaused,\n\tisUploadInProgress,\n\tmediaPickerOptions,\n\tonImageDataLoad,\n\tonSelectMediaUploadOption,\n\topenMediaOptions,\n\tresizeMode,\n\tretryMessage,\n\tretryIcon,\n\turl,\n\tshapeStyle,\n\tstyle,\n\twidth: imageWidth,\n} ) => {\n\tconst [ imageData, setImageData ] = useState( null );\n\tconst [ containerSize, setContainerSize ] = useState( null );\n\tconst [ localURL, setLocalURL ] = useState( null );\n\tconst [ networkURL, setNetworkURL ] = useState( null );\n\tconst [ networkImageLoaded, setNetworkImageLoaded ] = useState( false );\n\n\t// Disabled for Android due to https://github.com/WordPress/gutenberg/issues/43149\n\tconst Image =\n\t\t! shouldUseFastImage || Platform.isAndroid ? RNImage : FastImage;\n\tconst imageResizeMode =\n\t\t! shouldUseFastImage || Platform.isAndroid\n\t\t\t? resizeMode\n\t\t\t: FastImage.resizeMode[ resizeMode ];\n\n\tuseEffect( () => {\n\t\tlet isCurrent = true;\n\t\tif ( url ) {\n\t\t\tRNImage.getSize( url, ( imgWidth, imgHeight ) => {\n\t\t\t\tif ( ! isCurrent ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tconst metaData = {\n\t\t\t\t\taspectRatio: imgWidth / imgHeight,\n\t\t\t\t\twidth: imgWidth,\n\t\t\t\t\theight: imgHeight,\n\t\t\t\t};\n\t\t\t\tsetImageData( metaData );\n\t\t\t\tif ( onImageDataLoad ) {\n\t\t\t\t\tonImageDataLoad( metaData );\n\t\t\t\t}\n\t\t\t} );\n\n\t\t\tif ( url.startsWith( 'file:///' ) ) {\n\t\t\t\tsetLocalURL( url );\n\t\t\t\tsetNetworkURL( null );\n\t\t\t\tsetNetworkImageLoaded( false );\n\t\t\t} else if ( url.startsWith( 'https://' ) ) {\n\t\t\t\tif ( Platform.isIOS ) {\n\t\t\t\t\tsetNetworkURL( url );\n\t\t\t\t} else if ( Platform.isAndroid ) {\n\t\t\t\t\tRNImage.prefetch( url ).then(\n\t\t\t\t\t\t() => {\n\t\t\t\t\t\t\tif ( ! isCurrent ) {\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tsetNetworkURL( url );\n\t\t\t\t\t\t\tsetNetworkImageLoaded( true );\n\t\t\t\t\t\t},\n\t\t\t\t\t\t() => {\n\t\t\t\t\t\t\t// This callback is called when the image fails to load,\n\t\t\t\t\t\t\t// but these events are handled by `isUploadFailed`\n\t\t\t\t\t\t\t// and `isUploadPaused` events instead.\n\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t// Ignoring the error event will persist the local image URI.\n\t\t\t\t\t\t}\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn () => ( isCurrent = false );\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ url ] );\n\n\tconst onContainerLayout = ( event ) => {\n\t\tconst { height, width } = event.nativeEvent.layout;\n\n\t\tif (\n\t\t\twidth !== 0 &&\n\t\t\theight !== 0 &&\n\t\t\t( containerSize?.width !== width ||\n\t\t\t\tcontainerSize?.height !== height )\n\t\t) {\n\t\t\tsetContainerSize( { width, height } );\n\t\t}\n\t};\n\n\tconst getIcon = ( iconType ) => {\n\t\tlet icon;\n\t\tlet iconStyle;\n\t\tswitch ( iconType ) {\n\t\t\tcase ICON_TYPE.RETRY:\n\t\t\t\ticon = retryIcon || SvgIconRetry;\n\t\t\t\ticonStyle = iconRetryStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.OFFLINE:\n\t\t\t\ticon = offline;\n\t\t\t\ticonStyle = iconOfflineStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.PLACEHOLDER:\n\t\t\t\ticon = image;\n\t\t\t\ticonStyle = iconPlaceholderStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.UPLOAD:\n\t\t\t\ticon = image;\n\t\t\t\ticonStyle = iconUploadStyles;\n\t\t\t\tbreak;\n\t\t}\n\t\treturn <Icon icon={ icon } { ...iconStyle } />;\n\t};\n\n\tconst iconPlaceholderStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconPlaceholder,\n\t\tstyles.iconPlaceholderDark\n\t);\n\n\tconst iconUploadStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconUpload,\n\t\tstyles.iconUploadDark\n\t);\n\n\tconst iconOfflineStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconOffline,\n\t\tstyles.iconOfflineDark\n\t);\n\n\tconst retryIconStyles = usePreferredColorSchemeStyle(\n\t\tstyles.retryIcon,\n\t\tstyles.retryIconDark\n\t);\n\n\tconst iconRetryStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconRetry,\n\t\tstyles.iconRetryDark\n\t);\n\n\tconst retryContainerStyles = usePreferredColorSchemeStyle(\n\t\tstyles.retryContainer,\n\t\tstyles.retryContainerDark\n\t);\n\n\tconst uploadFailedTextStyles = usePreferredColorSchemeStyle(\n\t\tstyles.uploadFailedText,\n\t\tstyles.uploadFailedTextDark\n\t);\n\n\tconst placeholderStyles = [\n\t\tusePreferredColorSchemeStyle(\n\t\t\tstyles.imageContainerUpload,\n\t\t\tstyles.imageContainerUploadDark\n\t\t),\n\t\tfocalPoint && styles.imageContainerUploadWithFocalpoint,\n\t\timageHeight && { height: imageHeight },\n\t];\n\n\tconst customWidth =\n\t\timageData?.width < containerSize?.width\n\t\t\t? imageData?.width\n\t\t\t: styles.wide?.width;\n\n\tconst imageContainerStyles = [\n\t\tstyles.imageContent,\n\t\t{\n\t\t\twidth:\n\t\t\t\timageWidth === styles.wide?.width ||\n\t\t\t\t( imageData &&\n\t\t\t\t\timageWidth > 0 &&\n\t\t\t\t\timageWidth < containerSize?.width )\n\t\t\t\t\t? imageWidth\n\t\t\t\t\t: customWidth,\n\t\t},\n\t\tresizeMode && { width: styles.wide?.width },\n\t\tfocalPoint && styles.focalPointContainer,\n\t];\n\n\tconst imageStyles = [\n\t\t{\n\t\t\theight: containerSize?.height,\n\t\t},\n\t\t! resizeMode && {\n\t\t\taspectRatio: imageData?.aspectRatio,\n\t\t},\n\t\tfocalPoint && styles.focalPoint,\n\t\tfocalPoint &&\n\t\t\tgetImageWithFocalPointStyles(\n\t\t\t\tfocalPoint,\n\t\t\t\tcontainerSize,\n\t\t\t\timageData\n\t\t\t),\n\t\t! focalPoint &&\n\t\t\timageData &&\n\t\t\tcontainerSize && {\n\t\t\t\theight:\n\t\t\t\t\timageData?.width > containerSize?.width && ! imageWidth\n\t\t\t\t\t\t? containerSize?.width / imageData?.aspectRatio\n\t\t\t\t\t\t: undefined,\n\t\t\t},\n\t\timageHeight && { height: imageHeight },\n\t\tshapeStyle,\n\t];\n\n\t// On iOS, add 1 to height to account for the 1px non-visible image\n\t// that is used to determine when the network image has loaded\n\t// We also must verify that it is not NaN, as it can be NaN when the image is loading.\n\t// This is not necessary on Android as the non-visible image is not used.\n\tlet calculatedSelectedHeight;\n\tif ( Platform.isIOS ) {\n\t\tcalculatedSelectedHeight =\n\t\t\tcontainerSize && ! isNaN( containerSize.height )\n\t\t\t\t? containerSize.height + 1\n\t\t\t\t: 0;\n\t} else {\n\t\tcalculatedSelectedHeight = containerSize?.height;\n\t}\n\n\tconst imageSelectedStyles = [\n\t\tusePreferredColorSchemeStyle(\n\t\t\tstyles.imageBorder,\n\t\t\tstyles.imageBorderDark\n\t\t),\n\t\t{\n\t\t\theight: calculatedSelectedHeight,\n\t\t},\n\t];\n\n\treturn (\n\t\t<View\n\t\t\tstyle={ [\n\t\t\t\tstyles.container,\n\t\t\t\t// Only set alignItems if an image exists because alignItems causes the placeholder\n\t\t\t\t// to disappear when an aligned image can't be downloaded\n\t\t\t\t// https://github.com/wordpress-mobile/gutenberg-mobile/issues/1592\n\t\t\t\timageData && align && { alignItems: align },\n\t\t\t\tstyle,\n\t\t\t] }\n\t\t\tonLayout={ onContainerLayout }\n\t\t>\n\t\t\t<View\n\t\t\t\taccessible\n\t\t\t\tdisabled={ ! isSelected }\n\t\t\t\taccessibilityLabel={ alt }\n\t\t\t\taccessibilityHint={ __( 'Double tap and hold to edit' ) }\n\t\t\t\taccessibilityRole={ 'imagebutton' }\n\t\t\t\tkey={ url }\n\t\t\t\tstyle={ imageContainerStyles }\n\t\t\t>\n\t\t\t\t{ isSelected && highlightSelected && (\n\t\t\t\t\t<View style={ imageSelectedStyles } />\n\t\t\t\t) }\n\n\t\t\t\t{ ! imageData ? (\n\t\t\t\t\t<View style={ placeholderStyles }>\n\t\t\t\t\t\t<View style={ styles.imageUploadingIconContainer }>\n\t\t\t\t\t\t\t{ getIcon( ICON_TYPE.UPLOAD ) }\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</View>\n\t\t\t\t) : (\n\t\t\t\t\t<View style={ focalPoint && styles.focalPointContent }>\n\t\t\t\t\t\t{ Platform.isAndroid && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t{ networkImageLoaded && networkURL && (\n\t\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\t\tfadeDuration={ 0 }\n\t\t\t\t\t\t\t\t\t\tsource={ { uri: networkURL } }\n\t\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\t\ttestID={ `network-image-${ url }` }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t{ ! networkImageLoaded && ! networkURL && (\n\t\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\t\tfadeDuration={ 0 }\n\t\t\t\t\t\t\t\t\t\tsource={ { uri: localURL } }\n\t\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t) }\n\t\t\t\t\t\t{ Platform.isIOS && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\tsource={ {\n\t\t\t\t\t\t\t\t\t\turi:\n\t\t\t\t\t\t\t\t\t\t\tnetworkURL && networkImageLoaded\n\t\t\t\t\t\t\t\t\t\t\t\t? networkURL\n\t\t\t\t\t\t\t\t\t\t\t\t: localURL || url,\n\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\ttestID={ `network-image-${\n\t\t\t\t\t\t\t\t\t\tnetworkURL && networkImageLoaded\n\t\t\t\t\t\t\t\t\t\t\t? networkURL\n\t\t\t\t\t\t\t\t\t\t\t: localURL || url\n\t\t\t\t\t\t\t\t\t}` }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\tsource={ { uri: networkURL } }\n\t\t\t\t\t\t\t\t\tstyle={ styles.nonVisibleImage }\n\t\t\t\t\t\t\t\t\tonLoad={ () => {\n\t\t\t\t\t\t\t\t\t\tsetNetworkImageLoaded( true );\n\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t) }\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\n\t\t\t\t{ ( isUploadFailed || isUploadPaused ) && retryMessage && (\n\t\t\t\t\t<View\n\t\t\t\t\t\tstyle={ [\n\t\t\t\t\t\t\tstyles.imageContainer,\n\t\t\t\t\t\t\tretryContainerStyles,\n\t\t\t\t\t\t] }\n\t\t\t\t\t>\n\t\t\t\t\t\t<View\n\t\t\t\t\t\t\tstyle={ [\n\t\t\t\t\t\t\t\tretryIconStyles,\n\t\t\t\t\t\t\t\tretryIcon && styles.customRetryIcon,\n\t\t\t\t\t\t\t] }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ isUploadPaused\n\t\t\t\t\t\t\t\t? getIcon( ICON_TYPE.OFFLINE )\n\t\t\t\t\t\t\t\t: getIcon( ICON_TYPE.RETRY ) }\n\t\t\t\t\t\t</View>\n\t\t\t\t\t\t<Text style={ uploadFailedTextStyles }>\n\t\t\t\t\t\t\t{ retryMessage }\n\t\t\t\t\t\t</Text>\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\t\t\t</View>\n\n\t\t\t{ editButton && isSelected && ! isUploadInProgress && (\n\t\t\t\t<ImageEditingButton\n\t\t\t\t\tonSelectMediaUploadOption={ onSelectMediaUploadOption }\n\t\t\t\t\topenMediaOptions={ openMediaOptions }\n\t\t\t\t\turl={\n\t\t\t\t\t\t! ( isUploadFailed || isUploadPaused ) &&\n\t\t\t\t\t\timageData &&\n\t\t\t\t\t\turl\n\t\t\t\t\t}\n\t\t\t\t\tpickerOptions={ mediaPickerOptions }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</View>\n\t);\n};\n\nexport default ImageComponent;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,KAAK,IAAIC,OAAO,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAC3D,OAAOC,SAAS,MAAM,yBAAyB;;AAE/C;AACA;AACA;AACA,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SAASC,IAAI,QAAQ,uBAAuB;AAC5C,SAASC,KAAK,EAAEC,OAAO,QAAQ,kBAAkB;AACjD,SAASC,4BAA4B,QAAQ,oBAAoB;AACjE,SAASC,SAAS,EAAEC,QAAQ,EAAEC,QAAQ,QAAQ,oBAAoB;;AAElE;AACA;AACA;AACA,SAASC,4BAA4B,QAAQ,SAAS;AACtD,OAAOC,MAAM,MAAM,cAAc;AACjC,OAAOC,YAAY,MAAM,cAAc;AACvC,OAAOC,kBAAkB,MAAM,wBAAwB;AAEvD,MAAMC,SAAS,GAAG;EACjBC,OAAO,EAAE,SAAS;EAClBC,WAAW,EAAE,aAAa;EAC1BC,KAAK,EAAE,OAAO;EACdC,MAAM,EAAE;AACT,CAAC;AAED,MAAMC,cAAc,GAAGA,CAAE;EACxBC,KAAK;EACLC,GAAG;EACHC,UAAU,GAAG,IAAI;EACjBC,UAAU;EACVC,MAAM,EAAEC,WAAW;EACnBC,iBAAiB,GAAG,IAAI;EACxBC,UAAU;EACVC,kBAAkB;EAClBC,cAAc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qH,eAAiB;IAChCC,MAAM,EAAGA,CAAA,KAAM;MACd5E,qBAAqB,CAAE,IAAK,CAAC;IAC9B;EAAG,CACH,CACA,CAEE,CACN,EAEC,CAAExB,cAAc,IAAIC,cAAc,KAAMO,YAAY,IACrDyC,aAAA,CAAC9E,IAAI;IACJyC,KAAK,EAAG,CACP9B,MAAM,CAACuH,cAAc,EACrBzC,oBAAoB;EAClB,GAEHX,aAAA,CAAC9E,IAAI;IACJyC,KAAK,EAAG,CACP4C,eAAe,EACf/C,SAAS,IAAI3B,MAAM,CAACwH,eAAe;EACjC,GAEDrG,cAAc,GACbwC,OAAO,CAAExD,SAAS,CAACC,OAAQ,CAAC,GAC5BuD,OAAO,CAAExD,SAAS,CAACG,KAAM,CACvB,CAAC,EACP6D,aAAA,CAAC/E,IAAI;IAAC0C,KAAK,EAAGmD;EAAwB,GACnCvD,YACG,CACD,CAEF,CAAC,EAELf,UAAU,IAAIK,UAAU,IAAI,CAAEI,kBAAkB,IACjD+C,aAAA,CAACjE,kBAAkB;IAClBqB,yBAAyB,EAAGA,yBAA2B;IACvDC,gBAAgB,EAAGA,gBAAkB;IACrCI,GAAG,EACF,EAAIV,cAAc,IAAIC,cAAc,CAAE,IACtCc,SAAS,IACTL,GACA;IACD6F,aAAa,EAAGpG;EAAoB,CACpC,CAEG,CAAC;AAET,CAAC;AAED,eAAeb,cAAc"}
|
|
1
|
+
{"version":3,"names":["Image","RNImage","Text","View","FastImage","__","Icon","image","offline","usePreferredColorSchemeStyle","useEffect","useState","Platform","getImageWithFocalPointStyles","styles","SvgIconRetry","ImageEditingButton","ICON_TYPE","OFFLINE","PLACEHOLDER","RETRY","UPLOAD","ImageComponent","align","alt","editButton","focalPoint","height","imageHeight","highlightSelected","isSelected","shouldUseFastImage","isUploadFailed","isUploadPaused","isUploadInProgress","mediaPickerOptions","onImageDataLoad","onSelectMediaUploadOption","openMediaOptions","resizeMode","retryMessage","retryIcon","url","shapeStyle","style","width","imageWidth","imageData","setImageData","containerSize","setContainerSize","localURL","setLocalURL","networkURL","setNetworkURL","networkImageLoaded","setNetworkImageLoaded","isAndroid","imageResizeMode","isCurrent","getSize","imgWidth","imgHeight","metaData","aspectRatio","startsWith","isIOS","prefetch","then","onContainerLayout","event","nativeEvent","layout","getIcon","iconType","icon","iconStyle","iconRetryStyles","iconOfflineStyles","iconPlaceholderStyles","iconUploadStyles","createElement","iconPlaceholder","iconPlaceholderDark","iconUpload","iconUploadDark","iconOffline","iconOfflineDark","retryIconStyles","retryIconDark","iconRetry","iconRetryDark","retryContainerStyles","retryContainer","retryContainerDark","uploadFailedTextStyles","uploadFailedText","uploadFailedTextDark","placeholderStyles","imageContainerUpload","imageContainerUploadDark","imageContainerUploadWithFocalpoint","customWidth","wide","imageContainerStyles","imageContent","focalPointContainer","imageStyles","undefined","calculatedSelectedHeight","isNaN","imageSelectedStyles","imageBorder","imageBorderDark","container","alignItems","onLayout","accessible","disabled","accessibilityLabel","accessibilityHint","accessibilityRole","key","imageUploadingIconContainer","focalPointContent","Fragment","fadeDuration","source","uri","resizeMethod","testID","nonVisibleImage","onLoad","imageContainer","customRetryIcon","pickerOptions"],"sources":["@wordpress/components/src/mobile/image/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Image as RNImage, Text, View } from 'react-native';\nimport FastImage from 'react-native-fast-image';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { Icon } from '@wordpress/components';\nimport { image, offline } from '@wordpress/icons';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\nimport { useEffect, useState, Platform } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { getImageWithFocalPointStyles } from './utils';\nimport styles from './style.scss';\nimport SvgIconRetry from './icon-retry';\nimport ImageEditingButton from './image-editing-button';\n\nconst ICON_TYPE = {\n\tOFFLINE: 'offline',\n\tPLACEHOLDER: 'placeholder',\n\tRETRY: 'retry',\n\tUPLOAD: 'upload',\n};\n\nconst ImageComponent = ( {\n\talign,\n\talt,\n\teditButton = true,\n\tfocalPoint,\n\theight: imageHeight,\n\thighlightSelected = true,\n\tisSelected,\n\tshouldUseFastImage,\n\tisUploadFailed,\n\tisUploadPaused,\n\tisUploadInProgress,\n\tmediaPickerOptions,\n\tonImageDataLoad,\n\tonSelectMediaUploadOption,\n\topenMediaOptions,\n\tresizeMode,\n\tretryMessage,\n\tretryIcon,\n\turl,\n\tshapeStyle,\n\tstyle,\n\twidth: imageWidth,\n} ) => {\n\tconst [ imageData, setImageData ] = useState( null );\n\tconst [ containerSize, setContainerSize ] = useState( null );\n\tconst [ localURL, setLocalURL ] = useState( null );\n\tconst [ networkURL, setNetworkURL ] = useState( null );\n\tconst [ networkImageLoaded, setNetworkImageLoaded ] = useState( false );\n\n\t// Disabled for Android due to https://github.com/WordPress/gutenberg/issues/43149\n\tconst Image =\n\t\t! shouldUseFastImage || Platform.isAndroid ? RNImage : FastImage;\n\tconst imageResizeMode =\n\t\t! shouldUseFastImage || Platform.isAndroid\n\t\t\t? resizeMode\n\t\t\t: FastImage.resizeMode[ resizeMode ];\n\n\tuseEffect( () => {\n\t\tlet isCurrent = true;\n\t\tif ( url ) {\n\t\t\tRNImage.getSize( url, ( imgWidth, imgHeight ) => {\n\t\t\t\tif ( ! isCurrent ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tconst metaData = {\n\t\t\t\t\taspectRatio: imgWidth / imgHeight,\n\t\t\t\t\twidth: imgWidth,\n\t\t\t\t\theight: imgHeight,\n\t\t\t\t};\n\t\t\t\tsetImageData( metaData );\n\t\t\t\tif ( onImageDataLoad ) {\n\t\t\t\t\tonImageDataLoad( metaData );\n\t\t\t\t}\n\t\t\t} );\n\n\t\t\tif ( url.startsWith( 'file:///' ) ) {\n\t\t\t\tsetLocalURL( url );\n\t\t\t\tsetNetworkURL( null );\n\t\t\t\tsetNetworkImageLoaded( false );\n\t\t\t} else if ( url.startsWith( 'https://' ) ) {\n\t\t\t\tif ( Platform.isIOS ) {\n\t\t\t\t\tsetNetworkURL( url );\n\t\t\t\t} else if ( Platform.isAndroid ) {\n\t\t\t\t\tRNImage.prefetch( url ).then(\n\t\t\t\t\t\t() => {\n\t\t\t\t\t\t\tif ( ! isCurrent ) {\n\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tsetNetworkURL( url );\n\t\t\t\t\t\t\tsetNetworkImageLoaded( true );\n\t\t\t\t\t\t},\n\t\t\t\t\t\t() => {\n\t\t\t\t\t\t\t// This callback is called when the image fails to load,\n\t\t\t\t\t\t\t// but these events are handled by `isUploadFailed`\n\t\t\t\t\t\t\t// and `isUploadPaused` events instead.\n\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\t// Ignoring the error event will persist the local image URI.\n\t\t\t\t\t\t}\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn () => ( isCurrent = false );\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ url ] );\n\n\tconst onContainerLayout = ( event ) => {\n\t\tconst { height, width } = event.nativeEvent.layout;\n\n\t\tif (\n\t\t\twidth !== 0 &&\n\t\t\theight !== 0 &&\n\t\t\t( containerSize?.width !== width ||\n\t\t\t\tcontainerSize?.height !== height )\n\t\t) {\n\t\t\tsetContainerSize( { width, height } );\n\t\t}\n\t};\n\n\tconst getIcon = ( iconType ) => {\n\t\tlet icon;\n\t\tlet iconStyle;\n\t\tswitch ( iconType ) {\n\t\t\tcase ICON_TYPE.RETRY:\n\t\t\t\ticon = retryIcon || SvgIconRetry;\n\t\t\t\ticonStyle = iconRetryStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.OFFLINE:\n\t\t\t\ticon = offline;\n\t\t\t\ticonStyle = iconOfflineStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.PLACEHOLDER:\n\t\t\t\ticon = image;\n\t\t\t\ticonStyle = iconPlaceholderStyles;\n\t\t\t\tbreak;\n\t\t\tcase ICON_TYPE.UPLOAD:\n\t\t\t\ticon = image;\n\t\t\t\ticonStyle = iconUploadStyles;\n\t\t\t\tbreak;\n\t\t}\n\t\treturn <Icon icon={ icon } { ...iconStyle } />;\n\t};\n\n\tconst iconPlaceholderStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconPlaceholder,\n\t\tstyles.iconPlaceholderDark\n\t);\n\n\tconst iconUploadStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconUpload,\n\t\tstyles.iconUploadDark\n\t);\n\n\tconst iconOfflineStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconOffline,\n\t\tstyles.iconOfflineDark\n\t);\n\n\tconst retryIconStyles = usePreferredColorSchemeStyle(\n\t\tstyles.retryIcon,\n\t\tstyles.retryIconDark\n\t);\n\n\tconst iconRetryStyles = usePreferredColorSchemeStyle(\n\t\tstyles.iconRetry,\n\t\tstyles.iconRetryDark\n\t);\n\n\tconst retryContainerStyles = usePreferredColorSchemeStyle(\n\t\tstyles.retryContainer,\n\t\tstyles.retryContainerDark\n\t);\n\n\tconst uploadFailedTextStyles = usePreferredColorSchemeStyle(\n\t\tstyles.uploadFailedText,\n\t\tstyles.uploadFailedTextDark\n\t);\n\n\tconst placeholderStyles = [\n\t\tusePreferredColorSchemeStyle(\n\t\t\tstyles.imageContainerUpload,\n\t\t\tstyles.imageContainerUploadDark\n\t\t),\n\t\tfocalPoint && styles.imageContainerUploadWithFocalpoint,\n\t\timageHeight && { height: imageHeight },\n\t];\n\n\tconst customWidth =\n\t\timageData?.width < containerSize?.width\n\t\t\t? imageData?.width\n\t\t\t: styles.wide?.width;\n\n\tconst imageContainerStyles = [\n\t\tstyles.imageContent,\n\t\t{\n\t\t\twidth:\n\t\t\t\timageWidth === styles.wide?.width ||\n\t\t\t\t( imageData &&\n\t\t\t\t\timageWidth > 0 &&\n\t\t\t\t\timageWidth < containerSize?.width )\n\t\t\t\t\t? imageWidth\n\t\t\t\t\t: customWidth,\n\t\t},\n\t\tresizeMode && { width: styles.wide?.width },\n\t\tfocalPoint && styles.focalPointContainer,\n\t];\n\n\tconst imageStyles = [\n\t\t{\n\t\t\theight: containerSize?.height,\n\t\t},\n\t\t! resizeMode && {\n\t\t\taspectRatio: imageData?.aspectRatio,\n\t\t},\n\t\tfocalPoint && styles.focalPoint,\n\t\tfocalPoint &&\n\t\t\tgetImageWithFocalPointStyles(\n\t\t\t\tfocalPoint,\n\t\t\t\tcontainerSize,\n\t\t\t\timageData\n\t\t\t),\n\t\t! focalPoint &&\n\t\t\timageData &&\n\t\t\tcontainerSize && {\n\t\t\t\theight:\n\t\t\t\t\timageData?.width > containerSize?.width && ! imageWidth\n\t\t\t\t\t\t? containerSize?.width / imageData?.aspectRatio\n\t\t\t\t\t\t: undefined,\n\t\t\t},\n\t\timageHeight && { height: imageHeight },\n\t\tshapeStyle,\n\t];\n\n\t// On iOS, add 1 to height to account for the 1px non-visible image\n\t// that is used to determine when the network image has loaded\n\t// We also must verify that it is not NaN, as it can be NaN when the image is loading.\n\t// This is not necessary on Android as the non-visible image is not used.\n\tlet calculatedSelectedHeight;\n\tif ( Platform.isIOS ) {\n\t\tcalculatedSelectedHeight =\n\t\t\tcontainerSize && ! isNaN( containerSize.height )\n\t\t\t\t? containerSize.height + 1\n\t\t\t\t: 0;\n\t} else {\n\t\tcalculatedSelectedHeight = containerSize?.height;\n\t}\n\n\tconst imageSelectedStyles = [\n\t\tusePreferredColorSchemeStyle(\n\t\t\tstyles.imageBorder,\n\t\t\tstyles.imageBorderDark\n\t\t),\n\t\t{\n\t\t\theight: calculatedSelectedHeight,\n\t\t},\n\t];\n\n\treturn (\n\t\t<View\n\t\t\tstyle={ [\n\t\t\t\tstyles.container,\n\t\t\t\t// Only set alignItems if an image exists because alignItems causes the placeholder\n\t\t\t\t// to disappear when an aligned image can't be downloaded\n\t\t\t\t// https://github.com/wordpress-mobile/gutenberg-mobile/issues/1592\n\t\t\t\timageData && align && { alignItems: align },\n\t\t\t\tstyle,\n\t\t\t] }\n\t\t\tonLayout={ onContainerLayout }\n\t\t>\n\t\t\t<View\n\t\t\t\taccessible\n\t\t\t\tdisabled={ ! isSelected }\n\t\t\t\taccessibilityLabel={ alt }\n\t\t\t\taccessibilityHint={ __( 'Double tap and hold to edit' ) }\n\t\t\t\taccessibilityRole={ 'imagebutton' }\n\t\t\t\tkey={ url }\n\t\t\t\tstyle={ imageContainerStyles }\n\t\t\t>\n\t\t\t\t{ isSelected && highlightSelected && (\n\t\t\t\t\t<View style={ imageSelectedStyles } />\n\t\t\t\t) }\n\n\t\t\t\t{ ! imageData ? (\n\t\t\t\t\t<View style={ placeholderStyles }>\n\t\t\t\t\t\t<View style={ styles.imageUploadingIconContainer }>\n\t\t\t\t\t\t\t{ getIcon( ICON_TYPE.UPLOAD ) }\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</View>\n\t\t\t\t) : (\n\t\t\t\t\t<View style={ focalPoint && styles.focalPointContent }>\n\t\t\t\t\t\t{ Platform.isAndroid && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t{ networkImageLoaded && networkURL && (\n\t\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\t\tfadeDuration={ 0 }\n\t\t\t\t\t\t\t\t\t\tsource={ { uri: networkURL } }\n\t\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\t\ttestID={ `network-image-${ url }` }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t{ ! networkImageLoaded && ! networkURL && (\n\t\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\t\tfadeDuration={ 0 }\n\t\t\t\t\t\t\t\t\t\tsource={ { uri: localURL } }\n\t\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t) }\n\t\t\t\t\t\t{ Platform.isIOS && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\tstyle={ imageStyles }\n\t\t\t\t\t\t\t\t\tsource={ {\n\t\t\t\t\t\t\t\t\t\turi:\n\t\t\t\t\t\t\t\t\t\t\tnetworkURL && networkImageLoaded\n\t\t\t\t\t\t\t\t\t\t\t\t? networkURL\n\t\t\t\t\t\t\t\t\t\t\t\t: localURL || url,\n\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t\t{ ...( ! focalPoint && {\n\t\t\t\t\t\t\t\t\t\tresizeMethod: 'scale',\n\t\t\t\t\t\t\t\t\t} ) }\n\t\t\t\t\t\t\t\t\tresizeMode={ imageResizeMode }\n\t\t\t\t\t\t\t\t\ttestID={ `network-image-${\n\t\t\t\t\t\t\t\t\t\tnetworkURL && networkImageLoaded\n\t\t\t\t\t\t\t\t\t\t\t? networkURL\n\t\t\t\t\t\t\t\t\t\t\t: localURL || url\n\t\t\t\t\t\t\t\t\t}` }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t<Image\n\t\t\t\t\t\t\t\t\tsource={ { uri: networkURL } }\n\t\t\t\t\t\t\t\t\tstyle={ styles.nonVisibleImage }\n\t\t\t\t\t\t\t\t\tonLoad={ () => {\n\t\t\t\t\t\t\t\t\t\tsetNetworkImageLoaded( true );\n\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t) }\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\n\t\t\t\t{ ( isUploadFailed || isUploadPaused ) && retryMessage && (\n\t\t\t\t\t<View\n\t\t\t\t\t\tstyle={ [\n\t\t\t\t\t\t\tstyles.imageContainer,\n\t\t\t\t\t\t\tretryContainerStyles,\n\t\t\t\t\t\t] }\n\t\t\t\t\t>\n\t\t\t\t\t\t<View\n\t\t\t\t\t\t\tstyle={ [\n\t\t\t\t\t\t\t\tretryIconStyles,\n\t\t\t\t\t\t\t\tretryIcon && styles.customRetryIcon,\n\t\t\t\t\t\t\t] }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ isUploadPaused\n\t\t\t\t\t\t\t\t? getIcon( ICON_TYPE.OFFLINE )\n\t\t\t\t\t\t\t\t: getIcon( ICON_TYPE.RETRY ) }\n\t\t\t\t\t\t</View>\n\t\t\t\t\t\t<Text style={ uploadFailedTextStyles }>\n\t\t\t\t\t\t\t{ retryMessage }\n\t\t\t\t\t\t</Text>\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\t\t\t</View>\n\n\t\t\t{ editButton && isSelected && ! isUploadInProgress && (\n\t\t\t\t<ImageEditingButton\n\t\t\t\t\tonSelectMediaUploadOption={ onSelectMediaUploadOption }\n\t\t\t\t\topenMediaOptions={ openMediaOptions }\n\t\t\t\t\turl={\n\t\t\t\t\t\t! ( isUploadFailed || isUploadPaused ) &&\n\t\t\t\t\t\timageData &&\n\t\t\t\t\t\turl\n\t\t\t\t\t}\n\t\t\t\t\tpickerOptions={ mediaPickerOptions }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</View>\n\t);\n};\n\nexport default ImageComponent;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,KAAK,IAAIC,OAAO,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAC3D,OAAOC,S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,EAAGmD;EAAwB,GACnCvD,YACG,CACD,CAEF,CAAC,EAELf,UAAU,IAAIK,UAAU,IAAI,CAAEI,kBAAkB,IACjD+C,aAAA,CAACjE,kBAAkB;IAClBqB,yBAAyB,EAAGA,yBAA2B;IACvDC,gBAAgB,EAAGA,gBAAkB;IACrCI,GAAG,EACF,EAAIV,cAAc,IAAIC,cAAc,CAAE,IACtCc,SAAS,IACTL,GACA;IACD6F,aAAa,EAAGpG;EAAoB,CACpC,CAEG,CAAC;AAET,CAAC;AAED,eAAeb,cAAc","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["getFocalPointOffset","imageRatio","container","imageSize","focusPoint","containerCenter","Math","floor","scaledImage","focus","focusOffset","offsetRest","containerRest","getImageWithFocalPointStyles","focalPoint","containerSize","originalImageData","imageStyle","horizontalOffset","verticalOffset","widthRatio","width","heightRatio","height","resizeMode","x","undefined","left","y","top"],"sources":["@wordpress/components/src/mobile/image/utils/index.native.js"],"sourcesContent":["function getFocalPointOffset( imageRatio, container, imageSize, focusPoint ) {\n\tconst containerCenter = Math.floor( container / 2 );\n\tconst scaledImage = Math.floor( imageSize / imageRatio );\n\tconst focus = Math.floor( focusPoint * scaledImage );\n\tlet focusOffset = focus - containerCenter;\n\tconst offsetRest = scaledImage - focus;\n\tconst containerRest = container - containerCenter;\n\n\tif ( offsetRest < containerRest ) {\n\t\tfocusOffset -= containerRest - offsetRest;\n\t}\n\n\tif ( focusOffset < 0 ) {\n\t\tfocusOffset = 0;\n\t}\n\n\treturn -focusOffset;\n}\n\nexport function getImageWithFocalPointStyles(\n\tfocalPoint,\n\tcontainerSize,\n\toriginalImageData\n) {\n\tconst imageStyle = {};\n\tif ( focalPoint && containerSize && originalImageData ) {\n\t\tlet horizontalOffset = 0;\n\t\tlet verticalOffset = 0;\n\t\tconst widthRatio = originalImageData.width / containerSize.width;\n\t\tconst heightRatio = originalImageData.height / containerSize.height;\n\n\t\timageStyle.resizeMode = 'stretch';\n\n\t\tif ( widthRatio > heightRatio ) {\n\t\t\thorizontalOffset = getFocalPointOffset(\n\t\t\t\theightRatio,\n\t\t\t\tcontainerSize.width,\n\t\t\t\toriginalImageData.width,\n\t\t\t\tfocalPoint.x\n\t\t\t);\n\t\t\timageStyle.width = undefined;\n\t\t\timageStyle.left = horizontalOffset;\n\t\t} else if ( widthRatio < heightRatio ) {\n\t\t\tverticalOffset = getFocalPointOffset(\n\t\t\t\twidthRatio,\n\t\t\t\tcontainerSize.height,\n\t\t\t\toriginalImageData.height,\n\t\t\t\tfocalPoint.y\n\t\t\t);\n\t\t\timageStyle.height = undefined;\n\t\t\timageStyle.top = verticalOffset;\n\t\t}\n\n\t\treturn imageStyle;\n\t}\n\n\treturn imageStyle;\n}\n"],"mappings":"AAAA,SAASA,mBAAmBA,CAAEC,UAAU,EAAEC,SAAS,EAAEC,SAAS,EAAEC,UAAU,EAAG;EAC5E,MAAMC,eAAe,GAAGC,IAAI,CAACC,KAAK,CAAEL,SAAS,GAAG,CAAE,CAAC;EACnD,MAAMM,WAAW,GAAGF,IAAI,CAACC,KAAK,CAAEJ,SAAS,GAAGF,UAAW,CAAC;EACxD,MAAMQ,KAAK,GAAGH,IAAI,CAACC,KAAK,CAAEH,UAAU,GAAGI,WAAY,CAAC;EACpD,IAAIE,WAAW,GAAGD,KAAK,GAAGJ,eAAe;EACzC,MAAMM,UAAU,GAAGH,WAAW,GAAGC,KAAK;EACtC,MAAMG,aAAa,GAAGV,SAAS,GAAGG,eAAe;EAEjD,IAAKM,UAAU,GAAGC,aAAa,EAAG;IACjCF,WAAW,IAAIE,aAAa,GAAGD,UAAU;EAC1C;EAEA,IAAKD,WAAW,GAAG,CAAC,EAAG;IACtBA,WAAW,GAAG,CAAC;EAChB;EAEA,OAAO,CAACA,WAAW;AACpB;AAEA,OAAO,SAASG,4BAA4BA,CAC3CC,UAAU,EACVC,aAAa,EACbC,iBAAiB,EAChB;EACD,MAAMC,UAAU,GAAG,CAAC,CAAC;EACrB,IAAKH,UAAU,IAAIC,aAAa,IAAIC,iBAAiB,EAAG;IACvD,IAAIE,gBAAgB,GAAG,CAAC;IACxB,IAAIC,cAAc,GAAG,CAAC;IACtB,MAAMC,UAAU,GAAGJ,iBAAiB,CAACK,KAAK,GAAGN,aAAa,CAACM,KAAK;IAChE,MAAMC,WAAW,GAAGN,iBAAiB,CAACO,MAAM,GAAGR,aAAa,CAACQ,MAAM;IAEnEN,UAAU,CAACO,UAAU,GAAG,SAAS;IAEjC,IAAKJ,UAAU,GAAGE,WAAW,EAAG;MAC/BJ,gBAAgB,GAAGlB,mBAAmB,CACrCsB,WAAW,EACXP,aAAa,CAACM,KAAK,EACnBL,iBAAiB,CAACK,KAAK,EACvBP,UAAU,CAACW,CACZ,CAAC;MACDR,UAAU,CAACI,KAAK,GAAGK,SAAS;MAC5BT,UAAU,CAACU,IAAI,GAAGT,gBAAgB;IACnC,CAAC,MAAM,IAAKE,UAAU,GAAGE,WAAW,EAAG;MACtCH,cAAc,GAAGnB,mBAAmB,CACnCoB,UAAU,EACVL,aAAa,CAACQ,MAAM,EACpBP,iBAAiB,CAACO,MAAM,EACxBT,UAAU,CAACc,CACZ,CAAC;MACDX,UAAU,CAACM,MAAM,GAAGG,SAAS;MAC7BT,UAAU,CAACY,GAAG,GAAGV,cAAc;IAChC;IAEA,OAAOF,UAAU;EAClB;EAEA,OAAOA,UAAU;AAClB"}
|
|
1
|
+
{"version":3,"names":["getFocalPointOffset","imageRatio","container","imageSize","focusPoint","containerCenter","Math","floor","scaledImage","focus","focusOffset","offsetRest","containerRest","getImageWithFocalPointStyles","focalPoint","containerSize","originalImageData","imageStyle","horizontalOffset","verticalOffset","widthRatio","width","heightRatio","height","resizeMode","x","undefined","left","y","top"],"sources":["@wordpress/components/src/mobile/image/utils/index.native.js"],"sourcesContent":["function getFocalPointOffset( imageRatio, container, imageSize, focusPoint ) {\n\tconst containerCenter = Math.floor( container / 2 );\n\tconst scaledImage = Math.floor( imageSize / imageRatio );\n\tconst focus = Math.floor( focusPoint * scaledImage );\n\tlet focusOffset = focus - containerCenter;\n\tconst offsetRest = scaledImage - focus;\n\tconst containerRest = container - containerCenter;\n\n\tif ( offsetRest < containerRest ) {\n\t\tfocusOffset -= containerRest - offsetRest;\n\t}\n\n\tif ( focusOffset < 0 ) {\n\t\tfocusOffset = 0;\n\t}\n\n\treturn -focusOffset;\n}\n\nexport function getImageWithFocalPointStyles(\n\tfocalPoint,\n\tcontainerSize,\n\toriginalImageData\n) {\n\tconst imageStyle = {};\n\tif ( focalPoint && containerSize && originalImageData ) {\n\t\tlet horizontalOffset = 0;\n\t\tlet verticalOffset = 0;\n\t\tconst widthRatio = originalImageData.width / containerSize.width;\n\t\tconst heightRatio = originalImageData.height / containerSize.height;\n\n\t\timageStyle.resizeMode = 'stretch';\n\n\t\tif ( widthRatio > heightRatio ) {\n\t\t\thorizontalOffset = getFocalPointOffset(\n\t\t\t\theightRatio,\n\t\t\t\tcontainerSize.width,\n\t\t\t\toriginalImageData.width,\n\t\t\t\tfocalPoint.x\n\t\t\t);\n\t\t\timageStyle.width = undefined;\n\t\t\timageStyle.left = horizontalOffset;\n\t\t} else if ( widthRatio < heightRatio ) {\n\t\t\tverticalOffset = getFocalPointOffset(\n\t\t\t\twidthRatio,\n\t\t\t\tcontainerSize.height,\n\t\t\t\toriginalImageData.height,\n\t\t\t\tfocalPoint.y\n\t\t\t);\n\t\t\timageStyle.height = undefined;\n\t\t\timageStyle.top = verticalOffset;\n\t\t}\n\n\t\treturn imageStyle;\n\t}\n\n\treturn imageStyle;\n}\n"],"mappings":"AAAA,SAASA,mBAAmBA,CAAEC,UAAU,EAAEC,SAAS,EAAEC,SAAS,EAAEC,UAAU,EAAG;EAC5E,MAAMC,eAAe,GAAGC,IAAI,CAACC,KAAK,CAAEL,SAAS,GAAG,CAAE,CAAC;EACnD,MAAMM,WAAW,GAAGF,IAAI,CAACC,KAAK,CAAEJ,SAAS,GAAGF,UAAW,CAAC;EACxD,MAAMQ,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C;MACDX,UAAU,CAACM,MAAM,GAAGG,SAAS;MAC7BT,UAAU,CAACY,GAAG,GAAGV,cAAc;IAChC;IAEA,OAAOF,UAAU;EAClB;EAEA,OAAOA,UAAU;AAClB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["KeyboardAvoidingView","AndroidKeyboardAvoidingView"],"sources":["@wordpress/components/src/mobile/keyboard-avoiding-view/index.android.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { KeyboardAvoidingView as AndroidKeyboardAvoidingView } from 'react-native';\n\nexport const KeyboardAvoidingView = AndroidKeyboardAvoidingView;\n\nexport default KeyboardAvoidingView;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,oBAAoB,IAAIC,2BAA2B,QAAQ,cAAc;AAElF,OAAO,MAAMD,oBAAoB,GAAGC,2BAA2B;AAE/D,eAAeD,oBAAoB"}
|
|
1
|
+
{"version":3,"names":["KeyboardAvoidingView","AndroidKeyboardAvoidingView"],"sources":["@wordpress/components/src/mobile/keyboard-avoiding-view/index.android.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { KeyboardAvoidingView as AndroidKeyboardAvoidingView } from 'react-native';\n\nexport const KeyboardAvoidingView = AndroidKeyboardAvoidingView;\n\nexport default KeyboardAvoidingView;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,oBAAoB,IAAIC,2BAA2B,QAAQ,cAAc;AAElF,OAAO,MAAMD,oBAAoB,GAAGC,2BAA2B;AAE/D,eAAeD,oBAAoB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["KeyboardAvoidingView","IOSKeyboardAvoidingView","Animated","Keyboard","Dimensions","View","SafeArea","useEffect","useRef","useState","useResizeObserver","useIsFloatingKeyboard","styles","AnimatedKeyboardAvoidingView","createAnimatedComponent","MIN_HEIGHT","parentHeight","style","withAnimatedHeight","otherProps","resizeObserver","sizes","isKeyboardOpen","setIsKeyboardOpen","safeAreaBottomInset","setSafeAreaBottomInset","height","floatingKeyboard","animatedHeight","Value","current","fullHeight","get","keyboardVerticalOffset","getSafeAreaInsetsForRootView","then","safeAreaInsets","bottom","safeAreaSubscription","addEventListener","onSafeAreaInsetsUpdate","keyboardShowSubscription","addListener","onKeyboardWillShow","keyboardHideSubscription","onKeyboardWillHide","remove","endCoordinates","setValue","duration","startCoordinates","keyboardIsOpenBreakpoint","animatedListenerId","value","timing","toValue","useNativeDriver","start","removeListener","createElement","enabled","behavior","marginBottom","top","animatedChildStyle","defaultChildStyle","children"],"sources":["@wordpress/components/src/mobile/keyboard-avoiding-view/index.ios.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tKeyboardAvoidingView as IOSKeyboardAvoidingView,\n\tAnimated,\n\tKeyboard,\n\tDimensions,\n\tView,\n} from 'react-native';\nimport SafeArea from 'react-native-safe-area';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useRef, useState } from '@wordpress/element';\nimport { useResizeObserver } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport useIsFloatingKeyboard from '../utils/use-is-floating-keyboard';\nimport styles from './styles.scss';\n\nconst AnimatedKeyboardAvoidingView = Animated.createAnimatedComponent(\n\tIOSKeyboardAvoidingView\n);\n\nconst MIN_HEIGHT = 44;\n\nexport const KeyboardAvoidingView = ( {\n\tparentHeight,\n\tstyle,\n\twithAnimatedHeight = false,\n\t...otherProps\n} ) => {\n\tconst [ resizeObserver, sizes ] = useResizeObserver();\n\tconst [ isKeyboardOpen, setIsKeyboardOpen ] = useState( false );\n\tconst [ safeAreaBottomInset, setSafeAreaBottomInset ] = useState( 0 );\n\tconst { height = 0 } = sizes || {};\n\tconst floatingKeyboard = useIsFloatingKeyboard();\n\n\tconst animatedHeight = useRef( new Animated.Value( MIN_HEIGHT ) ).current;\n\n\tconst { height: fullHeight } = Dimensions.get( 'screen' );\n\tconst keyboardVerticalOffset = fullHeight - parentHeight;\n\n\tuseEffect( () => {\n\t\tSafeArea.getSafeAreaInsetsForRootView().then(\n\t\t\t( { safeAreaInsets } ) => {\n\t\t\t\tsetSafeAreaBottomInset( safeAreaInsets.bottom );\n\t\t\t}\n\t\t);\n\t\tconst safeAreaSubscription = SafeArea.addEventListener(\n\t\t\t'safeAreaInsetsForRootViewDidChange',\n\t\t\tonSafeAreaInsetsUpdate\n\t\t);\n\t\tconst keyboardShowSubscription = Keyboard.addListener(\n\t\t\t'keyboardWillShow',\n\t\t\tonKeyboardWillShow\n\t\t);\n\t\tconst keyboardHideSubscription = Keyboard.addListener(\n\t\t\t'keyboardWillHide',\n\t\t\tonKeyboardWillHide\n\t\t);\n\n\t\treturn () => {\n\t\t\tsafeAreaSubscription.remove();\n\t\t\tkeyboardShowSubscription.remove();\n\t\t\tkeyboardHideSubscription.remove();\n\t\t};\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [] );\n\n\tfunction onSafeAreaInsetsUpdate( { safeAreaInsets } ) {\n\t\tsetSafeAreaBottomInset( safeAreaInsets.bottom );\n\t}\n\n\tfunction onKeyboardWillShow( { endCoordinates } ) {\n\t\tsetIsKeyboardOpen( true );\n\t\tanimatedHeight.setValue( endCoordinates.height + MIN_HEIGHT );\n\t}\n\n\tfunction onKeyboardWillHide( { duration, startCoordinates } ) {\n\t\t// The startCoordinates.height is set to wrong value when we use cmd + k for hide the keyboard (Have no idea why).\n\t\t// Because of that the `setIsKeyboardOpened` is not invoked and the state of keyboard is wrong.\n\t\t// The keyboardIsOpenBreakpoint use 100 as a fallback if the startCoordinates.height is too small (cmd + k case)\n\t\tconst keyboardIsOpenBreakpoint =\n\t\t\tstartCoordinates.height > 100 ? startCoordinates.height / 3 : 100;\n\t\tconst animatedListenerId = animatedHeight.addListener(\n\t\t\t( { value } ) => {\n\t\t\t\tif ( value < keyboardIsOpenBreakpoint ) {\n\t\t\t\t\tsetIsKeyboardOpen( false );\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\n\t\tAnimated.timing( animatedHeight, {\n\t\t\ttoValue: MIN_HEIGHT,\n\t\t\tduration,\n\t\t\tuseNativeDriver: false,\n\t\t} ).start( () => {\n\t\t\tanimatedHeight.removeListener( animatedListenerId );\n\t\t} );\n\t}\n\n\treturn (\n\t\t<AnimatedKeyboardAvoidingView\n\t\t\t{ ...otherProps }\n\t\t\tenabled={ ! floatingKeyboard }\n\t\t\tbehavior=\"padding\"\n\t\t\tkeyboardVerticalOffset={ keyboardVerticalOffset }\n\t\t\tstyle={\n\t\t\t\twithAnimatedHeight\n\t\t\t\t\t? [\n\t\t\t\t\t\t\tstyle,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\theight: animatedHeight,\n\t\t\t\t\t\t\t\tmarginBottom: isKeyboardOpen\n\t\t\t\t\t\t\t\t\t? -safeAreaBottomInset\n\t\t\t\t\t\t\t\t\t: 0,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t ]\n\t\t\t\t\t: style\n\t\t\t}\n\t\t>\n\t\t\t<View\n\t\t\t\tstyle={ [\n\t\t\t\t\t{\n\t\t\t\t\t\ttop: -height + MIN_HEIGHT,\n\t\t\t\t\t},\n\t\t\t\t\tstyles.animatedChildStyle,\n\t\t\t\t\t! withAnimatedHeight && styles.defaultChildStyle,\n\t\t\t\t] }\n\t\t\t>\n\t\t\t\t{ resizeObserver }\n\t\t\t\t{ otherProps.children }\n\t\t\t</View>\n\t\t</AnimatedKeyboardAvoidingView>\n\t);\n};\n\nexport default KeyboardAvoidingView;\n"],"mappings":";AAAA;AACA;AACA;AACA,SACCA,oBAAoB,IAAIC,uBAAuB,EAC/CC,QAAQ,EACRC,QAAQ,EACRC,UAAU,EACVC,IAAI,QACE,cAAc;AACrB,OAAOC,QAAQ,MAAM,wBAAwB;;AAE7C;AACA;AACA;AACA,SAASC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,oBAAoB;AAChE,SAASC,iBAAiB,QAAQ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AAA,CAAC9C,4BAA4B;IAAA,GACvBM,UAAU;IACfyC,OAAO,EAAG,CAAEjC,gBAAkB;IAC9BkC,QAAQ,EAAC,SAAS;IAClB5B,sBAAsB,EAAGA,sBAAwB;IACjDhB,KAAK,EACJC,kBAAkB,GACf,CACAD,KAAK,EACL;MACCS,MAAM,EAAEE,cAAc;MACtBkC,YAAY,EAAExC,cAAc,GACzB,CAACE,mBAAmB,GACpB;IACJ,CAAC,CACA,GACDP;EACH,GAED0C,aAAA,CAACtD,IAAI;IACJY,KAAK,EAAG,CACP;MACC8C,GAAG,EAAE,CAACrC,MAAM,GAAGX;IAChB,CAAC,EACDH,MAAM,CAACoD,kBAAkB,EACzB,CAAE9C,kBAAkB,IAAIN,MAAM,CAACqD,iBAAiB;EAC9C,GAED7C,cAAc,EACdD,UAAU,CAAC+C,QACR,CACuB,CAAC;AAEjC,CAAC;AAED,eAAelE,oBAAoB"}
|
|
1
|
+
{"version":3,"names":["KeyboardAvoidingView","IOSKeyboardAvoidingView","Animated","Keyboard","Dimensions","View","SafeArea","useEffect","useRef","useState","useResizeObserver","useIsFloatingKeyboard","styles","AnimatedKeyboardAvoidingView","createAnimatedComponent","MIN_HEIGHT","parentHeight","style","withAnimatedHeight","otherProps","resizeObserver","sizes","isKeyboardOpen","setIsKeyboardOpen","safeAreaBottomInset","setSafeAreaBottomInset","height","floatingKeyboard","animatedHeight","Value","current","fullHeight","get","keyboardVerticalOffset","getSafeAreaInsetsForRootView","then","safeAreaInsets","bottom","safeAreaSubscription","addEventListener","onSafeAreaInsetsUpdate","keyboardShowSubscription","addListener","onKeyboardWillShow","keyboardHideSubscription","onKeyboardWillHide","remove","endCoordinates","setValue","duration","startCoordinates","keyboardIsOpenBreakpoint","animatedListenerId","value","timing","toValue","useNativeDriver","start","removeListener","createElement","enabled","behavior","marginBottom","top","animatedChildStyle","defaultChildStyle","children"],"sources":["@wordpress/components/src/mobile/keyboard-avoiding-view/index.ios.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tKeyboardAvoidingView as IOSKeyboardAvoidingView,\n\tAnimated,\n\tKeyboard,\n\tDimensions,\n\tView,\n} from 'react-native';\nimport SafeArea from 'react-native-safe-area';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useRef, useState } from '@wordpress/element';\nimport { useResizeObserver } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport useIsFloatingKeyboard from '../utils/use-is-floating-keyboard';\nimport styles from './styles.scss';\n\nconst AnimatedKeyboardAvoidingView = Animated.createAnimatedComponent(\n\tIOSKeyboardAvoidingView\n);\n\nconst MIN_HEIGHT = 44;\n\nexport const KeyboardAvoidingView = ( {\n\tparentHeight,\n\tstyle,\n\twithAnimatedHeight = false,\n\t...otherProps\n} ) => {\n\tconst [ resizeObserver, sizes ] = useResizeObserver();\n\tconst [ isKeyboardOpen, setIsKeyboardOpen ] = useState( false );\n\tconst [ safeAreaBottomInset, setSafeAreaBottomInset ] = useState( 0 );\n\tconst { height = 0 } = sizes || {};\n\tconst floatingKeyboard = useIsFloatingKeyboard();\n\n\tconst animatedHeight = useRef( new Animated.Value( MIN_HEIGHT ) ).current;\n\n\tconst { height: fullHeight } = Dimensions.get( 'screen' );\n\tconst keyboardVerticalOffset = fullHeight - parentHeight;\n\n\tuseEffect( () => {\n\t\tSafeArea.getSafeAreaInsetsForRootView().then(\n\t\t\t( { safeAreaInsets } ) => {\n\t\t\t\tsetSafeAreaBottomInset( safeAreaInsets.bottom );\n\t\t\t}\n\t\t);\n\t\tconst safeAreaSubscription = SafeArea.addEventListener(\n\t\t\t'safeAreaInsetsForRootViewDidChange',\n\t\t\tonSafeAreaInsetsUpdate\n\t\t);\n\t\tconst keyboardShowSubscription = Keyboard.addListener(\n\t\t\t'keyboardWillShow',\n\t\t\tonKeyboardWillShow\n\t\t);\n\t\tconst keyboardHideSubscription = Keyboard.addListener(\n\t\t\t'keyboardWillHide',\n\t\t\tonKeyboardWillHide\n\t\t);\n\n\t\treturn () => {\n\t\t\tsafeAreaSubscription.remove();\n\t\t\tkeyboardShowSubscription.remove();\n\t\t\tkeyboardHideSubscription.remove();\n\t\t};\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [] );\n\n\tfunction onSafeAreaInsetsUpdate( { safeAreaInsets } ) {\n\t\tsetSafeAreaBottomInset( safeAreaInsets.bottom );\n\t}\n\n\tfunction onKeyboardWillShow( { endCoordinates } ) {\n\t\tsetIsKeyboardOpen( true );\n\t\tanimatedHeight.setValue( endCoordinates.height + MIN_HEIGHT );\n\t}\n\n\tfunction onKeyboardWillHide( { duration, startCoordinates } ) {\n\t\t// The startCoordinates.height is set to wrong value when we use cmd + k for hide the keyboard (Have no idea why).\n\t\t// Because of that the `setIsKeyboardOpened` is not invoked and the state of keyboard is wrong.\n\t\t// The keyboardIsOpenBreakpoint use 100 as a fallback if the startCoordinates.height is too small (cmd + k case)\n\t\tconst keyboardIsOpenBreakpoint =\n\t\t\tstartCoordinates.height > 100 ? startCoordinates.height / 3 : 100;\n\t\tconst animatedListenerId = animatedHeight.addListener(\n\t\t\t( { value } ) => {\n\t\t\t\tif ( value < keyboardIsOpenBreakpoint ) {\n\t\t\t\t\tsetIsKeyboardOpen( false );\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\n\t\tAnimated.timing( animatedHeight, {\n\t\t\ttoValue: MIN_HEIGHT,\n\t\t\tduration,\n\t\t\tuseNativeDriver: false,\n\t\t} ).start( () => {\n\t\t\tanimatedHeight.removeListener( animatedListenerId );\n\t\t} );\n\t}\n\n\treturn (\n\t\t<AnimatedKeyboardAvoidingView\n\t\t\t{ ...otherProps }\n\t\t\tenabled={ ! floatingKeyboard }\n\t\t\tbehavior=\"padding\"\n\t\t\tkeyboardVerticalOffset={ keyboardVerticalOffset }\n\t\t\tstyle={\n\t\t\t\twithAnimatedHeight\n\t\t\t\t\t? [\n\t\t\t\t\t\t\tstyle,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\theight: animatedHeight,\n\t\t\t\t\t\t\t\tmarginBottom: isKeyboardOpen\n\t\t\t\t\t\t\t\t\t? -safeAreaBottomInset\n\t\t\t\t\t\t\t\t\t: 0,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t ]\n\t\t\t\t\t: style\n\t\t\t}\n\t\t>\n\t\t\t<View\n\t\t\t\tstyle={ [\n\t\t\t\t\t{\n\t\t\t\t\t\ttop: -height + MIN_HEIGHT,\n\t\t\t\t\t},\n\t\t\t\t\tstyles.animatedChildStyle,\n\t\t\t\t\t! withAnimatedHeight && styles.defaultChildStyle,\n\t\t\t\t] }\n\t\t\t>\n\t\t\t\t{ resizeObserver }\n\t\t\t\t{ otherProps.children }\n\t\t\t</View>\n\t\t</AnimatedKeyboardAvoidingView>\n\t);\n};\n\nexport default KeyboardAvoidingView;\n"],"mappings":";AAAA;AACA;AACA;AACA,SACCA,oBAAoB,IAAIC,uBAAuB,EAC/CC,QAAQ,EACRC,QAAQ,EACRC,UAAU,EACVC,IAAI,QACE,cAAc;AACrB,OAAOC,QAAQ,MAAM,wBAAwB;;AAE7C;AACA;AACA;AACA,SAASC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,oBAAoB;AAChE,SAASC,iBAAiB,QAAQ,oBAAoB;;AAEtD;AACA;AACA;AACA,OAAOC,qBAAqB,MAAM,mCAAmC;AACrE,OAAOC,MAAM,MAAM,eAAe;AAElC,MAAMC,4BAA4B,GAAGX,QAAQ,CAACY,uBAAuB,CACpEb,uBACD,CAAC;AAED,MAAMc,UAAU,GAAG,EAAE;AAErB,OAAO,MAAMf,oBAAoB,GAAGA,CAAE;EACrCgB,YAAY;EACZC,KAAK;EACLC,kBAAkB,GAAG,KAAK;EAC1B,GAAGC;AACJ,CAAC,KAAM;EACN,MAAM,CAAEC,cAAc,EAAEC,KAAK,CAAE,GAAGX,iBAAiB,CAAC,CAAC;EACrD,MAAM,CAA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,CAACoD,kBAAkB,EACzB,CAAE9C,kBAAkB,IAAIN,MAAM,CAACqD,iBAAiB;EAC9C,GAED7C,cAAc,EACdD,UAAU,CAAC+C,QACR,CACuB,CAAC;AAEjC,CAAC;AAED,eAAelE,oBAAoB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["FlatList","Animated","forwardRef","useCallback","useImperativeHandle","useScroll","KeyboardAvoidingView","AnimatedFlatList","createAnimatedComponent","KeyboardAwareFlatList","onScroll","props","ref","extraScrollHeight","scrollEnabled","shouldPreventAutomaticScroll","scrollViewRef","scrollHandler","scrollToSection","scrollToElement","onContentSizeChange","lastScrollTo","getFlatListRef","flatListRef","current","getNativeScrollRef","createElement","style","flex"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/index.android.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { FlatList } from 'react-native';\nimport Animated from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tforwardRef,\n\tuseCallback,\n\tuseImperativeHandle,\n} from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport useScroll from './use-scroll';\nimport KeyboardAvoidingView from '../keyboard-avoiding-view';\n\nconst AnimatedFlatList = Animated.createAnimatedComponent( FlatList );\n\nexport const KeyboardAwareFlatList = ( { onScroll, ...props }, ref ) => {\n\tconst { extraScrollHeight, scrollEnabled, shouldPreventAutomaticScroll } =\n\t\tprops;\n\n\tconst {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tscrollToSection,\n\t\tscrollToElement,\n\t\tonContentSizeChange,\n\t\tlastScrollTo,\n\t} = useScroll( {\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll,\n\t\textraScrollHeight,\n\t\tonScroll,\n\t} );\n\n\tconst getFlatListRef = useCallback(\n\t\t( flatListRef ) => {\n\t\t\t// On Android, we get the ref of the associated scroll\n\t\t\t// view to the FlatList.\n\t\t\tscrollViewRef.current = flatListRef?.getNativeScrollRef();\n\t\t},\n\t\t[ scrollViewRef ]\n\t);\n\n\tuseImperativeHandle( ref, () => {\n\t\treturn {\n\t\t\tscrollViewRef: scrollViewRef.current,\n\t\t\tscrollToSection,\n\t\t\tscrollToElement,\n\t\t\tlastScrollTo,\n\t\t};\n\t} );\n\n\treturn (\n\t\t<KeyboardAvoidingView style={ { flex: 1 } }>\n\t\t\t<AnimatedFlatList\n\t\t\t\tref={ getFlatListRef }\n\t\t\t\tonScroll={ scrollHandler }\n\t\t\t\tonContentSizeChange={ onContentSizeChange }\n\t\t\t\t{ ...props }\n\t\t\t/>\n\t\t</KeyboardAvoidingView>\n\t);\n};\n\nexport default forwardRef( KeyboardAwareFlatList );\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,QAAQ,QAAQ,cAAc;AACvC,OAAOC,QAAQ,MAAM,yBAAyB;;AAE9C;AACA;AACA;AACA,SACCC,UAAU,EACVC,WAAW,EACXC,mBAAmB,QACb,oBAAoB;;AAE3B;AACA;AACA;AACA,OAAOC,SAAS,MAAM,cAAc;AACpC,OAAOC,oBAAoB,MAAM,2BAA2B;AAE5D,MAAMC,gBAAgB,GAAGN,QAAQ,CAACO,uBAAuB,CAAER,QAAS,CAAC;AAErE,OAAO,MAAMS,qBAAqB,GAAGA,CAAE;EAAEC,QAAQ;EAAE,GAAGC;AAAM,CAAC,EAAEC,GAAG,KAAM;EACvE,MAAM;IAAEC,iBAAiB;IAAEC,aAAa;IAAEC;EAA6B,CAAC,GACvEJ,KAAK;EAEN,MAAM;IACLK,aAAa;IACbC,aAAa;IACbC,eAAe;IACfC,eAAe;IACfC,mBAAmB;IACnBC;EACD,CAAC,GAAGhB,SAAS,CAAE;IACdS,aAAa;IACbC,4BAA4B;IAC5BF,iBAAiB;IACjBH;EACD,CAAE,CAAC;EAEH,MAAMY,cAAc,GAAGnB,WAAW,CAC/BoB,WAAW,IAAM;IAClB;IACA;IACAP,aAAa,CAACQ,OAAO,GAAGD,WAAW,EAAEE,kBAAkB,CAAC,CAAC;EAC1D,CAAC,EACD,CAAET,aAAa,CAChB,CAAC;EAEDZ,mBAAmB,CAAEQ,GAAG,EAAE,MAAM;IAC/B,OAAO;MACNI,aAAa,EAAEA,aAAa,CAACQ,OAAO;MACpCN,eAAe;MACfC,eAAe;MACfE;IACD,CAAC;EACF,CAAE,CAAC;EAEH,OACCK,aAAA,CAACpB,oBAAoB;IAACqB,KAAK,EAAG;MAAEC,IAAI,EAAE;IAAE;EAAG,GAC1CF,aAAA,CAACnB,gBAAgB;IAChBK,GAAG,EAAGU,cAAgB;IACtBZ,QAAQ,EAAGO,aAAe;IAC1BG,mBAAmB,EAAGA,mBAAqB;IAAA,GACtCT;EAAK,CACV,CACoB,CAAC;AAEzB,CAAC;AAED,eAAeT,UAAU,CAAEO,qBAAsB,CAAC"}
|
|
1
|
+
{"version":3,"names":["FlatList","Animated","forwardRef","useCallback","useImperativeHandle","useScroll","KeyboardAvoidingView","AnimatedFlatList","createAnimatedComponent","KeyboardAwareFlatList","onScroll","props","ref","extraScrollHeight","scrollEnabled","shouldPreventAutomaticScroll","scrollViewRef","scrollHandler","scrollToSection","scrollToElement","onContentSizeChange","lastScrollTo","getFlatListRef","flatListRef","current","getNativeScrollRef","createElement","style","flex"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/index.android.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { FlatList } from 'react-native';\nimport Animated from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tforwardRef,\n\tuseCallback,\n\tuseImperativeHandle,\n} from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport useScroll from './use-scroll';\nimport KeyboardAvoidingView from '../keyboard-avoiding-view';\n\nconst AnimatedFlatList = Animated.createAnimatedComponent( FlatList );\n\nexport const KeyboardAwareFlatList = ( { onScroll, ...props }, ref ) => {\n\tconst { extraScrollHeight, scrollEnabled, shouldPreventAutomaticScroll } =\n\t\tprops;\n\n\tconst {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tscrollToSection,\n\t\tscrollToElement,\n\t\tonContentSizeChange,\n\t\tlastScrollTo,\n\t} = useScroll( {\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll,\n\t\textraScrollHeight,\n\t\tonScroll,\n\t} );\n\n\tconst getFlatListRef = useCallback(\n\t\t( flatListRef ) => {\n\t\t\t// On Android, we get the ref of the associated scroll\n\t\t\t// view to the FlatList.\n\t\t\tscrollViewRef.current = flatListRef?.getNativeScrollRef();\n\t\t},\n\t\t[ scrollViewRef ]\n\t);\n\n\tuseImperativeHandle( ref, () => {\n\t\treturn {\n\t\t\tscrollViewRef: scrollViewRef.current,\n\t\t\tscrollToSection,\n\t\t\tscrollToElement,\n\t\t\tlastScrollTo,\n\t\t};\n\t} );\n\n\treturn (\n\t\t<KeyboardAvoidingView style={ { flex: 1 } }>\n\t\t\t<AnimatedFlatList\n\t\t\t\tref={ getFlatListRef }\n\t\t\t\tonScroll={ scrollHandler }\n\t\t\t\tonContentSizeChange={ onContentSizeChange }\n\t\t\t\t{ ...props }\n\t\t\t/>\n\t\t</KeyboardAvoidingView>\n\t);\n};\n\nexport default forwardRef( KeyboardAwareFlatList );\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,QAAQ,QAAQ,cAAc;AACvC,OAAOC,QAAQ,MAAM,yBAAyB;;AAE9C;AACA;AACA;AACA,SACCC,UAAU,EACVC,WAAW,EACXC,mBAAmB,QACb,oBAAoB;;AAE3B;AACA;AACA;AACA,OAAOC,SAAS,MAAM,cAAc;AACpC,OAAOC,oBAAoB,MAAM,2BAA2B;AAE5D,MAAMC,gBAAgB,GAAGN,QAAQ,CAACO,uBAAuB,CAAER,QAAS,CAAC;AAErE,OAAO,MAAMS,qBAAqB,GAAGA,CAAE;EAAEC,QAAQ;EAAE,GAAGC;AAAM,CAAC,EAAEC,GAAG,KAAM;EACvE,MAAM;IAAEC,iBAAiB;IAAEC,aAAa;IAAEC;EAA6B,CAAC,GACvEJ,KAAK;EAEN,MAAM;IACLK,aAAa;IACbC,aAAa;IACbC,eAAe;IACfC,eAAe;IACfC,mBAAmB;IACnBC;EACD,CAAC,GAAGhB,SAAS,CAAE;IACdS,aAAa;IACbC,4BAA4B;IAC5BF,iBAAiB;IACjBH;EACD,CAAE,CAAC;EAEH,MAAMY,cAAc,GAAGnB,WAAW,CAC/BoB,WAAW,IAAM;IAClB;IACA;IACAP,aAAa,CAACQ,OAAO,GAAGD,WAAW,EAAEE,kBAAkB,CAAC,CAAC;EAC1D,CAAC,EACD,CAAET,aAAa,CAChB,CAAC;EAEDZ,mBAAmB,CAAEQ,GAAG,EAAE,MAAM;IAC/B,OAAO;MACNI,aAAa,EAAEA,aAAa,CAACQ,OAAO;MACpCN,eAAe;MACfC,eAAe;MACfE;IACD,CAAC;EACF,CAAE,CAAC;EAEH,OACCK,aAAA,CAACpB,oBAAoB;IAACqB,KAAK,EAAG;MAAEC,IAAI,EAAE;IAAE;EAAG,GAC1CF,aAAA,CAACnB,gBAAgB;IAChBK,GAAG,EAAGU,cAAgB;IACtBZ,QAAQ,EAAGO,aAAe;IAC1BG,mBAAmB,EAAGA,mBAAqB;IAAA,GACtCT;EAAK,CACV,CACoB,CAAC;AAEzB,CAAC;AAED,eAAeT,UAAU,CAAEO,qBAAsB,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ScrollView","FlatList","Animated","useCallback","useEffect","forwardRef","useImperativeHandle","useThrottle","useScroll","useTextInputOffset","useTextInputCaretPosition","DEFAULT_FONT_SIZE","AnimatedScrollView","createAnimatedComponent","KeyboardAwareFlatList","extraScrollHeight","onScroll","scrollEnabled","scrollViewStyle","shouldPreventAutomaticScroll","props","ref","scrollViewRef","scrollHandler","keyboardOffset","scrollToSection","scrollToElement","onContentSizeChange","lastScrollTo","onSizeChange","getTextInputOffset","onScrollToTextInput","caret","caretHeight","textInputOffset","hasTextInputOffset","leading","currentCaretData","contentInset","bottom","style","flex","current","createElement","automaticallyAdjustContentInsets","keyboardShouldPersistTaps","scrollEventThrottle"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/index.ios.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { ScrollView, FlatList } from 'react-native';\nimport Animated from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tuseCallback,\n\tuseEffect,\n\tforwardRef,\n\tuseImperativeHandle,\n} from '@wordpress/element';\nimport { useThrottle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport useScroll from './use-scroll';\nimport useTextInputOffset from './use-text-input-offset';\nimport useTextInputCaretPosition from './use-text-input-caret-position';\n\nconst DEFAULT_FONT_SIZE = 16;\nconst AnimatedScrollView = Animated.createAnimatedComponent( ScrollView );\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * React component that provides a FlatList that is aware of the keyboard state and can scroll\n * to the currently focused TextInput.\n *\n * @param {Object} props Component props.\n * @param {number} props.extraScrollHeight Extra scroll height for the content.\n * @param {Function} props.onScroll Function to be called when the list is scrolled.\n * @param {boolean} props.scrollEnabled Whether the list can be scrolled.\n * @param {Object} props.scrollViewStyle Additional style for the ScrollView component.\n * @param {boolean} props.shouldPreventAutomaticScroll Whether to prevent scrolling when there's a Keyboard offset set.\n * @param {Object} props... Other props to pass to the FlatList component.\n * @param {RefObject} ref\n * @return {Component} KeyboardAwareFlatList component.\n */\nexport const KeyboardAwareFlatList = (\n\t{\n\t\textraScrollHeight,\n\t\tonScroll,\n\t\tscrollEnabled,\n\t\tscrollViewStyle,\n\t\tshouldPreventAutomaticScroll,\n\t\t...props\n\t},\n\tref\n) => {\n\tconst {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tkeyboardOffset,\n\t\tscrollToSection,\n\t\tscrollToElement,\n\t\tonContentSizeChange,\n\t\tlastScrollTo,\n\t} = useScroll( {\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll,\n\t\textraScrollHeight,\n\t\tonScroll,\n\t\tonSizeChange,\n\t} );\n\n\tconst [ getTextInputOffset ] = useTextInputOffset(\n\t\tscrollEnabled,\n\t\tscrollViewRef\n\t);\n\n\tconst onScrollToTextInput = useThrottle(\n\t\tuseCallback(\n\t\t\tasync ( caret ) => {\n\t\t\t\tconst { caretHeight = DEFAULT_FONT_SIZE } = caret ?? {};\n\t\t\t\tconst textInputOffset = await getTextInputOffset( caret );\n\t\t\t\tconst hasTextInputOffset = textInputOffset !== null;\n\n\t\t\t\tif ( hasTextInputOffset ) {\n\t\t\t\t\tscrollToSection( textInputOffset, caretHeight );\n\t\t\t\t}\n\t\t\t},\n\t\t\t[ getTextInputOffset, scrollToSection ]\n\t\t),\n\t\t200,\n\t\t{ leading: false }\n\t);\n\n\tconst [ currentCaretData ] = useTextInputCaretPosition( scrollEnabled );\n\n\tconst onSizeChange = useCallback(\n\t\t() => onScrollToTextInput( currentCaretData ),\n\t\t[ currentCaretData, onScrollToTextInput ]\n\t);\n\n\tuseEffect( () => {\n\t\tonScrollToTextInput( currentCaretData );\n\t}, [ currentCaretData, onScrollToTextInput ] );\n\n\t// Adds content insets when the keyboard is opened to have\n\t// extra padding at the bottom.\n\tconst contentInset = { bottom: keyboardOffset };\n\n\tconst style = [ { flex: 1 }, scrollViewStyle ];\n\n\tuseImperativeHandle( ref, () => {\n\t\treturn {\n\t\t\tscrollViewRef: scrollViewRef.current,\n\t\t\tscrollToSection,\n\t\t\tscrollToElement,\n\t\t\tlastScrollTo,\n\t\t};\n\t} );\n\n\treturn (\n\t\t<AnimatedScrollView\n\t\t\tautomaticallyAdjustContentInsets={ false }\n\t\t\tcontentInset={ contentInset }\n\t\t\tkeyboardShouldPersistTaps=\"handled\"\n\t\t\tonContentSizeChange={ onContentSizeChange }\n\t\t\tonScroll={ scrollHandler }\n\t\t\tref={ scrollViewRef }\n\t\t\tscrollEnabled={ scrollEnabled }\n\t\t\tscrollEventThrottle={ 16 }\n\t\t\tstyle={ style }\n\t\t>\n\t\t\t<FlatList { ...props } scrollEnabled={ false } />\n\t\t</AnimatedScrollView>\n\t);\n};\n\nexport default forwardRef( KeyboardAwareFlatList );\n"],"mappings":";AAAA;AACA;AACA;;AAEA,SAASA,UAAU,EAAEC,QAAQ,QAAQ,cAAc;AACnD,OAAOC,QAAQ,MAAM,yBAAyB;;AAE9C;AACA;AACA;AACA,SACCC,WAAW,EACXC,SAAS,EACTC,UAAU,EACVC,mBAAmB,QACb,oBAAoB;AAC3B,SAASC,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA,OAAOC,SAAS,MAAM,cAAc;AACpC,OAAOC,kBAAkB,MAAM,yBAAyB;AACxD,OAAOC,yBAAyB,MAAM,iCAAiC;AAEvE,MAAMC,iBAAiB,GAAG,EAAE;AAC5B,MAAMC,kBAAkB,GAAGV,QAAQ,CAACW,uBAAuB,CAAEb,UAAW,CAAC;;AAEzE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMc,qBAAqB,GAAGA,CACpC;EACCC,iBAAiB;EACjBC,QAAQ;EACRC,aAAa;EACbC,eAAe;EACfC,4BAA4B;EAC5B,GAAGC;AACJ,CAAC,EACDC,GAAG,KACC;EACJ,MAAM;IACLC,aAAa;IACbC,aAAa;IACbC,cAAc;IACdC,eAAe;IACfC,eAAe;IACfC,mBAAmB;IACnBC;EACD,CAAC,GAAGpB,SAAS,CAAE;IACdS,aAAa;IACbE,4BAA4B;IAC5BJ,iBAAiB;IACjBC,QAAQ;IACRa;EACD,CAAE,CAAC;EAEH,MAAM,CAAEC,kBAAkB,CAAE,GAAGrB,kBAAkB,CAChDQ,aAAa,EACbK,aACD,CAAC;EAED,MAAMS,mBAAmB,GAAGxB,WAAW,CACtCJ,WAAW,CACV,MAAQ6B,KAAK,IAAM;IAClB,MAAM;MAAEC,WAAW,GAAGtB;IAAkB,CAAC,GAAGqB,KAAK,aAALA,KAAK,cAALA,KAAK,GAAI,CAAC,CAAC;IACvD,M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C1C,QAAQ;IAAA,GAAMmB,KAAK;IAAGH,aAAa,EAAG;EAAO,CAAE,CAC7B,CAAC;AAEvB,CAAC;AAED,eAAeZ,UAAU,CAAES,qBAAsB,CAAC"}
|
|
1
|
+
{"version":3,"names":["ScrollView","FlatList","Animated","useCallback","useEffect","forwardRef","useImperativeHandle","useThrottle","useScroll","useTextInputOffset","useTextInputCaretPosition","DEFAULT_FONT_SIZE","AnimatedScrollView","createAnimatedComponent","KeyboardAwareFlatList","extraScrollHeight","onScroll","scrollEnabled","scrollViewStyle","shouldPreventAutomaticScroll","props","ref","scrollViewRef","scrollHandler","keyboardOffset","scrollToSection","scrollToElement","onContentSizeChange","lastScrollTo","onSizeChange","getTextInputOffset","onScrollToTextInput","caret","caretHeight","textInputOffset","hasTextInputOffset","leading","currentCaretData","contentInset","bottom","style","flex","current","createElement","automaticallyAdjustContentInsets","keyboardShouldPersistTaps","scrollEventThrottle"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/index.ios.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { ScrollView, FlatList } from 'react-native';\nimport Animated from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tuseCallback,\n\tuseEffect,\n\tforwardRef,\n\tuseImperativeHandle,\n} from '@wordpress/element';\nimport { useThrottle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport useScroll from './use-scroll';\nimport useTextInputOffset from './use-text-input-offset';\nimport useTextInputCaretPosition from './use-text-input-caret-position';\n\nconst DEFAULT_FONT_SIZE = 16;\nconst AnimatedScrollView = Animated.createAnimatedComponent( ScrollView );\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * React component that provides a FlatList that is aware of the keyboard state and can scroll\n * to the currently focused TextInput.\n *\n * @param {Object} props Component props.\n * @param {number} props.extraScrollHeight Extra scroll height for the content.\n * @param {Function} props.onScroll Function to be called when the list is scrolled.\n * @param {boolean} props.scrollEnabled Whether the list can be scrolled.\n * @param {Object} props.scrollViewStyle Additional style for the ScrollView component.\n * @param {boolean} props.shouldPreventAutomaticScroll Whether to prevent scrolling when there's a Keyboard offset set.\n * @param {Object} props... Other props to pass to the FlatList component.\n * @param {RefObject} ref\n * @return {Component} KeyboardAwareFlatList component.\n */\nexport const KeyboardAwareFlatList = (\n\t{\n\t\textraScrollHeight,\n\t\tonScroll,\n\t\tscrollEnabled,\n\t\tscrollViewStyle,\n\t\tshouldPreventAutomaticScroll,\n\t\t...props\n\t},\n\tref\n) => {\n\tconst {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tkeyboardOffset,\n\t\tscrollToSection,\n\t\tscrollToElement,\n\t\tonContentSizeChange,\n\t\tlastScrollTo,\n\t} = useScroll( {\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll,\n\t\textraScrollHeight,\n\t\tonScroll,\n\t\tonSizeChange,\n\t} );\n\n\tconst [ getTextInputOffset ] = useTextInputOffset(\n\t\tscrollEnabled,\n\t\tscrollViewRef\n\t);\n\n\tconst onScrollToTextInput = useThrottle(\n\t\tuseCallback(\n\t\t\tasync ( caret ) => {\n\t\t\t\tconst { caretHeight = DEFAULT_FONT_SIZE } = caret ?? {};\n\t\t\t\tconst textInputOffset = await getTextInputOffset( caret );\n\t\t\t\tconst hasTextInputOffset = textInputOffset !== null;\n\n\t\t\t\tif ( hasTextInputOffset ) {\n\t\t\t\t\tscrollToSection( textInputOffset, caretHeight );\n\t\t\t\t}\n\t\t\t},\n\t\t\t[ getTextInputOffset, scrollToSection ]\n\t\t),\n\t\t200,\n\t\t{ leading: false }\n\t);\n\n\tconst [ currentCaretData ] = useTextInputCaretPosition( scrollEnabled );\n\n\tconst onSizeChange = useCallback(\n\t\t() => onScrollToTextInput( currentCaretData ),\n\t\t[ currentCaretData, onScrollToTextInput ]\n\t);\n\n\tuseEffect( () => {\n\t\tonScrollToTextInput( currentCaretData );\n\t}, [ currentCaretData, onScrollToTextInput ] );\n\n\t// Adds content insets when the keyboard is opened to have\n\t// extra padding at the bottom.\n\tconst contentInset = { bottom: keyboardOffset };\n\n\tconst style = [ { flex: 1 }, scrollViewStyle ];\n\n\tuseImperativeHandle( ref, () => {\n\t\treturn {\n\t\t\tscrollViewRef: scrollViewRef.current,\n\t\t\tscrollToSection,\n\t\t\tscrollToElement,\n\t\t\tlastScrollTo,\n\t\t};\n\t} );\n\n\treturn (\n\t\t<AnimatedScrollView\n\t\t\tautomaticallyAdjustContentInsets={ false }\n\t\t\tcontentInset={ contentInset }\n\t\t\tkeyboardShouldPersistTaps=\"handled\"\n\t\t\tonContentSizeChange={ onContentSizeChange }\n\t\t\tonScroll={ scrollHandler }\n\t\t\tref={ scrollViewRef }\n\t\t\tscrollEnabled={ scrollEnabled }\n\t\t\tscrollEventThrottle={ 16 }\n\t\t\tstyle={ style }\n\t\t>\n\t\t\t<FlatList { ...props } scrollEnabled={ false } />\n\t\t</AnimatedScrollView>\n\t);\n};\n\nexport default forwardRef( KeyboardAwareFlatList );\n"],"mappings":";AAAA;AACA;AACA;;AAEA,SAASA,UAAU,EAAEC,QAAQ,QAAQ,cAAc;AACnD,OAAOC,QAAQ,MAAM,yBAAyB;;AAE9C;AACA;AACA;AACA,SACCC,WAAW,EACXC,SAAS,EACTC,UAAU,EACVC,mBAAmB,QACb,oBAAoB;AAC3B,SAASC,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA,OAAOC,SAAS,MAAM,cAAc;AACpC,OAAOC,kBAAkB,MAAM,yBAAyB;AACxD,OAAOC,yBAAyB,MAAM,iCAAiC;AAEvE,MAAMC,iBAAiB,GAAG,EAAE;AAC5B,MAAMC,kBAAkB,GAAGV,QAAQ,CAACW,uBAAuB,CAAEb,UAAW,CAAC;;AAEzE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMc,qBAAqB,GAAGA,CACpC;EACCC,iBAAiB;EACjBC,QAAQ;EACRC,aAAa;EACbC,eAAe;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AAK,GAAG,CAAE;IAAEC,IAAI,EAAE;EAAE,CAAC,EAAEvB,eAAe,CAAE;EAE9CZ,mBAAmB,CAAEe,GAAG,EAAE,MAAM;IAC/B,OAAO;MACNC,aAAa,EAAEA,aAAa,CAACoB,OAAO;MACpCjB,eAAe;MACfC,eAAe;MACfE;IACD,CAAC;EACF,CAAE,CAAC;EAEH,OACCe,aAAA,CAAC/B,kBAAkB;IAClBgC,gCAAgC,EAAG,KAAO;IAC1CN,YAAY,EAAGA,YAAc;IAC7BO,yBAAyB,EAAC,SAAS;IACnClB,mBAAmB,EAAGA,mBAAqB;IAC3CX,QAAQ,EAAGO,aAAe;IAC1BF,GAAG,EAAGC,aAAe;IACrBL,aAAa,EAAGA,aAAe;IAC/B6B,mBAAmB,EAAG,EAAI;IAC1BN,KAAK,EAAGA;EAAO,GAEfG,aAAA,CAAC1C,QAAQ;IAAA,GAAMmB,KAAK;IAAGH,aAAa,EAAG;EAAO,CAAE,CAC7B,CAAC;AAEvB,CAAC;AAED,eAAeZ,UAAU,CAAES,qBAAsB,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Keyboard","useEffect","useCallback","useState","useRef","useKeyboardOffset","scrollEnabled","shouldPreventAutomaticScroll","keyboardOffset","setKeyboardOffset","timeoutRef","onKeyboardDidHide","clearTimeout","current","setTimeout","onKeyboardDidShow","endCoordinates","height","onKeyboardWillShow","willShowSubscription","showSubscription","hideSubscription","addListener","remove"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-keyboard-offset.native.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { Keyboard } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useCallback, useState, useRef } from '@wordpress/element';\n\n/**\n * Hook that adds Keyboard listeners to get the offset space\n * when the keyboard is opened, taking into account focused AztecViews.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {Function} shouldPreventAutomaticScroll Whether to prevent scrolling when there's a Keyboard offset set.\n * @return {[number]} Keyboard offset.\n */\nexport default function useKeyboardOffset(\n\tscrollEnabled,\n\tshouldPreventAutomaticScroll\n) {\n\tconst [ keyboardOffset, setKeyboardOffset ] = useState( 0 );\n\tconst timeoutRef = useRef();\n\n\tconst onKeyboardDidHide = useCallback( () => {\n\t\tif ( shouldPreventAutomaticScroll() ) {\n\t\t\tclearTimeout( timeoutRef.current );\n\t\t\treturn;\n\t\t}\n\n\t\t// A timeout is being used to delay resetting the offset in cases\n\t\t// where the focus is changed to a different TextInput.\n\t\tclearTimeout( timeoutRef.current );\n\t\ttimeoutRef.current = setTimeout( () => {\n\t\t\tsetKeyboardOffset( 0 );\n\t\t}, 200 );\n\t}, [ shouldPreventAutomaticScroll ] );\n\n\tconst onKeyboardDidShow = useCallback( ( { endCoordinates } ) => {\n\t\tclearTimeout( timeoutRef.current );\n\t\tsetKeyboardOffset( endCoordinates.height );\n\t}, [] );\n\n\tconst onKeyboardWillShow = useCallback( () => {\n\t\tclearTimeout( timeoutRef.current );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\tlet willShowSubscription;\n\t\tlet showSubscription;\n\t\tlet hideSubscription;\n\n\t\tif ( scrollEnabled ) {\n\t\t\twillShowSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardWillShow',\n\t\t\t\tonKeyboardWillShow\n\t\t\t);\n\t\t\tshowSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardDidShow',\n\t\t\t\tonKeyboardDidShow\n\t\t\t);\n\t\t\thideSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardDidHide',\n\t\t\t\tonKeyboardDidHide\n\t\t\t);\n\t\t} else {\n\t\t\twillShowSubscription?.remove();\n\t\t\tshowSubscription?.remove();\n\t\t\thideSubscription?.remove();\n\t\t}\n\n\t\treturn () => {\n\t\t\tclearTimeout( timeoutRef.current );\n\t\t\twillShowSubscription?.remove();\n\t\t\tshowSubscription?.remove();\n\t\t\thideSubscription?.remove();\n\t\t};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;IACxB,IAAIC,gBAAgB;IACpB,IAAIC,gBAAgB;IAEpB,IAAKf,aAAa,EAAG;MACpBa,oBAAoB,GAAGnB,QAAQ,CAACsB,WAAW,CAC1C,kBAAkB,EAClBJ,kBACD,CAAC;MACDE,gBAAgB,GAAGpB,QAAQ,CAACsB,WAAW,CACtC,iBAAiB,EACjBP,iBACD,CAAC;MACDM,gBAAgB,GAAGrB,QAAQ,CAACsB,WAAW,CACtC,iBAAiB,EACjBX,iBACD,CAAC;IACF,CAAC,MAAM;MACNQ,oBAAoB,EAAEI,MAAM,CAAC,CAAC;MAC9BH,gBAAgB,EAAEG,MAAM,CAAC,CAAC;MAC1BF,gBAAgB,EAAEE,MAAM,CAAC,CAAC;IAC3B;IAEA,OAAO,MAAM;MACZX,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;MAClCM,oBAAoB,EAAEI,MAAM,CAAC,CAAC;MAC9BH,gBAAgB,EAAEG,MAAM,CAAC,CAAC;MAC1BF,gBAAgB,EAAEE,MAAM,CAAC,CAAC;IAC3B,CAAC;EACF,CAAC,EAAE,CACFZ,iBAAiB,EACjBI,iBAAiB,EACjBG,kBAAkB,EAClBZ,aAAa,CACZ,CAAC;EACH,OAAO,CAAEE,cAAc,CAAE;AAC1B"}
|
|
1
|
+
{"version":3,"names":["Keyboard","useEffect","useCallback","useState","useRef","useKeyboardOffset","scrollEnabled","shouldPreventAutomaticScroll","keyboardOffset","setKeyboardOffset","timeoutRef","onKeyboardDidHide","clearTimeout","current","setTimeout","onKeyboardDidShow","endCoordinates","height","onKeyboardWillShow","willShowSubscription","showSubscription","hideSubscription","addListener","remove"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-keyboard-offset.native.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { Keyboard } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useCallback, useState, useRef } from '@wordpress/element';\n\n/**\n * Hook that adds Keyboard listeners to get the offset space\n * when the keyboard is opened, taking into account focused AztecViews.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {Function} shouldPreventAutomaticScroll Whether to prevent scrolling when there's a Keyboard offset set.\n * @return {[number]} Keyboard offset.\n */\nexport default function useKeyboardOffset(\n\tscrollEnabled,\n\tshouldPreventAutomaticScroll\n) {\n\tconst [ keyboardOffset, setKeyboardOffset ] = useState( 0 );\n\tconst timeoutRef = useRef();\n\n\tconst onKeyboardDidHide = useCallback( () => {\n\t\tif ( shouldPreventAutomaticScroll() ) {\n\t\t\tclearTimeout( timeoutRef.current );\n\t\t\treturn;\n\t\t}\n\n\t\t// A timeout is being used to delay resetting the offset in cases\n\t\t// where the focus is changed to a different TextInput.\n\t\tclearTimeout( timeoutRef.current );\n\t\ttimeoutRef.current = setTimeout( () => {\n\t\t\tsetKeyboardOffset( 0 );\n\t\t}, 200 );\n\t}, [ shouldPreventAutomaticScroll ] );\n\n\tconst onKeyboardDidShow = useCallback( ( { endCoordinates } ) => {\n\t\tclearTimeout( timeoutRef.current );\n\t\tsetKeyboardOffset( endCoordinates.height );\n\t}, [] );\n\n\tconst onKeyboardWillShow = useCallback( () => {\n\t\tclearTimeout( timeoutRef.current );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\tlet willShowSubscription;\n\t\tlet showSubscription;\n\t\tlet hideSubscription;\n\n\t\tif ( scrollEnabled ) {\n\t\t\twillShowSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardWillShow',\n\t\t\t\tonKeyboardWillShow\n\t\t\t);\n\t\t\tshowSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardDidShow',\n\t\t\t\tonKeyboardDidShow\n\t\t\t);\n\t\t\thideSubscription = Keyboard.addListener(\n\t\t\t\t'keyboardDidHide',\n\t\t\t\tonKeyboardDidHide\n\t\t\t);\n\t\t} else {\n\t\t\twillShowSubscription?.remove();\n\t\t\tshowSubscription?.remove();\n\t\t\thideSubscription?.remove();\n\t\t}\n\n\t\treturn () => {\n\t\t\tclearTimeout( timeoutRef.current );\n\t\t\twillShowSubscription?.remove();\n\t\t\tshowSubscription?.remove();\n\t\t\thideSubscription?.remove();\n\t\t};\n\t}, [\n\t\tonKeyboardDidHide,\n\t\tonKeyboardDidShow,\n\t\tonKeyboardWillShow,\n\t\tscrollEnabled,\n\t] );\n\treturn [ keyboardOffset ];\n}\n"],"mappings":"AAAA;AACA;AACA;;AAEA,SAASA,QAAQ,QAAQ,cAAc;;AAEvC;AACA;AACA;AACA,SAASC,SAAS,EAAEC,WAAW,EAAEC,QAAQ,EAAEC,MAAM,QAAQ,oBAAoB;;AAE7E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,iBAAiBA,CACxCC,aAAa,EACbC,4BAA4B,EAC3B;EACD,MAAM,CAAEC,cAAc,EAAEC,iBAAiB,CAAE,GAAGN,QAAQ,CAAE,CAAE,CAAC;EAC3D,MAAMO,UAAU,GAAGN,MAAM,CAAC,CAAC;EAE3B,MAAMO,iBAAiB,GAAGT,WAAW,CAAE,MAAM;IAC5C,IAAKK,4BAA4B,CAAC,CAAC,EAAG;MACrCK,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;MAClC;IACD;;IAEA;IACA;IACAD,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;IAClCH,UAAU,CAACG,OAAO,GAAGC,UAAU,CAAE,MAAM;MACtCL,iBAAiB,CAAE,CAAE,CAAC;IACvB,CAAC,EAAE,GAAI,CAAC;EACT,CAAC,EAAE,CAAEF,4BAA4B,CAAG,CAAC;EAErC,MAAMQ,iBAAiB,GAAGb,WAAW,CAAE,CAAE;IAAEc;EAAe,CAAC,KAAM;IAChEJ,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;IAClCJ,iBAAiB,CAAEO,cAAc,CAACC,MAAO,CAAC;EAC3C,CAAC,EAAE,EAAG,CAAC;EAEP,MAAMC,kBAAkB,GAAGhB,WAAW,CAAE,MAAM;IAC7CU,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;EACnC,CAAC,EAAE,EAAG,CAAC;EAEPZ,SAAS,CAAE,MAAM;IAChB,IAAIkB,oBAAoB;IACxB,IAAIC,gBAAgB;IACpB,IAAIC,gBAAgB;IAEpB,IAAKf,aAAa,EAAG;MACpBa,oBAAoB,GAAGnB,QAAQ,CAACsB,WAAW,CAC1C,kBAAkB,EAClBJ,kBACD,CAAC;MACDE,gBAAgB,GAAGpB,QAAQ,CAACsB,WAAW,CACtC,iBAAiB,EACjBP,iBACD,CAAC;MACDM,gBAAgB,GAAGrB,QAAQ,CAACsB,WAAW,CACtC,iBAAiB,EACjBX,iBACD,CAAC;IACF,CAAC,MAAM;MACNQ,oBAAoB,EAAEI,MAAM,CAAC,CAAC;MAC9BH,gBAAgB,EAAEG,MAAM,CAAC,CAAC;MAC1BF,gBAAgB,EAAEE,MAAM,CAAC,CAAC;IAC3B;IAEA,OAAO,MAAM;MACZX,YAAY,CAAEF,UAAU,CAACG,OAAQ,CAAC;MAClCM,oBAAoB,EAAEI,MAAM,CAAC,CAAC;MAC9BH,gBAAgB,EAAEG,MAAM,CAAC,CAAC;MAC1BF,gBAAgB,EAAEE,MAAM,CAAC,CAAC;IAC3B,CAAC;EACF,CAAC,EAAE,CACFZ,iBAAiB,EACjBI,iBAAiB,EACjBG,kBAAkB,EAClBZ,aAAa,CACZ,CAAC;EACH,OAAO,CAAEE,cAAc,CAAE;AAC1B","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useCallback","useScrollToElement","scrollViewRef","scrollToSection","scrollToElement","elementRef","current","measureLayout","_x","y","_width","height","Math","round"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll-to-element.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * Hook to scroll to a specified element by taking into account the Keyboard\n * and the Header.\n *\n * @param {RefObject} scrollViewRef Scroll view reference.\n * @param {Function} scrollToSection Function to scroll.\n * @return {Function[]} Function to scroll to an element.\n */\nexport default function useScrollToElement( scrollViewRef, scrollToSection ) {\n\t/**\n\t * Function to scroll to an element.\n\t *\n\t * @param {RefObject} elementRef Ref of the element.\n\t */\n\tconst scrollToElement = useCallback(\n\t\t( elementRef ) => {\n\t\t\tif ( ! scrollViewRef.current || ! elementRef ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\telementRef.current.measureLayout(\n\t\t\t\tscrollViewRef.current,\n\t\t\t\t( _x, y, _width, height ) => {\n\t\t\t\t\tif ( height || y ) {\n\t\t\t\t\t\tscrollToSection( Math.round( y ), height );\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t() => {}\n\t\t\t);\n\t\t},\n\t\t[ scrollViewRef, scrollToSection ]\n\t);\n\n\treturn [ scrollToElement ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,kBAAkBA,CAAEC,aAAa,EAAEC,eAAe,EAAG;EAC5E;AACD;AACA;AACA;AACA;EACC,MAAMC,eAAe,GAAGJ,WAAW,CAChCK,UAAU,IAAM;IACjB,IAAK,CAAEH,aAAa,CAACI,OAAO,IAAI,CAAED,UAAU,EAAG;MAC9C;IACD;IAEAA,UAAU,CAACC,OAAO,CAACC,aAAa,CAC/BL,aAAa,CAACI,OAAO,EACrB,CAAEE,EAAE,EAAEC,CAAC,EAAEC,MAAM,EAAEC,MAAM,KAAM;MAC5B,IAAKA,MAAM,IAAIF,CAAC,EAAG;QAClBN,eAAe,CAAES,IAAI,CAACC,KAAK,CAAEJ,CAAE,CAAC,EAAEE,MAAO,CAAC;MAC3C;IACD,CAAC,EACD,MAAM,CAAC,CACR,CAAC;EACF,CAAC,EACD,CAAET,aAAa,EAAEC,eAAe,CACjC,CAAC;EAED,OAAO,CAAEC,eAAe,CAAE;AAC3B"}
|
|
1
|
+
{"version":3,"names":["useCallback","useScrollToElement","scrollViewRef","scrollToSection","scrollToElement","elementRef","current","measureLayout","_x","y","_width","height","Math","round"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll-to-element.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * Hook to scroll to a specified element by taking into account the Keyboard\n * and the Header.\n *\n * @param {RefObject} scrollViewRef Scroll view reference.\n * @param {Function} scrollToSection Function to scroll.\n * @return {Function[]} Function to scroll to an element.\n */\nexport default function useScrollToElement( scrollViewRef, scrollToSection ) {\n\t/**\n\t * Function to scroll to an element.\n\t *\n\t * @param {RefObject} elementRef Ref of the element.\n\t */\n\tconst scrollToElement = useCallback(\n\t\t( elementRef ) => {\n\t\t\tif ( ! scrollViewRef.current || ! elementRef ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\telementRef.current.measureLayout(\n\t\t\t\tscrollViewRef.current,\n\t\t\t\t( _x, y, _width, height ) => {\n\t\t\t\t\tif ( height || y ) {\n\t\t\t\t\t\tscrollToSection( Math.round( y ), height );\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t() => {}\n\t\t\t);\n\t\t},\n\t\t[ scrollViewRef, scrollToSection ]\n\t);\n\n\treturn [ scrollToElement ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,kBAAkBA,CAAEC,aAAa,EAAEC,eAAe,EAAG;EAC5E;AACD;AACA;AACA;AACA;EACC,MAAMC,eAAe,GAAGJ,WAAW,CAChCK,UAAU,IAAM;IACjB,IAAK,CAAEH,aAAa,CAACI,OAAO,IAAI,CAAED,UAAU,EAAG;MAC9C;IACD;IAEAA,UAAU,CAACC,OAAO,CAACC,aAAa,CAC/BL,aAAa,CAACI,OAAO,EACrB,CAAEE,EAAE,EAAEC,CAAC,EAAEC,MAAM,EAAEC,MAAM,KAAM;MAC5B,IAAKA,MAAM,IAAIF,CAAC,EAAG;QAClBN,eAAe,CAAES,IAAI,CAACC,KAAK,CAAEJ,CAAE,CAAC,EAAEE,MAAO,CAAC;MAC3C;IACD,CAAC,EACD,MAAM,CAAC,CACR,CAAC;EACF,CAAC,EACD,CAAET,aAAa,EAAEC,eAAe,CACjC,CAAC;EAED,OAAO,CAAEC,eAAe,CAAE;AAC3B","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useSafeAreaInsets","useCallback","useScrollToSection","extraScrollHeight","keyboardOffset","scrollEnabled","scrollViewMeasurements","scrollViewRef","scrollViewYOffset","top","bottom","insets","scrollToSection","sectionY","sectionHeight","current","currentScrollViewYOffset","Math","max","value","scrollTo","y","animated","availableScreenSpace","abs","floor","height","maxOffset","isAtTheTop"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll-to-section.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\n\n/**\n * WordPress dependencies\n */\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/** @typedef {import('react-native-reanimated').SharedValue} SharedValue */\n/**\n * Hook to scroll to a specified section by taking into account the Keyboard\n * and the Header.\n *\n * @param {number} extraScrollHeight Extra space to not overlap the content.\n * @param {number} keyboardOffset Keyboard space offset.\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {RefObject} scrollViewMeasurements ScrollView Layout measurements.\n * @param {RefObject} scrollViewRef Scroll view reference.\n * @param {SharedValue} scrollViewYOffset Current offset position of the ScrollView.\n * @return {Function[]} Function to scroll to a section.\n */\nexport default function useScrollToSection(\n\textraScrollHeight,\n\tkeyboardOffset,\n\tscrollEnabled,\n\tscrollViewMeasurements,\n\tscrollViewRef,\n\tscrollViewYOffset\n) {\n\tconst { top, bottom } = useSafeAreaInsets();\n\tconst insets = top + bottom;\n\n\t/**\n\t * Function to scroll to a section.\n\t *\n\t * @param {Object} section Section data to scroll to.\n\t * @param {number} section.y Y-coordinate of of the section.\n\t * @param {number} section.height Height of the section.\n\t */\n\tconst scrollToSection = useCallback(\n\t\t( sectionY, sectionHeight ) => {\n\t\t\tif (\n\t\t\t\t! scrollViewRef.current ||\n\t\t\t\t! scrollEnabled ||\n\t\t\t\t! scrollViewMeasurements.current\n\t\t\t) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst currentScrollViewYOffset = Math.max(\n\t\t\t\t0,\n\t\t\t\tscrollViewYOffset.value\n\t\t\t);\n\n\t\t\t// Scroll to the top of the section.\n\t\t\tif ( sectionY < currentScrollViewYOffset ) {\n\t\t\t\tscrollViewRef.current.scrollTo( {\n\t\t\t\t\ty: sectionY,\n\t\t\t\t\tanimated: true,\n\t\t\t\t} );\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst availableScreenSpace = Math.abs(\n\t\t\t\tMath.floor(\n\t\t\t\t\tscrollViewMeasurements.current.height -\n\t\t\t\t\t\t( keyboardOffset + extraScrollHeight + sectionHeight )\n\t\t\t\t)\n\t\t\t);\n\t\t\tconst maxOffset = Math.floor(\n\t\t\t\tcurrentScrollViewYOffset + availableScreenSpace\n\t\t\t);\n\n\t\t\tconst isAtTheTop =\n\t\t\t\tsectionY < scrollViewMeasurements.current.y + insets;\n\n\t\t\t// Scroll to the bottom of the section.\n\t\t\tif ( sectionY > maxOffset && ! isAtTheTop ) {\n\t\t\t\tscrollViewRef.current.scrollTo( {\n\t\t\t\t\ty: sectionY - availableScreenSpace,\n\t\t\t\t\tanimated: true,\n\t\t\t\t} );\n\t\t\t}\n\t\t},\n\t\t[\n\t\t\textraScrollHeight,\n\t\t\tinsets,\n\t\t\tkeyboardOffset,\n\t\t\tscrollEnabled,\n\t\t\tscrollViewMeasurements,\n\t\t\tscrollViewRef,\n\t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GAAGP,sBAAsB,CAACS,OAAO,CAACM,CAAC,GAAGV,MAAM;;IAErD;IACA,IAAKE,QAAQ,GAAGc,SAAS,IAAI,CAAEC,UAAU,EAAG;MAC3CrB,aAAa,CAACQ,OAAO,CAACK,QAAQ,CAAE;QAC/BC,CAAC,EAAER,QAAQ,GAAGU,oBAAoB;QAClCD,QAAQ,EAAE;MACX,CAAE,CAAC;IACJ;EACD,CAAC,EACD,CACCnB,iBAAiB,EACjBQ,MAAM,EACNP,cAAc,EACdC,aAAa,EACbC,sBAAsB,EACtBC,aAAa,EACbC,iBAAiB,CAEnB,CAAC;EAED,OAAO,CAAEI,eAAe,CAAE;AAC3B"}
|
|
1
|
+
{"version":3,"names":["useSafeAreaInsets","useCallback","useScrollToSection","extraScrollHeight","keyboardOffset","scrollEnabled","scrollViewMeasurements","scrollViewRef","scrollViewYOffset","top","bottom","insets","scrollToSection","sectionY","sectionHeight","current","currentScrollViewYOffset","Math","max","value","scrollTo","y","animated","availableScreenSpace","abs","floor","height","maxOffset","isAtTheTop"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll-to-section.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { useSafeAreaInsets } from 'react-native-safe-area-context';\n\n/**\n * WordPress dependencies\n */\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/** @typedef {import('react-native-reanimated').SharedValue} SharedValue */\n/**\n * Hook to scroll to a specified section by taking into account the Keyboard\n * and the Header.\n *\n * @param {number} extraScrollHeight Extra space to not overlap the content.\n * @param {number} keyboardOffset Keyboard space offset.\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {RefObject} scrollViewMeasurements ScrollView Layout measurements.\n * @param {RefObject} scrollViewRef Scroll view reference.\n * @param {SharedValue} scrollViewYOffset Current offset position of the ScrollView.\n * @return {Function[]} Function to scroll to a section.\n */\nexport default function useScrollToSection(\n\textraScrollHeight,\n\tkeyboardOffset,\n\tscrollEnabled,\n\tscrollViewMeasurements,\n\tscrollViewRef,\n\tscrollViewYOffset\n) {\n\tconst { top, bottom } = useSafeAreaInsets();\n\tconst insets = top + bottom;\n\n\t/**\n\t * Function to scroll to a section.\n\t *\n\t * @param {Object} section Section data to scroll to.\n\t * @param {number} section.y Y-coordinate of of the section.\n\t * @param {number} section.height Height of the section.\n\t */\n\tconst scrollToSection = useCallback(\n\t\t( sectionY, sectionHeight ) => {\n\t\t\tif (\n\t\t\t\t! scrollViewRef.current ||\n\t\t\t\t! scrollEnabled ||\n\t\t\t\t! scrollViewMeasurements.current\n\t\t\t) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst currentScrollViewYOffset = Math.max(\n\t\t\t\t0,\n\t\t\t\tscrollViewYOffset.value\n\t\t\t);\n\n\t\t\t// Scroll to the top of the section.\n\t\t\tif ( sectionY < currentScrollViewYOffset ) {\n\t\t\t\tscrollViewRef.current.scrollTo( {\n\t\t\t\t\ty: sectionY,\n\t\t\t\t\tanimated: true,\n\t\t\t\t} );\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst availableScreenSpace = Math.abs(\n\t\t\t\tMath.floor(\n\t\t\t\t\tscrollViewMeasurements.current.height -\n\t\t\t\t\t\t( keyboardOffset + extraScrollHeight + sectionHeight )\n\t\t\t\t)\n\t\t\t);\n\t\t\tconst maxOffset = Math.floor(\n\t\t\t\tcurrentScrollViewYOffset + availableScreenSpace\n\t\t\t);\n\n\t\t\tconst isAtTheTop =\n\t\t\t\tsectionY < scrollViewMeasurements.current.y + insets;\n\n\t\t\t// Scroll to the bottom of the section.\n\t\t\tif ( sectionY > maxOffset && ! isAtTheTop ) {\n\t\t\t\tscrollViewRef.current.scrollTo( {\n\t\t\t\t\ty: sectionY - availableScreenSpace,\n\t\t\t\t\tanimated: true,\n\t\t\t\t} );\n\t\t\t}\n\t\t},\n\t\t[\n\t\t\textraScrollHeight,\n\t\t\tinsets,\n\t\t\tkeyboardOffset,\n\t\t\tscrollEnabled,\n\t\t\tscrollViewMeasurements,\n\t\t\tscrollViewRef,\n\t\t\tscrollViewYOffset,\n\t\t]\n\t);\n\n\treturn [ scrollToSection ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,iBAAiB,QAAQ,gCAAgC;;AAElE;AACA;AACA;AACA,SAASC,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,kBAAkBA,CACzCC,iBAAiB,EACjBC,cAAc,EACdC,aAAa,EACbC,sBAAsB,EACtBC,aAAa,EACbC,iBAAiB,EAChB;EACD,MAAM;IAAEC,GAAG;IAAEC;EAAO,CAAC,GAAGV,iBAAiB,CAAC,CAAC;EAC3C,MAAMW,MAAM,GAAGF,GAAG,GAAGC,MAAM;;EAE3B;AACD;AACA;AACA;AACA;AACA;AACA;EACC,MAAME,eAAe,GAAGX,WAAW,CAClC,CAAEY,QAAQ,EAAEC,aAAa,KAAM;IAC9B,IACC,CAAEP,aAAa,CAACQ,OAAO,IACvB,CAAEV,aAAa,IACf,CAAEC,sBAAsB,CAACS,OAAO,EAC/B;MACD;IACD;IAEA,MAAMC,wBAAwB,GAAGC,IAAI,CAACC,GAAG,CACxC,CAAC,EACDV,iBAAiB,CAACW,KACnB,CAAC;;IAED;IACA,IAAKN,QAAQ,GAAGG,wBAAwB,EAAG;MAC1CT,aAAa,CAACQ,OAAO,CAACK,QAAQ,CAAE;QAC/BC,CAAC,EAAER,QAAQ;QACXS,QAAQ,EAAE;MACX,CAAE,CAAC;MACH;IACD;IAEA,MAAMC,oBAAoB,GAAGN,IAAI,CAACO,GAAG,CACpCP,IAAI,CAACQ,KAAK,CACTnB,sBAAsB,CAACS,OAAO,CAACW,MAAM,IAClCtB,cAAc,GAAGD,iBAAiB,GAAGW,aAAa,CACtD,CACD,CAAC;IACD,MAAMa,SAAS,GAAGV,IAAI,CAACQ,KAAK,CAC3BT,wBAAwB,GAAGO,oBAC5B,CAAC;IAED,MAAMK,UAAU,GACff,QAAQ,GAAGP,sBAAsB,CAACS,OAAO,CAACM,CAAC,GAAGV,MAAM;;IAErD;IACA,IAAKE,QAAQ,GAAGc,SAAS,IAAI,CAAEC,UAAU,EAAG;MAC3CrB,aAAa,CAACQ,OAAO,CAACK,QAAQ,CAAE;QAC/BC,CAAC,EAAER,QAAQ,GAAGU,oBAAoB;QAClCD,QAAQ,EAAE;MACX,CAAE,CAAC;IACJ;EACD,CAAC,EACD,CACCnB,iBAAiB,EACjBQ,MAAM,EACNP,cAAc,EACdC,aAAa,EACbC,sBAAsB,EACtBC,aAAa,EACbC,iBAAiB,CAEnB,CAAC;EAED,OAAO,CAAEI,eAAe,CAAE;AAC3B","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useWindowDimensions","useAnimatedScrollHandler","useSharedValue","useCallback","useEffect","useRef","useKeyboardOffset","useScrollToSection","useScrollToElement","useScroll","scrollEnabled","shouldPreventAutomaticScroll","onScroll","onSizeChange","extraScrollHeight","scrollViewRef","scrollViewMeasurements","scrollViewYOffset","lastScrollTo","clientId","height","windowHeight","width","windowWidth","isLandscape","keyboardOffset","scrollHandler","event","contentOffset","value","y","current","scrollToSection","scrollToElement","measureScrollView","measureInWindow","_x","onContentSizeChange"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll.native.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { useWindowDimensions } from 'react-native';\nimport {\n\tuseAnimatedScrollHandler,\n\tuseSharedValue,\n} from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport { useCallback, useEffect, useRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport useKeyboardOffset from './use-keyboard-offset';\nimport useScrollToSection from './use-scroll-to-section';\nimport useScrollToElement from './use-scroll-to-element';\n\nexport default function useScroll( {\n\tscrollEnabled,\n\tshouldPreventAutomaticScroll,\n\tonScroll,\n\tonSizeChange,\n\textraScrollHeight,\n} ) {\n\tconst scrollViewRef = useRef();\n\tconst scrollViewMeasurements = useRef();\n\tconst scrollViewYOffset = useSharedValue( -1 );\n\tconst lastScrollTo = useRef( {\n\t\tclientId: null,\n\t} );\n\n\tconst { height: windowHeight, width: windowWidth } = useWindowDimensions();\n\tconst isLandscape = windowWidth >= windowHeight;\n\n\tconst [ keyboardOffset ] = useKeyboardOffset(\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll\n\t);\n\n\tconst scrollHandler = useAnimatedScrollHandler( {\n\t\tonScroll: ( event ) => {\n\t\t\tconst { contentOffset } = event;\n\t\t\tscrollViewYOffset.value = contentOffset.y;\n\t\t\tonScroll( event );\n\t\t},\n\t} );\n\n\t// When the orientation changes, the ScrollView measurements\n\t// need to be re-calculated.\n\tuseEffect( () => {\n\t\tscrollViewMeasurements.current = null;\n\t}, [ isLandscape ] );\n\n\tconst [ scrollToSection ] = useScrollToSection(\n\t\textraScrollHeight,\n\t\tkeyboardOffset,\n\t\tscrollEnabled,\n\t\tscrollViewMeasurements,\n\t\tscrollViewRef,\n\t\tscrollViewYOffset\n\t);\n\tconst [ scrollToElement ] = useScrollToElement(\n\t\tscrollViewRef,\n\t\tscrollToSection\n\t);\n\n\tconst measureScrollView = useCallback( () => {\n\t\tif ( scrollViewRef.current ) {\n\t\t\tscrollViewRef.current.measureInWindow( ( _x, y, width, height ) => {\n\t\t\t\tscrollViewMeasurements.current = { y, width, height };\n\t\t\t} );\n\t\t}\n\t}, [ scrollViewRef ] );\n\n\tconst onContentSizeChange = useCallback( () => {\n\t\tif ( onSizeChange ) {\n\t\t\tonSizeChange();\n\t\t}\n\n\t\t// Sets the first values when the content size changes.\n\t\tif ( ! scrollViewMeasurements.current ) {\n\t\t\tmeasureScrollView();\n\t\t}\n\t}, [ measureScrollView, onSizeChange ] );\n\n\treturn {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tkeyboardOffset,\n\t\tscrollToSection,\n\t\tsc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G,IAAI;EACtC,CAAC,EAAE,CAAEP,WAAW,CAAG,CAAC;EAEpB,MAAM,CAAEQ,eAAe,CAAE,GAAGzB,kBAAkB,CAC7CO,iBAAiB,EACjBW,cAAc,EACdf,aAAa,EACbM,sBAAsB,EACtBD,aAAa,EACbE,iBACD,CAAC;EACD,MAAM,CAAEgB,eAAe,CAAE,GAAGzB,kBAAkB,CAC7CO,aAAa,EACbiB,eACD,CAAC;EAED,MAAME,iBAAiB,GAAG/B,WAAW,CAAE,MAAM;IAC5C,IAAKY,aAAa,CAACgB,OAAO,EAAG;MAC5BhB,aAAa,CAACgB,OAAO,CAACI,eAAe,CAAE,CAAEC,EAAE,EAAEN,CAAC,EAAER,KAAK,EAAEF,MAAM,KAAM;QAClEJ,sBAAsB,CAACe,OAAO,GAAG;UAAED,CAAC;UAAER,KAAK;UAAEF;QAAO,CAAC;MACtD,CAAE,CAAC;IACJ;EACD,CAAC,EAAE,CAAEL,aAAa,CAAG,CAAC;EAEtB,MAAMsB,mBAAmB,GAAGlC,WAAW,CAAE,MAAM;IAC9C,IAAKU,YAAY,EAAG;MACnBA,YAAY,CAAC,CAAC;IACf;;IAEA;IACA,IAAK,CAAEG,sBAAsB,CAACe,OAAO,EAAG;MACvCG,iBAAiB,CAAC,CAAC;IACpB;EACD,CAAC,EAAE,CAAEA,iBAAiB,EAAErB,YAAY,CAAG,CAAC;EAExC,OAAO;IACNE,aAAa;IACbW,aAAa;IACbD,cAAc;IACdO,eAAe;IACfC,eAAe;IACfI,mBAAmB;IACnBnB;EACD,CAAC;AACF"}
|
|
1
|
+
{"version":3,"names":["useWindowDimensions","useAnimatedScrollHandler","useSharedValue","useCallback","useEffect","useRef","useKeyboardOffset","useScrollToSection","useScrollToElement","useScroll","scrollEnabled","shouldPreventAutomaticScroll","onScroll","onSizeChange","extraScrollHeight","scrollViewRef","scrollViewMeasurements","scrollViewYOffset","lastScrollTo","clientId","height","windowHeight","width","windowWidth","isLandscape","keyboardOffset","scrollHandler","event","contentOffset","value","y","current","scrollToSection","scrollToElement","measureScrollView","measureInWindow","_x","onContentSizeChange"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-scroll.native.js"],"sourcesContent":["/**\n * External dependencies\n */\n\nimport { useWindowDimensions } from 'react-native';\nimport {\n\tuseAnimatedScrollHandler,\n\tuseSharedValue,\n} from 'react-native-reanimated';\n\n/**\n * WordPress dependencies\n */\nimport { useCallback, useEffect, useRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport useKeyboardOffset from './use-keyboard-offset';\nimport useScrollToSection from './use-scroll-to-section';\nimport useScrollToElement from './use-scroll-to-element';\n\nexport default function useScroll( {\n\tscrollEnabled,\n\tshouldPreventAutomaticScroll,\n\tonScroll,\n\tonSizeChange,\n\textraScrollHeight,\n} ) {\n\tconst scrollViewRef = useRef();\n\tconst scrollViewMeasurements = useRef();\n\tconst scrollViewYOffset = useSharedValue( -1 );\n\tconst lastScrollTo = useRef( {\n\t\tclientId: null,\n\t} );\n\n\tconst { height: windowHeight, width: windowWidth } = useWindowDimensions();\n\tconst isLandscape = windowWidth >= windowHeight;\n\n\tconst [ keyboardOffset ] = useKeyboardOffset(\n\t\tscrollEnabled,\n\t\tshouldPreventAutomaticScroll\n\t);\n\n\tconst scrollHandler = useAnimatedScrollHandler( {\n\t\tonScroll: ( event ) => {\n\t\t\tconst { contentOffset } = event;\n\t\t\tscrollViewYOffset.value = contentOffset.y;\n\t\t\tonScroll( event );\n\t\t},\n\t} );\n\n\t// When the orientation changes, the ScrollView measurements\n\t// need to be re-calculated.\n\tuseEffect( () => {\n\t\tscrollViewMeasurements.current = null;\n\t}, [ isLandscape ] );\n\n\tconst [ scrollToSection ] = useScrollToSection(\n\t\textraScrollHeight,\n\t\tkeyboardOffset,\n\t\tscrollEnabled,\n\t\tscrollViewMeasurements,\n\t\tscrollViewRef,\n\t\tscrollViewYOffset\n\t);\n\tconst [ scrollToElement ] = useScrollToElement(\n\t\tscrollViewRef,\n\t\tscrollToSection\n\t);\n\n\tconst measureScrollView = useCallback( () => {\n\t\tif ( scrollViewRef.current ) {\n\t\t\tscrollViewRef.current.measureInWindow( ( _x, y, width, height ) => {\n\t\t\t\tscrollViewMeasurements.current = { y, width, height };\n\t\t\t} );\n\t\t}\n\t}, [ scrollViewRef ] );\n\n\tconst onContentSizeChange = useCallback( () => {\n\t\tif ( onSizeChange ) {\n\t\t\tonSizeChange();\n\t\t}\n\n\t\t// Sets the first values when the content size changes.\n\t\tif ( ! scrollViewMeasurements.current ) {\n\t\t\tmeasureScrollView();\n\t\t}\n\t}, [ measureScrollView, onSizeChange ] );\n\n\treturn {\n\t\tscrollViewRef,\n\t\tscrollHandler,\n\t\tkeyboardOffset,\n\t\tscrollToSection,\n\t\tscrollToElement,\n\t\tonContentSizeChange,\n\t\tlastScrollTo,\n\t};\n}\n"],"mappings":"AAAA;AACA;AACA;;AAEA,SAASA,mBAAmB,QAAQ,cAAc;AAClD,SACCC,wBAAwB,EACxBC,cAAc,QACR,yBAAyB;;AAEhC;AACA;AACA;AACA,SAASC,WAAW,EAAEC,SAAS,EAAEC,MAAM,QAAQ,oBAAoB;;AAEnE;AACA;AACA;AACA,OAAOC,iBAAiB,MAAM,uBAAuB;AACrD,OAAOC,kBAAkB,MAAM,yBAAyB;AACxD,OAAOC,kBAAkB,MAAM,yBAAyB;AAExD,eAAe,SAASC,SAASA,CAAE;EAClCC,aAAa;EACbC,4BAA4B;EAC5BC,QAAQ;EACRC,YAAY;EACZC;AACD,CAAC,EAAG;EACH,MAAMC,aAAa,GAAGV,MAAM,CAAC,CAAC;EAC9B,MAAMW,sBAAsB,GAAGX,MAAM,CAAC,CAAC;EACvC,MAAMY,iBAAiB,GAAGf,cAAc,CAAE,CAAC,CAAE,CAAC;EAC9C,MAAMgB,YAAY,GAAGb,MAAM,CAAE;IAC5Bc,QAAQ,EAAE;EACX,CAAE,CAAC;EAEH,MAAM;IAAEC,MAAM,EAAEC,YAAY;IAAEC,KAAK,EAAEC;EAA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ACvCG,iBAAiB,CAAC,CAAC;IACpB;EACD,CAAC,EAAE,CAAEA,iBAAiB,EAAErB,YAAY,CAAG,CAAC;EAExC,OAAO;IACNE,aAAa;IACbW,aAAa;IACbD,cAAc;IACdO,eAAe;IACfC,eAAe;IACfI,mBAAmB;IACnBnB;EACD,CAAC;AACF","ignoreList":[]}
|
package/build-module/mobile/keyboard-aware-flat-list/use-text-input-caret-position.native.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["RCTAztecView","useCallback","useEffect","useState","useTextInputCaretPosition","scrollEnabled","currentCaretData","setCurrentCaretData","onCaretChange","caret","InputState","addCaretChangeListener","removeCaretChangeListener"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-text-input-caret-position.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport RCTAztecView from '@wordpress/react-native-aztec';\nimport { useCallback, useEffect, useState } from '@wordpress/element';\n\n/**\n * Hook that listens to caret changes from AztecView TextInputs.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @return {[number]} Current caret's data.\n */\nexport default function useTextInputCaretPosition( scrollEnabled ) {\n\tconst [ currentCaretData, setCurrentCaretData ] = useState();\n\n\tconst onCaretChange = useCallback( ( caret ) => {\n\t\tsetCurrentCaretData( caret );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\tif ( scrollEnabled ) {\n\t\t\tRCTAztecView.InputState.addCaretChangeListener( onCaretChange );\n\t\t} else {\n\t\t\tRCTAztecView.InputState.removeCaretChangeListener( onCaretChange );\n\t\t}\n\n\t\treturn () => {\n\t\t\tif ( scrollEnabled ) {\n\t\t\t\tRCTAztecView.InputState.removeCaretChangeListener(\n\t\t\t\t\tonCaretChange\n\t\t\t\t);\n\t\t\t}\n\t\t};\n\t}, [ scrollEnabled, onCaretChange ] );\n\treturn [ currentCaretData ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,YAAY,MAAM,+BAA+B;AACxD,SAASC,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,oBAAoB;;AAErE;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,yBAAyBA,CAAEC,aAAa,EAAG;EAClE,MAAM,CAAEC,gBAAgB,EAAEC,mBAAmB,CAAE,GAAGJ,QAAQ,CAAC,CAAC;EAE5D,MAAMK,aAAa,GAAGP,WAAW,CAAIQ,KAAK,IAAM;IAC/CF,mBAAmB,CAAEE,KAAM,CAAC;EAC7B,CAAC,EAAE,EAAG,CAAC;EAEPP,SAAS,CAAE,MAAM;IAChB,IAAKG,aAAa,EAAG;MACpBL,YAAY,CAACU,UAAU,CAACC,sBAAsB,CAAEH,aAAc,CAAC;IAChE,CAAC,MAAM;MACNR,YAAY,CAACU,UAAU,CAACE,yBAAyB,CAAEJ,aAAc,CAAC;IACnE;IAEA,OAAO,MAAM;MACZ,IAAKH,aAAa,EAAG;QACpBL,YAAY,CAACU,UAAU,CAACE,yBAAyB,CAChDJ,aACD,CAAC;MACF;IACD,CAAC;EACF,CAAC,EAAE,CAAEH,aAAa,EAAEG,aAAa,CAAG,CAAC;EACrC,OAAO,CAAEF,gBAAgB,CAAE;AAC5B"}
|
|
1
|
+
{"version":3,"names":["RCTAztecView","useCallback","useEffect","useState","useTextInputCaretPosition","scrollEnabled","currentCaretData","setCurrentCaretData","onCaretChange","caret","InputState","addCaretChangeListener","removeCaretChangeListener"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-text-input-caret-position.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport RCTAztecView from '@wordpress/react-native-aztec';\nimport { useCallback, useEffect, useState } from '@wordpress/element';\n\n/**\n * Hook that listens to caret changes from AztecView TextInputs.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @return {[number]} Current caret's data.\n */\nexport default function useTextInputCaretPosition( scrollEnabled ) {\n\tconst [ currentCaretData, setCurrentCaretData ] = useState();\n\n\tconst onCaretChange = useCallback( ( caret ) => {\n\t\tsetCurrentCaretData( caret );\n\t}, [] );\n\n\tuseEffect( () => {\n\t\tif ( scrollEnabled ) {\n\t\t\tRCTAztecView.InputState.addCaretChangeListener( onCaretChange );\n\t\t} else {\n\t\t\tRCTAztecView.InputState.removeCaretChangeListener( onCaretChange );\n\t\t}\n\n\t\treturn () => {\n\t\t\tif ( scrollEnabled ) {\n\t\t\t\tRCTAztecView.InputState.removeCaretChangeListener(\n\t\t\t\t\tonCaretChange\n\t\t\t\t);\n\t\t\t}\n\t\t};\n\t}, [ scrollEnabled, onCaretChange ] );\n\treturn [ currentCaretData ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,YAAY,MAAM,+BAA+B;AACxD,SAASC,WAAW,EAAEC,SAAS,EAAEC,QAAQ,QAAQ,oBAAoB;;AAErE;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,yBAAyBA,CAAEC,aAAa,EAAG;EAClE,MAAM,CAAEC,gBAAgB,EAAEC,mBAAmB,CAAE,GAAGJ,QAAQ,CAAC,CAAC;EAE5D,MAAMK,aAAa,GAAGP,WAAW,CAAIQ,KAAK,IAAM;IAC/CF,mBAAmB,CAAEE,KAAM,CAAC;EAC7B,CAAC,EAAE,EAAG,CAAC;EAEPP,SAAS,CAAE,MAAM;IAChB,IAAKG,aAAa,EAAG;MACpBL,YAAY,CAACU,UAAU,CAACC,sBAAsB,CAAEH,aAAc,CAAC;IAChE,CAAC,MAAM;MACNR,YAAY,CAACU,UAAU,CAACE,yBAAyB,CAAEJ,aAAc,CAAC;IACnE;IAEA,OAAO,MAAM;MACZ,IAAKH,aAAa,EAAG;QACpBL,YAAY,CAACU,UAAU,CAACE,yBAAyB,CAChDJ,aACD,CAAC;MACF;IACD,CAAC;EACF,CAAC,EAAE,CAAEH,aAAa,EAAEG,aAAa,CAAG,CAAC;EACrC,OAAO,CAAEF,gBAAgB,CAAE;AAC5B","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["RCTAztecView","useCallback","useTextInputOffset","scrollEnabled","scrollViewRef","getTextInputOffset","caret","caretY","textInput","InputState","getCurrentFocusedElement","Promise","resolve","current","measureLayout","_x","y","_width","height","caretYOffset","Math","round","abs"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-text-input-offset.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport RCTAztecView from '@wordpress/react-native-aztec';\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * Hook that calculates the currently focused TextInput's current\n * caret Y coordinate position.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {RefObject} scrollViewRef ScrollView reference.\n * @return {[Function]} Function to get the current TextInput's offset.\n */\nexport default function useTextInputOffset( scrollEnabled, scrollViewRef ) {\n\tconst getTextInputOffset = useCallback(\n\t\tasync ( caret ) => {\n\t\t\tconst { caretY = null } = caret ?? {};\n\t\t\tconst textInput =\n\t\t\t\tRCTAztecView.InputState.getCurrentFocusedElement();\n\n\t\t\treturn new Promise( ( resolve ) => {\n\t\t\t\tif (\n\t\t\t\t\tscrollViewRef.current &&\n\t\t\t\t\ttextInput &&\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tcaretY !== null\n\t\t\t\t) {\n\t\t\t\t\ttextInput.measureLayout(\n\t\t\t\t\t\tscrollViewRef.current,\n\t\t\t\t\t\t( _x, y, _width, height ) => {\n\t\t\t\t\t\t\tconst caretYOffset =\n\t\t\t\t\t\t\t\t// For cases where the caretY value is -1\n\t\t\t\t\t\t\t\t// we use the y + height value, e.g the current\n\t\t\t\t\t\t\t\t// character index is not valid or out of bounds\n\t\t\t\t\t\t\t\t// see https://github.com/wordpress-mobile/AztecEditor-iOS/blob/4d0522d67b0056ac211466caaa76936cc5b4f947/Aztec/Classes/TextKit/TextView.swift#L762\n\t\t\t\t\t\t\t\tcaretY >= 0 && caretY < height\n\t\t\t\t\t\t\t\t\t? y + caretY\n\t\t\t\t\t\t\t\t\t: y + height;\n\t\t\t\t\t\t\tresolve( Math.round( Math.abs( caretYOffset ) ) );\n\t\t\t\t\t\t},\n\t\t\t\t\t\t() => resolve( null )\n\t\t\t\t\t);\n\t\t\t\t} else {\n\t\t\t\t\tresolve( null );\n\t\t\t\t}\n\t\t\t} );\n\t\t},\n\t\t[ scrollEnabled, scrollViewRef ]\n\t);\n\n\treturn [ getTextInputOffset ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,YAAY,MAAM,+BAA+B;AACxD,SAASC,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,kBAAkBA,CAAEC,aAAa,EAAEC,aAAa,EAAG;EAC1E,MAAMC,kBAAkB,GAAGJ,WAAW,CACrC,MAAQK,KAAK,IAAM;IAClB,MAAM;MAAEC,MAAM,GAAG;IAAK,CAAC,GAAGD,KAAK,aAALA,KAAK,cAALA,KAAK,GAAI,CAAC,CAAC;IACrC,MAAME,SAAS,GACdR,YAAY,CAACS,UAAU,CAACC,wBAAwB,CAAC,CAAC;IAEnD,OAAO,IAAIC,OAAO,CAAIC,OAAO,IAAM;MAClC,IACCR,aAAa,CAACS,OAAO,IACrBL,SAAS,IACTL,aAAa,IACbI,MAAM,KAAK,IAAI,EACd;QACDC,SAAS,CAACM,aAAa,CACtBV,aAAa,CAACS,OAAO,EACrB,CAAEE,EAAE,EAAEC,CAAC,EAAEC,MAAM,EAAEC,MAAM,KAAM;UAC5B,MAAMC,YAAY;UACjB;UACA;UACA;UACA;UACAZ,MAAM,IAAI,CAAC,IAAIA,MAAM,GAAGW,MAAM,GAC3BF,CAAC,GAAGT,MAAM,GACVS,CAAC,GAAGE,MAAM;UACdN,OAAO,CAAEQ,IAAI,CAACC,KAAK,CAAED,IAAI,CAACE,GAAG,CAAEH,YAAa,CAAE,CAAE,CAAC;QAClD,CAAC,EACD,MAAMP,OAAO,CAAE,IAAK,CACrB,CAAC;MACF,CAAC,MAAM;QACNA,OAAO,CAAE,IAAK,CAAC;MAChB;IACD,CAAE,CAAC;EACJ,CAAC,EACD,CAAET,aAAa,EAAEC,aAAa,CAC/B,CAAC;EAED,OAAO,CAAEC,kBAAkB,CAAE;AAC9B"}
|
|
1
|
+
{"version":3,"names":["RCTAztecView","useCallback","useTextInputOffset","scrollEnabled","scrollViewRef","getTextInputOffset","caret","caretY","textInput","InputState","getCurrentFocusedElement","Promise","resolve","current","measureLayout","_x","y","_width","height","caretYOffset","Math","round","abs"],"sources":["@wordpress/components/src/mobile/keyboard-aware-flat-list/use-text-input-offset.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport RCTAztecView from '@wordpress/react-native-aztec';\nimport { useCallback } from '@wordpress/element';\n\n/** @typedef {import('@wordpress/element').RefObject} RefObject */\n/**\n * Hook that calculates the currently focused TextInput's current\n * caret Y coordinate position.\n *\n * @param {boolean} scrollEnabled Whether the scroll is enabled or not.\n * @param {RefObject} scrollViewRef ScrollView reference.\n * @return {[Function]} Function to get the current TextInput's offset.\n */\nexport default function useTextInputOffset( scrollEnabled, scrollViewRef ) {\n\tconst getTextInputOffset = useCallback(\n\t\tasync ( caret ) => {\n\t\t\tconst { caretY = null } = caret ?? {};\n\t\t\tconst textInput =\n\t\t\t\tRCTAztecView.InputState.getCurrentFocusedElement();\n\n\t\t\treturn new Promise( ( resolve ) => {\n\t\t\t\tif (\n\t\t\t\t\tscrollViewRef.current &&\n\t\t\t\t\ttextInput &&\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tcaretY !== null\n\t\t\t\t) {\n\t\t\t\t\ttextInput.measureLayout(\n\t\t\t\t\t\tscrollViewRef.current,\n\t\t\t\t\t\t( _x, y, _width, height ) => {\n\t\t\t\t\t\t\tconst caretYOffset =\n\t\t\t\t\t\t\t\t// For cases where the caretY value is -1\n\t\t\t\t\t\t\t\t// we use the y + height value, e.g the current\n\t\t\t\t\t\t\t\t// character index is not valid or out of bounds\n\t\t\t\t\t\t\t\t// see https://github.com/wordpress-mobile/AztecEditor-iOS/blob/4d0522d67b0056ac211466caaa76936cc5b4f947/Aztec/Classes/TextKit/TextView.swift#L762\n\t\t\t\t\t\t\t\tcaretY >= 0 && caretY < height\n\t\t\t\t\t\t\t\t\t? y + caretY\n\t\t\t\t\t\t\t\t\t: y + height;\n\t\t\t\t\t\t\tresolve( Math.round( Math.abs( caretYOffset ) ) );\n\t\t\t\t\t\t},\n\t\t\t\t\t\t() => resolve( null )\n\t\t\t\t\t);\n\t\t\t\t} else {\n\t\t\t\t\tresolve( null );\n\t\t\t\t}\n\t\t\t} );\n\t\t},\n\t\t[ scrollEnabled, scrollViewRef ]\n\t);\n\n\treturn [ getTextInputOffset ];\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,YAAY,MAAM,+BAA+B;AACxD,SAASC,WAAW,QAAQ,oBAAoB;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,kBAAkBA,CAAEC,aAAa,EAAEC,aAAa,EAAG;EAC1E,MAAMC,kBAAkB,GAAGJ,WAAW,CACrC,MAAQK,KAAK,IAAM;IAClB,MAAM;MAAEC,MAAM,GAAG;IAAK,CAAC,GAAGD,KAAK,aAALA,KAAK,cAALA,KAAK,GAAI,CAAC,CAAC;IACrC,MAAME,SAAS,GACdR,YAAY,CAACS,UAAU,CAACC,wBAAwB,CAAC,CAAC;IAEnD,OAAO,IAAIC,OAAO,CAAIC,OAAO,IAAM;MAClC,IACCR,aAAa,CAACS,OAAO,IACrBL,SAAS,IACTL,aAAa,IACbI,MAAM,KAAK,IAAI,EACd;QACDC,SAAS,CAACM,aAAa,CACtBV,aAAa,CAACS,OAAO,EACrB,CAAEE,EAAE,EAAEC,CAAC,EAAEC,MAAM,EAAEC,MAAM,KAAM;UAC5B,MAAMC,YAAY;UACjB;UACA;UACA;UACA;UACAZ,MAAM,IAAI,CAAC,IAAIA,MAAM,GAAGW,MAAM,GAC3BF,CAAC,GAAGT,MAAM,GACVS,CAAC,GAAGE,MAAM;UACdN,OAAO,CAAEQ,IAAI,CAACC,KAAK,CAAED,IAAI,CAACE,GAAG,CAAEH,YAAa,CAAE,CAAE,CAAC;QAClD,CAAC,EACD,MAAMP,OAAO,CAAE,IAAK,CACrB,CAAC;MACF,CAAC,MAAM;QACNA,OAAO,CAAE,IAAK,CAAC;MAChB;IACD,CAAE,CAAC;EACJ,CAAC,EACD,CAAET,aAAa,EAAEC,aAAa,CAC/B,CAAC;EAED,OAAO,CAAEC,kBAAkB,CAAE;AAC9B","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["LayoutAnimation","ANIMATION_DURATION","performLayoutAnimation","duration","configureNext","create","Types","easeInEaseOut","Properties","opacity"],"sources":["@wordpress/components/src/mobile/layout-animation/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { LayoutAnimation } from 'react-native';\n\nconst ANIMATION_DURATION = 300;\n\nexport function performLayoutAnimation( duration = ANIMATION_DURATION ) {\n\tLayoutAnimation.configureNext(\n\t\tLayoutAnimation.create(\n\t\t\tduration,\n\t\t\tLayoutAnimation.Types.easeInEaseOut,\n\t\t\tLayoutAnimation.Properties.opacity\n\t\t)\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,eAAe,QAAQ,cAAc;AAE9C,MAAMC,kBAAkB,GAAG,GAAG;AAE9B,OAAO,SAASC,sBAAsBA,CAAEC,QAAQ,GAAGF,kBAAkB,EAAG;EACvED,eAAe,CAACI,aAAa,CAC5BJ,eAAe,CAACK,MAAM,CACrBF,QAAQ,EACRH,eAAe,CAACM,KAAK,CAACC,aAAa,EACnCP,eAAe,CAACQ,UAAU,CAACC,OAC5B,CACD,CAAC;AACF"}
|
|
1
|
+
{"version":3,"names":["LayoutAnimation","ANIMATION_DURATION","performLayoutAnimation","duration","configureNext","create","Types","easeInEaseOut","Properties","opacity"],"sources":["@wordpress/components/src/mobile/layout-animation/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { LayoutAnimation } from 'react-native';\n\nconst ANIMATION_DURATION = 300;\n\nexport function performLayoutAnimation( duration = ANIMATION_DURATION ) {\n\tLayoutAnimation.configureNext(\n\t\tLayoutAnimation.create(\n\t\t\tduration,\n\t\t\tLayoutAnimation.Types.easeInEaseOut,\n\t\t\tLayoutAnimation.Properties.opacity\n\t\t)\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,eAAe,QAAQ,cAAc;AAE9C,MAAMC,kBAAkB,GAAG,GAAG;AAE9B,OAAO,SAASC,sBAAsBA,CAAEC,QAAQ,GAAGF,kBAAkB,EAAG;EACvED,eAAe,CAACI,aAAa,CAC5BJ,eAAe,CAACK,MAAM,CACrBF,QAAQ,EACRH,eAAe,CAACM,KAAK,CAACC,aAAa,EACnCP,eAAe,CAACQ,UAAU,CAACC,OAC5B,CACD,CAAC;AACF","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SafeAreaView","TouchableOpacity","View","Clipboard","useEffect","useState","__","sprintf","BottomSheet","Icon","getProtocol","isURL","prependHTTP","link","cancelCircleFilled","usePreferredColorSchemeStyle","LinkPickerResults","NavBar","styles","createDirectEntry","value","type","protocol","toLowerCase","includes","startsWith","isDirectEntry","title","url","getURLFromClipboard","text","getString","LinkPicker","initialValue","onLinkPicked","onCancel","cancel","setValue","clipboardUrl","setClipboardUrl","directEntry","pickLink","onSubmit","clear","omniCellStyle","omniCell","omniCellDark","iconStyle","icon","iconDark","then","catch","createElement","style","safeArea","DismissButton","onPress","Heading","ApplyButton","contentContainer","Cell","valueStyle","omniInput","placeholder","autoCapitalize","autoCorrect","keyboardType","onChangeValue","autoFocus","separatorType","clearIcon","fill","color","size","LinkSuggestionItemCell","accessible","accessibilityLabel","suggestion","query"],"sources":["@wordpress/components/src/mobile/link-picker/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { SafeAreaView, TouchableOpacity, View } from 'react-native';\nimport Clipboard from '@react-native-clipboard/clipboard';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useState } from '@wordpress/element';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { BottomSheet, Icon } from '@wordpress/components';\nimport { getProtocol, isURL, prependHTTP } from '@wordpress/url';\nimport { link, cancelCircleFilled } from '@wordpress/icons';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport LinkPickerResults from './link-picker-results';\nimport NavBar from '../bottom-sheet/nav-bar';\nimport styles from './styles.scss';\n\n// This creates a search suggestion for adding a url directly.\nexport const createDirectEntry = ( value ) => {\n\tlet type = 'URL';\n\n\tconst protocol = getProtocol( value )?.toLowerCase() || '';\n\n\tif ( protocol.includes( 'mailto' ) ) {\n\t\ttype = 'mailto';\n\t}\n\n\tif ( protocol.includes( 'tel' ) ) {\n\t\ttype = 'tel';\n\t}\n\n\tif ( value?.startsWith( '#' ) ) {\n\t\ttype = 'internal';\n\t}\n\n\treturn {\n\t\tisDirectEntry: true,\n\t\ttitle: value,\n\t\turl: type === 'URL' ? prependHTTP( value ) : value,\n\t\ttype,\n\t};\n};\n\nconst getURLFromClipboard = async () => {\n\tconst text = await Clipboard.getString();\n\treturn !! text && isURL( text ) ? text : '';\n};\n\nexport const LinkPicker = ( {\n\tvalue: initialValue,\n\tonLinkPicked,\n\tonCancel: cancel,\n} ) => {\n\tconst [ value, setValue ] = useState( initialValue );\n\tconst [ clipboardUrl, setClipboardUrl ] = useState( '' );\n\tconst directEntry = createDirectEntry( value );\n\n\t// The title of a direct entry is displayed as the raw input value, but if we\n\t// are replacing empty text, we want to use the generated url.\n\tconst pickLink = ( { title, url, isDirectEntry } ) => {\n\t\tonLinkPicked( { title: isDirectEntry ? url : title, url } );\n\t};\n\n\tconst onSubmit = () => {\n\t\tpickLink( directEntry );\n\t};\n\n\tconst clear = () => {\n\t\tsetValue( '' );\n\t\tsetClipboardUrl( '' );\n\t};\n\n\tconst omniCellStyle = usePreferredColorSchemeStyle(\n\t\tstyles.omniCell,\n\t\tstyles.omniCellDark\n\t);\n\n\tconst iconStyle = usePreferredColorSchemeStyle(\n\t\tstyles.icon,\n\t\tstyles.iconDark\n\t);\n\n\tuseEffect( () => {\n\t\tgetURLFromClipboard()\n\t\t\t.then( setClipboardUrl )\n\t\t\t.catch( () => setClipboardUrl( '' ) );\n\t}, [] );\n\n\t// TODO: Localize the accessibility label.\n\t// TODO: Decide on if `LinkSuggestionItemCell` with `isDirectEntry` makes sense.\n\treturn (\n\t\t<SafeAreaView style={ styles.safeArea }>\n\t\t\t<NavBar>\n\t\t\t\t<NavBar.DismissButton onPress={ cancel } />\n\t\t\t\t<NavBar.Heading>{ __( 'Link to' ) }</NavBar.Heading>\n\t\t\t\t<NavBar.ApplyButton onPress={ onSubmit } />\n\t\t\t</NavBar>\n\t\t\t<View style={ styles.contentContainer }>\n\t\t\t\t<BottomSheet.Cell\n\t\t\t\t\ticon={ link }\n\t\t\t\t\tstyle={ omniCellStyle }\n\t\t\t\t\tvalueStyle={ styles.omniInput }\n\t\t\t\t\tvalue={ value }\n\t\t\t\t\tplaceholder={ __( 'Search or type URL' ) }\n\t\t\t\t\tautoCapitalize=\"none\"\n\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\tkeyboardType=\"url\"\n\t\t\t\t\tonChangeValue={ setValue }\n\t\t\t\t\tonSubmit={ onSubmit }\n\t\t\t\t\t/* eslint-disable-next-line jsx-a11y/no-autofocus */\n\t\t\t\t\tautoFocus\n\t\t\t\t\tseparatorType=\"none\"\n\t\t\t\t>\n\t\t\t\t\t{ value !== '' && (\n\t\t\t\t\t\t<TouchableOpacity\n\t\t\t\t\t\t\tonPress={ clear }\n\t\t\t\t\t\t\tstyle={ styles.clearIcon }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<Icon\n\t\t\t\t\t\t\t\ticon={ cancelCircleFilled }\n\t\t\t\t\t\t\t\tfill={ iconStyle.color }\n\t\t\t\t\t\t\t\tsize={ 24 }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</TouchableOpacity>\n\t\t\t\t\t) }\n\t\t\t\t</BottomSheet.Cell>\n\t\t\t\t{ !! clipboardUrl && clipboardUrl !== value && (\n\t\t\t\t\t<BottomSheet.LinkSuggestionItemCell\n\t\t\t\t\t\taccessible\n\t\t\t\t\t\taccessibilityLabel={ sprintf(\n\t\t\t\t\t\t\t/* translators: Copy URL from the clipboard, https://sample.url */\n\t\t\t\t\t\t\t__( 'Copy URL from the clipboard, %s' ),\n\t\t\t\t\t\t\tclipboardUrl\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tsuggestion={ {\n\t\t\t\t\t\t\ttype: 'clipboard',\n\t\t\t\t\t\t\turl: clipboardUrl,\n\t\t\t\t\t\t\tisDirectEntry: true,\n\t\t\t\t\t\t} }\n\t\t\t\t\t\tonLinkPicked={ pickLink }\n\t\t\t\t\t/>\n\t\t\t\t) }\n\t\t\t\t{ !! value && (\n\t\t\t\t\t<LinkPickerResults\n\t\t\t\t\t\tquery={ value }\n\t\t\t\t\t\tonLinkPicked={ pickLink }\n\t\t\t\t\t\tdirectEntry={ directEntry }\n\t\t\t\t\t/>\n\t\t\t\t) }\n\t\t\t</View>\n\t\t</SafeAreaView>\n\t);\n};\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,YAAY,EAAEC,gBAAgB,EAAEC,IAAI,QAAQ,cAAc;AACnE,OAAOC,SAAS,MAAM,mCAAmC;;AAEzD;AACA;AACA;AACA,SAASC,SAAS,EAAEC,QAAQ,QAAQ,oBAAoB;AACxD,SAASC,EAAE,EAAEC,OAAO,QAAQ,iBAAiB;AAC7C,SAASC,WAAW,EAAEC,IAAI,QAAQ,uBAAuB;AACzD,SAASC,WAAW,EAAEC,KAAK,EAAEC,WAAW,QAAQ,gBAAgB;AAChE,SAASC,IAAI,EAAEC,kBAAkB,QAAQ,kBAAkB;AAC3D,SAASC,4BAA4B,QAAQ,oBAAoB;;A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TouchableOpacity","View","Clipboard","useEffect","useState","__","sprintf","BottomSheet","Icon","getProtocol","isURL","prependHTTP","link","cancelCircleFilled","usePreferredColorSchemeStyle","LinkPickerResults","NavBar","styles","createDirectEntry","value","type","protocol","toLowerCase","includes","startsWith","isDirectEntry","title","url","getURLFromClipboard","text","getString","LinkPicker","initialValue","onLinkPicked","onCancel","cancel","setValue","clipboardUrl","setClipboardUrl","directEntry","pickLink","onSubmit","clear","omniCellStyle","omniCell","omniCellDark","iconStyle","icon","iconDark","then","catch","createElement","style","safeArea","DismissButton","onPress","Heading","ApplyButton","contentContainer","Cell","valueStyle","omniInput","placeholder","autoCapitalize","autoCorrect","keyboardType","onChangeValue","autoFocus","separatorType","clearIcon","fill","color","size","LinkSuggestionItemCell","accessible","accessibilityLabel","suggestion","query"],"sources":["@wordpress/components/src/mobile/link-picker/index.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { SafeAreaView, TouchableOpacity, View } from 'react-native';\nimport Clipboard from '@react-native-clipboard/clipboard';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useState } from '@wordpress/element';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { BottomSheet, Icon } from '@wordpress/components';\nimport { getProtocol, isURL, prependHTTP } from '@wordpress/url';\nimport { link, cancelCircleFilled } from '@wordpress/icons';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport LinkPickerResults from './link-picker-results';\nimport NavBar from '../bottom-sheet/nav-bar';\nimport styles from './styles.scss';\n\n// This creates a search suggestion for adding a url directly.\nexport const createDirectEntry = ( value ) => {\n\tlet type = 'URL';\n\n\tconst protocol = getProtocol( value )?.toLowerCase() || '';\n\n\tif ( protocol.includes( 'mailto' ) ) {\n\t\ttype = 'mailto';\n\t}\n\n\tif ( protocol.includes( 'tel' ) ) {\n\t\ttype = 'tel';\n\t}\n\n\tif ( value?.startsWith( '#' ) ) {\n\t\ttype = 'internal';\n\t}\n\n\treturn {\n\t\tisDirectEntry: true,\n\t\ttitle: value,\n\t\turl: type === 'URL' ? prependHTTP( value ) : value,\n\t\ttype,\n\t};\n};\n\nconst getURLFromClipboard = async () => {\n\tconst text = await Clipboard.getString();\n\treturn !! text && isURL( text ) ? text : '';\n};\n\nexport const LinkPicker = ( {\n\tvalue: initialValue,\n\tonLinkPicked,\n\tonCancel: cancel,\n} ) => {\n\tconst [ value, setValue ] = useState( initialValue );\n\tconst [ clipboardUrl, setClipboardUrl ] = useState( '' );\n\tconst directEntry = createDirectEntry( value );\n\n\t// The title of a direct entry is displayed as the raw input value, but if we\n\t// are replacing empty text, we want to use the generated url.\n\tconst pickLink = ( { title, url, isDirectEntry } ) => {\n\t\tonLinkPicked( { title: isDirectEntry ? url : title, url } );\n\t};\n\n\tconst onSubmit = () => {\n\t\tpickLink( directEntry );\n\t};\n\n\tconst clear = () => {\n\t\tsetValue( '' );\n\t\tsetClipboardUrl( '' );\n\t};\n\n\tconst omniCellStyle = usePreferredColorSchemeStyle(\n\t\tstyles.omniCell,\n\t\tstyles.omniCellDark\n\t);\n\n\tconst iconStyle = usePreferredColorSchemeStyle(\n\t\tstyles.icon,\n\t\tstyles.iconDark\n\t);\n\n\tuseEffect( () => {\n\t\tgetURLFromClipboard()\n\t\t\t.then( setClipboardUrl )\n\t\t\t.catch( () => setClipboardUrl( '' ) );\n\t}, [] );\n\n\t// TODO: Localize the accessibility label.\n\t// TODO: Decide on if `LinkSuggestionItemCell` with `isDirectEntry` makes sense.\n\treturn (\n\t\t<SafeAreaView style={ styles.safeArea }>\n\t\t\t<NavBar>\n\t\t\t\t<NavBar.DismissButton onPress={ cancel } />\n\t\t\t\t<NavBar.Heading>{ __( 'Link to' ) }</NavBar.Heading>\n\t\t\t\t<NavBar.ApplyButton onPress={ onSubmit } />\n\t\t\t</NavBar>\n\t\t\t<View style={ styles.contentContainer }>\n\t\t\t\t<BottomSheet.Cell\n\t\t\t\t\ticon={ link }\n\t\t\t\t\tstyle={ omniCellStyle }\n\t\t\t\t\tvalueStyle={ styles.omniInput }\n\t\t\t\t\tvalue={ value }\n\t\t\t\t\tplaceholder={ __( 'Search or type URL' ) }\n\t\t\t\t\tautoCapitalize=\"none\"\n\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\tkeyboardType=\"url\"\n\t\t\t\t\tonChangeValue={ setValue }\n\t\t\t\t\tonSubmit={ onSubmit }\n\t\t\t\t\t/* eslint-disable-next-line jsx-a11y/no-autofocus */\n\t\t\t\t\tautoFocus\n\t\t\t\t\tseparatorType=\"none\"\n\t\t\t\t>\n\t\t\t\t\t{ value !== '' && (\n\t\t\t\t\t\t<TouchableOpacity\n\t\t\t\t\t\t\tonPress={ clear }\n\t\t\t\t\t\t\tstyle={ styles.clearIcon }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<Icon\n\t\t\t\t\t\t\t\ticon={ cancelCircleFilled }\n\t\t\t\t\t\t\t\tfill={ iconStyle.color }\n\t\t\t\t\t\t\t\tsize={ 24 }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</TouchableOpacity>\n\t\t\t\t\t) }\n\t\t\t\t</BottomSheet.Cell>\n\t\t\t\t{ !! clipboardUrl && clipboardUrl !== value && (\n\t\t\t\t\t<BottomSheet.LinkSuggestionItemCell\n\t\t\t\t\t\taccessible\n\t\t\t\t\t\taccessibilityLabel={ sprintf(\n\t\t\t\t\t\t\t/* translators: Copy URL from the clipboard, https://sample.url */\n\t\t\t\t\t\t\t__( 'Copy URL from the clipboard, %s' ),\n\t\t\t\t\t\t\tclipboardUrl\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tsuggestion={ {\n\t\t\t\t\t\t\ttype: 'clipboard',\n\t\t\t\t\t\t\turl: clipboardUrl,\n\t\t\t\t\t\t\tisDirectEntry: true,\n\t\t\t\t\t\t} }\n\t\t\t\t\t\tonLinkPicked={ pickLink }\n\t\t\t\t\t/>\n\t\t\t\t) }\n\t\t\t\t{ !! value && (\n\t\t\t\t\t<LinkPickerResults\n\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AAI,EAAG;EAAI,CACX,CACgB,CAEF,CAAC,EACjB,CAAC,CAAEnC,YAAY,IAAIA,YAAY,KAAKlB,KAAK,IAC1CgC,aAAA,CAAC5C,WAAW,CAACkE,sBAAsB;IAClCC,UAAU;IACVC,kBAAkB,EAAGrE,OAAO,EAC3B;IACAD,EAAE,CAAE,iCAAkC,CAAC,EACvCgC,YACD,CAAG;IACHuC,UAAU,EAAG;MACZxD,IAAI,EAAE,WAAW;MACjBO,GAAG,EAAEU,YAAY;MACjBZ,aAAa,EAAE;IAChB,CAAG;IACHQ,YAAY,EAAGO;EAAU,CACzB,CACD,EACC,CAAC,CAAErB,KAAK,IACTgC,aAAA,CAACpC,iBAAiB;IACjB8D,KAAK,EAAG1D,KAAO;IACfc,YAAY,EAAGO,QAAU;IACzBD,WAAW,EAAGA;EAAa,CAC3B,CAEG,CACO,CAAC;AAEjB,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ActivityIndicator","FlatList","View","BottomSheet","BottomSheetConsumer","debounce","useState","useEffect","useRef","useSelect","styles","PER_PAGE","REQUEST_DEBOUNCE_DELAY","MINIMUM_QUERY_SIZE","meetsThreshold","query","length","LinkPickerResults","onLinkPicked","directEntry","links","setLinks","hasAllSuggestions","setHasAllSuggestions","nextPage","pendingRequest","clearRequest","current","fetchMoreSuggestions","select","getSettings","fetchLinkSuggestions","search","__experimentalFetchLinkSuggestions","page","type","perPage","fetchMore","currentSuggestions","request","suggestions","onEndReached","spinner","createElement","style","testID","animating","listProps","data","keyboardShouldPersistTaps","renderItem","item","LinkSuggestionItemCell","suggestion","keyExtractor","url","onEndReachedThreshold","initialNumToRender","ListFooterComponent","contentContainerStyle","list"],"sources":["@wordpress/components/src/mobile/link-picker/link-picker-results.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { ActivityIndicator, FlatList, View } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { BottomSheet, BottomSheetConsumer } from '@wordpress/components';\nimport { debounce } from '@wordpress/compose';\nimport { useState, useEffect, useRef } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport styles from './styles.scss';\n\nconst PER_PAGE = 20;\nconst REQUEST_DEBOUNCE_DELAY = 400;\nconst MINIMUM_QUERY_SIZE = 2;\nconst meetsThreshold = ( query ) => MINIMUM_QUERY_SIZE <= query.length;\n\nexport default function LinkPickerResults( {\n\tquery,\n\tonLinkPicked,\n\tdirectEntry,\n} ) {\n\tconst [ links, setLinks ] = useState( [ directEntry ] );\n\tconst [ hasAllSuggestions, setHasAllSuggestions ] = useState( false );\n\tconst nextPage = useRef( 1 );\n\tconst pendingRequest = useRef();\n\tconst clearRequest = () => {\n\t\tpendingRequest.current = null;\n\t};\n\n\t// A stable debounced function to fetch suggestions and append.\n\tconst { fetchMoreSuggestions } = useSelect( ( select ) => {\n\t\tconst { getSettings } = select( 'core/block-editor' );\n\t\tconst fetchLinkSuggestions = async ( { search } ) => {\n\t\t\tif ( meetsThreshold( search ) ) {\n\t\t\t\treturn await getSettings().__experimentalFetchLinkSuggestions(\n\t\t\t\t\tsearch,\n\t\t\t\t\t{ page: nextPage.current, type: 'post', perPage: PER_PAGE }\n\t\t\t\t);\n\t\t\t}\n\t\t};\n\t\tconst fetchMore = async ( {\n\t\t\tquery: search,\n\t\t\tlinks: currentSuggestions,\n\t\t} ) => {\n\t\t\t// Return early if we've already detected the end of data or we are\n\t\t\t// already awaiting a response.\n\t\t\tif ( hasAllSuggestions || pendingRequest.current ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tconst request = fetchLinkSuggestions( { search } );\n\t\t\tpendingRequest.current = request;\n\t\t\tconst suggestions = await request;\n\n\t\t\t// Only update links for the most recent request.\n\t\t\tif ( suggestions && request === pendingRequest.current ) {\n\t\t\t\t// Since we don't have the response header, we check if the results\n\t\t\t\t// are truncated to determine we've reached the end.\n\t\t\t\tif ( suggestions.length < PER_PAGE ) {\n\t\t\t\t\tsetHasAllSuggestions( true );\n\t\t\t\t}\n\t\t\t\tsetLinks( [ ...currentSuggestions, ...suggestions ] );\n\t\t\t\tnextPage.current++;\n\t\t\t}\n\n\t\t\tclearRequest();\n\t\t};\n\t\treturn {\n\t\t\tfetchMoreSuggestions: debounce( fetchMore, REQUEST_DEBOUNCE_DELAY ),\n\t\t};\n\t\t// Disable eslint rule for now, to avoid introducing a regression\n\t\t// (see https://github.com/WordPress/gutenberg/pull/23922#discussion_r1170634879).\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [] );\n\n\t// Prevent setting state when unmounted.\n\tuseEffect( () => clearRequest, [] );\n\n\t// Any time the query changes, we reset pagination.\n\tuseEffect( () => {\n\t\tclearRequest();\n\t\tnextPage.current = 1;\n\t\tsetHasAllSuggestions( false );\n\t\tsetLinks( [ directEntry ] );\n\t\tfetchMoreSuggestions( { query, links: [ directEntry ] } );\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ query ] );\n\n\tconst onEndReached = () => fetchMoreSuggestions( { query, links } );\n\n\tconst spinner = ! hasAllSuggestions && meetsThreshold( query ) && (\n\t\t<View style={ styles.spinner } testID=\"link-picker-loading\">\n\t\t\t<ActivityIndicator animating />\n\t\t</View>\n\t);\n\n\treturn (\n\t\t<BottomSheetConsumer>\n\t\t\t{ ( { listProps } ) => (\n\t\t\t\t<FlatList\n\t\t\t\t\tdata={ links }\n\t\t\t\t\tkeyboardShouldPersistTaps=\"always\"\n\t\t\t\t\trenderItem={ ( { item } ) => (\n\t\t\t\t\t\t<BottomSheet.LinkSuggestionItemCell\n\t\t\t\t\t\t\tsuggestion={ item }\n\t\t\t\t\t\t\tonLinkPicked={ onLinkPicked }\n\t\t\t\t\t\t/>\n\t\t\t\t\t) }\n\t\t\t\t\tkeyExtractor={ ( { url, type } ) => `${ url }-${ type }` }\n\t\t\t\t\tonEndReached={ onEndReached }\n\t\t\t\t\tonEndReachedThreshold={ 0.1 }\n\t\t\t\t\tinitialNumToRender={ PER_PAGE }\n\t\t\t\t\tListFooterComponent={ spinner }\n\t\t\t\t\t{ ...listProps }\n\t\t\t\t\tcontentContainerStyle={ [\n\t\t\t\t\t\t...listProps.contentContainerStyle,\n\t\t\t\t\t\tstyles.list,\n\t\t\t\t\t] }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</BottomSheetConsumer>\n\t);\n}\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,iBAAiB,EAAEC,QAAQ,EAAEC,IAAI,QAAQ,cAAc;;AAEhE;AACA;AACA;AACA,SAASC,WAAW,EAAEC,mBAAmB,QAAQ,uBAAuB;AACxE,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,QAAQ,EAAEC,SAAS,EAAEC,MAAM,QAAQ,oBAAoB;AAChE,SAASC,SAAS,QAAQ,iBAAiB;;AAE3C;AACA;AACA;AACA,OAAOC,MAAM,MAAM,eAAe;AAElC,MAAMC,QAAQ,GAAG,EAAE;AACnB,MAAMC,sBAAsB,GAAG,GAAG;AAClC,MAAMC,kBAAkB,GAAG,CAAC;AAC5B,MAAMC,cAAc,GAAKC,KAAK,IAAMF,kBAAkB,IAAIE,KAAK,CAACC,MAAM;AAEtE,eAAe,SAASC,iBAAiBA,CAAE;EAC1CF,KAAK;EACLG,YAAY;EACZC;AACD,CAAC,EAAG;EACH,MAAM,CAAEC,KAAK,EAAEC,QAAQ,CAAE,GAAGf,QAAQ,CAAE,CAAEa,WAAW,CAAG,CAAC;EACvD,MAAM,CAAEG,iBAAiB,EAAEC,oBAAoB,CAAE,GAAGjB,QAAQ,CAAE,KAAM,CAAC;EACrE,MAAMkB,QAAQ,GAAGhB,MAAM,CAAE,CAAE,CAAC;EAC5B,MAAMiB,cAAc,GAAGjB,MAAM,CAAC,CAAC;EAC/B,MAAMkB,YAAY,GAAGA,CAAA,KAAM;IAC1BD,cAAc,CAACE,OA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+C,mBAAmB,EAAGhB,OAAS;IAAA,GAC1BK,SAAS;IACdY,qBAAqB,EAAG,CACvB,GAAGZ,SAAS,CAACY,qBAAqB,EAClCjD,MAAM,CAACkD,IAAI;EACT,CACH,CAEkB,CAAC;AAExB"}
|
|
1
|
+
{"version":3,"names":["ActivityIndicator","FlatList","View","BottomSheet","BottomSheetConsumer","debounce","useState","useEffect","useRef","useSelect","styles","PER_PAGE","REQUEST_DEBOUNCE_DELAY","MINIMUM_QUERY_SIZE","meetsThreshold","query","length","LinkPickerResults","onLinkPicked","directEntry","links","setLinks","hasAllSuggestions","setHasAllSuggestions","nextPage","pendingRequest","clearRequest","current","fetchMoreSuggestions","select","getSettings","fetchLinkSuggestions","search","__experimentalFetchLinkSuggestions","page","type","perPage","fetchMore","currentSuggestions","request","suggestions","onEndReached","spinner","createElement","style","testID","animating","listProps","data","keyboardShouldPersistTaps","renderItem","item","LinkSuggestionItemCell","suggestion","keyExtractor","url","onEndReachedThreshold","initialNumToRender","ListFooterComponent","contentContainerStyle","list"],"sources":["@wordpress/components/src/mobile/link-picker/link-picker-results.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { ActivityIndicator, FlatList, View } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { BottomSheet, BottomSheetConsumer } from '@wordpress/components';\nimport { debounce } from '@wordpress/compose';\nimport { useState, useEffect, useRef } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport styles from './styles.scss';\n\nconst PER_PAGE = 20;\nconst REQUEST_DEBOUNCE_DELAY = 400;\nconst MINIMUM_QUERY_SIZE = 2;\nconst meetsThreshold = ( query ) => MINIMUM_QUERY_SIZE <= query.length;\n\nexport default function LinkPickerResults( {\n\tquery,\n\tonLinkPicked,\n\tdirectEntry,\n} ) {\n\tconst [ links, setLinks ] = useState( [ directEntry ] );\n\tconst [ hasAllSuggestions, setHasAllSuggestions ] = useState( false );\n\tconst nextPage = useRef( 1 );\n\tconst pendingRequest = useRef();\n\tconst clearRequest = () => {\n\t\tpendingRequest.current = null;\n\t};\n\n\t// A stable debounced function to fetch suggestions and append.\n\tconst { fetchMoreSuggestions } = useSelect( ( select ) => {\n\t\tconst { getSettings } = select( 'core/block-editor' );\n\t\tconst fetchLinkSuggestions = async ( { search } ) => {\n\t\t\tif ( meetsThreshold( search ) ) {\n\t\t\t\treturn await getSettings().__experimentalFetchLinkSuggestions(\n\t\t\t\t\tsearch,\n\t\t\t\t\t{ page: nextPage.current, type: 'post', perPage: PER_PAGE }\n\t\t\t\t);\n\t\t\t}\n\t\t};\n\t\tconst fetchMore = async ( {\n\t\t\tquery: search,\n\t\t\tlinks: currentSuggestions,\n\t\t} ) => {\n\t\t\t// Return early if we've already detected the end of data or we are\n\t\t\t// already awaiting a response.\n\t\t\tif ( hasAllSuggestions || pendingRequest.current ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tconst request = fetchLinkSuggestions( { search } );\n\t\t\tpendingRequest.current = request;\n\t\t\tconst suggestions = await request;\n\n\t\t\t// Only update links for the most recent request.\n\t\t\tif ( suggestions && request === pendingRequest.current ) {\n\t\t\t\t// Since we don't have the response header, we check if the results\n\t\t\t\t// are truncated to determine we've reached the end.\n\t\t\t\tif ( suggestions.length < PER_PAGE ) {\n\t\t\t\t\tsetHasAllSuggestions( true );\n\t\t\t\t}\n\t\t\t\tsetLinks( [ ...currentSuggestions, ...suggestions ] );\n\t\t\t\tnextPage.current++;\n\t\t\t}\n\n\t\t\tclearRequest();\n\t\t};\n\t\treturn {\n\t\t\tfetchMoreSuggestions: debounce( fetchMore, REQUEST_DEBOUNCE_DELAY ),\n\t\t};\n\t\t// Disable eslint rule for now, to avoid introducing a regression\n\t\t// (see https://github.com/WordPress/gutenberg/pull/23922#discussion_r1170634879).\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [] );\n\n\t// Prevent setting state when unmounted.\n\tuseEffect( () => clearRequest, [] );\n\n\t// Any time the query changes, we reset pagination.\n\tuseEffect( () => {\n\t\tclearRequest();\n\t\tnextPage.current = 1;\n\t\tsetHasAllSuggestions( false );\n\t\tsetLinks( [ directEntry ] );\n\t\tfetchMoreSuggestions( { query, links: [ directEntry ] } );\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ query ] );\n\n\tconst onEndReached = () => fetchMoreSuggestions( { query, links } );\n\n\tconst spinner = ! hasAllSuggestions && meetsThreshold( query ) && (\n\t\t<View style={ styles.spinner } testID=\"link-picker-loading\">\n\t\t\t<ActivityIndicator animating />\n\t\t</View>\n\t);\n\n\treturn (\n\t\t<BottomSheetConsumer>\n\t\t\t{ ( { listProps } ) => (\n\t\t\t\t<FlatList\n\t\t\t\t\tdata={ links }\n\t\t\t\t\tkeyboardShouldPersistTaps=\"always\"\n\t\t\t\t\trenderItem={ ( { item } ) => (\n\t\t\t\t\t\t<BottomSheet.LinkSuggestionItemCell\n\t\t\t\t\t\t\tsuggestion={ item }\n\t\t\t\t\t\t\tonLinkPicked={ onLinkPicked }\n\t\t\t\t\t\t/>\n\t\t\t\t\t) }\n\t\t\t\t\tkeyExtractor={ ( { url, type } ) => `${ url }-${ type }` }\n\t\t\t\t\tonEndReached={ onEndReached }\n\t\t\t\t\tonEndReachedThreshold={ 0.1 }\n\t\t\t\t\tinitialNumToRender={ PER_PAGE }\n\t\t\t\t\tListFooterComponent={ spinner }\n\t\t\t\t\t{ ...listProps }\n\t\t\t\t\tcontentContainerStyle={ [\n\t\t\t\t\t\t...listProps.contentContainerStyle,\n\t\t\t\t\t\tstyles.list,\n\t\t\t\t\t] }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</BottomSheetConsumer>\n\t);\n}\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,iBAAiB,EAAEC,QAAQ,EAAEC,IAAI,QAAQ,cAAc;;AAEhE;AACA;AACA;AACA,SAASC,WAAW,E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AAA,KAAMb,oBAAoB,CAAE;IAAEb,KAAK;IAAEK;EAAM,CAAE,CAAC;EAEnE,MAAMsB,OAAO,GAAG,CAAEpB,iBAAiB,IAAIR,cAAc,CAAEC,KAAM,CAAC,IAC7D4B,aAAA,CAACzC,IAAI;IAAC0C,KAAK,EAAGlC,MAAM,CAACgC,OAAS;IAACG,MAAM,EAAC;EAAqB,GAC1DF,aAAA,CAAC3C,iBAAiB;IAAC8C,SAAS;EAAA,CAAE,CACzB,CACN;EAED,OACCH,aAAA,CAACvC,mBAAmB,QACjB,CAAE;IAAE2C;EAAU,CAAC,KAChBJ,aAAA,CAAC1C,QAAQ;IACR+C,IAAI,EAAG5B,KAAO;IACd6B,yBAAyB,EAAC,QAAQ;IAClCC,UAAU,EAAGA,CAAE;MAAEC;IAAK,CAAC,KACtBR,aAAA,CAACxC,WAAW,CAACiD,sBAAsB;MAClCC,UAAU,EAAGF,IAAM;MACnBjC,YAAY,EAAGA;IAAc,CAC7B,CACC;IACHoC,YAAY,EAAGA,CAAE;MAAEC,GAAG;MAAEpB;IAAK,CAAC,KAAO,GAAGoB,GAAK,IAAIpB,IAAM,EAAG;IAC1DM,YAAY,EAAGA,YAAc;IAC7Be,qBAAqB,EAAG,GAAK;IAC7BC,kBAAkB,EAAG9C,QAAU;IAC/B+C,mBAAmB,EAAGhB,OAAS;IAAA,GAC1BK,SAAS;IACdY,qBAAqB,EAAG,CACvB,GAAGZ,SAAS,CAACY,qBAAqB,EAClCjD,MAAM,CAACkD,IAAI;EACT,CACH,CAEkB,CAAC;AAExB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Keyboard","useNavigation","useRoute","useEffect","useMemo","useRef","LinkPicker","LinkPickerScreen","returnScreenName","navigation","route","navigateToLinkTimeoutRef","navigateBackTimeoutRef","onLinkPicked","url","title","dismiss","current","setTimeout","navigate","inputValue","text","onCancel","goBack","clearTimeout","params","createElement","value"],"sources":["@wordpress/components/src/mobile/link-picker/link-picker-screen.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Keyboard } from 'react-native';\nimport { useNavigation, useRoute } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useMemo, useRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { LinkPicker } from './';\n\nconst LinkPickerScreen = ( { returnScreenName } ) => {\n\tconst navigation = useNavigation();\n\tconst route = useRoute();\n\tconst navigateToLinkTimeoutRef = useRef( null );\n\tconst navigateBackTimeoutRef = useRef( null );\n\n\tconst onLinkPicked = ( { url, title } ) => {\n\t\tKeyboard.dismiss();\n\t\tnavigateToLinkTimeoutRef.current = setTimeout( () => {\n\t\t\tnavigation.navigate( returnScreenName, {\n\t\t\t\tinputValue: url,\n\t\t\t\ttext: title,\n\t\t\t} );\n\t\t}, 100 );\n\t};\n\n\tconst onCancel = () => {\n\t\tKeyboard.dismiss();\n\t\tnavigateBackTimeoutRef.current = setTimeout( () => {\n\t\t\tnavigation.goBack();\n\t\t}, 100 );\n\t};\n\n\tuseEffect( () => {\n\t\treturn () => {\n\t\t\tclearTimeout( navigateToLinkTimeoutRef.current );\n\t\t\tclearTimeout( navigateBackTimeoutRef.current );\n\t\t};\n\t}, [] );\n\n\tconst { inputValue } = route.params;\n\treturn useMemo( () => {\n\t\treturn (\n\t\t\t<LinkPicker\n\t\t\t\tvalue={ inputValue }\n\t\t\t\tonLinkPicked={ onLinkPicked }\n\t\t\t\tonCancel={ onCancel }\n\t\t\t/>\n\t\t);\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ inputValue ] );\n};\n\nexport default LinkPickerScreen;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,QAAQ,QAAQ,cAAc;AACvC,SAASC,aAAa,EAAEC,QAAQ,QAAQ,0BAA0B;;AAElE;AACA;AACA;AACA,SAASC,SAAS,EAAEC,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;MAC7BS,QAAQ,EAAGA;IAAU,CACrB,CAAC;IAEH;IACA;IACA;EACD,CAAC,EAAE,CAAEF,UAAU,CAAG,CAAC;AACpB,CAAC;AAED,eAAeb,gBAAgB"}
|
|
1
|
+
{"version":3,"names":["Keyboard","useNavigation","useRoute","useEffect","useMemo","useRef","LinkPicker","LinkPickerScreen","returnScreenName","navigation","route","navigateToLinkTimeoutRef","navigateBackTimeoutRef","onLinkPicked","url","title","dismiss","current","setTimeout","navigate","inputValue","text","onCancel","goBack","clearTimeout","params","createElement","value"],"sources":["@wordpress/components/src/mobile/link-picker/link-picker-screen.native.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport { Keyboard } from 'react-native';\nimport { useNavigation, useRoute } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { useEffect, useMemo, useRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { LinkPicker } from './';\n\nconst LinkPickerScreen = ( { returnScreenName } ) => {\n\tconst navigation = useNavigation();\n\tconst route = useRoute();\n\tconst navigateToLinkTimeoutRef = useRef( null );\n\tconst navigateBackTimeoutRef = useRef( null );\n\n\tconst onLinkPicked = ( { url, title } ) => {\n\t\tKeyboard.dismiss();\n\t\tnavigateToLinkTimeoutRef.current = setTimeout( () => {\n\t\t\tnavigation.navigate( returnScreenName, {\n\t\t\t\tinputValue: url,\n\t\t\t\ttext: title,\n\t\t\t} );\n\t\t}, 100 );\n\t};\n\n\tconst onCancel = () => {\n\t\tKeyboard.dismiss();\n\t\tnavigateBackTimeoutRef.current = setTimeout( () => {\n\t\t\tnavigation.goBack();\n\t\t}, 100 );\n\t};\n\n\tuseEffect( () => {\n\t\treturn () => {\n\t\t\tclearTimeout( navigateToLinkTimeoutRef.current );\n\t\t\tclearTimeout( navigateBackTimeoutRef.current );\n\t\t};\n\t}, [] );\n\n\tconst { inputValue } = route.params;\n\treturn useMemo( () => {\n\t\treturn (\n\t\t\t<LinkPicker\n\t\t\t\tvalue={ inputValue }\n\t\t\t\tonLinkPicked={ onLinkPicked }\n\t\t\t\tonCancel={ onCancel }\n\t\t\t/>\n\t\t);\n\t\t// Disable reason: deferring this refactor to the native team.\n\t\t// see https://github.com/WordPress/gutenberg/pull/41166\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [ inputValue ] );\n};\n\nexport default LinkPickerScreen;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,QAAQ,QAAQ,cAAc;AACvC,SAASC,aAAa,EAAEC,QAAQ,QAAQ,0BAA0B;;AAElE;AACA;AACA;AACA,SAASC,SAAS,EAAEC,OAAO,EAAEC,MAAM,QAAQ,oBAAoB;;AAE/D;AACA;AACA;AACA,SAASC,UAAU,QAAQ,IAAI;AAE/B,MAAMC,gBAAgB,GAAGA,CAAE;EAAEC;AAAiB,CAAC,KAAM;EACpD,MAAMC,UAAU,GAAGR,aAAa,CAAC,CAAC;EAClC,MAAMS,KAAK,GAAGR,QAAQ,CAAC,CAAC;EACxB,MAAMS,wBAAwB,GAAGN,MAAM,CAAE,IAAK,CAAC;EAC/C,MAAMO,sBAAsB,GAAGP,MAAM,CAAE,IAAK,CAAC;EAE7C,MAAMQ,YAAY,GAAGA,CAAE;IAAEC,GAAG;IAAEC;EAAM,CAAC,KAAM;IAC1Cf,QAAQ,CAACgB,OAAO,CAAC,CAAC;IAClBL,wBAAwB,CAACM,OAAO,GAAGC,UAAU,CAAE,MAAM;MACpDT,UAAU,CAACU,QAAQ,CAAEX,gBAAgB,EAAE;QACtCY,UAAU,EAAEN,GAAG;QACfO,IAAI,EAAEN;MACP,CAAE,CAAC;IACJ,CAAC,EAAE,GAAI,CAAC;EACT,CAAC;EAED,MAAMO,QAAQ,GAAGA,CAAA,KAAM;IACtBtB,QAAQ,CAACgB,OAAO,CAAC,CAAC;IAClBJ,sBAAsB,CAACK,OAAO,GAAGC,UAAU,CAAE,MAAM;MAClDT,UAAU,CAACc,MAAM,CAAC,CAAC;IACpB,CAAC,EAAE,GAAI,CAAC;E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