@la-main-verte/shared-types 1.0.43 → 1.0.47
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 +1 -1
- package/src/device.d.ts +13 -9
- package/src/image.d.ts +10 -0
- package/src/index.ts +1 -0
- package/src/member.d.ts +13 -0
- package/src/plant.d.ts +1 -0
- package/src/users.api.d.ts +0 -1
package/package.json
CHANGED
package/src/device.d.ts
CHANGED
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
import { Model } from 'sequelize'
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Raw Data returned by the device model
|
|
5
|
-
* Device.toJSON() will return this data
|
|
6
|
-
*/
|
|
7
1
|
/**
|
|
8
2
|
* Raw Data returned by the device model
|
|
9
3
|
* Device.toJSON() will return this data
|
|
@@ -23,9 +17,17 @@ type DeviceDataI = {
|
|
|
23
17
|
platform?: 'ios' | 'android' | 'windows'
|
|
24
18
|
/** Optional version of the device */
|
|
25
19
|
version?: string
|
|
26
|
-
/**
|
|
20
|
+
/**
|
|
21
|
+
* Technical model of the device
|
|
22
|
+
* ---
|
|
23
|
+
* Ex: iPhone12,1, iPhone13,2, iPhone14,4, etc.
|
|
24
|
+
*/
|
|
27
25
|
model?: string
|
|
28
|
-
/**
|
|
26
|
+
/**
|
|
27
|
+
* Readable name of the device
|
|
28
|
+
* ---
|
|
29
|
+
* Ex: 'iPhone 12 Pro Max', 'Samsung Galaxy S20', 'MacBook Pro 13 inch'
|
|
30
|
+
* */
|
|
29
31
|
name?: string
|
|
30
32
|
/** Optional app version of the device. Ex: 1.0.0 */
|
|
31
33
|
appVersion?: string
|
|
@@ -33,5 +35,7 @@ type DeviceDataI = {
|
|
|
33
35
|
createdAt: Date
|
|
34
36
|
/** Timestamp of when the device was last updated */
|
|
35
37
|
updatedAt: Date
|
|
38
|
+
/** Virtual field that combines the name and appVersion */
|
|
39
|
+
fullName: string
|
|
36
40
|
}
|
|
37
|
-
|
|
41
|
+
export { DeviceDataI }
|
package/src/image.d.ts
ADDED
package/src/index.ts
CHANGED
package/src/member.d.ts
CHANGED
|
@@ -3,12 +3,18 @@ export interface MemberI {
|
|
|
3
3
|
email: string
|
|
4
4
|
firstName: string
|
|
5
5
|
lastName: string
|
|
6
|
+
/** Virtual field to get the user's full name */
|
|
7
|
+
fullName?: string | null
|
|
6
8
|
city?: string
|
|
7
9
|
hardinessZoneName?: string
|
|
8
10
|
createdAt: Date
|
|
9
11
|
updatedAt: Date
|
|
10
12
|
lastFreezingDate?: Date
|
|
11
13
|
firstFreezingDate?: Date
|
|
14
|
+
/**
|
|
15
|
+
* Number of unread Crisp messages
|
|
16
|
+
*/
|
|
17
|
+
unreadMessagesCount?: number
|
|
12
18
|
notes?: NoteI[]
|
|
13
19
|
selections?: SelectionI[]
|
|
14
20
|
userActivities?: UserActivityI[]
|
|
@@ -37,4 +43,11 @@ export interface MemberI {
|
|
|
37
43
|
finishedOnboarding: boolean
|
|
38
44
|
hasDownloadedNativeApp?: boolean
|
|
39
45
|
unitSystem: 'imperial' | 'metric'
|
|
46
|
+
/**
|
|
47
|
+
* Virtual field to get the app badge count
|
|
48
|
+
* ----------------------------------------
|
|
49
|
+
* For now, it's just the number of unread messages.
|
|
50
|
+
*/
|
|
51
|
+
badgeCount?: number
|
|
52
|
+
isAdmin: boolean
|
|
40
53
|
}
|
package/src/plant.d.ts
CHANGED