@neatui/vue 3.1.0 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/README.md +1 -10
  2. package/package.json +5 -2
  3. package/rollup.config.js +42 -2
  4. package/src/components/basic/IDraggable@b.vue +1 -1
  5. package/src/components/basic/IFollowView.vue +2 -2
  6. package/src/components/basic/LayerView/Layer.vue +193 -42
  7. package/src/components/display/Calendar.vue +6 -6
  8. package/src/components/display/CalendarReg.vue +6 -6
  9. package/src/components/display/PhotoEditor.vue +2 -2
  10. package/src/components/display/TreeView.vue +4 -3
  11. package/src/components/form/Cascader.vue +3 -3
  12. package/src/components/form/DatePicker.vue +2 -2
  13. package/src/components/form/{DateRangePicker@v3.vue → DateRangePicker.vue} +2 -1
  14. package/src/components/form/{DateRangeView@v3.vue → DateRangeView.vue} +11 -11
  15. package/src/components/form/DateView.vue +461 -82
  16. package/src/components/form/ImgUpload.vue +3 -3
  17. package/src/components/form/{MoreSelect@v3.vue → MoreSelect.vue} +1 -1
  18. package/src/components/form/MoreSelectList.vue +1 -1
  19. package/src/components/form/{MoreSelectPanel@v3.vue → MoreSelectPanel.vue} +1 -1
  20. package/src/components/form/MoreSelectPicker.vue +3 -3
  21. package/src/components/form/MoreSelectTags.vue +1 -1
  22. package/src/components/form/PageMoreSelect.vue +1 -1
  23. package/src/components/form/PageSelect.vue +1 -1
  24. package/src/components/form/SearchMoreSelect.vue +1 -1
  25. package/src/components/form/{SearchSelect@v3.vue → SearchSelect.vue} +1 -1
  26. package/src/components/form/{Select@v3.vue → Select.vue} +1 -1
  27. package/src/components/form/SelectList.vue +1 -1
  28. package/src/components/form/SelectPicker.vue +3 -3
  29. package/src/components/form/SelectTree/{SelectTree@v1.vue → SelectTree.vue} +1 -1
  30. package/src/components/form/Switch.vue +2 -1
  31. package/src/components/form/TimeView.vue +6 -6
  32. package/src/components/form/Upload.vue +22 -11
  33. package/src/components/form/index.ts +8 -8
  34. package/src/components/loader/FormLoader/FormLoader.vue +124 -103
  35. package/src/components/loader/LayerLoader/LayerLoader.vue +6 -7
  36. package/src/components/loader/LimitLoader/{LimitLoader@v3.vue → LimitLoader.vue} +4 -4
  37. package/src/components/loader/LimitLoader/index.ts +1 -1
  38. package/src/components/loader/TableLoader/TableLoader.vue +7 -7
  39. package/src/components/loader/TableLoader/TableRender.vue +0 -1
  40. package/src/components/loader/ViewLoader/{ViewLoader@v1.vue → ViewLoader.vue} +124 -103
  41. package/src/components/loader/ViewLoader/index.ts +1 -1
  42. package/src/components/tools/FormDraftsView.vue +4 -4
  43. package/src/components/tools/FormVerifyView.vue +2 -2
  44. package/src/components/tools/MoreTools.vue +5 -5
  45. package/src/components/tools/Pagination@a.vue +4 -4
  46. package/src/components/tools/Pagination@b.vue +4 -4
  47. package/tsconfig.json +1 -2
  48. package/src/components/form/DateView@v2.vue +0 -386
  49. package/src/components/form/DateView@v3.vue +0 -608
  50. package/src/components/tools/MoreTools@v2.vue +0 -74
  51. /package/src/components/form/{Input@v3.vue → Input.vue} +0 -0
  52. /package/src/components/form/{TextArea.vue → Textarea.vue} +0 -0
@@ -24,21 +24,21 @@
24
24
  <slot name="suffix" :item="item" :path="paths(idx)"></slot>
25
25
  </div>
26
26
  <slot name="tools" :data="data" :item="item" :path="paths(idx)">
