pennly-types 1.0.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.
@@ -0,0 +1,85 @@
1
+ /**
2
+ * Shared Type Definitions for Pennly
3
+ */
4
+ export declare enum TransactionType {
5
+ INCOME = "INCOME",
6
+ EXPENSE = "EXPENSE",
7
+ TRANSFER = "TRANSFER"
8
+ }
9
+ export interface User {
10
+ id: string;
11
+ email: string;
12
+ name?: string;
13
+ createdAt: Date | string;
14
+ updatedAt: Date | string;
15
+ }
16
+ export interface Wallet {
17
+ id: string;
18
+ name: string;
19
+ balance: number;
20
+ currency: string;
21
+ userId: string;
22
+ createdAt: Date | string;
23
+ updatedAt: Date | string;
24
+ }
25
+ export interface Category {
26
+ id: string;
27
+ name: string;
28
+ icon?: string;
29
+ color?: string;
30
+ type: TransactionType;
31
+ userId?: string;
32
+ }
33
+ export interface Transaction {
34
+ id: string;
35
+ amount: number;
36
+ type: TransactionType;
37
+ description?: string;
38
+ date: Date | string;
39
+ categoryId: string;
40
+ walletId: string;
41
+ userId: string;
42
+ createdAt: Date | string;
43
+ updatedAt: Date | string;
44
+ }
45
+ export interface Budget {
46
+ id: string;
47
+ amount: number;
48
+ categoryId: string;
49
+ userId: string;
50
+ startDate: Date | string;
51
+ endDate: Date | string;
52
+ }
53
+ export interface RecurringTransaction {
54
+ id: string;
55
+ amount: number;
56
+ type: TransactionType;
57
+ frequency: 'DAILY' | 'WEEKLY' | 'MONTHLY' | 'YEARLY';
58
+ startDate: Date | string;
59
+ categoryId: string;
60
+ walletId: string;
61
+ userId: string;
62
+ }
63
+ export interface NotificationSettings {
64
+ id: string;
65
+ userId: string;
66
+ pauseAll: boolean;
67
+ accountActivity: boolean;
68
+ vaultAndFlow: boolean;
69
+ }
70
+ export interface RemoteConfig {
71
+ auth: {
72
+ google: boolean;
73
+ email: boolean;
74
+ guest: boolean;
75
+ };
76
+ navigation: {
77
+ home: boolean;
78
+ accounts: boolean;
79
+ history: boolean;
80
+ insights: boolean;
81
+ goals: boolean;
82
+ profile: boolean;
83
+ };
84
+ }
85
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,oBAAY,eAAe;IACzB,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,QAAQ,aAAa;CACtB;AAED,MAAM,WAAW,IAAI;IACnB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,IAAI,GAAG,MAAM,CAAC;IACzB,SAAS,EAAE,IAAI,GAAG,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,IAAI,GAAG,MAAM,CAAC;IACzB,SAAS,EAAE,IAAI,GAAG,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,eAAe,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,eAAe,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,IAAI,GAAG,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE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 "use strict";
2
+ /**
3
+ * Shared Type Definitions for Pennly
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.TransactionType = void 0;
7
+ var TransactionType;
8
+ (function (TransactionType) {
9
+ TransactionType["INCOME"] = "INCOME";
10
+ TransactionType["EXPENSE"] = "EXPENSE";
11
+ TransactionType["TRANSFER"] = "TRANSFER";
12
+ })(TransactionType || (exports.TransactionType = TransactionType = {}));
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,IAAY,eAIX;AAJD,WAAY,eAAe;IACzB,oCAAiB,CAAA;IACjB,sCAAmB,CAAA;IACnB,wCAAqB,CAAA;AACvB,CAAC,EAJW,eAAe,+BAAf,eAAe,QAI1B"}
package/package.json ADDED
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "pennly-types",
3
+ "version": "1.0.0",
4
+ "description": "Shared TypeScript definitions for Pennly",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
7
+ "scripts": {
8
+ "build": "tsc",
9
+ "dev": "tsc -w"
10
+ },
11
+ "devDependencies": {
12
+ "typescript": "^5.9.3"
13
+ }
14
+ }
package/src/index.ts ADDED
@@ -0,0 +1,93 @@
1
+ /**
2
+ * Shared Type Definitions for Pennly
3
+ */
4
+
5
+ export enum TransactionType {
6
+ INCOME = 'INCOME',
7
+ EXPENSE = 'EXPENSE',
8
+ TRANSFER = 'TRANSFER',
9
+ }
10
+
11
+ export interface User {
12
+ id: string;
13
+ email: string;
14
+ name?: string;
15
+ createdAt: Date | string;
16
+ updatedAt: Date | string;
17
+ }
18
+
19
+ export interface Wallet {
20
+ id: string;
21
+ name: string;
22
+ balance: number;
23
+ currency: string;
24
+ userId: string;
25
+ createdAt: Date | string;
26
+ updatedAt: Date | string;
27
+ }
28
+
29
+ export interface Category {
30
+ id: string;
31
+ name: string;
32
+ icon?: string;
33
+ color?: string;
34
+ type: TransactionType;
35
+ userId?: string; // Optional if global category
36
+ }
37
+
38
+ export interface Transaction {
39
+ id: string;
40
+ amount: number;
41
+ type: TransactionType;
42
+ description?: string;
43
+ date: Date | string;
44
+ categoryId: string;
45
+ walletId: string;
46
+ userId: string;
47
+ createdAt: Date | string;
48
+ updatedAt: Date | string;
49
+ }
50
+
51
+ export interface Budget {
52
+ id: string;
53
+ amount: number;
54
+ categoryId: string;
55
+ userId: string;
56
+ startDate: Date | string;
57
+ endDate: Date | string;
58
+ }
59
+
60
+ export interface RecurringTransaction {
61
+ id: string;
62
+ amount: number;
63
+ type: TransactionType;
64
+ frequency: 'DAILY' | 'WEEKLY' | 'MONTHLY' | 'YEARLY';
65
+ startDate: Date | string;
66
+ categoryId: string;
67
+ walletId: string;
68
+ userId: string;
69
+ }
70
+
71
+ export interface NotificationSettings {
72
+ id: string;
73
+ userId: string;
74
+ pauseAll: boolean;
75
+ accountActivity: boolean;
76
+ vaultAndFlow: boolean;
77
+ }
78
+
79
+ export interface RemoteConfig {
80
+ auth: {
81
+ google: boolean;
82
+ email: boolean;
83
+ guest: boolean;
84
+ };
85
+ navigation: {
86
+ home: boolean;
87
+ accounts: boolean;
88
+ history: boolean;
89
+ insights: boolean;
90
+ goals: boolean;
91
+ profile: boolean;
92
+ };
93
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,18 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "ES2022",
4
+ "module": "CommonJS",
5
+ "moduleResolution": "node",
6
+ "declaration": true,
7
+ "declarationMap": true,
8
+ "sourceMap": true,
9
+ "outDir": "dist",
10
+ "rootDir": "src",
11
+ "strict": true,
12
+ "esModuleInterop": true,
13
+ "skipLibCheck": true,
14
+ "forceConsistentCasingInFileNames": true
15
+ },
16
+ "include": ["src/**/*"],
17
+ "exclude": ["node_modules", "dist"]
18
+ }