vue-layout-gitcode 1.12.15-beta.1 → 1.12.15-beta.11
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/{GloabarSearch-NPtGnTQ1.js → GloabarSearch-DxJ6MLn8.js} +9 -9
- package/{MenuItem-D-NgnoC1.js → MenuItem-D4MiC6IG.js} +16 -13
- package/{ProjectMenuList-A573Arrk.js → ProjectMenuList-DZGYiODT.js} +23 -23
- package/{ProjectMenuListV2-DjpgvHQE.js → ProjectMenuListV2-EV89LR2x.js} +11 -11
- package/{ProjectSearch-D-9ryluX.js → ProjectSearch-BEwuDaPM.js} +19 -27
- package/{SearchHistoryList-awPBQlFr.js → SearchHistoryList-DmaxAvK8.js} +23 -16
- package/{SearchRecommed-8RHzmmRW.js → SearchRecommed-DZluuC-H.js} +8 -9
- package/{SearchScopeList-tBnniJs-.js → SearchScopeList-BYE_KyGE.js} +10 -13
- package/{UserSearch-vmcC6EeG.js → UserSearch-BzHQXmzE.js} +6 -6
- package/{index-bZAi191d.js → index-BOScKrtu.js} +71 -71
- package/{index-Z-gANvpG.js → index-BxHk52W8.js} +2 -2
- package/{index-CkQ6iZA_.js → index-EOrZj5ss.js} +4 -4
- package/{index-0AjxTFDx.js → index-G58a172b.js} +3009 -1882
- package/index.d.ts +2 -3
- package/index.js +11 -11
- package/{notice-BdcLXKWi.js → notice-B43kh3GE.js} +13 -14
- package/package.json +1 -1
- package/style.css +1 -1
- package/{transWebUrl-TUzSMmWj.js → transWebUrl-C4Zf5RBI.js} +1 -1
- package/SearchPrefixTag-Dqp_1PvV.js +0 -46
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent, inject,
|
|
1
|
+
import { defineComponent, inject, openBlock, createElementBlock, Fragment, createElementVNode, toDisplayString, unref, createVNode, renderList, withDirectives, createBlock, ref, watch, onMounted, createCommentVNode } from "vue";
|
|
2
2
|
import "vue-devui-lal/icon";
|
|
3
3
|
import "vue-devui-lal/icon/style.css";
|
|
4
|
-
import { h as headRequest, R as REPO_MODULE, a as i18n, G as GIcon, v as vElementExposure, b as REPO_EVENT, _ as _export_sfc, c as REPO_TYPE, e as extractRepoInfoWithURL } from "./index-
|
|
4
|
+
import { h as headRequest, R as REPO_MODULE, a as i18n, G as GIcon, v as vElementExposure, b as REPO_EVENT, _ as _export_sfc, c as REPO_TYPE, e as extractRepoInfoWithURL } from "./index-G58a172b.js";
|
|
5
5
|
import "lodash/debounce";
|
|
6
|
-
import { u as useReportRepo, S as SearchRepoCard, f as formatNameSpace } from "./index-
|
|
7
|
-
import "./transWebUrl-
|
|
6
|
+
import { u as useReportRepo, S as SearchRepoCard, f as formatNameSpace } from "./index-BOScKrtu.js";
|
|
7
|
+
import "./transWebUrl-C4Zf5RBI.js";
|
|
8
8
|
import "vue-devui-lal/tooltip";
|
|
9
9
|
import "vue-devui-lal/tooltip/style.css";
|
|
10
10
|
import "vue-router";
|
|
@@ -14,7 +14,7 @@ import "vue-devui-lal/grid/style.css";
|
|
|
14
14
|
import "vue-devui-lal/skeleton/style.css";
|
|
15
15
|
import "vue-devui-lal/popover";
|
|
16
16
|
import "vue-devui-lal/popover/style.css";
|
|
17
|
-
const _hoisted_1$1 = { class: "
|
|
17
|
+
const _hoisted_1$1 = { class: "mb-[4px] mt-[16px] flex justify-between" };
|
|
18
18
|
const _hoisted_2$1 = { class: "title" };
|
|
19
19
|
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
20
20
|
__name: "SearchRepoCardList",
|
|
@@ -67,7 +67,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
67
67
|
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.dataList, (item, index) => {
|
|
68
68
|
return withDirectives((openBlock(), createBlock(SearchRepoCard, {
|
|
69
69
|
key: item.id,
|
|
70
|
-
class: "
|
|
70
|
+
class: "mb-[8px]",
|
|
71
71
|
info: { ...item, index },
|
|
72
72
|
keyword: __props.searchStr,
|
|
73
73
|
hover: "",
|
|
@@ -89,15 +89,15 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
89
89
|
const SearchRepoCardList = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-vue-layout-gitcode"]]);
|
|
90
90
|
const _hoisted_1 = {
|
|
91
91
|
key: 0,
|
|
92
|
-
class: "history-list-project
|
|
92
|
+
class: "px-[8px] history-list-project pl-[8px]"
|
|
93
93
|
};
|
|
94
94
|
const _hoisted_2 = {
|
|
95
95
|
key: 1,
|
|
96
|
-
class: "history-list-project
|
|
96
|
+
class: "px-[8px] history-list-project pl-[8px]"
|
|
97
97
|
};
|
|
98
98
|
const _hoisted_3 = {
|
|
99
99
|
key: 2,
|
|
100
|
-
class: "history-list-project
|
|
100
|
+
class: "px-[8px] history-list-project pl-[8px]"
|
|
101
101
|
};
|
|
102
102
|
const _sfc_main = {
|
|
103
103
|
__name: "GloabarSearch",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent, inject, useSlots, computed, ref,
|
|
2
|
-
import { a as i18n, y as useLayoutConfig, A as ThemeType, B as currentTheme, L as LANG_ZH, C as LANG_EN, D as getLocaleLang, G as GIcon, F as emitEvent, H as isHttps, b as REPO_EVENT, _ as _export_sfc } from "./index-
|
|
1
|
+
import { defineComponent, inject, useSlots, computed, ref, openBlock, createBlock, unref, withCtx, createElementVNode, normalizeClass, createElementBlock, createCommentVNode, createTextVNode, toDisplayString, renderSlot } from "vue";
|
|
2
|
+
import { a as i18n, y as useLayoutConfig, A as ThemeType, B as currentTheme, L as LANG_ZH, C as LANG_EN, D as getLocaleLang, G as GIcon, F as emitEvent, H as isHttps, I as navigateWithMigrationGuard, b as REPO_EVENT, _ as _export_sfc } from "./index-G58a172b.js";
|
|
3
3
|
import { useRouter } from "vue-router";
|
|
4
4
|
import { Popover } from "vue-devui-lal/popover";
|
|
5
5
|
import "vue-devui-lal/popover/style.css";
|
|
@@ -8,10 +8,10 @@ const _hoisted_2 = {
|
|
|
8
8
|
key: 2,
|
|
9
9
|
class: "menu-item__badge"
|
|
10
10
|
};
|
|
11
|
-
const _hoisted_3 = { class: "
|
|
11
|
+
const _hoisted_3 = { class: "relative" };
|
|
12
12
|
const _hoisted_4 = {
|
|
13
13
|
key: 1,
|
|
14
|
-
class: "token-free-text"
|
|
14
|
+
class: "token-free-text bg-[#DBE2FA] text-[#2951E0] text-[12px] rounded-[4px] px-[4px] py-[2px]"
|
|
15
15
|
};
|
|
16
16
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
17
17
|
__name: "MenuItem",
|
|
@@ -93,7 +93,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
93
93
|
useReport(REPO_EVENT.CLICK, { module_name: `侧边栏_${reportName}` });
|
|
94
94
|
}
|
|
95
95
|
};
|
|
96
|
-
const handleMenuClick = () => {
|
|
96
|
+
const handleMenuClick = async () => {
|
|
97
97
|
var _a, _b;
|
|
98
98
|
const currentHref = window.location.href;
|
|
99
99
|
if (!props.item.left_menu_url) {
|
|
@@ -106,6 +106,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
106
106
|
emitEvent("login", { loginTriggerSource: `aside_${props.item.left_menu_url}` });
|
|
107
107
|
return;
|
|
108
108
|
}
|
|
109
|
+
if (props.item.left_menu_url === "/dashboard/downloads?tab=view") {
|
|
110
|
+
window.open(props.item.left_menu_url, "_blank");
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
109
113
|
if (props.item.left_menu_url === "/dashboard/downloads") {
|
|
110
114
|
(_b = (_a = globalStore.value) == null ? void 0 : _a.downloadClickRequest) == null ? void 0 : _b.call(_a);
|
|
111
115
|
}
|
|
@@ -113,14 +117,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
113
117
|
window.open(props.item.left_menu_url, "_blank");
|
|
114
118
|
} else if (isHttps(props.item.left_menu_url || "")) {
|
|
115
119
|
window.open(props.item.left_menu_url, "_self");
|
|
120
|
+
} else if (independence) {
|
|
121
|
+
window.open(layoutConfig.VITE_HOST + props.item.left_menu_url, "_self");
|
|
122
|
+
return;
|
|
116
123
|
} else {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
}
|
|
121
|
-
router.push({
|
|
122
|
-
path: props.item.left_menu_url
|
|
123
|
-
});
|
|
124
|
+
clickMenuReport();
|
|
125
|
+
await navigateWithMigrationGuard(router, { path: props.item.left_menu_url });
|
|
126
|
+
return;
|
|
124
127
|
}
|
|
125
128
|
clickMenuReport();
|
|
126
129
|
};
|
|
@@ -145,7 +148,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
145
148
|
]),
|
|
146
149
|
default: withCtx(() => [
|
|
147
150
|
createElementVNode("div", {
|
|
148
|
-
class: normalizeClass(["menu-item", { "menu-item__selected": isSelected.value
|
|
151
|
+
class: normalizeClass(["menu-item", { "menu-item__selected": isSelected.value }]),
|
|
149
152
|
onMouseenter: handleMouseEnter,
|
|
150
153
|
onMouseleave: handleMouseLeave,
|
|
151
154
|
onClick: handleMenuClick
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent, inject, ref, reactive, watch, computed,
|
|
2
|
-
import { a as i18n, y as useLayoutConfig, G as GIcon, t as transformUrl,
|
|
1
|
+
import { defineComponent, inject, ref, reactive, watch, computed, openBlock, createElementBlock, Fragment, createElementVNode, toDisplayString, unref, createVNode, withModifiers, normalizeClass, withCtx, renderList, createBlock, createCommentVNode, createTextVNode, withDirectives, vShow } from "vue";
|
|
2
|
+
import { a as i18n, y as useLayoutConfig, G as GIcon, t as transformUrl, K as _sfc_main$1, M as loadAsideData, I as navigateWithMigrationGuard, F as emitEvent, s as setLoginTriggerSource, f as useRequestReport, J as asideRequest, _ as _export_sfc } from "./index-G58a172b.js";
|
|
3
3
|
import { useRouter } from "vue-router";
|
|
4
|
-
import { t as transWebUrl } from "./transWebUrl-
|
|
4
|
+
import { t as transWebUrl } from "./transWebUrl-C4Zf5RBI.js";
|
|
5
5
|
import { Select, Option } from "vue-devui-lal/select";
|
|
6
6
|
import { Input } from "vue-devui-lal/input";
|
|
7
7
|
import { Skeleton } from "vue-devui-lal/skeleton";
|
|
@@ -12,25 +12,25 @@ import "vue-devui-lal/input/style.css";
|
|
|
12
12
|
import "vue-devui-lal/skeleton/style.css";
|
|
13
13
|
import "vue-devui-lal/menu/style.css";
|
|
14
14
|
import "vue-devui-lal/button/style.css";
|
|
15
|
-
const _hoisted_1 = { class: "devui-submenu layer_2 my-work-platform submenu-item
|
|
15
|
+
const _hoisted_1 = { class: "devui-submenu layer_2 my-work-platform submenu-item relative" };
|
|
16
16
|
const _hoisted_2 = {
|
|
17
17
|
class: "devui-submenu-title layer_2",
|
|
18
18
|
style: { "padding": "0px 24px" }
|
|
19
19
|
};
|
|
20
|
-
const _hoisted_3 = { class: "devui-submenu-title-content
|
|
20
|
+
const _hoisted_3 = { class: "devui-submenu-title-content cursor-auto" };
|
|
21
21
|
const _hoisted_4 = {
|
|
22
22
|
class: "devui-submenu-title layer_2",
|
|
23
23
|
style: { "padding": "0px 24px" }
|
|
24
24
|
};
|
|
25
|
-
const _hoisted_5 = { class: "devui-submenu-title-content
|
|
25
|
+
const _hoisted_5 = { class: "devui-submenu-title-content cursor-auto" };
|
|
26
26
|
const _hoisted_6 = {
|
|
27
27
|
class: "devui-submenu-title layer_2",
|
|
28
28
|
style: { "padding": "0px 24px" }
|
|
29
29
|
};
|
|
30
|
-
const _hoisted_7 = { class: "devui-submenu-title-content
|
|
30
|
+
const _hoisted_7 = { class: "devui-submenu-title-content cursor-auto" };
|
|
31
31
|
const _hoisted_8 = { key: 0 };
|
|
32
32
|
const _hoisted_9 = { class: "project-label" };
|
|
33
|
-
const _hoisted_10 = { class: "project-label
|
|
33
|
+
const _hoisted_10 = { class: "project-label flex-1 min-w-0 ellipsis" };
|
|
34
34
|
const _hoisted_11 = {
|
|
35
35
|
key: 1,
|
|
36
36
|
class: "project-label"
|
|
@@ -170,13 +170,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
170
170
|
}
|
|
171
171
|
return [...DEFAULT_ORG_FILTER_OPTIONS, ...moreOrgData.value];
|
|
172
172
|
});
|
|
173
|
-
const fastToLink = (type) => {
|
|
173
|
+
const fastToLink = async (type) => {
|
|
174
174
|
if (type === "project") {
|
|
175
|
-
router
|
|
175
|
+
await navigateWithMigrationGuard(router, { name: "userRepos", params: { namespace: props.username } });
|
|
176
176
|
} else if (type === "enterprise") {
|
|
177
177
|
window.location.href = transformUrl(`${layoutConfig.VITE_HOST}/setting/enterprise`);
|
|
178
178
|
} else {
|
|
179
|
-
router
|
|
179
|
+
await navigateWithMigrationGuard(router, { name: "settingOrganization" });
|
|
180
180
|
}
|
|
181
181
|
};
|
|
182
182
|
const loadMoreTeams = () => {
|
|
@@ -250,7 +250,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
250
250
|
};
|
|
251
251
|
return (_ctx, _cache) => {
|
|
252
252
|
return openBlock(), createElementBlock("ul", _hoisted_1, [
|
|
253
|
-
|
|
253
|
+
__props.type === "project" ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
254
254
|
createElementVNode("div", _hoisted_2, [
|
|
255
255
|
_cache[17] || (_cache[17] = createElementVNode("span", { class: "devui-menu-icon" }, null, -1)),
|
|
256
256
|
createElementVNode("span", _hoisted_3, [
|
|
@@ -267,7 +267,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
267
267
|
onClick: _cache[1] || (_cache[1] = withModifiers(($event) => showSearch.value = !showSearch.value, ["stop"]))
|
|
268
268
|
}),
|
|
269
269
|
createElementVNode("div", {
|
|
270
|
-
class: normalizeClass(["
|
|
270
|
+
class: normalizeClass(["flex flex-col pl-[0] my-work-platform-inputbox", showSearch.value ? "" : "my-work-platform-hideInputBox"]),
|
|
271
271
|
onClick: _cache[6] || (_cache[6] = withModifiers(() => {
|
|
272
272
|
}, ["stop"]))
|
|
273
273
|
}, [
|
|
@@ -275,7 +275,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
275
275
|
"menu-class": "my-work-platform-select",
|
|
276
276
|
modelValue: nameSpace.value,
|
|
277
277
|
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => nameSpace.value = $event),
|
|
278
|
-
class: "
|
|
278
|
+
class: "mb-[8px]",
|
|
279
279
|
placeholder: "",
|
|
280
280
|
filter: true,
|
|
281
281
|
onLoadMore: loadTeam,
|
|
@@ -311,7 +311,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
311
311
|
}, 8, ["modelValue", "placeholder"])
|
|
312
312
|
], 2)
|
|
313
313
|
], 64)) : createCommentVNode("", true),
|
|
314
|
-
|
|
314
|
+
__props.type === "team" ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
315
315
|
createElementVNode("div", _hoisted_4, [
|
|
316
316
|
_cache[18] || (_cache[18] = createElementVNode("span", { class: "devui-menu-icon" }, null, -1)),
|
|
317
317
|
createElementVNode("span", _hoisted_5, [
|
|
@@ -328,7 +328,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
328
328
|
color: "var(--theme-menu-icon-fill)"
|
|
329
329
|
}),
|
|
330
330
|
createElementVNode("div", {
|
|
331
|
-
class: normalizeClass(["
|
|
331
|
+
class: normalizeClass(["flex flex-col pl-[0] my-work-platform-inputbox", showSearch.value ? "" : "my-work-platform-hideInputBox"]),
|
|
332
332
|
onClick: _cache[11] || (_cache[11] = withModifiers(() => {
|
|
333
333
|
}, ["stop"]))
|
|
334
334
|
}, [
|
|
@@ -350,7 +350,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
350
350
|
}, 8, ["modelValue", "placeholder"])
|
|
351
351
|
], 2)
|
|
352
352
|
], 64)) : createCommentVNode("", true),
|
|
353
|
-
|
|
353
|
+
__props.type === "enterprise" ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
354
354
|
createElementVNode("div", _hoisted_6, [
|
|
355
355
|
_cache[19] || (_cache[19] = createElementVNode("span", { class: "devui-menu-icon" }, null, -1)),
|
|
356
356
|
createElementVNode("span", _hoisted_7, [
|
|
@@ -367,7 +367,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
367
367
|
color: "var(--theme-menu-icon-fill)"
|
|
368
368
|
}),
|
|
369
369
|
createElementVNode("div", {
|
|
370
|
-
class: normalizeClass(["
|
|
370
|
+
class: normalizeClass(["flex flex-col pl-[0] my-work-platform-inputbox", showSearch.value ? "" : "my-work-platform-hideInputBox"]),
|
|
371
371
|
onClick: _cache[16] || (_cache[16] = withModifiers(() => {
|
|
372
372
|
}, ["stop"]))
|
|
373
373
|
}, [
|
|
@@ -399,10 +399,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
399
399
|
"data-openBlank": true,
|
|
400
400
|
"data-href": unref(transformUrl)(unref(transWebUrl)(item.web_url)),
|
|
401
401
|
class: "text",
|
|
402
|
-
title:
|
|
402
|
+
title: __props.type === "project" ? `${item.namespace}/${item.label}` : item.label
|
|
403
403
|
}, {
|
|
404
404
|
icon: withCtx(() => [
|
|
405
|
-
|
|
405
|
+
__props.type === "project" ? (openBlock(), createBlock(GIcon, {
|
|
406
406
|
key: 0,
|
|
407
407
|
name: "gt-line-project",
|
|
408
408
|
color: "var(--theme-menu-icon-fill)",
|
|
@@ -417,7 +417,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
417
417
|
}, null, 8, ["src", "name", "class"]))
|
|
418
418
|
]),
|
|
419
419
|
default: withCtx(() => [
|
|
420
|
-
|
|
420
|
+
__props.type === "project" ? (openBlock(), createElementBlock("span", _hoisted_8, [
|
|
421
421
|
createElementVNode("span", _hoisted_9, toDisplayString((item.namespace || "").slice(0, 10)) + toDisplayString((item.namespace || "").length > 10 ? "..." : ""), 1),
|
|
422
422
|
createElementVNode("span", _hoisted_10, "/" + toDisplayString(item.label), 1)
|
|
423
423
|
])) : (openBlock(), createElementBlock("span", _hoisted_11, toDisplayString(item.label), 1))
|
|
@@ -425,14 +425,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
425
425
|
_: 2
|
|
426
426
|
}, 1032, ["data-href", "title"]);
|
|
427
427
|
}), 128)),
|
|
428
|
-
|
|
428
|
+
__props.type !== "enterprise" && !totalNum.value && !firstLoading.value ? (openBlock(), createBlock(unref(Button), {
|
|
429
429
|
key: 4,
|
|
430
430
|
variant: "text",
|
|
431
431
|
class: "more-btn",
|
|
432
432
|
onClick: withModifiers(createRepoOrOrg, ["stop"])
|
|
433
433
|
}, {
|
|
434
434
|
default: withCtx(() => [
|
|
435
|
-
createTextVNode(toDisplayString(
|
|
435
|
+
createTextVNode(toDisplayString(__props.buttonText), 1)
|
|
436
436
|
]),
|
|
437
437
|
_: 1
|
|
438
438
|
})) : createCommentVNode("", true),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent, inject, ref, reactive, computed, watch,
|
|
2
|
-
import { a as i18n, y as useLayoutConfig, t as transformUrl,
|
|
1
|
+
import { defineComponent, inject, ref, reactive, computed, watch, openBlock, createElementBlock, createElementVNode, toDisplayString, unref, createVNode, withModifiers, normalizeClass, withCtx, createBlock, createCommentVNode, Fragment, renderList, createTextVNode, withDirectives, vShow } from "vue";
|
|
2
|
+
import { a as i18n, y as useLayoutConfig, t as transformUrl, G as GIcon, J as asideRequest, I as navigateWithMigrationGuard, F as emitEvent, s as setLoginTriggerSource, f as useRequestReport, _ as _export_sfc } from "./index-G58a172b.js";
|
|
3
3
|
import { useRouter } from "vue-router";
|
|
4
|
-
import { t as transWebUrl } from "./transWebUrl-
|
|
4
|
+
import { t as transWebUrl } from "./transWebUrl-C4Zf5RBI.js";
|
|
5
5
|
import { Input } from "vue-devui-lal/input";
|
|
6
6
|
import { Skeleton } from "vue-devui-lal/skeleton";
|
|
7
7
|
import { MenuItem } from "vue-devui-lal/menu";
|
|
@@ -10,14 +10,14 @@ import "vue-devui-lal/input/style.css";
|
|
|
10
10
|
import "vue-devui-lal/skeleton/style.css";
|
|
11
11
|
import "vue-devui-lal/menu/style.css";
|
|
12
12
|
import "vue-devui-lal/button/style.css";
|
|
13
|
-
const _hoisted_1 = { class: "devui-submenu layer_2 my-work-platform submenu-item
|
|
13
|
+
const _hoisted_1 = { class: "devui-submenu layer_2 my-work-platform submenu-item relative" };
|
|
14
14
|
const _hoisted_2 = {
|
|
15
15
|
class: "devui-submenu-title layer_2",
|
|
16
16
|
style: { "padding": "0px 24px" }
|
|
17
17
|
};
|
|
18
|
-
const _hoisted_3 = { class: "devui-submenu-title-content
|
|
18
|
+
const _hoisted_3 = { class: "devui-submenu-title-content cursor-auto" };
|
|
19
19
|
const _hoisted_4 = { class: "project-label" };
|
|
20
|
-
const _hoisted_5 = { class: "project-label
|
|
20
|
+
const _hoisted_5 = { class: "project-label flex-1 min-w-0 ellipsis" };
|
|
21
21
|
const _hoisted_6 = ["href"];
|
|
22
22
|
const INIT_SHOW_COUNT = 4;
|
|
23
23
|
const LOAD_MORE_COUNT = 10;
|
|
@@ -113,8 +113,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
113
113
|
}, 200);
|
|
114
114
|
};
|
|
115
115
|
const router = useRouter();
|
|
116
|
-
const fastToLink = () => {
|
|
117
|
-
router
|
|
116
|
+
const fastToLink = async () => {
|
|
117
|
+
await navigateWithMigrationGuard(router, { name: "userRepos", params: { namespace: props.username } });
|
|
118
118
|
};
|
|
119
119
|
const handleOpenSearch = () => {
|
|
120
120
|
if (!props.isLogin) {
|
|
@@ -165,7 +165,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
165
165
|
onClick: withModifiers(handleOpenSearch, ["stop"])
|
|
166
166
|
}),
|
|
167
167
|
createElementVNode("div", {
|
|
168
|
-
class: normalizeClass(["
|
|
168
|
+
class: normalizeClass(["flex flex-col pl-[0] my-work-platform-inputbox", showSearch.value ? "" : "my-work-platform-hideInputBox"]),
|
|
169
169
|
onClick: _cache[4] || (_cache[4] = withModifiers(() => {
|
|
170
170
|
}, ["stop"]))
|
|
171
171
|
}, [
|
|
@@ -220,7 +220,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
220
220
|
onClick: withModifiers(createRepoOrOrg, ["stop"])
|
|
221
221
|
}, {
|
|
222
222
|
default: withCtx(() => [
|
|
223
|
-
createTextVNode(toDisplayString(
|
|
223
|
+
createTextVNode(toDisplayString(__props.buttonText), 1)
|
|
224
224
|
]),
|
|
225
225
|
_: 1
|
|
226
226
|
})) : createCommentVNode("", true),
|
|
@@ -241,7 +241,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
241
241
|
showTianqiRepo.value ? (openBlock(), createElementBlock("a", {
|
|
242
242
|
key: 2,
|
|
243
243
|
href: tianqiRepoUrl.value,
|
|
244
|
-
class: "
|
|
244
|
+
class: "flex-1 min-w-0 cursor-pointer more-btn"
|
|
245
245
|
}, toDisplayString(unref(t)("gitCodeLayout.org.tianqiRepo")) + " >", 9, _hoisted_6)) : createCommentVNode("", true)
|
|
246
246
|
]);
|
|
247
247
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { ref, inject, computed, withDirectives,
|
|
2
|
-
import { a as i18n, h as headRequest, G as GIcon, r as reqCatch } from "./index-
|
|
1
|
+
import { ref, inject, computed, withDirectives, openBlock, createElementBlock, createElementVNode, toDisplayString, unref, Fragment, renderList, createVNode, vShow } from "vue";
|
|
2
|
+
import { a as i18n, h as headRequest, G as GIcon, r as reqCatch } from "./index-G58a172b.js";
|
|
3
3
|
import { useRoute, useRouter } from "vue-router";
|
|
4
4
|
import "vue-devui-lal/icon";
|
|
5
5
|
import "vue-devui-lal/icon/style.css";
|
|
6
|
-
const _hoisted_1 = { class: "history-list-project
|
|
7
|
-
const _hoisted_2 = { class: "history-list-project-globartitle
|
|
6
|
+
const _hoisted_1 = { class: "px-[8px] history-list-project pl-[8px]" };
|
|
7
|
+
const _hoisted_2 = { class: "history-list-project-globartitle mb-[4px] mt-[16px]" };
|
|
8
8
|
const _hoisted_3 = ["href"];
|
|
9
|
-
const _hoisted_4 = { class: "history-list-project-globarbox" };
|
|
10
|
-
const _hoisted_5 = { class: "ellipsis
|
|
9
|
+
const _hoisted_4 = { class: "flex history-list-project-globarbox" };
|
|
10
|
+
const _hoisted_5 = { class: "ml-[8px] ellipsis" };
|
|
11
11
|
const _sfc_main = /* @__PURE__ */ Object.assign({ name: "SearchFileList" }, {
|
|
12
12
|
__name: "ProjectSearch",
|
|
13
13
|
props: ["searchStr", "searchInfo", "isSearchPage"],
|
|
@@ -42,30 +42,22 @@ const _sfc_main = /* @__PURE__ */ Object.assign({ name: "SearchFileList" }, {
|
|
|
42
42
|
params.namespace = namespace;
|
|
43
43
|
params.repoName = repoName;
|
|
44
44
|
} else {
|
|
45
|
-
params =
|
|
45
|
+
params = route == null ? void 0 : route.params;
|
|
46
46
|
}
|
|
47
47
|
const defaultBranch = props.searchInfo.branch;
|
|
48
48
|
const branchName = Array.isArray(defaultBranch) ? defaultBranch : defaultBranch == null ? void 0 : defaultBranch.split("/");
|
|
49
|
-
const
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}).href;
|
|
62
|
-
}
|
|
63
|
-
const joinSegments = (value) => {
|
|
64
|
-
const segmentList = Array.isArray(value) ? value : [value];
|
|
65
|
-
return segmentList.filter((seg) => seg !== void 0 && seg !== null && seg !== "").map((seg) => encodeURIComponent(String(seg))).join("/");
|
|
66
|
-
};
|
|
67
|
-
const repoSegment = params.repo || params.repoName;
|
|
68
|
-
return `/${params.namespace}/${repoSegment}/blob/${joinSegments(branchName)}/${joinSegments(filePathList)}?init=initTree`;
|
|
49
|
+
const routerPath = router.resolve({
|
|
50
|
+
name: "repoFile",
|
|
51
|
+
params: {
|
|
52
|
+
...params,
|
|
53
|
+
branchName,
|
|
54
|
+
filePath: filePath.split("/")
|
|
55
|
+
},
|
|
56
|
+
query: {
|
|
57
|
+
init: "initTree"
|
|
58
|
+
}
|
|
59
|
+
}).href;
|
|
60
|
+
return routerPath;
|
|
69
61
|
};
|
|
70
62
|
return (_ctx, _cache) => {
|
|
71
63
|
return withDirectives((openBlock(), createElementBlock("div", _hoisted_1, [
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent, computed,
|
|
2
|
-
import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-
|
|
1
|
+
import { defineComponent, computed, openBlock, createElementBlock, Fragment, renderList, normalizeClass, createElementVNode, createVNode, toDisplayString, withModifiers, createCommentVNode } from "vue";
|
|
2
|
+
import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-G58a172b.js";
|
|
3
3
|
import "vue-devui-lal/icon";
|
|
4
4
|
import "vue-devui-lal/icon/style.css";
|
|
5
5
|
const _hoisted_1 = { class: "history-list" };
|
|
6
6
|
const _hoisted_2 = ["onClick", "onMouseenter"];
|
|
7
|
-
const _hoisted_3 = { class: "history-list-box__content" };
|
|
8
|
-
const _hoisted_4 = { class: "
|
|
7
|
+
const _hoisted_3 = { class: "history-list-box__content flex items-center justify-between w-full" };
|
|
8
|
+
const _hoisted_4 = { class: "flex items-center" };
|
|
9
9
|
const _hoisted_5 = ["title"];
|
|
10
10
|
const _hoisted_6 = ["title"];
|
|
11
11
|
const _hoisted_7 = { class: "item-tx" };
|
|
12
|
-
const _hoisted_8 = { class: "
|
|
12
|
+
const _hoisted_8 = { class: "flex items-center gap-[8px]" };
|
|
13
13
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
14
14
|
__name: "SearchHistoryList",
|
|
15
15
|
props: {
|
|
@@ -87,9 +87,16 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
87
87
|
};
|
|
88
88
|
const historyList = computed(() => {
|
|
89
89
|
var _a;
|
|
90
|
-
return (_a = props.searchHistoryList) == null ? void 0 : _a.map((item) => {
|
|
90
|
+
return (_a = props.searchHistoryList) == null ? void 0 : _a.map((raw) => typeof raw === "string" ? { q: raw } : raw).filter((item) => item == null ? void 0 : item.q).map((item) => {
|
|
91
91
|
const repoTitle = item.repo ? `${t("gitCodeLayout.header.repo")} ${decodeURIComponent(item.repo)}:` : "";
|
|
92
|
-
const
|
|
92
|
+
const userVal = item.user || (item.scope === "user" ? item.namespace : "");
|
|
93
|
+
const orgVal = item.org || (item.scope === "user" ? "" : item.namespace);
|
|
94
|
+
let namespaceTitle = "";
|
|
95
|
+
if (userVal) {
|
|
96
|
+
namespaceTitle = `${t("gitCodeLayout.header.user")} ${decodeURIComponent(userVal)}:`;
|
|
97
|
+
} else if (orgVal) {
|
|
98
|
+
namespaceTitle = `${t("gitCodeLayout.header.org")} ${decodeURIComponent(orgVal)}:`;
|
|
99
|
+
}
|
|
93
100
|
return { ...item, repoTitle, namespaceTitle };
|
|
94
101
|
});
|
|
95
102
|
});
|
|
@@ -110,15 +117,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
110
117
|
};
|
|
111
118
|
return (_ctx, _cache) => {
|
|
112
119
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
113
|
-
|
|
120
|
+
__props.searchHistoryList.length ? (openBlock(), createElementBlock("ul", {
|
|
114
121
|
key: 0,
|
|
115
|
-
class: "history-list-box
|
|
122
|
+
class: "history-list-box mt-[16px]",
|
|
116
123
|
onMouseleave: resetIndex
|
|
117
124
|
}, [
|
|
118
125
|
(openBlock(true), createElementBlock(Fragment, null, renderList(historyList.value, (item, index) => {
|
|
119
126
|
return openBlock(), createElementBlock("li", {
|
|
120
127
|
key: item,
|
|
121
|
-
class: normalizeClass(
|
|
128
|
+
class: normalizeClass(__props.activeIndex === index ? "hoverbg" : ""),
|
|
122
129
|
onClick: ($event) => toSearch(item),
|
|
123
130
|
onMouseenter: ($event) => onSearchEnter(index)
|
|
124
131
|
}, [
|
|
@@ -127,24 +134,24 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
127
134
|
createVNode(GIcon, {
|
|
128
135
|
name: "gt-line-time",
|
|
129
136
|
color: "var(--devui-aide-text)",
|
|
130
|
-
class: "
|
|
137
|
+
class: "mr-[8px]"
|
|
131
138
|
}),
|
|
132
139
|
createElementVNode("span", {
|
|
133
|
-
class: "
|
|
140
|
+
class: "whitespace-nowrap overflow-hidden text-ellipsis",
|
|
134
141
|
title: item.repoTitle
|
|
135
142
|
}, toDisplayString(item.repoTitle), 9, _hoisted_5),
|
|
136
143
|
createElementVNode("span", {
|
|
137
|
-
class: "
|
|
144
|
+
class: "whitespace-nowrap overflow-hidden text-ellipsis",
|
|
138
145
|
title: item.namespaceTitle
|
|
139
146
|
}, toDisplayString(item.namespaceTitle), 9, _hoisted_6),
|
|
140
|
-
createElementVNode("span", _hoisted_7, toDisplayString(item.q
|
|
147
|
+
createElementVNode("span", _hoisted_7, toDisplayString(item.q), 1)
|
|
141
148
|
]),
|
|
142
149
|
createElementVNode("div", _hoisted_8, [
|
|
143
150
|
createElementVNode("span", {
|
|
144
|
-
class: normalizeClass(
|
|
151
|
+
class: normalizeClass(__props.activeIndex === index ? "text-[var(--theme-text)]" : "text-[var(--theme-placeholder)]")
|
|
145
152
|
}, toDisplayString(getRepoType(item).text), 3),
|
|
146
153
|
createVNode(GIcon, {
|
|
147
|
-
name:
|
|
154
|
+
name: __props.activeIndex === index ? getRepoType(item).hoverIcon : getRepoType(item).icon
|
|
148
155
|
}, null, 8, ["name"])
|
|
149
156
|
])
|
|
150
157
|
]),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent, inject, ref, onMounted,
|
|
2
|
-
import { u as useReportRepo, S as SearchRepoCard } from "./index-
|
|
3
|
-
import { a as i18n, h as headRequest, R as REPO_MODULE, b as REPO_EVENT, l as localStorage, _ as _export_sfc } from "./index-
|
|
1
|
+
import { defineComponent, inject, ref, onMounted, openBlock, createElementBlock, createElementVNode, toDisplayString, unref, Fragment, renderList, renderSlot, createBlock, createVNode, withCtx } from "vue";
|
|
2
|
+
import { u as useReportRepo, S as SearchRepoCard } from "./index-BOScKrtu.js";
|
|
3
|
+
import { a as i18n, h as headRequest, R as REPO_MODULE, b as REPO_EVENT, l as localStorage, _ as _export_sfc } from "./index-G58a172b.js";
|
|
4
4
|
import { Row, Col } from "vue-devui-lal/grid";
|
|
5
5
|
import { SkeletonItem } from "vue-devui-lal/skeleton";
|
|
6
6
|
import "vue-devui-lal/grid/style.css";
|
|
@@ -57,13 +57,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
57
57
|
createElementVNode("div", _hoisted_3, toDisplayString(unref($t)("gitCodeLayout.search.trendingToday")), 1),
|
|
58
58
|
(openBlock(true), createElementBlock(Fragment, null, renderList(recommendRepoList.value, (item, index) => {
|
|
59
59
|
return renderSlot(_ctx.$slots, "default", {
|
|
60
|
-
key: item.id,
|
|
61
60
|
item,
|
|
62
61
|
index
|
|
63
62
|
}, () => [
|
|
64
63
|
(openBlock(), createBlock(SearchRepoCard, {
|
|
65
64
|
key: item.id,
|
|
66
|
-
class: "
|
|
65
|
+
class: "mb-[8px]",
|
|
67
66
|
info: { ...item, index },
|
|
68
67
|
keyword: "",
|
|
69
68
|
hover: "",
|
|
@@ -72,12 +71,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
72
71
|
cardType: (item == null ? void 0 : item.repo_type) || "repo",
|
|
73
72
|
"url-params": { source_module: "search_box_discovery" }
|
|
74
73
|
}, null, 8, ["info", "onReport", "cardType"]))
|
|
75
|
-
], true);
|
|
74
|
+
], true, item.id);
|
|
76
75
|
}), 128))
|
|
77
76
|
])) : (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
78
77
|
(openBlock(), createElementBlock(Fragment, null, renderList(5, (item) => {
|
|
79
78
|
return createElementVNode("div", {
|
|
80
|
-
class: "
|
|
79
|
+
class: "pt-[8px] pb-[16px]",
|
|
81
80
|
key: item
|
|
82
81
|
}, [
|
|
83
82
|
createVNode(unref(Row), {
|
|
@@ -101,7 +100,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
101
100
|
_: 1
|
|
102
101
|
}),
|
|
103
102
|
createVNode(unref(Row), {
|
|
104
|
-
class: "
|
|
103
|
+
class: "mt-[12px]",
|
|
105
104
|
align: "middle",
|
|
106
105
|
gutter: 16
|
|
107
106
|
}, {
|
|
@@ -116,7 +115,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
116
115
|
_: 1
|
|
117
116
|
}),
|
|
118
117
|
createVNode(unref(Row), {
|
|
119
|
-
class: "
|
|
118
|
+
class: "mt-[12px]",
|
|
120
119
|
align: "middle",
|
|
121
120
|
gutter: 16
|
|
122
121
|
}, {
|
|
@@ -1,22 +1,20 @@
|
|
|
1
|
-
import { defineComponent,
|
|
2
|
-
import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-
|
|
1
|
+
import { defineComponent, openBlock, createElementBlock, Fragment, renderList, createElementVNode, createVNode, toDisplayString, createCommentVNode, unref } from "vue";
|
|
2
|
+
import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-G58a172b.js";
|
|
3
3
|
import "vue-devui-lal/icon";
|
|
4
4
|
import "vue-devui-lal/icon/style.css";
|
|
5
5
|
const _hoisted_1 = ["onClick"];
|
|
6
|
-
const _hoisted_2 = { class: "linkItem" };
|
|
6
|
+
const _hoisted_2 = { class: "flex linkItem pl-[9px] pr-[19px]" };
|
|
7
7
|
const _hoisted_3 = { class: "leftTx ellipsis" };
|
|
8
8
|
const _hoisted_4 = {
|
|
9
9
|
key: 0,
|
|
10
|
-
class: "
|
|
10
|
+
class: "ml-[4px]"
|
|
11
11
|
};
|
|
12
12
|
const _hoisted_5 = { key: 1 };
|
|
13
|
-
const _hoisted_6 = { class: "
|
|
14
|
-
const _hoisted_7 = { class: "right-text" };
|
|
13
|
+
const _hoisted_6 = { class: "right-text" };
|
|
15
14
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
16
15
|
__name: "SearchScopeList",
|
|
17
16
|
props: {
|
|
18
|
-
searchScopeList: {}
|
|
19
|
-
searchStr: {}
|
|
17
|
+
searchScopeList: {}
|
|
20
18
|
},
|
|
21
19
|
emits: ["scopeSearch"],
|
|
22
20
|
setup(__props, { emit: __emit }) {
|
|
@@ -27,10 +25,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
27
25
|
};
|
|
28
26
|
return (_ctx, _cache) => {
|
|
29
27
|
return openBlock(), createElementBlock("ul", null, [
|
|
30
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(
|
|
28
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.searchScopeList, (item, index) => {
|
|
31
29
|
return openBlock(), createElementBlock("li", {
|
|
32
30
|
key: index,
|
|
33
|
-
class: "g-header-search-scopechoose",
|
|
31
|
+
class: "g-header-search-scopechoose pt-[16px] px-[8px]",
|
|
34
32
|
onClick: ($event) => onScopeSearch(item)
|
|
35
33
|
}, [
|
|
36
34
|
createElementVNode("div", _hoisted_2, [
|
|
@@ -40,10 +38,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
40
38
|
class: "g-header-search-icon"
|
|
41
39
|
}),
|
|
42
40
|
item.label ? (openBlock(), createElementBlock("span", _hoisted_4, toDisplayString(item.label) + ":", 1)) : createCommentVNode("", true),
|
|
43
|
-
item.value ? (openBlock(), createElementBlock("span", _hoisted_5, toDisplayString(item.value), 1)) : createCommentVNode("", true)
|
|
44
|
-
createElementVNode("span", _hoisted_6, toDisplayString(_ctx.searchStr), 1)
|
|
41
|
+
item.value ? (openBlock(), createElementBlock("span", _hoisted_5, toDisplayString(item.value), 1)) : createCommentVNode("", true)
|
|
45
42
|
]),
|
|
46
|
-
createElementVNode("p",
|
|
43
|
+
createElementVNode("p", _hoisted_6, [
|
|
47
44
|
createElementVNode("span", null, toDisplayString(item.label ? `${item.label}${unref($t)("gitCodeLayout.header.underSearch")}` : item.title), 1),
|
|
48
45
|
createVNode(GIcon, { name: "gt-line-right" })
|
|
49
46
|
])
|