3h1-ui 2.7.0 → 2.8.0

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/es/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { h, nextTick, createVNode, defineComponent, ref, computed, unref, watchEffect, watch, resolveComponent, openBlock, createBlock, mergeProps, withCtx, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString, createSlots, renderSlot, normalizeProps, guardReactiveProps, createElementVNode, onMounted, normalizeClass, createCommentVNode, normalizeStyle, Transition, toHandlers, useSlots, withDirectives, vShow, getCurrentInstance, inject, onUnmounted, provide, onBeforeUnmount, resolveDynamicComponent, reactive, toRef, toRefs, TransitionGroup, getCurrentScope, onScopeDispose, readonly, isVNode, shallowReactive, toRaw, shallowRef, withKeys, withModifiers, render as render$1, resolveDirective, isRef, useAttrs as useAttrs$2 } from "vue";
2
- import { Radio, Select, Tree, TreeSelect, Cascader, Transfer, Input, Tooltip, Skeleton, Popover, Pagination, Empty, Button as Button$1, Table as Table$1, Form, FormItem, DatePicker, InputNumber, AutoComplete, Switch, Checkbox, Slider, Rate, TimePicker, Divider, Col, Popconfirm, Modal as Modal$2, Row, Dropdown, Menu, MenuItem, MenuDivider, Spin, PageHeader, Image, Badge, Tag, FormItemRest, Drawer, Space, Upload, Avatar } from "ant-design-vue";
2
+ import { Radio, Select, Tree, TreeSelect, Cascader, Transfer, Input, Tooltip, Skeleton, Popover, Pagination, Empty, Button as Button$1, Table as Table$1, Form, FormItem, DatePicker, InputNumber, AutoComplete, Switch, Checkbox, Slider, Rate, TimePicker, Col, Popconfirm, Modal as Modal$2, Row, Dropdown, Menu, MenuItem, MenuDivider, Divider as Divider$1, Spin, PageHeader, Space, Image, Badge, Tag, FormItemRest, Drawer, Upload, Avatar } from "ant-design-vue";
3
3
  import { propTypes, isFunction as isFunction$4, isString as isString$3, isArray as isArray$3, getSlot as getSlot$1, addClass as addClass$1, removeClass as removeClass$1, getPopupContainer as getPopupContainer$1, triggerWindowResize, off, on, addResizeListener, removeResizeListener, isNumber as isNumber$2, isBoolean, isNull, extendSlots as extendSlots$1, withInstall as withInstall$2, isObject as isObject$3, dateUtil, isNullOrUnDef, isDef as isDef$1, error as error$1, deepMerge as deepMerge$1, getDynamicProps, buildProps, createBEM, forEach as forEach$1, isClient as isClient$1, filter, treeToList, eachTree, isEmpty, isServer, formatToDate, isMap as isMap$2, buildUUID, findNodeAll, getViewportOffset, warn as warn$1, isNullAndUnDef, dataURLtoBlob } from "@shy-plugins/utils";
4
4
  import { useAttrs as useAttrs$1, useRuleFormItem, useTimeoutFn as useTimeoutFn$2, useScrollTo as useScrollTo$1, useIntersectionObserver, useCopyToClipboard, useMessage, usePagination as usePagination$2, createContext as createContext$1, useContext as useContext$2, useBreakpoint, useI18n as useI18n$1, useContentHeight, useDesign as useDesign$1, useWindowSizeFn as useWindowSizeFn$1, onMountedOrActivated, useEventListener as useEventListener$1 } from "@shy-plugins/use";
5
5
  import { zxcvbn } from "@zxcvbn-ts/core";
@@ -1679,6 +1679,21 @@ var SmallDashOutlined = function SmallDashOutlined2(props2, context) {
1679
1679
  SmallDashOutlined.displayName = "SmallDashOutlined";
1680
1680
  SmallDashOutlined.inheritAttrs = false;
1681
1681
  const SmallDashOutlined$1 = SmallDashOutlined;
1682
+ const Divider = /* @__PURE__ */ defineComponent({
1683
+ props: {
1684
+ label: {
1685
+ type: String,
1686
+ default: () => ""
1687
+ }
1688
+ },
1689
+ setup(props2, {
1690
+ attrs
1691
+ }) {
1692
+ return () => createVNode("div", {
1693
+ "class": "shy-form-divider"
1694
+ }, [props2.label]);
1695
+ }
1696
+ });
1682
1697
  var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
1683
1698
  const freeGlobal$1 = freeGlobal;
1684
1699
  var freeSelf = typeof self == "object" && self && self.Object === Object && self;
@@ -7275,6 +7290,7 @@ const _sfc_main$M = /* @__PURE__ */ defineComponent({
7275
7290
  });
7276
7291
  const Table_vue_vue_type_style_index_0_scoped_7465b460_lang = "";
7277
7292
  const Table = /* @__PURE__ */ _export_sfc(_sfc_main$M, [["__scopeId", "data-v-7465b460"]]);
7293
+ console.log(Divider);
7278
7294
  const componentMap$2 = /* @__PURE__ */ new Map();
7279
7295
  componentMap$2.set("Input", Input);
7280
7296
  componentMap$2.set("InputGroup", Input.Group);
@@ -7482,7 +7498,8 @@ const _sfc_main$L = /* @__PURE__ */ defineComponent({
7482
7498
  type: "horizontal"
7483
7499
  }, componentProps, {
7484
7500
  orientation: "left",
7485
- plain: true
7501
+ plain: true,
7502
+ label: (schema2 == null ? void 0 : schema2.label) || ""
7486
7503
  });
7487
7504
  }
