@kitledger/core 0.0.6 → 0.0.7

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.
@@ -0,0 +1,27 @@
1
+ {
2
+ "version": "7",
3
+ "dialect": "postgresql",
4
+ "entries": [
5
+ {
6
+ "idx": 0,
7
+ "version": "7",
8
+ "when": 1756234194845,
9
+ "tag": "0000_damp_golden_guardian",
10
+ "breakpoints": true
11
+ },
12
+ {
13
+ "idx": 1,
14
+ "version": "7",
15
+ "when": 1759327531423,
16
+ "tag": "0001_purple_morph",
17
+ "breakpoints": true
18
+ },
19
+ {
20
+ "idx": 2,
21
+ "version": "7",
22
+ "when": 1759329362701,
23
+ "tag": "0002_fair_thundra",
24
+ "breakpoints": true
25
+ }
26
+ ]
27
+ }
package/dist/schema.d.ts CHANGED
@@ -1,4 +1,11 @@
1
1
  import { BalanceType } from "./accounts.js";
2
+ /**
3
+ * Common database helper for timestamps
4
+ */
5
+ export declare const timestamps: {
6
+ created_at: import("drizzle-orm").NotNull<import("drizzle-orm").HasDefault<import("drizzle-orm/pg-core").PgTimestampBuilderInitial<"created_at">>>;
7
+ updated_at: import("drizzle-orm/pg-core").PgTimestampBuilderInitial<"updated_at">;
8
+ };
2
9
  export type BaseMetaProperty = Record<string, string | number | boolean | Date | null>;
3
10
  /**
4
11
  * 1. Tables, Indexes, and Constraints
package/dist/schema.js CHANGED
@@ -1,6 +1,12 @@
1
1
  import { relations } from "drizzle-orm";
2
2
  import { boolean, index, jsonb, pgTable, text, timestamp, uuid, varchar } from "drizzle-orm/pg-core";
3
- import { timestamps } from "./db.js";
3
+ /**
4
+ * Common database helper for timestamps
5
+ */
6
+ export const timestamps = {
7
+ created_at: timestamp("created_at", { mode: "date" }).defaultNow().notNull(),
8
+ updated_at: timestamp("updated_at", { mode: "date" }),
9
+ };
4
10
  /**
5
11
  * 1. Tables, Indexes, and Constraints
6
12
  * This allows us to defined and view the database schema in a structured way.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kitledger/core",
3
- "version": "0.0.6",
3
+ "version": "0.0.7",
4
4
  "private": false,
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -9,6 +9,10 @@
9
9
  "types": "./dist/main.d.ts",
10
10
  "default": "./dist/main.js"
11
11
  },
12
+ "./db": {
13
+ "types": "./dist/db.d.ts",
14
+ "default": "./dist/db.js"
15
+ },
12
16
  "./entities": {
13
17
  "types": "./dist/entities.d.ts",
14
18
  "default": "./dist/entities.js"
@@ -47,13 +51,14 @@
47
51
  },
48
52
  "devDependencies": {
49
53
  "@faker-js/faker": "^10.1.0",
54
+ "copyfiles": "^2.4.1",
50
55
  "drizzle-kit": "^0.31.8"
51
56
  },
52
57
  "publishConfig": {
53
58
  "access": "public"
54
59
  },
55
60
  "scripts": {
56
- "build": "tsc",
61
+ "build": "tsc && copyfiles -u 1 \"src/migrations/**/*\" dist",
57
62
  "typecheck": "tsc --noEmit"
58
63
  }
59
64
  }