@module-federation/devtools 0.22.0 → 0.23.0
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/dist/es/App.css +13 -0
- package/dist/es/App.js +461 -21
- package/dist/es/App.module.js +1 -1
- package/dist/es/App_module.css +293 -5
- package/dist/es/component/DependencyGraph/index.js +204 -0
- package/dist/es/component/DependencyGraph/index.module.js +5 -0
- package/dist/es/component/DependencyGraph/index_module.css +100 -0
- package/dist/es/component/{GraphItem → DependencyGraphItem}/index.js +20 -9
- package/dist/es/component/DependencyGraphItem/index.module.js +5 -0
- package/dist/es/component/DependencyGraphItem/index_module.css +95 -0
- package/dist/es/component/Form/index.js +192 -117
- package/dist/es/component/Form/index.module.js +1 -1
- package/dist/es/component/Form/index_module.css +176 -25
- package/dist/es/component/LanguageSwitch.js +50 -0
- package/dist/es/component/Layout/index.js +296 -49
- package/dist/es/component/Layout/index.module.js +1 -1
- package/dist/es/component/Layout/index_module.css +52 -32
- package/dist/es/component/ModuleInfo/index.js +313 -0
- package/dist/es/component/ModuleInfo/index.module.js +5 -0
- package/dist/es/component/ModuleInfo/index_module.css +184 -0
- package/dist/es/component/SharedDepsExplorer/FocusResultDisplay.js +35 -0
- package/dist/es/component/SharedDepsExplorer/FocusResultDisplay.module.js +5 -0
- package/dist/es/component/SharedDepsExplorer/FocusResultDisplay_module.css +45 -0
- package/dist/es/component/SharedDepsExplorer/index.js +495 -0
- package/dist/es/component/SharedDepsExplorer/index.module.js +5 -0
- package/dist/es/component/SharedDepsExplorer/index_module.css +467 -0
- package/dist/es/component/SharedDepsExplorer/share-utils.js +206 -0
- package/dist/es/component/ThemeToggle.js +19 -0
- package/dist/es/component/ThemeToggle.module.js +5 -0
- package/dist/es/component/ThemeToggle_module.css +12 -0
- package/dist/es/hooks/useDevtoolsTheme.js +77 -0
- package/dist/es/i18n/index.js +506 -0
- package/dist/es/template/constant.js +3 -19
- package/dist/es/utils/chrome/index.js +91 -38
- package/dist/es/utils/chrome/messages.js +6 -0
- package/dist/es/utils/chrome/override-remote.js +42 -0
- package/dist/es/utils/chrome/post-message-listener.js +2 -1
- package/dist/es/utils/chrome/post-message-start.js +10 -2
- package/dist/es/utils/chrome/storage.js +6 -1
- package/dist/es/utils/sdk/graph.js +25 -4
- package/dist/es/utils/sdk/index.js +9 -0
- package/dist/es/worker/index.js +168 -1
- package/dist/lib/App.css +13 -0
- package/dist/lib/App.js +451 -18
- package/dist/lib/App.module.js +1 -1
- package/dist/lib/App_module.css +293 -5
- package/dist/lib/component/DependencyGraph/index.js +226 -0
- package/dist/lib/component/{GraphItem → DependencyGraph}/index.module.js +1 -1
- package/dist/lib/component/DependencyGraph/index_module.css +100 -0
- package/dist/lib/component/{GraphItem → DependencyGraphItem}/index.js +23 -12
- package/dist/lib/component/{Graph → DependencyGraphItem}/index.module.js +1 -1
- package/dist/lib/component/DependencyGraphItem/index_module.css +95 -0
- package/dist/lib/component/Form/index.js +189 -115
- package/dist/lib/component/Form/index.module.js +1 -1
- package/dist/lib/component/Form/index_module.css +176 -25
- package/dist/lib/component/LanguageSwitch.js +80 -0
- package/dist/lib/component/Layout/index.js +290 -47
- package/dist/lib/component/Layout/index.module.js +1 -1
- package/dist/lib/component/Layout/index_module.css +52 -32
- package/dist/lib/component/ModuleInfo/index.js +343 -0
- package/dist/lib/component/ModuleInfo/index.module.js +25 -0
- package/dist/lib/component/ModuleInfo/index_module.css +184 -0
- package/dist/lib/component/SharedDepsExplorer/FocusResultDisplay.js +65 -0
- package/dist/lib/component/SharedDepsExplorer/FocusResultDisplay.module.js +25 -0
- package/dist/lib/component/SharedDepsExplorer/FocusResultDisplay_module.css +45 -0
- package/dist/lib/component/SharedDepsExplorer/index.js +502 -0
- package/dist/lib/component/SharedDepsExplorer/index.module.js +25 -0
- package/dist/lib/component/SharedDepsExplorer/index_module.css +467 -0
- package/dist/lib/component/SharedDepsExplorer/share-utils.js +237 -0
- package/dist/lib/component/ThemeToggle.js +49 -0
- package/dist/lib/component/ThemeToggle.module.js +25 -0
- package/dist/lib/component/ThemeToggle_module.css +12 -0
- package/dist/lib/hooks/useDevtoolsTheme.js +101 -0
- package/dist/lib/i18n/index.js +540 -0
- package/dist/lib/template/constant.js +4 -17
- package/dist/lib/utils/chrome/index.js +94 -38
- package/dist/lib/utils/chrome/messages.js +31 -0
- package/dist/lib/utils/chrome/override-remote.js +65 -0
- package/dist/lib/utils/chrome/post-message-listener.js +2 -1
- package/dist/lib/utils/chrome/post-message-start.js +10 -2
- package/dist/lib/utils/chrome/storage.js +5 -0
- package/dist/lib/utils/sdk/graph.js +25 -4
- package/dist/lib/utils/sdk/index.js +10 -0
- package/dist/lib/worker/index.js +156 -1
- package/dist/types/src/App.d.ts +2 -1
- package/dist/types/src/component/{Graph → DependencyGraph}/index.d.ts +0 -1
- package/dist/types/src/component/{GraphItem → DependencyGraphItem}/index.d.ts +0 -1
- package/dist/types/src/component/Form/index.d.ts +2 -0
- package/dist/types/src/component/LanguageSwitch.d.ts +2 -0
- package/dist/types/src/component/Layout/index.d.ts +0 -1
- package/dist/types/src/component/ModuleInfo/index.d.ts +8 -0
- package/dist/types/src/component/SharedDepsExplorer/FocusResultDisplay.d.ts +15 -0
- package/dist/types/src/component/SharedDepsExplorer/index.d.ts +6 -0
- package/dist/types/src/component/SharedDepsExplorer/share-utils.d.ts +44 -0
- package/dist/types/src/component/ThemeToggle.d.ts +8 -0
- package/dist/types/src/hooks/useDevtoolsTheme.d.ts +2 -0
- package/dist/types/src/i18n/index.d.ts +5 -0
- package/dist/types/src/init.d.ts +0 -1
- package/dist/types/src/template/constant.d.ts +2 -5
- package/dist/types/src/utils/chrome/index.d.ts +5 -3
- package/dist/types/src/utils/chrome/messages.d.ts +2 -0
- package/dist/types/src/utils/chrome/override-remote.d.ts +1 -0
- package/dist/types/src/utils/chrome/storage.d.ts +5 -4
- package/dist/types/src/utils/sdk/graph.d.ts +2 -1
- package/dist/types/src/utils/sdk/index.d.ts +1 -0
- package/dist/types/src/utils/types/common.d.ts +4 -0
- package/dist/types/src/worker/index.d.ts +1 -0
- package/package.json +18 -14
- package/dist/es/component/Graph/index.js +0 -127
- package/dist/es/component/Graph/index.module.js +0 -5
- package/dist/es/component/Graph/index_module.css +0 -12
- package/dist/es/component/GraphItem/index.module.js +0 -5
- package/dist/es/component/GraphItem/index_module.css +0 -61
- package/dist/lib/component/Graph/index.js +0 -149
- package/dist/lib/component/Graph/index_module.css +0 -12
- package/dist/lib/component/GraphItem/index_module.css +0 -61
|
@@ -1,47 +1,198 @@
|
|
|
1
|
-
.
|
|
1
|
+
.wrapper_20b79 {
|
|
2
2
|
display: flex;
|
|
3
|
-
|
|
3
|
+
flex-direction: column;
|
|
4
|
+
gap: 18px;
|
|
5
|
+
color: var(--color-text-1, #1f2937);
|
|
4
6
|
}
|
|
5
|
-
|
|
6
|
-
|
|
7
|
+
|
|
8
|
+
.sectionHeader_20b79 {
|
|
9
|
+
display: flex;
|
|
10
|
+
align-items: center;
|
|
11
|
+
justify-content: space-between;
|
|
12
|
+
gap: 18px;
|
|
13
|
+
padding: 12px 16px;
|
|
14
|
+
background: rgba(228, 228, 231, 0.1);
|
|
15
|
+
border: 1px solid rgba(228, 228, 231, 0.5);
|
|
7
16
|
}
|
|
8
|
-
|
|
9
|
-
|
|
17
|
+
|
|
18
|
+
.heading_20b79 {
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
gap: 6px;
|
|
10
22
|
flex: 1 1;
|
|
11
23
|
}
|
|
12
|
-
|
|
13
|
-
|
|
24
|
+
|
|
25
|
+
.titleRow_20b79 {
|
|
26
|
+
display: flex;
|
|
27
|
+
align-items: center;
|
|
28
|
+
gap: 10px;
|
|
29
|
+
font-size: 16px;
|
|
30
|
+
font-weight: 600;
|
|
31
|
+
color: var(--color-text-1, #1f2937);
|
|
32
|
+
}
|
|
33
|
+
.titleRow_20b79 .arco-icon {
|
|
34
|
+
color: rgba(23, 75, 180, 0.9);
|
|
35
|
+
font-size: 18px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.title_20b79 {
|
|
39
|
+
letter-spacing: 0.02em;
|
|
14
40
|
}
|
|
15
41
|
|
|
16
|
-
.
|
|
42
|
+
.subtitle_20b79 {
|
|
43
|
+
font-size: 12px;
|
|
44
|
+
color: var(--color-text-2, #4b5563);
|
|
45
|
+
line-height: 1.5;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.headerActions_20b79 {
|
|
17
49
|
display: flex;
|
|
18
50
|
align-items: center;
|
|
19
|
-
|
|
51
|
+
gap: 12px;
|
|
52
|
+
flex-wrap: wrap;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.badge_20b79 {
|
|
56
|
+
transform: scale(1.4);
|
|
57
|
+
margin-right: 6px;
|
|
20
58
|
}
|
|
21
|
-
|
|
22
|
-
|
|
59
|
+
|
|
60
|
+
.statusMessage_20b79 {
|
|
61
|
+
font-size: 12px;
|
|
62
|
+
color: var(--color-text-2, #4b5563);
|
|
63
|
+
max-width: 260px;
|
|
64
|
+
line-height: 1.4;
|
|
23
65
|
}
|
|
24
|
-
|
|
25
|
-
|
|
66
|
+
|
|
67
|
+
.divider_20b79 {
|
|
68
|
+
width: 1px;
|
|
69
|
+
height: 1px;
|
|
70
|
+
background: rgba(96, 165, 250, 0.3);
|
|
26
71
|
}
|
|
27
|
-
|
|
72
|
+
|
|
73
|
+
.hmrArea_20b79 {
|
|
28
74
|
display: flex;
|
|
29
|
-
flex: 1 1;
|
|
30
|
-
justify-content: flex-end;
|
|
31
75
|
align-items: center;
|
|
76
|
+
gap: 8px;
|
|
77
|
+
font-size: 12px;
|
|
78
|
+
color: var(--color-text-2, #4b5563);
|
|
32
79
|
}
|
|
33
|
-
|
|
34
|
-
|
|
80
|
+
|
|
81
|
+
.switch_20b79 .arco-switch {
|
|
82
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.9));
|
|
83
|
+
border-color: rgba(96, 165, 250, 0.35);
|
|
84
|
+
color: var(--color-text-2, #4b5563);
|
|
35
85
|
}
|
|
36
|
-
.
|
|
37
|
-
|
|
86
|
+
.switch_20b79 .arco-switch-checked {
|
|
87
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.9));
|
|
88
|
+
border-color: rgba(96, 165, 250, 0.35);
|
|
38
89
|
}
|
|
39
|
-
|
|
90
|
+
|
|
91
|
+
.rules_20b79 {
|
|
92
|
+
display: flex;
|
|
93
|
+
flex-direction: column;
|
|
94
|
+
gap: 16px;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.ruleCard_20b79 {
|
|
98
|
+
display: flex;
|
|
99
|
+
flex-direction: column;
|
|
100
|
+
gap: 14px;
|
|
101
|
+
padding: 18px;
|
|
102
|
+
border-radius: 18px;
|
|
103
|
+
border: 1px solid rgba(228, 228, 231, 0.5);
|
|
104
|
+
background: var(--color-bg-1, rgba(255, 255, 255, 0.9));
|
|
105
|
+
box-shadow: 0 15px 32px rgba(8, 11, 25, 0.45);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.ruleHeader_20b79 {
|
|
40
109
|
display: flex;
|
|
41
110
|
align-items: center;
|
|
111
|
+
justify-content: space-between;
|
|
42
112
|
}
|
|
43
|
-
|
|
113
|
+
|
|
114
|
+
.toggle_20b79 .arco-checkbox {
|
|
115
|
+
transform: scale(1.4);
|
|
116
|
+
}
|
|
117
|
+
.toggle_20b79 .arco-checkbox-icon {
|
|
118
|
+
border-radius: 6px;
|
|
119
|
+
border-color: rgba(228, 228, 231, 0.5);
|
|
120
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.1));
|
|
121
|
+
}
|
|
122
|
+
.toggle_20b79 .arco-checkbox-checked .arco-checkbox-icon {
|
|
123
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.1));
|
|
124
|
+
border-color: rgba(228, 228, 231, 0.5);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.inputs_20b79 {
|
|
128
|
+
display: flex;
|
|
129
|
+
flex-direction: column;
|
|
130
|
+
gap: 12px;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
@media (min-width: 520px) {
|
|
134
|
+
.inputs_20b79 {
|
|
135
|
+
flex-direction: row;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
.field_20b79 {
|
|
139
|
+
flex: 1 1;
|
|
140
|
+
}
|
|
141
|
+
.field_20b79 .arco-form-item-content {
|
|
142
|
+
width: 100%;
|
|
143
|
+
}
|
|
144
|
+
.field_20b79 .arco-select-view {
|
|
145
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.1));
|
|
146
|
+
border: 1px solid rgba(228, 228, 231, 0.5);
|
|
147
|
+
border-radius: 14px;
|
|
148
|
+
color: var(--color-text-1, #1f2937);
|
|
149
|
+
min-height: 42px;
|
|
150
|
+
padding: 6px 12px;
|
|
151
|
+
}
|
|
152
|
+
.field_20b79 .arco-select-view-input {
|
|
153
|
+
color: var(--color-text-2, #4b5563);
|
|
154
|
+
}
|
|
155
|
+
.field_20b79 .arco-select-view-placeholder {
|
|
156
|
+
color: var(--color-text-2, #4b5563);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.dropdown_20b79 {
|
|
160
|
+
background: var(--color-bg-1, rgba(255, 255, 255, 0.9));
|
|
161
|
+
border: 1px solid rgba(228, 228, 231, 0.5);
|
|
162
|
+
box-shadow: 0 16px 30px rgba(8, 11, 25, 0.45);
|
|
163
|
+
}
|
|
164
|
+
.dropdown_20b79 .arco-select-option {
|
|
165
|
+
color: var(--color-text-2, #4b5563);
|
|
166
|
+
}
|
|
167
|
+
.dropdown_20b79 .arco-select-option:hover,
|
|
168
|
+
.dropdown_20b79 .arco-select-option.arco-select-option-selected {
|
|
169
|
+
background: rgba(243, 244, 246, var(--form-control-alpha, 0.1));
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.delete_20b79 {
|
|
173
|
+
box-shadow: 0 8px 16px rgba(248, 113, 113, 0.18);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.emptyWrapper_20b79 {
|
|
177
|
+
border-radius: 16px;
|
|
178
|
+
border: 1px dashed rgba(228, 228, 231, 0.5);
|
|
179
|
+
padding: 28px 16px;
|
|
180
|
+
background: var(--color-bg-1, rgba(255, 255, 255, 0.9));
|
|
181
|
+
display: flex;
|
|
182
|
+
justify-content: center;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.empty_20b79 .arco-empty-description {
|
|
186
|
+
color: var(--color-text-2, #4b5563);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.footerHint_20b79 {
|
|
190
|
+
font-size: 11px;
|
|
191
|
+
color: var(--color-text-2, #4b5563);
|
|
192
|
+
text-align: right;
|
|
193
|
+
letter-spacing: 0.04em;
|
|
194
|
+
text-transform: uppercase;
|
|
195
|
+
align-items: center;
|
|
196
|
+
justify-content: center;
|
|
44
197
|
display: flex;
|
|
45
|
-
transform: scale(1.6);
|
|
46
|
-
margin: 0 0.6vw;
|
|
47
198
|
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { Button, Dropdown, Menu } from "@arco-design/web-react";
|
|
3
|
+
import { IconLanguage } from "@arco-design/web-react/icon";
|
|
4
|
+
import { useTranslation } from "react-i18next";
|
|
5
|
+
import { LANGUAGE_STORAGE_KEY } from "../i18n";
|
|
6
|
+
import styles from "./ThemeToggle.module";
|
|
7
|
+
const LANGUAGE_OPTIONS = [
|
|
8
|
+
{ value: "zh-CN", label: "中文" },
|
|
9
|
+
{ value: "en", label: "English" }
|
|
10
|
+
];
|
|
11
|
+
const persistLanguage = (lang) => {
|
|
12
|
+
var _a;
|
|
13
|
+
if (typeof window !== "undefined") {
|
|
14
|
+
try {
|
|
15
|
+
window.localStorage.setItem(LANGUAGE_STORAGE_KEY, lang);
|
|
16
|
+
} catch (e) {
|
|
17
|
+
}
|
|
18
|
+
const { chrome } = window;
|
|
19
|
+
const storage = (_a = chrome == null ? void 0 : chrome.storage) == null ? void 0 : _a.local;
|
|
20
|
+
if (storage && typeof storage.set === "function") {
|
|
21
|
+
try {
|
|
22
|
+
storage.set({ [LANGUAGE_STORAGE_KEY]: lang });
|
|
23
|
+
} catch (e) {
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
const LanguageSwitch = () => {
|
|
29
|
+
var _a;
|
|
30
|
+
const { i18n } = useTranslation();
|
|
31
|
+
const current = ((_a = i18n.language) == null ? void 0 : _a.toLowerCase()) || "zh-cn";
|
|
32
|
+
const value = current.startsWith("en") ? "en" : "zh-CN";
|
|
33
|
+
const handleChange = (next) => {
|
|
34
|
+
i18n.changeLanguage(next);
|
|
35
|
+
persistLanguage(next);
|
|
36
|
+
};
|
|
37
|
+
const droplist = /* @__PURE__ */ jsx(Menu, { onClickMenuItem: handleChange, selectedKeys: [value], children: LANGUAGE_OPTIONS.map((option) => /* @__PURE__ */ jsx(Menu.Item, { children: option.label }, option.value)) });
|
|
38
|
+
return /* @__PURE__ */ jsx(Dropdown, { droplist, trigger: "click", position: "br", children: /* @__PURE__ */ jsx(
|
|
39
|
+
Button,
|
|
40
|
+
{
|
|
41
|
+
icon: /* @__PURE__ */ jsx(IconLanguage, {}),
|
|
42
|
+
size: "default",
|
|
43
|
+
className: styles.themeToggle
|
|
44
|
+
}
|
|
45
|
+
) });
|
|
46
|
+
};
|
|
47
|
+
var LanguageSwitch_default = LanguageSwitch;
|
|
48
|
+
export {
|
|
49
|
+
LanguageSwitch_default as default
|
|
50
|
+
};
|