framework7 7.0.0-beta.8 → 7.0.0
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/components/accordion/accordion.lazy.js +1 -1
- package/components/actions/actions-class.js +6 -1
- package/components/actions/actions-rtl.css +1 -1
- package/components/actions/actions.css +1 -1
- package/components/actions/actions.d.ts +2 -0
- package/components/actions/actions.js +11 -2
- package/components/actions/actions.lazy.js +1 -1
- package/components/actions/actions.less +3 -0
- package/components/app/app-class.js +15 -9
- package/components/area-chart/area-chart-class.js +34 -18
- package/components/area-chart/area-chart.lazy.js +1 -1
- package/components/autocomplete/autocomplete-class.js +5 -1
- package/components/autocomplete/autocomplete.lazy.js +1 -1
- package/components/breadcrumbs/breadcrumbs-aurora.less +2 -0
- package/components/breadcrumbs/breadcrumbs-ios.less +2 -0
- package/components/breadcrumbs/breadcrumbs-md.less +2 -0
- package/components/breadcrumbs/breadcrumbs-rtl.css +1 -0
- package/components/breadcrumbs/breadcrumbs-vars.less +36 -0
- package/components/breadcrumbs/breadcrumbs.css +1 -0
- package/components/breadcrumbs/breadcrumbs.d.ts +15 -0
- package/components/breadcrumbs/breadcrumbs.js +13 -0
- package/components/breadcrumbs/breadcrumbs.lazy.js +1 -0
- package/components/breadcrumbs/breadcrumbs.less +100 -0
- package/components/calendar/calendar-class.js +216 -124
- package/components/calendar/calendar-rtl.css +1 -1
- package/components/calendar/calendar-vars.less +6 -10
- package/components/calendar/calendar.css +1 -1
- package/components/calendar/calendar.d.ts +2 -0
- package/components/calendar/calendar.js +6 -1
- package/components/calendar/calendar.lazy.js +1 -1
- package/components/calendar/calendar.less +20 -16
- package/components/card/card.js +23 -3
- package/components/card/card.lazy.js +1 -1
- package/components/color-picker/color-picker-class.js +19 -3
- package/components/color-picker/color-picker.js +5 -1
- package/components/color-picker/color-picker.lazy.js +1 -1
- package/components/data-table/data-table-class.js +5 -1
- package/components/data-table/data-table.lazy.js +1 -1
- package/components/dialog/dialog.js +30 -6
- package/components/dialog/dialog.lazy.js +1 -1
- package/components/fab/fab-rtl.css +1 -1
- package/components/fab/fab.css +1 -1
- package/components/fab/fab.js +15 -3
- package/components/fab/fab.lazy.js +1 -1
- package/components/form/form.lazy.js +1 -1
- package/components/gauge/gauge-class.js +10 -2
- package/components/gauge/gauge.d.ts +2 -2
- package/components/gauge/gauge.lazy.js +1 -1
- package/components/input/input.js +5 -1
- package/components/input/input.lazy.js +1 -1
- package/components/list-index/list-index-class.js +5 -1
- package/components/list-index/list-index.d.ts +1 -1
- package/components/list-index/list-index.lazy.js +1 -1
- package/components/login-screen/login-screen.js +10 -2
- package/components/login-screen/login-screen.lazy.js +1 -1
- package/components/menu/menu.js +10 -2
- package/components/menu/menu.lazy.js +1 -1
- package/components/messagebar/messagebar-class.js +25 -5
- package/components/messagebar/messagebar.lazy.js +1 -1
- package/components/messages/messages-class.js +60 -24
- package/components/messages/messages-rtl.css +1 -1
- package/components/messages/messages.css +1 -1
- package/components/messages/messages.lazy.js +1 -1
- package/components/modal/modal-class.js +10 -0
- package/components/navbar/navbar.js +26 -2
- package/components/notification/notification.d.ts +4 -4
- package/components/panel/panel-class.js +35 -7
- package/components/panel/panel.js +40 -8
- package/components/panel/panel.lazy.js +1 -1
- package/components/photo-browser/photo-browser-class.js +42 -8
- package/components/photo-browser/photo-browser.lazy.js +1 -1
- package/components/picker/picker-class.js +11 -7
- package/components/picker/picker-column.js +34 -270
- package/components/picker/picker-rtl.css +1 -1
- package/components/picker/picker.css +1 -1
- package/components/picker/picker.d.ts +2 -13
- package/components/picker/picker.js +5 -6
- package/components/picker/picker.lazy.js +1 -1
- package/components/picker/picker.less +28 -10
- package/components/pie-chart/pie-chart-class.js +16 -7
- package/components/pie-chart/pie-chart.lazy.js +1 -1
- package/components/popover/popover-class.js +20 -3
- package/components/popover/popover-rtl.css +1 -1
- package/components/popover/popover.css +1 -1
- package/components/popover/popover.d.ts +2 -0
- package/components/popover/popover.js +11 -2
- package/components/popover/popover.lazy.js +1 -1
- package/components/popover/popover.less +3 -0
- package/components/popup/popup-class.js +6 -1
- package/components/popup/popup-rtl.css +1 -1
- package/components/popup/popup.css +1 -1
- package/components/popup/popup.d.ts +4 -0
- package/components/popup/popup.js +11 -2
- package/components/popup/popup.lazy.js +1 -1
- package/components/popup/popup.less +4 -0
- package/components/preloader/preloader-ios.less +3 -0
- package/components/preloader/preloader-rtl.css +1 -1
- package/components/preloader/preloader.css +1 -1
- package/components/preloader/preloader.d.ts +4 -0
- package/components/preloader/preloader.js +10 -2
- package/components/preloader/preloader.lazy.js +1 -1
- package/components/progressbar/progressbar-aurora.less +32 -13
- package/components/progressbar/progressbar-ios.less +19 -7
- package/components/progressbar/progressbar-md.less +64 -28
- package/components/progressbar/progressbar-rtl.css +1 -1
- package/components/progressbar/progressbar.css +1 -1
- package/components/progressbar/progressbar.js +17 -4
- package/components/progressbar/progressbar.lazy.js +1 -1
- package/components/progressbar/progressbar.less +16 -4
- package/components/pull-to-refresh/pull-to-refresh-class.js +5 -1
- package/components/pull-to-refresh/pull-to-refresh.lazy.js +1 -1
- package/components/range/range.d.ts +23 -5
- package/components/range/range.js +10 -2
- package/components/range/range.lazy.js +1 -1
- package/components/searchbar/searchbar-class.js +6 -2
- package/components/searchbar/searchbar.js +20 -4
- package/components/searchbar/searchbar.lazy.js +1 -1
- package/components/sheet/sheet-class.js +21 -2
- package/components/sheet/sheet-rtl.css +1 -1
- package/components/sheet/sheet.css +1 -1
- package/components/sheet/sheet.d.ts +2 -0
- package/components/sheet/sheet.js +11 -2
- package/components/sheet/sheet.lazy.js +1 -1
- package/components/sheet/sheet.less +3 -0
- package/components/smart-select/smart-select-class.js +15 -3
- package/components/smart-select/smart-select.lazy.js +1 -1
- package/components/sortable/sortable.d.ts +5 -1
- package/components/sortable/sortable.js +45 -8
- package/components/sortable/sortable.lazy.js +1 -1
- package/components/statusbar/statusbar.d.ts +9 -9
- package/components/statusbar/statusbar.js +5 -1
- package/components/stepper/stepper.js +10 -2
- package/components/stepper/stepper.lazy.js +1 -1
- package/components/swipeout/swipeout.js +16 -3
- package/components/swipeout/swipeout.lazy.js +1 -1
- package/components/swiper/swiper-rtl.css +1 -1
- package/components/swiper/swiper.css +1 -1
- package/components/swiper/swiper.lazy.js +1 -1
- package/components/tabs/tabs.js +14 -7
- package/components/tabs/tabs.lazy.js +1 -1
- package/components/toast/toast.d.ts +2 -2
- package/components/toggle/toggle-class.js +5 -1
- package/components/toggle/toggle.lazy.js +1 -1
- package/components/toolbar/toolbar-aurora.less +0 -13
- package/components/toolbar/toolbar-md.less +0 -13
- package/components/toolbar/toolbar.js +11 -3
- package/components/toolbar/toolbar.less +13 -0
- package/components/tooltip/tooltip-class.js +5 -1
- package/components/tooltip/tooltip.lazy.js +1 -1
- package/components/touch-ripple/touch-ripple.js +5 -1
- package/components/treeview/treeview.lazy.js +1 -1
- package/components/view/view-class.js +13 -2
- package/components/view/view.d.ts +5 -1
- package/components/view/view.js +2 -0
- package/components/virtual-list/virtual-list-class.js +54 -9
- package/components/virtual-list/virtual-list.d.ts +2 -2
- package/components/virtual-list/virtual-list.lazy.js +1 -1
- package/framework7-bundle-rtl.css +252 -150
- package/framework7-bundle-rtl.min.css +4 -4
- package/framework7-bundle.css +237 -134
- package/framework7-bundle.esm.js +5 -4
- package/framework7-bundle.js +2661 -1190
- package/framework7-bundle.js.map +1 -1
- package/framework7-bundle.less +4 -3
- package/framework7-bundle.min.css +4 -4
- package/framework7-bundle.min.js +4 -4
- package/framework7-bundle.min.js.map +1 -1
- package/framework7-lite-bundle.esm.js +5 -4
- package/framework7-lite.esm.js +3 -3
- package/framework7-rtl.css +12 -21
- package/framework7-rtl.min.css +4 -4
- package/framework7-types.d.ts +5 -1
- package/framework7.css +11 -19
- package/framework7.d.ts +4 -0
- package/framework7.esm.js +3 -3
- package/framework7.js +609 -189
- package/framework7.js.map +1 -1
- package/framework7.less +3 -3
- package/framework7.min.css +4 -4
- package/framework7.min.js +4 -4
- package/framework7.min.js.map +1 -1
- package/modules/component/$h.js +5 -1
- package/modules/component/$jsx.js +5 -1
- package/modules/component/component-class.js +35 -22
- package/modules/component/component.d.ts +2 -2
- package/modules/component/component.js +7 -6
- package/modules/component/eventslisteners.js +5 -1
- package/modules/component/snabbdom/h.js +1 -1
- package/modules/component/vdom.js +32 -17
- package/modules/device/device.js +1 -1
- package/modules/router/back.js +16 -6
- package/modules/router/component-loader.js +34 -23
- package/modules/router/modal.js +5 -1
- package/modules/router/navigate.js +19 -3
- package/modules/router/redirect.js +5 -1
- package/modules/router/router-class.js +39 -10
- package/modules/router/swipe-back.js +7 -6
- package/modules/router/tab.js +6 -2
- package/modules/store/create-store.js +10 -2
- package/package.json +12 -6
- package/shared/$jsx.js +6 -1
- package/shared/class.js +33 -5
- package/shared/constructor-methods.js +25 -4
- package/shared/events-class.js +15 -3
- package/shared/get-device.d.ts +0 -2
- package/shared/get-device.js +10 -6
- package/shared/modal-methods.js +10 -2
- package/shared/request.js +45 -7
- package/shared/utils.js +47 -10
package/framework7.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Framework7 7.0.0
|
|
2
|
+
* Framework7 7.0.0
|
|
3
3
|
* Full featured mobile HTML framework for building iOS & Android apps
|
|
4
4
|
* https://framework7.io/
|
|
5
5
|
*
|
|
6
|
-
* Copyright 2014-
|
|
6
|
+
* Copyright 2014-2022 Vladimir Kharlampidi
|
|
7
7
|
*
|
|
8
8
|
* Released under the MIT License
|
|
9
9
|
*
|
|
10
|
-
* Released on:
|
|
10
|
+
* Released on: April 15, 2022
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
(function (global, factory) {
|
|
14
14
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
15
15
|
typeof define === 'function' && define.amd ? define(factory) :
|
|
16
16
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Framework7 = factory());
|
|
17
|
-
}(this, (function () { 'use strict';
|
|
17
|
+
})(this, (function () { 'use strict';
|
|
18
18
|
|
|
19
19
|
/**
|
|
20
|
-
* SSR Window 4.0.
|
|
20
|
+
* SSR Window 4.0.2
|
|
21
21
|
* Better handling for window object in SSR environment
|
|
22
22
|
* https://github.com/nolimits4web/ssr-window
|
|
23
23
|
*
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
*
|
|
26
26
|
* Licensed under MIT
|
|
27
27
|
*
|
|
28
|
-
* Released on:
|
|
28
|
+
* Released on: December 13, 2021
|
|
29
29
|
*/
|
|
30
30
|
|
|
31
31
|
/* eslint-disable no-param-reassign */
|
|
@@ -33,7 +33,15 @@
|
|
|
33
33
|
return obj !== null && typeof obj === 'object' && 'constructor' in obj && obj.constructor === Object;
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
function extend$1(target
|
|
36
|
+
function extend$1(target, src) {
|
|
37
|
+
if (target === void 0) {
|
|
38
|
+
target = {};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
if (src === void 0) {
|
|
42
|
+
src = {};
|
|
43
|
+
}
|
|
44
|
+
|
|
37
45
|
Object.keys(src).forEach(key => {
|
|
38
46
|
if (typeof target[key] === 'undefined') target[key] = src[key];else if (isObject$1(src[key]) && isObject$1(target[key]) && Object.keys(src[key]).length > 0) {
|
|
39
47
|
extend$1(target[key], src[key]);
|
|
@@ -196,15 +204,15 @@
|
|
|
196
204
|
}
|
|
197
205
|
|
|
198
206
|
/**
|
|
199
|
-
* Dom7 4.0.
|
|
207
|
+
* Dom7 4.0.4
|
|
200
208
|
* Minimalistic JavaScript library for DOM manipulation, with a jQuery-compatible API
|
|
201
209
|
* https://framework7.io/docs/dom7.html
|
|
202
210
|
*
|
|
203
|
-
* Copyright
|
|
211
|
+
* Copyright 2022, Vladimir Kharlampidi
|
|
204
212
|
*
|
|
205
213
|
* Licensed under MIT
|
|
206
214
|
*
|
|
207
|
-
* Released on:
|
|
215
|
+
* Released on: January 11, 2022
|
|
208
216
|
*/
|
|
209
217
|
/* eslint-disable no-proto */
|
|
210
218
|
|
|
@@ -224,13 +232,21 @@
|
|
|
224
232
|
|
|
225
233
|
class Dom7 extends Array {
|
|
226
234
|
constructor(items) {
|
|
227
|
-
|
|
228
|
-
|
|
235
|
+
if (typeof items === 'number') {
|
|
236
|
+
super(items);
|
|
237
|
+
} else {
|
|
238
|
+
super(...(items || []));
|
|
239
|
+
makeReactive(this);
|
|
240
|
+
}
|
|
229
241
|
}
|
|
230
242
|
|
|
231
243
|
}
|
|
232
244
|
|
|
233
|
-
function arrayFlat(arr
|
|
245
|
+
function arrayFlat(arr) {
|
|
246
|
+
if (arr === void 0) {
|
|
247
|
+
arr = [];
|
|
248
|
+
}
|
|
249
|
+
|
|
234
250
|
const res = [];
|
|
235
251
|
arr.forEach(el => {
|
|
236
252
|
if (Array.isArray(el)) {
|
|
@@ -321,7 +337,11 @@
|
|
|
321
337
|
|
|
322
338
|
$$1.fn = Dom7.prototype; // eslint-disable-next-line
|
|
323
339
|
|
|
324
|
-
function addClass(
|
|
340
|
+
function addClass() {
|
|
341
|
+
for (var _len = arguments.length, classes = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
342
|
+
classes[_key] = arguments[_key];
|
|
343
|
+
}
|
|
344
|
+
|
|
325
345
|
const classNames = arrayFlat(classes.map(c => c.split(' ')));
|
|
326
346
|
this.forEach(el => {
|
|
327
347
|
el.classList.add(...classNames);
|
|
@@ -329,7 +349,11 @@
|
|
|
329
349
|
return this;
|
|
330
350
|
}
|
|
331
351
|
|
|
332
|
-
function removeClass(
|
|
352
|
+
function removeClass() {
|
|
353
|
+
for (var _len2 = arguments.length, classes = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
354
|
+
classes[_key2] = arguments[_key2];
|
|
355
|
+
}
|
|
356
|
+
|
|
333
357
|
const classNames = arrayFlat(classes.map(c => c.split(' ')));
|
|
334
358
|
this.forEach(el => {
|
|
335
359
|
el.classList.remove(...classNames);
|
|
@@ -337,7 +361,11 @@
|
|
|
337
361
|
return this;
|
|
338
362
|
}
|
|
339
363
|
|
|
340
|
-
function toggleClass(
|
|
364
|
+
function toggleClass() {
|
|
365
|
+
for (var _len3 = arguments.length, classes = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
|
366
|
+
classes[_key3] = arguments[_key3];
|
|
367
|
+
}
|
|
368
|
+
|
|
341
369
|
const classNames = arrayFlat(classes.map(c => c.split(' ')));
|
|
342
370
|
this.forEach(el => {
|
|
343
371
|
classNames.forEach(className => {
|
|
@@ -346,7 +374,11 @@
|
|
|
346
374
|
});
|
|
347
375
|
}
|
|
348
376
|
|
|
349
|
-
function hasClass(
|
|
377
|
+
function hasClass() {
|
|
378
|
+
for (var _len4 = arguments.length, classes = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
379
|
+
classes[_key4] = arguments[_key4];
|
|
380
|
+
}
|
|
381
|
+
|
|
350
382
|
const classNames = arrayFlat(classes.map(c => c.split(' ')));
|
|
351
383
|
return arrayFilter(this, el => {
|
|
352
384
|
return classNames.filter(className => el.classList.contains(className)).length > 0;
|
|
@@ -531,7 +563,11 @@
|
|
|
531
563
|
return this;
|
|
532
564
|
}
|
|
533
565
|
|
|
534
|
-
function on(
|
|
566
|
+
function on() {
|
|
567
|
+
for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
|
|
568
|
+
args[_key5] = arguments[_key5];
|
|
569
|
+
}
|
|
570
|
+
|
|
535
571
|
let [eventType, targetSelector, listener, capture] = args;
|
|
536
572
|
|
|
537
573
|
if (typeof args[1] === 'function') {
|
|
@@ -604,7 +640,11 @@
|
|
|
604
640
|
return this;
|
|
605
641
|
}
|
|
606
642
|
|
|
607
|
-
function off(
|
|
643
|
+
function off() {
|
|
644
|
+
for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
|
|
645
|
+
args[_key6] = arguments[_key6];
|
|
646
|
+
}
|
|
647
|
+
|
|
608
648
|
let [eventType, targetSelector, listener, capture] = args;
|
|
609
649
|
|
|
610
650
|
if (typeof args[1] === 'function') {
|
|
@@ -650,8 +690,13 @@
|
|
|
650
690
|
return this;
|
|
651
691
|
}
|
|
652
692
|
|
|
653
|
-
function once(
|
|
693
|
+
function once() {
|
|
654
694
|
const dom = this;
|
|
695
|
+
|
|
696
|
+
for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) {
|
|
697
|
+
args[_key7] = arguments[_key7];
|
|
698
|
+
}
|
|
699
|
+
|
|
655
700
|
let [eventName, targetSelector, listener, capture] = args;
|
|
656
701
|
|
|
657
702
|
if (typeof args[1] === 'function') {
|
|
@@ -659,7 +704,11 @@
|
|
|
659
704
|
targetSelector = undefined;
|
|
660
705
|
}
|
|
661
706
|
|
|
662
|
-
function onceHandler(
|
|
707
|
+
function onceHandler() {
|
|
708
|
+
for (var _len8 = arguments.length, eventArgs = new Array(_len8), _key8 = 0; _key8 < _len8; _key8++) {
|
|
709
|
+
eventArgs[_key8] = arguments[_key8];
|
|
710
|
+
}
|
|
711
|
+
|
|
663
712
|
listener.apply(this, eventArgs);
|
|
664
713
|
dom.off(eventName, targetSelector, onceHandler, capture);
|
|
665
714
|
|
|
@@ -672,8 +721,13 @@
|
|
|
672
721
|
return dom.on(eventName, targetSelector, onceHandler, capture);
|
|
673
722
|
}
|
|
674
723
|
|
|
675
|
-
function trigger(
|
|
724
|
+
function trigger() {
|
|
676
725
|
const window = getWindow();
|
|
726
|
+
|
|
727
|
+
for (var _len9 = arguments.length, args = new Array(_len9), _key9 = 0; _key9 < _len9; _key9++) {
|
|
728
|
+
args[_key9] = arguments[_key9];
|
|
729
|
+
}
|
|
730
|
+
|
|
677
731
|
const events = args[0].split(' ');
|
|
678
732
|
const eventData = args[1];
|
|
679
733
|
|
|
@@ -984,12 +1038,12 @@
|
|
|
984
1038
|
return $$1([this[index]]);
|
|
985
1039
|
}
|
|
986
1040
|
|
|
987
|
-
function append(
|
|
1041
|
+
function append() {
|
|
988
1042
|
let newChild;
|
|
989
1043
|
const document = getDocument();
|
|
990
1044
|
|
|
991
|
-
for (let k = 0; k <
|
|
992
|
-
newChild =
|
|
1045
|
+
for (let k = 0; k < arguments.length; k += 1) {
|
|
1046
|
+
newChild = k < 0 || arguments.length <= k ? undefined : arguments[k];
|
|
993
1047
|
|
|
994
1048
|
for (let i = 0; i < this.length; i += 1) {
|
|
995
1049
|
if (typeof newChild === 'string') {
|
|
@@ -1243,11 +1297,15 @@
|
|
|
1243
1297
|
return this.remove();
|
|
1244
1298
|
}
|
|
1245
1299
|
|
|
1246
|
-
function add(
|
|
1300
|
+
function add() {
|
|
1247
1301
|
const dom = this;
|
|
1248
1302
|
let i;
|
|
1249
1303
|
let j;
|
|
1250
1304
|
|
|
1305
|
+
for (var _len10 = arguments.length, els = new Array(_len10), _key10 = 0; _key10 < _len10; _key10++) {
|
|
1306
|
+
els[_key10] = arguments[_key10];
|
|
1307
|
+
}
|
|
1308
|
+
|
|
1251
1309
|
for (i = 0; i < els.length; i += 1) {
|
|
1252
1310
|
const toAdd = $$1(els[i]);
|
|
1253
1311
|
|
|
@@ -1278,8 +1336,13 @@
|
|
|
1278
1336
|
} // eslint-disable-next-line
|
|
1279
1337
|
|
|
1280
1338
|
|
|
1281
|
-
function scrollTo(
|
|
1339
|
+
function scrollTo() {
|
|
1282
1340
|
const window = getWindow();
|
|
1341
|
+
|
|
1342
|
+
for (var _len11 = arguments.length, args = new Array(_len11), _key11 = 0; _key11 < _len11; _key11++) {
|
|
1343
|
+
args[_key11] = arguments[_key11];
|
|
1344
|
+
}
|
|
1345
|
+
|
|
1283
1346
|
let [left, top, duration, easing, callback] = args;
|
|
1284
1347
|
|
|
1285
1348
|
if (args.length === 4 && typeof easing === 'function') {
|
|
@@ -1339,7 +1402,11 @@
|
|
|
1339
1402
|
if (animateTop && newTop === currentTop) animateTop = false;
|
|
1340
1403
|
if (animateLeft && newLeft === currentLeft) animateLeft = false;
|
|
1341
1404
|
|
|
1342
|
-
function render(time
|
|
1405
|
+
function render(time) {
|
|
1406
|
+
if (time === void 0) {
|
|
1407
|
+
time = new Date().getTime();
|
|
1408
|
+
}
|
|
1409
|
+
|
|
1343
1410
|
if (startTime === null) {
|
|
1344
1411
|
startTime = time;
|
|
1345
1412
|
}
|
|
@@ -1385,7 +1452,11 @@
|
|
|
1385
1452
|
} // scrollTop(top, duration, easing, callback) {
|
|
1386
1453
|
|
|
1387
1454
|
|
|
1388
|
-
function scrollTop(
|
|
1455
|
+
function scrollTop() {
|
|
1456
|
+
for (var _len12 = arguments.length, args = new Array(_len12), _key12 = 0; _key12 < _len12; _key12++) {
|
|
1457
|
+
args[_key12] = arguments[_key12];
|
|
1458
|
+
}
|
|
1459
|
+
|
|
1389
1460
|
let [top, duration, easing, callback] = args;
|
|
1390
1461
|
|
|
1391
1462
|
if (args.length === 3 && typeof easing === 'function') {
|
|
@@ -1402,7 +1473,11 @@
|
|
|
1402
1473
|
return dom.scrollTo(undefined, top, duration, easing, callback);
|
|
1403
1474
|
}
|
|
1404
1475
|
|
|
1405
|
-
function scrollLeft(
|
|
1476
|
+
function scrollLeft() {
|
|
1477
|
+
for (var _len13 = arguments.length, args = new Array(_len13), _key13 = 0; _key13 < _len13; _key13++) {
|
|
1478
|
+
args[_key13] = arguments[_key13];
|
|
1479
|
+
}
|
|
1480
|
+
|
|
1406
1481
|
let [left, duration, easing, callback] = args;
|
|
1407
1482
|
|
|
1408
1483
|
if (args.length === 3 && typeof easing === 'function') {
|
|
@@ -1626,7 +1701,11 @@
|
|
|
1626
1701
|
const noTrigger = 'resize scroll'.split(' ');
|
|
1627
1702
|
|
|
1628
1703
|
function shortcut(name) {
|
|
1629
|
-
function eventHandler(
|
|
1704
|
+
function eventHandler() {
|
|
1705
|
+
for (var _len14 = arguments.length, args = new Array(_len14), _key14 = 0; _key14 < _len14; _key14++) {
|
|
1706
|
+
args[_key14] = arguments[_key14];
|
|
1707
|
+
}
|
|
1708
|
+
|
|
1630
1709
|
if (typeof args[0] === 'undefined') {
|
|
1631
1710
|
for (let i = 0; i < this.length; i += 1) {
|
|
1632
1711
|
if (noTrigger.indexOf(name) < 0) {
|
|
@@ -1769,7 +1848,15 @@
|
|
|
1769
1848
|
uniqueNum += 1;
|
|
1770
1849
|
return uniqueNum;
|
|
1771
1850
|
}
|
|
1772
|
-
function id(mask
|
|
1851
|
+
function id(mask, map) {
|
|
1852
|
+
if (mask === void 0) {
|
|
1853
|
+
mask = 'xxxxxxxxxx';
|
|
1854
|
+
}
|
|
1855
|
+
|
|
1856
|
+
if (map === void 0) {
|
|
1857
|
+
map = '0123456789abcdef';
|
|
1858
|
+
}
|
|
1859
|
+
|
|
1773
1860
|
const length = map.length;
|
|
1774
1861
|
return mask.replace(/x/g, () => map[Math.floor(Math.random() * length)]);
|
|
1775
1862
|
}
|
|
@@ -1823,7 +1910,11 @@
|
|
|
1823
1910
|
const window = getWindow();
|
|
1824
1911
|
return window.cancelAnimationFrame(frameId);
|
|
1825
1912
|
}
|
|
1826
|
-
function nextTick(callback, delay
|
|
1913
|
+
function nextTick(callback, delay) {
|
|
1914
|
+
if (delay === void 0) {
|
|
1915
|
+
delay = 0;
|
|
1916
|
+
}
|
|
1917
|
+
|
|
1827
1918
|
return setTimeout(callback, delay);
|
|
1828
1919
|
}
|
|
1829
1920
|
function nextFrame$1(callback) {
|
|
@@ -1856,7 +1947,11 @@
|
|
|
1856
1947
|
|
|
1857
1948
|
return query;
|
|
1858
1949
|
}
|
|
1859
|
-
function getTranslate(el, axis
|
|
1950
|
+
function getTranslate(el, axis) {
|
|
1951
|
+
if (axis === void 0) {
|
|
1952
|
+
axis = 'x';
|
|
1953
|
+
}
|
|
1954
|
+
|
|
1860
1955
|
const window = getWindow();
|
|
1861
1956
|
let matrix;
|
|
1862
1957
|
let curTransform;
|
|
@@ -1882,19 +1977,23 @@
|
|
|
1882
1977
|
// Latest Chrome and webkits Fix
|
|
1883
1978
|
if (window.WebKitCSSMatrix) curTransform = transformMatrix.m41; // Crazy IE10 Matrix
|
|
1884
1979
|
else if (matrix.length === 16) curTransform = parseFloat(matrix[12]); // Normal Browsers
|
|
1885
|
-
|
|
1980
|
+
else curTransform = parseFloat(matrix[4]);
|
|
1886
1981
|
}
|
|
1887
1982
|
|
|
1888
1983
|
if (axis === 'y') {
|
|
1889
1984
|
// Latest Chrome and webkits Fix
|
|
1890
1985
|
if (window.WebKitCSSMatrix) curTransform = transformMatrix.m42; // Crazy IE10 Matrix
|
|
1891
1986
|
else if (matrix.length === 16) curTransform = parseFloat(matrix[13]); // Normal Browsers
|
|
1892
|
-
|
|
1987
|
+
else curTransform = parseFloat(matrix[5]);
|
|
1893
1988
|
}
|
|
1894
1989
|
|
|
1895
1990
|
return curTransform || 0;
|
|
1896
1991
|
}
|
|
1897
|
-
function serializeObject(obj, parents
|
|
1992
|
+
function serializeObject(obj, parents) {
|
|
1993
|
+
if (parents === void 0) {
|
|
1994
|
+
parents = [];
|
|
1995
|
+
}
|
|
1996
|
+
|
|
1898
1997
|
if (typeof obj === 'string') return obj;
|
|
1899
1998
|
const resultArray = [];
|
|
1900
1999
|
const separator = '&';
|
|
@@ -1954,7 +2053,11 @@
|
|
|
1954
2053
|
function isObject(o) {
|
|
1955
2054
|
return typeof o === 'object' && o !== null && o.constructor && o.constructor === Object;
|
|
1956
2055
|
}
|
|
1957
|
-
function merge(
|
|
2056
|
+
function merge() {
|
|
2057
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2058
|
+
args[_key] = arguments[_key];
|
|
2059
|
+
}
|
|
2060
|
+
|
|
1958
2061
|
const to = args[0];
|
|
1959
2062
|
args.splice(0, 1);
|
|
1960
2063
|
const from = args;
|
|
@@ -1978,11 +2081,15 @@
|
|
|
1978
2081
|
|
|
1979
2082
|
return to;
|
|
1980
2083
|
}
|
|
1981
|
-
function extend(
|
|
2084
|
+
function extend() {
|
|
1982
2085
|
let deep = true;
|
|
1983
2086
|
let to;
|
|
1984
2087
|
let from;
|
|
1985
2088
|
|
|
2089
|
+
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
2090
|
+
args[_key2] = arguments[_key2];
|
|
2091
|
+
}
|
|
2092
|
+
|
|
1986
2093
|
if (typeof args[0] === 'boolean') {
|
|
1987
2094
|
deep = args[0];
|
|
1988
2095
|
to = args[1];
|
|
@@ -2095,10 +2202,14 @@
|
|
|
2095
2202
|
HSB.s = HSL.l > 0 ? 2 * t / HSB.b : HSB.s;
|
|
2096
2203
|
return [HSB.h, HSB.s, HSB.b];
|
|
2097
2204
|
}
|
|
2098
|
-
function colorThemeCSSProperties(
|
|
2205
|
+
function colorThemeCSSProperties() {
|
|
2099
2206
|
let hex;
|
|
2100
2207
|
let rgb;
|
|
2101
2208
|
|
|
2209
|
+
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
|
2210
|
+
args[_key3] = arguments[_key3];
|
|
2211
|
+
}
|
|
2212
|
+
|
|
2102
2213
|
if (args.length === 1) {
|
|
2103
2214
|
hex = args[0];
|
|
2104
2215
|
rgb = colorHexToRgb(hex);
|
|
@@ -2133,8 +2244,13 @@
|
|
|
2133
2244
|
instance[key] = obj[key];
|
|
2134
2245
|
});
|
|
2135
2246
|
}
|
|
2136
|
-
function flattenArray(
|
|
2247
|
+
function flattenArray() {
|
|
2137
2248
|
const arr = [];
|
|
2249
|
+
|
|
2250
|
+
for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
2251
|
+
args[_key4] = arguments[_key4];
|
|
2252
|
+
}
|
|
2253
|
+
|
|
2138
2254
|
args.forEach(arg => {
|
|
2139
2255
|
if (Array.isArray(arg)) arr.push(...flattenArray(...arg));else arr.push(arg);
|
|
2140
2256
|
});
|
|
@@ -2213,9 +2329,10 @@
|
|
|
2213
2329
|
|
|
2214
2330
|
let deviceCalculated;
|
|
2215
2331
|
|
|
2216
|
-
function calcDevice({
|
|
2217
|
-
|
|
2218
|
-
|
|
2332
|
+
function calcDevice(_temp) {
|
|
2333
|
+
let {
|
|
2334
|
+
userAgent
|
|
2335
|
+
} = _temp === void 0 ? {} : _temp;
|
|
2219
2336
|
const support = getSupport();
|
|
2220
2337
|
const window = getWindow();
|
|
2221
2338
|
const platform = window.navigator.platform;
|
|
@@ -2233,8 +2350,7 @@
|
|
|
2233
2350
|
firefox: false,
|
|
2234
2351
|
macos: false,
|
|
2235
2352
|
windows: false,
|
|
2236
|
-
cordova: !!
|
|
2237
|
-
phonegap: !!(window.cordova || window.phonegap),
|
|
2353
|
+
cordova: !!window.cordova,
|
|
2238
2354
|
electron: false,
|
|
2239
2355
|
capacitor: !!window.Capacitor,
|
|
2240
2356
|
nwjs: false
|
|
@@ -2347,7 +2463,11 @@
|
|
|
2347
2463
|
return device;
|
|
2348
2464
|
}
|
|
2349
2465
|
|
|
2350
|
-
function getDevice(overrides
|
|
2466
|
+
function getDevice(overrides, reset) {
|
|
2467
|
+
if (overrides === void 0) {
|
|
2468
|
+
overrides = {};
|
|
2469
|
+
}
|
|
2470
|
+
|
|
2351
2471
|
if (!deviceCalculated || reset) {
|
|
2352
2472
|
deviceCalculated = calcDevice(overrides);
|
|
2353
2473
|
}
|
|
@@ -2356,7 +2476,11 @@
|
|
|
2356
2476
|
}
|
|
2357
2477
|
|
|
2358
2478
|
class EventsClass {
|
|
2359
|
-
constructor(parents
|
|
2479
|
+
constructor(parents) {
|
|
2480
|
+
if (parents === void 0) {
|
|
2481
|
+
parents = [];
|
|
2482
|
+
}
|
|
2483
|
+
|
|
2360
2484
|
const self = this;
|
|
2361
2485
|
self.eventsParents = parents;
|
|
2362
2486
|
self.eventsListeners = {};
|
|
@@ -2377,13 +2501,17 @@
|
|
|
2377
2501
|
const self = this;
|
|
2378
2502
|
if (typeof handler !== 'function') return self;
|
|
2379
2503
|
|
|
2380
|
-
function onceHandler(
|
|
2504
|
+
function onceHandler() {
|
|
2381
2505
|
self.off(events, onceHandler);
|
|
2382
2506
|
|
|
2383
2507
|
if (onceHandler.f7proxy) {
|
|
2384
2508
|
delete onceHandler.f7proxy;
|
|
2385
2509
|
}
|
|
2386
2510
|
|
|
2511
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2512
|
+
args[_key] = arguments[_key];
|
|
2513
|
+
}
|
|
2514
|
+
|
|
2387
2515
|
handler.apply(self, args);
|
|
2388
2516
|
}
|
|
2389
2517
|
|
|
@@ -2408,7 +2536,7 @@
|
|
|
2408
2536
|
return self;
|
|
2409
2537
|
}
|
|
2410
2538
|
|
|
2411
|
-
emit(
|
|
2539
|
+
emit() {
|
|
2412
2540
|
const self = this;
|
|
2413
2541
|
if (!self.eventsListeners) return self;
|
|
2414
2542
|
let events;
|
|
@@ -2416,6 +2544,10 @@
|
|
|
2416
2544
|
let context;
|
|
2417
2545
|
let eventsParents;
|
|
2418
2546
|
|
|
2547
|
+
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
2548
|
+
args[_key2] = arguments[_key2];
|
|
2549
|
+
}
|
|
2550
|
+
|
|
2419
2551
|
if (typeof args[0] === 'string' || Array.isArray(args[0])) {
|
|
2420
2552
|
events = args[0];
|
|
2421
2553
|
data = args.slice(1, args.length);
|
|
@@ -2455,7 +2587,15 @@
|
|
|
2455
2587
|
}
|
|
2456
2588
|
|
|
2457
2589
|
class Framework7Class extends EventsClass {
|
|
2458
|
-
constructor(params
|
|
2590
|
+
constructor(params, parents) {
|
|
2591
|
+
if (params === void 0) {
|
|
2592
|
+
params = {};
|
|
2593
|
+
}
|
|
2594
|
+
|
|
2595
|
+
if (parents === void 0) {
|
|
2596
|
+
parents = [];
|
|
2597
|
+
}
|
|
2598
|
+
|
|
2459
2599
|
super(parents);
|
|
2460
2600
|
const self = this;
|
|
2461
2601
|
self.params = params;
|
|
@@ -2494,7 +2634,15 @@
|
|
|
2494
2634
|
});
|
|
2495
2635
|
}
|
|
2496
2636
|
|
|
2497
|
-
useModule(moduleName
|
|
2637
|
+
useModule(moduleName, moduleParams) {
|
|
2638
|
+
if (moduleName === void 0) {
|
|
2639
|
+
moduleName = '';
|
|
2640
|
+
}
|
|
2641
|
+
|
|
2642
|
+
if (moduleParams === void 0) {
|
|
2643
|
+
moduleParams = {};
|
|
2644
|
+
}
|
|
2645
|
+
|
|
2498
2646
|
const instance = this;
|
|
2499
2647
|
if (!instance.modules) return;
|
|
2500
2648
|
const module = typeof moduleName === 'string' ? instance.modules[moduleName] : moduleName;
|
|
@@ -2538,7 +2686,11 @@
|
|
|
2538
2686
|
}
|
|
2539
2687
|
}
|
|
2540
2688
|
|
|
2541
|
-
useModules(modulesParams
|
|
2689
|
+
useModules(modulesParams) {
|
|
2690
|
+
if (modulesParams === void 0) {
|
|
2691
|
+
modulesParams = {};
|
|
2692
|
+
}
|
|
2693
|
+
|
|
2542
2694
|
const instance = this;
|
|
2543
2695
|
if (!instance.modules) return;
|
|
2544
2696
|
Object.keys(instance.modules).forEach(moduleName => {
|
|
@@ -2553,7 +2705,7 @@
|
|
|
2553
2705
|
Class.use(components);
|
|
2554
2706
|
}
|
|
2555
2707
|
|
|
2556
|
-
static installModule(module
|
|
2708
|
+
static installModule(module) {
|
|
2557
2709
|
const Class = this;
|
|
2558
2710
|
if (!Class.prototype.modules) Class.prototype.modules = {};
|
|
2559
2711
|
const name = module.name || `${Object.keys(Class.prototype.modules).length}_${now()}`;
|
|
@@ -2574,13 +2726,17 @@
|
|
|
2574
2726
|
|
|
2575
2727
|
|
|
2576
2728
|
if (module.install) {
|
|
2729
|
+
for (var _len = arguments.length, params = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
2730
|
+
params[_key - 1] = arguments[_key];
|
|
2731
|
+
}
|
|
2732
|
+
|
|
2577
2733
|
module.install.apply(Class, params);
|
|
2578
2734
|
}
|
|
2579
2735
|
|
|
2580
2736
|
return Class;
|
|
2581
2737
|
}
|
|
2582
2738
|
|
|
2583
|
-
static use(module
|
|
2739
|
+
static use(module) {
|
|
2584
2740
|
const Class = this;
|
|
2585
2741
|
|
|
2586
2742
|
if (Array.isArray(module)) {
|
|
@@ -2588,12 +2744,20 @@
|
|
|
2588
2744
|
return Class;
|
|
2589
2745
|
}
|
|
2590
2746
|
|
|
2747
|
+
for (var _len2 = arguments.length, params = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
2748
|
+
params[_key2 - 1] = arguments[_key2];
|
|
2749
|
+
}
|
|
2750
|
+
|
|
2591
2751
|
return Class.installModule(module, ...params);
|
|
2592
2752
|
}
|
|
2593
2753
|
|
|
2594
2754
|
}
|
|
2595
2755
|
|
|
2596
|
-
function ConstructorMethods(parameters
|
|
2756
|
+
function ConstructorMethods(parameters) {
|
|
2757
|
+
if (parameters === void 0) {
|
|
2758
|
+
parameters = {};
|
|
2759
|
+
}
|
|
2760
|
+
|
|
2597
2761
|
const {
|
|
2598
2762
|
defaultSelector,
|
|
2599
2763
|
constructor: Constructor,
|
|
@@ -2602,12 +2766,20 @@
|
|
|
2602
2766
|
addMethods
|
|
2603
2767
|
} = parameters;
|
|
2604
2768
|
const methods = {
|
|
2605
|
-
create(
|
|
2769
|
+
create() {
|
|
2770
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2771
|
+
args[_key] = arguments[_key];
|
|
2772
|
+
}
|
|
2773
|
+
|
|
2606
2774
|
if (app) return new Constructor(app, ...args);
|
|
2607
2775
|
return new Constructor(...args);
|
|
2608
2776
|
},
|
|
2609
2777
|
|
|
2610
|
-
get(el
|
|
2778
|
+
get(el) {
|
|
2779
|
+
if (el === void 0) {
|
|
2780
|
+
el = defaultSelector;
|
|
2781
|
+
}
|
|
2782
|
+
|
|
2611
2783
|
if (el instanceof Constructor) return el;
|
|
2612
2784
|
const $el = $(el);
|
|
2613
2785
|
if ($el.length === 0) return undefined;
|
|
@@ -2624,8 +2796,17 @@
|
|
|
2624
2796
|
|
|
2625
2797
|
if (addMethods && Array.isArray(addMethods)) {
|
|
2626
2798
|
addMethods.forEach(methodName => {
|
|
2627
|
-
methods[methodName] = (el
|
|
2799
|
+
methods[methodName] = function (el) {
|
|
2800
|
+
if (el === void 0) {
|
|
2801
|
+
el = defaultSelector;
|
|
2802
|
+
}
|
|
2803
|
+
|
|
2628
2804
|
const instance = methods.get(el);
|
|
2805
|
+
|
|
2806
|
+
for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
2807
|
+
args[_key2 - 1] = arguments[_key2];
|
|
2808
|
+
}
|
|
2809
|
+
|
|
2629
2810
|
if (instance && instance[methodName]) return instance[methodName](...args);
|
|
2630
2811
|
return undefined;
|
|
2631
2812
|
};
|
|
@@ -2635,7 +2816,11 @@
|
|
|
2635
2816
|
return methods;
|
|
2636
2817
|
}
|
|
2637
2818
|
|
|
2638
|
-
function ModalMethods(parameters
|
|
2819
|
+
function ModalMethods(parameters) {
|
|
2820
|
+
if (parameters === void 0) {
|
|
2821
|
+
parameters = {};
|
|
2822
|
+
}
|
|
2823
|
+
|
|
2639
2824
|
const {
|
|
2640
2825
|
defaultSelector,
|
|
2641
2826
|
constructor: Constructor,
|
|
@@ -2683,7 +2868,11 @@
|
|
|
2683
2868
|
return instance.open(animate);
|
|
2684
2869
|
},
|
|
2685
2870
|
|
|
2686
|
-
close(el
|
|
2871
|
+
close(el, animate, targetEl) {
|
|
2872
|
+
if (el === void 0) {
|
|
2873
|
+
el = defaultSelector;
|
|
2874
|
+
}
|
|
2875
|
+
|
|
2687
2876
|
let $el = $(el);
|
|
2688
2877
|
if (!$el.length) return undefined;
|
|
2689
2878
|
|
|
@@ -2866,7 +3055,11 @@
|
|
|
2866
3055
|
/* eslint-disable no-underscore-dangle */
|
|
2867
3056
|
|
|
2868
3057
|
class Framework7 extends Framework7Class {
|
|
2869
|
-
constructor(params
|
|
3058
|
+
constructor(params) {
|
|
3059
|
+
if (params === void 0) {
|
|
3060
|
+
params = {};
|
|
3061
|
+
}
|
|
3062
|
+
|
|
2870
3063
|
super(params); // eslint-disable-next-line
|
|
2871
3064
|
|
|
2872
3065
|
if (Framework7.instance && typeof window !== 'undefined') {
|
|
@@ -2982,10 +3175,12 @@
|
|
|
2982
3175
|
app.mq.light = window.matchMedia(LIGHT);
|
|
2983
3176
|
}
|
|
2984
3177
|
|
|
2985
|
-
app.colorSchemeListener = function colorSchemeListener({
|
|
2986
|
-
|
|
2987
|
-
|
|
2988
|
-
|
|
3178
|
+
app.colorSchemeListener = function colorSchemeListener(_ref) {
|
|
3179
|
+
let {
|
|
3180
|
+
matches,
|
|
3181
|
+
media
|
|
3182
|
+
} = _ref;
|
|
3183
|
+
|
|
2989
3184
|
if (!matches) {
|
|
2990
3185
|
return;
|
|
2991
3186
|
}
|
|
@@ -3127,13 +3322,13 @@
|
|
|
3127
3322
|
} // eslint-disable-next-line
|
|
3128
3323
|
|
|
3129
3324
|
|
|
3130
|
-
loadModule(
|
|
3131
|
-
return Framework7.loadModule(...
|
|
3325
|
+
loadModule() {
|
|
3326
|
+
return Framework7.loadModule(...arguments);
|
|
3132
3327
|
} // eslint-disable-next-line
|
|
3133
3328
|
|
|
3134
3329
|
|
|
3135
|
-
loadModules(
|
|
3136
|
-
return Framework7.loadModules(...
|
|
3330
|
+
loadModules() {
|
|
3331
|
+
return Framework7.loadModules(...arguments);
|
|
3137
3332
|
}
|
|
3138
3333
|
|
|
3139
3334
|
getVnodeHooks(hook, id) {
|
|
@@ -3212,7 +3407,7 @@
|
|
|
3212
3407
|
}
|
|
3213
3408
|
}
|
|
3214
3409
|
|
|
3215
|
-
if (device.cordova
|
|
3410
|
+
if (device.cordova) {
|
|
3216
3411
|
classNames.push('device-cordova');
|
|
3217
3412
|
}
|
|
3218
3413
|
|
|
@@ -3369,7 +3564,7 @@
|
|
|
3369
3564
|
} // Function to run XHR callbacks and events
|
|
3370
3565
|
|
|
3371
3566
|
|
|
3372
|
-
function fireCallback(callbackName
|
|
3567
|
+
function fireCallback(callbackName) {
|
|
3373
3568
|
/*
|
|
3374
3569
|
Callbacks:
|
|
3375
3570
|
beforeCreate (options),
|
|
@@ -3383,6 +3578,10 @@
|
|
|
3383
3578
|
let globalCallbackValue;
|
|
3384
3579
|
let optionCallbackValue;
|
|
3385
3580
|
|
|
3581
|
+
for (var _len = arguments.length, data = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
3582
|
+
data[_key - 1] = arguments[_key];
|
|
3583
|
+
}
|
|
3584
|
+
|
|
3386
3585
|
if (globals[callbackName]) {
|
|
3387
3586
|
globalCallbackValue = globals[callbackName](...data);
|
|
3388
3587
|
}
|
|
@@ -3712,9 +3911,13 @@
|
|
|
3712
3911
|
xhr.send(postData);
|
|
3713
3912
|
});
|
|
3714
3913
|
|
|
3715
|
-
function requestShortcut(method
|
|
3914
|
+
function requestShortcut(method) {
|
|
3716
3915
|
let [url, data, success, error, dataType] = [];
|
|
3717
3916
|
|
|
3917
|
+
for (var _len2 = arguments.length, args = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
|
|
3918
|
+
args[_key2 - 1] = arguments[_key2];
|
|
3919
|
+
}
|
|
3920
|
+
|
|
3718
3921
|
if (typeof args[1] === 'function') {
|
|
3719
3922
|
[url, success, error, dataType] = args;
|
|
3720
3923
|
} else {
|
|
@@ -3750,11 +3953,41 @@
|
|
|
3750
3953
|
}
|
|
3751
3954
|
|
|
3752
3955
|
Object.assign(request, {
|
|
3753
|
-
get: (
|
|
3754
|
-
|
|
3755
|
-
|
|
3756
|
-
|
|
3757
|
-
|
|
3956
|
+
get: function () {
|
|
3957
|
+
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
|
3958
|
+
args[_key3] = arguments[_key3];
|
|
3959
|
+
}
|
|
3960
|
+
|
|
3961
|
+
return requestShortcut('get', ...args);
|
|
3962
|
+
},
|
|
3963
|
+
post: function () {
|
|
3964
|
+
for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
3965
|
+
args[_key4] = arguments[_key4];
|
|
3966
|
+
}
|
|
3967
|
+
|
|
3968
|
+
return requestShortcut('post', ...args);
|
|
3969
|
+
},
|
|
3970
|
+
json: function () {
|
|
3971
|
+
for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
|
|
3972
|
+
args[_key5] = arguments[_key5];
|
|
3973
|
+
}
|
|
3974
|
+
|
|
3975
|
+
return requestShortcut('json', ...args);
|
|
3976
|
+
},
|
|
3977
|
+
getJSON: function () {
|
|
3978
|
+
for (var _len6 = arguments.length, args = new Array(_len6), _key6 = 0; _key6 < _len6; _key6++) {
|
|
3979
|
+
args[_key6] = arguments[_key6];
|
|
3980
|
+
}
|
|
3981
|
+
|
|
3982
|
+
return requestShortcut('json', ...args);
|
|
3983
|
+
},
|
|
3984
|
+
postJSON: function () {
|
|
3985
|
+
for (var _len7 = arguments.length, args = new Array(_len7), _key7 = 0; _key7 < _len7; _key7++) {
|
|
3986
|
+
args[_key7] = arguments[_key7];
|
|
3987
|
+
}
|
|
3988
|
+
|
|
3989
|
+
return requestShortcut('postJSON', ...args);
|
|
3990
|
+
}
|
|
3758
3991
|
});
|
|
3759
3992
|
|
|
3760
3993
|
request.abortController = () => {
|
|
@@ -5299,12 +5532,13 @@
|
|
|
5299
5532
|
return els;
|
|
5300
5533
|
}
|
|
5301
5534
|
|
|
5302
|
-
function setAnimatableNavElements({
|
|
5303
|
-
|
|
5304
|
-
|
|
5305
|
-
|
|
5306
|
-
|
|
5307
|
-
|
|
5535
|
+
function setAnimatableNavElements(_temp) {
|
|
5536
|
+
let {
|
|
5537
|
+
progress,
|
|
5538
|
+
reset,
|
|
5539
|
+
transition,
|
|
5540
|
+
reflow
|
|
5541
|
+
} = _temp === void 0 ? {} : _temp;
|
|
5308
5542
|
const styles = ['overflow', 'transform', 'transform-origin', 'opacity'];
|
|
5309
5543
|
|
|
5310
5544
|
if (transition === true || transition === false) {
|
|
@@ -5709,7 +5943,11 @@
|
|
|
5709
5943
|
options.history = true; // eslint-disable-line
|
|
5710
5944
|
}
|
|
5711
5945
|
|
|
5712
|
-
function redirectResolve(redirectUrl, redirectOptions
|
|
5946
|
+
function redirectResolve(redirectUrl, redirectOptions) {
|
|
5947
|
+
if (redirectOptions === void 0) {
|
|
5948
|
+
redirectOptions = {};
|
|
5949
|
+
}
|
|
5950
|
+
|
|
5713
5951
|
router.allowPageChange = true;
|
|
5714
5952
|
router[method](redirectUrl, extend({}, options, redirectOptions));
|
|
5715
5953
|
}
|
|
@@ -5863,7 +6101,11 @@
|
|
|
5863
6101
|
});
|
|
5864
6102
|
}
|
|
5865
6103
|
|
|
5866
|
-
function forward(router, el, forwardOptions
|
|
6104
|
+
function forward(router, el, forwardOptions) {
|
|
6105
|
+
if (forwardOptions === void 0) {
|
|
6106
|
+
forwardOptions = {};
|
|
6107
|
+
}
|
|
6108
|
+
|
|
5867
6109
|
const document = getDocument();
|
|
5868
6110
|
const $el = $(el);
|
|
5869
6111
|
const app = router.app;
|
|
@@ -6462,7 +6704,15 @@
|
|
|
6462
6704
|
return router;
|
|
6463
6705
|
}
|
|
6464
6706
|
|
|
6465
|
-
function load(router, loadParams
|
|
6707
|
+
function load(router, loadParams, loadOptions, ignorePageChange) {
|
|
6708
|
+
if (loadParams === void 0) {
|
|
6709
|
+
loadParams = {};
|
|
6710
|
+
}
|
|
6711
|
+
|
|
6712
|
+
if (loadOptions === void 0) {
|
|
6713
|
+
loadOptions = {};
|
|
6714
|
+
}
|
|
6715
|
+
|
|
6466
6716
|
if (!router.allowPageChange && !ignorePageChange) return router;
|
|
6467
6717
|
const params = loadParams;
|
|
6468
6718
|
const options = loadOptions;
|
|
@@ -6577,7 +6827,11 @@
|
|
|
6577
6827
|
return router;
|
|
6578
6828
|
}
|
|
6579
6829
|
|
|
6580
|
-
function navigate(navigateParams, navigateOptions
|
|
6830
|
+
function navigate(navigateParams, navigateOptions) {
|
|
6831
|
+
if (navigateOptions === void 0) {
|
|
6832
|
+
navigateOptions = {};
|
|
6833
|
+
}
|
|
6834
|
+
|
|
6581
6835
|
const router = this;
|
|
6582
6836
|
if (router.swipeBackActive) return router;
|
|
6583
6837
|
let url;
|
|
@@ -6802,7 +7056,11 @@
|
|
|
6802
7056
|
return router;
|
|
6803
7057
|
}
|
|
6804
7058
|
|
|
6805
|
-
function tabLoad(tabRoute, loadOptions
|
|
7059
|
+
function tabLoad(tabRoute, loadOptions) {
|
|
7060
|
+
if (loadOptions === void 0) {
|
|
7061
|
+
loadOptions = {};
|
|
7062
|
+
}
|
|
7063
|
+
|
|
6806
7064
|
const router = this;
|
|
6807
7065
|
const options = extend({
|
|
6808
7066
|
animate: router.params.animate,
|
|
@@ -6832,7 +7090,7 @@
|
|
|
6832
7090
|
|
|
6833
7091
|
|
|
6834
7092
|
if (router.params.browserHistory && options.browserHistory && !options.reloadPrevious) {
|
|
6835
|
-
History.
|
|
7093
|
+
History[router.params.browserHistoryTabs](router.view.id, {
|
|
6836
7094
|
url: options.route.url
|
|
6837
7095
|
}, (router.params.browserHistoryRoot || '') + router.params.browserHistorySeparator + options.route.url);
|
|
6838
7096
|
} // Update Router History
|
|
@@ -7051,7 +7309,11 @@
|
|
|
7051
7309
|
router.removeTabContent($oldTabEl[0], tabRoute);
|
|
7052
7310
|
}
|
|
7053
7311
|
|
|
7054
|
-
function modalLoad(modalType, route, loadOptions
|
|
7312
|
+
function modalLoad(modalType, route, loadOptions, direction) {
|
|
7313
|
+
if (loadOptions === void 0) {
|
|
7314
|
+
loadOptions = {};
|
|
7315
|
+
}
|
|
7316
|
+
|
|
7055
7317
|
const router = this;
|
|
7056
7318
|
const app = router.app;
|
|
7057
7319
|
const isPanel = modalType === 'panel';
|
|
@@ -7298,7 +7560,7 @@
|
|
|
7298
7560
|
const $el = $(el);
|
|
7299
7561
|
const app = router.app;
|
|
7300
7562
|
const view = router.view;
|
|
7301
|
-
const options = extend({
|
|
7563
|
+
const options = extend(false, {
|
|
7302
7564
|
animate: router.params.animate,
|
|
7303
7565
|
browserHistory: true,
|
|
7304
7566
|
replaceState: false
|
|
@@ -7842,7 +8104,7 @@
|
|
|
7842
8104
|
return router;
|
|
7843
8105
|
}
|
|
7844
8106
|
|
|
7845
|
-
function back(
|
|
8107
|
+
function back() {
|
|
7846
8108
|
const router = this;
|
|
7847
8109
|
const device = getDevice();
|
|
7848
8110
|
if (router.swipeBackActive) return router;
|
|
@@ -7850,11 +8112,11 @@
|
|
|
7850
8112
|
let navigateOptions;
|
|
7851
8113
|
let route;
|
|
7852
8114
|
|
|
7853
|
-
if (typeof
|
|
7854
|
-
navigateOptions =
|
|
8115
|
+
if (typeof (arguments.length <= 0 ? undefined : arguments[0]) === 'object') {
|
|
8116
|
+
navigateOptions = (arguments.length <= 0 ? undefined : arguments[0]) || {};
|
|
7855
8117
|
} else {
|
|
7856
|
-
navigateUrl =
|
|
7857
|
-
navigateOptions =
|
|
8118
|
+
navigateUrl = arguments.length <= 0 ? undefined : arguments[0];
|
|
8119
|
+
navigateOptions = (arguments.length <= 1 ? undefined : arguments[1]) || {};
|
|
7858
8120
|
}
|
|
7859
8121
|
|
|
7860
8122
|
const {
|
|
@@ -8006,6 +8268,16 @@
|
|
|
8006
8268
|
}
|
|
8007
8269
|
|
|
8008
8270
|
const previousPageRoute = $previousPage[0].f7Page.route;
|
|
8271
|
+
|
|
8272
|
+
if (navigateOptions.preload && $previousPage.hasClass('stacked')) {
|
|
8273
|
+
loadBack(router, {
|
|
8274
|
+
el: $previousPage
|
|
8275
|
+
}, extend(navigateOptions, {
|
|
8276
|
+
route: previousPageRoute
|
|
8277
|
+
}));
|
|
8278
|
+
return router;
|
|
8279
|
+
}
|
|
8280
|
+
|
|
8009
8281
|
processRouteQueue.call(router, previousPageRoute, router.currentRoute, () => {
|
|
8010
8282
|
loadBack(router, {
|
|
8011
8283
|
el: $previousPage
|
|
@@ -8249,7 +8521,11 @@
|
|
|
8249
8521
|
enumerable: true,
|
|
8250
8522
|
configurable: true,
|
|
8251
8523
|
|
|
8252
|
-
set(newRoute
|
|
8524
|
+
set(newRoute) {
|
|
8525
|
+
if (newRoute === void 0) {
|
|
8526
|
+
newRoute = {};
|
|
8527
|
+
}
|
|
8528
|
+
|
|
8253
8529
|
previousRoute = extend({}, currentRoute);
|
|
8254
8530
|
currentRoute = newRoute;
|
|
8255
8531
|
if (!currentRoute) return;
|
|
@@ -8654,7 +8930,11 @@
|
|
|
8654
8930
|
return undefined;
|
|
8655
8931
|
}
|
|
8656
8932
|
|
|
8657
|
-
flattenRoutes(routes
|
|
8933
|
+
flattenRoutes(routes) {
|
|
8934
|
+
if (routes === void 0) {
|
|
8935
|
+
routes = this.routes;
|
|
8936
|
+
}
|
|
8937
|
+
|
|
8658
8938
|
const router = this;
|
|
8659
8939
|
let flattenedRoutes = [];
|
|
8660
8940
|
routes.forEach(route => {
|
|
@@ -8722,7 +9002,11 @@
|
|
|
8722
9002
|
};
|
|
8723
9003
|
}
|
|
8724
9004
|
|
|
8725
|
-
generateUrl(parameters
|
|
9005
|
+
generateUrl(parameters) {
|
|
9006
|
+
if (parameters === void 0) {
|
|
9007
|
+
parameters = {};
|
|
9008
|
+
}
|
|
9009
|
+
|
|
8726
9010
|
if (typeof parameters === 'string') {
|
|
8727
9011
|
return parameters;
|
|
8728
9012
|
}
|
|
@@ -8762,10 +9046,11 @@
|
|
|
8762
9046
|
} // eslint-disable-next-line
|
|
8763
9047
|
|
|
8764
9048
|
|
|
8765
|
-
constructRouteUrl(route, {
|
|
8766
|
-
|
|
8767
|
-
|
|
8768
|
-
|
|
9049
|
+
constructRouteUrl(route, _temp) {
|
|
9050
|
+
let {
|
|
9051
|
+
params,
|
|
9052
|
+
query
|
|
9053
|
+
} = _temp === void 0 ? {} : _temp;
|
|
8769
9054
|
const {
|
|
8770
9055
|
path
|
|
8771
9056
|
} = route;
|
|
@@ -8886,7 +9171,15 @@
|
|
|
8886
9171
|
} // eslint-disable-next-line
|
|
8887
9172
|
|
|
8888
9173
|
|
|
8889
|
-
replaceRequestUrlParams(url
|
|
9174
|
+
replaceRequestUrlParams(url, options) {
|
|
9175
|
+
if (url === void 0) {
|
|
9176
|
+
url = '';
|
|
9177
|
+
}
|
|
9178
|
+
|
|
9179
|
+
if (options === void 0) {
|
|
9180
|
+
options = {};
|
|
9181
|
+
}
|
|
9182
|
+
|
|
8890
9183
|
let compiledUrl = url;
|
|
8891
9184
|
|
|
8892
9185
|
if (typeof compiledUrl === 'string' && compiledUrl.indexOf('{{') >= 0 && options && options.route && options.route.params && Object.keys(options.route.params).length) {
|
|
@@ -9049,7 +9342,11 @@
|
|
|
9049
9342
|
$(el).find(toRemove).remove();
|
|
9050
9343
|
}
|
|
9051
9344
|
|
|
9052
|
-
getPageData(pageEl, navbarEl, from, to, route
|
|
9345
|
+
getPageData(pageEl, navbarEl, from, to, route, pageFromEl) {
|
|
9346
|
+
if (route === void 0) {
|
|
9347
|
+
route = {};
|
|
9348
|
+
}
|
|
9349
|
+
|
|
9053
9350
|
const router = this;
|
|
9054
9351
|
const $pageEl = $(pageEl).eq(0);
|
|
9055
9352
|
const $navbarEl = $(navbarEl).eq(0);
|
|
@@ -9096,7 +9393,11 @@
|
|
|
9096
9393
|
} // Callbacks
|
|
9097
9394
|
|
|
9098
9395
|
|
|
9099
|
-
pageCallback(callback, pageEl, navbarEl, from, to, options
|
|
9396
|
+
pageCallback(callback, pageEl, navbarEl, from, to, options, pageFromEl) {
|
|
9397
|
+
if (options === void 0) {
|
|
9398
|
+
options = {};
|
|
9399
|
+
}
|
|
9400
|
+
|
|
9100
9401
|
if (!pageEl) return;
|
|
9101
9402
|
const router = this;
|
|
9102
9403
|
const $pageEl = $(pageEl);
|
|
@@ -9821,7 +10122,11 @@
|
|
|
9821
10122
|
}
|
|
9822
10123
|
|
|
9823
10124
|
class View$1 extends Framework7Class {
|
|
9824
|
-
constructor(app, el, viewParams
|
|
10125
|
+
constructor(app, el, viewParams) {
|
|
10126
|
+
if (viewParams === void 0) {
|
|
10127
|
+
viewParams = {};
|
|
10128
|
+
}
|
|
10129
|
+
|
|
9825
10130
|
super(viewParams, [app]);
|
|
9826
10131
|
const view = this;
|
|
9827
10132
|
const ssr = view.params.routerId;
|
|
@@ -10023,7 +10328,14 @@
|
|
|
10023
10328
|
view.initMasterDetail();
|
|
10024
10329
|
}
|
|
10025
10330
|
|
|
10026
|
-
view.
|
|
10331
|
+
if (view.params.initRouterOnTabShow && view.$el.hasClass('tab') && !view.$el.hasClass('tab-active')) {
|
|
10332
|
+
view.$el.once('tab:show', () => {
|
|
10333
|
+
view.router.init();
|
|
10334
|
+
});
|
|
10335
|
+
} else {
|
|
10336
|
+
view.router.init();
|
|
10337
|
+
}
|
|
10338
|
+
|
|
10027
10339
|
view.$el.trigger('view:init');
|
|
10028
10340
|
view.emit('local::init viewInit', view);
|
|
10029
10341
|
}
|
|
@@ -10186,7 +10498,11 @@
|
|
|
10186
10498
|
return router.navigate(navigateOptions);
|
|
10187
10499
|
},
|
|
10188
10500
|
|
|
10189
|
-
componentLoader(component, componentUrl, options
|
|
10501
|
+
componentLoader(component, componentUrl, options, resolve, reject) {
|
|
10502
|
+
if (options === void 0) {
|
|
10503
|
+
options = {};
|
|
10504
|
+
}
|
|
10505
|
+
|
|
10190
10506
|
const router = this;
|
|
10191
10507
|
const {
|
|
10192
10508
|
app
|
|
@@ -10269,41 +10585,48 @@
|
|
|
10269
10585
|
}
|
|
10270
10586
|
},
|
|
10271
10587
|
|
|
10272
|
-
modalComponentLoader({
|
|
10273
|
-
|
|
10274
|
-
|
|
10275
|
-
|
|
10276
|
-
|
|
10277
|
-
|
|
10278
|
-
|
|
10588
|
+
modalComponentLoader(_temp) {
|
|
10589
|
+
let {
|
|
10590
|
+
component,
|
|
10591
|
+
componentUrl,
|
|
10592
|
+
options,
|
|
10593
|
+
resolve,
|
|
10594
|
+
reject
|
|
10595
|
+
} = _temp === void 0 ? {} : _temp;
|
|
10279
10596
|
const router = this;
|
|
10280
10597
|
router.componentLoader(component, componentUrl, options, el => {
|
|
10281
10598
|
resolve(el);
|
|
10282
10599
|
}, reject);
|
|
10283
10600
|
},
|
|
10284
10601
|
|
|
10285
|
-
tabComponentLoader({
|
|
10286
|
-
|
|
10287
|
-
|
|
10288
|
-
|
|
10289
|
-
|
|
10290
|
-
|
|
10291
|
-
|
|
10602
|
+
tabComponentLoader(_temp2) {
|
|
10603
|
+
let {
|
|
10604
|
+
component,
|
|
10605
|
+
componentUrl,
|
|
10606
|
+
options,
|
|
10607
|
+
resolve,
|
|
10608
|
+
reject
|
|
10609
|
+
} = _temp2 === void 0 ? {} : _temp2;
|
|
10292
10610
|
const router = this;
|
|
10293
10611
|
router.componentLoader(component, componentUrl, options, el => {
|
|
10294
10612
|
resolve(el);
|
|
10295
10613
|
}, reject);
|
|
10296
10614
|
},
|
|
10297
10615
|
|
|
10298
|
-
pageComponentLoader({
|
|
10299
|
-
|
|
10300
|
-
|
|
10301
|
-
|
|
10302
|
-
|
|
10303
|
-
|
|
10304
|
-
|
|
10616
|
+
pageComponentLoader(_temp3) {
|
|
10617
|
+
let {
|
|
10618
|
+
component,
|
|
10619
|
+
componentUrl,
|
|
10620
|
+
options,
|
|
10621
|
+
resolve,
|
|
10622
|
+
reject
|
|
10623
|
+
} = _temp3 === void 0 ? {} : _temp3;
|
|
10305
10624
|
const router = this;
|
|
10306
|
-
router.componentLoader(component, componentUrl, options, (el, newOptions
|
|
10625
|
+
router.componentLoader(component, componentUrl, options, function (el, newOptions) {
|
|
10626
|
+
if (newOptions === void 0) {
|
|
10627
|
+
newOptions = {};
|
|
10628
|
+
}
|
|
10629
|
+
|
|
10307
10630
|
resolve(el, newOptions);
|
|
10308
10631
|
}, reject);
|
|
10309
10632
|
}
|
|
@@ -10342,7 +10665,11 @@
|
|
|
10342
10665
|
|
|
10343
10666
|
const ignoreChildren = [false, null, '', undefined];
|
|
10344
10667
|
|
|
10345
|
-
const h$1 = (type, props
|
|
10668
|
+
const h$1 = function (type, props) {
|
|
10669
|
+
for (var _len = arguments.length, children = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
|
|
10670
|
+
children[_key - 2] = arguments[_key];
|
|
10671
|
+
}
|
|
10672
|
+
|
|
10346
10673
|
return {
|
|
10347
10674
|
type,
|
|
10348
10675
|
props: props || {},
|
|
@@ -10442,9 +10769,18 @@
|
|
|
10442
10769
|
}).join('');
|
|
10443
10770
|
};
|
|
10444
10771
|
|
|
10445
|
-
const propsFromAttrs = (
|
|
10772
|
+
const propsFromAttrs = function () {
|
|
10446
10773
|
const context = {};
|
|
10447
|
-
|
|
10774
|
+
|
|
10775
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
10776
|
+
args[_key] = arguments[_key];
|
|
10777
|
+
}
|
|
10778
|
+
|
|
10779
|
+
args.forEach(function (obj) {
|
|
10780
|
+
if (obj === void 0) {
|
|
10781
|
+
obj = {};
|
|
10782
|
+
}
|
|
10783
|
+
|
|
10448
10784
|
Object.keys(obj).forEach(key => {
|
|
10449
10785
|
context[toCamelCase(key)] = obj[key];
|
|
10450
10786
|
});
|
|
@@ -10452,12 +10788,13 @@
|
|
|
10452
10788
|
return context;
|
|
10453
10789
|
};
|
|
10454
10790
|
|
|
10455
|
-
const createCustomComponent =
|
|
10456
|
-
|
|
10457
|
-
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
|
|
10791
|
+
const createCustomComponent = _ref => {
|
|
10792
|
+
let {
|
|
10793
|
+
f7,
|
|
10794
|
+
treeNode,
|
|
10795
|
+
vnode,
|
|
10796
|
+
data
|
|
10797
|
+
} = _ref;
|
|
10461
10798
|
const component = typeof treeNode.type === 'function' ? treeNode.type : customComponents[treeNode.type];
|
|
10462
10799
|
f7.component.create(component, propsFromAttrs(data.attrs || {}, data.props || {}), {
|
|
10463
10800
|
el: vnode.elm,
|
|
@@ -10601,20 +10938,21 @@
|
|
|
10601
10938
|
return hooks;
|
|
10602
10939
|
}
|
|
10603
10940
|
|
|
10604
|
-
const getEventHandler = (eventHandler, {
|
|
10605
|
-
|
|
10606
|
-
|
|
10607
|
-
|
|
10608
|
-
|
|
10941
|
+
const getEventHandler = function (eventHandler, _temp) {
|
|
10942
|
+
let {
|
|
10943
|
+
stop,
|
|
10944
|
+
prevent,
|
|
10945
|
+
once
|
|
10946
|
+
} = _temp === void 0 ? {} : _temp;
|
|
10609
10947
|
let fired = false;
|
|
10610
10948
|
|
|
10611
|
-
function handler(
|
|
10612
|
-
const e =
|
|
10949
|
+
function handler() {
|
|
10950
|
+
const e = arguments.length <= 0 ? undefined : arguments[0];
|
|
10613
10951
|
if (once && fired) return;
|
|
10614
10952
|
if (stop) e.stopPropagation();
|
|
10615
10953
|
if (prevent) e.preventDefault();
|
|
10616
10954
|
fired = true;
|
|
10617
|
-
eventHandler(...
|
|
10955
|
+
eventHandler(...arguments);
|
|
10618
10956
|
}
|
|
10619
10957
|
|
|
10620
10958
|
return handler;
|
|
@@ -10780,7 +11118,11 @@
|
|
|
10780
11118
|
return h(getTagName(treeNode), data, children);
|
|
10781
11119
|
};
|
|
10782
11120
|
|
|
10783
|
-
function vdom(tree
|
|
11121
|
+
function vdom(tree, component, initial) {
|
|
11122
|
+
if (tree === void 0) {
|
|
11123
|
+
tree = {};
|
|
11124
|
+
}
|
|
11125
|
+
|
|
10784
11126
|
return treeNodeToVNode(tree, component, component.f7, initial, true);
|
|
10785
11127
|
}
|
|
10786
11128
|
|
|
@@ -11418,7 +11760,11 @@
|
|
|
11418
11760
|
}
|
|
11419
11761
|
|
|
11420
11762
|
function createListener() {
|
|
11421
|
-
return function handler(event
|
|
11763
|
+
return function handler(event) {
|
|
11764
|
+
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
11765
|
+
args[_key - 1] = arguments[_key];
|
|
11766
|
+
}
|
|
11767
|
+
|
|
11422
11768
|
handleEvent(event, args, handler.vnode);
|
|
11423
11769
|
};
|
|
11424
11770
|
}
|
|
@@ -11484,11 +11830,16 @@
|
|
|
11484
11830
|
/* eslint no-underscore-dangle: "off" */
|
|
11485
11831
|
|
|
11486
11832
|
class Component {
|
|
11487
|
-
constructor(app, component, props
|
|
11488
|
-
|
|
11489
|
-
|
|
11490
|
-
|
|
11491
|
-
|
|
11833
|
+
constructor(app, component, props, _temp) {
|
|
11834
|
+
if (props === void 0) {
|
|
11835
|
+
props = {};
|
|
11836
|
+
}
|
|
11837
|
+
|
|
11838
|
+
let {
|
|
11839
|
+
el,
|
|
11840
|
+
context,
|
|
11841
|
+
children
|
|
11842
|
+
} = _temp === void 0 ? {} : _temp;
|
|
11492
11843
|
const document = getDocument();
|
|
11493
11844
|
merge(this, {
|
|
11494
11845
|
f7: app,
|
|
@@ -11696,17 +12047,19 @@
|
|
|
11696
12047
|
} = this;
|
|
11697
12048
|
if (!this.__eventHandlers) return;
|
|
11698
12049
|
|
|
11699
|
-
this.__eventHandlers.forEach(
|
|
11700
|
-
|
|
11701
|
-
|
|
11702
|
-
|
|
12050
|
+
this.__eventHandlers.forEach(_ref => {
|
|
12051
|
+
let {
|
|
12052
|
+
eventName,
|
|
12053
|
+
handler
|
|
12054
|
+
} = _ref;
|
|
11703
12055
|
$el.on(eventNameToColonCase(eventName), handler);
|
|
11704
12056
|
});
|
|
11705
12057
|
|
|
11706
|
-
this.__onceEventHandlers.forEach(
|
|
11707
|
-
|
|
11708
|
-
|
|
11709
|
-
|
|
12058
|
+
this.__onceEventHandlers.forEach(_ref2 => {
|
|
12059
|
+
let {
|
|
12060
|
+
eventName,
|
|
12061
|
+
handler
|
|
12062
|
+
} = _ref2;
|
|
11710
12063
|
$el.once(eventNameToColonCase(eventName), handler);
|
|
11711
12064
|
});
|
|
11712
12065
|
}
|
|
@@ -11717,17 +12070,19 @@
|
|
|
11717
12070
|
} = this;
|
|
11718
12071
|
if (!this.__eventHandlers) return;
|
|
11719
12072
|
|
|
11720
|
-
this.__eventHandlers.forEach(
|
|
11721
|
-
|
|
11722
|
-
|
|
11723
|
-
|
|
12073
|
+
this.__eventHandlers.forEach(_ref3 => {
|
|
12074
|
+
let {
|
|
12075
|
+
eventName,
|
|
12076
|
+
handler
|
|
12077
|
+
} = _ref3;
|
|
11724
12078
|
$el.on(eventNameToColonCase(eventName), handler);
|
|
11725
12079
|
});
|
|
11726
12080
|
|
|
11727
|
-
this.__onceEventHandlers.forEach(
|
|
11728
|
-
|
|
11729
|
-
|
|
11730
|
-
|
|
12081
|
+
this.__onceEventHandlers.forEach(_ref4 => {
|
|
12082
|
+
let {
|
|
12083
|
+
eventName,
|
|
12084
|
+
handler
|
|
12085
|
+
} = _ref4;
|
|
11731
12086
|
$el.once(eventNameToColonCase(eventName), handler);
|
|
11732
12087
|
});
|
|
11733
12088
|
}
|
|
@@ -11847,7 +12202,11 @@
|
|
|
11847
12202
|
this.__destroyed = true;
|
|
11848
12203
|
}
|
|
11849
12204
|
|
|
11850
|
-
hook(name
|
|
12205
|
+
hook(name) {
|
|
12206
|
+
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
12207
|
+
args[_key - 1] = arguments[_key];
|
|
12208
|
+
}
|
|
12209
|
+
|
|
11851
12210
|
if (this.__destroyed) return;
|
|
11852
12211
|
this[`__${name}`].forEach(handler => {
|
|
11853
12212
|
handler(...args);
|
|
@@ -11956,12 +12315,13 @@
|
|
|
11956
12315
|
return parseComponent(componentString);
|
|
11957
12316
|
},
|
|
11958
12317
|
|
|
11959
|
-
create(component, props, {
|
|
11960
|
-
|
|
11961
|
-
|
|
11962
|
-
|
|
11963
|
-
|
|
11964
|
-
|
|
12318
|
+
create(component, props, _ref) {
|
|
12319
|
+
let {
|
|
12320
|
+
root,
|
|
12321
|
+
el,
|
|
12322
|
+
context,
|
|
12323
|
+
children
|
|
12324
|
+
} = _ref;
|
|
11965
12325
|
return new Component(app, component, props, {
|
|
11966
12326
|
root,
|
|
11967
12327
|
el,
|
|
@@ -12086,7 +12446,11 @@
|
|
|
12086
12446
|
|
|
12087
12447
|
/* eslint-disable no-underscore-dangle */
|
|
12088
12448
|
|
|
12089
|
-
function createStore(storeParams
|
|
12449
|
+
function createStore(storeParams) {
|
|
12450
|
+
if (storeParams === void 0) {
|
|
12451
|
+
storeParams = {};
|
|
12452
|
+
}
|
|
12453
|
+
|
|
12090
12454
|
const store = {
|
|
12091
12455
|
__store: true
|
|
12092
12456
|
};
|
|
@@ -12152,7 +12516,11 @@
|
|
|
12152
12516
|
removeGetterCallback(callback);
|
|
12153
12517
|
};
|
|
12154
12518
|
|
|
12155
|
-
const getterValue = (getterKey, addCallback
|
|
12519
|
+
const getterValue = function (getterKey, addCallback) {
|
|
12520
|
+
if (addCallback === void 0) {
|
|
12521
|
+
addCallback = true;
|
|
12522
|
+
}
|
|
12523
|
+
|
|
12156
12524
|
if (getterKey === 'constructor') return undefined;
|
|
12157
12525
|
propsQueue = [];
|
|
12158
12526
|
const value = getGetterValue(getterKey);
|
|
@@ -12360,7 +12728,11 @@
|
|
|
12360
12728
|
});
|
|
12361
12729
|
},
|
|
12362
12730
|
|
|
12363
|
-
overlaysWebView(overlays
|
|
12731
|
+
overlaysWebView(overlays) {
|
|
12732
|
+
if (overlays === void 0) {
|
|
12733
|
+
overlays = true;
|
|
12734
|
+
}
|
|
12735
|
+
|
|
12364
12736
|
const window = getWindow();
|
|
12365
12737
|
const device = getDevice();
|
|
12366
12738
|
|
|
@@ -12504,6 +12876,7 @@
|
|
|
12504
12876
|
params: {
|
|
12505
12877
|
view: {
|
|
12506
12878
|
init: true,
|
|
12879
|
+
initRouterOnTabShow: false,
|
|
12507
12880
|
name: undefined,
|
|
12508
12881
|
main: false,
|
|
12509
12882
|
router: true,
|
|
@@ -12554,6 +12927,7 @@
|
|
|
12554
12927
|
browserHistoryOnLoad: true,
|
|
12555
12928
|
browserHistoryInitialMatch: false,
|
|
12556
12929
|
browserHistoryStoreHistory: true,
|
|
12930
|
+
browserHistoryTabs: 'replace',
|
|
12557
12931
|
// Animate Pages
|
|
12558
12932
|
animate: true,
|
|
12559
12933
|
// iOS Dynamic Navbar
|
|
@@ -12803,7 +13177,19 @@
|
|
|
12803
13177
|
}
|
|
12804
13178
|
},
|
|
12805
13179
|
|
|
12806
|
-
hide(el, animate
|
|
13180
|
+
hide(el, animate, hideStatusbar, hideOnlyCurrent) {
|
|
13181
|
+
if (animate === void 0) {
|
|
13182
|
+
animate = true;
|
|
13183
|
+
}
|
|
13184
|
+
|
|
13185
|
+
if (hideStatusbar === void 0) {
|
|
13186
|
+
hideStatusbar = false;
|
|
13187
|
+
}
|
|
13188
|
+
|
|
13189
|
+
if (hideOnlyCurrent === void 0) {
|
|
13190
|
+
hideOnlyCurrent = false;
|
|
13191
|
+
}
|
|
13192
|
+
|
|
12807
13193
|
const app = this;
|
|
12808
13194
|
let $el = $(el);
|
|
12809
13195
|
const isDynamic = $el.hasClass('navbar') && $el.parent('.navbars').length && !hideOnlyCurrent;
|
|
@@ -12837,7 +13223,19 @@
|
|
|
12837
13223
|
}
|
|
12838
13224
|
},
|
|
12839
13225
|
|
|
12840
|
-
show(el
|
|
13226
|
+
show(el, animate, hideOnlyCurrent) {
|
|
13227
|
+
if (el === void 0) {
|
|
13228
|
+
el = '.navbar-hidden';
|
|
13229
|
+
}
|
|
13230
|
+
|
|
13231
|
+
if (animate === void 0) {
|
|
13232
|
+
animate = true;
|
|
13233
|
+
}
|
|
13234
|
+
|
|
13235
|
+
if (hideOnlyCurrent === void 0) {
|
|
13236
|
+
hideOnlyCurrent = false;
|
|
13237
|
+
}
|
|
13238
|
+
|
|
12841
13239
|
const app = this;
|
|
12842
13240
|
let $el = $(el);
|
|
12843
13241
|
const isDynamic = $el.hasClass('navbar') && $el.parent('.navbars').length && !hideOnlyCurrent;
|
|
@@ -13468,8 +13866,8 @@
|
|
|
13468
13866
|
const Toolbar = {
|
|
13469
13867
|
setHighlight(tabbarEl) {
|
|
13470
13868
|
const app = this;
|
|
13471
|
-
if (app.theme === 'ios') return;
|
|
13472
13869
|
const $tabbarEl = $(tabbarEl);
|
|
13870
|
+
if (app.theme === 'ios' && !$tabbarEl.hasClass('tabbar-highlight')) return;
|
|
13473
13871
|
if ($tabbarEl.length === 0 || !($tabbarEl.hasClass('tabbar') || $tabbarEl.hasClass('tabbar-labels'))) return;
|
|
13474
13872
|
let $highlightEl = $tabbarEl.find('.tab-link-highlight');
|
|
13475
13873
|
const tabLinksCount = $tabbarEl.find('.tab-link').length;
|
|
@@ -13509,7 +13907,11 @@
|
|
|
13509
13907
|
app.toolbar.setHighlight(tabbarEl);
|
|
13510
13908
|
},
|
|
13511
13909
|
|
|
13512
|
-
hide(el, animate
|
|
13910
|
+
hide(el, animate) {
|
|
13911
|
+
if (animate === void 0) {
|
|
13912
|
+
animate = true;
|
|
13913
|
+
}
|
|
13914
|
+
|
|
13513
13915
|
const app = this;
|
|
13514
13916
|
const $el = $(el);
|
|
13515
13917
|
if ($el.hasClass('toolbar-hidden')) return;
|
|
@@ -13522,7 +13924,11 @@
|
|
|
13522
13924
|
app.emit('toolbarHide', $el[0]);
|
|
13523
13925
|
},
|
|
13524
13926
|
|
|
13525
|
-
show(el, animate
|
|
13927
|
+
show(el, animate) {
|
|
13928
|
+
if (animate === void 0) {
|
|
13929
|
+
animate = true;
|
|
13930
|
+
}
|
|
13931
|
+
|
|
13526
13932
|
const app = this;
|
|
13527
13933
|
const $el = $(el);
|
|
13528
13934
|
if (!$el.hasClass('toolbar-hidden')) return;
|
|
@@ -13819,7 +14225,11 @@
|
|
|
13819
14225
|
create() {
|
|
13820
14226
|
const app = this;
|
|
13821
14227
|
app.touchRipple = {
|
|
13822
|
-
create(
|
|
14228
|
+
create() {
|
|
14229
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
14230
|
+
args[_key] = arguments[_key];
|
|
14231
|
+
}
|
|
14232
|
+
|
|
13823
14233
|
return new TouchRipple$1(...args);
|
|
13824
14234
|
}
|
|
13825
14235
|
|
|
@@ -13885,6 +14295,11 @@
|
|
|
13885
14295
|
if (!modal.type || !modal.$el) return;
|
|
13886
14296
|
modal.$el.removeClass('modal-out');
|
|
13887
14297
|
modal.$el.hide();
|
|
14298
|
+
|
|
14299
|
+
if (modal.params.backdrop && (modal.params.backdropUnique || modal.forceBackdropUnique) && modal.$backdropEl) {
|
|
14300
|
+
modal.$backdropEl.remove();
|
|
14301
|
+
}
|
|
14302
|
+
|
|
13888
14303
|
modal.$el.trigger(`modal:closed ${modal.type.toLowerCase()}:closed`);
|
|
13889
14304
|
modal.emit(`local::closed modalClosed ${modal.type}Closed`, modal);
|
|
13890
14305
|
}
|
|
@@ -13942,8 +14357,13 @@
|
|
|
13942
14357
|
|
|
13943
14358
|
|
|
13944
14359
|
$el.show();
|
|
14360
|
+
|
|
14361
|
+
if (modal.params.backdrop && (modal.params.backdropUnique || modal.forceBackdropUnique) && modal.$backdropEl) {
|
|
14362
|
+
modal.$backdropEl.insertBefore($el);
|
|
14363
|
+
}
|
|
13945
14364
|
/* eslint no-underscore-dangle: ["error", { "allow": ["_clientLeft"] }] */
|
|
13946
14365
|
|
|
14366
|
+
|
|
13947
14367
|
modal._clientLeft = $el[0].clientLeft; // Modal
|
|
13948
14368
|
|
|
13949
14369
|
function transitionEnd() {
|
|
@@ -14179,5 +14599,5 @@
|
|
|
14179
14599
|
|
|
14180
14600
|
return Framework7;
|
|
14181
14601
|
|
|
14182
|
-
}))
|
|
14602
|
+
}));
|
|
14183
14603
|
//# sourceMappingURL=framework7.js.map
|