naive-ui 2.21.5 → 2.22.0
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 +15 -0
- package/es/_internal/scrollbar/src/ScrollBar.js +13 -7
- package/es/_internal/selection/src/Selection.js +11 -9
- package/es/_internal/selection/src/styles/index.cssr.js +6 -2
- 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/avatar/src/Avatar.d.ts +5 -3
- package/es/avatar/src/Avatar.js +7 -5
- package/es/avatar/src/styles/index.cssr.js +3 -5
- package/es/button/src/Button.d.ts +33 -33
- package/es/button/src/Button.js +103 -102
- 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 +2 -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 +6 -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/Header.js +1 -1
- 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 +25 -1
- package/es/date-picker/src/DatePicker.js +16 -7
- package/es/date-picker/src/config.d.ts +1 -1
- package/es/date-picker/src/interface.d.ts +2 -1
- package/es/date-picker/src/panel/date.d.ts +9 -1
- package/es/date-picker/src/panel/date.js +2 -2
- package/es/date-picker/src/panel/daterange.d.ts +7 -0
- package/es/date-picker/src/panel/daterange.js +2 -2
- package/es/date-picker/src/panel/datetime.d.ts +9 -7
- package/es/date-picker/src/panel/datetime.js +2 -2
- package/es/date-picker/src/panel/datetimerange.d.ts +7 -0
- package/es/date-picker/src/panel/datetimerange.js +2 -2
- package/es/date-picker/src/panel/month.d.ts +13 -11
- package/es/date-picker/src/panel/month.js +23 -12
- package/es/date-picker/src/panel/use-calendar.d.ts +11 -34
- package/es/date-picker/src/panel/use-calendar.js +35 -18
- package/es/date-picker/src/panel/use-dual-calendar.d.ts +7 -31
- package/es/date-picker/src/panel/use-dual-calendar.js +23 -8
- package/es/date-picker/src/panel/use-panel-common.d.ts +7 -27
- package/es/date-picker/src/panel/use-panel-common.js +2 -2
- 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/image/src/Image.js +8 -12
- package/es/locales/common/deDE.js +2 -0
- package/es/locales/common/enUS.d.ts +2 -0
- package/es/locales/common/enUS.js +2 -0
- package/es/locales/common/frFR.js +3 -0
- package/es/locales/common/idID.js +2 -0
- package/es/locales/common/jaJP.js +2 -0
- package/es/locales/common/nbNO.js +2 -0
- package/es/locales/common/ruRU.js +2 -0
- package/es/locales/common/ukUA.js +2 -0
- package/es/locales/common/zhCN.js +2 -0
- package/es/locales/common/zhTW.d.ts +3 -0
- package/es/locales/common/zhTW.js +100 -0
- package/es/locales/date/zhTW.d.ts +3 -0
- package/es/locales/date/zhTW.js +6 -0
- package/es/locales/index.d.ts +2 -0
- package/es/locales/index.js +2 -0
- 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/tabs/src/styles/index.cssr.js +1 -0
- package/es/tag/src/styles/index.cssr.js +1 -1
- package/es/tree-select/src/TreeSelect.d.ts +38 -1
- package/es/tree-select/src/TreeSelect.js +25 -10
- package/es/tree-select/src/styles/index.cssr.js +11 -2
- package/es/tree-select/styles/light.d.ts +6 -0
- package/es/tree-select/styles/light.js +5 -2
- 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 +15 -0
- package/lib/_internal/scrollbar/src/ScrollBar.js +13 -7
- package/lib/_internal/selection/src/Selection.js +11 -9
- package/lib/_internal/selection/src/styles/index.cssr.js +6 -2
- 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/avatar/src/Avatar.d.ts +5 -3
- package/lib/avatar/src/Avatar.js +7 -5
- package/lib/avatar/src/styles/index.cssr.js +3 -5
- package/lib/button/src/Button.d.ts +33 -33
- package/lib/button/src/Button.js +103 -102
- 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 +2 -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 +6 -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/Header.js +1 -1
- 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 +25 -1
- package/lib/date-picker/src/DatePicker.js +16 -7
- package/lib/date-picker/src/config.d.ts +1 -1
- package/lib/date-picker/src/interface.d.ts +2 -1
- package/lib/date-picker/src/panel/date.d.ts +9 -1
- package/lib/date-picker/src/panel/date.js +1 -1
- package/lib/date-picker/src/panel/daterange.d.ts +7 -0
- package/lib/date-picker/src/panel/daterange.js +1 -1
- package/lib/date-picker/src/panel/datetime.d.ts +9 -7
- package/lib/date-picker/src/panel/datetime.js +1 -1
- package/lib/date-picker/src/panel/datetimerange.d.ts +7 -0
- package/lib/date-picker/src/panel/datetimerange.js +2 -2
- package/lib/date-picker/src/panel/month.d.ts +13 -11
- package/lib/date-picker/src/panel/month.js +23 -12
- package/lib/date-picker/src/panel/use-calendar.d.ts +11 -34
- package/lib/date-picker/src/panel/use-calendar.js +34 -16
- package/lib/date-picker/src/panel/use-dual-calendar.d.ts +7 -31
- package/lib/date-picker/src/panel/use-dual-calendar.js +22 -6
- package/lib/date-picker/src/panel/use-panel-common.d.ts +7 -27
- package/lib/date-picker/src/panel/use-panel-common.js +3 -2
- 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/image/src/Image.js +7 -11
- package/lib/locales/common/deDE.js +2 -0
- package/lib/locales/common/enUS.d.ts +2 -0
- package/lib/locales/common/enUS.js +2 -0
- package/lib/locales/common/frFR.js +3 -0
- package/lib/locales/common/idID.js +2 -0
- package/lib/locales/common/jaJP.js +2 -0
- package/lib/locales/common/nbNO.js +2 -0
- package/lib/locales/common/ruRU.js +2 -0
- package/lib/locales/common/ukUA.js +2 -0
- package/lib/locales/common/zhCN.js +2 -0
- package/lib/locales/common/zhTW.d.ts +3 -0
- package/lib/locales/common/zhTW.js +102 -0
- package/lib/locales/date/zhTW.d.ts +3 -0
- package/lib/locales/date/zhTW.js +11 -0
- package/lib/locales/index.d.ts +2 -0
- package/lib/locales/index.js +5 -1
- 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/tabs/src/styles/index.cssr.js +1 -0
- package/lib/tag/src/styles/index.cssr.js +1 -1
- package/lib/tree-select/src/TreeSelect.d.ts +38 -1
- package/lib/tree-select/src/TreeSelect.js +24 -9
- package/lib/tree-select/src/styles/index.cssr.js +11 -2
- package/lib/tree-select/styles/light.d.ts +6 -0
- package/lib/tree-select/styles/light.js +5 -2
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +4 -3
- package/web-types.json +25 -7
|
@@ -2,7 +2,7 @@ import { PropType, ExtractPropTypes, Ref } from 'vue';
|
|
|
2
2
|
import { FollowerPlacement } from 'vueuc';
|
|
3
3
|
import type { MaybeArray, ExtractPublicPropTypes } from '../../_utils';
|
|
4
4
|
import { DatePickerType } from './config';
|
|
5
|
-
import type { OnUpdateValue, Value, IsDateDisabled, IsTimeDisabled, Shortcuts, FirstDayOfWeek } from './interface';
|
|
5
|
+
import type { OnUpdateValue, Value, IsDateDisabled, IsTimeDisabled, Shortcuts, FirstDayOfWeek, DefaultTime } from './interface';
|
|
6
6
|
declare const datePickerProps: {
|
|
7
7
|
readonly to: {
|
|
8
8
|
type: PropType<string | boolean | HTMLElement>;
|
|
@@ -18,6 +18,7 @@ declare const datePickerProps: {
|
|
|
18
18
|
readonly type: PropType<Value | null>;
|
|
19
19
|
readonly default: null;
|
|
20
20
|
};
|
|
21
|
+
readonly defaultTime: PropType<DefaultTime>;
|
|
21
22
|
readonly disabled: {
|
|
22
23
|
readonly type: PropType<boolean | undefined>;
|
|
23
24
|
readonly default: undefined;
|
|
@@ -109,12 +110,14 @@ declare const datePickerProps: {
|
|
|
109
110
|
calendarLeftPaddingDatetimerange: string;
|
|
110
111
|
calendarLeftPaddingMonth: string;
|
|
111
112
|
calendarLeftPaddingYear: string;
|
|
113
|
+
calendarLeftPaddingQuarter: string;
|
|
112
114
|
calendarRightPaddingDate: string;
|
|
113
115
|
calendarRightPaddingDatetime: string;
|
|
114
116
|
calendarRightPaddingDaterange: string;
|
|
115
117
|
calendarRightPaddingDatetimerange: string;
|
|
116
118
|
calendarRightPaddingMonth: string;
|
|
117
119
|
calendarRightPaddingYear: string;
|
|
120
|
+
calendarRightPaddingQuarter: string;
|
|
118
121
|
}, {
|
|
119
122
|
Input: import("../../_mixins").Theme<"Input", {
|
|
120
123
|
countTextColor: string;
|
|
@@ -718,12 +721,14 @@ declare const datePickerProps: {
|
|
|
718
721
|
calendarLeftPaddingDatetimerange: string;
|
|
719
722
|
calendarLeftPaddingMonth: string;
|
|
720
723
|
calendarLeftPaddingYear: string;
|
|
724
|
+
calendarLeftPaddingQuarter: string;
|
|
721
725
|
calendarRightPaddingDate: string;
|
|
722
726
|
calendarRightPaddingDatetime: string;
|
|
723
727
|
calendarRightPaddingDaterange: string;
|
|
724
728
|
calendarRightPaddingDatetimerange: string;
|
|
725
729
|
calendarRightPaddingMonth: string;
|
|
726
730
|
calendarRightPaddingYear: string;
|
|
731
|
+
calendarRightPaddingQuarter: string;
|
|
727
732
|
}, {
|
|
728
733
|
Input: import("../../_mixins").Theme<"Input", {
|
|
729
734
|
countTextColor: string;
|
|
@@ -1327,12 +1332,14 @@ declare const datePickerProps: {
|
|
|
1327
1332
|
calendarLeftPaddingDatetimerange: string;
|
|
1328
1333
|
calendarLeftPaddingMonth: string;
|
|
1329
1334
|
calendarLeftPaddingYear: string;
|
|
1335
|
+
calendarLeftPaddingQuarter: string;
|
|
1330
1336
|
calendarRightPaddingDate: string;
|
|
1331
1337
|
calendarRightPaddingDatetime: string;
|
|
1332
1338
|
calendarRightPaddingDaterange: string;
|
|
1333
1339
|
calendarRightPaddingDatetimerange: string;
|
|
1334
1340
|
calendarRightPaddingMonth: string;
|
|
1335
1341
|
calendarRightPaddingYear: string;
|
|
1342
|
+
calendarRightPaddingQuarter: string;
|
|
1336
1343
|
}, {
|
|
1337
1344
|
Input: import("../../_mixins").Theme<"Input", {
|
|
1338
1345
|
countTextColor: string;
|
|
@@ -1907,6 +1914,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1907
1914
|
readonly type: PropType<Value | null>;
|
|
1908
1915
|
readonly default: null;
|
|
1909
1916
|
};
|
|
1917
|
+
readonly defaultTime: PropType<DefaultTime>;
|
|
1910
1918
|
readonly disabled: {
|
|
1911
1919
|
readonly type: PropType<boolean | undefined>;
|
|
1912
1920
|
readonly default: undefined;
|
|
@@ -1998,12 +2006,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1998
2006
|
calendarLeftPaddingDatetimerange: string;
|
|
1999
2007
|
calendarLeftPaddingMonth: string;
|
|
2000
2008
|
calendarLeftPaddingYear: string;
|
|
2009
|
+
calendarLeftPaddingQuarter: string;
|
|
2001
2010
|
calendarRightPaddingDate: string;
|
|
2002
2011
|
calendarRightPaddingDatetime: string;
|
|
2003
2012
|
calendarRightPaddingDaterange: string;
|
|
2004
2013
|
calendarRightPaddingDatetimerange: string;
|
|
2005
2014
|
calendarRightPaddingMonth: string;
|
|
2006
2015
|
calendarRightPaddingYear: string;
|
|
2016
|
+
calendarRightPaddingQuarter: string;
|
|
2007
2017
|
}, {
|
|
2008
2018
|
Input: import("../../_mixins").Theme<"Input", {
|
|
2009
2019
|
countTextColor: string;
|
|
@@ -2607,12 +2617,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
2607
2617
|
calendarLeftPaddingDatetimerange: string;
|
|
2608
2618
|
calendarLeftPaddingMonth: string;
|
|
2609
2619
|
calendarLeftPaddingYear: string;
|
|
2620
|
+
calendarLeftPaddingQuarter: string;
|
|
2610
2621
|
calendarRightPaddingDate: string;
|
|
2611
2622
|
calendarRightPaddingDatetime: string;
|
|
2612
2623
|
calendarRightPaddingDaterange: string;
|
|
2613
2624
|
calendarRightPaddingDatetimerange: string;
|
|
2614
2625
|
calendarRightPaddingMonth: string;
|
|
2615
2626
|
calendarRightPaddingYear: string;
|
|
2627
|
+
calendarRightPaddingQuarter: string;
|
|
2616
2628
|
}, {
|
|
2617
2629
|
Input: import("../../_mixins").Theme<"Input", {
|
|
2618
2630
|
countTextColor: string;
|
|
@@ -3216,12 +3228,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
3216
3228
|
calendarLeftPaddingDatetimerange: string;
|
|
3217
3229
|
calendarLeftPaddingMonth: string;
|
|
3218
3230
|
calendarLeftPaddingYear: string;
|
|
3231
|
+
calendarLeftPaddingQuarter: string;
|
|
3219
3232
|
calendarRightPaddingDate: string;
|
|
3220
3233
|
calendarRightPaddingDatetime: string;
|
|
3221
3234
|
calendarRightPaddingDaterange: string;
|
|
3222
3235
|
calendarRightPaddingDatetimerange: string;
|
|
3223
3236
|
calendarRightPaddingMonth: string;
|
|
3224
3237
|
calendarRightPaddingYear: string;
|
|
3238
|
+
calendarRightPaddingQuarter: string;
|
|
3225
3239
|
}, {
|
|
3226
3240
|
Input: import("../../_mixins").Theme<"Input", {
|
|
3227
3241
|
countTextColor: string;
|
|
@@ -3991,12 +4005,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
3991
4005
|
calendarLeftPaddingDatetimerange: string;
|
|
3992
4006
|
calendarLeftPaddingMonth: string;
|
|
3993
4007
|
calendarLeftPaddingYear: string;
|
|
4008
|
+
calendarLeftPaddingQuarter: string;
|
|
3994
4009
|
calendarRightPaddingDate: string;
|
|
3995
4010
|
calendarRightPaddingDatetime: string;
|
|
3996
4011
|
calendarRightPaddingDaterange: string;
|
|
3997
4012
|
calendarRightPaddingDatetimerange: string;
|
|
3998
4013
|
calendarRightPaddingMonth: string;
|
|
3999
4014
|
calendarRightPaddingYear: string;
|
|
4015
|
+
calendarRightPaddingQuarter: string;
|
|
4000
4016
|
};
|
|
4001
4017
|
peers: {
|
|
4002
4018
|
Input: import("../../_mixins").Theme<"Input", {
|
|
@@ -4900,6 +4916,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
4900
4916
|
readonly clearable?: unknown;
|
|
4901
4917
|
readonly updateValueOnClose?: unknown;
|
|
4902
4918
|
readonly defaultValue?: unknown;
|
|
4919
|
+
readonly defaultTime?: unknown;
|
|
4903
4920
|
readonly disabled?: unknown;
|
|
4904
4921
|
readonly placement?: unknown;
|
|
4905
4922
|
readonly value?: unknown;
|
|
@@ -4998,12 +5015,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
4998
5015
|
calendarLeftPaddingDatetimerange: string;
|
|
4999
5016
|
calendarLeftPaddingMonth: string;
|
|
5000
5017
|
calendarLeftPaddingYear: string;
|
|
5018
|
+
calendarLeftPaddingQuarter: string;
|
|
5001
5019
|
calendarRightPaddingDate: string;
|
|
5002
5020
|
calendarRightPaddingDatetime: string;
|
|
5003
5021
|
calendarRightPaddingDaterange: string;
|
|
5004
5022
|
calendarRightPaddingDatetimerange: string;
|
|
5005
5023
|
calendarRightPaddingMonth: string;
|
|
5006
5024
|
calendarRightPaddingYear: string;
|
|
5025
|
+
calendarRightPaddingQuarter: string;
|
|
5007
5026
|
}, {
|
|
5008
5027
|
Input: import("../../_mixins").Theme<"Input", {
|
|
5009
5028
|
countTextColor: string;
|
|
@@ -5607,12 +5626,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
5607
5626
|
calendarLeftPaddingDatetimerange: string;
|
|
5608
5627
|
calendarLeftPaddingMonth: string;
|
|
5609
5628
|
calendarLeftPaddingYear: string;
|
|
5629
|
+
calendarLeftPaddingQuarter: string;
|
|
5610
5630
|
calendarRightPaddingDate: string;
|
|
5611
5631
|
calendarRightPaddingDatetime: string;
|
|
5612
5632
|
calendarRightPaddingDaterange: string;
|
|
5613
5633
|
calendarRightPaddingDatetimerange: string;
|
|
5614
5634
|
calendarRightPaddingMonth: string;
|
|
5615
5635
|
calendarRightPaddingYear: string;
|
|
5636
|
+
calendarRightPaddingQuarter: string;
|
|
5616
5637
|
}, {
|
|
5617
5638
|
Input: import("../../_mixins").Theme<"Input", {
|
|
5618
5639
|
countTextColor: string;
|
|
@@ -6216,12 +6237,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
6216
6237
|
calendarLeftPaddingDatetimerange: string;
|
|
6217
6238
|
calendarLeftPaddingMonth: string;
|
|
6218
6239
|
calendarLeftPaddingYear: string;
|
|
6240
|
+
calendarLeftPaddingQuarter: string;
|
|
6219
6241
|
calendarRightPaddingDate: string;
|
|
6220
6242
|
calendarRightPaddingDatetime: string;
|
|
6221
6243
|
calendarRightPaddingDaterange: string;
|
|
6222
6244
|
calendarRightPaddingDatetimerange: string;
|
|
6223
6245
|
calendarRightPaddingMonth: string;
|
|
6224
6246
|
calendarRightPaddingYear: string;
|
|
6247
|
+
calendarRightPaddingQuarter: string;
|
|
6225
6248
|
}, {
|
|
6226
6249
|
Input: import("../../_mixins").Theme<"Input", {
|
|
6227
6250
|
countTextColor: string;
|
|
@@ -6787,6 +6810,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
6787
6810
|
onUpdateValue?: MaybeArray<OnUpdateValue> | undefined;
|
|
6788
6811
|
isDateDisabled?: IsDateDisabled | undefined;
|
|
6789
6812
|
actions?: ("clear" | "confirm" | "now")[] | undefined;
|
|
6813
|
+
defaultTime?: DefaultTime | undefined;
|
|
6790
6814
|
startPlaceholder?: string | undefined;
|
|
6791
6815
|
endPlaceholder?: string | undefined;
|
|
6792
6816
|
timeFormat?: string | undefined;
|
|
@@ -26,7 +26,7 @@ const datePickerProps = Object.assign(Object.assign({}, useTheme.props), { to: u
|
|
|
26
26
|
}, clearable: Boolean, updateValueOnClose: Boolean, defaultValue: {
|
|
27
27
|
type: [Number, Array],
|
|
28
28
|
default: null
|
|
29
|
-
}, disabled: {
|
|
29
|
+
}, defaultTime: [Number, String, Array], disabled: {
|
|
30
30
|
type: Boolean,
|
|
31
31
|
default: undefined
|
|
32
32
|
}, placement: {
|
|
@@ -101,6 +101,8 @@ export default defineComponent({
|
|
|
101
101
|
return localeRef.value.monthPlaceholder;
|
|
102
102
|
case 'year':
|
|
103
103
|
return localeRef.value.yearPlaceholder;
|
|
104
|
+
case 'quarter':
|
|
105
|
+
return localeRef.value.quarterPlaceholder;
|
|
104
106
|
default:
|
|
105
107
|
return '';
|
|
106
108
|
}
|
|
@@ -152,6 +154,8 @@ export default defineComponent({
|
|
|
152
154
|
return localeRef.value.yearTypeFormat;
|
|
153
155
|
case 'month':
|
|
154
156
|
return localeRef.value.monthTypeFormat;
|
|
157
|
+
case 'quarter':
|
|
158
|
+
return localeRef.value.quarterFormat;
|
|
155
159
|
}
|
|
156
160
|
});
|
|
157
161
|
const mergedActionsRef = computed(() => {
|
|
@@ -177,6 +181,9 @@ export default defineComponent({
|
|
|
177
181
|
case 'year': {
|
|
178
182
|
return ['clear', 'now'];
|
|
179
183
|
}
|
|
184
|
+
case 'quarter': {
|
|
185
|
+
return ['clear', 'now', 'confirm'];
|
|
186
|
+
}
|
|
180
187
|
default: {
|
|
181
188
|
warn('data-picker', "The type is wrong, n-date-picker's type only supports `date`, `datetime`, `daterange` and `datetimerange`.");
|
|
182
189
|
break;
|
|
@@ -259,7 +266,7 @@ export default defineComponent({
|
|
|
259
266
|
disableUpdateOnClose
|
|
260
267
|
});
|
|
261
268
|
}
|
|
262
|
-
function
|
|
269
|
+
function scrollPickerColumns(value) {
|
|
263
270
|
if (!panelInstRef.value)
|
|
264
271
|
return;
|
|
265
272
|
const { monthScrollRef, yearScrollRef } = panelInstRef.value;
|
|
@@ -405,8 +412,9 @@ export default defineComponent({
|
|
|
405
412
|
if (mergedDisabledRef.value || mergedShowRef.value)
|
|
406
413
|
return;
|
|
407
414
|
doUpdateShow(true);
|
|
408
|
-
|
|
409
|
-
|
|
415
|
+
const { type } = props;
|
|
416
|
+
if (type === 'month' || type === 'year' || type === 'quarter') {
|
|
417
|
+
void nextTick(scrollPickerColumns);
|
|
410
418
|
}
|
|
411
419
|
}
|
|
412
420
|
function closeCalendar({ returnFocus, disableUpdateOnClose }) {
|
|
@@ -442,7 +450,7 @@ export default defineComponent({
|
|
|
442
450
|
// use pending value to do validation
|
|
443
451
|
const uniVaidation = uniCalendarValidation(props, pendingValueRef);
|
|
444
452
|
const dualValidation = dualCalendarValidation(props, pendingValueRef);
|
|
445
|
-
provide(datePickerInjectionKey, Object.assign(Object.assign(Object.assign({
|
|
453
|
+
provide(datePickerInjectionKey, Object.assign(Object.assign(Object.assign({ scrollPickerColumns,
|
|
446
454
|
mergedClsPrefixRef, mergedThemeRef: themeRef, timePickerSizeRef,
|
|
447
455
|
localeRef,
|
|
448
456
|
dateLocaleRef, firstDayOfWeekRef: toRef(props, 'firstDayOfWeek'), isDateDisabledRef: toRef(props, 'isDateDisabled'), rangesRef: toRef(props, 'ranges'), closeOnSelectRef: toRef(props, 'closeOnSelect'), updateValueOnCloseRef: toRef(props, 'updateValueOnClose') }, uniVaidation), dualValidation), { datePickerSlots: slots }));
|
|
@@ -578,7 +586,8 @@ export default defineComponent({
|
|
|
578
586
|
active: this.mergedShow,
|
|
579
587
|
actions: this.actions,
|
|
580
588
|
shortcuts: this.shortcuts,
|
|
581
|
-
style: this.cssVars
|
|
589
|
+
style: this.cssVars,
|
|
590
|
+
defaultTime: this.defaultTime
|
|
582
591
|
};
|
|
583
592
|
const { mergedClsPrefix } = this;
|
|
584
593
|
return (h("div", { ref: "triggerElRef", class: [
|
|
@@ -607,7 +616,7 @@ export default defineComponent({
|
|
|
607
616
|
h(VFollower, { show: this.mergedShow, containerClass: this.namespace, to: this.adjustedTo, teleportDisabled: this.adjustedTo === useAdjustedTo.tdkey, placement: "bottom-start" }, {
|
|
608
617
|
default: () => (h(Transition, { name: "fade-in-scale-up-transition", appear: this.isMounted }, {
|
|
609
618
|
default: () => this.mergedShow
|
|
610
|
-
? withDirectives(this.type === 'datetime' ? (h(DatetimePanel, Object.assign({}, commonPanelProps))) : this.type === 'daterange' ? (h(DaterangePanel, Object.assign({}, commonPanelProps))) : this.type === 'datetimerange' ? (h(DatetimerangePanel, Object.assign({}, commonPanelProps))) : this.type === 'month' ? (h(MonthPanel, Object.assign({}, commonPanelProps, { type: "month", key: "month" }))) : this.type === 'year' ? (h(MonthPanel, Object.assign({}, commonPanelProps, { type: "year", key: "year" }))) : (h(DatePanel, Object.assign({}, commonPanelProps))), [[clickoutside, this.handleClickOutside]])
|
|
619
|
+
? withDirectives(this.type === 'datetime' ? (h(DatetimePanel, Object.assign({}, commonPanelProps))) : this.type === 'daterange' ? (h(DaterangePanel, Object.assign({}, commonPanelProps))) : this.type === 'datetimerange' ? (h(DatetimerangePanel, Object.assign({}, commonPanelProps))) : this.type === 'month' ? (h(MonthPanel, Object.assign({}, commonPanelProps, { type: "month", key: "month" }))) : this.type === 'year' ? (h(MonthPanel, Object.assign({}, commonPanelProps, { type: "year", key: "year" }))) : this.type === 'quarter' ? (h(MonthPanel, Object.assign({}, commonPanelProps, { type: "quarter", key: "quarter" }))) : (h(DatePanel, Object.assign({}, commonPanelProps))), [[clickoutside, this.handleClickOutside]])
|
|
611
620
|
: null
|
|
612
621
|
}))
|
|
613
622
|
})
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const START_YEAR = 1901;
|
|
2
2
|
export declare const MONTH_ITEM_HEIGHT = 40;
|
|
3
|
-
export declare type DatePickerType = 'date' | 'datetime' | 'daterange' | 'datetimerange' | 'month' | 'year';
|
|
3
|
+
export declare type DatePickerType = 'date' | 'datetime' | 'daterange' | 'datetimerange' | 'month' | 'year' | 'quarter';
|
|
@@ -7,6 +7,7 @@ import { MergedTheme } from '../../_mixins';
|
|
|
7
7
|
import { DatePickerTheme } from '../styles/light';
|
|
8
8
|
import { uniCalendarValidation, dualCalendarValidation } from './validation-utils';
|
|
9
9
|
export declare type Value = number | [number, number];
|
|
10
|
+
export declare type DefaultTime = string | [string | undefined, string | undefined];
|
|
10
11
|
export declare type Shortcuts = Record<string, number | (() => number)> | Record<string, [number, number] | (() => [number, number])>;
|
|
11
12
|
export declare type OnUpdateValue = (value: number & (number | null) & [number, number] & ([number, number] | null)) => void;
|
|
12
13
|
export declare type OnUpdateValueImpl = (value: Value | null) => void;
|
|
@@ -34,7 +35,7 @@ export declare type DatePickerInjection = {
|
|
|
34
35
|
updateValueOnCloseRef: Ref<boolean>;
|
|
35
36
|
firstDayOfWeekRef: Ref<FirstDayOfWeek | undefined>;
|
|
36
37
|
datePickerSlots: Slots;
|
|
37
|
-
|
|
38
|
+
scrollPickerColumns: (value?: number) => void;
|
|
38
39
|
} & ReturnType<typeof uniCalendarValidation> & ReturnType<typeof dualCalendarValidation>;
|
|
39
40
|
export declare const datePickerInjectionKey: InjectionKey<DatePickerInjection>;
|
|
40
41
|
export declare type IsDateDisabled = IsSingleDateDisabled | IsRangeDateDisabled;
|
|
@@ -17,6 +17,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
17
17
|
readonly default: null;
|
|
18
18
|
};
|
|
19
19
|
readonly shortcuts: import("vue").PropType<import("../interface").Shortcuts>;
|
|
20
|
+
readonly defaultTime: import("vue").PropType<import("../interface").DefaultTime>;
|
|
20
21
|
readonly onConfirm: FunctionConstructor;
|
|
21
22
|
readonly onClose: import("vue").PropType<import("../interface").OnClose>;
|
|
22
23
|
readonly onTabOut: FunctionConstructor;
|
|
@@ -25,7 +26,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
25
26
|
readonly required: true;
|
|
26
27
|
};
|
|
27
28
|
}, {
|
|
28
|
-
handleDateClick: (dateItem: import("../utils").DateItem | import("../utils").MonthItem | import("../utils").YearItem) => void;
|
|
29
|
+
handleDateClick: (dateItem: import("../utils").DateItem | import("../utils").MonthItem | import("../utils").YearItem | import("../utils").QuarterItem) => void;
|
|
29
30
|
handleDateInputBlur: () => void;
|
|
30
31
|
handleDateInput: (value: string) => void;
|
|
31
32
|
handleTimePickerChange: (value: number | null) => void;
|
|
@@ -208,12 +209,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
208
209
|
calendarLeftPaddingDatetimerange: string;
|
|
209
210
|
calendarLeftPaddingMonth: string;
|
|
210
211
|
calendarLeftPaddingYear: string;
|
|
212
|
+
calendarLeftPaddingQuarter: string;
|
|
211
213
|
calendarRightPaddingDate: string;
|
|
212
214
|
calendarRightPaddingDatetime: string;
|
|
213
215
|
calendarRightPaddingDaterange: string;
|
|
214
216
|
calendarRightPaddingDatetimerange: string;
|
|
215
217
|
calendarRightPaddingMonth: string;
|
|
216
218
|
calendarRightPaddingYear: string;
|
|
219
|
+
calendarRightPaddingQuarter: string;
|
|
217
220
|
};
|
|
218
221
|
peers: {
|
|
219
222
|
Input: import("../../../_mixins").Theme<"Input", {
|
|
@@ -1074,6 +1077,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1074
1077
|
monthTypeFormat: string;
|
|
1075
1078
|
dateFormat: string;
|
|
1076
1079
|
dateTimeFormat: string;
|
|
1080
|
+
quarterFormat: string;
|
|
1077
1081
|
clear: string;
|
|
1078
1082
|
now: string;
|
|
1079
1083
|
confirm: string;
|
|
@@ -1083,6 +1087,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1083
1087
|
datetimePlaceholder: string;
|
|
1084
1088
|
monthPlaceholder: string;
|
|
1085
1089
|
yearPlaceholder: string;
|
|
1090
|
+
quarterPlaceholder: string;
|
|
1086
1091
|
startDatePlaceholder: string;
|
|
1087
1092
|
endDatePlaceholder: string;
|
|
1088
1093
|
startDatetimePlaceholder: string;
|
|
@@ -1116,6 +1121,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1116
1121
|
dateArray: import("vue").ComputedRef<import("../utils").DateItem[]>;
|
|
1117
1122
|
monthArray: import("vue").ComputedRef<import("../utils").MonthItem[]>;
|
|
1118
1123
|
yearArray: import("vue").ComputedRef<import("../utils").YearItem[]>;
|
|
1124
|
+
quarterArray: import("vue").ComputedRef<import("../utils").QuarterItem[]>;
|
|
1119
1125
|
calendarYear: import("vue").ComputedRef<string>;
|
|
1120
1126
|
calendarMonth: import("vue").ComputedRef<string>;
|
|
1121
1127
|
weekdays: import("vue").ComputedRef<string[]>;
|
|
@@ -1135,6 +1141,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1135
1141
|
readonly timeFormat?: unknown;
|
|
1136
1142
|
readonly value?: unknown;
|
|
1137
1143
|
readonly shortcuts?: unknown;
|
|
1144
|
+
readonly defaultTime?: unknown;
|
|
1138
1145
|
readonly onConfirm?: unknown;
|
|
1139
1146
|
readonly onClose?: unknown;
|
|
1140
1147
|
readonly onTabOut?: unknown;
|
|
@@ -1150,6 +1157,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1150
1157
|
onTabOut?: Function | undefined;
|
|
1151
1158
|
onClose?: import("../interface").OnClose | undefined;
|
|
1152
1159
|
onConfirm?: Function | undefined;
|
|
1160
|
+
defaultTime?: import("../interface").DefaultTime | undefined;
|
|
1153
1161
|
shortcuts?: import("../interface").Shortcuts | undefined;
|
|
1154
1162
|
}>, {
|
|
1155
1163
|
value: import("../interface").Value | null;
|
|
@@ -2,7 +2,7 @@ import { h, defineComponent, renderSlot, watchEffect } from 'vue';
|
|
|
2
2
|
import { NButton, NxButton } from '../../../button';
|
|
3
3
|
import { BackwardIcon, FastBackwardIcon, ForwardIcon, FastForwardIcon } from '../../../_internal/icons';
|
|
4
4
|
import { NBaseFocusDetector } from '../../../_internal';
|
|
5
|
-
import { useCalendar } from './use-calendar';
|
|
5
|
+
import { useCalendar, useCalendarProps } from './use-calendar';
|
|
6
6
|
import { warnOnce } from '../../../_utils';
|
|
7
7
|
/**
|
|
8
8
|
* Date Panel
|
|
@@ -12,7 +12,7 @@ import { warnOnce } from '../../../_utils';
|
|
|
12
12
|
*/
|
|
13
13
|
export default defineComponent({
|
|
14
14
|
name: 'DatePanel',
|
|
15
|
-
props:
|
|
15
|
+
props: useCalendarProps,
|
|
16
16
|
setup(props) {
|
|
17
17
|
if (process.env.NODE_ENV !== 'production') {
|
|
18
18
|
watchEffect(() => {
|
|
@@ -17,6 +17,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
17
17
|
readonly default: null;
|
|
18
18
|
};
|
|
19
19
|
readonly shortcuts: import("vue").PropType<import("../interface").Shortcuts>;
|
|
20
|
+
readonly defaultTime: import("vue").PropType<import("../interface").DefaultTime>;
|
|
20
21
|
readonly onConfirm: FunctionConstructor;
|
|
21
22
|
readonly onClose: import("vue").PropType<import("../interface").OnClose>;
|
|
22
23
|
readonly onTabOut: FunctionConstructor;
|
|
@@ -206,12 +207,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
206
207
|
calendarLeftPaddingDatetimerange: string;
|
|
207
208
|
calendarLeftPaddingMonth: string;
|
|
208
209
|
calendarLeftPaddingYear: string;
|
|
210
|
+
calendarLeftPaddingQuarter: string;
|
|
209
211
|
calendarRightPaddingDate: string;
|
|
210
212
|
calendarRightPaddingDatetime: string;
|
|
211
213
|
calendarRightPaddingDaterange: string;
|
|
212
214
|
calendarRightPaddingDatetimerange: string;
|
|
213
215
|
calendarRightPaddingMonth: string;
|
|
214
216
|
calendarRightPaddingYear: string;
|
|
217
|
+
calendarRightPaddingQuarter: string;
|
|
215
218
|
};
|
|
216
219
|
peers: {
|
|
217
220
|
Input: import("../../../_mixins").Theme<"Input", {
|
|
@@ -1072,6 +1075,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1072
1075
|
monthTypeFormat: string;
|
|
1073
1076
|
dateFormat: string;
|
|
1074
1077
|
dateTimeFormat: string;
|
|
1078
|
+
quarterFormat: string;
|
|
1075
1079
|
clear: string;
|
|
1076
1080
|
now: string;
|
|
1077
1081
|
confirm: string;
|
|
@@ -1081,6 +1085,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1081
1085
|
datetimePlaceholder: string;
|
|
1082
1086
|
monthPlaceholder: string;
|
|
1083
1087
|
yearPlaceholder: string;
|
|
1088
|
+
quarterPlaceholder: string;
|
|
1084
1089
|
startDatePlaceholder: string;
|
|
1085
1090
|
endDatePlaceholder: string;
|
|
1086
1091
|
startDatetimePlaceholder: string;
|
|
@@ -1135,6 +1140,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1135
1140
|
readonly timeFormat?: unknown;
|
|
1136
1141
|
readonly value?: unknown;
|
|
1137
1142
|
readonly shortcuts?: unknown;
|
|
1143
|
+
readonly defaultTime?: unknown;
|
|
1138
1144
|
readonly onConfirm?: unknown;
|
|
1139
1145
|
readonly onClose?: unknown;
|
|
1140
1146
|
readonly onTabOut?: unknown;
|
|
@@ -1150,6 +1156,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1150
1156
|
onTabOut?: Function | undefined;
|
|
1151
1157
|
onClose?: import("../interface").OnClose | undefined;
|
|
1152
1158
|
onConfirm?: Function | undefined;
|
|
1159
|
+
defaultTime?: import("../interface").DefaultTime | undefined;
|
|
1153
1160
|
shortcuts?: import("../interface").Shortcuts | undefined;
|
|
1154
1161
|
}>, {
|
|
1155
1162
|
value: import("../interface").Value | null;
|
|
@@ -2,11 +2,11 @@ import { defineComponent, h, renderSlot, watchEffect } from 'vue';
|
|
|
2
2
|
import { NButton, NxButton } from '../../../button';
|
|
3
3
|
import { BackwardIcon, FastBackwardIcon, ForwardIcon, FastForwardIcon } from '../../../_internal/icons';
|
|
4
4
|
import { NBaseFocusDetector } from '../../../_internal';
|
|
5
|
-
import { useDualCalendar } from './use-dual-calendar';
|
|
5
|
+
import { useDualCalendar, useDualCalendarProps } from './use-dual-calendar';
|
|
6
6
|
import { warnOnce } from '../../../_utils';
|
|
7
7
|
export default defineComponent({
|
|
8
8
|
name: 'DateRangePanel',
|
|
9
|
-
props:
|
|
9
|
+
props: useDualCalendarProps,
|
|
10
10
|
setup(props) {
|
|
11
11
|
if (process.env.NODE_ENV !== 'production') {
|
|
12
12
|
watchEffect(() => {
|
|
@@ -17,6 +17,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
17
17
|
readonly default: null;
|
|
18
18
|
};
|
|
19
19
|
readonly shortcuts: import("vue").PropType<import("../interface").Shortcuts>;
|
|
20
|
+
readonly defaultTime: import("vue").PropType<import("../interface").DefaultTime>;
|
|
20
21
|
readonly onConfirm: FunctionConstructor;
|
|
21
22
|
readonly onClose: import("vue").PropType<import("../interface").OnClose>;
|
|
22
23
|
readonly onTabOut: FunctionConstructor;
|
|
@@ -25,7 +26,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
25
26
|
readonly required: true;
|
|
26
27
|
};
|
|
27
28
|
}, {
|
|
28
|
-
handleDateClick: (dateItem: import("../utils").DateItem | import("../utils").MonthItem | import("../utils").YearItem) => void;
|
|
29
|
+
handleDateClick: (dateItem: import("../utils").DateItem | import("../utils").MonthItem | import("../utils").YearItem | import("../utils").QuarterItem) => void;
|
|
29
30
|
handleDateInputBlur: () => void;
|
|
30
31
|
handleDateInput: (value: string) => void;
|
|
31
32
|
handleTimePickerChange: (value: number | null) => void;
|
|
@@ -143,12 +144,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
143
144
|
fontWeightStrong: string;
|
|
144
145
|
cubicBezierEaseInOut: string;
|
|
145
146
|
cubicBezierEaseOut: string;
|
|
146
|
-
/**
|
|
147
|
-
* DateTime Panel
|
|
148
|
-
* Update picker value on:
|
|
149
|
-
* 1. confirm click
|
|
150
|
-
* 2. clear click
|
|
151
|
-
*/
|
|
152
147
|
cubicBezierEaseIn: string;
|
|
153
148
|
borderRadius: string;
|
|
154
149
|
borderRadiusSmall: string;
|
|
@@ -214,12 +209,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
214
209
|
calendarLeftPaddingDatetimerange: string;
|
|
215
210
|
calendarLeftPaddingMonth: string;
|
|
216
211
|
calendarLeftPaddingYear: string;
|
|
212
|
+
calendarLeftPaddingQuarter: string;
|
|
217
213
|
calendarRightPaddingDate: string;
|
|
218
214
|
calendarRightPaddingDatetime: string;
|
|
219
215
|
calendarRightPaddingDaterange: string;
|
|
220
216
|
calendarRightPaddingDatetimerange: string;
|
|
221
217
|
calendarRightPaddingMonth: string;
|
|
222
218
|
calendarRightPaddingYear: string;
|
|
219
|
+
calendarRightPaddingQuarter: string;
|
|
223
220
|
};
|
|
224
221
|
peers: {
|
|
225
222
|
Input: import("../../../_mixins").Theme<"Input", {
|
|
@@ -1080,6 +1077,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1080
1077
|
monthTypeFormat: string;
|
|
1081
1078
|
dateFormat: string;
|
|
1082
1079
|
dateTimeFormat: string;
|
|
1080
|
+
quarterFormat: string;
|
|
1083
1081
|
clear: string;
|
|
1084
1082
|
now: string;
|
|
1085
1083
|
confirm: string;
|
|
@@ -1089,6 +1087,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1089
1087
|
datetimePlaceholder: string;
|
|
1090
1088
|
monthPlaceholder: string;
|
|
1091
1089
|
yearPlaceholder: string;
|
|
1090
|
+
quarterPlaceholder: string;
|
|
1092
1091
|
startDatePlaceholder: string;
|
|
1093
1092
|
endDatePlaceholder: string;
|
|
1094
1093
|
startDatetimePlaceholder: string;
|
|
@@ -1122,6 +1121,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1122
1121
|
dateArray: import("vue").ComputedRef<import("../utils").DateItem[]>;
|
|
1123
1122
|
monthArray: import("vue").ComputedRef<import("../utils").MonthItem[]>;
|
|
1124
1123
|
yearArray: import("vue").ComputedRef<import("../utils").YearItem[]>;
|
|
1124
|
+
quarterArray: import("vue").ComputedRef<import("../utils").QuarterItem[]>;
|
|
1125
1125
|
calendarYear: import("vue").ComputedRef<string>;
|
|
1126
1126
|
calendarMonth: import("vue").ComputedRef<string>;
|
|
1127
1127
|
weekdays: import("vue").ComputedRef<string[]>;
|
|
@@ -1141,6 +1141,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1141
1141
|
readonly timeFormat?: unknown;
|
|
1142
1142
|
readonly value?: unknown;
|
|
1143
1143
|
readonly shortcuts?: unknown;
|
|
1144
|
+
readonly defaultTime?: unknown;
|
|
1144
1145
|
readonly onConfirm?: unknown;
|
|
1145
1146
|
readonly onClose?: unknown;
|
|
1146
1147
|
readonly onTabOut?: unknown;
|
|
@@ -1156,6 +1157,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1156
1157
|
onTabOut?: Function | undefined;
|
|
1157
1158
|
onClose?: import("../interface").OnClose | undefined;
|
|
1158
1159
|
onConfirm?: Function | undefined;
|
|
1160
|
+
defaultTime?: import("../interface").DefaultTime | undefined;
|
|
1159
1161
|
shortcuts?: import("../interface").Shortcuts | undefined;
|
|
1160
1162
|
}>, {
|
|
1161
1163
|
value: import("../interface").Value | null;
|
|
@@ -4,7 +4,7 @@ import { NTimePicker } from '../../../time-picker';
|
|
|
4
4
|
import { NInput } from '../../../input';
|
|
5
5
|
import { BackwardIcon, FastBackwardIcon, ForwardIcon, FastForwardIcon } from '../../../_internal/icons';
|
|
6
6
|
import { NBaseFocusDetector } from '../../../_internal';
|
|
7
|
-
import { useCalendar } from './use-calendar';
|
|
7
|
+
import { useCalendar, useCalendarProps } from './use-calendar';
|
|
8
8
|
/**
|
|
9
9
|
* DateTime Panel
|
|
10
10
|
* Update picker value on:
|
|
@@ -13,7 +13,7 @@ import { useCalendar } from './use-calendar';
|
|
|
13
13
|
*/
|
|
14
14
|
export default defineComponent({
|
|
15
15
|
name: 'DateTimePanel',
|
|
16
|
-
props:
|
|
16
|
+
props: useCalendarProps,
|
|
17
17
|
setup(props) {
|
|
18
18
|
return useCalendar(props, 'datetime');
|
|
19
19
|
},
|
|
@@ -17,6 +17,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
17
17
|
readonly default: null;
|
|
18
18
|
};
|
|
19
19
|
readonly shortcuts: import("vue").PropType<import("../interface").Shortcuts>;
|
|
20
|
+
readonly defaultTime: import("vue").PropType<import("../interface").DefaultTime>;
|
|
20
21
|
readonly onConfirm: FunctionConstructor;
|
|
21
22
|
readonly onClose: import("vue").PropType<import("../interface").OnClose>;
|
|
22
23
|
readonly onTabOut: FunctionConstructor;
|
|
@@ -206,12 +207,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
206
207
|
calendarLeftPaddingDatetimerange: string;
|
|
207
208
|
calendarLeftPaddingMonth: string;
|
|
208
209
|
calendarLeftPaddingYear: string;
|
|
210
|
+
calendarLeftPaddingQuarter: string;
|
|
209
211
|
calendarRightPaddingDate: string;
|
|
210
212
|
calendarRightPaddingDatetime: string;
|
|
211
213
|
calendarRightPaddingDaterange: string;
|
|
212
214
|
calendarRightPaddingDatetimerange: string;
|
|
213
215
|
calendarRightPaddingMonth: string;
|
|
214
216
|
calendarRightPaddingYear: string;
|
|
217
|
+
calendarRightPaddingQuarter: string;
|
|
215
218
|
};
|
|
216
219
|
peers: {
|
|
217
220
|
Input: import("../../../_mixins").Theme<"Input", {
|
|
@@ -1072,6 +1075,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1072
1075
|
monthTypeFormat: string;
|
|
1073
1076
|
dateFormat: string;
|
|
1074
1077
|
dateTimeFormat: string;
|
|
1078
|
+
quarterFormat: string;
|
|
1075
1079
|
clear: string;
|
|
1076
1080
|
now: string;
|
|
1077
1081
|
confirm: string;
|
|
@@ -1081,6 +1085,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1081
1085
|
datetimePlaceholder: string;
|
|
1082
1086
|
monthPlaceholder: string;
|
|
1083
1087
|
yearPlaceholder: string;
|
|
1088
|
+
quarterPlaceholder: string;
|
|
1084
1089
|
startDatePlaceholder: string;
|
|
1085
1090
|
endDatePlaceholder: string;
|
|
1086
1091
|
startDatetimePlaceholder: string;
|
|
@@ -1135,6 +1140,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1135
1140
|
readonly timeFormat?: unknown;
|
|
1136
1141
|
readonly value?: unknown;
|
|
1137
1142
|
readonly shortcuts?: unknown;
|
|
1143
|
+
readonly defaultTime?: unknown;
|
|
1138
1144
|
readonly onConfirm?: unknown;
|
|
1139
1145
|
readonly onClose?: unknown;
|
|
1140
1146
|
readonly onTabOut?: unknown;
|
|
@@ -1150,6 +1156,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
1150
1156
|
onTabOut?: Function | undefined;
|
|
1151
1157
|
onClose?: import("../interface").OnClose | undefined;
|
|
1152
1158
|
onConfirm?: Function | undefined;
|
|
1159
|
+
defaultTime?: import("../interface").DefaultTime | undefined;
|
|
1153
1160
|
shortcuts?: import("../interface").Shortcuts | undefined;
|
|
1154
1161
|
}>, {
|
|
1155
1162
|
value: import("../interface").Value | null;
|
|
@@ -4,11 +4,11 @@ import { NInput } from '../../../input';
|
|
|
4
4
|
import { NTimePicker } from '../../../time-picker';
|
|
5
5
|
import { BackwardIcon, FastBackwardIcon, ForwardIcon, FastForwardIcon } from '../../../_internal/icons';
|
|
6
6
|
import { NBaseFocusDetector } from '../../../_internal';
|
|
7
|
-
import { useDualCalendar } from './use-dual-calendar';
|
|
8
7
|
import { warnOnce } from '../../../_utils';
|
|
8
|
+
import { useDualCalendar, useDualCalendarProps } from './use-dual-calendar';
|
|
9
9
|
export default defineComponent({
|
|
10
10
|
name: 'DateTimeRangePanel',
|
|
11
|
-
props:
|
|
11
|
+
props: useDualCalendarProps,
|
|
12
12
|
setup(props) {
|
|
13
13
|
if (process.env.NODE_ENV !== 'production') {
|
|
14
14
|
watchEffect(() => {
|