27
- <div ui-flex="row rm" class="layer-loader-tool parent-hover:show fs-xs" :data-model="item.model">
27
+ <div ui-flex="row rm" class="layer-loader-tool parent-hover:show fs-ss" :data-model="item.model">
28
28
  <div ui-tips="@a co:well ux:hover">
29
29
  <button ui-btn="@a none s :square">
30
30
  <i class="icon icon-add"></i>
31
31
  </button>
32
32
  <div ui-tips-box="bl">
33
- <div class="n-sm nowrap fs-ss">
33
+ <div class="n-sm nowrap fs-sm">
34
34
  <ul class="nx-sm-sub ny-ss-sub">
35
35
  <li class="r-sm ux-hover" @click="fAddArea(item, data, path, idx)">用容器包裹</li>
36
- <li class="b-solid bk-line bb-xs n-no my-ss" v-if="isBoxNode(item.model)"></li>
36
+ <li class="b-solid b-line bb-xs n-no my-ss" v-if="isBoxNode(item.model)"></li>
37
37
  <li class="r-sm ux-hover" v-if="isBoxNode(item.model)" @click="fAddNode(item, data, path, idx)">添加到内部</li>
38
- <li class="b-solid bk-line bb-xs n-no my-ss"></li>
38
+ <li class="b-solid b-line bb-xs n-no my-ss"></li>
39
39
  <li class="r-sm ux-hover" @click="fAddNode(item, data, path, idx, 'prev')">添加到前面</li>
40
40
  <li class="r-sm ux-hover" @click="fAddNode(item, data, path, idx, 'next')">添加到后面</li>
41
- <li class="b-solid bk-line bb-xs n-no my-ss"></li>
41
+ <li class="b-solid b-line bb-xs n-no my-ss"></li>
42
42
  <li class="r-sm ux-hover" @click="fAddNode(item, data, path, idx, 'prev', 1)">复制到前面</li>
43
43
  <li class="r-sm ux-hover" @click="fAddNode(item, data, path, idx, 'next', 1)">复制到后面</li>
44
44
  </ul>
@@ -47,7 +47,7 @@
47
47
  </div>
48
48
  <button ui-btn="@a none s :square" @click="fDelNode(item, data, idx)"><i class="icon icon-delete"></i></button>
49
49
  </div>
50
- <button ui-btn="@a none s :square" class="layer-loader-tool fs-xs" :class="item?.attrs?.hide ? '' : 'parent-hover:show'" @click="fhideNode(item)">
50
+ <button ui-btn="@a none s :square" class="layer-loader-tool fs-ss" :class="item?.attrs?.hide ? '' : 'parent-hover:show'" @click="fhideNode(item)">
51
51
  <i class="icon" :class="item?.attrs?.hide ? 'icon-hide' : 'icon-view'"></i>
52
52
  </button>
53
53
  </slot>
@@ -74,7 +74,6 @@
74
74
  </template>
75
75
  <script setup lang="ts">
76
76
  import { nextTick, reactive, ref, watch, onMounted } from 'vue';
77
- import LayerLoader from './LayerLoader.vue';
78
77
  import { useBasicStore, useWorksStore, storeToRefs } from '@/stores';
79
78
  import { deepcopy, env } from '@fekit/utils';
80
79
  import scrollto from '@fekit/scrollto';
@@ -25,14 +25,14 @@
25
25
  <div class="flex-fixed mr-sl-sub my-sm-sub nowrap" ui-flex="row rm" ui-hide="<pad">
26
26
  <IFollowView v-if="tools" tipBoxClass="nr-no">
27
27
  <button class="bg-fore" ui-btn="@a s case :border :square">
28
- <svg viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" class="co-read fs-ss" style="width: 1em; height: 1em">
28
+ <svg viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" class="co-read fs-sm" style="width: 1em; height: 1em">
29
29
  <path
