bi-element-ui 1.4.3 → 1.5.2
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/dist/css/about.798bca83.css +1 -0
- package/dist/css/chunk-vendors.32e08f47.css +22 -0
- package/dist/css/index.7de03914.css +1 -0
- package/dist/index.html +1 -1
- package/dist/js/about.8c4bb832.js +2 -0
- package/dist/js/chunk-vendors.30e16d8a.js +393 -0
- package/dist/js/index.fe38e2ac.js +11 -0
- package/lib/bi-element-ui.common.js +2321 -92
- package/lib/bi-element-ui.css +1 -1
- package/lib/bi-element-ui.umd.js +2321 -92
- package/lib/bi-element-ui.umd.min.js +35 -33
- package/package.json +2 -1
- package/pnpm-lock.yaml +55 -0
- package/src/App.vue +100 -15
- package/src/main.js +1 -1
- package/src/router/index.js +5 -0
- package/src/utils/index.js +15 -0
- package/src/views/Date.vue +52 -7
- package/src/views/Layout.vue +1 -1
- package/src/views/textEditor.vue +35 -0
- package/dist/css/about.f927ac1d.css +0 -1
- package/dist/css/chunk-vendors.bce393fb.css +0 -1
- package/dist/css/index.9da9fdde.css +0 -1
- package/dist/js/about.49a721d0.js +0 -2
- package/dist/js/chunk-vendors.008a0caf.js +0 -313
- package/dist/js/index.e9532c02.js +0 -11
@@ -1,2 +0,0 @@
|
|
1
|
-
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["about"],{1818:function(t,e,l){"use strict";l("e5d9")},"1d2a":function(t,e,l){},"3a43":function(t,e,l){"use strict";l.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"free-table"},[e("div",{staticClass:"example-table-box"},[e("p",[t._v("基础日期-"+t._s(t.date))]),e("BiDatePicker",{attrs:{type:"date",placeholder:"选择日期"},model:{value:t.date,callback:function(e){t.date=e},expression:"date"}})],1),e("div",{staticClass:"example-table-box"},[e("p",[t._v("基础周-"+t._s(t.date1))]),e("BiDatePicker",{attrs:{type:"week",placeholder:"选择周"},model:{value:t.date1,callback:function(e){t.date1=e},expression:"date1"}})],1),e("div",{staticClass:"example-table-box"},[e("p",[t._v("基础月-"+t._s(t.date2))]),e("BiDatePicker",{attrs:{type:"month",placeholder:"选择周"},model:{value:t.date2,callback:function(e){t.date2=e},expression:"date2"}})],1),e("div",{staticClass:"example-table-box"},[e("p",[t._v("范围日期-"+t._s(t.date3))]),e("BiDatePicker",{attrs:{type:"daterange",placeholder:"选择日期1","picker-option":t.pickerOptions1},model:{value:t.date3,callback:function(e){t.date3=e},expression:"date3"}}),e("p",[t._v("范围日期-"+t._s(t.date7))]),e("BiDatePicker",{attrs:{type:"daterange",placeholder:"选择日期2","picker-option":t.pickerOptions2},model:{value:t.date7,callback:function(e){t.date7=e},expression:"date7"}})],1),e("div",{staticClass:"example-table-box"},[e("p",[t._v("范围月-"+t._s(t.date5))]),e("BiDatePicker",{attrs:{type:"monthrange",placeholder:"选择日期",format:"yyyy-MM"},model:{value:t.date5,callback:function(e){t.date5=e},expression:"date5"}})],1),e("div",{staticClass:"example-table-box"},[e("p",[t._v("范围日期时间-"+t._s(t.date6))]),e("BiDatePicker",{attrs:{type:"datetimerange",format:"yyyy-MM-dd HH:mm:ss","value-format":"yyyy-MM-dd HH:mm:ss","default-time":["00:00:00","23:59:59"],"range-separator":"至","start-placeholder":"开始日期","end-placeholder":"结束日期"},model:{value:t.date6,callback:function(e){t.date6=e},expression:"date6"}})],1)])},a=[],i=l("bb03"),o=l.n(i),n={components:{},data(){return{date:"",date1:"",date2:"",date3:[],date4:[],date5:[],date6:[],date7:[],columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1,pickerOptions1:{firstDayOfWeek:1,onPick:({minDate:t,maxDate:e})=>{console.log(1,o()(t).format("YYYY-MM-DD"))}},pickerOptions2:{firstDayOfWeek:1,onPick:({minDate:t,maxDate:e})=>{console.log(2,o()(t).format("YYYY-MM-DD"))}}}},methods:{selectionChange(t){console.log("selected",t)},getList(){},openDialog({row:t}){this.editForm=Object.assign({},t),this.dialogVisible=!0}}},c=n,r=(l("e12d"),l("4a4e")),u=Object(r["a"])(c,s,a,!1,null,"49a6bb0c",null);e["default"]=u.exports},"3f0e":function(t,e,l){"use strict";l.r(e);var s=function(){var t=this,e=t._self._c;return e("div",[t._e(),e("div",{staticClass:"example-table-box"},[e("p",[t._v("tooltipIcon在表格内的组件使用")]),e("p",[e("el-button",{on:{click:function(e){t.tableLoading=!t.tableLoading}}},[t._v("tableLoading")])],1),e("el-table",{directives:[{name:"sticky-header",rawName:"v-sticky-header",value:{offsetTop:0},expression:"{offsetTop:0}"},{name:"sticky-footer",rawName:"v-sticky-footer",value:{offsetBottom:0},expression:"{offsetBottom:0}"}],attrs:{data:t.data,"summary-method":t.getSummaries,"show-summary":""}},[e("el-table-column",{attrs:{label:"日期",prop:"date",fixed:""}}),e("el-table-column",{attrs:{label:"姓名",prop:"name",fixed:""}}),e("el-table-column",{attrs:{label:"省份",prop:"province",fixed:""}}),e("el-table-column",{attrs:{label:"省份tableLoading3",prop:"province",fixed:"right"}}),t.tableLoading?e("el-table-column",{attrs:{label:"姓名right1",prop:"name",fixed:"right"}}):t._e(),t.tableLoading?e("el-table-column",{attrs:{label:"姓名right2",prop:"name",fixed:"right"}}):t._e(),e("el-table-column",{attrs:{label:"市区",prop:"city"}}),e("el-table-column",{attrs:{label:"地址",prop:"address",width:"400"}}),e("el-table-column",{attrs:{label:"地址2",prop:"address",width:"400"}}),e("el-table-column",{attrs:{label:"地址3",prop:"address",width:"400"}}),e("el-table-column",{attrs:{label:"邮编",prop:"zip"}}),e("el-table-column",{attrs:{label:"操作",prop:"cmp"}}),e("el-table-column",{attrs:{label:"邮编",prop:"zip"}}),e("el-table-column",{attrs:{label:"操作",prop:"cmp"}}),e("el-table-column",{attrs:{label:"邮编",prop:"zip"}}),e("el-table-column",{attrs:{label:"操作",prop:"cmp"}}),e("el-table-column",{attrs:{label:"邮编",prop:"zip"}}),e("el-table-column",{attrs:{label:"操作",prop:"cmp"}}),e("el-table-column",{attrs:{label:"邮编",prop:"zip"}}),e("el-table-column",{attrs:{label:"操作",prop:"cmp"}})],1)],1)],2)},a=[],i=l("ee74"),o=function(){var t=this,e=t._self._c;return e("el-button",{attrs:{type:"primary"},on:{click:function(e){t.visible=!0}}},[t._v(" 自定义列 "),e("el-dialog",{attrs:{"custom-class":"bi-column-dialog",title:"自定义列",visible:t.visible,width:"800px",top:"8vh","append-to-body":""},on:{"update:visible":function(e){t.visible=e},open:t.handleOpen,close:t.close}},[e("div",{staticClass:"dialog-body",staticStyle:{"min-height":"160px"}},[e("div",{staticClass:"bi-column-container"},[e("div",{staticClass:"checkbox-container"},[e("el-card",{staticClass:"box-card"},[e("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[e("span",[t._v("可操作性的列")])]),t._l(t.colList,(function(l,s){return e("div",{key:s,staticClass:"checkbox-group"},[e("p",{staticClass:"checkbox-title"},[e("el-checkbox",{on:{change:e=>t.handleCheckGroupAllChange(e,l)},model:{value:l.status,callback:function(e){t.$set(l,"status",e)},expression:"item.status"}},[t._v(t._s(l.content))])],1),e("p",[e("el-checkbox-group",{attrs:{"true-label":1,"false-label":0},on:{change:function(e){return t.handleCheckGroupAll(l)}},model:{value:t.checkList,callback:function(e){t.checkList=e},expression:"checkList"}},t._l(l.children,(function(l,s){return e("el-checkbox",{key:s,staticStyle:{width:"120px",margin:"0 15px 15px 0"},attrs:{label:l.name}},[t._v(" "+t._s(l.content)+" ")])})),1)],1)])}))],2)],1),e("div",{staticClass:"column-container"},[e("el-card",{staticClass:"box-card"},[e("div",{staticClass:"column-title",attrs:{slot:"header"},slot:"header"},[e("span",[t._v("已选"+t._s(t.columnLength)+"列")]),e("el-button",{attrs:{type:"text"},on:{click:t.clearAll}},[t._v("清空全部")])],1),e("p",{staticClass:"column-group-title"},[t._v("左侧固定列")]),e("div",{staticClass:"column-configurable"},[e("draggable",{attrs:{group:"column"},model:{value:t.leftColumnList,callback:function(e){t.leftColumnList=e},expression:"leftColumnList"}},t._l(t.leftColumnList,(function(l){return e("div",{key:l.prop,staticClass:"selected-column-item"},[e("i",{staticClass:"el-icon-menu"}),e("div",{staticClass:"column-name"},[t._v(t._s(l.content||l.label))]),e("i",{staticClass:"el-icon-close column-close",on:{click:function(e){return t.closeColumn(l.prop)}}})])})),0)],1),e("p",{staticClass:"column-group-title"},[t._v("中间不固定列")]),e("div",{staticClass:"column-configurable"},[e("draggable",{attrs:{group:"column"},model:{value:t.columnList,callback:function(e){t.columnList=e},expression:"columnList"}},t._l(t.columnList,(function(l){return e("div",{key:l.prop,staticClass:"selected-column-item"},[e("i",{staticClass:"el-icon-menu"}),e("div",{staticClass:"column-name"},[t._v(t._s(l.content||l.label))]),e("i",{staticClass:"el-icon-close column-close",on:{click:function(e){return t.closeColumn(l.prop)}}})])})),0)],1),e("p",{staticClass:"column-group-title"},[t._v("右侧固定列")]),e("div",{staticClass:"column-configurable"},[e("draggable",{attrs:{group:"column"},model:{value:t.rightColumnList,callback:function(e){t.rightColumnList=e},expression:"rightColumnList"}},t._l(t.rightColumnList,(function(l){return e("div",{key:l.prop,staticClass:"selected-column-item"},[e("i",{staticClass:"el-icon-menu"}),e("div",{staticClass:"column-name"},[t._v(t._s(l.content||l.label))]),e("i",{staticClass:"el-icon-close column-close",on:{click:function(e){return t.closeColumn(l.prop)}}})])})),0)],1)])],1)])]),e("span",{staticClass:"dialog-footer",staticStyle:{display:"flex","justify-content":"space-between"},attrs:{slot:"footer"},slot:"footer"},[e("span",{staticStyle:{display:"inline-block","line-height":"32px"}},[e("el-checkbox",{attrs:{label:"全选"},on:{change:t.checkAll},model:{value:t.checkAllData,callback:function(e){t.checkAllData=e},expression:"checkAllData"}},[t._v(" 全选 ")])],1),e("div",[e("el-button",{on:{click:t.close}},[t._v("关闭")]),e("el-button",{attrs:{type:"primary"},on:{click:t.ok}},[t._v("生效")])],1)])])],1)},n=[],c=l("ce7d"),r=l.n(c),u={name:"BiTableColumn",components:{draggable:r.a},props:{columnName:{type:String,require:!0,default:""},listType:{type:String,require:!0,default:""},checkData:{type:Array,require:!0,default:()=>[]},tableColumn:{type:Array,default:()=>[]},defaultColumn:{type:Object,default:()=>({left:[],center:[],right:[]})}},data(){return{tableColumnList:this.tableColumn,visible:!1,colList:[],checkList:[],checkAllData:!1,draggableList:[],leftColumnList:[],columnList:[],rightColumnList:[]}},computed:{columnLength(){return this.leftColumnList.length+this.columnList.length+this.rightColumnList.length}},watch:{colList:{handler(t){let e=!0;t.forEach(t=>{t.status=Boolean(t.status),t.status?this.checkAllData=t.status:e=!1,this.checkAllData=e})},deep:!0}},mounted(){const t={type:this.listType};this.defaultColumnInit(),this.getList(t),this.returnColumn()},beforeDestroy(){this.visible=!1},methods:{defaultColumnInit(){const t=this.getLocalStorage(),{left:e,center:l,right:s}=t||this.defaultColumn;e.map(t=>{this.checkList.push(t);const e=this.tableColumnList.find(e=>e.prop===t);e&&this.leftColumnList.push(e)}),l.map(t=>{this.checkList.push(t);const e=this.tableColumnList.find(e=>e.prop===t);e&&this.columnList.push(e)}),s.map(t=>{this.checkList.push(t);const e=this.tableColumnList.find(e=>e.prop===t);e&&this.rightColumnList.push(e)})},async getList(t){this.colList=[{content:"分组1",status:!1,children:[{name:"date",content:"日期",status:!1}]},{content:"分组2",status:!1,children:[{content:"姓名",name:"name",status:!1},{content:"省份",name:"province",status:!1},{content:"市区",name:"city",status:!1}]},{content:"分组3",status:!1,children:[{content:"地址",name:"address",status:!1},{content:"地址2",name:"address2",status:!1},{content:"邮编",name:"zip",status:!1},{content:"v-model",name:"other",status:!1}]}],this.defaultCheck()},checkAll(t){this.colList.forEach(e=>{this.handleCheckGroupAllChange(t,e),e.status=t}),t||(this.checkList=[])},defaultCheck(){this.colList.forEach(t=>{this.handleCheckGroupAll(t)})},deleteArrayItemForIndex(t,e){if(-1!==e)return t.splice(e,1)},handleCheckGroupAllChange(t,e){t?e.children.map(t=>{-1===this.checkList.indexOf(t.name)&&(this.checkList.push(t.name),this.insertColumn(t.name))}):e.children.map(t=>{this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(t.name)),this.removeColumn(t.name)})},handleCheckGroupAll(t){let e=1;t.children.map(t=>{-1===this.checkList.indexOf(t.name)?(this.removeColumn(t.name),e=0):this.insertColumn(t.name)}),t.status=e},async setTheadList(){const t=JSON.parse(JSON.stringify(this.colList));var e=[];t.forEach(t=>{t.status=t.status?1:0,e.push(...t.children)})},clearAll(){this.checkList=[],this.checkAll(!1)},closeColumn(t){this.deleteArrayItemForIndex(this.checkList,this.checkList.indexOf(t)),this.removeColumn(t),this.defaultCheck()},insertColumn(t){const e=this.tableColumnList.find(e=>e.prop===t);this.leftColumnList.find(e=>e.prop===t)||this.rightColumnList.find(e=>e.prop===t)||this.columnList.find(e=>e.prop===t)||this.columnList.push(e)},removeColumn(t){if(this.leftColumnList.length&&this.leftColumnList.find(e=>e.prop===t)){const e=this.leftColumnList.findIndex(e=>e.prop===t);e>-1&&this.leftColumnList.splice(e,1)}if(this.columnList.length&&this.columnList.find(e=>e.prop===t)){const e=this.columnList.findIndex(e=>e.prop===t);e>-1&&this.columnList.splice(e,1)}if(this.rightColumnList.length&&this.rightColumnList.find(e=>e.prop===t)){const e=this.rightColumnList.findIndex(e=>e.prop===t);e>-1&&this.rightColumnList.splice(e,1)}},returnColumn(){this.leftColumnList.map(t=>{t.fixed=!0}),this.columnList.map(t=>{t.fixed=!1}),this.rightColumnList.map(t=>{t.fixed="right"}),this.$emit("handleTableColumn",[...this.leftColumnList,...this.columnList,...this.rightColumnList])},ok(){this.returnColumn(),this.saveLocalStorage(),this.visible=!1},saveLocalStorage(){const t={left:[],center:[],right:[]};this.leftColumnList.map(({prop:e})=>{e&&t.left.push(e)}),this.columnList.map(({prop:e})=>{e&&t.center.push(e)}),this.rightColumnList.map(({prop:e})=>{e&&t.right.push(e)}),localStorage.setItem(this.columnName,JSON.stringify(t))},getLocalStorage(){const t=localStorage.getItem(this.columnName);return t?JSON.parse(t):void 0},handleOpen(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[];const t=this.getLocalStorage();t&&this.defaultColumnInit()},close(){this.checkList=[],this.rightColumnList=[],this.leftColumnList=[],this.columnList=[],this.visible=!1,this.$emit("closeDialog",{visible:!1})}}},p=u,d=(l("64c0"),l("1818"),l("4a4e")),m=Object(d["a"])(p,o,n,!1,null,"3ffbf407",null),h=(m.exports,l("3fc0")),b={components:{BiTooltipIcon:h["a"]},mixins:[i["a"]],data(){return{basicData2:[],basicColumn:[{label:"日期",prop:"date",sortable:!0,fixed:!0},{label:"姓名",prop:"name"},{label:"省份",prop:"province"},{label:"市区",prop:"city"},{label:"地址",prop:"address",width:()=>this.aaWidth},{label:"地址2",prop:"address2",minWidth:()=>"100"},{label:"邮编",prop:"zip"},{label:"v-model",prop:"other",fixed:"right",render:(t,e)=>t("input",{on:{input(t){e.row.name=t.target.value}},domProps:{value:e.row.name},style:{width:"100%",minHeight:"30px",color:"red",border:"1px solid #ddd"}})}],tableLoading:!0,columnsProps:{width:"auto"},total:0,listQuery:{page:2,limit:20},editForm:{},dialogVisible:!1}},computed:{aaWidth(){return 400}},methods:{selectionChange(t){console.log("selected",t)},getList(){},openDialog({row:t}){this.editForm=Object.assign({},t),this.dialogVisible=!0},setTableColumn(t){this.$set(this,"basicColumn",[]),setTimeout(()=>{this.$set(this,"basicColumn",t)},10)},getSummaries(){return["合计","2016-05-03","王小虎","上海","普陀区","上海市普陀区金沙江路 1518 弄","上海市普陀区金沙江路 1518 弄",200333]},search(){const t=JSON.parse(JSON.stringify(this.data));this.data=t.splice(0,7),this.$nextTick(()=>{this.$refs.table.resetHeaderFooter&&this.$refs.table.resetHeaderFooter()})}}},f=b,g=(l("a44b"),Object(d["a"])(f,s,a,!1,null,"3caabf88",null));e["default"]=g.exports},"64c0":function(t,e,l){"use strict";l("1d2a")},"6e4b":function(t,e,l){"use strict";l("ed4a")},8265:function(t,e,l){},"88e9":function(t,e,l){"use strict";l.r(e);var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"box"},[e("header",[e("BiNavbarTool",{attrs:{token:t.token,avatar:t.avatar}})],1)])},a=[],i={data(){return{token:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiIxNTc1NzE4NTMyMiIsImxvZ2luX2VudiI6IiIsImlhdCI6MTcwODMzNTUyNywiZXhwIjoxNzA4OTQwMzI3LCJuYmYiOjE3MDgzMzU1MjcsInN1YiI6InRva2Vu6K6k6K-BIiwianRpIjoiOWEzYWNkYTBkZDhlYmRjNzM3NTAwYzc2MGU0MWQ5N2YifQ.5XzkjXWgiNpA0yUYbNTT8TjPttdlnPWQzggcDNZEB20",avatar:"https://static-legacy.dingtalk.com/media/lADPBbCc1SE7SD7NAuzNAug_744_748.jpg?imageView2/1/w/80/h/80"}},methods:{}},o=i,n=(l("6e4b"),l("4a4e")),c=Object(n["a"])(o,s,a,!1,null,"ac1da312",null);e["default"]=c.exports},a44b:function(t,e,l){"use strict";l("dd15")},dd15:function(t,e,l){},e12d:function(t,e,l){"use strict";l("8265")},e5d9:function(t,e,l){},ed4a:function(t,e,l){},f45b:function(t,e,l){"use strict";l.r(e);var s=function(){var t=this,e=t._self._c;return e("bi-home-data")},a=[],i=l("4a4e"),o={},n=Object(i["a"])(o,s,a,!1,null,null,null);e["default"]=n.exports}}]);
|
2
|
-
//# sourceMappingURL=about.49a721d0.js.map
|