ecinc-cloud-yoaemail 9.5.4 → 9.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -87,17 +87,6 @@ module.exports =
87
87
  /************************************************************************/
88
88
  /******/ ({
89
89
 
90
- /***/ "1829":
91
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
92
-
93
- "use strict";
94
- /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_66e2781e_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("cd12");
95
- /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_66e2781e_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_66e2781e_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
96
- /* unused harmony reexport * */
97
-
98
-
99
- /***/ }),
100
-
101
90
  /***/ "24fb":
102
91
  /***/ (function(module, exports, __webpack_require__) {
103
92
 
@@ -1374,20 +1363,6 @@ var index = {
1374
1363
 
1375
1364
  /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__("c8ba")))
1376
1365
 
1377
- /***/ }),
1378
-
1379
- /***/ "3609":
1380
- /***/ (function(module, exports, __webpack_require__) {
1381
-
1382
- // Imports
1383
- var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
1384
- exports = ___CSS_LOADER_API_IMPORT___(false);
1385
- // Module
1386
- exports.push([module.i, "[data-v-66e2781e]:export{stdMenuBgcolor:var(--lmBgColor);stdMenuHover:var(--lmBgColorActive)!important;stdMenuText:var(--lmTextColor)!important;stdMenuAcitveText:var(--lmTextColorActive)!important;stdSubMenuBgcolor:var(--lmBgColor);stdSubMenuHover:rgba(163,174,177,.419608);stdSubMenuActiveText:var(--lmTextColorActive)!important;darkMenuBgcolor:#304156;darkMenuHover:#263445;darkMenuText:#bfcbd9;darkMenuAcitveText:#ffd04b;darkSubMenuBgcolor:#384b63;darkSubMenuHover:#263445;darkSubMenuActiveText:#ffd04b;sideBarWidth:210px;formLabelWidth:133px;lightBlue:var(--subjectColor)}.app-wrapper[data-v-66e2781e]{position:relative;height:100%;width:100%}.app-wrapper[data-v-66e2781e]:after{content:\"\";display:table;clear:both}.app-wrapper.mobile.openSidebar[data-v-66e2781e]{position:fixed;top:0}.drawer-bg[data-v-66e2781e]{background:#000;opacity:.3;width:100%;top:0;height:100%;position:absolute;z-index:999}.fixed-header[data-v-66e2781e]{position:fixed;top:60px;right:0;z-index:9;width:calc(100% - 210px);-webkit-transition:width .28s;transition:width .28s}.mobile .fixed-header[data-v-66e2781e]{width:100%}.imgHead[data-v-66e2781e]{width:20px;height:20px;border-radius:20px;text-align:center;line-height:20px;margin-right:10px}.imgHead2[data-v-66e2781e]{display:inline-block;width:24px;height:24px;border-radius:50%;text-align:center;line-height:24px;top:-3px;position:relative}[data-v-66e2781e] .changEmail .el-input__inner{border:none;padding-left:6px}.accountDialog[data-v-66e2781e]{width:300px;height:auto;position:absolute;z-index:100;top:45px;right:10px;background-color:#fff;-webkit-box-shadow:0 0 6px 0 rgba(0,0,0,.1)!important;box-shadow:0 0 6px 0 rgba(0,0,0,.1)!important;border-radius:4px;font-size:14px}.accountDialog .currentOptiopn[data-v-66e2781e]{height:66px;padding:10px 20px;border-bottom:1px solid #eee}.accountDialog .optionList[data-v-66e2781e]{width:260px;color:#333;margin-top:16px;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;cursor:pointer;padding:0 40px 0 20px}.accountDialog .optionList[data-v-66e2781e]:hover{color:#409eff}.accountDialog .optionListWrap>div:first-child .optionList[data-v-66e2781e]{margin-top:0}.headInfo[data-v-66e2781e]{width:240px;height:50px;background:#fff;position:absolute;top:0;right:0}[data-v-66e2781e] .navbar{margin:0;padding:0 10px}[data-v-66e2781e] .navbar .right-menu{right:10px}", ""]);
1387
- // Exports
1388
- module.exports = exports;
1389
-
1390
-
1391
1366
  /***/ }),
1392
1367
 
1393
1368
  /***/ "499e":
@@ -1712,52 +1687,19 @@ var WIDTH = 992; // refer to Bootstrap's responsive design
1712
1687
 
1713
1688
  /***/ }),
1714
1689
 
1715
- /***/ "4fe4":
1690
+ /***/ "7832":
1716
1691
  /***/ (function(module, exports, __webpack_require__) {
1717
1692
 
1718
1693
  // style-loader: Adds some css to the DOM by adding a <style> tag
1719
1694
 
1720
1695
  // load the styles
1721
- var content = __webpack_require__("8c9f");
1696
+ var content = __webpack_require__("bef1");
1722
1697
  if(content.__esModule) content = content.default;
1723
1698
  if(typeof content === 'string') content = [[module.i, content, '']];
1724
1699
  if(content.locals) module.exports = content.locals;
1725
1700
  // add the styles to the DOM
1726
1701
  var add = __webpack_require__("499e").default
1727
- var update = add("52c0d9b7", content, true, {"sourceMap":false,"shadowMode":false});
1728
-
1729
- /***/ }),
1730
-
1731
- /***/ "5fa6":
1732
- /***/ (function(module, exports, __webpack_require__) {
1733
-
1734
- // Imports
1735
- var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
1736
- exports = ___CSS_LOADER_API_IMPORT___(false);
1737
- // Module
1738
- exports.push([module.i, ".appname{margin-left:-5px}.el-menu--popup{overflow:hidden;border-radius:3px}.nest-menu.notop{border-top:none!important}.nest-menu.notop .el-menu-item{background-color:#384b63!important;border-bottom:1px dotted #777;height:50px;line-height:50px}.nest-menu.notop .el-menu-item.is-active{color:#fff!important}.nest-menu.notop .el-menu-item.is-active:after{right:0}.nest-menu.notop .el-menu-item:hover{background-color:#445c80!important;color:#fff!important}.nest-menu.notop:last-child .el-menu-item{border-bottom:none}.el-menu-item{height:50px}.std-scrollbar-wrapper{background-color:var(--lmBgColor);border-right:1px solid #e6e6e6}.std-scrollbar-wrapper .el-submenu__title:hover,.std-scrollbar-wrapper .submenu-title-noDropdown:hover{background-color:var(--lmBgColorActive) !important!important}.std-scrollbar-wrapper .is-active>.el-submenu__title{color:var(--lmTextColorActive)!important}.std-scrollbar-wrapper .el-submenu .el-menu-item,.std-scrollbar-wrapper .nest-menu .el-submenu>.el-submenu__title{background-color:var(--lmBgColor)!important}.std-scrollbar-wrapper .el-submenu .el-menu-item:hover,.std-scrollbar-wrapper .nest-menu .el-submenu>.el-submenu__title:hover{background-color:rgba(163,174,177,.419608)!important}.dark-scrollbar-wrapper{background-color:#304156;border-right:1px solid #304156}.dark-scrollbar-wrapper .el-submenu__title:hover,.dark-scrollbar-wrapper .submenu-title-noDropdown:hover{background-color:#263445!important}.dark-scrollbar-wrapper .is-active>.el-submenu__title{color:#fff}.dark-scrollbar-wrapper .el-submenu .el-menu-item,.dark-scrollbar-wrapper .nest-menu .el-submenu>.el-submenu__title{background-color:#384b63!important;border-bottom:none}.dark-scrollbar-wrapper .el-submenu .el-menu-item.is-active,.dark-scrollbar-wrapper .nest-menu .el-submenu>.el-submenu__title.is-active{color:#fff!important}.dark-scrollbar-wrapper .el-submenu .el-menu-item:hover,.dark-scrollbar-wrapper .nest-menu .el-submenu>.el-submenu__title:hover{background-color:#445c80!important;color:#fff!important}/deep/.topBtn-wrapper{text-align:center;height:55px}.separate{height:10px;background-color:#fff}.writeEmail{position:relative;justify-items:start;margin:0;border-radius:2px;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;display:inline-block;line-height:49px;border:1px solid #eee;text-align:center;background-color:#fff;height:31px;margin:12px 4px;width:76px;cursor:pointer}.writeEmail:first-child{border-right:1px solid #d8d9da}.writeEmail .svg-icon{width:14px;height:14px;position:absolute;top:30%;left:25%}.writeEmail span{font-size:14px;line-height:19px;position:absolute;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%);left:50%}", ""]);
1739
- // Exports
1740
- exports.locals = {
1741
- "stdMenuBgcolor": "var(--lmBgColor)",
1742
- "stdMenuHover": "var(--lmBgColorActive)",
1743
- "stdMenuText": "var(--lmTextColor)",
1744
- "stdMenuAcitveText": "var(--lmTextColorActive)",
1745
- "stdSubMenuBgcolor": "var(--lmBgColor)",
1746
- "stdSubMenuHover": "rgba(163,174,177,.419608)",
1747
- "stdSubMenuActiveText": "var(--lmTextColorActive)",
1748
- "darkMenuBgcolor": "#304156",
1749
- "darkMenuHover": "#263445",
1750
- "darkMenuText": "#bfcbd9",
1751
- "darkMenuAcitveText": "#ffd04b",
1752
- "darkSubMenuBgcolor": "#384b63",
1753
- "darkSubMenuHover": "#263445",
1754
- "darkSubMenuActiveText": "#ffd04b",
1755
- "sideBarWidth": "210px",
1756
- "formLabelWidth": "133px",
1757
- "lightBlue": "var(--subjectColor)"
1758
- };
1759
- module.exports = exports;
1760
-
1702
+ var update = add("2295d35e", content, true, {"sourceMap":false,"shadowMode":false});
1761
1703
 
1762
1704
  /***/ }),
1763
1705
 
@@ -1846,55 +1788,29 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1846
1788
 
1847
1789
  /***/ }),
1848
1790
 
1849
- /***/ "8bbf":
1850
- /***/ (function(module, exports) {
1791
+ /***/ "8979":
1792
+ /***/ (function(module, __webpack_exports__, __webpack_require__) {
1793
+
1794
+ "use strict";
1795
+ /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_5e809c44_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("7832");
1796
+ /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_5e809c44_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_5e809c44_prod_lang_scss_scoped_true___WEBPACK_IMPORTED_MODULE_0__);
1797
+ /* unused harmony reexport * */
1851
1798
 
1852
- module.exports = require("vue");
1853
1799
 
1854
1800
  /***/ }),
1855
1801
 
1856
- /***/ "8c9f":
1802
+ /***/ "bef1":
1857
1803
  /***/ (function(module, exports, __webpack_require__) {
1858
1804
 
1859
1805
  // Imports
1860
1806
  var ___CSS_LOADER_API_IMPORT___ = __webpack_require__("24fb");
1861
1807
  exports = ___CSS_LOADER_API_IMPORT___(false);
1862
1808
  // Module
1863
- exports.push([module.i, "", ""]);
1809
+ exports.push([module.i, "[data-v-5e809c44]:export{stdMenuBgcolor:var(--lmBgColor);stdMenuHover:var(--lmBgColorActive)!important;stdMenuText:var(--lmTextColor)!important;stdMenuAcitveText:var(--lmTextColorActive)!important;stdSubMenuBgcolor:var(--lmBgColor);stdSubMenuHover:rgba(163,174,177,.419608);stdSubMenuActiveText:var(--lmTextColorActive)!important;darkMenuBgcolor:#304156;darkMenuHover:#263445;darkMenuText:#bfcbd9;darkMenuAcitveText:#ffd04b;darkSubMenuBgcolor:#384b63;darkSubMenuHover:#263445;darkSubMenuActiveText:#ffd04b;sideBarWidth:210px;formLabelWidth:133px;lightBlue:var(--subjectColor)}.app-wrapper[data-v-5e809c44]{position:relative;height:100%;width:100%}.app-wrapper[data-v-5e809c44]:after{content:\"\";display:table;clear:both}.app-wrapper.mobile.openSidebar[data-v-5e809c44]{position:fixed;top:0}.drawer-bg[data-v-5e809c44]{background:#000;opacity:.3;width:100%;top:0;height:100%;position:absolute;z-index:999}.fixed-header[data-v-5e809c44]{position:fixed;top:60px;right:0;z-index:9;width:calc(100% - 210px);-webkit-transition:width .28s;transition:width .28s}.mobile .fixed-header[data-v-5e809c44]{width:100%}.imgHead[data-v-5e809c44]{width:20px;height:20px;border-radius:20px;text-align:center;line-height:20px;margin-right:10px}.imgHead2[data-v-5e809c44]{display:inline-block;width:24px;height:24px;border-radius:50%;text-align:center;line-height:24px;top:-3px;position:relative}[data-v-5e809c44] .changEmail .el-input__inner{border:none;padding-left:6px}.accountDialog[data-v-5e809c44]{width:300px;height:auto;position:absolute;z-index:100;top:45px;right:10px;background-color:#fff;-webkit-box-shadow:0 0 6px 0 rgba(0,0,0,.1)!important;box-shadow:0 0 6px 0 rgba(0,0,0,.1)!important;border-radius:4px;font-size:14px}.accountDialog .currentOptiopn[data-v-5e809c44]{height:66px;padding:10px 20px;border-bottom:1px solid #eee}.accountDialog .optionList[data-v-5e809c44]{width:260px;color:#333;margin-top:16px;width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;cursor:pointer;padding:0 40px 0 20px}.accountDialog .optionList[data-v-5e809c44]:hover{color:#409eff}.accountDialog .optionListWrap>div:first-child .optionList[data-v-5e809c44]{margin-top:0}.headInfo[data-v-5e809c44]{width:240px;height:50px;background:#fff;position:absolute;top:0;right:0}[data-v-5e809c44] .navbar{margin:0;padding:0 10px}[data-v-5e809c44] .navbar .right-menu{right:10px}", ""]);
1864
1810
  // Exports
1865
- exports.locals = {
1866
- "stdMenuBgcolor": "var(--lmBgColor)",
1867
- "stdMenuHover": "var(--lmBgColorActive)",
1868
- "stdMenuText": "var(--lmTextColor)",
1869
- "stdMenuAcitveText": "var(--lmTextColorActive)",
1870
- "stdSubMenuBgcolor": "var(--lmBgColor)",
1871
- "stdSubMenuHover": "rgba(163,174,177,.419608)",
1872
- "stdSubMenuActiveText": "var(--lmTextColorActive)",
1873
- "darkMenuBgcolor": "#304156",
1874
- "darkMenuHover": "#263445",
1875
- "darkMenuText": "#bfcbd9",
1876
- "darkMenuAcitveText": "#ffd04b",
1877
- "darkSubMenuBgcolor": "#384b63",
1878
- "darkSubMenuHover": "#263445",
1879
- "darkSubMenuActiveText": "#ffd04b",
1880
- "sideBarWidth": "210px",
1881
- "formLabelWidth": "133px",
1882
- "lightBlue": "var(--subjectColor)"
1883
- };
1884
1811
  module.exports = exports;
1885
1812
 
1886
1813
 
1887
- /***/ }),
1888
-
1889
- /***/ "a907":
1890
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
1891
-
1892
- "use strict";
1893
- /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_LeftMenu_vue_vue_type_style_index_0_id_670785a0_prod_lang_scss___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("f13b");
1894
- /* harmony import */ var _node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_LeftMenu_vue_vue_type_style_index_0_id_670785a0_prod_lang_scss___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_vue_style_loader_index_js_ref_9_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_9_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_2_node_modules_postcss_loader_src_index_js_ref_9_oneOf_1_3_node_modules_sass_loader_dist_cjs_js_ref_9_oneOf_1_4_node_modules_cache_loader_dist_cjs_js_ref_1_0_node_modules_vue_loader_lib_index_js_vue_loader_options_LeftMenu_vue_vue_type_style_index_0_id_670785a0_prod_lang_scss___WEBPACK_IMPORTED_MODULE_0__);
1895
- /* unused harmony reexport * */
1896
-
1897
-
1898
1814
  /***/ }),
1899
1815
 
1900
1816
  /***/ "c8ba":
@@ -1922,22 +1838,6 @@ try {
1922
1838
  module.exports = g;
1923
1839
 
1924
1840
 
1925
- /***/ }),
1926
-
1927
- /***/ "cd12":
1928
- /***/ (function(module, exports, __webpack_require__) {
1929
-
1930
- // style-loader: Adds some css to the DOM by adding a <style> tag
1931
-
1932
- // load the styles
1933
- var content = __webpack_require__("3609");
1934
- if(content.__esModule) content = content.default;
1935
- if(typeof content === 'string') content = [[module.i, content, '']];
1936
- if(content.locals) module.exports = content.locals;
1937
- // add the styles to the DOM
1938
- var add = __webpack_require__("499e").default
1939
- var update = add("3ee6287e", content, true, {"sourceMap":false,"shadowMode":false});
1940
-
1941
1841
  /***/ }),
1942
1842
 
1943
1843
  /***/ "ef8d":
@@ -2417,3237 +2317,101 @@ __webpack_require__.r(__webpack_exports__);
2417
2317
 
2418
2318
  /***/ }),
2419
2319
 
2420
- /***/ "f13b":
2421
- /***/ (function(module, exports, __webpack_require__) {
2422
-
2423
- // style-loader: Adds some css to the DOM by adding a <style> tag
2424
-
2425
- // load the styles
2426
- var content = __webpack_require__("5fa6");
2427
- if(content.__esModule) content = content.default;
2428
- if(typeof content === 'string') content = [[module.i, content, '']];
2429
- if(content.locals) module.exports = content.locals;
2430
- // add the styles to the DOM
2431
- var add = __webpack_require__("499e").default
2432
- var update = add("b53561cc", content, true, {"sourceMap":false,"shadowMode":false});
2433
-
2434
- /***/ }),
2435
-
2436
- /***/ "f583":
2320
+ /***/ "fb15":
2437
2321
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
2438
2322
 
2439
2323
  "use strict";
2440
2324
  __webpack_require__.r(__webpack_exports__);
2441
2325
 
