@longhongguo/form-create-ant-design-vue 3.3.6 → 3.3.8

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/auto-import.js CHANGED
@@ -26,7 +26,9 @@ import {
26
26
  Spin,
27
27
  Transfer,
28
28
  Image,
29
- Table
29
+ Table,
30
+ Alert,
31
+ Card
30
32
  } from 'ant-design-vue'
31
33
 
32
34
  export default function install(formCreate) {
@@ -61,5 +63,7 @@ export default function install(formCreate) {
61
63
  app.component(Transfer.name) || app.use(Transfer)
62
64
  app.component(Image.name) || app.use(Image)
63
65
  app.component(Table.name) || app.use(Table)
66
+ app.component(Alert.name) || app.use(Alert)
67
+ app.component(Card.name) || app.use(Card)
64
68
  })
65
69
  }
@@ -57,7 +57,11 @@
57
57
  .form-create.is-preview .ant-textarea,
58
58
  .form-create.is-preview .ant-upload,
59
59
  .form-create.is-preview .ant-upload-list,
60
- .form-create.is-preview .ant-upload-list-item {
60
+ .form-create.is-preview .ant-upload-list-item,
61
+ .form-create.is-preview .ant-input-wrapper,
62
+ .form-create.is-preview .ant-input-affix-wrapper,
63
+ .form-create.is-preview .ant-input-group-wrapper,
64
+ .form-create.is-preview .ant-input-group {
61
65
  border: none !important;
62
66
  box-shadow: none !important;
63
67
  background: transparent !important;
@@ -69,7 +73,10 @@
69
73
  .form-create.is-preview .ant-picker:focus,
70
74
  .form-create.is-preview .ant-cascader-picker:focus,
71
75
  .form-create.is-preview .ant-input-password:focus,
72
- .form-create.is-preview .ant-textarea:focus {
76
+ .form-create.is-preview .ant-textarea:focus,
77
+ .form-create.is-preview .ant-input-wrapper:focus,
78
+ .form-create.is-preview .ant-input-affix-wrapper:focus,
79
+ .form-create.is-preview .ant-input-affix-wrapper-focused {
73
80
  border: none !important;
74
81
  box-shadow: none !important;
75
82
  outline: none !important;
@@ -81,11 +88,30 @@
81
88
  .form-create.is-preview .ant-picker:hover,
82
89
  .form-create.is-preview .ant-cascader-picker:hover,
83
90
  .form-create.is-preview .ant-input-password:hover,
84
- .form-create.is-preview .ant-textarea:hover {
91
+ .form-create.is-preview .ant-textarea:hover,
92
+ .form-create.is-preview .ant-input-wrapper:hover,
93
+ .form-create.is-preview .ant-input-affix-wrapper:hover {
85
94
  border: none !important;
86
95
  box-shadow: none !important;
87
96
  }
88
97
 
98
+ /* 预览模式:移除所有 input 相关元素的边框(更全面的覆盖) */
99
+ .form-create.is-preview .ant-input-affix-wrapper,
100
+ .form-create.is-preview .ant-input-affix-wrapper:hover,
101
+ .form-create.is-preview .ant-input-affix-wrapper-focused,
102
+ .form-create.is-preview .ant-input-affix-wrapper-disabled,
103
+ .form-create.is-preview .ant-input-wrapper .ant-input,
104
+ .form-create.is-preview .ant-input-group-addon,
105
+ .form-create.is-preview .ant-input-group .ant-input,
106
+ .form-create.is-preview input.ant-input,
107
+ .form-create.is-preview textarea.ant-input {
108
+ border: none !important;
109
+ border-width: 0 !important;
110
+ box-shadow: none !important;
111
+ outline: none !important;
112
+ background: transparent !important;
113
+ }
114
+
89
115
  /* 隐藏字数限制等提示信息 */
90
116
  .form-create.is-preview .ant-input-character-count,
91
117
  .form-create.is-preview .ant-textarea-character-count,
@@ -117,6 +143,16 @@
117
143
  pointer-events: none !important;
118
144
  }
119
145
 
146
+ /* 预览模式:允许 textarea 交互(用于复制文本) */
147
+ .form-create.is-preview textarea.ant-input {
148
+ pointer-events: auto !important;
149
+ user-select: text !important;
150
+ -webkit-user-select: text !important;
151
+ -moz-user-select: text !important;
152
+ -ms-user-select: text !important;
153
+ cursor: text !important;
154
+ }
155
+
120
156
  /* 预览模式:允许富文本编辑器容器滚动 */
121
157
  .form-create.is-preview .w-e-text-container {
122
158
  pointer-events: auto !important;
@@ -273,6 +309,39 @@
273
309
  cursor: default !important;
274
310
  }
275
311
 
312
+ /* 预览模式:textarea 自适应高度且只读可复制 */
313
+ .form-create.is-preview textarea.ant-input,
314
+ .form-create.is-preview .ant-textarea {
315
+ /* 允许文本选择,用于复制 */
316
+ user-select: text !important;
317
+ -webkit-user-select: text !important;
318
+ -moz-user-select: text !important;
319
+ -ms-user-select: text !important;
320
+ /* 允许交互,用于复制 */
321
+ pointer-events: auto !important;
322
+ cursor: text !important;
323
+ /* 移除滚动条(因为内容会自适应显示) */
324
+ overflow: hidden !important;
325
+ overflow-y: hidden !important;
326
+ overflow-x: hidden !important;
327
+ /* 确保只读状态下仍可正常显示和选择 */
328
+ resize: none !important;
329
+ /* 确保 textarea 能够根据内容自动调整高度 */
330
+ box-sizing: border-box !important;
331
+ /* 移除固定高度限制,让 JavaScript 动态设置 */
332
+ min-height: auto !important;
333
+ max-height: none !important;
334
+ }
335
+
336
+ /* 预览模式:textarea 只读状态样式 */
337
+ .form-create.is-preview textarea.ant-input[readonly],
338
+ .form-create.is-preview .ant-textarea[readonly] {
339
+ opacity: 1 !important;
340
+ color: inherit !important;
341
+ background-color: transparent !important;
342
+ cursor: text !important;
343
+ }
344
+
276
345
  /* 预览模式:防止选择器显示为禁用状态 */
277
346
  .form-create.is-preview .ant-select-disabled .ant-select-selector {
278
347
  opacity: 1 !important;
@@ -314,7 +383,7 @@
314
383
  max-height: none !important;
315
384
  }
316
385
 
317
- /* 富文本内容不可编辑,但允许容器滚动 */
386
+ /* 富文本内容只读:允许选择文本和点击链接,但禁止编辑 */
318
387
  .form-create.is-preview .w-e-text p,
319
388
  .form-create.is-preview .w-e-text div,
320
389
  .form-create.is-preview .w-e-text span,
@@ -327,19 +396,47 @@
327
396
  .form-create.is-preview .w-e-text h4,
328
397
  .form-create.is-preview .w-e-text h5,
329
398
  .form-create.is-preview .w-e-text h6,
330
- .form-create.is-preview .w-e-text a,
331
- .form-create.is-preview .w-e-text img,
332
399
  .form-create.is-preview .w-e-text table,
333
400
  .form-create.is-preview .w-e-text tr,
334
401
  .form-create.is-preview .w-e-text td,
335
402
  .form-create.is-preview .w-e-text th {
336
- pointer-events: none !important;
403
+ /* 允许文本选择,用于复制 */
404
+ user-select: text !important;
405
+ -webkit-user-select: text !important;
406
+ -moz-user-select: text !important;
407
+ -ms-user-select: text !important;
408
+ /* 阻止编辑,但不阻止交互 */
409
+ pointer-events: auto !important;
410
+ }
411
+
412
+ /* 允许链接可以点击 */
413
+ .form-create.is-preview .w-e-text a {
414
+ pointer-events: auto !important;
415
+ cursor: pointer !important;
416
+ user-select: text !important;
417
+ -webkit-user-select: text !important;
418
+ -moz-user-select: text !important;
419
+ -ms-user-select: text !important;
420
+ text-decoration: underline !important;
421
+ }
422
+
423
+ /* 允许图片可以查看 */
424
+ .form-create.is-preview .w-e-text img {
425
+ pointer-events: auto !important;
337
426
  user-select: none !important;
338
427
  -webkit-user-select: none !important;
339
428
  -moz-user-select: none !important;
340
429
  -ms-user-select: none !important;
341
430
  }
342
431
 
432
+ /* 禁止编辑:通过 contenteditable 属性控制 */
433
+ .form-create.is-preview .w-e-text {
434
+ user-select: text !important;
435
+ -webkit-user-select: text !important;
436
+ -moz-user-select: text !important;
437
+ -ms-user-select: text !important;
438
+ }
439
+
343
440
  /* 预览模式:禁用按钮点击 */
344
441
  .form-create.is-preview .ant-btn {
345
442
  pointer-events: none !important;
@@ -57,7 +57,11 @@
57
57
  .form-create.is-preview .ant-textarea,
58
58
  .form-create.is-preview .ant-upload,
59
59
  .form-create.is-preview .ant-upload-list,
60
- .form-create.is-preview .ant-upload-list-item {
60
+ .form-create.is-preview .ant-upload-list-item,
61
+ .form-create.is-preview .ant-input-wrapper,
62
+ .form-create.is-preview .ant-input-affix-wrapper,
63
+ .form-create.is-preview .ant-input-group-wrapper,
64
+ .form-create.is-preview .ant-input-group {
61
65
  border: none !important;
62
66
  box-shadow: none !important;
63
67
  background: transparent !important;
@@ -69,7 +73,10 @@
69
73
  .form-create.is-preview .ant-picker:focus,
70
74
  .form-create.is-preview .ant-cascader-picker:focus,
71
75
  .form-create.is-preview .ant-input-password:focus,
72
- .form-create.is-preview .ant-textarea:focus {
76
+ .form-create.is-preview .ant-textarea:focus,
77
+ .form-create.is-preview .ant-input-wrapper:focus,
78
+ .form-create.is-preview .ant-input-affix-wrapper:focus,
79
+ .form-create.is-preview .ant-input-affix-wrapper-focused {
73
80
  border: none !important;
74
81
  box-shadow: none !important;
75
82
  outline: none !important;
@@ -81,11 +88,30 @@
81
88
  .form-create.is-preview .ant-picker:hover,
82
89
  .form-create.is-preview .ant-cascader-picker:hover,
83
90
  .form-create.is-preview .ant-input-password:hover,
84
- .form-create.is-preview .ant-textarea:hover {
91
+ .form-create.is-preview .ant-textarea:hover,
92
+ .form-create.is-preview .ant-input-wrapper:hover,
93
+ .form-create.is-preview .ant-input-affix-wrapper:hover {
85
94
  border: none !important;
86
95
  box-shadow: none !important;
87
96
  }
88
97
 
98
+ /* 预览模式:移除所有 input 相关元素的边框(更全面的覆盖) */
99
+ .form-create.is-preview .ant-input-affix-wrapper,
100
+ .form-create.is-preview .ant-input-affix-wrapper:hover,
101
+ .form-create.is-preview .ant-input-affix-wrapper-focused,
102
+ .form-create.is-preview .ant-input-affix-wrapper-disabled,
103
+ .form-create.is-preview .ant-input-wrapper .ant-input,
104
+ .form-create.is-preview .ant-input-group-addon,
105
+ .form-create.is-preview .ant-input-group .ant-input,
106
+ .form-create.is-preview input.ant-input,
107
+ .form-create.is-preview textarea.ant-input {
108
+ border: none !important;
109
+ border-width: 0 !important;
110
+ box-shadow: none !important;
111
+ outline: none !important;
112
+ background: transparent !important;
113
+ }
114
+
89
115
  /* 隐藏字数限制等提示信息 */
90
116
  .form-create.is-preview .ant-input-character-count,
91
117
  .form-create.is-preview .ant-textarea-character-count,
@@ -117,6 +143,16 @@
117
143
  pointer-events: none !important;
118
144
  }
119
145
 
146
+ /* 预览模式:允许 textarea 交互(用于复制文本) */
147
+ .form-create.is-preview textarea.ant-input {
148
+ pointer-events: auto !important;
149
+ user-select: text !important;
150
+ -webkit-user-select: text !important;
151
+ -moz-user-select: text !important;
152
+ -ms-user-select: text !important;
153
+ cursor: text !important;
154
+ }
155
+
120
156
  /* 预览模式:允许富文本编辑器容器滚动 */
121
157
  .form-create.is-preview .w-e-text-container {
122
158
  pointer-events: auto !important;
@@ -273,6 +309,39 @@
273
309
  cursor: default !important;
274
310
  }
275
311
 
312
+ /* 预览模式:textarea 自适应高度且只读可复制 */
313
+ .form-create.is-preview textarea.ant-input,
314
+ .form-create.is-preview .ant-textarea {
315
+ /* 允许文本选择,用于复制 */
316
+ user-select: text !important;
317
+ -webkit-user-select: text !important;
318
+ -moz-user-select: text !important;
319
+ -ms-user-select: text !important;
320
+ /* 允许交互,用于复制 */
321
+ pointer-events: auto !important;
322
+ cursor: text !important;
323
+ /* 移除滚动条(因为内容会自适应显示) */
324
+ overflow: hidden !important;
325
+ overflow-y: hidden !important;
326
+ overflow-x: hidden !important;
327
+ /* 确保只读状态下仍可正常显示和选择 */
328
+ resize: none !important;
329
+ /* 确保 textarea 能够根据内容自动调整高度 */
330
+ box-sizing: border-box !important;
331
+ /* 移除固定高度限制,让 JavaScript 动态设置 */
332
+ min-height: auto !important;
333
+ max-height: none !important;
334
+ }
335
+
336
+ /* 预览模式:textarea 只读状态样式 */
337
+ .form-create.is-preview textarea.ant-input[readonly],
338
+ .form-create.is-preview .ant-textarea[readonly] {
339
+ opacity: 1 !important;
340
+ color: inherit !important;
341
+ background-color: transparent !important;
342
+ cursor: text !important;
343
+ }
344
+
276
345
  /* 预览模式:防止选择器显示为禁用状态 */
277
346
  .form-create.is-preview .ant-select-disabled .ant-select-selector {
278
347
  opacity: 1 !important;
@@ -314,7 +383,7 @@
314
383
  max-height: none !important;
315
384
  }
316
385
 
317
- /* 富文本内容不可编辑,但允许容器滚动 */
386
+ /* 富文本内容只读:允许选择文本和点击链接,但禁止编辑 */
318
387
  .form-create.is-preview .w-e-text p,
319
388
  .form-create.is-preview .w-e-text div,
320
389
  .form-create.is-preview .w-e-text span,
@@ -327,19 +396,47 @@
327
396
  .form-create.is-preview .w-e-text h4,
328
397
  .form-create.is-preview .w-e-text h5,
329
398
  .form-create.is-preview .w-e-text h6,
330
- .form-create.is-preview .w-e-text a,
331
- .form-create.is-preview .w-e-text img,
332
399
  .form-create.is-preview .w-e-text table,
333
400
  .form-create.is-preview .w-e-text tr,
334
401
  .form-create.is-preview .w-e-text td,
335
402
  .form-create.is-preview .w-e-text th {
336
- pointer-events: none !important;
403
+ /* 允许文本选择,用于复制 */
404
+ user-select: text !important;
405
+ -webkit-user-select: text !important;
406
+ -moz-user-select: text !important;
407
+ -ms-user-select: text !important;
408
+ /* 阻止编辑,但不阻止交互 */
409
+ pointer-events: auto !important;
410
+ }
411
+
412
+ /* 允许链接可以点击 */
413
+ .form-create.is-preview .w-e-text a {
414
+ pointer-events: auto !important;
415
+ cursor: pointer !important;
416
+ user-select: text !important;
417
+ -webkit-user-select: text !important;
418
+ -moz-user-select: text !important;
419
+ -ms-user-select: text !important;
420
+ text-decoration: underline !important;
421
+ }
422
+
423
+ /* 允许图片可以查看 */
424
+ .form-create.is-preview .w-e-text img {
425
+ pointer-events: auto !important;
337
426
  user-select: none !important;
338
427
  -webkit-user-select: none !important;
339
428
  -moz-user-select: none !important;
340
429
  -ms-user-select: none !important;
341
430
  }
342
431
 
432
+ /* 禁止编辑:通过 contenteditable 属性控制 */
433
+ .form-create.is-preview .w-e-text {
434
+ user-select: text !important;
435
+ -webkit-user-select: text !important;
436
+ -moz-user-select: text !important;
437
+ -ms-user-select: text !important;
438
+ }
439
+
343
440
  /* 预览模式:禁用按钮点击 */
344
441
  .form-create.is-preview .ant-btn {
345
442
  pointer-events: none !important;