@sima-land/ui-nucleons 45.0.0-alpha.4 → 45.0.0-alpha.6
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/_internal/custom-scrollbar/index.js +6 -27
- package/_internal/custom-scrollbar/index.js.map +1 -0
- package/_internal/dropdown-loading/index.js +3 -3
- package/_internal/dropdown-loading/index.js.map +1 -0
- package/_internal/page-scroll-lock/adapters/body-scroll-lock.js +5 -1
- package/_internal/page-scroll-lock/adapters/body-scroll-lock.js.map +1 -0
- package/_internal/page-scroll-lock/adapters/ui-nucleons.js +1 -0
- package/_internal/page-scroll-lock/adapters/ui-nucleons.js.map +1 -0
- package/_internal/page-scroll-lock/context.js +4 -25
- package/_internal/page-scroll-lock/context.js.map +1 -0
- package/_internal/page-scroll-lock/hook.js +1 -0
- package/_internal/page-scroll-lock/hook.js.map +1 -0
- package/_internal/page-scroll-lock/index.js +1 -0
- package/_internal/page-scroll-lock/index.js.map +1 -0
- package/_internal/page-scroll-lock/types.js +1 -0
- package/_internal/page-scroll-lock/types.js.map +1 -0
- package/_internal/utils/dropdown.js +1 -0
- package/_internal/utils/dropdown.js.map +1 -0
- package/alert/index.d.ts +2 -2
- package/alert/index.js +6 -31
- package/alert/index.js.map +1 -0
- package/arrow-button/index.js +20 -32
- package/arrow-button/index.js.map +1 -0
- package/autocomplete/autocomplete.js +60 -95
- package/autocomplete/autocomplete.js.map +1 -0
- package/autocomplete/index.js +1 -0
- package/autocomplete/index.js.map +1 -0
- package/autocomplete/types.js +1 -0
- package/autocomplete/types.js.map +1 -0
- package/autocomplete-deprecated/index.d.ts +1 -1
- package/autocomplete-deprecated/index.js +45 -80
- package/autocomplete-deprecated/index.js.map +1 -0
- package/avatar/avatar.module.scss +3 -1
- package/avatar/index.d.ts +1 -1
- package/avatar/index.js +12 -33
- package/avatar/index.js.map +1 -0
- package/avatar/user.d.ts +1 -1
- package/avatar/user.js +9 -29
- package/avatar/user.js.map +1 -0
- package/avatar/utils.js +1 -0
- package/avatar/utils.js.map +1 -0
- package/base-input/base-input.js +11 -48
- package/base-input/base-input.js.map +1 -0
- package/base-input/index.js +1 -0
- package/base-input/index.js.map +1 -0
- package/base-input/types.js +1 -0
- package/base-input/types.js.map +1 -0
- package/base-input/utils.js +2 -1
- package/base-input/utils.js.map +1 -0
- package/base-input-deprecated/index.d.ts +2 -2
- package/base-input-deprecated/index.js +11 -48
- package/base-input-deprecated/index.js.map +1 -0
- package/bordered-layout/index.d.ts +1 -1
- package/bordered-layout/index.js +3 -3
- package/bordered-layout/index.js.map +1 -0
- package/bottom-bar/bottom-bar.js +4 -16
- package/bottom-bar/bottom-bar.js.map +1 -0
- package/bottom-bar/index.js +1 -0
- package/bottom-bar/index.js.map +1 -0
- package/bottom-bar/types.js +1 -0
- package/bottom-bar/types.js.map +1 -0
- package/box/index.d.ts +1 -1
- package/box/index.js +3 -2
- package/box/index.js.map +1 -0
- package/button/index.d.ts +2 -2
- package/button/index.js +8 -45
- package/button/index.js.map +1 -0
- package/card/index.js +4 -21
- package/card/index.js.map +1 -0
- package/card/slots.d.ts +1 -1
- package/card/slots.js +12 -46
- package/card/slots.js.map +1 -0
- package/card/utils.js +1 -0
- package/card/utils.js.map +1 -0
- package/carousel/draggable.d.ts +1 -1
- package/carousel/draggable.js +6 -28
- package/carousel/draggable.js.map +1 -0
- package/carousel/helpers/draggable-event.js +1 -0
- package/carousel/helpers/draggable-event.js.map +1 -0
- package/carousel/index.d.ts +1 -1
- package/carousel/index.js +22 -43
- package/carousel/index.js.map +1 -0
- package/checkbox/index.d.ts +2 -2
- package/checkbox/index.js +6 -45
- package/checkbox/index.js.map +1 -0
- package/checkbox-field/index.d.ts +3 -2
- package/checkbox-field/index.js +8 -47
- package/checkbox-field/index.js.map +1 -0
- package/chips/index.d.ts +1 -1
- package/chips/index.js +4 -39
- package/chips/index.js.map +1 -0
- package/chips/item.d.ts +1 -1
- package/chips/item.js +4 -5
- package/chips/item.js.map +1 -0
- package/clean-buttons/index.d.ts +1 -0
- package/clean-buttons/index.js +8 -41
- package/clean-buttons/index.js.map +1 -0
- package/clean-buttons/types.js +1 -0
- package/clean-buttons/types.js.map +1 -0
- package/clean-buttons/utils.js +1 -0
- package/clean-buttons/utils.js.map +1 -0
- package/colors/index.js +1 -0
- package/colors/index.js.map +1 -0
- package/context/viewport.js +1 -0
- package/context/viewport.js.map +1 -0
- package/dot-nav/index.d.ts +1 -1
- package/dot-nav/index.js +13 -34
- package/dot-nav/index.js.map +1 -0
- package/dropdown/index.d.ts +2 -2
- package/dropdown/index.js +5 -39
- package/dropdown/index.js.map +1 -0
- package/dropdown/utils.js +1 -0
- package/dropdown/utils.js.map +1 -0
- package/dropdown-item/index.d.ts +1 -1
- package/dropdown-item/index.js +6 -22
- package/dropdown-item/index.js.map +1 -0
- package/dropdown-item/types.js +1 -0
- package/dropdown-item/types.js.map +1 -0
- package/dropdown-item/utils.js +1 -0
- package/dropdown-item/utils.js.map +1 -0
- package/expandable/index.d.ts +2 -2
- package/expandable/index.js +15 -36
- package/expandable/index.js.map +1 -0
- package/expandable/utils.js +1 -0
- package/expandable/utils.js.map +1 -0
- package/field-block/index.js +3 -9
- package/field-block/index.js.map +1 -0
- package/field-grid/index.d.ts +7 -1
- package/field-grid/index.js +50 -66
- package/field-grid/index.js.map +1 -0
- package/file-icon/index.d.ts +1 -1
- package/file-icon/index.js +7 -23
- package/file-icon/index.js.map +1 -0
- package/group-overflow/index.js +9 -44
- package/group-overflow/index.js.map +1 -0
- package/group-overflow/utils.js +1 -0
- package/group-overflow/utils.js.map +1 -0
- package/helpers/bounds-of.js +1 -0
- package/helpers/bounds-of.js.map +1 -0
- package/helpers/center-of.js +1 -0
- package/helpers/center-of.js.map +1 -0
- package/helpers/create-container.js +1 -0
- package/helpers/create-container.js.map +1 -0
- package/helpers/define-slots.d.ts +1 -1
- package/helpers/define-slots.js +1 -0
- package/helpers/define-slots.js.map +1 -0
- package/helpers/events.d.ts +1 -1
- package/helpers/events.js +1 -0
- package/helpers/events.js.map +1 -0
- package/helpers/find-child-element.js +1 -0
- package/helpers/find-child-element.js.map +1 -0
- package/helpers/find-offset-parent.js +1 -0
- package/helpers/find-offset-parent.js.map +1 -0
- package/helpers/find-sibling-index.js +1 -0
- package/helpers/find-sibling-index.js.map +1 -0
- package/helpers/fit-element-height.js +1 -0
- package/helpers/fit-element-height.js.map +1 -0
- package/helpers/format-date.js +1 -0
- package/helpers/format-date.js.map +1 -0
- package/helpers/format-number.js +1 -0
- package/helpers/format-number.js.map +1 -0
- package/helpers/get-date-interval-data.js +1 -0
- package/helpers/get-date-interval-data.js.map +1 -0
- package/helpers/get-declination.js +1 -0
- package/helpers/get-declination.js.map +1 -0
- package/helpers/get-fraction-depth.js +1 -0
- package/helpers/get-fraction-depth.js.map +1 -0
- package/helpers/get-no-index.js +1 -0
- package/helpers/get-no-index.js.map +1 -0
- package/helpers/get-relative-pos.js +1 -0
- package/helpers/get-relative-pos.js.map +1 -0
- package/helpers/get-scroll-parent.js +1 -0
- package/helpers/get-scroll-parent.js.map +1 -0
- package/helpers/is-browser.js +1 -0
- package/helpers/is-browser.js.map +1 -0
- package/helpers/is-fully-scrolled.js +1 -0
- package/helpers/is-fully-scrolled.js.map +1 -0
- package/helpers/is-touch-device.js +1 -0
- package/helpers/is-touch-device.js.map +1 -0
- package/helpers/layer.js +1 -0
- package/helpers/layer.js.map +1 -0
- package/helpers/max-index-of.js +1 -0
- package/helpers/max-index-of.js.map +1 -0
- package/helpers/media-query-list.js +1 -0
- package/helpers/media-query-list.js.map +1 -0
- package/helpers/on.d.ts +1 -1
- package/helpers/on.js +1 -0
- package/helpers/on.js.map +1 -0
- package/helpers/point.js +1 -0
- package/helpers/point.js.map +1 -0
- package/helpers/rename.js +1 -0
- package/helpers/rename.js.map +1 -0
- package/helpers/scroll-to-child.js +1 -0
- package/helpers/scroll-to-child.js.map +1 -0
- package/helpers/styles.js +1 -0
- package/helpers/styles.js.map +1 -0
- package/helpers/with-prevent.js +1 -0
- package/helpers/with-prevent.js.map +1 -0
- package/hint/hint-view.js +6 -18
- package/hint/hint-view.js.map +1 -0
- package/hint/hint.js +6 -23
- package/hint/hint.js.map +1 -0
- package/hint/index.js +1 -0
- package/hint/index.js.map +1 -0
- package/hint/utils.js +23 -4
- package/hint/utils.js.map +1 -0
- package/hint-deprecated/index.d.ts +2 -2
- package/hint-deprecated/index.js +4 -40
- package/hint-deprecated/index.js.map +1 -0
- package/hooks/breakpoint/index.js +4 -25
- package/hooks/breakpoint/index.js.map +1 -0
- package/hooks/breakpoint/types.js +1 -0
- package/hooks/breakpoint/types.js.map +1 -0
- package/hooks/breakpoint/utils.js +1 -0
- package/hooks/breakpoint/utils.js.map +1 -0
- package/hooks/identity.js +1 -0
- package/hooks/identity.js.map +1 -0
- package/hooks/index.js +1 -0
- package/hooks/index.js.map +1 -0
- package/hooks/intersection/index.js +1 -0
- package/hooks/intersection/index.js.map +1 -0
- package/hooks/intersection/test-utils.js +6 -2
- package/hooks/intersection/test-utils.js.map +1 -0
- package/hooks/keydown.js +1 -0
- package/hooks/keydown.js.map +1 -0
- package/hooks/media.js +1 -0
- package/hooks/media.js.map +1 -0
- package/hooks/styles.js +1 -0
- package/hooks/styles.js.map +1 -0
- package/info-text/index.js +16 -42
- package/info-text/index.js.map +1 -0
- package/input/index.js +34 -58
- package/input/index.js.map +1 -0
- package/input/utils.js +1 -0
- package/input/utils.js.map +1 -0
- package/layout/index.js +1 -0
- package/layout/index.js.map +1 -0
- package/layout/layout.js +4 -15
- package/layout/layout.js.map +1 -0
- package/layout/legacy.d.ts +5 -5
- package/layout/legacy.js +4 -39
- package/layout/legacy.js.map +1 -0
- package/layout/types.js +1 -0
- package/layout/types.js.map +1 -0
- package/link/index.d.ts +6 -3
- package/link/index.js +5 -38
- package/link/index.js.map +1 -0
- package/loading-overlay/index.d.ts +1 -1
- package/loading-overlay/index.js +3 -3
- package/loading-overlay/index.js.map +1 -0
- package/masked-field/index.d.ts +2 -2
- package/masked-field/index.js +11 -40
- package/masked-field/index.js.map +1 -0
- package/masked-input/hook.js +1 -0
- package/masked-input/hook.js.map +1 -0
- package/masked-input/index.js +1 -0
- package/masked-input/index.js.map +1 -0
- package/masked-input/masked-input.js +11 -41
- package/masked-input/masked-input.js.map +1 -0
- package/masked-input/types.js +1 -0
- package/masked-input/types.js.map +1 -0
- package/masked-input/utils.js +1 -0
- package/masked-input/utils.js.map +1 -0
- package/modal/index.d.ts +1 -1
- package/modal/index.js +4 -10
- package/modal/index.js.map +1 -0
- package/modal/slots.js +10 -45
- package/modal/slots.js.map +1 -0
- package/modal/utils.js +1 -0
- package/modal/utils.js.map +1 -0
- package/modal-overlay/index.js +8 -39
- package/modal-overlay/index.js.map +1 -0
- package/modal-overlay/utils.js +1 -0
- package/modal-overlay/utils.js.map +1 -0
- package/no-index/index.d.ts +3 -3
- package/no-index/index.js +5 -8
- package/no-index/index.js.map +1 -0
- package/no-index-mark/index.d.ts +2 -2
- package/no-index-mark/index.js +8 -6
- package/no-index-mark/index.js.map +1 -0
- package/package.json +7 -14
- package/pagination/index.d.ts +4 -20
- package/pagination/index.js +10 -15
- package/pagination/index.js.map +1 -0
- package/pagination/pagination-item.d.ts +8 -0
- package/pagination/pagination-item.js +20 -0
- package/pagination/pagination-item.js.map +1 -0
- package/pagination/pagination-item.module.scss +49 -0
- package/pagination/pagination.d.ts +8 -0
- package/pagination/pagination.js +98 -0
- package/pagination/pagination.js.map +1 -0
- package/pagination/pagination.module.scss +15 -70
- package/pagination/types.d.ts +28 -0
- package/pagination/types.js +3 -0
- package/pagination/types.js.map +1 -0
- package/pagination/utils.d.ts +25 -41
- package/pagination/utils.js +51 -85
- package/pagination/utils.js.map +1 -0
- package/{pagination → pagination-deprecated}/base-pagination.d.ts +6 -1
- package/{pagination → pagination-deprecated}/base-pagination.js +34 -47
- package/pagination-deprecated/base-pagination.js.map +1 -0
- package/pagination-deprecated/index.d.ts +22 -0
- package/pagination-deprecated/index.js +16 -0
- package/pagination-deprecated/index.js.map +1 -0
- package/{pagination → pagination-deprecated}/page-button.d.ts +2 -1
- package/pagination-deprecated/page-button.js +17 -0
- package/pagination-deprecated/page-button.js.map +1 -0
- package/pagination-deprecated/pagination.module.scss +76 -0
- package/pagination-deprecated/utils.d.ts +58 -0
- package/pagination-deprecated/utils.js +125 -0
- package/pagination-deprecated/utils.js.map +1 -0
- package/panel/index.js +4 -6
- package/panel/index.js.map +1 -0
- package/phone-input/images/armenia.png +0 -0
- package/phone-input/images/azerbaijan.png +0 -0
- package/phone-input/images/belarus.png +0 -0
- package/phone-input/images/georgia.png +0 -0
- package/phone-input/images/kazakhstan.png +0 -0
- package/phone-input/images/kyrgyzstan.png +0 -0
- package/phone-input/images/moldova.png +0 -0
- package/phone-input/images/other.png +0 -0
- package/phone-input/images/russia.png +0 -0
- package/phone-input/images/tajikistan.png +0 -0
- package/phone-input/images/turkmenistan.png +0 -0
- package/phone-input/images/ukraine.png +0 -0
- package/phone-input/images/uzbekistan.png +0 -0
- package/phone-input/index.js +1 -0
- package/phone-input/index.js.map +1 -0
- package/phone-input/phone-input.js +27 -56
- package/phone-input/phone-input.js.map +1 -0
- package/phone-input/presets.js +4 -1
- package/phone-input/presets.js.map +1 -0
- package/phone-input/types.js +1 -0
- package/phone-input/types.js.map +1 -0
- package/phone-input/utils.js +1 -0
- package/phone-input/utils.js.map +1 -0
- package/phone-input-deprecated/index.d.ts +1 -1
- package/phone-input-deprecated/index.js +43 -71
- package/phone-input-deprecated/index.js.map +1 -0
- package/plate/index.d.ts +2 -2
- package/plate/index.js +5 -38
- package/plate/index.js.map +1 -0
- package/popup/index.js +1 -0
- package/popup/index.js.map +1 -0
- package/popup/popup-view.js +5 -19
- package/popup/popup-view.js.map +1 -0
- package/popup/popup.js +11 -42
- package/popup/popup.js.map +1 -0
- package/popup/utils.js +1 -0
- package/popup/utils.js.map +1 -0
- package/portal/index.d.ts +1 -1
- package/portal/index.js +1 -0
- package/portal/index.js.map +1 -0
- package/price/index.js +3 -2
- package/price/index.js.map +1 -0
- package/price/utils.js +1 -0
- package/price/utils.js.map +1 -0
- package/radio-button/index.js +4 -17
- package/radio-button/index.js.map +1 -0
- package/range/index.d.ts +1 -1
- package/range/index.js +7 -33
- package/range/index.js.map +1 -0
- package/rating/index.d.ts +1 -1
- package/rating/index.js +5 -23
- package/rating/index.js.map +1 -0
- package/rating/types.js +1 -0
- package/rating/types.js.map +1 -0
- package/rating/utils.js +1 -0
- package/rating/utils.js.map +1 -0
- package/screen/index.d.ts +5 -5
- package/screen/index.js +12 -37
- package/screen/index.js.map +1 -0
- package/screen/slots.d.ts +3 -3
- package/screen/slots.js +31 -62
- package/screen/slots.js.map +1 -0
- package/screen/utils.js +1 -0
- package/screen/utils.js.map +1 -0
- package/select/index.js +1 -0
- package/select/index.js.map +1 -0
- package/select/parts/block.js +20 -32
- package/select/parts/block.js.map +1 -0
- package/select/parts/button.js +9 -42
- package/select/parts/button.js.map +1 -0
- package/select/parts/menu.js +14 -46
- package/select/parts/menu.js.map +1 -0
- package/select/select.js +28 -47
- package/select/select.js.map +1 -0
- package/select/types.js +1 -0
- package/select/types.js.map +1 -0
- package/select/utils.js +1 -0
- package/select/utils.js.map +1 -0
- package/select-deprecated/index.d.ts +1 -1
- package/select-deprecated/index.js +34 -69
- package/select-deprecated/index.js.map +1 -0
- package/side-page/index.js +12 -45
- package/side-page/index.js.map +1 -0
- package/side-page/slots.js +7 -19
- package/side-page/slots.js.map +1 -0
- package/spinner/index.d.ts +1 -1
- package/spinner/index.js +4 -5
- package/spinner/index.js.map +1 -0
- package/spinner/spinner.module.scss +3 -1
- package/stepper/index.d.ts +2 -2
- package/stepper/index.js +14 -52
- package/stepper/index.js.map +1 -0
- package/stroked-svg/index.d.ts +2 -2
- package/stroked-svg/index.js +4 -41
- package/stroked-svg/index.js.map +1 -0
- package/styling/borders.js +1 -0
- package/styling/borders.js.map +1 -0
- package/styling/colors.js +1 -0
- package/styling/colors.js.map +1 -0
- package/styling/fonts.js +1 -0
- package/styling/fonts.js.map +1 -0
- package/styling/shadows.js +1 -0
- package/styling/shadows.js.map +1 -0
- package/styling/shapes.js +1 -0
- package/styling/shapes.js.map +1 -0
- package/styling/sizes.js +1 -0
- package/styling/sizes.js.map +1 -0
- package/styling/sizes.module.scss +3 -1
- package/styling/utils.js +1 -0
- package/styling/utils.js.map +1 -0
- package/super-ellipse-clip-path/index.js +3 -8
- package/super-ellipse-clip-path/index.js.map +1 -0
- package/switcher-row/index.js +6 -10
- package/switcher-row/index.js.map +1 -0
- package/tabs/index.d.ts +1 -1
- package/tabs/index.js +5 -26
- package/tabs/index.js.map +1 -0
- package/text/index.d.ts +2 -2
- package/text/index.js +4 -25
- package/text/index.js.map +1 -0
- package/text-button/index.d.ts +2 -2
- package/text-button/index.js +6 -20
- package/text-button/index.js.map +1 -0
- package/text-field/index.d.ts +2 -2
- package/text-field/index.js +26 -55
- package/text-field/index.js.map +1 -0
- package/textarea/index.js +24 -48
- package/textarea/index.js.map +1 -0
- package/timer/index.d.ts +1 -1
- package/timer/index.js +4 -25
- package/timer/index.js.map +1 -0
- package/timer/types.js +1 -0
- package/timer/types.js.map +1 -0
- package/timer/utils.js +1 -0
- package/timer/utils.js.map +1 -0
- package/toggle/index.d.ts +2 -2
- package/toggle/index.js +6 -43
- package/toggle/index.js.map +1 -0
- package/tooltip/index.d.ts +2 -2
- package/tooltip/index.js +5 -28
- package/tooltip/index.js.map +1 -0
- package/top-bar/index.js +1 -0
- package/top-bar/index.js.map +1 -0
- package/top-bar/top-bar.js +11 -58
- package/top-bar/top-bar.js.map +1 -0
- package/top-bar/types.js +1 -0
- package/top-bar/types.js.map +1 -0
- package/top-bar/utils.d.ts +2 -2
- package/top-bar/utils.js +22 -39
- package/top-bar/utils.js.map +1 -0
- package/touch-slider/index.d.ts +1 -1
- package/touch-slider/index.js +3 -4
- package/touch-slider/index.js.map +1 -0
- package/types.js +1 -0
- package/types.js.map +1 -0
- package/unknown-content/index.d.ts +1 -1
- package/unknown-content/index.js +4 -25
- package/unknown-content/index.js.map +1 -0
- package/unknown-content/utils.js +1 -0
- package/unknown-content/utils.js.map +1 -0
- package/upload-area/index.js +1 -0
- package/upload-area/index.js.map +1 -0
- package/upload-area/types.js +1 -0
- package/upload-area/types.js.map +1 -0
- package/upload-area/upload-area.js +9 -38
- package/upload-area/upload-area.js.map +1 -0
- package/upload-area/utils.js +1 -0
- package/upload-area/utils.js.map +1 -0
- package/with-hint/index.d.ts +1 -1
- package/with-hint/index.js +4 -28
- package/with-hint/index.js.map +1 -0
- package/with-hint/positioning-hint.d.ts +1 -1
- package/with-hint/positioning-hint.js +4 -25
- package/with-hint/positioning-hint.js.map +1 -0
- package/with-hint/utils.js +1 -0
- package/with-hint/utils.js.map +1 -0
- package/with-tooltip/index.d.ts +1 -1
- package/with-tooltip/index.js +7 -31
- package/with-tooltip/index.js.map +1 -0
- package/with-tooltip/positioning-tooltip.d.ts +1 -1
- package/with-tooltip/positioning-tooltip.js +5 -26
- package/with-tooltip/positioning-tooltip.js.map +1 -0
- package/with-tooltip/utils.js +1 -0
- package/with-tooltip/utils.js.map +1 -0
- package/file-icon/unknown.svg +0 -9
- package/pagination/page-button.js +0 -32
- package/rating/star.svg +0 -3
- package/readme.md +0 -183
- package/upload-area/upload.svg +0 -6
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/text/index.tsx"],"names":[],"mappings":";;;;;;;AAAA,iCAAyC;AACzC,2DAAyC;AACzC,0EAAyC;AACzC,8CAAwD;AACxD,4CAO0B;AA0C1B,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,0BAAO,CAAC,CAAC;AAEvB,QAAA,cAAc,GAAuC;IAChE,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,EAAE,EAAE,EAAE;IACN,E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button/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { AnchorHTMLAttributes, ButtonHTMLAttributes, ComponentType, ReactElement, Ref, SVGAttributes } from 'react';
|
|
2
2
|
import { LinkColor } from '../link';
|
|
3
3
|
export type TextButtonSize = 's' | 'm';
|
|
4
4
|
export type TextButtonColor = LinkColor;
|
|
@@ -38,5 +38,5 @@ export type TextButtonProps = TextButtonAsButtonProps | TextButtonAsAnchorProps;
|
|
|
38
38
|
* @param props Свойства.
|
|
39
39
|
* @return Элемент.
|
|
40
40
|
*/
|
|
41
|
-
export declare function TextButton({ size, color, children, className, startIcon: StartIcon, endIcon: EndIcon, buttonRef, anchorRef, underline, disabled, iconGutter, 'data-testid': testId, ...restProps }: TextButtonProps):
|
|
41
|
+
export declare function TextButton({ size, color, children, className, startIcon: StartIcon, endIcon: EndIcon, buttonRef, anchorRef, underline, disabled, iconGutter, 'data-testid': testId, ...restProps }: TextButtonProps): ReactElement<any, string | import("react").JSXElementConstructor<any>>;
|
|
42
42
|
export {};
|
package/text-button/index.js
CHANGED
|
@@ -1,21 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
14
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
15
4
|
};
|
|
16
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
6
|
exports.TextButton = void 0;
|
|
18
|
-
const
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
19
8
|
const bind_1 = __importDefault(require("classnames/bind"));
|
|
20
9
|
const text_button_module_scss_1 = __importDefault(require("./text-button.module.scss"));
|
|
21
10
|
const cx = bind_1.default.bind(text_button_module_scss_1.default);
|
|
@@ -24,23 +13,20 @@ const cx = bind_1.default.bind(text_button_module_scss_1.default);
|
|
|
24
13
|
* @param props Свойства.
|
|
25
14
|
* @return Элемент.
|
|
26
15
|
*/
|
|
27
|
-
function TextButton(
|
|
28
|
-
var { size = 'm', color = 'basic-blue', children, className, startIcon: StartIcon, endIcon: EndIcon, buttonRef, anchorRef, underline, disabled, iconGutter = 8, 'data-testid': testId = 'text-button' } = _a, restProps = __rest(_a, ["size", "color", "children", "className", "startIcon", "endIcon", "buttonRef", "anchorRef", "underline", "disabled", "iconGutter", 'data-testid']);
|
|
16
|
+
function TextButton({ size = 'm', color = 'basic-blue', children, className, startIcon: StartIcon, endIcon: EndIcon, buttonRef, anchorRef, underline, disabled, iconGutter = 8, 'data-testid': testId = 'text-button', ...restProps }) {
|
|
29
17
|
const rooClassName = cx('root', `color-${color}`, `size-${size}`, `icon-gutter-${iconGutter}`, underline && 'underline', disabled && 'disabled', className);
|
|
30
|
-
const content = (
|
|
31
|
-
StartIcon && react_1.default.createElement(StartIcon, { className: cx('icon-start') }),
|
|
32
|
-
children,
|
|
33
|
-
EndIcon && react_1.default.createElement(EndIcon, { className: cx('icon-end') })));
|
|
18
|
+
const content = ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [StartIcon && (0, jsx_runtime_1.jsx)(StartIcon, { className: cx('icon-start') }), children, EndIcon && (0, jsx_runtime_1.jsx)(EndIcon, { className: cx('icon-end') })] }));
|
|
34
19
|
let result;
|
|
35
20
|
switch (restProps.as) {
|
|
36
21
|
case 'anchor':
|
|
37
|
-
result = (
|
|
22
|
+
result = ((0, jsx_runtime_1.jsx)("a", { ...restProps, ref: anchorRef, className: rooClassName, "data-testid": testId, children: content }));
|
|
38
23
|
break;
|
|
39
24
|
case 'button':
|
|
40
25
|
default:
|
|
41
|
-
result = (
|
|
26
|
+
result = ((0, jsx_runtime_1.jsx)("button", { ...restProps, ref: buttonRef, className: rooClassName, disabled: disabled, "data-testid": testId, children: content }));
|
|
42
27
|
break;
|
|
43
28
|
}
|
|
44
29
|
return result;
|
|
45
30
|
}
|
|
46
31
|
exports.TextButton = TextButton;
|
|
32
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/text-button/index.tsx"],"names":[],"mappings":";;;;;;;AASA,2DAAyC;AACzC,wFAA+C;AAoD/C,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,iCAAM,CAAC,CAAC;AAEnC;;;;GAIG;AACH,SAAgB,UAAU,CAAC,EACzB,IAAI,GAAG,GAAG,EACV,KAAK,GAAG,YAAY,EACpB,QAAQ,EACR,SAAS,EACT,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,OAAO,EAChB,SAAS,EACT,SAAS,EACT,SAAS,EACT,QAAQ,EACR,UAAU,GAAG,CAAC,EACd,aAAa,EAAE,MAAM,GAAG,aAAa,EACrC,GAAG,SAAS,EACI;IAChB,MAAM,YAAY,GAAG,EAAE,CACrB,MAAM,EACN,SAAS,KAAK,EAAE,EAChB,QAAQ,IAAI,EAAE,EACd,eAAe,UAAU,EAAE,EAC3B,SAAS,IAAI,WAAW,EACxB,QAAQ,IAAI,UAAU,EACtB,SAAS,CACV,CAAC;IAEF,MAAM,OAAO,GAAG,CACd,6DACG,SAAS,IAAI,uBAAC,SAAS,IAAC,SAAS,EAAE,EAAE,CAAC,YAAY,CAAC,GAAI,EACvD,QAAQ,EACR,OAAO,IAAI,uBAAC,OAAO,IAAC,SAAS,EAAE,EAAE,CAAC,UAAU,CAAC,GAAI,IACjD,CACJ,CAAC;IAEF,IAAI,MAAoB,CAAC;IAEzB,QAAQ,SAAS,CAAC,EAAE,EAAE;QACpB,KAAK,QAAQ;YACX,MAAM,GAAG,CACP,iCAAO,SAAS,EAAE,GAAG,EAAE,SAAS,EAAE,SAAS,EAAE,YAAY,iBAAe,MAAM,YAC3E,OAAO,GACN,CACL,CAAC;YACF,MAAM;QAER,KAAK,QAAQ,CAAC;QACd;YACE,MAAM,GAAG,CACP,sCACM,SAAS,EACb,GAAG,EAAE,SAAS,EACd,SAAS,EAAE,YAAY,EACvB,QAAQ,EAAE,QAAQ,iBACL,MAAM,YAElB,OAAO,GACD,CACV,CAAC;YACF,MAAM;KACT;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AA7DD,gCA6DC"}
|
package/text-field/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { BaseInputProps } from '../base-input-deprecated';
|
|
3
3
|
import { SmallRounds } from '../styling/shapes';
|
|
4
4
|
type Variant = 'desktop' | 'mobile';
|
|
@@ -65,5 +65,5 @@ export declare const DEFAULTS: {
|
|
|
65
65
|
* @param props Свойства.
|
|
66
66
|
* @return Элемент.
|
|
67
67
|
*/
|
|
68
|
-
export declare const TextField:
|
|
68
|
+
export declare const TextField: import("react").ForwardRefExoticComponent<TextFieldProps & import("react").RefAttributes<HTMLInputElement | HTMLTextAreaElement | undefined>>;
|
|
69
69
|
export {};
|
package/text-field/index.js
CHANGED
|
@@ -1,33 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
4
|
};
|
|
28
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
6
|
exports.TextField = exports.DEFAULTS = exports.HEIGHTS = void 0;
|
|
30
|
-
const
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = require("react");
|
|
31
9
|
const lodash_1 = require("lodash");
|
|
32
10
|
const box_1 = require("../box");
|
|
33
11
|
const base_input_deprecated_1 = require("../base-input-deprecated");
|
|
@@ -74,35 +52,28 @@ exports.TextField = (0, react_1.forwardRef)(function TextField({ autoFocus, capt
|
|
|
74
52
|
});
|
|
75
53
|
(0, react_1.useImperativeHandle)(ref, () => baseInputRef.current);
|
|
76
54
|
(0, react_1.useEffect)(() => { var _a; return toggleHasValue(Boolean((_a = baseInputRef.current) === null || _a === void 0 ? void 0 : _a.value)); });
|
|
77
|
-
return (
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
onInput === null || onInput === void 0 ? void 0 : onInput(event);
|
|
101
|
-
toggleHasValue(Boolean(event.target.value));
|
|
102
|
-
}, onChange: (event) => {
|
|
103
|
-
onChange === null || onChange === void 0 ? void 0 : onChange(event);
|
|
104
|
-
toggleHasValue(Boolean(event.target.value));
|
|
105
|
-
}, onKeyDown: onKeyDown, onKeyUp: onKeyUp })))),
|
|
106
|
-
!multiline && Boolean(endAdornment) && (react_1.default.createElement(box_1.Box, { display: 'flex', alignItems: 'center', marginLeft: 4 }, endAdornment))),
|
|
107
|
-
Boolean(caption) && (react_1.default.createElement("div", { className: cx('caption', (0, sizes_1.marginTop)(isMobile ? 1 : 2), failed && 'failed'), children: caption }))));
|
|
55
|
+
return ((0, jsx_runtime_1.jsxs)("div", { "data-testid": dataTestId, className: cx('root', className, classes.root), style: style, children: [(0, jsx_runtime_1.jsxs)("div", { ...blockProps, "data-testid": 'text-field:block', className: cx('reset', 'input-block', commonModifyClasses, size && `size-${size}`, focused && classes.blockFocused, multiline && 'multiline', withLabel && 'with-label', variant === 'desktop' && rounds !== 'none' && shapes_1.SmallRounds[rounds], blockProps === null || blockProps === void 0 ? void 0 : blockProps.className), onClick: event => {
|
|
56
|
+
const input = baseInputRef.current;
|
|
57
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(event);
|
|
58
|
+
input &&
|
|
59
|
+
!disabled &&
|
|
60
|
+
!event.defaultPrevented &&
|
|
61
|
+
input !== document.activeElement &&
|
|
62
|
+
input.focus();
|
|
63
|
+
}, children: [!multiline && Boolean(startAdornment) && ((0, jsx_runtime_1.jsx)(box_1.Box, { display: 'flex', alignItems: 'center', marginRight: 4, children: startAdornment })), (0, jsx_runtime_1.jsxs)("div", { className: cx('main-column'), children: [withLabel && ((0, jsx_runtime_1.jsx)("label", { className: cx('label', commonModifyClasses, hasValue && 'filled', labelAsPlaceholder && 'as-placeholder'), htmlFor: id, children: label, "data-testid": 'text-field:label' })), (0, jsx_runtime_1.jsx)("div", { className: cx('input-wrapper'), children: (0, jsx_runtime_1.jsx)(base_input_deprecated_1.BaseInput, { ...baseInputProps, type: type, id: id, name: name, autoComplete: autoComplete, "data-testid": 'text-field:field', multiline: multiline, ref: baseInputRef, placeholder: withLabel && labelAsPlaceholder ? undefined : placeholder, restPlaceholder: withLabel && labelAsPlaceholder ? undefined : restPlaceholder, autoFocus: autoFocus, className: cx('base-input', commonModifyClasses, classes.baseInput, size && `size-${size}`), defaultValue: defaultValue, value: value, readOnly: readOnly, disabled: disabled, onFocus: (event) => {
|
|
64
|
+
onFocus && onFocus(event);
|
|
65
|
+
toggleHasValue(Boolean(event.target.value));
|
|
66
|
+
toggleFocused(true);
|
|
67
|
+
}, onBlur: (event) => {
|
|
68
|
+
onBlur && onBlur(event);
|
|
69
|
+
toggleHasValue(Boolean(event.target.value));
|
|
70
|
+
toggleFocused(false);
|
|
71
|
+
}, onInput: (event) => {
|
|
72
|
+
onInput === null || onInput === void 0 ? void 0 : onInput(event);
|
|
73
|
+
toggleHasValue(Boolean(event.target.value));
|
|
74
|
+
}, onChange: (event) => {
|
|
75
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(event);
|
|
76
|
+
toggleHasValue(Boolean(event.target.value));
|
|
77
|
+
}, onKeyDown: onKeyDown, onKeyUp: onKeyUp }) })] }), !multiline && Boolean(endAdornment) && ((0, jsx_runtime_1.jsx)(box_1.Box, { display: 'flex', alignItems: 'center', marginLeft: 4, children: endAdornment }))] }), Boolean(caption) && ((0, jsx_runtime_1.jsx)("div", { className: cx('caption', (0, sizes_1.marginTop)(isMobile ? 1 : 2), failed && 'failed'), children: caption }))] }));
|
|
108
78
|
});
|
|
79
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/text-field/index.tsx"],"names":[],"mappings":";;;;;;;AAAA,iCAAqF;AACrF,mCAA+B;AAC/B,gCAA6B;AAC7B,oEAAqE;AACrE,8CAAgD;AAChD,2DAAyC;AACzC,sFAA8C;AAC9C,4CAA6C;AAoF7C,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,gCAAM,CAAC,CAAC;AAEtB,QAAA,OAAO,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,EAAE,EAAE,EAAW,CAAC;AAE5C,QAAA,QAAQ,GAAG,EAAE,IAAI,EAAE,GAA2B,EAAW,CAAC;AAEvE;;;;GAIG;AACH,MAAM,SAAS,GAAG,CAAC,KAAW,EAAE,EAAE,CAAC,CAAC,IAAA,cAAK,EAAC,KAAK,CAAC,IAAI,GAAG,KAAK,EAAE,KAAK,EAAE,CAAC;AAEtE;;;;GAIG;AACH,MAAM,kBAAkB,GAAG,CAAC,EAC1B,QAAQ,EACR,MAAM,EACN,OAAO,EACP,OAAO,GAMR,EAAE,EAAE,CACH,EAAE,CACA,QAAQ,IAAI,UAAU,EACtB,MAAM,IAAI,QAAQ,EAClB,OAAO,IAAI,SAAS,EACpB,OAAO,IAAI,WAAW,OAAO,EAAE,CAChC,CAAC;AAEJ;;;;;GAKG;AACU,QAAA,SAAS,GAAG,IAAA,kBAAU,EAGjC,SAAS,SAAS,CAClB,EACE,SAAS,EACT,OAAO,EACP,OAAO,GAAG,EAAE,EACZ,YAAY,EACZ,QAAQ,EACR,YAAY,EACZ,MAAM,EACN,OAAO,EAAE,SAAS,EAClB,KAAK,EACL,OAAO,EACP,MAAM,EACN,QAAQ,EACR,OAAO,EACP,OAAO,EACP,SAAS,EACT,OAAO,EACP,WAAW,EACX,QAAQ,EACR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AAC,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;oCAC9C,CAAC,EACD,QAAQ,EAAE,CAAC,KAAU,EAAE,EAAE;wCACvB,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAG,KAAK,CAAC,CAAC;wCAClB,cAAc,CAAC,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;oCAC9C,CAAC,EACD,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,OAAO,GAChB,GACE,IACF,EAGL,CAAC,SAAS,IAAI,OAAO,CAAC,YAAY,CAAC,IAAI,CACtC,uBAAC,SAAG,IAAC,OAAO,EAAC,MAAM,EAAC,UAAU,EAAC,QAAQ,EAAC,UAAU,EAAE,CAAC,YAClD,YAAY,GACT,CACP,IACG,EAGL,OAAO,CAAC,OAAO,CAAC,IAAI,CACnB,gCACE,SAAS,EAAE,EAAE,CAAC,SAAS,EAAE,IAAA,iBAAS,EAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,MAAM,IAAI,QAAQ,CAAC,EACzE,QAAQ,EAAE,OAAO,GACjB,CACH,IACG,CACP,CAAC;AACJ,CAAC,CAAC,CAAC"}
|
package/textarea/index.js
CHANGED
|
@@ -1,44 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
26
|
-
var t = {};
|
|
27
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
28
|
-
t[p] = s[p];
|
|
29
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
30
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
31
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
32
|
-
t[p[i]] = s[p[i]];
|
|
33
|
-
}
|
|
34
|
-
return t;
|
|
35
|
-
};
|
|
36
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
37
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
38
4
|
};
|
|
39
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
6
|
exports.Textarea = void 0;
|
|
41
|
-
const
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = require("react");
|
|
42
9
|
const base_input_1 = require("../base-input");
|
|
43
10
|
const field_block_1 = require("../field-block");
|
|
44
11
|
const utils_1 = require("../input/utils");
|
|
@@ -50,23 +17,31 @@ const cx = bind_1.default.bind(textarea_module_scss_1.default);
|
|
|
50
17
|
* @param props Свойства.
|
|
51
18
|
* @return Элемент.
|
|
52
19
|
*/
|
|
53
|
-
function Textarea(
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
label, failed, caption, blockProps, 'data-testid': testId = 'textarea' } = _a, restProps = __rest(_a, ["textareaRef", "baseInputProps", "style", "className", "autoComplete", "autoFocus", "defaultValue", "disabled", "id", "name", "onBlur", "onChange", "onFocus", "onInput", "placeholder", "readOnly", "required", "rows", "value", "label", "failed", "caption", "blockProps", 'data-testid']);
|
|
20
|
+
function Textarea({
|
|
21
|
+
// specific Textarea props
|
|
22
|
+
textareaRef, baseInputProps,
|
|
23
|
+
// root props
|
|
24
|
+
style, className,
|
|
25
|
+
// textarea element props (popular)
|
|
26
|
+
autoComplete, autoFocus, defaultValue, disabled, id, name, onBlur, onChange, onFocus, onInput, placeholder, readOnly, required, rows = 4, value,
|
|
27
|
+
// FieldBlock props
|
|
28
|
+
label, failed, caption, blockProps, 'data-testid': testId = 'textarea', ...restProps }) {
|
|
63
29
|
const ref = (0, react_1.useRef)(null);
|
|
64
30
|
const [filled, updateFilled] = (0, utils_1.useFilledState)(ref, { value, defaultValue });
|
|
65
31
|
const [focused, setFocused] = (0, react_1.useState)(false);
|
|
66
32
|
const handleMouseDown = (0, utils_1.useFieldMouseDown)(ref, blockProps === null || blockProps === void 0 ? void 0 : blockProps.onMouseDown);
|
|
67
33
|
(0, react_1.useImperativeHandle)(textareaRef, () => ref.current);
|
|
68
|
-
return (
|
|
69
|
-
|
|
34
|
+
return ((0, jsx_runtime_1.jsx)(field_block_1.FieldBlock, { ...restProps, rootProps: {
|
|
35
|
+
...restProps.rootProps,
|
|
36
|
+
style,
|
|
37
|
+
className,
|
|
38
|
+
}, "data-testid": testId, caption: caption, disabled: disabled, failed: failed, fixedHeight: false, focused: focused, label: label, labelAsPlaceholder: !focused && !filled, labelProps: { htmlFor: id }, size: 'l', blockProps: {
|
|
39
|
+
...blockProps,
|
|
40
|
+
onMouseDown: handleMouseDown,
|
|
41
|
+
}, main: (0, jsx_runtime_1.jsx)(base_input_1.BaseInput, { ...baseInputProps, textareaRef: ref, multiline: true, className: cx('textarea', baseInputProps === null || baseInputProps === void 0 ? void 0 : baseInputProps.className), style: {
|
|
42
|
+
...baseInputProps === null || baseInputProps === void 0 ? void 0 : baseInputProps.style,
|
|
43
|
+
'--placeholder-color': (0, utils_1.definePlaceholderColor)({ failed, disabled }),
|
|
44
|
+
}, autoComplete: autoComplete, autoFocus: autoFocus, defaultValue: defaultValue, disabled: disabled, id: id, name: name, placeholder: placeholder, readOnly: readOnly, required: required, rows: rows, value: value, onFocus: (event) => {
|
|
70
45
|
onFocus === null || onFocus === void 0 ? void 0 : onFocus(event);
|
|
71
46
|
updateFilled(event);
|
|
72
47
|
setFocused(true);
|
|
@@ -80,6 +55,7 @@ function Textarea(_a) {
|
|
|
80
55
|
}, onChange: (event) => {
|
|
81
56
|
onChange === null || onChange === void 0 ? void 0 : onChange(event);
|
|
82
57
|
updateFilled(event);
|
|
83
|
-
} })
|
|
58
|
+
} }), mainProps: { className: cx('main') } }));
|
|
84
59
|
}
|
|
85
60
|
exports.Textarea = Textarea;
|
|
61
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/textarea/index.tsx"],"names":[],"mappings":";;;;;;;AAAA,iCAA2F;AAC3F,8CAAoE;AACpE,gDAA6D;AAC7D,0CAA2F;AAC3F,2DAAyC;AACzC,kFAA4C;AAmC5C,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,8BAAM,CAAC,CAAC;AAEnC;;;;GAIG;AACH,SAAgB,QAAQ,CAAC;AACvB,0BAA0B;AAC1B,WAAW,EACX,cAAc;AAEd,aAAa;AACb,KAAK,EACL,SAAS;AAET,mCAAmC;AACnC,YAAY,EACZ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AY,CAAC,KAAK,CAAC,CAAC;YACtB,CAAC,GACD,EAEJ,SAAS,EAAE,EAAE,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,GACpC,CACH,CAAC;AACJ,CAAC;AA/GD,4BA+GC"}
|
package/timer/index.d.ts
CHANGED
package/timer/index.js
CHANGED
|
@@ -1,30 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
3
|
exports.Timer = void 0;
|
|
27
|
-
const
|
|
4
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
const react_1 = require("react");
|
|
28
6
|
const utils_1 = require("./utils");
|
|
29
7
|
/**
|
|
30
8
|
* Компонент для вывода оставшегося времени до целевой временной отметки.
|
|
@@ -40,6 +18,7 @@ const Timer = ({ date, format = utils_1.formatDistance, timeout = 1000 }) => {
|
|
|
40
18
|
setDistance((0, utils_1.getDistanceToNow)(date));
|
|
41
19
|
return () => clearInterval(timerId);
|
|
42
20
|
}, [timeout]);
|
|
43
|
-
return
|
|
21
|
+
return (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: format(distance) });
|
|
44
22
|
};
|
|
45
23
|
exports.Timer = Timer;
|
|
24
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/timer/index.tsx"],"names":[],"mappings":";;;;AAAA,iCAA4C;AAE5C,mCAA2D;AAa3D;;;;GAIG;AACI,MAAM,KAAK,GAAG,CAAC,EAAE,IAAI,EAAE,MAAM,GAAG,sBAAc,EAAE,OAAO,GAAG,IAAI,EAAc,EAAE,EAAE;IACrF,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,IAAA,gBAAQ,EAAC,IAAA,wBAAgB,EAAC,IAAI,CAAC,CAAC,CAAC;IAEjE,IAAA,iBAAS,EAAC,GAAG,EAAE;QACb,MAAM,OAAO,GAAG,WAAW,CAAC,GAAG,EAAE;YAC/B,WAAW,CAAC,IAAA,wBAAgB,EAAC,IAAI,CAAC,CAAC,CAAC;QACtC,CAAC,EAAE,OAAO,CAAC,CAAC;QAEZ,WAAW,CAAC,IAAA,wBAAgB,EAAC,IAAI,CAAC,CAAC,CAAC;QAEpC,OAAO,GAAG,EAAE,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;IACtC,CAAC,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IAEd,OAAO,2DAAG,MAAM,CAAC,QAAQ,CAAC,GAAI,CAAC;AACjC,CAAC,CAAC;AAdW,QAAA,KAAK,SAchB"}
|
package/timer/types.js
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/timer/types.ts"],"names":[],"mappings":""}
|
package/timer/utils.js
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/timer/utils.ts"],"names":[],"mappings":";;;;;;AAAA,mGAA2E;AAC3E,+DAAuC;AACvC,+DAAuC;AACvC,iEAAyC;AAGzC,MAAM,KAAK,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,QAAQ,CAAU,CAAC;AAE3D;;;;GAIG;AACI,MAAM,cAAc,GAAG,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,EAAY,EAAU,EAAE,CACpF,CAAC,IAAI,EAAE,GAAG,CAAC,KAAK,GAAG,EAAE,EAAE,OAAO,GAAG,EAAE,EAAE,OAAO,GAAG,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AADrF,QAAA,cAAc,kBACuE;AAElG;;;;GAIG;AACI,MAAM,gBAAgB,GAAG,CAAC,UAAkB,EAAY,EAAE;IAC/D,MAAM,IAAI,GAAG,IAAA,kBAAQ,EAAC,UAAU,CAAC,CAAC;IAElC,IAAI,MAAM,GAAG,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;IAE3D,IAAI,IAAA,iBAAO,EAAC,IAAI,CAAC,IAAI,CAAC,IAAA,iBAAO,EAAC,IAAI,IAAI,EAAE,EAAE,IAAI,CAAC,EAAE;QAC/C,MAAM,CAAC,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,CAAC,GAAG,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CACvD,QAAQ,CACN,IAAA,mCAAyB,EAAC,IAAI,EAAE;YAC9B,IAAI;YACJ,cAAc,EAAE,OAAO;SACxB,CAAC,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CACtB,CACF,CAAC;QAEF,MAAM,GAAG,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC;KAC5C;IAED,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AAnBW,QAAA,gBAAgB,oBAmB3B"}
|
package/toggle/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { CheckboxInputProps } from '../types';
|
|
3
3
|
export type ToggleProps = CheckboxInputProps;
|
|
4
4
|
/**
|
|
5
5
|
* Компонент стилизованного переключателя (input[type=checkbox]).
|
|
6
6
|
*/
|
|
7
|
-
export declare const Toggle:
|
|
7
|
+
export declare const Toggle: import("react").ForwardRefExoticComponent<CheckboxInputProps & import("react").RefAttributes<HTMLInputElement>>;
|
package/toggle/index.js
CHANGED
|
@@ -1,56 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
26
|
-
var t = {};
|
|
27
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
28
|
-
t[p] = s[p];
|
|
29
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
30
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
31
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
32
|
-
t[p[i]] = s[p[i]];
|
|
33
|
-
}
|
|
34
|
-
return t;
|
|
35
|
-
};
|
|
36
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
37
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
38
4
|
};
|
|
39
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
6
|
exports.Toggle = void 0;
|
|
41
|
-
const
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = require("react");
|
|
42
9
|
const bind_1 = __importDefault(require("classnames/bind"));
|
|
43
10
|
const toggle_module_scss_1 = __importDefault(require("./toggle.module.scss"));
|
|
44
11
|
const cx = bind_1.default.bind(toggle_module_scss_1.default);
|
|
45
12
|
/**
|
|
46
13
|
* Компонент стилизованного переключателя (input[type=checkbox]).
|
|
47
14
|
*/
|
|
48
|
-
exports.Toggle = (0, react_1.forwardRef)((
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
restProps = __rest(_a, ["className", "style", 'data-testid']);
|
|
52
|
-
return (react_1.default.createElement("label", { className: cx('root', className), style: style },
|
|
53
|
-
react_1.default.createElement("input", Object.assign({}, restProps, { className: cx('input'), ref: ref, type: 'checkbox', "data-testid": testId })),
|
|
54
|
-
react_1.default.createElement("span", { className: cx('switch') })));
|
|
55
|
-
});
|
|
15
|
+
exports.Toggle = (0, react_1.forwardRef)(({ className, style, 'data-testid': testId = 'toggle',
|
|
16
|
+
// input props
|
|
17
|
+
...restProps }, ref) => ((0, jsx_runtime_1.jsxs)("label", { className: cx('root', className), style: style, children: [(0, jsx_runtime_1.jsx)("input", { ...restProps, className: cx('input'), ref: ref, type: 'checkbox', "data-testid": testId }), (0, jsx_runtime_1.jsx)("span", { className: cx('switch') })] })));
|
|
56
18
|
exports.Toggle.displayName = 'Toggle';
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/toggle/index.tsx"],"names":[],"mappings":";;;;;;;AAAA,iCAAmC;AAEnC,2DAAyC;AACzC,8EAA0C;AAI1C,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,4BAAM,CAAC,CAAC;AAEnC;;GAEG;AACU,QAAA,MAAM,GAAG,IAAA,kBAAU,EAC9B,CACE,EACE,SAAS,EACT,KAAK,EACL,aAAa,EAAE,MAAM,GAAG,QAAQ;AAEhC,cAAc;AACd,GAAG,SAAS,EACb,EACD,GAAG,EACH,EAAE,CAAC,CACH,mCAAO,SAAS,EAAE,EAAE,CAAC,MAAM,EAAE,SAAS,CAAC,EAAE,KAAK,EAAE,KAAK,aACnD,qCACM,SAAS,EACb,SAAS,EAAE,EAAE,CAAC,OAAO,CAAC,EACtB,GAAG,EAAE,GAAG,EACR,IAAI,EAAC,UAAU,iBACF,MAAM,GACnB,EACF,iCAAM,SAAS,EAAE,EAAE,CAAC,QAAQ,CAAC,GAAI,IAC3B,CACT,CACF,CAAC;AAEF,cAAM,CAAC,WAAW,GAAG,QAAQ,CAAC"}
|
package/tooltip/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
export interface TooltipProps {
|
|
3
3
|
/** Содержимое. */
|
|
4
4
|
children?: React.ReactNode;
|
|
@@ -15,4 +15,4 @@ export interface TooltipProps {
|
|
|
15
15
|
* @param props Свойства.
|
|
16
16
|
* @return Элемент.
|
|
17
17
|
*/
|
|
18
|
-
export declare const Tooltip:
|
|
18
|
+
export declare const Tooltip: import("react").ForwardRefExoticComponent<TooltipProps & import("react").RefAttributes<HTMLDivElement | null>>;
|
package/tooltip/index.js
CHANGED
|
@@ -1,34 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
4
|
};
|
|
28
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
6
|
exports.Tooltip = void 0;
|
|
30
|
-
const
|
|
31
|
-
const
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = require("react");
|
|
9
|
+
const Cross_1 = __importDefault(require("@sima-land/ui-quarks/icons/16x16/Stroked/Cross"));
|
|
32
10
|
const bind_1 = __importDefault(require("classnames/bind"));
|
|
33
11
|
const tooltip_module_scss_1 = __importDefault(require("./tooltip.module.scss"));
|
|
34
12
|
const cx = bind_1.default.bind(tooltip_module_scss_1.default);
|
|
@@ -38,6 +16,5 @@ const cx = bind_1.default.bind(tooltip_module_scss_1.default);
|
|
|
38
16
|
* @param props Свойства.
|
|
39
17
|
* @return Элемент.
|
|
40
18
|
*/
|
|
41
|
-
exports.Tooltip = (0, react_1.forwardRef)(({ children, onClose, style, className }, ref) => (
|
|
42
|
-
|
|
43
|
-
react_1.default.createElement("div", { className: cx('content') }, children))));
|
|
19
|
+
exports.Tooltip = (0, react_1.forwardRef)(({ children, onClose, style, className }, ref) => ((0, jsx_runtime_1.jsxs)("div", { ref: ref, style: style, className: cx('root', className), "data-testid": 'tooltip', children: [(0, jsx_runtime_1.jsx)(Cross_1.default, { className: cx('cross'), onClick: onClose, "data-testid": 'tooltip:cross' }), (0, jsx_runtime_1.jsx)("div", { className: cx('content'), children: children })] })));
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tooltip/index.tsx"],"names":[],"mappings":";;;;;;;AAAA,iCAAmC;AACnC,2FAAsE;AACtE,2DAAyC;AACzC,gFAA2C;AAgB3C,MAAM,EAAE,GAAG,cAAU,CAAC,IAAI,CAAC,6BAAM,CAAC,CAAC;AAEnC;;;;;GAKG;AACU,QAAA,OAAO,GAAG,IAAA,kBAAU,EAC/B,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,GAAG,EAAE,EAAE,CAAC,CAChD,iCAAK,GAAG,EAAE,GAAG,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,CAAC,MAAM,EAAE,SAAS,CAAC,iBAAc,SAAS,aAClF,uBAAC,eAAQ,IAAC,SAAS,EAAE,EAAE,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,OAAO,iBAAc,eAAe,GAAG,EAClF,gCAAK,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,YAAG,QAAQ,GAAO,IAC3C,CACP,CACF,CAAC"}
|
package/top-bar/index.js
CHANGED
|
@@ -6,3 +6,4 @@ Object.defineProperty(exports, "navigationButtons", { enumerable: true, get: fun
|
|
|
6
6
|
var top_bar_1 = require("./top-bar");
|
|
7
7
|
Object.defineProperty(exports, "TopBar", { enumerable: true, get: function () { return top_bar_1.TopBar; } });
|
|
8
8
|
Object.defineProperty(exports, "TOP_BAR_HEIGHT", { enumerable: true, get: function () { return top_bar_1.TOP_BAR_HEIGHT; } });
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/top-bar/index.ts"],"names":[],"mappings":";;;AACA,iCAA4C;AAAnC,0GAAA,iBAAiB,OAAA;AAC1B,qCAAmD;AAA1C,iGAAA,MAAM,OAAA;AAAE,yGAAA,cAAc,OAAA"}
|