@titaui/pc 1.15.19 → 1.15.21-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/dialog-qq-docs/index.css +6 -0
- package/lib/components/nav-top/components/user-message/components/inform/index.css +0 -1
- package/lib/components/nav-top/index.js +7 -3
- package/lib/components/okr-flow/mini-map/index.css +1 -1
- package/lib/components/period-selector/index.js +1 -0
- package/package.json +1 -1
|
@@ -213,9 +213,9 @@ var NavTop = function NavTop() {
|
|
|
213
213
|
|
|
214
214
|
if (hash) {
|
|
215
215
|
var activeMenu = menu.find(function (item) {
|
|
216
|
-
var _item$href$split, _item$href$split
|
|
216
|
+
var _item$href$split, _item$href$split$, _item$href$split$$spl;
|
|
217
217
|
|
|
218
|
-
return hash.includes((_item$href$split = item.href.split('#')) === null || _item$href$split === void 0 ? void 0 : (_item$href$split$ = _item$href$split[1]) === null || _item$href$split$ === void 0 ? void 0 : _item$href$split$.split('?')[0]);
|
|
218
|
+
return hash.includes((_item$href$split = item.href.split('#')) === null || _item$href$split === void 0 ? void 0 : (_item$href$split$ = _item$href$split[1]) === null || _item$href$split$ === void 0 ? void 0 : (_item$href$split$$spl = _item$href$split$.split('?')) === null || _item$href$split$$spl === void 0 ? void 0 : _item$href$split$$spl[0]);
|
|
219
219
|
});
|
|
220
220
|
|
|
221
221
|
if (hash.includes('homepage')) {
|
|
@@ -226,7 +226,11 @@ var NavTop = function NavTop() {
|
|
|
226
226
|
if (activeMenu) {
|
|
227
227
|
setActiveMenuId(activeMenu.id);
|
|
228
228
|
} else {
|
|
229
|
-
|
|
229
|
+
if (menu.length <= 1) {
|
|
230
|
+
setActiveMenuId(-1);
|
|
231
|
+
} else {
|
|
232
|
+
setActiveMenuId(menu[1].id);
|
|
233
|
+
}
|
|
230
234
|
}
|
|
231
235
|
}
|
|
232
236
|
};
|