@housebookgroup/shared-types 1.0.3 → 1.0.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.
@@ -1,8 +1,8 @@
1
- export interface SignupData {
2
- email: string;
3
- password: string;
4
- first_name: string;
5
- last_name: string;
6
- phone: string;
7
- userType: "admin" | "owner";
8
- }
1
+ export interface SignupData {
2
+ email: string;
3
+ password: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ phone: string;
7
+ userType: "admin" | "owner";
8
+ }
@@ -1,25 +1,24 @@
1
- export interface ChangeLog {
2
- id: string;
3
- asset_id: string;
4
- specifications: JSON;
5
- change_description: string;
6
- changed_by_user_id?: string;
7
- created_at: string;
8
- status: ChangeLogStatus;
9
- actions: ChangeLogAction;
10
- deleted: boolean;
11
- asset_name?: string;
12
- space_name?: string;
13
- property_id?: string;
14
- }
15
- declare enum ChangeLogStatus {
16
- PENDING = "PENDING",
17
- ACCEPTED = "ACCEPTED",
18
- DECLINED = "DECLINED"
19
- }
20
- declare enum ChangeLogAction {
21
- CREATED = "CREATED",
22
- UPDATED = "UPDATED",
23
- DELETED = "DELETED"
24
- }
25
- export {};
1
+ export interface ChangeLog {
2
+ id: string;
3
+ assetId: string;
4
+ specifications: JSON;
5
+ changeDescription: string;
6
+ changedByUserId?: string;
7
+ created_at: string;
8
+ status: ChangeLogStatus;
9
+ actions: ChangeLogAction;
10
+ deleted: boolean;
11
+ assetName?: string;
12
+ spaceName?: string;
13
+ propertyId?: string;
14
+ }
15
+ export declare enum ChangeLogStatus {
16
+ PENDING = "PENDING",
17
+ ACCEPTED = "ACCEPTED",
18
+ DECLINED = "DECLINED"
19
+ }
20
+ export declare enum ChangeLogAction {
21
+ CREATED = "CREATED",
22
+ UPDATED = "UPDATED",
23
+ DELETED = "DELETED"
24
+ }
@@ -1,28 +1,22 @@
1
- export interface OwnerData {
2
- firstName: string;
3
- lastName: string;
4
- email: string;
5
- phone: string;
6
- }
7
- export interface FormData {
8
- propertyName: string;
9
- propertyDescription: string;
10
- address: string;
11
- floorPlans: File[];
12
- buildingPlans: File[];
13
- }
14
- export interface AssetFeature {
15
- name: string;
16
- value: string;
17
- }
18
- export interface AssetInt {
19
- typeId: string;
20
- name: string;
21
- description: string;
22
- features: AssetFeature[];
23
- }
24
- export interface SpaceInt {
25
- type: string;
26
- name: string;
27
- assets: AssetInt[];
28
- }
1
+ export interface FormData {
2
+ propertyName: string;
3
+ propertyDescription: string;
4
+ address: string;
5
+ floorPlans: File[];
6
+ buildingPlans: File[];
7
+ }
8
+ export interface AssetFeature {
9
+ name: string;
10
+ value: string;
11
+ }
12
+ export interface AssetInt {
13
+ typeId: string;
14
+ name: string;
15
+ description: string;
16
+ features: AssetFeature[];
17
+ }
18
+ export interface SpaceInt {
19
+ type: string;
20
+ name: string;
21
+ assets: AssetInt[];
22
+ }
@@ -1,30 +1,36 @@
1
- export type Property = {
2
- property_id: string;
3
- address: string;
4
- description: string;
5
- pin: string;
6
- name: string;
7
- type: string;
8
- status: string;
9
- lastUpdated: string;
10
- completionStatus: number;
11
- totalFloorArea?: number;
12
- spaces?: Space[];
13
- images?: string[];
14
- created_at: string;
15
- splash_image?: string;
16
- };
17
- export type Space = {
18
- space_id: string;
19
- name: string;
20
- type: string;
21
- assets: Asset[];
22
- deleted: boolean;
23
- };
24
- export type Asset = {
25
- asset_id: string;
26
- type: string;
27
- description: string;
28
- current_specifications: JSON;
29
- deleted: boolean;
30
- };
1
+ export interface AssetType {
2
+ id: string;
3
+ name: string;
4
+ discipline: string;
5
+ }
6
+ export interface Asset {
7
+ id: string;
8
+ description: string;
9
+ type?: string;
10
+ curretSpecifications: Record<string, any>;
11
+ deleted: boolean;
12
+ assetTypes: AssetType;
13
+ }
14
+ export interface Space {
15
+ id: string;
16
+ name: string;
17
+ type: string;
18
+ deleted: boolean;
19
+ assets: Asset[];
20
+ }
21
+ export interface Property {
22
+ propertyId: string;
23
+ address: string;
24
+ description: string;
25
+ pin: string;
26
+ name: string;
27
+ type: string;
28
+ status: string;
29
+ lastUpdated: string;
30
+ completionStatus: number;
31
+ totalFloorArea?: number;
32
+ spaces?: Space[];
33
+ images?: string[];
34
+ createdAt: string;
35
+ splashImage?: string;
36
+ }
@@ -1,6 +1,6 @@
1
- export type Owner = {
2
- owner_id: string;
3
- first_name: string;
4
- last_name: string;
5
- email: string;
6
- };
1
+ export interface Owner {
2
+ ownerId: string;
3
+ firstName: string;
4
+ lastName: string;
5
+ email: string;
6
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@housebookgroup/shared-types",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "private": false,
@@ -19,5 +19,8 @@
19
19
  "bugs": {
20
20
  "url": "https://github.com/SSIEK-unimelb/housebook-shared-types/issues"
21
21
  },
22
- "homepage": "https://github.com/SSIEK-unimelb/housebook-shared-types#readme"
22
+ "homepage": "https://github.com/SSIEK-unimelb/housebook-shared-types#readme",
23
+ "devDependencies": {
24
+ "typescript": "^5.9.3"
25
+ }
23
26
  }
