@niyamulahsan/create-deskapp 0.0.0-stage → 1.2.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 (132) hide show
  1. package/README.md +49 -2
  2. package/bin/create.js +136 -0
  3. package/package.json +14 -4
  4. package/template/.env +13 -0
  5. package/template/.env.example +13 -0
  6. package/template/.vscode/extensions.json +6 -0
  7. package/template/.vscode/settings.json +37 -0
  8. package/template/LICENSE +21 -0
  9. package/template/README.md +29 -0
  10. package/template/biome.json +99 -0
  11. package/template/drizzle.config.ts +32 -0
  12. package/template/gitignore-stub +19 -0
  13. package/template/package.json +111 -0
  14. package/template/scripts/build-electron.mjs +55 -0
  15. package/template/scripts/dev-electron.mjs +53 -0
  16. package/template/scripts/installer.nsh +14 -0
  17. package/template/src/config/app.ts +24 -0
  18. package/template/src/core/api/bindings.generated.ts +23 -0
  19. package/template/src/core/api/generate.manifest.ts +86 -0
  20. package/template/src/core/api/registry.ts +48 -0
  21. package/template/src/core/config.ts +99 -0
  22. package/template/src/core/database/aggregate.ts +85 -0
  23. package/template/src/core/database/config.ts +48 -0
  24. package/template/src/core/database/connection.ts +114 -0
  25. package/template/src/core/database/migrate-hooks.ts +84 -0
  26. package/template/src/core/database/paginate.ts +224 -0
  27. package/template/src/core/database/reset.ts +19 -0
  28. package/template/src/core/database/seed.ts +169 -0
  29. package/template/src/core/database/status.ts +32 -0
  30. package/template/src/core/env.ts +106 -0
  31. package/template/src/core/facade.ts +59 -0
  32. package/template/src/core/maker/db/fresh.ts +8 -0
  33. package/template/src/core/maker/db/generate.ts +11 -0
  34. package/template/src/core/maker/db/helpers.ts +96 -0
  35. package/template/src/core/maker/db/migrate.ts +36 -0
  36. package/template/src/core/maker/db/mod.ts +63 -0
  37. package/template/src/core/maker/db/module-migrate.ts +53 -0
  38. package/template/src/core/maker/db/push.ts +21 -0
  39. package/template/src/core/maker/db/reset.ts +6 -0
  40. package/template/src/core/maker/db/seed.ts +7 -0
  41. package/template/src/core/maker/db/status.ts +6 -0
  42. package/template/src/core/maker/help.ts +66 -0
  43. package/template/src/core/maker/make/controller.ts +27 -0
  44. package/template/src/core/maker/make/helpers.ts +93 -0
  45. package/template/src/core/maker/make/mod.ts +68 -0
  46. package/template/src/core/maker/make/model.ts +14 -0
  47. package/template/src/core/maker/make/module.ts +62 -0
  48. package/template/src/core/maker/make/seeder.ts +21 -0
  49. package/template/src/core/maker/make/test.ts +30 -0
  50. package/template/src/core/maker/mod.ts +83 -0
  51. package/template/src/core/maker/run/mod.ts +112 -0
  52. package/template/src/core/maker/stub.ts +24 -0
  53. package/template/src/core/maker/stubs/controller/controller.controller.stub +55 -0
  54. package/template/src/core/maker/stubs/controller/controller.schema.stub +13 -0
  55. package/template/src/core/maker/stubs/model/model.stub +8 -0
  56. package/template/src/core/maker/stubs/seeder/seeder.stub +16 -0
  57. package/template/src/core/maker/stubs/test/test.stub +7 -0
  58. package/template/src/core/maker/sync-config.ts +94 -0
  59. package/template/src/core/utils/password.ts +27 -0
  60. package/template/src/core/utils/playwright.ts +121 -0
  61. package/template/src/core/utils/queue.ts +59 -0
  62. package/template/src/core/utils/scheduler.ts +70 -0
  63. package/template/src/core/utils/storage.ts +599 -0
  64. package/template/src/core/utils/validation.ts +35 -0
  65. package/template/src/database/migrations/sqlite/meta/_journal.json +1 -0
  66. package/template/src/database/schema.ts +6 -0
  67. package/template/src/icons/apple-touch-icon.png +0 -0
  68. package/template/src/icons/deskapp.png +0 -0
  69. package/template/src/icons/favicon-96x96.png +0 -0
  70. package/template/src/icons/favicon.ico +0 -0
  71. package/template/src/icons/favicon.svg +1 -0
  72. package/template/src/icons/site.webmanifest +21 -0
  73. package/template/src/icons/tray.png +0 -0
  74. package/template/src/icons/web-app-manifest-192x192.png +0 -0
  75. package/template/src/icons/web-app-manifest-512x512.png +0 -0
  76. package/template/src/main.ts +116 -0
  77. package/template/src/modules/app/controllers/demo.controller.ts +118 -0
  78. package/template/src/modules/app/controllers/net.controller.ts +48 -0
  79. package/template/src/modules/app/controllers/playwright.controller.ts +140 -0
  80. package/template/src/modules/app/controllers/storage.controller.ts +229 -0
  81. package/template/src/modules/app/controllers/window.controller.ts +107 -0
  82. package/template/src/preload.ts +35 -0
  83. package/template/src/storage/.gitkeep +1 -0
  84. package/template/src/storage/app/private/.gitkeep +1 -0
  85. package/template/src/storage/app/private/samples/.gitkeep +1 -0
  86. package/template/src/storage/app/private/samples/state.json +5 -0
  87. package/template/src/storage/app/private/uploads/.gitkeep +1 -0
  88. package/template/src/storage/app/public/.gitkeep +1 -0
  89. package/template/src/storage/app/tmp/generated/.gitkeep +1 -0
  90. package/template/src/storage/logs/.gitkeep +0 -0
  91. package/template/src/storage/logs/app.log +0 -0
  92. package/template/src/storage/logs/fatal.log +0 -0
  93. package/template/src/ui/.vscode/extensions.json +3 -0
  94. package/template/src/ui/index.html +14 -0
  95. package/template/src/ui/public/icons.svg +24 -0
  96. package/template/src/ui/src/App.vue +3 -0
  97. package/template/src/ui/src/app.ts +23 -0
  98. package/template/src/ui/src/assets/fonts/public-sans/public-sans-latin-ext.woff2 +0 -0
  99. package/template/src/ui/src/assets/fonts/public-sans/public-sans-latin.woff2 +0 -0
  100. package/template/src/ui/src/assets/images/deskapp.png +0 -0
  101. package/template/src/ui/src/assets/images/favicon/favicon.ico +0 -0
  102. package/template/src/ui/src/assets/scss/custom.scss +186 -0
  103. package/template/src/ui/src/bindings.d.ts +16 -0
  104. package/template/src/ui/src/components/Button.vue +32 -0
  105. package/template/src/ui/src/components/Checkbox.vue +29 -0
  106. package/template/src/ui/src/components/Input.vue +227 -0
  107. package/template/src/ui/src/components/Modal.vue +55 -0
  108. package/template/src/ui/src/components/Spinner.vue +42 -0
  109. package/template/src/ui/src/components/Switch.vue +65 -0
  110. package/template/src/ui/src/components/TextArea.vue +121 -0
  111. package/template/src/ui/src/components/Toast.vue +56 -0
  112. package/template/src/ui/src/components/datatable/DataTableSkeleton.vue +98 -0
  113. package/template/src/ui/src/components/datatable/Pagination.vue +125 -0
  114. package/template/src/ui/src/components/datatable/SelectOpption.vue +35 -0
  115. package/template/src/ui/src/components/datatable/index.vue +258 -0
  116. package/template/src/ui/src/env.d.ts +13 -0
  117. package/template/src/ui/src/global.d.ts +35 -0
  118. package/template/src/ui/src/helpers/nformatter.ts +10 -0
  119. package/template/src/ui/src/pages/dashboard/index.vue +687 -0
  120. package/template/src/ui/src/plugins/gum.ts +549 -0
  121. package/template/src/ui/src/plugins/gum.ts.bak +683 -0
  122. package/template/src/ui/src/plugins/pulse.ts +148 -0
  123. package/template/src/ui/src/router/index.ts +25 -0
  124. package/template/src/ui/src/stores/example.ts +27 -0
  125. package/template/src/ui/tsconfig.json +15 -0
  126. package/template/src/ui/vite.config.ts +38 -0
  127. package/template/src/window/config.ts +71 -0
  128. package/template/src/window/dialogs.ts +67 -0
  129. package/template/src/window/manager.ts +139 -0
  130. package/template/src/window/native.ts +215 -0
  131. package/template/tsconfig.json +22 -0
  132. package/template/vitest.config.ts +34 -0
