@hh.ru/magritte-ui-select 10.0.14 → 10.0.15
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/SelectBottomSheet.js +3 -3
- package/SelectBottomSheet.js.map +1 -1
- package/SelectDrop.js +1 -1
- package/SelectEmptyHint.js +1 -1
- package/SelectError.js +3 -3
- package/SelectError.js.map +1 -1
- package/SelectOption.js +1 -1
- package/index.css +24 -24
- package/package.json +15 -15
package/SelectBottomSheet.js
CHANGED
|
@@ -8,7 +8,7 @@ import { ActionBar } from '@hh.ru/magritte-ui-action-bar';
|
|
|
8
8
|
import { BottomSheetFooter, BottomSheet } from '@hh.ru/magritte-ui-bottom-sheet';
|
|
9
9
|
import { Button } from '@hh.ru/magritte-ui-button';
|
|
10
10
|
import { CellText, Cell } from '@hh.ru/magritte-ui-cell';
|
|
11
|
-
import {
|
|
11
|
+
import { ArrowPathClockwiseOutlinedSize24, CrossOutlinedSize24 } from '@hh.ru/magritte-ui-icon/icon';
|
|
12
12
|
import { SearchInput } from '@hh.ru/magritte-ui-input';
|
|
13
13
|
import { Loader } from '@hh.ru/magritte-ui-loader';
|
|
14
14
|
import { NavigationBar } from '@hh.ru/magritte-ui-navigation-bar';
|
|
@@ -24,7 +24,7 @@ import '@hh.ru/magritte-ui-typography';
|
|
|
24
24
|
import '@hh.ru/magritte-ui-checkable-card/CheckableCardElement';
|
|
25
25
|
import '@hh.ru/magritte-ui-checkbox-radio';
|
|
26
26
|
|
|
27
|
-
var styles = {"select-bottom-sheet":"magritte-select-bottom-sheet___1RZDJ_10-0-
|
|
27
|
+
var styles = {"select-bottom-sheet":"magritte-select-bottom-sheet___1RZDJ_10-0-15","selectBottomSheet":"magritte-select-bottom-sheet___1RZDJ_10-0-15","select-bottom-sheet_checkbox":"magritte-select-bottom-sheet_checkbox___hwTgo_10-0-15","selectBottomSheetCheckbox":"magritte-select-bottom-sheet_checkbox___hwTgo_10-0-15","select-bottom-sheet_radio":"magritte-select-bottom-sheet_radio___qvFFV_10-0-15","selectBottomSheetRadio":"magritte-select-bottom-sheet_radio___qvFFV_10-0-15","full-screen-placeholder":"magritte-full-screen-placeholder___zPC8k_10-0-15","fullScreenPlaceholder":"magritte-full-screen-placeholder___zPC8k_10-0-15","error-wrapper":"magritte-error-wrapper___P7jYg_10-0-15","errorWrapper":"magritte-error-wrapper___P7jYg_10-0-15"};
|
|
28
28
|
|
|
29
29
|
const SelectOptionDefault = ({ data, input, type, }) => {
|
|
30
30
|
if (type === 'delimiter') {
|
|
@@ -141,7 +141,7 @@ const SelectBottomSheet = ({ type, name, multiple, clearButton: _clearButton, ap
|
|
|
141
141
|
onSearchSubmit,
|
|
142
142
|
optionsCount: optionList.length,
|
|
143
143
|
onCloseBottomSheetWithUpdateValues,
|
|
144
|
-
}), onClose: onCloseWithAlertCheck, footer: internalError && innerErrorTrls ? (jsx(BottomSheetFooter, { children: jsx(Button, { mode: "primary", style: "accent", size: "medium", onClick: reload, stretched: true, icon: jsx(
|
|
144
|
+
}), onClose: onCloseWithAlertCheck, footer: internalError && innerErrorTrls ? (jsx(BottomSheetFooter, { children: jsx(Button, { mode: "primary", style: "accent", size: "medium", onClick: reload, stretched: true, icon: jsx(ArrowPathClockwiseOutlinedSize24, {}), children: innerErrorTrls.reloadButton }) })) : (footer), onAppear: onBottomSheetOpen, onAfterExit: onBottomSheetClose, children: [internalError && innerErrorTrls && jsx(SelectError, { innerErrorTrls: innerErrorTrls, reload: reload }), emptyOptionsSearchHintVisible && (jsx("div", { className: styles.fullScreenPlaceholder, children: emptyOptionsSearchHint })), emptyOptionsHintVisible && jsx("div", { className: styles.fullScreenPlaceholder, children: emptyOptionsHint }), loading && !showErrorPlaceholder && (jsx("div", { className: styles.fullScreenPlaceholder, children: jsx(Loader, { size: 24 }) })), showErrorPlaceholder && jsx("div", { className: styles.errorWrapper, children: error && error.placeholder }), optionsVisible && (jsx("div", { className: classnames(styles.selectBottomSheet, styles[`select-bottom-sheet_${type}`]), "data-qa": "magritte-select-option-list-on-xs", children: optionList.map(({ disabled: _disabled, type: optionType, ...option }) => {
|
|
145
145
|
const checked = Boolean(option.data && getChecked(option.data, values ?? []));
|
|
146
146
|
const disabled = !checked && (_disabled || isLimitExceeded);
|
|
147
147
|
return (jsx(SelectOption, { name: name, checked: checked, onChange: handleChange, render: renderItem, disabled: disabled, type: optionType || type, plain: type === 'label', multiple: multiple, "data-qa": optionDataQa, isXS: true, ...option }, option.data.value));
|
package/SelectBottomSheet.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectBottomSheet.js","sources":["../src/SelectBottomSheet.tsx"],"sourcesContent":["import { useCallback, ReactElement, ReactNode, cloneElement, useState, ComponentProps } from 'react';\nimport classnames from 'classnames';\n\nimport { StaticDataFetcherItem } from '@hh.ru/magritte-common-data-provider';\nimport { keyboardKeys, keyboardMatch } from '@hh.ru/magritte-common-keyboard';\nimport { Action } from '@hh.ru/magritte-ui-action';\nimport { ActionBar } from '@hh.ru/magritte-ui-action-bar';\nimport { BottomSheet, BottomSheetFooter } from '@hh.ru/magritte-ui-bottom-sheet';\nimport { Button } from '@hh.ru/magritte-ui-button';\nimport { ButtonElement } from '@hh.ru/magritte-ui-button-stack';\nimport { Cell, CellText } from '@hh.ru/magritte-ui-cell';\nimport { ArrowPathClockwiseSize24, CrossOutlinedSize24 } from '@hh.ru/magritte-ui-icon/icon';\nimport { SearchInput } from '@hh.ru/magritte-ui-input';\nimport { Loader } from '@hh.ru/magritte-ui-loader';\nimport { NavigationBar } from '@hh.ru/magritte-ui-navigation-bar';\nimport { SelectError } from '@hh.ru/magritte-ui-select/SelectError';\nimport { SelectOption } from '@hh.ru/magritte-ui-select/SelectOption';\nimport { getChecked } from '@hh.ru/magritte-ui-select/getChecked';\nimport { isArraysEquals } from '@hh.ru/magritte-ui-select/isArraysEquals';\nimport {\n OnChangeAction,\n SelectButtons,\n SelectBottomSheetProps,\n RenderOptionTypeProps,\n RenderHeaderProps,\n} from '@hh.ru/magritte-ui-select/types';\n\nimport styles from './select-bottom-sheet.less';\n\nconst SelectOptionDefault = <DataType extends StaticDataFetcherItem>({\n data,\n input,\n type,\n}: RenderOptionTypeProps<DataType>): ReactElement => {\n if (type === 'delimiter') {\n return (\n <CellText maxLines={1} style=\"secondary\">\n {data.text}\n </CellText>\n );\n }\n if (type === 'label') {\n return <CellText maxLines={1}>{data.text}</CellText>;\n }\n return (\n <Cell Element=\"div\" align=\"center\" right={input}>\n <CellText maxLines={1}>{data.text}</CellText>\n </Cell>\n );\n};\n\nconst RenderButtonsContainerDefault = ({ clearButton, applyChangesButton }: SelectButtons): ReactNode => {\n const primaryActions = [clearButton, applyChangesButton].filter(Boolean);\n return <ActionBar type=\"mobile\" primaryActions={primaryActions as ButtonElement[]} />;\n};\n\nconst RenderHeaderDefault = ({\n onCloseBottomSheet,\n searchValue,\n setSearchValue,\n searchable,\n headerTitle,\n onSearchSubmit,\n optionsCount,\n onCloseBottomSheetWithUpdateValues,\n}: RenderHeaderProps): ReactNode => {\n return (\n <NavigationBar\n title={headerTitle}\n right={\n <Action\n icon={CrossOutlinedSize24}\n onClick={onCloseBottomSheet}\n data-qa=\"select-bottom-sheet-navigation-close\"\n />\n }\n options={\n searchable && (\n <SearchInput\n clearable\n size=\"medium\"\n value={searchValue}\n onChange={setSearchValue}\n onKeyDown={(event) => {\n if (onSearchSubmit && keyboardMatch(event.nativeEvent, keyboardKeys.Enter)) {\n onSearchSubmit(\n event,\n onCloseBottomSheet,\n optionsCount,\n onCloseBottomSheetWithUpdateValues\n );\n }\n }}\n data-qa=\"bottom-sheet-navigation-input\"\n autoComplete=\"off\"\n />\n )\n }\n />\n );\n};\n\nexport const SelectBottomSheet = <MultipleType extends boolean, DataType extends StaticDataFetcherItem>({\n type,\n name,\n multiple,\n clearButton: _clearButton,\n applyChangesButton: _applyChangesButton,\n useInitialValuesOnClearAction,\n loading,\n error,\n renderHeader = RenderHeaderDefault,\n renderItem = SelectOptionDefault,\n renderButtonsContainer = RenderButtonsContainerDefault,\n renderAlertOnExitWithoutSaving,\n headerTitle,\n onClose,\n visible,\n optionList,\n optionsListRef,\n searchValue,\n setSearchValue,\n searchable,\n value: values,\n onChange,\n clearSelectedValues,\n setInitialValues,\n isLimitExceeded,\n initialValuesOnOpening,\n setSelectedValues,\n onBottomSheetOpen,\n onBottomSheetClose,\n onSearchSubmit,\n onApply,\n onClear,\n emptyOptionsHint,\n emptyOptionsSearchHint,\n searchInProgress,\n internalError,\n reload,\n innerErrorTrls,\n optionDataQa,\n ...props\n}: SelectBottomSheetProps<MultipleType, DataType>): ReactElement => {\n const [alertVisible, setAlertVisible] = useState(false);\n const onCloseAlert = () => setAlertVisible(false);\n const showAlertOnExitWithoutSaving = Boolean(renderAlertOnExitWithoutSaving);\n const showErrorPlaceholder = Boolean(error);\n\n const onCloseWithAlertCheck = () => {\n if (showAlertOnExitWithoutSaving && multiple) {\n const haveUnsavingChanges = !isArraysEquals<string>(\n initialValuesOnOpening.current?.map((item) => item.value) ?? [],\n // eslint-disable-next-line no-nested-ternary\n Array.isArray(values) ? values.map((item) => item.value) : values ? [values.value] : []\n );\n if (haveUnsavingChanges) {\n setAlertVisible(true);\n } else {\n onClose();\n }\n } else {\n onClose();\n }\n };\n\n const clearButton =\n _clearButton &&\n cloneElement(_clearButton, {\n key: 'clearButton',\n size: 'medium',\n 'data-qa': 'magritte-select-clear-action-on-xs',\n onClick: () => {\n if (useInitialValuesOnClearAction) {\n setInitialValues();\n } else {\n clearSelectedValues();\n }\n onClose();\n onClear?.();\n },\n } as Partial<ComponentProps<typeof Button>>);\n\n const needAddChangesButton = multiple && _applyChangesButton;\n const applyChangesButton =\n (needAddChangesButton &&\n cloneElement(_applyChangesButton, {\n key: 'applyChangesButton',\n size: 'medium',\n 'data-qa': 'magritte-select-apply-on-xs',\n onClick: () => {\n setSelectedValues();\n onClose();\n onApply?.({ isMobile: true, searchValue });\n },\n } as Partial<ComponentProps<typeof Button>>)) ||\n undefined;\n\n const handleChange: OnChangeAction<DataType> = useCallback(\n (...args) => {\n if (!multiple) {\n onClose();\n }\n onChange(...args);\n },\n [multiple, onChange, onClose]\n );\n\n const haveClearOrApplyChangesButtons = clearButton || applyChangesButton;\n const footer = !showErrorPlaceholder ? (\n !loading &&\n haveClearOrApplyChangesButtons &&\n renderButtonsContainer({\n clearButton,\n applyChangesButton,\n })\n ) : (\n <BottomSheetFooter>{error && error.resetButton}</BottomSheetFooter>\n );\n\n const emptyOptionsHintVisible =\n optionList.length === 0 &&\n !searchValue &&\n !!emptyOptionsHint &&\n !loading &&\n !showErrorPlaceholder &&\n !searchInProgress &&\n !internalError;\n\n const emptyOptionsSearchHintVisible =\n optionList.length === 0 &&\n searchValue &&\n !!emptyOptionsSearchHint &&\n !loading &&\n !showErrorPlaceholder &&\n !searchInProgress &&\n !internalError;\n\n const onCloseBottomSheetWithUpdateValues = () => {\n setSelectedValues();\n onCloseWithAlertCheck();\n };\n\n const optionsVisible =\n !loading &&\n !emptyOptionsSearchHintVisible &&\n !emptyOptionsHintVisible &&\n !internalError &&\n !showErrorPlaceholder;\n\n return (\n <>\n <BottomSheet\n {...props}\n ref={optionsListRef}\n allowScrollWhileFocused\n keyboardOverlaysFooter={false}\n visible={visible}\n showDivider={false}\n withContentPaddings={showErrorPlaceholder}\n header={renderHeader({\n onCloseBottomSheet: onCloseWithAlertCheck,\n searchValue,\n setSearchValue,\n searchable,\n headerTitle,\n onSearchSubmit,\n optionsCount: optionList.length,\n onCloseBottomSheetWithUpdateValues,\n })}\n onClose={onCloseWithAlertCheck}\n footer={\n internalError && innerErrorTrls ? (\n <BottomSheetFooter>\n <Button\n mode=\"primary\"\n style=\"accent\"\n size=\"medium\"\n onClick={reload}\n stretched\n icon={<ArrowPathClockwiseSize24 />}\n >\n {innerErrorTrls.reloadButton}\n </Button>\n </BottomSheetFooter>\n ) : (\n footer\n )\n }\n onAppear={onBottomSheetOpen}\n onAfterExit={onBottomSheetClose}\n >\n {internalError && innerErrorTrls && <SelectError innerErrorTrls={innerErrorTrls} reload={reload} />}\n {emptyOptionsSearchHintVisible && (\n <div className={styles.fullScreenPlaceholder}>{emptyOptionsSearchHint}</div>\n )}\n {emptyOptionsHintVisible && <div className={styles.fullScreenPlaceholder}>{emptyOptionsHint}</div>}\n {loading && !showErrorPlaceholder && (\n <div className={styles.fullScreenPlaceholder}>\n <Loader size={24} />\n </div>\n )}\n {showErrorPlaceholder && <div className={styles.errorWrapper}>{error && error.placeholder}</div>}\n {optionsVisible && (\n <div\n className={classnames(styles.selectBottomSheet, styles[`select-bottom-sheet_${type}`])}\n data-qa=\"magritte-select-option-list-on-xs\"\n >\n {optionList.map(({ disabled: _disabled, type: optionType, ...option }) => {\n const checked = Boolean(option.data && getChecked<DataType>(option.data, values ?? []));\n const disabled = !checked && (_disabled || isLimitExceeded);\n return (\n <SelectOption\n key={option.data.value}\n name={name}\n checked={checked}\n onChange={handleChange}\n render={renderItem}\n disabled={disabled}\n type={optionType || type}\n plain={type === 'label'}\n multiple={multiple}\n data-qa={optionDataQa}\n isXS\n {...option}\n />\n );\n })}\n </div>\n )}\n </BottomSheet>\n {renderAlertOnExitWithoutSaving?.({\n alertVisible,\n onCloseAlert,\n onCloseBottomSheetAndAlert: () => {\n onCloseAlert();\n onClose();\n },\n })}\n </>\n );\n};\n"],"names":["_jsx","_jsxs","_Fragment"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,MAAM,mBAAmB,GAAG,CAAyC,EACjE,IAAI,EACJ,KAAK,EACL,IAAI,GAC0B,KAAkB;AAChD,IAAA,IAAI,IAAI,KAAK,WAAW,EAAE;AACtB,QAAA,QACIA,GAAC,CAAA,QAAQ,EAAC,EAAA,QAAQ,EAAE,CAAC,EAAE,KAAK,EAAC,WAAW,EACnC,QAAA,EAAA,IAAI,CAAC,IAAI,EAAA,CACH,EACb;KACL;AACD,IAAA,IAAI,IAAI,KAAK,OAAO,EAAE;QAClB,OAAOA,GAAA,CAAC,Q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xB,EACJ;AACN,yBAAC,CAAC,EACA,CAAA,CACT,IACS,EACb,8BAA8B,GAAG;gBAC9B,YAAY;gBACZ,YAAY;gBACZ,0BAA0B,EAAE,MAAK;AAC7B,oBAAA,YAAY,EAAE,CAAC;AACf,oBAAA,OAAO,EAAE,CAAC;iBACb;aACJ,CAAC,CAAA,EAAA,CACH,EACL;AACN;;;;"}
|
|
1
|
+
{"version":3,"file":"SelectBottomSheet.js","sources":["../src/SelectBottomSheet.tsx"],"sourcesContent":["import { useCallback, ReactElement, ReactNode, cloneElement, useState, ComponentProps } from 'react';\nimport classnames from 'classnames';\n\nimport { StaticDataFetcherItem } from '@hh.ru/magritte-common-data-provider';\nimport { keyboardKeys, keyboardMatch } from '@hh.ru/magritte-common-keyboard';\nimport { Action } from '@hh.ru/magritte-ui-action';\nimport { ActionBar } from '@hh.ru/magritte-ui-action-bar';\nimport { BottomSheet, BottomSheetFooter } from '@hh.ru/magritte-ui-bottom-sheet';\nimport { Button } from '@hh.ru/magritte-ui-button';\nimport { ButtonElement } from '@hh.ru/magritte-ui-button-stack';\nimport { Cell, CellText } from '@hh.ru/magritte-ui-cell';\nimport { ArrowPathClockwiseOutlinedSize24, CrossOutlinedSize24 } from '@hh.ru/magritte-ui-icon/icon';\nimport { SearchInput } from '@hh.ru/magritte-ui-input';\nimport { Loader } from '@hh.ru/magritte-ui-loader';\nimport { NavigationBar } from '@hh.ru/magritte-ui-navigation-bar';\nimport { SelectError } from '@hh.ru/magritte-ui-select/SelectError';\nimport { SelectOption } from '@hh.ru/magritte-ui-select/SelectOption';\nimport { getChecked } from '@hh.ru/magritte-ui-select/getChecked';\nimport { isArraysEquals } from '@hh.ru/magritte-ui-select/isArraysEquals';\nimport {\n OnChangeAction,\n SelectButtons,\n SelectBottomSheetProps,\n RenderOptionTypeProps,\n RenderHeaderProps,\n} from '@hh.ru/magritte-ui-select/types';\n\nimport styles from './select-bottom-sheet.less';\n\nconst SelectOptionDefault = <DataType extends StaticDataFetcherItem>({\n data,\n input,\n type,\n}: RenderOptionTypeProps<DataType>): ReactElement => {\n if (type === 'delimiter') {\n return (\n <CellText maxLines={1} style=\"secondary\">\n {data.text}\n </CellText>\n );\n }\n if (type === 'label') {\n return <CellText maxLines={1}>{data.text}</CellText>;\n }\n return (\n <Cell Element=\"div\" align=\"center\" right={input}>\n <CellText maxLines={1}>{data.text}</CellText>\n </Cell>\n );\n};\n\nconst RenderButtonsContainerDefault = ({ clearButton, applyChangesButton }: SelectButtons): ReactNode => {\n const primaryActions = [clearButton, applyChangesButton].filter(Boolean);\n return <ActionBar type=\"mobile\" primaryActions={primaryActions as ButtonElement[]} />;\n};\n\nconst RenderHeaderDefault = ({\n onCloseBottomSheet,\n searchValue,\n setSearchValue,\n searchable,\n headerTitle,\n onSearchSubmit,\n optionsCount,\n onCloseBottomSheetWithUpdateValues,\n}: RenderHeaderProps): ReactNode => {\n return (\n <NavigationBar\n title={headerTitle}\n right={\n <Action\n icon={CrossOutlinedSize24}\n onClick={onCloseBottomSheet}\n data-qa=\"select-bottom-sheet-navigation-close\"\n />\n }\n options={\n searchable && (\n <SearchInput\n clearable\n size=\"medium\"\n value={searchValue}\n onChange={setSearchValue}\n onKeyDown={(event) => {\n if (onSearchSubmit && keyboardMatch(event.nativeEvent, keyboardKeys.Enter)) {\n onSearchSubmit(\n event,\n onCloseBottomSheet,\n optionsCount,\n onCloseBottomSheetWithUpdateValues\n );\n }\n }}\n data-qa=\"bottom-sheet-navigation-input\"\n autoComplete=\"off\"\n />\n )\n }\n />\n );\n};\n\nexport const SelectBottomSheet = <MultipleType extends boolean, DataType extends StaticDataFetcherItem>({\n type,\n name,\n multiple,\n clearButton: _clearButton,\n applyChangesButton: _applyChangesButton,\n useInitialValuesOnClearAction,\n loading,\n error,\n renderHeader = RenderHeaderDefault,\n renderItem = SelectOptionDefault,\n renderButtonsContainer = RenderButtonsContainerDefault,\n renderAlertOnExitWithoutSaving,\n headerTitle,\n onClose,\n visible,\n optionList,\n optionsListRef,\n searchValue,\n setSearchValue,\n searchable,\n value: values,\n onChange,\n clearSelectedValues,\n setInitialValues,\n isLimitExceeded,\n initialValuesOnOpening,\n setSelectedValues,\n onBottomSheetOpen,\n onBottomSheetClose,\n onSearchSubmit,\n onApply,\n onClear,\n emptyOptionsHint,\n emptyOptionsSearchHint,\n searchInProgress,\n internalError,\n reload,\n innerErrorTrls,\n optionDataQa,\n ...props\n}: SelectBottomSheetProps<MultipleType, DataType>): ReactElement => {\n const [alertVisible, setAlertVisible] = useState(false);\n const onCloseAlert = () => setAlertVisible(false);\n const showAlertOnExitWithoutSaving = Boolean(renderAlertOnExitWithoutSaving);\n const showErrorPlaceholder = Boolean(error);\n\n const onCloseWithAlertCheck = () => {\n if (showAlertOnExitWithoutSaving && multiple) {\n const haveUnsavingChanges = !isArraysEquals<string>(\n initialValuesOnOpening.current?.map((item) => item.value) ?? [],\n // eslint-disable-next-line no-nested-ternary\n Array.isArray(values) ? values.map((item) => item.value) : values ? [values.value] : []\n );\n if (haveUnsavingChanges) {\n setAlertVisible(true);\n } else {\n onClose();\n }\n } else {\n onClose();\n }\n };\n\n const clearButton =\n _clearButton &&\n cloneElement(_clearButton, {\n key: 'clearButton',\n size: 'medium',\n 'data-qa': 'magritte-select-clear-action-on-xs',\n onClick: () => {\n if (useInitialValuesOnClearAction) {\n setInitialValues();\n } else {\n clearSelectedValues();\n }\n onClose();\n onClear?.();\n },\n } as Partial<ComponentProps<typeof Button>>);\n\n const needAddChangesButton = multiple && _applyChangesButton;\n const applyChangesButton =\n (needAddChangesButton &&\n cloneElement(_applyChangesButton, {\n key: 'applyChangesButton',\n size: 'medium',\n 'data-qa': 'magritte-select-apply-on-xs',\n onClick: () => {\n setSelectedValues();\n onClose();\n onApply?.({ isMobile: true, searchValue });\n },\n } as Partial<ComponentProps<typeof Button>>)) ||\n undefined;\n\n const handleChange: OnChangeAction<DataType> = useCallback(\n (...args) => {\n if (!multiple) {\n onClose();\n }\n onChange(...args);\n },\n [multiple, onChange, onClose]\n );\n\n const haveClearOrApplyChangesButtons = clearButton || applyChangesButton;\n const footer = !showErrorPlaceholder ? (\n !loading &&\n haveClearOrApplyChangesButtons &&\n renderButtonsContainer({\n clearButton,\n applyChangesButton,\n })\n ) : (\n <BottomSheetFooter>{error && error.resetButton}</BottomSheetFooter>\n );\n\n const emptyOptionsHintVisible =\n optionList.length === 0 &&\n !searchValue &&\n !!emptyOptionsHint &&\n !loading &&\n !showErrorPlaceholder &&\n !searchInProgress &&\n !internalError;\n\n const emptyOptionsSearchHintVisible =\n optionList.length === 0 &&\n searchValue &&\n !!emptyOptionsSearchHint &&\n !loading &&\n !showErrorPlaceholder &&\n !searchInProgress &&\n !internalError;\n\n const onCloseBottomSheetWithUpdateValues = () => {\n setSelectedValues();\n onCloseWithAlertCheck();\n };\n\n const optionsVisible =\n !loading &&\n !emptyOptionsSearchHintVisible &&\n !emptyOptionsHintVisible &&\n !internalError &&\n !showErrorPlaceholder;\n\n return (\n <>\n <BottomSheet\n {...props}\n ref={optionsListRef}\n allowScrollWhileFocused\n keyboardOverlaysFooter={false}\n visible={visible}\n showDivider={false}\n withContentPaddings={showErrorPlaceholder}\n header={renderHeader({\n onCloseBottomSheet: onCloseWithAlertCheck,\n searchValue,\n setSearchValue,\n searchable,\n headerTitle,\n onSearchSubmit,\n optionsCount: optionList.length,\n onCloseBottomSheetWithUpdateValues,\n })}\n onClose={onCloseWithAlertCheck}\n footer={\n internalError && innerErrorTrls ? (\n <BottomSheetFooter>\n <Button\n mode=\"primary\"\n style=\"accent\"\n size=\"medium\"\n onClick={reload}\n stretched\n icon={<ArrowPathClockwiseOutlinedSize24 />}\n >\n {innerErrorTrls.reloadButton}\n </Button>\n </BottomSheetFooter>\n ) : (\n footer\n )\n }\n onAppear={onBottomSheetOpen}\n onAfterExit={onBottomSheetClose}\n >\n {internalError && innerErrorTrls && <SelectError innerErrorTrls={innerErrorTrls} reload={reload} />}\n {emptyOptionsSearchHintVisible && (\n <div className={styles.fullScreenPlaceholder}>{emptyOptionsSearchHint}</div>\n )}\n {emptyOptionsHintVisible && <div className={styles.fullScreenPlaceholder}>{emptyOptionsHint}</div>}\n {loading && !showErrorPlaceholder && (\n <div className={styles.fullScreenPlaceholder}>\n <Loader size={24} />\n </div>\n )}\n {showErrorPlaceholder && <div className={styles.errorWrapper}>{error && error.placeholder}</div>}\n {optionsVisible && (\n <div\n className={classnames(styles.selectBottomSheet, styles[`select-bottom-sheet_${type}`])}\n data-qa=\"magritte-select-option-list-on-xs\"\n >\n {optionList.map(({ disabled: _disabled, type: optionType, ...option }) => {\n const checked = Boolean(option.data && getChecked<DataType>(option.data, values ?? []));\n const disabled = !checked && (_disabled || isLimitExceeded);\n return (\n <SelectOption\n key={option.data.value}\n name={name}\n checked={checked}\n onChange={handleChange}\n render={renderItem}\n disabled={disabled}\n type={optionType || type}\n plain={type === 'label'}\n multiple={multiple}\n data-qa={optionDataQa}\n isXS\n {...option}\n />\n );\n })}\n </div>\n )}\n </BottomSheet>\n {renderAlertOnExitWithoutSaving?.({\n alertVisible,\n onCloseAlert,\n onCloseBottomSheetAndAlert: () => {\n onCloseAlert();\n onClose();\n },\n })}\n </>\n );\n};\n"],"names":["_jsx","_jsxs","_Fragment"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AA6BA,MAAM,mBAAmB,GAAG,CAAyC,EACjE,IAAI,EACJ,KAAK,EACL,IAAI,GAC0B,KAAkB;AAChD,IAAA,IAAI,IAAI,KAAK,WAAW,EAAE;AACtB,QAAA,QACIA,GAAC,CAAA,QAAQ,EAAC,EAAA,QAAQ,EAAE,CAAC,EAAE,KAAK,EAAC,WAAW,EACnC,QAAA,EAAA,IAAI,CAAC,IAAI,EAAA,CACH,EACb;KACL;AACD,IAAA,IAAI,IAAI,KAAK,OAAO,EAAE;QAClB,OAAOA,GAAA,CAAC,QAAQ,EAAA,EAAC,QAAQ,EAAE,CAAC,EAAA,QAAA,EAAG,IAAI,CAAC,IAAI,EAAA,CAAY,CAAC;KACx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gBACZ,0BAA0B,EAAE,MAAK;AAC7B,oBAAA,YAAY,EAAE,CAAC;AACf,oBAAA,OAAO,EAAE,CAAC;iBACb;aACJ,CAAC,CAAA,EAAA,CACH,EACL;AACN;;;;"}
|
package/SelectDrop.js
CHANGED
|
@@ -19,7 +19,7 @@ import '@hh.ru/magritte-ui-checkable-card/CheckableCardElement';
|
|
|
19
19
|
import '@hh.ru/magritte-ui-checkbox-radio';
|
|
20
20
|
import '@hh.ru/magritte-ui-icon/icon';
|
|
21
21
|
|
|
22
|
-
var styles = {"select-drop-container-wrapper":"magritte-select-drop-container-wrapper___OHM0q_10-0-
|
|
22
|
+
var styles = {"select-drop-container-wrapper":"magritte-select-drop-container-wrapper___OHM0q_10-0-15","selectDropContainerWrapper":"magritte-select-drop-container-wrapper___OHM0q_10-0-15","select-drop-container":"magritte-select-drop-container___hee1p_10-0-15","selectDropContainer":"magritte-select-drop-container___hee1p_10-0-15","select-drop-container_plain":"magritte-select-drop-container_plain___766zl_10-0-15","selectDropContainerPlain":"magritte-select-drop-container_plain___766zl_10-0-15","select-drop":"magritte-select-drop___jn4O-_10-0-15","selectDrop":"magritte-select-drop___jn4O-_10-0-15","select-drop-header":"magritte-select-drop-header___fMmio_10-0-15","selectDropHeader":"magritte-select-drop-header___fMmio_10-0-15","select-drop_plain":"magritte-select-drop_plain___VL8Fz_10-0-15","selectDropPlain":"magritte-select-drop_plain___VL8Fz_10-0-15","label-option-plain":"magritte-label-option-plain___BvBH8_10-0-15","labelOptionPlain":"magritte-label-option-plain___BvBH8_10-0-15","loading":"magritte-loading___AMiuq_10-0-15","hint":"magritte-hint___6qaFl_10-0-15"};
|
|
23
23
|
|
|
24
24
|
const SelectOptionDefault = ({ data, input, type, plain, }) => {
|
|
25
25
|
if (type === 'delimiter') {
|
package/SelectEmptyHint.js
CHANGED
|
@@ -6,7 +6,7 @@ import { VSpacing } from '@hh.ru/magritte-ui-spacing';
|
|
|
6
6
|
import { Title } from '@hh.ru/magritte-ui-title';
|
|
7
7
|
import { Text } from '@hh.ru/magritte-ui-typography';
|
|
8
8
|
|
|
9
|
-
var styles = {"select-empty-hint":"magritte-select-empty-hint___B39XJ_10-0-
|
|
9
|
+
var styles = {"select-empty-hint":"magritte-select-empty-hint___B39XJ_10-0-15","selectEmptyHint":"magritte-select-empty-hint___B39XJ_10-0-15","icon":"magritte-icon___F0GQx_10-0-15","icon-init":"magritte-icon-init___GWK-V_10-0-15","iconInit":"magritte-icon-init___GWK-V_10-0-15","icon-search":"magritte-icon-search___ZsqO-_10-0-15","iconSearch":"magritte-icon-search___ZsqO-_10-0-15"};
|
|
10
10
|
|
|
11
11
|
const SelectEmptyHint = ({ title, titleElement, description, type }) => {
|
|
12
12
|
return (jsxs("div", { className: styles.selectEmptyHint, children: [type === 'init' && (jsx("div", { className: classnames(styles.icon, styles.iconInit), children: jsx(MagnifierOutlinedSize24, {}) })), type === 'emptySearch' && (jsx("div", { className: classnames(styles.icon, styles.iconSearch), children: jsx(EmojiHalfsadOutlinedSize24, {}) })), jsx(VSpacing, { default: 32 }), jsx(Title, { Element: titleElement, size: "small", children: title }), jsx(VSpacing, { default: 8 }), Boolean(description) && (jsx(Text, { typography: "paragraph-2-regular", style: "secondary", children: description }))] }));
|
package/SelectError.js
CHANGED
|
@@ -2,19 +2,19 @@ import './index.css';
|
|
|
2
2
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
3
|
import { useBreakpoint } from '@hh.ru/magritte-ui-breakpoint';
|
|
4
4
|
import { Button } from '@hh.ru/magritte-ui-button';
|
|
5
|
-
import {
|
|
5
|
+
import { ArrowPathClockwiseOutlinedSize24 } from '@hh.ru/magritte-ui-icon/variants/icon';
|
|
6
6
|
import { VSpacing } from '@hh.ru/magritte-ui-spacing';
|
|
7
7
|
import { Title } from '@hh.ru/magritte-ui-title';
|
|
8
8
|
import { Text } from '@hh.ru/magritte-ui-typography';
|
|
9
9
|
|
|
10
|
-
var styles = {"error-container":"magritte-error-container___t9B5w_10-0-
|
|
10
|
+
var styles = {"error-container":"magritte-error-container___t9B5w_10-0-15","errorContainer":"magritte-error-container___t9B5w_10-0-15"};
|
|
11
11
|
|
|
12
12
|
const SelectError = ({ innerErrorTrls, reload, }) => {
|
|
13
13
|
const { isMobile } = useBreakpoint();
|
|
14
14
|
if (isMobile) {
|
|
15
15
|
return (jsxs("div", { className: styles.errorContainer, children: [jsx(Title, { Element: 'h3', size: "small", children: innerErrorTrls.title }), jsx(VSpacing, { default: 8 }), jsx(Text, { typography: "paragraph-2-regular", style: "secondary", children: innerErrorTrls.description })] }));
|
|
16
16
|
}
|
|
17
|
-
return (jsxs("div", { className: styles.errorContainer, "data-qa": "magritte-select-error", children: [jsx(Title, { Element: 'h3', size: "small", children: innerErrorTrls.title }), jsx(VSpacing, { default: 8 }), jsx(Text, { typography: "paragraph-2-regular", style: "secondary", children: innerErrorTrls.description }), jsx(VSpacing, { default: 32 }), jsx(Button, { mode: "primary", style: "accent", size: "medium", onClick: reload, icon: jsx(
|
|
17
|
+
return (jsxs("div", { className: styles.errorContainer, "data-qa": "magritte-select-error", children: [jsx(Title, { Element: 'h3', size: "small", children: innerErrorTrls.title }), jsx(VSpacing, { default: 8 }), jsx(Text, { typography: "paragraph-2-regular", style: "secondary", children: innerErrorTrls.description }), jsx(VSpacing, { default: 32 }), jsx(Button, { mode: "primary", style: "accent", size: "medium", onClick: reload, icon: jsx(ArrowPathClockwiseOutlinedSize24, {}), children: innerErrorTrls.reloadButton })] }));
|
|
18
18
|
};
|
|
19
19
|
|
|
20
20
|
export { SelectError };
|
package/SelectError.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectError.js","sources":["../src/SelectError.tsx"],"sourcesContent":["import { ComponentType } from 'react';\n\nimport { useBreakpoint } from '@hh.ru/magritte-ui-breakpoint';\nimport { Button } from '@hh.ru/magritte-ui-button';\nimport {
|
|
1
|
+
{"version":3,"file":"SelectError.js","sources":["../src/SelectError.tsx"],"sourcesContent":["import { ComponentType } from 'react';\n\nimport { useBreakpoint } from '@hh.ru/magritte-ui-breakpoint';\nimport { Button } from '@hh.ru/magritte-ui-button';\nimport { ArrowPathClockwiseOutlinedSize24 } from '@hh.ru/magritte-ui-icon/variants/icon';\nimport { InnerErrorTrls } from '@hh.ru/magritte-ui-select/types';\nimport { VSpacing } from '@hh.ru/magritte-ui-spacing';\nimport { Title } from '@hh.ru/magritte-ui-title';\nimport { Text } from '@hh.ru/magritte-ui-typography';\n\nimport styles from './select-error.less';\n\nexport const SelectError: ComponentType<{ innerErrorTrls: InnerErrorTrls; reload: VoidFunction }> = ({\n innerErrorTrls,\n reload,\n}) => {\n const { isMobile } = useBreakpoint();\n if (isMobile) {\n return (\n <div className={styles.errorContainer}>\n <Title Element={'h3'} size=\"small\">\n {innerErrorTrls.title}\n </Title>\n <VSpacing default={8} />\n <Text typography=\"paragraph-2-regular\" style=\"secondary\">\n {innerErrorTrls.description}\n </Text>\n </div>\n );\n }\n return (\n <div className={styles.errorContainer} data-qa=\"magritte-select-error\">\n <Title Element={'h3'} size=\"small\">\n {innerErrorTrls.title}\n </Title>\n <VSpacing default={8} />\n <Text typography=\"paragraph-2-regular\" style=\"secondary\">\n {innerErrorTrls.description}\n </Text>\n <VSpacing default={32} />\n <Button\n mode=\"primary\"\n style=\"accent\"\n size=\"medium\"\n onClick={reload}\n icon={<ArrowPathClockwiseOutlinedSize24 />}\n >\n {innerErrorTrls.reloadButton}\n </Button>\n </div>\n );\n};\n"],"names":["_jsxs","_jsx"],"mappings":";;;;;;;;;;AAYa,MAAA,WAAW,GAA4E,CAAC,EACjG,cAAc,EACd,MAAM,GACT,KAAI;AACD,IAAA,MAAM,EAAE,QAAQ,EAAE,GAAG,aAAa,EAAE,CAAC;IACrC,IAAI,QAAQ,EAAE;QACV,QACIA,cAAK,SAAS,EAAE,MAAM,CAAC,cAAc,EACjC,QAAA,EAAA,CAAAC,GAAA,CAAC,KAAK,EAAA,EAAC,OAAO,EAAE,IAAI,EAAE,IAAI,EAAC,OAAO,EAC7B,QAAA,EAAA,cAAc,CAAC,KAAK,EACjB,CAAA,EACRA,IAAC,QAAQ,EAAA,EAAC,OAAO,EAAE,CAAC,GAAI,EACxBA,GAAA,CAAC,IAAI,EAAA,EAAC,UAAU,EAAC,qBAAqB,EAAC,KAAK,EAAC,WAAW,EACnD,QAAA,EAAA,cAAc,CAAC,WAAW,EAAA,CACxB,CACL,EAAA,CAAA,EACR;KACL;AACD,IAAA,QACID,IAAK,CAAA,KAAA,EAAA,EAAA,SAAS,EAAE,MAAM,CAAC,cAAc,EAAU,SAAA,EAAA,uBAAuB,aAClEC,GAAC,CAAA,KAAK,IAAC,OAAO,EAAE,IAAI,EAAE,IAAI,EAAC,OAAO,EAAA,QAAA,EAC7B,cAAc,CAAC,KAAK,EACjB,CAAA,EACRA,IAAC,QAAQ,EAAA,EAAC,OAAO,EAAE,CAAC,GAAI,EACxBA,GAAA,CAAC,IAAI,EAAC,EAAA,UAAU,EAAC,qBAAqB,EAAC,KAAK,EAAC,WAAW,EACnD,QAAA,EAAA,cAAc,CAAC,WAAW,EAAA,CACxB,EACPA,GAAC,CAAA,QAAQ,IAAC,OAAO,EAAE,EAAE,EAAI,CAAA,EACzBA,IAAC,MAAM,EAAA,EACH,IAAI,EAAC,SAAS,EACd,KAAK,EAAC,QAAQ,EACd,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,MAAM,EACf,IAAI,EAAEA,IAAC,gCAAgC,EAAA,EAAA,CAAG,YAEzC,cAAc,CAAC,YAAY,EACvB,CAAA,CAAA,EAAA,CACP,EACR;AACN;;;;"}
|
package/SelectOption.js
CHANGED
|
@@ -9,7 +9,7 @@ import { Radio, Checkbox } from '@hh.ru/magritte-ui-checkbox-radio';
|
|
|
9
9
|
import { CheckOutlinedSize24 } from '@hh.ru/magritte-ui-icon/icon';
|
|
10
10
|
import { Text } from '@hh.ru/magritte-ui-typography';
|
|
11
11
|
|
|
12
|
-
var styles = {"select-option-label":"magritte-select-option-label___bYo2l_10-0-
|
|
12
|
+
var styles = {"select-option-label":"magritte-select-option-label___bYo2l_10-0-15","selectOptionLabel":"magritte-select-option-label___bYo2l_10-0-15","select-option-label_desktop":"magritte-select-option-label_desktop___bceen_10-0-15","selectOptionLabelDesktop":"magritte-select-option-label_desktop___bceen_10-0-15","select-delimiter":"magritte-select-delimiter___WyeR6_10-0-15","selectDelimiter":"magritte-select-delimiter___WyeR6_10-0-15"};
|
|
13
13
|
|
|
14
14
|
const CheckableComponent = ({ type, value, checked, name, onChange, 'data-qa': dataQa, }) => {
|
|
15
15
|
if (type === 'label') {
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.magritte-error-container___t9B5w_10-0-
|
|
1
|
+
.magritte-error-container___t9B5w_10-0-15{
|
|
2
2
|
display:flex;
|
|
3
3
|
flex-direction:column;
|
|
4
4
|
align-items:center;
|
|
@@ -6,26 +6,26 @@
|
|
|
6
6
|
justify-content:center;
|
|
7
7
|
}
|
|
8
8
|
@media (min-width: 1020px){
|
|
9
|
-
body.magritte-old-layout .magritte-error-container___t9B5w_10-0-
|
|
9
|
+
body.magritte-old-layout .magritte-error-container___t9B5w_10-0-15{
|
|
10
10
|
min-height:320px;
|
|
11
11
|
height:auto;
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
@media (min-width: 1024px){
|
|
15
|
-
body:not(.magritte-old-layout) .magritte-error-container___t9B5w_10-0-
|
|
15
|
+
body:not(.magritte-old-layout) .magritte-error-container___t9B5w_10-0-15{
|
|
16
16
|
min-height:320px;
|
|
17
17
|
height:auto;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
.magritte-select-option-label___bYo2l_10-0-
|
|
21
|
+
.magritte-select-option-label___bYo2l_10-0-15{
|
|
22
22
|
display:flex;
|
|
23
23
|
max-height:56px;
|
|
24
24
|
}
|
|
25
|
-
.magritte-select-option-label_desktop___bceen_10-0-
|
|
25
|
+
.magritte-select-option-label_desktop___bceen_10-0-15{
|
|
26
26
|
max-height:24px;
|
|
27
27
|
}
|
|
28
|
-
.magritte-select-delimiter___WyeR6_10-0-
|
|
28
|
+
.magritte-select-delimiter___WyeR6_10-0-15{
|
|
29
29
|
padding-left:16px;
|
|
30
30
|
padding-top:12px;
|
|
31
31
|
}
|
|
@@ -33,24 +33,24 @@
|
|
|
33
33
|
:root{
|
|
34
34
|
--magritte-static-space-400-v21-3-2:16px;
|
|
35
35
|
}
|
|
36
|
-
.magritte-select-bottom-sheet___1RZDJ_10-0-
|
|
36
|
+
.magritte-select-bottom-sheet___1RZDJ_10-0-15{
|
|
37
37
|
display:flex;
|
|
38
38
|
flex-direction:column;
|
|
39
39
|
padding:0 var(--magritte-static-space-400-v21-3-2);
|
|
40
40
|
padding-bottom:16px;
|
|
41
41
|
}
|
|
42
|
-
.magritte-select-bottom-sheet_checkbox___hwTgo_10-0-
|
|
43
|
-
.magritte-select-bottom-sheet_radio___qvFFV_10-0-
|
|
42
|
+
.magritte-select-bottom-sheet_checkbox___hwTgo_10-0-15,
|
|
43
|
+
.magritte-select-bottom-sheet_radio___qvFFV_10-0-15{
|
|
44
44
|
gap:12px;
|
|
45
45
|
}
|
|
46
|
-
.magritte-full-screen-placeholder___zPC8k_10-0-
|
|
46
|
+
.magritte-full-screen-placeholder___zPC8k_10-0-15{
|
|
47
47
|
display:flex;
|
|
48
48
|
flex-direction:column;
|
|
49
49
|
align-items:center;
|
|
50
50
|
height:100%;
|
|
51
51
|
justify-content:center;
|
|
52
52
|
}
|
|
53
|
-
.magritte-error-wrapper___P7jYg_10-0-
|
|
53
|
+
.magritte-error-wrapper___P7jYg_10-0-15{
|
|
54
54
|
height:100%;
|
|
55
55
|
}
|
|
56
56
|
|
|
@@ -58,44 +58,44 @@
|
|
|
58
58
|
--magritte-static-space-300-v21-3-2:12px;
|
|
59
59
|
--magritte-static-space-600-v21-3-2:24px;
|
|
60
60
|
}
|
|
61
|
-
.magritte-select-drop-container-wrapper___OHM0q_10-0-
|
|
61
|
+
.magritte-select-drop-container-wrapper___OHM0q_10-0-15{
|
|
62
62
|
display:flex;
|
|
63
63
|
flex-direction:column;
|
|
64
64
|
}
|
|
65
|
-
.magritte-select-drop-container___hee1p_10-0-
|
|
65
|
+
.magritte-select-drop-container___hee1p_10-0-15{
|
|
66
66
|
display:flex;
|
|
67
67
|
flex-direction:column;
|
|
68
68
|
padding:var(--magritte-static-space-300-v21-3-2);
|
|
69
69
|
margin:calc(-1 * var(--magritte-static-space-300-v21-3-2));
|
|
70
70
|
}
|
|
71
|
-
.magritte-select-drop-container_plain___766zl_10-0-
|
|
71
|
+
.magritte-select-drop-container_plain___766zl_10-0-15{
|
|
72
72
|
padding:var(--magritte-static-space-600-v21-3-2);
|
|
73
73
|
margin:calc(-1 * var(--magritte-static-space-600-v21-3-2));
|
|
74
74
|
}
|
|
75
|
-
.magritte-select-drop___jn4O-_10-0-
|
|
75
|
+
.magritte-select-drop___jn4O-_10-0-15{
|
|
76
76
|
display:flex;
|
|
77
77
|
flex-direction:column;
|
|
78
78
|
gap:8px;
|
|
79
79
|
}
|
|
80
|
-
.magritte-select-drop-header___fMmio_10-0-
|
|
80
|
+
.magritte-select-drop-header___fMmio_10-0-15{
|
|
81
81
|
display:flex;
|
|
82
82
|
flex-direction:column;
|
|
83
83
|
margin-bottom:8px;
|
|
84
84
|
}
|
|
85
|
-
.magritte-select-drop_plain___VL8Fz_10-0-
|
|
85
|
+
.magritte-select-drop_plain___VL8Fz_10-0-15{
|
|
86
86
|
gap:16px;
|
|
87
87
|
}
|
|
88
|
-
.magritte-label-option-plain___BvBH8_10-0-
|
|
88
|
+
.magritte-label-option-plain___BvBH8_10-0-15{
|
|
89
89
|
display:flex;
|
|
90
90
|
justify-content:center;
|
|
91
91
|
}
|
|
92
|
-
.magritte-loading___AMiuq_10-0-
|
|
92
|
+
.magritte-loading___AMiuq_10-0-15{
|
|
93
93
|
display:flex;
|
|
94
94
|
align-items:center;
|
|
95
95
|
height:150px;
|
|
96
96
|
justify-content:center;
|
|
97
97
|
}
|
|
98
|
-
.magritte-hint___6qaFl_10-0-
|
|
98
|
+
.magritte-hint___6qaFl_10-0-15{
|
|
99
99
|
display:flex;
|
|
100
100
|
flex-direction:column;
|
|
101
101
|
align-items:center;
|
|
@@ -115,14 +115,14 @@
|
|
|
115
115
|
--magritte-color-icon-tertiary-v21-3-2:#767676;
|
|
116
116
|
--magritte-color-icon-accent-v21-3-2:#5e9eff;
|
|
117
117
|
}
|
|
118
|
-
.magritte-select-empty-hint___B39XJ_10-0-
|
|
118
|
+
.magritte-select-empty-hint___B39XJ_10-0-15{
|
|
119
119
|
display:flex;
|
|
120
120
|
flex-direction:column;
|
|
121
121
|
justify-content:center;
|
|
122
122
|
align-content:center;
|
|
123
123
|
align-items:center;
|
|
124
124
|
}
|
|
125
|
-
.magritte-icon___F0GQx_10-0-
|
|
125
|
+
.magritte-icon___F0GQx_10-0-15{
|
|
126
126
|
display:flex;
|
|
127
127
|
align-items:center;
|
|
128
128
|
justify-content:center;
|
|
@@ -130,11 +130,11 @@
|
|
|
130
130
|
height:48px;
|
|
131
131
|
border-radius:50%;
|
|
132
132
|
}
|
|
133
|
-
.magritte-icon-init___GWK-V_10-0-
|
|
133
|
+
.magritte-icon-init___GWK-V_10-0-15{
|
|
134
134
|
background-color:var(--magritte-color-background-accent-secondary-v21-3-2);
|
|
135
135
|
--magritte-ui-icon-color-override:var(--magritte-color-icon-accent-v21-3-2);
|
|
136
136
|
}
|
|
137
|
-
.magritte-icon-search___ZsqO-_10-0-
|
|
137
|
+
.magritte-icon-search___ZsqO-_10-0-15{
|
|
138
138
|
background-color:var(--magritte-color-background-secondary-v21-3-2);
|
|
139
139
|
--magritte-ui-icon-color-override:var(--magritte-color-icon-tertiary-v21-3-2);
|
|
140
140
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hh.ru/magritte-ui-select",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.15",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"types": "index.d.ts",
|
|
6
6
|
"sideEffects": [
|
|
@@ -31,25 +31,25 @@
|
|
|
31
31
|
"@hh.ru/magritte-common-fuzzy-search": "1.0.5",
|
|
32
32
|
"@hh.ru/magritte-common-keyboard": "4.1.0",
|
|
33
33
|
"@hh.ru/magritte-common-use-multiple-refs": "1.1.5",
|
|
34
|
-
"@hh.ru/magritte-ui-action": "4.4.
|
|
35
|
-
"@hh.ru/magritte-ui-action-bar": "3.0.
|
|
36
|
-
"@hh.ru/magritte-ui-bottom-sheet": "7.0.
|
|
34
|
+
"@hh.ru/magritte-ui-action": "4.4.33",
|
|
35
|
+
"@hh.ru/magritte-ui-action-bar": "3.0.7",
|
|
36
|
+
"@hh.ru/magritte-ui-bottom-sheet": "7.0.9",
|
|
37
37
|
"@hh.ru/magritte-ui-breakpoint": "5.0.0",
|
|
38
|
-
"@hh.ru/magritte-ui-button": "5.2.
|
|
39
|
-
"@hh.ru/magritte-ui-button-stack": "2.1.
|
|
40
|
-
"@hh.ru/magritte-ui-cell": "4.1.
|
|
41
|
-
"@hh.ru/magritte-ui-checkable-card": "3.0.
|
|
42
|
-
"@hh.ru/magritte-ui-checkbox-radio": "3.0.
|
|
38
|
+
"@hh.ru/magritte-ui-button": "5.2.27",
|
|
39
|
+
"@hh.ru/magritte-ui-button-stack": "2.1.47",
|
|
40
|
+
"@hh.ru/magritte-ui-cell": "4.1.9",
|
|
41
|
+
"@hh.ru/magritte-ui-checkable-card": "3.0.75",
|
|
42
|
+
"@hh.ru/magritte-ui-checkbox-radio": "3.0.43",
|
|
43
43
|
"@hh.ru/magritte-ui-drop": "8.0.4",
|
|
44
|
-
"@hh.ru/magritte-ui-icon": "
|
|
45
|
-
"@hh.ru/magritte-ui-input": "7.1.
|
|
46
|
-
"@hh.ru/magritte-ui-loader": "1.3.
|
|
47
|
-
"@hh.ru/magritte-ui-navigation-bar": "7.0.
|
|
44
|
+
"@hh.ru/magritte-ui-icon": "10.0.0",
|
|
45
|
+
"@hh.ru/magritte-ui-input": "7.1.17",
|
|
46
|
+
"@hh.ru/magritte-ui-loader": "1.3.25",
|
|
47
|
+
"@hh.ru/magritte-ui-navigation-bar": "7.0.7",
|
|
48
48
|
"@hh.ru/magritte-ui-spacing": "2.0.43",
|
|
49
49
|
"@hh.ru/magritte-ui-theme-provider": "1.1.41",
|
|
50
50
|
"@hh.ru/magritte-ui-title": "6.1.4",
|
|
51
|
-
"@hh.ru/magritte-ui-trigger": "3.0.
|
|
51
|
+
"@hh.ru/magritte-ui-trigger": "3.0.30",
|
|
52
52
|
"@hh.ru/magritte-ui-typography": "3.0.31"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "0e4b0b94efe23dfdde06869bd8c294469ce0fe6b"
|
|
55
55
|
}
|