bkui-vue 0.0.1-beta.36 → 0.0.1-beta.37

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.
@@ -9262,8 +9262,9 @@ const inputType = {
9262
9262
  showControl: PropTypes.bool.def(true),
9263
9263
  showClearOnlyHover: PropTypes.bool.def(false),
9264
9264
  precision: PropTypes.number.def(0).validate((val) => val >= 0 && val < 20),
9265
- modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
9266
- size: PropTypes.size()
9265
+ modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).def(""),
9266
+ size: PropTypes.size(),
9267
+ rows: PropTypes.number
9267
9268
  };
9268
9269
  const inputEvents = ["update:modelValue", "focus", "blur", "change", "clear", "input", "keypress", "keydown", "keyup", "enter", "paste"];
9269
9270
  const EventEnum = stringEnum([...inputEvents]);
@@ -9275,7 +9276,8 @@ var Component$i = vue.defineComponent({
9275
9276
  setup(props, ctx) {
9276
9277
  const isFocused = vue.ref(false);
9277
9278
  const isCNInput = vue.ref(false);
9278
- const inputClsPrefix = "bk-input";
9279
+ const isTextArea = vue.computed(() => props.type === "textarea");
9280
+ const inputClsPrefix = vue.computed(() => isTextArea.value ? "bk-textarea" : "bk-input");
9279
9281
  const _a = ctx.attrs, {
9280
9282
  class: cls,
9281
9283
  style
@@ -9284,13 +9286,13 @@ var Component$i = vue.defineComponent({
9284
9286
  "style"
9285
9287
  ]);
9286
9288
  const inputCls = vue.computed(() => classes({
9287
- [`${inputClsPrefix}--${props.size}`]: !!props.size,
9289
+ [`${inputClsPrefix.value}--${props.size}`]: !!props.size,
9288
9290
  "is-focused": isFocused.value,
9289
9291
  "is-readonly": props.readonly,
9290
9292
  "is-disabled": props.disabled,
9291
9293
  "is-simplicity": props.behavior === "simplicity",
9292
9294
  [`${cls}`]: !!cls
9293
- }, inputClsPrefix));
9295
+ }, inputClsPrefix.value));
9294
9296
  const suffixIconMap = {
9295
9297
  search: () => vue.createVNode(search, null, null),
9296
9298
  password: () => vue.createVNode(eye, {
@@ -9376,11 +9378,28 @@ var Component$i = vue.defineComponent({
9376
9378
  ctx.emit(EventEnum["update:modelValue"], newVal);
9377
9379
  }
9378
9380
  function getCls(name) {
9379
- return `${inputClsPrefix}--${name}`;
9381
+ return `${inputClsPrefix.value}--${name}`;
9380
9382
  }
9381
9383
  function handleVisibleChange() {
9382
9384
  pwdVisible.value = !pwdVisible.value;
9383
9385
  }
9386
+ const bindProps = vue.computed(() => ({
9387
+ value: props.modelValue,
9388
+ maxlength: props.maxlength,
9389
+ placeholder: props.placeholder,
9390
+ readonly: props.readonly,
9391
+ disabled: props.disabled,
9392
+ onInput: handleInput,
9393
+ onFocus: handleFocus,
9394
+ onBlur: handleBlur,
9395
+ onPaste: handlePaste,
9396
+ onChange: handleChange,
9397
+ onKeypress: handleKeyPress,
9398
+ onKeydown: handleKeydown,
9399
+ onKeyup: handleKeyup,
9400
+ onCompositionstart: handleCompositionStart,
9401
+ onCompositionend: handleCompositionEnd
9402
+ }));
9384
9403
  return () => {
9385
9404
  var _a2, _b, _c, _d, _e, _f;
9386
9405
  return vue.createVNode("div", {
@@ -9390,31 +9409,18 @@ var Component$i = vue.defineComponent({
9390
9409
  "class": getCls("prefix-area")
9391
9410
  }, [vue.createVNode("span", {
9392
9411
  "class": getCls("prefix-area--text")
9393
- }, [props.prefix])]), vue.createVNode("input", vue.mergeProps(inputAttrs, {
9394
- "class": `${inputClsPrefix}--text`,
9395
- "value": props.modelValue,
9412
+ }, [props.prefix])]), isTextArea.value ? vue.createVNode("textarea", vue.mergeProps(inputAttrs, bindProps.value, {
9413
+ "rows": props.rows
9414
+ }), null) : vue.createVNode("input", vue.mergeProps(inputAttrs, {
9415
+ "class": `${inputClsPrefix.value}--text`,
9396
9416
  "type": pwdVisible.value && props.type === "password" ? "text" : props.type,
9397
- "maxlength": props.maxlength,
9398
9417
  "step": props.step,
9399
9418
  "max": props.max,
9400
- "min": props.min,
9401
- "placeholder": props.placeholder,
9402
- "readonly": props.readonly,
9403
- "disabled": props.disabled,
9404
- "onInput": handleInput,
9405
- "onFocus": handleFocus,
9406
- "onBlur": handleBlur,
9407
- "onPaste": handlePaste,
9408
- "onChange": handleChange,
9409
- "onKeypress": handleKeyPress,
9410
- "onKeydown": handleKeydown,
9411
- "onKeyup": handleKeyup,
9412
- "onCompositionstart": handleCompositionStart,
9413
- "onCompositionend": handleCompositionEnd
9414
- }), null), props.clearable && !!props.modelValue && vue.createVNode(close$1, {
9419
+ "min": props.min
9420
+ }, bindProps.value), null), !isTextArea.value && props.clearable && !!props.modelValue && vue.createVNode(close$1, {
9415
9421
  "onClick": clear,
9416
9422
  "class": clearCls.value
9417
- }, null), suffixIcon.value, typeof props.maxlength === "number" && props.showWordLimit && vue.createVNode("p", {
9423
+ }, null), suffixIcon.value, typeof props.maxlength === "number" && (props.showWordLimit || isTextArea.value) && vue.createVNode("p", {
9418
9424
  "class": getCls("max-length")
9419
9425
  }, [props.modelValue.toString().length, vue.createTextVNode("/"), vue.createVNode("span", null, [ceilMaxLength.value])]), isNumberInput.value && props.showControl && vue.createVNode("div", {
9420
9426
  "class": getCls("number-control")
@@ -12489,7 +12495,7 @@ const resolveColumnWidth = (root, colgroups, autoWidth = 20) => {
12489
12495
  const {
12490
12496
  width
12491
12497
  } = root.getBoundingClientRect() || {};
12492
- let avgWidth = width;
12498
+ let avgWidth = width - 4;
12493
12499
  const avgColIndexList = [];
12494
12500
  const resolveColNumberWidth = (col, numWidth, resetAvgWidth = true) => {
12495
12501
  Object.assign(col, {
@@ -12573,11 +12579,13 @@ const resolvePaginationOption = (propPagination, defVal) => {
12573
12579
  };
12574
12580
  class TableRender {
12575
12581
  constructor(props, ctx, reactiveProp, colgroups) {
12582
+ __publicField(this, "getColumnClass", (colIndex) => `${this.uuid}-column-${colIndex}`);
12576
12583
  this.props = props;
12577
12584
  this.context = ctx;
12578
12585
  this.reactiveProp = reactiveProp;
12579
12586
  this.colgroups = colgroups;
12580
12587
  this.plugins = new TablePlugins(props, ctx);
12588
+ this.uuid = random(8);
12581
12589
  }
12582
12590
  get propActiveCols() {
12583
12591
  return this.reactiveProp.activeColumns;
@@ -12659,12 +12667,13 @@ class TableRender {
12659
12667
  "style": rowStyle,
12660
12668
  "onClick": (e) => this.handleRowClick(e, row, index, rows),
12661
12669
  "onDblclick": (e) => this.handleRowDblClick(e, row, index, rows)
12662
- }, [this.props.columns.map((column) => vue.createVNode("td", {
12670
+ }, [this.props.columns.map((column, index2) => vue.createVNode("td", {
12671
+ "class": this.getColumnClass(index2),
12663
12672
  "colspan": 1,
12664
12673
  "rowspan": 1
12665
12674
  }, [vue.createVNode("div", {
12666
12675
  "class": "cell"
12667
- }, [this.renderCell(row, column, index, rows)])]))]);
12676
+ }, [this.renderCell(row, column, index2, rows)])]))]);
12668
12677
  })]);
12669
12678
  }
12670
12679
  handleRowClick(e, row, index, rows) {
@@ -12688,12 +12697,10 @@ class TableRender {
12688
12697
  const colCls = classes({
12689
12698
  active: this.isColActive(index)
12690
12699
  });
12691
- const colStyle = {
12692
- width: resolveWidth(column.calcWidth)
12693
- };
12700
+ const width = `${resolveWidth(column.calcWidth)}`.replace(/px$/i, "");
12694
12701
  return vue.createVNode("col", {
12695
12702
  "class": colCls,
12696
- "style": colStyle
12703
+ "width": width
12697
12704
  }, null);
12698
12705
  })]);
12699
12706
  }
@@ -9260,8 +9260,9 @@ const inputType = {
9260
9260
  showControl: PropTypes.bool.def(true),
9261
9261
  showClearOnlyHover: PropTypes.bool.def(false),
9262
9262
  precision: PropTypes.number.def(0).validate((val) => val >= 0 && val < 20),
9263
- modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
9264
- size: PropTypes.size()
9263
+ modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).def(""),
9264
+ size: PropTypes.size(),
9265
+ rows: PropTypes.number
9265
9266
  };
