@rsdoctor/components 0.4.13 → 1.0.0-alpha.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.
Files changed (197) hide show
  1. package/README.md +1 -1
  2. package/dist/common/imgs/connection-point.js +11 -0
  3. package/dist/common/imgs/webpack.js +11 -0
  4. package/dist/common/svg/bundle-size.js +11 -0
  5. package/dist/common/svg/error.js +10 -0
  6. package/dist/common/svg/file-css.js +11 -0
  7. package/dist/common/svg/file-html.js +11 -0
  8. package/dist/common/svg/file-image.js +11 -0
  9. package/dist/common/svg/file-js.js +11 -0
  10. package/dist/common/svg/file-unknown.js +11 -0
  11. package/dist/common/svg/file.js +10 -0
  12. package/dist/common/svg/files/css.js +11 -0
  13. package/dist/common/svg/files/html.js +11 -0
  14. package/dist/common/svg/files/image.js +11 -0
  15. package/dist/common/svg/files/js.js +11 -0
  16. package/dist/common/svg/files/unkown-file.js +11 -0
  17. package/dist/common/svg/loader/input.js +11 -0
  18. package/dist/common/svg/loader/output.js +12 -0
  19. package/dist/common/svg/loader/step.js +7 -0
  20. package/dist/common/svg/navbar/bundle-size-active.js +10 -0
  21. package/dist/common/svg/navbar/bundle-size-inactive.js +10 -0
  22. package/dist/common/svg/navbar/compile-analysis-active.js +11 -0
  23. package/dist/common/svg/navbar/compile-analysis-inactive.js +11 -0
  24. package/dist/common/svg/navbar/overall-active.js +11 -0
  25. package/dist/common/svg/navbar/overall-inactive.js +11 -0
  26. package/dist/common/svg/output.js +12 -0
  27. package/dist/common/svg/source-size.js +12 -0
  28. package/dist/common/svg/source.js +10 -0
  29. package/dist/common/svg/total-size.js +11 -0
  30. package/dist/common/svg/version.js +11 -0
  31. package/dist/components/Alert/ecma-version-check.d.ts +2 -0
  32. package/dist/components/Alert/ecma-version-check.js +69 -0
  33. package/dist/components/Alert/ecma-version-check.module.js +5 -0
  34. package/dist/components/Alert/ecma-version-check_module.css +23 -0
  35. package/dist/components/Alert/package-relation.d.ts +1 -2
  36. package/dist/components/Alert/package-relation.js +29 -59
  37. package/dist/components/Alert/package-relation.module.js +5 -0
  38. package/dist/components/Alert/package-relation_module.css +23 -0
  39. package/dist/components/Alert/types.d.ts +6 -1
  40. package/dist/components/Alerts/{common.d.ts → bundle-alert.d.ts} +3 -4
  41. package/dist/components/Alerts/bundle-alert.js +156 -0
  42. package/dist/components/Alerts/bundle-alert.module.js +5 -0
  43. package/dist/components/Alerts/bundle-alert_module.css +46 -0
  44. package/dist/components/Alerts/bundle.js +25 -6
  45. package/dist/components/Alerts/collapse.d.ts +6 -0
  46. package/dist/components/Alerts/collapse.js +209 -0
  47. package/dist/components/Alerts/collapse.module.js +5 -0
  48. package/dist/components/Alerts/collapse_module.css +71 -0
  49. package/dist/components/Alerts/compile.js +18 -5
  50. package/dist/components/Alerts/list.d.ts +4 -0
  51. package/dist/components/Alerts/list.js +25 -0
  52. package/dist/components/Alerts/list.module.js +5 -0
  53. package/dist/components/Alerts/list_module.css +5 -0
  54. package/dist/components/Alerts/overlay.js +67 -28
  55. package/dist/components/Alerts/overlay.module.js +5 -0
  56. package/dist/components/Alerts/overlay_module.css +11 -0
  57. package/dist/components/Card/index.d.ts +1 -1
  58. package/dist/components/Card/index.js +8 -18
  59. package/dist/components/Card/size.d.ts +1 -0
  60. package/dist/components/Card/size.js +99 -65
  61. package/dist/components/Card/size.module.js +5 -0
  62. package/dist/components/Card/size_module.css +34 -0
  63. package/dist/components/Card/statistic.d.ts +0 -2
  64. package/dist/components/Card/statistic.js +7 -5
  65. package/dist/components/Charts/TimelineCharts/index.d.ts +6 -1
  66. package/dist/components/Charts/TimelineCharts/index.js +208 -192
  67. package/dist/components/Charts/bootstrap.js +15 -10
  68. package/dist/components/Charts/common.d.ts +2 -0
  69. package/dist/components/Charts/common.js +18 -5
  70. package/dist/components/Charts/constants.d.ts +8 -1
  71. package/dist/components/Charts/constants.js +37 -41
  72. package/dist/components/Charts/done.js +14 -9
  73. package/dist/components/Charts/index.js +1 -1
  74. package/dist/components/Charts/loader.js +12 -2
  75. package/dist/components/Charts/minify.js +14 -9
  76. package/dist/components/Charts/utils.js +2 -2
  77. package/dist/components/CodeViewer/diff.js +8 -2
  78. package/dist/components/CodeViewer/viewer.js +0 -7
  79. package/dist/components/Configuration/builder.js +50 -36
  80. package/dist/components/Configuration/builder.module.js +5 -0
  81. package/dist/components/Configuration/builder_module.css +6 -0
  82. package/dist/components/FileTree/css.js +11 -0
  83. package/dist/components/FileTree/html.js +11 -0
  84. package/dist/components/FileTree/image.js +11 -0
  85. package/dist/components/FileTree/index.css +8 -0
  86. package/dist/components/FileTree/index.d.ts +1 -0
  87. package/dist/components/FileTree/index.js +65 -5
  88. package/dist/components/FileTree/js.js +11 -0
  89. package/dist/components/FileTree/unkown-file.js +11 -0
  90. package/dist/components/Form/keyword.js +3 -2
  91. package/dist/components/Keyword/index.js +38 -14
  92. package/dist/components/Keyword/style.module.js +5 -0
  93. package/dist/components/Keyword/style_module.css +5 -0
  94. package/dist/components/Layout/builder-select.js +37 -24
  95. package/dist/components/Layout/bundle-size-icon.js +10 -0
  96. package/dist/components/Layout/compile-icon.js +11 -0
  97. package/dist/components/Layout/header.css +7 -0
  98. package/dist/components/Layout/header.js +10 -17
  99. package/dist/components/Layout/menus.js +59 -64
  100. package/dist/components/Layout/overall-icon.js +10 -0
  101. package/dist/components/Layout/progress.js +2 -1
  102. package/dist/components/Loader/Analysis/files.js +187 -101
  103. package/dist/components/Loader/Analysis/index.js +34 -17
  104. package/dist/components/Loader/Analysis/input.js +11 -0
  105. package/dist/components/Loader/Analysis/output.js +12 -0
  106. package/dist/components/Loader/Analysis/style.module.js +5 -0
  107. package/dist/components/Loader/Analysis/style_module.css +73 -0
  108. package/dist/components/Loader/executions.js +95 -114
  109. package/dist/components/Loader/step.js +7 -0
  110. package/dist/components/Opener/code.js +2 -1
  111. package/dist/components/Overall/DataSummary.d.ts +8 -0
  112. package/dist/components/Overall/DataSummary.js +25 -0
  113. package/dist/components/Overall/DataSummary.module.js +5 -0
  114. package/dist/components/Overall/DataSummary_module.css +95 -0
  115. package/dist/components/Overall/bundle.d.ts +6 -1
  116. package/dist/components/Overall/bundle.js +208 -112
  117. package/dist/components/Overall/bundle.module.js +5 -0
  118. package/dist/components/Overall/bundle_module.css +67 -0
  119. package/dist/components/Overall/card_module.css +1 -4
  120. package/dist/components/Overall/compile.js +47 -41
  121. package/dist/components/Overall/compile.module.js +1 -1
  122. package/dist/components/Overall/compile_module.css +6 -0
  123. package/dist/components/Overall/help-center.d.ts +1 -0
  124. package/dist/components/Overall/help-center.js +86 -0
  125. package/dist/components/Overall/help-center.module.js +5 -0
  126. package/dist/components/Overall/help-center_module.css +35 -0
  127. package/dist/components/Overall/list.module.js +1 -1
  128. package/dist/components/Overall/list_module.css +14 -4
  129. package/dist/components/Overall/overview.d.ts +8 -0
  130. package/dist/components/Overall/overview.js +17 -0
  131. package/dist/components/Overall/overview.module.js +5 -0
  132. package/dist/components/Overall/overview_module.css +25 -0
  133. package/dist/components/Overall/project.d.ts +0 -1
  134. package/dist/components/Overall/project.js +101 -36
  135. package/dist/components/Overall/project.module.js +5 -0
  136. package/dist/components/Overall/project_module.css +19 -0
  137. package/dist/components/Select/index.css +6 -0
  138. package/dist/components/Select/index.d.ts +1 -0
  139. package/dist/components/Select/index.js +7 -4
  140. package/dist/components/TextDrawer/index.d.ts +2 -1
  141. package/dist/components/TextDrawer/index.js +38 -27
  142. package/dist/components/index.d.ts +0 -1
  143. package/dist/components/index.js +0 -1
  144. package/dist/constants.d.ts +1 -1
  145. package/dist/constants.js +1 -1
  146. package/dist/pages/BundleSize/components/asset.js +106 -124
  147. package/dist/pages/BundleSize/components/card.module.js +5 -0
  148. package/dist/pages/BundleSize/components/card_module.css +54 -0
  149. package/dist/pages/BundleSize/components/cards.js +157 -47
  150. package/dist/pages/BundleSize/components/index.js +129 -121
  151. package/dist/pages/BundleSize/components/index.module.js +5 -0
  152. package/dist/pages/BundleSize/components/index_module.css +82 -0
  153. package/dist/pages/ModuleAnalyze/components/fileTreeCom.css +13 -0
  154. package/dist/pages/ModuleAnalyze/components/fileTreeCom.d.ts +1 -1
  155. package/dist/pages/ModuleAnalyze/components/fileTreeCom.js +40 -63
  156. package/dist/pages/ModuleAnalyze/fileTree.d.ts +1 -0
  157. package/dist/pages/ModuleAnalyze/fileTree.js +36 -164
  158. package/dist/pages/ModuleAnalyze/index.css +7 -3
  159. package/dist/pages/ModuleAnalyze/index.d.ts +7 -1
  160. package/dist/pages/ModuleAnalyze/index.js +122 -45
  161. package/dist/pages/Overall/index.js +14 -9
  162. package/dist/pages/Overall/index.module.js +5 -0
  163. package/dist/pages/Overall/index_module.css +26 -0
  164. package/dist/pages/Overall/responsiveLayout.d.ts +6 -0
  165. package/dist/pages/Overall/responsiveLayout.js +9 -0
  166. package/dist/pages/Resources/BundleDiff/DiffContainer/modules.js +4 -4
  167. package/dist/pages/TreeShaking/editor.d.ts +3 -4
  168. package/dist/pages/TreeShaking/table.d.ts +3 -3
  169. package/dist/pages/TreeShaking/types.d.ts +2 -2
  170. package/dist/pages/TreeShaking/utils.d.ts +4 -5
  171. package/dist/pages/WebpackLoaders/Analysis/index.js +4 -1
  172. package/dist/pages/WebpackLoaders/Overall/index.js +8 -1
  173. package/dist/pages/WebpackPlugins/index.css +3 -0
  174. package/dist/pages/WebpackPlugins/index.d.ts +1 -0
  175. package/dist/pages/WebpackPlugins/index.js +61 -51
  176. package/dist/utils/data/brief.js +0 -2
  177. package/dist/utils/file.d.ts +4 -2
  178. package/dist/utils/file.js +40 -5
  179. package/dist/utils/i18n/cn.js +5 -0
  180. package/dist/utils/i18n/en.d.ts +5 -0
  181. package/dist/utils/i18n/en.js +5 -0
  182. package/package.json +8 -7
  183. package/dist/assets/connection-point.3b3c78ca.svg +0 -1
  184. package/dist/assets/webpack.98604d64.svg +0 -1
  185. package/dist/components/Alert/index.d.ts +0 -4
  186. package/dist/components/Alert/index.js +0 -34
  187. package/dist/components/Alert/link.d.ts +0 -3
  188. package/dist/components/Alert/link.js +0 -27
  189. package/dist/components/Alerts/common.js +0 -123
  190. package/dist/components/Card/statistic.css +0 -17
  191. package/dist/components/Overall/NumberButton.d.ts +0 -8
  192. package/dist/components/Overall/NumberButton.js +0 -29
  193. package/dist/components/Overall/NumberButton.module.js +0 -5
  194. package/dist/components/Overall/NumberButton_module.css +0 -70
  195. package/dist/components/Overall/bundle.module.css +0 -0
  196. package/dist/pages/Overall/responsiveGridList.d.ts +0 -6
  197. package/dist/pages/Overall/responsiveGridList.js +0 -28
@@ -1,9 +1,7 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { ClockCircleOutlined } from "@ant-design/icons";
2
+ import { ClockCircleTwoTone } from "@ant-design/icons";
3
3
  import Editor from "@monaco-editor/react";
4
4
  import {
5
- Badge,
6
- Button,
7
5
  Col,
8
6
  Divider,
9
7
  Empty,
@@ -13,10 +11,14 @@ import {
13
11
  Timeline,
14
12
  Tooltip,
15
13
  Typography,
16
- Tabs
14
+ Tabs,
15
+ List
17
16
  } from "antd";
18
17
  import dayjs from "dayjs";
19
18
  import { useCallback, useState } from "react";
19
+ import StepIcon from "../../common/svg/loader/step.js";
20
+ import InputIcon from "../../common/svg/loader/input.js";
21
+ import OutputIcon from "../../common/svg/loader/output.js";
20
22
  import { Size } from "../../constants";
21
23
  import {
22
24
  beautifyPath,
@@ -28,96 +30,67 @@ import { Card } from "../Card";
28
30
  import { DiffViewer } from "../CodeViewer";
29
31
  import { CodeOpener } from "../Opener";
30
32
  import { Title } from "../Title";
31
- const LoaderInfoItem = ({
32
- label,
33
- value,
34
- ellipsis = false,
35
- ...textProps
36
- }) => {
37
- return /* @__PURE__ */ jsxs(Row, { children: [
38
- /* @__PURE__ */ jsx(Col, { span: 6, children: /* @__PURE__ */ jsxs(Space, { children: [
39
- /* @__PURE__ */ jsx(Badge, { status: "processing" }),
40
- /* @__PURE__ */ jsx("div", { style: { width: 180 }, children: /* @__PURE__ */ jsx(Typography.Text, { strong: true, code: true, children: label }) }),
41
- /* @__PURE__ */ jsx(Divider, { type: "vertical" })
42
- ] }) }),
43
- /* @__PURE__ */ jsx(Col, { span: 18, children: /* @__PURE__ */ jsx(Typography.Paragraph, { ellipsis, strong: true, ...textProps, children: value }) })
44
- ] });
45
- };
33
+ import styles from "./Analysis/style.module";
46
34
  const LoaderPropsItem = ({
47
35
  loader,
48
36
  resource,
49
37
  cwd
50
38
  }) => {
51
- return /* @__PURE__ */ jsxs(
39
+ return /* @__PURE__ */ jsx(
52
40
  Card,
53
41
  {
54
42
  title: "Loader Details",
55
43
  style: { border: "none" },
56
- extra: /* @__PURE__ */ jsx(Tag, { icon: /* @__PURE__ */ jsx(ClockCircleOutlined, {}), color: "default", children: dayjs(loader.startAt).format("YYYY-MM-DD HH:mm:ss") }),
57
- children: [
44
+ extra: /* @__PURE__ */ jsx(Tag, { icon: /* @__PURE__ */ jsx(ClockCircleTwoTone, {}), color: "default", children: dayjs(loader.startAt).format("YYYY-MM-DD HH:mm:ss") }),
45
+ children: /* @__PURE__ */ jsxs(Space, { direction: "vertical", style: { width: "100%" }, children: [
58
46
  loader.isPitch ? /* @__PURE__ */ jsx(Typography.Text, { code: true, children: "pitch" }) : null,
59
- /* @__PURE__ */ jsxs(
60
- Space,
61
- {
62
- direction: "vertical",
63
- style: { padding: Size.BasePadding, wordBreak: "break-all" },
64
- children: [
65
- /* @__PURE__ */ jsx(
66
- LoaderInfoItem,
67
- {
68
- label: "file path",
69
- value: beautifyPath(resource.path, cwd),
70
- code: true
71
- }
72
- ),
73
- /* @__PURE__ */ jsx(
74
- LoaderInfoItem,
75
- {
76
- label: "resource path",
77
- value: /* @__PURE__ */ jsx(CodeOpener, { cwd, url: resource.path, loc: "", disabled: true })
78
- }
79
- ),
80
- /* @__PURE__ */ jsx(
81
- LoaderInfoItem,
82
- {
83
- label: "resource query",
84
- value: resource.queryRaw || "-"
85
- }
86
- ),
87
- /* @__PURE__ */ jsx(
88
- LoaderInfoItem,
89
- {
90
- label: "duration",
91
- value: formatCosts(loader.costs),
92
- mark: true
93
- }
94
- ),
95
- /* @__PURE__ */ jsx(LoaderInfoItem, { label: "loader name", value: loader.loader, code: true }),
96
- /* @__PURE__ */ jsx(LoaderInfoItem, { label: "loader index", value: `${loader.loaderIndex}` }),
97
- /* @__PURE__ */ jsx(
98
- LoaderInfoItem,
99
- {
100
- label: "loader path",
101
- value: /* @__PURE__ */ jsx(CodeOpener, { cwd, url: loader.path, loc: "", disabled: true })
102
- }
103
- ),
104
- /* @__PURE__ */ jsx(
105
- LoaderInfoItem,
106
- {
107
- label: "options",
108
- value: JSON.stringify(loader.options || "-"),
109
- copyable: true,
110
- ellipsis: {
111
- rows: 2,
112
- expandable: true,
113
- symbol: "more"
114
- }
115
- }
116
- )
117
- ]
118
- }
119
- )
120
- ]
47
+ /* @__PURE__ */ jsxs(List, { size: "large", bordered: true, children: [
48
+ /* @__PURE__ */ jsxs(List.Item, { children: [
49
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "File Path" }),
50
+ /* @__PURE__ */ jsx("div", { children: beautifyPath(resource.path, cwd) })
51
+ ] }),
52
+ /* @__PURE__ */ jsxs(List.Item, { children: [
53
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Resource Path" }),
54
+ /* @__PURE__ */ jsx(CodeOpener, { cwd, url: resource.path, loc: "", disabled: true })
55
+ ] }),
56
+ /* @__PURE__ */ jsxs(List.Item, { children: [
57
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Resource Query" }),
58
+ /* @__PURE__ */ jsx("div", { children: resource.queryRaw || "-" })
59
+ ] }),
60
+ /* @__PURE__ */ jsxs(List.Item, { children: [
61
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Duration" }),
62
+ /* @__PURE__ */ jsx("div", { children: formatCosts(loader.costs) })
63
+ ] }),
64
+ /* @__PURE__ */ jsxs(List.Item, { children: [
65
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Loader" }),
66
+ /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Typography.Text, { code: true, children: loader.loader }) })
67
+ ] }),
68
+ /* @__PURE__ */ jsxs(List.Item, { children: [
69
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Loader Index" }),
70
+ /* @__PURE__ */ jsx("div", { children: `${loader.loaderIndex}` })
71
+ ] }),
72
+ /* @__PURE__ */ jsxs(List.Item, { children: [
73
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Loader Path" }),
74
+ /* @__PURE__ */ jsx(CodeOpener, { cwd, url: loader.path, loc: "", disabled: true })
75
+ ] }),
76
+ /* @__PURE__ */ jsxs(List.Item, { children: [
77
+ /* @__PURE__ */ jsx("div", { style: { width: 180 }, children: /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Options" }) }),
78
+ /* @__PURE__ */ jsx(Divider, { type: "vertical" }),
79
+ /* @__PURE__ */ jsx(
80
+ Typography.Paragraph,
81
+ {
82
+ ellipsis: {
83
+ rows: 2,
84
+ expandable: true,
85
+ symbol: "more"
86
+ },
87
+ copyable: true,
88
+ children: JSON.stringify(loader.options || "-")
89
+ }
90
+ )
91
+ ] })
92
+ ] })
93
+ ] })
121
94
  }
122
95
  );
123
96
  };
@@ -138,7 +111,7 @@ const LoaderExecutions = ({
138
111
  const onChange = useCallback((key) => {
139
112
  setActiveKey(key);
140
113
  }, []);
141
- return /* @__PURE__ */ jsxs(Row, { style: { height: "100%" }, children: [
114
+ return /* @__PURE__ */ jsxs(Row, { className: styles.executions, style: { height: "100%" }, children: [
142
115
  /* @__PURE__ */ jsx(
143
116
  Col,
144
117
  {
@@ -151,43 +124,45 @@ const LoaderExecutions = ({
151
124
  /* @__PURE__ */ jsx(Title, { text: "Executions" }),
152
125
  /* @__PURE__ */ jsx(Timeline, { mode: "left", style: { marginTop: Size.BasePadding }, children: loaders.map((e, i, arr) => {
153
126
  const { loader: loader2, isPitch } = e;
127
+ const costs = formatCosts(e.costs);
154
128
  return /* @__PURE__ */ jsxs(
155
129
  Timeline.Item,
156
130
  {
157
- dot: isPitch ? /* @__PURE__ */ jsx(Tag, { style: { marginLeft: 1, fontWeight: 500 }, children: "pitch" }) : /* @__PURE__ */ jsx(ClockCircleOutlined, {}),
131
+ dot: isPitch ? /* @__PURE__ */ jsx(Tag, { style: { marginLeft: 1, fontWeight: 500 }, children: "pitch" }) : /* @__PURE__ */ jsx(ClockCircleTwoTone, {}),
158
132
  style: { paddingBottom: 10, textAlign: "center" },
159
133
  children: [
160
- /* @__PURE__ */ jsx(Row, { align: "middle", justify: "space-between", gutter: [0, 10], children: /* @__PURE__ */ jsx(Col, { span: 24, children: /* @__PURE__ */ jsx(Tooltip, { title: loader2, trigger: "hover", children: /* @__PURE__ */ jsx(
161
- Button,
134
+ /* @__PURE__ */ jsx(Row, { align: "middle", justify: "space-between", gutter: [0, 10], children: /* @__PURE__ */ jsx(Col, { span: 24, className: styles.timeline, children: /* @__PURE__ */ jsx(Tooltip, { title: loader2, trigger: "hover", children: /* @__PURE__ */ jsxs(
135
+ "div",
162
136
  {
163
- type: i === currentIndex ? "primary" : "default",
164
- block: true,
137
+ className: `${styles.box} ${currentIndex === i ? styles.selected : ""}`,
165
138
  onClick: () => {
166
139
  setCurrentIndex(i);
167
140
  },
168
141
  style: { textAlign: "left" },
169
- children: /* @__PURE__ */ jsxs(
170
- Typography.Text,
171
- {
172
- ellipsis: true,
173
- style: { color: "inherit" },
174
- children: [
175
- /* @__PURE__ */ jsx(
176
- Typography.Text,
177
- {
178
- strong: true,
179
- style: { color: "inherit" },
180
- children: formatCosts(e.costs)
181
- }
182
- ),
183
- /* @__PURE__ */ jsx(Divider, { type: "vertical" }),
184
- loader2
185
- ]
186
- }
187
- )
142
+ children: [
143
+ /* @__PURE__ */ jsxs("div", { children: [
144
+ /* @__PURE__ */ jsx(Typography.Text, { style: { color: "#000" }, children: costs.match(/[0-9]+/g) }),
145
+ " ",
146
+ /* @__PURE__ */ jsx(
147
+ Typography.Text,
148
+ {
149
+ style: { color: "rgba(0,0,0,0.45)" },
150
+ children: costs.match(/[a-zA-Z]+/g)
151
+ }
152
+ )
153
+ ] }),
154
+ /* @__PURE__ */ jsx(
155
+ Typography.Text,
156
+ {
157
+ style: { color: "rgba(0,0,0,0.65)" },
158
+ className: styles.loader,
159
+ children: loader2
160
+ }
161
+ )
162
+ ]
188
163
  }
189
164
  ) }) }) }),
190
- i === arr.length - 1 ? null : /* @__PURE__ */ jsx("div", { style: { paddingTop: 10 }, children: /* @__PURE__ */ jsx(Typography.Text, { children: "⬇️" }) })
165
+ i === arr.length - 1 ? null : /* @__PURE__ */ jsx("div", { style: { paddingTop: 10 }, children: /* @__PURE__ */ jsx(StepIcon, {}) })
191
166
  ]
192
167
  },
193
168
  i
@@ -238,7 +213,7 @@ const LoaderExecutions = ({
238
213
  /* @__PURE__ */ jsx("div", { style: { height: "90%" }, children: /* @__PURE__ */ jsx(
239
214
  Editor,
240
215
  {
241
- theme: "vs-dark",
216
+ theme: "vs",
242
217
  options: {
243
218
  readOnly: true,
244
219
  domReadOnly: true,
@@ -270,7 +245,7 @@ const LoaderExecutions = ({
270
245
  loader.isPitch ? loader.result ? /* @__PURE__ */ jsx("div", { style: { height: "90%" }, children: /* @__PURE__ */ jsx(
271
246
  Editor,
272
247
  {
273
- theme: "vs-dark",
248
+ theme: "vs",
274
249
  options: {
275
250
  readOnly: true,
276
251
  domReadOnly: true,
@@ -295,7 +270,10 @@ const LoaderExecutions = ({
295
270
  style: {
296
271
  padding: `${Size.BasePadding / 2}px ${Size.BasePadding}px`
297
272
  },
298
- children: /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Input" })
273
+ children: /* @__PURE__ */ jsxs(Space, { align: "center", className: styles.space, children: [
274
+ /* @__PURE__ */ jsx(InputIcon, {}),
275
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Input" })
276
+ ] })
299
277
  }
300
278
  ),
301
279
  /* @__PURE__ */ jsx(
@@ -305,7 +283,10 @@ const LoaderExecutions = ({
305
283
  style: {
306
284
  padding: `${Size.BasePadding / 2}px ${Size.BasePadding}px`
307
285
  },
308
- children: /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Output" })
286
+ children: /* @__PURE__ */ jsxs(Space, { align: "center", className: styles.space, children: [
287
+ /* @__PURE__ */ jsx(OutputIcon, {}),
288
+ /* @__PURE__ */ jsx(Typography.Text, { strong: true, children: "Output" })
289
+ ] })
309
290
  }
310
291
  )
311
292
  ] }),
@@ -0,0 +1,7 @@
1
+ import { jsx } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ const SvgStep = (props) => /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: 14, height: 14, fill: "none", viewBox: "0 0 14 14", ...props, children: /* @__PURE__ */ jsx("path", { fill: "#2994FF", d: "M7 10.736 1.7 6.589a.125.125 0 0 0-.201.098v1.208c0 .077.036.15.095.197l5.097 3.989a.5.5 0 0 0 .617 0l5.095-3.99a.248.248 0 0 0 .096-.196V6.687a.125.125 0 0 0-.202-.098L7 10.736Zm0-4.75L1.7 1.839a.125.125 0 0 0-.201.098v1.208c0 .077.036.15.095.197L6.692 7.33a.5.5 0 0 0 .617 0l5.095-3.99a.248.248 0 0 0 .096-.196V1.937a.125.125 0 0 0-.202-.098L7 5.986Z" }) });
4
+ var step_default = SvgStep;
5
+ export {
6
+ step_default as default
7
+ };
@@ -3,6 +3,7 @@ import { Typography } from "antd";
3
3
  import path from "path";
4
4
  import { startsWith } from "lodash-es";
5
5
  import { VSCode, openVSCode } from "./vscode";
6
+ import { getShortPath } from "../../utils";
6
7
  function parseUrl(url) {
7
8
  const strs = url.split(" ");
8
9
  let res = "";
@@ -54,7 +55,7 @@ const CodeOpener = ({
54
55
  },
55
56
  style: { cursor: disabled ? "revert" : "pointer" },
56
57
  children: [
57
- label || url,
58
+ label || getShortPath(url),
58
59
  loc ? `:${loc}` : ""
59
60
  ]
60
61
  }
@@ -0,0 +1,8 @@
1
+ export interface DataSummaryProps {
2
+ theme: 'common' | 'warning';
3
+ number: string | number;
4
+ onClick?: () => void;
5
+ description: string;
6
+ numberFontSize?: string;
7
+ }
8
+ export declare const DataSummary: ({ theme, number, description, }: DataSummaryProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,25 @@
1
+ import { jsx, jsxs } from "react/jsx-runtime";
2
+ import Icon from "@ant-design/icons";
3
+ import TotalSizeSvg from "../../common/svg/total-size.js";
4
+ import FileSvg from "../../common/svg/file.js";
5
+ import styles from "./DataSummary.module";
6
+ const DataSummary = ({
7
+ theme,
8
+ number,
9
+ description
10
+ }) => {
11
+ return /* @__PURE__ */ jsxs("div", { className: `${styles.container} ${styles[theme]}`, children: [
12
+ /* @__PURE__ */ jsx(
13
+ Icon,
14
+ {
15
+ style: { fontSize: "18px", margin: "0 5px" },
16
+ component: theme === "common" ? FileSvg : TotalSizeSvg
17
+ }
18
+ ),
19
+ /* @__PURE__ */ jsx("span", { className: styles.description, children: description }),
20
+ /* @__PURE__ */ jsx("span", { className: styles.data, children: number })
21
+ ] });
22
+ };
23
+ export {
24
+ DataSummary
25
+ };
@@ -0,0 +1,5 @@
1
+ import "./DataSummary_module.css";
2
+ var DataSummary_module_default = { "errorNumber": "errorNumber_14ee6", "warningNumber": "warningNumber_14ee6", "successNumber": "successNumber_14ee6", "errorText": "errorText_14ee6", "warningText": "warningText_14ee6", "successText": "successText_14ee6", "errorButton": "errorButton_14ee6", "warningButton": "warningButton_14ee6", "successButton": "successButton_14ee6", "container": "container_14ee6", "icon": "icon_14ee6", "description": "description_14ee6", "data": "data_14ee6", "common": "common_14ee6", "warning": "warning_14ee6" };
3
+ export {
4
+ DataSummary_module_default as default
5
+ };
@@ -0,0 +1,95 @@
1
+ .errorNumber_14ee6,
2
+ .warningNumber_14ee6,
3
+ .successNumber_14ee6 {
4
+ font-size: 14px;
5
+ font-weight: 500;
6
+ line-height: 32px;
7
+ }
8
+
9
+ .errorNumber_14ee6,
10
+ .errorText_14ee6 {
11
+ color: #f5222d;
12
+ }
13
+
14
+ .warningNumber_14ee6,
15
+ .warningText_14ee6 {
16
+ color: #fa8c16;
17
+ }
18
+
19
+ .successNumber_14ee6,
20
+ .successText_14ee6 {
21
+ color: #52c41a;
22
+ }
23
+
24
+ .errorButton_14ee6,
25
+ .warningButton_14ee6,
26
+ .successButton_14ee6 {
27
+ width: 100%;
28
+ height: 90px !important;
29
+ color: inherit;
30
+ font-size: inherit !important;
31
+ padding: 4px 0 8px !important;
32
+ border-radius: 12px !important;
33
+ }
34
+
35
+ .errorButton_14ee6 {
36
+ background-color: rgba(245, 34, 45, 0.08);
37
+ }
38
+ .errorButton_14ee6:hover {
39
+ background-color: rgba(245, 34, 45, 0.15) !important;
40
+ }
41
+
42
+ .warningButton_14ee6 {
43
+ background-color: rgba(250, 139, 22, 0.08);
44
+ }
45
+ .warningButton_14ee6:hover {
46
+ background-color: rgba(250, 139, 22, 0.15) !important;
47
+ }
48
+
49
+ .successButton_14ee6 {
50
+ background-color: rgba(82, 196, 26, 0.08);
51
+ }
52
+ .successButton_14ee6:hover {
53
+ background-color: rgba(82, 196, 26, 0.15) !important;
54
+ }
55
+
56
+ .errorText_14ee6,
57
+ .warningText_14ee6,
58
+ .successText_14ee6 {
59
+ opacity: 0.75;
60
+ font-size: 13px;
61
+ padding-bottom: 6px;
62
+ margin-top: -2px;
63
+ }
64
+
65
+ .container_14ee6 {
66
+ height: 40px;
67
+ display: flex;
68
+ align-items: center;
69
+ padding: 10px 20px 10px 5px;
70
+ border-radius: 10px;
71
+ margin: 10px 0 20px 0;
72
+ }
73
+ .container_14ee6 .icon_14ee6 {
74
+ margin: 0 5px 0 10px;
75
+ }
76
+ .container_14ee6 .description_14ee6 {
77
+ margin-right: 5px;
78
+ font-size: 14px;
79
+ font-weight: 400;
80
+ line-height: 20px;
81
+ color: rgba(0, 0, 0, 0.6509803922);
82
+ }
83
+ .container_14ee6 .data_14ee6 {
84
+ font-size: 14px;
85
+ font-weight: 500;
86
+ line-height: 32px;
87
+ }
88
+
89
+ .common_14ee6 {
90
+ background: #f0f5ff;
91
+ }
92
+
93
+ .warning_14ee6 {
94
+ background: #fff7e6;
95
+ }
@@ -1,5 +1,10 @@
1
1
  import React from 'react';
2
- import { SDK } from '@rsdoctor/types';
2
+ import { Client, SDK } from '@rsdoctor/types';
3
+ import type { TreeDataNode } from 'antd';
4
+ export declare const getFiles: (data: Client.RsdoctorClientAssetsSummary["all"]["total"]) => {
5
+ treeData: TreeDataNode[];
6
+ };
7
+ export declare const getFilesWithDrawer: (data: Client.RsdoctorClientAssetsSummary["all"]["total"]) => JSX.Element;
3
8
  export declare const BundleOverall: React.FC<{
4
9
  errors: SDK.ErrorsData;
5
10
  cwd: string;