vue-layout-gitcode 1.1.26 → 1.1.27

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.
@@ -1,8 +1,8 @@
1
1
  import { inject, ref, watch, onMounted, createElementBlock, createCommentVNode, openBlock, createElementVNode, toDisplayString, unref, Fragment, renderList, createBlock } from "vue";
2
2
  import "vue-devui-lal/icon";
3
3
  import "vue-devui-lal/icon/style.css";
4
- import { a as i18n, h as headRequest, R as REPO_MODULE, b as REPO_TYPE, e as extractRepoInfoWithURL, c as REPO_EVENT } from "./index-C-L6yUgJ.js";
5
- import { u as useReportRepo, S as SearchRepoCard, f as formatNameSpace } from "./index-BQm-pUeu.js";
4
+ import { a as i18n, h as headRequest, R as REPO_MODULE, b as REPO_TYPE, e as extractRepoInfoWithURL, c as REPO_EVENT } from "./index-CFV2tQ1P.js";
5
+ import { u as useReportRepo, S as SearchRepoCard, f as formatNameSpace } from "./index-Ct2cthC3.js";
6
6
  const _hoisted_1 = {
7
7
  key: 0,
8
8
  class: "px-[8px] history-list-project pl-[8px]"
@@ -1,5 +1,5 @@
1
1
  import { ref, inject, computed, withDirectives, createElementBlock, openBlock, 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-C-L6yUgJ.js";
2
+ import { a as i18n, h as headRequest, G as GIcon, r as reqCatch } from "./index-CFV2tQ1P.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";
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, computed, createElementBlock, openBlock, createCommentVNode, Fragment, renderList, normalizeClass, createElementVNode, createVNode, toDisplayString, withModifiers } from "vue";
2
- import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-C-L6yUgJ.js";
2
+ import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-CFV2tQ1P.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" };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, createElementBlock, openBlock, createElementVNode, withDirectives, toDisplayString, withModifiers, createVNode, vShow } from "vue";
2
- import { G as GIcon, _ as _export_sfc } from "./index-C-L6yUgJ.js";
2
+ import { G as GIcon, _ as _export_sfc } from "./index-CFV2tQ1P.js";
3
3
  import "vue-devui-lal/icon";
4
4
  import "vue-devui-lal/icon/style.css";
5
5
  const _hoisted_1 = { class: "ellipsis" };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, inject, ref, onMounted, createElementBlock, openBlock, createElementVNode, toDisplayString, unref, Fragment, renderList, createBlock, createVNode, withCtx } from "vue";
2
- import { u as useReportRepo, S as SearchRepoCard } from "./index-BQm-pUeu.js";
3
- import { a as i18n, h as headRequest, R as REPO_MODULE, c as REPO_EVENT, l as localStorage, _ as _export_sfc } from "./index-C-L6yUgJ.js";
2
+ import { u as useReportRepo, S as SearchRepoCard } from "./index-Ct2cthC3.js";
3
+ import { a as i18n, h as headRequest, R as REPO_MODULE, c as REPO_EVENT, l as localStorage, _ as _export_sfc } from "./index-CFV2tQ1P.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";
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, createElementBlock, openBlock, Fragment, renderList, createElementVNode, createVNode, createCommentVNode, toDisplayString, unref } from "vue";
2
- import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-C-L6yUgJ.js";
2
+ import { a as i18n, G as GIcon, _ as _export_sfc } from "./index-CFV2tQ1P.js";
3
3
  import "vue-devui-lal/icon";
4
4
  import "vue-devui-lal/icon/style.css";
5
5
  const _hoisted_1 = ["onClick"];
@@ -1,5 +1,5 @@
1
1
  import { inject, ref, watch, withDirectives, createElementBlock, openBlock, createElementVNode, toDisplayString, unref, Fragment, renderList, createVNode, vShow } from "vue";
2
- import { a as i18n, h as headRequest, G as GIcon } from "./index-C-L6yUgJ.js";
2
+ import { a as i18n, h as headRequest, G as GIcon } from "./index-CFV2tQ1P.js";
3
3
  import "vue-devui-lal/icon";
4
4
  import "vue-devui-lal/icon/style.css";
5
5
  const _hoisted_1 = { class: "px-[8px] history-list-project pl-[8px]" };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent, onMounted, createBlock, openBlock, unref, withCtx, createElementVNode } from "vue";
2
2
  import { FixedOverlay } from "vue-devui-lal/overlay";