9266
9267
  const inputEvents = ["update:modelValue", "focus", "blur", "change", "clear", "input", "keypress", "keydown", "keyup", "enter", "paste"];
9267
9268
  const EventEnum = stringEnum([...inputEvents]);
@@ -9273,7 +9274,8 @@ var Component$i = defineComponent({
9273
9274
  setup(props, ctx) {
9274
9275
  const isFocused = ref(false);
9275
9276
  const isCNInput = ref(false);
9276
- const inputClsPrefix = "bk-input";
9277
+ const isTextArea = computed(() => props.type === "textarea");
9278
+ const inputClsPrefix = computed(() => isTextArea.value ? "bk-textarea" : "bk-input");
9277
9279
  const _a = ctx.attrs, {
9278
9280
  class: cls,
9279
9281
  style
@@ -9282,13 +9284,13 @@ var Component$i = defineComponent({
9282
9284
  "style"
9283
9285
  ]);
9284
9286
  const inputCls = computed(() => classes({
9285
- [`${inputClsPrefix}--${props.size}`]: !!props.size,
9287
+ [`${inputClsPrefix.value}--${props.size}`]: !!props.size,
9286
9288
  "is-focused": isFocused.value,
9287
9289
  "is-readonly": props.readonly,
9288
9290
  "is-disabled": props.disabled,
9289
9291
  "is-simplicity": props.behavior === "simplicity",
9290
9292
  [`${cls}`]: !!cls
9291
- }, inputClsPrefix));
9293
+ }, inputClsPrefix.value));
9292
9294
  const suffixIconMap = {
9293
9295
  search: () => createVNode(search, null, null),
9294
9296
  password: () => createVNode(eye, {
@@ -9374,11 +9376,28 @@ var Component$i = defineComponent({
9374
9376
  ctx.emit(EventEnum["update:modelValue"], newVal);
9375
9377
  }
9376
9378
  function getCls(name) {
9377
- return `${inputClsPrefix}--${name}`;
9379
+ return `${inputClsPrefix.value}--${name}`;
9378
9380
  }
9379
9381
  function handleVisibleChange() {
9380
9382
  pwdVisible.value = !pwdVisible.value;
9381
9383
  }
9384
+ const bindProps = computed(() => ({
9385
+ value: props.modelValue,
9386
+ maxlength: props.maxlength,
9387
+ placeholder: props.placeholder,
9388
+ readonly: props.readonly,
9389
+ disabled: props.disabled,
9390
+ onInput: handleInput,
9391
+ onFocus: handleFocus,
9392
+ onBlur: handleBlur,
9393
+ onPaste: handlePaste,
9394
+ onChange: handleChange,
9395
+ onKeypress: handleKeyPress,
9396
+ onKeydown: handleKeydown,
9397
+ onKeyup: handleKeyup,
9398
+ onCompositionstart: handleCompositionStart,
9399
+ onCompositionend: handleCompositionEnd
9400
+ }));
9382
9401
  return () => {
9383
9402
  var _a2, _b, _c, _d, _e, _f;
9384
9403
  return createVNode("div", {
@@ -9388,31 +9407,18 @@ var Component$i = defineComponent({
9388
9407
  "class": getCls("prefix-area")
9389
9408
  }, [createVNode("span", {
9390
9409
  "class": getCls("prefix-area--text")
9391
- }, [props.prefix])]), createVNode("input", mergeProps(inputAttrs, {
9392
- "class": `${inputClsPrefix}--text`,
9393
- "value": props.modelValue,
9410
+ }, [props.prefix])]), isTextArea.value ? createVNode("textarea", mergeProps(inputAttrs, bindProps.value, {
9411
+ "rows": props.rows
9412
+ }), null) : createVNode("input", mergeProps(inputAttrs, {
9413
+ "class": `${inputClsPrefix.value}--text`,
9394
9414
  "type": pwdVisible.value && props.type === "password" ? "text" : props.type,
9395
- "maxlength": props.maxlength,
9396
9415
  "step": props.step,
9397
9416
  "max": props.max,
9398
- "min": props.min,
9399
- "placeholder": props.placeholder,
9400
- "readonly": props.readonly,
9401
- "disabled": props.disabled,
9402
- "onInput": handleInput,
9403
- "onFocus": handleFocus,
9404
- "onBlur": handleBlur,
9405
- "onPaste": handlePaste,
9406
- "onChange": handleChange,
9407
- "onKeypress": handleKeyPress,
9408
- "onKeydown": handleKeydown,
9409
- "onKeyup": handleKeyup,
9410
- "onCompositionstart": handleCompositionStart,
9411
- "onCompositionend": handleCompositionEnd
9412
- }), null), props.clearable && !!props.modelValue && createVNode(close$1, {
9417
+ "min": props.min
9418
+ }, bindProps.value), null), !isTextArea.value && props.clearable && !!props.modelValue && createVNode(close$1, {
9413
9419
  "onClick": clear,
9414
9420
  "class": clearCls.value
9415
- }, null), suffixIcon.value, typeof props.maxlength === "number" && props.showWordLimit && createVNode("p", {
9421
+ }, null), suffixIcon.value, typeof props.maxlength === "number" && (props.showWordLimit || isTextArea.value) && createVNode("p", {
9416
9422
  "class": getCls("max-length")
9417
9423
  }, [props.modelValue.toString().length, createTextVNode("/"), createVNode("span", null, [ceilMaxLength.value])]), isNumberInput.value && props.showControl && createVNode("div", {
9418
9424
  "class": getCls("number-control")
@@ -12487,7 +12493,7 @@ const resolveColumnWidth = (root, colgroups, autoWidth = 20) => {
12487
12493
  const {
12488
12494
  width
12489
12495
  } = root.getBoundingClientRect() || {};
12490
- let avgWidth = width;
12496
+ let avgWidth = width - 4;
12491
12497
  const avgColIndexList = [];
12492
12498
  const resolveColNumberWidth = (col, numWidth, resetAvgWidth = true) => {
12493
12499
  Object.assign(col, {
@@ -12571,11 +12577,13 @@ const resolvePaginationOption = (propPagination, defVal) => {
12571
12577
  };
12572
12578
  class TableRender {
12573
12579
  constructor(props, ctx, reactiveProp, colgroups) {
12580
+ __publicField(this, "getColumnClass", (colIndex) => `${this.uuid}-column-${colIndex}`);
12574
12581
  this.props = props;
12575
12582
  this.context = ctx;
12576
12583
  this.reactiveProp = reactiveProp;
12577
12584
  this.colgroups = colgroups;
12578
12585
  this.plugins = new TablePlugins(props, ctx);
12586
+ this.uuid = random(8);
12579
12587
  }
12580
12588
  get propActiveCols() {
12581
12589
  return this.reactiveProp.activeColumns;
@@ -12657,12 +12665,13 @@ class TableRender {
12657
12665
  "style": rowStyle,
12658
12666
  "onClick": (e) => this.handleRowClick(e, row, index, rows),
12659
12667
  "onDblclick": (e) => this.handleRowDblClick(e, row, index, rows)
12660
- }, [this.props.columns.map((column) => createVNode("td", {
12668
+ }, [this.props.columns.map((column, index2) => createVNode("td", {
12669
+ "class": this.getColumnClass(index2),
12661
12670
  "colspan": 1,
12662
12671
  "rowspan": 1
12663
12672
  }, [createVNode("div", {
12664
12673
  "class": "cell"
12665
- }, [this.renderCell(row, column, index, rows)])]))]);
12674
+ }, [this.renderCell(row, column, index2, rows)])]))]);
12666
12675
  })]);
12667
12676
  }
12668
12677
  handleRowClick(e, row, index, rows) {
@@ -12686,12 +12695,10 @@ class TableRender {
12686
12695
  const colCls = classes({
12687
12696
  active: this.isColActive(index)
12688
12697
  });
12689
- const colStyle = {
12690
- width: resolveWidth(column.calcWidth)
12691
- };
12698
+ const width = `${resolveWidth(column.calcWidth)}`.replace(/px$/i, "");
12692
12699
  return createVNode("col", {
12693
12700
  "class": colCls,
12694
- "style": colStyle
12701
+ "width": width
12695
12702
  }, null);
12696
12703
  })]);
12697
12704
  }
@@ -9263,8 +9263,9 @@ ${$(r2)}`), n2;
9263
9263
  showControl: PropTypes.bool.def(true),
9264
9264
  showClearOnlyHover: PropTypes.bool.def(false),
9265
9265
  precision: PropTypes.number.def(0).validate((val) => val >= 0 && val < 20),
9266
- modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
9267
- size: PropTypes.size()
9266
+ modelValue: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).def(""),
9267
+ size: PropTypes.size(),
9268
+ rows: PropTypes.number
9268
9269
  };
9269
9270
  const inputEvents = ["update:modelValue", "focus", "blur", "change", "clear", "input", "keypress", "keydown", "keyup", "enter", "paste"];
9270
9271
  const EventEnum = stringEnum([...inputEvents]);
@@ -9276,7 +9277,8 @@ ${$(r2)}`), n2;
9276
9277
  setup(props, ctx) {
9277
9278
  const isFocused = vue.ref(false);
9278
9279
  const isCNInput = vue.ref(false);
9279
- const inputClsPrefix = "bk-input";
9280
+ const isTextArea = vue.computed(() => props.type === "textarea");
9281
+ const inputClsPrefix = vue.computed(() => isTextArea.value ? "bk-textarea" : "bk-input");
9280
9282
  const _a = ctx.attrs, {
9281
9283
  class: cls,
9282
9284
  style
@@ -9285,13 +9287,13 @@ ${$(r2)}`), n2;
9285
9287
  "style"
9286
9288
  ]);
9287
9289
  const inputCls = vue.computed(() => classes({
9288
- [`${inputClsPrefix}--${props.size}`]: !!props.size,
9290
+ [`${inputClsPrefix.value}--${props.size}`]: !!props.size,
9289
9291
  "is-focused": isFocused.value,
9290
9292
  "is-readonly": props.readonly,
9291
9293
  "is-disabled": props.disabled,
9292
9294
  "is-simplicity": props.behavior === "simplicity",
9293
9295
  [`${cls}`]: !!cls
9294
- }, inputClsPrefix));
9296
+ }, inputClsPrefix.value));
9295
9297
  const suffixIconMap = {
9296
9298
  search: () => vue.createVNode(search, null, null),
9297
9299
  password: () => vue.createVNode(eye, {
@@ -9377,11 +9379,28 @@ ${$(r2)}`), n2;
9377
9379
  ctx.emit(EventEnum["update:modelValue"], newVal);
9378
9380
  }
