Version Description
- 2017-04-11 =
- Fixed: Interactive widget customizer is now working with MailPoet form widgets. Thanks Peter and Charis!
- Fixed: Multi-line headings are now properly displayed in emails. Thanks Karen!
Download this release
Release Info
| Developer | wysija |
| Plugin | |
| Version | 3.0.0-beta.26 |
| Comparing to | |
| See all releases | |
Code changes from version 3.0.0-beta.25 to 3.0.0-beta.26
- assets/css/admin.css +4 -6
- assets/js/admin.js +1912 -989
- assets/js/admin_vendor.js +2321 -860
- assets/js/form_editor.js +3689 -3614
- assets/js/mailpoet.js +1264 -606
assets/css/admin.css
CHANGED
|
@@ -1773,11 +1773,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;}
|
|
| 1773 |
cursor: default;
|
| 1774 |
z-index: 4;
|
| 1775 |
}
|
| 1776 |
-
.CodeMirror-gutter-wrapper {
|
| 1777 |
-
|
| 1778 |
-
-moz-user-select: none;
|
| 1779 |
-
user-select: none;
|
| 1780 |
-
}
|
| 1781 |
|
| 1782 |
.CodeMirror-lines {
|
| 1783 |
cursor: text;
|
|
@@ -1822,6 +1819,8 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;}
|
|
| 1822 |
|
| 1823 |
.CodeMirror-widget {}
|
| 1824 |
|
|
|
|
|
|
|
| 1825 |
.CodeMirror-code {
|
| 1826 |
outline: none;
|
| 1827 |
}
|
|
@@ -2749,7 +2748,6 @@ textarea.parsley-error {
|
|
| 2749 |
#mailpoet_settings .mailpoet_sending_methods h3 {
|
| 2750 |
text-align: center;
|
| 2751 |
height: 54px;
|
| 2752 |
-
line-height: 54px;
|
| 2753 |
font-size: 1.5em;
|
| 2754 |
}
|
| 2755 |
#mailpoet_settings .mailpoet_sending_methods .mailpoet_description {
|
| 1773 |
cursor: default;
|
| 1774 |
z-index: 4;
|
| 1775 |
}
|
| 1776 |
+
.CodeMirror-gutter-wrapper ::selection { background-color: transparent }
|
| 1777 |
+
.CodeMirror-gutter-wrapper ::-moz-selection { background-color: transparent }
|
|
|
|
|
|
|
|
|
|
| 1778 |
|
| 1779 |
.CodeMirror-lines {
|
| 1780 |
cursor: text;
|
| 1819 |
|
| 1820 |
.CodeMirror-widget {}
|
| 1821 |
|
| 1822 |
+
.CodeMirror-rtl pre { direction: rtl; }
|
| 1823 |
+
|
| 1824 |
.CodeMirror-code {
|
| 1825 |
outline: none;
|
| 1826 |
}
|
| 2748 |
#mailpoet_settings .mailpoet_sending_methods h3 {
|
| 2749 |
text-align: center;
|
| 2750 |
height: 54px;
|
|
|
|
| 2751 |
font-size: 1.5em;
|
| 2752 |
}
|
| 2753 |
#mailpoet_settings .mailpoet_sending_methods .mailpoet_description {
|
assets/js/admin.js
CHANGED
|
@@ -3,13 +3,13 @@ webpackJsonp([0],[
|
|
| 3 |
/***/ function(module, exports, __webpack_require__) {
|
| 4 |
|
| 5 |
__webpack_require__(1);
|
| 6 |
-
__webpack_require__(
|
| 7 |
-
__webpack_require__(
|
| 8 |
-
__webpack_require__(
|
| 9 |
-
__webpack_require__(
|
| 10 |
-
__webpack_require__(
|
| 11 |
-
__webpack_require__(
|
| 12 |
-
module.exports = __webpack_require__(
|
| 13 |
|
| 14 |
|
| 15 |
/***/ },
|
|
@@ -30,13 +30,13 @@ webpackJsonp([0],[
|
|
| 30 |
|
| 31 |
var _reactRouter = __webpack_require__(181);
|
| 32 |
|
| 33 |
-
var _history = __webpack_require__(
|
| 34 |
|
| 35 |
-
var _subscribersListJsx = __webpack_require__(
|
| 36 |
|
| 37 |
var _subscribersListJsx2 = _interopRequireDefault(_subscribersListJsx);
|
| 38 |
|
| 39 |
-
var _subscribersFormJsx = __webpack_require__(
|
| 40 |
|
| 41 |
var _subscribersFormJsx2 = _interopRequireDefault(_subscribersFormJsx);
|
| 42 |
|
|
@@ -303,7 +303,14 @@ webpackJsonp([0],[
|
|
| 303 |
/* 234 */,
|
| 304 |
/* 235 */,
|
| 305 |
/* 236 */,
|
| 306 |
-
/* 237
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 307 |
/***/ function(module, exports, __webpack_require__) {
|
| 308 |
|
| 309 |
'use strict';
|
|
@@ -312,49 +319,49 @@ webpackJsonp([0],[
|
|
| 312 |
|
| 313 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 314 |
|
| 315 |
-
var _createBrowserHistory = __webpack_require__(
|
| 316 |
|
| 317 |
var _createBrowserHistory2 = _interopRequireDefault(_createBrowserHistory);
|
| 318 |
|
| 319 |
exports.createHistory = _createBrowserHistory2['default'];
|
| 320 |
|
| 321 |
-
var _createHashHistory2 = __webpack_require__(
|
| 322 |
|
| 323 |
var _createHashHistory3 = _interopRequireDefault(_createHashHistory2);
|
| 324 |
|
| 325 |
exports.createHashHistory = _createHashHistory3['default'];
|
| 326 |
|
| 327 |
-
var _createMemoryHistory2 = __webpack_require__(
|
| 328 |
|
| 329 |
var _createMemoryHistory3 = _interopRequireDefault(_createMemoryHistory2);
|
| 330 |
|
| 331 |
exports.createMemoryHistory = _createMemoryHistory3['default'];
|
| 332 |
|
| 333 |
-
var _createLocation2 = __webpack_require__(
|
| 334 |
|
| 335 |
var _createLocation3 = _interopRequireDefault(_createLocation2);
|
| 336 |
|
| 337 |
exports.createLocation = _createLocation3['default'];
|
| 338 |
|
| 339 |
-
var _useBasename2 = __webpack_require__(
|
| 340 |
|
| 341 |
var _useBasename3 = _interopRequireDefault(_useBasename2);
|
| 342 |
|
| 343 |
exports.useBasename = _useBasename3['default'];
|
| 344 |
|
| 345 |
-
var _useBeforeUnload2 = __webpack_require__(
|
| 346 |
|
| 347 |
var _useBeforeUnload3 = _interopRequireDefault(_useBeforeUnload2);
|
| 348 |
|
| 349 |
exports.useBeforeUnload = _useBeforeUnload3['default'];
|
| 350 |
|
| 351 |
-
var _useQueries2 = __webpack_require__(
|
| 352 |
|
| 353 |
var _useQueries3 = _interopRequireDefault(_useQueries2);
|
| 354 |
|
| 355 |
exports.useQueries = _useQueries3['default'];
|
| 356 |
|
| 357 |
-
var _Actions2 = __webpack_require__(
|
| 358 |
|
| 359 |
var _Actions3 = _interopRequireDefault(_Actions2);
|
| 360 |
|
|
@@ -362,20 +369,20 @@ webpackJsonp([0],[
|
|
| 362 |
|
| 363 |
// deprecated
|
| 364 |
|
| 365 |
-
var _enableBeforeUnload2 = __webpack_require__(
|
| 366 |
|
| 367 |
var _enableBeforeUnload3 = _interopRequireDefault(_enableBeforeUnload2);
|
| 368 |
|
| 369 |
exports.enableBeforeUnload = _enableBeforeUnload3['default'];
|
| 370 |
|
| 371 |
-
var _enableQueries2 = __webpack_require__(
|
| 372 |
|
| 373 |
var _enableQueries3 = _interopRequireDefault(_enableQueries2);
|
| 374 |
|
| 375 |
exports.enableQueries = _enableQueries3['default'];
|
| 376 |
|
| 377 |
/***/ },
|
| 378 |
-
/*
|
| 379 |
/***/ function(module, exports, __webpack_require__) {
|
| 380 |
|
| 381 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -386,19 +393,19 @@ webpackJsonp([0],[
|
|
| 386 |
|
| 387 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 388 |
|
| 389 |
-
var _invariant = __webpack_require__(
|
| 390 |
|
| 391 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 392 |
|
| 393 |
-
var _Actions = __webpack_require__(
|
| 394 |
|
| 395 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 396 |
|
| 397 |
-
var _DOMUtils = __webpack_require__(
|
| 398 |
|
| 399 |
-
var _DOMStateStorage = __webpack_require__(
|
| 400 |
|
| 401 |
-
var _createDOMHistory = __webpack_require__(
|
| 402 |
|
| 403 |
var _createDOMHistory2 = _interopRequireDefault(_createDOMHistory);
|
| 404 |
|
|
@@ -553,7 +560,7 @@ webpackJsonp([0],[
|
|
| 553 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 554 |
|
| 555 |
/***/ },
|
| 556 |
-
/*
|
| 557 |
/***/ function(module, exports) {
|
| 558 |
|
| 559 |
/**
|
|
@@ -589,7 +596,7 @@ webpackJsonp([0],[
|
|
| 589 |
};
|
| 590 |
|
| 591 |
/***/ },
|
| 592 |
-
/*
|
| 593 |
/***/ function(module, exports) {
|
| 594 |
|
| 595 |
'use strict';
|
|
@@ -599,7 +606,7 @@ webpackJsonp([0],[
|
|
| 599 |
exports.canUseDOM = canUseDOM;
|
| 600 |
|
| 601 |
/***/ },
|
| 602 |
-
/*
|
| 603 |
/***/ function(module, exports) {
|
| 604 |
|
| 605 |
'use strict';
|
|
@@ -679,7 +686,7 @@ webpackJsonp([0],[
|
|
| 679 |
}
|
| 680 |
|
| 681 |
/***/ },
|
| 682 |
-
/*
|
| 683 |
/***/ function(module, exports, __webpack_require__) {
|
| 684 |
|
| 685 |
/* WEBPACK VAR INJECTION */(function(process) {/*eslint-disable no-empty */
|
|
@@ -691,7 +698,7 @@ webpackJsonp([0],[
|
|
| 691 |
|
| 692 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 693 |
|
| 694 |
-
var _warning = __webpack_require__(
|
| 695 |
|
| 696 |
var _warning2 = _interopRequireDefault(_warning);
|
| 697 |
|
|
@@ -753,7 +760,7 @@ webpackJsonp([0],[
|
|
| 753 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 754 |
|
| 755 |
/***/ },
|
| 756 |
-
/*
|
| 757 |
/***/ function(module, exports, __webpack_require__) {
|
| 758 |
|
| 759 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
|
@@ -820,7 +827,7 @@ webpackJsonp([0],[
|
|
| 820 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 821 |
|
| 822 |
/***/ },
|
| 823 |
-
/*
|
| 824 |
/***/ function(module, exports, __webpack_require__) {
|
| 825 |
|
| 826 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -831,15 +838,15 @@ webpackJsonp([0],[
|
|
| 831 |
|
| 832 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 833 |
|
| 834 |
-
var _invariant = __webpack_require__(
|
| 835 |
|
| 836 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 837 |
|
| 838 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 839 |
|
| 840 |
-
var _DOMUtils = __webpack_require__(
|
| 841 |
|
| 842 |
-
var _createHistory = __webpack_require__(
|
| 843 |
|
| 844 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 845 |
|
|
@@ -866,7 +873,7 @@ webpackJsonp([0],[
|
|
| 866 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 867 |
|
| 868 |
/***/ },
|
| 869 |
-
/*
|
| 870 |
/***/ function(module, exports, __webpack_require__) {
|
| 871 |
|
| 872 |
'use strict';
|
|
@@ -877,23 +884,23 @@ webpackJsonp([0],[
|
|
| 877 |
|
| 878 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 879 |
|
| 880 |
-
var _deepEqual = __webpack_require__(
|
| 881 |
|
| 882 |
var _deepEqual2 = _interopRequireDefault(_deepEqual);
|
| 883 |
|
| 884 |
-
var _AsyncUtils = __webpack_require__(
|
| 885 |
|
| 886 |
-
var _Actions = __webpack_require__(
|
| 887 |
|
| 888 |
-
var _createLocation2 = __webpack_require__(
|
| 889 |
|
| 890 |
var _createLocation3 = _interopRequireDefault(_createLocation2);
|
| 891 |
|
| 892 |
-
var _runTransitionHook = __webpack_require__(
|
| 893 |
|
| 894 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 895 |
|
| 896 |
-
var _deprecate = __webpack_require__(
|
| 897 |
|
| 898 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 899 |
|
|
@@ -1141,12 +1148,12 @@ webpackJsonp([0],[
|
|
| 1141 |
module.exports = exports['default'];
|
| 1142 |
|
| 1143 |
/***/ },
|
| 1144 |
-
/*
|
| 1145 |
/***/ function(module, exports, __webpack_require__) {
|
| 1146 |
|
| 1147 |
var pSlice = Array.prototype.slice;
|
| 1148 |
-
var objectKeys = __webpack_require__(
|
| 1149 |
-
var isArguments = __webpack_require__(
|
| 1150 |
|
| 1151 |
var deepEqual = module.exports = function (actual, expected, opts) {
|
| 1152 |
if (!opts) opts = {};
|
|
@@ -1241,7 +1248,7 @@ webpackJsonp([0],[
|
|
| 1241 |
|
| 1242 |
|
| 1243 |
/***/ },
|
| 1244 |
-
/*
|
| 1245 |
/***/ function(module, exports) {
|
| 1246 |
|
| 1247 |
exports = module.exports = typeof Object.keys === 'function'
|
|
@@ -1256,7 +1263,7 @@ webpackJsonp([0],[
|
|
| 1256 |
|
| 1257 |
|
| 1258 |
/***/ },
|
| 1259 |
-
/*
|
| 1260 |
/***/ function(module, exports) {
|
| 1261 |
|
| 1262 |
var supportsArgumentsClass = (function(){
|
|
@@ -1282,7 +1289,7 @@ webpackJsonp([0],[
|
|
| 1282 |
|
| 1283 |
|
| 1284 |
/***/ },
|
| 1285 |
-
/*
|
| 1286 |
/***/ function(module, exports) {
|
| 1287 |
|
| 1288 |
"use strict";
|
|
@@ -1313,7 +1320,7 @@ webpackJsonp([0],[
|
|
| 1313 |
}
|
| 1314 |
|
| 1315 |
/***/ },
|
| 1316 |
-
/*
|
| 1317 |
/***/ function(module, exports, __webpack_require__) {
|
| 1318 |
|
| 1319 |
'use strict';
|
|
@@ -1322,9 +1329,9 @@ webpackJsonp([0],[
|
|
| 1322 |
|
| 1323 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1324 |
|
| 1325 |
-
var _Actions = __webpack_require__(
|
| 1326 |
|
| 1327 |
-
var _parsePath = __webpack_require__(
|
| 1328 |
|
| 1329 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 1330 |
|
|
@@ -1354,7 +1361,7 @@ webpackJsonp([0],[
|
|
| 1354 |
module.exports = exports['default'];
|
| 1355 |
|
| 1356 |
/***/ },
|
| 1357 |
-
/*
|
| 1358 |
/***/ function(module, exports, __webpack_require__) {
|
| 1359 |
|
| 1360 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -1363,11 +1370,11 @@ webpackJsonp([0],[
|
|
| 1363 |
|
| 1364 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1365 |
|
| 1366 |
-
var _warning = __webpack_require__(
|
| 1367 |
|
| 1368 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1369 |
|
| 1370 |
-
var _extractPath = __webpack_require__(
|
| 1371 |
|
| 1372 |
var _extractPath2 = _interopRequireDefault(_extractPath);
|
| 1373 |
|
|
@@ -1404,7 +1411,7 @@ webpackJsonp([0],[
|
|
| 1404 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1405 |
|
| 1406 |
/***/ },
|
| 1407 |
-
/*
|
| 1408 |
/***/ function(module, exports) {
|
| 1409 |
|
| 1410 |
"use strict";
|
|
@@ -1422,7 +1429,7 @@ webpackJsonp([0],[
|
|
| 1422 |
module.exports = exports["default"];
|
| 1423 |
|
| 1424 |
/***/ },
|
| 1425 |
-
/*
|
| 1426 |
/***/ function(module, exports, __webpack_require__) {
|
| 1427 |
|
| 1428 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -1431,7 +1438,7 @@ webpackJsonp([0],[
|
|
| 1431 |
|
| 1432 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1433 |
|
| 1434 |
-
var _warning = __webpack_require__(
|
| 1435 |
|
| 1436 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1437 |
|
|
@@ -1452,7 +1459,7 @@ webpackJsonp([0],[
|
|
| 1452 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1453 |
|
| 1454 |
/***/ },
|
| 1455 |
-
/*
|
| 1456 |
/***/ function(module, exports, __webpack_require__) {
|
| 1457 |
|
| 1458 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -1461,7 +1468,7 @@ webpackJsonp([0],[
|
|
| 1461 |
|
| 1462 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1463 |
|
| 1464 |
-
var _warning = __webpack_require__(
|
| 1465 |
|
| 1466 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1467 |
|
|
@@ -1477,7 +1484,7 @@ webpackJsonp([0],[
|
|
| 1477 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1478 |
|
| 1479 |
/***/ },
|
| 1480 |
-
/*
|
| 1481 |
/***/ function(module, exports, __webpack_require__) {
|
| 1482 |
|
| 1483 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -1488,23 +1495,23 @@ webpackJsonp([0],[
|
|
| 1488 |
|
| 1489 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1490 |
|
| 1491 |
-
var _warning = __webpack_require__(
|
| 1492 |
|
| 1493 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1494 |
|
| 1495 |
-
var _invariant = __webpack_require__(
|
| 1496 |
|
| 1497 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 1498 |
|
| 1499 |
-
var _Actions = __webpack_require__(
|
| 1500 |
|
| 1501 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 1502 |
|
| 1503 |
-
var _DOMUtils = __webpack_require__(
|
| 1504 |
|
| 1505 |
-
var _DOMStateStorage = __webpack_require__(
|
| 1506 |
|
| 1507 |
-
var _createDOMHistory = __webpack_require__(
|
| 1508 |
|
| 1509 |
var _createDOMHistory2 = _interopRequireDefault(_createDOMHistory);
|
| 1510 |
|
|
@@ -1708,7 +1715,7 @@ webpackJsonp([0],[
|
|
| 1708 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1709 |
|
| 1710 |
/***/ },
|
| 1711 |
-
/*
|
| 1712 |
/***/ function(module, exports, __webpack_require__) {
|
| 1713 |
|
| 1714 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -1719,13 +1726,13 @@ webpackJsonp([0],[
|
|
| 1719 |
|
| 1720 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1721 |
|
| 1722 |
-
var _invariant = __webpack_require__(
|
| 1723 |
|
| 1724 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 1725 |
|
| 1726 |
-
var _Actions = __webpack_require__(
|
| 1727 |
|
| 1728 |
-
var _createHistory = __webpack_require__(
|
| 1729 |
|
| 1730 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 1731 |
|
|
@@ -1856,7 +1863,7 @@ webpackJsonp([0],[
|
|
| 1856 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1857 |
|
| 1858 |
/***/ },
|
| 1859 |
-
/*
|
| 1860 |
/***/ function(module, exports, __webpack_require__) {
|
| 1861 |
|
| 1862 |
'use strict';
|
|
@@ -1869,17 +1876,17 @@ webpackJsonp([0],[
|
|
| 1869 |
|
| 1870 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 1871 |
|
| 1872 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 1873 |
|
| 1874 |
-
var _runTransitionHook = __webpack_require__(
|
| 1875 |
|
| 1876 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 1877 |
|
| 1878 |
-
var _extractPath = __webpack_require__(
|
| 1879 |
|
| 1880 |
var _extractPath2 = _interopRequireDefault(_extractPath);
|
| 1881 |
|
| 1882 |
-
var _parsePath = __webpack_require__(
|
| 1883 |
|
| 1884 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 1885 |
|
|
@@ -1990,7 +1997,7 @@ webpackJsonp([0],[
|
|
| 1990 |
module.exports = exports['default'];
|
| 1991 |
|
| 1992 |
/***/ },
|
| 1993 |
-
/*
|
| 1994 |
/***/ function(module, exports, __webpack_require__) {
|
| 1995 |
|
| 1996 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -2001,15 +2008,15 @@ webpackJsonp([0],[
|
|
| 2001 |
|
| 2002 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2003 |
|
| 2004 |
-
var _warning = __webpack_require__(
|
| 2005 |
|
| 2006 |
var _warning2 = _interopRequireDefault(_warning);
|
| 2007 |
|
| 2008 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 2009 |
|
| 2010 |
-
var _DOMUtils = __webpack_require__(
|
| 2011 |
|
| 2012 |
-
var _deprecate = __webpack_require__(
|
| 2013 |
|
| 2014 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2015 |
|
|
@@ -2107,7 +2114,7 @@ webpackJsonp([0],[
|
|
| 2107 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 2108 |
|
| 2109 |
/***/ },
|
| 2110 |
-
/*
|
| 2111 |
/***/ function(module, exports, __webpack_require__) {
|
| 2112 |
|
| 2113 |
'use strict';
|
|
@@ -2120,15 +2127,15 @@ webpackJsonp([0],[
|
|
| 2120 |
|
| 2121 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 2122 |
|
| 2123 |
-
var _qs = __webpack_require__(
|
| 2124 |
|
| 2125 |
var _qs2 = _interopRequireDefault(_qs);
|
| 2126 |
|
| 2127 |
-
var _runTransitionHook = __webpack_require__(
|
| 2128 |
|
| 2129 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 2130 |
|
| 2131 |
-
var _parsePath = __webpack_require__(
|
| 2132 |
|
| 2133 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 2134 |
|
|
@@ -2227,13 +2234,13 @@ webpackJsonp([0],[
|
|
| 2227 |
module.exports = exports['default'];
|
| 2228 |
|
| 2229 |
/***/ },
|
| 2230 |
-
/*
|
| 2231 |
/***/ function(module, exports, __webpack_require__) {
|
| 2232 |
|
| 2233 |
// Load modules
|
| 2234 |
|
| 2235 |
-
var Stringify = __webpack_require__(
|
| 2236 |
-
var Parse = __webpack_require__(
|
| 2237 |
|
| 2238 |
|
| 2239 |
// Declare internals
|
|
@@ -2248,12 +2255,12 @@ webpackJsonp([0],[
|
|
| 2248 |
|
| 2249 |
|
| 2250 |
/***/ },
|
| 2251 |
-
/*
|
| 2252 |
/***/ function(module, exports, __webpack_require__) {
|
| 2253 |
|
| 2254 |
// Load modules
|
| 2255 |
|
| 2256 |
-
var Utils = __webpack_require__(
|
| 2257 |
|
| 2258 |
|
| 2259 |
// Declare internals
|
|
@@ -2375,7 +2382,7 @@ webpackJsonp([0],[
|
|
| 2375 |
|
| 2376 |
|
| 2377 |
/***/ },
|
| 2378 |
-
/*
|
| 2379 |
/***/ function(module, exports) {
|
| 2380 |
|
| 2381 |
// Load modules
|
|
@@ -2571,12 +2578,12 @@ webpackJsonp([0],[
|
|
| 2571 |
|
| 2572 |
|
| 2573 |
/***/ },
|
| 2574 |
-
/*
|
| 2575 |
/***/ function(module, exports, __webpack_require__) {
|
| 2576 |
|
| 2577 |
// Load modules
|
| 2578 |
|
| 2579 |
-
var Utils = __webpack_require__(
|
| 2580 |
|
| 2581 |
|
| 2582 |
// Declare internals
|
|
@@ -2763,7 +2770,7 @@ webpackJsonp([0],[
|
|
| 2763 |
|
| 2764 |
|
| 2765 |
/***/ },
|
| 2766 |
-
/*
|
| 2767 |
/***/ function(module, exports, __webpack_require__) {
|
| 2768 |
|
| 2769 |
'use strict';
|
|
@@ -2772,11 +2779,11 @@ webpackJsonp([0],[
|
|
| 2772 |
|
| 2773 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2774 |
|
| 2775 |
-
var _deprecate = __webpack_require__(
|
| 2776 |
|
| 2777 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2778 |
|
| 2779 |
-
var _useBeforeUnload = __webpack_require__(
|
| 2780 |
|
| 2781 |
var _useBeforeUnload2 = _interopRequireDefault(_useBeforeUnload);
|
| 2782 |
|
|
@@ -2784,7 +2791,7 @@ webpackJsonp([0],[
|
|
| 2784 |
module.exports = exports['default'];
|
| 2785 |
|
| 2786 |
/***/ },
|
| 2787 |
-
/*
|
| 2788 |
/***/ function(module, exports, __webpack_require__) {
|
| 2789 |
|
| 2790 |
'use strict';
|
|
@@ -2793,11 +2800,11 @@ webpackJsonp([0],[
|
|
| 2793 |
|
| 2794 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2795 |
|
| 2796 |
-
var _deprecate = __webpack_require__(
|
| 2797 |
|
| 2798 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2799 |
|
| 2800 |
-
var _useQueries = __webpack_require__(
|
| 2801 |
|
| 2802 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 2803 |
|
|
@@ -2805,7 +2812,7 @@ webpackJsonp([0],[
|
|
| 2805 |
module.exports = exports['default'];
|
| 2806 |
|
| 2807 |
/***/ },
|
| 2808 |
-
/*
|
| 2809 |
/***/ function(module, exports, __webpack_require__) {
|
| 2810 |
|
| 2811 |
'use strict';
|
|
@@ -2818,23 +2825,23 @@ webpackJsonp([0],[
|
|
| 2818 |
|
| 2819 |
var _reactRouter = __webpack_require__(181);
|
| 2820 |
|
| 2821 |
-
var _jquery = __webpack_require__(
|
| 2822 |
|
| 2823 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 2824 |
|
| 2825 |
-
var _mailpoet = __webpack_require__(
|
| 2826 |
|
| 2827 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 2828 |
|
| 2829 |
-
var _classnames = __webpack_require__(
|
| 2830 |
|
| 2831 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 2832 |
|
| 2833 |
-
var _listingListingJsx = __webpack_require__(
|
| 2834 |
|
| 2835 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 2836 |
|
| 2837 |
-
var _formFieldsSelectionJsx = __webpack_require__(
|
| 2838 |
|
| 2839 |
var _formFieldsSelectionJsx2 = _interopRequireDefault(_formFieldsSelectionJsx);
|
| 2840 |
|
|
@@ -3179,13 +3186,13 @@ webpackJsonp([0],[
|
|
| 3179 |
module.exports = SubscriberList;
|
| 3180 |
|
| 3181 |
/***/ },
|
| 3182 |
-
/*
|
| 3183 |
/***/ function(module, exports) {
|
| 3184 |
|
| 3185 |
module.exports = jQuery;
|
| 3186 |
|
| 3187 |
/***/ },
|
| 3188 |
-
/*
|
| 3189 |
/***/ function(module, exports, __webpack_require__) {
|
| 3190 |
|
| 3191 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
|
@@ -3200,7 +3207,7 @@ webpackJsonp([0],[
|
|
| 3200 |
|
| 3201 |
|
| 3202 |
/***/ },
|
| 3203 |
-
/*
|
| 3204 |
/***/ function(module, exports, __webpack_require__) {
|
| 3205 |
|
| 3206 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
|
|
@@ -3254,7 +3261,7 @@ webpackJsonp([0],[
|
|
| 3254 |
|
| 3255 |
|
| 3256 |
/***/ },
|
| 3257 |
-
/*
|
| 3258 |
/***/ function(module, exports, __webpack_require__) {
|
| 3259 |
|
| 3260 |
'use strict';
|
|
@@ -3263,11 +3270,11 @@ webpackJsonp([0],[
|
|
| 3263 |
|
| 3264 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 3265 |
|
| 3266 |
-
var _mailpoet = __webpack_require__(
|
| 3267 |
|
| 3268 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 3269 |
|
| 3270 |
-
var _jquery = __webpack_require__(
|
| 3271 |
|
| 3272 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 3273 |
|
|
@@ -3275,37 +3282,37 @@ webpackJsonp([0],[
|
|
| 3275 |
|
| 3276 |
var _react2 = _interopRequireDefault(_react);
|
| 3277 |
|
| 3278 |
-
var _underscore = __webpack_require__(
|
| 3279 |
|
| 3280 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 3281 |
|
| 3282 |
var _reactRouter = __webpack_require__(181);
|
| 3283 |
|
| 3284 |
-
var _classnames = __webpack_require__(
|
| 3285 |
|
| 3286 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 3287 |
|
| 3288 |
-
var _listingBulk_actionsJsx = __webpack_require__(
|
| 3289 |
|
| 3290 |
var _listingBulk_actionsJsx2 = _interopRequireDefault(_listingBulk_actionsJsx);
|
| 3291 |
|
| 3292 |
-
var _listingHeaderJsx = __webpack_require__(
|
| 3293 |
|
| 3294 |
var _listingHeaderJsx2 = _interopRequireDefault(_listingHeaderJsx);
|
| 3295 |
|
| 3296 |
-
var _listingPagesJsx = __webpack_require__(
|
| 3297 |
|
| 3298 |
var _listingPagesJsx2 = _interopRequireDefault(_listingPagesJsx);
|
| 3299 |
|
| 3300 |
-
var _listingSearchJsx = __webpack_require__(
|
| 3301 |
|
| 3302 |
var _listingSearchJsx2 = _interopRequireDefault(_listingSearchJsx);
|
| 3303 |
|
| 3304 |
-
var _listingGroupsJsx = __webpack_require__(
|
| 3305 |
|
| 3306 |
var _listingGroupsJsx2 = _interopRequireDefault(_listingGroupsJsx);
|
| 3307 |
|
| 3308 |
-
var _listingFiltersJsx = __webpack_require__(
|
| 3309 |
|
| 3310 |
var _listingFiltersJsx2 = _interopRequireDefault(_listingFiltersJsx);
|
| 3311 |
|
|
@@ -4175,14 +4182,14 @@ webpackJsonp([0],[
|
|
| 4175 |
module.exports = Listing;
|
| 4176 |
|
| 4177 |
/***/ },
|
| 4178 |
-
/*
|
| 4179 |
/***/ function(module, exports, __webpack_require__) {
|
| 4180 |
|
| 4181 |
-
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["_"] = __webpack_require__(
|
| 4182 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 4183 |
|
| 4184 |
/***/ },
|
| 4185 |
-
/*
|
| 4186 |
/***/ function(module, exports, __webpack_require__) {
|
| 4187 |
|
| 4188 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Underscore.js 1.8.3
|
|
@@ -5736,12 +5743,12 @@ webpackJsonp([0],[
|
|
| 5736 |
|
| 5737 |
|
| 5738 |
/***/ },
|
| 5739 |
-
/*
|
| 5740 |
/***/ function(module, exports, __webpack_require__) {
|
| 5741 |
|
| 5742 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 5743 |
|
| 5744 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 5745 |
var ListingBulkActions = React.createClass({
|
| 5746 |
displayName: 'ListingBulkActions',
|
| 5747 |
|
|
@@ -5864,14 +5871,14 @@ webpackJsonp([0],[
|
|
| 5864 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 5865 |
|
| 5866 |
/***/ },
|
| 5867 |
-
/*
|
| 5868 |
/***/ function(module, exports, __webpack_require__) {
|
| 5869 |
|
| 5870 |
'use strict';
|
| 5871 |
|
| 5872 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 5873 |
|
| 5874 |
-
var _mailpoet = __webpack_require__(
|
| 5875 |
|
| 5876 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 5877 |
|
|
@@ -5879,7 +5886,7 @@ webpackJsonp([0],[
|
|
| 5879 |
|
| 5880 |
var _react2 = _interopRequireDefault(_react);
|
| 5881 |
|
| 5882 |
-
var _classnames = __webpack_require__(
|
| 5883 |
|
| 5884 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 5885 |
|
|
@@ -5972,12 +5979,12 @@ webpackJsonp([0],[
|
|
| 5972 |
module.exports = ListingHeader;
|
| 5973 |
|
| 5974 |
/***/ },
|
| 5975 |
-
/*
|
| 5976 |
/***/ function(module, exports, __webpack_require__) {
|
| 5977 |
|
| 5978 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 5979 |
|
| 5980 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 5981 |
|
| 5982 |
var ListingPages = React.createClass({
|
| 5983 |
displayName: 'ListingPages',
|
|
@@ -6204,12 +6211,12 @@ webpackJsonp([0],[
|
|
| 6204 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6205 |
|
| 6206 |
/***/ },
|
| 6207 |
-
/*
|
| 6208 |
/***/ function(module, exports, __webpack_require__) {
|
| 6209 |
|
| 6210 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6211 |
|
| 6212 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 6213 |
|
| 6214 |
var ListingSearch = React.createClass({
|
| 6215 |
displayName: 'ListingSearch',
|
|
@@ -6256,12 +6263,12 @@ webpackJsonp([0],[
|
|
| 6256 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6257 |
|
| 6258 |
/***/ },
|
| 6259 |
-
/*
|
| 6260 |
/***/ function(module, exports, __webpack_require__) {
|
| 6261 |
|
| 6262 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6263 |
|
| 6264 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 6265 |
|
| 6266 |
var ListingGroups = React.createClass({
|
| 6267 |
displayName: 'ListingGroups',
|
|
@@ -6312,12 +6319,12 @@ webpackJsonp([0],[
|
|
| 6312 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6313 |
|
| 6314 |
/***/ },
|
| 6315 |
-
/*
|
| 6316 |
/***/ function(module, exports, __webpack_require__) {
|
| 6317 |
|
| 6318 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6319 |
|
| 6320 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 6321 |
var ListingFilters = React.createClass({
|
| 6322 |
displayName: 'ListingFilters',
|
| 6323 |
|
|
@@ -6405,14 +6412,14 @@ webpackJsonp([0],[
|
|
| 6405 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6406 |
|
| 6407 |
/***/ },
|
| 6408 |
-
/*
|
| 6409 |
/***/ function(module, exports, __webpack_require__) {
|
| 6410 |
|
| 6411 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6412 |
|
| 6413 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 6414 |
|
| 6415 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(34), __webpack_require__(
|
| 6416 |
var Selection = React.createClass({
|
| 6417 |
displayName: 'Selection',
|
| 6418 |
|
|
@@ -6596,7 +6603,7 @@ webpackJsonp([0],[
|
|
| 6596 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6597 |
|
| 6598 |
/***/ },
|
| 6599 |
-
/*
|
| 6600 |
/***/ function(module, exports, __webpack_require__) {
|
| 6601 |
|
| 6602 |
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;var require;var require;/*!
|
|
@@ -6609,7 +6616,7 @@ webpackJsonp([0],[
|
|
| 6609 |
(function (factory) {
|
| 6610 |
if (true) {
|
| 6611 |
// AMD. Register as an anonymous module.
|
| 6612 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 6613 |
} else if (typeof exports === 'object') {
|
| 6614 |
// Node/CommonJS
|
| 6615 |
factory(require('jquery'));
|
|
@@ -12327,12 +12334,12 @@ webpackJsonp([0],[
|
|
| 12327 |
|
| 12328 |
|
| 12329 |
/***/ },
|
| 12330 |
-
/*
|
| 12331 |
/***/ function(module, exports, __webpack_require__) {
|
| 12332 |
|
| 12333 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12334 |
|
| 12335 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(
|
| 12336 |
var fields = [{
|
| 12337 |
name: 'email',
|
| 12338 |
label: MailPoet.I18n.t('email'),
|
|
@@ -12521,12 +12528,12 @@ webpackJsonp([0],[
|
|
| 12521 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12522 |
|
| 12523 |
/***/ },
|
| 12524 |
-
/*
|
| 12525 |
/***/ function(module, exports, __webpack_require__) {
|
| 12526 |
|
| 12527 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12528 |
|
| 12529 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 12530 |
|
| 12531 |
var Form = React.createClass({
|
| 12532 |
displayName: 'Form',
|
|
@@ -12746,12 +12753,12 @@ webpackJsonp([0],[
|
|
| 12746 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12747 |
|
| 12748 |
/***/ },
|
| 12749 |
-
/*
|
| 12750 |
/***/ function(module, exports, __webpack_require__) {
|
| 12751 |
|
| 12752 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12753 |
|
| 12754 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 12755 |
var FormField = React.createClass({
|
| 12756 |
displayName: 'FormField',
|
| 12757 |
|
|
@@ -12876,7 +12883,7 @@ webpackJsonp([0],[
|
|
| 12876 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12877 |
|
| 12878 |
/***/ },
|
| 12879 |
-
/*
|
| 12880 |
/***/ function(module, exports, __webpack_require__) {
|
| 12881 |
|
| 12882 |
'use strict';
|
|
@@ -12915,7 +12922,7 @@ webpackJsonp([0],[
|
|
| 12915 |
module.exports = FormFieldText;
|
| 12916 |
|
| 12917 |
/***/ },
|
| 12918 |
-
/*
|
| 12919 |
/***/ function(module, exports, __webpack_require__) {
|
| 12920 |
|
| 12921 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;"use strict";
|
|
@@ -12944,7 +12951,7 @@ webpackJsonp([0],[
|
|
| 12944 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12945 |
|
| 12946 |
/***/ },
|
| 12947 |
-
/*
|
| 12948 |
/***/ function(module, exports, __webpack_require__) {
|
| 12949 |
|
| 12950 |
'use strict';
|
|
@@ -12957,7 +12964,7 @@ webpackJsonp([0],[
|
|
| 12957 |
|
| 12958 |
var _react2 = _interopRequireDefault(_react);
|
| 12959 |
|
| 12960 |
-
var _underscore = __webpack_require__(
|
| 12961 |
|
| 12962 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 12963 |
|
|
@@ -13036,7 +13043,7 @@ webpackJsonp([0],[
|
|
| 13036 |
module.exports = FormFieldSelect;
|
| 13037 |
|
| 13038 |
/***/ },
|
| 13039 |
-
/*
|
| 13040 |
/***/ function(module, exports, __webpack_require__) {
|
| 13041 |
|
| 13042 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
|
@@ -13083,7 +13090,7 @@ webpackJsonp([0],[
|
|
| 13083 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13084 |
|
| 13085 |
/***/ },
|
| 13086 |
-
/*
|
| 13087 |
/***/ function(module, exports, __webpack_require__) {
|
| 13088 |
|
| 13089 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
|
@@ -13138,7 +13145,7 @@ webpackJsonp([0],[
|
|
| 13138 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13139 |
|
| 13140 |
/***/ },
|
| 13141 |
-
/*
|
| 13142 |
/***/ function(module, exports, __webpack_require__) {
|
| 13143 |
|
| 13144 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
|
@@ -13153,7 +13160,7 @@ webpackJsonp([0],[
|
|
| 13153 |
|
| 13154 |
function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
|
| 13155 |
|
| 13156 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 13157 |
var FormFieldDateYear = (function (_React$Component) {
|
| 13158 |
_inherits(FormFieldDateYear, _React$Component);
|
| 13159 |
|
|
@@ -13470,11 +13477,11 @@ webpackJsonp([0],[
|
|
| 13470 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13471 |
|
| 13472 |
/***/ },
|
| 13473 |
-
/*
|
| 13474 |
/***/ function(module, exports, __webpack_require__) {
|
| 13475 |
|
| 13476 |
/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
|
| 13477 |
-
//! version : 2.
|
| 13478 |
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
| 13479 |
//! license : MIT
|
| 13480 |
//! momentjs.com
|
|
@@ -13516,6 +13523,10 @@ webpackJsonp([0],[
|
|
| 13516 |
return true;
|
| 13517 |
}
|
| 13518 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13519 |
function isNumber(input) {
|
| 13520 |
return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';
|
| 13521 |
}
|
|
@@ -13572,7 +13583,9 @@ webpackJsonp([0],[
|
|
| 13572 |
userInvalidated : false,
|
| 13573 |
iso : false,
|
| 13574 |
parsedDateParts : [],
|
| 13575 |
-
meridiem : null
|
|
|
|
|
|
|
| 13576 |
};
|
| 13577 |
}
|
| 13578 |
|
|
@@ -13648,10 +13661,6 @@ webpackJsonp([0],[
|
|
| 13648 |
return m;
|
| 13649 |
}
|
| 13650 |
|
| 13651 |
-
function isUndefined(input) {
|
| 13652 |
-
return input === void 0;
|
| 13653 |
-
}
|
| 13654 |
-
|
| 13655 |
// Plugins that add properties should also add the key here (null value),
|
| 13656 |
// so we can properly clone ourselves.
|
| 13657 |
var momentProperties = hooks.momentProperties = [];
|
|
@@ -13691,7 +13700,7 @@ webpackJsonp([0],[
|
|
| 13691 |
}
|
| 13692 |
|
| 13693 |
if (momentProperties.length > 0) {
|
| 13694 |
-
for (i
|
| 13695 |
prop = momentProperties[i];
|
| 13696 |
val = from[prop];
|
| 13697 |
if (!isUndefined(val)) {
|
|
@@ -13828,8 +13837,11 @@ webpackJsonp([0],[
|
|
| 13828 |
}
|
| 13829 |
this._config = config;
|
| 13830 |
// Lenient ordinal parsing accepts just a number in addition to
|
| 13831 |
-
// number + (possibly) stuff coming from
|
| 13832 |
-
|
|
|
|
|
|
|
|
|
|
| 13833 |
}
|
| 13834 |
|
| 13835 |
function mergeConfigs(parentConfig, childConfig) {
|
|
@@ -13927,7 +13939,7 @@ webpackJsonp([0],[
|
|
| 13927 |
}
|
| 13928 |
|
| 13929 |
var defaultOrdinal = '%d';
|
| 13930 |
-
var
|
| 13931 |
|
| 13932 |
function ordinal (number) {
|
| 13933 |
return this._ordinal.replace('%d', number);
|
|
@@ -13937,6 +13949,7 @@ webpackJsonp([0],[
|
|
| 13937 |
future : 'in %s',
|
| 13938 |
past : '%s ago',
|
| 13939 |
s : 'a few seconds',
|
|
|
|
| 13940 |
m : 'a minute',
|
| 13941 |
mm : '%d minutes',
|
| 13942 |
h : 'an hour',
|
|
@@ -14119,7 +14132,7 @@ webpackJsonp([0],[
|
|
| 14119 |
return function (mom) {
|
| 14120 |
var output = '', i;
|
| 14121 |
for (i = 0; i < length; i++) {
|
| 14122 |
-
output += array[i]
|
| 14123 |
}
|
| 14124 |
return output;
|
| 14125 |
};
|
|
@@ -14322,7 +14335,8 @@ webpackJsonp([0],[
|
|
| 14322 |
var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
|
| 14323 |
function localeMonths (m, format) {
|
| 14324 |
if (!m) {
|
| 14325 |
-
return this._months
|
|
|
|
| 14326 |
}
|
| 14327 |
return isArray(this._months) ? this._months[m.month()] :
|
| 14328 |
this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];
|
|
@@ -14331,7 +14345,8 @@ webpackJsonp([0],[
|
|
| 14331 |
var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
|
| 14332 |
function localeMonthsShort (m, format) {
|
| 14333 |
if (!m) {
|
| 14334 |
-
return this._monthsShort
|
|
|
|
| 14335 |
}
|
| 14336 |
return isArray(this._monthsShort) ? this._monthsShort[m.month()] :
|
| 14337 |
this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];
|
|
@@ -14598,11 +14613,11 @@ webpackJsonp([0],[
|
|
| 14598 |
}
|
| 14599 |
|
| 14600 |
function createDate (y, m, d, h, M, s, ms) {
|
| 14601 |
-
//can't just apply() to create a date:
|
| 14602 |
-
//
|
| 14603 |
var date = new Date(y, m, d, h, M, s, ms);
|
| 14604 |
|
| 14605 |
-
//the date constructor remaps years 0-99 to 1900-1999
|
| 14606 |
if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
|
| 14607 |
date.setFullYear(y);
|
| 14608 |
}
|
|
@@ -14612,7 +14627,7 @@ webpackJsonp([0],[
|
|
| 14612 |
function createUTCDate (y) {
|
| 14613 |
var date = new Date(Date.UTC.apply(null, arguments));
|
| 14614 |
|
| 14615 |
-
//the Date.UTC function remaps years 0-99 to 1900-1999
|
| 14616 |
if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
|
| 14617 |
date.setUTCFullYear(y);
|
| 14618 |
}
|
|
@@ -14629,7 +14644,7 @@ webpackJsonp([0],[
|
|
| 14629 |
return -fwdlw + fwd - 1;
|
| 14630 |
}
|
| 14631 |
|
| 14632 |
-
//
|
| 14633 |
function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
|
| 14634 |
var localWeekday = (7 + weekday - dow) % 7,
|
| 14635 |
weekOffset = firstWeekOffset(year, dow, doy),
|
|
@@ -14830,7 +14845,8 @@ webpackJsonp([0],[
|
|
| 14830 |
var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
|
| 14831 |
function localeWeekdays (m, format) {
|
| 14832 |
if (!m) {
|
| 14833 |
-
return this._weekdays
|
|
|
|
| 14834 |
}
|
| 14835 |
return isArray(this._weekdays) ? this._weekdays[m.day()] :
|
| 14836 |
this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
|
|
@@ -15150,8 +15166,10 @@ webpackJsonp([0],[
|
|
| 15150 |
addRegexToken('A', matchMeridiem);
|
| 15151 |
addRegexToken('H', match1to2);
|
| 15152 |
addRegexToken('h', match1to2);
|
|
|
|
| 15153 |
addRegexToken('HH', match1to2, match2);
|
| 15154 |
addRegexToken('hh', match1to2, match2);
|
|
|
|
| 15155 |
|
| 15156 |
addRegexToken('hmm', match3to4);
|
| 15157 |
addRegexToken('hmmss', match5to6);
|
|
@@ -15159,6 +15177,10 @@ webpackJsonp([0],[
|
|
| 15159 |
addRegexToken('Hmmss', match5to6);
|
| 15160 |
|
| 15161 |
addParseToken(['H', 'HH'], HOUR);
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15162 |
addParseToken(['a', 'A'], function (input, array, config) {
|
| 15163 |
config._isPm = config._locale.isPM(input);
|
| 15164 |
config._meridiem = input;
|
|
@@ -15229,7 +15251,7 @@ webpackJsonp([0],[
|
|
| 15229 |
longDateFormat: defaultLongDateFormat,
|
| 15230 |
invalidDate: defaultInvalidDate,
|
| 15231 |
ordinal: defaultOrdinal,
|
| 15232 |
-
|
| 15233 |
relativeTime: defaultRelativeTime,
|
| 15234 |
|
| 15235 |
months: defaultLocaleMonths,
|
|
@@ -15287,7 +15309,7 @@ webpackJsonp([0],[
|
|
| 15287 |
module && module.exports) {
|
| 15288 |
try {
|
| 15289 |
oldLocale = globalLocale._abbr;
|
| 15290 |
-
__webpack_require__(
|
| 15291 |
// because defineLocale currently also sets the global locale, we
|
| 15292 |
// want to undo that for lazy loaded locales
|
| 15293 |
getSetGlobalLocale(oldLocale);
|
|
@@ -15540,6 +15562,77 @@ webpackJsonp([0],[
|
|
| 15540 |
}
|
| 15541 |
}
|
| 15542 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15543 |
// date from iso format or fallback
|
| 15544 |
function configFromString(config) {
|
| 15545 |
var matched = aspNetJsonRegex.exec(config._i);
|
|
@@ -15552,13 +15645,24 @@ webpackJsonp([0],[
|
|
| 15552 |
configFromISO(config);
|
| 15553 |
if (config._isValid === false) {
|
| 15554 |
delete config._isValid;
|
| 15555 |
-
|
|
|
|
| 15556 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15557 |
}
|
| 15558 |
|
| 15559 |
hooks.createFromInputFallback = deprecate(
|
| 15560 |
-
'value provided is not in a recognized ISO format. moment construction falls back to js Date(), ' +
|
| 15561 |
-
'which is not reliable across all browsers and versions. Non ISO date formats are ' +
|
| 15562 |
'discouraged and will be removed in an upcoming major release. Please refer to ' +
|
| 15563 |
'http://momentjs.com/guides/#/warnings/js-date/ for more info.',
|
| 15564 |
function (config) {
|
|
@@ -15605,10 +15709,10 @@ webpackJsonp([0],[
|
|
| 15605 |
}
|
| 15606 |
|
| 15607 |
//if the day of the year is set, figure out what it is
|
| 15608 |
-
if (config._dayOfYear) {
|
| 15609 |
yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
|
| 15610 |
|
| 15611 |
-
if (config._dayOfYear > daysInYear(yearToUse)) {
|
| 15612 |
getParsingFlags(config)._overflowDayOfYear = true;
|
| 15613 |
}
|
| 15614 |
|
|
@@ -15712,6 +15816,9 @@ webpackJsonp([0],[
|
|
| 15712 |
// constant that refers to the ISO standard
|
| 15713 |
hooks.ISO_8601 = function () {};
|
| 15714 |
|
|
|
|
|
|
|
|
|
|
| 15715 |
// date from string and format string
|
| 15716 |
function configFromStringAndFormat(config) {
|
| 15717 |
// TODO: Move this to another part of the creation flow to prevent circular deps
|
|
@@ -15719,7 +15826,10 @@ webpackJsonp([0],[
|
|
| 15719 |
configFromISO(config);
|
| 15720 |
return;
|
| 15721 |
}
|
| 15722 |
-
|
|
|
|
|
|
|
|
|
|
| 15723 |
config._a = [];
|
| 15724 |
getParsingFlags(config).empty = true;
|
| 15725 |
|
|
@@ -15911,7 +16021,7 @@ webpackJsonp([0],[
|
|
| 15911 |
|
| 15912 |
function configFromInput(config) {
|
| 15913 |
var input = config._i;
|
| 15914 |
-
if (input
|
| 15915 |
config._d = new Date(hooks.now());
|
| 15916 |
} else if (isDate(input)) {
|
| 15917 |
config._d = new Date(input.valueOf());
|
|
@@ -15922,7 +16032,7 @@ webpackJsonp([0],[
|
|
| 15922 |
return parseInt(obj, 10);
|
| 15923 |
});
|
| 15924 |
configFromArray(config);
|
| 15925 |
-
} else if (
|
| 15926 |
configFromObject(config);
|
| 15927 |
} else if (isNumber(input)) {
|
| 15928 |
// from milliseconds
|
|
@@ -16023,6 +16133,38 @@ webpackJsonp([0],[
|
|
| 16023 |
return Date.now ? Date.now() : +(new Date());
|
| 16024 |
};
|
| 16025 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16026 |
function Duration (duration) {
|
| 16027 |
var normalizedInput = normalizeObjectUnits(duration),
|
| 16028 |
years = normalizedInput.year || 0,
|
|
@@ -16035,6 +16177,8 @@ webpackJsonp([0],[
|
|
| 16035 |
seconds = normalizedInput.second || 0,
|
| 16036 |
milliseconds = normalizedInput.millisecond || 0;
|
| 16037 |
|
|
|
|
|
|
|
| 16038 |
// representation for dateAddRemove
|
| 16039 |
this._milliseconds = +milliseconds +
|
| 16040 |
seconds * 1e3 + // 1000
|
|
@@ -16158,7 +16302,7 @@ webpackJsonp([0],[
|
|
| 16158 |
// a second time. In case it wants us to change the offset again
|
| 16159 |
// _changeInProgress == true case, then we have to adjust, because
|
| 16160 |
// there is no such time in the given timezone.
|
| 16161 |
-
function getSetOffset (input, keepLocalTime) {
|
| 16162 |
var offset = this._offset || 0,
|
| 16163 |
localAdjust;
|
| 16164 |
if (!this.isValid()) {
|
|
@@ -16170,7 +16314,7 @@ webpackJsonp([0],[
|
|
| 16170 |
if (input === null) {
|
| 16171 |
return this;
|
| 16172 |
}
|
| 16173 |
-
} else if (Math.abs(input) < 16) {
|
| 16174 |
input = input * 60;
|
| 16175 |
}
|
| 16176 |
if (!this._isUTC && keepLocalTime) {
|
|
@@ -16228,7 +16372,7 @@ webpackJsonp([0],[
|
|
| 16228 |
|
| 16229 |
function setOffsetToParsedOffset () {
|
| 16230 |
if (this._tzm != null) {
|
| 16231 |
-
this.utcOffset(this._tzm);
|
| 16232 |
} else if (typeof this._i === 'string') {
|
| 16233 |
var tZone = offsetFromString(matchOffset, this._i);
|
| 16234 |
if (tZone != null) {
|
|
@@ -16360,6 +16504,7 @@ webpackJsonp([0],[
|
|
| 16360 |
}
|
| 16361 |
|
| 16362 |
createDuration.fn = Duration.prototype;
|
|
|
|
| 16363 |
|
| 16364 |
function parseIso (inp, sign) {
|
| 16365 |
// We'd normally use ~~inp for this, but unfortunately it also
|
|
@@ -16596,18 +16741,19 @@ webpackJsonp([0],[
|
|
| 16596 |
return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
|
| 16597 |
}
|
| 16598 |
|
| 16599 |
-
function toISOString
|
|
|
|
|
|
|
|
|
|
| 16600 |
var m = this.clone().utc();
|
| 16601 |
-
if (
|
| 16602 |
-
if (isFunction(Date.prototype.toISOString)) {
|
| 16603 |
-
// native implementation is ~50x faster, use it when we can
|
| 16604 |
-
return this.toDate().toISOString();
|
| 16605 |
-
} else {
|
| 16606 |
-
return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 16607 |
-
}
|
| 16608 |
-
} else {
|
| 16609 |
return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 16610 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16611 |
}
|
| 16612 |
|
| 16613 |
/**
|
|
@@ -16627,7 +16773,7 @@ webpackJsonp([0],[
|
|
| 16627 |
zone = 'Z';
|
| 16628 |
}
|
| 16629 |
var prefix = '[' + func + '("]';
|
| 16630 |
-
var year = (0
|
| 16631 |
var datetime = '-MM-DD[T]HH:mm:ss.SSS';
|
| 16632 |
var suffix = zone + '[")]';
|
| 16633 |
|
|
@@ -16795,7 +16941,7 @@ webpackJsonp([0],[
|
|
| 16795 |
return this.isValid() ? this.toISOString() : null;
|
| 16796 |
}
|
| 16797 |
|
| 16798 |
-
function isValid$
|
| 16799 |
return isValid(this);
|
| 16800 |
}
|
| 16801 |
|
|
@@ -16955,7 +17101,10 @@ webpackJsonp([0],[
|
|
| 16955 |
addRegexToken('D', match1to2);
|
| 16956 |
addRegexToken('DD', match1to2, match2);
|
| 16957 |
addRegexToken('Do', function (isStrict, locale) {
|
| 16958 |
-
|
|
|
|
|
|
|
|
|
|
| 16959 |
});
|
| 16960 |
|
| 16961 |
addParseToken(['D', 'DD'], DATE);
|
|
@@ -17135,7 +17284,7 @@ webpackJsonp([0],[
|
|
| 17135 |
proto.isSame = isSame;
|
| 17136 |
proto.isSameOrAfter = isSameOrAfter;
|
| 17137 |
proto.isSameOrBefore = isSameOrBefore;
|
| 17138 |
-
proto.isValid = isValid$
|
| 17139 |
proto.lang = lang;
|
| 17140 |
proto.locale = locale;
|
| 17141 |
proto.localeData = localeData;
|
|
@@ -17360,7 +17509,7 @@ webpackJsonp([0],[
|
|
| 17360 |
}
|
| 17361 |
|
| 17362 |
getSetGlobalLocale('en', {
|
| 17363 |
-
|
| 17364 |
ordinal : function (number) {
|
| 17365 |
var b = number % 10,
|
| 17366 |
output = (toInt(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -17481,6 +17630,9 @@ webpackJsonp([0],[
|
|
| 17481 |
}
|
| 17482 |
|
| 17483 |
function as (units) {
|
|
|
|
|
|
|
|
|
|
| 17484 |
var days;
|
| 17485 |
var months;
|
| 17486 |
var milliseconds = this._milliseconds;
|
|
@@ -17509,6 +17661,9 @@ webpackJsonp([0],[
|
|
| 17509 |
|
| 17510 |
// TODO: Use this.as('ms')?
|
| 17511 |
function valueOf$1 () {
|
|
|
|
|
|
|
|
|
|
| 17512 |
return (
|
| 17513 |
this._milliseconds +
|
| 17514 |
this._days * 864e5 +
|
|
@@ -17534,12 +17689,12 @@ webpackJsonp([0],[
|
|
| 17534 |
|
| 17535 |
function get$2 (units) {
|
| 17536 |
units = normalizeUnits(units);
|
| 17537 |
-
return this[units + 's']();
|
| 17538 |
}
|
| 17539 |
|
| 17540 |
function makeGetter(name) {
|
| 17541 |
return function () {
|
| 17542 |
-
return this._data[name];
|
| 17543 |
};
|
| 17544 |
}
|
| 17545 |
|
|
@@ -17557,11 +17712,12 @@ webpackJsonp([0],[
|
|
| 17557 |
|
| 17558 |
var round = Math.round;
|
| 17559 |
var thresholds = {
|
| 17560 |
-
|
| 17561 |
-
|
| 17562 |
-
|
| 17563 |
-
|
| 17564 |
-
|
|
|
|
| 17565 |
};
|
| 17566 |
|
| 17567 |
// helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize
|
|
@@ -17578,16 +17734,17 @@ webpackJsonp([0],[
|
|
| 17578 |
var months = round(duration.as('M'));
|
| 17579 |
var years = round(duration.as('y'));
|
| 17580 |
|
| 17581 |
-
var a = seconds
|
| 17582 |
-
|
| 17583 |
-
minutes
|
| 17584 |
-
|
| 17585 |
-
hours
|
| 17586 |
-
|
| 17587 |
-
days
|
| 17588 |
-
|
| 17589 |
-
months
|
| 17590 |
-
|
|
|
|
| 17591 |
|
| 17592 |
a[2] = withoutSuffix;
|
| 17593 |
a[3] = +posNegDuration > 0;
|
|
@@ -17616,10 +17773,17 @@ webpackJsonp([0],[
|
|
| 17616 |
return thresholds[threshold];
|
| 17617 |
}
|
| 17618 |
thresholds[threshold] = limit;
|
|
|
|
|
|
|
|
|
|
| 17619 |
return true;
|
| 17620 |
}
|
| 17621 |
|
| 17622 |
function humanize (withSuffix) {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17623 |
var locale = this.localeData();
|
| 17624 |
var output = relativeTime$1(this, !withSuffix, locale);
|
| 17625 |
|
|
@@ -17640,6 +17804,10 @@ webpackJsonp([0],[
|
|
| 17640 |
// This is because there is no context-free conversion between hours and days
|
| 17641 |
// (think of clock changes)
|
| 17642 |
// and also not between days and months (28-31 days per month)
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17643 |
var seconds = abs$1(this._milliseconds) / 1000;
|
| 17644 |
var days = abs$1(this._days);
|
| 17645 |
var months = abs$1(this._months);
|
|
@@ -17684,6 +17852,7 @@ webpackJsonp([0],[
|
|
| 17684 |
|
| 17685 |
var proto$2 = Duration.prototype;
|
| 17686 |
|
|
|
|
| 17687 |
proto$2.abs = abs;
|
| 17688 |
proto$2.add = add$1;
|
| 17689 |
proto$2.subtract = subtract$1;
|
|
@@ -17739,7 +17908,7 @@ webpackJsonp([0],[
|
|
| 17739 |
// Side effect imports
|
| 17740 |
|
| 17741 |
|
| 17742 |
-
hooks.version = '2.
|
| 17743 |
|
| 17744 |
setHookCallback(createLocal);
|
| 17745 |
|
|
@@ -17775,230 +17944,244 @@ webpackJsonp([0],[
|
|
| 17775 |
|
| 17776 |
})));
|
| 17777 |
|
| 17778 |
-
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(
|
| 17779 |
|
| 17780 |
/***/ },
|
| 17781 |
-
/*
|
| 17782 |
-
/*
|
| 17783 |
/***/ function(module, exports, __webpack_require__) {
|
| 17784 |
|
| 17785 |
var map = {
|
| 17786 |
-
"./af":
|
| 17787 |
-
"./af.js":
|
| 17788 |
-
"./ar":
|
| 17789 |
-
"./ar-dz":
|
| 17790 |
-
"./ar-dz.js":
|
| 17791 |
-
"./ar-
|
| 17792 |
-
"./ar-
|
| 17793 |
-
"./ar-
|
| 17794 |
-
"./ar-
|
| 17795 |
-
"./ar-
|
| 17796 |
-
"./ar-
|
| 17797 |
-
"./ar-
|
| 17798 |
-
"./ar-
|
| 17799 |
-
"./ar
|
| 17800 |
-
"./
|
| 17801 |
-
"./
|
| 17802 |
-
"./
|
| 17803 |
-
"./
|
| 17804 |
-
"./
|
| 17805 |
-
"./
|
| 17806 |
-
"./
|
| 17807 |
-
"./
|
| 17808 |
-
"./
|
| 17809 |
-
"./
|
| 17810 |
-
"./
|
| 17811 |
-
"./
|
| 17812 |
-
"./
|
| 17813 |
-
"./
|
| 17814 |
-
"./
|
| 17815 |
-
"./
|
| 17816 |
-
"./
|
| 17817 |
-
"./
|
| 17818 |
-
"./
|
| 17819 |
-
"./
|
| 17820 |
-
"./
|
| 17821 |
-
"./
|
| 17822 |
-
"./
|
| 17823 |
-
"./
|
| 17824 |
-
"./
|
| 17825 |
-
"./
|
| 17826 |
-
"./de
|
| 17827 |
-
"./de
|
| 17828 |
-
"./
|
| 17829 |
-
"./
|
| 17830 |
-
"./
|
| 17831 |
-
"./
|
| 17832 |
-
"./
|
| 17833 |
-
"./
|
| 17834 |
-
"./
|
| 17835 |
-
"./
|
| 17836 |
-
"./en-
|
| 17837 |
-
"./en-
|
| 17838 |
-
"./en-
|
| 17839 |
-
"./en-
|
| 17840 |
-
"./en-
|
| 17841 |
-
"./en-
|
| 17842 |
-
"./
|
| 17843 |
-
"./
|
| 17844 |
-
"./
|
| 17845 |
-
"./
|
| 17846 |
-
"./
|
| 17847 |
-
"./
|
| 17848 |
-
"./
|
| 17849 |
-
"./
|
| 17850 |
-
"./
|
| 17851 |
-
"./
|
| 17852 |
-
"./
|
| 17853 |
-
"./
|
| 17854 |
-
"./
|
| 17855 |
-
"./
|
| 17856 |
-
"./
|
| 17857 |
-
"./
|
| 17858 |
-
"./
|
| 17859 |
-
"./
|
| 17860 |
-
"./
|
| 17861 |
-
"./
|
| 17862 |
-
"./fr
|
| 17863 |
-
"./fr
|
| 17864 |
-
"./
|
| 17865 |
-
"./
|
| 17866 |
-
"./
|
| 17867 |
-
"./
|
| 17868 |
-
"./
|
| 17869 |
-
"./
|
| 17870 |
-
"./
|
| 17871 |
-
"./
|
| 17872 |
-
"./
|
| 17873 |
-
"./
|
| 17874 |
-
"./
|
| 17875 |
-
"./
|
| 17876 |
-
"./
|
| 17877 |
-
"./
|
| 17878 |
-
"./
|
| 17879 |
-
"./
|
| 17880 |
-
"./
|
| 17881 |
-
"./
|
| 17882 |
-
"./
|
| 17883 |
-
"./
|
| 17884 |
-
"./
|
| 17885 |
-
"./
|
| 17886 |
-
"./
|
| 17887 |
-
"./
|
| 17888 |
-
"./
|
| 17889 |
-
"./
|
| 17890 |
-
"./
|
| 17891 |
-
"./
|
| 17892 |
-
"./
|
| 17893 |
-
"./
|
| 17894 |
-
"./
|
| 17895 |
-
"./
|
| 17896 |
-
"./
|
| 17897 |
-
"./
|
| 17898 |
-
"./
|
| 17899 |
-
"./
|
| 17900 |
-
"./
|
| 17901 |
-
"./
|
| 17902 |
-
"./
|
| 17903 |
-
"./
|
| 17904 |
-
"./
|
| 17905 |
-
"./
|
| 17906 |
-
"./
|
| 17907 |
-
"./
|
| 17908 |
-
"./
|
| 17909 |
-
"./
|
| 17910 |
-
"./
|
| 17911 |
-
"./
|
| 17912 |
-
"./
|
| 17913 |
-
"./
|
| 17914 |
-
"./
|
| 17915 |
-
"./
|
| 17916 |
-
"./
|
| 17917 |
-
"./
|
| 17918 |
-
"./
|
| 17919 |
-
"./
|
| 17920 |
-
"./
|
| 17921 |
-
"./
|
| 17922 |
-
"./
|
| 17923 |
-
"./
|
| 17924 |
-
"./
|
| 17925 |
-
"./
|
| 17926 |
-
"./
|
| 17927 |
-
"./
|
| 17928 |
-
"./
|
| 17929 |
-
"./
|
| 17930 |
-
"./
|
| 17931 |
-
"./
|
| 17932 |
-
"./
|
| 17933 |
-
"./
|
| 17934 |
-
"./
|
| 17935 |
-
"./
|
| 17936 |
-
"./
|
| 17937 |
-
"./
|
| 17938 |
-
"./
|
| 17939 |
-
"./
|
| 17940 |
-
"./
|
| 17941 |
-
"./
|
| 17942 |
-
"./
|
| 17943 |
-
"./
|
| 17944 |
-
"./
|
| 17945 |
-
"./
|
| 17946 |
-
"./
|
| 17947 |
-
"./
|
| 17948 |
-
"./
|
| 17949 |
-
"./
|
| 17950 |
-
"./
|
| 17951 |
-
"./
|
| 17952 |
-
"./
|
| 17953 |
-
"./
|
| 17954 |
-
"./
|
| 17955 |
-
"./
|
| 17956 |
-
"./
|
| 17957 |
-
"./
|
| 17958 |
-
"./
|
| 17959 |
-
"./
|
| 17960 |
-
"./
|
| 17961 |
-
"./
|
| 17962 |
-
"./
|
| 17963 |
-
"./
|
| 17964 |
-
"./
|
| 17965 |
-
"./
|
| 17966 |
-
"./
|
| 17967 |
-
"./
|
| 17968 |
-
"./
|
| 17969 |
-
"./
|
| 17970 |
-
"./
|
| 17971 |
-
"./
|
| 17972 |
-
"./
|
| 17973 |
-
"./
|
| 17974 |
-
"./
|
| 17975 |
-
"./
|
| 17976 |
-
"./
|
| 17977 |
-
"./
|
| 17978 |
-
"./
|
| 17979 |
-
"./
|
| 17980 |
-
"./
|
| 17981 |
-
"./
|
| 17982 |
-
"./
|
| 17983 |
-
"./
|
| 17984 |
-
"./
|
| 17985 |
-
"./
|
| 17986 |
-
"./
|
| 17987 |
-
"./
|
| 17988 |
-
"./
|
| 17989 |
-
"./
|
| 17990 |
-
"./
|
| 17991 |
-
"./
|
| 17992 |
-
"./
|
| 17993 |
-
"./
|
| 17994 |
-
"./
|
| 17995 |
-
"./
|
| 17996 |
-
"./
|
| 17997 |
-
"./
|
| 17998 |
-
"./
|
| 17999 |
-
"./
|
| 18000 |
-
"./
|
| 18001 |
-
"./
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18002 |
};
|
| 18003 |
function webpackContext(req) {
|
| 18004 |
return __webpack_require__(webpackContextResolve(req));
|
|
@@ -18011,11 +18194,11 @@ webpackJsonp([0],[
|
|
| 18011 |
};
|
| 18012 |
webpackContext.resolve = webpackContextResolve;
|
| 18013 |
module.exports = webpackContext;
|
| 18014 |
-
webpackContext.id =
|
| 18015 |
|
| 18016 |
|
| 18017 |
/***/ },
|
| 18018 |
-
/*
|
| 18019 |
/***/ function(module, exports, __webpack_require__) {
|
| 18020 |
|
| 18021 |
//! moment.js locale configuration
|
|
@@ -18023,7 +18206,7 @@ webpackJsonp([0],[
|
|
| 18023 |
//! author : Werner Mollentze : https://github.com/wernerm
|
| 18024 |
|
| 18025 |
;(function (global, factory) {
|
| 18026 |
-
true ? factory(__webpack_require__(
|
| 18027 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18028 |
factory(global.moment)
|
| 18029 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18077,7 +18260,7 @@ webpackJsonp([0],[
|
|
| 18077 |
y : '\'n jaar',
|
| 18078 |
yy : '%d jaar'
|
| 18079 |
},
|
| 18080 |
-
|
| 18081 |
ordinal : function (number) {
|
| 18082 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de'); // Thanks to Joris Röling : https://github.com/jjupiter
|
| 18083 |
},
|
|
@@ -18093,7 +18276,7 @@ webpackJsonp([0],[
|
|
| 18093 |
|
| 18094 |
|
| 18095 |
/***/ },
|
| 18096 |
-
/*
|
| 18097 |
/***/ function(module, exports, __webpack_require__) {
|
| 18098 |
|
| 18099 |
//! moment.js locale configuration
|
|
@@ -18103,7 +18286,7 @@ webpackJsonp([0],[
|
|
| 18103 |
//! author : forabi https://github.com/forabi
|
| 18104 |
|
| 18105 |
;(function (global, factory) {
|
| 18106 |
-
true ? factory(__webpack_require__(
|
| 18107 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18108 |
factory(global.moment)
|
| 18109 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18240,7 +18423,7 @@ webpackJsonp([0],[
|
|
| 18240 |
|
| 18241 |
|
| 18242 |
/***/ },
|
| 18243 |
-
/*
|
| 18244 |
/***/ function(module, exports, __webpack_require__) {
|
| 18245 |
|
| 18246 |
//! moment.js locale configuration
|
|
@@ -18248,7 +18431,7 @@ webpackJsonp([0],[
|
|
| 18248 |
//! author : Noureddine LOUAHEDJ : https://github.com/noureddineme
|
| 18249 |
|
| 18250 |
;(function (global, factory) {
|
| 18251 |
-
true ? factory(__webpack_require__(
|
| 18252 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18253 |
factory(global.moment)
|
| 18254 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18304,7 +18487,71 @@ webpackJsonp([0],[
|
|
| 18304 |
|
| 18305 |
|
| 18306 |
/***/ },
|
| 18307 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18308 |
/***/ function(module, exports, __webpack_require__) {
|
| 18309 |
|
| 18310 |
//! moment.js locale configuration
|
|
@@ -18312,7 +18559,7 @@ webpackJsonp([0],[
|
|
| 18312 |
//! author : Ali Hmer: https://github.com/kikoanis
|
| 18313 |
|
| 18314 |
;(function (global, factory) {
|
| 18315 |
-
true ? factory(__webpack_require__(
|
| 18316 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18317 |
factory(global.moment)
|
| 18318 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18435,7 +18682,7 @@ webpackJsonp([0],[
|
|
| 18435 |
|
| 18436 |
|
| 18437 |
/***/ },
|
| 18438 |
-
/*
|
| 18439 |
/***/ function(module, exports, __webpack_require__) {
|
| 18440 |
|
| 18441 |
//! moment.js locale configuration
|
|
@@ -18444,7 +18691,7 @@ webpackJsonp([0],[
|
|
| 18444 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 18445 |
|
| 18446 |
;(function (global, factory) {
|
| 18447 |
-
true ? factory(__webpack_require__(
|
| 18448 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18449 |
factory(global.moment)
|
| 18450 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18500,7 +18747,7 @@ webpackJsonp([0],[
|
|
| 18500 |
|
| 18501 |
|
| 18502 |
/***/ },
|
| 18503 |
-
/*
|
| 18504 |
/***/ function(module, exports, __webpack_require__) {
|
| 18505 |
|
| 18506 |
//! moment.js locale configuration
|
|
@@ -18508,7 +18755,7 @@ webpackJsonp([0],[
|
|
| 18508 |
//! author : Suhail Alkowaileet : https://github.com/xsoh
|
| 18509 |
|
| 18510 |
;(function (global, factory) {
|
| 18511 |
-
true ? factory(__webpack_require__(
|
| 18512 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18513 |
factory(global.moment)
|
| 18514 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18610,7 +18857,7 @@ webpackJsonp([0],[
|
|
| 18610 |
|
| 18611 |
|
| 18612 |
/***/ },
|
| 18613 |
-
/*
|
| 18614 |
/***/ function(module, exports, __webpack_require__) {
|
| 18615 |
|
| 18616 |
//! moment.js locale configuration
|
|
@@ -18618,7 +18865,7 @@ webpackJsonp([0],[
|
|
| 18618 |
//! author : Nader Toukabri : https://github.com/naderio
|
| 18619 |
|
| 18620 |
;(function (global, factory) {
|
| 18621 |
-
true ? factory(__webpack_require__(
|
| 18622 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18623 |
factory(global.moment)
|
| 18624 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18674,7 +18921,7 @@ webpackJsonp([0],[
|
|
| 18674 |
|
| 18675 |
|
| 18676 |
/***/ },
|
| 18677 |
-
/*
|
| 18678 |
/***/ function(module, exports, __webpack_require__) {
|
| 18679 |
|
| 18680 |
//! moment.js locale configuration
|
|
@@ -18682,7 +18929,7 @@ webpackJsonp([0],[
|
|
| 18682 |
//! author : topchiyev : https://github.com/topchiyev
|
| 18683 |
|
| 18684 |
;(function (global, factory) {
|
| 18685 |
-
true ? factory(__webpack_require__(
|
| 18686 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18687 |
factory(global.moment)
|
| 18688 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18762,7 +19009,7 @@ webpackJsonp([0],[
|
|
| 18762 |
return 'axşam';
|
| 18763 |
}
|
| 18764 |
},
|
| 18765 |
-
|
| 18766 |
ordinal : function (number) {
|
| 18767 |
if (number === 0) { // special case for zero
|
| 18768 |
return number + '-ıncı';
|
|
@@ -18784,7 +19031,7 @@ webpackJsonp([0],[
|
|
| 18784 |
|
| 18785 |
|
| 18786 |
/***/ },
|
| 18787 |
-
/*
|
| 18788 |
/***/ function(module, exports, __webpack_require__) {
|
| 18789 |
|
| 18790 |
//! moment.js locale configuration
|
|
@@ -18794,7 +19041,7 @@ webpackJsonp([0],[
|
|
| 18794 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 18795 |
|
| 18796 |
;(function (global, factory) {
|
| 18797 |
-
true ? factory(__webpack_require__(
|
| 18798 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18799 |
factory(global.moment)
|
| 18800 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18896,7 +19143,7 @@ webpackJsonp([0],[
|
|
| 18896 |
return 'вечара';
|
| 18897 |
}
|
| 18898 |
},
|
| 18899 |
-
|
| 18900 |
ordinal: function (number, period) {
|
| 18901 |
switch (period) {
|
| 18902 |
case 'M':
|
|
@@ -18923,7 +19170,7 @@ webpackJsonp([0],[
|
|
| 18923 |
|
| 18924 |
|
| 18925 |
/***/ },
|
| 18926 |
-
/*
|
| 18927 |
/***/ function(module, exports, __webpack_require__) {
|
| 18928 |
|
| 18929 |
//! moment.js locale configuration
|
|
@@ -18931,7 +19178,7 @@ webpackJsonp([0],[
|
|
| 18931 |
//! author : Krasen Borisov : https://github.com/kraz
|
| 18932 |
|
| 18933 |
;(function (global, factory) {
|
| 18934 |
-
true ? factory(__webpack_require__(
|
| 18935 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18936 |
factory(global.moment)
|
| 18937 |
}(this, (function (moment) { 'use strict';
|
|
@@ -18986,7 +19233,7 @@ webpackJsonp([0],[
|
|
| 18986 |
y : 'година',
|
| 18987 |
yy : '%d години'
|
| 18988 |
},
|
| 18989 |
-
|
| 18990 |
ordinal : function (number) {
|
| 18991 |
var lastDigit = number % 10,
|
| 18992 |
last2Digits = number % 100;
|
|
@@ -19018,7 +19265,7 @@ webpackJsonp([0],[
|
|
| 19018 |
|
| 19019 |
|
| 19020 |
/***/ },
|
| 19021 |
-
/*
|
| 19022 |
/***/ function(module, exports, __webpack_require__) {
|
| 19023 |
|
| 19024 |
//! moment.js locale configuration
|
|
@@ -19026,7 +19273,7 @@ webpackJsonp([0],[
|
|
| 19026 |
//! author : Kaushik Gandhi : https://github.com/kaushikgandhi
|
| 19027 |
|
| 19028 |
;(function (global, factory) {
|
| 19029 |
-
true ? factory(__webpack_require__(
|
| 19030 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19031 |
factory(global.moment)
|
| 19032 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19142,7 +19389,7 @@ webpackJsonp([0],[
|
|
| 19142 |
|
| 19143 |
|
| 19144 |
/***/ },
|
| 19145 |
-
/*
|
| 19146 |
/***/ function(module, exports, __webpack_require__) {
|
| 19147 |
|
| 19148 |
//! moment.js locale configuration
|
|
@@ -19150,7 +19397,7 @@ webpackJsonp([0],[
|
|
| 19150 |
//! author : Thupten N. Chakrishar : https://github.com/vajradog
|
| 19151 |
|
| 19152 |
;(function (global, factory) {
|
| 19153 |
-
true ? factory(__webpack_require__(
|
| 19154 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19155 |
factory(global.moment)
|
| 19156 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19266,7 +19513,7 @@ webpackJsonp([0],[
|
|
| 19266 |
|
| 19267 |
|
| 19268 |
/***/ },
|
| 19269 |
-
/*
|
| 19270 |
/***/ function(module, exports, __webpack_require__) {
|
| 19271 |
|
| 19272 |
//! moment.js locale configuration
|
|
@@ -19274,7 +19521,7 @@ webpackJsonp([0],[
|
|
| 19274 |
//! author : Jean-Baptiste Le Duigou : https://github.com/jbleduigou
|
| 19275 |
|
| 19276 |
;(function (global, factory) {
|
| 19277 |
-
true ? factory(__webpack_require__(
|
| 19278 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19279 |
factory(global.moment)
|
| 19280 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19362,7 +19609,7 @@ webpackJsonp([0],[
|
|
| 19362 |
y : 'ur bloaz',
|
| 19363 |
yy : specialMutationForYears
|
| 19364 |
},
|
| 19365 |
-
|
| 19366 |
ordinal : function (number) {
|
| 19367 |
var output = (number === 1) ? 'añ' : 'vet';
|
| 19368 |
return number + output;
|
|
@@ -19379,7 +19626,7 @@ webpackJsonp([0],[
|
|
| 19379 |
|
| 19380 |
|
| 19381 |
/***/ },
|
| 19382 |
-
/*
|
| 19383 |
/***/ function(module, exports, __webpack_require__) {
|
| 19384 |
|
| 19385 |
//! moment.js locale configuration
|
|
@@ -19388,7 +19635,7 @@ webpackJsonp([0],[
|
|
| 19388 |
//! based on (hr) translation by Bojan Marković
|
| 19389 |
|
| 19390 |
;(function (global, factory) {
|
| 19391 |
-
true ? factory(__webpack_require__(
|
| 19392 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19393 |
factory(global.moment)
|
| 19394 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19513,7 +19760,7 @@ webpackJsonp([0],[
|
|
| 19513 |
y : 'godinu',
|
| 19514 |
yy : translate
|
| 19515 |
},
|
| 19516 |
-
|
| 19517 |
ordinal : '%d.',
|
| 19518 |
week : {
|
| 19519 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -19527,7 +19774,7 @@ webpackJsonp([0],[
|
|
| 19527 |
|
| 19528 |
|
| 19529 |
/***/ },
|
| 19530 |
-
/*
|
| 19531 |
/***/ function(module, exports, __webpack_require__) {
|
| 19532 |
|
| 19533 |
//! moment.js locale configuration
|
|
@@ -19535,15 +19782,19 @@ webpackJsonp([0],[
|
|
| 19535 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 19536 |
|
| 19537 |
;(function (global, factory) {
|
| 19538 |
-
true ? factory(__webpack_require__(
|
| 19539 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19540 |
factory(global.moment)
|
| 19541 |
}(this, (function (moment) { 'use strict';
|
| 19542 |
|
| 19543 |
|
| 19544 |
var ca = moment.defineLocale('ca', {
|
| 19545 |
-
months :
|
| 19546 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 19547 |
monthsParseExact : true,
|
| 19548 |
weekdays : 'diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte'.split('_'),
|
| 19549 |
weekdaysShort : 'dg._dl._dt._dc._dj._dv._ds.'.split('_'),
|
|
@@ -19553,9 +19804,12 @@ webpackJsonp([0],[
|
|
| 19553 |
LT : 'H:mm',
|
| 19554 |
LTS : 'H:mm:ss',
|
| 19555 |
L : 'DD/MM/YYYY',
|
| 19556 |
-
LL : 'D MMMM YYYY',
|
| 19557 |
-
|
| 19558 |
-
|
|
|
|
|
|
|
|
|
|
| 19559 |
},
|
| 19560 |
calendar : {
|
| 19561 |
sameDay : function () {
|
|
@@ -19590,7 +19844,7 @@ webpackJsonp([0],[
|
|
| 19590 |
y : 'un any',
|
| 19591 |
yy : '%d anys'
|
| 19592 |
},
|
| 19593 |
-
|
| 19594 |
ordinal : function (number, period) {
|
| 19595 |
var output = (number === 1) ? 'r' :
|
| 19596 |
(number === 2) ? 'n' :
|
|
@@ -19613,7 +19867,7 @@ webpackJsonp([0],[
|
|
| 19613 |
|
| 19614 |
|
| 19615 |
/***/ },
|
| 19616 |
-
/*
|
| 19617 |
/***/ function(module, exports, __webpack_require__) {
|
| 19618 |
|
| 19619 |
//! moment.js locale configuration
|
|
@@ -19621,7 +19875,7 @@ webpackJsonp([0],[
|
|
| 19621 |
//! author : petrbela : https://github.com/petrbela
|
| 19622 |
|
| 19623 |
;(function (global, factory) {
|
| 19624 |
-
true ? factory(__webpack_require__(
|
| 19625 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19626 |
factory(global.moment)
|
| 19627 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19776,7 +20030,7 @@ webpackJsonp([0],[
|
|
| 19776 |
y : translate,
|
| 19777 |
yy : translate
|
| 19778 |
},
|
| 19779 |
-
|
| 19780 |
ordinal : '%d.',
|
| 19781 |
week : {
|
| 19782 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -19790,7 +20044,7 @@ webpackJsonp([0],[
|
|
| 19790 |
|
| 19791 |
|
| 19792 |
/***/ },
|
| 19793 |
-
/*
|
| 19794 |
/***/ function(module, exports, __webpack_require__) {
|
| 19795 |
|
| 19796 |
//! moment.js locale configuration
|
|
@@ -19798,7 +20052,7 @@ webpackJsonp([0],[
|
|
| 19798 |
//! author : Anatoly Mironov : https://github.com/mirontoli
|
| 19799 |
|
| 19800 |
;(function (global, factory) {
|
| 19801 |
-
true ? factory(__webpack_require__(
|
| 19802 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19803 |
factory(global.moment)
|
| 19804 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19844,7 +20098,7 @@ webpackJsonp([0],[
|
|
| 19844 |
y : 'пӗр ҫул',
|
| 19845 |
yy : '%d ҫул'
|
| 19846 |
},
|
| 19847 |
-
|
| 19848 |
ordinal : '%d-мӗш',
|
| 19849 |
week : {
|
| 19850 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -19858,7 +20112,7 @@ webpackJsonp([0],[
|
|
| 19858 |
|
| 19859 |
|
| 19860 |
/***/ },
|
| 19861 |
-
/*
|
| 19862 |
/***/ function(module, exports, __webpack_require__) {
|
| 19863 |
|
| 19864 |
//! moment.js locale configuration
|
|
@@ -19867,7 +20121,7 @@ webpackJsonp([0],[
|
|
| 19867 |
//! author : https://github.com/ryangreaves
|
| 19868 |
|
| 19869 |
;(function (global, factory) {
|
| 19870 |
-
true ? factory(__webpack_require__(
|
| 19871 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19872 |
factory(global.moment)
|
| 19873 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19912,7 +20166,7 @@ webpackJsonp([0],[
|
|
| 19912 |
y: 'blwyddyn',
|
| 19913 |
yy: '%d flynedd'
|
| 19914 |
},
|
| 19915 |
-
|
| 19916 |
// traditional ordinal numbers above 31 are not commonly used in colloquial Welsh
|
| 19917 |
ordinal: function (number) {
|
| 19918 |
var b = number,
|
|
@@ -19944,7 +20198,7 @@ webpackJsonp([0],[
|
|
| 19944 |
|
| 19945 |
|
| 19946 |
/***/ },
|
| 19947 |
-
/*
|
| 19948 |
/***/ function(module, exports, __webpack_require__) {
|
| 19949 |
|
| 19950 |
//! moment.js locale configuration
|
|
@@ -19952,7 +20206,7 @@ webpackJsonp([0],[
|
|
| 19952 |
//! author : Ulrik Nielsen : https://github.com/mrbase
|
| 19953 |
|
| 19954 |
;(function (global, factory) {
|
| 19955 |
-
true ? factory(__webpack_require__(
|
| 19956 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19957 |
factory(global.moment)
|
| 19958 |
}(this, (function (moment) { 'use strict';
|
|
@@ -19970,14 +20224,14 @@ webpackJsonp([0],[
|
|
| 19970 |
L : 'DD/MM/YYYY',
|
| 19971 |
LL : 'D. MMMM YYYY',
|
| 19972 |
LLL : 'D. MMMM YYYY HH:mm',
|
| 19973 |
-
LLLL : 'dddd [d.] D. MMMM YYYY HH:mm'
|
| 19974 |
},
|
| 19975 |
calendar : {
|
| 19976 |
-
sameDay : '[
|
| 19977 |
-
nextDay : '[
|
| 19978 |
-
nextWeek : 'dddd [kl.] LT',
|
| 19979 |
-
lastDay : '[
|
| 19980 |
-
lastWeek : '[
|
| 19981 |
sameElse : 'L'
|
| 19982 |
},
|
| 19983 |
relativeTime : {
|
|
@@ -19995,7 +20249,7 @@ webpackJsonp([0],[
|
|
| 19995 |
y : 'et år',
|
| 19996 |
yy : '%d år'
|
| 19997 |
},
|
| 19998 |
-
|
| 19999 |
ordinal : '%d.',
|
| 20000 |
week : {
|
| 20001 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20009,7 +20263,7 @@ webpackJsonp([0],[
|
|
| 20009 |
|
| 20010 |
|
| 20011 |
/***/ },
|
| 20012 |
-
/*
|
| 20013 |
/***/ function(module, exports, __webpack_require__) {
|
| 20014 |
|
| 20015 |
//! moment.js locale configuration
|
|
@@ -20019,7 +20273,7 @@ webpackJsonp([0],[
|
|
| 20019 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 20020 |
|
| 20021 |
;(function (global, factory) {
|
| 20022 |
-
true ? factory(__webpack_require__(
|
| 20023 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20024 |
factory(global.moment)
|
| 20025 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20078,7 +20332,7 @@ webpackJsonp([0],[
|
|
| 20078 |
y : processRelativeTime,
|
| 20079 |
yy : processRelativeTime
|
| 20080 |
},
|
| 20081 |
-
|
| 20082 |
ordinal : '%d.',
|
| 20083 |
week : {
|
| 20084 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20092,7 +20346,7 @@ webpackJsonp([0],[
|
|
| 20092 |
|
| 20093 |
|
| 20094 |
/***/ },
|
| 20095 |
-
/*
|
| 20096 |
/***/ function(module, exports, __webpack_require__) {
|
| 20097 |
|
| 20098 |
//! moment.js locale configuration
|
|
@@ -20103,7 +20357,7 @@ webpackJsonp([0],[
|
|
| 20103 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 20104 |
|
| 20105 |
;(function (global, factory) {
|
| 20106 |
-
true ? factory(__webpack_require__(
|
| 20107 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20108 |
factory(global.moment)
|
| 20109 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20162,7 +20416,7 @@ webpackJsonp([0],[
|
|
| 20162 |
y : processRelativeTime,
|
| 20163 |
yy : processRelativeTime
|
| 20164 |
},
|
| 20165 |
-
|
| 20166 |
ordinal : '%d.',
|
| 20167 |
week : {
|
| 20168 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20176,7 +20430,90 @@ webpackJsonp([0],[
|
|
| 20176 |
|
| 20177 |
|
| 20178 |
/***/ },
|
| 20179 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20180 |
/***/ function(module, exports, __webpack_require__) {
|
| 20181 |
|
| 20182 |
//! moment.js locale configuration
|
|
@@ -20184,7 +20521,7 @@ webpackJsonp([0],[
|
|
| 20184 |
//! author : Jawish Hameed : https://github.com/jawish
|
| 20185 |
|
| 20186 |
;(function (global, factory) {
|
| 20187 |
-
true ? factory(__webpack_require__(
|
| 20188 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20189 |
factory(global.moment)
|
| 20190 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20281,7 +20618,7 @@ webpackJsonp([0],[
|
|
| 20281 |
|
| 20282 |
|
| 20283 |
/***/ },
|
| 20284 |
-
/*
|
| 20285 |
/***/ function(module, exports, __webpack_require__) {
|
| 20286 |
|
| 20287 |
//! moment.js locale configuration
|
|
@@ -20289,7 +20626,7 @@ webpackJsonp([0],[
|
|
| 20289 |
//! author : Aggelos Karalias : https://github.com/mehiel
|
| 20290 |
|
| 20291 |
;(function (global, factory) {
|
| 20292 |
-
true ? factory(__webpack_require__(
|
| 20293 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20294 |
factory(global.moment)
|
| 20295 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20303,7 +20640,9 @@ webpackJsonp([0],[
|
|
| 20303 |
monthsNominativeEl : 'Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος'.split('_'),
|
| 20304 |
monthsGenitiveEl : 'Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου'.split('_'),
|
| 20305 |
months : function (momentToFormat, format) {
|
| 20306 |
-
if (
|
|
|
|
|
|
|
| 20307 |
return this._monthsGenitiveEl[momentToFormat.month()];
|
| 20308 |
} else {
|
| 20309 |
return this._monthsNominativeEl[momentToFormat.month()];
|
|
@@ -20370,7 +20709,7 @@ webpackJsonp([0],[
|
|
| 20370 |
y : 'ένας χρόνος',
|
| 20371 |
yy : '%d χρόνια'
|
| 20372 |
},
|
| 20373 |
-
|
| 20374 |
ordinal: '%dη',
|
| 20375 |
week : {
|
| 20376 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20384,7 +20723,7 @@ webpackJsonp([0],[
|
|
| 20384 |
|
| 20385 |
|
| 20386 |
/***/ },
|
| 20387 |
-
/*
|
| 20388 |
/***/ function(module, exports, __webpack_require__) {
|
| 20389 |
|
| 20390 |
//! moment.js locale configuration
|
|
@@ -20392,7 +20731,7 @@ webpackJsonp([0],[
|
|
| 20392 |
//! author : Jared Morse : https://github.com/jarcoal
|
| 20393 |
|
| 20394 |
;(function (global, factory) {
|
| 20395 |
-
true ? factory(__webpack_require__(
|
| 20396 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20397 |
factory(global.moment)
|
| 20398 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20435,7 +20774,7 @@ webpackJsonp([0],[
|
|
| 20435 |
y : 'a year',
|
| 20436 |
yy : '%d years'
|
| 20437 |
},
|
| 20438 |
-
|
| 20439 |
ordinal : function (number) {
|
| 20440 |
var b = number % 10,
|
| 20441 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -20456,7 +20795,7 @@ webpackJsonp([0],[
|
|
| 20456 |
|
| 20457 |
|
| 20458 |
/***/ },
|
| 20459 |
-
/*
|
| 20460 |
/***/ function(module, exports, __webpack_require__) {
|
| 20461 |
|
| 20462 |
//! moment.js locale configuration
|
|
@@ -20464,7 +20803,7 @@ webpackJsonp([0],[
|
|
| 20464 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 20465 |
|
| 20466 |
;(function (global, factory) {
|
| 20467 |
-
true ? factory(__webpack_require__(
|
| 20468 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20469 |
factory(global.moment)
|
| 20470 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20507,7 +20846,7 @@ webpackJsonp([0],[
|
|
| 20507 |
y : 'a year',
|
| 20508 |
yy : '%d years'
|
| 20509 |
},
|
| 20510 |
-
|
| 20511 |
ordinal : function (number) {
|
| 20512 |
var b = number % 10,
|
| 20513 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -20524,7 +20863,7 @@ webpackJsonp([0],[
|
|
| 20524 |
|
| 20525 |
|
| 20526 |
/***/ },
|
| 20527 |
-
/*
|
| 20528 |
/***/ function(module, exports, __webpack_require__) {
|
| 20529 |
|
| 20530 |
//! moment.js locale configuration
|
|
@@ -20532,7 +20871,7 @@ webpackJsonp([0],[
|
|
| 20532 |
//! author : Chris Gedrim : https://github.com/chrisgedrim
|
| 20533 |
|
| 20534 |
;(function (global, factory) {
|
| 20535 |
-
true ? factory(__webpack_require__(
|
| 20536 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20537 |
factory(global.moment)
|
| 20538 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20575,7 +20914,7 @@ webpackJsonp([0],[
|
|
| 20575 |
y : 'a year',
|
| 20576 |
yy : '%d years'
|
| 20577 |
},
|
| 20578 |
-
|
| 20579 |
ordinal : function (number) {
|
| 20580 |
var b = number % 10,
|
| 20581 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -20596,7 +20935,7 @@ webpackJsonp([0],[
|
|
| 20596 |
|
| 20597 |
|
| 20598 |
/***/ },
|
| 20599 |
-
/*
|
| 20600 |
/***/ function(module, exports, __webpack_require__) {
|
| 20601 |
|
| 20602 |
//! moment.js locale configuration
|
|
@@ -20604,7 +20943,7 @@ webpackJsonp([0],[
|
|
| 20604 |
//! author : Chris Cartlidge : https://github.com/chriscartlidge
|
| 20605 |
|
| 20606 |
;(function (global, factory) {
|
| 20607 |
-
true ? factory(__webpack_require__(
|
| 20608 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20609 |
factory(global.moment)
|
| 20610 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20647,7 +20986,7 @@ webpackJsonp([0],[
|
|
| 20647 |
y : 'a year',
|
| 20648 |
yy : '%d years'
|
| 20649 |
},
|
| 20650 |
-
|
| 20651 |
ordinal : function (number) {
|
| 20652 |
var b = number % 10,
|
| 20653 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -20668,7 +21007,7 @@ webpackJsonp([0],[
|
|
| 20668 |
|
| 20669 |
|
| 20670 |
/***/ },
|
| 20671 |
-
/*
|
| 20672 |
/***/ function(module, exports, __webpack_require__) {
|
| 20673 |
|
| 20674 |
//! moment.js locale configuration
|
|
@@ -20676,7 +21015,7 @@ webpackJsonp([0],[
|
|
| 20676 |
//! author : Luke McGregor : https://github.com/lukemcgregor
|
| 20677 |
|
| 20678 |
;(function (global, factory) {
|
| 20679 |
-
true ? factory(__webpack_require__(
|
| 20680 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20681 |
factory(global.moment)
|
| 20682 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20719,7 +21058,7 @@ webpackJsonp([0],[
|
|
| 20719 |
y : 'a year',
|
| 20720 |
yy : '%d years'
|
| 20721 |
},
|
| 20722 |
-
|
| 20723 |
ordinal : function (number) {
|
| 20724 |
var b = number % 10,
|
| 20725 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -20740,17 +21079,17 @@ webpackJsonp([0],[
|
|
| 20740 |
|
| 20741 |
|
| 20742 |
/***/ },
|
| 20743 |
-
/*
|
| 20744 |
/***/ function(module, exports, __webpack_require__) {
|
| 20745 |
|
| 20746 |
//! moment.js locale configuration
|
| 20747 |
//! locale : Esperanto [eo]
|
| 20748 |
//! author : Colin Dean : https://github.com/colindean
|
| 20749 |
-
//!
|
| 20750 |
-
//!
|
| 20751 |
|
| 20752 |
;(function (global, factory) {
|
| 20753 |
-
true ? factory(__webpack_require__(
|
| 20754 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20755 |
factory(global.moment)
|
| 20756 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20759,16 +21098,16 @@ webpackJsonp([0],[
|
|
| 20759 |
var eo = moment.defineLocale('eo', {
|
| 20760 |
months : 'januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro'.split('_'),
|
| 20761 |
monthsShort : 'jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec'.split('_'),
|
| 20762 |
-
weekdays : '
|
| 20763 |
-
weekdaysShort : '
|
| 20764 |
-
weekdaysMin : '
|
| 20765 |
longDateFormat : {
|
| 20766 |
LT : 'HH:mm',
|
| 20767 |
LTS : 'HH:mm:ss',
|
| 20768 |
L : 'YYYY-MM-DD',
|
| 20769 |
-
LL : 'D[-
|
| 20770 |
-
LLL : 'D[-
|
| 20771 |
-
LLLL : 'dddd, [la] D[-
|
| 20772 |
},
|
| 20773 |
meridiemParse: /[ap]\.t\.m/i,
|
| 20774 |
isPM: function (input) {
|
|
@@ -20790,7 +21129,7 @@ webpackJsonp([0],[
|
|
| 20790 |
sameElse : 'L'
|
| 20791 |
},
|
| 20792 |
relativeTime : {
|
| 20793 |
-
future : '
|
| 20794 |
past : 'antaŭ %s',
|
| 20795 |
s : 'sekundoj',
|
| 20796 |
m : 'minuto',
|
|
@@ -20804,7 +21143,7 @@ webpackJsonp([0],[
|
|
| 20804 |
y : 'jaro',
|
| 20805 |
yy : '%d jaroj'
|
| 20806 |
},
|
| 20807 |
-
|
| 20808 |
ordinal : '%da',
|
| 20809 |
week : {
|
| 20810 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20818,7 +21157,7 @@ webpackJsonp([0],[
|
|
| 20818 |
|
| 20819 |
|
| 20820 |
/***/ },
|
| 20821 |
-
/*
|
| 20822 |
/***/ function(module, exports, __webpack_require__) {
|
| 20823 |
|
| 20824 |
//! moment.js locale configuration
|
|
@@ -20826,7 +21165,7 @@ webpackJsonp([0],[
|
|
| 20826 |
//! author : Julio Napurí : https://github.com/julionc
|
| 20827 |
|
| 20828 |
;(function (global, factory) {
|
| 20829 |
-
true ? factory(__webpack_require__(
|
| 20830 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20831 |
factory(global.moment)
|
| 20832 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20838,7 +21177,9 @@ webpackJsonp([0],[
|
|
| 20838 |
var es = moment.defineLocale('es', {
|
| 20839 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 20840 |
monthsShort : function (m, format) {
|
| 20841 |
-
if (
|
|
|
|
|
|
|
| 20842 |
return monthsShort[m.month()];
|
| 20843 |
} else {
|
| 20844 |
return monthsShortDot[m.month()];
|
|
@@ -20890,7 +21231,7 @@ webpackJsonp([0],[
|
|
| 20890 |
y : 'un año',
|
| 20891 |
yy : '%d años'
|
| 20892 |
},
|
| 20893 |
-
|
| 20894 |
ordinal : '%dº',
|
| 20895 |
week : {
|
| 20896 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20904,14 +21245,14 @@ webpackJsonp([0],[
|
|
| 20904 |
|
| 20905 |
|
| 20906 |
/***/ },
|
| 20907 |
-
/*
|
| 20908 |
/***/ function(module, exports, __webpack_require__) {
|
| 20909 |
|
| 20910 |
//! moment.js locale configuration
|
| 20911 |
//! locale : Spanish (Dominican Republic) [es-do]
|
| 20912 |
|
| 20913 |
;(function (global, factory) {
|
| 20914 |
-
true ? factory(__webpack_require__(
|
| 20915 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20916 |
factory(global.moment)
|
| 20917 |
}(this, (function (moment) { 'use strict';
|
|
@@ -20923,7 +21264,9 @@ webpackJsonp([0],[
|
|
| 20923 |
var esDo = moment.defineLocale('es-do', {
|
| 20924 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 20925 |
monthsShort : function (m, format) {
|
| 20926 |
-
if (
|
|
|
|
|
|
|
| 20927 |
return monthsShort[m.month()];
|
| 20928 |
} else {
|
| 20929 |
return monthsShortDot[m.month()];
|
|
@@ -20975,7 +21318,7 @@ webpackJsonp([0],[
|
|
| 20975 |
y : 'un año',
|
| 20976 |
yy : '%d años'
|
| 20977 |
},
|
| 20978 |
-
|
| 20979 |
ordinal : '%dº',
|
| 20980 |
week : {
|
| 20981 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -20989,7 +21332,7 @@ webpackJsonp([0],[
|
|
| 20989 |
|
| 20990 |
|
| 20991 |
/***/ },
|
| 20992 |
-
/*
|
| 20993 |
/***/ function(module, exports, __webpack_require__) {
|
| 20994 |
|
| 20995 |
//! moment.js locale configuration
|
|
@@ -20998,7 +21341,7 @@ webpackJsonp([0],[
|
|
| 20998 |
//! improvements : Illimar Tambek : https://github.com/ragulka
|
| 20999 |
|
| 21000 |
;(function (global, factory) {
|
| 21001 |
-
true ? factory(__webpack_require__(
|
| 21002 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21003 |
factory(global.moment)
|
| 21004 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21060,7 +21403,7 @@ webpackJsonp([0],[
|
|
| 21060 |
y : processRelativeTime,
|
| 21061 |
yy : processRelativeTime
|
| 21062 |
},
|
| 21063 |
-
|
| 21064 |
ordinal : '%d.',
|
| 21065 |
week : {
|
| 21066 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21074,7 +21417,7 @@ webpackJsonp([0],[
|
|
| 21074 |
|
| 21075 |
|
| 21076 |
/***/ },
|
| 21077 |
-
/*
|
| 21078 |
/***/ function(module, exports, __webpack_require__) {
|
| 21079 |
|
| 21080 |
//! moment.js locale configuration
|
|
@@ -21082,7 +21425,7 @@ webpackJsonp([0],[
|
|
| 21082 |
//! author : Eneko Illarramendi : https://github.com/eillarra
|
| 21083 |
|
| 21084 |
;(function (global, factory) {
|
| 21085 |
-
true ? factory(__webpack_require__(
|
| 21086 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21087 |
factory(global.moment)
|
| 21088 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21131,7 +21474,7 @@ webpackJsonp([0],[
|
|
| 21131 |
y : 'urte bat',
|
| 21132 |
yy : '%d urte'
|
| 21133 |
},
|
| 21134 |
-
|
| 21135 |
ordinal : '%d.',
|
| 21136 |
week : {
|
| 21137 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21145,7 +21488,7 @@ webpackJsonp([0],[
|
|
| 21145 |
|
| 21146 |
|
| 21147 |
/***/ },
|
| 21148 |
-
/*
|
| 21149 |
/***/ function(module, exports, __webpack_require__) {
|
| 21150 |
|
| 21151 |
//! moment.js locale configuration
|
|
@@ -21153,7 +21496,7 @@ webpackJsonp([0],[
|
|
| 21153 |
//! author : Ebrahim Byagowi : https://github.com/ebraminio
|
| 21154 |
|
| 21155 |
;(function (global, factory) {
|
| 21156 |
-
true ? factory(__webpack_require__(
|
| 21157 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21158 |
factory(global.moment)
|
| 21159 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21221,7 +21564,7 @@ webpackJsonp([0],[
|
|
| 21221 |
relativeTime : {
|
| 21222 |
future : 'در %s',
|
| 21223 |
past : '%s پیش',
|
| 21224 |
-
s : '
|
| 21225 |
m : 'یک دقیقه',
|
| 21226 |
mm : '%d دقیقه',
|
| 21227 |
h : 'یک ساعت',
|
|
@@ -21243,7 +21586,7 @@ webpackJsonp([0],[
|
|
| 21243 |
return symbolMap[match];
|
| 21244 |
}).replace(/,/g, '،');
|
| 21245 |
},
|
| 21246 |
-
|
| 21247 |
ordinal : '%dم',
|
| 21248 |
week : {
|
| 21249 |
dow : 6, // Saturday is the first day of the week.
|
|
@@ -21257,7 +21600,7 @@ webpackJsonp([0],[
|
|
| 21257 |
|
| 21258 |
|
| 21259 |
/***/ },
|
| 21260 |
-
/*
|
| 21261 |
/***/ function(module, exports, __webpack_require__) {
|
| 21262 |
|
| 21263 |
//! moment.js locale configuration
|
|
@@ -21265,7 +21608,7 @@ webpackJsonp([0],[
|
|
| 21265 |
//! author : Tarmo Aidantausta : https://github.com/bleadof
|
| 21266 |
|
| 21267 |
;(function (global, factory) {
|
| 21268 |
-
true ? factory(__webpack_require__(
|
| 21269 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21270 |
factory(global.moment)
|
| 21271 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21355,7 +21698,7 @@ webpackJsonp([0],[
|
|
| 21355 |
y : translate,
|
| 21356 |
yy : translate
|
| 21357 |
},
|
| 21358 |
-
|
| 21359 |
ordinal : '%d.',
|
| 21360 |
week : {
|
| 21361 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21369,7 +21712,7 @@ webpackJsonp([0],[
|
|
| 21369 |
|
| 21370 |
|
| 21371 |
/***/ },
|
| 21372 |
-
/*
|
| 21373 |
/***/ function(module, exports, __webpack_require__) {
|
| 21374 |
|
| 21375 |
//! moment.js locale configuration
|
|
@@ -21377,7 +21720,7 @@ webpackJsonp([0],[
|
|
| 21377 |
//! author : Ragnar Johannesen : https://github.com/ragnar123
|
| 21378 |
|
| 21379 |
;(function (global, factory) {
|
| 21380 |
-
true ? factory(__webpack_require__(
|
| 21381 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21382 |
factory(global.moment)
|
| 21383 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21420,7 +21763,7 @@ webpackJsonp([0],[
|
|
| 21420 |
y : 'eitt ár',
|
| 21421 |
yy : '%d ár'
|
| 21422 |
},
|
| 21423 |
-
|
| 21424 |
ordinal : '%d.',
|
| 21425 |
week : {
|
| 21426 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21434,7 +21777,7 @@ webpackJsonp([0],[
|
|
| 21434 |
|
| 21435 |
|
| 21436 |
/***/ },
|
| 21437 |
-
/*
|
| 21438 |
/***/ function(module, exports, __webpack_require__) {
|
| 21439 |
|
| 21440 |
//! moment.js locale configuration
|
|
@@ -21442,7 +21785,7 @@ webpackJsonp([0],[
|
|
| 21442 |
//! author : John Fischer : https://github.com/jfroffice
|
| 21443 |
|
| 21444 |
;(function (global, factory) {
|
| 21445 |
-
true ? factory(__webpack_require__(
|
| 21446 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21447 |
factory(global.moment)
|
| 21448 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21465,12 +21808,12 @@ webpackJsonp([0],[
|
|
| 21465 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21466 |
},
|
| 21467 |
calendar : {
|
| 21468 |
-
sameDay: '[Aujourd
|
| 21469 |
-
nextDay: '[Demain à] LT',
|
| 21470 |
-
nextWeek: 'dddd [à] LT',
|
| 21471 |
-
lastDay: '[Hier à] LT',
|
| 21472 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 21473 |
-
sameElse: 'L'
|
| 21474 |
},
|
| 21475 |
relativeTime : {
|
| 21476 |
future : 'dans %s',
|
|
@@ -21487,9 +21830,28 @@ webpackJsonp([0],[
|
|
| 21487 |
y : 'un an',
|
| 21488 |
yy : '%d ans'
|
| 21489 |
},
|
| 21490 |
-
|
| 21491 |
-
ordinal : function (number) {
|
| 21492 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21493 |
},
|
| 21494 |
week : {
|
| 21495 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21503,7 +21865,7 @@ webpackJsonp([0],[
|
|
| 21503 |
|
| 21504 |
|
| 21505 |
/***/ },
|
| 21506 |
-
/*
|
| 21507 |
/***/ function(module, exports, __webpack_require__) {
|
| 21508 |
|
| 21509 |
//! moment.js locale configuration
|
|
@@ -21511,7 +21873,7 @@ webpackJsonp([0],[
|
|
| 21511 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 21512 |
|
| 21513 |
;(function (global, factory) {
|
| 21514 |
-
true ? factory(__webpack_require__(
|
| 21515 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21516 |
factory(global.moment)
|
| 21517 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21534,12 +21896,12 @@ webpackJsonp([0],[
|
|
| 21534 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21535 |
},
|
| 21536 |
calendar : {
|
| 21537 |
-
sameDay: '[Aujourd
|
| 21538 |
-
nextDay: '[Demain à] LT',
|
| 21539 |
-
nextWeek: 'dddd [à] LT',
|
| 21540 |
-
lastDay: '[Hier à] LT',
|
| 21541 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 21542 |
-
sameElse: 'L'
|
| 21543 |
},
|
| 21544 |
relativeTime : {
|
| 21545 |
future : 'dans %s',
|
|
@@ -21556,9 +21918,23 @@ webpackJsonp([0],[
|
|
| 21556 |
y : 'un an',
|
| 21557 |
yy : '%d ans'
|
| 21558 |
},
|
| 21559 |
-
|
| 21560 |
-
ordinal : function (number) {
|
| 21561 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21562 |
}
|
| 21563 |
});
|
| 21564 |
|
|
@@ -21568,7 +21944,7 @@ webpackJsonp([0],[
|
|
| 21568 |
|
| 21569 |
|
| 21570 |
/***/ },
|
| 21571 |
-
/*
|
| 21572 |
/***/ function(module, exports, __webpack_require__) {
|
| 21573 |
|
| 21574 |
//! moment.js locale configuration
|
|
@@ -21576,7 +21952,7 @@ webpackJsonp([0],[
|
|
| 21576 |
//! author : Gaspard Bucher : https://github.com/gaspard
|
| 21577 |
|
| 21578 |
;(function (global, factory) {
|
| 21579 |
-
true ? factory(__webpack_require__(
|
| 21580 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21581 |
factory(global.moment)
|
| 21582 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21599,12 +21975,12 @@ webpackJsonp([0],[
|
|
| 21599 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21600 |
},
|
| 21601 |
calendar : {
|
| 21602 |
-
sameDay: '[Aujourd
|
| 21603 |
-
nextDay: '[Demain à] LT',
|
| 21604 |
-
nextWeek: 'dddd [à] LT',
|
| 21605 |
-
lastDay: '[Hier à] LT',
|
| 21606 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 21607 |
-
sameElse: 'L'
|
| 21608 |
},
|
| 21609 |
relativeTime : {
|
| 21610 |
future : 'dans %s',
|
|
@@ -21621,9 +21997,23 @@ webpackJsonp([0],[
|
|
| 21621 |
y : 'un an',
|
| 21622 |
yy : '%d ans'
|
| 21623 |
},
|
| 21624 |
-
|
| 21625 |
-
ordinal : function (number) {
|
| 21626 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21627 |
},
|
| 21628 |
week : {
|
| 21629 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21637,7 +22027,7 @@ webpackJsonp([0],[
|
|
| 21637 |
|
| 21638 |
|
| 21639 |
/***/ },
|
| 21640 |
-
/*
|
| 21641 |
/***/ function(module, exports, __webpack_require__) {
|
| 21642 |
|
| 21643 |
//! moment.js locale configuration
|
|
@@ -21645,7 +22035,7 @@ webpackJsonp([0],[
|
|
| 21645 |
//! author : Robin van der Vliet : https://github.com/robin0van0der0v
|
| 21646 |
|
| 21647 |
;(function (global, factory) {
|
| 21648 |
-
true ? factory(__webpack_require__(
|
| 21649 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21650 |
factory(global.moment)
|
| 21651 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21657,7 +22047,9 @@ webpackJsonp([0],[
|
|
| 21657 |
var fy = moment.defineLocale('fy', {
|
| 21658 |
months : 'jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber'.split('_'),
|
| 21659 |
monthsShort : function (m, format) {
|
| 21660 |
-
if (
|
|
|
|
|
|
|
| 21661 |
return monthsShortWithoutDots[m.month()];
|
| 21662 |
} else {
|
| 21663 |
return monthsShortWithDots[m.month()];
|
|
@@ -21699,7 +22091,7 @@ webpackJsonp([0],[
|
|
| 21699 |
y : 'ien jier',
|
| 21700 |
yy : '%d jierren'
|
| 21701 |
},
|
| 21702 |
-
|
| 21703 |
ordinal : function (number) {
|
| 21704 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 21705 |
},
|
|
@@ -21715,7 +22107,7 @@ webpackJsonp([0],[
|
|
| 21715 |
|
| 21716 |
|
| 21717 |
/***/ },
|
| 21718 |
-
/*
|
| 21719 |
/***/ function(module, exports, __webpack_require__) {
|
| 21720 |
|
| 21721 |
//! moment.js locale configuration
|
|
@@ -21723,7 +22115,7 @@ webpackJsonp([0],[
|
|
| 21723 |
//! author : Jon Ashdown : https://github.com/jonashdown
|
| 21724 |
|
| 21725 |
;(function (global, factory) {
|
| 21726 |
-
true ? factory(__webpack_require__(
|
| 21727 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21728 |
factory(global.moment)
|
| 21729 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21779,7 +22171,7 @@ webpackJsonp([0],[
|
|
| 21779 |
y : 'bliadhna',
|
| 21780 |
yy : '%d bliadhna'
|
| 21781 |
},
|
| 21782 |
-
|
| 21783 |
ordinal : function (number) {
|
| 21784 |
var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';
|
| 21785 |
return number + output;
|
|
@@ -21796,7 +22188,7 @@ webpackJsonp([0],[
|
|
| 21796 |
|
| 21797 |
|
| 21798 |
/***/ },
|
| 21799 |
-
/*
|
| 21800 |
/***/ function(module, exports, __webpack_require__) {
|
| 21801 |
|
| 21802 |
//! moment.js locale configuration
|
|
@@ -21804,7 +22196,7 @@ webpackJsonp([0],[
|
|
| 21804 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 21805 |
|
| 21806 |
;(function (global, factory) {
|
| 21807 |
-
true ? factory(__webpack_require__(
|
| 21808 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21809 |
factory(global.moment)
|
| 21810 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21864,7 +22256,7 @@ webpackJsonp([0],[
|
|
| 21864 |
y : 'un ano',
|
| 21865 |
yy : '%d anos'
|
| 21866 |
},
|
| 21867 |
-
|
| 21868 |
ordinal : '%dº',
|
| 21869 |
week : {
|
| 21870 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -21878,7 +22270,134 @@ webpackJsonp([0],[
|
|
| 21878 |
|
| 21879 |
|
| 21880 |
/***/ },
|
| 21881 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21882 |
/***/ function(module, exports, __webpack_require__) {
|
| 21883 |
|
| 21884 |
//! moment.js locale configuration
|
|
@@ -21888,7 +22407,7 @@ webpackJsonp([0],[
|
|
| 21888 |
//! author : Tal Ater : https://github.com/TalAter
|
| 21889 |
|
| 21890 |
;(function (global, factory) {
|
| 21891 |
-
true ? factory(__webpack_require__(
|
| 21892 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21893 |
factory(global.moment)
|
| 21894 |
}(this, (function (moment) { 'use strict';
|
|
@@ -21982,7 +22501,7 @@ webpackJsonp([0],[
|
|
| 21982 |
|
| 21983 |
|
| 21984 |
/***/ },
|
| 21985 |
-
/*
|
| 21986 |
/***/ function(module, exports, __webpack_require__) {
|
| 21987 |
|
| 21988 |
//! moment.js locale configuration
|
|
@@ -21990,7 +22509,7 @@ webpackJsonp([0],[
|
|
| 21990 |
//! author : Mayank Singhal : https://github.com/mayanksinghal
|
| 21991 |
|
| 21992 |
;(function (global, factory) {
|
| 21993 |
-
true ? factory(__webpack_require__(
|
| 21994 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21995 |
factory(global.moment)
|
| 21996 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22111,7 +22630,7 @@ webpackJsonp([0],[
|
|
| 22111 |
|
| 22112 |
|
| 22113 |
/***/ },
|
| 22114 |
-
/*
|
| 22115 |
/***/ function(module, exports, __webpack_require__) {
|
| 22116 |
|
| 22117 |
//! moment.js locale configuration
|
|
@@ -22119,7 +22638,7 @@ webpackJsonp([0],[
|
|
| 22119 |
//! author : Bojan Marković : https://github.com/bmarkovic
|
| 22120 |
|
| 22121 |
;(function (global, factory) {
|
| 22122 |
-
true ? factory(__webpack_require__(
|
| 22123 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22124 |
factory(global.moment)
|
| 22125 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22247,7 +22766,7 @@ webpackJsonp([0],[
|
|
| 22247 |
y : 'godinu',
|
| 22248 |
yy : translate
|
| 22249 |
},
|
| 22250 |
-
|
| 22251 |
ordinal : '%d.',
|
| 22252 |
week : {
|
| 22253 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -22261,7 +22780,7 @@ webpackJsonp([0],[
|
|
| 22261 |
|
| 22262 |
|
| 22263 |
/***/ },
|
| 22264 |
-
/*
|
| 22265 |
/***/ function(module, exports, __webpack_require__) {
|
| 22266 |
|
| 22267 |
//! moment.js locale configuration
|
|
@@ -22269,7 +22788,7 @@ webpackJsonp([0],[
|
|
| 22269 |
//! author : Adam Brunner : https://github.com/adambrunner
|
| 22270 |
|
| 22271 |
;(function (global, factory) {
|
| 22272 |
-
true ? factory(__webpack_require__(
|
| 22273 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22274 |
factory(global.moment)
|
| 22275 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22361,7 +22880,7 @@ webpackJsonp([0],[
|
|
| 22361 |
y : translate,
|
| 22362 |
yy : translate
|
| 22363 |
},
|
| 22364 |
-
|
| 22365 |
ordinal : '%d.',
|
| 22366 |
week : {
|
| 22367 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -22375,7 +22894,7 @@ webpackJsonp([0],[
|
|
| 22375 |
|
| 22376 |
|
| 22377 |
/***/ },
|
| 22378 |
-
/*
|
| 22379 |
/***/ function(module, exports, __webpack_require__) {
|
| 22380 |
|
| 22381 |
//! moment.js locale configuration
|
|
@@ -22383,7 +22902,7 @@ webpackJsonp([0],[
|
|
| 22383 |
//! author : Armendarabyan : https://github.com/armendarabyan
|
| 22384 |
|
| 22385 |
;(function (global, factory) {
|
| 22386 |
-
true ? factory(__webpack_require__(
|
| 22387 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22388 |
factory(global.moment)
|
| 22389 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22448,7 +22967,7 @@ webpackJsonp([0],[
|
|
| 22448 |
return 'երեկոյան';
|
| 22449 |
}
|
| 22450 |
},
|
| 22451 |
-
|
| 22452 |
ordinal: function (number, period) {
|
| 22453 |
switch (period) {
|
| 22454 |
case 'DDD':
|
|
@@ -22475,7 +22994,7 @@ webpackJsonp([0],[
|
|
| 22475 |
|
| 22476 |
|
| 22477 |
/***/ },
|
| 22478 |
-
/*
|
| 22479 |
/***/ function(module, exports, __webpack_require__) {
|
| 22480 |
|
| 22481 |
//! moment.js locale configuration
|
|
@@ -22484,7 +23003,7 @@ webpackJsonp([0],[
|
|
| 22484 |
//! reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan
|
| 22485 |
|
| 22486 |
;(function (global, factory) {
|
| 22487 |
-
true ? factory(__webpack_require__(
|
| 22488 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22489 |
factory(global.moment)
|
| 22490 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22563,7 +23082,7 @@ webpackJsonp([0],[
|
|
| 22563 |
|
| 22564 |
|
| 22565 |
/***/ },
|
| 22566 |
-
/*
|
| 22567 |
/***/ function(module, exports, __webpack_require__) {
|
| 22568 |
|
| 22569 |
//! moment.js locale configuration
|
|
@@ -22571,7 +23090,7 @@ webpackJsonp([0],[
|
|
| 22571 |
//! author : Hinrik Örn Sigurðsson : https://github.com/hinrik
|
| 22572 |
|
| 22573 |
;(function (global, factory) {
|
| 22574 |
-
true ? factory(__webpack_require__(
|
| 22575 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22576 |
factory(global.moment)
|
| 22577 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22681,7 +23200,7 @@ webpackJsonp([0],[
|
|
| 22681 |
y : translate,
|
| 22682 |
yy : translate
|
| 22683 |
},
|
| 22684 |
-
|
| 22685 |
ordinal : '%d.',
|
| 22686 |
week : {
|
| 22687 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -22695,7 +23214,7 @@ webpackJsonp([0],[
|
|
| 22695 |
|
| 22696 |
|
| 22697 |
/***/ },
|
| 22698 |
-
/*
|
| 22699 |
/***/ function(module, exports, __webpack_require__) {
|
| 22700 |
|
| 22701 |
//! moment.js locale configuration
|
|
@@ -22704,7 +23223,7 @@ webpackJsonp([0],[
|
|
| 22704 |
//! author: Mattia Larentis: https://github.com/nostalgiaz
|
| 22705 |
|
| 22706 |
;(function (global, factory) {
|
| 22707 |
-
true ? factory(__webpack_require__(
|
| 22708 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22709 |
factory(global.moment)
|
| 22710 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22713,9 +23232,9 @@ webpackJsonp([0],[
|
|
| 22713 |
var it = moment.defineLocale('it', {
|
| 22714 |
months : 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split('_'),
|
| 22715 |
monthsShort : 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),
|
| 22716 |
-
weekdays : '
|
| 22717 |
-
weekdaysShort : '
|
| 22718 |
-
weekdaysMin : '
|
| 22719 |
longDateFormat : {
|
| 22720 |
LT : 'HH:mm',
|
| 22721 |
LTS : 'HH:mm:ss',
|
|
@@ -22756,7 +23275,7 @@ webpackJsonp([0],[
|
|
| 22756 |
y : 'un anno',
|
| 22757 |
yy : '%d anni'
|
| 22758 |
},
|
| 22759 |
-
|
| 22760 |
ordinal: '%dº',
|
| 22761 |
week : {
|
| 22762 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -22770,7 +23289,7 @@ webpackJsonp([0],[
|
|
| 22770 |
|
| 22771 |
|
| 22772 |
/***/ },
|
| 22773 |
-
/*
|
| 22774 |
/***/ function(module, exports, __webpack_require__) {
|
| 22775 |
|
| 22776 |
//! moment.js locale configuration
|
|
@@ -22778,7 +23297,7 @@ webpackJsonp([0],[
|
|
| 22778 |
//! author : LI Long : https://github.com/baryon
|
| 22779 |
|
| 22780 |
;(function (global, factory) {
|
| 22781 |
-
true ? factory(__webpack_require__(
|
| 22782 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22783 |
factory(global.moment)
|
| 22784 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22791,12 +23310,16 @@ webpackJsonp([0],[
|
|
| 22791 |
weekdaysShort : '日_月_火_水_木_金_土'.split('_'),
|
| 22792 |
weekdaysMin : '日_月_火_水_木_金_土'.split('_'),
|
| 22793 |
longDateFormat : {
|
| 22794 |
-
LT : '
|
| 22795 |
-
LTS : '
|
| 22796 |
L : 'YYYY/MM/DD',
|
| 22797 |
LL : 'YYYY年M月D日',
|
| 22798 |
-
LLL : 'YYYY年M月D日
|
| 22799 |
-
LLLL : 'YYYY年M月D日
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22800 |
},
|
| 22801 |
meridiemParse: /午前|午後/i,
|
| 22802 |
isPM : function (input) {
|
|
@@ -22817,7 +23340,7 @@ webpackJsonp([0],[
|
|
| 22817 |
lastWeek : '[前週]dddd LT',
|
| 22818 |
sameElse : 'L'
|
| 22819 |
},
|
| 22820 |
-
|
| 22821 |
ordinal : function (number, period) {
|
| 22822 |
switch (period) {
|
| 22823 |
case 'd':
|
|
@@ -22851,7 +23374,7 @@ webpackJsonp([0],[
|
|
| 22851 |
|
| 22852 |
|
| 22853 |
/***/ },
|
| 22854 |
-
/*
|
| 22855 |
/***/ function(module, exports, __webpack_require__) {
|
| 22856 |
|
| 22857 |
//! moment.js locale configuration
|
|
@@ -22860,7 +23383,7 @@ webpackJsonp([0],[
|
|
| 22860 |
//! reference: http://jv.wikipedia.org/wiki/Basa_Jawa
|
| 22861 |
|
| 22862 |
;(function (global, factory) {
|
| 22863 |
-
true ? factory(__webpack_require__(
|
| 22864 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22865 |
factory(global.moment)
|
| 22866 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22939,7 +23462,7 @@ webpackJsonp([0],[
|
|
| 22939 |
|
| 22940 |
|
| 22941 |
/***/ },
|
| 22942 |
-
/*
|
| 22943 |
/***/ function(module, exports, __webpack_require__) {
|
| 22944 |
|
| 22945 |
//! moment.js locale configuration
|
|
@@ -22947,7 +23470,7 @@ webpackJsonp([0],[
|
|
| 22947 |
//! author : Irakli Janiashvili : https://github.com/irakli-janiashvili
|
| 22948 |
|
| 22949 |
;(function (global, factory) {
|
| 22950 |
-
true ? factory(__webpack_require__(
|
| 22951 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22952 |
factory(global.moment)
|
| 22953 |
}(this, (function (moment) { 'use strict';
|
|
@@ -22990,10 +23513,10 @@ webpackJsonp([0],[
|
|
| 22990 |
},
|
| 22991 |
past : function (s) {
|
| 22992 |
if ((/(წამი|წუთი|საათი|დღე|თვე)/).test(s)) {
|
| 22993 |
-
return s.replace(/(ი|ე)$/, 'ის
|
| 22994 |
}
|
| 22995 |
if ((/წელი/).test(s)) {
|
| 22996 |
-
return s.replace(/წელი$/, 'წლის
|
| 22997 |
}
|
| 22998 |
},
|
| 22999 |
s : 'რამდენიმე წამი',
|
|
@@ -23008,7 +23531,7 @@ webpackJsonp([0],[
|
|
| 23008 |
y : 'წელი',
|
| 23009 |
yy : '%d წელი'
|
| 23010 |
},
|
| 23011 |
-
|
| 23012 |
ordinal : function (number) {
|
| 23013 |
if (number === 0) {
|
| 23014 |
return number;
|
|
@@ -23033,7 +23556,7 @@ webpackJsonp([0],[
|
|
| 23033 |
|
| 23034 |
|
| 23035 |
/***/ },
|
| 23036 |
-
/*
|
| 23037 |
/***/ function(module, exports, __webpack_require__) {
|
| 23038 |
|
| 23039 |
//! moment.js locale configuration
|
|
@@ -23041,7 +23564,7 @@ webpackJsonp([0],[
|
|
| 23041 |
//! authors : Nurlan Rakhimzhanov : https://github.com/nurlan
|
| 23042 |
|
| 23043 |
;(function (global, factory) {
|
| 23044 |
-
true ? factory(__webpack_require__(
|
| 23045 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23046 |
factory(global.moment)
|
| 23047 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23107,7 +23630,7 @@ webpackJsonp([0],[
|
|
| 23107 |
y : 'бір жыл',
|
| 23108 |
yy : '%d жыл'
|
| 23109 |
},
|
| 23110 |
-
|
| 23111 |
ordinal : function (number) {
|
| 23112 |
var a = number % 10,
|
| 23113 |
b = number >= 100 ? 100 : null;
|
|
@@ -23125,7 +23648,7 @@ webpackJsonp([0],[
|
|
| 23125 |
|
| 23126 |
|
| 23127 |
/***/ },
|
| 23128 |
-
/*
|
| 23129 |
/***/ function(module, exports, __webpack_require__) {
|
| 23130 |
|
| 23131 |
//! moment.js locale configuration
|
|
@@ -23133,7 +23656,7 @@ webpackJsonp([0],[
|
|
| 23133 |
//! author : Kruy Vanna : https://github.com/kruyvanna
|
| 23134 |
|
| 23135 |
;(function (global, factory) {
|
| 23136 |
-
true ? factory(__webpack_require__(
|
| 23137 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23138 |
factory(global.moment)
|
| 23139 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23188,7 +23711,138 @@ webpackJsonp([0],[
|
|
| 23188 |
|
| 23189 |
|
| 23190 |
/***/ },
|
| 23191 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23192 |
/***/ function(module, exports, __webpack_require__) {
|
| 23193 |
|
| 23194 |
//! moment.js locale configuration
|
|
@@ -23197,7 +23851,7 @@ webpackJsonp([0],[
|
|
| 23197 |
//! author : Jeeeyul Lee <jeeeyul@gmail.com>
|
| 23198 |
|
| 23199 |
;(function (global, factory) {
|
| 23200 |
-
true ? factory(__webpack_require__(
|
| 23201 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23202 |
factory(global.moment)
|
| 23203 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23210,12 +23864,16 @@ webpackJsonp([0],[
|
|
| 23210 |
weekdaysShort : '일_월_화_수_목_금_토'.split('_'),
|
| 23211 |
weekdaysMin : '일_월_화_수_목_금_토'.split('_'),
|
| 23212 |
longDateFormat : {
|
| 23213 |
-
LT : 'A h
|
| 23214 |
-
LTS : 'A h
|
| 23215 |
L : 'YYYY.MM.DD',
|
| 23216 |
LL : 'YYYY년 MMMM D일',
|
| 23217 |
-
LLL : 'YYYY년 MMMM D일 A h
|
| 23218 |
-
LLLL : 'YYYY년 MMMM D일 dddd A h
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23219 |
},
|
| 23220 |
calendar : {
|
| 23221 |
sameDay : '오늘 LT',
|
|
@@ -23230,7 +23888,7 @@ webpackJsonp([0],[
|
|
| 23230 |
past : '%s 전',
|
| 23231 |
s : '몇 초',
|
| 23232 |
ss : '%d초',
|
| 23233 |
-
m : '
|
| 23234 |
mm : '%d분',
|
| 23235 |
h : '한 시간',
|
| 23236 |
hh : '%d시간',
|
|
@@ -23241,7 +23899,7 @@ webpackJsonp([0],[
|
|
| 23241 |
y : '일 년',
|
| 23242 |
yy : '%d년'
|
| 23243 |
},
|
| 23244 |
-
|
| 23245 |
ordinal : '%d일',
|
| 23246 |
meridiemParse : /오전|오후/,
|
| 23247 |
isPM : function (token) {
|
|
@@ -23258,7 +23916,7 @@ webpackJsonp([0],[
|
|
| 23258 |
|
| 23259 |
|
| 23260 |
/***/ },
|
| 23261 |
-
/*
|
| 23262 |
/***/ function(module, exports, __webpack_require__) {
|
| 23263 |
|
| 23264 |
//! moment.js locale configuration
|
|
@@ -23266,7 +23924,7 @@ webpackJsonp([0],[
|
|
| 23266 |
//! author : Chyngyz Arystan uulu : https://github.com/chyngyz
|
| 23267 |
|
| 23268 |
;(function (global, factory) {
|
| 23269 |
-
true ? factory(__webpack_require__(
|
| 23270 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23271 |
factory(global.moment)
|
| 23272 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23333,7 +23991,7 @@ webpackJsonp([0],[
|
|
| 23333 |
y : 'бир жыл',
|
| 23334 |
yy : '%d жыл'
|
| 23335 |
},
|
| 23336 |
-
|
| 23337 |
ordinal : function (number) {
|
| 23338 |
var a = number % 10,
|
| 23339 |
b = number >= 100 ? 100 : null;
|
|
@@ -23351,7 +24009,7 @@ webpackJsonp([0],[
|
|
| 23351 |
|
| 23352 |
|
| 23353 |
/***/ },
|
| 23354 |
-
/*
|
| 23355 |
/***/ function(module, exports, __webpack_require__) {
|
| 23356 |
|
| 23357 |
//! moment.js locale configuration
|
|
@@ -23360,7 +24018,7 @@ webpackJsonp([0],[
|
|
| 23360 |
//! author : David Raison : https://github.com/kwisatz
|
| 23361 |
|
| 23362 |
;(function (global, factory) {
|
| 23363 |
-
true ? factory(__webpack_require__(
|
| 23364 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23365 |
factory(global.moment)
|
| 23366 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23479,7 +24137,7 @@ webpackJsonp([0],[
|
|
| 23479 |
y : processRelativeTime,
|
| 23480 |
yy : '%d Joer'
|
| 23481 |
},
|
| 23482 |
-
|
| 23483 |
ordinal: '%d.',
|
| 23484 |
week: {
|
| 23485 |
dow: 1, // Monday is the first day of the week.
|
|
@@ -23493,7 +24151,7 @@ webpackJsonp([0],[
|
|
| 23493 |
|
| 23494 |
|
| 23495 |
/***/ },
|
| 23496 |
-
/*
|
| 23497 |
/***/ function(module, exports, __webpack_require__) {
|
| 23498 |
|
| 23499 |
//! moment.js locale configuration
|
|
@@ -23501,7 +24159,7 @@ webpackJsonp([0],[
|
|
| 23501 |
//! author : Ryan Hart : https://github.com/ryanhart2
|
| 23502 |
|
| 23503 |
;(function (global, factory) {
|
| 23504 |
-
true ? factory(__webpack_require__(
|
| 23505 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23506 |
factory(global.moment)
|
| 23507 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23556,7 +24214,7 @@ webpackJsonp([0],[
|
|
| 23556 |
y : '1 ປີ',
|
| 23557 |
yy : '%d ປີ'
|
| 23558 |
},
|
| 23559 |
-
|
| 23560 |
ordinal : function (number) {
|
| 23561 |
return 'ທີ່' + number;
|
| 23562 |
}
|
|
@@ -23568,7 +24226,7 @@ webpackJsonp([0],[
|
|
| 23568 |
|
| 23569 |
|
| 23570 |
/***/ },
|
| 23571 |
-
/*
|
| 23572 |
/***/ function(module, exports, __webpack_require__) {
|
| 23573 |
|
| 23574 |
//! moment.js locale configuration
|
|
@@ -23576,7 +24234,7 @@ webpackJsonp([0],[
|
|
| 23576 |
//! author : Mindaugas Mozūras : https://github.com/mmozuras
|
| 23577 |
|
| 23578 |
;(function (global, factory) {
|
| 23579 |
-
true ? factory(__webpack_require__(
|
| 23580 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23581 |
factory(global.moment)
|
| 23582 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23674,7 +24332,7 @@ webpackJsonp([0],[
|
|
| 23674 |
y : translateSingular,
|
| 23675 |
yy : translate
|
| 23676 |
},
|
| 23677 |
-
|
| 23678 |
ordinal : function (number) {
|
| 23679 |
return number + '-oji';
|
| 23680 |
},
|
|
@@ -23690,7 +24348,7 @@ webpackJsonp([0],[
|
|
| 23690 |
|
| 23691 |
|
| 23692 |
/***/ },
|
| 23693 |
-
/*
|
| 23694 |
/***/ function(module, exports, __webpack_require__) {
|
| 23695 |
|
| 23696 |
//! moment.js locale configuration
|
|
@@ -23699,7 +24357,7 @@ webpackJsonp([0],[
|
|
| 23699 |
//! author : Jānis Elmeris : https://github.com/JanisE
|
| 23700 |
|
| 23701 |
;(function (global, factory) {
|
| 23702 |
-
true ? factory(__webpack_require__(
|
| 23703 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23704 |
factory(global.moment)
|
| 23705 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23778,7 +24436,7 @@ webpackJsonp([0],[
|
|
| 23778 |
y : relativeTimeWithSingular,
|
| 23779 |
yy : relativeTimeWithPlural
|
| 23780 |
},
|
| 23781 |
-
|
| 23782 |
ordinal : '%d.',
|
| 23783 |
week : {
|
| 23784 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -23792,7 +24450,7 @@ webpackJsonp([0],[
|
|
| 23792 |
|
| 23793 |
|
| 23794 |
/***/ },
|
| 23795 |
-
/*
|
| 23796 |
/***/ function(module, exports, __webpack_require__) {
|
| 23797 |
|
| 23798 |
//! moment.js locale configuration
|
|
@@ -23800,7 +24458,7 @@ webpackJsonp([0],[
|
|
| 23800 |
//! author : Miodrag Nikač <miodrag@restartit.me> : https://github.com/miodragnikac
|
| 23801 |
|
| 23802 |
;(function (global, factory) {
|
| 23803 |
-
true ? factory(__webpack_require__(
|
| 23804 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23805 |
factory(global.moment)
|
| 23806 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23894,7 +24552,7 @@ webpackJsonp([0],[
|
|
| 23894 |
y : 'godinu',
|
| 23895 |
yy : translator.translate
|
| 23896 |
},
|
| 23897 |
-
|
| 23898 |
ordinal : '%d.',
|
| 23899 |
week : {
|
| 23900 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -23908,7 +24566,7 @@ webpackJsonp([0],[
|
|
| 23908 |
|
| 23909 |
|
| 23910 |
/***/ },
|
| 23911 |
-
/*
|
| 23912 |
/***/ function(module, exports, __webpack_require__) {
|
| 23913 |
|
| 23914 |
//! moment.js locale configuration
|
|
@@ -23916,7 +24574,7 @@ webpackJsonp([0],[
|
|
| 23916 |
//! author : John Corrigan <robbiecloset@gmail.com> : https://github.com/johnideal
|
| 23917 |
|
| 23918 |
;(function (global, factory) {
|
| 23919 |
-
true ? factory(__webpack_require__(
|
| 23920 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23921 |
factory(global.moment)
|
| 23922 |
}(this, (function (moment) { 'use strict';
|
|
@@ -23963,7 +24621,7 @@ webpackJsonp([0],[
|
|
| 23963 |
y: 'he tau',
|
| 23964 |
yy: '%d tau'
|
| 23965 |
},
|
| 23966 |
-
|
| 23967 |
ordinal: '%dº',
|
| 23968 |
week : {
|
| 23969 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -23977,7 +24635,7 @@ webpackJsonp([0],[
|
|
| 23977 |
|
| 23978 |
|
| 23979 |
/***/ },
|
| 23980 |
-
/*
|
| 23981 |
/***/ function(module, exports, __webpack_require__) {
|
| 23982 |
|
| 23983 |
//! moment.js locale configuration
|
|
@@ -23985,7 +24643,7 @@ webpackJsonp([0],[
|
|
| 23985 |
//! author : Borislav Mickov : https://github.com/B0k0
|
| 23986 |
|
| 23987 |
;(function (global, factory) {
|
| 23988 |
-
true ? factory(__webpack_require__(
|
| 23989 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23990 |
factory(global.moment)
|
| 23991 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24040,7 +24698,7 @@ webpackJsonp([0],[
|
|
| 24040 |
y : 'година',
|
| 24041 |
yy : '%d години'
|
| 24042 |
},
|
| 24043 |
-
|
| 24044 |
ordinal : function (number) {
|
| 24045 |
var lastDigit = number % 10,
|
| 24046 |
last2Digits = number % 100;
|
|
@@ -24072,7 +24730,7 @@ webpackJsonp([0],[
|
|
| 24072 |
|
| 24073 |
|
| 24074 |
/***/ },
|
| 24075 |
-
/*
|
| 24076 |
/***/ function(module, exports, __webpack_require__) {
|
| 24077 |
|
| 24078 |
//! moment.js locale configuration
|
|
@@ -24080,7 +24738,7 @@ webpackJsonp([0],[
|
|
| 24080 |
//! author : Floyd Pink : https://github.com/floydpink
|
| 24081 |
|
| 24082 |
;(function (global, factory) {
|
| 24083 |
-
true ? factory(__webpack_require__(
|
| 24084 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24085 |
factory(global.moment)
|
| 24086 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24158,7 +24816,7 @@ webpackJsonp([0],[
|
|
| 24158 |
|
| 24159 |
|
| 24160 |
/***/ },
|
| 24161 |
-
/*
|
| 24162 |
/***/ function(module, exports, __webpack_require__) {
|
| 24163 |
|
| 24164 |
//! moment.js locale configuration
|
|
@@ -24167,7 +24825,7 @@ webpackJsonp([0],[
|
|
| 24167 |
//! author : Vivek Athalye : https://github.com/vnathalye
|
| 24168 |
|
| 24169 |
;(function (global, factory) {
|
| 24170 |
-
true ? factory(__webpack_require__(
|
| 24171 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24172 |
factory(global.moment)
|
| 24173 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24322,7 +24980,7 @@ webpackJsonp([0],[
|
|
| 24322 |
|
| 24323 |
|
| 24324 |
/***/ },
|
| 24325 |
-
/*
|
| 24326 |
/***/ function(module, exports, __webpack_require__) {
|
| 24327 |
|
| 24328 |
//! moment.js locale configuration
|
|
@@ -24330,7 +24988,7 @@ webpackJsonp([0],[
|
|
| 24330 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 24331 |
|
| 24332 |
;(function (global, factory) {
|
| 24333 |
-
true ? factory(__webpack_require__(
|
| 24334 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24335 |
factory(global.moment)
|
| 24336 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24409,7 +25067,7 @@ webpackJsonp([0],[
|
|
| 24409 |
|
| 24410 |
|
| 24411 |
/***/ },
|
| 24412 |
-
/*
|
| 24413 |
/***/ function(module, exports, __webpack_require__) {
|
| 24414 |
|
| 24415 |
//! moment.js locale configuration
|
|
@@ -24418,7 +25076,7 @@ webpackJsonp([0],[
|
|
| 24418 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 24419 |
|
| 24420 |
;(function (global, factory) {
|
| 24421 |
-
true ? factory(__webpack_require__(
|
| 24422 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24423 |
factory(global.moment)
|
| 24424 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24497,7 +25155,7 @@ webpackJsonp([0],[
|
|
| 24497 |
|
| 24498 |
|
| 24499 |
/***/ },
|
| 24500 |
-
/*
|
| 24501 |
/***/ function(module, exports, __webpack_require__) {
|
| 24502 |
|
| 24503 |
//! moment.js locale configuration
|
|
@@ -24507,7 +25165,7 @@ webpackJsonp([0],[
|
|
| 24507 |
//! author : Tin Aung Lin : https://github.com/thanyawzinmin
|
| 24508 |
|
| 24509 |
;(function (global, factory) {
|
| 24510 |
-
true ? factory(__webpack_require__(
|
| 24511 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24512 |
factory(global.moment)
|
| 24513 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24598,7 +25256,7 @@ webpackJsonp([0],[
|
|
| 24598 |
|
| 24599 |
|
| 24600 |
/***/ },
|
| 24601 |
-
/*
|
| 24602 |
/***/ function(module, exports, __webpack_require__) {
|
| 24603 |
|
| 24604 |
//! moment.js locale configuration
|
|
@@ -24607,7 +25265,7 @@ webpackJsonp([0],[
|
|
| 24607 |
//! Sigurd Gartmann : https://github.com/sigurdga
|
| 24608 |
|
| 24609 |
;(function (global, factory) {
|
| 24610 |
-
true ? factory(__webpack_require__(
|
| 24611 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24612 |
factory(global.moment)
|
| 24613 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24652,7 +25310,7 @@ webpackJsonp([0],[
|
|
| 24652 |
y : 'ett år',
|
| 24653 |
yy : '%d år'
|
| 24654 |
},
|
| 24655 |
-
|
| 24656 |
ordinal : '%d.',
|
| 24657 |
week : {
|
| 24658 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -24666,7 +25324,7 @@ webpackJsonp([0],[
|
|
| 24666 |
|
| 24667 |
|
| 24668 |
/***/ },
|
| 24669 |
-
/*
|
| 24670 |
/***/ function(module, exports, __webpack_require__) {
|
| 24671 |
|
| 24672 |
//! moment.js locale configuration
|
|
@@ -24674,7 +25332,7 @@ webpackJsonp([0],[
|
|
| 24674 |
//! author : suvash : https://github.com/suvash
|
| 24675 |
|
| 24676 |
;(function (global, factory) {
|
| 24677 |
-
true ? factory(__webpack_require__(
|
| 24678 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24679 |
factory(global.moment)
|
| 24680 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24794,7 +25452,7 @@ webpackJsonp([0],[
|
|
| 24794 |
|
| 24795 |
|
| 24796 |
/***/ },
|
| 24797 |
-
/*
|
| 24798 |
/***/ function(module, exports, __webpack_require__) {
|
| 24799 |
|
| 24800 |
//! moment.js locale configuration
|
|
@@ -24803,7 +25461,7 @@ webpackJsonp([0],[
|
|
| 24803 |
//! author : Jacob Middag : https://github.com/middagj
|
| 24804 |
|
| 24805 |
;(function (global, factory) {
|
| 24806 |
-
true ? factory(__webpack_require__(
|
| 24807 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24808 |
factory(global.moment)
|
| 24809 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24818,7 +25476,9 @@ webpackJsonp([0],[
|
|
| 24818 |
var nl = moment.defineLocale('nl', {
|
| 24819 |
months : 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split('_'),
|
| 24820 |
monthsShort : function (m, format) {
|
| 24821 |
-
if (
|
|
|
|
|
|
|
| 24822 |
return monthsShortWithoutDots[m.month()];
|
| 24823 |
} else {
|
| 24824 |
return monthsShortWithDots[m.month()];
|
|
@@ -24869,7 +25529,7 @@ webpackJsonp([0],[
|
|
| 24869 |
y : 'één jaar',
|
| 24870 |
yy : '%d jaar'
|
| 24871 |
},
|
| 24872 |
-
|
| 24873 |
ordinal : function (number) {
|
| 24874 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 24875 |
},
|
|
@@ -24885,7 +25545,7 @@ webpackJsonp([0],[
|
|
| 24885 |
|
| 24886 |
|
| 24887 |
/***/ },
|
| 24888 |
-
/*
|
| 24889 |
/***/ function(module, exports, __webpack_require__) {
|
| 24890 |
|
| 24891 |
//! moment.js locale configuration
|
|
@@ -24894,7 +25554,7 @@ webpackJsonp([0],[
|
|
| 24894 |
//! author : Jacob Middag : https://github.com/middagj
|
| 24895 |
|
| 24896 |
;(function (global, factory) {
|
| 24897 |
-
true ? factory(__webpack_require__(
|
| 24898 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24899 |
factory(global.moment)
|
| 24900 |
}(this, (function (moment) { 'use strict';
|
|
@@ -24909,7 +25569,9 @@ webpackJsonp([0],[
|
|
| 24909 |
var nlBe = moment.defineLocale('nl-be', {
|
| 24910 |
months : 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split('_'),
|
| 24911 |
monthsShort : function (m, format) {
|
| 24912 |
-
if (
|
|
|
|
|
|
|
| 24913 |
return monthsShortWithoutDots[m.month()];
|
| 24914 |
} else {
|
| 24915 |
return monthsShortWithDots[m.month()];
|
|
@@ -24960,7 +25622,7 @@ webpackJsonp([0],[
|
|
| 24960 |
y : 'één jaar',
|
| 24961 |
yy : '%d jaar'
|
| 24962 |
},
|
| 24963 |
-
|
| 24964 |
ordinal : function (number) {
|
| 24965 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 24966 |
},
|
|
@@ -24976,7 +25638,7 @@ webpackJsonp([0],[
|
|
| 24976 |
|
| 24977 |
|
| 24978 |
/***/ },
|
| 24979 |
-
/*
|
| 24980 |
/***/ function(module, exports, __webpack_require__) {
|
| 24981 |
|
| 24982 |
//! moment.js locale configuration
|
|
@@ -24984,7 +25646,7 @@ webpackJsonp([0],[
|
|
| 24984 |
//! author : https://github.com/mechuwind
|
| 24985 |
|
| 24986 |
;(function (global, factory) {
|
| 24987 |
-
true ? factory(__webpack_require__(
|
| 24988 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24989 |
factory(global.moment)
|
| 24990 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25027,7 +25689,7 @@ webpackJsonp([0],[
|
|
| 25027 |
y : 'eit år',
|
| 25028 |
yy : '%d år'
|
| 25029 |
},
|
| 25030 |
-
|
| 25031 |
ordinal : '%d.',
|
| 25032 |
week : {
|
| 25033 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -25041,7 +25703,7 @@ webpackJsonp([0],[
|
|
| 25041 |
|
| 25042 |
|
| 25043 |
/***/ },
|
| 25044 |
-
/*
|
| 25045 |
/***/ function(module, exports, __webpack_require__) {
|
| 25046 |
|
| 25047 |
//! moment.js locale configuration
|
|
@@ -25049,7 +25711,7 @@ webpackJsonp([0],[
|
|
| 25049 |
//! author : Harpreet Singh : https://github.com/harpreetkhalsagtbit
|
| 25050 |
|
| 25051 |
;(function (global, factory) {
|
| 25052 |
-
true ? factory(__webpack_require__(
|
| 25053 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25054 |
factory(global.moment)
|
| 25055 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25170,7 +25832,7 @@ webpackJsonp([0],[
|
|
| 25170 |
|
| 25171 |
|
| 25172 |
/***/ },
|
| 25173 |
-
/*
|
| 25174 |
/***/ function(module, exports, __webpack_require__) {
|
| 25175 |
|
| 25176 |
//! moment.js locale configuration
|
|
@@ -25178,7 +25840,7 @@ webpackJsonp([0],[
|
|
| 25178 |
//! author : Rafal Hirsz : https://github.com/evoL
|
| 25179 |
|
| 25180 |
;(function (global, factory) {
|
| 25181 |
-
true ? factory(__webpack_require__(
|
| 25182 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25183 |
factory(global.moment)
|
| 25184 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25209,7 +25871,9 @@ webpackJsonp([0],[
|
|
| 25209 |
|
| 25210 |
var pl = moment.defineLocale('pl', {
|
| 25211 |
months : function (momentToFormat, format) {
|
| 25212 |
-
if (
|
|
|
|
|
|
|
| 25213 |
// Hack: if format empty we know this is used to generate
|
| 25214 |
// RegExp by moment. Give then back both valid forms of months
|
| 25215 |
// in RegExp ready format.
|
|
@@ -25266,7 +25930,7 @@ webpackJsonp([0],[
|
|
| 25266 |
y : 'rok',
|
| 25267 |
yy : translate
|
| 25268 |
},
|
| 25269 |
-
|
| 25270 |
ordinal : '%d.',
|
| 25271 |
week : {
|
| 25272 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -25280,7 +25944,7 @@ webpackJsonp([0],[
|
|
| 25280 |
|
| 25281 |
|
| 25282 |
/***/ },
|
| 25283 |
-
/*
|
| 25284 |
/***/ function(module, exports, __webpack_require__) {
|
| 25285 |
|
| 25286 |
//! moment.js locale configuration
|
|
@@ -25288,7 +25952,7 @@ webpackJsonp([0],[
|
|
| 25288 |
//! author : Jefferson : https://github.com/jalex79
|
| 25289 |
|
| 25290 |
;(function (global, factory) {
|
| 25291 |
-
true ? factory(__webpack_require__(
|
| 25292 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25293 |
factory(global.moment)
|
| 25294 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25299,7 +25963,7 @@ webpackJsonp([0],[
|
|
| 25299 |
monthsShort : 'Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez'.split('_'),
|
| 25300 |
weekdays : 'Domingo_Segunda-Feira_Terça-Feira_Quarta-Feira_Quinta-Feira_Sexta-Feira_Sábado'.split('_'),
|
| 25301 |
weekdaysShort : 'Dom_Seg_Ter_Qua_Qui_Sex_Sáb'.split('_'),
|
| 25302 |
-
weekdaysMin : '
|
| 25303 |
weekdaysParseExact : true,
|
| 25304 |
longDateFormat : {
|
| 25305 |
LT : 'HH:mm',
|
|
@@ -25336,7 +26000,7 @@ webpackJsonp([0],[
|
|
| 25336 |
y : 'um ano',
|
| 25337 |
yy : '%d anos'
|
| 25338 |
},
|
| 25339 |
-
|
| 25340 |
ordinal : '%dº',
|
| 25341 |
week : {
|
| 25342 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -25350,7 +26014,7 @@ webpackJsonp([0],[
|
|
| 25350 |
|
| 25351 |
|
| 25352 |
/***/ },
|
| 25353 |
-
/*
|
| 25354 |
/***/ function(module, exports, __webpack_require__) {
|
| 25355 |
|
| 25356 |
//! moment.js locale configuration
|
|
@@ -25358,7 +26022,7 @@ webpackJsonp([0],[
|
|
| 25358 |
//! author : Caio Ribeiro Pereira : https://github.com/caio-ribeiro-pereira
|
| 25359 |
|
| 25360 |
;(function (global, factory) {
|
| 25361 |
-
true ? factory(__webpack_require__(
|
| 25362 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25363 |
factory(global.moment)
|
| 25364 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25369,7 +26033,7 @@ webpackJsonp([0],[
|
|
| 25369 |
monthsShort : 'Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez'.split('_'),
|
| 25370 |
weekdays : 'Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado'.split('_'),
|
| 25371 |
weekdaysShort : 'Dom_Seg_Ter_Qua_Qui_Sex_Sáb'.split('_'),
|
| 25372 |
-
weekdaysMin : '
|
| 25373 |
weekdaysParseExact : true,
|
| 25374 |
longDateFormat : {
|
| 25375 |
LT : 'HH:mm',
|
|
@@ -25406,7 +26070,7 @@ webpackJsonp([0],[
|
|
| 25406 |
y : 'um ano',
|
| 25407 |
yy : '%d anos'
|
| 25408 |
},
|
| 25409 |
-
|
| 25410 |
ordinal : '%dº'
|
| 25411 |
});
|
| 25412 |
|
|
@@ -25416,7 +26080,7 @@ webpackJsonp([0],[
|
|
| 25416 |
|
| 25417 |
|
| 25418 |
/***/ },
|
| 25419 |
-
/*
|
| 25420 |
/***/ function(module, exports, __webpack_require__) {
|
| 25421 |
|
| 25422 |
//! moment.js locale configuration
|
|
@@ -25425,7 +26089,7 @@ webpackJsonp([0],[
|
|
| 25425 |
//! author : Valentin Agachi : https://github.com/avaly
|
| 25426 |
|
| 25427 |
;(function (global, factory) {
|
| 25428 |
-
true ? factory(__webpack_require__(
|
| 25429 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25430 |
factory(global.moment)
|
| 25431 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25496,7 +26160,7 @@ webpackJsonp([0],[
|
|
| 25496 |
|
| 25497 |
|
| 25498 |
/***/ },
|
| 25499 |
-
/*
|
| 25500 |
/***/ function(module, exports, __webpack_require__) {
|
| 25501 |
|
| 25502 |
//! moment.js locale configuration
|
|
@@ -25506,7 +26170,7 @@ webpackJsonp([0],[
|
|
| 25506 |
//! author : Коренберг Марк : https://github.com/socketpair
|
| 25507 |
|
| 25508 |
;(function (global, factory) {
|
| 25509 |
-
true ? factory(__webpack_require__(
|
| 25510 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25511 |
factory(global.moment)
|
| 25512 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25656,7 +26320,7 @@ webpackJsonp([0],[
|
|
| 25656 |
return 'вечера';
|
| 25657 |
}
|
| 25658 |
},
|
| 25659 |
-
|
| 25660 |
ordinal: function (number, period) {
|
| 25661 |
switch (period) {
|
| 25662 |
case 'M':
|
|
@@ -25684,7 +26348,110 @@ webpackJsonp([0],[
|
|
| 25684 |
|
| 25685 |
|
| 25686 |
/***/ },
|
| 25687 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25688 |
/***/ function(module, exports, __webpack_require__) {
|
| 25689 |
|
| 25690 |
//! moment.js locale configuration
|
|
@@ -25692,7 +26459,7 @@ webpackJsonp([0],[
|
|
| 25692 |
//! authors : Bård Rolstad Henriksen : https://github.com/karamell
|
| 25693 |
|
| 25694 |
;(function (global, factory) {
|
| 25695 |
-
true ? factory(__webpack_require__(
|
| 25696 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25697 |
factory(global.moment)
|
| 25698 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25736,7 +26503,7 @@ webpackJsonp([0],[
|
|
| 25736 |
y : 'okta jahki',
|
| 25737 |
yy : '%d jagit'
|
| 25738 |
},
|
| 25739 |
-
|
| 25740 |
ordinal : '%d.',
|
| 25741 |
week : {
|
| 25742 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -25750,7 +26517,7 @@ webpackJsonp([0],[
|
|
| 25750 |
|
| 25751 |
|
| 25752 |
/***/ },
|
| 25753 |
-
/*
|
| 25754 |
/***/ function(module, exports, __webpack_require__) {
|
| 25755 |
|
| 25756 |
//! moment.js locale configuration
|
|
@@ -25758,7 +26525,7 @@ webpackJsonp([0],[
|
|
| 25758 |
//! author : Sampath Sitinamaluwa : https://github.com/sampathsris
|
| 25759 |
|
| 25760 |
;(function (global, factory) {
|
| 25761 |
-
true ? factory(__webpack_require__(
|
| 25762 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25763 |
factory(global.moment)
|
| 25764 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25803,7 +26570,7 @@ webpackJsonp([0],[
|
|
| 25803 |
y : 'වසර',
|
| 25804 |
yy : 'වසර %d'
|
| 25805 |
},
|
| 25806 |
-
|
| 25807 |
ordinal : function (number) {
|
| 25808 |
return number + ' වැනි';
|
| 25809 |
},
|
|
@@ -25826,7 +26593,7 @@ webpackJsonp([0],[
|
|
| 25826 |
|
| 25827 |
|
| 25828 |
/***/ },
|
| 25829 |
-
/*
|
| 25830 |
/***/ function(module, exports, __webpack_require__) {
|
| 25831 |
|
| 25832 |
//! moment.js locale configuration
|
|
@@ -25835,7 +26602,7 @@ webpackJsonp([0],[
|
|
| 25835 |
//! based on work of petrbela : https://github.com/petrbela
|
| 25836 |
|
| 25837 |
;(function (global, factory) {
|
| 25838 |
-
true ? factory(__webpack_require__(
|
| 25839 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25840 |
factory(global.moment)
|
| 25841 |
}(this, (function (moment) { 'use strict';
|
|
@@ -25967,7 +26734,7 @@ webpackJsonp([0],[
|
|
| 25967 |
y : translate,
|
| 25968 |
yy : translate
|
| 25969 |
},
|
| 25970 |
-
|
| 25971 |
ordinal : '%d.',
|
| 25972 |
week : {
|
| 25973 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -25981,7 +26748,7 @@ webpackJsonp([0],[
|
|
| 25981 |
|
| 25982 |
|
| 25983 |
/***/ },
|
| 25984 |
-
/*
|
| 25985 |
/***/ function(module, exports, __webpack_require__) {
|
| 25986 |
|
| 25987 |
//! moment.js locale configuration
|
|
@@ -25989,7 +26756,7 @@ webpackJsonp([0],[
|
|
| 25989 |
//! author : Robert Sedovšek : https://github.com/sedovsek
|
| 25990 |
|
| 25991 |
;(function (global, factory) {
|
| 25992 |
-
true ? factory(__webpack_require__(
|
| 25993 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25994 |
factory(global.moment)
|
| 25995 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26134,7 +26901,7 @@ webpackJsonp([0],[
|
|
| 26134 |
y : processRelativeTime,
|
| 26135 |
yy : processRelativeTime
|
| 26136 |
},
|
| 26137 |
-
|
| 26138 |
ordinal : '%d.',
|
| 26139 |
week : {
|
| 26140 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -26148,7 +26915,7 @@ webpackJsonp([0],[
|
|
| 26148 |
|
| 26149 |
|
| 26150 |
/***/ },
|
| 26151 |
-
/*
|
| 26152 |
/***/ function(module, exports, __webpack_require__) {
|
| 26153 |
|
| 26154 |
//! moment.js locale configuration
|
|
@@ -26158,7 +26925,7 @@ webpackJsonp([0],[
|
|
| 26158 |
//! author : Oerd Cukalla : https://github.com/oerd
|
| 26159 |
|
| 26160 |
;(function (global, factory) {
|
| 26161 |
-
true ? factory(__webpack_require__(
|
| 26162 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26163 |
factory(global.moment)
|
| 26164 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26209,7 +26976,7 @@ webpackJsonp([0],[
|
|
| 26209 |
y : 'një vit',
|
| 26210 |
yy : '%d vite'
|
| 26211 |
},
|
| 26212 |
-
|
| 26213 |
ordinal : '%d.',
|
| 26214 |
week : {
|
| 26215 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -26223,7 +26990,7 @@ webpackJsonp([0],[
|
|
| 26223 |
|
| 26224 |
|
| 26225 |
/***/ },
|
| 26226 |
-
/*
|
| 26227 |
/***/ function(module, exports, __webpack_require__) {
|
| 26228 |
|
| 26229 |
//! moment.js locale configuration
|
|
@@ -26231,7 +26998,7 @@ webpackJsonp([0],[
|
|
| 26231 |
//! author : Milan Janačković<milanjanackovic@gmail.com> : https://github.com/milan-j
|
| 26232 |
|
| 26233 |
;(function (global, factory) {
|
| 26234 |
-
true ? factory(__webpack_require__(
|
| 26235 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26236 |
factory(global.moment)
|
| 26237 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26324,7 +27091,7 @@ webpackJsonp([0],[
|
|
| 26324 |
y : 'godinu',
|
| 26325 |
yy : translator.translate
|
| 26326 |
},
|
| 26327 |
-
|
| 26328 |
ordinal : '%d.',
|
| 26329 |
week : {
|
| 26330 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -26338,7 +27105,7 @@ webpackJsonp([0],[
|
|
| 26338 |
|
| 26339 |
|
| 26340 |
/***/ },
|
| 26341 |
-
/*
|
| 26342 |
/***/ function(module, exports, __webpack_require__) {
|
| 26343 |
|
| 26344 |
//! moment.js locale configuration
|
|
@@ -26346,7 +27113,7 @@ webpackJsonp([0],[
|
|
| 26346 |
//! author : Milan Janačković<milanjanackovic@gmail.com> : https://github.com/milan-j
|
| 26347 |
|
| 26348 |
;(function (global, factory) {
|
| 26349 |
-
true ? factory(__webpack_require__(
|
| 26350 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26351 |
factory(global.moment)
|
| 26352 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26439,7 +27206,7 @@ webpackJsonp([0],[
|
|
| 26439 |
y : 'годину',
|
| 26440 |
yy : translator.translate
|
| 26441 |
},
|
| 26442 |
-
|
| 26443 |
ordinal : '%d.',
|
| 26444 |
week : {
|
| 26445 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -26453,7 +27220,7 @@ webpackJsonp([0],[
|
|
| 26453 |
|
| 26454 |
|
| 26455 |
/***/ },
|
| 26456 |
-
/*
|
| 26457 |
/***/ function(module, exports, __webpack_require__) {
|
| 26458 |
|
| 26459 |
//! moment.js locale configuration
|
|
@@ -26461,7 +27228,7 @@ webpackJsonp([0],[
|
|
| 26461 |
//! author : Nicolai Davies<mail@nicolai.io> : https://github.com/nicolaidavies
|
| 26462 |
|
| 26463 |
;(function (global, factory) {
|
| 26464 |
-
true ? factory(__webpack_require__(
|
| 26465 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26466 |
factory(global.moment)
|
| 26467 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26533,7 +27300,7 @@ webpackJsonp([0],[
|
|
| 26533 |
return hour + 12;
|
| 26534 |
}
|
| 26535 |
},
|
| 26536 |
-
|
| 26537 |
ordinal : '%d',
|
| 26538 |
week : {
|
| 26539 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -26547,7 +27314,7 @@ webpackJsonp([0],[
|
|
| 26547 |
|
| 26548 |
|
| 26549 |
/***/ },
|
| 26550 |
-
/*
|
| 26551 |
/***/ function(module, exports, __webpack_require__) {
|
| 26552 |
|
| 26553 |
//! moment.js locale configuration
|
|
@@ -26555,7 +27322,7 @@ webpackJsonp([0],[
|
|
| 26555 |
//! author : Jens Alm : https://github.com/ulmus
|
| 26556 |
|
| 26557 |
;(function (global, factory) {
|
| 26558 |
-
true ? factory(__webpack_require__(
|
| 26559 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26560 |
factory(global.moment)
|
| 26561 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26600,7 +27367,7 @@ webpackJsonp([0],[
|
|
| 26600 |
y : 'ett år',
|
| 26601 |
yy : '%d år'
|
| 26602 |
},
|
| 26603 |
-
|
| 26604 |
ordinal : function (number) {
|
| 26605 |
var b = number % 10,
|
| 26606 |
output = (~~(number % 100 / 10) === 1) ? 'e' :
|
|
@@ -26621,7 +27388,7 @@ webpackJsonp([0],[
|
|
| 26621 |
|
| 26622 |
|
| 26623 |
/***/ },
|
| 26624 |
-
/*
|
| 26625 |
/***/ function(module, exports, __webpack_require__) {
|
| 26626 |
|
| 26627 |
//! moment.js locale configuration
|
|
@@ -26629,7 +27396,7 @@ webpackJsonp([0],[
|
|
| 26629 |
//! author : Fahad Kassim : https://github.com/fadsel
|
| 26630 |
|
| 26631 |
;(function (global, factory) {
|
| 26632 |
-
true ? factory(__webpack_require__(
|
| 26633 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26634 |
factory(global.moment)
|
| 26635 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26685,7 +27452,7 @@ webpackJsonp([0],[
|
|
| 26685 |
|
| 26686 |
|
| 26687 |
/***/ },
|
| 26688 |
-
/*
|
| 26689 |
/***/ function(module, exports, __webpack_require__) {
|
| 26690 |
|
| 26691 |
//! moment.js locale configuration
|
|
@@ -26693,7 +27460,7 @@ webpackJsonp([0],[
|
|
| 26693 |
//! author : Arjunkumar Krishnamoorthy : https://github.com/tk120404
|
| 26694 |
|
| 26695 |
;(function (global, factory) {
|
| 26696 |
-
true ? factory(__webpack_require__(
|
| 26697 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26698 |
factory(global.moment)
|
| 26699 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26761,7 +27528,7 @@ webpackJsonp([0],[
|
|
| 26761 |
y : 'ஒரு வருடம்',
|
| 26762 |
yy : '%d ஆண்டுகள்'
|
| 26763 |
},
|
| 26764 |
-
|
| 26765 |
ordinal : function (number) {
|
| 26766 |
return number + 'வது';
|
| 26767 |
},
|
|
@@ -26820,7 +27587,7 @@ webpackJsonp([0],[
|
|
| 26820 |
|
| 26821 |
|
| 26822 |
/***/ },
|
| 26823 |
-
/*
|
| 26824 |
/***/ function(module, exports, __webpack_require__) {
|
| 26825 |
|
| 26826 |
//! moment.js locale configuration
|
|
@@ -26828,7 +27595,7 @@ webpackJsonp([0],[
|
|
| 26828 |
//! author : Krishna Chaitanya Thota : https://github.com/kcthota
|
| 26829 |
|
| 26830 |
;(function (global, factory) {
|
| 26831 |
-
true ? factory(__webpack_require__(
|
| 26832 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26833 |
factory(global.moment)
|
| 26834 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26872,7 +27639,7 @@ webpackJsonp([0],[
|
|
| 26872 |
y : 'ఒక సంవత్సరం',
|
| 26873 |
yy : '%d సంవత్సరాలు'
|
| 26874 |
},
|
| 26875 |
-
|
| 26876 |
ordinal : '%dవ',
|
| 26877 |
meridiemParse: /రాత్రి|ఉదయం|మధ్యాహ్నం|సాయంత్రం/,
|
| 26878 |
meridiemHour : function (hour, meridiem) {
|
|
@@ -26914,7 +27681,7 @@ webpackJsonp([0],[
|
|
| 26914 |
|
| 26915 |
|
| 26916 |
/***/ },
|
| 26917 |
-
/*
|
| 26918 |
/***/ function(module, exports, __webpack_require__) {
|
| 26919 |
|
| 26920 |
//! moment.js locale configuration
|
|
@@ -26923,7 +27690,7 @@ webpackJsonp([0],[
|
|
| 26923 |
//! author : Onorio De J. Afonso : https://github.com/marobo
|
| 26924 |
|
| 26925 |
;(function (global, factory) {
|
| 26926 |
-
true ? factory(__webpack_require__(
|
| 26927 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26928 |
factory(global.moment)
|
| 26929 |
}(this, (function (moment) { 'use strict';
|
|
@@ -26966,7 +27733,7 @@ webpackJsonp([0],[
|
|
| 26966 |
y : 'tinan ida',
|
| 26967 |
yy : 'tinan %d'
|
| 26968 |
},
|
| 26969 |
-
|
| 26970 |
ordinal : function (number) {
|
| 26971 |
var b = number % 10,
|
| 26972 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -26987,7 +27754,7 @@ webpackJsonp([0],[
|
|
| 26987 |
|
| 26988 |
|
| 26989 |
/***/ },
|
| 26990 |
-
/*
|
| 26991 |
/***/ function(module, exports, __webpack_require__) {
|
| 26992 |
|
| 26993 |
//! moment.js locale configuration
|
|
@@ -26995,7 +27762,7 @@ webpackJsonp([0],[
|
|
| 26995 |
//! author : Kridsada Thanabulpong : https://github.com/sirn
|
| 26996 |
|
| 26997 |
;(function (global, factory) {
|
| 26998 |
-
true ? factory(__webpack_require__(
|
| 26999 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27000 |
factory(global.moment)
|
| 27001 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27012,7 +27779,7 @@ webpackJsonp([0],[
|
|
| 27012 |
longDateFormat : {
|
| 27013 |
LT : 'H:mm',
|
| 27014 |
LTS : 'H:mm:ss',
|
| 27015 |
-
L : '
|
| 27016 |
LL : 'D MMMM YYYY',
|
| 27017 |
LLL : 'D MMMM YYYY เวลา H:mm',
|
| 27018 |
LLLL : 'วันddddที่ D MMMM YYYY เวลา H:mm'
|
|
@@ -27059,7 +27826,7 @@ webpackJsonp([0],[
|
|
| 27059 |
|
| 27060 |
|
| 27061 |
/***/ },
|
| 27062 |
-
/*
|
| 27063 |
/***/ function(module, exports, __webpack_require__) {
|
| 27064 |
|
| 27065 |
//! moment.js locale configuration
|
|
@@ -27067,7 +27834,7 @@ webpackJsonp([0],[
|
|
| 27067 |
//! author : Dan Hagman : https://github.com/hagmandan
|
| 27068 |
|
| 27069 |
;(function (global, factory) {
|
| 27070 |
-
true ? factory(__webpack_require__(
|
| 27071 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27072 |
factory(global.moment)
|
| 27073 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27110,7 +27877,7 @@ webpackJsonp([0],[
|
|
| 27110 |
y : 'isang taon',
|
| 27111 |
yy : '%d taon'
|
| 27112 |
},
|
| 27113 |
-
|
| 27114 |
ordinal : function (number) {
|
| 27115 |
return number;
|
| 27116 |
},
|
|
@@ -27126,7 +27893,7 @@ webpackJsonp([0],[
|
|
| 27126 |
|
| 27127 |
|
| 27128 |
/***/ },
|
| 27129 |
-
/*
|
| 27130 |
/***/ function(module, exports, __webpack_require__) {
|
| 27131 |
|
| 27132 |
//! moment.js locale configuration
|
|
@@ -27134,7 +27901,7 @@ webpackJsonp([0],[
|
|
| 27134 |
//! author : Dominika Kruk : https://github.com/amaranthrose
|
| 27135 |
|
| 27136 |
;(function (global, factory) {
|
| 27137 |
-
true ? factory(__webpack_require__(
|
| 27138 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27139 |
factory(global.moment)
|
| 27140 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27237,7 +28004,7 @@ webpackJsonp([0],[
|
|
| 27237 |
y : 'wa’ DIS',
|
| 27238 |
yy : translate
|
| 27239 |
},
|
| 27240 |
-
|
| 27241 |
ordinal : '%d.',
|
| 27242 |
week : {
|
| 27243 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -27251,7 +28018,7 @@ webpackJsonp([0],[
|
|
| 27251 |
|
| 27252 |
|
| 27253 |
/***/ },
|
| 27254 |
-
/*
|
| 27255 |
/***/ function(module, exports, __webpack_require__) {
|
| 27256 |
|
| 27257 |
//! moment.js locale configuration
|
|
@@ -27260,7 +28027,7 @@ webpackJsonp([0],[
|
|
| 27260 |
//! Burak Yiğit Kaya: https://github.com/BYK
|
| 27261 |
|
| 27262 |
;(function (global, factory) {
|
| 27263 |
-
true ? factory(__webpack_require__(
|
| 27264 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27265 |
factory(global.moment)
|
| 27266 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27324,7 +28091,7 @@ webpackJsonp([0],[
|
|
| 27324 |
y : 'bir yıl',
|
| 27325 |
yy : '%d yıl'
|
| 27326 |
},
|
| 27327 |
-
|
| 27328 |
ordinal : function (number) {
|
| 27329 |
if (number === 0) { // special case for zero
|
| 27330 |
return number + '\'ıncı';
|
|
@@ -27346,7 +28113,7 @@ webpackJsonp([0],[
|
|
| 27346 |
|
| 27347 |
|
| 27348 |
/***/ },
|
| 27349 |
-
/*
|
| 27350 |
/***/ function(module, exports, __webpack_require__) {
|
| 27351 |
|
| 27352 |
//! moment.js locale configuration
|
|
@@ -27355,7 +28122,7 @@ webpackJsonp([0],[
|
|
| 27355 |
//! author : Iustì Canun
|
| 27356 |
|
| 27357 |
;(function (global, factory) {
|
| 27358 |
-
true ? factory(__webpack_require__(
|
| 27359 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27360 |
factory(global.moment)
|
| 27361 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27411,7 +28178,7 @@ webpackJsonp([0],[
|
|
| 27411 |
y : processRelativeTime,
|
| 27412 |
yy : processRelativeTime
|
| 27413 |
},
|
| 27414 |
-
|
| 27415 |
ordinal : '%d.',
|
| 27416 |
week : {
|
| 27417 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -27442,7 +28209,7 @@ webpackJsonp([0],[
|
|
| 27442 |
|
| 27443 |
|
| 27444 |
/***/ },
|
| 27445 |
-
/*
|
| 27446 |
/***/ function(module, exports, __webpack_require__) {
|
| 27447 |
|
| 27448 |
//! moment.js locale configuration
|
|
@@ -27450,7 +28217,7 @@ webpackJsonp([0],[
|
|
| 27450 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 27451 |
|
| 27452 |
;(function (global, factory) {
|
| 27453 |
-
true ? factory(__webpack_require__(
|
| 27454 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27455 |
factory(global.moment)
|
| 27456 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27505,7 +28272,7 @@ webpackJsonp([0],[
|
|
| 27505 |
|
| 27506 |
|
| 27507 |
/***/ },
|
| 27508 |
-
/*
|
| 27509 |
/***/ function(module, exports, __webpack_require__) {
|
| 27510 |
|
| 27511 |
//! moment.js locale configuration
|
|
@@ -27513,7 +28280,7 @@ webpackJsonp([0],[
|
|
| 27513 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 27514 |
|
| 27515 |
;(function (global, factory) {
|
| 27516 |
-
true ? factory(__webpack_require__(
|
| 27517 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27518 |
factory(global.moment)
|
| 27519 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27568,7 +28335,7 @@ webpackJsonp([0],[
|
|
| 27568 |
|
| 27569 |
|
| 27570 |
/***/ },
|
| 27571 |
-
/*
|
| 27572 |
/***/ function(module, exports, __webpack_require__) {
|
| 27573 |
|
| 27574 |
//! moment.js locale configuration
|
|
@@ -27577,7 +28344,7 @@ webpackJsonp([0],[
|
|
| 27577 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 27578 |
|
| 27579 |
;(function (global, factory) {
|
| 27580 |
-
true ? factory(__webpack_require__(
|
| 27581 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27582 |
factory(global.moment)
|
| 27583 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27610,8 +28377,13 @@ webpackJsonp([0],[
|
|
| 27610 |
'nominative': 'неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота'.split('_'),
|
| 27611 |
'accusative': 'неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу'.split('_'),
|
| 27612 |
'genitive': 'неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи'.split('_')
|
| 27613 |
-
}
|
| 27614 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27615 |
'accusative' :
|
| 27616 |
((/\[?(?:минулої|наступної)? ?\] ?dddd/).test(format) ?
|
| 27617 |
'genitive' :
|
|
@@ -27692,7 +28464,7 @@ webpackJsonp([0],[
|
|
| 27692 |
return 'вечора';
|
| 27693 |
}
|
| 27694 |
},
|
| 27695 |
-
|
| 27696 |
ordinal: function (number, period) {
|
| 27697 |
switch (period) {
|
| 27698 |
case 'M':
|
|
@@ -27719,7 +28491,111 @@ webpackJsonp([0],[
|
|
| 27719 |
|
| 27720 |
|
| 27721 |
/***/ },
|
| 27722 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27723 |
/***/ function(module, exports, __webpack_require__) {
|
| 27724 |
|
| 27725 |
//! moment.js locale configuration
|
|
@@ -27727,7 +28603,7 @@ webpackJsonp([0],[
|
|
| 27727 |
//! author : Sardor Muminov : https://github.com/muminoff
|
| 27728 |
|
| 27729 |
;(function (global, factory) {
|
| 27730 |
-
true ? factory(__webpack_require__(
|
| 27731 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27732 |
factory(global.moment)
|
| 27733 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27782,7 +28658,70 @@ webpackJsonp([0],[
|
|
| 27782 |
|
| 27783 |
|
| 27784 |
/***/ },
|
| 27785 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27786 |
/***/ function(module, exports, __webpack_require__) {
|
| 27787 |
|
| 27788 |
//! moment.js locale configuration
|
|
@@ -27790,7 +28729,7 @@ webpackJsonp([0],[
|
|
| 27790 |
//! author : Bang Nguyen : https://github.com/bangnk
|
| 27791 |
|
| 27792 |
;(function (global, factory) {
|
| 27793 |
-
true ? factory(__webpack_require__(
|
| 27794 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27795 |
factory(global.moment)
|
| 27796 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27850,7 +28789,7 @@ webpackJsonp([0],[
|
|
| 27850 |
y : 'một năm',
|
| 27851 |
yy : '%d năm'
|
| 27852 |
},
|
| 27853 |
-
|
| 27854 |
ordinal : function (number) {
|
| 27855 |
return number;
|
| 27856 |
},
|
|
@@ -27866,7 +28805,7 @@ webpackJsonp([0],[
|
|
| 27866 |
|
| 27867 |
|
| 27868 |
/***/ },
|
| 27869 |
-
/*
|
| 27870 |
/***/ function(module, exports, __webpack_require__) {
|
| 27871 |
|
| 27872 |
//! moment.js locale configuration
|
|
@@ -27874,7 +28813,7 @@ webpackJsonp([0],[
|
|
| 27874 |
//! author : Andrew Hood : https://github.com/andrewhood125
|
| 27875 |
|
| 27876 |
;(function (global, factory) {
|
| 27877 |
-
true ? factory(__webpack_require__(
|
| 27878 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27879 |
factory(global.moment)
|
| 27880 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27918,7 +28857,7 @@ webpackJsonp([0],[
|
|
| 27918 |
y : 'á ~ýéár',
|
| 27919 |
yy : '%d ý~éárs'
|
| 27920 |
},
|
| 27921 |
-
|
| 27922 |
ordinal : function (number) {
|
| 27923 |
var b = number % 10,
|
| 27924 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -27939,7 +28878,7 @@ webpackJsonp([0],[
|
|
| 27939 |
|
| 27940 |
|
| 27941 |
/***/ },
|
| 27942 |
-
/*
|
| 27943 |
/***/ function(module, exports, __webpack_require__) {
|
| 27944 |
|
| 27945 |
//! moment.js locale configuration
|
|
@@ -27947,7 +28886,7 @@ webpackJsonp([0],[
|
|
| 27947 |
//! author : Atolagbe Abisoye : https://github.com/andela-batolagbe
|
| 27948 |
|
| 27949 |
;(function (global, factory) {
|
| 27950 |
-
true ? factory(__webpack_require__(
|
| 27951 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27952 |
factory(global.moment)
|
| 27953 |
}(this, (function (moment) { 'use strict';
|
|
@@ -27990,7 +28929,7 @@ webpackJsonp([0],[
|
|
| 27990 |
y : 'ọdún kan',
|
| 27991 |
yy : 'ọdún %d'
|
| 27992 |
},
|
| 27993 |
-
|
| 27994 |
ordinal : 'ọjọ́ %d',
|
| 27995 |
week : {
|
| 27996 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -28004,7 +28943,7 @@ webpackJsonp([0],[
|
|
| 28004 |
|
| 28005 |
|
| 28006 |
/***/ },
|
| 28007 |
-
/*
|
| 28008 |
/***/ function(module, exports, __webpack_require__) {
|
| 28009 |
|
| 28010 |
//! moment.js locale configuration
|
|
@@ -28013,7 +28952,7 @@ webpackJsonp([0],[
|
|
| 28013 |
//! author : Zeno Zeng : https://github.com/zenozeng
|
| 28014 |
|
| 28015 |
;(function (global, factory) {
|
| 28016 |
-
true ? factory(__webpack_require__(
|
| 28017 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28018 |
factory(global.moment)
|
| 28019 |
}(this, (function (moment) { 'use strict';
|
|
@@ -28026,16 +28965,16 @@ webpackJsonp([0],[
|
|
| 28026 |
weekdaysShort : '周日_周一_周二_周三_周四_周五_周六'.split('_'),
|
| 28027 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 28028 |
longDateFormat : {
|
| 28029 |
-
LT : '
|
| 28030 |
-
LTS : '
|
| 28031 |
-
L : 'YYYY
|
| 28032 |
LL : 'YYYY年MMMD日',
|
| 28033 |
LLL : 'YYYY年MMMD日Ah点mm分',
|
| 28034 |
LLLL : 'YYYY年MMMD日ddddAh点mm分',
|
| 28035 |
-
l : 'YYYY
|
| 28036 |
ll : 'YYYY年MMMD日',
|
| 28037 |
-
lll : 'YYYY年MMMD日
|
| 28038 |
-
llll : 'YYYY年MMMD日
|
| 28039 |
},
|
| 28040 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 28041 |
meridiemHour: function (hour, meridiem) {
|
|
@@ -28069,30 +29008,14 @@ webpackJsonp([0],[
|
|
| 28069 |
}
|
| 28070 |
},
|
| 28071 |
calendar : {
|
| 28072 |
-
sameDay :
|
| 28073 |
-
|
| 28074 |
-
|
| 28075 |
-
|
| 28076 |
-
|
| 28077 |
-
|
| 28078 |
-
lastDay : function () {
|
| 28079 |
-
return this.minutes() === 0 ? '[昨天]Ah[点整]' : '[昨天]LT';
|
| 28080 |
-
},
|
| 28081 |
-
nextWeek : function () {
|
| 28082 |
-
var startOfWeek, prefix;
|
| 28083 |
-
startOfWeek = moment().startOf('week');
|
| 28084 |
-
prefix = this.diff(startOfWeek, 'days') >= 7 ? '[下]' : '[本]';
|
| 28085 |
-
return this.minutes() === 0 ? prefix + 'dddAh点整' : prefix + 'dddAh点mm';
|
| 28086 |
-
},
|
| 28087 |
-
lastWeek : function () {
|
| 28088 |
-
var startOfWeek, prefix;
|
| 28089 |
-
startOfWeek = moment().startOf('week');
|
| 28090 |
-
prefix = this.unix() < startOfWeek.unix() ? '[上]' : '[本]';
|
| 28091 |
-
return this.minutes() === 0 ? prefix + 'dddAh点整' : prefix + 'dddAh点mm';
|
| 28092 |
-
},
|
| 28093 |
-
sameElse : 'LL'
|
| 28094 |
},
|
| 28095 |
-
|
| 28096 |
ordinal : function (number, period) {
|
| 28097 |
switch (period) {
|
| 28098 |
case 'd':
|
|
@@ -28136,7 +29059,7 @@ webpackJsonp([0],[
|
|
| 28136 |
|
| 28137 |
|
| 28138 |
/***/ },
|
| 28139 |
-
/*
|
| 28140 |
/***/ function(module, exports, __webpack_require__) {
|
| 28141 |
|
| 28142 |
//! moment.js locale configuration
|
|
@@ -28146,7 +29069,7 @@ webpackJsonp([0],[
|
|
| 28146 |
//! author : Konstantin : https://github.com/skfd
|
| 28147 |
|
| 28148 |
;(function (global, factory) {
|
| 28149 |
-
true ? factory(__webpack_require__(
|
| 28150 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28151 |
factory(global.moment)
|
| 28152 |
}(this, (function (moment) { 'use strict';
|
|
@@ -28159,16 +29082,16 @@ webpackJsonp([0],[
|
|
| 28159 |
weekdaysShort : '週日_週一_週二_週三_週四_週五_週六'.split('_'),
|
| 28160 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 28161 |
longDateFormat : {
|
| 28162 |
-
LT : '
|
| 28163 |
-
LTS : '
|
| 28164 |
L : 'YYYY年MMMD日',
|
| 28165 |
LL : 'YYYY年MMMD日',
|
| 28166 |
-
LLL : 'YYYY年MMMD日
|
| 28167 |
-
LLLL : 'YYYY年MMMD日
|
| 28168 |
l : 'YYYY年MMMD日',
|
| 28169 |
ll : 'YYYY年MMMD日',
|
| 28170 |
-
lll : 'YYYY年MMMD日
|
| 28171 |
-
llll : 'YYYY年MMMD日
|
| 28172 |
},
|
| 28173 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 28174 |
meridiemHour : function (hour, meridiem) {
|
|
@@ -28207,7 +29130,7 @@ webpackJsonp([0],[
|
|
| 28207 |
lastWeek : '[上]ddddLT',
|
| 28208 |
sameElse : 'L'
|
| 28209 |
},
|
| 28210 |
-
|
| 28211 |
ordinal : function (number, period) {
|
| 28212 |
switch (period) {
|
| 28213 |
case 'd' :
|
|
@@ -28246,7 +29169,7 @@ webpackJsonp([0],[
|
|
| 28246 |
|
| 28247 |
|
| 28248 |
/***/ },
|
| 28249 |
-
/*
|
| 28250 |
/***/ function(module, exports, __webpack_require__) {
|
| 28251 |
|
| 28252 |
//! moment.js locale configuration
|
|
@@ -28255,7 +29178,7 @@ webpackJsonp([0],[
|
|
| 28255 |
//! author : Chris Lam : https://github.com/hehachris
|
| 28256 |
|
| 28257 |
;(function (global, factory) {
|
| 28258 |
-
true ? factory(__webpack_require__(
|
| 28259 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28260 |
factory(global.moment)
|
| 28261 |
}(this, (function (moment) { 'use strict';
|
|
@@ -28268,16 +29191,16 @@ webpackJsonp([0],[
|
|
| 28268 |
weekdaysShort : '週日_週一_週二_週三_週四_週五_週六'.split('_'),
|
| 28269 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 28270 |
longDateFormat : {
|
| 28271 |
-
LT : '
|
| 28272 |
-
LTS : '
|
| 28273 |
L : 'YYYY年MMMD日',
|
| 28274 |
LL : 'YYYY年MMMD日',
|
| 28275 |
-
LLL : 'YYYY年MMMD日
|
| 28276 |
-
LLLL : 'YYYY年MMMD日
|
| 28277 |
l : 'YYYY年MMMD日',
|
| 28278 |
ll : 'YYYY年MMMD日',
|
| 28279 |
-
lll : 'YYYY年MMMD日
|
| 28280 |
-
llll : 'YYYY年MMMD日
|
| 28281 |
},
|
| 28282 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 28283 |
meridiemHour : function (hour, meridiem) {
|
|
@@ -28316,7 +29239,7 @@ webpackJsonp([0],[
|
|
| 28316 |
lastWeek : '[上]ddddLT',
|
| 28317 |
sameElse : 'L'
|
| 28318 |
},
|
| 28319 |
-
|
| 28320 |
ordinal : function (number, period) {
|
| 28321 |
switch (period) {
|
| 28322 |
case 'd' :
|
|
@@ -28355,13 +29278,13 @@ webpackJsonp([0],[
|
|
| 28355 |
|
| 28356 |
|
| 28357 |
/***/ },
|
| 28358 |
-
/*
|
| 28359 |
-
/*
|
| 28360 |
-
/*
|
| 28361 |
-
/*
|
| 28362 |
-
/*
|
| 28363 |
-
/*
|
| 28364 |
-
/*
|
| 28365 |
/***/ function(module, exports, __webpack_require__) {
|
| 28366 |
|
| 28367 |
'use strict';
|
|
@@ -28378,45 +29301,45 @@ webpackJsonp([0],[
|
|
| 28378 |
|
| 28379 |
var _reactRouter = __webpack_require__(181);
|
| 28380 |
|
| 28381 |
-
var _history = __webpack_require__(
|
| 28382 |
|
| 28383 |
-
var _newslettersTypesJsx = __webpack_require__(
|
| 28384 |
|
| 28385 |
var _newslettersTypesJsx2 = _interopRequireDefault(_newslettersTypesJsx);
|
| 28386 |
|
| 28387 |
-
var _newslettersTemplatesJsx = __webpack_require__(
|
| 28388 |
|
| 28389 |
var _newslettersTemplatesJsx2 = _interopRequireDefault(_newslettersTemplatesJsx);
|
| 28390 |
|
| 28391 |
-
var _newslettersSendJsx = __webpack_require__(
|
| 28392 |
|
| 28393 |
var _newslettersSendJsx2 = _interopRequireDefault(_newslettersSendJsx);
|
| 28394 |
|
| 28395 |
-
var _newslettersTypesStandardJsx = __webpack_require__(
|
| 28396 |
|
| 28397 |
var _newslettersTypesStandardJsx2 = _interopRequireDefault(_newslettersTypesStandardJsx);
|
| 28398 |
|
| 28399 |
-
var _newslettersTypesWelcomeWelcomeJsx = __webpack_require__(
|
| 28400 |
|
| 28401 |
var _newslettersTypesWelcomeWelcomeJsx2 = _interopRequireDefault(_newslettersTypesWelcomeWelcomeJsx);
|
| 28402 |
|
| 28403 |
-
var _newslettersTypesNotificationNotificationJsx = __webpack_require__(
|
| 28404 |
|
| 28405 |
var _newslettersTypesNotificationNotificationJsx2 = _interopRequireDefault(_newslettersTypesNotificationNotificationJsx);
|
| 28406 |
|
| 28407 |
-
var _newslettersListingsStandardJsx = __webpack_require__(
|
| 28408 |
|
| 28409 |
var _newslettersListingsStandardJsx2 = _interopRequireDefault(_newslettersListingsStandardJsx);
|
| 28410 |
|
| 28411 |
-
var _newslettersListingsWelcomeJsx = __webpack_require__(
|
| 28412 |
|
| 28413 |
var _newslettersListingsWelcomeJsx2 = _interopRequireDefault(_newslettersListingsWelcomeJsx);
|
| 28414 |
|
| 28415 |
-
var _newslettersListingsNotificationJsx = __webpack_require__(
|
| 28416 |
|
| 28417 |
var _newslettersListingsNotificationJsx2 = _interopRequireDefault(_newslettersListingsNotificationJsx);
|
| 28418 |
|
| 28419 |
-
var _newslettersListingsNotification_historyJsx = __webpack_require__(
|
| 28420 |
|
| 28421 |
var _newslettersListingsNotification_historyJsx2 = _interopRequireDefault(_newslettersListingsNotification_historyJsx);
|
| 28422 |
|
|
@@ -28458,12 +29381,12 @@ webpackJsonp([0],[
|
|
| 28458 |
/* Listings */ /* Newsletter: type selection */ /* New newsletter: types */ /* Template selection */ /* Sending options */
|
| 28459 |
|
| 28460 |
/***/ },
|
| 28461 |
-
/*
|
| 28462 |
/***/ function(module, exports, __webpack_require__) {
|
| 28463 |
|
| 28464 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 28465 |
|
| 28466 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 28467 |
var NewsletterTypes = React.createClass({
|
| 28468 |
displayName: 'NewsletterTypes',
|
| 28469 |
|
|
@@ -28610,12 +29533,12 @@ webpackJsonp([0],[
|
|
| 28610 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 28611 |
|
| 28612 |
/***/ },
|
| 28613 |
-
/*
|
| 28614 |
/***/ function(module, exports, __webpack_require__) {
|
| 28615 |
|
| 28616 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 28617 |
|
| 28618 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(
|
| 28619 |
var Link = Router.Link;
|
| 28620 |
|
| 28621 |
var Breadcrumb = React.createClass({
|
|
@@ -28678,12 +29601,12 @@ webpackJsonp([0],[
|
|
| 28678 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 28679 |
|
| 28680 |
/***/ },
|
| 28681 |
-
/*
|
| 28682 |
/***/ function(module, exports, __webpack_require__) {
|
| 28683 |
|
| 28684 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 28685 |
|
| 28686 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 28687 |
|
| 28688 |
var ImportTemplate = React.createClass({
|
| 28689 |
displayName: 'ImportTemplate',
|
|
@@ -28950,14 +29873,14 @@ webpackJsonp([0],[
|
|
| 28950 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 28951 |
|
| 28952 |
/***/ },
|
| 28953 |
-
/*
|
| 28954 |
/***/ function(module, exports, __webpack_require__) {
|
| 28955 |
|
| 28956 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 28957 |
|
| 28958 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 28959 |
|
| 28960 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(
|
| 28961 |
|
| 28962 |
var NewsletterSend = React.createClass({
|
| 28963 |
displayName: 'NewsletterSend',
|
|
@@ -29196,7 +30119,7 @@ webpackJsonp([0],[
|
|
| 29196 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29197 |
|
| 29198 |
/***/ },
|
| 29199 |
-
/*
|
| 29200 |
/***/ function(module, exports, __webpack_require__) {
|
| 29201 |
|
| 29202 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
|
@@ -29205,7 +30128,7 @@ webpackJsonp([0],[
|
|
| 29205 |
|
| 29206 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 29207 |
|
| 29208 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(
|
| 29209 |
|
| 29210 |
var settings = window.mailpoet_settings || {},
|
| 29211 |
currentTime = window.mailpoet_current_time || '00:00',
|
|
@@ -29574,14 +30497,14 @@ webpackJsonp([0],[
|
|
| 29574 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29575 |
|
| 29576 |
/***/ },
|
| 29577 |
-
/*
|
| 29578 |
-
/*
|
| 29579 |
-
/*
|
| 29580 |
/***/ function(module, exports, __webpack_require__) {
|
| 29581 |
|
| 29582 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29583 |
|
| 29584 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 29585 |
|
| 29586 |
var settings = window.mailpoet_settings || {};
|
| 29587 |
|
|
@@ -29677,14 +30600,14 @@ webpackJsonp([0],[
|
|
| 29677 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29678 |
|
| 29679 |
/***/ },
|
| 29680 |
-
/*
|
| 29681 |
/***/ function(module, exports, __webpack_require__) {
|
| 29682 |
|
| 29683 |
'use strict';
|
| 29684 |
|
| 29685 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 29686 |
|
| 29687 |
-
var _underscore = __webpack_require__(
|
| 29688 |
|
| 29689 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 29690 |
|
|
@@ -29692,11 +30615,11 @@ webpackJsonp([0],[
|
|
| 29692 |
|
| 29693 |
var _react2 = _interopRequireDefault(_react);
|
| 29694 |
|
| 29695 |
-
var _formFieldsSelectJsx = __webpack_require__(
|
| 29696 |
|
| 29697 |
var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
|
| 29698 |
|
| 29699 |
-
var _newslettersSchedulingCommonJsx = __webpack_require__(
|
| 29700 |
|
| 29701 |
var intervalField = {
|
| 29702 |
name: 'intervalType',
|
|
@@ -29810,7 +30733,7 @@ webpackJsonp([0],[
|
|
| 29810 |
module.exports = NotificationScheduling;
|
| 29811 |
|
| 29812 |
/***/ },
|
| 29813 |
-
/*
|
| 29814 |
/***/ function(module, exports, __webpack_require__) {
|
| 29815 |
|
| 29816 |
'use strict';
|
|
@@ -29821,11 +30744,11 @@ webpackJsonp([0],[
|
|
| 29821 |
|
| 29822 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 29823 |
|
| 29824 |
-
var _underscore = __webpack_require__(
|
| 29825 |
|
| 29826 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 29827 |
|
| 29828 |
-
var _mailpoet = __webpack_require__(
|
| 29829 |
|
| 29830 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 29831 |
|
|
@@ -29904,12 +30827,12 @@ webpackJsonp([0],[
|
|
| 29904 |
exports.nthWeekDayValues = _nthWeekDayValues;
|
| 29905 |
|
| 29906 |
/***/ },
|
| 29907 |
-
/*
|
| 29908 |
/***/ function(module, exports, __webpack_require__) {
|
| 29909 |
|
| 29910 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29911 |
|
| 29912 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 29913 |
|
| 29914 |
var settings = window.mailpoet_settings || {};
|
| 29915 |
|
|
@@ -29978,14 +30901,14 @@ webpackJsonp([0],[
|
|
| 29978 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29979 |
|
| 29980 |
/***/ },
|
| 29981 |
-
/*
|
| 29982 |
/***/ function(module, exports, __webpack_require__) {
|
| 29983 |
|
| 29984 |
'use strict';
|
| 29985 |
|
| 29986 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 29987 |
|
| 29988 |
-
var _underscore = __webpack_require__(
|
| 29989 |
|
| 29990 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 29991 |
|
|
@@ -29993,19 +30916,19 @@ webpackJsonp([0],[
|
|
| 29993 |
|
| 29994 |
var _react2 = _interopRequireDefault(_react);
|
| 29995 |
|
| 29996 |
-
var _mailpoet = __webpack_require__(
|
| 29997 |
|
| 29998 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 29999 |
|
| 30000 |
-
var _formFieldsSelectJsx = __webpack_require__(
|
| 30001 |
|
| 30002 |
var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
|
| 30003 |
|
| 30004 |
-
var _formFieldsTextJsx = __webpack_require__(
|
| 30005 |
|
| 30006 |
var _formFieldsTextJsx2 = _interopRequireDefault(_formFieldsTextJsx);
|
| 30007 |
|
| 30008 |
-
var _newslettersSchedulingCommonJsx = __webpack_require__(
|
| 30009 |
|
| 30010 |
var availableRoles = window.mailpoet_roles || {};
|
| 30011 |
var availableSegments = _underscore2['default'].filter(window.mailpoet_segments || [], function (segment) {
|
|
@@ -30150,12 +31073,12 @@ webpackJsonp([0],[
|
|
| 30150 |
module.exports = WelcomeScheduling;
|
| 30151 |
|
| 30152 |
/***/ },
|
| 30153 |
-
/*
|
| 30154 |
/***/ function(module, exports, __webpack_require__) {
|
| 30155 |
|
| 30156 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30157 |
|
| 30158 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(
|
| 30159 |
|
| 30160 |
var NewsletterStandard = React.createClass({
|
| 30161 |
displayName: 'NewsletterStandard',
|
|
@@ -30204,12 +31127,12 @@ webpackJsonp([0],[
|
|
| 30204 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30205 |
|
| 30206 |
/***/ },
|
| 30207 |
-
/*
|
| 30208 |
/***/ function(module, exports, __webpack_require__) {
|
| 30209 |
|
| 30210 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30211 |
|
| 30212 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 30213 |
|
| 30214 |
var field = {
|
| 30215 |
name: 'options',
|
|
@@ -30306,12 +31229,12 @@ webpackJsonp([0],[
|
|
| 30306 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30307 |
|
| 30308 |
/***/ },
|
| 30309 |
-
/*
|
| 30310 |
/***/ function(module, exports, __webpack_require__) {
|
| 30311 |
|
| 30312 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30313 |
|
| 30314 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 30315 |
|
| 30316 |
var field = {
|
| 30317 |
name: 'options',
|
|
@@ -30400,7 +31323,7 @@ webpackJsonp([0],[
|
|
| 30400 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30401 |
|
| 30402 |
/***/ },
|
| 30403 |
-
/*
|
| 30404 |
/***/ function(module, exports, __webpack_require__) {
|
| 30405 |
|
| 30406 |
'use strict';
|
|
@@ -30413,27 +31336,27 @@ webpackJsonp([0],[
|
|
| 30413 |
|
| 30414 |
var _reactRouter = __webpack_require__(181);
|
| 30415 |
|
| 30416 |
-
var _classnames = __webpack_require__(
|
| 30417 |
|
| 30418 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 30419 |
|
| 30420 |
-
var _jquery = __webpack_require__(
|
| 30421 |
|
| 30422 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 30423 |
|
| 30424 |
-
var _mailpoet = __webpack_require__(
|
| 30425 |
|
| 30426 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 30427 |
|
| 30428 |
-
var _listingListingJsx = __webpack_require__(
|
| 30429 |
|
| 30430 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 30431 |
|
| 30432 |
-
var _newslettersListingsTabsJsx = __webpack_require__(
|
| 30433 |
|
| 30434 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 30435 |
|
| 30436 |
-
var _newslettersListingsMixinsJsx = __webpack_require__(
|
| 30437 |
|
| 30438 |
var mailpoet_tracking_enabled = !!window['mailpoet_tracking_enabled'];
|
| 30439 |
var mailpoet_settings = window.mailpoet_settings || {};
|
|
@@ -30640,7 +31563,7 @@ webpackJsonp([0],[
|
|
| 30640 |
module.exports = NewsletterListStandard;
|
| 30641 |
|
| 30642 |
/***/ },
|
| 30643 |
-
/*
|
| 30644 |
/***/ function(module, exports, __webpack_require__) {
|
| 30645 |
|
| 30646 |
'use strict';
|
|
@@ -30653,11 +31576,11 @@ webpackJsonp([0],[
|
|
| 30653 |
|
| 30654 |
var _reactRouter = __webpack_require__(181);
|
| 30655 |
|
| 30656 |
-
var _classnames = __webpack_require__(
|
| 30657 |
|
| 30658 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 30659 |
|
| 30660 |
-
var _mailpoet = __webpack_require__(
|
| 30661 |
|
| 30662 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 30663 |
|
|
@@ -30710,7 +31633,7 @@ webpackJsonp([0],[
|
|
| 30710 |
module.exports = ListingTabs;
|
| 30711 |
|
| 30712 |
/***/ },
|
| 30713 |
-
/*
|
| 30714 |
/***/ function(module, exports, __webpack_require__) {
|
| 30715 |
|
| 30716 |
'use strict';
|
|
@@ -30729,19 +31652,19 @@ webpackJsonp([0],[
|
|
| 30729 |
|
| 30730 |
var _reactDom2 = _interopRequireDefault(_reactDom);
|
| 30731 |
|
| 30732 |
-
var _reactStringReplace = __webpack_require__(
|
| 30733 |
|
| 30734 |
var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
|
| 30735 |
|
| 30736 |
-
var _mailpoet = __webpack_require__(
|
| 30737 |
|
| 30738 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 30739 |
|
| 30740 |
-
var _classnames = __webpack_require__(
|
| 30741 |
|
| 30742 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 30743 |
|
| 30744 |
-
var _jquery = __webpack_require__(
|
| 30745 |
|
| 30746 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 30747 |
|
|
@@ -30995,7 +31918,7 @@ webpackJsonp([0],[
|
|
| 30995 |
exports.MailerMixin = _MailerMixin;
|
| 30996 |
|
| 30997 |
/***/ },
|
| 30998 |
-
/*
|
| 30999 |
/***/ function(module, exports, __webpack_require__) {
|
| 31000 |
|
| 31001 |
'use strict';
|
|
@@ -31008,31 +31931,31 @@ webpackJsonp([0],[
|
|
| 31008 |
|
| 31009 |
var _reactRouter = __webpack_require__(181);
|
| 31010 |
|
| 31011 |
-
var _history = __webpack_require__(
|
| 31012 |
|
| 31013 |
-
var _listingListingJsx = __webpack_require__(
|
| 31014 |
|
| 31015 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 31016 |
|
| 31017 |
-
var _newslettersListingsTabsJsx = __webpack_require__(
|
| 31018 |
|
| 31019 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 31020 |
|
| 31021 |
-
var _newslettersListingsMixinsJsx = __webpack_require__(
|
| 31022 |
|
| 31023 |
-
var _classnames = __webpack_require__(
|
| 31024 |
|
| 31025 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31026 |
|
| 31027 |
-
var _jquery = __webpack_require__(
|
| 31028 |
|
| 31029 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31030 |
|
| 31031 |
-
var _mailpoet = __webpack_require__(
|
| 31032 |
|
| 31033 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31034 |
|
| 31035 |
-
var _underscore = __webpack_require__(
|
| 31036 |
|
| 31037 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 31038 |
|
|
@@ -31394,7 +32317,7 @@ webpackJsonp([0],[
|
|
| 31394 |
module.exports = NewsletterListWelcome;
|
| 31395 |
|
| 31396 |
/***/ },
|
| 31397 |
-
/*
|
| 31398 |
/***/ function(module, exports, __webpack_require__) {
|
| 31399 |
|
| 31400 |
'use strict';
|
|
@@ -31407,31 +32330,31 @@ webpackJsonp([0],[
|
|
| 31407 |
|
| 31408 |
var _reactRouter = __webpack_require__(181);
|
| 31409 |
|
| 31410 |
-
var _history = __webpack_require__(
|
| 31411 |
|
| 31412 |
-
var _listingListingJsx = __webpack_require__(
|
| 31413 |
|
| 31414 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 31415 |
|
| 31416 |
-
var _newslettersListingsTabsJsx = __webpack_require__(
|
| 31417 |
|
| 31418 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 31419 |
|
| 31420 |
-
var _newslettersListingsMixinsJsx = __webpack_require__(
|
| 31421 |
|
| 31422 |
-
var _classnames = __webpack_require__(
|
| 31423 |
|
| 31424 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31425 |
|
| 31426 |
-
var _jquery = __webpack_require__(
|
| 31427 |
|
| 31428 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31429 |
|
| 31430 |
-
var _mailpoet = __webpack_require__(
|
| 31431 |
|
| 31432 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31433 |
|
| 31434 |
-
var _newslettersSchedulingCommonJsx = __webpack_require__(
|
| 31435 |
|
| 31436 |
var mailpoet_settings = window.mailpoet_settings || {};
|
| 31437 |
|
|
@@ -31746,7 +32669,7 @@ webpackJsonp([0],[
|
|
| 31746 |
module.exports = NewsletterListNotification;
|
| 31747 |
|
| 31748 |
/***/ },
|
| 31749 |
-
/*
|
| 31750 |
/***/ function(module, exports, __webpack_require__) {
|
| 31751 |
|
| 31752 |
'use strict';
|
|
@@ -31759,27 +32682,27 @@ webpackJsonp([0],[
|
|
| 31759 |
|
| 31760 |
var _reactRouter = __webpack_require__(181);
|
| 31761 |
|
| 31762 |
-
var _classnames = __webpack_require__(
|
| 31763 |
|
| 31764 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31765 |
|
| 31766 |
-
var _jquery = __webpack_require__(
|
| 31767 |
|
| 31768 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31769 |
|
| 31770 |
-
var _mailpoet = __webpack_require__(
|
| 31771 |
|
| 31772 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31773 |
|
| 31774 |
-
var _listingListingJsx = __webpack_require__(
|
| 31775 |
|
| 31776 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 31777 |
|
| 31778 |
-
var _newslettersListingsTabsJsx = __webpack_require__(
|
| 31779 |
|
| 31780 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 31781 |
|
| 31782 |
-
var _newslettersListingsMixinsJsx = __webpack_require__(
|
| 31783 |
|
| 31784 |
var mailpoet_tracking_enabled = !!window['mailpoet_tracking_enabled'];
|
| 31785 |
var mailpoet_settings = window.mailpoet_settings || {};
|
|
@@ -31918,7 +32841,7 @@ webpackJsonp([0],[
|
|
| 31918 |
module.exports = NewsletterListNotificationHistory;
|
| 31919 |
|
| 31920 |
/***/ },
|
| 31921 |
-
/*
|
| 31922 |
/***/ function(module, exports, __webpack_require__) {
|
| 31923 |
|
| 31924 |
'use strict';
|
|
@@ -31935,13 +32858,13 @@ webpackJsonp([0],[
|
|
| 31935 |
|
| 31936 |
var _reactRouter = __webpack_require__(181);
|
| 31937 |
|
| 31938 |
-
var _history = __webpack_require__(
|
| 31939 |
|
| 31940 |
-
var _segmentsListJsx = __webpack_require__(
|
| 31941 |
|
| 31942 |
var _segmentsListJsx2 = _interopRequireDefault(_segmentsListJsx);
|
| 31943 |
|
| 31944 |
-
var _segmentsFormJsx = __webpack_require__(
|
| 31945 |
|
| 31946 |
var _segmentsFormJsx2 = _interopRequireDefault(_segmentsFormJsx);
|
| 31947 |
|
|
@@ -31973,7 +32896,7 @@ webpackJsonp([0],[
|
|
| 31973 |
}
|
| 31974 |
|
| 31975 |
/***/ },
|
| 31976 |
-
/*
|
| 31977 |
/***/ function(module, exports, __webpack_require__) {
|
| 31978 |
|
| 31979 |
'use strict';
|
|
@@ -31986,19 +32909,19 @@ webpackJsonp([0],[
|
|
| 31986 |
|
| 31987 |
var _reactRouter = __webpack_require__(181);
|
| 31988 |
|
| 31989 |
-
var _jquery = __webpack_require__(
|
| 31990 |
|
| 31991 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31992 |
|
| 31993 |
-
var _mailpoet = __webpack_require__(
|
| 31994 |
|
| 31995 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31996 |
|
| 31997 |
-
var _classnames = __webpack_require__(
|
| 31998 |
|
| 31999 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 32000 |
|
| 32001 |
-
var _listingListingJsx = __webpack_require__(
|
| 32002 |
|
| 32003 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 32004 |
|
|
@@ -32289,12 +33212,12 @@ webpackJsonp([0],[
|
|
| 32289 |
module.exports = SegmentList;
|
| 32290 |
|
| 32291 |
/***/ },
|
| 32292 |
-
/*
|
| 32293 |
/***/ function(module, exports, __webpack_require__) {
|
| 32294 |
|
| 32295 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 32296 |
|
| 32297 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(
|
| 32298 |
|
| 32299 |
var fields = [{
|
| 32300 |
name: 'name',
|
|
@@ -32349,7 +33272,7 @@ webpackJsonp([0],[
|
|
| 32349 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 32350 |
|
| 32351 |
/***/ },
|
| 32352 |
-
/*
|
| 32353 |
/***/ function(module, exports, __webpack_require__) {
|
| 32354 |
|
| 32355 |
'use strict';
|
|
@@ -32366,9 +33289,9 @@ webpackJsonp([0],[
|
|
| 32366 |
|
| 32367 |
var _reactRouter = __webpack_require__(181);
|
| 32368 |
|
| 32369 |
-
var _history = __webpack_require__(
|
| 32370 |
|
| 32371 |
-
var _formsListJsx = __webpack_require__(
|
| 32372 |
|
| 32373 |
var _formsListJsx2 = _interopRequireDefault(_formsListJsx);
|
| 32374 |
|
|
@@ -32398,7 +33321,7 @@ webpackJsonp([0],[
|
|
| 32398 |
}
|
| 32399 |
|
| 32400 |
/***/ },
|
| 32401 |
-
/*
|
| 32402 |
/***/ function(module, exports, __webpack_require__) {
|
| 32403 |
|
| 32404 |
'use strict';
|
|
@@ -32415,15 +33338,15 @@ webpackJsonp([0],[
|
|
| 32415 |
|
| 32416 |
var _reactRouter = __webpack_require__(181);
|
| 32417 |
|
| 32418 |
-
var _listingListingJsx = __webpack_require__(
|
| 32419 |
|
| 32420 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 32421 |
|
| 32422 |
-
var _classnames = __webpack_require__(
|
| 32423 |
|
| 32424 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 32425 |
|
| 32426 |
-
var _mailpoet = __webpack_require__(
|
| 32427 |
|
| 32428 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 32429 |
|
|
@@ -32629,13 +33552,13 @@ webpackJsonp([0],[
|
|
| 32629 |
module.exports = FormList;
|
| 32630 |
|
| 32631 |
/***/ },
|
| 32632 |
-
/*
|
| 32633 |
/***/ function(module, exports, __webpack_require__) {
|
| 32634 |
|
| 32635 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 32636 |
-
__webpack_require__(
|
| 32637 |
-
__webpack_require__(
|
| 32638 |
-
__webpack_require__(
|
| 32639 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function(
|
| 32640 |
Backbone,
|
| 32641 |
jQuery,
|
|
@@ -32710,14 +33633,14 @@ webpackJsonp([0],[
|
|
| 32710 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 32711 |
|
| 32712 |
/***/ },
|
| 32713 |
-
/*
|
| 32714 |
/***/ function(module, exports, __webpack_require__) {
|
| 32715 |
|
| 32716 |
-
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["Backbone"] = __webpack_require__(
|
| 32717 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 32718 |
|
| 32719 |
/***/ },
|
| 32720 |
-
/*
|
| 32721 |
/***/ function(module, exports, __webpack_require__) {
|
| 32722 |
|
| 32723 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* WEBPACK VAR INJECTION */(function(global) {// Backbone.js 1.3.3
|
|
@@ -32736,7 +33659,7 @@ webpackJsonp([0],[
|
|
| 32736 |
|
| 32737 |
// Set up Backbone appropriately for the environment. Start with AMD.
|
| 32738 |
if (true) {
|
| 32739 |
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
| 32740 |
// Export global even in AMD case in case this script is loaded with
|
| 32741 |
// others that may still expect a global Backbone.
|
| 32742 |
root.Backbone = factory(root, exports, _, $);
|
|
@@ -34644,19 +35567,19 @@ webpackJsonp([0],[
|
|
| 34644 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 34645 |
|
| 34646 |
/***/ },
|
| 34647 |
-
/*
|
| 34648 |
/***/ function(module, exports, __webpack_require__) {
|
| 34649 |
|
| 34650 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 34651 |
-
__webpack_require__(
|
| 34652 |
-
__webpack_require__(
|
| 34653 |
-
__webpack_require__(
|
| 34654 |
-
__webpack_require__(
|
| 34655 |
-
__webpack_require__(
|
| 34656 |
-
__webpack_require__(
|
| 34657 |
-
__webpack_require__(
|
| 34658 |
-
__webpack_require__(
|
| 34659 |
-
__webpack_require__(
|
| 34660 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function (
|
| 34661 |
Backbone,
|
| 34662 |
_,
|
|
@@ -35758,8 +36681,8 @@ webpackJsonp([0],[
|
|
| 35758 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 35759 |
|
| 35760 |
/***/ },
|
| 35761 |
-
/*
|
| 35762 |
-
/*
|
| 35763 |
/***/ function(module, exports) {
|
| 35764 |
|
| 35765 |
/*!
|
|
@@ -35770,7 +36693,7 @@ webpackJsonp([0],[
|
|
| 35770 |
!function(e){"use strict";function t(t,r){if(r=r||{},r.worker&&w.WORKERS_SUPPORTED){var n=h();return n.userStep=r.step,n.userChunk=r.chunk,n.userComplete=r.complete,n.userError=r.error,r.step=m(r.step),r.chunk=m(r.chunk),r.complete=m(r.complete),r.error=m(r.error),delete r.worker,void n.postMessage({input:t,config:r,workerId:n.id})}var o=null;return"string"==typeof t?o=r.download?new i(r):new a(r):(e.File&&t instanceof File||t instanceof Object)&&(o=new s(r)),o.stream(t)}function r(e,t){function r(){"object"==typeof t&&("string"==typeof t.delimiter&&1==t.delimiter.length&&-1==w.BAD_DELIMITERS.indexOf(t.delimiter)&&(u=t.delimiter),("boolean"==typeof t.quotes||t.quotes instanceof Array)&&(o=t.quotes),"string"==typeof t.newline&&(f=t.newline))}function n(e){if("object"!=typeof e)return[];var t=[];for(var r in e)t.push(r);return t}function i(e,t){var r="";"string"==typeof e&&(e=JSON.parse(e)),"string"==typeof t&&(t=JSON.parse(t));var n=e instanceof Array&&e.length>0,i=!(t[0]instanceof Array);if(n){for(var a=0;a<e.length;a++)a>0&&(r+=u),r+=s(e[a],a);t.length>0&&(r+=f)}for(var o=0;o<t.length;o++){for(var h=n?e.length:t[o].length,d=0;h>d;d++){d>0&&(r+=u);var c=n&&i?e[d]:d;r+=s(t[o][c],d)}o<t.length-1&&(r+=f)}return r}function s(e,t){if("undefined"==typeof e||null===e)return"";e=e.toString().replace(/"/g,'""');var r="boolean"==typeof o&&o||o instanceof Array&&o[t]||a(e,w.BAD_DELIMITERS)||e.indexOf(u)>-1||" "==e.charAt(0)||" "==e.charAt(e.length-1);return r?'"'+e+'"':e}function a(e,t){for(var r=0;r<t.length;r++)if(e.indexOf(t[r])>-1)return!0;return!1}var o=!1,u=",",f="\r\n";if(r(),"string"==typeof e&&(e=JSON.parse(e)),e instanceof Array){if(!e.length||e[0]instanceof Array)return i(null,e);if("object"==typeof e[0])return i(n(e[0]),e)}else if("object"==typeof e)return"string"==typeof e.data&&(e.data=JSON.parse(e.data)),e.data instanceof Array&&(e.fields||(e.fields=e.data[0]instanceof Array?e.fields:n(e.data[0])),e.data[0]instanceof Array||"object"==typeof e.data[0]||(e.data=[e.data])),i(e.fields||[],e.data||[]);throw"exception: Unable to serialize unrecognized input"}function n(t){function r(e){var t=_(e);t.chunkSize=parseInt(t.chunkSize),this._handle=new o(t),this._handle.streamer=this,this._config=t}this._handle=null,this._paused=!1,this._finished=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this._completeResults={data:[],errors:[],meta:{}},r.call(this,t),this.parseChunk=function(t){var r=this._partialLine+t;this._partialLine="";var n=this._handle.parse(r,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.aborted()){var i=n.meta.cursor;this._finished||(this._partialLine=r.substring(i-this._baseIndex),this._baseIndex=i),n&&n.data&&(this._rowCount+=n.data.length);var s=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(k)e.postMessage({results:n,workerId:w.WORKER_ID,finished:s});else if(m(this._config.chunk)){if(this._config.chunk(n,this._handle),this._paused)return;n=void 0,this._completeResults=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(n.data),this._completeResults.errors=this._completeResults.errors.concat(n.errors),this._completeResults.meta=n.meta),!s||!m(this._config.complete)||n&&n.meta.aborted||this._config.complete(this._completeResults),s||n&&n.meta.paused||this._nextChunk(),n}},this._sendError=function(t){m(this._config.error)?this._config.error(t):k&&this._config.error&&e.postMessage({workerId:w.WORKER_ID,error:t,finished:!1})}}function i(e){function t(e){var t=e.getResponseHeader("Content-Range");return parseInt(t.substr(t.lastIndexOf("/")+1))}e=e||{},e.chunkSize||(e.chunkSize=w.RemoteChunkSize),n.call(this,e);var r;this._nextChunk=k?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(e){this._input=e,this._nextChunk()},this._readChunk=function(){if(this._finished)return void this._chunkLoaded();if(r=new XMLHttpRequest,k||(r.onload=g(this._chunkLoaded,this),r.onerror=g(this._chunkError,this)),r.open("GET",this._input,!k),this._config.chunkSize){var e=this._start+this._config.chunkSize-1;r.setRequestHeader("Range","bytes="+this._start+"-"+e),r.setRequestHeader("If-None-Match","webkit-no-cache")}try{r.send()}catch(t){this._chunkError(t.message)}k&&0==r.status?this._chunkError():this._start+=this._config.chunkSize},this._chunkLoaded=function(){if(4==r.readyState){if(r.status<200||r.status>=400)return void this._chunkError();this._finished=!this._config.chunkSize||this._start>t(r),this.parseChunk(r.responseText)}},this._chunkError=function(e){var t=r.statusText||e;this._sendError(t)}}function s(e){e=e||{},e.chunkSize||(e.chunkSize=w.LocalChunkSize),n.call(this,e);var t,r,i="undefined"!=typeof FileReader;this.stream=function(e){this._input=e,r=e.slice||e.webkitSlice||e.mozSlice,i?(t=new FileReader,t.onload=g(this._chunkLoaded,this),t.onerror=g(this._chunkError,this)):t=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var e=this._input;if(this._config.chunkSize){var n=Math.min(this._start+this._config.chunkSize,this._input.size);e=r.call(e,this._start,n)}var s=t.readAsText(e,this._config.encoding);i||this._chunkLoaded({target:{result:s}})},this._chunkLoaded=function(e){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(e.target.result)},this._chunkError=function(){this._sendError(t.error)}}function a(e){e=e||{},n.call(this,e);var t,r;this.stream=function(e){return t=e,r=e,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var e=this._config.chunkSize,t=e?r.substr(0,e):r;return r=e?r.substr(e):"",this._finished=!r,this.parseChunk(t)}}}function o(e){function t(){if(b&&c&&(f("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+w.DefaultDelimiter+"'"),c=!1),e.skipEmptyLines)for(var t=0;t<b.data.length;t++)1==b.data[t].length&&""==b.data[t][0]&&b.data.splice(t--,1);return r()&&n(),i()}function r(){return e.header&&0==y.length}function n(){if(b){for(var e=0;r()&&e<b.data.length;e++)for(var t=0;t<b.data[e].length;t++)y.push(b.data[e][t]);b.data.splice(0,1)}}function i(){if(!b||!e.header&&!e.dynamicTyping)return b;for(var t=0;t<b.data.length;t++){for(var r={},n=0;n<b.data[t].length;n++){if(e.dynamicTyping){var i=b.data[t][n];b.data[t][n]="true"==i||"TRUE"==i?!0:"false"==i||"FALSE"==i?!1:o(i)}e.header&&(n>=y.length?(r.__parsed_extra||(r.__parsed_extra=[]),r.__parsed_extra.push(b.data[t][n])):r[y[n]]=b.data[t][n])}e.header&&(b.data[t]=r,n>y.length?f("FieldMismatch","TooManyFields","Too many fields: expected "+y.length+" fields but parsed "+n,t):n<y.length&&f("FieldMismatch","TooFewFields","Too few fields: expected "+y.length+" fields but parsed "+n,t))}return e.header&&b.meta&&(b.meta.fields=y),b}function s(t){for(var r,n,i,s=[","," ","|",";",w.RECORD_SEP,w.UNIT_SEP],a=0;a<s.length;a++){var o=s[a],f=0,h=0;i=void 0;for(var d=new u({delimiter:o,preview:10}).parse(t),c=0;c<d.data.length;c++){var l=d.data[c].length;h+=l,"undefined"!=typeof i?l>1&&(f+=Math.abs(l-i),i=l):i=l}h/=d.data.length,("undefined"==typeof n||n>f)&&h>1.99&&(n=f,r=o)}return e.delimiter=r,{successful:!!r,bestDelimiter:r}}function a(e){e=e.substr(0,1048576);var t=e.split("\r");if(1==t.length)return"\n";for(var r=0,n=0;n<t.length;n++)"\n"==t[n][0]&&r++;return r>=t.length/2?"\r\n":"\r"}function o(e){var t=l.test(e);return t?parseFloat(e):e}function f(e,t,r,n){b.errors.push({type:e,code:t,message:r,row:n})}var h,d,c,l=/^\s*-?(\d*\.?\d+|\d+\.?\d*)(e[-+]?\d+)?\s*$/i,p=this,g=0,v=!1,k=!1,y=[],b={data:[],errors:[],meta:{}};if(m(e.step)){var R=e.step;e.step=function(n){if(b=n,r())t();else{if(t(),0==b.data.length)return;g+=n.data.length,e.preview&&g>e.preview?d.abort():R(b,p)}}}this.parse=function(r,n,i){if(e.newline||(e.newline=a(r)),c=!1,!e.delimiter){var o=s(r);o.successful?e.delimiter=o.bestDelimiter:(c=!0,e.delimiter=w.DefaultDelimiter),b.meta.delimiter=e.delimiter}var f=_(e);return e.preview&&e.header&&f.preview++,h=r,d=new u(f),b=d.parse(h,n,i),t(),v?{meta:{paused:!0}}:b||{meta:{paused:!1}}},this.paused=function(){return v},this.pause=function(){v=!0,d.abort(),h=h.substr(d.getCharIndex())},this.resume=function(){v=!1,p.streamer.parseChunk(h)},this.aborted=function(){return k},this.abort=function(){k=!0,d.abort(),b.meta.aborted=!0,m(e.complete)&&e.complete(b),h=""}}function u(e){e=e||{};var t=e.delimiter,r=e.newline,n=e.comments,i=e.step,s=e.preview,a=e.fastMode;if(("string"!=typeof t||w.BAD_DELIMITERS.indexOf(t)>-1)&&(t=","),n===t)throw"Comment character same as delimiter";n===!0?n="#":("string"!=typeof n||w.BAD_DELIMITERS.indexOf(n)>-1)&&(n=!1),"\n"!=r&&"\r"!=r&&"\r\n"!=r&&(r="\n");var o=0,u=!1;this.parse=function(e,f,h){function d(e){b.push(e),S=o}function c(t){return h?p():(t||(t=e.substr(o)),w.push(t),o=g,d(w),y&&_(),p())}function l(t){o=t,d(w),w=[],O=e.indexOf(r,o)}function p(e){return{data:b,errors:R,meta:{delimiter:t,linebreak:r,aborted:u,truncated:!!e,cursor:S+(f||0)}}}function _(){i(p()),b=[],R=[]}if("string"!=typeof e)throw"Input must be a string";var g=e.length,m=t.length,v=r.length,k=n.length,y="function"==typeof i;o=0;var b=[],R=[],w=[],S=0;if(!e)return p();if(a||a!==!1&&-1===e.indexOf('"')){for(var E=e.split(r),C=0;C<E.length;C++){var w=E[C];if(o+=w.length,C!==E.length-1)o+=r.length;else if(h)return p();if(!n||w.substr(0,k)!=n){if(y){if(b=[],d(w.split(t)),_(),u)return p()}else d(w.split(t));if(s&&C>=s)return b=b.slice(0,s),p(!0)}}return p()}for(var x=e.indexOf(t,o),O=e.indexOf(r,o);;)if('"'!=e[o])if(n&&0===w.length&&e.substr(o,k)===n){if(-1==O)return p();o=O+v,O=e.indexOf(r,o),x=e.indexOf(t,o)}else if(-1!==x&&(O>x||-1===O))w.push(e.substring(o,x)),o=x+m,x=e.indexOf(t,o);else{if(-1===O)break;if(w.push(e.substring(o,O)),l(O+v),y&&(_(),u))return p();if(s&&b.length>=s)return p(!0)}else{var I=o;for(o++;;){var I=e.indexOf('"',I+1);if(-1===I)return h||R.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:b.length,index:o}),c();if(I===g-1){var D=e.substring(o,I).replace(/""/g,'"');return c(D)}if('"'!=e[I+1]){if(e[I+1]==t){w.push(e.substring(o,I).replace(/""/g,'"')),o=I+1+m,x=e.indexOf(t,o),O=e.indexOf(r,o);break}if(e.substr(I+1,v)===r){if(w.push(e.substring(o,I).replace(/""/g,'"')),l(I+1+v),x=e.indexOf(t,o),y&&(_(),u))return p();if(s&&b.length>=s)return p(!0);break}}else I++}}return c()},this.abort=function(){u=!0},this.getCharIndex=function(){return o}}function f(){var e=document.getElementsByTagName("script");return e.length?e[e.length-1].src:""}function h(){if(!w.WORKERS_SUPPORTED)return!1;if(!y&&null===w.SCRIPT_PATH)throw new Error("Script path cannot be determined automatically when Papa Parse is loaded asynchronously. You need to set Papa.SCRIPT_PATH manually.");var t=new e.Worker(w.SCRIPT_PATH||v);return t.onmessage=d,t.id=R++,b[t.id]=t,t}function d(e){var t=e.data,r=b[t.workerId],n=!1;if(t.error)r.userError(t.error,t.file);else if(t.results&&t.results.data){var i=function(){n=!0,c(t.workerId,{data:[],errors:[],meta:{aborted:!0}})},s={abort:i,pause:l,resume:l};if(m(r.userStep)){for(var a=0;a<t.results.data.length&&(r.userStep({data:[t.results.data[a]],errors:t.results.errors,meta:t.results.meta},s),!n);a++);delete t.results}else m(r.userChunk)&&(r.userChunk(t.results,s,t.file),delete t.results)}t.finished&&!n&&c(t.workerId,t.results)}function c(e,t){var r=b[e];m(r.userComplete)&&r.userComplete(t),r.terminate(),delete b[e]}function l(){throw"Not implemented."}function p(t){var r=t.data;if("undefined"==typeof w.WORKER_ID&&r&&(w.WORKER_ID=r.workerId),"string"==typeof r.input)e.postMessage({workerId:w.WORKER_ID,results:w.parse(r.input,r.config),finished:!0});else if(e.File&&r.input instanceof File||r.input instanceof Object){var n=w.parse(r.input,r.config);n&&e.postMessage({workerId:w.WORKER_ID,results:n,finished:!0})}}function _(e){if("object"!=typeof e)return e;var t=e instanceof Array?[]:{};for(var r in e)t[r]=_(e[r]);return t}function g(e,t){return function(){e.apply(t,arguments)}}function m(e){return"function"==typeof e}var v,k=!e.document&&!!e.postMessage,y=!1,b={},R=0,w={};if(w.parse=t,w.unparse=r,w.RECORD_SEP=String.fromCharCode(30),w.UNIT_SEP=String.fromCharCode(31),w.BYTE_ORDER_MARK="",w.BAD_DELIMITERS=["\r","\n",'"',w.BYTE_ORDER_MARK],w.WORKERS_SUPPORTED=!!e.Worker,w.SCRIPT_PATH=null,w.LocalChunkSize=10485760,w.RemoteChunkSize=5242880,w.DefaultDelimiter=",",w.Parser=u,w.ParserHandle=o,w.NetworkStreamer=i,w.FileStreamer=s,w.StringStreamer=a,"undefined"!=typeof module&&module.exports?module.exports=w:m(e.define)&&e.define.amd?e.define(function(){return w}):e.Papa=w,e.jQuery){var S=e.jQuery;S.fn.parse=function(t){function r(){if(0==a.length)return void(m(t.complete)&&t.complete());var e=a[0];if(m(t.before)){var r=t.before(e.file,e.inputElem);if("object"==typeof r){if("abort"==r.action)return void n("AbortError",e.file,e.inputElem,r.reason);if("skip"==r.action)return void i();"object"==typeof r.config&&(e.instanceConfig=S.extend(e.instanceConfig,r.config))}else if("skip"==r)return void i()}var s=e.instanceConfig.complete;e.instanceConfig.complete=function(t){m(s)&&s(t,e.file,e.inputElem),i()},w.parse(e.file,e.instanceConfig)}function n(e,r,n,i){m(t.error)&&t.error({name:e},r,n,i)}function i(){a.splice(0,1),r()}var s=t.config||{},a=[];return this.each(function(){var t="INPUT"==S(this).prop("tagName").toUpperCase()&&"file"==S(this).attr("type").toLowerCase()&&e.FileReader;if(!t||!this.files||0==this.files.length)return!0;for(var r=0;r<this.files.length;r++)a.push({file:this.files[r],inputElem:this,instanceConfig:S.extend({},s)})}),r(),this}}k?e.onmessage=p:w.WORKERS_SUPPORTED&&(v=f(),document.body?document.addEventListener("DOMContentLoaded",function(){y=!0},!0):y=!0),i.prototype=Object.create(n.prototype),i.prototype.constructor=i,s.prototype=Object.create(n.prototype),s.prototype.constructor=s,a.prototype=Object.create(a.prototype),a.prototype.constructor=a}("undefined"!=typeof window?window:this);
|
| 35771 |
|
| 35772 |
/***/ },
|
| 35773 |
-
/*
|
| 35774 |
/***/ function(module, exports) {
|
| 35775 |
|
| 35776 |
/*
|
|
@@ -35855,15 +36778,15 @@ webpackJsonp([0],[
|
|
| 35855 |
|
| 35856 |
|
| 35857 |
/***/ },
|
| 35858 |
-
/*
|
| 35859 |
/***/ function(module, exports, __webpack_require__) {
|
| 35860 |
|
| 35861 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 35862 |
-
__webpack_require__(
|
| 35863 |
-
__webpack_require__(
|
| 35864 |
-
__webpack_require__(
|
| 35865 |
-
__webpack_require__(
|
| 35866 |
-
__webpack_require__(
|
| 35867 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function (
|
| 35868 |
_,
|
| 35869 |
jQuery,
|
|
@@ -36028,7 +36951,7 @@ webpackJsonp([0],[
|
|
| 36028 |
|
| 36029 |
|
| 36030 |
/***/ },
|
| 36031 |
-
/*
|
| 36032 |
/***/ function(module, exports, __webpack_require__) {
|
| 36033 |
|
| 36034 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
| 3 |
/***/ function(module, exports, __webpack_require__) {
|
| 4 |
|
| 5 |
__webpack_require__(1);
|
| 6 |
+
__webpack_require__(421);
|
| 7 |
+
__webpack_require__(443);
|
| 8 |
+
__webpack_require__(446);
|
| 9 |
+
__webpack_require__(448);
|
| 10 |
+
__webpack_require__(451);
|
| 11 |
+
__webpack_require__(455);
|
| 12 |
+
module.exports = __webpack_require__(456);
|
| 13 |
|
| 14 |
|
| 15 |
/***/ },
|
| 30 |
|
| 31 |
var _reactRouter = __webpack_require__(181);
|
| 32 |
|
| 33 |
+
var _history = __webpack_require__(244);
|
| 34 |
|
| 35 |
+
var _subscribersListJsx = __webpack_require__(273);
|
| 36 |
|
| 37 |
var _subscribersListJsx2 = _interopRequireDefault(_subscribersListJsx);
|
| 38 |
|
| 39 |
+
var _subscribersFormJsx = __webpack_require__(288);
|
| 40 |
|
| 41 |
var _subscribersFormJsx2 = _interopRequireDefault(_subscribersFormJsx);
|
| 42 |
|
| 303 |
/* 234 */,
|
| 304 |
/* 235 */,
|
| 305 |
/* 236 */,
|
| 306 |
+
/* 237 */,
|
| 307 |
+
/* 238 */,
|
| 308 |
+
/* 239 */,
|
| 309 |
+
/* 240 */,
|
| 310 |
+
/* 241 */,
|
| 311 |
+
/* 242 */,
|
| 312 |
+
/* 243 */,
|
| 313 |
+
/* 244 */
|
| 314 |
/***/ function(module, exports, __webpack_require__) {
|
| 315 |
|
| 316 |
'use strict';
|
| 319 |
|
| 320 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 321 |
|
| 322 |
+
var _createBrowserHistory = __webpack_require__(245);
|
| 323 |
|
| 324 |
var _createBrowserHistory2 = _interopRequireDefault(_createBrowserHistory);
|
| 325 |
|
| 326 |
exports.createHistory = _createBrowserHistory2['default'];
|
| 327 |
|
| 328 |
+
var _createHashHistory2 = __webpack_require__(262);
|
| 329 |
|
| 330 |
var _createHashHistory3 = _interopRequireDefault(_createHashHistory2);
|
| 331 |
|
| 332 |
exports.createHashHistory = _createHashHistory3['default'];
|
| 333 |
|
| 334 |
+
var _createMemoryHistory2 = __webpack_require__(263);
|
| 335 |
|
| 336 |
var _createMemoryHistory3 = _interopRequireDefault(_createMemoryHistory2);
|
| 337 |
|
| 338 |
exports.createMemoryHistory = _createMemoryHistory3['default'];
|
| 339 |
|
| 340 |
+
var _createLocation2 = __webpack_require__(257);
|
| 341 |
|
| 342 |
var _createLocation3 = _interopRequireDefault(_createLocation2);
|
| 343 |
|
| 344 |
exports.createLocation = _createLocation3['default'];
|
| 345 |
|
| 346 |
+
var _useBasename2 = __webpack_require__(264);
|
| 347 |
|
| 348 |
var _useBasename3 = _interopRequireDefault(_useBasename2);
|
| 349 |
|
| 350 |
exports.useBasename = _useBasename3['default'];
|
| 351 |
|
| 352 |
+
var _useBeforeUnload2 = __webpack_require__(265);
|
| 353 |
|
| 354 |
var _useBeforeUnload3 = _interopRequireDefault(_useBeforeUnload2);
|
| 355 |
|
| 356 |
exports.useBeforeUnload = _useBeforeUnload3['default'];
|
| 357 |
|
| 358 |
+
var _useQueries2 = __webpack_require__(266);
|
| 359 |
|
| 360 |
var _useQueries3 = _interopRequireDefault(_useQueries2);
|
| 361 |
|
| 362 |
exports.useQueries = _useQueries3['default'];
|
| 363 |
|
| 364 |
+
var _Actions2 = __webpack_require__(246);
|
| 365 |
|
| 366 |
var _Actions3 = _interopRequireDefault(_Actions2);
|
| 367 |
|
| 369 |
|
| 370 |
// deprecated
|
| 371 |
|
| 372 |
+
var _enableBeforeUnload2 = __webpack_require__(271);
|
| 373 |
|
| 374 |
var _enableBeforeUnload3 = _interopRequireDefault(_enableBeforeUnload2);
|
| 375 |
|
| 376 |
exports.enableBeforeUnload = _enableBeforeUnload3['default'];
|
| 377 |
|
| 378 |
+
var _enableQueries2 = __webpack_require__(272);
|
| 379 |
|
| 380 |
var _enableQueries3 = _interopRequireDefault(_enableQueries2);
|
| 381 |
|
| 382 |
exports.enableQueries = _enableQueries3['default'];
|
| 383 |
|
| 384 |
/***/ },
|
| 385 |
+
/* 245 */
|
| 386 |
/***/ function(module, exports, __webpack_require__) {
|
| 387 |
|
| 388 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 393 |
|
| 394 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 395 |
|
| 396 |
+
var _invariant = __webpack_require__(189);
|
| 397 |
|
| 398 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 399 |
|
| 400 |
+
var _Actions = __webpack_require__(246);
|
| 401 |
|
| 402 |
+
var _ExecutionEnvironment = __webpack_require__(247);
|
| 403 |
|
| 404 |
+
var _DOMUtils = __webpack_require__(248);
|
| 405 |
|
| 406 |
+
var _DOMStateStorage = __webpack_require__(249);
|
| 407 |
|
| 408 |
+
var _createDOMHistory = __webpack_require__(251);
|
| 409 |
|
| 410 |
var _createDOMHistory2 = _interopRequireDefault(_createDOMHistory);
|
| 411 |
|
| 560 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 561 |
|
| 562 |
/***/ },
|
| 563 |
+
/* 246 */
|
| 564 |
/***/ function(module, exports) {
|
| 565 |
|
| 566 |
/**
|
| 596 |
};
|
| 597 |
|
| 598 |
/***/ },
|
| 599 |
+
/* 247 */
|
| 600 |
/***/ function(module, exports) {
|
| 601 |
|
| 602 |
'use strict';
|
| 606 |
exports.canUseDOM = canUseDOM;
|
| 607 |
|
| 608 |
/***/ },
|
| 609 |
+
/* 248 */
|
| 610 |
/***/ function(module, exports) {
|
| 611 |
|
| 612 |
'use strict';
|
| 686 |
}
|
| 687 |
|
| 688 |
/***/ },
|
| 689 |
+
/* 249 */
|
| 690 |
/***/ function(module, exports, __webpack_require__) {
|
| 691 |
|
| 692 |
/* WEBPACK VAR INJECTION */(function(process) {/*eslint-disable no-empty */
|
| 698 |
|
| 699 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 700 |
|
| 701 |
+
var _warning = __webpack_require__(250);
|
| 702 |
|
| 703 |
var _warning2 = _interopRequireDefault(_warning);
|
| 704 |
|
| 760 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 761 |
|
| 762 |
/***/ },
|
| 763 |
+
/* 250 */
|
| 764 |
/***/ function(module, exports, __webpack_require__) {
|
| 765 |
|
| 766 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 827 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 828 |
|
| 829 |
/***/ },
|
| 830 |
+
/* 251 */
|
| 831 |
/***/ function(module, exports, __webpack_require__) {
|
| 832 |
|
| 833 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 838 |
|
| 839 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 840 |
|
| 841 |
+
var _invariant = __webpack_require__(189);
|
| 842 |
|
| 843 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 844 |
|
| 845 |
+
var _ExecutionEnvironment = __webpack_require__(247);
|
| 846 |
|
| 847 |
+
var _DOMUtils = __webpack_require__(248);
|
| 848 |
|
| 849 |
+
var _createHistory = __webpack_require__(252);
|
| 850 |
|
| 851 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 852 |
|
| 873 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 874 |
|
| 875 |
/***/ },
|
| 876 |
+
/* 252 */
|
| 877 |
/***/ function(module, exports, __webpack_require__) {
|
| 878 |
|
| 879 |
'use strict';
|
| 884 |
|
| 885 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 886 |
|
| 887 |
+
var _deepEqual = __webpack_require__(253);
|
| 888 |
|
| 889 |
var _deepEqual2 = _interopRequireDefault(_deepEqual);
|
| 890 |
|
| 891 |
+
var _AsyncUtils = __webpack_require__(256);
|
| 892 |
|
| 893 |
+
var _Actions = __webpack_require__(246);
|
| 894 |
|
| 895 |
+
var _createLocation2 = __webpack_require__(257);
|
| 896 |
|
| 897 |
var _createLocation3 = _interopRequireDefault(_createLocation2);
|
| 898 |
|
| 899 |
+
var _runTransitionHook = __webpack_require__(260);
|
| 900 |
|
| 901 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 902 |
|
| 903 |
+
var _deprecate = __webpack_require__(261);
|
| 904 |
|
| 905 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 906 |
|
| 1148 |
module.exports = exports['default'];
|
| 1149 |
|
| 1150 |
/***/ },
|
| 1151 |
+
/* 253 */
|
| 1152 |
/***/ function(module, exports, __webpack_require__) {
|
| 1153 |
|
| 1154 |
var pSlice = Array.prototype.slice;
|
| 1155 |
+
var objectKeys = __webpack_require__(254);
|
| 1156 |
+
var isArguments = __webpack_require__(255);
|
| 1157 |
|
| 1158 |
var deepEqual = module.exports = function (actual, expected, opts) {
|
| 1159 |
if (!opts) opts = {};
|
| 1248 |
|
| 1249 |
|
| 1250 |
/***/ },
|
| 1251 |
+
/* 254 */
|
| 1252 |
/***/ function(module, exports) {
|
| 1253 |
|
| 1254 |
exports = module.exports = typeof Object.keys === 'function'
|
| 1263 |
|
| 1264 |
|
| 1265 |
/***/ },
|
| 1266 |
+
/* 255 */
|
| 1267 |
/***/ function(module, exports) {
|
| 1268 |
|
| 1269 |
var supportsArgumentsClass = (function(){
|
| 1289 |
|
| 1290 |
|
| 1291 |
/***/ },
|
| 1292 |
+
/* 256 */
|
| 1293 |
/***/ function(module, exports) {
|
| 1294 |
|
| 1295 |
"use strict";
|
| 1320 |
}
|
| 1321 |
|
| 1322 |
/***/ },
|
| 1323 |
+
/* 257 */
|
| 1324 |
/***/ function(module, exports, __webpack_require__) {
|
| 1325 |
|
| 1326 |
'use strict';
|
| 1329 |
|
| 1330 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1331 |
|
| 1332 |
+
var _Actions = __webpack_require__(246);
|
| 1333 |
|
| 1334 |
+
var _parsePath = __webpack_require__(258);
|
| 1335 |
|
| 1336 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 1337 |
|
| 1361 |
module.exports = exports['default'];
|
| 1362 |
|
| 1363 |
/***/ },
|
| 1364 |
+
/* 258 */
|
| 1365 |
/***/ function(module, exports, __webpack_require__) {
|
| 1366 |
|
| 1367 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 1370 |
|
| 1371 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1372 |
|
| 1373 |
+
var _warning = __webpack_require__(250);
|
| 1374 |
|
| 1375 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1376 |
|
| 1377 |
+
var _extractPath = __webpack_require__(259);
|
| 1378 |
|
| 1379 |
var _extractPath2 = _interopRequireDefault(_extractPath);
|
| 1380 |
|
| 1411 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1412 |
|
| 1413 |
/***/ },
|
| 1414 |
+
/* 259 */
|
| 1415 |
/***/ function(module, exports) {
|
| 1416 |
|
| 1417 |
"use strict";
|
| 1429 |
module.exports = exports["default"];
|
| 1430 |
|
| 1431 |
/***/ },
|
| 1432 |
+
/* 260 */
|
| 1433 |
/***/ function(module, exports, __webpack_require__) {
|
| 1434 |
|
| 1435 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 1438 |
|
| 1439 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1440 |
|
| 1441 |
+
var _warning = __webpack_require__(250);
|
| 1442 |
|
| 1443 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1444 |
|
| 1459 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1460 |
|
| 1461 |
/***/ },
|
| 1462 |
+
/* 261 */
|
| 1463 |
/***/ function(module, exports, __webpack_require__) {
|
| 1464 |
|
| 1465 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 1468 |
|
| 1469 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1470 |
|
| 1471 |
+
var _warning = __webpack_require__(250);
|
| 1472 |
|
| 1473 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1474 |
|
| 1484 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1485 |
|
| 1486 |
/***/ },
|
| 1487 |
+
/* 262 */
|
| 1488 |
/***/ function(module, exports, __webpack_require__) {
|
| 1489 |
|
| 1490 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 1495 |
|
| 1496 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1497 |
|
| 1498 |
+
var _warning = __webpack_require__(250);
|
| 1499 |
|
| 1500 |
var _warning2 = _interopRequireDefault(_warning);
|
| 1501 |
|
| 1502 |
+
var _invariant = __webpack_require__(189);
|
| 1503 |
|
| 1504 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 1505 |
|
| 1506 |
+
var _Actions = __webpack_require__(246);
|
| 1507 |
|
| 1508 |
+
var _ExecutionEnvironment = __webpack_require__(247);
|
| 1509 |
|
| 1510 |
+
var _DOMUtils = __webpack_require__(248);
|
| 1511 |
|
| 1512 |
+
var _DOMStateStorage = __webpack_require__(249);
|
| 1513 |
|
| 1514 |
+
var _createDOMHistory = __webpack_require__(251);
|
| 1515 |
|
| 1516 |
var _createDOMHistory2 = _interopRequireDefault(_createDOMHistory);
|
| 1517 |
|
| 1715 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1716 |
|
| 1717 |
/***/ },
|
| 1718 |
+
/* 263 */
|
| 1719 |
/***/ function(module, exports, __webpack_require__) {
|
| 1720 |
|
| 1721 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 1726 |
|
| 1727 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 1728 |
|
| 1729 |
+
var _invariant = __webpack_require__(189);
|
| 1730 |
|
| 1731 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 1732 |
|
| 1733 |
+
var _Actions = __webpack_require__(246);
|
| 1734 |
|
| 1735 |
+
var _createHistory = __webpack_require__(252);
|
| 1736 |
|
| 1737 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 1738 |
|
| 1863 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 1864 |
|
| 1865 |
/***/ },
|
| 1866 |
+
/* 264 */
|
| 1867 |
/***/ function(module, exports, __webpack_require__) {
|
| 1868 |
|
| 1869 |
'use strict';
|
| 1876 |
|
| 1877 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 1878 |
|
| 1879 |
+
var _ExecutionEnvironment = __webpack_require__(247);
|
| 1880 |
|
| 1881 |
+
var _runTransitionHook = __webpack_require__(260);
|
| 1882 |
|
| 1883 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 1884 |
|
| 1885 |
+
var _extractPath = __webpack_require__(259);
|
| 1886 |
|
| 1887 |
var _extractPath2 = _interopRequireDefault(_extractPath);
|
| 1888 |
|
| 1889 |
+
var _parsePath = __webpack_require__(258);
|
| 1890 |
|
| 1891 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 1892 |
|
| 1997 |
module.exports = exports['default'];
|
| 1998 |
|
| 1999 |
/***/ },
|
| 2000 |
+
/* 265 */
|
| 2001 |
/***/ function(module, exports, __webpack_require__) {
|
| 2002 |
|
| 2003 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 2008 |
|
| 2009 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2010 |
|
| 2011 |
+
var _warning = __webpack_require__(250);
|
| 2012 |
|
| 2013 |
var _warning2 = _interopRequireDefault(_warning);
|
| 2014 |
|
| 2015 |
+
var _ExecutionEnvironment = __webpack_require__(247);
|
| 2016 |
|
| 2017 |
+
var _DOMUtils = __webpack_require__(248);
|
| 2018 |
|
| 2019 |
+
var _deprecate = __webpack_require__(261);
|
| 2020 |
|
| 2021 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2022 |
|
| 2114 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 2115 |
|
| 2116 |
/***/ },
|
| 2117 |
+
/* 266 */
|
| 2118 |
/***/ function(module, exports, __webpack_require__) {
|
| 2119 |
|
| 2120 |
'use strict';
|
| 2127 |
|
| 2128 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 2129 |
|
| 2130 |
+
var _qs = __webpack_require__(267);
|
| 2131 |
|
| 2132 |
var _qs2 = _interopRequireDefault(_qs);
|
| 2133 |
|
| 2134 |
+
var _runTransitionHook = __webpack_require__(260);
|
| 2135 |
|
| 2136 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 2137 |
|
| 2138 |
+
var _parsePath = __webpack_require__(258);
|
| 2139 |
|
| 2140 |
var _parsePath2 = _interopRequireDefault(_parsePath);
|
| 2141 |
|
| 2234 |
module.exports = exports['default'];
|
| 2235 |
|
| 2236 |
/***/ },
|
| 2237 |
+
/* 267 */
|
| 2238 |
/***/ function(module, exports, __webpack_require__) {
|
| 2239 |
|
| 2240 |
// Load modules
|
| 2241 |
|
| 2242 |
+
var Stringify = __webpack_require__(268);
|
| 2243 |
+
var Parse = __webpack_require__(270);
|
| 2244 |
|
| 2245 |
|
| 2246 |
// Declare internals
|
| 2255 |
|
| 2256 |
|
| 2257 |
/***/ },
|
| 2258 |
+
/* 268 */
|
| 2259 |
/***/ function(module, exports, __webpack_require__) {
|
| 2260 |
|
| 2261 |
// Load modules
|
| 2262 |
|
| 2263 |
+
var Utils = __webpack_require__(269);
|
| 2264 |
|
| 2265 |
|
| 2266 |
// Declare internals
|
| 2382 |
|
| 2383 |
|
| 2384 |
/***/ },
|
| 2385 |
+
/* 269 */
|
| 2386 |
/***/ function(module, exports) {
|
| 2387 |
|
| 2388 |
// Load modules
|
| 2578 |
|
| 2579 |
|
| 2580 |
/***/ },
|
| 2581 |
+
/* 270 */
|
| 2582 |
/***/ function(module, exports, __webpack_require__) {
|
| 2583 |
|
| 2584 |
// Load modules
|
| 2585 |
|
| 2586 |
+
var Utils = __webpack_require__(269);
|
| 2587 |
|
| 2588 |
|
| 2589 |
// Declare internals
|
| 2770 |
|
| 2771 |
|
| 2772 |
/***/ },
|
| 2773 |
+
/* 271 */
|
| 2774 |
/***/ function(module, exports, __webpack_require__) {
|
| 2775 |
|
| 2776 |
'use strict';
|
| 2779 |
|
| 2780 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2781 |
|
| 2782 |
+
var _deprecate = __webpack_require__(261);
|
| 2783 |
|
| 2784 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2785 |
|
| 2786 |
+
var _useBeforeUnload = __webpack_require__(265);
|
| 2787 |
|
| 2788 |
var _useBeforeUnload2 = _interopRequireDefault(_useBeforeUnload);
|
| 2789 |
|
| 2791 |
module.exports = exports['default'];
|
| 2792 |
|
| 2793 |
/***/ },
|
| 2794 |
+
/* 272 */
|
| 2795 |
/***/ function(module, exports, __webpack_require__) {
|
| 2796 |
|
| 2797 |
'use strict';
|
| 2800 |
|
| 2801 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 2802 |
|
| 2803 |
+
var _deprecate = __webpack_require__(261);
|
| 2804 |
|
| 2805 |
var _deprecate2 = _interopRequireDefault(_deprecate);
|
| 2806 |
|
| 2807 |
+
var _useQueries = __webpack_require__(266);
|
| 2808 |
|
| 2809 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 2810 |
|
| 2812 |
module.exports = exports['default'];
|
| 2813 |
|
| 2814 |
/***/ },
|
| 2815 |
+
/* 273 */
|
| 2816 |
/***/ function(module, exports, __webpack_require__) {
|
| 2817 |
|
| 2818 |
'use strict';
|
| 2825 |
|
| 2826 |
var _reactRouter = __webpack_require__(181);
|
| 2827 |
|
| 2828 |
+
var _jquery = __webpack_require__(274);
|
| 2829 |
|
| 2830 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 2831 |
|
| 2832 |
+
var _mailpoet = __webpack_require__(275);
|
| 2833 |
|
| 2834 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 2835 |
|
| 2836 |
+
var _classnames = __webpack_require__(276);
|
| 2837 |
|
| 2838 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 2839 |
|
| 2840 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 2841 |
|
| 2842 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 2843 |
|
| 2844 |
+
var _formFieldsSelectionJsx = __webpack_require__(286);
|
| 2845 |
|
| 2846 |
var _formFieldsSelectionJsx2 = _interopRequireDefault(_formFieldsSelectionJsx);
|
| 2847 |
|
| 3186 |
module.exports = SubscriberList;
|
| 3187 |
|
| 3188 |
/***/ },
|
| 3189 |
+
/* 274 */
|
| 3190 |
/***/ function(module, exports) {
|
| 3191 |
|
| 3192 |
module.exports = jQuery;
|
| 3193 |
|
| 3194 |
/***/ },
|
| 3195 |
+
/* 275 */
|
| 3196 |
/***/ function(module, exports, __webpack_require__) {
|
| 3197 |
|
| 3198 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
| 3207 |
|
| 3208 |
|
| 3209 |
/***/ },
|
| 3210 |
+
/* 276 */
|
| 3211 |
/***/ function(module, exports, __webpack_require__) {
|
| 3212 |
|
| 3213 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
|
| 3261 |
|
| 3262 |
|
| 3263 |
/***/ },
|
| 3264 |
+
/* 277 */
|
| 3265 |
/***/ function(module, exports, __webpack_require__) {
|
| 3266 |
|
| 3267 |
'use strict';
|
| 3270 |
|
| 3271 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 3272 |
|
| 3273 |
+
var _mailpoet = __webpack_require__(275);
|
| 3274 |
|
| 3275 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 3276 |
|
| 3277 |
+
var _jquery = __webpack_require__(274);
|
| 3278 |
|
| 3279 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 3280 |
|
| 3282 |
|
| 3283 |
var _react2 = _interopRequireDefault(_react);
|
| 3284 |
|
| 3285 |
+
var _underscore = __webpack_require__(278);
|
| 3286 |
|
| 3287 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 3288 |
|
| 3289 |
var _reactRouter = __webpack_require__(181);
|
| 3290 |
|
| 3291 |
+
var _classnames = __webpack_require__(276);
|
| 3292 |
|
| 3293 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 3294 |
|
| 3295 |
+
var _listingBulk_actionsJsx = __webpack_require__(280);
|
| 3296 |
|
| 3297 |
var _listingBulk_actionsJsx2 = _interopRequireDefault(_listingBulk_actionsJsx);
|
| 3298 |
|
| 3299 |
+
var _listingHeaderJsx = __webpack_require__(281);
|
| 3300 |
|
| 3301 |
var _listingHeaderJsx2 = _interopRequireDefault(_listingHeaderJsx);
|
| 3302 |
|
| 3303 |
+
var _listingPagesJsx = __webpack_require__(282);
|
| 3304 |
|
| 3305 |
var _listingPagesJsx2 = _interopRequireDefault(_listingPagesJsx);
|
| 3306 |
|
| 3307 |
+
var _listingSearchJsx = __webpack_require__(283);
|
| 3308 |
|
| 3309 |
var _listingSearchJsx2 = _interopRequireDefault(_listingSearchJsx);
|
| 3310 |
|
| 3311 |
+
var _listingGroupsJsx = __webpack_require__(284);
|
| 3312 |
|
| 3313 |
var _listingGroupsJsx2 = _interopRequireDefault(_listingGroupsJsx);
|
| 3314 |
|
| 3315 |
+
var _listingFiltersJsx = __webpack_require__(285);
|
| 3316 |
|
| 3317 |
var _listingFiltersJsx2 = _interopRequireDefault(_listingFiltersJsx);
|
| 3318 |
|
| 4182 |
module.exports = Listing;
|
| 4183 |
|
| 4184 |
/***/ },
|
| 4185 |
+
/* 278 */
|
| 4186 |
/***/ function(module, exports, __webpack_require__) {
|
| 4187 |
|
| 4188 |
+
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["_"] = __webpack_require__(279);
|
| 4189 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 4190 |
|
| 4191 |
/***/ },
|
| 4192 |
+
/* 279 */
|
| 4193 |
/***/ function(module, exports, __webpack_require__) {
|
| 4194 |
|
| 4195 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Underscore.js 1.8.3
|
| 5743 |
|
| 5744 |
|
| 5745 |
/***/ },
|
| 5746 |
+
/* 280 */
|
| 5747 |
/***/ function(module, exports, __webpack_require__) {
|
| 5748 |
|
| 5749 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 5750 |
|
| 5751 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, MailPoet) {
|
| 5752 |
var ListingBulkActions = React.createClass({
|
| 5753 |
displayName: 'ListingBulkActions',
|
| 5754 |
|
| 5871 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 5872 |
|
| 5873 |
/***/ },
|
| 5874 |
+
/* 281 */
|
| 5875 |
/***/ function(module, exports, __webpack_require__) {
|
| 5876 |
|
| 5877 |
'use strict';
|
| 5878 |
|
| 5879 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 5880 |
|
| 5881 |
+
var _mailpoet = __webpack_require__(275);
|
| 5882 |
|
| 5883 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 5884 |
|
| 5886 |
|
| 5887 |
var _react2 = _interopRequireDefault(_react);
|
| 5888 |
|
| 5889 |
+
var _classnames = __webpack_require__(276);
|
| 5890 |
|
| 5891 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 5892 |
|
| 5979 |
module.exports = ListingHeader;
|
| 5980 |
|
| 5981 |
/***/ },
|
| 5982 |
+
/* 282 */
|
| 5983 |
/***/ function(module, exports, __webpack_require__) {
|
| 5984 |
|
| 5985 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 5986 |
|
| 5987 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(276), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, classNames, MailPoet) {
|
| 5988 |
|
| 5989 |
var ListingPages = React.createClass({
|
| 5990 |
displayName: 'ListingPages',
|
| 6211 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6212 |
|
| 6213 |
/***/ },
|
| 6214 |
+
/* 283 */
|
| 6215 |
/***/ function(module, exports, __webpack_require__) {
|
| 6216 |
|
| 6217 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6218 |
|
| 6219 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(275), __webpack_require__(2)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, React) {
|
| 6220 |
|
| 6221 |
var ListingSearch = React.createClass({
|
| 6222 |
displayName: 'ListingSearch',
|
| 6263 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6264 |
|
| 6265 |
/***/ },
|
| 6266 |
+
/* 284 */
|
| 6267 |
/***/ function(module, exports, __webpack_require__) {
|
| 6268 |
|
| 6269 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6270 |
|
| 6271 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(276)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, classNames) {
|
| 6272 |
|
| 6273 |
var ListingGroups = React.createClass({
|
| 6274 |
displayName: 'ListingGroups',
|
| 6319 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6320 |
|
| 6321 |
/***/ },
|
| 6322 |
+
/* 285 */
|
| 6323 |
/***/ function(module, exports, __webpack_require__) {
|
| 6324 |
|
| 6325 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6326 |
|
| 6327 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(274), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, jQuery, MailPoet) {
|
| 6328 |
var ListingFilters = React.createClass({
|
| 6329 |
displayName: 'ListingFilters',
|
| 6330 |
|
| 6412 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6413 |
|
| 6414 |
/***/ },
|
| 6415 |
+
/* 286 */
|
| 6416 |
/***/ function(module, exports, __webpack_require__) {
|
| 6417 |
|
| 6418 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 6419 |
|
| 6420 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 6421 |
|
| 6422 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(34), __webpack_require__(274), __webpack_require__(287)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, ReactDOM, jQuery) {
|
| 6423 |
var Selection = React.createClass({
|
| 6424 |
displayName: 'Selection',
|
| 6425 |
|
| 6603 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6604 |
|
| 6605 |
/***/ },
|
| 6606 |
+
/* 287 */
|
| 6607 |
/***/ function(module, exports, __webpack_require__) {
|
| 6608 |
|
| 6609 |
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;var require;var require;/*!
|
| 6616 |
(function (factory) {
|
| 6617 |
if (true) {
|
| 6618 |
// AMD. Register as an anonymous module.
|
| 6619 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(274)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 6620 |
} else if (typeof exports === 'object') {
|
| 6621 |
// Node/CommonJS
|
| 6622 |
factory(require('jquery'));
|
| 12334 |
|
| 12335 |
|
| 12336 |
/***/ },
|
| 12337 |
+
/* 288 */
|
| 12338 |
/***/ function(module, exports, __webpack_require__) {
|
| 12339 |
|
| 12340 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12341 |
|
| 12342 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(275), __webpack_require__(289), __webpack_require__(415)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Form, ReactStringReplace) {
|
| 12343 |
var fields = [{
|
| 12344 |
name: 'email',
|
| 12345 |
label: MailPoet.I18n.t('email'),
|
| 12528 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12529 |
|
| 12530 |
/***/ },
|
| 12531 |
+
/* 289 */
|
| 12532 |
/***/ function(module, exports, __webpack_require__) {
|
| 12533 |
|
| 12534 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12535 |
|
| 12536 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(275), __webpack_require__(276), __webpack_require__(181), __webpack_require__(290)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, MailPoet, classNames, Router, FormField) {
|
| 12537 |
|
| 12538 |
var Form = React.createClass({
|
| 12539 |
displayName: 'Form',
|
| 12753 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12754 |
|
| 12755 |
/***/ },
|
| 12756 |
+
/* 290 */
|
| 12757 |
/***/ function(module, exports, __webpack_require__) {
|
| 12758 |
|
| 12759 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 12760 |
|
| 12761 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(291), __webpack_require__(292), __webpack_require__(293), __webpack_require__(294), __webpack_require__(295), __webpack_require__(286), __webpack_require__(296)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, FormFieldText, FormFieldTextarea, FormFieldSelect, FormFieldRadio, FormFieldCheckbox, FormFieldSelection, FormFieldDate) {
|
| 12762 |
var FormField = React.createClass({
|
| 12763 |
displayName: 'FormField',
|
| 12764 |
|
| 12883 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12884 |
|
| 12885 |
/***/ },
|
| 12886 |
+
/* 291 */
|
| 12887 |
/***/ function(module, exports, __webpack_require__) {
|
| 12888 |
|
| 12889 |
'use strict';
|
| 12922 |
module.exports = FormFieldText;
|
| 12923 |
|
| 12924 |
/***/ },
|
| 12925 |
+
/* 292 */
|
| 12926 |
/***/ function(module, exports, __webpack_require__) {
|
| 12927 |
|
| 12928 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;"use strict";
|
| 12951 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 12952 |
|
| 12953 |
/***/ },
|
| 12954 |
+
/* 293 */
|
| 12955 |
/***/ function(module, exports, __webpack_require__) {
|
| 12956 |
|
| 12957 |
'use strict';
|
| 12964 |
|
| 12965 |
var _react2 = _interopRequireDefault(_react);
|
| 12966 |
|
| 12967 |
+
var _underscore = __webpack_require__(278);
|
| 12968 |
|
| 12969 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 12970 |
|
| 13043 |
module.exports = FormFieldSelect;
|
| 13044 |
|
| 13045 |
/***/ },
|
| 13046 |
+
/* 294 */
|
| 13047 |
/***/ function(module, exports, __webpack_require__) {
|
| 13048 |
|
| 13049 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 13090 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13091 |
|
| 13092 |
/***/ },
|
| 13093 |
+
/* 295 */
|
| 13094 |
/***/ function(module, exports, __webpack_require__) {
|
| 13095 |
|
| 13096 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 13145 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13146 |
|
| 13147 |
/***/ },
|
| 13148 |
+
/* 296 */
|
| 13149 |
/***/ function(module, exports, __webpack_require__) {
|
| 13150 |
|
| 13151 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 13160 |
|
| 13161 |
function _inherits(subClass, superClass) { if (typeof superClass !== 'function' && superClass !== null) { throw new TypeError('Super expression must either be null or a function, not ' + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
|
| 13162 |
|
| 13163 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(297)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Moment) {
|
| 13164 |
var FormFieldDateYear = (function (_React$Component) {
|
| 13165 |
_inherits(FormFieldDateYear, _React$Component);
|
| 13166 |
|
| 13477 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 13478 |
|
| 13479 |
/***/ },
|
| 13480 |
+
/* 297 */
|
| 13481 |
/***/ function(module, exports, __webpack_require__) {
|
| 13482 |
|
| 13483 |
/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
|
| 13484 |
+
//! version : 2.18.1
|
| 13485 |
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
| 13486 |
//! license : MIT
|
| 13487 |
//! momentjs.com
|
| 13523 |
return true;
|
| 13524 |
}
|
| 13525 |
|
| 13526 |
+
function isUndefined(input) {
|
| 13527 |
+
return input === void 0;
|
| 13528 |
+
}
|
| 13529 |
+
|
| 13530 |
function isNumber(input) {
|
| 13531 |
return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';
|
| 13532 |
}
|
| 13583 |
userInvalidated : false,
|
| 13584 |
iso : false,
|
| 13585 |
parsedDateParts : [],
|
| 13586 |
+
meridiem : null,
|
| 13587 |
+
rfc2822 : false,
|
| 13588 |
+
weekdayMismatch : false
|
| 13589 |
};
|
| 13590 |
}
|
| 13591 |
|
| 13661 |
return m;
|
| 13662 |
}
|
| 13663 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13664 |
// Plugins that add properties should also add the key here (null value),
|
| 13665 |
// so we can properly clone ourselves.
|
| 13666 |
var momentProperties = hooks.momentProperties = [];
|
| 13700 |
}
|
| 13701 |
|
| 13702 |
if (momentProperties.length > 0) {
|
| 13703 |
+
for (i = 0; i < momentProperties.length; i++) {
|
| 13704 |
prop = momentProperties[i];
|
| 13705 |
val = from[prop];
|
| 13706 |
if (!isUndefined(val)) {
|
| 13837 |
}
|
| 13838 |
this._config = config;
|
| 13839 |
// Lenient ordinal parsing accepts just a number in addition to
|
| 13840 |
+
// number + (possibly) stuff coming from _dayOfMonthOrdinalParse.
|
| 13841 |
+
// TODO: Remove "ordinalParse" fallback in next major release.
|
| 13842 |
+
this._dayOfMonthOrdinalParseLenient = new RegExp(
|
| 13843 |
+
(this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) +
|
| 13844 |
+
'|' + (/\d{1,2}/).source);
|
| 13845 |
}
|
| 13846 |
|
| 13847 |
function mergeConfigs(parentConfig, childConfig) {
|
| 13939 |
}
|
| 13940 |
|
| 13941 |
var defaultOrdinal = '%d';
|
| 13942 |
+
var defaultDayOfMonthOrdinalParse = /\d{1,2}/;
|
| 13943 |
|
| 13944 |
function ordinal (number) {
|
| 13945 |
return this._ordinal.replace('%d', number);
|
| 13949 |
future : 'in %s',
|
| 13950 |
past : '%s ago',
|
| 13951 |
s : 'a few seconds',
|
| 13952 |
+
ss : '%d seconds',
|
| 13953 |
m : 'a minute',
|
| 13954 |
mm : '%d minutes',
|
| 13955 |
h : 'an hour',
|
| 14132 |
return function (mom) {
|
| 14133 |
var output = '', i;
|
| 14134 |
for (i = 0; i < length; i++) {
|
| 14135 |
+
output += isFunction(array[i]) ? array[i].call(mom, format) : array[i];
|
| 14136 |
}
|
| 14137 |
return output;
|
| 14138 |
};
|
| 14335 |
var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
|
| 14336 |
function localeMonths (m, format) {
|
| 14337 |
if (!m) {
|
| 14338 |
+
return isArray(this._months) ? this._months :
|
| 14339 |
+
this._months['standalone'];
|
| 14340 |
}
|
| 14341 |
return isArray(this._months) ? this._months[m.month()] :
|
| 14342 |
this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];
|
| 14345 |
var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
|
| 14346 |
function localeMonthsShort (m, format) {
|
| 14347 |
if (!m) {
|
| 14348 |
+
return isArray(this._monthsShort) ? this._monthsShort :
|
| 14349 |
+
this._monthsShort['standalone'];
|
| 14350 |
}
|
| 14351 |
return isArray(this._monthsShort) ? this._monthsShort[m.month()] :
|
| 14352 |
this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];
|
| 14613 |
}
|
| 14614 |
|
| 14615 |
function createDate (y, m, d, h, M, s, ms) {
|
| 14616 |
+
// can't just apply() to create a date:
|
| 14617 |
+
// https://stackoverflow.com/q/181348
|
| 14618 |
var date = new Date(y, m, d, h, M, s, ms);
|
| 14619 |
|
| 14620 |
+
// the date constructor remaps years 0-99 to 1900-1999
|
| 14621 |
if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
|
| 14622 |
date.setFullYear(y);
|
| 14623 |
}
|
| 14627 |
function createUTCDate (y) {
|
| 14628 |
var date = new Date(Date.UTC.apply(null, arguments));
|
| 14629 |
|
| 14630 |
+
// the Date.UTC function remaps years 0-99 to 1900-1999
|
| 14631 |
if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
|
| 14632 |
date.setUTCFullYear(y);
|
| 14633 |
}
|
| 14644 |
return -fwdlw + fwd - 1;
|
| 14645 |
}
|
| 14646 |
|
| 14647 |
+
// https://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday
|
| 14648 |
function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
|
| 14649 |
var localWeekday = (7 + weekday - dow) % 7,
|
| 14650 |
weekOffset = firstWeekOffset(year, dow, doy),
|
| 14845 |
var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
|
| 14846 |
function localeWeekdays (m, format) {
|
| 14847 |
if (!m) {
|
| 14848 |
+
return isArray(this._weekdays) ? this._weekdays :
|
| 14849 |
+
this._weekdays['standalone'];
|
| 14850 |
}
|
| 14851 |
return isArray(this._weekdays) ? this._weekdays[m.day()] :
|
| 14852 |
this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
|
| 15166 |
addRegexToken('A', matchMeridiem);
|
| 15167 |
addRegexToken('H', match1to2);
|
| 15168 |
addRegexToken('h', match1to2);
|
| 15169 |
+
addRegexToken('k', match1to2);
|
| 15170 |
addRegexToken('HH', match1to2, match2);
|
| 15171 |
addRegexToken('hh', match1to2, match2);
|
| 15172 |
+
addRegexToken('kk', match1to2, match2);
|
| 15173 |
|
| 15174 |
addRegexToken('hmm', match3to4);
|
| 15175 |
addRegexToken('hmmss', match5to6);
|
| 15177 |
addRegexToken('Hmmss', match5to6);
|
| 15178 |
|
| 15179 |
addParseToken(['H', 'HH'], HOUR);
|
| 15180 |
+
addParseToken(['k', 'kk'], function (input, array, config) {
|
| 15181 |
+
var kInput = toInt(input);
|
| 15182 |
+
array[HOUR] = kInput === 24 ? 0 : kInput;
|
| 15183 |
+
});
|
| 15184 |
addParseToken(['a', 'A'], function (input, array, config) {
|
| 15185 |
config._isPm = config._locale.isPM(input);
|
| 15186 |
config._meridiem = input;
|
| 15251 |
longDateFormat: defaultLongDateFormat,
|
| 15252 |
invalidDate: defaultInvalidDate,
|
| 15253 |
ordinal: defaultOrdinal,
|
| 15254 |
+
dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse,
|
| 15255 |
relativeTime: defaultRelativeTime,
|
| 15256 |
|
| 15257 |
months: defaultLocaleMonths,
|
| 15309 |
module && module.exports) {
|
| 15310 |
try {
|
| 15311 |
oldLocale = globalLocale._abbr;
|
| 15312 |
+
__webpack_require__(299)("./" + name);
|
| 15313 |
// because defineLocale currently also sets the global locale, we
|
| 15314 |
// want to undo that for lazy loaded locales
|
| 15315 |
getSetGlobalLocale(oldLocale);
|
| 15562 |
}
|
| 15563 |
}
|
| 15564 |
|
| 15565 |
+
// RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3
|
| 15566 |
+
var basicRfcRegex = /^((?:Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d?\d\s(?:Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(?:\d\d)?\d\d\s)(\d\d:\d\d)(\:\d\d)?(\s(?:UT|GMT|[ECMP][SD]T|[A-IK-Za-ik-z]|[+-]\d{4}))$/;
|
| 15567 |
+
|
| 15568 |
+
// date and time from ref 2822 format
|
| 15569 |
+
function configFromRFC2822(config) {
|
| 15570 |
+
var string, match, dayFormat,
|
| 15571 |
+
dateFormat, timeFormat, tzFormat;
|
| 15572 |
+
var timezones = {
|
| 15573 |
+
' GMT': ' +0000',
|
| 15574 |
+
' EDT': ' -0400',
|
| 15575 |
+
' EST': ' -0500',
|
| 15576 |
+
' CDT': ' -0500',
|
| 15577 |
+
' CST': ' -0600',
|
| 15578 |
+
' MDT': ' -0600',
|
| 15579 |
+
' MST': ' -0700',
|
| 15580 |
+
' PDT': ' -0700',
|
| 15581 |
+
' PST': ' -0800'
|
| 15582 |
+
};
|
| 15583 |
+
var military = 'YXWVUTSRQPONZABCDEFGHIKLM';
|
| 15584 |
+
var timezone, timezoneIndex;
|
| 15585 |
+
|
| 15586 |
+
string = config._i
|
| 15587 |
+
.replace(/\([^\)]*\)|[\n\t]/g, ' ') // Remove comments and folding whitespace
|
| 15588 |
+
.replace(/(\s\s+)/g, ' ') // Replace multiple-spaces with a single space
|
| 15589 |
+
.replace(/^\s|\s$/g, ''); // Remove leading and trailing spaces
|
| 15590 |
+
match = basicRfcRegex.exec(string);
|
| 15591 |
+
|
| 15592 |
+
if (match) {
|
| 15593 |
+
dayFormat = match[1] ? 'ddd' + ((match[1].length === 5) ? ', ' : ' ') : '';
|
| 15594 |
+
dateFormat = 'D MMM ' + ((match[2].length > 10) ? 'YYYY ' : 'YY ');
|
| 15595 |
+
timeFormat = 'HH:mm' + (match[4] ? ':ss' : '');
|
| 15596 |
+
|
| 15597 |
+
// TODO: Replace the vanilla JS Date object with an indepentent day-of-week check.
|
| 15598 |
+
if (match[1]) { // day of week given
|
| 15599 |
+
var momentDate = new Date(match[2]);
|
| 15600 |
+
var momentDay = ['Sun','Mon','Tue','Wed','Thu','Fri','Sat'][momentDate.getDay()];
|
| 15601 |
+
|
| 15602 |
+
if (match[1].substr(0,3) !== momentDay) {
|
| 15603 |
+
getParsingFlags(config).weekdayMismatch = true;
|
| 15604 |
+
config._isValid = false;
|
| 15605 |
+
return;
|
| 15606 |
+
}
|
| 15607 |
+
}
|
| 15608 |
+
|
| 15609 |
+
switch (match[5].length) {
|
| 15610 |
+
case 2: // military
|
| 15611 |
+
if (timezoneIndex === 0) {
|
| 15612 |
+
timezone = ' +0000';
|
| 15613 |
+
} else {
|
| 15614 |
+
timezoneIndex = military.indexOf(match[5][1].toUpperCase()) - 12;
|
| 15615 |
+
timezone = ((timezoneIndex < 0) ? ' -' : ' +') +
|
| 15616 |
+
(('' + timezoneIndex).replace(/^-?/, '0')).match(/..$/)[0] + '00';
|
| 15617 |
+
}
|
| 15618 |
+
break;
|
| 15619 |
+
case 4: // Zone
|
| 15620 |
+
timezone = timezones[match[5]];
|
| 15621 |
+
break;
|
| 15622 |
+
default: // UT or +/-9999
|
| 15623 |
+
timezone = timezones[' GMT'];
|
| 15624 |
+
}
|
| 15625 |
+
match[5] = timezone;
|
| 15626 |
+
config._i = match.splice(1).join('');
|
| 15627 |
+
tzFormat = ' ZZ';
|
| 15628 |
+
config._f = dayFormat + dateFormat + timeFormat + tzFormat;
|
| 15629 |
+
configFromStringAndFormat(config);
|
| 15630 |
+
getParsingFlags(config).rfc2822 = true;
|
| 15631 |
+
} else {
|
| 15632 |
+
config._isValid = false;
|
| 15633 |
+
}
|
| 15634 |
+
}
|
| 15635 |
+
|
| 15636 |
// date from iso format or fallback
|
| 15637 |
function configFromString(config) {
|
| 15638 |
var matched = aspNetJsonRegex.exec(config._i);
|
| 15645 |
configFromISO(config);
|
| 15646 |
if (config._isValid === false) {
|
| 15647 |
delete config._isValid;
|
| 15648 |
+
} else {
|
| 15649 |
+
return;
|
| 15650 |
}
|
| 15651 |
+
|
| 15652 |
+
configFromRFC2822(config);
|
| 15653 |
+
if (config._isValid === false) {
|
| 15654 |
+
delete config._isValid;
|
| 15655 |
+
} else {
|
| 15656 |
+
return;
|
| 15657 |
+
}
|
| 15658 |
+
|
| 15659 |
+
// Final attempt, use Input Fallback
|
| 15660 |
+
hooks.createFromInputFallback(config);
|
| 15661 |
}
|
| 15662 |
|
| 15663 |
hooks.createFromInputFallback = deprecate(
|
| 15664 |
+
'value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), ' +
|
| 15665 |
+
'which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are ' +
|
| 15666 |
'discouraged and will be removed in an upcoming major release. Please refer to ' +
|
| 15667 |
'http://momentjs.com/guides/#/warnings/js-date/ for more info.',
|
| 15668 |
function (config) {
|
| 15709 |
}
|
| 15710 |
|
| 15711 |
//if the day of the year is set, figure out what it is
|
| 15712 |
+
if (config._dayOfYear != null) {
|
| 15713 |
yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
|
| 15714 |
|
| 15715 |
+
if (config._dayOfYear > daysInYear(yearToUse) || config._dayOfYear === 0) {
|
| 15716 |
getParsingFlags(config)._overflowDayOfYear = true;
|
| 15717 |
}
|
| 15718 |
|
| 15816 |
// constant that refers to the ISO standard
|
| 15817 |
hooks.ISO_8601 = function () {};
|
| 15818 |
|
| 15819 |
+
// constant that refers to the RFC 2822 form
|
| 15820 |
+
hooks.RFC_2822 = function () {};
|
| 15821 |
+
|
| 15822 |
// date from string and format string
|
| 15823 |
function configFromStringAndFormat(config) {
|
| 15824 |
// TODO: Move this to another part of the creation flow to prevent circular deps
|
| 15826 |
configFromISO(config);
|
| 15827 |
return;
|
| 15828 |
}
|
| 15829 |
+
if (config._f === hooks.RFC_2822) {
|
| 15830 |
+
configFromRFC2822(config);
|
| 15831 |
+
return;
|
| 15832 |
+
}
|
| 15833 |
config._a = [];
|
| 15834 |
getParsingFlags(config).empty = true;
|
| 15835 |
|
| 16021 |
|
| 16022 |
function configFromInput(config) {
|
| 16023 |
var input = config._i;
|
| 16024 |
+
if (isUndefined(input)) {
|
| 16025 |
config._d = new Date(hooks.now());
|
| 16026 |
} else if (isDate(input)) {
|
| 16027 |
config._d = new Date(input.valueOf());
|
| 16032 |
return parseInt(obj, 10);
|
| 16033 |
});
|
| 16034 |
configFromArray(config);
|
| 16035 |
+
} else if (isObject(input)) {
|
| 16036 |
configFromObject(config);
|
| 16037 |
} else if (isNumber(input)) {
|
| 16038 |
// from milliseconds
|
| 16133 |
return Date.now ? Date.now() : +(new Date());
|
| 16134 |
};
|
| 16135 |
|
| 16136 |
+
var ordering = ['year', 'quarter', 'month', 'week', 'day', 'hour', 'minute', 'second', 'millisecond'];
|
| 16137 |
+
|
| 16138 |
+
function isDurationValid(m) {
|
| 16139 |
+
for (var key in m) {
|
| 16140 |
+
if (!(ordering.indexOf(key) !== -1 && (m[key] == null || !isNaN(m[key])))) {
|
| 16141 |
+
return false;
|
| 16142 |
+
}
|
| 16143 |
+
}
|
| 16144 |
+
|
| 16145 |
+
var unitHasDecimal = false;
|
| 16146 |
+
for (var i = 0; i < ordering.length; ++i) {
|
| 16147 |
+
if (m[ordering[i]]) {
|
| 16148 |
+
if (unitHasDecimal) {
|
| 16149 |
+
return false; // only allow non-integers for smallest unit
|
| 16150 |
+
}
|
| 16151 |
+
if (parseFloat(m[ordering[i]]) !== toInt(m[ordering[i]])) {
|
| 16152 |
+
unitHasDecimal = true;
|
| 16153 |
+
}
|
| 16154 |
+
}
|
| 16155 |
+
}
|
| 16156 |
+
|
| 16157 |
+
return true;
|
| 16158 |
+
}
|
| 16159 |
+
|
| 16160 |
+
function isValid$1() {
|
| 16161 |
+
return this._isValid;
|
| 16162 |
+
}
|
| 16163 |
+
|
| 16164 |
+
function createInvalid$1() {
|
| 16165 |
+
return createDuration(NaN);
|
| 16166 |
+
}
|
| 16167 |
+
|
| 16168 |
function Duration (duration) {
|
| 16169 |
var normalizedInput = normalizeObjectUnits(duration),
|
| 16170 |
years = normalizedInput.year || 0,
|
| 16177 |
seconds = normalizedInput.second || 0,
|
| 16178 |
milliseconds = normalizedInput.millisecond || 0;
|
| 16179 |
|
| 16180 |
+
this._isValid = isDurationValid(normalizedInput);
|
| 16181 |
+
|
| 16182 |
// representation for dateAddRemove
|
| 16183 |
this._milliseconds = +milliseconds +
|
| 16184 |
seconds * 1e3 + // 1000
|
| 16302 |
// a second time. In case it wants us to change the offset again
|
| 16303 |
// _changeInProgress == true case, then we have to adjust, because
|
| 16304 |
// there is no such time in the given timezone.
|
| 16305 |
+
function getSetOffset (input, keepLocalTime, keepMinutes) {
|
| 16306 |
var offset = this._offset || 0,
|
| 16307 |
localAdjust;
|
| 16308 |
if (!this.isValid()) {
|
| 16314 |
if (input === null) {
|
| 16315 |
return this;
|
| 16316 |
}
|
| 16317 |
+
} else if (Math.abs(input) < 16 && !keepMinutes) {
|
| 16318 |
input = input * 60;
|
| 16319 |
}
|
| 16320 |
if (!this._isUTC && keepLocalTime) {
|
| 16372 |
|
| 16373 |
function setOffsetToParsedOffset () {
|
| 16374 |
if (this._tzm != null) {
|
| 16375 |
+
this.utcOffset(this._tzm, false, true);
|
| 16376 |
} else if (typeof this._i === 'string') {
|
| 16377 |
var tZone = offsetFromString(matchOffset, this._i);
|
| 16378 |
if (tZone != null) {
|
| 16504 |
}
|
| 16505 |
|
| 16506 |
createDuration.fn = Duration.prototype;
|
| 16507 |
+
createDuration.invalid = createInvalid$1;
|
| 16508 |
|
| 16509 |
function parseIso (inp, sign) {
|
| 16510 |
// We'd normally use ~~inp for this, but unfortunately it also
|
| 16741 |
return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
|
| 16742 |
}
|
| 16743 |
|
| 16744 |
+
function toISOString() {
|
| 16745 |
+
if (!this.isValid()) {
|
| 16746 |
+
return null;
|
| 16747 |
+
}
|
| 16748 |
var m = this.clone().utc();
|
| 16749 |
+
if (m.year() < 0 || m.year() > 9999) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16750 |
return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 16751 |
}
|
| 16752 |
+
if (isFunction(Date.prototype.toISOString)) {
|
| 16753 |
+
// native implementation is ~50x faster, use it when we can
|
| 16754 |
+
return this.toDate().toISOString();
|
| 16755 |
+
}
|
| 16756 |
+
return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 16757 |
}
|
| 16758 |
|
| 16759 |
/**
|
| 16773 |
zone = 'Z';
|
| 16774 |
}
|
| 16775 |
var prefix = '[' + func + '("]';
|
| 16776 |
+
var year = (0 <= this.year() && this.year() <= 9999) ? 'YYYY' : 'YYYYYY';
|
| 16777 |
var datetime = '-MM-DD[T]HH:mm:ss.SSS';
|
| 16778 |
var suffix = zone + '[")]';
|
| 16779 |
|
| 16941 |
return this.isValid() ? this.toISOString() : null;
|
| 16942 |
}
|
| 16943 |
|
| 16944 |
+
function isValid$2 () {
|
| 16945 |
return isValid(this);
|
| 16946 |
}
|
| 16947 |
|
| 17101 |
addRegexToken('D', match1to2);
|
| 17102 |
addRegexToken('DD', match1to2, match2);
|
| 17103 |
addRegexToken('Do', function (isStrict, locale) {
|
| 17104 |
+
// TODO: Remove "ordinalParse" fallback in next major release.
|
| 17105 |
+
return isStrict ?
|
| 17106 |
+
(locale._dayOfMonthOrdinalParse || locale._ordinalParse) :
|
| 17107 |
+
locale._dayOfMonthOrdinalParseLenient;
|
| 17108 |
});
|
| 17109 |
|
| 17110 |
addParseToken(['D', 'DD'], DATE);
|
| 17284 |
proto.isSame = isSame;
|
| 17285 |
proto.isSameOrAfter = isSameOrAfter;
|
| 17286 |
proto.isSameOrBefore = isSameOrBefore;
|
| 17287 |
+
proto.isValid = isValid$2;
|
| 17288 |
proto.lang = lang;
|
| 17289 |
proto.locale = locale;
|
| 17290 |
proto.localeData = localeData;
|
| 17509 |
}
|
| 17510 |
|
| 17511 |
getSetGlobalLocale('en', {
|
| 17512 |
+
dayOfMonthOrdinalParse: /\d{1,2}(th|st|nd|rd)/,
|
| 17513 |
ordinal : function (number) {
|
| 17514 |
var b = number % 10,
|
| 17515 |
output = (toInt(number % 100 / 10) === 1) ? 'th' :
|
| 17630 |
}
|
| 17631 |
|
| 17632 |
function as (units) {
|
| 17633 |
+
if (!this.isValid()) {
|
| 17634 |
+
return NaN;
|
| 17635 |
+
}
|
| 17636 |
var days;
|
| 17637 |
var months;
|
| 17638 |
var milliseconds = this._milliseconds;
|
| 17661 |
|
| 17662 |
// TODO: Use this.as('ms')?
|
| 17663 |
function valueOf$1 () {
|
| 17664 |
+
if (!this.isValid()) {
|
| 17665 |
+
return NaN;
|
| 17666 |
+
}
|
| 17667 |
return (
|
| 17668 |
this._milliseconds +
|
| 17669 |
this._days * 864e5 +
|
| 17689 |
|
| 17690 |
function get$2 (units) {
|
| 17691 |
units = normalizeUnits(units);
|
| 17692 |
+
return this.isValid() ? this[units + 's']() : NaN;
|
| 17693 |
}
|
| 17694 |
|
| 17695 |
function makeGetter(name) {
|
| 17696 |
return function () {
|
| 17697 |
+
return this.isValid() ? this._data[name] : NaN;
|
| 17698 |
};
|
| 17699 |
}
|
| 17700 |
|
| 17712 |
|
| 17713 |
var round = Math.round;
|
| 17714 |
var thresholds = {
|
| 17715 |
+
ss: 44, // a few seconds to seconds
|
| 17716 |
+
s : 45, // seconds to minute
|
| 17717 |
+
m : 45, // minutes to hour
|
| 17718 |
+
h : 22, // hours to day
|
| 17719 |
+
d : 26, // days to month
|
| 17720 |
+
M : 11 // months to year
|
| 17721 |
};
|
| 17722 |
|
| 17723 |
// helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize
|
| 17734 |
var months = round(duration.as('M'));
|
| 17735 |
var years = round(duration.as('y'));
|
| 17736 |
|
| 17737 |
+
var a = seconds <= thresholds.ss && ['s', seconds] ||
|
| 17738 |
+
seconds < thresholds.s && ['ss', seconds] ||
|
| 17739 |
+
minutes <= 1 && ['m'] ||
|
| 17740 |
+
minutes < thresholds.m && ['mm', minutes] ||
|
| 17741 |
+
hours <= 1 && ['h'] ||
|
| 17742 |
+
hours < thresholds.h && ['hh', hours] ||
|
| 17743 |
+
days <= 1 && ['d'] ||
|
| 17744 |
+
days < thresholds.d && ['dd', days] ||
|
| 17745 |
+
months <= 1 && ['M'] ||
|
| 17746 |
+
months < thresholds.M && ['MM', months] ||
|
| 17747 |
+
years <= 1 && ['y'] || ['yy', years];
|
| 17748 |
|
| 17749 |
a[2] = withoutSuffix;
|
| 17750 |
a[3] = +posNegDuration > 0;
|
| 17773 |
return thresholds[threshold];
|
| 17774 |
}
|
| 17775 |
thresholds[threshold] = limit;
|
| 17776 |
+
if (threshold === 's') {
|
| 17777 |
+
thresholds.ss = limit - 1;
|
| 17778 |
+
}
|
| 17779 |
return true;
|
| 17780 |
}
|
| 17781 |
|
| 17782 |
function humanize (withSuffix) {
|
| 17783 |
+
if (!this.isValid()) {
|
| 17784 |
+
return this.localeData().invalidDate();
|
| 17785 |
+
}
|
| 17786 |
+
|
| 17787 |
var locale = this.localeData();
|
| 17788 |
var output = relativeTime$1(this, !withSuffix, locale);
|
| 17789 |
|
| 17804 |
// This is because there is no context-free conversion between hours and days
|
| 17805 |
// (think of clock changes)
|
| 17806 |
// and also not between days and months (28-31 days per month)
|
| 17807 |
+
if (!this.isValid()) {
|
| 17808 |
+
return this.localeData().invalidDate();
|
| 17809 |
+
}
|
| 17810 |
+
|
| 17811 |
var seconds = abs$1(this._milliseconds) / 1000;
|
| 17812 |
var days = abs$1(this._days);
|
| 17813 |
var months = abs$1(this._months);
|
| 17852 |
|
| 17853 |
var proto$2 = Duration.prototype;
|
| 17854 |
|
| 17855 |
+
proto$2.isValid = isValid$1;
|
| 17856 |
proto$2.abs = abs;
|
| 17857 |
proto$2.add = add$1;
|
| 17858 |
proto$2.subtract = subtract$1;
|
| 17908 |
// Side effect imports
|
| 17909 |
|
| 17910 |
|
| 17911 |
+
hooks.version = '2.18.1';
|
| 17912 |
|
| 17913 |
setHookCallback(createLocal);
|
| 17914 |
|
| 17944 |
|
| 17945 |
})));
|
| 17946 |
|
| 17947 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(298)(module)))
|
| 17948 |
|
| 17949 |
/***/ },
|
| 17950 |
+
/* 298 */,
|
| 17951 |
+
/* 299 */
|
| 17952 |
/***/ function(module, exports, __webpack_require__) {
|
| 17953 |
|
| 17954 |
var map = {
|
| 17955 |
+
"./af": 300,
|
| 17956 |
+
"./af.js": 300,
|
| 17957 |
+
"./ar": 301,
|
| 17958 |
+
"./ar-dz": 302,
|
| 17959 |
+
"./ar-dz.js": 302,
|
| 17960 |
+
"./ar-kw": 303,
|
| 17961 |
+
"./ar-kw.js": 303,
|
| 17962 |
+
"./ar-ly": 304,
|
| 17963 |
+
"./ar-ly.js": 304,
|
| 17964 |
+
"./ar-ma": 305,
|
| 17965 |
+
"./ar-ma.js": 305,
|
| 17966 |
+
"./ar-sa": 306,
|
| 17967 |
+
"./ar-sa.js": 306,
|
| 17968 |
+
"./ar-tn": 307,
|
| 17969 |
+
"./ar-tn.js": 307,
|
| 17970 |
+
"./ar.js": 301,
|
| 17971 |
+
"./az": 308,
|
| 17972 |
+
"./az.js": 308,
|
| 17973 |
+
"./be": 309,
|
| 17974 |
+
"./be.js": 309,
|
| 17975 |
+
"./bg": 310,
|
| 17976 |
+
"./bg.js": 310,
|
| 17977 |
+
"./bn": 311,
|
| 17978 |
+
"./bn.js": 311,
|
| 17979 |
+
"./bo": 312,
|
| 17980 |
+
"./bo.js": 312,
|
| 17981 |
+
"./br": 313,
|
| 17982 |
+
"./br.js": 313,
|
| 17983 |
+
"./bs": 314,
|
| 17984 |
+
"./bs.js": 314,
|
| 17985 |
+
"./ca": 315,
|
| 17986 |
+
"./ca.js": 315,
|
| 17987 |
+
"./cs": 316,
|
| 17988 |
+
"./cs.js": 316,
|
| 17989 |
+
"./cv": 317,
|
| 17990 |
+
"./cv.js": 317,
|
| 17991 |
+
"./cy": 318,
|
| 17992 |
+
"./cy.js": 318,
|
| 17993 |
+
"./da": 319,
|
| 17994 |
+
"./da.js": 319,
|
| 17995 |
+
"./de": 320,
|
| 17996 |
+
"./de-at": 321,
|
| 17997 |
+
"./de-at.js": 321,
|
| 17998 |
+
"./de-ch": 322,
|
| 17999 |
+
"./de-ch.js": 322,
|
| 18000 |
+
"./de.js": 320,
|
| 18001 |
+
"./dv": 323,
|
| 18002 |
+
"./dv.js": 323,
|
| 18003 |
+
"./el": 324,
|
| 18004 |
+
"./el.js": 324,
|
| 18005 |
+
"./en-au": 325,
|
| 18006 |
+
"./en-au.js": 325,
|
| 18007 |
+
"./en-ca": 326,
|
| 18008 |
+
"./en-ca.js": 326,
|
| 18009 |
+
"./en-gb": 327,
|
| 18010 |
+
"./en-gb.js": 327,
|
| 18011 |
+
"./en-ie": 328,
|
| 18012 |
+
"./en-ie.js": 328,
|
| 18013 |
+
"./en-nz": 329,
|
| 18014 |
+
"./en-nz.js": 329,
|
| 18015 |
+
"./eo": 330,
|
| 18016 |
+
"./eo.js": 330,
|
| 18017 |
+
"./es": 331,
|
| 18018 |
+
"./es-do": 332,
|
| 18019 |
+
"./es-do.js": 332,
|
| 18020 |
+
"./es.js": 331,
|
| 18021 |
+
"./et": 333,
|
| 18022 |
+
"./et.js": 333,
|
| 18023 |
+
"./eu": 334,
|
| 18024 |
+
"./eu.js": 334,
|
| 18025 |
+
"./fa": 335,
|
| 18026 |
+
"./fa.js": 335,
|
| 18027 |
+
"./fi": 336,
|
| 18028 |
+
"./fi.js": 336,
|
| 18029 |
+
"./fo": 337,
|
| 18030 |
+
"./fo.js": 337,
|
| 18031 |
+
"./fr": 338,
|
| 18032 |
+
"./fr-ca": 339,
|
| 18033 |
+
"./fr-ca.js": 339,
|
| 18034 |
+
"./fr-ch": 340,
|
| 18035 |
+
"./fr-ch.js": 340,
|
| 18036 |
+
"./fr.js": 338,
|
| 18037 |
+
"./fy": 341,
|
| 18038 |
+
"./fy.js": 341,
|
| 18039 |
+
"./gd": 342,
|
| 18040 |
+
"./gd.js": 342,
|
| 18041 |
+
"./gl": 343,
|
| 18042 |
+
"./gl.js": 343,
|
| 18043 |
+
"./gom-latn": 344,
|
| 18044 |
+
"./gom-latn.js": 344,
|
| 18045 |
+
"./he": 345,
|
| 18046 |
+
"./he.js": 345,
|
| 18047 |
+
"./hi": 346,
|
| 18048 |
+
"./hi.js": 346,
|
| 18049 |
+
"./hr": 347,
|
| 18050 |
+
"./hr.js": 347,
|
| 18051 |
+
"./hu": 348,
|
| 18052 |
+
"./hu.js": 348,
|
| 18053 |
+
"./hy-am": 349,
|
| 18054 |
+
"./hy-am.js": 349,
|
| 18055 |
+
"./id": 350,
|
| 18056 |
+
"./id.js": 350,
|
| 18057 |
+
"./is": 351,
|
| 18058 |
+
"./is.js": 351,
|
| 18059 |
+
"./it": 352,
|
| 18060 |
+
"./it.js": 352,
|
| 18061 |
+
"./ja": 353,
|
| 18062 |
+
"./ja.js": 353,
|
| 18063 |
+
"./jv": 354,
|
| 18064 |
+
"./jv.js": 354,
|
| 18065 |
+
"./ka": 355,
|
| 18066 |
+
"./ka.js": 355,
|
| 18067 |
+
"./kk": 356,
|
| 18068 |
+
"./kk.js": 356,
|
| 18069 |
+
"./km": 357,
|
| 18070 |
+
"./km.js": 357,
|
| 18071 |
+
"./kn": 358,
|
| 18072 |
+
"./kn.js": 358,
|
| 18073 |
+
"./ko": 359,
|
| 18074 |
+
"./ko.js": 359,
|
| 18075 |
+
"./ky": 360,
|
| 18076 |
+
"./ky.js": 360,
|
| 18077 |
+
"./lb": 361,
|
| 18078 |
+
"./lb.js": 361,
|
| 18079 |
+
"./lo": 362,
|
| 18080 |
+
"./lo.js": 362,
|
| 18081 |
+
"./lt": 363,
|
| 18082 |
+
"./lt.js": 363,
|
| 18083 |
+
"./lv": 364,
|
| 18084 |
+
"./lv.js": 364,
|
| 18085 |
+
"./me": 365,
|
| 18086 |
+
"./me.js": 365,
|
| 18087 |
+
"./mi": 366,
|
| 18088 |
+
"./mi.js": 366,
|
| 18089 |
+
"./mk": 367,
|
| 18090 |
+
"./mk.js": 367,
|
| 18091 |
+
"./ml": 368,
|
| 18092 |
+
"./ml.js": 368,
|
| 18093 |
+
"./mr": 369,
|
| 18094 |
+
"./mr.js": 369,
|
| 18095 |
+
"./ms": 370,
|
| 18096 |
+
"./ms-my": 371,
|
| 18097 |
+
"./ms-my.js": 371,
|
| 18098 |
+
"./ms.js": 370,
|
| 18099 |
+
"./my": 372,
|
| 18100 |
+
"./my.js": 372,
|
| 18101 |
+
"./nb": 373,
|
| 18102 |
+
"./nb.js": 373,
|
| 18103 |
+
"./ne": 374,
|
| 18104 |
+
"./ne.js": 374,
|
| 18105 |
+
"./nl": 375,
|
| 18106 |
+
"./nl-be": 376,
|
| 18107 |
+
"./nl-be.js": 376,
|
| 18108 |
+
"./nl.js": 375,
|
| 18109 |
+
"./nn": 377,
|
| 18110 |
+
"./nn.js": 377,
|
| 18111 |
+
"./pa-in": 378,
|
| 18112 |
+
"./pa-in.js": 378,
|
| 18113 |
+
"./pl": 379,
|
| 18114 |
+
"./pl.js": 379,
|
| 18115 |
+
"./pt": 380,
|
| 18116 |
+
"./pt-br": 381,
|
| 18117 |
+
"./pt-br.js": 381,
|
| 18118 |
+
"./pt.js": 380,
|
| 18119 |
+
"./ro": 382,
|
| 18120 |
+
"./ro.js": 382,
|
| 18121 |
+
"./ru": 383,
|
| 18122 |
+
"./ru.js": 383,
|
| 18123 |
+
"./sd": 384,
|
| 18124 |
+
"./sd.js": 384,
|
| 18125 |
+
"./se": 385,
|
| 18126 |
+
"./se.js": 385,
|
| 18127 |
+
"./si": 386,
|
| 18128 |
+
"./si.js": 386,
|
| 18129 |
+
"./sk": 387,
|
| 18130 |
+
"./sk.js": 387,
|
| 18131 |
+
"./sl": 388,
|
| 18132 |
+
"./sl.js": 388,
|
| 18133 |
+
"./sq": 389,
|
| 18134 |
+
"./sq.js": 389,
|
| 18135 |
+
"./sr": 390,
|
| 18136 |
+
"./sr-cyrl": 391,
|
| 18137 |
+
"./sr-cyrl.js": 391,
|
| 18138 |
+
"./sr.js": 390,
|
| 18139 |
+
"./ss": 392,
|
| 18140 |
+
"./ss.js": 392,
|
| 18141 |
+
"./sv": 393,
|
| 18142 |
+
"./sv.js": 393,
|
| 18143 |
+
"./sw": 394,
|
| 18144 |
+
"./sw.js": 394,
|
| 18145 |
+
"./ta": 395,
|
| 18146 |
+
"./ta.js": 395,
|
| 18147 |
+
"./te": 396,
|
| 18148 |
+
"./te.js": 396,
|
| 18149 |
+
"./tet": 397,
|
| 18150 |
+
"./tet.js": 397,
|
| 18151 |
+
"./th": 398,
|
| 18152 |
+
"./th.js": 398,
|
| 18153 |
+
"./tl-ph": 399,
|
| 18154 |
+
"./tl-ph.js": 399,
|
| 18155 |
+
"./tlh": 400,
|
| 18156 |
+
"./tlh.js": 400,
|
| 18157 |
+
"./tr": 401,
|
| 18158 |
+
"./tr.js": 401,
|
| 18159 |
+
"./tzl": 402,
|
| 18160 |
+
"./tzl.js": 402,
|
| 18161 |
+
"./tzm": 403,
|
| 18162 |
+
"./tzm-latn": 404,
|
| 18163 |
+
"./tzm-latn.js": 404,
|
| 18164 |
+
"./tzm.js": 403,
|
| 18165 |
+
"./uk": 405,
|
| 18166 |
+
"./uk.js": 405,
|
| 18167 |
+
"./ur": 406,
|
| 18168 |
+
"./ur.js": 406,
|
| 18169 |
+
"./uz": 407,
|
| 18170 |
+
"./uz-latn": 408,
|
| 18171 |
+
"./uz-latn.js": 408,
|
| 18172 |
+
"./uz.js": 407,
|
| 18173 |
+
"./vi": 409,
|
| 18174 |
+
"./vi.js": 409,
|
| 18175 |
+
"./x-pseudo": 410,
|
| 18176 |
+
"./x-pseudo.js": 410,
|
| 18177 |
+
"./yo": 411,
|
| 18178 |
+
"./yo.js": 411,
|
| 18179 |
+
"./zh-cn": 412,
|
| 18180 |
+
"./zh-cn.js": 412,
|
| 18181 |
+
"./zh-hk": 413,
|
| 18182 |
+
"./zh-hk.js": 413,
|
| 18183 |
+
"./zh-tw": 414,
|
| 18184 |
+
"./zh-tw.js": 414
|
| 18185 |
};
|
| 18186 |
function webpackContext(req) {
|
| 18187 |
return __webpack_require__(webpackContextResolve(req));
|
| 18194 |
};
|
| 18195 |
webpackContext.resolve = webpackContextResolve;
|
| 18196 |
module.exports = webpackContext;
|
| 18197 |
+
webpackContext.id = 299;
|
| 18198 |
|
| 18199 |
|
| 18200 |
/***/ },
|
| 18201 |
+
/* 300 */
|
| 18202 |
/***/ function(module, exports, __webpack_require__) {
|
| 18203 |
|
| 18204 |
//! moment.js locale configuration
|
| 18206 |
//! author : Werner Mollentze : https://github.com/wernerm
|
| 18207 |
|
| 18208 |
;(function (global, factory) {
|
| 18209 |
+
true ? factory(__webpack_require__(297)) :
|
| 18210 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18211 |
factory(global.moment)
|
| 18212 |
}(this, (function (moment) { 'use strict';
|
| 18260 |
y : '\'n jaar',
|
| 18261 |
yy : '%d jaar'
|
| 18262 |
},
|
| 18263 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 18264 |
ordinal : function (number) {
|
| 18265 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de'); // Thanks to Joris Röling : https://github.com/jjupiter
|
| 18266 |
},
|
| 18276 |
|
| 18277 |
|
| 18278 |
/***/ },
|
| 18279 |
+
/* 301 */
|
| 18280 |
/***/ function(module, exports, __webpack_require__) {
|
| 18281 |
|
| 18282 |
//! moment.js locale configuration
|
| 18286 |
//! author : forabi https://github.com/forabi
|
| 18287 |
|
| 18288 |
;(function (global, factory) {
|
| 18289 |
+
true ? factory(__webpack_require__(297)) :
|
| 18290 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18291 |
factory(global.moment)
|
| 18292 |
}(this, (function (moment) { 'use strict';
|
| 18423 |
|
| 18424 |
|
| 18425 |
/***/ },
|
| 18426 |
+
/* 302 */
|
| 18427 |
/***/ function(module, exports, __webpack_require__) {
|
| 18428 |
|
| 18429 |
//! moment.js locale configuration
|
| 18431 |
//! author : Noureddine LOUAHEDJ : https://github.com/noureddineme
|
| 18432 |
|
| 18433 |
;(function (global, factory) {
|
| 18434 |
+
true ? factory(__webpack_require__(297)) :
|
| 18435 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18436 |
factory(global.moment)
|
| 18437 |
}(this, (function (moment) { 'use strict';
|
| 18487 |
|
| 18488 |
|
| 18489 |
/***/ },
|
| 18490 |
+
/* 303 */
|
| 18491 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 18492 |
+
|
| 18493 |
+
//! moment.js locale configuration
|
| 18494 |
+
//! locale : Arabic (Kuwait) [ar-kw]
|
| 18495 |
+
//! author : Nusret Parlak: https://github.com/nusretparlak
|
| 18496 |
+
|
| 18497 |
+
;(function (global, factory) {
|
| 18498 |
+
true ? factory(__webpack_require__(297)) :
|
| 18499 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18500 |
+
factory(global.moment)
|
| 18501 |
+
}(this, (function (moment) { 'use strict';
|
| 18502 |
+
|
| 18503 |
+
|
| 18504 |
+
var arKw = moment.defineLocale('ar-kw', {
|
| 18505 |
+
months : 'يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split('_'),
|
| 18506 |
+
monthsShort : 'يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split('_'),
|
| 18507 |
+
weekdays : 'الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),
|
| 18508 |
+
weekdaysShort : 'احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت'.split('_'),
|
| 18509 |
+
weekdaysMin : 'ح_ن_ث_ر_خ_ج_س'.split('_'),
|
| 18510 |
+
weekdaysParseExact : true,
|
| 18511 |
+
longDateFormat : {
|
| 18512 |
+
LT : 'HH:mm',
|
| 18513 |
+
LTS : 'HH:mm:ss',
|
| 18514 |
+
L : 'DD/MM/YYYY',
|
| 18515 |
+
LL : 'D MMMM YYYY',
|
| 18516 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 18517 |
+
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 18518 |
+
},
|
| 18519 |
+
calendar : {
|
| 18520 |
+
sameDay: '[اليوم على الساعة] LT',
|
| 18521 |
+
nextDay: '[غدا على الساعة] LT',
|
| 18522 |
+
nextWeek: 'dddd [على الساعة] LT',
|
| 18523 |
+
lastDay: '[أمس على الساعة] LT',
|
| 18524 |
+
lastWeek: 'dddd [على الساعة] LT',
|
| 18525 |
+
sameElse: 'L'
|
| 18526 |
+
},
|
| 18527 |
+
relativeTime : {
|
| 18528 |
+
future : 'في %s',
|
| 18529 |
+
past : 'منذ %s',
|
| 18530 |
+
s : 'ثوان',
|
| 18531 |
+
m : 'دقيقة',
|
| 18532 |
+
mm : '%d دقائق',
|
| 18533 |
+
h : 'ساعة',
|
| 18534 |
+
hh : '%d ساعات',
|
| 18535 |
+
d : 'يوم',
|
| 18536 |
+
dd : '%d أيام',
|
| 18537 |
+
M : 'شهر',
|
| 18538 |
+
MM : '%d أشهر',
|
| 18539 |
+
y : 'سنة',
|
| 18540 |
+
yy : '%d سنوات'
|
| 18541 |
+
},
|
| 18542 |
+
week : {
|
| 18543 |
+
dow : 0, // Sunday is the first day of the week.
|
| 18544 |
+
doy : 12 // The week that contains Jan 1st is the first week of the year.
|
| 18545 |
+
}
|
| 18546 |
+
});
|
| 18547 |
+
|
| 18548 |
+
return arKw;
|
| 18549 |
+
|
| 18550 |
+
})));
|
| 18551 |
+
|
| 18552 |
+
|
| 18553 |
+
/***/ },
|
| 18554 |
+
/* 304 */
|
| 18555 |
/***/ function(module, exports, __webpack_require__) {
|
| 18556 |
|
| 18557 |
//! moment.js locale configuration
|
| 18559 |
//! author : Ali Hmer: https://github.com/kikoanis
|
| 18560 |
|
| 18561 |
;(function (global, factory) {
|
| 18562 |
+
true ? factory(__webpack_require__(297)) :
|
| 18563 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18564 |
factory(global.moment)
|
| 18565 |
}(this, (function (moment) { 'use strict';
|
| 18682 |
|
| 18683 |
|
| 18684 |
/***/ },
|
| 18685 |
+
/* 305 */
|
| 18686 |
/***/ function(module, exports, __webpack_require__) {
|
| 18687 |
|
| 18688 |
//! moment.js locale configuration
|
| 18691 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 18692 |
|
| 18693 |
;(function (global, factory) {
|
| 18694 |
+
true ? factory(__webpack_require__(297)) :
|
| 18695 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18696 |
factory(global.moment)
|
| 18697 |
}(this, (function (moment) { 'use strict';
|
| 18747 |
|
| 18748 |
|
| 18749 |
/***/ },
|
| 18750 |
+
/* 306 */
|
| 18751 |
/***/ function(module, exports, __webpack_require__) {
|
| 18752 |
|
| 18753 |
//! moment.js locale configuration
|
| 18755 |
//! author : Suhail Alkowaileet : https://github.com/xsoh
|
| 18756 |
|
| 18757 |
;(function (global, factory) {
|
| 18758 |
+
true ? factory(__webpack_require__(297)) :
|
| 18759 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18760 |
factory(global.moment)
|
| 18761 |
}(this, (function (moment) { 'use strict';
|
| 18857 |
|
| 18858 |
|
| 18859 |
/***/ },
|
| 18860 |
+
/* 307 */
|
| 18861 |
/***/ function(module, exports, __webpack_require__) {
|
| 18862 |
|
| 18863 |
//! moment.js locale configuration
|
| 18865 |
//! author : Nader Toukabri : https://github.com/naderio
|
| 18866 |
|
| 18867 |
;(function (global, factory) {
|
| 18868 |
+
true ? factory(__webpack_require__(297)) :
|
| 18869 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18870 |
factory(global.moment)
|
| 18871 |
}(this, (function (moment) { 'use strict';
|
| 18921 |
|
| 18922 |
|
| 18923 |
/***/ },
|
| 18924 |
+
/* 308 */
|
| 18925 |
/***/ function(module, exports, __webpack_require__) {
|
| 18926 |
|
| 18927 |
//! moment.js locale configuration
|
| 18929 |
//! author : topchiyev : https://github.com/topchiyev
|
| 18930 |
|
| 18931 |
;(function (global, factory) {
|
| 18932 |
+
true ? factory(__webpack_require__(297)) :
|
| 18933 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 18934 |
factory(global.moment)
|
| 18935 |
}(this, (function (moment) { 'use strict';
|
| 19009 |
return 'axşam';
|
| 19010 |
}
|
| 19011 |
},
|
| 19012 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,
|
| 19013 |
ordinal : function (number) {
|
| 19014 |
if (number === 0) { // special case for zero
|
| 19015 |
return number + '-ıncı';
|
| 19031 |
|
| 19032 |
|
| 19033 |
/***/ },
|
| 19034 |
+
/* 309 */
|
| 19035 |
/***/ function(module, exports, __webpack_require__) {
|
| 19036 |
|
| 19037 |
//! moment.js locale configuration
|
| 19041 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 19042 |
|
| 19043 |
;(function (global, factory) {
|
| 19044 |
+
true ? factory(__webpack_require__(297)) :
|
| 19045 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19046 |
factory(global.moment)
|
| 19047 |
}(this, (function (moment) { 'use strict';
|
| 19143 |
return 'вечара';
|
| 19144 |
}
|
| 19145 |
},
|
| 19146 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(і|ы|га)/,
|
| 19147 |
ordinal: function (number, period) {
|
| 19148 |
switch (period) {
|
| 19149 |
case 'M':
|
| 19170 |
|
| 19171 |
|
| 19172 |
/***/ },
|
| 19173 |
+
/* 310 */
|
| 19174 |
/***/ function(module, exports, __webpack_require__) {
|
| 19175 |
|
| 19176 |
//! moment.js locale configuration
|
| 19178 |
//! author : Krasen Borisov : https://github.com/kraz
|
| 19179 |
|
| 19180 |
;(function (global, factory) {
|
| 19181 |
+
true ? factory(__webpack_require__(297)) :
|
| 19182 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19183 |
factory(global.moment)
|
| 19184 |
}(this, (function (moment) { 'use strict';
|
| 19233 |
y : 'година',
|
| 19234 |
yy : '%d години'
|
| 19235 |
},
|
| 19236 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ев|ен|ти|ви|ри|ми)/,
|
| 19237 |
ordinal : function (number) {
|
| 19238 |
var lastDigit = number % 10,
|
| 19239 |
last2Digits = number % 100;
|
| 19265 |
|
| 19266 |
|
| 19267 |
/***/ },
|
| 19268 |
+
/* 311 */
|
| 19269 |
/***/ function(module, exports, __webpack_require__) {
|
| 19270 |
|
| 19271 |
//! moment.js locale configuration
|
| 19273 |
//! author : Kaushik Gandhi : https://github.com/kaushikgandhi
|
| 19274 |
|
| 19275 |
;(function (global, factory) {
|
| 19276 |
+
true ? factory(__webpack_require__(297)) :
|
| 19277 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19278 |
factory(global.moment)
|
| 19279 |
}(this, (function (moment) { 'use strict';
|
| 19389 |
|
| 19390 |
|
| 19391 |
/***/ },
|
| 19392 |
+
/* 312 */
|
| 19393 |
/***/ function(module, exports, __webpack_require__) {
|
| 19394 |
|
| 19395 |
//! moment.js locale configuration
|
| 19397 |
//! author : Thupten N. Chakrishar : https://github.com/vajradog
|
| 19398 |
|
| 19399 |
;(function (global, factory) {
|
| 19400 |
+
true ? factory(__webpack_require__(297)) :
|
| 19401 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19402 |
factory(global.moment)
|
| 19403 |
}(this, (function (moment) { 'use strict';
|
| 19513 |
|
| 19514 |
|
| 19515 |
/***/ },
|
| 19516 |
+
/* 313 */
|
| 19517 |
/***/ function(module, exports, __webpack_require__) {
|
| 19518 |
|
| 19519 |
//! moment.js locale configuration
|
| 19521 |
//! author : Jean-Baptiste Le Duigou : https://github.com/jbleduigou
|
| 19522 |
|
| 19523 |
;(function (global, factory) {
|
| 19524 |
+
true ? factory(__webpack_require__(297)) :
|
| 19525 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19526 |
factory(global.moment)
|
| 19527 |
}(this, (function (moment) { 'use strict';
|
| 19609 |
y : 'ur bloaz',
|
| 19610 |
yy : specialMutationForYears
|
| 19611 |
},
|
| 19612 |
+
dayOfMonthOrdinalParse: /\d{1,2}(añ|vet)/,
|
| 19613 |
ordinal : function (number) {
|
| 19614 |
var output = (number === 1) ? 'añ' : 'vet';
|
| 19615 |
return number + output;
|
| 19626 |
|
| 19627 |
|
| 19628 |
/***/ },
|
| 19629 |
+
/* 314 */
|
| 19630 |
/***/ function(module, exports, __webpack_require__) {
|
| 19631 |
|
| 19632 |
//! moment.js locale configuration
|
| 19635 |
//! based on (hr) translation by Bojan Marković
|
| 19636 |
|
| 19637 |
;(function (global, factory) {
|
| 19638 |
+
true ? factory(__webpack_require__(297)) :
|
| 19639 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19640 |
factory(global.moment)
|
| 19641 |
}(this, (function (moment) { 'use strict';
|
| 19760 |
y : 'godinu',
|
| 19761 |
yy : translate
|
| 19762 |
},
|
| 19763 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 19764 |
ordinal : '%d.',
|
| 19765 |
week : {
|
| 19766 |
dow : 1, // Monday is the first day of the week.
|
| 19774 |
|
| 19775 |
|
| 19776 |
/***/ },
|
| 19777 |
+
/* 315 */
|
| 19778 |
/***/ function(module, exports, __webpack_require__) {
|
| 19779 |
|
| 19780 |
//! moment.js locale configuration
|
| 19782 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 19783 |
|
| 19784 |
;(function (global, factory) {
|
| 19785 |
+
true ? factory(__webpack_require__(297)) :
|
| 19786 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19787 |
factory(global.moment)
|
| 19788 |
}(this, (function (moment) { 'use strict';
|
| 19789 |
|
| 19790 |
|
| 19791 |
var ca = moment.defineLocale('ca', {
|
| 19792 |
+
months : {
|
| 19793 |
+
standalone: 'gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre'.split('_'),
|
| 19794 |
+
format: 'de gener_de febrer_de març_d\'abril_de maig_de juny_de juliol_d\'agost_de setembre_d\'octubre_de novembre_de desembre'.split('_'),
|
| 19795 |
+
isFormat: /D[oD]?(\s)+MMMM/
|
| 19796 |
+
},
|
| 19797 |
+
monthsShort : 'gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.'.split('_'),
|
| 19798 |
monthsParseExact : true,
|
| 19799 |
weekdays : 'diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte'.split('_'),
|
| 19800 |
weekdaysShort : 'dg._dl._dt._dc._dj._dv._ds.'.split('_'),
|
| 19804 |
LT : 'H:mm',
|
| 19805 |
LTS : 'H:mm:ss',
|
| 19806 |
L : 'DD/MM/YYYY',
|
| 19807 |
+
LL : '[el] D MMMM [de] YYYY',
|
| 19808 |
+
ll : 'D MMM YYYY',
|
| 19809 |
+
LLL : '[el] D MMMM [de] YYYY [a les] H:mm',
|
| 19810 |
+
lll : 'D MMM YYYY, H:mm',
|
| 19811 |
+
LLLL : '[el] dddd D MMMM [de] YYYY [a les] H:mm',
|
| 19812 |
+
llll : 'ddd D MMM YYYY, H:mm'
|
| 19813 |
},
|
| 19814 |
calendar : {
|
| 19815 |
sameDay : function () {
|
| 19844 |
y : 'un any',
|
| 19845 |
yy : '%d anys'
|
| 19846 |
},
|
| 19847 |
+
dayOfMonthOrdinalParse: /\d{1,2}(r|n|t|è|a)/,
|
| 19848 |
ordinal : function (number, period) {
|
| 19849 |
var output = (number === 1) ? 'r' :
|
| 19850 |
(number === 2) ? 'n' :
|
| 19867 |
|
| 19868 |
|
| 19869 |
/***/ },
|
| 19870 |
+
/* 316 */
|
| 19871 |
/***/ function(module, exports, __webpack_require__) {
|
| 19872 |
|
| 19873 |
//! moment.js locale configuration
|
| 19875 |
//! author : petrbela : https://github.com/petrbela
|
| 19876 |
|
| 19877 |
;(function (global, factory) {
|
| 19878 |
+
true ? factory(__webpack_require__(297)) :
|
| 19879 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 19880 |
factory(global.moment)
|
| 19881 |
}(this, (function (moment) { 'use strict';
|
| 20030 |
y : translate,
|
| 20031 |
yy : translate
|
| 20032 |
},
|
| 20033 |
+
dayOfMonthOrdinalParse : /\d{1,2}\./,
|
| 20034 |
ordinal : '%d.',
|
| 20035 |
week : {
|
| 20036 |
dow : 1, // Monday is the first day of the week.
|
| 20044 |
|
| 20045 |
|
| 20046 |
/***/ },
|
| 20047 |
+
/* 317 */
|
| 20048 |
/***/ function(module, exports, __webpack_require__) {
|
| 20049 |
|
| 20050 |
//! moment.js locale configuration
|
| 20052 |
//! author : Anatoly Mironov : https://github.com/mirontoli
|
| 20053 |
|
| 20054 |
;(function (global, factory) {
|
| 20055 |
+
true ? factory(__webpack_require__(297)) :
|
| 20056 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20057 |
factory(global.moment)
|
| 20058 |
}(this, (function (moment) { 'use strict';
|
| 20098 |
y : 'пӗр ҫул',
|
| 20099 |
yy : '%d ҫул'
|
| 20100 |
},
|
| 20101 |
+
dayOfMonthOrdinalParse: /\d{1,2}-мӗш/,
|
| 20102 |
ordinal : '%d-мӗш',
|
| 20103 |
week : {
|
| 20104 |
dow : 1, // Monday is the first day of the week.
|
| 20112 |
|
| 20113 |
|
| 20114 |
/***/ },
|
| 20115 |
+
/* 318 */
|
| 20116 |
/***/ function(module, exports, __webpack_require__) {
|
| 20117 |
|
| 20118 |
//! moment.js locale configuration
|
| 20121 |
//! author : https://github.com/ryangreaves
|
| 20122 |
|
| 20123 |
;(function (global, factory) {
|
| 20124 |
+
true ? factory(__webpack_require__(297)) :
|
| 20125 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20126 |
factory(global.moment)
|
| 20127 |
}(this, (function (moment) { 'use strict';
|
| 20166 |
y: 'blwyddyn',
|
| 20167 |
yy: '%d flynedd'
|
| 20168 |
},
|
| 20169 |
+
dayOfMonthOrdinalParse: /\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,
|
| 20170 |
// traditional ordinal numbers above 31 are not commonly used in colloquial Welsh
|
| 20171 |
ordinal: function (number) {
|
| 20172 |
var b = number,
|
| 20198 |
|
| 20199 |
|
| 20200 |
/***/ },
|
| 20201 |
+
/* 319 */
|
| 20202 |
/***/ function(module, exports, __webpack_require__) {
|
| 20203 |
|
| 20204 |
//! moment.js locale configuration
|
| 20206 |
//! author : Ulrik Nielsen : https://github.com/mrbase
|
| 20207 |
|
| 20208 |
;(function (global, factory) {
|
| 20209 |
+
true ? factory(__webpack_require__(297)) :
|
| 20210 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20211 |
factory(global.moment)
|
| 20212 |
}(this, (function (moment) { 'use strict';
|
| 20224 |
L : 'DD/MM/YYYY',
|
| 20225 |
LL : 'D. MMMM YYYY',
|
| 20226 |
LLL : 'D. MMMM YYYY HH:mm',
|
| 20227 |
+
LLLL : 'dddd [d.] D. MMMM YYYY [kl.] HH:mm'
|
| 20228 |
},
|
| 20229 |
calendar : {
|
| 20230 |
+
sameDay : '[i dag kl.] LT',
|
| 20231 |
+
nextDay : '[i morgen kl.] LT',
|
| 20232 |
+
nextWeek : 'på dddd [kl.] LT',
|
| 20233 |
+
lastDay : '[i går kl.] LT',
|
| 20234 |
+
lastWeek : '[i] dddd[s kl.] LT',
|
| 20235 |
sameElse : 'L'
|
| 20236 |
},
|
| 20237 |
relativeTime : {
|
| 20249 |
y : 'et år',
|
| 20250 |
yy : '%d år'
|
| 20251 |
},
|
| 20252 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 20253 |
ordinal : '%d.',
|
| 20254 |
week : {
|
| 20255 |
dow : 1, // Monday is the first day of the week.
|
| 20263 |
|
| 20264 |
|
| 20265 |
/***/ },
|
| 20266 |
+
/* 320 */
|
| 20267 |
/***/ function(module, exports, __webpack_require__) {
|
| 20268 |
|
| 20269 |
//! moment.js locale configuration
|
| 20273 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 20274 |
|
| 20275 |
;(function (global, factory) {
|
| 20276 |
+
true ? factory(__webpack_require__(297)) :
|
| 20277 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20278 |
factory(global.moment)
|
| 20279 |
}(this, (function (moment) { 'use strict';
|
| 20332 |
y : processRelativeTime,
|
| 20333 |
yy : processRelativeTime
|
| 20334 |
},
|
| 20335 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 20336 |
ordinal : '%d.',
|
| 20337 |
week : {
|
| 20338 |
dow : 1, // Monday is the first day of the week.
|
| 20346 |
|
| 20347 |
|
| 20348 |
/***/ },
|
| 20349 |
+
/* 321 */
|
| 20350 |
/***/ function(module, exports, __webpack_require__) {
|
| 20351 |
|
| 20352 |
//! moment.js locale configuration
|
| 20357 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 20358 |
|
| 20359 |
;(function (global, factory) {
|
| 20360 |
+
true ? factory(__webpack_require__(297)) :
|
| 20361 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20362 |
factory(global.moment)
|
| 20363 |
}(this, (function (moment) { 'use strict';
|
| 20416 |
y : processRelativeTime,
|
| 20417 |
yy : processRelativeTime
|
| 20418 |
},
|
| 20419 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 20420 |
ordinal : '%d.',
|
| 20421 |
week : {
|
| 20422 |
dow : 1, // Monday is the first day of the week.
|
| 20430 |
|
| 20431 |
|
| 20432 |
/***/ },
|
| 20433 |
+
/* 322 */
|
| 20434 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 20435 |
+
|
| 20436 |
+
//! moment.js locale configuration
|
| 20437 |
+
//! locale : German (Switzerland) [de-ch]
|
| 20438 |
+
//! author : sschueller : https://github.com/sschueller
|
| 20439 |
+
|
| 20440 |
+
;(function (global, factory) {
|
| 20441 |
+
true ? factory(__webpack_require__(297)) :
|
| 20442 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20443 |
+
factory(global.moment)
|
| 20444 |
+
}(this, (function (moment) { 'use strict';
|
| 20445 |
+
|
| 20446 |
+
|
| 20447 |
+
// based on: https://www.bk.admin.ch/dokumentation/sprachen/04915/05016/index.html?lang=de#
|
| 20448 |
+
|
| 20449 |
+
function processRelativeTime(number, withoutSuffix, key, isFuture) {
|
| 20450 |
+
var format = {
|
| 20451 |
+
'm': ['eine Minute', 'einer Minute'],
|
| 20452 |
+
'h': ['eine Stunde', 'einer Stunde'],
|
| 20453 |
+
'd': ['ein Tag', 'einem Tag'],
|
| 20454 |
+
'dd': [number + ' Tage', number + ' Tagen'],
|
| 20455 |
+
'M': ['ein Monat', 'einem Monat'],
|
| 20456 |
+
'MM': [number + ' Monate', number + ' Monaten'],
|
| 20457 |
+
'y': ['ein Jahr', 'einem Jahr'],
|
| 20458 |
+
'yy': [number + ' Jahre', number + ' Jahren']
|
| 20459 |
+
};
|
| 20460 |
+
return withoutSuffix ? format[key][0] : format[key][1];
|
| 20461 |
+
}
|
| 20462 |
+
|
| 20463 |
+
var deCh = moment.defineLocale('de-ch', {
|
| 20464 |
+
months : 'Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember'.split('_'),
|
| 20465 |
+
monthsShort : 'Jan._Febr._März_April_Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.'.split('_'),
|
| 20466 |
+
monthsParseExact : true,
|
| 20467 |
+
weekdays : 'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split('_'),
|
| 20468 |
+
weekdaysShort : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
|
| 20469 |
+
weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
|
| 20470 |
+
weekdaysParseExact : true,
|
| 20471 |
+
longDateFormat : {
|
| 20472 |
+
LT: 'HH.mm',
|
| 20473 |
+
LTS: 'HH.mm.ss',
|
| 20474 |
+
L : 'DD.MM.YYYY',
|
| 20475 |
+
LL : 'D. MMMM YYYY',
|
| 20476 |
+
LLL : 'D. MMMM YYYY HH.mm',
|
| 20477 |
+
LLLL : 'dddd, D. MMMM YYYY HH.mm'
|
| 20478 |
+
},
|
| 20479 |
+
calendar : {
|
| 20480 |
+
sameDay: '[heute um] LT [Uhr]',
|
| 20481 |
+
sameElse: 'L',
|
| 20482 |
+
nextDay: '[morgen um] LT [Uhr]',
|
| 20483 |
+
nextWeek: 'dddd [um] LT [Uhr]',
|
| 20484 |
+
lastDay: '[gestern um] LT [Uhr]',
|
| 20485 |
+
lastWeek: '[letzten] dddd [um] LT [Uhr]'
|
| 20486 |
+
},
|
| 20487 |
+
relativeTime : {
|
| 20488 |
+
future : 'in %s',
|
| 20489 |
+
past : 'vor %s',
|
| 20490 |
+
s : 'ein paar Sekunden',
|
| 20491 |
+
m : processRelativeTime,
|
| 20492 |
+
mm : '%d Minuten',
|
| 20493 |
+
h : processRelativeTime,
|
| 20494 |
+
hh : '%d Stunden',
|
| 20495 |
+
d : processRelativeTime,
|
| 20496 |
+
dd : processRelativeTime,
|
| 20497 |
+
M : processRelativeTime,
|
| 20498 |
+
MM : processRelativeTime,
|
| 20499 |
+
y : processRelativeTime,
|
| 20500 |
+
yy : processRelativeTime
|
| 20501 |
+
},
|
| 20502 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 20503 |
+
ordinal : '%d.',
|
| 20504 |
+
week : {
|
| 20505 |
+
dow : 1, // Monday is the first day of the week.
|
| 20506 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 20507 |
+
}
|
| 20508 |
+
});
|
| 20509 |
+
|
| 20510 |
+
return deCh;
|
| 20511 |
+
|
| 20512 |
+
})));
|
| 20513 |
+
|
| 20514 |
+
|
| 20515 |
+
/***/ },
|
| 20516 |
+
/* 323 */
|
| 20517 |
/***/ function(module, exports, __webpack_require__) {
|
| 20518 |
|
| 20519 |
//! moment.js locale configuration
|
| 20521 |
//! author : Jawish Hameed : https://github.com/jawish
|
| 20522 |
|
| 20523 |
;(function (global, factory) {
|
| 20524 |
+
true ? factory(__webpack_require__(297)) :
|
| 20525 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20526 |
factory(global.moment)
|
| 20527 |
}(this, (function (moment) { 'use strict';
|
| 20618 |
|
| 20619 |
|
| 20620 |
/***/ },
|
| 20621 |
+
/* 324 */
|
| 20622 |
/***/ function(module, exports, __webpack_require__) {
|
| 20623 |
|
| 20624 |
//! moment.js locale configuration
|
| 20626 |
//! author : Aggelos Karalias : https://github.com/mehiel
|
| 20627 |
|
| 20628 |
;(function (global, factory) {
|
| 20629 |
+
true ? factory(__webpack_require__(297)) :
|
| 20630 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20631 |
factory(global.moment)
|
| 20632 |
}(this, (function (moment) { 'use strict';
|
| 20640 |
monthsNominativeEl : 'Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος'.split('_'),
|
| 20641 |
monthsGenitiveEl : 'Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου'.split('_'),
|
| 20642 |
months : function (momentToFormat, format) {
|
| 20643 |
+
if (!momentToFormat) {
|
| 20644 |
+
return this._monthsNominativeEl;
|
| 20645 |
+
} else if (/D/.test(format.substring(0, format.indexOf('MMMM')))) { // if there is a day number before 'MMMM'
|
| 20646 |
return this._monthsGenitiveEl[momentToFormat.month()];
|
| 20647 |
} else {
|
| 20648 |
return this._monthsNominativeEl[momentToFormat.month()];
|
| 20709 |
y : 'ένας χρόνος',
|
| 20710 |
yy : '%d χρόνια'
|
| 20711 |
},
|
| 20712 |
+
dayOfMonthOrdinalParse: /\d{1,2}η/,
|
| 20713 |
ordinal: '%dη',
|
| 20714 |
week : {
|
| 20715 |
dow : 1, // Monday is the first day of the week.
|
| 20723 |
|
| 20724 |
|
| 20725 |
/***/ },
|
| 20726 |
+
/* 325 */
|
| 20727 |
/***/ function(module, exports, __webpack_require__) {
|
| 20728 |
|
| 20729 |
//! moment.js locale configuration
|
| 20731 |
//! author : Jared Morse : https://github.com/jarcoal
|
| 20732 |
|
| 20733 |
;(function (global, factory) {
|
| 20734 |
+
true ? factory(__webpack_require__(297)) :
|
| 20735 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20736 |
factory(global.moment)
|
| 20737 |
}(this, (function (moment) { 'use strict';
|
| 20774 |
y : 'a year',
|
| 20775 |
yy : '%d years'
|
| 20776 |
},
|
| 20777 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 20778 |
ordinal : function (number) {
|
| 20779 |
var b = number % 10,
|
| 20780 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 20795 |
|
| 20796 |
|
| 20797 |
/***/ },
|
| 20798 |
+
/* 326 */
|
| 20799 |
/***/ function(module, exports, __webpack_require__) {
|
| 20800 |
|
| 20801 |
//! moment.js locale configuration
|
| 20803 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 20804 |
|
| 20805 |
;(function (global, factory) {
|
| 20806 |
+
true ? factory(__webpack_require__(297)) :
|
| 20807 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20808 |
factory(global.moment)
|
| 20809 |
}(this, (function (moment) { 'use strict';
|
| 20846 |
y : 'a year',
|
| 20847 |
yy : '%d years'
|
| 20848 |
},
|
| 20849 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 20850 |
ordinal : function (number) {
|
| 20851 |
var b = number % 10,
|
| 20852 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 20863 |
|
| 20864 |
|
| 20865 |
/***/ },
|
| 20866 |
+
/* 327 */
|
| 20867 |
/***/ function(module, exports, __webpack_require__) {
|
| 20868 |
|
| 20869 |
//! moment.js locale configuration
|
| 20871 |
//! author : Chris Gedrim : https://github.com/chrisgedrim
|
| 20872 |
|
| 20873 |
;(function (global, factory) {
|
| 20874 |
+
true ? factory(__webpack_require__(297)) :
|
| 20875 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20876 |
factory(global.moment)
|
| 20877 |
}(this, (function (moment) { 'use strict';
|
| 20914 |
y : 'a year',
|
| 20915 |
yy : '%d years'
|
| 20916 |
},
|
| 20917 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 20918 |
ordinal : function (number) {
|
| 20919 |
var b = number % 10,
|
| 20920 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 20935 |
|
| 20936 |
|
| 20937 |
/***/ },
|
| 20938 |
+
/* 328 */
|
| 20939 |
/***/ function(module, exports, __webpack_require__) {
|
| 20940 |
|
| 20941 |
//! moment.js locale configuration
|
| 20943 |
//! author : Chris Cartlidge : https://github.com/chriscartlidge
|
| 20944 |
|
| 20945 |
;(function (global, factory) {
|
| 20946 |
+
true ? factory(__webpack_require__(297)) :
|
| 20947 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 20948 |
factory(global.moment)
|
| 20949 |
}(this, (function (moment) { 'use strict';
|
| 20986 |
y : 'a year',
|
| 20987 |
yy : '%d years'
|
| 20988 |
},
|
| 20989 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 20990 |
ordinal : function (number) {
|
| 20991 |
var b = number % 10,
|
| 20992 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 21007 |
|
| 21008 |
|
| 21009 |
/***/ },
|
| 21010 |
+
/* 329 */
|
| 21011 |
/***/ function(module, exports, __webpack_require__) {
|
| 21012 |
|
| 21013 |
//! moment.js locale configuration
|
| 21015 |
//! author : Luke McGregor : https://github.com/lukemcgregor
|
| 21016 |
|
| 21017 |
;(function (global, factory) {
|
| 21018 |
+
true ? factory(__webpack_require__(297)) :
|
| 21019 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21020 |
factory(global.moment)
|
| 21021 |
}(this, (function (moment) { 'use strict';
|
| 21058 |
y : 'a year',
|
| 21059 |
yy : '%d years'
|
| 21060 |
},
|
| 21061 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 21062 |
ordinal : function (number) {
|
| 21063 |
var b = number % 10,
|
| 21064 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 21079 |
|
| 21080 |
|
| 21081 |
/***/ },
|
| 21082 |
+
/* 330 */
|
| 21083 |
/***/ function(module, exports, __webpack_require__) {
|
| 21084 |
|
| 21085 |
//! moment.js locale configuration
|
| 21086 |
//! locale : Esperanto [eo]
|
| 21087 |
//! author : Colin Dean : https://github.com/colindean
|
| 21088 |
+
//! author : Mia Nordentoft Imperatori : https://github.com/miestasmia
|
| 21089 |
+
//! comment : miestasmia corrected the translation by colindean
|
| 21090 |
|
| 21091 |
;(function (global, factory) {
|
| 21092 |
+
true ? factory(__webpack_require__(297)) :
|
| 21093 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21094 |
factory(global.moment)
|
| 21095 |
}(this, (function (moment) { 'use strict';
|
| 21098 |
var eo = moment.defineLocale('eo', {
|
| 21099 |
months : 'januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro'.split('_'),
|
| 21100 |
monthsShort : 'jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec'.split('_'),
|
| 21101 |
+
weekdays : 'dimanĉo_lundo_mardo_merkredo_ĵaŭdo_vendredo_sabato'.split('_'),
|
| 21102 |
+
weekdaysShort : 'dim_lun_mard_merk_ĵaŭ_ven_sab'.split('_'),
|
| 21103 |
+
weekdaysMin : 'di_lu_ma_me_ĵa_ve_sa'.split('_'),
|
| 21104 |
longDateFormat : {
|
| 21105 |
LT : 'HH:mm',
|
| 21106 |
LTS : 'HH:mm:ss',
|
| 21107 |
L : 'YYYY-MM-DD',
|
| 21108 |
+
LL : 'D[-a de] MMMM, YYYY',
|
| 21109 |
+
LLL : 'D[-a de] MMMM, YYYY HH:mm',
|
| 21110 |
+
LLLL : 'dddd, [la] D[-a de] MMMM, YYYY HH:mm'
|
| 21111 |
},
|
| 21112 |
meridiemParse: /[ap]\.t\.m/i,
|
| 21113 |
isPM: function (input) {
|
| 21129 |
sameElse : 'L'
|
| 21130 |
},
|
| 21131 |
relativeTime : {
|
| 21132 |
+
future : 'post %s',
|
| 21133 |
past : 'antaŭ %s',
|
| 21134 |
s : 'sekundoj',
|
| 21135 |
m : 'minuto',
|
| 21143 |
y : 'jaro',
|
| 21144 |
yy : '%d jaroj'
|
| 21145 |
},
|
| 21146 |
+
dayOfMonthOrdinalParse: /\d{1,2}a/,
|
| 21147 |
ordinal : '%da',
|
| 21148 |
week : {
|
| 21149 |
dow : 1, // Monday is the first day of the week.
|
| 21157 |
|
| 21158 |
|
| 21159 |
/***/ },
|
| 21160 |
+
/* 331 */
|
| 21161 |
/***/ function(module, exports, __webpack_require__) {
|
| 21162 |
|
| 21163 |
//! moment.js locale configuration
|
| 21165 |
//! author : Julio Napurí : https://github.com/julionc
|
| 21166 |
|
| 21167 |
;(function (global, factory) {
|
| 21168 |
+
true ? factory(__webpack_require__(297)) :
|
| 21169 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21170 |
factory(global.moment)
|
| 21171 |
}(this, (function (moment) { 'use strict';
|
| 21177 |
var es = moment.defineLocale('es', {
|
| 21178 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 21179 |
monthsShort : function (m, format) {
|
| 21180 |
+
if (!m) {
|
| 21181 |
+
return monthsShortDot;
|
| 21182 |
+
} else if (/-MMM-/.test(format)) {
|
| 21183 |
return monthsShort[m.month()];
|
| 21184 |
} else {
|
| 21185 |
return monthsShortDot[m.month()];
|
| 21231 |
y : 'un año',
|
| 21232 |
yy : '%d años'
|
| 21233 |
},
|
| 21234 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 21235 |
ordinal : '%dº',
|
| 21236 |
week : {
|
| 21237 |
dow : 1, // Monday is the first day of the week.
|
| 21245 |
|
| 21246 |
|
| 21247 |
/***/ },
|
| 21248 |
+
/* 332 */
|
| 21249 |
/***/ function(module, exports, __webpack_require__) {
|
| 21250 |
|
| 21251 |
//! moment.js locale configuration
|
| 21252 |
//! locale : Spanish (Dominican Republic) [es-do]
|
| 21253 |
|
| 21254 |
;(function (global, factory) {
|
| 21255 |
+
true ? factory(__webpack_require__(297)) :
|
| 21256 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21257 |
factory(global.moment)
|
| 21258 |
}(this, (function (moment) { 'use strict';
|
| 21264 |
var esDo = moment.defineLocale('es-do', {
|
| 21265 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 21266 |
monthsShort : function (m, format) {
|
| 21267 |
+
if (!m) {
|
| 21268 |
+
return monthsShortDot;
|
| 21269 |
+
} else if (/-MMM-/.test(format)) {
|
| 21270 |
return monthsShort[m.month()];
|
| 21271 |
} else {
|
| 21272 |
return monthsShortDot[m.month()];
|
| 21318 |
y : 'un año',
|
| 21319 |
yy : '%d años'
|
| 21320 |
},
|
| 21321 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 21322 |
ordinal : '%dº',
|
| 21323 |
week : {
|
| 21324 |
dow : 1, // Monday is the first day of the week.
|
| 21332 |
|
| 21333 |
|
| 21334 |
/***/ },
|
| 21335 |
+
/* 333 */
|
| 21336 |
/***/ function(module, exports, __webpack_require__) {
|
| 21337 |
|
| 21338 |
//! moment.js locale configuration
|
| 21341 |
//! improvements : Illimar Tambek : https://github.com/ragulka
|
| 21342 |
|
| 21343 |
;(function (global, factory) {
|
| 21344 |
+
true ? factory(__webpack_require__(297)) :
|
| 21345 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21346 |
factory(global.moment)
|
| 21347 |
}(this, (function (moment) { 'use strict';
|
| 21403 |
y : processRelativeTime,
|
| 21404 |
yy : processRelativeTime
|
| 21405 |
},
|
| 21406 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 21407 |
ordinal : '%d.',
|
| 21408 |
week : {
|
| 21409 |
dow : 1, // Monday is the first day of the week.
|
| 21417 |
|
| 21418 |
|
| 21419 |
/***/ },
|
| 21420 |
+
/* 334 */
|
| 21421 |
/***/ function(module, exports, __webpack_require__) {
|
| 21422 |
|
| 21423 |
//! moment.js locale configuration
|
| 21425 |
//! author : Eneko Illarramendi : https://github.com/eillarra
|
| 21426 |
|
| 21427 |
;(function (global, factory) {
|
| 21428 |
+
true ? factory(__webpack_require__(297)) :
|
| 21429 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21430 |
factory(global.moment)
|
| 21431 |
}(this, (function (moment) { 'use strict';
|
| 21474 |
y : 'urte bat',
|
| 21475 |
yy : '%d urte'
|
| 21476 |
},
|
| 21477 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 21478 |
ordinal : '%d.',
|
| 21479 |
week : {
|
| 21480 |
dow : 1, // Monday is the first day of the week.
|
| 21488 |
|
| 21489 |
|
| 21490 |
/***/ },
|
| 21491 |
+
/* 335 */
|
| 21492 |
/***/ function(module, exports, __webpack_require__) {
|
| 21493 |
|
| 21494 |
//! moment.js locale configuration
|
| 21496 |
//! author : Ebrahim Byagowi : https://github.com/ebraminio
|
| 21497 |
|
| 21498 |
;(function (global, factory) {
|
| 21499 |
+
true ? factory(__webpack_require__(297)) :
|
| 21500 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21501 |
factory(global.moment)
|
| 21502 |
}(this, (function (moment) { 'use strict';
|
| 21564 |
relativeTime : {
|
| 21565 |
future : 'در %s',
|
| 21566 |
past : '%s پیش',
|
| 21567 |
+
s : 'چند ثانیه',
|
| 21568 |
m : 'یک دقیقه',
|
| 21569 |
mm : '%d دقیقه',
|
| 21570 |
h : 'یک ساعت',
|
| 21586 |
return symbolMap[match];
|
| 21587 |
}).replace(/,/g, '،');
|
| 21588 |
},
|
| 21589 |
+
dayOfMonthOrdinalParse: /\d{1,2}م/,
|
| 21590 |
ordinal : '%dم',
|
| 21591 |
week : {
|
| 21592 |
dow : 6, // Saturday is the first day of the week.
|
| 21600 |
|
| 21601 |
|
| 21602 |
/***/ },
|
| 21603 |
+
/* 336 */
|
| 21604 |
/***/ function(module, exports, __webpack_require__) {
|
| 21605 |
|
| 21606 |
//! moment.js locale configuration
|
| 21608 |
//! author : Tarmo Aidantausta : https://github.com/bleadof
|
| 21609 |
|
| 21610 |
;(function (global, factory) {
|
| 21611 |
+
true ? factory(__webpack_require__(297)) :
|
| 21612 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21613 |
factory(global.moment)
|
| 21614 |
}(this, (function (moment) { 'use strict';
|
| 21698 |
y : translate,
|
| 21699 |
yy : translate
|
| 21700 |
},
|
| 21701 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 21702 |
ordinal : '%d.',
|
| 21703 |
week : {
|
| 21704 |
dow : 1, // Monday is the first day of the week.
|
| 21712 |
|
| 21713 |
|
| 21714 |
/***/ },
|
| 21715 |
+
/* 337 */
|
| 21716 |
/***/ function(module, exports, __webpack_require__) {
|
| 21717 |
|
| 21718 |
//! moment.js locale configuration
|
| 21720 |
//! author : Ragnar Johannesen : https://github.com/ragnar123
|
| 21721 |
|
| 21722 |
;(function (global, factory) {
|
| 21723 |
+
true ? factory(__webpack_require__(297)) :
|
| 21724 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21725 |
factory(global.moment)
|
| 21726 |
}(this, (function (moment) { 'use strict';
|
| 21763 |
y : 'eitt ár',
|
| 21764 |
yy : '%d ár'
|
| 21765 |
},
|
| 21766 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 21767 |
ordinal : '%d.',
|
| 21768 |
week : {
|
| 21769 |
dow : 1, // Monday is the first day of the week.
|
| 21777 |
|
| 21778 |
|
| 21779 |
/***/ },
|
| 21780 |
+
/* 338 */
|
| 21781 |
/***/ function(module, exports, __webpack_require__) {
|
| 21782 |
|
| 21783 |
//! moment.js locale configuration
|
| 21785 |
//! author : John Fischer : https://github.com/jfroffice
|
| 21786 |
|
| 21787 |
;(function (global, factory) {
|
| 21788 |
+
true ? factory(__webpack_require__(297)) :
|
| 21789 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21790 |
factory(global.moment)
|
| 21791 |
}(this, (function (moment) { 'use strict';
|
| 21808 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21809 |
},
|
| 21810 |
calendar : {
|
| 21811 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 21812 |
+
nextDay : '[Demain à] LT',
|
| 21813 |
+
nextWeek : 'dddd [à] LT',
|
| 21814 |
+
lastDay : '[Hier à] LT',
|
| 21815 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 21816 |
+
sameElse : 'L'
|
| 21817 |
},
|
| 21818 |
relativeTime : {
|
| 21819 |
future : 'dans %s',
|
| 21830 |
y : 'un an',
|
| 21831 |
yy : '%d ans'
|
| 21832 |
},
|
| 21833 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|)/,
|
| 21834 |
+
ordinal : function (number, period) {
|
| 21835 |
+
switch (period) {
|
| 21836 |
+
// TODO: Return 'e' when day of month > 1. Move this case inside
|
| 21837 |
+
// block for masculine words below.
|
| 21838 |
+
// See https://github.com/moment/moment/issues/3375
|
| 21839 |
+
case 'D':
|
| 21840 |
+
return number + (number === 1 ? 'er' : '');
|
| 21841 |
+
|
| 21842 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 21843 |
+
default:
|
| 21844 |
+
case 'M':
|
| 21845 |
+
case 'Q':
|
| 21846 |
+
case 'DDD':
|
| 21847 |
+
case 'd':
|
| 21848 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 21849 |
+
|
| 21850 |
+
// Words with feminine grammatical gender: semaine
|
| 21851 |
+
case 'w':
|
| 21852 |
+
case 'W':
|
| 21853 |
+
return number + (number === 1 ? 're' : 'e');
|
| 21854 |
+
}
|
| 21855 |
},
|
| 21856 |
week : {
|
| 21857 |
dow : 1, // Monday is the first day of the week.
|
| 21865 |
|
| 21866 |
|
| 21867 |
/***/ },
|
| 21868 |
+
/* 339 */
|
| 21869 |
/***/ function(module, exports, __webpack_require__) {
|
| 21870 |
|
| 21871 |
//! moment.js locale configuration
|
| 21873 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 21874 |
|
| 21875 |
;(function (global, factory) {
|
| 21876 |
+
true ? factory(__webpack_require__(297)) :
|
| 21877 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21878 |
factory(global.moment)
|
| 21879 |
}(this, (function (moment) { 'use strict';
|
| 21896 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21897 |
},
|
| 21898 |
calendar : {
|
| 21899 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 21900 |
+
nextDay : '[Demain à] LT',
|
| 21901 |
+
nextWeek : 'dddd [à] LT',
|
| 21902 |
+
lastDay : '[Hier à] LT',
|
| 21903 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 21904 |
+
sameElse : 'L'
|
| 21905 |
},
|
| 21906 |
relativeTime : {
|
| 21907 |
future : 'dans %s',
|
| 21918 |
y : 'un an',
|
| 21919 |
yy : '%d ans'
|
| 21920 |
},
|
| 21921 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|e)/,
|
| 21922 |
+
ordinal : function (number, period) {
|
| 21923 |
+
switch (period) {
|
| 21924 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 21925 |
+
default:
|
| 21926 |
+
case 'M':
|
| 21927 |
+
case 'Q':
|
| 21928 |
+
case 'D':
|
| 21929 |
+
case 'DDD':
|
| 21930 |
+
case 'd':
|
| 21931 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 21932 |
+
|
| 21933 |
+
// Words with feminine grammatical gender: semaine
|
| 21934 |
+
case 'w':
|
| 21935 |
+
case 'W':
|
| 21936 |
+
return number + (number === 1 ? 're' : 'e');
|
| 21937 |
+
}
|
| 21938 |
}
|
| 21939 |
});
|
| 21940 |
|
| 21944 |
|
| 21945 |
|
| 21946 |
/***/ },
|
| 21947 |
+
/* 340 */
|
| 21948 |
/***/ function(module, exports, __webpack_require__) {
|
| 21949 |
|
| 21950 |
//! moment.js locale configuration
|
| 21952 |
//! author : Gaspard Bucher : https://github.com/gaspard
|
| 21953 |
|
| 21954 |
;(function (global, factory) {
|
| 21955 |
+
true ? factory(__webpack_require__(297)) :
|
| 21956 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 21957 |
factory(global.moment)
|
| 21958 |
}(this, (function (moment) { 'use strict';
|
| 21975 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 21976 |
},
|
| 21977 |
calendar : {
|
| 21978 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 21979 |
+
nextDay : '[Demain à] LT',
|
| 21980 |
+
nextWeek : 'dddd [à] LT',
|
| 21981 |
+
lastDay : '[Hier à] LT',
|
| 21982 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 21983 |
+
sameElse : 'L'
|
| 21984 |
},
|
| 21985 |
relativeTime : {
|
| 21986 |
future : 'dans %s',
|
| 21997 |
y : 'un an',
|
| 21998 |
yy : '%d ans'
|
| 21999 |
},
|
| 22000 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|e)/,
|
| 22001 |
+
ordinal : function (number, period) {
|
| 22002 |
+
switch (period) {
|
| 22003 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 22004 |
+
default:
|
| 22005 |
+
case 'M':
|
| 22006 |
+
case 'Q':
|
| 22007 |
+
case 'D':
|
| 22008 |
+
case 'DDD':
|
| 22009 |
+
case 'd':
|
| 22010 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 22011 |
+
|
| 22012 |
+
// Words with feminine grammatical gender: semaine
|
| 22013 |
+
case 'w':
|
| 22014 |
+
case 'W':
|
| 22015 |
+
return number + (number === 1 ? 're' : 'e');
|
| 22016 |
+
}
|
| 22017 |
},
|
| 22018 |
week : {
|
| 22019 |
dow : 1, // Monday is the first day of the week.
|
| 22027 |
|
| 22028 |
|
| 22029 |
/***/ },
|
| 22030 |
+
/* 341 */
|
| 22031 |
/***/ function(module, exports, __webpack_require__) {
|
| 22032 |
|
| 22033 |
//! moment.js locale configuration
|
| 22035 |
//! author : Robin van der Vliet : https://github.com/robin0van0der0v
|
| 22036 |
|
| 22037 |
;(function (global, factory) {
|
| 22038 |
+
true ? factory(__webpack_require__(297)) :
|
| 22039 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22040 |
factory(global.moment)
|
| 22041 |
}(this, (function (moment) { 'use strict';
|
| 22047 |
var fy = moment.defineLocale('fy', {
|
| 22048 |
months : 'jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber'.split('_'),
|
| 22049 |
monthsShort : function (m, format) {
|
| 22050 |
+
if (!m) {
|
| 22051 |
+
return monthsShortWithDots;
|
| 22052 |
+
} else if (/-MMM-/.test(format)) {
|
| 22053 |
return monthsShortWithoutDots[m.month()];
|
| 22054 |
} else {
|
| 22055 |
return monthsShortWithDots[m.month()];
|
| 22091 |
y : 'ien jier',
|
| 22092 |
yy : '%d jierren'
|
| 22093 |
},
|
| 22094 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 22095 |
ordinal : function (number) {
|
| 22096 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 22097 |
},
|
| 22107 |
|
| 22108 |
|
| 22109 |
/***/ },
|
| 22110 |
+
/* 342 */
|
| 22111 |
/***/ function(module, exports, __webpack_require__) {
|
| 22112 |
|
| 22113 |
//! moment.js locale configuration
|
| 22115 |
//! author : Jon Ashdown : https://github.com/jonashdown
|
| 22116 |
|
| 22117 |
;(function (global, factory) {
|
| 22118 |
+
true ? factory(__webpack_require__(297)) :
|
| 22119 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22120 |
factory(global.moment)
|
| 22121 |
}(this, (function (moment) { 'use strict';
|
| 22171 |
y : 'bliadhna',
|
| 22172 |
yy : '%d bliadhna'
|
| 22173 |
},
|
| 22174 |
+
dayOfMonthOrdinalParse : /\d{1,2}(d|na|mh)/,
|
| 22175 |
ordinal : function (number) {
|
| 22176 |
var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';
|
| 22177 |
return number + output;
|
| 22188 |
|
| 22189 |
|
| 22190 |
/***/ },
|
| 22191 |
+
/* 343 */
|
| 22192 |
/***/ function(module, exports, __webpack_require__) {
|
| 22193 |
|
| 22194 |
//! moment.js locale configuration
|
| 22196 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 22197 |
|
| 22198 |
;(function (global, factory) {
|
| 22199 |
+
true ? factory(__webpack_require__(297)) :
|
| 22200 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22201 |
factory(global.moment)
|
| 22202 |
}(this, (function (moment) { 'use strict';
|
| 22256 |
y : 'un ano',
|
| 22257 |
yy : '%d anos'
|
| 22258 |
},
|
| 22259 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 22260 |
ordinal : '%dº',
|
| 22261 |
week : {
|
| 22262 |
dow : 1, // Monday is the first day of the week.
|
| 22270 |
|
| 22271 |
|
| 22272 |
/***/ },
|
| 22273 |
+
/* 344 */
|
| 22274 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 22275 |
+
|
| 22276 |
+
//! moment.js locale configuration
|
| 22277 |
+
//! locale : Konkani Latin script [gom-latn]
|
| 22278 |
+
//! author : The Discoverer : https://github.com/WikiDiscoverer
|
| 22279 |
+
|
| 22280 |
+
;(function (global, factory) {
|
| 22281 |
+
true ? factory(__webpack_require__(297)) :
|
| 22282 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22283 |
+
factory(global.moment)
|
| 22284 |
+
}(this, (function (moment) { 'use strict';
|
| 22285 |
+
|
| 22286 |
+
|
| 22287 |
+
function processRelativeTime(number, withoutSuffix, key, isFuture) {
|
| 22288 |
+
var format = {
|
| 22289 |
+
's': ['thodde secondanim', 'thodde second'],
|
| 22290 |
+
'm': ['eka mintan', 'ek minute'],
|
| 22291 |
+
'mm': [number + ' mintanim', number + ' mintam'],
|
| 22292 |
+
'h': ['eka horan', 'ek hor'],
|
| 22293 |
+
'hh': [number + ' horanim', number + ' hor'],
|
| 22294 |
+
'd': ['eka disan', 'ek dis'],
|
| 22295 |
+
'dd': [number + ' disanim', number + ' dis'],
|
| 22296 |
+
'M': ['eka mhoinean', 'ek mhoino'],
|
| 22297 |
+
'MM': [number + ' mhoineanim', number + ' mhoine'],
|
| 22298 |
+
'y': ['eka vorsan', 'ek voros'],
|
| 22299 |
+
'yy': [number + ' vorsanim', number + ' vorsam']
|
| 22300 |
+
};
|
| 22301 |
+
return withoutSuffix ? format[key][0] : format[key][1];
|
| 22302 |
+
}
|
| 22303 |
+
|
| 22304 |
+
var gomLatn = moment.defineLocale('gom-latn', {
|
| 22305 |
+
months : 'Janer_Febrer_Mars_Abril_Mai_Jun_Julai_Agost_Setembr_Otubr_Novembr_Dezembr'.split('_'),
|
| 22306 |
+
monthsShort : 'Jan._Feb._Mars_Abr._Mai_Jun_Jul._Ago._Set._Otu._Nov._Dez.'.split('_'),
|
| 22307 |
+
monthsParseExact : true,
|
| 22308 |
+
weekdays : 'Aitar_Somar_Mongllar_Budvar_Brestar_Sukrar_Son\'var'.split('_'),
|
| 22309 |
+
weekdaysShort : 'Ait._Som._Mon._Bud._Bre._Suk._Son.'.split('_'),
|
| 22310 |
+
weekdaysMin : 'Ai_Sm_Mo_Bu_Br_Su_Sn'.split('_'),
|
| 22311 |
+
weekdaysParseExact : true,
|
| 22312 |
+
longDateFormat : {
|
| 22313 |
+
LT : 'A h:mm [vazta]',
|
| 22314 |
+
LTS : 'A h:mm:ss [vazta]',
|
| 22315 |
+
L : 'DD-MM-YYYY',
|
| 22316 |
+
LL : 'D MMMM YYYY',
|
| 22317 |
+
LLL : 'D MMMM YYYY A h:mm [vazta]',
|
| 22318 |
+
LLLL : 'dddd, MMMM[achea] Do, YYYY, A h:mm [vazta]',
|
| 22319 |
+
llll: 'ddd, D MMM YYYY, A h:mm [vazta]'
|
| 22320 |
+
},
|
| 22321 |
+
calendar : {
|
| 22322 |
+
sameDay: '[Aiz] LT',
|
| 22323 |
+
nextDay: '[Faleam] LT',
|
| 22324 |
+
nextWeek: '[Ieta to] dddd[,] LT',
|
| 22325 |
+
lastDay: '[Kal] LT',
|
| 22326 |
+
lastWeek: '[Fatlo] dddd[,] LT',
|
| 22327 |
+
sameElse: 'L'
|
| 22328 |
+
},
|
| 22329 |
+
relativeTime : {
|
| 22330 |
+
future : '%s',
|
| 22331 |
+
past : '%s adim',
|
| 22332 |
+
s : processRelativeTime,
|
| 22333 |
+
m : processRelativeTime,
|
| 22334 |
+
mm : processRelativeTime,
|
| 22335 |
+
h : processRelativeTime,
|
| 22336 |
+
hh : processRelativeTime,
|
| 22337 |
+
d : processRelativeTime,
|
| 22338 |
+
dd : processRelativeTime,
|
| 22339 |
+
M : processRelativeTime,
|
| 22340 |
+
MM : processRelativeTime,
|
| 22341 |
+
y : processRelativeTime,
|
| 22342 |
+
yy : processRelativeTime
|
| 22343 |
+
},
|
| 22344 |
+
dayOfMonthOrdinalParse : /\d{1,2}(er)/,
|
| 22345 |
+
ordinal : function (number, period) {
|
| 22346 |
+
switch (period) {
|
| 22347 |
+
// the ordinal 'er' only applies to day of the month
|
| 22348 |
+
case 'D':
|
| 22349 |
+
return number + 'er';
|
| 22350 |
+
default:
|
| 22351 |
+
case 'M':
|
| 22352 |
+
case 'Q':
|
| 22353 |
+
case 'DDD':
|
| 22354 |
+
case 'd':
|
| 22355 |
+
case 'w':
|
| 22356 |
+
case 'W':
|
| 22357 |
+
return number;
|
| 22358 |
+
}
|
| 22359 |
+
},
|
| 22360 |
+
week : {
|
| 22361 |
+
dow : 1, // Monday is the first day of the week.
|
| 22362 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 22363 |
+
},
|
| 22364 |
+
meridiemParse: /rati|sokalli|donparam|sanje/,
|
| 22365 |
+
meridiemHour : function (hour, meridiem) {
|
| 22366 |
+
if (hour === 12) {
|
| 22367 |
+
hour = 0;
|
| 22368 |
+
}
|
| 22369 |
+
if (meridiem === 'rati') {
|
| 22370 |
+
return hour < 4 ? hour : hour + 12;
|
| 22371 |
+
} else if (meridiem === 'sokalli') {
|
| 22372 |
+
return hour;
|
| 22373 |
+
} else if (meridiem === 'donparam') {
|
| 22374 |
+
return hour > 12 ? hour : hour + 12;
|
| 22375 |
+
} else if (meridiem === 'sanje') {
|
| 22376 |
+
return hour + 12;
|
| 22377 |
+
}
|
| 22378 |
+
},
|
| 22379 |
+
meridiem : function (hour, minute, isLower) {
|
| 22380 |
+
if (hour < 4) {
|
| 22381 |
+
return 'rati';
|
| 22382 |
+
} else if (hour < 12) {
|
| 22383 |
+
return 'sokalli';
|
| 22384 |
+
} else if (hour < 16) {
|
| 22385 |
+
return 'donparam';
|
| 22386 |
+
} else if (hour < 20) {
|
| 22387 |
+
return 'sanje';
|
| 22388 |
+
} else {
|
| 22389 |
+
return 'rati';
|
| 22390 |
+
}
|
| 22391 |
+
}
|
| 22392 |
+
});
|
| 22393 |
+
|
| 22394 |
+
return gomLatn;
|
| 22395 |
+
|
| 22396 |
+
})));
|
| 22397 |
+
|
| 22398 |
+
|
| 22399 |
+
/***/ },
|
| 22400 |
+
/* 345 */
|
| 22401 |
/***/ function(module, exports, __webpack_require__) {
|
| 22402 |
|
| 22403 |
//! moment.js locale configuration
|
| 22407 |
//! author : Tal Ater : https://github.com/TalAter
|
| 22408 |
|
| 22409 |
;(function (global, factory) {
|
| 22410 |
+
true ? factory(__webpack_require__(297)) :
|
| 22411 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22412 |
factory(global.moment)
|
| 22413 |
}(this, (function (moment) { 'use strict';
|
| 22501 |
|
| 22502 |
|
| 22503 |
/***/ },
|
| 22504 |
+
/* 346 */
|
| 22505 |
/***/ function(module, exports, __webpack_require__) {
|
| 22506 |
|
| 22507 |
//! moment.js locale configuration
|
| 22509 |
//! author : Mayank Singhal : https://github.com/mayanksinghal
|
| 22510 |
|
| 22511 |
;(function (global, factory) {
|
| 22512 |
+
true ? factory(__webpack_require__(297)) :
|
| 22513 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22514 |
factory(global.moment)
|
| 22515 |
}(this, (function (moment) { 'use strict';
|
| 22630 |
|
| 22631 |
|
| 22632 |
/***/ },
|
| 22633 |
+
/* 347 */
|
| 22634 |
/***/ function(module, exports, __webpack_require__) {
|
| 22635 |
|
| 22636 |
//! moment.js locale configuration
|
| 22638 |
//! author : Bojan Marković : https://github.com/bmarkovic
|
| 22639 |
|
| 22640 |
;(function (global, factory) {
|
| 22641 |
+
true ? factory(__webpack_require__(297)) :
|
| 22642 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22643 |
factory(global.moment)
|
| 22644 |
}(this, (function (moment) { 'use strict';
|
| 22766 |
y : 'godinu',
|
| 22767 |
yy : translate
|
| 22768 |
},
|
| 22769 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 22770 |
ordinal : '%d.',
|
| 22771 |
week : {
|
| 22772 |
dow : 1, // Monday is the first day of the week.
|
| 22780 |
|
| 22781 |
|
| 22782 |
/***/ },
|
| 22783 |
+
/* 348 */
|
| 22784 |
/***/ function(module, exports, __webpack_require__) {
|
| 22785 |
|
| 22786 |
//! moment.js locale configuration
|
| 22788 |
//! author : Adam Brunner : https://github.com/adambrunner
|
| 22789 |
|
| 22790 |
;(function (global, factory) {
|
| 22791 |
+
true ? factory(__webpack_require__(297)) :
|
| 22792 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22793 |
factory(global.moment)
|
| 22794 |
}(this, (function (moment) { 'use strict';
|
| 22880 |
y : translate,
|
| 22881 |
yy : translate
|
| 22882 |
},
|
| 22883 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 22884 |
ordinal : '%d.',
|
| 22885 |
week : {
|
| 22886 |
dow : 1, // Monday is the first day of the week.
|
| 22894 |
|
| 22895 |
|
| 22896 |
/***/ },
|
| 22897 |
+
/* 349 */
|
| 22898 |
/***/ function(module, exports, __webpack_require__) {
|
| 22899 |
|
| 22900 |
//! moment.js locale configuration
|
| 22902 |
//! author : Armendarabyan : https://github.com/armendarabyan
|
| 22903 |
|
| 22904 |
;(function (global, factory) {
|
| 22905 |
+
true ? factory(__webpack_require__(297)) :
|
| 22906 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 22907 |
factory(global.moment)
|
| 22908 |
}(this, (function (moment) { 'use strict';
|
| 22967 |
return 'երեկոյան';
|
| 22968 |
}
|
| 22969 |
},
|
| 22970 |
+
dayOfMonthOrdinalParse: /\d{1,2}|\d{1,2}-(ին|րդ)/,
|
| 22971 |
ordinal: function (number, period) {
|
| 22972 |
switch (period) {
|
| 22973 |
case 'DDD':
|
| 22994 |
|
| 22995 |
|
| 22996 |
/***/ },
|
| 22997 |
+
/* 350 */
|
| 22998 |
/***/ function(module, exports, __webpack_require__) {
|
| 22999 |
|
| 23000 |
//! moment.js locale configuration
|
| 23003 |
//! reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan
|
| 23004 |
|
| 23005 |
;(function (global, factory) {
|
| 23006 |
+
true ? factory(__webpack_require__(297)) :
|
| 23007 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23008 |
factory(global.moment)
|
| 23009 |
}(this, (function (moment) { 'use strict';
|
| 23082 |
|
| 23083 |
|
| 23084 |
/***/ },
|
| 23085 |
+
/* 351 */
|
| 23086 |
/***/ function(module, exports, __webpack_require__) {
|
| 23087 |
|
| 23088 |
//! moment.js locale configuration
|
| 23090 |
//! author : Hinrik Örn Sigurðsson : https://github.com/hinrik
|
| 23091 |
|
| 23092 |
;(function (global, factory) {
|
| 23093 |
+
true ? factory(__webpack_require__(297)) :
|
| 23094 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23095 |
factory(global.moment)
|
| 23096 |
}(this, (function (moment) { 'use strict';
|
| 23200 |
y : translate,
|
| 23201 |
yy : translate
|
| 23202 |
},
|
| 23203 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 23204 |
ordinal : '%d.',
|
| 23205 |
week : {
|
| 23206 |
dow : 1, // Monday is the first day of the week.
|
| 23214 |
|
| 23215 |
|
| 23216 |
/***/ },
|
| 23217 |
+
/* 352 */
|
| 23218 |
/***/ function(module, exports, __webpack_require__) {
|
| 23219 |
|
| 23220 |
//! moment.js locale configuration
|
| 23223 |
//! author: Mattia Larentis: https://github.com/nostalgiaz
|
| 23224 |
|
| 23225 |
;(function (global, factory) {
|
| 23226 |
+
true ? factory(__webpack_require__(297)) :
|
| 23227 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23228 |
factory(global.moment)
|
| 23229 |
}(this, (function (moment) { 'use strict';
|
| 23232 |
var it = moment.defineLocale('it', {
|
| 23233 |
months : 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split('_'),
|
| 23234 |
monthsShort : 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),
|
| 23235 |
+
weekdays : 'domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato'.split('_'),
|
| 23236 |
+
weekdaysShort : 'dom_lun_mar_mer_gio_ven_sab'.split('_'),
|
| 23237 |
+
weekdaysMin : 'do_lu_ma_me_gi_ve_sa'.split('_'),
|
| 23238 |
longDateFormat : {
|
| 23239 |
LT : 'HH:mm',
|
| 23240 |
LTS : 'HH:mm:ss',
|
| 23275 |
y : 'un anno',
|
| 23276 |
yy : '%d anni'
|
| 23277 |
},
|
| 23278 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 23279 |
ordinal: '%dº',
|
| 23280 |
week : {
|
| 23281 |
dow : 1, // Monday is the first day of the week.
|
| 23289 |
|
| 23290 |
|
| 23291 |
/***/ },
|
| 23292 |
+
/* 353 */
|
| 23293 |
/***/ function(module, exports, __webpack_require__) {
|
| 23294 |
|
| 23295 |
//! moment.js locale configuration
|
| 23297 |
//! author : LI Long : https://github.com/baryon
|
| 23298 |
|
| 23299 |
;(function (global, factory) {
|
| 23300 |
+
true ? factory(__webpack_require__(297)) :
|
| 23301 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23302 |
factory(global.moment)
|
| 23303 |
}(this, (function (moment) { 'use strict';
|
| 23310 |
weekdaysShort : '日_月_火_水_木_金_土'.split('_'),
|
| 23311 |
weekdaysMin : '日_月_火_水_木_金_土'.split('_'),
|
| 23312 |
longDateFormat : {
|
| 23313 |
+
LT : 'HH:mm',
|
| 23314 |
+
LTS : 'HH:mm:ss',
|
| 23315 |
L : 'YYYY/MM/DD',
|
| 23316 |
LL : 'YYYY年M月D日',
|
| 23317 |
+
LLL : 'YYYY年M月D日 HH:mm',
|
| 23318 |
+
LLLL : 'YYYY年M月D日 HH:mm dddd',
|
| 23319 |
+
l : 'YYYY/MM/DD',
|
| 23320 |
+
ll : 'YYYY年M月D日',
|
| 23321 |
+
lll : 'YYYY年M月D日 HH:mm',
|
| 23322 |
+
llll : 'YYYY年M月D日 HH:mm dddd'
|
| 23323 |
},
|
| 23324 |
meridiemParse: /午前|午後/i,
|
| 23325 |
isPM : function (input) {
|
| 23340 |
lastWeek : '[前週]dddd LT',
|
| 23341 |
sameElse : 'L'
|
| 23342 |
},
|
| 23343 |
+
dayOfMonthOrdinalParse : /\d{1,2}日/,
|
| 23344 |
ordinal : function (number, period) {
|
| 23345 |
switch (period) {
|
| 23346 |
case 'd':
|
| 23374 |
|
| 23375 |
|
| 23376 |
/***/ },
|
| 23377 |
+
/* 354 */
|
| 23378 |
/***/ function(module, exports, __webpack_require__) {
|
| 23379 |
|
| 23380 |
//! moment.js locale configuration
|
| 23383 |
//! reference: http://jv.wikipedia.org/wiki/Basa_Jawa
|
| 23384 |
|
| 23385 |
;(function (global, factory) {
|
| 23386 |
+
true ? factory(__webpack_require__(297)) :
|
| 23387 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23388 |
factory(global.moment)
|
| 23389 |
}(this, (function (moment) { 'use strict';
|
| 23462 |
|
| 23463 |
|
| 23464 |
/***/ },
|
| 23465 |
+
/* 355 */
|
| 23466 |
/***/ function(module, exports, __webpack_require__) {
|
| 23467 |
|
| 23468 |
//! moment.js locale configuration
|
| 23470 |
//! author : Irakli Janiashvili : https://github.com/irakli-janiashvili
|
| 23471 |
|
| 23472 |
;(function (global, factory) {
|
| 23473 |
+
true ? factory(__webpack_require__(297)) :
|
| 23474 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23475 |
factory(global.moment)
|
| 23476 |
}(this, (function (moment) { 'use strict';
|
| 23513 |
},
|
| 23514 |
past : function (s) {
|
| 23515 |
if ((/(წამი|წუთი|საათი|დღე|თვე)/).test(s)) {
|
| 23516 |
+
return s.replace(/(ი|ე)$/, 'ის უკან');
|
| 23517 |
}
|
| 23518 |
if ((/წელი/).test(s)) {
|
| 23519 |
+
return s.replace(/წელი$/, 'წლის უკან');
|
| 23520 |
}
|
| 23521 |
},
|
| 23522 |
s : 'რამდენიმე წამი',
|
| 23531 |
y : 'წელი',
|
| 23532 |
yy : '%d წელი'
|
| 23533 |
},
|
| 23534 |
+
dayOfMonthOrdinalParse: /0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,
|
| 23535 |
ordinal : function (number) {
|
| 23536 |
if (number === 0) {
|
| 23537 |
return number;
|
| 23556 |
|
| 23557 |
|
| 23558 |
/***/ },
|
| 23559 |
+
/* 356 */
|
| 23560 |
/***/ function(module, exports, __webpack_require__) {
|
| 23561 |
|
| 23562 |
//! moment.js locale configuration
|
| 23564 |
//! authors : Nurlan Rakhimzhanov : https://github.com/nurlan
|
| 23565 |
|
| 23566 |
;(function (global, factory) {
|
| 23567 |
+
true ? factory(__webpack_require__(297)) :
|
| 23568 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23569 |
factory(global.moment)
|
| 23570 |
}(this, (function (moment) { 'use strict';
|
| 23630 |
y : 'бір жыл',
|
| 23631 |
yy : '%d жыл'
|
| 23632 |
},
|
| 23633 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ші|шы)/,
|
| 23634 |
ordinal : function (number) {
|
| 23635 |
var a = number % 10,
|
| 23636 |
b = number >= 100 ? 100 : null;
|
| 23648 |
|
| 23649 |
|
| 23650 |
/***/ },
|
| 23651 |
+
/* 357 */
|
| 23652 |
/***/ function(module, exports, __webpack_require__) {
|
| 23653 |
|
| 23654 |
//! moment.js locale configuration
|
| 23656 |
//! author : Kruy Vanna : https://github.com/kruyvanna
|
| 23657 |
|
| 23658 |
;(function (global, factory) {
|
| 23659 |
+
true ? factory(__webpack_require__(297)) :
|
| 23660 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23661 |
factory(global.moment)
|
| 23662 |
}(this, (function (moment) { 'use strict';
|
| 23711 |
|
| 23712 |
|
| 23713 |
/***/ },
|
| 23714 |
+
/* 358 */
|
| 23715 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 23716 |
+
|
| 23717 |
+
//! moment.js locale configuration
|
| 23718 |
+
//! locale : Kannada [kn]
|
| 23719 |
+
//! author : Rajeev Naik : https://github.com/rajeevnaikte
|
| 23720 |
+
|
| 23721 |
+
;(function (global, factory) {
|
| 23722 |
+
true ? factory(__webpack_require__(297)) :
|
| 23723 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23724 |
+
factory(global.moment)
|
| 23725 |
+
}(this, (function (moment) { 'use strict';
|
| 23726 |
+
|
| 23727 |
+
|
| 23728 |
+
var symbolMap = {
|
| 23729 |
+
'1': '೧',
|
| 23730 |
+
'2': '೨',
|
| 23731 |
+
'3': '೩',
|
| 23732 |
+
'4': '೪',
|
| 23733 |
+
'5': '೫',
|
| 23734 |
+
'6': '೬',
|
| 23735 |
+
'7': '೭',
|
| 23736 |
+
'8': '೮',
|
| 23737 |
+
'9': '೯',
|
| 23738 |
+
'0': '೦'
|
| 23739 |
+
};
|
| 23740 |
+
var numberMap = {
|
| 23741 |
+
'೧': '1',
|
| 23742 |
+
'೨': '2',
|
| 23743 |
+
'೩': '3',
|
| 23744 |
+
'೪': '4',
|
| 23745 |
+
'೫': '5',
|
| 23746 |
+
'೬': '6',
|
| 23747 |
+
'೭': '7',
|
| 23748 |
+
'೮': '8',
|
| 23749 |
+
'೯': '9',
|
| 23750 |
+
'೦': '0'
|
| 23751 |
+
};
|
| 23752 |
+
|
| 23753 |
+
var kn = moment.defineLocale('kn', {
|
| 23754 |
+
months : 'ಜನವರಿ_ಫೆಬ್ರವರಿ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬರ್_ಅಕ್ಟೋಬರ್_ನವೆಂಬರ್_ಡಿಸೆಂಬರ್'.split('_'),
|
| 23755 |
+
monthsShort : 'ಜನ_ಫೆಬ್ರ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬ_ಅಕ್ಟೋಬ_ನವೆಂಬ_ಡಿಸೆಂಬ'.split('_'),
|
| 23756 |
+
monthsParseExact: true,
|
| 23757 |
+
weekdays : 'ಭಾನುವಾರ_ಸೋಮವಾರ_ಮಂಗಳವಾರ_ಬುಧವಾರ_ಗುರುವಾರ_ಶುಕ್ರವಾರ_ಶನಿವಾರ'.split('_'),
|
| 23758 |
+
weekdaysShort : 'ಭಾನು_ಸೋಮ_ಮಂಗಳ_ಬುಧ_ಗುರು_ಶುಕ್ರ_ಶನಿ'.split('_'),
|
| 23759 |
+
weekdaysMin : 'ಭಾ_ಸೋ_ಮಂ_ಬು_ಗು_ಶು_ಶ'.split('_'),
|
| 23760 |
+
longDateFormat : {
|
| 23761 |
+
LT : 'A h:mm',
|
| 23762 |
+
LTS : 'A h:mm:ss',
|
| 23763 |
+
L : 'DD/MM/YYYY',
|
| 23764 |
+
LL : 'D MMMM YYYY',
|
| 23765 |
+
LLL : 'D MMMM YYYY, A h:mm',
|
| 23766 |
+
LLLL : 'dddd, D MMMM YYYY, A h:mm'
|
| 23767 |
+
},
|
| 23768 |
+
calendar : {
|
| 23769 |
+
sameDay : '[ಇಂದು] LT',
|
| 23770 |
+
nextDay : '[ನಾಳೆ] LT',
|
| 23771 |
+
nextWeek : 'dddd, LT',
|
| 23772 |
+
lastDay : '[ನಿನ್ನೆ] LT',
|
| 23773 |
+
lastWeek : '[ಕೊನೆಯ] dddd, LT',
|
| 23774 |
+
sameElse : 'L'
|
| 23775 |
+
},
|
| 23776 |
+
relativeTime : {
|
| 23777 |
+
future : '%s ನಂತರ',
|
| 23778 |
+
past : '%s ಹಿಂದೆ',
|
| 23779 |
+
s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
|
| 23780 |
+
m : 'ಒಂದು ನಿಮಿಷ',
|
| 23781 |
+
mm : '%d ನಿಮಿಷ',
|
| 23782 |
+
h : 'ಒಂದು ಗಂಟೆ',
|
| 23783 |
+
hh : '%d ಗಂಟೆ',
|
| 23784 |
+
d : 'ಒಂದು ದಿನ',
|
| 23785 |
+
dd : '%d ದಿನ',
|
| 23786 |
+
M : 'ಒಂದು ತಿಂಗಳು',
|
| 23787 |
+
MM : '%d ತಿಂಗಳು',
|
| 23788 |
+
y : 'ಒಂದು ವರ್ಷ',
|
| 23789 |
+
yy : '%d ವರ್ಷ'
|
| 23790 |
+
},
|
| 23791 |
+
preparse: function (string) {
|
| 23792 |
+
return string.replace(/[೧೨೩೪೫೬೭೮೯೦]/g, function (match) {
|
| 23793 |
+
return numberMap[match];
|
| 23794 |
+
});
|
| 23795 |
+
},
|
| 23796 |
+
postformat: function (string) {
|
| 23797 |
+
return string.replace(/\d/g, function (match) {
|
| 23798 |
+
return symbolMap[match];
|
| 23799 |
+
});
|
| 23800 |
+
},
|
| 23801 |
+
meridiemParse: /ರಾತ್ರಿ|ಬೆಳಿಗ್ಗೆ|ಮಧ್ಯಾಹ್ನ|ಸಂಜೆ/,
|
| 23802 |
+
meridiemHour : function (hour, meridiem) {
|
| 23803 |
+
if (hour === 12) {
|
| 23804 |
+
hour = 0;
|
| 23805 |
+
}
|
| 23806 |
+
if (meridiem === 'ರಾತ್ರಿ') {
|
| 23807 |
+
return hour < 4 ? hour : hour + 12;
|
| 23808 |
+
} else if (meridiem === 'ಬೆಳಿಗ್ಗೆ') {
|
| 23809 |
+
return hour;
|
| 23810 |
+
} else if (meridiem === 'ಮಧ್ಯಾಹ್ನ') {
|
| 23811 |
+
return hour >= 10 ? hour : hour + 12;
|
| 23812 |
+
} else if (meridiem === 'ಸಂಜೆ') {
|
| 23813 |
+
return hour + 12;
|
| 23814 |
+
}
|
| 23815 |
+
},
|
| 23816 |
+
meridiem : function (hour, minute, isLower) {
|
| 23817 |
+
if (hour < 4) {
|
| 23818 |
+
return 'ರಾತ್ರಿ';
|
| 23819 |
+
} else if (hour < 10) {
|
| 23820 |
+
return 'ಬೆಳಿಗ್ಗೆ';
|
| 23821 |
+
} else if (hour < 17) {
|
| 23822 |
+
return 'ಮಧ್ಯಾಹ್ನ';
|
| 23823 |
+
} else if (hour < 20) {
|
| 23824 |
+
return 'ಸಂಜೆ';
|
| 23825 |
+
} else {
|
| 23826 |
+
return 'ರಾತ್ರಿ';
|
| 23827 |
+
}
|
| 23828 |
+
},
|
| 23829 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ನೇ)/,
|
| 23830 |
+
ordinal : function (number) {
|
| 23831 |
+
return number + 'ನೇ';
|
| 23832 |
+
},
|
| 23833 |
+
week : {
|
| 23834 |
+
dow : 0, // Sunday is the first day of the week.
|
| 23835 |
+
doy : 6 // The week that contains Jan 1st is the first week of the year.
|
| 23836 |
+
}
|
| 23837 |
+
});
|
| 23838 |
+
|
| 23839 |
+
return kn;
|
| 23840 |
+
|
| 23841 |
+
})));
|
| 23842 |
+
|
| 23843 |
+
|
| 23844 |
+
/***/ },
|
| 23845 |
+
/* 359 */
|
| 23846 |
/***/ function(module, exports, __webpack_require__) {
|
| 23847 |
|
| 23848 |
//! moment.js locale configuration
|
| 23851 |
//! author : Jeeeyul Lee <jeeeyul@gmail.com>
|
| 23852 |
|
| 23853 |
;(function (global, factory) {
|
| 23854 |
+
true ? factory(__webpack_require__(297)) :
|
| 23855 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23856 |
factory(global.moment)
|
| 23857 |
}(this, (function (moment) { 'use strict';
|
| 23864 |
weekdaysShort : '일_월_화_수_목_금_토'.split('_'),
|
| 23865 |
weekdaysMin : '일_월_화_수_목_금_토'.split('_'),
|
| 23866 |
longDateFormat : {
|
| 23867 |
+
LT : 'A h:mm',
|
| 23868 |
+
LTS : 'A h:mm:ss',
|
| 23869 |
L : 'YYYY.MM.DD',
|
| 23870 |
LL : 'YYYY년 MMMM D일',
|
| 23871 |
+
LLL : 'YYYY년 MMMM D일 A h:mm',
|
| 23872 |
+
LLLL : 'YYYY년 MMMM D일 dddd A h:mm',
|
| 23873 |
+
l : 'YYYY.MM.DD',
|
| 23874 |
+
ll : 'YYYY년 MMMM D일',
|
| 23875 |
+
lll : 'YYYY년 MMMM D일 A h:mm',
|
| 23876 |
+
llll : 'YYYY년 MMMM D일 dddd A h:mm'
|
| 23877 |
},
|
| 23878 |
calendar : {
|
| 23879 |
sameDay : '오늘 LT',
|
| 23888 |
past : '%s 전',
|
| 23889 |
s : '몇 초',
|
| 23890 |
ss : '%d초',
|
| 23891 |
+
m : '1분',
|
| 23892 |
mm : '%d분',
|
| 23893 |
h : '한 시간',
|
| 23894 |
hh : '%d시간',
|
| 23899 |
y : '일 년',
|
| 23900 |
yy : '%d년'
|
| 23901 |
},
|
| 23902 |
+
dayOfMonthOrdinalParse : /\d{1,2}일/,
|
| 23903 |
ordinal : '%d일',
|
| 23904 |
meridiemParse : /오전|오후/,
|
| 23905 |
isPM : function (token) {
|
| 23916 |
|
| 23917 |
|
| 23918 |
/***/ },
|
| 23919 |
+
/* 360 */
|
| 23920 |
/***/ function(module, exports, __webpack_require__) {
|
| 23921 |
|
| 23922 |
//! moment.js locale configuration
|
| 23924 |
//! author : Chyngyz Arystan uulu : https://github.com/chyngyz
|
| 23925 |
|
| 23926 |
;(function (global, factory) {
|
| 23927 |
+
true ? factory(__webpack_require__(297)) :
|
| 23928 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 23929 |
factory(global.moment)
|
| 23930 |
}(this, (function (moment) { 'use strict';
|
| 23991 |
y : 'бир жыл',
|
| 23992 |
yy : '%d жыл'
|
| 23993 |
},
|
| 23994 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(чи|чы|чү|чу)/,
|
| 23995 |
ordinal : function (number) {
|
| 23996 |
var a = number % 10,
|
| 23997 |
b = number >= 100 ? 100 : null;
|
| 24009 |
|
| 24010 |
|
| 24011 |
/***/ },
|
| 24012 |
+
/* 361 */
|
| 24013 |
/***/ function(module, exports, __webpack_require__) {
|
| 24014 |
|
| 24015 |
//! moment.js locale configuration
|
| 24018 |
//! author : David Raison : https://github.com/kwisatz
|
| 24019 |
|
| 24020 |
;(function (global, factory) {
|
| 24021 |
+
true ? factory(__webpack_require__(297)) :
|
| 24022 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24023 |
factory(global.moment)
|
| 24024 |
}(this, (function (moment) { 'use strict';
|
| 24137 |
y : processRelativeTime,
|
| 24138 |
yy : '%d Joer'
|
| 24139 |
},
|
| 24140 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 24141 |
ordinal: '%d.',
|
| 24142 |
week: {
|
| 24143 |
dow: 1, // Monday is the first day of the week.
|
| 24151 |
|
| 24152 |
|
| 24153 |
/***/ },
|
| 24154 |
+
/* 362 */
|
| 24155 |
/***/ function(module, exports, __webpack_require__) {
|
| 24156 |
|
| 24157 |
//! moment.js locale configuration
|
| 24159 |
//! author : Ryan Hart : https://github.com/ryanhart2
|
| 24160 |
|
| 24161 |
;(function (global, factory) {
|
| 24162 |
+
true ? factory(__webpack_require__(297)) :
|
| 24163 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24164 |
factory(global.moment)
|
| 24165 |
}(this, (function (moment) { 'use strict';
|
| 24214 |
y : '1 ປີ',
|
| 24215 |
yy : '%d ປີ'
|
| 24216 |
},
|
| 24217 |
+
dayOfMonthOrdinalParse: /(ທີ່)\d{1,2}/,
|
| 24218 |
ordinal : function (number) {
|
| 24219 |
return 'ທີ່' + number;
|
| 24220 |
}
|
| 24226 |
|
| 24227 |
|
| 24228 |
/***/ },
|
| 24229 |
+
/* 363 */
|
| 24230 |
/***/ function(module, exports, __webpack_require__) {
|
| 24231 |
|
| 24232 |
//! moment.js locale configuration
|
| 24234 |
//! author : Mindaugas Mozūras : https://github.com/mmozuras
|
| 24235 |
|
| 24236 |
;(function (global, factory) {
|
| 24237 |
+
true ? factory(__webpack_require__(297)) :
|
| 24238 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24239 |
factory(global.moment)
|
| 24240 |
}(this, (function (moment) { 'use strict';
|
| 24332 |
y : translateSingular,
|
| 24333 |
yy : translate
|
| 24334 |
},
|
| 24335 |
+
dayOfMonthOrdinalParse: /\d{1,2}-oji/,
|
| 24336 |
ordinal : function (number) {
|
| 24337 |
return number + '-oji';
|
| 24338 |
},
|
| 24348 |
|
| 24349 |
|
| 24350 |
/***/ },
|
| 24351 |
+
/* 364 */
|
| 24352 |
/***/ function(module, exports, __webpack_require__) {
|
| 24353 |
|
| 24354 |
//! moment.js locale configuration
|
| 24357 |
//! author : Jānis Elmeris : https://github.com/JanisE
|
| 24358 |
|
| 24359 |
;(function (global, factory) {
|
| 24360 |
+
true ? factory(__webpack_require__(297)) :
|
| 24361 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24362 |
factory(global.moment)
|
| 24363 |
}(this, (function (moment) { 'use strict';
|
| 24436 |
y : relativeTimeWithSingular,
|
| 24437 |
yy : relativeTimeWithPlural
|
| 24438 |
},
|
| 24439 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 24440 |
ordinal : '%d.',
|
| 24441 |
week : {
|
| 24442 |
dow : 1, // Monday is the first day of the week.
|
| 24450 |
|
| 24451 |
|
| 24452 |
/***/ },
|
| 24453 |
+
/* 365 */
|
| 24454 |
/***/ function(module, exports, __webpack_require__) {
|
| 24455 |
|
| 24456 |
//! moment.js locale configuration
|
| 24458 |
//! author : Miodrag Nikač <miodrag@restartit.me> : https://github.com/miodragnikac
|
| 24459 |
|
| 24460 |
;(function (global, factory) {
|
| 24461 |
+
true ? factory(__webpack_require__(297)) :
|
| 24462 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24463 |
factory(global.moment)
|
| 24464 |
}(this, (function (moment) { 'use strict';
|
| 24552 |
y : 'godinu',
|
| 24553 |
yy : translator.translate
|
| 24554 |
},
|
| 24555 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 24556 |
ordinal : '%d.',
|
| 24557 |
week : {
|
| 24558 |
dow : 1, // Monday is the first day of the week.
|
| 24566 |
|
| 24567 |
|
| 24568 |
/***/ },
|
| 24569 |
+
/* 366 */
|
| 24570 |
/***/ function(module, exports, __webpack_require__) {
|
| 24571 |
|
| 24572 |
//! moment.js locale configuration
|
| 24574 |
//! author : John Corrigan <robbiecloset@gmail.com> : https://github.com/johnideal
|
| 24575 |
|
| 24576 |
;(function (global, factory) {
|
| 24577 |
+
true ? factory(__webpack_require__(297)) :
|
| 24578 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24579 |
factory(global.moment)
|
| 24580 |
}(this, (function (moment) { 'use strict';
|
| 24621 |
y: 'he tau',
|
| 24622 |
yy: '%d tau'
|
| 24623 |
},
|
| 24624 |
+
dayOfMonthOrdinalParse: /\d{1,2}º/,
|
| 24625 |
ordinal: '%dº',
|
| 24626 |
week : {
|
| 24627 |
dow : 1, // Monday is the first day of the week.
|
| 24635 |
|
| 24636 |
|
| 24637 |
/***/ },
|
| 24638 |
+
/* 367 */
|
| 24639 |
/***/ function(module, exports, __webpack_require__) {
|
| 24640 |
|
| 24641 |
//! moment.js locale configuration
|
| 24643 |
//! author : Borislav Mickov : https://github.com/B0k0
|
| 24644 |
|
| 24645 |
;(function (global, factory) {
|
| 24646 |
+
true ? factory(__webpack_require__(297)) :
|
| 24647 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24648 |
factory(global.moment)
|
| 24649 |
}(this, (function (moment) { 'use strict';
|
| 24698 |
y : 'година',
|
| 24699 |
yy : '%d години'
|
| 24700 |
},
|
| 24701 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ев|ен|ти|ви|ри|ми)/,
|
| 24702 |
ordinal : function (number) {
|
| 24703 |
var lastDigit = number % 10,
|
| 24704 |
last2Digits = number % 100;
|
| 24730 |
|
| 24731 |
|
| 24732 |
/***/ },
|
| 24733 |
+
/* 368 */
|
| 24734 |
/***/ function(module, exports, __webpack_require__) {
|
| 24735 |
|
| 24736 |
//! moment.js locale configuration
|
| 24738 |
//! author : Floyd Pink : https://github.com/floydpink
|
| 24739 |
|
| 24740 |
;(function (global, factory) {
|
| 24741 |
+
true ? factory(__webpack_require__(297)) :
|
| 24742 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24743 |
factory(global.moment)
|
| 24744 |
}(this, (function (moment) { 'use strict';
|
| 24816 |
|
| 24817 |
|
| 24818 |
/***/ },
|
| 24819 |
+
/* 369 */
|
| 24820 |
/***/ function(module, exports, __webpack_require__) {
|
| 24821 |
|
| 24822 |
//! moment.js locale configuration
|
| 24825 |
//! author : Vivek Athalye : https://github.com/vnathalye
|
| 24826 |
|
| 24827 |
;(function (global, factory) {
|
| 24828 |
+
true ? factory(__webpack_require__(297)) :
|
| 24829 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24830 |
factory(global.moment)
|
| 24831 |
}(this, (function (moment) { 'use strict';
|
| 24980 |
|
| 24981 |
|
| 24982 |
/***/ },
|
| 24983 |
+
/* 370 */
|
| 24984 |
/***/ function(module, exports, __webpack_require__) {
|
| 24985 |
|
| 24986 |
//! moment.js locale configuration
|
| 24988 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 24989 |
|
| 24990 |
;(function (global, factory) {
|
| 24991 |
+
true ? factory(__webpack_require__(297)) :
|
| 24992 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 24993 |
factory(global.moment)
|
| 24994 |
}(this, (function (moment) { 'use strict';
|
| 25067 |
|
| 25068 |
|
| 25069 |
/***/ },
|
| 25070 |
+
/* 371 */
|
| 25071 |
/***/ function(module, exports, __webpack_require__) {
|
| 25072 |
|
| 25073 |
//! moment.js locale configuration
|
| 25076 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 25077 |
|
| 25078 |
;(function (global, factory) {
|
| 25079 |
+
true ? factory(__webpack_require__(297)) :
|
| 25080 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25081 |
factory(global.moment)
|
| 25082 |
}(this, (function (moment) { 'use strict';
|
| 25155 |
|
| 25156 |
|
| 25157 |
/***/ },
|
| 25158 |
+
/* 372 */
|
| 25159 |
/***/ function(module, exports, __webpack_require__) {
|
| 25160 |
|
| 25161 |
//! moment.js locale configuration
|
| 25165 |
//! author : Tin Aung Lin : https://github.com/thanyawzinmin
|
| 25166 |
|
| 25167 |
;(function (global, factory) {
|
| 25168 |
+
true ? factory(__webpack_require__(297)) :
|
| 25169 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25170 |
factory(global.moment)
|
| 25171 |
}(this, (function (moment) { 'use strict';
|
| 25256 |
|
| 25257 |
|
| 25258 |
/***/ },
|
| 25259 |
+
/* 373 */
|
| 25260 |
/***/ function(module, exports, __webpack_require__) {
|
| 25261 |
|
| 25262 |
//! moment.js locale configuration
|
| 25265 |
//! Sigurd Gartmann : https://github.com/sigurdga
|
| 25266 |
|
| 25267 |
;(function (global, factory) {
|
| 25268 |
+
true ? factory(__webpack_require__(297)) :
|
| 25269 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25270 |
factory(global.moment)
|
| 25271 |
}(this, (function (moment) { 'use strict';
|
| 25310 |
y : 'ett år',
|
| 25311 |
yy : '%d år'
|
| 25312 |
},
|
| 25313 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 25314 |
ordinal : '%d.',
|
| 25315 |
week : {
|
| 25316 |
dow : 1, // Monday is the first day of the week.
|
| 25324 |
|
| 25325 |
|
| 25326 |
/***/ },
|
| 25327 |
+
/* 374 */
|
| 25328 |
/***/ function(module, exports, __webpack_require__) {
|
| 25329 |
|
| 25330 |
//! moment.js locale configuration
|
| 25332 |
//! author : suvash : https://github.com/suvash
|
| 25333 |
|
| 25334 |
;(function (global, factory) {
|
| 25335 |
+
true ? factory(__webpack_require__(297)) :
|
| 25336 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25337 |
factory(global.moment)
|
| 25338 |
}(this, (function (moment) { 'use strict';
|
| 25452 |
|
| 25453 |
|
| 25454 |
/***/ },
|
| 25455 |
+
/* 375 */
|
| 25456 |
/***/ function(module, exports, __webpack_require__) {
|
| 25457 |
|
| 25458 |
//! moment.js locale configuration
|
| 25461 |
//! author : Jacob Middag : https://github.com/middagj
|
| 25462 |
|
| 25463 |
;(function (global, factory) {
|
| 25464 |
+
true ? factory(__webpack_require__(297)) :
|
| 25465 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25466 |
factory(global.moment)
|
| 25467 |
}(this, (function (moment) { 'use strict';
|
| 25476 |
var nl = moment.defineLocale('nl', {
|
| 25477 |
months : 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split('_'),
|
| 25478 |
monthsShort : function (m, format) {
|
| 25479 |
+
if (!m) {
|
| 25480 |
+
return monthsShortWithDots;
|
| 25481 |
+
} else if (/-MMM-/.test(format)) {
|
| 25482 |
return monthsShortWithoutDots[m.month()];
|
| 25483 |
} else {
|
| 25484 |
return monthsShortWithDots[m.month()];
|
| 25529 |
y : 'één jaar',
|
| 25530 |
yy : '%d jaar'
|
| 25531 |
},
|
| 25532 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 25533 |
ordinal : function (number) {
|
| 25534 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 25535 |
},
|
| 25545 |
|
| 25546 |
|
| 25547 |
/***/ },
|
| 25548 |
+
/* 376 */
|
| 25549 |
/***/ function(module, exports, __webpack_require__) {
|
| 25550 |
|
| 25551 |
//! moment.js locale configuration
|
| 25554 |
//! author : Jacob Middag : https://github.com/middagj
|
| 25555 |
|
| 25556 |
;(function (global, factory) {
|
| 25557 |
+
true ? factory(__webpack_require__(297)) :
|
| 25558 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25559 |
factory(global.moment)
|
| 25560 |
}(this, (function (moment) { 'use strict';
|
| 25569 |
var nlBe = moment.defineLocale('nl-be', {
|
| 25570 |
months : 'januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december'.split('_'),
|
| 25571 |
monthsShort : function (m, format) {
|
| 25572 |
+
if (!m) {
|
| 25573 |
+
return monthsShortWithDots;
|
| 25574 |
+
} else if (/-MMM-/.test(format)) {
|
| 25575 |
return monthsShortWithoutDots[m.month()];
|
| 25576 |
} else {
|
| 25577 |
return monthsShortWithDots[m.month()];
|
| 25622 |
y : 'één jaar',
|
| 25623 |
yy : '%d jaar'
|
| 25624 |
},
|
| 25625 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 25626 |
ordinal : function (number) {
|
| 25627 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 25628 |
},
|
| 25638 |
|
| 25639 |
|
| 25640 |
/***/ },
|
| 25641 |
+
/* 377 */
|
| 25642 |
/***/ function(module, exports, __webpack_require__) {
|
| 25643 |
|
| 25644 |
//! moment.js locale configuration
|
| 25646 |
//! author : https://github.com/mechuwind
|
| 25647 |
|
| 25648 |
;(function (global, factory) {
|
| 25649 |
+
true ? factory(__webpack_require__(297)) :
|
| 25650 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25651 |
factory(global.moment)
|
| 25652 |
}(this, (function (moment) { 'use strict';
|
| 25689 |
y : 'eit år',
|
| 25690 |
yy : '%d år'
|
| 25691 |
},
|
| 25692 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 25693 |
ordinal : '%d.',
|
| 25694 |
week : {
|
| 25695 |
dow : 1, // Monday is the first day of the week.
|
| 25703 |
|
| 25704 |
|
| 25705 |
/***/ },
|
| 25706 |
+
/* 378 */
|
| 25707 |
/***/ function(module, exports, __webpack_require__) {
|
| 25708 |
|
| 25709 |
//! moment.js locale configuration
|
| 25711 |
//! author : Harpreet Singh : https://github.com/harpreetkhalsagtbit
|
| 25712 |
|
| 25713 |
;(function (global, factory) {
|
| 25714 |
+
true ? factory(__webpack_require__(297)) :
|
| 25715 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25716 |
factory(global.moment)
|
| 25717 |
}(this, (function (moment) { 'use strict';
|
| 25832 |
|
| 25833 |
|
| 25834 |
/***/ },
|
| 25835 |
+
/* 379 */
|
| 25836 |
/***/ function(module, exports, __webpack_require__) {
|
| 25837 |
|
| 25838 |
//! moment.js locale configuration
|
| 25840 |
//! author : Rafal Hirsz : https://github.com/evoL
|
| 25841 |
|
| 25842 |
;(function (global, factory) {
|
| 25843 |
+
true ? factory(__webpack_require__(297)) :
|
| 25844 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25845 |
factory(global.moment)
|
| 25846 |
}(this, (function (moment) { 'use strict';
|
| 25871 |
|
| 25872 |
var pl = moment.defineLocale('pl', {
|
| 25873 |
months : function (momentToFormat, format) {
|
| 25874 |
+
if (!momentToFormat) {
|
| 25875 |
+
return monthsNominative;
|
| 25876 |
+
} else if (format === '') {
|
| 25877 |
// Hack: if format empty we know this is used to generate
|
| 25878 |
// RegExp by moment. Give then back both valid forms of months
|
| 25879 |
// in RegExp ready format.
|
| 25930 |
y : 'rok',
|
| 25931 |
yy : translate
|
| 25932 |
},
|
| 25933 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 25934 |
ordinal : '%d.',
|
| 25935 |
week : {
|
| 25936 |
dow : 1, // Monday is the first day of the week.
|
| 25944 |
|
| 25945 |
|
| 25946 |
/***/ },
|
| 25947 |
+
/* 380 */
|
| 25948 |
/***/ function(module, exports, __webpack_require__) {
|
| 25949 |
|
| 25950 |
//! moment.js locale configuration
|
| 25952 |
//! author : Jefferson : https://github.com/jalex79
|
| 25953 |
|
| 25954 |
;(function (global, factory) {
|
| 25955 |
+
true ? factory(__webpack_require__(297)) :
|
| 25956 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 25957 |
factory(global.moment)
|
| 25958 |
}(this, (function (moment) { 'use strict';
|
| 25963 |
monthsShort : 'Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez'.split('_'),
|
| 25964 |
weekdays : 'Domingo_Segunda-Feira_Terça-Feira_Quarta-Feira_Quinta-Feira_Sexta-Feira_Sábado'.split('_'),
|
| 25965 |
weekdaysShort : 'Dom_Seg_Ter_Qua_Qui_Sex_Sáb'.split('_'),
|
| 25966 |
+
weekdaysMin : 'Do_2ª_3ª_4ª_5ª_6ª_Sá'.split('_'),
|
| 25967 |
weekdaysParseExact : true,
|
| 25968 |
longDateFormat : {
|
| 25969 |
LT : 'HH:mm',
|
| 26000 |
y : 'um ano',
|
| 26001 |
yy : '%d anos'
|
| 26002 |
},
|
| 26003 |
+
dayOfMonthOrdinalParse: /\d{1,2}º/,
|
| 26004 |
ordinal : '%dº',
|
| 26005 |
week : {
|
| 26006 |
dow : 1, // Monday is the first day of the week.
|
| 26014 |
|
| 26015 |
|
| 26016 |
/***/ },
|
| 26017 |
+
/* 381 */
|
| 26018 |
/***/ function(module, exports, __webpack_require__) {
|
| 26019 |
|
| 26020 |
//! moment.js locale configuration
|
| 26022 |
//! author : Caio Ribeiro Pereira : https://github.com/caio-ribeiro-pereira
|
| 26023 |
|
| 26024 |
;(function (global, factory) {
|
| 26025 |
+
true ? factory(__webpack_require__(297)) :
|
| 26026 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26027 |
factory(global.moment)
|
| 26028 |
}(this, (function (moment) { 'use strict';
|
| 26033 |
monthsShort : 'Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez'.split('_'),
|
| 26034 |
weekdays : 'Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado'.split('_'),
|
| 26035 |
weekdaysShort : 'Dom_Seg_Ter_Qua_Qui_Sex_Sáb'.split('_'),
|
| 26036 |
+
weekdaysMin : 'Do_2ª_3ª_4ª_5ª_6ª_Sá'.split('_'),
|
| 26037 |
weekdaysParseExact : true,
|
| 26038 |
longDateFormat : {
|
| 26039 |
LT : 'HH:mm',
|
| 26070 |
y : 'um ano',
|
| 26071 |
yy : '%d anos'
|
| 26072 |
},
|
| 26073 |
+
dayOfMonthOrdinalParse: /\d{1,2}º/,
|
| 26074 |
ordinal : '%dº'
|
| 26075 |
});
|
| 26076 |
|
| 26080 |
|
| 26081 |
|
| 26082 |
/***/ },
|
| 26083 |
+
/* 382 */
|
| 26084 |
/***/ function(module, exports, __webpack_require__) {
|
| 26085 |
|
| 26086 |
//! moment.js locale configuration
|
| 26089 |
//! author : Valentin Agachi : https://github.com/avaly
|
| 26090 |
|
| 26091 |
;(function (global, factory) {
|
| 26092 |
+
true ? factory(__webpack_require__(297)) :
|
| 26093 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26094 |
factory(global.moment)
|
| 26095 |
}(this, (function (moment) { 'use strict';
|
| 26160 |
|
| 26161 |
|
| 26162 |
/***/ },
|
| 26163 |
+
/* 383 */
|
| 26164 |
/***/ function(module, exports, __webpack_require__) {
|
| 26165 |
|
| 26166 |
//! moment.js locale configuration
|
| 26170 |
//! author : Коренберг Марк : https://github.com/socketpair
|
| 26171 |
|
| 26172 |
;(function (global, factory) {
|
| 26173 |
+
true ? factory(__webpack_require__(297)) :
|
| 26174 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26175 |
factory(global.moment)
|
| 26176 |
}(this, (function (moment) { 'use strict';
|
| 26320 |
return 'вечера';
|
| 26321 |
}
|
| 26322 |
},
|
| 26323 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(й|го|я)/,
|
| 26324 |
ordinal: function (number, period) {
|
| 26325 |
switch (period) {
|
| 26326 |
case 'M':
|
| 26348 |
|
| 26349 |
|
| 26350 |
/***/ },
|
| 26351 |
+
/* 384 */
|
| 26352 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 26353 |
+
|
| 26354 |
+
//! moment.js locale configuration
|
| 26355 |
+
//! locale : Sindhi [sd]
|
| 26356 |
+
//! author : Narain Sagar : https://github.com/narainsagar
|
| 26357 |
+
|
| 26358 |
+
;(function (global, factory) {
|
| 26359 |
+
true ? factory(__webpack_require__(297)) :
|
| 26360 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26361 |
+
factory(global.moment)
|
| 26362 |
+
}(this, (function (moment) { 'use strict';
|
| 26363 |
+
|
| 26364 |
+
|
| 26365 |
+
var months = [
|
| 26366 |
+
'جنوري',
|
| 26367 |
+
'فيبروري',
|
| 26368 |
+
'مارچ',
|
| 26369 |
+
'اپريل',
|
| 26370 |
+
'مئي',
|
| 26371 |
+
'جون',
|
| 26372 |
+
'جولاءِ',
|
| 26373 |
+
'آگسٽ',
|
| 26374 |
+
'سيپٽمبر',
|
| 26375 |
+
'آڪٽوبر',
|
| 26376 |
+
'نومبر',
|
| 26377 |
+
'ڊسمبر'
|
| 26378 |
+
];
|
| 26379 |
+
var days = [
|
| 26380 |
+
'آچر',
|
| 26381 |
+
'سومر',
|
| 26382 |
+
'اڱارو',
|
| 26383 |
+
'اربع',
|
| 26384 |
+
'خميس',
|
| 26385 |
+
'جمع',
|
| 26386 |
+
'ڇنڇر'
|
| 26387 |
+
];
|
| 26388 |
+
|
| 26389 |
+
var sd = moment.defineLocale('sd', {
|
| 26390 |
+
months : months,
|
| 26391 |
+
monthsShort : months,
|
| 26392 |
+
weekdays : days,
|
| 26393 |
+
weekdaysShort : days,
|
| 26394 |
+
weekdaysMin : days,
|
| 26395 |
+
longDateFormat : {
|
| 26396 |
+
LT : 'HH:mm',
|
| 26397 |
+
LTS : 'HH:mm:ss',
|
| 26398 |
+
L : 'DD/MM/YYYY',
|
| 26399 |
+
LL : 'D MMMM YYYY',
|
| 26400 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 26401 |
+
LLLL : 'dddd، D MMMM YYYY HH:mm'
|
| 26402 |
+
},
|
| 26403 |
+
meridiemParse: /صبح|شام/,
|
| 26404 |
+
isPM : function (input) {
|
| 26405 |
+
return 'شام' === input;
|
| 26406 |
+
},
|
| 26407 |
+
meridiem : function (hour, minute, isLower) {
|
| 26408 |
+
if (hour < 12) {
|
| 26409 |
+
return 'صبح';
|
| 26410 |
+
}
|
| 26411 |
+
return 'شام';
|
| 26412 |
+
},
|
| 26413 |
+
calendar : {
|
| 26414 |
+
sameDay : '[اڄ] LT',
|
| 26415 |
+
nextDay : '[سڀاڻي] LT',
|
| 26416 |
+
nextWeek : 'dddd [اڳين هفتي تي] LT',
|
| 26417 |
+
lastDay : '[ڪالهه] LT',
|
| 26418 |
+
lastWeek : '[گزريل هفتي] dddd [تي] LT',
|
| 26419 |
+
sameElse : 'L'
|
| 26420 |
+
},
|
| 26421 |
+
relativeTime : {
|
| 26422 |
+
future : '%s پوء',
|
| 26423 |
+
past : '%s اڳ',
|
| 26424 |
+
s : 'چند سيڪنڊ',
|
| 26425 |
+
m : 'هڪ منٽ',
|
| 26426 |
+
mm : '%d منٽ',
|
| 26427 |
+
h : 'هڪ ڪلاڪ',
|
| 26428 |
+
hh : '%d ڪلاڪ',
|
| 26429 |
+
d : 'هڪ ڏينهن',
|
| 26430 |
+
dd : '%d ڏينهن',
|
| 26431 |
+
M : 'هڪ مهينو',
|
| 26432 |
+
MM : '%d مهينا',
|
| 26433 |
+
y : 'هڪ سال',
|
| 26434 |
+
yy : '%d سال'
|
| 26435 |
+
},
|
| 26436 |
+
preparse: function (string) {
|
| 26437 |
+
return string.replace(/،/g, ',');
|
| 26438 |
+
},
|
| 26439 |
+
postformat: function (string) {
|
| 26440 |
+
return string.replace(/,/g, '،');
|
| 26441 |
+
},
|
| 26442 |
+
week : {
|
| 26443 |
+
dow : 1, // Monday is the first day of the week.
|
| 26444 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 26445 |
+
}
|
| 26446 |
+
});
|
| 26447 |
+
|
| 26448 |
+
return sd;
|
| 26449 |
+
|
| 26450 |
+
})));
|
| 26451 |
+
|
| 26452 |
+
|
| 26453 |
+
/***/ },
|
| 26454 |
+
/* 385 */
|
| 26455 |
/***/ function(module, exports, __webpack_require__) {
|
| 26456 |
|
| 26457 |
//! moment.js locale configuration
|
| 26459 |
//! authors : Bård Rolstad Henriksen : https://github.com/karamell
|
| 26460 |
|
| 26461 |
;(function (global, factory) {
|
| 26462 |
+
true ? factory(__webpack_require__(297)) :
|
| 26463 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26464 |
factory(global.moment)
|
| 26465 |
}(this, (function (moment) { 'use strict';
|
| 26503 |
y : 'okta jahki',
|
| 26504 |
yy : '%d jagit'
|
| 26505 |
},
|
| 26506 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 26507 |
ordinal : '%d.',
|
| 26508 |
week : {
|
| 26509 |
dow : 1, // Monday is the first day of the week.
|
| 26517 |
|
| 26518 |
|
| 26519 |
/***/ },
|
| 26520 |
+
/* 386 */
|
| 26521 |
/***/ function(module, exports, __webpack_require__) {
|
| 26522 |
|
| 26523 |
//! moment.js locale configuration
|
| 26525 |
//! author : Sampath Sitinamaluwa : https://github.com/sampathsris
|
| 26526 |
|
| 26527 |
;(function (global, factory) {
|
| 26528 |
+
true ? factory(__webpack_require__(297)) :
|
| 26529 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26530 |
factory(global.moment)
|
| 26531 |
}(this, (function (moment) { 'use strict';
|
| 26570 |
y : 'වසර',
|
| 26571 |
yy : 'වසර %d'
|
| 26572 |
},
|
| 26573 |
+
dayOfMonthOrdinalParse: /\d{1,2} වැනි/,
|
| 26574 |
ordinal : function (number) {
|
| 26575 |
return number + ' වැනි';
|
| 26576 |
},
|
| 26593 |
|
| 26594 |
|
| 26595 |
/***/ },
|
| 26596 |
+
/* 387 */
|
| 26597 |
/***/ function(module, exports, __webpack_require__) {
|
| 26598 |
|
| 26599 |
//! moment.js locale configuration
|
| 26602 |
//! based on work of petrbela : https://github.com/petrbela
|
| 26603 |
|
| 26604 |
;(function (global, factory) {
|
| 26605 |
+
true ? factory(__webpack_require__(297)) :
|
| 26606 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26607 |
factory(global.moment)
|
| 26608 |
}(this, (function (moment) { 'use strict';
|
| 26734 |
y : translate,
|
| 26735 |
yy : translate
|
| 26736 |
},
|
| 26737 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 26738 |
ordinal : '%d.',
|
| 26739 |
week : {
|
| 26740 |
dow : 1, // Monday is the first day of the week.
|
| 26748 |
|
| 26749 |
|
| 26750 |
/***/ },
|
| 26751 |
+
/* 388 */
|
| 26752 |
/***/ function(module, exports, __webpack_require__) {
|
| 26753 |
|
| 26754 |
//! moment.js locale configuration
|
| 26756 |
//! author : Robert Sedovšek : https://github.com/sedovsek
|
| 26757 |
|
| 26758 |
;(function (global, factory) {
|
| 26759 |
+
true ? factory(__webpack_require__(297)) :
|
| 26760 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26761 |
factory(global.moment)
|
| 26762 |
}(this, (function (moment) { 'use strict';
|
| 26901 |
y : processRelativeTime,
|
| 26902 |
yy : processRelativeTime
|
| 26903 |
},
|
| 26904 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 26905 |
ordinal : '%d.',
|
| 26906 |
week : {
|
| 26907 |
dow : 1, // Monday is the first day of the week.
|
| 26915 |
|
| 26916 |
|
| 26917 |
/***/ },
|
| 26918 |
+
/* 389 */
|
| 26919 |
/***/ function(module, exports, __webpack_require__) {
|
| 26920 |
|
| 26921 |
//! moment.js locale configuration
|
| 26925 |
//! author : Oerd Cukalla : https://github.com/oerd
|
| 26926 |
|
| 26927 |
;(function (global, factory) {
|
| 26928 |
+
true ? factory(__webpack_require__(297)) :
|
| 26929 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 26930 |
factory(global.moment)
|
| 26931 |
}(this, (function (moment) { 'use strict';
|
| 26976 |
y : 'një vit',
|
| 26977 |
yy : '%d vite'
|
| 26978 |
},
|
| 26979 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 26980 |
ordinal : '%d.',
|
| 26981 |
week : {
|
| 26982 |
dow : 1, // Monday is the first day of the week.
|
| 26990 |
|
| 26991 |
|
| 26992 |
/***/ },
|
| 26993 |
+
/* 390 */
|
| 26994 |
/***/ function(module, exports, __webpack_require__) {
|
| 26995 |
|
| 26996 |
//! moment.js locale configuration
|
| 26998 |
//! author : Milan Janačković<milanjanackovic@gmail.com> : https://github.com/milan-j
|
| 26999 |
|
| 27000 |
;(function (global, factory) {
|
| 27001 |
+
true ? factory(__webpack_require__(297)) :
|
| 27002 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27003 |
factory(global.moment)
|
| 27004 |
}(this, (function (moment) { 'use strict';
|
| 27091 |
y : 'godinu',
|
| 27092 |
yy : translator.translate
|
| 27093 |
},
|
| 27094 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 27095 |
ordinal : '%d.',
|
| 27096 |
week : {
|
| 27097 |
dow : 1, // Monday is the first day of the week.
|
| 27105 |
|
| 27106 |
|
| 27107 |
/***/ },
|
| 27108 |
+
/* 391 */
|
| 27109 |
/***/ function(module, exports, __webpack_require__) {
|
| 27110 |
|
| 27111 |
//! moment.js locale configuration
|
| 27113 |
//! author : Milan Janačković<milanjanackovic@gmail.com> : https://github.com/milan-j
|
| 27114 |
|
| 27115 |
;(function (global, factory) {
|
| 27116 |
+
true ? factory(__webpack_require__(297)) :
|
| 27117 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27118 |
factory(global.moment)
|
| 27119 |
}(this, (function (moment) { 'use strict';
|
| 27206 |
y : 'годину',
|
| 27207 |
yy : translator.translate
|
| 27208 |
},
|
| 27209 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 27210 |
ordinal : '%d.',
|
| 27211 |
week : {
|
| 27212 |
dow : 1, // Monday is the first day of the week.
|
| 27220 |
|
| 27221 |
|
| 27222 |
/***/ },
|
| 27223 |
+
/* 392 */
|
| 27224 |
/***/ function(module, exports, __webpack_require__) {
|
| 27225 |
|
| 27226 |
//! moment.js locale configuration
|
| 27228 |
//! author : Nicolai Davies<mail@nicolai.io> : https://github.com/nicolaidavies
|
| 27229 |
|
| 27230 |
;(function (global, factory) {
|
| 27231 |
+
true ? factory(__webpack_require__(297)) :
|
| 27232 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27233 |
factory(global.moment)
|
| 27234 |
}(this, (function (moment) { 'use strict';
|
| 27300 |
return hour + 12;
|
| 27301 |
}
|
| 27302 |
},
|
| 27303 |
+
dayOfMonthOrdinalParse: /\d{1,2}/,
|
| 27304 |
ordinal : '%d',
|
| 27305 |
week : {
|
| 27306 |
dow : 1, // Monday is the first day of the week.
|
| 27314 |
|
| 27315 |
|
| 27316 |
/***/ },
|
| 27317 |
+
/* 393 */
|
| 27318 |
/***/ function(module, exports, __webpack_require__) {
|
| 27319 |
|
| 27320 |
//! moment.js locale configuration
|
| 27322 |
//! author : Jens Alm : https://github.com/ulmus
|
| 27323 |
|
| 27324 |
;(function (global, factory) {
|
| 27325 |
+
true ? factory(__webpack_require__(297)) :
|
| 27326 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27327 |
factory(global.moment)
|
| 27328 |
}(this, (function (moment) { 'use strict';
|
| 27367 |
y : 'ett år',
|
| 27368 |
yy : '%d år'
|
| 27369 |
},
|
| 27370 |
+
dayOfMonthOrdinalParse: /\d{1,2}(e|a)/,
|
| 27371 |
ordinal : function (number) {
|
| 27372 |
var b = number % 10,
|
| 27373 |
output = (~~(number % 100 / 10) === 1) ? 'e' :
|
| 27388 |
|
| 27389 |
|
| 27390 |
/***/ },
|
| 27391 |
+
/* 394 */
|
| 27392 |
/***/ function(module, exports, __webpack_require__) {
|
| 27393 |
|
| 27394 |
//! moment.js locale configuration
|
| 27396 |
//! author : Fahad Kassim : https://github.com/fadsel
|
| 27397 |
|
| 27398 |
;(function (global, factory) {
|
| 27399 |
+
true ? factory(__webpack_require__(297)) :
|
| 27400 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27401 |
factory(global.moment)
|
| 27402 |
}(this, (function (moment) { 'use strict';
|
| 27452 |
|
| 27453 |
|
| 27454 |
/***/ },
|
| 27455 |
+
/* 395 */
|
| 27456 |
/***/ function(module, exports, __webpack_require__) {
|
| 27457 |
|
| 27458 |
//! moment.js locale configuration
|
| 27460 |
//! author : Arjunkumar Krishnamoorthy : https://github.com/tk120404
|
| 27461 |
|
| 27462 |
;(function (global, factory) {
|
| 27463 |
+
true ? factory(__webpack_require__(297)) :
|
| 27464 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27465 |
factory(global.moment)
|
| 27466 |
}(this, (function (moment) { 'use strict';
|
| 27528 |
y : 'ஒரு வருடம்',
|
| 27529 |
yy : '%d ஆண்டுகள்'
|
| 27530 |
},
|
| 27531 |
+
dayOfMonthOrdinalParse: /\d{1,2}வது/,
|
| 27532 |
ordinal : function (number) {
|
| 27533 |
return number + 'வது';
|
| 27534 |
},
|
| 27587 |
|
| 27588 |
|
| 27589 |
/***/ },
|
| 27590 |
+
/* 396 */
|
| 27591 |
/***/ function(module, exports, __webpack_require__) {
|
| 27592 |
|
| 27593 |
//! moment.js locale configuration
|
| 27595 |
//! author : Krishna Chaitanya Thota : https://github.com/kcthota
|
| 27596 |
|
| 27597 |
;(function (global, factory) {
|
| 27598 |
+
true ? factory(__webpack_require__(297)) :
|
| 27599 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27600 |
factory(global.moment)
|
| 27601 |
}(this, (function (moment) { 'use strict';
|
| 27639 |
y : 'ఒక సంవత్సరం',
|
| 27640 |
yy : '%d సంవత్సరాలు'
|
| 27641 |
},
|
| 27642 |
+
dayOfMonthOrdinalParse : /\d{1,2}వ/,
|
| 27643 |
ordinal : '%dవ',
|
| 27644 |
meridiemParse: /రాత్రి|ఉదయం|మధ్యాహ్నం|సాయంత్రం/,
|
| 27645 |
meridiemHour : function (hour, meridiem) {
|
| 27681 |
|
| 27682 |
|
| 27683 |
/***/ },
|
| 27684 |
+
/* 397 */
|
| 27685 |
/***/ function(module, exports, __webpack_require__) {
|
| 27686 |
|
| 27687 |
//! moment.js locale configuration
|
| 27690 |
//! author : Onorio De J. Afonso : https://github.com/marobo
|
| 27691 |
|
| 27692 |
;(function (global, factory) {
|
| 27693 |
+
true ? factory(__webpack_require__(297)) :
|
| 27694 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27695 |
factory(global.moment)
|
| 27696 |
}(this, (function (moment) { 'use strict';
|
| 27733 |
y : 'tinan ida',
|
| 27734 |
yy : 'tinan %d'
|
| 27735 |
},
|
| 27736 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 27737 |
ordinal : function (number) {
|
| 27738 |
var b = number % 10,
|
| 27739 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 27754 |
|
| 27755 |
|
| 27756 |
/***/ },
|
| 27757 |
+
/* 398 */
|
| 27758 |
/***/ function(module, exports, __webpack_require__) {
|
| 27759 |
|
| 27760 |
//! moment.js locale configuration
|
| 27762 |
//! author : Kridsada Thanabulpong : https://github.com/sirn
|
| 27763 |
|
| 27764 |
;(function (global, factory) {
|
| 27765 |
+
true ? factory(__webpack_require__(297)) :
|
| 27766 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27767 |
factory(global.moment)
|
| 27768 |
}(this, (function (moment) { 'use strict';
|
| 27779 |
longDateFormat : {
|
| 27780 |
LT : 'H:mm',
|
| 27781 |
LTS : 'H:mm:ss',
|
| 27782 |
+
L : 'DD/MM/YYYY',
|
| 27783 |
LL : 'D MMMM YYYY',
|
| 27784 |
LLL : 'D MMMM YYYY เวลา H:mm',
|
| 27785 |
LLLL : 'วันddddที่ D MMMM YYYY เวลา H:mm'
|
| 27826 |
|
| 27827 |
|
| 27828 |
/***/ },
|
| 27829 |
+
/* 399 */
|
| 27830 |
/***/ function(module, exports, __webpack_require__) {
|
| 27831 |
|
| 27832 |
//! moment.js locale configuration
|
| 27834 |
//! author : Dan Hagman : https://github.com/hagmandan
|
| 27835 |
|
| 27836 |
;(function (global, factory) {
|
| 27837 |
+
true ? factory(__webpack_require__(297)) :
|
| 27838 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27839 |
factory(global.moment)
|
| 27840 |
}(this, (function (moment) { 'use strict';
|
| 27877 |
y : 'isang taon',
|
| 27878 |
yy : '%d taon'
|
| 27879 |
},
|
| 27880 |
+
dayOfMonthOrdinalParse: /\d{1,2}/,
|
| 27881 |
ordinal : function (number) {
|
| 27882 |
return number;
|
| 27883 |
},
|
| 27893 |
|
| 27894 |
|
| 27895 |
/***/ },
|
| 27896 |
+
/* 400 */
|
| 27897 |
/***/ function(module, exports, __webpack_require__) {
|
| 27898 |
|
| 27899 |
//! moment.js locale configuration
|
| 27901 |
//! author : Dominika Kruk : https://github.com/amaranthrose
|
| 27902 |
|
| 27903 |
;(function (global, factory) {
|
| 27904 |
+
true ? factory(__webpack_require__(297)) :
|
| 27905 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 27906 |
factory(global.moment)
|
| 27907 |
}(this, (function (moment) { 'use strict';
|
| 28004 |
y : 'wa’ DIS',
|
| 28005 |
yy : translate
|
| 28006 |
},
|
| 28007 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 28008 |
ordinal : '%d.',
|
| 28009 |
week : {
|
| 28010 |
dow : 1, // Monday is the first day of the week.
|
| 28018 |
|
| 28019 |
|
| 28020 |
/***/ },
|
| 28021 |
+
/* 401 */
|
| 28022 |
/***/ function(module, exports, __webpack_require__) {
|
| 28023 |
|
| 28024 |
//! moment.js locale configuration
|
| 28027 |
//! Burak Yiğit Kaya: https://github.com/BYK
|
| 28028 |
|
| 28029 |
;(function (global, factory) {
|
| 28030 |
+
true ? factory(__webpack_require__(297)) :
|
| 28031 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28032 |
factory(global.moment)
|
| 28033 |
}(this, (function (moment) { 'use strict';
|
| 28091 |
y : 'bir yıl',
|
| 28092 |
yy : '%d yıl'
|
| 28093 |
},
|
| 28094 |
+
dayOfMonthOrdinalParse: /\d{1,2}'(inci|nci|üncü|ncı|uncu|ıncı)/,
|
| 28095 |
ordinal : function (number) {
|
| 28096 |
if (number === 0) { // special case for zero
|
| 28097 |
return number + '\'ıncı';
|
| 28113 |
|
| 28114 |
|
| 28115 |
/***/ },
|
| 28116 |
+
/* 402 */
|
| 28117 |
/***/ function(module, exports, __webpack_require__) {
|
| 28118 |
|
| 28119 |
//! moment.js locale configuration
|
| 28122 |
//! author : Iustì Canun
|
| 28123 |
|
| 28124 |
;(function (global, factory) {
|
| 28125 |
+
true ? factory(__webpack_require__(297)) :
|
| 28126 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28127 |
factory(global.moment)
|
| 28128 |
}(this, (function (moment) { 'use strict';
|
| 28178 |
y : processRelativeTime,
|
| 28179 |
yy : processRelativeTime
|
| 28180 |
},
|
| 28181 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 28182 |
ordinal : '%d.',
|
| 28183 |
week : {
|
| 28184 |
dow : 1, // Monday is the first day of the week.
|
| 28209 |
|
| 28210 |
|
| 28211 |
/***/ },
|
| 28212 |
+
/* 403 */
|
| 28213 |
/***/ function(module, exports, __webpack_require__) {
|
| 28214 |
|
| 28215 |
//! moment.js locale configuration
|
| 28217 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 28218 |
|
| 28219 |
;(function (global, factory) {
|
| 28220 |
+
true ? factory(__webpack_require__(297)) :
|
| 28221 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28222 |
factory(global.moment)
|
| 28223 |
}(this, (function (moment) { 'use strict';
|
| 28272 |
|
| 28273 |
|
| 28274 |
/***/ },
|
| 28275 |
+
/* 404 */
|
| 28276 |
/***/ function(module, exports, __webpack_require__) {
|
| 28277 |
|
| 28278 |
//! moment.js locale configuration
|
| 28280 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 28281 |
|
| 28282 |
;(function (global, factory) {
|
| 28283 |
+
true ? factory(__webpack_require__(297)) :
|
| 28284 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28285 |
factory(global.moment)
|
| 28286 |
}(this, (function (moment) { 'use strict';
|
| 28335 |
|
| 28336 |
|
| 28337 |
/***/ },
|
| 28338 |
+
/* 405 */
|
| 28339 |
/***/ function(module, exports, __webpack_require__) {
|
| 28340 |
|
| 28341 |
//! moment.js locale configuration
|
| 28344 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 28345 |
|
| 28346 |
;(function (global, factory) {
|
| 28347 |
+
true ? factory(__webpack_require__(297)) :
|
| 28348 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28349 |
factory(global.moment)
|
| 28350 |
}(this, (function (moment) { 'use strict';
|
| 28377 |
'nominative': 'неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота'.split('_'),
|
| 28378 |
'accusative': 'неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу'.split('_'),
|
| 28379 |
'genitive': 'неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи'.split('_')
|
| 28380 |
+
};
|
| 28381 |
+
|
| 28382 |
+
if (!m) {
|
| 28383 |
+
return weekdays['nominative'];
|
| 28384 |
+
}
|
| 28385 |
+
|
| 28386 |
+
var nounCase = (/(\[[ВвУу]\]) ?dddd/).test(format) ?
|
| 28387 |
'accusative' :
|
| 28388 |
((/\[?(?:минулої|наступної)? ?\] ?dddd/).test(format) ?
|
| 28389 |
'genitive' :
|
| 28464 |
return 'вечора';
|
| 28465 |
}
|
| 28466 |
},
|
| 28467 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(й|го)/,
|
| 28468 |
ordinal: function (number, period) {
|
| 28469 |
switch (period) {
|
| 28470 |
case 'M':
|
| 28491 |
|
| 28492 |
|
| 28493 |
/***/ },
|
| 28494 |
+
/* 406 */
|
| 28495 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 28496 |
+
|
| 28497 |
+
//! moment.js locale configuration
|
| 28498 |
+
//! locale : Urdu [ur]
|
| 28499 |
+
//! author : Sawood Alam : https://github.com/ibnesayeed
|
| 28500 |
+
//! author : Zack : https://github.com/ZackVision
|
| 28501 |
+
|
| 28502 |
+
;(function (global, factory) {
|
| 28503 |
+
true ? factory(__webpack_require__(297)) :
|
| 28504 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28505 |
+
factory(global.moment)
|
| 28506 |
+
}(this, (function (moment) { 'use strict';
|
| 28507 |
+
|
| 28508 |
+
|
| 28509 |
+
var months = [
|
| 28510 |
+
'جنوری',
|
| 28511 |
+
'فروری',
|
| 28512 |
+
'مارچ',
|
| 28513 |
+
'اپریل',
|
| 28514 |
+
'مئی',
|
| 28515 |
+
'جون',
|
| 28516 |
+
'جولائی',
|
| 28517 |
+
'اگست',
|
| 28518 |
+
'ستمبر',
|
| 28519 |
+
'اکتوبر',
|
| 28520 |
+
'نومبر',
|
| 28521 |
+
'دسمبر'
|
| 28522 |
+
];
|
| 28523 |
+
var days = [
|
| 28524 |
+
'اتوار',
|
| 28525 |
+
'پیر',
|
| 28526 |
+
'منگل',
|
| 28527 |
+
'بدھ',
|
| 28528 |
+
'جمعرات',
|
| 28529 |
+
'جمعہ',
|
| 28530 |
+
'ہفتہ'
|
| 28531 |
+
];
|
| 28532 |
+
|
| 28533 |
+
var ur = moment.defineLocale('ur', {
|
| 28534 |
+
months : months,
|
| 28535 |
+
monthsShort : months,
|
| 28536 |
+
weekdays : days,
|
| 28537 |
+
weekdaysShort : days,
|
| 28538 |
+
weekdaysMin : days,
|
| 28539 |
+
longDateFormat : {
|
| 28540 |
+
LT : 'HH:mm',
|
| 28541 |
+
LTS : 'HH:mm:ss',
|
| 28542 |
+
L : 'DD/MM/YYYY',
|
| 28543 |
+
LL : 'D MMMM YYYY',
|
| 28544 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 28545 |
+
LLLL : 'dddd، D MMMM YYYY HH:mm'
|
| 28546 |
+
},
|
| 28547 |
+
meridiemParse: /صبح|شام/,
|
| 28548 |
+
isPM : function (input) {
|
| 28549 |
+
return 'شام' === input;
|
| 28550 |
+
},
|
| 28551 |
+
meridiem : function (hour, minute, isLower) {
|
| 28552 |
+
if (hour < 12) {
|
| 28553 |
+
return 'صبح';
|
| 28554 |
+
}
|
| 28555 |
+
return 'شام';
|
| 28556 |
+
},
|
| 28557 |
+
calendar : {
|
| 28558 |
+
sameDay : '[آج بوقت] LT',
|
| 28559 |
+
nextDay : '[کل بوقت] LT',
|
| 28560 |
+
nextWeek : 'dddd [بوقت] LT',
|
| 28561 |
+
lastDay : '[گذشتہ روز بوقت] LT',
|
| 28562 |
+
lastWeek : '[گذشتہ] dddd [بوقت] LT',
|
| 28563 |
+
sameElse : 'L'
|
| 28564 |
+
},
|
| 28565 |
+
relativeTime : {
|
| 28566 |
+
future : '%s بعد',
|
| 28567 |
+
past : '%s قبل',
|
| 28568 |
+
s : 'چند سیکنڈ',
|
| 28569 |
+
m : 'ایک منٹ',
|
| 28570 |
+
mm : '%d منٹ',
|
| 28571 |
+
h : 'ایک گھنٹہ',
|
| 28572 |
+
hh : '%d گھنٹے',
|
| 28573 |
+
d : 'ایک دن',
|
| 28574 |
+
dd : '%d دن',
|
| 28575 |
+
M : 'ایک ماہ',
|
| 28576 |
+
MM : '%d ماہ',
|
| 28577 |
+
y : 'ایک سال',
|
| 28578 |
+
yy : '%d سال'
|
| 28579 |
+
},
|
| 28580 |
+
preparse: function (string) {
|
| 28581 |
+
return string.replace(/،/g, ',');
|
| 28582 |
+
},
|
| 28583 |
+
postformat: function (string) {
|
| 28584 |
+
return string.replace(/,/g, '،');
|
| 28585 |
+
},
|
| 28586 |
+
week : {
|
| 28587 |
+
dow : 1, // Monday is the first day of the week.
|
| 28588 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 28589 |
+
}
|
| 28590 |
+
});
|
| 28591 |
+
|
| 28592 |
+
return ur;
|
| 28593 |
+
|
| 28594 |
+
})));
|
| 28595 |
+
|
| 28596 |
+
|
| 28597 |
+
/***/ },
|
| 28598 |
+
/* 407 */
|
| 28599 |
/***/ function(module, exports, __webpack_require__) {
|
| 28600 |
|
| 28601 |
//! moment.js locale configuration
|
| 28603 |
//! author : Sardor Muminov : https://github.com/muminoff
|
| 28604 |
|
| 28605 |
;(function (global, factory) {
|
| 28606 |
+
true ? factory(__webpack_require__(297)) :
|
| 28607 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28608 |
factory(global.moment)
|
| 28609 |
}(this, (function (moment) { 'use strict';
|
| 28658 |
|
| 28659 |
|
| 28660 |
/***/ },
|
| 28661 |
+
/* 408 */
|
| 28662 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 28663 |
+
|
| 28664 |
+
//! moment.js locale configuration
|
| 28665 |
+
//! locale : Uzbek Latin [uz-latn]
|
| 28666 |
+
//! author : Rasulbek Mirzayev : github.com/Rasulbeeek
|
| 28667 |
+
|
| 28668 |
+
;(function (global, factory) {
|
| 28669 |
+
true ? factory(__webpack_require__(297)) :
|
| 28670 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28671 |
+
factory(global.moment)
|
| 28672 |
+
}(this, (function (moment) { 'use strict';
|
| 28673 |
+
|
| 28674 |
+
|
| 28675 |
+
var uzLatn = moment.defineLocale('uz-latn', {
|
| 28676 |
+
months : 'Yanvar_Fevral_Mart_Aprel_May_Iyun_Iyul_Avgust_Sentabr_Oktabr_Noyabr_Dekabr'.split('_'),
|
| 28677 |
+
monthsShort : 'Yan_Fev_Mar_Apr_May_Iyun_Iyul_Avg_Sen_Okt_Noy_Dek'.split('_'),
|
| 28678 |
+
weekdays : 'Yakshanba_Dushanba_Seshanba_Chorshanba_Payshanba_Juma_Shanba'.split('_'),
|
| 28679 |
+
weekdaysShort : 'Yak_Dush_Sesh_Chor_Pay_Jum_Shan'.split('_'),
|
| 28680 |
+
weekdaysMin : 'Ya_Du_Se_Cho_Pa_Ju_Sha'.split('_'),
|
| 28681 |
+
longDateFormat : {
|
| 28682 |
+
LT : 'HH:mm',
|
| 28683 |
+
LTS : 'HH:mm:ss',
|
| 28684 |
+
L : 'DD/MM/YYYY',
|
| 28685 |
+
LL : 'D MMMM YYYY',
|
| 28686 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 28687 |
+
LLLL : 'D MMMM YYYY, dddd HH:mm'
|
| 28688 |
+
},
|
| 28689 |
+
calendar : {
|
| 28690 |
+
sameDay : '[Bugun soat] LT [da]',
|
| 28691 |
+
nextDay : '[Ertaga] LT [da]',
|
| 28692 |
+
nextWeek : 'dddd [kuni soat] LT [da]',
|
| 28693 |
+
lastDay : '[Kecha soat] LT [da]',
|
| 28694 |
+
lastWeek : '[O\'tgan] dddd [kuni soat] LT [da]',
|
| 28695 |
+
sameElse : 'L'
|
| 28696 |
+
},
|
| 28697 |
+
relativeTime : {
|
| 28698 |
+
future : 'Yaqin %s ichida',
|
| 28699 |
+
past : 'Bir necha %s oldin',
|
| 28700 |
+
s : 'soniya',
|
| 28701 |
+
m : 'bir daqiqa',
|
| 28702 |
+
mm : '%d daqiqa',
|
| 28703 |
+
h : 'bir soat',
|
| 28704 |
+
hh : '%d soat',
|
| 28705 |
+
d : 'bir kun',
|
| 28706 |
+
dd : '%d kun',
|
| 28707 |
+
M : 'bir oy',
|
| 28708 |
+
MM : '%d oy',
|
| 28709 |
+
y : 'bir yil',
|
| 28710 |
+
yy : '%d yil'
|
| 28711 |
+
},
|
| 28712 |
+
week : {
|
| 28713 |
+
dow : 1, // Monday is the first day of the week.
|
| 28714 |
+
doy : 7 // The week that contains Jan 1st is the first week of the year.
|
| 28715 |
+
}
|
| 28716 |
+
});
|
| 28717 |
+
|
| 28718 |
+
return uzLatn;
|
| 28719 |
+
|
| 28720 |
+
})));
|
| 28721 |
+
|
| 28722 |
+
|
| 28723 |
+
/***/ },
|
| 28724 |
+
/* 409 */
|
| 28725 |
/***/ function(module, exports, __webpack_require__) {
|
| 28726 |
|
| 28727 |
//! moment.js locale configuration
|
| 28729 |
//! author : Bang Nguyen : https://github.com/bangnk
|
| 28730 |
|
| 28731 |
;(function (global, factory) {
|
| 28732 |
+
true ? factory(__webpack_require__(297)) :
|
| 28733 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28734 |
factory(global.moment)
|
| 28735 |
}(this, (function (moment) { 'use strict';
|
| 28789 |
y : 'một năm',
|
| 28790 |
yy : '%d năm'
|
| 28791 |
},
|
| 28792 |
+
dayOfMonthOrdinalParse: /\d{1,2}/,
|
| 28793 |
ordinal : function (number) {
|
| 28794 |
return number;
|
| 28795 |
},
|
| 28805 |
|
| 28806 |
|
| 28807 |
/***/ },
|
| 28808 |
+
/* 410 */
|
| 28809 |
/***/ function(module, exports, __webpack_require__) {
|
| 28810 |
|
| 28811 |
//! moment.js locale configuration
|
| 28813 |
//! author : Andrew Hood : https://github.com/andrewhood125
|
| 28814 |
|
| 28815 |
;(function (global, factory) {
|
| 28816 |
+
true ? factory(__webpack_require__(297)) :
|
| 28817 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28818 |
factory(global.moment)
|
| 28819 |
}(this, (function (moment) { 'use strict';
|
| 28857 |
y : 'á ~ýéár',
|
| 28858 |
yy : '%d ý~éárs'
|
| 28859 |
},
|
| 28860 |
+
dayOfMonthOrdinalParse: /\d{1,2}(th|st|nd|rd)/,
|
| 28861 |
ordinal : function (number) {
|
| 28862 |
var b = number % 10,
|
| 28863 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 28878 |
|
| 28879 |
|
| 28880 |
/***/ },
|
| 28881 |
+
/* 411 */
|
| 28882 |
/***/ function(module, exports, __webpack_require__) {
|
| 28883 |
|
| 28884 |
//! moment.js locale configuration
|
| 28886 |
//! author : Atolagbe Abisoye : https://github.com/andela-batolagbe
|
| 28887 |
|
| 28888 |
;(function (global, factory) {
|
| 28889 |
+
true ? factory(__webpack_require__(297)) :
|
| 28890 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28891 |
factory(global.moment)
|
| 28892 |
}(this, (function (moment) { 'use strict';
|
| 28929 |
y : 'ọdún kan',
|
| 28930 |
yy : 'ọdún %d'
|
| 28931 |
},
|
| 28932 |
+
dayOfMonthOrdinalParse : /ọjọ́\s\d{1,2}/,
|
| 28933 |
ordinal : 'ọjọ́ %d',
|
| 28934 |
week : {
|
| 28935 |
dow : 1, // Monday is the first day of the week.
|
| 28943 |
|
| 28944 |
|
| 28945 |
/***/ },
|
| 28946 |
+
/* 412 */
|
| 28947 |
/***/ function(module, exports, __webpack_require__) {
|
| 28948 |
|
| 28949 |
//! moment.js locale configuration
|
| 28952 |
//! author : Zeno Zeng : https://github.com/zenozeng
|
| 28953 |
|
| 28954 |
;(function (global, factory) {
|
| 28955 |
+
true ? factory(__webpack_require__(297)) :
|
| 28956 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 28957 |
factory(global.moment)
|
| 28958 |
}(this, (function (moment) { 'use strict';
|
| 28965 |
weekdaysShort : '周日_周一_周二_周三_周四_周五_周六'.split('_'),
|
| 28966 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 28967 |
longDateFormat : {
|
| 28968 |
+
LT : 'HH:mm',
|
| 28969 |
+
LTS : 'HH:mm:ss',
|
| 28970 |
+
L : 'YYYY年MMMD日',
|
| 28971 |
LL : 'YYYY年MMMD日',
|
| 28972 |
LLL : 'YYYY年MMMD日Ah点mm分',
|
| 28973 |
LLLL : 'YYYY年MMMD日ddddAh点mm分',
|
| 28974 |
+
l : 'YYYY年MMMD日',
|
| 28975 |
ll : 'YYYY年MMMD日',
|
| 28976 |
+
lll : 'YYYY年MMMD日 HH:mm',
|
| 28977 |
+
llll : 'YYYY年MMMD日dddd HH:mm'
|
| 28978 |
},
|
| 28979 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 28980 |
meridiemHour: function (hour, meridiem) {
|
| 29008 |
}
|
| 29009 |
},
|
| 29010 |
calendar : {
|
| 29011 |
+
sameDay : '[今天]LT',
|
| 29012 |
+
nextDay : '[明天]LT',
|
| 29013 |
+
nextWeek : '[下]ddddLT',
|
| 29014 |
+
lastDay : '[昨天]LT',
|
| 29015 |
+
lastWeek : '[上]ddddLT',
|
| 29016 |
+
sameElse : 'L'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29017 |
},
|
| 29018 |
+
dayOfMonthOrdinalParse: /\d{1,2}(日|月|周)/,
|
| 29019 |
ordinal : function (number, period) {
|
| 29020 |
switch (period) {
|
| 29021 |
case 'd':
|
| 29059 |
|
| 29060 |
|
| 29061 |
/***/ },
|
| 29062 |
+
/* 413 */
|
| 29063 |
/***/ function(module, exports, __webpack_require__) {
|
| 29064 |
|
| 29065 |
//! moment.js locale configuration
|
| 29069 |
//! author : Konstantin : https://github.com/skfd
|
| 29070 |
|
| 29071 |
;(function (global, factory) {
|
| 29072 |
+
true ? factory(__webpack_require__(297)) :
|
| 29073 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 29074 |
factory(global.moment)
|
| 29075 |
}(this, (function (moment) { 'use strict';
|
| 29082 |
weekdaysShort : '週日_週一_週二_週三_週四_週五_週六'.split('_'),
|
| 29083 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 29084 |
longDateFormat : {
|
| 29085 |
+
LT : 'HH:mm',
|
| 29086 |
+
LTS : 'HH:mm:ss',
|
| 29087 |
L : 'YYYY年MMMD日',
|
| 29088 |
LL : 'YYYY年MMMD日',
|
| 29089 |
+
LLL : 'YYYY年MMMD日 HH:mm',
|
| 29090 |
+
LLLL : 'YYYY年MMMD日dddd HH:mm',
|
| 29091 |
l : 'YYYY年MMMD日',
|
| 29092 |
ll : 'YYYY年MMMD日',
|
| 29093 |
+
lll : 'YYYY年MMMD日 HH:mm',
|
| 29094 |
+
llll : 'YYYY年MMMD日dddd HH:mm'
|
| 29095 |
},
|
| 29096 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 29097 |
meridiemHour : function (hour, meridiem) {
|
| 29130 |
lastWeek : '[上]ddddLT',
|
| 29131 |
sameElse : 'L'
|
| 29132 |
},
|
| 29133 |
+
dayOfMonthOrdinalParse: /\d{1,2}(日|月|週)/,
|
| 29134 |
ordinal : function (number, period) {
|
| 29135 |
switch (period) {
|
| 29136 |
case 'd' :
|
| 29169 |
|
| 29170 |
|
| 29171 |
/***/ },
|
| 29172 |
+
/* 414 */
|
| 29173 |
/***/ function(module, exports, __webpack_require__) {
|
| 29174 |
|
| 29175 |
//! moment.js locale configuration
|
| 29178 |
//! author : Chris Lam : https://github.com/hehachris
|
| 29179 |
|
| 29180 |
;(function (global, factory) {
|
| 29181 |
+
true ? factory(__webpack_require__(297)) :
|
| 29182 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 29183 |
factory(global.moment)
|
| 29184 |
}(this, (function (moment) { 'use strict';
|
| 29191 |
weekdaysShort : '週日_週一_週二_週三_週四_週五_週六'.split('_'),
|
| 29192 |
weekdaysMin : '日_一_二_三_四_五_六'.split('_'),
|
| 29193 |
longDateFormat : {
|
| 29194 |
+
LT : 'HH:mm',
|
| 29195 |
+
LTS : 'HH:mm:ss',
|
| 29196 |
L : 'YYYY年MMMD日',
|
| 29197 |
LL : 'YYYY年MMMD日',
|
| 29198 |
+
LLL : 'YYYY年MMMD日 HH:mm',
|
| 29199 |
+
LLLL : 'YYYY年MMMD日dddd HH:mm',
|
| 29200 |
l : 'YYYY年MMMD日',
|
| 29201 |
ll : 'YYYY年MMMD日',
|
| 29202 |
+
lll : 'YYYY年MMMD日 HH:mm',
|
| 29203 |
+
llll : 'YYYY年MMMD日dddd HH:mm'
|
| 29204 |
},
|
| 29205 |
meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
|
| 29206 |
meridiemHour : function (hour, meridiem) {
|
| 29239 |
lastWeek : '[上]ddddLT',
|
| 29240 |
sameElse : 'L'
|
| 29241 |
},
|
| 29242 |
+
dayOfMonthOrdinalParse: /\d{1,2}(日|月|週)/,
|
| 29243 |
ordinal : function (number, period) {
|
| 29244 |
switch (period) {
|
| 29245 |
case 'd' :
|
| 29278 |
|
| 29279 |
|
| 29280 |
/***/ },
|
| 29281 |
+
/* 415 */,
|
| 29282 |
+
/* 416 */,
|
| 29283 |
+
/* 417 */,
|
| 29284 |
+
/* 418 */,
|
| 29285 |
+
/* 419 */,
|
| 29286 |
+
/* 420 */,
|
| 29287 |
+
/* 421 */
|
| 29288 |
/***/ function(module, exports, __webpack_require__) {
|
| 29289 |
|
| 29290 |
'use strict';
|
| 29301 |
|
| 29302 |
var _reactRouter = __webpack_require__(181);
|
| 29303 |
|
| 29304 |
+
var _history = __webpack_require__(244);
|
| 29305 |
|
| 29306 |
+
var _newslettersTypesJsx = __webpack_require__(422);
|
| 29307 |
|
| 29308 |
var _newslettersTypesJsx2 = _interopRequireDefault(_newslettersTypesJsx);
|
| 29309 |
|
| 29310 |
+
var _newslettersTemplatesJsx = __webpack_require__(424);
|
| 29311 |
|
| 29312 |
var _newslettersTemplatesJsx2 = _interopRequireDefault(_newslettersTemplatesJsx);
|
| 29313 |
|
| 29314 |
+
var _newslettersSendJsx = __webpack_require__(425);
|
| 29315 |
|
| 29316 |
var _newslettersSendJsx2 = _interopRequireDefault(_newslettersSendJsx);
|
| 29317 |
|
| 29318 |
+
var _newslettersTypesStandardJsx = __webpack_require__(434);
|
| 29319 |
|
| 29320 |
var _newslettersTypesStandardJsx2 = _interopRequireDefault(_newslettersTypesStandardJsx);
|
| 29321 |
|
| 29322 |
+
var _newslettersTypesWelcomeWelcomeJsx = __webpack_require__(435);
|
| 29323 |
|
| 29324 |
var _newslettersTypesWelcomeWelcomeJsx2 = _interopRequireDefault(_newslettersTypesWelcomeWelcomeJsx);
|
| 29325 |
|
| 29326 |
+
var _newslettersTypesNotificationNotificationJsx = __webpack_require__(436);
|
| 29327 |
|
| 29328 |
var _newslettersTypesNotificationNotificationJsx2 = _interopRequireDefault(_newslettersTypesNotificationNotificationJsx);
|
| 29329 |
|
| 29330 |
+
var _newslettersListingsStandardJsx = __webpack_require__(437);
|
| 29331 |
|
| 29332 |
var _newslettersListingsStandardJsx2 = _interopRequireDefault(_newslettersListingsStandardJsx);
|
| 29333 |
|
| 29334 |
+
var _newslettersListingsWelcomeJsx = __webpack_require__(440);
|
| 29335 |
|
| 29336 |
var _newslettersListingsWelcomeJsx2 = _interopRequireDefault(_newslettersListingsWelcomeJsx);
|
| 29337 |
|
| 29338 |
+
var _newslettersListingsNotificationJsx = __webpack_require__(441);
|
| 29339 |
|
| 29340 |
var _newslettersListingsNotificationJsx2 = _interopRequireDefault(_newslettersListingsNotificationJsx);
|
| 29341 |
|
| 29342 |
+
var _newslettersListingsNotification_historyJsx = __webpack_require__(442);
|
| 29343 |
|
| 29344 |
var _newslettersListingsNotification_historyJsx2 = _interopRequireDefault(_newslettersListingsNotification_historyJsx);
|
| 29345 |
|
| 29381 |
/* Listings */ /* Newsletter: type selection */ /* New newsletter: types */ /* Template selection */ /* Sending options */
|
| 29382 |
|
| 29383 |
/***/ },
|
| 29384 |
+
/* 422 */
|
| 29385 |
/***/ function(module, exports, __webpack_require__) {
|
| 29386 |
|
| 29387 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29388 |
|
| 29389 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(275), __webpack_require__(181), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, MailPoet, Router, Breadcrumb) {
|
| 29390 |
var NewsletterTypes = React.createClass({
|
| 29391 |
displayName: 'NewsletterTypes',
|
| 29392 |
|
| 29533 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29534 |
|
| 29535 |
/***/ },
|
| 29536 |
+
/* 423 */
|
| 29537 |
/***/ function(module, exports, __webpack_require__) {
|
| 29538 |
|
| 29539 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29540 |
|
| 29541 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, classNames, MailPoet) {
|
| 29542 |
var Link = Router.Link;
|
| 29543 |
|
| 29544 |
var Breadcrumb = React.createClass({
|
| 29601 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29602 |
|
| 29603 |
/***/ },
|
| 29604 |
+
/* 424 */
|
| 29605 |
/***/ function(module, exports, __webpack_require__) {
|
| 29606 |
|
| 29607 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29608 |
|
| 29609 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(278), __webpack_require__(275), __webpack_require__(181), __webpack_require__(276), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, _, MailPoet, Router, classNames, Breadcrumb) {
|
| 29610 |
|
| 29611 |
var ImportTemplate = React.createClass({
|
| 29612 |
displayName: 'ImportTemplate',
|
| 29873 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 29874 |
|
| 29875 |
/***/ },
|
| 29876 |
+
/* 425 */
|
| 29877 |
/***/ function(module, exports, __webpack_require__) {
|
| 29878 |
|
| 29879 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 29880 |
|
| 29881 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 29882 |
|
| 29883 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(278), __webpack_require__(275), __webpack_require__(289), __webpack_require__(426), __webpack_require__(429), __webpack_require__(432), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, _, MailPoet, Form, StandardNewsletterFields, NotificationNewsletterFields, WelcomeNewsletterFields, Breadcrumb) {
|
| 29884 |
|
| 29885 |
var NewsletterSend = React.createClass({
|
| 29886 |
displayName: 'NewsletterSend',
|
| 30119 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30120 |
|
| 30121 |
/***/ },
|
| 30122 |
+
/* 426 */
|
| 30123 |
/***/ function(module, exports, __webpack_require__) {
|
| 30124 |
|
| 30125 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30128 |
|
| 30129 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 30130 |
|
| 30131 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(274), __webpack_require__(278), __webpack_require__(275), __webpack_require__(427), __webpack_require__(295), __webpack_require__(293), __webpack_require__(291)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, jQuery, _, MailPoet, Hooks, Checkbox, Select, Text) {
|
| 30132 |
|
| 30133 |
var settings = window.mailpoet_settings || {},
|
| 30134 |
currentTime = window.mailpoet_current_time || '00:00',
|
| 30497 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30498 |
|
| 30499 |
/***/ },
|
| 30500 |
+
/* 427 */,
|
| 30501 |
+
/* 428 */,
|
| 30502 |
+
/* 429 */
|
| 30503 |
/***/ function(module, exports, __webpack_require__) {
|
| 30504 |
|
| 30505 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30506 |
|
| 30507 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(275), __webpack_require__(427), __webpack_require__(430), __webpack_require__(278)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling, _) {
|
| 30508 |
|
| 30509 |
var settings = window.mailpoet_settings || {};
|
| 30510 |
|
| 30600 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30601 |
|
| 30602 |
/***/ },
|
| 30603 |
+
/* 430 */
|
| 30604 |
/***/ function(module, exports, __webpack_require__) {
|
| 30605 |
|
| 30606 |
'use strict';
|
| 30607 |
|
| 30608 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 30609 |
|
| 30610 |
+
var _underscore = __webpack_require__(278);
|
| 30611 |
|
| 30612 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 30613 |
|
| 30615 |
|
| 30616 |
var _react2 = _interopRequireDefault(_react);
|
| 30617 |
|
| 30618 |
+
var _formFieldsSelectJsx = __webpack_require__(293);
|
| 30619 |
|
| 30620 |
var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
|
| 30621 |
|
| 30622 |
+
var _newslettersSchedulingCommonJsx = __webpack_require__(431);
|
| 30623 |
|
| 30624 |
var intervalField = {
|
| 30625 |
name: 'intervalType',
|
| 30733 |
module.exports = NotificationScheduling;
|
| 30734 |
|
| 30735 |
/***/ },
|
| 30736 |
+
/* 431 */
|
| 30737 |
/***/ function(module, exports, __webpack_require__) {
|
| 30738 |
|
| 30739 |
'use strict';
|
| 30744 |
|
| 30745 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 30746 |
|
| 30747 |
+
var _underscore = __webpack_require__(278);
|
| 30748 |
|
| 30749 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 30750 |
|
| 30751 |
+
var _mailpoet = __webpack_require__(275);
|
| 30752 |
|
| 30753 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 30754 |
|
| 30827 |
exports.nthWeekDayValues = _nthWeekDayValues;
|
| 30828 |
|
| 30829 |
/***/ },
|
| 30830 |
+
/* 432 */
|
| 30831 |
/***/ function(module, exports, __webpack_require__) {
|
| 30832 |
|
| 30833 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 30834 |
|
| 30835 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(275), __webpack_require__(427), __webpack_require__(433)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling) {
|
| 30836 |
|
| 30837 |
var settings = window.mailpoet_settings || {};
|
| 30838 |
|
| 30901 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 30902 |
|
| 30903 |
/***/ },
|
| 30904 |
+
/* 433 */
|
| 30905 |
/***/ function(module, exports, __webpack_require__) {
|
| 30906 |
|
| 30907 |
'use strict';
|
| 30908 |
|
| 30909 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
|
| 30910 |
|
| 30911 |
+
var _underscore = __webpack_require__(278);
|
| 30912 |
|
| 30913 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 30914 |
|
| 30916 |
|
| 30917 |
var _react2 = _interopRequireDefault(_react);
|
| 30918 |
|
| 30919 |
+
var _mailpoet = __webpack_require__(275);
|
| 30920 |
|
| 30921 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 30922 |
|
| 30923 |
+
var _formFieldsSelectJsx = __webpack_require__(293);
|
| 30924 |
|
| 30925 |
var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
|
| 30926 |
|
| 30927 |
+
var _formFieldsTextJsx = __webpack_require__(291);
|
| 30928 |
|
| 30929 |
var _formFieldsTextJsx2 = _interopRequireDefault(_formFieldsTextJsx);
|
| 30930 |
|
| 30931 |
+
var _newslettersSchedulingCommonJsx = __webpack_require__(431);
|
| 30932 |
|
| 30933 |
var availableRoles = window.mailpoet_roles || {};
|
| 30934 |
var availableSegments = _underscore2['default'].filter(window.mailpoet_segments || [], function (segment) {
|
| 31073 |
module.exports = WelcomeScheduling;
|
| 31074 |
|
| 31075 |
/***/ },
|
| 31076 |
+
/* 434 */
|
| 31077 |
/***/ function(module, exports, __webpack_require__) {
|
| 31078 |
|
| 31079 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 31080 |
|
| 31081 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(275), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Breadcrumb) {
|
| 31082 |
|
| 31083 |
var NewsletterStandard = React.createClass({
|
| 31084 |
displayName: 'NewsletterStandard',
|
| 31127 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 31128 |
|
| 31129 |
/***/ },
|
| 31130 |
+
/* 435 */
|
| 31131 |
/***/ function(module, exports, __webpack_require__) {
|
| 31132 |
|
| 31133 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 31134 |
|
| 31135 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(278), __webpack_require__(2), __webpack_require__(181), __webpack_require__(275), __webpack_require__(433), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (_, React, Router, MailPoet, Scheduling, Breadcrumb) {
|
| 31136 |
|
| 31137 |
var field = {
|
| 31138 |
name: 'options',
|
| 31229 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 31230 |
|
| 31231 |
/***/ },
|
| 31232 |
+
/* 436 */
|
| 31233 |
/***/ function(module, exports, __webpack_require__) {
|
| 31234 |
|
| 31235 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 31236 |
|
| 31237 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(278), __webpack_require__(2), __webpack_require__(181), __webpack_require__(275), __webpack_require__(430), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (_, React, Router, MailPoet, Scheduling, Breadcrumb) {
|
| 31238 |
|
| 31239 |
var field = {
|
| 31240 |
name: 'options',
|
| 31323 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 31324 |
|
| 31325 |
/***/ },
|
| 31326 |
+
/* 437 */
|
| 31327 |
/***/ function(module, exports, __webpack_require__) {
|
| 31328 |
|
| 31329 |
'use strict';
|
| 31336 |
|
| 31337 |
var _reactRouter = __webpack_require__(181);
|
| 31338 |
|
| 31339 |
+
var _classnames = __webpack_require__(276);
|
| 31340 |
|
| 31341 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31342 |
|
| 31343 |
+
var _jquery = __webpack_require__(274);
|
| 31344 |
|
| 31345 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31346 |
|
| 31347 |
+
var _mailpoet = __webpack_require__(275);
|
| 31348 |
|
| 31349 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31350 |
|
| 31351 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 31352 |
|
| 31353 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 31354 |
|
| 31355 |
+
var _newslettersListingsTabsJsx = __webpack_require__(438);
|
| 31356 |
|
| 31357 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 31358 |
|
| 31359 |
+
var _newslettersListingsMixinsJsx = __webpack_require__(439);
|
| 31360 |
|
| 31361 |
var mailpoet_tracking_enabled = !!window['mailpoet_tracking_enabled'];
|
| 31362 |
var mailpoet_settings = window.mailpoet_settings || {};
|
| 31563 |
module.exports = NewsletterListStandard;
|
| 31564 |
|
| 31565 |
/***/ },
|
| 31566 |
+
/* 438 */
|
| 31567 |
/***/ function(module, exports, __webpack_require__) {
|
| 31568 |
|
| 31569 |
'use strict';
|
| 31576 |
|
| 31577 |
var _reactRouter = __webpack_require__(181);
|
| 31578 |
|
| 31579 |
+
var _classnames = __webpack_require__(276);
|
| 31580 |
|
| 31581 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31582 |
|
| 31583 |
+
var _mailpoet = __webpack_require__(275);
|
| 31584 |
|
| 31585 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31586 |
|
| 31633 |
module.exports = ListingTabs;
|
| 31634 |
|
| 31635 |
/***/ },
|
| 31636 |
+
/* 439 */
|
| 31637 |
/***/ function(module, exports, __webpack_require__) {
|
| 31638 |
|
| 31639 |
'use strict';
|
| 31652 |
|
| 31653 |
var _reactDom2 = _interopRequireDefault(_reactDom);
|
| 31654 |
|
| 31655 |
+
var _reactStringReplace = __webpack_require__(415);
|
| 31656 |
|
| 31657 |
var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
|
| 31658 |
|
| 31659 |
+
var _mailpoet = __webpack_require__(275);
|
| 31660 |
|
| 31661 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31662 |
|
| 31663 |
+
var _classnames = __webpack_require__(276);
|
| 31664 |
|
| 31665 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31666 |
|
| 31667 |
+
var _jquery = __webpack_require__(274);
|
| 31668 |
|
| 31669 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31670 |
|
| 31918 |
exports.MailerMixin = _MailerMixin;
|
| 31919 |
|
| 31920 |
/***/ },
|
| 31921 |
+
/* 440 */
|
| 31922 |
/***/ function(module, exports, __webpack_require__) {
|
| 31923 |
|
| 31924 |
'use strict';
|
| 31931 |
|
| 31932 |
var _reactRouter = __webpack_require__(181);
|
| 31933 |
|
| 31934 |
+
var _history = __webpack_require__(244);
|
| 31935 |
|
| 31936 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 31937 |
|
| 31938 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 31939 |
|
| 31940 |
+
var _newslettersListingsTabsJsx = __webpack_require__(438);
|
| 31941 |
|
| 31942 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 31943 |
|
| 31944 |
+
var _newslettersListingsMixinsJsx = __webpack_require__(439);
|
| 31945 |
|
| 31946 |
+
var _classnames = __webpack_require__(276);
|
| 31947 |
|
| 31948 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 31949 |
|
| 31950 |
+
var _jquery = __webpack_require__(274);
|
| 31951 |
|
| 31952 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 31953 |
|
| 31954 |
+
var _mailpoet = __webpack_require__(275);
|
| 31955 |
|
| 31956 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 31957 |
|
| 31958 |
+
var _underscore = __webpack_require__(278);
|
| 31959 |
|
| 31960 |
var _underscore2 = _interopRequireDefault(_underscore);
|
| 31961 |
|
| 32317 |
module.exports = NewsletterListWelcome;
|
| 32318 |
|
| 32319 |
/***/ },
|
| 32320 |
+
/* 441 */
|
| 32321 |
/***/ function(module, exports, __webpack_require__) {
|
| 32322 |
|
| 32323 |
'use strict';
|
| 32330 |
|
| 32331 |
var _reactRouter = __webpack_require__(181);
|
| 32332 |
|
| 32333 |
+
var _history = __webpack_require__(244);
|
| 32334 |
|
| 32335 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 32336 |
|
| 32337 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 32338 |
|
| 32339 |
+
var _newslettersListingsTabsJsx = __webpack_require__(438);
|
| 32340 |
|
| 32341 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 32342 |
|
| 32343 |
+
var _newslettersListingsMixinsJsx = __webpack_require__(439);
|
| 32344 |
|
| 32345 |
+
var _classnames = __webpack_require__(276);
|
| 32346 |
|
| 32347 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 32348 |
|
| 32349 |
+
var _jquery = __webpack_require__(274);
|
| 32350 |
|
| 32351 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 32352 |
|
| 32353 |
+
var _mailpoet = __webpack_require__(275);
|
| 32354 |
|
| 32355 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 32356 |
|
| 32357 |
+
var _newslettersSchedulingCommonJsx = __webpack_require__(431);
|
| 32358 |
|
| 32359 |
var mailpoet_settings = window.mailpoet_settings || {};
|
| 32360 |
|
| 32669 |
module.exports = NewsletterListNotification;
|
| 32670 |
|
| 32671 |
/***/ },
|
| 32672 |
+
/* 442 */
|
| 32673 |
/***/ function(module, exports, __webpack_require__) {
|
| 32674 |
|
| 32675 |
'use strict';
|
| 32682 |
|
| 32683 |
var _reactRouter = __webpack_require__(181);
|
| 32684 |
|
| 32685 |
+
var _classnames = __webpack_require__(276);
|
| 32686 |
|
| 32687 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 32688 |
|
| 32689 |
+
var _jquery = __webpack_require__(274);
|
| 32690 |
|
| 32691 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 32692 |
|
| 32693 |
+
var _mailpoet = __webpack_require__(275);
|
| 32694 |
|
| 32695 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 32696 |
|
| 32697 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 32698 |
|
| 32699 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 32700 |
|
| 32701 |
+
var _newslettersListingsTabsJsx = __webpack_require__(438);
|
| 32702 |
|
| 32703 |
var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
|
| 32704 |
|
| 32705 |
+
var _newslettersListingsMixinsJsx = __webpack_require__(439);
|
| 32706 |
|
| 32707 |
var mailpoet_tracking_enabled = !!window['mailpoet_tracking_enabled'];
|
| 32708 |
var mailpoet_settings = window.mailpoet_settings || {};
|
| 32841 |
module.exports = NewsletterListNotificationHistory;
|
| 32842 |
|
| 32843 |
/***/ },
|
| 32844 |
+
/* 443 */
|
| 32845 |
/***/ function(module, exports, __webpack_require__) {
|
| 32846 |
|
| 32847 |
'use strict';
|
| 32858 |
|
| 32859 |
var _reactRouter = __webpack_require__(181);
|
| 32860 |
|
| 32861 |
+
var _history = __webpack_require__(244);
|
| 32862 |
|
| 32863 |
+
var _segmentsListJsx = __webpack_require__(444);
|
| 32864 |
|
| 32865 |
var _segmentsListJsx2 = _interopRequireDefault(_segmentsListJsx);
|
| 32866 |
|
| 32867 |
+
var _segmentsFormJsx = __webpack_require__(445);
|
| 32868 |
|
| 32869 |
var _segmentsFormJsx2 = _interopRequireDefault(_segmentsFormJsx);
|
| 32870 |
|
| 32896 |
}
|
| 32897 |
|
| 32898 |
/***/ },
|
| 32899 |
+
/* 444 */
|
| 32900 |
/***/ function(module, exports, __webpack_require__) {
|
| 32901 |
|
| 32902 |
'use strict';
|
| 32909 |
|
| 32910 |
var _reactRouter = __webpack_require__(181);
|
| 32911 |
|
| 32912 |
+
var _jquery = __webpack_require__(274);
|
| 32913 |
|
| 32914 |
var _jquery2 = _interopRequireDefault(_jquery);
|
| 32915 |
|
| 32916 |
+
var _mailpoet = __webpack_require__(275);
|
| 32917 |
|
| 32918 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 32919 |
|
| 32920 |
+
var _classnames = __webpack_require__(276);
|
| 32921 |
|
| 32922 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 32923 |
|
| 32924 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 32925 |
|
| 32926 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 32927 |
|
| 33212 |
module.exports = SegmentList;
|
| 33213 |
|
| 33214 |
/***/ },
|
| 33215 |
+
/* 445 */
|
| 33216 |
/***/ function(module, exports, __webpack_require__) {
|
| 33217 |
|
| 33218 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
|
| 33219 |
|
| 33220 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(275), __webpack_require__(289)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Form) {
|
| 33221 |
|
| 33222 |
var fields = [{
|
| 33223 |
name: 'name',
|
| 33272 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 33273 |
|
| 33274 |
/***/ },
|
| 33275 |
+
/* 446 */
|
| 33276 |
/***/ function(module, exports, __webpack_require__) {
|
| 33277 |
|
| 33278 |
'use strict';
|
| 33289 |
|
| 33290 |
var _reactRouter = __webpack_require__(181);
|
| 33291 |
|
| 33292 |
+
var _history = __webpack_require__(244);
|
| 33293 |
|
| 33294 |
+
var _formsListJsx = __webpack_require__(447);
|
| 33295 |
|
| 33296 |
var _formsListJsx2 = _interopRequireDefault(_formsListJsx);
|
| 33297 |
|
| 33321 |
}
|
| 33322 |
|
| 33323 |
/***/ },
|
| 33324 |
+
/* 447 */
|
| 33325 |
/***/ function(module, exports, __webpack_require__) {
|
| 33326 |
|
| 33327 |
'use strict';
|
| 33338 |
|
| 33339 |
var _reactRouter = __webpack_require__(181);
|
| 33340 |
|
| 33341 |
+
var _listingListingJsx = __webpack_require__(277);
|
| 33342 |
|
| 33343 |
var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
|
| 33344 |
|
| 33345 |
+
var _classnames = __webpack_require__(276);
|
| 33346 |
|
| 33347 |
var _classnames2 = _interopRequireDefault(_classnames);
|
| 33348 |
|
| 33349 |
+
var _mailpoet = __webpack_require__(275);
|
| 33350 |
|
| 33351 |
var _mailpoet2 = _interopRequireDefault(_mailpoet);
|
| 33352 |
|
| 33552 |
module.exports = FormList;
|
| 33553 |
|
| 33554 |
/***/ },
|
| 33555 |
+
/* 448 */
|
| 33556 |
/***/ function(module, exports, __webpack_require__) {
|
| 33557 |
|
| 33558 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 33559 |
+
__webpack_require__(449),
|
| 33560 |
+
__webpack_require__(274),
|
| 33561 |
+
__webpack_require__(275)
|
| 33562 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function(
|
| 33563 |
Backbone,
|
| 33564 |
jQuery,
|
| 33633 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 33634 |
|
| 33635 |
/***/ },
|
| 33636 |
+
/* 449 */
|
| 33637 |
/***/ function(module, exports, __webpack_require__) {
|
| 33638 |
|
| 33639 |
+
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["Backbone"] = __webpack_require__(450);
|
| 33640 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 33641 |
|
| 33642 |
/***/ },
|
| 33643 |
+
/* 450 */
|
| 33644 |
/***/ function(module, exports, __webpack_require__) {
|
| 33645 |
|
| 33646 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* WEBPACK VAR INJECTION */(function(global) {// Backbone.js 1.3.3
|
| 33659 |
|
| 33660 |
// Set up Backbone appropriately for the environment. Start with AMD.
|
| 33661 |
if (true) {
|
| 33662 |
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(278), __webpack_require__(274), exports], __WEBPACK_AMD_DEFINE_RESULT__ = function(_, $, exports) {
|
| 33663 |
// Export global even in AMD case in case this script is loaded with
|
| 33664 |
// others that may still expect a global Backbone.
|
| 33665 |
root.Backbone = factory(root, exports, _, $);
|
| 35567 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 35568 |
|
| 35569 |
/***/ },
|
| 35570 |
+
/* 451 */
|
| 35571 |
/***/ function(module, exports, __webpack_require__) {
|
| 35572 |
|
| 35573 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 35574 |
+
__webpack_require__(449),
|
| 35575 |
+
__webpack_require__(278),
|
| 35576 |
+
__webpack_require__(274),
|
| 35577 |
+
__webpack_require__(275),
|
| 35578 |
+
__webpack_require__(452),
|
| 35579 |
+
__webpack_require__(453),
|
| 35580 |
+
__webpack_require__(454),
|
| 35581 |
+
__webpack_require__(297),
|
| 35582 |
+
__webpack_require__(287)
|
| 35583 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function (
|
| 35584 |
Backbone,
|
| 35585 |
_,
|
| 36681 |
}.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
| 36682 |
|
| 36683 |
/***/ },
|
| 36684 |
+
/* 452 */,
|
| 36685 |
+
/* 453 */
|
| 36686 |
/***/ function(module, exports) {
|
| 36687 |
|
| 36688 |
/*!
|
| 36693 |
!function(e){"use strict";function t(t,r){if(r=r||{},r.worker&&w.WORKERS_SUPPORTED){var n=h();return n.userStep=r.step,n.userChunk=r.chunk,n.userComplete=r.complete,n.userError=r.error,r.step=m(r.step),r.chunk=m(r.chunk),r.complete=m(r.complete),r.error=m(r.error),delete r.worker,void n.postMessage({input:t,config:r,workerId:n.id})}var o=null;return"string"==typeof t?o=r.download?new i(r):new a(r):(e.File&&t instanceof File||t instanceof Object)&&(o=new s(r)),o.stream(t)}function r(e,t){function r(){"object"==typeof t&&("string"==typeof t.delimiter&&1==t.delimiter.length&&-1==w.BAD_DELIMITERS.indexOf(t.delimiter)&&(u=t.delimiter),("boolean"==typeof t.quotes||t.quotes instanceof Array)&&(o=t.quotes),"string"==typeof t.newline&&(f=t.newline))}function n(e){if("object"!=typeof e)return[];var t=[];for(var r in e)t.push(r);return t}function i(e,t){var r="";"string"==typeof e&&(e=JSON.parse(e)),"string"==typeof t&&(t=JSON.parse(t));var n=e instanceof Array&&e.length>0,i=!(t[0]instanceof Array);if(n){for(var a=0;a<e.length;a++)a>0&&(r+=u),r+=s(e[a],a);t.length>0&&(r+=f)}for(var o=0;o<t.length;o++){for(var h=n?e.length:t[o].length,d=0;h>d;d++){d>0&&(r+=u);var c=n&&i?e[d]:d;r+=s(t[o][c],d)}o<t.length-1&&(r+=f)}return r}function s(e,t){if("undefined"==typeof e||null===e)return"";e=e.toString().replace(/"/g,'""');var r="boolean"==typeof o&&o||o instanceof Array&&o[t]||a(e,w.BAD_DELIMITERS)||e.indexOf(u)>-1||" "==e.charAt(0)||" "==e.charAt(e.length-1);return r?'"'+e+'"':e}function a(e,t){for(var r=0;r<t.length;r++)if(e.indexOf(t[r])>-1)return!0;return!1}var o=!1,u=",",f="\r\n";if(r(),"string"==typeof e&&(e=JSON.parse(e)),e instanceof Array){if(!e.length||e[0]instanceof Array)return i(null,e);if("object"==typeof e[0])return i(n(e[0]),e)}else if("object"==typeof e)return"string"==typeof e.data&&(e.data=JSON.parse(e.data)),e.data instanceof Array&&(e.fields||(e.fields=e.data[0]instanceof Array?e.fields:n(e.data[0])),e.data[0]instanceof Array||"object"==typeof e.data[0]||(e.data=[e.data])),i(e.fields||[],e.data||[]);throw"exception: Unable to serialize unrecognized input"}function n(t){function r(e){var t=_(e);t.chunkSize=parseInt(t.chunkSize),this._handle=new o(t),this._handle.streamer=this,this._config=t}this._handle=null,this._paused=!1,this._finished=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this._completeResults={data:[],errors:[],meta:{}},r.call(this,t),this.parseChunk=function(t){var r=this._partialLine+t;this._partialLine="";var n=this._handle.parse(r,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.aborted()){var i=n.meta.cursor;this._finished||(this._partialLine=r.substring(i-this._baseIndex),this._baseIndex=i),n&&n.data&&(this._rowCount+=n.data.length);var s=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(k)e.postMessage({results:n,workerId:w.WORKER_ID,finished:s});else if(m(this._config.chunk)){if(this._config.chunk(n,this._handle),this._paused)return;n=void 0,this._completeResults=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(n.data),this._completeResults.errors=this._completeResults.errors.concat(n.errors),this._completeResults.meta=n.meta),!s||!m(this._config.complete)||n&&n.meta.aborted||this._config.complete(this._completeResults),s||n&&n.meta.paused||this._nextChunk(),n}},this._sendError=function(t){m(this._config.error)?this._config.error(t):k&&this._config.error&&e.postMessage({workerId:w.WORKER_ID,error:t,finished:!1})}}function i(e){function t(e){var t=e.getResponseHeader("Content-Range");return parseInt(t.substr(t.lastIndexOf("/")+1))}e=e||{},e.chunkSize||(e.chunkSize=w.RemoteChunkSize),n.call(this,e);var r;this._nextChunk=k?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(e){this._input=e,this._nextChunk()},this._readChunk=function(){if(this._finished)return void this._chunkLoaded();if(r=new XMLHttpRequest,k||(r.onload=g(this._chunkLoaded,this),r.onerror=g(this._chunkError,this)),r.open("GET",this._input,!k),this._config.chunkSize){var e=this._start+this._config.chunkSize-1;r.setRequestHeader("Range","bytes="+this._start+"-"+e),r.setRequestHeader("If-None-Match","webkit-no-cache")}try{r.send()}catch(t){this._chunkError(t.message)}k&&0==r.status?this._chunkError():this._start+=this._config.chunkSize},this._chunkLoaded=function(){if(4==r.readyState){if(r.status<200||r.status>=400)return void this._chunkError();this._finished=!this._config.chunkSize||this._start>t(r),this.parseChunk(r.responseText)}},this._chunkError=function(e){var t=r.statusText||e;this._sendError(t)}}function s(e){e=e||{},e.chunkSize||(e.chunkSize=w.LocalChunkSize),n.call(this,e);var t,r,i="undefined"!=typeof FileReader;this.stream=function(e){this._input=e,r=e.slice||e.webkitSlice||e.mozSlice,i?(t=new FileReader,t.onload=g(this._chunkLoaded,this),t.onerror=g(this._chunkError,this)):t=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var e=this._input;if(this._config.chunkSize){var n=Math.min(this._start+this._config.chunkSize,this._input.size);e=r.call(e,this._start,n)}var s=t.readAsText(e,this._config.encoding);i||this._chunkLoaded({target:{result:s}})},this._chunkLoaded=function(e){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(e.target.result)},this._chunkError=function(){this._sendError(t.error)}}function a(e){e=e||{},n.call(this,e);var t,r;this.stream=function(e){return t=e,r=e,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var e=this._config.chunkSize,t=e?r.substr(0,e):r;return r=e?r.substr(e):"",this._finished=!r,this.parseChunk(t)}}}function o(e){function t(){if(b&&c&&(f("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+w.DefaultDelimiter+"'"),c=!1),e.skipEmptyLines)for(var t=0;t<b.data.length;t++)1==b.data[t].length&&""==b.data[t][0]&&b.data.splice(t--,1);return r()&&n(),i()}function r(){return e.header&&0==y.length}function n(){if(b){for(var e=0;r()&&e<b.data.length;e++)for(var t=0;t<b.data[e].length;t++)y.push(b.data[e][t]);b.data.splice(0,1)}}function i(){if(!b||!e.header&&!e.dynamicTyping)return b;for(var t=0;t<b.data.length;t++){for(var r={},n=0;n<b.data[t].length;n++){if(e.dynamicTyping){var i=b.data[t][n];b.data[t][n]="true"==i||"TRUE"==i?!0:"false"==i||"FALSE"==i?!1:o(i)}e.header&&(n>=y.length?(r.__parsed_extra||(r.__parsed_extra=[]),r.__parsed_extra.push(b.data[t][n])):r[y[n]]=b.data[t][n])}e.header&&(b.data[t]=r,n>y.length?f("FieldMismatch","TooManyFields","Too many fields: expected "+y.length+" fields but parsed "+n,t):n<y.length&&f("FieldMismatch","TooFewFields","Too few fields: expected "+y.length+" fields but parsed "+n,t))}return e.header&&b.meta&&(b.meta.fields=y),b}function s(t){for(var r,n,i,s=[","," ","|",";",w.RECORD_SEP,w.UNIT_SEP],a=0;a<s.length;a++){var o=s[a],f=0,h=0;i=void 0;for(var d=new u({delimiter:o,preview:10}).parse(t),c=0;c<d.data.length;c++){var l=d.data[c].length;h+=l,"undefined"!=typeof i?l>1&&(f+=Math.abs(l-i),i=l):i=l}h/=d.data.length,("undefined"==typeof n||n>f)&&h>1.99&&(n=f,r=o)}return e.delimiter=r,{successful:!!r,bestDelimiter:r}}function a(e){e=e.substr(0,1048576);var t=e.split("\r");if(1==t.length)return"\n";for(var r=0,n=0;n<t.length;n++)"\n"==t[n][0]&&r++;return r>=t.length/2?"\r\n":"\r"}function o(e){var t=l.test(e);return t?parseFloat(e):e}function f(e,t,r,n){b.errors.push({type:e,code:t,message:r,row:n})}var h,d,c,l=/^\s*-?(\d*\.?\d+|\d+\.?\d*)(e[-+]?\d+)?\s*$/i,p=this,g=0,v=!1,k=!1,y=[],b={data:[],errors:[],meta:{}};if(m(e.step)){var R=e.step;e.step=function(n){if(b=n,r())t();else{if(t(),0==b.data.length)return;g+=n.data.length,e.preview&&g>e.preview?d.abort():R(b,p)}}}this.parse=function(r,n,i){if(e.newline||(e.newline=a(r)),c=!1,!e.delimiter){var o=s(r);o.successful?e.delimiter=o.bestDelimiter:(c=!0,e.delimiter=w.DefaultDelimiter),b.meta.delimiter=e.delimiter}var f=_(e);return e.preview&&e.header&&f.preview++,h=r,d=new u(f),b=d.parse(h,n,i),t(),v?{meta:{paused:!0}}:b||{meta:{paused:!1}}},this.paused=function(){return v},this.pause=function(){v=!0,d.abort(),h=h.substr(d.getCharIndex())},this.resume=function(){v=!1,p.streamer.parseChunk(h)},this.aborted=function(){return k},this.abort=function(){k=!0,d.abort(),b.meta.aborted=!0,m(e.complete)&&e.complete(b),h=""}}function u(e){e=e||{};var t=e.delimiter,r=e.newline,n=e.comments,i=e.step,s=e.preview,a=e.fastMode;if(("string"!=typeof t||w.BAD_DELIMITERS.indexOf(t)>-1)&&(t=","),n===t)throw"Comment character same as delimiter";n===!0?n="#":("string"!=typeof n||w.BAD_DELIMITERS.indexOf(n)>-1)&&(n=!1),"\n"!=r&&"\r"!=r&&"\r\n"!=r&&(r="\n");var o=0,u=!1;this.parse=function(e,f,h){function d(e){b.push(e),S=o}function c(t){return h?p():(t||(t=e.substr(o)),w.push(t),o=g,d(w),y&&_(),p())}function l(t){o=t,d(w),w=[],O=e.indexOf(r,o)}function p(e){return{data:b,errors:R,meta:{delimiter:t,linebreak:r,aborted:u,truncated:!!e,cursor:S+(f||0)}}}function _(){i(p()),b=[],R=[]}if("string"!=typeof e)throw"Input must be a string";var g=e.length,m=t.length,v=r.length,k=n.length,y="function"==typeof i;o=0;var b=[],R=[],w=[],S=0;if(!e)return p();if(a||a!==!1&&-1===e.indexOf('"')){for(var E=e.split(r),C=0;C<E.length;C++){var w=E[C];if(o+=w.length,C!==E.length-1)o+=r.length;else if(h)return p();if(!n||w.substr(0,k)!=n){if(y){if(b=[],d(w.split(t)),_(),u)return p()}else d(w.split(t));if(s&&C>=s)return b=b.slice(0,s),p(!0)}}return p()}for(var x=e.indexOf(t,o),O=e.indexOf(r,o);;)if('"'!=e[o])if(n&&0===w.length&&e.substr(o,k)===n){if(-1==O)return p();o=O+v,O=e.indexOf(r,o),x=e.indexOf(t,o)}else if(-1!==x&&(O>x||-1===O))w.push(e.substring(o,x)),o=x+m,x=e.indexOf(t,o);else{if(-1===O)break;if(w.push(e.substring(o,O)),l(O+v),y&&(_(),u))return p();if(s&&b.length>=s)return p(!0)}else{var I=o;for(o++;;){var I=e.indexOf('"',I+1);if(-1===I)return h||R.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:b.length,index:o}),c();if(I===g-1){var D=e.substring(o,I).replace(/""/g,'"');return c(D)}if('"'!=e[I+1]){if(e[I+1]==t){w.push(e.substring(o,I).replace(/""/g,'"')),o=I+1+m,x=e.indexOf(t,o),O=e.indexOf(r,o);break}if(e.substr(I+1,v)===r){if(w.push(e.substring(o,I).replace(/""/g,'"')),l(I+1+v),x=e.indexOf(t,o),y&&(_(),u))return p();if(s&&b.length>=s)return p(!0);break}}else I++}}return c()},this.abort=function(){u=!0},this.getCharIndex=function(){return o}}function f(){var e=document.getElementsByTagName("script");return e.length?e[e.length-1].src:""}function h(){if(!w.WORKERS_SUPPORTED)return!1;if(!y&&null===w.SCRIPT_PATH)throw new Error("Script path cannot be determined automatically when Papa Parse is loaded asynchronously. You need to set Papa.SCRIPT_PATH manually.");var t=new e.Worker(w.SCRIPT_PATH||v);return t.onmessage=d,t.id=R++,b[t.id]=t,t}function d(e){var t=e.data,r=b[t.workerId],n=!1;if(t.error)r.userError(t.error,t.file);else if(t.results&&t.results.data){var i=function(){n=!0,c(t.workerId,{data:[],errors:[],meta:{aborted:!0}})},s={abort:i,pause:l,resume:l};if(m(r.userStep)){for(var a=0;a<t.results.data.length&&(r.userStep({data:[t.results.data[a]],errors:t.results.errors,meta:t.results.meta},s),!n);a++);delete t.results}else m(r.userChunk)&&(r.userChunk(t.results,s,t.file),delete t.results)}t.finished&&!n&&c(t.workerId,t.results)}function c(e,t){var r=b[e];m(r.userComplete)&&r.userComplete(t),r.terminate(),delete b[e]}function l(){throw"Not implemented."}function p(t){var r=t.data;if("undefined"==typeof w.WORKER_ID&&r&&(w.WORKER_ID=r.workerId),"string"==typeof r.input)e.postMessage({workerId:w.WORKER_ID,results:w.parse(r.input,r.config),finished:!0});else if(e.File&&r.input instanceof File||r.input instanceof Object){var n=w.parse(r.input,r.config);n&&e.postMessage({workerId:w.WORKER_ID,results:n,finished:!0})}}function _(e){if("object"!=typeof e)return e;var t=e instanceof Array?[]:{};for(var r in e)t[r]=_(e[r]);return t}function g(e,t){return function(){e.apply(t,arguments)}}function m(e){return"function"==typeof e}var v,k=!e.document&&!!e.postMessage,y=!1,b={},R=0,w={};if(w.parse=t,w.unparse=r,w.RECORD_SEP=String.fromCharCode(30),w.UNIT_SEP=String.fromCharCode(31),w.BYTE_ORDER_MARK="",w.BAD_DELIMITERS=["\r","\n",'"',w.BYTE_ORDER_MARK],w.WORKERS_SUPPORTED=!!e.Worker,w.SCRIPT_PATH=null,w.LocalChunkSize=10485760,w.RemoteChunkSize=5242880,w.DefaultDelimiter=",",w.Parser=u,w.ParserHandle=o,w.NetworkStreamer=i,w.FileStreamer=s,w.StringStreamer=a,"undefined"!=typeof module&&module.exports?module.exports=w:m(e.define)&&e.define.amd?e.define(function(){return w}):e.Papa=w,e.jQuery){var S=e.jQuery;S.fn.parse=function(t){function r(){if(0==a.length)return void(m(t.complete)&&t.complete());var e=a[0];if(m(t.before)){var r=t.before(e.file,e.inputElem);if("object"==typeof r){if("abort"==r.action)return void n("AbortError",e.file,e.inputElem,r.reason);if("skip"==r.action)return void i();"object"==typeof r.config&&(e.instanceConfig=S.extend(e.instanceConfig,r.config))}else if("skip"==r)return void i()}var s=e.instanceConfig.complete;e.instanceConfig.complete=function(t){m(s)&&s(t,e.file,e.inputElem),i()},w.parse(e.file,e.instanceConfig)}function n(e,r,n,i){m(t.error)&&t.error({name:e},r,n,i)}function i(){a.splice(0,1),r()}var s=t.config||{},a=[];return this.each(function(){var t="INPUT"==S(this).prop("tagName").toUpperCase()&&"file"==S(this).attr("type").toLowerCase()&&e.FileReader;if(!t||!this.files||0==this.files.length)return!0;for(var r=0;r<this.files.length;r++)a.push({file:this.files[r],inputElem:this,instanceConfig:S.extend({},s)})}),r(),this}}k?e.onmessage=p:w.WORKERS_SUPPORTED&&(v=f(),document.body?document.addEventListener("DOMContentLoaded",function(){y=!0},!0):y=!0),i.prototype=Object.create(n.prototype),i.prototype.constructor=i,s.prototype=Object.create(n.prototype),s.prototype.constructor=s,a.prototype=Object.create(a.prototype),a.prototype.constructor=a}("undefined"!=typeof window?window:this);
|
| 36694 |
|
| 36695 |
/***/ },
|
| 36696 |
+
/* 454 */
|
| 36697 |
/***/ function(module, exports) {
|
| 36698 |
|
| 36699 |
/*
|
| 36778 |
|
| 36779 |
|
| 36780 |
/***/ },
|
| 36781 |
+
/* 455 */
|
| 36782 |
/***/ function(module, exports, __webpack_require__) {
|
| 36783 |
|
| 36784 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
|
| 36785 |
+
__webpack_require__(278),
|
| 36786 |
+
__webpack_require__(274),
|
| 36787 |
+
__webpack_require__(275),
|
| 36788 |
+
__webpack_require__(452),
|
| 36789 |
+
__webpack_require__(287)
|
| 36790 |
], __WEBPACK_AMD_DEFINE_RESULT__ = function (
|
| 36791 |
_,
|
| 36792 |
jQuery,
|
| 36951 |
|
| 36952 |
|
| 36953 |
/***/ },
|
| 36954 |
+
/* 456 */
|
| 36955 |
/***/ function(module, exports, __webpack_require__) {
|
| 36956 |
|
| 36957 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
assets/js/admin_vendor.js
CHANGED
|
@@ -5,7 +5,7 @@ webpackJsonp([1],[
|
|
| 5 |
__webpack_require__(2);
|
| 6 |
__webpack_require__(34);
|
| 7 |
__webpack_require__(181);
|
| 8 |
-
module.exports = __webpack_require__(
|
| 9 |
|
| 10 |
|
| 11 |
/***/ },
|
|
@@ -18348,10 +18348,10 @@ webpackJsonp([1],[
|
|
| 18348 |
*/
|
| 18349 |
|
| 18350 |
function getUnboundedScrollPosition(scrollable) {
|
| 18351 |
-
if (scrollable
|
| 18352 |
return {
|
| 18353 |
-
x:
|
| 18354 |
-
y:
|
| 18355 |
};
|
| 18356 |
}
|
| 18357 |
return {
|
|
@@ -19100,7 +19100,9 @@ webpackJsonp([1],[
|
|
| 19100 |
* @return {boolean} Whether or not the object is a DOM node.
|
| 19101 |
*/
|
| 19102 |
function isNode(object) {
|
| 19103 |
-
|
|
|
|
|
|
|
| 19104 |
}
|
| 19105 |
|
| 19106 |
module.exports = isNode;
|
|
@@ -19130,15 +19132,19 @@ webpackJsonp([1],[
|
|
| 19130 |
*
|
| 19131 |
* The activeElement will be null only if the document or document body is not
|
| 19132 |
* yet defined.
|
|
|
|
|
|
|
|
|
|
| 19133 |
*/
|
| 19134 |
-
function getActiveElement() /*?DOMElement*/{
|
| 19135 |
-
|
|
|
|
| 19136 |
return null;
|
| 19137 |
}
|
| 19138 |
try {
|
| 19139 |
-
return
|
| 19140 |
} catch (e) {
|
| 19141 |
-
return
|
| 19142 |
}
|
| 19143 |
}
|
| 19144 |
|
|
@@ -21580,7 +21586,7 @@ webpackJsonp([1],[
|
|
| 21580 |
}
|
| 21581 |
});
|
| 21582 |
|
| 21583 |
-
var _PatternUtils = __webpack_require__(
|
| 21584 |
|
| 21585 |
Object.defineProperty(exports, 'formatPattern', {
|
| 21586 |
enumerable: true,
|
|
@@ -21589,63 +21595,63 @@ webpackJsonp([1],[
|
|
| 21589 |
}
|
| 21590 |
});
|
| 21591 |
|
| 21592 |
-
var _Router2 = __webpack_require__(
|
| 21593 |
|
| 21594 |
var _Router3 = _interopRequireDefault(_Router2);
|
| 21595 |
|
| 21596 |
-
var _Link2 = __webpack_require__(
|
| 21597 |
|
| 21598 |
var _Link3 = _interopRequireDefault(_Link2);
|
| 21599 |
|
| 21600 |
-
var _IndexLink2 = __webpack_require__(
|
| 21601 |
|
| 21602 |
var _IndexLink3 = _interopRequireDefault(_IndexLink2);
|
| 21603 |
|
| 21604 |
-
var _withRouter2 = __webpack_require__(
|
| 21605 |
|
| 21606 |
var _withRouter3 = _interopRequireDefault(_withRouter2);
|
| 21607 |
|
| 21608 |
-
var _IndexRedirect2 = __webpack_require__(
|
| 21609 |
|
| 21610 |
var _IndexRedirect3 = _interopRequireDefault(_IndexRedirect2);
|
| 21611 |
|
| 21612 |
-
var _IndexRoute2 = __webpack_require__(
|
| 21613 |
|
| 21614 |
var _IndexRoute3 = _interopRequireDefault(_IndexRoute2);
|
| 21615 |
|
| 21616 |
-
var _Redirect2 = __webpack_require__(
|
| 21617 |
|
| 21618 |
var _Redirect3 = _interopRequireDefault(_Redirect2);
|
| 21619 |
|
| 21620 |
-
var _Route2 = __webpack_require__(
|
| 21621 |
|
| 21622 |
var _Route3 = _interopRequireDefault(_Route2);
|
| 21623 |
|
| 21624 |
-
var _RouterContext2 = __webpack_require__(
|
| 21625 |
|
| 21626 |
var _RouterContext3 = _interopRequireDefault(_RouterContext2);
|
| 21627 |
|
| 21628 |
-
var _match2 = __webpack_require__(
|
| 21629 |
|
| 21630 |
var _match3 = _interopRequireDefault(_match2);
|
| 21631 |
|
| 21632 |
-
var _useRouterHistory2 = __webpack_require__(
|
| 21633 |
|
| 21634 |
var _useRouterHistory3 = _interopRequireDefault(_useRouterHistory2);
|
| 21635 |
|
| 21636 |
-
var _applyRouterMiddleware2 = __webpack_require__(
|
| 21637 |
|
| 21638 |
var _applyRouterMiddleware3 = _interopRequireDefault(_applyRouterMiddleware2);
|
| 21639 |
|
| 21640 |
-
var _browserHistory2 = __webpack_require__(
|
| 21641 |
|
| 21642 |
var _browserHistory3 = _interopRequireDefault(_browserHistory2);
|
| 21643 |
|
| 21644 |
-
var _hashHistory2 = __webpack_require__(
|
| 21645 |
|
| 21646 |
var _hashHistory3 = _interopRequireDefault(_hashHistory2);
|
| 21647 |
|
| 21648 |
-
var _createMemoryHistory2 = __webpack_require__(
|
| 21649 |
|
| 21650 |
var _createMemoryHistory3 = _interopRequireDefault(_createMemoryHistory2);
|
| 21651 |
|
|
@@ -21784,286 +21790,572 @@ webpackJsonp([1],[
|
|
| 21784 |
exports.__esModule = true;
|
| 21785 |
exports.locationShape = exports.routerShape = undefined;
|
| 21786 |
|
| 21787 |
-
var
|
| 21788 |
|
| 21789 |
-
var
|
| 21790 |
-
|
| 21791 |
-
|
| 21792 |
-
|
| 21793 |
-
|
| 21794 |
-
|
| 21795 |
-
|
| 21796 |
-
|
| 21797 |
-
goBack: func.isRequired,
|
| 21798 |
-
goForward: func.isRequired,
|
| 21799 |
-
setRouteLeaveHook: func.isRequired,
|
| 21800 |
-
isActive: func.isRequired
|
| 21801 |
});
|
| 21802 |
|
| 21803 |
-
var locationShape = exports.locationShape = shape({
|
| 21804 |
-
pathname: string.isRequired,
|
| 21805 |
-
search: string.isRequired,
|
| 21806 |
-
state: object,
|
| 21807 |
-
action: string.isRequired,
|
| 21808 |
-
key: string
|
| 21809 |
});
|
| 21810 |
|
| 21811 |
/***/ },
|
| 21812 |
/* 184 */
|
| 21813 |
/***/ function(module, exports, __webpack_require__) {
|
| 21814 |
|
| 21815 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21816 |
|
| 21817 |
-
|
| 21818 |
-
exports.compilePattern = compilePattern;
|
| 21819 |
-
exports.matchPattern = matchPattern;
|
| 21820 |
-
exports.getParamNames = getParamNames;
|
| 21821 |
-
exports.getParams = getParams;
|
| 21822 |
-
exports.formatPattern = formatPattern;
|
| 21823 |
|
| 21824 |
-
var
|
|
|
|
|
|
|
|
|
|
| 21825 |
|
| 21826 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21827 |
|
| 21828 |
-
|
| 21829 |
|
| 21830 |
-
function escapeRegExp(string) {
|
| 21831 |
-
return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
| 21832 |
-
}
|
| 21833 |
|
| 21834 |
-
|
| 21835 |
-
|
| 21836 |
-
|
| 21837 |
-
var tokens = [];
|
| 21838 |
|
| 21839 |
-
|
| 21840 |
-
|
| 21841 |
-
|
| 21842 |
-
|
| 21843 |
-
|
| 21844 |
-
|
| 21845 |
-
|
| 21846 |
-
|
| 21847 |
|
| 21848 |
-
|
| 21849 |
-
regexpSource += '([^/]+)';
|
| 21850 |
-
paramNames.push(match[1]);
|
| 21851 |
-
} else if (match[0] === '**') {
|
| 21852 |
-
regexpSource += '(.*)';
|
| 21853 |
-
paramNames.push('splat');
|
| 21854 |
-
} else if (match[0] === '*') {
|
| 21855 |
-
regexpSource += '(.*?)';
|
| 21856 |
-
paramNames.push('splat');
|
| 21857 |
-
} else if (match[0] === '(') {
|
| 21858 |
-
regexpSource += '(?:';
|
| 21859 |
-
} else if (match[0] === ')') {
|
| 21860 |
-
regexpSource += ')?';
|
| 21861 |
-
} else if (match[0] === '\\(') {
|
| 21862 |
-
regexpSource += '\\(';
|
| 21863 |
-
} else if (match[0] === '\\)') {
|
| 21864 |
-
regexpSource += '\\)';
|
| 21865 |
-
}
|
| 21866 |
|
| 21867 |
-
|
|
|
|
|
|
|
| 21868 |
|
| 21869 |
-
|
| 21870 |
-
|
| 21871 |
|
| 21872 |
-
|
| 21873 |
-
|
| 21874 |
-
|
| 21875 |
-
|
| 21876 |
|
| 21877 |
-
|
| 21878 |
-
|
| 21879 |
-
|
| 21880 |
-
|
| 21881 |
-
|
| 21882 |
-
|
| 21883 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21884 |
|
| 21885 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21886 |
|
| 21887 |
-
|
| 21888 |
-
if (!CompiledPatternsCache[pattern]) CompiledPatternsCache[pattern] = _compilePattern(pattern);
|
| 21889 |
|
| 21890 |
-
|
| 21891 |
-
}
|
| 21892 |
|
| 21893 |
-
|
| 21894 |
-
|
| 21895 |
-
|
| 21896 |
-
|
| 21897 |
-
|
| 21898 |
-
|
| 21899 |
-
|
| 21900 |
-
|
| 21901 |
-
|
| 21902 |
-
|
| 21903 |
-
|
| 21904 |
-
|
| 21905 |
-
|
| 21906 |
-
|
| 21907 |
-
|
| 21908 |
-
|
| 21909 |
-
|
| 21910 |
-
|
| 21911 |
-
|
| 21912 |
-
|
| 21913 |
-
|
| 21914 |
-
|
| 21915 |
-
|
| 21916 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21917 |
}
|
| 21918 |
|
| 21919 |
-
|
| 21920 |
-
|
| 21921 |
-
|
| 21922 |
-
|
| 21923 |
-
|
| 21924 |
-
|
| 21925 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21926 |
}
|
|
|
|
| 21927 |
|
| 21928 |
-
|
| 21929 |
-
|
| 21930 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21931 |
}
|
|
|
|
|
|
|
| 21932 |
|
| 21933 |
-
|
| 21934 |
-
|
| 21935 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21936 |
}
|
| 21937 |
|
| 21938 |
-
|
| 21939 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21940 |
|
| 21941 |
-
|
| 21942 |
-
|
| 21943 |
-
// the full path, so any remaining pathname is a new path segment.
|
| 21944 |
-
if (matchedPath.charAt(matchedPath.length - 1) !== '/') {
|
| 21945 |
return null;
|
| 21946 |
}
|
|
|
|
|
|
|
| 21947 |
|
| 21948 |
-
|
| 21949 |
-
|
| 21950 |
-
remainingPathname = '/' + remainingPathname;
|
| 21951 |
}
|
| 21952 |
|
| 21953 |
-
|
| 21954 |
-
|
| 21955 |
-
|
| 21956 |
-
|
| 21957 |
-
|
| 21958 |
-
|
| 21959 |
-
|
| 21960 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21961 |
|
| 21962 |
-
|
| 21963 |
-
|
| 21964 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21965 |
|
| 21966 |
-
|
| 21967 |
-
|
| 21968 |
-
|
| 21969 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21970 |
}
|
| 21971 |
|
| 21972 |
-
|
| 21973 |
-
|
|
|
|
|
|
|
|
|
|
| 21974 |
|
| 21975 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21976 |
|
| 21977 |
-
|
| 21978 |
-
|
| 21979 |
-
|
|
|
|
|
|
|
| 21980 |
|
| 21981 |
-
|
| 21982 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21983 |
|
| 21984 |
-
|
| 21985 |
-
|
| 21986 |
-
|
| 21987 |
-
|
| 21988 |
-
|
| 21989 |
-
params = params || {};
|
| 21990 |
|
| 21991 |
-
|
| 21992 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21993 |
|
| 21994 |
-
|
| 21995 |
-
|
| 21996 |
-
|
| 21997 |
-
|
| 21998 |
|
| 21999 |
-
|
| 22000 |
-
|
| 22001 |
-
|
| 22002 |
-
|
| 22003 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22004 |
|
| 22005 |
-
|
| 22006 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22007 |
|
| 22008 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22009 |
|
| 22010 |
-
|
| 22011 |
-
|
| 22012 |
-
|
| 22013 |
-
|
| 22014 |
-
|
| 22015 |
-
|
| 22016 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22017 |
|
| 22018 |
-
|
| 22019 |
-
|
| 22020 |
-
|
| 22021 |
-
}
|
| 22022 |
-
|
| 22023 |
-
} else if (token.charAt(0) === ':') {
|
| 22024 |
-
paramName = token.substring(1);
|
| 22025 |
-
paramValue = params[paramName];
|
| 22026 |
|
| 22027 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22028 |
|
| 22029 |
-
|
| 22030 |
-
|
| 22031 |
-
|
|
|
|
| 22032 |
|
| 22033 |
-
|
| 22034 |
-
|
| 22035 |
-
|
|
|
|
| 22036 |
|
| 22037 |
-
|
| 22038 |
-
|
| 22039 |
-
nextParenIdx = _i;
|
| 22040 |
-
break;
|
| 22041 |
-
}
|
| 22042 |
-
}
|
| 22043 |
|
| 22044 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22045 |
|
| 22046 |
-
|
| 22047 |
-
|
| 22048 |
-
|
| 22049 |
-
|
| 22050 |
-
|
| 22051 |
-
if (
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22052 |
}
|
|
|
|
| 22053 |
}
|
| 22054 |
|
| 22055 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22056 |
|
| 22057 |
-
return pathname.replace(/\/+/g, '/');
|
| 22058 |
-
}
|
| 22059 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22060 |
|
| 22061 |
/***/ },
|
| 22062 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22063 |
/***/ function(module, exports, __webpack_require__) {
|
| 22064 |
|
| 22065 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 22066 |
-
* Copyright 2013-
|
| 22067 |
* All rights reserved.
|
| 22068 |
*
|
| 22069 |
* This source code is licensed under the BSD-style license found in the
|
|
@@ -22073,232 +22365,1408 @@ webpackJsonp([1],[
|
|
| 22073 |
|
| 22074 |
'use strict';
|
| 22075 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22076 |
/**
|
| 22077 |
-
*
|
| 22078 |
-
*
|
| 22079 |
-
* Provide sprintf-style format (only %s is supported) and arguments
|
| 22080 |
-
* to provide information about what broke and what you were
|
| 22081 |
-
* expecting.
|
| 22082 |
*
|
| 22083 |
-
*
|
| 22084 |
-
*
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22085 |
*/
|
| 22086 |
-
|
| 22087 |
-
var invariant = function(condition, format, a, b, c, d, e, f) {
|
| 22088 |
if (process.env.NODE_ENV !== 'production') {
|
| 22089 |
-
|
| 22090 |
-
|
| 22091 |
-
|
| 22092 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22093 |
|
| 22094 |
-
|
| 22095 |
-
var error;
|
| 22096 |
-
if (format === undefined) {
|
| 22097 |
-
error = new Error(
|
| 22098 |
-
'Minified exception occurred; use the non-minified dev environment ' +
|
| 22099 |
-
'for the full error message and additional helpful warnings.'
|
| 22100 |
-
);
|
| 22101 |
-
} else {
|
| 22102 |
-
var args = [a, b, c, d, e, f];
|
| 22103 |
-
var argIndex = 0;
|
| 22104 |
-
error = new Error(
|
| 22105 |
-
format.replace(/%s/g, function() { return args[argIndex++]; })
|
| 22106 |
-
);
|
| 22107 |
-
error.name = 'Invariant Violation';
|
| 22108 |
-
}
|
| 22109 |
|
| 22110 |
-
|
| 22111 |
-
|
|
|
|
|
|
|
| 22112 |
}
|
| 22113 |
-
}
|
| 22114 |
|
| 22115 |
-
module.exports =
|
| 22116 |
|
| 22117 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22118 |
|
| 22119 |
/***/ },
|
| 22120 |
-
/*
|
| 22121 |
/***/ function(module, exports, __webpack_require__) {
|
| 22122 |
|
| 22123 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 22124 |
|
| 22125 |
exports.__esModule = true;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22126 |
|
| 22127 |
-
var
|
| 22128 |
-
|
| 22129 |
-
var _invariant = __webpack_require__(185);
|
| 22130 |
|
| 22131 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 22132 |
|
| 22133 |
-
|
| 22134 |
|
| 22135 |
-
|
|
|
|
|
|
|
| 22136 |
|
| 22137 |
-
|
|
|
|
|
|
|
|
|
|
| 22138 |
|
| 22139 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22140 |
|
| 22141 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22142 |
|
| 22143 |
-
|
| 22144 |
|
| 22145 |
-
|
|
|
|
| 22146 |
|
| 22147 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22148 |
|
| 22149 |
-
|
|
|
|
|
|
|
|
|
|
| 22150 |
|
| 22151 |
-
|
| 22152 |
|
| 22153 |
-
|
|
|
|
| 22154 |
|
| 22155 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22156 |
|
| 22157 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22158 |
|
| 22159 |
-
|
| 22160 |
-
func = _React$PropTypes.func,
|
| 22161 |
-
object = _React$PropTypes.object;
|
| 22162 |
|
| 22163 |
-
|
| 22164 |
-
|
| 22165 |
-
* a router that renders a <RouterContext> with all the props
|
| 22166 |
-
* it needs each time the URL changes.
|
| 22167 |
-
*/
|
| 22168 |
|
| 22169 |
-
|
| 22170 |
-
|
|
|
|
|
|
|
| 22171 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22172 |
|
| 22173 |
-
|
| 22174 |
-
history: object,
|
| 22175 |
-
children: _InternalPropTypes.routes,
|
| 22176 |
-
routes: _InternalPropTypes.routes, // alias for children
|
| 22177 |
-
render: func,
|
| 22178 |
-
createElement: func,
|
| 22179 |
-
onError: func,
|
| 22180 |
-
onUpdate: func,
|
| 22181 |
|
| 22182 |
-
|
| 22183 |
-
|
| 22184 |
-
|
|
|
|
| 22185 |
|
| 22186 |
-
|
| 22187 |
-
|
| 22188 |
-
|
| 22189 |
-
|
| 22190 |
}
|
| 22191 |
-
};
|
| 22192 |
-
},
|
| 22193 |
-
getInitialState: function getInitialState() {
|
| 22194 |
-
return {
|
| 22195 |
-
location: null,
|
| 22196 |
-
routes: null,
|
| 22197 |
-
params: null,
|
| 22198 |
-
components: null
|
| 22199 |
-
};
|
| 22200 |
-
},
|
| 22201 |
-
handleError: function handleError(error) {
|
| 22202 |
-
if (this.props.onError) {
|
| 22203 |
-
this.props.onError.call(this, error);
|
| 22204 |
-
} else {
|
| 22205 |
-
// Throw errors by default so we don't silently swallow them!
|
| 22206 |
-
throw error; // This error probably occurred in getChildRoutes or getComponents.
|
| 22207 |
}
|
| 22208 |
-
},
|
| 22209 |
-
createRouterObject: function createRouterObject(state) {
|
| 22210 |
-
var matchContext = this.props.matchContext;
|
| 22211 |
|
| 22212 |
-
|
| 22213 |
-
|
| 22214 |
-
}
|
| 22215 |
|
| 22216 |
-
|
|
|
|
| 22217 |
|
| 22218 |
-
|
| 22219 |
-
},
|
| 22220 |
-
createTransitionManager: function createTransitionManager() {
|
| 22221 |
-
var matchContext = this.props.matchContext;
|
| 22222 |
|
| 22223 |
-
|
| 22224 |
-
return matchContext.transitionManager;
|
| 22225 |
-
}
|
| 22226 |
|
| 22227 |
-
|
| 22228 |
-
|
| 22229 |
-
|
| 22230 |
-
children = _props.children;
|
| 22231 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22232 |
|
| 22233 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22234 |
|
| 22235 |
-
|
| 22236 |
-
|
| 22237 |
-
|
| 22238 |
-
|
| 22239 |
|
| 22240 |
-
|
| 22241 |
-
|
| 22242 |
|
| 22243 |
-
|
| 22244 |
-
|
| 22245 |
-
|
| 22246 |
-
|
| 22247 |
-
|
| 22248 |
-
// they only work if the object identity is preserved.
|
| 22249 |
-
(0, _RouterUtils.assignRouterState)(_this.router, state);
|
| 22250 |
-
_this.setState(state, _this.props.onUpdate);
|
| 22251 |
-
}
|
| 22252 |
-
});
|
| 22253 |
-
},
|
| 22254 |
|
|
|
|
| 22255 |
|
| 22256 |
-
|
| 22257 |
-
|
| 22258 |
-
|
|
|
|
|
|
|
|
|
|
| 22259 |
|
| 22260 |
-
|
| 22261 |
-
|
| 22262 |
-
|
| 22263 |
-
|
| 22264 |
-
|
| 22265 |
-
|
| 22266 |
-
|
| 22267 |
-
|
| 22268 |
-
|
| 22269 |
-
|
| 22270 |
-
|
| 22271 |
|
| 22272 |
-
|
| 22273 |
-
|
| 22274 |
-
|
| 22275 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22276 |
|
| 22277 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22278 |
|
| 22279 |
-
|
| 22280 |
-
|
| 22281 |
-
|
| 22282 |
-
|
| 22283 |
-
});
|
| 22284 |
|
| 22285 |
-
|
| 22286 |
-
|
| 22287 |
-
|
| 22288 |
-
|
| 22289 |
-
|
| 22290 |
-
|
| 22291 |
-
|
| 22292 |
-
|
| 22293 |
-
|
| 22294 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22295 |
|
| 22296 |
-
exports.default = Router;
|
| 22297 |
-
module.exports = exports['default'];
|
| 22298 |
-
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22299 |
|
| 22300 |
/***/ },
|
| 22301 |
-
/*
|
| 22302 |
/***/ function(module, exports, __webpack_require__) {
|
| 22303 |
|
| 22304 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -22309,25 +23777,27 @@ webpackJsonp([1],[
|
|
| 22309 |
|
| 22310 |
exports.default = createTransitionManager;
|
| 22311 |
|
| 22312 |
-
var _routerWarning = __webpack_require__(
|
| 22313 |
|
| 22314 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 22315 |
|
| 22316 |
-
var _computeChangedRoutes2 = __webpack_require__(
|
| 22317 |
|
| 22318 |
var _computeChangedRoutes3 = _interopRequireDefault(_computeChangedRoutes2);
|
| 22319 |
|
| 22320 |
-
var _TransitionUtils = __webpack_require__(
|
| 22321 |
|
| 22322 |
-
var
|
|
|
|
|
|
|
| 22323 |
|
| 22324 |
var _isActive3 = _interopRequireDefault(_isActive2);
|
| 22325 |
|
| 22326 |
-
var _getComponents = __webpack_require__(
|
| 22327 |
|
| 22328 |
var _getComponents2 = _interopRequireDefault(_getComponents);
|
| 22329 |
|
| 22330 |
-
var _matchRoutes = __webpack_require__(
|
| 22331 |
|
| 22332 |
var _matchRoutes2 = _interopRequireDefault(_matchRoutes);
|
| 22333 |
|
|
@@ -22342,8 +23812,15 @@ webpackJsonp([1],[
|
|
| 22342 |
function createTransitionManager(history, routes) {
|
| 22343 |
var state = {};
|
| 22344 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22345 |
// Signature should be (location, indexOnly), but needs to support (path,
|
| 22346 |
// query, indexOnly)
|
|
|
|
|
|
|
| 22347 |
function isActive(location, indexOnly) {
|
| 22348 |
location = history.createLocation(location);
|
| 22349 |
|
|
@@ -22375,7 +23852,7 @@ webpackJsonp([1],[
|
|
| 22375 |
changeRoutes = _computeChangedRoutes.changeRoutes,
|
| 22376 |
enterRoutes = _computeChangedRoutes.enterRoutes;
|
| 22377 |
|
| 22378 |
-
|
| 22379 |
|
| 22380 |
// Tear down confirmation hooks for left routes
|
| 22381 |
leaveRoutes.filter(function (route) {
|
|
@@ -22383,10 +23860,10 @@ webpackJsonp([1],[
|
|
| 22383 |
}).forEach(removeListenBeforeHooksForRoute);
|
| 22384 |
|
| 22385 |
// change and enter hooks are run in series
|
| 22386 |
-
|
| 22387 |
if (error || redirectInfo) return handleErrorOrRedirect(error, redirectInfo);
|
| 22388 |
|
| 22389 |
-
|
| 22390 |
});
|
| 22391 |
|
| 22392 |
function finishEnterHooks(error, redirectInfo) {
|
|
@@ -22579,7 +24056,7 @@ webpackJsonp([1],[
|
|
| 22579 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22580 |
|
| 22581 |
/***/ },
|
| 22582 |
-
/*
|
| 22583 |
/***/ function(module, exports, __webpack_require__) {
|
| 22584 |
|
| 22585 |
'use strict';
|
|
@@ -22588,7 +24065,7 @@ webpackJsonp([1],[
|
|
| 22588 |
exports.default = routerWarning;
|
| 22589 |
exports._resetWarned = _resetWarned;
|
| 22590 |
|
| 22591 |
-
var _warning = __webpack_require__(
|
| 22592 |
|
| 22593 |
var _warning2 = _interopRequireDefault(_warning);
|
| 22594 |
|
|
@@ -22620,7 +24097,7 @@ webpackJsonp([1],[
|
|
| 22620 |
}
|
| 22621 |
|
| 22622 |
/***/ },
|
| 22623 |
-
/*
|
| 22624 |
/***/ function(module, exports, __webpack_require__) {
|
| 22625 |
|
| 22626 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
|
@@ -22687,14 +24164,14 @@ webpackJsonp([1],[
|
|
| 22687 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22688 |
|
| 22689 |
/***/ },
|
| 22690 |
-
/*
|
| 22691 |
/***/ function(module, exports, __webpack_require__) {
|
| 22692 |
|
| 22693 |
'use strict';
|
| 22694 |
|
| 22695 |
exports.__esModule = true;
|
| 22696 |
|
| 22697 |
-
var _PatternUtils = __webpack_require__(
|
| 22698 |
|
| 22699 |
function routeParamsChanged(route, prevState, nextState) {
|
| 22700 |
if (!route.path) return false;
|
|
@@ -22725,33 +24202,31 @@ webpackJsonp([1],[
|
|
| 22725 |
|
| 22726 |
var leaveRoutes = void 0,
|
| 22727 |
changeRoutes = void 0,
|
| 22728 |
-
enterRoutes = void 0;
|
| 22729 |
-
if (prevRoutes) {
|
| 22730 |
-
|
| 22731 |
-
|
| 22732 |
-
|
| 22733 |
-
|
| 22734 |
-
|
| 22735 |
-
|
| 22736 |
-
|
| 22737 |
-
|
| 22738 |
-
|
| 22739 |
-
|
| 22740 |
-
});
|
| 22741 |
|
| 22742 |
-
|
| 22743 |
-
|
| 22744 |
|
| 22745 |
-
|
| 22746 |
-
|
| 22747 |
|
| 22748 |
-
|
| 22749 |
-
|
| 22750 |
-
|
| 22751 |
|
| 22752 |
-
|
| 22753 |
-
|
| 22754 |
-
})();
|
| 22755 |
} else {
|
| 22756 |
leaveRoutes = [];
|
| 22757 |
changeRoutes = [];
|
|
@@ -22769,17 +24244,15 @@ webpackJsonp([1],[
|
|
| 22769 |
module.exports = exports['default'];
|
| 22770 |
|
| 22771 |
/***/ },
|
| 22772 |
-
/*
|
| 22773 |
/***/ function(module, exports, __webpack_require__) {
|
| 22774 |
|
| 22775 |
'use strict';
|
| 22776 |
|
| 22777 |
exports.__esModule = true;
|
| 22778 |
-
exports.
|
| 22779 |
-
exports.runChangeHooks = runChangeHooks;
|
| 22780 |
-
exports.runLeaveHooks = runLeaveHooks;
|
| 22781 |
|
| 22782 |
-
var _AsyncUtils = __webpack_require__(
|
| 22783 |
|
| 22784 |
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
| 22785 |
|
|
@@ -22809,127 +24282,136 @@ webpackJsonp([1],[
|
|
| 22809 |
};
|
| 22810 |
};
|
| 22811 |
|
| 22812 |
-
|
| 22813 |
-
|
| 22814 |
-
|
| 22815 |
-
function createTransitionHook(hook, route, asyncArity, pendingHooks) {
|
| 22816 |
-
var isSync = hook.length < asyncArity;
|
| 22817 |
-
|
| 22818 |
-
var transitionHook = function transitionHook() {
|
| 22819 |
-
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
| 22820 |
-
args[_key] = arguments[_key];
|
| 22821 |
-
}
|
| 22822 |
|
| 22823 |
-
|
|
|
|
| 22824 |
|
| 22825 |
-
|
| 22826 |
-
var
|
| 22827 |
-
|
| 22828 |
-
|
| 22829 |
-
callback();
|
| 22830 |
-
}
|
| 22831 |
-
};
|
| 22832 |
|
| 22833 |
-
|
| 22834 |
|
| 22835 |
-
|
| 22836 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22837 |
|
| 22838 |
-
|
| 22839 |
-
return routes.reduce(function (hooks, route) {
|
| 22840 |
-
if (route.onEnter) hooks.push(createTransitionHook(route.onEnter, route, 3, enterHooks));
|
| 22841 |
-
return hooks;
|
| 22842 |
-
}, []);
|
| 22843 |
-
}
|
| 22844 |
|
| 22845 |
-
|
| 22846 |
-
|
| 22847 |
-
if (route.onChange) hooks.push(createTransitionHook(route.onChange, route, 4, changeHooks));
|
| 22848 |
-
return hooks;
|
| 22849 |
-
}, []);
|
| 22850 |
-
}
|
| 22851 |
|
| 22852 |
-
|
| 22853 |
-
|
| 22854 |
-
|
| 22855 |
-
|
|
|
|
| 22856 |
}
|
| 22857 |
|
| 22858 |
-
|
| 22859 |
-
|
| 22860 |
-
|
|
|
|
|
|
|
| 22861 |
}
|
| 22862 |
|
| 22863 |
-
|
| 22864 |
-
|
| 22865 |
-
|
| 22866 |
-
|
| 22867 |
-
|
| 22868 |
-
next();
|
| 22869 |
-
}
|
| 22870 |
-
});
|
| 22871 |
-
}, callback);
|
| 22872 |
-
}
|
| 22873 |
|
| 22874 |
-
|
| 22875 |
-
|
| 22876 |
-
|
| 22877 |
-
|
| 22878 |
-
* to use replace short-circuits the loop.
|
| 22879 |
-
*
|
| 22880 |
-
* If a hook needs to run asynchronously, it may use the callback
|
| 22881 |
-
* function. However, doing so will cause the transition to pause,
|
| 22882 |
-
* which could lead to a non-responsive UI if the hook is slow.
|
| 22883 |
-
*/
|
| 22884 |
-
function runEnterHooks(routes, nextState, callback) {
|
| 22885 |
-
enterHooks.clear();
|
| 22886 |
-
var hooks = getEnterHooks(routes);
|
| 22887 |
-
return runTransitionHooks(hooks.length, function (index, replace, next) {
|
| 22888 |
-
var wrappedNext = function wrappedNext() {
|
| 22889 |
-
if (enterHooks.has(hooks[index])) {
|
| 22890 |
-
next.apply(undefined, arguments);
|
| 22891 |
-
enterHooks.remove(hooks[index]);
|
| 22892 |
-
}
|
| 22893 |
-
};
|
| 22894 |
-
hooks[index](nextState, replace, wrappedNext);
|
| 22895 |
-
}, callback);
|
| 22896 |
-
}
|
| 22897 |
|
| 22898 |
-
|
| 22899 |
-
|
| 22900 |
-
|
| 22901 |
-
|
| 22902 |
-
|
| 22903 |
-
|
| 22904 |
-
|
| 22905 |
-
|
| 22906 |
-
|
| 22907 |
-
|
| 22908 |
-
function runChangeHooks(routes, state, nextState, callback) {
|
| 22909 |
-
changeHooks.clear();
|
| 22910 |
-
var hooks = getChangeHooks(routes);
|
| 22911 |
-
return runTransitionHooks(hooks.length, function (index, replace, next) {
|
| 22912 |
-
var wrappedNext = function wrappedNext() {
|
| 22913 |
-
if (changeHooks.has(hooks[index])) {
|
| 22914 |
-
next.apply(undefined, arguments);
|
| 22915 |
-
changeHooks.remove(hooks[index]);
|
| 22916 |
-
}
|
| 22917 |
-
};
|
| 22918 |
-
hooks[index](state, nextState, replace, wrappedNext);
|
| 22919 |
-
}, callback);
|
| 22920 |
-
}
|
| 22921 |
|
| 22922 |
-
|
| 22923 |
-
|
| 22924 |
-
|
| 22925 |
-
|
| 22926 |
-
|
| 22927 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22928 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22929 |
}
|
|
|
|
| 22930 |
|
| 22931 |
/***/ },
|
| 22932 |
-
/*
|
| 22933 |
/***/ function(module, exports) {
|
| 22934 |
|
| 22935 |
"use strict";
|
|
@@ -23022,7 +24504,7 @@ webpackJsonp([1],[
|
|
| 23022 |
}
|
| 23023 |
|
| 23024 |
/***/ },
|
| 23025 |
-
/*
|
| 23026 |
/***/ function(module, exports, __webpack_require__) {
|
| 23027 |
|
| 23028 |
'use strict';
|
|
@@ -23033,7 +24515,7 @@ webpackJsonp([1],[
|
|
| 23033 |
|
| 23034 |
exports.default = isActive;
|
| 23035 |
|
| 23036 |
-
var _PatternUtils = __webpack_require__(
|
| 23037 |
|
| 23038 |
function deepEqual(a, b) {
|
| 23039 |
if (a == b) return true;
|
|
@@ -23179,16 +24661,16 @@ webpackJsonp([1],[
|
|
| 23179 |
module.exports = exports['default'];
|
| 23180 |
|
| 23181 |
/***/ },
|
| 23182 |
-
/*
|
| 23183 |
/***/ function(module, exports, __webpack_require__) {
|
| 23184 |
|
| 23185 |
'use strict';
|
| 23186 |
|
| 23187 |
exports.__esModule = true;
|
| 23188 |
|
| 23189 |
-
var _AsyncUtils = __webpack_require__(
|
| 23190 |
|
| 23191 |
-
var _PromiseUtils = __webpack_require__(
|
| 23192 |
|
| 23193 |
function getComponentsForRoute(nextState, route, callback) {
|
| 23194 |
if (route.component || route.components) {
|
|
@@ -23224,7 +24706,7 @@ webpackJsonp([1],[
|
|
| 23224 |
module.exports = exports['default'];
|
| 23225 |
|
| 23226 |
/***/ },
|
| 23227 |
-
/*
|
| 23228 |
/***/ function(module, exports) {
|
| 23229 |
|
| 23230 |
'use strict';
|
|
@@ -23236,7 +24718,7 @@ webpackJsonp([1],[
|
|
| 23236 |
}
|
| 23237 |
|
| 23238 |
/***/ },
|
| 23239 |
-
/*
|
| 23240 |
/***/ function(module, exports, __webpack_require__) {
|
| 23241 |
|
| 23242 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -23245,17 +24727,15 @@ webpackJsonp([1],[
|
|
| 23245 |
|
| 23246 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 23247 |
|
| 23248 |
-
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
|
| 23249 |
-
|
| 23250 |
exports.default = matchRoutes;
|
| 23251 |
|
| 23252 |
-
var _AsyncUtils = __webpack_require__(
|
| 23253 |
|
| 23254 |
-
var _PromiseUtils = __webpack_require__(
|
| 23255 |
|
| 23256 |
-
var _PatternUtils = __webpack_require__(
|
| 23257 |
|
| 23258 |
-
var _routerWarning = __webpack_require__(
|
| 23259 |
|
| 23260 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 23261 |
|
|
@@ -23395,38 +24875,32 @@ webpackJsonp([1],[
|
|
| 23395 |
// By assumption, pattern is non-empty here, which is the prerequisite for
|
| 23396 |
// actually terminating a match.
|
| 23397 |
if (remainingPathname === '') {
|
| 23398 |
-
var
|
| 23399 |
-
|
| 23400 |
-
|
| 23401 |
-
|
| 23402 |
-
};
|
| 23403 |
-
|
| 23404 |
-
getIndexRoute(route, location, paramNames, paramValues, function (error, indexRoute) {
|
| 23405 |
-
if (error) {
|
| 23406 |
-
callback(error);
|
| 23407 |
-
} else {
|
| 23408 |
-
if (Array.isArray(indexRoute)) {
|
| 23409 |
-
var _match$routes;
|
| 23410 |
-
|
| 23411 |
-
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)(indexRoute.every(function (route) {
|
| 23412 |
-
return !route.path;
|
| 23413 |
-
}), 'Index routes should not have paths') : void 0;
|
| 23414 |
-
(_match$routes = match.routes).push.apply(_match$routes, indexRoute);
|
| 23415 |
-
} else if (indexRoute) {
|
| 23416 |
-
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)(!indexRoute.path, 'Index routes should not have paths') : void 0;
|
| 23417 |
-
match.routes.push(indexRoute);
|
| 23418 |
-
}
|
| 23419 |
|
| 23420 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23421 |
}
|
| 23422 |
-
});
|
| 23423 |
|
| 23424 |
-
|
| 23425 |
-
|
| 23426 |
-
|
| 23427 |
-
}();
|
| 23428 |
|
| 23429 |
-
|
| 23430 |
}
|
| 23431 |
}
|
| 23432 |
|
|
@@ -23505,7 +24979,7 @@ webpackJsonp([1],[
|
|
| 23505 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 23506 |
|
| 23507 |
/***/ },
|
| 23508 |
-
/*
|
| 23509 |
/***/ function(module, exports, __webpack_require__) {
|
| 23510 |
|
| 23511 |
'use strict';
|
|
@@ -23514,35 +24988,28 @@ webpackJsonp([1],[
|
|
| 23514 |
exports.routes = exports.route = exports.components = exports.component = exports.history = undefined;
|
| 23515 |
exports.falsy = falsy;
|
| 23516 |
|
| 23517 |
-
var
|
| 23518 |
|
| 23519 |
-
var func = _react.PropTypes.func,
|
| 23520 |
-
object = _react.PropTypes.object,
|
| 23521 |
-
arrayOf = _react.PropTypes.arrayOf,
|
| 23522 |
-
oneOfType = _react.PropTypes.oneOfType,
|
| 23523 |
-
element = _react.PropTypes.element,
|
| 23524 |
-
shape = _react.PropTypes.shape,
|
| 23525 |
-
string = _react.PropTypes.string;
|
| 23526 |
function falsy(props, propName, componentName) {
|
| 23527 |
if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop');
|
| 23528 |
}
|
| 23529 |
|
| 23530 |
-
var history = exports.history = shape({
|
| 23531 |
-
listen: func.isRequired,
|
| 23532 |
-
push: func.isRequired,
|
| 23533 |
-
replace: func.isRequired,
|
| 23534 |
-
go: func.isRequired,
|
| 23535 |
-
goBack: func.isRequired,
|
| 23536 |
-
goForward: func.isRequired
|
| 23537 |
});
|
| 23538 |
|
| 23539 |
-
var component = exports.component = oneOfType([func, string]);
|
| 23540 |
-
var components = exports.components = oneOfType([component, object]);
|
| 23541 |
-
var route = exports.route = oneOfType([object, element]);
|
| 23542 |
-
var routes = exports.routes = oneOfType([route, arrayOf(route)]);
|
| 23543 |
|
| 23544 |
/***/ },
|
| 23545 |
-
/*
|
| 23546 |
/***/ function(module, exports, __webpack_require__) {
|
| 23547 |
|
| 23548 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -23553,7 +25020,7 @@ webpackJsonp([1],[
|
|
| 23553 |
|
| 23554 |
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
|
| 23555 |
|
| 23556 |
-
var _invariant = __webpack_require__(
|
| 23557 |
|
| 23558 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 23559 |
|
|
@@ -23561,39 +25028,38 @@ webpackJsonp([1],[
|
|
| 23561 |
|
| 23562 |
var _react2 = _interopRequireDefault(_react);
|
| 23563 |
|
| 23564 |
-
var
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23565 |
|
| 23566 |
var _getRouteParams2 = _interopRequireDefault(_getRouteParams);
|
| 23567 |
|
| 23568 |
-
var _ContextUtils = __webpack_require__(
|
| 23569 |
|
| 23570 |
var _RouteUtils = __webpack_require__(182);
|
| 23571 |
|
| 23572 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 23573 |
|
| 23574 |
-
var _React$PropTypes = _react2.default.PropTypes,
|
| 23575 |
-
array = _React$PropTypes.array,
|
| 23576 |
-
func = _React$PropTypes.func,
|
| 23577 |
-
object = _React$PropTypes.object;
|
| 23578 |
-
|
| 23579 |
/**
|
| 23580 |
* A <RouterContext> renders the component tree for a given router state
|
| 23581 |
* and sets the history object and the current location in context.
|
| 23582 |
*/
|
| 23583 |
-
|
| 23584 |
-
var RouterContext = _react2.default.createClass({
|
| 23585 |
displayName: 'RouterContext',
|
| 23586 |
|
| 23587 |
-
|
| 23588 |
mixins: [(0, _ContextUtils.ContextProvider)('router')],
|
| 23589 |
|
| 23590 |
propTypes: {
|
| 23591 |
-
router: object.isRequired,
|
| 23592 |
-
location: object.isRequired,
|
| 23593 |
-
routes: array.isRequired,
|
| 23594 |
-
params: object.isRequired,
|
| 23595 |
-
components: array.isRequired,
|
| 23596 |
-
createElement: func.isRequired
|
| 23597 |
},
|
| 23598 |
|
| 23599 |
getDefaultProps: function getDefaultProps() {
|
|
@@ -23604,7 +25070,7 @@ webpackJsonp([1],[
|
|
| 23604 |
|
| 23605 |
|
| 23606 |
childContextTypes: {
|
| 23607 |
-
router: object.isRequired
|
| 23608 |
},
|
| 23609 |
|
| 23610 |
getChildContext: function getChildContext() {
|
|
@@ -23681,14 +25147,14 @@ webpackJsonp([1],[
|
|
| 23681 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 23682 |
|
| 23683 |
/***/ },
|
| 23684 |
-
/*
|
| 23685 |
/***/ function(module, exports, __webpack_require__) {
|
| 23686 |
|
| 23687 |
'use strict';
|
| 23688 |
|
| 23689 |
exports.__esModule = true;
|
| 23690 |
|
| 23691 |
-
var _PatternUtils = __webpack_require__(
|
| 23692 |
|
| 23693 |
/**
|
| 23694 |
* Extracts an object of params the given route cares about from
|
|
@@ -23712,7 +25178,7 @@ webpackJsonp([1],[
|
|
| 23712 |
module.exports = exports['default'];
|
| 23713 |
|
| 23714 |
/***/ },
|
| 23715 |
-
/*
|
| 23716 |
/***/ function(module, exports, __webpack_require__) {
|
| 23717 |
|
| 23718 |
'use strict';
|
|
@@ -23721,16 +25187,20 @@ webpackJsonp([1],[
|
|
| 23721 |
exports.ContextProvider = ContextProvider;
|
| 23722 |
exports.ContextSubscriber = ContextSubscriber;
|
| 23723 |
|
| 23724 |
-
var
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23725 |
|
| 23726 |
// Works around issues with context updates failing to propagate.
|
| 23727 |
// Caveat: the context value is expected to never change its identity.
|
| 23728 |
// https://github.com/facebook/react/issues/2517
|
| 23729 |
// https://github.com/reactjs/react-router/issues/470
|
| 23730 |
|
| 23731 |
-
var contextProviderShape =
|
| 23732 |
-
subscribe:
|
| 23733 |
-
eventIndex:
|
| 23734 |
});
|
| 23735 |
|
| 23736 |
function makeContextName(name) {
|
|
@@ -23838,7 +25308,7 @@ webpackJsonp([1],[
|
|
| 23838 |
}
|
| 23839 |
|
| 23840 |
/***/ },
|
| 23841 |
-
/*
|
| 23842 |
/***/ function(module, exports) {
|
| 23843 |
|
| 23844 |
"use strict";
|
|
@@ -23871,7 +25341,7 @@ webpackJsonp([1],[
|
|
| 23871 |
}
|
| 23872 |
|
| 23873 |
/***/ },
|
| 23874 |
-
/*
|
| 23875 |
/***/ function(module, exports, __webpack_require__) {
|
| 23876 |
|
| 23877 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -23884,26 +25354,24 @@ webpackJsonp([1],[
|
|
| 23884 |
|
| 23885 |
var _react2 = _interopRequireDefault(_react);
|
| 23886 |
|
| 23887 |
-
var
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23888 |
|
| 23889 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 23890 |
|
| 23891 |
var _PropTypes = __webpack_require__(183);
|
| 23892 |
|
| 23893 |
-
var _ContextUtils = __webpack_require__(
|
| 23894 |
|
| 23895 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 23896 |
|
| 23897 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 23898 |
|
| 23899 |
-
var _React$PropTypes = _react2.default.PropTypes,
|
| 23900 |
-
bool = _React$PropTypes.bool,
|
| 23901 |
-
object = _React$PropTypes.object,
|
| 23902 |
-
string = _React$PropTypes.string,
|
| 23903 |
-
func = _React$PropTypes.func,
|
| 23904 |
-
oneOfType = _React$PropTypes.oneOfType;
|
| 23905 |
-
|
| 23906 |
-
|
| 23907 |
function isLeftClickEvent(event) {
|
| 23908 |
return event.button === 0;
|
| 23909 |
}
|
|
@@ -23935,16 +25403,10 @@ webpackJsonp([1],[
|
|
| 23935 |
* You could use the following component to link to that route:
|
| 23936 |
*
|
| 23937 |
* <Link to={`/posts/${post.id}`} />
|
| 23938 |
-
*
|
| 23939 |
-
* Links may pass along location state and/or query string parameters
|
| 23940 |
-
* in the state/query props, respectively.
|
| 23941 |
-
*
|
| 23942 |
-
* <Link ... query={{ show: true }} state={{ the: 'state' }} />
|
| 23943 |
*/
|
| 23944 |
-
var Link =
|
| 23945 |
displayName: 'Link',
|
| 23946 |
|
| 23947 |
-
|
| 23948 |
mixins: [(0, _ContextUtils.ContextSubscriber)('router')],
|
| 23949 |
|
| 23950 |
contextTypes: {
|
|
@@ -23952,15 +25414,12 @@ webpackJsonp([1],[
|
|
| 23952 |
},
|
| 23953 |
|
| 23954 |
propTypes: {
|
| 23955 |
-
to: oneOfType([string, object, func]),
|
| 23956 |
-
|
| 23957 |
-
|
| 23958 |
-
|
| 23959 |
-
|
| 23960 |
-
|
| 23961 |
-
onlyActiveOnIndex: bool.isRequired,
|
| 23962 |
-
onClick: func,
|
| 23963 |
-
target: string
|
| 23964 |
},
|
| 23965 |
|
| 23966 |
getDefaultProps: function getDefaultProps() {
|
|
@@ -24035,7 +25494,7 @@ webpackJsonp([1],[
|
|
| 24035 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24036 |
|
| 24037 |
/***/ },
|
| 24038 |
-
/*
|
| 24039 |
/***/ function(module, exports, __webpack_require__) {
|
| 24040 |
|
| 24041 |
'use strict';
|
|
@@ -24048,7 +25507,11 @@ webpackJsonp([1],[
|
|
| 24048 |
|
| 24049 |
var _react2 = _interopRequireDefault(_react);
|
| 24050 |
|
| 24051 |
-
var
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24052 |
|
| 24053 |
var _Link2 = _interopRequireDefault(_Link);
|
| 24054 |
|
|
@@ -24057,8 +25520,9 @@ webpackJsonp([1],[
|
|
| 24057 |
/**
|
| 24058 |
* An <IndexLink> is used to link to an <IndexRoute>.
|
| 24059 |
*/
|
| 24060 |
-
var IndexLink =
|
| 24061 |
displayName: 'IndexLink',
|
|
|
|
| 24062 |
render: function render() {
|
| 24063 |
return _react2.default.createElement(_Link2.default, _extends({}, this.props, { onlyActiveOnIndex: true }));
|
| 24064 |
}
|
|
@@ -24068,7 +25532,7 @@ webpackJsonp([1],[
|
|
| 24068 |
module.exports = exports['default'];
|
| 24069 |
|
| 24070 |
/***/ },
|
| 24071 |
-
/*
|
| 24072 |
/***/ function(module, exports, __webpack_require__) {
|
| 24073 |
|
| 24074 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -24079,7 +25543,7 @@ webpackJsonp([1],[
|
|
| 24079 |
|
| 24080 |
exports.default = withRouter;
|
| 24081 |
|
| 24082 |
-
var _invariant = __webpack_require__(
|
| 24083 |
|
| 24084 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24085 |
|
|
@@ -24087,11 +25551,15 @@ webpackJsonp([1],[
|
|
| 24087 |
|
| 24088 |
var _react2 = _interopRequireDefault(_react);
|
| 24089 |
|
| 24090 |
-
var
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24091 |
|
| 24092 |
var _hoistNonReactStatics2 = _interopRequireDefault(_hoistNonReactStatics);
|
| 24093 |
|
| 24094 |
-
var _ContextUtils = __webpack_require__(
|
| 24095 |
|
| 24096 |
var _PropTypes = __webpack_require__(183);
|
| 24097 |
|
|
@@ -24104,7 +25572,7 @@ webpackJsonp([1],[
|
|
| 24104 |
function withRouter(WrappedComponent, options) {
|
| 24105 |
var withRef = options && options.withRef;
|
| 24106 |
|
| 24107 |
-
var WithRouter =
|
| 24108 |
displayName: 'WithRouter',
|
| 24109 |
|
| 24110 |
mixins: [(0, _ContextUtils.ContextSubscriber)('router')],
|
|
@@ -24150,7 +25618,7 @@ webpackJsonp([1],[
|
|
| 24150 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24151 |
|
| 24152 |
/***/ },
|
| 24153 |
-
/*
|
| 24154 |
/***/ function(module, exports) {
|
| 24155 |
|
| 24156 |
/**
|
|
@@ -24206,46 +25674,42 @@ webpackJsonp([1],[
|
|
| 24206 |
|
| 24207 |
|
| 24208 |
/***/ },
|
| 24209 |
-
/*
|
| 24210 |
/***/ function(module, exports, __webpack_require__) {
|
| 24211 |
|
| 24212 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 24213 |
|
| 24214 |
exports.__esModule = true;
|
| 24215 |
|
| 24216 |
-
var
|
| 24217 |
|
| 24218 |
-
var
|
| 24219 |
|
| 24220 |
-
var
|
|
|
|
|
|
|
| 24221 |
|
| 24222 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 24223 |
|
| 24224 |
-
var _invariant = __webpack_require__(
|
| 24225 |
|
| 24226 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24227 |
|
| 24228 |
-
var _Redirect = __webpack_require__(
|
| 24229 |
|
| 24230 |
var _Redirect2 = _interopRequireDefault(_Redirect);
|
| 24231 |
|
| 24232 |
-
var _InternalPropTypes = __webpack_require__(
|
| 24233 |
|
| 24234 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24235 |
|
| 24236 |
-
var _React$PropTypes = _react2.default.PropTypes,
|
| 24237 |
-
string = _React$PropTypes.string,
|
| 24238 |
-
object = _React$PropTypes.object;
|
| 24239 |
-
|
| 24240 |
/**
|
| 24241 |
* An <IndexRedirect> is used to redirect from an indexRoute.
|
| 24242 |
*/
|
| 24243 |
/* eslint-disable react/require-render-return */
|
| 24244 |
-
|
| 24245 |
-
var IndexRedirect = _react2.default.createClass({
|
| 24246 |
displayName: 'IndexRedirect',
|
| 24247 |
|
| 24248 |
-
|
| 24249 |
statics: {
|
| 24250 |
createRouteFromReactElement: function createRouteFromReactElement(element, parentRoute) {
|
| 24251 |
/* istanbul ignore else: sanity check */
|
|
@@ -24258,9 +25722,9 @@ webpackJsonp([1],[
|
|
| 24258 |
},
|
| 24259 |
|
| 24260 |
propTypes: {
|
| 24261 |
-
to: string.isRequired,
|
| 24262 |
-
query: object,
|
| 24263 |
-
state: object,
|
| 24264 |
onEnter: _InternalPropTypes.falsy,
|
| 24265 |
children: _InternalPropTypes.falsy
|
| 24266 |
},
|
|
@@ -24276,33 +25740,31 @@ webpackJsonp([1],[
|
|
| 24276 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24277 |
|
| 24278 |
/***/ },
|
| 24279 |
-
/*
|
| 24280 |
/***/ function(module, exports, __webpack_require__) {
|
| 24281 |
|
| 24282 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 24283 |
|
| 24284 |
exports.__esModule = true;
|
| 24285 |
|
| 24286 |
-
var
|
| 24287 |
|
| 24288 |
-
var
|
| 24289 |
|
| 24290 |
-
var
|
|
|
|
|
|
|
| 24291 |
|
| 24292 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24293 |
|
| 24294 |
var _RouteUtils = __webpack_require__(182);
|
| 24295 |
|
| 24296 |
-
var _PatternUtils = __webpack_require__(
|
| 24297 |
|
| 24298 |
-
var _InternalPropTypes = __webpack_require__(
|
| 24299 |
|
| 24300 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24301 |
|
| 24302 |
-
var _React$PropTypes = _react2.default.PropTypes,
|
| 24303 |
-
string = _React$PropTypes.string,
|
| 24304 |
-
object = _React$PropTypes.object;
|
| 24305 |
-
|
| 24306 |
/**
|
| 24307 |
* A <Redirect> is used to declare another URL path a client should
|
| 24308 |
* be sent to when they request a given URL.
|
|
@@ -24311,11 +25773,9 @@ webpackJsonp([1],[
|
|
| 24311 |
* and are traversed in the same manner.
|
| 24312 |
*/
|
| 24313 |
/* eslint-disable react/require-render-return */
|
| 24314 |
-
|
| 24315 |
-
var Redirect = _react2.default.createClass({
|
| 24316 |
displayName: 'Redirect',
|
| 24317 |
|
| 24318 |
-
|
| 24319 |
statics: {
|
| 24320 |
createRouteFromReactElement: function createRouteFromReactElement(element) {
|
| 24321 |
var route = (0, _RouteUtils.createRouteFromReactElement)(element);
|
|
@@ -24365,11 +25825,11 @@ webpackJsonp([1],[
|
|
| 24365 |
},
|
| 24366 |
|
| 24367 |
propTypes: {
|
| 24368 |
-
path: string,
|
| 24369 |
-
from: string, // Alias for path
|
| 24370 |
-
to: string.isRequired,
|
| 24371 |
-
query: object,
|
| 24372 |
-
state: object,
|
| 24373 |
onEnter: _InternalPropTypes.falsy,
|
| 24374 |
children: _InternalPropTypes.falsy
|
| 24375 |
},
|
|
@@ -24385,43 +25845,41 @@ webpackJsonp([1],[
|
|
| 24385 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24386 |
|
| 24387 |
/***/ },
|
| 24388 |
-
/*
|
| 24389 |
/***/ function(module, exports, __webpack_require__) {
|
| 24390 |
|
| 24391 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 24392 |
|
| 24393 |
exports.__esModule = true;
|
| 24394 |
|
| 24395 |
-
var
|
| 24396 |
|
| 24397 |
-
var
|
| 24398 |
|
| 24399 |
-
var
|
|
|
|
|
|
|
| 24400 |
|
| 24401 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 24402 |
|
| 24403 |
-
var _invariant = __webpack_require__(
|
| 24404 |
|
| 24405 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24406 |
|
| 24407 |
var _RouteUtils = __webpack_require__(182);
|
| 24408 |
|
| 24409 |
-
var _InternalPropTypes = __webpack_require__(
|
| 24410 |
|
| 24411 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24412 |
|
| 24413 |
-
var func = _react2.default.PropTypes.func;
|
| 24414 |
-
|
| 24415 |
/**
|
| 24416 |
* An <IndexRoute> is used to specify its parent's <Route indexRoute> in
|
| 24417 |
* a JSX route config.
|
| 24418 |
*/
|
| 24419 |
/* eslint-disable react/require-render-return */
|
| 24420 |
-
|
| 24421 |
-
var IndexRoute = _react2.default.createClass({
|
| 24422 |
displayName: 'IndexRoute',
|
| 24423 |
|
| 24424 |
-
|
| 24425 |
statics: {
|
| 24426 |
createRouteFromReactElement: function createRouteFromReactElement(element, parentRoute) {
|
| 24427 |
/* istanbul ignore else: sanity check */
|
|
@@ -24437,8 +25895,8 @@ webpackJsonp([1],[
|
|
| 24437 |
path: _InternalPropTypes.falsy,
|
| 24438 |
component: _InternalPropTypes.component,
|
| 24439 |
components: _InternalPropTypes.components,
|
| 24440 |
-
getComponent: func,
|
| 24441 |
-
getComponents: func
|
| 24442 |
},
|
| 24443 |
|
| 24444 |
/* istanbul ignore next: sanity check */
|
|
@@ -24452,31 +25910,29 @@ webpackJsonp([1],[
|
|
| 24452 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24453 |
|
| 24454 |
/***/ },
|
| 24455 |
-
/*
|
| 24456 |
/***/ function(module, exports, __webpack_require__) {
|
| 24457 |
|
| 24458 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 24459 |
|
| 24460 |
exports.__esModule = true;
|
| 24461 |
|
| 24462 |
-
var
|
| 24463 |
|
| 24464 |
-
var
|
| 24465 |
|
| 24466 |
-
var
|
|
|
|
|
|
|
| 24467 |
|
| 24468 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24469 |
|
| 24470 |
var _RouteUtils = __webpack_require__(182);
|
| 24471 |
|
| 24472 |
-
var _InternalPropTypes = __webpack_require__(
|
| 24473 |
|
| 24474 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24475 |
|
| 24476 |
-
var _React$PropTypes = _react2.default.PropTypes,
|
| 24477 |
-
string = _React$PropTypes.string,
|
| 24478 |
-
func = _React$PropTypes.func;
|
| 24479 |
-
|
| 24480 |
/**
|
| 24481 |
* A <Route> is used to declare which components are rendered to the
|
| 24482 |
* page when the URL matches a given pattern.
|
|
@@ -24488,21 +25944,19 @@ webpackJsonp([1],[
|
|
| 24488 |
* rendered into the DOM, nested in the same order as in the tree.
|
| 24489 |
*/
|
| 24490 |
/* eslint-disable react/require-render-return */
|
| 24491 |
-
|
| 24492 |
-
var Route = _react2.default.createClass({
|
| 24493 |
displayName: 'Route',
|
| 24494 |
|
| 24495 |
-
|
| 24496 |
statics: {
|
| 24497 |
createRouteFromReactElement: _RouteUtils.createRouteFromReactElement
|
| 24498 |
},
|
| 24499 |
|
| 24500 |
propTypes: {
|
| 24501 |
-
path: string,
|
| 24502 |
component: _InternalPropTypes.component,
|
| 24503 |
components: _InternalPropTypes.components,
|
| 24504 |
-
getComponent: func,
|
| 24505 |
-
getComponents: func
|
| 24506 |
},
|
| 24507 |
|
| 24508 |
/* istanbul ignore next: sanity check */
|
|
@@ -24516,7 +25970,7 @@ webpackJsonp([1],[
|
|
| 24516 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24517 |
|
| 24518 |
/***/ },
|
| 24519 |
-
/*
|
| 24520 |
/***/ function(module, exports, __webpack_require__) {
|
| 24521 |
|
| 24522 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -24525,23 +25979,23 @@ webpackJsonp([1],[
|
|
| 24525 |
|
| 24526 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 24527 |
|
| 24528 |
-
var _Actions = __webpack_require__(
|
| 24529 |
|
| 24530 |
-
var _invariant = __webpack_require__(
|
| 24531 |
|
| 24532 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 24533 |
|
| 24534 |
-
var _createMemoryHistory = __webpack_require__(
|
| 24535 |
|
| 24536 |
var _createMemoryHistory2 = _interopRequireDefault(_createMemoryHistory);
|
| 24537 |
|
| 24538 |
-
var _createTransitionManager = __webpack_require__(
|
| 24539 |
|
| 24540 |
var _createTransitionManager2 = _interopRequireDefault(_createTransitionManager);
|
| 24541 |
|
| 24542 |
var _RouteUtils = __webpack_require__(182);
|
| 24543 |
|
| 24544 |
-
var _RouterUtils = __webpack_require__(
|
| 24545 |
|
| 24546 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24547 |
|
|
@@ -24594,7 +26048,7 @@ webpackJsonp([1],[
|
|
| 24594 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24595 |
|
| 24596 |
/***/ },
|
| 24597 |
-
/*
|
| 24598 |
/***/ function(module, exports) {
|
| 24599 |
|
| 24600 |
'use strict';
|
|
@@ -24621,7 +26075,7 @@ webpackJsonp([1],[
|
|
| 24621 |
var POP = exports.POP = 'POP';
|
| 24622 |
|
| 24623 |
/***/ },
|
| 24624 |
-
/*
|
| 24625 |
/***/ function(module, exports, __webpack_require__) {
|
| 24626 |
|
| 24627 |
'use strict';
|
|
@@ -24629,15 +26083,15 @@ webpackJsonp([1],[
|
|
| 24629 |
exports.__esModule = true;
|
| 24630 |
exports.default = createMemoryHistory;
|
| 24631 |
|
| 24632 |
-
var _useQueries = __webpack_require__(
|
| 24633 |
|
| 24634 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 24635 |
|
| 24636 |
-
var _useBasename = __webpack_require__(
|
| 24637 |
|
| 24638 |
var _useBasename2 = _interopRequireDefault(_useBasename);
|
| 24639 |
|
| 24640 |
-
var _createMemoryHistory = __webpack_require__(
|
| 24641 |
|
| 24642 |
var _createMemoryHistory2 = _interopRequireDefault(_createMemoryHistory);
|
| 24643 |
|
|
@@ -24657,7 +26111,7 @@ webpackJsonp([1],[
|
|
| 24657 |
module.exports = exports['default'];
|
| 24658 |
|
| 24659 |
/***/ },
|
| 24660 |
-
/*
|
| 24661 |
/***/ function(module, exports, __webpack_require__) {
|
| 24662 |
|
| 24663 |
'use strict';
|
|
@@ -24666,15 +26120,15 @@ webpackJsonp([1],[
|
|
| 24666 |
|
| 24667 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 24668 |
|
| 24669 |
-
var _queryString = __webpack_require__(
|
| 24670 |
|
| 24671 |
-
var _runTransitionHook = __webpack_require__(
|
| 24672 |
|
| 24673 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 24674 |
|
| 24675 |
-
var _LocationUtils = __webpack_require__(
|
| 24676 |
|
| 24677 |
-
var _PathUtils = __webpack_require__(
|
| 24678 |
|
| 24679 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 24680 |
|
|
@@ -24783,12 +26237,12 @@ webpackJsonp([1],[
|
|
| 24783 |
exports.default = useQueries;
|
| 24784 |
|
| 24785 |
/***/ },
|
| 24786 |
-
/*
|
| 24787 |
/***/ function(module, exports, __webpack_require__) {
|
| 24788 |
|
| 24789 |
'use strict';
|
| 24790 |
-
var strictUriEncode = __webpack_require__(
|
| 24791 |
-
var objectAssign = __webpack_require__(
|
| 24792 |
|
| 24793 |
function encoderForArrayFormat(opts) {
|
| 24794 |
switch (opts.arrayFormat) {
|
|
@@ -24992,7 +26446,7 @@ webpackJsonp([1],[
|
|
| 24992 |
|
| 24993 |
|
| 24994 |
/***/ },
|
| 24995 |
-
/*
|
| 24996 |
/***/ function(module, exports) {
|
| 24997 |
|
| 24998 |
'use strict';
|
|
@@ -25004,7 +26458,7 @@ webpackJsonp([1],[
|
|
| 25004 |
|
| 25005 |
|
| 25006 |
/***/ },
|
| 25007 |
-
/*
|
| 25008 |
/***/ function(module, exports) {
|
| 25009 |
|
| 25010 |
/*
|
|
@@ -25100,14 +26554,14 @@ webpackJsonp([1],[
|
|
| 25100 |
|
| 25101 |
|
| 25102 |
/***/ },
|
| 25103 |
-
/*
|
| 25104 |
/***/ function(module, exports, __webpack_require__) {
|
| 25105 |
|
| 25106 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25107 |
|
| 25108 |
exports.__esModule = true;
|
| 25109 |
|
| 25110 |
-
var _warning = __webpack_require__(
|
| 25111 |
|
| 25112 |
var _warning2 = _interopRequireDefault(_warning);
|
| 25113 |
|
|
@@ -25129,7 +26583,7 @@ webpackJsonp([1],[
|
|
| 25129 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25130 |
|
| 25131 |
/***/ },
|
| 25132 |
-
/*
|
| 25133 |
/***/ function(module, exports, __webpack_require__) {
|
| 25134 |
|
| 25135 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -25141,17 +26595,17 @@ webpackJsonp([1],[
|
|
| 25141 |
|
| 25142 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 25143 |
|
| 25144 |
-
var _invariant = __webpack_require__(
|
| 25145 |
|
| 25146 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25147 |
|
| 25148 |
-
var _warning = __webpack_require__(
|
| 25149 |
|
| 25150 |
var _warning2 = _interopRequireDefault(_warning);
|
| 25151 |
|
| 25152 |
-
var _PathUtils = __webpack_require__(
|
| 25153 |
|
| 25154 |
-
var _Actions = __webpack_require__(
|
| 25155 |
|
| 25156 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25157 |
|
|
@@ -25227,7 +26681,7 @@ webpackJsonp([1],[
|
|
| 25227 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25228 |
|
| 25229 |
/***/ },
|
| 25230 |
-
/*
|
| 25231 |
/***/ function(module, exports, __webpack_require__) {
|
| 25232 |
|
| 25233 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -25235,7 +26689,7 @@ webpackJsonp([1],[
|
|
| 25235 |
exports.__esModule = true;
|
| 25236 |
exports.createPath = exports.parsePath = exports.getQueryStringValueFromPath = exports.stripQueryStringValueFromPath = exports.addQueryStringValueToPath = undefined;
|
| 25237 |
|
| 25238 |
-
var _warning = __webpack_require__(
|
| 25239 |
|
| 25240 |
var _warning2 = _interopRequireDefault(_warning);
|
| 25241 |
|
|
@@ -25329,7 +26783,7 @@ webpackJsonp([1],[
|
|
| 25329 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25330 |
|
| 25331 |
/***/ },
|
| 25332 |
-
/*
|
| 25333 |
/***/ function(module, exports, __webpack_require__) {
|
| 25334 |
|
| 25335 |
'use strict';
|
|
@@ -25338,11 +26792,11 @@ webpackJsonp([1],[
|
|
| 25338 |
|
| 25339 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 25340 |
|
| 25341 |
-
var _runTransitionHook = __webpack_require__(
|
| 25342 |
|
| 25343 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 25344 |
|
| 25345 |
-
var _PathUtils = __webpack_require__(
|
| 25346 |
|
| 25347 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25348 |
|
|
@@ -25443,7 +26897,7 @@ webpackJsonp([1],[
|
|
| 25443 |
exports.default = useBasename;
|
| 25444 |
|
| 25445 |
/***/ },
|
| 25446 |
-
/*
|
| 25447 |
/***/ function(module, exports, __webpack_require__) {
|
| 25448 |
|
| 25449 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -25452,23 +26906,23 @@ webpackJsonp([1],[
|
|
| 25452 |
|
| 25453 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 25454 |
|
| 25455 |
-
var _warning = __webpack_require__(
|
| 25456 |
|
| 25457 |
var _warning2 = _interopRequireDefault(_warning);
|
| 25458 |
|
| 25459 |
-
var _invariant = __webpack_require__(
|
| 25460 |
|
| 25461 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25462 |
|
| 25463 |
-
var _LocationUtils = __webpack_require__(
|
| 25464 |
|
| 25465 |
-
var _PathUtils = __webpack_require__(
|
| 25466 |
|
| 25467 |
-
var _createHistory = __webpack_require__(
|
| 25468 |
|
| 25469 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 25470 |
|
| 25471 |
-
var _Actions = __webpack_require__(
|
| 25472 |
|
| 25473 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25474 |
|
|
@@ -25589,24 +27043,24 @@ webpackJsonp([1],[
|
|
| 25589 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25590 |
|
| 25591 |
/***/ },
|
| 25592 |
-
/*
|
| 25593 |
/***/ function(module, exports, __webpack_require__) {
|
| 25594 |
|
| 25595 |
'use strict';
|
| 25596 |
|
| 25597 |
exports.__esModule = true;
|
| 25598 |
|
| 25599 |
-
var _AsyncUtils = __webpack_require__(
|
| 25600 |
|
| 25601 |
-
var _PathUtils = __webpack_require__(
|
| 25602 |
|
| 25603 |
-
var _runTransitionHook = __webpack_require__(
|
| 25604 |
|
| 25605 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 25606 |
|
| 25607 |
-
var _Actions = __webpack_require__(
|
| 25608 |
|
| 25609 |
-
var _LocationUtils = __webpack_require__(
|
| 25610 |
|
| 25611 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25612 |
|
|
@@ -25770,7 +27224,7 @@ webpackJsonp([1],[
|
|
| 25770 |
exports.default = createHistory;
|
| 25771 |
|
| 25772 |
/***/ },
|
| 25773 |
-
/*
|
| 25774 |
/***/ function(module, exports) {
|
| 25775 |
|
| 25776 |
"use strict";
|
|
@@ -25831,7 +27285,7 @@ webpackJsonp([1],[
|
|
| 25831 |
};
|
| 25832 |
|
| 25833 |
/***/ },
|
| 25834 |
-
/*
|
| 25835 |
/***/ function(module, exports, __webpack_require__) {
|
| 25836 |
|
| 25837 |
'use strict';
|
|
@@ -25839,11 +27293,11 @@ webpackJsonp([1],[
|
|
| 25839 |
exports.__esModule = true;
|
| 25840 |
exports.default = useRouterHistory;
|
| 25841 |
|
| 25842 |
-
var _useQueries = __webpack_require__(
|
| 25843 |
|
| 25844 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 25845 |
|
| 25846 |
-
var _useBasename = __webpack_require__(
|
| 25847 |
|
| 25848 |
var _useBasename2 = _interopRequireDefault(_useBasename);
|
| 25849 |
|
|
@@ -25858,7 +27312,7 @@ webpackJsonp([1],[
|
|
| 25858 |
module.exports = exports['default'];
|
| 25859 |
|
| 25860 |
/***/ },
|
| 25861 |
-
/*
|
| 25862 |
/***/ function(module, exports, __webpack_require__) {
|
| 25863 |
|
| 25864 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -25871,11 +27325,11 @@ webpackJsonp([1],[
|
|
| 25871 |
|
| 25872 |
var _react2 = _interopRequireDefault(_react);
|
| 25873 |
|
| 25874 |
-
var _RouterContext = __webpack_require__(
|
| 25875 |
|
| 25876 |
var _RouterContext2 = _interopRequireDefault(_RouterContext);
|
| 25877 |
|
| 25878 |
-
var _routerWarning = __webpack_require__(
|
| 25879 |
|
| 25880 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 25881 |
|
|
@@ -25921,18 +27375,18 @@ webpackJsonp([1],[
|
|
| 25921 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25922 |
|
| 25923 |
/***/ },
|
| 25924 |
-
/*
|
| 25925 |
/***/ function(module, exports, __webpack_require__) {
|
| 25926 |
|
| 25927 |
'use strict';
|
| 25928 |
|
| 25929 |
exports.__esModule = true;
|
| 25930 |
|
| 25931 |
-
var _createBrowserHistory = __webpack_require__(
|
| 25932 |
|
| 25933 |
var _createBrowserHistory2 = _interopRequireDefault(_createBrowserHistory);
|
| 25934 |
|
| 25935 |
-
var _createRouterHistory = __webpack_require__(
|
| 25936 |
|
| 25937 |
var _createRouterHistory2 = _interopRequireDefault(_createRouterHistory);
|
| 25938 |
|
|
@@ -25942,7 +27396,7 @@ webpackJsonp([1],[
|
|
| 25942 |
module.exports = exports['default'];
|
| 25943 |
|
| 25944 |
/***/ },
|
| 25945 |
-
/*
|
| 25946 |
/***/ function(module, exports, __webpack_require__) {
|
| 25947 |
|
| 25948 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -25951,23 +27405,23 @@ webpackJsonp([1],[
|
|
| 25951 |
|
| 25952 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 25953 |
|
| 25954 |
-
var _invariant = __webpack_require__(
|
| 25955 |
|
| 25956 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25957 |
|
| 25958 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 25959 |
|
| 25960 |
-
var _BrowserProtocol = __webpack_require__(
|
| 25961 |
|
| 25962 |
var BrowserProtocol = _interopRequireWildcard(_BrowserProtocol);
|
| 25963 |
|
| 25964 |
-
var _RefreshProtocol = __webpack_require__(
|
| 25965 |
|
| 25966 |
var RefreshProtocol = _interopRequireWildcard(_RefreshProtocol);
|
| 25967 |
|
| 25968 |
-
var _DOMUtils = __webpack_require__(
|
| 25969 |
|
| 25970 |
-
var _createHistory = __webpack_require__(
|
| 25971 |
|
| 25972 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 25973 |
|
|
@@ -26041,7 +27495,7 @@ webpackJsonp([1],[
|
|
| 26041 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26042 |
|
| 26043 |
/***/ },
|
| 26044 |
-
/*
|
| 26045 |
/***/ function(module, exports) {
|
| 26046 |
|
| 26047 |
'use strict';
|
|
@@ -26050,7 +27504,7 @@ webpackJsonp([1],[
|
|
| 26050 |
var canUseDOM = exports.canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
| 26051 |
|
| 26052 |
/***/ },
|
| 26053 |
-
/*
|
| 26054 |
/***/ function(module, exports, __webpack_require__) {
|
| 26055 |
|
| 26056 |
'use strict';
|
|
@@ -26058,15 +27512,15 @@ webpackJsonp([1],[
|
|
| 26058 |
exports.__esModule = true;
|
| 26059 |
exports.go = exports.replaceLocation = exports.pushLocation = exports.startListener = exports.getUserConfirmation = exports.getCurrentLocation = undefined;
|
| 26060 |
|
| 26061 |
-
var _LocationUtils = __webpack_require__(
|
| 26062 |
|
| 26063 |
-
var _DOMUtils = __webpack_require__(
|
| 26064 |
|
| 26065 |
-
var _DOMStateStorage = __webpack_require__(
|
| 26066 |
|
| 26067 |
-
var _PathUtils = __webpack_require__(
|
| 26068 |
|
| 26069 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 26070 |
|
| 26071 |
var PopStateEvent = 'popstate';
|
| 26072 |
var HashChangeEvent = 'hashchange';
|
|
@@ -26154,7 +27608,7 @@ webpackJsonp([1],[
|
|
| 26154 |
};
|
| 26155 |
|
| 26156 |
/***/ },
|
| 26157 |
-
/*
|
| 26158 |
/***/ function(module, exports) {
|
| 26159 |
|
| 26160 |
'use strict';
|
|
@@ -26208,7 +27662,7 @@ webpackJsonp([1],[
|
|
| 26208 |
};
|
| 26209 |
|
| 26210 |
/***/ },
|
| 26211 |
-
/*
|
| 26212 |
/***/ function(module, exports, __webpack_require__) {
|
| 26213 |
|
| 26214 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -26216,7 +27670,7 @@ webpackJsonp([1],[
|
|
| 26216 |
exports.__esModule = true;
|
| 26217 |
exports.readState = exports.saveState = undefined;
|
| 26218 |
|
| 26219 |
-
var _warning = __webpack_require__(
|
| 26220 |
|
| 26221 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26222 |
|
|
@@ -26299,7 +27753,7 @@ webpackJsonp([1],[
|
|
| 26299 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26300 |
|
| 26301 |
/***/ },
|
| 26302 |
-
/*
|
| 26303 |
/***/ function(module, exports, __webpack_require__) {
|
| 26304 |
|
| 26305 |
'use strict';
|
|
@@ -26307,7 +27761,7 @@ webpackJsonp([1],[
|
|
| 26307 |
exports.__esModule = true;
|
| 26308 |
exports.replaceLocation = exports.pushLocation = exports.getCurrentLocation = exports.go = exports.getUserConfirmation = undefined;
|
| 26309 |
|
| 26310 |
-
var _BrowserProtocol = __webpack_require__(
|
| 26311 |
|
| 26312 |
Object.defineProperty(exports, 'getUserConfirmation', {
|
| 26313 |
enumerable: true,
|
|
@@ -26322,9 +27776,9 @@ webpackJsonp([1],[
|
|
| 26322 |
}
|
| 26323 |
});
|
| 26324 |
|
| 26325 |
-
var _LocationUtils = __webpack_require__(
|
| 26326 |
|
| 26327 |
-
var _PathUtils = __webpack_require__(
|
| 26328 |
|
| 26329 |
var getCurrentLocation = exports.getCurrentLocation = function getCurrentLocation() {
|
| 26330 |
return (0, _LocationUtils.createLocation)(window.location);
|
|
@@ -26341,20 +27795,15 @@ webpackJsonp([1],[
|
|
| 26341 |
};
|
| 26342 |
|
| 26343 |
/***/ },
|
| 26344 |
-
/*
|
| 26345 |
/***/ function(module, exports, __webpack_require__) {
|
| 26346 |
|
| 26347 |
'use strict';
|
| 26348 |
|
| 26349 |
exports.__esModule = true;
|
|
|
|
| 26350 |
|
| 26351 |
-
|
| 26352 |
-
var history = void 0;
|
| 26353 |
-
if (canUseDOM) history = (0, _useRouterHistory2.default)(createHistory)();
|
| 26354 |
-
return history;
|
| 26355 |
-
};
|
| 26356 |
-
|
| 26357 |
-
var _useRouterHistory = __webpack_require__(224);
|
| 26358 |
|
| 26359 |
var _useRouterHistory2 = _interopRequireDefault(_useRouterHistory);
|
| 26360 |
|
|
@@ -26362,21 +27811,26 @@ webpackJsonp([1],[
|
|
| 26362 |
|
| 26363 |
var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
| 26364 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 26365 |
module.exports = exports['default'];
|
| 26366 |
|
| 26367 |
/***/ },
|
| 26368 |
-
/*
|
| 26369 |
/***/ function(module, exports, __webpack_require__) {
|
| 26370 |
|
| 26371 |
'use strict';
|
| 26372 |
|
| 26373 |
exports.__esModule = true;
|
| 26374 |
|
| 26375 |
-
var _createHashHistory = __webpack_require__(
|
| 26376 |
|
| 26377 |
var _createHashHistory2 = _interopRequireDefault(_createHashHistory);
|
| 26378 |
|
| 26379 |
-
var _createRouterHistory = __webpack_require__(
|
| 26380 |
|
| 26381 |
var _createRouterHistory2 = _interopRequireDefault(_createRouterHistory);
|
| 26382 |
|
|
@@ -26386,7 +27840,7 @@ webpackJsonp([1],[
|
|
| 26386 |
module.exports = exports['default'];
|
| 26387 |
|
| 26388 |
/***/ },
|
| 26389 |
-
/*
|
| 26390 |
/***/ function(module, exports, __webpack_require__) {
|
| 26391 |
|
| 26392 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -26395,23 +27849,23 @@ webpackJsonp([1],[
|
|
| 26395 |
|
| 26396 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 26397 |
|
| 26398 |
-
var _warning = __webpack_require__(
|
| 26399 |
|
| 26400 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26401 |
|
| 26402 |
-
var _invariant = __webpack_require__(
|
| 26403 |
|
| 26404 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 26405 |
|
| 26406 |
-
var _ExecutionEnvironment = __webpack_require__(
|
| 26407 |
|
| 26408 |
-
var _DOMUtils = __webpack_require__(
|
| 26409 |
|
| 26410 |
-
var _HashProtocol = __webpack_require__(
|
| 26411 |
|
| 26412 |
var HashProtocol = _interopRequireWildcard(_HashProtocol);
|
| 26413 |
|
| 26414 |
-
var _createHistory = __webpack_require__(
|
| 26415 |
|
| 26416 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 26417 |
|
|
@@ -26539,7 +27993,7 @@ webpackJsonp([1],[
|
|
| 26539 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26540 |
|
| 26541 |
/***/ },
|
| 26542 |
-
/*
|
| 26543 |
/***/ function(module, exports, __webpack_require__) {
|
| 26544 |
|
| 26545 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
|
@@ -26547,7 +28001,7 @@ webpackJsonp([1],[
|
|
| 26547 |
exports.__esModule = true;
|
| 26548 |
exports.replaceLocation = exports.pushLocation = exports.startListener = exports.getCurrentLocation = exports.go = exports.getUserConfirmation = undefined;
|
| 26549 |
|
| 26550 |
-
var _BrowserProtocol = __webpack_require__(
|
| 26551 |
|
| 26552 |
Object.defineProperty(exports, 'getUserConfirmation', {
|
| 26553 |
enumerable: true,
|
|
@@ -26562,17 +28016,17 @@ webpackJsonp([1],[
|
|
| 26562 |
}
|
| 26563 |
});
|
| 26564 |
|
| 26565 |
-
var _warning = __webpack_require__(
|
| 26566 |
|
| 26567 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26568 |
|
| 26569 |
-
var _LocationUtils = __webpack_require__(
|
| 26570 |
|
| 26571 |
-
var _DOMUtils = __webpack_require__(
|
| 26572 |
|
| 26573 |
-
var _DOMStateStorage = __webpack_require__(
|
| 26574 |
|
| 26575 |
-
var _PathUtils = __webpack_require__(
|
| 26576 |
|
| 26577 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26578 |
|
|
@@ -26681,13 +28135,6 @@ webpackJsonp([1],[
|
|
| 26681 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26682 |
|
| 26683 |
/***/ },
|
| 26684 |
-
/* 237 */,
|
| 26685 |
-
/* 238 */,
|
| 26686 |
-
/* 239 */,
|
| 26687 |
-
/* 240 */,
|
| 26688 |
-
/* 241 */,
|
| 26689 |
-
/* 242 */,
|
| 26690 |
-
/* 243 */,
|
| 26691 |
/* 244 */,
|
| 26692 |
/* 245 */,
|
| 26693 |
/* 246 */,
|
|
@@ -26735,7 +28182,14 @@ webpackJsonp([1],[
|
|
| 26735 |
/* 288 */,
|
| 26736 |
/* 289 */,
|
| 26737 |
/* 290 */,
|
| 26738 |
-
/* 291
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 26739 |
/***/ function(module, exports) {
|
| 26740 |
|
| 26741 |
module.exports = function(module) {
|
|
@@ -26751,13 +28205,6 @@ webpackJsonp([1],[
|
|
| 26751 |
|
| 26752 |
|
| 26753 |
/***/ },
|
| 26754 |
-
/* 292 */,
|
| 26755 |
-
/* 293 */,
|
| 26756 |
-
/* 294 */,
|
| 26757 |
-
/* 295 */,
|
| 26758 |
-
/* 296 */,
|
| 26759 |
-
/* 297 */,
|
| 26760 |
-
/* 298 */,
|
| 26761 |
/* 299 */,
|
| 26762 |
/* 300 */,
|
| 26763 |
/* 301 */,
|
|
@@ -26860,22 +28307,36 @@ webpackJsonp([1],[
|
|
| 26860 |
/* 398 */,
|
| 26861 |
/* 399 */,
|
| 26862 |
/* 400 */,
|
| 26863 |
-
/* 401
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 26864 |
/***/ function(module, exports, __webpack_require__) {
|
| 26865 |
|
| 26866 |
/* WEBPACK VAR INJECTION */(function(global) {if(!global["MailPoetLib"]) global["MailPoetLib"] = {};
|
| 26867 |
-
module.exports = global["MailPoetLib"]["ReactStringReplace"] = __webpack_require__(
|
| 26868 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 26869 |
|
| 26870 |
/***/ },
|
| 26871 |
-
/*
|
| 26872 |
/***/ function(module, exports, __webpack_require__) {
|
| 26873 |
|
| 26874 |
/* eslint-disable vars-on-top, no-var, prefer-template */
|
| 26875 |
-
var isRegExp = __webpack_require__(
|
| 26876 |
-
var escapeRegExp = __webpack_require__(
|
| 26877 |
-
var isString = __webpack_require__(
|
| 26878 |
-
var flatten = __webpack_require__(
|
| 26879 |
|
| 26880 |
/**
|
| 26881 |
* Given a string, replace every substring that is matched by the `match` regex
|
|
@@ -26933,7 +28394,7 @@ webpackJsonp([1],[
|
|
| 26933 |
|
| 26934 |
|
| 26935 |
/***/ },
|
| 26936 |
-
/*
|
| 26937 |
/***/ function(module, exports, __webpack_require__) {
|
| 26938 |
|
| 26939 |
/* WEBPACK VAR INJECTION */(function(global, module) {/**
|
|
@@ -27058,10 +28519,10 @@ webpackJsonp([1],[
|
|
| 27058 |
|
| 27059 |
module.exports = isRegExp;
|
| 27060 |
|
| 27061 |
-
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(
|
| 27062 |
|
| 27063 |
/***/ },
|
| 27064 |
-
/*
|
| 27065 |
/***/ function(module, exports) {
|
| 27066 |
|
| 27067 |
/* WEBPACK VAR INJECTION */(function(global) {/**
|
|
@@ -27234,7 +28695,7 @@ webpackJsonp([1],[
|
|
| 27234 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 27235 |
|
| 27236 |
/***/ },
|
| 27237 |
-
/*
|
| 27238 |
/***/ function(module, exports) {
|
| 27239 |
|
| 27240 |
/**
|
|
@@ -27335,7 +28796,7 @@ webpackJsonp([1],[
|
|
| 27335 |
|
| 27336 |
|
| 27337 |
/***/ },
|
| 27338 |
-
/*
|
| 27339 |
/***/ function(module, exports) {
|
| 27340 |
|
| 27341 |
/* WEBPACK VAR INJECTION */(function(global) {/**
|
| 5 |
__webpack_require__(2);
|
| 6 |
__webpack_require__(34);
|
| 7 |
__webpack_require__(181);
|
| 8 |
+
module.exports = __webpack_require__(415);
|
| 9 |
|
| 10 |
|
| 11 |
/***/ },
|
| 18348 |
*/
|
| 18349 |
|
| 18350 |
function getUnboundedScrollPosition(scrollable) {
|
| 18351 |
+
if (scrollable.Window && scrollable instanceof scrollable.Window) {
|
| 18352 |
return {
|
| 18353 |
+
x: scrollable.pageXOffset || scrollable.document.documentElement.scrollLeft,
|
| 18354 |
+
y: scrollable.pageYOffset || scrollable.document.documentElement.scrollTop
|
| 18355 |
};
|
| 18356 |
}
|
| 18357 |
return {
|
| 19100 |
* @return {boolean} Whether or not the object is a DOM node.
|
| 19101 |
*/
|
| 19102 |
function isNode(object) {
|
| 19103 |
+
var doc = object ? object.ownerDocument || object : document;
|
| 19104 |
+
var defaultView = doc.defaultView || window;
|
| 19105 |
+
return !!(object && (typeof defaultView.Node === 'function' ? object instanceof defaultView.Node : typeof object === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string'));
|
| 19106 |
}
|
| 19107 |
|
| 19108 |
module.exports = isNode;
|
| 19132 |
*
|
| 19133 |
* The activeElement will be null only if the document or document body is not
|
| 19134 |
* yet defined.
|
| 19135 |
+
*
|
| 19136 |
+
* @param {?DOMDocument} doc Defaults to current document.
|
| 19137 |
+
* @return {?DOMElement}
|
| 19138 |
*/
|
| 19139 |
+
function getActiveElement(doc) /*?DOMElement*/{
|
| 19140 |
+
doc = doc || (typeof document !== 'undefined' ? document : undefined);
|
| 19141 |
+
if (typeof doc === 'undefined') {
|
| 19142 |
return null;
|
| 19143 |
}
|
| 19144 |
try {
|
| 19145 |
+
return doc.activeElement || doc.body;
|
| 19146 |
} catch (e) {
|
| 19147 |
+
return doc.body;
|
| 19148 |
}
|
| 19149 |
}
|
| 19150 |
|
| 21586 |
}
|
| 21587 |
});
|
| 21588 |
|
| 21589 |
+
var _PatternUtils = __webpack_require__(188);
|
| 21590 |
|
| 21591 |
Object.defineProperty(exports, 'formatPattern', {
|
| 21592 |
enumerable: true,
|
| 21595 |
}
|
| 21596 |
});
|
| 21597 |
|
| 21598 |
+
var _Router2 = __webpack_require__(190);
|
| 21599 |
|
| 21600 |
var _Router3 = _interopRequireDefault(_Router2);
|
| 21601 |
|
| 21602 |
+
var _Link2 = __webpack_require__(209);
|
| 21603 |
|
| 21604 |
var _Link3 = _interopRequireDefault(_Link2);
|
| 21605 |
|
| 21606 |
+
var _IndexLink2 = __webpack_require__(210);
|
| 21607 |
|
| 21608 |
var _IndexLink3 = _interopRequireDefault(_IndexLink2);
|
| 21609 |
|
| 21610 |
+
var _withRouter2 = __webpack_require__(211);
|
| 21611 |
|
| 21612 |
var _withRouter3 = _interopRequireDefault(_withRouter2);
|
| 21613 |
|
| 21614 |
+
var _IndexRedirect2 = __webpack_require__(213);
|
| 21615 |
|
| 21616 |
var _IndexRedirect3 = _interopRequireDefault(_IndexRedirect2);
|
| 21617 |
|
| 21618 |
+
var _IndexRoute2 = __webpack_require__(215);
|
| 21619 |
|
| 21620 |
var _IndexRoute3 = _interopRequireDefault(_IndexRoute2);
|
| 21621 |
|
| 21622 |
+
var _Redirect2 = __webpack_require__(214);
|
| 21623 |
|
| 21624 |
var _Redirect3 = _interopRequireDefault(_Redirect2);
|
| 21625 |
|
| 21626 |
+
var _Route2 = __webpack_require__(216);
|
| 21627 |
|
| 21628 |
var _Route3 = _interopRequireDefault(_Route2);
|
| 21629 |
|
| 21630 |
+
var _RouterContext2 = __webpack_require__(205);
|
| 21631 |
|
| 21632 |
var _RouterContext3 = _interopRequireDefault(_RouterContext2);
|
| 21633 |
|
| 21634 |
+
var _match2 = __webpack_require__(217);
|
| 21635 |
|
| 21636 |
var _match3 = _interopRequireDefault(_match2);
|
| 21637 |
|
| 21638 |
+
var _useRouterHistory2 = __webpack_require__(231);
|
| 21639 |
|
| 21640 |
var _useRouterHistory3 = _interopRequireDefault(_useRouterHistory2);
|
| 21641 |
|
| 21642 |
+
var _applyRouterMiddleware2 = __webpack_require__(232);
|
| 21643 |
|
| 21644 |
var _applyRouterMiddleware3 = _interopRequireDefault(_applyRouterMiddleware2);
|
| 21645 |
|
| 21646 |
+
var _browserHistory2 = __webpack_require__(233);
|
| 21647 |
|
| 21648 |
var _browserHistory3 = _interopRequireDefault(_browserHistory2);
|
| 21649 |
|
| 21650 |
+
var _hashHistory2 = __webpack_require__(241);
|
| 21651 |
|
| 21652 |
var _hashHistory3 = _interopRequireDefault(_hashHistory2);
|
| 21653 |
|
| 21654 |
+
var _createMemoryHistory2 = __webpack_require__(219);
|
| 21655 |
|
| 21656 |
var _createMemoryHistory3 = _interopRequireDefault(_createMemoryHistory2);
|
| 21657 |
|
| 21790 |
exports.__esModule = true;
|
| 21791 |
exports.locationShape = exports.routerShape = undefined;
|
| 21792 |
|
| 21793 |
+
var _propTypes = __webpack_require__(184);
|
| 21794 |
|
| 21795 |
+
var routerShape = exports.routerShape = (0, _propTypes.shape)({
|
| 21796 |
+
push: _propTypes.func.isRequired,
|
| 21797 |
+
replace: _propTypes.func.isRequired,
|
| 21798 |
+
go: _propTypes.func.isRequired,
|
| 21799 |
+
goBack: _propTypes.func.isRequired,
|
| 21800 |
+
goForward: _propTypes.func.isRequired,
|
| 21801 |
+
setRouteLeaveHook: _propTypes.func.isRequired,
|
| 21802 |
+
isActive: _propTypes.func.isRequired
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21803 |
});
|
| 21804 |
|
| 21805 |
+
var locationShape = exports.locationShape = (0, _propTypes.shape)({
|
| 21806 |
+
pathname: _propTypes.string.isRequired,
|
| 21807 |
+
search: _propTypes.string.isRequired,
|
| 21808 |
+
state: _propTypes.object,
|
| 21809 |
+
action: _propTypes.string.isRequired,
|
| 21810 |
+
key: _propTypes.string
|
| 21811 |
});
|
| 21812 |
|
| 21813 |
/***/ },
|
| 21814 |
/* 184 */
|
| 21815 |
/***/ function(module, exports, __webpack_require__) {
|
| 21816 |
|
| 21817 |
+
/**
|
| 21818 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 21819 |
+
* All rights reserved.
|
| 21820 |
+
*
|
| 21821 |
+
* This source code is licensed under the BSD-style license found in the
|
| 21822 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 21823 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 21824 |
+
*/
|
| 21825 |
|
| 21826 |
+
var factory = __webpack_require__(185);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21827 |
|
| 21828 |
+
var REACT_ELEMENT_TYPE = (typeof Symbol === 'function' &&
|
| 21829 |
+
Symbol.for &&
|
| 21830 |
+
Symbol.for('react.element')) ||
|
| 21831 |
+
0xeac7;
|
| 21832 |
|
| 21833 |
+
function isValidElement(object) {
|
| 21834 |
+
return typeof object === 'object' &&
|
| 21835 |
+
object !== null &&
|
| 21836 |
+
object.$$typeof === REACT_ELEMENT_TYPE;
|
| 21837 |
+
}
|
| 21838 |
|
| 21839 |
+
module.exports = factory(isValidElement);
|
| 21840 |
|
|
|
|
|
|
|
|
|
|
| 21841 |
|
| 21842 |
+
/***/ },
|
| 21843 |
+
/* 185 */
|
| 21844 |
+
/***/ function(module, exports, __webpack_require__) {
|
|
|
|
| 21845 |
|
| 21846 |
+
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 21847 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 21848 |
+
* All rights reserved.
|
| 21849 |
+
*
|
| 21850 |
+
* This source code is licensed under the BSD-style license found in the
|
| 21851 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 21852 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 21853 |
+
*/
|
| 21854 |
|
| 21855 |
+
'use strict';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21856 |
|
| 21857 |
+
var emptyFunction = __webpack_require__(14);
|
| 21858 |
+
var invariant = __webpack_require__(10);
|
| 21859 |
+
var warning = __webpack_require__(13);
|
| 21860 |
|
| 21861 |
+
var ReactPropTypesSecret = __webpack_require__(186);
|
| 21862 |
+
var checkPropTypes = __webpack_require__(187);
|
| 21863 |
|
| 21864 |
+
module.exports = function (isValidElement) {
|
| 21865 |
+
/* global Symbol */
|
| 21866 |
+
var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
|
| 21867 |
+
var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.
|
| 21868 |
|
| 21869 |
+
/**
|
| 21870 |
+
* Returns the iterator method function contained on the iterable object.
|
| 21871 |
+
*
|
| 21872 |
+
* Be sure to invoke the function with the iterable as context:
|
| 21873 |
+
*
|
| 21874 |
+
* var iteratorFn = getIteratorFn(myIterable);
|
| 21875 |
+
* if (iteratorFn) {
|
| 21876 |
+
* var iterator = iteratorFn.call(myIterable);
|
| 21877 |
+
* ...
|
| 21878 |
+
* }
|
| 21879 |
+
*
|
| 21880 |
+
* @param {?object} maybeIterable
|
| 21881 |
+
* @return {?function}
|
| 21882 |
+
*/
|
| 21883 |
+
function getIteratorFn(maybeIterable) {
|
| 21884 |
+
var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);
|
| 21885 |
+
if (typeof iteratorFn === 'function') {
|
| 21886 |
+
return iteratorFn;
|
| 21887 |
+
}
|
| 21888 |
+
}
|
| 21889 |
|
| 21890 |
+
/**
|
| 21891 |
+
* Collection of methods that allow declaration and validation of props that are
|
| 21892 |
+
* supplied to React components. Example usage:
|
| 21893 |
+
*
|
| 21894 |
+
* var Props = require('ReactPropTypes');
|
| 21895 |
+
* var MyArticle = React.createClass({
|
| 21896 |
+
* propTypes: {
|
| 21897 |
+
* // An optional string prop named "description".
|
| 21898 |
+
* description: Props.string,
|
| 21899 |
+
*
|
| 21900 |
+
* // A required enum prop named "category".
|
| 21901 |
+
* category: Props.oneOf(['News','Photos']).isRequired,
|
| 21902 |
+
*
|
| 21903 |
+
* // A prop named "dialog" that requires an instance of Dialog.
|
| 21904 |
+
* dialog: Props.instanceOf(Dialog).isRequired
|
| 21905 |
+
* },
|
| 21906 |
+
* render: function() { ... }
|
| 21907 |
+
* });
|
| 21908 |
+
*
|
| 21909 |
+
* A more formal specification of how these methods are used:
|
| 21910 |
+
*
|
| 21911 |
+
* type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)
|
| 21912 |
+
* decl := ReactPropTypes.{type}(.isRequired)?
|
| 21913 |
+
*
|
| 21914 |
+
* Each and every declaration produces a function with the same signature. This
|
| 21915 |
+
* allows the creation of custom validation functions. For example:
|
| 21916 |
+
*
|
| 21917 |
+
* var MyLink = React.createClass({
|
| 21918 |
+
* propTypes: {
|
| 21919 |
+
* // An optional string or URI prop named "href".
|
| 21920 |
+
* href: function(props, propName, componentName) {
|
| 21921 |
+
* var propValue = props[propName];
|
| 21922 |
+
* if (propValue != null && typeof propValue !== 'string' &&
|
| 21923 |
+
* !(propValue instanceof URI)) {
|
| 21924 |
+
* return new Error(
|
| 21925 |
+
* 'Expected a string or an URI for ' + propName + ' in ' +
|
| 21926 |
+
* componentName
|
| 21927 |
+
* );
|
| 21928 |
+
* }
|
| 21929 |
+
* }
|
| 21930 |
+
* },
|
| 21931 |
+
* render: function() {...}
|
| 21932 |
+
* });
|
| 21933 |
+
*
|
| 21934 |
+
* @internal
|
| 21935 |
+
*/
|
| 21936 |
|
| 21937 |
+
var ANONYMOUS = '<<anonymous>>';
|
|
|
|
| 21938 |
|
| 21939 |
+
var ReactPropTypes;
|
|
|
|
| 21940 |
|
| 21941 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 21942 |
+
// Keep in sync with production version below
|
| 21943 |
+
ReactPropTypes = {
|
| 21944 |
+
array: createPrimitiveTypeChecker('array'),
|
| 21945 |
+
bool: createPrimitiveTypeChecker('boolean'),
|
| 21946 |
+
func: createPrimitiveTypeChecker('function'),
|
| 21947 |
+
number: createPrimitiveTypeChecker('number'),
|
| 21948 |
+
object: createPrimitiveTypeChecker('object'),
|
| 21949 |
+
string: createPrimitiveTypeChecker('string'),
|
| 21950 |
+
symbol: createPrimitiveTypeChecker('symbol'),
|
| 21951 |
+
|
| 21952 |
+
any: createAnyTypeChecker(),
|
| 21953 |
+
arrayOf: createArrayOfTypeChecker,
|
| 21954 |
+
element: createElementTypeChecker(),
|
| 21955 |
+
instanceOf: createInstanceTypeChecker,
|
| 21956 |
+
node: createNodeChecker(),
|
| 21957 |
+
objectOf: createObjectOfTypeChecker,
|
| 21958 |
+
oneOf: createEnumTypeChecker,
|
| 21959 |
+
oneOfType: createUnionTypeChecker,
|
| 21960 |
+
shape: createShapeTypeChecker
|
| 21961 |
+
};
|
| 21962 |
+
} else {
|
| 21963 |
+
var productionTypeChecker = function () {
|
| 21964 |
+
invariant(false, 'React.PropTypes type checking code is stripped in production.');
|
| 21965 |
+
};
|
| 21966 |
+
productionTypeChecker.isRequired = productionTypeChecker;
|
| 21967 |
+
var getProductionTypeChecker = function () {
|
| 21968 |
+
return productionTypeChecker;
|
| 21969 |
+
};
|
| 21970 |
+
// Keep in sync with development version above
|
| 21971 |
+
ReactPropTypes = {
|
| 21972 |
+
array: productionTypeChecker,
|
| 21973 |
+
bool: productionTypeChecker,
|
| 21974 |
+
func: productionTypeChecker,
|
| 21975 |
+
number: productionTypeChecker,
|
| 21976 |
+
object: productionTypeChecker,
|
| 21977 |
+
string: productionTypeChecker,
|
| 21978 |
+
symbol: productionTypeChecker,
|
| 21979 |
+
|
| 21980 |
+
any: productionTypeChecker,
|
| 21981 |
+
arrayOf: getProductionTypeChecker,
|
| 21982 |
+
element: productionTypeChecker,
|
| 21983 |
+
instanceOf: getProductionTypeChecker,
|
| 21984 |
+
node: productionTypeChecker,
|
| 21985 |
+
objectOf: getProductionTypeChecker,
|
| 21986 |
+
oneOf: getProductionTypeChecker,
|
| 21987 |
+
oneOfType: getProductionTypeChecker,
|
| 21988 |
+
shape: getProductionTypeChecker
|
| 21989 |
+
};
|
| 21990 |
}
|
| 21991 |
|
| 21992 |
+
/**
|
| 21993 |
+
* inlined Object.is polyfill to avoid requiring consumers ship their own
|
| 21994 |
+
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is
|
| 21995 |
+
*/
|
| 21996 |
+
/*eslint-disable no-self-compare*/
|
| 21997 |
+
function is(x, y) {
|
| 21998 |
+
// SameValue algorithm
|
| 21999 |
+
if (x === y) {
|
| 22000 |
+
// Steps 1-5, 7-10
|
| 22001 |
+
// Steps 6.b-6.e: +0 != -0
|
| 22002 |
+
return x !== 0 || 1 / x === 1 / y;
|
| 22003 |
+
} else {
|
| 22004 |
+
// Step 6.a: NaN == NaN
|
| 22005 |
+
return x !== x && y !== y;
|
| 22006 |
+
}
|
| 22007 |
}
|
| 22008 |
+
/*eslint-enable no-self-compare*/
|
| 22009 |
|
| 22010 |
+
/**
|
| 22011 |
+
* We use an Error-like object for backward compatibility as people may call
|
| 22012 |
+
* PropTypes directly and inspect their output. However, we don't use real
|
| 22013 |
+
* Errors anymore. We don't inspect their stack anyway, and creating them
|
| 22014 |
+
* is prohibitively expensive if they are created too often, such as what
|
| 22015 |
+
* happens in oneOfType() for any type before the one that matched.
|
| 22016 |
+
*/
|
| 22017 |
+
function PropTypeError(message) {
|
| 22018 |
+
this.message = message;
|
| 22019 |
+
this.stack = '';
|
| 22020 |
}
|
| 22021 |
+
// Make `instanceof Error` still work for returned errors.
|
| 22022 |
+
PropTypeError.prototype = Error.prototype;
|
| 22023 |
|
| 22024 |
+
function createChainableTypeChecker(validate) {
|
| 22025 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 22026 |
+
var manualPropTypeCallCache = {};
|
| 22027 |
+
}
|
| 22028 |
+
function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {
|
| 22029 |
+
componentName = componentName || ANONYMOUS;
|
| 22030 |
+
propFullName = propFullName || propName;
|
| 22031 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 22032 |
+
if (secret !== ReactPropTypesSecret && typeof console !== 'undefined') {
|
| 22033 |
+
var cacheKey = componentName + ':' + propName;
|
| 22034 |
+
if (!manualPropTypeCallCache[cacheKey]) {
|
| 22035 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'You are manually calling a React.PropTypes validation ' + 'function for the `%s` prop on `%s`. This is deprecated ' + 'and will not work in production with the next major version. ' + 'You may be seeing this warning due to a third-party PropTypes ' + 'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.', propFullName, componentName) : void 0;
|
| 22036 |
+
manualPropTypeCallCache[cacheKey] = true;
|
| 22037 |
+
}
|
| 22038 |
+
}
|
| 22039 |
+
}
|
| 22040 |
+
if (props[propName] == null) {
|
| 22041 |
+
if (isRequired) {
|
| 22042 |
+
if (props[propName] === null) {
|
| 22043 |
+
return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));
|
| 22044 |
+
}
|
| 22045 |
+
return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));
|
| 22046 |
+
}
|
| 22047 |
+
return null;
|
| 22048 |
+
} else {
|
| 22049 |
+
return validate(props, propName, componentName, location, propFullName);
|
| 22050 |
+
}
|
| 22051 |
+
}
|
| 22052 |
+
|
| 22053 |
+
var chainedCheckType = checkType.bind(null, false);
|
| 22054 |
+
chainedCheckType.isRequired = checkType.bind(null, true);
|
| 22055 |
+
|
| 22056 |
+
return chainedCheckType;
|
| 22057 |
}
|
| 22058 |
|
| 22059 |
+
function createPrimitiveTypeChecker(expectedType) {
|
| 22060 |
+
function validate(props, propName, componentName, location, propFullName, secret) {
|
| 22061 |
+
var propValue = props[propName];
|
| 22062 |
+
var propType = getPropType(propValue);
|
| 22063 |
+
if (propType !== expectedType) {
|
| 22064 |
+
// `propValue` being instance of, say, date/regexp, pass the 'object'
|
| 22065 |
+
// check, but we can offer a more precise error message here rather than
|
| 22066 |
+
// 'of type `object`'.
|
| 22067 |
+
var preciseType = getPreciseType(propValue);
|
| 22068 |
|
| 22069 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'));
|
| 22070 |
+
}
|
|
|
|
|
|
|
| 22071 |
return null;
|
| 22072 |
}
|
| 22073 |
+
return createChainableTypeChecker(validate);
|
| 22074 |
+
}
|
| 22075 |
|
| 22076 |
+
function createAnyTypeChecker() {
|
| 22077 |
+
return createChainableTypeChecker(emptyFunction.thatReturnsNull);
|
|
|
|
| 22078 |
}
|
| 22079 |
|
| 22080 |
+
function createArrayOfTypeChecker(typeChecker) {
|
| 22081 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22082 |
+
if (typeof typeChecker !== 'function') {
|
| 22083 |
+
return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');
|
| 22084 |
+
}
|
| 22085 |
+
var propValue = props[propName];
|
| 22086 |
+
if (!Array.isArray(propValue)) {
|
| 22087 |
+
var propType = getPropType(propValue);
|
| 22088 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));
|
| 22089 |
+
}
|
| 22090 |
+
for (var i = 0; i < propValue.length; i++) {
|
| 22091 |
+
var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);
|
| 22092 |
+
if (error instanceof Error) {
|
| 22093 |
+
return error;
|
| 22094 |
+
}
|
| 22095 |
+
}
|
| 22096 |
+
return null;
|
| 22097 |
+
}
|
| 22098 |
+
return createChainableTypeChecker(validate);
|
| 22099 |
+
}
|
| 22100 |
|
| 22101 |
+
function createElementTypeChecker() {
|
| 22102 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22103 |
+
var propValue = props[propName];
|
| 22104 |
+
if (!isValidElement(propValue)) {
|
| 22105 |
+
var propType = getPropType(propValue);
|
| 22106 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));
|
| 22107 |
+
}
|
| 22108 |
+
return null;
|
| 22109 |
+
}
|
| 22110 |
+
return createChainableTypeChecker(validate);
|
| 22111 |
+
}
|
| 22112 |
|
| 22113 |
+
function createInstanceTypeChecker(expectedClass) {
|
| 22114 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22115 |
+
if (!(props[propName] instanceof expectedClass)) {
|
| 22116 |
+
var expectedClassName = expectedClass.name || ANONYMOUS;
|
| 22117 |
+
var actualClassName = getClassName(props[propName]);
|
| 22118 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));
|
| 22119 |
+
}
|
| 22120 |
+
return null;
|
| 22121 |
+
}
|
| 22122 |
+
return createChainableTypeChecker(validate);
|
| 22123 |
}
|
| 22124 |
|
| 22125 |
+
function createEnumTypeChecker(expectedValues) {
|
| 22126 |
+
if (!Array.isArray(expectedValues)) {
|
| 22127 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOf, expected an instance of array.') : void 0;
|
| 22128 |
+
return emptyFunction.thatReturnsNull;
|
| 22129 |
+
}
|
| 22130 |
|
| 22131 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22132 |
+
var propValue = props[propName];
|
| 22133 |
+
for (var i = 0; i < expectedValues.length; i++) {
|
| 22134 |
+
if (is(propValue, expectedValues[i])) {
|
| 22135 |
+
return null;
|
| 22136 |
+
}
|
| 22137 |
+
}
|
| 22138 |
|
| 22139 |
+
var valuesString = JSON.stringify(expectedValues);
|
| 22140 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + propValue + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));
|
| 22141 |
+
}
|
| 22142 |
+
return createChainableTypeChecker(validate);
|
| 22143 |
+
}
|
| 22144 |
|
| 22145 |
+
function createObjectOfTypeChecker(typeChecker) {
|
| 22146 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22147 |
+
if (typeof typeChecker !== 'function') {
|
| 22148 |
+
return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');
|
| 22149 |
+
}
|
| 22150 |
+
var propValue = props[propName];
|
| 22151 |
+
var propType = getPropType(propValue);
|
| 22152 |
+
if (propType !== 'object') {
|
| 22153 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));
|
| 22154 |
+
}
|
| 22155 |
+
for (var key in propValue) {
|
| 22156 |
+
if (propValue.hasOwnProperty(key)) {
|
| 22157 |
+
var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
|
| 22158 |
+
if (error instanceof Error) {
|
| 22159 |
+
return error;
|
| 22160 |
+
}
|
| 22161 |
+
}
|
| 22162 |
+
}
|
| 22163 |
+
return null;
|
| 22164 |
+
}
|
| 22165 |
+
return createChainableTypeChecker(validate);
|
| 22166 |
+
}
|
| 22167 |
|
| 22168 |
+
function createUnionTypeChecker(arrayOfTypeCheckers) {
|
| 22169 |
+
if (!Array.isArray(arrayOfTypeCheckers)) {
|
| 22170 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;
|
| 22171 |
+
return emptyFunction.thatReturnsNull;
|
| 22172 |
+
}
|
|
|
|
| 22173 |
|
| 22174 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22175 |
+
for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
|
| 22176 |
+
var checker = arrayOfTypeCheckers[i];
|
| 22177 |
+
if (checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret) == null) {
|
| 22178 |
+
return null;
|
| 22179 |
+
}
|
| 22180 |
+
}
|
| 22181 |
|
| 22182 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`.'));
|
| 22183 |
+
}
|
| 22184 |
+
return createChainableTypeChecker(validate);
|
| 22185 |
+
}
|
| 22186 |
|
| 22187 |
+
function createNodeChecker() {
|
| 22188 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22189 |
+
if (!isNode(props[propName])) {
|
| 22190 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));
|
| 22191 |
+
}
|
| 22192 |
+
return null;
|
| 22193 |
+
}
|
| 22194 |
+
return createChainableTypeChecker(validate);
|
| 22195 |
+
}
|
| 22196 |
|
| 22197 |
+
function createShapeTypeChecker(shapeTypes) {
|
| 22198 |
+
function validate(props, propName, componentName, location, propFullName) {
|
| 22199 |
+
var propValue = props[propName];
|
| 22200 |
+
var propType = getPropType(propValue);
|
| 22201 |
+
if (propType !== 'object') {
|
| 22202 |
+
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
|
| 22203 |
+
}
|
| 22204 |
+
for (var key in shapeTypes) {
|
| 22205 |
+
var checker = shapeTypes[key];
|
| 22206 |
+
if (!checker) {
|
| 22207 |
+
continue;
|
| 22208 |
+
}
|
| 22209 |
+
var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
|
| 22210 |
+
if (error) {
|
| 22211 |
+
return error;
|
| 22212 |
+
}
|
| 22213 |
+
}
|
| 22214 |
+
return null;
|
| 22215 |
+
}
|
| 22216 |
+
return createChainableTypeChecker(validate);
|
| 22217 |
+
}
|
| 22218 |
|
| 22219 |
+
function isNode(propValue) {
|
| 22220 |
+
switch (typeof propValue) {
|
| 22221 |
+
case 'number':
|
| 22222 |
+
case 'string':
|
| 22223 |
+
case 'undefined':
|
| 22224 |
+
return true;
|
| 22225 |
+
case 'boolean':
|
| 22226 |
+
return !propValue;
|
| 22227 |
+
case 'object':
|
| 22228 |
+
if (Array.isArray(propValue)) {
|
| 22229 |
+
return propValue.every(isNode);
|
| 22230 |
+
}
|
| 22231 |
+
if (propValue === null || isValidElement(propValue)) {
|
| 22232 |
+
return true;
|
| 22233 |
+
}
|
| 22234 |
|
| 22235 |
+
var iteratorFn = getIteratorFn(propValue);
|
| 22236 |
+
if (iteratorFn) {
|
| 22237 |
+
var iterator = iteratorFn.call(propValue);
|
| 22238 |
+
var step;
|
| 22239 |
+
if (iteratorFn !== propValue.entries) {
|
| 22240 |
+
while (!(step = iterator.next()).done) {
|
| 22241 |
+
if (!isNode(step.value)) {
|
| 22242 |
+
return false;
|
| 22243 |
+
}
|
| 22244 |
+
}
|
| 22245 |
+
} else {
|
| 22246 |
+
// Iterator will provide entry [k,v] tuples rather than values.
|
| 22247 |
+
while (!(step = iterator.next()).done) {
|
| 22248 |
+
var entry = step.value;
|
| 22249 |
+
if (entry) {
|
| 22250 |
+
if (!isNode(entry[1])) {
|
| 22251 |
+
return false;
|
| 22252 |
+
}
|
| 22253 |
+
}
|
| 22254 |
+
}
|
| 22255 |
+
}
|
| 22256 |
+
} else {
|
| 22257 |
+
return false;
|
| 22258 |
+
}
|
| 22259 |
|
| 22260 |
+
return true;
|
| 22261 |
+
default:
|
| 22262 |
+
return false;
|
| 22263 |
+
}
|
| 22264 |
+
}
|
|
|
|
|
|
|
|
|
|
| 22265 |
|
| 22266 |
+
function isSymbol(propType, propValue) {
|
| 22267 |
+
// Native Symbol.
|
| 22268 |
+
if (propType === 'symbol') {
|
| 22269 |
+
return true;
|
| 22270 |
+
}
|
| 22271 |
|
| 22272 |
+
// 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'
|
| 22273 |
+
if (propValue['@@toStringTag'] === 'Symbol') {
|
| 22274 |
+
return true;
|
| 22275 |
+
}
|
| 22276 |
|
| 22277 |
+
// Fallback for non-spec compliant Symbols which are polyfilled.
|
| 22278 |
+
if (typeof Symbol === 'function' && propValue instanceof Symbol) {
|
| 22279 |
+
return true;
|
| 22280 |
+
}
|
| 22281 |
|
| 22282 |
+
return false;
|
| 22283 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22284 |
|
| 22285 |
+
// Equivalent of `typeof` but with special handling for array and regexp.
|
| 22286 |
+
function getPropType(propValue) {
|
| 22287 |
+
var propType = typeof propValue;
|
| 22288 |
+
if (Array.isArray(propValue)) {
|
| 22289 |
+
return 'array';
|
| 22290 |
+
}
|
| 22291 |
+
if (propValue instanceof RegExp) {
|
| 22292 |
+
// Old webkits (at least until Android 4.0) return 'function' rather than
|
| 22293 |
+
// 'object' for typeof a RegExp. We'll normalize this here so that /bla/
|
| 22294 |
+
// passes PropTypes.object.
|
| 22295 |
+
return 'object';
|
| 22296 |
+
}
|
| 22297 |
+
if (isSymbol(propType, propValue)) {
|
| 22298 |
+
return 'symbol';
|
| 22299 |
+
}
|
| 22300 |
+
return propType;
|
| 22301 |
+
}
|
| 22302 |
|
| 22303 |
+
// This handles more types than `getPropType`. Only used for error messages.
|
| 22304 |
+
// See `createPrimitiveTypeChecker`.
|
| 22305 |
+
function getPreciseType(propValue) {
|
| 22306 |
+
var propType = getPropType(propValue);
|
| 22307 |
+
if (propType === 'object') {
|
| 22308 |
+
if (propValue instanceof Date) {
|
| 22309 |
+
return 'date';
|
| 22310 |
+
} else if (propValue instanceof RegExp) {
|
| 22311 |
+
return 'regexp';
|
| 22312 |
+
}
|
| 22313 |
}
|
| 22314 |
+
return propType;
|
| 22315 |
}
|
| 22316 |
|
| 22317 |
+
// Returns class name of the object, if any.
|
| 22318 |
+
function getClassName(propValue) {
|
| 22319 |
+
if (!propValue.constructor || !propValue.constructor.name) {
|
| 22320 |
+
return ANONYMOUS;
|
| 22321 |
+
}
|
| 22322 |
+
return propValue.constructor.name;
|
| 22323 |
+
}
|
| 22324 |
+
|
| 22325 |
+
ReactPropTypes.checkPropTypes = checkPropTypes;
|
| 22326 |
+
ReactPropTypes.PropTypes = ReactPropTypes;
|
| 22327 |
+
|
| 22328 |
+
return ReactPropTypes;
|
| 22329 |
+
};
|
| 22330 |
|
|
|
|
|
|
|
| 22331 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22332 |
|
| 22333 |
/***/ },
|
| 22334 |
+
/* 186 */
|
| 22335 |
+
/***/ function(module, exports) {
|
| 22336 |
+
|
| 22337 |
+
/**
|
| 22338 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 22339 |
+
* All rights reserved.
|
| 22340 |
+
*
|
| 22341 |
+
* This source code is licensed under the BSD-style license found in the
|
| 22342 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 22343 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 22344 |
+
*/
|
| 22345 |
+
|
| 22346 |
+
'use strict';
|
| 22347 |
+
|
| 22348 |
+
var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
|
| 22349 |
+
|
| 22350 |
+
module.exports = ReactPropTypesSecret;
|
| 22351 |
+
|
| 22352 |
+
|
| 22353 |
+
/***/ },
|
| 22354 |
+
/* 187 */
|
| 22355 |
/***/ function(module, exports, __webpack_require__) {
|
| 22356 |
|
| 22357 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 22358 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 22359 |
* All rights reserved.
|
| 22360 |
*
|
| 22361 |
* This source code is licensed under the BSD-style license found in the
|
| 22365 |
|
| 22366 |
'use strict';
|
| 22367 |
|
| 22368 |
+
var invariant = __webpack_require__(10);
|
| 22369 |
+
var warning = __webpack_require__(13);
|
| 22370 |
+
|
| 22371 |
+
var ReactPropTypesSecret = __webpack_require__(186);
|
| 22372 |
+
|
| 22373 |
+
var loggedTypeFailures = {};
|
| 22374 |
+
|
| 22375 |
/**
|
| 22376 |
+
* Assert that the values match with the type specs.
|
| 22377 |
+
* Error messages are memorized and will only be shown once.
|
|
|
|
|
|
|
|
|
|
| 22378 |
*
|
| 22379 |
+
* @param {object} typeSpecs Map of name to a ReactPropType
|
| 22380 |
+
* @param {object} values Runtime values that need to be type-checked
|
| 22381 |
+
* @param {string} location e.g. "prop", "context", "child context"
|
| 22382 |
+
* @param {string} componentName Name of the component for error messages.
|
| 22383 |
+
* @param {?Function} getStack Returns the component stack.
|
| 22384 |
+
* @private
|
| 22385 |
*/
|
| 22386 |
+
function checkPropTypes(typeSpecs, values, location, componentName, getStack) {
|
|
|
|
| 22387 |
if (process.env.NODE_ENV !== 'production') {
|
| 22388 |
+
for (var typeSpecName in typeSpecs) {
|
| 22389 |
+
if (typeSpecs.hasOwnProperty(typeSpecName)) {
|
| 22390 |
+
var error;
|
| 22391 |
+
// Prop type validation may throw. In case they do, we don't want to
|
| 22392 |
+
// fail the render phase where it didn't fail before. So we log it.
|
| 22393 |
+
// After these have been cleaned up, we'll let them throw.
|
| 22394 |
+
try {
|
| 22395 |
+
// This is intentionally an invariant that gets caught. It's the same
|
| 22396 |
+
// behavior as without this statement except with a better message.
|
| 22397 |
+
invariant(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', componentName || 'React class', location, typeSpecName);
|
| 22398 |
+
error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);
|
| 22399 |
+
} catch (ex) {
|
| 22400 |
+
error = ex;
|
| 22401 |
+
}
|
| 22402 |
+
process.env.NODE_ENV !== 'production' ? warning(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error) : void 0;
|
| 22403 |
+
if (error instanceof Error && !(error.message in loggedTypeFailures)) {
|
| 22404 |
+
// Only monitor this failure once because there tends to be a lot of the
|
| 22405 |
+
// same error.
|
| 22406 |
+
loggedTypeFailures[error.message] = true;
|
| 22407 |
|
| 22408 |
+
var stack = getStack ? getStack() : '';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 22409 |
|
| 22410 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : '') : void 0;
|
| 22411 |
+
}
|
| 22412 |
+
}
|
| 22413 |
+
}
|
| 22414 |
}
|
| 22415 |
+
}
|
| 22416 |
|
| 22417 |
+
module.exports = checkPropTypes;
|
| 22418 |
|
| 22419 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22420 |
|
| 22421 |
/***/ },
|
| 22422 |
+
/* 188 */
|
| 22423 |
/***/ function(module, exports, __webpack_require__) {
|
| 22424 |
|
| 22425 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 22426 |
|
| 22427 |
exports.__esModule = true;
|
| 22428 |
+
exports.compilePattern = compilePattern;
|
| 22429 |
+
exports.matchPattern = matchPattern;
|
| 22430 |
+
exports.getParamNames = getParamNames;
|
| 22431 |
+
exports.getParams = getParams;
|
| 22432 |
+
exports.formatPattern = formatPattern;
|
| 22433 |
|
| 22434 |
+
var _invariant = __webpack_require__(189);
|
|
|
|
|
|
|
| 22435 |
|
| 22436 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 22437 |
|
| 22438 |
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 22439 |
|
| 22440 |
+
function escapeRegExp(string) {
|
| 22441 |
+
return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
| 22442 |
+
}
|
| 22443 |
|
| 22444 |
+
function _compilePattern(pattern) {
|
| 22445 |
+
var regexpSource = '';
|
| 22446 |
+
var paramNames = [];
|
| 22447 |
+
var tokens = [];
|
| 22448 |
|
| 22449 |
+
var match = void 0,
|
| 22450 |
+
lastIndex = 0,
|
| 22451 |
+
matcher = /:([a-zA-Z_$][a-zA-Z0-9_$]*)|\*\*|\*|\(|\)|\\\(|\\\)/g;
|
| 22452 |
+
while (match = matcher.exec(pattern)) {
|
| 22453 |
+
if (match.index !== lastIndex) {
|
| 22454 |
+
tokens.push(pattern.slice(lastIndex, match.index));
|
| 22455 |
+
regexpSource += escapeRegExp(pattern.slice(lastIndex, match.index));
|
| 22456 |
+
}
|
| 22457 |
|
| 22458 |
+
if (match[1]) {
|
| 22459 |
+
regexpSource += '([^/]+)';
|
| 22460 |
+
paramNames.push(match[1]);
|
| 22461 |
+
} else if (match[0] === '**') {
|
| 22462 |
+
regexpSource += '(.*)';
|
| 22463 |
+
paramNames.push('splat');
|
| 22464 |
+
} else if (match[0] === '*') {
|
| 22465 |
+
regexpSource += '(.*?)';
|
| 22466 |
+
paramNames.push('splat');
|
| 22467 |
+
} else if (match[0] === '(') {
|
| 22468 |
+
regexpSource += '(?:';
|
| 22469 |
+
} else if (match[0] === ')') {
|
| 22470 |
+
regexpSource += ')?';
|
| 22471 |
+
} else if (match[0] === '\\(') {
|
| 22472 |
+
regexpSource += '\\(';
|
| 22473 |
+
} else if (match[0] === '\\)') {
|
| 22474 |
+
regexpSource += '\\)';
|
| 22475 |
+
}
|
| 22476 |
|
| 22477 |
+
tokens.push(match[0]);
|
| 22478 |
|
| 22479 |
+
lastIndex = matcher.lastIndex;
|
| 22480 |
+
}
|
| 22481 |
|
| 22482 |
+
if (lastIndex !== pattern.length) {
|
| 22483 |
+
tokens.push(pattern.slice(lastIndex, pattern.length));
|
| 22484 |
+
regexpSource += escapeRegExp(pattern.slice(lastIndex, pattern.length));
|
| 22485 |
+
}
|
| 22486 |
+
|
| 22487 |
+
return {
|
| 22488 |
+
pattern: pattern,
|
| 22489 |
+
regexpSource: regexpSource,
|
| 22490 |
+
paramNames: paramNames,
|
| 22491 |
+
tokens: tokens
|
| 22492 |
+
};
|
| 22493 |
+
}
|
| 22494 |
+
|
| 22495 |
+
var CompiledPatternsCache = Object.create(null);
|
| 22496 |
+
|
| 22497 |
+
function compilePattern(pattern) {
|
| 22498 |
+
if (!CompiledPatternsCache[pattern]) CompiledPatternsCache[pattern] = _compilePattern(pattern);
|
| 22499 |
+
|
| 22500 |
+
return CompiledPatternsCache[pattern];
|
| 22501 |
+
}
|
| 22502 |
+
|
| 22503 |
+
/**
|
| 22504 |
+
* Attempts to match a pattern on the given pathname. Patterns may use
|
| 22505 |
+
* the following special characters:
|
| 22506 |
+
*
|
| 22507 |
+
* - :paramName Matches a URL segment up to the next /, ?, or #. The
|
| 22508 |
+
* captured string is considered a "param"
|
| 22509 |
+
* - () Wraps a segment of the URL that is optional
|
| 22510 |
+
* - * Consumes (non-greedy) all characters up to the next
|
| 22511 |
+
* character in the pattern, or to the end of the URL if
|
| 22512 |
+
* there is none
|
| 22513 |
+
* - ** Consumes (greedy) all characters up to the next character
|
| 22514 |
+
* in the pattern, or to the end of the URL if there is none
|
| 22515 |
+
*
|
| 22516 |
+
* The function calls callback(error, matched) when finished.
|
| 22517 |
+
* The return value is an object with the following properties:
|
| 22518 |
+
*
|
| 22519 |
+
* - remainingPathname
|
| 22520 |
+
* - paramNames
|
| 22521 |
+
* - paramValues
|
| 22522 |
+
*/
|
| 22523 |
+
function matchPattern(pattern, pathname) {
|
| 22524 |
+
// Ensure pattern starts with leading slash for consistency with pathname.
|
| 22525 |
+
if (pattern.charAt(0) !== '/') {
|
| 22526 |
+
pattern = '/' + pattern;
|
| 22527 |
+
}
|
| 22528 |
+
|
| 22529 |
+
var _compilePattern2 = compilePattern(pattern),
|
| 22530 |
+
regexpSource = _compilePattern2.regexpSource,
|
| 22531 |
+
paramNames = _compilePattern2.paramNames,
|
| 22532 |
+
tokens = _compilePattern2.tokens;
|
| 22533 |
+
|
| 22534 |
+
if (pattern.charAt(pattern.length - 1) !== '/') {
|
| 22535 |
+
regexpSource += '/?'; // Allow optional path separator at end.
|
| 22536 |
+
}
|
| 22537 |
+
|
| 22538 |
+
// Special-case patterns like '*' for catch-all routes.
|
| 22539 |
+
if (tokens[tokens.length - 1] === '*') {
|
| 22540 |
+
regexpSource += '$';
|
| 22541 |
+
}
|
| 22542 |
+
|
| 22543 |
+
var match = pathname.match(new RegExp('^' + regexpSource, 'i'));
|
| 22544 |
+
if (match == null) {
|
| 22545 |
+
return null;
|
| 22546 |
+
}
|
| 22547 |
+
|
| 22548 |
+
var matchedPath = match[0];
|
| 22549 |
+
var remainingPathname = pathname.substr(matchedPath.length);
|
| 22550 |
+
|
| 22551 |
+
if (remainingPathname) {
|
| 22552 |
+
// Require that the match ends at a path separator, if we didn't match
|
| 22553 |
+
// the full path, so any remaining pathname is a new path segment.
|
| 22554 |
+
if (matchedPath.charAt(matchedPath.length - 1) !== '/') {
|
| 22555 |
+
return null;
|
| 22556 |
+
}
|
| 22557 |
+
|
| 22558 |
+
// If there is a remaining pathname, treat the path separator as part of
|
| 22559 |
+
// the remaining pathname for properly continuing the match.
|
| 22560 |
+
remainingPathname = '/' + remainingPathname;
|
| 22561 |
+
}
|
| 22562 |
+
|
| 22563 |
+
return {
|
| 22564 |
+
remainingPathname: remainingPathname,
|
| 22565 |
+
paramNames: paramNames,
|
| 22566 |
+
paramValues: match.slice(1).map(function (v) {
|
| 22567 |
+
return v && decodeURIComponent(v);
|
| 22568 |
+
})
|
| 22569 |
+
};
|
| 22570 |
+
}
|
| 22571 |
+
|
| 22572 |
+
function getParamNames(pattern) {
|
| 22573 |
+
return compilePattern(pattern).paramNames;
|
| 22574 |
+
}
|
| 22575 |
+
|
| 22576 |
+
function getParams(pattern, pathname) {
|
| 22577 |
+
var match = matchPattern(pattern, pathname);
|
| 22578 |
+
if (!match) {
|
| 22579 |
+
return null;
|
| 22580 |
+
}
|
| 22581 |
+
|
| 22582 |
+
var paramNames = match.paramNames,
|
| 22583 |
+
paramValues = match.paramValues;
|
| 22584 |
+
|
| 22585 |
+
var params = {};
|
| 22586 |
+
|
| 22587 |
+
paramNames.forEach(function (paramName, index) {
|
| 22588 |
+
params[paramName] = paramValues[index];
|
| 22589 |
+
});
|
| 22590 |
+
|
| 22591 |
+
return params;
|
| 22592 |
+
}
|
| 22593 |
+
|
| 22594 |
+
/**
|
| 22595 |
+
* Returns a version of the given pattern with params interpolated. Throws
|
| 22596 |
+
* if there is a dynamic segment of the pattern for which there is no param.
|
| 22597 |
+
*/
|
| 22598 |
+
function formatPattern(pattern, params) {
|
| 22599 |
+
params = params || {};
|
| 22600 |
+
|
| 22601 |
+
var _compilePattern3 = compilePattern(pattern),
|
| 22602 |
+
tokens = _compilePattern3.tokens;
|
| 22603 |
+
|
| 22604 |
+
var parenCount = 0,
|
| 22605 |
+
pathname = '',
|
| 22606 |
+
splatIndex = 0,
|
| 22607 |
+
parenHistory = [];
|
| 22608 |
+
|
| 22609 |
+
var token = void 0,
|
| 22610 |
+
paramName = void 0,
|
| 22611 |
+
paramValue = void 0;
|
| 22612 |
+
for (var i = 0, len = tokens.length; i < len; ++i) {
|
| 22613 |
+
token = tokens[i];
|
| 22614 |
+
|
| 22615 |
+
if (token === '*' || token === '**') {
|
| 22616 |
+
paramValue = Array.isArray(params.splat) ? params.splat[splatIndex++] : params.splat;
|
| 22617 |
+
|
| 22618 |
+
!(paramValue != null || parenCount > 0) ? process.env.NODE_ENV !== 'production' ? (0, _invariant2.default)(false, 'Missing splat #%s for path "%s"', splatIndex, pattern) : (0, _invariant2.default)(false) : void 0;
|
| 22619 |
+
|
| 22620 |
+
if (paramValue != null) pathname += encodeURI(paramValue);
|
| 22621 |
+
} else if (token === '(') {
|
| 22622 |
+
parenHistory[parenCount] = '';
|
| 22623 |
+
parenCount += 1;
|
| 22624 |
+
} else if (token === ')') {
|
| 22625 |
+
var parenText = parenHistory.pop();
|
| 22626 |
+
parenCount -= 1;
|
| 22627 |
+
|
| 22628 |
+
if (parenCount) parenHistory[parenCount - 1] += parenText;else pathname += parenText;
|
| 22629 |
+
} else if (token === '\\(') {
|
| 22630 |
+
pathname += '(';
|
| 22631 |
+
} else if (token === '\\)') {
|
| 22632 |
+
pathname += ')';
|
| 22633 |
+
} else if (token.charAt(0) === ':') {
|
| 22634 |
+
paramName = token.substring(1);
|
| 22635 |
+
paramValue = params[paramName];
|
| 22636 |
+
|
| 22637 |
+
!(paramValue != null || parenCount > 0) ? process.env.NODE_ENV !== 'production' ? (0, _invariant2.default)(false, 'Missing "%s" parameter for path "%s"', paramName, pattern) : (0, _invariant2.default)(false) : void 0;
|
| 22638 |
+
|
| 22639 |
+
if (paramValue == null) {
|
| 22640 |
+
if (parenCount) {
|
| 22641 |
+
parenHistory[parenCount - 1] = '';
|
| 22642 |
+
|
| 22643 |
+
var curTokenIdx = tokens.indexOf(token);
|
| 22644 |
+
var tokensSubset = tokens.slice(curTokenIdx, tokens.length);
|
| 22645 |
+
var nextParenIdx = -1;
|
| 22646 |
+
|
| 22647 |
+
for (var _i = 0; _i < tokensSubset.length; _i++) {
|
| 22648 |
+
if (tokensSubset[_i] == ')') {
|
| 22649 |
+
nextParenIdx = _i;
|
| 22650 |
+
break;
|
| 22651 |
+
}
|
| 22652 |
+
}
|
| 22653 |
+
|
| 22654 |
+
!(nextParenIdx > 0) ? process.env.NODE_ENV !== 'production' ? (0, _invariant2.default)(false, 'Path "%s" is missing end paren at segment "%s"', pattern, tokensSubset.join('')) : (0, _invariant2.default)(false) : void 0;
|
| 22655 |
+
|
| 22656 |
+
// jump to ending paren
|
| 22657 |
+
i = curTokenIdx + nextParenIdx - 1;
|
| 22658 |
+
}
|
| 22659 |
+
} else if (parenCount) parenHistory[parenCount - 1] += encodeURIComponent(paramValue);else pathname += encodeURIComponent(paramValue);
|
| 22660 |
+
} else {
|
| 22661 |
+
if (parenCount) parenHistory[parenCount - 1] += token;else pathname += token;
|
| 22662 |
+
}
|
| 22663 |
+
}
|
| 22664 |
+
|
| 22665 |
+
!(parenCount <= 0) ? process.env.NODE_ENV !== 'production' ? (0, _invariant2.default)(false, 'Path "%s" is missing end paren', pattern) : (0, _invariant2.default)(false) : void 0;
|
| 22666 |
+
|
| 22667 |
+
return pathname.replace(/\/+/g, '/');
|
| 22668 |
+
}
|
| 22669 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22670 |
+
|
| 22671 |
+
/***/ },
|
| 22672 |
+
/* 189 */
|
| 22673 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 22674 |
+
|
| 22675 |
+
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 22676 |
+
* Copyright 2013-2015, Facebook, Inc.
|
| 22677 |
+
* All rights reserved.
|
| 22678 |
+
*
|
| 22679 |
+
* This source code is licensed under the BSD-style license found in the
|
| 22680 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 22681 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 22682 |
+
*/
|
| 22683 |
+
|
| 22684 |
+
'use strict';
|
| 22685 |
+
|
| 22686 |
+
/**
|
| 22687 |
+
* Use invariant() to assert state which your program assumes to be true.
|
| 22688 |
+
*
|
| 22689 |
+
* Provide sprintf-style format (only %s is supported) and arguments
|
| 22690 |
+
* to provide information about what broke and what you were
|
| 22691 |
+
* expecting.
|
| 22692 |
+
*
|
| 22693 |
+
* The invariant message will be stripped in production, but the invariant
|
| 22694 |
+
* will remain to ensure logic does not differ in production.
|
| 22695 |
+
*/
|
| 22696 |
+
|
| 22697 |
+
var invariant = function(condition, format, a, b, c, d, e, f) {
|
| 22698 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 22699 |
+
if (format === undefined) {
|
| 22700 |
+
throw new Error('invariant requires an error message argument');
|
| 22701 |
+
}
|
| 22702 |
+
}
|
| 22703 |
+
|
| 22704 |
+
if (!condition) {
|
| 22705 |
+
var error;
|
| 22706 |
+
if (format === undefined) {
|
| 22707 |
+
error = new Error(
|
| 22708 |
+
'Minified exception occurred; use the non-minified dev environment ' +
|
| 22709 |
+
'for the full error message and additional helpful warnings.'
|
| 22710 |
+
);
|
| 22711 |
+
} else {
|
| 22712 |
+
var args = [a, b, c, d, e, f];
|
| 22713 |
+
var argIndex = 0;
|
| 22714 |
+
error = new Error(
|
| 22715 |
+
format.replace(/%s/g, function() { return args[argIndex++]; })
|
| 22716 |
+
);
|
| 22717 |
+
error.name = 'Invariant Violation';
|
| 22718 |
+
}
|
| 22719 |
+
|
| 22720 |
+
error.framesToPop = 1; // we don't care about invariant's own frame
|
| 22721 |
+
throw error;
|
| 22722 |
+
}
|
| 22723 |
+
};
|
| 22724 |
+
|
| 22725 |
+
module.exports = invariant;
|
| 22726 |
+
|
| 22727 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22728 |
+
|
| 22729 |
+
/***/ },
|
| 22730 |
+
/* 190 */
|
| 22731 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 22732 |
+
|
| 22733 |
+
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 22734 |
+
|
| 22735 |
+
exports.__esModule = true;
|
| 22736 |
+
|
| 22737 |
+
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 22738 |
+
|
| 22739 |
+
var _invariant = __webpack_require__(189);
|
| 22740 |
+
|
| 22741 |
+
var _invariant2 = _interopRequireDefault(_invariant);
|
| 22742 |
+
|
| 22743 |
+
var _react = __webpack_require__(2);
|
| 22744 |
+
|
| 22745 |
+
var _react2 = _interopRequireDefault(_react);
|
| 22746 |
+
|
| 22747 |
+
var _createReactClass = __webpack_require__(191);
|
| 22748 |
+
|
| 22749 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 22750 |
+
|
| 22751 |
+
var _propTypes = __webpack_require__(184);
|
| 22752 |
+
|
| 22753 |
+
var _createTransitionManager2 = __webpack_require__(194);
|
| 22754 |
+
|
| 22755 |
+
var _createTransitionManager3 = _interopRequireDefault(_createTransitionManager2);
|
| 22756 |
+
|
| 22757 |
+
var _InternalPropTypes = __webpack_require__(204);
|
| 22758 |
+
|
| 22759 |
+
var _RouterContext = __webpack_require__(205);
|
| 22760 |
+
|
| 22761 |
+
var _RouterContext2 = _interopRequireDefault(_RouterContext);
|
| 22762 |
+
|
| 22763 |
+
var _RouteUtils = __webpack_require__(182);
|
| 22764 |
+
|
| 22765 |
+
var _RouterUtils = __webpack_require__(208);
|
| 22766 |
+
|
| 22767 |
+
var _routerWarning = __webpack_require__(195);
|
| 22768 |
+
|
| 22769 |
+
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 22770 |
+
|
| 22771 |
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 22772 |
+
|
| 22773 |
+
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 22774 |
+
|
| 22775 |
+
var propTypes = {
|
| 22776 |
+
history: _propTypes.object,
|
| 22777 |
+
children: _InternalPropTypes.routes,
|
| 22778 |
+
routes: _InternalPropTypes.routes, // alias for children
|
| 22779 |
+
render: _propTypes.func,
|
| 22780 |
+
createElement: _propTypes.func,
|
| 22781 |
+
onError: _propTypes.func,
|
| 22782 |
+
onUpdate: _propTypes.func,
|
| 22783 |
+
|
| 22784 |
+
// PRIVATE: For client-side rehydration of server match.
|
| 22785 |
+
matchContext: _propTypes.object
|
| 22786 |
+
};
|
| 22787 |
+
|
| 22788 |
+
/**
|
| 22789 |
+
* A <Router> is a high-level API for automatically setting up
|
| 22790 |
+
* a router that renders a <RouterContext> with all the props
|
| 22791 |
+
* it needs each time the URL changes.
|
| 22792 |
+
*/
|
| 22793 |
+
var Router = (0, _createReactClass2.default)({
|
| 22794 |
+
displayName: 'Router',
|
| 22795 |
+
|
| 22796 |
+
propTypes: propTypes,
|
| 22797 |
+
|
| 22798 |
+
getDefaultProps: function getDefaultProps() {
|
| 22799 |
+
return {
|
| 22800 |
+
render: function render(props) {
|
| 22801 |
+
return _react2.default.createElement(_RouterContext2.default, props);
|
| 22802 |
+
}
|
| 22803 |
+
};
|
| 22804 |
+
},
|
| 22805 |
+
getInitialState: function getInitialState() {
|
| 22806 |
+
return {
|
| 22807 |
+
location: null,
|
| 22808 |
+
routes: null,
|
| 22809 |
+
params: null,
|
| 22810 |
+
components: null
|
| 22811 |
+
};
|
| 22812 |
+
},
|
| 22813 |
+
handleError: function handleError(error) {
|
| 22814 |
+
if (this.props.onError) {
|
| 22815 |
+
this.props.onError.call(this, error);
|
| 22816 |
+
} else {
|
| 22817 |
+
// Throw errors by default so we don't silently swallow them!
|
| 22818 |
+
throw error; // This error probably occurred in getChildRoutes or getComponents.
|
| 22819 |
+
}
|
| 22820 |
+
},
|
| 22821 |
+
createRouterObject: function createRouterObject(state) {
|
| 22822 |
+
var matchContext = this.props.matchContext;
|
| 22823 |
+
|
| 22824 |
+
if (matchContext) {
|
| 22825 |
+
return matchContext.router;
|
| 22826 |
+
}
|
| 22827 |
+
|
| 22828 |
+
var history = this.props.history;
|
| 22829 |
+
|
| 22830 |
+
return (0, _RouterUtils.createRouterObject)(history, this.transitionManager, state);
|
| 22831 |
+
},
|
| 22832 |
+
createTransitionManager: function createTransitionManager() {
|
| 22833 |
+
var matchContext = this.props.matchContext;
|
| 22834 |
+
|
| 22835 |
+
if (matchContext) {
|
| 22836 |
+
return matchContext.transitionManager;
|
| 22837 |
+
}
|
| 22838 |
+
|
| 22839 |
+
var history = this.props.history;
|
| 22840 |
+
var _props = this.props,
|
| 22841 |
+
routes = _props.routes,
|
| 22842 |
+
children = _props.children;
|
| 22843 |
+
|
| 22844 |
+
|
| 22845 |
+
!history.getCurrentLocation ? process.env.NODE_ENV !== 'production' ? (0, _invariant2.default)(false, 'You have provided a history object created with history v4.x or v2.x ' + 'and earlier. This version of React Router is only compatible with v3 ' + 'history objects. Please change to history v3.x.') : (0, _invariant2.default)(false) : void 0;
|
| 22846 |
+
|
| 22847 |
+
return (0, _createTransitionManager3.default)(history, (0, _RouteUtils.createRoutes)(routes || children));
|
| 22848 |
+
},
|
| 22849 |
+
componentWillMount: function componentWillMount() {
|
| 22850 |
+
var _this = this;
|
| 22851 |
+
|
| 22852 |
+
this.transitionManager = this.createTransitionManager();
|
| 22853 |
+
this.router = this.createRouterObject(this.state);
|
| 22854 |
+
|
| 22855 |
+
this._unlisten = this.transitionManager.listen(function (error, state) {
|
| 22856 |
+
if (error) {
|
| 22857 |
+
_this.handleError(error);
|
| 22858 |
+
} else {
|
| 22859 |
+
// Keep the identity of this.router because of a caveat in ContextUtils:
|
| 22860 |
+
// they only work if the object identity is preserved.
|
| 22861 |
+
(0, _RouterUtils.assignRouterState)(_this.router, state);
|
| 22862 |
+
_this.setState(state, _this.props.onUpdate);
|
| 22863 |
+
}
|
| 22864 |
+
});
|
| 22865 |
+
},
|
| 22866 |
+
|
| 22867 |
+
|
| 22868 |
+
/* istanbul ignore next: sanity check */
|
| 22869 |
+
componentWillReceiveProps: function componentWillReceiveProps(nextProps) {
|
| 22870 |
+
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)(nextProps.history === this.props.history, 'You cannot change <Router history>; it will be ignored') : void 0;
|
| 22871 |
+
|
| 22872 |
+
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)((nextProps.routes || nextProps.children) === (this.props.routes || this.props.children), 'You cannot change <Router routes>; it will be ignored') : void 0;
|
| 22873 |
+
},
|
| 22874 |
+
componentWillUnmount: function componentWillUnmount() {
|
| 22875 |
+
if (this._unlisten) this._unlisten();
|
| 22876 |
+
},
|
| 22877 |
+
render: function render() {
|
| 22878 |
+
var _state = this.state,
|
| 22879 |
+
location = _state.location,
|
| 22880 |
+
routes = _state.routes,
|
| 22881 |
+
params = _state.params,
|
| 22882 |
+
components = _state.components;
|
| 22883 |
+
|
| 22884 |
+
var _props2 = this.props,
|
| 22885 |
+
createElement = _props2.createElement,
|
| 22886 |
+
render = _props2.render,
|
| 22887 |
+
props = _objectWithoutProperties(_props2, ['createElement', 'render']);
|
| 22888 |
+
|
| 22889 |
+
if (location == null) return null; // Async match
|
| 22890 |
+
|
| 22891 |
+
// Only forward non-Router-specific props to routing context, as those are
|
| 22892 |
+
// the only ones that might be custom routing context props.
|
| 22893 |
+
Object.keys(propTypes).forEach(function (propType) {
|
| 22894 |
+
return delete props[propType];
|
| 22895 |
+
});
|
| 22896 |
+
|
| 22897 |
+
return render(_extends({}, props, {
|
| 22898 |
+
router: this.router,
|
| 22899 |
+
location: location,
|
| 22900 |
+
routes: routes,
|
| 22901 |
+
params: params,
|
| 22902 |
+
components: components,
|
| 22903 |
+
createElement: createElement
|
| 22904 |
+
}));
|
| 22905 |
+
}
|
| 22906 |
+
});
|
| 22907 |
+
|
| 22908 |
+
exports.default = Router;
|
| 22909 |
+
module.exports = exports['default'];
|
| 22910 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 22911 |
+
|
| 22912 |
+
/***/ },
|
| 22913 |
+
/* 191 */
|
| 22914 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 22915 |
+
|
| 22916 |
+
/**
|
| 22917 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 22918 |
+
* All rights reserved.
|
| 22919 |
+
*
|
| 22920 |
+
* This source code is licensed under the BSD-style license found in the
|
| 22921 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 22922 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 22923 |
+
*
|
| 22924 |
+
*/
|
| 22925 |
+
|
| 22926 |
+
'use strict';
|
| 22927 |
+
|
| 22928 |
+
var React = __webpack_require__(2);
|
| 22929 |
+
var factory = __webpack_require__(192);
|
| 22930 |
+
|
| 22931 |
+
// Hack to grab NoopUpdateQueue from isomorphic React
|
| 22932 |
+
var ReactNoopUpdateQueue = new React.Component().updater;
|
| 22933 |
+
|
| 22934 |
+
module.exports = factory(
|
| 22935 |
+
React.Component,
|
| 22936 |
+
React.isValidElement,
|
| 22937 |
+
ReactNoopUpdateQueue
|
| 22938 |
+
);
|
| 22939 |
+
|
| 22940 |
+
|
| 22941 |
+
/***/ },
|
| 22942 |
+
/* 192 */
|
| 22943 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 22944 |
+
|
| 22945 |
+
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 22946 |
+
* Copyright 2013-present, Facebook, Inc.
|
| 22947 |
+
* All rights reserved.
|
| 22948 |
+
*
|
| 22949 |
+
* This source code is licensed under the BSD-style license found in the
|
| 22950 |
+
* LICENSE file in the root directory of this source tree. An additional grant
|
| 22951 |
+
* of patent rights can be found in the PATENTS file in the same directory.
|
| 22952 |
+
*
|
| 22953 |
+
*/
|
| 22954 |
+
|
| 22955 |
+
'use strict';
|
| 22956 |
+
|
| 22957 |
+
var _assign = __webpack_require__(193);
|
| 22958 |
+
|
| 22959 |
+
var emptyObject = __webpack_require__(22);
|
| 22960 |
+
var _invariant = __webpack_require__(10);
|
| 22961 |
+
|
| 22962 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 22963 |
+
var warning = __webpack_require__(13);
|
| 22964 |
+
}
|
| 22965 |
+
|
| 22966 |
+
var MIXINS_KEY = 'mixins';
|
| 22967 |
+
|
| 22968 |
+
// Helper function to allow the creation of anonymous functions which do not
|
| 22969 |
+
// have .name set to the name of the variable being assigned to.
|
| 22970 |
+
function identity(fn) {
|
| 22971 |
+
return fn;
|
| 22972 |
+
}
|
| 22973 |
+
|
| 22974 |
+
var ReactPropTypeLocationNames;
|
| 22975 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 22976 |
+
ReactPropTypeLocationNames = {
|
| 22977 |
+
prop: 'prop',
|
| 22978 |
+
context: 'context',
|
| 22979 |
+
childContext: 'child context',
|
| 22980 |
+
};
|
| 22981 |
+
} else {
|
| 22982 |
+
ReactPropTypeLocationNames = {};
|
| 22983 |
+
}
|
| 22984 |
+
|
| 22985 |
+
function factory(ReactComponent, isValidElement, ReactNoopUpdateQueue) {
|
| 22986 |
+
/**
|
| 22987 |
+
* Policies that describe methods in `ReactClassInterface`.
|
| 22988 |
+
*/
|
| 22989 |
+
|
| 22990 |
+
|
| 22991 |
+
var injectedMixins = [];
|
| 22992 |
+
|
| 22993 |
+
/**
|
| 22994 |
+
* Composite components are higher-level components that compose other composite
|
| 22995 |
+
* or host components.
|
| 22996 |
+
*
|
| 22997 |
+
* To create a new type of `ReactClass`, pass a specification of
|
| 22998 |
+
* your new class to `React.createClass`. The only requirement of your class
|
| 22999 |
+
* specification is that you implement a `render` method.
|
| 23000 |
+
*
|
| 23001 |
+
* var MyComponent = React.createClass({
|
| 23002 |
+
* render: function() {
|
| 23003 |
+
* return <div>Hello World</div>;
|
| 23004 |
+
* }
|
| 23005 |
+
* });
|
| 23006 |
+
*
|
| 23007 |
+
* The class specification supports a specific protocol of methods that have
|
| 23008 |
+
* special meaning (e.g. `render`). See `ReactClassInterface` for
|
| 23009 |
+
* more the comprehensive protocol. Any other properties and methods in the
|
| 23010 |
+
* class specification will be available on the prototype.
|
| 23011 |
+
*
|
| 23012 |
+
* @interface ReactClassInterface
|
| 23013 |
+
* @internal
|
| 23014 |
+
*/
|
| 23015 |
+
var ReactClassInterface = {
|
| 23016 |
+
|
| 23017 |
+
/**
|
| 23018 |
+
* An array of Mixin objects to include when defining your component.
|
| 23019 |
+
*
|
| 23020 |
+
* @type {array}
|
| 23021 |
+
* @optional
|
| 23022 |
+
*/
|
| 23023 |
+
mixins: 'DEFINE_MANY',
|
| 23024 |
+
|
| 23025 |
+
/**
|
| 23026 |
+
* An object containing properties and methods that should be defined on
|
| 23027 |
+
* the component's constructor instead of its prototype (static methods).
|
| 23028 |
+
*
|
| 23029 |
+
* @type {object}
|
| 23030 |
+
* @optional
|
| 23031 |
+
*/
|
| 23032 |
+
statics: 'DEFINE_MANY',
|
| 23033 |
+
|
| 23034 |
+
/**
|
| 23035 |
+
* Definition of prop types for this component.
|
| 23036 |
+
*
|
| 23037 |
+
* @type {object}
|
| 23038 |
+
* @optional
|
| 23039 |
+
*/
|
| 23040 |
+
propTypes: 'DEFINE_MANY',
|
| 23041 |
+
|
| 23042 |
+
/**
|
| 23043 |
+
* Definition of context types for this component.
|
| 23044 |
+
*
|
| 23045 |
+
* @type {object}
|
| 23046 |
+
* @optional
|
| 23047 |
+
*/
|
| 23048 |
+
contextTypes: 'DEFINE_MANY',
|
| 23049 |
+
|
| 23050 |
+
/**
|
| 23051 |
+
* Definition of context types this component sets for its children.
|
| 23052 |
+
*
|
| 23053 |
+
* @type {object}
|
| 23054 |
+
* @optional
|
| 23055 |
+
*/
|
| 23056 |
+
childContextTypes: 'DEFINE_MANY',
|
| 23057 |
+
|
| 23058 |
+
// ==== Definition methods ====
|
| 23059 |
+
|
| 23060 |
+
/**
|
| 23061 |
+
* Invoked when the component is mounted. Values in the mapping will be set on
|
| 23062 |
+
* `this.props` if that prop is not specified (i.e. using an `in` check).
|
| 23063 |
+
*
|
| 23064 |
+
* This method is invoked before `getInitialState` and therefore cannot rely
|
| 23065 |
+
* on `this.state` or use `this.setState`.
|
| 23066 |
+
*
|
| 23067 |
+
* @return {object}
|
| 23068 |
+
* @optional
|
| 23069 |
+
*/
|
| 23070 |
+
getDefaultProps: 'DEFINE_MANY_MERGED',
|
| 23071 |
+
|
| 23072 |
+
/**
|
| 23073 |
+
* Invoked once before the component is mounted. The return value will be used
|
| 23074 |
+
* as the initial value of `this.state`.
|
| 23075 |
+
*
|
| 23076 |
+
* getInitialState: function() {
|
| 23077 |
+
* return {
|
| 23078 |
+
* isOn: false,
|
| 23079 |
+
* fooBaz: new BazFoo()
|
| 23080 |
+
* }
|
| 23081 |
+
* }
|
| 23082 |
+
*
|
| 23083 |
+
* @return {object}
|
| 23084 |
+
* @optional
|
| 23085 |
+
*/
|
| 23086 |
+
getInitialState: 'DEFINE_MANY_MERGED',
|
| 23087 |
+
|
| 23088 |
+
/**
|
| 23089 |
+
* @return {object}
|
| 23090 |
+
* @optional
|
| 23091 |
+
*/
|
| 23092 |
+
getChildContext: 'DEFINE_MANY_MERGED',
|
| 23093 |
+
|
| 23094 |
+
/**
|
| 23095 |
+
* Uses props from `this.props` and state from `this.state` to render the
|
| 23096 |
+
* structure of the component.
|
| 23097 |
+
*
|
| 23098 |
+
* No guarantees are made about when or how often this method is invoked, so
|
| 23099 |
+
* it must not have side effects.
|
| 23100 |
+
*
|
| 23101 |
+
* render: function() {
|
| 23102 |
+
* var name = this.props.name;
|
| 23103 |
+
* return <div>Hello, {name}!</div>;
|
| 23104 |
+
* }
|
| 23105 |
+
*
|
| 23106 |
+
* @return {ReactComponent}
|
| 23107 |
+
* @nosideeffects
|
| 23108 |
+
* @required
|
| 23109 |
+
*/
|
| 23110 |
+
render: 'DEFINE_ONCE',
|
| 23111 |
+
|
| 23112 |
+
// ==== Delegate methods ====
|
| 23113 |
+
|
| 23114 |
+
/**
|
| 23115 |
+
* Invoked when the component is initially created and about to be mounted.
|
| 23116 |
+
* This may have side effects, but any external subscriptions or data created
|
| 23117 |
+
* by this method must be cleaned up in `componentWillUnmount`.
|
| 23118 |
+
*
|
| 23119 |
+
* @optional
|
| 23120 |
+
*/
|
| 23121 |
+
componentWillMount: 'DEFINE_MANY',
|
| 23122 |
+
|
| 23123 |
+
/**
|
| 23124 |
+
* Invoked when the component has been mounted and has a DOM representation.
|
| 23125 |
+
* However, there is no guarantee that the DOM node is in the document.
|
| 23126 |
+
*
|
| 23127 |
+
* Use this as an opportunity to operate on the DOM when the component has
|
| 23128 |
+
* been mounted (initialized and rendered) for the first time.
|
| 23129 |
+
*
|
| 23130 |
+
* @param {DOMElement} rootNode DOM element representing the component.
|
| 23131 |
+
* @optional
|
| 23132 |
+
*/
|
| 23133 |
+
componentDidMount: 'DEFINE_MANY',
|
| 23134 |
+
|
| 23135 |
+
/**
|
| 23136 |
+
* Invoked before the component receives new props.
|
| 23137 |
+
*
|
| 23138 |
+
* Use this as an opportunity to react to a prop transition by updating the
|
| 23139 |
+
* state using `this.setState`. Current props are accessed via `this.props`.
|
| 23140 |
+
*
|
| 23141 |
+
* componentWillReceiveProps: function(nextProps, nextContext) {
|
| 23142 |
+
* this.setState({
|
| 23143 |
+
* likesIncreasing: nextProps.likeCount > this.props.likeCount
|
| 23144 |
+
* });
|
| 23145 |
+
* }
|
| 23146 |
+
*
|
| 23147 |
+
* NOTE: There is no equivalent `componentWillReceiveState`. An incoming prop
|
| 23148 |
+
* transition may cause a state change, but the opposite is not true. If you
|
| 23149 |
+
* need it, you are probably looking for `componentWillUpdate`.
|
| 23150 |
+
*
|
| 23151 |
+
* @param {object} nextProps
|
| 23152 |
+
* @optional
|
| 23153 |
+
*/
|
| 23154 |
+
componentWillReceiveProps: 'DEFINE_MANY',
|
| 23155 |
+
|
| 23156 |
+
/**
|
| 23157 |
+
* Invoked while deciding if the component should be updated as a result of
|
| 23158 |
+
* receiving new props, state and/or context.
|
| 23159 |
+
*
|
| 23160 |
+
* Use this as an opportunity to `return false` when you're certain that the
|
| 23161 |
+
* transition to the new props/state/context will not require a component
|
| 23162 |
+
* update.
|
| 23163 |
+
*
|
| 23164 |
+
* shouldComponentUpdate: function(nextProps, nextState, nextContext) {
|
| 23165 |
+
* return !equal(nextProps, this.props) ||
|
| 23166 |
+
* !equal(nextState, this.state) ||
|
| 23167 |
+
* !equal(nextContext, this.context);
|
| 23168 |
+
* }
|
| 23169 |
+
*
|
| 23170 |
+
* @param {object} nextProps
|
| 23171 |
+
* @param {?object} nextState
|
| 23172 |
+
* @param {?object} nextContext
|
| 23173 |
+
* @return {boolean} True if the component should update.
|
| 23174 |
+
* @optional
|
| 23175 |
+
*/
|
| 23176 |
+
shouldComponentUpdate: 'DEFINE_ONCE',
|
| 23177 |
+
|
| 23178 |
+
/**
|
| 23179 |
+
* Invoked when the component is about to update due to a transition from
|
| 23180 |
+
* `this.props`, `this.state` and `this.context` to `nextProps`, `nextState`
|
| 23181 |
+
* and `nextContext`.
|
| 23182 |
+
*
|
| 23183 |
+
* Use this as an opportunity to perform preparation before an update occurs.
|
| 23184 |
+
*
|
| 23185 |
+
* NOTE: You **cannot** use `this.setState()` in this method.
|
| 23186 |
+
*
|
| 23187 |
+
* @param {object} nextProps
|
| 23188 |
+
* @param {?object} nextState
|
| 23189 |
+
* @param {?object} nextContext
|
| 23190 |
+
* @param {ReactReconcileTransaction} transaction
|
| 23191 |
+
* @optional
|
| 23192 |
+
*/
|
| 23193 |
+
componentWillUpdate: 'DEFINE_MANY',
|
| 23194 |
+
|
| 23195 |
+
/**
|
| 23196 |
+
* Invoked when the component's DOM representation has been updated.
|
| 23197 |
+
*
|
| 23198 |
+
* Use this as an opportunity to operate on the DOM when the component has
|
| 23199 |
+
* been updated.
|
| 23200 |
+
*
|
| 23201 |
+
* @param {object} prevProps
|
| 23202 |
+
* @param {?object} prevState
|
| 23203 |
+
* @param {?object} prevContext
|
| 23204 |
+
* @param {DOMElement} rootNode DOM element representing the component.
|
| 23205 |
+
* @optional
|
| 23206 |
+
*/
|
| 23207 |
+
componentDidUpdate: 'DEFINE_MANY',
|
| 23208 |
+
|
| 23209 |
+
/**
|
| 23210 |
+
* Invoked when the component is about to be removed from its parent and have
|
| 23211 |
+
* its DOM representation destroyed.
|
| 23212 |
+
*
|
| 23213 |
+
* Use this as an opportunity to deallocate any external resources.
|
| 23214 |
+
*
|
| 23215 |
+
* NOTE: There is no `componentDidUnmount` since your component will have been
|
| 23216 |
+
* destroyed by that point.
|
| 23217 |
+
*
|
| 23218 |
+
* @optional
|
| 23219 |
+
*/
|
| 23220 |
+
componentWillUnmount: 'DEFINE_MANY',
|
| 23221 |
+
|
| 23222 |
+
// ==== Advanced methods ====
|
| 23223 |
+
|
| 23224 |
+
/**
|
| 23225 |
+
* Updates the component's currently mounted DOM representation.
|
| 23226 |
+
*
|
| 23227 |
+
* By default, this implements React's rendering and reconciliation algorithm.
|
| 23228 |
+
* Sophisticated clients may wish to override this.
|
| 23229 |
+
*
|
| 23230 |
+
* @param {ReactReconcileTransaction} transaction
|
| 23231 |
+
* @internal
|
| 23232 |
+
* @overridable
|
| 23233 |
+
*/
|
| 23234 |
+
updateComponent: 'OVERRIDE_BASE'
|
| 23235 |
+
|
| 23236 |
+
};
|
| 23237 |
+
|
| 23238 |
+
/**
|
| 23239 |
+
* Mapping from class specification keys to special processing functions.
|
| 23240 |
+
*
|
| 23241 |
+
* Although these are declared like instance properties in the specification
|
| 23242 |
+
* when defining classes using `React.createClass`, they are actually static
|
| 23243 |
+
* and are accessible on the constructor instead of the prototype. Despite
|
| 23244 |
+
* being static, they must be defined outside of the "statics" key under
|
| 23245 |
+
* which all other static methods are defined.
|
| 23246 |
+
*/
|
| 23247 |
+
var RESERVED_SPEC_KEYS = {
|
| 23248 |
+
displayName: function (Constructor, displayName) {
|
| 23249 |
+
Constructor.displayName = displayName;
|
| 23250 |
+
},
|
| 23251 |
+
mixins: function (Constructor, mixins) {
|
| 23252 |
+
if (mixins) {
|
| 23253 |
+
for (var i = 0; i < mixins.length; i++) {
|
| 23254 |
+
mixSpecIntoComponent(Constructor, mixins[i]);
|
| 23255 |
+
}
|
| 23256 |
+
}
|
| 23257 |
+
},
|
| 23258 |
+
childContextTypes: function (Constructor, childContextTypes) {
|
| 23259 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23260 |
+
validateTypeDef(Constructor, childContextTypes, 'childContext');
|
| 23261 |
+
}
|
| 23262 |
+
Constructor.childContextTypes = _assign({}, Constructor.childContextTypes, childContextTypes);
|
| 23263 |
+
},
|
| 23264 |
+
contextTypes: function (Constructor, contextTypes) {
|
| 23265 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23266 |
+
validateTypeDef(Constructor, contextTypes, 'context');
|
| 23267 |
+
}
|
| 23268 |
+
Constructor.contextTypes = _assign({}, Constructor.contextTypes, contextTypes);
|
| 23269 |
+
},
|
| 23270 |
+
/**
|
| 23271 |
+
* Special case getDefaultProps which should move into statics but requires
|
| 23272 |
+
* automatic merging.
|
| 23273 |
+
*/
|
| 23274 |
+
getDefaultProps: function (Constructor, getDefaultProps) {
|
| 23275 |
+
if (Constructor.getDefaultProps) {
|
| 23276 |
+
Constructor.getDefaultProps = createMergedResultFunction(Constructor.getDefaultProps, getDefaultProps);
|
| 23277 |
+
} else {
|
| 23278 |
+
Constructor.getDefaultProps = getDefaultProps;
|
| 23279 |
+
}
|
| 23280 |
+
},
|
| 23281 |
+
propTypes: function (Constructor, propTypes) {
|
| 23282 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23283 |
+
validateTypeDef(Constructor, propTypes, 'prop');
|
| 23284 |
+
}
|
| 23285 |
+
Constructor.propTypes = _assign({}, Constructor.propTypes, propTypes);
|
| 23286 |
+
},
|
| 23287 |
+
statics: function (Constructor, statics) {
|
| 23288 |
+
mixStaticSpecIntoComponent(Constructor, statics);
|
| 23289 |
+
},
|
| 23290 |
+
autobind: function () {} };
|
| 23291 |
+
|
| 23292 |
+
function validateTypeDef(Constructor, typeDef, location) {
|
| 23293 |
+
for (var propName in typeDef) {
|
| 23294 |
+
if (typeDef.hasOwnProperty(propName)) {
|
| 23295 |
+
// use a warning instead of an _invariant so components
|
| 23296 |
+
// don't show up in prod but only in __DEV__
|
| 23297 |
+
process.env.NODE_ENV !== 'production' ? warning(typeof typeDef[propName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'React.PropTypes.', Constructor.displayName || 'ReactClass', ReactPropTypeLocationNames[location], propName) : void 0;
|
| 23298 |
+
}
|
| 23299 |
+
}
|
| 23300 |
+
}
|
| 23301 |
+
|
| 23302 |
+
function validateMethodOverride(isAlreadyDefined, name) {
|
| 23303 |
+
var specPolicy = ReactClassInterface.hasOwnProperty(name) ? ReactClassInterface[name] : null;
|
| 23304 |
+
|
| 23305 |
+
// Disallow overriding of base class methods unless explicitly allowed.
|
| 23306 |
+
if (ReactClassMixin.hasOwnProperty(name)) {
|
| 23307 |
+
_invariant(specPolicy === 'OVERRIDE_BASE', 'ReactClassInterface: You are attempting to override ' + '`%s` from your class specification. Ensure that your method names ' + 'do not overlap with React methods.', name);
|
| 23308 |
+
}
|
| 23309 |
+
|
| 23310 |
+
// Disallow defining methods more than once unless explicitly allowed.
|
| 23311 |
+
if (isAlreadyDefined) {
|
| 23312 |
+
_invariant(specPolicy === 'DEFINE_MANY' || specPolicy === 'DEFINE_MANY_MERGED', 'ReactClassInterface: You are attempting to define ' + '`%s` on your component more than once. This conflict may be due ' + 'to a mixin.', name);
|
| 23313 |
+
}
|
| 23314 |
+
}
|
| 23315 |
+
|
| 23316 |
+
/**
|
| 23317 |
+
* Mixin helper which handles policy validation and reserved
|
| 23318 |
+
* specification keys when building React classes.
|
| 23319 |
+
*/
|
| 23320 |
+
function mixSpecIntoComponent(Constructor, spec) {
|
| 23321 |
+
if (!spec) {
|
| 23322 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23323 |
+
var typeofSpec = typeof spec;
|
| 23324 |
+
var isMixinValid = typeofSpec === 'object' && spec !== null;
|
| 23325 |
+
|
| 23326 |
+
process.env.NODE_ENV !== 'production' ? warning(isMixinValid, '%s: You\'re attempting to include a mixin that is either null ' + 'or not an object. Check the mixins included by the component, ' + 'as well as any mixins they include themselves. ' + 'Expected object but got %s.', Constructor.displayName || 'ReactClass', spec === null ? null : typeofSpec) : void 0;
|
| 23327 |
+
}
|
| 23328 |
+
|
| 23329 |
+
return;
|
| 23330 |
+
}
|
| 23331 |
+
|
| 23332 |
+
_invariant(typeof spec !== 'function', 'ReactClass: You\'re attempting to ' + 'use a component class or function as a mixin. Instead, just use a ' + 'regular object.');
|
| 23333 |
+
_invariant(!isValidElement(spec), 'ReactClass: You\'re attempting to ' + 'use a component as a mixin. Instead, just use a regular object.');
|
| 23334 |
+
|
| 23335 |
+
var proto = Constructor.prototype;
|
| 23336 |
+
var autoBindPairs = proto.__reactAutoBindPairs;
|
| 23337 |
+
|
| 23338 |
+
// By handling mixins before any other properties, we ensure the same
|
| 23339 |
+
// chaining order is applied to methods with DEFINE_MANY policy, whether
|
| 23340 |
+
// mixins are listed before or after these methods in the spec.
|
| 23341 |
+
if (spec.hasOwnProperty(MIXINS_KEY)) {
|
| 23342 |
+
RESERVED_SPEC_KEYS.mixins(Constructor, spec.mixins);
|
| 23343 |
+
}
|
| 23344 |
+
|
| 23345 |
+
for (var name in spec) {
|
| 23346 |
+
if (!spec.hasOwnProperty(name)) {
|
| 23347 |
+
continue;
|
| 23348 |
+
}
|
| 23349 |
+
|
| 23350 |
+
if (name === MIXINS_KEY) {
|
| 23351 |
+
// We have already handled mixins in a special case above.
|
| 23352 |
+
continue;
|
| 23353 |
+
}
|
| 23354 |
+
|
| 23355 |
+
var property = spec[name];
|
| 23356 |
+
var isAlreadyDefined = proto.hasOwnProperty(name);
|
| 23357 |
+
validateMethodOverride(isAlreadyDefined, name);
|
| 23358 |
+
|
| 23359 |
+
if (RESERVED_SPEC_KEYS.hasOwnProperty(name)) {
|
| 23360 |
+
RESERVED_SPEC_KEYS[name](Constructor, property);
|
| 23361 |
+
} else {
|
| 23362 |
+
// Setup methods on prototype:
|
| 23363 |
+
// The following member methods should not be automatically bound:
|
| 23364 |
+
// 1. Expected ReactClass methods (in the "interface").
|
| 23365 |
+
// 2. Overridden methods (that were mixed in).
|
| 23366 |
+
var isReactClassMethod = ReactClassInterface.hasOwnProperty(name);
|
| 23367 |
+
var isFunction = typeof property === 'function';
|
| 23368 |
+
var shouldAutoBind = isFunction && !isReactClassMethod && !isAlreadyDefined && spec.autobind !== false;
|
| 23369 |
+
|
| 23370 |
+
if (shouldAutoBind) {
|
| 23371 |
+
autoBindPairs.push(name, property);
|
| 23372 |
+
proto[name] = property;
|
| 23373 |
+
} else {
|
| 23374 |
+
if (isAlreadyDefined) {
|
| 23375 |
+
var specPolicy = ReactClassInterface[name];
|
| 23376 |
+
|
| 23377 |
+
// These cases should already be caught by validateMethodOverride.
|
| 23378 |
+
_invariant(isReactClassMethod && (specPolicy === 'DEFINE_MANY_MERGED' || specPolicy === 'DEFINE_MANY'), 'ReactClass: Unexpected spec policy %s for key %s ' + 'when mixing in component specs.', specPolicy, name);
|
| 23379 |
+
|
| 23380 |
+
// For methods which are defined more than once, call the existing
|
| 23381 |
+
// methods before calling the new property, merging if appropriate.
|
| 23382 |
+
if (specPolicy === 'DEFINE_MANY_MERGED') {
|
| 23383 |
+
proto[name] = createMergedResultFunction(proto[name], property);
|
| 23384 |
+
} else if (specPolicy === 'DEFINE_MANY') {
|
| 23385 |
+
proto[name] = createChainedFunction(proto[name], property);
|
| 23386 |
+
}
|
| 23387 |
+
} else {
|
| 23388 |
+
proto[name] = property;
|
| 23389 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23390 |
+
// Add verbose displayName to the function, which helps when looking
|
| 23391 |
+
// at profiling tools.
|
| 23392 |
+
if (typeof property === 'function' && spec.displayName) {
|
| 23393 |
+
proto[name].displayName = spec.displayName + '_' + name;
|
| 23394 |
+
}
|
| 23395 |
+
}
|
| 23396 |
+
}
|
| 23397 |
+
}
|
| 23398 |
+
}
|
| 23399 |
+
}
|
| 23400 |
+
}
|
| 23401 |
+
|
| 23402 |
+
function mixStaticSpecIntoComponent(Constructor, statics) {
|
| 23403 |
+
if (!statics) {
|
| 23404 |
+
return;
|
| 23405 |
+
}
|
| 23406 |
+
for (var name in statics) {
|
| 23407 |
+
var property = statics[name];
|
| 23408 |
+
if (!statics.hasOwnProperty(name)) {
|
| 23409 |
+
continue;
|
| 23410 |
+
}
|
| 23411 |
+
|
| 23412 |
+
var isReserved = name in RESERVED_SPEC_KEYS;
|
| 23413 |
+
_invariant(!isReserved, 'ReactClass: You are attempting to define a reserved ' + 'property, `%s`, that shouldn\'t be on the "statics" key. Define it ' + 'as an instance property instead; it will still be accessible on the ' + 'constructor.', name);
|
| 23414 |
+
|
| 23415 |
+
var isInherited = name in Constructor;
|
| 23416 |
+
_invariant(!isInherited, 'ReactClass: You are attempting to define ' + '`%s` on your component more than once. This conflict may be ' + 'due to a mixin.', name);
|
| 23417 |
+
Constructor[name] = property;
|
| 23418 |
+
}
|
| 23419 |
+
}
|
| 23420 |
+
|
| 23421 |
+
/**
|
| 23422 |
+
* Merge two objects, but throw if both contain the same key.
|
| 23423 |
+
*
|
| 23424 |
+
* @param {object} one The first object, which is mutated.
|
| 23425 |
+
* @param {object} two The second object
|
| 23426 |
+
* @return {object} one after it has been mutated to contain everything in two.
|
| 23427 |
+
*/
|
| 23428 |
+
function mergeIntoWithNoDuplicateKeys(one, two) {
|
| 23429 |
+
_invariant(one && two && typeof one === 'object' && typeof two === 'object', 'mergeIntoWithNoDuplicateKeys(): Cannot merge non-objects.');
|
| 23430 |
+
|
| 23431 |
+
for (var key in two) {
|
| 23432 |
+
if (two.hasOwnProperty(key)) {
|
| 23433 |
+
_invariant(one[key] === undefined, 'mergeIntoWithNoDuplicateKeys(): ' + 'Tried to merge two objects with the same key: `%s`. This conflict ' + 'may be due to a mixin; in particular, this may be caused by two ' + 'getInitialState() or getDefaultProps() methods returning objects ' + 'with clashing keys.', key);
|
| 23434 |
+
one[key] = two[key];
|
| 23435 |
+
}
|
| 23436 |
+
}
|
| 23437 |
+
return one;
|
| 23438 |
+
}
|
| 23439 |
+
|
| 23440 |
+
/**
|
| 23441 |
+
* Creates a function that invokes two functions and merges their return values.
|
| 23442 |
+
*
|
| 23443 |
+
* @param {function} one Function to invoke first.
|
| 23444 |
+
* @param {function} two Function to invoke second.
|
| 23445 |
+
* @return {function} Function that invokes the two argument functions.
|
| 23446 |
+
* @private
|
| 23447 |
+
*/
|
| 23448 |
+
function createMergedResultFunction(one, two) {
|
| 23449 |
+
return function mergedResult() {
|
| 23450 |
+
var a = one.apply(this, arguments);
|
| 23451 |
+
var b = two.apply(this, arguments);
|
| 23452 |
+
if (a == null) {
|
| 23453 |
+
return b;
|
| 23454 |
+
} else if (b == null) {
|
| 23455 |
+
return a;
|
| 23456 |
+
}
|
| 23457 |
+
var c = {};
|
| 23458 |
+
mergeIntoWithNoDuplicateKeys(c, a);
|
| 23459 |
+
mergeIntoWithNoDuplicateKeys(c, b);
|
| 23460 |
+
return c;
|
| 23461 |
+
};
|
| 23462 |
+
}
|
| 23463 |
+
|
| 23464 |
+
/**
|
| 23465 |
+
* Creates a function that invokes two functions and ignores their return vales.
|
| 23466 |
+
*
|
| 23467 |
+
* @param {function} one Function to invoke first.
|
| 23468 |
+
* @param {function} two Function to invoke second.
|
| 23469 |
+
* @return {function} Function that invokes the two argument functions.
|
| 23470 |
+
* @private
|
| 23471 |
+
*/
|
| 23472 |
+
function createChainedFunction(one, two) {
|
| 23473 |
+
return function chainedFunction() {
|
| 23474 |
+
one.apply(this, arguments);
|
| 23475 |
+
two.apply(this, arguments);
|
| 23476 |
+
};
|
| 23477 |
+
}
|
| 23478 |
+
|
| 23479 |
+
/**
|
| 23480 |
+
* Binds a method to the component.
|
| 23481 |
+
*
|
| 23482 |
+
* @param {object} component Component whose method is going to be bound.
|
| 23483 |
+
* @param {function} method Method to be bound.
|
| 23484 |
+
* @return {function} The bound method.
|
| 23485 |
+
*/
|
| 23486 |
+
function bindAutoBindMethod(component, method) {
|
| 23487 |
+
var boundMethod = method.bind(component);
|
| 23488 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23489 |
+
boundMethod.__reactBoundContext = component;
|
| 23490 |
+
boundMethod.__reactBoundMethod = method;
|
| 23491 |
+
boundMethod.__reactBoundArguments = null;
|
| 23492 |
+
var componentName = component.constructor.displayName;
|
| 23493 |
+
var _bind = boundMethod.bind;
|
| 23494 |
+
boundMethod.bind = function (newThis) {
|
| 23495 |
+
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
| 23496 |
+
args[_key - 1] = arguments[_key];
|
| 23497 |
+
}
|
| 23498 |
+
|
| 23499 |
+
// User is trying to bind() an autobound method; we effectively will
|
| 23500 |
+
// ignore the value of "this" that the user is trying to use, so
|
| 23501 |
+
// let's warn.
|
| 23502 |
+
if (newThis !== component && newThis !== null) {
|
| 23503 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'bind(): React component methods may only be bound to the ' + 'component instance. See %s', componentName) : void 0;
|
| 23504 |
+
} else if (!args.length) {
|
| 23505 |
+
process.env.NODE_ENV !== 'production' ? warning(false, 'bind(): You are binding a component method to the component. ' + 'React does this for you automatically in a high-performance ' + 'way, so you can safely remove this call. See %s', componentName) : void 0;
|
| 23506 |
+
return boundMethod;
|
| 23507 |
+
}
|
| 23508 |
+
var reboundMethod = _bind.apply(boundMethod, arguments);
|
| 23509 |
+
reboundMethod.__reactBoundContext = component;
|
| 23510 |
+
reboundMethod.__reactBoundMethod = method;
|
| 23511 |
+
reboundMethod.__reactBoundArguments = args;
|
| 23512 |
+
return reboundMethod;
|
| 23513 |
+
};
|
| 23514 |
+
}
|
| 23515 |
+
return boundMethod;
|
| 23516 |
+
}
|
| 23517 |
+
|
| 23518 |
+
/**
|
| 23519 |
+
* Binds all auto-bound methods in a component.
|
| 23520 |
+
*
|
| 23521 |
+
* @param {object} component Component whose method is going to be bound.
|
| 23522 |
+
*/
|
| 23523 |
+
function bindAutoBindMethods(component) {
|
| 23524 |
+
var pairs = component.__reactAutoBindPairs;
|
| 23525 |
+
for (var i = 0; i < pairs.length; i += 2) {
|
| 23526 |
+
var autoBindKey = pairs[i];
|
| 23527 |
+
var method = pairs[i + 1];
|
| 23528 |
+
component[autoBindKey] = bindAutoBindMethod(component, method);
|
| 23529 |
+
}
|
| 23530 |
+
}
|
| 23531 |
+
|
| 23532 |
+
var IsMountedMixin = {
|
| 23533 |
+
componentDidMount: function () {
|
| 23534 |
+
this.__isMounted = true;
|
| 23535 |
+
},
|
| 23536 |
+
componentWillUnmount: function () {
|
| 23537 |
+
this.__isMounted = false;
|
| 23538 |
+
}
|
| 23539 |
+
};
|
| 23540 |
+
|
| 23541 |
+
/**
|
| 23542 |
+
* Add more to the ReactClass base class. These are all legacy features and
|
| 23543 |
+
* therefore not already part of the modern ReactComponent.
|
| 23544 |
+
*/
|
| 23545 |
+
var ReactClassMixin = {
|
| 23546 |
+
|
| 23547 |
+
/**
|
| 23548 |
+
* TODO: This will be deprecated because state should always keep a consistent
|
| 23549 |
+
* type signature and the only use case for this, is to avoid that.
|
| 23550 |
+
*/
|
| 23551 |
+
replaceState: function (newState, callback) {
|
| 23552 |
+
this.updater.enqueueReplaceState(this, newState, callback);
|
| 23553 |
+
},
|
| 23554 |
+
|
| 23555 |
+
/**
|
| 23556 |
+
* Checks whether or not this composite component is mounted.
|
| 23557 |
+
* @return {boolean} True if mounted, false otherwise.
|
| 23558 |
+
* @protected
|
| 23559 |
+
* @final
|
| 23560 |
+
*/
|
| 23561 |
+
isMounted: function () {
|
| 23562 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23563 |
+
process.env.NODE_ENV !== 'production' ? warning(this.__didWarnIsMounted, '%s: isMounted is deprecated. Instead, make sure to clean up ' + 'subscriptions and pending requests in componentWillUnmount to ' + 'prevent memory leaks.', this.constructor && this.constructor.displayName || this.name || 'Component') : void 0;
|
| 23564 |
+
this.__didWarnIsMounted = true;
|
| 23565 |
+
}
|
| 23566 |
+
return !!this.__isMounted;
|
| 23567 |
+
}
|
| 23568 |
+
};
|
| 23569 |
+
|
| 23570 |
+
var ReactClassComponent = function () {};
|
| 23571 |
+
_assign(ReactClassComponent.prototype, ReactComponent.prototype, ReactClassMixin);
|
| 23572 |
+
|
| 23573 |
+
/**
|
| 23574 |
+
* Creates a composite component class given a class specification.
|
| 23575 |
+
* See https://facebook.github.io/react/docs/top-level-api.html#react.createclass
|
| 23576 |
+
*
|
| 23577 |
+
* @param {object} spec Class specification (which must define `render`).
|
| 23578 |
+
* @return {function} Component constructor function.
|
| 23579 |
+
* @public
|
| 23580 |
+
*/
|
| 23581 |
+
function createClass(spec) {
|
| 23582 |
+
// To keep our warnings more understandable, we'll use a little hack here to
|
| 23583 |
+
// ensure that Constructor.name !== 'Constructor'. This makes sure we don't
|
| 23584 |
+
// unnecessarily identify a class without displayName as 'Constructor'.
|
| 23585 |
+
var Constructor = identity(function (props, context, updater) {
|
| 23586 |
+
// This constructor gets overridden by mocks. The argument is used
|
| 23587 |
+
// by mocks to assert on what gets mounted.
|
| 23588 |
+
|
| 23589 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23590 |
+
process.env.NODE_ENV !== 'production' ? warning(this instanceof Constructor, 'Something is calling a React component directly. Use a factory or ' + 'JSX instead. See: https://fb.me/react-legacyfactory') : void 0;
|
| 23591 |
+
}
|
| 23592 |
+
|
| 23593 |
+
// Wire up auto-binding
|
| 23594 |
+
if (this.__reactAutoBindPairs.length) {
|
| 23595 |
+
bindAutoBindMethods(this);
|
| 23596 |
+
}
|
| 23597 |
|
| 23598 |
+
this.props = props;
|
| 23599 |
+
this.context = context;
|
| 23600 |
+
this.refs = emptyObject;
|
| 23601 |
+
this.updater = updater || ReactNoopUpdateQueue;
|
| 23602 |
|
| 23603 |
+
this.state = null;
|
| 23604 |
|
| 23605 |
+
// ReactClasses doesn't have constructors. Instead, they use the
|
| 23606 |
+
// getInitialState and componentWillMount methods for initialization.
|
| 23607 |
|
| 23608 |
+
var initialState = this.getInitialState ? this.getInitialState() : null;
|
| 23609 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23610 |
+
// We allow auto-mocks to proceed as if they're returning null.
|
| 23611 |
+
if (initialState === undefined && this.getInitialState._isMockFunction) {
|
| 23612 |
+
// This is probably bad practice. Consider warning here and
|
| 23613 |
+
// deprecating this convenience.
|
| 23614 |
+
initialState = null;
|
| 23615 |
+
}
|
| 23616 |
+
}
|
| 23617 |
+
_invariant(typeof initialState === 'object' && !Array.isArray(initialState), '%s.getInitialState(): must return an object or null', Constructor.displayName || 'ReactCompositeComponent');
|
| 23618 |
|
| 23619 |
+
this.state = initialState;
|
| 23620 |
+
});
|
| 23621 |
+
Constructor.prototype = new ReactClassComponent();
|
| 23622 |
+
Constructor.prototype.constructor = Constructor;
|
| 23623 |
+
Constructor.prototype.__reactAutoBindPairs = [];
|
| 23624 |
|
| 23625 |
+
injectedMixins.forEach(mixSpecIntoComponent.bind(null, Constructor));
|
|
|
|
|
|
|
| 23626 |
|
| 23627 |
+
mixSpecIntoComponent(Constructor, IsMountedMixin);
|
| 23628 |
+
mixSpecIntoComponent(Constructor, spec);
|
|
|
|
|
|
|
|
|
|
| 23629 |
|
| 23630 |
+
// Initialize the defaultProps property after all mixins have been merged.
|
| 23631 |
+
if (Constructor.getDefaultProps) {
|
| 23632 |
+
Constructor.defaultProps = Constructor.getDefaultProps();
|
| 23633 |
+
}
|
| 23634 |
|
| 23635 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23636 |
+
// This is a tag to indicate that the use of these method names is ok,
|
| 23637 |
+
// since it's used with createClass. If it's not, then it's likely a
|
| 23638 |
+
// mistake so we'll warn you to use the static property, property
|
| 23639 |
+
// initializer or constructor respectively.
|
| 23640 |
+
if (Constructor.getDefaultProps) {
|
| 23641 |
+
Constructor.getDefaultProps.isReactClassApproved = {};
|
| 23642 |
+
}
|
| 23643 |
+
if (Constructor.prototype.getInitialState) {
|
| 23644 |
+
Constructor.prototype.getInitialState.isReactClassApproved = {};
|
| 23645 |
+
}
|
| 23646 |
+
}
|
| 23647 |
|
| 23648 |
+
_invariant(Constructor.prototype.render, 'createClass(...): Class specification must implement a `render` method.');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23649 |
|
| 23650 |
+
if (process.env.NODE_ENV !== 'production') {
|
| 23651 |
+
process.env.NODE_ENV !== 'production' ? warning(!Constructor.prototype.componentShouldUpdate, '%s has a method called ' + 'componentShouldUpdate(). Did you mean shouldComponentUpdate()? ' + 'The name is phrased as a question because the function is ' + 'expected to return a value.', spec.displayName || 'A component') : void 0;
|
| 23652 |
+
process.env.NODE_ENV !== 'production' ? warning(!Constructor.prototype.componentWillRecieveProps, '%s has a method called ' + 'componentWillRecieveProps(). Did you mean componentWillReceiveProps()?', spec.displayName || 'A component') : void 0;
|
| 23653 |
+
}
|
| 23654 |
|
| 23655 |
+
// Reduce time spent doing lookups by setting these on the prototype.
|
| 23656 |
+
for (var methodName in ReactClassInterface) {
|
| 23657 |
+
if (!Constructor.prototype[methodName]) {
|
| 23658 |
+
Constructor.prototype[methodName] = null;
|
| 23659 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23660 |
}
|
|
|
|
|
|
|
|
|
|
| 23661 |
|
| 23662 |
+
return Constructor;
|
| 23663 |
+
}
|
|
|
|
| 23664 |
|
| 23665 |
+
return createClass;
|
| 23666 |
+
}
|
| 23667 |
|
| 23668 |
+
module.exports = factory;
|
|
|
|
|
|
|
|
|
|
| 23669 |
|
| 23670 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
|
|
|
|
|
|
| 23671 |
|
| 23672 |
+
/***/ },
|
| 23673 |
+
/* 193 */
|
| 23674 |
+
/***/ function(module, exports) {
|
|
|
|
| 23675 |
|
| 23676 |
+
/*
|
| 23677 |
+
object-assign
|
| 23678 |
+
(c) Sindre Sorhus
|
| 23679 |
+
@license MIT
|
| 23680 |
+
*/
|
| 23681 |
|
| 23682 |
+
'use strict';
|
| 23683 |
+
/* eslint-disable no-unused-vars */
|
| 23684 |
+
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
| 23685 |
+
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
| 23686 |
+
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
| 23687 |
|
| 23688 |
+
function toObject(val) {
|
| 23689 |
+
if (val === null || val === undefined) {
|
| 23690 |
+
throw new TypeError('Object.assign cannot be called with null or undefined');
|
| 23691 |
+
}
|
| 23692 |
|
| 23693 |
+
return Object(val);
|
| 23694 |
+
}
|
| 23695 |
|
| 23696 |
+
function shouldUseNative() {
|
| 23697 |
+
try {
|
| 23698 |
+
if (!Object.assign) {
|
| 23699 |
+
return false;
|
| 23700 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 23701 |
|
| 23702 |
+
// Detect buggy property enumeration order in older V8 versions.
|
| 23703 |
|
| 23704 |
+
// https://bugs.chromium.org/p/v8/issues/detail?id=4118
|
| 23705 |
+
var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
|
| 23706 |
+
test1[5] = 'de';
|
| 23707 |
+
if (Object.getOwnPropertyNames(test1)[0] === '5') {
|
| 23708 |
+
return false;
|
| 23709 |
+
}
|
| 23710 |
|
| 23711 |
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
| 23712 |
+
var test2 = {};
|
| 23713 |
+
for (var i = 0; i < 10; i++) {
|
| 23714 |
+
test2['_' + String.fromCharCode(i)] = i;
|
| 23715 |
+
}
|
| 23716 |
+
var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
|
| 23717 |
+
return test2[n];
|
| 23718 |
+
});
|
| 23719 |
+
if (order2.join('') !== '0123456789') {
|
| 23720 |
+
return false;
|
| 23721 |
+
}
|
| 23722 |
|
| 23723 |
+
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
| 23724 |
+
var test3 = {};
|
| 23725 |
+
'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
|
| 23726 |
+
test3[letter] = letter;
|
| 23727 |
+
});
|
| 23728 |
+
if (Object.keys(Object.assign({}, test3)).join('') !==
|
| 23729 |
+
'abcdefghijklmnopqrst') {
|
| 23730 |
+
return false;
|
| 23731 |
+
}
|
| 23732 |
|
| 23733 |
+
return true;
|
| 23734 |
+
} catch (err) {
|
| 23735 |
+
// We don't expect any of the above to throw, but better to be safe.
|
| 23736 |
+
return false;
|
| 23737 |
+
}
|
| 23738 |
+
}
|
| 23739 |
|
| 23740 |
+
module.exports = shouldUseNative() ? Object.assign : function (target, source) {
|
| 23741 |
+
var from;
|
| 23742 |
+
var to = toObject(target);
|
| 23743 |
+
var symbols;
|
|
|
|
| 23744 |
|
| 23745 |
+
for (var s = 1; s < arguments.length; s++) {
|
| 23746 |
+
from = Object(arguments[s]);
|
| 23747 |
+
|
| 23748 |
+
for (var key in from) {
|
| 23749 |
+
if (hasOwnProperty.call(from, key)) {
|
| 23750 |
+
to[key] = from[key];
|
| 23751 |
+
}
|
| 23752 |
+
}
|
| 23753 |
+
|
| 23754 |
+
if (getOwnPropertySymbols) {
|
| 23755 |
+
symbols = getOwnPropertySymbols(from);
|
| 23756 |
+
for (var i = 0; i < symbols.length; i++) {
|
| 23757 |
+
if (propIsEnumerable.call(from, symbols[i])) {
|
| 23758 |
+
to[symbols[i]] = from[symbols[i]];
|
| 23759 |
+
}
|
| 23760 |
+
}
|
| 23761 |
+
}
|
| 23762 |
+
}
|
| 23763 |
+
|
| 23764 |
+
return to;
|
| 23765 |
+
};
|
| 23766 |
|
|
|
|
|
|
|
|
|
|
| 23767 |
|
| 23768 |
/***/ },
|
| 23769 |
+
/* 194 */
|
| 23770 |
/***/ function(module, exports, __webpack_require__) {
|
| 23771 |
|
| 23772 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 23777 |
|
| 23778 |
exports.default = createTransitionManager;
|
| 23779 |
|
| 23780 |
+
var _routerWarning = __webpack_require__(195);
|
| 23781 |
|
| 23782 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 23783 |
|
| 23784 |
+
var _computeChangedRoutes2 = __webpack_require__(197);
|
| 23785 |
|
| 23786 |
var _computeChangedRoutes3 = _interopRequireDefault(_computeChangedRoutes2);
|
| 23787 |
|
| 23788 |
+
var _TransitionUtils = __webpack_require__(198);
|
| 23789 |
|
| 23790 |
+
var _TransitionUtils2 = _interopRequireDefault(_TransitionUtils);
|
| 23791 |
+
|
| 23792 |
+
var _isActive2 = __webpack_require__(200);
|
| 23793 |
|
| 23794 |
var _isActive3 = _interopRequireDefault(_isActive2);
|
| 23795 |
|
| 23796 |
+
var _getComponents = __webpack_require__(201);
|
| 23797 |
|
| 23798 |
var _getComponents2 = _interopRequireDefault(_getComponents);
|
| 23799 |
|
| 23800 |
+
var _matchRoutes = __webpack_require__(203);
|
| 23801 |
|
| 23802 |
var _matchRoutes2 = _interopRequireDefault(_matchRoutes);
|
| 23803 |
|
| 23812 |
function createTransitionManager(history, routes) {
|
| 23813 |
var state = {};
|
| 23814 |
|
| 23815 |
+
var _getTransitionUtils = (0, _TransitionUtils2.default)(),
|
| 23816 |
+
runEnterHooks = _getTransitionUtils.runEnterHooks,
|
| 23817 |
+
runChangeHooks = _getTransitionUtils.runChangeHooks,
|
| 23818 |
+
runLeaveHooks = _getTransitionUtils.runLeaveHooks;
|
| 23819 |
+
|
| 23820 |
// Signature should be (location, indexOnly), but needs to support (path,
|
| 23821 |
// query, indexOnly)
|
| 23822 |
+
|
| 23823 |
+
|
| 23824 |
function isActive(location, indexOnly) {
|
| 23825 |
location = history.createLocation(location);
|
| 23826 |
|
| 23852 |
changeRoutes = _computeChangedRoutes.changeRoutes,
|
| 23853 |
enterRoutes = _computeChangedRoutes.enterRoutes;
|
| 23854 |
|
| 23855 |
+
runLeaveHooks(leaveRoutes, state);
|
| 23856 |
|
| 23857 |
// Tear down confirmation hooks for left routes
|
| 23858 |
leaveRoutes.filter(function (route) {
|
| 23860 |
}).forEach(removeListenBeforeHooksForRoute);
|
| 23861 |
|
| 23862 |
// change and enter hooks are run in series
|
| 23863 |
+
runChangeHooks(changeRoutes, state, nextState, function (error, redirectInfo) {
|
| 23864 |
if (error || redirectInfo) return handleErrorOrRedirect(error, redirectInfo);
|
| 23865 |
|
| 23866 |
+
runEnterHooks(enterRoutes, nextState, finishEnterHooks);
|
| 23867 |
});
|
| 23868 |
|
| 23869 |
function finishEnterHooks(error, redirectInfo) {
|
| 24056 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24057 |
|
| 24058 |
/***/ },
|
| 24059 |
+
/* 195 */
|
| 24060 |
/***/ function(module, exports, __webpack_require__) {
|
| 24061 |
|
| 24062 |
'use strict';
|
| 24065 |
exports.default = routerWarning;
|
| 24066 |
exports._resetWarned = _resetWarned;
|
| 24067 |
|
| 24068 |
+
var _warning = __webpack_require__(196);
|
| 24069 |
|
| 24070 |
var _warning2 = _interopRequireDefault(_warning);
|
| 24071 |
|
| 24097 |
}
|
| 24098 |
|
| 24099 |
/***/ },
|
| 24100 |
+
/* 196 */
|
| 24101 |
/***/ function(module, exports, __webpack_require__) {
|
| 24102 |
|
| 24103 |
/* WEBPACK VAR INJECTION */(function(process) {/**
|
| 24164 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24165 |
|
| 24166 |
/***/ },
|
| 24167 |
+
/* 197 */
|
| 24168 |
/***/ function(module, exports, __webpack_require__) {
|
| 24169 |
|
| 24170 |
'use strict';
|
| 24171 |
|
| 24172 |
exports.__esModule = true;
|
| 24173 |
|
| 24174 |
+
var _PatternUtils = __webpack_require__(188);
|
| 24175 |
|
| 24176 |
function routeParamsChanged(route, prevState, nextState) {
|
| 24177 |
if (!route.path) return false;
|
| 24202 |
|
| 24203 |
var leaveRoutes = void 0,
|
| 24204 |
changeRoutes = void 0,
|
| 24205 |
+
enterRoutes = void 0;
|
| 24206 |
+
if (prevRoutes) {
|
| 24207 |
+
var parentIsLeaving = false;
|
| 24208 |
+
leaveRoutes = prevRoutes.filter(function (route) {
|
| 24209 |
+
if (parentIsLeaving) {
|
| 24210 |
+
return true;
|
| 24211 |
+
} else {
|
| 24212 |
+
var isLeaving = nextRoutes.indexOf(route) === -1 || routeParamsChanged(route, prevState, nextState);
|
| 24213 |
+
if (isLeaving) parentIsLeaving = true;
|
| 24214 |
+
return isLeaving;
|
| 24215 |
+
}
|
| 24216 |
+
});
|
|
|
|
| 24217 |
|
| 24218 |
+
// onLeave hooks start at the leaf route.
|
| 24219 |
+
leaveRoutes.reverse();
|
| 24220 |
|
| 24221 |
+
enterRoutes = [];
|
| 24222 |
+
changeRoutes = [];
|
| 24223 |
|
| 24224 |
+
nextRoutes.forEach(function (route) {
|
| 24225 |
+
var isNew = prevRoutes.indexOf(route) === -1;
|
| 24226 |
+
var paramsChanged = leaveRoutes.indexOf(route) !== -1;
|
| 24227 |
|
| 24228 |
+
if (isNew || paramsChanged) enterRoutes.push(route);else changeRoutes.push(route);
|
| 24229 |
+
});
|
|
|
|
| 24230 |
} else {
|
| 24231 |
leaveRoutes = [];
|
| 24232 |
changeRoutes = [];
|
| 24244 |
module.exports = exports['default'];
|
| 24245 |
|
| 24246 |
/***/ },
|
| 24247 |
+
/* 198 */
|
| 24248 |
/***/ function(module, exports, __webpack_require__) {
|
| 24249 |
|
| 24250 |
'use strict';
|
| 24251 |
|
| 24252 |
exports.__esModule = true;
|
| 24253 |
+
exports.default = getTransitionUtils;
|
|
|
|
|
|
|
| 24254 |
|
| 24255 |
+
var _AsyncUtils = __webpack_require__(199);
|
| 24256 |
|
| 24257 |
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
| 24258 |
|
| 24282 |
};
|
| 24283 |
};
|
| 24284 |
|
| 24285 |
+
function getTransitionUtils() {
|
| 24286 |
+
var enterHooks = new PendingHooks();
|
| 24287 |
+
var changeHooks = new PendingHooks();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24288 |
|
| 24289 |
+
function createTransitionHook(hook, route, asyncArity, pendingHooks) {
|
| 24290 |
+
var isSync = hook.length < asyncArity;
|
| 24291 |
|
| 24292 |
+
var transitionHook = function transitionHook() {
|
| 24293 |
+
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
|
| 24294 |
+
args[_key] = arguments[_key];
|
| 24295 |
+
}
|
|
|
|
|
|
|
|
|
|
| 24296 |
|
| 24297 |
+
hook.apply(route, args);
|
| 24298 |
|
| 24299 |
+
if (isSync) {
|
| 24300 |
+
var callback = args[args.length - 1];
|
| 24301 |
+
// Assume hook executes synchronously and
|
| 24302 |
+
// automatically call the callback.
|
| 24303 |
+
callback();
|
| 24304 |
+
}
|
| 24305 |
+
};
|
| 24306 |
|
| 24307 |
+
pendingHooks.add(transitionHook);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24308 |
|
| 24309 |
+
return transitionHook;
|
| 24310 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24311 |
|
| 24312 |
+
function getEnterHooks(routes) {
|
| 24313 |
+
return routes.reduce(function (hooks, route) {
|
| 24314 |
+
if (route.onEnter) hooks.push(createTransitionHook(route.onEnter, route, 3, enterHooks));
|
| 24315 |
+
return hooks;
|
| 24316 |
+
}, []);
|
| 24317 |
}
|
| 24318 |
|
| 24319 |
+
function getChangeHooks(routes) {
|
| 24320 |
+
return routes.reduce(function (hooks, route) {
|
| 24321 |
+
if (route.onChange) hooks.push(createTransitionHook(route.onChange, route, 4, changeHooks));
|
| 24322 |
+
return hooks;
|
| 24323 |
+
}, []);
|
| 24324 |
}
|
| 24325 |
|
| 24326 |
+
function runTransitionHooks(length, iter, callback) {
|
| 24327 |
+
if (!length) {
|
| 24328 |
+
callback();
|
| 24329 |
+
return;
|
| 24330 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24331 |
|
| 24332 |
+
var redirectInfo = void 0;
|
| 24333 |
+
function replace(location) {
|
| 24334 |
+
redirectInfo = location;
|
| 24335 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24336 |
|
| 24337 |
+
(0, _AsyncUtils.loopAsync)(length, function (index, next, done) {
|
| 24338 |
+
iter(index, replace, function (error) {
|
| 24339 |
+
if (error || redirectInfo) {
|
| 24340 |
+
done(error, redirectInfo); // No need to continue.
|
| 24341 |
+
} else {
|
| 24342 |
+
next();
|
| 24343 |
+
}
|
| 24344 |
+
});
|
| 24345 |
+
}, callback);
|
| 24346 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24347 |
|
| 24348 |
+
/**
|
| 24349 |
+
* Runs all onEnter hooks in the given array of routes in order
|
| 24350 |
+
* with onEnter(nextState, replace, callback) and calls
|
| 24351 |
+
* callback(error, redirectInfo) when finished. The first hook
|
| 24352 |
+
* to use replace short-circuits the loop.
|
| 24353 |
+
*
|
| 24354 |
+
* If a hook needs to run asynchronously, it may use the callback
|
| 24355 |
+
* function. However, doing so will cause the transition to pause,
|
| 24356 |
+
* which could lead to a non-responsive UI if the hook is slow.
|
| 24357 |
+
*/
|
| 24358 |
+
function runEnterHooks(routes, nextState, callback) {
|
| 24359 |
+
enterHooks.clear();
|
| 24360 |
+
var hooks = getEnterHooks(routes);
|
| 24361 |
+
return runTransitionHooks(hooks.length, function (index, replace, next) {
|
| 24362 |
+
var wrappedNext = function wrappedNext() {
|
| 24363 |
+
if (enterHooks.has(hooks[index])) {
|
| 24364 |
+
next.apply(undefined, arguments);
|
| 24365 |
+
enterHooks.remove(hooks[index]);
|
| 24366 |
+
}
|
| 24367 |
+
};
|
| 24368 |
+
hooks[index](nextState, replace, wrappedNext);
|
| 24369 |
+
}, callback);
|
| 24370 |
+
}
|
| 24371 |
+
|
| 24372 |
+
/**
|
| 24373 |
+
* Runs all onChange hooks in the given array of routes in order
|
| 24374 |
+
* with onChange(prevState, nextState, replace, callback) and calls
|
| 24375 |
+
* callback(error, redirectInfo) when finished. The first hook
|
| 24376 |
+
* to use replace short-circuits the loop.
|
| 24377 |
+
*
|
| 24378 |
+
* If a hook needs to run asynchronously, it may use the callback
|
| 24379 |
+
* function. However, doing so will cause the transition to pause,
|
| 24380 |
+
* which could lead to a non-responsive UI if the hook is slow.
|
| 24381 |
+
*/
|
| 24382 |
+
function runChangeHooks(routes, state, nextState, callback) {
|
| 24383 |
+
changeHooks.clear();
|
| 24384 |
+
var hooks = getChangeHooks(routes);
|
| 24385 |
+
return runTransitionHooks(hooks.length, function (index, replace, next) {
|
| 24386 |
+
var wrappedNext = function wrappedNext() {
|
| 24387 |
+
if (changeHooks.has(hooks[index])) {
|
| 24388 |
+
next.apply(undefined, arguments);
|
| 24389 |
+
changeHooks.remove(hooks[index]);
|
| 24390 |
+
}
|
| 24391 |
+
};
|
| 24392 |
+
hooks[index](state, nextState, replace, wrappedNext);
|
| 24393 |
+
}, callback);
|
| 24394 |
+
}
|
| 24395 |
+
|
| 24396 |
+
/**
|
| 24397 |
+
* Runs all onLeave hooks in the given array of routes in order.
|
| 24398 |
+
*/
|
| 24399 |
+
function runLeaveHooks(routes, prevState) {
|
| 24400 |
+
for (var i = 0, len = routes.length; i < len; ++i) {
|
| 24401 |
+
if (routes[i].onLeave) routes[i].onLeave.call(routes[i], prevState);
|
| 24402 |
+
}
|
| 24403 |
}
|
| 24404 |
+
|
| 24405 |
+
return {
|
| 24406 |
+
runEnterHooks: runEnterHooks,
|
| 24407 |
+
runChangeHooks: runChangeHooks,
|
| 24408 |
+
runLeaveHooks: runLeaveHooks
|
| 24409 |
+
};
|
| 24410 |
}
|
| 24411 |
+
module.exports = exports['default'];
|
| 24412 |
|
| 24413 |
/***/ },
|
| 24414 |
+
/* 199 */
|
| 24415 |
/***/ function(module, exports) {
|
| 24416 |
|
| 24417 |
"use strict";
|
| 24504 |
}
|
| 24505 |
|
| 24506 |
/***/ },
|
| 24507 |
+
/* 200 */
|
| 24508 |
/***/ function(module, exports, __webpack_require__) {
|
| 24509 |
|
| 24510 |
'use strict';
|
| 24515 |
|
| 24516 |
exports.default = isActive;
|
| 24517 |
|
| 24518 |
+
var _PatternUtils = __webpack_require__(188);
|
| 24519 |
|
| 24520 |
function deepEqual(a, b) {
|
| 24521 |
if (a == b) return true;
|
| 24661 |
module.exports = exports['default'];
|
| 24662 |
|
| 24663 |
/***/ },
|
| 24664 |
+
/* 201 */
|
| 24665 |
/***/ function(module, exports, __webpack_require__) {
|
| 24666 |
|
| 24667 |
'use strict';
|
| 24668 |
|
| 24669 |
exports.__esModule = true;
|
| 24670 |
|
| 24671 |
+
var _AsyncUtils = __webpack_require__(199);
|
| 24672 |
|
| 24673 |
+
var _PromiseUtils = __webpack_require__(202);
|
| 24674 |
|
| 24675 |
function getComponentsForRoute(nextState, route, callback) {
|
| 24676 |
if (route.component || route.components) {
|
| 24706 |
module.exports = exports['default'];
|
| 24707 |
|
| 24708 |
/***/ },
|
| 24709 |
+
/* 202 */
|
| 24710 |
/***/ function(module, exports) {
|
| 24711 |
|
| 24712 |
'use strict';
|
| 24718 |
}
|
| 24719 |
|
| 24720 |
/***/ },
|
| 24721 |
+
/* 203 */
|
| 24722 |
/***/ function(module, exports, __webpack_require__) {
|
| 24723 |
|
| 24724 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 24727 |
|
| 24728 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 24729 |
|
|
|
|
|
|
|
| 24730 |
exports.default = matchRoutes;
|
| 24731 |
|
| 24732 |
+
var _AsyncUtils = __webpack_require__(199);
|
| 24733 |
|
| 24734 |
+
var _PromiseUtils = __webpack_require__(202);
|
| 24735 |
|
| 24736 |
+
var _PatternUtils = __webpack_require__(188);
|
| 24737 |
|
| 24738 |
+
var _routerWarning = __webpack_require__(195);
|
| 24739 |
|
| 24740 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 24741 |
|
| 24875 |
// By assumption, pattern is non-empty here, which is the prerequisite for
|
| 24876 |
// actually terminating a match.
|
| 24877 |
if (remainingPathname === '') {
|
| 24878 |
+
var match = {
|
| 24879 |
+
routes: [route],
|
| 24880 |
+
params: createParams(paramNames, paramValues)
|
| 24881 |
+
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24882 |
|
| 24883 |
+
getIndexRoute(route, location, paramNames, paramValues, function (error, indexRoute) {
|
| 24884 |
+
if (error) {
|
| 24885 |
+
callback(error);
|
| 24886 |
+
} else {
|
| 24887 |
+
if (Array.isArray(indexRoute)) {
|
| 24888 |
+
var _match$routes;
|
| 24889 |
+
|
| 24890 |
+
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)(indexRoute.every(function (route) {
|
| 24891 |
+
return !route.path;
|
| 24892 |
+
}), 'Index routes should not have paths') : void 0;
|
| 24893 |
+
(_match$routes = match.routes).push.apply(_match$routes, indexRoute);
|
| 24894 |
+
} else if (indexRoute) {
|
| 24895 |
+
process.env.NODE_ENV !== 'production' ? (0, _routerWarning2.default)(!indexRoute.path, 'Index routes should not have paths') : void 0;
|
| 24896 |
+
match.routes.push(indexRoute);
|
| 24897 |
}
|
|
|
|
| 24898 |
|
| 24899 |
+
callback(null, match);
|
| 24900 |
+
}
|
| 24901 |
+
});
|
|
|
|
| 24902 |
|
| 24903 |
+
return;
|
| 24904 |
}
|
| 24905 |
}
|
| 24906 |
|
| 24979 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 24980 |
|
| 24981 |
/***/ },
|
| 24982 |
+
/* 204 */
|
| 24983 |
/***/ function(module, exports, __webpack_require__) {
|
| 24984 |
|
| 24985 |
'use strict';
|
| 24988 |
exports.routes = exports.route = exports.components = exports.component = exports.history = undefined;
|
| 24989 |
exports.falsy = falsy;
|
| 24990 |
|
| 24991 |
+
var _propTypes = __webpack_require__(184);
|
| 24992 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24993 |
function falsy(props, propName, componentName) {
|
| 24994 |
if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop');
|
| 24995 |
}
|
| 24996 |
|
| 24997 |
+
var history = exports.history = (0, _propTypes.shape)({
|
| 24998 |
+
listen: _propTypes.func.isRequired,
|
| 24999 |
+
push: _propTypes.func.isRequired,
|
| 25000 |
+
replace: _propTypes.func.isRequired,
|
| 25001 |
+
go: _propTypes.func.isRequired,
|
| 25002 |
+
goBack: _propTypes.func.isRequired,
|
| 25003 |
+
goForward: _propTypes.func.isRequired
|
| 25004 |
});
|
| 25005 |
|
| 25006 |
+
var component = exports.component = (0, _propTypes.oneOfType)([_propTypes.func, _propTypes.string]);
|
| 25007 |
+
var components = exports.components = (0, _propTypes.oneOfType)([component, _propTypes.object]);
|
| 25008 |
+
var route = exports.route = (0, _propTypes.oneOfType)([_propTypes.object, _propTypes.element]);
|
| 25009 |
+
var routes = exports.routes = (0, _propTypes.oneOfType)([route, (0, _propTypes.arrayOf)(route)]);
|
| 25010 |
|
| 25011 |
/***/ },
|
| 25012 |
+
/* 205 */
|
| 25013 |
/***/ function(module, exports, __webpack_require__) {
|
| 25014 |
|
| 25015 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25020 |
|
| 25021 |
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
|
| 25022 |
|
| 25023 |
+
var _invariant = __webpack_require__(189);
|
| 25024 |
|
| 25025 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25026 |
|
| 25028 |
|
| 25029 |
var _react2 = _interopRequireDefault(_react);
|
| 25030 |
|
| 25031 |
+
var _createReactClass = __webpack_require__(191);
|
| 25032 |
+
|
| 25033 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25034 |
+
|
| 25035 |
+
var _propTypes = __webpack_require__(184);
|
| 25036 |
+
|
| 25037 |
+
var _getRouteParams = __webpack_require__(206);
|
| 25038 |
|
| 25039 |
var _getRouteParams2 = _interopRequireDefault(_getRouteParams);
|
| 25040 |
|
| 25041 |
+
var _ContextUtils = __webpack_require__(207);
|
| 25042 |
|
| 25043 |
var _RouteUtils = __webpack_require__(182);
|
| 25044 |
|
| 25045 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25046 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25047 |
/**
|
| 25048 |
* A <RouterContext> renders the component tree for a given router state
|
| 25049 |
* and sets the history object and the current location in context.
|
| 25050 |
*/
|
| 25051 |
+
var RouterContext = (0, _createReactClass2.default)({
|
|
|
|
| 25052 |
displayName: 'RouterContext',
|
| 25053 |
|
|
|
|
| 25054 |
mixins: [(0, _ContextUtils.ContextProvider)('router')],
|
| 25055 |
|
| 25056 |
propTypes: {
|
| 25057 |
+
router: _propTypes.object.isRequired,
|
| 25058 |
+
location: _propTypes.object.isRequired,
|
| 25059 |
+
routes: _propTypes.array.isRequired,
|
| 25060 |
+
params: _propTypes.object.isRequired,
|
| 25061 |
+
components: _propTypes.array.isRequired,
|
| 25062 |
+
createElement: _propTypes.func.isRequired
|
| 25063 |
},
|
| 25064 |
|
| 25065 |
getDefaultProps: function getDefaultProps() {
|
| 25070 |
|
| 25071 |
|
| 25072 |
childContextTypes: {
|
| 25073 |
+
router: _propTypes.object.isRequired
|
| 25074 |
},
|
| 25075 |
|
| 25076 |
getChildContext: function getChildContext() {
|
| 25147 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25148 |
|
| 25149 |
/***/ },
|
| 25150 |
+
/* 206 */
|
| 25151 |
/***/ function(module, exports, __webpack_require__) {
|
| 25152 |
|
| 25153 |
'use strict';
|
| 25154 |
|
| 25155 |
exports.__esModule = true;
|
| 25156 |
|
| 25157 |
+
var _PatternUtils = __webpack_require__(188);
|
| 25158 |
|
| 25159 |
/**
|
| 25160 |
* Extracts an object of params the given route cares about from
|
| 25178 |
module.exports = exports['default'];
|
| 25179 |
|
| 25180 |
/***/ },
|
| 25181 |
+
/* 207 */
|
| 25182 |
/***/ function(module, exports, __webpack_require__) {
|
| 25183 |
|
| 25184 |
'use strict';
|
| 25187 |
exports.ContextProvider = ContextProvider;
|
| 25188 |
exports.ContextSubscriber = ContextSubscriber;
|
| 25189 |
|
| 25190 |
+
var _propTypes = __webpack_require__(184);
|
| 25191 |
+
|
| 25192 |
+
var _propTypes2 = _interopRequireDefault(_propTypes);
|
| 25193 |
+
|
| 25194 |
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25195 |
|
| 25196 |
// Works around issues with context updates failing to propagate.
|
| 25197 |
// Caveat: the context value is expected to never change its identity.
|
| 25198 |
// https://github.com/facebook/react/issues/2517
|
| 25199 |
// https://github.com/reactjs/react-router/issues/470
|
| 25200 |
|
| 25201 |
+
var contextProviderShape = _propTypes2.default.shape({
|
| 25202 |
+
subscribe: _propTypes2.default.func.isRequired,
|
| 25203 |
+
eventIndex: _propTypes2.default.number.isRequired
|
| 25204 |
});
|
| 25205 |
|
| 25206 |
function makeContextName(name) {
|
| 25308 |
}
|
| 25309 |
|
| 25310 |
/***/ },
|
| 25311 |
+
/* 208 */
|
| 25312 |
/***/ function(module, exports) {
|
| 25313 |
|
| 25314 |
"use strict";
|
| 25341 |
}
|
| 25342 |
|
| 25343 |
/***/ },
|
| 25344 |
+
/* 209 */
|
| 25345 |
/***/ function(module, exports, __webpack_require__) {
|
| 25346 |
|
| 25347 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25354 |
|
| 25355 |
var _react2 = _interopRequireDefault(_react);
|
| 25356 |
|
| 25357 |
+
var _createReactClass = __webpack_require__(191);
|
| 25358 |
+
|
| 25359 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25360 |
+
|
| 25361 |
+
var _propTypes = __webpack_require__(184);
|
| 25362 |
+
|
| 25363 |
+
var _invariant = __webpack_require__(189);
|
| 25364 |
|
| 25365 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25366 |
|
| 25367 |
var _PropTypes = __webpack_require__(183);
|
| 25368 |
|
| 25369 |
+
var _ContextUtils = __webpack_require__(207);
|
| 25370 |
|
| 25371 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25372 |
|
| 25373 |
function _objectWithoutProperties(obj, keys) { var target = {}; for (var i in obj) { if (keys.indexOf(i) >= 0) continue; if (!Object.prototype.hasOwnProperty.call(obj, i)) continue; target[i] = obj[i]; } return target; }
|
| 25374 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25375 |
function isLeftClickEvent(event) {
|
| 25376 |
return event.button === 0;
|
| 25377 |
}
|
| 25403 |
* You could use the following component to link to that route:
|
| 25404 |
*
|
| 25405 |
* <Link to={`/posts/${post.id}`} />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25406 |
*/
|
| 25407 |
+
var Link = (0, _createReactClass2.default)({
|
| 25408 |
displayName: 'Link',
|
| 25409 |
|
|
|
|
| 25410 |
mixins: [(0, _ContextUtils.ContextSubscriber)('router')],
|
| 25411 |
|
| 25412 |
contextTypes: {
|
| 25414 |
},
|
| 25415 |
|
| 25416 |
propTypes: {
|
| 25417 |
+
to: (0, _propTypes.oneOfType)([_propTypes.string, _propTypes.object, _propTypes.func]),
|
| 25418 |
+
activeStyle: _propTypes.object,
|
| 25419 |
+
activeClassName: _propTypes.string,
|
| 25420 |
+
onlyActiveOnIndex: _propTypes.bool.isRequired,
|
| 25421 |
+
onClick: _propTypes.func,
|
| 25422 |
+
target: _propTypes.string
|
|
|
|
|
|
|
|
|
|
| 25423 |
},
|
| 25424 |
|
| 25425 |
getDefaultProps: function getDefaultProps() {
|
| 25494 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25495 |
|
| 25496 |
/***/ },
|
| 25497 |
+
/* 210 */
|
| 25498 |
/***/ function(module, exports, __webpack_require__) {
|
| 25499 |
|
| 25500 |
'use strict';
|
| 25507 |
|
| 25508 |
var _react2 = _interopRequireDefault(_react);
|
| 25509 |
|
| 25510 |
+
var _createReactClass = __webpack_require__(191);
|
| 25511 |
+
|
| 25512 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25513 |
+
|
| 25514 |
+
var _Link = __webpack_require__(209);
|
| 25515 |
|
| 25516 |
var _Link2 = _interopRequireDefault(_Link);
|
| 25517 |
|
| 25520 |
/**
|
| 25521 |
* An <IndexLink> is used to link to an <IndexRoute>.
|
| 25522 |
*/
|
| 25523 |
+
var IndexLink = (0, _createReactClass2.default)({
|
| 25524 |
displayName: 'IndexLink',
|
| 25525 |
+
|
| 25526 |
render: function render() {
|
| 25527 |
return _react2.default.createElement(_Link2.default, _extends({}, this.props, { onlyActiveOnIndex: true }));
|
| 25528 |
}
|
| 25532 |
module.exports = exports['default'];
|
| 25533 |
|
| 25534 |
/***/ },
|
| 25535 |
+
/* 211 */
|
| 25536 |
/***/ function(module, exports, __webpack_require__) {
|
| 25537 |
|
| 25538 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25543 |
|
| 25544 |
exports.default = withRouter;
|
| 25545 |
|
| 25546 |
+
var _invariant = __webpack_require__(189);
|
| 25547 |
|
| 25548 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25549 |
|
| 25551 |
|
| 25552 |
var _react2 = _interopRequireDefault(_react);
|
| 25553 |
|
| 25554 |
+
var _createReactClass = __webpack_require__(191);
|
| 25555 |
+
|
| 25556 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25557 |
+
|
| 25558 |
+
var _hoistNonReactStatics = __webpack_require__(212);
|
| 25559 |
|
| 25560 |
var _hoistNonReactStatics2 = _interopRequireDefault(_hoistNonReactStatics);
|
| 25561 |
|
| 25562 |
+
var _ContextUtils = __webpack_require__(207);
|
| 25563 |
|
| 25564 |
var _PropTypes = __webpack_require__(183);
|
| 25565 |
|
| 25572 |
function withRouter(WrappedComponent, options) {
|
| 25573 |
var withRef = options && options.withRef;
|
| 25574 |
|
| 25575 |
+
var WithRouter = (0, _createReactClass2.default)({
|
| 25576 |
displayName: 'WithRouter',
|
| 25577 |
|
| 25578 |
mixins: [(0, _ContextUtils.ContextSubscriber)('router')],
|
| 25618 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25619 |
|
| 25620 |
/***/ },
|
| 25621 |
+
/* 212 */
|
| 25622 |
/***/ function(module, exports) {
|
| 25623 |
|
| 25624 |
/**
|
| 25674 |
|
| 25675 |
|
| 25676 |
/***/ },
|
| 25677 |
+
/* 213 */
|
| 25678 |
/***/ function(module, exports, __webpack_require__) {
|
| 25679 |
|
| 25680 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25681 |
|
| 25682 |
exports.__esModule = true;
|
| 25683 |
|
| 25684 |
+
var _createReactClass = __webpack_require__(191);
|
| 25685 |
|
| 25686 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25687 |
|
| 25688 |
+
var _propTypes = __webpack_require__(184);
|
| 25689 |
+
|
| 25690 |
+
var _routerWarning = __webpack_require__(195);
|
| 25691 |
|
| 25692 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 25693 |
|
| 25694 |
+
var _invariant = __webpack_require__(189);
|
| 25695 |
|
| 25696 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25697 |
|
| 25698 |
+
var _Redirect = __webpack_require__(214);
|
| 25699 |
|
| 25700 |
var _Redirect2 = _interopRequireDefault(_Redirect);
|
| 25701 |
|
| 25702 |
+
var _InternalPropTypes = __webpack_require__(204);
|
| 25703 |
|
| 25704 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25705 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25706 |
/**
|
| 25707 |
* An <IndexRedirect> is used to redirect from an indexRoute.
|
| 25708 |
*/
|
| 25709 |
/* eslint-disable react/require-render-return */
|
| 25710 |
+
var IndexRedirect = (0, _createReactClass2.default)({
|
|
|
|
| 25711 |
displayName: 'IndexRedirect',
|
| 25712 |
|
|
|
|
| 25713 |
statics: {
|
| 25714 |
createRouteFromReactElement: function createRouteFromReactElement(element, parentRoute) {
|
| 25715 |
/* istanbul ignore else: sanity check */
|
| 25722 |
},
|
| 25723 |
|
| 25724 |
propTypes: {
|
| 25725 |
+
to: _propTypes.string.isRequired,
|
| 25726 |
+
query: _propTypes.object,
|
| 25727 |
+
state: _propTypes.object,
|
| 25728 |
onEnter: _InternalPropTypes.falsy,
|
| 25729 |
children: _InternalPropTypes.falsy
|
| 25730 |
},
|
| 25740 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25741 |
|
| 25742 |
/***/ },
|
| 25743 |
+
/* 214 */
|
| 25744 |
/***/ function(module, exports, __webpack_require__) {
|
| 25745 |
|
| 25746 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25747 |
|
| 25748 |
exports.__esModule = true;
|
| 25749 |
|
| 25750 |
+
var _createReactClass = __webpack_require__(191);
|
| 25751 |
|
| 25752 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25753 |
|
| 25754 |
+
var _propTypes = __webpack_require__(184);
|
| 25755 |
+
|
| 25756 |
+
var _invariant = __webpack_require__(189);
|
| 25757 |
|
| 25758 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25759 |
|
| 25760 |
var _RouteUtils = __webpack_require__(182);
|
| 25761 |
|
| 25762 |
+
var _PatternUtils = __webpack_require__(188);
|
| 25763 |
|
| 25764 |
+
var _InternalPropTypes = __webpack_require__(204);
|
| 25765 |
|
| 25766 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25767 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25768 |
/**
|
| 25769 |
* A <Redirect> is used to declare another URL path a client should
|
| 25770 |
* be sent to when they request a given URL.
|
| 25773 |
* and are traversed in the same manner.
|
| 25774 |
*/
|
| 25775 |
/* eslint-disable react/require-render-return */
|
| 25776 |
+
var Redirect = (0, _createReactClass2.default)({
|
|
|
|
| 25777 |
displayName: 'Redirect',
|
| 25778 |
|
|
|
|
| 25779 |
statics: {
|
| 25780 |
createRouteFromReactElement: function createRouteFromReactElement(element) {
|
| 25781 |
var route = (0, _RouteUtils.createRouteFromReactElement)(element);
|
| 25825 |
},
|
| 25826 |
|
| 25827 |
propTypes: {
|
| 25828 |
+
path: _propTypes.string,
|
| 25829 |
+
from: _propTypes.string, // Alias for path
|
| 25830 |
+
to: _propTypes.string.isRequired,
|
| 25831 |
+
query: _propTypes.object,
|
| 25832 |
+
state: _propTypes.object,
|
| 25833 |
onEnter: _InternalPropTypes.falsy,
|
| 25834 |
children: _InternalPropTypes.falsy
|
| 25835 |
},
|
| 25845 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25846 |
|
| 25847 |
/***/ },
|
| 25848 |
+
/* 215 */
|
| 25849 |
/***/ function(module, exports, __webpack_require__) {
|
| 25850 |
|
| 25851 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25852 |
|
| 25853 |
exports.__esModule = true;
|
| 25854 |
|
| 25855 |
+
var _createReactClass = __webpack_require__(191);
|
| 25856 |
|
| 25857 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25858 |
|
| 25859 |
+
var _propTypes = __webpack_require__(184);
|
| 25860 |
+
|
| 25861 |
+
var _routerWarning = __webpack_require__(195);
|
| 25862 |
|
| 25863 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 25864 |
|
| 25865 |
+
var _invariant = __webpack_require__(189);
|
| 25866 |
|
| 25867 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25868 |
|
| 25869 |
var _RouteUtils = __webpack_require__(182);
|
| 25870 |
|
| 25871 |
+
var _InternalPropTypes = __webpack_require__(204);
|
| 25872 |
|
| 25873 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25874 |
|
|
|
|
|
|
|
| 25875 |
/**
|
| 25876 |
* An <IndexRoute> is used to specify its parent's <Route indexRoute> in
|
| 25877 |
* a JSX route config.
|
| 25878 |
*/
|
| 25879 |
/* eslint-disable react/require-render-return */
|
| 25880 |
+
var IndexRoute = (0, _createReactClass2.default)({
|
|
|
|
| 25881 |
displayName: 'IndexRoute',
|
| 25882 |
|
|
|
|
| 25883 |
statics: {
|
| 25884 |
createRouteFromReactElement: function createRouteFromReactElement(element, parentRoute) {
|
| 25885 |
/* istanbul ignore else: sanity check */
|
| 25895 |
path: _InternalPropTypes.falsy,
|
| 25896 |
component: _InternalPropTypes.component,
|
| 25897 |
components: _InternalPropTypes.components,
|
| 25898 |
+
getComponent: _propTypes.func,
|
| 25899 |
+
getComponents: _propTypes.func
|
| 25900 |
},
|
| 25901 |
|
| 25902 |
/* istanbul ignore next: sanity check */
|
| 25910 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25911 |
|
| 25912 |
/***/ },
|
| 25913 |
+
/* 216 */
|
| 25914 |
/***/ function(module, exports, __webpack_require__) {
|
| 25915 |
|
| 25916 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25917 |
|
| 25918 |
exports.__esModule = true;
|
| 25919 |
|
| 25920 |
+
var _createReactClass = __webpack_require__(191);
|
| 25921 |
|
| 25922 |
+
var _createReactClass2 = _interopRequireDefault(_createReactClass);
|
| 25923 |
|
| 25924 |
+
var _propTypes = __webpack_require__(184);
|
| 25925 |
+
|
| 25926 |
+
var _invariant = __webpack_require__(189);
|
| 25927 |
|
| 25928 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25929 |
|
| 25930 |
var _RouteUtils = __webpack_require__(182);
|
| 25931 |
|
| 25932 |
+
var _InternalPropTypes = __webpack_require__(204);
|
| 25933 |
|
| 25934 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 25935 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25936 |
/**
|
| 25937 |
* A <Route> is used to declare which components are rendered to the
|
| 25938 |
* page when the URL matches a given pattern.
|
| 25944 |
* rendered into the DOM, nested in the same order as in the tree.
|
| 25945 |
*/
|
| 25946 |
/* eslint-disable react/require-render-return */
|
| 25947 |
+
var Route = (0, _createReactClass2.default)({
|
|
|
|
| 25948 |
displayName: 'Route',
|
| 25949 |
|
|
|
|
| 25950 |
statics: {
|
| 25951 |
createRouteFromReactElement: _RouteUtils.createRouteFromReactElement
|
| 25952 |
},
|
| 25953 |
|
| 25954 |
propTypes: {
|
| 25955 |
+
path: _propTypes.string,
|
| 25956 |
component: _InternalPropTypes.component,
|
| 25957 |
components: _InternalPropTypes.components,
|
| 25958 |
+
getComponent: _propTypes.func,
|
| 25959 |
+
getComponents: _propTypes.func
|
| 25960 |
},
|
| 25961 |
|
| 25962 |
/* istanbul ignore next: sanity check */
|
| 25970 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 25971 |
|
| 25972 |
/***/ },
|
| 25973 |
+
/* 217 */
|
| 25974 |
/***/ function(module, exports, __webpack_require__) {
|
| 25975 |
|
| 25976 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 25979 |
|
| 25980 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 25981 |
|
| 25982 |
+
var _Actions = __webpack_require__(218);
|
| 25983 |
|
| 25984 |
+
var _invariant = __webpack_require__(189);
|
| 25985 |
|
| 25986 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 25987 |
|
| 25988 |
+
var _createMemoryHistory = __webpack_require__(219);
|
| 25989 |
|
| 25990 |
var _createMemoryHistory2 = _interopRequireDefault(_createMemoryHistory);
|
| 25991 |
|
| 25992 |
+
var _createTransitionManager = __webpack_require__(194);
|
| 25993 |
|
| 25994 |
var _createTransitionManager2 = _interopRequireDefault(_createTransitionManager);
|
| 25995 |
|
| 25996 |
var _RouteUtils = __webpack_require__(182);
|
| 25997 |
|
| 25998 |
+
var _RouterUtils = __webpack_require__(208);
|
| 25999 |
|
| 26000 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26001 |
|
| 26048 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26049 |
|
| 26050 |
/***/ },
|
| 26051 |
+
/* 218 */
|
| 26052 |
/***/ function(module, exports) {
|
| 26053 |
|
| 26054 |
'use strict';
|
| 26075 |
var POP = exports.POP = 'POP';
|
| 26076 |
|
| 26077 |
/***/ },
|
| 26078 |
+
/* 219 */
|
| 26079 |
/***/ function(module, exports, __webpack_require__) {
|
| 26080 |
|
| 26081 |
'use strict';
|
| 26083 |
exports.__esModule = true;
|
| 26084 |
exports.default = createMemoryHistory;
|
| 26085 |
|
| 26086 |
+
var _useQueries = __webpack_require__(220);
|
| 26087 |
|
| 26088 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 26089 |
|
| 26090 |
+
var _useBasename = __webpack_require__(227);
|
| 26091 |
|
| 26092 |
var _useBasename2 = _interopRequireDefault(_useBasename);
|
| 26093 |
|
| 26094 |
+
var _createMemoryHistory = __webpack_require__(228);
|
| 26095 |
|
| 26096 |
var _createMemoryHistory2 = _interopRequireDefault(_createMemoryHistory);
|
| 26097 |
|
| 26111 |
module.exports = exports['default'];
|
| 26112 |
|
| 26113 |
/***/ },
|
| 26114 |
+
/* 220 */
|
| 26115 |
/***/ function(module, exports, __webpack_require__) {
|
| 26116 |
|
| 26117 |
'use strict';
|
| 26120 |
|
| 26121 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 26122 |
|
| 26123 |
+
var _queryString = __webpack_require__(221);
|
| 26124 |
|
| 26125 |
+
var _runTransitionHook = __webpack_require__(224);
|
| 26126 |
|
| 26127 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 26128 |
|
| 26129 |
+
var _LocationUtils = __webpack_require__(225);
|
| 26130 |
|
| 26131 |
+
var _PathUtils = __webpack_require__(226);
|
| 26132 |
|
| 26133 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26134 |
|
| 26237 |
exports.default = useQueries;
|
| 26238 |
|
| 26239 |
/***/ },
|
| 26240 |
+
/* 221 */
|
| 26241 |
/***/ function(module, exports, __webpack_require__) {
|
| 26242 |
|
| 26243 |
'use strict';
|
| 26244 |
+
var strictUriEncode = __webpack_require__(222);
|
| 26245 |
+
var objectAssign = __webpack_require__(223);
|
| 26246 |
|
| 26247 |
function encoderForArrayFormat(opts) {
|
| 26248 |
switch (opts.arrayFormat) {
|
| 26446 |
|
| 26447 |
|
| 26448 |
/***/ },
|
| 26449 |
+
/* 222 */
|
| 26450 |
/***/ function(module, exports) {
|
| 26451 |
|
| 26452 |
'use strict';
|
| 26458 |
|
| 26459 |
|
| 26460 |
/***/ },
|
| 26461 |
+
/* 223 */
|
| 26462 |
/***/ function(module, exports) {
|
| 26463 |
|
| 26464 |
/*
|
| 26554 |
|
| 26555 |
|
| 26556 |
/***/ },
|
| 26557 |
+
/* 224 */
|
| 26558 |
/***/ function(module, exports, __webpack_require__) {
|
| 26559 |
|
| 26560 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 26561 |
|
| 26562 |
exports.__esModule = true;
|
| 26563 |
|
| 26564 |
+
var _warning = __webpack_require__(196);
|
| 26565 |
|
| 26566 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26567 |
|
| 26583 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26584 |
|
| 26585 |
/***/ },
|
| 26586 |
+
/* 225 */
|
| 26587 |
/***/ function(module, exports, __webpack_require__) {
|
| 26588 |
|
| 26589 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 26595 |
|
| 26596 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 26597 |
|
| 26598 |
+
var _invariant = __webpack_require__(189);
|
| 26599 |
|
| 26600 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 26601 |
|
| 26602 |
+
var _warning = __webpack_require__(196);
|
| 26603 |
|
| 26604 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26605 |
|
| 26606 |
+
var _PathUtils = __webpack_require__(226);
|
| 26607 |
|
| 26608 |
+
var _Actions = __webpack_require__(218);
|
| 26609 |
|
| 26610 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26611 |
|
| 26681 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26682 |
|
| 26683 |
/***/ },
|
| 26684 |
+
/* 226 */
|
| 26685 |
/***/ function(module, exports, __webpack_require__) {
|
| 26686 |
|
| 26687 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 26689 |
exports.__esModule = true;
|
| 26690 |
exports.createPath = exports.parsePath = exports.getQueryStringValueFromPath = exports.stripQueryStringValueFromPath = exports.addQueryStringValueToPath = undefined;
|
| 26691 |
|
| 26692 |
+
var _warning = __webpack_require__(196);
|
| 26693 |
|
| 26694 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26695 |
|
| 26783 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 26784 |
|
| 26785 |
/***/ },
|
| 26786 |
+
/* 227 */
|
| 26787 |
/***/ function(module, exports, __webpack_require__) {
|
| 26788 |
|
| 26789 |
'use strict';
|
| 26792 |
|
| 26793 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 26794 |
|
| 26795 |
+
var _runTransitionHook = __webpack_require__(224);
|
| 26796 |
|
| 26797 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 26798 |
|
| 26799 |
+
var _PathUtils = __webpack_require__(226);
|
| 26800 |
|
| 26801 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26802 |
|
| 26897 |
exports.default = useBasename;
|
| 26898 |
|
| 26899 |
/***/ },
|
| 26900 |
+
/* 228 */
|
| 26901 |
/***/ function(module, exports, __webpack_require__) {
|
| 26902 |
|
| 26903 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 26906 |
|
| 26907 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 26908 |
|
| 26909 |
+
var _warning = __webpack_require__(196);
|
| 26910 |
|
| 26911 |
var _warning2 = _interopRequireDefault(_warning);
|
| 26912 |
|
| 26913 |
+
var _invariant = __webpack_require__(189);
|
| 26914 |
|
| 26915 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 26916 |
|
| 26917 |
+
var _LocationUtils = __webpack_require__(225);
|
| 26918 |
|
| 26919 |
+
var _PathUtils = __webpack_require__(226);
|
| 26920 |
|
| 26921 |
+
var _createHistory = __webpack_require__(229);
|
| 26922 |
|
| 26923 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 26924 |
|
| 26925 |
+
var _Actions = __webpack_require__(218);
|
| 26926 |
|
| 26927 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 26928 |
|
| 27043 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 27044 |
|
| 27045 |
/***/ },
|
| 27046 |
+
/* 229 */
|
| 27047 |
/***/ function(module, exports, __webpack_require__) {
|
| 27048 |
|
| 27049 |
'use strict';
|
| 27050 |
|
| 27051 |
exports.__esModule = true;
|
| 27052 |
|
| 27053 |
+
var _AsyncUtils = __webpack_require__(230);
|
| 27054 |
|
| 27055 |
+
var _PathUtils = __webpack_require__(226);
|
| 27056 |
|
| 27057 |
+
var _runTransitionHook = __webpack_require__(224);
|
| 27058 |
|
| 27059 |
var _runTransitionHook2 = _interopRequireDefault(_runTransitionHook);
|
| 27060 |
|
| 27061 |
+
var _Actions = __webpack_require__(218);
|
| 27062 |
|
| 27063 |
+
var _LocationUtils = __webpack_require__(225);
|
| 27064 |
|
| 27065 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 27066 |
|
| 27224 |
exports.default = createHistory;
|
| 27225 |
|
| 27226 |
/***/ },
|
| 27227 |
+
/* 230 */
|
| 27228 |
/***/ function(module, exports) {
|
| 27229 |
|
| 27230 |
"use strict";
|
| 27285 |
};
|
| 27286 |
|
| 27287 |
/***/ },
|
| 27288 |
+
/* 231 */
|
| 27289 |
/***/ function(module, exports, __webpack_require__) {
|
| 27290 |
|
| 27291 |
'use strict';
|
| 27293 |
exports.__esModule = true;
|
| 27294 |
exports.default = useRouterHistory;
|
| 27295 |
|
| 27296 |
+
var _useQueries = __webpack_require__(220);
|
| 27297 |
|
| 27298 |
var _useQueries2 = _interopRequireDefault(_useQueries);
|
| 27299 |
|
| 27300 |
+
var _useBasename = __webpack_require__(227);
|
| 27301 |
|
| 27302 |
var _useBasename2 = _interopRequireDefault(_useBasename);
|
| 27303 |
|
| 27312 |
module.exports = exports['default'];
|
| 27313 |
|
| 27314 |
/***/ },
|
| 27315 |
+
/* 232 */
|
| 27316 |
/***/ function(module, exports, __webpack_require__) {
|
| 27317 |
|
| 27318 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 27325 |
|
| 27326 |
var _react2 = _interopRequireDefault(_react);
|
| 27327 |
|
| 27328 |
+
var _RouterContext = __webpack_require__(205);
|
| 27329 |
|
| 27330 |
var _RouterContext2 = _interopRequireDefault(_RouterContext);
|
| 27331 |
|
| 27332 |
+
var _routerWarning = __webpack_require__(195);
|
| 27333 |
|
| 27334 |
var _routerWarning2 = _interopRequireDefault(_routerWarning);
|
| 27335 |
|
| 27375 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 27376 |
|
| 27377 |
/***/ },
|
| 27378 |
+
/* 233 */
|
| 27379 |
/***/ function(module, exports, __webpack_require__) {
|
| 27380 |
|
| 27381 |
'use strict';
|
| 27382 |
|
| 27383 |
exports.__esModule = true;
|
| 27384 |
|
| 27385 |
+
var _createBrowserHistory = __webpack_require__(234);
|
| 27386 |
|
| 27387 |
var _createBrowserHistory2 = _interopRequireDefault(_createBrowserHistory);
|
| 27388 |
|
| 27389 |
+
var _createRouterHistory = __webpack_require__(240);
|
| 27390 |
|
| 27391 |
var _createRouterHistory2 = _interopRequireDefault(_createRouterHistory);
|
| 27392 |
|
| 27396 |
module.exports = exports['default'];
|
| 27397 |
|
| 27398 |
/***/ },
|
| 27399 |
+
/* 234 */
|
| 27400 |
/***/ function(module, exports, __webpack_require__) {
|
| 27401 |
|
| 27402 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 27405 |
|
| 27406 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 27407 |
|
| 27408 |
+
var _invariant = __webpack_require__(189);
|
| 27409 |
|
| 27410 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 27411 |
|
| 27412 |
+
var _ExecutionEnvironment = __webpack_require__(235);
|
| 27413 |
|
| 27414 |
+
var _BrowserProtocol = __webpack_require__(236);
|
| 27415 |
|
| 27416 |
var BrowserProtocol = _interopRequireWildcard(_BrowserProtocol);
|
| 27417 |
|
| 27418 |
+
var _RefreshProtocol = __webpack_require__(239);
|
| 27419 |
|
| 27420 |
var RefreshProtocol = _interopRequireWildcard(_RefreshProtocol);
|
| 27421 |
|
| 27422 |
+
var _DOMUtils = __webpack_require__(237);
|
| 27423 |
|
| 27424 |
+
var _createHistory = __webpack_require__(229);
|
| 27425 |
|
| 27426 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 27427 |
|
| 27495 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 27496 |
|
| 27497 |
/***/ },
|
| 27498 |
+
/* 235 */
|
| 27499 |
/***/ function(module, exports) {
|
| 27500 |
|
| 27501 |
'use strict';
|
| 27504 |
var canUseDOM = exports.canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
| 27505 |
|
| 27506 |
/***/ },
|
| 27507 |
+
/* 236 */
|
| 27508 |
/***/ function(module, exports, __webpack_require__) {
|
| 27509 |
|
| 27510 |
'use strict';
|
| 27512 |
exports.__esModule = true;
|
| 27513 |
exports.go = exports.replaceLocation = exports.pushLocation = exports.startListener = exports.getUserConfirmation = exports.getCurrentLocation = undefined;
|
| 27514 |
|
| 27515 |
+
var _LocationUtils = __webpack_require__(225);
|
| 27516 |
|
| 27517 |
+
var _DOMUtils = __webpack_require__(237);
|
| 27518 |
|
| 27519 |
+
var _DOMStateStorage = __webpack_require__(238);
|
| 27520 |
|
| 27521 |
+
var _PathUtils = __webpack_require__(226);
|
| 27522 |
|
| 27523 |
+
var _ExecutionEnvironment = __webpack_require__(235);
|
| 27524 |
|
| 27525 |
var PopStateEvent = 'popstate';
|
| 27526 |
var HashChangeEvent = 'hashchange';
|
| 27608 |
};
|
| 27609 |
|
| 27610 |
/***/ },
|
| 27611 |
+
/* 237 */
|
| 27612 |
/***/ function(module, exports) {
|
| 27613 |
|
| 27614 |
'use strict';
|
| 27662 |
};
|
| 27663 |
|
| 27664 |
/***/ },
|
| 27665 |
+
/* 238 */
|
| 27666 |
/***/ function(module, exports, __webpack_require__) {
|
| 27667 |
|
| 27668 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 27670 |
exports.__esModule = true;
|
| 27671 |
exports.readState = exports.saveState = undefined;
|
| 27672 |
|
| 27673 |
+
var _warning = __webpack_require__(196);
|
| 27674 |
|
| 27675 |
var _warning2 = _interopRequireDefault(_warning);
|
| 27676 |
|
| 27753 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 27754 |
|
| 27755 |
/***/ },
|
| 27756 |
+
/* 239 */
|
| 27757 |
/***/ function(module, exports, __webpack_require__) {
|
| 27758 |
|
| 27759 |
'use strict';
|
| 27761 |
exports.__esModule = true;
|
| 27762 |
exports.replaceLocation = exports.pushLocation = exports.getCurrentLocation = exports.go = exports.getUserConfirmation = undefined;
|
| 27763 |
|
| 27764 |
+
var _BrowserProtocol = __webpack_require__(236);
|
| 27765 |
|
| 27766 |
Object.defineProperty(exports, 'getUserConfirmation', {
|
| 27767 |
enumerable: true,
|
| 27776 |
}
|
| 27777 |
});
|
| 27778 |
|
| 27779 |
+
var _LocationUtils = __webpack_require__(225);
|
| 27780 |
|
| 27781 |
+
var _PathUtils = __webpack_require__(226);
|
| 27782 |
|
| 27783 |
var getCurrentLocation = exports.getCurrentLocation = function getCurrentLocation() {
|
| 27784 |
return (0, _LocationUtils.createLocation)(window.location);
|
| 27795 |
};
|
| 27796 |
|
| 27797 |
/***/ },
|
| 27798 |
+
/* 240 */
|
| 27799 |
/***/ function(module, exports, __webpack_require__) {
|
| 27800 |
|
| 27801 |
'use strict';
|
| 27802 |
|
| 27803 |
exports.__esModule = true;
|
| 27804 |
+
exports.default = createRouterHistory;
|
| 27805 |
|
| 27806 |
+
var _useRouterHistory = __webpack_require__(231);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 27807 |
|
| 27808 |
var _useRouterHistory2 = _interopRequireDefault(_useRouterHistory);
|
| 27809 |
|
| 27811 |
|
| 27812 |
var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
| 27813 |
|
| 27814 |
+
function createRouterHistory(createHistory) {
|
| 27815 |
+
var history = void 0;
|
| 27816 |
+
if (canUseDOM) history = (0, _useRouterHistory2.default)(createHistory)();
|
| 27817 |
+
return history;
|
| 27818 |
+
}
|
| 27819 |
module.exports = exports['default'];
|
| 27820 |
|
| 27821 |
/***/ },
|
| 27822 |
+
/* 241 */
|
| 27823 |
/***/ function(module, exports, __webpack_require__) {
|
| 27824 |
|
| 27825 |
'use strict';
|
| 27826 |
|
| 27827 |
exports.__esModule = true;
|
| 27828 |
|
| 27829 |
+
var _createHashHistory = __webpack_require__(242);
|
| 27830 |
|
| 27831 |
var _createHashHistory2 = _interopRequireDefault(_createHashHistory);
|
| 27832 |
|
| 27833 |
+
var _createRouterHistory = __webpack_require__(240);
|
| 27834 |
|
| 27835 |
var _createRouterHistory2 = _interopRequireDefault(_createRouterHistory);
|
| 27836 |
|
| 27840 |
module.exports = exports['default'];
|
| 27841 |
|
| 27842 |
/***/ },
|
| 27843 |
+
/* 242 */
|
| 27844 |
/***/ function(module, exports, __webpack_require__) {
|
| 27845 |
|
| 27846 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 27849 |
|
| 27850 |
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
| 27851 |
|
| 27852 |
+
var _warning = __webpack_require__(196);
|
| 27853 |
|
| 27854 |
var _warning2 = _interopRequireDefault(_warning);
|
| 27855 |
|
| 27856 |
+
var _invariant = __webpack_require__(189);
|
| 27857 |
|
| 27858 |
var _invariant2 = _interopRequireDefault(_invariant);
|
| 27859 |
|
| 27860 |
+
var _ExecutionEnvironment = __webpack_require__(235);
|
| 27861 |
|
| 27862 |
+
var _DOMUtils = __webpack_require__(237);
|
| 27863 |
|
| 27864 |
+
var _HashProtocol = __webpack_require__(243);
|
| 27865 |
|
| 27866 |
var HashProtocol = _interopRequireWildcard(_HashProtocol);
|
| 27867 |
|
| 27868 |
+
var _createHistory = __webpack_require__(229);
|
| 27869 |
|
| 27870 |
var _createHistory2 = _interopRequireDefault(_createHistory);
|
| 27871 |
|
| 27993 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 27994 |
|
| 27995 |
/***/ },
|
| 27996 |
+
/* 243 */
|
| 27997 |
/***/ function(module, exports, __webpack_require__) {
|
| 27998 |
|
| 27999 |
/* WEBPACK VAR INJECTION */(function(process) {'use strict';
|
| 28001 |
exports.__esModule = true;
|
| 28002 |
exports.replaceLocation = exports.pushLocation = exports.startListener = exports.getCurrentLocation = exports.go = exports.getUserConfirmation = undefined;
|
| 28003 |
|
| 28004 |
+
var _BrowserProtocol = __webpack_require__(236);
|
| 28005 |
|
| 28006 |
Object.defineProperty(exports, 'getUserConfirmation', {
|
| 28007 |
enumerable: true,
|
| 28016 |
}
|
| 28017 |
});
|
| 28018 |
|
| 28019 |
+
var _warning = __webpack_require__(196);
|
| 28020 |
|
| 28021 |
var _warning2 = _interopRequireDefault(_warning);
|
| 28022 |
|
| 28023 |
+
var _LocationUtils = __webpack_require__(225);
|
| 28024 |
|
| 28025 |
+
var _DOMUtils = __webpack_require__(237);
|
| 28026 |
|
| 28027 |
+
var _DOMStateStorage = __webpack_require__(238);
|
| 28028 |
|
| 28029 |
+
var _PathUtils = __webpack_require__(226);
|
| 28030 |
|
| 28031 |
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
| 28032 |
|
| 28135 |
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
|
| 28136 |
|
| 28137 |
/***/ },
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 28138 |
/* 244 */,
|
| 28139 |
/* 245 */,
|
| 28140 |
/* 246 */,
|
| 28182 |
/* 288 */,
|
| 28183 |
/* 289 */,
|
| 28184 |
/* 290 */,
|
| 28185 |
+
/* 291 */,
|
| 28186 |
+
/* 292 */,
|
| 28187 |
+
/* 293 */,
|
| 28188 |
+
/* 294 */,
|
| 28189 |
+
/* 295 */,
|
| 28190 |
+
/* 296 */,
|
| 28191 |
+
/* 297 */,
|
| 28192 |
+
/* 298 */
|
| 28193 |
/***/ function(module, exports) {
|
| 28194 |
|
| 28195 |
module.exports = function(module) {
|
| 28205 |
|
| 28206 |
|
| 28207 |
/***/ },
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 28208 |
/* 299 */,
|
| 28209 |
/* 300 */,
|
| 28210 |
/* 301 */,
|
| 28307 |
/* 398 */,
|
| 28308 |
/* 399 */,
|
| 28309 |
/* 400 */,
|
| 28310 |
+
/* 401 */,
|
| 28311 |
+
/* 402 */,
|
| 28312 |
+
/* 403 */,
|
| 28313 |
+
/* 404 */,
|
| 28314 |
+
/* 405 */,
|
| 28315 |
+
/* 406 */,
|
| 28316 |
+
/* 407 */,
|
| 28317 |
+
/* 408 */,
|
| 28318 |
+
/* 409 */,
|
| 28319 |
+
/* 410 */,
|
| 28320 |
+
/* 411 */,
|
| 28321 |
+
/* 412 */,
|
| 28322 |
+
/* 413 */,
|
| 28323 |
+
/* 414 */,
|
| 28324 |
+
/* 415 */
|
| 28325 |
/***/ function(module, exports, __webpack_require__) {
|
| 28326 |
|
| 28327 |
/* WEBPACK VAR INJECTION */(function(global) {if(!global["MailPoetLib"]) global["MailPoetLib"] = {};
|
| 28328 |
+
module.exports = global["MailPoetLib"]["ReactStringReplace"] = __webpack_require__(416);
|
| 28329 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 28330 |
|
| 28331 |
/***/ },
|
| 28332 |
+
/* 416 */
|
| 28333 |
/***/ function(module, exports, __webpack_require__) {
|
| 28334 |
|
| 28335 |
/* eslint-disable vars-on-top, no-var, prefer-template */
|
| 28336 |
+
var isRegExp = __webpack_require__(417);
|
| 28337 |
+
var escapeRegExp = __webpack_require__(418);
|
| 28338 |
+
var isString = __webpack_require__(419);
|
| 28339 |
+
var flatten = __webpack_require__(420);
|
| 28340 |
|
| 28341 |
/**
|
| 28342 |
* Given a string, replace every substring that is matched by the `match` regex
|
| 28394 |
|
| 28395 |
|
| 28396 |
/***/ },
|
| 28397 |
+
/* 417 */
|
| 28398 |
/***/ function(module, exports, __webpack_require__) {
|
| 28399 |
|
| 28400 |
/* WEBPACK VAR INJECTION */(function(global, module) {/**
|
| 28519 |
|
| 28520 |
module.exports = isRegExp;
|
| 28521 |
|
| 28522 |
+
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(298)(module)))
|
| 28523 |
|
| 28524 |
/***/ },
|
| 28525 |
+
/* 418 */
|
| 28526 |
/***/ function(module, exports) {
|
| 28527 |
|
| 28528 |
/* WEBPACK VAR INJECTION */(function(global) {/**
|
| 28695 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 28696 |
|
| 28697 |
/***/ },
|
| 28698 |
+
/* 419 */
|
| 28699 |
/***/ function(module, exports) {
|
| 28700 |
|
| 28701 |
/**
|
| 28796 |
|
| 28797 |
|
| 28798 |
/***/ },
|
| 28799 |
+
/* 420 */
|
| 28800 |
/***/ function(module, exports) {
|
| 28801 |
|
| 28802 |
/* WEBPACK VAR INJECTION */(function(global) {/**
|
assets/js/form_editor.js
CHANGED
|
@@ -3,22 +3,22 @@ webpackJsonp([2],{
|
|
| 3 |
/***/ 0:
|
| 4 |
/***/ function(module, exports, __webpack_require__) {
|
| 5 |
|
| 6 |
-
__webpack_require__(
|
| 7 |
-
__webpack_require__(
|
| 8 |
-
module.exports = __webpack_require__(
|
| 9 |
|
| 10 |
|
| 11 |
/***/ },
|
| 12 |
|
| 13 |
-
/***/
|
| 14 |
/***/ function(module, exports, __webpack_require__) {
|
| 15 |
|
| 16 |
-
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["WysijaForm"] = __webpack_require__(
|
| 17 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 18 |
|
| 19 |
/***/ },
|
| 20 |
|
| 21 |
-
/***/
|
| 22 |
/***/ function(module, exports) {
|
| 23 |
|
| 24 |
/*
|
|
@@ -1089,15 +1089,15 @@ webpackJsonp([2],{
|
|
| 1089 |
|
| 1090 |
/***/ },
|
| 1091 |
|
| 1092 |
-
/***/
|
| 1093 |
/***/ function(module, exports, __webpack_require__) {
|
| 1094 |
|
| 1095 |
-
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["CodeMirror"] = __webpack_require__(
|
| 1096 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 1097 |
|
| 1098 |
/***/ },
|
| 1099 |
|
| 1100 |
-
/***/
|
| 1101 |
/***/ function(module, exports, __webpack_require__) {
|
| 1102 |
|
| 1103 |
// CodeMirror, copyright (c) by Marijn Haverbeke and others
|
|
@@ -1110,58 +1110,59 @@ webpackJsonp([2],{
|
|
| 1110 |
// at http://marijnhaverbeke.nl/blog/#cm-internals .
|
| 1111 |
|
| 1112 |
(function (global, factory) {
|
| 1113 |
-
|
| 1114 |
-
|
| 1115 |
-
|
| 1116 |
}(this, (function () { 'use strict';
|
| 1117 |
|
| 1118 |
// Kludges for bugs and behavior differences that can't be feature
|
| 1119 |
// detected are enabled based on userAgent etc sniffing.
|
| 1120 |
-
var userAgent = navigator.userAgent
|
| 1121 |
-
var platform = navigator.platform
|
| 1122 |
-
|
| 1123 |
-
var gecko = /gecko\/\d/i.test(userAgent)
|
| 1124 |
-
var ie_upto10 = /MSIE \d/.test(userAgent)
|
| 1125 |
-
var ie_11up = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(userAgent)
|
| 1126 |
-
var edge = /Edge\/(\d+)/.exec(userAgent)
|
| 1127 |
-
var ie = ie_upto10 || ie_11up || edge
|
| 1128 |
-
var ie_version = ie && (ie_upto10 ? document.documentMode || 6 : +(edge || ie_11up)[1])
|
| 1129 |
-
var webkit = !edge && /WebKit\//.test(userAgent)
|
| 1130 |
-
var qtwebkit = webkit && /Qt\/\d+\.\d+/.test(userAgent)
|
| 1131 |
-
var chrome = !edge && /Chrome\//.test(userAgent)
|
| 1132 |
-
var presto = /Opera\//.test(userAgent)
|
| 1133 |
-
var safari = /Apple Computer/.test(navigator.vendor)
|
| 1134 |
-
var mac_geMountainLion = /Mac OS X 1\d\D([8-9]|\d\d)\D/.test(userAgent)
|
| 1135 |
-
var phantom = /PhantomJS/.test(userAgent)
|
| 1136 |
-
|
| 1137 |
-
var ios = !edge && /AppleWebKit/.test(userAgent) && /Mobile\/\w+/.test(userAgent)
|
|
|
|
| 1138 |
// This is woefully incomplete. Suggestions for alternative methods welcome.
|
| 1139 |
-
var mobile = ios || /
|
| 1140 |
-
var mac = ios || /Mac/.test(platform)
|
| 1141 |
-
var chromeOS = /\bCrOS\b/.test(userAgent)
|
| 1142 |
-
var windows = /win/i.test(platform)
|
| 1143 |
-
|
| 1144 |
-
var presto_version = presto && userAgent.match(/Version\/(\d*\.\d*)/)
|
| 1145 |
-
if (presto_version) { presto_version = Number(presto_version[1]) }
|
| 1146 |
-
if (presto_version && presto_version >= 15) { presto = false; webkit = true }
|
| 1147 |
// Some browsers use the wrong event properties to signal cmd/ctrl on OS X
|
| 1148 |
-
var flipCtrlCmd = mac && (qtwebkit || presto && (presto_version == null || presto_version < 12.11))
|
| 1149 |
-
var captureRightClick = gecko || (ie && ie_version >= 9)
|
| 1150 |
|
| 1151 |
function classTest(cls) { return new RegExp("(^|\\s)" + cls + "(?:$|\\s)\\s*") }
|
| 1152 |
|
| 1153 |
var rmClass = function(node, cls) {
|
| 1154 |
-
var current = node.className
|
| 1155 |
-
var match = classTest(cls).exec(current)
|
| 1156 |
if (match) {
|
| 1157 |
-
var after = current.slice(match.index + match[0].length)
|
| 1158 |
-
node.className = current.slice(0, match.index) + (after ? match[1] + after : "")
|
| 1159 |
}
|
| 1160 |
-
}
|
| 1161 |
|
| 1162 |
function removeChildren(e) {
|
| 1163 |
for (var count = e.childNodes.length; count > 0; --count)
|
| 1164 |
-
{ e.removeChild(e.firstChild) }
|
| 1165 |
return e
|
| 1166 |
}
|
| 1167 |
|
|
@@ -1170,38 +1171,44 @@ webpackJsonp([2],{
|
|
| 1170 |
}
|
| 1171 |
|
| 1172 |
function elt(tag, content, className, style) {
|
| 1173 |
-
var e = document.createElement(tag)
|
| 1174 |
-
if (className) { e.className = className }
|
| 1175 |
-
if (style) { e.style.cssText = style }
|
| 1176 |
-
if (typeof content == "string") { e.appendChild(document.createTextNode(content)) }
|
| 1177 |
-
else if (content) { for (var i = 0; i < content.length; ++i) { e.appendChild(content[i]) } }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1178 |
return e
|
| 1179 |
}
|
| 1180 |
|
| 1181 |
-
var range
|
| 1182 |
if (document.createRange) { range = function(node, start, end, endNode) {
|
| 1183 |
-
var r = document.createRange()
|
| 1184 |
-
r.setEnd(endNode || node, end)
|
| 1185 |
-
r.setStart(node, start)
|
| 1186 |
return r
|
| 1187 |
-
} }
|
| 1188 |
else { range = function(node, start, end) {
|
| 1189 |
-
var r = document.body.createTextRange()
|
| 1190 |
-
try { r.moveToElementText(node.parentNode) }
|
| 1191 |
catch(e) { return r }
|
| 1192 |
-
r.collapse(true)
|
| 1193 |
-
r.moveEnd("character", end)
|
| 1194 |
-
r.moveStart("character", start)
|
| 1195 |
return r
|
| 1196 |
-
} }
|
| 1197 |
|
| 1198 |
function contains(parent, child) {
|
| 1199 |
if (child.nodeType == 3) // Android browser always returns false when child is a textnode
|
| 1200 |
-
{ child = child.parentNode }
|
| 1201 |
if (parent.contains)
|
| 1202 |
{ return parent.contains(child) }
|
| 1203 |
do {
|
| 1204 |
-
if (child.nodeType == 11) { child = child.host }
|
| 1205 |
if (child == parent) { return true }
|
| 1206 |
} while (child = child.parentNode)
|
| 1207 |
}
|
|
@@ -1210,44 +1217,44 @@ webpackJsonp([2],{
|
|
| 1210 |
// IE and Edge may throw an "Unspecified Error" when accessing document.activeElement.
|
| 1211 |
// IE < 10 will throw when accessed while the page is loading or in an iframe.
|
| 1212 |
// IE > 9 and Edge will throw when accessed in an iframe if document.body is unavailable.
|
| 1213 |
-
var activeElement
|
| 1214 |
try {
|
| 1215 |
-
activeElement = document.activeElement
|
| 1216 |
} catch(e) {
|
| 1217 |
-
activeElement = document.body || null
|
| 1218 |
}
|
| 1219 |
-
while (activeElement && activeElement.
|
| 1220 |
-
{ activeElement = activeElement.
|
| 1221 |
return activeElement
|
| 1222 |
}
|
| 1223 |
|
| 1224 |
function addClass(node, cls) {
|
| 1225 |
-
var current = node.className
|
| 1226 |
-
if (!classTest(cls).test(current)) { node.className += (current ? " " : "") + cls }
|
| 1227 |
}
|
| 1228 |
function joinClasses(a, b) {
|
| 1229 |
-
var as = a.split(" ")
|
| 1230 |
for (var i = 0; i < as.length; i++)
|
| 1231 |
-
{ if (as[i] && !classTest(as[i]).test(b)) { b += " " + as[i] } }
|
| 1232 |
return b
|
| 1233 |
}
|
| 1234 |
|
| 1235 |
-
var selectInput = function(node) { node.select() }
|
| 1236 |
if (ios) // Mobile Safari apparently has a bug where select() is broken.
|
| 1237 |
-
{ selectInput = function(node) { node.selectionStart = 0; node.selectionEnd = node.value.length } }
|
| 1238 |
else if (ie) // Suppress mysterious IE10 errors
|
| 1239 |
-
{ selectInput = function(node) { try { node.select() } catch(_e) {} } }
|
| 1240 |
|
| 1241 |
function bind(f) {
|
| 1242 |
-
var args = Array.prototype.slice.call(arguments, 1)
|
| 1243 |
return function(){return f.apply(null, args)}
|
| 1244 |
}
|
| 1245 |
|
| 1246 |
function copyObj(obj, target, overwrite) {
|
| 1247 |
-
if (!target) { target = {} }
|
| 1248 |
for (var prop in obj)
|
| 1249 |
{ if (obj.hasOwnProperty(prop) && (overwrite !== false || !target.hasOwnProperty(prop)))
|
| 1250 |
-
{ target[prop] = obj[prop] } }
|
| 1251 |
return target
|
| 1252 |
}
|
| 1253 |
|
|
@@ -1255,23 +1262,23 @@ webpackJsonp([2],{
|
|
| 1255 |
// Used mostly to find indentation.
|
| 1256 |
function countColumn(string, end, tabSize, startIndex, startValue) {
|
| 1257 |
if (end == null) {
|
| 1258 |
-
end = string.search(/[^\s\u00a0]/)
|
| 1259 |
-
if (end == -1) { end = string.length }
|
| 1260 |
}
|
| 1261 |
for (var i = startIndex || 0, n = startValue || 0;;) {
|
| 1262 |
-
var nextTab = string.indexOf("\t", i)
|
| 1263 |
if (nextTab < 0 || nextTab >= end)
|
| 1264 |
{ return n + (end - i) }
|
| 1265 |
-
n += nextTab - i
|
| 1266 |
-
n += tabSize - (n % tabSize)
|
| 1267 |
-
i = nextTab + 1
|
| 1268 |
}
|
| 1269 |
}
|
| 1270 |
|
| 1271 |
-
var Delayed = function() {this.id = null};
|
| 1272 |
Delayed.prototype.set = function (ms, f) {
|
| 1273 |
-
clearTimeout(this.id)
|
| 1274 |
-
this.id = setTimeout(f, ms)
|
| 1275 |
};
|
| 1276 |
|
| 1277 |
function indexOf(array, elt) {
|
|
@@ -1281,68 +1288,69 @@ webpackJsonp([2],{
|
|
| 1281 |
}
|
| 1282 |
|
| 1283 |
// Number of pixels added to scroller and sizer to hide scrollbar
|
| 1284 |
-
var scrollerGap = 30
|
| 1285 |
|
| 1286 |
// Returned or thrown by various protocols to signal 'I'm not
|
| 1287 |
// handling this'.
|
| 1288 |
-
var Pass = {toString: function(){return "CodeMirror.Pass"}}
|
| 1289 |
|
| 1290 |
// Reused option objects for setSelection & friends
|
| 1291 |
var sel_dontScroll = {scroll: false};
|
| 1292 |
var sel_mouse = {origin: "*mouse"};
|
| 1293 |
var sel_move = {origin: "+move"};
|
|
|
|
| 1294 |
// The inverse of countColumn -- find the offset that corresponds to
|
| 1295 |
// a particular column.
|
| 1296 |
function findColumn(string, goal, tabSize) {
|
| 1297 |
for (var pos = 0, col = 0;;) {
|
| 1298 |
-
var nextTab = string.indexOf("\t", pos)
|
| 1299 |
-
if (nextTab == -1) { nextTab = string.length }
|
| 1300 |
-
var skipped = nextTab - pos
|
| 1301 |
if (nextTab == string.length || col + skipped >= goal)
|
| 1302 |
{ return pos + Math.min(skipped, goal - col) }
|
| 1303 |
-
col += nextTab - pos
|
| 1304 |
-
col += tabSize - (col % tabSize)
|
| 1305 |
-
pos = nextTab + 1
|
| 1306 |
if (col >= goal) { return pos }
|
| 1307 |
}
|
| 1308 |
}
|
| 1309 |
|
| 1310 |
-
var spaceStrs = [""]
|
| 1311 |
function spaceStr(n) {
|
| 1312 |
while (spaceStrs.length <= n)
|
| 1313 |
-
{ spaceStrs.push(lst(spaceStrs) + " ") }
|
| 1314 |
return spaceStrs[n]
|
| 1315 |
}
|
| 1316 |
|
| 1317 |
function lst(arr) { return arr[arr.length-1] }
|
| 1318 |
|
| 1319 |
function map(array, f) {
|
| 1320 |
-
var out = []
|
| 1321 |
-
for (var i = 0; i < array.length; i++) { out[i] = f(array[i], i) }
|
| 1322 |
return out
|
| 1323 |
}
|
| 1324 |
|
| 1325 |
function insertSorted(array, value, score) {
|
| 1326 |
-
var pos = 0, priority = score(value)
|
| 1327 |
-
while (pos < array.length && score(array[pos]) <= priority) { pos
|
| 1328 |
-
array.splice(pos, 0, value)
|
| 1329 |
}
|
| 1330 |
|
| 1331 |
function nothing() {}
|
| 1332 |
|
| 1333 |
function createObj(base, props) {
|
| 1334 |
-
var inst
|
| 1335 |
if (Object.create) {
|
| 1336 |
-
inst = Object.create(base)
|
| 1337 |
} else {
|
| 1338 |
-
nothing.prototype = base
|
| 1339 |
-
inst = new nothing()
|
| 1340 |
}
|
| 1341 |
-
if (props) { copyObj(props, inst) }
|
| 1342 |
return inst
|
| 1343 |
}
|
| 1344 |
|
| 1345 |
-
var nonASCIISingleCaseWordChar = /[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]
|
| 1346 |
function isWordCharBasic(ch) {
|
| 1347 |
return /\w/.test(ch) || ch > "\x80" &&
|
| 1348 |
(ch.toUpperCase() != ch.toLowerCase() || nonASCIISingleCaseWordChar.test(ch))
|
|
@@ -1363,12 +1371,12 @@ webpackJsonp([2],{
|
|
| 1363 |
// as editing and measuring is concerned. This is not fully correct,
|
| 1364 |
// since some scripts/fonts/browsers also treat other configurations
|
| 1365 |
// of code points as a group.
|
| 1366 |
-
var extendingChars = /[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]
|
| 1367 |
function isExtendingChar(ch) { return ch.charCodeAt(0) >= 768 && extendingChars.test(ch) }
|
| 1368 |
|
| 1369 |
// Returns a number from the range [`0`; `str.length`] unless `pos` is outside that range.
|
| 1370 |
function skipExtendingChars(str, pos, dir) {
|
| 1371 |
-
while ((dir < 0 ? pos > 0 : pos < str.length) && isExtendingChar(str.charAt(pos))) { pos += dir }
|
| 1372 |
return pos
|
| 1373 |
}
|
| 1374 |
|
|
@@ -1377,9 +1385,9 @@ webpackJsonp([2],{
|
|
| 1377 |
function findFirst(pred, from, to) {
|
| 1378 |
for (;;) {
|
| 1379 |
if (Math.abs(from - to) <= 1) { return pred(from) ? from : to }
|
| 1380 |
-
var mid = Math.floor((from + to) / 2)
|
| 1381 |
-
if (pred(mid)) { to = mid }
|
| 1382 |
-
else { from = mid }
|
| 1383 |
}
|
| 1384 |
}
|
| 1385 |
|
|
@@ -1388,113 +1396,114 @@ webpackJsonp([2],{
|
|
| 1388 |
// display-related state.
|
| 1389 |
|
| 1390 |
function Display(place, doc, input) {
|
| 1391 |
-
var d = this
|
| 1392 |
-
this.input = input
|
| 1393 |
|
| 1394 |
// Covers bottom-right square when both scrollbars are present.
|
| 1395 |
-
d.scrollbarFiller = elt("div", null, "CodeMirror-scrollbar-filler")
|
| 1396 |
-
d.scrollbarFiller.setAttribute("cm-not-content", "true")
|
| 1397 |
// Covers bottom of gutter when coverGutterNextToScrollbar is on
|
| 1398 |
// and h scrollbar is present.
|
| 1399 |
-
d.gutterFiller = elt("div", null, "CodeMirror-gutter-filler")
|
| 1400 |
-
d.gutterFiller.setAttribute("cm-not-content", "true")
|
| 1401 |
// Will contain the actual code, positioned to cover the viewport.
|
| 1402 |
-
d.lineDiv =
|
| 1403 |
// Elements are added to these to represent selection and cursors.
|
| 1404 |
-
d.selectionDiv = elt("div", null, null, "position: relative; z-index: 1")
|
| 1405 |
-
d.cursorDiv = elt("div", null, "CodeMirror-cursors")
|
| 1406 |
// A visibility: hidden element used to find the size of things.
|
| 1407 |
-
d.measure = elt("div", null, "CodeMirror-measure")
|
| 1408 |
// When lines outside of the viewport are measured, they are drawn in this.
|
| 1409 |
-
d.lineMeasure = elt("div", null, "CodeMirror-measure")
|
| 1410 |
// Wraps everything that needs to exist inside the vertically-padded coordinate system
|
| 1411 |
-
d.lineSpace =
|
| 1412 |
-
null, "position: relative; outline: none")
|
|
|
|
| 1413 |
// Moved around its parent to cover visible view.
|
| 1414 |
-
d.mover = elt("div", [
|
| 1415 |
// Set to the height of the document, allowing scrolling.
|
| 1416 |
-
d.sizer = elt("div", [d.mover], "CodeMirror-sizer")
|
| 1417 |
-
d.sizerWidth = null
|
| 1418 |
// Behavior of elts with overflow: auto and padding is
|
| 1419 |
// inconsistent across browsers. This is used to ensure the
|
| 1420 |
// scrollable area is big enough.
|
| 1421 |
-
d.heightForcer = elt("div", null, null, "position: absolute; height: " + scrollerGap + "px; width: 1px;")
|
| 1422 |
// Will contain the gutters, if any.
|
| 1423 |
-
d.gutters = elt("div", null, "CodeMirror-gutters")
|
| 1424 |
-
d.lineGutter = null
|
| 1425 |
// Actual scrollable element.
|
| 1426 |
-
d.scroller = elt("div", [d.sizer, d.heightForcer, d.gutters], "CodeMirror-scroll")
|
| 1427 |
-
d.scroller.setAttribute("tabIndex", "-1")
|
| 1428 |
// The element in which the editor lives.
|
| 1429 |
-
d.wrapper = elt("div", [d.scrollbarFiller, d.gutterFiller, d.scroller], "CodeMirror")
|
| 1430 |
|
| 1431 |
// Work around IE7 z-index bug (not perfect, hence IE7 not really being supported)
|
| 1432 |
-
if (ie && ie_version < 8) { d.gutters.style.zIndex = -1; d.scroller.style.paddingRight = 0 }
|
| 1433 |
-
if (!webkit && !(gecko && mobile)) { d.scroller.draggable = true }
|
| 1434 |
|
| 1435 |
if (place) {
|
| 1436 |
-
if (place.appendChild) { place.appendChild(d.wrapper) }
|
| 1437 |
-
else { place(d.wrapper) }
|
| 1438 |
}
|
| 1439 |
|
| 1440 |
// Current rendered range (may be bigger than the view window).
|
| 1441 |
-
d.viewFrom = d.viewTo = doc.first
|
| 1442 |
-
d.reportedViewFrom = d.reportedViewTo = doc.first
|
| 1443 |
// Information about the rendered lines.
|
| 1444 |
-
d.view = []
|
| 1445 |
-
d.renderedView = null
|
| 1446 |
// Holds info about a single rendered line when it was rendered
|
| 1447 |
// for measurement, while not in view.
|
| 1448 |
-
d.externalMeasured = null
|
| 1449 |
// Empty space (in pixels) above the view
|
| 1450 |
-
d.viewOffset = 0
|
| 1451 |
-
d.lastWrapHeight = d.lastWrapWidth = 0
|
| 1452 |
-
d.updateLineNumbers = null
|
| 1453 |
|
| 1454 |
-
d.nativeBarWidth = d.barHeight = d.barWidth = 0
|
| 1455 |
-
d.scrollbarsClipped = false
|
| 1456 |
|
| 1457 |
// Used to only resize the line number gutter when necessary (when
|
| 1458 |
// the amount of lines crosses a boundary that makes its width change)
|
| 1459 |
-
d.lineNumWidth = d.lineNumInnerWidth = d.lineNumChars = null
|
| 1460 |
// Set to true when a non-horizontal-scrolling line widget is
|
| 1461 |
// added. As an optimization, line widget aligning is skipped when
|
| 1462 |
// this is false.
|
| 1463 |
-
d.alignWidgets = false
|
| 1464 |
|
| 1465 |
-
d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = null
|
| 1466 |
|
| 1467 |
// Tracks the maximum line length so that the horizontal scrollbar
|
| 1468 |
// can be kept static when scrolling.
|
| 1469 |
-
d.maxLine = null
|
| 1470 |
-
d.maxLineLength = 0
|
| 1471 |
-
d.maxLineChanged = false
|
| 1472 |
|
| 1473 |
// Used for measuring wheel scrolling granularity
|
| 1474 |
-
d.wheelDX = d.wheelDY = d.wheelStartX = d.wheelStartY = null
|
| 1475 |
|
| 1476 |
// True when shift is held down.
|
| 1477 |
-
d.shift = false
|
| 1478 |
|
| 1479 |
// Used to track whether anything happened since the context menu
|
| 1480 |
// was opened.
|
| 1481 |
-
d.selForContextMenu = null
|
| 1482 |
|
| 1483 |
-
d.activeTouch = null
|
| 1484 |
|
| 1485 |
-
input.init(d)
|
| 1486 |
}
|
| 1487 |
|
| 1488 |
// Find the line object corresponding to the given line number.
|
| 1489 |
function getLine(doc, n) {
|
| 1490 |
-
n -= doc.first
|
| 1491 |
if (n < 0 || n >= doc.size) { throw new Error("There is no line " + (n + doc.first) + " in the document.") }
|
| 1492 |
-
var chunk = doc
|
| 1493 |
while (!chunk.lines) {
|
| 1494 |
for (var i = 0;; ++i) {
|
| 1495 |
-
var child = chunk.children[i], sz = child.chunkSize()
|
| 1496 |
if (n < sz) { chunk = child; break }
|
| 1497 |
-
n -= sz
|
| 1498 |
}
|
| 1499 |
}
|
| 1500 |
return chunk.lines[n]
|
|
@@ -1503,39 +1512,39 @@ webpackJsonp([2],{
|
|
| 1503 |
// Get the part of a document between two positions, as an array of
|
| 1504 |
// strings.
|
| 1505 |
function getBetween(doc, start, end) {
|
| 1506 |
-
var out = [], n = start.line
|
| 1507 |
doc.iter(start.line, end.line + 1, function (line) {
|
| 1508 |
-
var text = line.text
|
| 1509 |
-
if (n == end.line) { text = text.slice(0, end.ch) }
|
| 1510 |
-
if (n == start.line) { text = text.slice(start.ch) }
|
| 1511 |
-
out.push(text)
|
| 1512 |
-
++n
|
| 1513 |
-
})
|
| 1514 |
return out
|
| 1515 |
}
|
| 1516 |
// Get the lines between from and to, as array of strings.
|
| 1517 |
function getLines(doc, from, to) {
|
| 1518 |
-
var out = []
|
| 1519 |
-
doc.iter(from, to, function (line) { out.push(line.text) }) // iter aborts when callback returns truthy value
|
| 1520 |
return out
|
| 1521 |
}
|
| 1522 |
|
| 1523 |
// Update the height of a line, propagating the height change
|
| 1524 |
// upwards to parent nodes.
|
| 1525 |
function updateLineHeight(line, height) {
|
| 1526 |
-
var diff = height - line.height
|
| 1527 |
-
if (diff) { for (var n = line; n; n = n.parent) { n.height += diff } }
|
| 1528 |
}
|
| 1529 |
|
| 1530 |
// Given a line object, find its line number by walking up through
|
| 1531 |
// its parent links.
|
| 1532 |
function lineNo(line) {
|
| 1533 |
if (line.parent == null) { return null }
|
| 1534 |
-
var cur = line.parent, no = indexOf(cur.lines, line)
|
| 1535 |
for (var chunk = cur.parent; chunk; cur = chunk, chunk = chunk.parent) {
|
| 1536 |
for (var i = 0;; ++i) {
|
| 1537 |
if (chunk.children[i] == cur) { break }
|
| 1538 |
-
no += chunk.children[i].chunkSize()
|
| 1539 |
}
|
| 1540 |
}
|
| 1541 |
return no + cur.first
|
|
@@ -1544,21 +1553,21 @@ webpackJsonp([2],{
|
|
| 1544 |
// Find the line at the given vertical position, using the height
|
| 1545 |
// information in the document tree.
|
| 1546 |
function lineAtHeight(chunk, h) {
|
| 1547 |
-
var n = chunk.first
|
| 1548 |
outer: do {
|
| 1549 |
for (var i$1 = 0; i$1 < chunk.children.length; ++i$1) {
|
| 1550 |
-
var child = chunk.children[i$1], ch = child.height
|
| 1551 |
if (h < ch) { chunk = child; continue outer }
|
| 1552 |
-
h -= ch
|
| 1553 |
-
n += child.chunkSize()
|
| 1554 |
}
|
| 1555 |
return n
|
| 1556 |
} while (!chunk.lines)
|
| 1557 |
-
var i = 0
|
| 1558 |
for (; i < chunk.lines.length; ++i) {
|
| 1559 |
-
var line = chunk.lines[i], lh = line.height
|
| 1560 |
if (h < lh) { break }
|
| 1561 |
-
h -= lh
|
| 1562 |
}
|
| 1563 |
return n + i
|
| 1564 |
}
|
|
@@ -1574,9 +1583,9 @@ webpackJsonp([2],{
|
|
| 1574 |
if ( sticky === void 0 ) sticky = null;
|
| 1575 |
|
| 1576 |
if (!(this instanceof Pos)) { return new Pos(line, ch, sticky) }
|
| 1577 |
-
this.line = line
|
| 1578 |
-
this.ch = ch
|
| 1579 |
-
this.sticky = sticky
|
| 1580 |
}
|
| 1581 |
|
| 1582 |
// Compare two positions, return 0 if they are the same, a negative
|
|
@@ -1594,59 +1603,60 @@ webpackJsonp([2],{
|
|
| 1594 |
function clipLine(doc, n) {return Math.max(doc.first, Math.min(n, doc.first + doc.size - 1))}
|
| 1595 |
function clipPos(doc, pos) {
|
| 1596 |
if (pos.line < doc.first) { return Pos(doc.first, 0) }
|
| 1597 |
-
var last = doc.first + doc.size - 1
|
| 1598 |
if (pos.line > last) { return Pos(last, getLine(doc, last).text.length) }
|
| 1599 |
return clipToLen(pos, getLine(doc, pos.line).text.length)
|
| 1600 |
}
|
| 1601 |
function clipToLen(pos, linelen) {
|
| 1602 |
-
var ch = pos.ch
|
| 1603 |
if (ch == null || ch > linelen) { return Pos(pos.line, linelen) }
|
| 1604 |
else if (ch < 0) { return Pos(pos.line, 0) }
|
| 1605 |
else { return pos }
|
| 1606 |
}
|
| 1607 |
function clipPosArray(doc, array) {
|
| 1608 |
-
var out = []
|
| 1609 |
-
for (var i = 0; i < array.length; i++) { out[i] = clipPos(doc, array[i]) }
|
| 1610 |
return out
|
| 1611 |
}
|
| 1612 |
|
| 1613 |
// Optimize some code when these features are not used.
|
| 1614 |
var sawReadOnlySpans = false;
|
| 1615 |
var sawCollapsedSpans = false;
|
|
|
|
| 1616 |
function seeReadOnlySpans() {
|
| 1617 |
-
sawReadOnlySpans = true
|
| 1618 |
}
|
| 1619 |
|
| 1620 |
function seeCollapsedSpans() {
|
| 1621 |
-
sawCollapsedSpans = true
|
| 1622 |
}
|
| 1623 |
|
| 1624 |
// TEXTMARKER SPANS
|
| 1625 |
|
| 1626 |
function MarkedSpan(marker, from, to) {
|
| 1627 |
-
this.marker = marker
|
| 1628 |
-
this.from = from; this.to = to
|
| 1629 |
}
|
| 1630 |
|
| 1631 |
// Search an array of spans for a span matching the given marker.
|
| 1632 |
function getMarkedSpanFor(spans, marker) {
|
| 1633 |
if (spans) { for (var i = 0; i < spans.length; ++i) {
|
| 1634 |
-
var span = spans[i]
|
| 1635 |
if (span.marker == marker) { return span }
|
| 1636 |
} }
|
| 1637 |
}
|
| 1638 |
// Remove a span from an array, returning undefined if no spans are
|
| 1639 |
// left (we don't store arrays for lines without spans).
|
| 1640 |
function removeMarkedSpan(spans, span) {
|
| 1641 |
-
var r
|
| 1642 |
for (var i = 0; i < spans.length; ++i)
|
| 1643 |
-
{ if (spans[i] != span) { (r || (r = [])).push(spans[i]) } }
|
| 1644 |
return r
|
| 1645 |
}
|
| 1646 |
// Add a span to a line.
|
| 1647 |
function addMarkedSpan(line, span) {
|
| 1648 |
-
line.markedSpans = line.markedSpans ? line.markedSpans.concat([span]) : [span]
|
| 1649 |
-
span.marker.attachLine(line)
|
| 1650 |
}
|
| 1651 |
|
| 1652 |
// Used for the algorithm that adjusts markers for a change in the
|
|
@@ -1654,26 +1664,24 @@ webpackJsonp([2],{
|
|
| 1654 |
// character position, returning an array of remaining chunks (or
|
| 1655 |
// undefined if nothing remains).
|
| 1656 |
function markedSpansBefore(old, startCh, isInsert) {
|
| 1657 |
-
var nw
|
| 1658 |
if (old) { for (var i = 0; i < old.length; ++i) {
|
| 1659 |
-
var span = old[i], marker = span.marker
|
| 1660 |
-
var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= startCh : span.from < startCh)
|
| 1661 |
if (startsBefore || span.from == startCh && marker.type == "bookmark" && (!isInsert || !span.marker.insertLeft)) {
|
| 1662 |
-
var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= startCh : span.to > startCh)
|
| 1663 |
-
;(nw || (nw = [])).push(new MarkedSpan(marker, span.from, endsAfter ? null : span.to))
|
| 1664 |
}
|
| 1665 |
} }
|
| 1666 |
return nw
|
| 1667 |
}
|
| 1668 |
function markedSpansAfter(old, endCh, isInsert) {
|
| 1669 |
-
var nw
|
| 1670 |
if (old) { for (var i = 0; i < old.length; ++i) {
|
| 1671 |
-
var span = old[i], marker = span.marker
|
| 1672 |
-
var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= endCh : span.to > endCh)
|
| 1673 |
if (endsAfter || span.from == endCh && marker.type == "bookmark" && (!isInsert || span.marker.insertLeft)) {
|
| 1674 |
-
var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= endCh : span.from < endCh)
|
| 1675 |
-
|
| 1676 |
-
span.to == null ? null : span.to - endCh))
|
| 1677 |
}
|
| 1678 |
} }
|
| 1679 |
return nw
|
|
@@ -1687,60 +1695,60 @@ webpackJsonp([2],{
|
|
| 1687 |
// arrays with one element for each line in (after) the change.
|
| 1688 |
function stretchSpansOverChange(doc, change) {
|
| 1689 |
if (change.full) { return null }
|
| 1690 |
-
var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans
|
| 1691 |
-
var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans
|
| 1692 |
if (!oldFirst && !oldLast) { return null }
|
| 1693 |
|
| 1694 |
-
var startCh = change.from.ch, endCh = change.to.ch, isInsert = cmp(change.from, change.to) == 0
|
| 1695 |
// Get the spans that 'stick out' on both sides
|
| 1696 |
-
var first = markedSpansBefore(oldFirst, startCh, isInsert)
|
| 1697 |
-
var last = markedSpansAfter(oldLast, endCh, isInsert)
|
| 1698 |
|
| 1699 |
// Next, merge those two ends
|
| 1700 |
-
var sameLine = change.text.length == 1, offset = lst(change.text).length + (sameLine ? startCh : 0)
|
| 1701 |
if (first) {
|
| 1702 |
// Fix up .to properties of first
|
| 1703 |
for (var i = 0; i < first.length; ++i) {
|
| 1704 |
-
var span = first[i]
|
| 1705 |
if (span.to == null) {
|
| 1706 |
-
var found = getMarkedSpanFor(last, span.marker)
|
| 1707 |
-
if (!found) { span.to = startCh }
|
| 1708 |
-
else if (sameLine) { span.to = found.to == null ? null : found.to + offset }
|
| 1709 |
}
|
| 1710 |
}
|
| 1711 |
}
|
| 1712 |
if (last) {
|
| 1713 |
// Fix up .from in last (or move them into first in case of sameLine)
|
| 1714 |
for (var i$1 = 0; i$1 < last.length; ++i$1) {
|
| 1715 |
-
var span$1 = last[i$1]
|
| 1716 |
-
if (span$1.to != null) { span$1.to += offset }
|
| 1717 |
if (span$1.from == null) {
|
| 1718 |
-
var found$1 = getMarkedSpanFor(first, span$1.marker)
|
| 1719 |
if (!found$1) {
|
| 1720 |
-
span$1.from = offset
|
| 1721 |
-
if (sameLine) { (first || (first = [])).push(span$1) }
|
| 1722 |
}
|
| 1723 |
} else {
|
| 1724 |
-
span$1.from += offset
|
| 1725 |
-
if (sameLine) { (first || (first = [])).push(span$1) }
|
| 1726 |
}
|
| 1727 |
}
|
| 1728 |
}
|
| 1729 |
// Make sure we didn't create any zero-length spans
|
| 1730 |
-
if (first) { first = clearEmptySpans(first) }
|
| 1731 |
-
if (last && last != first) { last = clearEmptySpans(last) }
|
| 1732 |
|
| 1733 |
-
var newMarkers = [first]
|
| 1734 |
if (!sameLine) {
|
| 1735 |
// Fill gap with whole-line-spans
|
| 1736 |
-
var gap = change.text.length - 2, gapMarkers
|
| 1737 |
if (gap > 0 && first)
|
| 1738 |
{ for (var i$2 = 0; i$2 < first.length; ++i$2)
|
| 1739 |
{ if (first[i$2].to == null)
|
| 1740 |
-
{ (gapMarkers || (gapMarkers = [])).push(new MarkedSpan(first[i$2].marker, null, null)) } } }
|
| 1741 |
for (var i$3 = 0; i$3 < gap; ++i$3)
|
| 1742 |
-
{ newMarkers.push(gapMarkers) }
|
| 1743 |
-
newMarkers.push(last)
|
| 1744 |
}
|
| 1745 |
return newMarkers
|
| 1746 |
}
|
|
@@ -1749,9 +1757,9 @@ webpackJsonp([2],{
|
|
| 1749 |
// option of false.
|
| 1750 |
function clearEmptySpans(spans) {
|
| 1751 |
for (var i = 0; i < spans.length; ++i) {
|
| 1752 |
-
var span = spans[i]
|
| 1753 |
if (span.from != null && span.from == span.to && span.marker.clearWhenEmpty !== false)
|
| 1754 |
-
{ spans.splice(i--, 1) }
|
| 1755 |
}
|
| 1756 |
if (!spans.length) { return null }
|
| 1757 |
return spans
|
|
@@ -1759,28 +1767,28 @@ webpackJsonp([2],{
|
|
| 1759 |
|
| 1760 |
// Used to 'clip' out readOnly ranges when making a change.
|
| 1761 |
function removeReadOnlyRanges(doc, from, to) {
|
| 1762 |
-
var markers = null
|
| 1763 |
doc.iter(from.line, to.line + 1, function (line) {
|
| 1764 |
if (line.markedSpans) { for (var i = 0; i < line.markedSpans.length; ++i) {
|
| 1765 |
-
var mark = line.markedSpans[i].marker
|
| 1766 |
if (mark.readOnly && (!markers || indexOf(markers, mark) == -1))
|
| 1767 |
-
{ (markers || (markers = [])).push(mark) }
|
| 1768 |
} }
|
| 1769 |
-
})
|
| 1770 |
if (!markers) { return null }
|
| 1771 |
-
var parts = [{from: from, to: to}]
|
| 1772 |
for (var i = 0; i < markers.length; ++i) {
|
| 1773 |
-
var mk = markers[i], m = mk.find(0)
|
| 1774 |
for (var j = 0; j < parts.length; ++j) {
|
| 1775 |
-
var p = parts[j]
|
| 1776 |
if (cmp(p.to, m.from) < 0 || cmp(p.from, m.to) > 0) { continue }
|
| 1777 |
-
var newParts = [j, 1], dfrom = cmp(p.from, m.from), dto = cmp(p.to, m.to)
|
| 1778 |
if (dfrom < 0 || !mk.inclusiveLeft && !dfrom)
|
| 1779 |
-
{ newParts.push({from: p.from, to: m.from}) }
|
| 1780 |
if (dto > 0 || !mk.inclusiveRight && !dto)
|
| 1781 |
-
{ newParts.push({from: m.to, to: p.to}) }
|
| 1782 |
-
parts.splice.apply(parts, newParts)
|
| 1783 |
-
j += newParts.length - 3
|
| 1784 |
}
|
| 1785 |
}
|
| 1786 |
return parts
|
|
@@ -1788,17 +1796,17 @@ webpackJsonp([2],{
|
|
| 1788 |
|
| 1789 |
// Connect or disconnect spans from a line.
|
| 1790 |
function detachMarkedSpans(line) {
|
| 1791 |
-
var spans = line.markedSpans
|
| 1792 |
if (!spans) { return }
|
| 1793 |
for (var i = 0; i < spans.length; ++i)
|
| 1794 |
-
{ spans[i].marker.detachLine(line) }
|
| 1795 |
-
line.markedSpans = null
|
| 1796 |
}
|
| 1797 |
function attachMarkedSpans(line, spans) {
|
| 1798 |
if (!spans) { return }
|
| 1799 |
for (var i = 0; i < spans.length; ++i)
|
| 1800 |
-
{ spans[i].marker.attachLine(line) }
|
| 1801 |
-
line.markedSpans = spans
|
| 1802 |
}
|
| 1803 |
|
| 1804 |
// Helpers used when computing which overlapping collapsed span
|
|
@@ -1810,12 +1818,12 @@ webpackJsonp([2],{
|
|
| 1810 |
// spans is larger (and thus includes the other). Falls back to
|
| 1811 |
// comparing ids when the spans cover exactly the same range.
|
| 1812 |
function compareCollapsedMarkers(a, b) {
|
| 1813 |
-
var lenDiff = a.lines.length - b.lines.length
|
| 1814 |
if (lenDiff != 0) { return lenDiff }
|
| 1815 |
-
var aPos = a.find(), bPos = b.find()
|
| 1816 |
-
var fromCmp = cmp(aPos.from, bPos.from) || extraLeft(a) - extraLeft(b)
|
| 1817 |
if (fromCmp) { return -fromCmp }
|
| 1818 |
-
var toCmp = cmp(aPos.to, bPos.to) || extraRight(a) - extraRight(b)
|
| 1819 |
if (toCmp) { return toCmp }
|
| 1820 |
return b.id - a.id
|
| 1821 |
}
|
|
@@ -1823,12 +1831,12 @@ webpackJsonp([2],{
|
|
| 1823 |
// Find out whether a line ends or starts in a collapsed span. If
|
| 1824 |
// so, return the marker for that span.
|
| 1825 |
function collapsedSpanAtSide(line, start) {
|
| 1826 |
-
var sps = sawCollapsedSpans && line.markedSpans, found
|
| 1827 |
if (sps) { for (var sp = (void 0), i = 0; i < sps.length; ++i) {
|
| 1828 |
-
sp = sps[i]
|
| 1829 |
if (sp.marker.collapsed && (start ? sp.from : sp.to) == null &&
|
| 1830 |
(!found || compareCollapsedMarkers(found, sp.marker) < 0))
|
| 1831 |
-
{ found = sp.marker }
|
| 1832 |
} }
|
| 1833 |
return found
|
| 1834 |
}
|
|
@@ -1838,15 +1846,15 @@ webpackJsonp([2],{
|
|
| 1838 |
// Test whether there exists a collapsed span that partially
|
| 1839 |
// overlaps (covers the start or end, but not both) of a new span.
|
| 1840 |
// Such overlap is not allowed.
|
| 1841 |
-
function conflictingCollapsedRange(doc, lineNo, from, to, marker) {
|
| 1842 |
-
var line = getLine(doc, lineNo)
|
| 1843 |
-
var sps = sawCollapsedSpans && line.markedSpans
|
| 1844 |
if (sps) { for (var i = 0; i < sps.length; ++i) {
|
| 1845 |
-
var sp = sps[i]
|
| 1846 |
if (!sp.marker.collapsed) { continue }
|
| 1847 |
-
var found = sp.marker.find(0)
|
| 1848 |
-
var fromCmp = cmp(found.from, from) || extraLeft(sp.marker) - extraLeft(marker)
|
| 1849 |
-
var toCmp = cmp(found.to, to) || extraRight(sp.marker) - extraRight(marker)
|
| 1850 |
if (fromCmp >= 0 && toCmp <= 0 || fromCmp <= 0 && toCmp >= 0) { continue }
|
| 1851 |
if (fromCmp <= 0 && (sp.marker.inclusiveRight && marker.inclusiveLeft ? cmp(found.to, from) >= 0 : cmp(found.to, from) > 0) ||
|
| 1852 |
fromCmp >= 0 && (sp.marker.inclusiveRight && marker.inclusiveLeft ? cmp(found.from, to) <= 0 : cmp(found.from, to) < 0))
|
|
@@ -1859,26 +1867,26 @@ webpackJsonp([2],{
|
|
| 1859 |
// visual line. This finds the start of the visual line that the
|
| 1860 |
// given line is part of (usually that is the line itself).
|
| 1861 |
function visualLine(line) {
|
| 1862 |
-
var merged
|
| 1863 |
while (merged = collapsedSpanAtStart(line))
|
| 1864 |
-
{ line = merged.find(-1, true).line }
|
| 1865 |
return line
|
| 1866 |
}
|
| 1867 |
|
| 1868 |
function visualLineEnd(line) {
|
| 1869 |
-
var merged
|
| 1870 |
while (merged = collapsedSpanAtEnd(line))
|
| 1871 |
-
{ line = merged.find(1, true).line }
|
| 1872 |
return line
|
| 1873 |
}
|
| 1874 |
|
| 1875 |
// Returns an array of logical lines that continue the visual line
|
| 1876 |
// started by the argument, or undefined if there are no such lines.
|
| 1877 |
function visualLineContinued(line) {
|
| 1878 |
-
var merged, lines
|
| 1879 |
while (merged = collapsedSpanAtEnd(line)) {
|
| 1880 |
line = merged.find(1, true).line
|
| 1881 |
-
;(lines || (lines = [])).push(line)
|
| 1882 |
}
|
| 1883 |
return lines
|
| 1884 |
}
|
|
@@ -1886,7 +1894,7 @@ webpackJsonp([2],{
|
|
| 1886 |
// Get the line number of the start of the visual line that the
|
| 1887 |
// given line number is part of.
|
| 1888 |
function visualLineNo(doc, lineN) {
|
| 1889 |
-
var line = getLine(doc, lineN), vis = visualLine(line)
|
| 1890 |
if (line == vis) { return lineN }
|
| 1891 |
return lineNo(vis)
|
| 1892 |
}
|
|
@@ -1895,10 +1903,10 @@ webpackJsonp([2],{
|
|
| 1895 |
// the given line.
|
| 1896 |
function visualLineEndNo(doc, lineN) {
|
| 1897 |
if (lineN > doc.lastLine()) { return lineN }
|
| 1898 |
-
var line = getLine(doc, lineN), merged
|
| 1899 |
if (!lineIsHidden(doc, line)) { return lineN }
|
| 1900 |
while (merged = collapsedSpanAtEnd(line))
|
| 1901 |
-
{ line = merged.find(1, true).line }
|
| 1902 |
return lineNo(line) + 1
|
| 1903 |
}
|
| 1904 |
|
|
@@ -1906,9 +1914,9 @@ webpackJsonp([2],{
|
|
| 1906 |
// are part of a visual line that starts with another line, or when
|
| 1907 |
// they are entirely covered by collapsed, non-widget span.
|
| 1908 |
function lineIsHidden(doc, line) {
|
| 1909 |
-
var sps = sawCollapsedSpans && line.markedSpans
|
| 1910 |
if (sps) { for (var sp = (void 0), i = 0; i < sps.length; ++i) {
|
| 1911 |
-
sp = sps[i]
|
| 1912 |
if (!sp.marker.collapsed) { continue }
|
| 1913 |
if (sp.from == null) { return true }
|
| 1914 |
if (sp.marker.widgetNode) { continue }
|
|
@@ -1918,13 +1926,13 @@ webpackJsonp([2],{
|
|
| 1918 |
}
|
| 1919 |
function lineIsHiddenInner(doc, line, span) {
|
| 1920 |
if (span.to == null) {
|
| 1921 |
-
var end = span.marker.find(1, true)
|
| 1922 |
return lineIsHiddenInner(doc, end.line, getMarkedSpanFor(end.line.markedSpans, span.marker))
|
| 1923 |
}
|
| 1924 |
if (span.marker.inclusiveRight && span.to == line.text.length)
|
| 1925 |
{ return true }
|
| 1926 |
for (var sp = (void 0), i = 0; i < line.markedSpans.length; ++i) {
|
| 1927 |
-
sp = line.markedSpans[i]
|
| 1928 |
if (sp.marker.collapsed && !sp.marker.widgetNode && sp.from == span.to &&
|
| 1929 |
(sp.to == null || sp.to != span.from) &&
|
| 1930 |
(sp.marker.inclusiveLeft || span.marker.inclusiveRight) &&
|
|
@@ -1934,19 +1942,19 @@ webpackJsonp([2],{
|
|
| 1934 |
|
| 1935 |
// Find the height above the given line.
|
| 1936 |
function heightAtLine(lineObj) {
|
| 1937 |
-
lineObj = visualLine(lineObj)
|
| 1938 |
|
| 1939 |
-
var h = 0, chunk = lineObj.parent
|
| 1940 |
for (var i = 0; i < chunk.lines.length; ++i) {
|
| 1941 |
-
var line = chunk.lines[i]
|
| 1942 |
if (line == lineObj) { break }
|
| 1943 |
-
else { h += line.height }
|
| 1944 |
}
|
| 1945 |
for (var p = chunk.parent; p; chunk = p, p = chunk.parent) {
|
| 1946 |
for (var i$1 = 0; i$1 < p.children.length; ++i$1) {
|
| 1947 |
-
var cur = p.children[i$1]
|
| 1948 |
if (cur == chunk) { break }
|
| 1949 |
-
else { h += cur.height }
|
| 1950 |
}
|
| 1951 |
}
|
| 1952 |
return h
|
|
@@ -1957,66 +1965,66 @@ webpackJsonp([2],{
|
|
| 1957 |
// other lines onto it.
|
| 1958 |
function lineLength(line) {
|
| 1959 |
if (line.height == 0) { return 0 }
|
| 1960 |
-
var len = line.text.length, merged, cur = line
|
| 1961 |
while (merged = collapsedSpanAtStart(cur)) {
|
| 1962 |
-
var found = merged.find(0, true)
|
| 1963 |
-
cur = found.from.line
|
| 1964 |
-
len += found.from.ch - found.to.ch
|
| 1965 |
}
|
| 1966 |
-
cur = line
|
| 1967 |
while (merged = collapsedSpanAtEnd(cur)) {
|
| 1968 |
-
var found$1 = merged.find(0, true)
|
| 1969 |
-
len -= cur.text.length - found$1.from.ch
|
| 1970 |
-
cur = found$1.to.line
|
| 1971 |
-
len += cur.text.length - found$1.to.ch
|
| 1972 |
}
|
| 1973 |
return len
|
| 1974 |
}
|
| 1975 |
|
| 1976 |
// Find the longest line in the document.
|
| 1977 |
function findMaxLine(cm) {
|
| 1978 |
-
var d = cm.display, doc = cm.doc
|
| 1979 |
-
d.maxLine = getLine(doc, doc.first)
|
| 1980 |
-
d.maxLineLength = lineLength(d.maxLine)
|
| 1981 |
-
d.maxLineChanged = true
|
| 1982 |
doc.iter(function (line) {
|
| 1983 |
-
var len = lineLength(line)
|
| 1984 |
if (len > d.maxLineLength) {
|
| 1985 |
-
d.maxLineLength = len
|
| 1986 |
-
d.maxLine = line
|
| 1987 |
}
|
| 1988 |
-
})
|
| 1989 |
}
|
| 1990 |
|
| 1991 |
// BIDI HELPERS
|
| 1992 |
|
| 1993 |
function iterateBidiSections(order, from, to, f) {
|
| 1994 |
if (!order) { return f(from, to, "ltr") }
|
| 1995 |
-
var found = false
|
| 1996 |
for (var i = 0; i < order.length; ++i) {
|
| 1997 |
-
var part = order[i]
|
| 1998 |
if (part.from < to && part.to > from || from == to && part.to == from) {
|
| 1999 |
-
f(Math.max(part.from, from), Math.min(part.to, to), part.level == 1 ? "rtl" : "ltr")
|
| 2000 |
-
found = true
|
| 2001 |
}
|
| 2002 |
}
|
| 2003 |
-
if (!found) { f(from, to, "ltr") }
|
| 2004 |
}
|
| 2005 |
|
| 2006 |
-
var bidiOther = null
|
| 2007 |
function getBidiPartAt(order, ch, sticky) {
|
| 2008 |
-
var found
|
| 2009 |
-
bidiOther = null
|
| 2010 |
for (var i = 0; i < order.length; ++i) {
|
| 2011 |
-
var cur = order[i]
|
| 2012 |
if (cur.from < ch && cur.to > ch) { return i }
|
| 2013 |
if (cur.to == ch) {
|
| 2014 |
-
if (cur.from != cur.to && sticky == "before") { found = i }
|
| 2015 |
-
else { bidiOther = i }
|
| 2016 |
}
|
| 2017 |
if (cur.from == ch) {
|
| 2018 |
-
if (cur.from != cur.to && sticky != "before") { found = i }
|
| 2019 |
-
else { bidiOther = i }
|
| 2020 |
}
|
| 2021 |
}
|
| 2022 |
return found != null ? found : bidiOther
|
|
@@ -2047,9 +2055,9 @@ webpackJsonp([2],{
|
|
| 2047 |
// objects) in the order in which they occur visually.
|
| 2048 |
var bidiOrdering = (function() {
|
| 2049 |
// Character types for codepoints 0 to 0xff
|
| 2050 |
-
var lowTypes = "bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN"
|
| 2051 |
// Character types for codepoints 0x600 to 0x6f9
|
| 2052 |
-
var arabicTypes = "nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111"
|
| 2053 |
function charType(code) {
|
| 2054 |
if (code <= 0xf7) { return lowTypes.charAt(code) }
|
| 2055 |
else if (0x590 <= code && code <= 0x5f4) { return "R" }
|
|
@@ -2060,30 +2068,30 @@ webpackJsonp([2],{
|
|
| 2060 |
else { return "L" }
|
| 2061 |
}
|
| 2062 |
|
| 2063 |
-
var bidiRE = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]
|
| 2064 |
-
var isNeutral = /[stwN]/, isStrong = /[LRr]/, countsAsLeft = /[Lb1n]/, countsAsNum = /[1n]
|
| 2065 |
-
// Browsers seem to always treat the boundaries of block elements as being L.
|
| 2066 |
-
var outerType = "L"
|
| 2067 |
|
| 2068 |
function BidiSpan(level, from, to) {
|
| 2069 |
-
this.level = level
|
| 2070 |
-
this.from = from; this.to = to
|
| 2071 |
}
|
| 2072 |
|
| 2073 |
-
return function(str) {
|
| 2074 |
-
|
| 2075 |
-
|
|
|
|
|
|
|
| 2076 |
for (var i = 0; i < len; ++i)
|
| 2077 |
-
{ types.push(charType(str.charCodeAt(i))) }
|
| 2078 |
|
| 2079 |
// W1. Examine each non-spacing mark (NSM) in the level run, and
|
| 2080 |
// change the type of the NSM to the type of the previous
|
| 2081 |
// character. If the NSM is at the start of the level run, it will
|
| 2082 |
// get the type of sor.
|
| 2083 |
for (var i$1 = 0, prev = outerType; i$1 < len; ++i$1) {
|
| 2084 |
-
var type = types[i$1]
|
| 2085 |
-
if (type == "m") { types[i$1] = prev }
|
| 2086 |
-
else { prev = type }
|
| 2087 |
}
|
| 2088 |
|
| 2089 |
// W2. Search backwards from each instance of a European number
|
|
@@ -2092,20 +2100,20 @@ webpackJsonp([2],{
|
|
| 2092 |
// number.
|
| 2093 |
// W3. Change all ALs to R.
|
| 2094 |
for (var i$2 = 0, cur = outerType; i$2 < len; ++i$2) {
|
| 2095 |
-
var type$1 = types[i$2]
|
| 2096 |
-
if (type$1 == "1" && cur == "r") { types[i$2] = "n" }
|
| 2097 |
-
else if (isStrong.test(type$1)) { cur = type$1; if (type$1 == "r") { types[i$2] = "R" } }
|
| 2098 |
}
|
| 2099 |
|
| 2100 |
// W4. A single European separator between two European numbers
|
| 2101 |
// changes to a European number. A single common separator between
|
| 2102 |
// two numbers of the same type changes to that type.
|
| 2103 |
for (var i$3 = 1, prev$1 = types[0]; i$3 < len - 1; ++i$3) {
|
| 2104 |
-
var type$2 = types[i$3]
|
| 2105 |
-
if (type$2 == "+" && prev$1 == "1" && types[i$3+1] == "1") { types[i$3] = "1" }
|
| 2106 |
else if (type$2 == "," && prev$1 == types[i$3+1] &&
|
| 2107 |
-
(prev$1 == "1" || prev$1 == "n")) { types[i$3] = prev$1 }
|
| 2108 |
-
prev$1 = type$2
|
| 2109 |
}
|
| 2110 |
|
| 2111 |
// W5. A sequence of European terminators adjacent to European
|
|
@@ -2113,14 +2121,14 @@ webpackJsonp([2],{
|
|
| 2113 |
// W6. Otherwise, separators and terminators change to Other
|
| 2114 |
// Neutral.
|
| 2115 |
for (var i$4 = 0; i$4 < len; ++i$4) {
|
| 2116 |
-
var type$3 = types[i$4]
|
| 2117 |
-
if (type$3 == ",") { types[i$4] = "N" }
|
| 2118 |
else if (type$3 == "%") {
|
| 2119 |
-
var end = (void 0)
|
| 2120 |
for (end = i$4 + 1; end < len && types[end] == "%"; ++end) {}
|
| 2121 |
-
var replace = (i$4 && types[i$4-1] == "!") || (end < len && types[end] == "1") ? "1" : "N"
|
| 2122 |
-
for (var j = i$4; j < end; ++j) { types[j] = replace }
|
| 2123 |
-
i$4 = end - 1
|
| 2124 |
}
|
| 2125 |
}
|
| 2126 |
|
|
@@ -2128,9 +2136,9 @@ webpackJsonp([2],{
|
|
| 2128 |
// until the first strong type (R, L, or sor) is found. If an L is
|
| 2129 |
// found, then change the type of the European number to L.
|
| 2130 |
for (var i$5 = 0, cur$1 = outerType; i$5 < len; ++i$5) {
|
| 2131 |
-
var type$4 = types[i$5]
|
| 2132 |
-
if (cur$1 == "L" && type$4 == "1") { types[i$5] = "L" }
|
| 2133 |
-
else if (isStrong.test(type$4)) { cur$1 = type$4 }
|
| 2134 |
}
|
| 2135 |
|
| 2136 |
// N1. A sequence of neutrals takes the direction of the
|
|
@@ -2141,13 +2149,13 @@ webpackJsonp([2],{
|
|
| 2141 |
// N2. Any remaining neutrals take the embedding direction.
|
| 2142 |
for (var i$6 = 0; i$6 < len; ++i$6) {
|
| 2143 |
if (isNeutral.test(types[i$6])) {
|
| 2144 |
-
var end$1 = (void 0)
|
| 2145 |
for (end$1 = i$6 + 1; end$1 < len && isNeutral.test(types[end$1]); ++end$1) {}
|
| 2146 |
-
var before = (i$6 ? types[i$6-1] : outerType) == "L"
|
| 2147 |
-
var after = (end$1 < len ? types[end$1] : outerType) == "L"
|
| 2148 |
-
var replace$1 = before
|
| 2149 |
-
for (var j$1 = i$6; j$1 < end$1; ++j$1) { types[j$1] = replace$1 }
|
| 2150 |
-
i$6 = end$1 - 1
|
| 2151 |
}
|
| 2152 |
}
|
| 2153 |
|
|
@@ -2156,67 +2164,67 @@ webpackJsonp([2],{
|
|
| 2156 |
// levels (0, 1, 2) in an implementation that doesn't take
|
| 2157 |
// explicit embedding into account, we can build up the order on
|
| 2158 |
// the fly, without following the level-based algorithm.
|
| 2159 |
-
var order = [], m
|
| 2160 |
for (var i$7 = 0; i$7 < len;) {
|
| 2161 |
if (countsAsLeft.test(types[i$7])) {
|
| 2162 |
-
var start = i$7
|
| 2163 |
for (++i$7; i$7 < len && countsAsLeft.test(types[i$7]); ++i$7) {}
|
| 2164 |
-
order.push(new BidiSpan(0, start, i$7))
|
| 2165 |
} else {
|
| 2166 |
-
var pos = i$7, at = order.length
|
| 2167 |
for (++i$7; i$7 < len && types[i$7] != "L"; ++i$7) {}
|
| 2168 |
for (var j$2 = pos; j$2 < i$7;) {
|
| 2169 |
if (countsAsNum.test(types[j$2])) {
|
| 2170 |
-
if (pos < j$2) { order.splice(at, 0, new BidiSpan(1, pos, j$2)) }
|
| 2171 |
-
var nstart = j$2
|
| 2172 |
for (++j$2; j$2 < i$7 && countsAsNum.test(types[j$2]); ++j$2) {}
|
| 2173 |
-
order.splice(at, 0, new BidiSpan(2, nstart, j$2))
|
| 2174 |
-
pos = j$2
|
| 2175 |
-
} else { ++j$2 }
|
| 2176 |
}
|
| 2177 |
-
if (pos < i$7) { order.splice(at, 0, new BidiSpan(1, pos, i$7)) }
|
| 2178 |
}
|
| 2179 |
}
|
| 2180 |
if (order[0].level == 1 && (m = str.match(/^\s+/))) {
|
| 2181 |
-
order[0].from = m[0].length
|
| 2182 |
-
order.unshift(new BidiSpan(0, 0, m[0].length))
|
| 2183 |
}
|
| 2184 |
if (lst(order).level == 1 && (m = str.match(/\s+$/))) {
|
| 2185 |
-
lst(order).to -= m[0].length
|
| 2186 |
-
order.push(new BidiSpan(0, len - m[0].length, len))
|
| 2187 |
}
|
| 2188 |
|
| 2189 |
-
return order
|
| 2190 |
}
|
| 2191 |
-
})()
|
| 2192 |
|
| 2193 |
// Get the bidi ordering for the given line (and cache it). Returns
|
| 2194 |
// false for lines that are fully left-to-right, and an array of
|
| 2195 |
// BidiSpan objects otherwise.
|
| 2196 |
-
function getOrder(line) {
|
| 2197 |
-
var order = line.order
|
| 2198 |
-
if (order == null) { order = line.order = bidiOrdering(line.text) }
|
| 2199 |
return order
|
| 2200 |
}
|
| 2201 |
|
| 2202 |
function moveCharLogically(line, ch, dir) {
|
| 2203 |
-
var target = skipExtendingChars(line.text, ch + dir, dir)
|
| 2204 |
return target < 0 || target > line.text.length ? null : target
|
| 2205 |
}
|
| 2206 |
|
| 2207 |
function moveLogically(line, start, dir) {
|
| 2208 |
-
var ch = moveCharLogically(line, start.ch, dir)
|
| 2209 |
return ch == null ? null : new Pos(start.line, ch, dir < 0 ? "after" : "before")
|
| 2210 |
}
|
| 2211 |
|
| 2212 |
function endOfLine(visually, cm, lineObj, lineNo, dir) {
|
| 2213 |
if (visually) {
|
| 2214 |
-
var order = getOrder(lineObj)
|
| 2215 |
if (order) {
|
| 2216 |
-
var part = dir < 0 ? lst(order) : order[0]
|
| 2217 |
-
var moveInStorageOrder = (dir < 0) == (part.level == 1)
|
| 2218 |
-
var sticky = moveInStorageOrder ? "after" : "before"
|
| 2219 |
-
var ch
|
| 2220 |
// With a wrapped rtl chunk (possibly spanning multiple bidi parts),
|
| 2221 |
// it could be that the last bidi part is not on the last visual line,
|
| 2222 |
// since visual lines contain content order-consecutive chunks.
|
|
@@ -2224,12 +2232,12 @@ webpackJsonp([2],{
|
|
| 2224 |
// in the rtl chunk that is on the last line (that is, the same line
|
| 2225 |
// as the last (content-order) character).
|
| 2226 |
if (part.level > 0) {
|
| 2227 |
-
var prep = prepareMeasureForLine(cm, lineObj)
|
| 2228 |
-
ch = dir < 0 ? lineObj.text.length - 1 : 0
|
| 2229 |
-
var targetTop = measureCharPrepared(cm, prep, ch).top
|
| 2230 |
-
ch = findFirst(function (ch) { return measureCharPrepared(cm, prep, ch).top == targetTop; }, (dir < 0) == (part.level == 1) ? part.from : part.to - 1, ch)
|
| 2231 |
-
if (sticky == "before") { ch = moveCharLogically(lineObj, ch, 1, true) }
|
| 2232 |
-
} else { ch = dir < 0 ? part.to : part.from }
|
| 2233 |
return new Pos(lineNo, ch, sticky)
|
| 2234 |
}
|
| 2235 |
}
|
|
@@ -2237,36 +2245,37 @@ webpackJsonp([2],{
|
|
| 2237 |
}
|
| 2238 |
|
| 2239 |
function moveVisually(cm, line, start, dir) {
|
| 2240 |
-
var bidi = getOrder(line)
|
| 2241 |
if (!bidi) { return moveLogically(line, start, dir) }
|
| 2242 |
if (start.ch >= line.text.length) {
|
| 2243 |
-
start.ch = line.text.length
|
| 2244 |
-
start.sticky = "before"
|
| 2245 |
} else if (start.ch <= 0) {
|
| 2246 |
-
start.ch = 0
|
| 2247 |
-
start.sticky = "after"
|
| 2248 |
}
|
| 2249 |
-
var partPos = getBidiPartAt(bidi, start.ch, start.sticky), part = bidi[partPos]
|
| 2250 |
-
if (part.level % 2 == 0 && (dir > 0 ? part.to > start.ch : part.from < start.ch)) {
|
| 2251 |
-
// Case 1: We move within an ltr part. Even with wrapped lines,
|
| 2252 |
// nothing interesting happens.
|
| 2253 |
return moveLogically(line, start, dir)
|
| 2254 |
}
|
| 2255 |
|
| 2256 |
-
var mv = function (pos, dir) { return moveCharLogically(line, pos instanceof Pos ? pos.ch : pos, dir); }
|
| 2257 |
-
var prep
|
| 2258 |
var getWrappedLineExtent = function (ch) {
|
| 2259 |
if (!cm.options.lineWrapping) { return {begin: 0, end: line.text.length} }
|
| 2260 |
-
prep = prep || prepareMeasureForLine(cm, line)
|
| 2261 |
return wrappedLineExtentChar(cm, line, prep, ch)
|
| 2262 |
-
}
|
| 2263 |
-
var wrappedLineExtent = getWrappedLineExtent(start.sticky == "before" ? mv(start, -1) : start.ch)
|
| 2264 |
-
|
| 2265 |
-
if (part.level
|
| 2266 |
-
var
|
| 2267 |
-
|
| 2268 |
-
|
| 2269 |
-
|
|
|
|
| 2270 |
return new Pos(start.line, ch, sticky)
|
| 2271 |
}
|
| 2272 |
}
|
|
@@ -2277,26 +2286,26 @@ webpackJsonp([2],{
|
|
| 2277 |
var searchInVisualLine = function (partPos, dir, wrappedLineExtent) {
|
| 2278 |
var getRes = function (ch, moveInStorageOrder) { return moveInStorageOrder
|
| 2279 |
? new Pos(start.line, mv(ch, 1), "before")
|
| 2280 |
-
: new Pos(start.line, ch, "after"); }
|
| 2281 |
|
| 2282 |
for (; partPos >= 0 && partPos < bidi.length; partPos += dir) {
|
| 2283 |
-
var part = bidi[partPos]
|
| 2284 |
-
var moveInStorageOrder = (dir > 0) == (part.level != 1)
|
| 2285 |
-
var ch = moveInStorageOrder ? wrappedLineExtent.begin : mv(wrappedLineExtent.end, -1)
|
| 2286 |
if (part.from <= ch && ch < part.to) { return getRes(ch, moveInStorageOrder) }
|
| 2287 |
-
ch = moveInStorageOrder ? part.from : mv(part.to, -1)
|
| 2288 |
if (wrappedLineExtent.begin <= ch && ch < wrappedLineExtent.end) { return getRes(ch, moveInStorageOrder) }
|
| 2289 |
}
|
| 2290 |
-
}
|
| 2291 |
|
| 2292 |
// Case 3a: Look for other bidi parts on the same visual line
|
| 2293 |
-
var res = searchInVisualLine(partPos + dir, dir, wrappedLineExtent)
|
| 2294 |
if (res) { return res }
|
| 2295 |
|
| 2296 |
// Case 3b: Look for other bidi parts on the next visual line
|
| 2297 |
-
var nextCh = dir > 0 ? wrappedLineExtent.end : mv(wrappedLineExtent.begin, -1)
|
| 2298 |
if (nextCh != null && !(dir > 0 && nextCh == line.text.length)) {
|
| 2299 |
-
res = searchInVisualLine(dir > 0 ? 0 : bidi.length - 1, dir, getWrappedLineExtent(nextCh))
|
| 2300 |
if (res) { return res }
|
| 2301 |
}
|
| 2302 |
|
|
@@ -2309,18 +2318,18 @@ webpackJsonp([2],{
|
|
| 2309 |
// Lightweight event framework. on/off also work on DOM nodes,
|
| 2310 |
// registering native DOM handlers.
|
| 2311 |
|
| 2312 |
-
var noHandlers = []
|
| 2313 |
|
| 2314 |
var on = function(emitter, type, f) {
|
| 2315 |
if (emitter.addEventListener) {
|
| 2316 |
-
emitter.addEventListener(type, f, false)
|
| 2317 |
} else if (emitter.attachEvent) {
|
| 2318 |
-
emitter.attachEvent("on" + type, f)
|
| 2319 |
} else {
|
| 2320 |
-
var map = emitter._handlers || (emitter._handlers = {})
|
| 2321 |
-
map[type] = (map[type] || noHandlers).concat(f)
|
| 2322 |
}
|
| 2323 |
-
}
|
| 2324 |
|
| 2325 |
function getHandlers(emitter, type) {
|
| 2326 |
return emitter._handlers && emitter._handlers[type] || noHandlers
|
|
@@ -2328,24 +2337,24 @@ webpackJsonp([2],{
|
|
| 2328 |
|
| 2329 |
function off(emitter, type, f) {
|
| 2330 |
if (emitter.removeEventListener) {
|
| 2331 |
-
emitter.removeEventListener(type, f, false)
|
| 2332 |
} else if (emitter.detachEvent) {
|
| 2333 |
-
emitter.detachEvent("on" + type, f)
|
| 2334 |
} else {
|
| 2335 |
-
var map = emitter._handlers, arr = map && map[type]
|
| 2336 |
if (arr) {
|
| 2337 |
-
var index = indexOf(arr, f)
|
| 2338 |
if (index > -1)
|
| 2339 |
-
{ map[type] = arr.slice(0, index).concat(arr.slice(index + 1)) }
|
| 2340 |
}
|
| 2341 |
}
|
| 2342 |
}
|
| 2343 |
|
| 2344 |
function signal(emitter, type /*, values...*/) {
|
| 2345 |
-
var handlers = getHandlers(emitter, type)
|
| 2346 |
if (!handlers.length) { return }
|
| 2347 |
-
var args = Array.prototype.slice.call(arguments, 2)
|
| 2348 |
-
for (var i = 0; i < handlers.length; ++i) { handlers[i].apply(null, args) }
|
| 2349 |
}
|
| 2350 |
|
| 2351 |
// The DOM events that CodeMirror handles can be overridden by
|
|
@@ -2353,17 +2362,17 @@ webpackJsonp([2],{
|
|
| 2353 |
// and preventDefault-ing the event in that handler.
|
| 2354 |
function signalDOMEvent(cm, e, override) {
|
| 2355 |
if (typeof e == "string")
|
| 2356 |
-
{ e = {type: e, preventDefault: function() { this.defaultPrevented = true }} }
|
| 2357 |
-
signal(cm, override || e.type, cm, e)
|
| 2358 |
return e_defaultPrevented(e) || e.codemirrorIgnore
|
| 2359 |
}
|
| 2360 |
|
| 2361 |
function signalCursorActivity(cm) {
|
| 2362 |
-
var arr = cm._handlers && cm._handlers.cursorActivity
|
| 2363 |
if (!arr) { return }
|
| 2364 |
-
var set = cm.curOp.cursorActivityHandlers || (cm.curOp.cursorActivityHandlers = [])
|
| 2365 |
for (var i = 0; i < arr.length; ++i) { if (indexOf(set, arr[i]) == -1)
|
| 2366 |
-
{ set.push(arr[i]) } }
|
| 2367 |
}
|
| 2368 |
|
| 2369 |
function hasHandler(emitter, type) {
|
|
@@ -2373,35 +2382,35 @@ webpackJsonp([2],{
|
|
| 2373 |
// Add on and off methods to a constructor's prototype, to make
|
| 2374 |
// registering events on such objects more convenient.
|
| 2375 |
function eventMixin(ctor) {
|
| 2376 |
-
ctor.prototype.on = function(type, f) {on(this, type, f)}
|
| 2377 |
-
ctor.prototype.off = function(type, f) {off(this, type, f)}
|
| 2378 |
}
|
| 2379 |
|
| 2380 |
// Due to the fact that we still support jurassic IE versions, some
|
| 2381 |
// compatibility wrappers are needed.
|
| 2382 |
|
| 2383 |
function e_preventDefault(e) {
|
| 2384 |
-
if (e.preventDefault) { e.preventDefault() }
|
| 2385 |
-
else { e.returnValue = false }
|
| 2386 |
}
|
| 2387 |
function e_stopPropagation(e) {
|
| 2388 |
-
if (e.stopPropagation) { e.stopPropagation() }
|
| 2389 |
-
else { e.cancelBubble = true }
|
| 2390 |
}
|
| 2391 |
function e_defaultPrevented(e) {
|
| 2392 |
return e.defaultPrevented != null ? e.defaultPrevented : e.returnValue == false
|
| 2393 |
}
|
| 2394 |
-
function e_stop(e) {e_preventDefault(e); e_stopPropagation(e)}
|
| 2395 |
|
| 2396 |
function e_target(e) {return e.target || e.srcElement}
|
| 2397 |
function e_button(e) {
|
| 2398 |
-
var b = e.which
|
| 2399 |
if (b == null) {
|
| 2400 |
-
if (e.button & 1) { b = 1 }
|
| 2401 |
-
else if (e.button & 2) { b = 3 }
|
| 2402 |
-
else if (e.button & 4) { b = 2 }
|
| 2403 |
}
|
| 2404 |
-
if (mac && e.ctrlKey && b == 1) { b = 3 }
|
| 2405 |
return b
|
| 2406 |
}
|
| 2407 |
|
|
@@ -2410,32 +2419,32 @@ webpackJsonp([2],{
|
|
| 2410 |
// There is *some* kind of drag-and-drop support in IE6-8, but I
|
| 2411 |
// couldn't get it to work yet.
|
| 2412 |
if (ie && ie_version < 9) { return false }
|
| 2413 |
-
var div = elt('div')
|
| 2414 |
return "draggable" in div || "dragDrop" in div
|
| 2415 |
-
}()
|
| 2416 |
|
| 2417 |
-
var zwspSupported
|
| 2418 |
function zeroWidthElement(measure) {
|
| 2419 |
if (zwspSupported == null) {
|
| 2420 |
-
var test = elt("span", "\u200b")
|
| 2421 |
-
removeChildrenAndAdd(measure, elt("span", [test, document.createTextNode("x")]))
|
| 2422 |
if (measure.firstChild.offsetHeight != 0)
|
| 2423 |
-
{ zwspSupported = test.offsetWidth <= 1 && test.offsetHeight > 2 && !(ie && ie_version < 8) }
|
| 2424 |
}
|
| 2425 |
var node = zwspSupported ? elt("span", "\u200b") :
|
| 2426 |
-
elt("span", "\u00a0", null, "display: inline-block; width: 1px; margin-right: -1px")
|
| 2427 |
-
node.setAttribute("cm-text", "")
|
| 2428 |
return node
|
| 2429 |
}
|
| 2430 |
|
| 2431 |
// Feature-detect IE's crummy client rect reporting for bidi text
|
| 2432 |
-
var badBidiRects
|
| 2433 |
function hasBadBidiRects(measure) {
|
| 2434 |
if (badBidiRects != null) { return badBidiRects }
|
| 2435 |
-
var txt = removeChildrenAndAdd(measure, document.createTextNode("A\u062eA"))
|
| 2436 |
-
var r0 = range(txt, 0, 1).getBoundingClientRect()
|
| 2437 |
-
var r1 = range(txt, 1, 2).getBoundingClientRect()
|
| 2438 |
-
removeChildren(measure)
|
| 2439 |
if (!r0 || r0.left == r0.right) { return false } // Safari returns null in some cases (#2780)
|
| 2440 |
return badBidiRects = (r1.right - r0.right < 3)
|
| 2441 |
}
|
|
@@ -2443,75 +2452,77 @@ webpackJsonp([2],{
|
|
| 2443 |
// See if "".split is the broken IE version, if so, provide an
|
| 2444 |
// alternative way to split lines.
|
| 2445 |
var splitLinesAuto = "\n\nb".split(/\n/).length != 3 ? function (string) {
|
| 2446 |
-
var pos = 0, result = [], l = string.length
|
| 2447 |
while (pos <= l) {
|
| 2448 |
-
var nl = string.indexOf("\n", pos)
|
| 2449 |
-
if (nl == -1) { nl = string.length }
|
| 2450 |
-
var line = string.slice(pos, string.charAt(nl - 1) == "\r" ? nl - 1 : nl)
|
| 2451 |
-
var rt = line.indexOf("\r")
|
| 2452 |
if (rt != -1) {
|
| 2453 |
-
result.push(line.slice(0, rt))
|
| 2454 |
-
pos += rt + 1
|
| 2455 |
} else {
|
| 2456 |
-
result.push(line)
|
| 2457 |
-
pos = nl + 1
|
| 2458 |
}
|
| 2459 |
}
|
| 2460 |
return result
|
| 2461 |
-
} : function (string) { return string.split(/\r\n?|\n/); }
|
| 2462 |
|
| 2463 |
var hasSelection = window.getSelection ? function (te) {
|
| 2464 |
try { return te.selectionStart != te.selectionEnd }
|
| 2465 |
catch(e) { return false }
|
| 2466 |
} : function (te) {
|
| 2467 |
-
var range
|
| 2468 |
-
try {range = te.ownerDocument.selection.createRange()}
|
| 2469 |
catch(e) {}
|
| 2470 |
-
if (!range || range.parentElement() != te) { return false }
|
| 2471 |
-
return range.compareEndPoints("StartToEnd", range) != 0
|
| 2472 |
-
}
|
| 2473 |
|
| 2474 |
var hasCopyEvent = (function () {
|
| 2475 |
-
var e = elt("div")
|
| 2476 |
if ("oncopy" in e) { return true }
|
| 2477 |
-
e.setAttribute("oncopy", "return;")
|
| 2478 |
return typeof e.oncopy == "function"
|
| 2479 |
-
})()
|
| 2480 |
|
| 2481 |
-
var badZoomedRects = null
|
| 2482 |
function hasBadZoomedRects(measure) {
|
| 2483 |
if (badZoomedRects != null) { return badZoomedRects }
|
| 2484 |
-
var node = removeChildrenAndAdd(measure, elt("span", "x"))
|
| 2485 |
-
var normal = node.getBoundingClientRect()
|
| 2486 |
-
var fromRange = range(node, 0, 1).getBoundingClientRect()
|
| 2487 |
return badZoomedRects = Math.abs(normal.left - fromRange.left) > 1
|
| 2488 |
}
|
| 2489 |
|
|
|
|
| 2490 |
var modes = {};
|
| 2491 |
var mimeModes = {};
|
|
|
|
| 2492 |
// Extra arguments are stored as the mode's dependencies, which is
|
| 2493 |
// used by (legacy) mechanisms like loadmode.js to automatically
|
| 2494 |
// load a mode. (Preferred mechanism is the require/define calls.)
|
| 2495 |
function defineMode(name, mode) {
|
| 2496 |
if (arguments.length > 2)
|
| 2497 |
-
{ mode.dependencies = Array.prototype.slice.call(arguments, 2) }
|
| 2498 |
-
modes[name] = mode
|
| 2499 |
}
|
| 2500 |
|
| 2501 |
function defineMIME(mime, spec) {
|
| 2502 |
-
mimeModes[mime] = spec
|
| 2503 |
}
|
| 2504 |
|
| 2505 |
// Given a MIME type, a {name, ...options} config object, or a name
|
| 2506 |
// string, return a mode config object.
|
| 2507 |
function resolveMode(spec) {
|
| 2508 |
if (typeof spec == "string" && mimeModes.hasOwnProperty(spec)) {
|
| 2509 |
-
spec = mimeModes[spec]
|
| 2510 |
} else if (spec && typeof spec.name == "string" && mimeModes.hasOwnProperty(spec.name)) {
|
| 2511 |
-
var found = mimeModes[spec.name]
|
| 2512 |
-
if (typeof found == "string") { found = {name: found} }
|
| 2513 |
-
spec = createObj(found, spec)
|
| 2514 |
-
spec.name = found.name
|
| 2515 |
} else if (typeof spec == "string" && /^[\w\-]+\/[\w\-]+\+xml$/.test(spec)) {
|
| 2516 |
return resolveMode("application/xml")
|
| 2517 |
} else if (typeof spec == "string" && /^[\w\-]+\/[\w\-]+\+json$/.test(spec)) {
|
|
@@ -2524,42 +2535,42 @@ webpackJsonp([2],{
|
|
| 2524 |
// Given a mode spec (anything that resolveMode accepts), find and
|
| 2525 |
// initialize an actual mode object.
|
| 2526 |
function getMode(options, spec) {
|
| 2527 |
-
spec = resolveMode(spec)
|
| 2528 |
-
var mfactory = modes[spec.name]
|
| 2529 |
if (!mfactory) { return getMode(options, "text/plain") }
|
| 2530 |
-
var modeObj = mfactory(options, spec)
|
| 2531 |
if (modeExtensions.hasOwnProperty(spec.name)) {
|
| 2532 |
-
var exts = modeExtensions[spec.name]
|
| 2533 |
for (var prop in exts) {
|
| 2534 |
if (!exts.hasOwnProperty(prop)) { continue }
|
| 2535 |
-
if (modeObj.hasOwnProperty(prop)) { modeObj["_" + prop] = modeObj[prop] }
|
| 2536 |
-
modeObj[prop] = exts[prop]
|
| 2537 |
}
|
| 2538 |
}
|
| 2539 |
-
modeObj.name = spec.name
|
| 2540 |
-
if (spec.helperType) { modeObj.helperType = spec.helperType }
|
| 2541 |
if (spec.modeProps) { for (var prop$1 in spec.modeProps)
|
| 2542 |
-
{ modeObj[prop$1] = spec.modeProps[prop$1] } }
|
| 2543 |
|
| 2544 |
return modeObj
|
| 2545 |
}
|
| 2546 |
|
| 2547 |
// This can be used to attach properties to mode objects from
|
| 2548 |
// outside the actual mode definition.
|
| 2549 |
-
var modeExtensions = {}
|
| 2550 |
function extendMode(mode, properties) {
|
| 2551 |
-
var exts = modeExtensions.hasOwnProperty(mode) ? modeExtensions[mode] : (modeExtensions[mode] = {})
|
| 2552 |
-
copyObj(properties, exts)
|
| 2553 |
}
|
| 2554 |
|
| 2555 |
function copyState(mode, state) {
|
| 2556 |
if (state === true) { return state }
|
| 2557 |
if (mode.copyState) { return mode.copyState(state) }
|
| 2558 |
-
var nstate = {}
|
| 2559 |
for (var n in state) {
|
| 2560 |
-
var val = state[n]
|
| 2561 |
-
if (val instanceof Array) { val = val.concat([]) }
|
| 2562 |
-
nstate[n] = val
|
| 2563 |
}
|
| 2564 |
return nstate
|
| 2565 |
}
|
|
@@ -2567,12 +2578,12 @@ webpackJsonp([2],{
|
|
| 2567 |
// Given a mode and a state (for that mode), find the inner mode and
|
| 2568 |
// state at the position that the state refers to.
|
| 2569 |
function innerMode(mode, state) {
|
| 2570 |
-
var info
|
| 2571 |
while (mode.innerMode) {
|
| 2572 |
-
info = mode.innerMode(state)
|
| 2573 |
if (!info || info.mode == mode) { break }
|
| 2574 |
-
state = info.state
|
| 2575 |
-
mode = info.mode
|
| 2576 |
}
|
| 2577 |
return info || {mode: mode, state: state}
|
| 2578 |
}
|
|
@@ -2587,11 +2598,11 @@ webpackJsonp([2],{
|
|
| 2587 |
// parsers more succinct.
|
| 2588 |
|
| 2589 |
var StringStream = function(string, tabSize) {
|
| 2590 |
-
this.pos = this.start = 0
|
| 2591 |
-
this.string = string
|
| 2592 |
-
this.tabSize = tabSize || 8
|
| 2593 |
-
this.lastColumnPos = this.lastColumnValue = 0
|
| 2594 |
-
this.lineStart = 0
|
| 2595 |
};
|
| 2596 |
|
| 2597 |
StringStream.prototype.eol = function () {return this.pos >= this.string.length};
|
|
@@ -2602,34 +2613,34 @@ webpackJsonp([2],{
|
|
| 2602 |
{ return this.string.charAt(this.pos++) }
|
| 2603 |
};
|
| 2604 |
StringStream.prototype.eat = function (match) {
|
| 2605 |
-
var ch = this.string.charAt(this.pos)
|
| 2606 |
-
var ok
|
| 2607 |
-
if (typeof match == "string") { ok = ch == match }
|
| 2608 |
-
else { ok = ch && (match.test ? match.test(ch) : match(ch)) }
|
| 2609 |
if (ok) {++this.pos; return ch}
|
| 2610 |
};
|
| 2611 |
StringStream.prototype.eatWhile = function (match) {
|
| 2612 |
-
var start = this.pos
|
| 2613 |
while (this.eat(match)){}
|
| 2614 |
return this.pos > start
|
| 2615 |
};
|
| 2616 |
StringStream.prototype.eatSpace = function () {
|
| 2617 |
var this$1 = this;
|
| 2618 |
|
| 2619 |
-
var start = this.pos
|
| 2620 |
-
while (/[\s\u00a0]/.test(this.string.charAt(this.pos))) { ++this$1.pos }
|
| 2621 |
return this.pos > start
|
| 2622 |
};
|
| 2623 |
-
StringStream.prototype.skipToEnd = function () {this.pos = this.string.length};
|
| 2624 |
StringStream.prototype.skipTo = function (ch) {
|
| 2625 |
-
var found = this.string.indexOf(ch, this.pos)
|
| 2626 |
if (found > -1) {this.pos = found; return true}
|
| 2627 |
};
|
| 2628 |
-
StringStream.prototype.backUp = function (n) {this.pos -= n};
|
| 2629 |
StringStream.prototype.column = function () {
|
| 2630 |
if (this.lastColumnPos < this.start) {
|
| 2631 |
-
this.lastColumnValue = countColumn(this.string, this.start, this.tabSize, this.lastColumnPos, this.lastColumnValue)
|
| 2632 |
-
this.lastColumnPos = this.start
|
| 2633 |
}
|
| 2634 |
return this.lastColumnValue - (this.lineStart ? countColumn(this.string, this.lineStart, this.tabSize) : 0)
|
| 2635 |
};
|
|
@@ -2639,24 +2650,24 @@ webpackJsonp([2],{
|
|
| 2639 |
};
|
| 2640 |
StringStream.prototype.match = function (pattern, consume, caseInsensitive) {
|
| 2641 |
if (typeof pattern == "string") {
|
| 2642 |
-
var cased = function (str) { return caseInsensitive ? str.toLowerCase() : str; }
|
| 2643 |
-
var substr = this.string.substr(this.pos, pattern.length)
|
| 2644 |
if (cased(substr) == cased(pattern)) {
|
| 2645 |
-
if (consume !== false) { this.pos += pattern.length }
|
| 2646 |
return true
|
| 2647 |
}
|
| 2648 |
} else {
|
| 2649 |
-
var match = this.string.slice(this.pos).match(pattern)
|
| 2650 |
if (match && match.index > 0) { return null }
|
| 2651 |
-
if (match && consume !== false) { this.pos += match[0].length }
|
| 2652 |
return match
|
| 2653 |
}
|
| 2654 |
};
|
| 2655 |
StringStream.prototype.current = function (){return this.string.slice(this.start, this.pos)};
|
| 2656 |
StringStream.prototype.hideFirstChars = function (n, inner) {
|
| 2657 |
-
this.lineStart += n
|
| 2658 |
try { return inner() }
|
| 2659 |
-
finally { this.lineStart -= n }
|
| 2660 |
};
|
| 2661 |
|
| 2662 |
// Compute a style array (an array starting with a mode generation
|
|
@@ -2666,35 +2677,35 @@ webpackJsonp([2],{
|
|
| 2666 |
function highlightLine(cm, line, state, forceToEnd) {
|
| 2667 |
// A styles array always starts with a number identifying the
|
| 2668 |
// mode/overlays that it is based on (for easy invalidation).
|
| 2669 |
-
var st = [cm.state.modeGen], lineClasses = {}
|
| 2670 |
// Compute the base array of styles
|
| 2671 |
runMode(cm, line.text, cm.doc.mode, state, function (end, style) { return st.push(end, style); },
|
| 2672 |
-
lineClasses, forceToEnd)
|
| 2673 |
|
| 2674 |
// Run overlays, adjust style array.
|
| 2675 |
var loop = function ( o ) {
|
| 2676 |
-
var overlay = cm.state.overlays[o], i = 1, at = 0
|
| 2677 |
runMode(cm, line.text, overlay.mode, true, function (end, style) {
|
| 2678 |
-
var start = i
|
| 2679 |
// Ensure there's a token end at the current position, and that i points at it
|
| 2680 |
while (at < end) {
|
| 2681 |
-
var i_end = st[i]
|
| 2682 |
if (i_end > end)
|
| 2683 |
-
{ st.splice(i, 1, end, st[i+1], i_end) }
|
| 2684 |
-
i += 2
|
| 2685 |
-
at = Math.min(end, i_end)
|
| 2686 |
}
|
| 2687 |
if (!style) { return }
|
| 2688 |
if (overlay.opaque) {
|
| 2689 |
-
st.splice(start, i - start, end, "overlay " + style)
|
| 2690 |
-
i = start + 2
|
| 2691 |
} else {
|
| 2692 |
for (; start < i; start += 2) {
|
| 2693 |
-
var cur = st[start+1]
|
| 2694 |
-
st[start+1] = (cur ? cur + " " : "") + "overlay " + style
|
| 2695 |
}
|
| 2696 |
}
|
| 2697 |
-
}, lineClasses)
|
| 2698 |
};
|
| 2699 |
|
| 2700 |
for (var o = 0; o < cm.state.overlays.length; ++o) loop( o );
|
|
@@ -2704,30 +2715,30 @@ webpackJsonp([2],{
|
|
| 2704 |
|
| 2705 |
function getLineStyles(cm, line, updateFrontier) {
|
| 2706 |
if (!line.styles || line.styles[0] != cm.state.modeGen) {
|
| 2707 |
-
var state = getStateBefore(cm, lineNo(line))
|
| 2708 |
-
var result = highlightLine(cm, line, line.text.length > cm.options.maxHighlightLength ? copyState(cm.doc.mode, state) : state)
|
| 2709 |
-
line.stateAfter = state
|
| 2710 |
-
line.styles = result.styles
|
| 2711 |
-
if (result.classes) { line.styleClasses = result.classes }
|
| 2712 |
-
else if (line.styleClasses) { line.styleClasses = null }
|
| 2713 |
-
if (updateFrontier === cm.doc.frontier) { cm.doc.frontier
|
| 2714 |
}
|
| 2715 |
return line.styles
|
| 2716 |
}
|
| 2717 |
|
| 2718 |
function getStateBefore(cm, n, precise) {
|
| 2719 |
-
var doc = cm.doc, display = cm.display
|
| 2720 |
if (!doc.mode.startState) { return true }
|
| 2721 |
-
var pos = findStartLine(cm, n, precise), state = pos > doc.first && getLine(doc, pos-1).stateAfter
|
| 2722 |
-
if (!state) { state = startState(doc.mode) }
|
| 2723 |
-
else { state = copyState(doc.mode, state) }
|
| 2724 |
doc.iter(pos, n, function (line) {
|
| 2725 |
-
processLine(cm, line.text, state)
|
| 2726 |
-
var save = pos == n - 1 || pos % 5 == 0 || pos >= display.viewFrom && pos < display.viewTo
|
| 2727 |
-
line.stateAfter = save ? copyState(doc.mode, state) : null
|
| 2728 |
-
++pos
|
| 2729 |
-
})
|
| 2730 |
-
if (precise) { doc.frontier = pos }
|
| 2731 |
return state
|
| 2732 |
}
|
| 2733 |
|
|
@@ -2735,27 +2746,27 @@ webpackJsonp([2],{
|
|
| 2735 |
// update state, but don't save a style array. Used for lines that
|
| 2736 |
// aren't currently visible.
|
| 2737 |
function processLine(cm, text, state, startAt) {
|
| 2738 |
-
var mode = cm.doc.mode
|
| 2739 |
-
var stream = new StringStream(text, cm.options.tabSize)
|
| 2740 |
-
stream.start = stream.pos = startAt || 0
|
| 2741 |
-
if (text == "") { callBlankLine(mode, state) }
|
| 2742 |
while (!stream.eol()) {
|
| 2743 |
-
readToken(mode, stream, state)
|
| 2744 |
-
stream.start = stream.pos
|
| 2745 |
}
|
| 2746 |
}
|
| 2747 |
|
| 2748 |
function callBlankLine(mode, state) {
|
| 2749 |
if (mode.blankLine) { return mode.blankLine(state) }
|
| 2750 |
if (!mode.innerMode) { return }
|
| 2751 |
-
var inner = innerMode(mode, state)
|
| 2752 |
if (inner.mode.blankLine) { return inner.mode.blankLine(inner.state) }
|
| 2753 |
}
|
| 2754 |
|
| 2755 |
function readToken(mode, stream, state, inner) {
|
| 2756 |
for (var i = 0; i < 10; i++) {
|
| 2757 |
-
if (inner) { inner[0] = innerMode(mode, state).mode }
|
| 2758 |
-
var style = mode.token(stream, state)
|
| 2759 |
if (stream.pos > stream.start) { return style }
|
| 2760 |
}
|
| 2761 |
throw new Error("Mode " + mode.name + " failed to advance stream.")
|
|
@@ -2768,72 +2779,72 @@ webpackJsonp([2],{
|
|
| 2768 |
string: stream.current(),
|
| 2769 |
type: style || null,
|
| 2770 |
state: copy ? copyState(doc.mode, state) : state
|
| 2771 |
-
}); }
|
| 2772 |
|
| 2773 |
-
var doc = cm.doc, mode = doc.mode, style
|
| 2774 |
-
pos = clipPos(doc, pos)
|
| 2775 |
-
var line = getLine(doc, pos.line), state = getStateBefore(cm, pos.line, precise)
|
| 2776 |
-
var stream = new StringStream(line.text, cm.options.tabSize), tokens
|
| 2777 |
-
if (asArray) { tokens = [] }
|
| 2778 |
while ((asArray || stream.pos < pos.ch) && !stream.eol()) {
|
| 2779 |
-
stream.start = stream.pos
|
| 2780 |
-
style = readToken(mode, stream, state)
|
| 2781 |
-
if (asArray) { tokens.push(getObj(true)) }
|
| 2782 |
}
|
| 2783 |
return asArray ? tokens : getObj()
|
| 2784 |
}
|
| 2785 |
|
| 2786 |
function extractLineClasses(type, output) {
|
| 2787 |
if (type) { for (;;) {
|
| 2788 |
-
var lineClass = type.match(/(?:^|\s+)line-(background-)?(\S+)/)
|
| 2789 |
if (!lineClass) { break }
|
| 2790 |
-
type = type.slice(0, lineClass.index) + type.slice(lineClass.index + lineClass[0].length)
|
| 2791 |
-
var prop = lineClass[1] ? "bgClass" : "textClass"
|
| 2792 |
if (output[prop] == null)
|
| 2793 |
-
{ output[prop] = lineClass[2] }
|
| 2794 |
else if (!(new RegExp("(?:^|\s)" + lineClass[2] + "(?:$|\s)")).test(output[prop]))
|
| 2795 |
-
{ output[prop] += " " + lineClass[2] }
|
| 2796 |
} }
|
| 2797 |
return type
|
| 2798 |
}
|
| 2799 |
|
| 2800 |
// Run the given mode's parser over a line, calling f for each token.
|
| 2801 |
function runMode(cm, text, mode, state, f, lineClasses, forceToEnd) {
|
| 2802 |
-
var flattenSpans = mode.flattenSpans
|
| 2803 |
-
if (flattenSpans == null) { flattenSpans = cm.options.flattenSpans }
|
| 2804 |
-
var curStart = 0, curStyle = null
|
| 2805 |
-
var stream = new StringStream(text, cm.options.tabSize), style
|
| 2806 |
-
var inner = cm.options.addModeClass && [null]
|
| 2807 |
-
if (text == "") { extractLineClasses(callBlankLine(mode, state), lineClasses) }
|
| 2808 |
while (!stream.eol()) {
|
| 2809 |
if (stream.pos > cm.options.maxHighlightLength) {
|
| 2810 |
-
flattenSpans = false
|
| 2811 |
-
if (forceToEnd) { processLine(cm, text, state, stream.pos) }
|
| 2812 |
-
stream.pos = text.length
|
| 2813 |
-
style = null
|
| 2814 |
} else {
|
| 2815 |
-
style = extractLineClasses(readToken(mode, stream, state, inner), lineClasses)
|
| 2816 |
}
|
| 2817 |
if (inner) {
|
| 2818 |
-
var mName = inner[0].name
|
| 2819 |
-
if (mName) { style = "m-" + (style ? mName + " " + style : mName) }
|
| 2820 |
}
|
| 2821 |
if (!flattenSpans || curStyle != style) {
|
| 2822 |
while (curStart < stream.start) {
|
| 2823 |
-
curStart = Math.min(stream.start, curStart + 5000)
|
| 2824 |
-
f(curStart, curStyle)
|
| 2825 |
}
|
| 2826 |
-
curStyle = style
|
| 2827 |
}
|
| 2828 |
-
stream.start = stream.pos
|
| 2829 |
}
|
| 2830 |
while (curStart < stream.pos) {
|
| 2831 |
// Webkit seems to refuse to render text nodes longer than 57444
|
| 2832 |
// characters, and returns inaccurate measurements in nodes
|
| 2833 |
// starting around 5000 chars.
|
| 2834 |
-
var pos = Math.min(stream.pos, curStart + 5000)
|
| 2835 |
-
f(pos, curStyle)
|
| 2836 |
-
curStart = pos
|
| 2837 |
}
|
| 2838 |
}
|
| 2839 |
|
|
@@ -2843,16 +2854,16 @@ webpackJsonp([2],{
|
|
| 2843 |
// smallest indentation, which tends to need the least context to
|
| 2844 |
// parse correctly.
|
| 2845 |
function findStartLine(cm, n, precise) {
|
| 2846 |
-
var minindent, minline, doc = cm.doc
|
| 2847 |
-
var lim = precise ? -1 : n - (cm.doc.mode.innerMode ? 1000 : 100)
|
| 2848 |
for (var search = n; search > lim; --search) {
|
| 2849 |
if (search <= doc.first) { return doc.first }
|
| 2850 |
-
var line = getLine(doc, search - 1)
|
| 2851 |
if (line.stateAfter && (!precise || search <= doc.frontier)) { return search }
|
| 2852 |
-
var indented = countColumn(line.text, null, cm.options.tabSize)
|
| 2853 |
if (minline == null || minindent > indented) {
|
| 2854 |
-
minline = search - 1
|
| 2855 |
-
minindent = indented
|
| 2856 |
}
|
| 2857 |
}
|
| 2858 |
return minline
|
|
@@ -2863,32 +2874,32 @@ webpackJsonp([2],{
|
|
| 2863 |
// Line objects. These hold state related to a line, including
|
| 2864 |
// highlighting info (the styles array).
|
| 2865 |
var Line = function(text, markedSpans, estimateHeight) {
|
| 2866 |
-
this.text = text
|
| 2867 |
-
attachMarkedSpans(this, markedSpans)
|
| 2868 |
-
this.height = estimateHeight ? estimateHeight(this) : 1
|
| 2869 |
};
|
| 2870 |
|
| 2871 |
Line.prototype.lineNo = function () { return lineNo(this) };
|
| 2872 |
-
eventMixin(Line)
|
| 2873 |
|
| 2874 |
// Change the content (text, markers) of a line. Automatically
|
| 2875 |
// invalidates cached information and tries to re-estimate the
|
| 2876 |
// line's height.
|
| 2877 |
function updateLine(line, text, markedSpans, estimateHeight) {
|
| 2878 |
-
line.text = text
|
| 2879 |
-
if (line.stateAfter) { line.stateAfter = null }
|
| 2880 |
-
if (line.styles) { line.styles = null }
|
| 2881 |
-
if (line.order != null) { line.order = null }
|
| 2882 |
-
detachMarkedSpans(line)
|
| 2883 |
-
attachMarkedSpans(line, markedSpans)
|
| 2884 |
-
var estHeight = estimateHeight ? estimateHeight(line) : 1
|
| 2885 |
-
if (estHeight != line.height) { updateLineHeight(line, estHeight) }
|
| 2886 |
}
|
| 2887 |
|
| 2888 |
// Detach a line from the document tree and its markers.
|
| 2889 |
function cleanUpLine(line) {
|
| 2890 |
-
line.parent = null
|
| 2891 |
-
detachMarkedSpans(line)
|
| 2892 |
}
|
| 2893 |
|
| 2894 |
// Convert a style as returned by a mode (either null, or a string
|
|
@@ -2898,7 +2909,7 @@ webpackJsonp([2],{
|
|
| 2898 |
var styleToClassCacheWithMode = {};
|
| 2899 |
function interpretTokenStyle(style, options) {
|
| 2900 |
if (!style || /^\s*$/.test(style)) { return null }
|
| 2901 |
-
var cache = options.addModeClass ? styleToClassCacheWithMode : styleToClassCache
|
| 2902 |
return cache[style] ||
|
| 2903 |
(cache[style] = style.replace(/\S+/g, "cm-$&"))
|
| 2904 |
}
|
|
@@ -2912,67 +2923,64 @@ webpackJsonp([2],{
|
|
| 2912 |
// The padding-right forces the element to have a 'border', which
|
| 2913 |
// is needed on Webkit to be able to get line-level bounding
|
| 2914 |
// rectangles for it (in measureChar).
|
| 2915 |
-
var content =
|
| 2916 |
-
var builder = {pre:
|
| 2917 |
col: 0, pos: 0, cm: cm,
|
| 2918 |
trailingSpace: false,
|
| 2919 |
-
splitSpaces: (ie || webkit) && cm.getOption("lineWrapping")}
|
| 2920 |
-
|
| 2921 |
-
content.setAttribute("role", "presentation")
|
| 2922 |
-
builder.pre.setAttribute("role", "presentation")
|
| 2923 |
-
lineView.measure = {}
|
| 2924 |
|
| 2925 |
// Iterate over the logical lines that make up this visual line.
|
| 2926 |
for (var i = 0; i <= (lineView.rest ? lineView.rest.length : 0); i++) {
|
| 2927 |
-
var line = i ? lineView.rest[i - 1] : lineView.line, order = (void 0)
|
| 2928 |
-
builder.pos = 0
|
| 2929 |
-
builder.addToken = buildToken
|
| 2930 |
// Optionally wire in some hacks into the token-rendering
|
| 2931 |
// algorithm, to deal with browser quirks.
|
| 2932 |
-
if (hasBadBidiRects(cm.display.measure) && (order = getOrder(line)))
|
| 2933 |
-
{ builder.addToken = buildTokenBadBidi(builder.addToken, order) }
|
| 2934 |
-
builder.map = []
|
| 2935 |
-
var allowFrontierUpdate = lineView != cm.display.externalMeasured && lineNo(line)
|
| 2936 |
-
insertLineContent(line, builder, getLineStyles(cm, line, allowFrontierUpdate))
|
| 2937 |
if (line.styleClasses) {
|
| 2938 |
if (line.styleClasses.bgClass)
|
| 2939 |
-
{ builder.bgClass = joinClasses(line.styleClasses.bgClass, builder.bgClass || "") }
|
| 2940 |
if (line.styleClasses.textClass)
|
| 2941 |
-
{ builder.textClass = joinClasses(line.styleClasses.textClass, builder.textClass || "") }
|
| 2942 |
}
|
| 2943 |
|
| 2944 |
// Ensure at least a single node is present, for measuring.
|
| 2945 |
if (builder.map.length == 0)
|
| 2946 |
-
{ builder.map.push(0, 0, builder.content.appendChild(zeroWidthElement(cm.display.measure))) }
|
| 2947 |
|
| 2948 |
// Store the map and a cache object for the current logical line
|
| 2949 |
if (i == 0) {
|
| 2950 |
-
lineView.measure.map = builder.map
|
| 2951 |
-
lineView.measure.cache = {}
|
| 2952 |
} else {
|
| 2953 |
-
|
| 2954 |
-
;(lineView.measure.caches || (lineView.measure.caches = [])).push({})
|
| 2955 |
}
|
| 2956 |
}
|
| 2957 |
|
| 2958 |
// See issue #2901
|
| 2959 |
if (webkit) {
|
| 2960 |
-
var last = builder.content.lastChild
|
| 2961 |
if (/\bcm-tab\b/.test(last.className) || (last.querySelector && last.querySelector(".cm-tab")))
|
| 2962 |
-
{ builder.content.className = "cm-tab-wrap-hack" }
|
| 2963 |
}
|
| 2964 |
|
| 2965 |
-
signal(cm, "renderLine", cm, lineView.line, builder.pre)
|
| 2966 |
if (builder.pre.className)
|
| 2967 |
-
{ builder.textClass = joinClasses(builder.pre.className, builder.textClass || "") }
|
| 2968 |
|
| 2969 |
return builder
|
| 2970 |
}
|
| 2971 |
|
| 2972 |
function defaultSpecialCharPlaceholder(ch) {
|
| 2973 |
-
var token = elt("span", "\u2022", "cm-invalidchar")
|
| 2974 |
-
token.title = "\\u" + ch.charCodeAt(0).toString(16)
|
| 2975 |
-
token.setAttribute("aria-label", token.title)
|
| 2976 |
return token
|
| 2977 |
}
|
| 2978 |
|
|
@@ -2980,75 +2988,75 @@ webpackJsonp([2],{
|
|
| 2980 |
// the line map. Takes care to render special characters separately.
|
| 2981 |
function buildToken(builder, text, style, startStyle, endStyle, title, css) {
|
| 2982 |
if (!text) { return }
|
| 2983 |
-
var displayText = builder.splitSpaces ? splitSpaces(text, builder.trailingSpace) : text
|
| 2984 |
-
var special = builder.cm.state.specialChars, mustWrap = false
|
| 2985 |
-
var content
|
| 2986 |
if (!special.test(text)) {
|
| 2987 |
-
builder.col += text.length
|
| 2988 |
-
content = document.createTextNode(displayText)
|
| 2989 |
-
builder.map.push(builder.pos, builder.pos + text.length, content)
|
| 2990 |
-
if (ie && ie_version < 9) { mustWrap = true }
|
| 2991 |
-
builder.pos += text.length
|
| 2992 |
} else {
|
| 2993 |
-
content = document.createDocumentFragment()
|
| 2994 |
-
var pos = 0
|
| 2995 |
while (true) {
|
| 2996 |
-
special.lastIndex = pos
|
| 2997 |
-
var m = special.exec(text)
|
| 2998 |
-
var skipped = m ? m.index - pos : text.length - pos
|
| 2999 |
if (skipped) {
|
| 3000 |
-
var txt = document.createTextNode(displayText.slice(pos, pos + skipped))
|
| 3001 |
-
if (ie && ie_version < 9) { content.appendChild(elt("span", [txt])) }
|
| 3002 |
-
else { content.appendChild(txt) }
|
| 3003 |
-
builder.map.push(builder.pos, builder.pos + skipped, txt)
|
| 3004 |
-
builder.col += skipped
|
| 3005 |
-
builder.pos += skipped
|
| 3006 |
}
|
| 3007 |
if (!m) { break }
|
| 3008 |
-
pos += skipped + 1
|
| 3009 |
-
var txt$1 = (void 0)
|
| 3010 |
if (m[0] == "\t") {
|
| 3011 |
-
var tabSize = builder.cm.options.tabSize, tabWidth = tabSize - builder.col % tabSize
|
| 3012 |
-
txt$1 = content.appendChild(elt("span", spaceStr(tabWidth), "cm-tab"))
|
| 3013 |
-
txt$1.setAttribute("role", "presentation")
|
| 3014 |
-
txt$1.setAttribute("cm-text", "\t")
|
| 3015 |
-
builder.col += tabWidth
|
| 3016 |
} else if (m[0] == "\r" || m[0] == "\n") {
|
| 3017 |
-
txt$1 = content.appendChild(elt("span", m[0] == "\r" ? "\u240d" : "\u2424", "cm-invalidchar"))
|
| 3018 |
-
txt$1.setAttribute("cm-text", m[0])
|
| 3019 |
-
builder.col += 1
|
| 3020 |
} else {
|
| 3021 |
-
txt$1 = builder.cm.options.specialCharPlaceholder(m[0])
|
| 3022 |
-
txt$1.setAttribute("cm-text", m[0])
|
| 3023 |
-
if (ie && ie_version < 9) { content.appendChild(elt("span", [txt$1])) }
|
| 3024 |
-
else { content.appendChild(txt$1) }
|
| 3025 |
-
builder.col += 1
|
| 3026 |
}
|
| 3027 |
-
builder.map.push(builder.pos, builder.pos + 1, txt$1)
|
| 3028 |
-
builder.pos
|
| 3029 |
}
|
| 3030 |
}
|
| 3031 |
-
builder.trailingSpace = displayText.charCodeAt(text.length - 1) == 32
|
| 3032 |
if (style || startStyle || endStyle || mustWrap || css) {
|
| 3033 |
-
var fullStyle = style || ""
|
| 3034 |
-
if (startStyle) { fullStyle += startStyle }
|
| 3035 |
-
if (endStyle) { fullStyle += endStyle }
|
| 3036 |
-
var token = elt("span", [content], fullStyle, css)
|
| 3037 |
-
if (title) { token.title = title }
|
| 3038 |
return builder.content.appendChild(token)
|
| 3039 |
}
|
| 3040 |
-
builder.content.appendChild(content)
|
| 3041 |
}
|
| 3042 |
|
| 3043 |
function splitSpaces(text, trailingBefore) {
|
| 3044 |
if (text.length > 1 && !/ /.test(text)) { return text }
|
| 3045 |
-
var spaceBefore = trailingBefore, result = ""
|
| 3046 |
for (var i = 0; i < text.length; i++) {
|
| 3047 |
-
var ch = text.charAt(i)
|
| 3048 |
if (ch == " " && spaceBefore && (i == text.length - 1 || text.charCodeAt(i + 1) == 32))
|
| 3049 |
-
{ ch = "\u00a0" }
|
| 3050 |
-
result += ch
|
| 3051 |
-
spaceBefore = ch == " "
|
| 3052 |
}
|
| 3053 |
return result
|
| 3054 |
}
|
|
@@ -3057,106 +3065,106 @@ webpackJsonp([2],{
|
|
| 3057 |
// right-to-left text.
|
| 3058 |
function buildTokenBadBidi(inner, order) {
|
| 3059 |
return function (builder, text, style, startStyle, endStyle, title, css) {
|
| 3060 |
-
style = style ? style + " cm-force-border" : "cm-force-border"
|
| 3061 |
-
var start = builder.pos, end = start + text.length
|
| 3062 |
for (;;) {
|
| 3063 |
// Find the part that overlaps with the start of this text
|
| 3064 |
-
var part = (void 0)
|
| 3065 |
for (var i = 0; i < order.length; i++) {
|
| 3066 |
-
part = order[i]
|
| 3067 |
if (part.to > start && part.from <= start) { break }
|
| 3068 |
}
|
| 3069 |
if (part.to >= end) { return inner(builder, text, style, startStyle, endStyle, title, css) }
|
| 3070 |
-
inner(builder, text.slice(0, part.to - start), style, startStyle, null, title, css)
|
| 3071 |
-
startStyle = null
|
| 3072 |
-
text = text.slice(part.to - start)
|
| 3073 |
-
start = part.to
|
| 3074 |
}
|
| 3075 |
}
|
| 3076 |
}
|
| 3077 |
|
| 3078 |
function buildCollapsedSpan(builder, size, marker, ignoreWidget) {
|
| 3079 |
-
var widget = !ignoreWidget && marker.widgetNode
|
| 3080 |
-
if (widget) { builder.map.push(builder.pos, builder.pos + size, widget) }
|
| 3081 |
if (!ignoreWidget && builder.cm.display.input.needsContentAttribute) {
|
| 3082 |
if (!widget)
|
| 3083 |
-
{ widget = builder.content.appendChild(document.createElement("span")) }
|
| 3084 |
-
widget.setAttribute("cm-marker", marker.id)
|
| 3085 |
}
|
| 3086 |
if (widget) {
|
| 3087 |
-
builder.cm.display.input.setUneditable(widget)
|
| 3088 |
-
builder.content.appendChild(widget)
|
| 3089 |
}
|
| 3090 |
-
builder.pos += size
|
| 3091 |
-
builder.trailingSpace = false
|
| 3092 |
}
|
| 3093 |
|
| 3094 |
// Outputs a number of spans to make up a line, taking highlighting
|
| 3095 |
// and marked text into account.
|
| 3096 |
function insertLineContent(line, builder, styles) {
|
| 3097 |
-
var spans = line.markedSpans, allText = line.text, at = 0
|
| 3098 |
if (!spans) {
|
| 3099 |
for (var i$1 = 1; i$1 < styles.length; i$1+=2)
|
| 3100 |
-
{ builder.addToken(builder, allText.slice(at, at = styles[i$1]), interpretTokenStyle(styles[i$1+1], builder.cm.options)) }
|
| 3101 |
return
|
| 3102 |
}
|
| 3103 |
|
| 3104 |
-
var len = allText.length, pos = 0, i = 1, text = "", style, css
|
| 3105 |
-
var nextChange = 0, spanStyle, spanEndStyle, spanStartStyle, title, collapsed
|
| 3106 |
for (;;) {
|
| 3107 |
if (nextChange == pos) { // Update current marker set
|
| 3108 |
-
spanStyle = spanEndStyle = spanStartStyle = title = css = ""
|
| 3109 |
-
collapsed = null; nextChange = Infinity
|
| 3110 |
-
var foundBookmarks = [], endStyles = (void 0)
|
| 3111 |
for (var j = 0; j < spans.length; ++j) {
|
| 3112 |
-
var sp = spans[j], m = sp.marker
|
| 3113 |
if (m.type == "bookmark" && sp.from == pos && m.widgetNode) {
|
| 3114 |
-
foundBookmarks.push(m)
|
| 3115 |
} else if (sp.from <= pos && (sp.to == null || sp.to > pos || m.collapsed && sp.to == pos && sp.from == pos)) {
|
| 3116 |
if (sp.to != null && sp.to != pos && nextChange > sp.to) {
|
| 3117 |
-
nextChange = sp.to
|
| 3118 |
-
spanEndStyle = ""
|
| 3119 |
}
|
| 3120 |
-
if (m.className) { spanStyle += " " + m.className }
|
| 3121 |
-
if (m.css) { css = (css ? css + ";" : "") + m.css }
|
| 3122 |
-
if (m.startStyle && sp.from == pos) { spanStartStyle += " " + m.startStyle }
|
| 3123 |
-
if (m.endStyle && sp.to == nextChange) { (endStyles || (endStyles = [])).push(m.endStyle, sp.to) }
|
| 3124 |
-
if (m.title && !title) { title = m.title }
|
| 3125 |
if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
|
| 3126 |
-
{ collapsed = sp }
|
| 3127 |
} else if (sp.from > pos && nextChange > sp.from) {
|
| 3128 |
-
nextChange = sp.from
|
| 3129 |
}
|
| 3130 |
}
|
| 3131 |
if (endStyles) { for (var j$1 = 0; j$1 < endStyles.length; j$1 += 2)
|
| 3132 |
-
{ if (endStyles[j$1 + 1] == nextChange) { spanEndStyle += " " + endStyles[j$1] } } }
|
| 3133 |
|
| 3134 |
if (!collapsed || collapsed.from == pos) { for (var j$2 = 0; j$2 < foundBookmarks.length; ++j$2)
|
| 3135 |
-
{ buildCollapsedSpan(builder, 0, foundBookmarks[j$2]) } }
|
| 3136 |
if (collapsed && (collapsed.from || 0) == pos) {
|
| 3137 |
buildCollapsedSpan(builder, (collapsed.to == null ? len + 1 : collapsed.to) - pos,
|
| 3138 |
-
collapsed.marker, collapsed.from == null)
|
| 3139 |
if (collapsed.to == null) { return }
|
| 3140 |
-
if (collapsed.to == pos) { collapsed = false }
|
| 3141 |
}
|
| 3142 |
}
|
| 3143 |
if (pos >= len) { break }
|
| 3144 |
|
| 3145 |
-
var upto = Math.min(len, nextChange)
|
| 3146 |
while (true) {
|
| 3147 |
if (text) {
|
| 3148 |
-
var end = pos + text.length
|
| 3149 |
if (!collapsed) {
|
| 3150 |
-
var tokenText = end > upto ? text.slice(0, upto - pos) : text
|
| 3151 |
builder.addToken(builder, tokenText, style ? style + spanStyle : spanStyle,
|
| 3152 |
-
spanStartStyle, pos + tokenText.length == nextChange ? spanEndStyle : "", title, css)
|
| 3153 |
}
|
| 3154 |
if (end >= upto) {text = text.slice(upto - pos); pos = upto; break}
|
| 3155 |
-
pos = end
|
| 3156 |
-
spanStartStyle = ""
|
| 3157 |
}
|
| 3158 |
-
text = allText.slice(at, at = styles[i++])
|
| 3159 |
-
style = interpretTokenStyle(styles[i++], builder.cm.options)
|
| 3160 |
}
|
| 3161 |
}
|
| 3162 |
}
|
|
@@ -3167,67 +3175,67 @@ webpackJsonp([2],{
|
|
| 3167 |
// logical lines, if those are connected by collapsed ranges.
|
| 3168 |
function LineView(doc, line, lineN) {
|
| 3169 |
// The starting line
|
| 3170 |
-
this.line = line
|
| 3171 |
// Continuing lines, if any
|
| 3172 |
-
this.rest = visualLineContinued(line)
|
| 3173 |
// Number of logical lines in this visual line
|
| 3174 |
-
this.size = this.rest ? lineNo(lst(this.rest)) - lineN + 1 : 1
|
| 3175 |
-
this.node = this.text = null
|
| 3176 |
-
this.hidden = lineIsHidden(doc, line)
|
| 3177 |
}
|
| 3178 |
|
| 3179 |
// Create a range of LineView objects for the given lines.
|
| 3180 |
function buildViewArray(cm, from, to) {
|
| 3181 |
-
var array = [], nextPos
|
| 3182 |
for (var pos = from; pos < to; pos = nextPos) {
|
| 3183 |
-
var view = new LineView(cm.doc, getLine(cm.doc, pos), pos)
|
| 3184 |
-
nextPos = pos + view.size
|
| 3185 |
-
array.push(view)
|
| 3186 |
}
|
| 3187 |
return array
|
| 3188 |
}
|
| 3189 |
|
| 3190 |
-
var operationGroup = null
|
| 3191 |
|
| 3192 |
function pushOperation(op) {
|
| 3193 |
if (operationGroup) {
|
| 3194 |
-
operationGroup.ops.push(op)
|
| 3195 |
} else {
|
| 3196 |
op.ownsGroup = operationGroup = {
|
| 3197 |
ops: [op],
|
| 3198 |
delayedCallbacks: []
|
| 3199 |
-
}
|
| 3200 |
}
|
| 3201 |
}
|
| 3202 |
|
| 3203 |
function fireCallbacksForOps(group) {
|
| 3204 |
// Calls delayed callbacks and cursorActivity handlers until no
|
| 3205 |
// new ones appear
|
| 3206 |
-
var callbacks = group.delayedCallbacks, i = 0
|
| 3207 |
do {
|
| 3208 |
for (; i < callbacks.length; i++)
|
| 3209 |
-
{ callbacks[i].call(null) }
|
| 3210 |
for (var j = 0; j < group.ops.length; j++) {
|
| 3211 |
-
var op = group.ops[j]
|
| 3212 |
if (op.cursorActivityHandlers)
|
| 3213 |
{ while (op.cursorActivityCalled < op.cursorActivityHandlers.length)
|
| 3214 |
-
{ op.cursorActivityHandlers[op.cursorActivityCalled++].call(null, op.cm) } }
|
| 3215 |
}
|
| 3216 |
} while (i < callbacks.length)
|
| 3217 |
}
|
| 3218 |
|
| 3219 |
function finishOperation(op, endCb) {
|
| 3220 |
-
var group = op.ownsGroup
|
| 3221 |
if (!group) { return }
|
| 3222 |
|
| 3223 |
-
try { fireCallbacksForOps(group) }
|
| 3224 |
finally {
|
| 3225 |
-
operationGroup = null
|
| 3226 |
-
endCb(group)
|
| 3227 |
}
|
| 3228 |
}
|
| 3229 |
|
| 3230 |
-
var orphanDelayedCallbacks = null
|
| 3231 |
|
| 3232 |
// Often, we want to signal events at a point where we are in the
|
| 3233 |
// middle of some work, but don't want the handler to start calling
|
|
@@ -3237,19 +3245,19 @@ webpackJsonp([2],{
|
|
| 3237 |
// them to be executed when the last operation ends, or, if no
|
| 3238 |
// operation is active, when a timeout fires.
|
| 3239 |
function signalLater(emitter, type /*, values...*/) {
|
| 3240 |
-
var arr = getHandlers(emitter, type)
|
| 3241 |
if (!arr.length) { return }
|
| 3242 |
-
var args = Array.prototype.slice.call(arguments, 2), list
|
| 3243 |
if (operationGroup) {
|
| 3244 |
-
list = operationGroup.delayedCallbacks
|
| 3245 |
} else if (orphanDelayedCallbacks) {
|
| 3246 |
-
list = orphanDelayedCallbacks
|
| 3247 |
} else {
|
| 3248 |
-
list = orphanDelayedCallbacks = []
|
| 3249 |
-
setTimeout(fireOrphanDelayed, 0)
|
| 3250 |
}
|
| 3251 |
var loop = function ( i ) {
|
| 3252 |
-
list.push(function () { return arr[i].apply(null, args); })
|
| 3253 |
};
|
| 3254 |
|
| 3255 |
for (var i = 0; i < arr.length; ++i)
|
|
@@ -3257,9 +3265,9 @@ webpackJsonp([2],{
|
|
| 3257 |
}
|
| 3258 |
|
| 3259 |
function fireOrphanDelayed() {
|
| 3260 |
-
var delayed = orphanDelayedCallbacks
|
| 3261 |
-
orphanDelayedCallbacks = null
|
| 3262 |
-
for (var i = 0; i < delayed.length; ++i) { delayed[i]() }
|
| 3263 |
}
|
| 3264 |
|
| 3265 |
// When an aspect of a line changes, a string is added to
|
|
@@ -3267,47 +3275,48 @@ webpackJsonp([2],{
|
|
| 3267 |
// DOM structure.
|
| 3268 |
function updateLineForChanges(cm, lineView, lineN, dims) {
|
| 3269 |
for (var j = 0; j < lineView.changes.length; j++) {
|
| 3270 |
-
var type = lineView.changes[j]
|
| 3271 |
-
if (type == "text") { updateLineText(cm, lineView) }
|
| 3272 |
-
else if (type == "gutter") { updateLineGutter(cm, lineView, lineN, dims) }
|
| 3273 |
-
else if (type == "class") { updateLineClasses(lineView) }
|
| 3274 |
-
else if (type == "widget") { updateLineWidgets(cm, lineView, dims) }
|
| 3275 |
}
|
| 3276 |
-
lineView.changes = null
|
| 3277 |
}
|
| 3278 |
|
| 3279 |
// Lines with gutter elements, widgets or a background class need to
|
| 3280 |
// be wrapped, and have the extra elements added to the wrapper div
|
| 3281 |
function ensureLineWrapped(lineView) {
|
| 3282 |
if (lineView.node == lineView.text) {
|
| 3283 |
-
lineView.node = elt("div", null, null, "position: relative")
|
| 3284 |
if (lineView.text.parentNode)
|
| 3285 |
-
{ lineView.text.parentNode.replaceChild(lineView.node, lineView.text) }
|
| 3286 |
-
lineView.node.appendChild(lineView.text)
|
| 3287 |
-
if (ie && ie_version < 8) { lineView.node.style.zIndex = 2 }
|
| 3288 |
}
|
| 3289 |
return lineView.node
|
| 3290 |
}
|
| 3291 |
|
| 3292 |
-
function updateLineBackground(lineView) {
|
| 3293 |
-
var cls = lineView.bgClass ? lineView.bgClass + " " + (lineView.line.bgClass || "") : lineView.line.bgClass
|
| 3294 |
-
if (cls) { cls += " CodeMirror-linebackground" }
|
| 3295 |
if (lineView.background) {
|
| 3296 |
-
if (cls) { lineView.background.className = cls }
|
| 3297 |
-
else { lineView.background.parentNode.removeChild(lineView.background); lineView.background = null }
|
| 3298 |
} else if (cls) {
|
| 3299 |
-
var wrap = ensureLineWrapped(lineView)
|
| 3300 |
-
lineView.background = wrap.insertBefore(elt("div", null, cls), wrap.firstChild)
|
|
|
|
| 3301 |
}
|
| 3302 |
}
|
| 3303 |
|
| 3304 |
// Wrapper around buildLineContent which will reuse the structure
|
| 3305 |
// in display.externalMeasured when possible.
|
| 3306 |
function getLineContent(cm, lineView) {
|
| 3307 |
-
var ext = cm.display.externalMeasured
|
| 3308 |
if (ext && ext.line == lineView.line) {
|
| 3309 |
-
cm.display.externalMeasured = null
|
| 3310 |
-
lineView.measure = ext.measure
|
| 3311 |
return ext.built
|
| 3312 |
}
|
| 3313 |
return buildLineContent(cm, lineView)
|
|
@@ -3317,143 +3326,144 @@ webpackJsonp([2],{
|
|
| 3317 |
// classes because the mode may output tokens that influence these
|
| 3318 |
// classes.
|
| 3319 |
function updateLineText(cm, lineView) {
|
| 3320 |
-
var cls = lineView.text.className
|
| 3321 |
-
var built = getLineContent(cm, lineView)
|
| 3322 |
-
if (lineView.text == lineView.node) { lineView.node = built.pre }
|
| 3323 |
-
lineView.text.parentNode.replaceChild(built.pre, lineView.text)
|
| 3324 |
-
lineView.text = built.pre
|
| 3325 |
if (built.bgClass != lineView.bgClass || built.textClass != lineView.textClass) {
|
| 3326 |
-
lineView.bgClass = built.bgClass
|
| 3327 |
-
lineView.textClass = built.textClass
|
| 3328 |
-
updateLineClasses(lineView)
|
| 3329 |
} else if (cls) {
|
| 3330 |
-
lineView.text.className = cls
|
| 3331 |
}
|
| 3332 |
}
|
| 3333 |
|
| 3334 |
-
function updateLineClasses(lineView) {
|
| 3335 |
-
updateLineBackground(lineView)
|
| 3336 |
if (lineView.line.wrapClass)
|
| 3337 |
-
{ ensureLineWrapped(lineView).className = lineView.line.wrapClass }
|
| 3338 |
else if (lineView.node != lineView.text)
|
| 3339 |
-
{ lineView.node.className = "" }
|
| 3340 |
-
var textClass = lineView.textClass ? lineView.textClass + " " + (lineView.line.textClass || "") : lineView.line.textClass
|
| 3341 |
-
lineView.text.className = textClass || ""
|
| 3342 |
}
|
| 3343 |
|
| 3344 |
function updateLineGutter(cm, lineView, lineN, dims) {
|
| 3345 |
if (lineView.gutter) {
|
| 3346 |
-
lineView.node.removeChild(lineView.gutter)
|
| 3347 |
-
lineView.gutter = null
|
| 3348 |
}
|
| 3349 |
if (lineView.gutterBackground) {
|
| 3350 |
-
lineView.node.removeChild(lineView.gutterBackground)
|
| 3351 |
-
lineView.gutterBackground = null
|
| 3352 |
}
|
| 3353 |
if (lineView.line.gutterClass) {
|
| 3354 |
-
var wrap = ensureLineWrapped(lineView)
|
| 3355 |
lineView.gutterBackground = elt("div", null, "CodeMirror-gutter-background " + lineView.line.gutterClass,
|
| 3356 |
-
("left: " + (cm.options.fixedGutter ? dims.fixedPos : -dims.gutterTotalWidth) + "px; width: " + (dims.gutterTotalWidth) + "px"))
|
| 3357 |
-
|
|
|
|
| 3358 |
}
|
| 3359 |
-
var markers = lineView.line.gutterMarkers
|
| 3360 |
if (cm.options.lineNumbers || markers) {
|
| 3361 |
-
var wrap$1 = ensureLineWrapped(lineView)
|
| 3362 |
-
var gutterWrap = lineView.gutter = elt("div", null, "CodeMirror-gutter-wrapper", ("left: " + (cm.options.fixedGutter ? dims.fixedPos : -dims.gutterTotalWidth) + "px"))
|
| 3363 |
-
cm.display.input.setUneditable(gutterWrap)
|
| 3364 |
-
wrap$1.insertBefore(gutterWrap, lineView.text)
|
| 3365 |
if (lineView.line.gutterClass)
|
| 3366 |
-
{ gutterWrap.className += " " + lineView.line.gutterClass }
|
| 3367 |
if (cm.options.lineNumbers && (!markers || !markers["CodeMirror-linenumbers"]))
|
| 3368 |
{ lineView.lineNumber = gutterWrap.appendChild(
|
| 3369 |
elt("div", lineNumberFor(cm.options, lineN),
|
| 3370 |
"CodeMirror-linenumber CodeMirror-gutter-elt",
|
| 3371 |
-
("left: " + (dims.gutterLeft["CodeMirror-linenumbers"]) + "px; width: " + (cm.display.lineNumInnerWidth) + "px"))) }
|
| 3372 |
if (markers) { for (var k = 0; k < cm.options.gutters.length; ++k) {
|
| 3373 |
-
var id = cm.options.gutters[k], found = markers.hasOwnProperty(id) && markers[id]
|
| 3374 |
if (found)
|
| 3375 |
{ gutterWrap.appendChild(elt("div", [found], "CodeMirror-gutter-elt",
|
| 3376 |
-
("left: " + (dims.gutterLeft[id]) + "px; width: " + (dims.gutterWidth[id]) + "px"))) }
|
| 3377 |
} }
|
| 3378 |
}
|
| 3379 |
}
|
| 3380 |
|
| 3381 |
function updateLineWidgets(cm, lineView, dims) {
|
| 3382 |
-
if (lineView.alignable) { lineView.alignable = null }
|
| 3383 |
for (var node = lineView.node.firstChild, next = (void 0); node; node = next) {
|
| 3384 |
-
next = node.nextSibling
|
| 3385 |
if (node.className == "CodeMirror-linewidget")
|
| 3386 |
-
{ lineView.node.removeChild(node) }
|
| 3387 |
}
|
| 3388 |
-
insertLineWidgets(cm, lineView, dims)
|
| 3389 |
}
|
| 3390 |
|
| 3391 |
// Build a line's DOM representation from scratch
|
| 3392 |
function buildLineElement(cm, lineView, lineN, dims) {
|
| 3393 |
-
var built = getLineContent(cm, lineView)
|
| 3394 |
-
lineView.text = lineView.node = built.pre
|
| 3395 |
-
if (built.bgClass) { lineView.bgClass = built.bgClass }
|
| 3396 |
-
if (built.textClass) { lineView.textClass = built.textClass }
|
| 3397 |
-
|
| 3398 |
-
updateLineClasses(lineView)
|
| 3399 |
-
updateLineGutter(cm, lineView, lineN, dims)
|
| 3400 |
-
insertLineWidgets(cm, lineView, dims)
|
| 3401 |
return lineView.node
|
| 3402 |
}
|
| 3403 |
|
| 3404 |
// A lineView may contain multiple logical lines (when merged by
|
| 3405 |
// collapsed spans). The widgets for all of them need to be drawn.
|
| 3406 |
function insertLineWidgets(cm, lineView, dims) {
|
| 3407 |
-
insertLineWidgetsFor(cm, lineView.line, lineView, dims, true)
|
| 3408 |
if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)
|
| 3409 |
-
{ insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false) } }
|
| 3410 |
}
|
| 3411 |
|
| 3412 |
function insertLineWidgetsFor(cm, line, lineView, dims, allowAbove) {
|
| 3413 |
if (!line.widgets) { return }
|
| 3414 |
-
var wrap = ensureLineWrapped(lineView)
|
| 3415 |
for (var i = 0, ws = line.widgets; i < ws.length; ++i) {
|
| 3416 |
-
var widget = ws[i], node = elt("div", [widget.node], "CodeMirror-linewidget")
|
| 3417 |
-
if (!widget.handleMouseEvents) { node.setAttribute("cm-ignore-events", "true") }
|
| 3418 |
-
positionLineWidget(widget, node, lineView, dims)
|
| 3419 |
-
cm.display.input.setUneditable(node)
|
| 3420 |
if (allowAbove && widget.above)
|
| 3421 |
-
{ wrap.insertBefore(node, lineView.gutter || lineView.text) }
|
| 3422 |
else
|
| 3423 |
-
{ wrap.appendChild(node) }
|
| 3424 |
-
signalLater(widget, "redraw")
|
| 3425 |
}
|
| 3426 |
}
|
| 3427 |
|
| 3428 |
function positionLineWidget(widget, node, lineView, dims) {
|
| 3429 |
if (widget.noHScroll) {
|
| 3430 |
-
|
| 3431 |
-
var width = dims.wrapperWidth
|
| 3432 |
-
node.style.left = dims.fixedPos + "px"
|
| 3433 |
if (!widget.coverGutter) {
|
| 3434 |
-
width -= dims.gutterTotalWidth
|
| 3435 |
-
node.style.paddingLeft = dims.gutterTotalWidth + "px"
|
| 3436 |
}
|
| 3437 |
-
node.style.width = width + "px"
|
| 3438 |
}
|
| 3439 |
if (widget.coverGutter) {
|
| 3440 |
-
node.style.zIndex = 5
|
| 3441 |
-
node.style.position = "relative"
|
| 3442 |
-
if (!widget.noHScroll) { node.style.marginLeft = -dims.gutterTotalWidth + "px" }
|
| 3443 |
}
|
| 3444 |
}
|
| 3445 |
|
| 3446 |
function widgetHeight(widget) {
|
| 3447 |
if (widget.height != null) { return widget.height }
|
| 3448 |
-
var cm = widget.doc.cm
|
| 3449 |
if (!cm) { return 0 }
|
| 3450 |
if (!contains(document.body, widget.node)) {
|
| 3451 |
-
var parentStyle = "position: relative;"
|
| 3452 |
if (widget.coverGutter)
|
| 3453 |
-
{ parentStyle += "margin-left: -" + cm.display.gutters.offsetWidth + "px;" }
|
| 3454 |
if (widget.noHScroll)
|
| 3455 |
-
{ parentStyle += "width: " + cm.display.wrapper.clientWidth + "px;" }
|
| 3456 |
-
removeChildrenAndAdd(cm.display.measure, elt("div", [widget.node], null, parentStyle))
|
| 3457 |
}
|
| 3458 |
return widget.height = widget.node.parentNode.offsetHeight
|
| 3459 |
}
|
|
@@ -3473,10 +3483,10 @@ webpackJsonp([2],{
|
|
| 3473 |
function paddingVert(display) {return display.mover.offsetHeight - display.lineSpace.offsetHeight}
|
| 3474 |
function paddingH(display) {
|
| 3475 |
if (display.cachedPaddingH) { return display.cachedPaddingH }
|
| 3476 |
-
var e = removeChildrenAndAdd(display.measure, elt("pre", "x"))
|
| 3477 |
-
var style = window.getComputedStyle ? window.getComputedStyle(e) : e.currentStyle
|
| 3478 |
-
var data = {left: parseInt(style.paddingLeft), right: parseInt(style.paddingRight)}
|
| 3479 |
-
if (!isNaN(data.left) && !isNaN(data.right)) { display.cachedPaddingH = data }
|
| 3480 |
return data
|
| 3481 |
}
|
| 3482 |
|
|
@@ -3493,20 +3503,20 @@ webpackJsonp([2],{
|
|
| 3493 |
// line. When lineWrapping is on, there might be more than one
|
| 3494 |
// height.
|
| 3495 |
function ensureLineHeights(cm, lineView, rect) {
|
| 3496 |
-
var wrapping = cm.options.lineWrapping
|
| 3497 |
-
var curWidth = wrapping && displayWidth(cm)
|
| 3498 |
if (!lineView.measure.heights || wrapping && lineView.measure.width != curWidth) {
|
| 3499 |
-
var heights = lineView.measure.heights = []
|
| 3500 |
if (wrapping) {
|
| 3501 |
-
lineView.measure.width = curWidth
|
| 3502 |
-
var rects = lineView.text.firstChild.getClientRects()
|
| 3503 |
for (var i = 0; i < rects.length - 1; i++) {
|
| 3504 |
-
var cur = rects[i], next = rects[i + 1]
|
| 3505 |
if (Math.abs(cur.bottom - next.bottom) > 2)
|
| 3506 |
-
{ heights.push((cur.bottom + next.top) / 2 - rect.top) }
|
| 3507 |
}
|
| 3508 |
}
|
| 3509 |
-
heights.push(rect.bottom - rect.top)
|
| 3510 |
}
|
| 3511 |
}
|
| 3512 |
|
|
@@ -3527,13 +3537,13 @@ webpackJsonp([2],{
|
|
| 3527 |
// Render a line into the hidden node display.externalMeasured. Used
|
| 3528 |
// when measurement is needed for a line that's not in the viewport.
|
| 3529 |
function updateExternalMeasurement(cm, line) {
|
| 3530 |
-
line = visualLine(line)
|
| 3531 |
-
var lineN = lineNo(line)
|
| 3532 |
-
var view = cm.display.externalMeasured = new LineView(cm.doc, line, lineN)
|
| 3533 |
-
view.lineN = lineN
|
| 3534 |
-
var built = view.built = buildLineContent(cm, view)
|
| 3535 |
-
view.text = built.pre
|
| 3536 |
-
removeChildrenAndAdd(cm.display.lineMeasure, built.pre)
|
| 3537 |
return view
|
| 3538 |
}
|
| 3539 |
|
|
@@ -3547,7 +3557,7 @@ webpackJsonp([2],{
|
|
| 3547 |
function findViewForLine(cm, lineN) {
|
| 3548 |
if (lineN >= cm.display.viewFrom && lineN < cm.display.viewTo)
|
| 3549 |
{ return cm.display.view[findViewIndex(cm, lineN)] }
|
| 3550 |
-
var ext = cm.display.externalMeasured
|
| 3551 |
if (ext && lineN >= ext.lineN && lineN < ext.lineN + ext.size)
|
| 3552 |
{ return ext }
|
| 3553 |
}
|
|
@@ -3558,18 +3568,18 @@ webpackJsonp([2],{
|
|
| 3558 |
// measurements in a row, can thus ensure that the set-up work is
|
| 3559 |
// only done once.
|
| 3560 |
function prepareMeasureForLine(cm, line) {
|
| 3561 |
-
var lineN = lineNo(line)
|
| 3562 |
-
var view = findViewForLine(cm, lineN)
|
| 3563 |
if (view && !view.text) {
|
| 3564 |
-
view = null
|
| 3565 |
} else if (view && view.changes) {
|
| 3566 |
-
updateLineForChanges(cm, view, lineN, getDimensions(cm))
|
| 3567 |
-
cm.curOp.forceUpdate = true
|
| 3568 |
}
|
| 3569 |
if (!view)
|
| 3570 |
-
{ view = updateExternalMeasurement(cm, line) }
|
| 3571 |
|
| 3572 |
-
var info = mapFromLineView(view, line, lineN)
|
| 3573 |
return {
|
| 3574 |
line: line, view: view, rect: null,
|
| 3575 |
map: info.map, cache: info.cache, before: info.before,
|
|
@@ -3580,58 +3590,58 @@ webpackJsonp([2],{
|
|
| 3580 |
// Given a prepared measurement object, measures the position of an
|
| 3581 |
// actual character (or fetches it from the cache).
|
| 3582 |
function measureCharPrepared(cm, prepared, ch, bias, varHeight) {
|
| 3583 |
-
if (prepared.before) { ch = -1 }
|
| 3584 |
-
var key = ch + (bias || ""), found
|
| 3585 |
if (prepared.cache.hasOwnProperty(key)) {
|
| 3586 |
-
found = prepared.cache[key]
|
| 3587 |
} else {
|
| 3588 |
if (!prepared.rect)
|
| 3589 |
-
{ prepared.rect = prepared.view.text.getBoundingClientRect() }
|
| 3590 |
if (!prepared.hasHeights) {
|
| 3591 |
-
ensureLineHeights(cm, prepared.view, prepared.rect)
|
| 3592 |
-
prepared.hasHeights = true
|
| 3593 |
}
|
| 3594 |
-
found = measureCharInner(cm, prepared, ch, bias)
|
| 3595 |
-
if (!found.bogus) { prepared.cache[key] = found }
|
| 3596 |
}
|
| 3597 |
return {left: found.left, right: found.right,
|
| 3598 |
top: varHeight ? found.rtop : found.top,
|
| 3599 |
bottom: varHeight ? found.rbottom : found.bottom}
|
| 3600 |
}
|
| 3601 |
|
| 3602 |
-
var nullRect = {left: 0, right: 0, top: 0, bottom: 0}
|
| 3603 |
|
| 3604 |
-
function nodeAndOffsetInLineMap(map, ch, bias) {
|
| 3605 |
-
var node, start, end, collapse, mStart, mEnd
|
| 3606 |
// First, search the line map for the text node corresponding to,
|
| 3607 |
// or closest to, the target character.
|
| 3608 |
-
for (var i = 0; i < map.length; i += 3) {
|
| 3609 |
-
mStart = map[i]
|
| 3610 |
-
mEnd = map[i + 1]
|
| 3611 |
if (ch < mStart) {
|
| 3612 |
-
start = 0; end = 1
|
| 3613 |
-
collapse = "left"
|
| 3614 |
} else if (ch < mEnd) {
|
| 3615 |
-
start = ch - mStart
|
| 3616 |
-
end = start + 1
|
| 3617 |
-
} else if (i == map.length - 3 || ch == mEnd && map[i + 3] > ch) {
|
| 3618 |
-
end = mEnd - mStart
|
| 3619 |
-
start = end - 1
|
| 3620 |
-
if (ch >= mEnd) { collapse = "right" }
|
| 3621 |
}
|
| 3622 |
if (start != null) {
|
| 3623 |
-
node = map[i + 2]
|
| 3624 |
if (mStart == mEnd && bias == (node.insertLeft ? "left" : "right"))
|
| 3625 |
-
{ collapse = bias }
|
| 3626 |
if (bias == "left" && start == 0)
|
| 3627 |
-
{ while (i && map[i - 2] == map[i - 3] && map[i - 1].insertLeft) {
|
| 3628 |
-
node = map[(i -= 3) + 2]
|
| 3629 |
-
collapse = "left"
|
| 3630 |
} }
|
| 3631 |
if (bias == "right" && start == mEnd - mStart)
|
| 3632 |
-
{ while (i < map.length - 3 && map[i + 3] == map[i + 4] && !map[i + 5].insertLeft) {
|
| 3633 |
-
node = map[(i += 3) + 2]
|
| 3634 |
-
collapse = "right"
|
| 3635 |
} }
|
| 3636 |
break
|
| 3637 |
}
|
|
@@ -3640,7 +3650,7 @@ webpackJsonp([2],{
|
|
| 3640 |
}
|
| 3641 |
|
| 3642 |
function getUsefulRect(rects, bias) {
|
| 3643 |
-
var rect = nullRect
|
| 3644 |
if (bias == "left") { for (var i = 0; i < rects.length; i++) {
|
| 3645 |
if ((rect = rects[i]).left != rect.right) { break }
|
| 3646 |
} } else { for (var i$1 = rects.length - 1; i$1 >= 0; i$1--) {
|
|
@@ -3650,52 +3660,52 @@ webpackJsonp([2],{
|
|
| 3650 |
}
|
| 3651 |
|
| 3652 |
function measureCharInner(cm, prepared, ch, bias) {
|
| 3653 |
-
var place = nodeAndOffsetInLineMap(prepared.map, ch, bias)
|
| 3654 |
-
var node = place.node, start = place.start, end = place.end, collapse = place.collapse
|
| 3655 |
|
| 3656 |
-
var rect
|
| 3657 |
if (node.nodeType == 3) { // If it is a text node, use a range to retrieve the coordinates.
|
| 3658 |
for (var i$1 = 0; i$1 < 4; i$1++) { // Retry a maximum of 4 times when nonsense rectangles are returned
|
| 3659 |
-
while (start && isExtendingChar(prepared.line.text.charAt(place.coverStart + start))) { --start }
|
| 3660 |
-
while (place.coverStart + end < place.coverEnd && isExtendingChar(prepared.line.text.charAt(place.coverStart + end))) { ++end }
|
| 3661 |
if (ie && ie_version < 9 && start == 0 && end == place.coverEnd - place.coverStart)
|
| 3662 |
-
{ rect = node.parentNode.getBoundingClientRect() }
|
| 3663 |
else
|
| 3664 |
-
{ rect = getUsefulRect(range(node, start, end).getClientRects(), bias) }
|
| 3665 |
if (rect.left || rect.right || start == 0) { break }
|
| 3666 |
-
end = start
|
| 3667 |
-
start = start - 1
|
| 3668 |
-
collapse = "right"
|
| 3669 |
}
|
| 3670 |
-
if (ie && ie_version < 11) { rect = maybeUpdateRectForZooming(cm.display.measure, rect) }
|
| 3671 |
} else { // If it is a widget, simply get the box for the whole widget.
|
| 3672 |
-
if (start > 0) { collapse = bias = "right" }
|
| 3673 |
-
var rects
|
| 3674 |
if (cm.options.lineWrapping && (rects = node.getClientRects()).length > 1)
|
| 3675 |
-
{ rect = rects[bias == "right" ? rects.length - 1 : 0] }
|
| 3676 |
else
|
| 3677 |
-
{ rect = node.getBoundingClientRect() }
|
| 3678 |
}
|
| 3679 |
if (ie && ie_version < 9 && !start && (!rect || !rect.left && !rect.right)) {
|
| 3680 |
-
var rSpan = node.parentNode.getClientRects()[0]
|
| 3681 |
if (rSpan)
|
| 3682 |
-
{ rect = {left: rSpan.left, right: rSpan.left + charWidth(cm.display), top: rSpan.top, bottom: rSpan.bottom} }
|
| 3683 |
else
|
| 3684 |
-
{ rect = nullRect }
|
| 3685 |
}
|
| 3686 |
|
| 3687 |
-
var rtop = rect.top - prepared.rect.top, rbot = rect.bottom - prepared.rect.top
|
| 3688 |
-
var mid = (rtop + rbot) / 2
|
| 3689 |
-
var heights = prepared.view.measure.heights
|
| 3690 |
-
var i = 0
|
| 3691 |
for (; i < heights.length - 1; i++)
|
| 3692 |
{ if (mid < heights[i]) { break } }
|
| 3693 |
-
var top = i ? heights[i - 1] : 0, bot = heights[i]
|
| 3694 |
var result = {left: (collapse == "right" ? rect.right : rect.left) - prepared.rect.left,
|
| 3695 |
right: (collapse == "left" ? rect.left : rect.right) - prepared.rect.left,
|
| 3696 |
-
top: top, bottom: bot}
|
| 3697 |
-
if (!rect.left && !rect.right) { result.bogus = true }
|
| 3698 |
-
if (!cm.options.singleCursorHeightPerLine) { result.rtop = rtop; result.rbottom = rbot }
|
| 3699 |
|
| 3700 |
return result
|
| 3701 |
}
|
|
@@ -3706,33 +3716,33 @@ webpackJsonp([2],{
|
|
| 3706 |
if (!window.screen || screen.logicalXDPI == null ||
|
| 3707 |
screen.logicalXDPI == screen.deviceXDPI || !hasBadZoomedRects(measure))
|
| 3708 |
{ return rect }
|
| 3709 |
-
var scaleX = screen.logicalXDPI / screen.deviceXDPI
|
| 3710 |
-
var scaleY = screen.logicalYDPI / screen.deviceYDPI
|
| 3711 |
return {left: rect.left * scaleX, right: rect.right * scaleX,
|
| 3712 |
top: rect.top * scaleY, bottom: rect.bottom * scaleY}
|
| 3713 |
}
|
| 3714 |
|
| 3715 |
function clearLineMeasurementCacheFor(lineView) {
|
| 3716 |
if (lineView.measure) {
|
| 3717 |
-
lineView.measure.cache = {}
|
| 3718 |
-
lineView.measure.heights = null
|
| 3719 |
if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)
|
| 3720 |
-
{ lineView.measure.caches[i] = {} } }
|
| 3721 |
}
|
| 3722 |
}
|
| 3723 |
|
| 3724 |
function clearLineMeasurementCache(cm) {
|
| 3725 |
-
cm.display.externalMeasure = null
|
| 3726 |
-
removeChildren(cm.display.lineMeasure)
|
| 3727 |
for (var i = 0; i < cm.display.view.length; i++)
|
| 3728 |
-
{ clearLineMeasurementCacheFor(cm.display.view[i]) }
|
| 3729 |
}
|
| 3730 |
|
| 3731 |
function clearCaches(cm) {
|
| 3732 |
-
clearLineMeasurementCache(cm)
|
| 3733 |
-
cm.display.cachedCharWidth = cm.display.cachedTextHeight = cm.display.cachedPaddingH = null
|
| 3734 |
-
if (!cm.options.lineWrapping) { cm.display.maxLineChanged = true }
|
| 3735 |
-
cm.display.lineNumChars = null
|
| 3736 |
}
|
| 3737 |
|
| 3738 |
function pageScrollX() { return window.pageXOffset || (document.documentElement || document.body).scrollLeft }
|
|
@@ -3744,21 +3754,21 @@ webpackJsonp([2],{
|
|
| 3744 |
// or "page".
|
| 3745 |
function intoCoordSystem(cm, lineObj, rect, context, includeWidgets) {
|
| 3746 |
if (!includeWidgets && lineObj.widgets) { for (var i = 0; i < lineObj.widgets.length; ++i) { if (lineObj.widgets[i].above) {
|
| 3747 |
-
var size = widgetHeight(lineObj.widgets[i])
|
| 3748 |
-
rect.top += size; rect.bottom += size
|
| 3749 |
} } }
|
| 3750 |
if (context == "line") { return rect }
|
| 3751 |
-
if (!context) { context = "local" }
|
| 3752 |
-
var yOff = heightAtLine(lineObj)
|
| 3753 |
-
if (context == "local") { yOff += paddingTop(cm.display) }
|
| 3754 |
-
else { yOff -= cm.display.viewOffset }
|
| 3755 |
if (context == "page" || context == "window") {
|
| 3756 |
-
var lOff = cm.display.lineSpace.getBoundingClientRect()
|
| 3757 |
-
yOff += lOff.top + (context == "window" ? 0 : pageScrollY())
|
| 3758 |
-
var xOff = lOff.left + (context == "window" ? 0 : pageScrollX())
|
| 3759 |
-
rect.left += xOff; rect.right += xOff
|
| 3760 |
}
|
| 3761 |
-
rect.top += yOff; rect.bottom += yOff
|
| 3762 |
return rect
|
| 3763 |
}
|
| 3764 |
|
|
@@ -3766,23 +3776,23 @@ webpackJsonp([2],{
|
|
| 3766 |
// Context may be "window", "page", "div", or "local"./null.
|
| 3767 |
function fromCoordSystem(cm, coords, context) {
|
| 3768 |
if (context == "div") { return coords }
|
| 3769 |
-
var left = coords.left, top = coords.top
|
| 3770 |
// First move into "page" coordinate system
|
| 3771 |
if (context == "page") {
|
| 3772 |
-
left -= pageScrollX()
|
| 3773 |
-
top -= pageScrollY()
|
| 3774 |
} else if (context == "local" || !context) {
|
| 3775 |
-
var localBox = cm.display.sizer.getBoundingClientRect()
|
| 3776 |
-
left += localBox.left
|
| 3777 |
-
top += localBox.top
|
| 3778 |
}
|
| 3779 |
|
| 3780 |
-
var lineSpaceBox = cm.display.lineSpace.getBoundingClientRect()
|
| 3781 |
return {left: left - lineSpaceBox.left, top: top - lineSpaceBox.top}
|
| 3782 |
}
|
| 3783 |
|
| 3784 |
function charCoords(cm, pos, context, lineObj, bias) {
|
| 3785 |
-
if (!lineObj) { lineObj = getLine(cm.doc, pos.line) }
|
| 3786 |
return intoCoordSystem(cm, lineObj, measureChar(cm, lineObj, pos.ch, bias), context)
|
| 3787 |
}
|
| 3788 |
|
|
@@ -3803,42 +3813,42 @@ webpackJsonp([2],{
|
|
| 3803 |
// Every position after the last character on a line is considered to stick
|
| 3804 |
// to the last character on the line.
|
| 3805 |
function cursorCoords(cm, pos, context, lineObj, preparedMeasure, varHeight) {
|
| 3806 |
-
lineObj = lineObj || getLine(cm.doc, pos.line)
|
| 3807 |
-
if (!preparedMeasure) { preparedMeasure = prepareMeasureForLine(cm, lineObj) }
|
| 3808 |
function get(ch, right) {
|
| 3809 |
-
var m = measureCharPrepared(cm, preparedMeasure, ch, right ? "right" : "left", varHeight)
|
| 3810 |
-
if (right) { m.left = m.right; } else { m.right = m.left }
|
| 3811 |
return intoCoordSystem(cm, lineObj, m, context)
|
| 3812 |
}
|
| 3813 |
-
var order = getOrder(lineObj), ch = pos.ch, sticky = pos.sticky
|
| 3814 |
if (ch >= lineObj.text.length) {
|
| 3815 |
-
ch = lineObj.text.length
|
| 3816 |
-
sticky = "before"
|
| 3817 |
} else if (ch <= 0) {
|
| 3818 |
-
ch = 0
|
| 3819 |
-
sticky = "after"
|
| 3820 |
}
|
| 3821 |
if (!order) { return get(sticky == "before" ? ch - 1 : ch, sticky == "before") }
|
| 3822 |
|
| 3823 |
function getBidi(ch, partPos, invert) {
|
| 3824 |
-
var part = order[partPos], right = (part.level % 2) != 0
|
| 3825 |
return get(invert ? ch - 1 : ch, right != invert)
|
| 3826 |
}
|
| 3827 |
-
var partPos = getBidiPartAt(order, ch, sticky)
|
| 3828 |
-
var other = bidiOther
|
| 3829 |
-
var val = getBidi(ch, partPos, sticky == "before")
|
| 3830 |
-
if (other != null) { val.other = getBidi(ch, other, sticky != "before") }
|
| 3831 |
return val
|
| 3832 |
}
|
| 3833 |
|
| 3834 |
// Used to cheaply estimate the coordinates for a position. Used for
|
| 3835 |
// intermediate scroll updates.
|
| 3836 |
function estimateCoords(cm, pos) {
|
| 3837 |
-
var left = 0
|
| 3838 |
-
pos = clipPos(cm.doc, pos)
|
| 3839 |
-
if (!cm.options.lineWrapping) { left = charWidth(cm.display) * pos.ch }
|
| 3840 |
-
var lineObj = getLine(cm.doc, pos.line)
|
| 3841 |
-
var top = heightAtLine(lineObj) + paddingTop(cm.display)
|
| 3842 |
return {left: left, right: left, top: top, bottom: top + lineObj.height}
|
| 3843 |
}
|
| 3844 |
|
|
@@ -3849,139 +3859,139 @@ webpackJsonp([2],{
|
|
| 3849 |
// is true, that means the coordinates lie outside the line's
|
| 3850 |
// vertical range.
|
| 3851 |
function PosWithInfo(line, ch, sticky, outside, xRel) {
|
| 3852 |
-
var pos = Pos(line, ch, sticky)
|
| 3853 |
-
pos.xRel = xRel
|
| 3854 |
-
if (outside) { pos.outside = true }
|
| 3855 |
return pos
|
| 3856 |
}
|
| 3857 |
|
| 3858 |
// Compute the character position closest to the given coordinates.
|
| 3859 |
// Input must be lineSpace-local ("div" coordinate system).
|
| 3860 |
function coordsChar(cm, x, y) {
|
| 3861 |
-
var doc = cm.doc
|
| 3862 |
-
y += cm.display.viewOffset
|
| 3863 |
if (y < 0) { return PosWithInfo(doc.first, 0, null, true, -1) }
|
| 3864 |
-
var lineN = lineAtHeight(doc, y), last = doc.first + doc.size - 1
|
| 3865 |
if (lineN > last)
|
| 3866 |
{ return PosWithInfo(doc.first + doc.size - 1, getLine(doc, last).text.length, null, true, 1) }
|
| 3867 |
-
if (x < 0) { x = 0 }
|
| 3868 |
|
| 3869 |
-
var lineObj = getLine(doc, lineN)
|
| 3870 |
for (;;) {
|
| 3871 |
-
var found = coordsCharInner(cm, lineObj, lineN, x, y)
|
| 3872 |
-
var merged = collapsedSpanAtEnd(lineObj)
|
| 3873 |
-
var mergedPos = merged && merged.find(0, true)
|
| 3874 |
if (merged && (found.ch > mergedPos.from.ch || found.ch == mergedPos.from.ch && found.xRel > 0))
|
| 3875 |
-
{ lineN = lineNo(lineObj = mergedPos.to.line) }
|
| 3876 |
else
|
| 3877 |
{ return found }
|
| 3878 |
}
|
| 3879 |
}
|
| 3880 |
|
| 3881 |
function wrappedLineExtent(cm, lineObj, preparedMeasure, y) {
|
| 3882 |
-
var measure = function (ch) { return intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, ch), "line"); }
|
| 3883 |
-
var end = lineObj.text.length
|
| 3884 |
-
var begin = findFirst(function (ch) { return measure(ch - 1).bottom <= y; }, end, 0)
|
| 3885 |
-
end = findFirst(function (ch) { return measure(ch).top > y; }, begin, end)
|
| 3886 |
return {begin: begin, end: end}
|
| 3887 |
}
|
| 3888 |
|
| 3889 |
function wrappedLineExtentChar(cm, lineObj, preparedMeasure, target) {
|
| 3890 |
-
var targetTop = intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, target), "line").top
|
| 3891 |
return wrappedLineExtent(cm, lineObj, preparedMeasure, targetTop)
|
| 3892 |
}
|
| 3893 |
|
| 3894 |
-
function coordsCharInner(cm, lineObj, lineNo, x, y) {
|
| 3895 |
-
y -= heightAtLine(lineObj)
|
| 3896 |
-
var begin = 0, end = lineObj.text.length
|
| 3897 |
-
var preparedMeasure = prepareMeasureForLine(cm, lineObj)
|
| 3898 |
-
var pos
|
| 3899 |
-
var order = getOrder(lineObj)
|
| 3900 |
if (order) {
|
| 3901 |
if (cm.options.lineWrapping) {
|
| 3902 |
-
|
| 3903 |
-
((assign = wrappedLineExtent(cm, lineObj, preparedMeasure, y), begin = assign.begin, end = assign.end, assign))
|
| 3904 |
}
|
| 3905 |
-
pos = new Pos(lineNo, begin)
|
| 3906 |
-
var beginLeft = cursorCoords(cm, pos, "line", lineObj, preparedMeasure).left
|
| 3907 |
-
var dir = beginLeft < x ? 1 : -1
|
| 3908 |
-
var prevDiff, diff = beginLeft - x, prevPos
|
| 3909 |
do {
|
| 3910 |
-
prevDiff = diff
|
| 3911 |
-
prevPos = pos
|
| 3912 |
-
pos = moveVisually(cm, lineObj, pos, dir)
|
| 3913 |
if (pos == null || pos.ch < begin || end <= (pos.sticky == "before" ? pos.ch - 1 : pos.ch)) {
|
| 3914 |
-
pos = prevPos
|
| 3915 |
break
|
| 3916 |
}
|
| 3917 |
-
diff = cursorCoords(cm, pos, "line", lineObj, preparedMeasure).left - x
|
| 3918 |
} while ((dir < 0) != (diff < 0) && (Math.abs(diff) <= Math.abs(prevDiff)))
|
| 3919 |
if (Math.abs(diff) > Math.abs(prevDiff)) {
|
| 3920 |
if ((diff < 0) == (prevDiff < 0)) { throw new Error("Broke out of infinite loop in coordsCharInner") }
|
| 3921 |
-
pos = prevPos
|
| 3922 |
}
|
| 3923 |
} else {
|
| 3924 |
var ch = findFirst(function (ch) {
|
| 3925 |
-
var box = intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, ch), "line")
|
| 3926 |
if (box.top > y) {
|
| 3927 |
// For the cursor stickiness
|
| 3928 |
-
end = Math.min(ch, end)
|
| 3929 |
return true
|
| 3930 |
}
|
| 3931 |
else if (box.bottom <= y) { return false }
|
| 3932 |
else if (box.left > x) { return true }
|
| 3933 |
else if (box.right < x) { return false }
|
| 3934 |
else { return (x - box.left < box.right - x) }
|
| 3935 |
-
}, begin, end)
|
| 3936 |
-
ch = skipExtendingChars(lineObj.text, ch, 1)
|
| 3937 |
-
pos = new Pos(lineNo, ch, ch == end ? "before" : "after")
|
| 3938 |
}
|
| 3939 |
-
var coords = cursorCoords(cm, pos, "line", lineObj, preparedMeasure)
|
| 3940 |
-
if (y < coords.top || coords.bottom < y) { pos.outside = true }
|
| 3941 |
-
pos.xRel = x < coords.left ? -1 : (x > coords.right ? 1 : 0)
|
| 3942 |
return pos
|
| 3943 |
}
|
| 3944 |
|
| 3945 |
-
var measureText
|
| 3946 |
// Compute the default text height.
|
| 3947 |
function textHeight(display) {
|
| 3948 |
if (display.cachedTextHeight != null) { return display.cachedTextHeight }
|
| 3949 |
if (measureText == null) {
|
| 3950 |
-
measureText = elt("pre")
|
| 3951 |
// Measure a bunch of lines, for browsers that compute
|
| 3952 |
// fractional heights.
|
| 3953 |
for (var i = 0; i < 49; ++i) {
|
| 3954 |
-
measureText.appendChild(document.createTextNode("x"))
|
| 3955 |
-
measureText.appendChild(elt("br"))
|
| 3956 |
}
|
| 3957 |
-
measureText.appendChild(document.createTextNode("x"))
|
| 3958 |
}
|
| 3959 |
-
removeChildrenAndAdd(display.measure, measureText)
|
| 3960 |
-
var height = measureText.offsetHeight / 50
|
| 3961 |
-
if (height > 3) { display.cachedTextHeight = height }
|
| 3962 |
-
removeChildren(display.measure)
|
| 3963 |
return height || 1
|
| 3964 |
}
|
| 3965 |
|
| 3966 |
// Compute the default character width.
|
| 3967 |
function charWidth(display) {
|
| 3968 |
if (display.cachedCharWidth != null) { return display.cachedCharWidth }
|
| 3969 |
-
var anchor = elt("span", "xxxxxxxxxx")
|
| 3970 |
-
var pre = elt("pre", [anchor])
|
| 3971 |
-
removeChildrenAndAdd(display.measure, pre)
|
| 3972 |
-
var rect = anchor.getBoundingClientRect(), width = (rect.right - rect.left) / 10
|
| 3973 |
-
if (width > 2) { display.cachedCharWidth = width }
|
| 3974 |
return width || 10
|
| 3975 |
}
|
| 3976 |
|
| 3977 |
// Do a bulk-read of the DOM positions and sizes needed to draw the
|
| 3978 |
// view, so that we don't interleave reading and writing to the DOM.
|
| 3979 |
function getDimensions(cm) {
|
| 3980 |
-
var d = cm.display, left = {}, width = {}
|
| 3981 |
-
var gutterLeft = d.gutters.clientLeft
|
| 3982 |
for (var n = d.gutters.firstChild, i = 0; n; n = n.nextSibling, ++i) {
|
| 3983 |
-
left[cm.options.gutters[i]] = n.offsetLeft + n.clientLeft + gutterLeft
|
| 3984 |
-
width[cm.options.gutters[i]] = n.clientWidth
|
| 3985 |
}
|
| 3986 |
return {fixedPos: compensateForHScroll(d),
|
| 3987 |
gutterTotalWidth: d.gutters.offsetWidth,
|
|
@@ -4001,14 +4011,14 @@ webpackJsonp([2],{
|
|
| 4001 |
// first approximation until the line becomes visible (and is thus
|
| 4002 |
// properly measurable).
|
| 4003 |
function estimateHeight(cm) {
|
| 4004 |
-
var th = textHeight(cm.display), wrapping = cm.options.lineWrapping
|
| 4005 |
-
var perLine = wrapping && Math.max(5, cm.display.scroller.clientWidth / charWidth(cm.display) - 3)
|
| 4006 |
return function (line) {
|
| 4007 |
if (lineIsHidden(cm.doc, line)) { return 0 }
|
| 4008 |
|
| 4009 |
-
var widgetsHeight = 0
|
| 4010 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; i++) {
|
| 4011 |
-
if (line.widgets[i].height) { widgetsHeight += line.widgets[i].height }
|
| 4012 |
} }
|
| 4013 |
|
| 4014 |
if (wrapping)
|
|
@@ -4019,11 +4029,11 @@ webpackJsonp([2],{
|
|
| 4019 |
}
|
| 4020 |
|
| 4021 |
function estimateLineHeights(cm) {
|
| 4022 |
-
var doc = cm.doc, est = estimateHeight(cm)
|
| 4023 |
doc.iter(function (line) {
|
| 4024 |
-
var estHeight = est(line)
|
| 4025 |
-
if (estHeight != line.height) { updateLineHeight(line, estHeight) }
|
| 4026 |
-
})
|
| 4027 |
}
|
| 4028 |
|
| 4029 |
// Given a mouse event, find the corresponding position. If liberal
|
|
@@ -4032,17 +4042,17 @@ webpackJsonp([2],{
|
|
| 4032 |
// selections, and tries to estimate a character position even for
|
| 4033 |
// coordinates beyond the right of the text.
|
| 4034 |
function posFromMouse(cm, e, liberal, forRect) {
|
| 4035 |
-
var display = cm.display
|
| 4036 |
if (!liberal && e_target(e).getAttribute("cm-not-content") == "true") { return null }
|
| 4037 |
|
| 4038 |
-
var x, y, space = display.lineSpace.getBoundingClientRect()
|
| 4039 |
// Fails unpredictably on IE[67] when mouse is dragged around quickly.
|
| 4040 |
-
try { x = e.clientX - space.left; y = e.clientY - space.top }
|
| 4041 |
catch (e) { return null }
|
| 4042 |
-
var coords = coordsChar(cm, x, y), line
|
| 4043 |
if (forRect && coords.xRel == 1 && (line = getLine(cm.doc, coords.line).text).length == coords.ch) {
|
| 4044 |
-
var colDiff = countColumn(line, line.length, cm.options.tabSize) - line.length
|
| 4045 |
-
coords = Pos(coords.line, Math.max(0, Math.round((x - paddingH(cm.display).left) / charWidth(cm.display)) - colDiff))
|
| 4046 |
}
|
| 4047 |
return coords
|
| 4048 |
}
|
|
@@ -4051,206 +4061,206 @@ webpackJsonp([2],{
|
|
| 4051 |
// when the line isn't visible.
|
| 4052 |
function findViewIndex(cm, n) {
|
| 4053 |
if (n >= cm.display.viewTo) { return null }
|
| 4054 |
-
n -= cm.display.viewFrom
|
| 4055 |
if (n < 0) { return null }
|
| 4056 |
-
var view = cm.display.view
|
| 4057 |
for (var i = 0; i < view.length; i++) {
|
| 4058 |
-
n -= view[i].size
|
| 4059 |
if (n < 0) { return i }
|
| 4060 |
}
|
| 4061 |
}
|
| 4062 |
|
| 4063 |
function updateSelection(cm) {
|
| 4064 |
-
cm.display.input.showSelection(cm.display.input.prepareSelection())
|
| 4065 |
}
|
| 4066 |
|
| 4067 |
function prepareSelection(cm, primary) {
|
| 4068 |
-
var doc = cm.doc, result = {}
|
| 4069 |
-
var curFragment = result.cursors = document.createDocumentFragment()
|
| 4070 |
-
var selFragment = result.selection = document.createDocumentFragment()
|
| 4071 |
|
| 4072 |
for (var i = 0; i < doc.sel.ranges.length; i++) {
|
| 4073 |
if (primary === false && i == doc.sel.primIndex) { continue }
|
| 4074 |
-
var range = doc.sel.ranges[i]
|
| 4075 |
-
if (range.from().line >= cm.display.viewTo || range.to().line < cm.display.viewFrom) { continue }
|
| 4076 |
-
var collapsed = range.empty()
|
| 4077 |
if (collapsed || cm.options.showCursorWhenSelecting)
|
| 4078 |
-
{ drawSelectionCursor(cm, range.head, curFragment) }
|
| 4079 |
if (!collapsed)
|
| 4080 |
-
{ drawSelectionRange(cm, range, selFragment) }
|
| 4081 |
}
|
| 4082 |
return result
|
| 4083 |
}
|
| 4084 |
|
| 4085 |
// Draws a cursor for the given range
|
| 4086 |
function drawSelectionCursor(cm, head, output) {
|
| 4087 |
-
var pos = cursorCoords(cm, head, "div", null, null, !cm.options.singleCursorHeightPerLine)
|
| 4088 |
|
| 4089 |
-
var cursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor"))
|
| 4090 |
-
cursor.style.left = pos.left + "px"
|
| 4091 |
-
cursor.style.top = pos.top + "px"
|
| 4092 |
-
cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + "px"
|
| 4093 |
|
| 4094 |
if (pos.other) {
|
| 4095 |
// Secondary cursor, shown when on a 'jump' in bi-directional text
|
| 4096 |
-
var otherCursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor CodeMirror-secondarycursor"))
|
| 4097 |
-
otherCursor.style.display = ""
|
| 4098 |
-
otherCursor.style.left = pos.other.left + "px"
|
| 4099 |
-
otherCursor.style.top = pos.other.top + "px"
|
| 4100 |
-
otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + "px"
|
| 4101 |
}
|
| 4102 |
}
|
| 4103 |
|
| 4104 |
// Draws the given range as a highlighted selection
|
| 4105 |
-
function drawSelectionRange(cm, range, output) {
|
| 4106 |
-
var display = cm.display, doc = cm.doc
|
| 4107 |
-
var fragment = document.createDocumentFragment()
|
| 4108 |
-
var padding = paddingH(cm.display), leftSide = padding.left
|
| 4109 |
-
var rightSide = Math.max(display.sizerWidth, displayWidth(cm) - display.sizer.offsetLeft) - padding.right
|
| 4110 |
|
| 4111 |
function add(left, top, width, bottom) {
|
| 4112 |
-
if (top < 0) { top = 0 }
|
| 4113 |
-
top = Math.round(top)
|
| 4114 |
-
bottom = Math.round(bottom)
|
| 4115 |
-
fragment.appendChild(elt("div", null, "CodeMirror-selected", ("position: absolute; left: " + left + "px;\n top: " + top + "px; width: " + (width == null ? rightSide - left : width) + "px;\n height: " + (bottom - top) + "px")))
|
| 4116 |
}
|
| 4117 |
|
| 4118 |
function drawForLine(line, fromArg, toArg) {
|
| 4119 |
-
var lineObj = getLine(doc, line)
|
| 4120 |
-
var lineLen = lineObj.text.length
|
| 4121 |
-
var start, end
|
| 4122 |
function coords(ch, bias) {
|
| 4123 |
return charCoords(cm, Pos(line, ch), "div", lineObj, bias)
|
| 4124 |
}
|
| 4125 |
|
| 4126 |
-
iterateBidiSections(getOrder(lineObj), fromArg || 0, toArg == null ? lineLen : toArg, function (from, to, dir) {
|
| 4127 |
-
var leftPos = coords(from, "left"), rightPos, left, right
|
| 4128 |
if (from == to) {
|
| 4129 |
-
rightPos = leftPos
|
| 4130 |
-
left = right = leftPos.left
|
| 4131 |
} else {
|
| 4132 |
-
rightPos = coords(to - 1, "right")
|
| 4133 |
-
if (dir == "rtl") { var tmp = leftPos; leftPos = rightPos; rightPos = tmp }
|
| 4134 |
-
left = leftPos.left
|
| 4135 |
-
right = rightPos.right
|
| 4136 |
}
|
| 4137 |
-
if (fromArg == null && from == 0) { left = leftSide }
|
| 4138 |
if (rightPos.top - leftPos.top > 3) { // Different lines, draw top part
|
| 4139 |
-
add(left, leftPos.top, null, leftPos.bottom)
|
| 4140 |
-
left = leftSide
|
| 4141 |
-
if (leftPos.bottom < rightPos.top) { add(left, leftPos.bottom, null, rightPos.top) }
|
| 4142 |
}
|
| 4143 |
-
if (toArg == null && to == lineLen) { right = rightSide }
|
| 4144 |
if (!start || leftPos.top < start.top || leftPos.top == start.top && leftPos.left < start.left)
|
| 4145 |
-
{ start = leftPos }
|
| 4146 |
if (!end || rightPos.bottom > end.bottom || rightPos.bottom == end.bottom && rightPos.right > end.right)
|
| 4147 |
-
{ end = rightPos }
|
| 4148 |
-
if (left < leftSide + 1) { left = leftSide }
|
| 4149 |
-
add(left, rightPos.top, right - left, rightPos.bottom)
|
| 4150 |
-
})
|
| 4151 |
return {start: start, end: end}
|
| 4152 |
}
|
| 4153 |
|
| 4154 |
-
var sFrom = range.from(), sTo = range.to()
|
| 4155 |
if (sFrom.line == sTo.line) {
|
| 4156 |
-
drawForLine(sFrom.line, sFrom.ch, sTo.ch)
|
| 4157 |
} else {
|
| 4158 |
-
var fromLine = getLine(doc, sFrom.line), toLine = getLine(doc, sTo.line)
|
| 4159 |
-
var singleVLine = visualLine(fromLine) == visualLine(toLine)
|
| 4160 |
-
var leftEnd = drawForLine(sFrom.line, sFrom.ch, singleVLine ? fromLine.text.length + 1 : null).end
|
| 4161 |
-
var rightStart = drawForLine(sTo.line, singleVLine ? 0 : null, sTo.ch).start
|
| 4162 |
if (singleVLine) {
|
| 4163 |
if (leftEnd.top < rightStart.top - 2) {
|
| 4164 |
-
add(leftEnd.right, leftEnd.top, null, leftEnd.bottom)
|
| 4165 |
-
add(leftSide, rightStart.top, rightStart.left, rightStart.bottom)
|
| 4166 |
} else {
|
| 4167 |
-
add(leftEnd.right, leftEnd.top, rightStart.left - leftEnd.right, leftEnd.bottom)
|
| 4168 |
}
|
| 4169 |
}
|
| 4170 |
if (leftEnd.bottom < rightStart.top)
|
| 4171 |
-
{ add(leftSide, leftEnd.bottom, null, rightStart.top) }
|
| 4172 |
}
|
| 4173 |
|
| 4174 |
-
output.appendChild(fragment)
|
| 4175 |
}
|
| 4176 |
|
| 4177 |
// Cursor-blinking
|
| 4178 |
function restartBlink(cm) {
|
| 4179 |
if (!cm.state.focused) { return }
|
| 4180 |
-
var display = cm.display
|
| 4181 |
-
clearInterval(display.blinker)
|
| 4182 |
-
var on = true
|
| 4183 |
-
display.cursorDiv.style.visibility = ""
|
| 4184 |
if (cm.options.cursorBlinkRate > 0)
|
| 4185 |
{ display.blinker = setInterval(function () { return display.cursorDiv.style.visibility = (on = !on) ? "" : "hidden"; },
|
| 4186 |
-
cm.options.cursorBlinkRate) }
|
| 4187 |
else if (cm.options.cursorBlinkRate < 0)
|
| 4188 |
-
{ display.cursorDiv.style.visibility = "hidden" }
|
| 4189 |
}
|
| 4190 |
|
| 4191 |
function ensureFocus(cm) {
|
| 4192 |
-
if (!cm.state.focused) { cm.display.input.focus(); onFocus(cm) }
|
| 4193 |
}
|
| 4194 |
|
| 4195 |
function delayBlurEvent(cm) {
|
| 4196 |
-
cm.state.delayingBlurEvent = true
|
| 4197 |
setTimeout(function () { if (cm.state.delayingBlurEvent) {
|
| 4198 |
-
cm.state.delayingBlurEvent = false
|
| 4199 |
-
onBlur(cm)
|
| 4200 |
-
} }, 100)
|
| 4201 |
}
|
| 4202 |
|
| 4203 |
function onFocus(cm, e) {
|
| 4204 |
-
if (cm.state.delayingBlurEvent) { cm.state.delayingBlurEvent = false }
|
| 4205 |
|
| 4206 |
if (cm.options.readOnly == "nocursor") { return }
|
| 4207 |
if (!cm.state.focused) {
|
| 4208 |
-
signal(cm, "focus", cm, e)
|
| 4209 |
-
cm.state.focused = true
|
| 4210 |
-
addClass(cm.display.wrapper, "CodeMirror-focused")
|
| 4211 |
// This test prevents this from firing when a context
|
| 4212 |
// menu is closed (since the input reset would kill the
|
| 4213 |
// select-all detection hack)
|
| 4214 |
if (!cm.curOp && cm.display.selForContextMenu != cm.doc.sel) {
|
| 4215 |
-
cm.display.input.reset()
|
| 4216 |
-
if (webkit) { setTimeout(function () { return cm.display.input.reset(true); }, 20) } // Issue #1730
|
| 4217 |
}
|
| 4218 |
-
cm.display.input.receivedFocus()
|
| 4219 |
}
|
| 4220 |
-
restartBlink(cm)
|
| 4221 |
}
|
| 4222 |
function onBlur(cm, e) {
|
| 4223 |
if (cm.state.delayingBlurEvent) { return }
|
| 4224 |
|
| 4225 |
if (cm.state.focused) {
|
| 4226 |
-
signal(cm, "blur", cm, e)
|
| 4227 |
-
cm.state.focused = false
|
| 4228 |
-
rmClass(cm.display.wrapper, "CodeMirror-focused")
|
| 4229 |
}
|
| 4230 |
-
clearInterval(cm.display.blinker)
|
| 4231 |
-
setTimeout(function () { if (!cm.state.focused) { cm.display.shift = false } }, 150)
|
| 4232 |
}
|
| 4233 |
|
| 4234 |
// Re-align line numbers and gutter marks to compensate for
|
| 4235 |
// horizontal scrolling.
|
| 4236 |
function alignHorizontally(cm) {
|
| 4237 |
-
var display = cm.display, view = display.view
|
| 4238 |
if (!display.alignWidgets && (!display.gutters.firstChild || !cm.options.fixedGutter)) { return }
|
| 4239 |
-
var comp = compensateForHScroll(display) - display.scroller.scrollLeft + cm.doc.scrollLeft
|
| 4240 |
-
var gutterW = display.gutters.offsetWidth, left = comp + "px"
|
| 4241 |
for (var i = 0; i < view.length; i++) { if (!view[i].hidden) {
|
| 4242 |
if (cm.options.fixedGutter) {
|
| 4243 |
if (view[i].gutter)
|
| 4244 |
-
{ view[i].gutter.style.left = left }
|
| 4245 |
if (view[i].gutterBackground)
|
| 4246 |
-
{ view[i].gutterBackground.style.left = left }
|
| 4247 |
}
|
| 4248 |
-
var align = view[i].alignable
|
| 4249 |
if (align) { for (var j = 0; j < align.length; j++)
|
| 4250 |
-
{ align[j].style.left = left } }
|
| 4251 |
} }
|
| 4252 |
if (cm.options.fixedGutter)
|
| 4253 |
-
{ display.gutters.style.left = (comp + gutterW) + "px" }
|
| 4254 |
}
|
| 4255 |
|
| 4256 |
// Used to ensure that the line number gutter is still the right
|
|
@@ -4258,17 +4268,17 @@ webpackJsonp([2],{
|
|
| 4258 |
// is needed.
|
| 4259 |
function maybeUpdateLineNumberWidth(cm) {
|
| 4260 |
if (!cm.options.lineNumbers) { return false }
|
| 4261 |
-
var doc = cm.doc, last = lineNumberFor(cm.options, doc.first + doc.size - 1), display = cm.display
|
| 4262 |
if (last.length != display.lineNumChars) {
|
| 4263 |
var test = display.measure.appendChild(elt("div", [elt("div", last)],
|
| 4264 |
-
"CodeMirror-linenumber CodeMirror-gutter-elt"))
|
| 4265 |
-
var innerW = test.firstChild.offsetWidth, padding = test.offsetWidth - innerW
|
| 4266 |
-
display.lineGutter.style.width = ""
|
| 4267 |
-
display.lineNumInnerWidth = Math.max(innerW, display.lineGutter.offsetWidth - padding) + 1
|
| 4268 |
-
display.lineNumWidth = display.lineNumInnerWidth + padding
|
| 4269 |
-
display.lineNumChars = display.lineNumInnerWidth ? last.length : -1
|
| 4270 |
-
display.lineGutter.style.width = display.lineNumWidth + "px"
|
| 4271 |
-
updateGutterSpace(cm)
|
| 4272 |
return true
|
| 4273 |
}
|
| 4274 |
return false
|
|
@@ -4277,26 +4287,26 @@ webpackJsonp([2],{
|
|
| 4277 |
// Read the actual heights of the rendered lines, and update their
|
| 4278 |
// stored heights to match.
|
| 4279 |
function updateHeightsInViewport(cm) {
|
| 4280 |
-
var display = cm.display
|
| 4281 |
-
var prevBottom = display.lineDiv.offsetTop
|
| 4282 |
for (var i = 0; i < display.view.length; i++) {
|
| 4283 |
-
var cur = display.view[i], height = (void 0)
|
| 4284 |
if (cur.hidden) { continue }
|
| 4285 |
if (ie && ie_version < 8) {
|
| 4286 |
-
var bot = cur.node.offsetTop + cur.node.offsetHeight
|
| 4287 |
-
height = bot - prevBottom
|
| 4288 |
-
prevBottom = bot
|
| 4289 |
} else {
|
| 4290 |
-
var box = cur.node.getBoundingClientRect()
|
| 4291 |
-
height = box.bottom - box.top
|
| 4292 |
}
|
| 4293 |
-
var diff = cur.line.height - height
|
| 4294 |
-
if (height < 2) { height = textHeight(display) }
|
| 4295 |
if (diff > .001 || diff < -.001) {
|
| 4296 |
-
updateLineHeight(cur.line, height)
|
| 4297 |
-
updateWidgetHeight(cur.line)
|
| 4298 |
if (cur.rest) { for (var j = 0; j < cur.rest.length; j++)
|
| 4299 |
-
{ updateWidgetHeight(cur.rest[j]) } }
|
| 4300 |
}
|
| 4301 |
}
|
| 4302 |
}
|
|
@@ -4305,28 +4315,28 @@ webpackJsonp([2],{
|
|
| 4305 |
// given line.
|
| 4306 |
function updateWidgetHeight(line) {
|
| 4307 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; ++i)
|
| 4308 |
-
{ line.widgets[i].height = line.widgets[i].node.parentNode.offsetHeight } }
|
| 4309 |
}
|
| 4310 |
|
| 4311 |
// Compute the lines that are visible in a given viewport (defaults
|
| 4312 |
// the the current scroll position). viewport may contain top,
|
| 4313 |
// height, and ensure (see op.scrollToPos) properties.
|
| 4314 |
function visibleLines(display, doc, viewport) {
|
| 4315 |
-
var top = viewport && viewport.top != null ? Math.max(0, viewport.top) : display.scroller.scrollTop
|
| 4316 |
-
top = Math.floor(top - paddingTop(display))
|
| 4317 |
-
var bottom = viewport && viewport.bottom != null ? viewport.bottom : top + display.wrapper.clientHeight
|
| 4318 |
|
| 4319 |
-
var from = lineAtHeight(doc, top), to = lineAtHeight(doc, bottom)
|
| 4320 |
// Ensure is a {from: {line, ch}, to: {line, ch}} object, and
|
| 4321 |
// forces those lines into the viewport (if possible).
|
| 4322 |
if (viewport && viewport.ensure) {
|
| 4323 |
-
var ensureFrom = viewport.ensure.from.line, ensureTo = viewport.ensure.to.line
|
| 4324 |
if (ensureFrom < from) {
|
| 4325 |
-
from = ensureFrom
|
| 4326 |
-
to = lineAtHeight(doc, heightAtLine(getLine(doc, ensureFrom)) + display.wrapper.clientHeight)
|
| 4327 |
} else if (Math.min(ensureTo, doc.lastLine()) >= to) {
|
| 4328 |
-
from = lineAtHeight(doc, heightAtLine(getLine(doc, ensureTo)) - display.wrapper.clientHeight)
|
| 4329 |
-
to = ensureTo
|
| 4330 |
}
|
| 4331 |
}
|
| 4332 |
return {from: from, to: Math.max(to, from + 1)}
|
|
@@ -4336,22 +4346,22 @@ webpackJsonp([2],{
|
|
| 4336 |
// covers the visible area.
|
| 4337 |
function setScrollTop(cm, val) {
|
| 4338 |
if (Math.abs(cm.doc.scrollTop - val) < 2) { return }
|
| 4339 |
-
cm.doc.scrollTop = val
|
| 4340 |
-
if (!gecko) { updateDisplaySimple(cm, {top: val}) }
|
| 4341 |
-
if (cm.display.scroller.scrollTop != val) { cm.display.scroller.scrollTop = val }
|
| 4342 |
-
cm.display.scrollbars.setScrollTop(val)
|
| 4343 |
-
if (gecko) { updateDisplaySimple(cm) }
|
| 4344 |
-
startWorker(cm, 100)
|
| 4345 |
}
|
| 4346 |
// Sync scroller and scrollbar, ensure the gutter elements are
|
| 4347 |
// aligned.
|
| 4348 |
function setScrollLeft(cm, val, isScroller) {
|
| 4349 |
if (isScroller ? val == cm.doc.scrollLeft : Math.abs(cm.doc.scrollLeft - val) < 2) { return }
|
| 4350 |
-
val = Math.min(val, cm.display.scroller.scrollWidth - cm.display.scroller.clientWidth)
|
| 4351 |
-
cm.doc.scrollLeft = val
|
| 4352 |
-
alignHorizontally(cm)
|
| 4353 |
-
if (cm.display.scroller.scrollLeft != val) { cm.display.scroller.scrollLeft = val }
|
| 4354 |
-
cm.display.scrollbars.setScrollLeft(val)
|
| 4355 |
}
|
| 4356 |
|
| 4357 |
// Since the delta values reported on mouse wheel events are
|
|
@@ -4371,32 +4381,32 @@ webpackJsonp([2],{
|
|
| 4371 |
// know one. These don't have to be accurate -- the result of them
|
| 4372 |
// being wrong would just be a slight flicker on the first wheel
|
| 4373 |
// scroll (if it is large enough).
|
| 4374 |
-
if (ie) { wheelPixelsPerUnit = -.53 }
|
| 4375 |
-
else if (gecko) { wheelPixelsPerUnit = 15 }
|
| 4376 |
-
else if (chrome) { wheelPixelsPerUnit = -.7 }
|
| 4377 |
-
else if (safari) { wheelPixelsPerUnit = -1/3 }
|
| 4378 |
|
| 4379 |
function wheelEventDelta(e) {
|
| 4380 |
-
var dx = e.wheelDeltaX, dy = e.wheelDeltaY
|
| 4381 |
-
if (dx == null && e.detail && e.axis == e.HORIZONTAL_AXIS) { dx = e.detail }
|
| 4382 |
-
if (dy == null && e.detail && e.axis == e.VERTICAL_AXIS) { dy = e.detail }
|
| 4383 |
-
else if (dy == null) { dy = e.wheelDelta }
|
| 4384 |
return {x: dx, y: dy}
|
| 4385 |
}
|
| 4386 |
function wheelEventPixels(e) {
|
| 4387 |
-
var delta = wheelEventDelta(e)
|
| 4388 |
-
delta.x *= wheelPixelsPerUnit
|
| 4389 |
-
delta.y *= wheelPixelsPerUnit
|
| 4390 |
return delta
|
| 4391 |
}
|
| 4392 |
|
| 4393 |
function onScrollWheel(cm, e) {
|
| 4394 |
-
var delta = wheelEventDelta(e), dx = delta.x, dy = delta.y
|
| 4395 |
|
| 4396 |
-
var display = cm.display, scroll = display.scroller
|
| 4397 |
// Quit if there's nothing to scroll here
|
| 4398 |
-
var canScrollX = scroll.scrollWidth > scroll.clientWidth
|
| 4399 |
-
var canScrollY = scroll.scrollHeight > scroll.clientHeight
|
| 4400 |
if (!(dx && canScrollX || dy && canScrollY)) { return }
|
| 4401 |
|
| 4402 |
// Webkit browsers on OS X abort momentum scrolls when the target
|
|
@@ -4407,7 +4417,7 @@ webpackJsonp([2],{
|
|
| 4407 |
outer: for (var cur = e.target, view = display.view; cur != scroll; cur = cur.parentNode) {
|
| 4408 |
for (var i = 0; i < view.length; i++) {
|
| 4409 |
if (view[i].node == cur) {
|
| 4410 |
-
cm.display.currentWheelTarget = cur
|
| 4411 |
break outer
|
| 4412 |
}
|
| 4413 |
}
|
|
@@ -4422,45 +4432,45 @@ webpackJsonp([2],{
|
|
| 4422 |
// better than glitching out.
|
| 4423 |
if (dx && !gecko && !presto && wheelPixelsPerUnit != null) {
|
| 4424 |
if (dy && canScrollY)
|
| 4425 |
-
{ setScrollTop(cm, Math.max(0, Math.min(scroll.scrollTop + dy * wheelPixelsPerUnit, scroll.scrollHeight - scroll.clientHeight))) }
|
| 4426 |
-
setScrollLeft(cm, Math.max(0, Math.min(scroll.scrollLeft + dx * wheelPixelsPerUnit, scroll.scrollWidth - scroll.clientWidth)))
|
| 4427 |
// Only prevent default scrolling if vertical scrolling is
|
| 4428 |
// actually possible. Otherwise, it causes vertical scroll
|
| 4429 |
// jitter on OSX trackpads when deltaX is small and deltaY
|
| 4430 |
// is large (issue #3579)
|
| 4431 |
if (!dy || (dy && canScrollY))
|
| 4432 |
-
{ e_preventDefault(e) }
|
| 4433 |
-
display.wheelStartX = null // Abort measurement, if in progress
|
| 4434 |
return
|
| 4435 |
}
|
| 4436 |
|
| 4437 |
// 'Project' the visible viewport to cover the area that is being
|
| 4438 |
// scrolled into view (if we know enough to estimate it).
|
| 4439 |
if (dy && wheelPixelsPerUnit != null) {
|
| 4440 |
-
var pixels = dy * wheelPixelsPerUnit
|
| 4441 |
-
var top = cm.doc.scrollTop, bot = top + display.wrapper.clientHeight
|
| 4442 |
-
if (pixels < 0) { top = Math.max(0, top + pixels - 50) }
|
| 4443 |
-
else { bot = Math.min(cm.doc.height, bot + pixels + 50) }
|
| 4444 |
-
updateDisplaySimple(cm, {top: top, bottom: bot})
|
| 4445 |
}
|
| 4446 |
|
| 4447 |
if (wheelSamples < 20) {
|
| 4448 |
if (display.wheelStartX == null) {
|
| 4449 |
-
display.wheelStartX = scroll.scrollLeft; display.wheelStartY = scroll.scrollTop
|
| 4450 |
-
display.wheelDX = dx; display.wheelDY = dy
|
| 4451 |
setTimeout(function () {
|
| 4452 |
if (display.wheelStartX == null) { return }
|
| 4453 |
-
var movedX = scroll.scrollLeft - display.wheelStartX
|
| 4454 |
-
var movedY = scroll.scrollTop - display.wheelStartY
|
| 4455 |
var sample = (movedY && display.wheelDY && movedY / display.wheelDY) ||
|
| 4456 |
-
(movedX && display.wheelDX && movedX / display.wheelDX)
|
| 4457 |
-
display.wheelStartX = display.wheelStartY = null
|
| 4458 |
if (!sample) { return }
|
| 4459 |
-
wheelPixelsPerUnit = (wheelPixelsPerUnit * wheelSamples + sample) / (wheelSamples + 1)
|
| 4460 |
-
++wheelSamples
|
| 4461 |
-
}, 200)
|
| 4462 |
} else {
|
| 4463 |
-
display.wheelDX += dx; display.wheelDY += dy
|
| 4464 |
}
|
| 4465 |
}
|
| 4466 |
}
|
|
@@ -4470,8 +4480,8 @@ webpackJsonp([2],{
|
|
| 4470 |
// Prepare DOM reads needed to update the scrollbars. Done in one
|
| 4471 |
// shot to minimize update/measure roundtrips.
|
| 4472 |
function measureForScrollbars(cm) {
|
| 4473 |
-
var d = cm.display, gutterW = d.gutters.offsetWidth
|
| 4474 |
-
var docH = Math.round(cm.doc.height + paddingVert(cm.display))
|
| 4475 |
return {
|
| 4476 |
clientHeight: d.scroller.clientHeight,
|
| 4477 |
viewHeight: d.wrapper.clientHeight,
|
|
@@ -4486,80 +4496,80 @@ webpackJsonp([2],{
|
|
| 4486 |
}
|
| 4487 |
|
| 4488 |
var NativeScrollbars = function(place, scroll, cm) {
|
| 4489 |
-
this.cm = cm
|
| 4490 |
-
var vert = this.vert = elt("div", [elt("div", null, null, "min-width: 1px")], "CodeMirror-vscrollbar")
|
| 4491 |
-
var horiz = this.horiz = elt("div", [elt("div", null, null, "height: 100%; min-height: 1px")], "CodeMirror-hscrollbar")
|
| 4492 |
-
place(vert); place(horiz)
|
| 4493 |
|
| 4494 |
on(vert, "scroll", function () {
|
| 4495 |
-
if (vert.clientHeight) { scroll(vert.scrollTop, "vertical") }
|
| 4496 |
-
})
|
| 4497 |
on(horiz, "scroll", function () {
|
| 4498 |
-
if (horiz.clientWidth) { scroll(horiz.scrollLeft, "horizontal") }
|
| 4499 |
-
})
|
| 4500 |
|
| 4501 |
-
this.checkedZeroWidth = false
|
| 4502 |
// Need to set a minimum width to see the scrollbar on IE7 (but must not set it on IE8).
|
| 4503 |
-
if (ie && ie_version < 8) { this.horiz.style.minHeight = this.vert.style.minWidth = "18px" }
|
| 4504 |
};
|
| 4505 |
|
| 4506 |
NativeScrollbars.prototype.update = function (measure) {
|
| 4507 |
-
var needsH = measure.scrollWidth > measure.clientWidth + 1
|
| 4508 |
-
var needsV = measure.scrollHeight > measure.clientHeight + 1
|
| 4509 |
-
var sWidth = measure.nativeBarWidth
|
| 4510 |
|
| 4511 |
if (needsV) {
|
| 4512 |
-
this.vert.style.display = "block"
|
| 4513 |
-
this.vert.style.bottom = needsH ? sWidth + "px" : "0"
|
| 4514 |
-
var totalHeight = measure.viewHeight - (needsH ? sWidth : 0)
|
| 4515 |
// A bug in IE8 can cause this value to be negative, so guard it.
|
| 4516 |
this.vert.firstChild.style.height =
|
| 4517 |
-
Math.max(0, measure.scrollHeight - measure.clientHeight + totalHeight) + "px"
|
| 4518 |
} else {
|
| 4519 |
-
this.vert.style.display = ""
|
| 4520 |
-
this.vert.firstChild.style.height = "0"
|
| 4521 |
}
|
| 4522 |
|
| 4523 |
if (needsH) {
|
| 4524 |
-
this.horiz.style.display = "block"
|
| 4525 |
-
this.horiz.style.right = needsV ? sWidth + "px" : "0"
|
| 4526 |
-
this.horiz.style.left = measure.barLeft + "px"
|
| 4527 |
-
var totalWidth = measure.viewWidth - measure.barLeft - (needsV ? sWidth : 0)
|
| 4528 |
this.horiz.firstChild.style.width =
|
| 4529 |
-
Math.max(0, measure.scrollWidth - measure.clientWidth + totalWidth) + "px"
|
| 4530 |
} else {
|
| 4531 |
-
this.horiz.style.display = ""
|
| 4532 |
-
this.horiz.firstChild.style.width = "0"
|
| 4533 |
}
|
| 4534 |
|
| 4535 |
if (!this.checkedZeroWidth && measure.clientHeight > 0) {
|
| 4536 |
-
if (sWidth == 0) { this.zeroWidthHack() }
|
| 4537 |
-
this.checkedZeroWidth = true
|
| 4538 |
}
|
| 4539 |
|
| 4540 |
return {right: needsV ? sWidth : 0, bottom: needsH ? sWidth : 0}
|
| 4541 |
};
|
| 4542 |
|
| 4543 |
NativeScrollbars.prototype.setScrollLeft = function (pos) {
|
| 4544 |
-
if (this.horiz.scrollLeft != pos) { this.horiz.scrollLeft = pos }
|
| 4545 |
-
if (this.disableHoriz) { this.enableZeroWidthBar(this.horiz, this.disableHoriz) }
|
| 4546 |
};
|
| 4547 |
|
| 4548 |
NativeScrollbars.prototype.setScrollTop = function (pos) {
|
| 4549 |
-
if (this.vert.scrollTop != pos) { this.vert.scrollTop = pos }
|
| 4550 |
-
if (this.disableVert) { this.enableZeroWidthBar(this.vert, this.disableVert) }
|
| 4551 |
};
|
| 4552 |
|
| 4553 |
NativeScrollbars.prototype.zeroWidthHack = function () {
|
| 4554 |
-
var w = mac && !mac_geMountainLion ? "12px" : "18px"
|
| 4555 |
-
this.horiz.style.height = this.vert.style.width = w
|
| 4556 |
-
this.horiz.style.pointerEvents = this.vert.style.pointerEvents = "none"
|
| 4557 |
-
this.disableHoriz = new Delayed
|
| 4558 |
-
this.disableVert = new Delayed
|
| 4559 |
};
|
| 4560 |
|
| 4561 |
NativeScrollbars.prototype.enableZeroWidthBar = function (bar, delay) {
|
| 4562 |
-
bar.style.pointerEvents = "auto"
|
| 4563 |
function maybeDisable() {
|
| 4564 |
// To find out whether the scrollbar is still visible, we
|
| 4565 |
// check whether the element under the pixel in the bottom
|
|
@@ -4567,18 +4577,18 @@ webpackJsonp([2],{
|
|
| 4567 |
// itself (when the bar is still visible) or its filler child
|
| 4568 |
// (when the bar is hidden). If it is still visible, we keep
|
| 4569 |
// it enabled, if it's hidden, we disable pointer events.
|
| 4570 |
-
var box = bar.getBoundingClientRect()
|
| 4571 |
-
var elt = document.elementFromPoint(box.left + 1, box.bottom - 1)
|
| 4572 |
-
if (elt != bar) { bar.style.pointerEvents = "none" }
|
| 4573 |
-
else { delay.set(1000, maybeDisable) }
|
| 4574 |
}
|
| 4575 |
-
delay.set(1000, maybeDisable)
|
| 4576 |
};
|
| 4577 |
|
| 4578 |
NativeScrollbars.prototype.clear = function () {
|
| 4579 |
-
var parent = this.horiz.parentNode
|
| 4580 |
-
parent.removeChild(this.horiz)
|
| 4581 |
-
parent.removeChild(this.vert)
|
| 4582 |
};
|
| 4583 |
|
| 4584 |
var NullScrollbars = function () {};
|
|
@@ -4589,78 +4599,78 @@ webpackJsonp([2],{
|
|
| 4589 |
NullScrollbars.prototype.clear = function () {};
|
| 4590 |
|
| 4591 |
function updateScrollbars(cm, measure) {
|
| 4592 |
-
if (!measure) { measure = measureForScrollbars(cm) }
|
| 4593 |
-
var startWidth = cm.display.barWidth, startHeight = cm.display.barHeight
|
| 4594 |
-
updateScrollbarsInner(cm, measure)
|
| 4595 |
for (var i = 0; i < 4 && startWidth != cm.display.barWidth || startHeight != cm.display.barHeight; i++) {
|
| 4596 |
if (startWidth != cm.display.barWidth && cm.options.lineWrapping)
|
| 4597 |
-
{ updateHeightsInViewport(cm) }
|
| 4598 |
-
updateScrollbarsInner(cm, measureForScrollbars(cm))
|
| 4599 |
-
startWidth = cm.display.barWidth; startHeight = cm.display.barHeight
|
| 4600 |
}
|
| 4601 |
}
|
| 4602 |
|
| 4603 |
// Re-synchronize the fake scrollbars with the actual size of the
|
| 4604 |
// content.
|
| 4605 |
function updateScrollbarsInner(cm, measure) {
|
| 4606 |
-
var d = cm.display
|
| 4607 |
-
var sizes = d.scrollbars.update(measure)
|
| 4608 |
|
| 4609 |
-
d.sizer.style.paddingRight = (d.barWidth = sizes.right) + "px"
|
| 4610 |
-
d.sizer.style.paddingBottom = (d.barHeight = sizes.bottom) + "px"
|
| 4611 |
-
d.heightForcer.style.borderBottom = sizes.bottom + "px solid transparent"
|
| 4612 |
|
| 4613 |
if (sizes.right && sizes.bottom) {
|
| 4614 |
-
d.scrollbarFiller.style.display = "block"
|
| 4615 |
-
d.scrollbarFiller.style.height = sizes.bottom + "px"
|
| 4616 |
-
d.scrollbarFiller.style.width = sizes.right + "px"
|
| 4617 |
-
} else { d.scrollbarFiller.style.display = "" }
|
| 4618 |
if (sizes.bottom && cm.options.coverGutterNextToScrollbar && cm.options.fixedGutter) {
|
| 4619 |
-
d.gutterFiller.style.display = "block"
|
| 4620 |
-
d.gutterFiller.style.height = sizes.bottom + "px"
|
| 4621 |
-
d.gutterFiller.style.width = measure.gutterWidth + "px"
|
| 4622 |
-
} else { d.gutterFiller.style.display = "" }
|
| 4623 |
}
|
| 4624 |
|
| 4625 |
-
var scrollbarModel = {"native": NativeScrollbars, "null": NullScrollbars}
|
| 4626 |
|
| 4627 |
function initScrollbars(cm) {
|
| 4628 |
if (cm.display.scrollbars) {
|
| 4629 |
-
cm.display.scrollbars.clear()
|
| 4630 |
if (cm.display.scrollbars.addClass)
|
| 4631 |
-
{ rmClass(cm.display.wrapper, cm.display.scrollbars.addClass) }
|
| 4632 |
}
|
| 4633 |
|
| 4634 |
cm.display.scrollbars = new scrollbarModel[cm.options.scrollbarStyle](function (node) {
|
| 4635 |
-
cm.display.wrapper.insertBefore(node, cm.display.scrollbarFiller)
|
| 4636 |
// Prevent clicks in the scrollbars from killing focus
|
| 4637 |
on(node, "mousedown", function () {
|
| 4638 |
-
if (cm.state.focused) { setTimeout(function () { return cm.display.input.focus(); }, 0) }
|
| 4639 |
-
})
|
| 4640 |
-
node.setAttribute("cm-not-content", "true")
|
| 4641 |
}, function (pos, axis) {
|
| 4642 |
-
if (axis == "horizontal") { setScrollLeft(cm, pos) }
|
| 4643 |
-
else { setScrollTop(cm, pos) }
|
| 4644 |
-
}, cm)
|
| 4645 |
if (cm.display.scrollbars.addClass)
|
| 4646 |
-
{ addClass(cm.display.wrapper, cm.display.scrollbars.addClass) }
|
| 4647 |
}
|
| 4648 |
|
| 4649 |
// SCROLLING THINGS INTO VIEW
|
| 4650 |
|
| 4651 |
// If an editor sits on the top or bottom of the window, partially
|
| 4652 |
// scrolled out of view, this ensures that the cursor is visible.
|
| 4653 |
-
function maybeScrollWindow(cm,
|
| 4654 |
if (signalDOMEvent(cm, "scrollCursorIntoView")) { return }
|
| 4655 |
|
| 4656 |
-
var display = cm.display, box = display.sizer.getBoundingClientRect(), doScroll = null
|
| 4657 |
-
if (
|
| 4658 |
-
else if (
|
| 4659 |
if (doScroll != null && !phantom) {
|
| 4660 |
-
var scrollNode = elt("div", "\u200b", null, ("position: absolute;\n top: " + (
|
| 4661 |
-
cm.display.lineSpace.appendChild(scrollNode)
|
| 4662 |
-
scrollNode.scrollIntoView(doScroll)
|
| 4663 |
-
cm.display.lineSpace.removeChild(scrollNode)
|
| 4664 |
}
|
| 4665 |
}
|
| 4666 |
|
|
@@ -4668,89 +4678,90 @@ webpackJsonp([2],{
|
|
| 4668 |
// it actually became visible (as line heights are accurately
|
| 4669 |
// measured, the position of something may 'drift' during drawing).
|
| 4670 |
function scrollPosIntoView(cm, pos, end, margin) {
|
| 4671 |
-
if (margin == null) { margin = 0 }
|
| 4672 |
-
var
|
| 4673 |
for (var limit = 0; limit < 5; limit++) {
|
| 4674 |
-
var changed = false
|
| 4675 |
-
coords = cursorCoords(cm, pos)
|
| 4676 |
-
var endCoords = !end || end == pos ? coords : cursorCoords(cm, end)
|
| 4677 |
-
|
| 4678 |
-
|
| 4679 |
-
|
| 4680 |
-
|
| 4681 |
-
var
|
|
|
|
| 4682 |
if (scrollPos.scrollTop != null) {
|
| 4683 |
-
setScrollTop(cm, scrollPos.scrollTop)
|
| 4684 |
-
if (Math.abs(cm.doc.scrollTop - startTop) > 1) { changed = true }
|
| 4685 |
}
|
| 4686 |
if (scrollPos.scrollLeft != null) {
|
| 4687 |
-
setScrollLeft(cm, scrollPos.scrollLeft)
|
| 4688 |
-
if (Math.abs(cm.doc.scrollLeft - startLeft) > 1) { changed = true }
|
| 4689 |
}
|
| 4690 |
if (!changed) { break }
|
| 4691 |
}
|
| 4692 |
-
return
|
| 4693 |
}
|
| 4694 |
|
| 4695 |
// Scroll a given set of coordinates into view (immediately).
|
| 4696 |
-
function scrollIntoView(cm,
|
| 4697 |
-
var scrollPos = calculateScrollPos(cm,
|
| 4698 |
-
if (scrollPos.scrollTop != null) { setScrollTop(cm, scrollPos.scrollTop) }
|
| 4699 |
-
if (scrollPos.scrollLeft != null) { setScrollLeft(cm, scrollPos.scrollLeft) }
|
| 4700 |
}
|
| 4701 |
|
| 4702 |
// Calculate a new scroll position needed to scroll the given
|
| 4703 |
// rectangle into view. Returns an object with scrollTop and
|
| 4704 |
// scrollLeft properties. When these are undefined, the
|
| 4705 |
// vertical/horizontal position does not need to be adjusted.
|
| 4706 |
-
function calculateScrollPos(cm,
|
| 4707 |
-
var display = cm.display, snapMargin = textHeight(cm.display)
|
| 4708 |
-
if (
|
| 4709 |
-
var screentop = cm.curOp && cm.curOp.scrollTop != null ? cm.curOp.scrollTop : display.scroller.scrollTop
|
| 4710 |
-
var screen = displayHeight(cm), result = {}
|
| 4711 |
-
if (
|
| 4712 |
-
var docBottom = cm.doc.height + paddingVert(display)
|
| 4713 |
-
var atTop =
|
| 4714 |
-
if (
|
| 4715 |
-
result.scrollTop = atTop ? 0 :
|
| 4716 |
-
} else if (
|
| 4717 |
-
var newTop = Math.min(
|
| 4718 |
-
if (newTop != screentop) { result.scrollTop = newTop }
|
| 4719 |
-
}
|
| 4720 |
-
|
| 4721 |
-
var screenleft = cm.curOp && cm.curOp.scrollLeft != null ? cm.curOp.scrollLeft : display.scroller.scrollLeft
|
| 4722 |
-
var screenw = displayWidth(cm) - (cm.options.fixedGutter ? display.gutters.offsetWidth : 0)
|
| 4723 |
-
var tooWide =
|
| 4724 |
-
if (tooWide) {
|
| 4725 |
-
if (
|
| 4726 |
-
{ result.scrollLeft = 0 }
|
| 4727 |
-
else if (
|
| 4728 |
-
{ result.scrollLeft = Math.max(0,
|
| 4729 |
-
else if (
|
| 4730 |
-
{ result.scrollLeft =
|
| 4731 |
return result
|
| 4732 |
}
|
| 4733 |
|
| 4734 |
// Store a relative adjustment to the scroll position in the current
|
| 4735 |
// operation (to be applied when the operation finishes).
|
| 4736 |
function addToScrollPos(cm, left, top) {
|
| 4737 |
-
if (left != null || top != null) { resolveScrollToPos(cm) }
|
| 4738 |
if (left != null)
|
| 4739 |
-
{ cm.curOp.scrollLeft = (cm.curOp.scrollLeft == null ? cm.doc.scrollLeft : cm.curOp.scrollLeft) + left }
|
| 4740 |
if (top != null)
|
| 4741 |
-
{ cm.curOp.scrollTop = (cm.curOp.scrollTop == null ? cm.doc.scrollTop : cm.curOp.scrollTop) + top }
|
| 4742 |
}
|
| 4743 |
|
| 4744 |
// Make sure that at the end of the operation the current cursor is
|
| 4745 |
// shown.
|
| 4746 |
function ensureCursorVisible(cm) {
|
| 4747 |
-
resolveScrollToPos(cm)
|
| 4748 |
-
var cur = cm.getCursor(), from = cur, to = cur
|
| 4749 |
if (!cm.options.lineWrapping) {
|
| 4750 |
-
from = cur.ch ? Pos(cur.line, cur.ch - 1) : cur
|
| 4751 |
-
to = Pos(cur.line, cur.ch + 1)
|
| 4752 |
}
|
| 4753 |
-
cm.curOp.scrollToPos = {from: from, to: to, margin: cm.options.cursorScrollMargin
|
| 4754 |
}
|
| 4755 |
|
| 4756 |
// When an operation has its scrollToPos property set, and another
|
|
@@ -4758,15 +4769,17 @@ webpackJsonp([2],{
|
|
| 4758 |
// 'simulates' scrolling that position into view in a cheap way, so
|
| 4759 |
// that the effect of intermediate scroll commands is not ignored.
|
| 4760 |
function resolveScrollToPos(cm) {
|
| 4761 |
-
var range = cm.curOp.scrollToPos
|
| 4762 |
-
if (range) {
|
| 4763 |
-
cm.curOp.scrollToPos = null
|
| 4764 |
-
var from = estimateCoords(cm, range.from), to = estimateCoords(cm, range.to)
|
| 4765 |
-
var sPos = calculateScrollPos(cm,
|
| 4766 |
-
|
| 4767 |
-
|
| 4768 |
-
|
| 4769 |
-
|
|
|
|
|
|
|
| 4770 |
}
|
| 4771 |
}
|
| 4772 |
|
|
@@ -4776,7 +4789,7 @@ webpackJsonp([2],{
|
|
| 4776 |
// error-prone). Instead, display updates are batched and then all
|
| 4777 |
// combined and executed at once.
|
| 4778 |
|
| 4779 |
-
var nextOpId = 0
|
| 4780 |
// Start a new operation.
|
| 4781 |
function startOperation(cm) {
|
| 4782 |
cm.curOp = {
|
|
@@ -4795,159 +4808,159 @@ webpackJsonp([2],{
|
|
| 4795 |
scrollToPos: null, // Used to scroll to a specific position
|
| 4796 |
focus: false,
|
| 4797 |
id: ++nextOpId // Unique ID
|
| 4798 |
-
}
|
| 4799 |
-
pushOperation(cm.curOp)
|
| 4800 |
}
|
| 4801 |
|
| 4802 |
// Finish an operation, updating the display and signalling delayed events
|
| 4803 |
function endOperation(cm) {
|
| 4804 |
-
var op = cm.curOp
|
| 4805 |
finishOperation(op, function (group) {
|
| 4806 |
for (var i = 0; i < group.ops.length; i++)
|
| 4807 |
-
{ group.ops[i].cm.curOp = null }
|
| 4808 |
-
endOperations(group)
|
| 4809 |
-
})
|
| 4810 |
}
|
| 4811 |
|
| 4812 |
// The DOM updates done when an operation finishes are batched so
|
| 4813 |
// that the minimum number of relayouts are required.
|
| 4814 |
function endOperations(group) {
|
| 4815 |
-
var ops = group.ops
|
| 4816 |
for (var i = 0; i < ops.length; i++) // Read DOM
|
| 4817 |
-
{ endOperation_R1(ops[i]) }
|
| 4818 |
for (var i$1 = 0; i$1 < ops.length; i$1++) // Write DOM (maybe)
|
| 4819 |
-
{ endOperation_W1(ops[i$1]) }
|
| 4820 |
for (var i$2 = 0; i$2 < ops.length; i$2++) // Read DOM
|
| 4821 |
-
{ endOperation_R2(ops[i$2]) }
|
| 4822 |
for (var i$3 = 0; i$3 < ops.length; i$3++) // Write DOM (maybe)
|
| 4823 |
-
{ endOperation_W2(ops[i$3]) }
|
| 4824 |
for (var i$4 = 0; i$4 < ops.length; i$4++) // Read DOM
|
| 4825 |
-
{ endOperation_finish(ops[i$4]) }
|
| 4826 |
}
|
| 4827 |
|
| 4828 |
function endOperation_R1(op) {
|
| 4829 |
-
var cm = op.cm, display = cm.display
|
| 4830 |
-
maybeClipScrollbars(cm)
|
| 4831 |
-
if (op.updateMaxLine) { findMaxLine(cm) }
|
| 4832 |
|
| 4833 |
op.mustUpdate = op.viewChanged || op.forceUpdate || op.scrollTop != null ||
|
| 4834 |
op.scrollToPos && (op.scrollToPos.from.line < display.viewFrom ||
|
| 4835 |
op.scrollToPos.to.line >= display.viewTo) ||
|
| 4836 |
-
display.maxLineChanged && cm.options.lineWrapping
|
| 4837 |
op.update = op.mustUpdate &&
|
| 4838 |
-
new DisplayUpdate(cm, op.mustUpdate && {top: op.scrollTop, ensure: op.scrollToPos}, op.forceUpdate)
|
| 4839 |
}
|
| 4840 |
|
| 4841 |
function endOperation_W1(op) {
|
| 4842 |
-
op.updatedDisplay = op.mustUpdate && updateDisplayIfNeeded(op.cm, op.update)
|
| 4843 |
}
|
| 4844 |
|
| 4845 |
function endOperation_R2(op) {
|
| 4846 |
-
var cm = op.cm, display = cm.display
|
| 4847 |
-
if (op.updatedDisplay) { updateHeightsInViewport(cm) }
|
| 4848 |
|
| 4849 |
-
op.barMeasure = measureForScrollbars(cm)
|
| 4850 |
|
| 4851 |
// If the max line changed since it was last measured, measure it,
|
| 4852 |
// and ensure the document's width matches it.
|
| 4853 |
// updateDisplay_W2 will use these properties to do the actual resizing
|
| 4854 |
if (display.maxLineChanged && !cm.options.lineWrapping) {
|
| 4855 |
-
op.adjustWidthTo = measureChar(cm, display.maxLine, display.maxLine.text.length).left + 3
|
| 4856 |
-
cm.display.sizerWidth = op.adjustWidthTo
|
| 4857 |
op.barMeasure.scrollWidth =
|
| 4858 |
-
Math.max(display.scroller.clientWidth, display.sizer.offsetLeft + op.adjustWidthTo + scrollGap(cm) + cm.display.barWidth)
|
| 4859 |
-
op.maxScrollLeft = Math.max(0, display.sizer.offsetLeft + op.adjustWidthTo - displayWidth(cm))
|
| 4860 |
}
|
| 4861 |
|
| 4862 |
if (op.updatedDisplay || op.selectionChanged)
|
| 4863 |
-
{ op.preparedSelection = display.input.prepareSelection(op.focus) }
|
| 4864 |
}
|
| 4865 |
|
| 4866 |
function endOperation_W2(op) {
|
| 4867 |
-
var cm = op.cm
|
| 4868 |
|
| 4869 |
if (op.adjustWidthTo != null) {
|
| 4870 |
-
cm.display.sizer.style.minWidth = op.adjustWidthTo + "px"
|
| 4871 |
if (op.maxScrollLeft < cm.doc.scrollLeft)
|
| 4872 |
-
{ setScrollLeft(cm, Math.min(cm.display.scroller.scrollLeft, op.maxScrollLeft), true) }
|
| 4873 |
-
cm.display.maxLineChanged = false
|
| 4874 |
}
|
| 4875 |
|
| 4876 |
-
var takeFocus = op.focus && op.focus == activeElt() && (!document.hasFocus || document.hasFocus())
|
| 4877 |
if (op.preparedSelection)
|
| 4878 |
-
{ cm.display.input.showSelection(op.preparedSelection, takeFocus) }
|
| 4879 |
if (op.updatedDisplay || op.startHeight != cm.doc.height)
|
| 4880 |
-
{ updateScrollbars(cm, op.barMeasure) }
|
| 4881 |
if (op.updatedDisplay)
|
| 4882 |
-
{ setDocumentHeight(cm, op.barMeasure) }
|
| 4883 |
|
| 4884 |
-
if (op.selectionChanged) { restartBlink(cm) }
|
| 4885 |
|
| 4886 |
if (cm.state.focused && op.updateInput)
|
| 4887 |
-
{ cm.display.input.reset(op.typing) }
|
| 4888 |
-
if (takeFocus) { ensureFocus(op.cm) }
|
| 4889 |
}
|
| 4890 |
|
| 4891 |
function endOperation_finish(op) {
|
| 4892 |
-
var cm = op.cm, display = cm.display, doc = cm.doc
|
| 4893 |
|
| 4894 |
-
if (op.updatedDisplay) { postUpdateDisplay(cm, op.update) }
|
| 4895 |
|
| 4896 |
// Abort mouse wheel delta measurement, when scrolling explicitly
|
| 4897 |
if (display.wheelStartX != null && (op.scrollTop != null || op.scrollLeft != null || op.scrollToPos))
|
| 4898 |
-
{ display.wheelStartX = display.wheelStartY = null }
|
| 4899 |
|
| 4900 |
// Propagate the scroll position to the actual DOM scroller
|
| 4901 |
if (op.scrollTop != null && (display.scroller.scrollTop != op.scrollTop || op.forceScroll)) {
|
| 4902 |
-
doc.scrollTop = Math.max(0, Math.min(display.scroller.scrollHeight - display.scroller.clientHeight, op.scrollTop))
|
| 4903 |
-
display.scrollbars.setScrollTop(doc.scrollTop)
|
| 4904 |
-
display.scroller.scrollTop = doc.scrollTop
|
| 4905 |
}
|
| 4906 |
if (op.scrollLeft != null && (display.scroller.scrollLeft != op.scrollLeft || op.forceScroll)) {
|
| 4907 |
-
doc.scrollLeft = Math.max(0, Math.min(display.scroller.scrollWidth - display.scroller.clientWidth, op.scrollLeft))
|
| 4908 |
-
display.scrollbars.setScrollLeft(doc.scrollLeft)
|
| 4909 |
-
display.scroller.scrollLeft = doc.scrollLeft
|
| 4910 |
-
alignHorizontally(cm)
|
| 4911 |
}
|
| 4912 |
// If we need to scroll a specific position into view, do so.
|
| 4913 |
if (op.scrollToPos) {
|
| 4914 |
-
var
|
| 4915 |
-
|
| 4916 |
-
|
| 4917 |
}
|
| 4918 |
|
| 4919 |
// Fire events for markers that are hidden/unidden by editing or
|
| 4920 |
// undoing
|
| 4921 |
-
var hidden = op.maybeHiddenMarkers, unhidden = op.maybeUnhiddenMarkers
|
| 4922 |
if (hidden) { for (var i = 0; i < hidden.length; ++i)
|
| 4923 |
-
{ if (!hidden[i].lines.length) { signal(hidden[i], "hide") } } }
|
| 4924 |
if (unhidden) { for (var i$1 = 0; i$1 < unhidden.length; ++i$1)
|
| 4925 |
-
{ if (unhidden[i$1].lines.length) { signal(unhidden[i$1], "unhide") } } }
|
| 4926 |
|
| 4927 |
if (display.wrapper.offsetHeight)
|
| 4928 |
-
{ doc.scrollTop = cm.display.scroller.scrollTop }
|
| 4929 |
|
| 4930 |
// Fire change events, and delayed event handlers
|
| 4931 |
if (op.changeObjs)
|
| 4932 |
-
{ signal(cm, "changes", cm, op.changeObjs) }
|
| 4933 |
if (op.update)
|
| 4934 |
-
{ op.update.finish() }
|
| 4935 |
}
|
| 4936 |
|
| 4937 |
// Run the given function in an operation
|
| 4938 |
function runInOp(cm, f) {
|
| 4939 |
if (cm.curOp) { return f() }
|
| 4940 |
-
startOperation(cm)
|
| 4941 |
try { return f() }
|
| 4942 |
-
finally { endOperation(cm) }
|
| 4943 |
}
|
| 4944 |
// Wraps a function in an operation. Returns the wrapped function.
|
| 4945 |
function operation(cm, f) {
|
| 4946 |
return function() {
|
| 4947 |
if (cm.curOp) { return f.apply(cm, arguments) }
|
| 4948 |
-
startOperation(cm)
|
| 4949 |
try { return f.apply(cm, arguments) }
|
| 4950 |
-
finally { endOperation(cm) }
|
| 4951 |
}
|
| 4952 |
}
|
| 4953 |
// Used to add methods to editor and doc instances, wrapping them in
|
|
@@ -4955,18 +4968,18 @@ webpackJsonp([2],{
|
|
| 4955 |
function methodOp(f) {
|
| 4956 |
return function() {
|
| 4957 |
if (this.curOp) { return f.apply(this, arguments) }
|
| 4958 |
-
startOperation(this)
|
| 4959 |
try { return f.apply(this, arguments) }
|
| 4960 |
-
finally { endOperation(this) }
|
| 4961 |
}
|
| 4962 |
}
|
| 4963 |
function docMethodOp(f) {
|
| 4964 |
return function() {
|
| 4965 |
-
var cm = this.cm
|
| 4966 |
if (!cm || cm.curOp) { return f.apply(this, arguments) }
|
| 4967 |
-
startOperation(cm)
|
| 4968 |
try { return f.apply(this, arguments) }
|
| 4969 |
-
finally { endOperation(cm) }
|
| 4970 |
}
|
| 4971 |
}
|
| 4972 |
|
|
@@ -4977,111 +4990,111 @@ webpackJsonp([2],{
|
|
| 4977 |
// lines are divided into visual lines. regLineChange (below)
|
| 4978 |
// registers single-line changes.
|
| 4979 |
function regChange(cm, from, to, lendiff) {
|
| 4980 |
-
if (from == null) { from = cm.doc.first }
|
| 4981 |
-
if (to == null) { to = cm.doc.first + cm.doc.size }
|
| 4982 |
-
if (!lendiff) { lendiff = 0 }
|
| 4983 |
|
| 4984 |
-
var display = cm.display
|
| 4985 |
if (lendiff && to < display.viewTo &&
|
| 4986 |
(display.updateLineNumbers == null || display.updateLineNumbers > from))
|
| 4987 |
-
{ display.updateLineNumbers = from }
|
| 4988 |
|
| 4989 |
-
cm.curOp.viewChanged = true
|
| 4990 |
|
| 4991 |
if (from >= display.viewTo) { // Change after
|
| 4992 |
if (sawCollapsedSpans && visualLineNo(cm.doc, from) < display.viewTo)
|
| 4993 |
-
{ resetView(cm) }
|
| 4994 |
} else if (to <= display.viewFrom) { // Change before
|
| 4995 |
if (sawCollapsedSpans && visualLineEndNo(cm.doc, to + lendiff) > display.viewFrom) {
|
| 4996 |
-
resetView(cm)
|
| 4997 |
} else {
|
| 4998 |
-
display.viewFrom += lendiff
|
| 4999 |
-
display.viewTo += lendiff
|
| 5000 |
}
|
| 5001 |
} else if (from <= display.viewFrom && to >= display.viewTo) { // Full overlap
|
| 5002 |
-
resetView(cm)
|
| 5003 |
} else if (from <= display.viewFrom) { // Top overlap
|
| 5004 |
-
var cut = viewCuttingPoint(cm, to, to + lendiff, 1)
|
| 5005 |
if (cut) {
|
| 5006 |
-
display.view = display.view.slice(cut.index)
|
| 5007 |
-
display.viewFrom = cut.lineN
|
| 5008 |
-
display.viewTo += lendiff
|
| 5009 |
} else {
|
| 5010 |
-
resetView(cm)
|
| 5011 |
}
|
| 5012 |
} else if (to >= display.viewTo) { // Bottom overlap
|
| 5013 |
-
var cut$1 = viewCuttingPoint(cm, from, from, -1)
|
| 5014 |
if (cut$1) {
|
| 5015 |
-
display.view = display.view.slice(0, cut$1.index)
|
| 5016 |
-
display.viewTo = cut$1.lineN
|
| 5017 |
} else {
|
| 5018 |
-
resetView(cm)
|
| 5019 |
}
|
| 5020 |
} else { // Gap in the middle
|
| 5021 |
-
var cutTop = viewCuttingPoint(cm, from, from, -1)
|
| 5022 |
-
var cutBot = viewCuttingPoint(cm, to, to + lendiff, 1)
|
| 5023 |
if (cutTop && cutBot) {
|
| 5024 |
display.view = display.view.slice(0, cutTop.index)
|
| 5025 |
.concat(buildViewArray(cm, cutTop.lineN, cutBot.lineN))
|
| 5026 |
-
.concat(display.view.slice(cutBot.index))
|
| 5027 |
-
display.viewTo += lendiff
|
| 5028 |
} else {
|
| 5029 |
-
resetView(cm)
|
| 5030 |
}
|
| 5031 |
}
|
| 5032 |
|
| 5033 |
-
var ext = display.externalMeasured
|
| 5034 |
if (ext) {
|
| 5035 |
if (to < ext.lineN)
|
| 5036 |
-
{ ext.lineN += lendiff }
|
| 5037 |
else if (from < ext.lineN + ext.size)
|
| 5038 |
-
{ display.externalMeasured = null }
|
| 5039 |
}
|
| 5040 |
}
|
| 5041 |
|
| 5042 |
// Register a change to a single line. Type must be one of "text",
|
| 5043 |
// "gutter", "class", "widget"
|
| 5044 |
function regLineChange(cm, line, type) {
|
| 5045 |
-
cm.curOp.viewChanged = true
|
| 5046 |
-
var display = cm.display, ext = cm.display.externalMeasured
|
| 5047 |
if (ext && line >= ext.lineN && line < ext.lineN + ext.size)
|
| 5048 |
-
{ display.externalMeasured = null }
|
| 5049 |
|
| 5050 |
if (line < display.viewFrom || line >= display.viewTo) { return }
|
| 5051 |
-
var lineView = display.view[findViewIndex(cm, line)]
|
| 5052 |
if (lineView.node == null) { return }
|
| 5053 |
-
var arr = lineView.changes || (lineView.changes = [])
|
| 5054 |
-
if (indexOf(arr, type) == -1) { arr.push(type) }
|
| 5055 |
}
|
| 5056 |
|
| 5057 |
// Clear the view.
|
| 5058 |
function resetView(cm) {
|
| 5059 |
-
cm.display.viewFrom = cm.display.viewTo = cm.doc.first
|
| 5060 |
-
cm.display.view = []
|
| 5061 |
-
cm.display.viewOffset = 0
|
| 5062 |
}
|
| 5063 |
|
| 5064 |
function viewCuttingPoint(cm, oldN, newN, dir) {
|
| 5065 |
-
var index = findViewIndex(cm, oldN), diff, view = cm.display.view
|
| 5066 |
if (!sawCollapsedSpans || newN == cm.doc.first + cm.doc.size)
|
| 5067 |
{ return {index: index, lineN: newN} }
|
| 5068 |
-
var n = cm.display.viewFrom
|
| 5069 |
for (var i = 0; i < index; i++)
|
| 5070 |
-
{ n += view[i].size }
|
| 5071 |
if (n != oldN) {
|
| 5072 |
if (dir > 0) {
|
| 5073 |
if (index == view.length - 1) { return null }
|
| 5074 |
-
diff = (n + view[index].size) - oldN
|
| 5075 |
-
index
|
| 5076 |
} else {
|
| 5077 |
-
diff = n - oldN
|
| 5078 |
}
|
| 5079 |
-
oldN += diff; newN += diff
|
| 5080 |
}
|
| 5081 |
while (visualLineNo(cm.doc, newN) != newN) {
|
| 5082 |
if (index == (dir < 0 ? 0 : view.length - 1)) { return null }
|
| 5083 |
-
newN += dir * view[index - (dir < 0 ? 1 : 0)].size
|
| 5084 |
-
index += dir
|
| 5085 |
}
|
| 5086 |
return {index: index, lineN: newN}
|
| 5087 |
}
|
|
@@ -5089,31 +5102,31 @@ webpackJsonp([2],{
|
|
| 5089 |
// Force the view to cover a given range, adding empty view element
|
| 5090 |
// or clipping off existing ones as needed.
|
| 5091 |
function adjustView(cm, from, to) {
|
| 5092 |
-
var display = cm.display, view = display.view
|
| 5093 |
if (view.length == 0 || from >= display.viewTo || to <= display.viewFrom) {
|
| 5094 |
-
display.view = buildViewArray(cm, from, to)
|
| 5095 |
-
display.viewFrom = from
|
| 5096 |
} else {
|
| 5097 |
if (display.viewFrom > from)
|
| 5098 |
-
{ display.view = buildViewArray(cm, from, display.viewFrom).concat(display.view) }
|
| 5099 |
else if (display.viewFrom < from)
|
| 5100 |
-
{ display.view = display.view.slice(findViewIndex(cm, from)) }
|
| 5101 |
-
display.viewFrom = from
|
| 5102 |
if (display.viewTo < to)
|
| 5103 |
-
{ display.view = display.view.concat(buildViewArray(cm, display.viewTo, to)) }
|
| 5104 |
else if (display.viewTo > to)
|
| 5105 |
-
{ display.view = display.view.slice(0, findViewIndex(cm, to)) }
|
| 5106 |
}
|
| 5107 |
-
display.viewTo = to
|
| 5108 |
}
|
| 5109 |
|
| 5110 |
// Count the number of lines in the view whose DOM representation is
|
| 5111 |
// out of date (or nonexistent).
|
| 5112 |
function countDirtyView(cm) {
|
| 5113 |
-
var view = cm.display.view, dirty = 0
|
| 5114 |
for (var i = 0; i < view.length; i++) {
|
| 5115 |
-
var lineView = view[i]
|
| 5116 |
-
if (!lineView.hidden && (!lineView.node || lineView.changes)) { ++dirty }
|
| 5117 |
}
|
| 5118 |
return dirty
|
| 5119 |
}
|
|
@@ -5122,83 +5135,83 @@ webpackJsonp([2],{
|
|
| 5122 |
|
| 5123 |
function startWorker(cm, time) {
|
| 5124 |
if (cm.doc.mode.startState && cm.doc.frontier < cm.display.viewTo)
|
| 5125 |
-
{ cm.state.highlight.set(time, bind(highlightWorker, cm)) }
|
| 5126 |
}
|
| 5127 |
|
| 5128 |
function highlightWorker(cm) {
|
| 5129 |
-
var doc = cm.doc
|
| 5130 |
-
if (doc.frontier < doc.first) { doc.frontier = doc.first }
|
| 5131 |
if (doc.frontier >= cm.display.viewTo) { return }
|
| 5132 |
-
var end = +new Date + cm.options.workTime
|
| 5133 |
-
var state = copyState(doc.mode, getStateBefore(cm, doc.frontier))
|
| 5134 |
-
var changedLines = []
|
| 5135 |
|
| 5136 |
doc.iter(doc.frontier, Math.min(doc.first + doc.size, cm.display.viewTo + 500), function (line) {
|
| 5137 |
if (doc.frontier >= cm.display.viewFrom) { // Visible
|
| 5138 |
-
var oldStyles = line.styles, tooLong = line.text.length > cm.options.maxHighlightLength
|
| 5139 |
-
var highlighted = highlightLine(cm, line, tooLong ? copyState(doc.mode, state) : state, true)
|
| 5140 |
-
line.styles = highlighted.styles
|
| 5141 |
-
var oldCls = line.styleClasses, newCls = highlighted.classes
|
| 5142 |
-
if (newCls) { line.styleClasses = newCls }
|
| 5143 |
-
else if (oldCls) { line.styleClasses = null }
|
| 5144 |
var ischange = !oldStyles || oldStyles.length != line.styles.length ||
|
| 5145 |
-
oldCls != newCls && (!oldCls || !newCls || oldCls.bgClass != newCls.bgClass || oldCls.textClass != newCls.textClass)
|
| 5146 |
-
for (var i = 0; !ischange && i < oldStyles.length; ++i) { ischange = oldStyles[i] != line.styles[i] }
|
| 5147 |
-
if (ischange) { changedLines.push(doc.frontier) }
|
| 5148 |
-
line.stateAfter = tooLong ? state : copyState(doc.mode, state)
|
| 5149 |
} else {
|
| 5150 |
if (line.text.length <= cm.options.maxHighlightLength)
|
| 5151 |
-
{ processLine(cm, line.text, state) }
|
| 5152 |
-
line.stateAfter = doc.frontier % 5 == 0 ? copyState(doc.mode, state) : null
|
| 5153 |
}
|
| 5154 |
-
++doc.frontier
|
| 5155 |
if (+new Date > end) {
|
| 5156 |
-
startWorker(cm, cm.options.workDelay)
|
| 5157 |
return true
|
| 5158 |
}
|
| 5159 |
-
})
|
| 5160 |
if (changedLines.length) { runInOp(cm, function () {
|
| 5161 |
for (var i = 0; i < changedLines.length; i++)
|
| 5162 |
-
{ regLineChange(cm, changedLines[i], "text") }
|
| 5163 |
-
}) }
|
| 5164 |
}
|
| 5165 |
|
| 5166 |
// DISPLAY DRAWING
|
| 5167 |
|
| 5168 |
var DisplayUpdate = function(cm, viewport, force) {
|
| 5169 |
-
var display = cm.display
|
| 5170 |
|
| 5171 |
-
this.viewport = viewport
|
| 5172 |
// Store some values that we'll need later (but don't want to force a relayout for)
|
| 5173 |
-
this.visible = visibleLines(display, cm.doc, viewport)
|
| 5174 |
-
this.editorIsHidden = !display.wrapper.offsetWidth
|
| 5175 |
-
this.wrapperHeight = display.wrapper.clientHeight
|
| 5176 |
-
this.wrapperWidth = display.wrapper.clientWidth
|
| 5177 |
-
this.oldDisplayWidth = displayWidth(cm)
|
| 5178 |
-
this.force = force
|
| 5179 |
-
this.dims = getDimensions(cm)
|
| 5180 |
-
this.events = []
|
| 5181 |
};
|
| 5182 |
|
| 5183 |
DisplayUpdate.prototype.signal = function (emitter, type) {
|
| 5184 |
if (hasHandler(emitter, type))
|
| 5185 |
-
{ this.events.push(arguments) }
|
| 5186 |
};
|
| 5187 |
DisplayUpdate.prototype.finish = function () {
|
| 5188 |
var this$1 = this;
|
| 5189 |
|
| 5190 |
for (var i = 0; i < this.events.length; i++)
|
| 5191 |
-
{ signal.apply(null, this$1.events[i]) }
|
| 5192 |
};
|
| 5193 |
|
| 5194 |
function maybeClipScrollbars(cm) {
|
| 5195 |
-
var display = cm.display
|
| 5196 |
if (!display.scrollbarsClipped && display.scroller.offsetWidth) {
|
| 5197 |
-
display.nativeBarWidth = display.scroller.offsetWidth - display.scroller.clientWidth
|
| 5198 |
-
display.heightForcer.style.height = scrollGap(cm) + "px"
|
| 5199 |
-
display.sizer.style.marginBottom = -display.nativeBarWidth + "px"
|
| 5200 |
-
display.sizer.style.borderRightWidth = scrollGap(cm) + "px"
|
| 5201 |
-
display.scrollbarsClipped = true
|
| 5202 |
}
|
| 5203 |
}
|
| 5204 |
|
|
@@ -5206,10 +5219,10 @@ webpackJsonp([2],{
|
|
| 5206 |
// (returning false) when there is nothing to be done and forced is
|
| 5207 |
// false.
|
| 5208 |
function updateDisplayIfNeeded(cm, update) {
|
| 5209 |
-
var display = cm.display, doc = cm.doc
|
| 5210 |
|
| 5211 |
if (update.editorIsHidden) {
|
| 5212 |
-
resetView(cm)
|
| 5213 |
return false
|
| 5214 |
}
|
| 5215 |
|
|
@@ -5221,101 +5234,101 @@ webpackJsonp([2],{
|
|
| 5221 |
{ return false }
|
| 5222 |
|
| 5223 |
if (maybeUpdateLineNumberWidth(cm)) {
|
| 5224 |
-
resetView(cm)
|
| 5225 |
-
update.dims = getDimensions(cm)
|
| 5226 |
}
|
| 5227 |
|
| 5228 |
// Compute a suitable new viewport (from & to)
|
| 5229 |
-
var end = doc.first + doc.size
|
| 5230 |
-
var from = Math.max(update.visible.from - cm.options.viewportMargin, doc.first)
|
| 5231 |
-
var to = Math.min(end, update.visible.to + cm.options.viewportMargin)
|
| 5232 |
-
if (display.viewFrom < from && from - display.viewFrom < 20) { from = Math.max(doc.first, display.viewFrom) }
|
| 5233 |
-
if (display.viewTo > to && display.viewTo - to < 20) { to = Math.min(end, display.viewTo) }
|
| 5234 |
if (sawCollapsedSpans) {
|
| 5235 |
-
from = visualLineNo(cm.doc, from)
|
| 5236 |
-
to = visualLineEndNo(cm.doc, to)
|
| 5237 |
}
|
| 5238 |
|
| 5239 |
var different = from != display.viewFrom || to != display.viewTo ||
|
| 5240 |
-
display.lastWrapHeight != update.wrapperHeight || display.lastWrapWidth != update.wrapperWidth
|
| 5241 |
-
adjustView(cm, from, to)
|
| 5242 |
|
| 5243 |
-
display.viewOffset = heightAtLine(getLine(cm.doc, display.viewFrom))
|
| 5244 |
// Position the mover div to align with the current scroll position
|
| 5245 |
-
cm.display.mover.style.top = display.viewOffset + "px"
|
| 5246 |
|
| 5247 |
-
var toUpdate = countDirtyView(cm)
|
| 5248 |
if (!different && toUpdate == 0 && !update.force && display.renderedView == display.view &&
|
| 5249 |
(display.updateLineNumbers == null || display.updateLineNumbers >= display.viewTo))
|
| 5250 |
{ return false }
|
| 5251 |
|
| 5252 |
// For big changes, we hide the enclosing element during the
|
| 5253 |
// update, since that speeds up the operations on most browsers.
|
| 5254 |
-
var focused = activeElt()
|
| 5255 |
-
if (toUpdate > 4) { display.lineDiv.style.display = "none" }
|
| 5256 |
-
patchDisplay(cm, display.updateLineNumbers, update.dims)
|
| 5257 |
-
if (toUpdate > 4) { display.lineDiv.style.display = "" }
|
| 5258 |
-
display.renderedView = display.view
|
| 5259 |
// There might have been a widget with a focused element that got
|
| 5260 |
// hidden or updated, if so re-focus it.
|
| 5261 |
-
if (focused && activeElt() != focused && focused.offsetHeight) { focused.focus() }
|
| 5262 |
|
| 5263 |
// Prevent selection and cursors from interfering with the scroll
|
| 5264 |
// width and height.
|
| 5265 |
-
removeChildren(display.cursorDiv)
|
| 5266 |
-
removeChildren(display.selectionDiv)
|
| 5267 |
-
display.gutters.style.height = display.sizer.style.minHeight = 0
|
| 5268 |
|
| 5269 |
if (different) {
|
| 5270 |
-
display.lastWrapHeight = update.wrapperHeight
|
| 5271 |
-
display.lastWrapWidth = update.wrapperWidth
|
| 5272 |
-
startWorker(cm, 400)
|
| 5273 |
}
|
| 5274 |
|
| 5275 |
-
display.updateLineNumbers = null
|
| 5276 |
|
| 5277 |
return true
|
| 5278 |
}
|
| 5279 |
|
| 5280 |
function postUpdateDisplay(cm, update) {
|
| 5281 |
-
var viewport = update.viewport
|
| 5282 |
|
| 5283 |
for (var first = true;; first = false) {
|
| 5284 |
if (!first || !cm.options.lineWrapping || update.oldDisplayWidth == displayWidth(cm)) {
|
| 5285 |
// Clip forced viewport to actual scrollable area.
|
| 5286 |
if (viewport && viewport.top != null)
|
| 5287 |
-
{ viewport = {top: Math.min(cm.doc.height + paddingVert(cm.display) - displayHeight(cm), viewport.top)} }
|
| 5288 |
// Updated line heights might result in the drawn area not
|
| 5289 |
// actually covering the viewport. Keep looping until it does.
|
| 5290 |
-
update.visible = visibleLines(cm.display, cm.doc, viewport)
|
| 5291 |
if (update.visible.from >= cm.display.viewFrom && update.visible.to <= cm.display.viewTo)
|
| 5292 |
{ break }
|
| 5293 |
}
|
| 5294 |
if (!updateDisplayIfNeeded(cm, update)) { break }
|
| 5295 |
-
updateHeightsInViewport(cm)
|
| 5296 |
-
var barMeasure = measureForScrollbars(cm)
|
| 5297 |
-
updateSelection(cm)
|
| 5298 |
-
updateScrollbars(cm, barMeasure)
|
| 5299 |
-
setDocumentHeight(cm, barMeasure)
|
| 5300 |
}
|
| 5301 |
|
| 5302 |
-
update.signal(cm, "update", cm)
|
| 5303 |
if (cm.display.viewFrom != cm.display.reportedViewFrom || cm.display.viewTo != cm.display.reportedViewTo) {
|
| 5304 |
-
update.signal(cm, "viewportChange", cm, cm.display.viewFrom, cm.display.viewTo)
|
| 5305 |
-
cm.display.reportedViewFrom = cm.display.viewFrom; cm.display.reportedViewTo = cm.display.viewTo
|
| 5306 |
}
|
| 5307 |
}
|
| 5308 |
|
| 5309 |
function updateDisplaySimple(cm, viewport) {
|
| 5310 |
-
var update = new DisplayUpdate(cm, viewport)
|
| 5311 |
if (updateDisplayIfNeeded(cm, update)) {
|
| 5312 |
-
updateHeightsInViewport(cm)
|
| 5313 |
-
postUpdateDisplay(cm, update)
|
| 5314 |
-
var barMeasure = measureForScrollbars(cm)
|
| 5315 |
-
updateSelection(cm)
|
| 5316 |
-
updateScrollbars(cm, barMeasure)
|
| 5317 |
-
setDocumentHeight(cm, barMeasure)
|
| 5318 |
-
update.finish()
|
| 5319 |
}
|
| 5320 |
}
|
| 5321 |
|
|
@@ -5324,85 +5337,85 @@ webpackJsonp([2],{
|
|
| 5324 |
// that are not there yet, and updating the ones that are out of
|
| 5325 |
// date.
|
| 5326 |
function patchDisplay(cm, updateNumbersFrom, dims) {
|
| 5327 |
-
var display = cm.display, lineNumbers = cm.options.lineNumbers
|
| 5328 |
-
var container = display.lineDiv, cur = container.firstChild
|
| 5329 |
|
| 5330 |
function rm(node) {
|
| 5331 |
-
var next = node.nextSibling
|
| 5332 |
// Works around a throw-scroll bug in OS X Webkit
|
| 5333 |
if (webkit && mac && cm.display.currentWheelTarget == node)
|
| 5334 |
-
{ node.style.display = "none" }
|
| 5335 |
else
|
| 5336 |
-
{ node.parentNode.removeChild(node) }
|
| 5337 |
return next
|
| 5338 |
}
|
| 5339 |
|
| 5340 |
-
var view = display.view, lineN = display.viewFrom
|
| 5341 |
// Loop over the elements in the view, syncing cur (the DOM nodes
|
| 5342 |
// in display.lineDiv) with the view as we go.
|
| 5343 |
for (var i = 0; i < view.length; i++) {
|
| 5344 |
-
var lineView = view[i]
|
| 5345 |
if (lineView.hidden) {
|
| 5346 |
} else if (!lineView.node || lineView.node.parentNode != container) { // Not drawn yet
|
| 5347 |
-
var node = buildLineElement(cm, lineView, lineN, dims)
|
| 5348 |
-
container.insertBefore(node, cur)
|
| 5349 |
} else { // Already drawn
|
| 5350 |
-
while (cur != lineView.node) { cur = rm(cur) }
|
| 5351 |
var updateNumber = lineNumbers && updateNumbersFrom != null &&
|
| 5352 |
-
updateNumbersFrom <= lineN && lineView.lineNumber
|
| 5353 |
if (lineView.changes) {
|
| 5354 |
-
if (indexOf(lineView.changes, "gutter") > -1) { updateNumber = false }
|
| 5355 |
-
updateLineForChanges(cm, lineView, lineN, dims)
|
| 5356 |
}
|
| 5357 |
if (updateNumber) {
|
| 5358 |
-
removeChildren(lineView.lineNumber)
|
| 5359 |
-
lineView.lineNumber.appendChild(document.createTextNode(lineNumberFor(cm.options, lineN)))
|
| 5360 |
}
|
| 5361 |
-
cur = lineView.node.nextSibling
|
| 5362 |
}
|
| 5363 |
-
lineN += lineView.size
|
| 5364 |
}
|
| 5365 |
-
while (cur) { cur = rm(cur) }
|
| 5366 |
}
|
| 5367 |
|
| 5368 |
function updateGutterSpace(cm) {
|
| 5369 |
-
var width = cm.display.gutters.offsetWidth
|
| 5370 |
-
cm.display.sizer.style.marginLeft = width + "px"
|
| 5371 |
}
|
| 5372 |
|
| 5373 |
function setDocumentHeight(cm, measure) {
|
| 5374 |
-
cm.display.sizer.style.minHeight = measure.docHeight + "px"
|
| 5375 |
-
cm.display.heightForcer.style.top = measure.docHeight + "px"
|
| 5376 |
-
cm.display.gutters.style.height = (measure.docHeight + cm.display.barHeight + scrollGap(cm)) + "px"
|
| 5377 |
}
|
| 5378 |
|
| 5379 |
// Rebuild the gutter elements, ensure the margin to the left of the
|
| 5380 |
// code matches their width.
|
| 5381 |
function updateGutters(cm) {
|
| 5382 |
-
var gutters = cm.display.gutters, specs = cm.options.gutters
|
| 5383 |
-
removeChildren(gutters)
|
| 5384 |
-
var i = 0
|
| 5385 |
for (; i < specs.length; ++i) {
|
| 5386 |
-
var gutterClass = specs[i]
|
| 5387 |
-
var gElt = gutters.appendChild(elt("div", null, "CodeMirror-gutter " + gutterClass))
|
| 5388 |
if (gutterClass == "CodeMirror-linenumbers") {
|
| 5389 |
-
cm.display.lineGutter = gElt
|
| 5390 |
-
gElt.style.width = (cm.display.lineNumWidth || 1) + "px"
|
| 5391 |
}
|
| 5392 |
}
|
| 5393 |
-
gutters.style.display = i ? "" : "none"
|
| 5394 |
-
updateGutterSpace(cm)
|
| 5395 |
}
|
| 5396 |
|
| 5397 |
// Make sure the gutters options contains the element
|
| 5398 |
// "CodeMirror-linenumbers" when the lineNumbers option is true.
|
| 5399 |
function setGuttersForLineNumbers(options) {
|
| 5400 |
-
var found = indexOf(options.gutters, "CodeMirror-linenumbers")
|
| 5401 |
if (found == -1 && options.lineNumbers) {
|
| 5402 |
-
options.gutters = options.gutters.concat(["CodeMirror-linenumbers"])
|
| 5403 |
} else if (found > -1 && !options.lineNumbers) {
|
| 5404 |
-
options.gutters = options.gutters.slice(0)
|
| 5405 |
-
options.gutters.splice(found, 1)
|
| 5406 |
}
|
| 5407 |
}
|
| 5408 |
|
|
@@ -5412,8 +5425,8 @@ webpackJsonp([2],{
|
|
| 5412 |
// which one is the primary selection (the one that's scrolled into
|
| 5413 |
// view, that getCursor returns, etc).
|
| 5414 |
var Selection = function(ranges, primIndex) {
|
| 5415 |
-
this.ranges = ranges
|
| 5416 |
-
this.primIndex = primIndex
|
| 5417 |
};
|
| 5418 |
|
| 5419 |
Selection.prototype.primary = function () { return this.ranges[this.primIndex] };
|
|
@@ -5424,7 +5437,7 @@ webpackJsonp([2],{
|
|
| 5424 |
if (other == this) { return true }
|
| 5425 |
if (other.primIndex != this.primIndex || other.ranges.length != this.ranges.length) { return false }
|
| 5426 |
for (var i = 0; i < this.ranges.length; i++) {
|
| 5427 |
-
var here = this$1.ranges[i], there = other.ranges[i]
|
| 5428 |
if (!equalCursorPos(here.anchor, there.anchor) || !equalCursorPos(here.head, there.head)) { return false }
|
| 5429 |
}
|
| 5430 |
return true
|
|
@@ -5433,9 +5446,9 @@ webpackJsonp([2],{
|
|
| 5433 |
Selection.prototype.deepCopy = function () {
|
| 5434 |
var this$1 = this;
|
| 5435 |
|
| 5436 |
-
var out = []
|
| 5437 |
for (var i = 0; i < this.ranges.length; i++)
|
| 5438 |
-
{ out[i] = new Range(copyPos(this$1.ranges[i].anchor), copyPos(this$1.ranges[i].head)) }
|
| 5439 |
return new Selection(out, this.primIndex)
|
| 5440 |
};
|
| 5441 |
|
|
@@ -5450,9 +5463,9 @@ webpackJsonp([2],{
|
|
| 5450 |
Selection.prototype.contains = function (pos, end) {
|
| 5451 |
var this$1 = this;
|
| 5452 |
|
| 5453 |
-
if (!end) { end = pos }
|
| 5454 |
for (var i = 0; i < this.ranges.length; i++) {
|
| 5455 |
-
var range = this$1.ranges[i]
|
| 5456 |
if (cmp(end, range.from()) >= 0 && cmp(pos, range.to()) <= 0)
|
| 5457 |
{ return i }
|
| 5458 |
}
|
|
@@ -5460,7 +5473,7 @@ webpackJsonp([2],{
|
|
| 5460 |
};
|
| 5461 |
|
| 5462 |
var Range = function(anchor, head) {
|
| 5463 |
-
this.anchor = anchor; this.head = head
|
| 5464 |
};
|
| 5465 |
|
| 5466 |
Range.prototype.from = function () { return minPos(this.anchor, this.head) };
|
|
@@ -5471,16 +5484,16 @@ webpackJsonp([2],{
|
|
| 5471 |
// build a selection out of it. 'Consumes' ranges array (modifying
|
| 5472 |
// it).
|
| 5473 |
function normalizeSelection(ranges, primIndex) {
|
| 5474 |
-
var prim = ranges[primIndex]
|
| 5475 |
-
ranges.sort(function (a, b) { return cmp(a.from(), b.from()); })
|
| 5476 |
-
primIndex = indexOf(ranges, prim)
|
| 5477 |
for (var i = 1; i < ranges.length; i++) {
|
| 5478 |
-
var cur = ranges[i], prev = ranges[i - 1]
|
| 5479 |
if (cmp(prev.to(), cur.from()) >= 0) {
|
| 5480 |
-
var from = minPos(prev.from(), cur.from()), to = maxPos(prev.to(), cur.to())
|
| 5481 |
-
var inv = prev.empty() ? cur.from() == cur.head : prev.from() == prev.head
|
| 5482 |
-
if (i <= primIndex) { --primIndex }
|
| 5483 |
-
ranges.splice(--i, 2, new Range(inv ? to : from, inv ? from : to))
|
| 5484 |
}
|
| 5485 |
}
|
| 5486 |
return new Selection(ranges, primIndex)
|
|
@@ -5504,17 +5517,17 @@ webpackJsonp([2],{
|
|
| 5504 |
if (cmp(pos, change.from) < 0) { return pos }
|
| 5505 |
if (cmp(pos, change.to) <= 0) { return changeEnd(change) }
|
| 5506 |
|
| 5507 |
-
var line = pos.line + change.text.length - (change.to.line - change.from.line) - 1, ch = pos.ch
|
| 5508 |
-
if (pos.line == change.to.line) { ch += changeEnd(change).ch - change.to.ch }
|
| 5509 |
return Pos(line, ch)
|
| 5510 |
}
|
| 5511 |
|
| 5512 |
function computeSelAfterChange(doc, change) {
|
| 5513 |
-
var out = []
|
| 5514 |
for (var i = 0; i < doc.sel.ranges.length; i++) {
|
| 5515 |
-
var range = doc.sel.ranges[i]
|
| 5516 |
out.push(new Range(adjustForChange(range.anchor, change),
|
| 5517 |
-
adjustForChange(range.head, change)))
|
| 5518 |
}
|
| 5519 |
return normalizeSelection(out, doc.sel.primIndex)
|
| 5520 |
}
|
|
@@ -5529,19 +5542,19 @@ webpackJsonp([2],{
|
|
| 5529 |
// Used by replaceSelections to allow moving the selection to the
|
| 5530 |
// start or around the replaced test. Hint may be "start" or "around".
|
| 5531 |
function computeReplacedSel(doc, changes, hint) {
|
| 5532 |
-
var out = []
|
| 5533 |
-
var oldPrev = Pos(doc.first, 0), newPrev = oldPrev
|
| 5534 |
for (var i = 0; i < changes.length; i++) {
|
| 5535 |
-
var change = changes[i]
|
| 5536 |
-
var from = offsetPos(change.from, oldPrev, newPrev)
|
| 5537 |
-
var to = offsetPos(changeEnd(change), oldPrev, newPrev)
|
| 5538 |
-
oldPrev = change.to
|
| 5539 |
-
newPrev = to
|
| 5540 |
if (hint == "around") {
|
| 5541 |
-
var range = doc.sel.ranges[i], inv = cmp(range.head, range.anchor) < 0
|
| 5542 |
-
out[i] = new Range(inv ? to : from, inv ? from : to)
|
| 5543 |
} else {
|
| 5544 |
-
out[i] = new Range(from, from)
|
| 5545 |
}
|
| 5546 |
}
|
| 5547 |
return new Selection(out, doc.sel.primIndex)
|
|
@@ -5550,19 +5563,19 @@ webpackJsonp([2],{
|
|
| 5550 |
// Used to get the editor into a consistent state again when options change.
|
| 5551 |
|
| 5552 |
function loadMode(cm) {
|
| 5553 |
-
cm.doc.mode = getMode(cm.options, cm.doc.modeOption)
|
| 5554 |
-
resetModeState(cm)
|
| 5555 |
}
|
| 5556 |
|
| 5557 |
function resetModeState(cm) {
|
| 5558 |
cm.doc.iter(function (line) {
|
| 5559 |
-
if (line.stateAfter) { line.stateAfter = null }
|
| 5560 |
-
if (line.styles) { line.styles = null }
|
| 5561 |
-
})
|
| 5562 |
-
cm.doc.frontier = cm.doc.first
|
| 5563 |
-
startWorker(cm, 100)
|
| 5564 |
-
cm.state.modeGen
|
| 5565 |
-
if (cm.curOp) { regChange(cm) }
|
| 5566 |
}
|
| 5567 |
|
| 5568 |
// DOCUMENT DATA STRUCTURE
|
|
@@ -5576,105 +5589,117 @@ webpackJsonp([2],{
|
|
| 5576 |
}
|
| 5577 |
|
| 5578 |
// Perform a change on the document data structure.
|
| 5579 |
-
function updateDoc(doc, change, markedSpans, estimateHeight) {
|
| 5580 |
function spansFor(n) {return markedSpans ? markedSpans[n] : null}
|
| 5581 |
function update(line, text, spans) {
|
| 5582 |
-
updateLine(line, text, spans, estimateHeight)
|
| 5583 |
-
signalLater(line, "change", line, change)
|
| 5584 |
}
|
| 5585 |
function linesFor(start, end) {
|
| 5586 |
-
var result = []
|
| 5587 |
for (var i = start; i < end; ++i)
|
| 5588 |
-
{ result.push(new Line(text[i], spansFor(i), estimateHeight)) }
|
| 5589 |
return result
|
| 5590 |
}
|
| 5591 |
|
| 5592 |
-
var from = change.from, to = change.to, text = change.text
|
| 5593 |
-
var firstLine = getLine(doc, from.line), lastLine = getLine(doc, to.line)
|
| 5594 |
-
var lastText = lst(text), lastSpans = spansFor(text.length - 1), nlines = to.line - from.line
|
| 5595 |
|
| 5596 |
// Adjust the line structure
|
| 5597 |
if (change.full) {
|
| 5598 |
-
doc.insert(0, linesFor(0, text.length))
|
| 5599 |
-
doc.remove(text.length, doc.size - text.length)
|
| 5600 |
} else if (isWholeLineUpdate(doc, change)) {
|
| 5601 |
// This is a whole-line replace. Treated specially to make
|
| 5602 |
// sure line objects move the way they are supposed to.
|
| 5603 |
-
var added = linesFor(0, text.length - 1)
|
| 5604 |
-
update(lastLine, lastLine.text, lastSpans)
|
| 5605 |
-
if (nlines) { doc.remove(from.line, nlines) }
|
| 5606 |
-
if (added.length) { doc.insert(from.line, added) }
|
| 5607 |
} else if (firstLine == lastLine) {
|
| 5608 |
if (text.length == 1) {
|
| 5609 |
-
update(firstLine, firstLine.text.slice(0, from.ch) + lastText + firstLine.text.slice(to.ch), lastSpans)
|
| 5610 |
} else {
|
| 5611 |
-
var added$1 = linesFor(1, text.length - 1)
|
| 5612 |
-
added$1.push(new Line(lastText + firstLine.text.slice(to.ch), lastSpans, estimateHeight))
|
| 5613 |
-
update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0))
|
| 5614 |
-
doc.insert(from.line + 1, added$1)
|
| 5615 |
}
|
| 5616 |
} else if (text.length == 1) {
|
| 5617 |
-
update(firstLine, firstLine.text.slice(0, from.ch) + text[0] + lastLine.text.slice(to.ch), spansFor(0))
|
| 5618 |
-
doc.remove(from.line + 1, nlines)
|
| 5619 |
} else {
|
| 5620 |
-
update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0))
|
| 5621 |
-
update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans)
|
| 5622 |
-
var added$2 = linesFor(1, text.length - 1)
|
| 5623 |
-
if (nlines > 1) { doc.remove(from.line + 1, nlines - 1) }
|
| 5624 |
-
doc.insert(from.line + 1, added$2)
|
| 5625 |
}
|
| 5626 |
|
| 5627 |
-
signalLater(doc, "change", doc, change)
|
| 5628 |
}
|
| 5629 |
|
| 5630 |
// Call f for all linked documents.
|
| 5631 |
function linkedDocs(doc, f, sharedHistOnly) {
|
| 5632 |
function propagate(doc, skip, sharedHist) {
|
| 5633 |
if (doc.linked) { for (var i = 0; i < doc.linked.length; ++i) {
|
| 5634 |
-
var rel = doc.linked[i]
|
| 5635 |
if (rel.doc == skip) { continue }
|
| 5636 |
-
var shared = sharedHist && rel.sharedHist
|
| 5637 |
if (sharedHistOnly && !shared) { continue }
|
| 5638 |
-
f(rel.doc, shared)
|
| 5639 |
-
propagate(rel.doc, doc, shared)
|
| 5640 |
} }
|
| 5641 |
}
|
| 5642 |
-
propagate(doc, null, true)
|
| 5643 |
}
|
| 5644 |
|
| 5645 |
// Attach a document to an editor.
|
| 5646 |
function attachDoc(cm, doc) {
|
| 5647 |
if (doc.cm) { throw new Error("This document is already in use.") }
|
| 5648 |
-
cm.doc = doc
|
| 5649 |
-
doc.cm = cm
|
| 5650 |
-
estimateLineHeights(cm)
|
| 5651 |
-
loadMode(cm)
|
| 5652 |
-
|
| 5653 |
-
cm.options.
|
| 5654 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5655 |
}
|
| 5656 |
|
| 5657 |
function History(startGen) {
|
| 5658 |
// Arrays of change events and selections. Doing something adds an
|
| 5659 |
// event to done and clears undo. Undoing moves events from done
|
| 5660 |
// to undone, redoing moves them in the other direction.
|
| 5661 |
-
this.done = []; this.undone = []
|
| 5662 |
-
this.undoDepth = Infinity
|
| 5663 |
// Used to track when changes can be merged into a single undo
|
| 5664 |
// event
|
| 5665 |
-
this.lastModTime = this.lastSelTime = 0
|
| 5666 |
-
this.lastOp = this.lastSelOp = null
|
| 5667 |
-
this.lastOrigin = this.lastSelOrigin = null
|
| 5668 |
// Used by the isClean() method
|
| 5669 |
-
this.generation = this.maxGeneration = startGen || 1
|
| 5670 |
}
|
| 5671 |
|
| 5672 |
// Create a history change event from an updateDoc-style change
|
| 5673 |
// object.
|
| 5674 |
function historyChangeFromChange(doc, change) {
|
| 5675 |
-
var histChange = {from: copyPos(change.from), to: changeEnd(change), text: getBetween(doc, change.from, change.to)}
|
| 5676 |
-
attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1)
|
| 5677 |
-
linkedDocs(doc, function (doc) { return attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1); }, true)
|
| 5678 |
return histChange
|
| 5679 |
}
|
| 5680 |
|
|
@@ -5682,8 +5707,8 @@ webpackJsonp([2],{
|
|
| 5682 |
// a change event.
|
| 5683 |
function clearSelectionEvents(array) {
|
| 5684 |
while (array.length) {
|
| 5685 |
-
var last = lst(array)
|
| 5686 |
-
if (last.ranges) { array.pop() }
|
| 5687 |
else { break }
|
| 5688 |
}
|
| 5689 |
}
|
|
@@ -5692,12 +5717,12 @@ webpackJsonp([2],{
|
|
| 5692 |
// events that are in the way.
|
| 5693 |
function lastChangeEvent(hist, force) {
|
| 5694 |
if (force) {
|
| 5695 |
-
clearSelectionEvents(hist.done)
|
| 5696 |
return lst(hist.done)
|
| 5697 |
} else if (hist.done.length && !lst(hist.done).ranges) {
|
| 5698 |
return lst(hist.done)
|
| 5699 |
} else if (hist.done.length > 1 && !hist.done[hist.done.length - 2].ranges) {
|
| 5700 |
-
hist.done.pop()
|
| 5701 |
return lst(hist.done)
|
| 5702 |
}
|
| 5703 |
}
|
|
@@ -5706,10 +5731,10 @@ webpackJsonp([2],{
|
|
| 5706 |
// a single operation, or are close together with an origin that
|
| 5707 |
// allows merging (starting with "+") into a single event.
|
| 5708 |
function addChangeToHistory(doc, change, selAfter, opId) {
|
| 5709 |
-
var hist = doc.history
|
| 5710 |
-
hist.undone.length = 0
|
| 5711 |
-
var time = +new Date, cur
|
| 5712 |
-
var last
|
| 5713 |
|
| 5714 |
if ((hist.lastOp == opId ||
|
| 5715 |
hist.lastOrigin == change.origin && change.origin &&
|
|
@@ -5717,39 +5742,39 @@ webpackJsonp([2],{
|
|
| 5717 |
change.origin.charAt(0) == "*")) &&
|
| 5718 |
(cur = lastChangeEvent(hist, hist.lastOp == opId))) {
|
| 5719 |
// Merge this change into the last event
|
| 5720 |
-
last = lst(cur.changes)
|
| 5721 |
if (cmp(change.from, change.to) == 0 && cmp(change.from, last.to) == 0) {
|
| 5722 |
// Optimized case for simple insertion -- don't want to add
|
| 5723 |
// new changesets for every character typed
|
| 5724 |
-
last.to = changeEnd(change)
|
| 5725 |
} else {
|
| 5726 |
// Add new sub-event
|
| 5727 |
-
cur.changes.push(historyChangeFromChange(doc, change))
|
| 5728 |
}
|
| 5729 |
} else {
|
| 5730 |
// Can not be merged, start a new event.
|
| 5731 |
-
var before = lst(hist.done)
|
| 5732 |
if (!before || !before.ranges)
|
| 5733 |
-
{ pushSelectionToHistory(doc.sel, hist.done) }
|
| 5734 |
cur = {changes: [historyChangeFromChange(doc, change)],
|
| 5735 |
-
generation: hist.generation}
|
| 5736 |
-
hist.done.push(cur)
|
| 5737 |
while (hist.done.length > hist.undoDepth) {
|
| 5738 |
-
hist.done.shift()
|
| 5739 |
-
if (!hist.done[0].ranges) { hist.done.shift() }
|
| 5740 |
}
|
| 5741 |
}
|
| 5742 |
-
hist.done.push(selAfter)
|
| 5743 |
-
hist.generation = ++hist.maxGeneration
|
| 5744 |
-
hist.lastModTime = hist.lastSelTime = time
|
| 5745 |
-
hist.lastOp = hist.lastSelOp = opId
|
| 5746 |
-
hist.lastOrigin = hist.lastSelOrigin = change.origin
|
| 5747 |
|
| 5748 |
-
if (!last) { signal(doc, "historyAdded") }
|
| 5749 |
}
|
| 5750 |
|
| 5751 |
function selectionEventCanBeMerged(doc, origin, prev, sel) {
|
| 5752 |
-
var ch = origin.charAt(0)
|
| 5753 |
return ch == "*" ||
|
| 5754 |
ch == "+" &&
|
| 5755 |
prev.ranges.length == sel.ranges.length &&
|
|
@@ -5762,7 +5787,7 @@ webpackJsonp([2],{
|
|
| 5762 |
// selection into the 'done' array when it was significantly
|
| 5763 |
// different (in number of selected ranges, emptiness, or time).
|
| 5764 |
function addSelectionToHistory(doc, sel, opId, options) {
|
| 5765 |
-
var hist = doc.history, origin = options && options.origin
|
| 5766 |
|
| 5767 |
// A new event is started when the previous origin does not match
|
| 5768 |
// the current, or the origins don't allow matching. Origins
|
|
@@ -5772,52 +5797,52 @@ webpackJsonp([2],{
|
|
| 5772 |
(origin && hist.lastSelOrigin == origin &&
|
| 5773 |
(hist.lastModTime == hist.lastSelTime && hist.lastOrigin == origin ||
|
| 5774 |
selectionEventCanBeMerged(doc, origin, lst(hist.done), sel))))
|
| 5775 |
-
{ hist.done[hist.done.length - 1] = sel }
|
| 5776 |
else
|
| 5777 |
-
{ pushSelectionToHistory(sel, hist.done) }
|
| 5778 |
|
| 5779 |
-
hist.lastSelTime = +new Date
|
| 5780 |
-
hist.lastSelOrigin = origin
|
| 5781 |
-
hist.lastSelOp = opId
|
| 5782 |
if (options && options.clearRedo !== false)
|
| 5783 |
-
{ clearSelectionEvents(hist.undone) }
|
| 5784 |
}
|
| 5785 |
|
| 5786 |
function pushSelectionToHistory(sel, dest) {
|
| 5787 |
-
var top = lst(dest)
|
| 5788 |
if (!(top && top.ranges && top.equals(sel)))
|
| 5789 |
-
{ dest.push(sel) }
|
| 5790 |
}
|
| 5791 |
|
| 5792 |
// Used to store marked span information in the history.
|
| 5793 |
function attachLocalSpans(doc, change, from, to) {
|
| 5794 |
-
var existing = change["spans_" + doc.id], n = 0
|
| 5795 |
doc.iter(Math.max(doc.first, from), Math.min(doc.first + doc.size, to), function (line) {
|
| 5796 |
if (line.markedSpans)
|
| 5797 |
-
{ (existing || (existing = change["spans_" + doc.id] = {}))[n] = line.markedSpans }
|
| 5798 |
-
++n
|
| 5799 |
-
})
|
| 5800 |
}
|
| 5801 |
|
| 5802 |
// When un/re-doing restores text containing marked spans, those
|
| 5803 |
// that have been explicitly cleared should not be restored.
|
| 5804 |
function removeClearedSpans(spans) {
|
| 5805 |
if (!spans) { return null }
|
| 5806 |
-
var out
|
| 5807 |
for (var i = 0; i < spans.length; ++i) {
|
| 5808 |
-
if (spans[i].marker.explicitlyCleared) { if (!out) { out = spans.slice(0, i) } }
|
| 5809 |
-
else if (out) { out.push(spans[i]) }
|
| 5810 |
}
|
| 5811 |
return !out ? spans : out.length ? out : null
|
| 5812 |
}
|
| 5813 |
|
| 5814 |
// Retrieve and filter the old marked spans stored in a change event.
|
| 5815 |
function getOldSpans(doc, change) {
|
| 5816 |
-
var found = change["spans_" + doc.id]
|
| 5817 |
if (!found) { return null }
|
| 5818 |
-
var nw = []
|
| 5819 |
for (var i = 0; i < change.text.length; ++i)
|
| 5820 |
-
{ nw.push(removeClearedSpans(found[i])) }
|
| 5821 |
return nw
|
| 5822 |
}
|
| 5823 |
|
|
@@ -5826,22 +5851,22 @@ webpackJsonp([2],{
|
|
| 5826 |
// existed in the history (so that deleting around a span and then
|
| 5827 |
// undoing brings back the span).
|
| 5828 |
function mergeOldSpans(doc, change) {
|
| 5829 |
-
var old = getOldSpans(doc, change)
|
| 5830 |
-
var stretched = stretchSpansOverChange(doc, change)
|
| 5831 |
if (!old) { return stretched }
|
| 5832 |
if (!stretched) { return old }
|
| 5833 |
|
| 5834 |
for (var i = 0; i < old.length; ++i) {
|
| 5835 |
-
var oldCur = old[i], stretchCur = stretched[i]
|
| 5836 |
if (oldCur && stretchCur) {
|
| 5837 |
spans: for (var j = 0; j < stretchCur.length; ++j) {
|
| 5838 |
-
var span = stretchCur[j]
|
| 5839 |
for (var k = 0; k < oldCur.length; ++k)
|
| 5840 |
{ if (oldCur[k].marker == span.marker) { continue spans } }
|
| 5841 |
-
oldCur.push(span)
|
| 5842 |
}
|
| 5843 |
} else if (stretchCur) {
|
| 5844 |
-
old[i] = stretchCur
|
| 5845 |
}
|
| 5846 |
}
|
| 5847 |
return old
|
|
@@ -5850,22 +5875,22 @@ webpackJsonp([2],{
|
|
| 5850 |
// Used both to provide a JSON-safe object in .getHistory, and, when
|
| 5851 |
// detaching a document, to split the history in two
|
| 5852 |
function copyHistoryArray(events, newGroup, instantiateSel) {
|
| 5853 |
-
var copy = []
|
| 5854 |
for (var i = 0; i < events.length; ++i) {
|
| 5855 |
-
var event = events[i]
|
| 5856 |
if (event.ranges) {
|
| 5857 |
-
copy.push(instantiateSel ? Selection.prototype.deepCopy.call(event) : event)
|
| 5858 |
continue
|
| 5859 |
}
|
| 5860 |
-
var changes = event.changes, newChanges = []
|
| 5861 |
-
copy.push({changes: newChanges})
|
| 5862 |
for (var j = 0; j < changes.length; ++j) {
|
| 5863 |
-
var change = changes[j], m = (void 0)
|
| 5864 |
-
newChanges.push({from: change.from, to: change.to, text: change.text})
|
| 5865 |
if (newGroup) { for (var prop in change) { if (m = prop.match(/^spans_(\d+)$/)) {
|
| 5866 |
if (indexOf(newGroup, Number(m[1])) > -1) {
|
| 5867 |
-
lst(newChanges)[prop] = change[prop]
|
| 5868 |
-
delete change[prop]
|
| 5869 |
}
|
| 5870 |
} } }
|
| 5871 |
}
|
|
@@ -5883,14 +5908,14 @@ webpackJsonp([2],{
|
|
| 5883 |
// Used for cursor motion and such.
|
| 5884 |
function extendRange(doc, range, head, other) {
|
| 5885 |
if (doc.cm && doc.cm.display.shift || doc.extend) {
|
| 5886 |
-
var anchor = range.anchor
|
| 5887 |
if (other) {
|
| 5888 |
-
var posBefore = cmp(head, anchor) < 0
|
| 5889 |
if (posBefore != (cmp(other, anchor) < 0)) {
|
| 5890 |
-
anchor = head
|
| 5891 |
-
head = other
|
| 5892 |
} else if (posBefore != (cmp(head, other) < 0)) {
|
| 5893 |
-
head = other
|
| 5894 |
}
|
| 5895 |
}
|
| 5896 |
return new Range(anchor, head)
|
|
@@ -5901,29 +5926,29 @@ webpackJsonp([2],{
|
|
| 5901 |
|
| 5902 |
// Extend the primary selection range, discard the rest.
|
| 5903 |
function extendSelection(doc, head, other, options) {
|
| 5904 |
-
setSelection(doc, new Selection([extendRange(doc, doc.sel.primary(), head, other)], 0), options)
|
| 5905 |
}
|
| 5906 |
|
| 5907 |
// Extend all selections (pos is an array of selections with length
|
| 5908 |
// equal the number of selections)
|
| 5909 |
function extendSelections(doc, heads, options) {
|
| 5910 |
-
var out = []
|
| 5911 |
for (var i = 0; i < doc.sel.ranges.length; i++)
|
| 5912 |
-
{ out[i] = extendRange(doc, doc.sel.ranges[i], heads[i], null) }
|
| 5913 |
-
var newSel = normalizeSelection(out, doc.sel.primIndex)
|
| 5914 |
-
setSelection(doc, newSel, options)
|
| 5915 |
}
|
| 5916 |
|
| 5917 |
// Updates a single range in the selection.
|
| 5918 |
function replaceOneSelection(doc, i, range, options) {
|
| 5919 |
-
var ranges = doc.sel.ranges.slice(0)
|
| 5920 |
-
ranges[i] = range
|
| 5921 |
-
setSelection(doc, normalizeSelection(ranges, doc.sel.primIndex), options)
|
| 5922 |
}
|
| 5923 |
|
| 5924 |
// Reset the selection to a single range.
|
| 5925 |
function setSimpleSelection(doc, anchor, head, options) {
|
| 5926 |
-
setSelection(doc, simpleSelection(anchor, head), options)
|
| 5927 |
}
|
| 5928 |
|
| 5929 |
// Give beforeSelectionChange handlers a change to influence a
|
|
@@ -5934,90 +5959,90 @@ webpackJsonp([2],{
|
|
| 5934 |
update: function(ranges) {
|
| 5935 |
var this$1 = this;
|
| 5936 |
|
| 5937 |
-
this.ranges = []
|
| 5938 |
for (var i = 0; i < ranges.length; i++)
|
| 5939 |
{ this$1.ranges[i] = new Range(clipPos(doc, ranges[i].anchor),
|
| 5940 |
-
clipPos(doc, ranges[i].head)) }
|
| 5941 |
},
|
| 5942 |
origin: options && options.origin
|
| 5943 |
-
}
|
| 5944 |
-
signal(doc, "beforeSelectionChange", doc, obj)
|
| 5945 |
-
if (doc.cm) { signal(doc.cm, "beforeSelectionChange", doc.cm, obj) }
|
| 5946 |
if (obj.ranges != sel.ranges) { return normalizeSelection(obj.ranges, obj.ranges.length - 1) }
|
| 5947 |
else { return sel }
|
| 5948 |
}
|
| 5949 |
|
| 5950 |
function setSelectionReplaceHistory(doc, sel, options) {
|
| 5951 |
-
var done = doc.history.done, last = lst(done)
|
| 5952 |
if (last && last.ranges) {
|
| 5953 |
-
done[done.length - 1] = sel
|
| 5954 |
-
setSelectionNoUndo(doc, sel, options)
|
| 5955 |
} else {
|
| 5956 |
-
setSelection(doc, sel, options)
|
| 5957 |
}
|
| 5958 |
}
|
| 5959 |
|
| 5960 |
// Set a new selection.
|
| 5961 |
function setSelection(doc, sel, options) {
|
| 5962 |
-
setSelectionNoUndo(doc, sel, options)
|
| 5963 |
-
addSelectionToHistory(doc, doc.sel, doc.cm ? doc.cm.curOp.id : NaN, options)
|
| 5964 |
}
|
| 5965 |
|
| 5966 |
function setSelectionNoUndo(doc, sel, options) {
|
| 5967 |
if (hasHandler(doc, "beforeSelectionChange") || doc.cm && hasHandler(doc.cm, "beforeSelectionChange"))
|
| 5968 |
-
{ sel = filterSelectionChange(doc, sel, options) }
|
| 5969 |
|
| 5970 |
var bias = options && options.bias ||
|
| 5971 |
-
(cmp(sel.primary().head, doc.sel.primary().head) < 0 ? -1 : 1)
|
| 5972 |
-
setSelectionInner(doc, skipAtomicInSelection(doc, sel, bias, true))
|
| 5973 |
|
| 5974 |
if (!(options && options.scroll === false) && doc.cm)
|
| 5975 |
-
{ ensureCursorVisible(doc.cm) }
|
| 5976 |
}
|
| 5977 |
|
| 5978 |
function setSelectionInner(doc, sel) {
|
| 5979 |
if (sel.equals(doc.sel)) { return }
|
| 5980 |
|
| 5981 |
-
doc.sel = sel
|
| 5982 |
|
| 5983 |
if (doc.cm) {
|
| 5984 |
-
doc.cm.curOp.updateInput = doc.cm.curOp.selectionChanged = true
|
| 5985 |
-
signalCursorActivity(doc.cm)
|
| 5986 |
}
|
| 5987 |
-
signalLater(doc, "cursorActivity", doc)
|
| 5988 |
}
|
| 5989 |
|
| 5990 |
// Verify that the selection does not partially select any atomic
|
| 5991 |
// marked ranges.
|
| 5992 |
function reCheckSelection(doc) {
|
| 5993 |
-
setSelectionInner(doc, skipAtomicInSelection(doc, doc.sel, null, false), sel_dontScroll)
|
| 5994 |
}
|
| 5995 |
|
| 5996 |
// Return a selection that does not partially select any atomic
|
| 5997 |
// ranges.
|
| 5998 |
function skipAtomicInSelection(doc, sel, bias, mayClear) {
|
| 5999 |
-
var out
|
| 6000 |
for (var i = 0; i < sel.ranges.length; i++) {
|
| 6001 |
-
var range = sel.ranges[i]
|
| 6002 |
-
var old = sel.ranges.length == doc.sel.ranges.length && doc.sel.ranges[i]
|
| 6003 |
-
var newAnchor = skipAtomic(doc, range.anchor, old && old.anchor, bias, mayClear)
|
| 6004 |
-
var newHead = skipAtomic(doc, range.head, old && old.head, bias, mayClear)
|
| 6005 |
if (out || newAnchor != range.anchor || newHead != range.head) {
|
| 6006 |
-
if (!out) { out = sel.ranges.slice(0, i) }
|
| 6007 |
-
out[i] = new Range(newAnchor, newHead)
|
| 6008 |
}
|
| 6009 |
}
|
| 6010 |
return out ? normalizeSelection(out, sel.primIndex) : sel
|
| 6011 |
}
|
| 6012 |
|
| 6013 |
function skipAtomicInner(doc, pos, oldPos, dir, mayClear) {
|
| 6014 |
-
var line = getLine(doc, pos.line)
|
| 6015 |
if (line.markedSpans) { for (var i = 0; i < line.markedSpans.length; ++i) {
|
| 6016 |
-
var sp = line.markedSpans[i], m = sp.marker
|
| 6017 |
if ((sp.from == null || (m.inclusiveLeft ? sp.from <= pos.ch : sp.from < pos.ch)) &&
|
| 6018 |
(sp.to == null || (m.inclusiveRight ? sp.to >= pos.ch : sp.to > pos.ch))) {
|
| 6019 |
if (mayClear) {
|
| 6020 |
-
signal(m, "beforeCursorEnter")
|
| 6021 |
if (m.explicitlyCleared) {
|
| 6022 |
if (!line.markedSpans) { break }
|
| 6023 |
else {--i; continue}
|
|
@@ -6026,16 +6051,16 @@ webpackJsonp([2],{
|
|
| 6026 |
if (!m.atomic) { continue }
|
| 6027 |
|
| 6028 |
if (oldPos) {
|
| 6029 |
-
var near = m.find(dir < 0 ? 1 : -1), diff = (void 0)
|
| 6030 |
if (dir < 0 ? m.inclusiveRight : m.inclusiveLeft)
|
| 6031 |
-
{ near = movePos(doc, near, -dir, near && near.line == pos.line ? line : null) }
|
| 6032 |
if (near && near.line == pos.line && (diff = cmp(near, oldPos)) && (dir < 0 ? diff < 0 : diff > 0))
|
| 6033 |
{ return skipAtomicInner(doc, near, pos, dir, mayClear) }
|
| 6034 |
}
|
| 6035 |
|
| 6036 |
-
var far = m.find(dir < 0 ? -1 : 1)
|
| 6037 |
if (dir < 0 ? m.inclusiveLeft : m.inclusiveRight)
|
| 6038 |
-
{ far = movePos(doc, far, dir, far.line == pos.line ? line : null) }
|
| 6039 |
return far ? skipAtomicInner(doc, far, pos, dir, mayClear) : null
|
| 6040 |
}
|
| 6041 |
} }
|
|
@@ -6044,13 +6069,13 @@ webpackJsonp([2],{
|
|
| 6044 |
|
| 6045 |
// Ensure a given position is not inside an atomic range.
|
| 6046 |
function skipAtomic(doc, pos, oldPos, bias, mayClear) {
|
| 6047 |
-
var dir = bias || 1
|
| 6048 |
var found = skipAtomicInner(doc, pos, oldPos, dir, mayClear) ||
|
| 6049 |
(!mayClear && skipAtomicInner(doc, pos, oldPos, dir, true)) ||
|
| 6050 |
skipAtomicInner(doc, pos, oldPos, -dir, mayClear) ||
|
| 6051 |
-
(!mayClear && skipAtomicInner(doc, pos, oldPos, -dir, true))
|
| 6052 |
if (!found) {
|
| 6053 |
-
doc.cantEdit = true
|
| 6054 |
return Pos(doc.first, 0)
|
| 6055 |
}
|
| 6056 |
return found
|
|
@@ -6069,7 +6094,7 @@ webpackJsonp([2],{
|
|
| 6069 |
}
|
| 6070 |
|
| 6071 |
function selectAll(cm) {
|
| 6072 |
-
cm.setSelection(Pos(cm.firstLine(), 0), Pos(cm.lastLine()), sel_dontScroll)
|
| 6073 |
}
|
| 6074 |
|
| 6075 |
// UPDATING
|
|
@@ -6083,15 +6108,15 @@ webpackJsonp([2],{
|
|
| 6083 |
text: change.text,
|
| 6084 |
origin: change.origin,
|
| 6085 |
cancel: function () { return obj.canceled = true; }
|
| 6086 |
-
}
|
| 6087 |
if (update) { obj.update = function (from, to, text, origin) {
|
| 6088 |
-
if (from) { obj.from = clipPos(doc, from) }
|
| 6089 |
-
if (to) { obj.to = clipPos(doc, to) }
|
| 6090 |
-
if (text) { obj.text = text }
|
| 6091 |
-
if (origin !== undefined) { obj.origin = origin }
|
| 6092 |
-
} }
|
| 6093 |
-
signal(doc, "beforeChange", doc, obj)
|
| 6094 |
-
if (doc.cm) { signal(doc.cm, "beforeChange", doc.cm, obj) }
|
| 6095 |
|
| 6096 |
if (obj.canceled) { return null }
|
| 6097 |
return {from: obj.from, to: obj.to, text: obj.text, origin: obj.origin}
|
|
@@ -6106,101 +6131,101 @@ webpackJsonp([2],{
|
|
| 6106 |
}
|
| 6107 |
|
| 6108 |
if (hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange")) {
|
| 6109 |
-
change = filterChange(doc, change, true)
|
| 6110 |
if (!change) { return }
|
| 6111 |
}
|
| 6112 |
|
| 6113 |
// Possibly split or suppress the update based on the presence
|
| 6114 |
// of read-only spans in its range.
|
| 6115 |
-
var split = sawReadOnlySpans && !ignoreReadOnly && removeReadOnlyRanges(doc, change.from, change.to)
|
| 6116 |
if (split) {
|
| 6117 |
for (var i = split.length - 1; i >= 0; --i)
|
| 6118 |
-
{ makeChangeInner(doc, {from: split[i].from, to: split[i].to, text: i ? [""] : change.text}) }
|
| 6119 |
} else {
|
| 6120 |
-
makeChangeInner(doc, change)
|
| 6121 |
}
|
| 6122 |
}
|
| 6123 |
|
| 6124 |
function makeChangeInner(doc, change) {
|
| 6125 |
if (change.text.length == 1 && change.text[0] == "" && cmp(change.from, change.to) == 0) { return }
|
| 6126 |
-
var selAfter = computeSelAfterChange(doc, change)
|
| 6127 |
-
addChangeToHistory(doc, change, selAfter, doc.cm ? doc.cm.curOp.id : NaN)
|
| 6128 |
|
| 6129 |
-
makeChangeSingleDoc(doc, change, selAfter, stretchSpansOverChange(doc, change))
|
| 6130 |
-
var rebased = []
|
| 6131 |
|
| 6132 |
linkedDocs(doc, function (doc, sharedHist) {
|
| 6133 |
if (!sharedHist && indexOf(rebased, doc.history) == -1) {
|
| 6134 |
-
rebaseHist(doc.history, change)
|
| 6135 |
-
rebased.push(doc.history)
|
| 6136 |
}
|
| 6137 |
-
makeChangeSingleDoc(doc, change, null, stretchSpansOverChange(doc, change))
|
| 6138 |
-
})
|
| 6139 |
}
|
| 6140 |
|
| 6141 |
// Revert a change stored in a document's history.
|
| 6142 |
function makeChangeFromHistory(doc, type, allowSelectionOnly) {
|
| 6143 |
if (doc.cm && doc.cm.state.suppressEdits && !allowSelectionOnly) { return }
|
| 6144 |
|
| 6145 |
-
var hist = doc.history, event, selAfter = doc.sel
|
| 6146 |
-
var source = type == "undo" ? hist.done : hist.undone, dest = type == "undo" ? hist.undone : hist.done
|
| 6147 |
|
| 6148 |
// Verify that there is a useable event (so that ctrl-z won't
|
| 6149 |
// needlessly clear selection events)
|
| 6150 |
-
var i = 0
|
| 6151 |
for (; i < source.length; i++) {
|
| 6152 |
-
event = source[i]
|
| 6153 |
if (allowSelectionOnly ? event.ranges && !event.equals(doc.sel) : !event.ranges)
|
| 6154 |
{ break }
|
| 6155 |
}
|
| 6156 |
if (i == source.length) { return }
|
| 6157 |
-
hist.lastOrigin = hist.lastSelOrigin = null
|
| 6158 |
|
| 6159 |
for (;;) {
|
| 6160 |
-
event = source.pop()
|
| 6161 |
if (event.ranges) {
|
| 6162 |
-
pushSelectionToHistory(event, dest)
|
| 6163 |
if (allowSelectionOnly && !event.equals(doc.sel)) {
|
| 6164 |
-
setSelection(doc, event, {clearRedo: false})
|
| 6165 |
return
|
| 6166 |
}
|
| 6167 |
-
selAfter = event
|
| 6168 |
}
|
| 6169 |
else { break }
|
| 6170 |
}
|
| 6171 |
|
| 6172 |
// Build up a reverse change object to add to the opposite history
|
| 6173 |
// stack (redo when undoing, and vice versa).
|
| 6174 |
-
var antiChanges = []
|
| 6175 |
-
pushSelectionToHistory(selAfter, dest)
|
| 6176 |
-
dest.push({changes: antiChanges, generation: hist.generation})
|
| 6177 |
-
hist.generation = event.generation || ++hist.maxGeneration
|
| 6178 |
|
| 6179 |
-
var filter = hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange")
|
| 6180 |
|
| 6181 |
var loop = function ( i ) {
|
| 6182 |
-
var change = event.changes[i]
|
| 6183 |
-
change.origin = type
|
| 6184 |
if (filter && !filterChange(doc, change, false)) {
|
| 6185 |
-
source.length = 0
|
| 6186 |
return {}
|
| 6187 |
}
|
| 6188 |
|
| 6189 |
-
antiChanges.push(historyChangeFromChange(doc, change))
|
| 6190 |
|
| 6191 |
-
var after = i ? computeSelAfterChange(doc, change) : lst(source)
|
| 6192 |
-
makeChangeSingleDoc(doc, change, after, mergeOldSpans(doc, change))
|
| 6193 |
-
if (!i && doc.cm) { doc.cm.scrollIntoView({from: change.from, to: changeEnd(change)}) }
|
| 6194 |
-
var rebased = []
|
| 6195 |
|
| 6196 |
// Propagate to the linked documents
|
| 6197 |
linkedDocs(doc, function (doc, sharedHist) {
|
| 6198 |
if (!sharedHist && indexOf(rebased, doc.history) == -1) {
|
| 6199 |
-
rebaseHist(doc.history, change)
|
| 6200 |
-
rebased.push(doc.history)
|
| 6201 |
}
|
| 6202 |
-
makeChangeSingleDoc(doc, change, null, mergeOldSpans(doc, change))
|
| 6203 |
-
})
|
| 6204 |
};
|
| 6205 |
|
| 6206 |
for (var i$1 = event.changes.length - 1; i$1 >= 0; --i$1) {
|
|
@@ -6214,15 +6239,15 @@ webpackJsonp([2],{
|
|
| 6214 |
// above or below them in the parent document.
|
| 6215 |
function shiftDoc(doc, distance) {
|
| 6216 |
if (distance == 0) { return }
|
| 6217 |
-
doc.first += distance
|
| 6218 |
doc.sel = new Selection(map(doc.sel.ranges, function (range) { return new Range(
|
| 6219 |
Pos(range.anchor.line + distance, range.anchor.ch),
|
| 6220 |
Pos(range.head.line + distance, range.head.ch)
|
| 6221 |
-
); }), doc.sel.primIndex)
|
| 6222 |
if (doc.cm) {
|
| 6223 |
-
regChange(doc.cm, doc.first, doc.first - distance, distance)
|
| 6224 |
for (var d = doc.cm.display, l = d.viewFrom; l < d.viewTo; l++)
|
| 6225 |
-
{ regLineChange(doc.cm, l, "gutter") }
|
| 6226 |
}
|
| 6227 |
}
|
| 6228 |
|
|
@@ -6233,108 +6258,108 @@ webpackJsonp([2],{
|
|
| 6233 |
{ return operation(doc.cm, makeChangeSingleDoc)(doc, change, selAfter, spans) }
|
| 6234 |
|
| 6235 |
if (change.to.line < doc.first) {
|
| 6236 |
-
shiftDoc(doc, change.text.length - 1 - (change.to.line - change.from.line))
|
| 6237 |
return
|
| 6238 |
}
|
| 6239 |
if (change.from.line > doc.lastLine()) { return }
|
| 6240 |
|
| 6241 |
// Clip the change to the size of this doc
|
| 6242 |
if (change.from.line < doc.first) {
|
| 6243 |
-
var shift = change.text.length - 1 - (doc.first - change.from.line)
|
| 6244 |
-
shiftDoc(doc, shift)
|
| 6245 |
change = {from: Pos(doc.first, 0), to: Pos(change.to.line + shift, change.to.ch),
|
| 6246 |
-
text: [lst(change.text)], origin: change.origin}
|
| 6247 |
}
|
| 6248 |
-
var last = doc.lastLine()
|
| 6249 |
if (change.to.line > last) {
|
| 6250 |
change = {from: change.from, to: Pos(last, getLine(doc, last).text.length),
|
| 6251 |
-
text: [change.text[0]], origin: change.origin}
|
| 6252 |
}
|
| 6253 |
|
| 6254 |
-
change.removed = getBetween(doc, change.from, change.to)
|
| 6255 |
|
| 6256 |
-
if (!selAfter) { selAfter = computeSelAfterChange(doc, change) }
|
| 6257 |
-
if (doc.cm) { makeChangeSingleDocInEditor(doc.cm, change, spans) }
|
| 6258 |
-
else { updateDoc(doc, change, spans) }
|
| 6259 |
-
setSelectionNoUndo(doc, selAfter, sel_dontScroll)
|
| 6260 |
}
|
| 6261 |
|
| 6262 |
// Handle the interaction of a change to a document with the editor
|
| 6263 |
// that this document is part of.
|
| 6264 |
function makeChangeSingleDocInEditor(cm, change, spans) {
|
| 6265 |
-
var doc = cm.doc, display = cm.display, from = change.from, to = change.to
|
| 6266 |
|
| 6267 |
-
var recomputeMaxLength = false, checkWidthStart = from.line
|
| 6268 |
if (!cm.options.lineWrapping) {
|
| 6269 |
-
checkWidthStart = lineNo(visualLine(getLine(doc, from.line)))
|
| 6270 |
doc.iter(checkWidthStart, to.line + 1, function (line) {
|
| 6271 |
if (line == display.maxLine) {
|
| 6272 |
-
recomputeMaxLength = true
|
| 6273 |
return true
|
| 6274 |
}
|
| 6275 |
-
})
|
| 6276 |
}
|
| 6277 |
|
| 6278 |
if (doc.sel.contains(change.from, change.to) > -1)
|
| 6279 |
-
{ signalCursorActivity(cm) }
|
| 6280 |
|
| 6281 |
-
updateDoc(doc, change, spans, estimateHeight(cm))
|
| 6282 |
|
| 6283 |
if (!cm.options.lineWrapping) {
|
| 6284 |
doc.iter(checkWidthStart, from.line + change.text.length, function (line) {
|
| 6285 |
-
var len = lineLength(line)
|
| 6286 |
if (len > display.maxLineLength) {
|
| 6287 |
-
display.maxLine = line
|
| 6288 |
-
display.maxLineLength = len
|
| 6289 |
-
display.maxLineChanged = true
|
| 6290 |
-
recomputeMaxLength = false
|
| 6291 |
}
|
| 6292 |
-
})
|
| 6293 |
-
if (recomputeMaxLength) { cm.curOp.updateMaxLine = true }
|
| 6294 |
}
|
| 6295 |
|
| 6296 |
// Adjust frontier, schedule worker
|
| 6297 |
-
doc.frontier = Math.min(doc.frontier, from.line)
|
| 6298 |
-
startWorker(cm, 400)
|
| 6299 |
|
| 6300 |
-
var lendiff = change.text.length - (to.line - from.line) - 1
|
| 6301 |
// Remember that these lines changed, for updating the display
|
| 6302 |
if (change.full)
|
| 6303 |
-
{ regChange(cm) }
|
| 6304 |
else if (from.line == to.line && change.text.length == 1 && !isWholeLineUpdate(cm.doc, change))
|
| 6305 |
-
{ regLineChange(cm, from.line, "text") }
|
| 6306 |
else
|
| 6307 |
-
{ regChange(cm, from.line, to.line + 1, lendiff) }
|
| 6308 |
|
| 6309 |
-
var changesHandler = hasHandler(cm, "changes"), changeHandler = hasHandler(cm, "change")
|
| 6310 |
if (changeHandler || changesHandler) {
|
| 6311 |
var obj = {
|
| 6312 |
from: from, to: to,
|
| 6313 |
text: change.text,
|
| 6314 |
removed: change.removed,
|
| 6315 |
origin: change.origin
|
| 6316 |
-
}
|
| 6317 |
-
if (changeHandler) { signalLater(cm, "change", cm, obj) }
|
| 6318 |
-
if (changesHandler) { (cm.curOp.changeObjs || (cm.curOp.changeObjs = [])).push(obj) }
|
| 6319 |
}
|
| 6320 |
-
cm.display.selForContextMenu = null
|
| 6321 |
}
|
| 6322 |
|
| 6323 |
function replaceRange(doc, code, from, to, origin) {
|
| 6324 |
-
if (!to) { to = from }
|
| 6325 |
-
if (cmp(to, from) < 0) { var tmp = to; to = from; from = tmp }
|
| 6326 |
-
if (typeof code == "string") { code = doc.splitLines(code) }
|
| 6327 |
-
makeChange(doc, {from: from, to: to, text: code, origin: origin})
|
| 6328 |
}
|
| 6329 |
|
| 6330 |
// Rebasing/resetting history to deal with externally-sourced changes
|
| 6331 |
|
| 6332 |
function rebaseHistSelSingle(pos, from, to, diff) {
|
| 6333 |
if (to < pos.line) {
|
| 6334 |
-
pos.line += diff
|
| 6335 |
} else if (from < pos.line) {
|
| 6336 |
-
pos.line = from
|
| 6337 |
-
pos.ch = 0
|
| 6338 |
}
|
| 6339 |
}
|
| 6340 |
|
|
@@ -6347,47 +6372,47 @@ webpackJsonp([2],{
|
|
| 6347 |
// shared position objects being unsafely updated.
|
| 6348 |
function rebaseHistArray(array, from, to, diff) {
|
| 6349 |
for (var i = 0; i < array.length; ++i) {
|
| 6350 |
-
var sub = array[i], ok = true
|
| 6351 |
if (sub.ranges) {
|
| 6352 |
-
if (!sub.copied) { sub = array[i] = sub.deepCopy(); sub.copied = true }
|
| 6353 |
for (var j = 0; j < sub.ranges.length; j++) {
|
| 6354 |
-
rebaseHistSelSingle(sub.ranges[j].anchor, from, to, diff)
|
| 6355 |
-
rebaseHistSelSingle(sub.ranges[j].head, from, to, diff)
|
| 6356 |
}
|
| 6357 |
continue
|
| 6358 |
}
|
| 6359 |
for (var j$1 = 0; j$1 < sub.changes.length; ++j$1) {
|
| 6360 |
-
var cur = sub.changes[j$1]
|
| 6361 |
if (to < cur.from.line) {
|
| 6362 |
-
cur.from = Pos(cur.from.line + diff, cur.from.ch)
|
| 6363 |
-
cur.to = Pos(cur.to.line + diff, cur.to.ch)
|
| 6364 |
} else if (from <= cur.to.line) {
|
| 6365 |
-
ok = false
|
| 6366 |
break
|
| 6367 |
}
|
| 6368 |
}
|
| 6369 |
if (!ok) {
|
| 6370 |
-
array.splice(0, i + 1)
|
| 6371 |
-
i = 0
|
| 6372 |
}
|
| 6373 |
}
|
| 6374 |
}
|
| 6375 |
|
| 6376 |
function rebaseHist(hist, change) {
|
| 6377 |
-
var from = change.from.line, to = change.to.line, diff = change.text.length - (to - from) - 1
|
| 6378 |
-
rebaseHistArray(hist.done, from, to, diff)
|
| 6379 |
-
rebaseHistArray(hist.undone, from, to, diff)
|
| 6380 |
}
|
| 6381 |
|
| 6382 |
// Utility for applying a change to a line by handle or number,
|
| 6383 |
// returning the number and optionally registering the line as
|
| 6384 |
// changed.
|
| 6385 |
function changeLine(doc, handle, changeType, op) {
|
| 6386 |
-
var no = handle, line = handle
|
| 6387 |
-
if (typeof handle == "number") { line = getLine(doc, clipLine(doc, handle)) }
|
| 6388 |
-
else { no = lineNo(handle) }
|
| 6389 |
if (no == null) { return null }
|
| 6390 |
-
if (op(line, no) && doc.cm) { regLineChange(doc.cm, no, changeType) }
|
| 6391 |
return line
|
| 6392 |
}
|
| 6393 |
|
|
@@ -6407,14 +6432,14 @@ webpackJsonp([2],{
|
|
| 6407 |
var LeafChunk = function(lines) {
|
| 6408 |
var this$1 = this;
|
| 6409 |
|
| 6410 |
-
this.lines = lines
|
| 6411 |
-
this.parent = null
|
| 6412 |
-
var height = 0
|
| 6413 |
for (var i = 0; i < lines.length; ++i) {
|
| 6414 |
-
lines[i].parent = this$1
|
| 6415 |
-
height += lines[i].height
|
| 6416 |
}
|
| 6417 |
-
this.height = height
|
| 6418 |
};
|
| 6419 |
|
| 6420 |
LeafChunk.prototype.chunkSize = function () { return this.lines.length };
|
|
@@ -6424,17 +6449,17 @@ webpackJsonp([2],{
|
|
| 6424 |
var this$1 = this;
|
| 6425 |
|
| 6426 |
for (var i = at, e = at + n; i < e; ++i) {
|
| 6427 |
-
var line = this$1.lines[i]
|
| 6428 |
-
this$1.height -= line.height
|
| 6429 |
-
cleanUpLine(line)
|
| 6430 |
-
signalLater(line, "delete")
|
| 6431 |
}
|
| 6432 |
-
this.lines.splice(at, n)
|
| 6433 |
};
|
| 6434 |
|
| 6435 |
// Helper used to collapse a small branch into a single leaf.
|
| 6436 |
LeafChunk.prototype.collapse = function (lines) {
|
| 6437 |
-
lines.push.apply(lines, this.lines)
|
| 6438 |
};
|
| 6439 |
|
| 6440 |
// Insert the given array of lines at offset 'at', count them as
|
|
@@ -6442,9 +6467,9 @@ webpackJsonp([2],{
|
|
| 6442 |
LeafChunk.prototype.insertInner = function (at, lines, height) {
|
| 6443 |
var this$1 = this;
|
| 6444 |
|
| 6445 |
-
this.height += height
|
| 6446 |
-
this.lines = this.lines.slice(0, at).concat(lines).concat(this.lines.slice(at))
|
| 6447 |
-
for (var i = 0; i < lines.length; ++i) { lines[i].parent = this$1 }
|
| 6448 |
};
|
| 6449 |
|
| 6450 |
// Used to iterate over a part of the tree.
|
|
@@ -6458,16 +6483,16 @@ webpackJsonp([2],{
|
|
| 6458 |
var BranchChunk = function(children) {
|
| 6459 |
var this$1 = this;
|
| 6460 |
|
| 6461 |
-
this.children = children
|
| 6462 |
-
var size = 0, height = 0
|
| 6463 |
for (var i = 0; i < children.length; ++i) {
|
| 6464 |
-
var ch = children[i]
|
| 6465 |
-
size += ch.chunkSize(); height += ch.height
|
| 6466 |
-
ch.parent = this$1
|
| 6467 |
}
|
| 6468 |
-
this.size = size
|
| 6469 |
-
this.height = height
|
| 6470 |
-
this.parent = null
|
| 6471 |
};
|
| 6472 |
|
| 6473 |
BranchChunk.prototype.chunkSize = function () { return this.size };
|
|
@@ -6475,97 +6500,97 @@ webpackJsonp([2],{
|
|
| 6475 |
BranchChunk.prototype.removeInner = function (at, n) {
|
| 6476 |
var this$1 = this;
|
| 6477 |
|
| 6478 |
-
this.size -= n
|
| 6479 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6480 |
-
var child = this$1.children[i], sz = child.chunkSize()
|
| 6481 |
if (at < sz) {
|
| 6482 |
-
var rm = Math.min(n, sz - at), oldHeight = child.height
|
| 6483 |
-
child.removeInner(at, rm)
|
| 6484 |
-
this$1.height -= oldHeight - child.height
|
| 6485 |
-
if (sz == rm) { this$1.children.splice(i--, 1); child.parent = null }
|
| 6486 |
if ((n -= rm) == 0) { break }
|
| 6487 |
-
at = 0
|
| 6488 |
-
} else { at -= sz }
|
| 6489 |
}
|
| 6490 |
// If the result is smaller than 25 lines, ensure that it is a
|
| 6491 |
// single leaf node.
|
| 6492 |
if (this.size - n < 25 &&
|
| 6493 |
(this.children.length > 1 || !(this.children[0] instanceof LeafChunk))) {
|
| 6494 |
-
var lines = []
|
| 6495 |
-
this.collapse(lines)
|
| 6496 |
-
this.children = [new LeafChunk(lines)]
|
| 6497 |
-
this.children[0].parent = this
|
| 6498 |
}
|
| 6499 |
};
|
| 6500 |
|
| 6501 |
BranchChunk.prototype.collapse = function (lines) {
|
| 6502 |
var this$1 = this;
|
| 6503 |
|
| 6504 |
-
for (var i = 0; i < this.children.length; ++i) { this$1.children[i].collapse(lines) }
|
| 6505 |
};
|
| 6506 |
|
| 6507 |
BranchChunk.prototype.insertInner = function (at, lines, height) {
|
| 6508 |
var this$1 = this;
|
| 6509 |
|
| 6510 |
-
this.size += lines.length
|
| 6511 |
-
this.height += height
|
| 6512 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6513 |
-
var child = this$1.children[i], sz = child.chunkSize()
|
| 6514 |
if (at <= sz) {
|
| 6515 |
-
child.insertInner(at, lines, height)
|
| 6516 |
if (child.lines && child.lines.length > 50) {
|
| 6517 |
// To avoid memory thrashing when child.lines is huge (e.g. first view of a large file), it's never spliced.
|
| 6518 |
// Instead, small slices are taken. They're taken in order because sequential memory accesses are fastest.
|
| 6519 |
-
var remaining = child.lines.length % 25 + 25
|
| 6520 |
for (var pos = remaining; pos < child.lines.length;) {
|
| 6521 |
-
var leaf = new LeafChunk(child.lines.slice(pos, pos += 25))
|
| 6522 |
-
child.height -= leaf.height
|
| 6523 |
-
this$1.children.splice(++i, 0, leaf)
|
| 6524 |
-
leaf.parent = this$1
|
| 6525 |
}
|
| 6526 |
-
child.lines = child.lines.slice(0, remaining)
|
| 6527 |
-
this$1.maybeSpill()
|
| 6528 |
}
|
| 6529 |
break
|
| 6530 |
}
|
| 6531 |
-
at -= sz
|
| 6532 |
}
|
| 6533 |
};
|
| 6534 |
|
| 6535 |
// When a node has grown, check whether it should be split.
|
| 6536 |
BranchChunk.prototype.maybeSpill = function () {
|
| 6537 |
if (this.children.length <= 10) { return }
|
| 6538 |
-
var me = this
|
| 6539 |
do {
|
| 6540 |
-
var spilled = me.children.splice(me.children.length - 5, 5)
|
| 6541 |
-
var sibling = new BranchChunk(spilled)
|
| 6542 |
if (!me.parent) { // Become the parent node
|
| 6543 |
-
var copy = new BranchChunk(me.children)
|
| 6544 |
-
copy.parent = me
|
| 6545 |
-
me.children = [copy, sibling]
|
| 6546 |
-
me = copy
|
| 6547 |
} else {
|
| 6548 |
-
me.size -= sibling.size
|
| 6549 |
-
me.height -= sibling.height
|
| 6550 |
-
var myIndex = indexOf(me.parent.children, me)
|
| 6551 |
-
me.parent.children.splice(myIndex + 1, 0, sibling)
|
| 6552 |
}
|
| 6553 |
-
sibling.parent = me.parent
|
| 6554 |
} while (me.children.length > 10)
|
| 6555 |
-
me.parent.maybeSpill()
|
| 6556 |
};
|
| 6557 |
|
| 6558 |
BranchChunk.prototype.iterN = function (at, n, op) {
|
| 6559 |
var this$1 = this;
|
| 6560 |
|
| 6561 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6562 |
-
var child = this$1.children[i], sz = child.chunkSize()
|
| 6563 |
if (at < sz) {
|
| 6564 |
-
var used = Math.min(n, sz - at)
|
| 6565 |
if (child.iterN(at, used, op)) { return true }
|
| 6566 |
if ((n -= used) == 0) { break }
|
| 6567 |
-
at = 0
|
| 6568 |
-
} else { at -= sz }
|
| 6569 |
}
|
| 6570 |
};
|
| 6571 |
|
|
@@ -6575,70 +6600,70 @@ webpackJsonp([2],{
|
|
| 6575 |
var this$1 = this;
|
| 6576 |
|
| 6577 |
if (options) { for (var opt in options) { if (options.hasOwnProperty(opt))
|
| 6578 |
-
{ this$1[opt] = options[opt] } } }
|
| 6579 |
-
this.doc = doc
|
| 6580 |
-
this.node = node
|
| 6581 |
};
|
| 6582 |
|
| 6583 |
LineWidget.prototype.clear = function () {
|
| 6584 |
var this$1 = this;
|
| 6585 |
|
| 6586 |
-
var cm = this.doc.cm, ws = this.line.widgets, line = this.line, no = lineNo(line)
|
| 6587 |
if (no == null || !ws) { return }
|
| 6588 |
-
for (var i = 0; i < ws.length; ++i) { if (ws[i] == this$1) { ws.splice(i--, 1) } }
|
| 6589 |
-
if (!ws.length) { line.widgets = null }
|
| 6590 |
-
var height = widgetHeight(this)
|
| 6591 |
-
updateLineHeight(line, Math.max(0, line.height - height))
|
| 6592 |
if (cm) {
|
| 6593 |
runInOp(cm, function () {
|
| 6594 |
-
adjustScrollWhenAboveVisible(cm, line, -height)
|
| 6595 |
-
regLineChange(cm, no, "widget")
|
| 6596 |
-
})
|
| 6597 |
-
signalLater(cm, "lineWidgetCleared", cm, this, no)
|
| 6598 |
}
|
| 6599 |
};
|
| 6600 |
|
| 6601 |
LineWidget.prototype.changed = function () {
|
| 6602 |
var this$1 = this;
|
| 6603 |
|
| 6604 |
-
var oldH = this.height, cm = this.doc.cm, line = this.line
|
| 6605 |
-
this.height = null
|
| 6606 |
-
var diff = widgetHeight(this) - oldH
|
| 6607 |
if (!diff) { return }
|
| 6608 |
-
updateLineHeight(line, line.height + diff)
|
| 6609 |
if (cm) {
|
| 6610 |
runInOp(cm, function () {
|
| 6611 |
-
cm.curOp.forceUpdate = true
|
| 6612 |
-
adjustScrollWhenAboveVisible(cm, line, diff)
|
| 6613 |
-
signalLater(cm, "lineWidgetChanged", cm, this$1, lineNo(line))
|
| 6614 |
-
})
|
| 6615 |
}
|
| 6616 |
};
|
| 6617 |
-
eventMixin(LineWidget)
|
| 6618 |
|
| 6619 |
function adjustScrollWhenAboveVisible(cm, line, diff) {
|
| 6620 |
if (heightAtLine(line) < ((cm.curOp && cm.curOp.scrollTop) || cm.doc.scrollTop))
|
| 6621 |
-
{ addToScrollPos(cm, null, diff) }
|
| 6622 |
}
|
| 6623 |
|
| 6624 |
function addLineWidget(doc, handle, node, options) {
|
| 6625 |
-
var widget = new LineWidget(doc, node, options)
|
| 6626 |
-
var cm = doc.cm
|
| 6627 |
-
if (cm && widget.noHScroll) { cm.display.alignWidgets = true }
|
| 6628 |
changeLine(doc, handle, "widget", function (line) {
|
| 6629 |
-
var widgets = line.widgets || (line.widgets = [])
|
| 6630 |
-
if (widget.insertAt == null) { widgets.push(widget) }
|
| 6631 |
-
else { widgets.splice(Math.min(widgets.length - 1, Math.max(0, widget.insertAt)), 0, widget) }
|
| 6632 |
-
widget.line = line
|
| 6633 |
if (cm && !lineIsHidden(doc, line)) {
|
| 6634 |
-
var aboveVisible = heightAtLine(line) < doc.scrollTop
|
| 6635 |
-
updateLineHeight(line, line.height + widgetHeight(widget))
|
| 6636 |
-
if (aboveVisible) { addToScrollPos(cm, null, widget.height) }
|
| 6637 |
-
cm.curOp.forceUpdate = true
|
| 6638 |
}
|
| 6639 |
return true
|
| 6640 |
-
})
|
| 6641 |
-
signalLater(cm, "lineWidgetAdded", cm, widget, typeof handle == "number" ? handle : lineNo(handle))
|
| 6642 |
return widget
|
| 6643 |
}
|
| 6644 |
|
|
@@ -6657,13 +6682,13 @@ webpackJsonp([2],{
|
|
| 6657 |
// Collapsed markers have unique ids, in order to be able to order
|
| 6658 |
// them, which is needed for uniquely determining an outer marker
|
| 6659 |
// when they overlap (they may nest, but not partially overlap).
|
| 6660 |
-
var nextMarkerId = 0
|
| 6661 |
|
| 6662 |
var TextMarker = function(doc, type) {
|
| 6663 |
-
this.lines = []
|
| 6664 |
-
this.type = type
|
| 6665 |
-
this.doc = doc
|
| 6666 |
-
this.id = ++nextMarkerId
|
| 6667 |
};
|
| 6668 |
|
| 6669 |
// Clear the marker.
|
|
@@ -6671,44 +6696,44 @@ webpackJsonp([2],{
|
|
| 6671 |
var this$1 = this;
|
| 6672 |
|
| 6673 |
if (this.explicitlyCleared) { return }
|
| 6674 |
-
var cm = this.doc.cm, withOp = cm && !cm.curOp
|
| 6675 |
-
if (withOp) { startOperation(cm) }
|
| 6676 |
if (hasHandler(this, "clear")) {
|
| 6677 |
-
var found = this.find()
|
| 6678 |
-
if (found) { signalLater(this, "clear", found.from, found.to) }
|
| 6679 |
}
|
| 6680 |
-
var min = null, max = null
|
| 6681 |
for (var i = 0; i < this.lines.length; ++i) {
|
| 6682 |
-
var line = this$1.lines[i]
|
| 6683 |
-
var span = getMarkedSpanFor(line.markedSpans, this$1)
|
| 6684 |
-
if (cm && !this$1.collapsed) { regLineChange(cm, lineNo(line), "text") }
|
| 6685 |
else if (cm) {
|
| 6686 |
-
if (span.to != null) { max = lineNo(line) }
|
| 6687 |
-
if (span.from != null) { min = lineNo(line) }
|
| 6688 |
}
|
| 6689 |
-
line.markedSpans = removeMarkedSpan(line.markedSpans, span)
|
| 6690 |
if (span.from == null && this$1.collapsed && !lineIsHidden(this$1.doc, line) && cm)
|
| 6691 |
-
{ updateLineHeight(line, textHeight(cm.display)) }
|
| 6692 |
}
|
| 6693 |
if (cm && this.collapsed && !cm.options.lineWrapping) { for (var i$1 = 0; i$1 < this.lines.length; ++i$1) {
|
| 6694 |
-
var visual = visualLine(this$1.lines[i$1]), len = lineLength(visual)
|
| 6695 |
if (len > cm.display.maxLineLength) {
|
| 6696 |
-
cm.display.maxLine = visual
|
| 6697 |
-
cm.display.maxLineLength = len
|
| 6698 |
-
cm.display.maxLineChanged = true
|
| 6699 |
}
|
| 6700 |
} }
|
| 6701 |
|
| 6702 |
-
if (min != null && cm && this.collapsed) { regChange(cm, min, max + 1) }
|
| 6703 |
-
this.lines.length = 0
|
| 6704 |
-
this.explicitlyCleared = true
|
| 6705 |
if (this.atomic && this.doc.cantEdit) {
|
| 6706 |
-
this.doc.cantEdit = false
|
| 6707 |
-
if (cm) { reCheckSelection(cm.doc) }
|
| 6708 |
}
|
| 6709 |
-
if (cm) { signalLater(cm, "markerCleared", cm, this, min, max) }
|
| 6710 |
-
if (withOp) { endOperation(cm) }
|
| 6711 |
-
if (this.parent) { this.parent.clear() }
|
| 6712 |
};
|
| 6713 |
|
| 6714 |
// Find the position of the marker in the document. Returns a {from,
|
|
@@ -6719,17 +6744,17 @@ webpackJsonp([2],{
|
|
| 6719 |
TextMarker.prototype.find = function (side, lineObj) {
|
| 6720 |
var this$1 = this;
|
| 6721 |
|
| 6722 |
-
if (side == null && this.type == "bookmark") { side = 1 }
|
| 6723 |
-
var from, to
|
| 6724 |
for (var i = 0; i < this.lines.length; ++i) {
|
| 6725 |
-
var line = this$1.lines[i]
|
| 6726 |
-
var span = getMarkedSpanFor(line.markedSpans, this$1)
|
| 6727 |
if (span.from != null) {
|
| 6728 |
-
from = Pos(lineObj ? line : lineNo(line), span.from)
|
| 6729 |
if (side == -1) { return from }
|
| 6730 |
}
|
| 6731 |
if (span.to != null) {
|
| 6732 |
-
to = Pos(lineObj ? line : lineNo(line), span.to)
|
| 6733 |
if (side == 1) { return to }
|
| 6734 |
}
|
| 6735 |
}
|
|
@@ -6741,44 +6766,43 @@ webpackJsonp([2],{
|
|
| 6741 |
TextMarker.prototype.changed = function () {
|
| 6742 |
var this$1 = this;
|
| 6743 |
|
| 6744 |
-
var pos = this.find(-1, true), widget = this, cm = this.doc.cm
|
| 6745 |
if (!pos || !cm) { return }
|
| 6746 |
runInOp(cm, function () {
|
| 6747 |
-
var line = pos.line, lineN = lineNo(pos.line)
|
| 6748 |
-
var view = findViewForLine(cm, lineN)
|
| 6749 |
if (view) {
|
| 6750 |
-
clearLineMeasurementCacheFor(view)
|
| 6751 |
-
cm.curOp.selectionChanged = cm.curOp.forceUpdate = true
|
| 6752 |
}
|
| 6753 |
-
cm.curOp.updateMaxLine = true
|
| 6754 |
if (!lineIsHidden(widget.doc, line) && widget.height != null) {
|
| 6755 |
-
var oldHeight = widget.height
|
| 6756 |
-
widget.height = null
|
| 6757 |
-
var dHeight = widgetHeight(widget) - oldHeight
|
| 6758 |
if (dHeight)
|
| 6759 |
-
{ updateLineHeight(line, line.height + dHeight) }
|
| 6760 |
}
|
| 6761 |
-
signalLater(cm, "markerChanged", cm, this$1)
|
| 6762 |
-
})
|
| 6763 |
};
|
| 6764 |
|
| 6765 |
TextMarker.prototype.attachLine = function (line) {
|
| 6766 |
if (!this.lines.length && this.doc.cm) {
|
| 6767 |
-
var op = this.doc.cm.curOp
|
| 6768 |
if (!op.maybeHiddenMarkers || indexOf(op.maybeHiddenMarkers, this) == -1)
|
| 6769 |
-
{ (op.maybeUnhiddenMarkers || (op.maybeUnhiddenMarkers = [])).push(this) }
|
| 6770 |
}
|
| 6771 |
-
this.lines.push(line)
|
| 6772 |
};
|
| 6773 |
|
| 6774 |
TextMarker.prototype.detachLine = function (line) {
|
| 6775 |
-
this.lines.splice(indexOf(this.lines, line), 1)
|
| 6776 |
if (!this.lines.length && this.doc.cm) {
|
| 6777 |
-
var op = this.doc.cm.curOp
|
| 6778 |
-
;(op.maybeHiddenMarkers || (op.maybeHiddenMarkers = [])).push(this)
|
| 6779 |
}
|
| 6780 |
};
|
| 6781 |
-
eventMixin(TextMarker)
|
| 6782 |
|
| 6783 |
// Create a marker, wire it up to the right lines, and
|
| 6784 |
function markText(doc, from, to, options, type) {
|
|
@@ -6789,64 +6813,63 @@ webpackJsonp([2],{
|
|
| 6789 |
// Ensure we are in an operation.
|
| 6790 |
if (doc.cm && !doc.cm.curOp) { return operation(doc.cm, markText)(doc, from, to, options, type) }
|
| 6791 |
|
| 6792 |
-
var marker = new TextMarker(doc, type), diff = cmp(from, to)
|
| 6793 |
-
if (options) { copyObj(options, marker, false) }
|
| 6794 |
// Don't connect empty markers unless clearWhenEmpty is false
|
| 6795 |
if (diff > 0 || diff == 0 && marker.clearWhenEmpty !== false)
|
| 6796 |
{ return marker }
|
| 6797 |
if (marker.replacedWith) {
|
| 6798 |
// Showing up as a widget implies collapsed (widget replaces text)
|
| 6799 |
-
marker.collapsed = true
|
| 6800 |
-
marker.widgetNode =
|
| 6801 |
-
marker.widgetNode.setAttribute("
|
| 6802 |
-
if (
|
| 6803 |
-
if (options.insertLeft) { marker.widgetNode.insertLeft = true }
|
| 6804 |
}
|
| 6805 |
if (marker.collapsed) {
|
| 6806 |
if (conflictingCollapsedRange(doc, from.line, from, to, marker) ||
|
| 6807 |
from.line != to.line && conflictingCollapsedRange(doc, to.line, from, to, marker))
|
| 6808 |
{ throw new Error("Inserting collapsed marker partially overlapping an existing one") }
|
| 6809 |
-
seeCollapsedSpans()
|
| 6810 |
}
|
| 6811 |
|
| 6812 |
if (marker.addToHistory)
|
| 6813 |
-
{ addChangeToHistory(doc, {from: from, to: to, origin: "markText"}, doc.sel, NaN) }
|
| 6814 |
|
| 6815 |
-
var curLine = from.line, cm = doc.cm, updateMaxLine
|
| 6816 |
doc.iter(curLine, to.line + 1, function (line) {
|
| 6817 |
if (cm && marker.collapsed && !cm.options.lineWrapping && visualLine(line) == cm.display.maxLine)
|
| 6818 |
-
{ updateMaxLine = true }
|
| 6819 |
-
if (marker.collapsed && curLine != from.line) { updateLineHeight(line, 0) }
|
| 6820 |
addMarkedSpan(line, new MarkedSpan(marker,
|
| 6821 |
curLine == from.line ? from.ch : null,
|
| 6822 |
-
curLine == to.line ? to.ch : null))
|
| 6823 |
-
++curLine
|
| 6824 |
-
})
|
| 6825 |
// lineIsHidden depends on the presence of the spans, so needs a second pass
|
| 6826 |
if (marker.collapsed) { doc.iter(from.line, to.line + 1, function (line) {
|
| 6827 |
-
if (lineIsHidden(doc, line)) { updateLineHeight(line, 0) }
|
| 6828 |
-
}) }
|
| 6829 |
|
| 6830 |
-
if (marker.clearOnEnter) { on(marker, "beforeCursorEnter", function () { return marker.clear(); }) }
|
| 6831 |
|
| 6832 |
if (marker.readOnly) {
|
| 6833 |
-
seeReadOnlySpans()
|
| 6834 |
if (doc.history.done.length || doc.history.undone.length)
|
| 6835 |
-
{ doc.clearHistory() }
|
| 6836 |
}
|
| 6837 |
if (marker.collapsed) {
|
| 6838 |
-
marker.id = ++nextMarkerId
|
| 6839 |
-
marker.atomic = true
|
| 6840 |
}
|
| 6841 |
if (cm) {
|
| 6842 |
// Sync editor state
|
| 6843 |
-
if (updateMaxLine) { cm.curOp.updateMaxLine = true }
|
| 6844 |
if (marker.collapsed)
|
| 6845 |
-
{ regChange(cm, from.line, to.line + 1) }
|
| 6846 |
else if (marker.className || marker.title || marker.startStyle || marker.endStyle || marker.css)
|
| 6847 |
-
{ for (var i = from.line; i <= to.line; i++) { regLineChange(cm, i, "text") } }
|
| 6848 |
-
if (marker.atomic) { reCheckSelection(cm.doc) }
|
| 6849 |
-
signalLater(cm, "markerAdded", cm, marker)
|
| 6850 |
}
|
| 6851 |
return marker
|
| 6852 |
}
|
|
@@ -6859,39 +6882,39 @@ webpackJsonp([2],{
|
|
| 6859 |
var SharedTextMarker = function(markers, primary) {
|
| 6860 |
var this$1 = this;
|
| 6861 |
|
| 6862 |
-
this.markers = markers
|
| 6863 |
-
this.primary = primary
|
| 6864 |
for (var i = 0; i < markers.length; ++i)
|
| 6865 |
-
{ markers[i].parent = this$1 }
|
| 6866 |
};
|
| 6867 |
|
| 6868 |
SharedTextMarker.prototype.clear = function () {
|
| 6869 |
var this$1 = this;
|
| 6870 |
|
| 6871 |
if (this.explicitlyCleared) { return }
|
| 6872 |
-
this.explicitlyCleared = true
|
| 6873 |
for (var i = 0; i < this.markers.length; ++i)
|
| 6874 |
-
{ this$1.markers[i].clear() }
|
| 6875 |
-
signalLater(this, "clear")
|
| 6876 |
};
|
| 6877 |
|
| 6878 |
SharedTextMarker.prototype.find = function (side, lineObj) {
|
| 6879 |
return this.primary.find(side, lineObj)
|
| 6880 |
};
|
| 6881 |
-
eventMixin(SharedTextMarker)
|
| 6882 |
|
| 6883 |
function markTextShared(doc, from, to, options, type) {
|
| 6884 |
-
options = copyObj(options)
|
| 6885 |
-
options.shared = false
|
| 6886 |
-
var markers = [markText(doc, from, to, options, type)], primary = markers[0]
|
| 6887 |
-
var widget = options.widgetNode
|
| 6888 |
linkedDocs(doc, function (doc) {
|
| 6889 |
-
if (widget) { options.widgetNode = widget.cloneNode(true) }
|
| 6890 |
-
markers.push(markText(doc, clipPos(doc, from), clipPos(doc, to), options, type))
|
| 6891 |
for (var i = 0; i < doc.linked.length; ++i)
|
| 6892 |
{ if (doc.linked[i].isParent) { return } }
|
| 6893 |
-
primary = lst(markers)
|
| 6894 |
-
})
|
| 6895 |
return new SharedTextMarker(markers, primary)
|
| 6896 |
}
|
| 6897 |
|
|
@@ -6901,25 +6924,25 @@ webpackJsonp([2],{
|
|
| 6901 |
|
| 6902 |
function copySharedMarkers(doc, markers) {
|
| 6903 |
for (var i = 0; i < markers.length; i++) {
|
| 6904 |
-
var marker = markers[i], pos = marker.find()
|
| 6905 |
-
var mFrom = doc.clipPos(pos.from), mTo = doc.clipPos(pos.to)
|
| 6906 |
if (cmp(mFrom, mTo)) {
|
| 6907 |
-
var subMark = markText(doc, mFrom, mTo, marker.primary, marker.primary.type)
|
| 6908 |
-
marker.markers.push(subMark)
|
| 6909 |
-
subMark.parent = marker
|
| 6910 |
}
|
| 6911 |
}
|
| 6912 |
}
|
| 6913 |
|
| 6914 |
function detachSharedMarkers(markers) {
|
| 6915 |
var loop = function ( i ) {
|
| 6916 |
-
var marker = markers[i], linked = [marker.primary.doc]
|
| 6917 |
-
linkedDocs(marker.primary.doc, function (d) { return linked.push(d); })
|
| 6918 |
for (var j = 0; j < marker.markers.length; j++) {
|
| 6919 |
-
var subMarker = marker.markers[j]
|
| 6920 |
if (indexOf(linked, subMarker.doc) == -1) {
|
| 6921 |
-
subMarker.parent = null
|
| 6922 |
-
marker.markers.splice(j--, 1)
|
| 6923 |
}
|
| 6924 |
}
|
| 6925 |
};
|
|
@@ -6927,29 +6950,30 @@ webpackJsonp([2],{
|
|
| 6927 |
for (var i = 0; i < markers.length; i++) loop( i );
|
| 6928 |
}
|
| 6929 |
|
| 6930 |
-
var nextDocId = 0
|
| 6931 |
-
var Doc = function(text, mode, firstLine, lineSep) {
|
| 6932 |
-
if (!(this instanceof Doc)) { return new Doc(text, mode, firstLine, lineSep) }
|
| 6933 |
-
if (firstLine == null) { firstLine = 0 }
|
| 6934 |
-
|
| 6935 |
-
BranchChunk.call(this, [new LeafChunk([new Line("", null)])])
|
| 6936 |
-
this.first = firstLine
|
| 6937 |
-
this.scrollTop = this.scrollLeft = 0
|
| 6938 |
-
this.cantEdit = false
|
| 6939 |
-
this.cleanGeneration = 1
|
| 6940 |
-
this.frontier = firstLine
|
| 6941 |
-
var start = Pos(firstLine, 0)
|
| 6942 |
-
this.sel = simpleSelection(start)
|
| 6943 |
-
this.history = new History(null)
|
| 6944 |
-
this.id = ++nextDocId
|
| 6945 |
-
this.modeOption = mode
|
| 6946 |
-
this.lineSep = lineSep
|
| 6947 |
-
this.
|
| 6948 |
-
|
| 6949 |
-
|
| 6950 |
-
|
| 6951 |
-
|
| 6952 |
-
|
|
|
|
| 6953 |
|
| 6954 |
Doc.prototype = createObj(BranchChunk.prototype, {
|
| 6955 |
constructor: Doc,
|
|
@@ -6958,39 +6982,39 @@ webpackJsonp([2],{
|
|
| 6958 |
// three, it iterates over the range given by the first two (with
|
| 6959 |
// the second being non-inclusive).
|
| 6960 |
iter: function(from, to, op) {
|
| 6961 |
-
if (op) { this.iterN(from - this.first, to - from, op) }
|
| 6962 |
-
else { this.iterN(this.first, this.first + this.size, from) }
|
| 6963 |
},
|
| 6964 |
|
| 6965 |
// Non-public interface for adding and removing lines.
|
| 6966 |
insert: function(at, lines) {
|
| 6967 |
-
var height = 0
|
| 6968 |
-
for (var i = 0; i < lines.length; ++i) { height += lines[i].height }
|
| 6969 |
-
this.insertInner(at - this.first, lines, height)
|
| 6970 |
},
|
| 6971 |
-
remove: function(at, n) { this.removeInner(at - this.first, n) },
|
| 6972 |
|
| 6973 |
// From here, the methods are part of the public interface. Most
|
| 6974 |
// are also available from CodeMirror (editor) instances.
|
| 6975 |
|
| 6976 |
getValue: function(lineSep) {
|
| 6977 |
-
var lines = getLines(this, this.first, this.first + this.size)
|
| 6978 |
if (lineSep === false) { return lines }
|
| 6979 |
return lines.join(lineSep || this.lineSeparator())
|
| 6980 |
},
|
| 6981 |
setValue: docMethodOp(function(code) {
|
| 6982 |
-
var top = Pos(this.first, 0), last = this.first + this.size - 1
|
| 6983 |
makeChange(this, {from: top, to: Pos(last, getLine(this, last).text.length),
|
| 6984 |
-
text: this.splitLines(code), origin: "setValue", full: true}, true)
|
| 6985 |
-
setSelection(this, simpleSelection(top))
|
| 6986 |
}),
|
| 6987 |
replaceRange: function(code, from, to, origin) {
|
| 6988 |
-
from = clipPos(this, from)
|
| 6989 |
-
to = to ? clipPos(this, to) : from
|
| 6990 |
-
replaceRange(this, code, from, to, origin)
|
| 6991 |
},
|
| 6992 |
getRange: function(from, to, lineSep) {
|
| 6993 |
-
var lines = getBetween(this, clipPos(this, from), clipPos(this, to))
|
| 6994 |
if (lineSep === false) { return lines }
|
| 6995 |
return lines.join(lineSep || this.lineSeparator())
|
| 6996 |
},
|
|
@@ -7001,7 +7025,7 @@ webpackJsonp([2],{
|
|
| 7001 |
getLineNumber: function(line) {return lineNo(line)},
|
| 7002 |
|
| 7003 |
getLineHandleVisualStart: function(line) {
|
| 7004 |
-
if (typeof line == "number") { line = getLine(this, line) }
|
| 7005 |
return visualLine(line)
|
| 7006 |
},
|
| 7007 |
|
|
@@ -7012,56 +7036,56 @@ webpackJsonp([2],{
|
|
| 7012 |
clipPos: function(pos) {return clipPos(this, pos)},
|
| 7013 |
|
| 7014 |
getCursor: function(start) {
|
| 7015 |
-
var range = this.sel.primary(), pos
|
| 7016 |
-
if (start == null || start == "head") { pos = range.head }
|
| 7017 |
-
else if (start == "anchor") { pos = range.anchor }
|
| 7018 |
-
else if (start == "end" || start == "to" || start === false) { pos = range.to() }
|
| 7019 |
-
else { pos = range.from() }
|
| 7020 |
return pos
|
| 7021 |
},
|
| 7022 |
listSelections: function() { return this.sel.ranges },
|
| 7023 |
somethingSelected: function() {return this.sel.somethingSelected()},
|
| 7024 |
|
| 7025 |
setCursor: docMethodOp(function(line, ch, options) {
|
| 7026 |
-
setSimpleSelection(this, clipPos(this, typeof line == "number" ? Pos(line, ch || 0) : line), null, options)
|
| 7027 |
}),
|
| 7028 |
setSelection: docMethodOp(function(anchor, head, options) {
|
| 7029 |
-
setSimpleSelection(this, clipPos(this, anchor), clipPos(this, head || anchor), options)
|
| 7030 |
}),
|
| 7031 |
extendSelection: docMethodOp(function(head, other, options) {
|
| 7032 |
-
extendSelection(this, clipPos(this, head), other && clipPos(this, other), options)
|
| 7033 |
}),
|
| 7034 |
extendSelections: docMethodOp(function(heads, options) {
|
| 7035 |
-
extendSelections(this, clipPosArray(this, heads), options)
|
| 7036 |
}),
|
| 7037 |
extendSelectionsBy: docMethodOp(function(f, options) {
|
| 7038 |
-
var heads = map(this.sel.ranges, f)
|
| 7039 |
-
extendSelections(this, clipPosArray(this, heads), options)
|
| 7040 |
}),
|
| 7041 |
setSelections: docMethodOp(function(ranges, primary, options) {
|
| 7042 |
var this$1 = this;
|
| 7043 |
|
| 7044 |
if (!ranges.length) { return }
|
| 7045 |
-
var out = []
|
| 7046 |
for (var i = 0; i < ranges.length; i++)
|
| 7047 |
{ out[i] = new Range(clipPos(this$1, ranges[i].anchor),
|
| 7048 |
-
clipPos(this$1, ranges[i].head)) }
|
| 7049 |
-
if (primary == null) { primary = Math.min(ranges.length - 1, this.sel.primIndex) }
|
| 7050 |
-
setSelection(this, normalizeSelection(out, primary), options)
|
| 7051 |
}),
|
| 7052 |
addSelection: docMethodOp(function(anchor, head, options) {
|
| 7053 |
-
var ranges = this.sel.ranges.slice(0)
|
| 7054 |
-
ranges.push(new Range(clipPos(this, anchor), clipPos(this, head || anchor)))
|
| 7055 |
-
setSelection(this, normalizeSelection(ranges, ranges.length - 1), options)
|
| 7056 |
}),
|
| 7057 |
|
| 7058 |
getSelection: function(lineSep) {
|
| 7059 |
var this$1 = this;
|
| 7060 |
|
| 7061 |
-
var ranges = this.sel.ranges, lines
|
| 7062 |
for (var i = 0; i < ranges.length; i++) {
|
| 7063 |
-
var sel = getBetween(this$1, ranges[i].from(), ranges[i].to())
|
| 7064 |
-
lines = lines ? lines.concat(sel) : sel
|
| 7065 |
}
|
| 7066 |
if (lineSep === false) { return lines }
|
| 7067 |
else { return lines.join(lineSep || this.lineSeparator()) }
|
|
@@ -7069,56 +7093,56 @@ webpackJsonp([2],{
|
|
| 7069 |
getSelections: function(lineSep) {
|
| 7070 |
var this$1 = this;
|
| 7071 |
|
| 7072 |
-
var parts = [], ranges = this.sel.ranges
|
| 7073 |
for (var i = 0; i < ranges.length; i++) {
|
| 7074 |
-
var sel = getBetween(this$1, ranges[i].from(), ranges[i].to())
|
| 7075 |
-
if (lineSep !== false) { sel = sel.join(lineSep || this$1.lineSeparator()) }
|
| 7076 |
-
parts[i] = sel
|
| 7077 |
}
|
| 7078 |
return parts
|
| 7079 |
},
|
| 7080 |
replaceSelection: function(code, collapse, origin) {
|
| 7081 |
-
var dup = []
|
| 7082 |
for (var i = 0; i < this.sel.ranges.length; i++)
|
| 7083 |
-
{ dup[i] = code }
|
| 7084 |
-
this.replaceSelections(dup, collapse, origin || "+input")
|
| 7085 |
},
|
| 7086 |
replaceSelections: docMethodOp(function(code, collapse, origin) {
|
| 7087 |
var this$1 = this;
|
| 7088 |
|
| 7089 |
-
var changes = [], sel = this.sel
|
| 7090 |
for (var i = 0; i < sel.ranges.length; i++) {
|
| 7091 |
-
var range = sel.ranges[i]
|
| 7092 |
-
changes[i] = {from: range.from(), to: range.to(), text: this$1.splitLines(code[i]), origin: origin}
|
| 7093 |
}
|
| 7094 |
-
var newSel = collapse && collapse != "end" && computeReplacedSel(this, changes, collapse)
|
| 7095 |
for (var i$1 = changes.length - 1; i$1 >= 0; i$1--)
|
| 7096 |
-
{ makeChange(this$1, changes[i$1]) }
|
| 7097 |
-
if (newSel) { setSelectionReplaceHistory(this, newSel) }
|
| 7098 |
-
else if (this.cm) { ensureCursorVisible(this.cm) }
|
| 7099 |
}),
|
| 7100 |
-
undo: docMethodOp(function() {makeChangeFromHistory(this, "undo")}),
|
| 7101 |
-
redo: docMethodOp(function() {makeChangeFromHistory(this, "redo")}),
|
| 7102 |
-
undoSelection: docMethodOp(function() {makeChangeFromHistory(this, "undo", true)}),
|
| 7103 |
-
redoSelection: docMethodOp(function() {makeChangeFromHistory(this, "redo", true)}),
|
| 7104 |
|
| 7105 |
-
setExtending: function(val) {this.extend = val},
|
| 7106 |
getExtending: function() {return this.extend},
|
| 7107 |
|
| 7108 |
historySize: function() {
|
| 7109 |
-
var hist = this.history, done = 0, undone = 0
|
| 7110 |
-
for (var i = 0; i < hist.done.length; i++) { if (!hist.done[i].ranges) { ++done } }
|
| 7111 |
-
for (var i$1 = 0; i$1 < hist.undone.length; i$1++) { if (!hist.undone[i$1].ranges) { ++undone } }
|
| 7112 |
return {undo: done, redo: undone}
|
| 7113 |
},
|
| 7114 |
-
clearHistory: function() {this.history = new History(this.history.maxGeneration)},
|
| 7115 |
|
| 7116 |
markClean: function() {
|
| 7117 |
-
this.cleanGeneration = this.changeGeneration(true)
|
| 7118 |
},
|
| 7119 |
changeGeneration: function(forceSplit) {
|
| 7120 |
if (forceSplit)
|
| 7121 |
-
{ this.history.lastOp = this.history.lastSelOp = this.history.lastOrigin = null }
|
| 7122 |
return this.history.generation
|
| 7123 |
},
|
| 7124 |
isClean: function (gen) {
|
|
@@ -7130,16 +7154,16 @@ webpackJsonp([2],{
|
|
| 7130 |
undone: copyHistoryArray(this.history.undone)}
|
| 7131 |
},
|
| 7132 |
setHistory: function(histData) {
|
| 7133 |
-
var hist = this.history = new History(this.history.maxGeneration)
|
| 7134 |
-
hist.done = copyHistoryArray(histData.done.slice(0), null, true)
|
| 7135 |
-
hist.undone = copyHistoryArray(histData.undone.slice(0), null, true)
|
| 7136 |
},
|
| 7137 |
|
| 7138 |
setGutterMarker: docMethodOp(function(line, gutterID, value) {
|
| 7139 |
return changeLine(this, line, "gutter", function (line) {
|
| 7140 |
-
var markers = line.gutterMarkers || (line.gutterMarkers = {})
|
| 7141 |
-
markers[gutterID] = value
|
| 7142 |
-
if (!value && isEmpty(markers)) { line.gutterMarkers = null }
|
| 7143 |
return true
|
| 7144 |
})
|
| 7145 |
}),
|
|
@@ -7150,23 +7174,23 @@ webpackJsonp([2],{
|
|
| 7150 |
this.iter(function (line) {
|
| 7151 |
if (line.gutterMarkers && line.gutterMarkers[gutterID]) {
|
| 7152 |
changeLine(this$1, line, "gutter", function () {
|
| 7153 |
-
line.gutterMarkers[gutterID] = null
|
| 7154 |
-
if (isEmpty(line.gutterMarkers)) { line.gutterMarkers = null }
|
| 7155 |
return true
|
| 7156 |
-
})
|
| 7157 |
}
|
| 7158 |
-
})
|
| 7159 |
}),
|
| 7160 |
|
| 7161 |
lineInfo: function(line) {
|
| 7162 |
-
var n
|
| 7163 |
if (typeof line == "number") {
|
| 7164 |
if (!isLine(this, line)) { return null }
|
| 7165 |
-
n = line
|
| 7166 |
-
line = getLine(this, line)
|
| 7167 |
if (!line) { return null }
|
| 7168 |
} else {
|
| 7169 |
-
n = lineNo(line)
|
| 7170 |
if (n == null) { return null }
|
| 7171 |
}
|
| 7172 |
return {line: n, handle: line, text: line.text, gutterMarkers: line.gutterMarkers,
|
|
@@ -7178,10 +7202,10 @@ webpackJsonp([2],{
|
|
| 7178 |
return changeLine(this, handle, where == "gutter" ? "gutter" : "class", function (line) {
|
| 7179 |
var prop = where == "text" ? "textClass"
|
| 7180 |
: where == "background" ? "bgClass"
|
| 7181 |
-
: where == "gutter" ? "gutterClass" : "wrapClass"
|
| 7182 |
-
if (!line[prop]) { line[prop] = cls }
|
| 7183 |
else if (classTest(cls).test(line[prop])) { return false }
|
| 7184 |
-
else { line[prop] += " " + cls }
|
| 7185 |
return true
|
| 7186 |
})
|
| 7187 |
}),
|
|
@@ -7189,15 +7213,15 @@ webpackJsonp([2],{
|
|
| 7189 |
return changeLine(this, handle, where == "gutter" ? "gutter" : "class", function (line) {
|
| 7190 |
var prop = where == "text" ? "textClass"
|
| 7191 |
: where == "background" ? "bgClass"
|
| 7192 |
-
: where == "gutter" ? "gutterClass" : "wrapClass"
|
| 7193 |
-
var cur = line[prop]
|
| 7194 |
if (!cur) { return false }
|
| 7195 |
-
else if (cls == null) { line[prop] = null }
|
| 7196 |
else {
|
| 7197 |
-
var found = cur.match(classTest(cls))
|
| 7198 |
if (!found) { return false }
|
| 7199 |
-
var end = found.index + found[0].length
|
| 7200 |
-
line[prop] = cur.slice(0, found.index) + (!found.index || end == cur.length ? "" : " ") + cur.slice(end) || null
|
| 7201 |
}
|
| 7202 |
return true
|
| 7203 |
})
|
|
@@ -7206,7 +7230,7 @@ webpackJsonp([2],{
|
|
| 7206 |
addLineWidget: docMethodOp(function(handle, node, options) {
|
| 7207 |
return addLineWidget(this, handle, node, options)
|
| 7208 |
}),
|
| 7209 |
-
removeLineWidget: function(widget) { widget.clear() },
|
| 7210 |
|
| 7211 |
markText: function(from, to, options) {
|
| 7212 |
return markText(this, clipPos(this, from), clipPos(this, to), options, options && options.type || "range")
|
|
@@ -7215,116 +7239,116 @@ webpackJsonp([2],{
|
|
| 7215 |
var realOpts = {replacedWith: options && (options.nodeType == null ? options.widget : options),
|
| 7216 |
insertLeft: options && options.insertLeft,
|
| 7217 |
clearWhenEmpty: false, shared: options && options.shared,
|
| 7218 |
-
handleMouseEvents: options && options.handleMouseEvents}
|
| 7219 |
-
pos = clipPos(this, pos)
|
| 7220 |
return markText(this, pos, pos, realOpts, "bookmark")
|
| 7221 |
},
|
| 7222 |
findMarksAt: function(pos) {
|
| 7223 |
-
pos = clipPos(this, pos)
|
| 7224 |
-
var markers = [], spans = getLine(this, pos.line).markedSpans
|
| 7225 |
if (spans) { for (var i = 0; i < spans.length; ++i) {
|
| 7226 |
-
var span = spans[i]
|
| 7227 |
if ((span.from == null || span.from <= pos.ch) &&
|
| 7228 |
(span.to == null || span.to >= pos.ch))
|
| 7229 |
-
{ markers.push(span.marker.parent || span.marker) }
|
| 7230 |
} }
|
| 7231 |
return markers
|
| 7232 |
},
|
| 7233 |
findMarks: function(from, to, filter) {
|
| 7234 |
-
from = clipPos(this, from); to = clipPos(this, to)
|
| 7235 |
-
var found = [], lineNo = from.line
|
| 7236 |
this.iter(from.line, to.line + 1, function (line) {
|
| 7237 |
-
var spans = line.markedSpans
|
| 7238 |
if (spans) { for (var i = 0; i < spans.length; i++) {
|
| 7239 |
-
var span = spans[i]
|
| 7240 |
-
if (!(span.to != null && lineNo == from.line && from.ch >= span.to ||
|
| 7241 |
-
span.from == null && lineNo != from.line ||
|
| 7242 |
-
span.from != null && lineNo == to.line && span.from >= to.ch) &&
|
| 7243 |
(!filter || filter(span.marker)))
|
| 7244 |
-
{ found.push(span.marker.parent || span.marker) }
|
| 7245 |
} }
|
| 7246 |
-
++lineNo
|
| 7247 |
-
})
|
| 7248 |
return found
|
| 7249 |
},
|
| 7250 |
getAllMarks: function() {
|
| 7251 |
-
var markers = []
|
| 7252 |
this.iter(function (line) {
|
| 7253 |
-
var sps = line.markedSpans
|
| 7254 |
if (sps) { for (var i = 0; i < sps.length; ++i)
|
| 7255 |
-
{ if (sps[i].from != null) { markers.push(sps[i].marker) } } }
|
| 7256 |
-
})
|
| 7257 |
return markers
|
| 7258 |
},
|
| 7259 |
|
| 7260 |
posFromIndex: function(off) {
|
| 7261 |
-
var ch, lineNo = this.first, sepSize = this.lineSeparator().length
|
| 7262 |
this.iter(function (line) {
|
| 7263 |
-
var sz = line.text.length + sepSize
|
| 7264 |
if (sz > off) { ch = off; return true }
|
| 7265 |
-
off -= sz
|
| 7266 |
-
++lineNo
|
| 7267 |
-
})
|
| 7268 |
-
return clipPos(this, Pos(lineNo, ch))
|
| 7269 |
},
|
| 7270 |
indexFromPos: function (coords) {
|
| 7271 |
-
coords = clipPos(this, coords)
|
| 7272 |
-
var index = coords.ch
|
| 7273 |
if (coords.line < this.first || coords.ch < 0) { return 0 }
|
| 7274 |
-
var sepSize = this.lineSeparator().length
|
| 7275 |
this.iter(this.first, coords.line, function (line) { // iter aborts when callback returns a truthy value
|
| 7276 |
-
index += line.text.length + sepSize
|
| 7277 |
-
})
|
| 7278 |
return index
|
| 7279 |
},
|
| 7280 |
|
| 7281 |
copy: function(copyHistory) {
|
| 7282 |
var doc = new Doc(getLines(this, this.first, this.first + this.size),
|
| 7283 |
-
this.modeOption, this.first, this.lineSep)
|
| 7284 |
-
doc.scrollTop = this.scrollTop; doc.scrollLeft = this.scrollLeft
|
| 7285 |
-
doc.sel = this.sel
|
| 7286 |
-
doc.extend = false
|
| 7287 |
if (copyHistory) {
|
| 7288 |
-
doc.history.undoDepth = this.history.undoDepth
|
| 7289 |
-
doc.setHistory(this.getHistory())
|
| 7290 |
}
|
| 7291 |
return doc
|
| 7292 |
},
|
| 7293 |
|
| 7294 |
linkedDoc: function(options) {
|
| 7295 |
-
if (!options) { options = {} }
|
| 7296 |
-
var from = this.first, to = this.first + this.size
|
| 7297 |
-
if (options.from != null && options.from > from) { from = options.from }
|
| 7298 |
-
if (options.to != null && options.to < to) { to = options.to }
|
| 7299 |
-
var copy = new Doc(getLines(this, from, to), options.mode || this.modeOption, from, this.lineSep)
|
| 7300 |
if (options.sharedHist) { copy.history = this.history
|
| 7301 |
-
; }(this.linked || (this.linked = [])).push({doc: copy, sharedHist: options.sharedHist})
|
| 7302 |
-
copy.linked = [{doc: this, isParent: true, sharedHist: options.sharedHist}]
|
| 7303 |
-
copySharedMarkers(copy, findSharedMarkers(this))
|
| 7304 |
return copy
|
| 7305 |
},
|
| 7306 |
unlinkDoc: function(other) {
|
| 7307 |
var this$1 = this;
|
| 7308 |
|
| 7309 |
-
if (other instanceof CodeMirror) { other = other.doc }
|
| 7310 |
if (this.linked) { for (var i = 0; i < this.linked.length; ++i) {
|
| 7311 |
-
var link = this$1.linked[i]
|
| 7312 |
if (link.doc != other) { continue }
|
| 7313 |
-
this$1.linked.splice(i, 1)
|
| 7314 |
-
other.unlinkDoc(this$1)
|
| 7315 |
-
detachSharedMarkers(findSharedMarkers(this$1))
|
| 7316 |
break
|
| 7317 |
} }
|
| 7318 |
// If the histories were shared, split them again
|
| 7319 |
if (other.history == this.history) {
|
| 7320 |
-
var splitIds = [other.id]
|
| 7321 |
-
linkedDocs(other, function (doc) { return splitIds.push(doc.id); }, true)
|
| 7322 |
-
other.history = new History(null)
|
| 7323 |
-
other.history.done = copyHistoryArray(this.history.done, splitIds)
|
| 7324 |
-
other.history.undone = copyHistoryArray(this.history.undone, splitIds)
|
| 7325 |
}
|
| 7326 |
},
|
| 7327 |
-
iterLinkedDocs: function(f) {linkedDocs(this, f)},
|
| 7328 |
|
| 7329 |
getMode: function() {return this.mode},
|
| 7330 |
getEditor: function() {return this.cm},
|
|
@@ -7333,70 +7357,78 @@ webpackJsonp([2],{
|
|
| 7333 |
if (this.lineSep) { return str.split(this.lineSep) }
|
| 7334 |
return splitLinesAuto(str)
|
| 7335 |
},
|
| 7336 |
-
lineSeparator: function() { return this.lineSep || "\n" }
|
| 7337 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7338 |
|
| 7339 |
// Public alias.
|
| 7340 |
-
Doc.prototype.eachLine = Doc.prototype.iter
|
| 7341 |
|
| 7342 |
// Kludge to work around strange IE behavior where it'll sometimes
|
| 7343 |
// re-fire a series of drag-related events right after the drop (#1551)
|
| 7344 |
-
var lastDrop = 0
|
| 7345 |
|
| 7346 |
function onDrop(e) {
|
| 7347 |
-
var cm = this
|
| 7348 |
-
clearDragCursor(cm)
|
| 7349 |
if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e))
|
| 7350 |
{ return }
|
| 7351 |
-
e_preventDefault(e)
|
| 7352 |
-
if (ie) { lastDrop = +new Date }
|
| 7353 |
-
var pos = posFromMouse(cm, e, true), files = e.dataTransfer.files
|
| 7354 |
if (!pos || cm.isReadOnly()) { return }
|
| 7355 |
// Might be a file drop, in which case we simply extract the text
|
| 7356 |
// and insert it.
|
| 7357 |
if (files && files.length && window.FileReader && window.File) {
|
| 7358 |
-
var n = files.length, text = Array(n), read = 0
|
| 7359 |
var loadFile = function (file, i) {
|
| 7360 |
if (cm.options.allowDropFileTypes &&
|
| 7361 |
indexOf(cm.options.allowDropFileTypes, file.type) == -1)
|
| 7362 |
{ return }
|
| 7363 |
|
| 7364 |
-
var reader = new FileReader
|
| 7365 |
reader.onload = operation(cm, function () {
|
| 7366 |
-
var content = reader.result
|
| 7367 |
-
if (/[\x00-\x08\x0e-\x1f]{2}/.test(content)) { content = "" }
|
| 7368 |
-
text[i] = content
|
| 7369 |
if (++read == n) {
|
| 7370 |
-
pos = clipPos(cm.doc, pos)
|
| 7371 |
var change = {from: pos, to: pos,
|
| 7372 |
text: cm.doc.splitLines(text.join(cm.doc.lineSeparator())),
|
| 7373 |
-
origin: "paste"}
|
| 7374 |
-
makeChange(cm.doc, change)
|
| 7375 |
-
setSelectionReplaceHistory(cm.doc, simpleSelection(pos, changeEnd(change)))
|
| 7376 |
}
|
| 7377 |
-
})
|
| 7378 |
-
reader.readAsText(file)
|
| 7379 |
-
}
|
| 7380 |
-
for (var i = 0; i < n; ++i) { loadFile(files[i], i) }
|
| 7381 |
} else { // Normal drop
|
| 7382 |
// Don't do a replace if the drop happened inside of the selected text.
|
| 7383 |
if (cm.state.draggingText && cm.doc.sel.contains(pos) > -1) {
|
| 7384 |
-
cm.state.draggingText(e)
|
| 7385 |
// Ensure the editor is re-focused
|
| 7386 |
-
setTimeout(function () { return cm.display.input.focus(); }, 20)
|
| 7387 |
return
|
| 7388 |
}
|
| 7389 |
try {
|
| 7390 |
-
var text$1 = e.dataTransfer.getData("Text")
|
| 7391 |
if (text$1) {
|
| 7392 |
-
var selected
|
| 7393 |
if (cm.state.draggingText && !cm.state.draggingText.copy)
|
| 7394 |
-
{ selected = cm.listSelections() }
|
| 7395 |
-
setSelectionNoUndo(cm.doc, simpleSelection(pos, pos))
|
| 7396 |
if (selected) { for (var i$1 = 0; i$1 < selected.length; ++i$1)
|
| 7397 |
-
{ replaceRange(cm.doc, "", selected[i$1].anchor, selected[i$1].head, "drag") } }
|
| 7398 |
-
cm.replaceSelection(text$1, "around", "paste")
|
| 7399 |
-
cm.display.input.focus()
|
| 7400 |
}
|
| 7401 |
}
|
| 7402 |
catch(e){}
|
|
@@ -7407,41 +7439,41 @@ webpackJsonp([2],{
|
|
| 7407 |
if (ie && (!cm.state.draggingText || +new Date - lastDrop < 100)) { e_stop(e); return }
|
| 7408 |
if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e)) { return }
|
| 7409 |
|
| 7410 |
-
e.dataTransfer.setData("Text", cm.getSelection())
|
| 7411 |
-
e.dataTransfer.effectAllowed = "copyMove"
|
| 7412 |
|
| 7413 |
// Use dummy image instead of default browsers image.
|
| 7414 |
// Recent Safari (~6.0.2) have a tendency to segfault when this happens, so we don't do it there.
|
| 7415 |
if (e.dataTransfer.setDragImage && !safari) {
|
| 7416 |
-
var img = elt("img", null, null, "position: fixed; left: 0; top: 0;")
|
| 7417 |
-
img.src = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="
|
| 7418 |
if (presto) {
|
| 7419 |
-
img.width = img.height = 1
|
| 7420 |
-
cm.display.wrapper.appendChild(img)
|
| 7421 |
// Force a relayout, or Opera won't use our image for some obscure reason
|
| 7422 |
-
img._top = img.offsetTop
|
| 7423 |
}
|
| 7424 |
-
e.dataTransfer.setDragImage(img, 0, 0)
|
| 7425 |
-
if (presto) { img.parentNode.removeChild(img) }
|
| 7426 |
}
|
| 7427 |
}
|
| 7428 |
|
| 7429 |
function onDragOver(cm, e) {
|
| 7430 |
-
var pos = posFromMouse(cm, e)
|
| 7431 |
if (!pos) { return }
|
| 7432 |
-
var frag = document.createDocumentFragment()
|
| 7433 |
-
drawSelectionCursor(cm, pos, frag)
|
| 7434 |
if (!cm.display.dragCursor) {
|
| 7435 |
-
cm.display.dragCursor = elt("div", null, "CodeMirror-cursors CodeMirror-dragcursors")
|
| 7436 |
-
cm.display.lineSpace.insertBefore(cm.display.dragCursor, cm.display.cursorDiv)
|
| 7437 |
}
|
| 7438 |
-
removeChildrenAndAdd(cm.display.dragCursor, frag)
|
| 7439 |
}
|
| 7440 |
|
| 7441 |
function clearDragCursor(cm) {
|
| 7442 |
if (cm.display.dragCursor) {
|
| 7443 |
-
cm.display.lineSpace.removeChild(cm.display.dragCursor)
|
| 7444 |
-
cm.display.dragCursor = null
|
| 7445 |
}
|
| 7446 |
}
|
| 7447 |
|
|
@@ -7451,40 +7483,40 @@ webpackJsonp([2],{
|
|
| 7451 |
|
| 7452 |
function forEachCodeMirror(f) {
|
| 7453 |
if (!document.body.getElementsByClassName) { return }
|
| 7454 |
-
var byClass = document.body.getElementsByClassName("CodeMirror")
|
| 7455 |
for (var i = 0; i < byClass.length; i++) {
|
| 7456 |
-
var cm = byClass[i].CodeMirror
|
| 7457 |
-
if (cm) { f(cm) }
|
| 7458 |
}
|
| 7459 |
}
|
| 7460 |
|
| 7461 |
-
var globalsRegistered = false
|
| 7462 |
function ensureGlobalHandlers() {
|
| 7463 |
if (globalsRegistered) { return }
|
| 7464 |
-
registerGlobalHandlers()
|
| 7465 |
-
globalsRegistered = true
|
| 7466 |
}
|
| 7467 |
function registerGlobalHandlers() {
|
| 7468 |
// When the window resizes, we need to refresh active editors.
|
| 7469 |
-
var resizeTimer
|
| 7470 |
on(window, "resize", function () {
|
| 7471 |
if (resizeTimer == null) { resizeTimer = setTimeout(function () {
|
| 7472 |
-
resizeTimer = null
|
| 7473 |
-
forEachCodeMirror(onResize)
|
| 7474 |
-
}, 100) }
|
| 7475 |
-
})
|
| 7476 |
// When the window loses focus, we want to show the editor as blurred
|
| 7477 |
-
on(window, "blur", function () { return forEachCodeMirror(onBlur); })
|
| 7478 |
}
|
| 7479 |
// Called when the window resizes
|
| 7480 |
function onResize(cm) {
|
| 7481 |
-
var d = cm.display
|
| 7482 |
if (d.lastWrapHeight == d.wrapper.clientHeight && d.lastWrapWidth == d.wrapper.clientWidth)
|
| 7483 |
{ return }
|
| 7484 |
// Might be a text scaling operation, clear size caches.
|
| 7485 |
-
d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = null
|
| 7486 |
-
d.scrollbarsClipped = false
|
| 7487 |
-
cm.setSize()
|
| 7488 |
}
|
| 7489 |
|
| 7490 |
var keyNames = {
|
|
@@ -7496,16 +7528,16 @@ webpackJsonp([2],{
|
|
| 7496 |
173: "-", 186: ";", 187: "=", 188: ",", 189: "-", 190: ".", 191: "/", 192: "`", 219: "[", 220: "\\",
|
| 7497 |
221: "]", 222: "'", 63232: "Up", 63233: "Down", 63234: "Left", 63235: "Right", 63272: "Delete",
|
| 7498 |
63273: "Home", 63275: "End", 63276: "PageUp", 63277: "PageDown", 63302: "Insert"
|
| 7499 |
-
}
|
| 7500 |
|
| 7501 |
// Number keys
|
| 7502 |
-
for (var i = 0; i < 10; i++) { keyNames[i + 48] = keyNames[i + 96] = String(i) }
|
| 7503 |
// Alphabetic keys
|
| 7504 |
-
for (var i$1 = 65; i$1 <= 90; i$1++) { keyNames[i$1] = String.fromCharCode(i$1) }
|
| 7505 |
// Function keys
|
| 7506 |
-
for (var i$2 = 1; i$2 <= 12; i$2++) { keyNames[i$2 + 111] = keyNames[i$2 + 63235] = "F" + i$2 }
|
| 7507 |
|
| 7508 |
-
var keyMap = {}
|
| 7509 |
|
| 7510 |
keyMap.basic = {
|
| 7511 |
"Left": "goCharLeft", "Right": "goCharRight", "Up": "goLineUp", "Down": "goLineDown",
|
|
@@ -7514,7 +7546,7 @@ webpackJsonp([2],{
|
|
| 7514 |
"Tab": "defaultTab", "Shift-Tab": "indentAuto",
|
| 7515 |
"Enter": "newlineAndIndent", "Insert": "toggleOverwrite",
|
| 7516 |
"Esc": "singleSelection"
|
| 7517 |
-
}
|
| 7518 |
// Note that the save and find-related commands aren't defined by
|
| 7519 |
// default. User code or addons can define them. Unknown commands
|
| 7520 |
// are simply ignored.
|
|
@@ -7527,7 +7559,7 @@ webpackJsonp([2],{
|
|
| 7527 |
"Ctrl-[": "indentLess", "Ctrl-]": "indentMore",
|
| 7528 |
"Ctrl-U": "undoSelection", "Shift-Ctrl-U": "redoSelection", "Alt-U": "redoSelection",
|
| 7529 |
fallthrough: "basic"
|
| 7530 |
-
}
|
| 7531 |
// Very basic readline/emacs-style bindings, which are standard on Mac.
|
| 7532 |
keyMap.emacsy = {
|
| 7533 |
"Ctrl-F": "goCharRight", "Ctrl-B": "goCharLeft", "Ctrl-P": "goLineUp", "Ctrl-N": "goLineDown",
|
|
@@ -7535,7 +7567,7 @@ webpackJsonp([2],{
|
|
| 7535 |
"Ctrl-V": "goPageDown", "Shift-Ctrl-V": "goPageUp", "Ctrl-D": "delCharAfter", "Ctrl-H": "delCharBefore",
|
| 7536 |
"Alt-D": "delWordAfter", "Alt-Backspace": "delWordBefore", "Ctrl-K": "killLine", "Ctrl-T": "transposeChars",
|
| 7537 |
"Ctrl-O": "openLine"
|
| 7538 |
-
}
|
| 7539 |
keyMap.macDefault = {
|
| 7540 |
"Cmd-A": "selectAll", "Cmd-D": "deleteLine", "Cmd-Z": "undo", "Shift-Cmd-Z": "redo", "Cmd-Y": "redo",
|
| 7541 |
"Cmd-Home": "goDocStart", "Cmd-Up": "goDocStart", "Cmd-End": "goDocEnd", "Cmd-Down": "goDocEnd", "Alt-Left": "goGroupLeft",
|
|
@@ -7545,27 +7577,27 @@ webpackJsonp([2],{
|
|
| 7545 |
"Cmd-[": "indentLess", "Cmd-]": "indentMore", "Cmd-Backspace": "delWrappedLineLeft", "Cmd-Delete": "delWrappedLineRight",
|
| 7546 |
"Cmd-U": "undoSelection", "Shift-Cmd-U": "redoSelection", "Ctrl-Up": "goDocStart", "Ctrl-Down": "goDocEnd",
|
| 7547 |
fallthrough: ["basic", "emacsy"]
|
| 7548 |
-
}
|
| 7549 |
-
keyMap["default"] = mac ? keyMap.macDefault : keyMap.pcDefault
|
| 7550 |
|
| 7551 |
// KEYMAP DISPATCH
|
| 7552 |
|
| 7553 |
function normalizeKeyName(name) {
|
| 7554 |
-
var parts = name.split(/-(?!$)/)
|
| 7555 |
-
name = parts[parts.length - 1]
|
| 7556 |
-
var alt, ctrl, shift, cmd
|
| 7557 |
for (var i = 0; i < parts.length - 1; i++) {
|
| 7558 |
-
var mod = parts[i]
|
| 7559 |
-
if (/^(cmd|meta|m)$/i.test(mod)) { cmd = true }
|
| 7560 |
-
else if (/^a(lt)?$/i.test(mod)) { alt = true }
|
| 7561 |
-
else if (/^(c|ctrl|control)$/i.test(mod)) { ctrl = true }
|
| 7562 |
-
else if (/^s(hift)?$/i.test(mod)) { shift = true }
|
| 7563 |
else { throw new Error("Unrecognized modifier name: " + mod) }
|
| 7564 |
}
|
| 7565 |
-
if (alt) { name = "Alt-" + name }
|
| 7566 |
-
if (ctrl) { name = "Ctrl-" + name }
|
| 7567 |
-
if (cmd) { name = "Cmd-" + name }
|
| 7568 |
-
if (shift) { name = "Shift-" + name }
|
| 7569 |
return name
|
| 7570 |
}
|
| 7571 |
|
|
@@ -7575,44 +7607,44 @@ webpackJsonp([2],{
|
|
| 7575 |
// new normalized keymap, and then updates the old object to reflect
|
| 7576 |
// this.
|
| 7577 |
function normalizeKeyMap(keymap) {
|
| 7578 |
-
var copy = {}
|
| 7579 |
for (var keyname in keymap) { if (keymap.hasOwnProperty(keyname)) {
|
| 7580 |
-
var value = keymap[keyname]
|
| 7581 |
if (/^(name|fallthrough|(de|at)tach)$/.test(keyname)) { continue }
|
| 7582 |
if (value == "...") { delete keymap[keyname]; continue }
|
| 7583 |
|
| 7584 |
-
var keys = map(keyname.split(" "), normalizeKeyName)
|
| 7585 |
for (var i = 0; i < keys.length; i++) {
|
| 7586 |
-
var val = (void 0), name = (void 0)
|
| 7587 |
if (i == keys.length - 1) {
|
| 7588 |
-
name = keys.join(" ")
|
| 7589 |
-
val = value
|
| 7590 |
} else {
|
| 7591 |
-
name = keys.slice(0, i + 1).join(" ")
|
| 7592 |
-
val = "..."
|
| 7593 |
}
|
| 7594 |
-
var prev = copy[name]
|
| 7595 |
-
if (!prev) { copy[name] = val }
|
| 7596 |
else if (prev != val) { throw new Error("Inconsistent bindings for " + name) }
|
| 7597 |
}
|
| 7598 |
-
delete keymap[keyname]
|
| 7599 |
} }
|
| 7600 |
-
for (var prop in copy) { keymap[prop] = copy[prop] }
|
| 7601 |
return keymap
|
| 7602 |
}
|
| 7603 |
|
| 7604 |
-
function lookupKey(key, map, handle, context) {
|
| 7605 |
-
map = getKeyMap(map)
|
| 7606 |
-
var found = map.call ? map.call(key, context) : map[key]
|
| 7607 |
if (found === false) { return "nothing" }
|
| 7608 |
if (found === "...") { return "multi" }
|
| 7609 |
if (found != null && handle(found)) { return "handled" }
|
| 7610 |
|
| 7611 |
-
if (map.fallthrough) {
|
| 7612 |
-
if (Object.prototype.toString.call(map.fallthrough) != "[object Array]")
|
| 7613 |
-
{ return lookupKey(key, map.fallthrough, handle, context) }
|
| 7614 |
-
for (var i = 0; i < map.fallthrough.length; i++) {
|
| 7615 |
-
var result = lookupKey(key, map.fallthrough[i], handle, context)
|
| 7616 |
if (result) { return result }
|
| 7617 |
}
|
| 7618 |
}
|
|
@@ -7621,19 +7653,19 @@ webpackJsonp([2],{
|
|
| 7621 |
// Modifier key presses don't count as 'real' key presses for the
|
| 7622 |
// purpose of keymap fallthrough.
|
| 7623 |
function isModifierKey(value) {
|
| 7624 |
-
var name = typeof value == "string" ? value : keyNames[value.keyCode]
|
| 7625 |
return name == "Ctrl" || name == "Alt" || name == "Shift" || name == "Mod"
|
| 7626 |
}
|
| 7627 |
|
| 7628 |
// Look up the name of a key as indicated by an event object.
|
| 7629 |
function keyName(event, noShift) {
|
| 7630 |
if (presto && event.keyCode == 34 && event["char"]) { return false }
|
| 7631 |
-
var base = keyNames[event.keyCode], name = base
|
| 7632 |
if (name == null || event.altGraphKey) { return false }
|
| 7633 |
-
if (event.altKey && base != "Alt") { name = "Alt-" + name }
|
| 7634 |
-
if ((flipCtrlCmd ? event.metaKey : event.ctrlKey) && base != "Ctrl") { name = "Ctrl-" + name }
|
| 7635 |
-
if ((flipCtrlCmd ? event.ctrlKey : event.metaKey) && base != "Cmd") { name = "Cmd-" + name }
|
| 7636 |
-
if (!noShift && event.shiftKey && base != "Shift") { name = "Shift-" + name }
|
| 7637 |
return name
|
| 7638 |
}
|
| 7639 |
|
|
@@ -7644,26 +7676,26 @@ webpackJsonp([2],{
|
|
| 7644 |
// Helper for deleting text near the selection(s), used to implement
|
| 7645 |
// backspace, delete, and similar functionality.
|
| 7646 |
function deleteNearSelection(cm, compute) {
|
| 7647 |
-
var ranges = cm.doc.sel.ranges, kill = []
|
| 7648 |
// Build up a set of ranges to kill first, merging overlapping
|
| 7649 |
// ranges.
|
| 7650 |
for (var i = 0; i < ranges.length; i++) {
|
| 7651 |
-
var toKill = compute(ranges[i])
|
| 7652 |
while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {
|
| 7653 |
-
var replaced = kill.pop()
|
| 7654 |
if (cmp(replaced.from, toKill.from) < 0) {
|
| 7655 |
-
toKill.from = replaced.from
|
| 7656 |
break
|
| 7657 |
}
|
| 7658 |
}
|
| 7659 |
-
kill.push(toKill)
|
| 7660 |
}
|
| 7661 |
// Next, remove those actual ranges.
|
| 7662 |
runInOp(cm, function () {
|
| 7663 |
for (var i = kill.length - 1; i >= 0; i--)
|
| 7664 |
-
{ replaceRange(cm.doc, "", kill[i].from, kill[i].to, "+delete") }
|
| 7665 |
-
ensureCursorVisible(cm)
|
| 7666 |
-
})
|
| 7667 |
}
|
| 7668 |
|
| 7669 |
// Commands are parameter-less actions that can be performed on an
|
|
@@ -7673,7 +7705,7 @@ webpackJsonp([2],{
|
|
| 7673 |
singleSelection: function (cm) { return cm.setSelection(cm.getCursor("anchor"), cm.getCursor("head"), sel_dontScroll); },
|
| 7674 |
killLine: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7675 |
if (range.empty()) {
|
| 7676 |
-
var len = getLine(cm.doc, range.head.line).text.length
|
| 7677 |
if (range.head.ch == len && range.head.line < cm.lastLine())
|
| 7678 |
{ return {from: range.head, to: Pos(range.head.line + 1, 0)} }
|
| 7679 |
else
|
|
@@ -7690,13 +7722,13 @@ webpackJsonp([2],{
|
|
| 7690 |
from: Pos(range.from().line, 0), to: range.from()
|
| 7691 |
}); }); },
|
| 7692 |
delWrappedLineLeft: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7693 |
-
var top = cm.charCoords(range.head, "div").top + 5
|
| 7694 |
-
var leftPos = cm.coordsChar({left: 0, top: top}, "div")
|
| 7695 |
return {from: leftPos, to: range.from()}
|
| 7696 |
}); },
|
| 7697 |
delWrappedLineRight: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7698 |
-
var top = cm.charCoords(range.head, "div").top + 5
|
| 7699 |
-
var rightPos = cm.coordsChar({left: cm.display.lineDiv.offsetWidth + 100, top: top}, "div")
|
| 7700 |
return {from: range.from(), to: rightPos }
|
| 7701 |
}); },
|
| 7702 |
undo: function (cm) { return cm.undo(); },
|
|
@@ -7715,16 +7747,16 @@ webpackJsonp([2],{
|
|
| 7715 |
{origin: "+move", bias: -1}
|
| 7716 |
); },
|
| 7717 |
goLineRight: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7718 |
-
var top = cm.charCoords(range.head, "div").top + 5
|
| 7719 |
return cm.coordsChar({left: cm.display.lineDiv.offsetWidth + 100, top: top}, "div")
|
| 7720 |
}, sel_move); },
|
| 7721 |
goLineLeft: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7722 |
-
var top = cm.charCoords(range.head, "div").top + 5
|
| 7723 |
return cm.coordsChar({left: 0, top: top}, "div")
|
| 7724 |
}, sel_move); },
|
| 7725 |
goLineLeftSmart: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7726 |
-
var top = cm.charCoords(range.head, "div").top + 5
|
| 7727 |
-
var pos = cm.coordsChar({left: 0, top: top}, "div")
|
| 7728 |
if (pos.ch < cm.getLine(pos.line).search(/\S/)) { return lineStartSmart(cm, range.head) }
|
| 7729 |
return pos
|
| 7730 |
}, sel_move); },
|
|
@@ -7751,17 +7783,17 @@ webpackJsonp([2],{
|
|
| 7751 |
indentLess: function (cm) { return cm.indentSelection("subtract"); },
|
| 7752 |
insertTab: function (cm) { return cm.replaceSelection("\t"); },
|
| 7753 |
insertSoftTab: function (cm) {
|
| 7754 |
-
var spaces = [], ranges = cm.listSelections(), tabSize = cm.options.tabSize
|
| 7755 |
for (var i = 0; i < ranges.length; i++) {
|
| 7756 |
-
var pos = ranges[i].from()
|
| 7757 |
-
var col = countColumn(cm.getLine(pos.line), pos.ch, tabSize)
|
| 7758 |
-
spaces.push(spaceStr(tabSize - col % tabSize))
|
| 7759 |
}
|
| 7760 |
-
cm.replaceSelections(spaces)
|
| 7761 |
},
|
| 7762 |
defaultTab: function (cm) {
|
| 7763 |
-
if (cm.somethingSelected()) { cm.indentSelection("add") }
|
| 7764 |
-
else { cm.execCommand("insertTab") }
|
| 7765 |
},
|
| 7766 |
// Swap the two chars left and right of each selection's head.
|
| 7767 |
// Move cursor behind the two swapped characters afterwards.
|
|
@@ -7771,63 +7803,63 @@ webpackJsonp([2],{
|
|
| 7771 |
// Doesn't do anything on an empty line.
|
| 7772 |
// Doesn't do anything with non-empty selections.
|
| 7773 |
transposeChars: function (cm) { return runInOp(cm, function () {
|
| 7774 |
-
var ranges = cm.listSelections(), newSel = []
|
| 7775 |
for (var i = 0; i < ranges.length; i++) {
|
| 7776 |
if (!ranges[i].empty()) { continue }
|
| 7777 |
-
var cur = ranges[i].head, line = getLine(cm.doc, cur.line).text
|
| 7778 |
if (line) {
|
| 7779 |
-
if (cur.ch == line.length) { cur = new Pos(cur.line, cur.ch - 1) }
|
| 7780 |
if (cur.ch > 0) {
|
| 7781 |
-
cur = new Pos(cur.line, cur.ch + 1)
|
| 7782 |
cm.replaceRange(line.charAt(cur.ch - 1) + line.charAt(cur.ch - 2),
|
| 7783 |
-
Pos(cur.line, cur.ch - 2), cur, "+transpose")
|
| 7784 |
} else if (cur.line > cm.doc.first) {
|
| 7785 |
-
var prev = getLine(cm.doc, cur.line - 1).text
|
| 7786 |
if (prev) {
|
| 7787 |
-
cur = new Pos(cur.line, 1)
|
| 7788 |
cm.replaceRange(line.charAt(0) + cm.doc.lineSeparator() +
|
| 7789 |
prev.charAt(prev.length - 1),
|
| 7790 |
-
Pos(cur.line - 1, prev.length - 1), cur, "+transpose")
|
| 7791 |
}
|
| 7792 |
}
|
| 7793 |
}
|
| 7794 |
-
newSel.push(new Range(cur, cur))
|
| 7795 |
}
|
| 7796 |
-
cm.setSelections(newSel)
|
| 7797 |
}); },
|
| 7798 |
newlineAndIndent: function (cm) { return runInOp(cm, function () {
|
| 7799 |
-
var sels = cm.listSelections()
|
| 7800 |
for (var i = sels.length - 1; i >= 0; i--)
|
| 7801 |
-
{ cm.replaceRange(cm.doc.lineSeparator(), sels[i].anchor, sels[i].head, "+input") }
|
| 7802 |
-
sels = cm.listSelections()
|
| 7803 |
for (var i$1 = 0; i$1 < sels.length; i$1++)
|
| 7804 |
-
{ cm.indentLine(sels[i$1].from().line, null, true) }
|
| 7805 |
-
ensureCursorVisible(cm)
|
| 7806 |
}); },
|
| 7807 |
openLine: function (cm) { return cm.replaceSelection("\n", "start"); },
|
| 7808 |
toggleOverwrite: function (cm) { return cm.toggleOverwrite(); }
|
| 7809 |
-
}
|
| 7810 |
|
| 7811 |
|
| 7812 |
function lineStart(cm, lineN) {
|
| 7813 |
-
var line = getLine(cm.doc, lineN)
|
| 7814 |
-
var visual = visualLine(line)
|
| 7815 |
-
if (visual != line) { lineN = lineNo(visual) }
|
| 7816 |
return endOfLine(true, cm, visual, lineN, 1)
|
| 7817 |
}
|
| 7818 |
function lineEnd(cm, lineN) {
|
| 7819 |
-
var line = getLine(cm.doc, lineN)
|
| 7820 |
-
var visual = visualLineEnd(line)
|
| 7821 |
-
if (visual != line) { lineN = lineNo(visual) }
|
| 7822 |
return endOfLine(true, cm, line, lineN, -1)
|
| 7823 |
}
|
| 7824 |
function lineStartSmart(cm, pos) {
|
| 7825 |
-
var start = lineStart(cm, pos.line)
|
| 7826 |
-
var line = getLine(cm.doc, start.line)
|
| 7827 |
-
var order = getOrder(line)
|
| 7828 |
if (!order || order[0].level == 0) {
|
| 7829 |
-
var firstNonWS = Math.max(0, line.text.search(/\S/))
|
| 7830 |
-
var inWS = pos.line == start.line && pos.ch <= firstNonWS && pos.ch
|
| 7831 |
return Pos(start.line, inWS ? 0 : firstNonWS, start.sticky)
|
| 7832 |
}
|
| 7833 |
return start
|
|
@@ -7836,60 +7868,60 @@ webpackJsonp([2],{
|
|
| 7836 |
// Run a handler that was bound to a key.
|
| 7837 |
function doHandleBinding(cm, bound, dropShift) {
|
| 7838 |
if (typeof bound == "string") {
|
| 7839 |
-
bound = commands[bound]
|
| 7840 |
if (!bound) { return false }
|
| 7841 |
}
|
| 7842 |
// Ensure previous input has been read, so that the handler sees a
|
| 7843 |
// consistent view of the document
|
| 7844 |
-
cm.display.input.ensurePolled()
|
| 7845 |
-
var prevShift = cm.display.shift, done = false
|
| 7846 |
try {
|
| 7847 |
-
if (cm.isReadOnly()) { cm.state.suppressEdits = true }
|
| 7848 |
-
if (dropShift) { cm.display.shift = false }
|
| 7849 |
-
done = bound(cm) != Pass
|
| 7850 |
} finally {
|
| 7851 |
-
cm.display.shift = prevShift
|
| 7852 |
-
cm.state.suppressEdits = false
|
| 7853 |
}
|
| 7854 |
return done
|
| 7855 |
}
|
| 7856 |
|
| 7857 |
function lookupKeyForEditor(cm, name, handle) {
|
| 7858 |
for (var i = 0; i < cm.state.keyMaps.length; i++) {
|
| 7859 |
-
var result = lookupKey(name, cm.state.keyMaps[i], handle, cm)
|
| 7860 |
if (result) { return result }
|
| 7861 |
}
|
| 7862 |
return (cm.options.extraKeys && lookupKey(name, cm.options.extraKeys, handle, cm))
|
| 7863 |
|| lookupKey(name, cm.options.keyMap, handle, cm)
|
| 7864 |
}
|
| 7865 |
|
| 7866 |
-
var stopSeq = new Delayed
|
| 7867 |
function dispatchKey(cm, name, e, handle) {
|
| 7868 |
-
var seq = cm.state.keySeq
|
| 7869 |
if (seq) {
|
| 7870 |
if (isModifierKey(name)) { return "handled" }
|
| 7871 |
stopSeq.set(50, function () {
|
| 7872 |
if (cm.state.keySeq == seq) {
|
| 7873 |
-
cm.state.keySeq = null
|
| 7874 |
-
cm.display.input.reset()
|
| 7875 |
}
|
| 7876 |
-
})
|
| 7877 |
-
name = seq + " " + name
|
| 7878 |
}
|
| 7879 |
-
var result = lookupKeyForEditor(cm, name, handle)
|
| 7880 |
|
| 7881 |
if (result == "multi")
|
| 7882 |
-
{ cm.state.keySeq = name }
|
| 7883 |
if (result == "handled")
|
| 7884 |
-
{ signalLater(cm, "keyHandled", cm, name, e) }
|
| 7885 |
|
| 7886 |
if (result == "handled" || result == "multi") {
|
| 7887 |
-
e_preventDefault(e)
|
| 7888 |
-
restartBlink(cm)
|
| 7889 |
}
|
| 7890 |
|
| 7891 |
if (seq && !result && /\'$/.test(name)) {
|
| 7892 |
-
e_preventDefault(e)
|
| 7893 |
return true
|
| 7894 |
}
|
| 7895 |
return !!result
|
|
@@ -7897,7 +7929,7 @@ webpackJsonp([2],{
|
|
| 7897 |
|
| 7898 |
// Handle a key from the keydown event.
|
| 7899 |
function handleKeyBinding(cm, e) {
|
| 7900 |
-
var name = keyName(e, true)
|
| 7901 |
if (!name) { return false }
|
| 7902 |
|
| 7903 |
if (e.shiftKey && !cm.state.keySeq) {
|
|
@@ -7919,59 +7951,59 @@ webpackJsonp([2],{
|
|
| 7919 |
return dispatchKey(cm, "'" + ch + "'", e, function (b) { return doHandleBinding(cm, b, true); })
|
| 7920 |
}
|
| 7921 |
|
| 7922 |
-
var lastStoppedKey = null
|
| 7923 |
function onKeyDown(e) {
|
| 7924 |
-
var cm = this
|
| 7925 |
-
cm.curOp.focus = activeElt()
|
| 7926 |
if (signalDOMEvent(cm, e)) { return }
|
| 7927 |
// IE does strange things with escape.
|
| 7928 |
-
if (ie && ie_version < 11 && e.keyCode == 27) { e.returnValue = false }
|
| 7929 |
-
var code = e.keyCode
|
| 7930 |
-
cm.display.shift = code == 16 || e.shiftKey
|
| 7931 |
-
var handled = handleKeyBinding(cm, e)
|
| 7932 |
if (presto) {
|
| 7933 |
-
lastStoppedKey = handled ? code : null
|
| 7934 |
// Opera has no cut event... we try to at least catch the key combo
|
| 7935 |
if (!handled && code == 88 && !hasCopyEvent && (mac ? e.metaKey : e.ctrlKey))
|
| 7936 |
-
{ cm.replaceSelection("", null, "cut") }
|
| 7937 |
}
|
| 7938 |
|
| 7939 |
// Turn mouse into crosshair when Alt is held on Mac.
|
| 7940 |
if (code == 18 && !/\bCodeMirror-crosshair\b/.test(cm.display.lineDiv.className))
|
| 7941 |
-
{ showCrossHair(cm) }
|
| 7942 |
}
|
| 7943 |
|
| 7944 |
function showCrossHair(cm) {
|
| 7945 |
-
var lineDiv = cm.display.lineDiv
|
| 7946 |
-
addClass(lineDiv, "CodeMirror-crosshair")
|
| 7947 |
|
| 7948 |
function up(e) {
|
| 7949 |
if (e.keyCode == 18 || !e.altKey) {
|
| 7950 |
-
rmClass(lineDiv, "CodeMirror-crosshair")
|
| 7951 |
-
off(document, "keyup", up)
|
| 7952 |
-
off(document, "mouseover", up)
|
| 7953 |
}
|
| 7954 |
}
|
| 7955 |
-
on(document, "keyup", up)
|
| 7956 |
-
on(document, "mouseover", up)
|
| 7957 |
}
|
| 7958 |
|
| 7959 |
function onKeyUp(e) {
|
| 7960 |
-
if (e.keyCode == 16) { this.doc.sel.shift = false }
|
| 7961 |
-
signalDOMEvent(this, e)
|
| 7962 |
}
|
| 7963 |
|
| 7964 |
function onKeyPress(e) {
|
| 7965 |
-
var cm = this
|
| 7966 |
if (eventInWidget(cm.display, e) || signalDOMEvent(cm, e) || e.ctrlKey && !e.altKey || mac && e.metaKey) { return }
|
| 7967 |
-
var keyCode = e.keyCode, charCode = e.charCode
|
| 7968 |
if (presto && keyCode == lastStoppedKey) {lastStoppedKey = null; e_preventDefault(e); return}
|
| 7969 |
if ((presto && (!e.which || e.which < 10)) && handleKeyBinding(cm, e)) { return }
|
| 7970 |
-
var ch = String.fromCharCode(charCode == null ? keyCode : charCode)
|
| 7971 |
// Some browsers fire keypress events for backspace
|
| 7972 |
if (ch == "\x08") { return }
|
| 7973 |
if (handleCharBinding(cm, e, ch)) { return }
|
| 7974 |
-
cm.display.input.onKeyPress(e)
|
| 7975 |
}
|
| 7976 |
|
| 7977 |
// A mouse down can be a single click, double click, triple click,
|
|
@@ -7980,43 +8012,43 @@ webpackJsonp([2],{
|
|
| 7980 |
// middle-click-paste. Or it might be a click on something we should
|
| 7981 |
// not interfere with, such as a scrollbar or widget.
|
| 7982 |
function onMouseDown(e) {
|
| 7983 |
-
var cm = this, display = cm.display
|
| 7984 |
if (signalDOMEvent(cm, e) || display.activeTouch && display.input.supportsTouch()) { return }
|
| 7985 |
-
display.input.ensurePolled()
|
| 7986 |
-
display.shift = e.shiftKey
|
| 7987 |
|
| 7988 |
if (eventInWidget(display, e)) {
|
| 7989 |
if (!webkit) {
|
| 7990 |
// Briefly turn off draggability, to allow widgets to do
|
| 7991 |
// normal dragging things.
|
| 7992 |
-
display.scroller.draggable = false
|
| 7993 |
-
setTimeout(function () { return display.scroller.draggable = true; }, 100)
|
| 7994 |
}
|
| 7995 |
return
|
| 7996 |
}
|
| 7997 |
if (clickInGutter(cm, e)) { return }
|
| 7998 |
-
var start = posFromMouse(cm, e)
|
| 7999 |
-
window.focus()
|
| 8000 |
|
| 8001 |
switch (e_button(e)) {
|
| 8002 |
case 1:
|
| 8003 |
// #3261: make sure, that we're not starting a second selection
|
| 8004 |
if (cm.state.selectingText)
|
| 8005 |
-
{ cm.state.selectingText(e) }
|
| 8006 |
else if (start)
|
| 8007 |
-
{ leftButtonDown(cm, e, start) }
|
| 8008 |
else if (e_target(e) == display.scroller)
|
| 8009 |
-
{ e_preventDefault(e) }
|
| 8010 |
break
|
| 8011 |
case 2:
|
| 8012 |
-
if (webkit) { cm.state.lastMiddleDown = +new Date }
|
| 8013 |
-
if (start) { extendSelection(cm.doc, start) }
|
| 8014 |
-
setTimeout(function () { return display.input.focus(); }, 20)
|
| 8015 |
-
e_preventDefault(e)
|
| 8016 |
break
|
| 8017 |
case 3:
|
| 8018 |
-
if (captureRightClick) { onContextMenu(cm, e) }
|
| 8019 |
-
else { delayBlurEvent(cm) }
|
| 8020 |
break
|
| 8021 |
}
|
| 8022 |
}
|
|
@@ -8024,228 +8056,228 @@ webpackJsonp([2],{
|
|
| 8024 |
var lastClick;
|
| 8025 |
var lastDoubleClick;
|
| 8026 |
function leftButtonDown(cm, e, start) {
|
| 8027 |
-
if (ie) { setTimeout(bind(ensureFocus, cm), 0) }
|
| 8028 |
-
else { cm.curOp.focus = activeElt() }
|
| 8029 |
|
| 8030 |
-
var now = +new Date, type
|
| 8031 |
if (lastDoubleClick && lastDoubleClick.time > now - 400 && cmp(lastDoubleClick.pos, start) == 0) {
|
| 8032 |
-
type = "triple"
|
| 8033 |
} else if (lastClick && lastClick.time > now - 400 && cmp(lastClick.pos, start) == 0) {
|
| 8034 |
-
type = "double"
|
| 8035 |
-
lastDoubleClick = {time: now, pos: start}
|
| 8036 |
} else {
|
| 8037 |
-
type = "single"
|
| 8038 |
-
lastClick = {time: now, pos: start}
|
| 8039 |
}
|
| 8040 |
|
| 8041 |
-
var sel = cm.doc.sel, modifier = mac ? e.metaKey : e.ctrlKey, contained
|
| 8042 |
if (cm.options.dragDrop && dragAndDrop && !cm.isReadOnly() &&
|
| 8043 |
type == "single" && (contained = sel.contains(start)) > -1 &&
|
| 8044 |
(cmp((contained = sel.ranges[contained]).from(), start) < 0 || start.xRel > 0) &&
|
| 8045 |
(cmp(contained.to(), start) > 0 || start.xRel < 0))
|
| 8046 |
-
{ leftButtonStartDrag(cm, e, start, modifier) }
|
| 8047 |
else
|
| 8048 |
-
{ leftButtonSelect(cm, e, start, type, modifier) }
|
| 8049 |
}
|
| 8050 |
|
| 8051 |
// Start a text drag. When it ends, see if any dragging actually
|
| 8052 |
// happen, and treat as a click if it didn't.
|
| 8053 |
function leftButtonStartDrag(cm, e, start, modifier) {
|
| 8054 |
-
var display = cm.display, startTime = +new Date
|
| 8055 |
var dragEnd = operation(cm, function (e2) {
|
| 8056 |
-
if (webkit) { display.scroller.draggable = false }
|
| 8057 |
-
cm.state.draggingText = false
|
| 8058 |
-
off(document, "mouseup", dragEnd)
|
| 8059 |
-
off(display.scroller, "drop", dragEnd)
|
| 8060 |
if (Math.abs(e.clientX - e2.clientX) + Math.abs(e.clientY - e2.clientY) < 10) {
|
| 8061 |
-
e_preventDefault(e2)
|
| 8062 |
if (!modifier && +new Date - 200 < startTime)
|
| 8063 |
-
{ extendSelection(cm.doc, start) }
|
| 8064 |
// Work around unexplainable focus problem in IE9 (#2127) and Chrome (#3081)
|
| 8065 |
if (webkit || ie && ie_version == 9)
|
| 8066 |
-
{ setTimeout(function () {document.body.focus(); display.input.focus()}, 20) }
|
| 8067 |
else
|
| 8068 |
-
{ display.input.focus() }
|
| 8069 |
}
|
| 8070 |
-
})
|
| 8071 |
// Let the drag handler handle this.
|
| 8072 |
-
if (webkit) { display.scroller.draggable = true }
|
| 8073 |
-
cm.state.draggingText = dragEnd
|
| 8074 |
-
dragEnd.copy = mac ? e.altKey : e.ctrlKey
|
| 8075 |
// IE's approach to draggable
|
| 8076 |
-
if (display.scroller.dragDrop) { display.scroller.dragDrop() }
|
| 8077 |
-
on(document, "mouseup", dragEnd)
|
| 8078 |
-
on(display.scroller, "drop", dragEnd)
|
| 8079 |
}
|
| 8080 |
|
| 8081 |
// Normal selection, as opposed to text dragging.
|
| 8082 |
function leftButtonSelect(cm, e, start, type, addNew) {
|
| 8083 |
-
var display = cm.display, doc = cm.doc
|
| 8084 |
-
e_preventDefault(e)
|
| 8085 |
|
| 8086 |
-
var ourRange, ourIndex, startSel = doc.sel, ranges = startSel.ranges
|
| 8087 |
if (addNew && !e.shiftKey) {
|
| 8088 |
-
ourIndex = doc.sel.contains(start)
|
| 8089 |
if (ourIndex > -1)
|
| 8090 |
-
{ ourRange = ranges[ourIndex] }
|
| 8091 |
else
|
| 8092 |
-
{ ourRange = new Range(start, start) }
|
| 8093 |
} else {
|
| 8094 |
-
ourRange = doc.sel.primary()
|
| 8095 |
-
ourIndex = doc.sel.primIndex
|
| 8096 |
}
|
| 8097 |
|
| 8098 |
if (chromeOS ? e.shiftKey && e.metaKey : e.altKey) {
|
| 8099 |
-
type = "rect"
|
| 8100 |
-
if (!addNew) { ourRange = new Range(start, start) }
|
| 8101 |
-
start = posFromMouse(cm, e, true, true)
|
| 8102 |
-
ourIndex = -1
|
| 8103 |
} else if (type == "double") {
|
| 8104 |
-
var word = cm.findWordAt(start)
|
| 8105 |
if (cm.display.shift || doc.extend)
|
| 8106 |
-
{ ourRange = extendRange(doc, ourRange, word.anchor, word.head) }
|
| 8107 |
else
|
| 8108 |
-
{ ourRange = word }
|
| 8109 |
} else if (type == "triple") {
|
| 8110 |
-
var line = new Range(Pos(start.line, 0), clipPos(doc, Pos(start.line + 1, 0)))
|
| 8111 |
if (cm.display.shift || doc.extend)
|
| 8112 |
-
{ ourRange = extendRange(doc, ourRange, line.anchor, line.head) }
|
| 8113 |
else
|
| 8114 |
-
{ ourRange = line }
|
| 8115 |
} else {
|
| 8116 |
-
ourRange = extendRange(doc, ourRange, start)
|
| 8117 |
}
|
| 8118 |
|
| 8119 |
if (!addNew) {
|
| 8120 |
-
ourIndex = 0
|
| 8121 |
-
setSelection(doc, new Selection([ourRange], 0), sel_mouse)
|
| 8122 |
-
startSel = doc.sel
|
| 8123 |
} else if (ourIndex == -1) {
|
| 8124 |
-
ourIndex = ranges.length
|
| 8125 |
setSelection(doc, normalizeSelection(ranges.concat([ourRange]), ourIndex),
|
| 8126 |
-
{scroll: false, origin: "*mouse"})
|
| 8127 |
} else if (ranges.length > 1 && ranges[ourIndex].empty() && type == "single" && !e.shiftKey) {
|
| 8128 |
setSelection(doc, normalizeSelection(ranges.slice(0, ourIndex).concat(ranges.slice(ourIndex + 1)), 0),
|
| 8129 |
-
{scroll: false, origin: "*mouse"})
|
| 8130 |
-
startSel = doc.sel
|
| 8131 |
} else {
|
| 8132 |
-
replaceOneSelection(doc, ourIndex, ourRange, sel_mouse)
|
| 8133 |
}
|
| 8134 |
|
| 8135 |
-
var lastPos = start
|
| 8136 |
function extendTo(pos) {
|
| 8137 |
if (cmp(lastPos, pos) == 0) { return }
|
| 8138 |
-
lastPos = pos
|
| 8139 |
|
| 8140 |
if (type == "rect") {
|
| 8141 |
-
var ranges = [], tabSize = cm.options.tabSize
|
| 8142 |
-
var startCol = countColumn(getLine(doc, start.line).text, start.ch, tabSize)
|
| 8143 |
-
var posCol = countColumn(getLine(doc, pos.line).text, pos.ch, tabSize)
|
| 8144 |
-
var left = Math.min(startCol, posCol), right = Math.max(startCol, posCol)
|
| 8145 |
for (var line = Math.min(start.line, pos.line), end = Math.min(cm.lastLine(), Math.max(start.line, pos.line));
|
| 8146 |
line <= end; line++) {
|
| 8147 |
-
var text = getLine(doc, line).text, leftPos = findColumn(text, left, tabSize)
|
| 8148 |
if (left == right)
|
| 8149 |
-
{ ranges.push(new Range(Pos(line, leftPos), Pos(line, leftPos))) }
|
| 8150 |
else if (text.length > leftPos)
|
| 8151 |
-
{ ranges.push(new Range(Pos(line, leftPos), Pos(line, findColumn(text, right, tabSize)))) }
|
| 8152 |
}
|
| 8153 |
-
if (!ranges.length) { ranges.push(new Range(start, start)) }
|
| 8154 |
setSelection(doc, normalizeSelection(startSel.ranges.slice(0, ourIndex).concat(ranges), ourIndex),
|
| 8155 |
-
{origin: "*mouse", scroll: false})
|
| 8156 |
-
cm.scrollIntoView(pos)
|
| 8157 |
} else {
|
| 8158 |
-
var oldRange = ourRange
|
| 8159 |
-
var anchor = oldRange.anchor, head = pos
|
| 8160 |
if (type != "single") {
|
| 8161 |
-
var range
|
| 8162 |
if (type == "double")
|
| 8163 |
-
{ range = cm.findWordAt(pos) }
|
| 8164 |
else
|
| 8165 |
-
{ range = new Range(Pos(pos.line, 0), clipPos(doc, Pos(pos.line + 1, 0))) }
|
| 8166 |
-
if (cmp(range.anchor, anchor) > 0) {
|
| 8167 |
-
head = range.head
|
| 8168 |
-
anchor = minPos(oldRange.from(), range.anchor)
|
| 8169 |
} else {
|
| 8170 |
-
head = range.anchor
|
| 8171 |
-
anchor = maxPos(oldRange.to(), range.head)
|
| 8172 |
}
|
| 8173 |
}
|
| 8174 |
-
var ranges$1 = startSel.ranges.slice(0)
|
| 8175 |
-
ranges$1[ourIndex] = new Range(clipPos(doc, anchor), head)
|
| 8176 |
-
setSelection(doc, normalizeSelection(ranges$1, ourIndex), sel_mouse)
|
| 8177 |
}
|
| 8178 |
}
|
| 8179 |
|
| 8180 |
-
var editorSize = display.wrapper.getBoundingClientRect()
|
| 8181 |
// Used to ensure timeout re-tries don't fire when another extend
|
| 8182 |
// happened in the meantime (clearTimeout isn't reliable -- at
|
| 8183 |
// least on Chrome, the timeouts still happen even when cleared,
|
| 8184 |
// if the clear happens after their scheduled firing time).
|
| 8185 |
-
var counter = 0
|
| 8186 |
|
| 8187 |
function extend(e) {
|
| 8188 |
-
var curCount = ++counter
|
| 8189 |
-
var cur = posFromMouse(cm, e, true, type == "rect")
|
| 8190 |
if (!cur) { return }
|
| 8191 |
if (cmp(cur, lastPos) != 0) {
|
| 8192 |
-
cm.curOp.focus = activeElt()
|
| 8193 |
-
extendTo(cur)
|
| 8194 |
-
var visible = visibleLines(display, doc)
|
| 8195 |
if (cur.line >= visible.to || cur.line < visible.from)
|
| 8196 |
-
{ setTimeout(operation(cm, function () {if (counter == curCount) { extend(e) }}), 150) }
|
| 8197 |
} else {
|
| 8198 |
-
var outside = e.clientY < editorSize.top ? -20 : e.clientY > editorSize.bottom ? 20 : 0
|
| 8199 |
if (outside) { setTimeout(operation(cm, function () {
|
| 8200 |
if (counter != curCount) { return }
|
| 8201 |
-
display.scroller.scrollTop += outside
|
| 8202 |
-
extend(e)
|
| 8203 |
-
}), 50) }
|
| 8204 |
}
|
| 8205 |
}
|
| 8206 |
|
| 8207 |
function done(e) {
|
| 8208 |
-
cm.state.selectingText = false
|
| 8209 |
-
counter = Infinity
|
| 8210 |
-
e_preventDefault(e)
|
| 8211 |
-
display.input.focus()
|
| 8212 |
-
off(document, "mousemove", move)
|
| 8213 |
-
off(document, "mouseup", up)
|
| 8214 |
-
doc.history.lastSelOrigin = null
|
| 8215 |
}
|
| 8216 |
|
| 8217 |
var move = operation(cm, function (e) {
|
| 8218 |
-
if (!e_button(e)) { done(e) }
|
| 8219 |
-
else { extend(e) }
|
| 8220 |
-
})
|
| 8221 |
-
var up = operation(cm, done)
|
| 8222 |
-
cm.state.selectingText = up
|
| 8223 |
-
on(document, "mousemove", move)
|
| 8224 |
-
on(document, "mouseup", up)
|
| 8225 |
}
|
| 8226 |
|
| 8227 |
|
| 8228 |
// Determines whether an event happened in the gutter, and fires the
|
| 8229 |
// handlers for the corresponding event.
|
| 8230 |
function gutterEvent(cm, e, type, prevent) {
|
| 8231 |
-
var mX, mY
|
| 8232 |
-
try { mX = e.clientX; mY = e.clientY }
|
| 8233 |
catch(e) { return false }
|
| 8234 |
if (mX >= Math.floor(cm.display.gutters.getBoundingClientRect().right)) { return false }
|
| 8235 |
-
if (prevent) { e_preventDefault(e) }
|
| 8236 |
|
| 8237 |
-
var display = cm.display
|
| 8238 |
-
var lineBox = display.lineDiv.getBoundingClientRect()
|
| 8239 |
|
| 8240 |
if (mY > lineBox.bottom || !hasHandler(cm, type)) { return e_defaultPrevented(e) }
|
| 8241 |
-
mY -= lineBox.top - display.viewOffset
|
| 8242 |
|
| 8243 |
for (var i = 0; i < cm.options.gutters.length; ++i) {
|
| 8244 |
-
var g = display.gutters.childNodes[i]
|
| 8245 |
if (g && g.getBoundingClientRect().right >= mX) {
|
| 8246 |
-
var line = lineAtHeight(cm.doc, mY)
|
| 8247 |
-
var gutter = cm.options.gutters[i]
|
| 8248 |
-
signal(cm, type, cm, line, gutter, e)
|
| 8249 |
return e_defaultPrevented(e)
|
| 8250 |
}
|
| 8251 |
}
|
|
@@ -8263,7 +8295,7 @@ webpackJsonp([2],{
|
|
| 8263 |
function onContextMenu(cm, e) {
|
| 8264 |
if (eventInWidget(cm.display, e) || contextMenuInGutter(cm, e)) { return }
|
| 8265 |
if (signalDOMEvent(cm, e, "contextmenu")) { return }
|
| 8266 |
-
cm.display.input.onContextMenu(e)
|
| 8267 |
}
|
| 8268 |
|
| 8269 |
function contextMenuInGutter(cm, e) {
|
|
@@ -8273,207 +8305,208 @@ webpackJsonp([2],{
|
|
| 8273 |
|
| 8274 |
function themeChanged(cm) {
|
| 8275 |
cm.display.wrapper.className = cm.display.wrapper.className.replace(/\s*cm-s-\S+/g, "") +
|
| 8276 |
-
cm.options.theme.replace(/(^|\s)\s*/g, " cm-s-")
|
| 8277 |
-
clearCaches(cm)
|
| 8278 |
}
|
| 8279 |
|
| 8280 |
-
var Init = {toString: function(){return "CodeMirror.Init"}}
|
| 8281 |
|
| 8282 |
-
var defaults = {}
|
| 8283 |
-
var optionHandlers = {}
|
| 8284 |
|
| 8285 |
function defineOptions(CodeMirror) {
|
| 8286 |
-
var optionHandlers = CodeMirror.optionHandlers
|
| 8287 |
|
| 8288 |
function option(name, deflt, handle, notOnInit) {
|
| 8289 |
-
CodeMirror.defaults[name] = deflt
|
| 8290 |
if (handle) { optionHandlers[name] =
|
| 8291 |
-
notOnInit ? function (cm, val, old) {if (old != Init) { handle(cm, val, old) }} : handle }
|
| 8292 |
}
|
| 8293 |
|
| 8294 |
-
CodeMirror.defineOption = option
|
| 8295 |
|
| 8296 |
// Passed to option handlers when there is no old value.
|
| 8297 |
-
CodeMirror.Init = Init
|
| 8298 |
|
| 8299 |
// These two are, on init, called from the constructor because they
|
| 8300 |
// have to be initialized before the editor can start at all.
|
| 8301 |
-
option("value", "", function (cm, val) { return cm.setValue(val); }, true)
|
| 8302 |
option("mode", null, function (cm, val) {
|
| 8303 |
-
cm.doc.modeOption = val
|
| 8304 |
-
loadMode(cm)
|
| 8305 |
-
}, true)
|
| 8306 |
|
| 8307 |
-
option("indentUnit", 2, loadMode, true)
|
| 8308 |
-
option("indentWithTabs", false)
|
| 8309 |
-
option("smartIndent", true)
|
| 8310 |
option("tabSize", 4, function (cm) {
|
| 8311 |
-
resetModeState(cm)
|
| 8312 |
-
clearCaches(cm)
|
| 8313 |
-
regChange(cm)
|
| 8314 |
-
}, true)
|
| 8315 |
option("lineSeparator", null, function (cm, val) {
|
| 8316 |
-
cm.doc.lineSep = val
|
| 8317 |
if (!val) { return }
|
| 8318 |
-
var newBreaks = [], lineNo = cm.doc.first
|
| 8319 |
cm.doc.iter(function (line) {
|
| 8320 |
for (var pos = 0;;) {
|
| 8321 |
-
var found = line.text.indexOf(val, pos)
|
| 8322 |
if (found == -1) { break }
|
| 8323 |
-
pos = found + val.length
|
| 8324 |
-
newBreaks.push(Pos(lineNo, found))
|
| 8325 |
}
|
| 8326 |
-
lineNo
|
| 8327 |
-
})
|
| 8328 |
for (var i = newBreaks.length - 1; i >= 0; i--)
|
| 8329 |
-
{ replaceRange(cm.doc, val, newBreaks[i], Pos(newBreaks[i].line, newBreaks[i].ch + val.length)) }
|
| 8330 |
-
})
|
| 8331 |
-
option("specialChars", /[\u0000-\u001f\u007f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff]/g, function (cm, val, old) {
|
| 8332 |
-
cm.state.specialChars = new RegExp(val.source + (val.test("\t") ? "" : "|\t"), "g")
|
| 8333 |
-
if (old != Init) { cm.refresh() }
|
| 8334 |
-
})
|
| 8335 |
-
option("specialCharPlaceholder", defaultSpecialCharPlaceholder, function (cm) { return cm.refresh(); }, true)
|
| 8336 |
-
option("electricChars", true)
|
| 8337 |
option("inputStyle", mobile ? "contenteditable" : "textarea", function () {
|
| 8338 |
throw new Error("inputStyle can not (yet) be changed in a running editor") // FIXME
|
| 8339 |
-
}, true)
|
| 8340 |
-
option("spellcheck", false, function (cm, val) { return cm.getInputField().spellcheck = val; }, true)
|
| 8341 |
-
option("rtlMoveVisually", !windows)
|
| 8342 |
-
option("wholeLineUpdateBefore", true)
|
| 8343 |
|
| 8344 |
option("theme", "default", function (cm) {
|
| 8345 |
-
themeChanged(cm)
|
| 8346 |
-
guttersChanged(cm)
|
| 8347 |
-
}, true)
|
| 8348 |
option("keyMap", "default", function (cm, val, old) {
|
| 8349 |
-
var next = getKeyMap(val)
|
| 8350 |
-
var prev = old != Init && getKeyMap(old)
|
| 8351 |
-
if (prev && prev.detach) { prev.detach(cm, next) }
|
| 8352 |
-
if (next.attach) { next.attach(cm, prev || null) }
|
| 8353 |
-
})
|
| 8354 |
-
option("extraKeys", null)
|
| 8355 |
|
| 8356 |
-
option("lineWrapping", false, wrappingChanged, true)
|
| 8357 |
option("gutters", [], function (cm) {
|
| 8358 |
-
setGuttersForLineNumbers(cm.options)
|
| 8359 |
-
guttersChanged(cm)
|
| 8360 |
-
}, true)
|
| 8361 |
option("fixedGutter", true, function (cm, val) {
|
| 8362 |
-
cm.display.gutters.style.left = val ? compensateForHScroll(cm.display) + "px" : "0"
|
| 8363 |
-
cm.refresh()
|
| 8364 |
-
}, true)
|
| 8365 |
-
option("coverGutterNextToScrollbar", false, function (cm) { return updateScrollbars(cm); }, true)
|
| 8366 |
option("scrollbarStyle", "native", function (cm) {
|
| 8367 |
-
initScrollbars(cm)
|
| 8368 |
-
updateScrollbars(cm)
|
| 8369 |
-
cm.display.scrollbars.setScrollTop(cm.doc.scrollTop)
|
| 8370 |
-
cm.display.scrollbars.setScrollLeft(cm.doc.scrollLeft)
|
| 8371 |
-
}, true)
|
| 8372 |
option("lineNumbers", false, function (cm) {
|
| 8373 |
-
setGuttersForLineNumbers(cm.options)
|
| 8374 |
-
guttersChanged(cm)
|
| 8375 |
-
}, true)
|
| 8376 |
-
option("firstLineNumber", 1, guttersChanged, true)
|
| 8377 |
-
option("lineNumberFormatter", function (integer) { return integer; }, guttersChanged, true)
|
| 8378 |
-
option("showCursorWhenSelecting", false, updateSelection, true)
|
| 8379 |
|
| 8380 |
-
option("resetSelectionOnContextMenu", true)
|
| 8381 |
-
option("lineWiseCopyCut", true)
|
| 8382 |
|
| 8383 |
option("readOnly", false, function (cm, val) {
|
| 8384 |
if (val == "nocursor") {
|
| 8385 |
-
onBlur(cm)
|
| 8386 |
-
cm.display.input.blur()
|
| 8387 |
-
cm.display.disabled = true
|
| 8388 |
} else {
|
| 8389 |
-
cm.display.disabled = false
|
| 8390 |
}
|
| 8391 |
-
cm.display.input.readOnlyChanged(val)
|
| 8392 |
-
})
|
| 8393 |
-
option("disableInput", false, function (cm, val) {if (!val) { cm.display.input.reset() }}, true)
|
| 8394 |
-
option("dragDrop", true, dragDropChanged)
|
| 8395 |
-
option("allowDropFileTypes", null)
|
| 8396 |
-
|
| 8397 |
-
option("cursorBlinkRate", 530)
|
| 8398 |
-
option("cursorScrollMargin", 0)
|
| 8399 |
-
option("cursorHeight", 1, updateSelection, true)
|
| 8400 |
-
option("singleCursorHeightPerLine", true, updateSelection, true)
|
| 8401 |
-
option("workTime", 100)
|
| 8402 |
-
option("workDelay", 100)
|
| 8403 |
-
option("flattenSpans", true, resetModeState, true)
|
| 8404 |
-
option("addModeClass", false, resetModeState, true)
|
| 8405 |
-
option("pollInterval", 100)
|
| 8406 |
-
option("undoDepth", 200, function (cm, val) { return cm.doc.history.undoDepth = val; })
|
| 8407 |
-
option("historyEventDelay", 1250)
|
| 8408 |
-
option("viewportMargin", 10, function (cm) { return cm.refresh(); }, true)
|
| 8409 |
-
option("maxHighlightLength", 10000, resetModeState, true)
|
| 8410 |
option("moveInputWithCursor", true, function (cm, val) {
|
| 8411 |
-
if (!val) { cm.display.input.resetPosition() }
|
| 8412 |
-
})
|
| 8413 |
|
| 8414 |
-
option("tabindex", null, function (cm, val) { return cm.display.input.getField().tabIndex = val || ""; })
|
| 8415 |
-
option("autofocus", null)
|
|
|
|
| 8416 |
}
|
| 8417 |
|
| 8418 |
function guttersChanged(cm) {
|
| 8419 |
-
updateGutters(cm)
|
| 8420 |
-
regChange(cm)
|
| 8421 |
-
alignHorizontally(cm)
|
| 8422 |
}
|
| 8423 |
|
| 8424 |
function dragDropChanged(cm, value, old) {
|
| 8425 |
-
var wasOn = old && old != Init
|
| 8426 |
if (!value != !wasOn) {
|
| 8427 |
-
var funcs = cm.display.dragFunctions
|
| 8428 |
-
var toggle = value ? on : off
|
| 8429 |
-
toggle(cm.display.scroller, "dragstart", funcs.start)
|
| 8430 |
-
toggle(cm.display.scroller, "dragenter", funcs.enter)
|
| 8431 |
-
toggle(cm.display.scroller, "dragover", funcs.over)
|
| 8432 |
-
toggle(cm.display.scroller, "dragleave", funcs.leave)
|
| 8433 |
-
toggle(cm.display.scroller, "drop", funcs.drop)
|
| 8434 |
}
|
| 8435 |
}
|
| 8436 |
|
| 8437 |
function wrappingChanged(cm) {
|
| 8438 |
if (cm.options.lineWrapping) {
|
| 8439 |
-
addClass(cm.display.wrapper, "CodeMirror-wrap")
|
| 8440 |
-
cm.display.sizer.style.minWidth = ""
|
| 8441 |
-
cm.display.sizerWidth = null
|
| 8442 |
} else {
|
| 8443 |
-
rmClass(cm.display.wrapper, "CodeMirror-wrap")
|
| 8444 |
-
findMaxLine(cm)
|
| 8445 |
}
|
| 8446 |
-
estimateLineHeights(cm)
|
| 8447 |
-
regChange(cm)
|
| 8448 |
-
clearCaches(cm)
|
| 8449 |
-
setTimeout(function () { return updateScrollbars(cm); }, 100)
|
| 8450 |
}
|
| 8451 |
|
| 8452 |
// A CodeMirror instance represents an editor. This is the object
|
| 8453 |
// that user code is usually dealing with.
|
| 8454 |
|
| 8455 |
-
function CodeMirror(place, options) {
|
| 8456 |
var this$1 = this;
|
| 8457 |
|
| 8458 |
-
if (!(this instanceof CodeMirror)) { return new CodeMirror(place, options) }
|
| 8459 |
|
| 8460 |
-
this.options = options = options ? copyObj(options) : {}
|
| 8461 |
// Determine effective options based on given values and defaults.
|
| 8462 |
-
copyObj(defaults, options, false)
|
| 8463 |
-
setGuttersForLineNumbers(options)
|
| 8464 |
-
|
| 8465 |
-
var doc = options.value
|
| 8466 |
-
if (typeof doc == "string") { doc = new Doc(doc, options.mode, null, options.lineSeparator) }
|
| 8467 |
-
this.doc = doc
|
| 8468 |
-
|
| 8469 |
-
var input = new CodeMirror.inputStyles[options.inputStyle](this)
|
| 8470 |
-
var display = this.display = new Display(place, doc, input)
|
| 8471 |
-
display.wrapper.CodeMirror = this
|
| 8472 |
-
updateGutters(this)
|
| 8473 |
-
themeChanged(this)
|
| 8474 |
if (options.lineWrapping)
|
| 8475 |
-
{ this.display.wrapper.className += " CodeMirror-wrap" }
|
| 8476 |
-
initScrollbars(this)
|
| 8477 |
|
| 8478 |
this.state = {
|
| 8479 |
keyMaps: [], // stores maps added by addKeyMap
|
|
@@ -8489,154 +8522,154 @@ webpackJsonp([2],{
|
|
| 8489 |
highlight: new Delayed(), // stores highlight worker timeout
|
| 8490 |
keySeq: null, // Unfinished key sequence
|
| 8491 |
specialChars: null
|
| 8492 |
-
}
|
| 8493 |
|
| 8494 |
-
if (options.autofocus && !mobile) { display.input.focus() }
|
| 8495 |
|
| 8496 |
// Override magic textarea content restore that IE sometimes does
|
| 8497 |
// on our hidden textarea on reload
|
| 8498 |
-
if (ie && ie_version < 11) { setTimeout(function () { return this$1.display.input.reset(true); }, 20) }
|
| 8499 |
|
| 8500 |
-
registerEventHandlers(this)
|
| 8501 |
-
ensureGlobalHandlers()
|
| 8502 |
|
| 8503 |
-
startOperation(this)
|
| 8504 |
-
this.curOp.forceUpdate = true
|
| 8505 |
-
attachDoc(this, doc)
|
| 8506 |
|
| 8507 |
if ((options.autofocus && !mobile) || this.hasFocus())
|
| 8508 |
-
{ setTimeout(bind(onFocus, this), 20) }
|
| 8509 |
else
|
| 8510 |
-
{ onBlur(this) }
|
| 8511 |
|
| 8512 |
for (var opt in optionHandlers) { if (optionHandlers.hasOwnProperty(opt))
|
| 8513 |
-
{ optionHandlers[opt](this$1, options[opt], Init) } }
|
| 8514 |
-
maybeUpdateLineNumberWidth(this)
|
| 8515 |
-
if (options.finishInit) { options.finishInit(this) }
|
| 8516 |
-
for (var i = 0; i < initHooks.length; ++i) { initHooks[i](this$1) }
|
| 8517 |
-
endOperation(this)
|
| 8518 |
// Suppress optimizelegibility in Webkit, since it breaks text
|
| 8519 |
// measuring on line wrapping boundaries.
|
| 8520 |
if (webkit && options.lineWrapping &&
|
| 8521 |
getComputedStyle(display.lineDiv).textRendering == "optimizelegibility")
|
| 8522 |
-
{ display.lineDiv.style.textRendering = "auto" }
|
| 8523 |
}
|
| 8524 |
|
| 8525 |
// The default configuration options.
|
| 8526 |
-
CodeMirror.defaults = defaults
|
| 8527 |
// Functions to run when options are changed.
|
| 8528 |
-
CodeMirror.optionHandlers = optionHandlers
|
| 8529 |
|
| 8530 |
// Attach the necessary event handlers when initializing the editor
|
| 8531 |
function registerEventHandlers(cm) {
|
| 8532 |
-
var d = cm.display
|
| 8533 |
-
on(d.scroller, "mousedown", operation(cm, onMouseDown))
|
| 8534 |
// Older IE's will not fire a second mousedown for a double click
|
| 8535 |
if (ie && ie_version < 11)
|
| 8536 |
{ on(d.scroller, "dblclick", operation(cm, function (e) {
|
| 8537 |
if (signalDOMEvent(cm, e)) { return }
|
| 8538 |
-
var pos = posFromMouse(cm, e)
|
| 8539 |
if (!pos || clickInGutter(cm, e) || eventInWidget(cm.display, e)) { return }
|
| 8540 |
-
e_preventDefault(e)
|
| 8541 |
-
var word = cm.findWordAt(pos)
|
| 8542 |
-
extendSelection(cm.doc, word.anchor, word.head)
|
| 8543 |
-
})) }
|
| 8544 |
else
|
| 8545 |
-
{ on(d.scroller, "dblclick", function (e) { return signalDOMEvent(cm, e) || e_preventDefault(e); }) }
|
| 8546 |
// Some browsers fire contextmenu *after* opening the menu, at
|
| 8547 |
// which point we can't mess with it anymore. Context menu is
|
| 8548 |
// handled in onMouseDown for these browsers.
|
| 8549 |
-
if (!captureRightClick) { on(d.scroller, "contextmenu", function (e) { return onContextMenu(cm, e); }) }
|
| 8550 |
|
| 8551 |
// Used to suppress mouse event handling when a touch happens
|
| 8552 |
-
var touchFinished, prevTouch = {end: 0}
|
| 8553 |
function finishTouch() {
|
| 8554 |
if (d.activeTouch) {
|
| 8555 |
-
touchFinished = setTimeout(function () { return d.activeTouch = null; }, 1000)
|
| 8556 |
-
prevTouch = d.activeTouch
|
| 8557 |
-
prevTouch.end = +new Date
|
| 8558 |
}
|
| 8559 |
}
|
| 8560 |
function isMouseLikeTouchEvent(e) {
|
| 8561 |
if (e.touches.length != 1) { return false }
|
| 8562 |
-
var touch = e.touches[0]
|
| 8563 |
return touch.radiusX <= 1 && touch.radiusY <= 1
|
| 8564 |
}
|
| 8565 |
function farAway(touch, other) {
|
| 8566 |
if (other.left == null) { return true }
|
| 8567 |
-
var dx = other.left - touch.left, dy = other.top - touch.top
|
| 8568 |
return dx * dx + dy * dy > 20 * 20
|
| 8569 |
}
|
| 8570 |
on(d.scroller, "touchstart", function (e) {
|
| 8571 |
if (!signalDOMEvent(cm, e) && !isMouseLikeTouchEvent(e)) {
|
| 8572 |
-
d.input.ensurePolled()
|
| 8573 |
-
clearTimeout(touchFinished)
|
| 8574 |
-
var now = +new Date
|
| 8575 |
d.activeTouch = {start: now, moved: false,
|
| 8576 |
-
prev: now - prevTouch.end <= 300 ? prevTouch : null}
|
| 8577 |
if (e.touches.length == 1) {
|
| 8578 |
-
d.activeTouch.left = e.touches[0].pageX
|
| 8579 |
-
d.activeTouch.top = e.touches[0].pageY
|
| 8580 |
}
|
| 8581 |
}
|
| 8582 |
-
})
|
| 8583 |
on(d.scroller, "touchmove", function () {
|
| 8584 |
-
if (d.activeTouch) { d.activeTouch.moved = true }
|
| 8585 |
-
})
|
| 8586 |
on(d.scroller, "touchend", function (e) {
|
| 8587 |
-
var touch = d.activeTouch
|
| 8588 |
if (touch && !eventInWidget(d, e) && touch.left != null &&
|
| 8589 |
!touch.moved && new Date - touch.start < 300) {
|
| 8590 |
-
var pos = cm.coordsChar(d.activeTouch, "page"), range
|
| 8591 |
if (!touch.prev || farAway(touch, touch.prev)) // Single tap
|
| 8592 |
-
{ range = new Range(pos, pos) }
|
| 8593 |
else if (!touch.prev.prev || farAway(touch, touch.prev.prev)) // Double tap
|
| 8594 |
-
{ range = cm.findWordAt(pos) }
|
| 8595 |
else // Triple tap
|
| 8596 |
-
{ range = new Range(Pos(pos.line, 0), clipPos(cm.doc, Pos(pos.line + 1, 0))) }
|
| 8597 |
-
cm.setSelection(range.anchor, range.head)
|
| 8598 |
-
cm.focus()
|
| 8599 |
-
e_preventDefault(e)
|
| 8600 |
}
|
| 8601 |
-
finishTouch()
|
| 8602 |
-
})
|
| 8603 |
-
on(d.scroller, "touchcancel", finishTouch)
|
| 8604 |
|
| 8605 |
// Sync scrolling between fake scrollbars and real scrollable
|
| 8606 |
// area, ensure viewport is updated when scrolling.
|
| 8607 |
on(d.scroller, "scroll", function () {
|
| 8608 |
if (d.scroller.clientHeight) {
|
| 8609 |
-
setScrollTop(cm, d.scroller.scrollTop)
|
| 8610 |
-
setScrollLeft(cm, d.scroller.scrollLeft, true)
|
| 8611 |
-
signal(cm, "scroll", cm)
|
| 8612 |
}
|
| 8613 |
-
})
|
| 8614 |
|
| 8615 |
// Listen to wheel events in order to try and update the viewport on time.
|
| 8616 |
-
on(d.scroller, "mousewheel", function (e) { return onScrollWheel(cm, e); })
|
| 8617 |
-
on(d.scroller, "DOMMouseScroll", function (e) { return onScrollWheel(cm, e); })
|
| 8618 |
|
| 8619 |
// Prevent wrapper from ever scrolling
|
| 8620 |
-
on(d.wrapper, "scroll", function () { return d.wrapper.scrollTop = d.wrapper.scrollLeft = 0; })
|
| 8621 |
|
| 8622 |
d.dragFunctions = {
|
| 8623 |
-
enter: function (e) {if (!signalDOMEvent(cm, e)) { e_stop(e) }},
|
| 8624 |
-
over: function (e) {if (!signalDOMEvent(cm, e)) { onDragOver(cm, e); e_stop(e) }},
|
| 8625 |
start: function (e) { return onDragStart(cm, e); },
|
| 8626 |
drop: operation(cm, onDrop),
|
| 8627 |
-
leave: function (e) {if (!signalDOMEvent(cm, e)) { clearDragCursor(cm) }}
|
| 8628 |
-
}
|
| 8629 |
|
| 8630 |
-
var inp = d.input.getField()
|
| 8631 |
-
on(inp, "keyup", function (e) { return onKeyUp.call(cm, e); })
|
| 8632 |
-
on(inp, "keydown", operation(cm, onKeyDown))
|
| 8633 |
-
on(inp, "keypress", operation(cm, onKeyPress))
|
| 8634 |
-
on(inp, "focus", function (e) { return onFocus(cm, e); })
|
| 8635 |
-
on(inp, "blur", function (e) { return onBlur(cm, e); })
|
| 8636 |
}
|
| 8637 |
|
| 8638 |
-
var initHooks = []
|
| 8639 |
-
CodeMirror.defineInitHook = function (f) { return initHooks.push(f); }
|
| 8640 |
|
| 8641 |
// Indent the given line. The how parameter can be "smart",
|
| 8642 |
// "add"/null, "subtract", or "prev". When aggressive is false
|
|
@@ -8644,58 +8677,58 @@ webpackJsonp([2],{
|
|
| 8644 |
// lines are not indented, and places where the mode returns Pass
|
| 8645 |
// are left alone.
|
| 8646 |
function indentLine(cm, n, how, aggressive) {
|
| 8647 |
-
var doc = cm.doc, state
|
| 8648 |
-
if (how == null) { how = "add" }
|
| 8649 |
if (how == "smart") {
|
| 8650 |
// Fall back to "prev" when the mode doesn't have an indentation
|
| 8651 |
// method.
|
| 8652 |
-
if (!doc.mode.indent) { how = "prev" }
|
| 8653 |
-
else { state = getStateBefore(cm, n) }
|
| 8654 |
}
|
| 8655 |
|
| 8656 |
-
var tabSize = cm.options.tabSize
|
| 8657 |
-
var line = getLine(doc, n), curSpace = countColumn(line.text, null, tabSize)
|
| 8658 |
-
if (line.stateAfter) { line.stateAfter = null }
|
| 8659 |
-
var curSpaceString = line.text.match(/^\s*/)[0], indentation
|
| 8660 |
if (!aggressive && !/\S/.test(line.text)) {
|
| 8661 |
-
indentation = 0
|
| 8662 |
-
how = "not"
|
| 8663 |
} else if (how == "smart") {
|
| 8664 |
-
indentation = doc.mode.indent(state, line.text.slice(curSpaceString.length), line.text)
|
| 8665 |
if (indentation == Pass || indentation > 150) {
|
| 8666 |
if (!aggressive) { return }
|
| 8667 |
-
how = "prev"
|
| 8668 |
}
|
| 8669 |
}
|
| 8670 |
if (how == "prev") {
|
| 8671 |
-
if (n > doc.first) { indentation = countColumn(getLine(doc, n-1).text, null, tabSize) }
|
| 8672 |
-
else { indentation = 0 }
|
| 8673 |
} else if (how == "add") {
|
| 8674 |
-
indentation = curSpace + cm.options.indentUnit
|
| 8675 |
} else if (how == "subtract") {
|
| 8676 |
-
indentation = curSpace - cm.options.indentUnit
|
| 8677 |
} else if (typeof how == "number") {
|
| 8678 |
-
indentation = curSpace + how
|
| 8679 |
}
|
| 8680 |
-
indentation = Math.max(0, indentation)
|
| 8681 |
|
| 8682 |
-
var indentString = "", pos = 0
|
| 8683 |
if (cm.options.indentWithTabs)
|
| 8684 |
-
{ for (var i = Math.floor(indentation / tabSize); i; --i) {pos += tabSize; indentString += "\t"} }
|
| 8685 |
-
if (pos < indentation) { indentString += spaceStr(indentation - pos) }
|
| 8686 |
|
| 8687 |
if (indentString != curSpaceString) {
|
| 8688 |
-
replaceRange(doc, indentString, Pos(n, 0), Pos(n, curSpaceString.length), "+input")
|
| 8689 |
-
line.stateAfter = null
|
| 8690 |
return true
|
| 8691 |
} else {
|
| 8692 |
// Ensure that, if the cursor was in the whitespace at the start
|
| 8693 |
// of the line, it is moved to the end of that space.
|
| 8694 |
for (var i$1 = 0; i$1 < doc.sel.ranges.length; i$1++) {
|
| 8695 |
-
var range = doc.sel.ranges[i$1]
|
| 8696 |
if (range.head.line == n && range.head.ch < curSpaceString.length) {
|
| 8697 |
-
var pos$1 = Pos(n, curSpaceString.length)
|
| 8698 |
-
replaceOneSelection(doc, i$1, new Range(pos$1, pos$1))
|
| 8699 |
break
|
| 8700 |
}
|
| 8701 |
}
|
|
@@ -8705,66 +8738,66 @@ webpackJsonp([2],{
|
|
| 8705 |
// This will be set to a {lineWise: bool, text: [string]} object, so
|
| 8706 |
// that, when pasting, we know what kind of selections the copied
|
| 8707 |
// text was made out of.
|
| 8708 |
-
var lastCopied = null
|
| 8709 |
|
| 8710 |
function setLastCopied(newLastCopied) {
|
| 8711 |
-
lastCopied = newLastCopied
|
| 8712 |
}
|
| 8713 |
|
| 8714 |
function applyTextInput(cm, inserted, deleted, sel, origin) {
|
| 8715 |
-
var doc = cm.doc
|
| 8716 |
-
cm.display.shift = false
|
| 8717 |
-
if (!sel) { sel = doc.sel }
|
| 8718 |
|
| 8719 |
-
var paste = cm.state.pasteIncoming || origin == "paste"
|
| 8720 |
-
var textLines = splitLinesAuto(inserted), multiPaste = null
|
| 8721 |
// When pasing N lines into N selections, insert one line per selection
|
| 8722 |
if (paste && sel.ranges.length > 1) {
|
| 8723 |
if (lastCopied && lastCopied.text.join("\n") == inserted) {
|
| 8724 |
if (sel.ranges.length % lastCopied.text.length == 0) {
|
| 8725 |
-
multiPaste = []
|
| 8726 |
for (var i = 0; i < lastCopied.text.length; i++)
|
| 8727 |
-
{ multiPaste.push(doc.splitLines(lastCopied.text[i])) }
|
| 8728 |
}
|
| 8729 |
} else if (textLines.length == sel.ranges.length) {
|
| 8730 |
-
multiPaste = map(textLines, function (l) { return [l]; })
|
| 8731 |
}
|
| 8732 |
}
|
| 8733 |
|
| 8734 |
-
var updateInput
|
| 8735 |
// Normal behavior is to insert the new text into every selection
|
| 8736 |
for (var i$1 = sel.ranges.length - 1; i$1 >= 0; i$1--) {
|
| 8737 |
-
var range = sel.ranges[i$1]
|
| 8738 |
-
var from = range.from(), to = range.to()
|
| 8739 |
-
if (range.empty()) {
|
| 8740 |
if (deleted && deleted > 0) // Handle deletion
|
| 8741 |
-
{ from = Pos(from.line, from.ch - deleted) }
|
| 8742 |
else if (cm.state.overwrite && !paste) // Handle overwrite
|
| 8743 |
-
{ to = Pos(to.line, Math.min(getLine(doc, to.line).text.length, to.ch + lst(textLines).length)) }
|
| 8744 |
else if (lastCopied && lastCopied.lineWise && lastCopied.text.join("\n") == inserted)
|
| 8745 |
-
{ from = to = Pos(from.line, 0) }
|
| 8746 |
}
|
| 8747 |
-
updateInput = cm.curOp.updateInput
|
| 8748 |
var changeEvent = {from: from, to: to, text: multiPaste ? multiPaste[i$1 % multiPaste.length] : textLines,
|
| 8749 |
-
origin: origin || (paste ? "paste" : cm.state.cutIncoming ? "cut" : "+input")}
|
| 8750 |
-
makeChange(cm.doc, changeEvent)
|
| 8751 |
-
signalLater(cm, "inputRead", cm, changeEvent)
|
| 8752 |
}
|
| 8753 |
if (inserted && !paste)
|
| 8754 |
-
{ triggerElectric(cm, inserted) }
|
| 8755 |
|
| 8756 |
-
ensureCursorVisible(cm)
|
| 8757 |
-
cm.curOp.updateInput = updateInput
|
| 8758 |
-
cm.curOp.typing = true
|
| 8759 |
-
cm.state.pasteIncoming = cm.state.cutIncoming = false
|
| 8760 |
}
|
| 8761 |
|
| 8762 |
function handlePaste(e, cm) {
|
| 8763 |
-
var pasted = e.clipboardData && e.clipboardData.getData("Text")
|
| 8764 |
if (pasted) {
|
| 8765 |
-
e.preventDefault()
|
| 8766 |
if (!cm.isReadOnly() && !cm.options.disableInput)
|
| 8767 |
-
{ runInOp(cm, function () { return applyTextInput(cm, pasted, 0, null, "paste"); }) }
|
| 8768 |
return true
|
| 8769 |
}
|
| 8770 |
}
|
|
@@ -8772,56 +8805,56 @@ webpackJsonp([2],{
|
|
| 8772 |
function triggerElectric(cm, inserted) {
|
| 8773 |
// When an 'electric' character is inserted, immediately trigger a reindent
|
| 8774 |
if (!cm.options.electricChars || !cm.options.smartIndent) { return }
|
| 8775 |
-
var sel = cm.doc.sel
|
| 8776 |
|
| 8777 |
for (var i = sel.ranges.length - 1; i >= 0; i--) {
|
| 8778 |
-
var range = sel.ranges[i]
|
| 8779 |
-
if (range.head.ch > 100 || (i && sel.ranges[i - 1].head.line == range.head.line)) { continue }
|
| 8780 |
-
var mode = cm.getModeAt(range.head)
|
| 8781 |
-
var indented = false
|
| 8782 |
if (mode.electricChars) {
|
| 8783 |
for (var j = 0; j < mode.electricChars.length; j++)
|
| 8784 |
{ if (inserted.indexOf(mode.electricChars.charAt(j)) > -1) {
|
| 8785 |
-
indented = indentLine(cm, range.head.line, "smart")
|
| 8786 |
break
|
| 8787 |
} }
|
| 8788 |
} else if (mode.electricInput) {
|
| 8789 |
-
if (mode.electricInput.test(getLine(cm.doc, range.head.line).text.slice(0, range.head.ch)))
|
| 8790 |
-
{ indented = indentLine(cm, range.head.line, "smart") }
|
| 8791 |
}
|
| 8792 |
-
if (indented) { signalLater(cm, "electricInput", cm, range.head.line) }
|
| 8793 |
}
|
| 8794 |
}
|
| 8795 |
|
| 8796 |
function copyableRanges(cm) {
|
| 8797 |
-
var text = [], ranges = []
|
| 8798 |
for (var i = 0; i < cm.doc.sel.ranges.length; i++) {
|
| 8799 |
-
var line = cm.doc.sel.ranges[i].head.line
|
| 8800 |
-
var lineRange = {anchor: Pos(line, 0), head: Pos(line + 1, 0)}
|
| 8801 |
-
ranges.push(lineRange)
|
| 8802 |
-
text.push(cm.getRange(lineRange.anchor, lineRange.head))
|
| 8803 |
}
|
| 8804 |
return {text: text, ranges: ranges}
|
| 8805 |
}
|
| 8806 |
|
| 8807 |
function disableBrowserMagic(field, spellcheck) {
|
| 8808 |
-
field.setAttribute("autocorrect", "off")
|
| 8809 |
-
field.setAttribute("autocapitalize", "off")
|
| 8810 |
-
field.setAttribute("spellcheck", !!spellcheck)
|
| 8811 |
}
|
| 8812 |
|
| 8813 |
function hiddenTextarea() {
|
| 8814 |
-
var te = elt("textarea", null, null, "position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none")
|
| 8815 |
-
var div = elt("div", [te], null, "overflow: hidden; position: relative; width: 3px; height: 0px;")
|
| 8816 |
// The textarea is kept positioned near the cursor to prevent the
|
| 8817 |
// fact that it'll be scrolled into view on input from scrolling
|
| 8818 |
// our fake cursor out of view. On webkit, when wrap=off, paste is
|
| 8819 |
// very slow. So make the area wide instead.
|
| 8820 |
-
if (webkit) { te.style.width = "1000px" }
|
| 8821 |
-
else { te.setAttribute("wrap", "off") }
|
| 8822 |
// If border: 0; -- iOS fails to open keyboard (issue #1287)
|
| 8823 |
-
if (ios) { te.style.border = "1px solid black" }
|
| 8824 |
-
disableBrowserMagic(te)
|
| 8825 |
return div
|
| 8826 |
}
|
| 8827 |
|
|
@@ -8833,59 +8866,59 @@ webpackJsonp([2],{
|
|
| 8833 |
// CodeMirror.prototype, for backwards compatibility and
|
| 8834 |
// convenience.
|
| 8835 |
|
| 8836 |
-
|
| 8837 |
-
var optionHandlers = CodeMirror.optionHandlers
|
| 8838 |
|
| 8839 |
-
var helpers = CodeMirror.helpers = {}
|
| 8840 |
|
| 8841 |
CodeMirror.prototype = {
|
| 8842 |
constructor: CodeMirror,
|
| 8843 |
-
focus: function(){window.focus(); this.display.input.focus()},
|
| 8844 |
|
| 8845 |
setOption: function(option, value) {
|
| 8846 |
-
var options = this.options, old = options[option]
|
| 8847 |
if (options[option] == value && option != "mode") { return }
|
| 8848 |
-
options[option] = value
|
| 8849 |
if (optionHandlers.hasOwnProperty(option))
|
| 8850 |
-
{ operation(this, optionHandlers[option])(this, value, old) }
|
| 8851 |
-
signal(this, "optionChange", this, option)
|
| 8852 |
},
|
| 8853 |
|
| 8854 |
getOption: function(option) {return this.options[option]},
|
| 8855 |
getDoc: function() {return this.doc},
|
| 8856 |
|
| 8857 |
-
addKeyMap: function(map, bottom) {
|
| 8858 |
-
this.state.keyMaps[bottom ? "push" : "unshift"](getKeyMap(map))
|
| 8859 |
},
|
| 8860 |
-
removeKeyMap: function(map) {
|
| 8861 |
-
var maps = this.state.keyMaps
|
| 8862 |
for (var i = 0; i < maps.length; ++i)
|
| 8863 |
-
{ if (maps[i] == map || maps[i].name == map) {
|
| 8864 |
-
maps.splice(i, 1)
|
| 8865 |
return true
|
| 8866 |
} }
|
| 8867 |
},
|
| 8868 |
|
| 8869 |
addOverlay: methodOp(function(spec, options) {
|
| 8870 |
-
var mode = spec.token ? spec : CodeMirror.getMode(this.options, spec)
|
| 8871 |
if (mode.startState) { throw new Error("Overlays may not be stateful.") }
|
| 8872 |
insertSorted(this.state.overlays,
|
| 8873 |
{mode: mode, modeSpec: spec, opaque: options && options.opaque,
|
| 8874 |
priority: (options && options.priority) || 0},
|
| 8875 |
-
function (overlay) { return overlay.priority; })
|
| 8876 |
-
this.state.modeGen
|
| 8877 |
-
regChange(this)
|
| 8878 |
}),
|
| 8879 |
removeOverlay: methodOp(function(spec) {
|
| 8880 |
var this$1 = this;
|
| 8881 |
|
| 8882 |
-
var overlays = this.state.overlays
|
| 8883 |
for (var i = 0; i < overlays.length; ++i) {
|
| 8884 |
-
var cur = overlays[i].modeSpec
|
| 8885 |
if (cur == spec || typeof spec == "string" && cur.name == spec) {
|
| 8886 |
-
overlays.splice(i, 1)
|
| 8887 |
-
this$1.state.modeGen
|
| 8888 |
-
regChange(this$1)
|
| 8889 |
return
|
| 8890 |
}
|
| 8891 |
}
|
|
@@ -8893,30 +8926,30 @@ webpackJsonp([2],{
|
|
| 8893 |
|
| 8894 |
indentLine: methodOp(function(n, dir, aggressive) {
|
| 8895 |
if (typeof dir != "string" && typeof dir != "number") {
|
| 8896 |
-
if (dir == null) { dir = this.options.smartIndent ? "smart" : "prev" }
|
| 8897 |
-
else { dir = dir ? "add" : "subtract" }
|
| 8898 |
}
|
| 8899 |
-
if (isLine(this.doc, n)) { indentLine(this, n, dir, aggressive) }
|
| 8900 |
}),
|
| 8901 |
indentSelection: methodOp(function(how) {
|
| 8902 |
var this$1 = this;
|
| 8903 |
|
| 8904 |
-
var ranges = this.doc.sel.ranges, end = -1
|
| 8905 |
for (var i = 0; i < ranges.length; i++) {
|
| 8906 |
-
var range = ranges[i]
|
| 8907 |
-
if (!range.empty()) {
|
| 8908 |
-
var from = range.from(), to = range.to()
|
| 8909 |
-
var start = Math.max(end, from.line)
|
| 8910 |
-
end = Math.min(this$1.lastLine(), to.line - (to.ch ? 0 : 1)) + 1
|
| 8911 |
for (var j = start; j < end; ++j)
|
| 8912 |
-
{ indentLine(this$1, j, how) }
|
| 8913 |
-
var newRanges = this$1.doc.sel.ranges
|
| 8914 |
if (from.ch == 0 && ranges.length == newRanges.length && newRanges[i].from().ch > 0)
|
| 8915 |
-
{ replaceOneSelection(this$1.doc, i, new Range(from, newRanges[i].to()), sel_dontScroll) }
|
| 8916 |
-
} else if (range.head.line > end) {
|
| 8917 |
-
indentLine(this$1, range.head.line, how, true)
|
| 8918 |
-
end = range.head.line
|
| 8919 |
-
if (i == this$1.doc.sel.primIndex) { ensureCursorVisible(this$1) }
|
| 8920 |
}
|
| 8921 |
}
|
| 8922 |
}),
|
|
@@ -8932,23 +8965,23 @@ webpackJsonp([2],{
|
|
| 8932 |
},
|
| 8933 |
|
| 8934 |
getTokenTypeAt: function(pos) {
|
| 8935 |
-
pos = clipPos(this.doc, pos)
|
| 8936 |
-
var styles = getLineStyles(this, getLine(this.doc, pos.line))
|
| 8937 |
-
var before = 0, after = (styles.length - 1) / 2, ch = pos.ch
|
| 8938 |
-
var type
|
| 8939 |
-
if (ch == 0) { type = styles[2] }
|
| 8940 |
else { for (;;) {
|
| 8941 |
-
var mid = (before + after) >> 1
|
| 8942 |
-
if ((mid ? styles[mid * 2 - 1] : 0) >= ch) { after = mid }
|
| 8943 |
-
else if (styles[mid * 2 + 1] < ch) { before = mid + 1 }
|
| 8944 |
else { type = styles[mid * 2 + 2]; break }
|
| 8945 |
} }
|
| 8946 |
-
var cut = type ? type.indexOf("overlay ") : -1
|
| 8947 |
return cut < 0 ? type : cut == 0 ? null : type.slice(0, cut - 1)
|
| 8948 |
},
|
| 8949 |
|
| 8950 |
getModeAt: function(pos) {
|
| 8951 |
-
var mode = this.doc.mode
|
| 8952 |
if (!mode.innerMode) { return mode }
|
| 8953 |
return CodeMirror.innerMode(mode, this.getTokenAt(pos).state).mode
|
| 8954 |
},
|
|
@@ -8960,40 +8993,40 @@ webpackJsonp([2],{
|
|
| 8960 |
getHelpers: function(pos, type) {
|
| 8961 |
var this$1 = this;
|
| 8962 |
|
| 8963 |
-
var found = []
|
| 8964 |
if (!helpers.hasOwnProperty(type)) { return found }
|
| 8965 |
-
var help = helpers[type], mode = this.getModeAt(pos)
|
| 8966 |
if (typeof mode[type] == "string") {
|
| 8967 |
-
if (help[mode[type]]) { found.push(help[mode[type]]) }
|
| 8968 |
} else if (mode[type]) {
|
| 8969 |
for (var i = 0; i < mode[type].length; i++) {
|
| 8970 |
-
var val = help[mode[type][i]]
|
| 8971 |
-
if (val) { found.push(val) }
|
| 8972 |
}
|
| 8973 |
} else if (mode.helperType && help[mode.helperType]) {
|
| 8974 |
-
found.push(help[mode.helperType])
|
| 8975 |
} else if (help[mode.name]) {
|
| 8976 |
-
found.push(help[mode.name])
|
| 8977 |
}
|
| 8978 |
for (var i$1 = 0; i$1 < help._global.length; i$1++) {
|
| 8979 |
-
var cur = help._global[i$1]
|
| 8980 |
if (cur.pred(mode, this$1) && indexOf(found, cur.val) == -1)
|
| 8981 |
-
{ found.push(cur.val) }
|
| 8982 |
}
|
| 8983 |
return found
|
| 8984 |
},
|
| 8985 |
|
| 8986 |
getStateAfter: function(line, precise) {
|
| 8987 |
-
var doc = this.doc
|
| 8988 |
-
line = clipLine(doc, line == null ? doc.first + doc.size - 1: line)
|
| 8989 |
return getStateBefore(this, line + 1, precise)
|
| 8990 |
},
|
| 8991 |
|
| 8992 |
cursorCoords: function(start, mode) {
|
| 8993 |
-
var pos, range = this.doc.sel.primary()
|
| 8994 |
-
if (start == null) { pos = range.head }
|
| 8995 |
-
else if (typeof start == "object") { pos = clipPos(this.doc, start) }
|
| 8996 |
-
else { pos = start ? range.from() : range.to() }
|
| 8997 |
return cursorCoords(this, pos, mode || "page")
|
| 8998 |
},
|
| 8999 |
|
|
@@ -9002,23 +9035,23 @@ webpackJsonp([2],{
|
|
| 9002 |
},
|
| 9003 |
|
| 9004 |
coordsChar: function(coords, mode) {
|
| 9005 |
-
coords = fromCoordSystem(this, coords, mode || "page")
|
| 9006 |
return coordsChar(this, coords.left, coords.top)
|
| 9007 |
},
|
| 9008 |
|
| 9009 |
lineAtHeight: function(height, mode) {
|
| 9010 |
-
height = fromCoordSystem(this, {top: height, left: 0}, mode || "page").top
|
| 9011 |
return lineAtHeight(this.doc, height + this.display.viewOffset)
|
| 9012 |
},
|
| 9013 |
heightAtLine: function(line, mode, includeWidgets) {
|
| 9014 |
-
var end = false, lineObj
|
| 9015 |
if (typeof line == "number") {
|
| 9016 |
-
var last = this.doc.first + this.doc.size - 1
|
| 9017 |
-
if (line < this.doc.first) { line = this.doc.first }
|
| 9018 |
-
else if (line > last) { line = last; end = true }
|
| 9019 |
-
lineObj = getLine(this.doc, line)
|
| 9020 |
} else {
|
| 9021 |
-
lineObj = line
|
| 9022 |
}
|
| 9023 |
return intoCoordSystem(this, lineObj, {top: 0, left: 0}, mode || "page", includeWidgets || end).top +
|
| 9024 |
(end ? this.doc.height - heightAtLine(lineObj) : 0)
|
|
@@ -9030,38 +9063,38 @@ webpackJsonp([2],{
|
|
| 9030 |
getViewport: function() { return {from: this.display.viewFrom, to: this.display.viewTo}},
|
| 9031 |
|
| 9032 |
addWidget: function(pos, node, scroll, vert, horiz) {
|
| 9033 |
-
var display = this.display
|
| 9034 |
-
pos = cursorCoords(this, clipPos(this.doc, pos))
|
| 9035 |
-
var top = pos.bottom, left = pos.left
|
| 9036 |
-
node.style.position = "absolute"
|
| 9037 |
-
node.setAttribute("cm-ignore-events", "true")
|
| 9038 |
-
this.display.input.setUneditable(node)
|
| 9039 |
-
display.sizer.appendChild(node)
|
| 9040 |
if (vert == "over") {
|
| 9041 |
-
top = pos.top
|
| 9042 |
} else if (vert == "above" || vert == "near") {
|
| 9043 |
var vspace = Math.max(display.wrapper.clientHeight, this.doc.height),
|
| 9044 |
-
hspace = Math.max(display.sizer.clientWidth, display.lineSpace.clientWidth)
|
| 9045 |
// Default to positioning above (if specified and possible); otherwise default to positioning below
|
| 9046 |
if ((vert == 'above' || pos.bottom + node.offsetHeight > vspace) && pos.top > node.offsetHeight)
|
| 9047 |
-
{ top = pos.top - node.offsetHeight }
|
| 9048 |
else if (pos.bottom + node.offsetHeight <= vspace)
|
| 9049 |
-
{ top = pos.bottom }
|
| 9050 |
if (left + node.offsetWidth > hspace)
|
| 9051 |
-
{ left = hspace - node.offsetWidth }
|
| 9052 |
}
|
| 9053 |
-
node.style.top = top + "px"
|
| 9054 |
-
node.style.left = node.style.right = ""
|
| 9055 |
if (horiz == "right") {
|
| 9056 |
-
left = display.sizer.clientWidth - node.offsetWidth
|
| 9057 |
-
node.style.right = "0px"
|
| 9058 |
} else {
|
| 9059 |
-
if (horiz == "left") { left = 0 }
|
| 9060 |
-
else if (horiz == "middle") { left = (display.sizer.clientWidth - node.offsetWidth) / 2 }
|
| 9061 |
-
node.style.left = left + "px"
|
| 9062 |
}
|
| 9063 |
if (scroll)
|
| 9064 |
-
{ scrollIntoView(this, left, top, left + node.offsetWidth, top + node.offsetHeight) }
|
| 9065 |
},
|
| 9066 |
|
| 9067 |
triggerOnKeyDown: methodOp(onKeyDown),
|
|
@@ -9073,16 +9106,16 @@ webpackJsonp([2],{
|
|
| 9073 |
{ return commands[cmd].call(null, this) }
|
| 9074 |
},
|
| 9075 |
|
| 9076 |
-
triggerElectric: methodOp(function(text) { triggerElectric(this, text) }),
|
| 9077 |
|
| 9078 |
findPosH: function(from, amount, unit, visually) {
|
| 9079 |
var this$1 = this;
|
| 9080 |
|
| 9081 |
-
var dir = 1
|
| 9082 |
-
if (amount < 0) { dir = -1; amount = -amount }
|
| 9083 |
-
var cur = clipPos(this.doc, from)
|
| 9084 |
for (var i = 0; i < amount; ++i) {
|
| 9085 |
-
cur = findPosH(this$1.doc, cur, dir, unit, visually)
|
| 9086 |
if (cur.hitSide) { break }
|
| 9087 |
}
|
| 9088 |
return cur
|
|
@@ -9091,36 +9124,36 @@ webpackJsonp([2],{
|
|
| 9091 |
moveH: methodOp(function(dir, unit) {
|
| 9092 |
var this$1 = this;
|
| 9093 |
|
| 9094 |
-
this.extendSelectionsBy(function (range) {
|
| 9095 |
-
if (this$1.display.shift || this$1.doc.extend || range.empty())
|
| 9096 |
-
{ return findPosH(this$1.doc, range.head, dir, unit, this$1.options.rtlMoveVisually) }
|
| 9097 |
else
|
| 9098 |
-
{ return dir < 0 ? range.from() : range.to() }
|
| 9099 |
-
}, sel_move)
|
| 9100 |
}),
|
| 9101 |
|
| 9102 |
deleteH: methodOp(function(dir, unit) {
|
| 9103 |
-
var sel = this.doc.sel, doc = this.doc
|
| 9104 |
if (sel.somethingSelected())
|
| 9105 |
-
{ doc.replaceSelection("", null, "+delete") }
|
| 9106 |
else
|
| 9107 |
-
{ deleteNearSelection(this, function (range) {
|
| 9108 |
-
var other = findPosH(doc, range.head, dir, unit, false)
|
| 9109 |
-
return dir < 0 ? {from: other, to: range.head} : {from: range.head, to: other}
|
| 9110 |
-
}) }
|
| 9111 |
}),
|
| 9112 |
|
| 9113 |
findPosV: function(from, amount, unit, goalColumn) {
|
| 9114 |
var this$1 = this;
|
| 9115 |
|
| 9116 |
-
var dir = 1, x = goalColumn
|
| 9117 |
-
if (amount < 0) { dir = -1; amount = -amount }
|
| 9118 |
-
var cur = clipPos(this.doc, from)
|
| 9119 |
for (var i = 0; i < amount; ++i) {
|
| 9120 |
-
var coords = cursorCoords(this$1, cur, "div")
|
| 9121 |
-
if (x == null) { x = coords.left }
|
| 9122 |
-
else { coords.left = x }
|
| 9123 |
-
cur = findPosV(this$1, coords, dir, unit)
|
| 9124 |
if (cur.hitSide) { break }
|
| 9125 |
}
|
| 9126 |
return cur
|
|
@@ -9129,37 +9162,37 @@ webpackJsonp([2],{
|
|
| 9129 |
moveV: methodOp(function(dir, unit) {
|
| 9130 |
var this$1 = this;
|
| 9131 |
|
| 9132 |
-
var doc = this.doc, goals = []
|
| 9133 |
-
var collapse = !this.display.shift && !doc.extend && doc.sel.somethingSelected()
|
| 9134 |
-
doc.extendSelectionsBy(function (range) {
|
| 9135 |
if (collapse)
|
| 9136 |
-
{ return dir < 0 ? range.from() : range.to() }
|
| 9137 |
-
var headPos = cursorCoords(this$1, range.head, "div")
|
| 9138 |
-
if (range.goalColumn != null) { headPos.left = range.goalColumn }
|
| 9139 |
-
goals.push(headPos.left)
|
| 9140 |
-
var pos = findPosV(this$1, headPos, dir, unit)
|
| 9141 |
-
if (unit == "page" && range == doc.sel.primary())
|
| 9142 |
-
{ addToScrollPos(this$1, null, charCoords(this$1, pos, "div").top - headPos.top) }
|
| 9143 |
return pos
|
| 9144 |
-
}, sel_move)
|
| 9145 |
if (goals.length) { for (var i = 0; i < doc.sel.ranges.length; i++)
|
| 9146 |
-
{ doc.sel.ranges[i].goalColumn = goals[i] } }
|
| 9147 |
}),
|
| 9148 |
|
| 9149 |
// Find the word at the given position (as returned by coordsChar).
|
| 9150 |
findWordAt: function(pos) {
|
| 9151 |
-
var doc = this.doc, line = getLine(doc, pos.line).text
|
| 9152 |
-
var start = pos.ch, end = pos.ch
|
| 9153 |
if (line) {
|
| 9154 |
-
var helper = this.getHelper(pos, "wordChars")
|
| 9155 |
-
if ((pos.sticky == "before" || end == line.length) && start) { --start; } else { ++end }
|
| 9156 |
-
var startChar = line.charAt(start)
|
| 9157 |
var check = isWordChar(startChar, helper)
|
| 9158 |
? function (ch) { return isWordChar(ch, helper); }
|
| 9159 |
: /\s/.test(startChar) ? function (ch) { return /\s/.test(ch); }
|
| 9160 |
-
: function (ch) { return (!/\s/.test(ch) && !isWordChar(ch)); }
|
| 9161 |
-
while (start > 0 && check(line.charAt(start - 1))) { --start }
|
| 9162 |
-
while (end < line.length && check(line.charAt(end))) { ++end }
|
| 9163 |
}
|
| 9164 |
return new Range(Pos(pos.line, start), Pos(pos.line, end))
|
| 9165 |
},
|
|
@@ -9167,92 +9200,94 @@ webpackJsonp([2],{
|
|
| 9167 |
toggleOverwrite: function(value) {
|
| 9168 |
if (value != null && value == this.state.overwrite) { return }
|
| 9169 |
if (this.state.overwrite = !this.state.overwrite)
|
| 9170 |
-
{ addClass(this.display.cursorDiv, "CodeMirror-overwrite") }
|
| 9171 |
else
|
| 9172 |
-
{ rmClass(this.display.cursorDiv, "CodeMirror-overwrite") }
|
| 9173 |
|
| 9174 |
-
signal(this, "overwriteToggle", this, this.state.overwrite)
|
| 9175 |
},
|
| 9176 |
hasFocus: function() { return this.display.input.getField() == activeElt() },
|
| 9177 |
isReadOnly: function() { return !!(this.options.readOnly || this.doc.cantEdit) },
|
| 9178 |
|
| 9179 |
scrollTo: methodOp(function(x, y) {
|
| 9180 |
-
if (x != null || y != null) { resolveScrollToPos(this) }
|
| 9181 |
-
if (x != null) { this.curOp.scrollLeft = x }
|
| 9182 |
-
if (y != null) { this.curOp.scrollTop = y }
|
| 9183 |
}),
|
| 9184 |
getScrollInfo: function() {
|
| 9185 |
-
var scroller = this.display.scroller
|
| 9186 |
return {left: scroller.scrollLeft, top: scroller.scrollTop,
|
| 9187 |
height: scroller.scrollHeight - scrollGap(this) - this.display.barHeight,
|
| 9188 |
width: scroller.scrollWidth - scrollGap(this) - this.display.barWidth,
|
| 9189 |
clientHeight: displayHeight(this), clientWidth: displayWidth(this)}
|
| 9190 |
},
|
| 9191 |
|
| 9192 |
-
scrollIntoView: methodOp(function(range, margin) {
|
| 9193 |
-
if (range == null) {
|
| 9194 |
-
range = {from: this.doc.sel.primary().head, to: null}
|
| 9195 |
-
if (margin == null) { margin = this.options.cursorScrollMargin }
|
| 9196 |
-
} else if (typeof range == "number") {
|
| 9197 |
-
range = {from: Pos(range, 0), to: null}
|
| 9198 |
-
} else if (range.from == null) {
|
| 9199 |
-
range = {from: range, to: null}
|
| 9200 |
}
|
| 9201 |
-
if (!range.to) { range.to = range.from }
|
| 9202 |
-
range.margin = margin || 0
|
| 9203 |
|
| 9204 |
-
if (range.from.line != null) {
|
| 9205 |
-
resolveScrollToPos(this)
|
| 9206 |
-
this.curOp.scrollToPos = range
|
| 9207 |
} else {
|
| 9208 |
-
var sPos = calculateScrollPos(this,
|
| 9209 |
-
|
| 9210 |
-
|
| 9211 |
-
|
| 9212 |
-
|
|
|
|
|
|
|
| 9213 |
}
|
| 9214 |
}),
|
| 9215 |
|
| 9216 |
setSize: methodOp(function(width, height) {
|
| 9217 |
var this$1 = this;
|
| 9218 |
|
| 9219 |
-
var interpret = function (val) { return typeof val == "number" || /^\d+$/.test(String(val)) ? val + "px" : val; }
|
| 9220 |
-
if (width != null) { this.display.wrapper.style.width = interpret(width) }
|
| 9221 |
-
if (height != null) { this.display.wrapper.style.height = interpret(height) }
|
| 9222 |
-
if (this.options.lineWrapping) { clearLineMeasurementCache(this) }
|
| 9223 |
-
var lineNo = this.display.viewFrom
|
| 9224 |
-
this.doc.iter(lineNo, this.display.viewTo, function (line) {
|
| 9225 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; i++)
|
| 9226 |
-
{ if (line.widgets[i].noHScroll) { regLineChange(this$1, lineNo, "widget"); break } } }
|
| 9227 |
-
++lineNo
|
| 9228 |
-
})
|
| 9229 |
-
this.curOp.forceUpdate = true
|
| 9230 |
-
signal(this, "refresh", this)
|
| 9231 |
}),
|
| 9232 |
|
| 9233 |
operation: function(f){return runInOp(this, f)},
|
| 9234 |
|
| 9235 |
refresh: methodOp(function() {
|
| 9236 |
-
var oldHeight = this.display.cachedTextHeight
|
| 9237 |
-
regChange(this)
|
| 9238 |
-
this.curOp.forceUpdate = true
|
| 9239 |
-
clearCaches(this)
|
| 9240 |
-
this.scrollTo(this.doc.scrollLeft, this.doc.scrollTop)
|
| 9241 |
-
updateGutterSpace(this)
|
| 9242 |
if (oldHeight == null || Math.abs(oldHeight - textHeight(this.display)) > .5)
|
| 9243 |
-
{ estimateLineHeights(this) }
|
| 9244 |
-
signal(this, "refresh", this)
|
| 9245 |
}),
|
| 9246 |
|
| 9247 |
swapDoc: methodOp(function(doc) {
|
| 9248 |
-
var old = this.doc
|
| 9249 |
-
old.cm = null
|
| 9250 |
-
attachDoc(this, doc)
|
| 9251 |
-
clearCaches(this)
|
| 9252 |
-
this.display.input.reset()
|
| 9253 |
-
this.scrollTo(doc.scrollLeft, doc.scrollTop)
|
| 9254 |
-
this.curOp.forceScroll = true
|
| 9255 |
-
signalLater(this, "swapDoc", this, old)
|
| 9256 |
return old
|
| 9257 |
}),
|
| 9258 |
|
|
@@ -9260,18 +9295,18 @@ webpackJsonp([2],{
|
|
| 9260 |
getWrapperElement: function(){return this.display.wrapper},
|
| 9261 |
getScrollerElement: function(){return this.display.scroller},
|
| 9262 |
getGutterElement: function(){return this.display.gutters}
|
| 9263 |
-
}
|
| 9264 |
-
eventMixin(CodeMirror)
|
| 9265 |
|
| 9266 |
CodeMirror.registerHelper = function(type, name, value) {
|
| 9267 |
-
if (!helpers.hasOwnProperty(type)) { helpers[type] = CodeMirror[type] = {_global: []} }
|
| 9268 |
-
helpers[type][name] = value
|
| 9269 |
-
}
|
| 9270 |
CodeMirror.registerGlobalHelper = function(type, name, predicate, value) {
|
| 9271 |
-
CodeMirror.registerHelper(type, name, value)
|
| 9272 |
-
helpers[type]._global.push({pred: predicate, val: value})
|
| 9273 |
-
}
|
| 9274 |
-
}
|
| 9275 |
|
| 9276 |
// Used for horizontal relative motion. Dir is -1 or 1 (left or
|
| 9277 |
// right), unit can be "char", "column" (like char, but doesn't
|
|
@@ -9283,59 +9318,59 @@ webpackJsonp([2],{
|
|
| 9283 |
// position. The resulting position will have a hitSide=true
|
| 9284 |
// property if it reached the end of the document.
|
| 9285 |
function findPosH(doc, pos, dir, unit, visually) {
|
| 9286 |
-
var oldPos = pos
|
| 9287 |
-
var origDir = dir
|
| 9288 |
-
var lineObj = getLine(doc, pos.line)
|
| 9289 |
function findNextLine() {
|
| 9290 |
-
var l = pos.line + dir
|
| 9291 |
if (l < doc.first || l >= doc.first + doc.size) { return false }
|
| 9292 |
-
pos = new Pos(l, pos.ch, pos.sticky)
|
| 9293 |
return lineObj = getLine(doc, l)
|
| 9294 |
}
|
| 9295 |
function moveOnce(boundToLine) {
|
| 9296 |
-
var next
|
| 9297 |
if (visually) {
|
| 9298 |
-
next = moveVisually(doc.cm, lineObj, pos, dir)
|
| 9299 |
} else {
|
| 9300 |
-
next = moveLogically(lineObj, pos, dir)
|
| 9301 |
}
|
| 9302 |
if (next == null) {
|
| 9303 |
if (!boundToLine && findNextLine())
|
| 9304 |
-
{ pos = endOfLine(visually, doc.cm, lineObj, pos.line, dir) }
|
| 9305 |
else
|
| 9306 |
{ return false }
|
| 9307 |
} else {
|
| 9308 |
-
pos = next
|
| 9309 |
}
|
| 9310 |
return true
|
| 9311 |
}
|
| 9312 |
|
| 9313 |
if (unit == "char") {
|
| 9314 |
-
moveOnce()
|
| 9315 |
} else if (unit == "column") {
|
| 9316 |
-
moveOnce(true)
|
| 9317 |
} else if (unit == "word" || unit == "group") {
|
| 9318 |
-
var sawType = null, group = unit == "group"
|
| 9319 |
-
var helper = doc.cm && doc.cm.getHelper(pos, "wordChars")
|
| 9320 |
for (var first = true;; first = false) {
|
| 9321 |
if (dir < 0 && !moveOnce(!first)) { break }
|
| 9322 |
-
var cur = lineObj.text.charAt(pos.ch) || "\n"
|
| 9323 |
var type = isWordChar(cur, helper) ? "w"
|
| 9324 |
: group && cur == "\n" ? "n"
|
| 9325 |
: !group || /\s/.test(cur) ? null
|
| 9326 |
-
: "p"
|
| 9327 |
-
if (group && !first && !type) { type = "s" }
|
| 9328 |
if (sawType && sawType != type) {
|
| 9329 |
-
if (dir < 0) {dir = 1; moveOnce(); pos.sticky = "after"}
|
| 9330 |
break
|
| 9331 |
}
|
| 9332 |
|
| 9333 |
-
if (type) { sawType = type }
|
| 9334 |
if (dir > 0 && !moveOnce(!first)) { break }
|
| 9335 |
}
|
| 9336 |
}
|
| 9337 |
-
var result = skipAtomic(doc, pos, oldPos, origDir, true)
|
| 9338 |
-
if (equalCursorPos(oldPos, result)) { result.hitSide = true }
|
| 9339 |
return result
|
| 9340 |
}
|
| 9341 |
|
|
@@ -9343,21 +9378,21 @@ webpackJsonp([2],{
|
|
| 9343 |
// "page" or "line". The resulting position will have a hitSide=true
|
| 9344 |
// property if it reached the end of the document.
|
| 9345 |
function findPosV(cm, pos, dir, unit) {
|
| 9346 |
-
var doc = cm.doc, x = pos.left, y
|
| 9347 |
if (unit == "page") {
|
| 9348 |
-
var pageSize = Math.min(cm.display.wrapper.clientHeight, window.innerHeight || document.documentElement.clientHeight)
|
| 9349 |
-
var moveAmount = Math.max(pageSize - .5 * textHeight(cm.display), 3)
|
| 9350 |
-
y = (dir > 0 ? pos.bottom : pos.top) + dir * moveAmount
|
| 9351 |
|
| 9352 |
} else if (unit == "line") {
|
| 9353 |
-
y = dir > 0 ? pos.bottom + 3 : pos.top - 3
|
| 9354 |
}
|
| 9355 |
-
var target
|
| 9356 |
for (;;) {
|
| 9357 |
-
target = coordsChar(cm, x, y)
|
| 9358 |
if (!target.outside) { break }
|
| 9359 |
if (dir < 0 ? y <= 0 : y >= doc.height) { target.hitSide = true; break }
|
| 9360 |
-
y += dir * 5
|
| 9361 |
}
|
| 9362 |
return target
|
| 9363 |
}
|
|
@@ -9365,399 +9400,438 @@ webpackJsonp([2],{
|
|
| 9365 |
// CONTENTEDITABLE INPUT STYLE
|
| 9366 |
|
| 9367 |
var ContentEditableInput = function(cm) {
|
| 9368 |
-
this.cm = cm
|
| 9369 |
-
this.lastAnchorNode = this.lastAnchorOffset = this.lastFocusNode = this.lastFocusOffset = null
|
| 9370 |
-
this.polling = new Delayed()
|
| 9371 |
-
this.composing = null
|
| 9372 |
-
this.gracePeriod = false
|
| 9373 |
-
this.readDOMTimeout = null
|
| 9374 |
};
|
| 9375 |
|
| 9376 |
ContentEditableInput.prototype.init = function (display) {
|
| 9377 |
var this$1 = this;
|
| 9378 |
|
| 9379 |
-
var input = this, cm = input.cm
|
| 9380 |
-
var div = input.div = display.lineDiv
|
| 9381 |
-
disableBrowserMagic(div, cm.options.spellcheck)
|
| 9382 |
|
| 9383 |
on(div, "paste", function (e) {
|
| 9384 |
if (signalDOMEvent(cm, e) || handlePaste(e, cm)) { return }
|
| 9385 |
// IE doesn't fire input events, so we schedule a read for the pasted content in this way
|
| 9386 |
-
if (ie_version <= 11) { setTimeout(operation(cm, function () {
|
| 9387 |
-
|
| 9388 |
-
}), 20) }
|
| 9389 |
-
})
|
| 9390 |
|
| 9391 |
on(div, "compositionstart", function (e) {
|
| 9392 |
-
this$1.composing = {data: e.data, done: false}
|
| 9393 |
-
})
|
| 9394 |
on(div, "compositionupdate", function (e) {
|
| 9395 |
-
if (!this$1.composing) { this$1.composing = {data: e.data, done: false} }
|
| 9396 |
-
})
|
| 9397 |
on(div, "compositionend", function (e) {
|
| 9398 |
if (this$1.composing) {
|
| 9399 |
-
if (e.data != this$1.composing.data) { this$1.readFromDOMSoon() }
|
| 9400 |
-
this$1.composing.done = true
|
| 9401 |
}
|
| 9402 |
-
})
|
| 9403 |
|
| 9404 |
-
on(div, "touchstart", function () { return input.forceCompositionEnd(); })
|
| 9405 |
|
| 9406 |
on(div, "input", function () {
|
| 9407 |
-
if (!this$1.composing) { this$1.readFromDOMSoon() }
|
| 9408 |
-
})
|
| 9409 |
|
| 9410 |
function onCopyCut(e) {
|
| 9411 |
if (signalDOMEvent(cm, e)) { return }
|
| 9412 |
if (cm.somethingSelected()) {
|
| 9413 |
-
setLastCopied({lineWise: false, text: cm.getSelections()})
|
| 9414 |
-
if (e.type == "cut") { cm.replaceSelection("", null, "cut") }
|
| 9415 |
} else if (!cm.options.lineWiseCopyCut) {
|
| 9416 |
return
|
| 9417 |
} else {
|
| 9418 |
-
var ranges = copyableRanges(cm)
|
| 9419 |
-
setLastCopied({lineWise: true, text: ranges.text})
|
| 9420 |
if (e.type == "cut") {
|
| 9421 |
cm.operation(function () {
|
| 9422 |
-
cm.setSelections(ranges.ranges, 0, sel_dontScroll)
|
| 9423 |
-
cm.replaceSelection("", null, "cut")
|
| 9424 |
-
})
|
| 9425 |
}
|
| 9426 |
}
|
| 9427 |
if (e.clipboardData) {
|
| 9428 |
-
e.clipboardData.clearData()
|
| 9429 |
-
var content = lastCopied.text.join("\n")
|
| 9430 |
// iOS exposes the clipboard API, but seems to discard content inserted into it
|
| 9431 |
-
e.clipboardData.setData("Text", content)
|
| 9432 |
if (e.clipboardData.getData("Text") == content) {
|
| 9433 |
-
e.preventDefault()
|
| 9434 |
return
|
| 9435 |
}
|
| 9436 |
}
|
| 9437 |
// Old-fashioned briefly-focus-a-textarea hack
|
| 9438 |
-
var kludge = hiddenTextarea(), te = kludge.firstChild
|
| 9439 |
-
cm.display.lineSpace.insertBefore(kludge, cm.display.lineSpace.firstChild)
|
| 9440 |
-
te.value = lastCopied.text.join("\n")
|
| 9441 |
-
var hadFocus = document.activeElement
|
| 9442 |
-
selectInput(te)
|
| 9443 |
setTimeout(function () {
|
| 9444 |
-
cm.display.lineSpace.removeChild(kludge)
|
| 9445 |
-
hadFocus.focus()
|
| 9446 |
-
if (hadFocus == div) { input.showPrimarySelection() }
|
| 9447 |
-
}, 50)
|
| 9448 |
}
|
| 9449 |
-
on(div, "copy", onCopyCut)
|
| 9450 |
-
on(div, "cut", onCopyCut)
|
| 9451 |
};
|
| 9452 |
|
| 9453 |
ContentEditableInput.prototype.prepareSelection = function () {
|
| 9454 |
-
var result = prepareSelection(this.cm, false)
|
| 9455 |
-
result.focus = this.cm.state.focused
|
| 9456 |
return result
|
| 9457 |
};
|
| 9458 |
|
| 9459 |
ContentEditableInput.prototype.showSelection = function (info, takeFocus) {
|
| 9460 |
if (!info || !this.cm.display.view.length) { return }
|
| 9461 |
-
if (info.focus || takeFocus) { this.showPrimarySelection() }
|
| 9462 |
-
this.showMultipleSelections(info)
|
| 9463 |
};
|
| 9464 |
|
| 9465 |
ContentEditableInput.prototype.showPrimarySelection = function () {
|
| 9466 |
-
var sel = window.getSelection(), prim = this.cm.doc.sel.primary()
|
| 9467 |
-
var curAnchor = domToPos(this.cm, sel.anchorNode, sel.anchorOffset)
|
| 9468 |
-
var curFocus = domToPos(this.cm, sel.focusNode, sel.focusOffset)
|
| 9469 |
if (curAnchor && !curAnchor.bad && curFocus && !curFocus.bad &&
|
| 9470 |
cmp(minPos(curAnchor, curFocus), prim.from()) == 0 &&
|
| 9471 |
cmp(maxPos(curAnchor, curFocus), prim.to()) == 0)
|
| 9472 |
{ return }
|
| 9473 |
|
| 9474 |
-
var start = posToDOM(this.cm, prim.from())
|
| 9475 |
-
var end = posToDOM(this.cm, prim.to())
|
| 9476 |
-
if (!start && !end) {
|
|
|
|
|
|
|
|
|
|
| 9477 |
|
| 9478 |
-
var view = this.cm.display.view
|
| 9479 |
-
var old = sel.rangeCount && sel.getRangeAt(0)
|
| 9480 |
if (!start) {
|
| 9481 |
-
start = {node: view[0].measure.map[2], offset: 0}
|
| 9482 |
} else if (!end) { // FIXME dangerously hacky
|
| 9483 |
-
var measure = view[view.length - 1].measure
|
| 9484 |
-
var map = measure.maps ? measure.maps[measure.maps.length - 1] : measure.map
|
| 9485 |
-
end = {node: map[map.length - 1], offset: map[map.length - 2] - map[map.length - 3]}
|
| 9486 |
}
|
| 9487 |
|
| 9488 |
-
var rng
|
| 9489 |
-
try { rng = range(start.node, start.offset, end.offset, end.node) }
|
| 9490 |
catch(e) {} // Our model of the DOM might be outdated, in which case the range we try to set can be impossible
|
| 9491 |
if (rng) {
|
| 9492 |
if (!gecko && this.cm.state.focused) {
|
| 9493 |
-
sel.collapse(start.node, start.offset)
|
| 9494 |
if (!rng.collapsed) {
|
| 9495 |
-
sel.removeAllRanges()
|
| 9496 |
-
sel.addRange(rng)
|
| 9497 |
}
|
| 9498 |
} else {
|
| 9499 |
-
sel.removeAllRanges()
|
| 9500 |
-
sel.addRange(rng)
|
| 9501 |
}
|
| 9502 |
-
if (old && sel.anchorNode == null) { sel.addRange(old) }
|
| 9503 |
-
else if (gecko) { this.startGracePeriod() }
|
| 9504 |
}
|
| 9505 |
-
this.rememberSelection()
|
| 9506 |
};
|
| 9507 |
|
| 9508 |
ContentEditableInput.prototype.startGracePeriod = function () {
|
| 9509 |
var this$1 = this;
|
| 9510 |
|
| 9511 |
-
clearTimeout(this.gracePeriod)
|
| 9512 |
this.gracePeriod = setTimeout(function () {
|
| 9513 |
-
this$1.gracePeriod = false
|
| 9514 |
if (this$1.selectionChanged())
|
| 9515 |
-
{ this$1.cm.operation(function () { return this$1.cm.curOp.selectionChanged = true; }) }
|
| 9516 |
-
}, 20)
|
| 9517 |
};
|
| 9518 |
|
| 9519 |
ContentEditableInput.prototype.showMultipleSelections = function (info) {
|
| 9520 |
-
removeChildrenAndAdd(this.cm.display.cursorDiv, info.cursors)
|
| 9521 |
-
removeChildrenAndAdd(this.cm.display.selectionDiv, info.selection)
|
| 9522 |
};
|
| 9523 |
|
| 9524 |
ContentEditableInput.prototype.rememberSelection = function () {
|
| 9525 |
-
var sel = window.getSelection()
|
| 9526 |
-
this.lastAnchorNode = sel.anchorNode; this.lastAnchorOffset = sel.anchorOffset
|
| 9527 |
-
this.lastFocusNode = sel.focusNode; this.lastFocusOffset = sel.focusOffset
|
| 9528 |
};
|
| 9529 |
|
| 9530 |
ContentEditableInput.prototype.selectionInEditor = function () {
|
| 9531 |
-
var sel = window.getSelection()
|
| 9532 |
if (!sel.rangeCount) { return false }
|
| 9533 |
-
var node = sel.getRangeAt(0).commonAncestorContainer
|
| 9534 |
return contains(this.div, node)
|
| 9535 |
};
|
| 9536 |
|
| 9537 |
ContentEditableInput.prototype.focus = function () {
|
| 9538 |
if (this.cm.options.readOnly != "nocursor") {
|
| 9539 |
if (!this.selectionInEditor())
|
| 9540 |
-
{ this.showSelection(this.prepareSelection(), true) }
|
| 9541 |
-
this.div.focus()
|
| 9542 |
}
|
| 9543 |
};
|
| 9544 |
-
ContentEditableInput.prototype.blur = function () { this.div.blur() };
|
| 9545 |
ContentEditableInput.prototype.getField = function () { return this.div };
|
| 9546 |
|
| 9547 |
ContentEditableInput.prototype.supportsTouch = function () { return true };
|
| 9548 |
|
| 9549 |
ContentEditableInput.prototype.receivedFocus = function () {
|
| 9550 |
-
var input = this
|
| 9551 |
if (this.selectionInEditor())
|
| 9552 |
-
{ this.pollSelection() }
|
| 9553 |
else
|
| 9554 |
-
{ runInOp(this.cm, function () { return input.cm.curOp.selectionChanged = true; }) }
|
| 9555 |
|
| 9556 |
function poll() {
|
| 9557 |
if (input.cm.state.focused) {
|
| 9558 |
-
input.pollSelection()
|
| 9559 |
-
input.polling.set(input.cm.options.pollInterval, poll)
|
| 9560 |
}
|
| 9561 |
}
|
| 9562 |
-
this.polling.set(this.cm.options.pollInterval, poll)
|
| 9563 |
};
|
| 9564 |
|
| 9565 |
ContentEditableInput.prototype.selectionChanged = function () {
|
| 9566 |
-
var sel = window.getSelection()
|
| 9567 |
return sel.anchorNode != this.lastAnchorNode || sel.anchorOffset != this.lastAnchorOffset ||
|
| 9568 |
sel.focusNode != this.lastFocusNode || sel.focusOffset != this.lastFocusOffset
|
| 9569 |
};
|
| 9570 |
|
| 9571 |
ContentEditableInput.prototype.pollSelection = function () {
|
| 9572 |
-
if (
|
| 9573 |
-
|
| 9574 |
-
|
| 9575 |
-
|
| 9576 |
-
|
| 9577 |
-
|
| 9578 |
-
|
| 9579 |
-
|
| 9580 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9581 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9582 |
};
|
| 9583 |
|
| 9584 |
ContentEditableInput.prototype.pollContent = function () {
|
| 9585 |
if (this.readDOMTimeout != null) {
|
| 9586 |
-
clearTimeout(this.readDOMTimeout)
|
| 9587 |
-
this.readDOMTimeout = null
|
| 9588 |
}
|
| 9589 |
|
| 9590 |
-
var cm = this.cm, display = cm.display, sel = cm.doc.sel.primary()
|
| 9591 |
-
var from = sel.from(), to = sel.to()
|
| 9592 |
if (from.ch == 0 && from.line > cm.firstLine())
|
| 9593 |
-
{ from = Pos(from.line - 1, getLine(cm.doc, from.line - 1).length) }
|
| 9594 |
if (to.ch == getLine(cm.doc, to.line).text.length && to.line < cm.lastLine())
|
| 9595 |
-
{ to = Pos(to.line + 1, 0) }
|
| 9596 |
if (from.line < display.viewFrom || to.line > display.viewTo - 1) { return false }
|
| 9597 |
|
| 9598 |
-
var fromIndex, fromLine, fromNode
|
| 9599 |
if (from.line == display.viewFrom || (fromIndex = findViewIndex(cm, from.line)) == 0) {
|
| 9600 |
-
fromLine = lineNo(display.view[0].line)
|
| 9601 |
-
fromNode = display.view[0].node
|
| 9602 |
} else {
|
| 9603 |
-
fromLine = lineNo(display.view[fromIndex].line)
|
| 9604 |
-
fromNode = display.view[fromIndex - 1].node.nextSibling
|
| 9605 |
}
|
| 9606 |
-
var toIndex = findViewIndex(cm, to.line)
|
| 9607 |
-
var toLine, toNode
|
| 9608 |
if (toIndex == display.view.length - 1) {
|
| 9609 |
-
toLine = display.viewTo - 1
|
| 9610 |
-
toNode = display.lineDiv.lastChild
|
| 9611 |
} else {
|
| 9612 |
-
toLine = lineNo(display.view[toIndex + 1].line) - 1
|
| 9613 |
-
toNode = display.view[toIndex + 1].node.previousSibling
|
| 9614 |
}
|
| 9615 |
|
| 9616 |
if (!fromNode) { return false }
|
| 9617 |
-
var newText = cm.doc.splitLines(domTextBetween(cm, fromNode, toNode, fromLine, toLine))
|
| 9618 |
-
var oldText = getBetween(cm.doc, Pos(fromLine, 0), Pos(toLine, getLine(cm.doc, toLine).text.length))
|
| 9619 |
while (newText.length > 1 && oldText.length > 1) {
|
| 9620 |
-
if (lst(newText) == lst(oldText)) { newText.pop(); oldText.pop(); toLine
|
| 9621 |
-
else if (newText[0] == oldText[0]) { newText.shift(); oldText.shift(); fromLine
|
| 9622 |
else { break }
|
| 9623 |
}
|
| 9624 |
|
| 9625 |
-
var cutFront = 0, cutEnd = 0
|
| 9626 |
-
var newTop = newText[0], oldTop = oldText[0], maxCutFront = Math.min(newTop.length, oldTop.length)
|
| 9627 |
while (cutFront < maxCutFront && newTop.charCodeAt(cutFront) == oldTop.charCodeAt(cutFront))
|
| 9628 |
-
{ ++cutFront }
|
| 9629 |
-
var newBot = lst(newText), oldBot = lst(oldText)
|
| 9630 |
var maxCutEnd = Math.min(newBot.length - (newText.length == 1 ? cutFront : 0),
|
| 9631 |
-
oldBot.length - (oldText.length == 1 ? cutFront : 0))
|
| 9632 |
while (cutEnd < maxCutEnd &&
|
| 9633 |
newBot.charCodeAt(newBot.length - cutEnd - 1) == oldBot.charCodeAt(oldBot.length - cutEnd - 1))
|
| 9634 |
-
{ ++cutEnd }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9635 |
|
| 9636 |
-
newText[newText.length - 1] = newBot.slice(0, newBot.length - cutEnd).replace(/^\u200b+/, "")
|
| 9637 |
-
newText[0] = newText[0].slice(cutFront).replace(/\u200b+$/, "")
|
| 9638 |
|
| 9639 |
-
var chFrom = Pos(fromLine, cutFront)
|
| 9640 |
-
var chTo = Pos(toLine, oldText.length ? lst(oldText).length - cutEnd : 0)
|
| 9641 |
if (newText.length > 1 || newText[0] || cmp(chFrom, chTo)) {
|
| 9642 |
-
replaceRange(cm.doc, newText, chFrom, chTo, "+input")
|
| 9643 |
return true
|
| 9644 |
}
|
| 9645 |
};
|
| 9646 |
|
| 9647 |
ContentEditableInput.prototype.ensurePolled = function () {
|
| 9648 |
-
this.forceCompositionEnd()
|
| 9649 |
};
|
| 9650 |
ContentEditableInput.prototype.reset = function () {
|
| 9651 |
-
this.forceCompositionEnd()
|
| 9652 |
};
|
| 9653 |
ContentEditableInput.prototype.forceCompositionEnd = function () {
|
| 9654 |
if (!this.composing) { return }
|
| 9655 |
-
clearTimeout(this.readDOMTimeout)
|
| 9656 |
-
this.composing = null
|
| 9657 |
-
|
| 9658 |
-
this.div.blur()
|
| 9659 |
-
this.div.focus()
|
| 9660 |
};
|
| 9661 |
ContentEditableInput.prototype.readFromDOMSoon = function () {
|
| 9662 |
var this$1 = this;
|
| 9663 |
|
| 9664 |
if (this.readDOMTimeout != null) { return }
|
| 9665 |
this.readDOMTimeout = setTimeout(function () {
|
| 9666 |
-
this$1.readDOMTimeout = null
|
| 9667 |
if (this$1.composing) {
|
| 9668 |
-
if (this$1.composing.done) { this$1.composing = null }
|
| 9669 |
else { return }
|
| 9670 |
}
|
| 9671 |
-
|
| 9672 |
-
|
| 9673 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9674 |
};
|
| 9675 |
|
| 9676 |
ContentEditableInput.prototype.setUneditable = function (node) {
|
| 9677 |
-
node.contentEditable = "false"
|
| 9678 |
};
|
| 9679 |
|
| 9680 |
ContentEditableInput.prototype.onKeyPress = function (e) {
|
| 9681 |
if (e.charCode == 0) { return }
|
| 9682 |
-
e.preventDefault()
|
| 9683 |
if (!this.cm.isReadOnly())
|
| 9684 |
-
{ operation(this.cm, applyTextInput)(this.cm, String.fromCharCode(e.charCode == null ? e.keyCode : e.charCode), 0) }
|
| 9685 |
};
|
| 9686 |
|
| 9687 |
ContentEditableInput.prototype.readOnlyChanged = function (val) {
|
| 9688 |
-
this.div.contentEditable = String(val != "nocursor")
|
| 9689 |
};
|
| 9690 |
|
| 9691 |
ContentEditableInput.prototype.onContextMenu = function () {};
|
| 9692 |
ContentEditableInput.prototype.resetPosition = function () {};
|
| 9693 |
|
| 9694 |
-
ContentEditableInput.prototype.needsContentAttribute = true
|
| 9695 |
|
| 9696 |
function posToDOM(cm, pos) {
|
| 9697 |
-
var view = findViewForLine(cm, pos.line)
|
| 9698 |
if (!view || view.hidden) { return null }
|
| 9699 |
-
var line = getLine(cm.doc, pos.line)
|
| 9700 |
-
var info = mapFromLineView(view, line, pos.line)
|
| 9701 |
|
| 9702 |
-
var order = getOrder(line), side = "left"
|
| 9703 |
if (order) {
|
| 9704 |
-
var partPos = getBidiPartAt(order, pos.ch)
|
| 9705 |
-
side = partPos % 2 ? "right" : "left"
|
| 9706 |
}
|
| 9707 |
-
var result = nodeAndOffsetInLineMap(info.map, pos.ch, side)
|
| 9708 |
-
result.offset = result.collapse == "right" ? result.end : result.start
|
| 9709 |
return result
|
| 9710 |
}
|
| 9711 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9712 |
function badPos(pos, bad) { if (bad) { pos.bad = true; } return pos }
|
| 9713 |
|
| 9714 |
function domTextBetween(cm, from, to, fromLine, toLine) {
|
| 9715 |
-
var text = "", closing = false, lineSep = cm.doc.lineSeparator()
|
| 9716 |
function recognizeMarker(id) { return function (marker) { return marker.id == id; } }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9717 |
function walk(node) {
|
| 9718 |
if (node.nodeType == 1) {
|
| 9719 |
-
var cmText = node.getAttribute("cm-text")
|
| 9720 |
if (cmText != null) {
|
| 9721 |
-
|
| 9722 |
-
else { text += cmText }
|
| 9723 |
return
|
| 9724 |
}
|
| 9725 |
-
var markerID = node.getAttribute("cm-marker"), range
|
| 9726 |
if (markerID) {
|
| 9727 |
-
var found = cm.findMarks(Pos(fromLine, 0), Pos(toLine + 1, 0), recognizeMarker(+markerID))
|
| 9728 |
-
if (found.length && (range = found[0].find()))
|
| 9729 |
-
{
|
| 9730 |
return
|
| 9731 |
}
|
| 9732 |
if (node.getAttribute("contenteditable") == "false") { return }
|
|
|
|
|
|
|
| 9733 |
for (var i = 0; i < node.childNodes.length; i++)
|
| 9734 |
-
{ walk(node.childNodes[i]) }
|
| 9735 |
-
if (
|
| 9736 |
-
{ closing = true }
|
| 9737 |
} else if (node.nodeType == 3) {
|
| 9738 |
-
|
| 9739 |
-
if (!val) { return }
|
| 9740 |
-
if (closing) {
|
| 9741 |
-
text += lineSep
|
| 9742 |
-
closing = false
|
| 9743 |
-
}
|
| 9744 |
-
text += val
|
| 9745 |
}
|
| 9746 |
}
|
| 9747 |
for (;;) {
|
| 9748 |
-
walk(from)
|
| 9749 |
if (from == to) { break }
|
| 9750 |
-
from = from.nextSibling
|
| 9751 |
}
|
| 9752 |
return text
|
| 9753 |
}
|
| 9754 |
|
| 9755 |
function domToPos(cm, node, offset) {
|
| 9756 |
-
var lineNode
|
| 9757 |
if (node == cm.display.lineDiv) {
|
| 9758 |
-
lineNode = cm.display.lineDiv.childNodes[offset]
|
| 9759 |
if (!lineNode) { return badPos(cm.clipPos(Pos(cm.display.viewTo - 1)), true) }
|
| 9760 |
-
node = null; offset = 0
|
| 9761 |
} else {
|
| 9762 |
for (lineNode = node;; lineNode = lineNode.parentNode) {
|
| 9763 |
if (!lineNode || lineNode == cm.display.lineDiv) { return null }
|
|
@@ -9765,196 +9839,196 @@ webpackJsonp([2],{
|
|
| 9765 |
}
|
| 9766 |
}
|
| 9767 |
for (var i = 0; i < cm.display.view.length; i++) {
|
| 9768 |
-
var lineView = cm.display.view[i]
|
| 9769 |
if (lineView.node == lineNode)
|
| 9770 |
{ return locateNodeInLineView(lineView, node, offset) }
|
| 9771 |
}
|
| 9772 |
}
|
| 9773 |
|
| 9774 |
function locateNodeInLineView(lineView, node, offset) {
|
| 9775 |
-
var wrapper = lineView.text.firstChild, bad = false
|
| 9776 |
if (!node || !contains(wrapper, node)) { return badPos(Pos(lineNo(lineView.line), 0), true) }
|
| 9777 |
if (node == wrapper) {
|
| 9778 |
-
bad = true
|
| 9779 |
-
node = wrapper.childNodes[offset]
|
| 9780 |
-
offset = 0
|
| 9781 |
if (!node) {
|
| 9782 |
-
var line = lineView.rest ? lst(lineView.rest) : lineView.line
|
| 9783 |
return badPos(Pos(lineNo(line), line.text.length), bad)
|
| 9784 |
}
|
| 9785 |
}
|
| 9786 |
|
| 9787 |
-
var textNode = node.nodeType == 3 ? node : null, topNode = node
|
| 9788 |
if (!textNode && node.childNodes.length == 1 && node.firstChild.nodeType == 3) {
|
| 9789 |
-
textNode = node.firstChild
|
| 9790 |
-
if (offset) { offset = textNode.nodeValue.length }
|
| 9791 |
}
|
| 9792 |
-
while (topNode.parentNode != wrapper) { topNode = topNode.parentNode }
|
| 9793 |
-
var measure = lineView.measure, maps = measure.maps
|
| 9794 |
|
| 9795 |
function find(textNode, topNode, offset) {
|
| 9796 |
for (var i = -1; i < (maps ? maps.length : 0); i++) {
|
| 9797 |
-
var map = i < 0 ? measure.map : maps[i]
|
| 9798 |
-
for (var j = 0; j < map.length; j += 3) {
|
| 9799 |
-
var curNode = map[j + 2]
|
| 9800 |
if (curNode == textNode || curNode == topNode) {
|
| 9801 |
-
var line = lineNo(i < 0 ? lineView.line : lineView.rest[i])
|
| 9802 |
-
var ch = map[j] + offset
|
| 9803 |
-
if (offset < 0 || curNode != textNode) { ch = map[j + (offset ? 1 : 0)] }
|
| 9804 |
return Pos(line, ch)
|
| 9805 |
}
|
| 9806 |
}
|
| 9807 |
}
|
| 9808 |
}
|
| 9809 |
-
var found = find(textNode, topNode, offset)
|
| 9810 |
if (found) { return badPos(found, bad) }
|
| 9811 |
|
| 9812 |
// FIXME this is all really shaky. might handle the few cases it needs to handle, but likely to cause problems
|
| 9813 |
for (var after = topNode.nextSibling, dist = textNode ? textNode.nodeValue.length - offset : 0; after; after = after.nextSibling) {
|
| 9814 |
-
found = find(after, after.firstChild, 0)
|
| 9815 |
if (found)
|
| 9816 |
{ return badPos(Pos(found.line, found.ch - dist), bad) }
|
| 9817 |
else
|
| 9818 |
-
{ dist += after.textContent.length }
|
| 9819 |
}
|
| 9820 |
for (var before = topNode.previousSibling, dist$1 = offset; before; before = before.previousSibling) {
|
| 9821 |
-
found = find(before, before.firstChild, -1)
|
| 9822 |
if (found)
|
| 9823 |
{ return badPos(Pos(found.line, found.ch + dist$1), bad) }
|
| 9824 |
else
|
| 9825 |
-
{ dist$1 += before.textContent.length }
|
| 9826 |
}
|
| 9827 |
}
|
| 9828 |
|
| 9829 |
// TEXTAREA INPUT STYLE
|
| 9830 |
|
| 9831 |
var TextareaInput = function(cm) {
|
| 9832 |
-
this.cm = cm
|
| 9833 |
// See input.poll and input.reset
|
| 9834 |
-
this.prevInput = ""
|
| 9835 |
|
| 9836 |
// Flag that indicates whether we expect input to appear real soon
|
| 9837 |
// now (after some event like 'keypress' or 'input') and are
|
| 9838 |
// polling intensively.
|
| 9839 |
-
this.pollingFast = false
|
| 9840 |
// Self-resetting timeout for the poller
|
| 9841 |
-
this.polling = new Delayed()
|
| 9842 |
// Tracks when input.reset has punted to just putting a short
|
| 9843 |
// string into the textarea instead of the full selection.
|
| 9844 |
-
this.inaccurateSelection = false
|
| 9845 |
// Used to work around IE issue with selection being forgotten when focus moves away from textarea
|
| 9846 |
-
this.hasSelection = false
|
| 9847 |
-
this.composing = null
|
| 9848 |
};
|
| 9849 |
|
| 9850 |
TextareaInput.prototype.init = function (display) {
|
| 9851 |
var this$1 = this;
|
| 9852 |
|
| 9853 |
-
var input = this, cm = this.cm
|
| 9854 |
|
| 9855 |
// Wraps and hides input textarea
|
| 9856 |
-
var div = this.wrapper = hiddenTextarea()
|
| 9857 |
// The semihidden textarea that is focused when the editor is
|
| 9858 |
// focused, and receives input.
|
| 9859 |
-
var te = this.textarea = div.firstChild
|
| 9860 |
-
display.wrapper.insertBefore(div, display.wrapper.firstChild)
|
| 9861 |
|
| 9862 |
// Needed to hide big blue blinking cursor on Mobile Safari (doesn't seem to work in iOS 8 anymore)
|
| 9863 |
-
if (ios) { te.style.width = "0px" }
|
| 9864 |
|
| 9865 |
on(te, "input", function () {
|
| 9866 |
-
if (ie && ie_version >= 9 && this$1.hasSelection) { this$1.hasSelection = null }
|
| 9867 |
-
input.poll()
|
| 9868 |
-
})
|
| 9869 |
|
| 9870 |
on(te, "paste", function (e) {
|
| 9871 |
if (signalDOMEvent(cm, e) || handlePaste(e, cm)) { return }
|
| 9872 |
|
| 9873 |
-
cm.state.pasteIncoming = true
|
| 9874 |
-
input.fastPoll()
|
| 9875 |
-
})
|
| 9876 |
|
| 9877 |
function prepareCopyCut(e) {
|
| 9878 |
if (signalDOMEvent(cm, e)) { return }
|
| 9879 |
if (cm.somethingSelected()) {
|
| 9880 |
-
setLastCopied({lineWise: false, text: cm.getSelections()})
|
| 9881 |
if (input.inaccurateSelection) {
|
| 9882 |
-
input.prevInput = ""
|
| 9883 |
-
input.inaccurateSelection = false
|
| 9884 |
-
te.value = lastCopied.text.join("\n")
|
| 9885 |
-
selectInput(te)
|
| 9886 |
}
|
| 9887 |
} else if (!cm.options.lineWiseCopyCut) {
|
| 9888 |
return
|
| 9889 |
} else {
|
| 9890 |
-
var ranges = copyableRanges(cm)
|
| 9891 |
-
setLastCopied({lineWise: true, text: ranges.text})
|
| 9892 |
if (e.type == "cut") {
|
| 9893 |
-
cm.setSelections(ranges.ranges, null, sel_dontScroll)
|
| 9894 |
} else {
|
| 9895 |
-
input.prevInput = ""
|
| 9896 |
-
te.value = ranges.text.join("\n")
|
| 9897 |
-
selectInput(te)
|
| 9898 |
}
|
| 9899 |
}
|
| 9900 |
-
if (e.type == "cut") { cm.state.cutIncoming = true }
|
| 9901 |
}
|
| 9902 |
-
on(te, "cut", prepareCopyCut)
|
| 9903 |
-
on(te, "copy", prepareCopyCut)
|
| 9904 |
|
| 9905 |
on(display.scroller, "paste", function (e) {
|
| 9906 |
if (eventInWidget(display, e) || signalDOMEvent(cm, e)) { return }
|
| 9907 |
-
cm.state.pasteIncoming = true
|
| 9908 |
-
input.focus()
|
| 9909 |
-
})
|
| 9910 |
|
| 9911 |
// Prevent normal selection in the editor (we handle our own)
|
| 9912 |
on(display.lineSpace, "selectstart", function (e) {
|
| 9913 |
-
if (!eventInWidget(display, e)) { e_preventDefault(e) }
|
| 9914 |
-
})
|
| 9915 |
|
| 9916 |
on(te, "compositionstart", function () {
|
| 9917 |
-
var start = cm.getCursor("from")
|
| 9918 |
-
if (input.composing) { input.composing.range.clear() }
|
| 9919 |
input.composing = {
|
| 9920 |
start: start,
|
| 9921 |
range: cm.markText(start, cm.getCursor("to"), {className: "CodeMirror-composing"})
|
| 9922 |
-
}
|
| 9923 |
-
})
|
| 9924 |
on(te, "compositionend", function () {
|
| 9925 |
if (input.composing) {
|
| 9926 |
-
input.poll()
|
| 9927 |
-
input.composing.range.clear()
|
| 9928 |
-
input.composing = null
|
| 9929 |
}
|
| 9930 |
-
})
|
| 9931 |
};
|
| 9932 |
|
| 9933 |
TextareaInput.prototype.prepareSelection = function () {
|
| 9934 |
// Redraw the selection and/or cursor
|
| 9935 |
-
var cm = this.cm, display = cm.display, doc = cm.doc
|
| 9936 |
-
var result = prepareSelection(cm)
|
| 9937 |
|
| 9938 |
// Move the hidden textarea near the cursor to prevent scrolling artifacts
|
| 9939 |
if (cm.options.moveInputWithCursor) {
|
| 9940 |
-
var headPos = cursorCoords(cm, doc.sel.primary().head, "div")
|
| 9941 |
-
var wrapOff = display.wrapper.getBoundingClientRect(), lineOff = display.lineDiv.getBoundingClientRect()
|
| 9942 |
result.teTop = Math.max(0, Math.min(display.wrapper.clientHeight - 10,
|
| 9943 |
-
headPos.top + lineOff.top - wrapOff.top))
|
| 9944 |
result.teLeft = Math.max(0, Math.min(display.wrapper.clientWidth - 10,
|
| 9945 |
-
headPos.left + lineOff.left - wrapOff.left))
|
| 9946 |
}
|
| 9947 |
|
| 9948 |
return result
|
| 9949 |
};
|
| 9950 |
|
| 9951 |
TextareaInput.prototype.showSelection = function (drawn) {
|
| 9952 |
-
var cm = this.cm, display = cm.display
|
| 9953 |
-
removeChildrenAndAdd(display.cursorDiv, drawn.cursors)
|
| 9954 |
-
removeChildrenAndAdd(display.selectionDiv, drawn.selection)
|
| 9955 |
if (drawn.teTop != null) {
|
| 9956 |
-
this.wrapper.style.top = drawn.teTop + "px"
|
| 9957 |
-
this.wrapper.style.left = drawn.teLeft + "px"
|
| 9958 |
}
|
| 9959 |
};
|
| 9960 |
|
|
@@ -9962,21 +10036,21 @@ webpackJsonp([2],{
|
|
| 9962 |
// when not typing and nothing is selected)
|
| 9963 |
TextareaInput.prototype.reset = function (typing) {
|
| 9964 |
if (this.contextMenuPending) { return }
|
| 9965 |
-
var minimal, selected, cm = this.cm, doc = cm.doc
|
| 9966 |
if (cm.somethingSelected()) {
|
| 9967 |
-
this.prevInput = ""
|
| 9968 |
-
var range = doc.sel.primary()
|
| 9969 |
minimal = hasCopyEvent &&
|
| 9970 |
-
(range.to().line - range.from().line > 100 || (selected = cm.getSelection()).length > 1000)
|
| 9971 |
-
var content = minimal ? "-" : selected || cm.getSelection()
|
| 9972 |
-
this.textarea.value = content
|
| 9973 |
-
if (cm.state.focused) { selectInput(this.textarea) }
|
| 9974 |
-
if (ie && ie_version >= 9) { this.hasSelection = content }
|
| 9975 |
} else if (!typing) {
|
| 9976 |
-
this.prevInput = this.textarea.value = ""
|
| 9977 |
-
if (ie && ie_version >= 9) { this.hasSelection = null }
|
| 9978 |
}
|
| 9979 |
-
this.inaccurateSelection = minimal
|
| 9980 |
};
|
| 9981 |
|
| 9982 |
TextareaInput.prototype.getField = function () { return this.textarea };
|
|
@@ -9985,18 +10059,18 @@ webpackJsonp([2],{
|
|
| 9985 |
|
| 9986 |
TextareaInput.prototype.focus = function () {
|
| 9987 |
if (this.cm.options.readOnly != "nocursor" && (!mobile || activeElt() != this.textarea)) {
|
| 9988 |
-
try { this.textarea.focus() }
|
| 9989 |
catch (e) {} // IE8 will throw if the textarea is display: none or not in DOM
|
| 9990 |
}
|
| 9991 |
};
|
| 9992 |
|
| 9993 |
-
TextareaInput.prototype.blur = function () { this.textarea.blur() };
|
| 9994 |
|
| 9995 |
TextareaInput.prototype.resetPosition = function () {
|
| 9996 |
-
this.wrapper.style.top = this.wrapper.style.left = 0
|
| 9997 |
};
|
| 9998 |
|
| 9999 |
-
TextareaInput.prototype.receivedFocus = function () { this.slowPoll() };
|
| 10000 |
|
| 10001 |
// Poll for input changes, using the normal rate of polling. This
|
| 10002 |
// runs as long as the editor is focused.
|
|
@@ -10005,23 +10079,23 @@ webpackJsonp([2],{
|
|
| 10005 |
|
| 10006 |
if (this.pollingFast) { return }
|
| 10007 |
this.polling.set(this.cm.options.pollInterval, function () {
|
| 10008 |
-
this$1.poll()
|
| 10009 |
-
if (this$1.cm.state.focused) { this$1.slowPoll() }
|
| 10010 |
-
})
|
| 10011 |
};
|
| 10012 |
|
| 10013 |
// When an event has just come in that is likely to add or change
|
| 10014 |
// something in the input textarea, we poll faster, to ensure that
|
| 10015 |
// the change appears on the screen quickly.
|
| 10016 |
TextareaInput.prototype.fastPoll = function () {
|
| 10017 |
-
var missed = false, input = this
|
| 10018 |
-
input.pollingFast = true
|
| 10019 |
function p() {
|
| 10020 |
-
var changed = input.poll()
|
| 10021 |
-
if (!changed && !missed) {missed = true; input.polling.set(60, p)}
|
| 10022 |
-
else {input.pollingFast = false; input.slowPoll()}
|
| 10023 |
}
|
| 10024 |
-
input.polling.set(20, p)
|
| 10025 |
};
|
| 10026 |
|
| 10027 |
// Read input from the textarea, and update the document to match.
|
|
@@ -10033,7 +10107,7 @@ webpackJsonp([2],{
|
|
| 10033 |
TextareaInput.prototype.poll = function () {
|
| 10034 |
var this$1 = this;
|
| 10035 |
|
| 10036 |
-
var cm = this.cm, input = this.textarea, prevInput = this.prevInput
|
| 10037 |
// Since this is called a *lot*, try to bail out as cheaply as
|
| 10038 |
// possible when it is clear that nothing happened. hasSelection
|
| 10039 |
// will be the case when there is a lot of text in the textarea,
|
|
@@ -10043,7 +10117,7 @@ webpackJsonp([2],{
|
|
| 10043 |
cm.isReadOnly() || cm.options.disableInput || cm.state.keySeq)
|
| 10044 |
{ return false }
|
| 10045 |
|
| 10046 |
-
var text = input.value
|
| 10047 |
// If nothing changed, bail.
|
| 10048 |
if (text == prevInput && !cm.somethingSelected()) { return false }
|
| 10049 |
// Work around nonsensical selection resetting in IE9/10, and
|
|
@@ -10051,290 +10125,291 @@ webpackJsonp([2],{
|
|
| 10051 |
// some key combos in Mac (#2689).
|
| 10052 |
if (ie && ie_version >= 9 && this.hasSelection === text ||
|
| 10053 |
mac && /[\uf700-\uf7ff]/.test(text)) {
|
| 10054 |
-
cm.display.input.reset()
|
| 10055 |
return false
|
| 10056 |
}
|
| 10057 |
|
| 10058 |
if (cm.doc.sel == cm.display.selForContextMenu) {
|
| 10059 |
-
var first = text.charCodeAt(0)
|
| 10060 |
-
if (first == 0x200b && !prevInput) { prevInput = "\u200b" }
|
| 10061 |
if (first == 0x21da) { this.reset(); return this.cm.execCommand("undo") }
|
| 10062 |
}
|
| 10063 |
// Find the part of the input that is actually new
|
| 10064 |
-
var same = 0, l = Math.min(prevInput.length, text.length)
|
| 10065 |
-
while (same < l && prevInput.charCodeAt(same) == text.charCodeAt(same)) { ++same }
|
| 10066 |
|
| 10067 |
runInOp(cm, function () {
|
| 10068 |
applyTextInput(cm, text.slice(same), prevInput.length - same,
|
| 10069 |
-
null, this$1.composing ? "*compose" : null)
|
| 10070 |
|
| 10071 |
// Don't leave long text in the textarea, since it makes further polling slow
|
| 10072 |
-
if (text.length > 1000 || text.indexOf("\n") > -1) { input.value = this$1.prevInput = "" }
|
| 10073 |
-
else { this$1.prevInput = text }
|
| 10074 |
|
| 10075 |
if (this$1.composing) {
|
| 10076 |
-
this$1.composing.range.clear()
|
| 10077 |
this$1.composing.range = cm.markText(this$1.composing.start, cm.getCursor("to"),
|
| 10078 |
-
{className: "CodeMirror-composing"})
|
| 10079 |
}
|
| 10080 |
-
})
|
| 10081 |
return true
|
| 10082 |
};
|
| 10083 |
|
| 10084 |
TextareaInput.prototype.ensurePolled = function () {
|
| 10085 |
-
if (this.pollingFast && this.poll()) { this.pollingFast = false }
|
| 10086 |
};
|
| 10087 |
|
| 10088 |
TextareaInput.prototype.onKeyPress = function () {
|
| 10089 |
-
if (ie && ie_version >= 9) { this.hasSelection = null }
|
| 10090 |
-
this.fastPoll()
|
| 10091 |
};
|
| 10092 |
|
| 10093 |
TextareaInput.prototype.onContextMenu = function (e) {
|
| 10094 |
-
var input = this, cm = input.cm, display = cm.display, te = input.textarea
|
| 10095 |
-
var pos = posFromMouse(cm, e), scrollPos = display.scroller.scrollTop
|
| 10096 |
if (!pos || presto) { return } // Opera is difficult.
|
| 10097 |
|
| 10098 |
// Reset the current text selection only if the click is done outside of the selection
|
| 10099 |
// and 'resetSelectionOnContextMenu' option is true.
|
| 10100 |
-
var reset = cm.options.resetSelectionOnContextMenu
|
| 10101 |
if (reset && cm.doc.sel.contains(pos) == -1)
|
| 10102 |
-
{ operation(cm, setSelection)(cm.doc, simpleSelection(pos), sel_dontScroll) }
|
| 10103 |
-
|
| 10104 |
-
var oldCSS = te.style.cssText, oldWrapperCSS = input.wrapper.style.cssText
|
| 10105 |
-
input.wrapper.style.cssText = "position: absolute"
|
| 10106 |
-
var wrapperBox = input.wrapper.getBoundingClientRect()
|
| 10107 |
-
te.style.cssText = "position: absolute; width: 30px; height: 30px;\n top: " + (e.clientY - wrapperBox.top - 5) + "px; left: " + (e.clientX - wrapperBox.left - 5) + "px;\n z-index: 1000; background: " + (ie ? "rgba(255, 255, 255, .05)" : "transparent") + ";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);"
|
| 10108 |
-
var oldScrollY
|
| 10109 |
-
if (webkit) { oldScrollY = window.scrollY } // Work around Chrome issue (#2712)
|
| 10110 |
-
display.input.focus()
|
| 10111 |
-
if (webkit) { window.scrollTo(null, oldScrollY) }
|
| 10112 |
-
display.input.reset()
|
| 10113 |
// Adds "Select all" to context menu in FF
|
| 10114 |
-
if (!cm.somethingSelected()) { te.value = input.prevInput = " " }
|
| 10115 |
-
input.contextMenuPending = true
|
| 10116 |
-
display.selForContextMenu = cm.doc.sel
|
| 10117 |
-
clearTimeout(display.detectingSelectAll)
|
| 10118 |
|
| 10119 |
// Select-all will be greyed out if there's nothing to select, so
|
| 10120 |
// this adds a zero-width space so that we can later check whether
|
| 10121 |
// it got selected.
|
| 10122 |
function prepareSelectAllHack() {
|
| 10123 |
if (te.selectionStart != null) {
|
| 10124 |
-
var selected = cm.somethingSelected()
|
| 10125 |
-
var extval = "\u200b" + (selected ? te.value : "")
|
| 10126 |
-
te.value = "\u21da" // Used to catch context-menu undo
|
| 10127 |
-
te.value = extval
|
| 10128 |
-
input.prevInput = selected ? "" : "\u200b"
|
| 10129 |
-
te.selectionStart = 1; te.selectionEnd = extval.length
|
| 10130 |
// Re-set this, in case some other handler touched the
|
| 10131 |
// selection in the meantime.
|
| 10132 |
-
display.selForContextMenu = cm.doc.sel
|
| 10133 |
}
|
| 10134 |
}
|
| 10135 |
function rehide() {
|
| 10136 |
-
input.contextMenuPending = false
|
| 10137 |
-
input.wrapper.style.cssText = oldWrapperCSS
|
| 10138 |
-
te.style.cssText = oldCSS
|
| 10139 |
-
if (ie && ie_version < 9) { display.scrollbars.setScrollTop(display.scroller.scrollTop = scrollPos) }
|
| 10140 |
|
| 10141 |
// Try to detect the user choosing select-all
|
| 10142 |
if (te.selectionStart != null) {
|
| 10143 |
-
if (!ie || (ie && ie_version < 9)) { prepareSelectAllHack() }
|
| 10144 |
var i = 0, poll = function () {
|
| 10145 |
if (display.selForContextMenu == cm.doc.sel && te.selectionStart == 0 &&
|
| 10146 |
te.selectionEnd > 0 && input.prevInput == "\u200b") {
|
| 10147 |
-
operation(cm, selectAll)(cm)
|
| 10148 |
} else if (i++ < 10) {
|
| 10149 |
-
display.detectingSelectAll = setTimeout(poll, 500)
|
| 10150 |
} else {
|
| 10151 |
-
display.selForContextMenu = null
|
| 10152 |
-
display.input.reset()
|
| 10153 |
}
|
| 10154 |
-
}
|
| 10155 |
-
display.detectingSelectAll = setTimeout(poll, 200)
|
| 10156 |
}
|
| 10157 |
}
|
| 10158 |
|
| 10159 |
-
if (ie && ie_version >= 9) { prepareSelectAllHack() }
|
| 10160 |
if (captureRightClick) {
|
| 10161 |
-
e_stop(e)
|
| 10162 |
var mouseup = function () {
|
| 10163 |
-
off(window, "mouseup", mouseup)
|
| 10164 |
-
setTimeout(rehide, 20)
|
| 10165 |
-
}
|
| 10166 |
-
on(window, "mouseup", mouseup)
|
| 10167 |
} else {
|
| 10168 |
-
setTimeout(rehide, 50)
|
| 10169 |
}
|
| 10170 |
};
|
| 10171 |
|
| 10172 |
TextareaInput.prototype.readOnlyChanged = function (val) {
|
| 10173 |
-
if (!val) { this.reset() }
|
| 10174 |
};
|
| 10175 |
|
| 10176 |
TextareaInput.prototype.setUneditable = function () {};
|
| 10177 |
|
| 10178 |
-
TextareaInput.prototype.needsContentAttribute = false
|
| 10179 |
|
| 10180 |
function fromTextArea(textarea, options) {
|
| 10181 |
-
options = options ? copyObj(options) : {}
|
| 10182 |
-
options.value = textarea.value
|
| 10183 |
if (!options.tabindex && textarea.tabIndex)
|
| 10184 |
-
{ options.tabindex = textarea.tabIndex }
|
| 10185 |
if (!options.placeholder && textarea.placeholder)
|
| 10186 |
-
{ options.placeholder = textarea.placeholder }
|
| 10187 |
// Set autofocus to true if this textarea is focused, or if it has
|
| 10188 |
// autofocus and no other element is focused.
|
| 10189 |
if (options.autofocus == null) {
|
| 10190 |
-
var hasFocus = activeElt()
|
| 10191 |
options.autofocus = hasFocus == textarea ||
|
| 10192 |
-
textarea.getAttribute("autofocus") != null && hasFocus == document.body
|
| 10193 |
}
|
| 10194 |
|
| 10195 |
-
function save() {textarea.value = cm.getValue()}
|
| 10196 |
|
| 10197 |
-
var realSubmit
|
| 10198 |
if (textarea.form) {
|
| 10199 |
-
on(textarea.form, "submit", save)
|
| 10200 |
// Deplorable hack to make the submit method do the right thing.
|
| 10201 |
if (!options.leaveSubmitMethodAlone) {
|
| 10202 |
-
var form = textarea.form
|
| 10203 |
-
realSubmit = form.submit
|
| 10204 |
try {
|
| 10205 |
var wrappedSubmit = form.submit = function () {
|
| 10206 |
-
save()
|
| 10207 |
-
form.submit = realSubmit
|
| 10208 |
-
form.submit()
|
| 10209 |
-
form.submit = wrappedSubmit
|
| 10210 |
-
}
|
| 10211 |
} catch(e) {}
|
| 10212 |
}
|
| 10213 |
}
|
| 10214 |
|
| 10215 |
options.finishInit = function (cm) {
|
| 10216 |
-
cm.save = save
|
| 10217 |
-
cm.getTextArea = function () { return textarea; }
|
| 10218 |
cm.toTextArea = function () {
|
| 10219 |
-
cm.toTextArea = isNaN // Prevent this from being ran twice
|
| 10220 |
-
save()
|
| 10221 |
-
textarea.parentNode.removeChild(cm.getWrapperElement())
|
| 10222 |
-
textarea.style.display = ""
|
| 10223 |
if (textarea.form) {
|
| 10224 |
-
off(textarea.form, "submit", save)
|
| 10225 |
if (typeof textarea.form.submit == "function")
|
| 10226 |
-
{ textarea.form.submit = realSubmit }
|
| 10227 |
}
|
| 10228 |
-
}
|
| 10229 |
-
}
|
| 10230 |
|
| 10231 |
-
textarea.style.display = "none"
|
| 10232 |
-
var cm = CodeMirror(function (node) { return textarea.parentNode.insertBefore(node, textarea.nextSibling); },
|
| 10233 |
-
options)
|
| 10234 |
return cm
|
| 10235 |
}
|
| 10236 |
|
| 10237 |
function addLegacyProps(CodeMirror) {
|
| 10238 |
-
CodeMirror.off = off
|
| 10239 |
-
CodeMirror.on = on
|
| 10240 |
-
CodeMirror.wheelEventPixels = wheelEventPixels
|
| 10241 |
-
CodeMirror.Doc = Doc
|
| 10242 |
-
CodeMirror.splitLines = splitLinesAuto
|
| 10243 |
-
CodeMirror.countColumn = countColumn
|
| 10244 |
-
CodeMirror.findColumn = findColumn
|
| 10245 |
-
CodeMirror.isWordChar = isWordCharBasic
|
| 10246 |
-
CodeMirror.Pass = Pass
|
| 10247 |
-
CodeMirror.signal = signal
|
| 10248 |
-
CodeMirror.Line = Line
|
| 10249 |
-
CodeMirror.changeEnd = changeEnd
|
| 10250 |
-
CodeMirror.scrollbarModel = scrollbarModel
|
| 10251 |
-
CodeMirror.Pos = Pos
|
| 10252 |
-
CodeMirror.cmpPos = cmp
|
| 10253 |
-
CodeMirror.modes = modes
|
| 10254 |
-
CodeMirror.mimeModes = mimeModes
|
| 10255 |
-
CodeMirror.resolveMode = resolveMode
|
| 10256 |
-
CodeMirror.getMode = getMode
|
| 10257 |
-
CodeMirror.modeExtensions = modeExtensions
|
| 10258 |
-
CodeMirror.extendMode = extendMode
|
| 10259 |
-
CodeMirror.copyState = copyState
|
| 10260 |
-
CodeMirror.startState = startState
|
| 10261 |
-
CodeMirror.innerMode = innerMode
|
| 10262 |
-
CodeMirror.commands = commands
|
| 10263 |
-
CodeMirror.keyMap = keyMap
|
| 10264 |
-
CodeMirror.keyName = keyName
|
| 10265 |
-
CodeMirror.isModifierKey = isModifierKey
|
| 10266 |
-
CodeMirror.lookupKey = lookupKey
|
| 10267 |
-
CodeMirror.normalizeKeyMap = normalizeKeyMap
|
| 10268 |
-
CodeMirror.StringStream = StringStream
|
| 10269 |
-
CodeMirror.SharedTextMarker = SharedTextMarker
|
| 10270 |
-
CodeMirror.TextMarker = TextMarker
|
| 10271 |
-
CodeMirror.LineWidget = LineWidget
|
| 10272 |
-
CodeMirror.e_preventDefault = e_preventDefault
|
| 10273 |
-
CodeMirror.e_stopPropagation = e_stopPropagation
|
| 10274 |
-
CodeMirror.e_stop = e_stop
|
| 10275 |
-
CodeMirror.addClass = addClass
|
| 10276 |
-
CodeMirror.contains = contains
|
| 10277 |
-
CodeMirror.rmClass = rmClass
|
| 10278 |
-
CodeMirror.keyNames = keyNames
|
| 10279 |
}
|
| 10280 |
|
| 10281 |
// EDITOR CONSTRUCTOR
|
| 10282 |
|
| 10283 |
-
defineOptions(CodeMirror)
|
| 10284 |
|
| 10285 |
-
addEditorMethods(CodeMirror)
|
| 10286 |
|
| 10287 |
// Set up methods on CodeMirror's prototype to redirect to the editor's document.
|
| 10288 |
-
var dontDelegate = "iter insert remove copy getEditor constructor".split(" ")
|
| 10289 |
for (var prop in Doc.prototype) { if (Doc.prototype.hasOwnProperty(prop) && indexOf(dontDelegate, prop) < 0)
|
| 10290 |
-
{ CodeMirror.prototype[prop] = (function(method) {
|
| 10291 |
return function() {return method.apply(this.doc, arguments)}
|
| 10292 |
-
})(Doc.prototype[prop]) } }
|
| 10293 |
|
| 10294 |
-
eventMixin(Doc)
|
| 10295 |
|
| 10296 |
// INPUT HANDLING
|
| 10297 |
|
| 10298 |
-
CodeMirror.inputStyles = {"textarea": TextareaInput, "contenteditable": ContentEditableInput}
|
| 10299 |
|
| 10300 |
// MODE DEFINITION AND QUERYING
|
| 10301 |
|
| 10302 |
// Extra arguments are stored as the mode's dependencies, which is
|
| 10303 |
// used by (legacy) mechanisms like loadmode.js to automatically
|
| 10304 |
// load a mode. (Preferred mechanism is the require/define calls.)
|
| 10305 |
-
CodeMirror.defineMode = function(name/*, mode, …*/) {
|
| 10306 |
-
if (!CodeMirror.defaults.mode && name != "null") { CodeMirror.defaults.mode = name }
|
| 10307 |
-
defineMode.apply(this, arguments)
|
| 10308 |
-
}
|
| 10309 |
|
| 10310 |
-
CodeMirror.defineMIME = defineMIME
|
| 10311 |
|
| 10312 |
// Minimal default mode.
|
| 10313 |
-
CodeMirror.defineMode("null", function () { return ({token: function (stream) { return stream.skipToEnd(); }}); })
|
| 10314 |
-
CodeMirror.defineMIME("text/plain", "null")
|
| 10315 |
|
| 10316 |
// EXTENSIONS
|
| 10317 |
|
| 10318 |
-
CodeMirror.defineExtension = function (name, func) {
|
| 10319 |
-
CodeMirror.prototype[name] = func
|
| 10320 |
-
}
|
| 10321 |
-
CodeMirror.defineDocExtension = function (name, func) {
|
| 10322 |
-
Doc.prototype[name] = func
|
| 10323 |
-
}
|
| 10324 |
|
| 10325 |
-
CodeMirror.fromTextArea = fromTextArea
|
| 10326 |
|
| 10327 |
-
addLegacyProps(CodeMirror)
|
| 10328 |
|
| 10329 |
-
CodeMirror.version = "5.
|
| 10330 |
|
| 10331 |
-
return CodeMirror;
|
| 10332 |
|
| 10333 |
})));
|
| 10334 |
|
|
|
|
| 10335 |
/***/ },
|
| 10336 |
|
| 10337 |
-
/***/
|
| 10338 |
/***/ function(module, exports, __webpack_require__) {
|
| 10339 |
|
| 10340 |
// CodeMirror, copyright (c) by Marijn Haverbeke and others
|
|
@@ -10342,7 +10417,7 @@ webpackJsonp([2],{
|
|
| 10342 |
|
| 10343 |
(function(mod) {
|
| 10344 |
if (true) // CommonJS
|
| 10345 |
-
mod(__webpack_require__(
|
| 10346 |
else if (typeof define == "function" && define.amd) // AMD
|
| 10347 |
define(["../../lib/codemirror"], mod);
|
| 10348 |
else // Plain browser env
|
|
@@ -11006,7 +11081,7 @@ webpackJsonp([2],{
|
|
| 11006 |
"small", "small-caps", "small-caption", "smaller", "soft-light", "solid", "somali",
|
| 11007 |
"source-atop", "source-in", "source-out", "source-over", "space", "space-around", "space-between", "spell-out", "square",
|
| 11008 |
"square-button", "start", "static", "status-bar", "stretch", "stroke", "sub",
|
| 11009 |
-
"subpixel-antialiased", "super", "sw-resize", "symbolic", "symbols", "table",
|
| 11010 |
"table-caption", "table-cell", "table-column", "table-column-group",
|
| 11011 |
"table-footer-group", "table-header-group", "table-row", "table-row-group",
|
| 11012 |
"tamil",
|
| 3 |
/***/ 0:
|
| 4 |
/***/ function(module, exports, __webpack_require__) {
|
| 5 |
|
| 6 |
+
__webpack_require__(457);
|
| 7 |
+
__webpack_require__(459);
|
| 8 |
+
module.exports = __webpack_require__(461);
|
| 9 |
|
| 10 |
|
| 11 |
/***/ },
|
| 12 |
|
| 13 |
+
/***/ 457:
|
| 14 |
/***/ function(module, exports, __webpack_require__) {
|
| 15 |
|
| 16 |
+
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["WysijaForm"] = __webpack_require__(458);
|
| 17 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 18 |
|
| 19 |
/***/ },
|
| 20 |
|
| 21 |
+
/***/ 458:
|
| 22 |
/***/ function(module, exports) {
|
| 23 |
|
| 24 |
/*
|
| 1089 |
|
| 1090 |
/***/ },
|
| 1091 |
|
| 1092 |
+
/***/ 459:
|
| 1093 |
/***/ function(module, exports, __webpack_require__) {
|
| 1094 |
|
| 1095 |
+
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["CodeMirror"] = __webpack_require__(460);
|
| 1096 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 1097 |
|
| 1098 |
/***/ },
|
| 1099 |
|
| 1100 |
+
/***/ 460:
|
| 1101 |
/***/ function(module, exports, __webpack_require__) {
|
| 1102 |
|
| 1103 |
// CodeMirror, copyright (c) by Marijn Haverbeke and others
|
| 1110 |
// at http://marijnhaverbeke.nl/blog/#cm-internals .
|
| 1111 |
|
| 1112 |
(function (global, factory) {
|
| 1113 |
+
true ? module.exports = factory() :
|
| 1114 |
+
typeof define === 'function' && define.amd ? define(factory) :
|
| 1115 |
+
(global.CodeMirror = factory());
|
| 1116 |
}(this, (function () { 'use strict';
|
| 1117 |
|
| 1118 |
// Kludges for bugs and behavior differences that can't be feature
|
| 1119 |
// detected are enabled based on userAgent etc sniffing.
|
| 1120 |
+
var userAgent = navigator.userAgent;
|
| 1121 |
+
var platform = navigator.platform;
|
| 1122 |
+
|
| 1123 |
+
var gecko = /gecko\/\d/i.test(userAgent);
|
| 1124 |
+
var ie_upto10 = /MSIE \d/.test(userAgent);
|
| 1125 |
+
var ie_11up = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(userAgent);
|
| 1126 |
+
var edge = /Edge\/(\d+)/.exec(userAgent);
|
| 1127 |
+
var ie = ie_upto10 || ie_11up || edge;
|
| 1128 |
+
var ie_version = ie && (ie_upto10 ? document.documentMode || 6 : +(edge || ie_11up)[1]);
|
| 1129 |
+
var webkit = !edge && /WebKit\//.test(userAgent);
|
| 1130 |
+
var qtwebkit = webkit && /Qt\/\d+\.\d+/.test(userAgent);
|
| 1131 |
+
var chrome = !edge && /Chrome\//.test(userAgent);
|
| 1132 |
+
var presto = /Opera\//.test(userAgent);
|
| 1133 |
+
var safari = /Apple Computer/.test(navigator.vendor);
|
| 1134 |
+
var mac_geMountainLion = /Mac OS X 1\d\D([8-9]|\d\d)\D/.test(userAgent);
|
| 1135 |
+
var phantom = /PhantomJS/.test(userAgent);
|
| 1136 |
+
|
| 1137 |
+
var ios = !edge && /AppleWebKit/.test(userAgent) && /Mobile\/\w+/.test(userAgent);
|
| 1138 |
+
var android = /Android/.test(userAgent);
|
| 1139 |
// This is woefully incomplete. Suggestions for alternative methods welcome.
|
| 1140 |
+
var mobile = ios || android || /webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(userAgent);
|
| 1141 |
+
var mac = ios || /Mac/.test(platform);
|
| 1142 |
+
var chromeOS = /\bCrOS\b/.test(userAgent);
|
| 1143 |
+
var windows = /win/i.test(platform);
|
| 1144 |
+
|
| 1145 |
+
var presto_version = presto && userAgent.match(/Version\/(\d*\.\d*)/);
|
| 1146 |
+
if (presto_version) { presto_version = Number(presto_version[1]); }
|
| 1147 |
+
if (presto_version && presto_version >= 15) { presto = false; webkit = true; }
|
| 1148 |
// Some browsers use the wrong event properties to signal cmd/ctrl on OS X
|
| 1149 |
+
var flipCtrlCmd = mac && (qtwebkit || presto && (presto_version == null || presto_version < 12.11));
|
| 1150 |
+
var captureRightClick = gecko || (ie && ie_version >= 9);
|
| 1151 |
|
| 1152 |
function classTest(cls) { return new RegExp("(^|\\s)" + cls + "(?:$|\\s)\\s*") }
|
| 1153 |
|
| 1154 |
var rmClass = function(node, cls) {
|
| 1155 |
+
var current = node.className;
|
| 1156 |
+
var match = classTest(cls).exec(current);
|
| 1157 |
if (match) {
|
| 1158 |
+
var after = current.slice(match.index + match[0].length);
|
| 1159 |
+
node.className = current.slice(0, match.index) + (after ? match[1] + after : "");
|
| 1160 |
}
|
| 1161 |
+
};
|
| 1162 |
|
| 1163 |
function removeChildren(e) {
|
| 1164 |
for (var count = e.childNodes.length; count > 0; --count)
|
| 1165 |
+
{ e.removeChild(e.firstChild); }
|
| 1166 |
return e
|
| 1167 |
}
|
| 1168 |
|
| 1171 |
}
|
| 1172 |
|
| 1173 |
function elt(tag, content, className, style) {
|
| 1174 |
+
var e = document.createElement(tag);
|
| 1175 |
+
if (className) { e.className = className; }
|
| 1176 |
+
if (style) { e.style.cssText = style; }
|
| 1177 |
+
if (typeof content == "string") { e.appendChild(document.createTextNode(content)); }
|
| 1178 |
+
else if (content) { for (var i = 0; i < content.length; ++i) { e.appendChild(content[i]); } }
|
| 1179 |
+
return e
|
| 1180 |
+
}
|
| 1181 |
+
// wrapper for elt, which removes the elt from the accessibility tree
|
| 1182 |
+
function eltP(tag, content, className, style) {
|
| 1183 |
+
var e = elt(tag, content, className, style);
|
| 1184 |
+
e.setAttribute("role", "presentation");
|
| 1185 |
return e
|
| 1186 |
}
|
| 1187 |
|
| 1188 |
+
var range;
|
| 1189 |
if (document.createRange) { range = function(node, start, end, endNode) {
|
| 1190 |
+
var r = document.createRange();
|
| 1191 |
+
r.setEnd(endNode || node, end);
|
| 1192 |
+
r.setStart(node, start);
|
| 1193 |
return r
|
| 1194 |
+
}; }
|
| 1195 |
else { range = function(node, start, end) {
|
| 1196 |
+
var r = document.body.createTextRange();
|
| 1197 |
+
try { r.moveToElementText(node.parentNode); }
|
| 1198 |
catch(e) { return r }
|
| 1199 |
+
r.collapse(true);
|
| 1200 |
+
r.moveEnd("character", end);
|
| 1201 |
+
r.moveStart("character", start);
|
| 1202 |
return r
|
| 1203 |
+
}; }
|
| 1204 |
|
| 1205 |
function contains(parent, child) {
|
| 1206 |
if (child.nodeType == 3) // Android browser always returns false when child is a textnode
|
| 1207 |
+
{ child = child.parentNode; }
|
| 1208 |
if (parent.contains)
|
| 1209 |
{ return parent.contains(child) }
|
| 1210 |
do {
|
| 1211 |
+
if (child.nodeType == 11) { child = child.host; }
|
| 1212 |
if (child == parent) { return true }
|
| 1213 |
} while (child = child.parentNode)
|
| 1214 |
}
|
| 1217 |
// IE and Edge may throw an "Unspecified Error" when accessing document.activeElement.
|
| 1218 |
// IE < 10 will throw when accessed while the page is loading or in an iframe.
|
| 1219 |
// IE > 9 and Edge will throw when accessed in an iframe if document.body is unavailable.
|
| 1220 |
+
var activeElement;
|
| 1221 |
try {
|
| 1222 |
+
activeElement = document.activeElement;
|
| 1223 |
} catch(e) {
|
| 1224 |
+
activeElement = document.body || null;
|
| 1225 |
}
|
| 1226 |
+
while (activeElement && activeElement.shadowRoot && activeElement.shadowRoot.activeElement)
|
| 1227 |
+
{ activeElement = activeElement.shadowRoot.activeElement; }
|
| 1228 |
return activeElement
|
| 1229 |
}
|
| 1230 |
|
| 1231 |
function addClass(node, cls) {
|
| 1232 |
+
var current = node.className;
|
| 1233 |
+
if (!classTest(cls).test(current)) { node.className += (current ? " " : "") + cls; }
|
| 1234 |
}
|
| 1235 |
function joinClasses(a, b) {
|
| 1236 |
+
var as = a.split(" ");
|
| 1237 |
for (var i = 0; i < as.length; i++)
|
| 1238 |
+
{ if (as[i] && !classTest(as[i]).test(b)) { b += " " + as[i]; } }
|
| 1239 |
return b
|
| 1240 |
}
|
| 1241 |
|
| 1242 |
+
var selectInput = function(node) { node.select(); };
|
| 1243 |
if (ios) // Mobile Safari apparently has a bug where select() is broken.
|
| 1244 |
+
{ selectInput = function(node) { node.selectionStart = 0; node.selectionEnd = node.value.length; }; }
|
| 1245 |
else if (ie) // Suppress mysterious IE10 errors
|
| 1246 |
+
{ selectInput = function(node) { try { node.select(); } catch(_e) {} }; }
|
| 1247 |
|
| 1248 |
function bind(f) {
|
| 1249 |
+
var args = Array.prototype.slice.call(arguments, 1);
|
| 1250 |
return function(){return f.apply(null, args)}
|
| 1251 |
}
|
| 1252 |
|
| 1253 |
function copyObj(obj, target, overwrite) {
|
| 1254 |
+
if (!target) { target = {}; }
|
| 1255 |
for (var prop in obj)
|
| 1256 |
{ if (obj.hasOwnProperty(prop) && (overwrite !== false || !target.hasOwnProperty(prop)))
|
| 1257 |
+
{ target[prop] = obj[prop]; } }
|
| 1258 |
return target
|
| 1259 |
}
|
| 1260 |
|
| 1262 |
// Used mostly to find indentation.
|
| 1263 |
function countColumn(string, end, tabSize, startIndex, startValue) {
|
| 1264 |
if (end == null) {
|
| 1265 |
+
end = string.search(/[^\s\u00a0]/);
|
| 1266 |
+
if (end == -1) { end = string.length; }
|
| 1267 |
}
|
| 1268 |
for (var i = startIndex || 0, n = startValue || 0;;) {
|
| 1269 |
+
var nextTab = string.indexOf("\t", i);
|
| 1270 |
if (nextTab < 0 || nextTab >= end)
|
| 1271 |
{ return n + (end - i) }
|
| 1272 |
+
n += nextTab - i;
|
| 1273 |
+
n += tabSize - (n % tabSize);
|
| 1274 |
+
i = nextTab + 1;
|
| 1275 |
}
|
| 1276 |
}
|
| 1277 |
|
| 1278 |
+
var Delayed = function() {this.id = null;};
|
| 1279 |
Delayed.prototype.set = function (ms, f) {
|
| 1280 |
+
clearTimeout(this.id);
|
| 1281 |
+
this.id = setTimeout(f, ms);
|
| 1282 |
};
|
| 1283 |
|
| 1284 |
function indexOf(array, elt) {
|
| 1288 |
}
|
| 1289 |
|
| 1290 |
// Number of pixels added to scroller and sizer to hide scrollbar
|
| 1291 |
+
var scrollerGap = 30;
|
| 1292 |
|
| 1293 |
// Returned or thrown by various protocols to signal 'I'm not
|
| 1294 |
// handling this'.
|
| 1295 |
+
var Pass = {toString: function(){return "CodeMirror.Pass"}};
|
| 1296 |
|
| 1297 |
// Reused option objects for setSelection & friends
|
| 1298 |
var sel_dontScroll = {scroll: false};
|
| 1299 |
var sel_mouse = {origin: "*mouse"};
|
| 1300 |
var sel_move = {origin: "+move"};
|
| 1301 |
+
|
| 1302 |
// The inverse of countColumn -- find the offset that corresponds to
|
| 1303 |
// a particular column.
|
| 1304 |
function findColumn(string, goal, tabSize) {
|
| 1305 |
for (var pos = 0, col = 0;;) {
|
| 1306 |
+
var nextTab = string.indexOf("\t", pos);
|
| 1307 |
+
if (nextTab == -1) { nextTab = string.length; }
|
| 1308 |
+
var skipped = nextTab - pos;
|
| 1309 |
if (nextTab == string.length || col + skipped >= goal)
|
| 1310 |
{ return pos + Math.min(skipped, goal - col) }
|
| 1311 |
+
col += nextTab - pos;
|
| 1312 |
+
col += tabSize - (col % tabSize);
|
| 1313 |
+
pos = nextTab + 1;
|
| 1314 |
if (col >= goal) { return pos }
|
| 1315 |
}
|
| 1316 |
}
|
| 1317 |
|
| 1318 |
+
var spaceStrs = [""];
|
| 1319 |
function spaceStr(n) {
|
| 1320 |
while (spaceStrs.length <= n)
|
| 1321 |
+
{ spaceStrs.push(lst(spaceStrs) + " "); }
|
| 1322 |
return spaceStrs[n]
|
| 1323 |
}
|
| 1324 |
|
| 1325 |
function lst(arr) { return arr[arr.length-1] }
|
| 1326 |
|
| 1327 |
function map(array, f) {
|
| 1328 |
+
var out = [];
|
| 1329 |
+
for (var i = 0; i < array.length; i++) { out[i] = f(array[i], i); }
|
| 1330 |
return out
|
| 1331 |
}
|
| 1332 |
|
| 1333 |
function insertSorted(array, value, score) {
|
| 1334 |
+
var pos = 0, priority = score(value);
|
| 1335 |
+
while (pos < array.length && score(array[pos]) <= priority) { pos++; }
|
| 1336 |
+
array.splice(pos, 0, value);
|
| 1337 |
}
|
| 1338 |
|
| 1339 |
function nothing() {}
|
| 1340 |
|
| 1341 |
function createObj(base, props) {
|
| 1342 |
+
var inst;
|
| 1343 |
if (Object.create) {
|
| 1344 |
+
inst = Object.create(base);
|
| 1345 |
} else {
|
| 1346 |
+
nothing.prototype = base;
|
| 1347 |
+
inst = new nothing();
|
| 1348 |
}
|
| 1349 |
+
if (props) { copyObj(props, inst); }
|
| 1350 |
return inst
|
| 1351 |
}
|
| 1352 |
|
| 1353 |
+
var nonASCIISingleCaseWordChar = /[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;
|
| 1354 |
function isWordCharBasic(ch) {
|
| 1355 |
return /\w/.test(ch) || ch > "\x80" &&
|
| 1356 |
(ch.toUpperCase() != ch.toLowerCase() || nonASCIISingleCaseWordChar.test(ch))
|
| 1371 |
// as editing and measuring is concerned. This is not fully correct,
|
| 1372 |
// since some scripts/fonts/browsers also treat other configurations
|
| 1373 |
// of code points as a group.
|
| 1374 |
+
var extendingChars = /[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;
|
| 1375 |
function isExtendingChar(ch) { return ch.charCodeAt(0) >= 768 && extendingChars.test(ch) }
|
| 1376 |
|
| 1377 |
// Returns a number from the range [`0`; `str.length`] unless `pos` is outside that range.
|
| 1378 |
function skipExtendingChars(str, pos, dir) {
|
| 1379 |
+
while ((dir < 0 ? pos > 0 : pos < str.length) && isExtendingChar(str.charAt(pos))) { pos += dir; }
|
| 1380 |
return pos
|
| 1381 |
}
|
| 1382 |
|
| 1385 |
function findFirst(pred, from, to) {
|
| 1386 |
for (;;) {
|
| 1387 |
if (Math.abs(from - to) <= 1) { return pred(from) ? from : to }
|
| 1388 |
+
var mid = Math.floor((from + to) / 2);
|
| 1389 |
+
if (pred(mid)) { to = mid; }
|
| 1390 |
+
else { from = mid; }
|
| 1391 |
}
|
| 1392 |
}
|
| 1393 |
|
| 1396 |
// display-related state.
|
| 1397 |
|
| 1398 |
function Display(place, doc, input) {
|
| 1399 |
+
var d = this;
|
| 1400 |
+
this.input = input;
|
| 1401 |
|
| 1402 |
// Covers bottom-right square when both scrollbars are present.
|
| 1403 |
+
d.scrollbarFiller = elt("div", null, "CodeMirror-scrollbar-filler");
|
| 1404 |
+
d.scrollbarFiller.setAttribute("cm-not-content", "true");
|
| 1405 |
// Covers bottom of gutter when coverGutterNextToScrollbar is on
|
| 1406 |
// and h scrollbar is present.
|
| 1407 |
+
d.gutterFiller = elt("div", null, "CodeMirror-gutter-filler");
|
| 1408 |
+
d.gutterFiller.setAttribute("cm-not-content", "true");
|
| 1409 |
// Will contain the actual code, positioned to cover the viewport.
|
| 1410 |
+
d.lineDiv = eltP("div", null, "CodeMirror-code");
|
| 1411 |
// Elements are added to these to represent selection and cursors.
|
| 1412 |
+
d.selectionDiv = elt("div", null, null, "position: relative; z-index: 1");
|
| 1413 |
+
d.cursorDiv = elt("div", null, "CodeMirror-cursors");
|
| 1414 |
// A visibility: hidden element used to find the size of things.
|
| 1415 |
+
d.measure = elt("div", null, "CodeMirror-measure");
|
| 1416 |
// When lines outside of the viewport are measured, they are drawn in this.
|
| 1417 |
+
d.lineMeasure = elt("div", null, "CodeMirror-measure");
|
| 1418 |
// Wraps everything that needs to exist inside the vertically-padded coordinate system
|
| 1419 |
+
d.lineSpace = eltP("div", [d.measure, d.lineMeasure, d.selectionDiv, d.cursorDiv, d.lineDiv],
|
| 1420 |
+
null, "position: relative; outline: none");
|
| 1421 |
+
var lines = eltP("div", [d.lineSpace], "CodeMirror-lines");
|
| 1422 |
// Moved around its parent to cover visible view.
|
| 1423 |
+
d.mover = elt("div", [lines], null, "position: relative");
|
| 1424 |
// Set to the height of the document, allowing scrolling.
|
| 1425 |
+
d.sizer = elt("div", [d.mover], "CodeMirror-sizer");
|
| 1426 |
+
d.sizerWidth = null;
|
| 1427 |
// Behavior of elts with overflow: auto and padding is
|
| 1428 |
// inconsistent across browsers. This is used to ensure the
|
| 1429 |
// scrollable area is big enough.
|
| 1430 |
+
d.heightForcer = elt("div", null, null, "position: absolute; height: " + scrollerGap + "px; width: 1px;");
|
| 1431 |
// Will contain the gutters, if any.
|
| 1432 |
+
d.gutters = elt("div", null, "CodeMirror-gutters");
|
| 1433 |
+
d.lineGutter = null;
|
| 1434 |
// Actual scrollable element.
|
| 1435 |
+
d.scroller = elt("div", [d.sizer, d.heightForcer, d.gutters], "CodeMirror-scroll");
|
| 1436 |
+
d.scroller.setAttribute("tabIndex", "-1");
|
| 1437 |
// The element in which the editor lives.
|
| 1438 |
+
d.wrapper = elt("div", [d.scrollbarFiller, d.gutterFiller, d.scroller], "CodeMirror");
|
| 1439 |
|
| 1440 |
// Work around IE7 z-index bug (not perfect, hence IE7 not really being supported)
|
| 1441 |
+
if (ie && ie_version < 8) { d.gutters.style.zIndex = -1; d.scroller.style.paddingRight = 0; }
|
| 1442 |
+
if (!webkit && !(gecko && mobile)) { d.scroller.draggable = true; }
|
| 1443 |
|
| 1444 |
if (place) {
|
| 1445 |
+
if (place.appendChild) { place.appendChild(d.wrapper); }
|
| 1446 |
+
else { place(d.wrapper); }
|
| 1447 |
}
|
| 1448 |
|
| 1449 |
// Current rendered range (may be bigger than the view window).
|
| 1450 |
+
d.viewFrom = d.viewTo = doc.first;
|
| 1451 |
+
d.reportedViewFrom = d.reportedViewTo = doc.first;
|
| 1452 |
// Information about the rendered lines.
|
| 1453 |
+
d.view = [];
|
| 1454 |
+
d.renderedView = null;
|
| 1455 |
// Holds info about a single rendered line when it was rendered
|
| 1456 |
// for measurement, while not in view.
|
| 1457 |
+
d.externalMeasured = null;
|
| 1458 |
// Empty space (in pixels) above the view
|
| 1459 |
+
d.viewOffset = 0;
|
| 1460 |
+
d.lastWrapHeight = d.lastWrapWidth = 0;
|
| 1461 |
+
d.updateLineNumbers = null;
|
| 1462 |
|
| 1463 |
+
d.nativeBarWidth = d.barHeight = d.barWidth = 0;
|
| 1464 |
+
d.scrollbarsClipped = false;
|
| 1465 |
|
| 1466 |
// Used to only resize the line number gutter when necessary (when
|
| 1467 |
// the amount of lines crosses a boundary that makes its width change)
|
| 1468 |
+
d.lineNumWidth = d.lineNumInnerWidth = d.lineNumChars = null;
|
| 1469 |
// Set to true when a non-horizontal-scrolling line widget is
|
| 1470 |
// added. As an optimization, line widget aligning is skipped when
|
| 1471 |
// this is false.
|
| 1472 |
+
d.alignWidgets = false;
|
| 1473 |
|
| 1474 |
+
d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = null;
|
| 1475 |
|
| 1476 |
// Tracks the maximum line length so that the horizontal scrollbar
|
| 1477 |
// can be kept static when scrolling.
|
| 1478 |
+
d.maxLine = null;
|
| 1479 |
+
d.maxLineLength = 0;
|
| 1480 |
+
d.maxLineChanged = false;
|
| 1481 |
|
| 1482 |
// Used for measuring wheel scrolling granularity
|
| 1483 |
+
d.wheelDX = d.wheelDY = d.wheelStartX = d.wheelStartY = null;
|
| 1484 |
|
| 1485 |
// True when shift is held down.
|
| 1486 |
+
d.shift = false;
|
| 1487 |
|
| 1488 |
// Used to track whether anything happened since the context menu
|
| 1489 |
// was opened.
|
| 1490 |
+
d.selForContextMenu = null;
|
| 1491 |
|
| 1492 |
+
d.activeTouch = null;
|
| 1493 |
|
| 1494 |
+
input.init(d);
|
| 1495 |
}
|
| 1496 |
|
| 1497 |
// Find the line object corresponding to the given line number.
|
| 1498 |
function getLine(doc, n) {
|
| 1499 |
+
n -= doc.first;
|
| 1500 |
if (n < 0 || n >= doc.size) { throw new Error("There is no line " + (n + doc.first) + " in the document.") }
|
| 1501 |
+
var chunk = doc;
|
| 1502 |
while (!chunk.lines) {
|
| 1503 |
for (var i = 0;; ++i) {
|
| 1504 |
+
var child = chunk.children[i], sz = child.chunkSize();
|
| 1505 |
if (n < sz) { chunk = child; break }
|
| 1506 |
+
n -= sz;
|
| 1507 |
}
|
| 1508 |
}
|
| 1509 |
return chunk.lines[n]
|
| 1512 |
// Get the part of a document between two positions, as an array of
|
| 1513 |
// strings.
|
| 1514 |
function getBetween(doc, start, end) {
|
| 1515 |
+
var out = [], n = start.line;
|
| 1516 |
doc.iter(start.line, end.line + 1, function (line) {
|
| 1517 |
+
var text = line.text;
|
| 1518 |
+
if (n == end.line) { text = text.slice(0, end.ch); }
|
| 1519 |
+
if (n == start.line) { text = text.slice(start.ch); }
|
| 1520 |
+
out.push(text);
|
| 1521 |
+
++n;
|
| 1522 |
+
});
|
| 1523 |
return out
|
| 1524 |
}
|
| 1525 |
// Get the lines between from and to, as array of strings.
|
| 1526 |
function getLines(doc, from, to) {
|
| 1527 |
+
var out = [];
|
| 1528 |
+
doc.iter(from, to, function (line) { out.push(line.text); }); // iter aborts when callback returns truthy value
|
| 1529 |
return out
|
| 1530 |
}
|
| 1531 |
|
| 1532 |
// Update the height of a line, propagating the height change
|
| 1533 |
// upwards to parent nodes.
|
| 1534 |
function updateLineHeight(line, height) {
|
| 1535 |
+
var diff = height - line.height;
|
| 1536 |
+
if (diff) { for (var n = line; n; n = n.parent) { n.height += diff; } }
|
| 1537 |
}
|
| 1538 |
|
| 1539 |
// Given a line object, find its line number by walking up through
|
| 1540 |
// its parent links.
|
| 1541 |
function lineNo(line) {
|
| 1542 |
if (line.parent == null) { return null }
|
| 1543 |
+
var cur = line.parent, no = indexOf(cur.lines, line);
|
| 1544 |
for (var chunk = cur.parent; chunk; cur = chunk, chunk = chunk.parent) {
|
| 1545 |
for (var i = 0;; ++i) {
|
| 1546 |
if (chunk.children[i] == cur) { break }
|
| 1547 |
+
no += chunk.children[i].chunkSize();
|
| 1548 |
}
|
| 1549 |
}
|
| 1550 |
return no + cur.first
|
| 1553 |
// Find the line at the given vertical position, using the height
|
| 1554 |
// information in the document tree.
|
| 1555 |
function lineAtHeight(chunk, h) {
|
| 1556 |
+
var n = chunk.first;
|
| 1557 |
outer: do {
|
| 1558 |
for (var i$1 = 0; i$1 < chunk.children.length; ++i$1) {
|
| 1559 |
+
var child = chunk.children[i$1], ch = child.height;
|
| 1560 |
if (h < ch) { chunk = child; continue outer }
|
| 1561 |
+
h -= ch;
|
| 1562 |
+
n += child.chunkSize();
|
| 1563 |
}
|
| 1564 |
return n
|
| 1565 |
} while (!chunk.lines)
|
| 1566 |
+
var i = 0;
|
| 1567 |
for (; i < chunk.lines.length; ++i) {
|
| 1568 |
+
var line = chunk.lines[i], lh = line.height;
|
| 1569 |
if (h < lh) { break }
|
| 1570 |
+
h -= lh;
|
| 1571 |
}
|
| 1572 |
return n + i
|
| 1573 |
}
|
| 1583 |
if ( sticky === void 0 ) sticky = null;
|
| 1584 |
|
| 1585 |
if (!(this instanceof Pos)) { return new Pos(line, ch, sticky) }
|
| 1586 |
+
this.line = line;
|
| 1587 |
+
this.ch = ch;
|
| 1588 |
+
this.sticky = sticky;
|
| 1589 |
}
|
| 1590 |
|
| 1591 |
// Compare two positions, return 0 if they are the same, a negative
|
| 1603 |
function clipLine(doc, n) {return Math.max(doc.first, Math.min(n, doc.first + doc.size - 1))}
|
| 1604 |
function clipPos(doc, pos) {
|
| 1605 |
if (pos.line < doc.first) { return Pos(doc.first, 0) }
|
| 1606 |
+
var last = doc.first + doc.size - 1;
|
| 1607 |
if (pos.line > last) { return Pos(last, getLine(doc, last).text.length) }
|
| 1608 |
return clipToLen(pos, getLine(doc, pos.line).text.length)
|
| 1609 |
}
|
| 1610 |
function clipToLen(pos, linelen) {
|
| 1611 |
+
var ch = pos.ch;
|
| 1612 |
if (ch == null || ch > linelen) { return Pos(pos.line, linelen) }
|
| 1613 |
else if (ch < 0) { return Pos(pos.line, 0) }
|
| 1614 |
else { return pos }
|
| 1615 |
}
|
| 1616 |
function clipPosArray(doc, array) {
|
| 1617 |
+
var out = [];
|
| 1618 |
+
for (var i = 0; i < array.length; i++) { out[i] = clipPos(doc, array[i]); }
|
| 1619 |
return out
|
| 1620 |
}
|
| 1621 |
|
| 1622 |
// Optimize some code when these features are not used.
|
| 1623 |
var sawReadOnlySpans = false;
|
| 1624 |
var sawCollapsedSpans = false;
|
| 1625 |
+
|
| 1626 |
function seeReadOnlySpans() {
|
| 1627 |
+
sawReadOnlySpans = true;
|
| 1628 |
}
|
| 1629 |
|
| 1630 |
function seeCollapsedSpans() {
|
| 1631 |
+
sawCollapsedSpans = true;
|
| 1632 |
}
|
| 1633 |
|
| 1634 |
// TEXTMARKER SPANS
|
| 1635 |
|
| 1636 |
function MarkedSpan(marker, from, to) {
|
| 1637 |
+
this.marker = marker;
|
| 1638 |
+
this.from = from; this.to = to;
|
| 1639 |
}
|
| 1640 |
|
| 1641 |
// Search an array of spans for a span matching the given marker.
|
| 1642 |
function getMarkedSpanFor(spans, marker) {
|
| 1643 |
if (spans) { for (var i = 0; i < spans.length; ++i) {
|
| 1644 |
+
var span = spans[i];
|
| 1645 |
if (span.marker == marker) { return span }
|
| 1646 |
} }
|
| 1647 |
}
|
| 1648 |
// Remove a span from an array, returning undefined if no spans are
|
| 1649 |
// left (we don't store arrays for lines without spans).
|
| 1650 |
function removeMarkedSpan(spans, span) {
|
| 1651 |
+
var r;
|
| 1652 |
for (var i = 0; i < spans.length; ++i)
|
| 1653 |
+
{ if (spans[i] != span) { (r || (r = [])).push(spans[i]); } }
|
| 1654 |
return r
|
| 1655 |
}
|
| 1656 |
// Add a span to a line.
|
| 1657 |
function addMarkedSpan(line, span) {
|
| 1658 |
+
line.markedSpans = line.markedSpans ? line.markedSpans.concat([span]) : [span];
|
| 1659 |
+
span.marker.attachLine(line);
|
| 1660 |
}
|
| 1661 |
|
| 1662 |
// Used for the algorithm that adjusts markers for a change in the
|
| 1664 |
// character position, returning an array of remaining chunks (or
|
| 1665 |
// undefined if nothing remains).
|
| 1666 |
function markedSpansBefore(old, startCh, isInsert) {
|
| 1667 |
+
var nw;
|
| 1668 |
if (old) { for (var i = 0; i < old.length; ++i) {
|
| 1669 |
+
var span = old[i], marker = span.marker;
|
| 1670 |
+
var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= startCh : span.from < startCh);
|
| 1671 |
if (startsBefore || span.from == startCh && marker.type == "bookmark" && (!isInsert || !span.marker.insertLeft)) {
|
| 1672 |
+
var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= startCh : span.to > startCh);(nw || (nw = [])).push(new MarkedSpan(marker, span.from, endsAfter ? null : span.to));
|
|
|
|
| 1673 |
}
|
| 1674 |
} }
|
| 1675 |
return nw
|
| 1676 |
}
|
| 1677 |
function markedSpansAfter(old, endCh, isInsert) {
|
| 1678 |
+
var nw;
|
| 1679 |
if (old) { for (var i = 0; i < old.length; ++i) {
|
| 1680 |
+
var span = old[i], marker = span.marker;
|
| 1681 |
+
var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= endCh : span.to > endCh);
|
| 1682 |
if (endsAfter || span.from == endCh && marker.type == "bookmark" && (!isInsert || span.marker.insertLeft)) {
|
| 1683 |
+
var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= endCh : span.from < endCh);(nw || (nw = [])).push(new MarkedSpan(marker, startsBefore ? null : span.from - endCh,
|
| 1684 |
+
span.to == null ? null : span.to - endCh));
|
|
|
|
| 1685 |
}
|
| 1686 |
} }
|
| 1687 |
return nw
|
| 1695 |
// arrays with one element for each line in (after) the change.
|
| 1696 |
function stretchSpansOverChange(doc, change) {
|
| 1697 |
if (change.full) { return null }
|
| 1698 |
+
var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans;
|
| 1699 |
+
var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans;
|
| 1700 |
if (!oldFirst && !oldLast) { return null }
|
| 1701 |
|
| 1702 |
+
var startCh = change.from.ch, endCh = change.to.ch, isInsert = cmp(change.from, change.to) == 0;
|
| 1703 |
// Get the spans that 'stick out' on both sides
|
| 1704 |
+
var first = markedSpansBefore(oldFirst, startCh, isInsert);
|
| 1705 |
+
var last = markedSpansAfter(oldLast, endCh, isInsert);
|
| 1706 |
|
| 1707 |
// Next, merge those two ends
|
| 1708 |
+
var sameLine = change.text.length == 1, offset = lst(change.text).length + (sameLine ? startCh : 0);
|
| 1709 |
if (first) {
|
| 1710 |
// Fix up .to properties of first
|
| 1711 |
for (var i = 0; i < first.length; ++i) {
|
| 1712 |
+
var span = first[i];
|
| 1713 |
if (span.to == null) {
|
| 1714 |
+
var found = getMarkedSpanFor(last, span.marker);
|
| 1715 |
+
if (!found) { span.to = startCh; }
|
| 1716 |
+
else if (sameLine) { span.to = found.to == null ? null : found.to + offset; }
|
| 1717 |
}
|
| 1718 |
}
|
| 1719 |
}
|
| 1720 |
if (last) {
|
| 1721 |
// Fix up .from in last (or move them into first in case of sameLine)
|
| 1722 |
for (var i$1 = 0; i$1 < last.length; ++i$1) {
|
| 1723 |
+
var span$1 = last[i$1];
|
| 1724 |
+
if (span$1.to != null) { span$1.to += offset; }
|
| 1725 |
if (span$1.from == null) {
|
| 1726 |
+
var found$1 = getMarkedSpanFor(first, span$1.marker);
|
| 1727 |
if (!found$1) {
|
| 1728 |
+
span$1.from = offset;
|
| 1729 |
+
if (sameLine) { (first || (first = [])).push(span$1); }
|
| 1730 |
}
|
| 1731 |
} else {
|
| 1732 |
+
span$1.from += offset;
|
| 1733 |
+
if (sameLine) { (first || (first = [])).push(span$1); }
|
| 1734 |
}
|
| 1735 |
}
|
| 1736 |
}
|
| 1737 |
// Make sure we didn't create any zero-length spans
|
| 1738 |
+
if (first) { first = clearEmptySpans(first); }
|
| 1739 |
+
if (last && last != first) { last = clearEmptySpans(last); }
|
| 1740 |
|
| 1741 |
+
var newMarkers = [first];
|
| 1742 |
if (!sameLine) {
|
| 1743 |
// Fill gap with whole-line-spans
|
| 1744 |
+
var gap = change.text.length - 2, gapMarkers;
|
| 1745 |
if (gap > 0 && first)
|
| 1746 |
{ for (var i$2 = 0; i$2 < first.length; ++i$2)
|
| 1747 |
{ if (first[i$2].to == null)
|
| 1748 |
+
{ (gapMarkers || (gapMarkers = [])).push(new MarkedSpan(first[i$2].marker, null, null)); } } }
|
| 1749 |
for (var i$3 = 0; i$3 < gap; ++i$3)
|
| 1750 |
+
{ newMarkers.push(gapMarkers); }
|
| 1751 |
+
newMarkers.push(last);
|
| 1752 |
}
|
| 1753 |
return newMarkers
|
| 1754 |
}
|
| 1757 |
// option of false.
|
| 1758 |
function clearEmptySpans(spans) {
|
| 1759 |
for (var i = 0; i < spans.length; ++i) {
|
| 1760 |
+
var span = spans[i];
|
| 1761 |
if (span.from != null && span.from == span.to && span.marker.clearWhenEmpty !== false)
|
| 1762 |
+
{ spans.splice(i--, 1); }
|
| 1763 |
}
|
| 1764 |
if (!spans.length) { return null }
|
| 1765 |
return spans
|
| 1767 |
|
| 1768 |
// Used to 'clip' out readOnly ranges when making a change.
|
| 1769 |
function removeReadOnlyRanges(doc, from, to) {
|
| 1770 |
+
var markers = null;
|
| 1771 |
doc.iter(from.line, to.line + 1, function (line) {
|
| 1772 |
if (line.markedSpans) { for (var i = 0; i < line.markedSpans.length; ++i) {
|
| 1773 |
+
var mark = line.markedSpans[i].marker;
|
| 1774 |
if (mark.readOnly && (!markers || indexOf(markers, mark) == -1))
|
| 1775 |
+
{ (markers || (markers = [])).push(mark); }
|
| 1776 |
} }
|
| 1777 |
+
});
|
| 1778 |
if (!markers) { return null }
|
| 1779 |
+
var parts = [{from: from, to: to}];
|
| 1780 |
for (var i = 0; i < markers.length; ++i) {
|
| 1781 |
+
var mk = markers[i], m = mk.find(0);
|
| 1782 |
for (var j = 0; j < parts.length; ++j) {
|
| 1783 |
+
var p = parts[j];
|
| 1784 |
if (cmp(p.to, m.from) < 0 || cmp(p.from, m.to) > 0) { continue }
|
| 1785 |
+
var newParts = [j, 1], dfrom = cmp(p.from, m.from), dto = cmp(p.to, m.to);
|
| 1786 |
if (dfrom < 0 || !mk.inclusiveLeft && !dfrom)
|
| 1787 |
+
{ newParts.push({from: p.from, to: m.from}); }
|
| 1788 |
if (dto > 0 || !mk.inclusiveRight && !dto)
|
| 1789 |
+
{ newParts.push({from: m.to, to: p.to}); }
|
| 1790 |
+
parts.splice.apply(parts, newParts);
|
| 1791 |
+
j += newParts.length - 3;
|
| 1792 |
}
|
| 1793 |
}
|
| 1794 |
return parts
|
| 1796 |
|
| 1797 |
// Connect or disconnect spans from a line.
|
| 1798 |
function detachMarkedSpans(line) {
|
| 1799 |
+
var spans = line.markedSpans;
|
| 1800 |
if (!spans) { return }
|
| 1801 |
for (var i = 0; i < spans.length; ++i)
|
| 1802 |
+
{ spans[i].marker.detachLine(line); }
|
| 1803 |
+
line.markedSpans = null;
|
| 1804 |
}
|
| 1805 |
function attachMarkedSpans(line, spans) {
|
| 1806 |
if (!spans) { return }
|
| 1807 |
for (var i = 0; i < spans.length; ++i)
|
| 1808 |
+
{ spans[i].marker.attachLine(line); }
|
| 1809 |
+
line.markedSpans = spans;
|
| 1810 |
}
|
| 1811 |
|
| 1812 |
// Helpers used when computing which overlapping collapsed span
|
| 1818 |
// spans is larger (and thus includes the other). Falls back to
|
| 1819 |
// comparing ids when the spans cover exactly the same range.
|
| 1820 |
function compareCollapsedMarkers(a, b) {
|
| 1821 |
+
var lenDiff = a.lines.length - b.lines.length;
|
| 1822 |
if (lenDiff != 0) { return lenDiff }
|
| 1823 |
+
var aPos = a.find(), bPos = b.find();
|
| 1824 |
+
var fromCmp = cmp(aPos.from, bPos.from) || extraLeft(a) - extraLeft(b);
|
| 1825 |
if (fromCmp) { return -fromCmp }
|
| 1826 |
+
var toCmp = cmp(aPos.to, bPos.to) || extraRight(a) - extraRight(b);
|
| 1827 |
if (toCmp) { return toCmp }
|
| 1828 |
return b.id - a.id
|
| 1829 |
}
|
| 1831 |
// Find out whether a line ends or starts in a collapsed span. If
|
| 1832 |
// so, return the marker for that span.
|
| 1833 |
function collapsedSpanAtSide(line, start) {
|
| 1834 |
+
var sps = sawCollapsedSpans && line.markedSpans, found;
|
| 1835 |
if (sps) { for (var sp = (void 0), i = 0; i < sps.length; ++i) {
|
| 1836 |
+
sp = sps[i];
|
| 1837 |
if (sp.marker.collapsed && (start ? sp.from : sp.to) == null &&
|
| 1838 |
(!found || compareCollapsedMarkers(found, sp.marker) < 0))
|
| 1839 |
+
{ found = sp.marker; }
|
| 1840 |
} }
|
| 1841 |
return found
|
| 1842 |
}
|
| 1846 |
// Test whether there exists a collapsed span that partially
|
| 1847 |
// overlaps (covers the start or end, but not both) of a new span.
|
| 1848 |
// Such overlap is not allowed.
|
| 1849 |
+
function conflictingCollapsedRange(doc, lineNo$$1, from, to, marker) {
|
| 1850 |
+
var line = getLine(doc, lineNo$$1);
|
| 1851 |
+
var sps = sawCollapsedSpans && line.markedSpans;
|
| 1852 |
if (sps) { for (var i = 0; i < sps.length; ++i) {
|
| 1853 |
+
var sp = sps[i];
|
| 1854 |
if (!sp.marker.collapsed) { continue }
|
| 1855 |
+
var found = sp.marker.find(0);
|
| 1856 |
+
var fromCmp = cmp(found.from, from) || extraLeft(sp.marker) - extraLeft(marker);
|
| 1857 |
+
var toCmp = cmp(found.to, to) || extraRight(sp.marker) - extraRight(marker);
|
| 1858 |
if (fromCmp >= 0 && toCmp <= 0 || fromCmp <= 0 && toCmp >= 0) { continue }
|
| 1859 |
if (fromCmp <= 0 && (sp.marker.inclusiveRight && marker.inclusiveLeft ? cmp(found.to, from) >= 0 : cmp(found.to, from) > 0) ||
|
| 1860 |
fromCmp >= 0 && (sp.marker.inclusiveRight && marker.inclusiveLeft ? cmp(found.from, to) <= 0 : cmp(found.from, to) < 0))
|
| 1867 |
// visual line. This finds the start of the visual line that the
|
| 1868 |
// given line is part of (usually that is the line itself).
|
| 1869 |
function visualLine(line) {
|
| 1870 |
+
var merged;
|
| 1871 |
while (merged = collapsedSpanAtStart(line))
|
| 1872 |
+
{ line = merged.find(-1, true).line; }
|
| 1873 |
return line
|
| 1874 |
}
|
| 1875 |
|
| 1876 |
function visualLineEnd(line) {
|
| 1877 |
+
var merged;
|
| 1878 |
while (merged = collapsedSpanAtEnd(line))
|
| 1879 |
+
{ line = merged.find(1, true).line; }
|
| 1880 |
return line
|
| 1881 |
}
|
| 1882 |
|
| 1883 |
// Returns an array of logical lines that continue the visual line
|
| 1884 |
// started by the argument, or undefined if there are no such lines.
|
| 1885 |
function visualLineContinued(line) {
|
| 1886 |
+
var merged, lines;
|
| 1887 |
while (merged = collapsedSpanAtEnd(line)) {
|
| 1888 |
line = merged.find(1, true).line
|
| 1889 |
+
;(lines || (lines = [])).push(line);
|
| 1890 |
}
|
| 1891 |
return lines
|
| 1892 |
}
|
| 1894 |
// Get the line number of the start of the visual line that the
|
| 1895 |
// given line number is part of.
|
| 1896 |
function visualLineNo(doc, lineN) {
|
| 1897 |
+
var line = getLine(doc, lineN), vis = visualLine(line);
|
| 1898 |
if (line == vis) { return lineN }
|
| 1899 |
return lineNo(vis)
|
| 1900 |
}
|
| 1903 |
// the given line.
|
| 1904 |
function visualLineEndNo(doc, lineN) {
|
| 1905 |
if (lineN > doc.lastLine()) { return lineN }
|
| 1906 |
+
var line = getLine(doc, lineN), merged;
|
| 1907 |
if (!lineIsHidden(doc, line)) { return lineN }
|
| 1908 |
while (merged = collapsedSpanAtEnd(line))
|
| 1909 |
+
{ line = merged.find(1, true).line; }
|
| 1910 |
return lineNo(line) + 1
|
| 1911 |
}
|
| 1912 |
|
| 1914 |
// are part of a visual line that starts with another line, or when
|
| 1915 |
// they are entirely covered by collapsed, non-widget span.
|
| 1916 |
function lineIsHidden(doc, line) {
|
| 1917 |
+
var sps = sawCollapsedSpans && line.markedSpans;
|
| 1918 |
if (sps) { for (var sp = (void 0), i = 0; i < sps.length; ++i) {
|
| 1919 |
+
sp = sps[i];
|
| 1920 |
if (!sp.marker.collapsed) { continue }
|
| 1921 |
if (sp.from == null) { return true }
|
| 1922 |
if (sp.marker.widgetNode) { continue }
|
| 1926 |
}
|
| 1927 |
function lineIsHiddenInner(doc, line, span) {
|
| 1928 |
if (span.to == null) {
|
| 1929 |
+
var end = span.marker.find(1, true);
|
| 1930 |
return lineIsHiddenInner(doc, end.line, getMarkedSpanFor(end.line.markedSpans, span.marker))
|
| 1931 |
}
|
| 1932 |
if (span.marker.inclusiveRight && span.to == line.text.length)
|
| 1933 |
{ return true }
|
| 1934 |
for (var sp = (void 0), i = 0; i < line.markedSpans.length; ++i) {
|
| 1935 |
+
sp = line.markedSpans[i];
|
| 1936 |
if (sp.marker.collapsed && !sp.marker.widgetNode && sp.from == span.to &&
|
| 1937 |
(sp.to == null || sp.to != span.from) &&
|
| 1938 |
(sp.marker.inclusiveLeft || span.marker.inclusiveRight) &&
|
| 1942 |
|
| 1943 |
// Find the height above the given line.
|
| 1944 |
function heightAtLine(lineObj) {
|
| 1945 |
+
lineObj = visualLine(lineObj);
|
| 1946 |
|
| 1947 |
+
var h = 0, chunk = lineObj.parent;
|
| 1948 |
for (var i = 0; i < chunk.lines.length; ++i) {
|
| 1949 |
+
var line = chunk.lines[i];
|
| 1950 |
if (line == lineObj) { break }
|
| 1951 |
+
else { h += line.height; }
|
| 1952 |
}
|
| 1953 |
for (var p = chunk.parent; p; chunk = p, p = chunk.parent) {
|
| 1954 |
for (var i$1 = 0; i$1 < p.children.length; ++i$1) {
|
| 1955 |
+
var cur = p.children[i$1];
|
| 1956 |
if (cur == chunk) { break }
|
| 1957 |
+
else { h += cur.height; }
|
| 1958 |
}
|
| 1959 |
}
|
| 1960 |
return h
|
| 1965 |
// other lines onto it.
|
| 1966 |
function lineLength(line) {
|
| 1967 |
if (line.height == 0) { return 0 }
|
| 1968 |
+
var len = line.text.length, merged, cur = line;
|
| 1969 |
while (merged = collapsedSpanAtStart(cur)) {
|
| 1970 |
+
var found = merged.find(0, true);
|
| 1971 |
+
cur = found.from.line;
|
| 1972 |
+
len += found.from.ch - found.to.ch;
|
| 1973 |
}
|
| 1974 |
+
cur = line;
|
| 1975 |
while (merged = collapsedSpanAtEnd(cur)) {
|
| 1976 |
+
var found$1 = merged.find(0, true);
|
| 1977 |
+
len -= cur.text.length - found$1.from.ch;
|
| 1978 |
+
cur = found$1.to.line;
|
| 1979 |
+
len += cur.text.length - found$1.to.ch;
|
| 1980 |
}
|
| 1981 |
return len
|
| 1982 |
}
|
| 1983 |
|
| 1984 |
// Find the longest line in the document.
|
| 1985 |
function findMaxLine(cm) {
|
| 1986 |
+
var d = cm.display, doc = cm.doc;
|
| 1987 |
+
d.maxLine = getLine(doc, doc.first);
|
| 1988 |
+
d.maxLineLength = lineLength(d.maxLine);
|
| 1989 |
+
d.maxLineChanged = true;
|
| 1990 |
doc.iter(function (line) {
|
| 1991 |
+
var len = lineLength(line);
|
| 1992 |
if (len > d.maxLineLength) {
|
| 1993 |
+
d.maxLineLength = len;
|
| 1994 |
+
d.maxLine = line;
|
| 1995 |
}
|
| 1996 |
+
});
|
| 1997 |
}
|
| 1998 |
|
| 1999 |
// BIDI HELPERS
|
| 2000 |
|
| 2001 |
function iterateBidiSections(order, from, to, f) {
|
| 2002 |
if (!order) { return f(from, to, "ltr") }
|
| 2003 |
+
var found = false;
|
| 2004 |
for (var i = 0; i < order.length; ++i) {
|
| 2005 |
+
var part = order[i];
|
| 2006 |
if (part.from < to && part.to > from || from == to && part.to == from) {
|
| 2007 |
+
f(Math.max(part.from, from), Math.min(part.to, to), part.level == 1 ? "rtl" : "ltr");
|
| 2008 |
+
found = true;
|
| 2009 |
}
|
| 2010 |
}
|
| 2011 |
+
if (!found) { f(from, to, "ltr"); }
|
| 2012 |
}
|
| 2013 |
|
| 2014 |
+
var bidiOther = null;
|
| 2015 |
function getBidiPartAt(order, ch, sticky) {
|
| 2016 |
+
var found;
|
| 2017 |
+
bidiOther = null;
|
| 2018 |
for (var i = 0; i < order.length; ++i) {
|
| 2019 |
+
var cur = order[i];
|
| 2020 |
if (cur.from < ch && cur.to > ch) { return i }
|
| 2021 |
if (cur.to == ch) {
|
| 2022 |
+
if (cur.from != cur.to && sticky == "before") { found = i; }
|
| 2023 |
+
else { bidiOther = i; }
|
| 2024 |
}
|
| 2025 |
if (cur.from == ch) {
|
| 2026 |
+
if (cur.from != cur.to && sticky != "before") { found = i; }
|
| 2027 |
+
else { bidiOther = i; }
|
| 2028 |
}
|
| 2029 |
}
|
| 2030 |
return found != null ? found : bidiOther
|
| 2055 |
// objects) in the order in which they occur visually.
|
| 2056 |
var bidiOrdering = (function() {
|
| 2057 |
// Character types for codepoints 0 to 0xff
|
| 2058 |
+
var lowTypes = "bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN";
|
| 2059 |
// Character types for codepoints 0x600 to 0x6f9
|
| 2060 |
+
var arabicTypes = "nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";
|
| 2061 |
function charType(code) {
|
| 2062 |
if (code <= 0xf7) { return lowTypes.charAt(code) }
|
| 2063 |
else if (0x590 <= code && code <= 0x5f4) { return "R" }
|
| 2068 |
else { return "L" }
|
| 2069 |
}
|
| 2070 |
|
| 2071 |
+
var bidiRE = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;
|
| 2072 |
+
var isNeutral = /[stwN]/, isStrong = /[LRr]/, countsAsLeft = /[Lb1n]/, countsAsNum = /[1n]/;
|
|
|
|
|
|
|
| 2073 |
|
| 2074 |
function BidiSpan(level, from, to) {
|
| 2075 |
+
this.level = level;
|
| 2076 |
+
this.from = from; this.to = to;
|
| 2077 |
}
|
| 2078 |
|
| 2079 |
+
return function(str, direction) {
|
| 2080 |
+
var outerType = direction == "ltr" ? "L" : "R";
|
| 2081 |
+
|
| 2082 |
+
if (str.length == 0 || direction == "ltr" && !bidiRE.test(str)) { return false }
|
| 2083 |
+
var len = str.length, types = [];
|
| 2084 |
for (var i = 0; i < len; ++i)
|
| 2085 |
+
{ types.push(charType(str.charCodeAt(i))); }
|
| 2086 |
|
| 2087 |
// W1. Examine each non-spacing mark (NSM) in the level run, and
|
| 2088 |
// change the type of the NSM to the type of the previous
|
| 2089 |
// character. If the NSM is at the start of the level run, it will
|
| 2090 |
// get the type of sor.
|
| 2091 |
for (var i$1 = 0, prev = outerType; i$1 < len; ++i$1) {
|
| 2092 |
+
var type = types[i$1];
|
| 2093 |
+
if (type == "m") { types[i$1] = prev; }
|
| 2094 |
+
else { prev = type; }
|
| 2095 |
}
|
| 2096 |
|
| 2097 |
// W2. Search backwards from each instance of a European number
|
| 2100 |
// number.
|
| 2101 |
// W3. Change all ALs to R.
|
| 2102 |
for (var i$2 = 0, cur = outerType; i$2 < len; ++i$2) {
|
| 2103 |
+
var type$1 = types[i$2];
|
| 2104 |
+
if (type$1 == "1" && cur == "r") { types[i$2] = "n"; }
|
| 2105 |
+
else if (isStrong.test(type$1)) { cur = type$1; if (type$1 == "r") { types[i$2] = "R"; } }
|
| 2106 |
}
|
| 2107 |
|
| 2108 |
// W4. A single European separator between two European numbers
|
| 2109 |
// changes to a European number. A single common separator between
|
| 2110 |
// two numbers of the same type changes to that type.
|
| 2111 |
for (var i$3 = 1, prev$1 = types[0]; i$3 < len - 1; ++i$3) {
|
| 2112 |
+
var type$2 = types[i$3];
|
| 2113 |
+
if (type$2 == "+" && prev$1 == "1" && types[i$3+1] == "1") { types[i$3] = "1"; }
|
| 2114 |
else if (type$2 == "," && prev$1 == types[i$3+1] &&
|
| 2115 |
+
(prev$1 == "1" || prev$1 == "n")) { types[i$3] = prev$1; }
|
| 2116 |
+
prev$1 = type$2;
|
| 2117 |
}
|
| 2118 |
|
| 2119 |
// W5. A sequence of European terminators adjacent to European
|
| 2121 |
// W6. Otherwise, separators and terminators change to Other
|
| 2122 |
// Neutral.
|
| 2123 |
for (var i$4 = 0; i$4 < len; ++i$4) {
|
| 2124 |
+
var type$3 = types[i$4];
|
| 2125 |
+
if (type$3 == ",") { types[i$4] = "N"; }
|
| 2126 |
else if (type$3 == "%") {
|
| 2127 |
+
var end = (void 0);
|
| 2128 |
for (end = i$4 + 1; end < len && types[end] == "%"; ++end) {}
|
| 2129 |
+
var replace = (i$4 && types[i$4-1] == "!") || (end < len && types[end] == "1") ? "1" : "N";
|
| 2130 |
+
for (var j = i$4; j < end; ++j) { types[j] = replace; }
|
| 2131 |
+
i$4 = end - 1;
|
| 2132 |
}
|
| 2133 |
}
|
| 2134 |
|
| 2136 |
// until the first strong type (R, L, or sor) is found. If an L is
|
| 2137 |
// found, then change the type of the European number to L.
|
| 2138 |
for (var i$5 = 0, cur$1 = outerType; i$5 < len; ++i$5) {
|
| 2139 |
+
var type$4 = types[i$5];
|
| 2140 |
+
if (cur$1 == "L" && type$4 == "1") { types[i$5] = "L"; }
|
| 2141 |
+
else if (isStrong.test(type$4)) { cur$1 = type$4; }
|
| 2142 |
}
|
| 2143 |
|
| 2144 |
// N1. A sequence of neutrals takes the direction of the
|
| 2149 |
// N2. Any remaining neutrals take the embedding direction.
|
| 2150 |
for (var i$6 = 0; i$6 < len; ++i$6) {
|
| 2151 |
if (isNeutral.test(types[i$6])) {
|
| 2152 |
+
var end$1 = (void 0);
|
| 2153 |
for (end$1 = i$6 + 1; end$1 < len && isNeutral.test(types[end$1]); ++end$1) {}
|
| 2154 |
+
var before = (i$6 ? types[i$6-1] : outerType) == "L";
|
| 2155 |
+
var after = (end$1 < len ? types[end$1] : outerType) == "L";
|
| 2156 |
+
var replace$1 = before == after ? (before ? "L" : "R") : outerType;
|
| 2157 |
+
for (var j$1 = i$6; j$1 < end$1; ++j$1) { types[j$1] = replace$1; }
|
| 2158 |
+
i$6 = end$1 - 1;
|
| 2159 |
}
|
| 2160 |
}
|
| 2161 |
|
| 2164 |
// levels (0, 1, 2) in an implementation that doesn't take
|
| 2165 |
// explicit embedding into account, we can build up the order on
|
| 2166 |
// the fly, without following the level-based algorithm.
|
| 2167 |
+
var order = [], m;
|
| 2168 |
for (var i$7 = 0; i$7 < len;) {
|
| 2169 |
if (countsAsLeft.test(types[i$7])) {
|
| 2170 |
+
var start = i$7;
|
| 2171 |
for (++i$7; i$7 < len && countsAsLeft.test(types[i$7]); ++i$7) {}
|
| 2172 |
+
order.push(new BidiSpan(0, start, i$7));
|
| 2173 |
} else {
|
| 2174 |
+
var pos = i$7, at = order.length;
|
| 2175 |
for (++i$7; i$7 < len && types[i$7] != "L"; ++i$7) {}
|
| 2176 |
for (var j$2 = pos; j$2 < i$7;) {
|
| 2177 |
if (countsAsNum.test(types[j$2])) {
|
| 2178 |
+
if (pos < j$2) { order.splice(at, 0, new BidiSpan(1, pos, j$2)); }
|
| 2179 |
+
var nstart = j$2;
|
| 2180 |
for (++j$2; j$2 < i$7 && countsAsNum.test(types[j$2]); ++j$2) {}
|
| 2181 |
+
order.splice(at, 0, new BidiSpan(2, nstart, j$2));
|
| 2182 |
+
pos = j$2;
|
| 2183 |
+
} else { ++j$2; }
|
| 2184 |
}
|
| 2185 |
+
if (pos < i$7) { order.splice(at, 0, new BidiSpan(1, pos, i$7)); }
|
| 2186 |
}
|
| 2187 |
}
|
| 2188 |
if (order[0].level == 1 && (m = str.match(/^\s+/))) {
|
| 2189 |
+
order[0].from = m[0].length;
|
| 2190 |
+
order.unshift(new BidiSpan(0, 0, m[0].length));
|
| 2191 |
}
|
| 2192 |
if (lst(order).level == 1 && (m = str.match(/\s+$/))) {
|
| 2193 |
+
lst(order).to -= m[0].length;
|
| 2194 |
+
order.push(new BidiSpan(0, len - m[0].length, len));
|
| 2195 |
}
|
| 2196 |
|
| 2197 |
+
return direction == "rtl" ? order.reverse() : order
|
| 2198 |
}
|
| 2199 |
+
})();
|
| 2200 |
|
| 2201 |
// Get the bidi ordering for the given line (and cache it). Returns
|
| 2202 |
// false for lines that are fully left-to-right, and an array of
|
| 2203 |
// BidiSpan objects otherwise.
|
| 2204 |
+
function getOrder(line, direction) {
|
| 2205 |
+
var order = line.order;
|
| 2206 |
+
if (order == null) { order = line.order = bidiOrdering(line.text, direction); }
|
| 2207 |
return order
|
| 2208 |
}
|
| 2209 |
|
| 2210 |
function moveCharLogically(line, ch, dir) {
|
| 2211 |
+
var target = skipExtendingChars(line.text, ch + dir, dir);
|
| 2212 |
return target < 0 || target > line.text.length ? null : target
|
| 2213 |
}
|
| 2214 |
|
| 2215 |
function moveLogically(line, start, dir) {
|
| 2216 |
+
var ch = moveCharLogically(line, start.ch, dir);
|
| 2217 |
return ch == null ? null : new Pos(start.line, ch, dir < 0 ? "after" : "before")
|
| 2218 |
}
|
| 2219 |
|
| 2220 |
function endOfLine(visually, cm, lineObj, lineNo, dir) {
|
| 2221 |
if (visually) {
|
| 2222 |
+
var order = getOrder(lineObj, cm.doc.direction);
|
| 2223 |
if (order) {
|
| 2224 |
+
var part = dir < 0 ? lst(order) : order[0];
|
| 2225 |
+
var moveInStorageOrder = (dir < 0) == (part.level == 1);
|
| 2226 |
+
var sticky = moveInStorageOrder ? "after" : "before";
|
| 2227 |
+
var ch;
|
| 2228 |
// With a wrapped rtl chunk (possibly spanning multiple bidi parts),
|
| 2229 |
// it could be that the last bidi part is not on the last visual line,
|
| 2230 |
// since visual lines contain content order-consecutive chunks.
|
| 2232 |
// in the rtl chunk that is on the last line (that is, the same line
|
| 2233 |
// as the last (content-order) character).
|
| 2234 |
if (part.level > 0) {
|
| 2235 |
+
var prep = prepareMeasureForLine(cm, lineObj);
|
| 2236 |
+
ch = dir < 0 ? lineObj.text.length - 1 : 0;
|
| 2237 |
+
var targetTop = measureCharPrepared(cm, prep, ch).top;
|
| 2238 |
+
ch = findFirst(function (ch) { return measureCharPrepared(cm, prep, ch).top == targetTop; }, (dir < 0) == (part.level == 1) ? part.from : part.to - 1, ch);
|
| 2239 |
+
if (sticky == "before") { ch = moveCharLogically(lineObj, ch, 1, true); }
|
| 2240 |
+
} else { ch = dir < 0 ? part.to : part.from; }
|
| 2241 |
return new Pos(lineNo, ch, sticky)
|
| 2242 |
}
|
| 2243 |
}
|
| 2245 |
}
|
| 2246 |
|
| 2247 |
function moveVisually(cm, line, start, dir) {
|
| 2248 |
+
var bidi = getOrder(line, cm.doc.direction);
|
| 2249 |
if (!bidi) { return moveLogically(line, start, dir) }
|
| 2250 |
if (start.ch >= line.text.length) {
|
| 2251 |
+
start.ch = line.text.length;
|
| 2252 |
+
start.sticky = "before";
|
| 2253 |
} else if (start.ch <= 0) {
|
| 2254 |
+
start.ch = 0;
|
| 2255 |
+
start.sticky = "after";
|
| 2256 |
}
|
| 2257 |
+
var partPos = getBidiPartAt(bidi, start.ch, start.sticky), part = bidi[partPos];
|
| 2258 |
+
if (cm.doc.direction == "ltr" && part.level % 2 == 0 && (dir > 0 ? part.to > start.ch : part.from < start.ch)) {
|
| 2259 |
+
// Case 1: We move within an ltr part in an ltr editor. Even with wrapped lines,
|
| 2260 |
// nothing interesting happens.
|
| 2261 |
return moveLogically(line, start, dir)
|
| 2262 |
}
|
| 2263 |
|
| 2264 |
+
var mv = function (pos, dir) { return moveCharLogically(line, pos instanceof Pos ? pos.ch : pos, dir); };
|
| 2265 |
+
var prep;
|
| 2266 |
var getWrappedLineExtent = function (ch) {
|
| 2267 |
if (!cm.options.lineWrapping) { return {begin: 0, end: line.text.length} }
|
| 2268 |
+
prep = prep || prepareMeasureForLine(cm, line);
|
| 2269 |
return wrappedLineExtentChar(cm, line, prep, ch)
|
| 2270 |
+
};
|
| 2271 |
+
var wrappedLineExtent = getWrappedLineExtent(start.sticky == "before" ? mv(start, -1) : start.ch);
|
| 2272 |
+
|
| 2273 |
+
if (cm.doc.direction == "rtl" || part.level == 1) {
|
| 2274 |
+
var moveInStorageOrder = (part.level == 1) == (dir < 0);
|
| 2275 |
+
var ch = mv(start, moveInStorageOrder ? 1 : -1);
|
| 2276 |
+
if (ch != null && (!moveInStorageOrder ? ch >= part.from && ch >= wrappedLineExtent.begin : ch <= part.to && ch <= wrappedLineExtent.end)) {
|
| 2277 |
+
// Case 2: We move within an rtl part or in an rtl editor on the same visual line
|
| 2278 |
+
var sticky = moveInStorageOrder ? "before" : "after";
|
| 2279 |
return new Pos(start.line, ch, sticky)
|
| 2280 |
}
|
| 2281 |
}
|
| 2286 |
var searchInVisualLine = function (partPos, dir, wrappedLineExtent) {
|
| 2287 |
var getRes = function (ch, moveInStorageOrder) { return moveInStorageOrder
|
| 2288 |
? new Pos(start.line, mv(ch, 1), "before")
|
| 2289 |
+
: new Pos(start.line, ch, "after"); };
|
| 2290 |
|
| 2291 |
for (; partPos >= 0 && partPos < bidi.length; partPos += dir) {
|
| 2292 |
+
var part = bidi[partPos];
|
| 2293 |
+
var moveInStorageOrder = (dir > 0) == (part.level != 1);
|
| 2294 |
+
var ch = moveInStorageOrder ? wrappedLineExtent.begin : mv(wrappedLineExtent.end, -1);
|
| 2295 |
if (part.from <= ch && ch < part.to) { return getRes(ch, moveInStorageOrder) }
|
| 2296 |
+
ch = moveInStorageOrder ? part.from : mv(part.to, -1);
|
| 2297 |
if (wrappedLineExtent.begin <= ch && ch < wrappedLineExtent.end) { return getRes(ch, moveInStorageOrder) }
|
| 2298 |
}
|
| 2299 |
+
};
|
| 2300 |
|
| 2301 |
// Case 3a: Look for other bidi parts on the same visual line
|
| 2302 |
+
var res = searchInVisualLine(partPos + dir, dir, wrappedLineExtent);
|
| 2303 |
if (res) { return res }
|
| 2304 |
|
| 2305 |
// Case 3b: Look for other bidi parts on the next visual line
|
| 2306 |
+
var nextCh = dir > 0 ? wrappedLineExtent.end : mv(wrappedLineExtent.begin, -1);
|
| 2307 |
if (nextCh != null && !(dir > 0 && nextCh == line.text.length)) {
|
| 2308 |
+
res = searchInVisualLine(dir > 0 ? 0 : bidi.length - 1, dir, getWrappedLineExtent(nextCh));
|
| 2309 |
if (res) { return res }
|
| 2310 |
}
|
| 2311 |
|
| 2318 |
// Lightweight event framework. on/off also work on DOM nodes,
|
| 2319 |
// registering native DOM handlers.
|
| 2320 |
|
| 2321 |
+
var noHandlers = [];
|
| 2322 |
|
| 2323 |
var on = function(emitter, type, f) {
|
| 2324 |
if (emitter.addEventListener) {
|
| 2325 |
+
emitter.addEventListener(type, f, false);
|
| 2326 |
} else if (emitter.attachEvent) {
|
| 2327 |
+
emitter.attachEvent("on" + type, f);
|
| 2328 |
} else {
|
| 2329 |
+
var map$$1 = emitter._handlers || (emitter._handlers = {});
|
| 2330 |
+
map$$1[type] = (map$$1[type] || noHandlers).concat(f);
|
| 2331 |
}
|
| 2332 |
+
};
|
| 2333 |
|
| 2334 |
function getHandlers(emitter, type) {
|
| 2335 |
return emitter._handlers && emitter._handlers[type] || noHandlers
|
| 2337 |
|
| 2338 |
function off(emitter, type, f) {
|
| 2339 |
if (emitter.removeEventListener) {
|
| 2340 |
+
emitter.removeEventListener(type, f, false);
|
| 2341 |
} else if (emitter.detachEvent) {
|
| 2342 |
+
emitter.detachEvent("on" + type, f);
|
| 2343 |
} else {
|
| 2344 |
+
var map$$1 = emitter._handlers, arr = map$$1 && map$$1[type];
|
| 2345 |
if (arr) {
|
| 2346 |
+
var index = indexOf(arr, f);
|
| 2347 |
if (index > -1)
|
| 2348 |
+
{ map$$1[type] = arr.slice(0, index).concat(arr.slice(index + 1)); }
|
| 2349 |
}
|
| 2350 |
}
|
| 2351 |
}
|
| 2352 |
|
| 2353 |
function signal(emitter, type /*, values...*/) {
|
| 2354 |
+
var handlers = getHandlers(emitter, type);
|
| 2355 |
if (!handlers.length) { return }
|
| 2356 |
+
var args = Array.prototype.slice.call(arguments, 2);
|
| 2357 |
+
for (var i = 0; i < handlers.length; ++i) { handlers[i].apply(null, args); }
|
| 2358 |
}
|
| 2359 |
|
| 2360 |
// The DOM events that CodeMirror handles can be overridden by
|
| 2362 |
// and preventDefault-ing the event in that handler.
|
| 2363 |
function signalDOMEvent(cm, e, override) {
|
| 2364 |
if (typeof e == "string")
|
| 2365 |
+
{ e = {type: e, preventDefault: function() { this.defaultPrevented = true; }}; }
|
| 2366 |
+
signal(cm, override || e.type, cm, e);
|
| 2367 |
return e_defaultPrevented(e) || e.codemirrorIgnore
|
| 2368 |
}
|
| 2369 |
|
| 2370 |
function signalCursorActivity(cm) {
|
| 2371 |
+
var arr = cm._handlers && cm._handlers.cursorActivity;
|
| 2372 |
if (!arr) { return }
|
| 2373 |
+
var set = cm.curOp.cursorActivityHandlers || (cm.curOp.cursorActivityHandlers = []);
|
| 2374 |
for (var i = 0; i < arr.length; ++i) { if (indexOf(set, arr[i]) == -1)
|
| 2375 |
+
{ set.push(arr[i]); } }
|
| 2376 |
}
|
| 2377 |
|
| 2378 |
function hasHandler(emitter, type) {
|
| 2382 |
// Add on and off methods to a constructor's prototype, to make
|
| 2383 |
// registering events on such objects more convenient.
|
| 2384 |
function eventMixin(ctor) {
|
| 2385 |
+
ctor.prototype.on = function(type, f) {on(this, type, f);};
|
| 2386 |
+
ctor.prototype.off = function(type, f) {off(this, type, f);};
|
| 2387 |
}
|
| 2388 |
|
| 2389 |
// Due to the fact that we still support jurassic IE versions, some
|
| 2390 |
// compatibility wrappers are needed.
|
| 2391 |
|
| 2392 |
function e_preventDefault(e) {
|
| 2393 |
+
if (e.preventDefault) { e.preventDefault(); }
|
| 2394 |
+
else { e.returnValue = false; }
|
| 2395 |
}
|
| 2396 |
function e_stopPropagation(e) {
|
| 2397 |
+
if (e.stopPropagation) { e.stopPropagation(); }
|
| 2398 |
+
else { e.cancelBubble = true; }
|
| 2399 |
}
|
| 2400 |
function e_defaultPrevented(e) {
|
| 2401 |
return e.defaultPrevented != null ? e.defaultPrevented : e.returnValue == false
|
| 2402 |
}
|
| 2403 |
+
function e_stop(e) {e_preventDefault(e); e_stopPropagation(e);}
|
| 2404 |
|
| 2405 |
function e_target(e) {return e.target || e.srcElement}
|
| 2406 |
function e_button(e) {
|
| 2407 |
+
var b = e.which;
|
| 2408 |
if (b == null) {
|
| 2409 |
+
if (e.button & 1) { b = 1; }
|
| 2410 |
+
else if (e.button & 2) { b = 3; }
|
| 2411 |
+
else if (e.button & 4) { b = 2; }
|
| 2412 |
}
|
| 2413 |
+
if (mac && e.ctrlKey && b == 1) { b = 3; }
|
| 2414 |
return b
|
| 2415 |
}
|
| 2416 |
|
| 2419 |
// There is *some* kind of drag-and-drop support in IE6-8, but I
|
| 2420 |
// couldn't get it to work yet.
|
| 2421 |
if (ie && ie_version < 9) { return false }
|
| 2422 |
+
var div = elt('div');
|
| 2423 |
return "draggable" in div || "dragDrop" in div
|
| 2424 |
+
}();
|
| 2425 |
|
| 2426 |
+
var zwspSupported;
|
| 2427 |
function zeroWidthElement(measure) {
|
| 2428 |
if (zwspSupported == null) {
|
| 2429 |
+
var test = elt("span", "\u200b");
|
| 2430 |
+
removeChildrenAndAdd(measure, elt("span", [test, document.createTextNode("x")]));
|
| 2431 |
if (measure.firstChild.offsetHeight != 0)
|
| 2432 |
+
{ zwspSupported = test.offsetWidth <= 1 && test.offsetHeight > 2 && !(ie && ie_version < 8); }
|
| 2433 |
}
|
| 2434 |
var node = zwspSupported ? elt("span", "\u200b") :
|
| 2435 |
+
elt("span", "\u00a0", null, "display: inline-block; width: 1px; margin-right: -1px");
|
| 2436 |
+
node.setAttribute("cm-text", "");
|
| 2437 |
return node
|
| 2438 |
}
|
| 2439 |
|
| 2440 |
// Feature-detect IE's crummy client rect reporting for bidi text
|
| 2441 |
+
var badBidiRects;
|
| 2442 |
function hasBadBidiRects(measure) {
|
| 2443 |
if (badBidiRects != null) { return badBidiRects }
|
| 2444 |
+
var txt = removeChildrenAndAdd(measure, document.createTextNode("A\u062eA"));
|
| 2445 |
+
var r0 = range(txt, 0, 1).getBoundingClientRect();
|
| 2446 |
+
var r1 = range(txt, 1, 2).getBoundingClientRect();
|
| 2447 |
+
removeChildren(measure);
|
| 2448 |
if (!r0 || r0.left == r0.right) { return false } // Safari returns null in some cases (#2780)
|
| 2449 |
return badBidiRects = (r1.right - r0.right < 3)
|
| 2450 |
}
|
| 2452 |
// See if "".split is the broken IE version, if so, provide an
|
| 2453 |
// alternative way to split lines.
|
| 2454 |
var splitLinesAuto = "\n\nb".split(/\n/).length != 3 ? function (string) {
|
| 2455 |
+
var pos = 0, result = [], l = string.length;
|
| 2456 |
while (pos <= l) {
|
| 2457 |
+
var nl = string.indexOf("\n", pos);
|
| 2458 |
+
if (nl == -1) { nl = string.length; }
|
| 2459 |
+
var line = string.slice(pos, string.charAt(nl - 1) == "\r" ? nl - 1 : nl);
|
| 2460 |
+
var rt = line.indexOf("\r");
|
| 2461 |
if (rt != -1) {
|
| 2462 |
+
result.push(line.slice(0, rt));
|
| 2463 |
+
pos += rt + 1;
|
| 2464 |
} else {
|
| 2465 |
+
result.push(line);
|
| 2466 |
+
pos = nl + 1;
|
| 2467 |
}
|
| 2468 |
}
|
| 2469 |
return result
|
| 2470 |
+
} : function (string) { return string.split(/\r\n?|\n/); };
|
| 2471 |
|
| 2472 |
var hasSelection = window.getSelection ? function (te) {
|
| 2473 |
try { return te.selectionStart != te.selectionEnd }
|
| 2474 |
catch(e) { return false }
|
| 2475 |
} : function (te) {
|
| 2476 |
+
var range$$1;
|
| 2477 |
+
try {range$$1 = te.ownerDocument.selection.createRange();}
|
| 2478 |
catch(e) {}
|
| 2479 |
+
if (!range$$1 || range$$1.parentElement() != te) { return false }
|
| 2480 |
+
return range$$1.compareEndPoints("StartToEnd", range$$1) != 0
|
| 2481 |
+
};
|
| 2482 |
|
| 2483 |
var hasCopyEvent = (function () {
|
| 2484 |
+
var e = elt("div");
|
| 2485 |
if ("oncopy" in e) { return true }
|
| 2486 |
+
e.setAttribute("oncopy", "return;");
|
| 2487 |
return typeof e.oncopy == "function"
|
| 2488 |
+
})();
|
| 2489 |
|
| 2490 |
+
var badZoomedRects = null;
|
| 2491 |
function hasBadZoomedRects(measure) {
|
| 2492 |
if (badZoomedRects != null) { return badZoomedRects }
|
| 2493 |
+
var node = removeChildrenAndAdd(measure, elt("span", "x"));
|
| 2494 |
+
var normal = node.getBoundingClientRect();
|
| 2495 |
+
var fromRange = range(node, 0, 1).getBoundingClientRect();
|
| 2496 |
return badZoomedRects = Math.abs(normal.left - fromRange.left) > 1
|
| 2497 |
}
|
| 2498 |
|
| 2499 |
+
// Known modes, by name and by MIME
|
| 2500 |
var modes = {};
|
| 2501 |
var mimeModes = {};
|
| 2502 |
+
|
| 2503 |
// Extra arguments are stored as the mode's dependencies, which is
|
| 2504 |
// used by (legacy) mechanisms like loadmode.js to automatically
|
| 2505 |
// load a mode. (Preferred mechanism is the require/define calls.)
|
| 2506 |
function defineMode(name, mode) {
|
| 2507 |
if (arguments.length > 2)
|
| 2508 |
+
{ mode.dependencies = Array.prototype.slice.call(arguments, 2); }
|
| 2509 |
+
modes[name] = mode;
|
| 2510 |
}
|
| 2511 |
|
| 2512 |
function defineMIME(mime, spec) {
|
| 2513 |
+
mimeModes[mime] = spec;
|
| 2514 |
}
|
| 2515 |
|
| 2516 |
// Given a MIME type, a {name, ...options} config object, or a name
|
| 2517 |
// string, return a mode config object.
|
| 2518 |
function resolveMode(spec) {
|
| 2519 |
if (typeof spec == "string" && mimeModes.hasOwnProperty(spec)) {
|
| 2520 |
+
spec = mimeModes[spec];
|
| 2521 |
} else if (spec && typeof spec.name == "string" && mimeModes.hasOwnProperty(spec.name)) {
|
| 2522 |
+
var found = mimeModes[spec.name];
|
| 2523 |
+
if (typeof found == "string") { found = {name: found}; }
|
| 2524 |
+
spec = createObj(found, spec);
|
| 2525 |
+
spec.name = found.name;
|
| 2526 |
} else if (typeof spec == "string" && /^[\w\-]+\/[\w\-]+\+xml$/.test(spec)) {
|
| 2527 |
return resolveMode("application/xml")
|
| 2528 |
} else if (typeof spec == "string" && /^[\w\-]+\/[\w\-]+\+json$/.test(spec)) {
|
| 2535 |
// Given a mode spec (anything that resolveMode accepts), find and
|
| 2536 |
// initialize an actual mode object.
|
| 2537 |
function getMode(options, spec) {
|
| 2538 |
+
spec = resolveMode(spec);
|
| 2539 |
+
var mfactory = modes[spec.name];
|
| 2540 |
if (!mfactory) { return getMode(options, "text/plain") }
|
| 2541 |
+
var modeObj = mfactory(options, spec);
|
| 2542 |
if (modeExtensions.hasOwnProperty(spec.name)) {
|
| 2543 |
+
var exts = modeExtensions[spec.name];
|
| 2544 |
for (var prop in exts) {
|
| 2545 |
if (!exts.hasOwnProperty(prop)) { continue }
|
| 2546 |
+
if (modeObj.hasOwnProperty(prop)) { modeObj["_" + prop] = modeObj[prop]; }
|
| 2547 |
+
modeObj[prop] = exts[prop];
|
| 2548 |
}
|
| 2549 |
}
|
| 2550 |
+
modeObj.name = spec.name;
|
| 2551 |
+
if (spec.helperType) { modeObj.helperType = spec.helperType; }
|
| 2552 |
if (spec.modeProps) { for (var prop$1 in spec.modeProps)
|
| 2553 |
+
{ modeObj[prop$1] = spec.modeProps[prop$1]; } }
|
| 2554 |
|
| 2555 |
return modeObj
|
| 2556 |
}
|
| 2557 |
|
| 2558 |
// This can be used to attach properties to mode objects from
|
| 2559 |
// outside the actual mode definition.
|
| 2560 |
+
var modeExtensions = {};
|
| 2561 |
function extendMode(mode, properties) {
|
| 2562 |
+
var exts = modeExtensions.hasOwnProperty(mode) ? modeExtensions[mode] : (modeExtensions[mode] = {});
|
| 2563 |
+
copyObj(properties, exts);
|
| 2564 |
}
|
| 2565 |
|
| 2566 |
function copyState(mode, state) {
|
| 2567 |
if (state === true) { return state }
|
| 2568 |
if (mode.copyState) { return mode.copyState(state) }
|
| 2569 |
+
var nstate = {};
|
| 2570 |
for (var n in state) {
|
| 2571 |
+
var val = state[n];
|
| 2572 |
+
if (val instanceof Array) { val = val.concat([]); }
|
| 2573 |
+
nstate[n] = val;
|
| 2574 |
}
|
| 2575 |
return nstate
|
| 2576 |
}
|
| 2578 |
// Given a mode and a state (for that mode), find the inner mode and
|
| 2579 |
// state at the position that the state refers to.
|
| 2580 |
function innerMode(mode, state) {
|
| 2581 |
+
var info;
|
| 2582 |
while (mode.innerMode) {
|
| 2583 |
+
info = mode.innerMode(state);
|
| 2584 |
if (!info || info.mode == mode) { break }
|
| 2585 |
+
state = info.state;
|
| 2586 |
+
mode = info.mode;
|
| 2587 |
}
|
| 2588 |
return info || {mode: mode, state: state}
|
| 2589 |
}
|
| 2598 |
// parsers more succinct.
|
| 2599 |
|
| 2600 |
var StringStream = function(string, tabSize) {
|
| 2601 |
+
this.pos = this.start = 0;
|
| 2602 |
+
this.string = string;
|
| 2603 |
+
this.tabSize = tabSize || 8;
|
| 2604 |
+
this.lastColumnPos = this.lastColumnValue = 0;
|
| 2605 |
+
this.lineStart = 0;
|
| 2606 |
};
|
| 2607 |
|
| 2608 |
StringStream.prototype.eol = function () {return this.pos >= this.string.length};
|
| 2613 |
{ return this.string.charAt(this.pos++) }
|
| 2614 |
};
|
| 2615 |
StringStream.prototype.eat = function (match) {
|
| 2616 |
+
var ch = this.string.charAt(this.pos);
|
| 2617 |
+
var ok;
|
| 2618 |
+
if (typeof match == "string") { ok = ch == match; }
|
| 2619 |
+
else { ok = ch && (match.test ? match.test(ch) : match(ch)); }
|
| 2620 |
if (ok) {++this.pos; return ch}
|
| 2621 |
};
|
| 2622 |
StringStream.prototype.eatWhile = function (match) {
|
| 2623 |
+
var start = this.pos;
|
| 2624 |
while (this.eat(match)){}
|
| 2625 |
return this.pos > start
|
| 2626 |
};
|
| 2627 |
StringStream.prototype.eatSpace = function () {
|
| 2628 |
var this$1 = this;
|
| 2629 |
|
| 2630 |
+
var start = this.pos;
|
| 2631 |
+
while (/[\s\u00a0]/.test(this.string.charAt(this.pos))) { ++this$1.pos; }
|
| 2632 |
return this.pos > start
|
| 2633 |
};
|
| 2634 |
+
StringStream.prototype.skipToEnd = function () {this.pos = this.string.length;};
|
| 2635 |
StringStream.prototype.skipTo = function (ch) {
|
| 2636 |
+
var found = this.string.indexOf(ch, this.pos);
|
| 2637 |
if (found > -1) {this.pos = found; return true}
|
| 2638 |
};
|
| 2639 |
+
StringStream.prototype.backUp = function (n) {this.pos -= n;};
|
| 2640 |
StringStream.prototype.column = function () {
|
| 2641 |
if (this.lastColumnPos < this.start) {
|
| 2642 |
+
this.lastColumnValue = countColumn(this.string, this.start, this.tabSize, this.lastColumnPos, this.lastColumnValue);
|
| 2643 |
+
this.lastColumnPos = this.start;
|
| 2644 |
}
|
| 2645 |
return this.lastColumnValue - (this.lineStart ? countColumn(this.string, this.lineStart, this.tabSize) : 0)
|
| 2646 |
};
|
| 2650 |
};
|
| 2651 |
StringStream.prototype.match = function (pattern, consume, caseInsensitive) {
|
| 2652 |
if (typeof pattern == "string") {
|
| 2653 |
+
var cased = function (str) { return caseInsensitive ? str.toLowerCase() : str; };
|
| 2654 |
+
var substr = this.string.substr(this.pos, pattern.length);
|
| 2655 |
if (cased(substr) == cased(pattern)) {
|
| 2656 |
+
if (consume !== false) { this.pos += pattern.length; }
|
| 2657 |
return true
|
| 2658 |
}
|
| 2659 |
} else {
|
| 2660 |
+
var match = this.string.slice(this.pos).match(pattern);
|
| 2661 |
if (match && match.index > 0) { return null }
|
| 2662 |
+
if (match && consume !== false) { this.pos += match[0].length; }
|
| 2663 |
return match
|
| 2664 |
}
|
| 2665 |
};
|
| 2666 |
StringStream.prototype.current = function (){return this.string.slice(this.start, this.pos)};
|
| 2667 |
StringStream.prototype.hideFirstChars = function (n, inner) {
|
| 2668 |
+
this.lineStart += n;
|
| 2669 |
try { return inner() }
|
| 2670 |
+
finally { this.lineStart -= n; }
|
| 2671 |
};
|
| 2672 |
|
| 2673 |
// Compute a style array (an array starting with a mode generation
|
| 2677 |
function highlightLine(cm, line, state, forceToEnd) {
|
| 2678 |
// A styles array always starts with a number identifying the
|
| 2679 |
// mode/overlays that it is based on (for easy invalidation).
|
| 2680 |
+
var st = [cm.state.modeGen], lineClasses = {};
|
| 2681 |
// Compute the base array of styles
|
| 2682 |
runMode(cm, line.text, cm.doc.mode, state, function (end, style) { return st.push(end, style); },
|
| 2683 |
+
lineClasses, forceToEnd);
|
| 2684 |
|
| 2685 |
// Run overlays, adjust style array.
|
| 2686 |
var loop = function ( o ) {
|
| 2687 |
+
var overlay = cm.state.overlays[o], i = 1, at = 0;
|
| 2688 |
runMode(cm, line.text, overlay.mode, true, function (end, style) {
|
| 2689 |
+
var start = i;
|
| 2690 |
// Ensure there's a token end at the current position, and that i points at it
|
| 2691 |
while (at < end) {
|
| 2692 |
+
var i_end = st[i];
|
| 2693 |
if (i_end > end)
|
| 2694 |
+
{ st.splice(i, 1, end, st[i+1], i_end); }
|
| 2695 |
+
i += 2;
|
| 2696 |
+
at = Math.min(end, i_end);
|
| 2697 |
}
|
| 2698 |
if (!style) { return }
|
| 2699 |
if (overlay.opaque) {
|
| 2700 |
+
st.splice(start, i - start, end, "overlay " + style);
|
| 2701 |
+
i = start + 2;
|
| 2702 |
} else {
|
| 2703 |
for (; start < i; start += 2) {
|
| 2704 |
+
var cur = st[start+1];
|
| 2705 |
+
st[start+1] = (cur ? cur + " " : "") + "overlay " + style;
|
| 2706 |
}
|
| 2707 |
}
|
| 2708 |
+
}, lineClasses);
|
| 2709 |
};
|
| 2710 |
|
| 2711 |
for (var o = 0; o < cm.state.overlays.length; ++o) loop( o );
|
| 2715 |
|
| 2716 |
function getLineStyles(cm, line, updateFrontier) {
|
| 2717 |
if (!line.styles || line.styles[0] != cm.state.modeGen) {
|
| 2718 |
+
var state = getStateBefore(cm, lineNo(line));
|
| 2719 |
+
var result = highlightLine(cm, line, line.text.length > cm.options.maxHighlightLength ? copyState(cm.doc.mode, state) : state);
|
| 2720 |
+
line.stateAfter = state;
|
| 2721 |
+
line.styles = result.styles;
|
| 2722 |
+
if (result.classes) { line.styleClasses = result.classes; }
|
| 2723 |
+
else if (line.styleClasses) { line.styleClasses = null; }
|
| 2724 |
+
if (updateFrontier === cm.doc.frontier) { cm.doc.frontier++; }
|
| 2725 |
}
|
| 2726 |
return line.styles
|
| 2727 |
}
|
| 2728 |
|
| 2729 |
function getStateBefore(cm, n, precise) {
|
| 2730 |
+
var doc = cm.doc, display = cm.display;
|
| 2731 |
if (!doc.mode.startState) { return true }
|
| 2732 |
+
var pos = findStartLine(cm, n, precise), state = pos > doc.first && getLine(doc, pos-1).stateAfter;
|
| 2733 |
+
if (!state) { state = startState(doc.mode); }
|
| 2734 |
+
else { state = copyState(doc.mode, state); }
|
| 2735 |
doc.iter(pos, n, function (line) {
|
| 2736 |
+
processLine(cm, line.text, state);
|
| 2737 |
+
var save = pos == n - 1 || pos % 5 == 0 || pos >= display.viewFrom && pos < display.viewTo;
|
| 2738 |
+
line.stateAfter = save ? copyState(doc.mode, state) : null;
|
| 2739 |
+
++pos;
|
| 2740 |
+
});
|
| 2741 |
+
if (precise) { doc.frontier = pos; }
|
| 2742 |
return state
|
| 2743 |
}
|
| 2744 |
|
| 2746 |
// update state, but don't save a style array. Used for lines that
|
| 2747 |
// aren't currently visible.
|
| 2748 |
function processLine(cm, text, state, startAt) {
|
| 2749 |
+
var mode = cm.doc.mode;
|
| 2750 |
+
var stream = new StringStream(text, cm.options.tabSize);
|
| 2751 |
+
stream.start = stream.pos = startAt || 0;
|
| 2752 |
+
if (text == "") { callBlankLine(mode, state); }
|
| 2753 |
while (!stream.eol()) {
|
| 2754 |
+
readToken(mode, stream, state);
|
| 2755 |
+
stream.start = stream.pos;
|
| 2756 |
}
|
| 2757 |
}
|
| 2758 |
|
| 2759 |
function callBlankLine(mode, state) {
|
| 2760 |
if (mode.blankLine) { return mode.blankLine(state) }
|
| 2761 |
if (!mode.innerMode) { return }
|
| 2762 |
+
var inner = innerMode(mode, state);
|
| 2763 |
if (inner.mode.blankLine) { return inner.mode.blankLine(inner.state) }
|
| 2764 |
}
|
| 2765 |
|
| 2766 |
function readToken(mode, stream, state, inner) {
|
| 2767 |
for (var i = 0; i < 10; i++) {
|
| 2768 |
+
if (inner) { inner[0] = innerMode(mode, state).mode; }
|
| 2769 |
+
var style = mode.token(stream, state);
|
| 2770 |
if (stream.pos > stream.start) { return style }
|
| 2771 |
}
|
| 2772 |
throw new Error("Mode " + mode.name + " failed to advance stream.")
|
| 2779 |
string: stream.current(),
|
| 2780 |
type: style || null,
|
| 2781 |
state: copy ? copyState(doc.mode, state) : state
|
| 2782 |
+
}); };
|
| 2783 |
|
| 2784 |
+
var doc = cm.doc, mode = doc.mode, style;
|
| 2785 |
+
pos = clipPos(doc, pos);
|
| 2786 |
+
var line = getLine(doc, pos.line), state = getStateBefore(cm, pos.line, precise);
|
| 2787 |
+
var stream = new StringStream(line.text, cm.options.tabSize), tokens;
|
| 2788 |
+
if (asArray) { tokens = []; }
|
| 2789 |
while ((asArray || stream.pos < pos.ch) && !stream.eol()) {
|
| 2790 |
+
stream.start = stream.pos;
|
| 2791 |
+
style = readToken(mode, stream, state);
|
| 2792 |
+
if (asArray) { tokens.push(getObj(true)); }
|
| 2793 |
}
|
| 2794 |
return asArray ? tokens : getObj()
|
| 2795 |
}
|
| 2796 |
|
| 2797 |
function extractLineClasses(type, output) {
|
| 2798 |
if (type) { for (;;) {
|
| 2799 |
+
var lineClass = type.match(/(?:^|\s+)line-(background-)?(\S+)/);
|
| 2800 |
if (!lineClass) { break }
|
| 2801 |
+
type = type.slice(0, lineClass.index) + type.slice(lineClass.index + lineClass[0].length);
|
| 2802 |
+
var prop = lineClass[1] ? "bgClass" : "textClass";
|
| 2803 |
if (output[prop] == null)
|
| 2804 |
+
{ output[prop] = lineClass[2]; }
|
| 2805 |
else if (!(new RegExp("(?:^|\s)" + lineClass[2] + "(?:$|\s)")).test(output[prop]))
|
| 2806 |
+
{ output[prop] += " " + lineClass[2]; }
|
| 2807 |
} }
|
| 2808 |
return type
|
| 2809 |
}
|
| 2810 |
|
| 2811 |
// Run the given mode's parser over a line, calling f for each token.
|
| 2812 |
function runMode(cm, text, mode, state, f, lineClasses, forceToEnd) {
|
| 2813 |
+
var flattenSpans = mode.flattenSpans;
|
| 2814 |
+
if (flattenSpans == null) { flattenSpans = cm.options.flattenSpans; }
|
| 2815 |
+
var curStart = 0, curStyle = null;
|
| 2816 |
+
var stream = new StringStream(text, cm.options.tabSize), style;
|
| 2817 |
+
var inner = cm.options.addModeClass && [null];
|
| 2818 |
+
if (text == "") { extractLineClasses(callBlankLine(mode, state), lineClasses); }
|
| 2819 |
while (!stream.eol()) {
|
| 2820 |
if (stream.pos > cm.options.maxHighlightLength) {
|
| 2821 |
+
flattenSpans = false;
|
| 2822 |
+
if (forceToEnd) { processLine(cm, text, state, stream.pos); }
|
| 2823 |
+
stream.pos = text.length;
|
| 2824 |
+
style = null;
|
| 2825 |
} else {
|
| 2826 |
+
style = extractLineClasses(readToken(mode, stream, state, inner), lineClasses);
|
| 2827 |
}
|
| 2828 |
if (inner) {
|
| 2829 |
+
var mName = inner[0].name;
|
| 2830 |
+
if (mName) { style = "m-" + (style ? mName + " " + style : mName); }
|
| 2831 |
}
|
| 2832 |
if (!flattenSpans || curStyle != style) {
|
| 2833 |
while (curStart < stream.start) {
|
| 2834 |
+
curStart = Math.min(stream.start, curStart + 5000);
|
| 2835 |
+
f(curStart, curStyle);
|
| 2836 |
}
|
| 2837 |
+
curStyle = style;
|
| 2838 |
}
|
| 2839 |
+
stream.start = stream.pos;
|
| 2840 |
}
|
| 2841 |
while (curStart < stream.pos) {
|
| 2842 |
// Webkit seems to refuse to render text nodes longer than 57444
|
| 2843 |
// characters, and returns inaccurate measurements in nodes
|
| 2844 |
// starting around 5000 chars.
|
| 2845 |
+
var pos = Math.min(stream.pos, curStart + 5000);
|
| 2846 |
+
f(pos, curStyle);
|
| 2847 |
+
curStart = pos;
|
| 2848 |
}
|
| 2849 |
}
|
| 2850 |
|
| 2854 |
// smallest indentation, which tends to need the least context to
|
| 2855 |
// parse correctly.
|
| 2856 |
function findStartLine(cm, n, precise) {
|
| 2857 |
+
var minindent, minline, doc = cm.doc;
|
| 2858 |
+
var lim = precise ? -1 : n - (cm.doc.mode.innerMode ? 1000 : 100);
|
| 2859 |
for (var search = n; search > lim; --search) {
|
| 2860 |
if (search <= doc.first) { return doc.first }
|
| 2861 |
+
var line = getLine(doc, search - 1);
|
| 2862 |
if (line.stateAfter && (!precise || search <= doc.frontier)) { return search }
|
| 2863 |
+
var indented = countColumn(line.text, null, cm.options.tabSize);
|
| 2864 |
if (minline == null || minindent > indented) {
|
| 2865 |
+
minline = search - 1;
|
| 2866 |
+
minindent = indented;
|
| 2867 |
}
|
| 2868 |
}
|
| 2869 |
return minline
|
| 2874 |
// Line objects. These hold state related to a line, including
|
| 2875 |
// highlighting info (the styles array).
|
| 2876 |
var Line = function(text, markedSpans, estimateHeight) {
|
| 2877 |
+
this.text = text;
|
| 2878 |
+
attachMarkedSpans(this, markedSpans);
|
| 2879 |
+
this.height = estimateHeight ? estimateHeight(this) : 1;
|
| 2880 |
};
|
| 2881 |
|
| 2882 |
Line.prototype.lineNo = function () { return lineNo(this) };
|
| 2883 |
+
eventMixin(Line);
|
| 2884 |
|
| 2885 |
// Change the content (text, markers) of a line. Automatically
|
| 2886 |
// invalidates cached information and tries to re-estimate the
|
| 2887 |
// line's height.
|
| 2888 |
function updateLine(line, text, markedSpans, estimateHeight) {
|
| 2889 |
+
line.text = text;
|
| 2890 |
+
if (line.stateAfter) { line.stateAfter = null; }
|
| 2891 |
+
if (line.styles) { line.styles = null; }
|
| 2892 |
+
if (line.order != null) { line.order = null; }
|
| 2893 |
+
detachMarkedSpans(line);
|
| 2894 |
+
attachMarkedSpans(line, markedSpans);
|
| 2895 |
+
var estHeight = estimateHeight ? estimateHeight(line) : 1;
|
| 2896 |
+
if (estHeight != line.height) { updateLineHeight(line, estHeight); }
|
| 2897 |
}
|
| 2898 |
|
| 2899 |
// Detach a line from the document tree and its markers.
|
| 2900 |
function cleanUpLine(line) {
|
| 2901 |
+
line.parent = null;
|
| 2902 |
+
detachMarkedSpans(line);
|
| 2903 |
}
|
| 2904 |
|
| 2905 |
// Convert a style as returned by a mode (either null, or a string
|
| 2909 |
var styleToClassCacheWithMode = {};
|
| 2910 |
function interpretTokenStyle(style, options) {
|
| 2911 |
if (!style || /^\s*$/.test(style)) { return null }
|
| 2912 |
+
var cache = options.addModeClass ? styleToClassCacheWithMode : styleToClassCache;
|
| 2913 |
return cache[style] ||
|
| 2914 |
(cache[style] = style.replace(/\S+/g, "cm-$&"))
|
| 2915 |
}
|
| 2923 |
// The padding-right forces the element to have a 'border', which
|
| 2924 |
// is needed on Webkit to be able to get line-level bounding
|
| 2925 |
// rectangles for it (in measureChar).
|
| 2926 |
+
var content = eltP("span", null, null, webkit ? "padding-right: .1px" : null);
|
| 2927 |
+
var builder = {pre: eltP("pre", [content], "CodeMirror-line"), content: content,
|
| 2928 |
col: 0, pos: 0, cm: cm,
|
| 2929 |
trailingSpace: false,
|
| 2930 |
+
splitSpaces: (ie || webkit) && cm.getOption("lineWrapping")};
|
| 2931 |
+
lineView.measure = {};
|
|
|
|
|
|
|
|
|
|
| 2932 |
|
| 2933 |
// Iterate over the logical lines that make up this visual line.
|
| 2934 |
for (var i = 0; i <= (lineView.rest ? lineView.rest.length : 0); i++) {
|
| 2935 |
+
var line = i ? lineView.rest[i - 1] : lineView.line, order = (void 0);
|
| 2936 |
+
builder.pos = 0;
|
| 2937 |
+
builder.addToken = buildToken;
|
| 2938 |
// Optionally wire in some hacks into the token-rendering
|
| 2939 |
// algorithm, to deal with browser quirks.
|
| 2940 |
+
if (hasBadBidiRects(cm.display.measure) && (order = getOrder(line, cm.doc.direction)))
|
| 2941 |
+
{ builder.addToken = buildTokenBadBidi(builder.addToken, order); }
|
| 2942 |
+
builder.map = [];
|
| 2943 |
+
var allowFrontierUpdate = lineView != cm.display.externalMeasured && lineNo(line);
|
| 2944 |
+
insertLineContent(line, builder, getLineStyles(cm, line, allowFrontierUpdate));
|
| 2945 |
if (line.styleClasses) {
|
| 2946 |
if (line.styleClasses.bgClass)
|
| 2947 |
+
{ builder.bgClass = joinClasses(line.styleClasses.bgClass, builder.bgClass || ""); }
|
| 2948 |
if (line.styleClasses.textClass)
|
| 2949 |
+
{ builder.textClass = joinClasses(line.styleClasses.textClass, builder.textClass || ""); }
|
| 2950 |
}
|
| 2951 |
|
| 2952 |
// Ensure at least a single node is present, for measuring.
|
| 2953 |
if (builder.map.length == 0)
|
| 2954 |
+
{ builder.map.push(0, 0, builder.content.appendChild(zeroWidthElement(cm.display.measure))); }
|
| 2955 |
|
| 2956 |
// Store the map and a cache object for the current logical line
|
| 2957 |
if (i == 0) {
|
| 2958 |
+
lineView.measure.map = builder.map;
|
| 2959 |
+
lineView.measure.cache = {};
|
| 2960 |
} else {
|
| 2961 |
+
(lineView.measure.maps || (lineView.measure.maps = [])).push(builder.map)
|
| 2962 |
+
;(lineView.measure.caches || (lineView.measure.caches = [])).push({});
|
| 2963 |
}
|
| 2964 |
}
|
| 2965 |
|
| 2966 |
// See issue #2901
|
| 2967 |
if (webkit) {
|
| 2968 |
+
var last = builder.content.lastChild;
|
| 2969 |
if (/\bcm-tab\b/.test(last.className) || (last.querySelector && last.querySelector(".cm-tab")))
|
| 2970 |
+
{ builder.content.className = "cm-tab-wrap-hack"; }
|
| 2971 |
}
|
| 2972 |
|
| 2973 |
+
signal(cm, "renderLine", cm, lineView.line, builder.pre);
|
| 2974 |
if (builder.pre.className)
|
| 2975 |
+
{ builder.textClass = joinClasses(builder.pre.className, builder.textClass || ""); }
|
| 2976 |
|
| 2977 |
return builder
|
| 2978 |
}
|
| 2979 |
|
| 2980 |
function defaultSpecialCharPlaceholder(ch) {
|
| 2981 |
+
var token = elt("span", "\u2022", "cm-invalidchar");
|
| 2982 |
+
token.title = "\\u" + ch.charCodeAt(0).toString(16);
|
| 2983 |
+
token.setAttribute("aria-label", token.title);
|
| 2984 |
return token
|
| 2985 |
}
|
| 2986 |
|
| 2988 |
// the line map. Takes care to render special characters separately.
|
| 2989 |
function buildToken(builder, text, style, startStyle, endStyle, title, css) {
|
| 2990 |
if (!text) { return }
|
| 2991 |
+
var displayText = builder.splitSpaces ? splitSpaces(text, builder.trailingSpace) : text;
|
| 2992 |
+
var special = builder.cm.state.specialChars, mustWrap = false;
|
| 2993 |
+
var content;
|
| 2994 |
if (!special.test(text)) {
|
| 2995 |
+
builder.col += text.length;
|
| 2996 |
+
content = document.createTextNode(displayText);
|
| 2997 |
+
builder.map.push(builder.pos, builder.pos + text.length, content);
|
| 2998 |
+
if (ie && ie_version < 9) { mustWrap = true; }
|
| 2999 |
+
builder.pos += text.length;
|
| 3000 |
} else {
|
| 3001 |
+
content = document.createDocumentFragment();
|
| 3002 |
+
var pos = 0;
|
| 3003 |
while (true) {
|
| 3004 |
+
special.lastIndex = pos;
|
| 3005 |
+
var m = special.exec(text);
|
| 3006 |
+
var skipped = m ? m.index - pos : text.length - pos;
|
| 3007 |
if (skipped) {
|
| 3008 |
+
var txt = document.createTextNode(displayText.slice(pos, pos + skipped));
|
| 3009 |
+
if (ie && ie_version < 9) { content.appendChild(elt("span", [txt])); }
|
| 3010 |
+
else { content.appendChild(txt); }
|
| 3011 |
+
builder.map.push(builder.pos, builder.pos + skipped, txt);
|
| 3012 |
+
builder.col += skipped;
|
| 3013 |
+
builder.pos += skipped;
|
| 3014 |
}
|
| 3015 |
if (!m) { break }
|
| 3016 |
+
pos += skipped + 1;
|
| 3017 |
+
var txt$1 = (void 0);
|
| 3018 |
if (m[0] == "\t") {
|
| 3019 |
+
var tabSize = builder.cm.options.tabSize, tabWidth = tabSize - builder.col % tabSize;
|
| 3020 |
+
txt$1 = content.appendChild(elt("span", spaceStr(tabWidth), "cm-tab"));
|
| 3021 |
+
txt$1.setAttribute("role", "presentation");
|
| 3022 |
+
txt$1.setAttribute("cm-text", "\t");
|
| 3023 |
+
builder.col += tabWidth;
|
| 3024 |
} else if (m[0] == "\r" || m[0] == "\n") {
|
| 3025 |
+
txt$1 = content.appendChild(elt("span", m[0] == "\r" ? "\u240d" : "\u2424", "cm-invalidchar"));
|
| 3026 |
+
txt$1.setAttribute("cm-text", m[0]);
|
| 3027 |
+
builder.col += 1;
|
| 3028 |
} else {
|
| 3029 |
+
txt$1 = builder.cm.options.specialCharPlaceholder(m[0]);
|
| 3030 |
+
txt$1.setAttribute("cm-text", m[0]);
|
| 3031 |
+
if (ie && ie_version < 9) { content.appendChild(elt("span", [txt$1])); }
|
| 3032 |
+
else { content.appendChild(txt$1); }
|
| 3033 |
+
builder.col += 1;
|
| 3034 |
}
|
| 3035 |
+
builder.map.push(builder.pos, builder.pos + 1, txt$1);
|
| 3036 |
+
builder.pos++;
|
| 3037 |
}
|
| 3038 |
}
|
| 3039 |
+
builder.trailingSpace = displayText.charCodeAt(text.length - 1) == 32;
|
| 3040 |
if (style || startStyle || endStyle || mustWrap || css) {
|
| 3041 |
+
var fullStyle = style || "";
|
| 3042 |
+
if (startStyle) { fullStyle += startStyle; }
|
| 3043 |
+
if (endStyle) { fullStyle += endStyle; }
|
| 3044 |
+
var token = elt("span", [content], fullStyle, css);
|
| 3045 |
+
if (title) { token.title = title; }
|
| 3046 |
return builder.content.appendChild(token)
|
| 3047 |
}
|
| 3048 |
+
builder.content.appendChild(content);
|
| 3049 |
}
|
| 3050 |
|
| 3051 |
function splitSpaces(text, trailingBefore) {
|
| 3052 |
if (text.length > 1 && !/ /.test(text)) { return text }
|
| 3053 |
+
var spaceBefore = trailingBefore, result = "";
|
| 3054 |
for (var i = 0; i < text.length; i++) {
|
| 3055 |
+
var ch = text.charAt(i);
|
| 3056 |
if (ch == " " && spaceBefore && (i == text.length - 1 || text.charCodeAt(i + 1) == 32))
|
| 3057 |
+
{ ch = "\u00a0"; }
|
| 3058 |
+
result += ch;
|
| 3059 |
+
spaceBefore = ch == " ";
|
| 3060 |
}
|
| 3061 |
return result
|
| 3062 |
}
|
| 3065 |
// right-to-left text.
|
| 3066 |
function buildTokenBadBidi(inner, order) {
|
| 3067 |
return function (builder, text, style, startStyle, endStyle, title, css) {
|
| 3068 |
+
style = style ? style + " cm-force-border" : "cm-force-border";
|
| 3069 |
+
var start = builder.pos, end = start + text.length;
|
| 3070 |
for (;;) {
|
| 3071 |
// Find the part that overlaps with the start of this text
|
| 3072 |
+
var part = (void 0);
|
| 3073 |
for (var i = 0; i < order.length; i++) {
|
| 3074 |
+
part = order[i];
|
| 3075 |
if (part.to > start && part.from <= start) { break }
|
| 3076 |
}
|
| 3077 |
if (part.to >= end) { return inner(builder, text, style, startStyle, endStyle, title, css) }
|
| 3078 |
+
inner(builder, text.slice(0, part.to - start), style, startStyle, null, title, css);
|
| 3079 |
+
startStyle = null;
|
| 3080 |
+
text = text.slice(part.to - start);
|
| 3081 |
+
start = part.to;
|
| 3082 |
}
|
| 3083 |
}
|
| 3084 |
}
|
| 3085 |
|
| 3086 |
function buildCollapsedSpan(builder, size, marker, ignoreWidget) {
|
| 3087 |
+
var widget = !ignoreWidget && marker.widgetNode;
|
| 3088 |
+
if (widget) { builder.map.push(builder.pos, builder.pos + size, widget); }
|
| 3089 |
if (!ignoreWidget && builder.cm.display.input.needsContentAttribute) {
|
| 3090 |
if (!widget)
|
| 3091 |
+
{ widget = builder.content.appendChild(document.createElement("span")); }
|
| 3092 |
+
widget.setAttribute("cm-marker", marker.id);
|
| 3093 |
}
|
| 3094 |
if (widget) {
|
| 3095 |
+
builder.cm.display.input.setUneditable(widget);
|
| 3096 |
+
builder.content.appendChild(widget);
|
| 3097 |
}
|
| 3098 |
+
builder.pos += size;
|
| 3099 |
+
builder.trailingSpace = false;
|
| 3100 |
}
|
| 3101 |
|
| 3102 |
// Outputs a number of spans to make up a line, taking highlighting
|
| 3103 |
// and marked text into account.
|
| 3104 |
function insertLineContent(line, builder, styles) {
|
| 3105 |
+
var spans = line.markedSpans, allText = line.text, at = 0;
|
| 3106 |
if (!spans) {
|
| 3107 |
for (var i$1 = 1; i$1 < styles.length; i$1+=2)
|
| 3108 |
+
{ builder.addToken(builder, allText.slice(at, at = styles[i$1]), interpretTokenStyle(styles[i$1+1], builder.cm.options)); }
|
| 3109 |
return
|
| 3110 |
}
|
| 3111 |
|
| 3112 |
+
var len = allText.length, pos = 0, i = 1, text = "", style, css;
|
| 3113 |
+
var nextChange = 0, spanStyle, spanEndStyle, spanStartStyle, title, collapsed;
|
| 3114 |
for (;;) {
|
| 3115 |
if (nextChange == pos) { // Update current marker set
|
| 3116 |
+
spanStyle = spanEndStyle = spanStartStyle = title = css = "";
|
| 3117 |
+
collapsed = null; nextChange = Infinity;
|
| 3118 |
+
var foundBookmarks = [], endStyles = (void 0);
|
| 3119 |
for (var j = 0; j < spans.length; ++j) {
|
| 3120 |
+
var sp = spans[j], m = sp.marker;
|
| 3121 |
if (m.type == "bookmark" && sp.from == pos && m.widgetNode) {
|
| 3122 |
+
foundBookmarks.push(m);
|
| 3123 |
} else if (sp.from <= pos && (sp.to == null || sp.to > pos || m.collapsed && sp.to == pos && sp.from == pos)) {
|
| 3124 |
if (sp.to != null && sp.to != pos && nextChange > sp.to) {
|
| 3125 |
+
nextChange = sp.to;
|
| 3126 |
+
spanEndStyle = "";
|
| 3127 |
}
|
| 3128 |
+
if (m.className) { spanStyle += " " + m.className; }
|
| 3129 |
+
if (m.css) { css = (css ? css + ";" : "") + m.css; }
|
| 3130 |
+
if (m.startStyle && sp.from == pos) { spanStartStyle += " " + m.startStyle; }
|
| 3131 |
+
if (m.endStyle && sp.to == nextChange) { (endStyles || (endStyles = [])).push(m.endStyle, sp.to); }
|
| 3132 |
+
if (m.title && !title) { title = m.title; }
|
| 3133 |
if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
|
| 3134 |
+
{ collapsed = sp; }
|
| 3135 |
} else if (sp.from > pos && nextChange > sp.from) {
|
| 3136 |
+
nextChange = sp.from;
|
| 3137 |
}
|
| 3138 |
}
|
| 3139 |
if (endStyles) { for (var j$1 = 0; j$1 < endStyles.length; j$1 += 2)
|
| 3140 |
+
{ if (endStyles[j$1 + 1] == nextChange) { spanEndStyle += " " + endStyles[j$1]; } } }
|
| 3141 |
|
| 3142 |
if (!collapsed || collapsed.from == pos) { for (var j$2 = 0; j$2 < foundBookmarks.length; ++j$2)
|
| 3143 |
+
{ buildCollapsedSpan(builder, 0, foundBookmarks[j$2]); } }
|
| 3144 |
if (collapsed && (collapsed.from || 0) == pos) {
|
| 3145 |
buildCollapsedSpan(builder, (collapsed.to == null ? len + 1 : collapsed.to) - pos,
|
| 3146 |
+
collapsed.marker, collapsed.from == null);
|
| 3147 |
if (collapsed.to == null) { return }
|
| 3148 |
+
if (collapsed.to == pos) { collapsed = false; }
|
| 3149 |
}
|
| 3150 |
}
|
| 3151 |
if (pos >= len) { break }
|
| 3152 |
|
| 3153 |
+
var upto = Math.min(len, nextChange);
|
| 3154 |
while (true) {
|
| 3155 |
if (text) {
|
| 3156 |
+
var end = pos + text.length;
|
| 3157 |
if (!collapsed) {
|
| 3158 |
+
var tokenText = end > upto ? text.slice(0, upto - pos) : text;
|
| 3159 |
builder.addToken(builder, tokenText, style ? style + spanStyle : spanStyle,
|
| 3160 |
+
spanStartStyle, pos + tokenText.length == nextChange ? spanEndStyle : "", title, css);
|
| 3161 |
}
|
| 3162 |
if (end >= upto) {text = text.slice(upto - pos); pos = upto; break}
|
| 3163 |
+
pos = end;
|
| 3164 |
+
spanStartStyle = "";
|
| 3165 |
}
|
| 3166 |
+
text = allText.slice(at, at = styles[i++]);
|
| 3167 |
+
style = interpretTokenStyle(styles[i++], builder.cm.options);
|
| 3168 |
}
|
| 3169 |
}
|
| 3170 |
}
|
| 3175 |
// logical lines, if those are connected by collapsed ranges.
|
| 3176 |
function LineView(doc, line, lineN) {
|
| 3177 |
// The starting line
|
| 3178 |
+
this.line = line;
|
| 3179 |
// Continuing lines, if any
|
| 3180 |
+
this.rest = visualLineContinued(line);
|
| 3181 |
// Number of logical lines in this visual line
|
| 3182 |
+
this.size = this.rest ? lineNo(lst(this.rest)) - lineN + 1 : 1;
|
| 3183 |
+
this.node = this.text = null;
|
| 3184 |
+
this.hidden = lineIsHidden(doc, line);
|
| 3185 |
}
|
| 3186 |
|
| 3187 |
// Create a range of LineView objects for the given lines.
|
| 3188 |
function buildViewArray(cm, from, to) {
|
| 3189 |
+
var array = [], nextPos;
|
| 3190 |
for (var pos = from; pos < to; pos = nextPos) {
|
| 3191 |
+
var view = new LineView(cm.doc, getLine(cm.doc, pos), pos);
|
| 3192 |
+
nextPos = pos + view.size;
|
| 3193 |
+
array.push(view);
|
| 3194 |
}
|
| 3195 |
return array
|
| 3196 |
}
|
| 3197 |
|
| 3198 |
+
var operationGroup = null;
|
| 3199 |
|
| 3200 |
function pushOperation(op) {
|
| 3201 |
if (operationGroup) {
|
| 3202 |
+
operationGroup.ops.push(op);
|
| 3203 |
} else {
|
| 3204 |
op.ownsGroup = operationGroup = {
|
| 3205 |
ops: [op],
|
| 3206 |
delayedCallbacks: []
|
| 3207 |
+
};
|
| 3208 |
}
|
| 3209 |
}
|
| 3210 |
|
| 3211 |
function fireCallbacksForOps(group) {
|
| 3212 |
// Calls delayed callbacks and cursorActivity handlers until no
|
| 3213 |
// new ones appear
|
| 3214 |
+
var callbacks = group.delayedCallbacks, i = 0;
|
| 3215 |
do {
|
| 3216 |
for (; i < callbacks.length; i++)
|
| 3217 |
+
{ callbacks[i].call(null); }
|
| 3218 |
for (var j = 0; j < group.ops.length; j++) {
|
| 3219 |
+
var op = group.ops[j];
|
| 3220 |
if (op.cursorActivityHandlers)
|
| 3221 |
{ while (op.cursorActivityCalled < op.cursorActivityHandlers.length)
|
| 3222 |
+
{ op.cursorActivityHandlers[op.cursorActivityCalled++].call(null, op.cm); } }
|
| 3223 |
}
|
| 3224 |
} while (i < callbacks.length)
|
| 3225 |
}
|
| 3226 |
|
| 3227 |
function finishOperation(op, endCb) {
|
| 3228 |
+
var group = op.ownsGroup;
|
| 3229 |
if (!group) { return }
|
| 3230 |
|
| 3231 |
+
try { fireCallbacksForOps(group); }
|
| 3232 |
finally {
|
| 3233 |
+
operationGroup = null;
|
| 3234 |
+
endCb(group);
|
| 3235 |
}
|
| 3236 |
}
|
| 3237 |
|
| 3238 |
+
var orphanDelayedCallbacks = null;
|
| 3239 |
|
| 3240 |
// Often, we want to signal events at a point where we are in the
|
| 3241 |
// middle of some work, but don't want the handler to start calling
|
| 3245 |
// them to be executed when the last operation ends, or, if no
|
| 3246 |
// operation is active, when a timeout fires.
|
| 3247 |
function signalLater(emitter, type /*, values...*/) {
|
| 3248 |
+
var arr = getHandlers(emitter, type);
|
| 3249 |
if (!arr.length) { return }
|
| 3250 |
+
var args = Array.prototype.slice.call(arguments, 2), list;
|
| 3251 |
if (operationGroup) {
|
| 3252 |
+
list = operationGroup.delayedCallbacks;
|
| 3253 |
} else if (orphanDelayedCallbacks) {
|
| 3254 |
+
list = orphanDelayedCallbacks;
|
| 3255 |
} else {
|
| 3256 |
+
list = orphanDelayedCallbacks = [];
|
| 3257 |
+
setTimeout(fireOrphanDelayed, 0);
|
| 3258 |
}
|
| 3259 |
var loop = function ( i ) {
|
| 3260 |
+
list.push(function () { return arr[i].apply(null, args); });
|
| 3261 |
};
|
| 3262 |
|
| 3263 |
for (var i = 0; i < arr.length; ++i)
|
| 3265 |
}
|
| 3266 |
|
| 3267 |
function fireOrphanDelayed() {
|
| 3268 |
+
var delayed = orphanDelayedCallbacks;
|
| 3269 |
+
orphanDelayedCallbacks = null;
|
| 3270 |
+
for (var i = 0; i < delayed.length; ++i) { delayed[i](); }
|
| 3271 |
}
|
| 3272 |
|
| 3273 |
// When an aspect of a line changes, a string is added to
|
| 3275 |
// DOM structure.
|
| 3276 |
function updateLineForChanges(cm, lineView, lineN, dims) {
|
| 3277 |
for (var j = 0; j < lineView.changes.length; j++) {
|
| 3278 |
+
var type = lineView.changes[j];
|
| 3279 |
+
if (type == "text") { updateLineText(cm, lineView); }
|
| 3280 |
+
else if (type == "gutter") { updateLineGutter(cm, lineView, lineN, dims); }
|
| 3281 |
+
else if (type == "class") { updateLineClasses(cm, lineView); }
|
| 3282 |
+
else if (type == "widget") { updateLineWidgets(cm, lineView, dims); }
|
| 3283 |
}
|
| 3284 |
+
lineView.changes = null;
|
| 3285 |
}
|
| 3286 |
|
| 3287 |
// Lines with gutter elements, widgets or a background class need to
|
| 3288 |
// be wrapped, and have the extra elements added to the wrapper div
|
| 3289 |
function ensureLineWrapped(lineView) {
|
| 3290 |
if (lineView.node == lineView.text) {
|
| 3291 |
+
lineView.node = elt("div", null, null, "position: relative");
|
| 3292 |
if (lineView.text.parentNode)
|
| 3293 |
+
{ lineView.text.parentNode.replaceChild(lineView.node, lineView.text); }
|
| 3294 |
+
lineView.node.appendChild(lineView.text);
|
| 3295 |
+
if (ie && ie_version < 8) { lineView.node.style.zIndex = 2; }
|
| 3296 |
}
|
| 3297 |
return lineView.node
|
| 3298 |
}
|
| 3299 |
|
| 3300 |
+
function updateLineBackground(cm, lineView) {
|
| 3301 |
+
var cls = lineView.bgClass ? lineView.bgClass + " " + (lineView.line.bgClass || "") : lineView.line.bgClass;
|
| 3302 |
+
if (cls) { cls += " CodeMirror-linebackground"; }
|
| 3303 |
if (lineView.background) {
|
| 3304 |
+
if (cls) { lineView.background.className = cls; }
|
| 3305 |
+
else { lineView.background.parentNode.removeChild(lineView.background); lineView.background = null; }
|
| 3306 |
} else if (cls) {
|
| 3307 |
+
var wrap = ensureLineWrapped(lineView);
|
| 3308 |
+
lineView.background = wrap.insertBefore(elt("div", null, cls), wrap.firstChild);
|
| 3309 |
+
cm.display.input.setUneditable(lineView.background);
|
| 3310 |
}
|
| 3311 |
}
|
| 3312 |
|
| 3313 |
// Wrapper around buildLineContent which will reuse the structure
|
| 3314 |
// in display.externalMeasured when possible.
|
| 3315 |
function getLineContent(cm, lineView) {
|
| 3316 |
+
var ext = cm.display.externalMeasured;
|
| 3317 |
if (ext && ext.line == lineView.line) {
|
| 3318 |
+
cm.display.externalMeasured = null;
|
| 3319 |
+
lineView.measure = ext.measure;
|
| 3320 |
return ext.built
|
| 3321 |
}
|
| 3322 |
return buildLineContent(cm, lineView)
|
| 3326 |
// classes because the mode may output tokens that influence these
|
| 3327 |
// classes.
|
| 3328 |
function updateLineText(cm, lineView) {
|
| 3329 |
+
var cls = lineView.text.className;
|
| 3330 |
+
var built = getLineContent(cm, lineView);
|
| 3331 |
+
if (lineView.text == lineView.node) { lineView.node = built.pre; }
|
| 3332 |
+
lineView.text.parentNode.replaceChild(built.pre, lineView.text);
|
| 3333 |
+
lineView.text = built.pre;
|
| 3334 |
if (built.bgClass != lineView.bgClass || built.textClass != lineView.textClass) {
|
| 3335 |
+
lineView.bgClass = built.bgClass;
|
| 3336 |
+
lineView.textClass = built.textClass;
|
| 3337 |
+
updateLineClasses(cm, lineView);
|
| 3338 |
} else if (cls) {
|
| 3339 |
+
lineView.text.className = cls;
|
| 3340 |
}
|
| 3341 |
}
|
| 3342 |
|
| 3343 |
+
function updateLineClasses(cm, lineView) {
|
| 3344 |
+
updateLineBackground(cm, lineView);
|
| 3345 |
if (lineView.line.wrapClass)
|
| 3346 |
+
{ ensureLineWrapped(lineView).className = lineView.line.wrapClass; }
|
| 3347 |
else if (lineView.node != lineView.text)
|
| 3348 |
+
{ lineView.node.className = ""; }
|
| 3349 |
+
var textClass = lineView.textClass ? lineView.textClass + " " + (lineView.line.textClass || "") : lineView.line.textClass;
|
| 3350 |
+
lineView.text.className = textClass || "";
|
| 3351 |
}
|
| 3352 |
|
| 3353 |
function updateLineGutter(cm, lineView, lineN, dims) {
|
| 3354 |
if (lineView.gutter) {
|
| 3355 |
+
lineView.node.removeChild(lineView.gutter);
|
| 3356 |
+
lineView.gutter = null;
|
| 3357 |
}
|
| 3358 |
if (lineView.gutterBackground) {
|
| 3359 |
+
lineView.node.removeChild(lineView.gutterBackground);
|
| 3360 |
+
lineView.gutterBackground = null;
|
| 3361 |
}
|
| 3362 |
if (lineView.line.gutterClass) {
|
| 3363 |
+
var wrap = ensureLineWrapped(lineView);
|
| 3364 |
lineView.gutterBackground = elt("div", null, "CodeMirror-gutter-background " + lineView.line.gutterClass,
|
| 3365 |
+
("left: " + (cm.options.fixedGutter ? dims.fixedPos : -dims.gutterTotalWidth) + "px; width: " + (dims.gutterTotalWidth) + "px"));
|
| 3366 |
+
cm.display.input.setUneditable(lineView.gutterBackground);
|
| 3367 |
+
wrap.insertBefore(lineView.gutterBackground, lineView.text);
|
| 3368 |
}
|
| 3369 |
+
var markers = lineView.line.gutterMarkers;
|
| 3370 |
if (cm.options.lineNumbers || markers) {
|
| 3371 |
+
var wrap$1 = ensureLineWrapped(lineView);
|
| 3372 |
+
var gutterWrap = lineView.gutter = elt("div", null, "CodeMirror-gutter-wrapper", ("left: " + (cm.options.fixedGutter ? dims.fixedPos : -dims.gutterTotalWidth) + "px"));
|
| 3373 |
+
cm.display.input.setUneditable(gutterWrap);
|
| 3374 |
+
wrap$1.insertBefore(gutterWrap, lineView.text);
|
| 3375 |
if (lineView.line.gutterClass)
|
| 3376 |
+
{ gutterWrap.className += " " + lineView.line.gutterClass; }
|
| 3377 |
if (cm.options.lineNumbers && (!markers || !markers["CodeMirror-linenumbers"]))
|
| 3378 |
{ lineView.lineNumber = gutterWrap.appendChild(
|
| 3379 |
elt("div", lineNumberFor(cm.options, lineN),
|
| 3380 |
"CodeMirror-linenumber CodeMirror-gutter-elt",
|
| 3381 |
+
("left: " + (dims.gutterLeft["CodeMirror-linenumbers"]) + "px; width: " + (cm.display.lineNumInnerWidth) + "px"))); }
|
| 3382 |
if (markers) { for (var k = 0; k < cm.options.gutters.length; ++k) {
|
| 3383 |
+
var id = cm.options.gutters[k], found = markers.hasOwnProperty(id) && markers[id];
|
| 3384 |
if (found)
|
| 3385 |
{ gutterWrap.appendChild(elt("div", [found], "CodeMirror-gutter-elt",
|
| 3386 |
+
("left: " + (dims.gutterLeft[id]) + "px; width: " + (dims.gutterWidth[id]) + "px"))); }
|
| 3387 |
} }
|
| 3388 |
}
|
| 3389 |
}
|
| 3390 |
|
| 3391 |
function updateLineWidgets(cm, lineView, dims) {
|
| 3392 |
+
if (lineView.alignable) { lineView.alignable = null; }
|
| 3393 |
for (var node = lineView.node.firstChild, next = (void 0); node; node = next) {
|
| 3394 |
+
next = node.nextSibling;
|
| 3395 |
if (node.className == "CodeMirror-linewidget")
|
| 3396 |
+
{ lineView.node.removeChild(node); }
|
| 3397 |
}
|
| 3398 |
+
insertLineWidgets(cm, lineView, dims);
|
| 3399 |
}
|
| 3400 |
|
| 3401 |
// Build a line's DOM representation from scratch
|
| 3402 |
function buildLineElement(cm, lineView, lineN, dims) {
|
| 3403 |
+
var built = getLineContent(cm, lineView);
|
| 3404 |
+
lineView.text = lineView.node = built.pre;
|
| 3405 |
+
if (built.bgClass) { lineView.bgClass = built.bgClass; }
|
| 3406 |
+
if (built.textClass) { lineView.textClass = built.textClass; }
|
| 3407 |
+
|
| 3408 |
+
updateLineClasses(cm, lineView);
|
| 3409 |
+
updateLineGutter(cm, lineView, lineN, dims);
|
| 3410 |
+
insertLineWidgets(cm, lineView, dims);
|
| 3411 |
return lineView.node
|
| 3412 |
}
|
| 3413 |
|
| 3414 |
// A lineView may contain multiple logical lines (when merged by
|
| 3415 |
// collapsed spans). The widgets for all of them need to be drawn.
|
| 3416 |
function insertLineWidgets(cm, lineView, dims) {
|
| 3417 |
+
insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);
|
| 3418 |
if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)
|
| 3419 |
+
{ insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }
|
| 3420 |
}
|
| 3421 |
|
| 3422 |
function insertLineWidgetsFor(cm, line, lineView, dims, allowAbove) {
|
| 3423 |
if (!line.widgets) { return }
|
| 3424 |
+
var wrap = ensureLineWrapped(lineView);
|
| 3425 |
for (var i = 0, ws = line.widgets; i < ws.length; ++i) {
|
| 3426 |
+
var widget = ws[i], node = elt("div", [widget.node], "CodeMirror-linewidget");
|
| 3427 |
+
if (!widget.handleMouseEvents) { node.setAttribute("cm-ignore-events", "true"); }
|
| 3428 |
+
positionLineWidget(widget, node, lineView, dims);
|
| 3429 |
+
cm.display.input.setUneditable(node);
|
| 3430 |
if (allowAbove && widget.above)
|
| 3431 |
+
{ wrap.insertBefore(node, lineView.gutter || lineView.text); }
|
| 3432 |
else
|
| 3433 |
+
{ wrap.appendChild(node); }
|
| 3434 |
+
signalLater(widget, "redraw");
|
| 3435 |
}
|
| 3436 |
}
|
| 3437 |
|
| 3438 |
function positionLineWidget(widget, node, lineView, dims) {
|
| 3439 |
if (widget.noHScroll) {
|
| 3440 |
+
(lineView.alignable || (lineView.alignable = [])).push(node);
|
| 3441 |
+
var width = dims.wrapperWidth;
|
| 3442 |
+
node.style.left = dims.fixedPos + "px";
|
| 3443 |
if (!widget.coverGutter) {
|
| 3444 |
+
width -= dims.gutterTotalWidth;
|
| 3445 |
+
node.style.paddingLeft = dims.gutterTotalWidth + "px";
|
| 3446 |
}
|
| 3447 |
+
node.style.width = width + "px";
|
| 3448 |
}
|
| 3449 |
if (widget.coverGutter) {
|
| 3450 |
+
node.style.zIndex = 5;
|
| 3451 |
+
node.style.position = "relative";
|
| 3452 |
+
if (!widget.noHScroll) { node.style.marginLeft = -dims.gutterTotalWidth + "px"; }
|
| 3453 |
}
|
| 3454 |
}
|
| 3455 |
|
| 3456 |
function widgetHeight(widget) {
|
| 3457 |
if (widget.height != null) { return widget.height }
|
| 3458 |
+
var cm = widget.doc.cm;
|
| 3459 |
if (!cm) { return 0 }
|
| 3460 |
if (!contains(document.body, widget.node)) {
|
| 3461 |
+
var parentStyle = "position: relative;";
|
| 3462 |
if (widget.coverGutter)
|
| 3463 |
+
{ parentStyle += "margin-left: -" + cm.display.gutters.offsetWidth + "px;"; }
|
| 3464 |
if (widget.noHScroll)
|
| 3465 |
+
{ parentStyle += "width: " + cm.display.wrapper.clientWidth + "px;"; }
|
| 3466 |
+
removeChildrenAndAdd(cm.display.measure, elt("div", [widget.node], null, parentStyle));
|
| 3467 |
}
|
| 3468 |
return widget.height = widget.node.parentNode.offsetHeight
|
| 3469 |
}
|
| 3483 |
function paddingVert(display) {return display.mover.offsetHeight - display.lineSpace.offsetHeight}
|
| 3484 |
function paddingH(display) {
|
| 3485 |
if (display.cachedPaddingH) { return display.cachedPaddingH }
|
| 3486 |
+
var e = removeChildrenAndAdd(display.measure, elt("pre", "x"));
|
| 3487 |
+
var style = window.getComputedStyle ? window.getComputedStyle(e) : e.currentStyle;
|
| 3488 |
+
var data = {left: parseInt(style.paddingLeft), right: parseInt(style.paddingRight)};
|
| 3489 |
+
if (!isNaN(data.left) && !isNaN(data.right)) { display.cachedPaddingH = data; }
|
| 3490 |
return data
|
| 3491 |
}
|
| 3492 |
|
| 3503 |
// line. When lineWrapping is on, there might be more than one
|
| 3504 |
// height.
|
| 3505 |
function ensureLineHeights(cm, lineView, rect) {
|
| 3506 |
+
var wrapping = cm.options.lineWrapping;
|
| 3507 |
+
var curWidth = wrapping && displayWidth(cm);
|
| 3508 |
if (!lineView.measure.heights || wrapping && lineView.measure.width != curWidth) {
|
| 3509 |
+
var heights = lineView.measure.heights = [];
|
| 3510 |
if (wrapping) {
|
| 3511 |
+
lineView.measure.width = curWidth;
|
| 3512 |
+
var rects = lineView.text.firstChild.getClientRects();
|
| 3513 |
for (var i = 0; i < rects.length - 1; i++) {
|
| 3514 |
+
var cur = rects[i], next = rects[i + 1];
|
| 3515 |
if (Math.abs(cur.bottom - next.bottom) > 2)
|
| 3516 |
+
{ heights.push((cur.bottom + next.top) / 2 - rect.top); }
|
| 3517 |
}
|
| 3518 |
}
|
| 3519 |
+
heights.push(rect.bottom - rect.top);
|
| 3520 |
}
|
| 3521 |
}
|
| 3522 |
|
| 3537 |
// Render a line into the hidden node display.externalMeasured. Used
|
| 3538 |
// when measurement is needed for a line that's not in the viewport.
|
| 3539 |
function updateExternalMeasurement(cm, line) {
|
| 3540 |
+
line = visualLine(line);
|
| 3541 |
+
var lineN = lineNo(line);
|
| 3542 |
+
var view = cm.display.externalMeasured = new LineView(cm.doc, line, lineN);
|
| 3543 |
+
view.lineN = lineN;
|
| 3544 |
+
var built = view.built = buildLineContent(cm, view);
|
| 3545 |
+
view.text = built.pre;
|
| 3546 |
+
removeChildrenAndAdd(cm.display.lineMeasure, built.pre);
|
| 3547 |
return view
|
| 3548 |
}
|
| 3549 |
|
| 3557 |
function findViewForLine(cm, lineN) {
|
| 3558 |
if (lineN >= cm.display.viewFrom && lineN < cm.display.viewTo)
|
| 3559 |
{ return cm.display.view[findViewIndex(cm, lineN)] }
|
| 3560 |
+
var ext = cm.display.externalMeasured;
|
| 3561 |
if (ext && lineN >= ext.lineN && lineN < ext.lineN + ext.size)
|
| 3562 |
{ return ext }
|
| 3563 |
}
|
| 3568 |
// measurements in a row, can thus ensure that the set-up work is
|
| 3569 |
// only done once.
|
| 3570 |
function prepareMeasureForLine(cm, line) {
|
| 3571 |
+
var lineN = lineNo(line);
|
| 3572 |
+
var view = findViewForLine(cm, lineN);
|
| 3573 |
if (view && !view.text) {
|
| 3574 |
+
view = null;
|
| 3575 |
} else if (view && view.changes) {
|
| 3576 |
+
updateLineForChanges(cm, view, lineN, getDimensions(cm));
|
| 3577 |
+
cm.curOp.forceUpdate = true;
|
| 3578 |
}
|
| 3579 |
if (!view)
|
| 3580 |
+
{ view = updateExternalMeasurement(cm, line); }
|
| 3581 |
|
| 3582 |
+
var info = mapFromLineView(view, line, lineN);
|
| 3583 |
return {
|
| 3584 |
line: line, view: view, rect: null,
|
| 3585 |
map: info.map, cache: info.cache, before: info.before,
|
| 3590 |
// Given a prepared measurement object, measures the position of an
|
| 3591 |
// actual character (or fetches it from the cache).
|
| 3592 |
function measureCharPrepared(cm, prepared, ch, bias, varHeight) {
|
| 3593 |
+
if (prepared.before) { ch = -1; }
|
| 3594 |
+
var key = ch + (bias || ""), found;
|
| 3595 |
if (prepared.cache.hasOwnProperty(key)) {
|
| 3596 |
+
found = prepared.cache[key];
|
| 3597 |
} else {
|
| 3598 |
if (!prepared.rect)
|
| 3599 |
+
{ prepared.rect = prepared.view.text.getBoundingClientRect(); }
|
| 3600 |
if (!prepared.hasHeights) {
|
| 3601 |
+
ensureLineHeights(cm, prepared.view, prepared.rect);
|
| 3602 |
+
prepared.hasHeights = true;
|
| 3603 |
}
|
| 3604 |
+
found = measureCharInner(cm, prepared, ch, bias);
|
| 3605 |
+
if (!found.bogus) { prepared.cache[key] = found; }
|
| 3606 |
}
|
| 3607 |
return {left: found.left, right: found.right,
|
| 3608 |
top: varHeight ? found.rtop : found.top,
|
| 3609 |
bottom: varHeight ? found.rbottom : found.bottom}
|
| 3610 |
}
|
| 3611 |
|
| 3612 |
+
var nullRect = {left: 0, right: 0, top: 0, bottom: 0};
|
| 3613 |
|
| 3614 |
+
function nodeAndOffsetInLineMap(map$$1, ch, bias) {
|
| 3615 |
+
var node, start, end, collapse, mStart, mEnd;
|
| 3616 |
// First, search the line map for the text node corresponding to,
|
| 3617 |
// or closest to, the target character.
|
| 3618 |
+
for (var i = 0; i < map$$1.length; i += 3) {
|
| 3619 |
+
mStart = map$$1[i];
|
| 3620 |
+
mEnd = map$$1[i + 1];
|
| 3621 |
if (ch < mStart) {
|
| 3622 |
+
start = 0; end = 1;
|
| 3623 |
+
collapse = "left";
|
| 3624 |
} else if (ch < mEnd) {
|
| 3625 |
+
start = ch - mStart;
|
| 3626 |
+
end = start + 1;
|
| 3627 |
+
} else if (i == map$$1.length - 3 || ch == mEnd && map$$1[i + 3] > ch) {
|
| 3628 |
+
end = mEnd - mStart;
|
| 3629 |
+
start = end - 1;
|
| 3630 |
+
if (ch >= mEnd) { collapse = "right"; }
|
| 3631 |
}
|
| 3632 |
if (start != null) {
|
| 3633 |
+
node = map$$1[i + 2];
|
| 3634 |
if (mStart == mEnd && bias == (node.insertLeft ? "left" : "right"))
|
| 3635 |
+
{ collapse = bias; }
|
| 3636 |
if (bias == "left" && start == 0)
|
| 3637 |
+
{ while (i && map$$1[i - 2] == map$$1[i - 3] && map$$1[i - 1].insertLeft) {
|
| 3638 |
+
node = map$$1[(i -= 3) + 2];
|
| 3639 |
+
collapse = "left";
|
| 3640 |
} }
|
| 3641 |
if (bias == "right" && start == mEnd - mStart)
|
| 3642 |
+
{ while (i < map$$1.length - 3 && map$$1[i + 3] == map$$1[i + 4] && !map$$1[i + 5].insertLeft) {
|
| 3643 |
+
node = map$$1[(i += 3) + 2];
|
| 3644 |
+
collapse = "right";
|
| 3645 |
} }
|
| 3646 |
break
|
| 3647 |
}
|
| 3650 |
}
|
| 3651 |
|
| 3652 |
function getUsefulRect(rects, bias) {
|
| 3653 |
+
var rect = nullRect;
|
| 3654 |
if (bias == "left") { for (var i = 0; i < rects.length; i++) {
|
| 3655 |
if ((rect = rects[i]).left != rect.right) { break }
|
| 3656 |
} } else { for (var i$1 = rects.length - 1; i$1 >= 0; i$1--) {
|
| 3660 |
}
|
| 3661 |
|
| 3662 |
function measureCharInner(cm, prepared, ch, bias) {
|
| 3663 |
+
var place = nodeAndOffsetInLineMap(prepared.map, ch, bias);
|
| 3664 |
+
var node = place.node, start = place.start, end = place.end, collapse = place.collapse;
|
| 3665 |
|
| 3666 |
+
var rect;
|
| 3667 |
if (node.nodeType == 3) { // If it is a text node, use a range to retrieve the coordinates.
|
| 3668 |
for (var i$1 = 0; i$1 < 4; i$1++) { // Retry a maximum of 4 times when nonsense rectangles are returned
|
| 3669 |
+
while (start && isExtendingChar(prepared.line.text.charAt(place.coverStart + start))) { --start; }
|
| 3670 |
+
while (place.coverStart + end < place.coverEnd && isExtendingChar(prepared.line.text.charAt(place.coverStart + end))) { ++end; }
|
| 3671 |
if (ie && ie_version < 9 && start == 0 && end == place.coverEnd - place.coverStart)
|
| 3672 |
+
{ rect = node.parentNode.getBoundingClientRect(); }
|
| 3673 |
else
|
| 3674 |
+
{ rect = getUsefulRect(range(node, start, end).getClientRects(), bias); }
|
| 3675 |
if (rect.left || rect.right || start == 0) { break }
|
| 3676 |
+
end = start;
|
| 3677 |
+
start = start - 1;
|
| 3678 |
+
collapse = "right";
|
| 3679 |
}
|
| 3680 |
+
if (ie && ie_version < 11) { rect = maybeUpdateRectForZooming(cm.display.measure, rect); }
|
| 3681 |
} else { // If it is a widget, simply get the box for the whole widget.
|
| 3682 |
+
if (start > 0) { collapse = bias = "right"; }
|
| 3683 |
+
var rects;
|
| 3684 |
if (cm.options.lineWrapping && (rects = node.getClientRects()).length > 1)
|
| 3685 |
+
{ rect = rects[bias == "right" ? rects.length - 1 : 0]; }
|
| 3686 |
else
|
| 3687 |
+
{ rect = node.getBoundingClientRect(); }
|
| 3688 |
}
|
| 3689 |
if (ie && ie_version < 9 && !start && (!rect || !rect.left && !rect.right)) {
|
| 3690 |
+
var rSpan = node.parentNode.getClientRects()[0];
|
| 3691 |
if (rSpan)
|
| 3692 |
+
{ rect = {left: rSpan.left, right: rSpan.left + charWidth(cm.display), top: rSpan.top, bottom: rSpan.bottom}; }
|
| 3693 |
else
|
| 3694 |
+
{ rect = nullRect; }
|
| 3695 |
}
|
| 3696 |
|
| 3697 |
+
var rtop = rect.top - prepared.rect.top, rbot = rect.bottom - prepared.rect.top;
|
| 3698 |
+
var mid = (rtop + rbot) / 2;
|
| 3699 |
+
var heights = prepared.view.measure.heights;
|
| 3700 |
+
var i = 0;
|
| 3701 |
for (; i < heights.length - 1; i++)
|
| 3702 |
{ if (mid < heights[i]) { break } }
|
| 3703 |
+
var top = i ? heights[i - 1] : 0, bot = heights[i];
|
| 3704 |
var result = {left: (collapse == "right" ? rect.right : rect.left) - prepared.rect.left,
|
| 3705 |
right: (collapse == "left" ? rect.left : rect.right) - prepared.rect.left,
|
| 3706 |
+
top: top, bottom: bot};
|
| 3707 |
+
if (!rect.left && !rect.right) { result.bogus = true; }
|
| 3708 |
+
if (!cm.options.singleCursorHeightPerLine) { result.rtop = rtop; result.rbottom = rbot; }
|
| 3709 |
|
| 3710 |
return result
|
| 3711 |
}
|
| 3716 |
if (!window.screen || screen.logicalXDPI == null ||
|
| 3717 |
screen.logicalXDPI == screen.deviceXDPI || !hasBadZoomedRects(measure))
|
| 3718 |
{ return rect }
|
| 3719 |
+
var scaleX = screen.logicalXDPI / screen.deviceXDPI;
|
| 3720 |
+
var scaleY = screen.logicalYDPI / screen.deviceYDPI;
|
| 3721 |
return {left: rect.left * scaleX, right: rect.right * scaleX,
|
| 3722 |
top: rect.top * scaleY, bottom: rect.bottom * scaleY}
|
| 3723 |
}
|
| 3724 |
|
| 3725 |
function clearLineMeasurementCacheFor(lineView) {
|
| 3726 |
if (lineView.measure) {
|
| 3727 |
+
lineView.measure.cache = {};
|
| 3728 |
+
lineView.measure.heights = null;
|
| 3729 |
if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)
|
| 3730 |
+
{ lineView.measure.caches[i] = {}; } }
|
| 3731 |
}
|
| 3732 |
}
|
| 3733 |
|
| 3734 |
function clearLineMeasurementCache(cm) {
|
| 3735 |
+
cm.display.externalMeasure = null;
|
| 3736 |
+
removeChildren(cm.display.lineMeasure);
|
| 3737 |
for (var i = 0; i < cm.display.view.length; i++)
|
| 3738 |
+
{ clearLineMeasurementCacheFor(cm.display.view[i]); }
|
| 3739 |
}
|
| 3740 |
|
| 3741 |
function clearCaches(cm) {
|
| 3742 |
+
clearLineMeasurementCache(cm);
|
| 3743 |
+
cm.display.cachedCharWidth = cm.display.cachedTextHeight = cm.display.cachedPaddingH = null;
|
| 3744 |
+
if (!cm.options.lineWrapping) { cm.display.maxLineChanged = true; }
|
| 3745 |
+
cm.display.lineNumChars = null;
|
| 3746 |
}
|
| 3747 |
|
| 3748 |
function pageScrollX() { return window.pageXOffset || (document.documentElement || document.body).scrollLeft }
|
| 3754 |
// or "page".
|
| 3755 |
function intoCoordSystem(cm, lineObj, rect, context, includeWidgets) {
|
| 3756 |
if (!includeWidgets && lineObj.widgets) { for (var i = 0; i < lineObj.widgets.length; ++i) { if (lineObj.widgets[i].above) {
|
| 3757 |
+
var size = widgetHeight(lineObj.widgets[i]);
|
| 3758 |
+
rect.top += size; rect.bottom += size;
|
| 3759 |
} } }
|
| 3760 |
if (context == "line") { return rect }
|
| 3761 |
+
if (!context) { context = "local"; }
|
| 3762 |
+
var yOff = heightAtLine(lineObj);
|
| 3763 |
+
if (context == "local") { yOff += paddingTop(cm.display); }
|
| 3764 |
+
else { yOff -= cm.display.viewOffset; }
|
| 3765 |
if (context == "page" || context == "window") {
|
| 3766 |
+
var lOff = cm.display.lineSpace.getBoundingClientRect();
|
| 3767 |
+
yOff += lOff.top + (context == "window" ? 0 : pageScrollY());
|
| 3768 |
+
var xOff = lOff.left + (context == "window" ? 0 : pageScrollX());
|
| 3769 |
+
rect.left += xOff; rect.right += xOff;
|
| 3770 |
}
|
| 3771 |
+
rect.top += yOff; rect.bottom += yOff;
|
| 3772 |
return rect
|
| 3773 |
}
|
| 3774 |
|
| 3776 |
// Context may be "window", "page", "div", or "local"./null.
|
| 3777 |
function fromCoordSystem(cm, coords, context) {
|
| 3778 |
if (context == "div") { return coords }
|
| 3779 |
+
var left = coords.left, top = coords.top;
|
| 3780 |
// First move into "page" coordinate system
|
| 3781 |
if (context == "page") {
|
| 3782 |
+
left -= pageScrollX();
|
| 3783 |
+
top -= pageScrollY();
|
| 3784 |
} else if (context == "local" || !context) {
|
| 3785 |
+
var localBox = cm.display.sizer.getBoundingClientRect();
|
| 3786 |
+
left += localBox.left;
|
| 3787 |
+
top += localBox.top;
|
| 3788 |
}
|
| 3789 |
|
| 3790 |
+
var lineSpaceBox = cm.display.lineSpace.getBoundingClientRect();
|
| 3791 |
return {left: left - lineSpaceBox.left, top: top - lineSpaceBox.top}
|
| 3792 |
}
|
| 3793 |
|
| 3794 |
function charCoords(cm, pos, context, lineObj, bias) {
|
| 3795 |
+
if (!lineObj) { lineObj = getLine(cm.doc, pos.line); }
|
| 3796 |
return intoCoordSystem(cm, lineObj, measureChar(cm, lineObj, pos.ch, bias), context)
|
| 3797 |
}
|
| 3798 |
|
| 3813 |
// Every position after the last character on a line is considered to stick
|
| 3814 |
// to the last character on the line.
|
| 3815 |
function cursorCoords(cm, pos, context, lineObj, preparedMeasure, varHeight) {
|
| 3816 |
+
lineObj = lineObj || getLine(cm.doc, pos.line);
|
| 3817 |
+
if (!preparedMeasure) { preparedMeasure = prepareMeasureForLine(cm, lineObj); }
|
| 3818 |
function get(ch, right) {
|
| 3819 |
+
var m = measureCharPrepared(cm, preparedMeasure, ch, right ? "right" : "left", varHeight);
|
| 3820 |
+
if (right) { m.left = m.right; } else { m.right = m.left; }
|
| 3821 |
return intoCoordSystem(cm, lineObj, m, context)
|
| 3822 |
}
|
| 3823 |
+
var order = getOrder(lineObj, cm.doc.direction), ch = pos.ch, sticky = pos.sticky;
|
| 3824 |
if (ch >= lineObj.text.length) {
|
| 3825 |
+
ch = lineObj.text.length;
|
| 3826 |
+
sticky = "before";
|
| 3827 |
} else if (ch <= 0) {
|
| 3828 |
+
ch = 0;
|
| 3829 |
+
sticky = "after";
|
| 3830 |
}
|
| 3831 |
if (!order) { return get(sticky == "before" ? ch - 1 : ch, sticky == "before") }
|
| 3832 |
|
| 3833 |
function getBidi(ch, partPos, invert) {
|
| 3834 |
+
var part = order[partPos], right = (part.level % 2) != 0;
|
| 3835 |
return get(invert ? ch - 1 : ch, right != invert)
|
| 3836 |
}
|
| 3837 |
+
var partPos = getBidiPartAt(order, ch, sticky);
|
| 3838 |
+
var other = bidiOther;
|
| 3839 |
+
var val = getBidi(ch, partPos, sticky == "before");
|
| 3840 |
+
if (other != null) { val.other = getBidi(ch, other, sticky != "before"); }
|
| 3841 |
return val
|
| 3842 |
}
|
| 3843 |
|
| 3844 |
// Used to cheaply estimate the coordinates for a position. Used for
|
| 3845 |
// intermediate scroll updates.
|
| 3846 |
function estimateCoords(cm, pos) {
|
| 3847 |
+
var left = 0;
|
| 3848 |
+
pos = clipPos(cm.doc, pos);
|
| 3849 |
+
if (!cm.options.lineWrapping) { left = charWidth(cm.display) * pos.ch; }
|
| 3850 |
+
var lineObj = getLine(cm.doc, pos.line);
|
| 3851 |
+
var top = heightAtLine(lineObj) + paddingTop(cm.display);
|
| 3852 |
return {left: left, right: left, top: top, bottom: top + lineObj.height}
|
| 3853 |
}
|
| 3854 |
|
| 3859 |
// is true, that means the coordinates lie outside the line's
|
| 3860 |
// vertical range.
|
| 3861 |
function PosWithInfo(line, ch, sticky, outside, xRel) {
|
| 3862 |
+
var pos = Pos(line, ch, sticky);
|
| 3863 |
+
pos.xRel = xRel;
|
| 3864 |
+
if (outside) { pos.outside = true; }
|
| 3865 |
return pos
|
| 3866 |
}
|
| 3867 |
|
| 3868 |
// Compute the character position closest to the given coordinates.
|
| 3869 |
// Input must be lineSpace-local ("div" coordinate system).
|
| 3870 |
function coordsChar(cm, x, y) {
|
| 3871 |
+
var doc = cm.doc;
|
| 3872 |
+
y += cm.display.viewOffset;
|
| 3873 |
if (y < 0) { return PosWithInfo(doc.first, 0, null, true, -1) }
|
| 3874 |
+
var lineN = lineAtHeight(doc, y), last = doc.first + doc.size - 1;
|
| 3875 |
if (lineN > last)
|
| 3876 |
{ return PosWithInfo(doc.first + doc.size - 1, getLine(doc, last).text.length, null, true, 1) }
|
| 3877 |
+
if (x < 0) { x = 0; }
|
| 3878 |
|
| 3879 |
+
var lineObj = getLine(doc, lineN);
|
| 3880 |
for (;;) {
|
| 3881 |
+
var found = coordsCharInner(cm, lineObj, lineN, x, y);
|
| 3882 |
+
var merged = collapsedSpanAtEnd(lineObj);
|
| 3883 |
+
var mergedPos = merged && merged.find(0, true);
|
| 3884 |
if (merged && (found.ch > mergedPos.from.ch || found.ch == mergedPos.from.ch && found.xRel > 0))
|
| 3885 |
+
{ lineN = lineNo(lineObj = mergedPos.to.line); }
|
| 3886 |
else
|
| 3887 |
{ return found }
|
| 3888 |
}
|
| 3889 |
}
|
| 3890 |
|
| 3891 |
function wrappedLineExtent(cm, lineObj, preparedMeasure, y) {
|
| 3892 |
+
var measure = function (ch) { return intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, ch), "line"); };
|
| 3893 |
+
var end = lineObj.text.length;
|
| 3894 |
+
var begin = findFirst(function (ch) { return measure(ch - 1).bottom <= y; }, end, 0);
|
| 3895 |
+
end = findFirst(function (ch) { return measure(ch).top > y; }, begin, end);
|
| 3896 |
return {begin: begin, end: end}
|
| 3897 |
}
|
| 3898 |
|
| 3899 |
function wrappedLineExtentChar(cm, lineObj, preparedMeasure, target) {
|
| 3900 |
+
var targetTop = intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, target), "line").top;
|
| 3901 |
return wrappedLineExtent(cm, lineObj, preparedMeasure, targetTop)
|
| 3902 |
}
|
| 3903 |
|
| 3904 |
+
function coordsCharInner(cm, lineObj, lineNo$$1, x, y) {
|
| 3905 |
+
y -= heightAtLine(lineObj);
|
| 3906 |
+
var begin = 0, end = lineObj.text.length;
|
| 3907 |
+
var preparedMeasure = prepareMeasureForLine(cm, lineObj);
|
| 3908 |
+
var pos;
|
| 3909 |
+
var order = getOrder(lineObj, cm.doc.direction);
|
| 3910 |
if (order) {
|
| 3911 |
if (cm.options.lineWrapping) {
|
| 3912 |
+
var assign;
|
| 3913 |
+
((assign = wrappedLineExtent(cm, lineObj, preparedMeasure, y), begin = assign.begin, end = assign.end, assign));
|
| 3914 |
}
|
| 3915 |
+
pos = new Pos(lineNo$$1, begin);
|
| 3916 |
+
var beginLeft = cursorCoords(cm, pos, "line", lineObj, preparedMeasure).left;
|
| 3917 |
+
var dir = beginLeft < x ? 1 : -1;
|
| 3918 |
+
var prevDiff, diff = beginLeft - x, prevPos;
|
| 3919 |
do {
|
| 3920 |
+
prevDiff = diff;
|
| 3921 |
+
prevPos = pos;
|
| 3922 |
+
pos = moveVisually(cm, lineObj, pos, dir);
|
| 3923 |
if (pos == null || pos.ch < begin || end <= (pos.sticky == "before" ? pos.ch - 1 : pos.ch)) {
|
| 3924 |
+
pos = prevPos;
|
| 3925 |
break
|
| 3926 |
}
|
| 3927 |
+
diff = cursorCoords(cm, pos, "line", lineObj, preparedMeasure).left - x;
|
| 3928 |
} while ((dir < 0) != (diff < 0) && (Math.abs(diff) <= Math.abs(prevDiff)))
|
| 3929 |
if (Math.abs(diff) > Math.abs(prevDiff)) {
|
| 3930 |
if ((diff < 0) == (prevDiff < 0)) { throw new Error("Broke out of infinite loop in coordsCharInner") }
|
| 3931 |
+
pos = prevPos;
|
| 3932 |
}
|
| 3933 |
} else {
|
| 3934 |
var ch = findFirst(function (ch) {
|
| 3935 |
+
var box = intoCoordSystem(cm, lineObj, measureCharPrepared(cm, preparedMeasure, ch), "line");
|
| 3936 |
if (box.top > y) {
|
| 3937 |
// For the cursor stickiness
|
| 3938 |
+
end = Math.min(ch, end);
|
| 3939 |
return true
|
| 3940 |
}
|
| 3941 |
else if (box.bottom <= y) { return false }
|
| 3942 |
else if (box.left > x) { return true }
|
| 3943 |
else if (box.right < x) { return false }
|
| 3944 |
else { return (x - box.left < box.right - x) }
|
| 3945 |
+
}, begin, end);
|
| 3946 |
+
ch = skipExtendingChars(lineObj.text, ch, 1);
|
| 3947 |
+
pos = new Pos(lineNo$$1, ch, ch == end ? "before" : "after");
|
| 3948 |
}
|
| 3949 |
+
var coords = cursorCoords(cm, pos, "line", lineObj, preparedMeasure);
|
| 3950 |
+
if (y < coords.top || coords.bottom < y) { pos.outside = true; }
|
| 3951 |
+
pos.xRel = x < coords.left ? -1 : (x > coords.right ? 1 : 0);
|
| 3952 |
return pos
|
| 3953 |
}
|
| 3954 |
|
| 3955 |
+
var measureText;
|
| 3956 |
// Compute the default text height.
|
| 3957 |
function textHeight(display) {
|
| 3958 |
if (display.cachedTextHeight != null) { return display.cachedTextHeight }
|
| 3959 |
if (measureText == null) {
|
| 3960 |
+
measureText = elt("pre");
|
| 3961 |
// Measure a bunch of lines, for browsers that compute
|
| 3962 |
// fractional heights.
|
| 3963 |
for (var i = 0; i < 49; ++i) {
|
| 3964 |
+
measureText.appendChild(document.createTextNode("x"));
|
| 3965 |
+
measureText.appendChild(elt("br"));
|
| 3966 |
}
|
| 3967 |
+
measureText.appendChild(document.createTextNode("x"));
|
| 3968 |
}
|
| 3969 |
+
removeChildrenAndAdd(display.measure, measureText);
|
| 3970 |
+
var height = measureText.offsetHeight / 50;
|
| 3971 |
+
if (height > 3) { display.cachedTextHeight = height; }
|
| 3972 |
+
removeChildren(display.measure);
|
| 3973 |
return height || 1
|
| 3974 |
}
|
| 3975 |
|
| 3976 |
// Compute the default character width.
|
| 3977 |
function charWidth(display) {
|
| 3978 |
if (display.cachedCharWidth != null) { return display.cachedCharWidth }
|
| 3979 |
+
var anchor = elt("span", "xxxxxxxxxx");
|
| 3980 |
+
var pre = elt("pre", [anchor]);
|
| 3981 |
+
removeChildrenAndAdd(display.measure, pre);
|
| 3982 |
+
var rect = anchor.getBoundingClientRect(), width = (rect.right - rect.left) / 10;
|
| 3983 |
+
if (width > 2) { display.cachedCharWidth = width; }
|
| 3984 |
return width || 10
|
| 3985 |
}
|
| 3986 |
|
| 3987 |
// Do a bulk-read of the DOM positions and sizes needed to draw the
|
| 3988 |
// view, so that we don't interleave reading and writing to the DOM.
|
| 3989 |
function getDimensions(cm) {
|
| 3990 |
+
var d = cm.display, left = {}, width = {};
|
| 3991 |
+
var gutterLeft = d.gutters.clientLeft;
|
| 3992 |
for (var n = d.gutters.firstChild, i = 0; n; n = n.nextSibling, ++i) {
|
| 3993 |
+
left[cm.options.gutters[i]] = n.offsetLeft + n.clientLeft + gutterLeft;
|
| 3994 |
+
width[cm.options.gutters[i]] = n.clientWidth;
|
| 3995 |
}
|
| 3996 |
return {fixedPos: compensateForHScroll(d),
|
| 3997 |
gutterTotalWidth: d.gutters.offsetWidth,
|
| 4011 |
// first approximation until the line becomes visible (and is thus
|
| 4012 |
// properly measurable).
|
| 4013 |
function estimateHeight(cm) {
|
| 4014 |
+
var th = textHeight(cm.display), wrapping = cm.options.lineWrapping;
|
| 4015 |
+
var perLine = wrapping && Math.max(5, cm.display.scroller.clientWidth / charWidth(cm.display) - 3);
|
| 4016 |
return function (line) {
|
| 4017 |
if (lineIsHidden(cm.doc, line)) { return 0 }
|
| 4018 |
|
| 4019 |
+
var widgetsHeight = 0;
|
| 4020 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; i++) {
|
| 4021 |
+
if (line.widgets[i].height) { widgetsHeight += line.widgets[i].height; }
|
| 4022 |
} }
|
| 4023 |
|
| 4024 |
if (wrapping)
|
| 4029 |
}
|
| 4030 |
|
| 4031 |
function estimateLineHeights(cm) {
|
| 4032 |
+
var doc = cm.doc, est = estimateHeight(cm);
|
| 4033 |
doc.iter(function (line) {
|
| 4034 |
+
var estHeight = est(line);
|
| 4035 |
+
if (estHeight != line.height) { updateLineHeight(line, estHeight); }
|
| 4036 |
+
});
|
| 4037 |
}
|
| 4038 |
|
| 4039 |
// Given a mouse event, find the corresponding position. If liberal
|
| 4042 |
// selections, and tries to estimate a character position even for
|
| 4043 |
// coordinates beyond the right of the text.
|
| 4044 |
function posFromMouse(cm, e, liberal, forRect) {
|
| 4045 |
+
var display = cm.display;
|
| 4046 |
if (!liberal && e_target(e).getAttribute("cm-not-content") == "true") { return null }
|
| 4047 |
|
| 4048 |
+
var x, y, space = display.lineSpace.getBoundingClientRect();
|
| 4049 |
// Fails unpredictably on IE[67] when mouse is dragged around quickly.
|
| 4050 |
+
try { x = e.clientX - space.left; y = e.clientY - space.top; }
|
| 4051 |
catch (e) { return null }
|
| 4052 |
+
var coords = coordsChar(cm, x, y), line;
|
| 4053 |
if (forRect && coords.xRel == 1 && (line = getLine(cm.doc, coords.line).text).length == coords.ch) {
|
| 4054 |
+
var colDiff = countColumn(line, line.length, cm.options.tabSize) - line.length;
|
| 4055 |
+
coords = Pos(coords.line, Math.max(0, Math.round((x - paddingH(cm.display).left) / charWidth(cm.display)) - colDiff));
|
| 4056 |
}
|
| 4057 |
return coords
|
| 4058 |
}
|
| 4061 |
// when the line isn't visible.
|
| 4062 |
function findViewIndex(cm, n) {
|
| 4063 |
if (n >= cm.display.viewTo) { return null }
|
| 4064 |
+
n -= cm.display.viewFrom;
|
| 4065 |
if (n < 0) { return null }
|
| 4066 |
+
var view = cm.display.view;
|
| 4067 |
for (var i = 0; i < view.length; i++) {
|
| 4068 |
+
n -= view[i].size;
|
| 4069 |
if (n < 0) { return i }
|
| 4070 |
}
|
| 4071 |
}
|
| 4072 |
|
| 4073 |
function updateSelection(cm) {
|
| 4074 |
+
cm.display.input.showSelection(cm.display.input.prepareSelection());
|
| 4075 |
}
|
| 4076 |
|
| 4077 |
function prepareSelection(cm, primary) {
|
| 4078 |
+
var doc = cm.doc, result = {};
|
| 4079 |
+
var curFragment = result.cursors = document.createDocumentFragment();
|
| 4080 |
+
var selFragment = result.selection = document.createDocumentFragment();
|
| 4081 |
|
| 4082 |
for (var i = 0; i < doc.sel.ranges.length; i++) {
|
| 4083 |
if (primary === false && i == doc.sel.primIndex) { continue }
|
| 4084 |
+
var range$$1 = doc.sel.ranges[i];
|
| 4085 |
+
if (range$$1.from().line >= cm.display.viewTo || range$$1.to().line < cm.display.viewFrom) { continue }
|
| 4086 |
+
var collapsed = range$$1.empty();
|
| 4087 |
if (collapsed || cm.options.showCursorWhenSelecting)
|
| 4088 |
+
{ drawSelectionCursor(cm, range$$1.head, curFragment); }
|
| 4089 |
if (!collapsed)
|
| 4090 |
+
{ drawSelectionRange(cm, range$$1, selFragment); }
|
| 4091 |
}
|
| 4092 |
return result
|
| 4093 |
}
|
| 4094 |
|
| 4095 |
// Draws a cursor for the given range
|
| 4096 |
function drawSelectionCursor(cm, head, output) {
|
| 4097 |
+
var pos = cursorCoords(cm, head, "div", null, null, !cm.options.singleCursorHeightPerLine);
|
| 4098 |
|
| 4099 |
+
var cursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor"));
|
| 4100 |
+
cursor.style.left = pos.left + "px";
|
| 4101 |
+
cursor.style.top = pos.top + "px";
|
| 4102 |
+
cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + "px";
|
| 4103 |
|
| 4104 |
if (pos.other) {
|
| 4105 |
// Secondary cursor, shown when on a 'jump' in bi-directional text
|
| 4106 |
+
var otherCursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor CodeMirror-secondarycursor"));
|
| 4107 |
+
otherCursor.style.display = "";
|
| 4108 |
+
otherCursor.style.left = pos.other.left + "px";
|
| 4109 |
+
otherCursor.style.top = pos.other.top + "px";
|
| 4110 |
+
otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + "px";
|
| 4111 |
}
|
| 4112 |
}
|
| 4113 |
|
| 4114 |
// Draws the given range as a highlighted selection
|
| 4115 |
+
function drawSelectionRange(cm, range$$1, output) {
|
| 4116 |
+
var display = cm.display, doc = cm.doc;
|
| 4117 |
+
var fragment = document.createDocumentFragment();
|
| 4118 |
+
var padding = paddingH(cm.display), leftSide = padding.left;
|
| 4119 |
+
var rightSide = Math.max(display.sizerWidth, displayWidth(cm) - display.sizer.offsetLeft) - padding.right;
|
| 4120 |
|
| 4121 |
function add(left, top, width, bottom) {
|
| 4122 |
+
if (top < 0) { top = 0; }
|
| 4123 |
+
top = Math.round(top);
|
| 4124 |
+
bottom = Math.round(bottom);
|
| 4125 |
+
fragment.appendChild(elt("div", null, "CodeMirror-selected", ("position: absolute; left: " + left + "px;\n top: " + top + "px; width: " + (width == null ? rightSide - left : width) + "px;\n height: " + (bottom - top) + "px")));
|
| 4126 |
}
|
| 4127 |
|
| 4128 |
function drawForLine(line, fromArg, toArg) {
|
| 4129 |
+
var lineObj = getLine(doc, line);
|
| 4130 |
+
var lineLen = lineObj.text.length;
|
| 4131 |
+
var start, end;
|
| 4132 |
function coords(ch, bias) {
|
| 4133 |
return charCoords(cm, Pos(line, ch), "div", lineObj, bias)
|
| 4134 |
}
|
| 4135 |
|
| 4136 |
+
iterateBidiSections(getOrder(lineObj, doc.direction), fromArg || 0, toArg == null ? lineLen : toArg, function (from, to, dir) {
|
| 4137 |
+
var leftPos = coords(from, "left"), rightPos, left, right;
|
| 4138 |
if (from == to) {
|
| 4139 |
+
rightPos = leftPos;
|
| 4140 |
+
left = right = leftPos.left;
|
| 4141 |
} else {
|
| 4142 |
+
rightPos = coords(to - 1, "right");
|
| 4143 |
+
if (dir == "rtl") { var tmp = leftPos; leftPos = rightPos; rightPos = tmp; }
|
| 4144 |
+
left = leftPos.left;
|
| 4145 |
+
right = rightPos.right;
|
| 4146 |
}
|
| 4147 |
+
if (fromArg == null && from == 0) { left = leftSide; }
|
| 4148 |
if (rightPos.top - leftPos.top > 3) { // Different lines, draw top part
|
| 4149 |
+
add(left, leftPos.top, null, leftPos.bottom);
|
| 4150 |
+
left = leftSide;
|
| 4151 |
+
if (leftPos.bottom < rightPos.top) { add(left, leftPos.bottom, null, rightPos.top); }
|
| 4152 |
}
|
| 4153 |
+
if (toArg == null && to == lineLen) { right = rightSide; }
|
| 4154 |
if (!start || leftPos.top < start.top || leftPos.top == start.top && leftPos.left < start.left)
|
| 4155 |
+
{ start = leftPos; }
|
| 4156 |
if (!end || rightPos.bottom > end.bottom || rightPos.bottom == end.bottom && rightPos.right > end.right)
|
| 4157 |
+
{ end = rightPos; }
|
| 4158 |
+
if (left < leftSide + 1) { left = leftSide; }
|
| 4159 |
+
add(left, rightPos.top, right - left, rightPos.bottom);
|
| 4160 |
+
});
|
| 4161 |
return {start: start, end: end}
|
| 4162 |
}
|
| 4163 |
|
| 4164 |
+
var sFrom = range$$1.from(), sTo = range$$1.to();
|
| 4165 |
if (sFrom.line == sTo.line) {
|
| 4166 |
+
drawForLine(sFrom.line, sFrom.ch, sTo.ch);
|
| 4167 |
} else {
|
| 4168 |
+
var fromLine = getLine(doc, sFrom.line), toLine = getLine(doc, sTo.line);
|
| 4169 |
+
var singleVLine = visualLine(fromLine) == visualLine(toLine);
|
| 4170 |
+
var leftEnd = drawForLine(sFrom.line, sFrom.ch, singleVLine ? fromLine.text.length + 1 : null).end;
|
| 4171 |
+
var rightStart = drawForLine(sTo.line, singleVLine ? 0 : null, sTo.ch).start;
|
| 4172 |
if (singleVLine) {
|
| 4173 |
if (leftEnd.top < rightStart.top - 2) {
|
| 4174 |
+
add(leftEnd.right, leftEnd.top, null, leftEnd.bottom);
|
| 4175 |
+
add(leftSide, rightStart.top, rightStart.left, rightStart.bottom);
|
| 4176 |
} else {
|
| 4177 |
+
add(leftEnd.right, leftEnd.top, rightStart.left - leftEnd.right, leftEnd.bottom);
|
| 4178 |
}
|
| 4179 |
}
|
| 4180 |
if (leftEnd.bottom < rightStart.top)
|
| 4181 |
+
{ add(leftSide, leftEnd.bottom, null, rightStart.top); }
|
| 4182 |
}
|
| 4183 |
|
| 4184 |
+
output.appendChild(fragment);
|
| 4185 |
}
|
| 4186 |
|
| 4187 |
// Cursor-blinking
|
| 4188 |
function restartBlink(cm) {
|
| 4189 |
if (!cm.state.focused) { return }
|
| 4190 |
+
var display = cm.display;
|
| 4191 |
+
clearInterval(display.blinker);
|
| 4192 |
+
var on = true;
|
| 4193 |
+
display.cursorDiv.style.visibility = "";
|
| 4194 |
if (cm.options.cursorBlinkRate > 0)
|
| 4195 |
{ display.blinker = setInterval(function () { return display.cursorDiv.style.visibility = (on = !on) ? "" : "hidden"; },
|
| 4196 |
+
cm.options.cursorBlinkRate); }
|
| 4197 |
else if (cm.options.cursorBlinkRate < 0)
|
| 4198 |
+
{ display.cursorDiv.style.visibility = "hidden"; }
|
| 4199 |
}
|
| 4200 |
|
| 4201 |
function ensureFocus(cm) {
|
| 4202 |
+
if (!cm.state.focused) { cm.display.input.focus(); onFocus(cm); }
|
| 4203 |
}
|
| 4204 |
|
| 4205 |
function delayBlurEvent(cm) {
|
| 4206 |
+
cm.state.delayingBlurEvent = true;
|
| 4207 |
setTimeout(function () { if (cm.state.delayingBlurEvent) {
|
| 4208 |
+
cm.state.delayingBlurEvent = false;
|
| 4209 |
+
onBlur(cm);
|
| 4210 |
+
} }, 100);
|
| 4211 |
}
|
| 4212 |
|
| 4213 |
function onFocus(cm, e) {
|
| 4214 |
+
if (cm.state.delayingBlurEvent) { cm.state.delayingBlurEvent = false; }
|
| 4215 |
|
| 4216 |
if (cm.options.readOnly == "nocursor") { return }
|
| 4217 |
if (!cm.state.focused) {
|
| 4218 |
+
signal(cm, "focus", cm, e);
|
| 4219 |
+
cm.state.focused = true;
|
| 4220 |
+
addClass(cm.display.wrapper, "CodeMirror-focused");
|
| 4221 |
// This test prevents this from firing when a context
|
| 4222 |
// menu is closed (since the input reset would kill the
|
| 4223 |
// select-all detection hack)
|
| 4224 |
if (!cm.curOp && cm.display.selForContextMenu != cm.doc.sel) {
|
| 4225 |
+
cm.display.input.reset();
|
| 4226 |
+
if (webkit) { setTimeout(function () { return cm.display.input.reset(true); }, 20); } // Issue #1730
|
| 4227 |
}
|
| 4228 |
+
cm.display.input.receivedFocus();
|
| 4229 |
}
|
| 4230 |
+
restartBlink(cm);
|
| 4231 |
}
|
| 4232 |
function onBlur(cm, e) {
|
| 4233 |
if (cm.state.delayingBlurEvent) { return }
|
| 4234 |
|
| 4235 |
if (cm.state.focused) {
|
| 4236 |
+
signal(cm, "blur", cm, e);
|
| 4237 |
+
cm.state.focused = false;
|
| 4238 |
+
rmClass(cm.display.wrapper, "CodeMirror-focused");
|
| 4239 |
}
|
| 4240 |
+
clearInterval(cm.display.blinker);
|
| 4241 |
+
setTimeout(function () { if (!cm.state.focused) { cm.display.shift = false; } }, 150);
|
| 4242 |
}
|
| 4243 |
|
| 4244 |
// Re-align line numbers and gutter marks to compensate for
|
| 4245 |
// horizontal scrolling.
|
| 4246 |
function alignHorizontally(cm) {
|
| 4247 |
+
var display = cm.display, view = display.view;
|
| 4248 |
if (!display.alignWidgets && (!display.gutters.firstChild || !cm.options.fixedGutter)) { return }
|
| 4249 |
+
var comp = compensateForHScroll(display) - display.scroller.scrollLeft + cm.doc.scrollLeft;
|
| 4250 |
+
var gutterW = display.gutters.offsetWidth, left = comp + "px";
|
| 4251 |
for (var i = 0; i < view.length; i++) { if (!view[i].hidden) {
|
| 4252 |
if (cm.options.fixedGutter) {
|
| 4253 |
if (view[i].gutter)
|
| 4254 |
+
{ view[i].gutter.style.left = left; }
|
| 4255 |
if (view[i].gutterBackground)
|
| 4256 |
+
{ view[i].gutterBackground.style.left = left; }
|
| 4257 |
}
|
| 4258 |
+
var align = view[i].alignable;
|
| 4259 |
if (align) { for (var j = 0; j < align.length; j++)
|
| 4260 |
+
{ align[j].style.left = left; } }
|
| 4261 |
} }
|
| 4262 |
if (cm.options.fixedGutter)
|
| 4263 |
+
{ display.gutters.style.left = (comp + gutterW) + "px"; }
|
| 4264 |
}
|
| 4265 |
|
| 4266 |
// Used to ensure that the line number gutter is still the right
|
| 4268 |
// is needed.
|
| 4269 |
function maybeUpdateLineNumberWidth(cm) {
|
| 4270 |
if (!cm.options.lineNumbers) { return false }
|
| 4271 |
+
var doc = cm.doc, last = lineNumberFor(cm.options, doc.first + doc.size - 1), display = cm.display;
|
| 4272 |
if (last.length != display.lineNumChars) {
|
| 4273 |
var test = display.measure.appendChild(elt("div", [elt("div", last)],
|
| 4274 |
+
"CodeMirror-linenumber CodeMirror-gutter-elt"));
|
| 4275 |
+
var innerW = test.firstChild.offsetWidth, padding = test.offsetWidth - innerW;
|
| 4276 |
+
display.lineGutter.style.width = "";
|
| 4277 |
+
display.lineNumInnerWidth = Math.max(innerW, display.lineGutter.offsetWidth - padding) + 1;
|
| 4278 |
+
display.lineNumWidth = display.lineNumInnerWidth + padding;
|
| 4279 |
+
display.lineNumChars = display.lineNumInnerWidth ? last.length : -1;
|
| 4280 |
+
display.lineGutter.style.width = display.lineNumWidth + "px";
|
| 4281 |
+
updateGutterSpace(cm);
|
| 4282 |
return true
|
| 4283 |
}
|
| 4284 |
return false
|
| 4287 |
// Read the actual heights of the rendered lines, and update their
|
| 4288 |
// stored heights to match.
|
| 4289 |
function updateHeightsInViewport(cm) {
|
| 4290 |
+
var display = cm.display;
|
| 4291 |
+
var prevBottom = display.lineDiv.offsetTop;
|
| 4292 |
for (var i = 0; i < display.view.length; i++) {
|
| 4293 |
+
var cur = display.view[i], height = (void 0);
|
| 4294 |
if (cur.hidden) { continue }
|
| 4295 |
if (ie && ie_version < 8) {
|
| 4296 |
+
var bot = cur.node.offsetTop + cur.node.offsetHeight;
|
| 4297 |
+
height = bot - prevBottom;
|
| 4298 |
+
prevBottom = bot;
|
| 4299 |
} else {
|
| 4300 |
+
var box = cur.node.getBoundingClientRect();
|
| 4301 |
+
height = box.bottom - box.top;
|
| 4302 |
}
|
| 4303 |
+
var diff = cur.line.height - height;
|
| 4304 |
+
if (height < 2) { height = textHeight(display); }
|
| 4305 |
if (diff > .001 || diff < -.001) {
|
| 4306 |
+
updateLineHeight(cur.line, height);
|
| 4307 |
+
updateWidgetHeight(cur.line);
|
| 4308 |
if (cur.rest) { for (var j = 0; j < cur.rest.length; j++)
|
| 4309 |
+
{ updateWidgetHeight(cur.rest[j]); } }
|
| 4310 |
}
|
| 4311 |
}
|
| 4312 |
}
|
| 4315 |
// given line.
|
| 4316 |
function updateWidgetHeight(line) {
|
| 4317 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; ++i)
|
| 4318 |
+
{ line.widgets[i].height = line.widgets[i].node.parentNode.offsetHeight; } }
|
| 4319 |
}
|
| 4320 |
|
| 4321 |
// Compute the lines that are visible in a given viewport (defaults
|
| 4322 |
// the the current scroll position). viewport may contain top,
|
| 4323 |
// height, and ensure (see op.scrollToPos) properties.
|
| 4324 |
function visibleLines(display, doc, viewport) {
|
| 4325 |
+
var top = viewport && viewport.top != null ? Math.max(0, viewport.top) : display.scroller.scrollTop;
|
| 4326 |
+
top = Math.floor(top - paddingTop(display));
|
| 4327 |
+
var bottom = viewport && viewport.bottom != null ? viewport.bottom : top + display.wrapper.clientHeight;
|
| 4328 |
|
| 4329 |
+
var from = lineAtHeight(doc, top), to = lineAtHeight(doc, bottom);
|
| 4330 |
// Ensure is a {from: {line, ch}, to: {line, ch}} object, and
|
| 4331 |
// forces those lines into the viewport (if possible).
|
| 4332 |
if (viewport && viewport.ensure) {
|
| 4333 |
+
var ensureFrom = viewport.ensure.from.line, ensureTo = viewport.ensure.to.line;
|
| 4334 |
if (ensureFrom < from) {
|
| 4335 |
+
from = ensureFrom;
|
| 4336 |
+
to = lineAtHeight(doc, heightAtLine(getLine(doc, ensureFrom)) + display.wrapper.clientHeight);
|
| 4337 |
} else if (Math.min(ensureTo, doc.lastLine()) >= to) {
|
| 4338 |
+
from = lineAtHeight(doc, heightAtLine(getLine(doc, ensureTo)) - display.wrapper.clientHeight);
|
| 4339 |
+
to = ensureTo;
|
| 4340 |
}
|
| 4341 |
}
|
| 4342 |
return {from: from, to: Math.max(to, from + 1)}
|
| 4346 |
// covers the visible area.
|
| 4347 |
function setScrollTop(cm, val) {
|
| 4348 |
if (Math.abs(cm.doc.scrollTop - val) < 2) { return }
|
| 4349 |
+
cm.doc.scrollTop = val;
|
| 4350 |
+
if (!gecko) { updateDisplaySimple(cm, {top: val}); }
|
| 4351 |
+
if (cm.display.scroller.scrollTop != val) { cm.display.scroller.scrollTop = val; }
|
| 4352 |
+
cm.display.scrollbars.setScrollTop(val);
|
| 4353 |
+
if (gecko) { updateDisplaySimple(cm); }
|
| 4354 |
+
startWorker(cm, 100);
|
| 4355 |
}
|
| 4356 |
// Sync scroller and scrollbar, ensure the gutter elements are
|
| 4357 |
// aligned.
|
| 4358 |
function setScrollLeft(cm, val, isScroller) {
|
| 4359 |
if (isScroller ? val == cm.doc.scrollLeft : Math.abs(cm.doc.scrollLeft - val) < 2) { return }
|
| 4360 |
+
val = Math.min(val, cm.display.scroller.scrollWidth - cm.display.scroller.clientWidth);
|
| 4361 |
+
cm.doc.scrollLeft = val;
|
| 4362 |
+
alignHorizontally(cm);
|
| 4363 |
+
if (cm.display.scroller.scrollLeft != val) { cm.display.scroller.scrollLeft = val; }
|
| 4364 |
+
cm.display.scrollbars.setScrollLeft(val);
|
| 4365 |
}
|
| 4366 |
|
| 4367 |
// Since the delta values reported on mouse wheel events are
|
| 4381 |
// know one. These don't have to be accurate -- the result of them
|
| 4382 |
// being wrong would just be a slight flicker on the first wheel
|
| 4383 |
// scroll (if it is large enough).
|
| 4384 |
+
if (ie) { wheelPixelsPerUnit = -.53; }
|
| 4385 |
+
else if (gecko) { wheelPixelsPerUnit = 15; }
|
| 4386 |
+
else if (chrome) { wheelPixelsPerUnit = -.7; }
|
| 4387 |
+
else if (safari) { wheelPixelsPerUnit = -1/3; }
|
| 4388 |
|
| 4389 |
function wheelEventDelta(e) {
|
| 4390 |
+
var dx = e.wheelDeltaX, dy = e.wheelDeltaY;
|
| 4391 |
+
if (dx == null && e.detail && e.axis == e.HORIZONTAL_AXIS) { dx = e.detail; }
|
| 4392 |
+
if (dy == null && e.detail && e.axis == e.VERTICAL_AXIS) { dy = e.detail; }
|
| 4393 |
+
else if (dy == null) { dy = e.wheelDelta; }
|
| 4394 |
return {x: dx, y: dy}
|
| 4395 |
}
|
| 4396 |
function wheelEventPixels(e) {
|
| 4397 |
+
var delta = wheelEventDelta(e);
|
| 4398 |
+
delta.x *= wheelPixelsPerUnit;
|
| 4399 |
+
delta.y *= wheelPixelsPerUnit;
|
| 4400 |
return delta
|
| 4401 |
}
|
| 4402 |
|
| 4403 |
function onScrollWheel(cm, e) {
|
| 4404 |
+
var delta = wheelEventDelta(e), dx = delta.x, dy = delta.y;
|
| 4405 |
|
| 4406 |
+
var display = cm.display, scroll = display.scroller;
|
| 4407 |
// Quit if there's nothing to scroll here
|
| 4408 |
+
var canScrollX = scroll.scrollWidth > scroll.clientWidth;
|
| 4409 |
+
var canScrollY = scroll.scrollHeight > scroll.clientHeight;
|
| 4410 |
if (!(dx && canScrollX || dy && canScrollY)) { return }
|
| 4411 |
|
| 4412 |
// Webkit browsers on OS X abort momentum scrolls when the target
|
| 4417 |
outer: for (var cur = e.target, view = display.view; cur != scroll; cur = cur.parentNode) {
|
| 4418 |
for (var i = 0; i < view.length; i++) {
|
| 4419 |
if (view[i].node == cur) {
|
| 4420 |
+
cm.display.currentWheelTarget = cur;
|
| 4421 |
break outer
|
| 4422 |
}
|
| 4423 |
}
|
| 4432 |
// better than glitching out.
|
| 4433 |
if (dx && !gecko && !presto && wheelPixelsPerUnit != null) {
|
| 4434 |
if (dy && canScrollY)
|
| 4435 |
+
{ setScrollTop(cm, Math.max(0, Math.min(scroll.scrollTop + dy * wheelPixelsPerUnit, scroll.scrollHeight - scroll.clientHeight))); }
|
| 4436 |
+
setScrollLeft(cm, Math.max(0, Math.min(scroll.scrollLeft + dx * wheelPixelsPerUnit, scroll.scrollWidth - scroll.clientWidth)));
|
| 4437 |
// Only prevent default scrolling if vertical scrolling is
|
| 4438 |
// actually possible. Otherwise, it causes vertical scroll
|
| 4439 |
// jitter on OSX trackpads when deltaX is small and deltaY
|
| 4440 |
// is large (issue #3579)
|
| 4441 |
if (!dy || (dy && canScrollY))
|
| 4442 |
+
{ e_preventDefault(e); }
|
| 4443 |
+
display.wheelStartX = null; // Abort measurement, if in progress
|
| 4444 |
return
|
| 4445 |
}
|
| 4446 |
|
| 4447 |
// 'Project' the visible viewport to cover the area that is being
|
| 4448 |
// scrolled into view (if we know enough to estimate it).
|
| 4449 |
if (dy && wheelPixelsPerUnit != null) {
|
| 4450 |
+
var pixels = dy * wheelPixelsPerUnit;
|
| 4451 |
+
var top = cm.doc.scrollTop, bot = top + display.wrapper.clientHeight;
|
| 4452 |
+
if (pixels < 0) { top = Math.max(0, top + pixels - 50); }
|
| 4453 |
+
else { bot = Math.min(cm.doc.height, bot + pixels + 50); }
|
| 4454 |
+
updateDisplaySimple(cm, {top: top, bottom: bot});
|
| 4455 |
}
|
| 4456 |
|
| 4457 |
if (wheelSamples < 20) {
|
| 4458 |
if (display.wheelStartX == null) {
|
| 4459 |
+
display.wheelStartX = scroll.scrollLeft; display.wheelStartY = scroll.scrollTop;
|
| 4460 |
+
display.wheelDX = dx; display.wheelDY = dy;
|
| 4461 |
setTimeout(function () {
|
| 4462 |
if (display.wheelStartX == null) { return }
|
| 4463 |
+
var movedX = scroll.scrollLeft - display.wheelStartX;
|
| 4464 |
+
var movedY = scroll.scrollTop - display.wheelStartY;
|
| 4465 |
var sample = (movedY && display.wheelDY && movedY / display.wheelDY) ||
|
| 4466 |
+
(movedX && display.wheelDX && movedX / display.wheelDX);
|
| 4467 |
+
display.wheelStartX = display.wheelStartY = null;
|
| 4468 |
if (!sample) { return }
|
| 4469 |
+
wheelPixelsPerUnit = (wheelPixelsPerUnit * wheelSamples + sample) / (wheelSamples + 1);
|
| 4470 |
+
++wheelSamples;
|
| 4471 |
+
}, 200);
|
| 4472 |
} else {
|
| 4473 |
+
display.wheelDX += dx; display.wheelDY += dy;
|
| 4474 |
}
|
| 4475 |
}
|
| 4476 |
}
|
| 4480 |
// Prepare DOM reads needed to update the scrollbars. Done in one
|
| 4481 |
// shot to minimize update/measure roundtrips.
|
| 4482 |
function measureForScrollbars(cm) {
|
| 4483 |
+
var d = cm.display, gutterW = d.gutters.offsetWidth;
|
| 4484 |
+
var docH = Math.round(cm.doc.height + paddingVert(cm.display));
|
| 4485 |
return {
|
| 4486 |
clientHeight: d.scroller.clientHeight,
|
| 4487 |
viewHeight: d.wrapper.clientHeight,
|
| 4496 |
}
|
| 4497 |
|
| 4498 |
var NativeScrollbars = function(place, scroll, cm) {
|
| 4499 |
+
this.cm = cm;
|
| 4500 |
+
var vert = this.vert = elt("div", [elt("div", null, null, "min-width: 1px")], "CodeMirror-vscrollbar");
|
| 4501 |
+
var horiz = this.horiz = elt("div", [elt("div", null, null, "height: 100%; min-height: 1px")], "CodeMirror-hscrollbar");
|
| 4502 |
+
place(vert); place(horiz);
|
| 4503 |
|
| 4504 |
on(vert, "scroll", function () {
|
| 4505 |
+
if (vert.clientHeight) { scroll(vert.scrollTop, "vertical"); }
|
| 4506 |
+
});
|
| 4507 |
on(horiz, "scroll", function () {
|
| 4508 |
+
if (horiz.clientWidth) { scroll(horiz.scrollLeft, "horizontal"); }
|
| 4509 |
+
});
|
| 4510 |
|
| 4511 |
+
this.checkedZeroWidth = false;
|
| 4512 |
// Need to set a minimum width to see the scrollbar on IE7 (but must not set it on IE8).
|
| 4513 |
+
if (ie && ie_version < 8) { this.horiz.style.minHeight = this.vert.style.minWidth = "18px"; }
|
| 4514 |
};
|
| 4515 |
|
| 4516 |
NativeScrollbars.prototype.update = function (measure) {
|
| 4517 |
+
var needsH = measure.scrollWidth > measure.clientWidth + 1;
|
| 4518 |
+
var needsV = measure.scrollHeight > measure.clientHeight + 1;
|
| 4519 |
+
var sWidth = measure.nativeBarWidth;
|
| 4520 |
|
| 4521 |
if (needsV) {
|
| 4522 |
+
this.vert.style.display = "block";
|
| 4523 |
+
this.vert.style.bottom = needsH ? sWidth + "px" : "0";
|
| 4524 |
+
var totalHeight = measure.viewHeight - (needsH ? sWidth : 0);
|
| 4525 |
// A bug in IE8 can cause this value to be negative, so guard it.
|
| 4526 |
this.vert.firstChild.style.height =
|
| 4527 |
+
Math.max(0, measure.scrollHeight - measure.clientHeight + totalHeight) + "px";
|
| 4528 |
} else {
|
| 4529 |
+
this.vert.style.display = "";
|
| 4530 |
+
this.vert.firstChild.style.height = "0";
|
| 4531 |
}
|
| 4532 |
|
| 4533 |
if (needsH) {
|
| 4534 |
+
this.horiz.style.display = "block";
|
| 4535 |
+
this.horiz.style.right = needsV ? sWidth + "px" : "0";
|
| 4536 |
+
this.horiz.style.left = measure.barLeft + "px";
|
| 4537 |
+
var totalWidth = measure.viewWidth - measure.barLeft - (needsV ? sWidth : 0);
|
| 4538 |
this.horiz.firstChild.style.width =
|
| 4539 |
+
Math.max(0, measure.scrollWidth - measure.clientWidth + totalWidth) + "px";
|
| 4540 |
} else {
|
| 4541 |
+
this.horiz.style.display = "";
|
| 4542 |
+
this.horiz.firstChild.style.width = "0";
|
| 4543 |
}
|
| 4544 |
|
| 4545 |
if (!this.checkedZeroWidth && measure.clientHeight > 0) {
|
| 4546 |
+
if (sWidth == 0) { this.zeroWidthHack(); }
|
| 4547 |
+
this.checkedZeroWidth = true;
|
| 4548 |
}
|
| 4549 |
|
| 4550 |
return {right: needsV ? sWidth : 0, bottom: needsH ? sWidth : 0}
|
| 4551 |
};
|
| 4552 |
|
| 4553 |
NativeScrollbars.prototype.setScrollLeft = function (pos) {
|
| 4554 |
+
if (this.horiz.scrollLeft != pos) { this.horiz.scrollLeft = pos; }
|
| 4555 |
+
if (this.disableHoriz) { this.enableZeroWidthBar(this.horiz, this.disableHoriz); }
|
| 4556 |
};
|
| 4557 |
|
| 4558 |
NativeScrollbars.prototype.setScrollTop = function (pos) {
|
| 4559 |
+
if (this.vert.scrollTop != pos) { this.vert.scrollTop = pos; }
|
| 4560 |
+
if (this.disableVert) { this.enableZeroWidthBar(this.vert, this.disableVert); }
|
| 4561 |
};
|
| 4562 |
|
| 4563 |
NativeScrollbars.prototype.zeroWidthHack = function () {
|
| 4564 |
+
var w = mac && !mac_geMountainLion ? "12px" : "18px";
|
| 4565 |
+
this.horiz.style.height = this.vert.style.width = w;
|
| 4566 |
+
this.horiz.style.pointerEvents = this.vert.style.pointerEvents = "none";
|
| 4567 |
+
this.disableHoriz = new Delayed;
|
| 4568 |
+
this.disableVert = new Delayed;
|
| 4569 |
};
|
| 4570 |
|
| 4571 |
NativeScrollbars.prototype.enableZeroWidthBar = function (bar, delay) {
|
| 4572 |
+
bar.style.pointerEvents = "auto";
|
| 4573 |
function maybeDisable() {
|
| 4574 |
// To find out whether the scrollbar is still visible, we
|
| 4575 |
// check whether the element under the pixel in the bottom
|
| 4577 |
// itself (when the bar is still visible) or its filler child
|
| 4578 |
// (when the bar is hidden). If it is still visible, we keep
|
| 4579 |
// it enabled, if it's hidden, we disable pointer events.
|
| 4580 |
+
var box = bar.getBoundingClientRect();
|
| 4581 |
+
var elt$$1 = document.elementFromPoint(box.left + 1, box.bottom - 1);
|
| 4582 |
+
if (elt$$1 != bar) { bar.style.pointerEvents = "none"; }
|
| 4583 |
+
else { delay.set(1000, maybeDisable); }
|
| 4584 |
}
|
| 4585 |
+
delay.set(1000, maybeDisable);
|
| 4586 |
};
|
| 4587 |
|
| 4588 |
NativeScrollbars.prototype.clear = function () {
|
| 4589 |
+
var parent = this.horiz.parentNode;
|
| 4590 |
+
parent.removeChild(this.horiz);
|
| 4591 |
+
parent.removeChild(this.vert);
|
| 4592 |
};
|
| 4593 |
|
| 4594 |
var NullScrollbars = function () {};
|
| 4599 |
NullScrollbars.prototype.clear = function () {};
|
| 4600 |
|
| 4601 |
function updateScrollbars(cm, measure) {
|
| 4602 |
+
if (!measure) { measure = measureForScrollbars(cm); }
|
| 4603 |
+
var startWidth = cm.display.barWidth, startHeight = cm.display.barHeight;
|
| 4604 |
+
updateScrollbarsInner(cm, measure);
|
| 4605 |
for (var i = 0; i < 4 && startWidth != cm.display.barWidth || startHeight != cm.display.barHeight; i++) {
|
| 4606 |
if (startWidth != cm.display.barWidth && cm.options.lineWrapping)
|
| 4607 |
+
{ updateHeightsInViewport(cm); }
|
| 4608 |
+
updateScrollbarsInner(cm, measureForScrollbars(cm));
|
| 4609 |
+
startWidth = cm.display.barWidth; startHeight = cm.display.barHeight;
|
| 4610 |
}
|
| 4611 |
}
|
| 4612 |
|
| 4613 |
// Re-synchronize the fake scrollbars with the actual size of the
|
| 4614 |
// content.
|
| 4615 |
function updateScrollbarsInner(cm, measure) {
|
| 4616 |
+
var d = cm.display;
|
| 4617 |
+
var sizes = d.scrollbars.update(measure);
|
| 4618 |
|
| 4619 |
+
d.sizer.style.paddingRight = (d.barWidth = sizes.right) + "px";
|
| 4620 |
+
d.sizer.style.paddingBottom = (d.barHeight = sizes.bottom) + "px";
|
| 4621 |
+
d.heightForcer.style.borderBottom = sizes.bottom + "px solid transparent";
|
| 4622 |
|
| 4623 |
if (sizes.right && sizes.bottom) {
|
| 4624 |
+
d.scrollbarFiller.style.display = "block";
|
| 4625 |
+
d.scrollbarFiller.style.height = sizes.bottom + "px";
|
| 4626 |
+
d.scrollbarFiller.style.width = sizes.right + "px";
|
| 4627 |
+
} else { d.scrollbarFiller.style.display = ""; }
|
| 4628 |
if (sizes.bottom && cm.options.coverGutterNextToScrollbar && cm.options.fixedGutter) {
|
| 4629 |
+
d.gutterFiller.style.display = "block";
|
| 4630 |
+
d.gutterFiller.style.height = sizes.bottom + "px";
|
| 4631 |
+
d.gutterFiller.style.width = measure.gutterWidth + "px";
|
| 4632 |
+
} else { d.gutterFiller.style.display = ""; }
|
| 4633 |
}
|
| 4634 |
|
| 4635 |
+
var scrollbarModel = {"native": NativeScrollbars, "null": NullScrollbars};
|
| 4636 |
|
| 4637 |
function initScrollbars(cm) {
|
| 4638 |
if (cm.display.scrollbars) {
|
| 4639 |
+
cm.display.scrollbars.clear();
|
| 4640 |
if (cm.display.scrollbars.addClass)
|
| 4641 |
+
{ rmClass(cm.display.wrapper, cm.display.scrollbars.addClass); }
|
| 4642 |
}
|
| 4643 |
|
| 4644 |
cm.display.scrollbars = new scrollbarModel[cm.options.scrollbarStyle](function (node) {
|
| 4645 |
+
cm.display.wrapper.insertBefore(node, cm.display.scrollbarFiller);
|
| 4646 |
// Prevent clicks in the scrollbars from killing focus
|
| 4647 |
on(node, "mousedown", function () {
|
| 4648 |
+
if (cm.state.focused) { setTimeout(function () { return cm.display.input.focus(); }, 0); }
|
| 4649 |
+
});
|
| 4650 |
+
node.setAttribute("cm-not-content", "true");
|
| 4651 |
}, function (pos, axis) {
|
| 4652 |
+
if (axis == "horizontal") { setScrollLeft(cm, pos); }
|
| 4653 |
+
else { setScrollTop(cm, pos); }
|
| 4654 |
+
}, cm);
|
| 4655 |
if (cm.display.scrollbars.addClass)
|
| 4656 |
+
{ addClass(cm.display.wrapper, cm.display.scrollbars.addClass); }
|
| 4657 |
}
|
| 4658 |
|
| 4659 |
// SCROLLING THINGS INTO VIEW
|
| 4660 |
|
| 4661 |
// If an editor sits on the top or bottom of the window, partially
|
| 4662 |
// scrolled out of view, this ensures that the cursor is visible.
|
| 4663 |
+
function maybeScrollWindow(cm, rect) {
|
| 4664 |
if (signalDOMEvent(cm, "scrollCursorIntoView")) { return }
|
| 4665 |
|
| 4666 |
+
var display = cm.display, box = display.sizer.getBoundingClientRect(), doScroll = null;
|
| 4667 |
+
if (rect.top + box.top < 0) { doScroll = true; }
|
| 4668 |
+
else if (rect.bottom + box.top > (window.innerHeight || document.documentElement.clientHeight)) { doScroll = false; }
|
| 4669 |
if (doScroll != null && !phantom) {
|
| 4670 |
+
var scrollNode = elt("div", "\u200b", null, ("position: absolute;\n top: " + (rect.top - display.viewOffset - paddingTop(cm.display)) + "px;\n height: " + (rect.bottom - rect.top + scrollGap(cm) + display.barHeight) + "px;\n left: " + (rect.left) + "px; width: " + (Math.max(2, rect.right - rect.left)) + "px;"));
|
| 4671 |
+
cm.display.lineSpace.appendChild(scrollNode);
|
| 4672 |
+
scrollNode.scrollIntoView(doScroll);
|
| 4673 |
+
cm.display.lineSpace.removeChild(scrollNode);
|
| 4674 |
}
|
| 4675 |
}
|
| 4676 |
|
| 4678 |
// it actually became visible (as line heights are accurately
|
| 4679 |
// measured, the position of something may 'drift' during drawing).
|
| 4680 |
function scrollPosIntoView(cm, pos, end, margin) {
|
| 4681 |
+
if (margin == null) { margin = 0; }
|
| 4682 |
+
var rect;
|
| 4683 |
for (var limit = 0; limit < 5; limit++) {
|
| 4684 |
+
var changed = false;
|
| 4685 |
+
var coords = cursorCoords(cm, pos);
|
| 4686 |
+
var endCoords = !end || end == pos ? coords : cursorCoords(cm, end);
|
| 4687 |
+
rect = {left: Math.min(coords.left, endCoords.left),
|
| 4688 |
+
top: Math.min(coords.top, endCoords.top) - margin,
|
| 4689 |
+
right: Math.max(coords.left, endCoords.left),
|
| 4690 |
+
bottom: Math.max(coords.bottom, endCoords.bottom) + margin};
|
| 4691 |
+
var scrollPos = calculateScrollPos(cm, rect);
|
| 4692 |
+
var startTop = cm.doc.scrollTop, startLeft = cm.doc.scrollLeft;
|
| 4693 |
if (scrollPos.scrollTop != null) {
|
| 4694 |
+
setScrollTop(cm, scrollPos.scrollTop);
|
| 4695 |
+
if (Math.abs(cm.doc.scrollTop - startTop) > 1) { changed = true; }
|
| 4696 |
}
|
| 4697 |
if (scrollPos.scrollLeft != null) {
|
| 4698 |
+
setScrollLeft(cm, scrollPos.scrollLeft);
|
| 4699 |
+
if (Math.abs(cm.doc.scrollLeft - startLeft) > 1) { changed = true; }
|
| 4700 |
}
|
| 4701 |
if (!changed) { break }
|
| 4702 |
}
|
| 4703 |
+
return rect
|
| 4704 |
}
|
| 4705 |
|
| 4706 |
// Scroll a given set of coordinates into view (immediately).
|
| 4707 |
+
function scrollIntoView(cm, rect) {
|
| 4708 |
+
var scrollPos = calculateScrollPos(cm, rect);
|
| 4709 |
+
if (scrollPos.scrollTop != null) { setScrollTop(cm, scrollPos.scrollTop); }
|
| 4710 |
+
if (scrollPos.scrollLeft != null) { setScrollLeft(cm, scrollPos.scrollLeft); }
|
| 4711 |
}
|
| 4712 |
|
| 4713 |
// Calculate a new scroll position needed to scroll the given
|
| 4714 |
// rectangle into view. Returns an object with scrollTop and
|
| 4715 |
// scrollLeft properties. When these are undefined, the
|
| 4716 |
// vertical/horizontal position does not need to be adjusted.
|
| 4717 |
+
function calculateScrollPos(cm, rect) {
|
| 4718 |
+
var display = cm.display, snapMargin = textHeight(cm.display);
|
| 4719 |
+
if (rect.top < 0) { rect.top = 0; }
|
| 4720 |
+
var screentop = cm.curOp && cm.curOp.scrollTop != null ? cm.curOp.scrollTop : display.scroller.scrollTop;
|
| 4721 |
+
var screen = displayHeight(cm), result = {};
|
| 4722 |
+
if (rect.bottom - rect.top > screen) { rect.bottom = rect.top + screen; }
|
| 4723 |
+
var docBottom = cm.doc.height + paddingVert(display);
|
| 4724 |
+
var atTop = rect.top < snapMargin, atBottom = rect.bottom > docBottom - snapMargin;
|
| 4725 |
+
if (rect.top < screentop) {
|
| 4726 |
+
result.scrollTop = atTop ? 0 : rect.top;
|
| 4727 |
+
} else if (rect.bottom > screentop + screen) {
|
| 4728 |
+
var newTop = Math.min(rect.top, (atBottom ? docBottom : rect.bottom) - screen);
|
| 4729 |
+
if (newTop != screentop) { result.scrollTop = newTop; }
|
| 4730 |
+
}
|
| 4731 |
+
|
| 4732 |
+
var screenleft = cm.curOp && cm.curOp.scrollLeft != null ? cm.curOp.scrollLeft : display.scroller.scrollLeft;
|
| 4733 |
+
var screenw = displayWidth(cm) - (cm.options.fixedGutter ? display.gutters.offsetWidth : 0);
|
| 4734 |
+
var tooWide = rect.right - rect.left > screenw;
|
| 4735 |
+
if (tooWide) { rect.right = rect.left + screenw; }
|
| 4736 |
+
if (rect.left < 10)
|
| 4737 |
+
{ result.scrollLeft = 0; }
|
| 4738 |
+
else if (rect.left < screenleft)
|
| 4739 |
+
{ result.scrollLeft = Math.max(0, rect.left - (tooWide ? 0 : 10)); }
|
| 4740 |
+
else if (rect.right > screenw + screenleft - 3)
|
| 4741 |
+
{ result.scrollLeft = rect.right + (tooWide ? 0 : 10) - screenw; }
|
| 4742 |
return result
|
| 4743 |
}
|
| 4744 |
|
| 4745 |
// Store a relative adjustment to the scroll position in the current
|
| 4746 |
// operation (to be applied when the operation finishes).
|
| 4747 |
function addToScrollPos(cm, left, top) {
|
| 4748 |
+
if (left != null || top != null) { resolveScrollToPos(cm); }
|
| 4749 |
if (left != null)
|
| 4750 |
+
{ cm.curOp.scrollLeft = (cm.curOp.scrollLeft == null ? cm.doc.scrollLeft : cm.curOp.scrollLeft) + left; }
|
| 4751 |
if (top != null)
|
| 4752 |
+
{ cm.curOp.scrollTop = (cm.curOp.scrollTop == null ? cm.doc.scrollTop : cm.curOp.scrollTop) + top; }
|
| 4753 |
}
|
| 4754 |
|
| 4755 |
// Make sure that at the end of the operation the current cursor is
|
| 4756 |
// shown.
|
| 4757 |
function ensureCursorVisible(cm) {
|
| 4758 |
+
resolveScrollToPos(cm);
|
| 4759 |
+
var cur = cm.getCursor(), from = cur, to = cur;
|
| 4760 |
if (!cm.options.lineWrapping) {
|
| 4761 |
+
from = cur.ch ? Pos(cur.line, cur.ch - 1) : cur;
|
| 4762 |
+
to = Pos(cur.line, cur.ch + 1);
|
| 4763 |
}
|
| 4764 |
+
cm.curOp.scrollToPos = {from: from, to: to, margin: cm.options.cursorScrollMargin};
|
| 4765 |
}
|
| 4766 |
|
| 4767 |
// When an operation has its scrollToPos property set, and another
|
| 4769 |
// 'simulates' scrolling that position into view in a cheap way, so
|
| 4770 |
// that the effect of intermediate scroll commands is not ignored.
|
| 4771 |
function resolveScrollToPos(cm) {
|
| 4772 |
+
var range$$1 = cm.curOp.scrollToPos;
|
| 4773 |
+
if (range$$1) {
|
| 4774 |
+
cm.curOp.scrollToPos = null;
|
| 4775 |
+
var from = estimateCoords(cm, range$$1.from), to = estimateCoords(cm, range$$1.to);
|
| 4776 |
+
var sPos = calculateScrollPos(cm, {
|
| 4777 |
+
left: Math.min(from.left, to.left),
|
| 4778 |
+
top: Math.min(from.top, to.top) - range$$1.margin,
|
| 4779 |
+
right: Math.max(from.right, to.right),
|
| 4780 |
+
bottom: Math.max(from.bottom, to.bottom) + range$$1.margin
|
| 4781 |
+
});
|
| 4782 |
+
cm.scrollTo(sPos.scrollLeft, sPos.scrollTop);
|
| 4783 |
}
|
| 4784 |
}
|
| 4785 |
|
| 4789 |
// error-prone). Instead, display updates are batched and then all
|
| 4790 |
// combined and executed at once.
|
| 4791 |
|
| 4792 |
+
var nextOpId = 0;
|
| 4793 |
// Start a new operation.
|
| 4794 |
function startOperation(cm) {
|
| 4795 |
cm.curOp = {
|
| 4808 |
scrollToPos: null, // Used to scroll to a specific position
|
| 4809 |
focus: false,
|
| 4810 |
id: ++nextOpId // Unique ID
|
| 4811 |
+
};
|
| 4812 |
+
pushOperation(cm.curOp);
|
| 4813 |
}
|
| 4814 |
|
| 4815 |
// Finish an operation, updating the display and signalling delayed events
|
| 4816 |
function endOperation(cm) {
|
| 4817 |
+
var op = cm.curOp;
|
| 4818 |
finishOperation(op, function (group) {
|
| 4819 |
for (var i = 0; i < group.ops.length; i++)
|
| 4820 |
+
{ group.ops[i].cm.curOp = null; }
|
| 4821 |
+
endOperations(group);
|
| 4822 |
+
});
|
| 4823 |
}
|
| 4824 |
|
| 4825 |
// The DOM updates done when an operation finishes are batched so
|
| 4826 |
// that the minimum number of relayouts are required.
|
| 4827 |
function endOperations(group) {
|
| 4828 |
+
var ops = group.ops;
|
| 4829 |
for (var i = 0; i < ops.length; i++) // Read DOM
|
| 4830 |
+
{ endOperation_R1(ops[i]); }
|
| 4831 |
for (var i$1 = 0; i$1 < ops.length; i$1++) // Write DOM (maybe)
|
| 4832 |
+
{ endOperation_W1(ops[i$1]); }
|
| 4833 |
for (var i$2 = 0; i$2 < ops.length; i$2++) // Read DOM
|
| 4834 |
+
{ endOperation_R2(ops[i$2]); }
|
| 4835 |
for (var i$3 = 0; i$3 < ops.length; i$3++) // Write DOM (maybe)
|
| 4836 |
+
{ endOperation_W2(ops[i$3]); }
|
| 4837 |
for (var i$4 = 0; i$4 < ops.length; i$4++) // Read DOM
|
| 4838 |
+
{ endOperation_finish(ops[i$4]); }
|
| 4839 |
}
|
| 4840 |
|
| 4841 |
function endOperation_R1(op) {
|
| 4842 |
+
var cm = op.cm, display = cm.display;
|
| 4843 |
+
maybeClipScrollbars(cm);
|
| 4844 |
+
if (op.updateMaxLine) { findMaxLine(cm); }
|
| 4845 |
|
| 4846 |
op.mustUpdate = op.viewChanged || op.forceUpdate || op.scrollTop != null ||
|
| 4847 |
op.scrollToPos && (op.scrollToPos.from.line < display.viewFrom ||
|
| 4848 |
op.scrollToPos.to.line >= display.viewTo) ||
|
| 4849 |
+
display.maxLineChanged && cm.options.lineWrapping;
|
| 4850 |
op.update = op.mustUpdate &&
|
| 4851 |
+
new DisplayUpdate(cm, op.mustUpdate && {top: op.scrollTop, ensure: op.scrollToPos}, op.forceUpdate);
|
| 4852 |
}
|
| 4853 |
|
| 4854 |
function endOperation_W1(op) {
|
| 4855 |
+
op.updatedDisplay = op.mustUpdate && updateDisplayIfNeeded(op.cm, op.update);
|
| 4856 |
}
|
| 4857 |
|
| 4858 |
function endOperation_R2(op) {
|
| 4859 |
+
var cm = op.cm, display = cm.display;
|
| 4860 |
+
if (op.updatedDisplay) { updateHeightsInViewport(cm); }
|
| 4861 |
|
| 4862 |
+
op.barMeasure = measureForScrollbars(cm);
|
| 4863 |
|
| 4864 |
// If the max line changed since it was last measured, measure it,
|
| 4865 |
// and ensure the document's width matches it.
|
| 4866 |
// updateDisplay_W2 will use these properties to do the actual resizing
|
| 4867 |
if (display.maxLineChanged && !cm.options.lineWrapping) {
|
| 4868 |
+
op.adjustWidthTo = measureChar(cm, display.maxLine, display.maxLine.text.length).left + 3;
|
| 4869 |
+
cm.display.sizerWidth = op.adjustWidthTo;
|
| 4870 |
op.barMeasure.scrollWidth =
|
| 4871 |
+
Math.max(display.scroller.clientWidth, display.sizer.offsetLeft + op.adjustWidthTo + scrollGap(cm) + cm.display.barWidth);
|
| 4872 |
+
op.maxScrollLeft = Math.max(0, display.sizer.offsetLeft + op.adjustWidthTo - displayWidth(cm));
|
| 4873 |
}
|
| 4874 |
|
| 4875 |
if (op.updatedDisplay || op.selectionChanged)
|
| 4876 |
+
{ op.preparedSelection = display.input.prepareSelection(op.focus); }
|
| 4877 |
}
|
| 4878 |
|
| 4879 |
function endOperation_W2(op) {
|
| 4880 |
+
var cm = op.cm;
|
| 4881 |
|
| 4882 |
if (op.adjustWidthTo != null) {
|
| 4883 |
+
cm.display.sizer.style.minWidth = op.adjustWidthTo + "px";
|
| 4884 |
if (op.maxScrollLeft < cm.doc.scrollLeft)
|
| 4885 |
+
{ setScrollLeft(cm, Math.min(cm.display.scroller.scrollLeft, op.maxScrollLeft), true); }
|
| 4886 |
+
cm.display.maxLineChanged = false;
|
| 4887 |
}
|
| 4888 |
|
| 4889 |
+
var takeFocus = op.focus && op.focus == activeElt() && (!document.hasFocus || document.hasFocus());
|
| 4890 |
if (op.preparedSelection)
|
| 4891 |
+
{ cm.display.input.showSelection(op.preparedSelection, takeFocus); }
|
| 4892 |
if (op.updatedDisplay || op.startHeight != cm.doc.height)
|
| 4893 |
+
{ updateScrollbars(cm, op.barMeasure); }
|
| 4894 |
if (op.updatedDisplay)
|
| 4895 |
+
{ setDocumentHeight(cm, op.barMeasure); }
|
| 4896 |
|
| 4897 |
+
if (op.selectionChanged) { restartBlink(cm); }
|
| 4898 |
|
| 4899 |
if (cm.state.focused && op.updateInput)
|
| 4900 |
+
{ cm.display.input.reset(op.typing); }
|
| 4901 |
+
if (takeFocus) { ensureFocus(op.cm); }
|
| 4902 |
}
|
| 4903 |
|
| 4904 |
function endOperation_finish(op) {
|
| 4905 |
+
var cm = op.cm, display = cm.display, doc = cm.doc;
|
| 4906 |
|
| 4907 |
+
if (op.updatedDisplay) { postUpdateDisplay(cm, op.update); }
|
| 4908 |
|
| 4909 |
// Abort mouse wheel delta measurement, when scrolling explicitly
|
| 4910 |
if (display.wheelStartX != null && (op.scrollTop != null || op.scrollLeft != null || op.scrollToPos))
|
| 4911 |
+
{ display.wheelStartX = display.wheelStartY = null; }
|
| 4912 |
|
| 4913 |
// Propagate the scroll position to the actual DOM scroller
|
| 4914 |
if (op.scrollTop != null && (display.scroller.scrollTop != op.scrollTop || op.forceScroll)) {
|
| 4915 |
+
doc.scrollTop = Math.max(0, Math.min(display.scroller.scrollHeight - display.scroller.clientHeight, op.scrollTop));
|
| 4916 |
+
display.scrollbars.setScrollTop(doc.scrollTop);
|
| 4917 |
+
display.scroller.scrollTop = doc.scrollTop;
|
| 4918 |
}
|
| 4919 |
if (op.scrollLeft != null && (display.scroller.scrollLeft != op.scrollLeft || op.forceScroll)) {
|
| 4920 |
+
doc.scrollLeft = Math.max(0, Math.min(display.scroller.scrollWidth - display.scroller.clientWidth, op.scrollLeft));
|
| 4921 |
+
display.scrollbars.setScrollLeft(doc.scrollLeft);
|
| 4922 |
+
display.scroller.scrollLeft = doc.scrollLeft;
|
| 4923 |
+
alignHorizontally(cm);
|
| 4924 |
}
|
| 4925 |
// If we need to scroll a specific position into view, do so.
|
| 4926 |
if (op.scrollToPos) {
|
| 4927 |
+
var rect = scrollPosIntoView(cm, clipPos(doc, op.scrollToPos.from),
|
| 4928 |
+
clipPos(doc, op.scrollToPos.to), op.scrollToPos.margin);
|
| 4929 |
+
maybeScrollWindow(cm, rect);
|
| 4930 |
}
|
| 4931 |
|
| 4932 |
// Fire events for markers that are hidden/unidden by editing or
|
| 4933 |
// undoing
|
| 4934 |
+
var hidden = op.maybeHiddenMarkers, unhidden = op.maybeUnhiddenMarkers;
|
| 4935 |
if (hidden) { for (var i = 0; i < hidden.length; ++i)
|
| 4936 |
+
{ if (!hidden[i].lines.length) { signal(hidden[i], "hide"); } } }
|
| 4937 |
if (unhidden) { for (var i$1 = 0; i$1 < unhidden.length; ++i$1)
|
| 4938 |
+
{ if (unhidden[i$1].lines.length) { signal(unhidden[i$1], "unhide"); } } }
|
| 4939 |
|
| 4940 |
if (display.wrapper.offsetHeight)
|
| 4941 |
+
{ doc.scrollTop = cm.display.scroller.scrollTop; }
|
| 4942 |
|
| 4943 |
// Fire change events, and delayed event handlers
|
| 4944 |
if (op.changeObjs)
|
| 4945 |
+
{ signal(cm, "changes", cm, op.changeObjs); }
|
| 4946 |
if (op.update)
|
| 4947 |
+
{ op.update.finish(); }
|
| 4948 |
}
|
| 4949 |
|
| 4950 |
// Run the given function in an operation
|
| 4951 |
function runInOp(cm, f) {
|
| 4952 |
if (cm.curOp) { return f() }
|
| 4953 |
+
startOperation(cm);
|
| 4954 |
try { return f() }
|
| 4955 |
+
finally { endOperation(cm); }
|
| 4956 |
}
|
| 4957 |
// Wraps a function in an operation. Returns the wrapped function.
|
| 4958 |
function operation(cm, f) {
|
| 4959 |
return function() {
|
| 4960 |
if (cm.curOp) { return f.apply(cm, arguments) }
|
| 4961 |
+
startOperation(cm);
|
| 4962 |
try { return f.apply(cm, arguments) }
|
| 4963 |
+
finally { endOperation(cm); }
|
| 4964 |
}
|
| 4965 |
}
|
| 4966 |
// Used to add methods to editor and doc instances, wrapping them in
|
| 4968 |
function methodOp(f) {
|
| 4969 |
return function() {
|
| 4970 |
if (this.curOp) { return f.apply(this, arguments) }
|
| 4971 |
+
startOperation(this);
|
| 4972 |
try { return f.apply(this, arguments) }
|
| 4973 |
+
finally { endOperation(this); }
|
| 4974 |
}
|
| 4975 |
}
|
| 4976 |
function docMethodOp(f) {
|
| 4977 |
return function() {
|
| 4978 |
+
var cm = this.cm;
|
| 4979 |
if (!cm || cm.curOp) { return f.apply(this, arguments) }
|
| 4980 |
+
startOperation(cm);
|
| 4981 |
try { return f.apply(this, arguments) }
|
| 4982 |
+
finally { endOperation(cm); }
|
| 4983 |
}
|
| 4984 |
}
|
| 4985 |
|
| 4990 |
// lines are divided into visual lines. regLineChange (below)
|
| 4991 |
// registers single-line changes.
|
| 4992 |
function regChange(cm, from, to, lendiff) {
|
| 4993 |
+
if (from == null) { from = cm.doc.first; }
|
| 4994 |
+
if (to == null) { to = cm.doc.first + cm.doc.size; }
|
| 4995 |
+
if (!lendiff) { lendiff = 0; }
|
| 4996 |
|
| 4997 |
+
var display = cm.display;
|
| 4998 |
if (lendiff && to < display.viewTo &&
|
| 4999 |
(display.updateLineNumbers == null || display.updateLineNumbers > from))
|
| 5000 |
+
{ display.updateLineNumbers = from; }
|
| 5001 |
|
| 5002 |
+
cm.curOp.viewChanged = true;
|
| 5003 |
|
| 5004 |
if (from >= display.viewTo) { // Change after
|
| 5005 |
if (sawCollapsedSpans && visualLineNo(cm.doc, from) < display.viewTo)
|
| 5006 |
+
{ resetView(cm); }
|
| 5007 |
} else if (to <= display.viewFrom) { // Change before
|
| 5008 |
if (sawCollapsedSpans && visualLineEndNo(cm.doc, to + lendiff) > display.viewFrom) {
|
| 5009 |
+
resetView(cm);
|
| 5010 |
} else {
|
| 5011 |
+
display.viewFrom += lendiff;
|
| 5012 |
+
display.viewTo += lendiff;
|
| 5013 |
}
|
| 5014 |
} else if (from <= display.viewFrom && to >= display.viewTo) { // Full overlap
|
| 5015 |
+
resetView(cm);
|
| 5016 |
} else if (from <= display.viewFrom) { // Top overlap
|
| 5017 |
+
var cut = viewCuttingPoint(cm, to, to + lendiff, 1);
|
| 5018 |
if (cut) {
|
| 5019 |
+
display.view = display.view.slice(cut.index);
|
| 5020 |
+
display.viewFrom = cut.lineN;
|
| 5021 |
+
display.viewTo += lendiff;
|
| 5022 |
} else {
|
| 5023 |
+
resetView(cm);
|
| 5024 |
}
|
| 5025 |
} else if (to >= display.viewTo) { // Bottom overlap
|
| 5026 |
+
var cut$1 = viewCuttingPoint(cm, from, from, -1);
|
| 5027 |
if (cut$1) {
|
| 5028 |
+
display.view = display.view.slice(0, cut$1.index);
|
| 5029 |
+
display.viewTo = cut$1.lineN;
|
| 5030 |
} else {
|
| 5031 |
+
resetView(cm);
|
| 5032 |
}
|
| 5033 |
} else { // Gap in the middle
|
| 5034 |
+
var cutTop = viewCuttingPoint(cm, from, from, -1);
|
| 5035 |
+
var cutBot = viewCuttingPoint(cm, to, to + lendiff, 1);
|
| 5036 |
if (cutTop && cutBot) {
|
| 5037 |
display.view = display.view.slice(0, cutTop.index)
|
| 5038 |
.concat(buildViewArray(cm, cutTop.lineN, cutBot.lineN))
|
| 5039 |
+
.concat(display.view.slice(cutBot.index));
|
| 5040 |
+
display.viewTo += lendiff;
|
| 5041 |
} else {
|
| 5042 |
+
resetView(cm);
|
| 5043 |
}
|
| 5044 |
}
|
| 5045 |
|
| 5046 |
+
var ext = display.externalMeasured;
|
| 5047 |
if (ext) {
|
| 5048 |
if (to < ext.lineN)
|
| 5049 |
+
{ ext.lineN += lendiff; }
|
| 5050 |
else if (from < ext.lineN + ext.size)
|
| 5051 |
+
{ display.externalMeasured = null; }
|
| 5052 |
}
|
| 5053 |
}
|
| 5054 |
|
| 5055 |
// Register a change to a single line. Type must be one of "text",
|
| 5056 |
// "gutter", "class", "widget"
|
| 5057 |
function regLineChange(cm, line, type) {
|
| 5058 |
+
cm.curOp.viewChanged = true;
|
| 5059 |
+
var display = cm.display, ext = cm.display.externalMeasured;
|
| 5060 |
if (ext && line >= ext.lineN && line < ext.lineN + ext.size)
|
| 5061 |
+
{ display.externalMeasured = null; }
|
| 5062 |
|
| 5063 |
if (line < display.viewFrom || line >= display.viewTo) { return }
|
| 5064 |
+
var lineView = display.view[findViewIndex(cm, line)];
|
| 5065 |
if (lineView.node == null) { return }
|
| 5066 |
+
var arr = lineView.changes || (lineView.changes = []);
|
| 5067 |
+
if (indexOf(arr, type) == -1) { arr.push(type); }
|
| 5068 |
}
|
| 5069 |
|
| 5070 |
// Clear the view.
|
| 5071 |
function resetView(cm) {
|
| 5072 |
+
cm.display.viewFrom = cm.display.viewTo = cm.doc.first;
|
| 5073 |
+
cm.display.view = [];
|
| 5074 |
+
cm.display.viewOffset = 0;
|
| 5075 |
}
|
| 5076 |
|
| 5077 |
function viewCuttingPoint(cm, oldN, newN, dir) {
|
| 5078 |
+
var index = findViewIndex(cm, oldN), diff, view = cm.display.view;
|
| 5079 |
if (!sawCollapsedSpans || newN == cm.doc.first + cm.doc.size)
|
| 5080 |
{ return {index: index, lineN: newN} }
|
| 5081 |
+
var n = cm.display.viewFrom;
|
| 5082 |
for (var i = 0; i < index; i++)
|
| 5083 |
+
{ n += view[i].size; }
|
| 5084 |
if (n != oldN) {
|
| 5085 |
if (dir > 0) {
|
| 5086 |
if (index == view.length - 1) { return null }
|
| 5087 |
+
diff = (n + view[index].size) - oldN;
|
| 5088 |
+
index++;
|
| 5089 |
} else {
|
| 5090 |
+
diff = n - oldN;
|
| 5091 |
}
|
| 5092 |
+
oldN += diff; newN += diff;
|
| 5093 |
}
|
| 5094 |
while (visualLineNo(cm.doc, newN) != newN) {
|
| 5095 |
if (index == (dir < 0 ? 0 : view.length - 1)) { return null }
|
| 5096 |
+
newN += dir * view[index - (dir < 0 ? 1 : 0)].size;
|
| 5097 |
+
index += dir;
|
| 5098 |
}
|
| 5099 |
return {index: index, lineN: newN}
|
| 5100 |
}
|
| 5102 |
// Force the view to cover a given range, adding empty view element
|
| 5103 |
// or clipping off existing ones as needed.
|
| 5104 |
function adjustView(cm, from, to) {
|
| 5105 |
+
var display = cm.display, view = display.view;
|
| 5106 |
if (view.length == 0 || from >= display.viewTo || to <= display.viewFrom) {
|
| 5107 |
+
display.view = buildViewArray(cm, from, to);
|
| 5108 |
+
display.viewFrom = from;
|
| 5109 |
} else {
|
| 5110 |
if (display.viewFrom > from)
|
| 5111 |
+
{ display.view = buildViewArray(cm, from, display.viewFrom).concat(display.view); }
|
| 5112 |
else if (display.viewFrom < from)
|
| 5113 |
+
{ display.view = display.view.slice(findViewIndex(cm, from)); }
|
| 5114 |
+
display.viewFrom = from;
|
| 5115 |
if (display.viewTo < to)
|
| 5116 |
+
{ display.view = display.view.concat(buildViewArray(cm, display.viewTo, to)); }
|
| 5117 |
else if (display.viewTo > to)
|
| 5118 |
+
{ display.view = display.view.slice(0, findViewIndex(cm, to)); }
|
| 5119 |
}
|
| 5120 |
+
display.viewTo = to;
|
| 5121 |
}
|
| 5122 |
|
| 5123 |
// Count the number of lines in the view whose DOM representation is
|
| 5124 |
// out of date (or nonexistent).
|
| 5125 |
function countDirtyView(cm) {
|
| 5126 |
+
var view = cm.display.view, dirty = 0;
|
| 5127 |
for (var i = 0; i < view.length; i++) {
|
| 5128 |
+
var lineView = view[i];
|
| 5129 |
+
if (!lineView.hidden && (!lineView.node || lineView.changes)) { ++dirty; }
|
| 5130 |
}
|
| 5131 |
return dirty
|
| 5132 |
}
|
| 5135 |
|
| 5136 |
function startWorker(cm, time) {
|
| 5137 |
if (cm.doc.mode.startState && cm.doc.frontier < cm.display.viewTo)
|
| 5138 |
+
{ cm.state.highlight.set(time, bind(highlightWorker, cm)); }
|
| 5139 |
}
|
| 5140 |
|
| 5141 |
function highlightWorker(cm) {
|
| 5142 |
+
var doc = cm.doc;
|
| 5143 |
+
if (doc.frontier < doc.first) { doc.frontier = doc.first; }
|
| 5144 |
if (doc.frontier >= cm.display.viewTo) { return }
|
| 5145 |
+
var end = +new Date + cm.options.workTime;
|
| 5146 |
+
var state = copyState(doc.mode, getStateBefore(cm, doc.frontier));
|
| 5147 |
+
var changedLines = [];
|
| 5148 |
|
| 5149 |
doc.iter(doc.frontier, Math.min(doc.first + doc.size, cm.display.viewTo + 500), function (line) {
|
| 5150 |
if (doc.frontier >= cm.display.viewFrom) { // Visible
|
| 5151 |
+
var oldStyles = line.styles, tooLong = line.text.length > cm.options.maxHighlightLength;
|
| 5152 |
+
var highlighted = highlightLine(cm, line, tooLong ? copyState(doc.mode, state) : state, true);
|
| 5153 |
+
line.styles = highlighted.styles;
|
| 5154 |
+
var oldCls = line.styleClasses, newCls = highlighted.classes;
|
| 5155 |
+
if (newCls) { line.styleClasses = newCls; }
|
| 5156 |
+
else if (oldCls) { line.styleClasses = null; }
|
| 5157 |
var ischange = !oldStyles || oldStyles.length != line.styles.length ||
|
| 5158 |
+
oldCls != newCls && (!oldCls || !newCls || oldCls.bgClass != newCls.bgClass || oldCls.textClass != newCls.textClass);
|
| 5159 |
+
for (var i = 0; !ischange && i < oldStyles.length; ++i) { ischange = oldStyles[i] != line.styles[i]; }
|
| 5160 |
+
if (ischange) { changedLines.push(doc.frontier); }
|
| 5161 |
+
line.stateAfter = tooLong ? state : copyState(doc.mode, state);
|
| 5162 |
} else {
|
| 5163 |
if (line.text.length <= cm.options.maxHighlightLength)
|
| 5164 |
+
{ processLine(cm, line.text, state); }
|
| 5165 |
+
line.stateAfter = doc.frontier % 5 == 0 ? copyState(doc.mode, state) : null;
|
| 5166 |
}
|
| 5167 |
+
++doc.frontier;
|
| 5168 |
if (+new Date > end) {
|
| 5169 |
+
startWorker(cm, cm.options.workDelay);
|
| 5170 |
return true
|
| 5171 |
}
|
| 5172 |
+
});
|
| 5173 |
if (changedLines.length) { runInOp(cm, function () {
|
| 5174 |
for (var i = 0; i < changedLines.length; i++)
|
| 5175 |
+
{ regLineChange(cm, changedLines[i], "text"); }
|
| 5176 |
+
}); }
|
| 5177 |
}
|
| 5178 |
|
| 5179 |
// DISPLAY DRAWING
|
| 5180 |
|
| 5181 |
var DisplayUpdate = function(cm, viewport, force) {
|
| 5182 |
+
var display = cm.display;
|
| 5183 |
|
| 5184 |
+
this.viewport = viewport;
|
| 5185 |
// Store some values that we'll need later (but don't want to force a relayout for)
|
| 5186 |
+
this.visible = visibleLines(display, cm.doc, viewport);
|
| 5187 |
+
this.editorIsHidden = !display.wrapper.offsetWidth;
|
| 5188 |
+
this.wrapperHeight = display.wrapper.clientHeight;
|
| 5189 |
+
this.wrapperWidth = display.wrapper.clientWidth;
|
| 5190 |
+
this.oldDisplayWidth = displayWidth(cm);
|
| 5191 |
+
this.force = force;
|
| 5192 |
+
this.dims = getDimensions(cm);
|
| 5193 |
+
this.events = [];
|
| 5194 |
};
|
| 5195 |
|
| 5196 |
DisplayUpdate.prototype.signal = function (emitter, type) {
|
| 5197 |
if (hasHandler(emitter, type))
|
| 5198 |
+
{ this.events.push(arguments); }
|
| 5199 |
};
|
| 5200 |
DisplayUpdate.prototype.finish = function () {
|
| 5201 |
var this$1 = this;
|
| 5202 |
|
| 5203 |
for (var i = 0; i < this.events.length; i++)
|
| 5204 |
+
{ signal.apply(null, this$1.events[i]); }
|
| 5205 |
};
|
| 5206 |
|
| 5207 |
function maybeClipScrollbars(cm) {
|
| 5208 |
+
var display = cm.display;
|
| 5209 |
if (!display.scrollbarsClipped && display.scroller.offsetWidth) {
|
| 5210 |
+
display.nativeBarWidth = display.scroller.offsetWidth - display.scroller.clientWidth;
|
| 5211 |
+
display.heightForcer.style.height = scrollGap(cm) + "px";
|
| 5212 |
+
display.sizer.style.marginBottom = -display.nativeBarWidth + "px";
|
| 5213 |
+
display.sizer.style.borderRightWidth = scrollGap(cm) + "px";
|
| 5214 |
+
display.scrollbarsClipped = true;
|
| 5215 |
}
|
| 5216 |
}
|
| 5217 |
|
| 5219 |
// (returning false) when there is nothing to be done and forced is
|
| 5220 |
// false.
|
| 5221 |
function updateDisplayIfNeeded(cm, update) {
|
| 5222 |
+
var display = cm.display, doc = cm.doc;
|
| 5223 |
|
| 5224 |
if (update.editorIsHidden) {
|
| 5225 |
+
resetView(cm);
|
| 5226 |
return false
|
| 5227 |
}
|
| 5228 |
|
| 5234 |
{ return false }
|
| 5235 |
|
| 5236 |
if (maybeUpdateLineNumberWidth(cm)) {
|
| 5237 |
+
resetView(cm);
|
| 5238 |
+
update.dims = getDimensions(cm);
|
| 5239 |
}
|
| 5240 |
|
| 5241 |
// Compute a suitable new viewport (from & to)
|
| 5242 |
+
var end = doc.first + doc.size;
|
| 5243 |
+
var from = Math.max(update.visible.from - cm.options.viewportMargin, doc.first);
|
| 5244 |
+
var to = Math.min(end, update.visible.to + cm.options.viewportMargin);
|
| 5245 |
+
if (display.viewFrom < from && from - display.viewFrom < 20) { from = Math.max(doc.first, display.viewFrom); }
|
| 5246 |
+
if (display.viewTo > to && display.viewTo - to < 20) { to = Math.min(end, display.viewTo); }
|
| 5247 |
if (sawCollapsedSpans) {
|
| 5248 |
+
from = visualLineNo(cm.doc, from);
|
| 5249 |
+
to = visualLineEndNo(cm.doc, to);
|
| 5250 |
}
|
| 5251 |
|
| 5252 |
var different = from != display.viewFrom || to != display.viewTo ||
|
| 5253 |
+
display.lastWrapHeight != update.wrapperHeight || display.lastWrapWidth != update.wrapperWidth;
|
| 5254 |
+
adjustView(cm, from, to);
|
| 5255 |
|
| 5256 |
+
display.viewOffset = heightAtLine(getLine(cm.doc, display.viewFrom));
|
| 5257 |
// Position the mover div to align with the current scroll position
|
| 5258 |
+
cm.display.mover.style.top = display.viewOffset + "px";
|
| 5259 |
|
| 5260 |
+
var toUpdate = countDirtyView(cm);
|
| 5261 |
if (!different && toUpdate == 0 && !update.force && display.renderedView == display.view &&
|
| 5262 |
(display.updateLineNumbers == null || display.updateLineNumbers >= display.viewTo))
|
| 5263 |
{ return false }
|
| 5264 |
|
| 5265 |
// For big changes, we hide the enclosing element during the
|
| 5266 |
// update, since that speeds up the operations on most browsers.
|
| 5267 |
+
var focused = activeElt();
|
| 5268 |
+
if (toUpdate > 4) { display.lineDiv.style.display = "none"; }
|
| 5269 |
+
patchDisplay(cm, display.updateLineNumbers, update.dims);
|
| 5270 |
+
if (toUpdate > 4) { display.lineDiv.style.display = ""; }
|
| 5271 |
+
display.renderedView = display.view;
|
| 5272 |
// There might have been a widget with a focused element that got
|
| 5273 |
// hidden or updated, if so re-focus it.
|
| 5274 |
+
if (focused && activeElt() != focused && focused.offsetHeight) { focused.focus(); }
|
| 5275 |
|
| 5276 |
// Prevent selection and cursors from interfering with the scroll
|
| 5277 |
// width and height.
|
| 5278 |
+
removeChildren(display.cursorDiv);
|
| 5279 |
+
removeChildren(display.selectionDiv);
|
| 5280 |
+
display.gutters.style.height = display.sizer.style.minHeight = 0;
|
| 5281 |
|
| 5282 |
if (different) {
|
| 5283 |
+
display.lastWrapHeight = update.wrapperHeight;
|
| 5284 |
+
display.lastWrapWidth = update.wrapperWidth;
|
| 5285 |
+
startWorker(cm, 400);
|
| 5286 |
}
|
| 5287 |
|
| 5288 |
+
display.updateLineNumbers = null;
|
| 5289 |
|
| 5290 |
return true
|
| 5291 |
}
|
| 5292 |
|
| 5293 |
function postUpdateDisplay(cm, update) {
|
| 5294 |
+
var viewport = update.viewport;
|
| 5295 |
|
| 5296 |
for (var first = true;; first = false) {
|
| 5297 |
if (!first || !cm.options.lineWrapping || update.oldDisplayWidth == displayWidth(cm)) {
|
| 5298 |
// Clip forced viewport to actual scrollable area.
|
| 5299 |
if (viewport && viewport.top != null)
|
| 5300 |
+
{ viewport = {top: Math.min(cm.doc.height + paddingVert(cm.display) - displayHeight(cm), viewport.top)}; }
|
| 5301 |
// Updated line heights might result in the drawn area not
|
| 5302 |
// actually covering the viewport. Keep looping until it does.
|
| 5303 |
+
update.visible = visibleLines(cm.display, cm.doc, viewport);
|
| 5304 |
if (update.visible.from >= cm.display.viewFrom && update.visible.to <= cm.display.viewTo)
|
| 5305 |
{ break }
|
| 5306 |
}
|
| 5307 |
if (!updateDisplayIfNeeded(cm, update)) { break }
|
| 5308 |
+
updateHeightsInViewport(cm);
|
| 5309 |
+
var barMeasure = measureForScrollbars(cm);
|
| 5310 |
+
updateSelection(cm);
|
| 5311 |
+
updateScrollbars(cm, barMeasure);
|
| 5312 |
+
setDocumentHeight(cm, barMeasure);
|
| 5313 |
}
|
| 5314 |
|
| 5315 |
+
update.signal(cm, "update", cm);
|
| 5316 |
if (cm.display.viewFrom != cm.display.reportedViewFrom || cm.display.viewTo != cm.display.reportedViewTo) {
|
| 5317 |
+
update.signal(cm, "viewportChange", cm, cm.display.viewFrom, cm.display.viewTo);
|
| 5318 |
+
cm.display.reportedViewFrom = cm.display.viewFrom; cm.display.reportedViewTo = cm.display.viewTo;
|
| 5319 |
}
|
| 5320 |
}
|
| 5321 |
|
| 5322 |
function updateDisplaySimple(cm, viewport) {
|
| 5323 |
+
var update = new DisplayUpdate(cm, viewport);
|
| 5324 |
if (updateDisplayIfNeeded(cm, update)) {
|
| 5325 |
+
updateHeightsInViewport(cm);
|
| 5326 |
+
postUpdateDisplay(cm, update);
|
| 5327 |
+
var barMeasure = measureForScrollbars(cm);
|
| 5328 |
+
updateSelection(cm);
|
| 5329 |
+
updateScrollbars(cm, barMeasure);
|
| 5330 |
+
setDocumentHeight(cm, barMeasure);
|
| 5331 |
+
update.finish();
|
| 5332 |
}
|
| 5333 |
}
|
| 5334 |
|
| 5337 |
// that are not there yet, and updating the ones that are out of
|
| 5338 |
// date.
|
| 5339 |
function patchDisplay(cm, updateNumbersFrom, dims) {
|
| 5340 |
+
var display = cm.display, lineNumbers = cm.options.lineNumbers;
|
| 5341 |
+
var container = display.lineDiv, cur = container.firstChild;
|
| 5342 |
|
| 5343 |
function rm(node) {
|
| 5344 |
+
var next = node.nextSibling;
|
| 5345 |
// Works around a throw-scroll bug in OS X Webkit
|
| 5346 |
if (webkit && mac && cm.display.currentWheelTarget == node)
|
| 5347 |
+
{ node.style.display = "none"; }
|
| 5348 |
else
|
| 5349 |
+
{ node.parentNode.removeChild(node); }
|
| 5350 |
return next
|
| 5351 |
}
|
| 5352 |
|
| 5353 |
+
var view = display.view, lineN = display.viewFrom;
|
| 5354 |
// Loop over the elements in the view, syncing cur (the DOM nodes
|
| 5355 |
// in display.lineDiv) with the view as we go.
|
| 5356 |
for (var i = 0; i < view.length; i++) {
|
| 5357 |
+
var lineView = view[i];
|
| 5358 |
if (lineView.hidden) {
|
| 5359 |
} else if (!lineView.node || lineView.node.parentNode != container) { // Not drawn yet
|
| 5360 |
+
var node = buildLineElement(cm, lineView, lineN, dims);
|
| 5361 |
+
container.insertBefore(node, cur);
|
| 5362 |
} else { // Already drawn
|
| 5363 |
+
while (cur != lineView.node) { cur = rm(cur); }
|
| 5364 |
var updateNumber = lineNumbers && updateNumbersFrom != null &&
|
| 5365 |
+
updateNumbersFrom <= lineN && lineView.lineNumber;
|
| 5366 |
if (lineView.changes) {
|
| 5367 |
+
if (indexOf(lineView.changes, "gutter") > -1) { updateNumber = false; }
|
| 5368 |
+
updateLineForChanges(cm, lineView, lineN, dims);
|
| 5369 |
}
|
| 5370 |
if (updateNumber) {
|
| 5371 |
+
removeChildren(lineView.lineNumber);
|
| 5372 |
+
lineView.lineNumber.appendChild(document.createTextNode(lineNumberFor(cm.options, lineN)));
|
| 5373 |
}
|
| 5374 |
+
cur = lineView.node.nextSibling;
|
| 5375 |
}
|
| 5376 |
+
lineN += lineView.size;
|
| 5377 |
}
|
| 5378 |
+
while (cur) { cur = rm(cur); }
|
| 5379 |
}
|
| 5380 |
|
| 5381 |
function updateGutterSpace(cm) {
|
| 5382 |
+
var width = cm.display.gutters.offsetWidth;
|
| 5383 |
+
cm.display.sizer.style.marginLeft = width + "px";
|
| 5384 |
}
|
| 5385 |
|
| 5386 |
function setDocumentHeight(cm, measure) {
|
| 5387 |
+
cm.display.sizer.style.minHeight = measure.docHeight + "px";
|
| 5388 |
+
cm.display.heightForcer.style.top = measure.docHeight + "px";
|
| 5389 |
+
cm.display.gutters.style.height = (measure.docHeight + cm.display.barHeight + scrollGap(cm)) + "px";
|
| 5390 |
}
|
| 5391 |
|
| 5392 |
// Rebuild the gutter elements, ensure the margin to the left of the
|
| 5393 |
// code matches their width.
|
| 5394 |
function updateGutters(cm) {
|
| 5395 |
+
var gutters = cm.display.gutters, specs = cm.options.gutters;
|
| 5396 |
+
removeChildren(gutters);
|
| 5397 |
+
var i = 0;
|
| 5398 |
for (; i < specs.length; ++i) {
|
| 5399 |
+
var gutterClass = specs[i];
|
| 5400 |
+
var gElt = gutters.appendChild(elt("div", null, "CodeMirror-gutter " + gutterClass));
|
| 5401 |
if (gutterClass == "CodeMirror-linenumbers") {
|
| 5402 |
+
cm.display.lineGutter = gElt;
|
| 5403 |
+
gElt.style.width = (cm.display.lineNumWidth || 1) + "px";
|
| 5404 |
}
|
| 5405 |
}
|
| 5406 |
+
gutters.style.display = i ? "" : "none";
|
| 5407 |
+
updateGutterSpace(cm);
|
| 5408 |
}
|
| 5409 |
|
| 5410 |
// Make sure the gutters options contains the element
|
| 5411 |
// "CodeMirror-linenumbers" when the lineNumbers option is true.
|
| 5412 |
function setGuttersForLineNumbers(options) {
|
| 5413 |
+
var found = indexOf(options.gutters, "CodeMirror-linenumbers");
|
| 5414 |
if (found == -1 && options.lineNumbers) {
|
| 5415 |
+
options.gutters = options.gutters.concat(["CodeMirror-linenumbers"]);
|
| 5416 |
} else if (found > -1 && !options.lineNumbers) {
|
| 5417 |
+
options.gutters = options.gutters.slice(0);
|
| 5418 |
+
options.gutters.splice(found, 1);
|
| 5419 |
}
|
| 5420 |
}
|
| 5421 |
|
| 5425 |
// which one is the primary selection (the one that's scrolled into
|
| 5426 |
// view, that getCursor returns, etc).
|
| 5427 |
var Selection = function(ranges, primIndex) {
|
| 5428 |
+
this.ranges = ranges;
|
| 5429 |
+
this.primIndex = primIndex;
|
| 5430 |
};
|
| 5431 |
|
| 5432 |
Selection.prototype.primary = function () { return this.ranges[this.primIndex] };
|
| 5437 |
if (other == this) { return true }
|
| 5438 |
if (other.primIndex != this.primIndex || other.ranges.length != this.ranges.length) { return false }
|
| 5439 |
for (var i = 0; i < this.ranges.length; i++) {
|
| 5440 |
+
var here = this$1.ranges[i], there = other.ranges[i];
|
| 5441 |
if (!equalCursorPos(here.anchor, there.anchor) || !equalCursorPos(here.head, there.head)) { return false }
|
| 5442 |
}
|
| 5443 |
return true
|
| 5446 |
Selection.prototype.deepCopy = function () {
|
| 5447 |
var this$1 = this;
|
| 5448 |
|
| 5449 |
+
var out = [];
|
| 5450 |
for (var i = 0; i < this.ranges.length; i++)
|
| 5451 |
+
{ out[i] = new Range(copyPos(this$1.ranges[i].anchor), copyPos(this$1.ranges[i].head)); }
|
| 5452 |
return new Selection(out, this.primIndex)
|
| 5453 |
};
|
| 5454 |
|
| 5463 |
Selection.prototype.contains = function (pos, end) {
|
| 5464 |
var this$1 = this;
|
| 5465 |
|
| 5466 |
+
if (!end) { end = pos; }
|
| 5467 |
for (var i = 0; i < this.ranges.length; i++) {
|
| 5468 |
+
var range = this$1.ranges[i];
|
| 5469 |
if (cmp(end, range.from()) >= 0 && cmp(pos, range.to()) <= 0)
|
| 5470 |
{ return i }
|
| 5471 |
}
|
| 5473 |
};
|
| 5474 |
|
| 5475 |
var Range = function(anchor, head) {
|
| 5476 |
+
this.anchor = anchor; this.head = head;
|
| 5477 |
};
|
| 5478 |
|
| 5479 |
Range.prototype.from = function () { return minPos(this.anchor, this.head) };
|
| 5484 |
// build a selection out of it. 'Consumes' ranges array (modifying
|
| 5485 |
// it).
|
| 5486 |
function normalizeSelection(ranges, primIndex) {
|
| 5487 |
+
var prim = ranges[primIndex];
|
| 5488 |
+
ranges.sort(function (a, b) { return cmp(a.from(), b.from()); });
|
| 5489 |
+
primIndex = indexOf(ranges, prim);
|
| 5490 |
for (var i = 1; i < ranges.length; i++) {
|
| 5491 |
+
var cur = ranges[i], prev = ranges[i - 1];
|
| 5492 |
if (cmp(prev.to(), cur.from()) >= 0) {
|
| 5493 |
+
var from = minPos(prev.from(), cur.from()), to = maxPos(prev.to(), cur.to());
|
| 5494 |
+
var inv = prev.empty() ? cur.from() == cur.head : prev.from() == prev.head;
|
| 5495 |
+
if (i <= primIndex) { --primIndex; }
|
| 5496 |
+
ranges.splice(--i, 2, new Range(inv ? to : from, inv ? from : to));
|
| 5497 |
}
|
| 5498 |
}
|
| 5499 |
return new Selection(ranges, primIndex)
|
| 5517 |
if (cmp(pos, change.from) < 0) { return pos }
|
| 5518 |
if (cmp(pos, change.to) <= 0) { return changeEnd(change) }
|
| 5519 |
|
| 5520 |
+
var line = pos.line + change.text.length - (change.to.line - change.from.line) - 1, ch = pos.ch;
|
| 5521 |
+
if (pos.line == change.to.line) { ch += changeEnd(change).ch - change.to.ch; }
|
| 5522 |
return Pos(line, ch)
|
| 5523 |
}
|
| 5524 |
|
| 5525 |
function computeSelAfterChange(doc, change) {
|
| 5526 |
+
var out = [];
|
| 5527 |
for (var i = 0; i < doc.sel.ranges.length; i++) {
|
| 5528 |
+
var range = doc.sel.ranges[i];
|
| 5529 |
out.push(new Range(adjustForChange(range.anchor, change),
|
| 5530 |
+
adjustForChange(range.head, change)));
|
| 5531 |
}
|
| 5532 |
return normalizeSelection(out, doc.sel.primIndex)
|
| 5533 |
}
|
| 5542 |
// Used by replaceSelections to allow moving the selection to the
|
| 5543 |
// start or around the replaced test. Hint may be "start" or "around".
|
| 5544 |
function computeReplacedSel(doc, changes, hint) {
|
| 5545 |
+
var out = [];
|
| 5546 |
+
var oldPrev = Pos(doc.first, 0), newPrev = oldPrev;
|
| 5547 |
for (var i = 0; i < changes.length; i++) {
|
| 5548 |
+
var change = changes[i];
|
| 5549 |
+
var from = offsetPos(change.from, oldPrev, newPrev);
|
| 5550 |
+
var to = offsetPos(changeEnd(change), oldPrev, newPrev);
|
| 5551 |
+
oldPrev = change.to;
|
| 5552 |
+
newPrev = to;
|
| 5553 |
if (hint == "around") {
|
| 5554 |
+
var range = doc.sel.ranges[i], inv = cmp(range.head, range.anchor) < 0;
|
| 5555 |
+
out[i] = new Range(inv ? to : from, inv ? from : to);
|
| 5556 |
} else {
|
| 5557 |
+
out[i] = new Range(from, from);
|
| 5558 |
}
|
| 5559 |
}
|
| 5560 |
return new Selection(out, doc.sel.primIndex)
|
| 5563 |
// Used to get the editor into a consistent state again when options change.
|
| 5564 |
|
| 5565 |
function loadMode(cm) {
|
| 5566 |
+
cm.doc.mode = getMode(cm.options, cm.doc.modeOption);
|
| 5567 |
+
resetModeState(cm);
|
| 5568 |
}
|
| 5569 |
|
| 5570 |
function resetModeState(cm) {
|
| 5571 |
cm.doc.iter(function (line) {
|
| 5572 |
+
if (line.stateAfter) { line.stateAfter = null; }
|
| 5573 |
+
if (line.styles) { line.styles = null; }
|
| 5574 |
+
});
|
| 5575 |
+
cm.doc.frontier = cm.doc.first;
|
| 5576 |
+
startWorker(cm, 100);
|
| 5577 |
+
cm.state.modeGen++;
|
| 5578 |
+
if (cm.curOp) { regChange(cm); }
|
| 5579 |
}
|
| 5580 |
|
| 5581 |
// DOCUMENT DATA STRUCTURE
|
| 5589 |
}
|
| 5590 |
|
| 5591 |
// Perform a change on the document data structure.
|
| 5592 |
+
function updateDoc(doc, change, markedSpans, estimateHeight$$1) {
|
| 5593 |
function spansFor(n) {return markedSpans ? markedSpans[n] : null}
|
| 5594 |
function update(line, text, spans) {
|
| 5595 |
+
updateLine(line, text, spans, estimateHeight$$1);
|
| 5596 |
+
signalLater(line, "change", line, change);
|
| 5597 |
}
|
| 5598 |
function linesFor(start, end) {
|
| 5599 |
+
var result = [];
|
| 5600 |
for (var i = start; i < end; ++i)
|
| 5601 |
+
{ result.push(new Line(text[i], spansFor(i), estimateHeight$$1)); }
|
| 5602 |
return result
|
| 5603 |
}
|
| 5604 |
|
| 5605 |
+
var from = change.from, to = change.to, text = change.text;
|
| 5606 |
+
var firstLine = getLine(doc, from.line), lastLine = getLine(doc, to.line);
|
| 5607 |
+
var lastText = lst(text), lastSpans = spansFor(text.length - 1), nlines = to.line - from.line;
|
| 5608 |
|
| 5609 |
// Adjust the line structure
|
| 5610 |
if (change.full) {
|
| 5611 |
+
doc.insert(0, linesFor(0, text.length));
|
| 5612 |
+
doc.remove(text.length, doc.size - text.length);
|
| 5613 |
} else if (isWholeLineUpdate(doc, change)) {
|
| 5614 |
// This is a whole-line replace. Treated specially to make
|
| 5615 |
// sure line objects move the way they are supposed to.
|
| 5616 |
+
var added = linesFor(0, text.length - 1);
|
| 5617 |
+
update(lastLine, lastLine.text, lastSpans);
|
| 5618 |
+
if (nlines) { doc.remove(from.line, nlines); }
|
| 5619 |
+
if (added.length) { doc.insert(from.line, added); }
|
| 5620 |
} else if (firstLine == lastLine) {
|
| 5621 |
if (text.length == 1) {
|
| 5622 |
+
update(firstLine, firstLine.text.slice(0, from.ch) + lastText + firstLine.text.slice(to.ch), lastSpans);
|
| 5623 |
} else {
|
| 5624 |
+
var added$1 = linesFor(1, text.length - 1);
|
| 5625 |
+
added$1.push(new Line(lastText + firstLine.text.slice(to.ch), lastSpans, estimateHeight$$1));
|
| 5626 |
+
update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
|
| 5627 |
+
doc.insert(from.line + 1, added$1);
|
| 5628 |
}
|
| 5629 |
} else if (text.length == 1) {
|
| 5630 |
+
update(firstLine, firstLine.text.slice(0, from.ch) + text[0] + lastLine.text.slice(to.ch), spansFor(0));
|
| 5631 |
+
doc.remove(from.line + 1, nlines);
|
| 5632 |
} else {
|
| 5633 |
+
update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
|
| 5634 |
+
update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans);
|
| 5635 |
+
var added$2 = linesFor(1, text.length - 1);
|
| 5636 |
+
if (nlines > 1) { doc.remove(from.line + 1, nlines - 1); }
|
| 5637 |
+
doc.insert(from.line + 1, added$2);
|
| 5638 |
}
|
| 5639 |
|
| 5640 |
+
signalLater(doc, "change", doc, change);
|
| 5641 |
}
|
| 5642 |
|
| 5643 |
// Call f for all linked documents.
|
| 5644 |
function linkedDocs(doc, f, sharedHistOnly) {
|
| 5645 |
function propagate(doc, skip, sharedHist) {
|
| 5646 |
if (doc.linked) { for (var i = 0; i < doc.linked.length; ++i) {
|
| 5647 |
+
var rel = doc.linked[i];
|
| 5648 |
if (rel.doc == skip) { continue }
|
| 5649 |
+
var shared = sharedHist && rel.sharedHist;
|
| 5650 |
if (sharedHistOnly && !shared) { continue }
|
| 5651 |
+
f(rel.doc, shared);
|
| 5652 |
+
propagate(rel.doc, doc, shared);
|
| 5653 |
} }
|
| 5654 |
}
|
| 5655 |
+
propagate(doc, null, true);
|
| 5656 |
}
|
| 5657 |
|
| 5658 |
// Attach a document to an editor.
|
| 5659 |
function attachDoc(cm, doc) {
|
| 5660 |
if (doc.cm) { throw new Error("This document is already in use.") }
|
| 5661 |
+
cm.doc = doc;
|
| 5662 |
+
doc.cm = cm;
|
| 5663 |
+
estimateLineHeights(cm);
|
| 5664 |
+
loadMode(cm);
|
| 5665 |
+
setDirectionClass(cm);
|
| 5666 |
+
if (!cm.options.lineWrapping) { findMaxLine(cm); }
|
| 5667 |
+
cm.options.mode = doc.modeOption;
|
| 5668 |
+
regChange(cm);
|
| 5669 |
+
}
|
| 5670 |
+
|
| 5671 |
+
function setDirectionClass(cm) {
|
| 5672 |
+
(cm.doc.direction == "rtl" ? addClass : rmClass)(cm.display.lineDiv, "CodeMirror-rtl");
|
| 5673 |
+
}
|
| 5674 |
+
|
| 5675 |
+
function directionChanged(cm) {
|
| 5676 |
+
runInOp(cm, function () {
|
| 5677 |
+
setDirectionClass(cm);
|
| 5678 |
+
regChange(cm);
|
| 5679 |
+
});
|
| 5680 |
}
|
| 5681 |
|
| 5682 |
function History(startGen) {
|
| 5683 |
// Arrays of change events and selections. Doing something adds an
|
| 5684 |
// event to done and clears undo. Undoing moves events from done
|
| 5685 |
// to undone, redoing moves them in the other direction.
|
| 5686 |
+
this.done = []; this.undone = [];
|
| 5687 |
+
this.undoDepth = Infinity;
|
| 5688 |
// Used to track when changes can be merged into a single undo
|
| 5689 |
// event
|
| 5690 |
+
this.lastModTime = this.lastSelTime = 0;
|
| 5691 |
+
this.lastOp = this.lastSelOp = null;
|
| 5692 |
+
this.lastOrigin = this.lastSelOrigin = null;
|
| 5693 |
// Used by the isClean() method
|
| 5694 |
+
this.generation = this.maxGeneration = startGen || 1;
|
| 5695 |
}
|
| 5696 |
|
| 5697 |
// Create a history change event from an updateDoc-style change
|
| 5698 |
// object.
|
| 5699 |
function historyChangeFromChange(doc, change) {
|
| 5700 |
+
var histChange = {from: copyPos(change.from), to: changeEnd(change), text: getBetween(doc, change.from, change.to)};
|
| 5701 |
+
attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1);
|
| 5702 |
+
linkedDocs(doc, function (doc) { return attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1); }, true);
|
| 5703 |
return histChange
|
| 5704 |
}
|
| 5705 |
|
| 5707 |
// a change event.
|
| 5708 |
function clearSelectionEvents(array) {
|
| 5709 |
while (array.length) {
|
| 5710 |
+
var last = lst(array);
|
| 5711 |
+
if (last.ranges) { array.pop(); }
|
| 5712 |
else { break }
|
| 5713 |
}
|
| 5714 |
}
|
| 5717 |
// events that are in the way.
|
| 5718 |
function lastChangeEvent(hist, force) {
|
| 5719 |
if (force) {
|
| 5720 |
+
clearSelectionEvents(hist.done);
|
| 5721 |
return lst(hist.done)
|
| 5722 |
} else if (hist.done.length && !lst(hist.done).ranges) {
|
| 5723 |
return lst(hist.done)
|
| 5724 |
} else if (hist.done.length > 1 && !hist.done[hist.done.length - 2].ranges) {
|
| 5725 |
+
hist.done.pop();
|
| 5726 |
return lst(hist.done)
|
| 5727 |
}
|
| 5728 |
}
|
| 5731 |
// a single operation, or are close together with an origin that
|
| 5732 |
// allows merging (starting with "+") into a single event.
|
| 5733 |
function addChangeToHistory(doc, change, selAfter, opId) {
|
| 5734 |
+
var hist = doc.history;
|
| 5735 |
+
hist.undone.length = 0;
|
| 5736 |
+
var time = +new Date, cur;
|
| 5737 |
+
var last;
|
| 5738 |
|
| 5739 |
if ((hist.lastOp == opId ||
|
| 5740 |
hist.lastOrigin == change.origin && change.origin &&
|
| 5742 |
change.origin.charAt(0) == "*")) &&
|
| 5743 |
(cur = lastChangeEvent(hist, hist.lastOp == opId))) {
|
| 5744 |
// Merge this change into the last event
|
| 5745 |
+
last = lst(cur.changes);
|
| 5746 |
if (cmp(change.from, change.to) == 0 && cmp(change.from, last.to) == 0) {
|
| 5747 |
// Optimized case for simple insertion -- don't want to add
|
| 5748 |
// new changesets for every character typed
|
| 5749 |
+
last.to = changeEnd(change);
|
| 5750 |
} else {
|
| 5751 |
// Add new sub-event
|
| 5752 |
+
cur.changes.push(historyChangeFromChange(doc, change));
|
| 5753 |
}
|
| 5754 |
} else {
|
| 5755 |
// Can not be merged, start a new event.
|
| 5756 |
+
var before = lst(hist.done);
|
| 5757 |
if (!before || !before.ranges)
|
| 5758 |
+
{ pushSelectionToHistory(doc.sel, hist.done); }
|
| 5759 |
cur = {changes: [historyChangeFromChange(doc, change)],
|
| 5760 |
+
generation: hist.generation};
|
| 5761 |
+
hist.done.push(cur);
|
| 5762 |
while (hist.done.length > hist.undoDepth) {
|
| 5763 |
+
hist.done.shift();
|
| 5764 |
+
if (!hist.done[0].ranges) { hist.done.shift(); }
|
| 5765 |
}
|
| 5766 |
}
|
| 5767 |
+
hist.done.push(selAfter);
|
| 5768 |
+
hist.generation = ++hist.maxGeneration;
|
| 5769 |
+
hist.lastModTime = hist.lastSelTime = time;
|
| 5770 |
+
hist.lastOp = hist.lastSelOp = opId;
|
| 5771 |
+
hist.lastOrigin = hist.lastSelOrigin = change.origin;
|
| 5772 |
|
| 5773 |
+
if (!last) { signal(doc, "historyAdded"); }
|
| 5774 |
}
|
| 5775 |
|
| 5776 |
function selectionEventCanBeMerged(doc, origin, prev, sel) {
|
| 5777 |
+
var ch = origin.charAt(0);
|
| 5778 |
return ch == "*" ||
|
| 5779 |
ch == "+" &&
|
| 5780 |
prev.ranges.length == sel.ranges.length &&
|
| 5787 |
// selection into the 'done' array when it was significantly
|
| 5788 |
// different (in number of selected ranges, emptiness, or time).
|
| 5789 |
function addSelectionToHistory(doc, sel, opId, options) {
|
| 5790 |
+
var hist = doc.history, origin = options && options.origin;
|
| 5791 |
|
| 5792 |
// A new event is started when the previous origin does not match
|
| 5793 |
// the current, or the origins don't allow matching. Origins
|
| 5797 |
(origin && hist.lastSelOrigin == origin &&
|
| 5798 |
(hist.lastModTime == hist.lastSelTime && hist.lastOrigin == origin ||
|
| 5799 |
selectionEventCanBeMerged(doc, origin, lst(hist.done), sel))))
|
| 5800 |
+
{ hist.done[hist.done.length - 1] = sel; }
|
| 5801 |
else
|
| 5802 |
+
{ pushSelectionToHistory(sel, hist.done); }
|
| 5803 |
|
| 5804 |
+
hist.lastSelTime = +new Date;
|
| 5805 |
+
hist.lastSelOrigin = origin;
|
| 5806 |
+
hist.lastSelOp = opId;
|
| 5807 |
if (options && options.clearRedo !== false)
|
| 5808 |
+
{ clearSelectionEvents(hist.undone); }
|
| 5809 |
}
|
| 5810 |
|
| 5811 |
function pushSelectionToHistory(sel, dest) {
|
| 5812 |
+
var top = lst(dest);
|
| 5813 |
if (!(top && top.ranges && top.equals(sel)))
|
| 5814 |
+
{ dest.push(sel); }
|
| 5815 |
}
|
| 5816 |
|
| 5817 |
// Used to store marked span information in the history.
|
| 5818 |
function attachLocalSpans(doc, change, from, to) {
|
| 5819 |
+
var existing = change["spans_" + doc.id], n = 0;
|
| 5820 |
doc.iter(Math.max(doc.first, from), Math.min(doc.first + doc.size, to), function (line) {
|
| 5821 |
if (line.markedSpans)
|
| 5822 |
+
{ (existing || (existing = change["spans_" + doc.id] = {}))[n] = line.markedSpans; }
|
| 5823 |
+
++n;
|
| 5824 |
+
});
|
| 5825 |
}
|
| 5826 |
|
| 5827 |
// When un/re-doing restores text containing marked spans, those
|
| 5828 |
// that have been explicitly cleared should not be restored.
|
| 5829 |
function removeClearedSpans(spans) {
|
| 5830 |
if (!spans) { return null }
|
| 5831 |
+
var out;
|
| 5832 |
for (var i = 0; i < spans.length; ++i) {
|
| 5833 |
+
if (spans[i].marker.explicitlyCleared) { if (!out) { out = spans.slice(0, i); } }
|
| 5834 |
+
else if (out) { out.push(spans[i]); }
|
| 5835 |
}
|
| 5836 |
return !out ? spans : out.length ? out : null
|
| 5837 |
}
|
| 5838 |
|
| 5839 |
// Retrieve and filter the old marked spans stored in a change event.
|
| 5840 |
function getOldSpans(doc, change) {
|
| 5841 |
+
var found = change["spans_" + doc.id];
|
| 5842 |
if (!found) { return null }
|
| 5843 |
+
var nw = [];
|
| 5844 |
for (var i = 0; i < change.text.length; ++i)
|
| 5845 |
+
{ nw.push(removeClearedSpans(found[i])); }
|
| 5846 |
return nw
|
| 5847 |
}
|
| 5848 |
|
| 5851 |
// existed in the history (so that deleting around a span and then
|
| 5852 |
// undoing brings back the span).
|
| 5853 |
function mergeOldSpans(doc, change) {
|
| 5854 |
+
var old = getOldSpans(doc, change);
|
| 5855 |
+
var stretched = stretchSpansOverChange(doc, change);
|
| 5856 |
if (!old) { return stretched }
|
| 5857 |
if (!stretched) { return old }
|
| 5858 |
|
| 5859 |
for (var i = 0; i < old.length; ++i) {
|
| 5860 |
+
var oldCur = old[i], stretchCur = stretched[i];
|
| 5861 |
if (oldCur && stretchCur) {
|
| 5862 |
spans: for (var j = 0; j < stretchCur.length; ++j) {
|
| 5863 |
+
var span = stretchCur[j];
|
| 5864 |
for (var k = 0; k < oldCur.length; ++k)
|
| 5865 |
{ if (oldCur[k].marker == span.marker) { continue spans } }
|
| 5866 |
+
oldCur.push(span);
|
| 5867 |
}
|
| 5868 |
} else if (stretchCur) {
|
| 5869 |
+
old[i] = stretchCur;
|
| 5870 |
}
|
| 5871 |
}
|
| 5872 |
return old
|
| 5875 |
// Used both to provide a JSON-safe object in .getHistory, and, when
|
| 5876 |
// detaching a document, to split the history in two
|
| 5877 |
function copyHistoryArray(events, newGroup, instantiateSel) {
|
| 5878 |
+
var copy = [];
|
| 5879 |
for (var i = 0; i < events.length; ++i) {
|
| 5880 |
+
var event = events[i];
|
| 5881 |
if (event.ranges) {
|
| 5882 |
+
copy.push(instantiateSel ? Selection.prototype.deepCopy.call(event) : event);
|
| 5883 |
continue
|
| 5884 |
}
|
| 5885 |
+
var changes = event.changes, newChanges = [];
|
| 5886 |
+
copy.push({changes: newChanges});
|
| 5887 |
for (var j = 0; j < changes.length; ++j) {
|
| 5888 |
+
var change = changes[j], m = (void 0);
|
| 5889 |
+
newChanges.push({from: change.from, to: change.to, text: change.text});
|
| 5890 |
if (newGroup) { for (var prop in change) { if (m = prop.match(/^spans_(\d+)$/)) {
|
| 5891 |
if (indexOf(newGroup, Number(m[1])) > -1) {
|
| 5892 |
+
lst(newChanges)[prop] = change[prop];
|
| 5893 |
+
delete change[prop];
|
| 5894 |
}
|
| 5895 |
} } }
|
| 5896 |
}
|
| 5908 |
// Used for cursor motion and such.
|
| 5909 |
function extendRange(doc, range, head, other) {
|
| 5910 |
if (doc.cm && doc.cm.display.shift || doc.extend) {
|
| 5911 |
+
var anchor = range.anchor;
|
| 5912 |
if (other) {
|
| 5913 |
+
var posBefore = cmp(head, anchor) < 0;
|
| 5914 |
if (posBefore != (cmp(other, anchor) < 0)) {
|
| 5915 |
+
anchor = head;
|
| 5916 |
+
head = other;
|
| 5917 |
} else if (posBefore != (cmp(head, other) < 0)) {
|
| 5918 |
+
head = other;
|
| 5919 |
}
|
| 5920 |
}
|
| 5921 |
return new Range(anchor, head)
|
| 5926 |
|
| 5927 |
// Extend the primary selection range, discard the rest.
|
| 5928 |
function extendSelection(doc, head, other, options) {
|
| 5929 |
+
setSelection(doc, new Selection([extendRange(doc, doc.sel.primary(), head, other)], 0), options);
|
| 5930 |
}
|
| 5931 |
|
| 5932 |
// Extend all selections (pos is an array of selections with length
|
| 5933 |
// equal the number of selections)
|
| 5934 |
function extendSelections(doc, heads, options) {
|
| 5935 |
+
var out = [];
|
| 5936 |
for (var i = 0; i < doc.sel.ranges.length; i++)
|
| 5937 |
+
{ out[i] = extendRange(doc, doc.sel.ranges[i], heads[i], null); }
|
| 5938 |
+
var newSel = normalizeSelection(out, doc.sel.primIndex);
|
| 5939 |
+
setSelection(doc, newSel, options);
|
| 5940 |
}
|
| 5941 |
|
| 5942 |
// Updates a single range in the selection.
|
| 5943 |
function replaceOneSelection(doc, i, range, options) {
|
| 5944 |
+
var ranges = doc.sel.ranges.slice(0);
|
| 5945 |
+
ranges[i] = range;
|
| 5946 |
+
setSelection(doc, normalizeSelection(ranges, doc.sel.primIndex), options);
|
| 5947 |
}
|
| 5948 |
|
| 5949 |
// Reset the selection to a single range.
|
| 5950 |
function setSimpleSelection(doc, anchor, head, options) {
|
| 5951 |
+
setSelection(doc, simpleSelection(anchor, head), options);
|
| 5952 |
}
|
| 5953 |
|
| 5954 |
// Give beforeSelectionChange handlers a change to influence a
|
| 5959 |
update: function(ranges) {
|
| 5960 |
var this$1 = this;
|
| 5961 |
|
| 5962 |
+
this.ranges = [];
|
| 5963 |
for (var i = 0; i < ranges.length; i++)
|
| 5964 |
{ this$1.ranges[i] = new Range(clipPos(doc, ranges[i].anchor),
|
| 5965 |
+
clipPos(doc, ranges[i].head)); }
|
| 5966 |
},
|
| 5967 |
origin: options && options.origin
|
| 5968 |
+
};
|
| 5969 |
+
signal(doc, "beforeSelectionChange", doc, obj);
|
| 5970 |
+
if (doc.cm) { signal(doc.cm, "beforeSelectionChange", doc.cm, obj); }
|
| 5971 |
if (obj.ranges != sel.ranges) { return normalizeSelection(obj.ranges, obj.ranges.length - 1) }
|
| 5972 |
else { return sel }
|
| 5973 |
}
|
| 5974 |
|
| 5975 |
function setSelectionReplaceHistory(doc, sel, options) {
|
| 5976 |
+
var done = doc.history.done, last = lst(done);
|
| 5977 |
if (last && last.ranges) {
|
| 5978 |
+
done[done.length - 1] = sel;
|
| 5979 |
+
setSelectionNoUndo(doc, sel, options);
|
| 5980 |
} else {
|
| 5981 |
+
setSelection(doc, sel, options);
|
| 5982 |
}
|
| 5983 |
}
|
| 5984 |
|
| 5985 |
// Set a new selection.
|
| 5986 |
function setSelection(doc, sel, options) {
|
| 5987 |
+
setSelectionNoUndo(doc, sel, options);
|
| 5988 |
+
addSelectionToHistory(doc, doc.sel, doc.cm ? doc.cm.curOp.id : NaN, options);
|
| 5989 |
}
|
| 5990 |
|
| 5991 |
function setSelectionNoUndo(doc, sel, options) {
|
| 5992 |
if (hasHandler(doc, "beforeSelectionChange") || doc.cm && hasHandler(doc.cm, "beforeSelectionChange"))
|
| 5993 |
+
{ sel = filterSelectionChange(doc, sel, options); }
|
| 5994 |
|
| 5995 |
var bias = options && options.bias ||
|
| 5996 |
+
(cmp(sel.primary().head, doc.sel.primary().head) < 0 ? -1 : 1);
|
| 5997 |
+
setSelectionInner(doc, skipAtomicInSelection(doc, sel, bias, true));
|
| 5998 |
|
| 5999 |
if (!(options && options.scroll === false) && doc.cm)
|
| 6000 |
+
{ ensureCursorVisible(doc.cm); }
|
| 6001 |
}
|
| 6002 |
|
| 6003 |
function setSelectionInner(doc, sel) {
|
| 6004 |
if (sel.equals(doc.sel)) { return }
|
| 6005 |
|
| 6006 |
+
doc.sel = sel;
|
| 6007 |
|
| 6008 |
if (doc.cm) {
|
| 6009 |
+
doc.cm.curOp.updateInput = doc.cm.curOp.selectionChanged = true;
|
| 6010 |
+
signalCursorActivity(doc.cm);
|
| 6011 |
}
|
| 6012 |
+
signalLater(doc, "cursorActivity", doc);
|
| 6013 |
}
|
| 6014 |
|
| 6015 |
// Verify that the selection does not partially select any atomic
|
| 6016 |
// marked ranges.
|
| 6017 |
function reCheckSelection(doc) {
|
| 6018 |
+
setSelectionInner(doc, skipAtomicInSelection(doc, doc.sel, null, false), sel_dontScroll);
|
| 6019 |
}
|
| 6020 |
|
| 6021 |
// Return a selection that does not partially select any atomic
|
| 6022 |
// ranges.
|
| 6023 |
function skipAtomicInSelection(doc, sel, bias, mayClear) {
|
| 6024 |
+
var out;
|
| 6025 |
for (var i = 0; i < sel.ranges.length; i++) {
|
| 6026 |
+
var range = sel.ranges[i];
|
| 6027 |
+
var old = sel.ranges.length == doc.sel.ranges.length && doc.sel.ranges[i];
|
| 6028 |
+
var newAnchor = skipAtomic(doc, range.anchor, old && old.anchor, bias, mayClear);
|
| 6029 |
+
var newHead = skipAtomic(doc, range.head, old && old.head, bias, mayClear);
|
| 6030 |
if (out || newAnchor != range.anchor || newHead != range.head) {
|
| 6031 |
+
if (!out) { out = sel.ranges.slice(0, i); }
|
| 6032 |
+
out[i] = new Range(newAnchor, newHead);
|
| 6033 |
}
|
| 6034 |
}
|
| 6035 |
return out ? normalizeSelection(out, sel.primIndex) : sel
|
| 6036 |
}
|
| 6037 |
|
| 6038 |
function skipAtomicInner(doc, pos, oldPos, dir, mayClear) {
|
| 6039 |
+
var line = getLine(doc, pos.line);
|
| 6040 |
if (line.markedSpans) { for (var i = 0; i < line.markedSpans.length; ++i) {
|
| 6041 |
+
var sp = line.markedSpans[i], m = sp.marker;
|
| 6042 |
if ((sp.from == null || (m.inclusiveLeft ? sp.from <= pos.ch : sp.from < pos.ch)) &&
|
| 6043 |
(sp.to == null || (m.inclusiveRight ? sp.to >= pos.ch : sp.to > pos.ch))) {
|
| 6044 |
if (mayClear) {
|
| 6045 |
+
signal(m, "beforeCursorEnter");
|
| 6046 |
if (m.explicitlyCleared) {
|
| 6047 |
if (!line.markedSpans) { break }
|
| 6048 |
else {--i; continue}
|
| 6051 |
if (!m.atomic) { continue }
|
| 6052 |
|
| 6053 |
if (oldPos) {
|
| 6054 |
+
var near = m.find(dir < 0 ? 1 : -1), diff = (void 0);
|
| 6055 |
if (dir < 0 ? m.inclusiveRight : m.inclusiveLeft)
|
| 6056 |
+
{ near = movePos(doc, near, -dir, near && near.line == pos.line ? line : null); }
|
| 6057 |
if (near && near.line == pos.line && (diff = cmp(near, oldPos)) && (dir < 0 ? diff < 0 : diff > 0))
|
| 6058 |
{ return skipAtomicInner(doc, near, pos, dir, mayClear) }
|
| 6059 |
}
|
| 6060 |
|
| 6061 |
+
var far = m.find(dir < 0 ? -1 : 1);
|
| 6062 |
if (dir < 0 ? m.inclusiveLeft : m.inclusiveRight)
|
| 6063 |
+
{ far = movePos(doc, far, dir, far.line == pos.line ? line : null); }
|
| 6064 |
return far ? skipAtomicInner(doc, far, pos, dir, mayClear) : null
|
| 6065 |
}
|
| 6066 |
} }
|
| 6069 |
|
| 6070 |
// Ensure a given position is not inside an atomic range.
|
| 6071 |
function skipAtomic(doc, pos, oldPos, bias, mayClear) {
|
| 6072 |
+
var dir = bias || 1;
|
| 6073 |
var found = skipAtomicInner(doc, pos, oldPos, dir, mayClear) ||
|
| 6074 |
(!mayClear && skipAtomicInner(doc, pos, oldPos, dir, true)) ||
|
| 6075 |
skipAtomicInner(doc, pos, oldPos, -dir, mayClear) ||
|
| 6076 |
+
(!mayClear && skipAtomicInner(doc, pos, oldPos, -dir, true));
|
| 6077 |
if (!found) {
|
| 6078 |
+
doc.cantEdit = true;
|
| 6079 |
return Pos(doc.first, 0)
|
| 6080 |
}
|
| 6081 |
return found
|
| 6094 |
}
|
| 6095 |
|
| 6096 |
function selectAll(cm) {
|
| 6097 |
+
cm.setSelection(Pos(cm.firstLine(), 0), Pos(cm.lastLine()), sel_dontScroll);
|
| 6098 |
}
|
| 6099 |
|
| 6100 |
// UPDATING
|
| 6108 |
text: change.text,
|
| 6109 |
origin: change.origin,
|
| 6110 |
cancel: function () { return obj.canceled = true; }
|
| 6111 |
+
};
|
| 6112 |
if (update) { obj.update = function (from, to, text, origin) {
|
| 6113 |
+
if (from) { obj.from = clipPos(doc, from); }
|
| 6114 |
+
if (to) { obj.to = clipPos(doc, to); }
|
| 6115 |
+
if (text) { obj.text = text; }
|
| 6116 |
+
if (origin !== undefined) { obj.origin = origin; }
|
| 6117 |
+
}; }
|
| 6118 |
+
signal(doc, "beforeChange", doc, obj);
|
| 6119 |
+
if (doc.cm) { signal(doc.cm, "beforeChange", doc.cm, obj); }
|
| 6120 |
|
| 6121 |
if (obj.canceled) { return null }
|
| 6122 |
return {from: obj.from, to: obj.to, text: obj.text, origin: obj.origin}
|
| 6131 |
}
|
| 6132 |
|
| 6133 |
if (hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange")) {
|
| 6134 |
+
change = filterChange(doc, change, true);
|
| 6135 |
if (!change) { return }
|
| 6136 |
}
|
| 6137 |
|
| 6138 |
// Possibly split or suppress the update based on the presence
|
| 6139 |
// of read-only spans in its range.
|
| 6140 |
+
var split = sawReadOnlySpans && !ignoreReadOnly && removeReadOnlyRanges(doc, change.from, change.to);
|
| 6141 |
if (split) {
|
| 6142 |
for (var i = split.length - 1; i >= 0; --i)
|
| 6143 |
+
{ makeChangeInner(doc, {from: split[i].from, to: split[i].to, text: i ? [""] : change.text}); }
|
| 6144 |
} else {
|
| 6145 |
+
makeChangeInner(doc, change);
|
| 6146 |
}
|
| 6147 |
}
|
| 6148 |
|
| 6149 |
function makeChangeInner(doc, change) {
|
| 6150 |
if (change.text.length == 1 && change.text[0] == "" && cmp(change.from, change.to) == 0) { return }
|
| 6151 |
+
var selAfter = computeSelAfterChange(doc, change);
|
| 6152 |
+
addChangeToHistory(doc, change, selAfter, doc.cm ? doc.cm.curOp.id : NaN);
|
| 6153 |
|
| 6154 |
+
makeChangeSingleDoc(doc, change, selAfter, stretchSpansOverChange(doc, change));
|
| 6155 |
+
var rebased = [];
|
| 6156 |
|
| 6157 |
linkedDocs(doc, function (doc, sharedHist) {
|
| 6158 |
if (!sharedHist && indexOf(rebased, doc.history) == -1) {
|
| 6159 |
+
rebaseHist(doc.history, change);
|
| 6160 |
+
rebased.push(doc.history);
|
| 6161 |
}
|
| 6162 |
+
makeChangeSingleDoc(doc, change, null, stretchSpansOverChange(doc, change));
|
| 6163 |
+
});
|
| 6164 |
}
|
| 6165 |
|
| 6166 |
// Revert a change stored in a document's history.
|
| 6167 |
function makeChangeFromHistory(doc, type, allowSelectionOnly) {
|
| 6168 |
if (doc.cm && doc.cm.state.suppressEdits && !allowSelectionOnly) { return }
|
| 6169 |
|
| 6170 |
+
var hist = doc.history, event, selAfter = doc.sel;
|
| 6171 |
+
var source = type == "undo" ? hist.done : hist.undone, dest = type == "undo" ? hist.undone : hist.done;
|
| 6172 |
|
| 6173 |
// Verify that there is a useable event (so that ctrl-z won't
|
| 6174 |
// needlessly clear selection events)
|
| 6175 |
+
var i = 0;
|
| 6176 |
for (; i < source.length; i++) {
|
| 6177 |
+
event = source[i];
|
| 6178 |
if (allowSelectionOnly ? event.ranges && !event.equals(doc.sel) : !event.ranges)
|
| 6179 |
{ break }
|
| 6180 |
}
|
| 6181 |
if (i == source.length) { return }
|
| 6182 |
+
hist.lastOrigin = hist.lastSelOrigin = null;
|
| 6183 |
|
| 6184 |
for (;;) {
|
| 6185 |
+
event = source.pop();
|
| 6186 |
if (event.ranges) {
|
| 6187 |
+
pushSelectionToHistory(event, dest);
|
| 6188 |
if (allowSelectionOnly && !event.equals(doc.sel)) {
|
| 6189 |
+
setSelection(doc, event, {clearRedo: false});
|
| 6190 |
return
|
| 6191 |
}
|
| 6192 |
+
selAfter = event;
|
| 6193 |
}
|
| 6194 |
else { break }
|
| 6195 |
}
|
| 6196 |
|
| 6197 |
// Build up a reverse change object to add to the opposite history
|
| 6198 |
// stack (redo when undoing, and vice versa).
|
| 6199 |
+
var antiChanges = [];
|
| 6200 |
+
pushSelectionToHistory(selAfter, dest);
|
| 6201 |
+
dest.push({changes: antiChanges, generation: hist.generation});
|
| 6202 |
+
hist.generation = event.generation || ++hist.maxGeneration;
|
| 6203 |
|
| 6204 |
+
var filter = hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange");
|
| 6205 |
|
| 6206 |
var loop = function ( i ) {
|
| 6207 |
+
var change = event.changes[i];
|
| 6208 |
+
change.origin = type;
|
| 6209 |
if (filter && !filterChange(doc, change, false)) {
|
| 6210 |
+
source.length = 0;
|
| 6211 |
return {}
|
| 6212 |
}
|
| 6213 |
|
| 6214 |
+
antiChanges.push(historyChangeFromChange(doc, change));
|
| 6215 |
|
| 6216 |
+
var after = i ? computeSelAfterChange(doc, change) : lst(source);
|
| 6217 |
+
makeChangeSingleDoc(doc, change, after, mergeOldSpans(doc, change));
|
| 6218 |
+
if (!i && doc.cm) { doc.cm.scrollIntoView({from: change.from, to: changeEnd(change)}); }
|
| 6219 |
+
var rebased = [];
|
| 6220 |
|
| 6221 |
// Propagate to the linked documents
|
| 6222 |
linkedDocs(doc, function (doc, sharedHist) {
|
| 6223 |
if (!sharedHist && indexOf(rebased, doc.history) == -1) {
|
| 6224 |
+
rebaseHist(doc.history, change);
|
| 6225 |
+
rebased.push(doc.history);
|
| 6226 |
}
|
| 6227 |
+
makeChangeSingleDoc(doc, change, null, mergeOldSpans(doc, change));
|
| 6228 |
+
});
|
| 6229 |
};
|
| 6230 |
|
| 6231 |
for (var i$1 = event.changes.length - 1; i$1 >= 0; --i$1) {
|
| 6239 |
// above or below them in the parent document.
|
| 6240 |
function shiftDoc(doc, distance) {
|
| 6241 |
if (distance == 0) { return }
|
| 6242 |
+
doc.first += distance;
|
| 6243 |
doc.sel = new Selection(map(doc.sel.ranges, function (range) { return new Range(
|
| 6244 |
Pos(range.anchor.line + distance, range.anchor.ch),
|
| 6245 |
Pos(range.head.line + distance, range.head.ch)
|
| 6246 |
+
); }), doc.sel.primIndex);
|
| 6247 |
if (doc.cm) {
|
| 6248 |
+
regChange(doc.cm, doc.first, doc.first - distance, distance);
|
| 6249 |
for (var d = doc.cm.display, l = d.viewFrom; l < d.viewTo; l++)
|
| 6250 |
+
{ regLineChange(doc.cm, l, "gutter"); }
|
| 6251 |
}
|
| 6252 |
}
|
| 6253 |
|
| 6258 |
{ return operation(doc.cm, makeChangeSingleDoc)(doc, change, selAfter, spans) }
|
| 6259 |
|
| 6260 |
if (change.to.line < doc.first) {
|
| 6261 |
+
shiftDoc(doc, change.text.length - 1 - (change.to.line - change.from.line));
|
| 6262 |
return
|
| 6263 |
}
|
| 6264 |
if (change.from.line > doc.lastLine()) { return }
|
| 6265 |
|
| 6266 |
// Clip the change to the size of this doc
|
| 6267 |
if (change.from.line < doc.first) {
|
| 6268 |
+
var shift = change.text.length - 1 - (doc.first - change.from.line);
|
| 6269 |
+
shiftDoc(doc, shift);
|
| 6270 |
change = {from: Pos(doc.first, 0), to: Pos(change.to.line + shift, change.to.ch),
|
| 6271 |
+
text: [lst(change.text)], origin: change.origin};
|
| 6272 |
}
|
| 6273 |
+
var last = doc.lastLine();
|
| 6274 |
if (change.to.line > last) {
|
| 6275 |
change = {from: change.from, to: Pos(last, getLine(doc, last).text.length),
|
| 6276 |
+
text: [change.text[0]], origin: change.origin};
|
| 6277 |
}
|
| 6278 |
|
| 6279 |
+
change.removed = getBetween(doc, change.from, change.to);
|
| 6280 |
|
| 6281 |
+
if (!selAfter) { selAfter = computeSelAfterChange(doc, change); }
|
| 6282 |
+
if (doc.cm) { makeChangeSingleDocInEditor(doc.cm, change, spans); }
|
| 6283 |
+
else { updateDoc(doc, change, spans); }
|
| 6284 |
+
setSelectionNoUndo(doc, selAfter, sel_dontScroll);
|
| 6285 |
}
|
| 6286 |
|
| 6287 |
// Handle the interaction of a change to a document with the editor
|
| 6288 |
// that this document is part of.
|
| 6289 |
function makeChangeSingleDocInEditor(cm, change, spans) {
|
| 6290 |
+
var doc = cm.doc, display = cm.display, from = change.from, to = change.to;
|
| 6291 |
|
| 6292 |
+
var recomputeMaxLength = false, checkWidthStart = from.line;
|
| 6293 |
if (!cm.options.lineWrapping) {
|
| 6294 |
+
checkWidthStart = lineNo(visualLine(getLine(doc, from.line)));
|
| 6295 |
doc.iter(checkWidthStart, to.line + 1, function (line) {
|
| 6296 |
if (line == display.maxLine) {
|
| 6297 |
+
recomputeMaxLength = true;
|
| 6298 |
return true
|
| 6299 |
}
|
| 6300 |
+
});
|
| 6301 |
}
|
| 6302 |
|
| 6303 |
if (doc.sel.contains(change.from, change.to) > -1)
|
| 6304 |
+
{ signalCursorActivity(cm); }
|
| 6305 |
|
| 6306 |
+
updateDoc(doc, change, spans, estimateHeight(cm));
|
| 6307 |
|
| 6308 |
if (!cm.options.lineWrapping) {
|
| 6309 |
doc.iter(checkWidthStart, from.line + change.text.length, function (line) {
|
| 6310 |
+
var len = lineLength(line);
|
| 6311 |
if (len > display.maxLineLength) {
|
| 6312 |
+
display.maxLine = line;
|
| 6313 |
+
display.maxLineLength = len;
|
| 6314 |
+
display.maxLineChanged = true;
|
| 6315 |
+
recomputeMaxLength = false;
|
| 6316 |
}
|
| 6317 |
+
});
|
| 6318 |
+
if (recomputeMaxLength) { cm.curOp.updateMaxLine = true; }
|
| 6319 |
}
|
| 6320 |
|
| 6321 |
// Adjust frontier, schedule worker
|
| 6322 |
+
doc.frontier = Math.min(doc.frontier, from.line);
|
| 6323 |
+
startWorker(cm, 400);
|
| 6324 |
|
| 6325 |
+
var lendiff = change.text.length - (to.line - from.line) - 1;
|
| 6326 |
// Remember that these lines changed, for updating the display
|
| 6327 |
if (change.full)
|
| 6328 |
+
{ regChange(cm); }
|
| 6329 |
else if (from.line == to.line && change.text.length == 1 && !isWholeLineUpdate(cm.doc, change))
|
| 6330 |
+
{ regLineChange(cm, from.line, "text"); }
|
| 6331 |
else
|
| 6332 |
+
{ regChange(cm, from.line, to.line + 1, lendiff); }
|
| 6333 |
|
| 6334 |
+
var changesHandler = hasHandler(cm, "changes"), changeHandler = hasHandler(cm, "change");
|
| 6335 |
if (changeHandler || changesHandler) {
|
| 6336 |
var obj = {
|
| 6337 |
from: from, to: to,
|
| 6338 |
text: change.text,
|
| 6339 |
removed: change.removed,
|
| 6340 |
origin: change.origin
|
| 6341 |
+
};
|
| 6342 |
+
if (changeHandler) { signalLater(cm, "change", cm, obj); }
|
| 6343 |
+
if (changesHandler) { (cm.curOp.changeObjs || (cm.curOp.changeObjs = [])).push(obj); }
|
| 6344 |
}
|
| 6345 |
+
cm.display.selForContextMenu = null;
|
| 6346 |
}
|
| 6347 |
|
| 6348 |
function replaceRange(doc, code, from, to, origin) {
|
| 6349 |
+
if (!to) { to = from; }
|
| 6350 |
+
if (cmp(to, from) < 0) { var tmp = to; to = from; from = tmp; }
|
| 6351 |
+
if (typeof code == "string") { code = doc.splitLines(code); }
|
| 6352 |
+
makeChange(doc, {from: from, to: to, text: code, origin: origin});
|
| 6353 |
}
|
| 6354 |
|
| 6355 |
// Rebasing/resetting history to deal with externally-sourced changes
|
| 6356 |
|
| 6357 |
function rebaseHistSelSingle(pos, from, to, diff) {
|
| 6358 |
if (to < pos.line) {
|
| 6359 |
+
pos.line += diff;
|
| 6360 |
} else if (from < pos.line) {
|
| 6361 |
+
pos.line = from;
|
| 6362 |
+
pos.ch = 0;
|
| 6363 |
}
|
| 6364 |
}
|
| 6365 |
|
| 6372 |
// shared position objects being unsafely updated.
|
| 6373 |
function rebaseHistArray(array, from, to, diff) {
|
| 6374 |
for (var i = 0; i < array.length; ++i) {
|
| 6375 |
+
var sub = array[i], ok = true;
|
| 6376 |
if (sub.ranges) {
|
| 6377 |
+
if (!sub.copied) { sub = array[i] = sub.deepCopy(); sub.copied = true; }
|
| 6378 |
for (var j = 0; j < sub.ranges.length; j++) {
|
| 6379 |
+
rebaseHistSelSingle(sub.ranges[j].anchor, from, to, diff);
|
| 6380 |
+
rebaseHistSelSingle(sub.ranges[j].head, from, to, diff);
|
| 6381 |
}
|
| 6382 |
continue
|
| 6383 |
}
|
| 6384 |
for (var j$1 = 0; j$1 < sub.changes.length; ++j$1) {
|
| 6385 |
+
var cur = sub.changes[j$1];
|
| 6386 |
if (to < cur.from.line) {
|
| 6387 |
+
cur.from = Pos(cur.from.line + diff, cur.from.ch);
|
| 6388 |
+
cur.to = Pos(cur.to.line + diff, cur.to.ch);
|
| 6389 |
} else if (from <= cur.to.line) {
|
| 6390 |
+
ok = false;
|
| 6391 |
break
|
| 6392 |
}
|
| 6393 |
}
|
| 6394 |
if (!ok) {
|
| 6395 |
+
array.splice(0, i + 1);
|
| 6396 |
+
i = 0;
|
| 6397 |
}
|
| 6398 |
}
|
| 6399 |
}
|
| 6400 |
|
| 6401 |
function rebaseHist(hist, change) {
|
| 6402 |
+
var from = change.from.line, to = change.to.line, diff = change.text.length - (to - from) - 1;
|
| 6403 |
+
rebaseHistArray(hist.done, from, to, diff);
|
| 6404 |
+
rebaseHistArray(hist.undone, from, to, diff);
|
| 6405 |
}
|
| 6406 |
|
| 6407 |
// Utility for applying a change to a line by handle or number,
|
| 6408 |
// returning the number and optionally registering the line as
|
| 6409 |
// changed.
|
| 6410 |
function changeLine(doc, handle, changeType, op) {
|
| 6411 |
+
var no = handle, line = handle;
|
| 6412 |
+
if (typeof handle == "number") { line = getLine(doc, clipLine(doc, handle)); }
|
| 6413 |
+
else { no = lineNo(handle); }
|
| 6414 |
if (no == null) { return null }
|
| 6415 |
+
if (op(line, no) && doc.cm) { regLineChange(doc.cm, no, changeType); }
|
| 6416 |
return line
|
| 6417 |
}
|
| 6418 |
|
| 6432 |
var LeafChunk = function(lines) {
|
| 6433 |
var this$1 = this;
|
| 6434 |
|
| 6435 |
+
this.lines = lines;
|
| 6436 |
+
this.parent = null;
|
| 6437 |
+
var height = 0;
|
| 6438 |
for (var i = 0; i < lines.length; ++i) {
|
| 6439 |
+
lines[i].parent = this$1;
|
| 6440 |
+
height += lines[i].height;
|
| 6441 |
}
|
| 6442 |
+
this.height = height;
|
| 6443 |
};
|
| 6444 |
|
| 6445 |
LeafChunk.prototype.chunkSize = function () { return this.lines.length };
|
| 6449 |
var this$1 = this;
|
| 6450 |
|
| 6451 |
for (var i = at, e = at + n; i < e; ++i) {
|
| 6452 |
+
var line = this$1.lines[i];
|
| 6453 |
+
this$1.height -= line.height;
|
| 6454 |
+
cleanUpLine(line);
|
| 6455 |
+
signalLater(line, "delete");
|
| 6456 |
}
|
| 6457 |
+
this.lines.splice(at, n);
|
| 6458 |
};
|
| 6459 |
|
| 6460 |
// Helper used to collapse a small branch into a single leaf.
|
| 6461 |
LeafChunk.prototype.collapse = function (lines) {
|
| 6462 |
+
lines.push.apply(lines, this.lines);
|
| 6463 |
};
|
| 6464 |
|
| 6465 |
// Insert the given array of lines at offset 'at', count them as
|
| 6467 |
LeafChunk.prototype.insertInner = function (at, lines, height) {
|
| 6468 |
var this$1 = this;
|
| 6469 |
|
| 6470 |
+
this.height += height;
|
| 6471 |
+
this.lines = this.lines.slice(0, at).concat(lines).concat(this.lines.slice(at));
|
| 6472 |
+
for (var i = 0; i < lines.length; ++i) { lines[i].parent = this$1; }
|
| 6473 |
};
|
| 6474 |
|
| 6475 |
// Used to iterate over a part of the tree.
|
| 6483 |
var BranchChunk = function(children) {
|
| 6484 |
var this$1 = this;
|
| 6485 |
|
| 6486 |
+
this.children = children;
|
| 6487 |
+
var size = 0, height = 0;
|
| 6488 |
for (var i = 0; i < children.length; ++i) {
|
| 6489 |
+
var ch = children[i];
|
| 6490 |
+
size += ch.chunkSize(); height += ch.height;
|
| 6491 |
+
ch.parent = this$1;
|
| 6492 |
}
|
| 6493 |
+
this.size = size;
|
| 6494 |
+
this.height = height;
|
| 6495 |
+
this.parent = null;
|
| 6496 |
};
|
| 6497 |
|
| 6498 |
BranchChunk.prototype.chunkSize = function () { return this.size };
|
| 6500 |
BranchChunk.prototype.removeInner = function (at, n) {
|
| 6501 |
var this$1 = this;
|
| 6502 |
|
| 6503 |
+
this.size -= n;
|
| 6504 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6505 |
+
var child = this$1.children[i], sz = child.chunkSize();
|
| 6506 |
if (at < sz) {
|
| 6507 |
+
var rm = Math.min(n, sz - at), oldHeight = child.height;
|
| 6508 |
+
child.removeInner(at, rm);
|
| 6509 |
+
this$1.height -= oldHeight - child.height;
|
| 6510 |
+
if (sz == rm) { this$1.children.splice(i--, 1); child.parent = null; }
|
| 6511 |
if ((n -= rm) == 0) { break }
|
| 6512 |
+
at = 0;
|
| 6513 |
+
} else { at -= sz; }
|
| 6514 |
}
|
| 6515 |
// If the result is smaller than 25 lines, ensure that it is a
|
| 6516 |
// single leaf node.
|
| 6517 |
if (this.size - n < 25 &&
|
| 6518 |
(this.children.length > 1 || !(this.children[0] instanceof LeafChunk))) {
|
| 6519 |
+
var lines = [];
|
| 6520 |
+
this.collapse(lines);
|
| 6521 |
+
this.children = [new LeafChunk(lines)];
|
| 6522 |
+
this.children[0].parent = this;
|
| 6523 |
}
|
| 6524 |
};
|
| 6525 |
|
| 6526 |
BranchChunk.prototype.collapse = function (lines) {
|
| 6527 |
var this$1 = this;
|
| 6528 |
|
| 6529 |
+
for (var i = 0; i < this.children.length; ++i) { this$1.children[i].collapse(lines); }
|
| 6530 |
};
|
| 6531 |
|
| 6532 |
BranchChunk.prototype.insertInner = function (at, lines, height) {
|
| 6533 |
var this$1 = this;
|
| 6534 |
|
| 6535 |
+
this.size += lines.length;
|
| 6536 |
+
this.height += height;
|
| 6537 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6538 |
+
var child = this$1.children[i], sz = child.chunkSize();
|
| 6539 |
if (at <= sz) {
|
| 6540 |
+
child.insertInner(at, lines, height);
|
| 6541 |
if (child.lines && child.lines.length > 50) {
|
| 6542 |
// To avoid memory thrashing when child.lines is huge (e.g. first view of a large file), it's never spliced.
|
| 6543 |
// Instead, small slices are taken. They're taken in order because sequential memory accesses are fastest.
|
| 6544 |
+
var remaining = child.lines.length % 25 + 25;
|
| 6545 |
for (var pos = remaining; pos < child.lines.length;) {
|
| 6546 |
+
var leaf = new LeafChunk(child.lines.slice(pos, pos += 25));
|
| 6547 |
+
child.height -= leaf.height;
|
| 6548 |
+
this$1.children.splice(++i, 0, leaf);
|
| 6549 |
+
leaf.parent = this$1;
|
| 6550 |
}
|
| 6551 |
+
child.lines = child.lines.slice(0, remaining);
|
| 6552 |
+
this$1.maybeSpill();
|
| 6553 |
}
|
| 6554 |
break
|
| 6555 |
}
|
| 6556 |
+
at -= sz;
|
| 6557 |
}
|
| 6558 |
};
|
| 6559 |
|
| 6560 |
// When a node has grown, check whether it should be split.
|
| 6561 |
BranchChunk.prototype.maybeSpill = function () {
|
| 6562 |
if (this.children.length <= 10) { return }
|
| 6563 |
+
var me = this;
|
| 6564 |
do {
|
| 6565 |
+
var spilled = me.children.splice(me.children.length - 5, 5);
|
| 6566 |
+
var sibling = new BranchChunk(spilled);
|
| 6567 |
if (!me.parent) { // Become the parent node
|
| 6568 |
+
var copy = new BranchChunk(me.children);
|
| 6569 |
+
copy.parent = me;
|
| 6570 |
+
me.children = [copy, sibling];
|
| 6571 |
+
me = copy;
|
| 6572 |
} else {
|
| 6573 |
+
me.size -= sibling.size;
|
| 6574 |
+
me.height -= sibling.height;
|
| 6575 |
+
var myIndex = indexOf(me.parent.children, me);
|
| 6576 |
+
me.parent.children.splice(myIndex + 1, 0, sibling);
|
| 6577 |
}
|
| 6578 |
+
sibling.parent = me.parent;
|
| 6579 |
} while (me.children.length > 10)
|
| 6580 |
+
me.parent.maybeSpill();
|
| 6581 |
};
|
| 6582 |
|
| 6583 |
BranchChunk.prototype.iterN = function (at, n, op) {
|
| 6584 |
var this$1 = this;
|
| 6585 |
|
| 6586 |
for (var i = 0; i < this.children.length; ++i) {
|
| 6587 |
+
var child = this$1.children[i], sz = child.chunkSize();
|
| 6588 |
if (at < sz) {
|
| 6589 |
+
var used = Math.min(n, sz - at);
|
| 6590 |
if (child.iterN(at, used, op)) { return true }
|
| 6591 |
if ((n -= used) == 0) { break }
|
| 6592 |
+
at = 0;
|
| 6593 |
+
} else { at -= sz; }
|
| 6594 |
}
|
| 6595 |
};
|
| 6596 |
|
| 6600 |
var this$1 = this;
|
| 6601 |
|
| 6602 |
if (options) { for (var opt in options) { if (options.hasOwnProperty(opt))
|
| 6603 |
+
{ this$1[opt] = options[opt]; } } }
|
| 6604 |
+
this.doc = doc;
|
| 6605 |
+
this.node = node;
|
| 6606 |
};
|
| 6607 |
|
| 6608 |
LineWidget.prototype.clear = function () {
|
| 6609 |
var this$1 = this;
|
| 6610 |
|
| 6611 |
+
var cm = this.doc.cm, ws = this.line.widgets, line = this.line, no = lineNo(line);
|
| 6612 |
if (no == null || !ws) { return }
|
| 6613 |
+
for (var i = 0; i < ws.length; ++i) { if (ws[i] == this$1) { ws.splice(i--, 1); } }
|
| 6614 |
+
if (!ws.length) { line.widgets = null; }
|
| 6615 |
+
var height = widgetHeight(this);
|
| 6616 |
+
updateLineHeight(line, Math.max(0, line.height - height));
|
| 6617 |
if (cm) {
|
| 6618 |
runInOp(cm, function () {
|
| 6619 |
+
adjustScrollWhenAboveVisible(cm, line, -height);
|
| 6620 |
+
regLineChange(cm, no, "widget");
|
| 6621 |
+
});
|
| 6622 |
+
signalLater(cm, "lineWidgetCleared", cm, this, no);
|
| 6623 |
}
|
| 6624 |
};
|
| 6625 |
|
| 6626 |
LineWidget.prototype.changed = function () {
|
| 6627 |
var this$1 = this;
|
| 6628 |
|
| 6629 |
+
var oldH = this.height, cm = this.doc.cm, line = this.line;
|
| 6630 |
+
this.height = null;
|
| 6631 |
+
var diff = widgetHeight(this) - oldH;
|
| 6632 |
if (!diff) { return }
|
| 6633 |
+
updateLineHeight(line, line.height + diff);
|
| 6634 |
if (cm) {
|
| 6635 |
runInOp(cm, function () {
|
| 6636 |
+
cm.curOp.forceUpdate = true;
|
| 6637 |
+
adjustScrollWhenAboveVisible(cm, line, diff);
|
| 6638 |
+
signalLater(cm, "lineWidgetChanged", cm, this$1, lineNo(line));
|
| 6639 |
+
});
|
| 6640 |
}
|
| 6641 |
};
|
| 6642 |
+
eventMixin(LineWidget);
|
| 6643 |
|
| 6644 |
function adjustScrollWhenAboveVisible(cm, line, diff) {
|
| 6645 |
if (heightAtLine(line) < ((cm.curOp && cm.curOp.scrollTop) || cm.doc.scrollTop))
|
| 6646 |
+
{ addToScrollPos(cm, null, diff); }
|
| 6647 |
}
|
| 6648 |
|
| 6649 |
function addLineWidget(doc, handle, node, options) {
|
| 6650 |
+
var widget = new LineWidget(doc, node, options);
|
| 6651 |
+
var cm = doc.cm;
|
| 6652 |
+
if (cm && widget.noHScroll) { cm.display.alignWidgets = true; }
|
| 6653 |
changeLine(doc, handle, "widget", function (line) {
|
| 6654 |
+
var widgets = line.widgets || (line.widgets = []);
|
| 6655 |
+
if (widget.insertAt == null) { widgets.push(widget); }
|
| 6656 |
+
else { widgets.splice(Math.min(widgets.length - 1, Math.max(0, widget.insertAt)), 0, widget); }
|
| 6657 |
+
widget.line = line;
|
| 6658 |
if (cm && !lineIsHidden(doc, line)) {
|
| 6659 |
+
var aboveVisible = heightAtLine(line) < doc.scrollTop;
|
| 6660 |
+
updateLineHeight(line, line.height + widgetHeight(widget));
|
| 6661 |
+
if (aboveVisible) { addToScrollPos(cm, null, widget.height); }
|
| 6662 |
+
cm.curOp.forceUpdate = true;
|
| 6663 |
}
|
| 6664 |
return true
|
| 6665 |
+
});
|
| 6666 |
+
signalLater(cm, "lineWidgetAdded", cm, widget, typeof handle == "number" ? handle : lineNo(handle));
|
| 6667 |
return widget
|
| 6668 |
}
|
| 6669 |
|
| 6682 |
// Collapsed markers have unique ids, in order to be able to order
|
| 6683 |
// them, which is needed for uniquely determining an outer marker
|
| 6684 |
// when they overlap (they may nest, but not partially overlap).
|
| 6685 |
+
var nextMarkerId = 0;
|
| 6686 |
|
| 6687 |
var TextMarker = function(doc, type) {
|
| 6688 |
+
this.lines = [];
|
| 6689 |
+
this.type = type;
|
| 6690 |
+
this.doc = doc;
|
| 6691 |
+
this.id = ++nextMarkerId;
|
| 6692 |
};
|
| 6693 |
|
| 6694 |
// Clear the marker.
|
| 6696 |
var this$1 = this;
|
| 6697 |
|
| 6698 |
if (this.explicitlyCleared) { return }
|
| 6699 |
+
var cm = this.doc.cm, withOp = cm && !cm.curOp;
|
| 6700 |
+
if (withOp) { startOperation(cm); }
|
| 6701 |
if (hasHandler(this, "clear")) {
|
| 6702 |
+
var found = this.find();
|
| 6703 |
+
if (found) { signalLater(this, "clear", found.from, found.to); }
|
| 6704 |
}
|
| 6705 |
+
var min = null, max = null;
|
| 6706 |
for (var i = 0; i < this.lines.length; ++i) {
|
| 6707 |
+
var line = this$1.lines[i];
|
| 6708 |
+
var span = getMarkedSpanFor(line.markedSpans, this$1);
|
| 6709 |
+
if (cm && !this$1.collapsed) { regLineChange(cm, lineNo(line), "text"); }
|
| 6710 |
else if (cm) {
|
| 6711 |
+
if (span.to != null) { max = lineNo(line); }
|
| 6712 |
+
if (span.from != null) { min = lineNo(line); }
|
| 6713 |
}
|
| 6714 |
+
line.markedSpans = removeMarkedSpan(line.markedSpans, span);
|
| 6715 |
if (span.from == null && this$1.collapsed && !lineIsHidden(this$1.doc, line) && cm)
|
| 6716 |
+
{ updateLineHeight(line, textHeight(cm.display)); }
|
| 6717 |
}
|
| 6718 |
if (cm && this.collapsed && !cm.options.lineWrapping) { for (var i$1 = 0; i$1 < this.lines.length; ++i$1) {
|
| 6719 |
+
var visual = visualLine(this$1.lines[i$1]), len = lineLength(visual);
|
| 6720 |
if (len > cm.display.maxLineLength) {
|
| 6721 |
+
cm.display.maxLine = visual;
|
| 6722 |
+
cm.display.maxLineLength = len;
|
| 6723 |
+
cm.display.maxLineChanged = true;
|
| 6724 |
}
|
| 6725 |
} }
|
| 6726 |
|
| 6727 |
+
if (min != null && cm && this.collapsed) { regChange(cm, min, max + 1); }
|
| 6728 |
+
this.lines.length = 0;
|
| 6729 |
+
this.explicitlyCleared = true;
|
| 6730 |
if (this.atomic && this.doc.cantEdit) {
|
| 6731 |
+
this.doc.cantEdit = false;
|
| 6732 |
+
if (cm) { reCheckSelection(cm.doc); }
|
| 6733 |
}
|
| 6734 |
+
if (cm) { signalLater(cm, "markerCleared", cm, this, min, max); }
|
| 6735 |
+
if (withOp) { endOperation(cm); }
|
| 6736 |
+
if (this.parent) { this.parent.clear(); }
|
| 6737 |
};
|
| 6738 |
|
| 6739 |
// Find the position of the marker in the document. Returns a {from,
|
| 6744 |
TextMarker.prototype.find = function (side, lineObj) {
|
| 6745 |
var this$1 = this;
|
| 6746 |
|
| 6747 |
+
if (side == null && this.type == "bookmark") { side = 1; }
|
| 6748 |
+
var from, to;
|
| 6749 |
for (var i = 0; i < this.lines.length; ++i) {
|
| 6750 |
+
var line = this$1.lines[i];
|
| 6751 |
+
var span = getMarkedSpanFor(line.markedSpans, this$1);
|
| 6752 |
if (span.from != null) {
|
| 6753 |
+
from = Pos(lineObj ? line : lineNo(line), span.from);
|
| 6754 |
if (side == -1) { return from }
|
| 6755 |
}
|
| 6756 |
if (span.to != null) {
|
| 6757 |
+
to = Pos(lineObj ? line : lineNo(line), span.to);
|
| 6758 |
if (side == 1) { return to }
|
| 6759 |
}
|
| 6760 |
}
|
| 6766 |
TextMarker.prototype.changed = function () {
|
| 6767 |
var this$1 = this;
|
| 6768 |
|
| 6769 |
+
var pos = this.find(-1, true), widget = this, cm = this.doc.cm;
|
| 6770 |
if (!pos || !cm) { return }
|
| 6771 |
runInOp(cm, function () {
|
| 6772 |
+
var line = pos.line, lineN = lineNo(pos.line);
|
| 6773 |
+
var view = findViewForLine(cm, lineN);
|
| 6774 |
if (view) {
|
| 6775 |
+
clearLineMeasurementCacheFor(view);
|
| 6776 |
+
cm.curOp.selectionChanged = cm.curOp.forceUpdate = true;
|
| 6777 |
}
|
| 6778 |
+
cm.curOp.updateMaxLine = true;
|
| 6779 |
if (!lineIsHidden(widget.doc, line) && widget.height != null) {
|
| 6780 |
+
var oldHeight = widget.height;
|
| 6781 |
+
widget.height = null;
|
| 6782 |
+
var dHeight = widgetHeight(widget) - oldHeight;
|
| 6783 |
if (dHeight)
|
| 6784 |
+
{ updateLineHeight(line, line.height + dHeight); }
|
| 6785 |
}
|
| 6786 |
+
signalLater(cm, "markerChanged", cm, this$1);
|
| 6787 |
+
});
|
| 6788 |
};
|
| 6789 |
|
| 6790 |
TextMarker.prototype.attachLine = function (line) {
|
| 6791 |
if (!this.lines.length && this.doc.cm) {
|
| 6792 |
+
var op = this.doc.cm.curOp;
|
| 6793 |
if (!op.maybeHiddenMarkers || indexOf(op.maybeHiddenMarkers, this) == -1)
|
| 6794 |
+
{ (op.maybeUnhiddenMarkers || (op.maybeUnhiddenMarkers = [])).push(this); }
|
| 6795 |
}
|
| 6796 |
+
this.lines.push(line);
|
| 6797 |
};
|
| 6798 |
|
| 6799 |
TextMarker.prototype.detachLine = function (line) {
|
| 6800 |
+
this.lines.splice(indexOf(this.lines, line), 1);
|
| 6801 |
if (!this.lines.length && this.doc.cm) {
|
| 6802 |
+
var op = this.doc.cm.curOp;(op.maybeHiddenMarkers || (op.maybeHiddenMarkers = [])).push(this);
|
|
|
|
| 6803 |
}
|
| 6804 |
};
|
| 6805 |
+
eventMixin(TextMarker);
|
| 6806 |
|
| 6807 |
// Create a marker, wire it up to the right lines, and
|
| 6808 |
function markText(doc, from, to, options, type) {
|
| 6813 |
// Ensure we are in an operation.
|
| 6814 |
if (doc.cm && !doc.cm.curOp) { return operation(doc.cm, markText)(doc, from, to, options, type) }
|
| 6815 |
|
| 6816 |
+
var marker = new TextMarker(doc, type), diff = cmp(from, to);
|
| 6817 |
+
if (options) { copyObj(options, marker, false); }
|
| 6818 |
// Don't connect empty markers unless clearWhenEmpty is false
|
| 6819 |
if (diff > 0 || diff == 0 && marker.clearWhenEmpty !== false)
|
| 6820 |
{ return marker }
|
| 6821 |
if (marker.replacedWith) {
|
| 6822 |
// Showing up as a widget implies collapsed (widget replaces text)
|
| 6823 |
+
marker.collapsed = true;
|
| 6824 |
+
marker.widgetNode = eltP("span", [marker.replacedWith], "CodeMirror-widget");
|
| 6825 |
+
if (!options.handleMouseEvents) { marker.widgetNode.setAttribute("cm-ignore-events", "true"); }
|
| 6826 |
+
if (options.insertLeft) { marker.widgetNode.insertLeft = true; }
|
|
|
|
| 6827 |
}
|
| 6828 |
if (marker.collapsed) {
|
| 6829 |
if (conflictingCollapsedRange(doc, from.line, from, to, marker) ||
|
| 6830 |
from.line != to.line && conflictingCollapsedRange(doc, to.line, from, to, marker))
|
| 6831 |
{ throw new Error("Inserting collapsed marker partially overlapping an existing one") }
|
| 6832 |
+
seeCollapsedSpans();
|
| 6833 |
}
|
| 6834 |
|
| 6835 |
if (marker.addToHistory)
|
| 6836 |
+
{ addChangeToHistory(doc, {from: from, to: to, origin: "markText"}, doc.sel, NaN); }
|
| 6837 |
|
| 6838 |
+
var curLine = from.line, cm = doc.cm, updateMaxLine;
|
| 6839 |
doc.iter(curLine, to.line + 1, function (line) {
|
| 6840 |
if (cm && marker.collapsed && !cm.options.lineWrapping && visualLine(line) == cm.display.maxLine)
|
| 6841 |
+
{ updateMaxLine = true; }
|
| 6842 |
+
if (marker.collapsed && curLine != from.line) { updateLineHeight(line, 0); }
|
| 6843 |
addMarkedSpan(line, new MarkedSpan(marker,
|
| 6844 |
curLine == from.line ? from.ch : null,
|
| 6845 |
+
curLine == to.line ? to.ch : null));
|
| 6846 |
+
++curLine;
|
| 6847 |
+
});
|
| 6848 |
// lineIsHidden depends on the presence of the spans, so needs a second pass
|
| 6849 |
if (marker.collapsed) { doc.iter(from.line, to.line + 1, function (line) {
|
| 6850 |
+
if (lineIsHidden(doc, line)) { updateLineHeight(line, 0); }
|
| 6851 |
+
}); }
|
| 6852 |
|
| 6853 |
+
if (marker.clearOnEnter) { on(marker, "beforeCursorEnter", function () { return marker.clear(); }); }
|
| 6854 |
|
| 6855 |
if (marker.readOnly) {
|
| 6856 |
+
seeReadOnlySpans();
|
| 6857 |
if (doc.history.done.length || doc.history.undone.length)
|
| 6858 |
+
{ doc.clearHistory(); }
|
| 6859 |
}
|
| 6860 |
if (marker.collapsed) {
|
| 6861 |
+
marker.id = ++nextMarkerId;
|
| 6862 |
+
marker.atomic = true;
|
| 6863 |
}
|
| 6864 |
if (cm) {
|
| 6865 |
// Sync editor state
|
| 6866 |
+
if (updateMaxLine) { cm.curOp.updateMaxLine = true; }
|
| 6867 |
if (marker.collapsed)
|
| 6868 |
+
{ regChange(cm, from.line, to.line + 1); }
|
| 6869 |
else if (marker.className || marker.title || marker.startStyle || marker.endStyle || marker.css)
|
| 6870 |
+
{ for (var i = from.line; i <= to.line; i++) { regLineChange(cm, i, "text"); } }
|
| 6871 |
+
if (marker.atomic) { reCheckSelection(cm.doc); }
|
| 6872 |
+
signalLater(cm, "markerAdded", cm, marker);
|
| 6873 |
}
|
| 6874 |
return marker
|
| 6875 |
}
|
| 6882 |
var SharedTextMarker = function(markers, primary) {
|
| 6883 |
var this$1 = this;
|
| 6884 |
|
| 6885 |
+
this.markers = markers;
|
| 6886 |
+
this.primary = primary;
|
| 6887 |
for (var i = 0; i < markers.length; ++i)
|
| 6888 |
+
{ markers[i].parent = this$1; }
|
| 6889 |
};
|
| 6890 |
|
| 6891 |
SharedTextMarker.prototype.clear = function () {
|
| 6892 |
var this$1 = this;
|
| 6893 |
|
| 6894 |
if (this.explicitlyCleared) { return }
|
| 6895 |
+
this.explicitlyCleared = true;
|
| 6896 |
for (var i = 0; i < this.markers.length; ++i)
|
| 6897 |
+
{ this$1.markers[i].clear(); }
|
| 6898 |
+
signalLater(this, "clear");
|
| 6899 |
};
|
| 6900 |
|
| 6901 |
SharedTextMarker.prototype.find = function (side, lineObj) {
|
| 6902 |
return this.primary.find(side, lineObj)
|
| 6903 |
};
|
| 6904 |
+
eventMixin(SharedTextMarker);
|
| 6905 |
|
| 6906 |
function markTextShared(doc, from, to, options, type) {
|
| 6907 |
+
options = copyObj(options);
|
| 6908 |
+
options.shared = false;
|
| 6909 |
+
var markers = [markText(doc, from, to, options, type)], primary = markers[0];
|
| 6910 |
+
var widget = options.widgetNode;
|
| 6911 |
linkedDocs(doc, function (doc) {
|
| 6912 |
+
if (widget) { options.widgetNode = widget.cloneNode(true); }
|
| 6913 |
+
markers.push(markText(doc, clipPos(doc, from), clipPos(doc, to), options, type));
|
| 6914 |
for (var i = 0; i < doc.linked.length; ++i)
|
| 6915 |
{ if (doc.linked[i].isParent) { return } }
|
| 6916 |
+
primary = lst(markers);
|
| 6917 |
+
});
|
| 6918 |
return new SharedTextMarker(markers, primary)
|
| 6919 |
}
|
| 6920 |
|
| 6924 |
|
| 6925 |
function copySharedMarkers(doc, markers) {
|
| 6926 |
for (var i = 0; i < markers.length; i++) {
|
| 6927 |
+
var marker = markers[i], pos = marker.find();
|
| 6928 |
+
var mFrom = doc.clipPos(pos.from), mTo = doc.clipPos(pos.to);
|
| 6929 |
if (cmp(mFrom, mTo)) {
|
| 6930 |
+
var subMark = markText(doc, mFrom, mTo, marker.primary, marker.primary.type);
|
| 6931 |
+
marker.markers.push(subMark);
|
| 6932 |
+
subMark.parent = marker;
|
| 6933 |
}
|
| 6934 |
}
|
| 6935 |
}
|
| 6936 |
|
| 6937 |
function detachSharedMarkers(markers) {
|
| 6938 |
var loop = function ( i ) {
|
| 6939 |
+
var marker = markers[i], linked = [marker.primary.doc];
|
| 6940 |
+
linkedDocs(marker.primary.doc, function (d) { return linked.push(d); });
|
| 6941 |
for (var j = 0; j < marker.markers.length; j++) {
|
| 6942 |
+
var subMarker = marker.markers[j];
|
| 6943 |
if (indexOf(linked, subMarker.doc) == -1) {
|
| 6944 |
+
subMarker.parent = null;
|
| 6945 |
+
marker.markers.splice(j--, 1);
|
| 6946 |
}
|
| 6947 |
}
|
| 6948 |
};
|
| 6950 |
for (var i = 0; i < markers.length; i++) loop( i );
|
| 6951 |
}
|
| 6952 |
|
| 6953 |
+
var nextDocId = 0;
|
| 6954 |
+
var Doc = function(text, mode, firstLine, lineSep, direction) {
|
| 6955 |
+
if (!(this instanceof Doc)) { return new Doc(text, mode, firstLine, lineSep, direction) }
|
| 6956 |
+
if (firstLine == null) { firstLine = 0; }
|
| 6957 |
+
|
| 6958 |
+
BranchChunk.call(this, [new LeafChunk([new Line("", null)])]);
|
| 6959 |
+
this.first = firstLine;
|
| 6960 |
+
this.scrollTop = this.scrollLeft = 0;
|
| 6961 |
+
this.cantEdit = false;
|
| 6962 |
+
this.cleanGeneration = 1;
|
| 6963 |
+
this.frontier = firstLine;
|
| 6964 |
+
var start = Pos(firstLine, 0);
|
| 6965 |
+
this.sel = simpleSelection(start);
|
| 6966 |
+
this.history = new History(null);
|
| 6967 |
+
this.id = ++nextDocId;
|
| 6968 |
+
this.modeOption = mode;
|
| 6969 |
+
this.lineSep = lineSep;
|
| 6970 |
+
this.direction = (direction == "rtl") ? "rtl" : "ltr";
|
| 6971 |
+
this.extend = false;
|
| 6972 |
+
|
| 6973 |
+
if (typeof text == "string") { text = this.splitLines(text); }
|
| 6974 |
+
updateDoc(this, {from: start, to: start, text: text});
|
| 6975 |
+
setSelection(this, simpleSelection(start), sel_dontScroll);
|
| 6976 |
+
};
|
| 6977 |
|
| 6978 |
Doc.prototype = createObj(BranchChunk.prototype, {
|
| 6979 |
constructor: Doc,
|
| 6982 |
// three, it iterates over the range given by the first two (with
|
| 6983 |
// the second being non-inclusive).
|
| 6984 |
iter: function(from, to, op) {
|
| 6985 |
+
if (op) { this.iterN(from - this.first, to - from, op); }
|
| 6986 |
+
else { this.iterN(this.first, this.first + this.size, from); }
|
| 6987 |
},
|
| 6988 |
|
| 6989 |
// Non-public interface for adding and removing lines.
|
| 6990 |
insert: function(at, lines) {
|
| 6991 |
+
var height = 0;
|
| 6992 |
+
for (var i = 0; i < lines.length; ++i) { height += lines[i].height; }
|
| 6993 |
+
this.insertInner(at - this.first, lines, height);
|
| 6994 |
},
|
| 6995 |
+
remove: function(at, n) { this.removeInner(at - this.first, n); },
|
| 6996 |
|
| 6997 |
// From here, the methods are part of the public interface. Most
|
| 6998 |
// are also available from CodeMirror (editor) instances.
|
| 6999 |
|
| 7000 |
getValue: function(lineSep) {
|
| 7001 |
+
var lines = getLines(this, this.first, this.first + this.size);
|
| 7002 |
if (lineSep === false) { return lines }
|
| 7003 |
return lines.join(lineSep || this.lineSeparator())
|
| 7004 |
},
|
| 7005 |
setValue: docMethodOp(function(code) {
|
| 7006 |
+
var top = Pos(this.first, 0), last = this.first + this.size - 1;
|
| 7007 |
makeChange(this, {from: top, to: Pos(last, getLine(this, last).text.length),
|
| 7008 |
+
text: this.splitLines(code), origin: "setValue", full: true}, true);
|
| 7009 |
+
setSelection(this, simpleSelection(top));
|
| 7010 |
}),
|
| 7011 |
replaceRange: function(code, from, to, origin) {
|
| 7012 |
+
from = clipPos(this, from);
|
| 7013 |
+
to = to ? clipPos(this, to) : from;
|
| 7014 |
+
replaceRange(this, code, from, to, origin);
|
| 7015 |
},
|
| 7016 |
getRange: function(from, to, lineSep) {
|
| 7017 |
+
var lines = getBetween(this, clipPos(this, from), clipPos(this, to));
|
| 7018 |
if (lineSep === false) { return lines }
|
| 7019 |
return lines.join(lineSep || this.lineSeparator())
|
| 7020 |
},
|
| 7025 |
getLineNumber: function(line) {return lineNo(line)},
|
| 7026 |
|
| 7027 |
getLineHandleVisualStart: function(line) {
|
| 7028 |
+
if (typeof line == "number") { line = getLine(this, line); }
|
| 7029 |
return visualLine(line)
|
| 7030 |
},
|
| 7031 |
|
| 7036 |
clipPos: function(pos) {return clipPos(this, pos)},
|
| 7037 |
|
| 7038 |
getCursor: function(start) {
|
| 7039 |
+
var range$$1 = this.sel.primary(), pos;
|
| 7040 |
+
if (start == null || start == "head") { pos = range$$1.head; }
|
| 7041 |
+
else if (start == "anchor") { pos = range$$1.anchor; }
|
| 7042 |
+
else if (start == "end" || start == "to" || start === false) { pos = range$$1.to(); }
|
| 7043 |
+
else { pos = range$$1.from(); }
|
| 7044 |
return pos
|
| 7045 |
},
|
| 7046 |
listSelections: function() { return this.sel.ranges },
|
| 7047 |
somethingSelected: function() {return this.sel.somethingSelected()},
|
| 7048 |
|
| 7049 |
setCursor: docMethodOp(function(line, ch, options) {
|
| 7050 |
+
setSimpleSelection(this, clipPos(this, typeof line == "number" ? Pos(line, ch || 0) : line), null, options);
|
| 7051 |
}),
|
| 7052 |
setSelection: docMethodOp(function(anchor, head, options) {
|
| 7053 |
+
setSimpleSelection(this, clipPos(this, anchor), clipPos(this, head || anchor), options);
|
| 7054 |
}),
|
| 7055 |
extendSelection: docMethodOp(function(head, other, options) {
|
| 7056 |
+
extendSelection(this, clipPos(this, head), other && clipPos(this, other), options);
|
| 7057 |
}),
|
| 7058 |
extendSelections: docMethodOp(function(heads, options) {
|
| 7059 |
+
extendSelections(this, clipPosArray(this, heads), options);
|
| 7060 |
}),
|
| 7061 |
extendSelectionsBy: docMethodOp(function(f, options) {
|
| 7062 |
+
var heads = map(this.sel.ranges, f);
|
| 7063 |
+
extendSelections(this, clipPosArray(this, heads), options);
|
| 7064 |
}),
|
| 7065 |
setSelections: docMethodOp(function(ranges, primary, options) {
|
| 7066 |
var this$1 = this;
|
| 7067 |
|
| 7068 |
if (!ranges.length) { return }
|
| 7069 |
+
var out = [];
|
| 7070 |
for (var i = 0; i < ranges.length; i++)
|
| 7071 |
{ out[i] = new Range(clipPos(this$1, ranges[i].anchor),
|
| 7072 |
+
clipPos(this$1, ranges[i].head)); }
|
| 7073 |
+
if (primary == null) { primary = Math.min(ranges.length - 1, this.sel.primIndex); }
|
| 7074 |
+
setSelection(this, normalizeSelection(out, primary), options);
|
| 7075 |
}),
|
| 7076 |
addSelection: docMethodOp(function(anchor, head, options) {
|
| 7077 |
+
var ranges = this.sel.ranges.slice(0);
|
| 7078 |
+
ranges.push(new Range(clipPos(this, anchor), clipPos(this, head || anchor)));
|
| 7079 |
+
setSelection(this, normalizeSelection(ranges, ranges.length - 1), options);
|
| 7080 |
}),
|
| 7081 |
|
| 7082 |
getSelection: function(lineSep) {
|
| 7083 |
var this$1 = this;
|
| 7084 |
|
| 7085 |
+
var ranges = this.sel.ranges, lines;
|
| 7086 |
for (var i = 0; i < ranges.length; i++) {
|
| 7087 |
+
var sel = getBetween(this$1, ranges[i].from(), ranges[i].to());
|
| 7088 |
+
lines = lines ? lines.concat(sel) : sel;
|
| 7089 |
}
|
| 7090 |
if (lineSep === false) { return lines }
|
| 7091 |
else { return lines.join(lineSep || this.lineSeparator()) }
|
| 7093 |
getSelections: function(lineSep) {
|
| 7094 |
var this$1 = this;
|
| 7095 |
|
| 7096 |
+
var parts = [], ranges = this.sel.ranges;
|
| 7097 |
for (var i = 0; i < ranges.length; i++) {
|
| 7098 |
+
var sel = getBetween(this$1, ranges[i].from(), ranges[i].to());
|
| 7099 |
+
if (lineSep !== false) { sel = sel.join(lineSep || this$1.lineSeparator()); }
|
| 7100 |
+
parts[i] = sel;
|
| 7101 |
}
|
| 7102 |
return parts
|
| 7103 |
},
|
| 7104 |
replaceSelection: function(code, collapse, origin) {
|
| 7105 |
+
var dup = [];
|
| 7106 |
for (var i = 0; i < this.sel.ranges.length; i++)
|
| 7107 |
+
{ dup[i] = code; }
|
| 7108 |
+
this.replaceSelections(dup, collapse, origin || "+input");
|
| 7109 |
},
|
| 7110 |
replaceSelections: docMethodOp(function(code, collapse, origin) {
|
| 7111 |
var this$1 = this;
|
| 7112 |
|
| 7113 |
+
var changes = [], sel = this.sel;
|
| 7114 |
for (var i = 0; i < sel.ranges.length; i++) {
|
| 7115 |
+
var range$$1 = sel.ranges[i];
|
| 7116 |
+
changes[i] = {from: range$$1.from(), to: range$$1.to(), text: this$1.splitLines(code[i]), origin: origin};
|
| 7117 |
}
|
| 7118 |
+
var newSel = collapse && collapse != "end" && computeReplacedSel(this, changes, collapse);
|
| 7119 |
for (var i$1 = changes.length - 1; i$1 >= 0; i$1--)
|
| 7120 |
+
{ makeChange(this$1, changes[i$1]); }
|
| 7121 |
+
if (newSel) { setSelectionReplaceHistory(this, newSel); }
|
| 7122 |
+
else if (this.cm) { ensureCursorVisible(this.cm); }
|
| 7123 |
}),
|
| 7124 |
+
undo: docMethodOp(function() {makeChangeFromHistory(this, "undo");}),
|
| 7125 |
+
redo: docMethodOp(function() {makeChangeFromHistory(this, "redo");}),
|
| 7126 |
+
undoSelection: docMethodOp(function() {makeChangeFromHistory(this, "undo", true);}),
|
| 7127 |
+
redoSelection: docMethodOp(function() {makeChangeFromHistory(this, "redo", true);}),
|
| 7128 |
|
| 7129 |
+
setExtending: function(val) {this.extend = val;},
|
| 7130 |
getExtending: function() {return this.extend},
|
| 7131 |
|
| 7132 |
historySize: function() {
|
| 7133 |
+
var hist = this.history, done = 0, undone = 0;
|
| 7134 |
+
for (var i = 0; i < hist.done.length; i++) { if (!hist.done[i].ranges) { ++done; } }
|
| 7135 |
+
for (var i$1 = 0; i$1 < hist.undone.length; i$1++) { if (!hist.undone[i$1].ranges) { ++undone; } }
|
| 7136 |
return {undo: done, redo: undone}
|
| 7137 |
},
|
| 7138 |
+
clearHistory: function() {this.history = new History(this.history.maxGeneration);},
|
| 7139 |
|
| 7140 |
markClean: function() {
|
| 7141 |
+
this.cleanGeneration = this.changeGeneration(true);
|
| 7142 |
},
|
| 7143 |
changeGeneration: function(forceSplit) {
|
| 7144 |
if (forceSplit)
|
| 7145 |
+
{ this.history.lastOp = this.history.lastSelOp = this.history.lastOrigin = null; }
|
| 7146 |
return this.history.generation
|
| 7147 |
},
|
| 7148 |
isClean: function (gen) {
|
| 7154 |
undone: copyHistoryArray(this.history.undone)}
|
| 7155 |
},
|
| 7156 |
setHistory: function(histData) {
|
| 7157 |
+
var hist = this.history = new History(this.history.maxGeneration);
|
| 7158 |
+
hist.done = copyHistoryArray(histData.done.slice(0), null, true);
|
| 7159 |
+
hist.undone = copyHistoryArray(histData.undone.slice(0), null, true);
|
| 7160 |
},
|
| 7161 |
|
| 7162 |
setGutterMarker: docMethodOp(function(line, gutterID, value) {
|
| 7163 |
return changeLine(this, line, "gutter", function (line) {
|
| 7164 |
+
var markers = line.gutterMarkers || (line.gutterMarkers = {});
|
| 7165 |
+
markers[gutterID] = value;
|
| 7166 |
+
if (!value && isEmpty(markers)) { line.gutterMarkers = null; }
|
| 7167 |
return true
|
| 7168 |
})
|
| 7169 |
}),
|
| 7174 |
this.iter(function (line) {
|
| 7175 |
if (line.gutterMarkers && line.gutterMarkers[gutterID]) {
|
| 7176 |
changeLine(this$1, line, "gutter", function () {
|
| 7177 |
+
line.gutterMarkers[gutterID] = null;
|
| 7178 |
+
if (isEmpty(line.gutterMarkers)) { line.gutterMarkers = null; }
|
| 7179 |
return true
|
| 7180 |
+
});
|
| 7181 |
}
|
| 7182 |
+
});
|
| 7183 |
}),
|
| 7184 |
|
| 7185 |
lineInfo: function(line) {
|
| 7186 |
+
var n;
|
| 7187 |
if (typeof line == "number") {
|
| 7188 |
if (!isLine(this, line)) { return null }
|
| 7189 |
+
n = line;
|
| 7190 |
+
line = getLine(this, line);
|
| 7191 |
if (!line) { return null }
|
| 7192 |
} else {
|
| 7193 |
+
n = lineNo(line);
|
| 7194 |
if (n == null) { return null }
|
| 7195 |
}
|
| 7196 |
return {line: n, handle: line, text: line.text, gutterMarkers: line.gutterMarkers,
|
| 7202 |
return changeLine(this, handle, where == "gutter" ? "gutter" : "class", function (line) {
|
| 7203 |
var prop = where == "text" ? "textClass"
|
| 7204 |
: where == "background" ? "bgClass"
|
| 7205 |
+
: where == "gutter" ? "gutterClass" : "wrapClass";
|
| 7206 |
+
if (!line[prop]) { line[prop] = cls; }
|
| 7207 |
else if (classTest(cls).test(line[prop])) { return false }
|
| 7208 |
+
else { line[prop] += " " + cls; }
|
| 7209 |
return true
|
| 7210 |
})
|
| 7211 |
}),
|
| 7213 |
return changeLine(this, handle, where == "gutter" ? "gutter" : "class", function (line) {
|
| 7214 |
var prop = where == "text" ? "textClass"
|
| 7215 |
: where == "background" ? "bgClass"
|
| 7216 |
+
: where == "gutter" ? "gutterClass" : "wrapClass";
|
| 7217 |
+
var cur = line[prop];
|
| 7218 |
if (!cur) { return false }
|
| 7219 |
+
else if (cls == null) { line[prop] = null; }
|
| 7220 |
else {
|
| 7221 |
+
var found = cur.match(classTest(cls));
|
| 7222 |
if (!found) { return false }
|
| 7223 |
+
var end = found.index + found[0].length;
|
| 7224 |
+
line[prop] = cur.slice(0, found.index) + (!found.index || end == cur.length ? "" : " ") + cur.slice(end) || null;
|
| 7225 |
}
|
| 7226 |
return true
|
| 7227 |
})
|
| 7230 |
addLineWidget: docMethodOp(function(handle, node, options) {
|
| 7231 |
return addLineWidget(this, handle, node, options)
|
| 7232 |
}),
|
| 7233 |
+
removeLineWidget: function(widget) { widget.clear(); },
|
| 7234 |
|
| 7235 |
markText: function(from, to, options) {
|
| 7236 |
return markText(this, clipPos(this, from), clipPos(this, to), options, options && options.type || "range")
|
| 7239 |
var realOpts = {replacedWith: options && (options.nodeType == null ? options.widget : options),
|
| 7240 |
insertLeft: options && options.insertLeft,
|
| 7241 |
clearWhenEmpty: false, shared: options && options.shared,
|
| 7242 |
+
handleMouseEvents: options && options.handleMouseEvents};
|
| 7243 |
+
pos = clipPos(this, pos);
|
| 7244 |
return markText(this, pos, pos, realOpts, "bookmark")
|
| 7245 |
},
|
| 7246 |
findMarksAt: function(pos) {
|
| 7247 |
+
pos = clipPos(this, pos);
|
| 7248 |
+
var markers = [], spans = getLine(this, pos.line).markedSpans;
|
| 7249 |
if (spans) { for (var i = 0; i < spans.length; ++i) {
|
| 7250 |
+
var span = spans[i];
|
| 7251 |
if ((span.from == null || span.from <= pos.ch) &&
|
| 7252 |
(span.to == null || span.to >= pos.ch))
|
| 7253 |
+
{ markers.push(span.marker.parent || span.marker); }
|
| 7254 |
} }
|
| 7255 |
return markers
|
| 7256 |
},
|
| 7257 |
findMarks: function(from, to, filter) {
|
| 7258 |
+
from = clipPos(this, from); to = clipPos(this, to);
|
| 7259 |
+
var found = [], lineNo$$1 = from.line;
|
| 7260 |
this.iter(from.line, to.line + 1, function (line) {
|
| 7261 |
+
var spans = line.markedSpans;
|
| 7262 |
if (spans) { for (var i = 0; i < spans.length; i++) {
|
| 7263 |
+
var span = spans[i];
|
| 7264 |
+
if (!(span.to != null && lineNo$$1 == from.line && from.ch >= span.to ||
|
| 7265 |
+
span.from == null && lineNo$$1 != from.line ||
|
| 7266 |
+
span.from != null && lineNo$$1 == to.line && span.from >= to.ch) &&
|
| 7267 |
(!filter || filter(span.marker)))
|
| 7268 |
+
{ found.push(span.marker.parent || span.marker); }
|
| 7269 |
} }
|
| 7270 |
+
++lineNo$$1;
|
| 7271 |
+
});
|
| 7272 |
return found
|
| 7273 |
},
|
| 7274 |
getAllMarks: function() {
|
| 7275 |
+
var markers = [];
|
| 7276 |
this.iter(function (line) {
|
| 7277 |
+
var sps = line.markedSpans;
|
| 7278 |
if (sps) { for (var i = 0; i < sps.length; ++i)
|
| 7279 |
+
{ if (sps[i].from != null) { markers.push(sps[i].marker); } } }
|
| 7280 |
+
});
|
| 7281 |
return markers
|
| 7282 |
},
|
| 7283 |
|
| 7284 |
posFromIndex: function(off) {
|
| 7285 |
+
var ch, lineNo$$1 = this.first, sepSize = this.lineSeparator().length;
|
| 7286 |
this.iter(function (line) {
|
| 7287 |
+
var sz = line.text.length + sepSize;
|
| 7288 |
if (sz > off) { ch = off; return true }
|
| 7289 |
+
off -= sz;
|
| 7290 |
+
++lineNo$$1;
|
| 7291 |
+
});
|
| 7292 |
+
return clipPos(this, Pos(lineNo$$1, ch))
|
| 7293 |
},
|
| 7294 |
indexFromPos: function (coords) {
|
| 7295 |
+
coords = clipPos(this, coords);
|
| 7296 |
+
var index = coords.ch;
|
| 7297 |
if (coords.line < this.first || coords.ch < 0) { return 0 }
|
| 7298 |
+
var sepSize = this.lineSeparator().length;
|
| 7299 |
this.iter(this.first, coords.line, function (line) { // iter aborts when callback returns a truthy value
|
| 7300 |
+
index += line.text.length + sepSize;
|
| 7301 |
+
});
|
| 7302 |
return index
|
| 7303 |
},
|
| 7304 |
|
| 7305 |
copy: function(copyHistory) {
|
| 7306 |
var doc = new Doc(getLines(this, this.first, this.first + this.size),
|
| 7307 |
+
this.modeOption, this.first, this.lineSep, this.direction);
|
| 7308 |
+
doc.scrollTop = this.scrollTop; doc.scrollLeft = this.scrollLeft;
|
| 7309 |
+
doc.sel = this.sel;
|
| 7310 |
+
doc.extend = false;
|
| 7311 |
if (copyHistory) {
|
| 7312 |
+
doc.history.undoDepth = this.history.undoDepth;
|
| 7313 |
+
doc.setHistory(this.getHistory());
|
| 7314 |
}
|
| 7315 |
return doc
|
| 7316 |
},
|
| 7317 |
|
| 7318 |
linkedDoc: function(options) {
|
| 7319 |
+
if (!options) { options = {}; }
|
| 7320 |
+
var from = this.first, to = this.first + this.size;
|
| 7321 |
+
if (options.from != null && options.from > from) { from = options.from; }
|
| 7322 |
+
if (options.to != null && options.to < to) { to = options.to; }
|
| 7323 |
+
var copy = new Doc(getLines(this, from, to), options.mode || this.modeOption, from, this.lineSep, this.direction);
|
| 7324 |
if (options.sharedHist) { copy.history = this.history
|
| 7325 |
+
; }(this.linked || (this.linked = [])).push({doc: copy, sharedHist: options.sharedHist});
|
| 7326 |
+
copy.linked = [{doc: this, isParent: true, sharedHist: options.sharedHist}];
|
| 7327 |
+
copySharedMarkers(copy, findSharedMarkers(this));
|
| 7328 |
return copy
|
| 7329 |
},
|
| 7330 |
unlinkDoc: function(other) {
|
| 7331 |
var this$1 = this;
|
| 7332 |
|
| 7333 |
+
if (other instanceof CodeMirror$1) { other = other.doc; }
|
| 7334 |
if (this.linked) { for (var i = 0; i < this.linked.length; ++i) {
|
| 7335 |
+
var link = this$1.linked[i];
|
| 7336 |
if (link.doc != other) { continue }
|
| 7337 |
+
this$1.linked.splice(i, 1);
|
| 7338 |
+
other.unlinkDoc(this$1);
|
| 7339 |
+
detachSharedMarkers(findSharedMarkers(this$1));
|
| 7340 |
break
|
| 7341 |
} }
|
| 7342 |
// If the histories were shared, split them again
|
| 7343 |
if (other.history == this.history) {
|
| 7344 |
+
var splitIds = [other.id];
|
| 7345 |
+
linkedDocs(other, function (doc) { return splitIds.push(doc.id); }, true);
|
| 7346 |
+
other.history = new History(null);
|
| 7347 |
+
other.history.done = copyHistoryArray(this.history.done, splitIds);
|
| 7348 |
+
other.history.undone = copyHistoryArray(this.history.undone, splitIds);
|
| 7349 |
}
|
| 7350 |
},
|
| 7351 |
+
iterLinkedDocs: function(f) {linkedDocs(this, f);},
|
| 7352 |
|
| 7353 |
getMode: function() {return this.mode},
|
| 7354 |
getEditor: function() {return this.cm},
|
| 7357 |
if (this.lineSep) { return str.split(this.lineSep) }
|
| 7358 |
return splitLinesAuto(str)
|
| 7359 |
},
|
| 7360 |
+
lineSeparator: function() { return this.lineSep || "\n" },
|
| 7361 |
+
|
| 7362 |
+
setDirection: docMethodOp(function (dir) {
|
| 7363 |
+
if (dir != "rtl") { dir = "ltr"; }
|
| 7364 |
+
if (dir == this.direction) { return }
|
| 7365 |
+
this.direction = dir;
|
| 7366 |
+
this.iter(function (line) { return line.order = null; });
|
| 7367 |
+
if (this.cm) { directionChanged(this.cm); }
|
| 7368 |
+
})
|
| 7369 |
+
});
|
| 7370 |
|
| 7371 |
// Public alias.
|
| 7372 |
+
Doc.prototype.eachLine = Doc.prototype.iter;
|
| 7373 |
|
| 7374 |
// Kludge to work around strange IE behavior where it'll sometimes
|
| 7375 |
// re-fire a series of drag-related events right after the drop (#1551)
|
| 7376 |
+
var lastDrop = 0;
|
| 7377 |
|
| 7378 |
function onDrop(e) {
|
| 7379 |
+
var cm = this;
|
| 7380 |
+
clearDragCursor(cm);
|
| 7381 |
if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e))
|
| 7382 |
{ return }
|
| 7383 |
+
e_preventDefault(e);
|
| 7384 |
+
if (ie) { lastDrop = +new Date; }
|
| 7385 |
+
var pos = posFromMouse(cm, e, true), files = e.dataTransfer.files;
|
| 7386 |
if (!pos || cm.isReadOnly()) { return }
|
| 7387 |
// Might be a file drop, in which case we simply extract the text
|
| 7388 |
// and insert it.
|
| 7389 |
if (files && files.length && window.FileReader && window.File) {
|
| 7390 |
+
var n = files.length, text = Array(n), read = 0;
|
| 7391 |
var loadFile = function (file, i) {
|
| 7392 |
if (cm.options.allowDropFileTypes &&
|
| 7393 |
indexOf(cm.options.allowDropFileTypes, file.type) == -1)
|
| 7394 |
{ return }
|
| 7395 |
|
| 7396 |
+
var reader = new FileReader;
|
| 7397 |
reader.onload = operation(cm, function () {
|
| 7398 |
+
var content = reader.result;
|
| 7399 |
+
if (/[\x00-\x08\x0e-\x1f]{2}/.test(content)) { content = ""; }
|
| 7400 |
+
text[i] = content;
|
| 7401 |
if (++read == n) {
|
| 7402 |
+
pos = clipPos(cm.doc, pos);
|
| 7403 |
var change = {from: pos, to: pos,
|
| 7404 |
text: cm.doc.splitLines(text.join(cm.doc.lineSeparator())),
|
| 7405 |
+
origin: "paste"};
|
| 7406 |
+
makeChange(cm.doc, change);
|
| 7407 |
+
setSelectionReplaceHistory(cm.doc, simpleSelection(pos, changeEnd(change)));
|
| 7408 |
}
|
| 7409 |
+
});
|
| 7410 |
+
reader.readAsText(file);
|
| 7411 |
+
};
|
| 7412 |
+
for (var i = 0; i < n; ++i) { loadFile(files[i], i); }
|
| 7413 |
} else { // Normal drop
|
| 7414 |
// Don't do a replace if the drop happened inside of the selected text.
|
| 7415 |
if (cm.state.draggingText && cm.doc.sel.contains(pos) > -1) {
|
| 7416 |
+
cm.state.draggingText(e);
|
| 7417 |
// Ensure the editor is re-focused
|
| 7418 |
+
setTimeout(function () { return cm.display.input.focus(); }, 20);
|
| 7419 |
return
|
| 7420 |
}
|
| 7421 |
try {
|
| 7422 |
+
var text$1 = e.dataTransfer.getData("Text");
|
| 7423 |
if (text$1) {
|
| 7424 |
+
var selected;
|
| 7425 |
if (cm.state.draggingText && !cm.state.draggingText.copy)
|
| 7426 |
+
{ selected = cm.listSelections(); }
|
| 7427 |
+
setSelectionNoUndo(cm.doc, simpleSelection(pos, pos));
|
| 7428 |
if (selected) { for (var i$1 = 0; i$1 < selected.length; ++i$1)
|
| 7429 |
+
{ replaceRange(cm.doc, "", selected[i$1].anchor, selected[i$1].head, "drag"); } }
|
| 7430 |
+
cm.replaceSelection(text$1, "around", "paste");
|
| 7431 |
+
cm.display.input.focus();
|
| 7432 |
}
|
| 7433 |
}
|
| 7434 |
catch(e){}
|
| 7439 |
if (ie && (!cm.state.draggingText || +new Date - lastDrop < 100)) { e_stop(e); return }
|
| 7440 |
if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e)) { return }
|
| 7441 |
|
| 7442 |
+
e.dataTransfer.setData("Text", cm.getSelection());
|
| 7443 |
+
e.dataTransfer.effectAllowed = "copyMove";
|
| 7444 |
|
| 7445 |
// Use dummy image instead of default browsers image.
|
| 7446 |
// Recent Safari (~6.0.2) have a tendency to segfault when this happens, so we don't do it there.
|
| 7447 |
if (e.dataTransfer.setDragImage && !safari) {
|
| 7448 |
+
var img = elt("img", null, null, "position: fixed; left: 0; top: 0;");
|
| 7449 |
+
img.src = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==";
|
| 7450 |
if (presto) {
|
| 7451 |
+
img.width = img.height = 1;
|
| 7452 |
+
cm.display.wrapper.appendChild(img);
|
| 7453 |
// Force a relayout, or Opera won't use our image for some obscure reason
|
| 7454 |
+
img._top = img.offsetTop;
|
| 7455 |
}
|
| 7456 |
+
e.dataTransfer.setDragImage(img, 0, 0);
|
| 7457 |
+
if (presto) { img.parentNode.removeChild(img); }
|
| 7458 |
}
|
| 7459 |
}
|
| 7460 |
|
| 7461 |
function onDragOver(cm, e) {
|
| 7462 |
+
var pos = posFromMouse(cm, e);
|
| 7463 |
if (!pos) { return }
|
| 7464 |
+
var frag = document.createDocumentFragment();
|
| 7465 |
+
drawSelectionCursor(cm, pos, frag);
|
| 7466 |
if (!cm.display.dragCursor) {
|
| 7467 |
+
cm.display.dragCursor = elt("div", null, "CodeMirror-cursors CodeMirror-dragcursors");
|
| 7468 |
+
cm.display.lineSpace.insertBefore(cm.display.dragCursor, cm.display.cursorDiv);
|
| 7469 |
}
|
| 7470 |
+
removeChildrenAndAdd(cm.display.dragCursor, frag);
|
| 7471 |
}
|
| 7472 |
|
| 7473 |
function clearDragCursor(cm) {
|
| 7474 |
if (cm.display.dragCursor) {
|
| 7475 |
+
cm.display.lineSpace.removeChild(cm.display.dragCursor);
|
| 7476 |
+
cm.display.dragCursor = null;
|
| 7477 |
}
|
| 7478 |
}
|
| 7479 |
|
| 7483 |
|
| 7484 |
function forEachCodeMirror(f) {
|
| 7485 |
if (!document.body.getElementsByClassName) { return }
|
| 7486 |
+
var byClass = document.body.getElementsByClassName("CodeMirror");
|
| 7487 |
for (var i = 0; i < byClass.length; i++) {
|
| 7488 |
+
var cm = byClass[i].CodeMirror;
|
| 7489 |
+
if (cm) { f(cm); }
|
| 7490 |
}
|
| 7491 |
}
|
| 7492 |
|
| 7493 |
+
var globalsRegistered = false;
|
| 7494 |
function ensureGlobalHandlers() {
|
| 7495 |
if (globalsRegistered) { return }
|
| 7496 |
+
registerGlobalHandlers();
|
| 7497 |
+
globalsRegistered = true;
|
| 7498 |
}
|
| 7499 |
function registerGlobalHandlers() {
|
| 7500 |
// When the window resizes, we need to refresh active editors.
|
| 7501 |
+
var resizeTimer;
|
| 7502 |
on(window, "resize", function () {
|
| 7503 |
if (resizeTimer == null) { resizeTimer = setTimeout(function () {
|
| 7504 |
+
resizeTimer = null;
|
| 7505 |
+
forEachCodeMirror(onResize);
|
| 7506 |
+
}, 100); }
|
| 7507 |
+
});
|
| 7508 |
// When the window loses focus, we want to show the editor as blurred
|
| 7509 |
+
on(window, "blur", function () { return forEachCodeMirror(onBlur); });
|
| 7510 |
}
|
| 7511 |
// Called when the window resizes
|
| 7512 |
function onResize(cm) {
|
| 7513 |
+
var d = cm.display;
|
| 7514 |
if (d.lastWrapHeight == d.wrapper.clientHeight && d.lastWrapWidth == d.wrapper.clientWidth)
|
| 7515 |
{ return }
|
| 7516 |
// Might be a text scaling operation, clear size caches.
|
| 7517 |
+
d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = null;
|
| 7518 |
+
d.scrollbarsClipped = false;
|
| 7519 |
+
cm.setSize();
|
| 7520 |
}
|
| 7521 |
|
| 7522 |
var keyNames = {
|
| 7528 |
173: "-", 186: ";", 187: "=", 188: ",", 189: "-", 190: ".", 191: "/", 192: "`", 219: "[", 220: "\\",
|
| 7529 |
221: "]", 222: "'", 63232: "Up", 63233: "Down", 63234: "Left", 63235: "Right", 63272: "Delete",
|
| 7530 |
63273: "Home", 63275: "End", 63276: "PageUp", 63277: "PageDown", 63302: "Insert"
|
| 7531 |
+
};
|
| 7532 |
|
| 7533 |
// Number keys
|
| 7534 |
+
for (var i = 0; i < 10; i++) { keyNames[i + 48] = keyNames[i + 96] = String(i); }
|
| 7535 |
// Alphabetic keys
|
| 7536 |
+
for (var i$1 = 65; i$1 <= 90; i$1++) { keyNames[i$1] = String.fromCharCode(i$1); }
|
| 7537 |
// Function keys
|
| 7538 |
+
for (var i$2 = 1; i$2 <= 12; i$2++) { keyNames[i$2 + 111] = keyNames[i$2 + 63235] = "F" + i$2; }
|
| 7539 |
|
| 7540 |
+
var keyMap = {};
|
| 7541 |
|
| 7542 |
keyMap.basic = {
|
| 7543 |
"Left": "goCharLeft", "Right": "goCharRight", "Up": "goLineUp", "Down": "goLineDown",
|
| 7546 |
"Tab": "defaultTab", "Shift-Tab": "indentAuto",
|
| 7547 |
"Enter": "newlineAndIndent", "Insert": "toggleOverwrite",
|
| 7548 |
"Esc": "singleSelection"
|
| 7549 |
+
};
|
| 7550 |
// Note that the save and find-related commands aren't defined by
|
| 7551 |
// default. User code or addons can define them. Unknown commands
|
| 7552 |
// are simply ignored.
|
| 7559 |
"Ctrl-[": "indentLess", "Ctrl-]": "indentMore",
|
| 7560 |
"Ctrl-U": "undoSelection", "Shift-Ctrl-U": "redoSelection", "Alt-U": "redoSelection",
|
| 7561 |
fallthrough: "basic"
|
| 7562 |
+
};
|
| 7563 |
// Very basic readline/emacs-style bindings, which are standard on Mac.
|
| 7564 |
keyMap.emacsy = {
|
| 7565 |
"Ctrl-F": "goCharRight", "Ctrl-B": "goCharLeft", "Ctrl-P": "goLineUp", "Ctrl-N": "goLineDown",
|
| 7567 |
"Ctrl-V": "goPageDown", "Shift-Ctrl-V": "goPageUp", "Ctrl-D": "delCharAfter", "Ctrl-H": "delCharBefore",
|
| 7568 |
"Alt-D": "delWordAfter", "Alt-Backspace": "delWordBefore", "Ctrl-K": "killLine", "Ctrl-T": "transposeChars",
|
| 7569 |
"Ctrl-O": "openLine"
|
| 7570 |
+
};
|
| 7571 |
keyMap.macDefault = {
|
| 7572 |
"Cmd-A": "selectAll", "Cmd-D": "deleteLine", "Cmd-Z": "undo", "Shift-Cmd-Z": "redo", "Cmd-Y": "redo",
|
| 7573 |
"Cmd-Home": "goDocStart", "Cmd-Up": "goDocStart", "Cmd-End": "goDocEnd", "Cmd-Down": "goDocEnd", "Alt-Left": "goGroupLeft",
|
| 7577 |
"Cmd-[": "indentLess", "Cmd-]": "indentMore", "Cmd-Backspace": "delWrappedLineLeft", "Cmd-Delete": "delWrappedLineRight",
|
| 7578 |
"Cmd-U": "undoSelection", "Shift-Cmd-U": "redoSelection", "Ctrl-Up": "goDocStart", "Ctrl-Down": "goDocEnd",
|
| 7579 |
fallthrough: ["basic", "emacsy"]
|
| 7580 |
+
};
|
| 7581 |
+
keyMap["default"] = mac ? keyMap.macDefault : keyMap.pcDefault;
|
| 7582 |
|
| 7583 |
// KEYMAP DISPATCH
|
| 7584 |
|
| 7585 |
function normalizeKeyName(name) {
|
| 7586 |
+
var parts = name.split(/-(?!$)/);
|
| 7587 |
+
name = parts[parts.length - 1];
|
| 7588 |
+
var alt, ctrl, shift, cmd;
|
| 7589 |
for (var i = 0; i < parts.length - 1; i++) {
|
| 7590 |
+
var mod = parts[i];
|
| 7591 |
+
if (/^(cmd|meta|m)$/i.test(mod)) { cmd = true; }
|
| 7592 |
+
else if (/^a(lt)?$/i.test(mod)) { alt = true; }
|
| 7593 |
+
else if (/^(c|ctrl|control)$/i.test(mod)) { ctrl = true; }
|
| 7594 |
+
else if (/^s(hift)?$/i.test(mod)) { shift = true; }
|
| 7595 |
else { throw new Error("Unrecognized modifier name: " + mod) }
|
| 7596 |
}
|
| 7597 |
+
if (alt) { name = "Alt-" + name; }
|
| 7598 |
+
if (ctrl) { name = "Ctrl-" + name; }
|
| 7599 |
+
if (cmd) { name = "Cmd-" + name; }
|
| 7600 |
+
if (shift) { name = "Shift-" + name; }
|
| 7601 |
return name
|
| 7602 |
}
|
| 7603 |
|
| 7607 |
// new normalized keymap, and then updates the old object to reflect
|
| 7608 |
// this.
|
| 7609 |
function normalizeKeyMap(keymap) {
|
| 7610 |
+
var copy = {};
|
| 7611 |
for (var keyname in keymap) { if (keymap.hasOwnProperty(keyname)) {
|
| 7612 |
+
var value = keymap[keyname];
|
| 7613 |
if (/^(name|fallthrough|(de|at)tach)$/.test(keyname)) { continue }
|
| 7614 |
if (value == "...") { delete keymap[keyname]; continue }
|
| 7615 |
|
| 7616 |
+
var keys = map(keyname.split(" "), normalizeKeyName);
|
| 7617 |
for (var i = 0; i < keys.length; i++) {
|
| 7618 |
+
var val = (void 0), name = (void 0);
|
| 7619 |
if (i == keys.length - 1) {
|
| 7620 |
+
name = keys.join(" ");
|
| 7621 |
+
val = value;
|
| 7622 |
} else {
|
| 7623 |
+
name = keys.slice(0, i + 1).join(" ");
|
| 7624 |
+
val = "...";
|
| 7625 |
}
|
| 7626 |
+
var prev = copy[name];
|
| 7627 |
+
if (!prev) { copy[name] = val; }
|
| 7628 |
else if (prev != val) { throw new Error("Inconsistent bindings for " + name) }
|
| 7629 |
}
|
| 7630 |
+
delete keymap[keyname];
|
| 7631 |
} }
|
| 7632 |
+
for (var prop in copy) { keymap[prop] = copy[prop]; }
|
| 7633 |
return keymap
|
| 7634 |
}
|
| 7635 |
|
| 7636 |
+
function lookupKey(key, map$$1, handle, context) {
|
| 7637 |
+
map$$1 = getKeyMap(map$$1);
|
| 7638 |
+
var found = map$$1.call ? map$$1.call(key, context) : map$$1[key];
|
| 7639 |
if (found === false) { return "nothing" }
|
| 7640 |
if (found === "...") { return "multi" }
|
| 7641 |
if (found != null && handle(found)) { return "handled" }
|
| 7642 |
|
| 7643 |
+
if (map$$1.fallthrough) {
|
| 7644 |
+
if (Object.prototype.toString.call(map$$1.fallthrough) != "[object Array]")
|
| 7645 |
+
{ return lookupKey(key, map$$1.fallthrough, handle, context) }
|
| 7646 |
+
for (var i = 0; i < map$$1.fallthrough.length; i++) {
|
| 7647 |
+
var result = lookupKey(key, map$$1.fallthrough[i], handle, context);
|
| 7648 |
if (result) { return result }
|
| 7649 |
}
|
| 7650 |
}
|
| 7653 |
// Modifier key presses don't count as 'real' key presses for the
|
| 7654 |
// purpose of keymap fallthrough.
|
| 7655 |
function isModifierKey(value) {
|
| 7656 |
+
var name = typeof value == "string" ? value : keyNames[value.keyCode];
|
| 7657 |
return name == "Ctrl" || name == "Alt" || name == "Shift" || name == "Mod"
|
| 7658 |
}
|
| 7659 |
|
| 7660 |
// Look up the name of a key as indicated by an event object.
|
| 7661 |
function keyName(event, noShift) {
|
| 7662 |
if (presto && event.keyCode == 34 && event["char"]) { return false }
|
| 7663 |
+
var base = keyNames[event.keyCode], name = base;
|
| 7664 |
if (name == null || event.altGraphKey) { return false }
|
| 7665 |
+
if (event.altKey && base != "Alt") { name = "Alt-" + name; }
|
| 7666 |
+
if ((flipCtrlCmd ? event.metaKey : event.ctrlKey) && base != "Ctrl") { name = "Ctrl-" + name; }
|
| 7667 |
+
if ((flipCtrlCmd ? event.ctrlKey : event.metaKey) && base != "Cmd") { name = "Cmd-" + name; }
|
| 7668 |
+
if (!noShift && event.shiftKey && base != "Shift") { name = "Shift-" + name; }
|
| 7669 |
return name
|
| 7670 |
}
|
| 7671 |
|
| 7676 |
// Helper for deleting text near the selection(s), used to implement
|
| 7677 |
// backspace, delete, and similar functionality.
|
| 7678 |
function deleteNearSelection(cm, compute) {
|
| 7679 |
+
var ranges = cm.doc.sel.ranges, kill = [];
|
| 7680 |
// Build up a set of ranges to kill first, merging overlapping
|
| 7681 |
// ranges.
|
| 7682 |
for (var i = 0; i < ranges.length; i++) {
|
| 7683 |
+
var toKill = compute(ranges[i]);
|
| 7684 |
while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {
|
| 7685 |
+
var replaced = kill.pop();
|
| 7686 |
if (cmp(replaced.from, toKill.from) < 0) {
|
| 7687 |
+
toKill.from = replaced.from;
|
| 7688 |
break
|
| 7689 |
}
|
| 7690 |
}
|
| 7691 |
+
kill.push(toKill);
|
| 7692 |
}
|
| 7693 |
// Next, remove those actual ranges.
|
| 7694 |
runInOp(cm, function () {
|
| 7695 |
for (var i = kill.length - 1; i >= 0; i--)
|
| 7696 |
+
{ replaceRange(cm.doc, "", kill[i].from, kill[i].to, "+delete"); }
|
| 7697 |
+
ensureCursorVisible(cm);
|
| 7698 |
+
});
|
| 7699 |
}
|
| 7700 |
|
| 7701 |
// Commands are parameter-less actions that can be performed on an
|
| 7705 |
singleSelection: function (cm) { return cm.setSelection(cm.getCursor("anchor"), cm.getCursor("head"), sel_dontScroll); },
|
| 7706 |
killLine: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7707 |
if (range.empty()) {
|
| 7708 |
+
var len = getLine(cm.doc, range.head.line).text.length;
|
| 7709 |
if (range.head.ch == len && range.head.line < cm.lastLine())
|
| 7710 |
{ return {from: range.head, to: Pos(range.head.line + 1, 0)} }
|
| 7711 |
else
|
| 7722 |
from: Pos(range.from().line, 0), to: range.from()
|
| 7723 |
}); }); },
|
| 7724 |
delWrappedLineLeft: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7725 |
+
var top = cm.charCoords(range.head, "div").top + 5;
|
| 7726 |
+
var leftPos = cm.coordsChar({left: 0, top: top}, "div");
|
| 7727 |
return {from: leftPos, to: range.from()}
|
| 7728 |
}); },
|
| 7729 |
delWrappedLineRight: function (cm) { return deleteNearSelection(cm, function (range) {
|
| 7730 |
+
var top = cm.charCoords(range.head, "div").top + 5;
|
| 7731 |
+
var rightPos = cm.coordsChar({left: cm.display.lineDiv.offsetWidth + 100, top: top}, "div");
|
| 7732 |
return {from: range.from(), to: rightPos }
|
| 7733 |
}); },
|
| 7734 |
undo: function (cm) { return cm.undo(); },
|
| 7747 |
{origin: "+move", bias: -1}
|
| 7748 |
); },
|
| 7749 |
goLineRight: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7750 |
+
var top = cm.charCoords(range.head, "div").top + 5;
|
| 7751 |
return cm.coordsChar({left: cm.display.lineDiv.offsetWidth + 100, top: top}, "div")
|
| 7752 |
}, sel_move); },
|
| 7753 |
goLineLeft: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7754 |
+
var top = cm.charCoords(range.head, "div").top + 5;
|
| 7755 |
return cm.coordsChar({left: 0, top: top}, "div")
|
| 7756 |
}, sel_move); },
|
| 7757 |
goLineLeftSmart: function (cm) { return cm.extendSelectionsBy(function (range) {
|
| 7758 |
+
var top = cm.charCoords(range.head, "div").top + 5;
|
| 7759 |
+
var pos = cm.coordsChar({left: 0, top: top}, "div");
|
| 7760 |
if (pos.ch < cm.getLine(pos.line).search(/\S/)) { return lineStartSmart(cm, range.head) }
|
| 7761 |
return pos
|
| 7762 |
}, sel_move); },
|
| 7783 |
indentLess: function (cm) { return cm.indentSelection("subtract"); },
|
| 7784 |
insertTab: function (cm) { return cm.replaceSelection("\t"); },
|
| 7785 |
insertSoftTab: function (cm) {
|
| 7786 |
+
var spaces = [], ranges = cm.listSelections(), tabSize = cm.options.tabSize;
|
| 7787 |
for (var i = 0; i < ranges.length; i++) {
|
| 7788 |
+
var pos = ranges[i].from();
|
| 7789 |
+
var col = countColumn(cm.getLine(pos.line), pos.ch, tabSize);
|
| 7790 |
+
spaces.push(spaceStr(tabSize - col % tabSize));
|
| 7791 |
}
|
| 7792 |
+
cm.replaceSelections(spaces);
|
| 7793 |
},
|
| 7794 |
defaultTab: function (cm) {
|
| 7795 |
+
if (cm.somethingSelected()) { cm.indentSelection("add"); }
|
| 7796 |
+
else { cm.execCommand("insertTab"); }
|
| 7797 |
},
|
| 7798 |
// Swap the two chars left and right of each selection's head.
|
| 7799 |
// Move cursor behind the two swapped characters afterwards.
|
| 7803 |
// Doesn't do anything on an empty line.
|
| 7804 |
// Doesn't do anything with non-empty selections.
|
| 7805 |
transposeChars: function (cm) { return runInOp(cm, function () {
|
| 7806 |
+
var ranges = cm.listSelections(), newSel = [];
|
| 7807 |
for (var i = 0; i < ranges.length; i++) {
|
| 7808 |
if (!ranges[i].empty()) { continue }
|
| 7809 |
+
var cur = ranges[i].head, line = getLine(cm.doc, cur.line).text;
|
| 7810 |
if (line) {
|
| 7811 |
+
if (cur.ch == line.length) { cur = new Pos(cur.line, cur.ch - 1); }
|
| 7812 |
if (cur.ch > 0) {
|
| 7813 |
+
cur = new Pos(cur.line, cur.ch + 1);
|
| 7814 |
cm.replaceRange(line.charAt(cur.ch - 1) + line.charAt(cur.ch - 2),
|
| 7815 |
+
Pos(cur.line, cur.ch - 2), cur, "+transpose");
|
| 7816 |
} else if (cur.line > cm.doc.first) {
|
| 7817 |
+
var prev = getLine(cm.doc, cur.line - 1).text;
|
| 7818 |
if (prev) {
|
| 7819 |
+
cur = new Pos(cur.line, 1);
|
| 7820 |
cm.replaceRange(line.charAt(0) + cm.doc.lineSeparator() +
|
| 7821 |
prev.charAt(prev.length - 1),
|
| 7822 |
+
Pos(cur.line - 1, prev.length - 1), cur, "+transpose");
|
| 7823 |
}
|
| 7824 |
}
|
| 7825 |
}
|
| 7826 |
+
newSel.push(new Range(cur, cur));
|
| 7827 |
}
|
| 7828 |
+
cm.setSelections(newSel);
|
| 7829 |
}); },
|
| 7830 |
newlineAndIndent: function (cm) { return runInOp(cm, function () {
|
| 7831 |
+
var sels = cm.listSelections();
|
| 7832 |
for (var i = sels.length - 1; i >= 0; i--)
|
| 7833 |
+
{ cm.replaceRange(cm.doc.lineSeparator(), sels[i].anchor, sels[i].head, "+input"); }
|
| 7834 |
+
sels = cm.listSelections();
|
| 7835 |
for (var i$1 = 0; i$1 < sels.length; i$1++)
|
| 7836 |
+
{ cm.indentLine(sels[i$1].from().line, null, true); }
|
| 7837 |
+
ensureCursorVisible(cm);
|
| 7838 |
}); },
|
| 7839 |
openLine: function (cm) { return cm.replaceSelection("\n", "start"); },
|
| 7840 |
toggleOverwrite: function (cm) { return cm.toggleOverwrite(); }
|
| 7841 |
+
};
|
| 7842 |
|
| 7843 |
|
| 7844 |
function lineStart(cm, lineN) {
|
| 7845 |
+
var line = getLine(cm.doc, lineN);
|
| 7846 |
+
var visual = visualLine(line);
|
| 7847 |
+
if (visual != line) { lineN = lineNo(visual); }
|
| 7848 |
return endOfLine(true, cm, visual, lineN, 1)
|
| 7849 |
}
|
| 7850 |
function lineEnd(cm, lineN) {
|
| 7851 |
+
var line = getLine(cm.doc, lineN);
|
| 7852 |
+
var visual = visualLineEnd(line);
|
| 7853 |
+
if (visual != line) { lineN = lineNo(visual); }
|
| 7854 |
return endOfLine(true, cm, line, lineN, -1)
|
| 7855 |
}
|
| 7856 |
function lineStartSmart(cm, pos) {
|
| 7857 |
+
var start = lineStart(cm, pos.line);
|
| 7858 |
+
var line = getLine(cm.doc, start.line);
|
| 7859 |
+
var order = getOrder(line, cm.doc.direction);
|
| 7860 |
if (!order || order[0].level == 0) {
|
| 7861 |
+
var firstNonWS = Math.max(0, line.text.search(/\S/));
|
| 7862 |
+
var inWS = pos.line == start.line && pos.ch <= firstNonWS && pos.ch;
|
| 7863 |
return Pos(start.line, inWS ? 0 : firstNonWS, start.sticky)
|
| 7864 |
}
|
| 7865 |
return start
|
| 7868 |
// Run a handler that was bound to a key.
|
| 7869 |
function doHandleBinding(cm, bound, dropShift) {
|
| 7870 |
if (typeof bound == "string") {
|
| 7871 |
+
bound = commands[bound];
|
| 7872 |
if (!bound) { return false }
|
| 7873 |
}
|
| 7874 |
// Ensure previous input has been read, so that the handler sees a
|
| 7875 |
// consistent view of the document
|
| 7876 |
+
cm.display.input.ensurePolled();
|
| 7877 |
+
var prevShift = cm.display.shift, done = false;
|
| 7878 |
try {
|
| 7879 |
+
if (cm.isReadOnly()) { cm.state.suppressEdits = true; }
|
| 7880 |
+
if (dropShift) { cm.display.shift = false; }
|
| 7881 |
+
done = bound(cm) != Pass;
|
| 7882 |
} finally {
|
| 7883 |
+
cm.display.shift = prevShift;
|
| 7884 |
+
cm.state.suppressEdits = false;
|
| 7885 |
}
|
| 7886 |
return done
|
| 7887 |
}
|
| 7888 |
|
| 7889 |
function lookupKeyForEditor(cm, name, handle) {
|
| 7890 |
for (var i = 0; i < cm.state.keyMaps.length; i++) {
|
| 7891 |
+
var result = lookupKey(name, cm.state.keyMaps[i], handle, cm);
|
| 7892 |
if (result) { return result }
|
| 7893 |
}
|
| 7894 |
return (cm.options.extraKeys && lookupKey(name, cm.options.extraKeys, handle, cm))
|
| 7895 |
|| lookupKey(name, cm.options.keyMap, handle, cm)
|
| 7896 |
}
|
| 7897 |
|
| 7898 |
+
var stopSeq = new Delayed;
|
| 7899 |
function dispatchKey(cm, name, e, handle) {
|
| 7900 |
+
var seq = cm.state.keySeq;
|
| 7901 |
if (seq) {
|
| 7902 |
if (isModifierKey(name)) { return "handled" }
|
| 7903 |
stopSeq.set(50, function () {
|
| 7904 |
if (cm.state.keySeq == seq) {
|
| 7905 |
+
cm.state.keySeq = null;
|
| 7906 |
+
cm.display.input.reset();
|
| 7907 |
}
|
| 7908 |
+
});
|
| 7909 |
+
name = seq + " " + name;
|
| 7910 |
}
|
| 7911 |
+
var result = lookupKeyForEditor(cm, name, handle);
|
| 7912 |
|
| 7913 |
if (result == "multi")
|
| 7914 |
+
{ cm.state.keySeq = name; }
|
| 7915 |
if (result == "handled")
|
| 7916 |
+
{ signalLater(cm, "keyHandled", cm, name, e); }
|
| 7917 |
|
| 7918 |
if (result == "handled" || result == "multi") {
|
| 7919 |
+
e_preventDefault(e);
|
| 7920 |
+
restartBlink(cm);
|
| 7921 |
}
|
| 7922 |
|
| 7923 |
if (seq && !result && /\'$/.test(name)) {
|
| 7924 |
+
e_preventDefault(e);
|
| 7925 |
return true
|
| 7926 |
}
|
| 7927 |
return !!result
|
| 7929 |
|
| 7930 |
// Handle a key from the keydown event.
|
| 7931 |
function handleKeyBinding(cm, e) {
|
| 7932 |
+
var name = keyName(e, true);
|
| 7933 |
if (!name) { return false }
|
| 7934 |
|
| 7935 |
if (e.shiftKey && !cm.state.keySeq) {
|
| 7951 |
return dispatchKey(cm, "'" + ch + "'", e, function (b) { return doHandleBinding(cm, b, true); })
|
| 7952 |
}
|
| 7953 |
|
| 7954 |
+
var lastStoppedKey = null;
|
| 7955 |
function onKeyDown(e) {
|
| 7956 |
+
var cm = this;
|
| 7957 |
+
cm.curOp.focus = activeElt();
|
| 7958 |
if (signalDOMEvent(cm, e)) { return }
|
| 7959 |
// IE does strange things with escape.
|
| 7960 |
+
if (ie && ie_version < 11 && e.keyCode == 27) { e.returnValue = false; }
|
| 7961 |
+
var code = e.keyCode;
|
| 7962 |
+
cm.display.shift = code == 16 || e.shiftKey;
|
| 7963 |
+
var handled = handleKeyBinding(cm, e);
|
| 7964 |
if (presto) {
|
| 7965 |
+
lastStoppedKey = handled ? code : null;
|
| 7966 |
// Opera has no cut event... we try to at least catch the key combo
|
| 7967 |
if (!handled && code == 88 && !hasCopyEvent && (mac ? e.metaKey : e.ctrlKey))
|
| 7968 |
+
{ cm.replaceSelection("", null, "cut"); }
|
| 7969 |
}
|
| 7970 |
|
| 7971 |
// Turn mouse into crosshair when Alt is held on Mac.
|
| 7972 |
if (code == 18 && !/\bCodeMirror-crosshair\b/.test(cm.display.lineDiv.className))
|
| 7973 |
+
{ showCrossHair(cm); }
|
| 7974 |
}
|
| 7975 |
|
| 7976 |
function showCrossHair(cm) {
|
| 7977 |
+
var lineDiv = cm.display.lineDiv;
|
| 7978 |
+
addClass(lineDiv, "CodeMirror-crosshair");
|
| 7979 |
|
| 7980 |
function up(e) {
|
| 7981 |
if (e.keyCode == 18 || !e.altKey) {
|
| 7982 |
+
rmClass(lineDiv, "CodeMirror-crosshair");
|
| 7983 |
+
off(document, "keyup", up);
|
| 7984 |
+
off(document, "mouseover", up);
|
| 7985 |
}
|
| 7986 |
}
|
| 7987 |
+
on(document, "keyup", up);
|
| 7988 |
+
on(document, "mouseover", up);
|
| 7989 |
}
|
| 7990 |
|
| 7991 |
function onKeyUp(e) {
|
| 7992 |
+
if (e.keyCode == 16) { this.doc.sel.shift = false; }
|
| 7993 |
+
signalDOMEvent(this, e);
|
| 7994 |
}
|
| 7995 |
|
| 7996 |
function onKeyPress(e) {
|
| 7997 |
+
var cm = this;
|
| 7998 |
if (eventInWidget(cm.display, e) || signalDOMEvent(cm, e) || e.ctrlKey && !e.altKey || mac && e.metaKey) { return }
|
| 7999 |
+
var keyCode = e.keyCode, charCode = e.charCode;
|
| 8000 |
if (presto && keyCode == lastStoppedKey) {lastStoppedKey = null; e_preventDefault(e); return}
|
| 8001 |
if ((presto && (!e.which || e.which < 10)) && handleKeyBinding(cm, e)) { return }
|
| 8002 |
+
var ch = String.fromCharCode(charCode == null ? keyCode : charCode);
|
| 8003 |
// Some browsers fire keypress events for backspace
|
| 8004 |
if (ch == "\x08") { return }
|
| 8005 |
if (handleCharBinding(cm, e, ch)) { return }
|
| 8006 |
+
cm.display.input.onKeyPress(e);
|
| 8007 |
}
|
| 8008 |
|
| 8009 |
// A mouse down can be a single click, double click, triple click,
|
| 8012 |
// middle-click-paste. Or it might be a click on something we should
|
| 8013 |
// not interfere with, such as a scrollbar or widget.
|
| 8014 |
function onMouseDown(e) {
|
| 8015 |
+
var cm = this, display = cm.display;
|
| 8016 |
if (signalDOMEvent(cm, e) || display.activeTouch && display.input.supportsTouch()) { return }
|
| 8017 |
+
display.input.ensurePolled();
|
| 8018 |
+
display.shift = e.shiftKey;
|
| 8019 |
|
| 8020 |
if (eventInWidget(display, e)) {
|
| 8021 |
if (!webkit) {
|
| 8022 |
// Briefly turn off draggability, to allow widgets to do
|
| 8023 |
// normal dragging things.
|
| 8024 |
+
display.scroller.draggable = false;
|
| 8025 |
+
setTimeout(function () { return display.scroller.draggable = true; }, 100);
|
| 8026 |
}
|
| 8027 |
return
|
| 8028 |
}
|
| 8029 |
if (clickInGutter(cm, e)) { return }
|
| 8030 |
+
var start = posFromMouse(cm, e);
|
| 8031 |
+
window.focus();
|
| 8032 |
|
| 8033 |
switch (e_button(e)) {
|
| 8034 |
case 1:
|
| 8035 |
// #3261: make sure, that we're not starting a second selection
|
| 8036 |
if (cm.state.selectingText)
|
| 8037 |
+
{ cm.state.selectingText(e); }
|
| 8038 |
else if (start)
|
| 8039 |
+
{ leftButtonDown(cm, e, start); }
|
| 8040 |
else if (e_target(e) == display.scroller)
|
| 8041 |
+
{ e_preventDefault(e); }
|
| 8042 |
break
|
| 8043 |
case 2:
|
| 8044 |
+
if (webkit) { cm.state.lastMiddleDown = +new Date; }
|
| 8045 |
+
if (start) { extendSelection(cm.doc, start); }
|
| 8046 |
+
setTimeout(function () { return display.input.focus(); }, 20);
|
| 8047 |
+
e_preventDefault(e);
|
| 8048 |
break
|
| 8049 |
case 3:
|
| 8050 |
+
if (captureRightClick) { onContextMenu(cm, e); }
|
| 8051 |
+
else { delayBlurEvent(cm); }
|
| 8052 |
break
|
| 8053 |
}
|
| 8054 |
}
|
| 8056 |
var lastClick;
|
| 8057 |
var lastDoubleClick;
|
| 8058 |
function leftButtonDown(cm, e, start) {
|
| 8059 |
+
if (ie) { setTimeout(bind(ensureFocus, cm), 0); }
|
| 8060 |
+
else { cm.curOp.focus = activeElt(); }
|
| 8061 |
|
| 8062 |
+
var now = +new Date, type;
|
| 8063 |
if (lastDoubleClick && lastDoubleClick.time > now - 400 && cmp(lastDoubleClick.pos, start) == 0) {
|
| 8064 |
+
type = "triple";
|
| 8065 |
} else if (lastClick && lastClick.time > now - 400 && cmp(lastClick.pos, start) == 0) {
|
| 8066 |
+
type = "double";
|
| 8067 |
+
lastDoubleClick = {time: now, pos: start};
|
| 8068 |
} else {
|
| 8069 |
+
type = "single";
|
| 8070 |
+
lastClick = {time: now, pos: start};
|
| 8071 |
}
|
| 8072 |
|
| 8073 |
+
var sel = cm.doc.sel, modifier = mac ? e.metaKey : e.ctrlKey, contained;
|
| 8074 |
if (cm.options.dragDrop && dragAndDrop && !cm.isReadOnly() &&
|
| 8075 |
type == "single" && (contained = sel.contains(start)) > -1 &&
|
| 8076 |
(cmp((contained = sel.ranges[contained]).from(), start) < 0 || start.xRel > 0) &&
|
| 8077 |
(cmp(contained.to(), start) > 0 || start.xRel < 0))
|
| 8078 |
+
{ leftButtonStartDrag(cm, e, start, modifier); }
|
| 8079 |
else
|
| 8080 |
+
{ leftButtonSelect(cm, e, start, type, modifier); }
|
| 8081 |
}
|
| 8082 |
|
| 8083 |
// Start a text drag. When it ends, see if any dragging actually
|
| 8084 |
// happen, and treat as a click if it didn't.
|
| 8085 |
function leftButtonStartDrag(cm, e, start, modifier) {
|
| 8086 |
+
var display = cm.display, startTime = +new Date;
|
| 8087 |
var dragEnd = operation(cm, function (e2) {
|
| 8088 |
+
if (webkit) { display.scroller.draggable = false; }
|
| 8089 |
+
cm.state.draggingText = false;
|
| 8090 |
+
off(document, "mouseup", dragEnd);
|
| 8091 |
+
off(display.scroller, "drop", dragEnd);
|
| 8092 |
if (Math.abs(e.clientX - e2.clientX) + Math.abs(e.clientY - e2.clientY) < 10) {
|
| 8093 |
+
e_preventDefault(e2);
|
| 8094 |
if (!modifier && +new Date - 200 < startTime)
|
| 8095 |
+
{ extendSelection(cm.doc, start); }
|
| 8096 |
// Work around unexplainable focus problem in IE9 (#2127) and Chrome (#3081)
|
| 8097 |
if (webkit || ie && ie_version == 9)
|
| 8098 |
+
{ setTimeout(function () {document.body.focus(); display.input.focus();}, 20); }
|
| 8099 |
else
|
| 8100 |
+
{ display.input.focus(); }
|
| 8101 |
}
|
| 8102 |
+
});
|
| 8103 |
// Let the drag handler handle this.
|
| 8104 |
+
if (webkit) { display.scroller.draggable = true; }
|
| 8105 |
+
cm.state.draggingText = dragEnd;
|
| 8106 |
+
dragEnd.copy = mac ? e.altKey : e.ctrlKey;
|
| 8107 |
// IE's approach to draggable
|
| 8108 |
+
if (display.scroller.dragDrop) { display.scroller.dragDrop(); }
|
| 8109 |
+
on(document, "mouseup", dragEnd);
|
| 8110 |
+
on(display.scroller, "drop", dragEnd);
|
| 8111 |
}
|
| 8112 |
|
| 8113 |
// Normal selection, as opposed to text dragging.
|
| 8114 |
function leftButtonSelect(cm, e, start, type, addNew) {
|
| 8115 |
+
var display = cm.display, doc = cm.doc;
|
| 8116 |
+
e_preventDefault(e);
|
| 8117 |
|
| 8118 |
+
var ourRange, ourIndex, startSel = doc.sel, ranges = startSel.ranges;
|
| 8119 |
if (addNew && !e.shiftKey) {
|
| 8120 |
+
ourIndex = doc.sel.contains(start);
|
| 8121 |
if (ourIndex > -1)
|
| 8122 |
+
{ ourRange = ranges[ourIndex]; }
|
| 8123 |
else
|
| 8124 |
+
{ ourRange = new Range(start, start); }
|
| 8125 |
} else {
|
| 8126 |
+
ourRange = doc.sel.primary();
|
| 8127 |
+
ourIndex = doc.sel.primIndex;
|
| 8128 |
}
|
| 8129 |
|
| 8130 |
if (chromeOS ? e.shiftKey && e.metaKey : e.altKey) {
|
| 8131 |
+
type = "rect";
|
| 8132 |
+
if (!addNew) { ourRange = new Range(start, start); }
|
| 8133 |
+
start = posFromMouse(cm, e, true, true);
|
| 8134 |
+
ourIndex = -1;
|
| 8135 |
} else if (type == "double") {
|
| 8136 |
+
var word = cm.findWordAt(start);
|
| 8137 |
if (cm.display.shift || doc.extend)
|
| 8138 |
+
{ ourRange = extendRange(doc, ourRange, word.anchor, word.head); }
|
| 8139 |
else
|
| 8140 |
+
{ ourRange = word; }
|
| 8141 |
} else if (type == "triple") {
|
| 8142 |
+
var line = new Range(Pos(start.line, 0), clipPos(doc, Pos(start.line + 1, 0)));
|
| 8143 |
if (cm.display.shift || doc.extend)
|
| 8144 |
+
{ ourRange = extendRange(doc, ourRange, line.anchor, line.head); }
|
| 8145 |
else
|
| 8146 |
+
{ ourRange = line; }
|
| 8147 |
} else {
|
| 8148 |
+
ourRange = extendRange(doc, ourRange, start);
|
| 8149 |
}
|
| 8150 |
|
| 8151 |
if (!addNew) {
|
| 8152 |
+
ourIndex = 0;
|
| 8153 |
+
setSelection(doc, new Selection([ourRange], 0), sel_mouse);
|
| 8154 |
+
startSel = doc.sel;
|
| 8155 |
} else if (ourIndex == -1) {
|
| 8156 |
+
ourIndex = ranges.length;
|
| 8157 |
setSelection(doc, normalizeSelection(ranges.concat([ourRange]), ourIndex),
|
| 8158 |
+
{scroll: false, origin: "*mouse"});
|
| 8159 |
} else if (ranges.length > 1 && ranges[ourIndex].empty() && type == "single" && !e.shiftKey) {
|
| 8160 |
setSelection(doc, normalizeSelection(ranges.slice(0, ourIndex).concat(ranges.slice(ourIndex + 1)), 0),
|
| 8161 |
+
{scroll: false, origin: "*mouse"});
|
| 8162 |
+
startSel = doc.sel;
|
| 8163 |
} else {
|
| 8164 |
+
replaceOneSelection(doc, ourIndex, ourRange, sel_mouse);
|
| 8165 |
}
|
| 8166 |
|
| 8167 |
+
var lastPos = start;
|
| 8168 |
function extendTo(pos) {
|
| 8169 |
if (cmp(lastPos, pos) == 0) { return }
|
| 8170 |
+
lastPos = pos;
|
| 8171 |
|
| 8172 |
if (type == "rect") {
|
| 8173 |
+
var ranges = [], tabSize = cm.options.tabSize;
|
| 8174 |
+
var startCol = countColumn(getLine(doc, start.line).text, start.ch, tabSize);
|
| 8175 |
+
var posCol = countColumn(getLine(doc, pos.line).text, pos.ch, tabSize);
|
| 8176 |
+
var left = Math.min(startCol, posCol), right = Math.max(startCol, posCol);
|
| 8177 |
for (var line = Math.min(start.line, pos.line), end = Math.min(cm.lastLine(), Math.max(start.line, pos.line));
|
| 8178 |
line <= end; line++) {
|
| 8179 |
+
var text = getLine(doc, line).text, leftPos = findColumn(text, left, tabSize);
|
| 8180 |
if (left == right)
|
| 8181 |
+
{ ranges.push(new Range(Pos(line, leftPos), Pos(line, leftPos))); }
|
| 8182 |
else if (text.length > leftPos)
|
| 8183 |
+
{ ranges.push(new Range(Pos(line, leftPos), Pos(line, findColumn(text, right, tabSize)))); }
|
| 8184 |
}
|
| 8185 |
+
if (!ranges.length) { ranges.push(new Range(start, start)); }
|
| 8186 |
setSelection(doc, normalizeSelection(startSel.ranges.slice(0, ourIndex).concat(ranges), ourIndex),
|
| 8187 |
+
{origin: "*mouse", scroll: false});
|
| 8188 |
+
cm.scrollIntoView(pos);
|
| 8189 |
} else {
|
| 8190 |
+
var oldRange = ourRange;
|
| 8191 |
+
var anchor = oldRange.anchor, head = pos;
|
| 8192 |
if (type != "single") {
|
| 8193 |
+
var range$$1;
|
| 8194 |
if (type == "double")
|
| 8195 |
+
{ range$$1 = cm.findWordAt(pos); }
|
| 8196 |
else
|
| 8197 |
+
{ range$$1 = new Range(Pos(pos.line, 0), clipPos(doc, Pos(pos.line + 1, 0))); }
|
| 8198 |
+
if (cmp(range$$1.anchor, anchor) > 0) {
|
| 8199 |
+
head = range$$1.head;
|
| 8200 |
+
anchor = minPos(oldRange.from(), range$$1.anchor);
|
| 8201 |
} else {
|
| 8202 |
+
head = range$$1.anchor;
|
| 8203 |
+
anchor = maxPos(oldRange.to(), range$$1.head);
|
| 8204 |
}
|
| 8205 |
}
|
| 8206 |
+
var ranges$1 = startSel.ranges.slice(0);
|
| 8207 |
+
ranges$1[ourIndex] = new Range(clipPos(doc, anchor), head);
|
| 8208 |
+
setSelection(doc, normalizeSelection(ranges$1, ourIndex), sel_mouse);
|
| 8209 |
}
|
| 8210 |
}
|
| 8211 |
|
| 8212 |
+
var editorSize = display.wrapper.getBoundingClientRect();
|
| 8213 |
// Used to ensure timeout re-tries don't fire when another extend
|
| 8214 |
// happened in the meantime (clearTimeout isn't reliable -- at
|
| 8215 |
// least on Chrome, the timeouts still happen even when cleared,
|
| 8216 |
// if the clear happens after their scheduled firing time).
|
| 8217 |
+
var counter = 0;
|
| 8218 |
|
| 8219 |
function extend(e) {
|
| 8220 |
+
var curCount = ++counter;
|
| 8221 |
+
var cur = posFromMouse(cm, e, true, type == "rect");
|
| 8222 |
if (!cur) { return }
|
| 8223 |
if (cmp(cur, lastPos) != 0) {
|
| 8224 |
+
cm.curOp.focus = activeElt();
|
| 8225 |
+
extendTo(cur);
|
| 8226 |
+
var visible = visibleLines(display, doc);
|
| 8227 |
if (cur.line >= visible.to || cur.line < visible.from)
|
| 8228 |
+
{ setTimeout(operation(cm, function () {if (counter == curCount) { extend(e); }}), 150); }
|
| 8229 |
} else {
|
| 8230 |
+
var outside = e.clientY < editorSize.top ? -20 : e.clientY > editorSize.bottom ? 20 : 0;
|
| 8231 |
if (outside) { setTimeout(operation(cm, function () {
|
| 8232 |
if (counter != curCount) { return }
|
| 8233 |
+
display.scroller.scrollTop += outside;
|
| 8234 |
+
extend(e);
|
| 8235 |
+
}), 50); }
|
| 8236 |
}
|
| 8237 |
}
|
| 8238 |
|
| 8239 |
function done(e) {
|
| 8240 |
+
cm.state.selectingText = false;
|
| 8241 |
+
counter = Infinity;
|
| 8242 |
+
e_preventDefault(e);
|
| 8243 |
+
display.input.focus();
|
| 8244 |
+
off(document, "mousemove", move);
|
| 8245 |
+
off(document, "mouseup", up);
|
| 8246 |
+
doc.history.lastSelOrigin = null;
|
| 8247 |
}
|
| 8248 |
|
| 8249 |
var move = operation(cm, function (e) {
|
| 8250 |
+
if (!e_button(e)) { done(e); }
|
| 8251 |
+
else { extend(e); }
|
| 8252 |
+
});
|
| 8253 |
+
var up = operation(cm, done);
|
| 8254 |
+
cm.state.selectingText = up;
|
| 8255 |
+
on(document, "mousemove", move);
|
| 8256 |
+
on(document, "mouseup", up);
|
| 8257 |
}
|
| 8258 |
|
| 8259 |
|
| 8260 |
// Determines whether an event happened in the gutter, and fires the
|
| 8261 |
// handlers for the corresponding event.
|
| 8262 |
function gutterEvent(cm, e, type, prevent) {
|
| 8263 |
+
var mX, mY;
|
| 8264 |
+
try { mX = e.clientX; mY = e.clientY; }
|
| 8265 |
catch(e) { return false }
|
| 8266 |
if (mX >= Math.floor(cm.display.gutters.getBoundingClientRect().right)) { return false }
|
| 8267 |
+
if (prevent) { e_preventDefault(e); }
|
| 8268 |
|
| 8269 |
+
var display = cm.display;
|
| 8270 |
+
var lineBox = display.lineDiv.getBoundingClientRect();
|
| 8271 |
|
| 8272 |
if (mY > lineBox.bottom || !hasHandler(cm, type)) { return e_defaultPrevented(e) }
|
| 8273 |
+
mY -= lineBox.top - display.viewOffset;
|
| 8274 |
|
| 8275 |
for (var i = 0; i < cm.options.gutters.length; ++i) {
|
| 8276 |
+
var g = display.gutters.childNodes[i];
|
| 8277 |
if (g && g.getBoundingClientRect().right >= mX) {
|
| 8278 |
+
var line = lineAtHeight(cm.doc, mY);
|
| 8279 |
+
var gutter = cm.options.gutters[i];
|
| 8280 |
+
signal(cm, type, cm, line, gutter, e);
|
| 8281 |
return e_defaultPrevented(e)
|
| 8282 |
}
|
| 8283 |
}
|
| 8295 |
function onContextMenu(cm, e) {
|
| 8296 |
if (eventInWidget(cm.display, e) || contextMenuInGutter(cm, e)) { return }
|
| 8297 |
if (signalDOMEvent(cm, e, "contextmenu")) { return }
|
| 8298 |
+
cm.display.input.onContextMenu(e);
|
| 8299 |
}
|
| 8300 |
|
| 8301 |
function contextMenuInGutter(cm, e) {
|
| 8305 |
|
| 8306 |
function themeChanged(cm) {
|
| 8307 |
cm.display.wrapper.className = cm.display.wrapper.className.replace(/\s*cm-s-\S+/g, "") +
|
| 8308 |
+
cm.options.theme.replace(/(^|\s)\s*/g, " cm-s-");
|
| 8309 |
+
clearCaches(cm);
|
| 8310 |
}
|
| 8311 |
|
| 8312 |
+
var Init = {toString: function(){return "CodeMirror.Init"}};
|
| 8313 |
|
| 8314 |
+
var defaults = {};
|
| 8315 |
+
var optionHandlers = {};
|
| 8316 |
|
| 8317 |
function defineOptions(CodeMirror) {
|
| 8318 |
+
var optionHandlers = CodeMirror.optionHandlers;
|
| 8319 |
|
| 8320 |
function option(name, deflt, handle, notOnInit) {
|
| 8321 |
+
CodeMirror.defaults[name] = deflt;
|
| 8322 |
if (handle) { optionHandlers[name] =
|
| 8323 |
+
notOnInit ? function (cm, val, old) {if (old != Init) { handle(cm, val, old); }} : handle; }
|
| 8324 |
}
|
| 8325 |
|
| 8326 |
+
CodeMirror.defineOption = option;
|
| 8327 |
|
| 8328 |
// Passed to option handlers when there is no old value.
|
| 8329 |
+
CodeMirror.Init = Init;
|
| 8330 |
|
| 8331 |
// These two are, on init, called from the constructor because they
|
| 8332 |
// have to be initialized before the editor can start at all.
|
| 8333 |
+
option("value", "", function (cm, val) { return cm.setValue(val); }, true);
|
| 8334 |
option("mode", null, function (cm, val) {
|
| 8335 |
+
cm.doc.modeOption = val;
|
| 8336 |
+
loadMode(cm);
|
| 8337 |
+
}, true);
|
| 8338 |
|
| 8339 |
+
option("indentUnit", 2, loadMode, true);
|
| 8340 |
+
option("indentWithTabs", false);
|
| 8341 |
+
option("smartIndent", true);
|
| 8342 |
option("tabSize", 4, function (cm) {
|
| 8343 |
+
resetModeState(cm);
|
| 8344 |
+
clearCaches(cm);
|
| 8345 |
+
regChange(cm);
|
| 8346 |
+
}, true);
|
| 8347 |
option("lineSeparator", null, function (cm, val) {
|
| 8348 |
+
cm.doc.lineSep = val;
|
| 8349 |
if (!val) { return }
|
| 8350 |
+
var newBreaks = [], lineNo = cm.doc.first;
|
| 8351 |
cm.doc.iter(function (line) {
|
| 8352 |
for (var pos = 0;;) {
|
| 8353 |
+
var found = line.text.indexOf(val, pos);
|
| 8354 |
if (found == -1) { break }
|
| 8355 |
+
pos = found + val.length;
|
| 8356 |
+
newBreaks.push(Pos(lineNo, found));
|
| 8357 |
}
|
| 8358 |
+
lineNo++;
|
| 8359 |
+
});
|
| 8360 |
for (var i = newBreaks.length - 1; i >= 0; i--)
|
| 8361 |
+
{ replaceRange(cm.doc, val, newBreaks[i], Pos(newBreaks[i].line, newBreaks[i].ch + val.length)); }
|
| 8362 |
+
});
|
| 8363 |
+
option("specialChars", /[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff]/g, function (cm, val, old) {
|
| 8364 |
+
cm.state.specialChars = new RegExp(val.source + (val.test("\t") ? "" : "|\t"), "g");
|
| 8365 |
+
if (old != Init) { cm.refresh(); }
|
| 8366 |
+
});
|
| 8367 |
+
option("specialCharPlaceholder", defaultSpecialCharPlaceholder, function (cm) { return cm.refresh(); }, true);
|
| 8368 |
+
option("electricChars", true);
|
| 8369 |
option("inputStyle", mobile ? "contenteditable" : "textarea", function () {
|
| 8370 |
throw new Error("inputStyle can not (yet) be changed in a running editor") // FIXME
|
| 8371 |
+
}, true);
|
| 8372 |
+
option("spellcheck", false, function (cm, val) { return cm.getInputField().spellcheck = val; }, true);
|
| 8373 |
+
option("rtlMoveVisually", !windows);
|
| 8374 |
+
option("wholeLineUpdateBefore", true);
|
| 8375 |
|
| 8376 |
option("theme", "default", function (cm) {
|
| 8377 |
+
themeChanged(cm);
|
| 8378 |
+
guttersChanged(cm);
|
| 8379 |
+
}, true);
|
| 8380 |
option("keyMap", "default", function (cm, val, old) {
|
| 8381 |
+
var next = getKeyMap(val);
|
| 8382 |
+
var prev = old != Init && getKeyMap(old);
|
| 8383 |
+
if (prev && prev.detach) { prev.detach(cm, next); }
|
| 8384 |
+
if (next.attach) { next.attach(cm, prev || null); }
|
| 8385 |
+
});
|
| 8386 |
+
option("extraKeys", null);
|
| 8387 |
|
| 8388 |
+
option("lineWrapping", false, wrappingChanged, true);
|
| 8389 |
option("gutters", [], function (cm) {
|
| 8390 |
+
setGuttersForLineNumbers(cm.options);
|
| 8391 |
+
guttersChanged(cm);
|
| 8392 |
+
}, true);
|
| 8393 |
option("fixedGutter", true, function (cm, val) {
|
| 8394 |
+
cm.display.gutters.style.left = val ? compensateForHScroll(cm.display) + "px" : "0";
|
| 8395 |
+
cm.refresh();
|
| 8396 |
+
}, true);
|
| 8397 |
+
option("coverGutterNextToScrollbar", false, function (cm) { return updateScrollbars(cm); }, true);
|
| 8398 |
option("scrollbarStyle", "native", function (cm) {
|
| 8399 |
+
initScrollbars(cm);
|
| 8400 |
+
updateScrollbars(cm);
|
| 8401 |
+
cm.display.scrollbars.setScrollTop(cm.doc.scrollTop);
|
| 8402 |
+
cm.display.scrollbars.setScrollLeft(cm.doc.scrollLeft);
|
| 8403 |
+
}, true);
|
| 8404 |
option("lineNumbers", false, function (cm) {
|
| 8405 |
+
setGuttersForLineNumbers(cm.options);
|
| 8406 |
+
guttersChanged(cm);
|
| 8407 |
+
}, true);
|
| 8408 |
+
option("firstLineNumber", 1, guttersChanged, true);
|
| 8409 |
+
option("lineNumberFormatter", function (integer) { return integer; }, guttersChanged, true);
|
| 8410 |
+
option("showCursorWhenSelecting", false, updateSelection, true);
|
| 8411 |
|
| 8412 |
+
option("resetSelectionOnContextMenu", true);
|
| 8413 |
+
option("lineWiseCopyCut", true);
|
| 8414 |
|
| 8415 |
option("readOnly", false, function (cm, val) {
|
| 8416 |
if (val == "nocursor") {
|
| 8417 |
+
onBlur(cm);
|
| 8418 |
+
cm.display.input.blur();
|
| 8419 |
+
cm.display.disabled = true;
|
| 8420 |
} else {
|
| 8421 |
+
cm.display.disabled = false;
|
| 8422 |
}
|
| 8423 |
+
cm.display.input.readOnlyChanged(val);
|
| 8424 |
+
});
|
| 8425 |
+
option("disableInput", false, function (cm, val) {if (!val) { cm.display.input.reset(); }}, true);
|
| 8426 |
+
option("dragDrop", true, dragDropChanged);
|
| 8427 |
+
option("allowDropFileTypes", null);
|
| 8428 |
+
|
| 8429 |
+
option("cursorBlinkRate", 530);
|
| 8430 |
+
option("cursorScrollMargin", 0);
|
| 8431 |
+
option("cursorHeight", 1, updateSelection, true);
|
| 8432 |
+
option("singleCursorHeightPerLine", true, updateSelection, true);
|
| 8433 |
+
option("workTime", 100);
|
| 8434 |
+
option("workDelay", 100);
|
| 8435 |
+
option("flattenSpans", true, resetModeState, true);
|
| 8436 |
+
option("addModeClass", false, resetModeState, true);
|
| 8437 |
+
option("pollInterval", 100);
|
| 8438 |
+
option("undoDepth", 200, function (cm, val) { return cm.doc.history.undoDepth = val; });
|
| 8439 |
+
option("historyEventDelay", 1250);
|
| 8440 |
+
option("viewportMargin", 10, function (cm) { return cm.refresh(); }, true);
|
| 8441 |
+
option("maxHighlightLength", 10000, resetModeState, true);
|
| 8442 |
option("moveInputWithCursor", true, function (cm, val) {
|
| 8443 |
+
if (!val) { cm.display.input.resetPosition(); }
|
| 8444 |
+
});
|
| 8445 |
|
| 8446 |
+
option("tabindex", null, function (cm, val) { return cm.display.input.getField().tabIndex = val || ""; });
|
| 8447 |
+
option("autofocus", null);
|
| 8448 |
+
option("direction", "ltr", function (cm, val) { return cm.doc.setDirection(val); }, true);
|
| 8449 |
}
|
| 8450 |
|
| 8451 |
function guttersChanged(cm) {
|
| 8452 |
+
updateGutters(cm);
|
| 8453 |
+
regChange(cm);
|
| 8454 |
+
alignHorizontally(cm);
|
| 8455 |
}
|
| 8456 |
|
| 8457 |
function dragDropChanged(cm, value, old) {
|
| 8458 |
+
var wasOn = old && old != Init;
|
| 8459 |
if (!value != !wasOn) {
|
| 8460 |
+
var funcs = cm.display.dragFunctions;
|
| 8461 |
+
var toggle = value ? on : off;
|
| 8462 |
+
toggle(cm.display.scroller, "dragstart", funcs.start);
|
| 8463 |
+
toggle(cm.display.scroller, "dragenter", funcs.enter);
|
| 8464 |
+
toggle(cm.display.scroller, "dragover", funcs.over);
|
| 8465 |
+
toggle(cm.display.scroller, "dragleave", funcs.leave);
|
| 8466 |
+
toggle(cm.display.scroller, "drop", funcs.drop);
|
| 8467 |
}
|
| 8468 |
}
|
| 8469 |
|
| 8470 |
function wrappingChanged(cm) {
|
| 8471 |
if (cm.options.lineWrapping) {
|
| 8472 |
+
addClass(cm.display.wrapper, "CodeMirror-wrap");
|
| 8473 |
+
cm.display.sizer.style.minWidth = "";
|
| 8474 |
+
cm.display.sizerWidth = null;
|
| 8475 |
} else {
|
| 8476 |
+
rmClass(cm.display.wrapper, "CodeMirror-wrap");
|
| 8477 |
+
findMaxLine(cm);
|
| 8478 |
}
|
| 8479 |
+
estimateLineHeights(cm);
|
| 8480 |
+
regChange(cm);
|
| 8481 |
+
clearCaches(cm);
|
| 8482 |
+
setTimeout(function () { return updateScrollbars(cm); }, 100);
|
| 8483 |
}
|
| 8484 |
|
| 8485 |
// A CodeMirror instance represents an editor. This is the object
|
| 8486 |
// that user code is usually dealing with.
|
| 8487 |
|
| 8488 |
+
function CodeMirror$1(place, options) {
|
| 8489 |
var this$1 = this;
|
| 8490 |
|
| 8491 |
+
if (!(this instanceof CodeMirror$1)) { return new CodeMirror$1(place, options) }
|
| 8492 |
|
| 8493 |
+
this.options = options = options ? copyObj(options) : {};
|
| 8494 |
// Determine effective options based on given values and defaults.
|
| 8495 |
+
copyObj(defaults, options, false);
|
| 8496 |
+
setGuttersForLineNumbers(options);
|
| 8497 |
+
|
| 8498 |
+
var doc = options.value;
|
| 8499 |
+
if (typeof doc == "string") { doc = new Doc(doc, options.mode, null, options.lineSeparator, options.direction); }
|
| 8500 |
+
this.doc = doc;
|
| 8501 |
+
|
| 8502 |
+
var input = new CodeMirror$1.inputStyles[options.inputStyle](this);
|
| 8503 |
+
var display = this.display = new Display(place, doc, input);
|
| 8504 |
+
display.wrapper.CodeMirror = this;
|
| 8505 |
+
updateGutters(this);
|
| 8506 |
+
themeChanged(this);
|
| 8507 |
if (options.lineWrapping)
|
| 8508 |
+
{ this.display.wrapper.className += " CodeMirror-wrap"; }
|
| 8509 |
+
initScrollbars(this);
|
| 8510 |
|
| 8511 |
this.state = {
|
| 8512 |
keyMaps: [], // stores maps added by addKeyMap
|
| 8522 |
highlight: new Delayed(), // stores highlight worker timeout
|
| 8523 |
keySeq: null, // Unfinished key sequence
|
| 8524 |
specialChars: null
|
| 8525 |
+
};
|
| 8526 |
|
| 8527 |
+
if (options.autofocus && !mobile) { display.input.focus(); }
|
| 8528 |
|
| 8529 |
// Override magic textarea content restore that IE sometimes does
|
| 8530 |
// on our hidden textarea on reload
|
| 8531 |
+
if (ie && ie_version < 11) { setTimeout(function () { return this$1.display.input.reset(true); }, 20); }
|
| 8532 |
|
| 8533 |
+
registerEventHandlers(this);
|
| 8534 |
+
ensureGlobalHandlers();
|
| 8535 |
|
| 8536 |
+
startOperation(this);
|
| 8537 |
+
this.curOp.forceUpdate = true;
|
| 8538 |
+
attachDoc(this, doc);
|
| 8539 |
|
| 8540 |
if ((options.autofocus && !mobile) || this.hasFocus())
|
| 8541 |
+
{ setTimeout(bind(onFocus, this), 20); }
|
| 8542 |
else
|
| 8543 |
+
{ onBlur(this); }
|
| 8544 |
|
| 8545 |
for (var opt in optionHandlers) { if (optionHandlers.hasOwnProperty(opt))
|
| 8546 |
+
{ optionHandlers[opt](this$1, options[opt], Init); } }
|
| 8547 |
+
maybeUpdateLineNumberWidth(this);
|
| 8548 |
+
if (options.finishInit) { options.finishInit(this); }
|
| 8549 |
+
for (var i = 0; i < initHooks.length; ++i) { initHooks[i](this$1); }
|
| 8550 |
+
endOperation(this);
|
| 8551 |
// Suppress optimizelegibility in Webkit, since it breaks text
|
| 8552 |
// measuring on line wrapping boundaries.
|
| 8553 |
if (webkit && options.lineWrapping &&
|
| 8554 |
getComputedStyle(display.lineDiv).textRendering == "optimizelegibility")
|
| 8555 |
+
{ display.lineDiv.style.textRendering = "auto"; }
|
| 8556 |
}
|
| 8557 |
|
| 8558 |
// The default configuration options.
|
| 8559 |
+
CodeMirror$1.defaults = defaults;
|
| 8560 |
// Functions to run when options are changed.
|
| 8561 |
+
CodeMirror$1.optionHandlers = optionHandlers;
|
| 8562 |
|
| 8563 |
// Attach the necessary event handlers when initializing the editor
|
| 8564 |
function registerEventHandlers(cm) {
|
| 8565 |
+
var d = cm.display;
|
| 8566 |
+
on(d.scroller, "mousedown", operation(cm, onMouseDown));
|
| 8567 |
// Older IE's will not fire a second mousedown for a double click
|
| 8568 |
if (ie && ie_version < 11)
|
| 8569 |
{ on(d.scroller, "dblclick", operation(cm, function (e) {
|
| 8570 |
if (signalDOMEvent(cm, e)) { return }
|
| 8571 |
+
var pos = posFromMouse(cm, e);
|
| 8572 |
if (!pos || clickInGutter(cm, e) || eventInWidget(cm.display, e)) { return }
|
| 8573 |
+
e_preventDefault(e);
|
| 8574 |
+
var word = cm.findWordAt(pos);
|
| 8575 |
+
extendSelection(cm.doc, word.anchor, word.head);
|
| 8576 |
+
})); }
|
| 8577 |
else
|
| 8578 |
+
{ on(d.scroller, "dblclick", function (e) { return signalDOMEvent(cm, e) || e_preventDefault(e); }); }
|
| 8579 |
// Some browsers fire contextmenu *after* opening the menu, at
|
| 8580 |
// which point we can't mess with it anymore. Context menu is
|
| 8581 |
// handled in onMouseDown for these browsers.
|
| 8582 |
+
if (!captureRightClick) { on(d.scroller, "contextmenu", function (e) { return onContextMenu(cm, e); }); }
|
| 8583 |
|
| 8584 |
// Used to suppress mouse event handling when a touch happens
|
| 8585 |
+
var touchFinished, prevTouch = {end: 0};
|
| 8586 |
function finishTouch() {
|
| 8587 |
if (d.activeTouch) {
|
| 8588 |
+
touchFinished = setTimeout(function () { return d.activeTouch = null; }, 1000);
|
| 8589 |
+
prevTouch = d.activeTouch;
|
| 8590 |
+
prevTouch.end = +new Date;
|
| 8591 |
}
|
| 8592 |
}
|
| 8593 |
function isMouseLikeTouchEvent(e) {
|
| 8594 |
if (e.touches.length != 1) { return false }
|
| 8595 |
+
var touch = e.touches[0];
|
| 8596 |
return touch.radiusX <= 1 && touch.radiusY <= 1
|
| 8597 |
}
|
| 8598 |
function farAway(touch, other) {
|
| 8599 |
if (other.left == null) { return true }
|
| 8600 |
+
var dx = other.left - touch.left, dy = other.top - touch.top;
|
| 8601 |
return dx * dx + dy * dy > 20 * 20
|
| 8602 |
}
|
| 8603 |
on(d.scroller, "touchstart", function (e) {
|
| 8604 |
if (!signalDOMEvent(cm, e) && !isMouseLikeTouchEvent(e)) {
|
| 8605 |
+
d.input.ensurePolled();
|
| 8606 |
+
clearTimeout(touchFinished);
|
| 8607 |
+
var now = +new Date;
|
| 8608 |
d.activeTouch = {start: now, moved: false,
|
| 8609 |
+
prev: now - prevTouch.end <= 300 ? prevTouch : null};
|
| 8610 |
if (e.touches.length == 1) {
|
| 8611 |
+
d.activeTouch.left = e.touches[0].pageX;
|
| 8612 |
+
d.activeTouch.top = e.touches[0].pageY;
|
| 8613 |
}
|
| 8614 |
}
|
| 8615 |
+
});
|
| 8616 |
on(d.scroller, "touchmove", function () {
|
| 8617 |
+
if (d.activeTouch) { d.activeTouch.moved = true; }
|
| 8618 |
+
});
|
| 8619 |
on(d.scroller, "touchend", function (e) {
|
| 8620 |
+
var touch = d.activeTouch;
|
| 8621 |
if (touch && !eventInWidget(d, e) && touch.left != null &&
|
| 8622 |
!touch.moved && new Date - touch.start < 300) {
|
| 8623 |
+
var pos = cm.coordsChar(d.activeTouch, "page"), range;
|
| 8624 |
if (!touch.prev || farAway(touch, touch.prev)) // Single tap
|
| 8625 |
+
{ range = new Range(pos, pos); }
|
| 8626 |
else if (!touch.prev.prev || farAway(touch, touch.prev.prev)) // Double tap
|
| 8627 |
+
{ range = cm.findWordAt(pos); }
|
| 8628 |
else // Triple tap
|
| 8629 |
+
{ range = new Range(Pos(pos.line, 0), clipPos(cm.doc, Pos(pos.line + 1, 0))); }
|
| 8630 |
+
cm.setSelection(range.anchor, range.head);
|
| 8631 |
+
cm.focus();
|
| 8632 |
+
e_preventDefault(e);
|
| 8633 |
}
|
| 8634 |
+
finishTouch();
|
| 8635 |
+
});
|
| 8636 |
+
on(d.scroller, "touchcancel", finishTouch);
|
| 8637 |
|
| 8638 |
// Sync scrolling between fake scrollbars and real scrollable
|
| 8639 |
// area, ensure viewport is updated when scrolling.
|
| 8640 |
on(d.scroller, "scroll", function () {
|
| 8641 |
if (d.scroller.clientHeight) {
|
| 8642 |
+
setScrollTop(cm, d.scroller.scrollTop);
|
| 8643 |
+
setScrollLeft(cm, d.scroller.scrollLeft, true);
|
| 8644 |
+
signal(cm, "scroll", cm);
|
| 8645 |
}
|
| 8646 |
+
});
|
| 8647 |
|
| 8648 |
// Listen to wheel events in order to try and update the viewport on time.
|
| 8649 |
+
on(d.scroller, "mousewheel", function (e) { return onScrollWheel(cm, e); });
|
| 8650 |
+
on(d.scroller, "DOMMouseScroll", function (e) { return onScrollWheel(cm, e); });
|
| 8651 |
|
| 8652 |
// Prevent wrapper from ever scrolling
|
| 8653 |
+
on(d.wrapper, "scroll", function () { return d.wrapper.scrollTop = d.wrapper.scrollLeft = 0; });
|
| 8654 |
|
| 8655 |
d.dragFunctions = {
|
| 8656 |
+
enter: function (e) {if (!signalDOMEvent(cm, e)) { e_stop(e); }},
|
| 8657 |
+
over: function (e) {if (!signalDOMEvent(cm, e)) { onDragOver(cm, e); e_stop(e); }},
|
| 8658 |
start: function (e) { return onDragStart(cm, e); },
|
| 8659 |
drop: operation(cm, onDrop),
|
| 8660 |
+
leave: function (e) {if (!signalDOMEvent(cm, e)) { clearDragCursor(cm); }}
|
| 8661 |
+
};
|
| 8662 |
|
| 8663 |
+
var inp = d.input.getField();
|
| 8664 |
+
on(inp, "keyup", function (e) { return onKeyUp.call(cm, e); });
|
| 8665 |
+
on(inp, "keydown", operation(cm, onKeyDown));
|
| 8666 |
+
on(inp, "keypress", operation(cm, onKeyPress));
|
| 8667 |
+
on(inp, "focus", function (e) { return onFocus(cm, e); });
|
| 8668 |
+
on(inp, "blur", function (e) { return onBlur(cm, e); });
|
| 8669 |
}
|
| 8670 |
|
| 8671 |
+
var initHooks = [];
|
| 8672 |
+
CodeMirror$1.defineInitHook = function (f) { return initHooks.push(f); };
|
| 8673 |
|
| 8674 |
// Indent the given line. The how parameter can be "smart",
|
| 8675 |
// "add"/null, "subtract", or "prev". When aggressive is false
|
| 8677 |
// lines are not indented, and places where the mode returns Pass
|
| 8678 |
// are left alone.
|
| 8679 |
function indentLine(cm, n, how, aggressive) {
|
| 8680 |
+
var doc = cm.doc, state;
|
| 8681 |
+
if (how == null) { how = "add"; }
|
| 8682 |
if (how == "smart") {
|
| 8683 |
// Fall back to "prev" when the mode doesn't have an indentation
|
| 8684 |
// method.
|
| 8685 |
+
if (!doc.mode.indent) { how = "prev"; }
|
| 8686 |
+
else { state = getStateBefore(cm, n); }
|
| 8687 |
}
|
| 8688 |
|
| 8689 |
+
var tabSize = cm.options.tabSize;
|
| 8690 |
+
var line = getLine(doc, n), curSpace = countColumn(line.text, null, tabSize);
|
| 8691 |
+
if (line.stateAfter) { line.stateAfter = null; }
|
| 8692 |
+
var curSpaceString = line.text.match(/^\s*/)[0], indentation;
|
| 8693 |
if (!aggressive && !/\S/.test(line.text)) {
|
| 8694 |
+
indentation = 0;
|
| 8695 |
+
how = "not";
|
| 8696 |
} else if (how == "smart") {
|
| 8697 |
+
indentation = doc.mode.indent(state, line.text.slice(curSpaceString.length), line.text);
|
| 8698 |
if (indentation == Pass || indentation > 150) {
|
| 8699 |
if (!aggressive) { return }
|
| 8700 |
+
how = "prev";
|
| 8701 |
}
|
| 8702 |
}
|
| 8703 |
if (how == "prev") {
|
| 8704 |
+
if (n > doc.first) { indentation = countColumn(getLine(doc, n-1).text, null, tabSize); }
|
| 8705 |
+
else { indentation = 0; }
|
| 8706 |
} else if (how == "add") {
|
| 8707 |
+
indentation = curSpace + cm.options.indentUnit;
|
| 8708 |
} else if (how == "subtract") {
|
| 8709 |
+
indentation = curSpace - cm.options.indentUnit;
|
| 8710 |
} else if (typeof how == "number") {
|
| 8711 |
+
indentation = curSpace + how;
|
| 8712 |
}
|
| 8713 |
+
indentation = Math.max(0, indentation);
|
| 8714 |
|
| 8715 |
+
var indentString = "", pos = 0;
|
| 8716 |
if (cm.options.indentWithTabs)
|
| 8717 |
+
{ for (var i = Math.floor(indentation / tabSize); i; --i) {pos += tabSize; indentString += "\t";} }
|
| 8718 |
+
if (pos < indentation) { indentString += spaceStr(indentation - pos); }
|
| 8719 |
|
| 8720 |
if (indentString != curSpaceString) {
|
| 8721 |
+
replaceRange(doc, indentString, Pos(n, 0), Pos(n, curSpaceString.length), "+input");
|
| 8722 |
+
line.stateAfter = null;
|
| 8723 |
return true
|
| 8724 |
} else {
|
| 8725 |
// Ensure that, if the cursor was in the whitespace at the start
|
| 8726 |
// of the line, it is moved to the end of that space.
|
| 8727 |
for (var i$1 = 0; i$1 < doc.sel.ranges.length; i$1++) {
|
| 8728 |
+
var range = doc.sel.ranges[i$1];
|
| 8729 |
if (range.head.line == n && range.head.ch < curSpaceString.length) {
|
| 8730 |
+
var pos$1 = Pos(n, curSpaceString.length);
|
| 8731 |
+
replaceOneSelection(doc, i$1, new Range(pos$1, pos$1));
|
| 8732 |
break
|
| 8733 |
}
|
| 8734 |
}
|
| 8738 |
// This will be set to a {lineWise: bool, text: [string]} object, so
|
| 8739 |
// that, when pasting, we know what kind of selections the copied
|
| 8740 |
// text was made out of.
|
| 8741 |
+
var lastCopied = null;
|
| 8742 |
|
| 8743 |
function setLastCopied(newLastCopied) {
|
| 8744 |
+
lastCopied = newLastCopied;
|
| 8745 |
}
|
| 8746 |
|
| 8747 |
function applyTextInput(cm, inserted, deleted, sel, origin) {
|
| 8748 |
+
var doc = cm.doc;
|
| 8749 |
+
cm.display.shift = false;
|
| 8750 |
+
if (!sel) { sel = doc.sel; }
|
| 8751 |
|
| 8752 |
+
var paste = cm.state.pasteIncoming || origin == "paste";
|
| 8753 |
+
var textLines = splitLinesAuto(inserted), multiPaste = null;
|
| 8754 |
// When pasing N lines into N selections, insert one line per selection
|
| 8755 |
if (paste && sel.ranges.length > 1) {
|
| 8756 |
if (lastCopied && lastCopied.text.join("\n") == inserted) {
|
| 8757 |
if (sel.ranges.length % lastCopied.text.length == 0) {
|
| 8758 |
+
multiPaste = [];
|
| 8759 |
for (var i = 0; i < lastCopied.text.length; i++)
|
| 8760 |
+
{ multiPaste.push(doc.splitLines(lastCopied.text[i])); }
|
| 8761 |
}
|
| 8762 |
} else if (textLines.length == sel.ranges.length) {
|
| 8763 |
+
multiPaste = map(textLines, function (l) { return [l]; });
|
| 8764 |
}
|
| 8765 |
}
|
| 8766 |
|
| 8767 |
+
var updateInput;
|
| 8768 |
// Normal behavior is to insert the new text into every selection
|
| 8769 |
for (var i$1 = sel.ranges.length - 1; i$1 >= 0; i$1--) {
|
| 8770 |
+
var range$$1 = sel.ranges[i$1];
|
| 8771 |
+
var from = range$$1.from(), to = range$$1.to();
|
| 8772 |
+
if (range$$1.empty()) {
|
| 8773 |
if (deleted && deleted > 0) // Handle deletion
|
| 8774 |
+
{ from = Pos(from.line, from.ch - deleted); }
|
| 8775 |
else if (cm.state.overwrite && !paste) // Handle overwrite
|
| 8776 |
+
{ to = Pos(to.line, Math.min(getLine(doc, to.line).text.length, to.ch + lst(textLines).length)); }
|
| 8777 |
else if (lastCopied && lastCopied.lineWise && lastCopied.text.join("\n") == inserted)
|
| 8778 |
+
{ from = to = Pos(from.line, 0); }
|
| 8779 |
}
|
| 8780 |
+
updateInput = cm.curOp.updateInput;
|
| 8781 |
var changeEvent = {from: from, to: to, text: multiPaste ? multiPaste[i$1 % multiPaste.length] : textLines,
|
| 8782 |
+
origin: origin || (paste ? "paste" : cm.state.cutIncoming ? "cut" : "+input")};
|
| 8783 |
+
makeChange(cm.doc, changeEvent);
|
| 8784 |
+
signalLater(cm, "inputRead", cm, changeEvent);
|
| 8785 |
}
|
| 8786 |
if (inserted && !paste)
|
| 8787 |
+
{ triggerElectric(cm, inserted); }
|
| 8788 |
|
| 8789 |
+
ensureCursorVisible(cm);
|
| 8790 |
+
cm.curOp.updateInput = updateInput;
|
| 8791 |
+
cm.curOp.typing = true;
|
| 8792 |
+
cm.state.pasteIncoming = cm.state.cutIncoming = false;
|
| 8793 |
}
|
| 8794 |
|
| 8795 |
function handlePaste(e, cm) {
|
| 8796 |
+
var pasted = e.clipboardData && e.clipboardData.getData("Text");
|
| 8797 |
if (pasted) {
|
| 8798 |
+
e.preventDefault();
|
| 8799 |
if (!cm.isReadOnly() && !cm.options.disableInput)
|
| 8800 |
+
{ runInOp(cm, function () { return applyTextInput(cm, pasted, 0, null, "paste"); }); }
|
| 8801 |
return true
|
| 8802 |
}
|
| 8803 |
}
|
| 8805 |
function triggerElectric(cm, inserted) {
|
| 8806 |
// When an 'electric' character is inserted, immediately trigger a reindent
|
| 8807 |
if (!cm.options.electricChars || !cm.options.smartIndent) { return }
|
| 8808 |
+
var sel = cm.doc.sel;
|
| 8809 |
|
| 8810 |
for (var i = sel.ranges.length - 1; i >= 0; i--) {
|
| 8811 |
+
var range$$1 = sel.ranges[i];
|
| 8812 |
+
if (range$$1.head.ch > 100 || (i && sel.ranges[i - 1].head.line == range$$1.head.line)) { continue }
|
| 8813 |
+
var mode = cm.getModeAt(range$$1.head);
|
| 8814 |
+
var indented = false;
|
| 8815 |
if (mode.electricChars) {
|
| 8816 |
for (var j = 0; j < mode.electricChars.length; j++)
|
| 8817 |
{ if (inserted.indexOf(mode.electricChars.charAt(j)) > -1) {
|
| 8818 |
+
indented = indentLine(cm, range$$1.head.line, "smart");
|
| 8819 |
break
|
| 8820 |
} }
|
| 8821 |
} else if (mode.electricInput) {
|
| 8822 |
+
if (mode.electricInput.test(getLine(cm.doc, range$$1.head.line).text.slice(0, range$$1.head.ch)))
|
| 8823 |
+
{ indented = indentLine(cm, range$$1.head.line, "smart"); }
|
| 8824 |
}
|
| 8825 |
+
if (indented) { signalLater(cm, "electricInput", cm, range$$1.head.line); }
|
| 8826 |
}
|
| 8827 |
}
|
| 8828 |
|
| 8829 |
function copyableRanges(cm) {
|
| 8830 |
+
var text = [], ranges = [];
|
| 8831 |
for (var i = 0; i < cm.doc.sel.ranges.length; i++) {
|
| 8832 |
+
var line = cm.doc.sel.ranges[i].head.line;
|
| 8833 |
+
var lineRange = {anchor: Pos(line, 0), head: Pos(line + 1, 0)};
|
| 8834 |
+
ranges.push(lineRange);
|
| 8835 |
+
text.push(cm.getRange(lineRange.anchor, lineRange.head));
|
| 8836 |
}
|
| 8837 |
return {text: text, ranges: ranges}
|
| 8838 |
}
|
| 8839 |
|
| 8840 |
function disableBrowserMagic(field, spellcheck) {
|
| 8841 |
+
field.setAttribute("autocorrect", "off");
|
| 8842 |
+
field.setAttribute("autocapitalize", "off");
|
| 8843 |
+
field.setAttribute("spellcheck", !!spellcheck);
|
| 8844 |
}
|
| 8845 |
|
| 8846 |
function hiddenTextarea() {
|
| 8847 |
+
var te = elt("textarea", null, null, "position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none");
|
| 8848 |
+
var div = elt("div", [te], null, "overflow: hidden; position: relative; width: 3px; height: 0px;");
|
| 8849 |
// The textarea is kept positioned near the cursor to prevent the
|
| 8850 |
// fact that it'll be scrolled into view on input from scrolling
|
| 8851 |
// our fake cursor out of view. On webkit, when wrap=off, paste is
|
| 8852 |
// very slow. So make the area wide instead.
|
| 8853 |
+
if (webkit) { te.style.width = "1000px"; }
|
| 8854 |
+
else { te.setAttribute("wrap", "off"); }
|
| 8855 |
// If border: 0; -- iOS fails to open keyboard (issue #1287)
|
| 8856 |
+
if (ios) { te.style.border = "1px solid black"; }
|
| 8857 |
+
disableBrowserMagic(te);
|
| 8858 |
return div
|
| 8859 |
}
|
| 8860 |
|
| 8866 |
// CodeMirror.prototype, for backwards compatibility and
|
| 8867 |
// convenience.
|
| 8868 |
|
| 8869 |
+
var addEditorMethods = function(CodeMirror) {
|
| 8870 |
+
var optionHandlers = CodeMirror.optionHandlers;
|
| 8871 |
|
| 8872 |
+
var helpers = CodeMirror.helpers = {};
|
| 8873 |
|
| 8874 |
CodeMirror.prototype = {
|
| 8875 |
constructor: CodeMirror,
|
| 8876 |
+
focus: function(){window.focus(); this.display.input.focus();},
|
| 8877 |
|
| 8878 |
setOption: function(option, value) {
|
| 8879 |
+
var options = this.options, old = options[option];
|
| 8880 |
if (options[option] == value && option != "mode") { return }
|
| 8881 |
+
options[option] = value;
|
| 8882 |
if (optionHandlers.hasOwnProperty(option))
|
| 8883 |
+
{ operation(this, optionHandlers[option])(this, value, old); }
|
| 8884 |
+
signal(this, "optionChange", this, option);
|
| 8885 |
},
|
| 8886 |
|
| 8887 |
getOption: function(option) {return this.options[option]},
|
| 8888 |
getDoc: function() {return this.doc},
|
| 8889 |
|
| 8890 |
+
addKeyMap: function(map$$1, bottom) {
|
| 8891 |
+
this.state.keyMaps[bottom ? "push" : "unshift"](getKeyMap(map$$1));
|
| 8892 |
},
|
| 8893 |
+
removeKeyMap: function(map$$1) {
|
| 8894 |
+
var maps = this.state.keyMaps;
|
| 8895 |
for (var i = 0; i < maps.length; ++i)
|
| 8896 |
+
{ if (maps[i] == map$$1 || maps[i].name == map$$1) {
|
| 8897 |
+
maps.splice(i, 1);
|
| 8898 |
return true
|
| 8899 |
} }
|
| 8900 |
},
|
| 8901 |
|
| 8902 |
addOverlay: methodOp(function(spec, options) {
|
| 8903 |
+
var mode = spec.token ? spec : CodeMirror.getMode(this.options, spec);
|
| 8904 |
if (mode.startState) { throw new Error("Overlays may not be stateful.") }
|
| 8905 |
insertSorted(this.state.overlays,
|
| 8906 |
{mode: mode, modeSpec: spec, opaque: options && options.opaque,
|
| 8907 |
priority: (options && options.priority) || 0},
|
| 8908 |
+
function (overlay) { return overlay.priority; });
|
| 8909 |
+
this.state.modeGen++;
|
| 8910 |
+
regChange(this);
|
| 8911 |
}),
|
| 8912 |
removeOverlay: methodOp(function(spec) {
|
| 8913 |
var this$1 = this;
|
| 8914 |
|
| 8915 |
+
var overlays = this.state.overlays;
|
| 8916 |
for (var i = 0; i < overlays.length; ++i) {
|
| 8917 |
+
var cur = overlays[i].modeSpec;
|
| 8918 |
if (cur == spec || typeof spec == "string" && cur.name == spec) {
|
| 8919 |
+
overlays.splice(i, 1);
|
| 8920 |
+
this$1.state.modeGen++;
|
| 8921 |
+
regChange(this$1);
|
| 8922 |
return
|
| 8923 |
}
|
| 8924 |
}
|
| 8926 |
|
| 8927 |
indentLine: methodOp(function(n, dir, aggressive) {
|
| 8928 |
if (typeof dir != "string" && typeof dir != "number") {
|
| 8929 |
+
if (dir == null) { dir = this.options.smartIndent ? "smart" : "prev"; }
|
| 8930 |
+
else { dir = dir ? "add" : "subtract"; }
|
| 8931 |
}
|
| 8932 |
+
if (isLine(this.doc, n)) { indentLine(this, n, dir, aggressive); }
|
| 8933 |
}),
|
| 8934 |
indentSelection: methodOp(function(how) {
|
| 8935 |
var this$1 = this;
|
| 8936 |
|
| 8937 |
+
var ranges = this.doc.sel.ranges, end = -1;
|
| 8938 |
for (var i = 0; i < ranges.length; i++) {
|
| 8939 |
+
var range$$1 = ranges[i];
|
| 8940 |
+
if (!range$$1.empty()) {
|
| 8941 |
+
var from = range$$1.from(), to = range$$1.to();
|
| 8942 |
+
var start = Math.max(end, from.line);
|
| 8943 |
+
end = Math.min(this$1.lastLine(), to.line - (to.ch ? 0 : 1)) + 1;
|
| 8944 |
for (var j = start; j < end; ++j)
|
| 8945 |
+
{ indentLine(this$1, j, how); }
|
| 8946 |
+
var newRanges = this$1.doc.sel.ranges;
|
| 8947 |
if (from.ch == 0 && ranges.length == newRanges.length && newRanges[i].from().ch > 0)
|
| 8948 |
+
{ replaceOneSelection(this$1.doc, i, new Range(from, newRanges[i].to()), sel_dontScroll); }
|
| 8949 |
+
} else if (range$$1.head.line > end) {
|
| 8950 |
+
indentLine(this$1, range$$1.head.line, how, true);
|
| 8951 |
+
end = range$$1.head.line;
|
| 8952 |
+
if (i == this$1.doc.sel.primIndex) { ensureCursorVisible(this$1); }
|
| 8953 |
}
|
| 8954 |
}
|
| 8955 |
}),
|
| 8965 |
},
|
| 8966 |
|
| 8967 |
getTokenTypeAt: function(pos) {
|
| 8968 |
+
pos = clipPos(this.doc, pos);
|
| 8969 |
+
var styles = getLineStyles(this, getLine(this.doc, pos.line));
|
| 8970 |
+
var before = 0, after = (styles.length - 1) / 2, ch = pos.ch;
|
| 8971 |
+
var type;
|
| 8972 |
+
if (ch == 0) { type = styles[2]; }
|
| 8973 |
else { for (;;) {
|
| 8974 |
+
var mid = (before + after) >> 1;
|
| 8975 |
+
if ((mid ? styles[mid * 2 - 1] : 0) >= ch) { after = mid; }
|
| 8976 |
+
else if (styles[mid * 2 + 1] < ch) { before = mid + 1; }
|
| 8977 |
else { type = styles[mid * 2 + 2]; break }
|
| 8978 |
} }
|
| 8979 |
+
var cut = type ? type.indexOf("overlay ") : -1;
|
| 8980 |
return cut < 0 ? type : cut == 0 ? null : type.slice(0, cut - 1)
|
| 8981 |
},
|
| 8982 |
|
| 8983 |
getModeAt: function(pos) {
|
| 8984 |
+
var mode = this.doc.mode;
|
| 8985 |
if (!mode.innerMode) { return mode }
|
| 8986 |
return CodeMirror.innerMode(mode, this.getTokenAt(pos).state).mode
|
| 8987 |
},
|
| 8993 |
getHelpers: function(pos, type) {
|
| 8994 |
var this$1 = this;
|
| 8995 |
|
| 8996 |
+
var found = [];
|
| 8997 |
if (!helpers.hasOwnProperty(type)) { return found }
|
| 8998 |
+
var help = helpers[type], mode = this.getModeAt(pos);
|
| 8999 |
if (typeof mode[type] == "string") {
|
| 9000 |
+
if (help[mode[type]]) { found.push(help[mode[type]]); }
|
| 9001 |
} else if (mode[type]) {
|
| 9002 |
for (var i = 0; i < mode[type].length; i++) {
|
| 9003 |
+
var val = help[mode[type][i]];
|
| 9004 |
+
if (val) { found.push(val); }
|
| 9005 |
}
|
| 9006 |
} else if (mode.helperType && help[mode.helperType]) {
|
| 9007 |
+
found.push(help[mode.helperType]);
|
| 9008 |
} else if (help[mode.name]) {
|
| 9009 |
+
found.push(help[mode.name]);
|
| 9010 |
}
|
| 9011 |
for (var i$1 = 0; i$1 < help._global.length; i$1++) {
|
| 9012 |
+
var cur = help._global[i$1];
|
| 9013 |
if (cur.pred(mode, this$1) && indexOf(found, cur.val) == -1)
|
| 9014 |
+
{ found.push(cur.val); }
|
| 9015 |
}
|
| 9016 |
return found
|
| 9017 |
},
|
| 9018 |
|
| 9019 |
getStateAfter: function(line, precise) {
|
| 9020 |
+
var doc = this.doc;
|
| 9021 |
+
line = clipLine(doc, line == null ? doc.first + doc.size - 1: line);
|
| 9022 |
return getStateBefore(this, line + 1, precise)
|
| 9023 |
},
|
| 9024 |
|
| 9025 |
cursorCoords: function(start, mode) {
|
| 9026 |
+
var pos, range$$1 = this.doc.sel.primary();
|
| 9027 |
+
if (start == null) { pos = range$$1.head; }
|
| 9028 |
+
else if (typeof start == "object") { pos = clipPos(this.doc, start); }
|
| 9029 |
+
else { pos = start ? range$$1.from() : range$$1.to(); }
|
| 9030 |
return cursorCoords(this, pos, mode || "page")
|
| 9031 |
},
|
| 9032 |
|
| 9035 |
},
|
| 9036 |
|
| 9037 |
coordsChar: function(coords, mode) {
|
| 9038 |
+
coords = fromCoordSystem(this, coords, mode || "page");
|
| 9039 |
return coordsChar(this, coords.left, coords.top)
|
| 9040 |
},
|
| 9041 |
|
| 9042 |
lineAtHeight: function(height, mode) {
|
| 9043 |
+
height = fromCoordSystem(this, {top: height, left: 0}, mode || "page").top;
|
| 9044 |
return lineAtHeight(this.doc, height + this.display.viewOffset)
|
| 9045 |
},
|
| 9046 |
heightAtLine: function(line, mode, includeWidgets) {
|
| 9047 |
+
var end = false, lineObj;
|
| 9048 |
if (typeof line == "number") {
|
| 9049 |
+
var last = this.doc.first + this.doc.size - 1;
|
| 9050 |
+
if (line < this.doc.first) { line = this.doc.first; }
|
| 9051 |
+
else if (line > last) { line = last; end = true; }
|
| 9052 |
+
lineObj = getLine(this.doc, line);
|
| 9053 |
} else {
|
| 9054 |
+
lineObj = line;
|
| 9055 |
}
|
| 9056 |
return intoCoordSystem(this, lineObj, {top: 0, left: 0}, mode || "page", includeWidgets || end).top +
|
| 9057 |
(end ? this.doc.height - heightAtLine(lineObj) : 0)
|
| 9063 |
getViewport: function() { return {from: this.display.viewFrom, to: this.display.viewTo}},
|
| 9064 |
|
| 9065 |
addWidget: function(pos, node, scroll, vert, horiz) {
|
| 9066 |
+
var display = this.display;
|
| 9067 |
+
pos = cursorCoords(this, clipPos(this.doc, pos));
|
| 9068 |
+
var top = pos.bottom, left = pos.left;
|
| 9069 |
+
node.style.position = "absolute";
|
| 9070 |
+
node.setAttribute("cm-ignore-events", "true");
|
| 9071 |
+
this.display.input.setUneditable(node);
|
| 9072 |
+
display.sizer.appendChild(node);
|
| 9073 |
if (vert == "over") {
|
| 9074 |
+
top = pos.top;
|
| 9075 |
} else if (vert == "above" || vert == "near") {
|
| 9076 |
var vspace = Math.max(display.wrapper.clientHeight, this.doc.height),
|
| 9077 |
+
hspace = Math.max(display.sizer.clientWidth, display.lineSpace.clientWidth);
|
| 9078 |
// Default to positioning above (if specified and possible); otherwise default to positioning below
|
| 9079 |
if ((vert == 'above' || pos.bottom + node.offsetHeight > vspace) && pos.top > node.offsetHeight)
|
| 9080 |
+
{ top = pos.top - node.offsetHeight; }
|
| 9081 |
else if (pos.bottom + node.offsetHeight <= vspace)
|
| 9082 |
+
{ top = pos.bottom; }
|
| 9083 |
if (left + node.offsetWidth > hspace)
|
| 9084 |
+
{ left = hspace - node.offsetWidth; }
|
| 9085 |
}
|
| 9086 |
+
node.style.top = top + "px";
|
| 9087 |
+
node.style.left = node.style.right = "";
|
| 9088 |
if (horiz == "right") {
|
| 9089 |
+
left = display.sizer.clientWidth - node.offsetWidth;
|
| 9090 |
+
node.style.right = "0px";
|
| 9091 |
} else {
|
| 9092 |
+
if (horiz == "left") { left = 0; }
|
| 9093 |
+
else if (horiz == "middle") { left = (display.sizer.clientWidth - node.offsetWidth) / 2; }
|
| 9094 |
+
node.style.left = left + "px";
|
| 9095 |
}
|
| 9096 |
if (scroll)
|
| 9097 |
+
{ scrollIntoView(this, {left: left, top: top, right: left + node.offsetWidth, bottom: top + node.offsetHeight}); }
|
| 9098 |
},
|
| 9099 |
|
| 9100 |
triggerOnKeyDown: methodOp(onKeyDown),
|
| 9106 |
{ return commands[cmd].call(null, this) }
|
| 9107 |
},
|
| 9108 |
|
| 9109 |
+
triggerElectric: methodOp(function(text) { triggerElectric(this, text); }),
|
| 9110 |
|
| 9111 |
findPosH: function(from, amount, unit, visually) {
|
| 9112 |
var this$1 = this;
|
| 9113 |
|
| 9114 |
+
var dir = 1;
|
| 9115 |
+
if (amount < 0) { dir = -1; amount = -amount; }
|
| 9116 |
+
var cur = clipPos(this.doc, from);
|
| 9117 |
for (var i = 0; i < amount; ++i) {
|
| 9118 |
+
cur = findPosH(this$1.doc, cur, dir, unit, visually);
|
| 9119 |
if (cur.hitSide) { break }
|
| 9120 |
}
|
| 9121 |
return cur
|
| 9124 |
moveH: methodOp(function(dir, unit) {
|
| 9125 |
var this$1 = this;
|
| 9126 |
|
| 9127 |
+
this.extendSelectionsBy(function (range$$1) {
|
| 9128 |
+
if (this$1.display.shift || this$1.doc.extend || range$$1.empty())
|
| 9129 |
+
{ return findPosH(this$1.doc, range$$1.head, dir, unit, this$1.options.rtlMoveVisually) }
|
| 9130 |
else
|
| 9131 |
+
{ return dir < 0 ? range$$1.from() : range$$1.to() }
|
| 9132 |
+
}, sel_move);
|
| 9133 |
}),
|
| 9134 |
|
| 9135 |
deleteH: methodOp(function(dir, unit) {
|
| 9136 |
+
var sel = this.doc.sel, doc = this.doc;
|
| 9137 |
if (sel.somethingSelected())
|
| 9138 |
+
{ doc.replaceSelection("", null, "+delete"); }
|
| 9139 |
else
|
| 9140 |
+
{ deleteNearSelection(this, function (range$$1) {
|
| 9141 |
+
var other = findPosH(doc, range$$1.head, dir, unit, false);
|
| 9142 |
+
return dir < 0 ? {from: other, to: range$$1.head} : {from: range$$1.head, to: other}
|
| 9143 |
+
}); }
|
| 9144 |
}),
|
| 9145 |
|
| 9146 |
findPosV: function(from, amount, unit, goalColumn) {
|
| 9147 |
var this$1 = this;
|
| 9148 |
|
| 9149 |
+
var dir = 1, x = goalColumn;
|
| 9150 |
+
if (amount < 0) { dir = -1; amount = -amount; }
|
| 9151 |
+
var cur = clipPos(this.doc, from);
|
| 9152 |
for (var i = 0; i < amount; ++i) {
|
| 9153 |
+
var coords = cursorCoords(this$1, cur, "div");
|
| 9154 |
+
if (x == null) { x = coords.left; }
|
| 9155 |
+
else { coords.left = x; }
|
| 9156 |
+
cur = findPosV(this$1, coords, dir, unit);
|
| 9157 |
if (cur.hitSide) { break }
|
| 9158 |
}
|
| 9159 |
return cur
|
| 9162 |
moveV: methodOp(function(dir, unit) {
|
| 9163 |
var this$1 = this;
|
| 9164 |
|
| 9165 |
+
var doc = this.doc, goals = [];
|
| 9166 |
+
var collapse = !this.display.shift && !doc.extend && doc.sel.somethingSelected();
|
| 9167 |
+
doc.extendSelectionsBy(function (range$$1) {
|
| 9168 |
if (collapse)
|
| 9169 |
+
{ return dir < 0 ? range$$1.from() : range$$1.to() }
|
| 9170 |
+
var headPos = cursorCoords(this$1, range$$1.head, "div");
|
| 9171 |
+
if (range$$1.goalColumn != null) { headPos.left = range$$1.goalColumn; }
|
| 9172 |
+
goals.push(headPos.left);
|
| 9173 |
+
var pos = findPosV(this$1, headPos, dir, unit);
|
| 9174 |
+
if (unit == "page" && range$$1 == doc.sel.primary())
|
| 9175 |
+
{ addToScrollPos(this$1, null, charCoords(this$1, pos, "div").top - headPos.top); }
|
| 9176 |
return pos
|
| 9177 |
+
}, sel_move);
|
| 9178 |
if (goals.length) { for (var i = 0; i < doc.sel.ranges.length; i++)
|
| 9179 |
+
{ doc.sel.ranges[i].goalColumn = goals[i]; } }
|
| 9180 |
}),
|
| 9181 |
|
| 9182 |
// Find the word at the given position (as returned by coordsChar).
|
| 9183 |
findWordAt: function(pos) {
|
| 9184 |
+
var doc = this.doc, line = getLine(doc, pos.line).text;
|
| 9185 |
+
var start = pos.ch, end = pos.ch;
|
| 9186 |
if (line) {
|
| 9187 |
+
var helper = this.getHelper(pos, "wordChars");
|
| 9188 |
+
if ((pos.sticky == "before" || end == line.length) && start) { --start; } else { ++end; }
|
| 9189 |
+
var startChar = line.charAt(start);
|
| 9190 |
var check = isWordChar(startChar, helper)
|
| 9191 |
? function (ch) { return isWordChar(ch, helper); }
|
| 9192 |
: /\s/.test(startChar) ? function (ch) { return /\s/.test(ch); }
|
| 9193 |
+
: function (ch) { return (!/\s/.test(ch) && !isWordChar(ch)); };
|
| 9194 |
+
while (start > 0 && check(line.charAt(start - 1))) { --start; }
|
| 9195 |
+
while (end < line.length && check(line.charAt(end))) { ++end; }
|
| 9196 |
}
|
| 9197 |
return new Range(Pos(pos.line, start), Pos(pos.line, end))
|
| 9198 |
},
|
| 9200 |
toggleOverwrite: function(value) {
|
| 9201 |
if (value != null && value == this.state.overwrite) { return }
|
| 9202 |
if (this.state.overwrite = !this.state.overwrite)
|
| 9203 |
+
{ addClass(this.display.cursorDiv, "CodeMirror-overwrite"); }
|
| 9204 |
else
|
| 9205 |
+
{ rmClass(this.display.cursorDiv, "CodeMirror-overwrite"); }
|
| 9206 |
|
| 9207 |
+
signal(this, "overwriteToggle", this, this.state.overwrite);
|
| 9208 |
},
|
| 9209 |
hasFocus: function() { return this.display.input.getField() == activeElt() },
|
| 9210 |
isReadOnly: function() { return !!(this.options.readOnly || this.doc.cantEdit) },
|
| 9211 |
|
| 9212 |
scrollTo: methodOp(function(x, y) {
|
| 9213 |
+
if (x != null || y != null) { resolveScrollToPos(this); }
|
| 9214 |
+
if (x != null) { this.curOp.scrollLeft = x; }
|
| 9215 |
+
if (y != null) { this.curOp.scrollTop = y; }
|
| 9216 |
}),
|
| 9217 |
getScrollInfo: function() {
|
| 9218 |
+
var scroller = this.display.scroller;
|
| 9219 |
return {left: scroller.scrollLeft, top: scroller.scrollTop,
|
| 9220 |
height: scroller.scrollHeight - scrollGap(this) - this.display.barHeight,
|
| 9221 |
width: scroller.scrollWidth - scrollGap(this) - this.display.barWidth,
|
| 9222 |
clientHeight: displayHeight(this), clientWidth: displayWidth(this)}
|
| 9223 |
},
|
| 9224 |
|
| 9225 |
+
scrollIntoView: methodOp(function(range$$1, margin) {
|
| 9226 |
+
if (range$$1 == null) {
|
| 9227 |
+
range$$1 = {from: this.doc.sel.primary().head, to: null};
|
| 9228 |
+
if (margin == null) { margin = this.options.cursorScrollMargin; }
|
| 9229 |
+
} else if (typeof range$$1 == "number") {
|
| 9230 |
+
range$$1 = {from: Pos(range$$1, 0), to: null};
|
| 9231 |
+
} else if (range$$1.from == null) {
|
| 9232 |
+
range$$1 = {from: range$$1, to: null};
|
| 9233 |
}
|
| 9234 |
+
if (!range$$1.to) { range$$1.to = range$$1.from; }
|
| 9235 |
+
range$$1.margin = margin || 0;
|
| 9236 |
|
| 9237 |
+
if (range$$1.from.line != null) {
|
| 9238 |
+
resolveScrollToPos(this);
|
| 9239 |
+
this.curOp.scrollToPos = range$$1;
|
| 9240 |
} else {
|
| 9241 |
+
var sPos = calculateScrollPos(this, {
|
| 9242 |
+
left: Math.min(range$$1.from.left, range$$1.to.left),
|
| 9243 |
+
top: Math.min(range$$1.from.top, range$$1.to.top) - range$$1.margin,
|
| 9244 |
+
right: Math.max(range$$1.from.right, range$$1.to.right),
|
| 9245 |
+
bottom: Math.max(range$$1.from.bottom, range$$1.to.bottom) + range$$1.margin
|
| 9246 |
+
});
|
| 9247 |
+
this.scrollTo(sPos.scrollLeft, sPos.scrollTop);
|
| 9248 |
}
|
| 9249 |
}),
|
| 9250 |
|
| 9251 |
setSize: methodOp(function(width, height) {
|
| 9252 |
var this$1 = this;
|
| 9253 |
|
| 9254 |
+
var interpret = function (val) { return typeof val == "number" || /^\d+$/.test(String(val)) ? val + "px" : val; };
|
| 9255 |
+
if (width != null) { this.display.wrapper.style.width = interpret(width); }
|
| 9256 |
+
if (height != null) { this.display.wrapper.style.height = interpret(height); }
|
| 9257 |
+
if (this.options.lineWrapping) { clearLineMeasurementCache(this); }
|
| 9258 |
+
var lineNo$$1 = this.display.viewFrom;
|
| 9259 |
+
this.doc.iter(lineNo$$1, this.display.viewTo, function (line) {
|
| 9260 |
if (line.widgets) { for (var i = 0; i < line.widgets.length; i++)
|
| 9261 |
+
{ if (line.widgets[i].noHScroll) { regLineChange(this$1, lineNo$$1, "widget"); break } } }
|
| 9262 |
+
++lineNo$$1;
|
| 9263 |
+
});
|
| 9264 |
+
this.curOp.forceUpdate = true;
|
| 9265 |
+
signal(this, "refresh", this);
|
| 9266 |
}),
|
| 9267 |
|
| 9268 |
operation: function(f){return runInOp(this, f)},
|
| 9269 |
|
| 9270 |
refresh: methodOp(function() {
|
| 9271 |
+
var oldHeight = this.display.cachedTextHeight;
|
| 9272 |
+
regChange(this);
|
| 9273 |
+
this.curOp.forceUpdate = true;
|
| 9274 |
+
clearCaches(this);
|
| 9275 |
+
this.scrollTo(this.doc.scrollLeft, this.doc.scrollTop);
|
| 9276 |
+
updateGutterSpace(this);
|
| 9277 |
if (oldHeight == null || Math.abs(oldHeight - textHeight(this.display)) > .5)
|
| 9278 |
+
{ estimateLineHeights(this); }
|
| 9279 |
+
signal(this, "refresh", this);
|
| 9280 |
}),
|
| 9281 |
|
| 9282 |
swapDoc: methodOp(function(doc) {
|
| 9283 |
+
var old = this.doc;
|
| 9284 |
+
old.cm = null;
|
| 9285 |
+
attachDoc(this, doc);
|
| 9286 |
+
clearCaches(this);
|
| 9287 |
+
this.display.input.reset();
|
| 9288 |
+
this.scrollTo(doc.scrollLeft, doc.scrollTop);
|
| 9289 |
+
this.curOp.forceScroll = true;
|
| 9290 |
+
signalLater(this, "swapDoc", this, old);
|
| 9291 |
return old
|
| 9292 |
}),
|
| 9293 |
|
| 9295 |
getWrapperElement: function(){return this.display.wrapper},
|
| 9296 |
getScrollerElement: function(){return this.display.scroller},
|
| 9297 |
getGutterElement: function(){return this.display.gutters}
|
| 9298 |
+
};
|
| 9299 |
+
eventMixin(CodeMirror);
|
| 9300 |
|
| 9301 |
CodeMirror.registerHelper = function(type, name, value) {
|
| 9302 |
+
if (!helpers.hasOwnProperty(type)) { helpers[type] = CodeMirror[type] = {_global: []}; }
|
| 9303 |
+
helpers[type][name] = value;
|
| 9304 |
+
};
|
| 9305 |
CodeMirror.registerGlobalHelper = function(type, name, predicate, value) {
|
| 9306 |
+
CodeMirror.registerHelper(type, name, value);
|
| 9307 |
+
helpers[type]._global.push({pred: predicate, val: value});
|
| 9308 |
+
};
|
| 9309 |
+
};
|
| 9310 |
|
| 9311 |
// Used for horizontal relative motion. Dir is -1 or 1 (left or
|
| 9312 |
// right), unit can be "char", "column" (like char, but doesn't
|
| 9318 |
// position. The resulting position will have a hitSide=true
|
| 9319 |
// property if it reached the end of the document.
|
| 9320 |
function findPosH(doc, pos, dir, unit, visually) {
|
| 9321 |
+
var oldPos = pos;
|
| 9322 |
+
var origDir = dir;
|
| 9323 |
+
var lineObj = getLine(doc, pos.line);
|
| 9324 |
function findNextLine() {
|
| 9325 |
+
var l = pos.line + dir;
|
| 9326 |
if (l < doc.first || l >= doc.first + doc.size) { return false }
|
| 9327 |
+
pos = new Pos(l, pos.ch, pos.sticky);
|
| 9328 |
return lineObj = getLine(doc, l)
|
| 9329 |
}
|
| 9330 |
function moveOnce(boundToLine) {
|
| 9331 |
+
var next;
|
| 9332 |
if (visually) {
|
| 9333 |
+
next = moveVisually(doc.cm, lineObj, pos, dir);
|
| 9334 |
} else {
|
| 9335 |
+
next = moveLogically(lineObj, pos, dir);
|
| 9336 |
}
|
| 9337 |
if (next == null) {
|
| 9338 |
if (!boundToLine && findNextLine())
|
| 9339 |
+
{ pos = endOfLine(visually, doc.cm, lineObj, pos.line, dir); }
|
| 9340 |
else
|
| 9341 |
{ return false }
|
| 9342 |
} else {
|
| 9343 |
+
pos = next;
|
| 9344 |
}
|
| 9345 |
return true
|
| 9346 |
}
|
| 9347 |
|
| 9348 |
if (unit == "char") {
|
| 9349 |
+
moveOnce();
|
| 9350 |
} else if (unit == "column") {
|
| 9351 |
+
moveOnce(true);
|
| 9352 |
} else if (unit == "word" || unit == "group") {
|
| 9353 |
+
var sawType = null, group = unit == "group";
|
| 9354 |
+
var helper = doc.cm && doc.cm.getHelper(pos, "wordChars");
|
| 9355 |
for (var first = true;; first = false) {
|
| 9356 |
if (dir < 0 && !moveOnce(!first)) { break }
|
| 9357 |
+
var cur = lineObj.text.charAt(pos.ch) || "\n";
|
| 9358 |
var type = isWordChar(cur, helper) ? "w"
|
| 9359 |
: group && cur == "\n" ? "n"
|
| 9360 |
: !group || /\s/.test(cur) ? null
|
| 9361 |
+
: "p";
|
| 9362 |
+
if (group && !first && !type) { type = "s"; }
|
| 9363 |
if (sawType && sawType != type) {
|
| 9364 |
+
if (dir < 0) {dir = 1; moveOnce(); pos.sticky = "after";}
|
| 9365 |
break
|
| 9366 |
}
|
| 9367 |
|
| 9368 |
+
if (type) { sawType = type; }
|
| 9369 |
if (dir > 0 && !moveOnce(!first)) { break }
|
| 9370 |
}
|
| 9371 |
}
|
| 9372 |
+
var result = skipAtomic(doc, pos, oldPos, origDir, true);
|
| 9373 |
+
if (equalCursorPos(oldPos, result)) { result.hitSide = true; }
|
| 9374 |
return result
|
| 9375 |
}
|
| 9376 |
|
| 9378 |
// "page" or "line". The resulting position will have a hitSide=true
|
| 9379 |
// property if it reached the end of the document.
|
| 9380 |
function findPosV(cm, pos, dir, unit) {
|
| 9381 |
+
var doc = cm.doc, x = pos.left, y;
|
| 9382 |
if (unit == "page") {
|
| 9383 |
+
var pageSize = Math.min(cm.display.wrapper.clientHeight, window.innerHeight || document.documentElement.clientHeight);
|
| 9384 |
+
var moveAmount = Math.max(pageSize - .5 * textHeight(cm.display), 3);
|
| 9385 |
+
y = (dir > 0 ? pos.bottom : pos.top) + dir * moveAmount;
|
| 9386 |
|
| 9387 |
} else if (unit == "line") {
|
| 9388 |
+
y = dir > 0 ? pos.bottom + 3 : pos.top - 3;
|
| 9389 |
}
|
| 9390 |
+
var target;
|
| 9391 |
for (;;) {
|
| 9392 |
+
target = coordsChar(cm, x, y);
|
| 9393 |
if (!target.outside) { break }
|
| 9394 |
if (dir < 0 ? y <= 0 : y >= doc.height) { target.hitSide = true; break }
|
| 9395 |
+
y += dir * 5;
|
| 9396 |
}
|
| 9397 |
return target
|
| 9398 |
}
|
| 9400 |
// CONTENTEDITABLE INPUT STYLE
|
| 9401 |
|
| 9402 |
var ContentEditableInput = function(cm) {
|
| 9403 |
+
this.cm = cm;
|
| 9404 |
+
this.lastAnchorNode = this.lastAnchorOffset = this.lastFocusNode = this.lastFocusOffset = null;
|
| 9405 |
+
this.polling = new Delayed();
|
| 9406 |
+
this.composing = null;
|
| 9407 |
+
this.gracePeriod = false;
|
| 9408 |
+
this.readDOMTimeout = null;
|
| 9409 |
};
|
| 9410 |
|
| 9411 |
ContentEditableInput.prototype.init = function (display) {
|
| 9412 |
var this$1 = this;
|
| 9413 |
|
| 9414 |
+
var input = this, cm = input.cm;
|
| 9415 |
+
var div = input.div = display.lineDiv;
|
| 9416 |
+
disableBrowserMagic(div, cm.options.spellcheck);
|
| 9417 |
|
| 9418 |
on(div, "paste", function (e) {
|
| 9419 |
if (signalDOMEvent(cm, e) || handlePaste(e, cm)) { return }
|
| 9420 |
// IE doesn't fire input events, so we schedule a read for the pasted content in this way
|
| 9421 |
+
if (ie_version <= 11) { setTimeout(operation(cm, function () { return this$1.updateFromDOM(); }), 20); }
|
| 9422 |
+
});
|
|
|
|
|
|
|
| 9423 |
|
| 9424 |
on(div, "compositionstart", function (e) {
|
| 9425 |
+
this$1.composing = {data: e.data, done: false};
|
| 9426 |
+
});
|
| 9427 |
on(div, "compositionupdate", function (e) {
|
| 9428 |
+
if (!this$1.composing) { this$1.composing = {data: e.data, done: false}; }
|
| 9429 |
+
});
|
| 9430 |
on(div, "compositionend", function (e) {
|
| 9431 |
if (this$1.composing) {
|
| 9432 |
+
if (e.data != this$1.composing.data) { this$1.readFromDOMSoon(); }
|
| 9433 |
+
this$1.composing.done = true;
|
| 9434 |
}
|
| 9435 |
+
});
|
| 9436 |
|
| 9437 |
+
on(div, "touchstart", function () { return input.forceCompositionEnd(); });
|
| 9438 |
|
| 9439 |
on(div, "input", function () {
|
| 9440 |
+
if (!this$1.composing) { this$1.readFromDOMSoon(); }
|
| 9441 |
+
});
|
| 9442 |
|
| 9443 |
function onCopyCut(e) {
|
| 9444 |
if (signalDOMEvent(cm, e)) { return }
|
| 9445 |
if (cm.somethingSelected()) {
|
| 9446 |
+
setLastCopied({lineWise: false, text: cm.getSelections()});
|
| 9447 |
+
if (e.type == "cut") { cm.replaceSelection("", null, "cut"); }
|
| 9448 |
} else if (!cm.options.lineWiseCopyCut) {
|
| 9449 |
return
|
| 9450 |
} else {
|
| 9451 |
+
var ranges = copyableRanges(cm);
|
| 9452 |
+
setLastCopied({lineWise: true, text: ranges.text});
|
| 9453 |
if (e.type == "cut") {
|
| 9454 |
cm.operation(function () {
|
| 9455 |
+
cm.setSelections(ranges.ranges, 0, sel_dontScroll);
|
| 9456 |
+
cm.replaceSelection("", null, "cut");
|
| 9457 |
+
});
|
| 9458 |
}
|
| 9459 |
}
|
| 9460 |
if (e.clipboardData) {
|
| 9461 |
+
e.clipboardData.clearData();
|
| 9462 |
+
var content = lastCopied.text.join("\n");
|
| 9463 |
// iOS exposes the clipboard API, but seems to discard content inserted into it
|
| 9464 |
+
e.clipboardData.setData("Text", content);
|
| 9465 |
if (e.clipboardData.getData("Text") == content) {
|
| 9466 |
+
e.preventDefault();
|
| 9467 |
return
|
| 9468 |
}
|
| 9469 |
}
|
| 9470 |
// Old-fashioned briefly-focus-a-textarea hack
|
| 9471 |
+
var kludge = hiddenTextarea(), te = kludge.firstChild;
|
| 9472 |
+
cm.display.lineSpace.insertBefore(kludge, cm.display.lineSpace.firstChild);
|
| 9473 |
+
te.value = lastCopied.text.join("\n");
|
| 9474 |
+
var hadFocus = document.activeElement;
|
| 9475 |
+
selectInput(te);
|
| 9476 |
setTimeout(function () {
|
| 9477 |
+
cm.display.lineSpace.removeChild(kludge);
|
| 9478 |
+
hadFocus.focus();
|
| 9479 |
+
if (hadFocus == div) { input.showPrimarySelection(); }
|
| 9480 |
+
}, 50);
|
| 9481 |
}
|
| 9482 |
+
on(div, "copy", onCopyCut);
|
| 9483 |
+
on(div, "cut", onCopyCut);
|
| 9484 |
};
|
| 9485 |
|
| 9486 |
ContentEditableInput.prototype.prepareSelection = function () {
|
| 9487 |
+
var result = prepareSelection(this.cm, false);
|
| 9488 |
+
result.focus = this.cm.state.focused;
|
| 9489 |
return result
|
| 9490 |
};
|
| 9491 |
|
| 9492 |
ContentEditableInput.prototype.showSelection = function (info, takeFocus) {
|
| 9493 |
if (!info || !this.cm.display.view.length) { return }
|
| 9494 |
+
if (info.focus || takeFocus) { this.showPrimarySelection(); }
|
| 9495 |
+
this.showMultipleSelections(info);
|
| 9496 |
};
|
| 9497 |
|
| 9498 |
ContentEditableInput.prototype.showPrimarySelection = function () {
|
| 9499 |
+
var sel = window.getSelection(), prim = this.cm.doc.sel.primary();
|
| 9500 |
+
var curAnchor = domToPos(this.cm, sel.anchorNode, sel.anchorOffset);
|
| 9501 |
+
var curFocus = domToPos(this.cm, sel.focusNode, sel.focusOffset);
|
| 9502 |
if (curAnchor && !curAnchor.bad && curFocus && !curFocus.bad &&
|
| 9503 |
cmp(minPos(curAnchor, curFocus), prim.from()) == 0 &&
|
| 9504 |
cmp(maxPos(curAnchor, curFocus), prim.to()) == 0)
|
| 9505 |
{ return }
|
| 9506 |
|
| 9507 |
+
var start = posToDOM(this.cm, prim.from());
|
| 9508 |
+
var end = posToDOM(this.cm, prim.to());
|
| 9509 |
+
if (!start && !end) {
|
| 9510 |
+
sel.removeAllRanges();
|
| 9511 |
+
return
|
| 9512 |
+
}
|
| 9513 |
|
| 9514 |
+
var view = this.cm.display.view;
|
| 9515 |
+
var old = sel.rangeCount && sel.getRangeAt(0);
|
| 9516 |
if (!start) {
|
| 9517 |
+
start = {node: view[0].measure.map[2], offset: 0};
|
| 9518 |
} else if (!end) { // FIXME dangerously hacky
|
| 9519 |
+
var measure = view[view.length - 1].measure;
|
| 9520 |
+
var map$$1 = measure.maps ? measure.maps[measure.maps.length - 1] : measure.map;
|
| 9521 |
+
end = {node: map$$1[map$$1.length - 1], offset: map$$1[map$$1.length - 2] - map$$1[map$$1.length - 3]};
|
| 9522 |
}
|
| 9523 |
|
| 9524 |
+
var rng;
|
| 9525 |
+
try { rng = range(start.node, start.offset, end.offset, end.node); }
|
| 9526 |
catch(e) {} // Our model of the DOM might be outdated, in which case the range we try to set can be impossible
|
| 9527 |
if (rng) {
|
| 9528 |
if (!gecko && this.cm.state.focused) {
|
| 9529 |
+
sel.collapse(start.node, start.offset);
|
| 9530 |
if (!rng.collapsed) {
|
| 9531 |
+
sel.removeAllRanges();
|
| 9532 |
+
sel.addRange(rng);
|
| 9533 |
}
|
| 9534 |
} else {
|
| 9535 |
+
sel.removeAllRanges();
|
| 9536 |
+
sel.addRange(rng);
|
| 9537 |
}
|
| 9538 |
+
if (old && sel.anchorNode == null) { sel.addRange(old); }
|
| 9539 |
+
else if (gecko) { this.startGracePeriod(); }
|
| 9540 |
}
|
| 9541 |
+
this.rememberSelection();
|
| 9542 |
};
|
| 9543 |
|
| 9544 |
ContentEditableInput.prototype.startGracePeriod = function () {
|
| 9545 |
var this$1 = this;
|
| 9546 |
|
| 9547 |
+
clearTimeout(this.gracePeriod);
|
| 9548 |
this.gracePeriod = setTimeout(function () {
|
| 9549 |
+
this$1.gracePeriod = false;
|
| 9550 |
if (this$1.selectionChanged())
|
| 9551 |
+
{ this$1.cm.operation(function () { return this$1.cm.curOp.selectionChanged = true; }); }
|
| 9552 |
+
}, 20);
|
| 9553 |
};
|
| 9554 |
|
| 9555 |
ContentEditableInput.prototype.showMultipleSelections = function (info) {
|
| 9556 |
+
removeChildrenAndAdd(this.cm.display.cursorDiv, info.cursors);
|
| 9557 |
+
removeChildrenAndAdd(this.cm.display.selectionDiv, info.selection);
|
| 9558 |
};
|
| 9559 |
|
| 9560 |
ContentEditableInput.prototype.rememberSelection = function () {
|
| 9561 |
+
var sel = window.getSelection();
|
| 9562 |
+
this.lastAnchorNode = sel.anchorNode; this.lastAnchorOffset = sel.anchorOffset;
|
| 9563 |
+
this.lastFocusNode = sel.focusNode; this.lastFocusOffset = sel.focusOffset;
|
| 9564 |
};
|
| 9565 |
|
| 9566 |
ContentEditableInput.prototype.selectionInEditor = function () {
|
| 9567 |
+
var sel = window.getSelection();
|
| 9568 |
if (!sel.rangeCount) { return false }
|
| 9569 |
+
var node = sel.getRangeAt(0).commonAncestorContainer;
|
| 9570 |
return contains(this.div, node)
|
| 9571 |
};
|
| 9572 |
|
| 9573 |
ContentEditableInput.prototype.focus = function () {
|
| 9574 |
if (this.cm.options.readOnly != "nocursor") {
|
| 9575 |
if (!this.selectionInEditor())
|
| 9576 |
+
{ this.showSelection(this.prepareSelection(), true); }
|
| 9577 |
+
this.div.focus();
|
| 9578 |
}
|
| 9579 |
};
|
| 9580 |
+
ContentEditableInput.prototype.blur = function () { this.div.blur(); };
|
| 9581 |
ContentEditableInput.prototype.getField = function () { return this.div };
|
| 9582 |
|
| 9583 |
ContentEditableInput.prototype.supportsTouch = function () { return true };
|
| 9584 |
|
| 9585 |
ContentEditableInput.prototype.receivedFocus = function () {
|
| 9586 |
+
var input = this;
|
| 9587 |
if (this.selectionInEditor())
|
| 9588 |
+
{ this.pollSelection(); }
|
| 9589 |
else
|
| 9590 |
+
{ runInOp(this.cm, function () { return input.cm.curOp.selectionChanged = true; }); }
|
| 9591 |
|
| 9592 |
function poll() {
|
| 9593 |
if (input.cm.state.focused) {
|
| 9594 |
+
input.pollSelection();
|
| 9595 |
+
input.polling.set(input.cm.options.pollInterval, poll);
|
| 9596 |
}
|
| 9597 |
}
|
| 9598 |
+
this.polling.set(this.cm.options.pollInterval, poll);
|
| 9599 |
};
|
| 9600 |
|
| 9601 |
ContentEditableInput.prototype.selectionChanged = function () {
|
| 9602 |
+
var sel = window.getSelection();
|
| 9603 |
return sel.anchorNode != this.lastAnchorNode || sel.anchorOffset != this.lastAnchorOffset ||
|
| 9604 |
sel.focusNode != this.lastFocusNode || sel.focusOffset != this.lastFocusOffset
|
| 9605 |
};
|
| 9606 |
|
| 9607 |
ContentEditableInput.prototype.pollSelection = function () {
|
| 9608 |
+
if (this.readDOMTimeout != null || this.gracePeriod || !this.selectionChanged()) { return }
|
| 9609 |
+
var sel = window.getSelection(), cm = this.cm;
|
| 9610 |
+
// On Android Chrome (version 56, at least), backspacing into an
|
| 9611 |
+
// uneditable block element will put the cursor in that element,
|
| 9612 |
+
// and then, because it's not editable, hide the virtual keyboard.
|
| 9613 |
+
// Because Android doesn't allow us to actually detect backspace
|
| 9614 |
+
// presses in a sane way, this code checks for when that happens
|
| 9615 |
+
// and simulates a backspace press in this case.
|
| 9616 |
+
if (android && chrome && this.cm.options.gutters.length && isInGutter(sel.anchorNode)) {
|
| 9617 |
+
this.cm.triggerOnKeyDown({type: "keydown", keyCode: 8, preventDefault: Math.abs});
|
| 9618 |
+
this.blur();
|
| 9619 |
+
this.focus();
|
| 9620 |
+
return
|
| 9621 |
}
|
| 9622 |
+
if (this.composing) { return }
|
| 9623 |
+
this.rememberSelection();
|
| 9624 |
+
var anchor = domToPos(cm, sel.anchorNode, sel.anchorOffset);
|
| 9625 |
+
var head = domToPos(cm, sel.focusNode, sel.focusOffset);
|
| 9626 |
+
if (anchor && head) { runInOp(cm, function () {
|
| 9627 |
+
setSelection(cm.doc, simpleSelection(anchor, head), sel_dontScroll);
|
| 9628 |
+
if (anchor.bad || head.bad) { cm.curOp.selectionChanged = true; }
|
| 9629 |
+
}); }
|
| 9630 |
};
|
| 9631 |
|
| 9632 |
ContentEditableInput.prototype.pollContent = function () {
|
| 9633 |
if (this.readDOMTimeout != null) {
|
| 9634 |
+
clearTimeout(this.readDOMTimeout);
|
| 9635 |
+
this.readDOMTimeout = null;
|
| 9636 |
}
|
| 9637 |
|
| 9638 |
+
var cm = this.cm, display = cm.display, sel = cm.doc.sel.primary();
|
| 9639 |
+
var from = sel.from(), to = sel.to();
|
| 9640 |
if (from.ch == 0 && from.line > cm.firstLine())
|
| 9641 |
+
{ from = Pos(from.line - 1, getLine(cm.doc, from.line - 1).length); }
|
| 9642 |
if (to.ch == getLine(cm.doc, to.line).text.length && to.line < cm.lastLine())
|
| 9643 |
+
{ to = Pos(to.line + 1, 0); }
|
| 9644 |
if (from.line < display.viewFrom || to.line > display.viewTo - 1) { return false }
|
| 9645 |
|
| 9646 |
+
var fromIndex, fromLine, fromNode;
|
| 9647 |
if (from.line == display.viewFrom || (fromIndex = findViewIndex(cm, from.line)) == 0) {
|
| 9648 |
+
fromLine = lineNo(display.view[0].line);
|
| 9649 |
+
fromNode = display.view[0].node;
|
| 9650 |
} else {
|
| 9651 |
+
fromLine = lineNo(display.view[fromIndex].line);
|
| 9652 |
+
fromNode = display.view[fromIndex - 1].node.nextSibling;
|
| 9653 |
}
|
| 9654 |
+
var toIndex = findViewIndex(cm, to.line);
|
| 9655 |
+
var toLine, toNode;
|
| 9656 |
if (toIndex == display.view.length - 1) {
|
| 9657 |
+
toLine = display.viewTo - 1;
|
| 9658 |
+
toNode = display.lineDiv.lastChild;
|
| 9659 |
} else {
|
| 9660 |
+
toLine = lineNo(display.view[toIndex + 1].line) - 1;
|
| 9661 |
+
toNode = display.view[toIndex + 1].node.previousSibling;
|
| 9662 |
}
|
| 9663 |
|
| 9664 |
if (!fromNode) { return false }
|
| 9665 |
+
var newText = cm.doc.splitLines(domTextBetween(cm, fromNode, toNode, fromLine, toLine));
|
| 9666 |
+
var oldText = getBetween(cm.doc, Pos(fromLine, 0), Pos(toLine, getLine(cm.doc, toLine).text.length));
|
| 9667 |
while (newText.length > 1 && oldText.length > 1) {
|
| 9668 |
+
if (lst(newText) == lst(oldText)) { newText.pop(); oldText.pop(); toLine--; }
|
| 9669 |
+
else if (newText[0] == oldText[0]) { newText.shift(); oldText.shift(); fromLine++; }
|
| 9670 |
else { break }
|
| 9671 |
}
|
| 9672 |
|
| 9673 |
+
var cutFront = 0, cutEnd = 0;
|
| 9674 |
+
var newTop = newText[0], oldTop = oldText[0], maxCutFront = Math.min(newTop.length, oldTop.length);
|
| 9675 |
while (cutFront < maxCutFront && newTop.charCodeAt(cutFront) == oldTop.charCodeAt(cutFront))
|
| 9676 |
+
{ ++cutFront; }
|
| 9677 |
+
var newBot = lst(newText), oldBot = lst(oldText);
|
| 9678 |
var maxCutEnd = Math.min(newBot.length - (newText.length == 1 ? cutFront : 0),
|
| 9679 |
+
oldBot.length - (oldText.length == 1 ? cutFront : 0));
|
| 9680 |
while (cutEnd < maxCutEnd &&
|
| 9681 |
newBot.charCodeAt(newBot.length - cutEnd - 1) == oldBot.charCodeAt(oldBot.length - cutEnd - 1))
|
| 9682 |
+
{ ++cutEnd; }
|
| 9683 |
+
// Try to move start of change to start of selection if ambiguous
|
| 9684 |
+
if (newText.length == 1 && oldText.length == 1 && fromLine == from.line) {
|
| 9685 |
+
while (cutFront && cutFront > from.ch &&
|
| 9686 |
+
newBot.charCodeAt(newBot.length - cutEnd - 1) == oldBot.charCodeAt(oldBot.length - cutEnd - 1)) {
|
| 9687 |
+
cutFront--;
|
| 9688 |
+
cutEnd++;
|
| 9689 |
+
}
|
| 9690 |
+
}
|
| 9691 |
|
| 9692 |
+
newText[newText.length - 1] = newBot.slice(0, newBot.length - cutEnd).replace(/^\u200b+/, "");
|
| 9693 |
+
newText[0] = newText[0].slice(cutFront).replace(/\u200b+$/, "");
|
| 9694 |
|
| 9695 |
+
var chFrom = Pos(fromLine, cutFront);
|
| 9696 |
+
var chTo = Pos(toLine, oldText.length ? lst(oldText).length - cutEnd : 0);
|
| 9697 |
if (newText.length > 1 || newText[0] || cmp(chFrom, chTo)) {
|
| 9698 |
+
replaceRange(cm.doc, newText, chFrom, chTo, "+input");
|
| 9699 |
return true
|
| 9700 |
}
|
| 9701 |
};
|
| 9702 |
|
| 9703 |
ContentEditableInput.prototype.ensurePolled = function () {
|
| 9704 |
+
this.forceCompositionEnd();
|
| 9705 |
};
|
| 9706 |
ContentEditableInput.prototype.reset = function () {
|
| 9707 |
+
this.forceCompositionEnd();
|
| 9708 |
};
|
| 9709 |
ContentEditableInput.prototype.forceCompositionEnd = function () {
|
| 9710 |
if (!this.composing) { return }
|
| 9711 |
+
clearTimeout(this.readDOMTimeout);
|
| 9712 |
+
this.composing = null;
|
| 9713 |
+
this.updateFromDOM();
|
| 9714 |
+
this.div.blur();
|
| 9715 |
+
this.div.focus();
|
| 9716 |
};
|
| 9717 |
ContentEditableInput.prototype.readFromDOMSoon = function () {
|
| 9718 |
var this$1 = this;
|
| 9719 |
|
| 9720 |
if (this.readDOMTimeout != null) { return }
|
| 9721 |
this.readDOMTimeout = setTimeout(function () {
|
| 9722 |
+
this$1.readDOMTimeout = null;
|
| 9723 |
if (this$1.composing) {
|
| 9724 |
+
if (this$1.composing.done) { this$1.composing = null; }
|
| 9725 |
else { return }
|
| 9726 |
}
|
| 9727 |
+
this$1.updateFromDOM();
|
| 9728 |
+
}, 80);
|
| 9729 |
+
};
|
| 9730 |
+
|
| 9731 |
+
ContentEditableInput.prototype.updateFromDOM = function () {
|
| 9732 |
+
var this$1 = this;
|
| 9733 |
+
|
| 9734 |
+
if (this.cm.isReadOnly() || !this.pollContent())
|
| 9735 |
+
{ runInOp(this.cm, function () { return regChange(this$1.cm); }); }
|
| 9736 |
};
|
| 9737 |
|
| 9738 |
ContentEditableInput.prototype.setUneditable = function (node) {
|
| 9739 |
+
node.contentEditable = "false";
|
| 9740 |
};
|
| 9741 |
|
| 9742 |
ContentEditableInput.prototype.onKeyPress = function (e) {
|
| 9743 |
if (e.charCode == 0) { return }
|
| 9744 |
+
e.preventDefault();
|
| 9745 |
if (!this.cm.isReadOnly())
|
| 9746 |
+
{ operation(this.cm, applyTextInput)(this.cm, String.fromCharCode(e.charCode == null ? e.keyCode : e.charCode), 0); }
|
| 9747 |
};
|
| 9748 |
|
| 9749 |
ContentEditableInput.prototype.readOnlyChanged = function (val) {
|
| 9750 |
+
this.div.contentEditable = String(val != "nocursor");
|
| 9751 |
};
|
| 9752 |
|
| 9753 |
ContentEditableInput.prototype.onContextMenu = function () {};
|
| 9754 |
ContentEditableInput.prototype.resetPosition = function () {};
|
| 9755 |
|
| 9756 |
+
ContentEditableInput.prototype.needsContentAttribute = true;
|
| 9757 |
|
| 9758 |
function posToDOM(cm, pos) {
|
| 9759 |
+
var view = findViewForLine(cm, pos.line);
|
| 9760 |
if (!view || view.hidden) { return null }
|
| 9761 |
+
var line = getLine(cm.doc, pos.line);
|
| 9762 |
+
var info = mapFromLineView(view, line, pos.line);
|
| 9763 |
|
| 9764 |
+
var order = getOrder(line, cm.doc.direction), side = "left";
|
| 9765 |
if (order) {
|
| 9766 |
+
var partPos = getBidiPartAt(order, pos.ch);
|
| 9767 |
+
side = partPos % 2 ? "right" : "left";
|
| 9768 |
}
|
| 9769 |
+
var result = nodeAndOffsetInLineMap(info.map, pos.ch, side);
|
| 9770 |
+
result.offset = result.collapse == "right" ? result.end : result.start;
|
| 9771 |
return result
|
| 9772 |
}
|
| 9773 |
|
| 9774 |
+
function isInGutter(node) {
|
| 9775 |
+
for (var scan = node; scan; scan = scan.parentNode)
|
| 9776 |
+
{ if (/CodeMirror-gutter-wrapper/.test(scan.className)) { return true } }
|
| 9777 |
+
return false
|
| 9778 |
+
}
|
| 9779 |
+
|
| 9780 |
function badPos(pos, bad) { if (bad) { pos.bad = true; } return pos }
|
| 9781 |
|
| 9782 |
function domTextBetween(cm, from, to, fromLine, toLine) {
|
| 9783 |
+
var text = "", closing = false, lineSep = cm.doc.lineSeparator();
|
| 9784 |
function recognizeMarker(id) { return function (marker) { return marker.id == id; } }
|
| 9785 |
+
function close() {
|
| 9786 |
+
if (closing) {
|
| 9787 |
+
text += lineSep;
|
| 9788 |
+
closing = false;
|
| 9789 |
+
}
|
| 9790 |
+
}
|
| 9791 |
+
function addText(str) {
|
| 9792 |
+
if (str) {
|
| 9793 |
+
close();
|
| 9794 |
+
text += str;
|
| 9795 |
+
}
|
| 9796 |
+
}
|
| 9797 |
function walk(node) {
|
| 9798 |
if (node.nodeType == 1) {
|
| 9799 |
+
var cmText = node.getAttribute("cm-text");
|
| 9800 |
if (cmText != null) {
|
| 9801 |
+
addText(cmText || node.textContent.replace(/\u200b/g, ""));
|
|
|
|
| 9802 |
return
|
| 9803 |
}
|
| 9804 |
+
var markerID = node.getAttribute("cm-marker"), range$$1;
|
| 9805 |
if (markerID) {
|
| 9806 |
+
var found = cm.findMarks(Pos(fromLine, 0), Pos(toLine + 1, 0), recognizeMarker(+markerID));
|
| 9807 |
+
if (found.length && (range$$1 = found[0].find()))
|
| 9808 |
+
{ addText(getBetween(cm.doc, range$$1.from, range$$1.to).join(lineSep)); }
|
| 9809 |
return
|
| 9810 |
}
|
| 9811 |
if (node.getAttribute("contenteditable") == "false") { return }
|
| 9812 |
+
var isBlock = /^(pre|div|p)$/i.test(node.nodeName);
|
| 9813 |
+
if (isBlock) { close(); }
|
| 9814 |
for (var i = 0; i < node.childNodes.length; i++)
|
| 9815 |
+
{ walk(node.childNodes[i]); }
|
| 9816 |
+
if (isBlock) { closing = true; }
|
|
|
|
| 9817 |
} else if (node.nodeType == 3) {
|
| 9818 |
+
addText(node.nodeValue);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9819 |
}
|
| 9820 |
}
|
| 9821 |
for (;;) {
|
| 9822 |
+
walk(from);
|
| 9823 |
if (from == to) { break }
|
| 9824 |
+
from = from.nextSibling;
|
| 9825 |
}
|
| 9826 |
return text
|
| 9827 |
}
|
| 9828 |
|
| 9829 |
function domToPos(cm, node, offset) {
|
| 9830 |
+
var lineNode;
|
| 9831 |
if (node == cm.display.lineDiv) {
|
| 9832 |
+
lineNode = cm.display.lineDiv.childNodes[offset];
|
| 9833 |
if (!lineNode) { return badPos(cm.clipPos(Pos(cm.display.viewTo - 1)), true) }
|
| 9834 |
+
node = null; offset = 0;
|
| 9835 |
} else {
|
| 9836 |
for (lineNode = node;; lineNode = lineNode.parentNode) {
|
| 9837 |
if (!lineNode || lineNode == cm.display.lineDiv) { return null }
|
| 9839 |
}
|
| 9840 |
}
|
| 9841 |
for (var i = 0; i < cm.display.view.length; i++) {
|
| 9842 |
+
var lineView = cm.display.view[i];
|
| 9843 |
if (lineView.node == lineNode)
|
| 9844 |
{ return locateNodeInLineView(lineView, node, offset) }
|
| 9845 |
}
|
| 9846 |
}
|
| 9847 |
|
| 9848 |
function locateNodeInLineView(lineView, node, offset) {
|
| 9849 |
+
var wrapper = lineView.text.firstChild, bad = false;
|
| 9850 |
if (!node || !contains(wrapper, node)) { return badPos(Pos(lineNo(lineView.line), 0), true) }
|
| 9851 |
if (node == wrapper) {
|
| 9852 |
+
bad = true;
|
| 9853 |
+
node = wrapper.childNodes[offset];
|
| 9854 |
+
offset = 0;
|
| 9855 |
if (!node) {
|
| 9856 |
+
var line = lineView.rest ? lst(lineView.rest) : lineView.line;
|
| 9857 |
return badPos(Pos(lineNo(line), line.text.length), bad)
|
| 9858 |
}
|
| 9859 |
}
|
| 9860 |
|
| 9861 |
+
var textNode = node.nodeType == 3 ? node : null, topNode = node;
|
| 9862 |
if (!textNode && node.childNodes.length == 1 && node.firstChild.nodeType == 3) {
|
| 9863 |
+
textNode = node.firstChild;
|
| 9864 |
+
if (offset) { offset = textNode.nodeValue.length; }
|
| 9865 |
}
|
| 9866 |
+
while (topNode.parentNode != wrapper) { topNode = topNode.parentNode; }
|
| 9867 |
+
var measure = lineView.measure, maps = measure.maps;
|
| 9868 |
|
| 9869 |
function find(textNode, topNode, offset) {
|
| 9870 |
for (var i = -1; i < (maps ? maps.length : 0); i++) {
|
| 9871 |
+
var map$$1 = i < 0 ? measure.map : maps[i];
|
| 9872 |
+
for (var j = 0; j < map$$1.length; j += 3) {
|
| 9873 |
+
var curNode = map$$1[j + 2];
|
| 9874 |
if (curNode == textNode || curNode == topNode) {
|
| 9875 |
+
var line = lineNo(i < 0 ? lineView.line : lineView.rest[i]);
|
| 9876 |
+
var ch = map$$1[j] + offset;
|
| 9877 |
+
if (offset < 0 || curNode != textNode) { ch = map$$1[j + (offset ? 1 : 0)]; }
|
| 9878 |
return Pos(line, ch)
|
| 9879 |
}
|
| 9880 |
}
|
| 9881 |
}
|
| 9882 |
}
|
| 9883 |
+
var found = find(textNode, topNode, offset);
|
| 9884 |
if (found) { return badPos(found, bad) }
|
| 9885 |
|
| 9886 |
// FIXME this is all really shaky. might handle the few cases it needs to handle, but likely to cause problems
|
| 9887 |
for (var after = topNode.nextSibling, dist = textNode ? textNode.nodeValue.length - offset : 0; after; after = after.nextSibling) {
|
| 9888 |
+
found = find(after, after.firstChild, 0);
|
| 9889 |
if (found)
|
| 9890 |
{ return badPos(Pos(found.line, found.ch - dist), bad) }
|
| 9891 |
else
|
| 9892 |
+
{ dist += after.textContent.length; }
|
| 9893 |
}
|
| 9894 |
for (var before = topNode.previousSibling, dist$1 = offset; before; before = before.previousSibling) {
|
| 9895 |
+
found = find(before, before.firstChild, -1);
|
| 9896 |
if (found)
|
| 9897 |
{ return badPos(Pos(found.line, found.ch + dist$1), bad) }
|
| 9898 |
else
|
| 9899 |
+
{ dist$1 += before.textContent.length; }
|
| 9900 |
}
|
| 9901 |
}
|
| 9902 |
|
| 9903 |
// TEXTAREA INPUT STYLE
|
| 9904 |
|
| 9905 |
var TextareaInput = function(cm) {
|
| 9906 |
+
this.cm = cm;
|
| 9907 |
// See input.poll and input.reset
|
| 9908 |
+
this.prevInput = "";
|
| 9909 |
|
| 9910 |
// Flag that indicates whether we expect input to appear real soon
|
| 9911 |
// now (after some event like 'keypress' or 'input') and are
|
| 9912 |
// polling intensively.
|
| 9913 |
+
this.pollingFast = false;
|
| 9914 |
// Self-resetting timeout for the poller
|
| 9915 |
+
this.polling = new Delayed();
|
| 9916 |
// Tracks when input.reset has punted to just putting a short
|
| 9917 |
// string into the textarea instead of the full selection.
|
| 9918 |
+
this.inaccurateSelection = false;
|
| 9919 |
// Used to work around IE issue with selection being forgotten when focus moves away from textarea
|
| 9920 |
+
this.hasSelection = false;
|
| 9921 |
+
this.composing = null;
|
| 9922 |
};
|
| 9923 |
|
| 9924 |
TextareaInput.prototype.init = function (display) {
|
| 9925 |
var this$1 = this;
|
| 9926 |
|
| 9927 |
+
var input = this, cm = this.cm;
|
| 9928 |
|
| 9929 |
// Wraps and hides input textarea
|
| 9930 |
+
var div = this.wrapper = hiddenTextarea();
|
| 9931 |
// The semihidden textarea that is focused when the editor is
|
| 9932 |
// focused, and receives input.
|
| 9933 |
+
var te = this.textarea = div.firstChild;
|
| 9934 |
+
display.wrapper.insertBefore(div, display.wrapper.firstChild);
|
| 9935 |
|
| 9936 |
// Needed to hide big blue blinking cursor on Mobile Safari (doesn't seem to work in iOS 8 anymore)
|
| 9937 |
+
if (ios) { te.style.width = "0px"; }
|
| 9938 |
|
| 9939 |
on(te, "input", function () {
|
| 9940 |
+
if (ie && ie_version >= 9 && this$1.hasSelection) { this$1.hasSelection = null; }
|
| 9941 |
+
input.poll();
|
| 9942 |
+
});
|
| 9943 |
|
| 9944 |
on(te, "paste", function (e) {
|
| 9945 |
if (signalDOMEvent(cm, e) || handlePaste(e, cm)) { return }
|
| 9946 |
|
| 9947 |
+
cm.state.pasteIncoming = true;
|
| 9948 |
+
input.fastPoll();
|
| 9949 |
+
});
|
| 9950 |
|
| 9951 |
function prepareCopyCut(e) {
|
| 9952 |
if (signalDOMEvent(cm, e)) { return }
|
| 9953 |
if (cm.somethingSelected()) {
|
| 9954 |
+
setLastCopied({lineWise: false, text: cm.getSelections()});
|
| 9955 |
if (input.inaccurateSelection) {
|
| 9956 |
+
input.prevInput = "";
|
| 9957 |
+
input.inaccurateSelection = false;
|
| 9958 |
+
te.value = lastCopied.text.join("\n");
|
| 9959 |
+
selectInput(te);
|
| 9960 |
}
|
| 9961 |
} else if (!cm.options.lineWiseCopyCut) {
|
| 9962 |
return
|
| 9963 |
} else {
|
| 9964 |
+
var ranges = copyableRanges(cm);
|
| 9965 |
+
setLastCopied({lineWise: true, text: ranges.text});
|
| 9966 |
if (e.type == "cut") {
|
| 9967 |
+
cm.setSelections(ranges.ranges, null, sel_dontScroll);
|
| 9968 |
} else {
|
| 9969 |
+
input.prevInput = "";
|
| 9970 |
+
te.value = ranges.text.join("\n");
|
| 9971 |
+
selectInput(te);
|
| 9972 |
}
|
| 9973 |
}
|
| 9974 |
+
if (e.type == "cut") { cm.state.cutIncoming = true; }
|
| 9975 |
}
|
| 9976 |
+
on(te, "cut", prepareCopyCut);
|
| 9977 |
+
on(te, "copy", prepareCopyCut);
|
| 9978 |
|
| 9979 |
on(display.scroller, "paste", function (e) {
|
| 9980 |
if (eventInWidget(display, e) || signalDOMEvent(cm, e)) { return }
|
| 9981 |
+
cm.state.pasteIncoming = true;
|
| 9982 |
+
input.focus();
|
| 9983 |
+
});
|
| 9984 |
|
| 9985 |
// Prevent normal selection in the editor (we handle our own)
|
| 9986 |
on(display.lineSpace, "selectstart", function (e) {
|
| 9987 |
+
if (!eventInWidget(display, e)) { e_preventDefault(e); }
|
| 9988 |
+
});
|
| 9989 |
|
| 9990 |
on(te, "compositionstart", function () {
|
| 9991 |
+
var start = cm.getCursor("from");
|
| 9992 |
+
if (input.composing) { input.composing.range.clear(); }
|
| 9993 |
input.composing = {
|
| 9994 |
start: start,
|
| 9995 |
range: cm.markText(start, cm.getCursor("to"), {className: "CodeMirror-composing"})
|
| 9996 |
+
};
|
| 9997 |
+
});
|
| 9998 |
on(te, "compositionend", function () {
|
| 9999 |
if (input.composing) {
|
| 10000 |
+
input.poll();
|
| 10001 |
+
input.composing.range.clear();
|
| 10002 |
+
input.composing = null;
|
| 10003 |
}
|
| 10004 |
+
});
|
| 10005 |
};
|
| 10006 |
|
| 10007 |
TextareaInput.prototype.prepareSelection = function () {
|
| 10008 |
// Redraw the selection and/or cursor
|
| 10009 |
+
var cm = this.cm, display = cm.display, doc = cm.doc;
|
| 10010 |
+
var result = prepareSelection(cm);
|
| 10011 |
|
| 10012 |
// Move the hidden textarea near the cursor to prevent scrolling artifacts
|
| 10013 |
if (cm.options.moveInputWithCursor) {
|
| 10014 |
+
var headPos = cursorCoords(cm, doc.sel.primary().head, "div");
|
| 10015 |
+
var wrapOff = display.wrapper.getBoundingClientRect(), lineOff = display.lineDiv.getBoundingClientRect();
|
| 10016 |
result.teTop = Math.max(0, Math.min(display.wrapper.clientHeight - 10,
|
| 10017 |
+
headPos.top + lineOff.top - wrapOff.top));
|
| 10018 |
result.teLeft = Math.max(0, Math.min(display.wrapper.clientWidth - 10,
|
| 10019 |
+
headPos.left + lineOff.left - wrapOff.left));
|
| 10020 |
}
|
| 10021 |
|
| 10022 |
return result
|
| 10023 |
};
|
| 10024 |
|
| 10025 |
TextareaInput.prototype.showSelection = function (drawn) {
|
| 10026 |
+
var cm = this.cm, display = cm.display;
|
| 10027 |
+
removeChildrenAndAdd(display.cursorDiv, drawn.cursors);
|
| 10028 |
+
removeChildrenAndAdd(display.selectionDiv, drawn.selection);
|
| 10029 |
if (drawn.teTop != null) {
|
| 10030 |
+
this.wrapper.style.top = drawn.teTop + "px";
|
| 10031 |
+
this.wrapper.style.left = drawn.teLeft + "px";
|
| 10032 |
}
|
| 10033 |
};
|
| 10034 |
|
| 10036 |
// when not typing and nothing is selected)
|
| 10037 |
TextareaInput.prototype.reset = function (typing) {
|
| 10038 |
if (this.contextMenuPending) { return }
|
| 10039 |
+
var minimal, selected, cm = this.cm, doc = cm.doc;
|
| 10040 |
if (cm.somethingSelected()) {
|
| 10041 |
+
this.prevInput = "";
|
| 10042 |
+
var range$$1 = doc.sel.primary();
|
| 10043 |
minimal = hasCopyEvent &&
|
| 10044 |
+
(range$$1.to().line - range$$1.from().line > 100 || (selected = cm.getSelection()).length > 1000);
|
| 10045 |
+
var content = minimal ? "-" : selected || cm.getSelection();
|
| 10046 |
+
this.textarea.value = content;
|
| 10047 |
+
if (cm.state.focused) { selectInput(this.textarea); }
|
| 10048 |
+
if (ie && ie_version >= 9) { this.hasSelection = content; }
|
| 10049 |
} else if (!typing) {
|
| 10050 |
+
this.prevInput = this.textarea.value = "";
|
| 10051 |
+
if (ie && ie_version >= 9) { this.hasSelection = null; }
|
| 10052 |
}
|
| 10053 |
+
this.inaccurateSelection = minimal;
|
| 10054 |
};
|
| 10055 |
|
| 10056 |
TextareaInput.prototype.getField = function () { return this.textarea };
|
| 10059 |
|
| 10060 |
TextareaInput.prototype.focus = function () {
|
| 10061 |
if (this.cm.options.readOnly != "nocursor" && (!mobile || activeElt() != this.textarea)) {
|
| 10062 |
+
try { this.textarea.focus(); }
|
| 10063 |
catch (e) {} // IE8 will throw if the textarea is display: none or not in DOM
|
| 10064 |
}
|
| 10065 |
};
|
| 10066 |
|
| 10067 |
+
TextareaInput.prototype.blur = function () { this.textarea.blur(); };
|
| 10068 |
|
| 10069 |
TextareaInput.prototype.resetPosition = function () {
|
| 10070 |
+
this.wrapper.style.top = this.wrapper.style.left = 0;
|
| 10071 |
};
|
| 10072 |
|
| 10073 |
+
TextareaInput.prototype.receivedFocus = function () { this.slowPoll(); };
|
| 10074 |
|
| 10075 |
// Poll for input changes, using the normal rate of polling. This
|
| 10076 |
// runs as long as the editor is focused.
|
| 10079 |
|
| 10080 |
if (this.pollingFast) { return }
|
| 10081 |
this.polling.set(this.cm.options.pollInterval, function () {
|
| 10082 |
+
this$1.poll();
|
| 10083 |
+
if (this$1.cm.state.focused) { this$1.slowPoll(); }
|
| 10084 |
+
});
|
| 10085 |
};
|
| 10086 |
|
| 10087 |
// When an event has just come in that is likely to add or change
|
| 10088 |
// something in the input textarea, we poll faster, to ensure that
|
| 10089 |
// the change appears on the screen quickly.
|
| 10090 |
TextareaInput.prototype.fastPoll = function () {
|
| 10091 |
+
var missed = false, input = this;
|
| 10092 |
+
input.pollingFast = true;
|
| 10093 |
function p() {
|
| 10094 |
+
var changed = input.poll();
|
| 10095 |
+
if (!changed && !missed) {missed = true; input.polling.set(60, p);}
|
| 10096 |
+
else {input.pollingFast = false; input.slowPoll();}
|
| 10097 |
}
|
| 10098 |
+
input.polling.set(20, p);
|
| 10099 |
};
|
| 10100 |
|
| 10101 |
// Read input from the textarea, and update the document to match.
|
| 10107 |
TextareaInput.prototype.poll = function () {
|
| 10108 |
var this$1 = this;
|
| 10109 |
|
| 10110 |
+
var cm = this.cm, input = this.textarea, prevInput = this.prevInput;
|
| 10111 |
// Since this is called a *lot*, try to bail out as cheaply as
|
| 10112 |
// possible when it is clear that nothing happened. hasSelection
|
| 10113 |
// will be the case when there is a lot of text in the textarea,
|
| 10117 |
cm.isReadOnly() || cm.options.disableInput || cm.state.keySeq)
|
| 10118 |
{ return false }
|
| 10119 |
|
| 10120 |
+
var text = input.value;
|
| 10121 |
// If nothing changed, bail.
|
| 10122 |
if (text == prevInput && !cm.somethingSelected()) { return false }
|
| 10123 |
// Work around nonsensical selection resetting in IE9/10, and
|
| 10125 |
// some key combos in Mac (#2689).
|
| 10126 |
if (ie && ie_version >= 9 && this.hasSelection === text ||
|
| 10127 |
mac && /[\uf700-\uf7ff]/.test(text)) {
|
| 10128 |
+
cm.display.input.reset();
|
| 10129 |
return false
|
| 10130 |
}
|
| 10131 |
|
| 10132 |
if (cm.doc.sel == cm.display.selForContextMenu) {
|
| 10133 |
+
var first = text.charCodeAt(0);
|
| 10134 |
+
if (first == 0x200b && !prevInput) { prevInput = "\u200b"; }
|
| 10135 |
if (first == 0x21da) { this.reset(); return this.cm.execCommand("undo") }
|
| 10136 |
}
|
| 10137 |
// Find the part of the input that is actually new
|
| 10138 |
+
var same = 0, l = Math.min(prevInput.length, text.length);
|
| 10139 |
+
while (same < l && prevInput.charCodeAt(same) == text.charCodeAt(same)) { ++same; }
|
| 10140 |
|
| 10141 |
runInOp(cm, function () {
|
| 10142 |
applyTextInput(cm, text.slice(same), prevInput.length - same,
|
| 10143 |
+
null, this$1.composing ? "*compose" : null);
|
| 10144 |
|
| 10145 |
// Don't leave long text in the textarea, since it makes further polling slow
|
| 10146 |
+
if (text.length > 1000 || text.indexOf("\n") > -1) { input.value = this$1.prevInput = ""; }
|
| 10147 |
+
else { this$1.prevInput = text; }
|
| 10148 |
|
| 10149 |
if (this$1.composing) {
|
| 10150 |
+
this$1.composing.range.clear();
|
| 10151 |
this$1.composing.range = cm.markText(this$1.composing.start, cm.getCursor("to"),
|
| 10152 |
+
{className: "CodeMirror-composing"});
|
| 10153 |
}
|
| 10154 |
+
});
|
| 10155 |
return true
|
| 10156 |
};
|
| 10157 |
|
| 10158 |
TextareaInput.prototype.ensurePolled = function () {
|
| 10159 |
+
if (this.pollingFast && this.poll()) { this.pollingFast = false; }
|
| 10160 |
};
|
| 10161 |
|
| 10162 |
TextareaInput.prototype.onKeyPress = function () {
|
| 10163 |
+
if (ie && ie_version >= 9) { this.hasSelection = null; }
|
| 10164 |
+
this.fastPoll();
|
| 10165 |
};
|
| 10166 |
|
| 10167 |
TextareaInput.prototype.onContextMenu = function (e) {
|
| 10168 |
+
var input = this, cm = input.cm, display = cm.display, te = input.textarea;
|
| 10169 |
+
var pos = posFromMouse(cm, e), scrollPos = display.scroller.scrollTop;
|
| 10170 |
if (!pos || presto) { return } // Opera is difficult.
|
| 10171 |
|
| 10172 |
// Reset the current text selection only if the click is done outside of the selection
|
| 10173 |
// and 'resetSelectionOnContextMenu' option is true.
|
| 10174 |
+
var reset = cm.options.resetSelectionOnContextMenu;
|
| 10175 |
if (reset && cm.doc.sel.contains(pos) == -1)
|
| 10176 |
+
{ operation(cm, setSelection)(cm.doc, simpleSelection(pos), sel_dontScroll); }
|
| 10177 |
+
|
| 10178 |
+
var oldCSS = te.style.cssText, oldWrapperCSS = input.wrapper.style.cssText;
|
| 10179 |
+
input.wrapper.style.cssText = "position: absolute";
|
| 10180 |
+
var wrapperBox = input.wrapper.getBoundingClientRect();
|
| 10181 |
+
te.style.cssText = "position: absolute; width: 30px; height: 30px;\n top: " + (e.clientY - wrapperBox.top - 5) + "px; left: " + (e.clientX - wrapperBox.left - 5) + "px;\n z-index: 1000; background: " + (ie ? "rgba(255, 255, 255, .05)" : "transparent") + ";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);";
|
| 10182 |
+
var oldScrollY;
|
| 10183 |
+
if (webkit) { oldScrollY = window.scrollY; } // Work around Chrome issue (#2712)
|
| 10184 |
+
display.input.focus();
|
| 10185 |
+
if (webkit) { window.scrollTo(null, oldScrollY); }
|
| 10186 |
+
display.input.reset();
|
| 10187 |
// Adds "Select all" to context menu in FF
|
| 10188 |
+
if (!cm.somethingSelected()) { te.value = input.prevInput = " "; }
|
| 10189 |
+
input.contextMenuPending = true;
|
| 10190 |
+
display.selForContextMenu = cm.doc.sel;
|
| 10191 |
+
clearTimeout(display.detectingSelectAll);
|
| 10192 |
|
| 10193 |
// Select-all will be greyed out if there's nothing to select, so
|
| 10194 |
// this adds a zero-width space so that we can later check whether
|
| 10195 |
// it got selected.
|
| 10196 |
function prepareSelectAllHack() {
|
| 10197 |
if (te.selectionStart != null) {
|
| 10198 |
+
var selected = cm.somethingSelected();
|
| 10199 |
+
var extval = "\u200b" + (selected ? te.value : "");
|
| 10200 |
+
te.value = "\u21da"; // Used to catch context-menu undo
|
| 10201 |
+
te.value = extval;
|
| 10202 |
+
input.prevInput = selected ? "" : "\u200b";
|
| 10203 |
+
te.selectionStart = 1; te.selectionEnd = extval.length;
|
| 10204 |
// Re-set this, in case some other handler touched the
|
| 10205 |
// selection in the meantime.
|
| 10206 |
+
display.selForContextMenu = cm.doc.sel;
|
| 10207 |
}
|
| 10208 |
}
|
| 10209 |
function rehide() {
|
| 10210 |
+
input.contextMenuPending = false;
|
| 10211 |
+
input.wrapper.style.cssText = oldWrapperCSS;
|
| 10212 |
+
te.style.cssText = oldCSS;
|
| 10213 |
+
if (ie && ie_version < 9) { display.scrollbars.setScrollTop(display.scroller.scrollTop = scrollPos); }
|
| 10214 |
|
| 10215 |
// Try to detect the user choosing select-all
|
| 10216 |
if (te.selectionStart != null) {
|
| 10217 |
+
if (!ie || (ie && ie_version < 9)) { prepareSelectAllHack(); }
|
| 10218 |
var i = 0, poll = function () {
|
| 10219 |
if (display.selForContextMenu == cm.doc.sel && te.selectionStart == 0 &&
|
| 10220 |
te.selectionEnd > 0 && input.prevInput == "\u200b") {
|
| 10221 |
+
operation(cm, selectAll)(cm);
|
| 10222 |
} else if (i++ < 10) {
|
| 10223 |
+
display.detectingSelectAll = setTimeout(poll, 500);
|
| 10224 |
} else {
|
| 10225 |
+
display.selForContextMenu = null;
|
| 10226 |
+
display.input.reset();
|
| 10227 |
}
|
| 10228 |
+
};
|
| 10229 |
+
display.detectingSelectAll = setTimeout(poll, 200);
|
| 10230 |
}
|
| 10231 |
}
|
| 10232 |
|
| 10233 |
+
if (ie && ie_version >= 9) { prepareSelectAllHack(); }
|
| 10234 |
if (captureRightClick) {
|
| 10235 |
+
e_stop(e);
|
| 10236 |
var mouseup = function () {
|
| 10237 |
+
off(window, "mouseup", mouseup);
|
| 10238 |
+
setTimeout(rehide, 20);
|
| 10239 |
+
};
|
| 10240 |
+
on(window, "mouseup", mouseup);
|
| 10241 |
} else {
|
| 10242 |
+
setTimeout(rehide, 50);
|
| 10243 |
}
|
| 10244 |
};
|
| 10245 |
|
| 10246 |
TextareaInput.prototype.readOnlyChanged = function (val) {
|
| 10247 |
+
if (!val) { this.reset(); }
|
| 10248 |
};
|
| 10249 |
|
| 10250 |
TextareaInput.prototype.setUneditable = function () {};
|
| 10251 |
|
| 10252 |
+
TextareaInput.prototype.needsContentAttribute = false;
|
| 10253 |
|
| 10254 |
function fromTextArea(textarea, options) {
|
| 10255 |
+
options = options ? copyObj(options) : {};
|
| 10256 |
+
options.value = textarea.value;
|
| 10257 |
if (!options.tabindex && textarea.tabIndex)
|
| 10258 |
+
{ options.tabindex = textarea.tabIndex; }
|
| 10259 |
if (!options.placeholder && textarea.placeholder)
|
| 10260 |
+
{ options.placeholder = textarea.placeholder; }
|
| 10261 |
// Set autofocus to true if this textarea is focused, or if it has
|
| 10262 |
// autofocus and no other element is focused.
|
| 10263 |
if (options.autofocus == null) {
|
| 10264 |
+
var hasFocus = activeElt();
|
| 10265 |
options.autofocus = hasFocus == textarea ||
|
| 10266 |
+
textarea.getAttribute("autofocus") != null && hasFocus == document.body;
|
| 10267 |
}
|
| 10268 |
|
| 10269 |
+
function save() {textarea.value = cm.getValue();}
|
| 10270 |
|
| 10271 |
+
var realSubmit;
|
| 10272 |
if (textarea.form) {
|
| 10273 |
+
on(textarea.form, "submit", save);
|
| 10274 |
// Deplorable hack to make the submit method do the right thing.
|
| 10275 |
if (!options.leaveSubmitMethodAlone) {
|
| 10276 |
+
var form = textarea.form;
|
| 10277 |
+
realSubmit = form.submit;
|
| 10278 |
try {
|
| 10279 |
var wrappedSubmit = form.submit = function () {
|
| 10280 |
+
save();
|
| 10281 |
+
form.submit = realSubmit;
|
| 10282 |
+
form.submit();
|
| 10283 |
+
form.submit = wrappedSubmit;
|
| 10284 |
+
};
|
| 10285 |
} catch(e) {}
|
| 10286 |
}
|
| 10287 |
}
|
| 10288 |
|
| 10289 |
options.finishInit = function (cm) {
|
| 10290 |
+
cm.save = save;
|
| 10291 |
+
cm.getTextArea = function () { return textarea; };
|
| 10292 |
cm.toTextArea = function () {
|
| 10293 |
+
cm.toTextArea = isNaN; // Prevent this from being ran twice
|
| 10294 |
+
save();
|
| 10295 |
+
textarea.parentNode.removeChild(cm.getWrapperElement());
|
| 10296 |
+
textarea.style.display = "";
|
| 10297 |
if (textarea.form) {
|
| 10298 |
+
off(textarea.form, "submit", save);
|
| 10299 |
if (typeof textarea.form.submit == "function")
|
| 10300 |
+
{ textarea.form.submit = realSubmit; }
|
| 10301 |
}
|
| 10302 |
+
};
|
| 10303 |
+
};
|
| 10304 |
|
| 10305 |
+
textarea.style.display = "none";
|
| 10306 |
+
var cm = CodeMirror$1(function (node) { return textarea.parentNode.insertBefore(node, textarea.nextSibling); },
|
| 10307 |
+
options);
|
| 10308 |
return cm
|
| 10309 |
}
|
| 10310 |
|
| 10311 |
function addLegacyProps(CodeMirror) {
|
| 10312 |
+
CodeMirror.off = off;
|
| 10313 |
+
CodeMirror.on = on;
|
| 10314 |
+
CodeMirror.wheelEventPixels = wheelEventPixels;
|
| 10315 |
+
CodeMirror.Doc = Doc;
|
| 10316 |
+
CodeMirror.splitLines = splitLinesAuto;
|
| 10317 |
+
CodeMirror.countColumn = countColumn;
|
| 10318 |
+
CodeMirror.findColumn = findColumn;
|
| 10319 |
+
CodeMirror.isWordChar = isWordCharBasic;
|
| 10320 |
+
CodeMirror.Pass = Pass;
|
| 10321 |
+
CodeMirror.signal = signal;
|
| 10322 |
+
CodeMirror.Line = Line;
|
| 10323 |
+
CodeMirror.changeEnd = changeEnd;
|
| 10324 |
+
CodeMirror.scrollbarModel = scrollbarModel;
|
| 10325 |
+
CodeMirror.Pos = Pos;
|
| 10326 |
+
CodeMirror.cmpPos = cmp;
|
| 10327 |
+
CodeMirror.modes = modes;
|
| 10328 |
+
CodeMirror.mimeModes = mimeModes;
|
| 10329 |
+
CodeMirror.resolveMode = resolveMode;
|
| 10330 |
+
CodeMirror.getMode = getMode;
|
| 10331 |
+
CodeMirror.modeExtensions = modeExtensions;
|
| 10332 |
+
CodeMirror.extendMode = extendMode;
|
| 10333 |
+
CodeMirror.copyState = copyState;
|
| 10334 |
+
CodeMirror.startState = startState;
|
| 10335 |
+
CodeMirror.innerMode = innerMode;
|
| 10336 |
+
CodeMirror.commands = commands;
|
| 10337 |
+
CodeMirror.keyMap = keyMap;
|
| 10338 |
+
CodeMirror.keyName = keyName;
|
| 10339 |
+
CodeMirror.isModifierKey = isModifierKey;
|
| 10340 |
+
CodeMirror.lookupKey = lookupKey;
|
| 10341 |
+
CodeMirror.normalizeKeyMap = normalizeKeyMap;
|
| 10342 |
+
CodeMirror.StringStream = StringStream;
|
| 10343 |
+
CodeMirror.SharedTextMarker = SharedTextMarker;
|
| 10344 |
+
CodeMirror.TextMarker = TextMarker;
|
| 10345 |
+
CodeMirror.LineWidget = LineWidget;
|
| 10346 |
+
CodeMirror.e_preventDefault = e_preventDefault;
|
| 10347 |
+
CodeMirror.e_stopPropagation = e_stopPropagation;
|
| 10348 |
+
CodeMirror.e_stop = e_stop;
|
| 10349 |
+
CodeMirror.addClass = addClass;
|
| 10350 |
+
CodeMirror.contains = contains;
|
| 10351 |
+
CodeMirror.rmClass = rmClass;
|
| 10352 |
+
CodeMirror.keyNames = keyNames;
|
| 10353 |
}
|
| 10354 |
|
| 10355 |
// EDITOR CONSTRUCTOR
|
| 10356 |
|
| 10357 |
+
defineOptions(CodeMirror$1);
|
| 10358 |
|
| 10359 |
+
addEditorMethods(CodeMirror$1);
|
| 10360 |
|
| 10361 |
// Set up methods on CodeMirror's prototype to redirect to the editor's document.
|
| 10362 |
+
var dontDelegate = "iter insert remove copy getEditor constructor".split(" ");
|
| 10363 |
for (var prop in Doc.prototype) { if (Doc.prototype.hasOwnProperty(prop) && indexOf(dontDelegate, prop) < 0)
|
| 10364 |
+
{ CodeMirror$1.prototype[prop] = (function(method) {
|
| 10365 |
return function() {return method.apply(this.doc, arguments)}
|
| 10366 |
+
})(Doc.prototype[prop]); } }
|
| 10367 |
|
| 10368 |
+
eventMixin(Doc);
|
| 10369 |
|
| 10370 |
// INPUT HANDLING
|
| 10371 |
|
| 10372 |
+
CodeMirror$1.inputStyles = {"textarea": TextareaInput, "contenteditable": ContentEditableInput};
|
| 10373 |
|
| 10374 |
// MODE DEFINITION AND QUERYING
|
| 10375 |
|
| 10376 |
// Extra arguments are stored as the mode's dependencies, which is
|
| 10377 |
// used by (legacy) mechanisms like loadmode.js to automatically
|
| 10378 |
// load a mode. (Preferred mechanism is the require/define calls.)
|
| 10379 |
+
CodeMirror$1.defineMode = function(name/*, mode, …*/) {
|
| 10380 |
+
if (!CodeMirror$1.defaults.mode && name != "null") { CodeMirror$1.defaults.mode = name; }
|
| 10381 |
+
defineMode.apply(this, arguments);
|
| 10382 |
+
};
|
| 10383 |
|
| 10384 |
+
CodeMirror$1.defineMIME = defineMIME;
|
| 10385 |
|
| 10386 |
// Minimal default mode.
|
| 10387 |
+
CodeMirror$1.defineMode("null", function () { return ({token: function (stream) { return stream.skipToEnd(); }}); });
|
| 10388 |
+
CodeMirror$1.defineMIME("text/plain", "null");
|
| 10389 |
|
| 10390 |
// EXTENSIONS
|
| 10391 |
|
| 10392 |
+
CodeMirror$1.defineExtension = function (name, func) {
|
| 10393 |
+
CodeMirror$1.prototype[name] = func;
|
| 10394 |
+
};
|
| 10395 |
+
CodeMirror$1.defineDocExtension = function (name, func) {
|
| 10396 |
+
Doc.prototype[name] = func;
|
| 10397 |
+
};
|
| 10398 |
|
| 10399 |
+
CodeMirror$1.fromTextArea = fromTextArea;
|
| 10400 |
|
| 10401 |
+
addLegacyProps(CodeMirror$1);
|
| 10402 |
|
| 10403 |
+
CodeMirror$1.version = "5.25.0";
|
| 10404 |
|
| 10405 |
+
return CodeMirror$1;
|
| 10406 |
|
| 10407 |
})));
|
| 10408 |
|
| 10409 |
+
|
| 10410 |
/***/ },
|
| 10411 |
|
| 10412 |
+
/***/ 461:
|
| 10413 |
/***/ function(module, exports, __webpack_require__) {
|
| 10414 |
|
| 10415 |
// CodeMirror, copyright (c) by Marijn Haverbeke and others
|
| 10417 |
|
| 10418 |
(function(mod) {
|
| 10419 |
if (true) // CommonJS
|
| 10420 |
+
mod(__webpack_require__(459));
|
| 10421 |
else if (typeof define == "function" && define.amd) // AMD
|
| 10422 |
define(["../../lib/codemirror"], mod);
|
| 10423 |
else // Plain browser env
|
| 11081 |
"small", "small-caps", "small-caption", "smaller", "soft-light", "solid", "somali",
|
| 11082 |
"source-atop", "source-in", "source-out", "source-over", "space", "space-around", "space-between", "spell-out", "square",
|
| 11083 |
"square-button", "start", "static", "status-bar", "stretch", "stroke", "sub",
|
| 11084 |
+
"subpixel-antialiased", "super", "sw-resize", "symbolic", "symbols", "system-ui", "table",
|
| 11085 |
"table-caption", "table-cell", "table-column", "table-column-group",
|
| 11086 |
"table-footer-group", "table-header-group", "table-row", "table-row-group",
|
| 11087 |
"tamil",
|
assets/js/mailpoet.js
CHANGED
|
@@ -2,14 +2,14 @@ webpackJsonp([3],[
|
|
| 2 |
/* 0 */
|
| 3 |
/***/ function(module, exports, __webpack_require__) {
|
| 4 |
|
| 5 |
-
__webpack_require__(
|
| 6 |
-
__webpack_require__(
|
| 7 |
-
__webpack_require__(
|
| 8 |
-
__webpack_require__(
|
| 9 |
-
__webpack_require__(
|
| 10 |
-
__webpack_require__(
|
| 11 |
-
__webpack_require__(
|
| 12 |
-
module.exports = __webpack_require__(
|
| 13 |
|
| 14 |
|
| 15 |
/***/ },
|
|
@@ -279,13 +279,20 @@ webpackJsonp([3],[
|
|
| 279 |
/* 264 */,
|
| 280 |
/* 265 */,
|
| 281 |
/* 266 */,
|
| 282 |
-
/* 267
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 283 |
/***/ function(module, exports) {
|
| 284 |
|
| 285 |
module.exports = jQuery;
|
| 286 |
|
| 287 |
/***/ },
|
| 288 |
-
/*
|
| 289 |
/***/ function(module, exports, __webpack_require__) {
|
| 290 |
|
| 291 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
|
@@ -300,16 +307,16 @@ webpackJsonp([3],[
|
|
| 300 |
|
| 301 |
|
| 302 |
/***/ },
|
| 303 |
-
/*
|
| 304 |
-
/*
|
| 305 |
-
/*
|
| 306 |
/***/ function(module, exports, __webpack_require__) {
|
| 307 |
|
| 308 |
-
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["_"] = __webpack_require__(
|
| 309 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 310 |
|
| 311 |
/***/ },
|
| 312 |
-
/*
|
| 313 |
/***/ function(module, exports, __webpack_require__) {
|
| 314 |
|
| 315 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Underscore.js 1.8.3
|
|
@@ -1863,13 +1870,6 @@ webpackJsonp([3],[
|
|
| 1863 |
|
| 1864 |
|
| 1865 |
/***/ },
|
| 1866 |
-
/* 273 */,
|
| 1867 |
-
/* 274 */,
|
| 1868 |
-
/* 275 */,
|
| 1869 |
-
/* 276 */,
|
| 1870 |
-
/* 277 */,
|
| 1871 |
-
/* 278 */,
|
| 1872 |
-
/* 279 */,
|
| 1873 |
/* 280 */,
|
| 1874 |
/* 281 */,
|
| 1875 |
/* 282 */,
|
|
@@ -1880,11 +1880,18 @@ webpackJsonp([3],[
|
|
| 1880 |
/* 287 */,
|
| 1881 |
/* 288 */,
|
| 1882 |
/* 289 */,
|
| 1883 |
-
/* 290
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1884 |
/***/ function(module, exports, __webpack_require__) {
|
| 1885 |
|
| 1886 |
/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
|
| 1887 |
-
//! version : 2.
|
| 1888 |
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
| 1889 |
//! license : MIT
|
| 1890 |
//! momentjs.com
|
|
@@ -1926,6 +1933,10 @@ webpackJsonp([3],[
|
|
| 1926 |
return true;
|
| 1927 |
}
|
| 1928 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1929 |
function isNumber(input) {
|
| 1930 |
return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';
|
| 1931 |
}
|
|
@@ -1982,7 +1993,9 @@ webpackJsonp([3],[
|
|
| 1982 |
userInvalidated : false,
|
| 1983 |
iso : false,
|
| 1984 |
parsedDateParts : [],
|
| 1985 |
-
meridiem : null
|
|
|
|
|
|
|
| 1986 |
};
|
| 1987 |
}
|
| 1988 |
|
|
@@ -2058,10 +2071,6 @@ webpackJsonp([3],[
|
|
| 2058 |
return m;
|
| 2059 |
}
|
| 2060 |
|
| 2061 |
-
function isUndefined(input) {
|
| 2062 |
-
return input === void 0;
|
| 2063 |
-
}
|
| 2064 |
-
|
| 2065 |
// Plugins that add properties should also add the key here (null value),
|
| 2066 |
// so we can properly clone ourselves.
|
| 2067 |
var momentProperties = hooks.momentProperties = [];
|
|
@@ -2101,7 +2110,7 @@ webpackJsonp([3],[
|
|
| 2101 |
}
|
| 2102 |
|
| 2103 |
if (momentProperties.length > 0) {
|
| 2104 |
-
for (i
|
| 2105 |
prop = momentProperties[i];
|
| 2106 |
val = from[prop];
|
| 2107 |
if (!isUndefined(val)) {
|
|
@@ -2238,8 +2247,11 @@ webpackJsonp([3],[
|
|
| 2238 |
}
|
| 2239 |
this._config = config;
|
| 2240 |
// Lenient ordinal parsing accepts just a number in addition to
|
| 2241 |
-
// number + (possibly) stuff coming from
|
| 2242 |
-
|
|
|
|
|
|
|
|
|
|
| 2243 |
}
|
| 2244 |
|
| 2245 |
function mergeConfigs(parentConfig, childConfig) {
|
|
@@ -2337,7 +2349,7 @@ webpackJsonp([3],[
|
|
| 2337 |
}
|
| 2338 |
|
| 2339 |
var defaultOrdinal = '%d';
|
| 2340 |
-
var
|
| 2341 |
|
| 2342 |
function ordinal (number) {
|
| 2343 |
return this._ordinal.replace('%d', number);
|
|
@@ -2347,6 +2359,7 @@ webpackJsonp([3],[
|
|
| 2347 |
future : 'in %s',
|
| 2348 |
past : '%s ago',
|
| 2349 |
s : 'a few seconds',
|
|
|
|
| 2350 |
m : 'a minute',
|
| 2351 |
mm : '%d minutes',
|
| 2352 |
h : 'an hour',
|
|
@@ -2529,7 +2542,7 @@ webpackJsonp([3],[
|
|
| 2529 |
return function (mom) {
|
| 2530 |
var output = '', i;
|
| 2531 |
for (i = 0; i < length; i++) {
|
| 2532 |
-
output += array[i]
|
| 2533 |
}
|
| 2534 |
return output;
|
| 2535 |
};
|
|
@@ -2732,7 +2745,8 @@ webpackJsonp([3],[
|
|
| 2732 |
var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
|
| 2733 |
function localeMonths (m, format) {
|
| 2734 |
if (!m) {
|
| 2735 |
-
return this._months
|
|
|
|
| 2736 |
}
|
| 2737 |
return isArray(this._months) ? this._months[m.month()] :
|
| 2738 |
this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];
|
|
@@ -2741,7 +2755,8 @@ webpackJsonp([3],[
|
|
| 2741 |
var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
|
| 2742 |
function localeMonthsShort (m, format) {
|
| 2743 |
if (!m) {
|
| 2744 |
-
return this._monthsShort
|
|
|
|
| 2745 |
}
|
| 2746 |
return isArray(this._monthsShort) ? this._monthsShort[m.month()] :
|
| 2747 |
this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];
|
|
@@ -3008,11 +3023,11 @@ webpackJsonp([3],[
|
|
| 3008 |
}
|
| 3009 |
|
| 3010 |
function createDate (y, m, d, h, M, s, ms) {
|
| 3011 |
-
//can't just apply() to create a date:
|
| 3012 |
-
//
|
| 3013 |
var date = new Date(y, m, d, h, M, s, ms);
|
| 3014 |
|
| 3015 |
-
//the date constructor remaps years 0-99 to 1900-1999
|
| 3016 |
if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
|
| 3017 |
date.setFullYear(y);
|
| 3018 |
}
|
|
@@ -3022,7 +3037,7 @@ webpackJsonp([3],[
|
|
| 3022 |
function createUTCDate (y) {
|
| 3023 |
var date = new Date(Date.UTC.apply(null, arguments));
|
| 3024 |
|
| 3025 |
-
//the Date.UTC function remaps years 0-99 to 1900-1999
|
| 3026 |
if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
|
| 3027 |
date.setUTCFullYear(y);
|
| 3028 |
}
|
|
@@ -3039,7 +3054,7 @@ webpackJsonp([3],[
|
|
| 3039 |
return -fwdlw + fwd - 1;
|
| 3040 |
}
|
| 3041 |
|
| 3042 |
-
//
|
| 3043 |
function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
|
| 3044 |
var localWeekday = (7 + weekday - dow) % 7,
|
| 3045 |
weekOffset = firstWeekOffset(year, dow, doy),
|
|
@@ -3240,7 +3255,8 @@ webpackJsonp([3],[
|
|
| 3240 |
var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
|
| 3241 |
function localeWeekdays (m, format) {
|
| 3242 |
if (!m) {
|
| 3243 |
-
return this._weekdays
|
|
|
|
| 3244 |
}
|
| 3245 |
return isArray(this._weekdays) ? this._weekdays[m.day()] :
|
| 3246 |
this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
|
|
@@ -3560,8 +3576,10 @@ webpackJsonp([3],[
|
|
| 3560 |
addRegexToken('A', matchMeridiem);
|
| 3561 |
addRegexToken('H', match1to2);
|
| 3562 |
addRegexToken('h', match1to2);
|
|
|
|
| 3563 |
addRegexToken('HH', match1to2, match2);
|
| 3564 |
addRegexToken('hh', match1to2, match2);
|
|
|
|
| 3565 |
|
| 3566 |
addRegexToken('hmm', match3to4);
|
| 3567 |
addRegexToken('hmmss', match5to6);
|
|
@@ -3569,6 +3587,10 @@ webpackJsonp([3],[
|
|
| 3569 |
addRegexToken('Hmmss', match5to6);
|
| 3570 |
|
| 3571 |
addParseToken(['H', 'HH'], HOUR);
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3572 |
addParseToken(['a', 'A'], function (input, array, config) {
|
| 3573 |
config._isPm = config._locale.isPM(input);
|
| 3574 |
config._meridiem = input;
|
|
@@ -3639,7 +3661,7 @@ webpackJsonp([3],[
|
|
| 3639 |
longDateFormat: defaultLongDateFormat,
|
| 3640 |
invalidDate: defaultInvalidDate,
|
| 3641 |
ordinal: defaultOrdinal,
|
| 3642 |
-
|
| 3643 |
relativeTime: defaultRelativeTime,
|
| 3644 |
|
| 3645 |
months: defaultLocaleMonths,
|
|
@@ -3697,7 +3719,7 @@ webpackJsonp([3],[
|
|
| 3697 |
module && module.exports) {
|
| 3698 |
try {
|
| 3699 |
oldLocale = globalLocale._abbr;
|
| 3700 |
-
__webpack_require__(
|
| 3701 |
// because defineLocale currently also sets the global locale, we
|
| 3702 |
// want to undo that for lazy loaded locales
|
| 3703 |
getSetGlobalLocale(oldLocale);
|
|
@@ -3950,6 +3972,77 @@ webpackJsonp([3],[
|
|
| 3950 |
}
|
| 3951 |
}
|
| 3952 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3953 |
// date from iso format or fallback
|
| 3954 |
function configFromString(config) {
|
| 3955 |
var matched = aspNetJsonRegex.exec(config._i);
|
|
@@ -3962,13 +4055,24 @@ webpackJsonp([3],[
|
|
| 3962 |
configFromISO(config);
|
| 3963 |
if (config._isValid === false) {
|
| 3964 |
delete config._isValid;
|
| 3965 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 3966 |
}
|
|
|
|
|
|
|
|
|
|
| 3967 |
}
|
| 3968 |
|
| 3969 |
hooks.createFromInputFallback = deprecate(
|
| 3970 |
-
'value provided is not in a recognized ISO format. moment construction falls back to js Date(), ' +
|
| 3971 |
-
'which is not reliable across all browsers and versions. Non ISO date formats are ' +
|
| 3972 |
'discouraged and will be removed in an upcoming major release. Please refer to ' +
|
| 3973 |
'http://momentjs.com/guides/#/warnings/js-date/ for more info.',
|
| 3974 |
function (config) {
|
|
@@ -4015,10 +4119,10 @@ webpackJsonp([3],[
|
|
| 4015 |
}
|
| 4016 |
|
| 4017 |
//if the day of the year is set, figure out what it is
|
| 4018 |
-
if (config._dayOfYear) {
|
| 4019 |
yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
|
| 4020 |
|
| 4021 |
-
if (config._dayOfYear > daysInYear(yearToUse)) {
|
| 4022 |
getParsingFlags(config)._overflowDayOfYear = true;
|
| 4023 |
}
|
| 4024 |
|
|
@@ -4122,6 +4226,9 @@ webpackJsonp([3],[
|
|
| 4122 |
// constant that refers to the ISO standard
|
| 4123 |
hooks.ISO_8601 = function () {};
|
| 4124 |
|
|
|
|
|
|
|
|
|
|
| 4125 |
// date from string and format string
|
| 4126 |
function configFromStringAndFormat(config) {
|
| 4127 |
// TODO: Move this to another part of the creation flow to prevent circular deps
|
|
@@ -4129,7 +4236,10 @@ webpackJsonp([3],[
|
|
| 4129 |
configFromISO(config);
|
| 4130 |
return;
|
| 4131 |
}
|
| 4132 |
-
|
|
|
|
|
|
|
|
|
|
| 4133 |
config._a = [];
|
| 4134 |
getParsingFlags(config).empty = true;
|
| 4135 |
|
|
@@ -4321,7 +4431,7 @@ webpackJsonp([3],[
|
|
| 4321 |
|
| 4322 |
function configFromInput(config) {
|
| 4323 |
var input = config._i;
|
| 4324 |
-
if (input
|
| 4325 |
config._d = new Date(hooks.now());
|
| 4326 |
} else if (isDate(input)) {
|
| 4327 |
config._d = new Date(input.valueOf());
|
|
@@ -4332,7 +4442,7 @@ webpackJsonp([3],[
|
|
| 4332 |
return parseInt(obj, 10);
|
| 4333 |
});
|
| 4334 |
configFromArray(config);
|
| 4335 |
-
} else if (
|
| 4336 |
configFromObject(config);
|
| 4337 |
} else if (isNumber(input)) {
|
| 4338 |
// from milliseconds
|
|
@@ -4433,6 +4543,38 @@ webpackJsonp([3],[
|
|
| 4433 |
return Date.now ? Date.now() : +(new Date());
|
| 4434 |
};
|
| 4435 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4436 |
function Duration (duration) {
|
| 4437 |
var normalizedInput = normalizeObjectUnits(duration),
|
| 4438 |
years = normalizedInput.year || 0,
|
|
@@ -4445,6 +4587,8 @@ webpackJsonp([3],[
|
|
| 4445 |
seconds = normalizedInput.second || 0,
|
| 4446 |
milliseconds = normalizedInput.millisecond || 0;
|
| 4447 |
|
|
|
|
|
|
|
| 4448 |
// representation for dateAddRemove
|
| 4449 |
this._milliseconds = +milliseconds +
|
| 4450 |
seconds * 1e3 + // 1000
|
|
@@ -4568,7 +4712,7 @@ webpackJsonp([3],[
|
|
| 4568 |
// a second time. In case it wants us to change the offset again
|
| 4569 |
// _changeInProgress == true case, then we have to adjust, because
|
| 4570 |
// there is no such time in the given timezone.
|
| 4571 |
-
function getSetOffset (input, keepLocalTime) {
|
| 4572 |
var offset = this._offset || 0,
|
| 4573 |
localAdjust;
|
| 4574 |
if (!this.isValid()) {
|
|
@@ -4580,7 +4724,7 @@ webpackJsonp([3],[
|
|
| 4580 |
if (input === null) {
|
| 4581 |
return this;
|
| 4582 |
}
|
| 4583 |
-
} else if (Math.abs(input) < 16) {
|
| 4584 |
input = input * 60;
|
| 4585 |
}
|
| 4586 |
if (!this._isUTC && keepLocalTime) {
|
|
@@ -4638,7 +4782,7 @@ webpackJsonp([3],[
|
|
| 4638 |
|
| 4639 |
function setOffsetToParsedOffset () {
|
| 4640 |
if (this._tzm != null) {
|
| 4641 |
-
this.utcOffset(this._tzm);
|
| 4642 |
} else if (typeof this._i === 'string') {
|
| 4643 |
var tZone = offsetFromString(matchOffset, this._i);
|
| 4644 |
if (tZone != null) {
|
|
@@ -4770,6 +4914,7 @@ webpackJsonp([3],[
|
|
| 4770 |
}
|
| 4771 |
|
| 4772 |
createDuration.fn = Duration.prototype;
|
|
|
|
| 4773 |
|
| 4774 |
function parseIso (inp, sign) {
|
| 4775 |
// We'd normally use ~~inp for this, but unfortunately it also
|
|
@@ -5006,18 +5151,19 @@ webpackJsonp([3],[
|
|
| 5006 |
return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
|
| 5007 |
}
|
| 5008 |
|
| 5009 |
-
function toISOString
|
|
|
|
|
|
|
|
|
|
| 5010 |
var m = this.clone().utc();
|
| 5011 |
-
if (
|
| 5012 |
-
if (isFunction(Date.prototype.toISOString)) {
|
| 5013 |
-
// native implementation is ~50x faster, use it when we can
|
| 5014 |
-
return this.toDate().toISOString();
|
| 5015 |
-
} else {
|
| 5016 |
-
return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 5017 |
-
}
|
| 5018 |
-
} else {
|
| 5019 |
return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 5020 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5021 |
}
|
| 5022 |
|
| 5023 |
/**
|
|
@@ -5037,7 +5183,7 @@ webpackJsonp([3],[
|
|
| 5037 |
zone = 'Z';
|
| 5038 |
}
|
| 5039 |
var prefix = '[' + func + '("]';
|
| 5040 |
-
var year = (0
|
| 5041 |
var datetime = '-MM-DD[T]HH:mm:ss.SSS';
|
| 5042 |
var suffix = zone + '[")]';
|
| 5043 |
|
|
@@ -5205,7 +5351,7 @@ webpackJsonp([3],[
|
|
| 5205 |
return this.isValid() ? this.toISOString() : null;
|
| 5206 |
}
|
| 5207 |
|
| 5208 |
-
function isValid$
|
| 5209 |
return isValid(this);
|
| 5210 |
}
|
| 5211 |
|
|
@@ -5365,7 +5511,10 @@ webpackJsonp([3],[
|
|
| 5365 |
addRegexToken('D', match1to2);
|
| 5366 |
addRegexToken('DD', match1to2, match2);
|
| 5367 |
addRegexToken('Do', function (isStrict, locale) {
|
| 5368 |
-
|
|
|
|
|
|
|
|
|
|
| 5369 |
});
|
| 5370 |
|
| 5371 |
addParseToken(['D', 'DD'], DATE);
|
|
@@ -5545,7 +5694,7 @@ webpackJsonp([3],[
|
|
| 5545 |
proto.isSame = isSame;
|
| 5546 |
proto.isSameOrAfter = isSameOrAfter;
|
| 5547 |
proto.isSameOrBefore = isSameOrBefore;
|
| 5548 |
-
proto.isValid = isValid$
|
| 5549 |
proto.lang = lang;
|
| 5550 |
proto.locale = locale;
|
| 5551 |
proto.localeData = localeData;
|
|
@@ -5770,7 +5919,7 @@ webpackJsonp([3],[
|
|
| 5770 |
}
|
| 5771 |
|
| 5772 |
getSetGlobalLocale('en', {
|
| 5773 |
-
|
| 5774 |
ordinal : function (number) {
|
| 5775 |
var b = number % 10,
|
| 5776 |
output = (toInt(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -5891,6 +6040,9 @@ webpackJsonp([3],[
|
|
| 5891 |
}
|
| 5892 |
|
| 5893 |
function as (units) {
|
|
|
|
|
|
|
|
|
|
| 5894 |
var days;
|
| 5895 |
var months;
|
| 5896 |
var milliseconds = this._milliseconds;
|
|
@@ -5919,6 +6071,9 @@ webpackJsonp([3],[
|
|
| 5919 |
|
| 5920 |
// TODO: Use this.as('ms')?
|
| 5921 |
function valueOf$1 () {
|
|
|
|
|
|
|
|
|
|
| 5922 |
return (
|
| 5923 |
this._milliseconds +
|
| 5924 |
this._days * 864e5 +
|
|
@@ -5944,12 +6099,12 @@ webpackJsonp([3],[
|
|
| 5944 |
|
| 5945 |
function get$2 (units) {
|
| 5946 |
units = normalizeUnits(units);
|
| 5947 |
-
return this[units + 's']();
|
| 5948 |
}
|
| 5949 |
|
| 5950 |
function makeGetter(name) {
|
| 5951 |
return function () {
|
| 5952 |
-
return this._data[name];
|
| 5953 |
};
|
| 5954 |
}
|
| 5955 |
|
|
@@ -5967,11 +6122,12 @@ webpackJsonp([3],[
|
|
| 5967 |
|
| 5968 |
var round = Math.round;
|
| 5969 |
var thresholds = {
|
| 5970 |
-
|
| 5971 |
-
|
| 5972 |
-
|
| 5973 |
-
|
| 5974 |
-
|
|
|
|
| 5975 |
};
|
| 5976 |
|
| 5977 |
// helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize
|
|
@@ -5988,16 +6144,17 @@ webpackJsonp([3],[
|
|
| 5988 |
var months = round(duration.as('M'));
|
| 5989 |
var years = round(duration.as('y'));
|
| 5990 |
|
| 5991 |
-
var a = seconds
|
| 5992 |
-
|
| 5993 |
-
minutes
|
| 5994 |
-
|
| 5995 |
-
hours
|
| 5996 |
-
|
| 5997 |
-
days
|
| 5998 |
-
|
| 5999 |
-
months
|
| 6000 |
-
|
|
|
|
| 6001 |
|
| 6002 |
a[2] = withoutSuffix;
|
| 6003 |
a[3] = +posNegDuration > 0;
|
|
@@ -6026,10 +6183,17 @@ webpackJsonp([3],[
|
|
| 6026 |
return thresholds[threshold];
|
| 6027 |
}
|
| 6028 |
thresholds[threshold] = limit;
|
|
|
|
|
|
|
|
|
|
| 6029 |
return true;
|
| 6030 |
}
|
| 6031 |
|
| 6032 |
function humanize (withSuffix) {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6033 |
var locale = this.localeData();
|
| 6034 |
var output = relativeTime$1(this, !withSuffix, locale);
|
| 6035 |
|
|
@@ -6050,6 +6214,10 @@ webpackJsonp([3],[
|
|
| 6050 |
// This is because there is no context-free conversion between hours and days
|
| 6051 |
// (think of clock changes)
|
| 6052 |
// and also not between days and months (28-31 days per month)
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6053 |
var seconds = abs$1(this._milliseconds) / 1000;
|
| 6054 |
var days = abs$1(this._days);
|
| 6055 |
var months = abs$1(this._months);
|
|
@@ -6094,6 +6262,7 @@ webpackJsonp([3],[
|
|
| 6094 |
|
| 6095 |
var proto$2 = Duration.prototype;
|
| 6096 |
|
|
|
|
| 6097 |
proto$2.abs = abs;
|
| 6098 |
proto$2.add = add$1;
|
| 6099 |
proto$2.subtract = subtract$1;
|
|
@@ -6149,7 +6318,7 @@ webpackJsonp([3],[
|
|
| 6149 |
// Side effect imports
|
| 6150 |
|
| 6151 |
|
| 6152 |
-
hooks.version = '2.
|
| 6153 |
|
| 6154 |
setHookCallback(createLocal);
|
| 6155 |
|
|
@@ -6185,10 +6354,10 @@ webpackJsonp([3],[
|
|
| 6185 |
|
| 6186 |
})));
|
| 6187 |
|
| 6188 |
-
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(
|
| 6189 |
|
| 6190 |
/***/ },
|
| 6191 |
-
/*
|
| 6192 |
/***/ function(module, exports) {
|
| 6193 |
|
| 6194 |
module.exports = function(module) {
|
|
@@ -6204,226 +6373,240 @@ webpackJsonp([3],[
|
|
| 6204 |
|
| 6205 |
|
| 6206 |
/***/ },
|
| 6207 |
-
/*
|
| 6208 |
/***/ function(module, exports, __webpack_require__) {
|
| 6209 |
|
| 6210 |
var map = {
|
| 6211 |
-
"./af":
|
| 6212 |
-
"./af.js":
|
| 6213 |
-
"./ar":
|
| 6214 |
-
"./ar-dz":
|
| 6215 |
-
"./ar-dz.js":
|
| 6216 |
-
"./ar-
|
| 6217 |
-
"./ar-
|
| 6218 |
-
"./ar-
|
| 6219 |
-
"./ar-
|
| 6220 |
-
"./ar-
|
| 6221 |
-
"./ar-
|
| 6222 |
-
"./ar-
|
| 6223 |
-
"./ar-
|
| 6224 |
-
"./ar
|
| 6225 |
-
"./
|
| 6226 |
-
"./
|
| 6227 |
-
"./
|
| 6228 |
-
"./
|
| 6229 |
-
"./
|
| 6230 |
-
"./
|
| 6231 |
-
"./
|
| 6232 |
-
"./
|
| 6233 |
-
"./
|
| 6234 |
-
"./
|
| 6235 |
-
"./
|
| 6236 |
-
"./
|
| 6237 |
-
"./
|
| 6238 |
-
"./
|
| 6239 |
-
"./
|
| 6240 |
-
"./
|
| 6241 |
-
"./
|
| 6242 |
-
"./
|
| 6243 |
-
"./
|
| 6244 |
-
"./
|
| 6245 |
-
"./
|
| 6246 |
-
"./
|
| 6247 |
-
"./
|
| 6248 |
-
"./
|
| 6249 |
-
"./
|
| 6250 |
-
"./
|
| 6251 |
-
"./de
|
| 6252 |
-
"./de
|
| 6253 |
-
"./
|
| 6254 |
-
"./
|
| 6255 |
-
"./
|
| 6256 |
-
"./
|
| 6257 |
-
"./
|
| 6258 |
-
"./
|
| 6259 |
-
"./
|
| 6260 |
-
"./
|
| 6261 |
-
"./en-
|
| 6262 |
-
"./en-
|
| 6263 |
-
"./en-
|
| 6264 |
-
"./en-
|
| 6265 |
-
"./en-
|
| 6266 |
-
"./en-
|
| 6267 |
-
"./
|
| 6268 |
-
"./
|
| 6269 |
-
"./
|
| 6270 |
-
"./
|
| 6271 |
-
"./
|
| 6272 |
-
"./
|
| 6273 |
-
"./
|
| 6274 |
-
"./
|
| 6275 |
-
"./
|
| 6276 |
-
"./
|
| 6277 |
-
"./
|
| 6278 |
-
"./
|
| 6279 |
-
"./
|
| 6280 |
-
"./
|
| 6281 |
-
"./
|
| 6282 |
-
"./
|
| 6283 |
-
"./
|
| 6284 |
-
"./
|
| 6285 |
-
"./
|
| 6286 |
-
"./
|
| 6287 |
-
"./fr
|
| 6288 |
-
"./fr
|
| 6289 |
-
"./
|
| 6290 |
-
"./
|
| 6291 |
-
"./
|
| 6292 |
-
"./
|
| 6293 |
-
"./
|
| 6294 |
-
"./
|
| 6295 |
-
"./
|
| 6296 |
-
"./
|
| 6297 |
-
"./
|
| 6298 |
-
"./
|
| 6299 |
-
"./
|
| 6300 |
-
"./
|
| 6301 |
-
"./
|
| 6302 |
-
"./
|
| 6303 |
-
"./
|
| 6304 |
-
"./
|
| 6305 |
-
"./
|
| 6306 |
-
"./
|
| 6307 |
-
"./
|
| 6308 |
-
"./
|
| 6309 |
-
"./
|
| 6310 |
-
"./
|
| 6311 |
-
"./
|
| 6312 |
-
"./
|
| 6313 |
-
"./
|
| 6314 |
-
"./
|
| 6315 |
-
"./
|
| 6316 |
-
"./
|
| 6317 |
-
"./
|
| 6318 |
-
"./
|
| 6319 |
-
"./
|
| 6320 |
-
"./
|
| 6321 |
-
"./
|
| 6322 |
-
"./
|
| 6323 |
-
"./
|
| 6324 |
-
"./
|
| 6325 |
-
"./
|
| 6326 |
-
"./
|
| 6327 |
-
"./
|
| 6328 |
-
"./
|
| 6329 |
-
"./
|
| 6330 |
-
"./
|
| 6331 |
-
"./
|
| 6332 |
-
"./
|
| 6333 |
-
"./
|
| 6334 |
-
"./
|
| 6335 |
-
"./
|
| 6336 |
-
"./
|
| 6337 |
-
"./
|
| 6338 |
-
"./
|
| 6339 |
-
"./
|
| 6340 |
-
"./
|
| 6341 |
-
"./
|
| 6342 |
-
"./
|
| 6343 |
-
"./
|
| 6344 |
-
"./
|
| 6345 |
-
"./
|
| 6346 |
-
"./
|
| 6347 |
-
"./
|
| 6348 |
-
"./
|
| 6349 |
-
"./
|
| 6350 |
-
"./
|
| 6351 |
-
"./
|
| 6352 |
-
"./
|
| 6353 |
-
"./
|
| 6354 |
-
"./
|
| 6355 |
-
"./
|
| 6356 |
-
"./
|
| 6357 |
-
"./
|
| 6358 |
-
"./
|
| 6359 |
-
"./
|
| 6360 |
-
"./
|
| 6361 |
-
"./
|
| 6362 |
-
"./
|
| 6363 |
-
"./
|
| 6364 |
-
"./
|
| 6365 |
-
"./
|
| 6366 |
-
"./
|
| 6367 |
-
"./
|
| 6368 |
-
"./
|
| 6369 |
-
"./
|
| 6370 |
-
"./
|
| 6371 |
-
"./
|
| 6372 |
-
"./
|
| 6373 |
-
"./
|
| 6374 |
-
"./
|
| 6375 |
-
"./
|
| 6376 |
-
"./
|
| 6377 |
-
"./
|
| 6378 |
-
"./
|
| 6379 |
-
"./
|
| 6380 |
-
"./
|
| 6381 |
-
"./
|
| 6382 |
-
"./
|
| 6383 |
-
"./
|
| 6384 |
-
"./
|
| 6385 |
-
"./
|
| 6386 |
-
"./
|
| 6387 |
-
"./
|
| 6388 |
-
"./
|
| 6389 |
-
"./
|
| 6390 |
-
"./
|
| 6391 |
-
"./
|
| 6392 |
-
"./
|
| 6393 |
-
"./
|
| 6394 |
-
"./
|
| 6395 |
-
"./
|
| 6396 |
-
"./
|
| 6397 |
-
"./
|
| 6398 |
-
"./
|
| 6399 |
-
"./
|
| 6400 |
-
"./
|
| 6401 |
-
"./
|
| 6402 |
-
"./
|
| 6403 |
-
"./
|
| 6404 |
-
"./
|
| 6405 |
-
"./
|
| 6406 |
-
"./
|
| 6407 |
-
"./
|
| 6408 |
-
"./
|
| 6409 |
-
"./
|
| 6410 |
-
"./
|
| 6411 |
-
"./
|
| 6412 |
-
"./
|
| 6413 |
-
"./
|
| 6414 |
-
"./
|
| 6415 |
-
"./
|
| 6416 |
-
"./
|
| 6417 |
-
"./
|
| 6418 |
-
"./
|
| 6419 |
-
"./
|
| 6420 |
-
"./
|
| 6421 |
-
"./
|
| 6422 |
-
"./
|
| 6423 |
-
"./
|
| 6424 |
-
"./
|
| 6425 |
-
"./
|
| 6426 |
-
"./
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6427 |
};
|
| 6428 |
function webpackContext(req) {
|
| 6429 |
return __webpack_require__(webpackContextResolve(req));
|
|
@@ -6436,11 +6619,11 @@ webpackJsonp([3],[
|
|
| 6436 |
};
|
| 6437 |
webpackContext.resolve = webpackContextResolve;
|
| 6438 |
module.exports = webpackContext;
|
| 6439 |
-
webpackContext.id =
|
| 6440 |
|
| 6441 |
|
| 6442 |
/***/ },
|
| 6443 |
-
/*
|
| 6444 |
/***/ function(module, exports, __webpack_require__) {
|
| 6445 |
|
| 6446 |
//! moment.js locale configuration
|
|
@@ -6448,7 +6631,7 @@ webpackJsonp([3],[
|
|
| 6448 |
//! author : Werner Mollentze : https://github.com/wernerm
|
| 6449 |
|
| 6450 |
;(function (global, factory) {
|
| 6451 |
-
true ? factory(__webpack_require__(
|
| 6452 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6453 |
factory(global.moment)
|
| 6454 |
}(this, (function (moment) { 'use strict';
|
|
@@ -6502,7 +6685,7 @@ webpackJsonp([3],[
|
|
| 6502 |
y : '\'n jaar',
|
| 6503 |
yy : '%d jaar'
|
| 6504 |
},
|
| 6505 |
-
|
| 6506 |
ordinal : function (number) {
|
| 6507 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de'); // Thanks to Joris Röling : https://github.com/jjupiter
|
| 6508 |
},
|
|
@@ -6518,7 +6701,7 @@ webpackJsonp([3],[
|
|
| 6518 |
|
| 6519 |
|
| 6520 |
/***/ },
|
| 6521 |
-
/*
|
| 6522 |
/***/ function(module, exports, __webpack_require__) {
|
| 6523 |
|
| 6524 |
//! moment.js locale configuration
|
|
@@ -6528,7 +6711,7 @@ webpackJsonp([3],[
|
|
| 6528 |
//! author : forabi https://github.com/forabi
|
| 6529 |
|
| 6530 |
;(function (global, factory) {
|
| 6531 |
-
true ? factory(__webpack_require__(
|
| 6532 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6533 |
factory(global.moment)
|
| 6534 |
}(this, (function (moment) { 'use strict';
|
|
@@ -6665,7 +6848,7 @@ webpackJsonp([3],[
|
|
| 6665 |
|
| 6666 |
|
| 6667 |
/***/ },
|
| 6668 |
-
/*
|
| 6669 |
/***/ function(module, exports, __webpack_require__) {
|
| 6670 |
|
| 6671 |
//! moment.js locale configuration
|
|
@@ -6673,7 +6856,7 @@ webpackJsonp([3],[
|
|
| 6673 |
//! author : Noureddine LOUAHEDJ : https://github.com/noureddineme
|
| 6674 |
|
| 6675 |
;(function (global, factory) {
|
| 6676 |
-
true ? factory(__webpack_require__(
|
| 6677 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6678 |
factory(global.moment)
|
| 6679 |
}(this, (function (moment) { 'use strict';
|
|
@@ -6729,7 +6912,71 @@ webpackJsonp([3],[
|
|
| 6729 |
|
| 6730 |
|
| 6731 |
/***/ },
|
| 6732 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6733 |
/***/ function(module, exports, __webpack_require__) {
|
| 6734 |
|
| 6735 |
//! moment.js locale configuration
|
|
@@ -6737,7 +6984,7 @@ webpackJsonp([3],[
|
|
| 6737 |
//! author : Ali Hmer: https://github.com/kikoanis
|
| 6738 |
|
| 6739 |
;(function (global, factory) {
|
| 6740 |
-
true ? factory(__webpack_require__(
|
| 6741 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6742 |
factory(global.moment)
|
| 6743 |
}(this, (function (moment) { 'use strict';
|
|
@@ -6860,7 +7107,7 @@ webpackJsonp([3],[
|
|
| 6860 |
|
| 6861 |
|
| 6862 |
/***/ },
|
| 6863 |
-
/*
|
| 6864 |
/***/ function(module, exports, __webpack_require__) {
|
| 6865 |
|
| 6866 |
//! moment.js locale configuration
|
|
@@ -6869,7 +7116,7 @@ webpackJsonp([3],[
|
|
| 6869 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 6870 |
|
| 6871 |
;(function (global, factory) {
|
| 6872 |
-
true ? factory(__webpack_require__(
|
| 6873 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6874 |
factory(global.moment)
|
| 6875 |
}(this, (function (moment) { 'use strict';
|
|
@@ -6925,7 +7172,7 @@ webpackJsonp([3],[
|
|
| 6925 |
|
| 6926 |
|
| 6927 |
/***/ },
|
| 6928 |
-
/*
|
| 6929 |
/***/ function(module, exports, __webpack_require__) {
|
| 6930 |
|
| 6931 |
//! moment.js locale configuration
|
|
@@ -6933,7 +7180,7 @@ webpackJsonp([3],[
|
|
| 6933 |
//! author : Suhail Alkowaileet : https://github.com/xsoh
|
| 6934 |
|
| 6935 |
;(function (global, factory) {
|
| 6936 |
-
true ? factory(__webpack_require__(
|
| 6937 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6938 |
factory(global.moment)
|
| 6939 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7035,7 +7282,7 @@ webpackJsonp([3],[
|
|
| 7035 |
|
| 7036 |
|
| 7037 |
/***/ },
|
| 7038 |
-
/*
|
| 7039 |
/***/ function(module, exports, __webpack_require__) {
|
| 7040 |
|
| 7041 |
//! moment.js locale configuration
|
|
@@ -7043,7 +7290,7 @@ webpackJsonp([3],[
|
|
| 7043 |
//! author : Nader Toukabri : https://github.com/naderio
|
| 7044 |
|
| 7045 |
;(function (global, factory) {
|
| 7046 |
-
true ? factory(__webpack_require__(
|
| 7047 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7048 |
factory(global.moment)
|
| 7049 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7099,7 +7346,7 @@ webpackJsonp([3],[
|
|
| 7099 |
|
| 7100 |
|
| 7101 |
/***/ },
|
| 7102 |
-
/*
|
| 7103 |
/***/ function(module, exports, __webpack_require__) {
|
| 7104 |
|
| 7105 |
//! moment.js locale configuration
|
|
@@ -7107,7 +7354,7 @@ webpackJsonp([3],[
|
|
| 7107 |
//! author : topchiyev : https://github.com/topchiyev
|
| 7108 |
|
| 7109 |
;(function (global, factory) {
|
| 7110 |
-
true ? factory(__webpack_require__(
|
| 7111 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7112 |
factory(global.moment)
|
| 7113 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7187,7 +7434,7 @@ webpackJsonp([3],[
|
|
| 7187 |
return 'axşam';
|
| 7188 |
}
|
| 7189 |
},
|
| 7190 |
-
|
| 7191 |
ordinal : function (number) {
|
| 7192 |
if (number === 0) { // special case for zero
|
| 7193 |
return number + '-ıncı';
|
|
@@ -7209,7 +7456,7 @@ webpackJsonp([3],[
|
|
| 7209 |
|
| 7210 |
|
| 7211 |
/***/ },
|
| 7212 |
-
/*
|
| 7213 |
/***/ function(module, exports, __webpack_require__) {
|
| 7214 |
|
| 7215 |
//! moment.js locale configuration
|
|
@@ -7219,7 +7466,7 @@ webpackJsonp([3],[
|
|
| 7219 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 7220 |
|
| 7221 |
;(function (global, factory) {
|
| 7222 |
-
true ? factory(__webpack_require__(
|
| 7223 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7224 |
factory(global.moment)
|
| 7225 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7321,7 +7568,7 @@ webpackJsonp([3],[
|
|
| 7321 |
return 'вечара';
|
| 7322 |
}
|
| 7323 |
},
|
| 7324 |
-
|
| 7325 |
ordinal: function (number, period) {
|
| 7326 |
switch (period) {
|
| 7327 |
case 'M':
|
|
@@ -7348,7 +7595,7 @@ webpackJsonp([3],[
|
|
| 7348 |
|
| 7349 |
|
| 7350 |
/***/ },
|
| 7351 |
-
/*
|
| 7352 |
/***/ function(module, exports, __webpack_require__) {
|
| 7353 |
|
| 7354 |
//! moment.js locale configuration
|
|
@@ -7356,7 +7603,7 @@ webpackJsonp([3],[
|
|
| 7356 |
//! author : Krasen Borisov : https://github.com/kraz
|
| 7357 |
|
| 7358 |
;(function (global, factory) {
|
| 7359 |
-
true ? factory(__webpack_require__(
|
| 7360 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7361 |
factory(global.moment)
|
| 7362 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7411,7 +7658,7 @@ webpackJsonp([3],[
|
|
| 7411 |
y : 'година',
|
| 7412 |
yy : '%d години'
|
| 7413 |
},
|
| 7414 |
-
|
| 7415 |
ordinal : function (number) {
|
| 7416 |
var lastDigit = number % 10,
|
| 7417 |
last2Digits = number % 100;
|
|
@@ -7443,7 +7690,7 @@ webpackJsonp([3],[
|
|
| 7443 |
|
| 7444 |
|
| 7445 |
/***/ },
|
| 7446 |
-
/*
|
| 7447 |
/***/ function(module, exports, __webpack_require__) {
|
| 7448 |
|
| 7449 |
//! moment.js locale configuration
|
|
@@ -7451,7 +7698,7 @@ webpackJsonp([3],[
|
|
| 7451 |
//! author : Kaushik Gandhi : https://github.com/kaushikgandhi
|
| 7452 |
|
| 7453 |
;(function (global, factory) {
|
| 7454 |
-
true ? factory(__webpack_require__(
|
| 7455 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7456 |
factory(global.moment)
|
| 7457 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7567,7 +7814,7 @@ webpackJsonp([3],[
|
|
| 7567 |
|
| 7568 |
|
| 7569 |
/***/ },
|
| 7570 |
-
/*
|
| 7571 |
/***/ function(module, exports, __webpack_require__) {
|
| 7572 |
|
| 7573 |
//! moment.js locale configuration
|
|
@@ -7575,7 +7822,7 @@ webpackJsonp([3],[
|
|
| 7575 |
//! author : Thupten N. Chakrishar : https://github.com/vajradog
|
| 7576 |
|
| 7577 |
;(function (global, factory) {
|
| 7578 |
-
true ? factory(__webpack_require__(
|
| 7579 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7580 |
factory(global.moment)
|
| 7581 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7691,7 +7938,7 @@ webpackJsonp([3],[
|
|
| 7691 |
|
| 7692 |
|
| 7693 |
/***/ },
|
| 7694 |
-
/*
|
| 7695 |
/***/ function(module, exports, __webpack_require__) {
|
| 7696 |
|
| 7697 |
//! moment.js locale configuration
|
|
@@ -7699,7 +7946,7 @@ webpackJsonp([3],[
|
|
| 7699 |
//! author : Jean-Baptiste Le Duigou : https://github.com/jbleduigou
|
| 7700 |
|
| 7701 |
;(function (global, factory) {
|
| 7702 |
-
true ? factory(__webpack_require__(
|
| 7703 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7704 |
factory(global.moment)
|
| 7705 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7787,7 +8034,7 @@ webpackJsonp([3],[
|
|
| 7787 |
y : 'ur bloaz',
|
| 7788 |
yy : specialMutationForYears
|
| 7789 |
},
|
| 7790 |
-
|
| 7791 |
ordinal : function (number) {
|
| 7792 |
var output = (number === 1) ? 'añ' : 'vet';
|
| 7793 |
return number + output;
|
|
@@ -7804,7 +8051,7 @@ webpackJsonp([3],[
|
|
| 7804 |
|
| 7805 |
|
| 7806 |
/***/ },
|
| 7807 |
-
/*
|
| 7808 |
/***/ function(module, exports, __webpack_require__) {
|
| 7809 |
|
| 7810 |
//! moment.js locale configuration
|
|
@@ -7813,7 +8060,7 @@ webpackJsonp([3],[
|
|
| 7813 |
//! based on (hr) translation by Bojan Marković
|
| 7814 |
|
| 7815 |
;(function (global, factory) {
|
| 7816 |
-
true ? factory(__webpack_require__(
|
| 7817 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7818 |
factory(global.moment)
|
| 7819 |
}(this, (function (moment) { 'use strict';
|
|
@@ -7938,7 +8185,7 @@ webpackJsonp([3],[
|
|
| 7938 |
y : 'godinu',
|
| 7939 |
yy : translate
|
| 7940 |
},
|
| 7941 |
-
|
| 7942 |
ordinal : '%d.',
|
| 7943 |
week : {
|
| 7944 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -7952,7 +8199,7 @@ webpackJsonp([3],[
|
|
| 7952 |
|
| 7953 |
|
| 7954 |
/***/ },
|
| 7955 |
-
/*
|
| 7956 |
/***/ function(module, exports, __webpack_require__) {
|
| 7957 |
|
| 7958 |
//! moment.js locale configuration
|
|
@@ -7960,15 +8207,19 @@ webpackJsonp([3],[
|
|
| 7960 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 7961 |
|
| 7962 |
;(function (global, factory) {
|
| 7963 |
-
true ? factory(__webpack_require__(
|
| 7964 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7965 |
factory(global.moment)
|
| 7966 |
}(this, (function (moment) { 'use strict';
|
| 7967 |
|
| 7968 |
|
| 7969 |
var ca = moment.defineLocale('ca', {
|
| 7970 |
-
months :
|
| 7971 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7972 |
monthsParseExact : true,
|
| 7973 |
weekdays : 'diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte'.split('_'),
|
| 7974 |
weekdaysShort : 'dg._dl._dt._dc._dj._dv._ds.'.split('_'),
|
|
@@ -7978,9 +8229,12 @@ webpackJsonp([3],[
|
|
| 7978 |
LT : 'H:mm',
|
| 7979 |
LTS : 'H:mm:ss',
|
| 7980 |
L : 'DD/MM/YYYY',
|
| 7981 |
-
LL : 'D MMMM YYYY',
|
| 7982 |
-
|
| 7983 |
-
|
|
|
|
|
|
|
|
|
|
| 7984 |
},
|
| 7985 |
calendar : {
|
| 7986 |
sameDay : function () {
|
|
@@ -8015,7 +8269,7 @@ webpackJsonp([3],[
|
|
| 8015 |
y : 'un any',
|
| 8016 |
yy : '%d anys'
|
| 8017 |
},
|
| 8018 |
-
|
| 8019 |
ordinal : function (number, period) {
|
| 8020 |
var output = (number === 1) ? 'r' :
|
| 8021 |
(number === 2) ? 'n' :
|
|
@@ -8038,7 +8292,7 @@ webpackJsonp([3],[
|
|
| 8038 |
|
| 8039 |
|
| 8040 |
/***/ },
|
| 8041 |
-
/*
|
| 8042 |
/***/ function(module, exports, __webpack_require__) {
|
| 8043 |
|
| 8044 |
//! moment.js locale configuration
|
|
@@ -8046,7 +8300,7 @@ webpackJsonp([3],[
|
|
| 8046 |
//! author : petrbela : https://github.com/petrbela
|
| 8047 |
|
| 8048 |
;(function (global, factory) {
|
| 8049 |
-
true ? factory(__webpack_require__(
|
| 8050 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8051 |
factory(global.moment)
|
| 8052 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8201,7 +8455,7 @@ webpackJsonp([3],[
|
|
| 8201 |
y : translate,
|
| 8202 |
yy : translate
|
| 8203 |
},
|
| 8204 |
-
|
| 8205 |
ordinal : '%d.',
|
| 8206 |
week : {
|
| 8207 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8215,7 +8469,7 @@ webpackJsonp([3],[
|
|
| 8215 |
|
| 8216 |
|
| 8217 |
/***/ },
|
| 8218 |
-
/*
|
| 8219 |
/***/ function(module, exports, __webpack_require__) {
|
| 8220 |
|
| 8221 |
//! moment.js locale configuration
|
|
@@ -8223,7 +8477,7 @@ webpackJsonp([3],[
|
|
| 8223 |
//! author : Anatoly Mironov : https://github.com/mirontoli
|
| 8224 |
|
| 8225 |
;(function (global, factory) {
|
| 8226 |
-
true ? factory(__webpack_require__(
|
| 8227 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8228 |
factory(global.moment)
|
| 8229 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8269,7 +8523,7 @@ webpackJsonp([3],[
|
|
| 8269 |
y : 'пӗр ҫул',
|
| 8270 |
yy : '%d ҫул'
|
| 8271 |
},
|
| 8272 |
-
|
| 8273 |
ordinal : '%d-мӗш',
|
| 8274 |
week : {
|
| 8275 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8283,7 +8537,7 @@ webpackJsonp([3],[
|
|
| 8283 |
|
| 8284 |
|
| 8285 |
/***/ },
|
| 8286 |
-
/*
|
| 8287 |
/***/ function(module, exports, __webpack_require__) {
|
| 8288 |
|
| 8289 |
//! moment.js locale configuration
|
|
@@ -8292,7 +8546,7 @@ webpackJsonp([3],[
|
|
| 8292 |
//! author : https://github.com/ryangreaves
|
| 8293 |
|
| 8294 |
;(function (global, factory) {
|
| 8295 |
-
true ? factory(__webpack_require__(
|
| 8296 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8297 |
factory(global.moment)
|
| 8298 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8337,7 +8591,7 @@ webpackJsonp([3],[
|
|
| 8337 |
y: 'blwyddyn',
|
| 8338 |
yy: '%d flynedd'
|
| 8339 |
},
|
| 8340 |
-
|
| 8341 |
// traditional ordinal numbers above 31 are not commonly used in colloquial Welsh
|
| 8342 |
ordinal: function (number) {
|
| 8343 |
var b = number,
|
|
@@ -8369,7 +8623,7 @@ webpackJsonp([3],[
|
|
| 8369 |
|
| 8370 |
|
| 8371 |
/***/ },
|
| 8372 |
-
/*
|
| 8373 |
/***/ function(module, exports, __webpack_require__) {
|
| 8374 |
|
| 8375 |
//! moment.js locale configuration
|
|
@@ -8377,7 +8631,7 @@ webpackJsonp([3],[
|
|
| 8377 |
//! author : Ulrik Nielsen : https://github.com/mrbase
|
| 8378 |
|
| 8379 |
;(function (global, factory) {
|
| 8380 |
-
true ? factory(__webpack_require__(
|
| 8381 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8382 |
factory(global.moment)
|
| 8383 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8395,14 +8649,14 @@ webpackJsonp([3],[
|
|
| 8395 |
L : 'DD/MM/YYYY',
|
| 8396 |
LL : 'D. MMMM YYYY',
|
| 8397 |
LLL : 'D. MMMM YYYY HH:mm',
|
| 8398 |
-
LLLL : 'dddd [d.] D. MMMM YYYY HH:mm'
|
| 8399 |
},
|
| 8400 |
calendar : {
|
| 8401 |
-
sameDay : '[
|
| 8402 |
-
nextDay : '[
|
| 8403 |
-
nextWeek : 'dddd [kl.] LT',
|
| 8404 |
-
lastDay : '[
|
| 8405 |
-
lastWeek : '[
|
| 8406 |
sameElse : 'L'
|
| 8407 |
},
|
| 8408 |
relativeTime : {
|
|
@@ -8420,7 +8674,7 @@ webpackJsonp([3],[
|
|
| 8420 |
y : 'et år',
|
| 8421 |
yy : '%d år'
|
| 8422 |
},
|
| 8423 |
-
|
| 8424 |
ordinal : '%d.',
|
| 8425 |
week : {
|
| 8426 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8434,7 +8688,7 @@ webpackJsonp([3],[
|
|
| 8434 |
|
| 8435 |
|
| 8436 |
/***/ },
|
| 8437 |
-
/*
|
| 8438 |
/***/ function(module, exports, __webpack_require__) {
|
| 8439 |
|
| 8440 |
//! moment.js locale configuration
|
|
@@ -8444,7 +8698,7 @@ webpackJsonp([3],[
|
|
| 8444 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 8445 |
|
| 8446 |
;(function (global, factory) {
|
| 8447 |
-
true ? factory(__webpack_require__(
|
| 8448 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8449 |
factory(global.moment)
|
| 8450 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8503,7 +8757,7 @@ webpackJsonp([3],[
|
|
| 8503 |
y : processRelativeTime,
|
| 8504 |
yy : processRelativeTime
|
| 8505 |
},
|
| 8506 |
-
|
| 8507 |
ordinal : '%d.',
|
| 8508 |
week : {
|
| 8509 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8517,7 +8771,7 @@ webpackJsonp([3],[
|
|
| 8517 |
|
| 8518 |
|
| 8519 |
/***/ },
|
| 8520 |
-
/*
|
| 8521 |
/***/ function(module, exports, __webpack_require__) {
|
| 8522 |
|
| 8523 |
//! moment.js locale configuration
|
|
@@ -8528,7 +8782,7 @@ webpackJsonp([3],[
|
|
| 8528 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 8529 |
|
| 8530 |
;(function (global, factory) {
|
| 8531 |
-
true ? factory(__webpack_require__(
|
| 8532 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8533 |
factory(global.moment)
|
| 8534 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8587,7 +8841,7 @@ webpackJsonp([3],[
|
|
| 8587 |
y : processRelativeTime,
|
| 8588 |
yy : processRelativeTime
|
| 8589 |
},
|
| 8590 |
-
|
| 8591 |
ordinal : '%d.',
|
| 8592 |
week : {
|
| 8593 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8601,61 +8855,144 @@ webpackJsonp([3],[
|
|
| 8601 |
|
| 8602 |
|
| 8603 |
/***/ },
|
| 8604 |
-
/*
|
| 8605 |
/***/ function(module, exports, __webpack_require__) {
|
| 8606 |
|
| 8607 |
//! moment.js locale configuration
|
| 8608 |
-
//! locale :
|
| 8609 |
-
//! author :
|
| 8610 |
|
| 8611 |
;(function (global, factory) {
|
| 8612 |
-
true ? factory(__webpack_require__(
|
| 8613 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8614 |
factory(global.moment)
|
| 8615 |
}(this, (function (moment) { 'use strict';
|
| 8616 |
|
| 8617 |
|
| 8618 |
-
|
| 8619 |
-
'ޖެނުއަރީ',
|
| 8620 |
-
'ފެބްރުއަރީ',
|
| 8621 |
-
'މާރިޗު',
|
| 8622 |
-
'އޭޕްރީލު',
|
| 8623 |
-
'މޭ',
|
| 8624 |
-
'ޖޫން',
|
| 8625 |
-
'ޖުލައި',
|
| 8626 |
-
'އޯގަސްޓު',
|
| 8627 |
-
'ސެޕްޓެމްބަރު',
|
| 8628 |
-
'އޮކްޓޯބަރު',
|
| 8629 |
-
'ނޮވެމްބަރު',
|
| 8630 |
-
'ޑިސެމްބަރު'
|
| 8631 |
-
];
|
| 8632 |
-
var weekdays = [
|
| 8633 |
-
'އާދިއްތަ',
|
| 8634 |
-
'ހޯމަ',
|
| 8635 |
-
'އަންގާރަ',
|
| 8636 |
-
'ބުދަ',
|
| 8637 |
-
'ބުރާސްފަތި',
|
| 8638 |
-
'ހުކުރު',
|
| 8639 |
-
'ހޮނިހިރު'
|
| 8640 |
-
];
|
| 8641 |
|
| 8642 |
-
|
| 8643 |
-
|
| 8644 |
-
|
| 8645 |
-
|
| 8646 |
-
|
| 8647 |
-
|
| 8648 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8649 |
|
| 8650 |
-
|
| 8651 |
-
|
| 8652 |
-
|
| 8653 |
-
|
| 8654 |
-
|
| 8655 |
-
|
| 8656 |
-
|
| 8657 |
-
|
| 8658 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8659 |
return 'މފ' === input;
|
| 8660 |
},
|
| 8661 |
meridiem : function (hour, minute, isLower) {
|
|
@@ -8706,7 +9043,7 @@ webpackJsonp([3],[
|
|
| 8706 |
|
| 8707 |
|
| 8708 |
/***/ },
|
| 8709 |
-
/*
|
| 8710 |
/***/ function(module, exports, __webpack_require__) {
|
| 8711 |
|
| 8712 |
//! moment.js locale configuration
|
|
@@ -8714,7 +9051,7 @@ webpackJsonp([3],[
|
|
| 8714 |
//! author : Aggelos Karalias : https://github.com/mehiel
|
| 8715 |
|
| 8716 |
;(function (global, factory) {
|
| 8717 |
-
true ? factory(__webpack_require__(
|
| 8718 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8719 |
factory(global.moment)
|
| 8720 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8728,7 +9065,9 @@ webpackJsonp([3],[
|
|
| 8728 |
monthsNominativeEl : 'Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος'.split('_'),
|
| 8729 |
monthsGenitiveEl : 'Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου'.split('_'),
|
| 8730 |
months : function (momentToFormat, format) {
|
| 8731 |
-
if (
|
|
|
|
|
|
|
| 8732 |
return this._monthsGenitiveEl[momentToFormat.month()];
|
| 8733 |
} else {
|
| 8734 |
return this._monthsNominativeEl[momentToFormat.month()];
|
|
@@ -8795,7 +9134,7 @@ webpackJsonp([3],[
|
|
| 8795 |
y : 'ένας χρόνος',
|
| 8796 |
yy : '%d χρόνια'
|
| 8797 |
},
|
| 8798 |
-
|
| 8799 |
ordinal: '%dη',
|
| 8800 |
week : {
|
| 8801 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -8809,7 +9148,7 @@ webpackJsonp([3],[
|
|
| 8809 |
|
| 8810 |
|
| 8811 |
/***/ },
|
| 8812 |
-
/*
|
| 8813 |
/***/ function(module, exports, __webpack_require__) {
|
| 8814 |
|
| 8815 |
//! moment.js locale configuration
|
|
@@ -8817,7 +9156,7 @@ webpackJsonp([3],[
|
|
| 8817 |
//! author : Jared Morse : https://github.com/jarcoal
|
| 8818 |
|
| 8819 |
;(function (global, factory) {
|
| 8820 |
-
true ? factory(__webpack_require__(
|
| 8821 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8822 |
factory(global.moment)
|
| 8823 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8860,7 +9199,7 @@ webpackJsonp([3],[
|
|
| 8860 |
y : 'a year',
|
| 8861 |
yy : '%d years'
|
| 8862 |
},
|
| 8863 |
-
|
| 8864 |
ordinal : function (number) {
|
| 8865 |
var b = number % 10,
|
| 8866 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -8881,7 +9220,7 @@ webpackJsonp([3],[
|
|
| 8881 |
|
| 8882 |
|
| 8883 |
/***/ },
|
| 8884 |
-
/*
|
| 8885 |
/***/ function(module, exports, __webpack_require__) {
|
| 8886 |
|
| 8887 |
//! moment.js locale configuration
|
|
@@ -8889,7 +9228,7 @@ webpackJsonp([3],[
|
|
| 8889 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 8890 |
|
| 8891 |
;(function (global, factory) {
|
| 8892 |
-
true ? factory(__webpack_require__(
|
| 8893 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8894 |
factory(global.moment)
|
| 8895 |
}(this, (function (moment) { 'use strict';
|
|
@@ -8932,7 +9271,7 @@ webpackJsonp([3],[
|
|
| 8932 |
y : 'a year',
|
| 8933 |
yy : '%d years'
|
| 8934 |
},
|
| 8935 |
-
|
| 8936 |
ordinal : function (number) {
|
| 8937 |
var b = number % 10,
|
| 8938 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -8949,7 +9288,7 @@ webpackJsonp([3],[
|
|
| 8949 |
|
| 8950 |
|
| 8951 |
/***/ },
|
| 8952 |
-
/*
|
| 8953 |
/***/ function(module, exports, __webpack_require__) {
|
| 8954 |
|
| 8955 |
//! moment.js locale configuration
|
|
@@ -8957,7 +9296,7 @@ webpackJsonp([3],[
|
|
| 8957 |
//! author : Chris Gedrim : https://github.com/chrisgedrim
|
| 8958 |
|
| 8959 |
;(function (global, factory) {
|
| 8960 |
-
true ? factory(__webpack_require__(
|
| 8961 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8962 |
factory(global.moment)
|
| 8963 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9000,7 +9339,7 @@ webpackJsonp([3],[
|
|
| 9000 |
y : 'a year',
|
| 9001 |
yy : '%d years'
|
| 9002 |
},
|
| 9003 |
-
|
| 9004 |
ordinal : function (number) {
|
| 9005 |
var b = number % 10,
|
| 9006 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -9021,7 +9360,7 @@ webpackJsonp([3],[
|
|
| 9021 |
|
| 9022 |
|
| 9023 |
/***/ },
|
| 9024 |
-
/*
|
| 9025 |
/***/ function(module, exports, __webpack_require__) {
|
| 9026 |
|
| 9027 |
//! moment.js locale configuration
|
|
@@ -9029,7 +9368,7 @@ webpackJsonp([3],[
|
|
| 9029 |
//! author : Chris Cartlidge : https://github.com/chriscartlidge
|
| 9030 |
|
| 9031 |
;(function (global, factory) {
|
| 9032 |
-
true ? factory(__webpack_require__(
|
| 9033 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9034 |
factory(global.moment)
|
| 9035 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9072,7 +9411,7 @@ webpackJsonp([3],[
|
|
| 9072 |
y : 'a year',
|
| 9073 |
yy : '%d years'
|
| 9074 |
},
|
| 9075 |
-
|
| 9076 |
ordinal : function (number) {
|
| 9077 |
var b = number % 10,
|
| 9078 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -9093,7 +9432,7 @@ webpackJsonp([3],[
|
|
| 9093 |
|
| 9094 |
|
| 9095 |
/***/ },
|
| 9096 |
-
/*
|
| 9097 |
/***/ function(module, exports, __webpack_require__) {
|
| 9098 |
|
| 9099 |
//! moment.js locale configuration
|
|
@@ -9101,7 +9440,7 @@ webpackJsonp([3],[
|
|
| 9101 |
//! author : Luke McGregor : https://github.com/lukemcgregor
|
| 9102 |
|
| 9103 |
;(function (global, factory) {
|
| 9104 |
-
true ? factory(__webpack_require__(
|
| 9105 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9106 |
factory(global.moment)
|
| 9107 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9144,7 +9483,7 @@ webpackJsonp([3],[
|
|
| 9144 |
y : 'a year',
|
| 9145 |
yy : '%d years'
|
| 9146 |
},
|
| 9147 |
-
|
| 9148 |
ordinal : function (number) {
|
| 9149 |
var b = number % 10,
|
| 9150 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
|
@@ -9165,17 +9504,17 @@ webpackJsonp([3],[
|
|
| 9165 |
|
| 9166 |
|
| 9167 |
/***/ },
|
| 9168 |
-
/*
|
| 9169 |
/***/ function(module, exports, __webpack_require__) {
|
| 9170 |
|
| 9171 |
//! moment.js locale configuration
|
| 9172 |
//! locale : Esperanto [eo]
|
| 9173 |
//! author : Colin Dean : https://github.com/colindean
|
| 9174 |
-
//!
|
| 9175 |
-
//!
|
| 9176 |
|
| 9177 |
;(function (global, factory) {
|
| 9178 |
-
true ? factory(__webpack_require__(
|
| 9179 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9180 |
factory(global.moment)
|
| 9181 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9184,16 +9523,16 @@ webpackJsonp([3],[
|
|
| 9184 |
var eo = moment.defineLocale('eo', {
|
| 9185 |
months : 'januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro'.split('_'),
|
| 9186 |
monthsShort : 'jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec'.split('_'),
|
| 9187 |
-
weekdays : '
|
| 9188 |
-
weekdaysShort : '
|
| 9189 |
-
weekdaysMin : '
|
| 9190 |
longDateFormat : {
|
| 9191 |
LT : 'HH:mm',
|
| 9192 |
LTS : 'HH:mm:ss',
|
| 9193 |
L : 'YYYY-MM-DD',
|
| 9194 |
-
LL : 'D[-
|
| 9195 |
-
LLL : 'D[-
|
| 9196 |
-
LLLL : 'dddd, [la] D[-
|
| 9197 |
},
|
| 9198 |
meridiemParse: /[ap]\.t\.m/i,
|
| 9199 |
isPM: function (input) {
|
|
@@ -9215,7 +9554,7 @@ webpackJsonp([3],[
|
|
| 9215 |
sameElse : 'L'
|
| 9216 |
},
|
| 9217 |
relativeTime : {
|
| 9218 |
-
future : '
|
| 9219 |
past : 'antaŭ %s',
|
| 9220 |
s : 'sekundoj',
|
| 9221 |
m : 'minuto',
|
|
@@ -9229,7 +9568,7 @@ webpackJsonp([3],[
|
|
| 9229 |
y : 'jaro',
|
| 9230 |
yy : '%d jaroj'
|
| 9231 |
},
|
| 9232 |
-
|
| 9233 |
ordinal : '%da',
|
| 9234 |
week : {
|
| 9235 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9243,7 +9582,7 @@ webpackJsonp([3],[
|
|
| 9243 |
|
| 9244 |
|
| 9245 |
/***/ },
|
| 9246 |
-
/*
|
| 9247 |
/***/ function(module, exports, __webpack_require__) {
|
| 9248 |
|
| 9249 |
//! moment.js locale configuration
|
|
@@ -9251,7 +9590,7 @@ webpackJsonp([3],[
|
|
| 9251 |
//! author : Julio Napurí : https://github.com/julionc
|
| 9252 |
|
| 9253 |
;(function (global, factory) {
|
| 9254 |
-
true ? factory(__webpack_require__(
|
| 9255 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9256 |
factory(global.moment)
|
| 9257 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9263,7 +9602,9 @@ webpackJsonp([3],[
|
|
| 9263 |
var es = moment.defineLocale('es', {
|
| 9264 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 9265 |
monthsShort : function (m, format) {
|
| 9266 |
-
if (
|
|
|
|
|
|
|
| 9267 |
return monthsShort[m.month()];
|
| 9268 |
} else {
|
| 9269 |
return monthsShortDot[m.month()];
|
|
@@ -9315,7 +9656,7 @@ webpackJsonp([3],[
|
|
| 9315 |
y : 'un año',
|
| 9316 |
yy : '%d años'
|
| 9317 |
},
|
| 9318 |
-
|
| 9319 |
ordinal : '%dº',
|
| 9320 |
week : {
|
| 9321 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9329,14 +9670,14 @@ webpackJsonp([3],[
|
|
| 9329 |
|
| 9330 |
|
| 9331 |
/***/ },
|
| 9332 |
-
/*
|
| 9333 |
/***/ function(module, exports, __webpack_require__) {
|
| 9334 |
|
| 9335 |
//! moment.js locale configuration
|
| 9336 |
//! locale : Spanish (Dominican Republic) [es-do]
|
| 9337 |
|
| 9338 |
;(function (global, factory) {
|
| 9339 |
-
true ? factory(__webpack_require__(
|
| 9340 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9341 |
factory(global.moment)
|
| 9342 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9348,7 +9689,9 @@ webpackJsonp([3],[
|
|
| 9348 |
var esDo = moment.defineLocale('es-do', {
|
| 9349 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 9350 |
monthsShort : function (m, format) {
|
| 9351 |
-
if (
|
|
|
|
|
|
|
| 9352 |
return monthsShort[m.month()];
|
| 9353 |
} else {
|
| 9354 |
return monthsShortDot[m.month()];
|
|
@@ -9400,7 +9743,7 @@ webpackJsonp([3],[
|
|
| 9400 |
y : 'un año',
|
| 9401 |
yy : '%d años'
|
| 9402 |
},
|
| 9403 |
-
|
| 9404 |
ordinal : '%dº',
|
| 9405 |
week : {
|
| 9406 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9414,7 +9757,7 @@ webpackJsonp([3],[
|
|
| 9414 |
|
| 9415 |
|
| 9416 |
/***/ },
|
| 9417 |
-
/*
|
| 9418 |
/***/ function(module, exports, __webpack_require__) {
|
| 9419 |
|
| 9420 |
//! moment.js locale configuration
|
|
@@ -9423,7 +9766,7 @@ webpackJsonp([3],[
|
|
| 9423 |
//! improvements : Illimar Tambek : https://github.com/ragulka
|
| 9424 |
|
| 9425 |
;(function (global, factory) {
|
| 9426 |
-
true ? factory(__webpack_require__(
|
| 9427 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9428 |
factory(global.moment)
|
| 9429 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9485,7 +9828,7 @@ webpackJsonp([3],[
|
|
| 9485 |
y : processRelativeTime,
|
| 9486 |
yy : processRelativeTime
|
| 9487 |
},
|
| 9488 |
-
|
| 9489 |
ordinal : '%d.',
|
| 9490 |
week : {
|
| 9491 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9499,7 +9842,7 @@ webpackJsonp([3],[
|
|
| 9499 |
|
| 9500 |
|
| 9501 |
/***/ },
|
| 9502 |
-
/*
|
| 9503 |
/***/ function(module, exports, __webpack_require__) {
|
| 9504 |
|
| 9505 |
//! moment.js locale configuration
|
|
@@ -9507,7 +9850,7 @@ webpackJsonp([3],[
|
|
| 9507 |
//! author : Eneko Illarramendi : https://github.com/eillarra
|
| 9508 |
|
| 9509 |
;(function (global, factory) {
|
| 9510 |
-
true ? factory(__webpack_require__(
|
| 9511 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9512 |
factory(global.moment)
|
| 9513 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9556,7 +9899,7 @@ webpackJsonp([3],[
|
|
| 9556 |
y : 'urte bat',
|
| 9557 |
yy : '%d urte'
|
| 9558 |
},
|
| 9559 |
-
|
| 9560 |
ordinal : '%d.',
|
| 9561 |
week : {
|
| 9562 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9570,7 +9913,7 @@ webpackJsonp([3],[
|
|
| 9570 |
|
| 9571 |
|
| 9572 |
/***/ },
|
| 9573 |
-
/*
|
| 9574 |
/***/ function(module, exports, __webpack_require__) {
|
| 9575 |
|
| 9576 |
//! moment.js locale configuration
|
|
@@ -9578,7 +9921,7 @@ webpackJsonp([3],[
|
|
| 9578 |
//! author : Ebrahim Byagowi : https://github.com/ebraminio
|
| 9579 |
|
| 9580 |
;(function (global, factory) {
|
| 9581 |
-
true ? factory(__webpack_require__(
|
| 9582 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9583 |
factory(global.moment)
|
| 9584 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9646,7 +9989,7 @@ webpackJsonp([3],[
|
|
| 9646 |
relativeTime : {
|
| 9647 |
future : 'در %s',
|
| 9648 |
past : '%s پیش',
|
| 9649 |
-
s : '
|
| 9650 |
m : 'یک دقیقه',
|
| 9651 |
mm : '%d دقیقه',
|
| 9652 |
h : 'یک ساعت',
|
|
@@ -9668,7 +10011,7 @@ webpackJsonp([3],[
|
|
| 9668 |
return symbolMap[match];
|
| 9669 |
}).replace(/,/g, '،');
|
| 9670 |
},
|
| 9671 |
-
|
| 9672 |
ordinal : '%dم',
|
| 9673 |
week : {
|
| 9674 |
dow : 6, // Saturday is the first day of the week.
|
|
@@ -9682,7 +10025,7 @@ webpackJsonp([3],[
|
|
| 9682 |
|
| 9683 |
|
| 9684 |
/***/ },
|
| 9685 |
-
/*
|
| 9686 |
/***/ function(module, exports, __webpack_require__) {
|
| 9687 |
|
| 9688 |
//! moment.js locale configuration
|
|
@@ -9690,7 +10033,7 @@ webpackJsonp([3],[
|
|
| 9690 |
//! author : Tarmo Aidantausta : https://github.com/bleadof
|
| 9691 |
|
| 9692 |
;(function (global, factory) {
|
| 9693 |
-
true ? factory(__webpack_require__(
|
| 9694 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9695 |
factory(global.moment)
|
| 9696 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9780,7 +10123,7 @@ webpackJsonp([3],[
|
|
| 9780 |
y : translate,
|
| 9781 |
yy : translate
|
| 9782 |
},
|
| 9783 |
-
|
| 9784 |
ordinal : '%d.',
|
| 9785 |
week : {
|
| 9786 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9794,7 +10137,7 @@ webpackJsonp([3],[
|
|
| 9794 |
|
| 9795 |
|
| 9796 |
/***/ },
|
| 9797 |
-
/*
|
| 9798 |
/***/ function(module, exports, __webpack_require__) {
|
| 9799 |
|
| 9800 |
//! moment.js locale configuration
|
|
@@ -9802,7 +10145,7 @@ webpackJsonp([3],[
|
|
| 9802 |
//! author : Ragnar Johannesen : https://github.com/ragnar123
|
| 9803 |
|
| 9804 |
;(function (global, factory) {
|
| 9805 |
-
true ? factory(__webpack_require__(
|
| 9806 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9807 |
factory(global.moment)
|
| 9808 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9845,7 +10188,7 @@ webpackJsonp([3],[
|
|
| 9845 |
y : 'eitt ár',
|
| 9846 |
yy : '%d ár'
|
| 9847 |
},
|
| 9848 |
-
|
| 9849 |
ordinal : '%d.',
|
| 9850 |
week : {
|
| 9851 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9859,7 +10202,7 @@ webpackJsonp([3],[
|
|
| 9859 |
|
| 9860 |
|
| 9861 |
/***/ },
|
| 9862 |
-
/*
|
| 9863 |
/***/ function(module, exports, __webpack_require__) {
|
| 9864 |
|
| 9865 |
//! moment.js locale configuration
|
|
@@ -9867,7 +10210,7 @@ webpackJsonp([3],[
|
|
| 9867 |
//! author : John Fischer : https://github.com/jfroffice
|
| 9868 |
|
| 9869 |
;(function (global, factory) {
|
| 9870 |
-
true ? factory(__webpack_require__(
|
| 9871 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9872 |
factory(global.moment)
|
| 9873 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9890,12 +10233,12 @@ webpackJsonp([3],[
|
|
| 9890 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 9891 |
},
|
| 9892 |
calendar : {
|
| 9893 |
-
sameDay: '[Aujourd
|
| 9894 |
-
nextDay: '[Demain à] LT',
|
| 9895 |
-
nextWeek: 'dddd [à] LT',
|
| 9896 |
-
lastDay: '[Hier à] LT',
|
| 9897 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 9898 |
-
sameElse: 'L'
|
| 9899 |
},
|
| 9900 |
relativeTime : {
|
| 9901 |
future : 'dans %s',
|
|
@@ -9912,9 +10255,28 @@ webpackJsonp([3],[
|
|
| 9912 |
y : 'un an',
|
| 9913 |
yy : '%d ans'
|
| 9914 |
},
|
| 9915 |
-
|
| 9916 |
-
ordinal : function (number) {
|
| 9917 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9918 |
},
|
| 9919 |
week : {
|
| 9920 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -9928,7 +10290,7 @@ webpackJsonp([3],[
|
|
| 9928 |
|
| 9929 |
|
| 9930 |
/***/ },
|
| 9931 |
-
/*
|
| 9932 |
/***/ function(module, exports, __webpack_require__) {
|
| 9933 |
|
| 9934 |
//! moment.js locale configuration
|
|
@@ -9936,7 +10298,7 @@ webpackJsonp([3],[
|
|
| 9936 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 9937 |
|
| 9938 |
;(function (global, factory) {
|
| 9939 |
-
true ? factory(__webpack_require__(
|
| 9940 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9941 |
factory(global.moment)
|
| 9942 |
}(this, (function (moment) { 'use strict';
|
|
@@ -9959,12 +10321,12 @@ webpackJsonp([3],[
|
|
| 9959 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 9960 |
},
|
| 9961 |
calendar : {
|
| 9962 |
-
sameDay: '[Aujourd
|
| 9963 |
-
nextDay: '[Demain à] LT',
|
| 9964 |
-
nextWeek: 'dddd [à] LT',
|
| 9965 |
-
lastDay: '[Hier à] LT',
|
| 9966 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 9967 |
-
sameElse: 'L'
|
| 9968 |
},
|
| 9969 |
relativeTime : {
|
| 9970 |
future : 'dans %s',
|
|
@@ -9981,9 +10343,23 @@ webpackJsonp([3],[
|
|
| 9981 |
y : 'un an',
|
| 9982 |
yy : '%d ans'
|
| 9983 |
},
|
| 9984 |
-
|
| 9985 |
-
ordinal : function (number) {
|
| 9986 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9987 |
}
|
| 9988 |
});
|
| 9989 |
|
|
@@ -9993,7 +10369,7 @@ webpackJsonp([3],[
|
|
| 9993 |
|
| 9994 |
|
| 9995 |
/***/ },
|
| 9996 |
-
/*
|
| 9997 |
/***/ function(module, exports, __webpack_require__) {
|
| 9998 |
|
| 9999 |
//! moment.js locale configuration
|
|
@@ -10001,7 +10377,7 @@ webpackJsonp([3],[
|
|
| 10001 |
//! author : Gaspard Bucher : https://github.com/gaspard
|
| 10002 |
|
| 10003 |
;(function (global, factory) {
|
| 10004 |
-
true ? factory(__webpack_require__(
|
| 10005 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10006 |
factory(global.moment)
|
| 10007 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10024,12 +10400,12 @@ webpackJsonp([3],[
|
|
| 10024 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 10025 |
},
|
| 10026 |
calendar : {
|
| 10027 |
-
sameDay: '[Aujourd
|
| 10028 |
-
nextDay: '[Demain à] LT',
|
| 10029 |
-
nextWeek: 'dddd [à] LT',
|
| 10030 |
-
lastDay: '[Hier à] LT',
|
| 10031 |
-
lastWeek: 'dddd [dernier à] LT',
|
| 10032 |
-
sameElse: 'L'
|
| 10033 |
},
|
| 10034 |
relativeTime : {
|
| 10035 |
future : 'dans %s',
|
|
@@ -10046,9 +10422,23 @@ webpackJsonp([3],[
|
|
| 10046 |
y : 'un an',
|
| 10047 |
yy : '%d ans'
|
| 10048 |
},
|
| 10049 |
-
|
| 10050 |
-
ordinal : function (number) {
|
| 10051 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10052 |
},
|
| 10053 |
week : {
|
| 10054 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -10062,7 +10452,7 @@ webpackJsonp([3],[
|
|
| 10062 |
|
| 10063 |
|
| 10064 |
/***/ },
|
| 10065 |
-
/*
|
| 10066 |
/***/ function(module, exports, __webpack_require__) {
|
| 10067 |
|
| 10068 |
//! moment.js locale configuration
|
|
@@ -10070,7 +10460,7 @@ webpackJsonp([3],[
|
|
| 10070 |
//! author : Robin van der Vliet : https://github.com/robin0van0der0v
|
| 10071 |
|
| 10072 |
;(function (global, factory) {
|
| 10073 |
-
true ? factory(__webpack_require__(
|
| 10074 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10075 |
factory(global.moment)
|
| 10076 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10082,7 +10472,9 @@ webpackJsonp([3],[
|
|
| 10082 |
var fy = moment.defineLocale('fy', {
|
| 10083 |
months : 'jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber'.split('_'),
|
| 10084 |
monthsShort : function (m, format) {
|
| 10085 |
-
if (
|
|
|
|
|
|
|
| 10086 |
return monthsShortWithoutDots[m.month()];
|
| 10087 |
} else {
|
| 10088 |
return monthsShortWithDots[m.month()];
|
|
@@ -10124,7 +10516,7 @@ webpackJsonp([3],[
|
|
| 10124 |
y : 'ien jier',
|
| 10125 |
yy : '%d jierren'
|
| 10126 |
},
|
| 10127 |
-
|
| 10128 |
ordinal : function (number) {
|
| 10129 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 10130 |
},
|
|
@@ -10140,7 +10532,7 @@ webpackJsonp([3],[
|
|
| 10140 |
|
| 10141 |
|
| 10142 |
/***/ },
|
| 10143 |
-
/*
|
| 10144 |
/***/ function(module, exports, __webpack_require__) {
|
| 10145 |
|
| 10146 |
//! moment.js locale configuration
|
|
@@ -10148,7 +10540,7 @@ webpackJsonp([3],[
|
|
| 10148 |
//! author : Jon Ashdown : https://github.com/jonashdown
|
| 10149 |
|
| 10150 |
;(function (global, factory) {
|
| 10151 |
-
true ? factory(__webpack_require__(
|
| 10152 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10153 |
factory(global.moment)
|
| 10154 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10204,7 +10596,7 @@ webpackJsonp([3],[
|
|
| 10204 |
y : 'bliadhna',
|
| 10205 |
yy : '%d bliadhna'
|
| 10206 |
},
|
| 10207 |
-
|
| 10208 |
ordinal : function (number) {
|
| 10209 |
var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';
|
| 10210 |
return number + output;
|
|
@@ -10221,7 +10613,7 @@ webpackJsonp([3],[
|
|
| 10221 |
|
| 10222 |
|
| 10223 |
/***/ },
|
| 10224 |
-
/*
|
| 10225 |
/***/ function(module, exports, __webpack_require__) {
|
| 10226 |
|
| 10227 |
//! moment.js locale configuration
|
|
@@ -10229,7 +10621,7 @@ webpackJsonp([3],[
|
|
| 10229 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 10230 |
|
| 10231 |
;(function (global, factory) {
|
| 10232 |
-
true ? factory(__webpack_require__(
|
| 10233 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10234 |
factory(global.moment)
|
| 10235 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10289,7 +10681,7 @@ webpackJsonp([3],[
|
|
| 10289 |
y : 'un ano',
|
| 10290 |
yy : '%d anos'
|
| 10291 |
},
|
| 10292 |
-
|
| 10293 |
ordinal : '%dº',
|
| 10294 |
week : {
|
| 10295 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -10303,7 +10695,134 @@ webpackJsonp([3],[
|
|
| 10303 |
|
| 10304 |
|
| 10305 |
/***/ },
|
| 10306 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10307 |
/***/ function(module, exports, __webpack_require__) {
|
| 10308 |
|
| 10309 |
//! moment.js locale configuration
|
|
@@ -10313,7 +10832,7 @@ webpackJsonp([3],[
|
|
| 10313 |
//! author : Tal Ater : https://github.com/TalAter
|
| 10314 |
|
| 10315 |
;(function (global, factory) {
|
| 10316 |
-
true ? factory(__webpack_require__(
|
| 10317 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10318 |
factory(global.moment)
|
| 10319 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10407,7 +10926,7 @@ webpackJsonp([3],[
|
|
| 10407 |
|
| 10408 |
|
| 10409 |
/***/ },
|
| 10410 |
-
/*
|
| 10411 |
/***/ function(module, exports, __webpack_require__) {
|
| 10412 |
|
| 10413 |
//! moment.js locale configuration
|
|
@@ -10415,7 +10934,7 @@ webpackJsonp([3],[
|
|
| 10415 |
//! author : Mayank Singhal : https://github.com/mayanksinghal
|
| 10416 |
|
| 10417 |
;(function (global, factory) {
|
| 10418 |
-
true ? factory(__webpack_require__(
|
| 10419 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10420 |
factory(global.moment)
|
| 10421 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10536,7 +11055,7 @@ webpackJsonp([3],[
|
|
| 10536 |
|
| 10537 |
|
| 10538 |
/***/ },
|
| 10539 |
-
/*
|
| 10540 |
/***/ function(module, exports, __webpack_require__) {
|
| 10541 |
|
| 10542 |
//! moment.js locale configuration
|
|
@@ -10544,7 +11063,7 @@ webpackJsonp([3],[
|
|
| 10544 |
//! author : Bojan Marković : https://github.com/bmarkovic
|
| 10545 |
|
| 10546 |
;(function (global, factory) {
|
| 10547 |
-
true ? factory(__webpack_require__(
|
| 10548 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10549 |
factory(global.moment)
|
| 10550 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10672,7 +11191,7 @@ webpackJsonp([3],[
|
|
| 10672 |
y : 'godinu',
|
| 10673 |
yy : translate
|
| 10674 |
},
|
| 10675 |
-
|
| 10676 |
ordinal : '%d.',
|
| 10677 |
week : {
|
| 10678 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -10686,7 +11205,7 @@ webpackJsonp([3],[
|
|
| 10686 |
|
| 10687 |
|
| 10688 |
/***/ },
|
| 10689 |
-
/*
|
| 10690 |
/***/ function(module, exports, __webpack_require__) {
|
| 10691 |
|
| 10692 |
//! moment.js locale configuration
|
|
@@ -10694,7 +11213,7 @@ webpackJsonp([3],[
|
|
| 10694 |
//! author : Adam Brunner : https://github.com/adambrunner
|
| 10695 |
|
| 10696 |
;(function (global, factory) {
|
| 10697 |
-
true ? factory(__webpack_require__(
|
| 10698 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10699 |
factory(global.moment)
|
| 10700 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10786,7 +11305,7 @@ webpackJsonp([3],[
|
|
| 10786 |
y : translate,
|
| 10787 |
yy : translate
|
| 10788 |
},
|
| 10789 |
-
|
| 10790 |
ordinal : '%d.',
|
| 10791 |
week : {
|
| 10792 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -10800,7 +11319,7 @@ webpackJsonp([3],[
|
|
| 10800 |
|
| 10801 |
|
| 10802 |
/***/ },
|
| 10803 |
-
/*
|
| 10804 |
/***/ function(module, exports, __webpack_require__) {
|
| 10805 |
|
| 10806 |
//! moment.js locale configuration
|
|
@@ -10808,7 +11327,7 @@ webpackJsonp([3],[
|
|
| 10808 |
//! author : Armendarabyan : https://github.com/armendarabyan
|
| 10809 |
|
| 10810 |
;(function (global, factory) {
|
| 10811 |
-
true ? factory(__webpack_require__(
|
| 10812 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10813 |
factory(global.moment)
|
| 10814 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10873,7 +11392,7 @@ webpackJsonp([3],[
|
|
| 10873 |
return 'երեկոյան';
|
| 10874 |
}
|
| 10875 |
},
|
| 10876 |
-
|
| 10877 |
ordinal: function (number, period) {
|
| 10878 |
switch (period) {
|
| 10879 |
case 'DDD':
|
|
@@ -10900,7 +11419,7 @@ webpackJsonp([3],[
|
|
| 10900 |
|
| 10901 |
|
| 10902 |
/***/ },
|
| 10903 |
-
/*
|
| 10904 |
/***/ function(module, exports, __webpack_require__) {
|
| 10905 |
|
| 10906 |
//! moment.js locale configuration
|
|
@@ -10909,7 +11428,7 @@ webpackJsonp([3],[
|
|
| 10909 |
//! reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan
|
| 10910 |
|
| 10911 |
;(function (global, factory) {
|
| 10912 |
-
true ? factory(__webpack_require__(
|
| 10913 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10914 |
factory(global.moment)
|
| 10915 |
}(this, (function (moment) { 'use strict';
|
|
@@ -10988,7 +11507,7 @@ webpackJsonp([3],[
|
|
| 10988 |
|
| 10989 |
|
| 10990 |
/***/ },
|
| 10991 |
-
/*
|
| 10992 |
/***/ function(module, exports, __webpack_require__) {
|
| 10993 |
|
| 10994 |
//! moment.js locale configuration
|
|
@@ -10996,7 +11515,7 @@ webpackJsonp([3],[
|
|
| 10996 |
//! author : Hinrik Örn Sigurðsson : https://github.com/hinrik
|
| 10997 |
|
| 10998 |
;(function (global, factory) {
|
| 10999 |
-
true ? factory(__webpack_require__(
|
| 11000 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11001 |
factory(global.moment)
|
| 11002 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11106,7 +11625,7 @@ webpackJsonp([3],[
|
|
| 11106 |
y : translate,
|
| 11107 |
yy : translate
|
| 11108 |
},
|
| 11109 |
-
|
| 11110 |
ordinal : '%d.',
|
| 11111 |
week : {
|
| 11112 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -11120,7 +11639,7 @@ webpackJsonp([3],[
|
|
| 11120 |
|
| 11121 |
|
| 11122 |
/***/ },
|
| 11123 |
-
/*
|
| 11124 |
/***/ function(module, exports, __webpack_require__) {
|
| 11125 |
|
| 11126 |
//! moment.js locale configuration
|
|
@@ -11129,7 +11648,7 @@ webpackJsonp([3],[
|
|
| 11129 |
//! author: Mattia Larentis: https://github.com/nostalgiaz
|
| 11130 |
|
| 11131 |
;(function (global, factory) {
|
| 11132 |
-
true ? factory(__webpack_require__(
|
| 11133 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11134 |
factory(global.moment)
|
| 11135 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11138,9 +11657,9 @@ webpackJsonp([3],[
|
|
| 11138 |
var it = moment.defineLocale('it', {
|
| 11139 |
months : 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split('_'),
|
| 11140 |
monthsShort : 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),
|
| 11141 |
-
weekdays : '
|
| 11142 |
-
weekdaysShort : '
|
| 11143 |
-
weekdaysMin : '
|
| 11144 |
longDateFormat : {
|
| 11145 |
LT : 'HH:mm',
|
| 11146 |
LTS : 'HH:mm:ss',
|
|
@@ -11181,7 +11700,7 @@ webpackJsonp([3],[
|
|
| 11181 |
y : 'un anno',
|
| 11182 |
yy : '%d anni'
|
| 11183 |
},
|
| 11184 |
-
|
| 11185 |
ordinal: '%dº',
|
| 11186 |
week : {
|
| 11187 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -11195,7 +11714,7 @@ webpackJsonp([3],[
|
|
| 11195 |
|
| 11196 |
|
| 11197 |
/***/ },
|
| 11198 |
-
/*
|
| 11199 |
/***/ function(module, exports, __webpack_require__) {
|
| 11200 |
|
| 11201 |
//! moment.js locale configuration
|
|
@@ -11203,7 +11722,7 @@ webpackJsonp([3],[
|
|
| 11203 |
//! author : LI Long : https://github.com/baryon
|
| 11204 |
|
| 11205 |
;(function (global, factory) {
|
| 11206 |
-
true ? factory(__webpack_require__(
|
| 11207 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11208 |
factory(global.moment)
|
| 11209 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11216,12 +11735,16 @@ webpackJsonp([3],[
|
|
| 11216 |
weekdaysShort : '日_月_火_水_木_金_土'.split('_'),
|
| 11217 |
weekdaysMin : '日_月_火_水_木_金_土'.split('_'),
|
| 11218 |
longDateFormat : {
|
| 11219 |
-
LT : '
|
| 11220 |
-
LTS : '
|
| 11221 |
L : 'YYYY/MM/DD',
|
| 11222 |
LL : 'YYYY年M月D日',
|
| 11223 |
-
LLL : 'YYYY年M月D日
|
| 11224 |
-
LLLL : 'YYYY年M月D日
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11225 |
},
|
| 11226 |
meridiemParse: /午前|午後/i,
|
| 11227 |
isPM : function (input) {
|
|
@@ -11242,7 +11765,7 @@ webpackJsonp([3],[
|
|
| 11242 |
lastWeek : '[前週]dddd LT',
|
| 11243 |
sameElse : 'L'
|
| 11244 |
},
|
| 11245 |
-
|
| 11246 |
ordinal : function (number, period) {
|
| 11247 |
switch (period) {
|
| 11248 |
case 'd':
|
|
@@ -11276,7 +11799,7 @@ webpackJsonp([3],[
|
|
| 11276 |
|
| 11277 |
|
| 11278 |
/***/ },
|
| 11279 |
-
/*
|
| 11280 |
/***/ function(module, exports, __webpack_require__) {
|
| 11281 |
|
| 11282 |
//! moment.js locale configuration
|
|
@@ -11285,7 +11808,7 @@ webpackJsonp([3],[
|
|
| 11285 |
//! reference: http://jv.wikipedia.org/wiki/Basa_Jawa
|
| 11286 |
|
| 11287 |
;(function (global, factory) {
|
| 11288 |
-
true ? factory(__webpack_require__(
|
| 11289 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11290 |
factory(global.moment)
|
| 11291 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11364,7 +11887,7 @@ webpackJsonp([3],[
|
|
| 11364 |
|
| 11365 |
|
| 11366 |
/***/ },
|
| 11367 |
-
/*
|
| 11368 |
/***/ function(module, exports, __webpack_require__) {
|
| 11369 |
|
| 11370 |
//! moment.js locale configuration
|
|
@@ -11372,7 +11895,7 @@ webpackJsonp([3],[
|
|
| 11372 |
//! author : Irakli Janiashvili : https://github.com/irakli-janiashvili
|
| 11373 |
|
| 11374 |
;(function (global, factory) {
|
| 11375 |
-
true ? factory(__webpack_require__(
|
| 11376 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11377 |
factory(global.moment)
|
| 11378 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11415,10 +11938,10 @@ webpackJsonp([3],[
|
|
| 11415 |
},
|
| 11416 |
past : function (s) {
|
| 11417 |
if ((/(წამი|წუთი|საათი|დღე|თვე)/).test(s)) {
|
| 11418 |
-
return s.replace(/(ი|ე)$/, 'ის
|
| 11419 |
}
|
| 11420 |
if ((/წელი/).test(s)) {
|
| 11421 |
-
return s.replace(/წელი$/, 'წლის
|
| 11422 |
}
|
| 11423 |
},
|
| 11424 |
s : 'რამდენიმე წამი',
|
|
@@ -11433,7 +11956,7 @@ webpackJsonp([3],[
|
|
| 11433 |
y : 'წელი',
|
| 11434 |
yy : '%d წელი'
|
| 11435 |
},
|
| 11436 |
-
|
| 11437 |
ordinal : function (number) {
|
| 11438 |
if (number === 0) {
|
| 11439 |
return number;
|
|
@@ -11458,7 +11981,7 @@ webpackJsonp([3],[
|
|
| 11458 |
|
| 11459 |
|
| 11460 |
/***/ },
|
| 11461 |
-
/*
|
| 11462 |
/***/ function(module, exports, __webpack_require__) {
|
| 11463 |
|
| 11464 |
//! moment.js locale configuration
|
|
@@ -11466,7 +11989,7 @@ webpackJsonp([3],[
|
|
| 11466 |
//! authors : Nurlan Rakhimzhanov : https://github.com/nurlan
|
| 11467 |
|
| 11468 |
;(function (global, factory) {
|
| 11469 |
-
true ? factory(__webpack_require__(
|
| 11470 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11471 |
factory(global.moment)
|
| 11472 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11532,7 +12055,7 @@ webpackJsonp([3],[
|
|
| 11532 |
y : 'бір жыл',
|
| 11533 |
yy : '%d жыл'
|
| 11534 |
},
|
| 11535 |
-
|
| 11536 |
ordinal : function (number) {
|
| 11537 |
var a = number % 10,
|
| 11538 |
b = number >= 100 ? 100 : null;
|
|
@@ -11550,7 +12073,7 @@ webpackJsonp([3],[
|
|
| 11550 |
|
| 11551 |
|
| 11552 |
/***/ },
|
| 11553 |
-
/*
|
| 11554 |
/***/ function(module, exports, __webpack_require__) {
|
| 11555 |
|
| 11556 |
//! moment.js locale configuration
|
|
@@ -11558,7 +12081,7 @@ webpackJsonp([3],[
|
|
| 11558 |
//! author : Kruy Vanna : https://github.com/kruyvanna
|
| 11559 |
|
| 11560 |
;(function (global, factory) {
|
| 11561 |
-
true ? factory(__webpack_require__(
|
| 11562 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11563 |
factory(global.moment)
|
| 11564 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11613,7 +12136,138 @@ webpackJsonp([3],[
|
|
| 11613 |
|
| 11614 |
|
| 11615 |
/***/ },
|
| 11616 |
-
/*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11617 |
/***/ function(module, exports, __webpack_require__) {
|
| 11618 |
|
| 11619 |
//! moment.js locale configuration
|
|
@@ -11622,7 +12276,7 @@ webpackJsonp([3],[
|
|
| 11622 |
//! author : Jeeeyul Lee <jeeeyul@gmail.com>
|
| 11623 |
|
| 11624 |
;(function (global, factory) {
|
| 11625 |
-
true ? factory(__webpack_require__(
|
| 11626 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11627 |
factory(global.moment)
|
| 11628 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11635,12 +12289,16 @@ webpackJsonp([3],[
|
|
| 11635 |
weekdaysShort : '일_월_화_수_목_금_토'.split('_'),
|
| 11636 |
weekdaysMin : '일_월_화_수_목_금_토'.split('_'),
|
| 11637 |
longDateFormat : {
|
| 11638 |
-
LT : 'A h
|
| 11639 |
-
LTS : 'A h
|
| 11640 |
L : 'YYYY.MM.DD',
|
| 11641 |
LL : 'YYYY년 MMMM D일',
|
| 11642 |
-
LLL : 'YYYY년 MMMM D일 A h
|
| 11643 |
-
LLLL : 'YYYY년 MMMM D일 dddd A h
|
|
|
|
|
|
|
|
|
|
|
|
|
| 11644 |
},
|
| 11645 |
calendar : {
|
| 11646 |
sameDay : '오늘 LT',
|
|
@@ -11655,7 +12313,7 @@ webpackJsonp([3],[
|
|
| 11655 |
past : '%s 전',
|
| 11656 |
s : '몇 초',
|
| 11657 |
ss : '%d초',
|
| 11658 |
-
m : '
|
| 11659 |
mm : '%d분',
|
| 11660 |
h : '한 시간',
|
| 11661 |
hh : '%d시간',
|
|
@@ -11666,7 +12324,7 @@ webpackJsonp([3],[
|
|
| 11666 |
y : '일 년',
|
| 11667 |
yy : '%d년'
|
| 11668 |
},
|
| 11669 |
-
|
| 11670 |
ordinal : '%d일',
|
| 11671 |
meridiemParse : /오전|오후/,
|
| 11672 |
isPM : function (token) {
|
|
@@ -11683,7 +12341,7 @@ webpackJsonp([3],[
|
|
| 11683 |
|
| 11684 |
|
| 11685 |
/***/ },
|
| 11686 |
-
/*
|
| 11687 |
/***/ function(module, exports, __webpack_require__) {
|
| 11688 |
|
| 11689 |
//! moment.js locale configuration
|
|
@@ -11691,7 +12349,7 @@ webpackJsonp([3],[
|
|
| 11691 |
//! author : Chyngyz Arystan uulu : https://github.com/chyngyz
|
| 11692 |
|
| 11693 |
;(function (global, factory) {
|
| 11694 |
-
true ? factory(__webpack_require__(
|
| 11695 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11696 |
factory(global.moment)
|
| 11697 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11758,7 +12416,7 @@ webpackJsonp([3],[
|
|
| 11758 |
y : 'бир жыл',
|
| 11759 |
yy : '%d жыл'
|
| 11760 |
},
|
| 11761 |
-
|
| 11762 |
ordinal : function (number) {
|
| 11763 |
var a = number % 10,
|
| 11764 |
b = number >= 100 ? 100 : null;
|
|
@@ -11776,7 +12434,7 @@ webpackJsonp([3],[
|
|
| 11776 |
|
| 11777 |
|
| 11778 |
/***/ },
|
| 11779 |
-
/*
|
| 11780 |
/***/ function(module, exports, __webpack_require__) {
|
| 11781 |
|
| 11782 |
//! moment.js locale configuration
|
|
@@ -11785,7 +12443,7 @@ webpackJsonp([3],[
|
|
| 11785 |
//! author : David Raison : https://github.com/kwisatz
|
| 11786 |
|
| 11787 |
;(function (global, factory) {
|
| 11788 |
-
true ? factory(__webpack_require__(
|
| 11789 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11790 |
factory(global.moment)
|
| 11791 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11904,7 +12562,7 @@ webpackJsonp([3],[
|
|
| 11904 |
y : processRelativeTime,
|
| 11905 |
yy : '%d Joer'
|
| 11906 |
},
|
| 11907 |
-
|
| 11908 |
ordinal: '%d.',
|
| 11909 |
week: {
|
| 11910 |
dow: 1, // Monday is the first day of the week.
|
|
@@ -11918,7 +12576,7 @@ webpackJsonp([3],[
|
|
| 11918 |
|
| 11919 |
|
| 11920 |
/***/ },
|
| 11921 |
-
/*
|
| 11922 |
/***/ function(module, exports, __webpack_require__) {
|
| 11923 |
|
| 11924 |
//! moment.js locale configuration
|
|
@@ -11926,7 +12584,7 @@ webpackJsonp([3],[
|
|
| 11926 |
//! author : Ryan Hart : https://github.com/ryanhart2
|
| 11927 |
|
| 11928 |
;(function (global, factory) {
|
| 11929 |
-
true ? factory(__webpack_require__(
|
| 11930 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11931 |
factory(global.moment)
|
| 11932 |
}(this, (function (moment) { 'use strict';
|
|
@@ -11981,7 +12639,7 @@ webpackJsonp([3],[
|
|
| 11981 |
y : '1 ປີ',
|
| 11982 |
yy : '%d ປີ'
|
| 11983 |
},
|
| 11984 |
-
|
| 11985 |
ordinal : function (number) {
|
| 11986 |
return 'ທີ່' + number;
|
| 11987 |
}
|
|
@@ -11993,7 +12651,7 @@ webpackJsonp([3],[
|
|
| 11993 |
|
| 11994 |
|
| 11995 |
/***/ },
|
| 11996 |
-
/*
|
| 11997 |
/***/ function(module, exports, __webpack_require__) {
|
| 11998 |
|
| 11999 |
//! moment.js locale configuration
|
|
@@ -12001,7 +12659,7 @@ webpackJsonp([3],[
|
|
| 12001 |
//! author : Mindaugas Mozūras : https://github.com/mmozuras
|
| 12002 |
|
| 12003 |
;(function (global, factory) {
|
| 12004 |
-
true ? factory(__webpack_require__(
|
| 12005 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12006 |
factory(global.moment)
|
| 12007 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12099,7 +12757,7 @@ webpackJsonp([3],[
|
|
| 12099 |
y : translateSingular,
|
| 12100 |
yy : translate
|
| 12101 |
},
|
| 12102 |
-
|
| 12103 |
ordinal : function (number) {
|
| 12104 |
return number + '-oji';
|
| 12105 |
},
|
|
@@ -12115,7 +12773,7 @@ webpackJsonp([3],[
|
|
| 12115 |
|
| 12116 |
|
| 12117 |
/***/ },
|
| 12118 |
-
/*
|
| 12119 |
/***/ function(module, exports, __webpack_require__) {
|
| 12120 |
|
| 12121 |
//! moment.js locale configuration
|
|
@@ -12124,7 +12782,7 @@ webpackJsonp([3],[
|
|
| 12124 |
//! author : Jānis Elmeris : https://github.com/JanisE
|
| 12125 |
|
| 12126 |
;(function (global, factory) {
|
| 12127 |
-
true ? factory(__webpack_require__(
|
| 12128 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12129 |
factory(global.moment)
|
| 12130 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12203,7 +12861,7 @@ webpackJsonp([3],[
|
|
| 12203 |
y : relativeTimeWithSingular,
|
| 12204 |
yy : relativeTimeWithPlural
|
| 12205 |
},
|
| 12206 |
-
|
| 12207 |
ordinal : '%d.',
|
| 12208 |
week : {
|
| 12209 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -12217,7 +12875,7 @@ webpackJsonp([3],[
|
|
| 12217 |
|
| 12218 |
|
| 12219 |
/***/ },
|
| 12220 |
-
/*
|
| 12221 |
/***/ function(module, exports, __webpack_require__) {
|
| 12222 |
|
| 12223 |
//! moment.js locale configuration
|
|
@@ -12225,7 +12883,7 @@ webpackJsonp([3],[
|
|
| 12225 |
//! author : Miodrag Nikač <miodrag@restartit.me> : https://github.com/miodragnikac
|
| 12226 |
|
| 12227 |
;(function (global, factory) {
|
| 12228 |
-
true ? factory(__webpack_require__(
|
| 12229 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12230 |
factory(global.moment)
|
| 12231 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12319,7 +12977,7 @@ webpackJsonp([3],[
|
|
| 12319 |
y : 'godinu',
|
| 12320 |
yy : translator.translate
|
| 12321 |
},
|
| 12322 |
-
|
| 12323 |
ordinal : '%d.',
|
| 12324 |
week : {
|
| 12325 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -12333,7 +12991,7 @@ webpackJsonp([3],[
|
|
| 12333 |
|
| 12334 |
|
| 12335 |
/***/ },
|
| 12336 |
-
/*
|
| 12337 |
/***/ function(module, exports, __webpack_require__) {
|
| 12338 |
|
| 12339 |
//! moment.js locale configuration
|
|
@@ -12341,7 +12999,7 @@ webpackJsonp([3],[
|
|
| 12341 |
//! author : John Corrigan <robbiecloset@gmail.com> : https://github.com/johnideal
|
| 12342 |
|
| 12343 |
;(function (global, factory) {
|
| 12344 |
-
true ? factory(__webpack_require__(
|
| 12345 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12346 |
factory(global.moment)
|
| 12347 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12388,7 +13046,7 @@ webpackJsonp([3],[
|
|
| 12388 |
y: 'he tau',
|
| 12389 |
yy: '%d tau'
|
| 12390 |
},
|
| 12391 |
-
|
| 12392 |
ordinal: '%dº',
|
| 12393 |
week : {
|
| 12394 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -12402,7 +13060,7 @@ webpackJsonp([3],[
|
|
| 12402 |
|
| 12403 |
|
| 12404 |
/***/ },
|
| 12405 |
-
/*
|
| 12406 |
/***/ function(module, exports, __webpack_require__) {
|
| 12407 |
|
| 12408 |
//! moment.js locale configuration
|
|
@@ -12410,7 +13068,7 @@ webpackJsonp([3],[
|
|
| 12410 |
//! author : Borislav Mickov : https://github.com/B0k0
|
| 12411 |
|
| 12412 |
;(function (global, factory) {
|
| 12413 |
-
true ? factory(__webpack_require__(
|
| 12414 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12415 |
factory(global.moment)
|
| 12416 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12465,7 +13123,7 @@ webpackJsonp([3],[
|
|
| 12465 |
y : 'година',
|
| 12466 |
yy : '%d години'
|
| 12467 |
},
|
| 12468 |
-
|
| 12469 |
ordinal : function (number) {
|
| 12470 |
var lastDigit = number % 10,
|
| 12471 |
last2Digits = number % 100;
|
|
@@ -12497,7 +13155,7 @@ webpackJsonp([3],[
|
|
| 12497 |
|
| 12498 |
|
| 12499 |
/***/ },
|
| 12500 |
-
/*
|
| 12501 |
/***/ function(module, exports, __webpack_require__) {
|
| 12502 |
|
| 12503 |
//! moment.js locale configuration
|
|
@@ -12505,7 +13163,7 @@ webpackJsonp([3],[
|
|
| 12505 |
//! author : Floyd Pink : https://github.com/floydpink
|
| 12506 |
|
| 12507 |
;(function (global, factory) {
|
| 12508 |
-
true ? factory(__webpack_require__(
|
| 12509 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12510 |
factory(global.moment)
|
| 12511 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12583,7 +13241,7 @@ webpackJsonp([3],[
|
|
| 12583 |
|
| 12584 |
|
| 12585 |
/***/ },
|
| 12586 |
-
/*
|
| 12587 |
/***/ function(module, exports, __webpack_require__) {
|
| 12588 |
|
| 12589 |
//! moment.js locale configuration
|
|
@@ -12592,7 +13250,7 @@ webpackJsonp([3],[
|
|
| 12592 |
//! author : Vivek Athalye : https://github.com/vnathalye
|
| 12593 |
|
| 12594 |
;(function (global, factory) {
|
| 12595 |
-
true ? factory(__webpack_require__(
|
| 12596 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12597 |
factory(global.moment)
|
| 12598 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12747,7 +13405,7 @@ webpackJsonp([3],[
|
|
| 12747 |
|
| 12748 |
|
| 12749 |
/***/ },
|
| 12750 |
-
/*
|
| 12751 |
/***/ function(module, exports, __webpack_require__) {
|
| 12752 |
|
| 12753 |
//! moment.js locale configuration
|
|
@@ -12755,7 +13413,7 @@ webpackJsonp([3],[
|
|
| 12755 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 12756 |
|
| 12757 |
;(function (global, factory) {
|
| 12758 |
-
true ? factory(__webpack_require__(
|
| 12759 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12760 |
factory(global.moment)
|
| 12761 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12834,7 +13492,7 @@ webpackJsonp([3],[
|
|
| 12834 |
|
| 12835 |
|
| 12836 |
/***/ },
|
| 12837 |
-
/*
|
| 12838 |
/***/ function(module, exports, __webpack_require__) {
|
| 12839 |
|
| 12840 |
//! moment.js locale configuration
|
|
@@ -12843,7 +13501,7 @@ webpackJsonp([3],[
|
|
| 12843 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 12844 |
|
| 12845 |
;(function (global, factory) {
|
| 12846 |
-
true ? factory(__webpack_require__(
|
| 12847 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12848 |
factory(global.moment)
|
| 12849 |
}(this, (function (moment) { 'use strict';
|
|
@@ -12922,7 +13580,7 @@ webpackJsonp([3],[
|
|
| 12922 |
|
| 12923 |
|
| 12924 |
/***/ },
|
| 12925 |
-
/*
|
| 12926 |
/***/ function(module, exports, __webpack_require__) {
|
| 12927 |
|
| 12928 |
//! moment.js locale configuration
|
|
@@ -12932,7 +13590,7 @@ webpackJsonp([3],[
|
|
| 12932 |
//! author : Tin Aung Lin : https://github.com/thanyawzinmin
|
| 12933 |
|
| 12934 |
;(function (global, factory) {
|
| 12935 |
-
true ? factory(__webpack_require__(
|
| 12936 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12937 |
factory(global.moment)
|
| 12938 |
}(this, (function (moment) { 'use strict';
|
|
@@ -13023,7 +13681,7 @@ webpackJsonp([3],[
|
|
| 13023 |
|
| 13024 |
|
| 13025 |
/***/ },
|
| 13026 |
-
/*
|
| 13027 |
/***/ function(module, exports, __webpack_require__) {
|
| 13028 |
|
| 13029 |
//! moment.js locale configuration
|
|
@@ -13032,7 +13690,7 @@ webpackJsonp([3],[
|
|
| 13032 |
//! Sigurd Gartmann : https://github.com/sigurdga
|
| 13033 |
|
| 13034 |
;(function (global, factory) {
|
| 13035 |
-
true ? factory(__webpack_require__(
|
| 13036 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13037 |
factory(global.moment)
|
| 13038 |
}(this, (function (moment) { 'use strict';
|
|
@@ -13077,7 +13735,7 @@ webpackJsonp([3],[
|
|
| 13077 |
y : 'ett år',
|
| 13078 |
yy : '%d år'
|
| 13079 |
},
|
| 13080 |
-
|
| 13081 |
ordinal : '%d.',
|
| 13082 |
week : {
|
| 13083 |
dow : 1, // Monday is the first day of the week.
|
|
@@ -13091,7 +13749,7 @@ webpackJsonp([3],[
|
|
| 13091 |
|
| 13092 |
|
| 13093 |
/***/ },
|
| 13094 |
-
/*
|
| 13095 |
/***/ function(module, exports, __webpack_require__) {
|
| 13096 |
|
| 13097 |
//! moment.js locale configuration
|
|
@@ -13099,7 +13757,7 @@ webpackJsonp([3],[
|
|
| 13099 |
//! author : suvash : https://github.com/suvash
|
| 13100 |
|
| 13101 |
;(function (global, factory) {
|
| 13102 |
-
true ? factory(__webpack_require__(
|
| 13103 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13104 |
factory(global.moment)
|
| 13105 |
}(this, (function (moment) { 'use strict';
|
|
@@ -13219,7 +13877,7 @@ webpackJsonp([3],[
|
|
| 13219 |
|
| 13220 |
|
| 13221 |
/***/ },
|
| 13222 |
-
/*
|
| 13223 |
/***/ function(module, exports, __webpack_require__) {
|
| 13224 |
|
| 13225 |
//! moment.js locale configuration
|
|
@@ -13228,7 +13886,7 @@ webpackJsonp([3],[
|
|
| 13228 |
//! author : Jacob Middag : https://github.com/middagj
|
| 13229 |
|
| 13230 |
;(function (global, factory) {
|
| 13231 |
-
true ? factory(__webpack_require__(
|
| 13232 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13233 |
factory(global.moment)
|
| 13234 |
}(this, (function (momen
|
| 2 |
/* 0 */
|
| 3 |
/***/ function(module, exports, __webpack_require__) {
|
| 4 |
|
| 5 |
+
__webpack_require__(275);
|
| 6 |
+
__webpack_require__(462);
|
| 7 |
+
__webpack_require__(463);
|
| 8 |
+
__webpack_require__(464);
|
| 9 |
+
__webpack_require__(465);
|
| 10 |
+
__webpack_require__(466);
|
| 11 |
+
__webpack_require__(467);
|
| 12 |
+
module.exports = __webpack_require__(468);
|
| 13 |
|
| 14 |
|
| 15 |
/***/ },
|
| 279 |
/* 264 */,
|
| 280 |
/* 265 */,
|
| 281 |
/* 266 */,
|
| 282 |
+
/* 267 */,
|
| 283 |
+
/* 268 */,
|
| 284 |
+
/* 269 */,
|
| 285 |
+
/* 270 */,
|
| 286 |
+
/* 271 */,
|
| 287 |
+
/* 272 */,
|
| 288 |
+
/* 273 */,
|
| 289 |
+
/* 274 */
|
| 290 |
/***/ function(module, exports) {
|
| 291 |
|
| 292 |
module.exports = jQuery;
|
| 293 |
|
| 294 |
/***/ },
|
| 295 |
+
/* 275 */
|
| 296 |
/***/ function(module, exports, __webpack_require__) {
|
| 297 |
|
| 298 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_RESULT__ = function() {
|
| 307 |
|
| 308 |
|
| 309 |
/***/ },
|
| 310 |
+
/* 276 */,
|
| 311 |
+
/* 277 */,
|
| 312 |
+
/* 278 */
|
| 313 |
/***/ function(module, exports, __webpack_require__) {
|
| 314 |
|
| 315 |
+
/* WEBPACK VAR INJECTION */(function(global) {module.exports = global["_"] = __webpack_require__(279);
|
| 316 |
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
|
| 317 |
|
| 318 |
/***/ },
|
| 319 |
+
/* 279 */
|
| 320 |
/***/ function(module, exports, __webpack_require__) {
|
| 321 |
|
| 322 |
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;// Underscore.js 1.8.3
|
| 1870 |
|
| 1871 |
|
| 1872 |
/***/ },
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1873 |
/* 280 */,
|
| 1874 |
/* 281 */,
|
| 1875 |
/* 282 */,
|
| 1880 |
/* 287 */,
|
| 1881 |
/* 288 */,
|
| 1882 |
/* 289 */,
|
| 1883 |
+
/* 290 */,
|
| 1884 |
+
/* 291 */,
|
| 1885 |
+
/* 292 */,
|
| 1886 |
+
/* 293 */,
|
| 1887 |
+
/* 294 */,
|
| 1888 |
+
/* 295 */,
|
| 1889 |
+
/* 296 */,
|
| 1890 |
+
/* 297 */
|
| 1891 |
/***/ function(module, exports, __webpack_require__) {
|
| 1892 |
|
| 1893 |
/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
|
| 1894 |
+
//! version : 2.18.1
|
| 1895 |
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
| 1896 |
//! license : MIT
|
| 1897 |
//! momentjs.com
|
| 1933 |
return true;
|
| 1934 |
}
|
| 1935 |
|
| 1936 |
+
function isUndefined(input) {
|
| 1937 |
+
return input === void 0;
|
| 1938 |
+
}
|
| 1939 |
+
|
| 1940 |
function isNumber(input) {
|
| 1941 |
return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';
|
| 1942 |
}
|
| 1993 |
userInvalidated : false,
|
| 1994 |
iso : false,
|
| 1995 |
parsedDateParts : [],
|
| 1996 |
+
meridiem : null,
|
| 1997 |
+
rfc2822 : false,
|
| 1998 |
+
weekdayMismatch : false
|
| 1999 |
};
|
| 2000 |
}
|
| 2001 |
|
| 2071 |
return m;
|
| 2072 |
}
|
| 2073 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2074 |
// Plugins that add properties should also add the key here (null value),
|
| 2075 |
// so we can properly clone ourselves.
|
| 2076 |
var momentProperties = hooks.momentProperties = [];
|
| 2110 |
}
|
| 2111 |
|
| 2112 |
if (momentProperties.length > 0) {
|
| 2113 |
+
for (i = 0; i < momentProperties.length; i++) {
|
| 2114 |
prop = momentProperties[i];
|
| 2115 |
val = from[prop];
|
| 2116 |
if (!isUndefined(val)) {
|
| 2247 |
}
|
| 2248 |
this._config = config;
|
| 2249 |
// Lenient ordinal parsing accepts just a number in addition to
|
| 2250 |
+
// number + (possibly) stuff coming from _dayOfMonthOrdinalParse.
|
| 2251 |
+
// TODO: Remove "ordinalParse" fallback in next major release.
|
| 2252 |
+
this._dayOfMonthOrdinalParseLenient = new RegExp(
|
| 2253 |
+
(this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) +
|
| 2254 |
+
'|' + (/\d{1,2}/).source);
|
| 2255 |
}
|
| 2256 |
|
| 2257 |
function mergeConfigs(parentConfig, childConfig) {
|
| 2349 |
}
|
| 2350 |
|
| 2351 |
var defaultOrdinal = '%d';
|
| 2352 |
+
var defaultDayOfMonthOrdinalParse = /\d{1,2}/;
|
| 2353 |
|
| 2354 |
function ordinal (number) {
|
| 2355 |
return this._ordinal.replace('%d', number);
|
| 2359 |
future : 'in %s',
|
| 2360 |
past : '%s ago',
|
| 2361 |
s : 'a few seconds',
|
| 2362 |
+
ss : '%d seconds',
|
| 2363 |
m : 'a minute',
|
| 2364 |
mm : '%d minutes',
|
| 2365 |
h : 'an hour',
|
| 2542 |
return function (mom) {
|
| 2543 |
var output = '', i;
|
| 2544 |
for (i = 0; i < length; i++) {
|
| 2545 |
+
output += isFunction(array[i]) ? array[i].call(mom, format) : array[i];
|
| 2546 |
}
|
| 2547 |
return output;
|
| 2548 |
};
|
| 2745 |
var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_');
|
| 2746 |
function localeMonths (m, format) {
|
| 2747 |
if (!m) {
|
| 2748 |
+
return isArray(this._months) ? this._months :
|
| 2749 |
+
this._months['standalone'];
|
| 2750 |
}
|
| 2751 |
return isArray(this._months) ? this._months[m.month()] :
|
| 2752 |
this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];
|
| 2755 |
var defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_');
|
| 2756 |
function localeMonthsShort (m, format) {
|
| 2757 |
if (!m) {
|
| 2758 |
+
return isArray(this._monthsShort) ? this._monthsShort :
|
| 2759 |
+
this._monthsShort['standalone'];
|
| 2760 |
}
|
| 2761 |
return isArray(this._monthsShort) ? this._monthsShort[m.month()] :
|
| 2762 |
this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];
|
| 3023 |
}
|
| 3024 |
|
| 3025 |
function createDate (y, m, d, h, M, s, ms) {
|
| 3026 |
+
// can't just apply() to create a date:
|
| 3027 |
+
// https://stackoverflow.com/q/181348
|
| 3028 |
var date = new Date(y, m, d, h, M, s, ms);
|
| 3029 |
|
| 3030 |
+
// the date constructor remaps years 0-99 to 1900-1999
|
| 3031 |
if (y < 100 && y >= 0 && isFinite(date.getFullYear())) {
|
| 3032 |
date.setFullYear(y);
|
| 3033 |
}
|
| 3037 |
function createUTCDate (y) {
|
| 3038 |
var date = new Date(Date.UTC.apply(null, arguments));
|
| 3039 |
|
| 3040 |
+
// the Date.UTC function remaps years 0-99 to 1900-1999
|
| 3041 |
if (y < 100 && y >= 0 && isFinite(date.getUTCFullYear())) {
|
| 3042 |
date.setUTCFullYear(y);
|
| 3043 |
}
|
| 3054 |
return -fwdlw + fwd - 1;
|
| 3055 |
}
|
| 3056 |
|
| 3057 |
+
// https://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday
|
| 3058 |
function dayOfYearFromWeeks(year, week, weekday, dow, doy) {
|
| 3059 |
var localWeekday = (7 + weekday - dow) % 7,
|
| 3060 |
weekOffset = firstWeekOffset(year, dow, doy),
|
| 3255 |
var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_');
|
| 3256 |
function localeWeekdays (m, format) {
|
| 3257 |
if (!m) {
|
| 3258 |
+
return isArray(this._weekdays) ? this._weekdays :
|
| 3259 |
+
this._weekdays['standalone'];
|
| 3260 |
}
|
| 3261 |
return isArray(this._weekdays) ? this._weekdays[m.day()] :
|
| 3262 |
this._weekdays[this._weekdays.isFormat.test(format) ? 'format' : 'standalone'][m.day()];
|
| 3576 |
addRegexToken('A', matchMeridiem);
|
| 3577 |
addRegexToken('H', match1to2);
|
| 3578 |
addRegexToken('h', match1to2);
|
| 3579 |
+
addRegexToken('k', match1to2);
|
| 3580 |
addRegexToken('HH', match1to2, match2);
|
| 3581 |
addRegexToken('hh', match1to2, match2);
|
| 3582 |
+
addRegexToken('kk', match1to2, match2);
|
| 3583 |
|
| 3584 |
addRegexToken('hmm', match3to4);
|
| 3585 |
addRegexToken('hmmss', match5to6);
|
| 3587 |
addRegexToken('Hmmss', match5to6);
|
| 3588 |
|
| 3589 |
addParseToken(['H', 'HH'], HOUR);
|
| 3590 |
+
addParseToken(['k', 'kk'], function (input, array, config) {
|
| 3591 |
+
var kInput = toInt(input);
|
| 3592 |
+
array[HOUR] = kInput === 24 ? 0 : kInput;
|
| 3593 |
+
});
|
| 3594 |
addParseToken(['a', 'A'], function (input, array, config) {
|
| 3595 |
config._isPm = config._locale.isPM(input);
|
| 3596 |
config._meridiem = input;
|
| 3661 |
longDateFormat: defaultLongDateFormat,
|
| 3662 |
invalidDate: defaultInvalidDate,
|
| 3663 |
ordinal: defaultOrdinal,
|
| 3664 |
+
dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse,
|
| 3665 |
relativeTime: defaultRelativeTime,
|
| 3666 |
|
| 3667 |
months: defaultLocaleMonths,
|
| 3719 |
module && module.exports) {
|
| 3720 |
try {
|
| 3721 |
oldLocale = globalLocale._abbr;
|
| 3722 |
+
__webpack_require__(299)("./" + name);
|
| 3723 |
// because defineLocale currently also sets the global locale, we
|
| 3724 |
// want to undo that for lazy loaded locales
|
| 3725 |
getSetGlobalLocale(oldLocale);
|
| 3972 |
}
|
| 3973 |
}
|
| 3974 |
|
| 3975 |
+
// RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3
|
| 3976 |
+
var basicRfcRegex = /^((?:Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d?\d\s(?:Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(?:\d\d)?\d\d\s)(\d\d:\d\d)(\:\d\d)?(\s(?:UT|GMT|[ECMP][SD]T|[A-IK-Za-ik-z]|[+-]\d{4}))$/;
|
| 3977 |
+
|
| 3978 |
+
// date and time from ref 2822 format
|
| 3979 |
+
function configFromRFC2822(config) {
|
| 3980 |
+
var string, match, dayFormat,
|
| 3981 |
+
dateFormat, timeFormat, tzFormat;
|
| 3982 |
+
var timezones = {
|
| 3983 |
+
' GMT': ' +0000',
|
| 3984 |
+
' EDT': ' -0400',
|
| 3985 |
+
' EST': ' -0500',
|
| 3986 |
+
' CDT': ' -0500',
|
| 3987 |
+
' CST': ' -0600',
|
| 3988 |
+
' MDT': ' -0600',
|
| 3989 |
+
' MST': ' -0700',
|
| 3990 |
+
' PDT': ' -0700',
|
| 3991 |
+
' PST': ' -0800'
|
| 3992 |
+
};
|
| 3993 |
+
var military = 'YXWVUTSRQPONZABCDEFGHIKLM';
|
| 3994 |
+
var timezone, timezoneIndex;
|
| 3995 |
+
|
| 3996 |
+
string = config._i
|
| 3997 |
+
.replace(/\([^\)]*\)|[\n\t]/g, ' ') // Remove comments and folding whitespace
|
| 3998 |
+
.replace(/(\s\s+)/g, ' ') // Replace multiple-spaces with a single space
|
| 3999 |
+
.replace(/^\s|\s$/g, ''); // Remove leading and trailing spaces
|
| 4000 |
+
match = basicRfcRegex.exec(string);
|
| 4001 |
+
|
| 4002 |
+
if (match) {
|
| 4003 |
+
dayFormat = match[1] ? 'ddd' + ((match[1].length === 5) ? ', ' : ' ') : '';
|
| 4004 |
+
dateFormat = 'D MMM ' + ((match[2].length > 10) ? 'YYYY ' : 'YY ');
|
| 4005 |
+
timeFormat = 'HH:mm' + (match[4] ? ':ss' : '');
|
| 4006 |
+
|
| 4007 |
+
// TODO: Replace the vanilla JS Date object with an indepentent day-of-week check.
|
| 4008 |
+
if (match[1]) { // day of week given
|
| 4009 |
+
var momentDate = new Date(match[2]);
|
| 4010 |
+
var momentDay = ['Sun','Mon','Tue','Wed','Thu','Fri','Sat'][momentDate.getDay()];
|
| 4011 |
+
|
| 4012 |
+
if (match[1].substr(0,3) !== momentDay) {
|
| 4013 |
+
getParsingFlags(config).weekdayMismatch = true;
|
| 4014 |
+
config._isValid = false;
|
| 4015 |
+
return;
|
| 4016 |
+
}
|
| 4017 |
+
}
|
| 4018 |
+
|
| 4019 |
+
switch (match[5].length) {
|
| 4020 |
+
case 2: // military
|
| 4021 |
+
if (timezoneIndex === 0) {
|
| 4022 |
+
timezone = ' +0000';
|
| 4023 |
+
} else {
|
| 4024 |
+
timezoneIndex = military.indexOf(match[5][1].toUpperCase()) - 12;
|
| 4025 |
+
timezone = ((timezoneIndex < 0) ? ' -' : ' +') +
|
| 4026 |
+
(('' + timezoneIndex).replace(/^-?/, '0')).match(/..$/)[0] + '00';
|
| 4027 |
+
}
|
| 4028 |
+
break;
|
| 4029 |
+
case 4: // Zone
|
| 4030 |
+
timezone = timezones[match[5]];
|
| 4031 |
+
break;
|
| 4032 |
+
default: // UT or +/-9999
|
| 4033 |
+
timezone = timezones[' GMT'];
|
| 4034 |
+
}
|
| 4035 |
+
match[5] = timezone;
|
| 4036 |
+
config._i = match.splice(1).join('');
|
| 4037 |
+
tzFormat = ' ZZ';
|
| 4038 |
+
config._f = dayFormat + dateFormat + timeFormat + tzFormat;
|
| 4039 |
+
configFromStringAndFormat(config);
|
| 4040 |
+
getParsingFlags(config).rfc2822 = true;
|
| 4041 |
+
} else {
|
| 4042 |
+
config._isValid = false;
|
| 4043 |
+
}
|
| 4044 |
+
}
|
| 4045 |
+
|
| 4046 |
// date from iso format or fallback
|
| 4047 |
function configFromString(config) {
|
| 4048 |
var matched = aspNetJsonRegex.exec(config._i);
|
| 4055 |
configFromISO(config);
|
| 4056 |
if (config._isValid === false) {
|
| 4057 |
delete config._isValid;
|
| 4058 |
+
} else {
|
| 4059 |
+
return;
|
| 4060 |
+
}
|
| 4061 |
+
|
| 4062 |
+
configFromRFC2822(config);
|
| 4063 |
+
if (config._isValid === false) {
|
| 4064 |
+
delete config._isValid;
|
| 4065 |
+
} else {
|
| 4066 |
+
return;
|
| 4067 |
}
|
| 4068 |
+
|
| 4069 |
+
// Final attempt, use Input Fallback
|
| 4070 |
+
hooks.createFromInputFallback(config);
|
| 4071 |
}
|
| 4072 |
|
| 4073 |
hooks.createFromInputFallback = deprecate(
|
| 4074 |
+
'value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), ' +
|
| 4075 |
+
'which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are ' +
|
| 4076 |
'discouraged and will be removed in an upcoming major release. Please refer to ' +
|
| 4077 |
'http://momentjs.com/guides/#/warnings/js-date/ for more info.',
|
| 4078 |
function (config) {
|
| 4119 |
}
|
| 4120 |
|
| 4121 |
//if the day of the year is set, figure out what it is
|
| 4122 |
+
if (config._dayOfYear != null) {
|
| 4123 |
yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);
|
| 4124 |
|
| 4125 |
+
if (config._dayOfYear > daysInYear(yearToUse) || config._dayOfYear === 0) {
|
| 4126 |
getParsingFlags(config)._overflowDayOfYear = true;
|
| 4127 |
}
|
| 4128 |
|
| 4226 |
// constant that refers to the ISO standard
|
| 4227 |
hooks.ISO_8601 = function () {};
|
| 4228 |
|
| 4229 |
+
// constant that refers to the RFC 2822 form
|
| 4230 |
+
hooks.RFC_2822 = function () {};
|
| 4231 |
+
|
| 4232 |
// date from string and format string
|
| 4233 |
function configFromStringAndFormat(config) {
|
| 4234 |
// TODO: Move this to another part of the creation flow to prevent circular deps
|
| 4236 |
configFromISO(config);
|
| 4237 |
return;
|
| 4238 |
}
|
| 4239 |
+
if (config._f === hooks.RFC_2822) {
|
| 4240 |
+
configFromRFC2822(config);
|
| 4241 |
+
return;
|
| 4242 |
+
}
|
| 4243 |
config._a = [];
|
| 4244 |
getParsingFlags(config).empty = true;
|
| 4245 |
|
| 4431 |
|
| 4432 |
function configFromInput(config) {
|
| 4433 |
var input = config._i;
|
| 4434 |
+
if (isUndefined(input)) {
|
| 4435 |
config._d = new Date(hooks.now());
|
| 4436 |
} else if (isDate(input)) {
|
| 4437 |
config._d = new Date(input.valueOf());
|
| 4442 |
return parseInt(obj, 10);
|
| 4443 |
});
|
| 4444 |
configFromArray(config);
|
| 4445 |
+
} else if (isObject(input)) {
|
| 4446 |
configFromObject(config);
|
| 4447 |
} else if (isNumber(input)) {
|
| 4448 |
// from milliseconds
|
| 4543 |
return Date.now ? Date.now() : +(new Date());
|
| 4544 |
};
|
| 4545 |
|
| 4546 |
+
var ordering = ['year', 'quarter', 'month', 'week', 'day', 'hour', 'minute', 'second', 'millisecond'];
|
| 4547 |
+
|
| 4548 |
+
function isDurationValid(m) {
|
| 4549 |
+
for (var key in m) {
|
| 4550 |
+
if (!(ordering.indexOf(key) !== -1 && (m[key] == null || !isNaN(m[key])))) {
|
| 4551 |
+
return false;
|
| 4552 |
+
}
|
| 4553 |
+
}
|
| 4554 |
+
|
| 4555 |
+
var unitHasDecimal = false;
|
| 4556 |
+
for (var i = 0; i < ordering.length; ++i) {
|
| 4557 |
+
if (m[ordering[i]]) {
|
| 4558 |
+
if (unitHasDecimal) {
|
| 4559 |
+
return false; // only allow non-integers for smallest unit
|
| 4560 |
+
}
|
| 4561 |
+
if (parseFloat(m[ordering[i]]) !== toInt(m[ordering[i]])) {
|
| 4562 |
+
unitHasDecimal = true;
|
| 4563 |
+
}
|
| 4564 |
+
}
|
| 4565 |
+
}
|
| 4566 |
+
|
| 4567 |
+
return true;
|
| 4568 |
+
}
|
| 4569 |
+
|
| 4570 |
+
function isValid$1() {
|
| 4571 |
+
return this._isValid;
|
| 4572 |
+
}
|
| 4573 |
+
|
| 4574 |
+
function createInvalid$1() {
|
| 4575 |
+
return createDuration(NaN);
|
| 4576 |
+
}
|
| 4577 |
+
|
| 4578 |
function Duration (duration) {
|
| 4579 |
var normalizedInput = normalizeObjectUnits(duration),
|
| 4580 |
years = normalizedInput.year || 0,
|
| 4587 |
seconds = normalizedInput.second || 0,
|
| 4588 |
milliseconds = normalizedInput.millisecond || 0;
|
| 4589 |
|
| 4590 |
+
this._isValid = isDurationValid(normalizedInput);
|
| 4591 |
+
|
| 4592 |
// representation for dateAddRemove
|
| 4593 |
this._milliseconds = +milliseconds +
|
| 4594 |
seconds * 1e3 + // 1000
|
| 4712 |
// a second time. In case it wants us to change the offset again
|
| 4713 |
// _changeInProgress == true case, then we have to adjust, because
|
| 4714 |
// there is no such time in the given timezone.
|
| 4715 |
+
function getSetOffset (input, keepLocalTime, keepMinutes) {
|
| 4716 |
var offset = this._offset || 0,
|
| 4717 |
localAdjust;
|
| 4718 |
if (!this.isValid()) {
|
| 4724 |
if (input === null) {
|
| 4725 |
return this;
|
| 4726 |
}
|
| 4727 |
+
} else if (Math.abs(input) < 16 && !keepMinutes) {
|
| 4728 |
input = input * 60;
|
| 4729 |
}
|
| 4730 |
if (!this._isUTC && keepLocalTime) {
|
| 4782 |
|
| 4783 |
function setOffsetToParsedOffset () {
|
| 4784 |
if (this._tzm != null) {
|
| 4785 |
+
this.utcOffset(this._tzm, false, true);
|
| 4786 |
} else if (typeof this._i === 'string') {
|
| 4787 |
var tZone = offsetFromString(matchOffset, this._i);
|
| 4788 |
if (tZone != null) {
|
| 4914 |
}
|
| 4915 |
|
| 4916 |
createDuration.fn = Duration.prototype;
|
| 4917 |
+
createDuration.invalid = createInvalid$1;
|
| 4918 |
|
| 4919 |
function parseIso (inp, sign) {
|
| 4920 |
// We'd normally use ~~inp for this, but unfortunately it also
|
| 5151 |
return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
|
| 5152 |
}
|
| 5153 |
|
| 5154 |
+
function toISOString() {
|
| 5155 |
+
if (!this.isValid()) {
|
| 5156 |
+
return null;
|
| 5157 |
+
}
|
| 5158 |
var m = this.clone().utc();
|
| 5159 |
+
if (m.year() < 0 || m.year() > 9999) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5160 |
return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 5161 |
}
|
| 5162 |
+
if (isFunction(Date.prototype.toISOString)) {
|
| 5163 |
+
// native implementation is ~50x faster, use it when we can
|
| 5164 |
+
return this.toDate().toISOString();
|
| 5165 |
+
}
|
| 5166 |
+
return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
|
| 5167 |
}
|
| 5168 |
|
| 5169 |
/**
|
| 5183 |
zone = 'Z';
|
| 5184 |
}
|
| 5185 |
var prefix = '[' + func + '("]';
|
| 5186 |
+
var year = (0 <= this.year() && this.year() <= 9999) ? 'YYYY' : 'YYYYYY';
|
| 5187 |
var datetime = '-MM-DD[T]HH:mm:ss.SSS';
|
| 5188 |
var suffix = zone + '[")]';
|
| 5189 |
|
| 5351 |
return this.isValid() ? this.toISOString() : null;
|
| 5352 |
}
|
| 5353 |
|
| 5354 |
+
function isValid$2 () {
|
| 5355 |
return isValid(this);
|
| 5356 |
}
|
| 5357 |
|
| 5511 |
addRegexToken('D', match1to2);
|
| 5512 |
addRegexToken('DD', match1to2, match2);
|
| 5513 |
addRegexToken('Do', function (isStrict, locale) {
|
| 5514 |
+
// TODO: Remove "ordinalParse" fallback in next major release.
|
| 5515 |
+
return isStrict ?
|
| 5516 |
+
(locale._dayOfMonthOrdinalParse || locale._ordinalParse) :
|
| 5517 |
+
locale._dayOfMonthOrdinalParseLenient;
|
| 5518 |
});
|
| 5519 |
|
| 5520 |
addParseToken(['D', 'DD'], DATE);
|
| 5694 |
proto.isSame = isSame;
|
| 5695 |
proto.isSameOrAfter = isSameOrAfter;
|
| 5696 |
proto.isSameOrBefore = isSameOrBefore;
|
| 5697 |
+
proto.isValid = isValid$2;
|
| 5698 |
proto.lang = lang;
|
| 5699 |
proto.locale = locale;
|
| 5700 |
proto.localeData = localeData;
|
| 5919 |
}
|
| 5920 |
|
| 5921 |
getSetGlobalLocale('en', {
|
| 5922 |
+
dayOfMonthOrdinalParse: /\d{1,2}(th|st|nd|rd)/,
|
| 5923 |
ordinal : function (number) {
|
| 5924 |
var b = number % 10,
|
| 5925 |
output = (toInt(number % 100 / 10) === 1) ? 'th' :
|
| 6040 |
}
|
| 6041 |
|
| 6042 |
function as (units) {
|
| 6043 |
+
if (!this.isValid()) {
|
| 6044 |
+
return NaN;
|
| 6045 |
+
}
|
| 6046 |
var days;
|
| 6047 |
var months;
|
| 6048 |
var milliseconds = this._milliseconds;
|
| 6071 |
|
| 6072 |
// TODO: Use this.as('ms')?
|
| 6073 |
function valueOf$1 () {
|
| 6074 |
+
if (!this.isValid()) {
|
| 6075 |
+
return NaN;
|
| 6076 |
+
}
|
| 6077 |
return (
|
| 6078 |
this._milliseconds +
|
| 6079 |
this._days * 864e5 +
|
| 6099 |
|
| 6100 |
function get$2 (units) {
|
| 6101 |
units = normalizeUnits(units);
|
| 6102 |
+
return this.isValid() ? this[units + 's']() : NaN;
|
| 6103 |
}
|
| 6104 |
|
| 6105 |
function makeGetter(name) {
|
| 6106 |
return function () {
|
| 6107 |
+
return this.isValid() ? this._data[name] : NaN;
|
| 6108 |
};
|
| 6109 |
}
|
| 6110 |
|
| 6122 |
|
| 6123 |
var round = Math.round;
|
| 6124 |
var thresholds = {
|
| 6125 |
+
ss: 44, // a few seconds to seconds
|
| 6126 |
+
s : 45, // seconds to minute
|
| 6127 |
+
m : 45, // minutes to hour
|
| 6128 |
+
h : 22, // hours to day
|
| 6129 |
+
d : 26, // days to month
|
| 6130 |
+
M : 11 // months to year
|
| 6131 |
};
|
| 6132 |
|
| 6133 |
// helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize
|
| 6144 |
var months = round(duration.as('M'));
|
| 6145 |
var years = round(duration.as('y'));
|
| 6146 |
|
| 6147 |
+
var a = seconds <= thresholds.ss && ['s', seconds] ||
|
| 6148 |
+
seconds < thresholds.s && ['ss', seconds] ||
|
| 6149 |
+
minutes <= 1 && ['m'] ||
|
| 6150 |
+
minutes < thresholds.m && ['mm', minutes] ||
|
| 6151 |
+
hours <= 1 && ['h'] ||
|
| 6152 |
+
hours < thresholds.h && ['hh', hours] ||
|
| 6153 |
+
days <= 1 && ['d'] ||
|
| 6154 |
+
days < thresholds.d && ['dd', days] ||
|
| 6155 |
+
months <= 1 && ['M'] ||
|
| 6156 |
+
months < thresholds.M && ['MM', months] ||
|
| 6157 |
+
years <= 1 && ['y'] || ['yy', years];
|
| 6158 |
|
| 6159 |
a[2] = withoutSuffix;
|
| 6160 |
a[3] = +posNegDuration > 0;
|
| 6183 |
return thresholds[threshold];
|
| 6184 |
}
|
| 6185 |
thresholds[threshold] = limit;
|
| 6186 |
+
if (threshold === 's') {
|
| 6187 |
+
thresholds.ss = limit - 1;
|
| 6188 |
+
}
|
| 6189 |
return true;
|
| 6190 |
}
|
| 6191 |
|
| 6192 |
function humanize (withSuffix) {
|
| 6193 |
+
if (!this.isValid()) {
|
| 6194 |
+
return this.localeData().invalidDate();
|
| 6195 |
+
}
|
| 6196 |
+
|
| 6197 |
var locale = this.localeData();
|
| 6198 |
var output = relativeTime$1(this, !withSuffix, locale);
|
| 6199 |
|
| 6214 |
// This is because there is no context-free conversion between hours and days
|
| 6215 |
// (think of clock changes)
|
| 6216 |
// and also not between days and months (28-31 days per month)
|
| 6217 |
+
if (!this.isValid()) {
|
| 6218 |
+
return this.localeData().invalidDate();
|
| 6219 |
+
}
|
| 6220 |
+
|
| 6221 |
var seconds = abs$1(this._milliseconds) / 1000;
|
| 6222 |
var days = abs$1(this._days);
|
| 6223 |
var months = abs$1(this._months);
|
| 6262 |
|
| 6263 |
var proto$2 = Duration.prototype;
|
| 6264 |
|
| 6265 |
+
proto$2.isValid = isValid$1;
|
| 6266 |
proto$2.abs = abs;
|
| 6267 |
proto$2.add = add$1;
|
| 6268 |
proto$2.subtract = subtract$1;
|
| 6318 |
// Side effect imports
|
| 6319 |
|
| 6320 |
|
| 6321 |
+
hooks.version = '2.18.1';
|
| 6322 |
|
| 6323 |
setHookCallback(createLocal);
|
| 6324 |
|
| 6354 |
|
| 6355 |
})));
|
| 6356 |
|
| 6357 |
+
/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(298)(module)))
|
| 6358 |
|
| 6359 |
/***/ },
|
| 6360 |
+
/* 298 */
|
| 6361 |
/***/ function(module, exports) {
|
| 6362 |
|
| 6363 |
module.exports = function(module) {
|
| 6373 |
|
| 6374 |
|
| 6375 |
/***/ },
|
| 6376 |
+
/* 299 */
|
| 6377 |
/***/ function(module, exports, __webpack_require__) {
|
| 6378 |
|
| 6379 |
var map = {
|
| 6380 |
+
"./af": 300,
|
| 6381 |
+
"./af.js": 300,
|
| 6382 |
+
"./ar": 301,
|
| 6383 |
+
"./ar-dz": 302,
|
| 6384 |
+
"./ar-dz.js": 302,
|
| 6385 |
+
"./ar-kw": 303,
|
| 6386 |
+
"./ar-kw.js": 303,
|
| 6387 |
+
"./ar-ly": 304,
|
| 6388 |
+
"./ar-ly.js": 304,
|
| 6389 |
+
"./ar-ma": 305,
|
| 6390 |
+
"./ar-ma.js": 305,
|
| 6391 |
+
"./ar-sa": 306,
|
| 6392 |
+
"./ar-sa.js": 306,
|
| 6393 |
+
"./ar-tn": 307,
|
| 6394 |
+
"./ar-tn.js": 307,
|
| 6395 |
+
"./ar.js": 301,
|
| 6396 |
+
"./az": 308,
|
| 6397 |
+
"./az.js": 308,
|
| 6398 |
+
"./be": 309,
|
| 6399 |
+
"./be.js": 309,
|
| 6400 |
+
"./bg": 310,
|
| 6401 |
+
"./bg.js": 310,
|
| 6402 |
+
"./bn": 311,
|
| 6403 |
+
"./bn.js": 311,
|
| 6404 |
+
"./bo": 312,
|
| 6405 |
+
"./bo.js": 312,
|
| 6406 |
+
"./br": 313,
|
| 6407 |
+
"./br.js": 313,
|
| 6408 |
+
"./bs": 314,
|
| 6409 |
+
"./bs.js": 314,
|
| 6410 |
+
"./ca": 315,
|
| 6411 |
+
"./ca.js": 315,
|
| 6412 |
+
"./cs": 316,
|
| 6413 |
+
"./cs.js": 316,
|
| 6414 |
+
"./cv": 317,
|
| 6415 |
+
"./cv.js": 317,
|
| 6416 |
+
"./cy": 318,
|
| 6417 |
+
"./cy.js": 318,
|
| 6418 |
+
"./da": 319,
|
| 6419 |
+
"./da.js": 319,
|
| 6420 |
+
"./de": 320,
|
| 6421 |
+
"./de-at": 321,
|
| 6422 |
+
"./de-at.js": 321,
|
| 6423 |
+
"./de-ch": 322,
|
| 6424 |
+
"./de-ch.js": 322,
|
| 6425 |
+
"./de.js": 320,
|
| 6426 |
+
"./dv": 323,
|
| 6427 |
+
"./dv.js": 323,
|
| 6428 |
+
"./el": 324,
|
| 6429 |
+
"./el.js": 324,
|
| 6430 |
+
"./en-au": 325,
|
| 6431 |
+
"./en-au.js": 325,
|
| 6432 |
+
"./en-ca": 326,
|
| 6433 |
+
"./en-ca.js": 326,
|
| 6434 |
+
"./en-gb": 327,
|
| 6435 |
+
"./en-gb.js": 327,
|
| 6436 |
+
"./en-ie": 328,
|
| 6437 |
+
"./en-ie.js": 328,
|
| 6438 |
+
"./en-nz": 329,
|
| 6439 |
+
"./en-nz.js": 329,
|
| 6440 |
+
"./eo": 330,
|
| 6441 |
+
"./eo.js": 330,
|
| 6442 |
+
"./es": 331,
|
| 6443 |
+
"./es-do": 332,
|
| 6444 |
+
"./es-do.js": 332,
|
| 6445 |
+
"./es.js": 331,
|
| 6446 |
+
"./et": 333,
|
| 6447 |
+
"./et.js": 333,
|
| 6448 |
+
"./eu": 334,
|
| 6449 |
+
"./eu.js": 334,
|
| 6450 |
+
"./fa": 335,
|
| 6451 |
+
"./fa.js": 335,
|
| 6452 |
+
"./fi": 336,
|
| 6453 |
+
"./fi.js": 336,
|
| 6454 |
+
"./fo": 337,
|
| 6455 |
+
"./fo.js": 337,
|
| 6456 |
+
"./fr": 338,
|
| 6457 |
+
"./fr-ca": 339,
|
| 6458 |
+
"./fr-ca.js": 339,
|
| 6459 |
+
"./fr-ch": 340,
|
| 6460 |
+
"./fr-ch.js": 340,
|
| 6461 |
+
"./fr.js": 338,
|
| 6462 |
+
"./fy": 341,
|
| 6463 |
+
"./fy.js": 341,
|
| 6464 |
+
"./gd": 342,
|
| 6465 |
+
"./gd.js": 342,
|
| 6466 |
+
"./gl": 343,
|
| 6467 |
+
"./gl.js": 343,
|
| 6468 |
+
"./gom-latn": 344,
|
| 6469 |
+
"./gom-latn.js": 344,
|
| 6470 |
+
"./he": 345,
|
| 6471 |
+
"./he.js": 345,
|
| 6472 |
+
"./hi": 346,
|
| 6473 |
+
"./hi.js": 346,
|
| 6474 |
+
"./hr": 347,
|
| 6475 |
+
"./hr.js": 347,
|
| 6476 |
+
"./hu": 348,
|
| 6477 |
+
"./hu.js": 348,
|
| 6478 |
+
"./hy-am": 349,
|
| 6479 |
+
"./hy-am.js": 349,
|
| 6480 |
+
"./id": 350,
|
| 6481 |
+
"./id.js": 350,
|
| 6482 |
+
"./is": 351,
|
| 6483 |
+
"./is.js": 351,
|
| 6484 |
+
"./it": 352,
|
| 6485 |
+
"./it.js": 352,
|
| 6486 |
+
"./ja": 353,
|
| 6487 |
+
"./ja.js": 353,
|
| 6488 |
+
"./jv": 354,
|
| 6489 |
+
"./jv.js": 354,
|
| 6490 |
+
"./ka": 355,
|
| 6491 |
+
"./ka.js": 355,
|
| 6492 |
+
"./kk": 356,
|
| 6493 |
+
"./kk.js": 356,
|
| 6494 |
+
"./km": 357,
|
| 6495 |
+
"./km.js": 357,
|
| 6496 |
+
"./kn": 358,
|
| 6497 |
+
"./kn.js": 358,
|
| 6498 |
+
"./ko": 359,
|
| 6499 |
+
"./ko.js": 359,
|
| 6500 |
+
"./ky": 360,
|
| 6501 |
+
"./ky.js": 360,
|
| 6502 |
+
"./lb": 361,
|
| 6503 |
+
"./lb.js": 361,
|
| 6504 |
+
"./lo": 362,
|
| 6505 |
+
"./lo.js": 362,
|
| 6506 |
+
"./lt": 363,
|
| 6507 |
+
"./lt.js": 363,
|
| 6508 |
+
"./lv": 364,
|
| 6509 |
+
"./lv.js": 364,
|
| 6510 |
+
"./me": 365,
|
| 6511 |
+
"./me.js": 365,
|
| 6512 |
+
"./mi": 366,
|
| 6513 |
+
"./mi.js": 366,
|
| 6514 |
+
"./mk": 367,
|
| 6515 |
+
"./mk.js": 367,
|
| 6516 |
+
"./ml": 368,
|
| 6517 |
+
"./ml.js": 368,
|
| 6518 |
+
"./mr": 369,
|
| 6519 |
+
"./mr.js": 369,
|
| 6520 |
+
"./ms": 370,
|
| 6521 |
+
"./ms-my": 371,
|
| 6522 |
+
"./ms-my.js": 371,
|
| 6523 |
+
"./ms.js": 370,
|
| 6524 |
+
"./my": 372,
|
| 6525 |
+
"./my.js": 372,
|
| 6526 |
+
"./nb": 373,
|
| 6527 |
+
"./nb.js": 373,
|
| 6528 |
+
"./ne": 374,
|
| 6529 |
+
"./ne.js": 374,
|
| 6530 |
+
"./nl": 375,
|
| 6531 |
+
"./nl-be": 376,
|
| 6532 |
+
"./nl-be.js": 376,
|
| 6533 |
+
"./nl.js": 375,
|
| 6534 |
+
"./nn": 377,
|
| 6535 |
+
"./nn.js": 377,
|
| 6536 |
+
"./pa-in": 378,
|
| 6537 |
+
"./pa-in.js": 378,
|
| 6538 |
+
"./pl": 379,
|
| 6539 |
+
"./pl.js": 379,
|
| 6540 |
+
"./pt": 380,
|
| 6541 |
+
"./pt-br": 381,
|
| 6542 |
+
"./pt-br.js": 381,
|
| 6543 |
+
"./pt.js": 380,
|
| 6544 |
+
"./ro": 382,
|
| 6545 |
+
"./ro.js": 382,
|
| 6546 |
+
"./ru": 383,
|
| 6547 |
+
"./ru.js": 383,
|
| 6548 |
+
"./sd": 384,
|
| 6549 |
+
"./sd.js": 384,
|
| 6550 |
+
"./se": 385,
|
| 6551 |
+
"./se.js": 385,
|
| 6552 |
+
"./si": 386,
|
| 6553 |
+
"./si.js": 386,
|
| 6554 |
+
"./sk": 387,
|
| 6555 |
+
"./sk.js": 387,
|
| 6556 |
+
"./sl": 388,
|
| 6557 |
+
"./sl.js": 388,
|
| 6558 |
+
"./sq": 389,
|
| 6559 |
+
"./sq.js": 389,
|
| 6560 |
+
"./sr": 390,
|
| 6561 |
+
"./sr-cyrl": 391,
|
| 6562 |
+
"./sr-cyrl.js": 391,
|
| 6563 |
+
"./sr.js": 390,
|
| 6564 |
+
"./ss": 392,
|
| 6565 |
+
"./ss.js": 392,
|
| 6566 |
+
"./sv": 393,
|
| 6567 |
+
"./sv.js": 393,
|
| 6568 |
+
"./sw": 394,
|
| 6569 |
+
"./sw.js": 394,
|
| 6570 |
+
"./ta": 395,
|
| 6571 |
+
"./ta.js": 395,
|
| 6572 |
+
"./te": 396,
|
| 6573 |
+
"./te.js": 396,
|
| 6574 |
+
"./tet": 397,
|
| 6575 |
+
"./tet.js": 397,
|
| 6576 |
+
"./th": 398,
|
| 6577 |
+
"./th.js": 398,
|
| 6578 |
+
"./tl-ph": 399,
|
| 6579 |
+
"./tl-ph.js": 399,
|
| 6580 |
+
"./tlh": 400,
|
| 6581 |
+
"./tlh.js": 400,
|
| 6582 |
+
"./tr": 401,
|
| 6583 |
+
"./tr.js": 401,
|
| 6584 |
+
"./tzl": 402,
|
| 6585 |
+
"./tzl.js": 402,
|
| 6586 |
+
"./tzm": 403,
|
| 6587 |
+
"./tzm-latn": 404,
|
| 6588 |
+
"./tzm-latn.js": 404,
|
| 6589 |
+
"./tzm.js": 403,
|
| 6590 |
+
"./uk": 405,
|
| 6591 |
+
"./uk.js": 405,
|
| 6592 |
+
"./ur": 406,
|
| 6593 |
+
"./ur.js": 406,
|
| 6594 |
+
"./uz": 407,
|
| 6595 |
+
"./uz-latn": 408,
|
| 6596 |
+
"./uz-latn.js": 408,
|
| 6597 |
+
"./uz.js": 407,
|
| 6598 |
+
"./vi": 409,
|
| 6599 |
+
"./vi.js": 409,
|
| 6600 |
+
"./x-pseudo": 410,
|
| 6601 |
+
"./x-pseudo.js": 410,
|
| 6602 |
+
"./yo": 411,
|
| 6603 |
+
"./yo.js": 411,
|
| 6604 |
+
"./zh-cn": 412,
|
| 6605 |
+
"./zh-cn.js": 412,
|
| 6606 |
+
"./zh-hk": 413,
|
| 6607 |
+
"./zh-hk.js": 413,
|
| 6608 |
+
"./zh-tw": 414,
|
| 6609 |
+
"./zh-tw.js": 414
|
| 6610 |
};
|
| 6611 |
function webpackContext(req) {
|
| 6612 |
return __webpack_require__(webpackContextResolve(req));
|
| 6619 |
};
|
| 6620 |
webpackContext.resolve = webpackContextResolve;
|
| 6621 |
module.exports = webpackContext;
|
| 6622 |
+
webpackContext.id = 299;
|
| 6623 |
|
| 6624 |
|
| 6625 |
/***/ },
|
| 6626 |
+
/* 300 */
|
| 6627 |
/***/ function(module, exports, __webpack_require__) {
|
| 6628 |
|
| 6629 |
//! moment.js locale configuration
|
| 6631 |
//! author : Werner Mollentze : https://github.com/wernerm
|
| 6632 |
|
| 6633 |
;(function (global, factory) {
|
| 6634 |
+
true ? factory(__webpack_require__(297)) :
|
| 6635 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6636 |
factory(global.moment)
|
| 6637 |
}(this, (function (moment) { 'use strict';
|
| 6685 |
y : '\'n jaar',
|
| 6686 |
yy : '%d jaar'
|
| 6687 |
},
|
| 6688 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 6689 |
ordinal : function (number) {
|
| 6690 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de'); // Thanks to Joris Röling : https://github.com/jjupiter
|
| 6691 |
},
|
| 6701 |
|
| 6702 |
|
| 6703 |
/***/ },
|
| 6704 |
+
/* 301 */
|
| 6705 |
/***/ function(module, exports, __webpack_require__) {
|
| 6706 |
|
| 6707 |
//! moment.js locale configuration
|
| 6711 |
//! author : forabi https://github.com/forabi
|
| 6712 |
|
| 6713 |
;(function (global, factory) {
|
| 6714 |
+
true ? factory(__webpack_require__(297)) :
|
| 6715 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6716 |
factory(global.moment)
|
| 6717 |
}(this, (function (moment) { 'use strict';
|
| 6848 |
|
| 6849 |
|
| 6850 |
/***/ },
|
| 6851 |
+
/* 302 */
|
| 6852 |
/***/ function(module, exports, __webpack_require__) {
|
| 6853 |
|
| 6854 |
//! moment.js locale configuration
|
| 6856 |
//! author : Noureddine LOUAHEDJ : https://github.com/noureddineme
|
| 6857 |
|
| 6858 |
;(function (global, factory) {
|
| 6859 |
+
true ? factory(__webpack_require__(297)) :
|
| 6860 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6861 |
factory(global.moment)
|
| 6862 |
}(this, (function (moment) { 'use strict';
|
| 6912 |
|
| 6913 |
|
| 6914 |
/***/ },
|
| 6915 |
+
/* 303 */
|
| 6916 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 6917 |
+
|
| 6918 |
+
//! moment.js locale configuration
|
| 6919 |
+
//! locale : Arabic (Kuwait) [ar-kw]
|
| 6920 |
+
//! author : Nusret Parlak: https://github.com/nusretparlak
|
| 6921 |
+
|
| 6922 |
+
;(function (global, factory) {
|
| 6923 |
+
true ? factory(__webpack_require__(297)) :
|
| 6924 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6925 |
+
factory(global.moment)
|
| 6926 |
+
}(this, (function (moment) { 'use strict';
|
| 6927 |
+
|
| 6928 |
+
|
| 6929 |
+
var arKw = moment.defineLocale('ar-kw', {
|
| 6930 |
+
months : 'يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split('_'),
|
| 6931 |
+
monthsShort : 'يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر'.split('_'),
|
| 6932 |
+
weekdays : 'الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت'.split('_'),
|
| 6933 |
+
weekdaysShort : 'احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت'.split('_'),
|
| 6934 |
+
weekdaysMin : 'ح_ن_ث_ر_خ_ج_س'.split('_'),
|
| 6935 |
+
weekdaysParseExact : true,
|
| 6936 |
+
longDateFormat : {
|
| 6937 |
+
LT : 'HH:mm',
|
| 6938 |
+
LTS : 'HH:mm:ss',
|
| 6939 |
+
L : 'DD/MM/YYYY',
|
| 6940 |
+
LL : 'D MMMM YYYY',
|
| 6941 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 6942 |
+
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 6943 |
+
},
|
| 6944 |
+
calendar : {
|
| 6945 |
+
sameDay: '[اليوم على الساعة] LT',
|
| 6946 |
+
nextDay: '[غدا على الساعة] LT',
|
| 6947 |
+
nextWeek: 'dddd [على الساعة] LT',
|
| 6948 |
+
lastDay: '[أمس على الساعة] LT',
|
| 6949 |
+
lastWeek: 'dddd [على الساعة] LT',
|
| 6950 |
+
sameElse: 'L'
|
| 6951 |
+
},
|
| 6952 |
+
relativeTime : {
|
| 6953 |
+
future : 'في %s',
|
| 6954 |
+
past : 'منذ %s',
|
| 6955 |
+
s : 'ثوان',
|
| 6956 |
+
m : 'دقيقة',
|
| 6957 |
+
mm : '%d دقائق',
|
| 6958 |
+
h : 'ساعة',
|
| 6959 |
+
hh : '%d ساعات',
|
| 6960 |
+
d : 'يوم',
|
| 6961 |
+
dd : '%d أيام',
|
| 6962 |
+
M : 'شهر',
|
| 6963 |
+
MM : '%d أشهر',
|
| 6964 |
+
y : 'سنة',
|
| 6965 |
+
yy : '%d سنوات'
|
| 6966 |
+
},
|
| 6967 |
+
week : {
|
| 6968 |
+
dow : 0, // Sunday is the first day of the week.
|
| 6969 |
+
doy : 12 // The week that contains Jan 1st is the first week of the year.
|
| 6970 |
+
}
|
| 6971 |
+
});
|
| 6972 |
+
|
| 6973 |
+
return arKw;
|
| 6974 |
+
|
| 6975 |
+
})));
|
| 6976 |
+
|
| 6977 |
+
|
| 6978 |
+
/***/ },
|
| 6979 |
+
/* 304 */
|
| 6980 |
/***/ function(module, exports, __webpack_require__) {
|
| 6981 |
|
| 6982 |
//! moment.js locale configuration
|
| 6984 |
//! author : Ali Hmer: https://github.com/kikoanis
|
| 6985 |
|
| 6986 |
;(function (global, factory) {
|
| 6987 |
+
true ? factory(__webpack_require__(297)) :
|
| 6988 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 6989 |
factory(global.moment)
|
| 6990 |
}(this, (function (moment) { 'use strict';
|
| 7107 |
|
| 7108 |
|
| 7109 |
/***/ },
|
| 7110 |
+
/* 305 */
|
| 7111 |
/***/ function(module, exports, __webpack_require__) {
|
| 7112 |
|
| 7113 |
//! moment.js locale configuration
|
| 7116 |
//! author : Abdel Said : https://github.com/abdelsaid
|
| 7117 |
|
| 7118 |
;(function (global, factory) {
|
| 7119 |
+
true ? factory(__webpack_require__(297)) :
|
| 7120 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7121 |
factory(global.moment)
|
| 7122 |
}(this, (function (moment) { 'use strict';
|
| 7172 |
|
| 7173 |
|
| 7174 |
/***/ },
|
| 7175 |
+
/* 306 */
|
| 7176 |
/***/ function(module, exports, __webpack_require__) {
|
| 7177 |
|
| 7178 |
//! moment.js locale configuration
|
| 7180 |
//! author : Suhail Alkowaileet : https://github.com/xsoh
|
| 7181 |
|
| 7182 |
;(function (global, factory) {
|
| 7183 |
+
true ? factory(__webpack_require__(297)) :
|
| 7184 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7185 |
factory(global.moment)
|
| 7186 |
}(this, (function (moment) { 'use strict';
|
| 7282 |
|
| 7283 |
|
| 7284 |
/***/ },
|
| 7285 |
+
/* 307 */
|
| 7286 |
/***/ function(module, exports, __webpack_require__) {
|
| 7287 |
|
| 7288 |
//! moment.js locale configuration
|
| 7290 |
//! author : Nader Toukabri : https://github.com/naderio
|
| 7291 |
|
| 7292 |
;(function (global, factory) {
|
| 7293 |
+
true ? factory(__webpack_require__(297)) :
|
| 7294 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7295 |
factory(global.moment)
|
| 7296 |
}(this, (function (moment) { 'use strict';
|
| 7346 |
|
| 7347 |
|
| 7348 |
/***/ },
|
| 7349 |
+
/* 308 */
|
| 7350 |
/***/ function(module, exports, __webpack_require__) {
|
| 7351 |
|
| 7352 |
//! moment.js locale configuration
|
| 7354 |
//! author : topchiyev : https://github.com/topchiyev
|
| 7355 |
|
| 7356 |
;(function (global, factory) {
|
| 7357 |
+
true ? factory(__webpack_require__(297)) :
|
| 7358 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7359 |
factory(global.moment)
|
| 7360 |
}(this, (function (moment) { 'use strict';
|
| 7434 |
return 'axşam';
|
| 7435 |
}
|
| 7436 |
},
|
| 7437 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,
|
| 7438 |
ordinal : function (number) {
|
| 7439 |
if (number === 0) { // special case for zero
|
| 7440 |
return number + '-ıncı';
|
| 7456 |
|
| 7457 |
|
| 7458 |
/***/ },
|
| 7459 |
+
/* 309 */
|
| 7460 |
/***/ function(module, exports, __webpack_require__) {
|
| 7461 |
|
| 7462 |
//! moment.js locale configuration
|
| 7466 |
//! Author : Menelion Elensúle : https://github.com/Oire
|
| 7467 |
|
| 7468 |
;(function (global, factory) {
|
| 7469 |
+
true ? factory(__webpack_require__(297)) :
|
| 7470 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7471 |
factory(global.moment)
|
| 7472 |
}(this, (function (moment) { 'use strict';
|
| 7568 |
return 'вечара';
|
| 7569 |
}
|
| 7570 |
},
|
| 7571 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(і|ы|га)/,
|
| 7572 |
ordinal: function (number, period) {
|
| 7573 |
switch (period) {
|
| 7574 |
case 'M':
|
| 7595 |
|
| 7596 |
|
| 7597 |
/***/ },
|
| 7598 |
+
/* 310 */
|
| 7599 |
/***/ function(module, exports, __webpack_require__) {
|
| 7600 |
|
| 7601 |
//! moment.js locale configuration
|
| 7603 |
//! author : Krasen Borisov : https://github.com/kraz
|
| 7604 |
|
| 7605 |
;(function (global, factory) {
|
| 7606 |
+
true ? factory(__webpack_require__(297)) :
|
| 7607 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7608 |
factory(global.moment)
|
| 7609 |
}(this, (function (moment) { 'use strict';
|
| 7658 |
y : 'година',
|
| 7659 |
yy : '%d години'
|
| 7660 |
},
|
| 7661 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ев|ен|ти|ви|ри|ми)/,
|
| 7662 |
ordinal : function (number) {
|
| 7663 |
var lastDigit = number % 10,
|
| 7664 |
last2Digits = number % 100;
|
| 7690 |
|
| 7691 |
|
| 7692 |
/***/ },
|
| 7693 |
+
/* 311 */
|
| 7694 |
/***/ function(module, exports, __webpack_require__) {
|
| 7695 |
|
| 7696 |
//! moment.js locale configuration
|
| 7698 |
//! author : Kaushik Gandhi : https://github.com/kaushikgandhi
|
| 7699 |
|
| 7700 |
;(function (global, factory) {
|
| 7701 |
+
true ? factory(__webpack_require__(297)) :
|
| 7702 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7703 |
factory(global.moment)
|
| 7704 |
}(this, (function (moment) { 'use strict';
|
| 7814 |
|
| 7815 |
|
| 7816 |
/***/ },
|
| 7817 |
+
/* 312 */
|
| 7818 |
/***/ function(module, exports, __webpack_require__) {
|
| 7819 |
|
| 7820 |
//! moment.js locale configuration
|
| 7822 |
//! author : Thupten N. Chakrishar : https://github.com/vajradog
|
| 7823 |
|
| 7824 |
;(function (global, factory) {
|
| 7825 |
+
true ? factory(__webpack_require__(297)) :
|
| 7826 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7827 |
factory(global.moment)
|
| 7828 |
}(this, (function (moment) { 'use strict';
|
| 7938 |
|
| 7939 |
|
| 7940 |
/***/ },
|
| 7941 |
+
/* 313 */
|
| 7942 |
/***/ function(module, exports, __webpack_require__) {
|
| 7943 |
|
| 7944 |
//! moment.js locale configuration
|
| 7946 |
//! author : Jean-Baptiste Le Duigou : https://github.com/jbleduigou
|
| 7947 |
|
| 7948 |
;(function (global, factory) {
|
| 7949 |
+
true ? factory(__webpack_require__(297)) :
|
| 7950 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 7951 |
factory(global.moment)
|
| 7952 |
}(this, (function (moment) { 'use strict';
|
| 8034 |
y : 'ur bloaz',
|
| 8035 |
yy : specialMutationForYears
|
| 8036 |
},
|
| 8037 |
+
dayOfMonthOrdinalParse: /\d{1,2}(añ|vet)/,
|
| 8038 |
ordinal : function (number) {
|
| 8039 |
var output = (number === 1) ? 'añ' : 'vet';
|
| 8040 |
return number + output;
|
| 8051 |
|
| 8052 |
|
| 8053 |
/***/ },
|
| 8054 |
+
/* 314 */
|
| 8055 |
/***/ function(module, exports, __webpack_require__) {
|
| 8056 |
|
| 8057 |
//! moment.js locale configuration
|
| 8060 |
//! based on (hr) translation by Bojan Marković
|
| 8061 |
|
| 8062 |
;(function (global, factory) {
|
| 8063 |
+
true ? factory(__webpack_require__(297)) :
|
| 8064 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8065 |
factory(global.moment)
|
| 8066 |
}(this, (function (moment) { 'use strict';
|
| 8185 |
y : 'godinu',
|
| 8186 |
yy : translate
|
| 8187 |
},
|
| 8188 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 8189 |
ordinal : '%d.',
|
| 8190 |
week : {
|
| 8191 |
dow : 1, // Monday is the first day of the week.
|
| 8199 |
|
| 8200 |
|
| 8201 |
/***/ },
|
| 8202 |
+
/* 315 */
|
| 8203 |
/***/ function(module, exports, __webpack_require__) {
|
| 8204 |
|
| 8205 |
//! moment.js locale configuration
|
| 8207 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 8208 |
|
| 8209 |
;(function (global, factory) {
|
| 8210 |
+
true ? factory(__webpack_require__(297)) :
|
| 8211 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8212 |
factory(global.moment)
|
| 8213 |
}(this, (function (moment) { 'use strict';
|
| 8214 |
|
| 8215 |
|
| 8216 |
var ca = moment.defineLocale('ca', {
|
| 8217 |
+
months : {
|
| 8218 |
+
standalone: 'gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre'.split('_'),
|
| 8219 |
+
format: 'de gener_de febrer_de març_d\'abril_de maig_de juny_de juliol_d\'agost_de setembre_d\'octubre_de novembre_de desembre'.split('_'),
|
| 8220 |
+
isFormat: /D[oD]?(\s)+MMMM/
|
| 8221 |
+
},
|
| 8222 |
+
monthsShort : 'gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.'.split('_'),
|
| 8223 |
monthsParseExact : true,
|
| 8224 |
weekdays : 'diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte'.split('_'),
|
| 8225 |
weekdaysShort : 'dg._dl._dt._dc._dj._dv._ds.'.split('_'),
|
| 8229 |
LT : 'H:mm',
|
| 8230 |
LTS : 'H:mm:ss',
|
| 8231 |
L : 'DD/MM/YYYY',
|
| 8232 |
+
LL : '[el] D MMMM [de] YYYY',
|
| 8233 |
+
ll : 'D MMM YYYY',
|
| 8234 |
+
LLL : '[el] D MMMM [de] YYYY [a les] H:mm',
|
| 8235 |
+
lll : 'D MMM YYYY, H:mm',
|
| 8236 |
+
LLLL : '[el] dddd D MMMM [de] YYYY [a les] H:mm',
|
| 8237 |
+
llll : 'ddd D MMM YYYY, H:mm'
|
| 8238 |
},
|
| 8239 |
calendar : {
|
| 8240 |
sameDay : function () {
|
| 8269 |
y : 'un any',
|
| 8270 |
yy : '%d anys'
|
| 8271 |
},
|
| 8272 |
+
dayOfMonthOrdinalParse: /\d{1,2}(r|n|t|è|a)/,
|
| 8273 |
ordinal : function (number, period) {
|
| 8274 |
var output = (number === 1) ? 'r' :
|
| 8275 |
(number === 2) ? 'n' :
|
| 8292 |
|
| 8293 |
|
| 8294 |
/***/ },
|
| 8295 |
+
/* 316 */
|
| 8296 |
/***/ function(module, exports, __webpack_require__) {
|
| 8297 |
|
| 8298 |
//! moment.js locale configuration
|
| 8300 |
//! author : petrbela : https://github.com/petrbela
|
| 8301 |
|
| 8302 |
;(function (global, factory) {
|
| 8303 |
+
true ? factory(__webpack_require__(297)) :
|
| 8304 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8305 |
factory(global.moment)
|
| 8306 |
}(this, (function (moment) { 'use strict';
|
| 8455 |
y : translate,
|
| 8456 |
yy : translate
|
| 8457 |
},
|
| 8458 |
+
dayOfMonthOrdinalParse : /\d{1,2}\./,
|
| 8459 |
ordinal : '%d.',
|
| 8460 |
week : {
|
| 8461 |
dow : 1, // Monday is the first day of the week.
|
| 8469 |
|
| 8470 |
|
| 8471 |
/***/ },
|
| 8472 |
+
/* 317 */
|
| 8473 |
/***/ function(module, exports, __webpack_require__) {
|
| 8474 |
|
| 8475 |
//! moment.js locale configuration
|
| 8477 |
//! author : Anatoly Mironov : https://github.com/mirontoli
|
| 8478 |
|
| 8479 |
;(function (global, factory) {
|
| 8480 |
+
true ? factory(__webpack_require__(297)) :
|
| 8481 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8482 |
factory(global.moment)
|
| 8483 |
}(this, (function (moment) { 'use strict';
|
| 8523 |
y : 'пӗр ҫул',
|
| 8524 |
yy : '%d ҫул'
|
| 8525 |
},
|
| 8526 |
+
dayOfMonthOrdinalParse: /\d{1,2}-мӗш/,
|
| 8527 |
ordinal : '%d-мӗш',
|
| 8528 |
week : {
|
| 8529 |
dow : 1, // Monday is the first day of the week.
|
| 8537 |
|
| 8538 |
|
| 8539 |
/***/ },
|
| 8540 |
+
/* 318 */
|
| 8541 |
/***/ function(module, exports, __webpack_require__) {
|
| 8542 |
|
| 8543 |
//! moment.js locale configuration
|
| 8546 |
//! author : https://github.com/ryangreaves
|
| 8547 |
|
| 8548 |
;(function (global, factory) {
|
| 8549 |
+
true ? factory(__webpack_require__(297)) :
|
| 8550 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8551 |
factory(global.moment)
|
| 8552 |
}(this, (function (moment) { 'use strict';
|
| 8591 |
y: 'blwyddyn',
|
| 8592 |
yy: '%d flynedd'
|
| 8593 |
},
|
| 8594 |
+
dayOfMonthOrdinalParse: /\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,
|
| 8595 |
// traditional ordinal numbers above 31 are not commonly used in colloquial Welsh
|
| 8596 |
ordinal: function (number) {
|
| 8597 |
var b = number,
|
| 8623 |
|
| 8624 |
|
| 8625 |
/***/ },
|
| 8626 |
+
/* 319 */
|
| 8627 |
/***/ function(module, exports, __webpack_require__) {
|
| 8628 |
|
| 8629 |
//! moment.js locale configuration
|
| 8631 |
//! author : Ulrik Nielsen : https://github.com/mrbase
|
| 8632 |
|
| 8633 |
;(function (global, factory) {
|
| 8634 |
+
true ? factory(__webpack_require__(297)) :
|
| 8635 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8636 |
factory(global.moment)
|
| 8637 |
}(this, (function (moment) { 'use strict';
|
| 8649 |
L : 'DD/MM/YYYY',
|
| 8650 |
LL : 'D. MMMM YYYY',
|
| 8651 |
LLL : 'D. MMMM YYYY HH:mm',
|
| 8652 |
+
LLLL : 'dddd [d.] D. MMMM YYYY [kl.] HH:mm'
|
| 8653 |
},
|
| 8654 |
calendar : {
|
| 8655 |
+
sameDay : '[i dag kl.] LT',
|
| 8656 |
+
nextDay : '[i morgen kl.] LT',
|
| 8657 |
+
nextWeek : 'på dddd [kl.] LT',
|
| 8658 |
+
lastDay : '[i går kl.] LT',
|
| 8659 |
+
lastWeek : '[i] dddd[s kl.] LT',
|
| 8660 |
sameElse : 'L'
|
| 8661 |
},
|
| 8662 |
relativeTime : {
|
| 8674 |
y : 'et år',
|
| 8675 |
yy : '%d år'
|
| 8676 |
},
|
| 8677 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 8678 |
ordinal : '%d.',
|
| 8679 |
week : {
|
| 8680 |
dow : 1, // Monday is the first day of the week.
|
| 8688 |
|
| 8689 |
|
| 8690 |
/***/ },
|
| 8691 |
+
/* 320 */
|
| 8692 |
/***/ function(module, exports, __webpack_require__) {
|
| 8693 |
|
| 8694 |
//! moment.js locale configuration
|
| 8698 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 8699 |
|
| 8700 |
;(function (global, factory) {
|
| 8701 |
+
true ? factory(__webpack_require__(297)) :
|
| 8702 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8703 |
factory(global.moment)
|
| 8704 |
}(this, (function (moment) { 'use strict';
|
| 8757 |
y : processRelativeTime,
|
| 8758 |
yy : processRelativeTime
|
| 8759 |
},
|
| 8760 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 8761 |
ordinal : '%d.',
|
| 8762 |
week : {
|
| 8763 |
dow : 1, // Monday is the first day of the week.
|
| 8771 |
|
| 8772 |
|
| 8773 |
/***/ },
|
| 8774 |
+
/* 321 */
|
| 8775 |
/***/ function(module, exports, __webpack_require__) {
|
| 8776 |
|
| 8777 |
//! moment.js locale configuration
|
| 8782 |
//! author : Mikolaj Dadela : https://github.com/mik01aj
|
| 8783 |
|
| 8784 |
;(function (global, factory) {
|
| 8785 |
+
true ? factory(__webpack_require__(297)) :
|
| 8786 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8787 |
factory(global.moment)
|
| 8788 |
}(this, (function (moment) { 'use strict';
|
| 8841 |
y : processRelativeTime,
|
| 8842 |
yy : processRelativeTime
|
| 8843 |
},
|
| 8844 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 8845 |
ordinal : '%d.',
|
| 8846 |
week : {
|
| 8847 |
dow : 1, // Monday is the first day of the week.
|
| 8855 |
|
| 8856 |
|
| 8857 |
/***/ },
|
| 8858 |
+
/* 322 */
|
| 8859 |
/***/ function(module, exports, __webpack_require__) {
|
| 8860 |
|
| 8861 |
//! moment.js locale configuration
|
| 8862 |
+
//! locale : German (Switzerland) [de-ch]
|
| 8863 |
+
//! author : sschueller : https://github.com/sschueller
|
| 8864 |
|
| 8865 |
;(function (global, factory) {
|
| 8866 |
+
true ? factory(__webpack_require__(297)) :
|
| 8867 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8868 |
factory(global.moment)
|
| 8869 |
}(this, (function (moment) { 'use strict';
|
| 8870 |
|
| 8871 |
|
| 8872 |
+
// based on: https://www.bk.admin.ch/dokumentation/sprachen/04915/05016/index.html?lang=de#
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8873 |
|
| 8874 |
+
function processRelativeTime(number, withoutSuffix, key, isFuture) {
|
| 8875 |
+
var format = {
|
| 8876 |
+
'm': ['eine Minute', 'einer Minute'],
|
| 8877 |
+
'h': ['eine Stunde', 'einer Stunde'],
|
| 8878 |
+
'd': ['ein Tag', 'einem Tag'],
|
| 8879 |
+
'dd': [number + ' Tage', number + ' Tagen'],
|
| 8880 |
+
'M': ['ein Monat', 'einem Monat'],
|
| 8881 |
+
'MM': [number + ' Monate', number + ' Monaten'],
|
| 8882 |
+
'y': ['ein Jahr', 'einem Jahr'],
|
| 8883 |
+
'yy': [number + ' Jahre', number + ' Jahren']
|
| 8884 |
+
};
|
| 8885 |
+
return withoutSuffix ? format[key][0] : format[key][1];
|
| 8886 |
+
}
|
| 8887 |
|
| 8888 |
+
var deCh = moment.defineLocale('de-ch', {
|
| 8889 |
+
months : 'Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember'.split('_'),
|
| 8890 |
+
monthsShort : 'Jan._Febr._März_April_Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.'.split('_'),
|
| 8891 |
+
monthsParseExact : true,
|
| 8892 |
+
weekdays : 'Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag'.split('_'),
|
| 8893 |
+
weekdaysShort : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
|
| 8894 |
+
weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
|
| 8895 |
+
weekdaysParseExact : true,
|
| 8896 |
+
longDateFormat : {
|
| 8897 |
+
LT: 'HH.mm',
|
| 8898 |
+
LTS: 'HH.mm.ss',
|
| 8899 |
+
L : 'DD.MM.YYYY',
|
| 8900 |
+
LL : 'D. MMMM YYYY',
|
| 8901 |
+
LLL : 'D. MMMM YYYY HH.mm',
|
| 8902 |
+
LLLL : 'dddd, D. MMMM YYYY HH.mm'
|
| 8903 |
+
},
|
| 8904 |
+
calendar : {
|
| 8905 |
+
sameDay: '[heute um] LT [Uhr]',
|
| 8906 |
+
sameElse: 'L',
|
| 8907 |
+
nextDay: '[morgen um] LT [Uhr]',
|
| 8908 |
+
nextWeek: 'dddd [um] LT [Uhr]',
|
| 8909 |
+
lastDay: '[gestern um] LT [Uhr]',
|
| 8910 |
+
lastWeek: '[letzten] dddd [um] LT [Uhr]'
|
| 8911 |
+
},
|
| 8912 |
+
relativeTime : {
|
| 8913 |
+
future : 'in %s',
|
| 8914 |
+
past : 'vor %s',
|
| 8915 |
+
s : 'ein paar Sekunden',
|
| 8916 |
+
m : processRelativeTime,
|
| 8917 |
+
mm : '%d Minuten',
|
| 8918 |
+
h : processRelativeTime,
|
| 8919 |
+
hh : '%d Stunden',
|
| 8920 |
+
d : processRelativeTime,
|
| 8921 |
+
dd : processRelativeTime,
|
| 8922 |
+
M : processRelativeTime,
|
| 8923 |
+
MM : processRelativeTime,
|
| 8924 |
+
y : processRelativeTime,
|
| 8925 |
+
yy : processRelativeTime
|
| 8926 |
+
},
|
| 8927 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 8928 |
+
ordinal : '%d.',
|
| 8929 |
+
week : {
|
| 8930 |
+
dow : 1, // Monday is the first day of the week.
|
| 8931 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 8932 |
+
}
|
| 8933 |
+
});
|
| 8934 |
+
|
| 8935 |
+
return deCh;
|
| 8936 |
+
|
| 8937 |
+
})));
|
| 8938 |
+
|
| 8939 |
+
|
| 8940 |
+
/***/ },
|
| 8941 |
+
/* 323 */
|
| 8942 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 8943 |
+
|
| 8944 |
+
//! moment.js locale configuration
|
| 8945 |
+
//! locale : Maldivian [dv]
|
| 8946 |
+
//! author : Jawish Hameed : https://github.com/jawish
|
| 8947 |
+
|
| 8948 |
+
;(function (global, factory) {
|
| 8949 |
+
true ? factory(__webpack_require__(297)) :
|
| 8950 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 8951 |
+
factory(global.moment)
|
| 8952 |
+
}(this, (function (moment) { 'use strict';
|
| 8953 |
+
|
| 8954 |
+
|
| 8955 |
+
var months = [
|
| 8956 |
+
'ޖެނުއަރީ',
|
| 8957 |
+
'ފެބްރުއަރީ',
|
| 8958 |
+
'މާރިޗު',
|
| 8959 |
+
'އޭޕްރީލު',
|
| 8960 |
+
'މޭ',
|
| 8961 |
+
'ޖޫން',
|
| 8962 |
+
'ޖުލައި',
|
| 8963 |
+
'އޯގަސްޓު',
|
| 8964 |
+
'ސެޕްޓެމްބަރު',
|
| 8965 |
+
'އޮކްޓޯބަރު',
|
| 8966 |
+
'ނޮވެމްބަރު',
|
| 8967 |
+
'ޑިސެމްބަރު'
|
| 8968 |
+
];
|
| 8969 |
+
var weekdays = [
|
| 8970 |
+
'އާދިއްތަ',
|
| 8971 |
+
'ހޯމަ',
|
| 8972 |
+
'އަންގާރަ',
|
| 8973 |
+
'ބުދަ',
|
| 8974 |
+
'ބުރާސްފަތި',
|
| 8975 |
+
'ހުކުރު',
|
| 8976 |
+
'ހޮނިހިރު'
|
| 8977 |
+
];
|
| 8978 |
+
|
| 8979 |
+
var dv = moment.defineLocale('dv', {
|
| 8980 |
+
months : months,
|
| 8981 |
+
monthsShort : months,
|
| 8982 |
+
weekdays : weekdays,
|
| 8983 |
+
weekdaysShort : weekdays,
|
| 8984 |
+
weekdaysMin : 'އާދި_ހޯމަ_އަން_ބުދަ_ބުރާ_ހުކު_ހޮނި'.split('_'),
|
| 8985 |
+
longDateFormat : {
|
| 8986 |
+
|
| 8987 |
+
LT : 'HH:mm',
|
| 8988 |
+
LTS : 'HH:mm:ss',
|
| 8989 |
+
L : 'D/M/YYYY',
|
| 8990 |
+
LL : 'D MMMM YYYY',
|
| 8991 |
+
LLL : 'D MMMM YYYY HH:mm',
|
| 8992 |
+
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 8993 |
+
},
|
| 8994 |
+
meridiemParse: /މކ|މފ/,
|
| 8995 |
+
isPM : function (input) {
|
| 8996 |
return 'މފ' === input;
|
| 8997 |
},
|
| 8998 |
meridiem : function (hour, minute, isLower) {
|
| 9043 |
|
| 9044 |
|
| 9045 |
/***/ },
|
| 9046 |
+
/* 324 */
|
| 9047 |
/***/ function(module, exports, __webpack_require__) {
|
| 9048 |
|
| 9049 |
//! moment.js locale configuration
|
| 9051 |
//! author : Aggelos Karalias : https://github.com/mehiel
|
| 9052 |
|
| 9053 |
;(function (global, factory) {
|
| 9054 |
+
true ? factory(__webpack_require__(297)) :
|
| 9055 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9056 |
factory(global.moment)
|
| 9057 |
}(this, (function (moment) { 'use strict';
|
| 9065 |
monthsNominativeEl : 'Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος'.split('_'),
|
| 9066 |
monthsGenitiveEl : 'Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου'.split('_'),
|
| 9067 |
months : function (momentToFormat, format) {
|
| 9068 |
+
if (!momentToFormat) {
|
| 9069 |
+
return this._monthsNominativeEl;
|
| 9070 |
+
} else if (/D/.test(format.substring(0, format.indexOf('MMMM')))) { // if there is a day number before 'MMMM'
|
| 9071 |
return this._monthsGenitiveEl[momentToFormat.month()];
|
| 9072 |
} else {
|
| 9073 |
return this._monthsNominativeEl[momentToFormat.month()];
|
| 9134 |
y : 'ένας χρόνος',
|
| 9135 |
yy : '%d χρόνια'
|
| 9136 |
},
|
| 9137 |
+
dayOfMonthOrdinalParse: /\d{1,2}η/,
|
| 9138 |
ordinal: '%dη',
|
| 9139 |
week : {
|
| 9140 |
dow : 1, // Monday is the first day of the week.
|
| 9148 |
|
| 9149 |
|
| 9150 |
/***/ },
|
| 9151 |
+
/* 325 */
|
| 9152 |
/***/ function(module, exports, __webpack_require__) {
|
| 9153 |
|
| 9154 |
//! moment.js locale configuration
|
| 9156 |
//! author : Jared Morse : https://github.com/jarcoal
|
| 9157 |
|
| 9158 |
;(function (global, factory) {
|
| 9159 |
+
true ? factory(__webpack_require__(297)) :
|
| 9160 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9161 |
factory(global.moment)
|
| 9162 |
}(this, (function (moment) { 'use strict';
|
| 9199 |
y : 'a year',
|
| 9200 |
yy : '%d years'
|
| 9201 |
},
|
| 9202 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 9203 |
ordinal : function (number) {
|
| 9204 |
var b = number % 10,
|
| 9205 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 9220 |
|
| 9221 |
|
| 9222 |
/***/ },
|
| 9223 |
+
/* 326 */
|
| 9224 |
/***/ function(module, exports, __webpack_require__) {
|
| 9225 |
|
| 9226 |
//! moment.js locale configuration
|
| 9228 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 9229 |
|
| 9230 |
;(function (global, factory) {
|
| 9231 |
+
true ? factory(__webpack_require__(297)) :
|
| 9232 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9233 |
factory(global.moment)
|
| 9234 |
}(this, (function (moment) { 'use strict';
|
| 9271 |
y : 'a year',
|
| 9272 |
yy : '%d years'
|
| 9273 |
},
|
| 9274 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 9275 |
ordinal : function (number) {
|
| 9276 |
var b = number % 10,
|
| 9277 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 9288 |
|
| 9289 |
|
| 9290 |
/***/ },
|
| 9291 |
+
/* 327 */
|
| 9292 |
/***/ function(module, exports, __webpack_require__) {
|
| 9293 |
|
| 9294 |
//! moment.js locale configuration
|
| 9296 |
//! author : Chris Gedrim : https://github.com/chrisgedrim
|
| 9297 |
|
| 9298 |
;(function (global, factory) {
|
| 9299 |
+
true ? factory(__webpack_require__(297)) :
|
| 9300 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9301 |
factory(global.moment)
|
| 9302 |
}(this, (function (moment) { 'use strict';
|
| 9339 |
y : 'a year',
|
| 9340 |
yy : '%d years'
|
| 9341 |
},
|
| 9342 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 9343 |
ordinal : function (number) {
|
| 9344 |
var b = number % 10,
|
| 9345 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 9360 |
|
| 9361 |
|
| 9362 |
/***/ },
|
| 9363 |
+
/* 328 */
|
| 9364 |
/***/ function(module, exports, __webpack_require__) {
|
| 9365 |
|
| 9366 |
//! moment.js locale configuration
|
| 9368 |
//! author : Chris Cartlidge : https://github.com/chriscartlidge
|
| 9369 |
|
| 9370 |
;(function (global, factory) {
|
| 9371 |
+
true ? factory(__webpack_require__(297)) :
|
| 9372 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9373 |
factory(global.moment)
|
| 9374 |
}(this, (function (moment) { 'use strict';
|
| 9411 |
y : 'a year',
|
| 9412 |
yy : '%d years'
|
| 9413 |
},
|
| 9414 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 9415 |
ordinal : function (number) {
|
| 9416 |
var b = number % 10,
|
| 9417 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 9432 |
|
| 9433 |
|
| 9434 |
/***/ },
|
| 9435 |
+
/* 329 */
|
| 9436 |
/***/ function(module, exports, __webpack_require__) {
|
| 9437 |
|
| 9438 |
//! moment.js locale configuration
|
| 9440 |
//! author : Luke McGregor : https://github.com/lukemcgregor
|
| 9441 |
|
| 9442 |
;(function (global, factory) {
|
| 9443 |
+
true ? factory(__webpack_require__(297)) :
|
| 9444 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9445 |
factory(global.moment)
|
| 9446 |
}(this, (function (moment) { 'use strict';
|
| 9483 |
y : 'a year',
|
| 9484 |
yy : '%d years'
|
| 9485 |
},
|
| 9486 |
+
dayOfMonthOrdinalParse: /\d{1,2}(st|nd|rd|th)/,
|
| 9487 |
ordinal : function (number) {
|
| 9488 |
var b = number % 10,
|
| 9489 |
output = (~~(number % 100 / 10) === 1) ? 'th' :
|
| 9504 |
|
| 9505 |
|
| 9506 |
/***/ },
|
| 9507 |
+
/* 330 */
|
| 9508 |
/***/ function(module, exports, __webpack_require__) {
|
| 9509 |
|
| 9510 |
//! moment.js locale configuration
|
| 9511 |
//! locale : Esperanto [eo]
|
| 9512 |
//! author : Colin Dean : https://github.com/colindean
|
| 9513 |
+
//! author : Mia Nordentoft Imperatori : https://github.com/miestasmia
|
| 9514 |
+
//! comment : miestasmia corrected the translation by colindean
|
| 9515 |
|
| 9516 |
;(function (global, factory) {
|
| 9517 |
+
true ? factory(__webpack_require__(297)) :
|
| 9518 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9519 |
factory(global.moment)
|
| 9520 |
}(this, (function (moment) { 'use strict';
|
| 9523 |
var eo = moment.defineLocale('eo', {
|
| 9524 |
months : 'januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro'.split('_'),
|
| 9525 |
monthsShort : 'jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec'.split('_'),
|
| 9526 |
+
weekdays : 'dimanĉo_lundo_mardo_merkredo_ĵaŭdo_vendredo_sabato'.split('_'),
|
| 9527 |
+
weekdaysShort : 'dim_lun_mard_merk_ĵaŭ_ven_sab'.split('_'),
|
| 9528 |
+
weekdaysMin : 'di_lu_ma_me_ĵa_ve_sa'.split('_'),
|
| 9529 |
longDateFormat : {
|
| 9530 |
LT : 'HH:mm',
|
| 9531 |
LTS : 'HH:mm:ss',
|
| 9532 |
L : 'YYYY-MM-DD',
|
| 9533 |
+
LL : 'D[-a de] MMMM, YYYY',
|
| 9534 |
+
LLL : 'D[-a de] MMMM, YYYY HH:mm',
|
| 9535 |
+
LLLL : 'dddd, [la] D[-a de] MMMM, YYYY HH:mm'
|
| 9536 |
},
|
| 9537 |
meridiemParse: /[ap]\.t\.m/i,
|
| 9538 |
isPM: function (input) {
|
| 9554 |
sameElse : 'L'
|
| 9555 |
},
|
| 9556 |
relativeTime : {
|
| 9557 |
+
future : 'post %s',
|
| 9558 |
past : 'antaŭ %s',
|
| 9559 |
s : 'sekundoj',
|
| 9560 |
m : 'minuto',
|
| 9568 |
y : 'jaro',
|
| 9569 |
yy : '%d jaroj'
|
| 9570 |
},
|
| 9571 |
+
dayOfMonthOrdinalParse: /\d{1,2}a/,
|
| 9572 |
ordinal : '%da',
|
| 9573 |
week : {
|
| 9574 |
dow : 1, // Monday is the first day of the week.
|
| 9582 |
|
| 9583 |
|
| 9584 |
/***/ },
|
| 9585 |
+
/* 331 */
|
| 9586 |
/***/ function(module, exports, __webpack_require__) {
|
| 9587 |
|
| 9588 |
//! moment.js locale configuration
|
| 9590 |
//! author : Julio Napurí : https://github.com/julionc
|
| 9591 |
|
| 9592 |
;(function (global, factory) {
|
| 9593 |
+
true ? factory(__webpack_require__(297)) :
|
| 9594 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9595 |
factory(global.moment)
|
| 9596 |
}(this, (function (moment) { 'use strict';
|
| 9602 |
var es = moment.defineLocale('es', {
|
| 9603 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 9604 |
monthsShort : function (m, format) {
|
| 9605 |
+
if (!m) {
|
| 9606 |
+
return monthsShortDot;
|
| 9607 |
+
} else if (/-MMM-/.test(format)) {
|
| 9608 |
return monthsShort[m.month()];
|
| 9609 |
} else {
|
| 9610 |
return monthsShortDot[m.month()];
|
| 9656 |
y : 'un año',
|
| 9657 |
yy : '%d años'
|
| 9658 |
},
|
| 9659 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 9660 |
ordinal : '%dº',
|
| 9661 |
week : {
|
| 9662 |
dow : 1, // Monday is the first day of the week.
|
| 9670 |
|
| 9671 |
|
| 9672 |
/***/ },
|
| 9673 |
+
/* 332 */
|
| 9674 |
/***/ function(module, exports, __webpack_require__) {
|
| 9675 |
|
| 9676 |
//! moment.js locale configuration
|
| 9677 |
//! locale : Spanish (Dominican Republic) [es-do]
|
| 9678 |
|
| 9679 |
;(function (global, factory) {
|
| 9680 |
+
true ? factory(__webpack_require__(297)) :
|
| 9681 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9682 |
factory(global.moment)
|
| 9683 |
}(this, (function (moment) { 'use strict';
|
| 9689 |
var esDo = moment.defineLocale('es-do', {
|
| 9690 |
months : 'enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre'.split('_'),
|
| 9691 |
monthsShort : function (m, format) {
|
| 9692 |
+
if (!m) {
|
| 9693 |
+
return monthsShortDot;
|
| 9694 |
+
} else if (/-MMM-/.test(format)) {
|
| 9695 |
return monthsShort[m.month()];
|
| 9696 |
} else {
|
| 9697 |
return monthsShortDot[m.month()];
|
| 9743 |
y : 'un año',
|
| 9744 |
yy : '%d años'
|
| 9745 |
},
|
| 9746 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 9747 |
ordinal : '%dº',
|
| 9748 |
week : {
|
| 9749 |
dow : 1, // Monday is the first day of the week.
|
| 9757 |
|
| 9758 |
|
| 9759 |
/***/ },
|
| 9760 |
+
/* 333 */
|
| 9761 |
/***/ function(module, exports, __webpack_require__) {
|
| 9762 |
|
| 9763 |
//! moment.js locale configuration
|
| 9766 |
//! improvements : Illimar Tambek : https://github.com/ragulka
|
| 9767 |
|
| 9768 |
;(function (global, factory) {
|
| 9769 |
+
true ? factory(__webpack_require__(297)) :
|
| 9770 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9771 |
factory(global.moment)
|
| 9772 |
}(this, (function (moment) { 'use strict';
|
| 9828 |
y : processRelativeTime,
|
| 9829 |
yy : processRelativeTime
|
| 9830 |
},
|
| 9831 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 9832 |
ordinal : '%d.',
|
| 9833 |
week : {
|
| 9834 |
dow : 1, // Monday is the first day of the week.
|
| 9842 |
|
| 9843 |
|
| 9844 |
/***/ },
|
| 9845 |
+
/* 334 */
|
| 9846 |
/***/ function(module, exports, __webpack_require__) {
|
| 9847 |
|
| 9848 |
//! moment.js locale configuration
|
| 9850 |
//! author : Eneko Illarramendi : https://github.com/eillarra
|
| 9851 |
|
| 9852 |
;(function (global, factory) {
|
| 9853 |
+
true ? factory(__webpack_require__(297)) :
|
| 9854 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9855 |
factory(global.moment)
|
| 9856 |
}(this, (function (moment) { 'use strict';
|
| 9899 |
y : 'urte bat',
|
| 9900 |
yy : '%d urte'
|
| 9901 |
},
|
| 9902 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 9903 |
ordinal : '%d.',
|
| 9904 |
week : {
|
| 9905 |
dow : 1, // Monday is the first day of the week.
|
| 9913 |
|
| 9914 |
|
| 9915 |
/***/ },
|
| 9916 |
+
/* 335 */
|
| 9917 |
/***/ function(module, exports, __webpack_require__) {
|
| 9918 |
|
| 9919 |
//! moment.js locale configuration
|
| 9921 |
//! author : Ebrahim Byagowi : https://github.com/ebraminio
|
| 9922 |
|
| 9923 |
;(function (global, factory) {
|
| 9924 |
+
true ? factory(__webpack_require__(297)) :
|
| 9925 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 9926 |
factory(global.moment)
|
| 9927 |
}(this, (function (moment) { 'use strict';
|
| 9989 |
relativeTime : {
|
| 9990 |
future : 'در %s',
|
| 9991 |
past : '%s پیش',
|
| 9992 |
+
s : 'چند ثانیه',
|
| 9993 |
m : 'یک دقیقه',
|
| 9994 |
mm : '%d دقیقه',
|
| 9995 |
h : 'یک ساعت',
|
| 10011 |
return symbolMap[match];
|
| 10012 |
}).replace(/,/g, '،');
|
| 10013 |
},
|
| 10014 |
+
dayOfMonthOrdinalParse: /\d{1,2}م/,
|
| 10015 |
ordinal : '%dم',
|
| 10016 |
week : {
|
| 10017 |
dow : 6, // Saturday is the first day of the week.
|
| 10025 |
|
| 10026 |
|
| 10027 |
/***/ },
|
| 10028 |
+
/* 336 */
|
| 10029 |
/***/ function(module, exports, __webpack_require__) {
|
| 10030 |
|
| 10031 |
//! moment.js locale configuration
|
| 10033 |
//! author : Tarmo Aidantausta : https://github.com/bleadof
|
| 10034 |
|
| 10035 |
;(function (global, factory) {
|
| 10036 |
+
true ? factory(__webpack_require__(297)) :
|
| 10037 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10038 |
factory(global.moment)
|
| 10039 |
}(this, (function (moment) { 'use strict';
|
| 10123 |
y : translate,
|
| 10124 |
yy : translate
|
| 10125 |
},
|
| 10126 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 10127 |
ordinal : '%d.',
|
| 10128 |
week : {
|
| 10129 |
dow : 1, // Monday is the first day of the week.
|
| 10137 |
|
| 10138 |
|
| 10139 |
/***/ },
|
| 10140 |
+
/* 337 */
|
| 10141 |
/***/ function(module, exports, __webpack_require__) {
|
| 10142 |
|
| 10143 |
//! moment.js locale configuration
|
| 10145 |
//! author : Ragnar Johannesen : https://github.com/ragnar123
|
| 10146 |
|
| 10147 |
;(function (global, factory) {
|
| 10148 |
+
true ? factory(__webpack_require__(297)) :
|
| 10149 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10150 |
factory(global.moment)
|
| 10151 |
}(this, (function (moment) { 'use strict';
|
| 10188 |
y : 'eitt ár',
|
| 10189 |
yy : '%d ár'
|
| 10190 |
},
|
| 10191 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 10192 |
ordinal : '%d.',
|
| 10193 |
week : {
|
| 10194 |
dow : 1, // Monday is the first day of the week.
|
| 10202 |
|
| 10203 |
|
| 10204 |
/***/ },
|
| 10205 |
+
/* 338 */
|
| 10206 |
/***/ function(module, exports, __webpack_require__) {
|
| 10207 |
|
| 10208 |
//! moment.js locale configuration
|
| 10210 |
//! author : John Fischer : https://github.com/jfroffice
|
| 10211 |
|
| 10212 |
;(function (global, factory) {
|
| 10213 |
+
true ? factory(__webpack_require__(297)) :
|
| 10214 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10215 |
factory(global.moment)
|
| 10216 |
}(this, (function (moment) { 'use strict';
|
| 10233 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 10234 |
},
|
| 10235 |
calendar : {
|
| 10236 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 10237 |
+
nextDay : '[Demain à] LT',
|
| 10238 |
+
nextWeek : 'dddd [à] LT',
|
| 10239 |
+
lastDay : '[Hier à] LT',
|
| 10240 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 10241 |
+
sameElse : 'L'
|
| 10242 |
},
|
| 10243 |
relativeTime : {
|
| 10244 |
future : 'dans %s',
|
| 10255 |
y : 'un an',
|
| 10256 |
yy : '%d ans'
|
| 10257 |
},
|
| 10258 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|)/,
|
| 10259 |
+
ordinal : function (number, period) {
|
| 10260 |
+
switch (period) {
|
| 10261 |
+
// TODO: Return 'e' when day of month > 1. Move this case inside
|
| 10262 |
+
// block for masculine words below.
|
| 10263 |
+
// See https://github.com/moment/moment/issues/3375
|
| 10264 |
+
case 'D':
|
| 10265 |
+
return number + (number === 1 ? 'er' : '');
|
| 10266 |
+
|
| 10267 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 10268 |
+
default:
|
| 10269 |
+
case 'M':
|
| 10270 |
+
case 'Q':
|
| 10271 |
+
case 'DDD':
|
| 10272 |
+
case 'd':
|
| 10273 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 10274 |
+
|
| 10275 |
+
// Words with feminine grammatical gender: semaine
|
| 10276 |
+
case 'w':
|
| 10277 |
+
case 'W':
|
| 10278 |
+
return number + (number === 1 ? 're' : 'e');
|
| 10279 |
+
}
|
| 10280 |
},
|
| 10281 |
week : {
|
| 10282 |
dow : 1, // Monday is the first day of the week.
|
| 10290 |
|
| 10291 |
|
| 10292 |
/***/ },
|
| 10293 |
+
/* 339 */
|
| 10294 |
/***/ function(module, exports, __webpack_require__) {
|
| 10295 |
|
| 10296 |
//! moment.js locale configuration
|
| 10298 |
//! author : Jonathan Abourbih : https://github.com/jonbca
|
| 10299 |
|
| 10300 |
;(function (global, factory) {
|
| 10301 |
+
true ? factory(__webpack_require__(297)) :
|
| 10302 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10303 |
factory(global.moment)
|
| 10304 |
}(this, (function (moment) { 'use strict';
|
| 10321 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 10322 |
},
|
| 10323 |
calendar : {
|
| 10324 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 10325 |
+
nextDay : '[Demain à] LT',
|
| 10326 |
+
nextWeek : 'dddd [à] LT',
|
| 10327 |
+
lastDay : '[Hier à] LT',
|
| 10328 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 10329 |
+
sameElse : 'L'
|
| 10330 |
},
|
| 10331 |
relativeTime : {
|
| 10332 |
future : 'dans %s',
|
| 10343 |
y : 'un an',
|
| 10344 |
yy : '%d ans'
|
| 10345 |
},
|
| 10346 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|e)/,
|
| 10347 |
+
ordinal : function (number, period) {
|
| 10348 |
+
switch (period) {
|
| 10349 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 10350 |
+
default:
|
| 10351 |
+
case 'M':
|
| 10352 |
+
case 'Q':
|
| 10353 |
+
case 'D':
|
| 10354 |
+
case 'DDD':
|
| 10355 |
+
case 'd':
|
| 10356 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 10357 |
+
|
| 10358 |
+
// Words with feminine grammatical gender: semaine
|
| 10359 |
+
case 'w':
|
| 10360 |
+
case 'W':
|
| 10361 |
+
return number + (number === 1 ? 're' : 'e');
|
| 10362 |
+
}
|
| 10363 |
}
|
| 10364 |
});
|
| 10365 |
|
| 10369 |
|
| 10370 |
|
| 10371 |
/***/ },
|
| 10372 |
+
/* 340 */
|
| 10373 |
/***/ function(module, exports, __webpack_require__) {
|
| 10374 |
|
| 10375 |
//! moment.js locale configuration
|
| 10377 |
//! author : Gaspard Bucher : https://github.com/gaspard
|
| 10378 |
|
| 10379 |
;(function (global, factory) {
|
| 10380 |
+
true ? factory(__webpack_require__(297)) :
|
| 10381 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10382 |
factory(global.moment)
|
| 10383 |
}(this, (function (moment) { 'use strict';
|
| 10400 |
LLLL : 'dddd D MMMM YYYY HH:mm'
|
| 10401 |
},
|
| 10402 |
calendar : {
|
| 10403 |
+
sameDay : '[Aujourd’hui à] LT',
|
| 10404 |
+
nextDay : '[Demain à] LT',
|
| 10405 |
+
nextWeek : 'dddd [à] LT',
|
| 10406 |
+
lastDay : '[Hier à] LT',
|
| 10407 |
+
lastWeek : 'dddd [dernier à] LT',
|
| 10408 |
+
sameElse : 'L'
|
| 10409 |
},
|
| 10410 |
relativeTime : {
|
| 10411 |
future : 'dans %s',
|
| 10422 |
y : 'un an',
|
| 10423 |
yy : '%d ans'
|
| 10424 |
},
|
| 10425 |
+
dayOfMonthOrdinalParse: /\d{1,2}(er|e)/,
|
| 10426 |
+
ordinal : function (number, period) {
|
| 10427 |
+
switch (period) {
|
| 10428 |
+
// Words with masculine grammatical gender: mois, trimestre, jour
|
| 10429 |
+
default:
|
| 10430 |
+
case 'M':
|
| 10431 |
+
case 'Q':
|
| 10432 |
+
case 'D':
|
| 10433 |
+
case 'DDD':
|
| 10434 |
+
case 'd':
|
| 10435 |
+
return number + (number === 1 ? 'er' : 'e');
|
| 10436 |
+
|
| 10437 |
+
// Words with feminine grammatical gender: semaine
|
| 10438 |
+
case 'w':
|
| 10439 |
+
case 'W':
|
| 10440 |
+
return number + (number === 1 ? 're' : 'e');
|
| 10441 |
+
}
|
| 10442 |
},
|
| 10443 |
week : {
|
| 10444 |
dow : 1, // Monday is the first day of the week.
|
| 10452 |
|
| 10453 |
|
| 10454 |
/***/ },
|
| 10455 |
+
/* 341 */
|
| 10456 |
/***/ function(module, exports, __webpack_require__) {
|
| 10457 |
|
| 10458 |
//! moment.js locale configuration
|
| 10460 |
//! author : Robin van der Vliet : https://github.com/robin0van0der0v
|
| 10461 |
|
| 10462 |
;(function (global, factory) {
|
| 10463 |
+
true ? factory(__webpack_require__(297)) :
|
| 10464 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10465 |
factory(global.moment)
|
| 10466 |
}(this, (function (moment) { 'use strict';
|
| 10472 |
var fy = moment.defineLocale('fy', {
|
| 10473 |
months : 'jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber'.split('_'),
|
| 10474 |
monthsShort : function (m, format) {
|
| 10475 |
+
if (!m) {
|
| 10476 |
+
return monthsShortWithDots;
|
| 10477 |
+
} else if (/-MMM-/.test(format)) {
|
| 10478 |
return monthsShortWithoutDots[m.month()];
|
| 10479 |
} else {
|
| 10480 |
return monthsShortWithDots[m.month()];
|
| 10516 |
y : 'ien jier',
|
| 10517 |
yy : '%d jierren'
|
| 10518 |
},
|
| 10519 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
| 10520 |
ordinal : function (number) {
|
| 10521 |
return number + ((number === 1 || number === 8 || number >= 20) ? 'ste' : 'de');
|
| 10522 |
},
|
| 10532 |
|
| 10533 |
|
| 10534 |
/***/ },
|
| 10535 |
+
/* 342 */
|
| 10536 |
/***/ function(module, exports, __webpack_require__) {
|
| 10537 |
|
| 10538 |
//! moment.js locale configuration
|
| 10540 |
//! author : Jon Ashdown : https://github.com/jonashdown
|
| 10541 |
|
| 10542 |
;(function (global, factory) {
|
| 10543 |
+
true ? factory(__webpack_require__(297)) :
|
| 10544 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10545 |
factory(global.moment)
|
| 10546 |
}(this, (function (moment) { 'use strict';
|
| 10596 |
y : 'bliadhna',
|
| 10597 |
yy : '%d bliadhna'
|
| 10598 |
},
|
| 10599 |
+
dayOfMonthOrdinalParse : /\d{1,2}(d|na|mh)/,
|
| 10600 |
ordinal : function (number) {
|
| 10601 |
var output = number === 1 ? 'd' : number % 10 === 2 ? 'na' : 'mh';
|
| 10602 |
return number + output;
|
| 10613 |
|
| 10614 |
|
| 10615 |
/***/ },
|
| 10616 |
+
/* 343 */
|
| 10617 |
/***/ function(module, exports, __webpack_require__) {
|
| 10618 |
|
| 10619 |
//! moment.js locale configuration
|
| 10621 |
//! author : Juan G. Hurtado : https://github.com/juanghurtado
|
| 10622 |
|
| 10623 |
;(function (global, factory) {
|
| 10624 |
+
true ? factory(__webpack_require__(297)) :
|
| 10625 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10626 |
factory(global.moment)
|
| 10627 |
}(this, (function (moment) { 'use strict';
|
| 10681 |
y : 'un ano',
|
| 10682 |
yy : '%d anos'
|
| 10683 |
},
|
| 10684 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 10685 |
ordinal : '%dº',
|
| 10686 |
week : {
|
| 10687 |
dow : 1, // Monday is the first day of the week.
|
| 10695 |
|
| 10696 |
|
| 10697 |
/***/ },
|
| 10698 |
+
/* 344 */
|
| 10699 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 10700 |
+
|
| 10701 |
+
//! moment.js locale configuration
|
| 10702 |
+
//! locale : Konkani Latin script [gom-latn]
|
| 10703 |
+
//! author : The Discoverer : https://github.com/WikiDiscoverer
|
| 10704 |
+
|
| 10705 |
+
;(function (global, factory) {
|
| 10706 |
+
true ? factory(__webpack_require__(297)) :
|
| 10707 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10708 |
+
factory(global.moment)
|
| 10709 |
+
}(this, (function (moment) { 'use strict';
|
| 10710 |
+
|
| 10711 |
+
|
| 10712 |
+
function processRelativeTime(number, withoutSuffix, key, isFuture) {
|
| 10713 |
+
var format = {
|
| 10714 |
+
's': ['thodde secondanim', 'thodde second'],
|
| 10715 |
+
'm': ['eka mintan', 'ek minute'],
|
| 10716 |
+
'mm': [number + ' mintanim', number + ' mintam'],
|
| 10717 |
+
'h': ['eka horan', 'ek hor'],
|
| 10718 |
+
'hh': [number + ' horanim', number + ' hor'],
|
| 10719 |
+
'd': ['eka disan', 'ek dis'],
|
| 10720 |
+
'dd': [number + ' disanim', number + ' dis'],
|
| 10721 |
+
'M': ['eka mhoinean', 'ek mhoino'],
|
| 10722 |
+
'MM': [number + ' mhoineanim', number + ' mhoine'],
|
| 10723 |
+
'y': ['eka vorsan', 'ek voros'],
|
| 10724 |
+
'yy': [number + ' vorsanim', number + ' vorsam']
|
| 10725 |
+
};
|
| 10726 |
+
return withoutSuffix ? format[key][0] : format[key][1];
|
| 10727 |
+
}
|
| 10728 |
+
|
| 10729 |
+
var gomLatn = moment.defineLocale('gom-latn', {
|
| 10730 |
+
months : 'Janer_Febrer_Mars_Abril_Mai_Jun_Julai_Agost_Setembr_Otubr_Novembr_Dezembr'.split('_'),
|
| 10731 |
+
monthsShort : 'Jan._Feb._Mars_Abr._Mai_Jun_Jul._Ago._Set._Otu._Nov._Dez.'.split('_'),
|
| 10732 |
+
monthsParseExact : true,
|
| 10733 |
+
weekdays : 'Aitar_Somar_Mongllar_Budvar_Brestar_Sukrar_Son\'var'.split('_'),
|
| 10734 |
+
weekdaysShort : 'Ait._Som._Mon._Bud._Bre._Suk._Son.'.split('_'),
|
| 10735 |
+
weekdaysMin : 'Ai_Sm_Mo_Bu_Br_Su_Sn'.split('_'),
|
| 10736 |
+
weekdaysParseExact : true,
|
| 10737 |
+
longDateFormat : {
|
| 10738 |
+
LT : 'A h:mm [vazta]',
|
| 10739 |
+
LTS : 'A h:mm:ss [vazta]',
|
| 10740 |
+
L : 'DD-MM-YYYY',
|
| 10741 |
+
LL : 'D MMMM YYYY',
|
| 10742 |
+
LLL : 'D MMMM YYYY A h:mm [vazta]',
|
| 10743 |
+
LLLL : 'dddd, MMMM[achea] Do, YYYY, A h:mm [vazta]',
|
| 10744 |
+
llll: 'ddd, D MMM YYYY, A h:mm [vazta]'
|
| 10745 |
+
},
|
| 10746 |
+
calendar : {
|
| 10747 |
+
sameDay: '[Aiz] LT',
|
| 10748 |
+
nextDay: '[Faleam] LT',
|
| 10749 |
+
nextWeek: '[Ieta to] dddd[,] LT',
|
| 10750 |
+
lastDay: '[Kal] LT',
|
| 10751 |
+
lastWeek: '[Fatlo] dddd[,] LT',
|
| 10752 |
+
sameElse: 'L'
|
| 10753 |
+
},
|
| 10754 |
+
relativeTime : {
|
| 10755 |
+
future : '%s',
|
| 10756 |
+
past : '%s adim',
|
| 10757 |
+
s : processRelativeTime,
|
| 10758 |
+
m : processRelativeTime,
|
| 10759 |
+
mm : processRelativeTime,
|
| 10760 |
+
h : processRelativeTime,
|
| 10761 |
+
hh : processRelativeTime,
|
| 10762 |
+
d : processRelativeTime,
|
| 10763 |
+
dd : processRelativeTime,
|
| 10764 |
+
M : processRelativeTime,
|
| 10765 |
+
MM : processRelativeTime,
|
| 10766 |
+
y : processRelativeTime,
|
| 10767 |
+
yy : processRelativeTime
|
| 10768 |
+
},
|
| 10769 |
+
dayOfMonthOrdinalParse : /\d{1,2}(er)/,
|
| 10770 |
+
ordinal : function (number, period) {
|
| 10771 |
+
switch (period) {
|
| 10772 |
+
// the ordinal 'er' only applies to day of the month
|
| 10773 |
+
case 'D':
|
| 10774 |
+
return number + 'er';
|
| 10775 |
+
default:
|
| 10776 |
+
case 'M':
|
| 10777 |
+
case 'Q':
|
| 10778 |
+
case 'DDD':
|
| 10779 |
+
case 'd':
|
| 10780 |
+
case 'w':
|
| 10781 |
+
case 'W':
|
| 10782 |
+
return number;
|
| 10783 |
+
}
|
| 10784 |
+
},
|
| 10785 |
+
week : {
|
| 10786 |
+
dow : 1, // Monday is the first day of the week.
|
| 10787 |
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
| 10788 |
+
},
|
| 10789 |
+
meridiemParse: /rati|sokalli|donparam|sanje/,
|
| 10790 |
+
meridiemHour : function (hour, meridiem) {
|
| 10791 |
+
if (hour === 12) {
|
| 10792 |
+
hour = 0;
|
| 10793 |
+
}
|
| 10794 |
+
if (meridiem === 'rati') {
|
| 10795 |
+
return hour < 4 ? hour : hour + 12;
|
| 10796 |
+
} else if (meridiem === 'sokalli') {
|
| 10797 |
+
return hour;
|
| 10798 |
+
} else if (meridiem === 'donparam') {
|
| 10799 |
+
return hour > 12 ? hour : hour + 12;
|
| 10800 |
+
} else if (meridiem === 'sanje') {
|
| 10801 |
+
return hour + 12;
|
| 10802 |
+
}
|
| 10803 |
+
},
|
| 10804 |
+
meridiem : function (hour, minute, isLower) {
|
| 10805 |
+
if (hour < 4) {
|
| 10806 |
+
return 'rati';
|
| 10807 |
+
} else if (hour < 12) {
|
| 10808 |
+
return 'sokalli';
|
| 10809 |
+
} else if (hour < 16) {
|
| 10810 |
+
return 'donparam';
|
| 10811 |
+
} else if (hour < 20) {
|
| 10812 |
+
return 'sanje';
|
| 10813 |
+
} else {
|
| 10814 |
+
return 'rati';
|
| 10815 |
+
}
|
| 10816 |
+
}
|
| 10817 |
+
});
|
| 10818 |
+
|
| 10819 |
+
return gomLatn;
|
| 10820 |
+
|
| 10821 |
+
})));
|
| 10822 |
+
|
| 10823 |
+
|
| 10824 |
+
/***/ },
|
| 10825 |
+
/* 345 */
|
| 10826 |
/***/ function(module, exports, __webpack_require__) {
|
| 10827 |
|
| 10828 |
//! moment.js locale configuration
|
| 10832 |
//! author : Tal Ater : https://github.com/TalAter
|
| 10833 |
|
| 10834 |
;(function (global, factory) {
|
| 10835 |
+
true ? factory(__webpack_require__(297)) :
|
| 10836 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10837 |
factory(global.moment)
|
| 10838 |
}(this, (function (moment) { 'use strict';
|
| 10926 |
|
| 10927 |
|
| 10928 |
/***/ },
|
| 10929 |
+
/* 346 */
|
| 10930 |
/***/ function(module, exports, __webpack_require__) {
|
| 10931 |
|
| 10932 |
//! moment.js locale configuration
|
| 10934 |
//! author : Mayank Singhal : https://github.com/mayanksinghal
|
| 10935 |
|
| 10936 |
;(function (global, factory) {
|
| 10937 |
+
true ? factory(__webpack_require__(297)) :
|
| 10938 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 10939 |
factory(global.moment)
|
| 10940 |
}(this, (function (moment) { 'use strict';
|
| 11055 |
|
| 11056 |
|
| 11057 |
/***/ },
|
| 11058 |
+
/* 347 */
|
| 11059 |
/***/ function(module, exports, __webpack_require__) {
|
| 11060 |
|
| 11061 |
//! moment.js locale configuration
|
| 11063 |
//! author : Bojan Marković : https://github.com/bmarkovic
|
| 11064 |
|
| 11065 |
;(function (global, factory) {
|
| 11066 |
+
true ? factory(__webpack_require__(297)) :
|
| 11067 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11068 |
factory(global.moment)
|
| 11069 |
}(this, (function (moment) { 'use strict';
|
| 11191 |
y : 'godinu',
|
| 11192 |
yy : translate
|
| 11193 |
},
|
| 11194 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 11195 |
ordinal : '%d.',
|
| 11196 |
week : {
|
| 11197 |
dow : 1, // Monday is the first day of the week.
|
| 11205 |
|
| 11206 |
|
| 11207 |
/***/ },
|
| 11208 |
+
/* 348 */
|
| 11209 |
/***/ function(module, exports, __webpack_require__) {
|
| 11210 |
|
| 11211 |
//! moment.js locale configuration
|
| 11213 |
//! author : Adam Brunner : https://github.com/adambrunner
|
| 11214 |
|
| 11215 |
;(function (global, factory) {
|
| 11216 |
+
true ? factory(__webpack_require__(297)) :
|
| 11217 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11218 |
factory(global.moment)
|
| 11219 |
}(this, (function (moment) { 'use strict';
|
| 11305 |
y : translate,
|
| 11306 |
yy : translate
|
| 11307 |
},
|
| 11308 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 11309 |
ordinal : '%d.',
|
| 11310 |
week : {
|
| 11311 |
dow : 1, // Monday is the first day of the week.
|
| 11319 |
|
| 11320 |
|
| 11321 |
/***/ },
|
| 11322 |
+
/* 349 */
|
| 11323 |
/***/ function(module, exports, __webpack_require__) {
|
| 11324 |
|
| 11325 |
//! moment.js locale configuration
|
| 11327 |
//! author : Armendarabyan : https://github.com/armendarabyan
|
| 11328 |
|
| 11329 |
;(function (global, factory) {
|
| 11330 |
+
true ? factory(__webpack_require__(297)) :
|
| 11331 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11332 |
factory(global.moment)
|
| 11333 |
}(this, (function (moment) { 'use strict';
|
| 11392 |
return 'երեկոյան';
|
| 11393 |
}
|
| 11394 |
},
|
| 11395 |
+
dayOfMonthOrdinalParse: /\d{1,2}|\d{1,2}-(ին|րդ)/,
|
| 11396 |
ordinal: function (number, period) {
|
| 11397 |
switch (period) {
|
| 11398 |
case 'DDD':
|
| 11419 |
|
| 11420 |
|
| 11421 |
/***/ },
|
| 11422 |
+
/* 350 */
|
| 11423 |
/***/ function(module, exports, __webpack_require__) {
|
| 11424 |
|
| 11425 |
//! moment.js locale configuration
|
| 11428 |
//! reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan
|
| 11429 |
|
| 11430 |
;(function (global, factory) {
|
| 11431 |
+
true ? factory(__webpack_require__(297)) :
|
| 11432 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11433 |
factory(global.moment)
|
| 11434 |
}(this, (function (moment) { 'use strict';
|
| 11507 |
|
| 11508 |
|
| 11509 |
/***/ },
|
| 11510 |
+
/* 351 */
|
| 11511 |
/***/ function(module, exports, __webpack_require__) {
|
| 11512 |
|
| 11513 |
//! moment.js locale configuration
|
| 11515 |
//! author : Hinrik Örn Sigurðsson : https://github.com/hinrik
|
| 11516 |
|
| 11517 |
;(function (global, factory) {
|
| 11518 |
+
true ? factory(__webpack_require__(297)) :
|
| 11519 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11520 |
factory(global.moment)
|
| 11521 |
}(this, (function (moment) { 'use strict';
|
| 11625 |
y : translate,
|
| 11626 |
yy : translate
|
| 11627 |
},
|
| 11628 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 11629 |
ordinal : '%d.',
|
| 11630 |
week : {
|
| 11631 |
dow : 1, // Monday is the first day of the week.
|
| 11639 |
|
| 11640 |
|
| 11641 |
/***/ },
|
| 11642 |
+
/* 352 */
|
| 11643 |
/***/ function(module, exports, __webpack_require__) {
|
| 11644 |
|
| 11645 |
//! moment.js locale configuration
|
| 11648 |
//! author: Mattia Larentis: https://github.com/nostalgiaz
|
| 11649 |
|
| 11650 |
;(function (global, factory) {
|
| 11651 |
+
true ? factory(__webpack_require__(297)) :
|
| 11652 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11653 |
factory(global.moment)
|
| 11654 |
}(this, (function (moment) { 'use strict';
|
| 11657 |
var it = moment.defineLocale('it', {
|
| 11658 |
months : 'gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre'.split('_'),
|
| 11659 |
monthsShort : 'gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic'.split('_'),
|
| 11660 |
+
weekdays : 'domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato'.split('_'),
|
| 11661 |
+
weekdaysShort : 'dom_lun_mar_mer_gio_ven_sab'.split('_'),
|
| 11662 |
+
weekdaysMin : 'do_lu_ma_me_gi_ve_sa'.split('_'),
|
| 11663 |
longDateFormat : {
|
| 11664 |
LT : 'HH:mm',
|
| 11665 |
LTS : 'HH:mm:ss',
|
| 11700 |
y : 'un anno',
|
| 11701 |
yy : '%d anni'
|
| 11702 |
},
|
| 11703 |
+
dayOfMonthOrdinalParse : /\d{1,2}º/,
|
| 11704 |
ordinal: '%dº',
|
| 11705 |
week : {
|
| 11706 |
dow : 1, // Monday is the first day of the week.
|
| 11714 |
|
| 11715 |
|
| 11716 |
/***/ },
|
| 11717 |
+
/* 353 */
|
| 11718 |
/***/ function(module, exports, __webpack_require__) {
|
| 11719 |
|
| 11720 |
//! moment.js locale configuration
|
| 11722 |
//! author : LI Long : https://github.com/baryon
|
| 11723 |
|
| 11724 |
;(function (global, factory) {
|
| 11725 |
+
true ? factory(__webpack_require__(297)) :
|
| 11726 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11727 |
factory(global.moment)
|
| 11728 |
}(this, (function (moment) { 'use strict';
|
| 11735 |
weekdaysShort : '日_月_火_水_木_金_土'.split('_'),
|
| 11736 |
weekdaysMin : '日_月_火_水_木_金_土'.split('_'),
|
| 11737 |
longDateFormat : {
|
| 11738 |
+
LT : 'HH:mm',
|
| 11739 |
+
LTS : 'HH:mm:ss',
|
| 11740 |
L : 'YYYY/MM/DD',
|
| 11741 |
LL : 'YYYY年M月D日',
|
| 11742 |
+
LLL : 'YYYY年M月D日 HH:mm',
|
| 11743 |
+
LLLL : 'YYYY年M月D日 HH:mm dddd',
|
| 11744 |
+
l : 'YYYY/MM/DD',
|
| 11745 |
+
ll : 'YYYY年M月D日',
|
| 11746 |
+
lll : 'YYYY年M月D日 HH:mm',
|
| 11747 |
+
llll : 'YYYY年M月D日 HH:mm dddd'
|
| 11748 |
},
|
| 11749 |
meridiemParse: /午前|午後/i,
|
| 11750 |
isPM : function (input) {
|
| 11765 |
lastWeek : '[前週]dddd LT',
|
| 11766 |
sameElse : 'L'
|
| 11767 |
},
|
| 11768 |
+
dayOfMonthOrdinalParse : /\d{1,2}日/,
|
| 11769 |
ordinal : function (number, period) {
|
| 11770 |
switch (period) {
|
| 11771 |
case 'd':
|
| 11799 |
|
| 11800 |
|
| 11801 |
/***/ },
|
| 11802 |
+
/* 354 */
|
| 11803 |
/***/ function(module, exports, __webpack_require__) {
|
| 11804 |
|
| 11805 |
//! moment.js locale configuration
|
| 11808 |
//! reference: http://jv.wikipedia.org/wiki/Basa_Jawa
|
| 11809 |
|
| 11810 |
;(function (global, factory) {
|
| 11811 |
+
true ? factory(__webpack_require__(297)) :
|
| 11812 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11813 |
factory(global.moment)
|
| 11814 |
}(this, (function (moment) { 'use strict';
|
| 11887 |
|
| 11888 |
|
| 11889 |
/***/ },
|
| 11890 |
+
/* 355 */
|
| 11891 |
/***/ function(module, exports, __webpack_require__) {
|
| 11892 |
|
| 11893 |
//! moment.js locale configuration
|
| 11895 |
//! author : Irakli Janiashvili : https://github.com/irakli-janiashvili
|
| 11896 |
|
| 11897 |
;(function (global, factory) {
|
| 11898 |
+
true ? factory(__webpack_require__(297)) :
|
| 11899 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11900 |
factory(global.moment)
|
| 11901 |
}(this, (function (moment) { 'use strict';
|
| 11938 |
},
|
| 11939 |
past : function (s) {
|
| 11940 |
if ((/(წამი|წუთი|საათი|დღე|თვე)/).test(s)) {
|
| 11941 |
+
return s.replace(/(ი|ე)$/, 'ის უკან');
|
| 11942 |
}
|
| 11943 |
if ((/წელი/).test(s)) {
|
| 11944 |
+
return s.replace(/წელი$/, 'წლის უკან');
|
| 11945 |
}
|
| 11946 |
},
|
| 11947 |
s : 'რამდენიმე წამი',
|
| 11956 |
y : 'წელი',
|
| 11957 |
yy : '%d წელი'
|
| 11958 |
},
|
| 11959 |
+
dayOfMonthOrdinalParse: /0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,
|
| 11960 |
ordinal : function (number) {
|
| 11961 |
if (number === 0) {
|
| 11962 |
return number;
|
| 11981 |
|
| 11982 |
|
| 11983 |
/***/ },
|
| 11984 |
+
/* 356 */
|
| 11985 |
/***/ function(module, exports, __webpack_require__) {
|
| 11986 |
|
| 11987 |
//! moment.js locale configuration
|
| 11989 |
//! authors : Nurlan Rakhimzhanov : https://github.com/nurlan
|
| 11990 |
|
| 11991 |
;(function (global, factory) {
|
| 11992 |
+
true ? factory(__webpack_require__(297)) :
|
| 11993 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 11994 |
factory(global.moment)
|
| 11995 |
}(this, (function (moment) { 'use strict';
|
| 12055 |
y : 'бір жыл',
|
| 12056 |
yy : '%d жыл'
|
| 12057 |
},
|
| 12058 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ші|шы)/,
|
| 12059 |
ordinal : function (number) {
|
| 12060 |
var a = number % 10,
|
| 12061 |
b = number >= 100 ? 100 : null;
|
| 12073 |
|
| 12074 |
|
| 12075 |
/***/ },
|
| 12076 |
+
/* 357 */
|
| 12077 |
/***/ function(module, exports, __webpack_require__) {
|
| 12078 |
|
| 12079 |
//! moment.js locale configuration
|
| 12081 |
//! author : Kruy Vanna : https://github.com/kruyvanna
|
| 12082 |
|
| 12083 |
;(function (global, factory) {
|
| 12084 |
+
true ? factory(__webpack_require__(297)) :
|
| 12085 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12086 |
factory(global.moment)
|
| 12087 |
}(this, (function (moment) { 'use strict';
|
| 12136 |
|
| 12137 |
|
| 12138 |
/***/ },
|
| 12139 |
+
/* 358 */
|
| 12140 |
+
/***/ function(module, exports, __webpack_require__) {
|
| 12141 |
+
|
| 12142 |
+
//! moment.js locale configuration
|
| 12143 |
+
//! locale : Kannada [kn]
|
| 12144 |
+
//! author : Rajeev Naik : https://github.com/rajeevnaikte
|
| 12145 |
+
|
| 12146 |
+
;(function (global, factory) {
|
| 12147 |
+
true ? factory(__webpack_require__(297)) :
|
| 12148 |
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12149 |
+
factory(global.moment)
|
| 12150 |
+
}(this, (function (moment) { 'use strict';
|
| 12151 |
+
|
| 12152 |
+
|
| 12153 |
+
var symbolMap = {
|
| 12154 |
+
'1': '೧',
|
| 12155 |
+
'2': '೨',
|
| 12156 |
+
'3': '೩',
|
| 12157 |
+
'4': '೪',
|
| 12158 |
+
'5': '೫',
|
| 12159 |
+
'6': '೬',
|
| 12160 |
+
'7': '೭',
|
| 12161 |
+
'8': '೮',
|
| 12162 |
+
'9': '೯',
|
| 12163 |
+
'0': '೦'
|
| 12164 |
+
};
|
| 12165 |
+
var numberMap = {
|
| 12166 |
+
'೧': '1',
|
| 12167 |
+
'೨': '2',
|
| 12168 |
+
'೩': '3',
|
| 12169 |
+
'೪': '4',
|
| 12170 |
+
'೫': '5',
|
| 12171 |
+
'೬': '6',
|
| 12172 |
+
'೭': '7',
|
| 12173 |
+
'೮': '8',
|
| 12174 |
+
'೯': '9',
|
| 12175 |
+
'೦': '0'
|
| 12176 |
+
};
|
| 12177 |
+
|
| 12178 |
+
var kn = moment.defineLocale('kn', {
|
| 12179 |
+
months : 'ಜನವರಿ_ಫೆಬ್ರವರಿ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬರ್_ಅಕ್ಟೋಬರ್_ನವೆಂಬರ್_ಡಿಸೆಂಬರ್'.split('_'),
|
| 12180 |
+
monthsShort : 'ಜನ_ಫೆಬ್ರ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬ_ಅಕ್ಟೋಬ_ನವೆಂಬ_ಡಿಸೆಂಬ'.split('_'),
|
| 12181 |
+
monthsParseExact: true,
|
| 12182 |
+
weekdays : 'ಭಾನುವಾರ_ಸೋಮವಾರ_ಮಂಗಳವಾರ_ಬುಧವಾರ_ಗುರುವಾರ_ಶುಕ್ರವಾರ_ಶನಿವಾರ'.split('_'),
|
| 12183 |
+
weekdaysShort : 'ಭಾನು_ಸೋಮ_ಮಂಗಳ_ಬುಧ_ಗುರು_ಶುಕ್ರ_ಶನಿ'.split('_'),
|
| 12184 |
+
weekdaysMin : 'ಭಾ_ಸೋ_ಮಂ_ಬು_ಗು_ಶು_ಶ'.split('_'),
|
| 12185 |
+
longDateFormat : {
|
| 12186 |
+
LT : 'A h:mm',
|
| 12187 |
+
LTS : 'A h:mm:ss',
|
| 12188 |
+
L : 'DD/MM/YYYY',
|
| 12189 |
+
LL : 'D MMMM YYYY',
|
| 12190 |
+
LLL : 'D MMMM YYYY, A h:mm',
|
| 12191 |
+
LLLL : 'dddd, D MMMM YYYY, A h:mm'
|
| 12192 |
+
},
|
| 12193 |
+
calendar : {
|
| 12194 |
+
sameDay : '[ಇಂದು] LT',
|
| 12195 |
+
nextDay : '[ನಾಳೆ] LT',
|
| 12196 |
+
nextWeek : 'dddd, LT',
|
| 12197 |
+
lastDay : '[ನಿನ್ನೆ] LT',
|
| 12198 |
+
lastWeek : '[ಕೊನೆಯ] dddd, LT',
|
| 12199 |
+
sameElse : 'L'
|
| 12200 |
+
},
|
| 12201 |
+
relativeTime : {
|
| 12202 |
+
future : '%s ನಂತರ',
|
| 12203 |
+
past : '%s ಹಿಂದೆ',
|
| 12204 |
+
s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
|
| 12205 |
+
m : 'ಒಂದು ನಿಮಿಷ',
|
| 12206 |
+
mm : '%d ನಿಮಿಷ',
|
| 12207 |
+
h : 'ಒಂದು ಗಂಟೆ',
|
| 12208 |
+
hh : '%d ಗಂಟೆ',
|
| 12209 |
+
d : 'ಒಂದು ದಿನ',
|
| 12210 |
+
dd : '%d ದಿನ',
|
| 12211 |
+
M : 'ಒಂದು ತಿಂಗಳು',
|
| 12212 |
+
MM : '%d ತಿಂಗಳು',
|
| 12213 |
+
y : 'ಒಂದು ವರ್ಷ',
|
| 12214 |
+
yy : '%d ವರ್ಷ'
|
| 12215 |
+
},
|
| 12216 |
+
preparse: function (string) {
|
| 12217 |
+
return string.replace(/[೧೨೩೪೫೬೭೮೯೦]/g, function (match) {
|
| 12218 |
+
return numberMap[match];
|
| 12219 |
+
});
|
| 12220 |
+
},
|
| 12221 |
+
postformat: function (string) {
|
| 12222 |
+
return string.replace(/\d/g, function (match) {
|
| 12223 |
+
return symbolMap[match];
|
| 12224 |
+
});
|
| 12225 |
+
},
|
| 12226 |
+
meridiemParse: /ರಾತ್ರಿ|ಬೆಳಿಗ್ಗೆ|ಮಧ್ಯಾಹ್ನ|ಸಂಜೆ/,
|
| 12227 |
+
meridiemHour : function (hour, meridiem) {
|
| 12228 |
+
if (hour === 12) {
|
| 12229 |
+
hour = 0;
|
| 12230 |
+
}
|
| 12231 |
+
if (meridiem === 'ರಾತ್ರಿ') {
|
| 12232 |
+
return hour < 4 ? hour : hour + 12;
|
| 12233 |
+
} else if (meridiem === 'ಬೆಳಿಗ್ಗೆ') {
|
| 12234 |
+
return hour;
|
| 12235 |
+
} else if (meridiem === 'ಮಧ್ಯಾಹ್ನ') {
|
| 12236 |
+
return hour >= 10 ? hour : hour + 12;
|
| 12237 |
+
} else if (meridiem === 'ಸಂಜೆ') {
|
| 12238 |
+
return hour + 12;
|
| 12239 |
+
}
|
| 12240 |
+
},
|
| 12241 |
+
meridiem : function (hour, minute, isLower) {
|
| 12242 |
+
if (hour < 4) {
|
| 12243 |
+
return 'ರಾತ್ರಿ';
|
| 12244 |
+
} else if (hour < 10) {
|
| 12245 |
+
return 'ಬೆಳಿಗ್ಗೆ';
|
| 12246 |
+
} else if (hour < 17) {
|
| 12247 |
+
return 'ಮಧ್ಯಾಹ್ನ';
|
| 12248 |
+
} else if (hour < 20) {
|
| 12249 |
+
return 'ಸಂಜೆ';
|
| 12250 |
+
} else {
|
| 12251 |
+
return 'ರಾತ್ರಿ';
|
| 12252 |
+
}
|
| 12253 |
+
},
|
| 12254 |
+
dayOfMonthOrdinalParse: /\d{1,2}(ನೇ)/,
|
| 12255 |
+
ordinal : function (number) {
|
| 12256 |
+
return number + 'ನೇ';
|
| 12257 |
+
},
|
| 12258 |
+
week : {
|
| 12259 |
+
dow : 0, // Sunday is the first day of the week.
|
| 12260 |
+
doy : 6 // The week that contains Jan 1st is the first week of the year.
|
| 12261 |
+
}
|
| 12262 |
+
});
|
| 12263 |
+
|
| 12264 |
+
return kn;
|
| 12265 |
+
|
| 12266 |
+
})));
|
| 12267 |
+
|
| 12268 |
+
|
| 12269 |
+
/***/ },
|
| 12270 |
+
/* 359 */
|
| 12271 |
/***/ function(module, exports, __webpack_require__) {
|
| 12272 |
|
| 12273 |
//! moment.js locale configuration
|
| 12276 |
//! author : Jeeeyul Lee <jeeeyul@gmail.com>
|
| 12277 |
|
| 12278 |
;(function (global, factory) {
|
| 12279 |
+
true ? factory(__webpack_require__(297)) :
|
| 12280 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12281 |
factory(global.moment)
|
| 12282 |
}(this, (function (moment) { 'use strict';
|
| 12289 |
weekdaysShort : '일_월_화_수_목_금_토'.split('_'),
|
| 12290 |
weekdaysMin : '일_월_화_수_목_금_토'.split('_'),
|
| 12291 |
longDateFormat : {
|
| 12292 |
+
LT : 'A h:mm',
|
| 12293 |
+
LTS : 'A h:mm:ss',
|
| 12294 |
L : 'YYYY.MM.DD',
|
| 12295 |
LL : 'YYYY년 MMMM D일',
|
| 12296 |
+
LLL : 'YYYY년 MMMM D일 A h:mm',
|
| 12297 |
+
LLLL : 'YYYY년 MMMM D일 dddd A h:mm',
|
| 12298 |
+
l : 'YYYY.MM.DD',
|
| 12299 |
+
ll : 'YYYY년 MMMM D일',
|
| 12300 |
+
lll : 'YYYY년 MMMM D일 A h:mm',
|
| 12301 |
+
llll : 'YYYY년 MMMM D일 dddd A h:mm'
|
| 12302 |
},
|
| 12303 |
calendar : {
|
| 12304 |
sameDay : '오늘 LT',
|
| 12313 |
past : '%s 전',
|
| 12314 |
s : '몇 초',
|
| 12315 |
ss : '%d초',
|
| 12316 |
+
m : '1분',
|
| 12317 |
mm : '%d분',
|
| 12318 |
h : '한 시간',
|
| 12319 |
hh : '%d시간',
|
| 12324 |
y : '일 년',
|
| 12325 |
yy : '%d년'
|
| 12326 |
},
|
| 12327 |
+
dayOfMonthOrdinalParse : /\d{1,2}일/,
|
| 12328 |
ordinal : '%d일',
|
| 12329 |
meridiemParse : /오전|오후/,
|
| 12330 |
isPM : function (token) {
|
| 12341 |
|
| 12342 |
|
| 12343 |
/***/ },
|
| 12344 |
+
/* 360 */
|
| 12345 |
/***/ function(module, exports, __webpack_require__) {
|
| 12346 |
|
| 12347 |
//! moment.js locale configuration
|
| 12349 |
//! author : Chyngyz Arystan uulu : https://github.com/chyngyz
|
| 12350 |
|
| 12351 |
;(function (global, factory) {
|
| 12352 |
+
true ? factory(__webpack_require__(297)) :
|
| 12353 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12354 |
factory(global.moment)
|
| 12355 |
}(this, (function (moment) { 'use strict';
|
| 12416 |
y : 'бир жыл',
|
| 12417 |
yy : '%d жыл'
|
| 12418 |
},
|
| 12419 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(чи|чы|чү|чу)/,
|
| 12420 |
ordinal : function (number) {
|
| 12421 |
var a = number % 10,
|
| 12422 |
b = number >= 100 ? 100 : null;
|
| 12434 |
|
| 12435 |
|
| 12436 |
/***/ },
|
| 12437 |
+
/* 361 */
|
| 12438 |
/***/ function(module, exports, __webpack_require__) {
|
| 12439 |
|
| 12440 |
//! moment.js locale configuration
|
| 12443 |
//! author : David Raison : https://github.com/kwisatz
|
| 12444 |
|
| 12445 |
;(function (global, factory) {
|
| 12446 |
+
true ? factory(__webpack_require__(297)) :
|
| 12447 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12448 |
factory(global.moment)
|
| 12449 |
}(this, (function (moment) { 'use strict';
|
| 12562 |
y : processRelativeTime,
|
| 12563 |
yy : '%d Joer'
|
| 12564 |
},
|
| 12565 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 12566 |
ordinal: '%d.',
|
| 12567 |
week: {
|
| 12568 |
dow: 1, // Monday is the first day of the week.
|
| 12576 |
|
| 12577 |
|
| 12578 |
/***/ },
|
| 12579 |
+
/* 362 */
|
| 12580 |
/***/ function(module, exports, __webpack_require__) {
|
| 12581 |
|
| 12582 |
//! moment.js locale configuration
|
| 12584 |
//! author : Ryan Hart : https://github.com/ryanhart2
|
| 12585 |
|
| 12586 |
;(function (global, factory) {
|
| 12587 |
+
true ? factory(__webpack_require__(297)) :
|
| 12588 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12589 |
factory(global.moment)
|
| 12590 |
}(this, (function (moment) { 'use strict';
|
| 12639 |
y : '1 ປີ',
|
| 12640 |
yy : '%d ປີ'
|
| 12641 |
},
|
| 12642 |
+
dayOfMonthOrdinalParse: /(ທີ່)\d{1,2}/,
|
| 12643 |
ordinal : function (number) {
|
| 12644 |
return 'ທີ່' + number;
|
| 12645 |
}
|
| 12651 |
|
| 12652 |
|
| 12653 |
/***/ },
|
| 12654 |
+
/* 363 */
|
| 12655 |
/***/ function(module, exports, __webpack_require__) {
|
| 12656 |
|
| 12657 |
//! moment.js locale configuration
|
| 12659 |
//! author : Mindaugas Mozūras : https://github.com/mmozuras
|
| 12660 |
|
| 12661 |
;(function (global, factory) {
|
| 12662 |
+
true ? factory(__webpack_require__(297)) :
|
| 12663 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12664 |
factory(global.moment)
|
| 12665 |
}(this, (function (moment) { 'use strict';
|
| 12757 |
y : translateSingular,
|
| 12758 |
yy : translate
|
| 12759 |
},
|
| 12760 |
+
dayOfMonthOrdinalParse: /\d{1,2}-oji/,
|
| 12761 |
ordinal : function (number) {
|
| 12762 |
return number + '-oji';
|
| 12763 |
},
|
| 12773 |
|
| 12774 |
|
| 12775 |
/***/ },
|
| 12776 |
+
/* 364 */
|
| 12777 |
/***/ function(module, exports, __webpack_require__) {
|
| 12778 |
|
| 12779 |
//! moment.js locale configuration
|
| 12782 |
//! author : Jānis Elmeris : https://github.com/JanisE
|
| 12783 |
|
| 12784 |
;(function (global, factory) {
|
| 12785 |
+
true ? factory(__webpack_require__(297)) :
|
| 12786 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12787 |
factory(global.moment)
|
| 12788 |
}(this, (function (moment) { 'use strict';
|
| 12861 |
y : relativeTimeWithSingular,
|
| 12862 |
yy : relativeTimeWithPlural
|
| 12863 |
},
|
| 12864 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 12865 |
ordinal : '%d.',
|
| 12866 |
week : {
|
| 12867 |
dow : 1, // Monday is the first day of the week.
|
| 12875 |
|
| 12876 |
|
| 12877 |
/***/ },
|
| 12878 |
+
/* 365 */
|
| 12879 |
/***/ function(module, exports, __webpack_require__) {
|
| 12880 |
|
| 12881 |
//! moment.js locale configuration
|
| 12883 |
//! author : Miodrag Nikač <miodrag@restartit.me> : https://github.com/miodragnikac
|
| 12884 |
|
| 12885 |
;(function (global, factory) {
|
| 12886 |
+
true ? factory(__webpack_require__(297)) :
|
| 12887 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 12888 |
factory(global.moment)
|
| 12889 |
}(this, (function (moment) { 'use strict';
|
| 12977 |
y : 'godinu',
|
| 12978 |
yy : translator.translate
|
| 12979 |
},
|
| 12980 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 12981 |
ordinal : '%d.',
|
| 12982 |
week : {
|
| 12983 |
dow : 1, // Monday is the first day of the week.
|
| 12991 |
|
| 12992 |
|
| 12993 |
/***/ },
|
| 12994 |
+
/* 366 */
|
| 12995 |
/***/ function(module, exports, __webpack_require__) {
|
| 12996 |
|
| 12997 |
//! moment.js locale configuration
|
| 12999 |
//! author : John Corrigan <robbiecloset@gmail.com> : https://github.com/johnideal
|
| 13000 |
|
| 13001 |
;(function (global, factory) {
|
| 13002 |
+
true ? factory(__webpack_require__(297)) :
|
| 13003 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13004 |
factory(global.moment)
|
| 13005 |
}(this, (function (moment) { 'use strict';
|
| 13046 |
y: 'he tau',
|
| 13047 |
yy: '%d tau'
|
| 13048 |
},
|
| 13049 |
+
dayOfMonthOrdinalParse: /\d{1,2}º/,
|
| 13050 |
ordinal: '%dº',
|
| 13051 |
week : {
|
| 13052 |
dow : 1, // Monday is the first day of the week.
|
| 13060 |
|
| 13061 |
|
| 13062 |
/***/ },
|
| 13063 |
+
/* 367 */
|
| 13064 |
/***/ function(module, exports, __webpack_require__) {
|
| 13065 |
|
| 13066 |
//! moment.js locale configuration
|
| 13068 |
//! author : Borislav Mickov : https://github.com/B0k0
|
| 13069 |
|
| 13070 |
;(function (global, factory) {
|
| 13071 |
+
true ? factory(__webpack_require__(297)) :
|
| 13072 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13073 |
factory(global.moment)
|
| 13074 |
}(this, (function (moment) { 'use strict';
|
| 13123 |
y : 'година',
|
| 13124 |
yy : '%d години'
|
| 13125 |
},
|
| 13126 |
+
dayOfMonthOrdinalParse: /\d{1,2}-(ев|ен|ти|ви|ри|ми)/,
|
| 13127 |
ordinal : function (number) {
|
| 13128 |
var lastDigit = number % 10,
|
| 13129 |
last2Digits = number % 100;
|
| 13155 |
|
| 13156 |
|
| 13157 |
/***/ },
|
| 13158 |
+
/* 368 */
|
| 13159 |
/***/ function(module, exports, __webpack_require__) {
|
| 13160 |
|
| 13161 |
//! moment.js locale configuration
|
| 13163 |
//! author : Floyd Pink : https://github.com/floydpink
|
| 13164 |
|
| 13165 |
;(function (global, factory) {
|
| 13166 |
+
true ? factory(__webpack_require__(297)) :
|
| 13167 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13168 |
factory(global.moment)
|
| 13169 |
}(this, (function (moment) { 'use strict';
|
| 13241 |
|
| 13242 |
|
| 13243 |
/***/ },
|
| 13244 |
+
/* 369 */
|
| 13245 |
/***/ function(module, exports, __webpack_require__) {
|
| 13246 |
|
| 13247 |
//! moment.js locale configuration
|
| 13250 |
//! author : Vivek Athalye : https://github.com/vnathalye
|
| 13251 |
|
| 13252 |
;(function (global, factory) {
|
| 13253 |
+
true ? factory(__webpack_require__(297)) :
|
| 13254 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13255 |
factory(global.moment)
|
| 13256 |
}(this, (function (moment) { 'use strict';
|
| 13405 |
|
| 13406 |
|
| 13407 |
/***/ },
|
| 13408 |
+
/* 370 */
|
| 13409 |
/***/ function(module, exports, __webpack_require__) {
|
| 13410 |
|
| 13411 |
//! moment.js locale configuration
|
| 13413 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 13414 |
|
| 13415 |
;(function (global, factory) {
|
| 13416 |
+
true ? factory(__webpack_require__(297)) :
|
| 13417 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13418 |
factory(global.moment)
|
| 13419 |
}(this, (function (moment) { 'use strict';
|
| 13492 |
|
| 13493 |
|
| 13494 |
/***/ },
|
| 13495 |
+
/* 371 */
|
| 13496 |
/***/ function(module, exports, __webpack_require__) {
|
| 13497 |
|
| 13498 |
//! moment.js locale configuration
|
| 13501 |
//! author : Weldan Jamili : https://github.com/weldan
|
| 13502 |
|
| 13503 |
;(function (global, factory) {
|
| 13504 |
+
true ? factory(__webpack_require__(297)) :
|
| 13505 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13506 |
factory(global.moment)
|
| 13507 |
}(this, (function (moment) { 'use strict';
|
| 13580 |
|
| 13581 |
|
| 13582 |
/***/ },
|
| 13583 |
+
/* 372 */
|
| 13584 |
/***/ function(module, exports, __webpack_require__) {
|
| 13585 |
|
| 13586 |
//! moment.js locale configuration
|
| 13590 |
//! author : Tin Aung Lin : https://github.com/thanyawzinmin
|
| 13591 |
|
| 13592 |
;(function (global, factory) {
|
| 13593 |
+
true ? factory(__webpack_require__(297)) :
|
| 13594 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13595 |
factory(global.moment)
|
| 13596 |
}(this, (function (moment) { 'use strict';
|
| 13681 |
|
| 13682 |
|
| 13683 |
/***/ },
|
| 13684 |
+
/* 373 */
|
| 13685 |
/***/ function(module, exports, __webpack_require__) {
|
| 13686 |
|
| 13687 |
//! moment.js locale configuration
|
| 13690 |
//! Sigurd Gartmann : https://github.com/sigurdga
|
| 13691 |
|
| 13692 |
;(function (global, factory) {
|
| 13693 |
+
true ? factory(__webpack_require__(297)) :
|
| 13694 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13695 |
factory(global.moment)
|
| 13696 |
}(this, (function (moment) { 'use strict';
|
| 13735 |
y : 'ett år',
|
| 13736 |
yy : '%d år'
|
| 13737 |
},
|
| 13738 |
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
| 13739 |
ordinal : '%d.',
|
| 13740 |
week : {
|
| 13741 |
dow : 1, // Monday is the first day of the week.
|
| 13749 |
|
| 13750 |
|
| 13751 |
/***/ },
|
| 13752 |
+
/* 374 */
|
| 13753 |
/***/ function(module, exports, __webpack_require__) {
|
| 13754 |
|
| 13755 |
//! moment.js locale configuration
|
| 13757 |
//! author : suvash : https://github.com/suvash
|
| 13758 |
|
| 13759 |
;(function (global, factory) {
|
| 13760 |
+
true ? factory(__webpack_require__(297)) :
|
| 13761 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13762 |
factory(global.moment)
|
| 13763 |
}(this, (function (moment) { 'use strict';
|
| 13877 |
|
| 13878 |
|
| 13879 |
/***/ },
|
| 13880 |
+
/* 375 */
|
| 13881 |
/***/ function(module, exports, __webpack_require__) {
|
| 13882 |
|
| 13883 |
//! moment.js locale configuration
|
| 13886 |
//! author : Jacob Middag : https://github.com/middagj
|
| 13887 |
|
| 13888 |
;(function (global, factory) {
|
| 13889 |
+
true ? factory(__webpack_require__(297)) :
|
| 13890 |
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
| 13891 |
factory(global.moment)
|
| 13892 |
}(this, (function (momen
|
