mgtypes 1.0.100 → 1.0.102

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": "mgtypes",
3
- "version": "1.0.100",
3
+ "version": "1.0.102",
4
4
  "description": "types for mg development",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -42,8 +42,8 @@ export enum mgNotificationsPermissionTitle {
42
42
  // STATE //////////////////////////////////////////////
43
43
  // THESE ARE THE ACTUAL CURRENT PERMISSIONS AVAILABLE IN APP
44
44
  export interface mgPermissionsState {
45
- SHOW_LOCATION_AND_DISTANCES: mgNonNativePermission;
46
- LOCATION_FOREGROUND: mgNativePermission;
45
+ SHOW_LOCATION_AND_DISTANCES?: mgNonNativePermission;
46
+ LOCATION_FOREGROUND?: mgNativePermission;
47
47
  }
48
48
 
49
49
  export interface mgNativePermission {
@@ -56,13 +56,6 @@ export interface mgNonNativePermission {
56
56
  isToggleable: boolean;
57
57
  }
58
58
 
59
- /**
60
- * a non-native permission state in secure store
61
- */
62
- export interface mgSecureStorePermission {
63
- disabled: boolean; // disabled permisions won't be displayed in Settings page
64
- isGranted: boolean;
65
- }
66
59
 
67
60
  // ORDERS OF PERMISSIONS //////////////////////////////////
68
61
 
@@ -144,14 +144,18 @@ export interface mgFeaturesConfig {
144
144
  userAuthMode: 'guest only' | 'account only' | 'guest or account';
145
145
  AUTH_PAGE: {
146
146
  displayMode: 'never' | 'interval' | 'always';
147
- interval:
148
- | null
149
- | '10 minutes'
150
- | '30 minutes'
151
- | '1 hour'
152
- | '1 day'
153
- | '1 week'
154
- | '1 month';
147
+ interval: {
148
+ amount: number;
149
+ units: 'second' | 'minute' | 'day' | 'week' | 'month' | 'year';
150
+ };
151
+ };
152
+ };
153
+ PERMISSIONS: {
154
+ MODAL: {
155
+ interval: {
156
+ amount: number;
157
+ units: 'second' | 'minute' | 'day' | 'week' | 'month' | 'year';
158
+ };
155
159
  };
156
160
  };
157
161
  }
@@ -322,7 +326,7 @@ export interface mgFontTextStyle {
322
326
  *
323
327
  * @property labelLarge: BUTTONS, segmented buttons
324
328
  * accordion titles, help modal, confirm action snackbar title
325
- * @property labelMedium: Billboard title,
329
+ * @property labelMedium: Billboard title, setting subtitles
326
330
  * @property labelSmall: bottom navigation buttons,
327
331
  * Billboard "ZOOM IN", custom chip,
328
332
  * other small-font instructions/labels,
@@ -441,21 +445,35 @@ export interface mgPermissionsProfile {
441
445
  // if a permission is not toggleable and defaults to false, don't
442
446
  // even bother showing it
443
447
  LOCATION: {
444
- SHOW_LOCATION_AND_DISTANCES: { isToggleable: boolean; default: boolean }; // blue dot and user-to-pin distances
448
+ SHOW_LOCATION_AND_DISTANCES: {
449
+ isToggleable: boolean;
450
+ isGrantedByDefault: boolean;
451
+ requestOnInit: boolean;
452
+ }; // blue dot and user-to-pin distances
445
453
  // user coordinate are sent to server
446
- ENABLE_GEOTARGETED_CONTENT: { isToggleable: boolean; default: boolean };
454
+ ENABLE_GEOTARGETED_CONTENT: {
455
+ isToggleable: boolean;
456
+ isGrantedByDefault: boolean;
457
+ requestOnInit: boolean;
458
+ };
447
459
  // shares location with friends when using the app
448
460
  SHARE_FOREGROUND_LOCATION_WITH_FRIENDS: {
449
461
  isToggleable: boolean;
450
- default: boolean;
462
+ isGrantedByDefault: boolean;
463
+ requestOnInit: boolean;
451
464
  };
452
465
  // shares location with friends when not using the app
453
466
  SHARE_BACKGROUND_LOCATION_WITH_FRIENDS: {
454
467
  isToggleable: boolean;
455
- default: boolean;
468
+ isGrantedByDefault: boolean;
469
+ requestOnInit: boolean;
456
470
  };
457
471
  // requires both foreground and background location tracking
458
- SHARE_LOCATIONS_FOR_EMERGENCIES: { isToggleable: boolean; default: boolean };
472
+ SHARE_LOCATIONS_FOR_EMERGENCIES: {
473
+ isToggleable: boolean;
474
+ isGrantedByDefault: boolean;
475
+ requestOnInit: boolean;
476
+ };
459
477
  };
460
478
 
461
479
  // TODO:permissionsConfig