9379
9381
  function getCls(name) {
9380
- return `${inputClsPrefix}--${name}`;
9382
+ return `${inputClsPrefix.value}--${name}`;
9381
9383
  }
9382
9384
  function handleVisibleChange() {
9383
9385
  pwdVisible.value = !pwdVisible.value;
9384
9386
  }
9387
+ const bindProps = vue.computed(() => ({
9388
+ value: props.modelValue,
9389
+ maxlength: props.maxlength,
9390
+ placeholder: props.placeholder,
9391
+ readonly: props.readonly,
9392
+ disabled: props.disabled,
9393
+ onInput: handleInput,
9394
+ onFocus: handleFocus,
9395
+ onBlur: handleBlur,
9396
+ onPaste: handlePaste,
9397
+ onChange: handleChange,
9398
+ onKeypress: handleKeyPress,
9399
+ onKeydown: handleKeydown,
9400
+ onKeyup: handleKeyup,
9401
+ onCompositionstart: handleCompositionStart,
9402
+ onCompositionend: handleCompositionEnd
9403
+ }));
9385
9404
  return () => {
9386
9405
  var _a2, _b, _c, _d, _e, _f;
9387
9406
  return vue.createVNode("div", {
@@ -9391,31 +9410,18 @@ ${$(r2)}`), n2;
9391
9410
  "class": getCls("prefix-area")
9392
9411
  }, [vue.createVNode("span", {
9393
9412
  "class": getCls("prefix-area--text")
9394
- }, [props.prefix])]), vue.createVNode("input", vue.mergeProps(inputAttrs, {
9395
- "class": `${inputClsPrefix}--text`,
9396
- "value": props.modelValue,
9413
+ }, [props.prefix])]), isTextArea.value ? vue.createVNode("textarea", vue.mergeProps(inputAttrs, bindProps.value, {
9414
+ "rows": props.rows
9415
+ }), null) : vue.createVNode("input", vue.mergeProps(inputAttrs, {
9416
+ "class": `${inputClsPrefix.value}--text`,
9397
9417
  "type": pwdVisible.value && props.type === "password" ? "text" : props.type,
9398
- "maxlength": props.maxlength,
9399
9418
  "step": props.step,
9400
9419
  "max": props.max,
9401
- "min": props.min,
9402
- "placeholder": props.placeholder,
9403
- "readonly": props.readonly,
9404
- "disabled": props.disabled,
9405
- "onInput": handleInput,
9406
- "onFocus": handleFocus,
9407
- "onBlur": handleBlur,
9408
- "onPaste": handlePaste,
9409
- "onChange": handleChange,
9410
- "onKeypress": handleKeyPress,
9411
- "onKeydown": handleKeydown,
9412
- "onKeyup": handleKeyup,
9413
- "onCompositionstart": handleCompositionStart,
9414
- "onCompositionend": handleCompositionEnd
9415
- }), null), props.clearable && !!props.modelValue && vue.createVNode(close$1, {
9420
+ "min": props.min
9421
+ }, bindProps.value), null), !isTextArea.value && props.clearable && !!props.modelValue && vue.createVNode(close$1, {
9416
9422
  "onClick": clear,
9417
9423
  "class": clearCls.value
9418
- }, null), suffixIcon.value, typeof props.maxlength === "number" && props.showWordLimit && vue.createVNode("p", {
9424
+ }, null), suffixIcon.value, typeof props.maxlength === "number" && (props.showWordLimit || isTextArea.value) && vue.createVNode("p", {
9419
9425
  "class": getCls("max-length")
9420
9426
  }, [props.modelValue.toString().length, vue.createTextVNode("/"), vue.createVNode("span", null, [ceilMaxLength.value])]), isNumberInput.value && props.showControl && vue.createVNode("div", {
9421
9427
  "class": getCls("number-control")
@@ -12490,7 +12496,7 @@ ${$(r2)}`), n2;
12490
12496
  const {
12491
12497
  width
12492
12498
  } = root.getBoundingClientRect() || {};
12493
- let avgWidth = width;
12499
+ let avgWidth = width - 4;
12494
12500
  const avgColIndexList = [];
12495
12501
  const resolveColNumberWidth = (col, numWidth, resetAvgWidth = true) => {
12496
12502
  Object.assign(col, {
@@ -12574,11 +12580,13 @@ ${$(r2)}`), n2;
12574
12580
  };
12575
12581
  class TableRender {
12576
12582
  constructor(props, ctx, reactiveProp, colgroups) {
12583
+ __publicField(this, "getColumnClass", (colIndex) => `${this.uuid}-column-${colIndex}`);
12577
12584
  this.props = props;
12578
12585
  this.context = ctx;
12579
12586
  this.reactiveProp = reactiveProp;
12580
12587
  this.colgroups = colgroups;
12581
12588
  this.plugins = new TablePlugins(props, ctx);
12589
+ this.uuid = random(8);
12582
12590
  }
12583
12591
  get propActiveCols() {
12584
12592
  return this.reactiveProp.activeColumns;
@@ -12660,12 +12668,13 @@ ${$(r2)}`), n2;
12660
12668
  "style": rowStyle,
12661
12669
  "onClick": (e) => this.handleRowClick(e, row, index, rows),
12662
12670
  "onDblclick": (e) => this.handleRowDblClick(e, row, index, rows)
12663
- }, [this.props.columns.map((column) => vue.createVNode("td", {
12671
+ }, [this.props.columns.map((column, index2) => vue.createVNode("td", {
12672
+ "class": this.getColumnClass(index2),
12664
12673
  "colspan": 1,
12665
12674
  "rowspan": 1
12666
12675
  }, [vue.createVNode("div", {
12667
12676
  "class": "cell"
12668
- }, [this.renderCell(row, column, index, rows)])]))]);
12677
+ }, [this.renderCell(row, column, index2, rows)])]))]);
12669
12678
  })]);
