km-card-layout-component-miniprogram 0.1.24 → 0.1.26

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 (33) hide show
  1. package/example/app.js +1 -1
  2. package/example/pages/home/index.js +10 -0
  3. package/example/pages/home/index.wxml +2 -0
  4. package/example/pages/testicon/testicon.js +32 -8
  5. package/example/pages/testicon/testicon.wxml +25 -1
  6. package/example/pages/testicon/testicon.wxss +85 -30
  7. package/miniprogram_dist/components/card-layout/elements/icon-font.wxss +33 -402
  8. package/miniprogram_dist/components/card-layout/elements/text-element/index.js +2 -2
  9. package/miniprogram_dist/components/card-layout/elements/text-element/index.wxml +1 -1
  10. package/miniprogram_dist/components/card-layout/icon-map.js +11 -116
  11. package/miniprogram_dist/components/card-layout/index.js +22 -3
  12. package/miniprogram_dist/components/card-layout/index.json +2 -1
  13. package/miniprogram_dist/components/card-layout/index.wxml +1 -0
  14. package/miniprogram_dist/components/card-layout/share-canvas/index.js +56 -0
  15. package/miniprogram_dist/components/card-layout/share-canvas/index.json +6 -0
  16. package/miniprogram_dist/components/card-layout/share-canvas/index.wxml +11 -0
  17. package/miniprogram_dist/components/card-layout/share-canvas/index.wxss +27 -0
  18. package/miniprogram_dist/components/card-layout/share-canvas/share-style.js +37 -0
  19. package/miniprogram_dist/components/card-layout/share-style.js +5 -0
  20. package/package.json +1 -1
  21. package/src/components/card-layout/elements/icon-font.wxss +33 -402
  22. package/src/components/card-layout/elements/text-element/index.ts +2 -2
  23. package/src/components/card-layout/elements/text-element/index.wxml +1 -1
  24. package/src/components/card-layout/icon-map.ts +11 -116
  25. package/src/components/card-layout/index.json +2 -1
  26. package/src/components/card-layout/index.ts +23 -4
  27. package/src/components/card-layout/index.wxml +1 -0
  28. package/src/components/card-layout/share-canvas/index.json +6 -0
  29. package/src/components/card-layout/share-canvas/index.ts +59 -0
  30. package/src/components/card-layout/share-canvas/index.wxml +11 -0
  31. package/src/components/card-layout/share-canvas/index.wxss +27 -0
  32. package/src/components/card-layout/share-canvas/share-style.ts +42 -0
  33. package/src/components/card-layout/share-style.ts +1 -0
