@dckj-npm/dc-material 0.1.198 → 0.1.199

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.
@@ -347,26 +347,11 @@ const TeletextListMeta: IPublicTypeComponentMetadata = {
347
347
  ),
348
348
  )
349
349
  }
350
- // 改变属性dataList的值
351
- const dataListChildren = target.getProps().getPropValue('数据源绑定')
352
- const dataSourceConfig = {
353
- label: '图文数据',
354
- value: 'dataList',
355
- children: [
356
- { label: '图片链接', value: 'image' },
357
- { label: '标题', value: 'title' },
358
- { label: '说明', value: 'description' },
359
- // 根据实际的 textLines 动态生成文本字段
360
- ...Array.from({ length: value }).map((_, index) => ({
361
- label: `文本${index + 1}`,
362
- value: `text${index + 1}`,
363
- })),
364
- ],
365
- }
350
+ const setter = target?.node?.getProp('数据源绑定')?.setter
366
351
 
367
352
  // 设置新的数据源绑定配置
368
353
  // target.getProps().setPropValue('数据源绑定', dataSourceConfig)
369
- console.log('文字行数', target, value, schema, dataListChildren)
354
+ console.log('文字行数', target, value, schema, setter)
370
355
  },
371
356
  },
372
357
  },
@@ -99,7 +99,7 @@ function fillRealVersion(meta, packageName, version, basicLibraryVersion) {
99
99
  packageName = '@dckj-npm/dc-material';
100
100
  }
101
101
  if (version === void 0) {
102
- version = '0.1.198';
102
+ version = '0.1.199';
103
103
  }
104
104
  if (basicLibraryVersion === void 0) {
105
105
  basicLibraryVersion = {
@@ -273,7 +273,7 @@ var TeletextListMeta = {
273
273
  },
274
274
  extraProps: {
275
275
  setValue: function setValue(target, value) {
276
- var _target$node, _schema$children, _schema$children$filt;
276
+ var _target$node, _schema$children, _schema$children$filt, _target$node2, _target$node2$getProp;
277
277
  target.getProps().setPropValue('textLines', value);
278
278
  //获取组件schema
279
279
  var schema = target === null || target === void 0 ? void 0 : (_target$node = target.node) === null || _target$node === void 0 ? void 0 : _target$node.schema;
@@ -301,33 +301,11 @@ var TeletextListMeta = {
301
301
  return !(child.componentName === 'NextText' && (_child$props$key2 = child.props.key) !== null && _child$props$key2 !== void 0 && _child$props$key2.startsWith('text-') && parseInt(child.props.key.split('-')[1]) > value);
302
302
  });
303
303
  }
304
- // 改变属性dataList的值
305
- var dataListChildren = target.getProps().getPropValue('数据源绑定');
306
- var dataSourceConfig = {
307
- label: '图文数据',
308
- value: 'dataList',
309
- children: [{
310
- label: '图片链接',
311
- value: 'image'
312
- }, {
313
- label: '标题',
314
- value: 'title'
315
- }, {
316
- label: '说明',
317
- value: 'description'
318
- }].concat(Array.from({
319
- length: value
320
- }).map(function (_, index) {
321
- return {
322
- label: "\u6587\u672C" + (index + 1),
323
- value: "text" + (index + 1)
324
- };
325
- }))
326
- };
304
+ var setter = target === null || target === void 0 ? void 0 : (_target$node2 = target.node) === null || _target$node2 === void 0 ? void 0 : (_target$node2$getProp = _target$node2.getProp('数据源绑定')) === null || _target$node2$getProp === void 0 ? void 0 : _target$node2$getProp.setter;
327
305
 
328
306
  // 设置新的数据源绑定配置
329
307
  // target.getProps().setPropValue('数据源绑定', dataSourceConfig)
330
- console.log('文字行数', target, value, schema, dataListChildren);
308
+ console.log('文字行数', target, value, schema, setter);
331
309
  }
332
310
  }
333
311
  }, {
@@ -104,7 +104,7 @@ function fillRealVersion(meta, packageName, version, basicLibraryVersion) {
104
104
  packageName = '@dckj-npm/dc-material';
105
105
  }
106
106
  if (version === void 0) {
107
- version = '0.1.198';
107
+ version = '0.1.199';
108
108
  }
109
109
  if (basicLibraryVersion === void 0) {
110
110
  basicLibraryVersion = {
@@ -278,7 +278,7 @@ var TeletextListMeta = {
278
278
  },
279
279
  extraProps: {
280
280
  setValue: function setValue(target, value) {
281
- var _target$node, _schema$children, _schema$children$filt;
281
+ var _target$node, _schema$children, _schema$children$filt, _target$node2, _target$node2$getProp;
282
282
  target.getProps().setPropValue('textLines', value);
283
283
  //获取组件schema
284
284
  var schema = target === null || target === void 0 ? void 0 : (_target$node = target.node) === null || _target$node === void 0 ? void 0 : _target$node.schema;
@@ -306,33 +306,11 @@ var TeletextListMeta = {
306
306
  return !(child.componentName === 'NextText' && (_child$props$key2 = child.props.key) !== null && _child$props$key2 !== void 0 && _child$props$key2.startsWith('text-') && parseInt(child.props.key.split('-')[1]) > value);
307
307
  });
308
308
  }
309
- // 改变属性dataList的值
310
- var dataListChildren = target.getProps().getPropValue('数据源绑定');
311
- var dataSourceConfig = {
312
- label: '图文数据',
313
- value: 'dataList',
314
- children: [{
315
- label: '图片链接',
316
- value: 'image'
317
- }, {
318
- label: '标题',
319
- value: 'title'
320
- }, {
321
- label: '说明',
322
- value: 'description'
323
- }].concat(Array.from({
324
- length: value
325
- }).map(function (_, index) {
326
- return {
327
- label: "\u6587\u672C" + (index + 1),
328
- value: "text" + (index + 1)
329
- };
330
- }))
331
- };
309
+ var setter = target === null || target === void 0 ? void 0 : (_target$node2 = target.node) === null || _target$node2 === void 0 ? void 0 : (_target$node2$getProp = _target$node2.getProp('数据源绑定')) === null || _target$node2$getProp === void 0 ? void 0 : _target$node2$getProp.setter;
332
310
 
333
311
  // 设置新的数据源绑定配置
334
312
  // target.getProps().setPropValue('数据源绑定', dataSourceConfig)
335
- console.log('文字行数', target, value, schema, dataListChildren);
313
+ console.log('文字行数', target, value, schema, setter);
336
314
  }
337
315
  }
338
316
  }, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dckj-npm/dc-material",
3
- "version": "0.1.198",
3
+ "version": "0.1.199",
4
4
  "description": "dc低代码物料",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -106,7 +106,7 @@
106
106
  },
107
107
  "componentConfig": {
108
108
  "isComponentLibrary": true,
109
- "materialSchema": "https://unpkg.com/@dckj-npm/dc-material@0.1.198/build/lowcode/assets-prod.json"
109
+ "materialSchema": "https://unpkg.com/@dckj-npm/dc-material@0.1.199/build/lowcode/assets-prod.json"
110
110
  },
111
111
  "lcMeta": {
112
112
  "type": "component"