30
30
  d="M372 981.6c-80 0-154.4-43.2-195.2-112L35.2 624.8c-40-68.8-40-155.2 0-224.8l141.6-244.8c40-69.6 115.2-112 195.2-112h282.4c80 0 154.4 43.2 195.2 112L991.2 400c40 68.8 40 155.2 0 224.8l-141.6 244.8c-40 69.6-115.2 112-195.2 112H372z m0-825.6c-39.2 0-76.8 21.6-96.8 56L134.4 456c-20 34.4-20 76.8 0 112l140.8 244.8c20 34.4 56.8 55.2 96.8 55.2h282.4c39.2 0 76.8-21.6 96.8-56l140.8-244.8c20-34.4 20-76.8 0-112L751.2 211.2c-20-34.4-56.8-55.2-96.8-55.2H372z m140.8 552.8c-108.8 0-196.8-88-196.8-196.8 0-108.8 88-196.8 196.8-196.8 108.8 0 196.8 88 196.8 196.8 0.8 108.8-88 196.8-196.8 196.8z m0-280c-45.6 0-83.2 37.6-83.2 83.2s37.6 83.2 83.2 83.2c22.4 0 43.2-8.8 59.2-24 16-16 24-36.8 24-59.2 0-45.6-37.6-83.2-83.2-83.2z"
31
31
  />
32
32
  </svg>
33
33
  </button>
34
34
  <template v-if="state.limit.length" #tips>
35
- <div class="w-mm max-h-ls n-sl" ui-scroll="x:hidden :y">
35
+ <div class="w-ml*s max-h-xl*s n-sl" ui-scroll="x:hidden :y">
36
36
  <div v-for="(item, idx) in state.limit" :key="idx" class="item ux-hover nowrap r-ss">
37
37
  <label class="ny-xs nx-sm" ui-form="@a type:checkbox">
38
38
  <input :checked="!item._close" type="checkbox" @change="item._close = item._close ? 0 : 1" />
@@ -134,10 +134,10 @@
134
134
  // 属性处理
135
135
  if (item.model[1].class) {
136
136
  if (!/\bw-[sml]+/.test(item.model[1].class || '')) {
137
- item.model[1].class += ' w-ms+';
137
+ item.model[1].class += ' w-mm*s';
138
138
  }
139
139
  } else {
140
- item.model[1].class = 'w-ms+';
140
+ item.model[1].class = 'w-mm*s';
141
141
  }
142
142
 
143
143
  return item;
@@ -1,2 +1,2 @@
1
- import FormLoader from './LimitLoader@v3.vue';
1
+ import FormLoader from './LimitLoader.vue';
2
2
  export default FormLoader;
@@ -22,7 +22,7 @@
22
22
  <Icon name="tableloader-setting" class="co-read"></Icon>
23
23
  </button>
24
24
  <template #tips>
25
- <div class="w-mm h-ml+ n-sl" ui-scroll="x:hidden :y">
25
+ <div class="w-ml*s h-ll*s n-sl" ui-scroll="x:hidden :y">
26
26
  <IDraggable v-model:lists="state.table">
27
27
  <template #default="{ item: element, idx: index }">
28
28
  <div :class="`item ux-hover nowrap r-ss ${element.fixed ? 'forbid' : 'element'}`" :key="index">
@@ -43,15 +43,15 @@
43
43
  </slot>
44
44
  </th>
45
45
  </template>
46
- <th v-if="slots.operate" col-fixed="r" class="fs-ss nowrap ar">
46
+ <th v-if="slots.operate" col-fixed="r" class="fs-sm nowrap ar">
47
47
  <div ui-flex="row rm">
48
48
  <span>{{ words['operate'] || '操作' }}</span>
49
49
  <IFollowView v-if="tools" class="lh-xs" tipBoxClass="n-no">
50
50
  <button :ui-btn="`@a none xs :square`">
51
- <Icon name="tableloader-setting" class="co-auto o-ls fs-xs"></Icon>
51
+ <Icon name="tableloader-setting" class="co-auto o-ls fs-ss"></Icon>
52
52
  </button>
53
53
  <template #tips>
54
- <div class="w-mm h-ml+ n-sl" ui-scroll="x:hidden :y">
54
+ <div class="w-ml*s h-ll*s n-sl" ui-scroll="x:hidden :y">
55
55
  <IDraggable v-model:lists="state.table">
56
56
  <template #default="{ item: element, idx: index }">
57
57
  <div :class="`item ux-hover nowrap r-ss ${element.fixed ? 'forbid' : 'element'}`" :key="index">
@@ -139,7 +139,7 @@
139
139
  </div>
140
140
  <div v-if="!lists.length" class="ny-ls o-mm" ui-flex="col cm">
