@skaile/forge-layer-core 1.1.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skaile/forge-layer-core",
3
- "version": "1.1.0",
3
+ "version": "1.3.0",
4
4
  "description": "Nuxt layer every app built on forge-template-app (and forge-template-mobile) stands on: sign-in, principals and API tokens, settings, the server-action catalogue with /api/actions and /mcp, the data model, AI model roles and providers, the assistant's account, engines and definition, the database with its core migrations, and the generic settings and form UI.",
5
5
  "type": "module",
6
6
  "main": "./nuxt.config.ts",
@@ -58,9 +58,12 @@
58
58
  "@iconify-json/tabler": "^1.2.46",
59
59
  "@simplewebauthn/browser": "^13.3.0",
60
60
  "@simplewebauthn/server": "^13.3.3",
61
+ "@types/nodemailer": "^8.0.2",
61
62
  "@vueuse/nuxt": "^15.0.0",
63
+ "nodemailer": "^10.6.3",
62
64
  "nuxt-auth-utils": "^0.6.1",
63
- "postgres": "^4.0.0"
65
+ "postgres": "^4.0.0",
66
+ "ufo": "^1.6.4"
64
67
  },
65
68
  "peerDependencies": {
66
69
  "@nuxt/ui": "^4.11.1",
@@ -0,0 +1,16 @@
1
+ CREATE TABLE "login_codes" (
2
+ "id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
3
+ "user_id" uuid NOT NULL,
4
+ "code_hash" text NOT NULL,
5
+ "link_token_hash" text NOT NULL,
6
+ "expires_at" timestamp with time zone NOT NULL,
7
+ "used_at" timestamp with time zone,
8
+ "attempts" integer DEFAULT 0 NOT NULL,
9
+ "created_at" timestamp with time zone DEFAULT now() NOT NULL,
10
+ "updated_at" timestamp with time zone DEFAULT now() NOT NULL
11
+ );
12
+ --> statement-breakpoint
13
+ ALTER TABLE "users" ADD COLUMN "last_sign_in_at" timestamp with time zone;--> statement-breakpoint
14
+ ALTER TABLE "login_codes" ADD CONSTRAINT "login_codes_user_id_users_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("id") ON DELETE cascade ON UPDATE no action;--> statement-breakpoint
15
+ CREATE UNIQUE INDEX "login_codes_link_token_unique" ON "login_codes" USING btree ("link_token_hash");--> statement-breakpoint
16
+ CREATE INDEX "login_codes_user_created_idx" ON "login_codes" USING btree ("user_id","created_at");