sctj-components 1.0.4 → 1.0.6

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/README.md CHANGED
@@ -47,8 +47,9 @@ import { createApp } from 'vue'
47
47
  import ElementPlus from 'element-plus'
48
48
  import 'element-plus/dist/index.css'
49
49
  import SctjComponents from 'sctj-components'
50
- // 引入组件库样式(如果构建后生成了 style.css)
51
- import 'sctj-components/lib/style.css'
50
+ // 引入组件库样式
51
+ import 'sctj-components/style.css' // 推荐写法
52
+ // import 'sctj-components/lib/style.css' // 兼容旧写法(已在 exports 中兼容)
52
53
 
53
54
  const app = createApp(App)
54
55
  app.use(ElementPlus)
@@ -58,6 +59,12 @@ app.mount('#app')
58
59
 
59
60
  #### 按需引入
60
61
 
62
+ 即便按需引入组件,也需要全局引入一次样式:
63
+ ```javascript
64
+ import 'sctj-components/style.css' // 推荐写法
65
+ // import 'sctj-components/lib/style.css' // 兼容旧写法
66
+ ```
67
+
61
68
  组件名称均带前缀 `SCTJ`:
62
69
  ```javascript
63
70
  import { SCTJDictTag, SCTJTable, SCTJSearch } from 'sctj-components'
@@ -1643,7 +1643,7 @@ function _sfc_render(_ctx, _cache) {
1643
1643
  ]);
1644
1644
  }
1645
1645
  const SCTJTableContainer = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render], ["__scopeId", "data-v-45fb95db"]]);
1646
- const index_vue_vue_type_style_index_0_scoped_f8b93d19_lang = "";
1646
+ const index_vue_vue_type_style_index_0_scoped_0e82f8bf_lang = "";
1647
1647
  const _sfc_main$i = {
1648
1648
  __name: "index",
1649
1649
  props: {
@@ -1670,10 +1670,10 @@ const _sfc_main$i = {
1670
1670
  emits: ["update:showSearch", "queryTable"],
1671
1671
  setup(__props, { emit: emits }) {
1672
1672
  const props = __props;
1673
- const value = ref([]);
1674
- const title = ref("\u663E\u793A/\u9690\u85CF");
1675
- const open = ref(false);
1676
- const style = computed(() => {
1673
+ const value = ref$1([]);
1674
+ const title = ref$1("\u663E\u793A/\u9690\u85CF");
1675
+ const open = ref$1(false);
1676
+ const style = computed$1(() => {
1677
1677
  const ret = {};
1678
1678
  if (props.gutter) {
1679
1679
  ret.marginRight = `${props.gutter / 2}px`;
@@ -1764,16 +1764,16 @@ const _sfc_main$i = {
1764
1764
  _: 1
1765
1765
  }),
1766
1766
  createVNode(_component_el_dialog, {
1767
- title: unref(title),
1768
- modelValue: unref(open),
1769
- "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => isRef(open) ? open.value = $event : null),
1767
+ title: title.value,
1768
+ modelValue: open.value,
1769
+ "onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => open.value = $event),
1770
1770
  "append-to-body": ""
1771
1771
  }, {
1772
1772
  default: withCtx(() => [
1773
1773
  createVNode(_component_el_transfer, {
1774
1774
  titles: ["\u663E\u793A", "\u9690\u85CF"],
1775
- modelValue: unref(value),
1776
- "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => isRef(value) ? value.value = $event : null),
1775
+ modelValue: value.value,
1776
+ "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => value.value = $event),
1777
1777
  data: __props.columns,
1778
1778
  onChange: dataChange
1779
1779
  }, null, 8, ["modelValue", "data"])
@@ -1784,7 +1784,7 @@ const _sfc_main$i = {
1784
1784
  };
1785
1785
  }
1786
1786
  };
1787
- const SCTJRightToolbar = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["__scopeId", "data-v-f8b93d19"]]);
1787
+ const SCTJRightToolbar = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["__scopeId", "data-v-0e82f8bf"]]);
1788
1788
  const index_vue_vue_type_style_index_0_scoped_056cfdde_lang = "";
1789
1789
  const _hoisted_1$d = { class: "table-top-action-container" };
1790
1790
  const _sfc_main$h = {