package/src/authTypes.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  export interface SignupData {
2
2
  email: string;
3
3
  password: string;
4
- first_name: string;
5
- last_name: string;
4
+ firstName: string;
5
+ lastName: string;
6
6
  phone: string;
7
7
  userType: "admin" | "owner";
8
8
  };
@@ -1,26 +1,26 @@
1
1
  export interface ChangeLog {
2
2
  id: string;
3
- asset_id: string;
3
+ assetId: string;
4
4
  specifications: JSON;
5
- change_description: string;
6
- changed_by_user_id?: string;
5
+ changeDescription: string;
6
+ changedByUserId?: string;
7
7
  created_at: string;
8
8
  status: ChangeLogStatus;
9
9
  actions: ChangeLogAction;
10
10
  deleted: boolean;
11
11
  // Joined data
12
- asset_name?: string;
13
- space_name?: string;
14
- property_id?: string;
12
+ assetName?: string;
13
+ spaceName?: string;
14
+ propertyId?: string;
15
15
  }
16
16
 
17
- enum ChangeLogStatus {
17
+ export enum ChangeLogStatus {
18
18
  PENDING = "PENDING",
19
19
  ACCEPTED = "ACCEPTED",
20
20
  DECLINED = "DECLINED",
21
21
  }
22
22
 
23
- enum ChangeLogAction {
23
+ export enum ChangeLogAction {
24
24
  CREATED = "CREATED",
25
25
  UPDATED = "UPDATED",
26
26
  DELETED = "DELETED",
@@ -1,9 +1,9 @@
1
- export interface OwnerData {
2
- firstName: string,
3
- lastName: string,
4
- email: string,
5
- phone: string
6
- }
1
+ // export interface OwnerData {
2
+ // firstName: string,
3
+ // lastName: string,
4
+ // email: string,
5
+ // phone: string
6
+ // }
7
7
 
8
8
  // Setting what FormData looks like
9
9
  export interface FormData {
@@ -1,5 +1,28 @@
1
- export type Property = {
2
- property_id: string;
1
+ export interface AssetType {
2
+ id: string;
3
+ name: string;
4
+ discipline: string;
5
+ }
6
+
7
+ export interface Asset {
8
+ id: string;
9
+ description: string;
10
+ type?: string;
11
+ curretSpecifications: Record<string, any>;
12
+ deleted: boolean;
13
+ assetTypes: AssetType;
14
+ }
15
+
16
+ export interface Space {
17
+ id: string;
18
+ name: string;
19
+ type: string;
20
+ deleted: boolean;
21
+ assets: Asset[];
22
+ }
23
+
24
+ export interface Property {
25
+ propertyId: string;
3
26
  address: string;
4
27
  description: string;
5
28
  pin: string;
@@ -11,23 +34,6 @@ export type Property = {
11
34
  totalFloorArea?: number;
12
35
  spaces?: Space[];
13
36
  images?: string[];
14
- created_at: string;
15
- splash_image?: string;
16
- };
17
-
18
- export type Space = {
19
- space_id: string;
20
- name: string;
21
- type: string;
22
- assets: Asset[];
23
- deleted: boolean;
24
- };
25
-
26
- export type Asset = {
27
- asset_id: string;
28
- type: string;
29
- description: string;
30
- current_specifications: JSON;
31
- deleted: boolean;
32
- };
33
-
37
+ createdAt: string;
38
+ splashImage?: string;
39
+ }
package/src/userTypes.ts CHANGED
@@ -1,6 +1,6 @@
1
- export type Owner = {
2
- owner_id: string;
3
- first_name: string;
4
- last_name: string;
1
+ export interface Owner {
2
+ ownerId: string;
3
+ firstName: string;
4
+ lastName: string;
5
5
  email: string;
6
- };
6
+ }