12670
12679
  }
12671
12680
  handleRowClick(e, row, index, rows) {
@@ -12689,12 +12698,10 @@ ${$(r2)}`), n2;
12689
12698
  const colCls = classes({
12690
12699
  active: this.isColActive(index)
12691
12700
  });
12692
- const colStyle = {
12693
- width: resolveWidth(column.calcWidth)
12694
- };
12701
+ const width = `${resolveWidth(column.calcWidth)}`.replace(/px$/i, "");
12695
12702
  return vue.createVNode("col", {
12696
12703
  "class": colCls,
12697
- "style": colStyle
12704
+ "width": width
12698
12705
  }, null);
12699
12706
  })]);
12700
12707
  }
package/dist/style.css CHANGED
@@ -1162,6 +1162,35 @@ optgroup {
1162
1162
  .bk-fade-transtion .bk-fade-leave-to {
1163
1163
  opacity: 0;
1164
1164
  }
1165
+ .bk-textarea {
1166
+ width: 100%;
1167
+ min-height: 70px;
1168
+ font-size: 12px;
1169
+ line-height: 20px;
1170
+ background-color: white;
1171
+ border: 1px solid #c4c6cc;
1172
+ border-radius: 2px;
1173
+ box-sizing: border-box;
1174
+ transition: all 0.3s;
1175
+ }
1176
+ .bk-textarea > textarea {
1177
+ width: 100%;
1178
+ padding: 5px 10px;
1179
+ line-height: 1.5;
1180
+ text-align: left;
1181
+ vertical-align: middle;
1182
+ border: 0;
1183
+ outline: none;
1184
+ resize: none;
1185
+ }
1186
+ .bk-textarea--max-length {
1187
+ align-self: center;
1188
+ padding-right: 10px;
1189
+ margin: 0;
1190
+ }
1191
+ .bk-textarea--max-length span {
1192
+ color: #979ba5;
1193
+ }
1165
1194
  .bk-input {
1166
1195
  display: flex;
1167
1196
  align-items: stretch;
@@ -1191,12 +1220,24 @@ optgroup {
1191
1220
  }
1192
1221
  .bk-input--large {
1193
1222
  height: 38px;
1223
+ font-size: 14px;
1224
+ }
1225
+ .bk-input--large--max-length {
1194
1226
  font-size: 16px;
1195
1227
  }
1196
1228
  .bk-input--small {
1197
1229
  height: 26px;
1198
1230
  font-size: 12px;
1199
1231
  }
1232
+ .bk-input--small--max-length {
1233
+ font-size: 12px;
1234
+ }
1235
+ .bk-input--default {
1236
+ font-size: 12px;
1237
+ }
1238
+ .bk-input--default--max-length {
1239
+ font-size: 12px;
1240
+ }
1200
1241
  .bk-input.is-focused:not(.is-readonly) {
1201
1242
  border-color: #3a84ff;
1202
1243
  outline: 0;
@@ -1234,7 +1275,6 @@ optgroup {
1234
1275
  }
1235
1276
  .bk-input--text {
1236
1277
  padding: 0 10px;
1237
- font-size: 12px;
1238
1278
  line-height: 1;
1239
1279
  color: #63656e;
1240
1280
  background-color: white;
@@ -2766,6 +2806,7 @@ optgroup {
2766
2806
  .bk-table .bk-table-body table {
2767
2807
  width: 100%;
2768
2808
  border-collapse: collapse;
2809
+ table-layout: fixed;
2769
2810
  }
2770
2811
  .bk-table .bk-table-head table th,
2771
2812
  .bk-table .bk-table-body table th,
@@ -2777,7 +2818,6 @@ optgroup {
2777
2818
  .bk-table .bk-table-body table th .cell,
2778
2819
  .bk-table .bk-table-head table td .cell,
2779
2820
  .bk-table .bk-table-body table td .cell {
2780
- height: var(--row-height);
2781
2821
  padding: 0 15px;
2782
2822
  overflow: hidden;
2783
2823
  line-height: var(--row-height);
@@ -2807,23 +2847,24 @@ optgroup {
2807
2847
  .bk-table .bk-table-footer {
2808
2848
  line-height: 40px;
2809
2849
  }
2810
- .bk-table.bordered-row .cell {
2850
+ .bk-table.bordered-row td,
2851
+ .bk-table.bordered-row th {
2811
2852
  border-bottom: 1px solid #dcdee5;
2812
2853
  }
2813
2854
  .bk-table.bordered-outer {
2814
2855
  border-right: 1px solid #dcdee5;
2815
2856
  border-left: 1px solid #dcdee5;
2816
2857
  }
2817
- .bk-table.bordered-col th .cell,
2818
- .bk-table.bordered-col td .cell {
2858
+ .bk-table.bordered-col th,
2859
+ .bk-table.bordered-col td {
2819
2860
  border-right: 1px solid #dcdee5;
2820
2861
  }
2821
- .bk-table.bordered-col th:last-child .cell,
2822
- .bk-table.bordered-col td:last-child .cell {
2862
+ .bk-table.bordered-col th:last-child,
2863
+ .bk-table.bordered-col td:last-child {
2823
2864
  border-right: none;
2824
2865
  }
2825
- .bk-table.bordered-none th .cell,
2826
- .bk-table.bordered-none td .cell {
2866
+ .bk-table.bordered-none th,
2867
+ .bk-table.bordered-none td {
2827
2868
  border-top: none;
2828
2869
  border-right: none;
2829
2870
  border-bottom: none;
@@ -4692,23 +4733,16 @@ span.bk-date-picker-cells-cell-disabled.bk-date-picker-cells-cell-selected em {
4692
4733
  scrollbar-width: thin;
4693
4734
  }
4694
4735
  .bk-virtual-render.bk-scroll-x::-webkit-scrollbar {
4695
- height: 8px;
4696
- background-color: transparent;
4697
- }
4698
- .bk-virtual-render.bk-scroll-x::-webkit-scrollbar-thumb {
4699
- background-color: #a0a0a0;
4700
- border-radius: 8px;
4736
+ height: 6px;
4701
4737
  }
4702
4738
  .bk-virtual-render.bk-scroll-y {
4703
4739
  overflow-y: auto;
4704
4740
  }
4705
4741
  .bk-virtual-render.bk-scroll-y::-webkit-scrollbar {
4706
- width: 6px;
4707
- background-color: transparent;
4742
+ width: 4px;
4708
4743
  }
4709
4744
  .bk-virtual-render.bk-scroll-y::-webkit-scrollbar-thumb {
4710
- background-color: #dcdee5;
4711
- border-radius: 6px;
4745
+ border-radius: 4px;
4712
4746
  }
4713
4747
  /* 边框色 */
4714
4748
  /* 按钮、表单边框颜色、禁用时文本颜色 */