create-nexwire 4.2.3 → 4.2.4

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 (61) hide show
  1. package/express/package.json +48 -23
  2. package/express/src/database/migrations/sqlite/0000_init.sql +47 -60
  3. package/express/src/database/migrations/sqlite/meta/0000_snapshot.json +1 -89
  4. package/express/src/database/migrations/sqlite/meta/_journal.json +1 -1
  5. package/express/src/database/schema.ts +2 -3
  6. package/express/src/framework/facade.ts +12 -1
  7. package/express/src/framework/maker-cli/db/core.mjs +291 -288
  8. package/express/src/framework/maker-cli/module/core.mjs +125 -87
  9. package/express/src/framework/maker-cli/module/index.mjs +3 -3
  10. package/express/src/framework/maker-cli/stubs/notification/controller.ts.stub +61 -62
  11. package/express/src/framework/maker-cli/stubs/notification/job.ts.stub +11 -13
  12. package/express/src/framework/maker-cli/stubs/notification/model.ts.stub +29 -0
  13. package/express/src/framework/maker-cli/stubs/notification/provider.ts.stub +174 -0
  14. package/express/src/framework/maker-cli/stubs/notification/route.api.ts.stub +11 -10
  15. package/express/src/framework/maker-cli/stubs/notification/route.plain.ts.stub +1 -1
  16. package/express/src/framework/maker-cli/stubs/notification/schema.plain.ts.stub +25 -25
  17. package/express/src/framework/maker-cli/stubs/notification/schema.ts.stub +25 -25
  18. package/express/src/framework/notification/index.ts +49 -87
  19. package/express/src/framework/providers/adapter.ts +24 -10
  20. package/express/src/framework/providers/contracts.ts +80 -10
  21. package/express/src/framework/providers/registry.ts +27 -1
  22. package/express/src/resources/src/main.ts +1 -1
  23. package/express/src/resources/src/pages/auth/forgetPassword.vue +1 -1
  24. package/express/src/resources/src/pages/auth/login.vue +1 -1
  25. package/express/src/resources/src/pages/auth/register.vue +1 -1
  26. package/express/src/resources/src/pages/auth/resetPassword.vue +1 -1
  27. package/express/src/resources/src/pages/auth/verifyEmail.vue +1 -1
  28. package/express/src/resources/src/pages/dashboard/index.vue +66 -66
  29. package/express/src/storage/database/nexwire.sqlite +0 -0
  30. package/hono/package.json +44 -19
  31. package/hono/src/database/migrations/sqlite/0000_init.sql +47 -60
  32. package/hono/src/database/migrations/sqlite/meta/0000_snapshot.json +1 -89
  33. package/hono/src/database/migrations/sqlite/meta/_journal.json +1 -1
  34. package/hono/src/database/schema.ts +2 -3
  35. package/hono/src/framework/facade.ts +12 -1
  36. package/hono/src/framework/maker-cli/db/core.mjs +291 -288
  37. package/hono/src/framework/maker-cli/module/core.mjs +93 -52
  38. package/hono/src/framework/maker-cli/module/index.mjs +3 -3
  39. package/hono/src/framework/maker-cli/stubs/notification/controller.ts.stub +63 -58
  40. package/hono/src/framework/maker-cli/stubs/notification/job.ts.stub +10 -12
  41. package/hono/src/framework/maker-cli/stubs/notification/model.ts.stub +29 -0
  42. package/hono/src/framework/maker-cli/stubs/notification/provider.ts.stub +174 -0
  43. package/hono/src/framework/maker-cli/stubs/notification/route.api.ts.stub +11 -10
  44. package/hono/src/framework/maker-cli/stubs/notification/route.plain.ts.stub +1 -1
  45. package/hono/src/framework/maker-cli/stubs/notification/schema.plain.ts.stub +25 -25
  46. package/hono/src/framework/maker-cli/stubs/notification/schema.ts.stub +25 -25
  47. package/hono/src/framework/notification/index.ts +49 -87
  48. package/hono/src/framework/providers/adapter.ts +24 -10
  49. package/hono/src/framework/providers/contracts.ts +80 -10
  50. package/hono/src/framework/providers/registry.ts +27 -1
  51. package/hono/src/resources/src/main.ts +1 -1
  52. package/hono/src/resources/src/pages/auth/forgetPassword.vue +1 -1
  53. package/hono/src/resources/src/pages/auth/login.vue +1 -1
  54. package/hono/src/resources/src/pages/auth/register.vue +1 -1
  55. package/hono/src/resources/src/pages/auth/resetPassword.vue +1 -1
  56. package/hono/src/resources/src/pages/auth/verifyEmail.vue +1 -1
  57. package/hono/src/resources/src/pages/dashboard/index.vue +66 -66
  58. package/hono/src/storage/database/nexwire.sqlite +0 -0
  59. package/package.json +10 -10
  60. package/express/src/modules/auth/database/models/notification.ts +0 -24
  61. package/hono/src/modules/auth/database/models/notification.ts +0 -24
