bkui-vue 0.0.1-beta.14 → 0.0.1-beta.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -17
- package/README_EN.md +89 -0
- package/dist/bkui-vue.cjs.js +1473 -425
- package/dist/bkui-vue.esm.js +1472 -427
- package/dist/bkui-vue.umd.js +1473 -425
- package/dist/style.css +315 -177
- package/lib/alert/index.js +1 -1
- package/lib/badge/index.js +1 -1
- package/lib/breadcrumb/breadcrumb.css +10 -1
- package/lib/breadcrumb/breadcrumb.d.ts +20 -0
- package/lib/breadcrumb/breadcrumb.less +13 -2
- package/lib/breadcrumb/breadcrumb.variable.css +10 -1
- package/lib/breadcrumb/index.d.ts +37 -1
- package/lib/breadcrumb/index.js +1 -1
- package/lib/button/index.js +1 -1
- package/lib/card/index.js +1 -1
- package/lib/checkbox/index.js +1 -1
- package/lib/components.d.ts +2 -0
- package/lib/date-picker/index.js +1 -1
- package/lib/directives/index.js +1 -1
- package/lib/form/index.js +1 -1
- package/lib/icon/angle-down-fill.d.ts +4 -0
- package/lib/icon/angle-up-fill.d.ts +4 -0
- package/lib/icon/arrows-left.d.ts +4 -0
- package/lib/icon/index.d.ts +7 -3
- package/lib/icon/index.js +1 -1
- package/lib/icon/spinner.d.ts +4 -0
- package/lib/input/index.d.ts +11 -3
- package/lib/input/index.js +2 -2
- package/lib/input/input.css +1 -0
- package/lib/input/input.d.ts +3 -1
- package/lib/input/input.less +4 -3
- package/lib/input/input.variable.css +1 -0
- package/lib/loading/index.js +1 -1
- package/lib/menu/index.js +1 -1
- package/lib/modal/index.js +1 -1
- package/lib/notify/index.js +1 -1
- package/lib/notify/notifyConstructor.d.ts +2 -2
- package/lib/popover/index.d.ts +103 -48
- package/lib/popover/index.js +1 -1
- package/lib/popover/popover.css +22 -13
- package/lib/popover/popover.d.ts +30 -23
- package/lib/popover/popover.less +55 -45
- package/lib/popover/popover.variable.css +22 -13
- package/lib/popover/props.d.ts +77 -0
- package/lib/process/index.js +1 -1
- package/lib/progress/index.d.ts +23 -1
- package/lib/progress/index.js +1 -1
- package/lib/progress/progress.css +0 -3
- package/lib/progress/progress.d.ts +17 -1
- package/lib/progress/progress.less +0 -4
- package/lib/progress/progress.variable.css +0 -3
- package/lib/radio/index.js +1 -1
- package/lib/select/common.d.ts +10 -1
- package/lib/select/index.d.ts +131 -188
- package/lib/select/index.js +2 -2
- package/lib/select/option.d.ts +1 -7
- package/lib/select/optionGroup.d.ts +22 -15
- package/lib/select/select.css +71 -14
- package/lib/select/select.d.ts +40 -55
- package/lib/select/select.less +73 -14
- package/lib/select/select.variable.css +71 -14
- package/lib/shared/bk-helper-core.d.ts +6 -0
- package/lib/shared/bk-popover.d.ts +45 -4
- package/lib/shared/index.d.ts +10 -0
- package/lib/shared/index.js +1 -1
- package/lib/shared/utils.d.ts +6 -0
- package/lib/steps/index.js +1 -1
- package/lib/styles/index.d.ts +1 -0
- package/lib/styles/index.js +1 -1
- package/lib/switcher/index.js +1 -1
- package/lib/switcher/switcher.css +149 -135
- package/lib/switcher/switcher.less +210 -154
- package/lib/switcher/switcher.variable.css +149 -135
- package/lib/tab/index.js +1 -1
- package/lib/table/index.d.ts +76 -1
- package/lib/table/index.js +1 -1
- package/lib/table/props.d.ts +38 -0
- package/lib/table/render.d.ts +1 -1
- package/lib/table/table.css +6 -4
- package/lib/table/table.d.ts +34 -0
- package/lib/table/table.less +4 -4
- package/lib/table/table.variable.css +6 -4
- package/lib/table/utils.d.ts +7 -0
- package/lib/tree/index.d.ts +22 -8
- package/lib/tree/index.js +1 -1
- package/lib/tree/props.d.ts +52 -0
- package/lib/tree/tree.css +16 -7
- package/lib/tree/tree.d.ts +13 -7
- package/lib/tree/tree.less +24 -24
- package/lib/tree/tree.variable.css +16 -7
- package/lib/tree/util.d.ts +3 -44
- package/lib/virtual-render/index.d.ts +395 -0
- package/lib/virtual-render/index.js +1 -0
- package/lib/virtual-render/props.d.ts +147 -0
- package/lib/virtual-render/v-virtual-render.d.ts +7 -0
- package/lib/virtual-render/virtual-render.css +40 -0
- package/lib/virtual-render/virtual-render.d.ts +175 -0
- package/lib/virtual-render/virtual-render.less +51 -0
- package/lib/virtual-render/virtual-render.variable.css +40 -0
- package/package.json +8 -6
package/lib/menu/index.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("@bkui-vue/icon/"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","@bkui-vue/icon/","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e._,e.Shared)}(this,(function(e,t,n,o){"use strict";function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var l={exports:{}};!function(e){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("@bkui-vue/icon/"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","@bkui-vue/icon/","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e._,e.Shared)}(this,(function(e,t,n,o){"use strict";function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var l={exports:{}};!function(e){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports}(l);var a=r(l.exports),u={exports:{}},i={exports:{}},s={exports:{}};!function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,o=new Array(t);n<t;n++)o[n]=e[n];return o},e.exports.__esModule=!0,e.exports.default=e.exports}(s),function(e){var t=s.exports;e.exports=function(e){if(Array.isArray(e))return t(e)},e.exports.__esModule=!0,e.exports.default=e.exports}(i);var c={exports:{}};!function(e){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports}(c);var p={exports:{}};!function(e){var t=s.exports;e.exports=function(e,n){if(e){if("string"==typeof e)return t(e,n);var o=Object.prototype.toString.call(e).slice(8,-1);return"Object"===o&&e.constructor&&(o=e.constructor.name),"Map"===o||"Set"===o?Array.from(e):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?t(e,n):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports}(p);var d={exports:{}};!function(e){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports}(d),function(e){var t=i.exports,n=c.exports,o=p.exports,r=d.exports;e.exports=function(e){return t(e)||n(e)||o(e)||r()},e.exports.__esModule=!0,e.exports.default=e.exports}(u);var f=r(u.exports),v=Symbol("MENU_PROVIDER_KEY"),y=Symbol("MENU_PROVIDER_KEY_PATH"),m=function(){return t.inject(v)},h=function(){var e,n=t.getCurrentInstance(),o=n.parent?n.parent.provides:null===(e=n.vnode.appContext)||void 0===e?void 0:e.provides;return o&&y in o?t.inject(y):{parentInfo:void 0,parentKeys:t.ref([])}},x=function(e){return(e||"").split(" ").filter((function(e){return!!e.trim()}))};function g(e,t){if(e&&t){var n=x(t),o=e.getAttribute("class")||"";if(e.classList){var r;(r=e.classList).remove.apply(r,f(n))}else{n.forEach((function(e){o=o.replace(" ".concat(e," ")," ")}));var l=x(o).join(" ");e.setAttribute("class",l)}}}function b(e,t){if(e){var n,o=e.getAttribute("class")||"",r=x(o),l=(t||"").split(" ").filter((function(e){return!r.includes(e)&&!!e.trim()}));if(e.classList)(n=e.classList).add.apply(n,f(l));else o+=" ".concat(l.join(" ")),e.setAttribute("class",o)}}var I={activeKey:String,collapse:{type:Boolean,default:!1},OpenedKeys:{type:Array},mode:{type:String,default:"vertical"},uniqueOpen:{type:Boolean,default:!0}},_=t.defineComponent({name:"Menu",props:I,emits:["update:activeKey","update:openKeys","click","openChange"],setup:function(e,n){var o=n.slots,r=n.emit,l=t.ref(""),u=t.ref([]),i=t.ref({}),s=t.computed((function(){return e.mode})),c=t.ref(e.collapse),p=t.ref([]);t.watch((function(){return e.OpenedKeys}),(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u.value;u.value=e}),{immediate:!0}),t.watchEffect((function(){void 0!==e.activeKey&&(l.value=e.activeKey)})),t.watch((function(){return e.collapse}),(function(){c.value=e.collapse;var t=f(p.value),n=f(u.value);u.value=c.value?[]:t,p.value=c.value?n:[]}),{immediate:!0});var d;return d={activeKey:l,menuStore:i,registerMenuInfo:function(e,t){i.value=Object.assign(Object.assign({},i.value),a({},e,t))},unregisterMenuInfo:function(e){delete i.value[e],i.value=Object.assign({},i.value)},mode:s.value,openedKeys:u,collapse:c,handleOpenChange:function(t,n){n?e.uniqueOpen?u.value=[t]:u.value.push(t):u.value=u.value.filter((function(e){return e!==t})),r("openChange",n,i.value[t]),r("update:openKeys",f(u.value))},handleActiveChange:function(e){l.value=e,r("click",i.value[e]),r("update:activeKey",e,i.value[e])}},t.provide(v,d),function(){var e;return t.createVNode("div",{class:{"bk-menu":!0,"is-collapse":c.value}},[null===(e=null==o?void 0:o.default)||void 0===e?void 0:e.call(o)])}}}),w=t.defineComponent({name:"MenuItem",props:{needIcon:{type:Boolean,default:!0}},emits:["click"],slots:["icon"],setup:function(e,n){var o,r,l=n.slots,a=n.emit,u=m(),i=u.registerMenuInfo,s=u.unregisterMenuInfo,c=u.activeKey,p=u.handleActiveChange,d=t.getCurrentInstance(),f=h().parentInfo,v=(null===(r=null===(o=d.vnode.key)||void 0===o?void 0:o.toString)||void 0===r?void 0:r.call(o))||String(d.uid),y=t.computed((function(){return c.value===v})),x=t.computed((function(){return e.needIcon}));i(v,{key:v,parentKey:null==f?void 0:f.key});var g=function(e){p(v),a("click",e)};return t.onBeforeUnmount((function(){return s(v)})),function(){var e,n;return t.createVNode("li",{class:{"bk-menu-item":!0,"is-active":y.value},onClick:g},[x.value&&t.createVNode("span",{class:"item-icon"},[(null===(e=null==l?void 0:l.icon)||void 0===e?void 0:e.call(l))||t.createVNode("i",{class:"default-icon"},null)]),t.createVNode("span",{class:"item-content"},[null===(n=l.default)||void 0===n?void 0:n.call(l)])])}}}),K={title:{type:String,default:"title"}},S=t.defineComponent({name:"Submenu",props:K,emits:["collapse"],slots:["icon"],setup:function(e,o){var r,l,a=o.slots,u=o.emit,i=m(),s=i.registerMenuInfo,c=i.unregisterMenuInfo,p=i.openedKeys,d=i.handleOpenChange,v=i.collapse,x=i.activeKey,I=i.menuStore,_=h().parentInfo,w=t.getCurrentInstance(),K=(null===(l=null===(r=w.vnode.key)||void 0===r?void 0:r.toString)||void 0===l?void 0:l.call(r))||String(w.uid),S=t.ref({css:!0,onBeforeEnter:function(e){b(e,"collapse-transition"),e.dataset||(e.dataset={}),e.style.height="0px",e.style.maxHeight="0px"},onEnter:function(e){e.dataset.oldOverflow=e.style.overflow,0!==e.scrollHeight?(e.style.height="".concat(e.scrollHeight,"px"),e.style.maxHeight="".concat(e.scrollHeight,"px")):(e.style.height="0px",e.style.maxHeight="0px"),e.style.overflow="hidden"},onAfterEnter:function(e){e.style.height="",e.style.maxHeight="",e.style.overflow=e.dataset.oldOverflow,g(e,"collapse-transition")},onBeforeLeave:function(e){e.dataset||(e.dataset={}),e.dataset.oldOverflow=e.style.overflow,e.style.height="".concat(e.scrollHeight,"px"),e.style.maxHeight="".concat(e.scrollHeight,"px"),e.style.overflow="hidden"},onLeave:function(e){0!==e.scrollHeight&&(b(e,"collapse-transition"),e.style.transitionProperty="height",e.style.height="0px",e.style.maxHeight="0px")},onAfterLeave:function(e){g(e,"collapse-transition"),e.style.height="",e.style.maxHeight="",e.style.overflow=e.dataset.oldOverflow}}),k=t.computed((function(){return p.value.includes(K)})),M=t.computed((function(){var e,t,n=null===(t=null===(e=I.value)||void 0===e?void 0:e[x.value])||void 0===t?void 0:t.parentKey;return v.value&&n===K&&k}));!function(e){var n=h(),o=n.parentKeys,r=n.parentInfo,l=t.computed((function(){return[].concat(f(o.value),[e])}));t.provide(y,{parentInfo:{key:e,parentKey:null==r?void 0:r.key},parentKeys:l})}(K),s(K,{key:K,parentKey:null==_?void 0:_.key}),t.onBeforeUnmount((function(){return c(K)}));var O=function(){d(K,!k.value),u("collapse",!k.value,w)};return function(){var o,r;return t.createVNode("li",{class:{"bk-menu-submenu":!0,"is-opened":k.value}},[t.createVNode("div",{class:{"submenu-header":!0,"is-collapse":M.value},onClick:O},[t.createVNode("span",{class:"submenu-header-icon"},[(null===(o=a.icon)||void 0===o?void 0:o.call(a))||t.createVNode(n.TreeApplicationShape,{class:"menu-icon"},null)]),t.createVNode("span",{class:"submenu-header-content"},[e.title]),t.createVNode(n.AngleDown,{class:{"submenu-header-collapse":!0,"is-collapse":p.value.includes(K)}},null)]),t.createVNode(t.Transition,S.value,{default:function(){return[t.withDirectives(t.createVNode("ul",{class:"submenu-list"},[null===(r=a.default)||void 0===r?void 0:r.call(a)]),[[t.vShow,k.value]])]}})])}}}),k=t.defineComponent({name:"MenuGroup",props:{name:{type:String,default:""}},setup:function(e,n){var o=n.slots;return function(){var n;return t.createVNode("div",{class:"bk-menu-group"},[t.createVNode("div",{class:"group-name"},[e.name]),t.createVNode("ul",{class:"group-wrap"},[null===(n=o.default)||void 0===n?void 0:n.call(o)])])}}}),M=o.withInstallProps(_,{Item:w,Submenu:S,Group:k});e.default=M,Object.defineProperty(e,"__esModule",{value:!0})}));
|
package/lib/modal/index.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared)}(this,(function(e,t,o){"use strict";function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n={exports:{}},i={exports:{}},s={exports:{}};!function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,r=new Array(t);o<t;o++)r[o]=e[o];return r},e.exports.
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared)}(this,(function(e,t,o){"use strict";function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var n={exports:{}},i={exports:{}},s={exports:{}};!function(e){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,r=new Array(t);o<t;o++)r[o]=e[o];return r},e.exports.__esModule=!0,e.exports.default=e.exports}(s),function(e){var t=s.exports;e.exports=function(e){if(Array.isArray(e))return t(e)},e.exports.__esModule=!0,e.exports.default=e.exports}(i);var a={exports:{}};!function(e){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports}(a);var l={exports:{}};!function(e){var t=s.exports;e.exports=function(e,o){if(e){if("string"==typeof e)return t(e,o);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?t(e,o):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports}(l);var d={exports:{}};!function(e){e.exports=function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports}(d),function(e){var t=i.exports,o=a.exports,r=l.exports,n=d.exports;e.exports=function(e){return t(e)||o(e)||r(e)||n()},e.exports.__esModule=!0,e.exports.default=e.exports}(n);var u=r(n.exports),p={isShow:{type:Boolean,default:!1},width:{type:[Number,String],default:"50%"},height:{type:[Number,String],default:"50%"},customClass:{type:[Object,String],default:""},scrollable:{type:Boolean,default:!0}},c=t.defineComponent({name:"Modal",props:Object.assign({},p),data:function(){return{visible:!1}},watch:{isShow:{handler:function(e){this.visible=e}},visible:function(e){var t=this;e?this.$nextTick((function(){o.bkPopIndexManager.show(t.$el)})):o.bkPopIndexManager.hide(this.$el)}},computed:{dialogWidth:function(){return/^\d+$/.test("".concat(this.width))?"".concat(this.width,"px"):this.width},dialogHeight:function(){return/^\d+$/.test("".concat(this.height))?"".concat(this.height,"px"):this.height},compStyle:function(){return{width:this.dialogWidth,height:this.dialogHeight,display:this.visible?"inherit":"none"}}},beforeUnmount:function(){o.bkPopIndexManager.hide(this.$el)},render:function(){var e,o,r,n,i,s,a,l,d;return t.createVNode("div",{class:["bk-modal-wrapper"].concat(u(this.customClass)),style:this.compStyle},[this.isShow?t.createVNode("div",{class:"bk-modal-body"},[t.createVNode("div",{class:"bk-modal-header"},[null!==(r=null===(o=(e=this.$slots).header)||void 0===o?void 0:o.call(e))&&void 0!==r?r:""]),t.createVNode("div",{class:"bk-modal-content"},[null!==(s=null===(i=(n=this.$slots).default)||void 0===i?void 0:i.call(n))&&void 0!==s?s:""]),t.createVNode("div",{class:"bk-modal-footer"},[null!==(d=null===(l=(a=this.$slots).footer)||void 0===l?void 0:l.call(a))&&void 0!==d?d:""])]):""])}}),f=o.withInstallProps(c,{propsMixin:p},!0);e.BkModal=f,e.default=f,e.propsMixin=p,Object.defineProperty(e,"__esModule",{value:!0})}));
|
package/lib/notify/index.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared"),require("@bkui-vue/icon")):"function"==typeof define&&define.amd?define(["exports","vue","../shared","@bkui-vue/icon"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared,e["@bkui-vue/icon/icons"])}(this,(function(e,t,o,n){"use strict";var r={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},i=1,s=function(e,o){var n=o,s=n.position||"top-right";"string"==typeof o&&(n={message:o});var u=o.onClose,a=n.offset||20;r[s].forEach((function(e){a+=(e.el.offsetHeight||0)+16})),a+=16;var l="message_".concat(i+=1);n=Object.assign(Object.assign({},n),{offset:a,id:l});var c=document.createElement("div"),f=t.createVNode(e,n);f.props.onDestory=function(e){!function(e,t,o){null==o||o();var n=t.startsWith("top")?"top":"bottom",i=-1;r[t].forEach((function(t,o){t.props.id===e&&(i=o)}));for(var s=r[t][i].el.offsetHeight,u=r[t].length,a=i;a<u;a++){var l=parseInt(r[t][a].el.style[n],10)-s-16;r[t][a].component.props.offset=l}r[t].splice(i,1)}(e,s,u),t.render(null,c)},t.render(f,c),r[s].push(f),document.body.appendChild(c.firstElementChild)};function u(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var a={exports:{}};!function(e){e.exports=function(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e},e.exports.
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared"),require("@bkui-vue/icon")):"function"==typeof define&&define.amd?define(["exports","vue","../shared","@bkui-vue/icon"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared,e["@bkui-vue/icon/icons"])}(this,(function(e,t,o,n){"use strict";var r={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},i=1,s=function(e,o){var n=o,s=n.position||"top-right";"string"==typeof o&&(n={message:o});var u=o.onClose,a=n.offset||20;r[s].forEach((function(e){a+=(e.el.offsetHeight||0)+16})),a+=16;var l="message_".concat(i+=1);n=Object.assign(Object.assign({},n),{offset:a,id:l});var c=document.createElement("div"),f=t.createVNode(e,n);f.props.onDestory=function(e){!function(e,t,o){null==o||o();var n=t.startsWith("top")?"top":"bottom",i=-1;r[t].forEach((function(t,o){t.props.id===e&&(i=o)}));for(var s=r[t][i].el.offsetHeight,u=r[t].length,a=i;a<u;a++){var l=parseInt(r[t][a].el.style[n],10)-s-16;r[t][a].component.props.offset=l}r[t].splice(i,1)}(e,s,u),t.render(null,c)},t.render(f,c),r[s].push(f),document.body.appendChild(c.firstElementChild)};function u(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var a={exports:{}};!function(e){e.exports=function(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e},e.exports.__esModule=!0,e.exports.default=e.exports}(a);var l=u(a.exports),c={id:o.PropTypes.string.def(""),title:o.PropTypes.string.def(""),message:o.PropTypes.string.def(""),theme:o.PropTypes.theme(["primary","warning","success","danger"]).def("primary"),position:o.PropTypes.position().def("top-right"),delay:o.PropTypes.number.def(3e3),offset:o.PropTypes.number.def(0),onClose:o.PropTypes.func},f=t.defineComponent({name:"Notify",props:c,emits:["destory"],setup:function(e,n){var r=n.emit,i=t.computed((function(){return["bk-notify","bk-notify-".concat(e.theme)]})),s=o.bkZIndexManager.getMessageNextIndex(),u=t.computed((function(){return e.position.indexOf("right")>1?"right":"left"})),a=t.computed((function(){return e.position.startsWith("top")?"top":"bottom"})),c=t.computed((function(){var t;return l(t={},u.value,"10px"),l(t,a.value,"".concat(e.offset,"px")),l(t,"zIndex",s),t})),f=t.ref(!1),d=null;return t.onMounted((function(){d=setTimeout((function(){f.value=!1}),e.delay),f.value=!0})),t.onUnmounted((function(){clearTimeout(d)})),t.watch(f,(function(){f.value||r("destory",e.id)})),{classNames:i,styles:c,visible:f,handleClose:function(){f.value=!1}}},render:function(){var e=this;return t.createVNode(t.Transition,{name:"bk-notify-fade"},{default:function(){return[t.withDirectives(t.createVNode("div",{class:e.classNames,style:e.styles},[t.createVNode("div",{class:"bk-notify-content"},[t.createVNode("div",{class:"bk-notify-icon"},[{primary:t.createVNode(n.Info,null,null),warning:t.createVNode(n.Warn,null,null),success:t.createVNode(n.Success,null,null),danger:t.createVNode(n.Close,null,null)}[e.theme]]),e.title?t.createVNode("h3",{class:"bk-notify-content-header"},[e.title]):"",t.createVNode("div",{class:"bk-notify-content-text"},[e.message])]),t.createVNode(n.Error,{class:"bk-notify-icon bk-notify-close",onClick:e.handleClose},null)]),[[t.vShow,e.visible]])]}})}});e.default=function(e){s(f,e)},Object.defineProperty(e,"__esModule",{value:!0})}));
|
@@ -51,8 +51,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
51
51
|
offset?: unknown;
|
52
52
|
onClose?: unknown;
|
53
53
|
} & {
|
54
|
-
offset: number;
|
55
54
|
title: string;
|
55
|
+
offset: number;
|
56
56
|
id: string;
|
57
57
|
theme: string;
|
58
58
|
position: string;
|
@@ -63,8 +63,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
63
63
|
}> & {
|
64
64
|
onDestory?: (...args: any[]) => any;
|
65
65
|
}, {
|
66
|
-
offset: number;
|
67
66
|
title: string;
|
67
|
+
offset: number;
|
68
68
|
id: string;
|
69
69
|
onClose: (...args: any[]) => any;
|
70
70
|
theme: string;
|
package/lib/popover/index.d.ts
CHANGED
@@ -1,10 +1,7 @@
|
|
1
1
|
declare const BkPopover: {
|
2
2
|
new (...args: any[]): {
|
3
3
|
$: import("vue").ComponentInternalInstance;
|
4
|
-
$data: {
|
5
|
-
popoverInstance: any;
|
6
|
-
isPopInstance: boolean;
|
7
|
-
};
|
4
|
+
$data: {};
|
8
5
|
$props: Partial<{
|
9
6
|
placement: string;
|
10
7
|
modifiers: unknown[];
|
@@ -15,17 +12,52 @@ declare const BkPopover: {
|
|
15
12
|
trigger: string;
|
16
13
|
arrow: boolean;
|
17
14
|
isShow: boolean;
|
18
|
-
|
15
|
+
transition: string;
|
16
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
17
|
+
fixOnBoundary: boolean;
|
18
|
+
}> & Omit<({} & (Readonly<{
|
19
|
+
isShow?: unknown;
|
20
|
+
width?: unknown;
|
21
|
+
height?: unknown;
|
22
|
+
content?: unknown;
|
23
|
+
transition?: unknown;
|
24
|
+
placement?: unknown;
|
25
|
+
theme?: unknown;
|
26
|
+
handleFirstUpdate?: unknown;
|
27
|
+
trigger?: unknown;
|
28
|
+
arrow?: unknown;
|
29
|
+
modifiers?: unknown;
|
30
|
+
boundary?: unknown;
|
31
|
+
fixOnBoundary?: unknown;
|
32
|
+
} & {
|
33
|
+
placement: string;
|
34
|
+
modifiers: unknown[];
|
35
|
+
width: string | number;
|
36
|
+
height: string | number;
|
37
|
+
theme: string;
|
38
|
+
content: string | number;
|
39
|
+
trigger: string;
|
40
|
+
arrow: boolean;
|
41
|
+
isShow: boolean;
|
42
|
+
transition: string;
|
43
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
44
|
+
fixOnBoundary: boolean;
|
45
|
+
} & {
|
46
|
+
boundary?: string | HTMLElement;
|
47
|
+
}> & ({} | {}))) & (import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & Readonly<{
|
19
48
|
isShow?: unknown;
|
20
49
|
width?: unknown;
|
21
50
|
height?: unknown;
|
22
51
|
content?: unknown;
|
52
|
+
transition?: unknown;
|
23
53
|
placement?: unknown;
|
24
54
|
theme?: unknown;
|
25
55
|
handleFirstUpdate?: unknown;
|
26
56
|
trigger?: unknown;
|
27
57
|
arrow?: unknown;
|
28
58
|
modifiers?: unknown;
|
59
|
+
boundary?: unknown;
|
60
|
+
fixOnBoundary?: unknown;
|
29
61
|
} & {
|
30
62
|
placement: string;
|
31
63
|
modifiers: unknown[];
|
@@ -36,9 +68,12 @@ declare const BkPopover: {
|
|
36
68
|
trigger: string;
|
37
69
|
arrow: boolean;
|
38
70
|
isShow: boolean;
|
71
|
+
transition: string;
|
72
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
73
|
+
fixOnBoundary: boolean;
|
39
74
|
} & {
|
40
|
-
|
41
|
-
}> & {}
|
75
|
+
boundary?: string | HTMLElement;
|
76
|
+
}> & ({} | {})), "placement" | "modifiers" | "width" | "height" | "theme" | "content" | "trigger" | "arrow" | "isShow" | "transition" | "handleFirstUpdate" | "fixOnBoundary">;
|
42
77
|
$attrs: {
|
43
78
|
[x: string]: unknown;
|
44
79
|
};
|
@@ -50,19 +85,22 @@ declare const BkPopover: {
|
|
50
85
|
}>;
|
51
86
|
$root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>>;
|
52
87
|
$parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>>;
|
53
|
-
$emit: (event: string, ...args: any[]) => void;
|
88
|
+
$emit: ((event: string, ...args: any[]) => void) | ((event: string, ...args: any[]) => void);
|
54
89
|
$el: any;
|
55
90
|
$options: import("vue").ComponentOptionsBase<Readonly<{
|
56
91
|
isShow?: unknown;
|
57
92
|
width?: unknown;
|
58
93
|
height?: unknown;
|
59
94
|
content?: unknown;
|
95
|
+
transition?: unknown;
|
60
96
|
placement?: unknown;
|
61
97
|
theme?: unknown;
|
62
98
|
handleFirstUpdate?: unknown;
|
63
99
|
trigger?: unknown;
|
64
100
|
arrow?: unknown;
|
65
101
|
modifiers?: unknown;
|
102
|
+
boundary?: unknown;
|
103
|
+
fixOnBoundary?: unknown;
|
66
104
|
} & {
|
67
105
|
placement: string;
|
68
106
|
modifiers: unknown[];
|
@@ -73,20 +111,12 @@ declare const BkPopover: {
|
|
73
111
|
trigger: string;
|
74
112
|
arrow: boolean;
|
75
113
|
isShow: boolean;
|
114
|
+
transition: string;
|
115
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
116
|
+
fixOnBoundary: boolean;
|
76
117
|
} & {
|
77
|
-
|
78
|
-
}> & {}, {
|
79
|
-
compStyle: import("vue").ComputedRef<{
|
80
|
-
width: any;
|
81
|
-
height: any;
|
82
|
-
zIndex: number;
|
83
|
-
}>;
|
84
|
-
}, {
|
85
|
-
popoverInstance: any;
|
86
|
-
isPopInstance: boolean;
|
87
|
-
}, {}, {
|
88
|
-
handleClose(): void;
|
89
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {
|
118
|
+
boundary?: string | HTMLElement;
|
119
|
+
}> & ({} | {}), () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, {
|
90
120
|
placement: string;
|
91
121
|
modifiers: unknown[];
|
92
122
|
width: string | number;
|
@@ -96,6 +126,9 @@ declare const BkPopover: {
|
|
96
126
|
trigger: string;
|
97
127
|
arrow: boolean;
|
98
128
|
isShow: boolean;
|
129
|
+
transition: string;
|
130
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
131
|
+
fixOnBoundary: boolean;
|
99
132
|
}> & {
|
100
133
|
beforeCreate?: (() => void) | (() => void)[];
|
101
134
|
created?: (() => void) | (() => void)[];
|
@@ -116,17 +149,20 @@ declare const BkPopover: {
|
|
116
149
|
$forceUpdate: () => void;
|
117
150
|
$nextTick: typeof import("vue").nextTick;
|
118
151
|
$watch(source: string | Function, cb: Function, options?: import("vue").WatchOptions<boolean>): import("vue").WatchStopHandle;
|
119
|
-
} & Readonly<{
|
152
|
+
} & (Readonly<{
|
120
153
|
isShow?: unknown;
|
121
154
|
width?: unknown;
|
122
155
|
height?: unknown;
|
123
156
|
content?: unknown;
|
157
|
+
transition?: unknown;
|
124
158
|
placement?: unknown;
|
125
159
|
theme?: unknown;
|
126
160
|
handleFirstUpdate?: unknown;
|
127
161
|
trigger?: unknown;
|
128
162
|
arrow?: unknown;
|
129
163
|
modifiers?: unknown;
|
164
|
+
boundary?: unknown;
|
165
|
+
fixOnBoundary?: unknown;
|
130
166
|
} & {
|
131
167
|
placement: string;
|
132
168
|
modifiers: unknown[];
|
@@ -137,20 +173,41 @@ declare const BkPopover: {
|
|
137
173
|
trigger: string;
|
138
174
|
arrow: boolean;
|
139
175
|
isShow: boolean;
|
176
|
+
transition: string;
|
177
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
178
|
+
fixOnBoundary: boolean;
|
140
179
|
} & {
|
141
|
-
|
142
|
-
}> & {} & import("vue").ShallowUnwrapRef<{
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
180
|
+
boundary?: string | HTMLElement;
|
181
|
+
}> & ({} | {})) & import("vue").ShallowUnwrapRef<() => JSX.Element> & {} & {} & import("vue").ComponentCustomProperties & Readonly<{
|
182
|
+
isShow?: unknown;
|
183
|
+
width?: unknown;
|
184
|
+
height?: unknown;
|
185
|
+
content?: unknown;
|
186
|
+
transition?: unknown;
|
187
|
+
placement?: unknown;
|
188
|
+
theme?: unknown;
|
189
|
+
handleFirstUpdate?: unknown;
|
190
|
+
trigger?: unknown;
|
191
|
+
arrow?: unknown;
|
192
|
+
modifiers?: unknown;
|
193
|
+
boundary?: unknown;
|
194
|
+
fixOnBoundary?: unknown;
|
195
|
+
} & {
|
196
|
+
placement: string;
|
197
|
+
modifiers: unknown[];
|
198
|
+
width: string | number;
|
199
|
+
height: string | number;
|
200
|
+
theme: string;
|
201
|
+
content: string | number;
|
202
|
+
trigger: string;
|
203
|
+
arrow: boolean;
|
204
|
+
isShow: boolean;
|
205
|
+
transition: string;
|
206
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
207
|
+
fixOnBoundary: boolean;
|
208
|
+
} & {
|
209
|
+
boundary?: string | HTMLElement;
|
210
|
+
}> & ({} | {});
|
154
211
|
__isFragment?: never;
|
155
212
|
__isTeleport?: never;
|
156
213
|
__isSuspense?: never;
|
@@ -159,12 +216,15 @@ declare const BkPopover: {
|
|
159
216
|
width?: unknown;
|
160
217
|
height?: unknown;
|
161
218
|
content?: unknown;
|
219
|
+
transition?: unknown;
|
162
220
|
placement?: unknown;
|
163
221
|
theme?: unknown;
|
164
222
|
handleFirstUpdate?: unknown;
|
165
223
|
trigger?: unknown;
|
166
224
|
arrow?: unknown;
|
167
225
|
modifiers?: unknown;
|
226
|
+
boundary?: unknown;
|
227
|
+
fixOnBoundary?: unknown;
|
168
228
|
} & {
|
169
229
|
placement: string;
|
170
230
|
modifiers: unknown[];
|
@@ -175,20 +235,12 @@ declare const BkPopover: {
|
|
175
235
|
trigger: string;
|
176
236
|
arrow: boolean;
|
177
237
|
isShow: boolean;
|
238
|
+
transition: string;
|
239
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
240
|
+
fixOnBoundary: boolean;
|
178
241
|
} & {
|
179
|
-
|
180
|
-
}> & {}, {
|
181
|
-
compStyle: import("vue").ComputedRef<{
|
182
|
-
width: any;
|
183
|
-
height: any;
|
184
|
-
zIndex: number;
|
185
|
-
}>;
|
186
|
-
}, {
|
187
|
-
popoverInstance: any;
|
188
|
-
isPopInstance: boolean;
|
189
|
-
}, {}, {
|
190
|
-
handleClose(): void;
|
191
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {
|
242
|
+
boundary?: string | HTMLElement;
|
243
|
+
}> & ({} | {}), () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, {
|
192
244
|
placement: string;
|
193
245
|
modifiers: unknown[];
|
194
246
|
width: string | number;
|
@@ -198,5 +250,8 @@ declare const BkPopover: {
|
|
198
250
|
trigger: string;
|
199
251
|
arrow: boolean;
|
200
252
|
isShow: boolean;
|
253
|
+
transition: string;
|
254
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
255
|
+
fixOnBoundary: boolean;
|
201
256
|
}> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & import("@vue/runtime-core").Plugin;
|
202
257
|
export default BkPopover;
|
package/lib/popover/index.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared)}(this,(function(e,t,o){"use strict";var
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue"),require("../shared")):"function"==typeof define&&define.amd?define(["exports","vue","../shared"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).bkuiVue={},e.Vue,e.Shared)}(this,(function(e,t,o){"use strict";function n(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var r={exports:{}};!function(e){e.exports=function(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e},e.exports.__esModule=!0,e.exports.default=e.exports}(r);var a=n(r.exports),i={isShow:o.PropTypes.bool,width:o.PropTypes.oneOfType([o.PropTypes.string,o.PropTypes.number]).def("auto"),height:o.PropTypes.oneOfType([o.PropTypes.string,o.PropTypes.number]).def("auto"),content:o.PropTypes.oneOfType([o.PropTypes.string,o.PropTypes.number]).def(""),transition:o.PropTypes.string.def("fade-in"),placement:o.PropTypes.placement(["auto","auto-start","auto-end","top","top-start","top-end","bottom","bottom-start","bottom-end","right","right-start","right-end","left","left-start","left-end"]).def("top"),theme:o.PropTypes.string.def("light"),handleFirstUpdate:{type:Function,default:function(){}},trigger:o.PropTypes.string.def("hover"),arrow:o.PropTypes.bool.def(!0),modifiers:o.PropTypes.array.def([{name:"offset",options:{offset:[0,8]}}]),boundary:o.PropTypes.oneOfType([o.PropTypes.string.def("parent"),o.PropTypes.instanceOf(HTMLElement)]),fixOnBoundary:o.PropTypes.bool.def(!1)},u=t.defineComponent({name:"Popover",props:i,setup:function(e,n){var r=!1,i=Object.create(null),u=t.toRefs(e),s=u.width,p=u.height,d=u.theme,f=u.trigger,l=u.isShow,c=u.placement,m=u.modifiers,v=u.arrow,h=u.content,y=t.ref(),T=t.ref(),b=t.computed((function(){return{width:/^\d+$/.test(String(s.value))?"".concat(s.value,"px"):s.value,height:/^\d+$/.test(String(p.value))?"".concat(p.value,"px"):p.value,zIndex:o.bkZIndexManager.getModalNextIndex()}})),g=["dark","light"],P=t.computed((function(){var e=d.value.split(/\s+/);return e.sort((function(e,t){return Number(g.includes(t))-Number(g.includes(e))})),{systemThemes:e,customThemes:e.filter((function(e){return!g.includes(e)}))}})),w=function(e){"manual"===f.value&&r&&(e?i.show():i.hide())};t.watch((function(){return e.isShow}),(function(e){w(e)}),{immediate:!0});var x=function(){n.emit("update:isShow",!1)},O=function(){n.emit("update:isShow",!0)},S=function(){var e=i;e.constructor&&(e.isShow&&e.hide(),e.destroy(),i=Object.create(null))},j=function(){i=new o.BKPopover(y.value,T.value,{theme:P.value.systemThemes.join(" "),placement:c.value,trigger:f.value,modifiers:m.value,onFirstUpdate:e.handleFirstUpdate,afterShow:O,afterHidden:x,appendTo:e.boundary,fixOnBoundary:e.fixOnBoundary}),r=!0,w(l.value)},k=function(){S(),t.nextTick(j)};n.expose({update:k}),t.onMounted(k),t.onBeforeUnmount(S);var N=function(){n.emit("after-enter")},M=function(){n.emit("after-leave")},V=P.value.customThemes.join(" "),_=P.value.customThemes.reduce((function(e,t){return Object.assign(a({},"data-".concat(t,"-theme"),!0),e)}),{}),B="bk-popover-content ".concat(V);return function(){var o,r,a,i,u;return t.createVNode("div",{class:"bk-popover","data-bk-pop-container":!0},[t.createVNode("div",{ref:y,class:"bk-popover-reference"},[null===(r=(o=n.slots).default)||void 0===r?void 0:r.call(o)]),t.createVNode(t.Transition,{name:e.transition,onAfterEnter:N,onAfterLeave:M},{default:function(){return[t.createVNode("div",t.mergeProps({ref:T,class:B,style:b.value},_),[null!==(u=null===(i=(a=n.slots).content)||void 0===i?void 0:i.call(a))&&void 0!==u?u:h.value,v&&t.createVNode("div",{class:"arrow","data-popper-arrow":!0},null)])]}})])}}}),s=o.withInstall(u);e.default=s,Object.defineProperty(e,"__esModule",{value:!0})}));
|
package/lib/popover/popover.css
CHANGED
@@ -1,7 +1,16 @@
|
|
1
1
|
.bk-popover .bk-popover-reference {
|
2
2
|
display: inline-block;
|
3
3
|
}
|
4
|
-
.bk-popover .
|
4
|
+
.bk-popover .fade-in-enter-active,
|
5
|
+
.bk-popover .fade-in-linear-leave-active {
|
6
|
+
transition: opacity 200ms linear;
|
7
|
+
}
|
8
|
+
.bk-popover .fade-in-enter,
|
9
|
+
.bk-popover .fade-in-leave,
|
10
|
+
.bk-popover .fade-in-leave-active {
|
11
|
+
opacity: 0;
|
12
|
+
}
|
13
|
+
.bk-popover-content {
|
5
14
|
display: none;
|
6
15
|
padding: 7px 14px;
|
7
16
|
font-size: 12px;
|
@@ -10,29 +19,29 @@
|
|
10
19
|
border-radius: 4px;
|
11
20
|
box-sizing: border-box;
|
12
21
|
}
|
13
|
-
.bk-popover
|
22
|
+
.bk-popover-content[data-theme^='dark'] {
|
14
23
|
color: #fff;
|
15
24
|
background: #26323d;
|
16
25
|
}
|
17
|
-
.bk-popover
|
26
|
+
.bk-popover-content[data-theme^='light'] {
|
18
27
|
color: #26323d;
|
19
28
|
background-color: #fff;
|
20
29
|
box-shadow: 0 0 6px 0 #dcdee5;
|
21
30
|
}
|
22
|
-
.bk-popover
|
31
|
+
.bk-popover-content[data-theme^='light'][data-show] {
|
23
32
|
box-shadow: 0 0 6px 0 #dcdee5;
|
24
33
|
}
|
25
|
-
.bk-popover
|
34
|
+
.bk-popover-content[data-show] {
|
26
35
|
display: block;
|
27
36
|
}
|
28
|
-
.bk-popover
|
37
|
+
.bk-popover-content .arrow {
|
29
38
|
position: absolute;
|
30
39
|
width: 8px;
|
31
40
|
height: 8px;
|
32
41
|
background: inherit;
|
33
42
|
visibility: hidden;
|
34
43
|
}
|
35
|
-
.bk-popover
|
44
|
+
.bk-popover-content .arrow::before {
|
36
45
|
position: absolute;
|
37
46
|
width: 8px;
|
38
47
|
height: 8px;
|
@@ -41,15 +50,15 @@
|
|
41
50
|
visibility: visible;
|
42
51
|
transform: rotate(45deg);
|
43
52
|
}
|
44
|
-
.bk-popover
|
53
|
+
.bk-popover-content[data-popper-placement^='top'] > .arrow {
|
45
54
|
bottom: -4px;
|
46
55
|
}
|
47
|
-
.bk-popover
|
56
|
+
.bk-popover-content[data-popper-placement^='bottom'] > .arrow {
|
48
57
|
top: -4px;
|
49
58
|
}
|
50
|
-
.bk-popover
|
51
|
-
right:
|
59
|
+
.bk-popover-content[data-popper-placement^='left'] > .arrow {
|
60
|
+
right: -4px;
|
52
61
|
}
|
53
|
-
.bk-popover
|
54
|
-
left: -
|
62
|
+
.bk-popover-content[data-popper-placement^='right'] > .arrow {
|
63
|
+
left: -4px;
|
55
64
|
}
|
package/lib/popover/popover.d.ts
CHANGED
@@ -1,5 +1,3 @@
|
|
1
|
-
import { PropType } from 'vue';
|
2
|
-
import { OnFirstUpdateFnType } from '@bkui-vue/shared';
|
3
1
|
declare const _default: import("vue").DefineComponent<{
|
4
2
|
isShow: import("vue-types").VueTypeValidableDef<boolean> & {
|
5
3
|
default: boolean;
|
@@ -13,18 +11,23 @@ declare const _default: import("vue").DefineComponent<{
|
|
13
11
|
content: import("vue-types").VueTypeDef<string | number> & {
|
14
12
|
default: string | number;
|
15
13
|
};
|
14
|
+
transition: import("vue-types").VueTypeValidableDef<string> & {
|
15
|
+
default: string;
|
16
|
+
} & {
|
17
|
+
default: string;
|
18
|
+
};
|
16
19
|
placement: import("vue-types").VueTypeDef<string> & {
|
17
20
|
default: string;
|
18
21
|
};
|
19
|
-
theme: import("vue-types").
|
22
|
+
theme: import("vue-types").VueTypeValidableDef<string> & {
|
23
|
+
default: string;
|
24
|
+
} & {
|
20
25
|
default: string;
|
21
26
|
};
|
22
|
-
handleFirstUpdate:
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
* manual: 通过isShow控制显示、隐藏
|
27
|
-
*/
|
27
|
+
handleFirstUpdate: {
|
28
|
+
type: import("vue").PropType<import("@bkui-vue/shared").OnFirstUpdateFnType>;
|
29
|
+
default: () => void;
|
30
|
+
};
|
28
31
|
trigger: import("vue-types").VueTypeValidableDef<string> & {
|
29
32
|
default: string;
|
30
33
|
} & {
|
@@ -40,28 +43,26 @@ declare const _default: import("vue").DefineComponent<{
|
|
40
43
|
} & {
|
41
44
|
default: () => unknown[];
|
42
45
|
};
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
}
|
49
|
-
}, {
|
50
|
-
popoverInstance: any;
|
51
|
-
isPopInstance: boolean;
|
52
|
-
}, {}, {
|
53
|
-
handleClose(): void;
|
54
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
|
46
|
+
boundary: import("vue-types").VueTypeDef<string | HTMLElement>;
|
47
|
+
fixOnBoundary: import("vue-types").VueTypeValidableDef<boolean> & {
|
48
|
+
default: boolean;
|
49
|
+
} & {
|
50
|
+
default: boolean;
|
51
|
+
};
|
52
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
|
55
53
|
isShow?: unknown;
|
56
54
|
width?: unknown;
|
57
55
|
height?: unknown;
|
58
56
|
content?: unknown;
|
57
|
+
transition?: unknown;
|
59
58
|
placement?: unknown;
|
60
59
|
theme?: unknown;
|
61
60
|
handleFirstUpdate?: unknown;
|
62
61
|
trigger?: unknown;
|
63
62
|
arrow?: unknown;
|
64
63
|
modifiers?: unknown;
|
64
|
+
boundary?: unknown;
|
65
|
+
fixOnBoundary?: unknown;
|
65
66
|
} & {
|
66
67
|
placement: string;
|
67
68
|
modifiers: unknown[];
|
@@ -72,9 +73,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
72
73
|
trigger: string;
|
73
74
|
arrow: boolean;
|
74
75
|
isShow: boolean;
|
76
|
+
transition: string;
|
77
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
78
|
+
fixOnBoundary: boolean;
|
75
79
|
} & {
|
76
|
-
|
77
|
-
}> & {}, {
|
80
|
+
boundary?: string | HTMLElement;
|
81
|
+
}> & ({} | {}), {
|
78
82
|
placement: string;
|
79
83
|
modifiers: unknown[];
|
80
84
|
width: string | number;
|
@@ -84,5 +88,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
84
88
|
trigger: string;
|
85
89
|
arrow: boolean;
|
86
90
|
isShow: boolean;
|
91
|
+
transition: string;
|
92
|
+
handleFirstUpdate: import("@bkui-vue/shared").OnFirstUpdateFnType;
|
93
|
+
fixOnBoundary: boolean;
|
87
94
|
}>;
|
88
95
|
export default _default;
|