cnhis-design-vue 3.1.31-beta.5 → 3.1.31-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +123 -123
- package/es/components/button-print/index.d.ts +4 -6
- package/es/components/button-print/src/ButtonPrint.vue.d.ts +4 -6
- package/es/components/button-print/src/components/EditFormat.vue.d.ts +2 -3
- package/es/components/button-print/src/components/IdentityVerification.vue.d.ts +4 -6
- package/es/components/keyboard/index.d.ts +4 -4
- package/es/components/keyboard/src/Keyboard.js +4 -4
- package/es/components/keyboard/src/Keyboard.vue.d.ts +4 -4
- package/es/components/scale-view/index.d.ts +2 -3
- package/es/components/scale-view/src/ScaleView.vue.d.ts +2 -3
- package/es/shared/assets/img/failure.js +1 -1
- package/es/shared/assets/img/icon-asc.js +1 -1
- package/es/shared/assets/img/icon-desc.js +1 -1
- package/es/shared/assets/img/no-permission.js +1 -1
- package/es/shared/assets/img/nodata.js +1 -1
- package/es/shared/assets/img/notfound.js +1 -1
- package/es/shared/assets/img/qr.js +1 -1
- package/es/shared/assets/img/success.js +1 -1
- package/es/shared/assets/img/video.js +1 -1
- package/es/shared/assets/img/video_default_cover.js +1 -1
- package/es/shared/assets/img/video_hover.js +1 -1
- package/es/shared/assets/img/video_play_hover.js +1 -1
- package/es/shared/assets/img/xb_big.js +1 -1
- package/es/shared/assets/img/xb_small.js +1 -1
- package/package.json +2 -2
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
- package/es/components/fabric-chart/src/utils/index.d.ts +0 -6823
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
- package/es/shared/utils/tapable/index.d.ts +0 -139
package/README.md
CHANGED
|
@@ -1,123 +1,123 @@
|
|
|
1
|
-
# 安装
|
|
2
|
-
|
|
3
|
-
```shell
|
|
4
|
-
npm i cnhis-design-vue@[版本号]
|
|
5
|
-
# or
|
|
6
|
-
yarn add cnhis-design-vue@[版本号] #推荐
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
## 1.全局引入
|
|
10
|
-
|
|
11
|
-
```typescript
|
|
12
|
-
// main.ts
|
|
13
|
-
import { createApp } from 'vue';
|
|
14
|
-
import App from './App.vue';
|
|
15
|
-
import 'cnhis-design-vue/es/packages/index.css';
|
|
16
|
-
import cui from 'cnhis-design-vue';
|
|
17
|
-
|
|
18
|
-
const app = createApp(App);
|
|
19
|
-
app.use(cui).mount('#app');
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
## 2. 按需引入
|
|
23
|
-
|
|
24
|
-
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
|
25
|
-
|
|
26
|
-
### 2.1 样式处理方式 1(按需引入样式)
|
|
27
|
-
|
|
28
|
-
```shell
|
|
29
|
-
# 安装自动导入样式的插件
|
|
30
|
-
npm i -d vite-plugin-style-import
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
```typescript
|
|
34
|
-
// vite.config.ts
|
|
35
|
-
import { defineConfig } from 'vite';
|
|
36
|
-
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
|
37
|
-
|
|
38
|
-
export default defineConfig({
|
|
39
|
-
plugins: [
|
|
40
|
-
// ...otherPlugins
|
|
41
|
-
createStyleImportPlugin({
|
|
42
|
-
libs: [
|
|
43
|
-
{
|
|
44
|
-
libraryName: 'cnhis-design-vue',
|
|
45
|
-
esModule: true,
|
|
46
|
-
ensureStyleFile: true,
|
|
47
|
-
resolveStyle: name => {
|
|
48
|
-
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
]
|
|
52
|
-
})
|
|
53
|
-
]
|
|
54
|
-
});
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
### 2.2 样式处理方式 2(全局引入样式)
|
|
58
|
-
|
|
59
|
-
```typescript
|
|
60
|
-
// main.ts
|
|
61
|
-
import 'cnhis-design-vue/es/components/index.css';
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
## 3. 注意
|
|
65
|
-
|
|
66
|
-
由于 vxe-table 目前的引入方式是由组件 install 触发的,所以如果需要使用 c-grid/c-big-table 组件,需要全局注册二者任意一个
|
|
67
|
-
|
|
68
|
-
```typescript
|
|
69
|
-
// main.ts
|
|
70
|
-
import { createApp } from 'vue';
|
|
71
|
-
import App from './App.vue';
|
|
72
|
-
|
|
73
|
-
import { CGrid } from 'cnhis-design-vue';
|
|
74
|
-
// 或者
|
|
75
|
-
import { CBigTable } from 'cnhis-design-vue';
|
|
76
|
-
|
|
77
|
-
const app = createApp(App);
|
|
78
|
-
app.use(CGrid);
|
|
79
|
-
// 或者
|
|
80
|
-
app.use(CBigTable);
|
|
81
|
-
app.mount('#app');
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
## 4.FAQ
|
|
85
|
-
|
|
86
|
-
### 4.1 项目打包后样式丢失
|
|
87
|
-
|
|
88
|
-
> 处理方法, 将 cnhis-design-vue 从 vendor 包中移除
|
|
89
|
-
|
|
90
|
-
```typescript
|
|
91
|
-
// vite.config.ts
|
|
92
|
-
import { defineConfig } from 'vite';
|
|
93
|
-
|
|
94
|
-
export default defineConfig({
|
|
95
|
-
rollupOptions: {
|
|
96
|
-
// ..otherOptions
|
|
97
|
-
output: {
|
|
98
|
-
dir: './dist',
|
|
99
|
-
manualChunks(id: string) {
|
|
100
|
-
if (id.includes('node_modules') && !id.includes('cnhis-design-vue')) {
|
|
101
|
-
return 'vendor';
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
});
|
|
107
|
-
```
|
|
108
|
-
|
|
109
|
-
### 4.2 找不到文件
|
|
110
|
-
|
|
111
|
-
> 由于组件库输出文件类型由 js 修改成了 mjs, 如果配置了 resolve 属性的项目, 需要将 mjs 文件类型添加至 extensions 中
|
|
112
|
-
|
|
113
|
-
```javascript
|
|
114
|
-
// vite.config.ts
|
|
115
|
-
const config = {
|
|
116
|
-
// ...otherOptions
|
|
117
|
-
resolve: {
|
|
118
|
-
// ...otherOptions
|
|
119
|
-
// 如果没有配置, 则不用考虑
|
|
120
|
-
extensions: ['.js', '.ts', '.vue', '.json', '.mjs']
|
|
121
|
-
}
|
|
122
|
-
};
|
|
123
|
-
```
|
|
1
|
+
# 安装
|
|
2
|
+
|
|
3
|
+
```shell
|
|
4
|
+
npm i cnhis-design-vue@[版本号]
|
|
5
|
+
# or
|
|
6
|
+
yarn add cnhis-design-vue@[版本号] #推荐
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## 1.全局引入
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
// main.ts
|
|
13
|
+
import { createApp } from 'vue';
|
|
14
|
+
import App from './App.vue';
|
|
15
|
+
import 'cnhis-design-vue/es/packages/index.css';
|
|
16
|
+
import cui from 'cnhis-design-vue';
|
|
17
|
+
|
|
18
|
+
const app = createApp(App);
|
|
19
|
+
app.use(cui).mount('#app');
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## 2. 按需引入
|
|
23
|
+
|
|
24
|
+
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
|
25
|
+
|
|
26
|
+
### 2.1 样式处理方式 1(按需引入样式)
|
|
27
|
+
|
|
28
|
+
```shell
|
|
29
|
+
# 安装自动导入样式的插件
|
|
30
|
+
npm i -d vite-plugin-style-import
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
// vite.config.ts
|
|
35
|
+
import { defineConfig } from 'vite';
|
|
36
|
+
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
|
37
|
+
|
|
38
|
+
export default defineConfig({
|
|
39
|
+
plugins: [
|
|
40
|
+
// ...otherPlugins
|
|
41
|
+
createStyleImportPlugin({
|
|
42
|
+
libs: [
|
|
43
|
+
{
|
|
44
|
+
libraryName: 'cnhis-design-vue',
|
|
45
|
+
esModule: true,
|
|
46
|
+
ensureStyleFile: true,
|
|
47
|
+
resolveStyle: name => {
|
|
48
|
+
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
]
|
|
52
|
+
})
|
|
53
|
+
]
|
|
54
|
+
});
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
### 2.2 样式处理方式 2(全局引入样式)
|
|
58
|
+
|
|
59
|
+
```typescript
|
|
60
|
+
// main.ts
|
|
61
|
+
import 'cnhis-design-vue/es/components/index.css';
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
## 3. 注意
|
|
65
|
+
|
|
66
|
+
由于 vxe-table 目前的引入方式是由组件 install 触发的,所以如果需要使用 c-grid/c-big-table 组件,需要全局注册二者任意一个
|
|
67
|
+
|
|
68
|
+
```typescript
|
|
69
|
+
// main.ts
|
|
70
|
+
import { createApp } from 'vue';
|
|
71
|
+
import App from './App.vue';
|
|
72
|
+
|
|
73
|
+
import { CGrid } from 'cnhis-design-vue';
|
|
74
|
+
// 或者
|
|
75
|
+
import { CBigTable } from 'cnhis-design-vue';
|
|
76
|
+
|
|
77
|
+
const app = createApp(App);
|
|
78
|
+
app.use(CGrid);
|
|
79
|
+
// 或者
|
|
80
|
+
app.use(CBigTable);
|
|
81
|
+
app.mount('#app');
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
## 4.FAQ
|
|
85
|
+
|
|
86
|
+
### 4.1 项目打包后样式丢失
|
|
87
|
+
|
|
88
|
+
> 处理方法, 将 cnhis-design-vue 从 vendor 包中移除
|
|
89
|
+
|
|
90
|
+
```typescript
|
|
91
|
+
// vite.config.ts
|
|
92
|
+
import { defineConfig } from 'vite';
|
|
93
|
+
|
|
94
|
+
export default defineConfig({
|
|
95
|
+
rollupOptions: {
|
|
96
|
+
// ..otherOptions
|
|
97
|
+
output: {
|
|
98
|
+
dir: './dist',
|
|
99
|
+
manualChunks(id: string) {
|
|
100
|
+
if (id.includes('node_modules') && !id.includes('cnhis-design-vue')) {
|
|
101
|
+
return 'vendor';
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
});
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
### 4.2 找不到文件
|
|
110
|
+
|
|
111
|
+
> 由于组件库输出文件类型由 js 修改成了 mjs, 如果配置了 resolve 属性的项目, 需要将 mjs 文件类型添加至 extensions 中
|
|
112
|
+
|
|
113
|
+
```javascript
|
|
114
|
+
// vite.config.ts
|
|
115
|
+
const config = {
|
|
116
|
+
// ...otherOptions
|
|
117
|
+
resolve: {
|
|
118
|
+
// ...otherOptions
|
|
119
|
+
// 如果没有配置, 则不用考虑
|
|
120
|
+
extensions: ['.js', '.ts', '.vue', '.json', '.mjs']
|
|
121
|
+
}
|
|
122
|
+
};
|
|
123
|
+
```
|
|
@@ -383,8 +383,8 @@ declare const ButtonPrint: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
383
383
|
'--n-feedback-text-color-warning': string;
|
|
384
384
|
'--n-feedback-text-color-error': string;
|
|
385
385
|
}> | undefined;
|
|
386
|
-
themeClass: import("vue").Ref<string
|
|
387
|
-
onRender: (
|
|
386
|
+
themeClass: import("vue").Ref<string>;
|
|
387
|
+
onRender: () => void;
|
|
388
388
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
389
389
|
restoreValidation: () => void;
|
|
390
390
|
path?: string | undefined;
|
|
@@ -408,7 +408,6 @@ declare const ButtonPrint: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
408
408
|
key: string;
|
|
409
409
|
render: () => import("vue").VNodeChild;
|
|
410
410
|
}[]>;
|
|
411
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
412
411
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
413
412
|
readonly label: StringConstructor;
|
|
414
413
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -734,8 +733,8 @@ declare const ButtonPrint: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
734
733
|
'--n-feedback-text-color-warning': string;
|
|
735
734
|
'--n-feedback-text-color-error': string;
|
|
736
735
|
}> | undefined;
|
|
737
|
-
themeClass: import("vue").Ref<string
|
|
738
|
-
onRender: (
|
|
736
|
+
themeClass: import("vue").Ref<string>;
|
|
737
|
+
onRender: () => void;
|
|
739
738
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
740
739
|
restoreValidation: () => void;
|
|
741
740
|
path?: string | undefined;
|
|
@@ -759,7 +758,6 @@ declare const ButtonPrint: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
759
758
|
key: string;
|
|
760
759
|
render: () => import("vue").VNodeChild;
|
|
761
760
|
}[]>;
|
|
762
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
763
761
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
764
762
|
readonly label: StringConstructor;
|
|
765
763
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -387,8 +387,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
387
387
|
'--n-feedback-text-color-warning': string;
|
|
388
388
|
'--n-feedback-text-color-error': string;
|
|
389
389
|
}> | undefined;
|
|
390
|
-
themeClass: import("vue").Ref<string
|
|
391
|
-
onRender: (
|
|
390
|
+
themeClass: import("vue").Ref<string>;
|
|
391
|
+
onRender: () => void;
|
|
392
392
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
393
393
|
restoreValidation: () => void;
|
|
394
394
|
path?: string | undefined;
|
|
@@ -412,7 +412,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
412
412
|
key: string;
|
|
413
413
|
render: () => import("vue").VNodeChild;
|
|
414
414
|
}[]>;
|
|
415
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
416
415
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
417
416
|
readonly label: StringConstructor;
|
|
418
417
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -738,8 +737,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
738
737
|
'--n-feedback-text-color-warning': string;
|
|
739
738
|
'--n-feedback-text-color-error': string;
|
|
740
739
|
}> | undefined;
|
|
741
|
-
themeClass: import("vue").Ref<string
|
|
742
|
-
onRender: (
|
|
740
|
+
themeClass: import("vue").Ref<string>;
|
|
741
|
+
onRender: () => void;
|
|
743
742
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
744
743
|
restoreValidation: () => void;
|
|
745
744
|
path?: string | undefined;
|
|
@@ -763,7 +762,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
763
762
|
key: string;
|
|
764
763
|
render: () => import("vue").VNodeChild;
|
|
765
764
|
}[]>;
|
|
766
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
767
765
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
768
766
|
readonly label: StringConstructor;
|
|
769
767
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -195,8 +195,8 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
195
195
|
'--n-feedback-text-color-warning': string;
|
|
196
196
|
'--n-feedback-text-color-error': string;
|
|
197
197
|
}> | undefined;
|
|
198
|
-
themeClass: import("vue").Ref<string
|
|
199
|
-
onRender: (
|
|
198
|
+
themeClass: import("vue").Ref<string>;
|
|
199
|
+
onRender: () => void;
|
|
200
200
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
201
201
|
restoreValidation: () => void;
|
|
202
202
|
path?: string | undefined;
|
|
@@ -220,7 +220,6 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
220
220
|
key: string;
|
|
221
221
|
render: () => import("vue").VNodeChild;
|
|
222
222
|
}[]>;
|
|
223
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
224
223
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
225
224
|
readonly label: StringConstructor;
|
|
226
225
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -202,8 +202,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
202
202
|
'--n-feedback-text-color-warning': string;
|
|
203
203
|
'--n-feedback-text-color-error': string;
|
|
204
204
|
}> | undefined;
|
|
205
|
-
themeClass: import("vue").Ref<string
|
|
206
|
-
onRender: (
|
|
205
|
+
themeClass: import("vue").Ref<string>;
|
|
206
|
+
onRender: () => void;
|
|
207
207
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
208
208
|
restoreValidation: () => void;
|
|
209
209
|
path?: string | undefined;
|
|
@@ -227,7 +227,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
227
227
|
key: string;
|
|
228
228
|
render: () => import("vue").VNodeChild;
|
|
229
229
|
}[]>;
|
|
230
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
231
230
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
232
231
|
readonly label: StringConstructor;
|
|
233
232
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -553,8 +552,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
553
552
|
'--n-feedback-text-color-warning': string;
|
|
554
553
|
'--n-feedback-text-color-error': string;
|
|
555
554
|
}> | undefined;
|
|
556
|
-
themeClass: import("vue").Ref<string
|
|
557
|
-
onRender: (
|
|
555
|
+
themeClass: import("vue").Ref<string>;
|
|
556
|
+
onRender: () => void;
|
|
558
557
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
559
558
|
restoreValidation: () => void;
|
|
560
559
|
path?: string | undefined;
|
|
@@ -578,7 +577,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
578
577
|
key: string;
|
|
579
578
|
render: () => import("vue").VNodeChild;
|
|
580
579
|
}[]>;
|
|
581
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
582
580
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
583
581
|
readonly label: StringConstructor;
|
|
584
582
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -4,7 +4,7 @@ declare const Keyboard: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
4
4
|
type: import("vue").PropType<"day" | "dose" | "english">;
|
|
5
5
|
default: string;
|
|
6
6
|
};
|
|
7
|
-
|
|
7
|
+
drag: {
|
|
8
8
|
type: BooleanConstructor;
|
|
9
9
|
default: boolean;
|
|
10
10
|
};
|
|
@@ -35,7 +35,7 @@ declare const Keyboard: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
35
35
|
type: import("vue").PropType<"day" | "dose" | "english">;
|
|
36
36
|
default: string;
|
|
37
37
|
};
|
|
38
|
-
|
|
38
|
+
drag: {
|
|
39
39
|
type: BooleanConstructor;
|
|
40
40
|
default: boolean;
|
|
41
41
|
};
|
|
@@ -198,7 +198,7 @@ declare const Keyboard: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
198
198
|
type: import("vue").PropType<"day" | "dose" | "english">;
|
|
199
199
|
default: string;
|
|
200
200
|
};
|
|
201
|
-
|
|
201
|
+
drag: {
|
|
202
202
|
type: BooleanConstructor;
|
|
203
203
|
default: boolean;
|
|
204
204
|
};
|
|
@@ -223,8 +223,8 @@ declare const Keyboard: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
223
223
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
224
224
|
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
225
225
|
}, {
|
|
226
|
+
drag: boolean;
|
|
226
227
|
mode: "day" | "dose" | "english";
|
|
227
|
-
dragable: boolean;
|
|
228
228
|
positionInitialValue: {
|
|
229
229
|
x: number;
|
|
230
230
|
y: number;
|
|
@@ -12,7 +12,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
12
12
|
__name: "Keyboard",
|
|
13
13
|
props: {
|
|
14
14
|
mode: { type: String, default: "english" },
|
|
15
|
-
|
|
15
|
+
drag: { type: Boolean, default: false },
|
|
16
16
|
positionInitialValue: { type: Object, default: () => ({ x: 0, y: 0 }) },
|
|
17
17
|
defaultValue: { type: Number },
|
|
18
18
|
panel: { type: Boolean, default: true }
|
|
@@ -38,7 +38,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
38
38
|
if (props.defaultValue) {
|
|
39
39
|
currentValue.value = props.defaultValue;
|
|
40
40
|
}
|
|
41
|
-
if (isDefault.value && props.
|
|
41
|
+
if (isDefault.value && props.drag) {
|
|
42
42
|
const { x, y, style: style2 } = useDraggable(englishKeyboardRef, {
|
|
43
43
|
initialValue: props.positionInitialValue,
|
|
44
44
|
preventDefault: true,
|
|
@@ -93,7 +93,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
93
93
|
onChange: onchange
|
|
94
94
|
}, null, 8, ["mode", "defaultValue"])) : (openBlock(), createElementBlock("div", {
|
|
95
95
|
key: 2,
|
|
96
|
-
class: normalizeClass(["c-keyboard-english", { isFixed: __props.
|
|
96
|
+
class: normalizeClass(["c-keyboard-english", { isFixed: __props.drag }]),
|
|
97
97
|
ref_key: "englishKeyboardRef",
|
|
98
98
|
ref: englishKeyboardRef,
|
|
99
99
|
style: normalizeStyle(unref(style))
|
|
@@ -104,7 +104,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
104
104
|
justify: "space-between",
|
|
105
105
|
ref_key: "keyboardDragRef",
|
|
106
106
|
ref: keyboardDragRef,
|
|
107
|
-
style: normalizeStyle({ cursor: __props.
|
|
107
|
+
style: normalizeStyle({ cursor: __props.drag ? "move" : "default" })
|
|
108
108
|
}, {
|
|
109
109
|
default: withCtx(() => [
|
|
110
110
|
_hoisted_1,
|
|
@@ -8,7 +8,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
8
8
|
type: PropType<"day" | "dose" | "english">;
|
|
9
9
|
default: string;
|
|
10
10
|
};
|
|
11
|
-
|
|
11
|
+
drag: {
|
|
12
12
|
type: BooleanConstructor;
|
|
13
13
|
default: boolean;
|
|
14
14
|
};
|
|
@@ -36,7 +36,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
36
36
|
type: PropType<"day" | "dose" | "english">;
|
|
37
37
|
default: string;
|
|
38
38
|
};
|
|
39
|
-
|
|
39
|
+
drag: {
|
|
40
40
|
type: BooleanConstructor;
|
|
41
41
|
default: boolean;
|
|
42
42
|
};
|
|
@@ -196,7 +196,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
196
196
|
type: PropType<"day" | "dose" | "english">;
|
|
197
197
|
default: string;
|
|
198
198
|
};
|
|
199
|
-
|
|
199
|
+
drag: {
|
|
200
200
|
type: BooleanConstructor;
|
|
201
201
|
default: boolean;
|
|
202
202
|
};
|
|
@@ -218,8 +218,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
218
218
|
onChange?: ((...args: any[]) => any) | undefined;
|
|
219
219
|
onKeydown?: ((...args: any[]) => any) | undefined;
|
|
220
220
|
}, {
|
|
221
|
+
drag: boolean;
|
|
221
222
|
mode: "day" | "dose" | "english";
|
|
222
|
-
dragable: boolean;
|
|
223
223
|
positionInitialValue: IPointer;
|
|
224
224
|
panel: boolean;
|
|
225
225
|
}>;
|
|
@@ -923,8 +923,8 @@ declare const CScaleView: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
923
923
|
'--n-feedback-text-color-warning': string;
|
|
924
924
|
'--n-feedback-text-color-error': string;
|
|
925
925
|
}> | undefined;
|
|
926
|
-
themeClass: import("vue").Ref<string
|
|
927
|
-
onRender: (
|
|
926
|
+
themeClass: import("vue").Ref<string>;
|
|
927
|
+
onRender: () => void;
|
|
928
928
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
929
929
|
restoreValidation: () => void;
|
|
930
930
|
path?: string | undefined;
|
|
@@ -948,7 +948,6 @@ declare const CScaleView: SFCWithInstall<import("vue").DefineComponent<{
|
|
|
948
948
|
key: string;
|
|
949
949
|
render: () => import("vue").VNodeChild;
|
|
950
950
|
}[]>;
|
|
951
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
952
951
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
953
952
|
readonly label: StringConstructor;
|
|
954
953
|
readonly labelWidth: import("vue").PropType<string | number>;
|
|
@@ -922,8 +922,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
922
922
|
'--n-feedback-text-color-warning': string;
|
|
923
923
|
'--n-feedback-text-color-error': string;
|
|
924
924
|
}> | undefined;
|
|
925
|
-
themeClass: import("vue").Ref<string
|
|
926
|
-
onRender: (
|
|
925
|
+
themeClass: import("vue").Ref<string>;
|
|
926
|
+
onRender: () => void;
|
|
927
927
|
validate: import("naive-ui/es/form/src/interface").FormItemValidate;
|
|
928
928
|
restoreValidation: () => void;
|
|
929
929
|
path?: string | undefined;
|
|
@@ -947,7 +947,6 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
947
947
|
key: string;
|
|
948
948
|
render: () => import("vue").VNodeChild;
|
|
949
949
|
}[]>;
|
|
950
|
-
reverseColSpace: import("vue").ComputedRef<boolean>;
|
|
951
950
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
952
951
|
readonly label: StringConstructor;
|
|
953
952
|
readonly labelWidth: import("vue").PropType<string | number>;
|