@mdsfe/mds-ui 0.2.9-rc.1 → 0.2.10-rc.1
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/CHANGELOG.md +15 -0
- package/dist/datepicker.js +3 -1
- package/dist/drawer.js +8 -4
- package/dist/index.js +1 -1
- package/dist/mds-ui.min.js +91 -101
- package/dist/pagination.js +37 -12
- package/package.json +2 -1
package/dist/mds-ui.min.js
CHANGED
|
@@ -25607,7 +25607,7 @@ module.exports = { "default": __webpack_require__(296), __esModule: true };
|
|
|
25607
25607
|
"use strict";
|
|
25608
25608
|
/* WEBPACK VAR INJECTION */(function(global) {/**!
|
|
25609
25609
|
* @fileOverview Kickass library to create and place poppers near their reference elements.
|
|
25610
|
-
* @version 1.
|
|
25610
|
+
* @version 1.14.7
|
|
25611
25611
|
* @license
|
|
25612
25612
|
* Copyright (c) 2016 Federico Zivolo and contributors
|
|
25613
25613
|
*
|
|
@@ -25629,17 +25629,16 @@ module.exports = { "default": __webpack_require__(296), __esModule: true };
|
|
|
25629
25629
|
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
25630
25630
|
* SOFTWARE.
|
|
25631
25631
|
*/
|
|
25632
|
-
var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined'
|
|
25633
|
-
|
|
25634
|
-
var
|
|
25635
|
-
|
|
25636
|
-
|
|
25637
|
-
|
|
25638
|
-
|
|
25639
|
-
|
|
25632
|
+
var isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined';
|
|
25633
|
+
|
|
25634
|
+
var longerTimeoutBrowsers = ['Edge', 'Trident', 'Firefox'];
|
|
25635
|
+
var timeoutDuration = 0;
|
|
25636
|
+
for (var i = 0; i < longerTimeoutBrowsers.length; i += 1) {
|
|
25637
|
+
if (isBrowser && navigator.userAgent.indexOf(longerTimeoutBrowsers[i]) >= 0) {
|
|
25638
|
+
timeoutDuration = 1;
|
|
25639
|
+
break;
|
|
25640
25640
|
}
|
|
25641
|
-
|
|
25642
|
-
}();
|
|
25641
|
+
}
|
|
25643
25642
|
|
|
25644
25643
|
function microtaskDebounce(fn) {
|
|
25645
25644
|
var called = false;
|
|
@@ -25759,17 +25758,6 @@ function getScrollParent(element) {
|
|
|
25759
25758
|
return getScrollParent(getParentNode(element));
|
|
25760
25759
|
}
|
|
25761
25760
|
|
|
25762
|
-
/**
|
|
25763
|
-
* Returns the reference node of the reference object, or the reference object itself.
|
|
25764
|
-
* @method
|
|
25765
|
-
* @memberof Popper.Utils
|
|
25766
|
-
* @param {Element|Object} reference - the reference element (the popper will be relative to this)
|
|
25767
|
-
* @returns {Element} parent
|
|
25768
|
-
*/
|
|
25769
|
-
function getReferenceNode(reference) {
|
|
25770
|
-
return reference && reference.referenceNode ? reference.referenceNode : reference;
|
|
25771
|
-
}
|
|
25772
|
-
|
|
25773
25761
|
var isIE11 = isBrowser && !!(window.MSInputMethodContext && document.documentMode);
|
|
25774
25762
|
var isIE10 = isBrowser && /MSIE 10/.test(navigator.userAgent);
|
|
25775
25763
|
|
|
@@ -25953,7 +25941,7 @@ function getBordersSize(styles, axis) {
|
|
|
25953
25941
|
var sideA = axis === 'x' ? 'Left' : 'Top';
|
|
25954
25942
|
var sideB = sideA === 'Left' ? 'Right' : 'Bottom';
|
|
25955
25943
|
|
|
25956
|
-
return parseFloat(styles['border' + sideA + 'Width']) + parseFloat(styles['border' + sideB + 'Width']);
|
|
25944
|
+
return parseFloat(styles['border' + sideA + 'Width'], 10) + parseFloat(styles['border' + sideB + 'Width'], 10);
|
|
25957
25945
|
}
|
|
25958
25946
|
|
|
25959
25947
|
function getSize(axis, body, html, computedStyle) {
|
|
@@ -26078,8 +26066,8 @@ function getBoundingClientRect(element) {
|
|
|
26078
26066
|
|
|
26079
26067
|
// subtract scrollbar size from sizes
|
|
26080
26068
|
var sizes = element.nodeName === 'HTML' ? getWindowSizes(element.ownerDocument) : {};
|
|
26081
|
-
var width = sizes.width || element.clientWidth || result.
|
|
26082
|
-
var height = sizes.height || element.clientHeight || result.
|
|
26069
|
+
var width = sizes.width || element.clientWidth || result.right - result.left;
|
|
26070
|
+
var height = sizes.height || element.clientHeight || result.bottom - result.top;
|
|
26083
26071
|
|
|
26084
26072
|
var horizScrollbar = element.offsetWidth - width;
|
|
26085
26073
|
var vertScrollbar = element.offsetHeight - height;
|
|
@@ -26108,8 +26096,8 @@ function getOffsetRectRelativeToArbitraryNode(children, parent) {
|
|
|
26108
26096
|
var scrollParent = getScrollParent(children);
|
|
26109
26097
|
|
|
26110
26098
|
var styles = getStyleComputedProperty(parent);
|
|
26111
|
-
var borderTopWidth = parseFloat(styles.borderTopWidth);
|
|
26112
|
-
var borderLeftWidth = parseFloat(styles.borderLeftWidth);
|
|
26099
|
+
var borderTopWidth = parseFloat(styles.borderTopWidth, 10);
|
|
26100
|
+
var borderLeftWidth = parseFloat(styles.borderLeftWidth, 10);
|
|
26113
26101
|
|
|
26114
26102
|
// In cases where the parent is fixed, we must ignore negative scroll in offset calc
|
|
26115
26103
|
if (fixedPosition && isHTML) {
|
|
@@ -26130,8 +26118,8 @@ function getOffsetRectRelativeToArbitraryNode(children, parent) {
|
|
|
26130
26118
|
// differently when margins are applied to it. The margins are included in
|
|
26131
26119
|
// the box of the documentElement, in the other cases not.
|
|
26132
26120
|
if (!isIE10 && isHTML) {
|
|
26133
|
-
var marginTop = parseFloat(styles.marginTop);
|
|
26134
|
-
var marginLeft = parseFloat(styles.marginLeft);
|
|
26121
|
+
var marginTop = parseFloat(styles.marginTop, 10);
|
|
26122
|
+
var marginLeft = parseFloat(styles.marginLeft, 10);
|
|
26135
26123
|
|
|
26136
26124
|
offsets.top -= borderTopWidth - marginTop;
|
|
26137
26125
|
offsets.bottom -= borderTopWidth - marginTop;
|
|
@@ -26231,7 +26219,7 @@ function getBoundaries(popper, reference, padding, boundariesElement) {
|
|
|
26231
26219
|
// NOTE: 1 DOM access here
|
|
26232
26220
|
|
|
26233
26221
|
var boundaries = { top: 0, left: 0 };
|
|
26234
|
-
var offsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper,
|
|
26222
|
+
var offsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper, reference);
|
|
26235
26223
|
|
|
26236
26224
|
// Handle viewport case
|
|
26237
26225
|
if (boundariesElement === 'viewport') {
|
|
@@ -26359,7 +26347,7 @@ function computeAutoPlacement(placement, refRect, popper, reference, boundariesE
|
|
|
26359
26347
|
function getReferenceOffsets(state, popper, reference) {
|
|
26360
26348
|
var fixedPosition = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : null;
|
|
26361
26349
|
|
|
26362
|
-
var commonOffsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper,
|
|
26350
|
+
var commonOffsetParent = fixedPosition ? getFixedPositionOffsetParent(popper) : findCommonOffsetParent(popper, reference);
|
|
26363
26351
|
return getOffsetRectRelativeToArbitraryNode(reference, commonOffsetParent, fixedPosition);
|
|
26364
26352
|
}
|
|
26365
26353
|
|
|
@@ -26621,7 +26609,7 @@ function destroy() {
|
|
|
26621
26609
|
|
|
26622
26610
|
this.disableEventListeners();
|
|
26623
26611
|
|
|
26624
|
-
// remove the popper if user
|
|
26612
|
+
// remove the popper if user explicity asked for the deletion on destroy
|
|
26625
26613
|
// do not use `remove` because IE11 doesn't support it
|
|
26626
26614
|
if (this.options.removeOnDestroy) {
|
|
26627
26615
|
this.popper.parentNode.removeChild(this.popper);
|
|
@@ -27070,8 +27058,8 @@ function arrow(data, options) {
|
|
|
27070
27058
|
// Compute the sideValue using the updated popper offsets
|
|
27071
27059
|
// take popper margin in account because we don't have this info available
|
|
27072
27060
|
var css = getStyleComputedProperty(data.instance.popper);
|
|
27073
|
-
var popperMarginSide = parseFloat(css['margin' + sideCapitalized]);
|
|
27074
|
-
var popperBorderSide = parseFloat(css['border' + sideCapitalized + 'Width']);
|
|
27061
|
+
var popperMarginSide = parseFloat(css['margin' + sideCapitalized], 10);
|
|
27062
|
+
var popperBorderSide = parseFloat(css['border' + sideCapitalized + 'Width'], 10);
|
|
27075
27063
|
var sideValue = center - data.offsets.popper[side] - popperMarginSide - popperBorderSide;
|
|
27076
27064
|
|
|
27077
27065
|
// prevent arrowElement from being placed not contiguously to its popper
|
|
@@ -27223,14 +27211,7 @@ function flip(data, options) {
|
|
|
27223
27211
|
|
|
27224
27212
|
// flip the variation if required
|
|
27225
27213
|
var isVertical = ['top', 'bottom'].indexOf(placement) !== -1;
|
|
27226
|
-
|
|
27227
|
-
// flips variation if reference element overflows boundaries
|
|
27228
|
-
var flippedVariationByRef = !!options.flipVariations && (isVertical && variation === 'start' && overflowsLeft || isVertical && variation === 'end' && overflowsRight || !isVertical && variation === 'start' && overflowsTop || !isVertical && variation === 'end' && overflowsBottom);
|
|
27229
|
-
|
|
27230
|
-
// flips variation if popper content overflows boundaries
|
|
27231
|
-
var flippedVariationByContent = !!options.flipVariationsByContent && (isVertical && variation === 'start' && overflowsRight || isVertical && variation === 'end' && overflowsLeft || !isVertical && variation === 'start' && overflowsBottom || !isVertical && variation === 'end' && overflowsTop);
|
|
27232
|
-
|
|
27233
|
-
var flippedVariation = flippedVariationByRef || flippedVariationByContent;
|
|
27214
|
+
var flippedVariation = !!options.flipVariations && (isVertical && variation === 'start' && overflowsLeft || isVertical && variation === 'end' && overflowsRight || !isVertical && variation === 'start' && overflowsTop || !isVertical && variation === 'end' && overflowsBottom);
|
|
27234
27215
|
|
|
27235
27216
|
if (overlapsRef || overflowsBoundaries || flippedVariation) {
|
|
27236
27217
|
// this boolean to detect any flip loop
|
|
@@ -27837,23 +27818,7 @@ var modifiers = {
|
|
|
27837
27818
|
* The popper will never be placed outside of the defined boundaries
|
|
27838
27819
|
* (except if `keepTogether` is enabled)
|
|
27839
27820
|
*/
|
|
27840
|
-
boundariesElement: 'viewport'
|
|
27841
|
-
/**
|
|
27842
|
-
* @prop {Boolean} flipVariations=false
|
|
27843
|
-
* The popper will switch placement variation between `-start` and `-end` when
|
|
27844
|
-
* the reference element overlaps its boundaries.
|
|
27845
|
-
*
|
|
27846
|
-
* The original placement should have a set variation.
|
|
27847
|
-
*/
|
|
27848
|
-
flipVariations: false,
|
|
27849
|
-
/**
|
|
27850
|
-
* @prop {Boolean} flipVariationsByContent=false
|
|
27851
|
-
* The popper will switch placement variation between `-start` and `-end` when
|
|
27852
|
-
* the popper element overlaps its reference boundaries.
|
|
27853
|
-
*
|
|
27854
|
-
* The original placement should have a set variation.
|
|
27855
|
-
*/
|
|
27856
|
-
flipVariationsByContent: false
|
|
27821
|
+
boundariesElement: 'viewport'
|
|
27857
27822
|
},
|
|
27858
27823
|
|
|
27859
27824
|
/**
|
|
@@ -28070,8 +28035,8 @@ var Popper = function () {
|
|
|
28070
28035
|
/**
|
|
28071
28036
|
* Creates a new Popper.js instance.
|
|
28072
28037
|
* @class Popper
|
|
28073
|
-
* @param {
|
|
28074
|
-
* @param {
|
|
28038
|
+
* @param {HTMLElement|referenceObject} reference - The reference element used to position the popper
|
|
28039
|
+
* @param {HTMLElement} popper - The HTML element used as the popper
|
|
28075
28040
|
* @param {Object} options - Your custom options to override the ones defined in [Defaults](#defaults)
|
|
28076
28041
|
* @return {Object} instance - The generated Popper.js instance
|
|
28077
28042
|
*/
|
|
@@ -45413,12 +45378,12 @@ var time_component = normalizeComponent(
|
|
|
45413
45378
|
)
|
|
45414
45379
|
|
|
45415
45380
|
/* harmony default export */ var picker_time = (time_component.exports);
|
|
45416
|
-
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/datepicker/base/year-table.vue?vue&type=template&id=
|
|
45417
|
-
var
|
|
45418
|
-
var
|
|
45381
|
+
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/datepicker/base/year-table.vue?vue&type=template&id=4e42f730&
|
|
45382
|
+
var year_tablevue_type_template_id_4e42f730_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{class:(_vm.prefixCls + "-year-table-box")},[_c('table',{class:(_vm.prefixCls + "-table " + _vm.prefixCls + "-year-table"),on:{"click":_vm.handleYearTableClick}},[_c('tbody',[_c('tr',[_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 0)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 1)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 1))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 2)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 2))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 3)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 3))])])])]),_vm._v(" "),_c('tr',[_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 4)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 4))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 5)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 5))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 6)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 6))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 7)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 7))])])])]),_vm._v(" "),_c('tr',[_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 8)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 8))])])]),_vm._v(" "),_c('td',{staticClass:"available year-td",class:_vm.getCellStyle(_vm.startYear + 9)},[_c('div',[_c('a',{staticClass:"cell"},[_vm._v(_vm._s(_vm.startYear + 9))])])]),_vm._v(" "),_c('td'),_vm._v(" "),_c('td')])])])])}
|
|
45383
|
+
var year_tablevue_type_template_id_4e42f730_staticRenderFns = []
|
|
45419
45384
|
|
|
45420
45385
|
|
|
45421
|
-
// CONCATENATED MODULE: ./components/datepicker/base/year-table.vue?vue&type=template&id=
|
|
45386
|
+
// CONCATENATED MODULE: ./components/datepicker/base/year-table.vue?vue&type=template&id=4e42f730&
|
|
45422
45387
|
|
|
45423
45388
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib?cacheDirectory=true!./node_modules/vue-loader/lib??vue-loader-options!./components/datepicker/base/year-table.vue?vue&type=script&lang=js&
|
|
45424
45389
|
//
|
|
@@ -45541,8 +45506,10 @@ var year_tablevue_type_script_lang_js_datesInYear = function datesInYear(year) {
|
|
|
45541
45506
|
},
|
|
45542
45507
|
handleYearTableClick: function handleYearTableClick(event) {
|
|
45543
45508
|
var target = event.target;
|
|
45509
|
+
|
|
45544
45510
|
if (target.tagName === 'A') {
|
|
45545
|
-
|
|
45511
|
+
target = target.parentNode.parentNode;
|
|
45512
|
+
if (hasClass(target, 'disabled')) return;
|
|
45546
45513
|
var year = target.textContent || target.innerText;
|
|
45547
45514
|
this.$emit('pick', Number(year));
|
|
45548
45515
|
}
|
|
@@ -45561,8 +45528,8 @@ var year_tablevue_type_script_lang_js_datesInYear = function datesInYear(year) {
|
|
|
45561
45528
|
|
|
45562
45529
|
var year_table_component = normalizeComponent(
|
|
45563
45530
|
base_year_tablevue_type_script_lang_js_,
|
|
45564
|
-
|
|
45565
|
-
|
|
45531
|
+
year_tablevue_type_template_id_4e42f730_render,
|
|
45532
|
+
year_tablevue_type_template_id_4e42f730_staticRenderFns,
|
|
45566
45533
|
false,
|
|
45567
45534
|
null,
|
|
45568
45535
|
null,
|
|
@@ -51888,8 +51855,8 @@ var pagination_style = __webpack_require__(410);
|
|
|
51888
51855
|
// style dependencies
|
|
51889
51856
|
// import '../../select/style'
|
|
51890
51857
|
|
|
51891
|
-
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/pagination/pagination.vue?vue&type=template&id=
|
|
51892
|
-
var
|
|
51858
|
+
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/pagination/pagination.vue?vue&type=template&id=59b1b122&
|
|
51859
|
+
var paginationvue_type_template_id_59b1b122_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('ul',{class:[
|
|
51893
51860
|
_vm.simple ? (_vm.prefixCls + "-simple") : ("" + _vm.prefixCls),
|
|
51894
51861
|
_vm.disabled ? (_vm.prefixCls + "-disabled") : ("" + _vm.prefixCls),
|
|
51895
51862
|
_vm.mini ? "mini" : ''
|
|
@@ -51902,16 +51869,16 @@ var paginationvue_type_template_id_5ab300bc_render = function () {var _vm=this;v
|
|
|
51902
51869
|
_vm.pageRange.length &&
|
|
51903
51870
|
_vm.pageRange[_vm.pageRange.length - 1] !== _vm.calculatePage &&
|
|
51904
51871
|
!_vm.simple
|
|
51905
|
-
)?_c('li',{class:(_vm.prefixCls + "-item"),attrs:{"tabIndex":"0"},on:{"click":function($event){return _vm.handleChange(_vm.calculatePage)}}},[_c('a',[_vm._v(_vm._s(_vm.calculatePage))])]):_vm._e(),_vm._v(" "),_c('li',{class:("" + (_vm.hasNext ? '' : (_vm.prefixCls + "-disabled ")) + _vm.prefixCls + "-next"),attrs:{"tabIndex":"0","aria-disabled":!_vm.hasNext},on:{"click":_vm.next,"keydown":_vm.runIfEnterNext}},[_vm._t("next",[_c('mds-icon',{staticClass:"mds-pagination-item-link",attrs:{"type":"line-caret-right"}})])],2),_vm._v(" "),(_vm.showQuickJumper || _vm.showJumper)?_c('mds-page-option',{on:{"jump-to":_vm.handleQuickJump}}):_vm._e(),_vm._v(" "),(!_vm.simple && _vm.showPageNumber && !_vm.mini)?_c('li',{class:(_vm.prefixCls + "-more")},[_vm._v("\n 共 "),_c('b',[_vm._v(_vm._s(_vm.calculatePage))]),_vm._v(" 页\n ")]):_vm._e(),_vm._v(" "),(!_vm.simple && _vm.showPageSize && !_vm.mini && _vm.pageSizesSeat==='right')?_c('change-page',{attrs:{"pageSizes":_vm.pageSizes,"pageSizeNum":_vm.pageSizeNum},on:{"changePageSize":_vm.changePageSize}}):_vm._e(),_vm._v(" "),(
|
|
51872
|
+
)?_c('li',{class:(_vm.prefixCls + "-item"),attrs:{"tabIndex":"0"},on:{"click":function($event){return _vm.handleChange(_vm.calculatePage)}}},[_c('a',[_vm._v(_vm._s(_vm.calculatePage))])]):_vm._e(),_vm._v(" "),_c('li',{class:("" + (_vm.hasNext ? '' : (_vm.prefixCls + "-disabled ")) + _vm.prefixCls + "-next"),attrs:{"tabIndex":"0","aria-disabled":!_vm.hasNext},on:{"click":_vm.next,"keydown":_vm.runIfEnterNext}},[_vm._t("next",[_c('mds-icon',{staticClass:"mds-pagination-item-link",attrs:{"type":"line-caret-right"}})])],2),_vm._v(" "),(_vm.showQuickJumper || _vm.showJumper)?_c('mds-page-option',{attrs:{"current-page":_vm.currentPage,"calculate-page":_vm.calculatePage},on:{"jump-to":_vm.handleQuickJump}}):_vm._e(),_vm._v(" "),(!_vm.simple && _vm.showPageNumber && !_vm.mini)?_c('li',{class:(_vm.prefixCls + "-more")},[_vm._v("\n 共 "),_c('b',[_vm._v(_vm._s(_vm.calculatePage))]),_vm._v(" 页\n ")]):_vm._e(),_vm._v(" "),(!_vm.simple && _vm.showPageSize && !_vm.mini && _vm.pageSizesSeat==='right')?_c('change-page',{attrs:{"pageSizes":_vm.pageSizes,"pageSizeNum":_vm.pageSizeNum},on:{"changePageSize":_vm.changePageSize}}):_vm._e(),_vm._v(" "),(
|
|
51906
51873
|
!_vm.simple &&
|
|
51907
51874
|
(_vm.showTotalString || _vm.showTotalSize) &&
|
|
51908
51875
|
!_vm.mini &&
|
|
51909
51876
|
_vm.totalSeat === 'right'
|
|
51910
51877
|
)?_c('li',{staticClass:"total-seat-right",class:(_vm.prefixCls + "-total")},[_vm._v("\n 共 "),_c('b',[_vm._v(_vm._s(_vm.total))]),_vm._v(" 条\n ")]):_vm._e()],2)}
|
|
51911
|
-
var
|
|
51878
|
+
var paginationvue_type_template_id_59b1b122_staticRenderFns = []
|
|
51912
51879
|
|
|
51913
51880
|
|
|
51914
|
-
// CONCATENATED MODULE: ./components/pagination/pagination.vue?vue&type=template&id=
|
|
51881
|
+
// CONCATENATED MODULE: ./components/pagination/pagination.vue?vue&type=template&id=59b1b122&
|
|
51915
51882
|
|
|
51916
51883
|
// CONCATENATED MODULE: ./components/pagination/locale/zh_CN.js
|
|
51917
51884
|
/* harmony default export */ var locale_zh_CN = ({
|
|
@@ -51929,12 +51896,12 @@ var paginationvue_type_template_id_5ab300bc_staticRenderFns = []
|
|
|
51929
51896
|
prev_3: '向前 3 页',
|
|
51930
51897
|
next_3: '向后 3 页'
|
|
51931
51898
|
});
|
|
51932
|
-
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/pagination/option.vue?vue&type=template&id=
|
|
51933
|
-
var
|
|
51934
|
-
var
|
|
51899
|
+
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/pagination/option.vue?vue&type=template&id=6fe1a610&
|
|
51900
|
+
var optionvue_type_template_id_6fe1a610_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('li',{class:("" + _vm.prefixCls)},[_c('div',{class:(_vm.prefixCls + "-quick-jumper")},[_vm._v("\n "+_vm._s(_vm.locale.jump_to)+"\n "),_c('mds-input',{attrs:{"type":"text"},on:{"press-enter":_vm.handleJump,"blur":_vm.blurJump},model:{value:(_vm.pageText),callback:function ($$v) {_vm.pageText=$$v},expression:"pageText"}}),_vm._v("\n "+_vm._s(_vm.locale.page)+"\n ")],1)])}
|
|
51901
|
+
var optionvue_type_template_id_6fe1a610_staticRenderFns = []
|
|
51935
51902
|
|
|
51936
51903
|
|
|
51937
|
-
// CONCATENATED MODULE: ./components/pagination/option.vue?vue&type=template&id=
|
|
51904
|
+
// CONCATENATED MODULE: ./components/pagination/option.vue?vue&type=template&id=6fe1a610&
|
|
51938
51905
|
|
|
51939
51906
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib?cacheDirectory=true!./node_modules/vue-loader/lib??vue-loader-options!./components/pagination/option.vue?vue&type=script&lang=js&
|
|
51940
51907
|
//
|
|
@@ -51954,6 +51921,14 @@ var optionvue_type_template_id_2526109e_staticRenderFns = []
|
|
|
51954
51921
|
/* harmony default export */ var pagination_optionvue_type_script_lang_js_ = ({
|
|
51955
51922
|
name: 'MdsPaginationOption',
|
|
51956
51923
|
props: {
|
|
51924
|
+
calculatePage: {
|
|
51925
|
+
type: Number,
|
|
51926
|
+
default: 1
|
|
51927
|
+
},
|
|
51928
|
+
currentPage: {
|
|
51929
|
+
type: Number,
|
|
51930
|
+
default: 1
|
|
51931
|
+
},
|
|
51957
51932
|
prefixCls: {
|
|
51958
51933
|
type: String,
|
|
51959
51934
|
default: 'mds-pagination-options'
|
|
@@ -51962,29 +51937,37 @@ var optionvue_type_template_id_2526109e_staticRenderFns = []
|
|
|
51962
51937
|
data: function data() {
|
|
51963
51938
|
return {
|
|
51964
51939
|
locale: locale_zh_CN,
|
|
51965
|
-
pageText:
|
|
51940
|
+
pageText: this.currentPage
|
|
51966
51941
|
};
|
|
51967
51942
|
},
|
|
51968
51943
|
|
|
51969
51944
|
methods: {
|
|
51945
|
+
handlPage: function handlPage() {
|
|
51946
|
+
var jumpPage = parseInt(this.pageText || 1, 10);
|
|
51947
|
+
return jumpPage > this.calculatePage ? this.calculatePage : jumpPage;
|
|
51948
|
+
},
|
|
51970
51949
|
handleJump: function handleJump(event) {
|
|
51971
51950
|
if (this.disabled) {
|
|
51972
51951
|
return;
|
|
51973
51952
|
}
|
|
51974
|
-
(event.key === 'Enter' || event.charCode === 13) && this.$emit('jump-to', this.
|
|
51975
|
-
this.pageText =
|
|
51953
|
+
(event.key === 'Enter' || event.charCode === 13) && this.$emit('jump-to', this.handlPage());
|
|
51954
|
+
this.pageText = this.handlPage();
|
|
51976
51955
|
},
|
|
51977
|
-
|
|
51978
|
-
if (this.disabled
|
|
51956
|
+
blurJump: function blurJump() {
|
|
51957
|
+
if (this.disabled) {
|
|
51979
51958
|
return false;
|
|
51980
|
-
} else {
|
|
51981
|
-
this.$emit('jump-to', this.pageText);
|
|
51982
|
-
this.pageText = '';
|
|
51983
51959
|
}
|
|
51960
|
+
this.$emit('jump-to', this.handlPage());
|
|
51961
|
+
this.pageText = this.handlPage();
|
|
51984
51962
|
}
|
|
51985
51963
|
},
|
|
51986
51964
|
components: {
|
|
51987
51965
|
MdsInput: components_input
|
|
51966
|
+
},
|
|
51967
|
+
watch: {
|
|
51968
|
+
current: function current() {
|
|
51969
|
+
this.pageText = this.currentPage;
|
|
51970
|
+
}
|
|
51988
51971
|
}
|
|
51989
51972
|
});
|
|
51990
51973
|
// CONCATENATED MODULE: ./components/pagination/option.vue?vue&type=script&lang=js&
|
|
@@ -51999,8 +51982,8 @@ var optionvue_type_template_id_2526109e_staticRenderFns = []
|
|
|
51999
51982
|
|
|
52000
51983
|
var pagination_option_component = normalizeComponent(
|
|
52001
51984
|
components_pagination_optionvue_type_script_lang_js_,
|
|
52002
|
-
|
|
52003
|
-
|
|
51985
|
+
optionvue_type_template_id_6fe1a610_render,
|
|
51986
|
+
optionvue_type_template_id_6fe1a610_staticRenderFns,
|
|
52004
51987
|
false,
|
|
52005
51988
|
null,
|
|
52006
51989
|
null,
|
|
@@ -52245,6 +52228,8 @@ var changePage_component = normalizeComponent(
|
|
|
52245
52228
|
//
|
|
52246
52229
|
//
|
|
52247
52230
|
//
|
|
52231
|
+
//
|
|
52232
|
+
//
|
|
52248
52233
|
|
|
52249
52234
|
|
|
52250
52235
|
|
|
@@ -52434,18 +52419,19 @@ var changePage_component = normalizeComponent(
|
|
|
52434
52419
|
}
|
|
52435
52420
|
},
|
|
52436
52421
|
handleJump: function handleJump(event) {
|
|
52437
|
-
;(event.key === 'Enter' || event.charCode === 13) && this.handleQuickJump(this.currentPage);
|
|
52422
|
+
;(event.key === 'Enter' || event.charCode === 13) && this.handleQuickJump(this.currentPage || 1);
|
|
52438
52423
|
},
|
|
52439
52424
|
handleQuickJump: function handleQuickJump(newPageText) {
|
|
52440
52425
|
if (this.disabled) {
|
|
52441
52426
|
return;
|
|
52442
52427
|
}
|
|
52443
|
-
var newPage = parseInt(newPageText, 10);
|
|
52428
|
+
var newPage = parseInt(newPageText || 1, 10);
|
|
52444
52429
|
this.currentPage = newPage;
|
|
52445
52430
|
if (isNaN(newPage)) return false;
|
|
52446
52431
|
if (newPage < 1) {
|
|
52447
52432
|
this.handleChange(1);
|
|
52448
52433
|
} else if (newPage > this.calculatePage) {
|
|
52434
|
+
this.currentPage = this.calculatePage;
|
|
52449
52435
|
this.handleChange(this.calculatePage);
|
|
52450
52436
|
} else {
|
|
52451
52437
|
this.handleChange(newPage);
|
|
@@ -52529,8 +52515,8 @@ var changePage_component = normalizeComponent(
|
|
|
52529
52515
|
|
|
52530
52516
|
var pagination_component = normalizeComponent(
|
|
52531
52517
|
pagination_paginationvue_type_script_lang_js_,
|
|
52532
|
-
|
|
52533
|
-
|
|
52518
|
+
paginationvue_type_template_id_59b1b122_render,
|
|
52519
|
+
paginationvue_type_template_id_59b1b122_staticRenderFns,
|
|
52534
52520
|
false,
|
|
52535
52521
|
null,
|
|
52536
52522
|
null,
|
|
@@ -66651,12 +66637,12 @@ var loaders = __webpack_require__(465);
|
|
|
66651
66637
|
|
|
66652
66638
|
|
|
66653
66639
|
|
|
66654
|
-
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/drawer/drawer.vue?vue&type=template&id=
|
|
66655
|
-
var
|
|
66656
|
-
var
|
|
66640
|
+
// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./components/drawer/drawer.vue?vue&type=template&id=6461c5ad&
|
|
66641
|
+
var drawervue_type_template_id_6461c5ad_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.visibility),expression:"visibility"}],ref:"root",class:_vm.contentClasses},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.mask),expression:"mask"}],class:_vm.prefixClsMask,on:{"click":function (e) { return _vm.onMaskClick(e); }}}),_vm._v(" "),_c('div',{class:_vm.prefixClsWrap,attrs:{"role":"document"},on:{"click":function (e) { return _vm.onMaskClick(e); }}},[_c('div',{class:[_vm.prefixCls, _vm.prefixCls + '-' + _vm.position],style:(_vm.isHorizontal ? ("width: " + _vm.size) : ("height: " + _vm.size))},[(_vm.loading)?_c('div',{class:_vm.prefixCls + '-loading',on:{"click":function($event){$event.stopPropagation();}}},[_c('div',{staticClass:"ball-spin-fade-loader"})]):_vm._e(),_vm._v(" "),_c('div',{class:_vm.prefixClsHeader},[_c('div',{class:_vm.prefixClsTitle},[_vm._t("title",[_vm._v(_vm._s(_vm.title))])],2),_vm._v(" "),_c('mds-icon',{directives:[{name:"show",rawName:"v-show",value:(_vm.showClose),expression:"showClose"}],class:_vm.prefixClsClose,attrs:{"type":"line-close"},nativeOn:{"click":function($event){return _vm.handleClose($event)}}})],1),_vm._v(" "),_c('div',{class:_vm.prefixClsBody},[_vm._t("default")],2),_vm._v(" "),(_vm.$slots.footer)?_c('div',{staticClass:"mds-drawer-footer"},[_vm._t("footer")],2):_vm._e()])])])}
|
|
66642
|
+
var drawervue_type_template_id_6461c5ad_staticRenderFns = []
|
|
66657
66643
|
|
|
66658
66644
|
|
|
66659
|
-
// CONCATENATED MODULE: ./components/drawer/drawer.vue?vue&type=template&id=
|
|
66645
|
+
// CONCATENATED MODULE: ./components/drawer/drawer.vue?vue&type=template&id=6461c5ad&
|
|
66660
66646
|
|
|
66661
66647
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib?cacheDirectory=true!./node_modules/vue-loader/lib??vue-loader-options!./components/drawer/drawer.vue?vue&type=script&lang=js&
|
|
66662
66648
|
//
|
|
@@ -66786,7 +66772,7 @@ var drawervue_type_script_lang_js_PREFIXCLS = 'mds-drawer';
|
|
|
66786
66772
|
visibility: function visibility(val) {
|
|
66787
66773
|
var _this = this;
|
|
66788
66774
|
|
|
66789
|
-
if (val) {
|
|
66775
|
+
if (val && this.closed === true) {
|
|
66790
66776
|
this.closed = false;
|
|
66791
66777
|
this.$emit('open');
|
|
66792
66778
|
if (this.appendToBody) {
|
|
@@ -66797,8 +66783,10 @@ var drawervue_type_script_lang_js_PREFIXCLS = 'mds-drawer';
|
|
|
66797
66783
|
if (this.preFocus) {
|
|
66798
66784
|
this.prevActiveElement = document.activeElement;
|
|
66799
66785
|
}
|
|
66800
|
-
} else {
|
|
66801
|
-
if (!this.closed)
|
|
66786
|
+
} else if (!val) {
|
|
66787
|
+
if (!this.closed) {
|
|
66788
|
+
this.handleClose();
|
|
66789
|
+
}
|
|
66802
66790
|
this.move();
|
|
66803
66791
|
if (this.prevActiveElement) {
|
|
66804
66792
|
this.$nextTick(function () {
|
|
@@ -66819,9 +66807,11 @@ var drawervue_type_script_lang_js_PREFIXCLS = 'mds-drawer';
|
|
|
66819
66807
|
methods: {
|
|
66820
66808
|
hide: function hide(cancel) {
|
|
66821
66809
|
if (cancel !== false) {
|
|
66822
|
-
this.$emit('update:visibility', false);
|
|
66810
|
+
this.visibility && this.$emit('update:visibility', false);
|
|
66823
66811
|
this.$emit('close');
|
|
66824
66812
|
this.closed = true;
|
|
66813
|
+
} else {
|
|
66814
|
+
this.$emit('update:visibility', true);
|
|
66825
66815
|
}
|
|
66826
66816
|
},
|
|
66827
66817
|
handleClose: function handleClose() {
|
|
@@ -66881,8 +66871,8 @@ var drawervue_type_script_lang_js_PREFIXCLS = 'mds-drawer';
|
|
|
66881
66871
|
|
|
66882
66872
|
var drawer_component = normalizeComponent(
|
|
66883
66873
|
drawer_drawervue_type_script_lang_js_,
|
|
66884
|
-
|
|
66885
|
-
|
|
66874
|
+
drawervue_type_template_id_6461c5ad_render,
|
|
66875
|
+
drawervue_type_template_id_6461c5ad_staticRenderFns,
|
|
66886
66876
|
false,
|
|
66887
66877
|
null,
|
|
66888
66878
|
null,
|
package/dist/pagination.js
CHANGED
|
@@ -460,7 +460,13 @@ var render = function () {
|
|
|
460
460
|
2
|
|
461
461
|
),
|
|
462
462
|
_vm.showQuickJumper || _vm.showJumper
|
|
463
|
-
? _c("mds-page-option", {
|
|
463
|
+
? _c("mds-page-option", {
|
|
464
|
+
attrs: {
|
|
465
|
+
"current-page": _vm.currentPage,
|
|
466
|
+
"calculate-page": _vm.calculatePage,
|
|
467
|
+
},
|
|
468
|
+
on: { "jump-to": _vm.handleQuickJump },
|
|
469
|
+
})
|
|
464
470
|
: _vm._e(),
|
|
465
471
|
!_vm.simple && _vm.showPageNumber && !_vm.mini
|
|
466
472
|
? _c("li", { class: _vm.prefixCls + "-more" }, [
|
|
@@ -538,7 +544,7 @@ var optionvue_type_template_id_1ad093df_render = function () {
|
|
|
538
544
|
_vm._v("\n " + _vm._s(_vm.locale.jump_to) + "\n "),
|
|
539
545
|
_c("mds-input", {
|
|
540
546
|
attrs: { type: "text" },
|
|
541
|
-
on: { "press-enter": _vm.handleJump, blur: _vm.
|
|
547
|
+
on: { "press-enter": _vm.handleJump, blur: _vm.blurJump },
|
|
542
548
|
model: {
|
|
543
549
|
value: _vm.pageText,
|
|
544
550
|
callback: function ($$v) {
|
|
@@ -581,6 +587,14 @@ var external_input_default = /*#__PURE__*/__webpack_require__.n(external_input_)
|
|
|
581
587
|
/* harmony default export */ var optionvue_type_script_lang_js_ = ({
|
|
582
588
|
name: 'MdsPaginationOption',
|
|
583
589
|
props: {
|
|
590
|
+
calculatePage: {
|
|
591
|
+
type: Number,
|
|
592
|
+
default: 1
|
|
593
|
+
},
|
|
594
|
+
currentPage: {
|
|
595
|
+
type: Number,
|
|
596
|
+
default: 1
|
|
597
|
+
},
|
|
584
598
|
prefixCls: {
|
|
585
599
|
type: String,
|
|
586
600
|
default: 'mds-pagination-options'
|
|
@@ -589,29 +603,37 @@ var external_input_default = /*#__PURE__*/__webpack_require__.n(external_input_)
|
|
|
589
603
|
data: function data() {
|
|
590
604
|
return {
|
|
591
605
|
locale: zh_CN,
|
|
592
|
-
pageText:
|
|
606
|
+
pageText: this.currentPage
|
|
593
607
|
};
|
|
594
608
|
},
|
|
595
609
|
|
|
596
610
|
methods: {
|
|
611
|
+
handlPage: function handlPage() {
|
|
612
|
+
var jumpPage = parseInt(this.pageText || 1, 10);
|
|
613
|
+
return jumpPage > this.calculatePage ? this.calculatePage : jumpPage;
|
|
614
|
+
},
|
|
597
615
|
handleJump: function handleJump(event) {
|
|
598
616
|
if (this.disabled) {
|
|
599
617
|
return;
|
|
600
618
|
}
|
|
601
|
-
(event.key === 'Enter' || event.charCode === 13) && this.$emit('jump-to', this.
|
|
602
|
-
this.pageText =
|
|
619
|
+
(event.key === 'Enter' || event.charCode === 13) && this.$emit('jump-to', this.handlPage());
|
|
620
|
+
this.pageText = this.handlPage();
|
|
603
621
|
},
|
|
604
|
-
|
|
605
|
-
if (this.disabled
|
|
622
|
+
blurJump: function blurJump() {
|
|
623
|
+
if (this.disabled) {
|
|
606
624
|
return false;
|
|
607
|
-
} else {
|
|
608
|
-
this.$emit('jump-to', this.pageText);
|
|
609
|
-
this.pageText = '';
|
|
610
625
|
}
|
|
626
|
+
this.$emit('jump-to', this.handlPage());
|
|
627
|
+
this.pageText = this.handlPage();
|
|
611
628
|
}
|
|
612
629
|
},
|
|
613
630
|
components: {
|
|
614
631
|
MdsInput: external_input_default.a
|
|
632
|
+
},
|
|
633
|
+
watch: {
|
|
634
|
+
current: function current() {
|
|
635
|
+
this.pageText = this.currentPage;
|
|
636
|
+
}
|
|
615
637
|
}
|
|
616
638
|
});
|
|
617
639
|
// CONCATENATED MODULE: ./components/pagination/option.vue?vue&type=script&lang=js&
|
|
@@ -916,6 +938,8 @@ changePage_component.options.__file = "components/pagination/changePage.vue"
|
|
|
916
938
|
//
|
|
917
939
|
//
|
|
918
940
|
//
|
|
941
|
+
//
|
|
942
|
+
//
|
|
919
943
|
|
|
920
944
|
|
|
921
945
|
|
|
@@ -1105,18 +1129,19 @@ changePage_component.options.__file = "components/pagination/changePage.vue"
|
|
|
1105
1129
|
}
|
|
1106
1130
|
},
|
|
1107
1131
|
handleJump: function handleJump(event) {
|
|
1108
|
-
;(event.key === 'Enter' || event.charCode === 13) && this.handleQuickJump(this.currentPage);
|
|
1132
|
+
;(event.key === 'Enter' || event.charCode === 13) && this.handleQuickJump(this.currentPage || 1);
|
|
1109
1133
|
},
|
|
1110
1134
|
handleQuickJump: function handleQuickJump(newPageText) {
|
|
1111
1135
|
if (this.disabled) {
|
|
1112
1136
|
return;
|
|
1113
1137
|
}
|
|
1114
|
-
var newPage = parseInt(newPageText, 10);
|
|
1138
|
+
var newPage = parseInt(newPageText || 1, 10);
|
|
1115
1139
|
this.currentPage = newPage;
|
|
1116
1140
|
if (isNaN(newPage)) return false;
|
|
1117
1141
|
if (newPage < 1) {
|
|
1118
1142
|
this.handleChange(1);
|
|
1119
1143
|
} else if (newPage > this.calculatePage) {
|
|
1144
|
+
this.currentPage = this.calculatePage;
|
|
1120
1145
|
this.handleChange(this.calculatePage);
|
|
1121
1146
|
} else {
|
|
1122
1147
|
this.handleChange(newPage);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mdsfe/mds-ui",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.10-rc.1",
|
|
4
4
|
"description": "A set of enterprise-class Vue UI components.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
"test": "jest ./components/",
|
|
10
10
|
"test:cov": "jest ./components/ --coverage",
|
|
11
11
|
"lint": "eslint components",
|
|
12
|
+
"lint:fix": "eslint --fix --ext '.js,.vue,.ts' components",
|
|
12
13
|
"clean": "rimraf dist",
|
|
13
14
|
"clean:site": "rimraf site/dist site/components site/docs site/router.js",
|
|
14
15
|
"create:site": "node scripts/generate.js -a",
|