@blueking/date-picker 1.0.1 → 2.0.0-beta.2
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/README.md +2 -4
- package/package.json +81 -41
- package/{dist → typings}/components/common-submit.vue.d.ts +3 -3
- package/{dist → typings}/components/common-tab.vue.d.ts +1 -1
- package/{dist → typings}/components/date-panel.vue.d.ts +11 -11
- package/{dist → typings}/components/date-picker.vue.d.ts +3 -3
- package/{dist → typings}/components/natural-picker.vue.d.ts +3 -3
- package/{dist → typings}/components/panel-wrapper.vue.d.ts +4 -4
- package/{dist → typings}/components/recent-picker.vue.d.ts +11 -11
- package/{dist → typings}/components/timezone-picker.vue.d.ts +3 -3
- package/{dist → typings}/date-picker.vue.d.ts +14 -14
- package/{dist → typings}/utils/store.d.ts +1 -1
- package/vue2/config.json +1 -0
- package/{dist/vue3-full.es.js → vue2/index.es.min.js} +10374 -9770
- package/vue2/index.iife.min.js +76 -0
- package/vue2/index.umd.min.js +57 -0
- package/vue2/vue2.css +1 -0
- package/vue3/config.json +1 -0
- package/{dist/vue3-light.es.js → vue3/index.es.min.js} +160 -168
- package/vue3/index.iife.min.js +57 -0
- package/vue3/index.umd.min.js +2 -0
- package/{dist/vue3-light.css → vue3/vue3.css} +1 -1
- package/dist/vue2-full.css +0 -1
- package/dist/vue2-full.es.js +0 -27080
- package/dist/vue2-light.css +0 -1
- package/dist/vue2-light.es.js +0 -26458
- package/dist/vue3-full.css +0 -1
- /package/{dist → typings}/lang/lang.d.ts +0 -0
- /package/{dist → typings}/utils/constant.d.ts +0 -0
- /package/{dist → typings}/utils/cookie.d.ts +0 -0
- /package/{dist → typings}/utils/date.d.ts +0 -0
- /package/{dist → typings}/utils/index.d.ts +0 -0
- /package/{dist → typings}/utils/timezone.d.ts +0 -0
- /package/{dist → typings}/utils/types.d.ts +0 -0
- /package/{dist → typings}/utils/utils.d.ts +0 -0
- /package/{dist → typings}/vue2.d.ts +0 -0
- /package/{dist → typings}/vue3.d.ts +0 -0
package/README.md
CHANGED
|
@@ -32,10 +32,8 @@ npm i @blueking/date-picker
|
|
|
32
32
|
import { ref } from 'vue';
|
|
33
33
|
|
|
34
34
|
import DatePicker from '@blueking/date-picker';
|
|
35
|
+
import DatePicker from '@blueking/date-picker/vue3/vue3.css';
|
|
35
36
|
|
|
36
|
-
// 如果项目没有安装bkui-vue, dayjs 则可使用全量版本
|
|
37
|
-
import DatePicker from '@blueking/date-picker/vue3';
|
|
38
|
-
import '@blueking/date-picker/dist/vue3-full.css';
|
|
39
37
|
|
|
40
38
|
const value = ref(['now-2d/d', 'now',]);
|
|
41
39
|
const timezone = ref('Asia/Shanghai');
|
|
@@ -59,7 +57,7 @@ const handleValueChange = (value, info) => {
|
|
|
59
57
|
|
|
60
58
|
<script>
|
|
61
59
|
import DatePicker from '@blueking/date-picker/vue2'
|
|
62
|
-
import '@blueking/date-picker/
|
|
60
|
+
import '@blueking/date-picker/vue2/vue2.css'
|
|
63
61
|
export default {
|
|
64
62
|
data(){
|
|
65
63
|
return {
|
package/package.json
CHANGED
|
@@ -1,74 +1,101 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blueking/date-picker",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-beta.2",
|
|
4
4
|
"description": "蓝鲸监控平台日期时间选择",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Tencent BlueKing",
|
|
7
|
-
"packageManager": "pnpm@8.6.0",
|
|
8
7
|
"exports": {
|
|
9
8
|
".": {
|
|
10
|
-
"types": "./
|
|
11
|
-
"import": "./dist/vue3
|
|
12
|
-
"
|
|
13
|
-
"default": "./dist/vue3-light.es.js"
|
|
9
|
+
"types": "./typings/vue3.d.ts",
|
|
10
|
+
"import": "./dist/vue3/index.es.min.js",
|
|
11
|
+
"default": "./dist/vue3/index.es.min.js"
|
|
14
12
|
},
|
|
15
13
|
"./vue3": {
|
|
16
|
-
"types": "./
|
|
17
|
-
"import": "./dist/vue3
|
|
18
|
-
"
|
|
19
|
-
"default": "./dist/vue3-full.es.js"
|
|
14
|
+
"types": "./typings/vue3.d.ts",
|
|
15
|
+
"import": "./dist/vue3/index.es.min.js",
|
|
16
|
+
"default": "./dist/vue3/index.es.min.js"
|
|
20
17
|
},
|
|
21
18
|
"./vue2": {
|
|
22
|
-
"types": "./
|
|
23
|
-
"import": "./dist/vue2
|
|
24
|
-
"
|
|
25
|
-
"default": "./dist/vue2-light.es.js"
|
|
26
|
-
},
|
|
27
|
-
"./vue2.full": {
|
|
28
|
-
"types": "./dist/vue2.d.ts",
|
|
29
|
-
"import": "./dist/vue2-full.es.js",
|
|
30
|
-
"require": "./dist/vue2-full.es.js",
|
|
31
|
-
"default": "./dist/vue2-full.es.js"
|
|
32
|
-
},
|
|
33
|
-
"./dist/*": "./dist/*",
|
|
34
|
-
"./src/date-picker.vue": {
|
|
35
|
-
"types": "./dist/date-picker.vue.d.ts",
|
|
36
|
-
"import": "./src/date-picker.vue"
|
|
19
|
+
"types": "./typings/vue2.d.ts",
|
|
20
|
+
"import": "./dist/vue2/index.es.min.js",
|
|
21
|
+
"default": "./dist/vue2/index.es.min.js"
|
|
37
22
|
}
|
|
38
23
|
},
|
|
39
24
|
"typesVersions": {
|
|
40
25
|
"*": {
|
|
41
26
|
".": [
|
|
42
|
-
"./
|
|
27
|
+
"./typings/vue3.d.ts"
|
|
43
28
|
],
|
|
44
29
|
"vue3": [
|
|
45
|
-
"./
|
|
30
|
+
"./typings/vue3.d.ts"
|
|
46
31
|
],
|
|
47
32
|
"vue2": [
|
|
48
|
-
"./
|
|
49
|
-
],
|
|
50
|
-
"vue2.full": [
|
|
51
|
-
"./dist/vue2.d.ts"
|
|
33
|
+
"./typings/vue2.d.ts"
|
|
52
34
|
]
|
|
53
35
|
}
|
|
54
36
|
},
|
|
55
|
-
"types": "./
|
|
56
|
-
"main": "dist/vue3
|
|
57
|
-
"unpkg": "dist/vue3
|
|
37
|
+
"types": "./typings/vue3.d.ts",
|
|
38
|
+
"main": "dist/vue3/index.es.min.js",
|
|
39
|
+
"unpkg": "dist/vue3/index.es.min.js",
|
|
58
40
|
"files": [
|
|
59
|
-
"
|
|
41
|
+
"vue2",
|
|
42
|
+
"vue3",
|
|
43
|
+
"typings"
|
|
60
44
|
],
|
|
61
45
|
"publishConfig": {
|
|
62
46
|
"access": "public",
|
|
63
47
|
"registry": "https://registry.npmjs.org/"
|
|
64
48
|
},
|
|
65
49
|
"dependencies": {
|
|
50
|
+
"@blueking/bkui-library": "0.0.0-beta.2",
|
|
66
51
|
"dayjs": "^1.11.10"
|
|
67
52
|
},
|
|
68
|
-
"
|
|
69
|
-
"
|
|
70
|
-
"
|
|
71
|
-
"
|
|
53
|
+
"devDependencies": {
|
|
54
|
+
"@types/node": "^20.12.3",
|
|
55
|
+
"@types/prompts": "^2.4.9",
|
|
56
|
+
"@types/semver": "^7.5.8",
|
|
57
|
+
"@typescript-eslint/eslint-plugin": "^7.5.0",
|
|
58
|
+
"@typescript-eslint/parser": "^7.5.0",
|
|
59
|
+
"@vitejs/plugin-vue": "^5.0.4",
|
|
60
|
+
"bkui-vue": "1.0.3-beta.25",
|
|
61
|
+
"eslint": "^8.57.0",
|
|
62
|
+
"eslint-config-prettier": "^9.1.0",
|
|
63
|
+
"eslint-config-tencent": "^1.0.4",
|
|
64
|
+
"eslint-plugin-codecc": "^0.3.0",
|
|
65
|
+
"eslint-plugin-perfectionist": "^2.7.0",
|
|
66
|
+
"eslint-plugin-prettier": "^5.1.3",
|
|
67
|
+
"eslint-plugin-vue": "^9.24.0",
|
|
68
|
+
"execa": "^8.0.1",
|
|
69
|
+
"less": "^4.2.0",
|
|
70
|
+
"lint-staged": "^15.2.2",
|
|
71
|
+
"npm-run-all": "^4.1.5",
|
|
72
|
+
"picocolors": "^1.0.0",
|
|
73
|
+
"postcss-html": "^1.6.0",
|
|
74
|
+
"postcss-scss": "^4.0.9",
|
|
75
|
+
"prettier": "^3.2.5",
|
|
76
|
+
"prompts": "^2.4.2",
|
|
77
|
+
"sass": "^1.72.0",
|
|
78
|
+
"semver": "^7.6.0",
|
|
79
|
+
"simple-git-hooks": "^2.11.1",
|
|
80
|
+
"stylelint": "^16.3.1",
|
|
81
|
+
"stylelint-config-recess-order": "^5.0.0",
|
|
82
|
+
"stylelint-config-recommended-vue": "1.5.0",
|
|
83
|
+
"stylelint-config-standard": "^36.0.0",
|
|
84
|
+
"stylelint-order": "^6.0.4",
|
|
85
|
+
"stylelint-scss": "^6.2.1",
|
|
86
|
+
"terser": "^5.30.2",
|
|
87
|
+
"ts-node": "^10.9.2",
|
|
88
|
+
"tslib": "^2.6.2",
|
|
89
|
+
"tsx": "^4.7.1",
|
|
90
|
+
"typescript": "^5.4.3",
|
|
91
|
+
"vite": "^5.2.7",
|
|
92
|
+
"vite-bundle-visualizer": "^1.1.0",
|
|
93
|
+
"vite-plugin-css-injected-by-js": "^3.5.0",
|
|
94
|
+
"vite-plugin-inspect": "^0.8.3",
|
|
95
|
+
"vue": "^3.4.21",
|
|
96
|
+
"vue-eslint-parser": "^9.4.2",
|
|
97
|
+
"vue-tsc": "^2.0.7",
|
|
98
|
+
"zip-a-folder": "^3.1.6"
|
|
72
99
|
},
|
|
73
100
|
"engines": {
|
|
74
101
|
"node": ">=18.16.0"
|
|
@@ -79,11 +106,24 @@
|
|
|
79
106
|
"Firefox ESR",
|
|
80
107
|
"not dead"
|
|
81
108
|
],
|
|
109
|
+
"simple-git-hooks": {
|
|
110
|
+
"pre-commit": "lint-staged",
|
|
111
|
+
"commit-msg": "node scripts/verify.commit.mjs"
|
|
112
|
+
},
|
|
113
|
+
"lint-staged": {
|
|
114
|
+
"*.{js,json}": [
|
|
115
|
+
"prettier --write"
|
|
116
|
+
],
|
|
117
|
+
"*.ts?(x)": [
|
|
118
|
+
"eslint --fix"
|
|
119
|
+
]
|
|
120
|
+
},
|
|
82
121
|
"scripts": {
|
|
122
|
+
"release": "tsx scripts/release.ts",
|
|
123
|
+
"dev": "vite --mode development -c scripts/vite.dev.ts",
|
|
83
124
|
"build": "tsx ./scripts/vite.build.ts",
|
|
84
125
|
"dts": "vue-tsc --project tsconfig.dts.json",
|
|
85
|
-
"prettier": "prettier ./src ./scripts --write",
|
|
86
|
-
"debug": "export TS_NODE_PROJECT=tsconfig.node.json && node --inspect-brk -r ts-node/register ./scripts/vite.build.ts",
|
|
126
|
+
"prettier": "prettier ./src ./scripts ./playground --write",
|
|
87
127
|
"visualize": "vite-bundle-visualizer -c scripts/vite.vusualizer.ts"
|
|
88
128
|
}
|
|
89
129
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<
|
|
1
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
2
2
|
disableTips?: string | undefined;
|
|
3
3
|
/**
|
|
4
4
|
* 是否禁用
|
|
@@ -6,7 +6,7 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
|
|
|
6
6
|
disabled?: boolean | undefined;
|
|
7
7
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
8
|
submit: () => void;
|
|
9
|
-
}, string, import("vue").
|
|
9
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
10
10
|
disableTips?: string | undefined;
|
|
11
11
|
/**
|
|
12
12
|
* 是否禁用
|
|
@@ -17,7 +17,7 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToRuntimePr
|
|
|
17
17
|
}, {}, {}>;
|
|
18
18
|
export default _default;
|
|
19
19
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
20
|
-
type
|
|
20
|
+
type __VLS_TypePropsToOption<T> = {
|
|
21
21
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
22
22
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
23
23
|
} : {
|
|
@@ -15,7 +15,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
15
15
|
default: boolean;
|
|
16
16
|
type: BooleanConstructor;
|
|
17
17
|
};
|
|
18
|
-
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").
|
|
18
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
19
19
|
/** modelValue 选中的tab */
|
|
20
20
|
modelValue: {
|
|
21
21
|
required: true;
|
|
@@ -16,12 +16,12 @@ interface Props {
|
|
|
16
16
|
modelValue?: Dayjs;
|
|
17
17
|
title?: string;
|
|
18
18
|
}
|
|
19
|
-
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<
|
|
19
|
+
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
|
|
20
20
|
format: string;
|
|
21
21
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
22
22
|
"update:modelValue": (date: dayjs.Dayjs) => void;
|
|
23
23
|
"update:isNow": (args_0: boolean) => void;
|
|
24
|
-
}, string, import("vue").
|
|
24
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
|
|
25
25
|
format: string;
|
|
26
26
|
}>>> & {
|
|
27
27
|
"onUpdate:modelValue"?: ((date: dayjs.Dayjs) => any) | undefined;
|
|
@@ -30,15 +30,6 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
|
|
|
30
30
|
format: string;
|
|
31
31
|
}, {}>;
|
|
32
32
|
export default _default;
|
|
33
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
34
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
35
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
36
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
37
|
-
} : {
|
|
38
|
-
type: import('vue').PropType<T[K]>;
|
|
39
|
-
required: true;
|
|
40
|
-
};
|
|
41
|
-
};
|
|
42
33
|
type __VLS_WithDefaults<P, D> = {
|
|
43
34
|
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
44
35
|
default: D[K];
|
|
@@ -47,3 +38,12 @@ type __VLS_WithDefaults<P, D> = {
|
|
|
47
38
|
type __VLS_Prettify<T> = {
|
|
48
39
|
[K in keyof T]: T[K];
|
|
49
40
|
} & {};
|
|
41
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
42
|
+
type __VLS_TypePropsToOption<T> = {
|
|
43
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
44
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
45
|
+
} : {
|
|
46
|
+
type: import('vue').PropType<T[K]>;
|
|
47
|
+
required: true;
|
|
48
|
+
};
|
|
49
|
+
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { type DateValue } from '../utils';
|
|
2
2
|
import { DateRange } from '../utils/date';
|
|
3
|
-
declare const _default: import("vue").DefineComponent<
|
|
3
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
4
4
|
value: DateRange;
|
|
5
5
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
6
6
|
change: (value: DateValue) => void;
|
|
7
|
-
}, string, import("vue").
|
|
7
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
8
8
|
value: DateRange;
|
|
9
9
|
}>>> & {
|
|
10
10
|
onChange?: ((value: DateValue) => any) | undefined;
|
|
11
11
|
}, {}, {}>;
|
|
12
12
|
export default _default;
|
|
13
13
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
14
|
-
type
|
|
14
|
+
type __VLS_TypePropsToOption<T> = {
|
|
15
15
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
16
16
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
17
17
|
} : {
|
|
@@ -4,14 +4,14 @@ interface IProps {
|
|
|
4
4
|
/** 已选择自然日期 */
|
|
5
5
|
value?: DateRange;
|
|
6
6
|
}
|
|
7
|
-
declare const _default: import("vue").DefineComponent<
|
|
7
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<IProps>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
8
8
|
change: (value: NaturalDateValue) => void;
|
|
9
|
-
}, string, import("vue").
|
|
9
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<IProps>>> & {
|
|
10
10
|
onChange?: ((value: NaturalDateValue) => any) | undefined;
|
|
11
11
|
}, {}, {}>;
|
|
12
12
|
export default _default;
|
|
13
13
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
14
|
-
type
|
|
14
|
+
type __VLS_TypePropsToOption<T> = {
|
|
15
15
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
16
16
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
17
17
|
} : {
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import { type DateValue } from '../utils';
|
|
2
2
|
import { DateRange } from '../utils/date';
|
|
3
3
|
import { type ITimezoneItem } from '../utils/timezone';
|
|
4
|
-
declare const _default: import("vue").DefineComponent<
|
|
4
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
5
5
|
defaultDate: DateRange;
|
|
6
6
|
needTimezone?: boolean | undefined;
|
|
7
7
|
timezone?: string | undefined;
|
|
8
8
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
9
9
|
change: (value: DateValue) => void;
|
|
10
10
|
"update:timezone": (value: string, timezoneInfo: ITimezoneItem) => void;
|
|
11
|
-
}, string, import("vue").
|
|
11
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
12
12
|
defaultDate: DateRange;
|
|
13
13
|
needTimezone?: boolean | undefined;
|
|
14
14
|
timezone?: string | undefined;
|
|
15
15
|
}>>> & {
|
|
16
|
-
onChange?: ((value: DateValue) => any) | undefined;
|
|
17
16
|
"onUpdate:timezone"?: ((value: string, timezoneInfo: ITimezoneItem) => any) | undefined;
|
|
17
|
+
onChange?: ((value: DateValue) => any) | undefined;
|
|
18
18
|
}, {}, {}>;
|
|
19
19
|
export default _default;
|
|
20
20
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
21
|
-
type
|
|
21
|
+
type __VLS_TypePropsToOption<T> = {
|
|
22
22
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
23
23
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
24
24
|
} : {
|
|
@@ -4,11 +4,11 @@ interface IProps {
|
|
|
4
4
|
type: DateMode.FUTURE | DateMode.RECENT;
|
|
5
5
|
value?: DateRange;
|
|
6
6
|
}
|
|
7
|
-
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<
|
|
7
|
+
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<IProps>, {
|
|
8
8
|
type: DateMode;
|
|
9
9
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
10
10
|
change: (value: RecentDateValue | FutureDateValue) => void;
|
|
11
|
-
}, string, import("vue").
|
|
11
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<IProps>, {
|
|
12
12
|
type: DateMode;
|
|
13
13
|
}>>> & {
|
|
14
14
|
onChange?: ((value: RecentDateValue | FutureDateValue) => any) | undefined;
|
|
@@ -16,15 +16,6 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
|
|
|
16
16
|
type: DateMode.FUTURE | DateMode.RECENT;
|
|
17
17
|
}, {}>;
|
|
18
18
|
export default _default;
|
|
19
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
20
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
21
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
22
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
23
|
-
} : {
|
|
24
|
-
type: import('vue').PropType<T[K]>;
|
|
25
|
-
required: true;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
19
|
type __VLS_WithDefaults<P, D> = {
|
|
29
20
|
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
30
21
|
default: D[K];
|
|
@@ -33,3 +24,12 @@ type __VLS_WithDefaults<P, D> = {
|
|
|
33
24
|
type __VLS_Prettify<T> = {
|
|
34
25
|
[K in keyof T]: T[K];
|
|
35
26
|
} & {};
|
|
27
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
28
|
+
type __VLS_TypePropsToOption<T> = {
|
|
29
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
30
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
31
|
+
} : {
|
|
32
|
+
type: import('vue').PropType<T[K]>;
|
|
33
|
+
required: true;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { type ITimezoneItem } from '../utils/timezone';
|
|
2
|
-
declare const _default: import("vue").DefineComponent<
|
|
2
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
3
3
|
value?: string | undefined;
|
|
4
4
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
5
5
|
change: (value: string, info: ITimezoneItem) => void;
|
|
6
|
-
}, string, import("vue").
|
|
6
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
7
7
|
value?: string | undefined;
|
|
8
8
|
}>>> & {
|
|
9
9
|
onChange?: ((value: string, info: ITimezoneItem) => any) | undefined;
|
|
10
10
|
}, {}, {}>;
|
|
11
11
|
export default _default;
|
|
12
12
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
13
|
-
type
|
|
13
|
+
type __VLS_TypePropsToOption<T> = {
|
|
14
14
|
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
15
15
|
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
16
16
|
} : {
|
|
@@ -2,7 +2,7 @@ import 'bkui-vue/lib/styles/reset.css';
|
|
|
2
2
|
import dayjs from 'dayjs';
|
|
3
3
|
import { type DateValue, type IDatePickerProps } from './utils';
|
|
4
4
|
import { type ITimezoneItem } from './utils/timezone';
|
|
5
|
-
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<
|
|
5
|
+
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<IDatePickerProps>, {
|
|
6
6
|
behavior: string;
|
|
7
7
|
commonUseList: any;
|
|
8
8
|
format: string;
|
|
@@ -17,7 +17,7 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
|
|
|
17
17
|
formatText: string | null;
|
|
18
18
|
}[]) => void;
|
|
19
19
|
"update:timezone": (value: string, timezoneInfo: ITimezoneItem) => void;
|
|
20
|
-
}, string, import("vue").
|
|
20
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<IDatePickerProps>, {
|
|
21
21
|
behavior: string;
|
|
22
22
|
commonUseList: any;
|
|
23
23
|
format: string;
|
|
@@ -30,22 +30,13 @@ declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_T
|
|
|
30
30
|
}[]) => any) | undefined;
|
|
31
31
|
"onUpdate:timezone"?: ((value: string, timezoneInfo: ITimezoneItem) => any) | undefined;
|
|
32
32
|
}, {
|
|
33
|
-
version: string | number;
|
|
34
|
-
format: string;
|
|
35
33
|
behavior: "normal" | "simplicity";
|
|
36
|
-
needTimezone: boolean;
|
|
37
34
|
commonUseList: DateValue[];
|
|
35
|
+
format: string;
|
|
36
|
+
needTimezone: boolean;
|
|
37
|
+
version: string | number;
|
|
38
38
|
}, {}>;
|
|
39
39
|
export default _default;
|
|
40
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
41
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
42
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
43
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
44
|
-
} : {
|
|
45
|
-
type: import('vue').PropType<T[K]>;
|
|
46
|
-
required: true;
|
|
47
|
-
};
|
|
48
|
-
};
|
|
49
40
|
type __VLS_WithDefaults<P, D> = {
|
|
50
41
|
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
51
42
|
default: D[K];
|
|
@@ -54,3 +45,12 @@ type __VLS_WithDefaults<P, D> = {
|
|
|
54
45
|
type __VLS_Prettify<T> = {
|
|
55
46
|
[K in keyof T]: T[K];
|
|
56
47
|
} & {};
|
|
48
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
49
|
+
type __VLS_TypePropsToOption<T> = {
|
|
50
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
51
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
52
|
+
} : {
|
|
53
|
+
type: import('vue').PropType<T[K]>;
|
|
54
|
+
required: true;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
@@ -5,7 +5,7 @@ export type StoreType = 'local' | 'session';
|
|
|
5
5
|
* @param storeKey store key
|
|
6
6
|
* @returns store value list
|
|
7
7
|
*/
|
|
8
|
-
export declare const getStoreDateList: (storeKey: string, type?: StoreType) =>
|
|
8
|
+
export declare const getStoreDateList: (storeKey: string, type?: StoreType) => never[];
|
|
9
9
|
/**
|
|
10
10
|
*
|
|
11
11
|
* @param val store value
|
package/vue2/config.json
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"type":"blueking-date-picker-new","name":"blueking-date-picker-new","displayName":"蓝鲸监控平台日期组件","framework":"vue2","props":{"behavior":{"type":"string","val":"normal","options":["normal","simplicity"],"tips":"组件展示风格"},"commonUseList":{"type":"array","tips":"常用列表"},"disabled":{"type":"boolean","tips":"是否禁用"},"format":{"type":"string","tips":"日期转换显示格式"},"modelValue":{"type":"array","val":["now-1d","now"],"tips":"日期值"},"needTimezone":{"type":"boolean","tips":"是否展示时区"},"timezone":{"type":"string","tips":"时区值"},"version":{"type":["number","string"],"val":"1.0","tips":"版本号 用于控制本地缓存"}},"events":[{"name":"update:modelValue","tips":"响应组件的点击事件"},{"name":"update:timezone","tips":"更新时区值的事件,以及时区信息"}]}
|