1 line
134 KiB
JavaScript
1 line
134 KiB
JavaScript
(window.webpackJsonp=window.webpackJsonp||[]).push([[2],{361:function(e,t,n){e.exports=n.p+"static/wx.f391ad4.jpg"},363:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("div",[n("p",[e._v("目前仅支持"),n("code",[e._v("中文")]),e._v("和"),n("code",[e._v("英文")]),e._v(", 如需更多语言, 可以"),n("code",[e._v("clone")]),e._v("代码进行二次开发")])]),n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n<div xid=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n language: 'en',\n data: []\n})\nvar demo2 = xmSelect.render({\n el: '[xid=demo2]', \n language: 'en',\n data: [\n {name: 'apple', value: 1},\n {name: 'banana', value: 2},\n {name: 'orange', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("div",{staticClass:"xm-select-demo",attrs:{xid:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",language:"en",data:[]}),xmSelect.render({el:"[xid=demo2]",language:"en",data:[{name:"apple",value:1},{name:"banana",value:2},{name:"orange",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"guo-ji-hua"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#guo-ji-hua","aria-hidden":"true"}},[this._v("¶")]),this._v(" 国际化")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"ying-yu"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#ying-yu","aria-hidden":"true"}},[this._v("¶")]),this._v(" 英语")])}],!1,null,null,null);r.options.__file="docs/mds/XM02.md";t.default=r.exports},364:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v('\n<table id="demo" lay-filter="test"></table>\n\n<script>\nlayui.use(\'table\', function() {\n var table = layui.table;\n\n //第一个实例\n table.render({\n elem: \'#demo\',\n height: 312,\n page: true, //开启分页\n cols: [\n [ //表头\n { field: \'id\', title: \'ID\', width: 80, sort: true }, \n { field: \'username\', title: \'用户名\', width: 80 }, \n { field: \'sex\', title: \'性别\', width: 80, sort: true }, \n { field: \'city\', title: \'城市\', width: 80 }, \n { field: \'sign\', title: \'爱好\', width: 177, templet: function(d){\n return \'<div id="XM-\' + d.id + \'" ></div>\'\n } }, \n { field: \'experience\', title: \'积分\', width: 80, sort: true }, \n { field: \'score\', title: \'评分\', width: 80, sort: true }, \n { field: \'classify\', title: \'职业\', width: 80 }, \n { field: \'wealth\', title: \'财富\', width: 135, sort: true }\n ]\n ],\n data: [\n {"id":10000,"username":"user-0","sex":"女","city":"城市-0","sign":"签名-0","experience":255,"logins":24,"wealth":82830700,"classify":"作家","score":57},\n {"id":10001,"username":"user-1","sex":"男","city":"城市-1","sign":"签名-1","experience":884,"logins":58,"wealth":64928690,"classify":"词人","score":27},\n {"id":10002,"username":"user-2","sex":"女","city":"城市-2","sign":"签名-2","experience":650,"logins":77,"wealth":6298078,"classify":"酱油","score":31},\n {"id":10003,"username":"user-3","sex":"女","city":"城市-3","sign":"签名-3","experience":362,"logins":157,"wealth":37117017,"classify":"诗人","score":68},\n {"id":10004,"username":"user-4","sex":"男","city":"城市-4","sign":"签名-4","experience":807,"logins":51,"wealth":76263262,"classify":"作家","score":6},\n {"id":10005,"username":"user-5","sex":"女","city":"城市-5","sign":"签名-5","experience":173,"logins":68,"wealth":60344147,"classify":"作家","score":87},\n {"id":10006,"username":"user-6","sex":"女","city":"城市-6","sign":"签名-6","experience":982,"logins":37,"wealth":57768166,"classify":"作家","score":34},\n {"id":10007,"username":"user-7","sex":"男","city":"城市-7","sign":"签名-7","experience":727,"logins":150,"wealth":82030578,"classify":"作家","score":28},\n {"id":10008,"username":"user-8","sex":"男","city":"城市-8","sign":"签名-8","experience":951,"logins":133,"wealth":16503371,"classify":"词人","score":14},\n {"id":10009,"username":"user-9","sex":"女","city":"城市-9","sign":"签名-9","experience":484,"logins":25,"wealth":86801934,"classify":"词人","score":75}\n ],\n done: function(res){\n res.data.forEach(item => {\n var xm = xmSelect.render({\n el: \'#XM-\' + item.id, \n data: [\n {name: \'张三\', value: 1},\n {name: \'李四\', value: 2},\n {name: \'王五\', value: 3},\n ]\n })\n \n item.__xm = xm;\n })\n }\n });\n\n});\n\n\n<\/script>\n')])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("table",{attrs:{id:"demo","lay-filter":"test"}})])}],mounted:function(){this.$nextTick(function(){layui.use("table",function(){layui.table.render({elem:"#demo",height:312,page:!0,cols:[[{field:"id",title:"ID",width:80,sort:!0},{field:"username",title:"用户名",width:80},{field:"sex",title:"性别",width:80,sort:!0},{field:"city",title:"城市",width:80},{field:"sign",title:"爱好",width:177,templet:function(e){return'<div id="XM-'+e.id+'" ></div>'}},{field:"experience",title:"积分",width:80,sort:!0},{field:"score",title:"评分",width:80,sort:!0},{field:"classify",title:"职业",width:80},{field:"wealth",title:"财富",width:135,sort:!0}]],data:[{id:1e4,username:"user-0",sex:"女",city:"城市-0",sign:"签名-0",experience:255,logins:24,wealth:82830700,classify:"作家",score:57},{id:10001,username:"user-1",sex:"男",city:"城市-1",sign:"签名-1",experience:884,logins:58,wealth:64928690,classify:"词人",score:27},{id:10002,username:"user-2",sex:"女",city:"城市-2",sign:"签名-2",experience:650,logins:77,wealth:6298078,classify:"酱油",score:31},{id:10003,username:"user-3",sex:"女",city:"城市-3",sign:"签名-3",experience:362,logins:157,wealth:37117017,classify:"诗人",score:68},{id:10004,username:"user-4",sex:"男",city:"城市-4",sign:"签名-4",experience:807,logins:51,wealth:76263262,classify:"作家",score:6},{id:10005,username:"user-5",sex:"女",city:"城市-5",sign:"签名-5",experience:173,logins:68,wealth:60344147,classify:"作家",score:87},{id:10006,username:"user-6",sex:"女",city:"城市-6",sign:"签名-6",experience:982,logins:37,wealth:57768166,classify:"作家",score:34},{id:10007,username:"user-7",sex:"男",city:"城市-7",sign:"签名-7",experience:727,logins:150,wealth:82030578,classify:"作家",score:28},{id:10008,username:"user-8",sex:"男",city:"城市-8",sign:"签名-8",experience:951,logins:133,wealth:16503371,classify:"词人",score:14},{id:10009,username:"user-9",sex:"女",city:"城市-9",sign:"签名-9",experience:484,logins:25,wealth:86801934,classify:"词人",score:75}],done:function(e){e.data.forEach(function(e){var t=xmSelect.render({el:"#XM-"+e.id,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]});e.__xm=t})}})})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"biao-ge-zhong-duo-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#biao-ge-zhong-duo-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" 表格中多选")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"layui-biao-ge-zhong-duo-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#layui-biao-ge-zhong-duo-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" Layui表格中多选")])}],!1,null,null,null);r.options.__file="docs/mds/ZM03.md";t.default=r.exports},365:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<form>\n <div id=\"demo1\" class=\"xm-select-demo\"></div>\n <button class=\"btn\" type=\"submit\">提交</button>\n</form>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<form>\n <div id=\"demo2\" class=\"xm-select-demo\"></div>\n <button class=\"btn\" type=\"submit\">提交</button>\n</form>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n name: 'lalalalalala',\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("form",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{type:"submit"}},[this._v("提交")])])])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("form",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{type:"submit"}},[this._v("提交")])])])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",name:"lalalalalala",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"biao-dan-ti-jiao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#biao-dan-ti-jiao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 表单提交")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mo-ren-biao-dan-ti-jiao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-ren-biao-dan-ti-jiao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 默认表单提交")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xiu-gainame"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gainame","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改name")])}],!1,null,null,null);r.options.__file="docs/mds/ZM02.md";t.default=r.exports},366:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n repeat: true,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("demo-block",[n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n repeat: true,\n clickClose: true,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(3),n("demo-block",[n("div",[n("p",[e._v("好像这样只能增不能减了~~ 有待完善")])]),n("template",{slot:"source"},[n("element-demo2")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n repeat: true,\n model: {\n label: {\n type: 'count',\n count: {\n template: function(data, sels){\n var res = {};\n sels.forEach(item => {\n var name = item.name; \n !res[name] && (res[name] = 0);\n res[name] += 1;\n });\n return Object.keys(res).map(key => {\n return `${key} (${res[key]})`\n }).join(',');\n }\n },\n }\n },\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",repeat:!0,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",repeat:!0,clickClose:!0,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",repeat:!0,model:{label:{type:"count",count:{template:function(e,t){var n={};return t.forEach(function(e){var t=e.name;!n[t]&&(n[t]=0),n[t]+=1}),Object.keys(n).map(function(e){return"".concat(e," (").concat(n[e],")")}).join(",")}}}},data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"chong-fu-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#chong-fu-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" 重复选")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"kai-qi-chong-fu-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#kai-qi-chong-fu-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" 开启重复选")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"chong-fu-xuan-wan-guan-bi-xia-la"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#chong-fu-xuan-wan-guan-bi-xia-la","aria-hidden":"true"}},[this._v("¶")]),this._v(" 重复选完关闭下拉")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"geng-huan-xian-shi-fang-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#geng-huan-xian-shi-fang-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 更换显示方式")])}],!1,null,null,null);r.options.__file="docs/mds/XM10.md";t.default=r.exports},367:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n<button class=\"btn\" id=\"demo1-open\">打开下拉框</button>\n<button class=\"btn\" id=\"demo1-close\">关闭下拉框</button>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n\n\ndocument.getElementById('demo1-open').onclick = function(){\n //这里延迟1S, 是因为, 点击下拉框外边的位置 会出发关闭事件, 所以延迟演示效果\n setTimeout(function(){\n demo1.opened();\n }, 1000);\n}\n\ndocument.getElementById('demo1-close').onclick = function(){\n //先点一下关闭, 然后把下拉框点开, 3S后会自动关闭\n setTimeout(function(){\n demo1.closed();\n }, 3000);\n}\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ],\n show(){\n alert('打开了')\n },\n hide(){\n alert('关闭了')\n }\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-open"}},[this._v("打开下拉框")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-close"}},[this._v("关闭下拉框")])])}],mounted:function(){this.$nextTick(function(){var e=xmSelect.render({el:"#demo1",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]});document.getElementById("demo1-open").onclick=function(){setTimeout(function(){e.opened()},1e3)},document.getElementById("demo1-close").onclick=function(){setTimeout(function(){e.closed()},3e3)}})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}],show:function(){alert("打开了")},hide:function(){alert("关闭了")}})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"xian-shi-yu-yin-cang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xian-shi-yu-yin-cang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 显示与隐藏")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zhu-dong-da-kai-guan-bi-xia-la-kuang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zhu-dong-da-kai-guan-bi-xia-la-kuang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 主动打开/关闭下拉框")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jian-ting-da-kai-guan-bi-xia-la-kuang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jian-ting-da-kai-guan-bi-xia-la-kuang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 监听打开/关闭下拉框")])}],!1,null,null,null);r.options.__file="docs/mds/XM13.md";t.default=r.exports},368:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),e._m(2),e._m(3),e._m(4),e._m(5),e._m(6),e._m(7),e._m(8),e._m(9),e._m(10),e._m(11),n("demo-block",[n("div",[n("p",[e._v("只需引入"),n("code",[e._v("xm-select.js")])])]),n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n<button class=\"btn\" id=\"demo1-getValue\">获取选中值</button>\n<pre id=\"demo1-value\"></pre>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n language: 'zn',\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n\ndocument.getElementById('demo1-getValue').onclick = function(){\n //获取当前多选选中的值\n var selectArr = demo1.getValue();\n document.getElementById('demo1-value').innerHTML = JSON.stringify(selectArr, null, 2);\n}\n<\/script>\n\n")])])])],2)],1)},i=[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"an-zhuang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#an-zhuang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 安装")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jian-jie"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jian-jie","aria-hidden":"true"}},[this._v("¶")]),this._v(" 简介")])},function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"tip"},[t("p",[this._v("基于 "),t("a",{attrs:{href:"https://layui.com"}},[this._v("layui")]),this._v(" 的一个多选解决方案。前身 "),t("a",{attrs:{href:"https://github.com/hnzzmsf/layui-formSelects/"}},[this._v("formSelects")]),this._v(",经历了4个大版本的更新迭代,移除了对 "),t("code",[this._v("jquery")]),this._v(" 的依赖,以一种全新的面貌诞生了。")])])},function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("ul",[n("li",[e._v("唯一依赖库"),n("a",{attrs:{href:"https://preactjs.com/"}},[e._v("preactjs")])]),n("li",[e._v("打包方式"),n("a",{attrs:{href:"https://www.webpackjs.com/"}},[e._v("webpack")])]),n("li",[e._v("文档借鉴于"),n("a",{attrs:{href:"https://element.eleme.cn/#/zh-CN"}},[e._v("ElementUI")]),e._v("的编写方式")]),n("li",[n("a",{attrs:{href:"https://fly.layui.com/jie/57776/"}},[e._v("Fly社区交流贴")])]),n("li",[e._v("QQ交流群: "),n("code",[e._v("660408068")])])])},function(){var e=this.$createElement,t=this._self._c||e;return t("blockquote",[t("p",[this._v("作者: maplemei, 热爱前端的Java程序猿, 如果喜欢作者的插件, 可以请作者吃雪糕 ^_^")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[t("a",{attrs:{href:"javascript:;"}},[t("img",{attrs:{src:n(361),alt:"打赏",width:"300"}})])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xia-zai"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xia-zai","aria-hidden":"true"}},[this._v("¶")]),this._v(" 下载")])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[t("a",{attrs:{href:"https://gitee.com/maplemei/xm-select/stargazers"}},[t("img",{attrs:{src:"https://gitee.com/maplemei/xm-select/badge/star.svg?theme=dark",alt:"star"}})]),t("a",{attrs:{href:"https://gitee.com/maplemei/xm-select/members"}},[t("img",{attrs:{src:"https://gitee.com/maplemei/xm-select/badge/fork.svg?theme=dark",alt:"fork"}})])])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[t("a",{attrs:{href:"https://gitee.com/maplemei/xm-select/releases"}},[this._v("码云下载")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"er-ci-kai-fa"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#er-ci-kai-fa","aria-hidden":"true"}},[this._v("¶")]),this._v(" 二次开发")])},function(){var e=this.$createElement,t=this._self._c||e;return t("pre",[t("code",[this._v("$ git clone https://gitee.com/maplemei/xm-select.git\n$ cd xm-select\n$ npm install && npm run dev\n")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"hello-world"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#hello-world","aria-hidden":"true"}},[this._v("¶")]),this._v(" Hello World")])}];a._withStripped=!0;var s={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-getValue"}},[this._v("获取选中值")]),this._v(" "),t("pre",{attrs:{id:"demo1-value"}})])}],mounted:function(){this.$nextTick(function(){var e=xmSelect.render({el:"#demo1",language:"zn",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]});document.getElementById("demo1-getValue").onclick=function(){var t=e.getValue();document.getElementById("demo1-value").innerHTML=JSON.stringify(t,null,2)}})}}}()}},r=n(4),l=Object(r.a)(s,a,i,!1,null,null,null);l.options.__file="docs/mds/install.md";t.default=l.exports},369:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("demo-block",[n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n theme: {\n color: '#e54d42',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(3),n("demo-block",[n("template",{slot:"source"},[n("element-demo2")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n theme: {\n color: '#f37b1d',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(4),n("demo-block",[n("template",{slot:"source"},[n("element-demo3")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo4\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo4 = xmSelect.render({\n el: '#demo4', \n theme: {\n color: '#fbbd08',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(5),n("demo-block",[n("template",{slot:"source"},[n("element-demo4")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo5\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo5 = xmSelect.render({\n el: '#demo5', \n theme: {\n color: '#8dc63f',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(6),n("demo-block",[n("template",{slot:"source"},[n("element-demo5")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo6\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo6 = xmSelect.render({\n el: '#demo6', \n theme: {\n color: '#1cbbb4',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(7),n("demo-block",[n("template",{slot:"source"},[n("element-demo6")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo7\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo7 = xmSelect.render({\n el: '#demo7', \n theme: {\n color: '#0081ff',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(8),n("demo-block",[n("template",{slot:"source"},[n("element-demo7")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo8\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo8 = xmSelect.render({\n el: '#demo8', \n theme: {\n color: '#6739b6',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(9),n("demo-block",[n("template",{slot:"source"},[n("element-demo8")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo9\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo9 = xmSelect.render({\n el: '#demo9', \n theme: {\n color: '#9c26b0',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(10),n("demo-block",[n("template",{slot:"source"},[n("element-demo9")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo10\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo10 = xmSelect.render({\n el: '#demo10', \n theme: {\n color: '#e03997',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(11),n("demo-block",[n("template",{slot:"source"},[n("element-demo10")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo11\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo11 = xmSelect.render({\n el: '#demo11', \n theme: {\n color: '#a5673f',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(12),n("demo-block",[n("template",{slot:"source"},[n("element-demo11")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo12\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo12 = xmSelect.render({\n el: '#demo12', \n theme: {\n color: '#8799a3',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(13),n("demo-block",[n("template",{slot:"source"},[n("element-demo12")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo13\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo13 = xmSelect.render({\n el: '#demo13', \n theme: {\n color: '#aaaaaa',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(14),n("demo-block",[n("template",{slot:"source"},[n("element-demo13")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo14\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo14 = xmSelect.render({\n el: '#demo14', \n theme: {\n color: '#333333',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(15)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",theme:{color:"#e54d42"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",theme:{color:"#f37b1d"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo3":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo4"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo4",theme:{color:"#fbbd08"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo4":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo5"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo5",theme:{color:"#8dc63f"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo5":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo6"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo6",theme:{color:"#1cbbb4"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo6":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo7"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo7",theme:{color:"#0081ff"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo7":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo8"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo8",theme:{color:"#6739b6"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo8":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo9"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo9",theme:{color:"#9c26b0"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo9":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo10"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo10",theme:{color:"#e03997"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo10":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo11"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo11",theme:{color:"#a5673f"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo11":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo12"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo12",theme:{color:"#8799a3"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo12":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo13"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo13",theme:{color:"#aaaaaa"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo13":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo14"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo14",theme:{color:"#333333"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"zhu-ti"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zhu-ti","aria-hidden":"true"}},[this._v("¶")]),this._v(" 主题")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jing-dian-lu-009688"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jing-dian-lu-009688","aria-hidden":"true"}},[this._v("¶")]),this._v(" 经典绿 ( #009688 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"yan-hong-e54d42"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#yan-hong-e54d42","aria-hidden":"true"}},[this._v("¶")]),this._v(" 嫣红 ( #e54d42 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jie-cheng-f37b1d"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jie-cheng-f37b1d","aria-hidden":"true"}},[this._v("¶")]),this._v(" 桔橙 ( #f37b1d )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"ming-huang-fbbd08"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#ming-huang-fbbd08","aria-hidden":"true"}},[this._v("¶")]),this._v(" 明黄 ( #fbbd08 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"gan-lan-8dc63f"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#gan-lan-8dc63f","aria-hidden":"true"}},[this._v("¶")]),this._v(" 橄榄 ( #8dc63f )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"tian-qing-1cbbb4"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#tian-qing-1cbbb4","aria-hidden":"true"}},[this._v("¶")]),this._v(" 天青 ( #1cbbb4 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"hai-lan-0081ff"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#hai-lan-0081ff","aria-hidden":"true"}},[this._v("¶")]),this._v(" 海蓝 ( #0081ff )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"cha-zi-6739b6"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#cha-zi-6739b6","aria-hidden":"true"}},[this._v("¶")]),this._v(" 姹紫 ( #6739b6 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mu-jin-9c26b0"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mu-jin-9c26b0","aria-hidden":"true"}},[this._v("¶")]),this._v(" 木槿 ( #9c26b0 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"tao-fen-e03997"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#tao-fen-e03997","aria-hidden":"true"}},[this._v("¶")]),this._v(" 桃粉 ( #e03997 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zong-he-a5673f"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zong-he-a5673f","aria-hidden":"true"}},[this._v("¶")]),this._v(" 棕褐 ( #a5673f )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xuan-hui-8799a3"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xuan-hui-8799a3","aria-hidden":"true"}},[this._v("¶")]),this._v(" 玄灰 ( #8799a3 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"cao-hui-aaaaaa"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#cao-hui-aaaaaa","aria-hidden":"true"}},[this._v("¶")]),this._v(" 草灰 ( #aaaaaa )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mo-hei-333333"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-hei-333333","aria-hidden":"true"}},[this._v("¶")]),this._v(" 墨黑 ( #333333 )")])},function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"warning"},[t("p",[this._v("颜色值来源于"),t("a",{attrs:{href:"https://github.com/weilanwl/ColorUI"}},[this._v("ColorUI")]),this._v(", 有兴趣的可以看看")])])}],!1,null,null,null);r.options.__file="docs/mds/XM12.md";t.default=r.exports},370:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v('<div id="demo1" class="xm-select-demo"></div>\n<button class="btn" id="demo1-test1">赋值张三</button>\n<button class="btn" id="demo1-test2">赋值张三(value方式)</button>\n<button class="btn" id="demo1-test3">清空</button>\n<pre id="demo1-result"></pre>\n\n<script>\nvar demo1 = xmSelect.render({\n el: \'#demo1\', \n data: [\n {name: \'张三\', value: 1},\n {name: \'李四\', value: 2},\n {name: \'王五\', value: 3},\n ]\n})\n\ndocument.getElementById(\'demo1-test1\').onclick = function(){\n demo1.setValue([\n\t\t{name: \'张三\', value: 1},\n\t])\n};\n\ndocument.getElementById(\'demo1-test2\').onclick = function(){\n demo1.setValue([ 1 ])\n};\n\ndocument.getElementById(\'demo1-test3\').onclick = function(){\n demo1.setValue([ ])\n};\n\n<\/script>\n')])])])],2),this._m(3),this._m(4),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n<button class=\"btn\" id=\"demo2-getValue\">获取选中值</button>\n\n<br/><br/>\n\n<button class=\"btn\" id=\"name\">获取name数组</button>\n<button class=\"btn\" id=\"nameStr\">获取name字符串</button>\n<button class=\"btn\" id=\"value\">获取value数组</button>\n<button class=\"btn\" id=\"valueStr\">获取value字符串</button>\n\n<pre id=\"demo2-value\"></pre>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n\ndocument.getElementById('demo2-getValue').onclick = function(){\n //获取当前多选选中的值\n var selectArr = demo2.getValue();\n document.getElementById('demo2-value').innerHTML = JSON.stringify(selectArr, null, 2);\n}\n\ndocument.getElementById('name').onclick = function(){\n //获取当前多选选中的值\n var selectArr = demo2.getValue('name');\n document.getElementById('demo2-value').innerHTML = JSON.stringify(selectArr, null, 2);\n}\n\n\nvar types = ['name', 'nameStr', 'value', 'valueStr'];\ntypes.forEach(function(type){\n document.getElementById(type).onclick = function(){\n //获取当前多选选中的值\n var selectArr = demo2.getValue(type);\n document.getElementById('demo2-value').innerHTML = JSON.stringify(selectArr, null, 2);\n }\n});\n\n\n<\/script>\n\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test1"}},[this._v("赋值张三")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test2"}},[this._v("赋值张三(value方式)")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test3"}},[this._v("清空")]),this._v(" "),t("pre",{attrs:{id:"demo1-result"}})])}],mounted:function(){this.$nextTick(function(){var e=xmSelect.render({el:"#demo1",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]});document.getElementById("demo1-test1").onclick=function(){e.setValue([{name:"张三",value:1}])},document.getElementById("demo1-test2").onclick=function(){e.setValue([1])},document.getElementById("demo1-test3").onclick=function(){e.setValue([])}})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}}),e._v(" "),n("button",{staticClass:"btn",attrs:{id:"demo2-getValue"}},[e._v("获取选中值")]),e._v(" "),n("br"),n("br"),e._v(" "),n("button",{staticClass:"btn",attrs:{id:"name"}},[e._v("获取name数组")]),e._v(" "),n("button",{staticClass:"btn",attrs:{id:"nameStr"}},[e._v("获取name字符串")]),e._v(" "),n("button",{staticClass:"btn",attrs:{id:"value"}},[e._v("获取value数组")]),e._v(" "),n("button",{staticClass:"btn",attrs:{id:"valueStr"}},[e._v("获取value字符串")]),e._v(" "),n("pre",{attrs:{id:"demo2-value"}})])}],mounted:function(){this.$nextTick(function(){var e=xmSelect.render({el:"#demo2",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]});document.getElementById("demo2-getValue").onclick=function(){var t=e.getValue();document.getElementById("demo2-value").innerHTML=JSON.stringify(t,null,2)},document.getElementById("name").onclick=function(){var t=e.getValue("name");document.getElementById("demo2-value").innerHTML=JSON.stringify(t,null,2)};["name","nameStr","value","valueStr"].forEach(function(t){document.getElementById(t).onclick=function(){var n=e.getValue(t);document.getElementById("demo2-value").innerHTML=JSON.stringify(n,null,2)}})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"fu-zhi-yu-qu-zhi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#fu-zhi-yu-qu-zhi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 赋值与取值")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"gei-duo-xuan-fu-zhi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#gei-duo-xuan-fu-zhi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 给多选赋值")])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("函数"),t("code",[this._v("setValue(array)")]),this._v(", 动态赋值多选选中的数据, array可以是value数组, 也可以是完整的object数组")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"qu-zhi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#qu-zhi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 取值")])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("函数"),t("code",[this._v("getValue(type)")]),this._v(", type类型 name, nameStr, value, valueStr")])}],!1,null,null,null);r.options.__file="docs/mds/ZM01.md";t.default=r.exports},371:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n toolbar: {\n show: true,\n },\n filterable: true,\n paging: true,\n pageSize: 3,\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n {name: '赵六', value: 4},\n {name: '苹果', value: 5},\n {name: '香蕉', value: 6},\n {name: '凤梨', value: 7},\n {name: '葡萄', value: 8},\n {name: '樱桃', value: 9},\n {name: '车厘子', value: 10},\n {name: '火龙果', value: 11},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n toolbar: {\n show: true,\n showIcon: false,\n },\n filterable: true,\n paging: true,\n pageSize: 3,\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n {name: '赵六', value: 4},\n {name: '苹果', value: 5},\n {name: '香蕉', value: 6},\n {name: '凤梨', value: 7},\n {name: '葡萄', value: 8},\n {name: '樱桃', value: 9},\n {name: '车厘子', value: 10},\n {name: '火龙果', value: 11},\n ]\n})\n<\/script>\n")])])])],2),this._m(3),t("demo-block",[t("template",{slot:"source"},[t("element-demo2")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n toolbar: {\n show: true,\n list: ['ALL', {\n name: '自定义',\n icon: 'el-icon-star-off',\n method(data){\n alert('我是自定义的');\n }\n }]\n },\n filterable: true,\n paging: true,\n pageSize: 3,\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n {name: '赵六', value: 4},\n {name: '苹果', value: 5},\n {name: '香蕉', value: 6},\n {name: '凤梨', value: 7},\n {name: '葡萄', value: 8},\n {name: '樱桃', value: 9},\n {name: '车厘子', value: 10},\n {name: '火龙果', value: 11},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",toolbar:{show:!0},filterable:!0,paging:!0,pageSize:3,data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3},{name:"赵六",value:4},{name:"苹果",value:5},{name:"香蕉",value:6},{name:"凤梨",value:7},{name:"葡萄",value:8},{name:"樱桃",value:9},{name:"车厘子",value:10},{name:"火龙果",value:11}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",toolbar:{show:!0,showIcon:!1},filterable:!0,paging:!0,pageSize:3,data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3},{name:"赵六",value:4},{name:"苹果",value:5},{name:"香蕉",value:6},{name:"凤梨",value:7},{name:"葡萄",value:8},{name:"樱桃",value:9},{name:"车厘子",value:10},{name:"火龙果",value:11}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",toolbar:{show:!0,list:["ALL",{name:"自定义",icon:"el-icon-star-off",method:function(e){alert("我是自定义的")}}]},filterable:!0,paging:!0,pageSize:3,data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3},{name:"赵六",value:4},{name:"苹果",value:5},{name:"香蕉",value:6},{name:"凤梨",value:7},{name:"葡萄",value:8},{name:"樱桃",value:9},{name:"车厘子",value:10},{name:"火龙果",value:11}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"gong-ju-tiao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#gong-ju-tiao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 工具条")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mo-ren-gong-ju-tiao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-ren-gong-ju-tiao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 默认工具条")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"yin-cang-tu-biao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#yin-cang-tu-biao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 隐藏图标")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-gong-ju-tiao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-gong-ju-tiao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义工具条")])}],!1,null,null,null);r.options.__file="docs/mds/XM19.md";t.default=r.exports},372:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),this._m(2),t("demo-block",[t("div",[t("p",[t("code",[this._v("el")]),this._v("绑定的不一定是id, 也可以是其他css选择器")])]),t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"ji-chu-shi-yong"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#ji-chu-shi-yong","aria-hidden":"true"}},[this._v("¶")]),this._v(" 基础使用")])},function(){var e=this.$createElement,t=this._self._c||e;return t("div",{staticClass:"tip"},[t("p",[this._v("只需引入"),t("code",[this._v("xm-select.js")]),this._v(", 剩下的就只有渲染了")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"yi-ge-xiao-li-zi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#yi-ge-xiao-li-zi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 一个小栗子")])}],!1,null,null,null);r.options.__file="docs/mds/XM01.md";t.default=r.exports},373:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n max: 2,\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n max: 2,\n maxMethod(seles, item){\n alert(`${item.name}不能选了, 已经超了`)\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),this._m(3),t("demo-block",[t("template",{slot:"source"},[t("element-demo2")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n max: 2,\n theme: {\n maxColor: 'orange',\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",max:2,data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",max:2,maxMethod:function(e,t){alert("".concat(t.name,"不能选了, 已经超了"))},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",max:2,theme:{maxColor:"orange"},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"duo-xuan-shang-xian"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#duo-xuan-shang-xian","aria-hidden":"true"}},[this._v("¶")]),this._v(" 多选上限")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zui-duo-xuan-ze2-ge"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zui-duo-xuan-ze2-ge","aria-hidden":"true"}},[this._v("¶")]),this._v(" 最多选择2个")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-xuan-chao-de-ti-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-xuan-chao-de-ti-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义选超的提示")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-xuan-chao-de-shan-shuo-yan-se"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-xuan-chao-de-shan-shuo-yan-se","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义选超的闪烁颜色")])}],!1,null,null,null);r.options.__file="docs/mds/XM18.md";t.default=r.exports},374:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("div",[n("p",[e._v("当然"),n("code",[e._v("selected")]),e._v("是选中, "),n("code",[e._v("disabled")]),e._v("是禁用")])]),n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n data: [\n {name: '水果', value: 1, selected: true, disabled: true},\n {name: '蔬菜', value: 2, selected: true},\n {name: '桌子', value: 3, disabled: true},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("demo-block",[n("div",[n("p",[n("code",[e._v("initValue")]),e._v("的优先级大于选项中的"),n("code",[e._v("selected")])])]),n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo5 = xmSelect.render({\n el: '#demo1', \n initValue: [4],\n data: [\n {name: '水果', value: 1, selected: true, disabled: true},\n {name: '蔬菜', value: 2, selected: true},\n {name: '桌子', value: 3, disabled: true},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",data:[{name:"水果",value:1,selected:!0,disabled:!0},{name:"蔬菜",value:2,selected:!0},{name:"桌子",value:3,disabled:!0},{name:"北京",value:4}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",initValue:[4],data:[{name:"水果",value:1,selected:!0,disabled:!0},{name:"蔬菜",value:2,selected:!0},{name:"桌子",value:3,disabled:!0},{name:"北京",value:4}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"mo-ren-xuan-zhong"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-ren-xuan-zhong","aria-hidden":"true"}},[this._v("¶")]),this._v(" 默认选中")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"shi-yongselected-shu-xing"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#shi-yongselected-shu-xing","aria-hidden":"true"}},[this._v("¶")]),this._v(" 使用"),t("code",[this._v("selected")]),this._v("属性")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"shi-yonginitvalue-jin-xing-chu-shi-hua"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#shi-yonginitvalue-jin-xing-chu-shi-hua","aria-hidden":"true"}},[this._v("¶")]),this._v(" 使用initValue进行初始化")])}],!1,null,null,null);r.options.__file="docs/mds/XM03.md";t.default=r.exports},375:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("div",[t("p",[this._v("事实证明分页是好使的 ^_^")])]),t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v('<div id="demo1" class="xm-select-demo"></div>\n<button class="btn" id="demo1-test1">测试1000条</button>\n<button class="btn" id="demo1-test2">测试10000条</button>\n<button class="btn" id="demo1-test3">测试10000条+分页</button>\n<pre id="demo1-result"></pre>\n\n<script>\nfunction run(count, paging){\n //生成数据\n var data = [];\n for(var i = 0; i < count; i++){\n data.push({\n name: \'测试数据\' + i,\n value: i,\n })\n }\n \n //记录开始渲染时间\n var startTime = Date.now();\n \n var demo1 = xmSelect.render({\n el: \'#demo1\', \n paging,\n data\n })\n \n //记录结束时间\n var endTime = Date.now();\n \n document.getElementById(\'demo1-result\').innerText = `渲染耗时: ${endTime - startTime} ms`\n}\n\ndocument.getElementById(\'demo1-test1\').onclick = function(){\n run(1000, false)\n};\n\ndocument.getElementById(\'demo1-test2\').onclick = function(){\n run(10000, false)\n};\n\ndocument.getElementById(\'demo1-test3\').onclick = function(){\n run(10000, true)\n};\n\nrun(1000, false);\n\n<\/script>\n')])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test1"}},[this._v("测试1000条")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test2"}},[this._v("测试10000条")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-test3"}},[this._v("测试10000条+分页")]),this._v(" "),t("pre",{attrs:{id:"demo1-result"}})])}],mounted:function(){this.$nextTick(function(){function e(e,t){for(var n=[],a=0;a<e;a++)n.push({name:"测试数据"+a,value:a});var i=Date.now(),s=(xmSelect.render({el:"#demo1",paging:t,data:n}),Date.now());document.getElementById("demo1-result").innerText="渲染耗时: ".concat(s-i," ms")}document.getElementById("demo1-test1").onclick=function(){e(1e3,!1)},document.getElementById("demo1-test2").onclick=function(){e(1e4,!1)},document.getElementById("demo1-test3").onclick=function(){e(1e4,!0)},e(1e3,!1)})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"xing-neng-ce-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xing-neng-ce-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 性能测试")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"shu-ju-xuan-ran-hao-shi-ce-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#shu-ju-xuan-ran-hao-shi-ce-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 数据渲染耗时测试")])}],!1,null,null,null);r.options.__file="docs/mds/XM17.md";t.default=r.exports},376:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n tips: '你喜欢什么水果呢?',\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n empty: '呀, 没有数据呢',\n data: [ ]\n})\n<\/script>\n")])])])],2),this._m(3),t("demo-block",[t("template",{slot:"source"},[t("element-demo2")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n filterable: true,\n searchTips: '你想吃什么水果吧',\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",tips:"你喜欢什么水果呢?",data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",empty:"呀, 没有数据呢",data:[]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",filterable:!0,searchTips:"你想吃什么水果吧",data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"xiu-gai-ti-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gai-ti-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改提示")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xiu-gai-xuan-xiang-ti-shi-wen-zi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gai-xuan-xiang-ti-shi-wen-zi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改选项提示文字")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xiu-gai-kong-shu-ju-ti-shi-wen-zi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gai-kong-shu-ju-ti-shi-wen-zi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改空数据提示文字")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xiu-gai-sou-suo-ti-shi-wen-zi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gai-sou-suo-ti-shi-wen-zi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改搜索提示文字")])}],!1,null,null,null);r.options.__file="docs/mds/XM04.md";t.default=r.exports},377:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("p",[this._v("实时监听多选的选中状态变化")]),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n on({ arr, item, selected }){\n alert(`name: ${item.name}, 状态: ${selected}`)\n },\n data: [\n {name: '张三', value: 'zhangsan', selected: true},\n {name: '李四', value: 'lisi', selected: true},\n {name: '王五', value: 'wangwu'},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("p",[this._v("选中北京后, 不能选中上海, 二者互斥")]),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n on({ arr, item, selected }){\n if(selected){\n var index = arr.findIndex(i => i.mutex == item.mutex && i.value != item.value);\n if(index != -1){\n arr.splice(index, 1);\n }\n }\n },\n data: [\n {name: '北京', value: 1, mutex: 1, selected: true},\n {name: '上海', value: 2, mutex: 1},\n {name: '广州', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",on:function(e){e.arr;var t=e.item,n=e.selected;alert("name: ".concat(t.name,", 状态: ").concat(n))},data:[{name:"张三",value:"zhangsan",selected:!0},{name:"李四",value:"lisi",selected:!0},{name:"王五",value:"wangwu"}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",on:function(e){var t=e.arr,n=e.item;if(e.selected){var a=t.findIndex(function(e){return e.mutex==n.mutex&&e.value!=n.value});-1!=a&&t.splice(a,1)}},data:[{name:"北京",value:1,mutex:1,selected:!0},{name:"上海",value:2,mutex:1},{name:"广州",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"jian-ting-xuan-ze"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jian-ting-xuan-ze","aria-hidden":"true"}},[this._v("¶")]),this._v(" 监听选择")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"shi-shi-jian-ting"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#shi-shi-jian-ting","aria-hidden":"true"}},[this._v("¶")]),this._v(" 实时监听")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jian-ting-dong-tai-fu-zhi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jian-ting-dong-tai-fu-zhi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 监听动态复制")])}],!1,null,null,null);r.options.__file="docs/mds/XM16.md";t.default=r.exports},378:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("div",[n("p",[e._v("默认按照"),n("code",[e._v("name")]),e._v("进行搜索")])]),n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n filterable: true,\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("demo-block",[n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n filterable: true,\n filterMethod: function(val, item, index, prop){\n if(val == item.value){//把value相同的搜索出来\n return true;\n }\n if(item.name.indexOf(val) != -1){//名称中包含的搜索出来\n return true;\n }\n return false;//不知道的就不管了\n },\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),e._m(3),e._m(4),n("demo-block",[n("div",[n("p",[n("code",[e._v("delay: 2000")]),e._v(" 输入停止2s后进行搜索过滤")])]),n("template",{slot:"source"},[n("element-demo2")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n filterable: true,\n delay: 2000,\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),e._m(5),e._m(6),e._m(7),n("p",[e._v("第三部: 重写搜索回调")]),n("p",[e._v("简单吧, 记得Star ^_^")]),n("demo-block",[n("div",[n("p",[n("code",[e._v("render")]),e._v("后, 就会进行一次回调, 用于渲染第一次数据")])]),n("template",{slot:"source"},[n("element-demo3")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo4\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo4 = xmSelect.render({\n el: '#demo4', \n filterable: true,\n remoteSearch: true,\n remoteMethod: function(val, cb){\n //这里模拟3s后返回数据\n setTimeout(function(){\n //需要回传一个数组\n cb([\n {name: '水果' + val, value: val + 1},\n {name: '蔬菜' + val, value: val + 2},\n {name: '桌子' + val, value: val + 3},\n {name: '北京' + val, value: val + 4},\n ])\n }, 3000)\n },\n data: []\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",filterable:!0,data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",filterable:!0,filterMethod:function(e,t,n,a){return e==t.value||-1!=t.name.indexOf(e)},data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",filterable:!0,delay:2e3,data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo3":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo4"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo4",filterable:!0,remoteSearch:!0,remoteMethod:function(e,t){setTimeout(function(){t([{name:"水果"+e,value:e+1},{name:"蔬菜"+e,value:e+2},{name:"桌子"+e,value:e+3},{name:"北京"+e,value:e+4}])},3e3)},data:[]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"sou-suo-mo-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#sou-suo-mo-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 搜索模式")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mo-ren-sou-suo"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-ren-sou-suo","aria-hidden":"true"}},[this._v("¶")]),this._v(" 默认搜索")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"chong-xie-sou-suo-fang-fa"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#chong-xie-sou-suo-fang-fa","aria-hidden":"true"}},[this._v("¶")]),this._v(" 重写搜索方法")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"sou-suo-yan-chi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#sou-suo-yan-chi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 搜索延迟")])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("为了提高有效搜索, 当停止输入"),t("code",[this._v("500ms")]),this._v("后才开始进行过滤搜索, 当然这个"),t("code",[this._v("500")]),this._v("你也可以进行修改")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-sou-suo-yuan-cheng-sou-suo"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-sou-suo-yuan-cheng-sou-suo","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义搜索 (远程搜索)")])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("第一步: 需要先开启搜索 "),t("code",[this._v("filterable: true,")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("p",[this._v("第二步: 开启自定义搜索 "),t("code",[this._v("remoteSearch: true")])])}],!1,null,null,null);r.options.__file="docs/mds/XM05.md";t.default=r.exports},379:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div style=\"height: 500px\">占位div, 演示效果使用, 底部空间不足时会自动向上展开</div>\n\n<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n direction: 'auto',\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n direction: 'up',\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2),this._m(3),t("demo-block",[t("template",{slot:"source"},[t("element-demo2")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n direction: 'down',\n data: [\n {name: '水果', value: 1},\n {name: '蔬菜', value: 2},\n {name: '桌子', value: 3},\n {name: '北京', value: 4},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticStyle:{height:"500px"}},[this._v("占位div, 演示效果使用, 底部空间不足时会自动向上展开")]),this._v(" "),t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",direction:"auto",data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",direction:"up",data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",direction:"down",data:[{name:"水果",value:1},{name:"蔬菜",value:2},{name:"桌子",value:3},{name:"北京",value:4}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"xia-la-fang-xiang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xia-la-fang-xiang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 下拉方向")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-dongauto"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-dongauto","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自动"),t("code",[this._v("auto")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"da-qia-xiang-shangup"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#da-qia-xiang-shangup","aria-hidden":"true"}},[this._v("¶")]),this._v(" 打卡向上"),t("code",[this._v("up")])])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"da-kai-xiang-xiadown"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#da-kai-xiang-xiadown","aria-hidden":"true"}},[this._v("¶")]),this._v(" 打开向下"),t("code",[this._v("down")])])}],!1,null,null,null);r.options.__file="docs/mds/XM06.md";t.default=r.exports},380:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 'zhangsan', selected: true},\n {name: '李四', value: 'lisi', selected: true},\n {name: '王五', value: 'wangwu'},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n template({ item, sels, name, value }){\n return name + '<span style=\"position: absolute; right: 10px; color: #8799a3\">'+value+'</span>' \n },\n data: [\n {name: '张三', value: 'zhangsan', selected: true},\n {name: '李四', value: 'lisi', selected: true},\n {name: '王五', value: 'wangwu'},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",data:[{name:"张三",value:"zhangsan",selected:!0},{name:"李四",value:"lisi",selected:!0},{name:"王五",value:"wangwu"}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",template:function(e){e.item,e.sels;return e.name+'<span style="position: absolute; right: 10px; color: #8799a3">'+e.value+"</span>"},data:[{name:"张三",value:"zhangsan",selected:!0},{name:"李四",value:"lisi",selected:!0},{name:"王五",value:"wangwu"}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"gou-jian-xuan-xiang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#gou-jian-xuan-xiang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 构建选项")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"mo-ren-xuan-ran"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#mo-ren-xuan-ran","aria-hidden":"true"}},[this._v("¶")]),this._v(" 默认渲染")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-xuan-ran"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-xuan-ran","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义渲染")])}],!1,null,null,null);r.options.__file="docs/mds/XM15.md";t.default=r.exports},381:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("p",[this._v("修改一下背景色和外边距吧")]),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n style: {\n backgroundColor: 'red',\n marginLeft: '200px',\n },\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n height: '50px',\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",style:{backgroundColor:"red",marginLeft:"200px"},data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",height:"50px",data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"zi-ding-yi-yang-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-yang-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义样式")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"sui-bian-shi-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#sui-bian-shi-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 随便试试")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"xiu-gai-xia-la-kuang-de-zui-da-gao-du"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xiu-gai-xia-la-kuang-de-zui-da-gao-du","aria-hidden":"true"}},[this._v("¶")]),this._v(" 修改下拉框的最大高度")])}],!1,null,null,null);r.options.__file="docs/mds/XM07.md";t.default=r.exports},382:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("demo-block",[n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n model: {\n label: {\n type: 'block',\n block: {\n //最大显示数量, 0:不限制\n showCount: 0,\n //是否显示删除图标\n showIcon: false,\n }\n }\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(3),n("demo-block",[n("template",{slot:"source"},[n("element-demo2")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n model: {\n label: {\n type: 'block',\n block: {\n //最大显示数量, 0:不限制\n showCount: 1,\n //是否显示删除图标\n showIcon: true,\n }\n }\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),e._m(4),n("demo-block",[n("template",{slot:"source"},[n("element-demo3")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo4\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo4 = xmSelect.render({\n el: '#demo4', \n model: {\n label: {\n type: 'text',\n //使用字符串拼接的方式\n text: {\n //左边拼接的字符\n left: '【',\n //右边拼接的字符\n right: '】',\n //中间的分隔符\n separator: ',',\n },\n }\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ],\n})\n<\/script>\n")])])])],2),e._m(5),n("demo-block",[n("template",{slot:"source"},[n("element-demo4")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo5\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo5 = xmSelect.render({\n el: '#demo5', \n model: {\n label: {\n type: 'xxxx', //自定义与下面的对应\n xxxx: {\n template(data, sels){\n return \"已选中 \" + sels.length + \" 项, 共 \" + data.length + \" 项\"\n }\n },\n }\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ],\n})\n<\/script>\n")])])])],2),e._m(6),n("demo-block",[n("template",{slot:"source"},[n("element-demo5")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo6\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo6 = xmSelect.render({\n el: '#demo6', \n model: {\n label: {\n type: 'xxxx', //自定义与下面的对应\n xxxx: {\n template(data, sels){\n //也可以是html\n return `<div style=\"color: red;\">${sels.length} / ${data.length}</div>`\n }\n },\n }\n },\n data: [\n {name: '张三', value: 1, selected: true},\n {name: '李四', value: 2, selected: true},\n {name: '王五', value: 3},\n ],\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",model:{label:{type:"block",block:{showCount:0,showIcon:!1}}},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",model:{label:{type:"block",block:{showCount:1,showIcon:!0}}},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo3":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo4"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo4",model:{label:{type:"text",text:{left:"【",right:"】",separator:","}}},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo4":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo5"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo5",model:{label:{type:"xxxx",xxxx:{template:function(e,t){return"已选中 "+t.length+" 项, 共 "+e.length+" 项"}}}},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}(),"element-demo5":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo6"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo6",model:{label:{type:"xxxx",xxxx:{template:function(e,t){return'<div style="color: red;">'.concat(t.length," / ").concat(e.length,"</div>")}}}},data:[{name:"张三",value:1,selected:!0},{name:"李四",value:2,selected:!0},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"xian-shi-fang-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#xian-shi-fang-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 显示方式")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"fang-kuai-xing-zhuang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#fang-kuai-xing-zhuang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 方块形状")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"fang-kuai-xing-zhuang-yin-cang-shan-chu-tu-biao"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#fang-kuai-xing-zhuang-yin-cang-shan-chu-tu-biao","aria-hidden":"true"}},[this._v("¶")]),this._v(" 方块形状, 隐藏删除图标")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"fang-kuai-xing-zhuang-chao-guo1-ge-yin-cang"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#fang-kuai-xing-zhuang-chao-guo1-ge-yin-cang","aria-hidden":"true"}},[this._v("¶")]),this._v(" 方块形状, 超过1个隐藏")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"jian-dan-pin-jie-xing-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#jian-dan-pin-jie-xing-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 简单拼接形式")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-xian-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-xian-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义显示")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-xian-shihtml"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-xian-shihtml","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义显示HTML")])}],!1,null,null,null);r.options.__file="docs/mds/XM14.md";t.default=r.exports},383:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),n("demo-block",[n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n paging: true,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n {name: '赵六', value: 4},\n {name: '苹果', value: 5},\n {name: '香蕉', value: 6},\n {name: '凤梨', value: 7},\n {name: '葡萄', value: 8},\n {name: '樱桃', value: 9},\n {name: '车厘子', value: 10},\n {name: '火龙果', value: 11},\n ]\n})\n<\/script>\n")])])])],2),e._m(2),n("p",[e._v("每页3条")]),n("demo-block",[n("template",{slot:"source"},[n("element-demo1")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n paging: true,\n pageSize: 3,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n {name: '赵六', value: 4},\n {name: '苹果', value: 5},\n {name: '香蕉', value: 6},\n {name: '凤梨', value: 7},\n {name: '葡萄', value: 8},\n {name: '樱桃', value: 9},\n {name: '车厘子', value: 10},\n {name: '火龙果', value: 11},\n ]\n})\n<\/script>\n")])])])],2),e._m(3),n("demo-block",[n("template",{slot:"source"},[n("element-demo2")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v('<div id="demo3" class="xm-select-demo"></div>\n<button class="btn" id="demo3-5">每页5条</button>\n<button class="btn" id="demo3-10">每页10条</button>\n<button class="btn" id="demo3-20">每页20条</button>\n\n<script>\nvar data = [];\nfor(var i = 0 ; i < 100 ; i++ ){\n data.push({\n name: \'测试数据\' + i,\n value: i,\n })\n}\n\nvar demo3 = xmSelect.render({\n el: \'#demo3\', \n paging: true,\n pageSize: 5,\n filterable: true,\n data\n})\n\ndocument.getElementById(\'demo3-5\').onclick = function(){\n demo3.update({\n pageSize: 5\n })\n}\n\ndocument.getElementById(\'demo3-10\').onclick = function(){\n demo3.update({\n pageSize: 10\n })\n}\n\ndocument.getElementById(\'demo3-20\').onclick = function(){\n demo3.update({\n pageSize: 20\n })\n}\n\n<\/script>\n')])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",paging:!0,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3},{name:"赵六",value:4},{name:"苹果",value:5},{name:"香蕉",value:6},{name:"凤梨",value:7},{name:"葡萄",value:8},{name:"樱桃",value:9},{name:"车厘子",value:10},{name:"火龙果",value:11}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",paging:!0,pageSize:3,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3},{name:"赵六",value:4},{name:"苹果",value:5},{name:"香蕉",value:6},{name:"凤梨",value:7},{name:"葡萄",value:8},{name:"樱桃",value:9},{name:"车厘子",value:10},{name:"火龙果",value:11}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo3-5"}},[this._v("每页5条")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo3-10"}},[this._v("每页10条")]),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo3-20"}},[this._v("每页20条")])])}],mounted:function(){this.$nextTick(function(){for(var e=[],t=0;t<100;t++)e.push({name:"测试数据"+t,value:t});var n=xmSelect.render({el:"#demo3",paging:!0,pageSize:5,filterable:!0,data:e});document.getElementById("demo3-5").onclick=function(){n.update({pageSize:5})},document.getElementById("demo3-10").onclick=function(){n.update({pageSize:10})},document.getElementById("demo3-20").onclick=function(){n.update({pageSize:20})}})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"fen-ye"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#fen-ye","aria-hidden":"true"}},[this._v("¶")]),this._v(" 分页")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"qi-yong-fen-ye"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#qi-yong-fen-ye","aria-hidden":"true"}},[this._v("¶")]),this._v(" 启用分页")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"zi-ding-yi-tiao-shu"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-tiao-shu","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义条数")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"sou-suo-fen-ye"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#sou-suo-fen-ye","aria-hidden":"true"}},[this._v("¶")]),this._v(" 搜索+分页")])}],!1,null,null,null);r.options.__file="docs/mds/XM08.md";t.default=r.exports},384:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement,t=this._self._c||e;return t("section",{staticClass:"content element-doc"},[this._m(0),this._m(1),t("demo-block",[t("template",{slot:"source"},[t("element-demo0")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n radio: true,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),this._m(2),t("demo-block",[t("template",{slot:"source"},[t("element-demo1")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo2\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo2 = xmSelect.render({\n el: '#demo2', \n radio: true,\n clickClose: true,\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2),this._m(3),t("demo-block",[t("template",{slot:"source"},[t("element-demo2")],1),t("template",{slot:"highlight"},[t("pre",{pre:!0},[t("code",{pre:!0,attrs:{class:"html"}},[this._v("<div id=\"demo3\" class=\"xm-select-demo\"></div>\n\n<script>\nvar demo3 = xmSelect.render({\n el: '#demo3', \n radio: true,\n clickClose: true,\n model: {\n label: {\n type: 'text',\n text: {\n //左边拼接的字符\n left: '',\n //右边拼接的字符\n right: '',\n //中间的分隔符\n separator: ', ',\n },\n }\n },\n data: [\n {name: '张三', value: 1},\n {name: '李四', value: 2},\n {name: '王五', value: 3},\n ]\n})\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo1",radio:!0,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo1":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo2"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo2",radio:!0,clickClose:!0,data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}(),"element-demo2":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo3"}})])}],mounted:function(){this.$nextTick(function(){xmSelect.render({el:"#demo3",radio:!0,clickClose:!0,model:{label:{type:"text",text:{left:"",right:"",separator:", "}}},data:[{name:"张三",value:1},{name:"李四",value:2},{name:"王五",value:3}]})})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"dan-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#dan-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" 单选")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"kai-qi-dan-xuan"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#kai-qi-dan-xuan","aria-hidden":"true"}},[this._v("¶")]),this._v(" 开启单选")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"dan-xuan-wan-guan-bi-xia-la"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#dan-xuan-wan-guan-bi-xia-la","aria-hidden":"true"}},[this._v("¶")]),this._v(" 单选完关闭下拉")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"geng-huan-xian-shi-fang-shi"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#geng-huan-xian-shi-fang-shi","aria-hidden":"true"}},[this._v("¶")]),this._v(" 更换显示方式")])}],!1,null,null,null);r.options.__file="docs/mds/XM09.md";t.default=r.exports},385:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[e._m(0),e._m(1),e._m(2),n("demo-block",[n("div",[n("p",[e._v("我的"),n("code",[e._v("name")]),e._v("是"),n("code",[e._v("label")]),e._v(", 我的"),n("code",[e._v("value")]),e._v("是"),n("code",[e._v("id")]),e._v(", 我有其他属性"),n("code",[e._v("group")])])]),n("template",{slot:"source"},[n("element-demo0")],1),n("template",{slot:"highlight"},[n("pre",{pre:!0},[n("code",{pre:!0,attrs:{class:"html"}},[e._v("<div id=\"demo1\" class=\"xm-select-demo\"></div>\n<button class=\"btn\" id=\"demo1-getValue\">获取选中值</button>\n<pre id=\"demo1-value\"></pre>\n\n<script>\nvar demo1 = xmSelect.render({\n el: '#demo1', \n prop: {\n name: 'label',\n value: 'id',\n },\n data: [\n {label: '张三', id: 1, group: 1},\n {label: '李四', id: 2, group: 1},\n {label: '王五', id: 3, group: 2},\n ]\n})\n\ndocument.getElementById('demo1-getValue').onclick = function(){\n //获取当前多选选中的值\n var selectArr = demo1.getValue();\n document.getElementById('demo1-value').innerHTML = JSON.stringify(selectArr, null, 2);\n}\n<\/script>\n")])])])],2)],1)};a._withStripped=!0;var i={name:"component-doc",components:{"element-demo0":function(){var e=function(){var e=this.$createElement;this._self._c;return this._m(0)};return e._withStripped=!0,{render:e,staticRenderFns:[function(){var e=this.$createElement,t=this._self._c||e;return t("div",[t("div",{staticClass:"xm-select-demo",attrs:{id:"demo1"}}),this._v(" "),t("button",{staticClass:"btn",attrs:{id:"demo1-getValue"}},[this._v("获取选中值")]),this._v(" "),t("pre",{attrs:{id:"demo1-value"}})])}],mounted:function(){this.$nextTick(function(){var e=xmSelect.render({el:"#demo1",prop:{name:"label",value:"id"},data:[{label:"张三",id:1,group:1},{label:"李四",id:2,group:1},{label:"王五",id:3,group:2}]});document.getElementById("demo1-getValue").onclick=function(){var t=e.getValue();document.getElementById("demo1-value").innerHTML=JSON.stringify(t,null,2)}})}}}()}},s=n(4),r=Object(s.a)(i,a,[function(){var e=this.$createElement,t=this._self._c||e;return t("h2",{attrs:{id:"zi-ding-yi-shu-xing"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#zi-ding-yi-shu-xing","aria-hidden":"true"}},[this._v("¶")]),this._v(" 自定义属性")])},function(){var e=this.$createElement,t=this._self._c||e;return t("h3",{attrs:{id:"geng-huan-shu-xingkey"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#geng-huan-shu-xingkey","aria-hidden":"true"}},[this._v("¶")]),this._v(" 更换属性key")])},function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("p",[e._v("也许你的数据库返回的并不是"),n("code",[e._v("name")]),e._v("和"),n("code",[e._v("value")]),e._v(", 也许你提交的时候不止"),n("code",[e._v("name")]),e._v("和"),n("code",[e._v("value")]),e._v(", 怎么办? 自定义就行")])}],!1,null,null,null);r.options.__file="docs/mds/XM11.md";t.default=r.exports},386:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement;this._self._c;return this._m(0)};a._withStripped=!0;var i=n(4),s=Object(i.a)({},a,[function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[n("h2",{attrs:{id:"pei-zhi-xiang-yu-fang-fa"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#pei-zhi-xiang-yu-fang-fa","aria-hidden":"true"}},[e._v("¶")]),e._v(" 配置项与方法")]),n("h3",{attrs:{id:"pei-zhi-xiang"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#pei-zhi-xiang","aria-hidden":"true"}},[e._v("¶")]),e._v(" 配置项")]),n("table",[n("thead",[n("tr",[n("th",[e._v("参数")]),n("th",[e._v("说明")]),n("th",[e._v("类型")]),n("th",[e._v("可选值")]),n("th",[e._v("默认值")])])]),n("tbody",[n("tr",[n("td",[e._v("el")]),n("td",[e._v("渲染对象, css选择器")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("language")]),n("td",[e._v("语言选择")]),n("td",[e._v("string")]),n("td",[e._v("zn / en")]),n("td",[e._v("zn")])]),n("tr",[n("td",[e._v("data")]),n("td",[e._v("显示的数据")]),n("td",[e._v("array")]),n("td",[e._v("-")]),n("td",[e._v("[ ]")])]),n("tr",[n("td",[e._v("initValue")]),n("td",[e._v("初始化选中的数据, 需要在data中存在")]),n("td",[e._v("array")]),n("td",[e._v("-")]),n("td",[e._v("null")])]),n("tr",[n("td",[e._v("tips")]),n("td",[e._v("默认提示, 类似于placeholder")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("请选择")])]),n("tr",[n("td",[e._v("empty")]),n("td",[e._v("空数据提示")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("暂无数据")])]),n("tr",[n("td",[e._v("filterable")]),n("td",[e._v("是否开启搜索")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("searchTips")]),n("td",[e._v("搜索提示")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("请选择")])]),n("tr",[n("td",[e._v("delay")]),n("td",[e._v("搜索延迟 ms")]),n("td",[e._v("int")]),n("td",[e._v("-")]),n("td",[e._v("500")])]),n("tr",[n("td",[e._v("filterMethod")]),n("td",[e._v("搜索回调函数")]),n("td",[e._v("function(val, item, index, prop) val: 当前搜索值, item: 每个option选项, index: 位置数据中的下标, prop: 定义key")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("remoteSearch")]),n("td",[e._v("是否开启自定义搜索 (远程搜索)")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("remoteMethod")]),n("td",[e._v("自定义搜索回调函数")]),n("td",[e._v("function(val, cb) val: 当前搜索值, cb: 回调函数, 需要回调一个数组, 结构同data")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("direction")]),n("td",[e._v("下拉方向")]),n("td",[e._v("string")]),n("td",[e._v("auto / up / down")]),n("td",[e._v("auto")])]),n("tr",[n("td",[e._v("style")]),n("td",[e._v("自定义样式")]),n("td",[e._v("object")]),n("td",[e._v("-")]),n("td",[e._v("{ }")])]),n("tr",[n("td",[e._v("height")]),n("td",[e._v("默认最大高度")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("200px")])]),n("tr",[n("td",[e._v("paging")]),n("td",[e._v("是否开启自定义分页")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("pageSize")]),n("td",[e._v("分页条数")]),n("td",[e._v("int")]),n("td",[e._v("-")]),n("td",[e._v("10")])]),n("tr",[n("td",[e._v("radio")]),n("td",[e._v("是否开启单选模式")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("repeat")]),n("td",[e._v("是否开启重复性模式")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("clickClose")]),n("td",[e._v("是否点击选项后自动关闭下拉框")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("prop")]),n("td",[e._v("自定义属性名称, 具体看下表")]),n("td",[e._v("object")]),n("td",[e._v("-")]),n("td")]),n("tr",[n("td",[e._v("theme")]),n("td",[e._v("主题配置, 具体看下表")]),n("td",[e._v("object")]),n("td",[e._v("-")]),n("td")]),n("tr",[n("td",[e._v("model")]),n("td",[e._v("模型, 多选的展示方式, 具体见下表")]),n("td",[e._v("object")]),n("td",[e._v("-")]),n("td")]),n("tr",[n("td",[e._v("show")]),n("td",[e._v("展开下拉的回调")]),n("td",[e._v("function")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("hide")]),n("td",[e._v("隐藏下拉的回调")]),n("td",[e._v("function")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("template")]),n("td",[e._v("自定义渲染选项")]),n("td",[e._v("function({ item, sels, name, value })")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("on")]),n("td",[e._v("监听选中变化")]),n("td",[e._v("function({ arr, item, selected })")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("max")]),n("td",[e._v("设置多选选中上限")]),n("td",[e._v("int")]),n("td",[e._v("-")]),n("td",[e._v("0")])]),n("tr",[n("td",[e._v("maxMethod")]),n("td",[e._v("达到选中上限的回到")]),n("td",[e._v("function(sels, item), sels: 已选中数据, item: 当前选中的值")]),n("td",[e._v("-")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("name")]),n("td",[e._v("表单提交时的name")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("select")])]),n("tr",[n("td",[e._v("toolbar")]),n("td",[e._v("工具条, 具体看下表")]),n("td",[e._v("object")]),n("td",[e._v("-")]),n("td",[e._v("-")])])])]),n("h3",{attrs:{id:"prop"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#prop","aria-hidden":"true"}},[e._v("¶")]),e._v(" prop")]),n("table",[n("thead",[n("tr",[n("th",[e._v("参数")]),n("th",[e._v("说明")]),n("th",[e._v("类型")]),n("th",[e._v("可选值")]),n("th",[e._v("默认值")])])]),n("tbody",[n("tr",[n("td",[e._v("name")]),n("td",[e._v("显示名称")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("name")])]),n("tr",[n("td",[e._v("value")]),n("td",[e._v("选中值")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("value")])]),n("tr",[n("td",[e._v("selected")]),n("td",[e._v("是否选中")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("selected")])]),n("tr",[n("td",[e._v("disabled")]),n("td",[e._v("是否警用")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("disabled")])])])]),n("h3",{attrs:{id:"theme"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#theme","aria-hidden":"true"}},[e._v("¶")]),e._v(" theme")]),n("table",[n("thead",[n("tr",[n("th",[e._v("参数")]),n("th",[e._v("说明")]),n("th",[e._v("类型")]),n("th",[e._v("可选值")]),n("th",[e._v("默认值")])])]),n("tbody",[n("tr",[n("td",[e._v("color")]),n("td",[e._v("主题颜色")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("#009688")])]),n("tr",[n("td",[e._v("maxColor")]),n("td",[e._v("选中上限闪烁边框颜色")]),n("td",[e._v("string")]),n("td",[e._v("-")]),n("td",[e._v("#e54d42")])])])]),n("h3",{attrs:{id:"model"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#model","aria-hidden":"true"}},[e._v("¶")]),e._v(" model")]),n("p",[e._v("目前仅配置label即可")]),n("pre",[n("code",[e._v("model: {\n label: {\n //使用方式\n type: 'block',\n //使用字符串拼接的方式\n text: {\n //左边拼接的字符\n left: '',\n //右边拼接的字符\n right: '',\n //中间的分隔符\n separator: ', ',\n },\n //使用方块显示\n block: {\n //最大显示数量, 0:不限制\n showCount: 0,\n //是否显示删除图标\n showIcon: true,\n },\n //自定义文字\n count: {\n //函数处理\n template(data, sels){\n //data: 所有的数据\n //sels: 选中的数据\n return `已选中 ${sels.length} 项, 共 ${data.length} 项`\n }\n },\n },\n},\n")])]),n("h3",{attrs:{id:"toolbar"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#toolbar","aria-hidden":"true"}},[e._v("¶")]),e._v(" toolbar")]),n("table",[n("thead",[n("tr",[n("th",[e._v("参数")]),n("th",[e._v("说明")]),n("th",[e._v("类型")]),n("th",[e._v("可选值")]),n("th",[e._v("默认值")])])]),n("tbody",[n("tr",[n("td",[e._v("show")]),n("td",[e._v("是否展示工具条")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("false")])]),n("tr",[n("td",[e._v("showIcon")]),n("td",[e._v("是否显示工具图标")]),n("td",[e._v("boolean")]),n("td",[e._v("true / false")]),n("td",[e._v("true")])]),n("tr",[n("td",[e._v("list")]),n("td",[e._v("工具条数组 (默认有 全选/清空, 可以自定义)")]),n("td",[e._v("array")]),n("td",[e._v("-")]),n("td",[e._v('[ "ALL", "CLEAR" ]')])])])]),n("ul",[n("li",[e._v("自定义方式")])]),n("pre",[n("code",[e._v('\nlist: [ "ALL", "CLEAR", \n {\n //显示图标, 可以是layui内置的图标, 也可以是自己引入的图标\n //传入的icon会转化为 <i class="layui-icon layui-icon-face-smile"></i>\n icon: \'layui-icon layui-icon-face-smile\',\n //显示名称 \n name: \'xxx\',\n //点击时触发的回调\n method: function(data){\n //data 当前页面的数据\n \n }\n } \n]\n\n\n')])]),n("h3",{attrs:{id:"fang-fa"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#fang-fa","aria-hidden":"true"}},[e._v("¶")]),e._v(" 方法")]),n("div",{staticClass:"warning"},[n("p",[e._v("xmSelect.render()后会返回一个xmSelect对象, 可以进行方法调用")])]),n("table",[n("thead",[n("tr",[n("th",[e._v("事件名")]),n("th",[e._v("说明")]),n("th",[e._v("参数")])])]),n("tbody",[n("tr",[n("td",[e._v("getValue")]),n("td",[e._v("获取当前选中的数据")]),n("td",[e._v("(type: 类型), 可选值: name, nameStr, value, valueStr")])]),n("tr",[n("td",[e._v("setValue")]),n("td",[e._v("动态设置数据")]),n("td",[e._v("(array: 选中的数据, show: 是否展开下拉)")])]),n("tr",[n("td",[e._v("opened")]),n("td",[e._v("主动展开下拉")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("closed")]),n("td",[e._v("主动关闭下拉")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("render")]),n("td",[e._v("重新渲染多选")]),n("td",[e._v("(options: 见配置项)")])]),n("tr",[n("td",[e._v("reset")]),n("td",[e._v("重置为上一次的render状态")]),n("td",[e._v("-")])]),n("tr",[n("td",[e._v("update")]),n("td",[e._v("更新多选选中, reset不保留")]),n("td",[e._v("-")])])])])])}],!1,null,null,null);s.options.__file="docs/mds/options.md";t.default=s.exports},387:function(e,t,n){"use strict";n.r(t);var a=function(){var e=this.$createElement;this._self._c;return this._m(0)};a._withStripped=!0;var i=n(4),s=Object(i.a)({},a,[function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("section",{staticClass:"content element-doc"},[n("h2",{attrs:{id:"chang-jian-wen-ti"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#chang-jian-wen-ti","aria-hidden":"true"}},[e._v("¶")]),e._v(" 常见问题")]),n("h3",{attrs:{id:"formselects-yu-xm-select"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#formselects-yu-xm-select","aria-hidden":"true"}},[e._v("¶")]),e._v(" formSelects 与 xm-select")]),n("p",[n("a",{attrs:{href:"https://github.com/hnzzmsf/layui-formSelects/"}},[e._v("formSelects")]),e._v("是作者很久以前开发的一款多选插件, 在jQuery时代还是相对比较稳定, 不过性能上有很大的问题。痛并思痛后,开始学习其他开源组件的编写方案,最后决定重新开发。")]),n("p",[n("a",{attrs:{href:"https://gitee.com/maplemei/xm-select"}},[e._v("xm-select")]),e._v("作者精心二次开发的组件, 在formSelects的样式基础上进行了性能优化。目前看来还是比较稳定的 ^_^")]),n("h3",{attrs:{id:"1.-zai-na-li-xia-zai"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#1.-zai-na-li-xia-zai","aria-hidden":"true"}},[e._v("¶")]),e._v(" 1.在哪里下载")]),n("p",[n("a",{attrs:{href:"https://gitee.com/maplemei/xm-select/releases"}},[e._v("Gitee码云下载")]),e._v(", 使用时引入"),n("code",[e._v("xm-select.js")]),e._v("即可, 已经内置了css, 具体请看"),n("a",{attrs:{href:"/#/component/install"}},[e._v("入门指南")])]),n("h3",{attrs:{id:"2.-wei-shi-me-duo-xuan-bu-xian-shi"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#2.-wei-shi-me-duo-xuan-bu-xian-shi","aria-hidden":"true"}},[e._v("¶")]),e._v(" 2.为什么多选不显示")]),n("p",[e._v("重要的事情说三遍, 需要渲染, 需要渲染, 需要渲染")]),n("h3",{attrs:{id:"3.-xuan-ran-hou-huan-shi-bu-xian-shi"}},[n("a",{staticClass:"header-anchor",attrs:{href:"#3.-xuan-ran-hou-huan-shi-bu-xian-shi","aria-hidden":"true"}},[e._v("¶")]),e._v(" 3.渲染后还是不显示")]),n("ul",[n("li",[e._v("打开控制台查看是否报错")]),n("li",[e._v("加群: 660408068, 询问")])])])}],!1,null,null,null);s.options.__file="docs/mds/question.md";t.default=s.exports},389:function(e,t,n){var a={"./mds/XM01.md":372,"./mds/XM02.md":363,"./mds/XM03.md":374,"./mds/XM04.md":376,"./mds/XM05.md":378,"./mds/XM06.md":379,"./mds/XM07.md":381,"./mds/XM08.md":383,"./mds/XM09.md":384,"./mds/XM10.md":366,"./mds/XM11.md":385,"./mds/XM12.md":369,"./mds/XM13.md":367,"./mds/XM14.md":382,"./mds/XM15.md":380,"./mds/XM16.md":377,"./mds/XM17.md":375,"./mds/XM18.md":373,"./mds/XM19.md":371,"./mds/ZM01.md":370,"./mds/ZM02.md":365,"./mds/ZM03.md":364,"./mds/install.md":368,"./mds/options.md":386,"./mds/question.md":387};function i(e){var t=s(e);return n(t)}function s(e){if(!n.o(a,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return a[e]}i.keys=function(){return Object.keys(a)},i.resolve=s,e.exports=i,i.id=389}}]); |