@@ -1,428 +1,59 @@
1
- .icon {
2
- font-family: 'layout-icon' !important;
1
+ @font-face {
2
+ font-family: "layoutIconFont"; /* Project id 5095635 */
3
+ src: url('//at.alicdn.com/t/c/font_5095635_ztv7ro0zm59.woff2?t=1766563440291') format('woff2'),
4
+ url('//at.alicdn.com/t/c/font_5095635_ztv7ro0zm59.woff?t=1766563440291') format('woff'),
5
+ url('//at.alicdn.com/t/c/font_5095635_ztv7ro0zm59.ttf?t=1766563440291') format('truetype'),
6
+ url('//at.alicdn.com/t/c/font_5095635_ztv7ro0zm59.svg?t=1766563440291#layoutIconFont') format('svg');
7
+ }
8
+
9
+ .layoutIconFont {
10
+ font-family: "layoutIconFont" !important;
11
+ font-size: 16px;
3
12
  font-style: normal;
4
13
  -webkit-font-smoothing: antialiased;
5
14
  -moz-osx-font-smoothing: grayscale;
6
15
  }
7
16
 
8
- .icon-buy-vip-13:before {
9
- content: '\e66a';
10
- }
11
-
12
- .icon-buy-vip-11:before {
13
- content: '\e669';
14
- }
15
-
16
- .icon-buy-vip-12:before {
17
- content: '\e668';
18
- }
19
-
20
- .icon-contact-wechat:before {
21
- content: '\e667';
22
- }
23
-
24
- .icon-contact-phone:before {
25
- content: '\e666';
26
- }
27
-
28
- .icon-column-group:before {
29
- content: '\e664';
30
- }
31
-
32
- .icon-minichat:before {
33
- content: '\e617';
34
- }
35
-
36
- .icon-remove-module:before {
37
- content: '\e660';
38
- }
39
-
40
- .icon-add-module:before {
41
- content: '\e662';
42
- }
43
-
44
- .icon-drag:before {
45
- content: '\e661';
46
- }
47
-
48
- .icon-switch-company:before {
49
- content: '\e65f';
50
- }
51
-
52
- .icon-switch-person:before {
53
- content: '\e65e';
54
- }
55
-
56
- .icon-manual-entry:before {
57
- content: '\e65d';
58
- }
59
-
60
- .icon-play:before {
61
- content: '\e65c';
62
- }
63
-
64
- .icon-plus:before {
65
- content: '\e659';
66
- }
67
-
68
- .icon-file-pdf:before {
69
- content: '\e65b';
70
- }
71
-
72
- .icon-file-video:before {
73
- content: '\e65a';
74
- }
75
-
76
- .icon-upload:before {
77
- content: '\e650';
78
- }
79
-
80
- .icon-cert-company:before {
81
- content: '\e64f';
82
- }
83
-
84
- .icon-qr-code:before {
85
- content: '\e658';
86
- }
87
-
88
- .icon-company-card:before {
89
- content: '\e657';
90
- }
91
-
92
- .icon-card-import:before {
93
- content: '\e64e';
94
- }
95
-
96
- .icon-camera:before {
97
- content: '\e655';
98
- }
99
-
100
- .icon-card-apply:before {
101
- content: '\e632';
102
- }
103
-
104
- .icon-check-2:before {
105
- content: '\e616';
106
- }
107
-
108
- .icon-check:before {
109
- content: '\e614';
110
- }
111
-
112
- .icon-buy-vip-4:before {
113
- content: '\e613';
114
- }
115
-
116
- .icon-buy-vip-10:before {
117
- content: '\e656';
118
- }
119
-
120
- .icon-weixin-2:before {
121
- content: '\e653';
122
- }
123
-
124
- .icon-qrcode-1:before {
125
- content: '\e654';
126
- }
127
-
128
- .icon-local:before {
129
- content: '\e652';
130
- }
131
-
132
- .icon-cert-job:before {
133
- content: '\e64d';
134
- }
135
-
136
- .icon-cert-name:before {
137
- content: '\e651';
138
- }
139
-
140
- .icon-card-style-1:before {
141
- content: '\e64c';
142
- }
143
-
144
- .icon-add-pic:before {
145
- content: '\e646';
146
- }
147
-
148
- .icon-add-text:before {
149
- content: '\e647';
150
- }
151
-
152
- .icon-buy-vip-2:before {
153
- content: '\e648';
154
- }
155
-
156
- .icon-company-upload-logo:before {
157
- content: '\e649';
158
- }
159
-
160
- .icon-Headset-one:before {
161
- content: '\e64a';
162
- }
163
-
164
- .icon-edit-info:before {
165
- content: '\e64b';
166
- }
167
-
168
- .icon-more-action:before {
169
- content: '\e645';
170
- }
171
-
172
- .icon-upload-video:before {
173
- content: '\e644';
174
- }
175
-
176
- .icon-upload-image:before {
177
- content: '\e643';
178
- }
179
-
180
- .icon-company-info:before {
181
- content: '\e62a';
182
- }
183
-
184
- .icon-contact:before {
185
- content: '\e642';
186
- }
187
-
188
- .icon-notice-1:before {
189
- content: '\e641';
190
- }
191
-
192
- .icon-visitor:before {
193
- content: '\e640';
194
- }
195
-
196
- .icon-mobile-2:before {
197
- content: '\e63e';
198
- }
199
-
200
- .icon-weixin-1:before {
201
- content: '\e63f';
202
- }
203
-
204
- .icon-share:before {
205
- content: '\e63d';
206
- }
207
-
208
- .icon-refund-mistake:before {
209
- content: '\e637';
210
- }
211
-
212
- .icon-buy-vip-7:before {
213
- content: '\e63b';
214
- }
215
-
216
- .icon-table-import:before {
217
- content: '\e63c';
218
- }
219
-
220
- .icon-misService:before {
221
- content: '\e63a';
222
- }
223
-
224
- .icon-buy-vip-6:before {
225
- content: '\e634';
226
- }
227
-
228
- .icon-import:before {
229
- content: '\e638';
230
- }
231
-
232
- .icon-download:before {
233
- content: '\e639';
234
- }
235
-
236
- .icon-image:before {
237
- content: '\e636';
238
- }
239
-
240
- .icon-buy-vip-9:before {
241
- content: '\e635';
242
- }
243
-
244
- .icon-buy-vip-5:before {
245
- content: '\e62f';
246
- }
247
-
248
- .icon-buy-vip-3:before {
249
- content: '\e630';
250
- }
251
-
252
- .icon-buy-vip-1:before {
253
- content: '\e631';
254
- }
255
-
256
- .icon-buy-vip-8:before {
257
- content: '\e633';
258
- }
259
-
260
- .icon-companyWx:before {
261
- content: '\e62b';
262
- }
263
-
264
- .icon-dingding:before {
265
- content: '\e62c';
266
- }
267
-
268
- .icon-shui:before {
269
- content: '\e62d';
270
- }
271
-
272
- .icon-gongzhang:before {
273
- content: '\e62e';
274
- }
275
-
276
- .icon-wait:before {
277
- content: '\e629';
278
- }
279
-
280
- .icon-addImg:before {
281
- content: '\e628';
282
- }
283
-
284
- .icon-copy:before {
285
- content: '\e625';
17
+ .layout-icon-round:before {
18
+ content: "\e608";
286
19
  }
287
20
 
288
- .icon-mobile-1:before {
289
- content: '\e627';
21
+ .layout-icon-email:before {
22
+ content: "\e648";
290
23
  }
291
24
 
292
- .icon-functional-config:before {
293
- content: '\e604';
25
+ .layout-icon-mobile-line:before {
26
+ content: "\e64c";
294
27
  }
295
28
 
296
- .icon-module-config:before {
297
- content: '\e601';
29
+ .layout-icon-address-line:before {
30
+ content: "\e606";
298
31
  }
299
32
 
300
- .icon-select-right:before {
301
- content: '\e626';
33
+ .layout-icon-mobile:before {
34
+ content: "\e605";
302
35
  }
303
36
 
304
- .icon-like:before {
305
- content: '\e624';
37
+ .layout-icon-email-line:before {
38
+ content: "\e625";
306
39
  }
307
40
 
308
- .icon-weixin:before {
309
- content: '\e620';
41
+ .layout-icon-company-line:before {
42
+ content: "\e647";
310
43
  }
311
44
 
312
- .icon-column-user:before {
313
- content: '\e621';
45
+ .layout-icon-company:before {
46
+ content: "\e64a";
314
47
  }
315
48
 
316
- .icon-column-card:before {
317
- content: '\e622';
49
+ .layout-icon-address:before {
50
+ content: "\e628";
318
51
  }
319
52
 
320
- .icon-column-company-card:before {
321
- content: '\e623';
53
+ .layout-icon-website-line:before {
54
+ content: "\e679";
322
55
  }
323
56
 
324
- .icon-on-job:before {
325
- content: '\e61e';
326
- }
327
-
328
- .icon-person:before {
329
- content: '\e61f';
330
- }
331
-
332
- .icon-wallet:before {
333
- content: '\e615';
334
- }
335
-
336
- .icon-opinion:before {
337
- content: '\e618';
338
- }
339
-
340
- .icon-sys-set:before {
341
- content: '\e619';
342
- }
343
-
344
- .icon-sys-msg:before {
345
- content: '\e61d';
346
- }
347
-
348
- .icon-add:before {
349
- content: '\e61a';
350
- }
351
-
352
- .icon-search:before {
353
- content: '\e61b';
354
- }
355
-
356
- .icon-delete:before {
357
- content: '\e61c';
358
- }
359
-
360
- .icon-enter:before {
361
- content: '\e60f';
362
- }
363
-
364
- .icon-card-style:before {
365
- content: '\e610';
366
- }
367
-
368
- .icon-switch:before {
369
- content: '\e612';
370
- }
371
-
372
- .icon-card-edit:before {
373
- content: '\e60a';
374
- }
375
-
376
- .icon-close:before {
377
- content: '\e60d';
378
- }
379
-
380
- .icon-notice:before {
381
- content: '\e611';
382
- }
383
-
384
- .icon-edit:before {
385
- content: '\e60b';
386
- }
387
-
388
- .icon-help-info:before {
389
- content: '\e60c';
390
- }
391
-
392
- .icon-tag-filtering:before {
393
- content: '\e60e';
394
- }
395
-
396
- .icon-kuanmai-logo:before {
397
- content: '\e603';
398
- }
399
-
400
- .icon-company:before {
401
- content: '\e606';
402
- }
403
-
404
- .icon-email:before {
405
- content: '\e607';
406
- }
407
-
408
- .icon-round:before {
409
- content: '\e608';
410
- }
411
-
412
- .icon-address:before {
413
- content: '\e609';
414
- }
415
-
416
- .icon-mobile:before {
417
- content: '\e602';
418
- }
419
- .icon-helper:before {
420
- content: '\e663';
421
- }
422
-
423
- .icon-bag:before {
424
- content: '\e605';
425
- }
426
- .icon-group:before {
427
- content: '\e665';
57
+ .layout-icon-website:before {
58
+ content: "\e643";
428
59
  }
@@ -11,13 +11,13 @@ import { ICON_CODE_MAP } from "../../icon-map";
11
11
 
12
12
  const normalizeIconName = (name?: string) => {
13
13
  if (!name) return "";
14
- return name.startsWith("icon-") ? name.slice(5) : name;
14
+ return name.startsWith("layout-icon-") ? name.slice(5) : name;
15
15
  };
16
16
 
17
17
  const buildIconClassName = (name?: string) => {
18
18
  const normalized = normalizeIconName(name);
19
19
  if (!normalized) return "";
20
- return `icon-${normalized}`;
20
+ return `layout-icon-${normalized}`;
21
21
  };
22
22
 
23
23
  const buildIconCode = (name?: string) => {
@@ -6,7 +6,7 @@
6
6
  class="km-node__text-icon--wrapper canvas-item"
7
7
  style="{{iconMeta.wrapperStyle}}"
8
8
  >
9
- <view class="km-node__text-icon icon {{iconMeta.className}} canvas-item" style="font-size: {{iconMeta.size}}; color: {{iconMeta.color || ''}}; margin-right: {{iconMeta.gap || ''}};" data-icon="{{iconMeta.iconCode}}" ></view>
9
+ <view class="km-node__text-icon layoutIconFont {{iconMeta.className}} canvas-item" style="font-size: {{iconMeta.size}}; color: {{iconMeta.color || ''}}; margin-right: {{iconMeta.gap || ''}};" data-icon="{{iconMeta.iconCode}}" ></view>
10
10
  </view>
11
11
  <view class="km-node__text-value canvas-item" style="{{textStyle}}" data-text="{{textValue || ''}}">{{textValue || ''}}</view>
12
12
  </view>
@@ -1,118 +1,13 @@
1
1
  export const ICON_CODE_MAP: Record<string, string> = {
2
- Frame4: 'e674',
3
- chain: 'e673',
4
- 'swap-setting': 'e672',
5
- email1: 'e670',
6
- mobile1: 'e671',
7
- website: 'e66f',
8
- calendar: 'e66e',
9
- 'contact-fill': 'e66d',
10
- 'card-holder': 'e66c',
11
- link: 'e66b',
12
- 'buy-vip-13': 'e66a',
13
- 'buy-vip-11': 'e669',
14
- 'buy-vip-12': 'e668',
15
- 'contact-phone': 'e666',
16
- 'contact-wechat': 'e667',
17
- group: 'e665',
18
- bag: 'e605',
19
- 'column-group': 'e664',
20
- minichat: 'e617',
21
- helper: 'e663',
22
- 'remove-module': 'e660',
23
- 'add-module': 'e662',
24
- drag: 'e661',
25
- 'switch-company': 'e65f',
26
- 'switch-person': 'e65e',
27
- 'manual-entry': 'e65d',
28
- play: 'e65c',
29
- 'file-pdf': 'e65b',
30
- 'file-video': 'e65a',
31
- plus: 'e659',
32
- upload: 'e650',
33
- 'cert-company': 'e64f',
34
- 'qr-code': 'e658',
35
- 'company-card': 'e657',
36
- 'card-import': 'e64e',
37
- camera: 'e655',
38
- 'card-apply': 'e632',
39
- 'check-2': 'e616',
40
- check: 'e614',
41
- 'buy-vip-4': 'e613',
42
- 'buy-vip-10': 'e656',
43
- 'weixin-2': 'e653',
44
- 'qrcode-1': 'e654',
45
- local: 'e652',
46
- 'cert-job': 'e64d',
47
- 'cert-name': 'e651',
48
- 'card-style-1': 'e64c',
49
- 'add-pic': 'e646',
50
- 'add-text': 'e647',
51
- 'buy-vip-2': 'e648',
52
- 'company-upload-logo': 'e649',
53
- 'Headset-one': 'e64a',
54
- 'edit-info': 'e64b',
55
- 'more-action': 'e645',
56
- 'upload-video': 'e644',
57
- 'upload-image': 'e643',
58
- 'company-info': 'e62a',
59
- contact: 'e642',
60
- 'notice-1': 'e641',
61
- visitor: 'e640',
62
- 'mobile-2': 'e63e',
63
- 'weixin-1': 'e63f',
64
- share: 'e63d',
65
- 'refund-mistake': 'e637',
66
- 'buy-vip-7': 'e63b',
67
- 'table-import': 'e63c',
68
- misService: 'e63a',
69
- 'buy-vip-6': 'e634',
70
- import: 'e638',
71
- download: 'e639',
72
- image: 'e636',
73
- 'buy-vip-9': 'e635',
74
- 'buy-vip-5': 'e62f',
75
- 'buy-vip-3': 'e630',
76
- 'buy-vip-1': 'e631',
77
- 'buy-vip-8': 'e633',
78
- companyWx: 'e62b',
79
- dingding: 'e62c',
80
- shui: 'e62d',
81
- gongzhang: 'e62e',
82
- wait: 'e629',
83
- addImg: 'e628',
84
- copy: 'e625',
85
- 'mobile-1': 'e627',
86
- 'functional-config': 'e604',
87
- 'module-config': 'e601',
88
- 'select-right': 'e626',
89
- like: 'e624',
90
- weixin: 'e620',
91
- 'column-user': 'e621',
92
- 'column-card': 'e622',
93
- 'column-company-card': 'e623',
94
- 'on-job': 'e61e',
95
- person: 'e61f',
96
- wallet: 'e615',
97
- opinion: 'e618',
98
- 'sys-set': 'e619',
99
- 'sys-msg': 'e61d',
100
- add: 'e61a',
101
- search: 'e61b',
102
- delete: 'e61c',
103
- enter: 'e60f',
104
- 'card-style': 'e610',
105
- switch: 'e612',
106
- 'card-edit': 'e60a',
107
- close: 'e60d',
108
- notice: 'e611',
109
- edit: 'e60b',
110
- 'help-info': 'e60c',
111
- 'tag-filtering': 'e60e',
112
- 'kuanmai-logo': 'e603',
113
- company: 'e606',
114
- email: 'e607',
115
- round: 'e608',
116
- address: 'e609',
117
- mobile: 'e602',
2
+ round: "e608",
3
+ email: "e648",
4
+ "mobile-line": "e64c",
5
+ "address-line": "e606",
6
+ mobile: "e605",
7
+ "email-line": "e625",
8
+ "company-line": "e647",
9
+ company: "e64a",
10
+ address: "e628",
11
+ "website-line": "e679",
12
+ website: "e643",
118
13
  };
@@ -6,6 +6,7 @@
6
6
  "icon-element": "./elements/icon-element/index",
7
7
  "custom-element": "./elements/custom-element/index",
8
8
  "layout-panel-element": "./elements/layout-panel-element/index",
9
- "wxml2canvas": "../../vendor/wxml2canvas-2d/index"
9
+ "wxml2canvas": "../../vendor/wxml2canvas-2d/index",
10
+ "share-canvas": "./share-canvas/index"
10
11
  }
11
12
  }