bkui-vue 0.0.1-beta.470 → 0.0.1-beta.472
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +59 -59
- package/dist/index.esm.js +11669 -11498
- package/dist/index.umd.js +61 -61
- package/dist/style.css +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/button/button-group.d.ts +2 -2
- package/lib/button/index.d.ts +2 -2
- package/lib/button/index.js +1 -1
- package/lib/card/card.d.ts +1 -0
- package/lib/card/index.d.ts +3 -0
- package/lib/card/index.js +1 -1
- package/lib/checkbox/checkbox.d.ts +9 -8
- package/lib/checkbox/index.d.ts +15 -12
- package/lib/checkbox/index.js +1 -1
- package/lib/code-diff/index.js +1 -1
- package/lib/collapse/collapse-panel.d.ts +1 -0
- package/lib/collapse/index.d.ts +1 -0
- package/lib/collapse/index.js +1 -1
- package/lib/color-picker/color-picker.less +50 -50
- package/lib/color-picker/index.js +1 -1
- package/lib/config-provider/index.d.ts +1 -1
- package/lib/container/container.less +4 -4
- package/lib/container/index.js +1 -1
- package/lib/dropdown/dropdown.d.ts +1 -0
- package/lib/dropdown/dropdown.less +6 -9
- package/lib/dropdown/index.d.ts +3 -0
- package/lib/dropdown/index.js +1 -1
- package/lib/exception/exception.less +15 -15
- package/lib/exception/index.js +1 -1
- package/lib/form/compose-form-item.d.ts +3 -1
- package/lib/form/form-item.d.ts +1 -0
- package/lib/form/form.d.ts +1 -0
- package/lib/form/index.d.ts +7 -1
- package/lib/form/index.js +1 -1
- package/lib/input/index.d.ts +7 -7
- package/lib/input/input.d.ts +4 -4
- package/lib/menu/index.js +1 -1
- package/lib/navigation/index.d.ts +3 -0
- package/lib/navigation/index.js +1 -1
- package/lib/navigation/navigation.d.ts +1 -0
- package/lib/notify/index.js +1 -1
- package/lib/notify/notify.less +8 -8
- package/lib/notify/notifyConstructor.d.ts +1 -0
- package/lib/pagination/index.d.ts +10 -7
- package/lib/pagination/index.js +1 -1
- package/lib/pagination/pagination.d.ts +5 -4
- package/lib/process/index.d.ts +3 -0
- package/lib/process/index.js +1 -1
- package/lib/process/process.d.ts +1 -0
- package/lib/process/process.less +7 -7
- package/lib/progress/index.d.ts +13 -7
- package/lib/progress/index.js +1 -1
- package/lib/progress/progress.d.ts +5 -3
- package/lib/progress/progress.less +8 -8
- package/lib/radio/index.d.ts +10 -4
- package/lib/radio/index.js +1 -1
- package/lib/radio/radio-button.d.ts +4 -3
- package/lib/radio/radio-group.d.ts +4 -2
- package/lib/radio/radio.d.ts +1 -0
- package/lib/rate/index.d.ts +4 -4
- package/lib/rate/rate.d.ts +2 -2
- package/lib/resize-layout/index.d.ts +3 -0
- package/lib/resize-layout/index.js +1 -1
- package/lib/resize-layout/resize-layout.d.ts +1 -0
- package/lib/resize-layout/resize-layout.less +23 -23
- package/lib/select/index.d.ts +15 -18
- package/lib/select/index.js +1 -1
- package/lib/select/option.d.ts +6 -9
- package/lib/select/select.d.ts +5 -5
- package/lib/select/type.d.ts +1 -1
- package/lib/shared/vue-types.d.ts +1 -1
- package/lib/sideslider/index.js +1 -1
- package/lib/sideslider/sideslider.less +9 -9
- package/lib/steps/index.d.ts +7 -4
- package/lib/steps/index.js +1 -1
- package/lib/steps/steps.d.ts +4 -3
- package/lib/steps/steps.less +62 -62
- package/lib/swiper/index.js +1 -1
- package/lib/swiper/swiper.less +15 -13
- package/lib/swiper/swiper.variable.css +122 -0
- package/lib/switcher/index.d.ts +4 -4
- package/lib/switcher/index.js +1 -1
- package/lib/switcher/switcher.d.ts +2 -2
- package/lib/switcher/switcher.less +29 -29
- package/lib/table/index.d.ts +1 -1
- package/lib/table-column/index.d.ts +1 -1
- package/lib/tag/index.d.ts +3 -0
- package/lib/tag/index.js +1 -1
- package/lib/tag/tag.css +2 -2
- package/lib/tag/tag.d.ts +1 -0
- package/lib/tag/tag.less +14 -13
- package/lib/tag/tag.variable.css +2 -2
- package/lib/tag-input/index.d.ts +9 -9
- package/lib/tag-input/index.js +1 -1
- package/lib/tag-input/tag-input.d.ts +3 -3
- package/lib/timeline/index.d.ts +3 -0
- package/lib/timeline/index.js +1 -1
- package/lib/timeline/timeline.d.ts +1 -0
- package/lib/timeline/timeline.less +35 -35
- package/lib/transfer/index.d.ts +3 -0
- package/lib/transfer/index.js +1 -1
- package/lib/transfer/transfer.d.ts +1 -0
- package/lib/transfer/transfer.less +2 -2
- package/package.json +1 -1
@@ -206,7 +206,7 @@ export declare function InputBehaviorType(): VueTypeDef<"normal" | "simplicity">
|
|
206
206
|
default: "normal" | "simplicity";
|
207
207
|
};
|
208
208
|
export declare class PropTypes extends propTypesNS {
|
209
|
-
static size(): VueTypeDef<"
|
209
|
+
static size(): VueTypeDef<"small" | "large" | "default">;
|
210
210
|
static theme(): VueTypeDef<"success" | "warning" | "danger" | "primary">;
|
211
211
|
static placement(): VueTypeDef<"top" | "right" | "bottom" | "left">;
|
212
212
|
static style(): VueTypeDef<CSSProperties>;
|
package/lib/sideslider/index.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
1
|
/*! For license information please see index.js.LICENSE.txt */
|
2
|
-
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("../shared"),require("vue"),require("../button"),require("../modal"));else if("function"==typeof define&&define.amd)define(["../shared","vue","../button","../modal"],e);else{var r="object"==typeof exports?e(require("../shared"),require("vue"),require("../button"),require("../modal")):e(t["../shared"],t.vue,t["../button"],t["../modal"]);for(var o in r)("object"==typeof exports?exports:t)[o]=r[o]}}(self,((t,e,r,o)=>(()=>{var n={4976:t=>{"use strict";t.exports=r},8014:t=>{"use strict";t.exports=o},4212:e=>{"use strict";e.exports=t},748:t=>{"use strict";t.exports=e},7609:(t,e,r)=>{var o=r(7425).default;function n(){"use strict";t.exports=n=function(){return e},t.exports.__esModule=!0,t.exports.default=t.exports;var e={},r=Object.prototype,i=r.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},u=c.iterator||"@@iterator",s=c.asyncIterator||"@@asyncIterator",l=c.toStringTag||"@@toStringTag";function f(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{f({},"")}catch(t){f=function(t,e,r){return t[e]=r}}function d(t,e,r,o){var n=e&&e.prototype instanceof v?e:v,i=Object.create(n.prototype),c=new k(o||[]);return a(i,"_invoke",{value:O(t,r,c)}),i}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=d;var h={};function v(){}function y(){}function m(){}var g={};f(g,u,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(N([])));x&&x!==r&&i.call(x,u)&&(g=x);var w=m.prototype=v.prototype=Object.create(g);function j(t){["next","throw","return"].forEach((function(e){f(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(n,a,c,u){var s=p(t[n],t,a);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==o(f)&&i.call(f,"__await")?e.resolve(f.__await).then((function(t){r("next",t,c,u)}),(function(t){r("throw",t,c,u)})):e.resolve(f).then((function(t){l.value=t,c(l)}),(function(t){return r("throw",t,c,u)}))}u(s.arg)}var n;a(this,"_invoke",{value:function(t,o){function i(){return new e((function(e,n){r(t,o,e,n)}))}return n=n?n.then(i,i):i()}})}function O(t,e,r){var o="suspendedStart";return function(n,i){if("executing"===o)throw new Error("Generator is already running");if("completed"===o){if("throw"===n)throw i;return{value:void 0,done:!0}}for(r.method=n,r.arg=i;;){var a=r.delegate;if(a){var c=_(a,r);if(c){if(c===h)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===o)throw o="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o="executing";var u=p(t,e,r);if("normal"===u.type){if(o=r.done?"completed":"suspendedYield",u.arg===h)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o="completed",r.method="throw",r.arg=u.arg)}}}function _(t,e){var r=e.method,o=t.iterator[r];if(void 0===o)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,_(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var n=p(o,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,h;var i=n.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function N(t){if(t){var e=t[u];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(i.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:P}}function P(){return{value:void 0,done:!0}}return y.prototype=m,a(w,"constructor",{value:m,configurable:!0}),a(m,"constructor",{value:y,configurable:!0}),y.displayName=f(m,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,f(t,l,"GeneratorFunction")),t.prototype=Object.create(w),t},e.awrap=function(t){return{__await:t}},j(L.prototype),f(L.prototype,s,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,o,n,i){void 0===i&&(i=Promise);var a=new L(d(t,r,o,n),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},j(w),f(w,l,"Generator"),f(w,u,(function(){return this})),f(w,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var o in e)r.push(o);return r.reverse(),function t(){for(;r.length;){var o=r.pop();if(o in e)return t.value=o,t.done=!1,t}return t.done=!0,t}},e.values=N,k.prototype={constructor:k,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&i.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,o){return a.type="throw",a.arg=t,e.next=r,o&&(e.method="next",e.arg=void 0),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var n=this.tryEntries[o],a=n.completion;if("root"===n.tryLoc)return r("end");if(n.tryLoc<=this.prev){var c=i.call(n,"catchLoc"),u=i.call(n,"finallyLoc");if(c&&u){if(this.prev<n.catchLoc)return r(n.catchLoc,!0);if(this.prev<n.finallyLoc)return r(n.finallyLoc)}else if(c){if(this.prev<n.catchLoc)return r(n.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<n.finallyLoc)return r(n.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&i.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var n=o;break}}n&&("break"===t||"continue"===t)&&n.tryLoc<=e&&e<=n.finallyLoc&&(n=null);var a=n?n.completion:{};return a.type=t,a.arg=e,n?(this.method="next",this.next=n.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),E(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var o=r.completion;if("throw"===o.type){var n=o.arg;E(r)}return n}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:N(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},e}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports},7425:t=>{function e(r){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2841:(t,e,r)=>{var o=r(7609)();t.exports=o;try{regeneratorRuntime=o}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=o:Function("r","regeneratorRuntime = r")(o)}}},i={};function a(t){var e=i[t];if(void 0!==e)return e.exports;var r=i[t]={exports:{}};return n[t](r,r.exports,a),r.exports}a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var r in e)a.o(e,r)&&!a.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var c={};return(()=>{"use strict";a.r(c),a.d(c,{default:()=>p});var t=a(4212),e=a(748),r=a(2841),o=a.n(r);Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var n=a(4976),i=a.n(n),u=a(8014),s=a.n(u),l=s().propsMixin,f=Object.assign({},l);f.width.default="400",f.height.default="100%";const d=(0,e.defineComponent)({name:"Sideslider",components:{BkModal:s(),BkButton:i()},props:Object.assign(Object.assign({},f),{direction:{type:String,default:"right",validator:function(t){var e=["left","right"];return!(e.indexOf(t)<0&&(console.error("direction property is not valid: '".concat(t,"',【").concat(e.join(" | "),"】")),1))}}}),emits:["closed","update:isShow","shown","hidden","animation-end"],setup:function(t,r){var n=this,i=r.slots,a=r.emit,c=function(){return e=n,r=void 0,i=void 0,c=o().mark((function e(){var r;return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=!0,"function"!=typeof t.beforeClose){e.next=5;break}return e.next=4,t.beforeClose();case 4:r=e.sent;case 5:r&&(a("update:isShow",!1),a("closed"),setTimeout((function(){a("animation-end")}),250));case 6:case"end":return e.stop()}}),e)})),new(i||(i=Promise))((function(t,o){function n(t){try{u(c.next(t))}catch(t){o(t)}}function a(t){try{u(c.throw(t))}catch(t){o(t)}}function u(e){var r;e.done?t(e.value):(r=e.value,r instanceof i?r:new i((function(t){t(r)}))).then(n,a)}u((c=c.apply(e,r||[])).next())}));var e,r,i,c},u=function(){setTimeout((function(){a("shown")}),200)},l=function(){setTimeout((function(){a("hidden")}),200)};return function(){var r,o={header:function(){var r,o;return(0,e.createVNode)(e.Fragment,null,[(0,e.createVNode)("div",{class:"bk-sideslider-header"},[(0,e.createVNode)("div",{class:"bk-sideslider-close ".concat(t.direction),onClick:function(){c()}},null),(0,e.createVNode)("div",{class:"bk-sideslider-title ".concat(t.direction)},[null!==(o=null===(r=i.header)||void 0===r?void 0:r.call(i))&&void 0!==o?o:t.title])])])},default:function(){var t,e;return null!==(e=null===(t=i.default)||void 0===t?void 0:t.call(i))&&void 0!==e?e:"Content"},footer:function(){return i.footer?(0,e.createVNode)("div",{class:"bk-sideslider-footer"},[i.footer()]):null}},n="bk-sideslider-wrapper ".concat(t.scrollable?"scroll-able":""," ").concat(t.extCls),a=i.footer?"calc(100vh - 106px)":"calc(100vh - 52px)";return(0,e.createVNode)(s(),(0,e.mergeProps)(t,{maxHeight:a,class:n,style:"".concat(t.direction,": 0;"),onHidden:l,onShown:u,onClose:c}),"function"==typeof(r=o)||"[object Object]"===Object.prototype.toString.call(r)&&!(0,e.isVNode)(r)?o:{default:function(){return[o]}})}}}),p=(0,t.withInstall)(d)})(),c})()));
|
2
|
+
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("../shared"),require("vue"),require("../button"),require("../config-provider"),require("../modal"));else if("function"==typeof define&&define.amd)define(["../shared","vue","../button","../config-provider","../modal"],e);else{var r="object"==typeof exports?e(require("../shared"),require("vue"),require("../button"),require("../config-provider"),require("../modal")):e(t["../shared"],t.vue,t["../button"],t["../config-provider"],t["../modal"]);for(var o in r)("object"==typeof exports?exports:t)[o]=r[o]}}(self,((t,e,r,o,n)=>(()=>{var i={4976:t=>{"use strict";t.exports=r},2717:t=>{"use strict";t.exports=o},8014:t=>{"use strict";t.exports=n},4212:e=>{"use strict";e.exports=t},748:t=>{"use strict";t.exports=e},7609:(t,e,r)=>{var o=r(7425).default;function n(){"use strict";t.exports=n=function(){return e},t.exports.__esModule=!0,t.exports.default=t.exports;var e={},r=Object.prototype,i=r.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},u=c.iterator||"@@iterator",s=c.asyncIterator||"@@asyncIterator",l=c.toStringTag||"@@toStringTag";function f(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{f({},"")}catch(t){f=function(t,e,r){return t[e]=r}}function d(t,e,r,o){var n=e&&e.prototype instanceof v?e:v,i=Object.create(n.prototype),c=new N(o||[]);return a(i,"_invoke",{value:O(t,r,c)}),i}function p(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=d;var h={};function v(){}function y(){}function g(){}var m={};f(m,u,(function(){return this}));var x=Object.getPrototypeOf,b=x&&x(x(P([])));b&&b!==r&&i.call(b,u)&&(m=b);var w=g.prototype=v.prototype=Object.create(m);function j(t){["next","throw","return"].forEach((function(e){f(t,e,(function(t){return this._invoke(e,t)}))}))}function L(t,e){function r(n,a,c,u){var s=p(t[n],t,a);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"==o(f)&&i.call(f,"__await")?e.resolve(f.__await).then((function(t){r("next",t,c,u)}),(function(t){r("throw",t,c,u)})):e.resolve(f).then((function(t){l.value=t,c(l)}),(function(t){return r("throw",t,c,u)}))}u(s.arg)}var n;a(this,"_invoke",{value:function(t,o){function i(){return new e((function(e,n){r(t,o,e,n)}))}return n=n?n.then(i,i):i()}})}function O(t,e,r){var o="suspendedStart";return function(n,i){if("executing"===o)throw new Error("Generator is already running");if("completed"===o){if("throw"===n)throw i;return{value:void 0,done:!0}}for(r.method=n,r.arg=i;;){var a=r.delegate;if(a){var c=_(a,r);if(c){if(c===h)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===o)throw o="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o="executing";var u=p(t,e,r);if("normal"===u.type){if(o=r.done?"completed":"suspendedYield",u.arg===h)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(o="completed",r.method="throw",r.arg=u.arg)}}}function _(t,e){var r=e.method,o=t.iterator[r];if(void 0===o)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,_(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var n=p(o,t.iterator,e.arg);if("throw"===n.type)return e.method="throw",e.arg=n.arg,e.delegate=null,h;var i=n.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function E(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function N(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function P(t){if(t){var e=t[u];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,o=function e(){for(;++r<t.length;)if(i.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return o.next=o}}return{next:k}}function k(){return{value:void 0,done:!0}}return y.prototype=g,a(w,"constructor",{value:g,configurable:!0}),a(g,"constructor",{value:y,configurable:!0}),y.displayName=f(g,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,g):(t.__proto__=g,f(t,l,"GeneratorFunction")),t.prototype=Object.create(w),t},e.awrap=function(t){return{__await:t}},j(L.prototype),f(L.prototype,s,(function(){return this})),e.AsyncIterator=L,e.async=function(t,r,o,n,i){void 0===i&&(i=Promise);var a=new L(d(t,r,o,n),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},j(w),f(w,l,"Generator"),f(w,u,(function(){return this})),f(w,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var o in e)r.push(o);return r.reverse(),function t(){for(;r.length;){var o=r.pop();if(o in e)return t.value=o,t.done=!1,t}return t.done=!0,t}},e.values=P,N.prototype={constructor:N,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(E),!t)for(var e in this)"t"===e.charAt(0)&&i.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,o){return a.type="throw",a.arg=t,e.next=r,o&&(e.method="next",e.arg=void 0),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var n=this.tryEntries[o],a=n.completion;if("root"===n.tryLoc)return r("end");if(n.tryLoc<=this.prev){var c=i.call(n,"catchLoc"),u=i.call(n,"finallyLoc");if(c&&u){if(this.prev<n.catchLoc)return r(n.catchLoc,!0);if(this.prev<n.finallyLoc)return r(n.finallyLoc)}else if(c){if(this.prev<n.catchLoc)return r(n.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<n.finallyLoc)return r(n.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&i.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var n=o;break}}n&&("break"===t||"continue"===t)&&n.tryLoc<=e&&e<=n.finallyLoc&&(n=null);var a=n?n.completion:{};return a.type=t,a.arg=e,n?(this.method="next",this.next=n.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),E(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var o=r.completion;if("throw"===o.type){var n=o.arg;E(r)}return n}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:P(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},e}t.exports=n,t.exports.__esModule=!0,t.exports.default=t.exports},7425:t=>{function e(r){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2841:(t,e,r)=>{var o=r(7609)();t.exports=o;try{regeneratorRuntime=o}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=o:Function("r","regeneratorRuntime = r")(o)}}},a={};function c(t){var e=a[t];if(void 0!==e)return e.exports;var r=a[t]={exports:{}};return i[t](r,r.exports,c),r.exports}c.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return c.d(e,{a:e}),e},c.d=(t,e)=>{for(var r in e)c.o(e,r)&&!c.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},c.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),c.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var u={};return(()=>{"use strict";c.r(u),c.d(u,{default:()=>h});var t=c(4212),e=c(748),r=c(2841),o=c.n(r);Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var n=c(4976),i=c.n(n),a=c(2717),s=c(8014),l=c.n(s),f=l().propsMixin,d=Object.assign({},f);d.width.default="400",d.height.default="100%";const p=(0,e.defineComponent)({name:"Sideslider",components:{BkModal:l(),BkButton:i()},props:Object.assign(Object.assign({},d),{direction:{type:String,default:"right",validator:function(t){var e=["left","right"];return!(e.indexOf(t)<0&&(console.error("direction property is not valid: '".concat(t,"',【").concat(e.join(" | "),"】")),1))}}}),emits:["closed","update:isShow","shown","hidden","animation-end"],setup:function(t,r){var n=this,i=r.slots,c=r.emit,u=function(){return e=n,r=void 0,i=void 0,a=o().mark((function e(){var r;return o().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=!0,"function"!=typeof t.beforeClose){e.next=5;break}return e.next=4,t.beforeClose();case 4:r=e.sent;case 5:r&&(c("update:isShow",!1),c("closed"),setTimeout((function(){c("animation-end")}),250));case 6:case"end":return e.stop()}}),e)})),new(i||(i=Promise))((function(t,o){function n(t){try{u(a.next(t))}catch(t){o(t)}}function c(t){try{u(a.throw(t))}catch(t){o(t)}}function u(e){var r;e.done?t(e.value):(r=e.value,r instanceof i?r:new i((function(t){t(r)}))).then(n,c)}u((a=a.apply(e,r||[])).next())}));var e,r,i,a},s=function(){setTimeout((function(){c("shown")}),200)},f=function(){setTimeout((function(){c("hidden")}),200)},d=(0,a.usePrefix)().resolveClassName;return function(){var r,o={header:function(){var r,o;return(0,e.createVNode)(e.Fragment,null,[(0,e.createVNode)("div",{class:"".concat(d("sideslider-header"))},[(0,e.createVNode)("div",{class:"".concat(d("sideslider-close")," ").concat(t.direction),onClick:function(){u()}},null),(0,e.createVNode)("div",{class:"".concat(d("sideslider-title")," ").concat(t.direction)},[null!==(o=null===(r=i.header)||void 0===r?void 0:r.call(i))&&void 0!==o?o:t.title])])])},default:function(){var t,e;return null!==(e=null===(t=i.default)||void 0===t?void 0:t.call(i))&&void 0!==e?e:"Content"},footer:function(){return i.footer?(0,e.createVNode)("div",{class:"".concat(d("sideslider-footer"))},[i.footer()]):null}},n="".concat(d("sideslider-wrapper")," ").concat(t.scrollable?"scroll-able":""," ").concat(t.extCls),a=i.footer?"calc(100vh - 106px)":"calc(100vh - 52px)";return(0,e.createVNode)(l(),(0,e.mergeProps)(t,{maxHeight:a,class:n,style:"".concat(t.direction,": 0;"),onHidden:f,onShown:s,onClose:u}),"function"==typeof(r=o)||"[object Object]"===Object.prototype.toString.call(r)&&!(0,e.isVNode)(r)?o:{default:function(){return[o]}})}}}),h=(0,t.withInstall)(p)})(),u})()));
|
@@ -1,6 +1,6 @@
|
|
1
1
|
@import '../styles/themes/themes.less';
|
2
2
|
|
3
|
-
|
3
|
+
.@{bk-prefix}-sideslider {
|
4
4
|
position: fixed;
|
5
5
|
top: 0;
|
6
6
|
right: 0;
|
@@ -13,7 +13,7 @@
|
|
13
13
|
/* slide过渡动画 */
|
14
14
|
.slide-enter-active,
|
15
15
|
.slide-leave-active,
|
16
|
-
|
16
|
+
.@{bk-prefix}-modal-body {
|
17
17
|
transform: translateX(0);
|
18
18
|
transition: transform .25s;
|
19
19
|
}
|
@@ -49,8 +49,8 @@
|
|
49
49
|
}
|
50
50
|
}
|
51
51
|
|
52
|
-
|
53
|
-
|
52
|
+
.@{bk-prefix}-modal-wrapper {
|
53
|
+
&.@{bk-prefix}-sideslider-wrapper {
|
54
54
|
position: absolute;
|
55
55
|
top: 0;
|
56
56
|
bottom: 0;
|
@@ -60,18 +60,18 @@
|
|
60
60
|
//box-shadow: -5px 0 8px -5px rgb(0 0 0 / 20%);
|
61
61
|
|
62
62
|
&.scroll-able {
|
63
|
-
|
63
|
+
.@{bk-prefix}-modal-content {
|
64
64
|
overflow: auto;
|
65
65
|
}
|
66
66
|
}
|
67
67
|
|
68
|
-
|
68
|
+
.@{bk-prefix}-sideslider-header {
|
69
69
|
width: 100%;
|
70
70
|
height: 52px;
|
71
71
|
background: #fff;
|
72
72
|
border-bottom: 1px solid #dcdee5;
|
73
73
|
|
74
|
-
|
74
|
+
.@{bk-prefix}-sideslider-close {
|
75
75
|
position: absolute;
|
76
76
|
top: 0;
|
77
77
|
width: 30px;
|
@@ -118,7 +118,7 @@
|
|
118
118
|
|
119
119
|
}
|
120
120
|
|
121
|
-
|
121
|
+
.@{bk-prefix}-sideslider-title {
|
122
122
|
display: flex;
|
123
123
|
height: 52px;
|
124
124
|
padding-left: 30px;
|
@@ -133,7 +133,7 @@
|
|
133
133
|
}
|
134
134
|
}
|
135
135
|
|
136
|
-
|
136
|
+
.@{bk-prefix}-sideslider-footer {
|
137
137
|
display: flex;
|
138
138
|
width: 100%;
|
139
139
|
height: 54px;
|
package/lib/steps/index.d.ts
CHANGED
@@ -58,7 +58,7 @@ declare const BkSteps: {
|
|
58
58
|
}>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
59
59
|
[key: string]: any;
|
60
60
|
}>) => void)[];
|
61
|
-
readonly size?: "
|
61
|
+
readonly size?: "small" | "large" | "default";
|
62
62
|
"onUpdate:curStep"?: (...args: any[]) => any;
|
63
63
|
};
|
64
64
|
$attrs: {
|
@@ -78,7 +78,7 @@ declare const BkSteps: {
|
|
78
78
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
79
79
|
default: "success" | "warning" | "danger" | "primary";
|
80
80
|
};
|
81
|
-
size: import("vue-types").VueTypeDef<"
|
81
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
82
82
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
83
83
|
default: number;
|
84
84
|
} & {
|
@@ -118,6 +118,7 @@ declare const BkSteps: {
|
|
118
118
|
}, {
|
119
119
|
defaultSteps: import("vue").Ref<any[]>;
|
120
120
|
jumpTo: (index: any) => Promise<void>;
|
121
|
+
resolveClassName: (cls: string) => string;
|
121
122
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:curStep")[], string, {
|
122
123
|
steps: unknown[];
|
123
124
|
text: boolean;
|
@@ -153,7 +154,7 @@ declare const BkSteps: {
|
|
153
154
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
154
155
|
default: "success" | "warning" | "danger" | "primary";
|
155
156
|
};
|
156
|
-
size: import("vue-types").VueTypeDef<"
|
157
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
157
158
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
158
159
|
default: number;
|
159
160
|
} & {
|
@@ -193,6 +194,7 @@ declare const BkSteps: {
|
|
193
194
|
} & import("vue").ShallowUnwrapRef<{
|
194
195
|
defaultSteps: import("vue").Ref<any[]>;
|
195
196
|
jumpTo: (index: any) => Promise<void>;
|
197
|
+
resolveClassName: (cls: string) => string;
|
196
198
|
}> & {} & import("vue").ComponentCustomProperties & {};
|
197
199
|
__isFragment?: never;
|
198
200
|
__isTeleport?: never;
|
@@ -201,7 +203,7 @@ declare const BkSteps: {
|
|
201
203
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
202
204
|
default: "success" | "warning" | "danger" | "primary";
|
203
205
|
};
|
204
|
-
size: import("vue-types").VueTypeDef<"
|
206
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
205
207
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
206
208
|
default: number;
|
207
209
|
} & {
|
@@ -241,6 +243,7 @@ declare const BkSteps: {
|
|
241
243
|
}, {
|
242
244
|
defaultSteps: import("vue").Ref<any[]>;
|
243
245
|
jumpTo: (index: any) => Promise<void>;
|
246
|
+
resolveClassName: (cls: string) => string;
|
244
247
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:curStep")[], "click" | "update:curStep", {
|
245
248
|
steps: unknown[];
|
246
249
|
text: boolean;
|
package/lib/steps/index.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
1
|
/*! For license information please see index.js.LICENSE.txt */
|
2
|
-
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("../shared"),require("vue"),require("vue-types"),require("../config-provider"),require("../icon"));else if("function"==typeof define&&define.amd)define(["../shared","vue","vue-types","../config-provider","../icon"],e);else{var r="object"==typeof exports?e(require("../shared"),require("vue"),require("vue-types"),require("../config-provider"),require("../icon")):e(t["../shared"],t.vue,t["vue-types"],t["../config-provider"],t["../icon"]);for(var n in r)("object"==typeof exports?exports:t)[n]=r[n]}}(self,((t,e,r,n,o)=>(()=>{var i={2717:t=>{"use strict";t.exports=n},6870:t=>{"use strict";t.exports=o},4212:e=>{"use strict";e.exports=t},748:t=>{"use strict";t.exports=e},210:t=>{"use strict";t.exports=r},7609:(t,e,r)=>{var n=r(7425).default;function o(){"use strict";t.exports=o=function(){return e},t.exports.__esModule=!0,t.exports.default=t.exports;var e={},r=Object.prototype,i=r.hasOwnProperty,c=Object.defineProperty||function(t,e,r){t[e]=r.value},a="function"==typeof Symbol?Symbol:{},u=a.iterator||"@@iterator",s=a.asyncIterator||"@@asyncIterator",l=a.toStringTag||"@@toStringTag";function p(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{p({},"")}catch(t){p=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof v?e:v,i=Object.create(o.prototype),a=new O(n||[]);return c(i,"_invoke",{value:k(t,r,a)}),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=f;var d={};function v(){}function y(){}function m(){}var b={};p(b,u,(function(){return this}));var g=Object.getPrototypeOf,x=g&&g(g(T([])));x&&x!==r&&i.call(x,u)&&(b=x);var w=m.prototype=v.prototype=Object.create(b);function S(t){["next","throw","return"].forEach((function(e){p(t,e,(function(t){return this._invoke(e,t)}))}))}function j(t,e){function r(o,c,a,u){var s=h(t[o],t,c);if("throw"!==s.type){var l=s.arg,p=l.value;return p&&"object"==n(p)&&i.call(p,"__await")?e.resolve(p.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(p).then((function(t){l.value=t,a(l)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var o;c(this,"_invoke",{value:function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}})}function k(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var c=r.delegate;if(c){var a=L(c,r);if(a){if(a===d)continue;return a}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var u=h(t,e,r);if("normal"===u.type){if(n=r.done?"completed":"suspendedYield",u.arg===d)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n="completed",r.method="throw",r.arg=u.arg)}}}function L(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,L(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),d;var o=h(n,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,d;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,d):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,d)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function N(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function T(t){if(t){var e=t[u];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,n=function e(){for(;++r<t.length;)if(i.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return n.next=n}}return{next:_}}function _(){return{value:void 0,done:!0}}return y.prototype=m,c(w,"constructor",{value:m,configurable:!0}),c(m,"constructor",{value:y,configurable:!0}),y.displayName=p(m,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,p(t,l,"GeneratorFunction")),t.prototype=Object.create(w),t},e.awrap=function(t){return{__await:t}},S(j.prototype),p(j.prototype,s,(function(){return this})),e.AsyncIterator=j,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var c=new j(f(t,r,n,o),i);return e.isGeneratorFunction(r)?c:c.next().then((function(t){return t.done?t.value:c.next()}))},S(w),p(w,l,"Generator"),p(w,u,(function(){return this})),p(w,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=T,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(N),!t)for(var e in this)"t"===e.charAt(0)&&i.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,n){return c.type="throw",c.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n],c=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var a=i.call(o,"catchLoc"),u=i.call(o,"finallyLoc");if(a&&u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(a){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var c=o?o.completion:{};return c.type=t,c.arg=e,o?(this.method="next",this.next=o.finallyLoc,d):this.complete(c)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),d},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),N(r),d}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),d}},e}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},7425:t=>{function e(r){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2841:(t,e,r)=>{var n=r(7609)();t.exports=n;try{regeneratorRuntime=n}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}},c={};function a(t){var e=c[t];if(void 0!==e)return e.exports;var r=c[t]={exports:{}};return i[t](r,r.exports,a),r.exports}a.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return a.d(e,{a:e}),e},a.d=(t,e)=>{for(var r in e)a.o(e,r)&&!a.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},a.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),a.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var u={};return(()=>{"use strict";a.r(u),a.d(u,{default:()=>v});var t=a(4212);function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},e(t)}function r(t,r,n){return(r=function(t){var r=function(t,r){if("object"!==e(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var o=n.call(t,"string");if("object"!==e(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===e(r)?r:String(r)}(r))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,t}var n=a(748),o=a(2841),i=a.n(o);function c(t,e,r,n){return new(r||(r=Promise))((function(o,i){function c(t){try{u(n.next(t))}catch(t){i(t)}}function a(t){try{u(n.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(c,a)}u((n=n.apply(t,e||[])).next())}))}Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var s,l=a(210),p=a(2717),f=a(6870);!function(t){t.UNKNOWN="",t.ERROR="error",t.LOADING="loading"}(s||(s={}));var h={theme:t.PropTypes.theme().def(t.ThemeEnum.PRIMARY),size:t.PropTypes.size(),curStep:t.PropTypes.number.def(1),controllable:t.PropTypes.bool.def(!1),direction:(0,t.directionType)(),status:(0,l.toType)("status",{}).def(s.UNKNOWN),lineType:(0,t.lineStyleType)(),text:t.PropTypes.bool,extCls:t.PropTypes.string,steps:t.PropTypes.array.def([]),beforeChange:t.PropTypes.func};const d=(0,n.defineComponent)({name:"Steps",props:h,emits:["update:curStep","click"],setup:function(t,e){var r=this,o=e.emit,a=(0,p.useLocale)("steps"),u=(0,p.useLocale)("lang"),s=(0,n.ref)([]),l=function(t){var e,r=[];t.forEach((function(t){var e;"string"==typeof t?r.push(t):r.push({title:t.title,icon:t.icon,description:t.description,status:t.status,border:null===(e=t.border)||void 0===e||e})})),(e=s.value).splice.apply(e,[0,s.value.length].concat(r))},f=function(){var e,r;(e=s.value).splice.apply(e,[0,s.value.length].concat([{title:a.value.step1,icon:1},{title:a.value.step2,icon:2},{title:a.value.step3,icon:3}])),(null===(r=t.steps)||void 0===r?void 0:r.length)&&l(t.steps)};return(0,n.watch)((function(){return u.value}),(function(){f()})),(0,n.onMounted)(f),(0,n.watch)((function(){return t.steps}),(function(){l(t.steps)}),{deep:!0}),(0,n.watch)((function(){return t.curStep}),(function(){var e;e=t.curStep,h.curStep=e}),{deep:!0}),{defaultSteps:s,jumpTo:function(e){return c(r,void 0,void 0,i().mark((function r(){var n=this;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(r.prev=0,!t.controllable||e===t.curStep){r.next=7;break}if("function"!=typeof t.beforeChange){r.next=5;break}return r.next=5,new Promise((function(r,o){return c(n,void 0,void 0,i().mark((function n(){var c;return i().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,t.beforeChange(e);case 2:(c=n.sent)?r(c):o(c);case 4:case"end":return n.stop()}}),n)})))}));case 5:o("update:curStep",e),o("click",e);case 7:r.next=12;break;case 9:r.prev=9,r.t0=r.catch(0),console.warn(r.t0);case 12:case"end":return r.stop()}}),r,null,[[0,9]])})))}}},render:function(){var e,o=this,i="bk-steps",c=this.theme?"".concat(i,"-").concat(this.theme):"",a=this.size?"".concat(i,"-").concat(this.size):"",u=(0,t.classes)((r(e={},"".concat(this.extCls),!!this.extCls),r(e,"bk-steps-".concat(this.direction),this.direction),r(e,"bk-steps-".concat(this.lineType),this.lineType),e),"".concat(c," ").concat(i," ").concat(a)),s=function(t){return o.curStep>t+1||"done"===o.defaultSteps[t].status},l=function(t){return o.curStep===t+1},p=function(t){var e=t.icon;return e?"[object Object]"===Object.prototype.toString.call(e):"string"==typeof t},h=function(t,e){return e.icon||(e.icon=t),!isNaN(e.icon)},d=function(t,e){return l(t)&&"loading"===o.status||function(t){return"loading"===t.status}(e)?(0,n.createVNode)(f.Circle,{class:"bk-icon bk-steps-icon icon-loading"},null):l(t)&&"error"===o.status||function(t){return"error"===t.status}(e)?(0,n.createVNode)(f.Error,{class:"bk-steps-icon"},null):s(t)?(0,n.createVNode)(f.Done,{class:"bk-steps-icon"},null):(0,n.createVNode)("span",null,[h(t,e)?t+1:(0,n.createVNode)(e.icon,null,null)])};return(0,n.createVNode)("div",{class:u},[this.defaultSteps.map((function(t,e){var r,i,c;return(0,n.createVNode)("div",{class:["bk-step",t.title?"":"bk-step-no-content",s(e)?"done":"",l(e)?"current":"",l(e)&&"error"===o.status?"isError":"",t.status&&l(e)?["bk-step-".concat(t.status)]:""]},[(0,n.createVNode)("span",{class:["bk-step-indicator","bk-step-".concat(p(t)?"icon":"number"),"bk-step-icon".concat(t.status)],style:{cursor:o.controllable?"pointer":""},onClick:function(){o.jumpTo(e+1)}},[null!==(c=null===(i=(r=o.$slots)[e+1])||void 0===i?void 0:i.call(r))&&void 0!==c?c:d(e,t)]),t.title?(0,n.createVNode)("div",{class:"bk-step-content"},[(0,n.createVNode)("div",{class:"bk-step-title",style:{cursor:o.controllable?"pointer":""},onClick:function(){o.jumpTo(e+1)}},[t.title]),t.description&&(0,n.createVNode)("div",{class:"bk-step-description",title:t.description},[t.description])]):""])}))])}}),v=(0,t.withInstall)(d)})(),u})()));
|
2
|
+
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e(require("../shared"),require("vue"),require("vue-types"),require("../config-provider"),require("../icon"));else if("function"==typeof define&&define.amd)define(["../shared","vue","vue-types","../config-provider","../icon"],e);else{var r="object"==typeof exports?e(require("../shared"),require("vue"),require("vue-types"),require("../config-provider"),require("../icon")):e(t["../shared"],t.vue,t["vue-types"],t["../config-provider"],t["../icon"]);for(var n in r)("object"==typeof exports?exports:t)[n]=r[n]}}(self,((t,e,r,n,o)=>(()=>{var i={2717:t=>{"use strict";t.exports=n},6870:t=>{"use strict";t.exports=o},4212:e=>{"use strict";e.exports=t},748:t=>{"use strict";t.exports=e},210:t=>{"use strict";t.exports=r},7609:(t,e,r)=>{var n=r(7425).default;function o(){"use strict";t.exports=o=function(){return e},t.exports.__esModule=!0,t.exports.default=t.exports;var e={},r=Object.prototype,i=r.hasOwnProperty,a=Object.defineProperty||function(t,e,r){t[e]=r.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",u=c.asyncIterator||"@@asyncIterator",l=c.toStringTag||"@@toStringTag";function p(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{p({},"")}catch(t){p=function(t,e,r){return t[e]=r}}function f(t,e,r,n){var o=e&&e.prototype instanceof d?e:d,i=Object.create(o.prototype),c=new O(n||[]);return a(i,"_invoke",{value:j(t,r,c)}),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}e.wrap=f;var v={};function d(){}function y(){}function m(){}var g={};p(g,s,(function(){return this}));var b=Object.getPrototypeOf,x=b&&b(b(T([])));x&&x!==r&&i.call(x,s)&&(g=x);var w=m.prototype=d.prototype=Object.create(g);function N(t){["next","throw","return"].forEach((function(e){p(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function r(o,a,c,s){var u=h(t[o],t,a);if("throw"!==u.type){var l=u.arg,p=l.value;return p&&"object"==n(p)&&i.call(p,"__await")?e.resolve(p.__await).then((function(t){r("next",t,c,s)}),(function(t){r("throw",t,c,s)})):e.resolve(p).then((function(t){l.value=t,c(l)}),(function(t){return r("throw",t,c,s)}))}s(u.arg)}var o;a(this,"_invoke",{value:function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}})}function j(t,e,r){var n="suspendedStart";return function(o,i){if("executing"===n)throw new Error("Generator is already running");if("completed"===n){if("throw"===o)throw i;return{value:void 0,done:!0}}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var c=L(a,r);if(c){if(c===v)continue;return c}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=h(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===v)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function L(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,L(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),v;var o=h(n,t.iterator,e.arg);if("throw"===o.type)return e.method="throw",e.arg=o.arg,e.delegate=null,v;var i=o.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,v):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,v)}function E(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function C(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(E,this),this.reset(!0)}function T(t){if(t){var e=t[s];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,n=function e(){for(;++r<t.length;)if(i.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return n.next=n}}return{next:_}}function _(){return{value:void 0,done:!0}}return y.prototype=m,a(w,"constructor",{value:m,configurable:!0}),a(m,"constructor",{value:y,configurable:!0}),y.displayName=p(m,l,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===y||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,p(t,l,"GeneratorFunction")),t.prototype=Object.create(w),t},e.awrap=function(t){return{__await:t}},N(S.prototype),p(S.prototype,u,(function(){return this})),e.AsyncIterator=S,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new S(f(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},N(w),p(w,l,"Generator"),p(w,s,(function(){return this})),p(w,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},e.values=T,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(C),!t)for(var e in this)"t"===e.charAt(0)&&i.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var n=this.tryEntries.length-1;n>=0;--n){var o=this.tryEntries[n],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var c=i.call(o,"catchLoc"),s=i.call(o,"finallyLoc");if(c&&s){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(c){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,v):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),C(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;C(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:T(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),v}},e}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},7425:t=>{function e(r){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},2841:(t,e,r)=>{var n=r(7609)();t.exports=n;try{regeneratorRuntime=n}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}},a={};function c(t){var e=a[t];if(void 0!==e)return e.exports;var r=a[t]={exports:{}};return i[t](r,r.exports,c),r.exports}c.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return c.d(e,{a:e}),e},c.d=(t,e)=>{for(var r in e)c.o(e,r)&&!c.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},c.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),c.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var s={};return(()=>{"use strict";c.r(s),c.d(s,{default:()=>d});var t=c(4212);function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},e(t)}function r(t,r,n){return(r=function(t){var r=function(t,r){if("object"!==e(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var o=n.call(t,"string");if("object"!==e(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===e(r)?r:String(r)}(r))in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,t}var n=c(748),o=c(2841),i=c.n(o);function a(t,e,r,n){return new(r||(r=Promise))((function(o,i){function a(t){try{s(n.next(t))}catch(t){i(t)}}function c(t){try{s(n.throw(t))}catch(t){i(t)}}function s(t){var e;t.done?o(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(a,c)}s((n=n.apply(t,e||[])).next())}))}Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError;var u,l=c(210),p=c(2717),f=c(6870);!function(t){t.UNKNOWN="",t.ERROR="error",t.LOADING="loading"}(u||(u={}));var h={theme:t.PropTypes.theme().def(t.ThemeEnum.PRIMARY),size:t.PropTypes.size(),curStep:t.PropTypes.number.def(1),controllable:t.PropTypes.bool.def(!1),direction:(0,t.directionType)(),status:(0,l.toType)("status",{}).def(u.UNKNOWN),lineType:(0,t.lineStyleType)(),text:t.PropTypes.bool,extCls:t.PropTypes.string,steps:t.PropTypes.array.def([]),beforeChange:t.PropTypes.func};const v=(0,n.defineComponent)({name:"Steps",props:h,emits:["update:curStep","click"],setup:function(t,e){var r=this,o=e.emit,c=(0,p.useLocale)("steps"),s=(0,p.useLocale)("lang"),u=(0,n.ref)([]),l=function(t){var e,r=[];t.forEach((function(t){var e;"string"==typeof t?r.push(t):r.push({title:t.title,icon:t.icon,description:t.description,status:t.status,border:null===(e=t.border)||void 0===e||e})})),(e=u.value).splice.apply(e,[0,u.value.length].concat(r))},f=function(){var e,r;(e=u.value).splice.apply(e,[0,u.value.length].concat([{title:c.value.step1,icon:1},{title:c.value.step2,icon:2},{title:c.value.step3,icon:3}])),(null===(r=t.steps)||void 0===r?void 0:r.length)&&l(t.steps)};(0,n.watch)((function(){return s.value}),(function(){f()})),(0,n.onMounted)(f),(0,n.watch)((function(){return t.steps}),(function(){l(t.steps)}),{deep:!0}),(0,n.watch)((function(){return t.curStep}),(function(){var e;e=t.curStep,h.curStep=e}),{deep:!0});var v=(0,p.usePrefix)().resolveClassName;return{defaultSteps:u,jumpTo:function(e){return a(r,void 0,void 0,i().mark((function r(){var n=this;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(r.prev=0,!t.controllable||e===t.curStep){r.next=7;break}if("function"!=typeof t.beforeChange){r.next=5;break}return r.next=5,new Promise((function(r,o){return a(n,void 0,void 0,i().mark((function n(){var a;return i().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,t.beforeChange(e);case 2:(a=n.sent)?r(a):o(a);case 4:case"end":return n.stop()}}),n)})))}));case 5:o("update:curStep",e),o("click",e);case 7:r.next=12;break;case 9:r.prev=9,r.t0=r.catch(0),console.warn(r.t0);case 12:case"end":return r.stop()}}),r,null,[[0,9]])})))},resolveClassName:v}},render:function(){var e,o=this,i=this.resolveClassName("steps"),a=this.theme?"".concat(i,"-").concat(this.theme):"",c=this.size?"".concat(i,"-").concat(this.size):"",s=(0,t.classes)((r(e={},"".concat(this.extCls),!!this.extCls),r(e,"".concat(this.resolveClassName("steps-".concat(this.direction))),this.direction),r(e,"".concat(this.resolveClassName("steps-".concat(this.lineType))),this.lineType),e),"".concat(a," ").concat(i," ").concat(c)),u=function(t){return o.curStep>t+1||"done"===o.defaultSteps[t].status},l=function(t){return o.curStep===t+1},p=function(t){var e=t.icon;return e?"[object Object]"===Object.prototype.toString.call(e):"string"==typeof t},h=function(t,e){return e.icon||(e.icon=t),!isNaN(e.icon)},v=function(t,e){return l(t)&&"loading"===o.status||function(t){return"loading"===t.status}(e)?(0,n.createVNode)(f.Circle,{class:"".concat(o.resolveClassName("icon")," ").concat(o.resolveClassName("steps-icon")," icon-loading")},null):l(t)&&"error"===o.status||function(t){return"error"===t.status}(e)?(0,n.createVNode)(f.Error,{class:"".concat(o.resolveClassName("steps-icon"))},null):u(t)?(0,n.createVNode)(f.Done,{class:"".concat(o.resolveClassName("steps-icon"))},null):(0,n.createVNode)("span",null,[h(t,e)?t+1:(0,n.createVNode)(e.icon,null,null)])};return(0,n.createVNode)("div",{class:s},[this.defaultSteps.map((function(t,e){var r,i,a;return(0,n.createVNode)("div",{class:[o.resolveClassName("steps"),t.title?"":o.resolveClassName("step-no-content"),u(e)?"done":"",l(e)?"current":"",l(e)&&"error"===o.status?"isError":"",t.status&&l(e)?["".concat(o.resolveClassName("step-".concat(t.status)))]:""]},[(0,n.createVNode)("span",{class:["".concat(o.resolveClassName("step-indicator")),"".concat(o.resolveClassName("step-".concat(p(t)?"icon":"number"))),"".concat(o.resolveClassName("step-icon".concat(t.status)))],style:{cursor:o.controllable?"pointer":""},onClick:function(){o.jumpTo(e+1)}},[null!==(a=null===(i=(r=o.$slots)[e+1])||void 0===i?void 0:i.call(r))&&void 0!==a?a:v(e,t)]),t.title?(0,n.createVNode)("div",{class:"".concat(o.resolveClassName("step-content"))},[(0,n.createVNode)("div",{class:"".concat(o.resolveClassName("step-title")),style:{cursor:o.controllable?"pointer":""},onClick:function(){o.jumpTo(e+1)}},[t.title]),t.description&&(0,n.createVNode)("div",{class:"".concat(o.resolveClassName("step-description")),title:t.description},[t.description])]):""])}))])}}),d=(0,t.withInstall)(v)})(),s})()));
|
package/lib/steps/steps.d.ts
CHANGED
@@ -28,7 +28,7 @@ declare const stepsProps: {
|
|
28
28
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
29
29
|
default: "success" | "warning" | "danger" | "primary";
|
30
30
|
};
|
31
|
-
size: import("vue-types").VueTypeDef<"
|
31
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
32
32
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
33
33
|
default: number;
|
34
34
|
} & {
|
@@ -68,7 +68,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
68
68
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
69
69
|
default: "success" | "warning" | "danger" | "primary";
|
70
70
|
};
|
71
|
-
size: import("vue-types").VueTypeDef<"
|
71
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
72
72
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
73
73
|
default: number;
|
74
74
|
} & {
|
@@ -105,11 +105,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
105
105
|
}, {
|
106
106
|
defaultSteps: import("vue").Ref<any[]>;
|
107
107
|
jumpTo: (index: any) => Promise<void>;
|
108
|
+
resolveClassName: (cls: string) => string;
|
108
109
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("click" | "update:curStep")[], "click" | "update:curStep", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
|
109
110
|
theme: import("vue-types").VueTypeDef<"success" | "warning" | "danger" | "primary"> & {
|
110
111
|
default: "success" | "warning" | "danger" | "primary";
|
111
112
|
};
|
112
|
-
size: import("vue-types").VueTypeDef<"
|
113
|
+
size: import("vue-types").VueTypeDef<"small" | "large" | "default">;
|
113
114
|
curStep: import("vue-types").VueTypeValidableDef<number> & {
|
114
115
|
default: number;
|
115
116
|
} & {
|
package/lib/steps/steps.less
CHANGED
@@ -26,7 +26,7 @@
|
|
26
26
|
}
|
27
27
|
}
|
28
28
|
|
29
|
-
|
29
|
+
.@{bk-prefix}-steps {
|
30
30
|
display: flex;
|
31
31
|
width: 100%;
|
32
32
|
font-size: 0;
|
@@ -41,7 +41,7 @@
|
|
41
41
|
border-radius: 7px;
|
42
42
|
}
|
43
43
|
|
44
|
-
|
44
|
+
.@{bk-prefix}-icon {
|
45
45
|
font-size: 24px;
|
46
46
|
line-height: 24px;
|
47
47
|
|
@@ -52,7 +52,7 @@
|
|
52
52
|
}
|
53
53
|
}
|
54
54
|
|
55
|
-
|
55
|
+
.@{bk-prefix}-step {
|
56
56
|
position: relative;
|
57
57
|
margin-right: 8px;
|
58
58
|
overflow: hidden;
|
@@ -60,7 +60,7 @@
|
|
60
60
|
white-space: nowrap;
|
61
61
|
flex: 1;
|
62
62
|
|
63
|
-
|
63
|
+
.@{bk-prefix}-step-indicator {
|
64
64
|
z-index: 1;
|
65
65
|
display: inline-flex;
|
66
66
|
width: 24px;
|
@@ -78,22 +78,22 @@
|
|
78
78
|
align-items: center;
|
79
79
|
justify-content: center;
|
80
80
|
|
81
|
-
//
|
81
|
+
// .@{bk-prefix}-steps-icon {
|
82
82
|
// color: @white-color;
|
83
83
|
// }
|
84
84
|
}
|
85
85
|
|
86
|
-
|
86
|
+
.@{bk-prefix}-step-number {
|
87
87
|
font-family: arial;
|
88
88
|
font-size: 14px;
|
89
89
|
}
|
90
90
|
|
91
|
-
|
91
|
+
.@{bk-prefix}-step-content {
|
92
92
|
display: inline-block;
|
93
93
|
vertical-align: top;
|
94
94
|
}
|
95
95
|
|
96
|
-
|
96
|
+
.@{bk-prefix}-step-title {
|
97
97
|
position: relative;
|
98
98
|
display: inline-block;
|
99
99
|
padding-right: 8px;
|
@@ -104,7 +104,7 @@
|
|
104
104
|
.after-line();
|
105
105
|
}
|
106
106
|
|
107
|
-
|
107
|
+
.@{bk-prefix}-step-description {
|
108
108
|
max-width: 140px;
|
109
109
|
font-size: 12px;
|
110
110
|
color: #979ba5;
|
@@ -112,8 +112,8 @@
|
|
112
112
|
|
113
113
|
}
|
114
114
|
|
115
|
-
|
116
|
-
|
115
|
+
&.@{bk-prefix}-step-no-content {
|
116
|
+
.@{bk-prefix}-step-indicator {
|
117
117
|
margin-right: 0;
|
118
118
|
|
119
119
|
.after-line();
|
@@ -129,7 +129,7 @@
|
|
129
129
|
margin-right: 0;
|
130
130
|
flex: none;
|
131
131
|
|
132
|
-
|
132
|
+
.@{bk-prefix}-step-title {
|
133
133
|
padding-right: 0;
|
134
134
|
|
135
135
|
&::after {
|
@@ -139,56 +139,56 @@
|
|
139
139
|
}
|
140
140
|
|
141
141
|
&.done {
|
142
|
-
|
143
|
-
|
142
|
+
.@{bk-prefix}-step-title,
|
143
|
+
.@{bk-prefix}-step-description {
|
144
144
|
color: @default-color;
|
145
145
|
}
|
146
146
|
|
147
|
-
|
147
|
+
.@{bk-prefix}-steps-icon {
|
148
148
|
margin-bottom: 3px;
|
149
149
|
font-size: 22px;
|
150
150
|
}
|
151
151
|
|
152
|
-
|
153
|
-
|
152
|
+
.@{bk-prefix}-step-iconerror {
|
153
|
+
.@{bk-prefix}-steps-icon {
|
154
154
|
font-size: 14px;
|
155
155
|
}
|
156
156
|
}
|
157
157
|
}
|
158
158
|
|
159
159
|
&.current {
|
160
|
-
|
161
|
-
|
162
|
-
|
160
|
+
.@{bk-prefix}-step-number,
|
161
|
+
.@{bk-prefix}-step-icon,
|
162
|
+
.@{bk-prefix}-step-text {
|
163
163
|
border-width: 2px;
|
164
164
|
}
|
165
165
|
|
166
|
-
|
167
|
-
|
166
|
+
.@{bk-prefix}-step-title,
|
167
|
+
.@{bk-prefix}-step-description {
|
168
168
|
color: @default-color;
|
169
169
|
}
|
170
170
|
|
171
|
-
|
172
|
-
|
171
|
+
&.@{bk-prefix}-step-error {
|
172
|
+
.@{bk-prefix}-step-indicator {
|
173
173
|
background-color: @danger-color;
|
174
174
|
border-color: @danger-color;
|
175
175
|
}
|
176
176
|
|
177
|
-
|
178
|
-
|
177
|
+
.@{bk-prefix}-step-title,
|
178
|
+
.@{bk-prefix}-step-description {
|
179
179
|
color: @danger-color;
|
180
180
|
}
|
181
181
|
}
|
182
182
|
}
|
183
183
|
|
184
184
|
&.isError {
|
185
|
-
|
185
|
+
.@{bk-prefix}-step-indicator {
|
186
186
|
background-color: @danger-color !important;
|
187
187
|
border-color: @danger-color !important;
|
188
188
|
}
|
189
189
|
|
190
|
-
|
191
|
-
|
190
|
+
.@{bk-prefix}-step-content {
|
191
|
+
.@{bk-prefix}-step-title {
|
192
192
|
color: @danger-color !important;
|
193
193
|
}
|
194
194
|
}
|
@@ -199,33 +199,33 @@
|
|
199
199
|
each(@themeSelectors, {
|
200
200
|
@color: '@{value}-color';
|
201
201
|
&-@{value} {
|
202
|
-
|
202
|
+
.@{bk-prefix}-step {
|
203
203
|
&.done {
|
204
|
-
|
205
|
-
|
206
|
-
|
204
|
+
.@{bk-prefix}-step-number,
|
205
|
+
.@{bk-prefix}-step-icon,
|
206
|
+
.@{bk-prefix}-step-text {
|
207
207
|
color: @@color;
|
208
208
|
border-color: @@color;
|
209
209
|
}
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
210
|
+
|
211
|
+
|
212
|
+
.@{bk-prefix}-step-title,
|
213
|
+
.@{bk-prefix}-step-indicator {
|
214
214
|
&::after {
|
215
215
|
background-image: linear-gradient(to right, @@color 50%, transparent 0%);
|
216
216
|
}
|
217
217
|
}
|
218
|
-
|
219
|
-
|
218
|
+
|
219
|
+
|
220
220
|
&::after {
|
221
221
|
background-image: linear-gradient(@@color 50%, transparent 0%);
|
222
222
|
}
|
223
223
|
}
|
224
|
-
|
224
|
+
|
225
225
|
&.current {
|
226
|
-
|
227
|
-
|
228
|
-
|
226
|
+
.@{bk-prefix}-step-number,
|
227
|
+
.@{bk-prefix}-step-icon,
|
228
|
+
.@{bk-prefix}-step-text {
|
229
229
|
color: #fff;
|
230
230
|
background-color: @@color;
|
231
231
|
border-color: @@color;
|
@@ -236,9 +236,9 @@
|
|
236
236
|
})
|
237
237
|
|
238
238
|
&-dashed {
|
239
|
-
|
240
|
-
|
241
|
-
|
239
|
+
.@{bk-prefix}-step {
|
240
|
+
.@{bk-prefix}-step-title,
|
241
|
+
.@{bk-prefix}-step-indicator {
|
242
242
|
&::after {
|
243
243
|
background-image: linear-gradient(to right, @light-gray 50%, transparent 0%);
|
244
244
|
background-position: bottom;
|
@@ -250,9 +250,9 @@
|
|
250
250
|
}
|
251
251
|
|
252
252
|
&-solid {
|
253
|
-
|
254
|
-
|
255
|
-
|
253
|
+
.@{bk-prefix}-step {
|
254
|
+
.@{bk-prefix}-step-title,
|
255
|
+
.@{bk-prefix}-step-indicator {
|
256
256
|
&::after {
|
257
257
|
background-color: @light-gray;
|
258
258
|
}
|
@@ -264,12 +264,12 @@
|
|
264
264
|
flex-direction: column;
|
265
265
|
height: 100%;
|
266
266
|
|
267
|
-
|
267
|
+
.@{bk-prefix}-step {
|
268
268
|
margin-right: 0;
|
269
269
|
margin-bottom: 8px;
|
270
270
|
|
271
|
-
|
272
|
-
|
271
|
+
.@{bk-prefix}-step-title,
|
272
|
+
.@{bk-prefix}-step-indicator {
|
273
273
|
&::after {
|
274
274
|
display: none;
|
275
275
|
}
|
@@ -288,7 +288,7 @@
|
|
288
288
|
content: '';
|
289
289
|
}
|
290
290
|
|
291
|
-
|
291
|
+
.@{bk-prefix}-step-title {
|
292
292
|
display: flex;
|
293
293
|
height: 100%;
|
294
294
|
margin-top: 0;
|
@@ -300,23 +300,23 @@
|
|
300
300
|
|
301
301
|
|
302
302
|
&-small {
|
303
|
-
|
304
|
-
|
303
|
+
.@{bk-prefix}-step {
|
304
|
+
.@{bk-prefix}-step-indicator {
|
305
305
|
width: 20px;
|
306
306
|
height: 20px;
|
307
307
|
line-height: 20px;
|
308
308
|
}
|
309
309
|
|
310
|
-
|
310
|
+
.@{bk-prefix}-step-title {
|
311
311
|
font-size: 12px;
|
312
312
|
line-height: 20px;
|
313
313
|
}
|
314
314
|
|
315
|
-
|
315
|
+
.@{bk-prefix}-step-number {
|
316
316
|
font-size: 12px;
|
317
317
|
}
|
318
318
|
|
319
|
-
|
319
|
+
.@{bk-prefix}-step-icon {
|
320
320
|
font-size: 14px;
|
321
321
|
line-height: 14px;
|
322
322
|
}
|
@@ -326,14 +326,14 @@
|
|
326
326
|
left: 10px;
|
327
327
|
}
|
328
328
|
|
329
|
-
|
329
|
+
.@{bk-prefix}-step-title {
|
330
330
|
&::after {
|
331
331
|
top: 10px;
|
332
332
|
}
|
333
333
|
}
|
334
334
|
|
335
|
-
|
336
|
-
|
335
|
+
&.@{bk-prefix}-step-no-content {
|
336
|
+
.@{bk-prefix}-step-indicator {
|
337
337
|
&::after {
|
338
338
|
top: 8px;
|
339
339
|
left: 28px;
|
@@ -342,4 +342,4 @@
|
|
342
342
|
}
|
343
343
|
}
|
344
344
|
}
|
345
|
-
}
|
345
|
+
}
|