@@ -0,0 +1,229 @@
1
+ /**
2
+ * storage.controller.ts (app module) - real file operations, all native.
3
+ *
4
+ * Every handler uses the cross-platform native dialogs in
5
+ * src/window/dialogs.ts (Windows WinForms, macOS AppKit, Linux zenity/kdialog)
6
+ * to get a real disk path from the user, then operates on it with the storage
7
+ * facade. One API, native on every OS:
8
+ *
9
+ * open -> pickers.open + files.readBinaryFile + files.fileMeta (text preview)
10
+ * save -> pickers.save + files.writeTextFile (atomic)
11
+ * upload -> pickers.open + files.uploadFile into app private uploads
12
+ * download -> pickers.save + files.downloadFile (streamed + atomic)
13
+ * remove -> pickers.open + files.removePath (missing-safe)
14
+ * list -> pickers.folder + files.listFiles
15
+ *
16
+ * App-managed layer (private + tmp):
17
+ * appSave/appLoad -> storage.put/get on samples/state.json
18
+ * appList -> storage.files/directories
19
+ * appExport -> generateForDownload + consumeGenerated (tmp, read-once)
20
+ * appDelete -> storage.delete
21
+ */
22
+
23
+ import { files, pickers, storage } from "@/core/facade";
24
+
25
+ const TEXT_EXTS = new Set([
26
+ "txt",
27
+ "md",
28
+ "json",
29
+ "csv",
30
+ "ts",
31
+ "tsx",
32
+ "js",
33
+ "jsx",
34
+ "html",
35
+ "css",
36
+ "log",
37
+ "xml",
38
+ "yml",
39
+ "yaml",
40
+ "toml",
41
+ "ini",
42
+ "env",
43
+ "vue",
44
+ "sql",
45
+ "deno"
46
+ ]);
47
+
48
+ function isTextLike(path: string): boolean {
49
+ const ext = path.split(/[\\/]/).pop()?.split(".").pop()?.toLowerCase() ?? "";
50
+ return TEXT_EXTS.has(ext);
51
+ }
52
+
53
+ function nameFromUrl(input: string): string {
54
+ if (/^(https?|file):\/\//i.test(input)) {
55
+ try {
56
+ const name = decodeURIComponent(new URL(input).pathname.split("/").pop() || "");
57
+ return name || "deskapp-download.bin";
58
+ } catch {
59
+ return "deskapp-download.bin";
60
+ }
61
+ }
62
+ return input.split(/[\\/]/).pop() || "deskapp-download.bin";
63
+ }
64
+
65
+ /** Open any real file: native picker, then bytes + metadata (+ text preview). */
66
+ export const open = async (): Promise<Record<string, unknown>> => {
67
+ const path = await pickers.open({ title: "Open a file" });
68
+ if (!path) return { ok: false, error: "cancelled", action: "open" };
69
+ try {
70
+ const meta = await files.fileMeta(path);
71
+ if (!meta?.isFile) return { ok: false, action: "open", path, error: "not a file" };
72
+ const bytes = await files.readBinaryFile(path);
73
+ const preview = isTextLike(path) ? new TextDecoder().decode(bytes).slice(0, 2000) : null;
74
+ return {
75
+ ok: true,
76
+ action: "open",
77
+ path,
78
+ size: meta.size,
79
+ modifiedAt: meta.modifiedAt.toISOString(),
80
+ preview
81
+ };
82
+ } catch (error) {
83
+ return { ok: false, action: "open", path, error: String(error) };
84
+ }
85
+ };
86
+
87
+ /** Save real content with a native Save As dialog (atomic write). */
88
+ export const save = async (): Promise<Record<string, unknown>> => {
89
+ const path = await pickers.save({
90
+ title: "Save file as",
91
+ defaultName: `deskapp-note-${Date.now()}.txt`,
92
+ filter: "Text files (*.txt)|*.txt|All files (*.*)|*.*"
93
+ });
94
+ if (!path) return { ok: false, error: "cancelled", action: "save" };
95
+ const content = `deskapp real save - ${new Date().toISOString()}\n`;
96
+ try {
97
+ await files.writeTextFile(path, content);
98
+ const meta = await files.fileMeta(path);
99
+ return { ok: true, action: "save", path, bytes: content.length, size: meta?.size ?? 0 };
100
+ } catch (error) {
101
+ return { ok: false, action: "save", path, error: String(error) };
102
+ }
103
+ };
104
+
105
+ /** Upload (import) a real source file into the app's private store. */
106
+ export const upload = async (): Promise<Record<string, unknown>> => {
107
+ const source = await pickers.open({ title: "Choose a file to upload" });
108
+ if (!source) return { ok: false, error: "cancelled", action: "upload" };
109
+ try {
110
+ const destDir = storage.disk("private").path("uploads");
111
+ const dest = await files.uploadFile(source, destDir);
112
+ const meta = await files.fileMeta(source);
113
+ return { ok: true, action: "upload", source, dest, size: meta?.size ?? 0 };
114
+ } catch (error) {
115
+ return { ok: false, action: "upload", source, error: String(error) };
116
+ }
117
+ };
118
+
119
+ /** Download a real URL to a real location chosen via Save As (atomic). */
120
+ export const download = async (url: string | undefined): Promise<Record<string, unknown>> => {
121
+ const clean = (url ?? "").trim();
122
+ if (!clean) return { ok: false, error: "enter a URL first", action: "download" };
123
+ const dest = await pickers.save({
124
+ title: "Save downloaded file as",
125
+ defaultName: nameFromUrl(clean)
126
+ });
127
+ if (!dest) return { ok: false, error: "cancelled", action: "download" };
128
+ try {
129
+ await files.downloadFile(clean, dest);
130
+ const meta = await files.fileMeta(dest);
131
+ return { ok: true, action: "download", url: clean, dest, size: meta?.size ?? 0 };
132
+ } catch (error) {
133
+ return { ok: false, action: "download", url: clean, dest, error: String(error) };
134
+ }
135
+ };
136
+
137
+ /** Remove a real file (missing-safe). */
138
+ export const remove = async (): Promise<Record<string, unknown>> => {
139
+ const path = await pickers.open({ title: "Choose a file to remove" });
140
+ if (!path) return { ok: false, error: "cancelled", action: "remove" };
141
+ try {
142
+ await files.removePath(path);
143
+ return { ok: true, action: "remove", path, existsAfter: await files.pathExists(path) };
144
+ } catch (error) {
145
+ return { ok: false, action: "remove", path, error: String(error) };
146
+ }
147
+ };
148
+
149
+ /** List the files inside a real folder chosen via the native picker. */
150
+ export const list = async (): Promise<Record<string, unknown>> => {
151
+ const path = await pickers.folder({ title: "Choose a folder to list" });
152
+ if (!path) return { ok: false, error: "cancelled", action: "list" };
153
+ try {
154
+ return { ok: true, action: "list", path, files: await files.listFiles(path) };
155
+ } catch (error) {
156
+ return { ok: false, action: "list", path, error: String(error) };
157
+ }
158
+ };
159
+
160
+ /* ---------------------------------------------------------------------------
161
+ * App-managed layer (private disk + tmp generated artifacts)
162
+ * ------------------------------------------------------------------------ */
163
+
164
+ const STATE_FILE = "samples/state.json";
165
+
166
+ /** Save app-owned state into the private disk (storage.put). */
167
+ export const appSave = async (): Promise<Record<string, unknown>> => {
168
+ const data = { theme: "dark", updatedAt: new Date().toISOString(), note: "app-managed private state" };
169
+ await storage.put(STATE_FILE, JSON.stringify(data, null, 2));
170
+ return { ok: true, action: "save (app state)", file: STATE_FILE, data };
171
+ };
172
+
173
+ /** Read app-owned state back (storage.get). */
174
+ export const appLoad = async (): Promise<Record<string, unknown>> => {
175
+ try {
176
+ const raw = await storage.get(STATE_FILE);
177
+ return { ok: true, action: "read (app state)", file: STATE_FILE, content: new TextDecoder().decode(raw) || null };
178
+ } catch (error) {
179
+ return { ok: false, action: "read (app state)", file: STATE_FILE, error: String(error) };
180
+ }
181
+ };
182
+
183
+ /** List the private disk contents (storage.files / storage.directories). */
184
+ export const appList = async (): Promise<Record<string, unknown>> => {
185
+ return {
186
+ ok: true,
187
+ action: "list (app state)",
188
+ disk: storage.disk("private").path("."),
189
+ files: await storage.files(),
190
+ directories: await storage.directories()
191
+ };
192
+ };
193
+
194
+ /** Generate an ephemeral export in tmp, then consume it read-once. */
195
+ export const appExport = async (): Promise<Record<string, unknown>> => {
196
+ const file = await storage.generateForDownload({
197
+ prefix: "report",
198
+ extension: "csv",
199
+ data: "name,value\nrows,2\n"
200
+ });
201
+ const bytes = await storage.consumeGenerated(file);
202
+ return {
203
+ ok: true,
204
+ action: "generate + consume (tmp)",
205
+ file,
206
+ content: new TextDecoder().decode(bytes).trim()
207
+ };
208
+ };
209
+
210
+ /** Delete app-owned state from the private disk (storage.delete). */
211
+ export const appDelete = async (): Promise<Record<string, unknown>> => {
212
+ await storage.delete(STATE_FILE);
213
+ return { ok: true, action: "delete (app state)", file: STATE_FILE, existsAfter: await storage.exists(STATE_FILE) };
214
+ };
215
+
216
+ /** Handlers exposed to the frontend via the bindings registry. */
217
+ export const handlers = {
218
+ open,
219
+ save,
220
+ upload,
221
+ download,
222
+ remove,
223
+ list,
224
+ appSave,
225
+ appLoad,
226
+ appList,
227
+ appExport,
228
+ appDelete
229
+ };
@@ -0,0 +1,107 @@
1
+ import { app } from "electron";
2
+ import { config } from "@/core/config";
3
+ import { chrome, type DesktopWindow, win } from "@/core/facade";
4
+
5
+ /** The window the controller acts on (the main window by default). */
6
+ function targetWindow(): DesktopWindow | undefined {
7
+ return win.getWindow();
8
+ }
9
+
10
+ /* ---------------------------------------------------------------------------
11
+ * Window controls
12
+ * ------------------------------------------------------------------------ */
13
+
14
+ export const setTitle = (title: unknown): void => {
15
+ const w = targetWindow();
16
+ if (w && typeof title === "string") w.setTitle(title);
17
+ };
18
+
19
+ export const setSize = (width: unknown, height: unknown): void => {
20
+ const w = targetWindow();
21
+ if (w && typeof width === "number" && typeof height === "number") {
22
+ w.setSize(width, height);
23
+ }
24
+ };
25
+
26
+ export const toggleAlwaysOnTop = (): void => {
27
+ const w = targetWindow();
28
+ if (!w) return;
29
+ w.setAlwaysOnTop(!w.isAlwaysOnTop());
30
+ };
31
+
32
+ export const focus = (): void => {
33
+ targetWindow()?.focus();
34
+ };
35
+
36
+ export const open = async (name: unknown): Promise<boolean> => {
37
+ if (typeof name !== "string") return false;
38
+ const opened = await win.openWindow(name);
39
+ return Boolean(opened);
40
+ };
41
+
42
+ export const openUrl = async (url: unknown): Promise<boolean> => {
43
+ if (typeof url !== "string") return false;
44
+ let parsed: URL;
45
+ try {
46
+ parsed = new URL(url);
47
+ } catch {
48
+ return false;
49
+ }
50
+ if (parsed.protocol !== "http:" && parsed.protocol !== "https:") return false;
51
+
52
+ const opened = await win.openWindow({
53
+ title: parsed.hostname,
54
+ width: 1024,
55
+ height: 720
56
+ });
57
+
58
+ if (!opened) return false;
59
+ opened.loadURL(parsed.href); // Electron uses loadURL instead of navigate
60
+ return true;
61
+ };
62
+
63
+ /* ---------------------------------------------------------------------------
64
+ * Menus, Tray, Dialogs
65
+ * ------------------------------------------------------------------------ */
66
+
67
+ export const installMenu = (): void => {
68
+ const w = targetWindow();
69
+ if (w) chrome.installAppMenu(w);
70
+ };
71
+
72
+ export const showContextMenu = (): void => {
73
+ // Context menu is handled natively by Electron in window/native.ts
74
+ // No manual call needed from the frontend.
75
+ };
76
+
77
+ export const createTray = (): boolean => {
78
+ chrome.createAppTray();
79
+ return true;
80
+ };
81
+
82
+ export const confirmSomething = async (message: unknown): Promise<boolean> => {
83
+ return await chrome.confirmDialog(typeof message === "string" ? message : "Are you sure?");
84
+ };
85
+
86
+ export const alertSomething = async (message: unknown): Promise<void> => {
87
+ await chrome.alertDialog(typeof message === "string" ? message : "Hello from Deskapp");
88
+ };
89
+
90
+ export const quit = (): void => {
91
+ app.quit();
92
+ };
93
+
94
+ export const handlers = {
95
+ setTitle,
96
+ setSize,
97
+ toggleAlwaysOnTop,
98
+ focus,
99
+ open,
100
+ openUrl,
101
+ installMenu,
102
+ showContextMenu,
103
+ createTray,
104
+ confirmSomething,
105
+ alertSomething,
106
+ quit
107
+ };
@@ -0,0 +1,35 @@
1
+ import { contextBridge, ipcRenderer } from "electron";
2
+
3
+ type BindingFn = (...args: unknown[]) => Promise<unknown>;
4
+
5
+ function setNested(root: Record<string, any>, path: string, fn: BindingFn) {
6
+ const parts = path.split(".");
7
+ let cur = root;
8
+ for (let i = 0; i < parts.length - 1; i++) {
9
+ const key = parts[i];
10
+ if (!cur[key] || typeof cur[key] !== "object" || typeof cur[key] === "function") cur[key] = {};
11
+ cur = cur[key];
12
+ }
13
+ cur[parts[parts.length - 1]] = fn;
14
+ }
15
+
16
+ try {
17
+ // contextBridge cannot clone/expose a Proxy reliably; expose a concrete object.
18
+ // Supports both forms: bindings['app.window.focus']() and bindings.app.window.focus()
19
+ const names = ipcRenderer.sendSync("deskapp:__list__") as string[];
20
+ const api: Record<string, any> = {};
21
+ for (const name of names) {
22
+ const fn: BindingFn = (...args: unknown[]) => ipcRenderer.invoke(`deskapp:${name}`, ...args);
23
+ api[name] = fn; // flat, backward-compatible
24
+ setNested(api, name, fn); // nested short form
25
+ }
26
+ // Fallback invoker for any name not in the static list.
27
+ api.__invoke = (name: string, ...args: unknown[]) => ipcRenderer.invoke(`deskapp:${name}`, ...args);
28
+
29
+ // `md` = module calls (short alias). `bindings` kept for compatibility.
30
+ contextBridge.exposeInMainWorld("md", api);
31
+ contextBridge.exposeInMainWorld("bindings", api);
32
+ console.log(`[preload] module bridge ready (${names.length} handlers) as \`md\`/\`bindings\``);
33
+ } catch (err) {
34
+ console.error("[preload] failed to expose bindings", err);
35
+ }
@@ -0,0 +1 @@
1
+
@@ -0,0 +1,5 @@
1
+ {
2
+ "theme": "dark",
3
+ "updatedAt": "2026-11-09T19:12:34.887Z",
4
+ "note": "app-managed private state"
5
+ }
File without changes
File without changes
File without changes
@@ -0,0 +1,3 @@
1
+ {
2
+ "recommendations": ["Vue.volar"]
3
+ }
@@ -0,0 +1,14 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Deskapp</title>
7
+ </head>
8
+ <body>
9
+ <div id="app"></div>
10
+ <div id="toast-show"></div>
11
+ <!-- Ensure this path matches where your app.ts is located -->
12
+ <script type="module" src="/src/app.ts"></script>
13
+ </body>
14
+ </html>
@@ -0,0 +1,24 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg">
2
+ <symbol id="bluesky-icon" viewBox="0 0 16 17">
3
+ <g clip-path="url(#bluesky-clip)"><path fill="#08060d" d="M7.75 7.735c-.693-1.348-2.58-3.86-4.334-5.097-1.68-1.187-2.32-.981-2.74-.79C.188 2.065.1 2.812.1 3.251s.241 3.602.398 4.13c.52 1.744 2.367 2.333 4.07 2.145-2.495.37-4.71 1.278-1.805 4.512 3.196 3.309 4.38-.71 4.987-2.746.608 2.036 1.307 5.91 4.93 2.746 2.72-2.746.747-4.143-1.747-4.512 1.702.189 3.55-.4 4.07-2.145.156-.528.397-3.691.397-4.13s-.088-1.186-.575-1.406c-.42-.19-1.06-.395-2.741.79-1.755 1.24-3.64 3.752-4.334 5.099"/></g>
4
+ <defs><clipPath id="bluesky-clip"><path fill="#fff" d="M.1.85h15.3v15.3H.1z"/></clipPath></defs>
5
+ </symbol>
6
+ <symbol id="discord-icon" viewBox="0 0 20 19">
7
+ <path fill="#08060d" d="M16.224 3.768a14.5 14.5 0 0 0-3.67-1.153c-.158.286-.343.67-.47.976a13.5 13.5 0 0 0-4.067 0c-.128-.306-.317-.69-.476-.976A14.4 14.4 0 0 0 3.868 3.77C1.546 7.28.916 10.703 1.231 14.077a14.7 14.7 0 0 0 4.5 2.306q.545-.748.965-1.587a9.5 9.5 0 0 1-1.518-.74q.191-.14.372-.293c2.927 1.369 6.107 1.369 8.999 0q.183.152.372.294-.723.437-1.52.74.418.838.963 1.588a14.6 14.6 0 0 0 4.504-2.308c.37-3.911-.63-7.302-2.644-10.309m-9.13 8.234c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.894 0 1.614.82 1.599 1.82.001 1-.705 1.82-1.6 1.82m5.91 0c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.893 0 1.614.82 1.599 1.82 0 1-.706 1.82-1.6 1.82"/>
8
+ </symbol>
9
+ <symbol id="documentation-icon" viewBox="0 0 21 20">
10
+ <path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="m15.5 13.333 1.533 1.322c.645.555.967.833.967 1.178s-.322.623-.967 1.179L15.5 18.333m-3.333-5-1.534 1.322c-.644.555-.966.833-.966 1.178s.322.623.966 1.179l1.534 1.321"/>
11
+ <path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M17.167 10.836v-4.32c0-1.41 0-2.117-.224-2.68-.359-.906-1.118-1.621-2.08-1.96-.599-.21-1.349-.21-2.848-.21-2.623 0-3.935 0-4.983.369-1.684.591-3.013 1.842-3.641 3.428C3 6.449 3 7.684 3 10.154v2.122c0 2.558 0 3.838.706 4.726q.306.383.713.671c.76.536 1.79.64 3.581.66"/>
12
+ <path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M3 10a2.78 2.78 0 0 1 2.778-2.778c.555 0 1.209.097 1.748-.047.48-.129.854-.503.982-.982.145-.54.048-1.194.048-1.749a2.78 2.78 0 0 1 2.777-2.777"/>
13
+ </symbol>
14
+ <symbol id="github-icon" viewBox="0 0 19 19">
15
+ <path fill="#08060d" fill-rule="evenodd" d="M9.356 1.85C5.05 1.85 1.57 5.356 1.57 9.694a7.84 7.84 0 0 0 5.324 7.44c.387.079.528-.168.528-.376 0-.182-.013-.805-.013-1.454-2.165.467-2.616-.935-2.616-.935-.349-.91-.864-1.143-.864-1.143-.71-.48.051-.48.051-.48.787.051 1.2.805 1.2.805.695 1.194 1.817.857 2.268.649.064-.507.27-.857.49-1.052-1.728-.182-3.545-.857-3.545-3.87 0-.857.31-1.558.8-2.104-.078-.195-.349-1 .077-2.078 0 0 .657-.208 2.14.805a7.5 7.5 0 0 1 1.946-.26c.657 0 1.328.092 1.946.26 1.483-1.013 2.14-.805 2.14-.805.426 1.078.155 1.883.078 2.078.502.546.799 1.247.799 2.104 0 3.013-1.818 3.675-3.558 3.87.284.247.528.714.528 1.454 0 1.052-.012 1.896-.012 2.156 0 .208.142.455.528.377a7.84 7.84 0 0 0 5.324-7.441c.013-4.338-3.48-7.844-7.773-7.844" clip-rule="evenodd"/>
16
+ </symbol>
17
+ <symbol id="social-icon" viewBox="0 0 20 20">
18
+ <path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M12.5 6.667a4.167 4.167 0 1 0-8.334 0 4.167 4.167 0 0 0 8.334 0"/>
19
+ <path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M2.5 16.667a5.833 5.833 0 0 1 8.75-5.053m3.837.474.513 1.035c.07.144.257.282.414.309l.93.155c.596.1.736.536.307.965l-.723.73a.64.64 0 0 0-.152.531l.207.903c.164.715-.213.991-.84.618l-.872-.52a.63.63 0 0 0-.577 0l-.872.52c-.624.373-1.003.094-.84-.618l.207-.903a.64.64 0 0 0-.152-.532l-.723-.729c-.426-.43-.289-.864.306-.964l.93-.156a.64.64 0 0 0 .412-.31l.513-1.034c.28-.562.735-.562 1.012 0"/>
20
+ </symbol>
21
+ <symbol id="x-icon" viewBox="0 0 19 19">
22
+ <path fill="#08060d" fill-rule="evenodd" d="M1.893 1.98c.052.072 1.245 1.769 2.653 3.77l2.892 4.114c.183.261.333.48.333.486s-.068.089-.152.183l-.522.593-.765.867-3.597 4.087c-.375.426-.734.834-.798.905a1 1 0 0 0-.118.148c0 .01.236.017.664.017h.663l.729-.83c.4-.457.796-.906.879-.999a692 692 0 0 0 1.794-2.038c.034-.037.301-.34.594-.675l.551-.624.345-.392a7 7 0 0 1 .34-.374c.006 0 .93 1.306 2.052 2.903l2.084 2.965.045.063h2.275c1.87 0 2.273-.003 2.266-.021-.008-.02-1.098-1.572-3.894-5.547-2.013-2.862-2.28-3.246-2.273-3.266.008-.019.282-.332 2.085-2.38l2-2.274 1.567-1.782c.022-.028-.016-.03-.65-.03h-.674l-.3.342a871 871 0 0 1-1.782 2.025c-.067.075-.405.458-.75.852a100 100 0 0 1-.803.91c-.148.172-.299.344-.99 1.127-.304.343-.32.358-.345.327-.015-.019-.904-1.282-1.976-2.808L6.365 1.85H1.8zm1.782.91 8.078 11.294c.772 1.08 1.413 1.973 1.425 1.984.016.017.241.02 1.05.017l1.03-.004-2.694-3.766L7.796 5.75 5.722 2.852l-1.039-.004-1.039-.004z" clip-rule="evenodd"/>
23
+ </symbol>
24
+ </svg>
@@ -0,0 +1,3 @@
1
+ <template>
2
+ <router-view />
3
+ </template>
@@ -0,0 +1,23 @@
1
+ import { createApp } from "vue";
2
+ import App from "@/ui/App.vue";
3
+ import faviconUrl from "@/ui/assets/images/favicon/favicon.ico";
4
+ import { GumPlugin } from "@/ui/plugins/gum.ts";
5
+ import { PulsePlugin, pulse } from "@/ui/plugins/pulse.ts";
6
+ import router from "@/ui/router/index.ts";
7
+
8
+ import "bootstrap/dist/css/bootstrap.min.css";
9
+ import "bootstrap-icons/font/bootstrap-icons.css";
10
+ import "bootstrap/dist/js/bootstrap.bundle.min.js";
11
+ import "@/ui/assets/scss/custom.scss";
12
+
13
+ let favicon = document.querySelector<HTMLLinkElement>('link[rel="icon"]');
14
+ if (!favicon) {
15
+ favicon = document.createElement("link");
16
+ favicon.rel = "icon";
17
+ document.head.appendChild(favicon);
18
+ }
19
+ favicon.href = faviconUrl;
20
+
21
+ export { pulse };
22
+
23
+ createApp(App).use(PulsePlugin).use(GumPlugin).use(router).mount("#app");
@@ -0,0 +1,186 @@
1
+ @font-face {
2
+ font-family: "Public Sans";
3
+ font-style: normal;
4
+ font-weight: 100 900;
5
+ font-display: swap;
6
+ src: url("../fonts/public-sans/public-sans-latin.woff2") format("woff2");
7
+ unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
8
+ }
9
+
10
+ @font-face {
11
+ font-family: "Public Sans";
12
+ font-style: normal;
13
+ font-weight: 100 900;
14
+ font-display: swap;
15
+ src: url("../fonts/public-sans/public-sans-latin-ext.woff2") format("woff2");
16
+ unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
17
+ }
18
+
19
+ :root {
20
+ color-scheme: dark;
21
+ --dk-bg: #0b0f14;
22
+ --dk-bg-soft: #0e141b;
23
+ --dk-surface: #121a23;
24
+ --dk-surface-2: #16202b;
25
+ --dk-border: rgba(148, 180, 218, 0.14);
26
+ --dk-text: #e6edf3;
27
+ --dk-muted: #9fb0c3;
28
+ --dk-faint: #6b7b90;
29
+ --dk-accent: #4ea3ff;
30
+ --dk-accent-2: #22d3ee;
31
+ --dk-safe: #34d399;
32
+ --dk-warn: #fbbf24;
33
+ --dk-err: #fb7185;
34
+
35
+ /* Map to Bootstrap 5.3+ CSS variables */
36
+ --bs-body-bg: var(--dk-bg);
37
+ --bs-body-color: var(--dk-text);
38
+ --bs-body-color-rgb: 230, 237, 243;
39
+ --bs-emphasis-color: var(--dk-text);
40
+ --bs-emphasis-color-rgb: 230, 237, 243;
41
+ --bs-secondary-color: var(--dk-muted);
42
+ --bs-secondary-color-rgb: 159, 176, 195;
43
+ --bs-tertiary-color: var(--dk-faint);
44
+ --bs-secondary-bg: var(--dk-surface);
45
+ --bs-tertiary-bg: var(--dk-surface-2);
46
+ --bs-card-bg: var(--dk-surface);
47
+ --bs-card-color: var(--dk-text);
48
+ --bs-card-border-color: var(--dk-border);
49
+ --bs-border-color: var(--dk-border);
50
+ --bs-primary: var(--dk-accent);
51
+ --bs-link-color: var(--dk-accent);
52
+ --bs-link-hover-color: var(--dk-accent-2);
53
+ }
54
+
55
+ *,
56
+ *::before,
57
+ *::after {
58
+ box-sizing: border-box;
59
+ }
60
+
61
+ html,
62
+ body {
63
+ height: 100%;
64
+ margin: 0;
65
+ }
66
+
67
+ body {
68
+ font-family: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
69
+ color: var(--dk-text);
70
+ background-color: var(--dk-bg);
71
+ -webkit-font-smoothing: antialiased;
72
+ text-rendering: optimizeLegibility;
73
+ }
74
+
75
+ #app {
76
+ position: relative;
77
+ height: 100%;
78
+ }
79
+
80
+ /* Safari / WebKit */
81
+ input[type="file"].form-control::-webkit-file-upload-button {
82
+ color: var(--dk-text) !important;
83
+ background-color: var(--dk-surface) !important;
84
+ border: 1px solid var(--dk-border) !important;
85
+ margin-right: 0.75rem;
86
+ padding: 0.375rem 0.75rem;
87
+ border-radius: 0.375rem;
88
+ }
89
+
90
+ button,
91
+ input {
92
+ font-family: inherit;
93
+ font-size: inherit;
94
+ line-height: inherit;
95
+ color: inherit;
96
+ }
97
+
98
+ button {
99
+ border: 0;
100
+ background: none;
101
+ cursor: pointer;
102
+ }
103
+
104
+ input {
105
+ color-scheme: dark;
106
+ }
107
+
108
+ pre {
109
+ margin: 0;
110
+ font-variant-ligatures: none;
111
+ }
112
+
113
+ a {
114
+ color: var(--dk-accent);
115
+ }
116
+
117
+ :focus-visible {
118
+ outline: 2px solid var(--dk-accent);
119
+ outline-offset: 2px;
120
+ border-radius: 4px;
121
+ }
122
+
123
+ *::-webkit-scrollbar {
124
+ width: 8px;
125
+ height: 8px;
126
+ }
127
+
128
+ *::-webkit-scrollbar-track {
129
+ background: transparent;
130
+ }
131
+
132
+ *::-webkit-scrollbar-thumb {
133
+ background: rgba(148, 180, 218, 0.22);
134
+ border-radius: 8px;
135
+ }
136
+
137
+ *::-webkit-scrollbar-thumb:hover {
138
+ background: rgba(148, 180, 218, 0.4);
139
+ }
140
+
141
+ .datatable thead tr>th,
142
+ .datatable tbody tr>td {
143
+ padding: 7.5px 10px;
144
+ }
145
+
146
+ .datatable thead tr>th:nth-child(-n+2) {
147
+ width: 1%;
148
+ white-space: nowrap;
149
+ }
150
+
151
+ .datatable thead tr>th:nth-child(-n+1),
152
+ .datatable tbody tr>td:nth-child(-n+1) {
153
+ padding-left: 6px !important;
154
+ padding-right: 5px !important;
155
+ }
156
+
157
+ // .datatable thead tr > th:last-child {
158
+ // width: 1% !important;
159
+ // }
160
+
161
+ .datatable-pagination .page-item {
162
+ .page-link {
163
+ border-radius: 5px;
164
+ margin-left: 0;
165
+ border: 1px solid #DFDFDF;
166
+ }
167
+ }
168
+
169
+ // general table
170
+ .datatable-general thead tr>th,
171
+ .datatable-general tbody tr>td {
172
+ padding: 7.5px 10px;
173
+ }
174
+
175
+ .datatable-general thead tr>th:nth-child(-n+1) {
176
+ width: 1%;
177
+ white-space: nowrap;
178
+ }
179
+
180
+ .datatable-general-pagination .page-item {
181
+ .page-link {
182
+ border-radius: 5px;
183
+ margin-left: 0;
184
+ border: 1px solid #DFDFDF;
185
+ }
186
+ }