@@ -1,66 +1,66 @@
1
- <template>
2
- <Pagebar title="Dashboard" />
3
-
4
- <div class="dashboard-placeholder">
5
- <div class="row g-2 mb-2">
6
- <div class="col-12 col-md-4">
7
- <div class="placeholder-card"></div>
8
- </div>
9
- <div class="col-12 col-md-4">
10
- <div class="placeholder-card"></div>
11
- </div>
12
- <div class="col-12 col-md-4">
13
- <div class="placeholder-card"></div>
14
- </div>
15
- </div>
16
-
17
- <div class="placeholder-panel"></div>
18
- </div>
19
- </template>
20
-
21
- <script setup lang="ts">
22
- import { useHead } from "@vueuse/head";
23
- import { onMounted, onUnmounted } from "vue";
24
- import Pagebar from "@/components/Pagebar.vue";
25
- import { useAuth } from "@/composables/useAuth";
26
- import { pulse } from "@/plugins/pulse";
27
-
28
- useHead({ title: "Dashboard" });
29
-
30
- const { user } = useAuth();
31
-
32
- onMounted(() => {
33
- const ch = pulse.channel("user");
34
- ch.listen("user.changed", () => alert("me"));
35
- onUnmounted(() => ch.stopListening("user.changed"));
36
- });
37
-
38
- // const hardRefresh = () => window.location.reload();
39
- </script>
40
-
41
- <style scoped>
42
- .placeholder-card,
43
- .placeholder-panel {
44
- border: 1px solid var(--app-border);
45
- border-radius: 0.3rem;
46
- background: var(--app-surface);
47
- }
48
-
49
- .placeholder-card {
50
- min-height: 220px;
51
- }
52
-
53
- .placeholder-panel {
54
- min-height: 520px;
55
- }
56
-
57
- @media (max-width: 768px) {
58
- .placeholder-card {
59
- min-height: 160px;
60
- }
61
-
62
- .placeholder-panel {
63
- min-height: 360px;
64
- }
65
- }
66
- </style>
1
+ <template>
2
+ <Pagebar title="Dashboard" />
3
+
4
+ <div class="dashboard-placeholder">
5
+ <div class="row g-2 mb-2">
6
+ <div class="col-12 col-md-4">
7
+ <div class="placeholder-card"></div>
8
+ </div>
9
+ <div class="col-12 col-md-4">
10
+ <div class="placeholder-card"></div>
11
+ </div>
12
+ <div class="col-12 col-md-4">
13
+ <div class="placeholder-card"></div>
14
+ </div>
15
+ </div>
16
+
17
+ <div class="placeholder-panel"></div>
18
+ </div>
19
+ </template>
20
+
21
+ <script setup lang="ts">
22
+ import { useHead } from "@unhead/vue";
23
+ import { onMounted, onUnmounted } from "vue";
24
+ import Pagebar from "@/components/Pagebar.vue";
25
+ import { useAuth } from "@/composables/useAuth";
26
+ import { pulse } from "@/plugins/pulse";
27
+
28
+ useHead({ title: "Dashboard" });
29
+
30
+ const { user } = useAuth();
31
+
32
+ onMounted(() => {
33
+ const ch = pulse.channel("user");
34
+ ch.listen("user.changed", () => alert("me"));
35
+ onUnmounted(() => ch.stopListening("user.changed"));
36
+ });
37
+
38
+ // const hardRefresh = () => window.location.reload();
39
+ </script>
40
+
41
+ <style scoped>
42
+ .placeholder-card,
43
+ .placeholder-panel {
44
+ border: 1px solid var(--app-border);
45
+ border-radius: 0.3rem;
46
+ background: var(--app-surface);
47
+ }
48
+
49
+ .placeholder-card {
50
+ min-height: 220px;
51
+ }
52
+
53
+ .placeholder-panel {
54
+ min-height: 520px;
55
+ }
56
+
57
+ @media (max-width: 768px) {
58
+ .placeholder-card {
59
+ min-height: 160px;
60
+ }
61
+
62
+ .placeholder-panel {
63
+ min-height: 360px;
64
+ }
65
+ }
66
+ </style>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-nexwire",
3
- "version": "4.2.3",
3
+ "version": "4.2.4",
4
4
  "type": "module",
