@skbkontur/react-ui 6.0.7-eab55.0 → 6.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/components/Autocomplete/Autocomplete.js +4 -15
- package/components/Autocomplete/Autocomplete.js.map +1 -1
- package/components/Calendar/Calendar.d.ts +14 -14
- package/components/Calendar/Calendar.js +2 -2
- package/components/Calendar/Calendar.js.map +1 -1
- package/components/Calendar/CalendarDay.d.ts +2 -2
- package/components/Calendar/CalendarDay.js +1 -4
- package/components/Calendar/CalendarDay.js.map +1 -1
- package/components/Calendar/DayCellView.styles.d.ts +0 -1
- package/components/Calendar/DayCellView.styles.js +3 -6
- package/components/Calendar/DayCellView.styles.js.map +1 -1
- package/components/Center/Center.d.ts +3 -3
- package/components/Center/Center.js +2 -2
- package/components/Center/Center.js.map +1 -1
- package/components/Checkbox/Checkbox.d.ts +11 -14
- package/components/Checkbox/Checkbox.js +3 -6
- package/components/Checkbox/Checkbox.js.map +1 -1
- package/components/ComboBox/ComboBox.d.ts +3 -3
- package/components/ComboBox/ComboBox.js.map +1 -1
- package/components/DateInput/DateInput.d.ts +15 -15
- package/components/DateInput/DateInput.js +1 -1
- package/components/DateInput/DateInput.js.map +1 -1
- package/components/DatePicker/DatePicker.d.ts +14 -16
- package/components/DatePicker/DatePicker.js +4 -5
- package/components/DatePicker/DatePicker.js.map +1 -1
- package/components/DatePicker/MobilePicker.js +1 -1
- package/components/DatePicker/MobilePicker.js.map +1 -1
- package/components/DateRangePicker/DateRangePicker.d.ts +4 -3
- package/components/DateRangePicker/DateRangePicker.js +6 -4
- package/components/DateRangePicker/DateRangePicker.js.map +1 -1
- package/components/DateRangePicker/DateRangePickerInput.js +9 -6
- package/components/DateRangePicker/DateRangePickerInput.js.map +1 -1
- package/components/Dropdown/Dropdown.d.ts +8 -15
- package/components/Dropdown/Dropdown.js +1 -8
- package/components/Dropdown/Dropdown.js.map +1 -1
- package/components/DropdownMenu/DropdownMenu.d.ts +2 -1
- package/components/DropdownMenu/DropdownMenu.js +2 -1
- package/components/DropdownMenu/DropdownMenu.js.map +1 -1
- package/components/FileUploader/FileUploader.d.ts +4 -6
- package/components/FileUploader/FileUploader.js +1 -3
- package/components/FileUploader/FileUploader.js.map +1 -1
- package/components/FileUploader/FileUploaderFile.d.ts +3 -3
- package/components/FileUploader/FileUploaderFile.js +1 -1
- package/components/FileUploader/FileUploaderFile.js.map +1 -1
- package/components/Hint/Hint.js +10 -3
- package/components/Hint/Hint.js.map +1 -1
- package/components/Input/Input.d.ts +2 -2
- package/components/Input/Input.js.map +1 -1
- package/components/Loader/Loader.d.ts +4 -12
- package/components/Loader/Loader.js +7 -18
- package/components/Loader/Loader.js.map +1 -1
- package/components/MenuFooter/MenuFooter.d.ts +1 -1
- package/components/MenuFooter/MenuFooter.js +1 -1
- package/components/MenuFooter/MenuFooter.js.map +1 -1
- package/components/MenuHeader/MenuHeader.d.ts +2 -2
- package/components/MenuHeader/MenuHeader.js +1 -1
- package/components/MenuHeader/MenuHeader.js.map +1 -1
- package/components/MenuItem/MenuItem.d.ts +1 -1
- package/components/MenuItem/MenuItem.js +16 -24
- package/components/MenuItem/MenuItem.js.map +1 -1
- package/components/MenuItem/MenuItem.styles.d.ts +0 -3
- package/components/MenuItem/MenuItem.styles.js +16 -25
- package/components/MenuItem/MenuItem.styles.js.map +1 -1
- package/components/MenuSeparator/MenuSeparator.d.ts +1 -1
- package/components/MenuSeparator/MenuSeparator.js +1 -1
- package/components/MenuSeparator/MenuSeparator.js.map +1 -1
- package/components/MiniModal/MiniModal.d.ts +1 -1
- package/components/MiniModal/MiniModal.js +1 -1
- package/components/MiniModal/MiniModal.js.map +1 -1
- package/components/MiniModal/MiniModalBody.d.ts +1 -1
- package/components/MiniModal/MiniModalBody.js +1 -1
- package/components/MiniModal/MiniModalBody.js.map +1 -1
- package/components/MiniModal/MiniModalFooter.d.ts +1 -1
- package/components/MiniModal/MiniModalFooter.js +1 -1
- package/components/MiniModal/MiniModalFooter.js.map +1 -1
- package/components/MiniModal/MiniModalHeader.d.ts +1 -1
- package/components/MiniModal/MiniModalHeader.js +1 -1
- package/components/MiniModal/MiniModalHeader.js.map +1 -1
- package/components/Paging/Paging.d.ts +2 -2
- package/components/Paging/Paging.js.map +1 -1
- package/components/Radio/Radio.d.ts +7 -7
- package/components/Radio/Radio.js.map +1 -1
- package/components/RadioGroup/RadioGroup.d.ts +2 -2
- package/components/RadioGroup/RadioGroup.js.map +1 -1
- package/components/Select/Select.d.ts +4 -4
- package/components/Select/Select.js +1 -11
- package/components/Select/Select.js.map +1 -1
- package/components/SingleToast/SingleToast.d.ts +7 -10
- package/components/SingleToast/SingleToast.js +7 -10
- package/components/SingleToast/SingleToast.js.map +1 -1
- package/components/Spinner/Spinner.d.ts +33 -23
- package/components/Spinner/Spinner.js +19 -23
- package/components/Spinner/Spinner.js.map +1 -1
- package/components/Spinner/Spinner.styles.d.ts +3 -0
- package/components/Spinner/Spinner.styles.js +15 -6
- package/components/Spinner/Spinner.styles.js.map +1 -1
- package/components/Sticky/Sticky.d.ts +0 -4
- package/components/Sticky/Sticky.js +0 -4
- package/components/Sticky/Sticky.js.map +1 -1
- package/components/Switcher/Switcher.d.ts +8 -10
- package/components/Switcher/Switcher.js +1 -3
- package/components/Switcher/Switcher.js.map +1 -1
- package/components/Textarea/Textarea.js +1 -1
- package/components/Textarea/Textarea.js.map +1 -1
- package/components/Textarea/Textarea.styles.d.ts +0 -1
- package/components/Textarea/Textarea.styles.js +4 -7
- package/components/Textarea/Textarea.styles.js.map +1 -1
- package/components/Textarea/TextareaCounter.d.ts +0 -2
- package/components/Textarea/TextareaCounter.js +4 -22
- package/components/Textarea/TextareaCounter.js.map +1 -1
- package/components/Toast/Toast.d.ts +14 -13
- package/components/Toast/Toast.js +3 -3
- package/components/Toast/Toast.js.map +1 -1
- package/components/Toast/ToastView.d.ts +5 -8
- package/components/Toast/ToastView.js +8 -28
- package/components/Toast/ToastView.js.map +1 -1
- package/components/Toast/ToastView.styles.d.ts +0 -7
- package/components/Toast/ToastView.styles.js +8 -30
- package/components/Toast/ToastView.styles.js.map +1 -1
- package/components/Tooltip/Tooltip.d.ts +4 -4
- package/components/Tooltip/Tooltip.js.map +1 -1
- package/index.d.ts +0 -1
- package/index.js +0 -1
- package/index.js.map +1 -1
- package/internal/CloseButtonIcon/CloseButtonIcon.js +1 -1
- package/internal/CloseButtonIcon/CloseButtonIcon.js.map +1 -1
- package/internal/CommonWrapper/CommonWrapper.js +0 -5
- package/internal/CommonWrapper/CommonWrapper.js.map +1 -1
- package/internal/CustomComboBox/ComboBoxMenu.js +1 -1
- package/internal/CustomComboBox/ComboBoxMenu.js.map +1 -1
- package/internal/CustomComboBox/ComboBoxView.js +2 -13
- package/internal/CustomComboBox/ComboBoxView.js.map +1 -1
- package/internal/Menu/Menu.js +0 -3
- package/internal/Menu/Menu.js.map +1 -1
- package/internal/Menu/Menu.styles.d.ts +0 -1
- package/internal/Menu/Menu.styles.js +10 -13
- package/internal/Menu/Menu.styles.js.map +1 -1
- package/internal/MenuMessage/MenuMessage.js +1 -17
- package/internal/MenuMessage/MenuMessage.js.map +1 -1
- package/internal/MenuMessage/MenuMessage.styles.d.ts +0 -3
- package/internal/MenuMessage/MenuMessage.styles.js +4 -13
- package/internal/MenuMessage/MenuMessage.styles.js.map +1 -1
- package/internal/MobilePopup/MobilePopup.d.ts +0 -8
- package/internal/MobilePopup/MobilePopup.js +11 -34
- package/internal/MobilePopup/MobilePopup.js.map +1 -1
- package/internal/MobilePopup/MobilePopup.styles.d.ts +0 -7
- package/internal/MobilePopup/MobilePopup.styles.js +10 -34
- package/internal/MobilePopup/MobilePopup.styles.js.map +1 -1
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.d.ts +1 -8
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.js +1 -18
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.js.map +1 -1
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.styles.d.ts +0 -3
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.styles.js +4 -14
- package/internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.styles.js.map +1 -1
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.d.ts +0 -4
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.js +11 -48
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.js.map +1 -1
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.styles.d.ts +0 -6
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.styles.js +8 -28
- package/internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.styles.js.map +1 -1
- package/internal/Popup/Popup.d.ts +4 -6
- package/internal/Popup/Popup.js +13 -38
- package/internal/Popup/Popup.js.map +1 -1
- package/internal/Popup/PopupHelper.d.ts +4 -0
- package/internal/Popup/PopupHelper.js +31 -0
- package/internal/Popup/PopupHelper.js.map +1 -1
- package/internal/PopupMenu/PopupMenu.d.ts +2 -1
- package/internal/PopupMenu/PopupMenu.js +21 -18
- package/internal/PopupMenu/PopupMenu.js.map +1 -1
- package/internal/SpinnerIcon/SpinnerIcon.d.ts +3 -3
- package/internal/SpinnerIcon/SpinnerIcon.js +4 -4
- package/internal/SpinnerIcon/SpinnerIcon.js.map +1 -1
- package/internal/icons2022/LoadingIcon.js +1 -1
- package/internal/icons2022/LoadingIcon.js.map +1 -1
- package/internal/themes/BasicTheme.d.ts +4 -51
- package/internal/themes/BasicTheme.js +6 -173
- package/internal/themes/BasicTheme.js.map +1 -1
- package/lib/getMenuPositions.js +11 -11
- package/lib/getMenuPositions.js.map +1 -1
- package/lib/theming/themes/DarkTheme.d.ts +0 -1
- package/lib/theming/themes/DarkTheme.js +1 -3
- package/lib/theming/themes/DarkTheme.js.map +1 -1
- package/lib/theming/themes/LightTheme.d.ts +0 -1
- package/lib/theming/themes/LightTheme.js +1 -3
- package/lib/theming/themes/LightTheme.js.map +1 -1
- package/package.json +1 -5
- package/components/TimePicker/TimeClockIcon.d.ts +0 -3
- package/components/TimePicker/TimeClockIcon.js +0 -11
- package/components/TimePicker/TimeClockIcon.js.map +0 -1
- package/components/TimePicker/TimeFragmentsView.d.ts +0 -15
- package/components/TimePicker/TimeFragmentsView.js +0 -72
- package/components/TimePicker/TimeFragmentsView.js.map +0 -1
- package/components/TimePicker/TimeFragmentsView.styles.d.ts +0 -12
- package/components/TimePicker/TimeFragmentsView.styles.js +0 -43
- package/components/TimePicker/TimeFragmentsView.styles.js.map +0 -1
- package/components/TimePicker/TimeInput.d.ts +0 -21
- package/components/TimePicker/TimeInput.js +0 -98
- package/components/TimePicker/TimeInput.js.map +0 -1
- package/components/TimePicker/TimePicker.d.ts +0 -59
- package/components/TimePicker/TimePicker.js +0 -478
- package/components/TimePicker/TimePicker.js.map +0 -1
- package/components/TimePicker/TimePicker.styles.d.ts +0 -11
- package/components/TimePicker/TimePicker.styles.js +0 -36
- package/components/TimePicker/TimePicker.styles.js.map +0 -1
- package/components/TimePicker/TimePickerMobilePopup.d.ts +0 -31
- package/components/TimePicker/TimePickerMobilePopup.js +0 -21
- package/components/TimePicker/TimePickerMobilePopup.js.map +0 -1
- package/components/TimePicker/TimePickerPopup.d.ts +0 -19
- package/components/TimePicker/TimePickerPopup.js +0 -18
- package/components/TimePicker/TimePickerPopup.js.map +0 -1
- package/components/TimePicker/TimePickerSlots.d.ts +0 -16
- package/components/TimePicker/TimePickerSlots.js +0 -67
- package/components/TimePicker/TimePickerSlots.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.constants.d.ts +0 -18
- package/components/TimePicker/helpers/TimePicker.constants.js +0 -41
- package/components/TimePicker/helpers/TimePicker.constants.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.editing.d.ts +0 -6
- package/components/TimePicker/helpers/TimePicker.editing.js +0 -86
- package/components/TimePicker/helpers/TimePicker.editing.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.layout.d.ts +0 -7
- package/components/TimePicker/helpers/TimePicker.layout.js +0 -17
- package/components/TimePicker/helpers/TimePicker.layout.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.selection.d.ts +0 -7
- package/components/TimePicker/helpers/TimePicker.selection.js +0 -51
- package/components/TimePicker/helpers/TimePicker.selection.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.shared.d.ts +0 -23
- package/components/TimePicker/helpers/TimePicker.shared.js +0 -50
- package/components/TimePicker/helpers/TimePicker.shared.js.map +0 -1
- package/components/TimePicker/helpers/TimePicker.value.d.ts +0 -8
- package/components/TimePicker/helpers/TimePicker.value.js +0 -61
- package/components/TimePicker/helpers/TimePicker.value.js.map +0 -1
- package/components/TimePicker/helpers/scrollSelectedSlotIntoView.d.ts +0 -1
- package/components/TimePicker/helpers/scrollSelectedSlotIntoView.js +0 -21
- package/components/TimePicker/helpers/scrollSelectedSlotIntoView.js.map +0 -1
- package/components/TimePicker/hooks/useTimePickerDropdown.d.ts +0 -17
- package/components/TimePicker/hooks/useTimePickerDropdown.js +0 -62
- package/components/TimePicker/hooks/useTimePickerDropdown.js.map +0 -1
- package/components/TimePicker/hooks/useTimePickerSelection.d.ts +0 -15
- package/components/TimePicker/hooks/useTimePickerSelection.js +0 -43
- package/components/TimePicker/hooks/useTimePickerSelection.js.map +0 -1
- package/components/TimePicker/hooks/useTimePickerValue.d.ts +0 -18
- package/components/TimePicker/hooks/useTimePickerValue.js +0 -48
- package/components/TimePicker/hooks/useTimePickerValue.js.map +0 -1
- package/components/TimePicker/index.d.ts +0 -2
- package/components/TimePicker/index.js +0 -2
- package/components/TimePicker/index.js.map +0 -1
- package/internal/NativeTimeInput/NativeTimeInput.d.ts +0 -16
- package/internal/NativeTimeInput/NativeTimeInput.js +0 -25
- package/internal/NativeTimeInput/NativeTimeInput.js.map +0 -1
- package/internal/NativeTimeInput/NativeTimeInput.styles.d.ts +0 -3
- package/internal/NativeTimeInput/NativeTimeInput.styles.js +0 -15
- package/internal/NativeTimeInput/NativeTimeInput.styles.js.map +0 -1
- package/internal/NativeTimeInput/index.d.ts +0 -1
- package/internal/NativeTimeInput/index.js +0 -2
- package/internal/NativeTimeInput/index.js.map +0 -1
- package/internal/NativeTimeInput/utils.d.ts +0 -7
- package/internal/NativeTimeInput/utils.js +0 -28
- package/internal/NativeTimeInput/utils.js.map +0 -1
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon16Light.d.ts +0 -2
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon16Light.js +0 -21
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon16Light.js.map +0 -1
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon20Regular.d.ts +0 -2
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon20Regular.js +0 -21
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon20Regular.js.map +0 -1
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon24Regular.d.ts +0 -2
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon24Regular.js +0 -21
- package/internal/icons2022/QuestionCircleIcon/QuestionCircleIcon24Regular.js.map +0 -1
- package/internal/icons2022/TimeClockIcon/TimeClockIcon16Light.d.ts +0 -2
- package/internal/icons2022/TimeClockIcon/TimeClockIcon16Light.js +0 -20
- package/internal/icons2022/TimeClockIcon/TimeClockIcon16Light.js.map +0 -1
- package/internal/icons2022/TimeClockIcon/TimeClockIcon20Light.d.ts +0 -2
- package/internal/icons2022/TimeClockIcon/TimeClockIcon20Light.js +0 -20
- package/internal/icons2022/TimeClockIcon/TimeClockIcon20Light.js.map +0 -1
- package/internal/icons2022/TimeClockIcon/TimeClockIcon24Regular.d.ts +0 -2
- package/internal/icons2022/TimeClockIcon/TimeClockIcon24Regular.js +0 -20
- package/internal/icons2022/TimeClockIcon/TimeClockIcon24Regular.js.map +0 -1
- package/internal/themes/DarkTheme6_1.d.ts +0 -1
- package/internal/themes/DarkTheme6_1.js +0 -164
- package/internal/themes/DarkTheme6_1.js.map +0 -1
- package/internal/themes/LightTheme6_1.d.ts +0 -1
- package/internal/themes/LightTheme6_1.js +0 -164
- package/internal/themes/LightTheme6_1.js.map +0 -1
|
@@ -5,53 +5,29 @@ var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cook
|
|
|
5
5
|
import { memoizeGetStyles } from '../../lib/theming/Emotion.js';
|
|
6
6
|
export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
7
7
|
var css = _a.css;
|
|
8
|
-
|
|
9
|
-
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n overflow-y: scroll;\n &::-webkit-scrollbar {\n width: 0;\n }\n "], ["\n background-color: ", ";\n overflow-y: scroll;\n &::-webkit-scrollbar {\n width: 0;\n }\n "])), t.bgDefault);
|
|
10
|
-
};
|
|
11
|
-
return {
|
|
8
|
+
return ({
|
|
12
9
|
root: function (t) {
|
|
13
|
-
return css(
|
|
10
|
+
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n width: 100%;\n height: 100%;\n flex-direction: column;\n display: flex;\n justify-content: flex-end;\n border-radius: ", ";\n overflow: hidden;\n padding-bottom: ", ";\n background: ", ";\n "], ["\n width: 100%;\n height: 100%;\n flex-direction: column;\n display: flex;\n justify-content: flex-end;\n border-radius: ", ";\n overflow: hidden;\n padding-bottom: ", ";\n background: ", ";\n "])), t.mobilePopupContainerBorderRadius, t.mobilePopupContainerBottomPadding, t.menuBgDefault);
|
|
14
11
|
},
|
|
15
12
|
wrapper: function () {
|
|
16
|
-
return css(
|
|
13
|
+
return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n overflow: auto;\n "], ["\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n overflow: auto;\n "])));
|
|
17
14
|
},
|
|
18
15
|
content: function (t) {
|
|
19
|
-
return css(
|
|
16
|
+
return css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n background-color: ", ";\n "], ["\n background-color: ", ";\n "])), t.bgDefault);
|
|
20
17
|
},
|
|
21
18
|
container: function (t) {
|
|
22
|
-
return css(
|
|
23
|
-
},
|
|
24
|
-
root_6_1: function (t) {
|
|
25
|
-
return css(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n width: 100%;\n height: 100%;\n flex-direction: column;\n display: flex;\n justify-content: flex-end;\n border-radius: ", ";\n overflow: hidden;\n background: ", ";\n\n max-height: calc(100vh - (2 * ", "));\n max-height: calc(100dvh - (2 * ", "));\n "], ["\n width: 100%;\n height: 100%;\n flex-direction: column;\n display: flex;\n justify-content: flex-end;\n border-radius: ", ";\n overflow: hidden;\n background: ", ";\n\n max-height: calc(100vh - (2 * ", "));\n max-height: calc(100dvh - (2 * ", "));\n "])), t.mobilePopupContainerBorderRadius, t.menuBgDefault, t.mobilePopupPositionY, t.mobilePopupPositionY);
|
|
26
|
-
},
|
|
27
|
-
wrapper_6_1: function (t) {
|
|
28
|
-
return css(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n position: fixed;\n top: ", ";\n bottom: ", ";\n right: ", ";\n left: ", ";\n display: flex;\n align-items: center;\n "], ["\n position: fixed;\n top: ", ";\n bottom: ", ";\n right: ", ";\n left: ", ";\n display: flex;\n align-items: center;\n "])), t.mobilePopupPositionY, t.mobilePopupPositionY, t.mobilePopupPositionX, t.mobilePopupPositionX);
|
|
29
|
-
},
|
|
30
|
-
contentSmall_6_1: function (t) {
|
|
31
|
-
return css(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n ", "\n padding: ", ";\n "], ["\n ", "\n padding: ", ";\n "])), content_6_1(t), t.mobilePopupPaddingSmall);
|
|
32
|
-
},
|
|
33
|
-
contentMedium_6_1: function (t) {
|
|
34
|
-
return css(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n ", "\n padding: ", ";\n "], ["\n ", "\n padding: ", ";\n "])), content_6_1(t), t.mobilePopupPaddingMedium);
|
|
35
|
-
},
|
|
36
|
-
contentLarge_6_1: function (t) {
|
|
37
|
-
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n ", "\n padding: ", ";\n "], ["\n ", "\n padding: ", ";\n "])), content_6_1(t), t.mobilePopupPaddingLarge);
|
|
38
|
-
},
|
|
39
|
-
containerBase_6_1: function (t) {
|
|
40
|
-
return css(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n position: absolute;\n z-index: 100000;\n min-width: calc(100vw - (2 * ", "));\n "], ["\n position: absolute;\n z-index: 100000;\n min-width: calc(100vw - (2 * ", "));\n "])), t.mobilePopupPositionX);
|
|
41
|
-
},
|
|
42
|
-
containerBottom_6_1: function (t) {
|
|
43
|
-
return css(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n bottom: 0;\n max-height: calc(100vh - (2 * ", "));\n "], ["\n bottom: 0;\n max-height: calc(100vh - (2 * ", "));\n "])), t.mobilePopupPositionY);
|
|
19
|
+
return css(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n position: absolute;\n top: ", ";\n left: ", ";\n right: ", ";\n z-index: 100000;\n "], ["\n position: absolute;\n top: ", ";\n left: ", ";\n right: ", ";\n z-index: 100000;\n "])), t.mobilePopupTopPadding, t.mobilePopupOuterIndentY, t.mobilePopupOuterIndentY);
|
|
44
20
|
},
|
|
45
21
|
bg: function () {
|
|
46
|
-
return css(
|
|
22
|
+
return css(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n z-index: 9999;\n touch-action: none;\n background: #333333;\n opacity: 50%;\n "], ["\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n z-index: 9999;\n touch-action: none;\n background: #333333;\n opacity: 50%;\n "])));
|
|
47
23
|
},
|
|
48
24
|
bottomIndent: function () {
|
|
49
|
-
return css(
|
|
25
|
+
return css(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n height: 80px;\n "], ["\n height: 80px;\n "])));
|
|
50
26
|
},
|
|
51
27
|
zIndex: function () {
|
|
52
|
-
return css(
|
|
28
|
+
return css(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n position: relative;\n "], ["\n position: relative;\n "])));
|
|
53
29
|
},
|
|
54
|
-
};
|
|
30
|
+
});
|
|
55
31
|
});
|
|
56
|
-
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7
|
|
32
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7;
|
|
57
33
|
//# sourceMappingURL=MobilePopup.styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobilePopup.styles.js","sourceRoot":"","sources":["../../../internal/MobilePopup/MobilePopup.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;
|
|
1
|
+
{"version":3,"file":"MobilePopup.styles.js","sourceRoot":"","sources":["../../../internal/MobilePopup/MobilePopup.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QACjE,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,sTAAA,yJAMS,EAAkC,oDAEjC,EAAmC,uBACvC,EAAe,SAC9B,KAJkB,CAAC,CAAC,gCAAgC,EAEjC,CAAC,CAAC,iCAAiC,EACvC,CAAC,CAAC,aAAa,EAC7B;QACJ,CAAC;QAED,OAAO;YACL,OAAO,GAAG,4LAAA,yHAOT,KAAC;QACJ,CAAC;QAED,OAAO,YAAC,CAAQ;YACd,OAAO,GAAG,0GAAA,4BACY,EAAW,SAChC,KADqB,CAAC,CAAC,SAAS,EAC/B;QACJ,CAAC;QAED,SAAS,YAAC,CAAQ;YAChB,OAAO,GAAG,uLAAA,0CAED,EAAuB,iBACtB,EAAyB,kBACxB,EAAyB,iCAEnC,KAJQ,CAAC,CAAC,qBAAqB,EACtB,CAAC,CAAC,uBAAuB,EACxB,CAAC,CAAC,uBAAuB,EAElC;QACJ,CAAC;QAED,EAAE;YACA,OAAO,GAAG,uQAAA,oMAUT,KAAC;QACJ,CAAC;QAED,YAAY;YACV,OAAO,GAAG,gGAAA,6BAET,KAAC;QACJ,CAAC;QAED,MAAM;YACJ,OAAO,GAAG,sGAAA,mCAET,KAAC;QACJ,CAAC;KACF,CAAC;AAnEgE,CAmEhE,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root(t: Theme) {\n return css`\n width: 100%;\n height: 100%;\n flex-direction: column;\n display: flex;\n justify-content: flex-end;\n border-radius: ${t.mobilePopupContainerBorderRadius};\n overflow: hidden;\n padding-bottom: ${t.mobilePopupContainerBottomPadding};\n background: ${t.menuBgDefault};\n `;\n },\n\n wrapper() {\n return css`\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n overflow: auto;\n `;\n },\n\n content(t: Theme) {\n return css`\n background-color: ${t.bgDefault};\n `;\n },\n\n container(t: Theme) {\n return css`\n position: absolute;\n top: ${t.mobilePopupTopPadding};\n left: ${t.mobilePopupOuterIndentY};\n right: ${t.mobilePopupOuterIndentY};\n z-index: 100000;\n `;\n },\n\n bg() {\n return css`\n position: fixed;\n top: 0;\n bottom: 0;\n right: 0;\n left: 0;\n z-index: 9999;\n touch-action: none;\n background: #333333;\n opacity: 50%;\n `;\n },\n\n bottomIndent() {\n return css`\n height: 80px;\n `;\n },\n\n zIndex() {\n return css`\n position: relative;\n `;\n },\n}));\n"]}
|
|
@@ -1,16 +1,9 @@
|
|
|
1
|
-
import type { PropsWithChildren } from 'react';
|
|
2
1
|
import React from 'react';
|
|
3
|
-
|
|
4
|
-
interface Props extends PropsWithChildren {
|
|
5
|
-
size?: SizeProp;
|
|
6
|
-
}
|
|
7
|
-
export declare class MobilePopupFooter extends React.Component<Props> {
|
|
2
|
+
export declare class MobilePopupFooter extends React.Component<React.PropsWithChildren> {
|
|
8
3
|
static __KONTUR_REACT_UI__: string;
|
|
9
4
|
private jsStyles;
|
|
10
5
|
private emotion;
|
|
11
6
|
private theme;
|
|
12
7
|
render(): React.JSX.Element;
|
|
13
8
|
private renderMain;
|
|
14
|
-
private getRootSizeClassName_6_1;
|
|
15
9
|
}
|
|
16
|
-
export {};
|
|
@@ -22,24 +22,11 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
22
22
|
import React from 'react';
|
|
23
23
|
import { withRenderEnvironment } from '../../../lib/renderEnvironment/index.js';
|
|
24
24
|
import { ThemeContext } from '../../../lib/theming/ThemeContext.js';
|
|
25
|
-
import { isThemeGTE } from '../../../lib/theming/ThemeHelpers.js';
|
|
26
25
|
import { getJsStyles } from './MobilePopupFooter.styles.js';
|
|
27
26
|
var MobilePopupFooter = /** @class */ (function (_super) {
|
|
28
27
|
__extends(MobilePopupFooter, _super);
|
|
29
28
|
function MobilePopupFooter() {
|
|
30
|
-
|
|
31
|
-
_this.getRootSizeClassName_6_1 = function () {
|
|
32
|
-
switch (_this.props.size) {
|
|
33
|
-
case 'large':
|
|
34
|
-
return _this.jsStyles.rootLarge_6_1(_this.theme);
|
|
35
|
-
case 'medium':
|
|
36
|
-
return _this.jsStyles.rootMedium_6_1(_this.theme);
|
|
37
|
-
case 'small':
|
|
38
|
-
default:
|
|
39
|
-
return _this.jsStyles.rootSmall_6_1(_this.theme);
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
return _this;
|
|
29
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
43
30
|
}
|
|
44
31
|
MobilePopupFooter.prototype.render = function () {
|
|
45
32
|
var _this = this;
|
|
@@ -50,14 +37,10 @@ var MobilePopupFooter = /** @class */ (function (_super) {
|
|
|
50
37
|
}));
|
|
51
38
|
};
|
|
52
39
|
MobilePopupFooter.prototype.renderMain = function () {
|
|
53
|
-
var themeGTE6_1 = isThemeGTE(this.theme, '6.1');
|
|
54
40
|
var children = this.props.children;
|
|
55
41
|
if (!children || !React.isValidElement(children)) {
|
|
56
42
|
return null;
|
|
57
43
|
}
|
|
58
|
-
if (themeGTE6_1) {
|
|
59
|
-
return React.createElement("div", { className: this.getRootSizeClassName_6_1() }, children);
|
|
60
|
-
}
|
|
61
44
|
return React.createElement("div", { className: this.jsStyles.root(this.theme) }, children);
|
|
62
45
|
};
|
|
63
46
|
MobilePopupFooter.__KONTUR_REACT_UI__ = 'MobileMenuFooter';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobilePopupFooter.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"MobilePopupFooter.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,yCAAyC,CAAC;AAEhF,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAG5D;IAAuC,qCAAwC;IAA/E;;IA6BA,CAAC;IAtBQ,kCAAM,GAAb;QAAA,iBAWC;QAVC,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAE1C,OAAO,CACL,oBAAC,YAAY,CAAC,QAAQ,QACnB,UAAC,KAAK;YACL,KAAI,CAAC,KAAK,GAAG,KAAK,CAAC;YACnB,OAAO,KAAI,CAAC,UAAU,EAAE,CAAC;QAC3B,CAAC,CACqB,CACzB,CAAC;IACJ,CAAC;IAEO,sCAAU,GAAlB;QACU,IAAA,QAAQ,GAAK,IAAI,CAAC,KAAK,SAAf,CAAgB;QAEhC,IAAI,CAAC,QAAQ,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,QAAQ,CAAC,EAAE,CAAC;YACjD,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO,6BAAK,SAAS,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAG,QAAQ,CAAO,CAAC;IAC1E,CAAC;IA3Ba,qCAAmB,GAAG,kBAAkB,AAArB,CAAsB;IAD5C,iBAAiB;QAD7B,qBAAqB;OACT,iBAAiB,CA6B7B;IAAD,wBAAC;CAAA,AA7BD,CAAuC,KAAK,CAAC,SAAS,GA6BrD;SA7BY,iBAAiB","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\nimport React from 'react';\n\nimport { withRenderEnvironment } from '../../../lib/renderEnvironment/index.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\nimport { ThemeContext } from '../../../lib/theming/ThemeContext.js';\nimport { getJsStyles } from './MobilePopupFooter.styles.js';\n\n@withRenderEnvironment\nexport class MobilePopupFooter extends React.Component<React.PropsWithChildren> {\n public static __KONTUR_REACT_UI__ = 'MobileMenuFooter';\n\n private jsStyles!: ReturnType<typeof getJsStyles>;\n private emotion!: Emotion;\n private theme!: Theme;\n\n public render() {\n this.jsStyles = getJsStyles(this.emotion);\n\n return (\n <ThemeContext.Consumer>\n {(theme) => {\n this.theme = theme;\n return this.renderMain();\n }}\n </ThemeContext.Consumer>\n );\n }\n\n private renderMain() {\n const { children } = this.props;\n\n if (!children || !React.isValidElement(children)) {\n return null;\n }\n\n return <div className={this.jsStyles.root(this.theme)}>{children}</div>;\n }\n}\n"]}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import type { Theme } from '../../../lib/theming/Theme.js';
|
|
2
2
|
export declare const getJsStyles: import("../../../lib/theming/Emotion.js").StylesGetter<{
|
|
3
3
|
root(t: Theme): string;
|
|
4
|
-
rootSmall_6_1(t: Theme): string;
|
|
5
|
-
rootMedium_6_1(t: Theme): string;
|
|
6
|
-
rootLarge_6_1(t: Theme): string;
|
|
7
4
|
}>;
|
|
@@ -5,21 +5,11 @@ var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cook
|
|
|
5
5
|
import { memoizeGetStyles } from '../../../lib/theming/Emotion.js';
|
|
6
6
|
export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
7
7
|
var css = _a.css;
|
|
8
|
-
|
|
9
|
-
return {
|
|
8
|
+
return ({
|
|
10
9
|
root: function (t) {
|
|
11
|
-
return css(
|
|
10
|
+
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n position: relative;\n display: flex;\n flex-direction: column;\n padding: ", ";\n "], ["\n position: relative;\n display: flex;\n flex-direction: column;\n padding: ", ";\n "])), t.mobilePopupHeaderPadding);
|
|
12
11
|
},
|
|
13
|
-
|
|
14
|
-
return css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), rootBase_6_1(t), t.mobilePopupFooterPaddingSmall);
|
|
15
|
-
},
|
|
16
|
-
rootMedium_6_1: function (t) {
|
|
17
|
-
return css(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), rootBase_6_1(t), t.mobilePopupFooterPaddingMedium);
|
|
18
|
-
},
|
|
19
|
-
rootLarge_6_1: function (t) {
|
|
20
|
-
return css(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), rootBase_6_1(t), t.mobilePopupFooterPaddingLarge);
|
|
21
|
-
},
|
|
22
|
-
};
|
|
12
|
+
});
|
|
23
13
|
});
|
|
24
|
-
var templateObject_1
|
|
14
|
+
var templateObject_1;
|
|
25
15
|
//# sourceMappingURL=MobilePopupFooter.styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobilePopupFooter.styles.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;
|
|
1
|
+
{"version":3,"file":"MobilePopupFooter.styles.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupFooter/MobilePopupFooter.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QACjE,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,iLAAA,mGAIG,EAA0B,SACtC,KADY,CAAC,CAAC,wBAAwB,EACrC;QACJ,CAAC;KACF,CAAC;AATgE,CAShE,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../../lib/theming/Emotion.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root(t: Theme) {\n return css`\n position: relative;\n display: flex;\n flex-direction: column;\n padding: ${t.mobilePopupHeaderPadding};\n `;\n },\n}));\n"]}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { SizeProp } from '../../../lib/types/props.js';
|
|
3
2
|
interface MobilePopupHeaderProps {
|
|
4
3
|
/**
|
|
5
4
|
* Заголовок шапки
|
|
6
5
|
*/
|
|
7
6
|
caption?: string;
|
|
8
|
-
size?: SizeProp;
|
|
9
7
|
}
|
|
10
8
|
export declare class MobilePopupHeader extends React.Component<React.PropsWithChildren<MobilePopupHeaderProps>> {
|
|
11
9
|
static __KONTUR_REACT_UI__: string;
|
|
@@ -16,7 +14,5 @@ export declare class MobilePopupHeader extends React.Component<React.PropsWithCh
|
|
|
16
14
|
private theme;
|
|
17
15
|
render(): React.JSX.Element;
|
|
18
16
|
private renderMain;
|
|
19
|
-
private getContainerClassName_6_1;
|
|
20
|
-
private getRootSizeClassName_6_1;
|
|
21
17
|
}
|
|
22
18
|
export {};
|
|
@@ -22,36 +22,12 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
22
22
|
import React from 'react';
|
|
23
23
|
import { withRenderEnvironment } from '../../../lib/renderEnvironment/index.js';
|
|
24
24
|
import { ThemeContext } from '../../../lib/theming/ThemeContext.js';
|
|
25
|
-
import { isThemeGTE } from '../../../lib/theming/ThemeHelpers.js';
|
|
26
25
|
import { isNonNullable } from '../../../lib/utils.js';
|
|
27
26
|
import { getJsStyles } from './MobilePopupHeader.styles.js';
|
|
28
27
|
var MobilePopupHeader = /** @class */ (function (_super) {
|
|
29
28
|
__extends(MobilePopupHeader, _super);
|
|
30
29
|
function MobilePopupHeader() {
|
|
31
|
-
|
|
32
|
-
_this.getContainerClassName_6_1 = function () {
|
|
33
|
-
switch (_this.props.size) {
|
|
34
|
-
case 'large':
|
|
35
|
-
return _this.jsStyles.containerLarge_6_1(_this.theme);
|
|
36
|
-
case 'medium':
|
|
37
|
-
return _this.jsStyles.containerMedium_6_1(_this.theme);
|
|
38
|
-
case 'small':
|
|
39
|
-
default:
|
|
40
|
-
return _this.jsStyles.containerSmall_6_1(_this.theme);
|
|
41
|
-
}
|
|
42
|
-
};
|
|
43
|
-
_this.getRootSizeClassName_6_1 = function () {
|
|
44
|
-
switch (_this.props.size) {
|
|
45
|
-
case 'large':
|
|
46
|
-
return _this.jsStyles.rootLarge_6_1(_this.theme);
|
|
47
|
-
case 'medium':
|
|
48
|
-
return _this.jsStyles.rootMedium_6_1(_this.theme);
|
|
49
|
-
case 'small':
|
|
50
|
-
default:
|
|
51
|
-
return _this.jsStyles.rootSmall_6_1(_this.theme);
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
return _this;
|
|
30
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
55
31
|
}
|
|
56
32
|
MobilePopupHeader.prototype.render = function () {
|
|
57
33
|
var _this = this;
|
|
@@ -62,30 +38,17 @@ var MobilePopupHeader = /** @class */ (function (_super) {
|
|
|
62
38
|
}));
|
|
63
39
|
};
|
|
64
40
|
MobilePopupHeader.prototype.renderMain = function () {
|
|
65
|
-
var _a, _b
|
|
66
|
-
var
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
}
|
|
72
|
-
return (React.createElement("div", { className: this.getRootSizeClassName_6_1() },
|
|
73
|
-
React.createElement("div", { className: this.getContainerClassName_6_1() },
|
|
74
|
-
caption && (React.createElement("div", { className: this.cx((_a = {},
|
|
75
|
-
_a[this.jsStyles.caption(this.theme)] = true,
|
|
76
|
-
_a[this.jsStyles.captionWithChildren()] = isNonNullable(children),
|
|
77
|
-
_a)) }, caption)),
|
|
78
|
-
React.isValidElement(children) && React.createElement("div", null, children))));
|
|
79
|
-
}
|
|
80
|
-
return (React.createElement("div", { className: this.cx((_b = {},
|
|
81
|
-
_b[this.jsStyles.root(this.theme)] = true,
|
|
82
|
-
_b[this.jsStyles.rootWithoutContent()] = !caption && !children,
|
|
83
|
-
_b)) },
|
|
41
|
+
var _a, _b;
|
|
42
|
+
var _c = this.props, caption = _c.caption, children = _c.children;
|
|
43
|
+
return (React.createElement("div", { className: this.cx((_a = {},
|
|
44
|
+
_a[this.jsStyles.root(this.theme)] = true,
|
|
45
|
+
_a[this.jsStyles.rootWithoutContent()] = !caption && !children,
|
|
46
|
+
_a)) },
|
|
84
47
|
React.createElement("div", { className: this.jsStyles.container() },
|
|
85
|
-
caption && (React.createElement("div", { className: this.cx((
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
48
|
+
caption && (React.createElement("div", { className: this.cx((_b = {},
|
|
49
|
+
_b[this.jsStyles.caption(this.theme)] = true,
|
|
50
|
+
_b[this.jsStyles.captionWithChildren()] = isNonNullable(children),
|
|
51
|
+
_b)) }, caption)),
|
|
89
52
|
React.isValidElement(children) && React.createElement("div", null, children))));
|
|
90
53
|
};
|
|
91
54
|
MobilePopupHeader.__KONTUR_REACT_UI__ = 'MobileMenuHeader';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobilePopupHeader.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"MobilePopupHeader.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,yCAAyC,CAAC;AAEhF,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AACpE,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAU5D;IAAuC,qCAAgE;IAAvG;;IAgDA,CAAC;IAvCQ,kCAAM,GAAb;QAAA,iBAWC;QAVC,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAE1C,OAAO,CACL,oBAAC,YAAY,CAAC,QAAQ,QACnB,UAAC,KAAK;YACL,KAAI,CAAC,KAAK,GAAG,KAAK,CAAC;YACnB,OAAO,KAAI,CAAC,UAAU,EAAE,CAAC;QAC3B,CAAC,CACqB,CACzB,CAAC;IACJ,CAAC;IAEO,sCAAU,GAAlB;;QACQ,IAAA,KAAwB,IAAI,CAAC,KAAK,EAAhC,OAAO,aAAA,EAAE,QAAQ,cAAe,CAAC;QAEzC,OAAO,CACL,6BACE,SAAS,EAAE,IAAI,CAAC,EAAE;gBAChB,GAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAG,IAAI;gBACtC,GAAC,IAAI,CAAC,QAAQ,CAAC,kBAAkB,EAAE,IAAG,CAAC,OAAO,IAAI,CAAC,QAAQ;oBAC3D;YAEF,6BAAK,SAAS,EAAE,IAAI,CAAC,QAAQ,CAAC,SAAS,EAAE;gBACtC,OAAO,IAAI,CACV,6BACE,SAAS,EAAE,IAAI,CAAC,EAAE;wBAChB,GAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,IAAG,IAAI;wBACzC,GAAC,IAAI,CAAC,QAAQ,CAAC,mBAAmB,EAAE,IAAG,aAAa,CAAC,QAAQ,CAAC;4BAC9D,IAED,OAAO,CACJ,CACP;gBACA,KAAK,CAAC,cAAc,CAAC,QAAQ,CAAC,IAAI,iCAAM,QAAQ,CAAO,CACpD,CACF,CACP,CAAC;IACJ,CAAC;IA9Ca,qCAAmB,GAAG,kBAAkB,AAArB,CAAsB;IACzC,6BAAW,GAAG,kBAAkB,AAArB,CAAsB;IAFpC,iBAAiB;QAD7B,qBAAqB;OACT,iBAAiB,CAgD7B;IAAD,wBAAC;CAAA,AAhDD,CAAuC,KAAK,CAAC,SAAS,GAgDrD;SAhDY,iBAAiB","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\nimport React from 'react';\n\nimport { withRenderEnvironment } from '../../../lib/renderEnvironment/index.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\nimport { ThemeContext } from '../../../lib/theming/ThemeContext.js';\nimport { isNonNullable } from '../../../lib/utils.js';\nimport { getJsStyles } from './MobilePopupHeader.styles.js';\n\ninterface MobilePopupHeaderProps {\n /**\n * Заголовок шапки\n */\n caption?: string;\n}\n\n@withRenderEnvironment\nexport class MobilePopupHeader extends React.Component<React.PropsWithChildren<MobilePopupHeaderProps>> {\n public static __KONTUR_REACT_UI__ = 'MobileMenuHeader';\n public static displayName = 'MobileMenuHeader';\n\n private emotion!: Emotion;\n private cx!: Emotion['cx'];\n private jsStyles!: ReturnType<typeof getJsStyles>;\n private theme!: Theme;\n\n public render() {\n this.jsStyles = getJsStyles(this.emotion);\n\n return (\n <ThemeContext.Consumer>\n {(theme) => {\n this.theme = theme;\n return this.renderMain();\n }}\n </ThemeContext.Consumer>\n );\n }\n\n private renderMain() {\n const { caption, children } = this.props;\n\n return (\n <div\n className={this.cx({\n [this.jsStyles.root(this.theme)]: true,\n [this.jsStyles.rootWithoutContent()]: !caption && !children,\n })}\n >\n <div className={this.jsStyles.container()}>\n {caption && (\n <div\n className={this.cx({\n [this.jsStyles.caption(this.theme)]: true,\n [this.jsStyles.captionWithChildren()]: isNonNullable(children),\n })}\n >\n {caption}\n </div>\n )}\n {React.isValidElement(children) && <div>{children}</div>}\n </div>\n </div>\n );\n }\n}\n"]}
|
|
@@ -3,12 +3,6 @@ export declare const getJsStyles: import("../../../lib/theming/Emotion.js").Styl
|
|
|
3
3
|
root(t: Theme): string;
|
|
4
4
|
rootWithoutContent(): string;
|
|
5
5
|
container(): string;
|
|
6
|
-
rootSmall_6_1(t: Theme): string;
|
|
7
|
-
rootMedium_6_1(t: Theme): string;
|
|
8
|
-
rootLarge_6_1(t: Theme): string;
|
|
9
|
-
containerSmall_6_1(t: Theme): string;
|
|
10
|
-
containerMedium_6_1(t: Theme): string;
|
|
11
|
-
containerLarge_6_1(t: Theme): string;
|
|
12
6
|
caption(t: Theme): string;
|
|
13
7
|
captionWithChildren(): string;
|
|
14
8
|
}>;
|
|
@@ -5,43 +5,23 @@ var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cook
|
|
|
5
5
|
import { memoizeGetStyles } from '../../../lib/theming/Emotion.js';
|
|
6
6
|
export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
7
7
|
var css = _a.css;
|
|
8
|
-
|
|
9
|
-
var containerBase_6_1 = function () { return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n "], ["\n display: flex;\n flex-direction: column;\n "]))); };
|
|
10
|
-
return {
|
|
8
|
+
return ({
|
|
11
9
|
root: function (t) {
|
|
12
|
-
return css(
|
|
10
|
+
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n position: relative;\n padding: ", ";\n "], ["\n position: relative;\n padding: ", ";\n "])), t.mobilePopupHeaderPadding);
|
|
13
11
|
},
|
|
14
12
|
rootWithoutContent: function () {
|
|
15
|
-
return css(
|
|
13
|
+
return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n padding: 8px 0 0 0;\n "], ["\n padding: 8px 0 0 0;\n "])));
|
|
16
14
|
},
|
|
17
15
|
container: function () {
|
|
18
|
-
return css(
|
|
19
|
-
},
|
|
20
|
-
rootSmall_6_1: function (t) {
|
|
21
|
-
return css(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n ", ";\n padding-top: ", ";\n "], ["\n ", ";\n padding-top: ", ";\n "])), rootBase_6_1(t), t.mobilePopupPaddingSmall);
|
|
22
|
-
},
|
|
23
|
-
rootMedium_6_1: function (t) {
|
|
24
|
-
return css(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n ", ";\n padding-top: ", ";\n "], ["\n ", ";\n padding-top: ", ";\n "])), rootBase_6_1(t), t.mobilePopupPaddingMedium);
|
|
25
|
-
},
|
|
26
|
-
rootLarge_6_1: function (t) {
|
|
27
|
-
return css(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n ", ";\n padding-top: ", ";\n "], ["\n ", ";\n padding-top: ", ";\n "])), rootBase_6_1(t), t.mobilePopupPaddingLarge);
|
|
28
|
-
},
|
|
29
|
-
containerSmall_6_1: function (t) {
|
|
30
|
-
return css(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), containerBase_6_1(), t.mobilePopupHeaderPaddingSmall);
|
|
31
|
-
},
|
|
32
|
-
containerMedium_6_1: function (t) {
|
|
33
|
-
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), containerBase_6_1(), t.mobilePopupHeaderPaddingMedium);
|
|
34
|
-
},
|
|
35
|
-
containerLarge_6_1: function (t) {
|
|
36
|
-
return css(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n ", ";\n padding: ", ";\n "], ["\n ", ";\n padding: ", ";\n "])), containerBase_6_1(), t.mobilePopupHeaderPaddingLarge);
|
|
16
|
+
return css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n display: flex;\n flex-direction: column;\n "], ["\n display: flex;\n flex-direction: column;\n "])));
|
|
37
17
|
},
|
|
38
18
|
caption: function (t) {
|
|
39
|
-
return css(
|
|
19
|
+
return css(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n font-size: ", ";\n line-height: ", ";\n font-weight: ", ";\n color: ", ";\n "], ["\n font-size: ", ";\n line-height: ", ";\n font-weight: ", ";\n color: ", ";\n "])), t.mobilePopupHeaderFontSize, t.mobilePopupHeaderLineHeight, t.mobilePopupHeaderFontWeight, t.textColorDefault);
|
|
40
20
|
},
|
|
41
21
|
captionWithChildren: function () {
|
|
42
|
-
return css(
|
|
22
|
+
return css(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n padding-bottom: 8px;\n "], ["\n padding-bottom: 8px;\n "])));
|
|
43
23
|
},
|
|
44
|
-
};
|
|
24
|
+
});
|
|
45
25
|
});
|
|
46
|
-
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5
|
|
26
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5;
|
|
47
27
|
//# sourceMappingURL=MobilePopupHeader.styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobilePopupHeader.styles.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;
|
|
1
|
+
{"version":3,"file":"MobilePopupHeader.styles.js","sourceRoot":"","sources":["../../../../internal/MobilePopup/MobilePopupHeader/MobilePopupHeader.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QACjE,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,4HAAA,8CAEG,EAA0B,SACtC,KADY,CAAC,CAAC,wBAAwB,EACrC;QACJ,CAAC;QAED,kBAAkB;YAChB,OAAO,GAAG,sGAAA,mCAET,KAAC;QACJ,CAAC;QAED,SAAS;YACP,OAAO,GAAG,gIAAA,6DAGT,KAAC;QACJ,CAAC;QAED,OAAO,YAAC,CAAQ;YACd,OAAO,GAAG,2KAAA,qBACK,EAA2B,wBACzB,EAA6B,wBAC7B,EAA6B,kBACnC,EAAkB,SAC5B,KAJc,CAAC,CAAC,yBAAyB,EACzB,CAAC,CAAC,2BAA2B,EAC7B,CAAC,CAAC,2BAA2B,EACnC,CAAC,CAAC,gBAAgB,EAC3B;QACJ,CAAC;QAED,mBAAmB;YACjB,OAAO,GAAG,uGAAA,oCAET,KAAC;QACJ,CAAC;KACF,CAAC;AAnCgE,CAmChE,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../../lib/theming/Emotion.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root(t: Theme) {\n return css`\n position: relative;\n padding: ${t.mobilePopupHeaderPadding};\n `;\n },\n\n rootWithoutContent() {\n return css`\n padding: 8px 0 0 0;\n `;\n },\n\n container() {\n return css`\n display: flex;\n flex-direction: column;\n `;\n },\n\n caption(t: Theme) {\n return css`\n font-size: ${t.mobilePopupHeaderFontSize};\n line-height: ${t.mobilePopupHeaderLineHeight};\n font-weight: ${t.mobilePopupHeaderFontWeight};\n color: ${t.textColorDefault};\n `;\n },\n\n captionWithChildren() {\n return css`\n padding-bottom: 8px;\n `;\n },\n}));\n"]}
|
|
@@ -5,10 +5,10 @@ import type { FocusEventType, MouseEventType } from '../../typings/event-types.j
|
|
|
5
5
|
import type { Nullable } from '../../typings/utility-types.js';
|
|
6
6
|
import type { CommonProps } from '../CommonWrapper/index.js';
|
|
7
7
|
import type { Priority } from '../ZIndex/index.js';
|
|
8
|
-
export declare const PopupNonPinnablePositions:
|
|
9
|
-
export declare const PopupPinnablePositions:
|
|
10
|
-
export declare const PopupPositions: readonly
|
|
11
|
-
export declare const DefaultPosition:
|
|
8
|
+
export declare const PopupNonPinnablePositions: readonly ["middle center", "middle left", "middle right"];
|
|
9
|
+
export declare const PopupPinnablePositions: readonly ["top center", "top left", "top right", "bottom center", "bottom left", "bottom right", "left middle", "left top", "left bottom", "right middle", "right top", "right bottom"];
|
|
10
|
+
export declare const PopupPositions: readonly ["top center", "top left", "top right", "bottom center", "bottom left", "bottom right", "left middle", "left top", "left bottom", "right middle", "right top", "right bottom", "middle center", "middle left", "middle right"];
|
|
11
|
+
export declare const DefaultPosition: "top center";
|
|
12
12
|
export type PopupPositionsType = (typeof PopupPositions)[number];
|
|
13
13
|
export type PopupPinnablePositionsType = (typeof PopupPinnablePositions)[number];
|
|
14
14
|
export type ShortPopupPositionsType = 'top' | 'bottom' | 'left' | 'right';
|
|
@@ -197,7 +197,5 @@ export declare class Popup extends React.Component<PopupProps, PopupState> {
|
|
|
197
197
|
private getRelativeShift;
|
|
198
198
|
private getCoordinates;
|
|
199
199
|
private getPinOffset;
|
|
200
|
-
private getHorizontalPosition;
|
|
201
|
-
private getVerticalPosition;
|
|
202
200
|
}
|
|
203
201
|
export {};
|
package/internal/Popup/Popup.js
CHANGED
|
@@ -81,6 +81,9 @@ export var PopupPinnablePositions = [
|
|
|
81
81
|
];
|
|
82
82
|
export var PopupPositions = __spreadArray(__spreadArray([], PopupPinnablePositions, true), PopupNonPinnablePositions, true);
|
|
83
83
|
export var DefaultPosition = PopupPositions[0];
|
|
84
|
+
var isPopupNonPinnablePosition = function (position) {
|
|
85
|
+
return PopupNonPinnablePositions.includes(position);
|
|
86
|
+
};
|
|
84
87
|
export var DUMMY_LOCATION = {
|
|
85
88
|
position: DefaultPosition,
|
|
86
89
|
coordinates: {
|
|
@@ -383,7 +386,7 @@ var Popup = /** @class */ (function (_super) {
|
|
|
383
386
|
var hasPin = this.getProps().hasPin;
|
|
384
387
|
var position = PopupHelper.getPositionObject(positionName);
|
|
385
388
|
return (hasPin &&
|
|
386
|
-
!
|
|
389
|
+
!isPopupNonPinnablePosition(positionName) && (React.createElement(PopupPin, { popupElement: this.lastPopupContentElement, popupPosition: positionName, size: pinSize || parseInt(this.theme.popupPinSize), offset: this.getPinOffset(position.align), backgroundColor: backgroundColor || this.theme.popupBackground })));
|
|
387
390
|
};
|
|
388
391
|
Popup.prototype.delayUpdateLocation = function () {
|
|
389
392
|
var _a, _b;
|
|
@@ -584,36 +587,36 @@ var Popup = /** @class */ (function (_super) {
|
|
|
584
587
|
: parseInt(this.theme.popupMargin) || 0;
|
|
585
588
|
var position = PopupHelper.getPositionObject(positionName);
|
|
586
589
|
var popupOffset = this.getProps().popupOffset + this.getPinnedPopupOffset(anchorRect, position);
|
|
587
|
-
var
|
|
590
|
+
var getDefaultCoordinates = function () { return ({
|
|
588
591
|
top: anchorRect.top - popupRect.height - margin,
|
|
589
|
-
left:
|
|
590
|
-
};
|
|
592
|
+
left: PopupHelper.getHorizontalPosition(anchorRect, popupRect, position.align, popupOffset),
|
|
593
|
+
}); };
|
|
591
594
|
switch (position.direction) {
|
|
592
595
|
case 'top':
|
|
593
|
-
return
|
|
596
|
+
return getDefaultCoordinates();
|
|
594
597
|
case 'middle':
|
|
595
598
|
return {
|
|
596
599
|
top: anchorRect.top + anchorRect.height / 2 - popupRect.height / 2,
|
|
597
|
-
left:
|
|
600
|
+
left: PopupHelper.getHorizontalPosition(anchorRect, popupRect, position.align, popupOffset),
|
|
598
601
|
};
|
|
599
602
|
case 'bottom':
|
|
600
603
|
return {
|
|
601
604
|
top: anchorRect.top + anchorRect.height + margin,
|
|
602
|
-
left:
|
|
605
|
+
left: PopupHelper.getHorizontalPosition(anchorRect, popupRect, position.align, popupOffset),
|
|
603
606
|
};
|
|
604
607
|
case 'left':
|
|
605
608
|
return {
|
|
606
|
-
top:
|
|
609
|
+
top: PopupHelper.getVerticalPosition(anchorRect, popupRect, position.align, popupOffset),
|
|
607
610
|
left: anchorRect.left - popupRect.width - margin,
|
|
608
611
|
};
|
|
609
612
|
case 'right':
|
|
610
613
|
return {
|
|
611
|
-
top:
|
|
614
|
+
top: PopupHelper.getVerticalPosition(anchorRect, popupRect, position.align, popupOffset),
|
|
612
615
|
left: anchorRect.left + anchorRect.width + margin,
|
|
613
616
|
};
|
|
614
617
|
default:
|
|
615
618
|
warning(false, "Unexpected align '".concat(position.direction, "'. Must be one of - 'top', 'bottom', 'left', 'right', 'center', 'middle'. Returning default value."));
|
|
616
|
-
return
|
|
619
|
+
return getDefaultCoordinates();
|
|
617
620
|
}
|
|
618
621
|
};
|
|
619
622
|
Popup.prototype.getPinOffset = function (align) {
|
|
@@ -634,34 +637,6 @@ var Popup = /** @class */ (function (_super) {
|
|
|
634
637
|
return defaultPinOffset;
|
|
635
638
|
}
|
|
636
639
|
};
|
|
637
|
-
Popup.prototype.getHorizontalPosition = function (anchorRect, popupRect, align, popupOffset) {
|
|
638
|
-
var defaultHorizontalPosition = anchorRect.left - (popupRect.width - anchorRect.width) / 2;
|
|
639
|
-
switch (align) {
|
|
640
|
-
case 'left':
|
|
641
|
-
return anchorRect.left - popupOffset;
|
|
642
|
-
case 'center':
|
|
643
|
-
return defaultHorizontalPosition;
|
|
644
|
-
case 'right':
|
|
645
|
-
return anchorRect.left - (popupRect.width - anchorRect.width) + popupOffset;
|
|
646
|
-
default:
|
|
647
|
-
warning(false, "Unexpected align '".concat(align, "'. Must be one of - 'left', 'center', 'right'. Returning default value."));
|
|
648
|
-
return defaultHorizontalPosition;
|
|
649
|
-
}
|
|
650
|
-
};
|
|
651
|
-
Popup.prototype.getVerticalPosition = function (anchorRect, popupRect, align, popupOffset) {
|
|
652
|
-
var defaultVerticalPosition = anchorRect.top - popupOffset;
|
|
653
|
-
switch (align) {
|
|
654
|
-
case 'top':
|
|
655
|
-
return defaultVerticalPosition;
|
|
656
|
-
case 'middle':
|
|
657
|
-
return anchorRect.top - (popupRect.height - anchorRect.height) / 2;
|
|
658
|
-
case 'bottom':
|
|
659
|
-
return anchorRect.top - (popupRect.height - anchorRect.height) + popupOffset;
|
|
660
|
-
default:
|
|
661
|
-
warning(false, "Unexpected align '".concat(align, "'. Must be one of - 'top', 'middle', 'bottom'. Returning default value."));
|
|
662
|
-
return defaultVerticalPosition;
|
|
663
|
-
}
|
|
664
|
-
};
|
|
665
640
|
var Popup_1;
|
|
666
641
|
Popup.__KONTUR_REACT_UI__ = 'Popup';
|
|
667
642
|
Popup.displayName = 'Popup';
|