3
- import { q as useLayoutConfig, _ as _export_sfc } from "./index-C-L6yUgJ.js";
3
+ import { s as useLayoutConfig, _ as _export_sfc } from "./index-CFV2tQ1P.js";
4
4
  import "vue-devui-lal/overlay/style.css";
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "index",
@@ -17578,13 +17578,13 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
17578
17578
  setup(__props) {
17579
17579
  var _a;
17580
17580
  const { t: $t } = i18n.global;
17581
- const ProjectSearch = defineAsyncComponent(() => import("./ProjectSearch-BUP8uaCj.js"));
17582
- const UserSearch = defineAsyncComponent(() => import("./UserSearch-JAMg7W9B.js"));
17583
- const GloabarSearch = defineAsyncComponent(() => import("./GloabarSearch-DlBp6deP.js"));
17584
- const SearchHistoryList = defineAsyncComponent(() => import("./SearchHistoryList-C2uR-dRD.js"));
17585
- const SearchScopeList = defineAsyncComponent(() => import("./SearchScopeList-tBGWHbat.js"));
17586
- const SearchPrefixTag = defineAsyncComponent(() => import("./SearchPrefixTag-DGk5Ak40.js"));
17587
- const SearchRecommed = defineAsyncComponent(() => import("./SearchRecommed-CNJb8ccy.js"));
17581
+ const ProjectSearch = defineAsyncComponent(() => import("./ProjectSearch-DIUDDOhE.js"));
17582
+ const UserSearch = defineAsyncComponent(() => import("./UserSearch-ClxVMSBW.js"));
17583
+ const GloabarSearch = defineAsyncComponent(() => import("./GloabarSearch-56vbVPbb.js"));
17584
+ const SearchHistoryList = defineAsyncComponent(() => import("./SearchHistoryList-zGU0atw6.js"));
17585
+ const SearchScopeList = defineAsyncComponent(() => import("./SearchScopeList-BAh9utDs.js"));
17586
+ const SearchPrefixTag = defineAsyncComponent(() => import("./SearchPrefixTag-8efjsn5B.js"));
17587
+ const SearchRecommed = defineAsyncComponent(() => import("./SearchRecommed-CeqlOet6.js"));
17588
17588
  const props = __props;
17589
17589
  const repoInfo = inject("repoInfo");
17590
17590
  const orgInfo = inject("orgInfo");
@@ -18104,7 +18104,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
18104
18104
  }
18105
18105
  });
18106
18106
  const Search = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["__scopeId", "data-v-gitcode-layout-lib"]]);
18107
- const NoticeModal = defineAsyncComponent(() => import("./notice-Ikg9Y_ia.js"));
18107
+ const NoticeModal = defineAsyncComponent(() => import("./notice-Btov3im1.js"));
18108
18108
  function clearNotice() {
18109
18109
  if (localStorage$2.getItem("validator_email")) {
18110
18110
  localStorage$2.removeItem("validator_email");
@@ -18179,6 +18179,7 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
18179
18179
  provide("userInfo", computed(() => props.userInfo));
18180
18180
  provide("otherUserInfo", computed(() => props.otherUserInfo));
18181
18181
  provide("useReport", useReport2);
18182
+ provide("isLogin", computed(() => props.isLogin));
18182
18183
  const visibleItems = computed(() => {
18183
18184
  if (props.headerFunctions && props.headerFunctions.length > 0) {
18184
18185
  return props.headerFunctions;
@@ -24272,7 +24273,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
24272
24273
  }
24273
24274
  });
24274
24275
  const MFA = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-gitcode-layout-lib"]]);
24275
- const SlidCaptcha = defineAsyncComponent(() => import("./index-aMICzTxu.js"));
24276
+ const SlidCaptcha = defineAsyncComponent(() => import("./index-B_jU0Xm1.js"));
24276
24277
  const useSlidCaptcha = () => {
24277
24278
  const { mount, unMount } = usePopup("slid-captcha-popup");
24278
24279
  const open = (config) => {
@@ -25816,11 +25817,12 @@ const index = {
25816
25817
  }
25817
25818
  };
25818
25819
  export {
25819
- GitCodeLayoutEmitter as A,
25820
- currentTheme as B,
25821
- setTheme as C,
25822
- index as D,
25820
+ setLayoutConfig as A,
25821
+ GitCodeLayoutEmitter as B,
25822
+ currentTheme as C,
25823
+ setTheme as D,
25823
25824
  EVENT_NAME as E,
25825
+ index as F,
25824
25826
  GIcon as G,
25825
25827
  LANG_KEY as L,
25826
25828
  REPO_MODULE as R,
@@ -25832,25 +25834,25 @@ export {
25832
25834
  REPO_EVENT as c,
25833
25835
  debounce$1 as d,
25834
25836
  extractRepoInfoWithURL as e,
25835
- useTimeFormat as f,
25836
- LANG_ZH as g,
25837
+ useRequestReport as f,
25838
+ useTimeFormat as g,
25837
25839
  headRequest as h,
25838
25840
  isPhone as i,
25839
- usePageResize as j,
25840
- isGstarRepo as k,
25841
+ LANG_ZH as j,
25842
+ usePageResize as k,
25841
25843
  localStorage$2 as l,
25842
- _sfc_main$v as m,
25843
- isIncubationRepo as n,
25844
- highlightWords as o,
25845
- _frEventTrack as p,
25846
- useLayoutConfig as q,
25844
+ isGstarRepo as m,
25845
+ _sfc_main$v as n,
25846
+ isIncubationRepo as o,
25847
+ highlightWords as p,
25848
+ _frEventTrack as q,
25847
25849
  reqCatch as r,
25848
- ToolsFloat as s,
25850
+ useLayoutConfig as s,
25849
25851
  transWebUrl as t,
25850
25852
  useModel as u,
25851
- _sfc_main as v,
25852
- GitCodeAside as w,
25853
- GitCodeHeader as x,
25854
- useLogin as y,
25855
- setLayoutConfig as z
25853
+ ToolsFloat as v,
25854
+ _sfc_main as w,
25855
+ GitCodeAside as x,
25856
+ GitCodeHeader as y,
25857
+ useLogin as z
25856
25858
  };
@@ -1,5 +1,5 @@
1
1
  import { ref, watchEffect, defineComponent, toDisplayString, inject, createElementBlock, openBlock, normalizeClass, createElementVNode, withModifiers, withDirectives, vShow, createVNode, computed, createCommentVNode, unref, normalizeStyle, createTextVNode, onMounted, onUnmounted, Fragment, createBlock, renderList, reactive, withCtx } from "vue";
2
- import { d as debounce, h as headRequest, G as GIcon, r as reqCatch, _ as _export_sfc, a as i18n, T as TOPIC_TYPE, f as useTimeFormat, L as LANG_KEY, g as LANG_ZH, j as usePageResize, k as isGstarRepo, m as _sfc_main$8, n as isIncubationRepo, o as highlightWords, t as transWebUrl, p as _frEventTrack, E as EVENT_NAME, b as REPO_TYPE, e as extractRepoInfoWithURL } from "./index-C-L6yUgJ.js";
2
+ import { d as debounce, G as GIcon, f as useRequestReport, r as reqCatch, h as headRequest, _ as _export_sfc, a as i18n, T as TOPIC_TYPE, g as useTimeFormat, L as LANG_KEY, j as LANG_ZH, k as usePageResize, m as isGstarRepo, n as _sfc_main$8, o as isIncubationRepo, p as highlightWords, t as transWebUrl, q as _frEventTrack, E as EVENT_NAME, b as REPO_TYPE, e as extractRepoInfoWithURL } from "./index-CFV2tQ1P.js";
3
3
  import { useRouter } from "vue-router";
4
4
  import { Row, Col } from "vue-devui-lal/grid";
5
5
  import { Skeleton, SkeletonItem } from "vue-devui-lal/skeleton";
@@ -124,11 +124,16 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
124
124
  starInfo: { default: () => ({
125
125
  starred: false,
126
126
  starCount: 0
127
- }) }
127
+ }) },
128
+ loginTriggerSource: { default: "search_star_repo_recommend" }
128
129
  },
