@cloudscape-design/components 3.0.135 → 3.0.137
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/alert/internal.d.ts +1 -1
- package/alert/internal.d.ts.map +1 -1
- package/app-layout/visual-refresh/styles.css.js +60 -60
- package/app-layout/visual-refresh/styles.scoped.css +148 -148
- package/app-layout/visual-refresh/styles.selectors.js +60 -60
- package/area-chart/chart-container.d.ts.map +1 -1
- package/area-chart/chart-container.js +2 -1
- package/area-chart/chart-container.js.map +1 -1
- package/area-chart/internal.d.ts +1 -1
- package/area-chart/internal.d.ts.map +1 -1
- package/area-chart/model/async-store.d.ts +2 -2
- package/area-chart/model/async-store.d.ts.map +1 -1
- package/area-chart/model/interactions-store.d.ts.map +1 -1
- package/area-chart/model/interactions-store.js +1 -1
- package/area-chart/model/interactions-store.js.map +1 -1
- package/area-chart/model/use-chart-model.d.ts +1 -2
- package/area-chart/model/use-chart-model.d.ts.map +1 -1
- package/area-chart/model/use-chart-model.js +46 -10
- package/area-chart/model/use-chart-model.js.map +1 -1
- package/area-chart/model/use-filter-props.d.ts +1 -1
- package/area-chart/model/use-filter-props.d.ts.map +1 -1
- package/area-chart/model/use-highlight-props.d.ts +1 -1
- package/area-chart/model/use-highlight-props.d.ts.map +1 -1
- package/attribute-editor/internal.js.map +1 -1
- package/autosuggest/interfaces.d.ts +1 -1
- package/autosuggest/interfaces.d.ts.map +1 -1
- package/autosuggest/options-controller.d.ts +1 -1
- package/autosuggest/options-controller.d.ts.map +1 -1
- package/autosuggest/plain-list.d.ts +1 -1
- package/autosuggest/plain-list.d.ts.map +1 -1
- package/bar-chart/interfaces.d.ts +1 -1
- package/bar-chart/interfaces.d.ts.map +1 -1
- package/box/internal.d.ts +1 -1
- package/box/internal.d.ts.map +1 -1
- package/breadcrumb-group/internal.d.ts +1 -1
- package/breadcrumb-group/internal.d.ts.map +1 -1
- package/button-dropdown/interfaces.d.ts +2 -2
- package/button-dropdown/interfaces.d.ts.map +1 -1
- package/button-dropdown/utils/create-items-tree.d.ts +1 -1
- package/button-dropdown/utils/create-items-tree.d.ts.map +1 -1
- package/calendar/internal.d.ts +1 -1
- package/calendar/internal.d.ts.map +1 -1
- package/code-editor/interfaces.d.ts +2 -2
- package/code-editor/interfaces.d.ts.map +1 -1
- package/code-editor/util.d.ts +1 -1
- package/code-editor/util.d.ts.map +1 -1
- package/collection-preferences/index.d.ts +1 -1
- package/collection-preferences/index.d.ts.map +1 -1
- package/collection-preferences/index.js +10 -5
- package/collection-preferences/index.js.map +1 -1
- package/collection-preferences/interfaces.d.ts +17 -0
- package/collection-preferences/interfaces.d.ts.map +1 -1
- package/collection-preferences/interfaces.js.map +1 -1
- package/collection-preferences/styles.css.js +20 -19
- package/collection-preferences/styles.scoped.css +21 -20
- package/collection-preferences/styles.selectors.js +20 -19
- package/collection-preferences/utils.d.ts +6 -1
- package/collection-preferences/utils.d.ts.map +1 -1
- package/collection-preferences/utils.js +10 -1
- package/collection-preferences/utils.js.map +1 -1
- package/column-layout/internal.d.ts +2 -2
- package/column-layout/internal.d.ts.map +1 -1
- package/container/use-sticky-header.d.ts +1 -1
- package/container/use-sticky-header.d.ts.map +1 -1
- package/date-range-picker/calendar/range-inputs.d.ts +1 -1
- package/date-range-picker/calendar/range-inputs.d.ts.map +1 -1
- package/date-range-picker/interfaces.d.ts +2 -2
- package/date-range-picker/interfaces.d.ts.map +1 -1
- package/expandable-section/internal.d.ts +1 -1
- package/expandable-section/internal.d.ts.map +1 -1
- package/form/internal.d.ts +1 -1
- package/form/internal.d.ts.map +1 -1
- package/icon/internal.d.ts +1 -1
- package/icon/internal.d.ts.map +1 -1
- package/input/index.js.map +1 -1
- package/internal/base-component/styles.scoped.css +4 -0
- package/internal/breakpoints.d.ts +1 -1
- package/internal/breakpoints.d.ts.map +1 -1
- package/internal/components/autosuggest-input/index.js.map +1 -1
- package/internal/components/cartesian-chart/bottom-labels.d.ts.map +1 -1
- package/internal/components/cartesian-chart/bottom-labels.js +1 -1
- package/internal/components/cartesian-chart/bottom-labels.js.map +1 -1
- package/internal/components/cartesian-chart/interfaces.d.ts +8 -8
- package/internal/components/cartesian-chart/interfaces.d.ts.map +1 -1
- package/internal/components/cartesian-chart/scales.d.ts +2 -2
- package/internal/components/cartesian-chart/scales.d.ts.map +1 -1
- package/internal/components/chart-plot/application-controller.js +1 -1
- package/internal/components/chart-plot/application-controller.js.map +1 -1
- package/internal/components/chart-plot/focus-outline.d.ts +2 -1
- package/internal/components/chart-plot/focus-outline.d.ts.map +1 -1
- package/internal/components/chart-plot/focus-outline.js +6 -4
- package/internal/components/chart-plot/focus-outline.js.map +1 -1
- package/internal/components/chart-plot/index.d.ts +3 -2
- package/internal/components/chart-plot/index.d.ts.map +1 -1
- package/internal/components/chart-plot/index.js.map +1 -1
- package/internal/components/chart-plot/interfaces.d.ts +5 -0
- package/internal/components/chart-plot/interfaces.d.ts.map +1 -0
- package/internal/components/chart-plot/interfaces.js +2 -0
- package/internal/components/chart-plot/interfaces.js.map +1 -0
- package/internal/components/chart-series-marker/index.d.ts +1 -1
- package/internal/components/chart-series-marker/index.d.ts.map +1 -1
- package/internal/components/dropdown/context.d.ts +1 -1
- package/internal/components/dropdown/context.d.ts.map +1 -1
- package/internal/components/dropdown/dropdown-fit-handler.d.ts +5 -5
- package/internal/components/dropdown/dropdown-fit-handler.d.ts.map +1 -1
- package/internal/components/dropdown/interfaces.d.ts +1 -1
- package/internal/components/dropdown/interfaces.d.ts.map +1 -1
- package/internal/components/dropdown-status/index.d.ts +1 -1
- package/internal/components/dropdown-status/index.d.ts.map +1 -1
- package/internal/components/interfaces.d.ts +5 -0
- package/internal/components/interfaces.d.ts.map +1 -0
- package/internal/components/interfaces.js +2 -0
- package/internal/components/interfaces.js.map +1 -0
- package/internal/components/live-region/index.d.ts +1 -1
- package/internal/components/live-region/index.d.ts.map +1 -1
- package/internal/components/option/utils/filter-options.d.ts +3 -3
- package/internal/components/option/utils/filter-options.d.ts.map +1 -1
- package/internal/components/options-list/utils/use-highlight-option.d.ts +1 -1
- package/internal/components/options-list/utils/use-highlight-option.d.ts.map +1 -1
- package/internal/components/selectable-item/index.d.ts +1 -1
- package/internal/components/selectable-item/index.d.ts.map +1 -1
- package/internal/components/transition/index.d.ts +1 -1
- package/internal/components/transition/index.d.ts.map +1 -1
- package/internal/context/split-panel-context.d.ts +1 -1
- package/internal/context/split-panel-context.d.ts.map +1 -1
- package/internal/environment.js +1 -1
- package/internal/events/index.d.ts +3 -3
- package/internal/events/index.d.ts.map +1 -1
- package/internal/generated/theming/index.cjs +26 -0
- package/internal/generated/theming/index.js +26 -0
- package/internal/hooks/container-queries/use-resize-observer.d.ts +1 -1
- package/internal/hooks/container-queries/use-resize-observer.d.ts.map +1 -1
- package/internal/hooks/forward-focus/index.js.map +1 -1
- package/internal/hooks/use-singleton-handler/index.d.ts +3 -3
- package/internal/hooks/use-singleton-handler/index.d.ts.map +1 -1
- package/internal/manifest.json +1 -1
- package/internal/metrics.d.ts +2 -2
- package/internal/metrics.d.ts.map +1 -1
- package/internal/metrics.js.map +1 -1
- package/internal/types.d.ts +1 -1
- package/internal/types.d.ts.map +1 -1
- package/internal/utils/locale/normalize-start-of-week.d.ts +1 -1
- package/internal/utils/locale/normalize-start-of-week.d.ts.map +1 -1
- package/internal/utils/scrollable-containers.d.ts +1 -1
- package/internal/utils/scrollable-containers.d.ts.map +1 -1
- package/internal/vendor/d3-scale.js +185 -186
- package/line-chart/interfaces.d.ts +1 -1
- package/line-chart/interfaces.d.ts.map +1 -1
- package/mixed-line-bar-chart/chart-container.d.ts +1 -2
- package/mixed-line-bar-chart/chart-container.d.ts.map +1 -1
- package/mixed-line-bar-chart/chart-container.js +55 -41
- package/mixed-line-bar-chart/chart-container.js.map +1 -1
- package/mixed-line-bar-chart/domain.js +4 -4
- package/mixed-line-bar-chart/domain.js.map +1 -1
- package/mixed-line-bar-chart/hooks/use-mouse-hover.d.ts +3 -4
- package/mixed-line-bar-chart/hooks/use-mouse-hover.d.ts.map +1 -1
- package/mixed-line-bar-chart/hooks/use-mouse-hover.js +22 -18
- package/mixed-line-bar-chart/hooks/use-mouse-hover.js.map +1 -1
- package/mixed-line-bar-chart/hooks/use-navigation.d.ts +7 -4
- package/mixed-line-bar-chart/hooks/use-navigation.d.ts.map +1 -1
- package/mixed-line-bar-chart/hooks/use-navigation.js +61 -31
- package/mixed-line-bar-chart/hooks/use-navigation.js.map +1 -1
- package/mixed-line-bar-chart/interfaces.d.ts +8 -4
- package/mixed-line-bar-chart/interfaces.d.ts.map +1 -1
- package/mixed-line-bar-chart/interfaces.js.map +1 -1
- package/mixed-line-bar-chart/internal.d.ts +1 -1
- package/mixed-line-bar-chart/internal.d.ts.map +1 -1
- package/mixed-line-bar-chart/internal.js +1 -1
- package/mixed-line-bar-chart/internal.js.map +1 -1
- package/mixed-line-bar-chart/utils.d.ts +1 -1
- package/mixed-line-bar-chart/utils.d.ts.map +1 -1
- package/modal/internal.d.ts +1 -1
- package/modal/internal.d.ts.map +1 -1
- package/package.json +1 -1
- package/pagination/internal.d.ts +1 -1
- package/pagination/internal.d.ts.map +1 -1
- package/popover/interfaces.d.ts +2 -2
- package/popover/interfaces.d.ts.map +1 -1
- package/property-filter/interfaces.d.ts +16 -16
- package/property-filter/interfaces.d.ts.map +1 -1
- package/property-filter/use-load-items.d.ts +2 -1
- package/property-filter/use-load-items.d.ts.map +1 -1
- package/s3-resource-selector/interfaces.d.ts +1 -1
- package/s3-resource-selector/interfaces.d.ts.map +1 -1
- package/segmented-control/internal.d.ts +1 -1
- package/segmented-control/internal.d.ts.map +1 -1
- package/select/utils/use-select.d.ts +3 -3
- package/select/utils/use-select.d.ts.map +1 -1
- package/select/utils/use-select.js +4 -3
- package/select/utils/use-select.js.map +1 -1
- package/side-navigation/util.d.ts +1 -1
- package/side-navigation/util.d.ts.map +1 -1
- package/space-between/internal.d.ts +1 -1
- package/space-between/internal.d.ts.map +1 -1
- package/table/body-cell/index.d.ts +3 -1
- package/table/body-cell/index.d.ts.map +1 -1
- package/table/body-cell/index.js +2 -2
- package/table/body-cell/index.js.map +1 -1
- package/table/body-cell/styles.css.js +8 -7
- package/table/body-cell/styles.scoped.css +21 -18
- package/table/body-cell/styles.selectors.js +8 -7
- package/table/header-cell/utils.d.ts +1 -1
- package/table/header-cell/utils.d.ts.map +1 -1
- package/table/interfaces.d.ts +4 -0
- package/table/interfaces.d.ts.map +1 -1
- package/table/interfaces.js.map +1 -1
- package/table/internal.d.ts.map +1 -1
- package/table/internal.js +4 -3
- package/table/internal.js.map +1 -1
- package/table/use-sticky-header.d.ts.map +1 -1
- package/table/use-sticky-header.js +4 -1
- package/table/use-sticky-header.js.map +1 -1
- package/tag-editor/validation.d.ts +1 -1
- package/tag-editor/validation.d.ts.map +1 -1
- package/test-utils/dom/collection-preferences/index.d.ts +1 -0
- package/test-utils/dom/collection-preferences/index.js +3 -0
- package/test-utils/dom/collection-preferences/index.js.map +1 -1
- package/test-utils/selectors/alert/index.js.map +1 -1
- package/test-utils/selectors/annotation/index.js.map +1 -1
- package/test-utils/selectors/app-layout/index.js.map +1 -1
- package/test-utils/selectors/area-chart/index.js.map +1 -1
- package/test-utils/selectors/attribute-editor/index.js.map +1 -1
- package/test-utils/selectors/autosuggest/index.js.map +1 -1
- package/test-utils/selectors/breadcrumb-group/index.js.map +1 -1
- package/test-utils/selectors/button/index.js.map +1 -1
- package/test-utils/selectors/button-dropdown/index.js.map +1 -1
- package/test-utils/selectors/calendar/index.js.map +1 -1
- package/test-utils/selectors/cards/index.js.map +1 -1
- package/test-utils/selectors/checkbox/index.js.map +1 -1
- package/test-utils/selectors/code-editor/index.js.map +1 -1
- package/test-utils/selectors/collection-preferences/index.d.ts +1 -0
- package/test-utils/selectors/collection-preferences/index.js +3 -0
- package/test-utils/selectors/collection-preferences/index.js.map +1 -1
- package/test-utils/selectors/collection-preferences/page-size-preference.js.map +1 -1
- package/test-utils/selectors/collection-preferences/visible-content-preference.js.map +1 -1
- package/test-utils/selectors/container/index.js.map +1 -1
- package/test-utils/selectors/content-layout/index.js.map +1 -1
- package/test-utils/selectors/date-picker/index.js +2 -2
- package/test-utils/selectors/date-picker/index.js.map +1 -1
- package/test-utils/selectors/date-range-picker/index.js +6 -3
- package/test-utils/selectors/date-range-picker/index.js.map +1 -1
- package/test-utils/selectors/expandable-section/index.js.map +1 -1
- package/test-utils/selectors/flashbar/flash.js.map +1 -1
- package/test-utils/selectors/flashbar/index.js.map +1 -1
- package/test-utils/selectors/form/index.js.map +1 -1
- package/test-utils/selectors/form-field/index.js.map +1 -1
- package/test-utils/selectors/grid/index.js.map +1 -1
- package/test-utils/selectors/header/index.js.map +1 -1
- package/test-utils/selectors/help-panel/index.js.map +1 -1
- package/test-utils/selectors/hotspot/index.js.map +1 -1
- package/test-utils/selectors/input/base-input.js.map +1 -1
- package/test-utils/selectors/input/index.js.map +1 -1
- package/test-utils/selectors/internal/abstract-switch.js.map +1 -1
- package/test-utils/selectors/internal/autosuggest-input.js.map +1 -1
- package/test-utils/selectors/internal/chart-filter.js.map +1 -1
- package/test-utils/selectors/internal/chart-legend.js.map +1 -1
- package/test-utils/selectors/internal/chart-popover.js.map +1 -1
- package/test-utils/selectors/internal/charts.js.map +1 -1
- package/test-utils/selectors/internal/dropdown-host.js.map +1 -1
- package/test-utils/selectors/internal/dropdown.js.map +1 -1
- package/test-utils/selectors/internal/filtering-token.js.map +1 -1
- package/test-utils/selectors/internal/option.js.map +1 -1
- package/test-utils/selectors/mixed-line-bar-chart/index.js.map +1 -1
- package/test-utils/selectors/modal/index.js.map +1 -1
- package/test-utils/selectors/multiselect/index.js.map +1 -1
- package/test-utils/selectors/pagination/index.js.map +1 -1
- package/test-utils/selectors/pie-chart/index.js.map +1 -1
- package/test-utils/selectors/popover/index.js.map +1 -1
- package/test-utils/selectors/progress-bar/index.js.map +1 -1
- package/test-utils/selectors/property-filter/index.js.map +1 -1
- package/test-utils/selectors/radio-group/index.js.map +1 -1
- package/test-utils/selectors/radio-group/radio-button.js.map +1 -1
- package/test-utils/selectors/s3-resource-selector/index.js.map +1 -1
- package/test-utils/selectors/segmented-control/index.js.map +1 -1
- package/test-utils/selectors/select/index.js.map +1 -1
- package/test-utils/selectors/side-navigation/index.js.map +1 -1
- package/test-utils/selectors/split-panel/index.js.map +1 -1
- package/test-utils/selectors/table/index.js +2 -1
- package/test-utils/selectors/table/index.js.map +1 -1
- package/test-utils/selectors/tabs/index.js.map +1 -1
- package/test-utils/selectors/tag-editor/index.js.map +1 -1
- package/test-utils/selectors/text-filter/index.js.map +1 -1
- package/test-utils/selectors/textarea/index.js.map +1 -1
- package/test-utils/selectors/tiles/index.js.map +1 -1
- package/test-utils/selectors/tiles/tile.js.map +1 -1
- package/test-utils/selectors/toggle/index.js.map +1 -1
- package/test-utils/selectors/token-group/index.js.map +1 -1
- package/test-utils/selectors/token-group/token.js.map +1 -1
- package/test-utils/selectors/top-navigation/1.0-beta/index.js.map +1 -1
- package/test-utils/selectors/top-navigation/index.js.map +1 -1
- package/test-utils/selectors/tutorial-panel/index.js.map +1 -1
- package/test-utils/selectors/tutorial-panel/tutorial.js.map +1 -1
- package/test-utils/selectors/wizard/index.js.map +1 -1
- package/test-utils/tsconfig.tsbuildinfo +1 -1
- package/theming/index.d.ts +1 -1
- package/theming/index.d.ts.map +1 -1
- package/token-group/internal.d.ts +1 -1
- package/token-group/internal.d.ts.map +1 -1
- package/top-navigation/1.0-beta/internal.d.ts +1 -1
- package/top-navigation/1.0-beta/internal.d.ts.map +1 -1
- package/top-navigation/internal.d.ts +1 -1
- package/top-navigation/internal.d.ts.map +1 -1
- package/top-navigation/parts/overflow-menu/menu-item.d.ts +2 -2
- package/top-navigation/parts/overflow-menu/menu-item.d.ts.map +1 -1
- package/top-navigation/parts/overflow-menu/menu-item.js.map +1 -1
- package/top-navigation/parts/overflow-menu/router.d.ts +1 -1
- package/top-navigation/parts/overflow-menu/router.d.ts.map +1 -1
- package/wizard/styles.css.js +32 -32
- package/wizard/styles.scoped.css +61 -60
- package/wizard/styles.selectors.js +32 -32
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.js","sourceRoot":"","sources":["../../../src/attribute-editor/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,mBAAmB,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC3D,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAG1D,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAGpD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5B,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAC9E,OAAO,WAAW,MAAM,iBAAiB,CAAC;AAE1C,OAAO,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAKhE,IAAM,uBAAuB,GAAG,KAAK,CAAC,UAAU,CAC9C,UACE,EAckC,EAClC,GAAwC;IAdtC,IAAA,cAAc,oBAAA,EACd,gBAAgB,sBAAA,EAChB,UAAU,gBAAA,EACV,KAAK,WAAA,EACL,uBAA4B,EAA5B,eAAe,mBAAG,cAAM,OAAA,IAAI,EAAJ,CAAI,KAAA,EAC5B,KAAK,WAAA,EACL,aAAa,mBAAA,EACb,gBAAgB,sBAAA,EAChB,WAAW,iBAAA,EACX,gBAAgB,sBAAA,EAChB,mBAAmB,yBAAA,EACnB,yBAAwB,EAAxB,iBAAiB,mBAAG,IAAI,KAAA,EACrB,KAAK,cAbV,6MAcC,CADS;IAIJ,IAAA,KAA8B,uBAAuB,CAAC,CAAC,SAAS,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC,EAA9E,UAAU,QAAA,EAAE,aAAa,QAAqD,CAAC;IACtF,IAAM,gB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BAAgB,CAAC,OAAO,EAC1C,mBAAmB,EAAE,mBAAmB,GACxC,CACH,EAb2B,CAa3B,CAAC,CACU;QACd,oBAAC,cAAc,IACb,SAAS,EAAE,MAAM,CAAC,YAAY,CAAC,EAC/B,QAAQ,EAAE,gBAAgB,EAC1B,OAAO,EAAE,gBAAgB,EACzB,UAAU,EAAC,MAAM,IAEhB,aAAa,CACC;QAChB,cAAc,IAAI,oBAAC,cAAc,QAAE,cAAc,CAAkB,CAChE,CACP,CAAC;AACJ,CAAC,CAC+B,CAAC;AAEnC,eAAe,uBAAuB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useImperativeHandle, useRef } from 'react';\nimport clsx from 'clsx';\n\nimport { getBaseProps } from '../internal/base-component';\n\nimport { ButtonProps } from '../button/interfaces';\nimport { InternalButton } from '../button/internal';\n\nimport { AttributeEditorForwardRefType, AttributeEditorProps } from './interfaces';\nimport { AdditionalInfo } from './additional-info';\nimport { Row } from './row';\n\nimport styles from './styles.css.js';\nimport { useContainerBreakpoints } from '../internal/hooks/container-queries';\nimport InternalBox from '../box/internal';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { useMergeRefs } from '../internal/hooks/use-merge-refs';\nimport { SomeRequired } from '../internal/types';\n\ntype InternalAttributeEditorProps<T> = SomeRequired<AttributeEditorProps<T>, 'items'> & InternalBaseComponentProps;\n\nconst InternalAttributeEditor = React.forwardRef(\n <T,>(\n {\n additionalInfo,\n disableAddButton,\n definition,\n items,\n isItemRemovable = () => true,\n empty,\n addButtonText,\n removeButtonText,\n i18nStrings,\n onAddButtonClick,\n onRemoveButtonClick,\n __internalRootRef = null,\n ...props\n }: InternalAttributeEditorProps<T>,\n ref: React.Ref<AttributeEditorProps.Ref>\n ) => {\n const [breakpoint, breakpointRef] = useContainerBreakpoints(['default', 'xxs', 'xs']);\n const removeButtonRefs = useRef<Array<ButtonProps.Ref | undefined>>([]);\n\n const baseProps = getBaseProps(props);\n const isEmpty = items && items.length === 0;\n\n useImperativeHandle(ref, () => ({\n focusRemoveButton(rowIndex: number) {\n removeButtonRefs.current[rowIndex]?.focus();\n },\n }));\n\n const mergedRef = useMergeRefs(breakpointRef, __internalRootRef);\n\n return (\n <div {...baseProps} ref={mergedRef} className={clsx(baseProps.className, styles.root)}>\n <InternalBox margin={{ bottom: 'l' }}>\n {isEmpty && <div className={styles.empty}>{empty}</div>}\n {items.map((item, index) => (\n <Row\n key={index}\n index={index}\n breakpoint={breakpoint}\n item={item}\n definition={definition}\n i18nStrings={i18nStrings}\n removable={isItemRemovable(item)}\n removeButtonText={removeButtonText}\n removeButtonRefs={removeButtonRefs.current}\n onRemoveButtonClick={onRemoveButtonClick}\n />\n ))}\n </InternalBox>\n <InternalButton\n className={styles['add-button']}\n disabled={disableAddButton}\n onClick={onAddButtonClick}\n formAction=\"none\"\n >\n {addButtonText}\n </InternalButton>\n {additionalInfo && <AdditionalInfo>{additionalInfo}</AdditionalInfo>}\n </div>\n );\n }\n) as AttributeEditorForwardRefType;\n\nexport default InternalAttributeEditor;\n"]}
|
|
@@ -118,7 +118,7 @@ export declare namespace AutosuggestProps {
|
|
|
118
118
|
select(): void;
|
|
119
119
|
}
|
|
120
120
|
}
|
|
121
|
-
export
|
|
121
|
+
export type AutosuggestItem = (AutosuggestProps.Option | AutosuggestProps.OptionGroup) & {
|
|
122
122
|
type?: 'parent' | 'child' | 'use-entered';
|
|
123
123
|
option: OptionDefinition | OptionGroup;
|
|
124
124
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/autosuggest/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,+BAA+B,EAAE,MAAM,wCAAwC,CAAC;AACzF,OAAO,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AAM,CAAC;KAC/C;IAED,UAAiB,GAAG;QAClB;;WAEG;QACH,KAAK,IAAI,IAAI,CAAC;QAEd;;WAEG;QACH,MAAM,IAAI,IAAI,CAAC;KAChB;CACF;AAGD,MAAM,MAAM,eAAe,GAAG,CAAC,gBAAgB,CAAC,MAAM,GAAG,gBAAgB,CAAC,WAAW,CAAC,GAAG;IACvF,IAAI,CAAC,EAAE,QAAQ,GAAG,OAAO,GAAG,aAAa,CAAC;IAC1C,MAAM,EAAE,gBAAgB,GAAG,WAAW,CAAC;CACxC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AutosuggestItem, AutosuggestProps } from './interfaces';
|
|
2
2
|
import { HighlightedOptionHandlers, HighlightedOptionState } from '../internal/components/options-list/utils/use-highlight-option';
|
|
3
|
-
|
|
3
|
+
type Options = AutosuggestProps.Options;
|
|
4
4
|
export interface UseAutosuggestItemsProps {
|
|
5
5
|
options: Options;
|
|
6
6
|
filterValue: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"options-controller.d.ts","sourceRoot":"","sources":["../../../src/autosuggest/options-controller.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AACjE,OAAO,EACL,yBAAyB,EACzB,sBAAsB,EAEvB,MAAM,gEAAgE,CAAC;AAExE,
|
|
1
|
+
{"version":3,"file":"options-controller.d.ts","sourceRoot":"","sources":["../../../src/autosuggest/options-controller.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AACjE,OAAO,EACL,yBAAyB,EACzB,sBAAsB,EAEvB,MAAM,gEAAgE,CAAC;AAExE,KAAK,OAAO,GAAG,gBAAgB,CAAC,OAAO,CAAC;AAExC,MAAM,WAAW,wBAAwB;IACvC,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,gBAAgB,CAAC,aAAa,CAAC;IAC9C,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,YAAY,EAAE,CAAC,MAAM,EAAE,eAAe,KAAK,IAAI,CAAC;CACjD;AAED,MAAM,WAAW,qBAAsB,SAAQ,sBAAsB,CAAC,eAAe,CAAC;IACpF,KAAK,EAAE,SAAS,eAAe,EAAE,CAAC;IAClC,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,WAAW,wBAAyB,SAAQ,yBAAyB,CAAC,eAAe,CAAC;IAC1F,UAAU,CAAC,KAAK,EAAE,OAAO,GAAG,IAAI,CAAC;IACjC,mCAAmC,IAAI,OAAO,CAAC;IAC/C,+BAA+B,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrD,4BAA4B,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;CACnD;AAOD,eAAO,MAAM,cAAc,SAAU,eAAe,gCAAwB,CAAC;AAI7E,eAAO,MAAM,mBAAmB,6FAO7B,wBAAwB,KAAG,CAAC,qBAAqB,EAAE,wBAAwB,CAiD7E,CAAC"}
|
|
@@ -13,7 +13,7 @@ export interface ListProps {
|
|
|
13
13
|
listBottom?: React.ReactNode;
|
|
14
14
|
screenReaderContent?: string;
|
|
15
15
|
}
|
|
16
|
-
export declare const getOptionProps: (index: number, item: AutosuggestItem, filteredItems: readonly AutosuggestItem[], highlightedA11yProps: ListProps['highlightedA11yProps'], highlightedOption?: AutosuggestItem
|
|
16
|
+
export declare const getOptionProps: (index: number, item: AutosuggestItem, filteredItems: readonly AutosuggestItem[], highlightedA11yProps: ListProps['highlightedA11yProps'], highlightedOption?: AutosuggestItem, hasDropdownStatus?: boolean) => {
|
|
17
17
|
className?: string | undefined;
|
|
18
18
|
id?: string | undefined;
|
|
19
19
|
nativeAttributes: Record<string, string | number | boolean>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plain-list.d.ts","sourceRoot":"","sources":["../../../src/autosuggest/plain-list.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAEjD,OAAoB,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AAKpF,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAE7D,MAAM,WAAW,SAAS;IACxB,qBAAqB,EAAE,qBAAqB,CAAC;IAC7C,SAAS,EAAE,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,CAAC;IAC9C,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,gBAAgB,EAAE,gBAAgB,CAAC,gBAAgB,CAAC;IACpD,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;IAChE,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,aAAa,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC7B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED,eAAO,MAAM,cAAc,UAClB,MAAM,QACP,eAAe,iBACN,SAAS,eAAe,EAAE,wBACnB,SAAS,CAAC,sBAAsB,CAAC;;;;;
|
|
1
|
+
{"version":3,"file":"plain-list.d.ts","sourceRoot":"","sources":["../../../src/autosuggest/plain-list.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAEjD,OAAoB,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AAKpF,OAAO,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAEjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAE7D,MAAM,WAAW,SAAS;IACxB,qBAAqB,EAAE,qBAAqB,CAAC;IAC7C,SAAS,EAAE,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,CAAC;IAC9C,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,gBAAgB,EAAE,gBAAgB,CAAC,gBAAgB,CAAC;IACpD,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;IAChE,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,aAAa,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC7B,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED,eAAO,MAAM,cAAc,UAClB,MAAM,QACP,eAAe,iBACN,SAAS,eAAe,EAAE,wBACnB,SAAS,CAAC,sBAAsB,CAAC,sBACnC,eAAe,sBACf,OAAO;;;;;CAS5B,CAAC;AAEF,QAAA,MAAM,SAAS,qKAUZ,SAAS,gBAmDX,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CartesianChartProps } from '../internal/components/cartesian-chart/interfaces';
|
|
2
2
|
import { ChartDataTypes, MixedLineBarChartProps } from '../mixed-line-bar-chart/interfaces';
|
|
3
|
-
|
|
3
|
+
type BarSeries<T> = MixedLineBarChartProps.BarDataSeries<T> | MixedLineBarChartProps.ThresholdSeries<T>;
|
|
4
4
|
export interface BarChartProps<T extends ChartDataTypes> extends CartesianChartProps<T, MixedLineBarChartProps.ChartSeries<T>> {
|
|
5
5
|
/**
|
|
6
6
|
* Array that represents the source of data for the displayed chart.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/bar-chart/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mDAAmD,CAAC;AACxF,OAAO,EAAE,cAAc,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAE5F,
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/bar-chart/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mDAAmD,CAAC;AACxF,OAAO,EAAE,cAAc,EAAE,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAE5F,KAAK,SAAS,CAAC,CAAC,IAAI,sBAAsB,CAAC,aAAa,CAAC,CAAC,CAAC,GAAG,sBAAsB,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC;AAExG,MAAM,WAAW,aAAa,CAAC,CAAC,SAAS,cAAc,CACrD,SAAQ,mBAAmB,CAAC,CAAC,EAAE,sBAAsB,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;IACrE;;;;;;;;;OASG;IACH,MAAM,EAAE,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;IAEpC;;OAEG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAEtB;;;OAGG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IAEzB;;;OAGG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC;AAGD,yBAAiB,aAAa,CAAC,GAAE"}
|
package/box/internal.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BoxProps } from './interfaces';
|
|
2
2
|
import { InternalBaseComponentProps } from '../internal/hooks/use-base-component';
|
|
3
|
-
|
|
3
|
+
type InternalBoxProps = BoxProps & InternalBaseComponentProps;
|
|
4
4
|
export default function InternalBox({ variant, tagOverride, margin, padding, display, textAlign, float, fontSize, fontWeight, color, children, __internalRootRef, ...props }: InternalBoxProps): JSX.Element;
|
|
5
5
|
export {};
|
|
6
6
|
//# sourceMappingURL=internal.d.ts.map
|
package/box/internal.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/box/internal.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAElF,
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/box/internal.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAElF,KAAK,gBAAgB,GAAG,QAAQ,GAAG,0BAA0B,CAAC;AAE9D,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,OAAe,EACf,WAAW,EACX,MAAW,EACX,OAAY,EACZ,OAAO,EACP,SAAS,EACT,KAAK,EACL,QAAQ,EACR,UAAU,EACV,KAAK,EACL,QAAQ,EACR,iBAAwB,EACxB,GAAG,KAAK,EACT,EAAE,gBAAgB,eA4BlB"}
|
|
@@ -6,7 +6,7 @@ export declare const getEventDetail: <T extends BreadcrumbGroupProps.Item>(item:
|
|
|
6
6
|
text: string;
|
|
7
7
|
href: string;
|
|
8
8
|
};
|
|
9
|
-
|
|
9
|
+
type InternalBreadcrumbGroupProps<T extends BreadcrumbGroupProps.Item = BreadcrumbGroupProps.Item> = SomeRequired<BreadcrumbGroupProps<T>, 'expandAriaLabel'> & InternalBaseComponentProps;
|
|
10
10
|
export default function InternalBreadcrumbGroup<T extends BreadcrumbGroupProps.Item = BreadcrumbGroupProps.Item>({ items, ariaLabel, expandAriaLabel, onClick, onFollow, __internalRootRef, ...props }: InternalBreadcrumbGroupProps<T>): JSX.Element;
|
|
11
11
|
export {};
|
|
12
12
|
//# sourceMappingURL=internal.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/breadcrumb-group/internal.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,oBAAoB,EAAyB,MAAM,cAAc,CAAC;AAI3E,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAElF,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAkDpD,eAAO,MAAM,cAAc;;;;CAIzB,CAAC;AAEH,
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/breadcrumb-group/internal.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAE,oBAAoB,EAAyB,MAAM,cAAc,CAAC;AAI3E,OAAO,EAAE,0BAA0B,EAAE,MAAM,sCAAsC,CAAC;AAElF,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAkDpD,eAAO,MAAM,cAAc;;;;CAIzB,CAAC;AAEH,KAAK,4BAA4B,CAAC,CAAC,SAAS,oBAAoB,CAAC,IAAI,GAAG,oBAAoB,CAAC,IAAI,IAAI,YAAY,CAC/G,oBAAoB,CAAC,CAAC,CAAC,EACvB,iBAAiB,CAClB,GACC,0BAA0B,CAAC;AAE7B,MAAM,CAAC,OAAO,UAAU,uBAAuB,CAAC,CAAC,SAAS,oBAAoB,CAAC,IAAI,GAAG,oBAAoB,CAAC,IAAI,EAAE,EAC/G,KAAU,EACV,SAAS,EACT,eAAe,EACf,OAAO,EACP,QAAQ,EACR,iBAAiB,EACjB,GAAG,KAAK,EACT,EAAE,4BAA4B,CAAC,CAAC,CAAC,eA4DjC"}
|
|
@@ -137,8 +137,8 @@ export interface HighlightProps {
|
|
|
137
137
|
isExpanded: (group: ButtonDropdownProps.ItemGroup) => boolean;
|
|
138
138
|
highlightItem: (item: ButtonDropdownProps.ItemOrGroup) => void;
|
|
139
139
|
}
|
|
140
|
-
export
|
|
141
|
-
export
|
|
140
|
+
export type GroupToggle = (item: ButtonDropdownProps.ItemGroup, event: React.SyntheticEvent) => void;
|
|
141
|
+
export type ItemActivate = (item: ButtonDropdownProps.Item, event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
142
142
|
export interface CategoryProps extends HighlightProps {
|
|
143
143
|
item: ButtonDropdownProps.ItemGroup;
|
|
144
144
|
onGroupToggle: GroupToggle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C;CAClD;AAED,MAAM,WAAW,QAAS,SAAQ,mBAAmB,CAAC,IAAI;IACxD,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,mBAAmB,CAAC,IAAI,GAAG,QAAQ,CAAC;IAC1C,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,OAAO,CAAC;IACrB,cAAc,EAAE,YAAY,CAAC;IAC7B,aAAa,EAAE,CAAC,IAAI,EAAE,mBAAmB,CAAC,WAAW,KAAK,IAAI,CAAC;IAC/D,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd,iBAAiB,EAAE,OAAO,CAAC;IAC3B,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,OAAO,CAAC,EAAE,aAAa,CAAC,SAAS,CAAC,CAAC;CACpC;AAED,MAAM,WAAW,2BAA4B,SAAQ,IAAI,CAAC,mBAAmB,EAAE,SAAS,CAAC,EAAE,0BAA0B;IACnH,oBAAoB,CAAC,EAAE,CACrB,YAAY,EAAE,MAAM,IAAI,EACxB,GAAG,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,EACnB,UAAU,EAAE,OAAO,EACnB,UAAU,EAAE,OAAO,EACnB,SAAS,CAAC,EAAE,MAAM,KACf,KAAK,CAAC,SAAS,CAAC;IACrB,OAAO,CAAC,EAAE,mBAAmB,CAAC,SAAS,CAAC,GAAG,YAAY,CAAC;IAExD;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ButtonDropdownProps } from '../interfaces';
|
|
2
|
-
export
|
|
2
|
+
export type TreeIndex = number[];
|
|
3
3
|
interface ItemsTreeApi {
|
|
4
4
|
getItem: (index: TreeIndex) => ButtonDropdownProps.ItemOrGroup | null;
|
|
5
5
|
getItemIndex: (item: ButtonDropdownProps.ItemOrGroup) => TreeIndex;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-items-tree.d.ts","sourceRoot":"","sources":["../../../../src/button-dropdown/utils/create-items-tree.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAMpD,
|
|
1
|
+
{"version":3,"file":"create-items-tree.d.ts","sourceRoot":"","sources":["../../../../src/button-dropdown/utils/create-items-tree.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAMpD,MAAM,MAAM,SAAS,GAAG,MAAM,EAAE,CAAC;AAEjC,UAAU,YAAY;IAEpB,OAAO,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,mBAAmB,CAAC,WAAW,GAAG,IAAI,CAAC;IAGtE,YAAY,EAAE,CAAC,IAAI,EAAE,mBAAmB,CAAC,WAAW,KAAK,SAAS,CAAC;IAEnE,kBAAkB,EAAE,CAAC,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC,CAAC,GAAG,CAAC,KAAK,SAAS,GAAG,IAAI,CAAC;IAE9E,cAAc,EAAE,CAAC,IAAI,EAAE,mBAAmB,CAAC,WAAW,KAAK,SAAS,GAAG,IAAI,CAAC;CAC7E;AAED,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,KAAK,EAAE,mBAAmB,CAAC,KAAK,GAAG,YAAY,CAwDtF"}
|
package/calendar/internal.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CalendarProps } from './interfaces.js';
|
|
2
2
|
import { InternalBaseComponentProps } from '../internal/hooks/use-base-component/index.js';
|
|
3
|
-
export
|
|
3
|
+
export type DayIndex = 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
4
4
|
export default function Calendar({ value, locale, startOfWeek, isDateEnabled, ariaLabel, ariaLabelledby, ariaDescribedby, todayAriaLabel, nextMonthAriaLabel, previousMonthAriaLabel, onChange, __internalRootRef, ...rest }: CalendarProps & InternalBaseComponentProps): JSX.Element;
|
|
5
5
|
//# sourceMappingURL=internal.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/calendar/internal.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,0BAA0B,EAAE,MAAM,+CAA+C,CAAC;AAK3F,
|
|
1
|
+
{"version":3,"file":"internal.d.ts","sourceRoot":"","sources":["../../../src/calendar/internal.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,0BAA0B,EAAE,MAAM,+CAA+C,CAAC;AAK3F,MAAM,MAAM,QAAQ,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AAEjD,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,EAC/B,KAAK,EACL,MAAW,EACX,WAAW,EACX,aAA0B,EAC1B,SAAS,EACT,cAAc,EACd,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,sBAAsB,EACtB,QAAQ,EACR,iBAAiB,EACjB,GAAG,IAAI,EACR,EAAE,aAAa,GAAG,0BAA0B,eA4G5C"}
|
|
@@ -94,10 +94,10 @@ export interface CodeEditorProps extends BaseComponentProps, FormFieldControlPro
|
|
|
94
94
|
*/
|
|
95
95
|
onEditorContentResize?: NonCancelableEventHandler<CodeEditorProps.ResizeDetail>;
|
|
96
96
|
}
|
|
97
|
-
|
|
97
|
+
type LiteralUnion<LiteralType, BaseType extends string> = LiteralType | (BaseType & {
|
|
98
98
|
_?: never;
|
|
99
99
|
});
|
|
100
|
-
|
|
100
|
+
type BuiltInLanguage = typeof AceModes[number]['value'];
|
|
101
101
|
export declare namespace CodeEditorProps {
|
|
102
102
|
type Language = LiteralUnion<BuiltInLanguage, string>;
|
|
103
103
|
type Theme = typeof LightThemes[number]['value'] | typeof DarkThemes[number]['value'];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/code-editor/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EAAE,qBAAqB,EAAE,MAAM,wCAAwC,CAAC;AAE/E,MAAM,WAAW,eAAgB,SAAQ,kBAAkB,EAAE,qBAAqB;IAChF;;OAEG;IACH,GAAG,EAAE,GAAG,CAAC;IAET;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;;;OAIG;IACH,QAAQ,EAAE,eAAe,CAAC,QAAQ,CAAC;IAEnC;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,yBAAyB,CAAC,eAAe,CAAC,YAAY,CAAC,CAAC;IAEnE;;;;OAIG;IACH,eAAe,CAAC,EAAE,yBAAyB,CAAC,eAAe,CAAC,YAAY,CAAC,CAAC;IAE1E;;OAEG;IACH,UAAU,CAAC,EAAE,yBAAyB,CAAC,eAAe,CAAC,cAAc,CAAC,CAAC;IAEvE;;;;;;;;;;;;;OAaG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,WAAW,CAAC,CAAC;IAEnD;;;OAGG;IACH,MAAM,CAAC,EAAE,eAAe,CAAC,eAAe,CAAC;IAEzC;;;;OAIG;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B,SAAS,EAAE,OAAO,CAAC;QACnB,KAAK,EAAE,KAAK,CAAC;KACd;IAED,UAAiB,WAAW;QAC1B,YAAY,EAAE,MAAM,CAAC;QACrB,UAAU,EAAE,MAAM,CAAC;QACnB,kBAAkB,EAAE,MAAM,CAAC;QAE3B,oBAAoB,EAAE,MAAM,CAAC;QAC7B,uBAAuB,EAAE,MAAM,CAAC;QAEhC,cAAc,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,KAAK,MAAM,CAAC;QACxD,SAAS,EAAE,MAAM,CAAC;QAClB,WAAW,EAAE,MAAM,CAAC;QACpB,0BAA0B,EAAE,MAAM,CAAC;QACnC,wBAAwB,EAAE,MAAM,CAAC;QAEjC,sBAAsB,EAAE,MAAM,CAAC;QAC/B,sBAAsB,EAAE,MAAM,CAAC;QAC/B,uBAAuB,EAAE,MAAM,CAAC;QAChC,yBAAyB,EAAE,MAAM,CAAC;QAClC,qBAAqB,EAAE,MAAM,CAAC;QAC9B,2BAA2B,EAAE,MAAM,CAAC;QACpC,0BAA0B,EAAE,MAAM,CAAC;KACpC;IACD,UAAiB,YAAY;QAC3B,MAAM,EAAE,MAAM,CAAC;KAChB;IACD,UAAiB,YAAY;QAC3B,KAAK,EAAE,MAAM,CAAC;KACf;IAED,UAAiB,cAAc;QAC7B,WAAW,EAAE,GAAG,CAAC,UAAU,EAAE,CAAC;KAC/B;CACF"}
|
package/code-editor/util.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Ace } from 'ace-builds';
|
|
2
2
|
import { LightThemes, DarkThemes } from './ace-themes';
|
|
3
3
|
import { CodeEditorProps } from './interfaces';
|
|
4
|
-
export
|
|
4
|
+
export type PaneStatus = 'error' | 'warning' | 'hidden';
|
|
5
5
|
export declare const DEFAULT_LIGHT_THEME: typeof LightThemes[number]['value'];
|
|
6
6
|
export declare const DEFAULT_DARK_THEME: typeof DarkThemes[number]['value'];
|
|
7
7
|
export declare function getDefaultConfig(): Partial<Ace.EditorOptions>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../src/code-editor/util.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAGjC,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAG/C,
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../src/code-editor/util.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAGjC,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAG/C,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,CAAC;AAExD,eAAO,MAAM,mBAAmB,EAAE,OAAO,WAAW,CAAC,MAAM,CAAC,CAAC,OAAO,CAAU,CAAC;AAC/E,eAAO,MAAM,kBAAkB,EAAE,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC,OAAO,CAA2B,CAAC;AAE9F,wBAAgB,gBAAgB,IAAI,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,CAI7D;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,WAAW,GAAG,eAAe,CAAC,KAAK,CAM3E;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,eAAe,CAAC,KAAK,UAEvD;AAED,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,eAAe,CAAC,QAAQ,GAAG,MAAM,CAE3E"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { CollectionPreferencesProps } from './interfaces';
|
|
2
2
|
export { CollectionPreferencesProps };
|
|
3
|
-
export default function CollectionPreferences({ title, confirmLabel, cancelLabel, disabled, onConfirm, onCancel, visibleContentPreference, pageSizePreference, wrapLinesPreference, preferences, customPreference, ...rest }: CollectionPreferencesProps): JSX.Element;
|
|
3
|
+
export default function CollectionPreferences({ title, confirmLabel, cancelLabel, disabled, onConfirm, onCancel, visibleContentPreference, pageSizePreference, wrapLinesPreference, stripedRowsPreference, preferences, customPreference, ...rest }: CollectionPreferencesProps): JSX.Element;
|
|
4
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/collection-preferences/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/collection-preferences/index.tsx"],"names":[],"mappings":"AAsBA,OAAO,EAAE,0BAA0B,EAAE,MAAM,cAAc,CAAC;AAK1D,OAAO,EAAE,0BAA0B,EAAE,CAAC;AAuFtC,MAAM,CAAC,OAAO,UAAU,qBAAqB,CAAC,EAC5C,KAAK,EACL,YAAY,EACZ,WAAW,EACX,QAAgB,EAChB,SAAS,EACT,QAAQ,EACR,wBAAwB,EACxB,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,WAAW,EACX,gBAAgB,EAChB,GAAG,IAAI,EACR,EAAE,0BAA0B,eAwF5B"}
|
|
@@ -9,24 +9,29 @@ import InternalBox from '../box/internal';
|
|
|
9
9
|
import { InternalButton } from '../button/internal';
|
|
10
10
|
import InternalModal from '../modal/internal';
|
|
11
11
|
import InternalSpaceBetween from '../space-between/internal';
|
|
12
|
-
import { copyPreferences, mergePreferences, ModalContentLayout, PageSizePreference, WrapLinesPreference, CustomPreference, } from './utils';
|
|
12
|
+
import { copyPreferences, mergePreferences, ModalContentLayout, PageSizePreference, WrapLinesPreference, StripedRowsPreference, CustomPreference, } from './utils';
|
|
13
13
|
import VisibleContentPreference from './visible-content';
|
|
14
14
|
import checkControlled from '../internal/hooks/check-controlled';
|
|
15
15
|
import styles from './styles.css.js';
|
|
16
16
|
import { applyDisplayName } from '../internal/utils/apply-display-name';
|
|
17
17
|
import useBaseComponent from '../internal/hooks/use-base-component';
|
|
18
18
|
var ModalContent = function (_a) {
|
|
19
|
-
var _b = _a.preferences, preferences = _b === void 0 ? {} : _b, pageSizePreference = _a.pageSizePreference, wrapLinesPreference = _a.wrapLinesPreference, customPreference = _a.customPreference, visibleContentPreference = _a.visibleContentPreference, onChange = _a.onChange;
|
|
20
|
-
if (!visibleContentPreference &&
|
|
19
|
+
var _b = _a.preferences, preferences = _b === void 0 ? {} : _b, pageSizePreference = _a.pageSizePreference, wrapLinesPreference = _a.wrapLinesPreference, stripedRowsPreference = _a.stripedRowsPreference, customPreference = _a.customPreference, visibleContentPreference = _a.visibleContentPreference, onChange = _a.onChange;
|
|
20
|
+
if (!visibleContentPreference &&
|
|
21
|
+
!pageSizePreference &&
|
|
22
|
+
!wrapLinesPreference &&
|
|
23
|
+
!stripedRowsPreference &&
|
|
24
|
+
customPreference) {
|
|
21
25
|
return (React.createElement(CustomPreference, { value: preferences.custom, customPreference: customPreference, onChange: function (custom) { return onChange({ custom: custom }); } }));
|
|
22
26
|
}
|
|
23
27
|
return (React.createElement(ModalContentLayout, { left: React.createElement(InternalSpaceBetween, { size: "l" },
|
|
24
28
|
pageSizePreference && (React.createElement(PageSizePreference, __assign({ value: preferences.pageSize }, pageSizePreference, { onChange: function (pageSize) { return onChange({ pageSize: pageSize }); } }))),
|
|
25
29
|
wrapLinesPreference && (React.createElement(WrapLinesPreference, __assign({ value: preferences.wrapLines }, wrapLinesPreference, { onChange: function (wrapLines) { return onChange({ wrapLines: wrapLines }); } }))),
|
|
30
|
+
stripedRowsPreference && (React.createElement(StripedRowsPreference, __assign({ value: preferences.stripedRows }, stripedRowsPreference, { onChange: function (stripedRows) { return onChange({ stripedRows: stripedRows }); } }))),
|
|
26
31
|
customPreference && (React.createElement(CustomPreference, { value: preferences.custom, customPreference: customPreference, onChange: function (custom) { return onChange({ custom: custom }); } }))), right: visibleContentPreference && (React.createElement(VisibleContentPreference, __assign({ value: preferences.visibleContent }, visibleContentPreference, { onChange: function (visibleContent) { return onChange({ visibleContent: visibleContent }); } }))) }));
|
|
27
32
|
};
|
|
28
33
|
export default function CollectionPreferences(_a) {
|
|
29
|
-
var title = _a.title, confirmLabel = _a.confirmLabel, cancelLabel = _a.cancelLabel, _b = _a.disabled, disabled = _b === void 0 ? false : _b, onConfirm = _a.onConfirm, onCancel = _a.onCancel, visibleContentPreference = _a.visibleContentPreference, pageSizePreference = _a.pageSizePreference, wrapLinesPreference = _a.wrapLinesPreference, preferences = _a.preferences, customPreference = _a.customPreference, rest = __rest(_a, ["title", "confirmLabel", "cancelLabel", "disabled", "onConfirm", "onCancel", "visibleContentPreference", "pageSizePreference", "wrapLinesPreference", "preferences", "customPreference"]);
|
|
34
|
+
var title = _a.title, confirmLabel = _a.confirmLabel, cancelLabel = _a.cancelLabel, _b = _a.disabled, disabled = _b === void 0 ? false : _b, onConfirm = _a.onConfirm, onCancel = _a.onCancel, visibleContentPreference = _a.visibleContentPreference, pageSizePreference = _a.pageSizePreference, wrapLinesPreference = _a.wrapLinesPreference, stripedRowsPreference = _a.stripedRowsPreference, preferences = _a.preferences, customPreference = _a.customPreference, rest = __rest(_a, ["title", "confirmLabel", "cancelLabel", "disabled", "onConfirm", "onCancel", "visibleContentPreference", "pageSizePreference", "wrapLinesPreference", "stripedRowsPreference", "preferences", "customPreference"]);
|
|
30
35
|
var __internalRootRef = useBaseComponent('CollectionPreferences').__internalRootRef;
|
|
31
36
|
checkControlled('CollectioPreferences', 'preferences', preferences, 'onConfirm', onConfirm);
|
|
32
37
|
var baseProps = getBaseProps(rest);
|
|
@@ -60,7 +65,7 @@ export default function CollectionPreferences(_a) {
|
|
|
60
65
|
React.createElement(InternalSpaceBetween, { direction: "horizontal", size: "xs" },
|
|
61
66
|
React.createElement(InternalButton, { className: styles['cancel-button'], variant: "link", formAction: "none", onClick: onCancelListener }, cancelLabel),
|
|
62
67
|
React.createElement(InternalButton, { className: styles['confirm-button'], variant: "primary", formAction: "none", onClick: onConfirmListener }, confirmLabel))), closeAriaLabel: cancelLabel, size: "large", onDismiss: onCancelListener },
|
|
63
|
-
React.createElement(ModalContent, { preferences: temporaryPreferences, visibleContentPreference: visibleContentPreference, pageSizePreference: pageSizePreference, wrapLinesPreference: wrapLinesPreference, customPreference: customPreference, onChange: function (changedPreferences) {
|
|
68
|
+
React.createElement(ModalContent, { preferences: temporaryPreferences, visibleContentPreference: visibleContentPreference, pageSizePreference: pageSizePreference, wrapLinesPreference: wrapLinesPreference, stripedRowsPreference: stripedRowsPreference, customPreference: customPreference, onChange: function (changedPreferences) {
|
|
64
69
|
return setTemporaryPreferences(mergePreferences(changedPreferences, temporaryPreferences));
|
|
65
70
|
} })))));
|
|
66
71
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/collection-preferences/index.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC3D,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,WAAW,MAAM,iBAAiB,CAAC;AAE1C,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,aAAa,MAAM,mBAAmB,CAAC;AAC9C,OAAO,oBAAoB,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EACL,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,GACjB,MAAM,SAAS,CAAC;AACjB,OAAO,wBAAwB,MAAM,mBAAmB,CAAC;AACzD,OAAO,eAAe,MAAM,oCAAoC,CAAC;AAEjE,OAAO,MAAM,M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,EACJ,oBAAC,WAAW,IAAC,KAAK,EAAC,OAAO;gBACxB,oBAAC,oBAAoB,IAAC,SAAS,EAAC,YAAY,EAAC,IAAI,EAAC,IAAI;oBACpD,oBAAC,cAAc,IACb,SAAS,EAAE,MAAM,CAAC,eAAe,CAAC,EAClC,OAAO,EAAC,MAAM,EACd,UAAU,EAAC,MAAM,EACjB,OAAO,EAAE,gBAAgB,IAExB,WAAW,CACG;oBACjB,oBAAC,cAAc,IACb,SAAS,EAAE,MAAM,CAAC,gBAAgB,CAAC,EACnC,OAAO,EAAC,SAAS,EACjB,UAAU,EAAC,MAAM,EACjB,OAAO,EAAE,iBAAiB,IAEzB,YAAY,CACE,CACI,CACX,EAEhB,cAAc,EAAE,WAAW,EAC3B,IAAI,EAAC,OAAO,EACZ,SAAS,EAAE,gBAAgB;YAE3B,oBAAC,YAAY,IACX,WAAW,EAAE,oBAAoB,EACjC,wBAAwB,EAAE,wBAAwB,EAClD,kBAAkB,EAAE,kBAAkB,EACtC,mBAAmB,EAAE,mBAAmB,EACxC,gBAAgB,EAAE,gBAAgB,EAClC,QAAQ,EAAE,UAAA,kBAAkB;oBAC1B,OAAA,uBAAuB,CAAC,gBAAgB,CAAC,kBAAkB,EAAE,oBAAoB,CAAC,CAAC;gBAAnF,CAAmF,GAErF,CACY,CACjB,CACG,CACP,CAAC;AACJ,CAAC;AAED,gBAAgB,CAAC,qBAAqB,EAAE,uBAAuB,CAAC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useEffect, useRef, useState } from 'react';\nimport clsx from 'clsx';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { getBaseProps } from '../internal/base-component';\nimport InternalBox from '../box/internal';\nimport { ButtonProps } from '../button/interfaces';\nimport { InternalButton } from '../button/internal';\nimport InternalModal from '../modal/internal';\nimport InternalSpaceBetween from '../space-between/internal';\nimport {\n copyPreferences,\n mergePreferences,\n ModalContentLayout,\n PageSizePreference,\n WrapLinesPreference,\n CustomPreference,\n} from './utils';\nimport VisibleContentPreference from './visible-content';\nimport checkControlled from '../internal/hooks/check-controlled';\nimport { CollectionPreferencesProps } from './interfaces';\nimport styles from './styles.css.js';\nimport { applyDisplayName } from '../internal/utils/apply-display-name';\nimport useBaseComponent from '../internal/hooks/use-base-component';\n\nexport { CollectionPreferencesProps };\n\ninterface ModalContentProps\n extends Pick<\n CollectionPreferencesProps,\n 'preferences' | 'visibleContentPreference' | 'pageSizePreference' | 'wrapLinesPreference' | 'customPreference'\n > {\n onChange: (preferences: CollectionPreferencesProps.Preferences) => void;\n}\n\nconst ModalContent = ({\n preferences = {},\n pageSizePreference,\n wrapLinesPreference,\n customPreference,\n visibleContentPreference,\n onChange,\n}: ModalContentProps) => {\n if (!visibleContentPreference && !pageSizePreference && !wrapLinesPreference && customPreference) {\n return (\n <CustomPreference\n value={preferences.custom}\n customPreference={customPreference}\n onChange={custom => onChange({ custom })}\n />\n );\n }\n return (\n <ModalContentLayout\n left={\n <InternalSpaceBetween size=\"l\">\n {pageSizePreference && (\n <PageSizePreference\n value={preferences.pageSize}\n {...pageSizePreference}\n onChange={pageSize => onChange({ pageSize })}\n />\n )}\n {wrapLinesPreference && (\n <WrapLinesPreference\n value={preferences.wrapLines}\n {...wrapLinesPreference}\n onChange={wrapLines => onChange({ wrapLines })}\n />\n )}\n {customPreference && (\n <CustomPreference\n value={preferences.custom}\n customPreference={customPreference}\n onChange={custom => onChange({ custom })}\n />\n )}\n </InternalSpaceBetween>\n }\n right={\n visibleContentPreference && (\n <VisibleContentPreference\n value={preferences.visibleContent}\n {...visibleContentPreference}\n onChange={visibleContent => onChange({ visibleContent })}\n />\n )\n }\n />\n );\n};\n\nexport default function CollectionPreferences({\n title,\n confirmLabel,\n cancelLabel,\n disabled = false,\n onConfirm,\n onCancel,\n visibleContentPreference,\n pageSizePreference,\n wrapLinesPreference,\n preferences,\n customPreference,\n ...rest\n}: CollectionPreferencesProps) {\n const { __internalRootRef } = useBaseComponent('CollectionPreferences');\n checkControlled('CollectioPreferences', 'preferences', preferences, 'onConfirm', onConfirm);\n const baseProps = getBaseProps(rest);\n const [modalVisible, setModalVisible] = useState(false);\n const [temporaryPreferences, setTemporaryPreferences] = useState(copyPreferences(preferences || {}));\n const triggerRef = useRef<ButtonProps.Ref>(null);\n const dialogPreviouslyOpen = useRef(false);\n useEffect(() => {\n if (!modalVisible) {\n dialogPreviouslyOpen.current && triggerRef.current && triggerRef.current.focus();\n } else {\n dialogPreviouslyOpen.current = true;\n }\n }, [modalVisible]);\n\n const onConfirmListener = () => {\n setModalVisible(false);\n fireNonCancelableEvent(onConfirm, temporaryPreferences);\n };\n\n const onCancelListener = () => {\n fireNonCancelableEvent(onCancel, {});\n setModalVisible(false);\n setTemporaryPreferences(copyPreferences(preferences || {}));\n };\n\n return (\n <div {...baseProps} className={clsx(baseProps.className, styles.root)} ref={__internalRootRef}>\n <InternalButton\n ref={triggerRef}\n className={styles['trigger-button']}\n disabled={disabled}\n ariaLabel={title}\n onClick={() => {\n setTemporaryPreferences(copyPreferences(preferences || {}));\n setModalVisible(true);\n }}\n variant=\"icon\"\n iconName=\"settings\"\n formAction=\"none\"\n />\n {!disabled && modalVisible && (\n <InternalModal\n className={styles['modal-root']}\n visible={true}\n header={title}\n footer={\n <InternalBox float=\"right\">\n <InternalSpaceBetween direction=\"horizontal\" size=\"xs\">\n <InternalButton\n className={styles['cancel-button']}\n variant=\"link\"\n formAction=\"none\"\n onClick={onCancelListener}\n >\n {cancelLabel}\n </InternalButton>\n <InternalButton\n className={styles['confirm-button']}\n variant=\"primary\"\n formAction=\"none\"\n onClick={onConfirmListener}\n >\n {confirmLabel}\n </InternalButton>\n </InternalSpaceBetween>\n </InternalBox>\n }\n closeAriaLabel={cancelLabel}\n size=\"large\"\n onDismiss={onCancelListener}\n >\n <ModalContent\n preferences={temporaryPreferences}\n visibleContentPreference={visibleContentPreference}\n pageSizePreference={pageSizePreference}\n wrapLinesPreference={wrapLinesPreference}\n customPreference={customPreference}\n onChange={changedPreferences =>\n setTemporaryPreferences(mergePreferences(changedPreferences, temporaryPreferences))\n }\n />\n </InternalModal>\n )}\n </div>\n );\n}\n\napplyDisplayName(CollectionPreferences, 'CollectionPreferences');\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/collection-preferences/index.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC3D,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,WAAW,MAAM,iBAAiB,CAAC;AAE1C,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,aAAa,MAAM,mBAAmB,CAAC;AAC9C,OAAO,oBAAoB,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EACL,eAAe,EACf,gBAAgB,EAChB,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,gBAAgB,GACjB,MAAM,SAAS,CAAC;AACjB,OAAO,wBAAwB,MAAM,mBAAmB,CAAC;AACzD,OAAO,eAAe,MAAM,oCAAoC,CAAC;AAEjE,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AACxE,OAAO,gBAAgB,MAAM,sCAAsC,CAAC;AAiBpE,IAAM,YAAY,GAAG,UAAC,EAQF;QAPlB,mBAAgB,EAAhB,WAAW,mBAAG,EAAE,KAAA,EAChB,kBAAkB,wBAAA,EAClB,mBAAmB,yBAAA,EACnB,qBAAqB,2BAAA,EACrB,gBAAgB,sBAAA,EAChB,wBAAwB,8BAAA,EACxB,QA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xB,oBAAC,oBAAoB,IAAC,SAAS,EAAC,YAAY,EAAC,IAAI,EAAC,IAAI;oBACpD,oBAAC,cAAc,IACb,SAAS,EAAE,MAAM,CAAC,eAAe,CAAC,EAClC,OAAO,EAAC,MAAM,EACd,UAAU,EAAC,MAAM,EACjB,OAAO,EAAE,gBAAgB,IAExB,WAAW,CACG;oBACjB,oBAAC,cAAc,IACb,SAAS,EAAE,MAAM,CAAC,gBAAgB,CAAC,EACnC,OAAO,EAAC,SAAS,EACjB,UAAU,EAAC,MAAM,EACjB,OAAO,EAAE,iBAAiB,IAEzB,YAAY,CACE,CACI,CACX,EAEhB,cAAc,EAAE,WAAW,EAC3B,IAAI,EAAC,OAAO,EACZ,SAAS,EAAE,gBAAgB;YAE3B,oBAAC,YAAY,IACX,WAAW,EAAE,oBAAoB,EACjC,wBAAwB,EAAE,wBAAwB,EAClD,kBAAkB,EAAE,kBAAkB,EACtC,mBAAmB,EAAE,mBAAmB,EACxC,qBAAqB,EAAE,qBAAqB,EAC5C,gBAAgB,EAAE,gBAAgB,EAClC,QAAQ,EAAE,UAAA,kBAAkB;oBAC1B,OAAA,uBAAuB,CAAC,gBAAgB,CAAC,kBAAkB,EAAE,oBAAoB,CAAC,CAAC;gBAAnF,CAAmF,GAErF,CACY,CACjB,CACG,CACP,CAAC;AACJ,CAAC;AAED,gBAAgB,CAAC,qBAAqB,EAAE,uBAAuB,CAAC,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useEffect, useRef, useState } from 'react';\nimport clsx from 'clsx';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { getBaseProps } from '../internal/base-component';\nimport InternalBox from '../box/internal';\nimport { ButtonProps } from '../button/interfaces';\nimport { InternalButton } from '../button/internal';\nimport InternalModal from '../modal/internal';\nimport InternalSpaceBetween from '../space-between/internal';\nimport {\n copyPreferences,\n mergePreferences,\n ModalContentLayout,\n PageSizePreference,\n WrapLinesPreference,\n StripedRowsPreference,\n CustomPreference,\n} from './utils';\nimport VisibleContentPreference from './visible-content';\nimport checkControlled from '../internal/hooks/check-controlled';\nimport { CollectionPreferencesProps } from './interfaces';\nimport styles from './styles.css.js';\nimport { applyDisplayName } from '../internal/utils/apply-display-name';\nimport useBaseComponent from '../internal/hooks/use-base-component';\n\nexport { CollectionPreferencesProps };\n\ninterface ModalContentProps\n extends Pick<\n CollectionPreferencesProps,\n | 'preferences'\n | 'visibleContentPreference'\n | 'pageSizePreference'\n | 'wrapLinesPreference'\n | 'stripedRowsPreference'\n | 'customPreference'\n > {\n onChange: (preferences: CollectionPreferencesProps.Preferences) => void;\n}\n\nconst ModalContent = ({\n preferences = {},\n pageSizePreference,\n wrapLinesPreference,\n stripedRowsPreference,\n customPreference,\n visibleContentPreference,\n onChange,\n}: ModalContentProps) => {\n if (\n !visibleContentPreference &&\n !pageSizePreference &&\n !wrapLinesPreference &&\n !stripedRowsPreference &&\n customPreference\n ) {\n return (\n <CustomPreference\n value={preferences.custom}\n customPreference={customPreference}\n onChange={custom => onChange({ custom })}\n />\n );\n }\n\n return (\n <ModalContentLayout\n left={\n <InternalSpaceBetween size=\"l\">\n {pageSizePreference && (\n <PageSizePreference\n value={preferences.pageSize}\n {...pageSizePreference}\n onChange={pageSize => onChange({ pageSize })}\n />\n )}\n {wrapLinesPreference && (\n <WrapLinesPreference\n value={preferences.wrapLines}\n {...wrapLinesPreference}\n onChange={wrapLines => onChange({ wrapLines })}\n />\n )}\n {stripedRowsPreference && (\n <StripedRowsPreference\n value={preferences.stripedRows}\n {...stripedRowsPreference}\n onChange={stripedRows => onChange({ stripedRows })}\n />\n )}\n {customPreference && (\n <CustomPreference\n value={preferences.custom}\n customPreference={customPreference}\n onChange={custom => onChange({ custom })}\n />\n )}\n </InternalSpaceBetween>\n }\n right={\n visibleContentPreference && (\n <VisibleContentPreference\n value={preferences.visibleContent}\n {...visibleContentPreference}\n onChange={visibleContent => onChange({ visibleContent })}\n />\n )\n }\n />\n );\n};\n\nexport default function CollectionPreferences({\n title,\n confirmLabel,\n cancelLabel,\n disabled = false,\n onConfirm,\n onCancel,\n visibleContentPreference,\n pageSizePreference,\n wrapLinesPreference,\n stripedRowsPreference,\n preferences,\n customPreference,\n ...rest\n}: CollectionPreferencesProps) {\n const { __internalRootRef } = useBaseComponent('CollectionPreferences');\n checkControlled('CollectioPreferences', 'preferences', preferences, 'onConfirm', onConfirm);\n const baseProps = getBaseProps(rest);\n const [modalVisible, setModalVisible] = useState(false);\n const [temporaryPreferences, setTemporaryPreferences] = useState(copyPreferences(preferences || {}));\n const triggerRef = useRef<ButtonProps.Ref>(null);\n const dialogPreviouslyOpen = useRef(false);\n useEffect(() => {\n if (!modalVisible) {\n dialogPreviouslyOpen.current && triggerRef.current && triggerRef.current.focus();\n } else {\n dialogPreviouslyOpen.current = true;\n }\n }, [modalVisible]);\n\n const onConfirmListener = () => {\n setModalVisible(false);\n fireNonCancelableEvent(onConfirm, temporaryPreferences);\n };\n\n const onCancelListener = () => {\n fireNonCancelableEvent(onCancel, {});\n setModalVisible(false);\n setTemporaryPreferences(copyPreferences(preferences || {}));\n };\n\n return (\n <div {...baseProps} className={clsx(baseProps.className, styles.root)} ref={__internalRootRef}>\n <InternalButton\n ref={triggerRef}\n className={styles['trigger-button']}\n disabled={disabled}\n ariaLabel={title}\n onClick={() => {\n setTemporaryPreferences(copyPreferences(preferences || {}));\n setModalVisible(true);\n }}\n variant=\"icon\"\n iconName=\"settings\"\n formAction=\"none\"\n />\n {!disabled && modalVisible && (\n <InternalModal\n className={styles['modal-root']}\n visible={true}\n header={title}\n footer={\n <InternalBox float=\"right\">\n <InternalSpaceBetween direction=\"horizontal\" size=\"xs\">\n <InternalButton\n className={styles['cancel-button']}\n variant=\"link\"\n formAction=\"none\"\n onClick={onCancelListener}\n >\n {cancelLabel}\n </InternalButton>\n <InternalButton\n className={styles['confirm-button']}\n variant=\"primary\"\n formAction=\"none\"\n onClick={onConfirmListener}\n >\n {confirmLabel}\n </InternalButton>\n </InternalSpaceBetween>\n </InternalBox>\n }\n closeAriaLabel={cancelLabel}\n size=\"large\"\n onDismiss={onCancelListener}\n >\n <ModalContent\n preferences={temporaryPreferences}\n visibleContentPreference={visibleContentPreference}\n pageSizePreference={pageSizePreference}\n wrapLinesPreference={wrapLinesPreference}\n stripedRowsPreference={stripedRowsPreference}\n customPreference={customPreference}\n onChange={changedPreferences =>\n setTemporaryPreferences(mergePreferences(changedPreferences, temporaryPreferences))\n }\n />\n </InternalModal>\n )}\n </div>\n );\n}\n\napplyDisplayName(CollectionPreferences, 'CollectionPreferences');\n"]}
|
|
@@ -43,6 +43,18 @@ export interface CollectionPreferencesProps<CustomPreferenceType = any> extends
|
|
|
43
43
|
* You must set the current value in the `preferences.wrapLines` property.
|
|
44
44
|
*/
|
|
45
45
|
wrapLinesPreference?: CollectionPreferencesProps.WrapLinesPreference;
|
|
46
|
+
/**
|
|
47
|
+
* Configures the built-in "striped rows" preference.
|
|
48
|
+
*
|
|
49
|
+
* If you set it, the component displays this preference in the modal.
|
|
50
|
+
*
|
|
51
|
+
* It contains the following:
|
|
52
|
+
* - `label` (string) - Specifies the label for the option checkbox.
|
|
53
|
+
* - `description` (string) - Specifies the text displayed below the checkbox label.
|
|
54
|
+
*
|
|
55
|
+
* You must set the current value in the `preferences.stripedRows` property.
|
|
56
|
+
*/
|
|
57
|
+
stripedRowsPreference?: CollectionPreferencesProps.StripedRowsPreference;
|
|
46
58
|
/**
|
|
47
59
|
* Configures the built-in "visible content selection" preference (for example, visible columns in a table).
|
|
48
60
|
*
|
|
@@ -115,6 +127,7 @@ export declare namespace CollectionPreferencesProps {
|
|
|
115
127
|
interface Preferences<CustomPreferenceType = any> {
|
|
116
128
|
pageSize?: number;
|
|
117
129
|
wrapLines?: boolean;
|
|
130
|
+
stripedRows?: boolean;
|
|
118
131
|
visibleContent?: ReadonlyArray<string>;
|
|
119
132
|
custom?: CustomPreferenceType;
|
|
120
133
|
}
|
|
@@ -143,5 +156,9 @@ export declare namespace CollectionPreferencesProps {
|
|
|
143
156
|
label: string;
|
|
144
157
|
description: string;
|
|
145
158
|
}
|
|
159
|
+
interface StripedRowsPreference {
|
|
160
|
+
label: string;
|
|
161
|
+
description: string;
|
|
162
|
+
}
|
|
146
163
|
}
|
|
147
164
|
//# sourceMappingURL=interfaces.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/collection-preferences/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AAE/D,MAAM,WAAW,0BAA0B,CAAC,oBAAoB,GAAG,GAAG,CAAE,SAAQ,kBAAkB;IAChG;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;;;;;;;;;OAYG;IACH,kBAAkB,CAAC,EAAE,0BAA0B,CAAC,kBAAkB,CAAC;IACnE;;;;;;;;;;OAUG;IACH,mBAAmB,CAAC,EAAE,0BAA0B,CAAC,mBAAmB,CAAC;IACrE;;;;;;;;;;;;;;;;;OAiBG;IACH,wBAAwB,CAAC,EAAE,0BAA0B,CAAC,wBAAwB,CAAC;IAC/E;;;;;;;;OAQG;IACH,WAAW,CAAC,EAAE,0BAA0B,CAAC,WAAW,CAAC,oBAAoB,CAAC,CAAC;IAC3E;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,gBAAgB,CAAC,EAAE,CACjB,WAAW,EAAE,oBAAoB,EACjC,cAAc,EAAE,KAAK,CAAC,QAAQ,CAAC,oBAAoB,CAAC,KACjD,KAAK,CAAC,SAAS,CAAC;IACrB;;OAEG;IACH,QAAQ,CAAC,EAAE,yBAAyB,CAAC;IACrC;;;;;;;;;;OAUG;IACH,SAAS,CAAC,EAAE,yBAAyB,CAAC,0BAA0B,CAAC,WAAW,CAAC,oBAAoB,CAAC,CAAC,CAAC;CACrG;AAED,yBAAiB,0BAA0B,CAAC;IAC1C,UAAiB,WAAW,CAAC,oBAAoB,GAAG,GAAG;QACrD,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,SAAS,CAAC,EAAE,OAAO,CAAC;QACpB,cAAc,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;QACvC,MAAM,CAAC,EAAE,oBAAoB,CAAC;KAC/B;IAED,UAAiB,wBAAwB;QACvC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,0BAA0B,CAAC,0BAA0B,CAAC,CAAC;KAC/E;IAED,UAAiB,0BAA0B;QACzC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,0BAA0B,CAAC,oBAAoB,CAAC,CAAC;KACzE;IAED,UAAiB,oBAAoB;QACnC,EAAE,EAAE,MAAM,CAAC;QACX,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,CAAC,EAAE,OAAO,CAAC;KACpB;IAED,UAAiB,kBAAkB;QACjC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,cAAc,CAAC,CAAC;KACxC;IAED,UAAiB,cAAc;QAC7B,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;KACf;IAED,UAAiB,mBAAmB;QAClC,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;KACrB;CACF"}
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../src/collection-preferences/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;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AM,CAAC,CAAC;QACvC,MAAM,CAAC,EAAE,oBAAoB,CAAC;KAC/B;IAED,UAAiB,wBAAwB;QACvC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,0BAA0B,CAAC,0BAA0B,CAAC,CAAC;KAC/E;IAED,UAAiB,0BAA0B;QACzC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,0BAA0B,CAAC,oBAAoB,CAAC,CAAC;KACzE;IAED,UAAiB,oBAAoB;QACnC,EAAE,EAAE,MAAM,CAAC;QACX,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,CAAC,EAAE,OAAO,CAAC;KACpB;IAED,UAAiB,kBAAkB;QACjC,KAAK,EAAE,MAAM,CAAC;QACd,OAAO,EAAE,aAAa,CAAC,cAAc,CAAC,CAAC;KACxC;IAED,UAAiB,cAAc;QAC7B,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,MAAM,CAAC;KACf;IAED,UAAiB,mBAAmB;QAClC,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;KACrB;IAED,UAAiB,qBAAqB;QACpC,KAAK,EAAE,MAAM,CAAC;QACd,WAAW,EAAE,MAAM,CAAC;KACrB;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../src/collection-preferences/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { BaseComponentProps } from '../internal/base-component';\nimport { NonCancelableEventHandler } from '../internal/events';\n\nexport interface CollectionPreferencesProps<CustomPreferenceType = any> extends BaseComponentProps {\n /**\n * Specifies the title of the preferences modal dialog. It is also used as an `aria-label` for the trigger button.\n */\n title: string;\n /**\n * Label of the confirm button in the modal footer.\n */\n confirmLabel: string;\n /**\n * Label of the cancel button in the modal footer.\n */\n cancelLabel: string;\n /**\n * Determines whether the preferences trigger button is disabled.\n */\n disabled?: boolean;\n /**\n * Configures the built-in \"page size selection\" preference.\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `title` (string) - Specifies the text displayed at the top of the preference.\n * - `options` - Specifies an array of options for page size selection. Each entry contains:\n * - `value` (number) - The value for the radio button (that is, the number of items per page).\n * - `label` (string) - A label for the radio button (for example, \"10 resources\").\n *\n * You must set the current value in the `preferences.pageSize` property.\n */\n pageSizePreference?: CollectionPreferencesProps.PageSizePreference;\n /**\n * Configures the built-in \"wrap lines\" preference.\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `label` (string) - Specifies the label for the option checkbox.\n * - `description` (string) - Specifies the text displayed below the checkbox label.\n *\n * You must set the current value in the `preferences.wrapLines` property.\n */\n wrapLinesPreference?: CollectionPreferencesProps.WrapLinesPreference;\n /**\n * Configures the built-in \"visible content selection\" preference (for example, visible columns in a table).\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `title` (string) - Specifies the text displayed at the top of the preference.\n * - `options` - Specifies an array of groups of options for visible content selection.\n *\n * Each group of options contains the following:\n * - `label` (string) - The text to display as a title for the options group.\n * - `options` - Specifies an aray of options in the group. Each option contains the following:\n * - `id` (string) - Corresponds to a column `id` for tables or to a section `id` for cards.\n * - `label` (string) - Specifies a short description of the content.\n * - `editable` (boolean) - (Optional) Determines whether the user is able to toggle its visibility. This is `true` by default.\n *\n * You must set the current list of visible content `id`s in the `preferences.visibleContent` property.\n */\n visibleContentPreference?: CollectionPreferencesProps.VisibleContentPreference;\n /**\n * Specifies the current preference values. This includes both built-in and custom preferences.\n *\n * It contains the following:\n * - `pageSize` (number) - (Optional)\n * - `wrapLines` (boolean) - (Optional)\n * - `visibleContent` (ReadonlyArray<string>) - Specifies the list of visible content `id`s. The order of the `id`s does not influence the display.\n * - `custom` (CustomPreferenceType) - Specifies the value for your custom preference.\n */\n preferences?: CollectionPreferencesProps.Preferences<CustomPreferenceType>;\n /**\n * Configures custom preferences. The function receives two parameters:\n *\n * - `customValue` (CustomPreferenceType) - Current value for your custom preference. It is initialized using the value you provide in `preferences.custom`.\n * - `setCustomValue` - A function that is called to notify a state update.\n *\n * It should return the content of your custom preference, for example:\n * ```\n * (customValue, setCustomValue) => (\n * <Checkbox checked={customValue} onChange={({ detail }) => setCustomValue(detail.checked)} />\n * )\n * ```\n *\n * When the user confirms the changes, the new value is passed in the `detail.custom` property of the `onConfirm` listener.\n * When the user cancels the changes, the `customValue` is reset to the one present in `preferences.custom` property.\n *\n * **Display**\n * - If any of the built-in preferences (`pageSizePreference`, `wrapLinesPreference`, or `visibleContentPreference`) are displayed,\n * the custom content is displayed at the bottom of the left column within the modal.\n * - If no built-in preference is displayed, the custom content occupies the whole modal.\n */\n customPreference?: (\n customValue: CustomPreferenceType,\n setCustomValue: React.Dispatch<CustomPreferenceType>\n ) => React.ReactNode;\n /**\n * Called when the user cancels a preference change using the cancel button in the modal footer or by dismissing the modal.\n */\n onCancel?: NonCancelableEventHandler;\n /**\n * Called when the user confirms a preference change using the confirm button in the modal footer.\n *\n * The event `detail` contains the following:\n * - `pageSize` (number) - (Optional) The selected page size value. Available only if you specify the `pageSizePreference` property.\n * - `wrapLines` (boolean) - (Optional) The current line wrapping preference value. Available only if you specify the `wrapLinesPreference` property.\n * - `visibleContent` (ReadonlyArray<string>) - (Optional) The list of selected content `id`s. Available only if you specify the `visibleContentPreference` property.\n * - `custom` (CustomPreferenceType) - (Optional) The selected value for your custom preference.\n *\n * The values for all configured preferences are present even if the user didn't change their values.\n */\n onConfirm?: NonCancelableEventHandler<CollectionPreferencesProps.Preferences<CustomPreferenceType>>;\n}\n\nexport namespace CollectionPreferencesProps {\n export interface Preferences<CustomPreferenceType = any> {\n pageSize?: number;\n wrapLines?: boolean;\n visibleContent?: ReadonlyArray<string>;\n custom?: CustomPreferenceType;\n }\n\n export interface VisibleContentPreference {\n title: string;\n options: ReadonlyArray<CollectionPreferencesProps.VisibleContentOptionsGroup>;\n }\n\n export interface VisibleContentOptionsGroup {\n label: string;\n options: ReadonlyArray<CollectionPreferencesProps.VisibleContentOption>;\n }\n\n export interface VisibleContentOption {\n id: string;\n label: string;\n editable?: boolean;\n }\n\n export interface PageSizePreference {\n title: string;\n options: ReadonlyArray<PageSizeOption>;\n }\n\n export interface PageSizeOption {\n value: number;\n label: string;\n }\n\n export interface WrapLinesPreference {\n label: string;\n description: string;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"interfaces.js","sourceRoot":"","sources":["../../../src/collection-preferences/interfaces.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport { BaseComponentProps } from '../internal/base-component';\nimport { NonCancelableEventHandler } from '../internal/events';\n\nexport interface CollectionPreferencesProps<CustomPreferenceType = any> extends BaseComponentProps {\n /**\n * Specifies the title of the preferences modal dialog. It is also used as an `aria-label` for the trigger button.\n */\n title: string;\n /**\n * Label of the confirm button in the modal footer.\n */\n confirmLabel: string;\n /**\n * Label of the cancel button in the modal footer.\n */\n cancelLabel: string;\n /**\n * Determines whether the preferences trigger button is disabled.\n */\n disabled?: boolean;\n /**\n * Configures the built-in \"page size selection\" preference.\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `title` (string) - Specifies the text displayed at the top of the preference.\n * - `options` - Specifies an array of options for page size selection. Each entry contains:\n * - `value` (number) - The value for the radio button (that is, the number of items per page).\n * - `label` (string) - A label for the radio button (for example, \"10 resources\").\n *\n * You must set the current value in the `preferences.pageSize` property.\n */\n pageSizePreference?: CollectionPreferencesProps.PageSizePreference;\n /**\n * Configures the built-in \"wrap lines\" preference.\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `label` (string) - Specifies the label for the option checkbox.\n * - `description` (string) - Specifies the text displayed below the checkbox label.\n *\n * You must set the current value in the `preferences.wrapLines` property.\n */\n wrapLinesPreference?: CollectionPreferencesProps.WrapLinesPreference;\n /**\n * Configures the built-in \"striped rows\" preference.\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `label` (string) - Specifies the label for the option checkbox.\n * - `description` (string) - Specifies the text displayed below the checkbox label.\n *\n * You must set the current value in the `preferences.stripedRows` property.\n */\n stripedRowsPreference?: CollectionPreferencesProps.StripedRowsPreference;\n /**\n * Configures the built-in \"visible content selection\" preference (for example, visible columns in a table).\n *\n * If you set it, the component displays this preference in the modal.\n *\n * It contains the following:\n * - `title` (string) - Specifies the text displayed at the top of the preference.\n * - `options` - Specifies an array of groups of options for visible content selection.\n *\n * Each group of options contains the following:\n * - `label` (string) - The text to display as a title for the options group.\n * - `options` - Specifies an aray of options in the group. Each option contains the following:\n * - `id` (string) - Corresponds to a column `id` for tables or to a section `id` for cards.\n * - `label` (string) - Specifies a short description of the content.\n * - `editable` (boolean) - (Optional) Determines whether the user is able to toggle its visibility. This is `true` by default.\n *\n * You must set the current list of visible content `id`s in the `preferences.visibleContent` property.\n */\n visibleContentPreference?: CollectionPreferencesProps.VisibleContentPreference;\n /**\n * Specifies the current preference values. This includes both built-in and custom preferences.\n *\n * It contains the following:\n * - `pageSize` (number) - (Optional)\n * - `wrapLines` (boolean) - (Optional)\n * - `visibleContent` (ReadonlyArray<string>) - Specifies the list of visible content `id`s. The order of the `id`s does not influence the display.\n * - `custom` (CustomPreferenceType) - Specifies the value for your custom preference.\n */\n preferences?: CollectionPreferencesProps.Preferences<CustomPreferenceType>;\n /**\n * Configures custom preferences. The function receives two parameters:\n *\n * - `customValue` (CustomPreferenceType) - Current value for your custom preference. It is initialized using the value you provide in `preferences.custom`.\n * - `setCustomValue` - A function that is called to notify a state update.\n *\n * It should return the content of your custom preference, for example:\n * ```\n * (customValue, setCustomValue) => (\n * <Checkbox checked={customValue} onChange={({ detail }) => setCustomValue(detail.checked)} />\n * )\n * ```\n *\n * When the user confirms the changes, the new value is passed in the `detail.custom` property of the `onConfirm` listener.\n * When the user cancels the changes, the `customValue` is reset to the one present in `preferences.custom` property.\n *\n * **Display**\n * - If any of the built-in preferences (`pageSizePreference`, `wrapLinesPreference`, or `visibleContentPreference`) are displayed,\n * the custom content is displayed at the bottom of the left column within the modal.\n * - If no built-in preference is displayed, the custom content occupies the whole modal.\n */\n customPreference?: (\n customValue: CustomPreferenceType,\n setCustomValue: React.Dispatch<CustomPreferenceType>\n ) => React.ReactNode;\n /**\n * Called when the user cancels a preference change using the cancel button in the modal footer or by dismissing the modal.\n */\n onCancel?: NonCancelableEventHandler;\n /**\n * Called when the user confirms a preference change using the confirm button in the modal footer.\n *\n * The event `detail` contains the following:\n * - `pageSize` (number) - (Optional) The selected page size value. Available only if you specify the `pageSizePreference` property.\n * - `wrapLines` (boolean) - (Optional) The current line wrapping preference value. Available only if you specify the `wrapLinesPreference` property.\n * - `visibleContent` (ReadonlyArray<string>) - (Optional) The list of selected content `id`s. Available only if you specify the `visibleContentPreference` property.\n * - `custom` (CustomPreferenceType) - (Optional) The selected value for your custom preference.\n *\n * The values for all configured preferences are present even if the user didn't change their values.\n */\n onConfirm?: NonCancelableEventHandler<CollectionPreferencesProps.Preferences<CustomPreferenceType>>;\n}\n\nexport namespace CollectionPreferencesProps {\n export interface Preferences<CustomPreferenceType = any> {\n pageSize?: number;\n wrapLines?: boolean;\n stripedRows?: boolean;\n visibleContent?: ReadonlyArray<string>;\n custom?: CustomPreferenceType;\n }\n\n export interface VisibleContentPreference {\n title: string;\n options: ReadonlyArray<CollectionPreferencesProps.VisibleContentOptionsGroup>;\n }\n\n export interface VisibleContentOptionsGroup {\n label: string;\n options: ReadonlyArray<CollectionPreferencesProps.VisibleContentOption>;\n }\n\n export interface VisibleContentOption {\n id: string;\n label: string;\n editable?: boolean;\n }\n\n export interface PageSizePreference {\n title: string;\n options: ReadonlyArray<PageSizeOption>;\n }\n\n export interface PageSizeOption {\n value: number;\n label: string;\n }\n\n export interface WrapLinesPreference {\n label: string;\n description: string;\n }\n\n export interface StripedRowsPreference {\n label: string;\n description: string;\n }\n}\n"]}
|
|
@@ -1,24 +1,25 @@
|
|
|
1
1
|
|
|
2
2
|
import './styles.scoped.css';
|
|
3
3
|
export default {
|
|
4
|
-
"visible-content": "awsui_visible-
|
|
5
|
-
"visible-content-toggle": "awsui_visible-content-
|
|
6
|
-
"visible-content-groups": "awsui_visible-content-
|
|
7
|
-
"visible-content-group": "awsui_visible-content-
|
|
8
|
-
"visible-content-title": "awsui_visible-content-
|
|
9
|
-
"visible-content-group-label": "awsui_visible-content-group-
|
|
10
|
-
"visible-content-option": "awsui_visible-content-
|
|
11
|
-
"visible-content-option-label": "awsui_visible-content-option-
|
|
12
|
-
"root": "
|
|
13
|
-
"modal-root": "awsui_modal-
|
|
14
|
-
"trigger-button": "awsui_trigger-
|
|
15
|
-
"cancel-button": "awsui_cancel-
|
|
16
|
-
"confirm-button": "awsui_confirm-
|
|
17
|
-
"custom": "
|
|
18
|
-
"second-column-small": "awsui_second-column-
|
|
19
|
-
"wrap-lines": "awsui_wrap-
|
|
20
|
-
"
|
|
21
|
-
"page-size
|
|
22
|
-
"page-size-
|
|
4
|
+
"visible-content": "awsui_visible-content_tc96w_1b1c1_185",
|
|
5
|
+
"visible-content-toggle": "awsui_visible-content-toggle_tc96w_1b1c1_186",
|
|
6
|
+
"visible-content-groups": "awsui_visible-content-groups_tc96w_1b1c1_187",
|
|
7
|
+
"visible-content-group": "awsui_visible-content-group_tc96w_1b1c1_187",
|
|
8
|
+
"visible-content-title": "awsui_visible-content-title_tc96w_1b1c1_192",
|
|
9
|
+
"visible-content-group-label": "awsui_visible-content-group-label_tc96w_1b1c1_200",
|
|
10
|
+
"visible-content-option": "awsui_visible-content-option_tc96w_1b1c1_206",
|
|
11
|
+
"visible-content-option-label": "awsui_visible-content-option-label_tc96w_1b1c1_217",
|
|
12
|
+
"root": "awsui_root_tc96w_1b1c1_224",
|
|
13
|
+
"modal-root": "awsui_modal-root_tc96w_1b1c1_225",
|
|
14
|
+
"trigger-button": "awsui_trigger-button_tc96w_1b1c1_226",
|
|
15
|
+
"cancel-button": "awsui_cancel-button_tc96w_1b1c1_227",
|
|
16
|
+
"confirm-button": "awsui_confirm-button_tc96w_1b1c1_228",
|
|
17
|
+
"custom": "awsui_custom_tc96w_1b1c1_229",
|
|
18
|
+
"second-column-small": "awsui_second-column-small_tc96w_1b1c1_233",
|
|
19
|
+
"wrap-lines": "awsui_wrap-lines_tc96w_1b1c1_237",
|
|
20
|
+
"striped-rows": "awsui_striped-rows_tc96w_1b1c1_238",
|
|
21
|
+
"page-size": "awsui_page-size_tc96w_1b1c1_239",
|
|
22
|
+
"page-size-form-field": "awsui_page-size-form-field_tc96w_1b1c1_240",
|
|
23
|
+
"page-size-radio-group": "awsui_page-size-radio-group_tc96w_1b1c1_241"
|
|
23
24
|
};
|
|
24
25
|
|