141
141
  <div class="ac">
142
- <p><i class="icon icon-nodata fs-lm lh-ss"></i></p>
142
+ <p><i class="icon icon-nodata fs-sm*s lh-ss"></i></p>
143
143
  <p>{{ words['common.nodata'] || '暂无记录' }}</p>
144
144
  </div>
145
145
  </div>
@@ -279,9 +279,9 @@
279
279
  if (!col.thead.class.some((c: any) => c === 'wrap' || c === 'nowrap')) {
280
280
  col.thead.class.push('nowrap');
281
281
  }
282
- // 如果没有以 fs- 开头的类,就加 fs-ss
282
+ // 如果没有以 fs- 开头的类,就加 fs-sm
283
283
  if (!col.thead.class.some((c: string) => /^fs-/.test(c))) {
284
- col.thead.class.push('fs-ss');
284
+ col.thead.class.push('fs-sm');
285
285
  }
286
286
 
287
287
  // 缓存的显示信息
@@ -30,7 +30,6 @@
30
30
  import { computed, onMounted, reactive, ref } from 'vue';
31
31
  import { isFunction, isArray, isObject, isString, findEnumName } from '@fekit/utils';
32
32
  import { useRoute, useRouter } from 'vue-router';
33
- import TableRender from './TableRender.vue';
34
33
  import { IFollowView } from '../../basic';
35
34
 
36
35
  const route = useRoute();
@@ -109,123 +109,146 @@
109
109
  _lw: 6
110
110
  });
111
111
 
