vxe-pc-ui 4.5.4 → 4.5.5

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 (44) hide show
  1. package/es/collapse/src/collapse.js +5 -1
  2. package/es/form/src/form.js +12 -16
  3. package/es/icon/style.css +1 -1
  4. package/es/split/src/split.js +113 -30
  5. package/es/style.css +1 -1
  6. package/es/style.min.css +1 -1
  7. package/es/ui/index.js +1 -1
  8. package/es/ui/src/log.js +1 -1
  9. package/lib/collapse/src/collapse.js +8 -1
  10. package/lib/collapse/src/collapse.min.js +1 -1
  11. package/lib/form/src/form.js +12 -16
  12. package/lib/form/src/form.min.js +1 -1
  13. package/lib/icon/style/style.css +1 -1
  14. package/lib/icon/style/style.min.css +1 -1
  15. package/lib/index.umd.js +147 -47
  16. package/lib/index.umd.min.js +1 -1
  17. package/lib/split/src/split.js +128 -30
  18. package/lib/split/src/split.min.js +1 -1
  19. package/lib/style.css +1 -1
  20. package/lib/style.min.css +1 -1
  21. package/lib/ui/index.js +1 -1
  22. package/lib/ui/index.min.js +1 -1
  23. package/lib/ui/src/log.js +1 -1
  24. package/lib/ui/src/log.min.js +1 -1
  25. package/package.json +1 -1
  26. package/packages/collapse/src/collapse.ts +5 -1
  27. package/packages/form/src/form.ts +12 -16
  28. package/packages/split/src/split.ts +120 -33
  29. package/types/components/carousel.d.ts +13 -3
  30. package/types/components/collapse.d.ts +23 -4
  31. package/types/components/split-item.d.ts +3 -0
  32. package/types/components/split.d.ts +62 -1
  33. /package/es/icon/{iconfont.1743125694154.ttf → iconfont.1743138565378.ttf} +0 -0
  34. /package/es/icon/{iconfont.1743125694154.woff → iconfont.1743138565378.woff} +0 -0
  35. /package/es/icon/{iconfont.1743125694154.woff2 → iconfont.1743138565378.woff2} +0 -0
  36. /package/es/{iconfont.1743125694154.ttf → iconfont.1743138565378.ttf} +0 -0
  37. /package/es/{iconfont.1743125694154.woff → iconfont.1743138565378.woff} +0 -0
  38. /package/es/{iconfont.1743125694154.woff2 → iconfont.1743138565378.woff2} +0 -0
  39. /package/lib/icon/style/{iconfont.1743125694154.ttf → iconfont.1743138565378.ttf} +0 -0
  40. /package/lib/icon/style/{iconfont.1743125694154.woff → iconfont.1743138565378.woff} +0 -0
  41. /package/lib/icon/style/{iconfont.1743125694154.woff2 → iconfont.1743138565378.woff2} +0 -0
  42. /package/lib/{iconfont.1743125694154.ttf → iconfont.1743138565378.ttf} +0 -0
  43. /package/lib/{iconfont.1743125694154.woff → iconfont.1743138565378.woff} +0 -0
  44. /package/lib/{iconfont.1743125694154.woff2 → iconfont.1743138565378.woff2} +0 -0
package/lib/ui/index.js CHANGED
@@ -26,7 +26,7 @@ Object.keys(_core).forEach(function (key) {
26
26
  });
27
27
  var _dynamics = require("../dynamics");
28
28
  var _log = require("./src/log");
29
- const version = exports.version = "4.5.4";
29
+ const version = exports.version = "4.5.5";
30
30
  _core.VxeUI.uiVersion = version;
31
31
  _core.VxeUI.dynamicApp = _dynamics.dynamicApp;