5
5
  "description": "Scaffold a new nexwire project",
6
6
  "bin": {
@@ -51,9 +51,9 @@
51
51
  "@socket.io/admin-ui": "^0.5",
52
52
  "@socket.io/bun-engine": "^0.1",
53
53
  "@socket.io/redis-adapter": "^8",
54
+ "@unhead/vue": "^3",
54
55
  "@vitejs/plugin-vue": "^6",
55
56
  "@vueuse/core": "^14",
56
- "@vueuse/head": "^2",
57
57
  "axios": "^1",
58
58
  "bcryptjs": "^3",
59
59
  "bootstrap": "^5",
@@ -61,7 +61,7 @@
61
61
  "bullmq": "^5",
62
62
  "bullmq-durable": "^0.2",
63
63
  "chalk": "^5",
64
- "commander": "^14",
64
+ "commander": "^15",
65
65
  "croner": "^10",
66
66
  "dotenv": "^17",
67
67
  "dotenv-expand": "^13",
@@ -72,14 +72,14 @@
72
72
  "ioredis": "^5",
73
73
  "lodash-es": "^4",
74
74
  "luxon": "^3",
75
- "maildev": "^2",
75
+ "maildev": "^3",
76
76
  "mysql2": "^3",
77
- "nodemailer": "^9",
77
+ "nodemailer": "^10",
78
78
  "pinia": "^3",
79
79
  "pino": "^10",
80
80
  "postgres": "^3",
81
81
  "redis-commander": "^0.9.0",
82
- "sass-embedded": "^1",
82
+ "sass": "^1",
83
83
  "socket.io": "^4",
84
84
  "socket.io-client": "^4",
85
85
  "stoker": "^2",
@@ -123,13 +123,13 @@
123
123
  "@socket.io/redis-adapter": {
124
124
  "optional": true
125
125
  },
126
- "@vitejs/plugin-vue": {
126
+ "@unhead/vue": {
127
127
  "optional": true
128
128
  },
129
- "@vueuse/core": {
129
+ "@vitejs/plugin-vue": {
130
130
  "optional": true
131
131
  },
132
- "@vueuse/head": {
132
+ "@vueuse/core": {
133
133
  "optional": true
134
134
  },
135
135
  "axios": {
@@ -207,7 +207,7 @@
207
207
  "redis-commander": {
208
208
  "optional": true
209
209
  },
210
- "sass-embedded": {
210
+ "sass": {
211
211
  "optional": true
212
212
  },
213
213
  "socket.io": {
@@ -1,24 +0,0 @@
1
- import { relations } from "drizzle-orm";
2
- import { integer, sqliteTable, text } from "drizzle-orm/sqlite-core";
3
- import { users } from "@/modules/auth/database/models/user.js";
4
-
5
- export const notifications = sqliteTable("notifications", {
6
- id: integer("id").primaryKey({ autoIncrement: true }),
7
- userId: integer("user_id")
8
- .notNull()
9
- .references(() => users.id, { onUpdate: "cascade", onDelete: "cascade" }),
10
- type: text("type").notNull(),
11
- title: text("title").notNull(),
12
- body: text("body"),
13
- data: text("data"),
14
- link: text("link"),
15
- readAt: integer("read_at", { mode: "timestamp" }),
16
- createdAt: integer("created_at", { mode: "timestamp" }).defaultNow().notNull()
17
- });
18
-
19
- export const notificationsRelations = relations(notifications, ({ one }) => ({
20
- user: one(users, {
21
- fields: [notifications.userId],
22
- references: [users.id]
23
- })
24
- }));
@@ -1,24 +0,0 @@
1
- import { relations } from "drizzle-orm";
2
- import { integer, sqliteTable, text } from "drizzle-orm/sqlite-core";
3
- import { users } from "@/modules/auth/database/models/user.js";
4
-
5
- export const notifications = sqliteTable("notifications", {
6
- id: integer("id").primaryKey({ autoIncrement: true }),
7
- userId: integer("user_id")
8
- .notNull()
9
- .references(() => users.id, { onUpdate: "cascade", onDelete: "cascade" }),
10
- type: text("type").notNull(),
11
- title: text("title").notNull(),
12
- body: text("body"),
13
- data: text("data"),
14
- link: text("link"),
15
- readAt: integer("read_at", { mode: "timestamp" }),
16
- createdAt: integer("created_at", { mode: "timestamp" }).defaultNow().notNull()
17
- });
18
-
19
- export const notificationsRelations = relations(notifications, ({ one }) => ({
20
- user: one(users, {
21
- fields: [notifications.userId],
22
- references: [users.id]
23
- })
24
- }));