7488
7505
  if (schema2.component === "Input") {
@@ -10253,7 +10270,7 @@ function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
10253
10270
  ], 64);
10254
10271
  }
10255
10272
  const BasicForm = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["render", _sfc_render$n]]);
10256
- const index$3 = "";
10273
+ const index$4 = "";
10257
10274
  function useComponentRegister(compName, comp) {
10258
10275
  add(compName, comp);
10259
10276
  tryOnUnmounted(() => {
@@ -10855,7 +10872,7 @@ function useTree(treeDataRef, getFieldNames) {
10855
10872
  function _isSlot$1(s) {
10856
10873
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
10857
10874
  }
10858
- const prefixCls = "context-menu";
10875
+ const prefixCls$1 = "context-menu";
10859
10876
  const props$4 = {
10860
10877
  width: {
10861
10878
  type: Number,
@@ -10974,11 +10991,11 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
10974
10991
  if (!children || children.length === 0) {
10975
10992
  return createVNode(Fragment, null, [createVNode(Menu.Item, {
10976
10993
  "disabled": disabled,
10977
- "class": `${prefixCls}__item`,
10994
+ "class": `${prefixCls$1}__item`,
10978
10995
  "key": label
10979
10996
  }, {
10980
10997
  default: () => [createVNode(ItemContent, contentProps, null)]
10981
- }), divider ? createVNode(Divider, {
10998
+ }), divider ? createVNode(Divider$1, {
10982
10999
  "key": `d-${label}`
10983
11000
  }, null) : null]);
10984
11001
  }
@@ -10987,7 +11004,7 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
10987
11004
  return createVNode(Menu.SubMenu, {
10988
11005
  "key": label,
10989
11006
  "disabled": disabled,
10990
- "popupClassName": `${prefixCls}__popup`
11007
+ "popupClassName": `${prefixCls$1}__popup`
10991
11008
  }, {
10992
11009
  title: () => createVNode(ItemContent, contentProps, null),
10993
11010
  default: () => renderMenuItem(children)
@@ -11003,7 +11020,7 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
11003
11020
  items
11004
11021
  } = props2;
11005
11022
  return createVNode("div", {
11006
- "class": prefixCls
11023
+ "class": prefixCls$1
11007
11024
  }, [createVNode(Menu, {
11008
11025
  "inlineIndent": 12,
11009
11026
  "mode": "vertical",
@@ -11469,7 +11486,7 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
11469
11486
  };
11470
11487
  }
11471
11488
  });
11472
- const index$2 = "";
11489
+ const index$3 = "";
11473
11490
  const _sfc_main$v = /* @__PURE__ */ defineComponent({
11474
11491
  __name: "DeptTree",
11475
11492
  props: {
@@ -11715,6 +11732,64 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
11715
11732
  ], 2);
11716
11733
  }
11717
11734
  const PageWrapper = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["render", _sfc_render$l]]);
11735
+ const prefixCls = "shy-basic-page-second";
11736
+ const PageSecond = /* @__PURE__ */ defineComponent({
11737
+ props: {
11738
+ title: {
11739
+ type: String,
11740
+ default: () => "Title"
11741
+ },
11742
+ isShowCancelButton: {
11743
+ type: Boolean,
11744
+ default: () => true
11745
+ },
11746
+ isShowConfirmButton: {
11747
+ type: Boolean,
11748
+ default: () => true
11749
+ }
11750
+ },
11751
+ emits: ["click-return"],
11752
+ setup(props2, {
11753
+ slots,
11754
+ emit
11755
+ }) {
11756
+ const handleClick = () => {
11757
+ emit("click-return");
11758
+ };
11759
+ return () => {
11760
+ var _a2;
11761
+ return createVNode("div", {
11762
+ "class": `${prefixCls}-wrapper`
11763
+ }, [createVNode("div", {
11764
+ "class": `${prefixCls}-header`
11765
+ }, [createVNode(ArrowLeftOutlined$1, {
11766
+ "class": `${prefixCls}-header-icon`,
11767
+ "onClick": handleClick
11768
+ }, null), createVNode("div", {
11769
+ "class": `${prefixCls}-header-title`
11770
+ }, [props2.title])]), createVNode("div", {
11771
+ "class": `${prefixCls}-body`
11772
+ }, [(_a2 = slots.default) == null ? void 0 : _a2.call(slots)]), createVNode("div", {
11773
+ "class": `${prefixCls}-footer`
11774
+ }, [createVNode(Space, null, {
11775
+ default: () => {
11776
+ var _a3, _b, _c;
11777
+ return [(_a3 = slots.beforeCancelButton) == null ? void 0 : _a3.call(slots), props2.isShowCancelButton ? createVNode(_sfc_main$K, {
11778
+ "size": "small"
11779
+ }, {
11780
+ default: () => [createTextVNode("取消")]
11781
+ }) : null, (_b = slots.afterCancelButton) == null ? void 0 : _b.call(slots), props2.isShowConfirmButton ? createVNode(_sfc_main$K, {
11782
+ "type": "primary",
11783
+ "size": "small"
11784
+ }, {
11785
+ default: () => [createTextVNode("确定")]
11786
+ }) : null, (_c = slots.beforeConfirmButton) == null ? void 0 : _c.call(slots)];
11787
+ }
11788
+ })])]);
11789
+ };
11790
+ }
11791
+ });
11792
+ const index$2 = "";
11718
11793
  const PageWrapperFixedHeightKey = "PageWrapperFixedHeight";
11719
11794
  const _sfc_main$s = defineComponent({
11720
11795
  name: "EditTableHeaderIcon",
@@ -11850,6 +11925,7 @@ const DEFAULT_FILTER_FN = defaultFilterFn;
11850
11925
  let DEFAULT_ALIGN = "left";
11851
11926
  const INDEX_COLUMN_FLAG = "INDEX";
11852
11927
  const ACTION_COLUMN_FLAG = "ACTION";
11928
+ const ACTION_COLUMN_WIDTH = 160;
11853
11929
  const setConstConfig = (config) => {
11854
11930
  DEFAULT_ALIGN = config.align;
11855
11931
  };
@@ -12607,6 +12683,7 @@ function handleActionColumn(propsRef, columns) {
12607
12683
  columns.push({
12608
12684
  ...columns[hasIndex],
12609
12685
  fixed: "right",
12686
+ width: ACTION_COLUMN_WIDTH,
12610
12687
  ...actionColumn,
12611
12688
  flag: ACTION_COLUMN_FLAG
12612
12689
  });
@@ -13524,7 +13601,7 @@ const _sfc_main$p = defineComponent({
13524
13601
  CheckboxGroup: Checkbox.Group,
13525
13602
  DragOutlined: DragOutlined$1,
13526
13603
  ScrollContainer: ScrollContainer$1,
13527
- Divider,
13604
+ Divider: Divider$1,
13528
13605
  Icon: Icon2
13529
13606
  },
13530
13607
  emits: ["columns-change"],
@@ -14489,6 +14566,8 @@ const basicProps$3 = reactive({
14489
14566
  },
14490
14567
  // 使用搜索表单
14491
14568
  useSearchForm: propTypes.bool,
14569
+ // 使用表格内边距
14570
+ useTableWrapper: propTypes.bool.def(true),
14492
14571
  // 表单配置
14493
14572
  formConfig: {
14494
14573
  type: Object,
@@ -14731,6 +14810,7 @@ const _sfc_main$i = defineComponent({
14731
14810
  attrs.class,
14732
14811
  {
14733
14812
  [`${prefixCls2}-form-container`]: values.useSearchForm,
14813
+ [`${prefixCls2}-table-wrapper`]: values.useTableWrapper,
14734
14814
  [`${prefixCls2}--inset`]: values.inset
14735
14815
  }
14736
14816
  ];
@@ -14821,7 +14901,8 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
14821
14901
  const _component_Table = resolveComponent("Table");
14822
14902
  return openBlock(), createElementBlock("div", {
14823
14903
  ref: "wrapRef",
14824
- class: normalizeClass(_ctx.getWrapperClass)
14904
+ class: normalizeClass(_ctx.getWrapperClass),
14905
+ style: { "background-color": "#fff" }
14825
14906
  }, [
14826
14907
  _ctx.getBindValues.useSearchForm ? (openBlock(), createBlock(_component_BasicForm, mergeProps({
14827
14908
  key: 0,
@@ -14999,7 +15080,7 @@ const _sfc_main$g = defineComponent({
14999
15080
  components: {
15000
15081
  Icon: Icon2,
15001
15082
  PopConfirmButton: _sfc_main$J,
15002
- Divider,
15083
+ Divider: Divider$1,
15003
15084
  Dropdown: _sfc_main$h,
15004
15085
  MoreOutlined: MoreOutlined$1,
15005
15086
  Tooltip
@@ -15717,6 +15798,19 @@ const basicProps$2 = {
15717
15798
  default: () => ({})
15718
15799
  }
15719
15800
  };
15801
+ const DescriptionGroup = /* @__PURE__ */ defineComponent({
15802
+ props: {
15803
+ label: {
15804
+ type: String,
15805
+ default: () => ""
15806
+ }
15807
+ },
15808
+ setup(props2) {
15809
+ return () => createVNode("div", {
15810
+ "class": "shy-form-divider"
15811
+ }, [props2.label]);
15812
+ }
15813
+ });
15720
15814
  const Description = /* @__PURE__ */ defineComponent({
15721
15815
  name: "Description",
15722
15816
  props: basicProps$2,
@@ -15742,19 +15836,31 @@ const Description = /* @__PURE__ */ defineComponent({
15742
15836
  const rows = computed(() => {
15743
15837
  return getProps.value.schema.map((item) => {
15744
15838
  var _a2, _b;
15745
- return createVNode("div", {
15746
- "class": `${prefixCls2}-row`,
15747
- "style": {
15748
- flex: `0 0 ${(((_a2 = item == null ? void 0 : item.colProps) == null ? void 0 : _a2.span) || basicColProps) / 24 * 100}%`
15749
- }
15750
- }, [createVNode("span", {
15751
- "style": {
15752
- width: `${getProps.value.labelWidth}px`
15753
- },
15754
- "class": `${prefixCls2}-label`
15755
- }, [slots[`${item.field}Label`] ? slots[`${item.field}Label`]() : item.label, ((_b = getProps.value) == null ? void 0 : _b.isShowColon) ? ":" : ""]), createVNode("span", {
15756
- "class": `${prefixCls2}-value`
15757
- }, [slots[`${item.field}Value`] ? slots[`${item.field}Value`]() : getProps.value.data[item.field]])]);
15839
+ if ((item == null ? void 0 : item.component) === "Divider") {
15840
+ return createVNode(Divider$1, null, null);
15841
+ } else if ((item == null ? void 0 : item.component) === "Group") {
15842
+ return createVNode("div", {
15843
+ "style": {
15844
+ flex: "0 0 100%"
15845
+ }
15846
+ }, [createVNode(DescriptionGroup, {
15847
+ "label": item == null ? void 0 : item.label
15848
+ }, null)]);
15849
+ } else {
15850
+ return createVNode("div", {
15851
+ "class": `${prefixCls2}-row`,
15852
+ "style": {
15853
+ flex: `0 0 ${(((_a2 = item == null ? void 0 : item.colProps) == null ? void 0 : _a2.span) || basicColProps) / 24 * 100}%`
15854
+ }
15855
+ }, [createVNode("span", {
15856
+ "style": {
15857
+ width: `${getProps.value.labelWidth}px`
15858
+ },
15859
+ "class": `${prefixCls2}-label`
15860
+ }, [slots[`${item.field}Label`] ? slots[`${item.field}Label`]() : item.label, ((_b = getProps.value) == null ? void 0 : _b.isShowColon) ? ":" : ""]), createVNode("span", {
15861
+ "class": `${prefixCls2}-value`
15862
+ }, [slots[`${item.field}Value`] ? slots[`${item.field}Value`]() : getProps.value.data[item.field]])]);
15863
+ }
15758
15864
  });
15759
15865
  });
15760
15866
  emit("register", {
@@ -20436,6 +20542,7 @@ export {
20436
20542
  LazyContainer,
20437
20543
  Loading,
20438
20544
  PageFooter,
20545
+ PageSecond,
20439
20546
  PageWrapper,
20440
20547
  PageWrapperFixedHeightKey,
20441
20548
  _sfc_main$J as PopConfirmButton,
package/es/style.css CHANGED
@@ -25108,6 +25108,24 @@ span.iconify {
25108
25108
  }
25109
25109
  .shy-form-action .ant-form-item-control-input-content button {
25110
25110
  margin: 0 5px;
25111
+ }
25112
+ .shy-form-divider {
25113
+ display: flex;
25114
+ align-items: center;
25115
+ height: 30px;
25116
+ font-size: 14px;
25117
+ font-weight: 600;
25118
+ font-family: PingFangSC-Semibold;
25119
+ color: #131415;
25120
+ line-height: 16px;
25121
+ }
25122
+ .shy-form-divider::after {
25123
+ display: inline-block;
25124
+ margin-left: 8px;
25125
+ width: 2px;
25126
+ height: 14px;
25127
+ content: '';
25128
+ background: #2991ff;
25111
25129
  }.shy-search[data-v-6d3f2554] {
25112
25130
  position: relative;
25113
25131
  display: flex;
@@ -25243,6 +25261,37 @@ span.iconify {
25243
25261
  }
25244
25262
  .shy-page-wrapper--dense .shy-page-wrapper-content {
25245
25263
  margin: 0;
25264
+ }.shy-basic-page-second-wrapper {
25265
+ height: 100%;
25266
+ padding: 15px;
25267
+ overflow: hidden;
25268
+ }
25269
+ .shy-basic-page-second-header {
25270
+ display: flex;
25271
+ align-items: center;
25272
+ line-height: 40px;
25273
+ height: 40px;
25274
+ }
25275
+ .shy-basic-page-second-header-icon {
25276
+ font-size: 16px;
25277
+ }
25278
+ .shy-basic-page-second-header-title {
25279
+ margin-left: 30px;
25280
+ font-size: 20px;
25281
+ font-family: PingFangSC-Regular;
25282
+ font-weight: 400;
25283
+ color: #131415;
25284
+ }
25285
+ .shy-basic-page-second-body {
25286
+ height: calc(100% - 40px - 50px);
25287
+ overflow: auto;
25288
+ }
25289
+ .shy-basic-page-second-footer {
25290
+ display: flex;
25291
+ justify-content: flex-end;
25292
+ align-items: flex-end;
25293
+ height: 50px;
25294
+ flex: none;
25246
25295
  }.shy-basic-table-header-cell__help {
25247
25296
  margin-left: 8px;
25248
25297
  color: rgba(0, 0, 0, 0.65) !important;
@@ -25429,6 +25478,9 @@ span.iconify {
25429
25478
  width: 100%;
25430
25479
  height: 100%;
25431
25480
  }
25481
+ .shy-basic-table-table-wrapper {
25482
+ padding: 15px;
25483
+ }
25432
25484
  .shy-basic-table-row__striped td {
25433
25485
  background-color: #fafafa;
25434
25486
  }
@@ -25512,7 +25564,6 @@ span.iconify {
25512
25564
  }.shy-basic-description-wrapper {
25513
25565
  display: flex;
25514
25566
  flex-flow: row wrap;
25515
- height: 100%;
25516
25567
  overflow-y: auto;
25517
25568
  }
25518
25569
  .shy-basic-description-label {
@@ -25532,6 +25583,24 @@ span.iconify {
25532
25583
  display: flex;
25533
25584
  margin: 8px 0;
25534
25585
  overflow: hidden;
25586
+ }
25587
+ .shy-form-divider {
25588
+ display: flex;
25589
+ align-items: center;
25590
+ height: 30px;
25591
+ font-size: 14px;
25592
+ font-weight: 600;
25593
+ font-family: PingFangSC-Semibold;
25594
+ color: #131415;
25595
+ line-height: 16px;
25596
+ }
25597
+ .shy-form-divider::after {
25598
+ display: inline-block;
25599
+ margin-left: 8px;
25600
+ width: 2px;
25601
+ height: 14px;
25602
+ content: '';
25603
+ background: #2991ff;
25535
25604
  }.shy-basic-drawer-footer {
25536
25605
  position: absolute;
25537
25606
  bottom: 0;
@@ -0,0 +1,14 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ label: {
3
+ type: StringConstructor;
4
+ default: () => string;
5
+ };
6
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
7
+ label: {
8
+ type: StringConstructor;
9
+ default: () => string;
10
+ };
11
+ }>>, {
12
+ label: string;
13
+ }>;
14
+ export default _default;
@@ -1,10 +1,11 @@
1
1
  import { PropType } from 'vue';
2
2
  export interface Schema {
3
- label: string;
4
- field: string;
3
+ label?: string;
4
+ field?: string;
5
5
  colProps?: {
6
6
  span: number;
7
7
  };
8
+ component?: 'Divider' | 'Group';
8
9
  }
9
10
  export declare const basicColProps = 24;
10
11
  export declare const basicProps: {
@@ -1,4 +1,5 @@
1
1
  import PageFooter from './src/PageFooter.vue';
2
2
  import PageWrapper from './src/PageWrapper.vue';
3
- export { PageFooter, PageWrapper };
3
+ import PageSecond from './src/PageSecond';
4
+ export { PageFooter, PageWrapper, PageSecond };
4
5
  export declare const PageWrapperFixedHeightKey = "PageWrapperFixedHeight";
@@ -0,0 +1,34 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ title: {
3
+ type: StringConstructor;
4
+ default: () => string;
5
+ };
6
+ isShowCancelButton: {
7
+ type: BooleanConstructor;
8
+ default: () => boolean;
9
+ };
10
+ isShowConfirmButton: {
11
+ type: BooleanConstructor;
12
+ default: () => boolean;
13
+ };
14
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "click-return"[], "click-return", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
15
+ title: {
16
+ type: StringConstructor;
17
+ default: () => string;
18
+ };
19
+ isShowCancelButton: {
20
+ type: BooleanConstructor;
21
+ default: () => boolean;
22
+ };
23
+ isShowConfirmButton: {
24
+ type: BooleanConstructor;
25
+ default: () => boolean;
26
+ };
27
+ }>> & {
28
+ "onClick-return"?: (...args: any[]) => any;
29
+ }, {
30
+ title: string;
31
+ isShowCancelButton: boolean;
32
+ isShowConfirmButton: boolean;
33
+ }>;
34
+ export default _default;
@@ -20,4 +20,5 @@ export declare const DEFAULT_FILTER_FN: (data: Partial<Recordable<string[]>>) =>
20
20
  export declare let DEFAULT_ALIGN: string;
21
21
  export declare const INDEX_COLUMN_FLAG = "INDEX";
22
22
  export declare const ACTION_COLUMN_FLAG = "ACTION";
23
+ export declare const ACTION_COLUMN_WIDTH = 160;
23
24
  export declare const setConstConfig: (config: any) => void;
@@ -341,6 +341,41 @@ export declare const basicProps: {
341
341
  default?: boolean | object | (() => boolean) | ((props: Record<string, unknown>) => boolean);
342
342
  validator?: (value: boolean) => boolean;
343
343
  };
344
+ useTableWrapper: {
345
+ readonly validate: (fn: import("vue-types/dist/types").ValidatorFunction<unknown>) => import("vue-types").VueTypeValidableDef<boolean> & {
346
+ default: boolean;
347
+ } & {
348
+ validator: import("vue-types/dist/types").ValidatorFunction<unknown>;
349
+ };
350
+ _vueTypes_name: string;
351
+ type?: import("vue-types/dist/types").Prop<boolean> | import("vue-types/dist/types").Prop<boolean>[];
352
+ readonly def: (def?: boolean) => import("vue-types").VueTypeValidableDef<boolean> & {
353
+ default: boolean;
354
+ };
355
+ readonly isRequired: {
356
+ readonly validate: (fn: import("vue-types/dist/types").ValidatorFunction<unknown>) => import("vue-types").VueTypeValidableDef<boolean> & {
357
+ default: boolean;
358
+ } & {
359
+ required: true;
360
+ } & {
361
+ validator: import("vue-types/dist/types").ValidatorFunction<unknown>;
362
+ };
363
+ _vueTypes_name: string;
364
+ type?: import("vue-types/dist/types").Prop<boolean> | import("vue-types/dist/types").Prop<boolean>[];
365
+ readonly def: (def?: boolean) => import("vue-types").VueTypeValidableDef<boolean> & {
366
+ default: boolean;
367
+ } & {
368
+ required: true;
369
+ };
370
+ readonly isRequired: any;
371
+ required: true;
372
+ default: (boolean | object | (() => boolean) | ((props: Record<string, unknown>) => boolean)) & boolean;
373
+ validator?: (value: boolean) => boolean;
374
+ };
375
+ required?: boolean;
376
+ default: (boolean | object | (() => boolean) | ((props: Record<string, unknown>) => boolean)) & boolean;
377
+ validator?: (value: boolean) => boolean;
378
+ };
344
379
  formConfig: {
345
380
  type: ((new (...args: any[]) => Partial<FormProps>) | (() => Partial<FormProps>)) | ((new (...args: any[]) => Partial<FormProps>) | (() => Partial<FormProps>))[];
346
381
  default: any;
package/lib/index.js CHANGED
@@ -1681,6 +1681,21 @@ var SmallDashOutlined = function SmallDashOutlined2(props2, context) {
1681
1681
  SmallDashOutlined.displayName = "SmallDashOutlined";
1682
1682
  SmallDashOutlined.inheritAttrs = false;
1683
1683
  const SmallDashOutlined$1 = SmallDashOutlined;
1684
+ const Divider = /* @__PURE__ */ vue.defineComponent({
1685
+ props: {
1686
+ label: {
1687
+ type: String,
1688
+ default: () => ""
1689
+ }
1690
+ },
1691
+ setup(props2, {
1692
+ attrs
1693
+ }) {
1694
+ return () => vue.createVNode("div", {
1695
+ "class": "shy-form-divider"
1696
+ }, [props2.label]);
1697
+ }
1698
+ });
1684
1699
  var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
1685
1700
  const freeGlobal$1 = freeGlobal;
1686
1701
  var freeSelf = typeof self == "object" && self && self.Object === Object && self;
@@ -7277,6 +7292,7 @@ const _sfc_main$M = /* @__PURE__ */ vue.defineComponent({
7277
7292
  });
7278
7293
  const Table_vue_vue_type_style_index_0_scoped_7465b460_lang = "";
7279
7294
  const Table = /* @__PURE__ */ _export_sfc(_sfc_main$M, [["__scopeId", "data-v-7465b460"]]);
7295
+ console.log(Divider);
7280
7296
  const componentMap$2 = /* @__PURE__ */ new Map();
7281
7297
  componentMap$2.set("Input", antDesignVue.Input);
7282
7298
  componentMap$2.set("InputGroup", antDesignVue.Input.Group);
@@ -7310,7 +7326,7 @@ componentMap$2.set("StrengthMeter", StrengthMeter);
7310
7326
  componentMap$2.set("IconPicker", _sfc_main$P);
7311
7327
  componentMap$2.set("InputCountDown", CountdownInput);
7312
7328
  componentMap$2.set("Table", Table);
7313
- componentMap$2.set("Divider", antDesignVue.Divider);
7329
+ componentMap$2.set("Divider", Divider);
7314
7330
  function add(compName, component) {
7315
7331
  componentMap$2.set(compName, component);
7316
7332
  }
@@ -7484,7 +7500,8 @@ const _sfc_main$L = /* @__PURE__ */ vue.defineComponent({
7484
7500
  type: "horizontal"
7485
7501
  }, componentProps, {
7486
7502
  orientation: "left",
7487
- plain: true
7503
+ plain: true,
7504
+ label: (schema2 == null ? void 0 : schema2.label) || ""
7488
7505
  });
7489
7506
  }
7490
7507
  if (schema2.component === "Input") {
@@ -7731,7 +7748,7 @@ const _sfc_main$L = /* @__PURE__ */ vue.defineComponent({
7731
7748
  return vue.createVNode(antDesignVue.Col, {
7732
7749
  "span": 24
7733
7750
  }, {
7734
- default: () => [vue.createVNode(antDesignVue.Divider, vue.unref(getComponentsProps), _isSlot$3(_slot = renderLabelHelpMessage()) ? _slot : {
7751
+ default: () => [vue.createVNode(Divider, vue.unref(getComponentsProps), _isSlot$3(_slot = renderLabelHelpMessage()) ? _slot : {
7735
7752
  default: () => [_slot]
7736
7753
  })]
7737
7754
  });
@@ -10255,7 +10272,7 @@ function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
10255
10272
  ], 64);
10256
10273
  }
10257
10274
  const BasicForm = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["render", _sfc_render$n]]);
10258
- const index$3 = "";
10275
+ const index$4 = "";
10259
10276
  function useComponentRegister(compName, comp) {
10260
10277
  add(compName, comp);
10261
10278
  tryOnUnmounted(() => {
@@ -10857,7 +10874,7 @@ function useTree(treeDataRef, getFieldNames) {
10857
10874
  function _isSlot$1(s) {
10858
10875
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
10859
10876
  }
10860
- const prefixCls = "context-menu";
10877
+ const prefixCls$1 = "context-menu";
10861
10878
  const props$4 = {
10862
10879
  width: {
10863
10880
  type: Number,
@@ -10976,7 +10993,7 @@ const _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
10976
10993
  if (!children || children.length === 0) {
10977
10994
  return vue.createVNode(vue.Fragment, null, [vue.createVNode(antDesignVue.Menu.Item, {
10978
10995
  "disabled": disabled,
10979
- "class": `${prefixCls}__item`,
10996
+ "class": `${prefixCls$1}__item`,
10980
10997
  "key": label
10981
10998
  }, {
10982
10999
  default: () => [vue.createVNode(ItemContent, contentProps, null)]
@@ -10989,7 +11006,7 @@ const _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
10989
11006
  return vue.createVNode(antDesignVue.Menu.SubMenu, {
10990
11007
  "key": label,
10991
11008
  "disabled": disabled,
10992
- "popupClassName": `${prefixCls}__popup`
11009
+ "popupClassName": `${prefixCls$1}__popup`
10993
11010
  }, {
10994
11011
  title: () => vue.createVNode(ItemContent, contentProps, null),
10995
11012
  default: () => renderMenuItem(children)
@@ -11005,7 +11022,7 @@ const _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
11005
11022
  items
11006
11023
  } = props2;
11007
11024
  return vue.createVNode("div", {
11008
- "class": prefixCls
11025
+ "class": prefixCls$1
11009
11026
  }, [vue.createVNode(antDesignVue.Menu, {
11010
11027
  "inlineIndent": 12,
11011
11028
  "mode": "vertical",
@@ -11471,7 +11488,7 @@ const _sfc_main$w = /* @__PURE__ */ vue.defineComponent({
11471
11488
  };
11472
11489
  }
11473
11490
  });
11474
- const index$2 = "";
11491
+ const index$3 = "";
11475
11492
  const _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
11476
11493
  __name: "DeptTree",
11477
11494
  props: {
@@ -11717,6 +11734,64 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
11717
11734
  ], 2);
11718
11735
  }
11719
11736
  const PageWrapper = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["render", _sfc_render$l]]);
11737
+ const prefixCls = "shy-basic-page-second";
11738
+ const PageSecond = /* @__PURE__ */ vue.defineComponent({
11739
+ props: {
11740
+ title: {
11741
+ type: String,
11742
+ default: () => "Title"
11743
+ },
11744
+ isShowCancelButton: {
11745
+ type: Boolean,
11746
+ default: () => true
11747
+ },
11748
+ isShowConfirmButton: {
11749
+ type: Boolean,
11750
+ default: () => true
11751
+ }
11752
+ },
11753
+ emits: ["click-return"],
11754
+ setup(props2, {
11755
+ slots,
11756
+ emit
11757
+ }) {
11758
+ const handleClick = () => {
11759
+ emit("click-return");
11760
+ };
11761
+ return () => {
11762
+ var _a2;
11763
+ return vue.createVNode("div", {
11764
+ "class": `${prefixCls}-wrapper`
11765
+ }, [vue.createVNode("div", {
11766
+ "class": `${prefixCls}-header`
11767
+ }, [vue.createVNode(ArrowLeftOutlined$1, {
11768
+ "class": `${prefixCls}-header-icon`,
11769
+ "onClick": handleClick
11770
+ }, null), vue.createVNode("div", {
11771
+ "class": `${prefixCls}-header-title`
11772
+ }, [props2.title])]), vue.createVNode("div", {
11773
+ "class": `${prefixCls}-body`
11774
+ }, [(_a2 = slots.default) == null ? void 0 : _a2.call(slots)]), vue.createVNode("div", {
11775
+ "class": `${prefixCls}-footer`
11776
+ }, [vue.createVNode(antDesignVue.Space, null, {
11777
+ default: () => {
11778
+ var _a3, _b, _c;
11779
+ return [(_a3 = slots.beforeCancelButton) == null ? void 0 : _a3.call(slots), props2.isShowCancelButton ? vue.createVNode(_sfc_main$K, {
11780
+ "size": "small"
11781
+ }, {
11782
+ default: () => [vue.createTextVNode("取消")]
11783
+ }) : null, (_b = slots.afterCancelButton) == null ? void 0 : _b.call(slots), props2.isShowConfirmButton ? vue.createVNode(_sfc_main$K, {
11784
+ "type": "primary",
11785
+ "size": "small"
11786
+ }, {
11787
+ default: () => [vue.createTextVNode("确定")]
11788
+ }) : null, (_c = slots.beforeConfirmButton) == null ? void 0 : _c.call(slots)];
11789
+ }
11790
+ })])]);
11791
+ };
11792
+ }
11793
+ });
11794
+ const index$2 = "";
11720
11795
  const PageWrapperFixedHeightKey = "PageWrapperFixedHeight";
11721
11796
  const _sfc_main$s = vue.defineComponent({
11722
11797
  name: "EditTableHeaderIcon",
@@ -11852,6 +11927,7 @@ const DEFAULT_FILTER_FN = defaultFilterFn;
11852
11927
  let DEFAULT_ALIGN = "left";
11853
11928
  const INDEX_COLUMN_FLAG = "INDEX";
11854
11929
  const ACTION_COLUMN_FLAG = "ACTION";
11930
+ const ACTION_COLUMN_WIDTH = 160;
11855
11931
  const setConstConfig = (config) => {
11856
11932
  DEFAULT_ALIGN = config.align;
11857
11933
  };
@@ -12609,6 +12685,7 @@ function handleActionColumn(propsRef, columns) {
12609
12685
  columns.push({
12610
12686
  ...columns[hasIndex],
12611
12687
  fixed: "right",
12688
+ width: ACTION_COLUMN_WIDTH,
12612
12689
  ...actionColumn,
12613
12690
  flag: ACTION_COLUMN_FLAG
12614
12691
  });
@@ -14491,6 +14568,8 @@ const basicProps$3 = vue.reactive({
14491
14568
  },
14492
14569
  // 使用搜索表单
14493
14570
  useSearchForm: utils.propTypes.bool,
14571
+ // 使用表格内边距
14572
+ useTableWrapper: utils.propTypes.bool.def(true),
14494
14573
  // 表单配置
14495
14574
  formConfig: {
14496
14575
  type: Object,
@@ -14733,6 +14812,7 @@ const _sfc_main$i = vue.defineComponent({
14733
14812
  attrs.class,
14734
14813
  {
14735
14814
  [`${prefixCls2}-form-container`]: values.useSearchForm,
14815
+ [`${prefixCls2}-table-wrapper`]: values.useTableWrapper,
14736
14816
  [`${prefixCls2}--inset`]: values.inset
14737
14817
  }
14738
14818
  ];
@@ -14823,7 +14903,8 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
14823
14903
  const _component_Table = vue.resolveComponent("Table");
14824
14904
  return vue.openBlock(), vue.createElementBlock("div", {
14825
14905
  ref: "wrapRef",
14826
- class: vue.normalizeClass(_ctx.getWrapperClass)
14906
+ class: vue.normalizeClass(_ctx.getWrapperClass),
14907
+ style: { "background-color": "#fff" }
14827
14908
  }, [
14828
14909
  _ctx.getBindValues.useSearchForm ? (vue.openBlock(), vue.createBlock(_component_BasicForm, vue.mergeProps({
14829
14910
  key: 0,
@@ -15719,6 +15800,19 @@ const basicProps$2 = {
15719
15800
  default: () => ({})
15720
15801
  }
15721
15802
  };
15803
+ const DescriptionGroup = /* @__PURE__ */ vue.defineComponent({
15804
+ props: {
15805
+ label: {
15806
+ type: String,
15807
+ default: () => ""
15808
+ }
15809
+ },
15810
+ setup(props2) {
15811
+ return () => vue.createVNode("div", {
15812
+ "class": "shy-form-divider"
15813
+ }, [props2.label]);
15814
+ }
15815
+ });
15722
15816
  const Description = /* @__PURE__ */ vue.defineComponent({
15723
15817
  name: "Description",
15724
15818
  props: basicProps$2,
@@ -15744,19 +15838,31 @@ const Description = /* @__PURE__ */ vue.defineComponent({
15744
15838
  const rows = vue.computed(() => {
15745
15839
  return getProps.value.schema.map((item) => {
15746
15840
  var _a2, _b;
15747
- return vue.createVNode("div", {
15748
- "class": `${prefixCls2}-row`,
15749
- "style": {
15750
- flex: `0 0 ${(((_a2 = item == null ? void 0 : item.colProps) == null ? void 0 : _a2.span) || basicColProps) / 24 * 100}%`
15751
- }
15752
- }, [vue.createVNode("span", {
15753
- "style": {
15754
- width: `${getProps.value.labelWidth}px`
15755
- },
15756
- "class": `${prefixCls2}-label`
15757
- }, [slots[`${item.field}Label`] ? slots[`${item.field}Label`]() : item.label, ((_b = getProps.value) == null ? void 0 : _b.isShowColon) ? ":" : ""]), vue.createVNode("span", {
15758
- "class": `${prefixCls2}-value`
15759
- }, [slots[`${item.field}Value`] ? slots[`${item.field}Value`]() : getProps.value.data[item.field]])]);
15841
+ if ((item == null ? void 0 : item.component) === "Divider") {
15842
+ return vue.createVNode(antDesignVue.Divider, null, null);
15843
+ } else if ((item == null ? void 0 : item.component) === "Group") {
15844
+ return vue.createVNode("div", {
15845
+ "style": {
15846
+ flex: "0 0 100%"
15847
+ }
15848
+ }, [vue.createVNode(DescriptionGroup, {
15849
+ "label": item == null ? void 0 : item.label
15850
+ }, null)]);
15851
+ } else {
15852
+ return vue.createVNode("div", {
15853
+ "class": `${prefixCls2}-row`,
15854
+ "style": {
15855
+ flex: `0 0 ${(((_a2 = item == null ? void 0 : item.colProps) == null ? void 0 : _a2.span) || basicColProps) / 24 * 100}%`
15856
+ }
15857
+ }, [vue.createVNode("span", {
15858
+ "style": {
15859
+ width: `${getProps.value.labelWidth}px`
15860
+ },
15861
+ "class": `${prefixCls2}-label`
15862
+ }, [slots[`${item.field}Label`] ? slots[`${item.field}Label`]() : item.label, ((_b = getProps.value) == null ? void 0 : _b.isShowColon) ? ":" : ""]), vue.createVNode("span", {
15863
+ "class": `${prefixCls2}-value`
15864
+ }, [slots[`${item.field}Value`] ? slots[`${item.field}Value`]() : getProps.value.data[item.field]])]);
15865
+ }
15760
15866
  });
15761
15867
  });
15762
15868
  emit("register", {
@@ -20437,6 +20543,7 @@ exports.IconPicker = _sfc_main$P;
20437
20543
  exports.LazyContainer = LazyContainer;
20438
20544
  exports.Loading = Loading;
20439
20545
  exports.PageFooter = PageFooter;
20546
+ exports.PageSecond = PageSecond;
20440
20547
  exports.PageWrapper = PageWrapper;
20441
20548
  exports.PageWrapperFixedHeightKey = PageWrapperFixedHeightKey;
20442
20549
  exports.PopConfirmButton = _sfc_main$J;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "3h1-ui",
3
- "version": "2.7.0",
3
+ "version": "2.8.0",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",