@cloudscape-design/components 3.0.793 → 3.0.795
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.map +1 -1
- package/alert/internal.js +3 -3
- package/alert/internal.js.map +1 -1
- package/alert/styles.css.js +28 -27
- package/alert/styles.scoped.css +47 -42
- package/alert/styles.selectors.js +28 -27
- package/app-layout/visual-refresh-toolbar/compute-layout.d.ts +1 -0
- package/app-layout/visual-refresh-toolbar/compute-layout.d.ts.map +1 -1
- package/app-layout/visual-refresh-toolbar/compute-layout.js +2 -2
- package/app-layout/visual-refresh-toolbar/compute-layout.js.map +1 -1
- package/app-layout/visual-refresh-toolbar/contexts.d.ts +7 -0
- package/app-layout/visual-refresh-toolbar/contexts.d.ts.map +1 -0
- package/app-layout/visual-refresh-toolbar/contexts.js +6 -0
- package/app-layout/visual-refresh-toolbar/contexts.js.map +1 -0
- package/app-layout/visual-refresh-toolbar/index.d.ts.map +1 -1
- package/app-layout/visual-refresh-toolbar/index.js +56 -20
- package/app-layout/visual-refresh-toolbar/index.js.map +1 -1
- package/app-layout/visual-refresh-toolbar/toolbar/index.d.ts.map +1 -1
- package/app-layout/visual-refresh-toolbar/toolbar/index.js +3 -2
- package/app-layout/visual-refresh-toolbar/toolbar/index.js.map +1 -1
- package/button-dropdown/internal.js +3 -3
- package/button-dropdown/internal.js.map +1 -1
- package/flashbar/flash.d.ts.map +1 -1
- package/flashbar/flash.js +3 -3
- package/flashbar/flash.js.map +1 -1
- package/flashbar/styles.css.js +50 -50
- package/flashbar/styles.scoped.css +151 -164
- package/flashbar/styles.selectors.js +50 -50
- package/internal/environment.js +1 -1
- package/internal/environment.json +1 -1
- package/internal/manifest.json +1 -1
- package/internal/plugins/api.d.ts +3 -0
- package/internal/plugins/api.d.ts.map +1 -1
- package/internal/plugins/api.js +3 -0
- package/internal/plugins/api.js.map +1 -1
- package/internal/plugins/controllers/alert-flash-content.d.ts +9 -0
- package/internal/plugins/controllers/alert-flash-content.d.ts.map +1 -1
- package/internal/plugins/controllers/alert-flash-content.js +9 -1
- package/internal/plugins/controllers/alert-flash-content.js.map +1 -1
- package/internal/plugins/controllers/shared-react-contexts.d.ts +10 -0
- package/internal/plugins/controllers/shared-react-contexts.d.ts.map +1 -0
- package/internal/plugins/controllers/shared-react-contexts.js +27 -0
- package/internal/plugins/controllers/shared-react-contexts.js.map +1 -0
- package/internal/plugins/helpers/use-discovered-content.d.ts +3 -2
- package/internal/plugins/helpers/use-discovered-content.d.ts.map +1 -1
- package/internal/plugins/helpers/use-discovered-content.js +9 -2
- package/internal/plugins/helpers/use-discovered-content.js.map +1 -1
- package/internal/plugins/helpers/use-global-breadcrumbs.d.ts.map +1 -1
- package/internal/plugins/helpers/use-global-breadcrumbs.js +11 -3
- package/internal/plugins/helpers/use-global-breadcrumbs.js.map +1 -1
- package/multiselect/embedded.d.ts.map +1 -1
- package/multiselect/embedded.js +2 -7
- package/multiselect/embedded.js.map +1 -1
- package/multiselect/use-multiselect.d.ts +1 -1
- package/multiselect/use-multiselect.d.ts.map +1 -1
- package/multiselect/use-multiselect.js.map +1 -1
- package/package.json +1 -1
- package/property-filter/i18n-utils.d.ts.map +1 -1
- package/property-filter/i18n-utils.js +6 -3
- package/property-filter/i18n-utils.js.map +1 -1
- package/property-filter/index.d.ts.map +1 -1
- package/property-filter/index.js +20 -2
- package/property-filter/index.js.map +1 -1
- package/property-filter/interfaces.d.ts +4 -2
- package/property-filter/interfaces.d.ts.map +1 -1
- package/property-filter/interfaces.js.map +1 -1
- package/property-filter/internal.d.ts.map +1 -1
- package/property-filter/internal.js +5 -3
- package/property-filter/internal.js.map +1 -1
- package/property-filter/property-editor.d.ts +13 -2
- package/property-filter/property-editor.d.ts.map +1 -1
- package/property-filter/property-editor.js +19 -1
- package/property-filter/property-editor.js.map +1 -1
- package/property-filter/styles.css.js +39 -35
- package/property-filter/styles.scoped.css +66 -37
- package/property-filter/styles.selectors.js +39 -35
- package/property-filter/token-editor-inputs.d.ts +3 -3
- package/property-filter/token-editor-inputs.d.ts.map +1 -1
- package/property-filter/token-editor-inputs.js +29 -4
- package/property-filter/token-editor-inputs.js.map +1 -1
- package/property-filter/token-editor.d.ts.map +1 -1
- package/property-filter/token-editor.js +9 -1
- package/property-filter/token-editor.js.map +1 -1
- package/property-filter/utils.d.ts.map +1 -1
- package/property-filter/utils.js +10 -3
- package/property-filter/utils.js.map +1 -1
- package/select/utils/use-select.d.ts.map +1 -1
- package/select/utils/use-select.js +14 -7
- package/select/utils/use-select.js.map +1 -1
- package/table/use-column-widths.d.ts.map +1 -1
- package/table/use-column-widths.js +7 -1
- package/table/use-column-widths.js.map +1 -1
- package/test-utils/tsconfig.tsbuildinfo +1 -1
- package/text-filter/index.d.ts.map +1 -1
- package/text-filter/index.js +3 -1
- package/text-filter/index.js.map +1 -1
- package/text-filter/interfaces.d.ts +2 -1
- package/text-filter/interfaces.d.ts.map +1 -1
- package/text-filter/interfaces.js.map +1 -1
- package/text-filter/internal.d.ts.map +1 -1
- package/text-filter/internal.js +2 -2
- package/text-filter/internal.js.map +1 -1
- package/tutorial-panel/components/tutorial-detail-view/styles.css.js +20 -20
- package/tutorial-panel/components/tutorial-detail-view/styles.scoped.css +22 -21
- package/tutorial-panel/components/tutorial-detail-view/styles.selectors.js +20 -20
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"internal.js","sourceRoot":"","sources":["../../../src/property-filter/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,mBAAmB,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrE,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB,OAAO,EAAE,6BAA6B,EAAE,MAAM,kEAAkE,CAAC;AAEjH,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;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AY,CAAC,EAC/B,QAAQ,EAAE,QAAQ,IAEjB,WAAW,CAAC,gBAAgB,CACd,CACZ,CACR,GAEH,CACmB,CACnB,CACP,CACG,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,sBAAsB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useImperativeHandle, useRef, useState } from 'react';\nimport clsx from 'clsx';\n\nimport { PropertyFilterOperator } from '@cloudscape-design/collection-hooks';\nimport { getAnalyticsMetadataAttribute } from '@cloudscape-design/component-toolkit/internal/analytics-metadata';\n\nimport { InternalButton } from '../button/internal';\nimport { getBaseProps } from '../internal/base-component';\nimport { AutosuggestInputRef } from '../internal/components/autosuggest-input';\nimport TokenList from '../internal/components/token-list';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { useListFocusController } from '../internal/hooks/use-list-focus-controller';\nimport { useMergeRefs } from '../internal/hooks/use-merge-refs';\nimport { useUniqueId } from '../internal/hooks/use-unique-id/index';\nimport { SomeRequired } from '../internal/types';\nimport { joinStrings } from '../internal/utils/strings';\nimport InternalSpaceBetween from '../space-between/internal';\nimport { SearchResults } from '../text-filter/search-results';\nimport { GeneratedAnalyticsMetadataPropertyFilterClearFilters } from './analytics-metadata/interfaces';\nimport { getAllowedOperators, getAutosuggestOptions, getQueryActions, parseText } from './controller';\nimport { usePropertyFilterI18n } from './i18n-utils';\nimport {\n ComparisonOperator,\n ExtendedOperator,\n FilteringProperty,\n InternalFilteringOption,\n InternalFilteringProperty,\n InternalFreeTextFiltering,\n InternalQuery,\n InternalToken,\n InternalTokenGroup,\n ParsedText,\n PropertyFilterProps,\n Ref,\n Token,\n TokenGroup,\n} from './interfaces';\nimport { PropertyEditorContent, PropertyEditorFooter } from './property-editor';\nimport PropertyFilterAutosuggest, { PropertyFilterAutosuggestProps } from './property-filter-autosuggest';\nimport { TokenButton } from './token';\nimport { useLoadItems } from './use-load-items';\n\nimport tokenListStyles from '../internal/components/token-list/styles.css.js';\nimport analyticsSelectors from './analytics-metadata/styles.css.js';\nimport styles from './styles.css.js';\n\nexport type PropertyFilterInternalProps = SomeRequired<\n PropertyFilterProps,\n 'filteringOptions' | 'customGroupsText' | 'enableTokenGroups' | 'disableFreeTextFiltering' | 'hideOperations'\n> &\n InternalBaseComponentProps;\n\nconst PropertyFilterInternal = React.forwardRef(\n (\n {\n disabled,\n countText,\n query,\n hideOperations,\n onChange,\n filteringProperties,\n filteringOptions,\n customGroupsText,\n disableFreeTextFiltering,\n freeTextFiltering,\n onLoadItems,\n virtualScroll,\n customControl,\n customFilterActions,\n filteringPlaceholder,\n filteringAriaLabel,\n filteringEmpty,\n filteringLoadingText,\n filteringFinishedText,\n filteringErrorText,\n filteringRecoveryText,\n filteringConstraintText,\n filteringStatusType,\n asyncProperties,\n tokenLimit,\n expandToViewport,\n tokenLimitShowFewerAriaLabel,\n tokenLimitShowMoreAriaLabel,\n enableTokenGroups,\n __internalRootRef,\n ...rest\n }: PropertyFilterInternalProps,\n ref: React.Ref<Ref>\n ) => {\n const [nextFocusIndex, setNextFocusIndex] = useState<null | number>(null);\n const tokenListRef = useListFocusController({\n nextFocusIndex,\n onFocusMoved: (target, targetType) => {\n if (targetType === 'fallback') {\n inputRef.current?.focus({ preventDropdown: true });\n } else {\n target.focus();\n }\n setNextFocusIndex(null);\n },\n listItemSelector: `.${tokenListStyles['list-item']}`,\n showMoreSelector: `.${tokenListStyles.toggle}`,\n fallbackSelector: `.${styles.input}`,\n });\n\n const mergedRef = useMergeRefs(tokenListRef, __internalRootRef);\n const inputRef = useRef<AutosuggestInputRef>(null);\n const baseProps = getBaseProps(rest);\n\n const i18nStrings = usePropertyFilterI18n(rest.i18nStrings);\n\n useImperativeHandle(ref, () => ({ focus: () => inputRef.current?.focus() }), []);\n const [filteringText, setFilteringText] = useState<string>('');\n\n const { internalProperties, internalOptions, internalQuery, internalFreeText } = (() => {\n const propertyByKey = filteringProperties.reduce((acc, property) => {\n const extendedOperators = (property?.operators ?? []).reduce(\n (acc, operator) => (typeof operator === 'object' ? acc.set(operator.operator, operator) : acc),\n new Map<PropertyFilterOperator, null | ExtendedOperator<any>>()\n );\n acc.set(property.key, {\n propertyKey: property.key,\n propertyLabel: property?.propertyLabel ?? '',\n groupValuesLabel: property?.groupValuesLabel ?? '',\n propertyGroup: property?.group,\n operators: (property?.operators ?? []).map(op => (typeof op === 'string' ? op : op.operator)),\n defaultOperator: property?.defaultOperator ?? '=',\n getValueFormatter: operator => (operator ? extendedOperators.get(operator)?.format ?? null : null),\n getValueFormRenderer: operator => (operator ? extendedOperators.get(operator)?.form ?? null : null),\n externalProperty: property,\n });\n return acc;\n }, new Map<string, InternalFilteringProperty>());\n const getProperty = (propertyKey: string): null | InternalFilteringProperty =>\n propertyByKey.get(propertyKey) ?? null;\n\n const internalOptions: readonly InternalFilteringOption[] = filteringOptions.map(option => ({\n property: getProperty(option.propertyKey),\n value: option.value,\n label: option.label ?? option.value ?? '',\n }));\n\n function transformToken(\n tokenOrGroup: Token | TokenGroup,\n standaloneIndex?: number\n ): InternalToken | InternalTokenGroup {\n return 'operation' in tokenOrGroup\n ? {\n operation: tokenOrGroup.operation,\n tokens: tokenOrGroup.tokens.map(token => transformToken(token)),\n }\n : {\n standaloneIndex,\n property: tokenOrGroup.propertyKey ? getProperty(tokenOrGroup.propertyKey) : null,\n operator: tokenOrGroup.operator,\n value: tokenOrGroup.value,\n };\n }\n\n const internalQuery: InternalQuery = {\n operation: query.operation,\n tokens: (enableTokenGroups && query.tokenGroups ? query.tokenGroups : query.tokens).map(transformToken),\n };\n\n const internalFreeText: InternalFreeTextFiltering = {\n disabled: disableFreeTextFiltering,\n operators: freeTextFiltering?.operators ?? [':', '!:'],\n defaultOperator: freeTextFiltering?.defaultOperator ?? ':',\n };\n\n return { internalProperties: [...propertyByKey.values()], internalOptions, internalQuery, internalFreeText };\n })();\n\n const { addToken, updateToken, updateOperation, removeToken, removeAllTokens } = getQueryActions({\n query: internalQuery,\n filteringOptions: internalOptions,\n onChange,\n enableTokenGroups,\n });\n\n const parsedText = parseText(filteringText, internalProperties, internalFreeText);\n const autosuggestOptions = getAutosuggestOptions(\n parsedText,\n internalProperties,\n internalOptions,\n customGroupsText,\n i18nStrings\n );\n\n const createToken = (currentText: string) => {\n const parsedText = parseText(currentText, internalProperties, internalFreeText);\n let newToken: InternalToken;\n switch (parsedText.step) {\n case 'property': {\n newToken = {\n property: parsedText.property,\n operator: parsedText.operator,\n value: parsedText.value,\n };\n break;\n }\n case 'free-text': {\n newToken = {\n property: null,\n operator: parsedText.operator || internalFreeText.defaultOperator,\n value: parsedText.value,\n };\n break;\n }\n case 'operator': {\n newToken = {\n property: null,\n operator: internalFreeText.defaultOperator,\n value: currentText,\n };\n break;\n }\n }\n if (internalFreeText.disabled && !newToken.property) {\n return;\n }\n addToken(newToken);\n setFilteringText('');\n };\n const getLoadMoreDetail = (parsedText: ParsedText, filteringText: string) => {\n const loadMoreDetail: {\n filteringProperty: FilteringProperty | undefined;\n filteringText: string;\n filteringOperator: ComparisonOperator | undefined;\n } = {\n filteringProperty: undefined,\n filteringText,\n filteringOperator: undefined,\n };\n if (parsedText.step === 'property') {\n loadMoreDetail.filteringProperty = parsedText.property.externalProperty;\n loadMoreDetail.filteringText = parsedText.value;\n loadMoreDetail.filteringOperator = parsedText.operator;\n }\n return loadMoreDetail;\n };\n const loadMoreDetail = getLoadMoreDetail(parsedText, filteringText);\n const inputLoadItemsHandlers = useLoadItems(\n onLoadItems,\n loadMoreDetail.filteringText,\n loadMoreDetail.filteringProperty,\n loadMoreDetail.filteringText,\n loadMoreDetail.filteringOperator\n );\n const asyncProps = {\n empty: filteringEmpty,\n loadingText: filteringLoadingText,\n finishedText: filteringFinishedText,\n errorText: filteringErrorText,\n recoveryText: filteringRecoveryText,\n statusType: filteringStatusType,\n };\n const asyncAutosuggestProps =\n !!filteringText.length || asyncProperties\n ? {\n ...inputLoadItemsHandlers,\n ...asyncProps,\n }\n : {};\n const handleSelected: PropertyFilterAutosuggestProps['onOptionClick'] = event => {\n const { detail: option } = event;\n const value = option.value || '';\n if (!value) {\n return;\n }\n\n if (!('keepOpenOnSelect' in option)) {\n createToken(value);\n return;\n }\n\n // stop dropdown from closing\n event.preventDefault();\n\n const parsedText = parseText(value, internalProperties, internalFreeText);\n const loadMoreDetail = getLoadMoreDetail(parsedText, value);\n\n // Insert operator automatically if only one operator is defined for the given property.\n if (parsedText.step === 'operator') {\n const operators = getAllowedOperators(parsedText.property);\n if (value.trim() === parsedText.property.propertyLabel && operators.length === 1) {\n loadMoreDetail.filteringProperty = parsedText.property.externalProperty ?? undefined;\n loadMoreDetail.filteringOperator = operators[0];\n loadMoreDetail.filteringText = '';\n setFilteringText(parsedText.property.propertyLabel + ' ' + operators[0] + ' ');\n }\n }\n\n fireNonCancelableEvent(onLoadItems, { ...loadMoreDetail, firstPage: true, samePage: false });\n };\n\n const propertyStep = parsedText.step === 'property' ? parsedText : null;\n const customValueKey = propertyStep ? propertyStep.property.propertyKey + ':' + propertyStep.operator : '';\n const [customFormValueRecord, setCustomFormValueRecord] = useState<Record<string, any>>({});\n const customFormValue = customValueKey in customFormValueRecord ? customFormValueRecord[customValueKey] : null;\n const setCustomFormValue = (value: null | any) => setCustomFormValueRecord({ [customValueKey]: value });\n const operatorForm = propertyStep && propertyStep.property.getValueFormRenderer(propertyStep.operator);\n\n const searchResultsId = useUniqueId('property-filter-search-results');\n const constraintTextId = useUniqueId('property-filter-constraint');\n const textboxAriaDescribedBy = filteringConstraintText\n ? joinStrings(rest.ariaDescribedby, constraintTextId)\n : rest.ariaDescribedby;\n\n const showResults = !!internalQuery.tokens?.length && !disabled && !!countText;\n\n return (\n <div {...baseProps} className={clsx(baseProps.className, styles.root)} ref={mergedRef}>\n <div className={clsx(styles['search-field'], analyticsSelectors['search-field'])}>\n {customControl && <div className={styles['custom-control']}>{customControl}</div>}\n <div className={styles['input-wrapper']}>\n <PropertyFilterAutosuggest\n ref={inputRef}\n virtualScroll={virtualScroll}\n enteredTextLabel={i18nStrings.enteredTextLabel}\n ariaLabel={filteringAriaLabel ?? i18nStrings.filteringAriaLabel}\n placeholder={filteringPlaceholder ?? i18nStrings.filteringPlaceholder}\n ariaLabelledby={rest.ariaLabelledby}\n ariaDescribedby={textboxAriaDescribedBy}\n controlId={rest.controlId}\n value={filteringText}\n disabled={disabled}\n {...autosuggestOptions}\n onChange={event => setFilteringText(event.detail.value)}\n empty={filteringEmpty}\n {...asyncAutosuggestProps}\n expandToViewport={expandToViewport}\n onOptionClick={handleSelected}\n customForm={\n operatorForm\n ? {\n content: (\n <PropertyEditorContent\n key={customValueKey}\n property={propertyStep.property}\n operator={propertyStep.operator}\n filter={propertyStep.value}\n operatorForm={operatorForm}\n value={customFormValue}\n onChange={setCustomFormValue}\n />\n ),\n footer: (\n <PropertyEditorFooter\n key={customValueKey}\n property={propertyStep.property}\n operator={propertyStep.operator}\n value={customFormValue}\n i18nStrings={i18nStrings}\n onCancel={() => {\n setFilteringText('');\n inputRef.current?.close();\n inputRef.current?.focus({ preventDropdown: true });\n }}\n onSubmit={token => {\n addToken(token);\n setFilteringText('');\n inputRef.current?.focus({ preventDropdown: true });\n inputRef.current?.close();\n }}\n />\n ),\n }\n : undefined\n }\n onCloseDropdown={() => setCustomFormValueRecord({})}\n hideEnteredTextOption={internalFreeText.disabled && parsedText.step !== 'property'}\n clearAriaLabel={i18nStrings.clearAriaLabel}\n searchResultsId={showResults ? searchResultsId : undefined}\n />\n {showResults ? (\n <div className={styles.results}>\n <SearchResults id={searchResultsId}>{countText}</SearchResults>\n </div>\n ) : null}\n </div>\n </div>\n {filteringConstraintText && (\n <div id={constraintTextId} className={styles.constraint}>\n {filteringConstraintText}\n </div>\n )}\n {internalQuery.tokens && internalQuery.tokens.length > 0 && (\n <div className={styles.tokens}>\n <InternalSpaceBetween size=\"xs\" direction=\"horizontal\">\n <TokenList\n alignment=\"inline\"\n limit={tokenLimit}\n items={internalQuery.tokens}\n limitShowFewerAriaLabel={tokenLimitShowFewerAriaLabel}\n limitShowMoreAriaLabel={tokenLimitShowMoreAriaLabel}\n renderItem={(_, tokenIndex) => (\n <TokenButton\n query={internalQuery}\n tokenIndex={tokenIndex}\n onUpdateToken={(token, releasedTokens) => {\n updateToken(tokenIndex, token, releasedTokens);\n }}\n onUpdateOperation={updateOperation}\n onRemoveToken={() => {\n removeToken(tokenIndex);\n setNextFocusIndex(tokenIndex);\n }}\n filteringProperties={internalProperties}\n filteringOptions={internalOptions}\n asyncProps={asyncProps}\n onLoadItems={onLoadItems}\n i18nStrings={i18nStrings}\n asyncProperties={asyncProperties}\n hideOperations={hideOperations}\n customGroupsText={customGroupsText}\n freeTextFiltering={internalFreeText}\n disabled={disabled}\n expandToViewport={expandToViewport}\n enableTokenGroups={enableTokenGroups}\n />\n )}\n i18nStrings={{\n limitShowFewer: i18nStrings.tokenLimitShowFewer,\n limitShowMore: i18nStrings.tokenLimitShowMore,\n }}\n after={\n customFilterActions ? (\n <div className={styles['custom-filter-actions']}>{customFilterActions}</div>\n ) : (\n <span\n {...getAnalyticsMetadataAttribute({\n action: 'clearFilters',\n } as Partial<GeneratedAnalyticsMetadataPropertyFilterClearFilters>)}\n >\n <InternalButton\n formAction=\"none\"\n onClick={() => {\n removeAllTokens();\n inputRef.current?.focus({ preventDropdown: true });\n }}\n className={styles['remove-all']}\n disabled={disabled}\n >\n {i18nStrings.clearFiltersText}\n </InternalButton>\n </span>\n )\n }\n />\n </InternalSpaceBetween>\n </div>\n )}\n </div>\n );\n }\n);\n\nexport default PropertyFilterInternal;\n"]}
|
|
1
|
+
{"version":3,"file":"internal.js","sourceRoot":"","sources":["../../../src/property-filter/internal.tsx"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,sCAAsC;AACtC,OAAO,KAAK,EAAE,EAAE,mBAAmB,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrE,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D,mBAAmB,EAAE,kBAAkB,EACvC,gBAAgB,EAAE,eAAe,EACjC,UAAU,EAAE,UAAU,EACtB,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,WAAW,EACxB,eAAe,EAAE,eAAe,EAChC,cAAc,EAAE,cAAc,EAC9B,gBAAgB,EAAE,gBAAgB,EAClC,iBAAiB,EAAE,gBAAgB,EACnC,QAAQ,EAAE,QAAQ,EAClB,gBAAgB,EAAE,gBAAgB,EAClC,iBAAiB,EAAE,iBAAiB,GACpC,CACH,EACD,WAAW,EAAE;wBACX,cAAc,EAAE,WAAW,CAAC,mBAAmB;wBAC/C,aAAa,EAAE,WAAW,CAAC,kBAAkB;qBAC9C,EACD,KAAK,EACH,mBAAmB,CAAC,CAAC,CAAC,CACpB,6BAAK,SAAS,EAAE,MAAM,CAAC,uBAAuB,CAAC,IAAG,mBAAmB,CAAO,CAC7E,CAAC,CAAC,CAAC,CACF,8CACM,6BAA6B,CAAC;wBAChC,MAAM,EAAE,cAAc;qBAC0C,CAAC;wBAEnE,oBAAC,cAAc,IACb,UAAU,EAAC,MAAM,EACjB,OAAO,EAAE,GAAG,EAAE;;gCACZ,eAAe,EAAE,CAAC;gCAClB,MAAA,QAAQ,CAAC,OAAO,0CAAE,KAAK,CAAC,EAAE,eAAe,EAAE,IAAI,EAAE,CAAC,CAAC;4BACrD,CAAC,EACD,SAAS,EAAE,MAAM,CAAC,YAAY,CAAC,EAC/B,QAAQ,EAAE,QAAQ,IAEjB,WAAW,CAAC,gBAAgB,CACd,CACZ,CACR,GAEH,CACmB,CACnB,CACP,CACG,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,sBAAsB,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { useImperativeHandle, useRef, useState } from 'react';\nimport clsx from 'clsx';\n\nimport { PropertyFilterOperator } from '@cloudscape-design/collection-hooks';\nimport { getAnalyticsMetadataAttribute } from '@cloudscape-design/component-toolkit/internal/analytics-metadata';\n\nimport { InternalButton } from '../button/internal';\nimport { getBaseProps } from '../internal/base-component';\nimport { AutosuggestInputRef } from '../internal/components/autosuggest-input';\nimport TokenList from '../internal/components/token-list';\nimport { fireNonCancelableEvent } from '../internal/events';\nimport { InternalBaseComponentProps } from '../internal/hooks/use-base-component';\nimport { useListFocusController } from '../internal/hooks/use-list-focus-controller';\nimport { useMergeRefs } from '../internal/hooks/use-merge-refs';\nimport { useUniqueId } from '../internal/hooks/use-unique-id/index';\nimport { SomeRequired } from '../internal/types';\nimport { joinStrings } from '../internal/utils/strings';\nimport InternalSpaceBetween from '../space-between/internal';\nimport { SearchResults } from '../text-filter/search-results';\nimport { GeneratedAnalyticsMetadataPropertyFilterClearFilters } from './analytics-metadata/interfaces';\nimport { getAllowedOperators, getAutosuggestOptions, getQueryActions, parseText } from './controller';\nimport { usePropertyFilterI18n } from './i18n-utils';\nimport {\n ComparisonOperator,\n ExtendedOperator,\n FilteringProperty,\n InternalFilteringOption,\n InternalFilteringProperty,\n InternalFreeTextFiltering,\n InternalQuery,\n InternalToken,\n InternalTokenGroup,\n ParsedText,\n PropertyFilterProps,\n Ref,\n Token,\n TokenGroup,\n} from './interfaces';\nimport { PropertyEditorContentCustom, PropertyEditorContentEnum, PropertyEditorFooter } from './property-editor';\nimport PropertyFilterAutosuggest, { PropertyFilterAutosuggestProps } from './property-filter-autosuggest';\nimport { TokenButton } from './token';\nimport { useLoadItems } from './use-load-items';\n\nimport tokenListStyles from '../internal/components/token-list/styles.css.js';\nimport analyticsSelectors from './analytics-metadata/styles.css.js';\nimport styles from './styles.css.js';\n\nexport type PropertyFilterInternalProps = SomeRequired<\n PropertyFilterProps,\n 'filteringOptions' | 'customGroupsText' | 'enableTokenGroups' | 'disableFreeTextFiltering' | 'hideOperations'\n> &\n InternalBaseComponentProps;\n\nconst PropertyFilterInternal = React.forwardRef(\n (\n {\n disabled,\n countText,\n query,\n hideOperations,\n onChange,\n filteringProperties,\n filteringOptions,\n customGroupsText,\n disableFreeTextFiltering,\n freeTextFiltering,\n onLoadItems,\n virtualScroll,\n customControl,\n customFilterActions,\n filteringPlaceholder,\n filteringAriaLabel,\n filteringEmpty,\n filteringLoadingText,\n filteringFinishedText,\n filteringErrorText,\n filteringRecoveryText,\n filteringConstraintText,\n filteringStatusType,\n asyncProperties,\n tokenLimit,\n expandToViewport,\n tokenLimitShowFewerAriaLabel,\n tokenLimitShowMoreAriaLabel,\n enableTokenGroups,\n __internalRootRef,\n ...rest\n }: PropertyFilterInternalProps,\n ref: React.Ref<Ref>\n ) => {\n const [nextFocusIndex, setNextFocusIndex] = useState<null | number>(null);\n const tokenListRef = useListFocusController({\n nextFocusIndex,\n onFocusMoved: (target, targetType) => {\n if (targetType === 'fallback') {\n inputRef.current?.focus({ preventDropdown: true });\n } else {\n target.focus();\n }\n setNextFocusIndex(null);\n },\n listItemSelector: `.${tokenListStyles['list-item']}`,\n showMoreSelector: `.${tokenListStyles.toggle}`,\n fallbackSelector: `.${styles.input}`,\n });\n\n const mergedRef = useMergeRefs(tokenListRef, __internalRootRef);\n const inputRef = useRef<AutosuggestInputRef>(null);\n const baseProps = getBaseProps(rest);\n\n const i18nStrings = usePropertyFilterI18n(rest.i18nStrings);\n\n useImperativeHandle(ref, () => ({ focus: () => inputRef.current?.focus() }), []);\n const [filteringText, setFilteringText] = useState<string>('');\n\n const { internalProperties, internalOptions, internalQuery, internalFreeText } = (() => {\n const propertyByKey = filteringProperties.reduce((acc, property) => {\n const extendedOperators = (property?.operators ?? []).reduce(\n (acc, operator) => (typeof operator === 'object' ? acc.set(operator.operator, operator) : acc),\n new Map<PropertyFilterOperator, null | ExtendedOperator<any>>()\n );\n acc.set(property.key, {\n propertyKey: property.key,\n propertyLabel: property?.propertyLabel ?? '',\n groupValuesLabel: property?.groupValuesLabel ?? '',\n propertyGroup: property?.group,\n operators: (property?.operators ?? []).map(op => (typeof op === 'string' ? op : op.operator)),\n defaultOperator: property?.defaultOperator ?? '=',\n getTokenType: operator => (operator ? extendedOperators.get(operator)?.tokenType ?? 'value' : 'value'),\n getValueFormatter: operator => (operator ? extendedOperators.get(operator)?.format ?? null : null),\n getValueFormRenderer: operator => (operator ? extendedOperators.get(operator)?.form ?? null : null),\n externalProperty: property,\n });\n return acc;\n }, new Map<string, InternalFilteringProperty>());\n const getProperty = (propertyKey: string): null | InternalFilteringProperty =>\n propertyByKey.get(propertyKey) ?? null;\n\n const internalOptions: readonly InternalFilteringOption[] = filteringOptions.map(option => ({\n property: getProperty(option.propertyKey),\n value: option.value,\n label: option.label ?? option.value ?? '',\n }));\n\n function transformToken(\n tokenOrGroup: Token | TokenGroup,\n standaloneIndex?: number\n ): InternalToken | InternalTokenGroup {\n return 'operation' in tokenOrGroup\n ? {\n operation: tokenOrGroup.operation,\n tokens: tokenOrGroup.tokens.map(token => transformToken(token)),\n }\n : {\n standaloneIndex,\n property: tokenOrGroup.propertyKey ? getProperty(tokenOrGroup.propertyKey) : null,\n operator: tokenOrGroup.operator,\n value: tokenOrGroup.value,\n };\n }\n\n const internalQuery: InternalQuery = {\n operation: query.operation,\n tokens: (enableTokenGroups && query.tokenGroups ? query.tokenGroups : query.tokens).map(transformToken),\n };\n\n const internalFreeText: InternalFreeTextFiltering = {\n disabled: disableFreeTextFiltering,\n operators: freeTextFiltering?.operators ?? [':', '!:'],\n defaultOperator: freeTextFiltering?.defaultOperator ?? ':',\n };\n\n return { internalProperties: [...propertyByKey.values()], internalOptions, internalQuery, internalFreeText };\n })();\n\n const { addToken, updateToken, updateOperation, removeToken, removeAllTokens } = getQueryActions({\n query: internalQuery,\n filteringOptions: internalOptions,\n onChange,\n enableTokenGroups,\n });\n\n const parsedText = parseText(filteringText, internalProperties, internalFreeText);\n const autosuggestOptions = getAutosuggestOptions(\n parsedText,\n internalProperties,\n internalOptions,\n customGroupsText,\n i18nStrings\n );\n\n const createToken = (currentText: string) => {\n const parsedText = parseText(currentText, internalProperties, internalFreeText);\n let newToken: InternalToken;\n switch (parsedText.step) {\n case 'property': {\n newToken = {\n property: parsedText.property,\n operator: parsedText.operator,\n value: parsedText.value,\n };\n break;\n }\n case 'free-text': {\n newToken = {\n property: null,\n operator: parsedText.operator || internalFreeText.defaultOperator,\n value: parsedText.value,\n };\n break;\n }\n case 'operator': {\n newToken = {\n property: null,\n operator: internalFreeText.defaultOperator,\n value: currentText,\n };\n break;\n }\n }\n if (internalFreeText.disabled && !newToken.property) {\n return;\n }\n addToken(newToken);\n setFilteringText('');\n };\n const getLoadMoreDetail = (parsedText: ParsedText, filteringText: string) => {\n const loadMoreDetail: {\n filteringProperty: FilteringProperty | undefined;\n filteringText: string;\n filteringOperator: ComparisonOperator | undefined;\n } = {\n filteringProperty: undefined,\n filteringText,\n filteringOperator: undefined,\n };\n if (parsedText.step === 'property') {\n loadMoreDetail.filteringProperty = parsedText.property.externalProperty;\n loadMoreDetail.filteringText = parsedText.value;\n loadMoreDetail.filteringOperator = parsedText.operator;\n }\n return loadMoreDetail;\n };\n const loadMoreDetail = getLoadMoreDetail(parsedText, filteringText);\n const inputLoadItemsHandlers = useLoadItems(\n onLoadItems,\n loadMoreDetail.filteringText,\n loadMoreDetail.filteringProperty,\n loadMoreDetail.filteringText,\n loadMoreDetail.filteringOperator\n );\n const asyncProps = {\n empty: filteringEmpty,\n loadingText: filteringLoadingText,\n finishedText: filteringFinishedText,\n errorText: filteringErrorText,\n recoveryText: filteringRecoveryText,\n statusType: filteringStatusType,\n };\n const asyncAutosuggestProps =\n !!filteringText.length || asyncProperties\n ? {\n ...inputLoadItemsHandlers,\n ...asyncProps,\n }\n : {};\n const handleSelected: PropertyFilterAutosuggestProps['onOptionClick'] = event => {\n const { detail: option } = event;\n const value = option.value || '';\n if (!value) {\n return;\n }\n\n if (!('keepOpenOnSelect' in option)) {\n createToken(value);\n return;\n }\n\n // stop dropdown from closing\n event.preventDefault();\n\n const parsedText = parseText(value, internalProperties, internalFreeText);\n const loadMoreDetail = getLoadMoreDetail(parsedText, value);\n\n // Insert operator automatically if only one operator is defined for the given property.\n if (parsedText.step === 'operator') {\n const operators = getAllowedOperators(parsedText.property);\n if (value.trim() === parsedText.property.propertyLabel && operators.length === 1) {\n loadMoreDetail.filteringProperty = parsedText.property.externalProperty ?? undefined;\n loadMoreDetail.filteringOperator = operators[0];\n loadMoreDetail.filteringText = '';\n setFilteringText(parsedText.property.propertyLabel + ' ' + operators[0] + ' ');\n }\n }\n\n fireNonCancelableEvent(onLoadItems, { ...loadMoreDetail, firstPage: true, samePage: false });\n };\n\n const propertyStep = parsedText.step === 'property' ? parsedText : null;\n const customValueKey = propertyStep ? propertyStep.property.propertyKey + ':' + propertyStep.operator : '';\n const [customFormValueRecord, setCustomFormValueRecord] = useState<Record<string, any>>({});\n const customFormValue = customValueKey in customFormValueRecord ? customFormValueRecord[customValueKey] : null;\n const setCustomFormValue = (value: null | any) => setCustomFormValueRecord({ [customValueKey]: value });\n const operatorForm = propertyStep && propertyStep.property.getValueFormRenderer(propertyStep.operator);\n const isEnumValue = propertyStep?.property.getTokenType(propertyStep.operator) === 'enum';\n\n const searchResultsId = useUniqueId('property-filter-search-results');\n const constraintTextId = useUniqueId('property-filter-constraint');\n const textboxAriaDescribedBy = filteringConstraintText\n ? joinStrings(rest.ariaDescribedby, constraintTextId)\n : rest.ariaDescribedby;\n\n const showResults = !!internalQuery.tokens?.length && !disabled && !!countText;\n\n return (\n <div {...baseProps} className={clsx(baseProps.className, styles.root)} ref={mergedRef}>\n <div className={clsx(styles['search-field'], analyticsSelectors['search-field'])}>\n {customControl && <div className={styles['custom-control']}>{customControl}</div>}\n <div className={styles['input-wrapper']}>\n <PropertyFilterAutosuggest\n ref={inputRef}\n virtualScroll={virtualScroll}\n enteredTextLabel={i18nStrings.enteredTextLabel}\n ariaLabel={filteringAriaLabel ?? i18nStrings.filteringAriaLabel}\n placeholder={filteringPlaceholder ?? i18nStrings.filteringPlaceholder}\n ariaLabelledby={rest.ariaLabelledby}\n ariaDescribedby={textboxAriaDescribedBy}\n controlId={rest.controlId}\n value={filteringText}\n disabled={disabled}\n {...autosuggestOptions}\n onChange={event => setFilteringText(event.detail.value)}\n empty={filteringEmpty}\n {...asyncAutosuggestProps}\n expandToViewport={expandToViewport}\n onOptionClick={handleSelected}\n customForm={\n operatorForm || isEnumValue\n ? {\n content: operatorForm ? (\n <PropertyEditorContentCustom\n key={customValueKey}\n property={propertyStep.property}\n operator={propertyStep.operator}\n filter={propertyStep.value}\n operatorForm={operatorForm}\n value={customFormValue}\n onChange={setCustomFormValue}\n />\n ) : (\n <PropertyEditorContentEnum\n key={customValueKey}\n property={propertyStep.property}\n filter={propertyStep.value}\n value={customFormValue}\n onChange={setCustomFormValue}\n asyncProps={asyncProps}\n filteringOptions={internalOptions}\n onLoadItems={inputLoadItemsHandlers.onLoadItems}\n />\n ),\n footer: (\n <PropertyEditorFooter\n key={customValueKey}\n property={propertyStep.property}\n operator={propertyStep.operator}\n value={customFormValue}\n i18nStrings={i18nStrings}\n onCancel={() => {\n setFilteringText('');\n inputRef.current?.close();\n inputRef.current?.focus({ preventDropdown: true });\n }}\n onSubmit={token => {\n addToken(token);\n setFilteringText('');\n inputRef.current?.focus({ preventDropdown: true });\n inputRef.current?.close();\n }}\n />\n ),\n }\n : undefined\n }\n onCloseDropdown={() => setCustomFormValueRecord({})}\n hideEnteredTextOption={internalFreeText.disabled && parsedText.step !== 'property'}\n clearAriaLabel={i18nStrings.clearAriaLabel}\n searchResultsId={showResults ? searchResultsId : undefined}\n />\n {showResults ? (\n <div className={styles.results}>\n <SearchResults id={searchResultsId}>{countText}</SearchResults>\n </div>\n ) : null}\n </div>\n </div>\n {filteringConstraintText && (\n <div id={constraintTextId} className={styles.constraint}>\n {filteringConstraintText}\n </div>\n )}\n {internalQuery.tokens && internalQuery.tokens.length > 0 && (\n <div className={styles.tokens}>\n <InternalSpaceBetween size=\"xs\" direction=\"horizontal\">\n <TokenList\n alignment=\"inline\"\n limit={tokenLimit}\n items={internalQuery.tokens}\n limitShowFewerAriaLabel={tokenLimitShowFewerAriaLabel}\n limitShowMoreAriaLabel={tokenLimitShowMoreAriaLabel}\n renderItem={(_, tokenIndex) => (\n <TokenButton\n query={internalQuery}\n tokenIndex={tokenIndex}\n onUpdateToken={(token, releasedTokens) => {\n updateToken(tokenIndex, token, releasedTokens);\n }}\n onUpdateOperation={updateOperation}\n onRemoveToken={() => {\n removeToken(tokenIndex);\n setNextFocusIndex(tokenIndex);\n }}\n filteringProperties={internalProperties}\n filteringOptions={internalOptions}\n asyncProps={asyncProps}\n onLoadItems={onLoadItems}\n i18nStrings={i18nStrings}\n asyncProperties={asyncProperties}\n hideOperations={hideOperations}\n customGroupsText={customGroupsText}\n freeTextFiltering={internalFreeText}\n disabled={disabled}\n expandToViewport={expandToViewport}\n enableTokenGroups={enableTokenGroups}\n />\n )}\n i18nStrings={{\n limitShowFewer: i18nStrings.tokenLimitShowFewer,\n limitShowMore: i18nStrings.tokenLimitShowMore,\n }}\n after={\n customFilterActions ? (\n <div className={styles['custom-filter-actions']}>{customFilterActions}</div>\n ) : (\n <span\n {...getAnalyticsMetadataAttribute({\n action: 'clearFilters',\n } as Partial<GeneratedAnalyticsMetadataPropertyFilterClearFilters>)}\n >\n <InternalButton\n formAction=\"none\"\n onClick={() => {\n removeAllTokens();\n inputRef.current?.focus({ preventDropdown: true });\n }}\n className={styles['remove-all']}\n disabled={disabled}\n >\n {i18nStrings.clearFiltersText}\n </InternalButton>\n </span>\n )\n }\n />\n </InternalSpaceBetween>\n </div>\n )}\n </div>\n );\n }\n);\n\nexport default PropertyFilterInternal;\n"]}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import { DropdownStatusProps } from '../internal/components/dropdown-status';
|
|
3
|
+
import { NonCancelableEventHandler } from '../internal/events';
|
|
2
4
|
import { I18nStringsInternal } from './i18n-utils';
|
|
3
|
-
import { ComparisonOperator, ExtendedOperatorForm, InternalFilteringProperty, InternalToken } from './interfaces';
|
|
4
|
-
export declare function
|
|
5
|
+
import { ComparisonOperator, ExtendedOperatorForm, InternalFilteringOption, InternalFilteringProperty, InternalToken, LoadItemsDetail } from './interfaces';
|
|
6
|
+
export declare function PropertyEditorContentCustom<TokenValue = any>({ property, operator, filter, value, onChange, operatorForm, }: {
|
|
5
7
|
property: InternalFilteringProperty;
|
|
6
8
|
operator: ComparisonOperator;
|
|
7
9
|
filter: string;
|
|
@@ -9,6 +11,15 @@ export declare function PropertyEditorContent<TokenValue = any>({ property, oper
|
|
|
9
11
|
onChange: (value: null | TokenValue) => void;
|
|
10
12
|
operatorForm: ExtendedOperatorForm<TokenValue>;
|
|
11
13
|
}): JSX.Element;
|
|
14
|
+
export declare function PropertyEditorContentEnum({ property, filter, value: unknownValue, onChange, asyncProps, filteringOptions, onLoadItems, }: {
|
|
15
|
+
property: InternalFilteringProperty;
|
|
16
|
+
filter: string;
|
|
17
|
+
value: unknown;
|
|
18
|
+
onChange: (value: null | string[]) => void;
|
|
19
|
+
asyncProps: DropdownStatusProps;
|
|
20
|
+
filteringOptions: readonly InternalFilteringOption[];
|
|
21
|
+
onLoadItems?: NonCancelableEventHandler<LoadItemsDetail>;
|
|
22
|
+
}): JSX.Element;
|
|
12
23
|
export declare function PropertyEditorFooter<TokenValue = any>({ property, operator, value, onCancel, onSubmit, i18nStrings, }: {
|
|
13
24
|
property: InternalFilteringProperty;
|
|
14
25
|
operator: ComparisonOperator;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"property-editor.d.ts","sourceRoot":"","sources":["../../../src/property-filter/property-editor.tsx"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"property-editor.d.ts","sourceRoot":"","sources":["../../../src/property-filter/property-editor.tsx"],"names":[],"mappings":";AAQA,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAC;AAE7E,OAAO,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AAI/D,OAAO,EAAE,mBAAmB,EAAE,MA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UAAU,CAAC;IACzB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IACzC,WAAW,EAAE,mBAAmB,CAAC;CAClC,eAgBA"}
|
|
@@ -3,17 +3,35 @@
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import InternalButton from '../button/internal';
|
|
6
|
+
import InternalCheckbox from '../checkbox/internal';
|
|
6
7
|
import { FormFieldContext } from '../internal/context/form-field-context';
|
|
7
8
|
import { useUniqueId } from '../internal/hooks/use-unique-id';
|
|
9
|
+
import EmbeddedMultiselect from '../multiselect/embedded';
|
|
10
|
+
import { filterOptions } from './filter-options';
|
|
11
|
+
import { useLoadItems } from './use-load-items';
|
|
8
12
|
import styles from './styles.css.js';
|
|
9
13
|
import testUtilStyles from './test-classes/styles.css.js';
|
|
10
|
-
export function
|
|
14
|
+
export function PropertyEditorContentCustom({ property, operator, filter, value, onChange, operatorForm, }) {
|
|
11
15
|
const labelId = useUniqueId();
|
|
12
16
|
return (React.createElement("div", { className: styles['property-editor'] },
|
|
13
17
|
React.createElement("div", { className: styles['property-editor-header'], id: labelId }, property.groupValuesLabel),
|
|
14
18
|
React.createElement("div", { className: styles['property-editor-form'] },
|
|
15
19
|
React.createElement(FormFieldContext.Provider, { value: { ariaLabelledby: labelId } }, operatorForm({ value, onChange, operator, filter })))));
|
|
16
20
|
}
|
|
21
|
+
export function PropertyEditorContentEnum({ property, filter, value: unknownValue, onChange, asyncProps, filteringOptions, onLoadItems, }) {
|
|
22
|
+
const valueOptions = filteringOptions
|
|
23
|
+
.filter(option => { var _a; return ((_a = option.property) === null || _a === void 0 ? void 0 : _a.propertyKey) === property.propertyKey; })
|
|
24
|
+
.map(({ label, value }) => ({ label, value }));
|
|
25
|
+
const valueHandlers = useLoadItems(onLoadItems, '', property.externalProperty);
|
|
26
|
+
const value = !unknownValue ? [] : Array.isArray(unknownValue) ? unknownValue : [unknownValue];
|
|
27
|
+
const selectedOptions = valueOptions.filter(option => value.includes(option.value));
|
|
28
|
+
const filteredOptions = filterOptions(valueOptions, filter);
|
|
29
|
+
return (React.createElement("div", { className: clsx(styles['property-editor'], styles['property-editor-enum']) },
|
|
30
|
+
filteredOptions.length === 0 && (React.createElement("div", { className: styles['property-editor-header-enum'] },
|
|
31
|
+
React.createElement(InternalCheckbox, { checked: false, readOnly: true }),
|
|
32
|
+
property.groupValuesLabel)),
|
|
33
|
+
React.createElement(EmbeddedMultiselect, Object.assign({ filteringType: "manual", selectedOptions: selectedOptions, onChange: e => onChange(e.detail.selectedOptions.map(o => o.value)), options: filteredOptions.length > 0 ? [{ options: filteredOptions, label: property.groupValuesLabel }] : [], filteringText: filter, ariaLabel: property.groupValuesLabel, statusType: "finished", noMatch: asyncProps.empty }, valueHandlers, asyncProps))));
|
|
34
|
+
}
|
|
17
35
|
export function PropertyEditorFooter({ property, operator, value, onCancel, onSubmit, i18nStrings, }) {
|
|
18
36
|
const submitToken = () => onSubmit({ property, operator, value });
|
|
19
37
|
return (React.createElement("div", { className: styles['property-editor-actions'] },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"property-editor.js","sourceRoot":"","sources":["../../../src/property-filter/property-editor.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,cAAc,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;
|
|
1
|
+
{"version":3,"file":"property-editor.js","sourceRoot":"","sources":["../../../src/property-filter/property-editor.tsx"],"names":[],"mappings":"AAAA,qEAAqE;AACrE,sCAAsC;AAEtC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,cAAc,MAAM,oBAAoB,CAAC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AC,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,KAAK,EAAE,QAAQ,CAAC,gBAAgB,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,EAC3G,aAAa,EAAE,MAAM,EACrB,SAAS,EAAE,QAAQ,CAAC,gBAAgB,EACpC,UAAU,EAAC,UAAU,EACrB,OAAO,EAAE,UAAU,CAAC,KAAK,IACrB,aAAa,EACb,UAAU,EACd,CACE,CACP,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAmB,EACrD,QAAQ,EACR,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,WAAW,GAQZ;IACC,MAAM,WAAW,GAAG,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC,CAAC;IAClE,OAAO,CACL,6BAAK,SAAS,EAAE,MAAM,CAAC,yBAAyB,CAAC;QAC/C,oBAAC,cAAc,IACb,OAAO,EAAC,MAAM,EACd,SAAS,EAAE,IAAI,CAAC,MAAM,CAAC,wBAAwB,CAAC,EAAE,cAAc,CAAC,wBAAwB,CAAC,CAAC,EAC3F,OAAO,EAAE,QAAQ,IAEhB,WAAW,CAAC,gBAAgB,CACd;QACjB,oBAAC,cAAc,IAAC,SAAS,EAAE,cAAc,CAAC,wBAAwB,CAAC,EAAE,OAAO,EAAE,WAAW,IACtF,WAAW,CAAC,eAAe,CACb,CACb,CACP,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport React from 'react';\nimport clsx from 'clsx';\n\nimport InternalButton from '../button/internal';\nimport InternalCheckbox from '../checkbox/internal';\nimport { DropdownStatusProps } from '../internal/components/dropdown-status';\nimport { FormFieldContext } from '../internal/context/form-field-context';\nimport { NonCancelableEventHandler } from '../internal/events';\nimport { useUniqueId } from '../internal/hooks/use-unique-id';\nimport EmbeddedMultiselect from '../multiselect/embedded';\nimport { filterOptions } from './filter-options';\nimport { I18nStringsInternal } from './i18n-utils';\nimport {\n ComparisonOperator,\n ExtendedOperatorForm,\n InternalFilteringOption,\n InternalFilteringProperty,\n InternalToken,\n LoadItemsDetail,\n} from './interfaces';\nimport { useLoadItems } from './use-load-items';\n\nimport styles from './styles.css.js';\nimport testUtilStyles from './test-classes/styles.css.js';\n\nexport function PropertyEditorContentCustom<TokenValue = any>({\n property,\n operator,\n filter,\n value,\n onChange,\n operatorForm,\n}: {\n property: InternalFilteringProperty;\n operator: ComparisonOperator;\n filter: string;\n value: null | TokenValue;\n onChange: (value: null | TokenValue) => void;\n operatorForm: ExtendedOperatorForm<TokenValue>;\n}) {\n const labelId = useUniqueId();\n return (\n <div className={styles['property-editor']}>\n <div className={styles['property-editor-header']} id={labelId}>\n {property.groupValuesLabel}\n </div>\n\n <div className={styles['property-editor-form']}>\n <FormFieldContext.Provider value={{ ariaLabelledby: labelId }}>\n {operatorForm({ value, onChange, operator, filter })}\n </FormFieldContext.Provider>\n </div>\n </div>\n );\n}\n\nexport function PropertyEditorContentEnum({\n property,\n filter,\n value: unknownValue,\n onChange,\n asyncProps,\n filteringOptions,\n onLoadItems,\n}: {\n property: InternalFilteringProperty;\n filter: string;\n value: unknown;\n onChange: (value: null | string[]) => void;\n asyncProps: DropdownStatusProps;\n filteringOptions: readonly InternalFilteringOption[];\n onLoadItems?: NonCancelableEventHandler<LoadItemsDetail>;\n}) {\n const valueOptions: readonly { value: string; label: string }[] = filteringOptions\n .filter(option => option.property?.propertyKey === property.propertyKey)\n .map(({ label, value }) => ({ label, value }));\n const valueHandlers = useLoadItems(onLoadItems, '', property.externalProperty);\n const value = !unknownValue ? [] : Array.isArray(unknownValue) ? unknownValue : [unknownValue];\n const selectedOptions = valueOptions.filter(option => value.includes(option.value));\n const filteredOptions = filterOptions(valueOptions, filter);\n return (\n <div className={clsx(styles['property-editor'], styles['property-editor-enum'])}>\n {filteredOptions.length === 0 && (\n <div className={styles['property-editor-header-enum']}>\n <InternalCheckbox checked={false} readOnly={true} />\n {property.groupValuesLabel}\n </div>\n )}\n\n <EmbeddedMultiselect\n filteringType=\"manual\"\n selectedOptions={selectedOptions}\n onChange={e => onChange(e.detail.selectedOptions.map(o => o.value!))}\n options={filteredOptions.length > 0 ? [{ options: filteredOptions, label: property.groupValuesLabel }] : []}\n filteringText={filter}\n ariaLabel={property.groupValuesLabel}\n statusType=\"finished\"\n noMatch={asyncProps.empty}\n {...valueHandlers}\n {...asyncProps}\n />\n </div>\n );\n}\n\nexport function PropertyEditorFooter<TokenValue = any>({\n property,\n operator,\n value,\n onCancel,\n onSubmit,\n i18nStrings,\n}: {\n property: InternalFilteringProperty;\n operator: ComparisonOperator;\n value: null | TokenValue;\n onCancel: () => void;\n onSubmit: (value: InternalToken) => void;\n i18nStrings: I18nStringsInternal;\n}) {\n const submitToken = () => onSubmit({ property, operator, value });\n return (\n <div className={styles['property-editor-actions']}>\n <InternalButton\n variant=\"link\"\n className={clsx(styles['property-editor-cancel'], testUtilStyles['property-editor-cancel'])}\n onClick={onCancel}\n >\n {i18nStrings.cancelActionText}\n </InternalButton>\n <InternalButton className={testUtilStyles['property-editor-submit']} onClick={submitToken}>\n {i18nStrings.applyActionText}\n </InternalButton>\n </div>\n );\n}\n"]}
|
|
@@ -1,40 +1,44 @@
|
|
|
1
1
|
|
|
2
2
|
import './styles.scoped.css';
|
|
3
3
|
export default {
|
|
4
|
-
"root": "
|
|
5
|
-
"search-field": "awsui_search-
|
|
6
|
-
"input-wrapper": "awsui_input-
|
|
7
|
-
"add-token": "awsui_add-
|
|
8
|
-
"tokens": "
|
|
9
|
-
"token-operator": "awsui_token-
|
|
10
|
-
"property-editor": "awsui_property-
|
|
11
|
-
"property-editor-header": "awsui_property-editor-
|
|
12
|
-
"property-editor-
|
|
13
|
-
"property-editor-
|
|
14
|
-
"property-editor-
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"token-editor
|
|
18
|
-
"token-editor-
|
|
19
|
-
"token-editor-field-
|
|
20
|
-
"token-editor-
|
|
21
|
-
"token-editor-
|
|
22
|
-
"token-editor-
|
|
23
|
-
"token-editor-
|
|
24
|
-
"token-editor-
|
|
25
|
-
"token-editor-
|
|
26
|
-
"token-editor-
|
|
27
|
-
"token-editor-grid
|
|
28
|
-
"token-editor-grid-
|
|
29
|
-
"token-editor-
|
|
30
|
-
"
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
4
|
+
"root": "awsui_root_1wzqe_13oab_141",
|
|
5
|
+
"search-field": "awsui_search-field_1wzqe_13oab_176",
|
|
6
|
+
"input-wrapper": "awsui_input-wrapper_1wzqe_13oab_183",
|
|
7
|
+
"add-token": "awsui_add-token_1wzqe_13oab_190",
|
|
8
|
+
"tokens": "awsui_tokens_1wzqe_13oab_197",
|
|
9
|
+
"token-operator": "awsui_token-operator_1wzqe_13oab_202",
|
|
10
|
+
"property-editor": "awsui_property-editor_1wzqe_13oab_206",
|
|
11
|
+
"property-editor-header": "awsui_property-editor-header_1wzqe_13oab_209",
|
|
12
|
+
"property-editor-header-enum": "awsui_property-editor-header-enum_1wzqe_13oab_222",
|
|
13
|
+
"property-editor-form": "awsui_property-editor-form_1wzqe_13oab_237",
|
|
14
|
+
"property-editor-cancel": "awsui_property-editor-cancel_1wzqe_13oab_242",
|
|
15
|
+
"property-editor-actions": "awsui_property-editor-actions_1wzqe_13oab_245",
|
|
16
|
+
"property-editor-enum": "awsui_property-editor-enum_1wzqe_13oab_253",
|
|
17
|
+
"token-editor": "awsui_token-editor_1wzqe_13oab_258",
|
|
18
|
+
"token-editor-form": "awsui_token-editor-form_1wzqe_13oab_265",
|
|
19
|
+
"token-editor-field-property": "awsui_token-editor-field-property_1wzqe_13oab_268",
|
|
20
|
+
"token-editor-field-operator": "awsui_token-editor-field-operator_1wzqe_13oab_271",
|
|
21
|
+
"token-editor-field-value": "awsui_token-editor-field-value_1wzqe_13oab_274",
|
|
22
|
+
"token-editor-multiselect-wrapper": "awsui_token-editor-multiselect-wrapper_1wzqe_13oab_277",
|
|
23
|
+
"token-editor-multiselect-wrapper-inner": "awsui_token-editor-multiselect-wrapper-inner_1wzqe_13oab_282",
|
|
24
|
+
"token-editor-cancel": "awsui_token-editor-cancel_1wzqe_13oab_286",
|
|
25
|
+
"token-editor-submit": "awsui_token-editor-submit_1wzqe_13oab_289",
|
|
26
|
+
"token-editor-actions": "awsui_token-editor-actions_1wzqe_13oab_292",
|
|
27
|
+
"token-editor-grid": "awsui_token-editor-grid_1wzqe_13oab_301",
|
|
28
|
+
"token-editor-grid-group": "awsui_token-editor-grid-group_1wzqe_13oab_338",
|
|
29
|
+
"token-editor-narrow": "awsui_token-editor-narrow_1wzqe_13oab_341",
|
|
30
|
+
"token-editor-supports-groups": "awsui_token-editor-supports-groups_1wzqe_13oab_350",
|
|
31
|
+
"token-editor-grid-header": "awsui_token-editor-grid-header_1wzqe_13oab_354",
|
|
32
|
+
"token-editor-grid-cell": "awsui_token-editor-grid-cell_1wzqe_13oab_360",
|
|
33
|
+
"token-editor-add-token": "awsui_token-editor-add-token_1wzqe_13oab_369",
|
|
34
|
+
"custom-content-wrapper": "awsui_custom-content-wrapper_1wzqe_13oab_373",
|
|
35
|
+
"custom-control": "awsui_custom-control_1wzqe_13oab_377",
|
|
36
|
+
"input": "awsui_input_1wzqe_13oab_183",
|
|
37
|
+
"results": "awsui_results_1wzqe_13oab_385",
|
|
38
|
+
"token-trigger": "awsui_token-trigger_1wzqe_13oab_390",
|
|
39
|
+
"remove-all": "awsui_remove-all_1wzqe_13oab_395",
|
|
40
|
+
"join-operation": "awsui_join-operation_1wzqe_13oab_396",
|
|
41
|
+
"custom-filter-actions": "awsui_custom-filter-actions_1wzqe_13oab_397",
|
|
42
|
+
"constraint": "awsui_constraint_1wzqe_13oab_401"
|
|
39
43
|
};
|
|
40
44
|
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
*/
|
|
139
139
|
/* Style used for links in slots/components that are text heavy, to help links stand out among
|
|
140
140
|
surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F73#description */
|
|
141
|
-
.
|
|
141
|
+
.awsui_root_1wzqe_13oab_141:not(#\9) {
|
|
142
142
|
border-collapse: separate;
|
|
143
143
|
border-spacing: 0;
|
|
144
144
|
box-sizing: border-box;
|
|
@@ -174,40 +174,40 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
174
174
|
-moz-osx-font-smoothing: auto;
|
|
175
175
|
}
|
|
176
176
|
|
|
177
|
-
.awsui_search-
|
|
177
|
+
.awsui_search-field_1wzqe_13oab_176:not(#\9) {
|
|
178
178
|
display: flex;
|
|
179
179
|
align-items: flex-end;
|
|
180
180
|
flex-wrap: wrap;
|
|
181
181
|
gap: var(--space-xs-zb16t3, 8px) var(--space-s-34lx8l, 12px);
|
|
182
182
|
}
|
|
183
183
|
|
|
184
|
-
.awsui_input-
|
|
184
|
+
.awsui_input-wrapper_1wzqe_13oab_183:not(#\9) {
|
|
185
185
|
flex-grow: 1;
|
|
186
186
|
display: flex;
|
|
187
187
|
align-items: flex-end;
|
|
188
188
|
max-inline-size: calc(688px - 2 * var(--space-l-t419sm, 20px));
|
|
189
189
|
}
|
|
190
190
|
|
|
191
|
-
.awsui_add-
|
|
191
|
+
.awsui_add-token_1wzqe_13oab_190:not(#\9) {
|
|
192
192
|
border-inline-start: 1px solid var(--color-border-divider-default-cx07f2, #c6c6cd);
|
|
193
193
|
box-sizing: border-box;
|
|
194
194
|
margin-inline-start: var(--space-m-udix3p, 16px);
|
|
195
195
|
padding-inline-start: var(--space-m-udix3p, 16px);
|
|
196
196
|
}
|
|
197
197
|
|
|
198
|
-
.
|
|
198
|
+
.awsui_tokens_1wzqe_13oab_197:not(#\9) {
|
|
199
199
|
margin-block: var(--space-xs-zb16t3, 8px);
|
|
200
200
|
margin-inline: 0;
|
|
201
201
|
}
|
|
202
202
|
|
|
203
|
-
.awsui_token-
|
|
203
|
+
.awsui_token-operator_1wzqe_13oab_202:not(#\9) {
|
|
204
204
|
font-weight: bold;
|
|
205
205
|
}
|
|
206
206
|
|
|
207
|
-
.awsui_property-
|
|
207
|
+
.awsui_property-editor_1wzqe_13oab_206:not(#\9) {
|
|
208
208
|
overflow-y: auto;
|
|
209
209
|
}
|
|
210
|
-
.awsui_property-editor-
|
|
210
|
+
.awsui_property-editor-header_1wzqe_13oab_209:not(#\9) {
|
|
211
211
|
font-size: var(--font-size-body-m-x4okxb, 14px);
|
|
212
212
|
line-height: var(--line-height-body-m-30ar75, 20px);
|
|
213
213
|
color: var(--color-text-body-default-7v1jfn, #0f141a);
|
|
@@ -220,15 +220,30 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
220
220
|
padding-block-end: var(--space-xxs-p8yyaw, 4px);
|
|
221
221
|
padding-inline: var(--space-s-34lx8l, 12px);
|
|
222
222
|
}
|
|
223
|
-
.awsui_property-editor-
|
|
223
|
+
.awsui_property-editor-header-enum_1wzqe_13oab_222:not(#\9) {
|
|
224
|
+
display: flex;
|
|
225
|
+
gap: var(--space-xs-zb16t3, 8px);
|
|
226
|
+
font-size: var(--font-size-body-m-x4okxb, 14px);
|
|
227
|
+
line-height: var(--line-height-body-m-30ar75, 20px);
|
|
228
|
+
color: var(--color-text-body-default-7v1jfn, #0f141a);
|
|
229
|
+
font-weight: 400;
|
|
230
|
+
font-family: var(--font-family-base-dnvic8, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
231
|
+
-webkit-font-smoothing: auto;
|
|
232
|
+
-moz-osx-font-smoothing: auto;
|
|
233
|
+
font-weight: bold;
|
|
234
|
+
color: var(--color-text-dropdown-group-label-iy2p4t, #424650);
|
|
235
|
+
padding-block: calc(var(--space-xs-zb16t3, 8px) + var(--border-item-width-yel47s, 2px) - var(--border-divider-list-width-27y3k5, 1px));
|
|
236
|
+
padding-inline: calc(var(--space-field-horizontal-gg19kw, 12px) + var(--border-item-width-yel47s, 2px));
|
|
237
|
+
}
|
|
238
|
+
.awsui_property-editor-form_1wzqe_13oab_237:not(#\9) {
|
|
224
239
|
padding-block-start: var(--space-xxs-p8yyaw, 4px);
|
|
225
240
|
padding-block-end: var(--space-s-34lx8l, 12px);
|
|
226
241
|
padding-inline: var(--space-s-34lx8l, 12px);
|
|
227
242
|
}
|
|
228
|
-
.awsui_property-editor-
|
|
243
|
+
.awsui_property-editor-cancel_1wzqe_13oab_242:not(#\9) {
|
|
229
244
|
margin-inline-end: var(--space-xs-zb16t3, 8px);
|
|
230
245
|
}
|
|
231
|
-
.awsui_property-editor-
|
|
246
|
+
.awsui_property-editor-actions_1wzqe_13oab_245:not(#\9) {
|
|
232
247
|
display: flex;
|
|
233
248
|
justify-content: flex-end;
|
|
234
249
|
border-block-start: var(--border-divider-list-width-27y3k5, 1px) solid var(--color-border-dropdown-item-default-xiw1xo, #c6c6cd);
|
|
@@ -236,32 +251,46 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
236
251
|
padding-block: var(--space-s-34lx8l, 12px);
|
|
237
252
|
}
|
|
238
253
|
|
|
239
|
-
.
|
|
254
|
+
.awsui_property-editor-enum_1wzqe_13oab_253:not(#\9) {
|
|
255
|
+
display: flex;
|
|
256
|
+
flex-direction: column;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.awsui_token-editor_1wzqe_13oab_258:not(#\9) {
|
|
240
260
|
display: flex;
|
|
241
261
|
flex-direction: column;
|
|
242
262
|
gap: var(--space-s-34lx8l, 12px);
|
|
243
263
|
margin-block: var(--space-xxs-p8yyaw, 4px);
|
|
244
264
|
margin-inline: var(--space-xxs-p8yyaw, 4px);
|
|
245
265
|
}
|
|
246
|
-
.awsui_token-editor-
|
|
266
|
+
.awsui_token-editor-form_1wzqe_13oab_265:not(#\9) {
|
|
247
267
|
/* used in test-utils */
|
|
248
268
|
}
|
|
249
|
-
.awsui_token-editor-field-
|
|
269
|
+
.awsui_token-editor-field-property_1wzqe_13oab_268:not(#\9) {
|
|
250
270
|
flex-grow: 2;
|
|
251
271
|
}
|
|
252
|
-
.awsui_token-editor-field-
|
|
272
|
+
.awsui_token-editor-field-operator_1wzqe_13oab_271:not(#\9) {
|
|
253
273
|
flex-grow: 1;
|
|
254
274
|
}
|
|
255
|
-
.awsui_token-editor-field-
|
|
275
|
+
.awsui_token-editor-field-value_1wzqe_13oab_274:not(#\9) {
|
|
256
276
|
flex-grow: 2;
|
|
257
277
|
}
|
|
258
|
-
.awsui_token-editor-
|
|
278
|
+
.awsui_token-editor-multiselect-wrapper_1wzqe_13oab_277:not(#\9) {
|
|
279
|
+
position: relative;
|
|
280
|
+
block-size: var(--size-vertical-input-v5iwwf, 32px);
|
|
281
|
+
min-inline-size: 200px;
|
|
282
|
+
}
|
|
283
|
+
.awsui_token-editor-multiselect-wrapper-inner_1wzqe_13oab_282:not(#\9) {
|
|
284
|
+
position: absolute;
|
|
285
|
+
inline-size: 100%;
|
|
286
|
+
}
|
|
287
|
+
.awsui_token-editor-cancel_1wzqe_13oab_286:not(#\9) {
|
|
259
288
|
margin-inline-end: var(--space-xs-zb16t3, 8px);
|
|
260
289
|
}
|
|
261
|
-
.awsui_token-editor-
|
|
290
|
+
.awsui_token-editor-submit_1wzqe_13oab_289:not(#\9) {
|
|
262
291
|
/* used in test-utils */
|
|
263
292
|
}
|
|
264
|
-
.awsui_token-editor-
|
|
293
|
+
.awsui_token-editor-actions_1wzqe_13oab_292:not(#\9) {
|
|
265
294
|
display: flex;
|
|
266
295
|
justify-content: flex-end;
|
|
267
296
|
padding-block-start: var(--space-s-34lx8l, 12px);
|
|
@@ -270,7 +299,7 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
270
299
|
margin-inline: calc(-1 * var(--space-m-udix3p, 16px) + -1 * var(--space-xxs-p8yyaw, 4px));
|
|
271
300
|
margin-block-start: var(--space-s-34lx8l, 12px);
|
|
272
301
|
}
|
|
273
|
-
.awsui_token-editor-
|
|
302
|
+
.awsui_token-editor-grid_1wzqe_13oab_301:not(#\9) {
|
|
274
303
|
border-collapse: separate;
|
|
275
304
|
border-spacing: 0;
|
|
276
305
|
box-sizing: border-box;
|
|
@@ -308,70 +337,70 @@ surrounding text. (WCAG F73) https://www.w3.org/WAI/WCAG21/Techniques/failures/F
|
|
|
308
337
|
gap: var(--space-s-34lx8l, 12px);
|
|
309
338
|
grid-template-columns: minmax(min-content, 2fr) minmax(min-content, 120px) minmax(min-content, 3fr) min-content;
|
|
310
339
|
}
|
|
311
|
-
.awsui_token-editor-grid-
|
|
340
|
+
.awsui_token-editor-grid-group_1wzqe_13oab_338:not(#\9) {
|
|
312
341
|
display: contents;
|
|
313
342
|
}
|
|
314
|
-
.awsui_token-editor-
|
|
343
|
+
.awsui_token-editor-grid_1wzqe_13oab_301.awsui_token-editor-narrow_1wzqe_13oab_341:not(#\9) {
|
|
315
344
|
grid-template-columns: minmax(100px, 1fr);
|
|
316
345
|
gap: var(--space-m-udix3p, 16px);
|
|
317
346
|
}
|
|
318
|
-
.awsui_token-editor-
|
|
347
|
+
.awsui_token-editor-grid_1wzqe_13oab_301.awsui_token-editor-narrow_1wzqe_13oab_341 > .awsui_token-editor-grid-group_1wzqe_13oab_338:not(#\9) {
|
|
319
348
|
display: flex;
|
|
320
349
|
flex-direction: column;
|
|
321
350
|
gap: var(--space-s-34lx8l, 12px);
|
|
322
351
|
}
|
|
323
|
-
.awsui_token-editor-
|
|
352
|
+
.awsui_token-editor-grid_1wzqe_13oab_301.awsui_token-editor-narrow_1wzqe_13oab_341 > .awsui_token-editor-grid-group_1wzqe_13oab_338.awsui_token-editor-supports-groups_1wzqe_13oab_350:not(#\9) {
|
|
324
353
|
padding-block-end: var(--space-m-udix3p, 16px);
|
|
325
354
|
border-block-end: var(--border-divider-section-width-1061zr, 1px) solid var(--color-border-divider-default-cx07f2, #c6c6cd);
|
|
326
355
|
}
|
|
327
|
-
.awsui_token-editor-grid-
|
|
356
|
+
.awsui_token-editor-grid-header_1wzqe_13oab_354:not(#\9) {
|
|
328
357
|
color: var(--color-text-column-header-18yqaj, #424650);
|
|
329
358
|
font-weight: var(--font-weight-heading-s-cwn6wc, 700);
|
|
330
359
|
padding-block: var(--space-scaled-xxs-7597g1, 4px);
|
|
331
360
|
text-align: start;
|
|
332
361
|
}
|
|
333
|
-
.awsui_token-editor-grid-
|
|
362
|
+
.awsui_token-editor-grid-cell_1wzqe_13oab_360:not(#\9):not(.awsui_token-editor-narrow_1wzqe_13oab_341) {
|
|
334
363
|
display: flex;
|
|
335
364
|
align-items: flex-end;
|
|
336
365
|
justify-content: flex-end;
|
|
337
366
|
}
|
|
338
|
-
.awsui_token-editor-grid-
|
|
367
|
+
.awsui_token-editor-grid-cell_1wzqe_13oab_360.awsui_token-editor-narrow_1wzqe_13oab_341:not(#\9):nth-child(4) {
|
|
339
368
|
display: flex;
|
|
340
369
|
justify-content: flex-end;
|
|
341
370
|
}
|
|
342
|
-
.awsui_token-editor-add-
|
|
371
|
+
.awsui_token-editor-add-token_1wzqe_13oab_369:not(#\9) {
|
|
343
372
|
margin-block-start: var(--space-s-34lx8l, 12px);
|
|
344
373
|
}
|
|
345
374
|
|
|
346
|
-
.awsui_custom-content-
|
|
375
|
+
.awsui_custom-content-wrapper_1wzqe_13oab_373:not(#\9) {
|
|
347
376
|
display: contents;
|
|
348
377
|
}
|
|
349
378
|
|
|
350
|
-
.awsui_custom-
|
|
379
|
+
.awsui_custom-control_1wzqe_13oab_377:not(#\9) {
|
|
351
380
|
/* used in test-utils */
|
|
352
381
|
}
|
|
353
382
|
|
|
354
|
-
.
|
|
383
|
+
.awsui_input_1wzqe_13oab_183:not(#\9) {
|
|
355
384
|
flex: 1;
|
|
356
385
|
}
|
|
357
386
|
|
|
358
|
-
.
|
|
387
|
+
.awsui_results_1wzqe_13oab_385:not(#\9) {
|
|
359
388
|
padding-block: calc(var(--space-scaled-xxs-7597g1, 4px) + var(--border-field-width-09w7vk, 2px));
|
|
360
389
|
padding-inline: 0;
|
|
361
390
|
}
|
|
362
391
|
|
|
363
|
-
.awsui_token-
|
|
392
|
+
.awsui_token-trigger_1wzqe_13oab_390:not(#\9) {
|
|
364
393
|
min-inline-size: 0;
|
|
365
394
|
word-break: break-word;
|
|
366
395
|
}
|
|
367
396
|
|
|
368
|
-
.awsui_remove-
|
|
369
|
-
.awsui_join-
|
|
370
|
-
.awsui_custom-filter-
|
|
397
|
+
.awsui_remove-all_1wzqe_13oab_395:not(#\9),
|
|
398
|
+
.awsui_join-operation_1wzqe_13oab_396:not(#\9),
|
|
399
|
+
.awsui_custom-filter-actions_1wzqe_13oab_397:not(#\9) {
|
|
371
400
|
/* used in test-utils */
|
|
372
401
|
}
|
|
373
402
|
|
|
374
|
-
.
|
|
403
|
+
.awsui_constraint_1wzqe_13oab_401:not(#\9) {
|
|
375
404
|
padding-block-start: var(--space-xxs-p8yyaw, 4px);
|
|
376
405
|
color: var(--color-text-form-secondary-54emib, #656871);
|
|
377
406
|
font-size: var(--font-size-body-s-asqx2i, 12px);
|