2442
- // EXTERNAL MODULE: external {"commonjs":"vue","commonjs2":"vue","root":"Vue"}
2443
- var external_commonjs_vue_commonjs2_vue_root_Vue_ = __webpack_require__("8bbf");
2444
- var external_commonjs_vue_commonjs2_vue_root_Vue_default = /*#__PURE__*/__webpack_require__.n(external_commonjs_vue_commonjs2_vue_root_Vue_);
2445
-
2446
- // CONCATENATED MODULE: ./node_modules/vue-router/dist/vue-router.esm.js
2447
- /*!
2448
- * vue-router v3.6.5
2449
- * (c) 2022 Evan You
2450
- * @license MIT
2451
- */
2452
- /* */
2453
-
2454
- function assert (condition, message) {
2455
- if (!condition) {
2456
- throw new Error(("[vue-router] " + message))
2457
- }
2458
- }
2459
-
2460
- function warn (condition, message) {
2461
- if (!condition) {
2462
- typeof console !== 'undefined' && console.warn(("[vue-router] " + message));
2463
- }
2464
- }
2465
-
2466
- function extend (a, b) {
2467
- for (var key in b) {
2468
- a[key] = b[key];
2469
- }
2470
- return a
2471
- }
2472
-
2473
- /* */
2474
-
2475
- var encodeReserveRE = /[!'()*]/g;
2476
- var encodeReserveReplacer = function (c) { return '%' + c.charCodeAt(0).toString(16); };
2477
- var commaRE = /%2C/g;
2478
-
2479
- // fixed encodeURIComponent which is more conformant to RFC3986:
2480
- // - escapes [!'()*]
2481
- // - preserve commas
2482
- var encode = function (str) { return encodeURIComponent(str)
2483
- .replace(encodeReserveRE, encodeReserveReplacer)
2484
- .replace(commaRE, ','); };
2485
-
2486
- function decode (str) {
2487
- try {
2488
- return decodeURIComponent(str)
2489
- } catch (err) {
2490
- if (false) {}
2491
- }
2492
- return str
2493
- }
2494
-
2495
- function resolveQuery (
2496
- query,
2497
- extraQuery,
2498
- _parseQuery
2499
- ) {
2500
- if ( extraQuery === void 0 ) extraQuery = {};
2501
-
2502
- var parse = _parseQuery || parseQuery;
2503
- var parsedQuery;
2504
- try {
2505
- parsedQuery = parse(query || '');
2506
- } catch (e) {
2507
- "production" !== 'production' && warn(false, e.message);
2508
- parsedQuery = {};
2509
- }
2510
- for (var key in extraQuery) {
2511
- var value = extraQuery[key];
2512
- parsedQuery[key] = Array.isArray(value)
2513
- ? value.map(castQueryParamValue)
2514
- : castQueryParamValue(value);
2515
- }
2516
- return parsedQuery
2517
- }
2518
-
2519
- var castQueryParamValue = function (value) { return (value == null || typeof value === 'object' ? value : String(value)); };
2520
-
2521
- function parseQuery (query) {
2522
- var res = {};
2523
-
2524
- query = query.trim().replace(/^(\?|#|&)/, '');
2525
-
2526
- if (!query) {
2527
- return res
2528
- }
2529
-
2530
- query.split('&').forEach(function (param) {
2531
- var parts = param.replace(/\+/g, ' ').split('=');
2532
- var key = decode(parts.shift());
2533
- var val = parts.length > 0 ? decode(parts.join('=')) : null;
2534
-
2535
- if (res[key] === undefined) {
2536
- res[key] = val;
2537
- } else if (Array.isArray(res[key])) {
2538
- res[key].push(val);
2539
- } else {
2540
- res[key] = [res[key], val];
2541
- }
2542
- });
2543
-
2544
- return res
2545
- }
2546
-
2547
- function stringifyQuery (obj) {
2548
- var res = obj
2549
- ? Object.keys(obj)
2550
- .map(function (key) {
2551
- var val = obj[key];
2552
-
2553
- if (val === undefined) {
2554
- return ''
2555
- }
2556
-
2557
- if (val === null) {
2558
- return encode(key)
2559
- }
2560
-
2561
- if (Array.isArray(val)) {
2562
- var result = [];
2563
- val.forEach(function (val2) {
2564
- if (val2 === undefined) {
2565
- return
2566
- }
2567
- if (val2 === null) {
2568
- result.push(encode(key));
2569
- } else {
2570
- result.push(encode(key) + '=' + encode(val2));
2571
- }
2572
- });
2573
- return result.join('&')
2574
- }
2575
-
2576
- return encode(key) + '=' + encode(val)
2577
- })
2578
- .filter(function (x) { return x.length > 0; })
2579
- .join('&')
2580
- : null;
2581
- return res ? ("?" + res) : ''
2582
- }
2583
-
2584
- /* */
2585
-
2586
- var trailingSlashRE = /\/?$/;
2587
-
2588
- function createRoute (
2589
- record,
2590
- location,
2591
- redirectedFrom,
2592
- router
2593
- ) {
2594
- var stringifyQuery = router && router.options.stringifyQuery;
2326
+ // CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
2327
+ // This file is imported into lib/wc client bundles.
2595
2328
 
2596
- var query = location.query || {};
2597
- try {
2598
- query = clone(query);
2599
- } catch (e) {}
2600
-
2601
- var route = {
2602
- name: location.name || (record && record.name),
2603
- meta: (record && record.meta) || {},
2604
- path: location.path || '/',
2605
- hash: location.hash || '',
2606
- query: query,
2607
- params: location.params || {},
2608
- fullPath: getFullPath(location, stringifyQuery),
2609
- matched: record ? formatMatch(record) : []
2610
- };
2611
- if (redirectedFrom) {
2612
- route.redirectedFrom = getFullPath(redirectedFrom, stringifyQuery);
2613
- }
2614
- return Object.freeze(route)
2615
- }
2329
+ if (typeof window !== 'undefined') {
2330
+ var currentScript = window.document.currentScript
2331
+ if (true) {
2332
+ var getCurrentScript = __webpack_require__("8875")
2333
+ currentScript = getCurrentScript()
2616
2334
 
2617
- function clone (value) {
2618
- if (Array.isArray(value)) {
2619
- return value.map(clone)
2620
- } else if (value && typeof value === 'object') {
2621
- var res = {};
2622
- for (var key in value) {
2623
- res[key] = clone(value[key]);
2335
+ // for backward compatibility, because previously we directly included the polyfill
2336
+ if (!('currentScript' in document)) {
2337
+ Object.defineProperty(document, 'currentScript', { get: getCurrentScript })
2624
2338
  }
2625
- return res
2626
- } else {
2627
- return value
2628
- }
2629
- }
2630
-
2631
- // the starting route that represents the initial state
2632
- var START = createRoute(null, {
2633
- path: '/'
2634
- });
2635
-
2636
- function formatMatch (record) {
2637
- var res = [];
2638
- while (record) {
2639
- res.unshift(record);
2640
- record = record.parent;
2641
2339
  }
2642
- return res
2643
- }
2644
2340
 
2645
- function getFullPath (
2646
- ref,
2647
- _stringifyQuery
2648
- ) {
2649
- var path = ref.path;
2650
- var query = ref.query; if ( query === void 0 ) query = {};
2651
- var hash = ref.hash; if ( hash === void 0 ) hash = '';
2652
-
2653
- var stringify = _stringifyQuery || stringifyQuery;
2654
- return (path || '/') + stringify(query) + hash
2655
- }
2656
-
2657
- function isSameRoute (a, b, onlyPath) {
2658
- if (b === START) {
2659
- return a === b
2660
- } else if (!b) {
2661
- return false
2662
- } else if (a.path && b.path) {
2663
- return a.path.replace(trailingSlashRE, '') === b.path.replace(trailingSlashRE, '') && (onlyPath ||
2664
- a.hash === b.hash &&
2665
- isObjectEqual(a.query, b.query))
2666
- } else if (a.name && b.name) {
2667
- return (
2668
- a.name === b.name &&
2669
- (onlyPath || (
2670
- a.hash === b.hash &&
2671
- isObjectEqual(a.query, b.query) &&
2672
- isObjectEqual(a.params, b.params))
2673
- )
2674
- )
2675
- } else {
2676
- return false
2341
+ var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
2342
+ if (src) {
2343
+ __webpack_require__.p = src[1] // eslint-disable-line
2677
2344
  }
2678
2345
  }
2679
2346
 
2680
- function isObjectEqual (a, b) {
2681
- if ( a === void 0 ) a = {};
2682
- if ( b === void 0 ) b = {};
2347
+ // Indicate to webpack that this file can be concatenated
2348
+ /* harmony default export */ var setPublicPath = (null);
2683
2349
 
2684
- // handle null value #1566
2685
- if (!a || !b) { return a === b }
2686
- var aKeys = Object.keys(a).sort();
2687
- var bKeys = Object.keys(b).sort();
2688
- if (aKeys.length !== bKeys.length) {
2689
- return false
2690
- }
2691
- return aKeys.every(function (key, i) {
2692
- var aVal = a[key];
2693
- var bKey = bKeys[i];
2694
- if (bKey !== key) { return false }
2695
- var bVal = b[key];
2696
- // query values can be null and undefined
2697
- if (aVal == null || bVal == null) { return aVal === bVal }
2698
- // check nested equality
2699
- if (typeof aVal === 'object' && typeof bVal === 'object') {
2700
- return isObjectEqual(aVal, bVal)
2350
+ // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"9ad868ba-vue-loader-template"}!./node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/ecyoa/email/src/index.vue?vue&type=template&id=5e809c44&scoped=true&
2351
+ var render = function render() {
2352
+ var _vm = this,
2353
+ _c = _vm._self._c;
2354
+ return _c('div', {
2355
+ staticClass: "app-wrapper",
2356
+ class: _vm.classObj,
2357
+ on: {
2358
+ "click": _vm.handleBodyOnClick
2701
2359
  }
2702
- return String(aVal) === String(bVal)
2703
- })
2704
- }
2705
-
2706
- function isIncludedRoute (current, target) {
2707
- return (
2708
- current.path.replace(trailingSlashRE, '/').indexOf(
2709
- target.path.replace(trailingSlashRE, '/')
2710
- ) === 0 &&
2711
- (!target.hash || current.hash === target.hash) &&
2712
- queryIncludes(current.query, target.query)
2713
- )
2714
- }
2715
-
2716
- function queryIncludes (current, target) {
2717
- for (var key in target) {
2718
- if (!(key in current)) {
2719
- return false
2360
+ }, [_vm.awaitShow ? _c('LeftMenu', {
2361
+ staticClass: "sidebar-container",
2362
+ on: {
2363
+ "getate": _vm.getate
2720
2364
  }
2721
- }
2722
- return true
2723
- }
2724
-
2725
- function handleRouteEntered (route) {
2726
- for (var i = 0; i < route.matched.length; i++) {
2727
- var record = route.matched[i];
2728
- for (var name in record.instances) {
2729
- var instance = record.instances[name];
2730
- var cbs = record.enteredCbs[name];
2731
- if (!instance || !cbs) { continue }
2732
- delete record.enteredCbs[name];
2733
- for (var i$1 = 0; i$1 < cbs.length; i$1++) {
2734
- if (!instance._isBeingDestroyed) { cbs[i$1](instance); }
2735
- }
2365
+ }) : _vm._e(), _c('div', {
2366
+ staticClass: "main-container",
2367
+ class: {
2368
+ hasTagsView: _vm.needTagsView
2369
+ },
2370
+ staticStyle: {
2371
+ "background": "#F4F6F9"
2736
2372
  }
2737
- }
2738
- }
2739
-
2740
- var View = {
2741
- name: 'RouterView',
2742
- functional: true,
2743
- props: {
2744
- name: {
2745
- type: String,
2746
- default: 'default'
2373
+ }, [_c('div', {
2374
+ class: {
2375
+ 'fixed-header': _vm.fixedHeader
2376
+ },
2377
+ staticStyle: {
2378
+ "position": "relative"
2747
2379
  }
2748
- },
2749
- render: function render (_, ref) {
2750
- var props = ref.props;
2751
- var children = ref.children;
2752
- var parent = ref.parent;
2753
- var data = ref.data;
2754
-
2755
- // used by devtools to display a router-view badge
2756
- data.routerView = true;
2757
-
2758
- // directly use parent context's createElement() function
2759
- // so that components rendered by router-view can resolve named slots
2760
- var h = parent.$createElement;
2761
- var name = props.name;
2762
- var route = parent.$route;
2763
- var cache = parent._routerViewCache || (parent._routerViewCache = {});
2764
-
2765
- // determine current view depth, also check to see if the tree
2766
- // has been toggled inactive but kept-alive.
2767
- var depth = 0;
2768
- var inactive = false;
2769
- while (parent && parent._routerRoot !== parent) {
2770
- var vnodeData = parent.$vnode ? parent.$vnode.data : {};
2771
- if (vnodeData.routerView) {
2772
- depth++;
2773
- }
2774
- if (vnodeData.keepAlive && parent._directInactive && parent._inactive) {
2775
- inactive = true;
2776
- }
2777
- parent = parent.$parent;
2380
+ }, [_vm.needTagsView && _vm.showTopMenus ? _c('tags-view', {
2381
+ ref: "tagsView",
2382
+ staticStyle: {
2383
+ "padding-right": "245px"
2778
2384
  }
2779
- data.routerViewDepth = depth;
2780
-
2781
- // render previous view if the tree is inactive and kept-alive
2782
- if (inactive) {
2783
- var cachedData = cache[name];
2784
- var cachedComponent = cachedData && cachedData.component;
2785
- if (cachedComponent) {
2786
- // #2301
2787
- // pass props
2788
- if (cachedData.configProps) {
2789
- fillPropsinData(cachedComponent, data, cachedData.route, cachedData.configProps);
2790
- }
2791
- return h(cachedComponent, data, children)
2792
- } else {
2793
- // render previous empty view
2794
- return h()
2385
+ }) : _vm._e(), _vm.show ? _c('div', {
2386
+ staticClass: "headInfo"
2387
+ }, [_c('div', {
2388
+ ref: "imgHead",
2389
+ staticStyle: {
2390
+ "cursor": "pointer"
2391
+ },
2392
+ on: {
2393
+ "click": function click($event) {
2394
+ _vm.accountDialog = !_vm.accountDialog;
2795
2395
  }
2796
2396
  }
2797
-
2798
- var matched = route.matched[depth];
2799
- var component = matched && matched.components[name];
2800
-
2801
- // render empty node if no matched route or no config component
2802
- if (!matched || !component) {
2803
- cache[name] = null;
2804
- return h()
2805
- }
2806
-
2807
- // cache component
2808
- cache[name] = { component: component };
2809
-
2810
- // attach instance registration hook
2811
- // this will be called in the instance's injected lifecycle hooks
2812
- data.registerRouteInstance = function (vm, val) {
2813
- // val could be undefined for unregistration
2814
- var current = matched.instances[name];
2815
- if (
2816
- (val && current !== vm) ||
2817
- (!val && current === vm)
2818
- ) {
2819
- matched.instances[name] = val;
2820
- }
2397
+ }, [_c('div', {
2398
+ staticStyle: {
2399
+ "max-width": "200px",
2400
+ "display": "inline-block",
2401
+ "position": "absolute",
2402
+ "top": "16px",
2403
+ "right": "46px"
2821
2404
  }
2822
-
2823
- // also register instance in prepatch hook
2824
- // in case the same component instance is reused across different routes
2825
- ;(data.hook || (data.hook = {})).prepatch = function (_, vnode) {
2826
- matched.instances[name] = vnode.componentInstance;
2827
- };
2828
-
2829
- // register instance in init hook
2830
- // in case kept-alive component be actived when routes changed
2831
- data.hook.init = function (vnode) {
2832
- if (vnode.data.keepAlive &&
2833
- vnode.componentInstance &&
2834
- vnode.componentInstance !== matched.instances[name]
2835
- ) {
2836
- matched.instances[name] = vnode.componentInstance;
2837
- }
2838
-
2839
- // if the route transition has already been confirmed then we weren't
2840
- // able to call the cbs during confirmation as the component was not
2841
- // registered yet, so we call it here.
2842
- handleRouteEntered(route);
2843
- };
2844
-
2845
- var configProps = matched.props && matched.props[name];
2846
- // save route and configProps in cache
2847
- if (configProps) {
2848
- extend(cache[name], {
2849
- route: route,
2850
- configProps: configProps
2851
- });
2852
- fillPropsinData(component, data, route, configProps);
2405
+ }, [_vm.valueHead !== null ? _c('div', {
2406
+ staticClass: "imgHead2",
2407
+ style: {
2408
+ 'background-color': _vm.colorDisplay(_vm.valueHead)
2853
2409
  }
2854
-
2855
- return h(component, data, children)
2856
- }
2857
- };
2858
-
2859
- function fillPropsinData (component, data, route, configProps) {
2860
- // resolve props
2861
- var propsToPass = data.props = resolveProps(route, configProps);
2862
- if (propsToPass) {
2863
- // clone to prevent mutation
2864
- propsToPass = data.props = extend({}, propsToPass);
2865
- // pass non-declared props as attrs
2866
- var attrs = data.attrs = data.attrs || {};
2867
- for (var key in propsToPass) {
2868
- if (!component.props || !(key in component.props)) {
2869
- attrs[key] = propsToPass[key];
2870
- delete propsToPass[key];
2871
- }
2872
- }
2873
- }
2874
- }
2875
-
2876
- function resolveProps (route, config) {
2877
- switch (typeof config) {
2878
- case 'undefined':
2879
- return
2880
- case 'object':
2881
- return config
2882
- case 'function':
2883
- return config(route)
2884
- case 'boolean':
2885
- return config ? route.params : undefined
2886
- default:
2887
- if (false) {}
2888
- }
2889
- }
2890
-
2891
- /* */
2892
-
2893
- function resolvePath (
2894
- relative,
2895
- base,
2896
- append
2897
- ) {
2898
- var firstChar = relative.charAt(0);
2899
- if (firstChar === '/') {
2900
- return relative
2901
- }
2902
-
2903
- if (firstChar === '?' || firstChar === '#') {
2904
- return base + relative
2905
- }
2906
-
2907
- var stack = base.split('/');
2908
-
2909
- // remove trailing segment if:
2910
- // - not appending
2911
- // - appending to trailing slash (last segment is empty)
2912
- if (!append || !stack[stack.length - 1]) {
2913
- stack.pop();
2914
- }
2915
-
2916
- // resolve relative path
2917
- var segments = relative.replace(/^\//, '').split('/');
2918
- for (var i = 0; i < segments.length; i++) {
2919
- var segment = segments[i];
2920
- if (segment === '..') {
2921
- stack.pop();
2922
- } else if (segment !== '.') {
2923
- stack.push(segment);
2924
- }
2925
- }
2926
-
2927
- // ensure leading slash
2928
- if (stack[0] !== '') {
2929
- stack.unshift('');
2930
- }
2931
-
2932
- return stack.join('/')
2933
- }
2934
-
2935
- function parsePath (path) {
2936
- var hash = '';
2937
- var query = '';
2938
-
2939
- var hashIndex = path.indexOf('#');
2940
- if (hashIndex >= 0) {
2941
- hash = path.slice(hashIndex);
2942
- path = path.slice(0, hashIndex);
2943
- }
2944
-
2945
- var queryIndex = path.indexOf('?');
2946
- if (queryIndex >= 0) {
2947
- query = path.slice(queryIndex + 1);
2948
- path = path.slice(0, queryIndex);
2949
- }
2950
-
2951
- return {
2952
- path: path,
2953
- query: query,
2954
- hash: hash
2955
- }
2956
- }
2957
-
2958
- function cleanPath (path) {
2959
- return path.replace(/\/(?:\s*\/)+/g, '/')
2960
- }
2961
-
2962
- var isarray = Array.isArray || function (arr) {
2963
- return Object.prototype.toString.call(arr) == '[object Array]';
2964
- };
2965
-
2966
- /**
2967
- * Expose `pathToRegexp`.
2968
- */
2969
- var pathToRegexp_1 = pathToRegexp;
2970
- var parse_1 = parse;
2971
- var compile_1 = compile;
2972
- var tokensToFunction_1 = tokensToFunction;
2973
- var tokensToRegExp_1 = tokensToRegExp;
2974
-
2975
- /**
2976
- * The main path matching regexp utility.
2977
- *
2978
- * @type {RegExp}
2979
- */
2980
- var PATH_REGEXP = new RegExp([
2981
- // Match escaped characters that would otherwise appear in future matches.
2982
- // This allows the user to escape special characters that won't transform.
2983
- '(\\\\.)',
2984
- // Match Express-style parameters and un-named parameters with a prefix
2985
- // and optional suffixes. Matches appear as:
2986
- //
2987
- // "/:test(\\d+)?" => ["/", "test", "\d+", undefined, "?", undefined]
2988
- // "/route(\\d+)" => [undefined, undefined, undefined, "\d+", undefined, undefined]
2989
- // "/*" => ["/", undefined, undefined, undefined, undefined, "*"]
2990
- '([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))'
2991
- ].join('|'), 'g');
2992
-
2993
- /**
2994
- * Parse a string for the raw tokens.
2995
- *
2996
- * @param {string} str
2997
- * @param {Object=} options
2998
- * @return {!Array}
2999
- */
3000
- function parse (str, options) {
3001
- var tokens = [];
3002
- var key = 0;
3003
- var index = 0;
3004
- var path = '';
3005
- var defaultDelimiter = options && options.delimiter || '/';
3006
- var res;
3007
-
3008
- while ((res = PATH_REGEXP.exec(str)) != null) {
3009
- var m = res[0];
3010
- var escaped = res[1];
3011
- var offset = res.index;
3012
- path += str.slice(index, offset);
3013
- index = offset + m.length;
3014
-
3015
- // Ignore already escaped sequences.
3016
- if (escaped) {
3017
- path += escaped[1];
3018
- continue
3019
- }
3020
-
3021
- var next = str[index];
3022
- var prefix = res[2];
3023
- var name = res[3];
3024
- var capture = res[4];
3025
- var group = res[5];
3026
- var modifier = res[6];
3027
- var asterisk = res[7];
3028
-
3029
- // Push the current path onto the tokens.
3030
- if (path) {
3031
- tokens.push(path);
3032
- path = '';
3033
- }
3034
-
3035
- var partial = prefix != null && next != null && next !== prefix;
3036
- var repeat = modifier === '+' || modifier === '*';
3037
- var optional = modifier === '?' || modifier === '*';
3038
- var delimiter = res[2] || defaultDelimiter;
3039
- var pattern = capture || group;
3040
-
3041
- tokens.push({
3042
- name: name || key++,
3043
- prefix: prefix || '',
3044
- delimiter: delimiter,
3045
- optional: optional,
3046
- repeat: repeat,
3047
- partial: partial,
3048
- asterisk: !!asterisk,
3049
- pattern: pattern ? escapeGroup(pattern) : (asterisk ? '.*' : '[^' + escapeString(delimiter) + ']+?')
3050
- });
3051
- }
3052
-
3053
- // Match any characters still remaining.
3054
- if (index < str.length) {
3055
- path += str.substr(index);
3056
- }
3057
-
3058
- // If the path exists, push it onto the end.
3059
- if (path) {
3060
- tokens.push(path);
3061
- }
3062
-
3063
- return tokens
3064
- }
3065
-
3066
- /**
3067
- * Compile a string to a template function for the path.
3068
- *
3069
- * @param {string} str
3070
- * @param {Object=} options
3071
- * @return {!function(Object=, Object=)}
3072
- */
3073
- function compile (str, options) {
3074
- return tokensToFunction(parse(str, options), options)
3075
- }
3076
-
3077
- /**
3078
- * Prettier encoding of URI path segments.
3079
- *
3080
- * @param {string}
3081
- * @return {string}
3082
- */
3083
- function encodeURIComponentPretty (str) {
3084
- return encodeURI(str).replace(/[\/?#]/g, function (c) {
3085
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
3086
- })
3087
- }
3088
-
3089
- /**
3090
- * Encode the asterisk parameter. Similar to `pretty`, but allows slashes.
3091
- *
3092
- * @param {string}
3093
- * @return {string}
3094
- */
3095
- function encodeAsterisk (str) {
3096
- return encodeURI(str).replace(/[?#]/g, function (c) {
3097
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
3098
- })
3099
- }
3100
-
3101
- /**
3102
- * Expose a method for transforming tokens into the path function.
3103
- */
3104
- function tokensToFunction (tokens, options) {
3105
- // Compile all the tokens into regexps.
3106
- var matches = new Array(tokens.length);
3107
-
3108
- // Compile all the patterns before compilation.
3109
- for (var i = 0; i < tokens.length; i++) {
3110
- if (typeof tokens[i] === 'object') {
3111
- matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options));
3112
- }
3113
- }
3114
-
3115
- return function (obj, opts) {
3116
- var path = '';
3117
- var data = obj || {};
3118
- var options = opts || {};
3119
- var encode = options.pretty ? encodeURIComponentPretty : encodeURIComponent;
3120
-
3121
- for (var i = 0; i < tokens.length; i++) {
3122
- var token = tokens[i];
3123
-
3124
- if (typeof token === 'string') {
3125
- path += token;
3126
-
3127
- continue
3128
- }
3129
-
3130
- var value = data[token.name];
3131
- var segment;
3132
-
3133
- if (value == null) {
3134
- if (token.optional) {
3135
- // Prepend partial segment prefixes.
3136
- if (token.partial) {
3137
- path += token.prefix;
3138
- }
3139
-
3140
- continue
3141
- } else {
3142
- throw new TypeError('Expected "' + token.name + '" to be defined')
3143
- }
3144
- }
3145
-
3146
- if (isarray(value)) {
3147
- if (!token.repeat) {
3148
- throw new TypeError('Expected "' + token.name + '" to not repeat, but received `' + JSON.stringify(value) + '`')
3149
- }
3150
-
3151
- if (value.length === 0) {
3152
- if (token.optional) {
3153
- continue
3154
- } else {
3155
- throw new TypeError('Expected "' + token.name + '" to not be empty')
3156
- }
3157
- }
3158
-
3159
- for (var j = 0; j < value.length; j++) {
3160
- segment = encode(value[j]);
3161
-
3162
- if (!matches[i].test(segment)) {
3163
- throw new TypeError('Expected all "' + token.name + '" to match "' + token.pattern + '", but received `' + JSON.stringify(segment) + '`')
3164
- }
3165
-
3166
- path += (j === 0 ? token.prefix : token.delimiter) + segment;
3167
- }
3168
-
3169
- continue
3170
- }
3171
-
3172
- segment = token.asterisk ? encodeAsterisk(value) : encode(value);
3173
-
3174
- if (!matches[i].test(segment)) {
3175
- throw new TypeError('Expected "' + token.name + '" to match "' + token.pattern + '", but received "' + segment + '"')
3176
- }
3177
-
3178
- path += token.prefix + segment;
3179
- }
3180
-
3181
- return path
3182
- }
3183
- }
3184
-
3185
- /**
3186
- * Escape a regular expression string.
3187
- *
3188
- * @param {string} str
3189
- * @return {string}
3190
- */
3191
- function escapeString (str) {
3192
- return str.replace(/([.+*?=^!:${}()[\]|\/\\])/g, '\\$1')
3193
- }
3194
-
3195
- /**
3196
- * Escape the capturing group by escaping special characters and meaning.
3197
- *
3198
- * @param {string} group
3199
- * @return {string}
3200
- */
3201
- function escapeGroup (group) {
3202
- return group.replace(/([=!:$\/()])/g, '\\$1')
3203
- }
3204
-
3205
- /**
3206
- * Attach the keys as a property of the regexp.
3207
- *
3208
- * @param {!RegExp} re
3209
- * @param {Array} keys
3210
- * @return {!RegExp}
3211
- */
3212
- function attachKeys (re, keys) {
3213
- re.keys = keys;
3214
- return re
3215
- }
3216
-
3217
- /**
3218
- * Get the flags for a regexp from the options.
3219
- *
3220
- * @param {Object} options
3221
- * @return {string}
3222
- */
3223
- function flags (options) {
3224
- return options && options.sensitive ? '' : 'i'
3225
- }
3226
-
3227
- /**
3228
- * Pull out keys from a regexp.
3229
- *
3230
- * @param {!RegExp} path
3231
- * @param {!Array} keys
3232
- * @return {!RegExp}
3233
- */
3234
- function regexpToRegexp (path, keys) {
3235
- // Use a negative lookahead to match only capturing groups.
3236
- var groups = path.source.match(/\((?!\?)/g);
3237
-
3238
- if (groups) {
3239
- for (var i = 0; i < groups.length; i++) {
3240
- keys.push({
3241
- name: i,
3242
- prefix: null,
3243
- delimiter: null,
3244
- optional: false,
3245
- repeat: false,
3246
- partial: false,
3247
- asterisk: false,
3248
- pattern: null
3249
- });
3250
- }
3251
- }
3252
-
3253
- return attachKeys(path, keys)
3254
- }
3255
-
3256
- /**
3257
- * Transform an array into a regexp.
3258
- *
3259
- * @param {!Array} path
3260
- * @param {Array} keys
3261
- * @param {!Object} options
3262
- * @return {!RegExp}
3263
- */
3264
- function arrayToRegexp (path, keys, options) {
3265
- var parts = [];
3266
-
3267
- for (var i = 0; i < path.length; i++) {
3268
- parts.push(pathToRegexp(path[i], keys, options).source);
3269
- }
3270
-
3271
- var regexp = new RegExp('(?:' + parts.join('|') + ')', flags(options));
3272
-
3273
- return attachKeys(regexp, keys)
3274
- }
3275
-
3276
- /**
3277
- * Create a path regexp from string input.
3278
- *
3279
- * @param {string} path
3280
- * @param {!Array} keys
3281
- * @param {!Object} options
3282
- * @return {!RegExp}
3283
- */
3284
- function stringToRegexp (path, keys, options) {
3285
- return tokensToRegExp(parse(path, options), keys, options)
3286
- }
3287
-
3288
- /**
3289
- * Expose a function for taking tokens and returning a RegExp.
3290
- *
3291
- * @param {!Array} tokens
3292
- * @param {(Array|Object)=} keys
3293
- * @param {Object=} options
3294
- * @return {!RegExp}
3295
- */
3296
- function tokensToRegExp (tokens, keys, options) {
3297
- if (!isarray(keys)) {
3298
- options = /** @type {!Object} */ (keys || options);
3299
- keys = [];
3300
- }
3301
-
3302
- options = options || {};
3303
-
3304
- var strict = options.strict;
3305
- var end = options.end !== false;
3306
- var route = '';
3307
-
3308
- // Iterate over the tokens and create our regexp string.
3309
- for (var i = 0; i < tokens.length; i++) {
3310
- var token = tokens[i];
3311
-
3312
- if (typeof token === 'string') {
3313
- route += escapeString(token);
3314
- } else {
3315
- var prefix = escapeString(token.prefix);
3316
- var capture = '(?:' + token.pattern + ')';
3317
-
3318
- keys.push(token);
3319
-
3320
- if (token.repeat) {
3321
- capture += '(?:' + prefix + capture + ')*';
3322
- }
3323
-
3324
- if (token.optional) {
3325
- if (!token.partial) {
3326
- capture = '(?:' + prefix + '(' + capture + '))?';
3327
- } else {
3328
- capture = prefix + '(' + capture + ')?';
3329
- }
3330
- } else {
3331
- capture = prefix + '(' + capture + ')';
3332
- }
3333
-
3334
- route += capture;
3335
- }
3336
- }
3337
-
3338
- var delimiter = escapeString(options.delimiter || '/');
3339
- var endsWithDelimiter = route.slice(-delimiter.length) === delimiter;
3340
-
3341
- // In non-strict mode we allow a slash at the end of match. If the path to
3342
- // match already ends with a slash, we remove it for consistency. The slash
3343
- // is valid at the end of a path match, not in the middle. This is important
3344
- // in non-ending mode, where "/test/" shouldn't match "/test//route".
3345
- if (!strict) {
3346
- route = (endsWithDelimiter ? route.slice(0, -delimiter.length) : route) + '(?:' + delimiter + '(?=$))?';
3347
- }
3348
-
3349
- if (end) {
3350
- route += '$';
3351
- } else {
3352
- // In non-ending mode, we need the capturing groups to match as much as
3353
- // possible by using a positive lookahead to the end or next path segment.
3354
- route += strict && endsWithDelimiter ? '' : '(?=' + delimiter + '|$)';
3355
- }
3356
-
3357
- return attachKeys(new RegExp('^' + route, flags(options)), keys)
3358
- }
3359
-
3360
- /**
3361
- * Normalize the given path string, returning a regular expression.
3362
- *
3363
- * An empty array can be passed in for the keys, which will hold the
3364
- * placeholder key descriptions. For example, using `/user/:id`, `keys` will
3365
- * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
3366
- *
3367
- * @param {(string|RegExp|Array)} path
3368
- * @param {(Array|Object)=} keys
3369
- * @param {Object=} options
3370
- * @return {!RegExp}
3371
- */
3372
- function pathToRegexp (path, keys, options) {
3373
- if (!isarray(keys)) {
3374
- options = /** @type {!Object} */ (keys || options);
3375
- keys = [];
3376
- }
3377
-
3378
- options = options || {};
3379
-
3380
- if (path instanceof RegExp) {
3381
- return regexpToRegexp(path, /** @type {!Array} */ (keys))
3382
- }
3383
-
3384
- if (isarray(path)) {
3385
- return arrayToRegexp(/** @type {!Array} */ (path), /** @type {!Array} */ (keys), options)
3386
- }
3387
-
3388
- return stringToRegexp(/** @type {string} */ (path), /** @type {!Array} */ (keys), options)
3389
- }
3390
- pathToRegexp_1.parse = parse_1;
3391
- pathToRegexp_1.compile = compile_1;
3392
- pathToRegexp_1.tokensToFunction = tokensToFunction_1;
3393
- pathToRegexp_1.tokensToRegExp = tokensToRegExp_1;
3394
-
3395
- /* */
3396
-
3397
- // $flow-disable-line
3398
- var regexpCompileCache = Object.create(null);
3399
-
3400
- function fillParams (
3401
- path,
3402
- params,
3403
- routeMsg
3404
- ) {
3405
- params = params || {};
3406
- try {
3407
- var filler =
3408
- regexpCompileCache[path] ||
3409
- (regexpCompileCache[path] = pathToRegexp_1.compile(path));
3410
-
3411
- // Fix #2505 resolving asterisk routes { name: 'not-found', params: { pathMatch: '/not-found' }}
3412
- // and fix #3106 so that you can work with location descriptor object having params.pathMatch equal to empty string
3413
- if (typeof params.pathMatch === 'string') { params[0] = params.pathMatch; }
3414
-
3415
- return filler(params, { pretty: true })
3416
- } catch (e) {
3417
- if (false) {}
3418
- return ''
3419
- } finally {
3420
- // delete the 0 if it was added
3421
- delete params[0];
3422
- }
3423
- }
3424
-
3425
- /* */
3426
-
3427
- function normalizeLocation (
3428
- raw,
3429
- current,
3430
- append,
3431
- router
3432
- ) {
3433
- var next = typeof raw === 'string' ? { path: raw } : raw;
3434
- // named target
3435
- if (next._normalized) {
3436
- return next
3437
- } else if (next.name) {
3438
- next = extend({}, raw);
3439
- var params = next.params;
3440
- if (params && typeof params === 'object') {
3441
- next.params = extend({}, params);
3442
- }
3443
- return next
3444
- }
3445
-
3446
- // relative params
3447
- if (!next.path && next.params && current) {
3448
- next = extend({}, next);
3449
- next._normalized = true;
3450
- var params$1 = extend(extend({}, current.params), next.params);
3451
- if (current.name) {
3452
- next.name = current.name;
3453
- next.params = params$1;
3454
- } else if (current.matched.length) {
3455
- var rawPath = current.matched[current.matched.length - 1].path;
3456
- next.path = fillParams(rawPath, params$1, ("path " + (current.path)));
3457
- } else if (false) {}
3458
- return next
3459
- }
3460
-
3461
- var parsedPath = parsePath(next.path || '');
3462
- var basePath = (current && current.path) || '/';
3463
- var path = parsedPath.path
3464
- ? resolvePath(parsedPath.path, basePath, append || next.append)
3465
- : basePath;
3466
-
3467
- var query = resolveQuery(
3468
- parsedPath.query,
3469
- next.query,
3470
- router && router.options.parseQuery
3471
- );
3472
-
3473
- var hash = next.hash || parsedPath.hash;
3474
- if (hash && hash.charAt(0) !== '#') {
3475
- hash = "#" + hash;
3476
- }
3477
-
3478
- return {
3479
- _normalized: true,
3480
- path: path,
3481
- query: query,
3482
- hash: hash
3483
- }
3484
- }
3485
-
3486
- /* */
3487
-
3488
- // work around weird flow bug
3489
- var toTypes = [String, Object];
3490
- var eventTypes = [String, Array];
3491
-
3492
- var noop = function () {};
3493
-
3494
- var warnedCustomSlot;
3495
- var warnedTagProp;
3496
- var warnedEventProp;
3497
-
3498
- var Link = {
3499
- name: 'RouterLink',
3500
- props: {
3501
- to: {
3502
- type: toTypes,
3503
- required: true
3504
- },
3505
- tag: {
3506
- type: String,
3507
- default: 'a'
3508
- },
3509
- custom: Boolean,
3510
- exact: Boolean,
3511
- exactPath: Boolean,
3512
- append: Boolean,
3513
- replace: Boolean,
3514
- activeClass: String,
3515
- exactActiveClass: String,
3516
- ariaCurrentValue: {
3517
- type: String,
3518
- default: 'page'
3519
- },
3520
- event: {
3521
- type: eventTypes,
3522
- default: 'click'
3523
- }
3524
- },
3525
- render: function render (h) {
3526
- var this$1$1 = this;
3527
-
3528
- var router = this.$router;
3529
- var current = this.$route;
3530
- var ref = router.resolve(
3531
- this.to,
3532
- current,
3533
- this.append
3534
- );
3535
- var location = ref.location;
3536
- var route = ref.route;
3537
- var href = ref.href;
3538
-
3539
- var classes = {};
3540
- var globalActiveClass = router.options.linkActiveClass;
3541
- var globalExactActiveClass = router.options.linkExactActiveClass;
3542
- // Support global empty active class
3543
- var activeClassFallback =
3544
- globalActiveClass == null ? 'router-link-active' : globalActiveClass;
3545
- var exactActiveClassFallback =
3546
- globalExactActiveClass == null
3547
- ? 'router-link-exact-active'
3548
- : globalExactActiveClass;
3549
- var activeClass =
3550
- this.activeClass == null ? activeClassFallback : this.activeClass;
3551
- var exactActiveClass =
3552
- this.exactActiveClass == null
3553
- ? exactActiveClassFallback
3554
- : this.exactActiveClass;
3555
-
3556
- var compareTarget = route.redirectedFrom
3557
- ? createRoute(null, normalizeLocation(route.redirectedFrom), null, router)
3558
- : route;
3559
-
3560
- classes[exactActiveClass] = isSameRoute(current, compareTarget, this.exactPath);
3561
- classes[activeClass] = this.exact || this.exactPath
3562
- ? classes[exactActiveClass]
3563
- : isIncludedRoute(current, compareTarget);
3564
-
3565
- var ariaCurrentValue = classes[exactActiveClass] ? this.ariaCurrentValue : null;
3566
-
3567
- var handler = function (e) {
3568
- if (guardEvent(e)) {
3569
- if (this$1$1.replace) {
3570
- router.replace(location, noop);
3571
- } else {
3572
- router.push(location, noop);
3573
- }
3574
- }
3575
- };
3576
-
3577
- var on = { click: guardEvent };
3578
- if (Array.isArray(this.event)) {
3579
- this.event.forEach(function (e) {
3580
- on[e] = handler;
3581
- });
3582
- } else {
3583
- on[this.event] = handler;
3584
- }
3585
-
3586
- var data = { class: classes };
3587
-
3588
- var scopedSlot =
3589
- !this.$scopedSlots.$hasNormal &&
3590
- this.$scopedSlots.default &&
3591
- this.$scopedSlots.default({
3592
- href: href,
3593
- route: route,
3594
- navigate: handler,
3595
- isActive: classes[activeClass],
3596
- isExactActive: classes[exactActiveClass]
3597
- });
3598
-
3599
- if (scopedSlot) {
3600
- if (false) {}
3601
- if (scopedSlot.length === 1) {
3602
- return scopedSlot[0]
3603
- } else if (scopedSlot.length > 1 || !scopedSlot.length) {
3604
- if (false) {}
3605
- return scopedSlot.length === 0 ? h() : h('span', {}, scopedSlot)
3606
- }
3607
- }
3608
-
3609
- if (false) {}
3610
-
3611
- if (this.tag === 'a') {
3612
- data.on = on;
3613
- data.attrs = { href: href, 'aria-current': ariaCurrentValue };
3614
- } else {
3615
- // find the first <a> child and apply listener and href
3616
- var a = findAnchor(this.$slots.default);
3617
- if (a) {
3618
- // in case the <a> is a static node
3619
- a.isStatic = false;
3620
- var aData = (a.data = extend({}, a.data));
3621
- aData.on = aData.on || {};
3622
- // transform existing events in both objects into arrays so we can push later
3623
- for (var event in aData.on) {
3624
- var handler$1 = aData.on[event];
3625
- if (event in on) {
3626
- aData.on[event] = Array.isArray(handler$1) ? handler$1 : [handler$1];
3627
- }
3628
- }
3629
- // append new listeners for router-link
3630
- for (var event$1 in on) {
3631
- if (event$1 in aData.on) {
3632
- // on[event] is always a function
3633
- aData.on[event$1].push(on[event$1]);
3634
- } else {
3635
- aData.on[event$1] = handler;
3636
- }
3637
- }
3638
-
3639
- var aAttrs = (a.data.attrs = extend({}, a.data.attrs));
3640
- aAttrs.href = href;
3641
- aAttrs['aria-current'] = ariaCurrentValue;
3642
- } else {
3643
- // doesn't have <a> child, apply listener to self
3644
- data.on = on;
3645
- }
3646
- }
3647
-
3648
- return h(this.tag, data, this.$slots.default)
3649
- }
3650
- };
3651
-
3652
- function guardEvent (e) {
3653
- // don't redirect with control keys
3654
- if (e.metaKey || e.altKey || e.ctrlKey || e.shiftKey) { return }
3655
- // don't redirect when preventDefault called
3656
- if (e.defaultPrevented) { return }
3657
- // don't redirect on right click
3658
- if (e.button !== undefined && e.button !== 0) { return }
3659
- // don't redirect if `target="_blank"`
3660
- if (e.currentTarget && e.currentTarget.getAttribute) {
3661
- var target = e.currentTarget.getAttribute('target');
3662
- if (/\b_blank\b/i.test(target)) { return }
3663
- }
3664
- // this may be a Weex event which doesn't have this method
3665
- if (e.preventDefault) {
3666
- e.preventDefault();
3667
- }
3668
- return true
3669
- }
3670
-
3671
- function findAnchor (children) {
3672
- if (children) {
3673
- var child;
3674
- for (var i = 0; i < children.length; i++) {
3675
- child = children[i];
3676
- if (child.tag === 'a') {
3677
- return child
3678
- }
3679
- if (child.children && (child = findAnchor(child.children))) {
3680
- return child
3681
- }
3682
- }
3683
- }
3684
- }
3685
-
3686
- var _Vue;
3687
-
3688
- function install (Vue) {
3689
- if (install.installed && _Vue === Vue) { return }
3690
- install.installed = true;
3691
-
3692
- _Vue = Vue;
3693
-
3694
- var isDef = function (v) { return v !== undefined; };
3695
-
3696
- var registerInstance = function (vm, callVal) {
3697
- var i = vm.$options._parentVnode;
3698
- if (isDef(i) && isDef(i = i.data) && isDef(i = i.registerRouteInstance)) {
3699
- i(vm, callVal);
3700
- }
3701
- };
3702
-
3703
- Vue.mixin({
3704
- beforeCreate: function beforeCreate () {
3705
- if (isDef(this.$options.router)) {
3706
- this._routerRoot = this;
3707
- this._router = this.$options.router;
3708
- this._router.init(this);
3709
- Vue.util.defineReactive(this, '_route', this._router.history.current);
3710
- } else {
3711
- this._routerRoot = (this.$parent && this.$parent._routerRoot) || this;
3712
- }
3713
- registerInstance(this, this);
3714
- },
3715
- destroyed: function destroyed () {
3716
- registerInstance(this);
3717
- }
3718
- });
3719
-
3720
- Object.defineProperty(Vue.prototype, '$router', {
3721
- get: function get () { return this._routerRoot._router }
3722
- });
3723
-
3724
- Object.defineProperty(Vue.prototype, '$route', {
3725
- get: function get () { return this._routerRoot._route }
3726
- });
3727
-
3728
- Vue.component('RouterView', View);
3729
- Vue.component('RouterLink', Link);
3730
-
3731
- var strats = Vue.config.optionMergeStrategies;
3732
- // use the same hook merging strategy for route hooks
3733
- strats.beforeRouteEnter = strats.beforeRouteLeave = strats.beforeRouteUpdate = strats.created;
3734
- }
3735
-
3736
- /* */
3737
-
3738
- var inBrowser = typeof window !== 'undefined';
3739
-
3740
- /* */
3741
-
3742
- function createRouteMap (
3743
- routes,
3744
- oldPathList,
3745
- oldPathMap,
3746
- oldNameMap,
3747
- parentRoute
3748
- ) {
3749
- // the path list is used to control path matching priority
3750
- var pathList = oldPathList || [];
3751
- // $flow-disable-line
3752
- var pathMap = oldPathMap || Object.create(null);
3753
- // $flow-disable-line
3754
- var nameMap = oldNameMap || Object.create(null);
3755
-
3756
- routes.forEach(function (route) {
3757
- addRouteRecord(pathList, pathMap, nameMap, route, parentRoute);
3758
- });
3759
-
3760
- // ensure wildcard routes are always at the end
3761
- for (var i = 0, l = pathList.length; i < l; i++) {
3762
- if (pathList[i] === '*') {
3763
- pathList.push(pathList.splice(i, 1)[0]);
3764
- l--;
3765
- i--;
3766
- }
3767
- }
3768
-
3769
- if (false) { var pathNames, found; }
3770
-
3771
- return {
3772
- pathList: pathList,
3773
- pathMap: pathMap,
3774
- nameMap: nameMap
3775
- }
3776
- }
3777
-
3778
- function addRouteRecord (
3779
- pathList,
3780
- pathMap,
3781
- nameMap,
3782
- route,
3783
- parent,
3784
- matchAs
3785
- ) {
3786
- var path = route.path;
3787
- var name = route.name;
3788
- if (false) {}
3789
-
3790
- var pathToRegexpOptions =
3791
- route.pathToRegexpOptions || {};
3792
- var normalizedPath = normalizePath(path, parent, pathToRegexpOptions.strict);
3793
-
3794
- if (typeof route.caseSensitive === 'boolean') {
3795
- pathToRegexpOptions.sensitive = route.caseSensitive;
3796
- }
3797
-
3798
- var record = {
3799
- path: normalizedPath,
3800
- regex: compileRouteRegex(normalizedPath, pathToRegexpOptions),
3801
- components: route.components || { default: route.component },
3802
- alias: route.alias
3803
- ? typeof route.alias === 'string'
3804
- ? [route.alias]
3805
- : route.alias
3806
- : [],
3807
- instances: {},
3808
- enteredCbs: {},
3809
- name: name,
3810
- parent: parent,
3811
- matchAs: matchAs,
3812
- redirect: route.redirect,
3813
- beforeEnter: route.beforeEnter,
3814
- meta: route.meta || {},
3815
- props:
3816
- route.props == null
3817
- ? {}
3818
- : route.components
3819
- ? route.props
3820
- : { default: route.props }
3821
- };
3822
-
3823
- if (route.children) {
3824
- // Warn if route is named, does not redirect and has a default child route.
3825
- // If users navigate to this route by name, the default child will
3826
- // not be rendered (GH Issue #629)
3827
- if (false) {}
3828
- route.children.forEach(function (child) {
3829
- var childMatchAs = matchAs
3830
- ? cleanPath((matchAs + "/" + (child.path)))
3831
- : undefined;
3832
- addRouteRecord(pathList, pathMap, nameMap, child, record, childMatchAs);
3833
- });
3834
- }
3835
-
3836
- if (!pathMap[record.path]) {
3837
- pathList.push(record.path);
3838
- pathMap[record.path] = record;
3839
- }
3840
-
3841
- if (route.alias !== undefined) {
3842
- var aliases = Array.isArray(route.alias) ? route.alias : [route.alias];
3843
- for (var i = 0; i < aliases.length; ++i) {
3844
- var alias = aliases[i];
3845
- if (false) {}
3846
-
3847
- var aliasRoute = {
3848
- path: alias,
3849
- children: route.children
3850
- };
3851
- addRouteRecord(
3852
- pathList,
3853
- pathMap,
3854
- nameMap,
3855
- aliasRoute,
3856
- parent,
3857
- record.path || '/' // matchAs
3858
- );
3859
- }
3860
- }
3861
-
3862
- if (name) {
3863
- if (!nameMap[name]) {
3864
- nameMap[name] = record;
3865
- } else if (false) {}
3866
- }
3867
- }
3868
-
3869
- function compileRouteRegex (
3870
- path,
3871
- pathToRegexpOptions
3872
- ) {
3873
- var regex = pathToRegexp_1(path, [], pathToRegexpOptions);
3874
- if (false) { var keys; }
3875
- return regex
3876
- }
3877
-
3878
- function normalizePath (
3879
- path,
3880
- parent,
3881
- strict
3882
- ) {
3883
- if (!strict) { path = path.replace(/\/$/, ''); }
3884
- if (path[0] === '/') { return path }
3885
- if (parent == null) { return path }
3886
- return cleanPath(((parent.path) + "/" + path))
3887
- }
3888
-
3889
- /* */
3890
-
3891
-
3892
-
3893
- function createMatcher (
3894
- routes,
3895
- router
3896
- ) {
3897
- var ref = createRouteMap(routes);
3898
- var pathList = ref.pathList;
3899
- var pathMap = ref.pathMap;
3900
- var nameMap = ref.nameMap;
3901
-
3902
- function addRoutes (routes) {
3903
- createRouteMap(routes, pathList, pathMap, nameMap);
3904
- }
3905
-
3906
- function addRoute (parentOrRoute, route) {
3907
- var parent = (typeof parentOrRoute !== 'object') ? nameMap[parentOrRoute] : undefined;
3908
- // $flow-disable-line
3909
- createRouteMap([route || parentOrRoute], pathList, pathMap, nameMap, parent);
3910
-
3911
- // add aliases of parent
3912
- if (parent && parent.alias.length) {
3913
- createRouteMap(
3914
- // $flow-disable-line route is defined if parent is
3915
- parent.alias.map(function (alias) { return ({ path: alias, children: [route] }); }),
3916
- pathList,
3917
- pathMap,
3918
- nameMap,
3919
- parent
3920
- );
3921
- }
3922
- }
3923
-
3924
- function getRoutes () {
3925
- return pathList.map(function (path) { return pathMap[path]; })
3926
- }
3927
-
3928
- function match (
3929
- raw,
3930
- currentRoute,
3931
- redirectedFrom
3932
- ) {
3933
- var location = normalizeLocation(raw, currentRoute, false, router);
3934
- var name = location.name;
3935
-
3936
- if (name) {
3937
- var record = nameMap[name];
3938
- if (false) {}
3939
- if (!record) { return _createRoute(null, location) }
3940
- var paramNames = record.regex.keys
3941
- .filter(function (key) { return !key.optional; })
3942
- .map(function (key) { return key.name; });
3943
-
3944
- if (typeof location.params !== 'object') {
3945
- location.params = {};
3946
- }
3947
-
3948
- if (currentRoute && typeof currentRoute.params === 'object') {
3949
- for (var key in currentRoute.params) {
3950
- if (!(key in location.params) && paramNames.indexOf(key) > -1) {
3951
- location.params[key] = currentRoute.params[key];
3952
- }
3953
- }
3954
- }
3955
-
3956
- location.path = fillParams(record.path, location.params, ("named route \"" + name + "\""));
3957
- return _createRoute(record, location, redirectedFrom)
3958
- } else if (location.path) {
3959
- location.params = {};
3960
- for (var i = 0; i < pathList.length; i++) {
3961
- var path = pathList[i];
3962
- var record$1 = pathMap[path];
3963
- if (matchRoute(record$1.regex, location.path, location.params)) {
3964
- return _createRoute(record$1, location, redirectedFrom)
3965
- }
3966
- }
3967
- }
3968
- // no match
3969
- return _createRoute(null, location)
3970
- }
3971
-
3972
- function redirect (
3973
- record,
3974
- location
3975
- ) {
3976
- var originalRedirect = record.redirect;
3977
- var redirect = typeof originalRedirect === 'function'
3978
- ? originalRedirect(createRoute(record, location, null, router))
3979
- : originalRedirect;
3980
-
3981
- if (typeof redirect === 'string') {
3982
- redirect = { path: redirect };
3983
- }
3984
-
3985
- if (!redirect || typeof redirect !== 'object') {
3986
- if (false) {}
3987
- return _createRoute(null, location)
3988
- }
3989
-
3990
- var re = redirect;
3991
- var name = re.name;
3992
- var path = re.path;
3993
- var query = location.query;
3994
- var hash = location.hash;
3995
- var params = location.params;
3996
- query = re.hasOwnProperty('query') ? re.query : query;
3997
- hash = re.hasOwnProperty('hash') ? re.hash : hash;
3998
- params = re.hasOwnProperty('params') ? re.params : params;
3999
-
4000
- if (name) {
4001
- // resolved named direct
4002
- var targetRecord = nameMap[name];
4003
- if (false) {}
4004
- return match({
4005
- _normalized: true,
4006
- name: name,
4007
- query: query,
4008
- hash: hash,
4009
- params: params
4010
- }, undefined, location)
4011
- } else if (path) {
4012
- // 1. resolve relative redirect
4013
- var rawPath = resolveRecordPath(path, record);
4014
- // 2. resolve params
4015
- var resolvedPath = fillParams(rawPath, params, ("redirect route with path \"" + rawPath + "\""));
4016
- // 3. rematch with existing query and hash
4017
- return match({
4018
- _normalized: true,
4019
- path: resolvedPath,
4020
- query: query,
4021
- hash: hash
4022
- }, undefined, location)
4023
- } else {
4024
- if (false) {}
4025
- return _createRoute(null, location)
4026
- }
4027
- }
4028
-
4029
- function alias (
4030
- record,
4031
- location,
4032
- matchAs
4033
- ) {
4034
- var aliasedPath = fillParams(matchAs, location.params, ("aliased route with path \"" + matchAs + "\""));
4035
- var aliasedMatch = match({
4036
- _normalized: true,
4037
- path: aliasedPath
4038
- });
4039
- if (aliasedMatch) {
4040
- var matched = aliasedMatch.matched;
4041
- var aliasedRecord = matched[matched.length - 1];
4042
- location.params = aliasedMatch.params;
4043
- return _createRoute(aliasedRecord, location)
4044
- }
4045
- return _createRoute(null, location)
4046
- }
4047
-
4048
- function _createRoute (
4049
- record,
4050
- location,
4051
- redirectedFrom
4052
- ) {
4053
- if (record && record.redirect) {
4054
- return redirect(record, redirectedFrom || location)
4055
- }
4056
- if (record && record.matchAs) {
4057
- return alias(record, location, record.matchAs)
4058
- }
4059
- return createRoute(record, location, redirectedFrom, router)
4060
- }
4061
-
4062
- return {
4063
- match: match,
4064
- addRoute: addRoute,
4065
- getRoutes: getRoutes,
4066
- addRoutes: addRoutes
4067
- }
4068
- }
4069
-
4070
- function matchRoute (
4071
- regex,
4072
- path,
4073
- params
4074
- ) {
4075
- var m = path.match(regex);
4076
-
4077
- if (!m) {
4078
- return false
4079
- } else if (!params) {
4080
- return true
4081
- }
4082
-
4083
- for (var i = 1, len = m.length; i < len; ++i) {
4084
- var key = regex.keys[i - 1];
4085
- if (key) {
4086
- // Fix #1994: using * with props: true generates a param named 0
4087
- params[key.name || 'pathMatch'] = typeof m[i] === 'string' ? decode(m[i]) : m[i];
4088
- }
4089
- }
4090
-
4091
- return true
4092
- }
4093
-
4094
- function resolveRecordPath (path, record) {
4095
- return resolvePath(path, record.parent ? record.parent.path : '/', true)
4096
- }
4097
-
4098
- /* */
4099
-
4100
- // use User Timing api (if present) for more accurate key precision
4101
- var Time =
4102
- inBrowser && window.performance && window.performance.now
4103
- ? window.performance
4104
- : Date;
4105
-
4106
- function genStateKey () {
4107
- return Time.now().toFixed(3)
4108
- }
4109
-
4110
- var _key = genStateKey();
4111
-
4112
- function getStateKey () {
4113
- return _key
4114
- }
4115
-
4116
- function setStateKey (key) {
4117
- return (_key = key)
4118
- }
4119
-
4120
- /* */
4121
-
4122
- var positionStore = Object.create(null);
4123
-
4124
- function setupScroll () {
4125
- // Prevent browser scroll behavior on History popstate
4126
- if ('scrollRestoration' in window.history) {
4127
- window.history.scrollRestoration = 'manual';
4128
- }
4129
- // Fix for #1585 for Firefox
4130
- // Fix for #2195 Add optional third attribute to workaround a bug in safari https://bugs.webkit.org/show_bug.cgi?id=182678
4131
- // Fix for #2774 Support for apps loaded from Windows file shares not mapped to network drives: replaced location.origin with
4132
- // window.location.protocol + '//' + window.location.host
4133
- // location.host contains the port and location.hostname doesn't
4134
- var protocolAndPath = window.location.protocol + '//' + window.location.host;
4135
- var absolutePath = window.location.href.replace(protocolAndPath, '');
4136
- // preserve existing history state as it could be overriden by the user
4137
- var stateCopy = extend({}, window.history.state);
4138
- stateCopy.key = getStateKey();
4139
- window.history.replaceState(stateCopy, '', absolutePath);
4140
- window.addEventListener('popstate', handlePopState);
4141
- return function () {
4142
- window.removeEventListener('popstate', handlePopState);
4143
- }
4144
- }
4145
-
4146
- function handleScroll (
4147
- router,
4148
- to,
4149
- from,
4150
- isPop
4151
- ) {
4152
- if (!router.app) {
4153
- return
4154
- }
4155
-
4156
- var behavior = router.options.scrollBehavior;
4157
- if (!behavior) {
4158
- return
4159
- }
4160
-
4161
- if (false) {}
4162
-
4163
- // wait until re-render finishes before scrolling
4164
- router.app.$nextTick(function () {
4165
- var position = getScrollPosition();
4166
- var shouldScroll = behavior.call(
4167
- router,
4168
- to,
4169
- from,
4170
- isPop ? position : null
4171
- );
4172
-
4173
- if (!shouldScroll) {
4174
- return
4175
- }
4176
-
4177
- if (typeof shouldScroll.then === 'function') {
4178
- shouldScroll
4179
- .then(function (shouldScroll) {
4180
- scrollToPosition((shouldScroll), position);
4181
- })
4182
- .catch(function (err) {
4183
- if (false) {}
4184
- });
4185
- } else {
4186
- scrollToPosition(shouldScroll, position);
4187
- }
4188
- });
4189
- }
4190
-
4191
- function saveScrollPosition () {
4192
- var key = getStateKey();
4193
- if (key) {
4194
- positionStore[key] = {
4195
- x: window.pageXOffset,
4196
- y: window.pageYOffset
4197
- };
4198
- }
4199
- }
4200
-
4201
- function handlePopState (e) {
4202
- saveScrollPosition();
4203
- if (e.state && e.state.key) {
4204
- setStateKey(e.state.key);
4205
- }
4206
- }
4207
-
4208
- function getScrollPosition () {
4209
- var key = getStateKey();
4210
- if (key) {
4211
- return positionStore[key]
4212
- }
4213
- }
4214
-
4215
- function getElementPosition (el, offset) {
4216
- var docEl = document.documentElement;
4217
- var docRect = docEl.getBoundingClientRect();
4218
- var elRect = el.getBoundingClientRect();
4219
- return {
4220
- x: elRect.left - docRect.left - offset.x,
4221
- y: elRect.top - docRect.top - offset.y
4222
- }
4223
- }
4224
-
4225
- function isValidPosition (obj) {
4226
- return isNumber(obj.x) || isNumber(obj.y)
4227
- }
4228
-
4229
- function normalizePosition (obj) {
4230
- return {
4231
- x: isNumber(obj.x) ? obj.x : window.pageXOffset,
4232
- y: isNumber(obj.y) ? obj.y : window.pageYOffset
4233
- }
4234
- }
4235
-
4236
- function normalizeOffset (obj) {
4237
- return {
4238
- x: isNumber(obj.x) ? obj.x : 0,
4239
- y: isNumber(obj.y) ? obj.y : 0
4240
- }
4241
- }
4242
-
4243
- function isNumber (v) {
4244
- return typeof v === 'number'
4245
- }
4246
-
4247
- var hashStartsWithNumberRE = /^#\d/;
4248
-
4249
- function scrollToPosition (shouldScroll, position) {
4250
- var isObject = typeof shouldScroll === 'object';
4251
- if (isObject && typeof shouldScroll.selector === 'string') {
4252
- // getElementById would still fail if the selector contains a more complicated query like #main[data-attr]
4253
- // but at the same time, it doesn't make much sense to select an element with an id and an extra selector
4254
- var el = hashStartsWithNumberRE.test(shouldScroll.selector) // $flow-disable-line
4255
- ? document.getElementById(shouldScroll.selector.slice(1)) // $flow-disable-line
4256
- : document.querySelector(shouldScroll.selector);
4257
-
4258
- if (el) {
4259
- var offset =
4260
- shouldScroll.offset && typeof shouldScroll.offset === 'object'
4261
- ? shouldScroll.offset
4262
- : {};
4263
- offset = normalizeOffset(offset);
4264
- position = getElementPosition(el, offset);
4265
- } else if (isValidPosition(shouldScroll)) {
4266
- position = normalizePosition(shouldScroll);
4267
- }
4268
- } else if (isObject && isValidPosition(shouldScroll)) {
4269
- position = normalizePosition(shouldScroll);
4270
- }
4271
-
4272
- if (position) {
4273
- // $flow-disable-line
4274
- if ('scrollBehavior' in document.documentElement.style) {
4275
- window.scrollTo({
4276
- left: position.x,
4277
- top: position.y,
4278
- // $flow-disable-line
4279
- behavior: shouldScroll.behavior
4280
- });
4281
- } else {
4282
- window.scrollTo(position.x, position.y);
4283
- }
4284
- }
4285
- }
4286
-
4287
- /* */
4288
-
4289
- var supportsPushState =
4290
- inBrowser &&
4291
- (function () {
4292
- var ua = window.navigator.userAgent;
4293
-
4294
- if (
4295
- (ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) &&
4296
- ua.indexOf('Mobile Safari') !== -1 &&
4297
- ua.indexOf('Chrome') === -1 &&
4298
- ua.indexOf('Windows Phone') === -1
4299
- ) {
4300
- return false
4301
- }
4302
-
4303
- return window.history && typeof window.history.pushState === 'function'
4304
- })();
4305
-
4306
- function pushState (url, replace) {
4307
- saveScrollPosition();
4308
- // try...catch the pushState call to get around Safari
4309
- // DOM Exception 18 where it limits to 100 pushState calls
4310
- var history = window.history;
4311
- try {
4312
- if (replace) {
4313
- // preserve existing history state as it could be overriden by the user
4314
- var stateCopy = extend({}, history.state);
4315
- stateCopy.key = getStateKey();
4316
- history.replaceState(stateCopy, '', url);
4317
- } else {
4318
- history.pushState({ key: setStateKey(genStateKey()) }, '', url);
4319
- }
4320
- } catch (e) {
4321
- window.location[replace ? 'replace' : 'assign'](url);
4322
- }
4323
- }
4324
-
4325
- function replaceState (url) {
4326
- pushState(url, true);
4327
- }
4328
-
4329
- // When changing thing, also edit router.d.ts
4330
- var NavigationFailureType = {
4331
- redirected: 2,
4332
- aborted: 4,
4333
- cancelled: 8,
4334
- duplicated: 16
4335
- };
4336
-
4337
- function createNavigationRedirectedError (from, to) {
4338
- return createRouterError(
4339
- from,
4340
- to,
4341
- NavigationFailureType.redirected,
4342
- ("Redirected when going from \"" + (from.fullPath) + "\" to \"" + (stringifyRoute(
4343
- to
4344
- )) + "\" via a navigation guard.")
4345
- )
4346
- }
4347
-
4348
- function createNavigationDuplicatedError (from, to) {
4349
- var error = createRouterError(
4350
- from,
4351
- to,
4352
- NavigationFailureType.duplicated,
4353
- ("Avoided redundant navigation to current location: \"" + (from.fullPath) + "\".")
4354
- );
4355
- // backwards compatible with the first introduction of Errors
4356
- error.name = 'NavigationDuplicated';
4357
- return error
4358
- }
4359
-
4360
- function createNavigationCancelledError (from, to) {
4361
- return createRouterError(
4362
- from,
4363
- to,
4364
- NavigationFailureType.cancelled,
4365
- ("Navigation cancelled from \"" + (from.fullPath) + "\" to \"" + (to.fullPath) + "\" with a new navigation.")
4366
- )
4367
- }
4368
-
4369
- function createNavigationAbortedError (from, to) {
4370
- return createRouterError(
4371
- from,
4372
- to,
4373
- NavigationFailureType.aborted,
4374
- ("Navigation aborted from \"" + (from.fullPath) + "\" to \"" + (to.fullPath) + "\" via a navigation guard.")
4375
- )
4376
- }
4377
-
4378
- function createRouterError (from, to, type, message) {
4379
- var error = new Error(message);
4380
- error._isRouter = true;
4381
- error.from = from;
4382
- error.to = to;
4383
- error.type = type;
4384
-
4385
- return error
4386
- }
4387
-
4388
- var propertiesToLog = ['params', 'query', 'hash'];
4389
-
4390
- function stringifyRoute (to) {
4391
- if (typeof to === 'string') { return to }
4392
- if ('path' in to) { return to.path }
4393
- var location = {};
4394
- propertiesToLog.forEach(function (key) {
4395
- if (key in to) { location[key] = to[key]; }
4396
- });
4397
- return JSON.stringify(location, null, 2)
4398
- }
4399
-
4400
- function isError (err) {
4401
- return Object.prototype.toString.call(err).indexOf('Error') > -1
4402
- }
4403
-
4404
- function isNavigationFailure (err, errorType) {
4405
- return (
4406
- isError(err) &&
4407
- err._isRouter &&
4408
- (errorType == null || err.type === errorType)
4409
- )
4410
- }
4411
-
4412
- /* */
4413
-
4414
- function runQueue (queue, fn, cb) {
4415
- var step = function (index) {
4416
- if (index >= queue.length) {
4417
- cb();
4418
- } else {
4419
- if (queue[index]) {
4420
- fn(queue[index], function () {
4421
- step(index + 1);
4422
- });
4423
- } else {
4424
- step(index + 1);
4425
- }
4426
- }
4427
- };
4428
- step(0);
4429
- }
4430
-
4431
- /* */
4432
-
4433
- function resolveAsyncComponents (matched) {
4434
- return function (to, from, next) {
4435
- var hasAsync = false;
4436
- var pending = 0;
4437
- var error = null;
4438
-
4439
- flatMapComponents(matched, function (def, _, match, key) {
4440
- // if it's a function and doesn't have cid attached,
4441
- // assume it's an async component resolve function.
4442
- // we are not using Vue's default async resolving mechanism because
4443
- // we want to halt the navigation until the incoming component has been
4444
- // resolved.
4445
- if (typeof def === 'function' && def.cid === undefined) {
4446
- hasAsync = true;
4447
- pending++;
4448
-
4449
- var resolve = once(function (resolvedDef) {
4450
- if (isESModule(resolvedDef)) {
4451
- resolvedDef = resolvedDef.default;
4452
- }
4453
- // save resolved on async factory in case it's used elsewhere
4454
- def.resolved = typeof resolvedDef === 'function'
4455
- ? resolvedDef
4456
- : _Vue.extend(resolvedDef);
4457
- match.components[key] = resolvedDef;
4458
- pending--;
4459
- if (pending <= 0) {
4460
- next();
4461
- }
4462
- });
4463
-
4464
- var reject = once(function (reason) {
4465
- var msg = "Failed to resolve async component " + key + ": " + reason;
4466
- "production" !== 'production' && warn(false, msg);
4467
- if (!error) {
4468
- error = isError(reason)
4469
- ? reason
4470
- : new Error(msg);
4471
- next(error);
4472
- }
4473
- });
4474
-
4475
- var res;
4476
- try {
4477
- res = def(resolve, reject);
4478
- } catch (e) {
4479
- reject(e);
4480
- }
4481
- if (res) {
4482
- if (typeof res.then === 'function') {
4483
- res.then(resolve, reject);
4484
- } else {
4485
- // new syntax in Vue 2.3
4486
- var comp = res.component;
4487
- if (comp && typeof comp.then === 'function') {
4488
- comp.then(resolve, reject);
4489
- }
4490
- }
4491
- }
4492
- }
4493
- });
4494
-
4495
- if (!hasAsync) { next(); }
4496
- }
4497
- }
4498
-
4499
- function flatMapComponents (
4500
- matched,
4501
- fn
4502
- ) {
4503
- return flatten(matched.map(function (m) {
4504
- return Object.keys(m.components).map(function (key) { return fn(
4505
- m.components[key],
4506
- m.instances[key],
4507
- m, key
4508
- ); })
4509
- }))
4510
- }
4511
-
4512
- function flatten (arr) {
4513
- return Array.prototype.concat.apply([], arr)
4514
- }
4515
-
4516
- var hasSymbol =
4517
- typeof Symbol === 'function' &&
4518
- typeof Symbol.toStringTag === 'symbol';
4519
-
4520
- function isESModule (obj) {
4521
- return obj.__esModule || (hasSymbol && obj[Symbol.toStringTag] === 'Module')
4522
- }
4523
-
4524
- // in Webpack 2, require.ensure now also returns a Promise
4525
- // so the resolve/reject functions may get called an extra time
4526
- // if the user uses an arrow function shorthand that happens to
4527
- // return that Promise.
4528
- function once (fn) {
4529
- var called = false;
4530
- return function () {
4531
- var args = [], len = arguments.length;
4532
- while ( len-- ) args[ len ] = arguments[ len ];
4533
-
4534
- if (called) { return }
4535
- called = true;
4536
- return fn.apply(this, args)
4537
- }
4538
- }
4539
-
4540
- /* */
4541
-
4542
- var History = function History (router, base) {
4543
- this.router = router;
4544
- this.base = normalizeBase(base);
4545
- // start with a route object that stands for "nowhere"
4546
- this.current = START;
4547
- this.pending = null;
4548
- this.ready = false;
4549
- this.readyCbs = [];
4550
- this.readyErrorCbs = [];
4551
- this.errorCbs = [];
4552
- this.listeners = [];
4553
- };
4554
-
4555
- History.prototype.listen = function listen (cb) {
4556
- this.cb = cb;
4557
- };
4558
-
4559
- History.prototype.onReady = function onReady (cb, errorCb) {
4560
- if (this.ready) {
4561
- cb();
4562
- } else {
4563
- this.readyCbs.push(cb);
4564
- if (errorCb) {
4565
- this.readyErrorCbs.push(errorCb);
4566
- }
4567
- }
4568
- };
4569
-
4570
- History.prototype.onError = function onError (errorCb) {
4571
- this.errorCbs.push(errorCb);
4572
- };
4573
-
4574
- History.prototype.transitionTo = function transitionTo (
4575
- location,
4576
- onComplete,
4577
- onAbort
4578
- ) {
4579
- var this$1$1 = this;
4580
-
4581
- var route;
4582
- // catch redirect option https://github.com/vuejs/vue-router/issues/3201
4583
- try {
4584
- route = this.router.match(location, this.current);
4585
- } catch (e) {
4586
- this.errorCbs.forEach(function (cb) {
4587
- cb(e);
4588
- });
4589
- // Exception should still be thrown
4590
- throw e
4591
- }
4592
- var prev = this.current;
4593
- this.confirmTransition(
4594
- route,
4595
- function () {
4596
- this$1$1.updateRoute(route);
4597
- onComplete && onComplete(route);
4598
- this$1$1.ensureURL();
4599
- this$1$1.router.afterHooks.forEach(function (hook) {
4600
- hook && hook(route, prev);
4601
- });
4602
-
4603
- // fire ready cbs once
4604
- if (!this$1$1.ready) {
4605
- this$1$1.ready = true;
4606
- this$1$1.readyCbs.forEach(function (cb) {
4607
- cb(route);
4608
- });
4609
- }
4610
- },
4611
- function (err) {
4612
- if (onAbort) {
4613
- onAbort(err);
4614
- }
4615
- if (err && !this$1$1.ready) {
4616
- // Initial redirection should not mark the history as ready yet
4617
- // because it's triggered by the redirection instead
4618
- // https://github.com/vuejs/vue-router/issues/3225
4619
- // https://github.com/vuejs/vue-router/issues/3331
4620
- if (!isNavigationFailure(err, NavigationFailureType.redirected) || prev !== START) {
4621
- this$1$1.ready = true;
4622
- this$1$1.readyErrorCbs.forEach(function (cb) {
4623
- cb(err);
4624
- });
4625
- }
4626
- }
4627
- }
4628
- );
4629
- };
4630
-
4631
- History.prototype.confirmTransition = function confirmTransition (route, onComplete, onAbort) {
4632
- var this$1$1 = this;
4633
-
4634
- var current = this.current;
4635
- this.pending = route;
4636
- var abort = function (err) {
4637
- // changed after adding errors with
4638
- // https://github.com/vuejs/vue-router/pull/3047 before that change,
4639
- // redirect and aborted navigation would produce an err == null
4640
- if (!isNavigationFailure(err) && isError(err)) {
4641
- if (this$1$1.errorCbs.length) {
4642
- this$1$1.errorCbs.forEach(function (cb) {
4643
- cb(err);
4644
- });
4645
- } else {
4646
- if (false) {}
4647
- console.error(err);
4648
- }
4649
- }
4650
- onAbort && onAbort(err);
4651
- };
4652
- var lastRouteIndex = route.matched.length - 1;
4653
- var lastCurrentIndex = current.matched.length - 1;
4654
- if (
4655
- isSameRoute(route, current) &&
4656
- // in the case the route map has been dynamically appended to
4657
- lastRouteIndex === lastCurrentIndex &&
4658
- route.matched[lastRouteIndex] === current.matched[lastCurrentIndex]
4659
- ) {
4660
- this.ensureURL();
4661
- if (route.hash) {
4662
- handleScroll(this.router, current, route, false);
4663
- }
4664
- return abort(createNavigationDuplicatedError(current, route))
4665
- }
4666
-
4667
- var ref = resolveQueue(
4668
- this.current.matched,
4669
- route.matched
4670
- );
4671
- var updated = ref.updated;
4672
- var deactivated = ref.deactivated;
4673
- var activated = ref.activated;
4674
-
4675
- var queue = [].concat(
4676
- // in-component leave guards
4677
- extractLeaveGuards(deactivated),
4678
- // global before hooks
4679
- this.router.beforeHooks,
4680
- // in-component update hooks
4681
- extractUpdateHooks(updated),
4682
- // in-config enter guards
4683
- activated.map(function (m) { return m.beforeEnter; }),
4684
- // async components
4685
- resolveAsyncComponents(activated)
4686
- );
4687
-
4688
- var iterator = function (hook, next) {
4689
- if (this$1$1.pending !== route) {
4690
- return abort(createNavigationCancelledError(current, route))
4691
- }
4692
- try {
4693
- hook(route, current, function (to) {
4694
- if (to === false) {
4695
- // next(false) -> abort navigation, ensure current URL
4696
- this$1$1.ensureURL(true);
4697
- abort(createNavigationAbortedError(current, route));
4698
- } else if (isError(to)) {
4699
- this$1$1.ensureURL(true);
4700
- abort(to);
4701
- } else if (
4702
- typeof to === 'string' ||
4703
- (typeof to === 'object' &&
4704
- (typeof to.path === 'string' || typeof to.name === 'string'))
4705
- ) {
4706
- // next('/') or next({ path: '/' }) -> redirect
4707
- abort(createNavigationRedirectedError(current, route));
4708
- if (typeof to === 'object' && to.replace) {
4709
- this$1$1.replace(to);
4710
- } else {
4711
- this$1$1.push(to);
4712
- }
4713
- } else {
4714
- // confirm transition and pass on the value
4715
- next(to);
4716
- }
4717
- });
4718
- } catch (e) {
4719
- abort(e);
4720
- }
4721
- };
4722
-
4723
- runQueue(queue, iterator, function () {
4724
- // wait until async components are resolved before
4725
- // extracting in-component enter guards
4726
- var enterGuards = extractEnterGuards(activated);
4727
- var queue = enterGuards.concat(this$1$1.router.resolveHooks);
4728
- runQueue(queue, iterator, function () {
4729
- if (this$1$1.pending !== route) {
4730
- return abort(createNavigationCancelledError(current, route))
4731
- }
4732
- this$1$1.pending = null;
4733
- onComplete(route);
4734
- if (this$1$1.router.app) {
4735
- this$1$1.router.app.$nextTick(function () {
4736
- handleRouteEntered(route);
4737
- });
4738
- }
4739
- });
4740
- });
4741
- };
4742
-
4743
- History.prototype.updateRoute = function updateRoute (route) {
4744
- this.current = route;
4745
- this.cb && this.cb(route);
4746
- };
4747
-
4748
- History.prototype.setupListeners = function setupListeners () {
4749
- // Default implementation is empty
4750
- };
4751
-
4752
- History.prototype.teardown = function teardown () {
4753
- // clean up event listeners
4754
- // https://github.com/vuejs/vue-router/issues/2341
4755
- this.listeners.forEach(function (cleanupListener) {
4756
- cleanupListener();
4757
- });
4758
- this.listeners = [];
4759
-
4760
- // reset current history route
4761
- // https://github.com/vuejs/vue-router/issues/3294
4762
- this.current = START;
4763
- this.pending = null;
4764
- };
4765
-
4766
- function normalizeBase (base) {
4767
- if (!base) {
4768
- if (inBrowser) {
4769
- // respect <base> tag
4770
- var baseEl = document.querySelector('base');
4771
- base = (baseEl && baseEl.getAttribute('href')) || '/';
4772
- // strip full URL origin
4773
- base = base.replace(/^https?:\/\/[^\/]+/, '');
4774
- } else {
4775
- base = '/';
4776
- }
4777
- }
4778
- // make sure there's the starting slash
4779
- if (base.charAt(0) !== '/') {
4780
- base = '/' + base;
4781
- }
4782
- // remove trailing slash
4783
- return base.replace(/\/$/, '')
4784
- }
4785
-
4786
- function resolveQueue (
4787
- current,
4788
- next
4789
- ) {
4790
- var i;
4791
- var max = Math.max(current.length, next.length);
4792
- for (i = 0; i < max; i++) {
4793
- if (current[i] !== next[i]) {
4794
- break
4795
- }
4796
- }
4797
- return {
4798
- updated: next.slice(0, i),
4799
- activated: next.slice(i),
4800
- deactivated: current.slice(i)
4801
- }
4802
- }
4803
-
4804
- function extractGuards (
4805
- records,
4806
- name,
4807
- bind,
4808
- reverse
4809
- ) {
4810
- var guards = flatMapComponents(records, function (def, instance, match, key) {
4811
- var guard = extractGuard(def, name);
4812
- if (guard) {
4813
- return Array.isArray(guard)
4814
- ? guard.map(function (guard) { return bind(guard, instance, match, key); })
4815
- : bind(guard, instance, match, key)
4816
- }
4817
- });
4818
- return flatten(reverse ? guards.reverse() : guards)
4819
- }
4820
-
4821
- function extractGuard (
4822
- def,
4823
- key
4824
- ) {
4825
- if (typeof def !== 'function') {
4826
- // extend now so that global mixins are applied.
4827
- def = _Vue.extend(def);
4828
- }
4829
- return def.options[key]
4830
- }
4831
-
4832
- function extractLeaveGuards (deactivated) {
4833
- return extractGuards(deactivated, 'beforeRouteLeave', bindGuard, true)
4834
- }
4835
-
4836
- function extractUpdateHooks (updated) {
4837
- return extractGuards(updated, 'beforeRouteUpdate', bindGuard)
4838
- }
4839
-
4840
- function bindGuard (guard, instance) {
4841
- if (instance) {
4842
- return function boundRouteGuard () {
4843
- return guard.apply(instance, arguments)
4844
- }
4845
- }
4846
- }
4847
-
4848
- function extractEnterGuards (
4849
- activated
4850
- ) {
4851
- return extractGuards(
4852
- activated,
4853
- 'beforeRouteEnter',
4854
- function (guard, _, match, key) {
4855
- return bindEnterGuard(guard, match, key)
4856
- }
4857
- )
4858
- }
4859
-
4860
- function bindEnterGuard (
4861
- guard,
4862
- match,
4863
- key
4864
- ) {
4865
- return function routeEnterGuard (to, from, next) {
4866
- return guard(to, from, function (cb) {
4867
- if (typeof cb === 'function') {
4868
- if (!match.enteredCbs[key]) {
4869
- match.enteredCbs[key] = [];
4870
- }
4871
- match.enteredCbs[key].push(cb);
4872
- }
4873
- next(cb);
4874
- })
4875
- }
4876
- }
4877
-
4878
- /* */
4879
-
4880
- var HTML5History = /*@__PURE__*/(function (History) {
4881
- function HTML5History (router, base) {
4882
- History.call(this, router, base);
4883
-
4884
- this._startLocation = getLocation(this.base);
4885
- }
4886
-
4887
- if ( History ) HTML5History.__proto__ = History;
4888
- HTML5History.prototype = Object.create( History && History.prototype );
4889
- HTML5History.prototype.constructor = HTML5History;
4890
-
4891
- HTML5History.prototype.setupListeners = function setupListeners () {
4892
- var this$1$1 = this;
4893
-
4894
- if (this.listeners.length > 0) {
4895
- return
4896
- }
4897
-
4898
- var router = this.router;
4899
- var expectScroll = router.options.scrollBehavior;
4900
- var supportsScroll = supportsPushState && expectScroll;
4901
-
4902
- if (supportsScroll) {
4903
- this.listeners.push(setupScroll());
4904
- }
4905
-
4906
- var handleRoutingEvent = function () {
4907
- var current = this$1$1.current;
4908
-
4909
- // Avoiding first `popstate` event dispatched in some browsers but first
4910
- // history route not updated since async guard at the same time.
4911
- var location = getLocation(this$1$1.base);
4912
- if (this$1$1.current === START && location === this$1$1._startLocation) {
4913
- return
4914
- }
4915
-
4916
- this$1$1.transitionTo(location, function (route) {
4917
- if (supportsScroll) {
4918
- handleScroll(router, route, current, true);
4919
- }
4920
- });
4921
- };
4922
- window.addEventListener('popstate', handleRoutingEvent);
4923
- this.listeners.push(function () {
4924
- window.removeEventListener('popstate', handleRoutingEvent);
4925
- });
4926
- };
4927
-
4928
- HTML5History.prototype.go = function go (n) {
4929
- window.history.go(n);
4930
- };
4931
-
4932
- HTML5History.prototype.push = function push (location, onComplete, onAbort) {
4933
- var this$1$1 = this;
4934
-
4935
- var ref = this;
4936
- var fromRoute = ref.current;
4937
- this.transitionTo(location, function (route) {
4938
- pushState(cleanPath(this$1$1.base + route.fullPath));
4939
- handleScroll(this$1$1.router, route, fromRoute, false);
4940
- onComplete && onComplete(route);
4941
- }, onAbort);
4942
- };
4943
-
4944
- HTML5History.prototype.replace = function replace (location, onComplete, onAbort) {
4945
- var this$1$1 = this;
4946
-
4947
- var ref = this;
4948
- var fromRoute = ref.current;
4949
- this.transitionTo(location, function (route) {
4950
- replaceState(cleanPath(this$1$1.base + route.fullPath));
4951
- handleScroll(this$1$1.router, route, fromRoute, false);
4952
- onComplete && onComplete(route);
4953
- }, onAbort);
4954
- };
4955
-
4956
- HTML5History.prototype.ensureURL = function ensureURL (push) {
4957
- if (getLocation(this.base) !== this.current.fullPath) {
4958
- var current = cleanPath(this.base + this.current.fullPath);
4959
- push ? pushState(current) : replaceState(current);
4960
- }
4961
- };
4962
-
4963
- HTML5History.prototype.getCurrentLocation = function getCurrentLocation () {
4964
- return getLocation(this.base)
4965
- };
4966
-
4967
- return HTML5History;
4968
- }(History));
4969
-
4970
- function getLocation (base) {
4971
- var path = window.location.pathname;
4972
- var pathLowerCase = path.toLowerCase();
4973
- var baseLowerCase = base.toLowerCase();
4974
- // base="/a" shouldn't turn path="/app" into "/a/pp"
4975
- // https://github.com/vuejs/vue-router/issues/3555
4976
- // so we ensure the trailing slash in the base
4977
- if (base && ((pathLowerCase === baseLowerCase) ||
4978
- (pathLowerCase.indexOf(cleanPath(baseLowerCase + '/')) === 0))) {
4979
- path = path.slice(base.length);
4980
- }
4981
- return (path || '/') + window.location.search + window.location.hash
4982
- }
4983
-
4984
- /* */
4985
-
4986
- var HashHistory = /*@__PURE__*/(function (History) {
4987
- function HashHistory (router, base, fallback) {
4988
- History.call(this, router, base);
4989
- // check history fallback deeplinking
4990
- if (fallback && checkFallback(this.base)) {
4991
- return
4992
- }
4993
- ensureSlash();
4994
- }
4995
-
4996
- if ( History ) HashHistory.__proto__ = History;
4997
- HashHistory.prototype = Object.create( History && History.prototype );
4998
- HashHistory.prototype.constructor = HashHistory;
4999
-
5000
- // this is delayed until the app mounts
5001
- // to avoid the hashchange listener being fired too early
5002
- HashHistory.prototype.setupListeners = function setupListeners () {
5003
- var this$1$1 = this;
5004
-
5005
- if (this.listeners.length > 0) {
5006
- return
5007
- }
5008
-
5009
- var router = this.router;
5010
- var expectScroll = router.options.scrollBehavior;
5011
- var supportsScroll = supportsPushState && expectScroll;
5012
-
5013
- if (supportsScroll) {
5014
- this.listeners.push(setupScroll());
5015
- }
5016
-
5017
- var handleRoutingEvent = function () {
5018
- var current = this$1$1.current;
5019
- if (!ensureSlash()) {
5020
- return
5021
- }
5022
- this$1$1.transitionTo(getHash(), function (route) {
5023
- if (supportsScroll) {
5024
- handleScroll(this$1$1.router, route, current, true);
5025
- }
5026
- if (!supportsPushState) {
5027
- replaceHash(route.fullPath);
5028
- }
5029
- });
5030
- };
5031
- var eventType = supportsPushState ? 'popstate' : 'hashchange';
5032
- window.addEventListener(
5033
- eventType,
5034
- handleRoutingEvent
5035
- );
5036
- this.listeners.push(function () {
5037
- window.removeEventListener(eventType, handleRoutingEvent);
5038
- });
5039
- };
5040
-
5041
- HashHistory.prototype.push = function push (location, onComplete, onAbort) {
5042
- var this$1$1 = this;
5043
-
5044
- var ref = this;
5045
- var fromRoute = ref.current;
5046
- this.transitionTo(
5047
- location,
5048
- function (route) {
5049
- pushHash(route.fullPath);
5050
- handleScroll(this$1$1.router, route, fromRoute, false);
5051
- onComplete && onComplete(route);
5052
- },
5053
- onAbort
5054
- );
5055
- };
5056
-
5057
- HashHistory.prototype.replace = function replace (location, onComplete, onAbort) {
5058
- var this$1$1 = this;
5059
-
5060
- var ref = this;
5061
- var fromRoute = ref.current;
5062
- this.transitionTo(
5063
- location,
5064
- function (route) {
5065
- replaceHash(route.fullPath);
5066
- handleScroll(this$1$1.router, route, fromRoute, false);
5067
- onComplete && onComplete(route);
5068
- },
5069
- onAbort
5070
- );
5071
- };
5072
-
5073
- HashHistory.prototype.go = function go (n) {
5074
- window.history.go(n);
5075
- };
5076
-
5077
- HashHistory.prototype.ensureURL = function ensureURL (push) {
5078
- var current = this.current.fullPath;
5079
- if (getHash() !== current) {
5080
- push ? pushHash(current) : replaceHash(current);
5081
- }
5082
- };
5083
-
5084
- HashHistory.prototype.getCurrentLocation = function getCurrentLocation () {
5085
- return getHash()
5086
- };
5087
-
5088
- return HashHistory;
5089
- }(History));
5090
-
5091
- function checkFallback (base) {
5092
- var location = getLocation(base);
5093
- if (!/^\/#/.test(location)) {
5094
- window.location.replace(cleanPath(base + '/#' + location));
5095
- return true
5096
- }
5097
- }
5098
-
5099
- function ensureSlash () {
5100
- var path = getHash();
5101
- if (path.charAt(0) === '/') {
5102
- return true
5103
- }
5104
- replaceHash('/' + path);
5105
- return false
5106
- }
5107
-
5108
- function getHash () {
5109
- // We can't use window.location.hash here because it's not
5110
- // consistent across browsers - Firefox will pre-decode it!
5111
- var href = window.location.href;
5112
- var index = href.indexOf('#');
5113
- // empty path
5114
- if (index < 0) { return '' }
5115
-
5116
- href = href.slice(index + 1);
5117
-
5118
- return href
5119
- }
5120
-
5121
- function getUrl (path) {
5122
- var href = window.location.href;
5123
- var i = href.indexOf('#');
5124
- var base = i >= 0 ? href.slice(0, i) : href;
5125
- return (base + "#" + path)
5126
- }
5127
-
5128
- function pushHash (path) {
5129
- if (supportsPushState) {
5130
- pushState(getUrl(path));
5131
- } else {
5132
- window.location.hash = path;
5133
- }
5134
- }
5135
-
5136
- function replaceHash (path) {
5137
- if (supportsPushState) {
5138
- replaceState(getUrl(path));
5139
- } else {
5140
- window.location.replace(getUrl(path));
5141
- }
5142
- }
5143
-
5144
- /* */
5145
-
5146
- var AbstractHistory = /*@__PURE__*/(function (History) {
5147
- function AbstractHistory (router, base) {
5148
- History.call(this, router, base);
5149
- this.stack = [];
5150
- this.index = -1;
5151
- }
5152
-
5153
- if ( History ) AbstractHistory.__proto__ = History;
5154
- AbstractHistory.prototype = Object.create( History && History.prototype );
5155
- AbstractHistory.prototype.constructor = AbstractHistory;
5156
-
5157
- AbstractHistory.prototype.push = function push (location, onComplete, onAbort) {
5158
- var this$1$1 = this;
5159
-
5160
- this.transitionTo(
5161
- location,
5162
- function (route) {
5163
- this$1$1.stack = this$1$1.stack.slice(0, this$1$1.index + 1).concat(route);
5164
- this$1$1.index++;
5165
- onComplete && onComplete(route);
5166
- },
5167
- onAbort
5168
- );
5169
- };
5170
-
5171
- AbstractHistory.prototype.replace = function replace (location, onComplete, onAbort) {
5172
- var this$1$1 = this;
5173
-
5174
- this.transitionTo(
5175
- location,
5176
- function (route) {
5177
- this$1$1.stack = this$1$1.stack.slice(0, this$1$1.index).concat(route);
5178
- onComplete && onComplete(route);
5179
- },
5180
- onAbort
5181
- );
5182
- };
5183
-
5184
- AbstractHistory.prototype.go = function go (n) {
5185
- var this$1$1 = this;
5186
-
5187
- var targetIndex = this.index + n;
5188
- if (targetIndex < 0 || targetIndex >= this.stack.length) {
5189
- return
5190
- }
5191
- var route = this.stack[targetIndex];
5192
- this.confirmTransition(
5193
- route,
5194
- function () {
5195
- var prev = this$1$1.current;
5196
- this$1$1.index = targetIndex;
5197
- this$1$1.updateRoute(route);
5198
- this$1$1.router.afterHooks.forEach(function (hook) {
5199
- hook && hook(route, prev);
5200
- });
5201
- },
5202
- function (err) {
5203
- if (isNavigationFailure(err, NavigationFailureType.duplicated)) {
5204
- this$1$1.index = targetIndex;
5205
- }
5206
- }
5207
- );
5208
- };
5209
-
5210
- AbstractHistory.prototype.getCurrentLocation = function getCurrentLocation () {
5211
- var current = this.stack[this.stack.length - 1];
5212
- return current ? current.fullPath : '/'
5213
- };
5214
-
5215
- AbstractHistory.prototype.ensureURL = function ensureURL () {
5216
- // noop
5217
- };
5218
-
5219
- return AbstractHistory;
5220
- }(History));
5221
-
5222
- /* */
5223
-
5224
-
5225
-
5226
- var VueRouter = function VueRouter (options) {
5227
- if ( options === void 0 ) options = {};
5228
-
5229
- if (false) {}
5230
- this.app = null;
5231
- this.apps = [];
5232
- this.options = options;
5233
- this.beforeHooks = [];
5234
- this.resolveHooks = [];
5235
- this.afterHooks = [];
5236
- this.matcher = createMatcher(options.routes || [], this);
5237
-
5238
- var mode = options.mode || 'hash';
5239
- this.fallback =
5240
- mode === 'history' && !supportsPushState && options.fallback !== false;
5241
- if (this.fallback) {
5242
- mode = 'hash';
5243
- }
5244
- if (!inBrowser) {
5245
- mode = 'abstract';
5246
- }
5247
- this.mode = mode;
5248
-
5249
- switch (mode) {
5250
- case 'history':
5251
- this.history = new HTML5History(this, options.base);
5252
- break
5253
- case 'hash':
5254
- this.history = new HashHistory(this, options.base, this.fallback);
5255
- break
5256
- case 'abstract':
5257
- this.history = new AbstractHistory(this, options.base);
5258
- break
5259
- default:
5260
- if (false) {}
5261
- }
5262
- };
5263
-
5264
- var prototypeAccessors = { currentRoute: { configurable: true } };
5265
-
5266
- VueRouter.prototype.match = function match (raw, current, redirectedFrom) {
5267
- return this.matcher.match(raw, current, redirectedFrom)
5268
- };
5269
-
5270
- prototypeAccessors.currentRoute.get = function () {
5271
- return this.history && this.history.current
5272
- };
5273
-
5274
- VueRouter.prototype.init = function init (app /* Vue component instance */) {
5275
- var this$1$1 = this;
5276
-
5277
- "production" !== 'production' &&
5278
- assert(
5279
- install.installed,
5280
- "not installed. Make sure to call `Vue.use(VueRouter)` " +
5281
- "before creating root instance."
5282
- );
5283
-
5284
- this.apps.push(app);
5285
-
5286
- // set up app destroyed handler
5287
- // https://github.com/vuejs/vue-router/issues/2639
5288
- app.$once('hook:destroyed', function () {
5289
- // clean out app from this.apps array once destroyed
5290
- var index = this$1$1.apps.indexOf(app);
5291
- if (index > -1) { this$1$1.apps.splice(index, 1); }
5292
- // ensure we still have a main app or null if no apps
5293
- // we do not release the router so it can be reused
5294
- if (this$1$1.app === app) { this$1$1.app = this$1$1.apps[0] || null; }
5295
-
5296
- if (!this$1$1.app) { this$1$1.history.teardown(); }
5297
- });
5298
-
5299
- // main app previously initialized
5300
- // return as we don't need to set up new history listener
5301
- if (this.app) {
5302
- return
5303
- }
5304
-
5305
- this.app = app;
5306
-
5307
- var history = this.history;
5308
-
5309
- if (history instanceof HTML5History || history instanceof HashHistory) {
5310
- var handleInitialScroll = function (routeOrError) {
5311
- var from = history.current;
5312
- var expectScroll = this$1$1.options.scrollBehavior;
5313
- var supportsScroll = supportsPushState && expectScroll;
5314
-
5315
- if (supportsScroll && 'fullPath' in routeOrError) {
5316
- handleScroll(this$1$1, routeOrError, from, false);
5317
- }
5318
- };
5319
- var setupListeners = function (routeOrError) {
5320
- history.setupListeners();
5321
- handleInitialScroll(routeOrError);
5322
- };
5323
- history.transitionTo(
5324
- history.getCurrentLocation(),
5325
- setupListeners,
5326
- setupListeners
5327
- );
5328
- }
5329
-
5330
- history.listen(function (route) {
5331
- this$1$1.apps.forEach(function (app) {
5332
- app._route = route;
5333
- });
5334
- });
5335
- };
5336
-
5337
- VueRouter.prototype.beforeEach = function beforeEach (fn) {
5338
- return registerHook(this.beforeHooks, fn)
5339
- };
5340
-
5341
- VueRouter.prototype.beforeResolve = function beforeResolve (fn) {
5342
- return registerHook(this.resolveHooks, fn)
5343
- };
5344
-
5345
- VueRouter.prototype.afterEach = function afterEach (fn) {
5346
- return registerHook(this.afterHooks, fn)
5347
- };
5348
-
5349
- VueRouter.prototype.onReady = function onReady (cb, errorCb) {
5350
- this.history.onReady(cb, errorCb);
5351
- };
5352
-
5353
- VueRouter.prototype.onError = function onError (errorCb) {
5354
- this.history.onError(errorCb);
5355
- };
5356
-
5357
- VueRouter.prototype.push = function push (location, onComplete, onAbort) {
5358
- var this$1$1 = this;
5359
-
5360
- // $flow-disable-line
5361
- if (!onComplete && !onAbort && typeof Promise !== 'undefined') {
5362
- return new Promise(function (resolve, reject) {
5363
- this$1$1.history.push(location, resolve, reject);
5364
- })
5365
- } else {
5366
- this.history.push(location, onComplete, onAbort);
5367
- }
5368
- };
5369
-
5370
- VueRouter.prototype.replace = function replace (location, onComplete, onAbort) {
5371
- var this$1$1 = this;
5372
-
5373
- // $flow-disable-line
5374
- if (!onComplete && !onAbort && typeof Promise !== 'undefined') {
5375
- return new Promise(function (resolve, reject) {
5376
- this$1$1.history.replace(location, resolve, reject);
5377
- })
5378
- } else {
5379
- this.history.replace(location, onComplete, onAbort);
5380
- }
5381
- };
5382
-
5383
- VueRouter.prototype.go = function go (n) {
5384
- this.history.go(n);
5385
- };
5386
-
5387
- VueRouter.prototype.back = function back () {
5388
- this.go(-1);
5389
- };
5390
-
5391
- VueRouter.prototype.forward = function forward () {
5392
- this.go(1);
5393
- };
5394
-
5395
- VueRouter.prototype.getMatchedComponents = function getMatchedComponents (to) {
5396
- var route = to
5397
- ? to.matched
5398
- ? to
5399
- : this.resolve(to).route
5400
- : this.currentRoute;
5401
- if (!route) {
5402
- return []
5403
- }
5404
- return [].concat.apply(
5405
- [],
5406
- route.matched.map(function (m) {
5407
- return Object.keys(m.components).map(function (key) {
5408
- return m.components[key]
5409
- })
5410
- })
5411
- )
5412
- };
5413
-
5414
- VueRouter.prototype.resolve = function resolve (
5415
- to,
5416
- current,
5417
- append
5418
- ) {
5419
- current = current || this.history.current;
5420
- var location = normalizeLocation(to, current, append, this);
5421
- var route = this.match(location, current);
5422
- var fullPath = route.redirectedFrom || route.fullPath;
5423
- var base = this.history.base;
5424
- var href = createHref(base, fullPath, this.mode);
5425
- return {
5426
- location: location,
5427
- route: route,
5428
- href: href,
5429
- // for backwards compat
5430
- normalizedTo: location,
5431
- resolved: route
5432
- }
5433
- };
5434
-
5435
- VueRouter.prototype.getRoutes = function getRoutes () {
5436
- return this.matcher.getRoutes()
5437
- };
5438
-
5439
- VueRouter.prototype.addRoute = function addRoute (parentOrRoute, route) {
5440
- this.matcher.addRoute(parentOrRoute, route);
5441
- if (this.history.current !== START) {
5442
- this.history.transitionTo(this.history.getCurrentLocation());
5443
- }
5444
- };
5445
-
5446
- VueRouter.prototype.addRoutes = function addRoutes (routes) {
5447
- if (false) {}
5448
- this.matcher.addRoutes(routes);
5449
- if (this.history.current !== START) {
5450
- this.history.transitionTo(this.history.getCurrentLocation());
5451
- }
5452
- };
5453
-
5454
- Object.defineProperties( VueRouter.prototype, prototypeAccessors );
5455
-
5456
- var VueRouter$1 = VueRouter;
5457
-
5458
- function registerHook (list, fn) {
5459
- list.push(fn);
5460
- return function () {
5461
- var i = list.indexOf(fn);
5462
- if (i > -1) { list.splice(i, 1); }
5463
- }
5464
- }
5465
-
5466
- function createHref (base, fullPath, mode) {
5467
- var path = mode === 'hash' ? '#' + fullPath : fullPath;
5468
- return base ? cleanPath(base + '/' + path) : path
5469
- }
5470
-
5471
- // We cannot remove this as it would be a breaking change
5472
- VueRouter.install = install;
5473
- VueRouter.version = '3.6.5';
5474
- VueRouter.isNavigationFailure = isNavigationFailure;
5475
- VueRouter.NavigationFailureType = NavigationFailureType;
5476
- VueRouter.START_LOCATION = START;
5477
-
5478
- if (inBrowser && window.Vue) {
5479
- window.Vue.use(VueRouter);
5480
- }
5481
-
5482
- var version = '3.6.5';
5483
-
5484
-
5485
-
5486
- // CONCATENATED MODULE: ./src/wapp/common/router/index.js
5487
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "constantRoutes", function() { return constantRoutes; });
5488
- /* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "resetRouter", function() { return resetRouter; });
5489
-
5490
-
5491
- external_commonjs_vue_commonjs2_vue_root_Vue_default.a.use(VueRouter$1);
5492
-
5493
- // 获取原型对象push函数
5494
- var originalPush = VueRouter$1.prototype.push;
5495
- // 获取原型对象replace函数
5496
- var originalReplace = VueRouter$1.prototype.replace;
5497
- // 修改原型对象中的push函数
5498
- VueRouter$1.prototype.push = function push(location) {
5499
- return originalPush.call(this, location).catch(function (err) {
5500
- return err;
5501
- });
5502
- };
5503
- // 修改原型对象中的replace函数
5504
- VueRouter$1.prototype.replace = function replace(location) {
5505
- return originalReplace.call(this, location).catch(function (err) {
5506
- return err;
5507
- });
5508
- };
5509
- /**
5510
- * Note: sub-menu only appear when route children.length >= 1
5511
- * Detail see: https://panjiachen.github.io/vue-element-admin-site/guide/essentials/router-and-nav.html
5512
- *
5513
- * hidden: true if set true, item will not show in the sidebar(default is false)
5514
- * alwaysShow: true if set true, will always show the root menu
5515
- * if not set alwaysShow, when item has more than one children route,
5516
- * it will becomes nested mode, otherwise not show the root menu
5517
- * redirect: noRedirect if set noRedirect will no redirect in the breadcrumb
5518
- * name:'router-name' the name is used by <keep-alive> (must set!!!)
5519
- * meta : {
5520
- roles: ['admin','editor'] control the page roles (you can set multiple roles)
5521
- title: 'title' the name show in sidebar and breadcrumb (recommend set)
5522
- icon: 'svg-name' the icon show in the sidebar
5523
- noCache: true if set true, the page will no be cached(default is false)
5524
- affix: true if set true, the tag will affix in the tags-view
5525
- breadcrumb: false if set false, the item will hidden in breadcrumb(default is true)
5526
- activeMenu: '/example/list' if set path, the sidebar will highlight the path you set
5527
- }
5528
- */
5529
-
5530
- /**
5531
- * constantRoutes
5532
- * a base page that does not have permission requirements
5533
- * all roles can be accessed
5534
- */
5535
- var constantRoutes = [];
5536
- var router_createRouter = function createRouter() {
5537
- return new VueRouter$1({
5538
- // mode: 'history', // require service support
5539
- scrollBehavior: function scrollBehavior() {
5540
- return {
5541
- y: 0
5542
- };
5543
- },
5544
- routes: constantRoutes
5545
- });
5546
- };
5547
- var router = router_createRouter();
5548
- function resetRouter() {
5549
- var newRouter = router_createRouter();
5550
- router.matcher = newRouter.matcher; // reset router
5551
- }
5552
- /* harmony default export */ var common_router = __webpack_exports__["default"] = (router);
5553
-
5554
- /***/ }),
5555
-
5556
- /***/ "fb15":
5557
- /***/ (function(module, __webpack_exports__, __webpack_require__) {
5558
-
5559
- "use strict";
5560
- __webpack_require__.r(__webpack_exports__);
5561
-
5562
- // CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
5563
- // This file is imported into lib/wc client bundles.
5564
-
5565
- if (typeof window !== 'undefined') {
5566
- var currentScript = window.document.currentScript
5567
- if (true) {
5568
- var getCurrentScript = __webpack_require__("8875")
5569
- currentScript = getCurrentScript()
5570
-
5571
- // for backward compatibility, because previously we directly included the polyfill
5572
- if (!('currentScript' in document)) {
5573
- Object.defineProperty(document, 'currentScript', { get: getCurrentScript })
5574
- }
5575
- }
5576
-
5577
- var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
5578
- if (src) {
5579
- __webpack_require__.p = src[1] // eslint-disable-line
5580
- }
5581
- }
5582
-
5583
- // Indicate to webpack that this file can be concatenated
5584
- /* harmony default export */ var setPublicPath = (null);
5585
-
5586
- // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"9ad868ba-vue-loader-template"}!./node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/ecyoa/email/src/index.vue?vue&type=template&id=66e2781e&scoped=true&
5587
- var render = function render() {
5588
- var _vm = this,
5589
- _c = _vm._self._c;
5590
- return _c('div', {
5591
- staticClass: "app-wrapper",
5592
- class: _vm.classObj,
5593
- on: {
5594
- "click": _vm.handleBodyOnClick
5595
- }
5596
- }, [_vm.awaitShow ? _c('LeftMenu', {
5597
- staticClass: "sidebar-container",
5598
- on: {
5599
- "getate": _vm.getate
5600
- }
5601
- }) : _vm._e(), _c('div', {
5602
- staticClass: "main-container",
5603
- class: {
5604
- hasTagsView: _vm.needTagsView
5605
- },
5606
- staticStyle: {
5607
- "background": "#F4F6F9"
5608
- }
5609
- }, [_c('div', {
5610
- class: {
5611
- 'fixed-header': _vm.fixedHeader
5612
- },
5613
- staticStyle: {
5614
- "position": "relative"
5615
- }
5616
- }, [_vm.needTagsView && _vm.showTopMenus ? _c('tags-view', {
5617
- ref: "tagsView",
5618
- staticStyle: {
5619
- "padding-right": "245px"
5620
- }
5621
- }) : _vm._e(), _vm.show ? _c('div', {
5622
- staticClass: "headInfo"
5623
- }, [_c('div', {
5624
- ref: "imgHead",
5625
- staticStyle: {
5626
- "cursor": "pointer"
5627
- },
5628
- on: {
5629
- "click": function click($event) {
5630
- _vm.accountDialog = !_vm.accountDialog;
5631
- }
5632
- }
5633
- }, [_c('div', {
5634
- staticStyle: {
5635
- "max-width": "200px",
5636
- "display": "inline-block",
5637
- "position": "absolute",
5638
- "top": "16px",
5639
- "right": "46px"
5640
- }
5641
- }, [_vm.valueHead !== null ? _c('div', {
5642
- staticClass: "imgHead2",
5643
- style: {
5644
- 'background-color': _vm.colorDisplay(_vm.valueHead)
5645
- }
5646
- }, [_c('span', {
5647
- staticStyle: {
5648
- "font-size": "14px",
5649
- "color": "#ffffff",
5650
- "line-height": "16px"
2410
+ }, [_c('span', {
2411
+ staticStyle: {
2412
+ "font-size": "14px",
2413
+ "color": "#ffffff",
2414
+ "line-height": "16px"
5651
2415
  }
5652
2416
  }, [_vm._v(_vm._s(_vm.headDisplay(_vm.valueHead)))])]) : _vm._e(), _c('span', {
5653
2417
  staticStyle: {
@@ -5706,763 +2470,69 @@ var render = function render() {
5706
2470
  staticStyle: {
5707
2471
  "margin-top": "4px",
5708
2472
  "padding": "0",
5709
- "color": "#666",
5710
- "line-height": "20px"
5711
- }
5712
- }, [_vm._v("最近登录:" + _vm._s(_vm.lastTimeLog.operateTime))])])]), _c('div', {
5713
- staticClass: "optionListWrap",
5714
- staticStyle: {
5715
- "padding": "16px 0"
5716
- }
5717
- }, _vm._l(_vm.accountList, function (item) {
5718
- return _c('div', {
5719
- key: item.id,
5720
- staticStyle: {
5721
- "position": "relative"
5722
- }
5723
- }, [_c('div', {
5724
- staticClass: "optionList",
5725
- on: {
5726
- "click": function click($event) {
5727
- return _vm.selectMail(item);
5728
- }
5729
- }
5730
- }, [item.emailAddr === _vm.valueMail ? _c('span', {
5731
- staticStyle: {
5732
- "color": "#409EFF"
5733
- }
5734
- }, [_vm._v(_vm._s(item.emailAddr) + " "), _c('span', [_vm._v("(" + _vm._s(_vm.unreadNum) + ")")])]) : _c('span', [_vm._v(_vm._s(item.emailAddr) + " "), _c('span', [_vm._v("(" + _vm._s(_vm.unreadNum) + ")")])])]), item.emailAddr === _vm.valueMail ? _c('img', {
5735
- staticStyle: {
5736
- "height": "16px",
5737
- "position": "absolute",
5738
- "top": "0",
5739
- "right": "21px"
5740
- },
5741
- attrs: {
5742
- "src": './images/w-imgs/success.png',
5743
- "alt": ""
5744
- }
5745
- }) : _vm._e()]);
5746
- }), 0)])]) : _c('div', {
5747
- staticClass: "headInfo"
5748
- })], 1), _vm.defultMail || _vm.awaitShow ? _c('app-main') : _vm._e(), _vm.showSettings ? _c('right-panel', [_c('settings')], 1) : _vm._e()], 1)], 1);
5749
- };
5750
- var staticRenderFns = [];
5751
-
5752
- // CONCATENATED MODULE: ./packages/ecyoa/email/src/index.vue?vue&type=template&id=66e2781e&scoped=true&
5753
-
5754
- // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"9ad868ba-vue-loader-template"}!./node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/ecyoa/email/src/components/LeftMenu.vue?vue&type=template&id=670785a0&
5755
- var LeftMenuvue_type_template_id_670785a0_render = function render() {
5756
- var _vm = this,
5757
- _c = _vm._self._c;
5758
- return _c('el-scrollbar', {
5759
- class: {
5760
- 'std-scrollbar-wrapper': _vm.showTopMenus,
5761
- 'dark-scrollbar-wrapper': !_vm.showTopMenus
5762
- },
5763
- attrs: {
5764
- "wrap-class": "scrollbar-wrapper"
5765
- }
5766
- }, [_c('el-menu', {
5767
- attrs: {
5768
- "default-active": _vm.activeMenu,
5769
- "collapse": false,
5770
- "background-color": _vm.menuBg,
5771
- "text-color": _vm.menuText,
5772
- "unique-opened": true,
5773
- "collapse-transition": false
5774
- }
5775
- }, [_c('el-menu-item', {
5776
- directives: [{
5777
- name: "show",
5778
- rawName: "v-show",
5779
- value: _vm.menuName !== '' && false,
5780
- expression: "menuName!=='' && false"
5781
- }],
5782
- staticClass: "submenu-title-noDropdown",
5783
- attrs: {
5784
- "index": "0",
5785
- "disabled": ""
5786
- }
5787
- }, [_vm.menuIcon.indexOf('.svg') > -1 ? _c('svg-icon', {
5788
- attrs: {
5789
- "icon-class": _vm.menuIconClass
5790
- }
5791
- }) : _vm._e(), _vm.menuIcon.indexOf('.svg') === -1 ? _c('i', {
5792
- class: _vm.menuIcon
5793
- }) : _vm._e(), _c('span', {
5794
- staticClass: "appname"
5795
- }, [_vm._v(_vm._s(_vm.menuName))])], 1), _c('div', {
5796
- staticClass: "topBtn-wrapper",
5797
- staticStyle: {
5798
- "text-align": "center",
5799
- "height": "55px"
5800
- }
5801
- }, [_c('div', {
5802
- staticClass: "writeEmail",
5803
- on: {
5804
- "click": function click($event) {
5805
- return _vm.gotoPages('email.svg');
5806
- }
5807
- }
5808
- }, [_c('svg-icon', {
5809
- staticStyle: {
5810
- "color": "#48BA79",
5811
- "width": "14px",
5812
- "height": "14px"
5813
- },
5814
- attrs: {
5815
- "icon-class": "email"
5816
- }
5817
- }), _vm._v(" "), _c('span', [_vm._v("收信")])], 1), _c('div', {
5818
- staticClass: "writeEmail",
5819
- on: {
5820
- "click": _vm.gotoWrite
5821
- }
5822
- }, [_c('svg-icon', {
5823
- staticStyle: {
5824
- "fill": "#EC8423",
5825
- "width": "14px",
5826
- "height": "14px"
5827
- },
5828
- attrs: {
5829
- "icon-class": "email_xieyoujian"
5830
- }
5831
- }), _vm._v(" "), _c('span', [_vm._v("写信")])], 1)]), [_vm._l(_vm.routes, function (route) {
5832
- return [_c('sidebar-item', {
5833
- key: route.path,
5834
- attrs: {
5835
- "item": _vm.resetRoute(route),
5836
- "base-path": route.path
5837
- }
5838
- })];
5839
- })]], 2)], 1);
5840
- };
5841
- var LeftMenuvue_type_template_id_670785a0_staticRenderFns = [];
5842
-
5843
- // CONCATENATED MODULE: ./packages/ecyoa/email/src/components/LeftMenu.vue?vue&type=template&id=670785a0&
5844
-
5845
- // EXTERNAL MODULE: ./node_modules/vuex/dist/vuex.esm.js
5846
- var vuex_esm = __webpack_require__("2f62");
5847
-
5848
- // CONCATENATED MODULE: ./node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/ecyoa/email/src/components/LeftMenu.vue?vue&type=script&lang=js&
5849
- function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
5850
- function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
5851
- function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
5852
- function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
5853
- function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5854
- function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5855
- function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
5856
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
5857
- function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
5858
-
5859
- var _variables = __webpack_require__("4fe4");
5860
- var router = __webpack_require__("f583").default;
5861
- /* harmony default export */ var LeftMenuvue_type_script_lang_js_ = ({
5862
- data: function data() {
5863
- return {
5864
- menuName: '',
5865
- menuIcon: '',
5866
- menuIconClass: '',
5867
- folder: [],
5868
- // 文件夹数组
5869
- xieyoujianPath: '',
5870
- isFolder: true,
5871
- defultMail: '',
5872
- yjjkMenu: true,
5873
- bfyxMenu: true,
5874
- txlMenu: true,
5875
- unreadNum: 0,
5876
- draftsNum: 0,
5877
- usersetId: '',
5878
- updataLM: true
5879
- };
5880
- },
5881
- watch: {
5882
- 'folder': {
5883
- handler: function handler(val) {
5884
- // this.refreshIsFolder()
5885
- }
5886
- }
5887
- },
5888
- // eslint-disable-next-line vue/order-in-components
5889
- computed: _objectSpread(_objectSpread({}, Object(vuex_esm["a" /* mapGetters */])(['routes', 'sidebar', 'loginUser'])), {}, {
5890
- showTopMenus: function showTopMenus() {
5891
- return this.$store.state.settings.showTopMenus;
5892
- },
5893
- activeMenu: function activeMenu() {
5894
- var route = this.$route;
5895
- var meta = route.meta,
5896
- path = route.path;
5897
- console.log(route, 'route');
5898
- // if set path, the sidebar will highlight the path you set
5899
- if (meta.activeMenu) {
5900
- return meta.activeMenu;
5901
- }
5902
- return path;
5903
- },
5904
- variables: function variables() {
5905
- return _variables;
5906
- },
5907
- isCollapse: function isCollapse() {
5908
- return !this.sidebar.opened;
5909
- },
5910
- menuBg: function menuBg() {
5911
- return this.showTopMenus ? _variables.stdMenuBgcolor : _variables.darkMenuBgcolor;
5912
- },
5913
- menuText: function menuText() {
5914
- return this.showTopMenus ? _variables.stdMenuText : _variables.darkMenuText;
5915
- },
5916
- menuActiveText: function menuActiveText() {
5917
- return this.showTopMenus ? _variables.stdMenuAcitveText : _variables.darkMenuAcitveText;
5918
- }
5919
- }),
5920
- beforeCreate: function beforeCreate() {},
5921
- created: function created() {
5922
- var _this = this;
5923
- this.$options.components['SidebarItem'] = this.$loadComponent('@/wapp/common/layout/components/Sidebar/SidebarItem');
5924
- this.$bus.on('changeEmail', function (res) {
5925
- _this.defultMail = res;
5926
- });
5927
- this.$bus.on('refreshFolder', this.refreshIsFolder);
5928
- this.$bus.on('getMenuName', this.getMenuName);
5929
- this.getFolder();
5930
- if (sessionStorage.getItem('currentMail') !== null && sessionStorage.getItem('currentMail') !== 'undefined') {
5931
- this.defultMail = JSON.parse(sessionStorage.getItem('currentMail'));
5932
- }
5933
- this.$bus.on('updateInboxLMnum', this.unread);
5934
- this.$bus.on('updateDraftsNum', this.drafts);
5935
- this.getUnreadNum();
5936
- this.getdraftsNum();
5937
- },
5938
- beforeDestroy: function beforeDestroy() {
5939
- this.$bus.off('refreshFolder', this.refreshIsFolder);
5940
- this.$bus.off('getMenuName', this.getMenuName);
5941
- this.$bus.off('changeEmail');
5942
- this.$bus.off('updateInboxLMnum', this.unread);
5943
- this.$bus.off('updateDraftsNum', this.drafts);
5944
- },
5945
- mounted: function mounted() {},
5946
- methods: {
5947
- // 请求文件夹接口
5948
- getFolder: function getFolder() {
5949
- var _this2 = this;
5950
- var mainpage = null; // 栏目页面组件
5951
- for (var i = 0; i < this.routes.length; i++) {
5952
- if (this.routes[i].meta && this.routes[i].meta.id === this.$route.meta.id && this.routes[i].meta.level === 1 && this.routes[i].children && this.routes[i].children.length > 0) {
5953
- mainpage = this.routes[i];
5954
- mainpage.children[0].children = mainpage.children[0].children || [];
5955
- }
5956
- }
5957
- if (mainpage !== null) {
5958
- if (sessionStorage.getItem('currentMail') !== null && sessionStorage.getItem('currentMail') !== 'undefined') {
5959
- var currentMail = JSON.parse(sessionStorage.getItem('currentMail'));
5960
-
5961
- // 请求被监控人员
5962
- var queryparams = [{
5963
- 'compare': 'like',
5964
- 'field': 'mailAddr',
5965
- 'merge': true,
5966
- 'value': currentMail.emailAddr
5967
- }, {
5968
- 'compare': '=',
5969
- 'field': 'orgCode',
5970
- 'merge': true,
5971
- 'value': currentMail.orgCode
5972
- }];
5973
- this.$app.querydata('/mail/byRegulator/querydata', queryparams).then(function (resp) {
5974
- if (resp.code === 'success') {
5975
- _this2.yjjkMenu = false;
5976
- if (resp.body.listdata.length === 0) {
5977
- _this2.yjjkMenu = false;
5978
- } else if (resp.body.listdata.length && currentMail.accountType === 1) {
5979
- _this2.yjjkMenu = true;
5980
- }
5981
- } else {
5982
- _this2.$alert(resp.message, {
5983
- type: 'error'
5984
- });
5985
- }
5986
- });
5987
-
5988
- // 请求是否有备份邮箱数据
5989
- var queryparams2 = [{
5990
- 'compare': 'like',
5991
- 'field': 'backupAdds',
5992
- 'merge': true,
5993
- 'value': "%".concat(this.loginUser.personAccount, "%")
5994
- }];
5995
- this.$app.querydata('/mail/userSetup/querydata', queryparams2).then(function (resp2) {
5996
- if (resp2.code === 'success') {
5997
- _this2.bfyxMenu = false;
5998
- if (resp2.body.listdata.length === 0) {
5999
- _this2.bfyxMenu = false;
6000
- } else if (resp2.body.listdata.length && currentMail.accountType === 1) {
6001
- _this2.bfyxMenu = true;
6002
- }
6003
- } else {
6004
- _this2.$alert(resp2.message, {
6005
- type: 'error'
6006
- });
6007
- }
6008
- });
6009
-
6010
- // 初始化自定义文件夹
6011
- var usersetId = currentMail.id;
6012
- var params = {
6013
- orderBy: 'orderNo asc',
6014
- urlsearch: "boxType:DEFINED;usersetId:".concat(usersetId)
6015
- };
6016
- this.$app.listdata('/mail/messageBox/listdata', params).then(function (res) {
6017
- console.log(res, 666666);
6018
- if (res.code === 'success') {
6019
- _this2.folder = res.body.pageInfo.list;
6020
- _this2.getDh(mainpage);
6021
- } else {
6022
- _this2.$alert(res.message, {
6023
- type: 'error'
6024
- });
6025
- }
6026
- });
6027
- } else {
6028
- this.gotoPages('email.svg');
6029
- }
6030
- } else if (this.$route.meta.title === '管理文件夹') {} else {
6031
- this.gotoPages('email.svg');
6032
- }
6033
- },
6034
- // 动态生成左边导航
6035
- getDh: function getDh(mainpage) {
6036
- var _this3 = this;
6037
- var _loop = function _loop() {
6038
- var proute = _this3.routes[i];
6039
- if (proute.meta && proute.meta.parentId === _this3.$route.meta.id) {
6040
- console.log('prouteprouteproute===', proute);
6041
- // 将标准左导航菜单路由修改为当前栏目路径下的子路由
6042
- if (proute.children && proute.children.length === 1) {
6043
- proute.component = window.$loadComponent('@/wapp/common/layout/components/Blank');
6044
- var troute = proute.children[0];
6045
- troute.path = proute.children[0].meta.id + i; // 路由的path不能相同,增加一个随机数字
6046
- troute.fullPath = proute.path + '/' + troute.path;
6047
- troute.meta.target = 'mainpage'; // 邮箱是“左导航+工作区”自定义布局
6048
- } else {
6049
- proute.path = mainpage.path + '/' + mainpage.children[0].path + '/' + proute.meta.id;
6050
- }
6051
- mainpage.children[0].children.push(proute);
6052
- if (proute.meta.title === '自定义文件夹') {
6053
- proute.children = [];
6054
- // if (this.routes[i].children.length === 0) {
6055
- // 加载文件夹配置,动态添加到路由中
6056
- myFolders = [];
6057
- _this3.folder.forEach(function (res) {
6058
- myFolders.push({
6059
- id: res.id,
6060
- name: res.boxName
6061
- });
6062
- });
6063
- myFolders.push({
6064
- id: 'glwjj',
6065
- name: '管理文件夹'
6066
- });
6067
- _this3.routes[i].component = window.$loadComponent('@/wapp/common/layout/components/Blank');
6068
- myFolders.forEach(function (folder) {
6069
- var folderRoute = {
6070
- 'path': folder.id,
6071
- 'name': folder.id,
6072
- 'alias': folder.name,
6073
- 'hidden': false,
6074
- 'alwaysShow': false,
6075
- 'component': _this3.$loadComponent('@/wapp/email/components/EmailFolder'),
6076
- 'meta': {
6077
- 'id': folder.id,
6078
- 'title': folder.name,
6079
- 'level': 3,
6080
- 'parentId': proute.meta.id,
6081
- 'parentIconCode': proute.meta.icon,
6082
- 'parentTitle': proute.alias,
6083
- 'activeMenu': proute.path + '/' + folder.id,
6084
- 'sysCode': proute.meta.sysCode,
6085
- 'target': 'mainpage'
6086
- }
6087
- };
6088
- proute.children.push(folderRoute);
6089
- });
6090
- }
6091
- }
6092
- };
6093
- for (var i = 0; i < this.routes.length; i++) {
6094
- var myFolders;
6095
- _loop();
6096
- }
6097
- this.xieyoujianPath = {
6098
- 'path': 'writeMail',
6099
- 'fullPath': mainpage.path + '/' + mainpage.children[0].path + '/writeMail',
6100
- 'name': 'writeMail',
6101
- 'alias': '写邮件',
6102
- 'hidden': false,
6103
- 'alwaysShow': false,
6104
- 'component': this.$loadComponent('@/wapp/email/EmailXieyoujian'),
6105
- 'meta': {
6106
- 'id': 'writeMail',
6107
- 'code': 'writeMail',
6108
- 'title': '写邮件',
6109
- 'level': 2,
6110
- 'parentId': mainpage.children[0].id,
6111
- 'parentIconCode': mainpage.children[0].meta.code,
6112
- 'parentTitle': mainpage.children[0].alias,
6113
- 'activeMenu': mainpage.children[0].path,
6114
- 'sysCode': mainpage.children[0].meta.sysCode,
6115
- 'icon': 'email_xieyoujian.svg',
6116
- 'target': 'mainpage'
6117
- }
6118
- };
6119
- mainpage.children[0].children.push(this.xieyoujianPath);
6120
- router.addRoutes([mainpage]);
6121
- if (this.activeMenu && this.activeMenu.indexOf('/tm/') === 0) {
6122
- // 写邮件时刷新页面,刷新后重新进入写邮件界面
6123
- this.gotoWrite();
6124
- }
6125
- var lroutes = mainpage.children[0].children.filter(function (proute) {
6126
- if (proute.children && proute.children.length === 1 && proute.children[0].meta.target === 'mainpage') {
6127
- return true;
6128
- }
6129
- });
6130
- if (lroutes.length > 0) this.$router.push(lroutes[0].children[0].fullPath);
6131
- },
6132
- getMenuName: function getMenuName(menuName, menuIcon) {
6133
- this.menuName = menuName;
6134
- this.menuIcon = menuIcon;
6135
- if (this.menuIcon.indexOf('.svg') > -1) {
6136
- this.menuIconClass = this.menuIcon.substring(0, this.menuIcon.lastIndexOf('.svg'));
6137
- } else {
6138
- this.menuIcon = 'el-icon-' + this.menuIcon;
6139
- }
6140
- },
6141
- // 获取收件箱未读数目
6142
- getUnreadNum: function getUnreadNum() {
6143
- var _this4 = this;
6144
- return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
6145
- var unreadNum, params, res;
6146
- return _regeneratorRuntime().wrap(function _callee$(_context) {
6147
- while (1) switch (_context.prev = _context.next) {
6148
- case 0:
6149
- unreadNum = 0;
6150
- params = {
6151
- orderBy: 'orderNo asc',
6152
- urlsearch: "usersetId:".concat(_this4.defultMail.id, ";")
6153
- };
6154
- _context.next = 4;
6155
- return _this4.$app.listdata('/mail/messageBox/listdata', params);
6156
- case 4:
6157
- res = _context.sent;
6158
- if (res.code === 'success') {
6159
- res.body.pageInfo.list.forEach(function (item) {
6160
- if (item.boxType === 'INBOX') {
6161
- unreadNum = item.notReadedNum;
6162
- }
6163
- return false;
6164
- });
6165
- }
6166
- _this4.$bus.emit('updateInboxLMnum', unreadNum);
6167
- case 7:
6168
- case "end":
6169
- return _context.stop();
6170
- }
6171
- }, _callee);
6172
- }))();
6173
- },
6174
- // 获取草稿箱数目
6175
- getdraftsNum: function getdraftsNum() {
6176
- var _this5 = this;
6177
- return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
6178
- var draftsNum, currentMail, usersetId;
6179
- return _regeneratorRuntime().wrap(function _callee2$(_context2) {
6180
- while (1) switch (_context2.prev = _context2.next) {
6181
- case 0:
6182
- draftsNum = 0;
6183
- currentMail = JSON.parse(sessionStorage.getItem('currentMail'));
6184
- usersetId = currentMail.id; // const params = {
6185
- // urlsearch: `usersetId:${usersetId}`
6186
- // }
6187
- // const res = await this.$app.listdata('/mail/message/listdata?&mailBoxType=DRAFT&accountType=1&usersetId=' + usersetId)
6188
- _this5.$http({
6189
- contentType: 'application/x-www-form-urlencoded',
6190
- url: '/mail/message/listdata?&usersetId=' + usersetId,
6191
- params: {
6192
- mailBoxType: 'DRAFT',
6193
- accountType: 1
6194
- },
6195
- method: 'POST'
6196
- }).then(function (res) {
6197
- _this5.draftsNum = draftsNum = res.body.pageInfo.total;
6198
- });
6199
- _this5.$bus.emit('updateDraftsNum', draftsNum);
6200
- case 5:
6201
- case "end":
6202
- return _context2.stop();
6203
- }
6204
- }, _callee2);
6205
- }))();
6206
- },
6207
- // 刷新文件夹
6208
- refreshIsFolder: function refreshIsFolder() {
6209
- var _this6 = this;
6210
- console.log('refreshIsFolder', new Date());
6211
- this.isFolder = false;
6212
- this.getFolder();
6213
- this.$bus.on('changeEmail', function (res) {
6214
- _this6.defultMail = JSON.parse(sessionStorage.getItem('currentMail'));
6215
- });
6216
- this.$nextTick(function () {
6217
- _this6.isFolder = true;
6218
- });
6219
- },
6220
- gotoWrite: function gotoWrite() {
6221
- this.gotoPages('writeMail');
6222
- },
6223
- // 收件箱路由跳转
6224
- gotoPages: function gotoPages(modelCode) {
6225
- var toPath = this.getMenuCode(modelCode);
6226
- if (toPath) {
6227
- var path;
6228
- if (toPath.fullPath) {
6229
- path = toPath.fullPath;
6230
- } else {
6231
- switch (toPath.meta.level) {
6232
- case 3:
6233
- path = toPath.meta.activeMenu || toPath.path;
6234
- break;
6235
- case 4:
6236
- path = toPath.meta.activeMenu + '/' + toPath.path;
6237
- break;
6238
- default:
6239
- path = toPath.path;
6240
- }
6241
- }
6242
- this.$router.push({
6243
- path: path
6244
- });
6245
- // }
6246
- }
6247
- },
6248
- // 递归查询菜单代码
6249
- getMenuCode: function getMenuCode(code) {
6250
- var toPath;
6251
- function findCode(ary) {
6252
- ary.forEach(function (val) {
6253
- if (val.children) {
6254
- findCode(val.children);
6255
- }
6256
- if (!val.children && val.meta && val.meta.code === code) {
6257
- toPath = val;
6258
- return false;
6259
- }
6260
- });
6261
- }
6262
- findCode(this.routes);
6263
- return toPath;
6264
- },
6265
- unread: function unread(num) {
6266
- var _this7 = this;
6267
- return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
6268
- return _regeneratorRuntime().wrap(function _callee3$(_context3) {
6269
- while (1) switch (_context3.prev = _context3.next) {
6270
- case 0:
6271
- _this7.unreadNum = num;
6272
- _this7.$emit('getate', _this7.unreadNum);
6273
- _this7.updataLM = false;
6274
- _this7.$nextTick(function () {
6275
- _this7.updataLM = true;
6276
- });
6277
- case 4:
6278
- case "end":
6279
- return _context3.stop();
6280
- }
6281
- }, _callee3);
6282
- }))();
6283
- },
6284
- drafts: function drafts(val) {
6285
- var _this8 = this;
6286
- return _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
6287
- return _regeneratorRuntime().wrap(function _callee4$(_context4) {
6288
- while (1) switch (_context4.prev = _context4.next) {
6289
- case 0:
6290
- _this8.draftsNum = val;
6291
- _this8.updataLm = false;
6292
- _this8.$nextTick(function () {
6293
- _this8.updataLm = true;
6294
- });
6295
- case 3:
6296
- case "end":
6297
- return _context4.stop();
6298
- }
6299
- }, _callee4);
6300
- }))();
6301
- },
6302
- resetRoute: function resetRoute(route) {
6303
- if (route.meta && route.meta.title === '收件箱') {
6304
- if (route.children && route.children.length > 0 && this.unreadNum > 0) {
6305
- route.children[0].alias = '收件箱(' + this.unreadNum + ')';
6306
- if (route.children[0].meta) route.children[0].meta.title = '收件箱(' + this.unreadNum + ')';
6307
- } else {
6308
- route.children[0].alias = '收件箱';
6309
- if (route.children[0].meta) route.children[0].meta.title = '收件箱';
6310
- }
6311
- } else if (route.meta && route.meta.title === '草稿箱') {
6312
- if (route.children && route.children.length > 0 && this.draftsNum > 0) {
6313
- route.children[0].alias = '草稿箱' + this.draftsNum + ')';
6314
- if (route.children[0].meta) route.children[0].meta.title = '草稿箱(' + this.draftsNum + ')';
6315
- }
6316
- // else {
6317
- // route.children[0].alias = '草稿箱'
6318
- // if (route.children[0].meta)route.children[0].meta.title = '草稿箱' + 3
6319
- // }
6320
- }
6321
- return route;
2473
+ "color": "#666",
2474
+ "line-height": "20px"
6322
2475
  }
6323
- }
6324
- });
6325
- // CONCATENATED MODULE: ./packages/ecyoa/email/src/components/LeftMenu.vue?vue&type=script&lang=js&
6326
- /* harmony default export */ var components_LeftMenuvue_type_script_lang_js_ = (LeftMenuvue_type_script_lang_js_);
6327
- // EXTERNAL MODULE: ./packages/ecyoa/email/src/components/LeftMenu.vue?vue&type=style&index=0&id=670785a0&prod&lang=scss&
6328
- var LeftMenuvue_type_style_index_0_id_670785a0_prod_lang_scss_ = __webpack_require__("a907");
6329
-
6330
- // CONCATENATED MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
6331
- /* globals __VUE_SSR_CONTEXT__ */
6332
-
6333
- // IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
6334
- // This module is a runtime utility for cleaner component module output and will
6335
- // be included in the final webpack user bundle.
6336
-
6337
- function normalizeComponent(
6338
- scriptExports,
6339
- render,
6340
- staticRenderFns,
6341
- functionalTemplate,
6342
- injectStyles,
6343
- scopeId,
6344
- moduleIdentifier /* server only */,
6345
- shadowMode /* vue-cli only */
6346
- ) {
6347
- // Vue.extend constructor export interop
6348
- var options =
6349
- typeof scriptExports === 'function' ? scriptExports.options : scriptExports
6350
-
6351
- // render functions
6352
- if (render) {
6353
- options.render = render
6354
- options.staticRenderFns = staticRenderFns
6355
- options._compiled = true
6356
- }
6357
-
6358
- // functional template
6359
- if (functionalTemplate) {
6360
- options.functional = true
6361
- }
6362
-
6363
- // scopedId
6364
- if (scopeId) {
6365
- options._scopeId = 'data-v-' + scopeId
6366
- }
6367
-
6368
- var hook
6369
- if (moduleIdentifier) {
6370
- // server build
6371
- hook = function (context) {
6372
- // 2.3 injection
6373
- context =
6374
- context || // cached call
6375
- (this.$vnode && this.$vnode.ssrContext) || // stateful
6376
- (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
6377
- // 2.2 with runInNewContext: true
6378
- if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
6379
- context = __VUE_SSR_CONTEXT__
2476
+ }, [_vm._v("最近登录:" + _vm._s(_vm.lastTimeLog.operateTime))])])]), _c('div', {
2477
+ staticClass: "optionListWrap",
2478
+ staticStyle: {
2479
+ "padding": "16px 0"
2480
+ }
2481
+ }, _vm._l(_vm.accountList, function (item) {
2482
+ return _c('div', {
2483
+ key: item.id,
2484
+ staticStyle: {
2485
+ "position": "relative"
6380
2486
  }
6381
- // inject component styles
6382
- if (injectStyles) {
6383
- injectStyles.call(this, context)
2487
+ }, [_c('div', {
2488
+ staticClass: "optionList",
2489
+ on: {
2490
+ "click": function click($event) {
2491
+ return _vm.selectMail(item);
2492
+ }
6384
2493
  }
6385
- // register component module identifier for async chunk inferrence
6386
- if (context && context._registeredComponents) {
6387
- context._registeredComponents.add(moduleIdentifier)
2494
+ }, [item.emailAddr === _vm.valueMail ? _c('span', {
2495
+ staticStyle: {
2496
+ "color": "#409EFF"
6388
2497
  }
6389
- }
6390
- // used by ssr in case component is cached and beforeCreate
6391
- // never gets called
6392
- options._ssrRegister = hook
6393
- } else if (injectStyles) {
6394
- hook = shadowMode
6395
- ? function () {
6396
- injectStyles.call(
6397
- this,
6398
- (options.functional ? this.parent : this).$root.$options.shadowRoot
6399
- )
6400
- }
6401
- : injectStyles
6402
- }
6403
-
6404
- if (hook) {
6405
- if (options.functional) {
6406
- // for template-only hot-reload because in that case the render fn doesn't
6407
- // go through the normalizer
6408
- options._injectStyles = hook
6409
- // register for functional component in vue file
6410
- var originalRender = options.render
6411
- options.render = function renderWithStyleInjection(h, context) {
6412
- hook.call(context)
6413
- return originalRender(h, context)
2498
+ }, [_vm._v(_vm._s(item.emailAddr) + " "), _c('span', [_vm._v("(" + _vm._s(_vm.unreadNum) + ")")])]) : _c('span', [_vm._v(_vm._s(item.emailAddr) + " "), _c('span', [_vm._v("(" + _vm._s(_vm.unreadNum) + ")")])])]), item.emailAddr === _vm.valueMail ? _c('img', {
2499
+ staticStyle: {
2500
+ "height": "16px",
2501
+ "position": "absolute",
2502
+ "top": "0",
2503
+ "right": "21px"
2504
+ },
2505
+ attrs: {
2506
+ "src": './images/w-imgs/success.png',
2507
+ "alt": ""
6414
2508
  }
6415
- } else {
6416
- // inject component registration as beforeCreate hook
6417
- var existing = options.beforeCreate
6418
- options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
6419
- }
6420
- }
6421
-
6422
- return {
6423
- exports: scriptExports,
6424
- options: options
6425
- }
6426
- }
6427
-
6428
- // CONCATENATED MODULE: ./packages/ecyoa/email/src/components/LeftMenu.vue
6429
-
6430
-
6431
-
6432
-
6433
-
2509
+ }) : _vm._e()]);
2510
+ }), 0)])]) : _c('div', {
2511
+ staticClass: "headInfo"
2512
+ })], 1), _vm.defultMail || _vm.awaitShow ? _c('app-main') : _vm._e(), _vm.showSettings ? _c('right-panel', [_c('settings')], 1) : _vm._e()], 1)], 1);
2513
+ };
2514
+ var staticRenderFns = [];
6434
2515
 
6435
- /* normalize component */
2516
+ // CONCATENATED MODULE: ./packages/ecyoa/email/src/index.vue?vue&type=template&id=5e809c44&scoped=true&
6436
2517
 
6437
- var component = normalizeComponent(
6438
- components_LeftMenuvue_type_script_lang_js_,
6439
- LeftMenuvue_type_template_id_670785a0_render,
6440
- LeftMenuvue_type_template_id_670785a0_staticRenderFns,
6441
- false,
6442
- null,
6443
- null,
6444
- null
6445
-
6446
- )
2518
+ // EXTERNAL MODULE: ./node_modules/vuex/dist/vuex.esm.js
2519
+ var vuex_esm = __webpack_require__("2f62");
6447
2520
 
6448
- /* harmony default export */ var LeftMenu = (component.exports);
6449
2521
  // CONCATENATED MODULE: ./node_modules/@vue/cli-plugin-babel/node_modules/cache-loader/dist/cjs.js??ref--13-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./packages/ecyoa/email/src/index.vue?vue&type=script&lang=js&
6450
- function srcvue_type_script_lang_js_typeof(o) { "@babel/helpers - typeof"; return srcvue_type_script_lang_js_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, srcvue_type_script_lang_js_typeof(o); }
6451
- function srcvue_type_script_lang_js_ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6452
- function srcvue_type_script_lang_js_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? srcvue_type_script_lang_js_ownKeys(Object(t), !0).forEach(function (r) { srcvue_type_script_lang_js_defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : srcvue_type_script_lang_js_ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6453
- function srcvue_type_script_lang_js_defineProperty(obj, key, value) { key = srcvue_type_script_lang_js_toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6454
- function srcvue_type_script_lang_js_toPropertyKey(t) { var i = srcvue_type_script_lang_js_toPrimitive(t, "string"); return "symbol" == srcvue_type_script_lang_js_typeof(i) ? i : i + ""; }
6455
- function srcvue_type_script_lang_js_toPrimitive(t, r) { if ("object" != srcvue_type_script_lang_js_typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != srcvue_type_script_lang_js_typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
2522
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2523
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
2524
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
2525
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
2526
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
2527
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
6456
2528
  var ResizeMixin = __webpack_require__("49ef").default;
6457
2529
  var getinitial = __webpack_require__("ef8d").default;
6458
-
2530
+ //import LeftMenu from './components/LeftMenu'
6459
2531
 
6460
2532
 
6461
2533
  /* harmony default export */ var srcvue_type_script_lang_js_ = ({
6462
2534
  name: 'MailLayout',
6463
- components: {
6464
- LeftMenu: LeftMenu
6465
- },
2535
+ components: {},
6466
2536
  mixins: [ResizeMixin],
6467
2537
  data: function data() {
6468
2538
  return {
@@ -6484,7 +2554,7 @@ var getinitial = __webpack_require__("ef8d").default;
6484
2554
  unreadNum: 0
6485
2555
  };
6486
2556
  },
6487
- computed: srcvue_type_script_lang_js_objectSpread(srcvue_type_script_lang_js_objectSpread(srcvue_type_script_lang_js_objectSpread({}, Object(vuex_esm["a" /* mapGetters */])(['routes'])), Object(vuex_esm["b" /* mapState */])({
2557
+ computed: _objectSpread(_objectSpread(_objectSpread({}, Object(vuex_esm["a" /* mapGetters */])(['routes'])), Object(vuex_esm["b" /* mapState */])({
6488
2558
  sidebar: function sidebar(state) {
6489
2559
  return state.app.sidebar;
6490
2560
  },
@@ -6669,8 +2739,6 @@ var getinitial = __webpack_require__("ef8d").default;
6669
2739
  },
6670
2740
  // 路由跳转
6671
2741
  gotoPages: function gotoPages(code) {
6672
- console.log(555555555555, code);
6673
- debugger;
6674
2742
  var toPath = this.getMenuCode(code);
6675
2743
  if (toPath && toPath.path) {
6676
2744
  var path;
@@ -6713,8 +2781,106 @@ var getinitial = __webpack_require__("ef8d").default;
6713
2781
  });
6714
2782
  // CONCATENATED MODULE: ./packages/ecyoa/email/src/index.vue?vue&type=script&lang=js&
6715
2783
  /* harmony default export */ var email_srcvue_type_script_lang_js_ = (srcvue_type_script_lang_js_);
6716
- // EXTERNAL MODULE: ./packages/ecyoa/email/src/index.vue?vue&type=style&index=0&id=66e2781e&prod&lang=scss&scoped=true&
6717
- var srcvue_type_style_index_0_id_66e2781e_prod_lang_scss_scoped_true_ = __webpack_require__("1829");
2784
+ // EXTERNAL MODULE: ./packages/ecyoa/email/src/index.vue?vue&type=style&index=0&id=5e809c44&prod&lang=scss&scoped=true&
2785
+ var srcvue_type_style_index_0_id_5e809c44_prod_lang_scss_scoped_true_ = __webpack_require__("8979");
2786
+
2787
+ // CONCATENATED MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
2788
+ /* globals __VUE_SSR_CONTEXT__ */
2789
+
2790
+ // IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
2791
+ // This module is a runtime utility for cleaner component module output and will
2792
+ // be included in the final webpack user bundle.
2793
+
2794
+ function normalizeComponent(
2795
+ scriptExports,
2796
+ render,
2797
+ staticRenderFns,
2798
+ functionalTemplate,
2799
+ injectStyles,
2800
+ scopeId,
2801
+ moduleIdentifier /* server only */,
2802
+ shadowMode /* vue-cli only */
2803
+ ) {
2804
+ // Vue.extend constructor export interop
2805
+ var options =
2806
+ typeof scriptExports === 'function' ? scriptExports.options : scriptExports
2807
+
2808
+ // render functions
2809
+ if (render) {
2810
+ options.render = render
2811
+ options.staticRenderFns = staticRenderFns
2812
+ options._compiled = true
2813
+ }
2814
+
2815
+ // functional template
2816
+ if (functionalTemplate) {
2817
+ options.functional = true
2818
+ }
2819
+
2820
+ // scopedId
2821
+ if (scopeId) {
2822
+ options._scopeId = 'data-v-' + scopeId
2823
+ }
2824
+
2825
+ var hook
2826
+ if (moduleIdentifier) {
2827
+ // server build
2828
+ hook = function (context) {
2829
+ // 2.3 injection
2830
+ context =
2831
+ context || // cached call
2832
+ (this.$vnode && this.$vnode.ssrContext) || // stateful
2833
+ (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
2834
+ // 2.2 with runInNewContext: true
2835
+ if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
2836
+ context = __VUE_SSR_CONTEXT__
2837
+ }
2838
+ // inject component styles
2839
+ if (injectStyles) {
2840
+ injectStyles.call(this, context)
2841
+ }
2842
+ // register component module identifier for async chunk inferrence
2843
+ if (context && context._registeredComponents) {
2844
+ context._registeredComponents.add(moduleIdentifier)
2845
+ }
2846
+ }
2847
+ // used by ssr in case component is cached and beforeCreate
2848
+ // never gets called
2849
+ options._ssrRegister = hook
2850
+ } else if (injectStyles) {
2851
+ hook = shadowMode
2852
+ ? function () {
2853
+ injectStyles.call(
2854
+ this,
2855
+ (options.functional ? this.parent : this).$root.$options.shadowRoot
2856
+ )
2857
+ }
2858
+ : injectStyles
2859
+ }
2860
+
2861
+ if (hook) {
2862
+ if (options.functional) {
2863
+ // for template-only hot-reload because in that case the render fn doesn't
2864
+ // go through the normalizer
2865
+ options._injectStyles = hook
2866
+ // register for functional component in vue file
2867
+ var originalRender = options.render
2868
+ options.render = function renderWithStyleInjection(h, context) {
2869
+ hook.call(context)
2870
+ return originalRender(h, context)
2871
+ }
2872
+ } else {
2873
+ // inject component registration as beforeCreate hook
2874
+ var existing = options.beforeCreate
2875
+ options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
2876
+ }
2877
+ }
2878
+
2879
+ return {
2880
+ exports: scriptExports,
2881
+ options: options
2882
+ }
2883
+ }
6718
2884
 
6719
2885
  // CONCATENATED MODULE: ./packages/ecyoa/email/src/index.vue
6720
2886
 
@@ -6725,18 +2891,18 @@ var srcvue_type_style_index_0_id_66e2781e_prod_lang_scss_scoped_true_ = __webpac
6725
2891
 
6726
2892
  /* normalize component */
6727
2893
 
6728
- var src_component = normalizeComponent(
2894
+ var component = normalizeComponent(
6729
2895
  email_srcvue_type_script_lang_js_,
6730
2896
  render,
6731
2897
  staticRenderFns,
6732
2898
  false,
6733
2899
  null,
6734
- "66e2781e",
2900
+ "5e809c44",
6735
2901
  null
6736
2902
 
6737
2903
  )
6738
2904
 
6739
- /* harmony default export */ var email_src = (src_component.exports);
2905
+ /* harmony default export */ var email_src = (component.exports);
6740
2906
  // CONCATENATED MODULE: ./packages/ecyoa/email/index.js
6741
2907
  function email_typeof(o) { "@babel/helpers - typeof"; return email_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, email_typeof(o); }
6742
2908
  function email_ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }