@alepha/devtools 0.19.1 → 0.19.3

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 (130) hide show
  1. package/assets/ui/200.html +10 -0
  2. package/assets/ui/200.html.br +1 -0
  3. package/assets/ui/404.html +10 -0
  4. package/assets/ui/404.html.br +1 -0
  5. package/assets/ui/CNAME +1 -0
  6. package/assets/ui/asset.CHpVij2M.css +1 -0
  7. package/assets/ui/asset.CHpVij2M.css.br +0 -0
  8. package/assets/ui/asset.Cxu56LSy.css +1 -0
  9. package/assets/ui/asset.Cxu56LSy.css.br +0 -0
  10. package/assets/ui/chunk.9plHAFDW.js +1 -0
  11. package/assets/ui/chunk.9plHAFDW.js.br +0 -0
  12. package/assets/ui/chunk.B82rsdDI.js +1 -0
  13. package/assets/ui/chunk.B82rsdDI.js.br +0 -0
  14. package/assets/ui/chunk.B9jGefQy.js +1 -0
  15. package/assets/ui/chunk.B9jGefQy.js.br +0 -0
  16. package/assets/ui/chunk.BHYZ9sAK.js +1 -0
  17. package/assets/ui/chunk.BHYZ9sAK.js.br +0 -0
  18. package/assets/ui/chunk.Bc7_n90V.js +1 -0
  19. package/assets/ui/chunk.Bc7_n90V.js.br +0 -0
  20. package/assets/ui/chunk.CCbhJSL_.js +1 -0
  21. package/assets/ui/chunk.CCbhJSL_.js.br +0 -0
  22. package/assets/ui/chunk.CJt_09bu.js +1 -0
  23. package/assets/ui/chunk.CJt_09bu.js.br +0 -0
  24. package/assets/ui/chunk.CK6Z-I-W.js +1 -0
  25. package/assets/ui/chunk.CK6Z-I-W.js.br +1 -0
  26. package/assets/ui/chunk.Cj1opA98.js +1 -0
  27. package/assets/ui/chunk.Cj1opA98.js.br +0 -0
  28. package/assets/ui/chunk.CvCu4yZb.js +2 -0
  29. package/assets/ui/chunk.CvCu4yZb.js.br +0 -0
  30. package/assets/ui/chunk.D93ZmnLR.js +1 -0
  31. package/assets/ui/chunk.D93ZmnLR.js.br +6 -0
  32. package/assets/ui/chunk.D9MCnLj_.js +7 -0
  33. package/assets/ui/chunk.D9MCnLj_.js.br +0 -0
  34. package/assets/ui/chunk.DOwjsMaD.js +1 -0
  35. package/assets/ui/chunk.DOwjsMaD.js.br +0 -0
  36. package/assets/ui/chunk.DYIu-C82.js +1 -0
  37. package/assets/ui/chunk.DYIu-C82.js.br +0 -0
  38. package/assets/ui/chunk.D_-fkSwu.js +1 -0
  39. package/assets/ui/chunk.D_-fkSwu.js.br +0 -0
  40. package/assets/ui/chunk.Dc4PCYcb.js +1 -0
  41. package/assets/ui/chunk.Dc4PCYcb.js.br +0 -0
  42. package/assets/ui/chunk.De1vj4hM.js +1 -0
  43. package/assets/ui/chunk.De1vj4hM.js.br +0 -0
  44. package/assets/ui/chunk.DuQak1OK.js +1 -0
  45. package/assets/ui/chunk.DuQak1OK.js.br +0 -0
  46. package/assets/ui/chunk.DxnuHDOY.js +1 -0
  47. package/assets/ui/chunk.DxnuHDOY.js.br +0 -0
  48. package/assets/ui/chunk.TIounDiA.js +1 -0
  49. package/assets/ui/chunk.TIounDiA.js.br +0 -0
  50. package/assets/ui/chunk.p3hCiSrt.js +80 -0
  51. package/assets/ui/chunk.p3hCiSrt.js.br +0 -0
  52. package/assets/ui/chunk.yh4jaMrg.js +1 -0
  53. package/assets/ui/chunk.yh4jaMrg.js.br +0 -0
  54. package/assets/ui/entry.DnXws2rz.js +2 -0
  55. package/assets/ui/entry.DnXws2rz.js.br +0 -0
  56. package/assets/ui/index.html +10 -0
  57. package/assets/ui/index.html.br +1 -0
  58. package/dist/public/200.html +10 -0
  59. package/dist/public/200.html.br +1 -0
  60. package/dist/public/404.html +10 -0
  61. package/dist/public/404.html.br +1 -0
  62. package/dist/public/CNAME +1 -0
  63. package/dist/public/asset.CHpVij2M.css +1 -0
  64. package/dist/public/asset.CHpVij2M.css.br +0 -0
  65. package/dist/public/asset.Cxu56LSy.css +1 -0
  66. package/dist/public/asset.Cxu56LSy.css.br +0 -0
  67. package/dist/public/chunk.9plHAFDW.js +1 -0
  68. package/dist/public/chunk.9plHAFDW.js.br +0 -0
  69. package/dist/public/chunk.B82rsdDI.js +1 -0
  70. package/dist/public/chunk.B82rsdDI.js.br +0 -0
  71. package/dist/public/chunk.B9jGefQy.js +1 -0
  72. package/dist/public/chunk.B9jGefQy.js.br +0 -0
  73. package/dist/public/chunk.BHYZ9sAK.js +1 -0
  74. package/dist/public/chunk.BHYZ9sAK.js.br +0 -0
  75. package/dist/public/chunk.Bc7_n90V.js +1 -0
  76. package/dist/public/chunk.Bc7_n90V.js.br +0 -0
  77. package/dist/public/chunk.CCbhJSL_.js +1 -0
  78. package/dist/public/chunk.CCbhJSL_.js.br +0 -0
  79. package/dist/public/chunk.CJt_09bu.js +1 -0
  80. package/dist/public/chunk.CJt_09bu.js.br +0 -0
  81. package/dist/public/chunk.CK6Z-I-W.js +1 -0
  82. package/dist/public/chunk.CK6Z-I-W.js.br +1 -0
  83. package/dist/public/chunk.Cj1opA98.js +1 -0
  84. package/dist/public/chunk.Cj1opA98.js.br +0 -0
  85. package/dist/public/chunk.CvCu4yZb.js +2 -0
  86. package/dist/public/chunk.CvCu4yZb.js.br +0 -0
  87. package/dist/public/chunk.D93ZmnLR.js +1 -0
  88. package/dist/public/chunk.D93ZmnLR.js.br +6 -0
  89. package/dist/public/chunk.D9MCnLj_.js +7 -0
  90. package/dist/public/chunk.D9MCnLj_.js.br +0 -0
  91. package/dist/public/chunk.DOwjsMaD.js +1 -0
  92. package/dist/public/chunk.DOwjsMaD.js.br +0 -0
  93. package/dist/public/chunk.DYIu-C82.js +1 -0
  94. package/dist/public/chunk.DYIu-C82.js.br +0 -0
  95. package/dist/public/chunk.D_-fkSwu.js +1 -0
  96. package/dist/public/chunk.D_-fkSwu.js.br +0 -0
  97. package/dist/public/chunk.Dc4PCYcb.js +1 -0
  98. package/dist/public/chunk.Dc4PCYcb.js.br +0 -0
  99. package/dist/public/chunk.De1vj4hM.js +1 -0
  100. package/dist/public/chunk.De1vj4hM.js.br +0 -0
  101. package/dist/public/chunk.DuQak1OK.js +1 -0
  102. package/dist/public/chunk.DuQak1OK.js.br +0 -0
  103. package/dist/public/chunk.DxnuHDOY.js +1 -0
  104. package/dist/public/chunk.DxnuHDOY.js.br +0 -0
  105. package/dist/public/chunk.TIounDiA.js +1 -0
  106. package/dist/public/chunk.TIounDiA.js.br +0 -0
  107. package/dist/public/chunk.p3hCiSrt.js +80 -0
  108. package/dist/public/chunk.p3hCiSrt.js.br +0 -0
  109. package/dist/public/chunk.yh4jaMrg.js +1 -0
  110. package/dist/public/chunk.yh4jaMrg.js.br +0 -0
  111. package/dist/public/entry.DnXws2rz.js +2 -0
  112. package/dist/public/entry.DnXws2rz.js.br +0 -0
  113. package/dist/public/index.html +10 -0
  114. package/dist/public/index.html.br +1 -0
  115. package/package.json +18 -17
  116. package/src/providers/DevToolsMetadataProvider.ts +1 -1
  117. package/src/providers/DevToolsProvider.ts +115 -1
  118. package/src/ui/AppRouter.tsx +18 -0
  119. package/src/ui/components/DevLayout.tsx +14 -15
  120. package/src/ui/components/configuration/ConfigEnv.tsx +1 -1
  121. package/src/ui/components/dashboard/DevDashboard.tsx +32 -13
  122. package/src/ui/components/database/DatabaseEditor.tsx +5 -2
  123. package/src/ui/components/emails/DevEmails.tsx +250 -0
  124. package/src/ui/components/explorer/DevExplorer.tsx +1 -1
  125. package/src/ui/components/sms/DevSms.tsx +225 -0
  126. package/dist/index.browser.js +0 -224
  127. package/dist/index.browser.js.map +0 -1
  128. package/dist/index.d.ts +0 -499
  129. package/dist/index.js +0 -782
  130. package/dist/index.js.map +0 -1
@@ -0,0 +1,250 @@
1
+ import { Flex, ui } from "@alepha/ui";
2
+ import { Badge, CloseButton, ScrollArea, Text, TextInput } from "@mantine/core";
3
+ import { IconSearch } from "@tabler/icons-react";
4
+ import { useInject } from "alepha/react";
5
+ import { HttpClient } from "alepha/server";
6
+ import { useCallback, useEffect, useState } from "react";
7
+
8
+ interface EmailEntry {
9
+ to: string;
10
+ subject: string;
11
+ body: string;
12
+ sentAt: string;
13
+ }
14
+
15
+ const formatDate = (iso: string): string => {
16
+ const d = new Date(iso);
17
+ return d.toLocaleString();
18
+ };
19
+
20
+ const formatRelative = (iso: string): string => {
21
+ const diff = Date.now() - new Date(iso).getTime();
22
+ if (diff < 1000) return "just now";
23
+ if (diff < 60_000) return `${Math.floor(diff / 1000)}s ago`;
24
+ if (diff < 3_600_000) return `${Math.floor(diff / 60_000)}m ago`;
25
+ return `${Math.floor(diff / 3_600_000)}h ago`;
26
+ };
27
+
28
+ export const DevEmails = () => {
29
+ const http = useInject(HttpClient);
30
+ const [emails, setEmails] = useState<EmailEntry[]>([]);
31
+ const [selectedIndex, setSelectedIndex] = useState<number | null>(null);
32
+ const [search, setSearch] = useState("");
33
+
34
+ const fetchEmails = useCallback(async () => {
35
+ if (document.visibilityState !== "visible") return;
36
+ try {
37
+ const res = await http.fetch("/__devtools/api/emails");
38
+ const data = res.data as any;
39
+ setEmails(data?.emails ?? []);
40
+ } catch {
41
+ // silently fail
42
+ }
43
+ }, [http]);
44
+
45
+ useEffect(() => {
46
+ fetchEmails();
47
+ const interval = setInterval(fetchEmails, 10_000);
48
+ return () => clearInterval(interval);
49
+ }, [fetchEmails]);
50
+
51
+ const filtered = emails.filter((email) => {
52
+ if (!search) return true;
53
+ const q = search.toLowerCase();
54
+ return (
55
+ email.to.toLowerCase().includes(q) ||
56
+ email.subject.toLowerCase().includes(q)
57
+ );
58
+ });
59
+
60
+ const selectedEmail = selectedIndex !== null ? filtered[selectedIndex] : null;
61
+
62
+ return (
63
+ <Flex style={{ flex: 1, overflow: "hidden" }} direction="column">
64
+ {/* Filter bar */}
65
+ <Flex
66
+ px="md"
67
+ py="xs"
68
+ gap="sm"
69
+ align="center"
70
+ style={{
71
+ borderBottom: `1px solid ${ui.colors.border}`,
72
+ flexShrink: 0,
73
+ }}
74
+ >
75
+ <TextInput
76
+ size="xs"
77
+ placeholder="Search..."
78
+ leftSection={<IconSearch size={14} />}
79
+ value={search}
80
+ onChange={(e) => setSearch(e.currentTarget.value)}
81
+ style={{ flex: 1, minWidth: 150, maxWidth: 300 }}
82
+ />
83
+ <Badge variant="light" color="gray" size="sm">
84
+ {filtered.length} emails
85
+ </Badge>
86
+ </Flex>
87
+
88
+ {/* Main area: list + detail */}
89
+ <Flex style={{ flex: 1, overflow: "hidden" }}>
90
+ {/* Email list */}
91
+ <Flex direction="column" style={{ flex: 1, overflow: "hidden" }}>
92
+ <ScrollArea style={{ flex: 1 }}>
93
+ {filtered.length === 0 && (
94
+ <Flex align="center" justify="center" py="xl" c="dimmed">
95
+ <Text fz="sm">No emails to display</Text>
96
+ </Flex>
97
+ )}
98
+ {filtered.map((email, i) => {
99
+ const isSelected = selectedIndex === i;
100
+
101
+ return (
102
+ <Flex
103
+ key={`${email.sentAt}-${i}`}
104
+ direction="column"
105
+ px="md"
106
+ py="xs"
107
+ onClick={() => setSelectedIndex(isSelected ? null : i)}
108
+ style={{
109
+ borderBottom: `1px solid ${ui.colors.border}20`,
110
+ background: isSelected ? ui.colors.elevated : "transparent",
111
+ cursor: "pointer",
112
+ transition: "background 100ms",
113
+ }}
114
+ onMouseEnter={(e) => {
115
+ if (!isSelected) {
116
+ (e.currentTarget as HTMLElement).style.background =
117
+ `${ui.colors.elevated}80`;
118
+ }
119
+ }}
120
+ onMouseLeave={(e) => {
121
+ if (!isSelected) {
122
+ (e.currentTarget as HTMLElement).style.background =
123
+ "transparent";
124
+ }
125
+ }}
126
+ >
127
+ <Flex justify="space-between" align="center">
128
+ <Text fz="sm" truncate>
129
+ {email.to}
130
+ </Text>
131
+ <Text fz={11} c="dimmed" style={{ flexShrink: 0 }}>
132
+ {formatRelative(email.sentAt)}
133
+ </Text>
134
+ </Flex>
135
+ <Text fz="xs" c="dimmed" truncate>
136
+ {email.subject}
137
+ </Text>
138
+ </Flex>
139
+ );
140
+ })}
141
+ </ScrollArea>
142
+ </Flex>
143
+
144
+ {/* Detail panel */}
145
+ {selectedEmail && (
146
+ <Flex
147
+ w={500}
148
+ direction="column"
149
+ style={{
150
+ borderLeft: `1px solid ${ui.colors.border}`,
151
+ flexShrink: 0,
152
+ overflow: "hidden",
153
+ }}
154
+ >
155
+ <Flex
156
+ px="md"
157
+ py="xs"
158
+ align="center"
159
+ justify="space-between"
160
+ style={{
161
+ borderBottom: `1px solid ${ui.colors.border}`,
162
+ flexShrink: 0,
163
+ }}
164
+ >
165
+ <Text fz="xs" fw={600} tt="uppercase" c="dimmed" lts={0.5}>
166
+ Email Detail
167
+ </Text>
168
+ <CloseButton size="xs" onClick={() => setSelectedIndex(null)} />
169
+ </Flex>
170
+ <ScrollArea style={{ flex: 1 }} p="md">
171
+ <Flex direction="column" gap="md">
172
+ {/* To */}
173
+ <Flex direction="column">
174
+ <Text
175
+ fz={10}
176
+ c="dimmed"
177
+ tt="uppercase"
178
+ fw={600}
179
+ lts={0.5}
180
+ mb={4}
181
+ >
182
+ To
183
+ </Text>
184
+ <Text fz="xs">{selectedEmail.to}</Text>
185
+ </Flex>
186
+
187
+ {/* Date */}
188
+ <Flex direction="column">
189
+ <Text
190
+ fz={10}
191
+ c="dimmed"
192
+ tt="uppercase"
193
+ fw={600}
194
+ lts={0.5}
195
+ mb={4}
196
+ >
197
+ Date
198
+ </Text>
199
+ <Text fz="xs">{formatDate(selectedEmail.sentAt)}</Text>
200
+ </Flex>
201
+
202
+ {/* Subject */}
203
+ <Flex direction="column">
204
+ <Text
205
+ fz={10}
206
+ c="dimmed"
207
+ tt="uppercase"
208
+ fw={600}
209
+ lts={0.5}
210
+ mb={4}
211
+ >
212
+ Subject
213
+ </Text>
214
+ <Text fz="xs">{selectedEmail.subject}</Text>
215
+ </Flex>
216
+
217
+ {/* Body */}
218
+ <Flex direction="column">
219
+ <Text
220
+ fz={10}
221
+ c="dimmed"
222
+ tt="uppercase"
223
+ fw={600}
224
+ lts={0.5}
225
+ mb={4}
226
+ >
227
+ Body
228
+ </Text>
229
+ <div
230
+ style={{
231
+ background: "white",
232
+ color: "#333",
233
+ border: "1px solid #ccc",
234
+ borderRadius: 4,
235
+ padding: 12,
236
+ }}
237
+ // biome-ignore lint/security/noDangerouslySetInnerHtml: devtools renders developer's own email HTML
238
+ dangerouslySetInnerHTML={{ __html: selectedEmail.body }}
239
+ />
240
+ </Flex>
241
+ </Flex>
242
+ </ScrollArea>
243
+ </Flex>
244
+ )}
245
+ </Flex>
246
+ </Flex>
247
+ );
248
+ };
249
+
250
+ export default DevEmails;
@@ -87,7 +87,7 @@ const buildTree = (metadata: any): TreeNode[] => {
87
87
  for (const page of metadata.pages) {
88
88
  pageNodeMap.set(page.name, {
89
89
  id: `page:${page.name}`,
90
- label: page.label || page.name,
90
+ label: page.name,
91
91
  type: "page" as const,
92
92
  data: page,
93
93
  children: [],
@@ -0,0 +1,225 @@
1
+ import { Flex, ui } from "@alepha/ui";
2
+ import { Badge, CloseButton, ScrollArea, Text, TextInput } from "@mantine/core";
3
+ import { IconSearch } from "@tabler/icons-react";
4
+ import { useInject } from "alepha/react";
5
+ import { HttpClient } from "alepha/server";
6
+ import { useCallback, useEffect, useState } from "react";
7
+
8
+ interface SmsEntry {
9
+ to: string;
10
+ message: string;
11
+ sentAt: string;
12
+ }
13
+
14
+ const formatDate = (iso: string): string => {
15
+ const d = new Date(iso);
16
+ return d.toLocaleString();
17
+ };
18
+
19
+ const formatRelative = (iso: string): string => {
20
+ const diff = Date.now() - new Date(iso).getTime();
21
+ if (diff < 1000) return "just now";
22
+ if (diff < 60_000) return `${Math.floor(diff / 1000)}s ago`;
23
+ if (diff < 3_600_000) return `${Math.floor(diff / 60_000)}m ago`;
24
+ return `${Math.floor(diff / 3_600_000)}h ago`;
25
+ };
26
+
27
+ export const DevSms = () => {
28
+ const http = useInject(HttpClient);
29
+ const [messages, setMessages] = useState<SmsEntry[]>([]);
30
+ const [selectedIndex, setSelectedIndex] = useState<number | null>(null);
31
+ const [search, setSearch] = useState("");
32
+
33
+ const fetchMessages = useCallback(async () => {
34
+ if (document.visibilityState !== "visible") return;
35
+ try {
36
+ const res = await http.fetch("/__devtools/api/sms");
37
+ const data = res.data as any;
38
+ setMessages(data?.messages ?? []);
39
+ } catch {
40
+ // silently fail
41
+ }
42
+ }, [http]);
43
+
44
+ useEffect(() => {
45
+ fetchMessages();
46
+ const interval = setInterval(fetchMessages, 10_000);
47
+ return () => clearInterval(interval);
48
+ }, [fetchMessages]);
49
+
50
+ const filtered = messages.filter((sms) => {
51
+ if (!search) return true;
52
+ const q = search.toLowerCase();
53
+ return (
54
+ sms.to.toLowerCase().includes(q) || sms.message.toLowerCase().includes(q)
55
+ );
56
+ });
57
+
58
+ const selectedSms = selectedIndex !== null ? filtered[selectedIndex] : null;
59
+
60
+ return (
61
+ <Flex style={{ flex: 1, overflow: "hidden" }} direction="column">
62
+ {/* Filter bar */}
63
+ <Flex
64
+ px="md"
65
+ py="xs"
66
+ gap="sm"
67
+ align="center"
68
+ style={{
69
+ borderBottom: `1px solid ${ui.colors.border}`,
70
+ flexShrink: 0,
71
+ }}
72
+ >
73
+ <TextInput
74
+ size="xs"
75
+ placeholder="Search..."
76
+ leftSection={<IconSearch size={14} />}
77
+ value={search}
78
+ onChange={(e) => setSearch(e.currentTarget.value)}
79
+ style={{ flex: 1, minWidth: 150, maxWidth: 300 }}
80
+ />
81
+ <Badge variant="light" color="gray" size="sm">
82
+ {filtered.length} messages
83
+ </Badge>
84
+ </Flex>
85
+
86
+ {/* Main area: list + detail */}
87
+ <Flex style={{ flex: 1, overflow: "hidden" }}>
88
+ {/* SMS list */}
89
+ <Flex direction="column" style={{ flex: 1, overflow: "hidden" }}>
90
+ <ScrollArea style={{ flex: 1 }}>
91
+ {filtered.length === 0 && (
92
+ <Flex align="center" justify="center" py="xl" c="dimmed">
93
+ <Text fz="sm">No messages to display</Text>
94
+ </Flex>
95
+ )}
96
+ {filtered.map((sms, i) => {
97
+ const isSelected = selectedIndex === i;
98
+
99
+ return (
100
+ <Flex
101
+ key={`${sms.sentAt}-${i}`}
102
+ direction="column"
103
+ px="md"
104
+ py="xs"
105
+ onClick={() => setSelectedIndex(isSelected ? null : i)}
106
+ style={{
107
+ borderBottom: `1px solid ${ui.colors.border}20`,
108
+ background: isSelected ? ui.colors.elevated : "transparent",
109
+ cursor: "pointer",
110
+ transition: "background 100ms",
111
+ }}
112
+ onMouseEnter={(e) => {
113
+ if (!isSelected) {
114
+ (e.currentTarget as HTMLElement).style.background =
115
+ `${ui.colors.elevated}80`;
116
+ }
117
+ }}
118
+ onMouseLeave={(e) => {
119
+ if (!isSelected) {
120
+ (e.currentTarget as HTMLElement).style.background =
121
+ "transparent";
122
+ }
123
+ }}
124
+ >
125
+ <Flex justify="space-between" align="center">
126
+ <Text fz="sm" truncate>
127
+ {sms.to}
128
+ </Text>
129
+ <Text fz={11} c="dimmed" style={{ flexShrink: 0 }}>
130
+ {formatRelative(sms.sentAt)}
131
+ </Text>
132
+ </Flex>
133
+ <Text fz="xs" c="dimmed" truncate>
134
+ {sms.message}
135
+ </Text>
136
+ </Flex>
137
+ );
138
+ })}
139
+ </ScrollArea>
140
+ </Flex>
141
+
142
+ {/* Detail panel */}
143
+ {selectedSms && (
144
+ <Flex
145
+ w={400}
146
+ direction="column"
147
+ style={{
148
+ borderLeft: `1px solid ${ui.colors.border}`,
149
+ flexShrink: 0,
150
+ overflow: "hidden",
151
+ }}
152
+ >
153
+ <Flex
154
+ px="md"
155
+ py="xs"
156
+ align="center"
157
+ justify="space-between"
158
+ style={{
159
+ borderBottom: `1px solid ${ui.colors.border}`,
160
+ flexShrink: 0,
161
+ }}
162
+ >
163
+ <Text fz="xs" fw={600} tt="uppercase" c="dimmed" lts={0.5}>
164
+ Message Detail
165
+ </Text>
166
+ <CloseButton size="xs" onClick={() => setSelectedIndex(null)} />
167
+ </Flex>
168
+ <ScrollArea style={{ flex: 1 }} p="md">
169
+ <Flex direction="column" gap="md">
170
+ {/* To */}
171
+ <Flex direction="column">
172
+ <Text
173
+ fz={10}
174
+ c="dimmed"
175
+ tt="uppercase"
176
+ fw={600}
177
+ lts={0.5}
178
+ mb={4}
179
+ >
180
+ To
181
+ </Text>
182
+ <Text fz="xs">{selectedSms.to}</Text>
183
+ </Flex>
184
+
185
+ {/* Date */}
186
+ <Flex direction="column">
187
+ <Text
188
+ fz={10}
189
+ c="dimmed"
190
+ tt="uppercase"
191
+ fw={600}
192
+ lts={0.5}
193
+ mb={4}
194
+ >
195
+ Date
196
+ </Text>
197
+ <Text fz="xs">{formatDate(selectedSms.sentAt)}</Text>
198
+ </Flex>
199
+
200
+ {/* Message */}
201
+ <Flex direction="column">
202
+ <Text
203
+ fz={10}
204
+ c="dimmed"
205
+ tt="uppercase"
206
+ fw={600}
207
+ lts={0.5}
208
+ mb={4}
209
+ >
210
+ Message
211
+ </Text>
212
+ <Text fz="xs" style={{ whiteSpace: "pre-wrap" }}>
213
+ {selectedSms.message}
214
+ </Text>
215
+ </Flex>
216
+ </Flex>
217
+ </ScrollArea>
218
+ </Flex>
219
+ )}
220
+ </Flex>
221
+ </Flex>
222
+ );
223
+ };
224
+
225
+ export default DevSms;
@@ -1,224 +0,0 @@
1
- import { $module, t } from "alepha";
2
- //#region src/schemas/DevActionMetadata.ts
3
- const devActionMetadataSchema = t.object({
4
- name: t.text(),
5
- group: t.text(),
6
- method: t.text(),
7
- path: t.text(),
8
- prefix: t.text(),
9
- fullPath: t.text(),
10
- description: t.optional(t.text()),
11
- summary: t.optional(t.text()),
12
- disabled: t.optional(t.boolean()),
13
- secure: t.optional(t.boolean()),
14
- hide: t.optional(t.boolean()),
15
- body: t.optional(t.any()),
16
- params: t.optional(t.any()),
17
- query: t.optional(t.any()),
18
- response: t.optional(t.any()),
19
- bodyContentType: t.optional(t.text()),
20
- middlewares: t.optional(t.array(t.object({
21
- name: t.text(),
22
- options: t.optional(t.any())
23
- })))
24
- });
25
- //#endregion
26
- //#region src/schemas/DevAtomMetadata.ts
27
- const devAtomMetadataSchema = t.object({
28
- name: t.text(),
29
- description: t.optional(t.text()),
30
- schema: t.any(),
31
- defaultValue: t.optional(t.any()),
32
- currentValue: t.optional(t.any())
33
- });
34
- //#endregion
35
- //#region src/schemas/DevBucketMetadata.ts
36
- const devBucketMetadataSchema = t.object({
37
- name: t.text(),
38
- description: t.optional(t.text()),
39
- mimeTypes: t.optional(t.array(t.text())),
40
- maxSize: t.optional(t.number()),
41
- provider: t.text()
42
- });
43
- //#endregion
44
- //#region src/schemas/DevCacheMetadata.ts
45
- const devCacheMetadataSchema = t.object({
46
- name: t.text(),
47
- ttl: t.optional(t.any()),
48
- disabled: t.optional(t.boolean()),
49
- provider: t.text()
50
- });
51
- //#endregion
52
- //#region src/schemas/DevEntityMetadata.ts
53
- const devEntityColumnSchema = t.object({
54
- name: t.text(),
55
- type: t.text(),
56
- nullable: t.boolean(),
57
- primaryKey: t.boolean(),
58
- identity: t.boolean(),
59
- createdAt: t.boolean(),
60
- updatedAt: t.boolean(),
61
- deletedAt: t.boolean(),
62
- version: t.boolean(),
63
- hasDefault: t.boolean(),
64
- ref: t.optional(t.object({
65
- entity: t.text(),
66
- column: t.text(),
67
- onUpdate: t.optional(t.text()),
68
- onDelete: t.optional(t.text())
69
- }))
70
- });
71
- const devEntityIndexSchema = t.object({
72
- name: t.optional(t.text()),
73
- columns: t.array(t.text()),
74
- unique: t.boolean()
75
- });
76
- const devEntityForeignKeySchema = t.object({
77
- name: t.optional(t.text()),
78
- columns: t.array(t.text()),
79
- foreignEntity: t.text(),
80
- foreignColumns: t.array(t.text())
81
- });
82
- const devEntityConstraintSchema = t.object({
83
- name: t.optional(t.text()),
84
- columns: t.array(t.text()),
85
- unique: t.boolean(),
86
- hasCheck: t.boolean()
87
- });
88
- const devEntityMetadataSchema = t.object({
89
- name: t.text(),
90
- provider: t.text(),
91
- columns: t.array(devEntityColumnSchema),
92
- indexes: t.array(devEntityIndexSchema),
93
- foreignKeys: t.array(devEntityForeignKeySchema),
94
- constraints: t.array(devEntityConstraintSchema),
95
- schema: t.optional(t.any()),
96
- insertSchema: t.optional(t.any()),
97
- updateSchema: t.optional(t.any())
98
- });
99
- //#endregion
100
- //#region src/schemas/DevEnvMetadata.ts
101
- const devEnvMetadataSchema = t.object({
102
- propertyKey: t.text(),
103
- schema: t.any(),
104
- values: t.record(t.text(), t.any()),
105
- serviceName: t.optional(t.text())
106
- });
107
- //#endregion
108
- //#region src/schemas/DevModuleMetadata.ts
109
- const devModuleMetadataSchema = t.object({
110
- name: t.text(),
111
- providers: t.array(t.text())
112
- });
113
- //#endregion
114
- //#region src/schemas/DevPageMetadata.ts
115
- const devPageMetadataSchema = t.object({
116
- name: t.text(),
117
- label: t.optional(t.text()),
118
- description: t.optional(t.text()),
119
- path: t.optional(t.text()),
120
- parentName: t.optional(t.text()),
121
- params: t.optional(t.any()),
122
- query: t.optional(t.any()),
123
- hasComponent: t.boolean(),
124
- hasLazy: t.boolean(),
125
- hasResolve: t.boolean(),
126
- childrenNames: t.optional(t.array(t.text())),
127
- hasChildren: t.boolean(),
128
- hasParent: t.boolean(),
129
- hasErrorHandler: t.boolean(),
130
- static: t.optional(t.boolean()),
131
- cache: t.optional(t.any()),
132
- client: t.optional(t.any()),
133
- animation: t.optional(t.any())
134
- });
135
- //#endregion
136
- //#region src/schemas/DevProviderMetadata.ts
137
- const devProviderMetadataSchema = t.object({
138
- name: t.text(),
139
- module: t.optional(t.text()),
140
- dependencies: t.array(t.text()),
141
- aliases: t.optional(t.array(t.text()))
142
- });
143
- //#endregion
144
- //#region src/schemas/DevQueueMetadata.ts
145
- const devQueueMetadataSchema = t.object({
146
- name: t.text(),
147
- description: t.optional(t.text()),
148
- schema: t.optional(t.any()),
149
- provider: t.text()
150
- });
151
- //#endregion
152
- //#region src/schemas/DevRealmMetadata.ts
153
- const devRealmMetadataSchema = t.object({
154
- name: t.text(),
155
- description: t.optional(t.text()),
156
- roles: t.optional(t.array(t.any())),
157
- type: t.enum(["internal", "external"]),
158
- settings: t.optional(t.object({
159
- accessTokenExpiration: t.optional(t.any()),
160
- refreshTokenExpiration: t.optional(t.any()),
161
- hasOnCreateSession: t.boolean(),
162
- hasOnRefreshSession: t.boolean(),
163
- hasOnDeleteSession: t.boolean()
164
- }))
165
- });
166
- //#endregion
167
- //#region src/schemas/DevRouteMetadata.ts
168
- const devRouteMetadataSchema = t.object({
169
- method: t.text(),
170
- path: t.text()
171
- });
172
- //#endregion
173
- //#region src/schemas/DevSchedulerMetadata.ts
174
- const devSchedulerMetadataSchema = t.object({
175
- name: t.text(),
176
- description: t.optional(t.text()),
177
- cron: t.optional(t.text()),
178
- interval: t.optional(t.any()),
179
- lock: t.optional(t.boolean())
180
- });
181
- //#endregion
182
- //#region src/schemas/DevTopicMetadata.ts
183
- const devTopicMetadataSchema = t.object({
184
- name: t.text(),
185
- description: t.optional(t.text()),
186
- schema: t.optional(t.any()),
187
- provider: t.text(),
188
- subscribers: t.integer()
189
- });
190
- //#endregion
191
- //#region src/schemas/DevMetadata.ts
192
- const devSystemSchema = t.object({
193
- alephaVersion: t.text(),
194
- nodeVersion: t.text(),
195
- runtime: t.enum(["node", "bun"]),
196
- mode: t.enum(["development", "production"]),
197
- port: t.integer(),
198
- uptime: t.number(),
199
- memoryUsage: t.number()
200
- });
201
- const devMetadataSchema = t.object({
202
- system: devSystemSchema,
203
- actions: t.array(devActionMetadataSchema),
204
- queues: t.array(devQueueMetadataSchema),
205
- schedulers: t.array(devSchedulerMetadataSchema),
206
- topics: t.array(devTopicMetadataSchema),
207
- buckets: t.array(devBucketMetadataSchema),
208
- realms: t.array(devRealmMetadataSchema),
209
- caches: t.array(devCacheMetadataSchema),
210
- pages: t.array(devPageMetadataSchema),
211
- providers: t.array(devProviderMetadataSchema),
212
- modules: t.array(devModuleMetadataSchema),
213
- entities: t.array(devEntityMetadataSchema),
214
- routes: t.array(devRouteMetadataSchema),
215
- envs: t.array(devEnvMetadataSchema),
216
- atoms: t.array(devAtomMetadataSchema)
217
- });
218
- //#endregion
219
- //#region src/index.browser.ts
220
- const AlephaDevtools = $module({ name: "alepha.devtools" });
221
- //#endregion
222
- export { AlephaDevtools, devActionMetadataSchema, devAtomMetadataSchema, devBucketMetadataSchema, devCacheMetadataSchema, devEntityColumnSchema, devEntityConstraintSchema, devEntityForeignKeySchema, devEntityIndexSchema, devEntityMetadataSchema, devEnvMetadataSchema, devMetadataSchema, devModuleMetadataSchema, devPageMetadataSchema, devProviderMetadataSchema, devQueueMetadataSchema, devRealmMetadataSchema, devRouteMetadataSchema, devSchedulerMetadataSchema, devSystemSchema, devTopicMetadataSchema };
223
-
224
- //# sourceMappingURL=index.browser.js.map