112
- // 监听结构
113
- const unwatchs: any = [];
114
- watch(
115
- [() => props.form, () => props.data, () => props.idx],
116
- ([form = []]) => {
117
- const wkeys: any = {};
118
- const onces: any = [];
119
- state.form = deepcopy(form)?.map((item: any = {}, idx: number) => {
120
- // 计算Label宽度
121
- const _w = clw(item.label) + 2;
122
- if (_w > state._lw) {
123
- state._lw = _w;
124
- }
112
+ // 结构变化时重建字段监听;普通字段变化只触发对应的联动任务
113
+ const unwatchs: Array<() => void> = [];
114
+ let fieldWatcherGeneration = 0;
115
+ const clearFieldWatchers = () => {
116
+ fieldWatcherGeneration += 1;
117
+ unwatchs.splice(0).forEach((unwatch) => {
118
+ unwatch();
119
+ });
120
+ return fieldWatcherGeneration;
121
+ };
122
+ const rebuildFieldWatchers = (form: any = []) => {
123
+ const generation = clearFieldWatchers();
124
+ const watched: any[] = [];
125
+ const onces: any[] = [];
126
+ const taskRuns = new Map<any, number>();
127
+ state.form = deepcopy(form)?.map((item: any = {}, idx: number) => {
128
+ // 计算Label宽度
129
+ const _w = clw(item.label) + 2;
130
+ if (_w > state._lw) {
131
+ state._lw = _w;
132
+ }
125
133
 
126
- if (isObject(item)) {
127
- for (const key in item) {
128
- let val = item[key] || {};
129
- // 处理函数
130
- if (isFunction(val)) {
131
- val = val(deepcopy(props.data), props.form, route, router);
132
- if (isObject(val)) {
133
- if (!isFunction(val.setup)) {
134
- val.setup = item[key];
135
- }
136
- if (!isArray(val.watch)) {
137
- val.watch = deepcopy(form).map(({ field = '' }: any = {}) => field);
138
- }
139
- } else {
140
- val = { value: val, setup: item[key], watch: deepcopy(form).map(({ field = '' }: any = {}) => field) };
141
- }
142
- }
143
- // 对象处理
134
+ if (isObject(item)) {
135
+ for (const key in item) {
136
+ let val = item[key] || {};
137
+ let hasInitialResult = false;
138
+ let initialResult: any;
139
+ // 处理函数
140
+ if (isFunction(val)) {
141
+ const setup = val;
142
+ val = setup(deepcopy(props.data), props.form, route, router);
144
143
  if (isObject(val)) {
145
- const { value = null, setup = () => {}, watch: _watch = [] } = val || {};
146
- // 监听字段为空
147
- if (_watch.length) {
148
- _watch?.forEach((k: any) => {
149
- if (wkeys[k]) {
150
- wkeys[k].push({ idx, key, value, setup });
151
- } else {
152
- wkeys[k] = [{ idx, key, value, setup }];
153
- }
154
- });
155
- } else {
156
- onces.push({ idx, key, value, setup });
144
+ if (!isFunction(val.setup)) {
145
+ val.setup = setup;
146
+ }
147
+ if (!isArray(val.watch)) {
148
+ val.watch = deepcopy(form).map(({ field = '' }: any = {}) => field);
157
149
  }
158
- item[key] = value;
159
150
  } else {
160
- item[key] = val;
151
+ hasInitialResult = true;
152
+ initialResult = val;
153
+ val = { value: val, setup, watch: deepcopy(form).map(({ field = '' }: any = {}) => field) };
161
154
  }
162
155
  }
163
- }
164
-
165
- // 模型处理
166
- if (item.model) {
167
- if (isString(item.model)) {
168
- item.model = [item.model, { verify: false }];
156
+ // 对象处理
157
+ if (isObject(val)) {
158
+ const { value = null, setup = () => {}, watch: _watch = [] } = val || {};
159
+ const task = { idx, key, value, setup, watch: _watch, hasInitialResult, initialResult };
160
+ // 监听字段为空
161
+ if (_watch.length) {
162
+ watched.push(task);
163
+ } else {
164
+ onces.push(task);
165
+ }
166
+ item[key] = value;
167
+ } else {
168
+ item[key] = val;
169
169
  }
170
- } else {
171
- item.model = ['', { verify: false }];
172
170
  }
173
- if (item.model[1] && !Object.prototype.hasOwnProperty.call(item.model[1], 'verify')) {
174
- item.model[1].verify = false;
171
+ }
172
+
173
+ // 模型处理
174
+ if (item.model) {
175
+ if (isString(item.model)) {
176
+ item.model = [item.model, { verify: false }];
175
177
  }
178
+ } else {
179
+ item.model = ['', { verify: false }];
180
+ }
181
+ if (item.model[1] && !Object.prototype.hasOwnProperty.call(item.model[1], 'verify')) {
182
+ item.model[1].verify = false;
183
+ }
176
184
 
177
- // 添加ID
178
- item._fid = `form-${props.idx !== '' ? props.idx + '-' : ''}field-${item.field}`;
185
+ // 添加ID
186
+ item._fid = `form-${props.idx !== '' ? props.idx + '-' : ''}field-${item.field}`;
179
187
 
180
- // 数据路径处理
181
- item._data = props.data;
182
- (item.paths?.split('.') || [])?.forEach((i: any) => {
183
- if (item._data[i]) {
184
- item._data = item._data[i];
185
- }
186
- });
187
- return item;
188
- });
189
- const runsetup = (item: any = {}) => {
190
- const { idx = null, key = null, value = null, setup = null }: any = item || {};
191
- if (state.form[idx] && isFunction(setup)) {
192
- const v = setup(deepcopy(props.data), state.form[idx], route, router);
193
- nextTick(() => {
194
- if (v instanceof Promise) {
195
- state.form[idx][key] = value;
196
- v.then((res: any) => {
197
- state.form[idx][key] = res;
198
- });
199
- } else {
200
- state.form[idx][key] = v;
201
- }
202
- });
188
+ // 数据路径处理
189
+ item._data = props.data;
190
+ (item.paths?.split('.') || [])?.forEach((i: any) => {
191
+ if (item._data[i]) {
192
+ item._data = item._data[i];
203
193
  }
204
- };
205
- // 执行一次
206
- onces?.forEach((item: any = {}) => {
207
- runsetup(item);
208
194
  });
209
- // 监听列表
210
- for (const key in wkeys) {
211
- unwatchs.push(
212
- watch(
213
- () => props.data[key],
214
- () => {
215
- wkeys[key]?.forEach((item: any = {}) => {
216
- runsetup(item);
217
- });
218
- },
219
- {
220
- deep: true,
221
- immediate: true
222
- }
223
- )
224
- );
195
+ return item;
196
+ });
197
+ const runsetup = (item: any = {}) => {
198
+ if (generation !== fieldWatcherGeneration) return;
199
+ const { idx = null, key = null, value = null, setup = null }: any = item || {};
200
+ const target = state.form[idx];
201
+ if (target && isFunction(setup)) {
202
+ const runId = (taskRuns.get(item) || 0) + 1;
203
+ taskRuns.set(item, runId);
204
+ const v = item.hasInitialResult ? item.initialResult : setup(deepcopy(props.data), target, route, router);
205
+ item.hasInitialResult = false;
206
+ const isCurrent = () => generation === fieldWatcherGeneration && state.form[idx] === target && taskRuns.get(item) === runId;
207
+ nextTick(() => {
208
+ if (!isCurrent()) return;
209
+ if (v instanceof Promise) {
210
+ target[key] = value;
211
+ v.then((res: any) => {
212
+ if (isCurrent()) {
213
+ target[key] = res;
214
+ }
215
+ });
216
+ } else {
217
+ target[key] = v;
218
+ }
219
+ });
225
220
  }
221
+ };
222
+ // 不声明 watch 的任务只执行一次
223
+ onces.forEach((item: any = {}) => {
224
+ runsetup(item);
225
+ });
226
+ // 每个动态属性只建立一个 watcher,多个依赖在同一轮变化时只执行一次
227
+ watched.forEach((item: any = {}) => {
228
+ unwatchs.push(
229
+ watch(
230
+ () => item.watch.map((key: any) => props.data[key]),
231
+ () => {
232
+ runsetup(item);
233
+ },
234
+ { deep: true, immediate: true }
235
+ )
236
+ );
237
+ });
238
+ };
239
+ watch(
240
+ () => props.form,
241
+ (form = []) => {
242
+ rebuildFieldWatchers(form);
226
243
  },
227
244
  { deep: true, immediate: true }
228
245
  );
246
+ watch(
247
+ [() => props.data, () => props.idx],
248
+ () => {
249
+ rebuildFieldWatchers(props.form);
250
+ }
251
+ );
229
252
 
230
253
  // 处理
231
254
  watch(
@@ -249,8 +272,6 @@
249
272
  );
250
273
 
251
274
  onBeforeUnmount(() => {
252
- unwatchs?.forEach((unwatch: any) => {
253
- unwatch();
254
- });
275
+ clearFieldWatchers();
255
276
  });
256
277
  </script>
@@ -1,2 +1,2 @@
1
- import ViewLoader from './ViewLoader@v1.vue';
1
+ import ViewLoader from './ViewLoader.vue';
2
2
  export default ViewLoader;
@@ -5,8 +5,8 @@
5
5
  ><sup v-if="state.len" class="sup">{{ state.len }}</sup></i
6
6
  >
7
7
  </button>
8
- <div ui-tips-box="tl" class="w-xl mob:w-lln-ms" :ux-view="state.show">
9
- <div class="fekit-layer-close" ui-flex="row cm" @click="state.show = 0"><i class="icon icon-close fs-xs"></i></div>
8
+ <div ui-tips-box="tl" class="w-sm*m mob:w-ss*m n-ms" :ux-view="state.show">
9
+ <div class="fekit-layer-close" ui-flex="row cm" @click="state.show = 0"><i class="icon icon-close fs-ss"></i></div>
10
10
  <h4>温馨提示</h4>
11
11
  <p class="ny-sm" v-if="state.len">本条记录有未保存的草稿,是否使用草稿?</p>
12
12
  <p class="ny-sm" v-else>当前没有未保存的草稿哦~</p>
@@ -14,9 +14,9 @@
14
14
  <span v-if="state.detail" class="ux-click co-link" @click="state.detail = 0">隐藏详情<i class="icon icon-dropdown r180"></i></span>
15
15
  <span v-else class="ux-click co-link" @click="state.detail = 1">显示详情<i class="icon icon-dropdown"></i></span>
16
16
  </p>
17
- <ul v-if="state.detail" class="mb-sl fs-ss" ui-scroll=":y" style="max-height: 20rem">
17
+ <ul v-if="state.detail" class="mb-sl fs-sm" ui-scroll=":y" style="max-height: 20rem">
18
18
  <template v-for="(item, idx) in state.diffs" :key="idx">
19
- <li v-if="item.label" ui-flex="row lm" class="bb-xs bk-line b-solid ny-ss">
19
+ <li v-if="item.label" ui-flex="row lm" class="bb-xs b-line b-solid ny-ss">
20
20
  <span class="nx-ss r-sm mr-sm ux-hover nowrap" @click="fScrollToField(item.domId)">[{{ item.label }}]</span>
21
21
  <span v-if="item.lhsLabel" class="nx-ss r-sm ux-hover" ui-flex="row lm" @click="fDiscardDrafts(item)">
22
22
  <i class="icon icon-cloud co-well o-mm mr-xs"></i>
@@ -5,8 +5,8 @@
5
5
  <i v-else class="icon icon-verify-ok co-well"></i>
6
6
  <span v-if="verify?.length">{{ verify?.length }}</span>
7
7
  </button>
8
- <div ui-tips-box="tl" :ux-view="state.show" class="w-xl mob:w-ll n-ms">
9
- <div class="fekit-layer-close" ui-flex="row cm" @click="state.show = 0"><i class="icon icon-close fs-xs"></i></div>
8
+ <div ui-tips-box="tl" :ux-view="state.show" class="w-sm*m mob:w-ss*m n-ms">
9
+ <div class="fekit-layer-close" ui-flex="row cm" @click="state.show = 0"><i class="icon icon-close fs-ss"></i></div>
10
10
  <h4>温馨提示</h4>
11
11
  <p v-if="verify?.length" class="ny-sm">本条记录疑似有{{ verify?.length }}个错误,您再检查一遍吧~</p>
12
12
  <p v-else class="nb-sm">好棒哦,没有发现任何错误!</p>
@@ -5,16 +5,16 @@
5
5
  <slot name="prefix"></slot>
6
6
  <slot>
7
7
  <div>
8
- <h6 class="fs-xs o-mm nowrap">每页显示数量</h6>
8
+ <h6 class="fs-ss o-mm nowrap">每页显示数量</h6>
9
9
  <div ui-btns="@a line s :group :border">
10
- <button @click="setLinkMode(0)"><code :class="`${state.tools.confs.linkMode === 0 ? 'co-main' : ''}`">跳转</code></button>
11
- <button @click="setLinkMode(1)"><code :class="`${state.tools.confs.linkMode === 1 ? 'co-main' : ''}`">预览</code></button>
12
- <button @click="setLinkMode(2)"><code :class="`${state.tools.confs.linkMode === 2 ? 'co-main' : ''}`">新窗口</code></button>
10
+ <button @click="setLinkMode('default')"><code :class="`${state.tools.confs.linkMode === 'default' ? 'co-main' : ''}`">跳转</code></button>
11
+ <button @click="setLinkMode('preview')"><code :class="`${state.tools.confs.linkMode === 'preview' ? 'co-main' : ''}`">预览</code></button>
12
+ <button @click="setLinkMode('windows')"><code :class="`${state.tools.confs.linkMode === 'windows' ? 'co-main' : ''}`">新窗口</code></button>
13
13
  </div>
14
14
  </div>
15
15
  <div ui-line="@a" class="mt-sm mb-ss"></div>
16
16
  <div>
17
- <h6 class="fs-xs o-mm nowrap">每页显示数量</h6>
17
+ <h6 class="fs-ss o-mm nowrap">每页显示数量</h6>
18
18
  <div ui-btns="@a line s :group :border">
19
19
  <button @click="setPageSize(10)"><code :class="`${state.tools.param.pageSize === 10 ? 'co-main' : ''}`">10</code></button>
20
20
  <button @click="setPageSize(20)"><code :class="`${state.tools.param.pageSize === 20 ? 'co-main' : ''}`">20</code></button>
@@ -42,7 +42,7 @@
42
42
  </svg>
43
43
  </div>
44
44
  <div v-if="state.lists.length" ui-tips-box="tc" class="ny-sl al">
45
- <div class="w-mm max-h-ls" ui-scroll=":y s">
45
+ <div class="w-ml*s max-h-xl*s" ui-scroll=":y s">
46
46
  <ul class="n-sl n-ss-sub dib-sub">
47
47
  <li v-for="item in state.lists" :key="item">
48
48
  <button :ui-btn="`@a s ${item === currentPage ? 'main' : 'read :border'}`" @click="page(item)">
@@ -85,18 +85,18 @@
85
85
  ></path>
86
86
  </svg>
87
87
  </button>
88
- <div ui-tips-box="tl" class="al min-w-ms">
88
+ <div ui-tips-box="tl" class="al min-w-ms*s">
89
89
  <slot name="setting">
90
90
  <ul class="n-ms mb-sm-sub">
91
91
  <li>
92
- <h6 class="fs-xs o-mm nowrap">显示总条数</h6>
92
+ <h6 class="fs-ss o-mm nowrap">显示总条数</h6>
93
93
  <label ui-form="@a type:switch">
94
94
  <input type="checkbox" name="form2" v-model="state.showTotal" />
95
95
  <span>{{ state.showTotal ? '' : '' }}</span>
96
96
  </label>
97
97
  </li>
98
98
  <li>
99
- <h6 class="fs-xs o-mm nowrap">每页显示数量</h6>
99
+ <h6 class="fs-ss o-mm nowrap">每页显示数量</h6>
100
100
  <ul>
101
101
  <li v-for="item in pageSizeOptions" :key="item" @click="size(item)" class="ux-hover r-sm">
102
102
  <code :class="`${pageSize === item ? 'co-main' : ''}`">{{ item }}条/页</code>
@@ -69,7 +69,7 @@
69
69
  </svg>
70
70
  </div>
71
71
  <div v-if="state.list.length" ui-tips-box="tl" class="ny-sl al">
72
- <div class="max-h-ls" ui-scroll=":y s">
72
+ <div class="max-h-xl*s" ui-scroll=":y s">
73
73
  <ul class="n-ms nx-ss-sub nowrap">
74
74
  <li @click="size(10)" class="ux-hover r-sm"><code :class="`${modelValue.pageSize === 10 ? 'co-main' : ''}`">10条/页</code></li>
75
75
  <li @click="size(20)" class="ux-hover r-sm"><code :class="`${modelValue.pageSize === 20 ? 'co-main' : ''}`">20条/页</code></li>
@@ -100,18 +100,18 @@
100
100
  ></path>
101
101
  </svg>
102
102
  </button>
103
- <div ui-tips-box="tl" class="al min-w-ms">
103
+ <div ui-tips-box="tl" class="al min-w-ms*s">
104
104
  <slot name="setting">
105
105
  <ul class="n-ms mb-sm-sub">
106
106
  <li>
107
- <h6 class="fs-xs o-mm nowrap">显示总页数</h6>
107
+ <h6 class="fs-ss o-mm nowrap">显示总页数</h6>
108
108
  <label ui-form="@a type:switch">
109
109
  <input type="checkbox" v-model="state.showTotalPages" />
110
110
  <span>{{ state.showTotalPages ? '' : '' }}</span>
111
111
  </label>
112
112
  </li>
113
113
  <li>
114
- <h6 class="fs-xs o-mm nowrap">显示总条数</h6>
114
+ <h6 class="fs-ss o-mm nowrap">显示总条数</h6>
115
115
  <label ui-form="@a type:switch">
116
116
  <input type="checkbox" v-model="state.showTotal" />
117
117
  <span>{{ state.showTotal ? '' : '' }}</span>
package/tsconfig.json CHANGED
@@ -13,12 +13,11 @@
13
13
  "useDefineForClassFields": true,
14
14
  "sourceMap": true,
15
15
  "baseUrl": ".",
16
- "types": ["webpack-env"],
17
16
  "paths": {
18
17
  "@/*": ["src/*"]
19
18
  },
20
19
  "lib": ["esnext", "dom", "dom.iterable", "scripthost"]
21
20
  },
22
- "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue", "src/shims-vue.d.ts", "src/components/loader/FormLoader/FormRender@v3.vue.backup", "src/components/loader/FormLoader/FormLoader@v3.vue.backup"],
21
+ "include": ["src/**/*.ts", "src/**/*.tsx", "src/**/*.vue", "src/shims-vue.d.ts"],
23
22
  "exclude": ["node_modules"]
24
23
  }