32
32
  function config(options) {
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _exportNames={version:!0,config:!0,setup:!0},_core=(exports.config=config,exports.default=void 0,exports.setup=setup,exports.version=void 0,require("@vxe-ui/core")),_dynamics=(Object.keys(_core).forEach(function(e){"default"===e||"__esModule"===e||Object.prototype.hasOwnProperty.call(_exportNames,e)||e in exports&&exports[e]===_core[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _core[e]}})}),require("../dynamics")),_log=require("./src/log");const version=exports.version="4.5.4";function config(e){return"development"===process.env.NODE_ENV&&(0,_log.warnLog)("vxe.error.delFunc",["config","setConfig"]),(0,_core.setConfig)(e)}function setup(e){return"development"===process.env.NODE_ENV&&(0,_log.warnLog)("vxe.error.delFunc",["setup","setConfig"]),(0,_core.setConfig)(e)}_core.VxeUI.uiVersion=version,_core.VxeUI.dynamicApp=_dynamics.dynamicApp,_core.VxeUI.config=config,_core.VxeUI.setup=setup,(0,_core.setConfig)({alert:{},anchor:{},anchorLink:{},avatar:{},badge:{},breadcrumb:{separator:"/"},breadcrumbItem:{},button:{trigger:"hover",prefixTooltip:{enterable:!0},suffixTooltip:{enterable:!0}},buttonGroup:{},calendar:{minDate:new Date(1900,0,1),maxDate:new Date(2100,0,1),startDay:1,selectDay:1},card:{border:!0,padding:!0},carousel:{height:200,loop:!0,interval:5e3},carouselItem:{},checkbox:{},checkboxGroup:{},col:{},collapse:{padding:!0,expandConfig:{showIcon:!0}},collapsePane:{},countdown:{},colorPicker:{type:"hex",clearable:!0,showAlpha:!0,clickToCopy:!0,showColorExtractor:!0,showQuick:!0},datePicker:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,shortcutConfig:{align:"left",mode:"text",autoClose:!0}},drawer:{position:"right",showHeader:!0,lockView:!0,mask:!0,showTitleOverflow:!0,showClose:!0,padding:!0,cancelClosable:!0,confirmClosable:!0},empty:{},form:{validConfig:{showMessage:!0,autoPos:!0,theme:"beautify"},tooltipConfig:{enterable:!0},titleAsterisk:!0,titleOverflow:!1,padding:!0},formDesign:{height:400,showHeader:!0,showPc:!0},formGather:{},formGroup:{},formItem:{},formView:{},icon:{},iconPicker:{icons:["home","company","comment","setting","send","envelope","envelope-open","bell","search","print","pc","goods","chart-line","edit","delete","save","folder","microphone","flag","link","location","sunny","rmb","usd","user","add-user","add-users","star","unlock","time","text","feedback","calendar","association-form","cloud-download","cloud-upload","file","subtable","chart-bar-x","chart-bar-y","chart-line","chart-pie","chart-radar"]},image:{showPreview:!0,showPrintButton:!0,maskClosable:!0},imageGroup:{showPreview:!0,showPrintButton:!0},imagePreview:{showPrintButton:!0},input:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,digits:2,controls:!0},layoutAside:{},layoutBody:{},layoutContainer:{},layoutFooter:{},layoutHeader:{},link:{underline:!0},listDesign:{height:400,showPc:!0},listView:{},list:{virtualYConfig:{enabled:!0,gt:100}},loading:{showIcon:!0,showText:!0},modal:{top:16,showHeader:!0,minWidth:340,minHeight:140,lockView:!0,mask:!0,duration:3e3,marginSize:0,dblclickZoom:!0,showTitleOverflow:!0,animat:!0,showClose:!0,padding:!0,draggable:!0,showConfirmButton:null,cancelClosable:!0,confirmClosable:!0,zoomConfig:{minimizeMaxSize:10,minimizeVerticalOffset:{top:-24,left:0},minimizeHorizontalOffset:{top:0,left:32}},storageKey:"VXE_MODAL_POSITION"},noticeBar:{},numberInput:{digits:2,autoFill:!0,controls:!0},optgroup:{},option:{},pager:{pageSizePlacement:"top"},print:{},passwordInput:{controls:!0},printPageBreak:{},pulldown:{destroyOnClose:!0},radio:{strict:!0},radioButton:{strict:!0},radioGroup:{strict:!0},rate:{},result:{},row:{},select:{multiCharOverflow:8,remoteConfig:{enabled:!0,autoLoad:!0},virtualYConfig:{enabled:!0,gt:100,oSize:2}},split:{itemConfig:{minWidth:40,minHeight:40}},splitItem:{},slider:{max:100,min:0},steps:{},switch:{},tabPane:{},tableSelect:{gridConfig:{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0,rowConfig:{isHover:!0},virtualXConfig:{enabled:!0,gt:0},virtualYConfig:{enabled:!0,gt:0}}},tabs:{},tag:{},textEllipsis:{underline:!0},text:{},textarea:{resize:"none"},tip:{},tooltip:{trigger:"hover",theme:"dark",enterDelay:500,leaveDelay:300,isArrow:!0},tree:{indent:20,minHeight:60,radioConfig:{strict:!0}},treeSelect:{treeConfig:{radioConfig:{},checkboxConfig:{}}},upload:{mode:"all",imageTypes:["jpg","jpeg","png","gif"],showList:!0,showUploadButton:!0,showButtonText:!0,showRemoveButton:!0,showButtonIcon:!0,showPreview:!0,dragToUpload:!0},watermark:{rotate:-30,gap:[100,100]},table:{},colgroup:{},column:{},toolbar:{},grid:{}});const iconPrefix="vxe-icon-";(0,_core.setIcon)({LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",BUTTON_DROPDOWN:iconPrefix+"arrow-down",BUTTON_LOADING:iconPrefix+"spinner roll",BUTTON_TOOLTIP_ICON:iconPrefix+"question-circle-fill",MENU_ITEM_EXPAND_OPEN:iconPrefix+"arrow-down rotate180",MENU_ITEM_EXPAND_CLOSE:iconPrefix+"arrow-down",SELECT_LOADED:iconPrefix+"spinner roll",SELECT_OPEN:iconPrefix+"caret-down rotate180",SELECT_CLOSE:iconPrefix+"caret-down",ADD_OPTION:iconPrefix+"add",ICON_PICKER_OPEN:iconPrefix+"caret-down rotate180",ICON_PICKER_CLOSE:iconPrefix+"caret-down",PAGER_HOME:iconPrefix+"home-page",PAGER_END:iconPrefix+"end-page",PAGER_JUMP_PREV:iconPrefix+"arrow-double-left",PAGER_JUMP_NEXT:iconPrefix+"arrow-double-right",PAGER_PREV_PAGE:iconPrefix+"arrow-left",PAGER_NEXT_PAGE:iconPrefix+"arrow-right",PAGER_JUMP_MORE:iconPrefix+"ellipsis-h",RADIO_CHECKED:iconPrefix+"radio-checked-fill",RADIO_UNCHECKED:iconPrefix+"radio-unchecked",CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",INPUT_CLEAR:iconPrefix+"error-circle-fill",INPUT_SEARCH:iconPrefix+"search",NUMBER_INPUT_PREV_NUM:iconPrefix+"caret-up",NUMBER_INPUT_NEXT_NUM:iconPrefix+"caret-down",DATE_PICKER_DATE:iconPrefix+"calendar",PASSWORD_INPUT_SHOW_PWD:iconPrefix+"eye-fill-close",PASSWORD_INPUT_HIDE_PWD:iconPrefix+"eye-fill",MODAL_ZOOM_MIN:iconPrefix+"minus",MODAL_ZOOM_REVERT:iconPrefix+"recover",MODAL_ZOOM_IN:iconPrefix+"square",MODAL_ZOOM_OUT:iconPrefix+"maximize",MODAL_CLOSE:iconPrefix+"close",MODAL_INFO:iconPrefix+"info-circle-fill",MODAL_SUCCESS:iconPrefix+"success-circle-fill",MODAL_WARNING:iconPrefix+"warning-circle-fill",MODAL_ERROR:iconPrefix+"error-circle-fill",MODAL_QUESTION:iconPrefix+"question-circle-fill",MODAL_LOADING:iconPrefix+"spinner roll",DRAWER_CLOSE:iconPrefix+"close",FORM_PREFIX:iconPrefix+"question-circle-fill",FORM_SUFFIX:iconPrefix+"question-circle-fill",FORM_FOLDING:iconPrefix+"arrow-up rotate180",FORM_UNFOLDING:iconPrefix+"arrow-up",FORM_DESIGN_STYLE_SETTING:iconPrefix+"layout",FORM_DESIGN_PROPS_PC:iconPrefix+"pc",FORM_DESIGN_PROPS_MOBILE:iconPrefix+"mobile",FORM_DESIGN_PROPS_ADD:iconPrefix+"add",FORM_DESIGN_PROPS_EDIT:iconPrefix+"edit",FORM_DESIGN_WIDGET_ADD:iconPrefix+"square-plus-fill",FORM_DESIGN_WIDGET_COPY:iconPrefix+"copy",FORM_DESIGN_WIDGET_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_SWAP_LR:iconPrefix+"swap",FORM_DESIGN_WIDGET_OPTION_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_OPTION_EXPAND_OPEN:iconPrefix+"square-plus",FORM_DESIGN_WIDGET_OPTION_EXPAND_CLOSE:iconPrefix+"square-minus",LIST_DESIGN_FIELD_SETTING:iconPrefix+"custom-column",LIST_DESIGN_LIST_SETTING:iconPrefix+"menu",LIST_DESIGN_LIST_SETTING_SEARCH_DELETE:iconPrefix+"delete",LIST_DESIGN_LIST_SETTING_ACTIVE_DELETE:iconPrefix+"delete",UPLOAD_FILE_ERROR:iconPrefix+"warning-circle-fill",UPLOAD_FILE_ADD:iconPrefix+"upload",UPLOAD_FILE_REMOVE:iconPrefix+"delete",UPLOAD_FILE_DOWNLOAD:iconPrefix+"download",UPLOAD_IMAGE_RE_UPLOAD:iconPrefix+"repeat",UPLOAD_IMAGE_ADD:iconPrefix+"add",UPLOAD_IMAGE_REMOVE:iconPrefix+"close",UPLOAD_LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",UPLOAD_FILE_TYPE_DEFAULT:iconPrefix+"file",UPLOAD_FILE_TYPE_XLSX:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_XLS:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_PDF:iconPrefix+"file-pdf",UPLOAD_FILE_TYPE_PNG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_GIF:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPEG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_MD:iconPrefix+"file-markdown",UPLOAD_FILE_TYPE_PPD:iconPrefix+"file-ppt",UPLOAD_FILE_TYPE_DOCX:iconPrefix+"file-word",UPLOAD_FILE_TYPE_DOC:iconPrefix+"file-word",UPLOAD_FILE_TYPE_ZIP:iconPrefix+"file-zip",UPLOAD_FILE_TYPE_TXT:iconPrefix+"file-txt",IMAGE_PREVIEW_CLOSE:iconPrefix+"close",IMAGE_PREVIEW_PREVIOUS:iconPrefix+"arrow-left",IMAGE_PREVIEW_NEXT:iconPrefix+"arrow-right",IMAGE_PREVIEW_PCT_FULL:iconPrefix+"pct-full",IMAGE_PREVIEW_PCT_1_1:iconPrefix+"pct-1-1",IMAGE_PREVIEW_ZOOM_OUT:iconPrefix+"search-zoom-out",IMAGE_PREVIEW_ZOOM_IN:iconPrefix+"search-zoom-in",IMAGE_PREVIEW_ROTATE_LEFT:iconPrefix+"rotate-left",IMAGE_PREVIEW_ROTATE_RIGHT:iconPrefix+"rotate-right",IMAGE_PREVIEW_PRINT:iconPrefix+"print",IMAGE_PREVIEW_DOWNLOAD:iconPrefix+"download",ALERT_CLOSE:iconPrefix+"close",ALERT_INFO:iconPrefix+"info-circle-fill",ALERT_SUCCESS:iconPrefix+"success-circle-fill",ALERT_WARNING:iconPrefix+"warning-circle-fill",ALERT_ERROR:iconPrefix+"error-circle-fill",TREE_NODE_OPEN:iconPrefix+"caret-right rotate90",TREE_NODE_CLOSE:iconPrefix+"caret-right",TREE_NODE_LOADED:iconPrefix+"spinner roll",TREE_SELECT_LOADED:iconPrefix+"spinner roll",TREE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TREE_SELECT_CLOSE:iconPrefix+"caret-down",TABLE_SELECT_LOADED:iconPrefix+"spinner roll",TABLE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TABLE_SELECT_CLOSE:iconPrefix+"caret-down",TABS_TAB_BUTTON_LEFT:iconPrefix+"arrow-left",TABS_TAB_BUTTON_RIGHT:iconPrefix+"arrow-right",TABS_TAB_CLOSE:iconPrefix+"close",TABS_TAB_REFRESH:iconPrefix+"refresh",TABS_TAB_REFRESH_LOADING:iconPrefix+"refresh roll",TEXT_COPY:iconPrefix+"copy",TEXT_LOADING:iconPrefix+"spinner roll",CAROUSEL_HORIZONTAL_PREVIOUS:iconPrefix+"arrow-left",CAROUSEL_HORIZONTAL_NEXT:iconPrefix+"arrow-right",CAROUSEL_VERTICAL_PREVIOUS:iconPrefix+"arrow-up",CAROUSEL_VERTICAL_NEXT:iconPrefix+"arrow-down",COLLAPSE_OPEN:iconPrefix+"arrow-right rotate90",COLLAPSE_CLOSE:iconPrefix+"arrow-right",EMPTY_DEFAULT:iconPrefix+"empty",RESULT_INFO:iconPrefix+"info-circle-fill",RESULT_SUCCESS:iconPrefix+"success-circle-fill",RESULT_WARNING:iconPrefix+"warning-circle-fill",RESULT_ERROR:iconPrefix+"error-circle-fill",RESULT_QUESTION:iconPrefix+"question-circle-fill",RESULT_LOADING:iconPrefix+"spinner roll",RATE_CHECKED:iconPrefix+"star-fill",RATE_UNCHECKED:iconPrefix+"star",COLOR_COPY:iconPrefix+"copy",EYE_DROPPER:iconPrefix+"dropper",SPLIT_TOP_ACTION:iconPrefix+"arrow-up",SPLIT_BOTTOM_ACTION:iconPrefix+"arrow-down",SPLIT_LEFT_ACTION:iconPrefix+"arrow-left",SPLIT_RIGHT_ACTION:iconPrefix+"arrow-right"});var _default=exports.default=_core.VxeUI;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _exportNames={version:!0,config:!0,setup:!0},_core=(exports.config=config,exports.default=void 0,exports.setup=setup,exports.version=void 0,require("@vxe-ui/core")),_dynamics=(Object.keys(_core).forEach(function(e){"default"===e||"__esModule"===e||Object.prototype.hasOwnProperty.call(_exportNames,e)||e in exports&&exports[e]===_core[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _core[e]}})}),require("../dynamics")),_log=require("./src/log");const version=exports.version="4.5.5";function config(e){return"development"===process.env.NODE_ENV&&(0,_log.warnLog)("vxe.error.delFunc",["config","setConfig"]),(0,_core.setConfig)(e)}function setup(e){return"development"===process.env.NODE_ENV&&(0,_log.warnLog)("vxe.error.delFunc",["setup","setConfig"]),(0,_core.setConfig)(e)}_core.VxeUI.uiVersion=version,_core.VxeUI.dynamicApp=_dynamics.dynamicApp,_core.VxeUI.config=config,_core.VxeUI.setup=setup,(0,_core.setConfig)({alert:{},anchor:{},anchorLink:{},avatar:{},badge:{},breadcrumb:{separator:"/"},breadcrumbItem:{},button:{trigger:"hover",prefixTooltip:{enterable:!0},suffixTooltip:{enterable:!0}},buttonGroup:{},calendar:{minDate:new Date(1900,0,1),maxDate:new Date(2100,0,1),startDay:1,selectDay:1},card:{border:!0,padding:!0},carousel:{height:200,loop:!0,interval:5e3},carouselItem:{},checkbox:{},checkboxGroup:{},col:{},collapse:{padding:!0,expandConfig:{showIcon:!0}},collapsePane:{},countdown:{},colorPicker:{type:"hex",clearable:!0,showAlpha:!0,clickToCopy:!0,showColorExtractor:!0,showQuick:!0},datePicker:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,shortcutConfig:{align:"left",mode:"text",autoClose:!0}},drawer:{position:"right",showHeader:!0,lockView:!0,mask:!0,showTitleOverflow:!0,showClose:!0,padding:!0,cancelClosable:!0,confirmClosable:!0},empty:{},form:{validConfig:{showMessage:!0,autoPos:!0,theme:"beautify"},tooltipConfig:{enterable:!0},titleAsterisk:!0,titleOverflow:!1,padding:!0},formDesign:{height:400,showHeader:!0,showPc:!0},formGather:{},formGroup:{},formItem:{},formView:{},icon:{},iconPicker:{icons:["home","company","comment","setting","send","envelope","envelope-open","bell","search","print","pc","goods","chart-line","edit","delete","save","folder","microphone","flag","link","location","sunny","rmb","usd","user","add-user","add-users","star","unlock","time","text","feedback","calendar","association-form","cloud-download","cloud-upload","file","subtable","chart-bar-x","chart-bar-y","chart-line","chart-pie","chart-radar"]},image:{showPreview:!0,showPrintButton:!0,maskClosable:!0},imageGroup:{showPreview:!0,showPrintButton:!0},imagePreview:{showPrintButton:!0},input:{startDate:new Date(1900,0,1),endDate:new Date(2100,0,1),startDay:1,selectDay:1,digits:2,controls:!0},layoutAside:{},layoutBody:{},layoutContainer:{},layoutFooter:{},layoutHeader:{},link:{underline:!0},listDesign:{height:400,showPc:!0},listView:{},list:{virtualYConfig:{enabled:!0,gt:100}},loading:{showIcon:!0,showText:!0},modal:{top:16,showHeader:!0,minWidth:340,minHeight:140,lockView:!0,mask:!0,duration:3e3,marginSize:0,dblclickZoom:!0,showTitleOverflow:!0,animat:!0,showClose:!0,padding:!0,draggable:!0,showConfirmButton:null,cancelClosable:!0,confirmClosable:!0,zoomConfig:{minimizeMaxSize:10,minimizeVerticalOffset:{top:-24,left:0},minimizeHorizontalOffset:{top:0,left:32}},storageKey:"VXE_MODAL_POSITION"},noticeBar:{},numberInput:{digits:2,autoFill:!0,controls:!0},optgroup:{},option:{},pager:{pageSizePlacement:"top"},print:{},passwordInput:{controls:!0},printPageBreak:{},pulldown:{destroyOnClose:!0},radio:{strict:!0},radioButton:{strict:!0},radioGroup:{strict:!0},rate:{},result:{},row:{},select:{multiCharOverflow:8,remoteConfig:{enabled:!0,autoLoad:!0},virtualYConfig:{enabled:!0,gt:100,oSize:2}},split:{itemConfig:{minWidth:40,minHeight:40}},splitItem:{},slider:{max:100,min:0},steps:{},switch:{},tabPane:{},tableSelect:{gridConfig:{showOverflow:!0,showHeaderOverflow:!0,showFooterOverflow:!0,rowConfig:{isHover:!0},virtualXConfig:{enabled:!0,gt:0},virtualYConfig:{enabled:!0,gt:0}}},tabs:{},tag:{},textEllipsis:{underline:!0},text:{},textarea:{resize:"none"},tip:{},tooltip:{trigger:"hover",theme:"dark",enterDelay:500,leaveDelay:300,isArrow:!0},tree:{indent:20,minHeight:60,radioConfig:{strict:!0}},treeSelect:{treeConfig:{radioConfig:{},checkboxConfig:{}}},upload:{mode:"all",imageTypes:["jpg","jpeg","png","gif"],showList:!0,showUploadButton:!0,showButtonText:!0,showRemoveButton:!0,showButtonIcon:!0,showPreview:!0,dragToUpload:!0},watermark:{rotate:-30,gap:[100,100]},table:{},colgroup:{},column:{},toolbar:{},grid:{}});const iconPrefix="vxe-icon-";(0,_core.setIcon)({LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",BUTTON_DROPDOWN:iconPrefix+"arrow-down",BUTTON_LOADING:iconPrefix+"spinner roll",BUTTON_TOOLTIP_ICON:iconPrefix+"question-circle-fill",MENU_ITEM_EXPAND_OPEN:iconPrefix+"arrow-down rotate180",MENU_ITEM_EXPAND_CLOSE:iconPrefix+"arrow-down",SELECT_LOADED:iconPrefix+"spinner roll",SELECT_OPEN:iconPrefix+"caret-down rotate180",SELECT_CLOSE:iconPrefix+"caret-down",ADD_OPTION:iconPrefix+"add",ICON_PICKER_OPEN:iconPrefix+"caret-down rotate180",ICON_PICKER_CLOSE:iconPrefix+"caret-down",PAGER_HOME:iconPrefix+"home-page",PAGER_END:iconPrefix+"end-page",PAGER_JUMP_PREV:iconPrefix+"arrow-double-left",PAGER_JUMP_NEXT:iconPrefix+"arrow-double-right",PAGER_PREV_PAGE:iconPrefix+"arrow-left",PAGER_NEXT_PAGE:iconPrefix+"arrow-right",PAGER_JUMP_MORE:iconPrefix+"ellipsis-h",RADIO_CHECKED:iconPrefix+"radio-checked-fill",RADIO_UNCHECKED:iconPrefix+"radio-unchecked",CHECKBOX_INDETERMINATE:iconPrefix+"checkbox-indeterminate-fill",CHECKBOX_CHECKED:iconPrefix+"checkbox-checked-fill",CHECKBOX_UNCHECKED:iconPrefix+"checkbox-unchecked",INPUT_CLEAR:iconPrefix+"error-circle-fill",INPUT_SEARCH:iconPrefix+"search",NUMBER_INPUT_PREV_NUM:iconPrefix+"caret-up",NUMBER_INPUT_NEXT_NUM:iconPrefix+"caret-down",DATE_PICKER_DATE:iconPrefix+"calendar",PASSWORD_INPUT_SHOW_PWD:iconPrefix+"eye-fill-close",PASSWORD_INPUT_HIDE_PWD:iconPrefix+"eye-fill",MODAL_ZOOM_MIN:iconPrefix+"minus",MODAL_ZOOM_REVERT:iconPrefix+"recover",MODAL_ZOOM_IN:iconPrefix+"square",MODAL_ZOOM_OUT:iconPrefix+"maximize",MODAL_CLOSE:iconPrefix+"close",MODAL_INFO:iconPrefix+"info-circle-fill",MODAL_SUCCESS:iconPrefix+"success-circle-fill",MODAL_WARNING:iconPrefix+"warning-circle-fill",MODAL_ERROR:iconPrefix+"error-circle-fill",MODAL_QUESTION:iconPrefix+"question-circle-fill",MODAL_LOADING:iconPrefix+"spinner roll",DRAWER_CLOSE:iconPrefix+"close",FORM_PREFIX:iconPrefix+"question-circle-fill",FORM_SUFFIX:iconPrefix+"question-circle-fill",FORM_FOLDING:iconPrefix+"arrow-up rotate180",FORM_UNFOLDING:iconPrefix+"arrow-up",FORM_DESIGN_STYLE_SETTING:iconPrefix+"layout",FORM_DESIGN_PROPS_PC:iconPrefix+"pc",FORM_DESIGN_PROPS_MOBILE:iconPrefix+"mobile",FORM_DESIGN_PROPS_ADD:iconPrefix+"add",FORM_DESIGN_PROPS_EDIT:iconPrefix+"edit",FORM_DESIGN_WIDGET_ADD:iconPrefix+"square-plus-fill",FORM_DESIGN_WIDGET_COPY:iconPrefix+"copy",FORM_DESIGN_WIDGET_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_SWAP_LR:iconPrefix+"swap",FORM_DESIGN_WIDGET_OPTION_DELETE:iconPrefix+"delete",FORM_DESIGN_WIDGET_OPTION_EXPAND_OPEN:iconPrefix+"square-plus",FORM_DESIGN_WIDGET_OPTION_EXPAND_CLOSE:iconPrefix+"square-minus",LIST_DESIGN_FIELD_SETTING:iconPrefix+"custom-column",LIST_DESIGN_LIST_SETTING:iconPrefix+"menu",LIST_DESIGN_LIST_SETTING_SEARCH_DELETE:iconPrefix+"delete",LIST_DESIGN_LIST_SETTING_ACTIVE_DELETE:iconPrefix+"delete",UPLOAD_FILE_ERROR:iconPrefix+"warning-circle-fill",UPLOAD_FILE_ADD:iconPrefix+"upload",UPLOAD_FILE_REMOVE:iconPrefix+"delete",UPLOAD_FILE_DOWNLOAD:iconPrefix+"download",UPLOAD_IMAGE_RE_UPLOAD:iconPrefix+"repeat",UPLOAD_IMAGE_ADD:iconPrefix+"add",UPLOAD_IMAGE_REMOVE:iconPrefix+"close",UPLOAD_LOADING:iconPrefix+"spinner roll vxe-loading--default-icon",UPLOAD_FILE_TYPE_DEFAULT:iconPrefix+"file",UPLOAD_FILE_TYPE_XLSX:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_XLS:iconPrefix+"file-excel",UPLOAD_FILE_TYPE_PDF:iconPrefix+"file-pdf",UPLOAD_FILE_TYPE_PNG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_GIF:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_JPEG:iconPrefix+"file-image",UPLOAD_FILE_TYPE_MD:iconPrefix+"file-markdown",UPLOAD_FILE_TYPE_PPD:iconPrefix+"file-ppt",UPLOAD_FILE_TYPE_DOCX:iconPrefix+"file-word",UPLOAD_FILE_TYPE_DOC:iconPrefix+"file-word",UPLOAD_FILE_TYPE_ZIP:iconPrefix+"file-zip",UPLOAD_FILE_TYPE_TXT:iconPrefix+"file-txt",IMAGE_PREVIEW_CLOSE:iconPrefix+"close",IMAGE_PREVIEW_PREVIOUS:iconPrefix+"arrow-left",IMAGE_PREVIEW_NEXT:iconPrefix+"arrow-right",IMAGE_PREVIEW_PCT_FULL:iconPrefix+"pct-full",IMAGE_PREVIEW_PCT_1_1:iconPrefix+"pct-1-1",IMAGE_PREVIEW_ZOOM_OUT:iconPrefix+"search-zoom-out",IMAGE_PREVIEW_ZOOM_IN:iconPrefix+"search-zoom-in",IMAGE_PREVIEW_ROTATE_LEFT:iconPrefix+"rotate-left",IMAGE_PREVIEW_ROTATE_RIGHT:iconPrefix+"rotate-right",IMAGE_PREVIEW_PRINT:iconPrefix+"print",IMAGE_PREVIEW_DOWNLOAD:iconPrefix+"download",ALERT_CLOSE:iconPrefix+"close",ALERT_INFO:iconPrefix+"info-circle-fill",ALERT_SUCCESS:iconPrefix+"success-circle-fill",ALERT_WARNING:iconPrefix+"warning-circle-fill",ALERT_ERROR:iconPrefix+"error-circle-fill",TREE_NODE_OPEN:iconPrefix+"caret-right rotate90",TREE_NODE_CLOSE:iconPrefix+"caret-right",TREE_NODE_LOADED:iconPrefix+"spinner roll",TREE_SELECT_LOADED:iconPrefix+"spinner roll",TREE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TREE_SELECT_CLOSE:iconPrefix+"caret-down",TABLE_SELECT_LOADED:iconPrefix+"spinner roll",TABLE_SELECT_OPEN:iconPrefix+"caret-down rotate180",TABLE_SELECT_CLOSE:iconPrefix+"caret-down",TABS_TAB_BUTTON_LEFT:iconPrefix+"arrow-left",TABS_TAB_BUTTON_RIGHT:iconPrefix+"arrow-right",TABS_TAB_CLOSE:iconPrefix+"close",TABS_TAB_REFRESH:iconPrefix+"refresh",TABS_TAB_REFRESH_LOADING:iconPrefix+"refresh roll",TEXT_COPY:iconPrefix+"copy",TEXT_LOADING:iconPrefix+"spinner roll",CAROUSEL_HORIZONTAL_PREVIOUS:iconPrefix+"arrow-left",CAROUSEL_HORIZONTAL_NEXT:iconPrefix+"arrow-right",CAROUSEL_VERTICAL_PREVIOUS:iconPrefix+"arrow-up",CAROUSEL_VERTICAL_NEXT:iconPrefix+"arrow-down",COLLAPSE_OPEN:iconPrefix+"arrow-right rotate90",COLLAPSE_CLOSE:iconPrefix+"arrow-right",EMPTY_DEFAULT:iconPrefix+"empty",RESULT_INFO:iconPrefix+"info-circle-fill",RESULT_SUCCESS:iconPrefix+"success-circle-fill",RESULT_WARNING:iconPrefix+"warning-circle-fill",RESULT_ERROR:iconPrefix+"error-circle-fill",RESULT_QUESTION:iconPrefix+"question-circle-fill",RESULT_LOADING:iconPrefix+"spinner roll",RATE_CHECKED:iconPrefix+"star-fill",RATE_UNCHECKED:iconPrefix+"star",COLOR_COPY:iconPrefix+"copy",EYE_DROPPER:iconPrefix+"dropper",SPLIT_TOP_ACTION:iconPrefix+"arrow-up",SPLIT_BOTTOM_ACTION:iconPrefix+"arrow-down",SPLIT_LEFT_ACTION:iconPrefix+"arrow-left",SPLIT_RIGHT_ACTION:iconPrefix+"arrow-right"});var _default=exports.default=_core.VxeUI;
package/lib/ui/src/log.js CHANGED
@@ -5,6 +5,6 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.warnLog = exports.errLog = void 0;
7
7
  var _core = require("@vxe-ui/core");