129
130
  emits: ["report"],
130
131
  setup(__props, { emit: __emit }) {
131
- const API = headRequest(inject("request"));
132
+ const request = inject("request");
133
+ const API = headRequest(request);
134
+ const globalStore = inject("globalStore");
135
+ const isLogin = inject("isLogin");
136
+ const { useReport } = useRequestReport(request, globalStore);
132
137
  const props = __props;
133
138
  const emits = __emit;
134
139
  const running = ref(false);
@@ -137,6 +142,9 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
137
142
  const starLoading = ref(false);
138
143
  const handleStar = async (e) => {
139
144
  e.preventDefault();
145
+ if (!isLogin.value) {
146
+ useReport("login_exposure", { source: props.loginTriggerSource || "search_star_repo_recommend" });
147
+ }
140
148
  try {
141
149
  if (starLoading.value) return;
142
150
  starLoading.value = true;
package/index.js CHANGED
@@ -1,14 +1,14 @@
1
- import { w, x, A, v, S, s, B, D, z, C, y } from "./index-C-L6yUgJ.js";
1
+ import { x, y, B, w, S, v, C, F, A, D, z } from "./index-CFV2tQ1P.js";
2
2
  export {
3
- w as GitCodeAside,
4
- x as GitCodeHeader,
5
- A as GitCodeLayoutEmitter,
6
- v as Login,
3
+ x as GitCodeAside,
4
+ y as GitCodeHeader,
5
+ B as GitCodeLayoutEmitter,
6
+ w as Login,
7
7
  S as SceneValue,
8
- s as ToolsFloat,
9
- B as currentTheme,
10
- D as default,
11
- z as setLayoutConfig,
12
- C as setTheme,
13
- y as useLogin
8
+ v as ToolsFloat,
9
+ C as currentTheme,
10
+ F as default,
11
+ A as setLayoutConfig,
12
+ D as setTheme,
13
+ z as useLogin
14
14
  };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent, computed, createBlock, openBlock, unref, isRef, withCtx, createElementVNode, normalizeClass, createVNode, createTextVNode } from "vue";
2
- import { i as isPhone, u as useModel } from "./index-C-L6yUgJ.js";
2
+ import { i as isPhone, u as useModel } from "./index-CFV2tQ1P.js";
3
3
  import { Notification } from "vue-devui-lal/notification";
4
4
  import { Button } from "vue-devui-lal/button";
5
5
  import "vue-devui-lal/notification/style.css";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue-layout-gitcode",
3
- "version": "1.1.26",
3
+ "version": "1.1.27",
4
4
  "description": "用于 gitcode 站点生产环境使用",
5
5
  "main": "index.js",
6
6
  "types": "./index.d.ts",