naive-ui 2.21.4 → 2.23.1
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/es/_internal/close/src/styles/index.cssr.js +6 -5
- package/es/_internal/scrollbar/src/ScrollBar.d.ts +4 -0
- package/es/_internal/scrollbar/src/ScrollBar.js +5 -2
- package/es/_internal/selection/src/Selection.js +11 -9
- package/es/_internal/selection/src/styles/index.cssr.js +6 -2
- package/es/_utils/composable/use-houdini.js +10 -7
- package/es/alert/src/Alert.d.ts +20 -20
- package/es/alert/src/Alert.js +22 -22
- package/es/alert/src/styles/index.cssr.js +45 -45
- package/es/anchor/src/AnchorAdapter.js +12 -12
- package/es/anchor/src/styles/index.cssr.js +41 -41
- package/es/auto-complete/src/AutoComplete.d.ts +2 -2
- package/es/auto-complete/src/AutoComplete.js +2 -2
- package/es/auto-complete/src/styles/index.cssr.js +4 -4
- package/es/avatar/src/Avatar.d.ts +10 -8
- package/es/avatar/src/Avatar.js +11 -9
- package/es/avatar/src/styles/index.cssr.js +14 -16
- package/es/back-top/src/BackTop.d.ts +13 -13
- package/es/back-top/src/BackTop.js +13 -13
- package/es/back-top/src/styles/index.cssr.js +29 -29
- package/es/badge/src/Badge.d.ts +6 -6
- package/es/badge/src/Badge.js +6 -6
- package/es/badge/src/styles/index.cssr.js +15 -15
- package/es/button/src/Button.d.ts +43 -38
- package/es/button/src/Button.js +124 -116
- package/es/button/src/styles/button.cssr.js +83 -80
- package/es/button/styles/light.js +1 -1
- package/es/calendar/src/Calendar.d.ts +6 -0
- package/es/cascader/src/Cascader.d.ts +135 -0
- package/es/cascader/src/Cascader.js +2 -4
- package/es/cascader/src/CascaderMenu.d.ts +345 -0
- package/es/cascader/src/CascaderMenu.js +6 -5
- package/es/cascader/src/CascaderOption.d.ts +18 -0
- package/es/cascader/src/CascaderSelectMenu.d.ts +18 -0
- package/es/cascader/src/CascaderSubmenu.d.ts +18 -0
- package/es/cascader/styles/dark.js +3 -1
- package/es/cascader/styles/light.d.ts +13 -0
- package/es/cascader/styles/light.js +3 -1
- package/es/config-provider/src/ConfigProvider.d.ts +18 -0
- package/es/data-table/src/DataTable.js +7 -13
- package/es/data-table/src/MainTable.js +2 -3
- package/es/data-table/src/TableParts/Body.d.ts +15 -4
- package/es/data-table/src/TableParts/Body.js +80 -28
- package/es/data-table/src/TableParts/Cell.js +2 -3
- package/es/data-table/src/TableParts/Header.js +2 -2
- package/es/data-table/src/interface.d.ts +4 -1
- package/es/data-table/src/styles/index.cssr.js +4 -3
- package/es/data-table/src/use-check.js +6 -2
- package/es/data-table/src/use-scroll.d.ts +2 -0
- package/es/data-table/src/use-scroll.js +34 -4
- package/es/data-table/src/use-table-data.js +3 -1
- package/es/data-table/styles/_common.js +1 -1
- package/es/date-picker/src/DatePicker.d.ts +30 -5
- package/es/date-picker/src/DatePicker.js +32 -9
- package/es/date-picker/src/config.d.ts +1 -9
- package/es/date-picker/src/config.js +0 -8
- package/es/date-picker/src/interface.d.ts +2 -1
- package/es/date-picker/src/panel/date.d.ts +17 -10
- package/es/date-picker/src/panel/date.js +2 -2
- package/es/date-picker/src/panel/daterange.d.ts +15 -9
- package/es/date-picker/src/panel/daterange.js +2 -2
- package/es/date-picker/src/panel/datetime.d.ts +17 -16
- package/es/date-picker/src/panel/datetime.js +2 -2
- package/es/date-picker/src/panel/datetimerange.d.ts +15 -9
- package/es/date-picker/src/panel/datetimerange.js +2 -2
- package/es/date-picker/src/panel/month.d.ts +21 -20
- package/es/date-picker/src/panel/month.js +23 -12
- package/es/date-picker/src/panel/use-calendar.d.ts +17 -39
- package/es/date-picker/src/panel/use-calendar.js +41 -23
- package/es/date-picker/src/panel/use-dual-calendar.d.ts +13 -36
- package/es/date-picker/src/panel/use-dual-calendar.js +35 -21
- package/es/date-picker/src/panel/use-panel-common.d.ts +13 -32
- package/es/date-picker/src/panel/use-panel-common.js +4 -8
- package/es/date-picker/src/utils.d.ts +19 -3
- package/es/date-picker/src/utils.js +40 -5
- package/es/date-picker/styles/_common.d.ts +2 -0
- package/es/date-picker/styles/_common.js +3 -1
- package/es/date-picker/styles/light.d.ts +4 -0
- package/es/dialog/src/Dialog.d.ts +21 -21
- package/es/dialog/src/Dialog.js +23 -23
- package/es/dialog/src/styles/index.cssr.js +45 -45
- package/es/divider/src/Divider.d.ts +4 -4
- package/es/divider/src/Divider.js +4 -4
- package/es/divider/src/styles/index.cssr.js +12 -12
- package/es/dynamic-tags/src/DynamicTags.d.ts +1 -1
- package/es/dynamic-tags/src/DynamicTags.js +1 -1
- package/es/dynamic-tags/src/styles/index.cssr.js +1 -1
- package/es/form/src/Form.d.ts +27 -27
- package/es/form/src/FormItem.d.ts +27 -27
- package/es/form/src/FormItemCol.d.ts +27 -27
- package/es/form/src/FormItemGridItem.d.ts +27 -27
- package/es/form/src/FormItemRow.d.ts +27 -27
- package/es/form/styles/_common.d.ts +0 -3
- package/es/form/styles/_common.js +0 -3
- package/es/form/styles/light.d.ts +3 -3
- package/es/form/styles/light.js +2 -2
- package/es/image/src/Image.js +8 -12
- package/es/input/src/Input.js +2 -0
- package/es/input-number/src/InputNumber.js +2 -0
- package/es/input-number/src/utils.js +1 -1
- package/es/locales/common/deDE.js +6 -0
- package/es/locales/common/enUS.d.ts +6 -0
- package/es/locales/common/enUS.js +7 -1
- package/es/locales/common/frFR.d.ts +3 -0
- package/es/locales/common/frFR.js +101 -0
- package/es/locales/common/idID.d.ts +2 -94
- package/es/locales/common/idID.js +6 -0
- package/es/locales/common/jaJP.js +6 -0
- package/es/locales/common/nbNO.js +6 -0
- package/es/locales/common/ruRU.js +6 -0
- package/es/locales/common/ukUA.js +6 -0
- package/es/locales/common/zhCN.js +6 -0
- package/es/locales/common/zhTW.d.ts +3 -0
- package/es/locales/common/zhTW.js +100 -0
- package/es/locales/date/frFR.d.ts +3 -0
- package/es/locales/date/frFR.js +6 -0
- package/es/locales/date/idID.d.ts +1 -6
- package/es/locales/date/zhTW.d.ts +3 -0
- package/es/locales/date/zhTW.js +6 -0
- package/es/locales/index.d.ts +4 -0
- package/es/locales/index.js +4 -0
- package/es/log/src/Log.d.ts +6 -6
- package/es/log/src/Log.js +6 -6
- package/es/log/src/styles/index.cssr.js +16 -18
- package/es/page-header/src/PageHeader.js +3 -3
- package/es/page-header/src/styles/index.cssr.js +2 -4
- package/es/popover/src/Popover.js +4 -1
- package/es/popover/src/PopoverBody.js +3 -3
- package/es/popselect/src/Popselect.d.ts +2 -11
- package/es/popselect/src/Popselect.js +2 -2
- package/es/popselect/src/PopselectPanel.d.ts +3 -11
- package/es/popselect/src/PopselectPanel.js +17 -11
- package/es/radio/src/Radio.js +3 -3
- package/es/radio/src/RadioButton.js +4 -5
- package/es/radio/src/styles/radio-group.cssr.js +8 -4
- package/es/radio/src/styles/radio.cssr.js +8 -4
- package/es/radio/src/use-radio.d.ts +0 -3
- package/es/radio/src/use-radio.js +1 -26
- package/es/steps/src/Step.d.ts +12 -12
- package/es/steps/src/Step.js +12 -12
- package/es/steps/src/styles/index.cssr.js +46 -46
- package/es/switch/src/Switch.d.ts +19 -19
- package/es/switch/src/Switch.js +26 -19
- package/es/switch/src/styles/index.cssr.js +59 -57
- package/es/tabs/src/styles/index.cssr.js +1 -0
- package/es/tag/src/Tag.d.ts +26 -26
- package/es/tag/src/Tag.js +26 -26
- package/es/tag/src/styles/index.cssr.js +55 -55
- package/es/tag/src/styles/rtl.cssr.js +1 -1
- package/es/time-picker/src/TimePicker.d.ts +17 -17
- package/es/time-picker/src/TimePicker.js +17 -17
- package/es/time-picker/src/styles/index.cssr.js +47 -47
- package/es/timeline/src/TimelineItem.d.ts +12 -12
- package/es/timeline/src/TimelineItem.js +12 -12
- package/es/timeline/src/styles/index.cssr.js +44 -44
- package/es/transfer/src/styles/index.cssr.js +9 -4
- package/es/tree/src/Tree.d.ts +11 -11
- package/es/tree/src/Tree.js +11 -11
- package/es/tree/src/dnd.js +2 -2
- package/es/tree/src/styles/index.cssr.js +33 -33
- package/es/tree-select/src/TreeSelect.d.ts +43 -6
- package/es/tree-select/src/TreeSelect.js +29 -14
- package/es/tree-select/src/styles/index.cssr.js +20 -11
- package/es/tree-select/styles/light.d.ts +6 -0
- package/es/tree-select/styles/light.js +5 -2
- package/es/typography/src/a.d.ts +2 -2
- package/es/typography/src/a.js +2 -2
- package/es/typography/src/blockquote.d.ts +5 -5
- package/es/typography/src/blockquote.js +5 -5
- package/es/typography/src/create-header.d.ts +8 -8
- package/es/typography/src/create-header.js +8 -8
- package/es/typography/src/headers.d.ts +48 -48
- package/es/typography/src/hr.d.ts +2 -1
- package/es/typography/src/hr.js +3 -1
- package/es/typography/src/ol.d.ts +7 -7
- package/es/typography/src/ol.js +7 -7
- package/es/typography/src/p.d.ts +5 -5
- package/es/typography/src/p.js +5 -5
- package/es/typography/src/styles/a.cssr.js +6 -6
- package/es/typography/src/styles/blockquote.cssr.js +11 -11
- package/es/typography/src/styles/header.cssr.js +19 -19
- package/es/typography/src/styles/hr.cssr.js +3 -3
- package/es/typography/src/styles/list.cssr.js +15 -15
- package/es/typography/src/styles/p.cssr.js +10 -10
- package/es/typography/src/styles/text.cssr.js +18 -18
- package/es/typography/src/text.d.ts +8 -7
- package/es/typography/src/text.js +9 -8
- package/es/typography/src/ul.d.ts +7 -7
- package/es/typography/src/ul.js +7 -7
- package/es/upload/src/Upload.js +16 -16
- package/es/upload/src/styles/index.cssr.js +36 -36
- package/es/version.d.ts +1 -1
- package/es/version.js +1 -1
- package/lib/_internal/close/src/styles/index.cssr.js +6 -5
- package/lib/_internal/scrollbar/src/ScrollBar.d.ts +4 -0
- package/lib/_internal/scrollbar/src/ScrollBar.js +5 -2
- package/lib/_internal/selection/src/Selection.js +11 -9
- package/lib/_internal/selection/src/styles/index.cssr.js +6 -2
- package/lib/_utils/composable/use-houdini.js +10 -7
- package/lib/alert/src/Alert.d.ts +20 -20
- package/lib/alert/src/Alert.js +22 -22
- package/lib/alert/src/styles/index.cssr.js +45 -45
- package/lib/anchor/src/AnchorAdapter.js +12 -12
- package/lib/anchor/src/styles/index.cssr.js +41 -41
- package/lib/auto-complete/src/AutoComplete.d.ts +2 -2
- package/lib/auto-complete/src/AutoComplete.js +2 -2
- package/lib/auto-complete/src/styles/index.cssr.js +4 -4
- package/lib/avatar/src/Avatar.d.ts +10 -8
- package/lib/avatar/src/Avatar.js +11 -9
- package/lib/avatar/src/styles/index.cssr.js +14 -16
- package/lib/back-top/src/BackTop.d.ts +13 -13
- package/lib/back-top/src/BackTop.js +13 -13
- package/lib/back-top/src/styles/index.cssr.js +29 -29
- package/lib/badge/src/Badge.d.ts +6 -6
- package/lib/badge/src/Badge.js +6 -6
- package/lib/badge/src/styles/index.cssr.js +15 -15
- package/lib/button/src/Button.d.ts +43 -38
- package/lib/button/src/Button.js +123 -115
- package/lib/button/src/styles/button.cssr.js +83 -80
- package/lib/button/styles/light.js +1 -1
- package/lib/calendar/src/Calendar.d.ts +6 -0
- package/lib/cascader/src/Cascader.d.ts +135 -0
- package/lib/cascader/src/Cascader.js +2 -4
- package/lib/cascader/src/CascaderMenu.d.ts +345 -0
- package/lib/cascader/src/CascaderMenu.js +6 -5
- package/lib/cascader/src/CascaderOption.d.ts +18 -0
- package/lib/cascader/src/CascaderSelectMenu.d.ts +18 -0
- package/lib/cascader/src/CascaderSubmenu.d.ts +18 -0
- package/lib/cascader/styles/dark.js +3 -1
- package/lib/cascader/styles/light.d.ts +13 -0
- package/lib/cascader/styles/light.js +3 -1
- package/lib/config-provider/src/ConfigProvider.d.ts +18 -0
- package/lib/data-table/src/DataTable.js +6 -12
- package/lib/data-table/src/MainTable.js +1 -2
- package/lib/data-table/src/TableParts/Body.d.ts +15 -4
- package/lib/data-table/src/TableParts/Body.js +78 -26
- package/lib/data-table/src/TableParts/Cell.js +2 -3
- package/lib/data-table/src/TableParts/Header.js +2 -2
- package/lib/data-table/src/interface.d.ts +4 -1
- package/lib/data-table/src/styles/index.cssr.js +4 -3
- package/lib/data-table/src/use-check.js +6 -2
- package/lib/data-table/src/use-scroll.d.ts +2 -0
- package/lib/data-table/src/use-scroll.js +34 -4
- package/lib/data-table/src/use-table-data.js +3 -1
- package/lib/data-table/styles/_common.js +1 -1
- package/lib/date-picker/src/DatePicker.d.ts +30 -5
- package/lib/date-picker/src/DatePicker.js +31 -8
- package/lib/date-picker/src/config.d.ts +1 -9
- package/lib/date-picker/src/config.js +1 -9
- package/lib/date-picker/src/interface.d.ts +2 -1
- package/lib/date-picker/src/panel/date.d.ts +17 -10
- package/lib/date-picker/src/panel/date.js +1 -1
- package/lib/date-picker/src/panel/daterange.d.ts +15 -9
- package/lib/date-picker/src/panel/daterange.js +1 -1
- package/lib/date-picker/src/panel/datetime.d.ts +17 -16
- package/lib/date-picker/src/panel/datetime.js +1 -1
- package/lib/date-picker/src/panel/datetimerange.d.ts +15 -9
- package/lib/date-picker/src/panel/datetimerange.js +2 -2
- package/lib/date-picker/src/panel/month.d.ts +21 -20
- package/lib/date-picker/src/panel/month.js +23 -12
- package/lib/date-picker/src/panel/use-calendar.d.ts +17 -39
- package/lib/date-picker/src/panel/use-calendar.js +40 -21
- package/lib/date-picker/src/panel/use-dual-calendar.d.ts +13 -36
- package/lib/date-picker/src/panel/use-dual-calendar.js +34 -19
- package/lib/date-picker/src/panel/use-panel-common.d.ts +13 -32
- package/lib/date-picker/src/panel/use-panel-common.js +5 -8
- package/lib/date-picker/src/utils.d.ts +19 -3
- package/lib/date-picker/src/utils.js +41 -4
- package/lib/date-picker/styles/_common.d.ts +2 -0
- package/lib/date-picker/styles/_common.js +3 -1
- package/lib/date-picker/styles/light.d.ts +4 -0
- package/lib/dialog/src/Dialog.d.ts +21 -21
- package/lib/dialog/src/Dialog.js +23 -23
- package/lib/dialog/src/styles/index.cssr.js +45 -45
- package/lib/divider/src/Divider.d.ts +4 -4
- package/lib/divider/src/Divider.js +4 -4
- package/lib/divider/src/styles/index.cssr.js +12 -12
- package/lib/dynamic-tags/src/DynamicTags.d.ts +1 -1
- package/lib/dynamic-tags/src/DynamicTags.js +1 -1
- package/lib/dynamic-tags/src/styles/index.cssr.js +1 -1
- package/lib/form/src/Form.d.ts +27 -27
- package/lib/form/src/FormItem.d.ts +27 -27
- package/lib/form/src/FormItemCol.d.ts +27 -27
- package/lib/form/src/FormItemGridItem.d.ts +27 -27
- package/lib/form/src/FormItemRow.d.ts +27 -27
- package/lib/form/styles/_common.d.ts +0 -3
- package/lib/form/styles/_common.js +0 -3
- package/lib/form/styles/light.d.ts +3 -3
- package/lib/form/styles/light.js +2 -2
- package/lib/image/src/Image.js +7 -11
- package/lib/input/src/Input.js +2 -0
- package/lib/input-number/src/InputNumber.js +2 -0
- package/lib/input-number/src/utils.js +1 -1
- package/lib/locales/common/deDE.js +6 -0
- package/lib/locales/common/enUS.d.ts +6 -0
- package/lib/locales/common/enUS.js +7 -1
- package/lib/locales/common/frFR.d.ts +3 -0
- package/lib/locales/common/frFR.js +103 -0
- package/lib/locales/common/idID.d.ts +2 -94
- package/lib/locales/common/idID.js +6 -0
- package/lib/locales/common/jaJP.js +6 -0
- package/lib/locales/common/nbNO.js +6 -0
- package/lib/locales/common/ruRU.js +6 -0
- package/lib/locales/common/ukUA.js +6 -0
- package/lib/locales/common/zhCN.js +6 -0
- package/lib/locales/common/zhTW.d.ts +3 -0
- package/lib/locales/common/zhTW.js +102 -0
- package/lib/locales/date/frFR.d.ts +3 -0
- package/lib/locales/date/frFR.js +11 -0
- package/lib/locales/date/idID.d.ts +1 -6
- package/lib/locales/date/zhTW.d.ts +3 -0
- package/lib/locales/date/zhTW.js +11 -0
- package/lib/locales/index.d.ts +4 -0
- package/lib/locales/index.js +9 -1
- package/lib/log/src/Log.d.ts +6 -6
- package/lib/log/src/Log.js +6 -6
- package/lib/log/src/styles/index.cssr.js +16 -18
- package/lib/page-header/src/PageHeader.js +3 -3
- package/lib/page-header/src/styles/index.cssr.js +2 -4
- package/lib/popover/src/Popover.js +4 -1
- package/lib/popover/src/PopoverBody.js +3 -3
- package/lib/popselect/src/Popselect.d.ts +2 -11
- package/lib/popselect/src/Popselect.js +2 -2
- package/lib/popselect/src/PopselectPanel.d.ts +3 -11
- package/lib/popselect/src/PopselectPanel.js +16 -10
- package/lib/radio/src/Radio.js +3 -3
- package/lib/radio/src/RadioButton.js +4 -5
- package/lib/radio/src/styles/radio-group.cssr.js +8 -4
- package/lib/radio/src/styles/radio.cssr.js +8 -4
- package/lib/radio/src/use-radio.d.ts +0 -3
- package/lib/radio/src/use-radio.js +1 -26
- package/lib/steps/src/Step.d.ts +12 -12
- package/lib/steps/src/Step.js +12 -12
- package/lib/steps/src/styles/index.cssr.js +46 -46
- package/lib/switch/src/Switch.d.ts +19 -19
- package/lib/switch/src/Switch.js +26 -19
- package/lib/switch/src/styles/index.cssr.js +59 -57
- package/lib/tabs/src/styles/index.cssr.js +1 -0
- package/lib/tag/src/Tag.d.ts +26 -26
- package/lib/tag/src/Tag.js +26 -26
- package/lib/tag/src/styles/index.cssr.js +55 -55
- package/lib/tag/src/styles/rtl.cssr.js +1 -1
- package/lib/time-picker/src/TimePicker.d.ts +17 -17
- package/lib/time-picker/src/TimePicker.js +17 -17
- package/lib/time-picker/src/styles/index.cssr.js +47 -47
- package/lib/timeline/src/TimelineItem.d.ts +12 -12
- package/lib/timeline/src/TimelineItem.js +12 -12
- package/lib/timeline/src/styles/index.cssr.js +44 -44
- package/lib/transfer/src/styles/index.cssr.js +9 -4
- package/lib/tree/src/Tree.d.ts +11 -11
- package/lib/tree/src/Tree.js +11 -11
- package/lib/tree/src/dnd.js +2 -2
- package/lib/tree/src/styles/index.cssr.js +33 -33
- package/lib/tree-select/src/TreeSelect.d.ts +43 -6
- package/lib/tree-select/src/TreeSelect.js +28 -13
- package/lib/tree-select/src/styles/index.cssr.js +20 -11
- package/lib/tree-select/styles/light.d.ts +6 -0
- package/lib/tree-select/styles/light.js +5 -2
- package/lib/typography/src/a.d.ts +2 -2
- package/lib/typography/src/a.js +2 -2
- package/lib/typography/src/blockquote.d.ts +5 -5
- package/lib/typography/src/blockquote.js +5 -5
- package/lib/typography/src/create-header.d.ts +8 -8
- package/lib/typography/src/create-header.js +8 -8
- package/lib/typography/src/headers.d.ts +48 -48
- package/lib/typography/src/hr.d.ts +2 -1
- package/lib/typography/src/hr.js +3 -1
- package/lib/typography/src/ol.d.ts +7 -7
- package/lib/typography/src/ol.js +7 -7
- package/lib/typography/src/p.d.ts +5 -5
- package/lib/typography/src/p.js +5 -5
- package/lib/typography/src/styles/a.cssr.js +6 -6
- package/lib/typography/src/styles/blockquote.cssr.js +11 -11
- package/lib/typography/src/styles/header.cssr.js +19 -19
- package/lib/typography/src/styles/hr.cssr.js +3 -3
- package/lib/typography/src/styles/list.cssr.js +15 -15
- package/lib/typography/src/styles/p.cssr.js +10 -10
- package/lib/typography/src/styles/text.cssr.js +18 -18
- package/lib/typography/src/text.d.ts +8 -7
- package/lib/typography/src/text.js +9 -8
- package/lib/typography/src/ul.d.ts +7 -7
- package/lib/typography/src/ul.js +7 -7
- package/lib/upload/src/Upload.js +16 -16
- package/lib/upload/src/styles/index.cssr.js +36 -36
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +29 -28
- package/web-types.json +25 -7
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { cB, cM, c } from '../../../../_utils/cssr'; // vars
|
|
1
|
+
import { cB, cM, c } from '../../../../_utils/cssr'; // Note: non-prefixed color should be removed after css vars prefix migration
|
|
2
|
+
// vars:
|
|
2
3
|
// --close-color
|
|
3
4
|
// --close-color-hover
|
|
4
5
|
// --close-color-pressed
|
|
@@ -6,12 +7,12 @@ import { cB, cM, c } from '../../../../_utils/cssr'; // vars:
|
|
|
6
7
|
|
|
7
8
|
export default cB('base-close', `
|
|
8
9
|
cursor: pointer;
|
|
9
|
-
color: var(--close-color);
|
|
10
|
+
color: var(--close-color, var(--n-close-color));
|
|
10
11
|
`, [c('&:hover', {
|
|
11
|
-
color: 'var(--close-color-hover)'
|
|
12
|
+
color: 'var(--close-color-hover, var(--n-close-color))'
|
|
12
13
|
}), c('&:active', {
|
|
13
|
-
color: 'var(--close-color-pressed)'
|
|
14
|
+
color: 'var(--close-color-pressed, var(--n-close-color-pressed))'
|
|
14
15
|
}), cM('disabled', {
|
|
15
16
|
cursor: 'not-allowed!important',
|
|
16
|
-
color: 'var(--close-color-disabled)'
|
|
17
|
+
color: 'var(--close-color-disabled, var(--n-close-color-disabled))'
|
|
17
18
|
})]);
|
|
@@ -51,6 +51,7 @@ declare const scrollbarProps: {
|
|
|
51
51
|
};
|
|
52
52
|
readonly container: PropType<() => HTMLElement | null | undefined>;
|
|
53
53
|
readonly content: PropType<() => HTMLElement | null | undefined>;
|
|
54
|
+
readonly containerClass: StringConstructor;
|
|
54
55
|
readonly containerStyle: PropType<string | CSSProperties>;
|
|
55
56
|
readonly contentClass: StringConstructor;
|
|
56
57
|
readonly contentStyle: PropType<string | CSSProperties>;
|
|
@@ -94,6 +95,7 @@ declare const Scrollbar: import("vue").DefineComponent<{
|
|
|
94
95
|
};
|
|
95
96
|
readonly container: PropType<() => HTMLElement | null | undefined>;
|
|
96
97
|
readonly content: PropType<() => HTMLElement | null | undefined>;
|
|
98
|
+
readonly containerClass: StringConstructor;
|
|
97
99
|
readonly containerStyle: PropType<string | CSSProperties>;
|
|
98
100
|
readonly contentClass: StringConstructor;
|
|
99
101
|
readonly contentStyle: PropType<string | CSSProperties>;
|
|
@@ -156,6 +158,7 @@ declare const Scrollbar: import("vue").DefineComponent<{
|
|
|
156
158
|
readonly xScrollable?: unknown;
|
|
157
159
|
readonly container?: unknown;
|
|
158
160
|
readonly content?: unknown;
|
|
161
|
+
readonly containerClass?: unknown;
|
|
159
162
|
readonly containerStyle?: unknown;
|
|
160
163
|
readonly contentClass?: unknown;
|
|
161
164
|
readonly contentStyle?: unknown;
|
|
@@ -189,6 +192,7 @@ declare const Scrollbar: import("vue").DefineComponent<{
|
|
|
189
192
|
color: string;
|
|
190
193
|
colorHover: string;
|
|
191
194
|
}, any>> | undefined;
|
|
195
|
+
containerClass?: string | undefined;
|
|
192
196
|
onResize?: ((e: ResizeObserverEntry) => void) | undefined;
|
|
193
197
|
container?: (() => HTMLElement | null | undefined) | undefined;
|
|
194
198
|
containerStyle?: string | CSSProperties | undefined;
|
|
@@ -19,7 +19,7 @@ const scrollbarProps = Object.assign(Object.assign({}, useTheme.props), { size:
|
|
|
19
19
|
default: false
|
|
20
20
|
},
|
|
21
21
|
// If container is set, resize observer won't not attached
|
|
22
|
-
container: Function, content: Function, containerStyle: [String, Object], contentClass: String, contentStyle: [String, Object], horizontalRailStyle: [String, Object], verticalRailStyle: [String, Object], onScroll: Function, onWheel: Function, onResize: Function, internalOnUpdateScrollLeft: Function });
|
|
22
|
+
container: Function, content: Function, containerClass: String, containerStyle: [String, Object], contentClass: String, contentStyle: [String, Object], horizontalRailStyle: [String, Object], verticalRailStyle: [String, Object], onScroll: Function, onWheel: Function, onResize: Function, internalOnUpdateScrollLeft: Function });
|
|
23
23
|
const Scrollbar = defineComponent({
|
|
24
24
|
name: 'Scrollbar',
|
|
25
25
|
props: scrollbarProps,
|
|
@@ -480,7 +480,10 @@ const Scrollbar = defineComponent({
|
|
|
480
480
|
onMouseenter: this.handleMouseEnterWrapper,
|
|
481
481
|
onMouseleave: this.handleMouseLeaveWrapper
|
|
482
482
|
}), [
|
|
483
|
-
this.container ? (renderSlot($slots, 'default')) : (h("div", { ref: "containerRef", class:
|
|
483
|
+
this.container ? (renderSlot($slots, 'default')) : (h("div", { ref: "containerRef", class: [
|
|
484
|
+
`${mergedClsPrefix}-scrollbar-container`,
|
|
485
|
+
this.containerClass
|
|
486
|
+
], style: this.containerStyle, onScroll: this.handleScroll, onWheel: this.onWheel },
|
|
484
487
|
h(VResizeObserver, { onResize: this.handleContentResize }, {
|
|
485
488
|
default: () => (h("div", { ref: "contentRef", style: [
|
|
486
489
|
{
|
|
@@ -491,15 +491,17 @@ export default defineComponent({
|
|
|
491
491
|
body = (h("div", { ref: "patternInputWrapperRef", class: `${clsPrefix}-base-selection-label` },
|
|
492
492
|
h("input", Object.assign({}, this.inputProps, { ref: "patternInputRef", class: `${clsPrefix}-base-selection-input`, value: this.patternInputFocused && this.active ? this.pattern : '', placeholder: "", readonly: disabled, disabled: disabled, tabindex: -1, autofocus: this.autofocus, onFocus: this.handlePatternInputFocus, onBlur: this.handlePatternInputBlur, onInput: this.handlePatternInputInput, onCompositionstart: this.handleCompositionStart, onCompositionend: this.handleCompositionEnd })),
|
|
493
493
|
showPlaceholder ? null : this.patternInputFocused &&
|
|
494
|
-
this.active ? null : (h("div", { class: `${clsPrefix}-base-selection-label__render-label ${clsPrefix}-base-selection-overlay`, key: "input" },
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
494
|
+
this.active ? null : (h("div", { class: `${clsPrefix}-base-selection-label__render-label ${clsPrefix}-base-selection-overlay`, key: "input" },
|
|
495
|
+
h("div", { class: `${clsPrefix}-base-selection-overlay__wrapper` }, renderTag
|
|
496
|
+
? renderTag({
|
|
497
|
+
option: this.selectedOption,
|
|
498
|
+
handleClose: () => { }
|
|
499
|
+
})
|
|
500
|
+
: renderLabel
|
|
501
|
+
? renderLabel(this.selectedOption, true)
|
|
502
|
+
: render(this.label, this.selectedOption, true)))),
|
|
503
|
+
showPlaceholder ? (h("div", { class: `${clsPrefix}-base-selection-placeholder ${clsPrefix}-base-selection-overlay`, key: "placeholder" },
|
|
504
|
+
h("div", { class: `${clsPrefix}-base-selection-overlay__wrapper` }, this.filterablePlaceholder))) : null,
|
|
503
505
|
suffix));
|
|
504
506
|
}
|
|
505
507
|
else {
|
|
@@ -70,7 +70,6 @@ export default c([cB('base-selection', `
|
|
|
70
70
|
display: flex;
|
|
71
71
|
align-items: center;
|
|
72
72
|
white-space: nowrap;
|
|
73
|
-
overflow: hidden;
|
|
74
73
|
pointer-events: none;
|
|
75
74
|
position: absolute;
|
|
76
75
|
top: 0;
|
|
@@ -79,7 +78,12 @@ export default c([cB('base-selection', `
|
|
|
79
78
|
left: 0;
|
|
80
79
|
padding: var(--padding-single);
|
|
81
80
|
transition: color .3s var(--bezier);
|
|
82
|
-
|
|
81
|
+
`, [cE('wrapper', `
|
|
82
|
+
flex-basis: 0;
|
|
83
|
+
flex-grow: 1;
|
|
84
|
+
overflow: hidden;
|
|
85
|
+
text-overflow: ellipsis;
|
|
86
|
+
`)]), cB('base-selection-placeholder', `
|
|
83
87
|
color: var(--placeholder-color);
|
|
84
88
|
`), cB('base-selection-tags', `
|
|
85
89
|
cursor: pointer;
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import { onBeforeMount } from 'vue';
|
|
2
1
|
let houdiniRegistered = false;
|
|
3
2
|
export function useHoudini() {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
if (typeof window === 'undefined')
|
|
4
|
+
return;
|
|
5
|
+
if (!window.CSS)
|
|
6
|
+
return;
|
|
7
|
+
if (!houdiniRegistered) {
|
|
8
|
+
houdiniRegistered = true;
|
|
9
|
+
if ('registerProperty' in (window === null || window === void 0 ? void 0 : window.CSS)) {
|
|
10
|
+
try {
|
|
9
11
|
;
|
|
10
12
|
CSS.registerProperty({
|
|
11
13
|
name: '--color-start',
|
|
@@ -20,6 +22,7 @@ export function useHoudini() {
|
|
|
20
22
|
initialValue: '#0000'
|
|
21
23
|
});
|
|
22
24
|
}
|
|
25
|
+
catch (e) { }
|
|
23
26
|
}
|
|
24
|
-
}
|
|
27
|
+
}
|
|
25
28
|
}
|
package/es/alert/src/Alert.d.ts
CHANGED
|
@@ -528,26 +528,26 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
528
528
|
};
|
|
529
529
|
}>;
|
|
530
530
|
cssVars: import("vue").ComputedRef<{
|
|
531
|
-
'--bezier': string;
|
|
532
|
-
'--color': string;
|
|
533
|
-
'--close-color': string;
|
|
534
|
-
'--close-color-hover': string;
|
|
535
|
-
'--close-color-pressed': string;
|
|
536
|
-
'--icon-color': string;
|
|
537
|
-
'--border': string;
|
|
538
|
-
'--title-text-color': string;
|
|
539
|
-
'--content-text-color': string;
|
|
540
|
-
'--line-height': string;
|
|
541
|
-
'--border-radius': string;
|
|
542
|
-
'--font-size': string;
|
|
543
|
-
'--title-font-weight': string;
|
|
544
|
-
'--icon-size': string;
|
|
545
|
-
'--icon-margin': string;
|
|
546
|
-
'--close-size': string;
|
|
547
|
-
'--close-margin': string;
|
|
548
|
-
'--padding': string;
|
|
549
|
-
'--icon-margin-left': string;
|
|
550
|
-
'--icon-margin-right': string;
|
|
531
|
+
'--n-bezier': string;
|
|
532
|
+
'--n-color': string;
|
|
533
|
+
'--n-close-color': string;
|
|
534
|
+
'--n-close-color-hover': string;
|
|
535
|
+
'--n-close-color-pressed': string;
|
|
536
|
+
'--n-icon-color': string;
|
|
537
|
+
'--n-border': string;
|
|
538
|
+
'--n-title-text-color': string;
|
|
539
|
+
'--n-content-text-color': string;
|
|
540
|
+
'--n-line-height': string;
|
|
541
|
+
'--n-border-radius': string;
|
|
542
|
+
'--n-font-size': string;
|
|
543
|
+
'--n-title-font-weight': string;
|
|
544
|
+
'--n-icon-size': string;
|
|
545
|
+
'--n-icon-margin': string;
|
|
546
|
+
'--n-close-size': string;
|
|
547
|
+
'--n-close-margin': string;
|
|
548
|
+
'--n-padding': string;
|
|
549
|
+
'--n-icon-margin-left': string;
|
|
550
|
+
'--n-icon-margin-right': string;
|
|
551
551
|
}>;
|
|
552
552
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
|
|
553
553
|
title?: unknown;
|
package/es/alert/src/Alert.js
CHANGED
|
@@ -44,26 +44,26 @@ export default defineComponent({
|
|
|
44
44
|
const { type } = props;
|
|
45
45
|
const { left, right } = getMargin(iconMargin);
|
|
46
46
|
return {
|
|
47
|
-
'--bezier': cubicBezierEaseInOut,
|
|
48
|
-
'--color': self[createKey('color', type)],
|
|
49
|
-
'--close-color': self[createKey('closeColor', type)],
|
|
50
|
-
'--close-color-hover': self[createKey('closeColorHover', type)],
|
|
51
|
-
'--close-color-pressed': self[createKey('closeColorPressed', type)],
|
|
52
|
-
'--icon-color': self[createKey('iconColor', type)],
|
|
53
|
-
'--border': self[createKey('border', type)],
|
|
54
|
-
'--title-text-color': self[createKey('titleTextColor', type)],
|
|
55
|
-
'--content-text-color': self[createKey('contentTextColor', type)],
|
|
56
|
-
'--line-height': lineHeight,
|
|
57
|
-
'--border-radius': borderRadius,
|
|
58
|
-
'--font-size': fontSize,
|
|
59
|
-
'--title-font-weight': titleFontWeight,
|
|
60
|
-
'--icon-size': iconSize,
|
|
61
|
-
'--icon-margin': iconMargin,
|
|
62
|
-
'--close-size': closeSize,
|
|
63
|
-
'--close-margin': closeMargin,
|
|
64
|
-
'--padding': padding,
|
|
65
|
-
'--icon-margin-left': left,
|
|
66
|
-
'--icon-margin-right': right
|
|
47
|
+
'--n-bezier': cubicBezierEaseInOut,
|
|
48
|
+
'--n-color': self[createKey('color', type)],
|
|
49
|
+
'--n-close-color': self[createKey('closeColor', type)],
|
|
50
|
+
'--n-close-color-hover': self[createKey('closeColorHover', type)],
|
|
51
|
+
'--n-close-color-pressed': self[createKey('closeColorPressed', type)],
|
|
52
|
+
'--n-icon-color': self[createKey('iconColor', type)],
|
|
53
|
+
'--n-border': self[createKey('border', type)],
|
|
54
|
+
'--n-title-text-color': self[createKey('titleTextColor', type)],
|
|
55
|
+
'--n-content-text-color': self[createKey('contentTextColor', type)],
|
|
56
|
+
'--n-line-height': lineHeight,
|
|
57
|
+
'--n-border-radius': borderRadius,
|
|
58
|
+
'--n-font-size': fontSize,
|
|
59
|
+
'--n-title-font-weight': titleFontWeight,
|
|
60
|
+
'--n-icon-size': iconSize,
|
|
61
|
+
'--n-icon-margin': iconMargin,
|
|
62
|
+
'--n-close-size': closeSize,
|
|
63
|
+
'--n-close-margin': closeMargin,
|
|
64
|
+
'--n-padding': padding,
|
|
65
|
+
'--n-icon-margin-left': left,
|
|
66
|
+
'--n-icon-margin-right': right
|
|
67
67
|
};
|
|
68
68
|
});
|
|
69
69
|
const visibleRef = ref(true);
|
|
@@ -126,9 +126,9 @@ export default defineComponent({
|
|
|
126
126
|
}
|
|
127
127
|
})))),
|
|
128
128
|
h("div", { class: `${mergedClsPrefix}-alert-body` },
|
|
129
|
-
this.title
|
|
129
|
+
this.title || $slots.header ? (h("div", { class: `${mergedClsPrefix}-alert-body__title` }, renderSlot($slots, 'header', undefined, () => [
|
|
130
130
|
this.title
|
|
131
|
-
]))),
|
|
131
|
+
]))) : null,
|
|
132
132
|
$slots.default && (h("div", { class: `${mergedClsPrefix}-alert-body__content` }, $slots))))) : null;
|
|
133
133
|
}
|
|
134
134
|
}));
|
|
@@ -1,44 +1,44 @@
|
|
|
1
1
|
import { c, cB, cE, cM } from '../../../_utils/cssr';
|
|
2
2
|
import fadeInHeightExpandTranstion from '../../../_styles/transitions/fade-in-height-expand.cssr'; // vars:
|
|
3
|
-
// --bezier
|
|
4
|
-
// --color
|
|
5
|
-
// --close-color
|
|
6
|
-
// --close-color-hover
|
|
7
|
-
// --close-color-pressed
|
|
8
|
-
// --icon-color
|
|
9
|
-
// --border
|
|
10
|
-
// --title-text-color
|
|
11
|
-
// --content-text-color
|
|
12
|
-
// --line-height
|
|
13
|
-
// --border-radius
|
|
14
|
-
// --font-size
|
|
15
|
-
// --title-font-weight
|
|
16
|
-
// --icon-size
|
|
17
|
-
// --icon-margin
|
|
18
|
-
// --close-size
|
|
19
|
-
// --close-margin
|
|
20
|
-
// --padding
|
|
21
|
-
// --icon-margin-left
|
|
22
|
-
// --icon-margin-right
|
|
3
|
+
// --n-bezier
|
|
4
|
+
// --n-color
|
|
5
|
+
// --n-close-color
|
|
6
|
+
// --n-close-color-hover
|
|
7
|
+
// --n-close-color-pressed
|
|
8
|
+
// --n-icon-color
|
|
9
|
+
// --n-border
|
|
10
|
+
// --n-title-text-color
|
|
11
|
+
// --n-content-text-color
|
|
12
|
+
// --n-line-height
|
|
13
|
+
// --n-border-radius
|
|
14
|
+
// --n-font-size
|
|
15
|
+
// --n-title-font-weight
|
|
16
|
+
// --n-icon-size
|
|
17
|
+
// --n-icon-margin
|
|
18
|
+
// --n-close-size
|
|
19
|
+
// --n-close-margin
|
|
20
|
+
// --n-padding
|
|
21
|
+
// --n-icon-margin-left
|
|
22
|
+
// --n-icon-margin-right
|
|
23
23
|
|
|
24
24
|
export default cB('alert', `
|
|
25
|
-
line-height: var(--line-height);
|
|
26
|
-
border-radius: var(--border-radius);
|
|
25
|
+
line-height: var(--n-line-height);
|
|
26
|
+
border-radius: var(--n-border-radius);
|
|
27
27
|
position: relative;
|
|
28
|
-
transition: background-color .3s var(--bezier);
|
|
29
|
-
background-color: var(--color);
|
|
28
|
+
transition: background-color .3s var(--n-bezier);
|
|
29
|
+
background-color: var(--n-color);
|
|
30
30
|
text-align: start;
|
|
31
31
|
`, [cE('icon', {
|
|
32
|
-
color: 'var(--icon-color)'
|
|
32
|
+
color: 'var(--n-icon-color)'
|
|
33
33
|
}), cB('alert-body', {
|
|
34
|
-
border: 'var(--border)',
|
|
35
|
-
padding: 'var(--padding)'
|
|
34
|
+
border: 'var(--n-border)',
|
|
35
|
+
padding: 'var(--n-padding)'
|
|
36
36
|
}, [cE('title', {
|
|
37
|
-
color: 'var(--title-text-color)'
|
|
37
|
+
color: 'var(--n-title-text-color)'
|
|
38
38
|
}), cE('content', {
|
|
39
|
-
color: 'var(--content-text-color)'
|
|
39
|
+
color: 'var(--n-content-text-color)'
|
|
40
40
|
})]), fadeInHeightExpandTranstion({
|
|
41
|
-
originalTransition: 'transform .3s var(--bezier)',
|
|
41
|
+
originalTransition: 'transform .3s var(--n-bezier)',
|
|
42
42
|
enterToProps: {
|
|
43
43
|
transform: 'scale(1)'
|
|
44
44
|
},
|
|
@@ -52,32 +52,32 @@ export default cB('alert', `
|
|
|
52
52
|
align-items: center;
|
|
53
53
|
justify-content: center;
|
|
54
54
|
display: flex;
|
|
55
|
-
width: var(--icon-size);
|
|
56
|
-
height: var(--icon-size);
|
|
57
|
-
font-size: var(--icon-size);
|
|
58
|
-
margin: var(--icon-margin);
|
|
55
|
+
width: var(--n-icon-size);
|
|
56
|
+
height: var(--n-icon-size);
|
|
57
|
+
font-size: var(--n-icon-size);
|
|
58
|
+
margin: var(--n-icon-margin);
|
|
59
59
|
`), cE('close', `
|
|
60
|
-
transition: color .3s var(--bezier);
|
|
60
|
+
transition: color .3s var(--n-bezier);
|
|
61
61
|
position: absolute;
|
|
62
62
|
right: 0;
|
|
63
63
|
top: 0;
|
|
64
|
-
margin: var(--close-margin);
|
|
65
|
-
font-size: var(--close-size);
|
|
64
|
+
margin: var(--n-close-margin);
|
|
65
|
+
font-size: var(--n-close-size);
|
|
66
66
|
`), cM('show-icon', [cB('alert-body', {
|
|
67
|
-
paddingLeft: 'calc(var(--icon-margin-left) + var(--icon-size) + var(--icon-margin-right))'
|
|
67
|
+
paddingLeft: 'calc(var(--n-icon-margin-left) + var(--n-icon-size) + var(--n-icon-margin-right))'
|
|
68
68
|
})]), cB('alert-body', `
|
|
69
|
-
border-radius: var(--border-radius);
|
|
70
|
-
transition: border-color .3s var(--bezier);
|
|
69
|
+
border-radius: var(--n-border-radius);
|
|
70
|
+
transition: border-color .3s var(--n-bezier);
|
|
71
71
|
`, [cE('title', `
|
|
72
|
-
transition: color .3s var(--bezier);
|
|
72
|
+
transition: color .3s var(--n-bezier);
|
|
73
73
|
font-size: 16px;
|
|
74
74
|
line-height: 19px;
|
|
75
|
-
font-weight: var(--title-font-weight);
|
|
75
|
+
font-weight: var(--n-title-font-weight);
|
|
76
76
|
`, [c('& +', [cE('content', {
|
|
77
77
|
marginTop: '9px'
|
|
78
78
|
})])]), cE('content', {
|
|
79
|
-
transition: 'color .3s var(--bezier)',
|
|
80
|
-
fontSize: 'var(--font-size)'
|
|
79
|
+
transition: 'color .3s var(--n-bezier)',
|
|
80
|
+
fontSize: 'var(--n-font-size)'
|
|
81
81
|
})]), cE('icon', {
|
|
82
|
-
transition: 'color .3s var(--bezier)'
|
|
82
|
+
transition: 'color .3s var(--n-bezier)'
|
|
83
83
|
})]);
|
|
@@ -17,18 +17,18 @@ export default defineComponent({
|
|
|
17
17
|
const cssVarsRef = computed(() => {
|
|
18
18
|
const { self: { railColor, linkColor, railColorActive, linkTextColor, linkTextColorHover, linkTextColorPressed, linkTextColorActive, linkFontSize, railWidth, linkPadding, borderRadius }, common: { cubicBezierEaseInOut } } = themeRef.value;
|
|
19
19
|
return {
|
|
20
|
-
'--link-border-radius': borderRadius,
|
|
21
|
-
'--link-color': linkColor,
|
|
22
|
-
'--link-font-size': linkFontSize,
|
|
23
|
-
'--link-text-color': linkTextColor,
|
|
24
|
-
'--link-text-color-hover': linkTextColorHover,
|
|
25
|
-
'--link-text-color-active': linkTextColorActive,
|
|
26
|
-
'--link-text-color-pressed': linkTextColorPressed,
|
|
27
|
-
'--link-padding': linkPadding,
|
|
28
|
-
'--bezier': cubicBezierEaseInOut,
|
|
29
|
-
'--rail-color': railColor,
|
|
30
|
-
'--rail-color-active': railColorActive,
|
|
31
|
-
'--rail-width': railWidth
|
|
20
|
+
'--n-link-border-radius': borderRadius,
|
|
21
|
+
'--n-link-color': linkColor,
|
|
22
|
+
'--n-link-font-size': linkFontSize,
|
|
23
|
+
'--n-link-text-color': linkTextColor,
|
|
24
|
+
'--n-link-text-color-hover': linkTextColorHover,
|
|
25
|
+
'--n-link-text-color-active': linkTextColorActive,
|
|
26
|
+
'--n-link-text-color-pressed': linkTextColorPressed,
|
|
27
|
+
'--n-link-padding': linkPadding,
|
|
28
|
+
'--n-bezier': cubicBezierEaseInOut,
|
|
29
|
+
'--n-rail-color': railColor,
|
|
30
|
+
'--n-rail-color-active': railColorActive,
|
|
31
|
+
'--n-rail-width': railWidth
|
|
32
32
|
};
|
|
33
33
|
});
|
|
34
34
|
return {
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { c, cE, cB, cM, cNotM } from '../../../_utils/cssr'; // vars:
|
|
2
|
-
// --link-color
|
|
3
|
-
// --link-font-size
|
|
4
|
-
// --link-text-color
|
|
5
|
-
// --link-text-color-hover
|
|
6
|
-
// --link-text-color-active
|
|
7
|
-
// --link-text-color-pressed
|
|
8
|
-
// --bezier
|
|
9
|
-
// --rail-color
|
|
10
|
-
// --rail-color-active
|
|
11
|
-
// --rail-width
|
|
12
|
-
// --link-padding
|
|
13
|
-
// --link-border-radius
|
|
2
|
+
// --n-link-color
|
|
3
|
+
// --n-link-font-size
|
|
4
|
+
// --n-link-text-color
|
|
5
|
+
// --n-link-text-color-hover
|
|
6
|
+
// --n-link-text-color-active
|
|
7
|
+
// --n-link-text-color-pressed
|
|
8
|
+
// --n-bezier
|
|
9
|
+
// --n-rail-color
|
|
10
|
+
// --n-rail-color-active
|
|
11
|
+
// --n-rail-width
|
|
12
|
+
// --n-link-padding
|
|
13
|
+
// --n-link-border-radius
|
|
14
14
|
|
|
15
15
|
export default cB('anchor', `
|
|
16
16
|
position: relative;
|
|
17
17
|
`, [cNotM('block', `
|
|
18
|
-
padding-left: var(--rail-width);
|
|
18
|
+
padding-left: var(--n-rail-width);
|
|
19
19
|
`, [cB('anchor-link', [c('+, >', [cB('anchor-link', `
|
|
20
20
|
margin-top: .5em;
|
|
21
21
|
`)])]), cB('anchor-link-background', `
|
|
@@ -25,56 +25,52 @@ export default cB('anchor', `
|
|
|
25
25
|
`), cNotM('show-rail', [c('>', [cB('anchor-link', 'padding-left: 0;')])])]), cM('block', [cB('anchor-link', `
|
|
26
26
|
margin-bottom: 4px;
|
|
27
27
|
padding: 2px 8px;
|
|
28
|
-
transition: background-color .3s var(--bezier);
|
|
28
|
+
transition: background-color .3s var(--n-bezier);
|
|
29
29
|
background-color: transparent;
|
|
30
|
-
border-radius: var(--link-border-radius);
|
|
30
|
+
border-radius: var(--n-link-border-radius);
|
|
31
31
|
`, [cM('active', `
|
|
32
|
-
background-color: var(--link-color);
|
|
32
|
+
background-color: var(--n-link-color);
|
|
33
33
|
`)])]), cB('anchor-link-background', `
|
|
34
34
|
position: absolute;
|
|
35
|
-
left: calc(var(--rail-width) / 2);
|
|
35
|
+
left: calc(var(--n-rail-width) / 2);
|
|
36
36
|
width: 100%;
|
|
37
|
-
background-color: var(--link-color);
|
|
37
|
+
background-color: var(--n-link-color);
|
|
38
38
|
transition:
|
|
39
|
-
top .15s var(--bezier),
|
|
40
|
-
max-width .15s var(--bezier),
|
|
41
|
-
background-color .3s var(--bezier);
|
|
39
|
+
top .15s var(--n-bezier),
|
|
40
|
+
max-width .15s var(--n-bezier),
|
|
41
|
+
background-color .3s var(--n-bezier);
|
|
42
42
|
`), cB('anchor-rail', `
|
|
43
43
|
position: absolute;
|
|
44
44
|
left: 0;
|
|
45
45
|
top: 0;
|
|
46
46
|
bottom: 0;
|
|
47
|
-
width: var(--rail-width);
|
|
48
|
-
border-radius: calc(var(--rail-width) / 2);
|
|
47
|
+
width: var(--n-rail-width);
|
|
48
|
+
border-radius: calc(var(--n-rail-width) / 2);
|
|
49
49
|
overflow: hidden;
|
|
50
|
-
transition: background-color .3s var(--bezier);
|
|
51
|
-
background-color: var(--rail-color);
|
|
50
|
+
transition: background-color .3s var(--n-bezier);
|
|
51
|
+
background-color: var(--n-rail-color);
|
|
52
52
|
`, [cE('bar', `
|
|
53
53
|
position: absolute;
|
|
54
54
|
left: 0;
|
|
55
|
-
width: var(--rail-width);
|
|
55
|
+
width: var(--n-rail-width);
|
|
56
56
|
height: 21px;
|
|
57
57
|
background-color: #0000;
|
|
58
58
|
transition:
|
|
59
|
-
top .15s var(--bezier),
|
|
60
|
-
background-color .3s var(--bezier);
|
|
59
|
+
top .15s var(--n-bezier),
|
|
60
|
+
background-color .3s var(--n-bezier);
|
|
61
61
|
`, [cM('active', {
|
|
62
|
-
backgroundColor: 'var(--rail-color-active)'
|
|
62
|
+
backgroundColor: 'var(--n-rail-color-active)'
|
|
63
63
|
})])]), cB('anchor-link', `
|
|
64
|
-
padding: var(--link-padding);
|
|
64
|
+
padding: var(--n-link-padding);
|
|
65
65
|
position: relative;
|
|
66
66
|
line-height: 1.5;
|
|
67
|
-
font-size: var(--link-font-size);
|
|
67
|
+
font-size: var(--n-link-font-size);
|
|
68
68
|
min-height: 1.5em;
|
|
69
69
|
display: flex;
|
|
70
70
|
flex-direction: column;
|
|
71
|
-
`, [cM('active', [cE('title', `
|
|
72
|
-
color: var(--link-text-color-active);
|
|
73
|
-
`)]),
|
|
74
|
-
color: var(--link-text-color-hover);
|
|
75
|
-
`)]), c('&:active', [cE('title', `
|
|
76
|
-
color: var(--link-text-color-pressed);
|
|
77
|
-
`)]), cE('title', `
|
|
71
|
+
`, [cM('active', [c('>', [cE('title', `
|
|
72
|
+
color: var(--n-link-text-color-active);
|
|
73
|
+
`)])]), cE('title', `
|
|
78
74
|
outline: none;
|
|
79
75
|
max-width: 100%;
|
|
80
76
|
text-decoration: none;
|
|
@@ -84,6 +80,10 @@ export default cB('anchor', `
|
|
|
84
80
|
cursor: pointer;
|
|
85
81
|
display: inline-block;
|
|
86
82
|
padding-right: 16px;
|
|
87
|
-
transition: color .3s var(--bezier);
|
|
88
|
-
color: var(--link-text-color);
|
|
89
|
-
`
|
|
83
|
+
transition: color .3s var(--n-bezier);
|
|
84
|
+
color: var(--n-link-text-color);
|
|
85
|
+
`, [c('&:hover, &:focus', `
|
|
86
|
+
color: var(--n-link-text-color-hover);
|
|
87
|
+
`), c('&:active', `
|
|
88
|
+
color: var(--n-link-text-color-pressed);
|
|
89
|
+
`)])])]);
|
|
@@ -1072,8 +1072,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1072
1072
|
};
|
|
1073
1073
|
}>;
|
|
1074
1074
|
cssVars: import("vue").ComputedRef<{
|
|
1075
|
-
'--menu-box-shadow': string;
|
|
1076
|
-
'--bezier': string;
|
|
1075
|
+
'--n-menu-box-shadow': string;
|
|
1076
|
+
'--n-bezier': string;
|
|
1077
1077
|
}>;
|
|
1078
1078
|
mergedBordered: import("vue").ComputedRef<boolean>;
|
|
1079
1079
|
namespace: import("vue").ComputedRef<string | undefined>;
|
|
@@ -206,8 +206,8 @@ export default defineComponent({
|
|
|
206
206
|
cssVars: computed(() => {
|
|
207
207
|
const { common: { cubicBezierEaseInOut }, self: { menuBoxShadow } } = themeRef.value;
|
|
208
208
|
return {
|
|
209
|
-
'--menu-box-shadow': menuBoxShadow,
|
|
210
|
-
'--bezier': cubicBezierEaseInOut
|
|
209
|
+
'--n-menu-box-shadow': menuBoxShadow,
|
|
210
|
+
'--n-bezier': cubicBezierEaseInOut
|
|
211
211
|
};
|
|
212
212
|
}),
|
|
213
213
|
mergedBordered: mergedBorderedRef,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { c, cB } from '../../../_utils/cssr';
|
|
2
2
|
import fadeInScaleUpTransition from '../../../_styles/transitions/fade-in-scale-up.cssr'; // vars:
|
|
3
|
-
// --bezier
|
|
4
|
-
// --menu-box-shadow
|
|
3
|
+
// --n-bezier
|
|
4
|
+
// --n-menu-box-shadow
|
|
5
5
|
|
|
6
6
|
export default c([cB('auto-complete', `
|
|
7
7
|
z-index: auto;
|
|
@@ -10,7 +10,7 @@ export default c([cB('auto-complete', `
|
|
|
10
10
|
width: 100%;
|
|
11
11
|
`), cB('auto-complete-menu', `
|
|
12
12
|
margin: 4px 0;
|
|
13
|
-
box-shadow: var(--menu-box-shadow);
|
|
13
|
+
box-shadow: var(--n-menu-box-shadow);
|
|
14
14
|
`, [fadeInScaleUpTransition({
|
|
15
|
-
originalTransition: 'background-color .3s var(--bezier)'
|
|
15
|
+
originalTransition: 'background-color .3s var(--n-bezier)'
|
|
16
16
|
})])]);
|