8
- const version = `ui v${"4.5.4"}`;
8
+ const version = `ui v${"4.5.5"}`;
9
9
  const warnLog = exports.warnLog = _core.log.create('warn', version);
10
10
  const errLog = exports.errLog = _core.log.create('error', version);
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");const version="ui v4.5.4",warnLog=exports.warnLog=_core.log.create("warn",version),errLog=exports.errLog=_core.log.create("error",version);
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.warnLog=exports.errLog=void 0;var _core=require("@vxe-ui/core");const version="ui v4.5.5",warnLog=exports.warnLog=_core.log.create("warn",version),errLog=exports.errLog=_core.log.create("error",version);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vxe-pc-ui",
3
- "version": "4.5.4",
3
+ "version": "4.5.5",
4
4
  "description": "A vue based PC component library",
5
5
  "scripts": {
6
6
  "update": "npm install --legacy-peer-deps",
@@ -23,7 +23,8 @@ export default defineComponent({
23
23
  emits: [
24
24
  'update:modelValue',
25
25
  'load',
26
- 'change'
26
+ 'change',
27
+ 'toggle-expand'
27
28
  ] as VxeCollapseEmits,
28
29
  setup (props, context) {
29
30
  const { emit, slots } = context
@@ -145,13 +146,16 @@ export default defineComponent({
145
146
  const { name } = item
146
147
  if (name) {
147
148
  const aIndex = activeNames.indexOf(name)
149
+ let expanded = false
148
150
  if (aIndex === -1) {
151
+ expanded = true
149
152
  activeNames.push(name)
150
153
  } else {
151
154
  activeNames.splice(aIndex, 1)
152
155
  }
153
156
  addInitName(name)
154
157
  dispatchEvent('change', { value: activeNames, name }, evnt)
158
+ dispatchEvent('toggle-expand', { value: activeNames, name, expanded }, evnt)
155
159
  }
156
160
  }
157
161
 
@@ -230,19 +230,17 @@ export default defineComponent({
230
230
 
231
231
  const loadItem = (list: VxeFormPropTypes.Items) => {
232
232
  if (list.length) {
233
- if (process.env.VUE_APP_VXE_ENV === 'development') {
234
- list.forEach((item) => {
235
- if (item.slots) {
236
- XEUtils.each(item.slots, (func) => {
237
- if (!XEUtils.isFunction(func)) {
238
- if (!slots[func]) {
239
- errLog('vxe.error.notSlot', [func])
240
- }
233
+ list.forEach((item) => {
234
+ if (item.slots) {
235
+ XEUtils.each(item.slots, (func) => {
236
+ if (!XEUtils.isFunction(func)) {
237
+ if (!slots[func]) {
238
+ errLog('vxe.error.notSlot', [func])
241
239
  }
242
- })
243
- }
244
- })
245
- }
240
+ }
241
+ })
242
+ }
243
+ })
246
244
  }
247
245
  reactData.staticItems = XEUtils.mapTree(list, item => createItem($xeForm, item), { children: 'children' })
248
246
  return nextTick()
@@ -792,10 +790,8 @@ export default defineComponent({
792
790
 
793
791
  onMounted(() => {
794
792
  nextTick(() => {
795
- if (process.env.VUE_APP_VXE_ENV === 'development') {
796
- if (props.customLayout && props.items) {
797
- errLog('vxe.error.errConflicts', ['custom-layout', 'items'])
798
- }
793
+ if (props.customLayout && props.items) {
794
+ errLog('vxe.error.errConflicts', ['custom-layout', 'items'])
799
795
  }
800
796
  })
801
797
  })
@@ -3,9 +3,10 @@ import { getConfig, getIcon, createEvent, globalEvents, renderEmptyElement } fro
3
3
  import { getSlotVNs } from '../../ui/src/vn'
4
4
  import { toCssUnit, isScale, addClass, removeClass } from '../../ui/src/dom'
5
5
  import { getGlobalDefaultConfig } from '../../ui/src/utils'
6
+ import { errLog } from '../../ui/src/log'
6
7
  import XEUtils from 'xe-utils'
7
8
 
8
- import type { SplitReactData, SplitPrivateRef, VxeSplitPropTypes, SplitInternalData, SplitMethods, VxeSplitDefines, VxeSplitPrivateComputed, SplitPrivateMethods, VxeSplitEmits, VxeSplitConstructor, ValueOf, VxeSplitPrivateMethods } from '../../../types'
9
+ import type { SplitReactData, SplitPrivateRef, VxeSplitPropTypes, SplitInternalData, SplitMethods, VxeSplitDefines, VxeSplitItemProps, VxeSplitPrivateComputed, SplitPrivateMethods, VxeSplitEmits, VxeSplitConstructor, ValueOf, VxeSplitPrivateMethods } from '../../../types'
9
10
 
10
11
  export default defineComponent({
11
12
  name: 'VxeSplit',
@@ -24,6 +25,7 @@ export default defineComponent({
24
25
  type: Boolean as PropType<VxeSplitPropTypes.Padding>,
25
26
  default: () => getConfig().split.padding
26
27
  },
28
+ items: Array as PropType<VxeSplitPropTypes.Items>,
27
29
  itemConfig: Object as PropType<VxeSplitPropTypes.ItemConfig>,
28
30
  barConfig: Object as PropType<VxeSplitPropTypes.BarConfig>,
29
31
  actionConfig: Object as PropType<VxeSplitPropTypes.ActionConfig>
@@ -31,6 +33,7 @@ export default defineComponent({
31
33
  emits: [
32
34
  'action-dblclick',
33
35
  'action-click',
36
+ 'toggle-expand',
34
37
  'resize-start',
35
38
  'resize-drag',
36
39
  'resize-end'
@@ -43,7 +46,8 @@ export default defineComponent({
43
46
  const refElem = ref<HTMLDivElement>()
44
47
 
45
48
  const reactData = reactive<SplitReactData>({
46
- staticItems: []
49
+ staticItems: [],
50
+ itemList: []
47
51
  })
48
52
 
49
53
  const internalData: SplitInternalData = {
@@ -148,8 +152,8 @@ export default defineComponent({
148
152
  }
149
153
 
150
154
  const reset = () => {
151
- const { staticItems } = reactData
152
- staticItems.forEach(item => {
155
+ const { itemList } = reactData
156
+ itemList.forEach(item => {
153
157
  item.isExpand = true
154
158
  item.isVisible = true
155
159
  item.foldHeight = 0
@@ -160,10 +164,50 @@ export default defineComponent({
160
164
  return nextTick()
161
165
  }
162
166
 
167
+ const handleLoadItem = (list: VxeSplitItemProps[], isReset: boolean) => {
168
+ const { staticItems } = reactData
169
+ const itemDef = {
170
+ isVisible: true,
171
+ isExpand: true,
172
+ renderWidth: 0,
173
+ resizeWidth: 0,
174
+ foldWidth: 0,
175
+ renderHeight: 0,
176
+ resizeHeight: 0,
177
+ foldHeight: 0
178
+ }
179
+ reactData.itemList = list.map(item => {
180
+ if (item.slots) {
181
+ XEUtils.each(item.slots, (func) => {
182
+ if (!XEUtils.isFunction(func)) {
183
+ if (!slots[func]) {
184
+ errLog('vxe.error.notSlot', [func])
185
+ }
186
+ }
187
+ })
188
+ }
189
+ return Object.assign({}, isReset ? null : itemDef, item, isReset ? itemDef : null, {
190
+ id: XEUtils.uniqueId()
191
+ })
192
+ })
193
+ if (staticItems.length) {
194
+ errLog('vxe.error.errConflicts', ['<vxe-split-item ...>', 'items'])
195
+ }
196
+ return recalculate()
197
+ }
198
+
199
+ const loadItem = (list: VxeSplitItemProps[]) => {
200
+ return handleLoadItem(list || [], false)
201
+ }
202
+
203
+ const reloadItem = (list: VxeSplitItemProps[]) => {
204
+ return handleLoadItem(list || [], true)
205
+ }
206
+
163
207
  const recalculate = () => {
164
208
  return nextTick().then(() => {
165
209
  const { vertical } = props
166
- const { staticItems } = reactData
210
+ const { itemList } = reactData
167
211
  const el = refElem.value
168
212
  if (!el) {
169
213
  return
@@ -179,7 +223,7 @@ export default defineComponent({
179
223
  const residueItems: VxeSplitDefines.ChunkConfig[] = []
180
224
  if (vertical) {
181
225
  let countHeight = 0
182
- staticItems.forEach(item => {
226
+ itemList.forEach(item => {
183
227
  const { height } = item
184
228
  let itemHeight = 0
185
229
  if (height) {
@@ -202,7 +246,7 @@ export default defineComponent({
202
246
  }
203
247
  } else {
204
248
  let countWidth = 0
205
- staticItems.forEach(item => {
249
+ itemList.forEach(item => {
206
250
  const { width } = item
207
251
  let itemWidth = 0
208
252
  if (width) {
@@ -230,7 +274,7 @@ export default defineComponent({
230
274
  const dragEvent = (evnt: MouseEvent) => {
231
275
  evnt.preventDefault()
232
276
  const { vertical } = props
233
- const { staticItems } = reactData
277
+ const { itemList } = reactData
234
278
  const barEl = evnt.currentTarget as HTMLDivElement
235
279
  const handleEl = barEl.parentElement as HTMLDivElement
236
280
  const el = refElem.value
@@ -238,8 +282,8 @@ export default defineComponent({
238
282
  return
239
283
  }
240
284
  const itemId = handleEl.getAttribute('itemid')
241
- const itemIndex = XEUtils.findIndexOf(staticItems, item => item.id === itemId)
242
- const item = staticItems[itemIndex]
285
+ const itemIndex = XEUtils.findIndexOf(itemList, item => item.id === itemId)
286
+ const item = itemList[itemIndex]
243
287
  if (!item) {
244
288
  return
245
289
  }
@@ -250,7 +294,7 @@ export default defineComponent({
250
294
  const itemOpts = computeItemOpts.value
251
295
  const allMinWidth = XEUtils.toNumber(itemOpts.minWidth)
252
296
  const allMinHeight = XEUtils.toNumber(itemOpts.minHeight)
253
- const targetItem = staticItems[itemIndex + (isFoldNext ? 1 : -1)]
297
+ const targetItem = itemList[itemIndex + (isFoldNext ? 1 : -1)]
254
298
  const targetItemEl = targetItem ? el.querySelector<HTMLDivElement>(`.vxe-split-item[itemid="${targetItem.id}"]`) : null
255
299
  const currItemEl = item ? el.querySelector<HTMLDivElement>(`.vxe-split-item[itemid="${item.id}"]`) : null
256
300
  const targetWidth = targetItemEl ? targetItemEl.clientWidth : 0
@@ -326,14 +370,14 @@ export default defineComponent({
326
370
  return
327
371
  }
328
372
  const { vertical } = props
329
- const { staticItems } = reactData
373
+ const { itemList } = reactData
330
374
  const isFoldNext = computeIsFoldNext.value
331
375
  const btnEl = evnt.currentTarget as HTMLDivElement
332
376
  const handleEl = btnEl.parentElement as HTMLDivElement
333
377
  const itemId = handleEl.getAttribute('itemid')
334
- const itemIndex = XEUtils.findIndexOf(staticItems, item => item.id === itemId)
335
- const item = staticItems[itemIndex]
336
- const targetItem = staticItems[itemIndex + (isFoldNext ? 1 : -1)]
378
+ const itemIndex = XEUtils.findIndexOf(itemList, item => item.id === itemId)
379
+ const item = itemList[itemIndex]
380
+ const targetItem = itemList[itemIndex + (isFoldNext ? 1 : -1)]
337
381
  if (item) {
338
382
  const { showAction, isExpand } = item
339
383
  if (showAction) {
@@ -354,12 +398,42 @@ export default defineComponent({
354
398
  item.foldWidth = isExpand ? (targetItem.resizeWidth || targetItem.renderWidth) + (item.resizeWidth || item.renderWidth) : 0
355
399
  }
356
400
  }
357
- dispatchEvent(evnt.type === 'dblclick' ? 'action-dblclick' : 'action-click', { item, name: item.name, targetItem, targetName: targetItem ? targetItem.name : '', expanded: item.isExpand }, evnt)
401
+ dispatchEvent('toggle-expand', { item, name: item.name, targetItem, targetName: targetItem ? targetItem.name : '', expanded: item.isExpand }, evnt)
358
402
  recalculate()
359
403
  }
360
404
  }
361
405
  }
362
406
 
407
+ const handleActionDblclickEvent = (evnt: MouseEvent) => {
408
+ const { itemList } = reactData
409
+ const actionOpts = computeActionOpts.value
410
+ const btnEl = evnt.currentTarget as HTMLDivElement
411
+ const handleEl = btnEl.parentElement as HTMLDivElement
412
+ const itemId = handleEl.getAttribute('itemid')
413
+ const itemIndex = XEUtils.findIndexOf(itemList, item => item.id === itemId)
414
+ const item = itemList[itemIndex]
415
+
416
+ if (actionOpts.trigger === 'dblclick') {
417
+ handleItemActionEvent(evnt)
418
+ }
419
+ dispatchEvent('action-dblclick', { item, name: item ? item.name : '' }, evnt)
420
+ }
421
+
422
+ const handleActionClickEvent = (evnt: MouseEvent) => {
423
+ const { itemList } = reactData
424
+ const actionOpts = computeActionOpts.value
425
+ const btnEl = evnt.currentTarget as HTMLDivElement
426
+ const handleEl = btnEl.parentElement as HTMLDivElement
427
+ const itemId = handleEl.getAttribute('itemid')
428
+ const itemIndex = XEUtils.findIndexOf(itemList, item => item.id === itemId)
429
+ const item = itemList[itemIndex]
430
+
431
+ if (actionOpts.trigger !== 'dblclick') {
432
+ handleItemActionEvent(evnt)
433
+ }
434
+ dispatchEvent('action-click', { item, name: item ? item.name : '' }, evnt)
435
+ }
436
+
363
437
  const handleGlobalResizeEvent = () => {
364
438
  recalculate()
365
439
  }
@@ -367,7 +441,9 @@ export default defineComponent({
367
441
  const splitMethods: SplitMethods = {
368
442
  dispatchEvent,
369
443
  recalculate,
370
- reset
444
+ reset,
445
+ loadItem,
446
+ reloadItem
371
447
  }
372
448
 
373
449
  const splitPrivateMethods: SplitPrivateMethods = {
@@ -381,15 +457,6 @@ export default defineComponent({
381
457
  const isFoldNext = computeIsFoldNext.value
382
458
  const { id, isExpand, showAction } = item
383
459
 
384
- const btnOns: {
385
- onClick?: (evnt: MouseEvent) => void
386
- onDblclick?: (evnt: MouseEvent) => void
387
- } = {}
388
- if (actionOpts.trigger === 'dblclick') {
389
- btnOns.onDblclick = handleItemActionEvent
390
- } else {
391
- btnOns.onClick = handleItemActionEvent
392
- }
393
460
  return h('div', {
394
461
  itemid: id,
395
462
  class: ['vxe-split-item-handle', isFoldNext ? 'to--next' : 'to--prev']
@@ -402,7 +469,8 @@ export default defineComponent({
402
469
  showAction
403
470
  ? h('span', {
404
471
  class: 'vxe-split-item-action-btn',
405
- ...btnOns
472
+ onDblclick: handleActionDblclickEvent,
473
+ onClick: handleActionClickEvent
406
474
  }, [
407
475
  h('i', {
408
476
  class: (isExpand ? actionOpts.openIcon : actionOpts.closeIcon) || getDefaultActionIcon(item)
@@ -414,11 +482,11 @@ export default defineComponent({
414
482
 
415
483
  const renderItems = () => {
416
484
  const { border, padding, vertical } = props
417
- const { staticItems } = reactData
485
+ const { itemList } = reactData
418
486
  const isFoldNext = computeIsFoldNext.value
419
487
  const itemVNs: VNode[] = []
420
- staticItems.forEach((item, index) => {
421
- const { id, slots, renderHeight, resizeHeight, foldHeight, renderWidth, resizeWidth, foldWidth, isVisible, isExpand } = item
488
+ itemList.forEach((item, index) => {
489
+ const { id, name, slots, renderHeight, resizeHeight, foldHeight, renderWidth, resizeWidth, foldWidth, isVisible, isExpand } = item
422
490
  const defaultSlot = slots ? slots.default : null
423
491
  const stys: Record<string, string | number> = {}
424
492
  const itemWidth = isVisible ? (foldWidth || resizeWidth || renderWidth) : 0
@@ -454,9 +522,9 @@ export default defineComponent({
454
522
  }, [
455
523
  h('div', {
456
524
  class: 'vxe-split-item--inner'
457
- }, defaultSlot ? callSlot(defaultSlot, { }) : [])
525
+ }, defaultSlot ? callSlot(defaultSlot, { name, isVisible, isExpand }) : [])
458
526
  ]),
459
- isFoldNext && index < staticItems.length - 1 ? renderHandleBar(item) : renderEmptyElement($xeSplit)
527
+ isFoldNext && index < itemList.length - 1 ? renderHandleBar(item) : renderEmptyElement($xeSplit)
460
528
  ])
461
529
  )
462
530
  })
@@ -487,7 +555,22 @@ export default defineComponent({
487
555
  ])
488
556
  }
489
557
 
490
- watch(() => reactData.staticItems, () => {
558
+ const itemFlag = ref(0)
559
+ watch(() => props.items ? props.items.length : -1, () => {
560
+ itemFlag.value++
561
+ })
562
+ watch(() => props.items, () => {
563
+ itemFlag.value++
564
+ })
565
+ watch(itemFlag, () => {
566
+ loadItem(props.items || [])
567
+ })
568
+
569
+ watch(() => reactData.staticItems, (val) => {
570
+ if (props.items && props.items.length) {
571
+ errLog('vxe.error.errConflicts', ['<vxe-split-item ...>', 'items'])
572
+ }
573
+ reactData.itemList = val
491
574
  recalculate()
492
575
  })
493
576
 
@@ -507,6 +590,10 @@ export default defineComponent({
507
590
  recalculate()
508
591
  })
509
592
 
593
+ if (props.items) {
594
+ loadItem(props.items)
595
+ }
596
+
510
597
  provide('$xeSplit', $xeSplit)
511
598
 
512
599
  $xeSplit.renderVN = renderVN
@@ -101,13 +101,23 @@ export namespace VxeCarouselDefines {
101
101
  className: VxeCarouselItemPropTypes.ClassName | undefined
102
102
  slots: VxeCarouselItemSlots
103
103
  }
104
+
105
+ export interface ChangeEventParams extends CarouselEventParams {
106
+ value: VxeCarouselPropTypes.ModelValue
107
+ }
104
108
  }
105
109
 
106
- export type VxeCarouselEventProps = {}
110
+ export type VxeCarouselEventProps = {
111
+ onChange?: VxeCarouselEvents.Change
112
+ }
107
113
 
108
- export interface VxeCarouselListeners { }
114
+ export interface VxeCarouselListeners {
115
+ change?: VxeCarouselEvents.Change
116
+ }
109
117
 
110
- export namespace VxeCarouselEvents { }
118
+ export namespace VxeCarouselEvents {
119
+ export type Change = (params: VxeCarouselDefines.ChangeEventParams) => void
120
+ }
111
121
 
112
122
  export namespace VxeCarouselSlotTypes {
113
123
  export interface DefaultSlotParams {}
@@ -68,20 +68,39 @@ export interface VxeCollapsePrivateMethods extends CollapsePrivateMethods { }
68
68
  export type VxeCollapseEmits = [
69
69
  'update:modelValue',
70
70
  'load',
71
- 'change'
71
+ 'change',
72
+ 'toggle-expand',
72
73
  ]
73
74
 
74
75
  export namespace VxeCollapseDefines {
75
76
  export interface CollapseEventParams extends VxeComponentEventParams {
76
77
  $collapse: VxeCollapseConstructor
77
78
  }
79
+ export interface ChangeEventParams extends CollapseEventParams {
80
+ value: (string | number)[]
81
+ name: VxeCollapsePanePropTypes.Name
82
+ }
83
+ export interface ToggleExpandEventParams extends CollapseEventParams {
84
+ value: (string | number)[]
85
+ name: VxeCollapsePanePropTypes.Name
86
+ expanded: boolean
87
+ }
78
88
  }
79
89
 
80
- export type VxeCollapseEventProps = {}
90
+ export type VxeCollapseEventProps = {
91
+ onChange?: VxeCollapseEvents.Change
92
+ onToggleExpand?: VxeCollapseEvents.ToggleExpand
93
+ }
81
94
 
82
- export interface VxeCollapseListeners { }
95
+ export interface VxeCollapseListeners {
96
+ change?: VxeCollapseEvents.Change
97
+ onToggleExpand?: VxeCollapseEvents.ToggleExpand
98
+ }
83
99
 
84
- export namespace VxeCollapseEvents { }
100
+ export namespace VxeCollapseEvents {
101
+ export type Change = (params: VxeCollapseDefines.ChangeEventParams) => void
102
+ export type ToggleExpand = (params: VxeCollapseDefines.ToggleExpandEventParams) => void
103
+ }
85
104
 
86
105
  export namespace VxeCollapseSlotTypes {
87
106
  export interface DefaultSlotParams {}
@@ -82,6 +82,9 @@ export namespace VxeSplitItemEvents {
82
82
 
83
83
  export namespace VxeSplitItemSlotTypes {
84
84
  export interface DefaultSlotParams {
85
+ name: VxeSplitItemPropTypes.Name
86
+ isVisible: boolean
87
+ isExpand: boolean
85
88
  }
86
89
  }
87
90