@wasto/sdk 1.0.3 → 1.0.5

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.
Files changed (56) hide show
  1. package/dist/index.d.mts +60 -3
  2. package/dist/index.d.ts +60 -3
  3. package/dist/index.js +79 -0
  4. package/dist/index.mjs +79 -0
  5. package/package.json +1 -1
  6. package/src/client.ts +791 -692
  7. package/src/dashboard-apps.ts +367 -350
  8. package/src/dto/cms-app-settings.ts +91 -91
  9. package/src/enums.ts +298 -298
  10. package/src/free-tier.ts +56 -56
  11. package/src/index.ts +35 -35
  12. package/src/opening-hours/constants.ts +48 -48
  13. package/src/opening-hours/convert.ts +276 -276
  14. package/src/opening-hours/format.ts +99 -99
  15. package/src/opening-hours/index.ts +9 -9
  16. package/src/opening-hours/is-open-now.ts +38 -38
  17. package/src/opening-hours/resolve.ts +71 -71
  18. package/src/opening-hours/time.ts +74 -74
  19. package/src/opening-hours/timezone.ts +34 -34
  20. package/src/opening-hours/types.ts +53 -53
  21. package/src/opening-hours/validate.ts +182 -182
  22. package/src/roi/calculations.ts +732 -732
  23. package/src/roi/index.ts +1 -1
  24. package/src/types/app-preload.types.ts +10 -0
  25. package/src/types/asset-bookings.types.ts +19 -19
  26. package/src/types/asset-interventions.types.ts +24 -24
  27. package/src/types/assets.types.ts +68 -68
  28. package/src/types/auth.types.ts +37 -37
  29. package/src/types/blog-posts.types.ts +19 -19
  30. package/src/types/calendar-pdf.types.ts +24 -24
  31. package/src/types/calendo-events.types.ts +64 -64
  32. package/src/types/challenges.types.ts +30 -30
  33. package/src/types/chatbot.types.ts +82 -82
  34. package/src/types/cities.types.ts +27 -27
  35. package/src/types/city-groups.types.ts +46 -46
  36. package/src/types/cms.types.ts +87 -87
  37. package/src/types/field-reports.types.ts +66 -66
  38. package/src/types/free-tier.types.ts +54 -54
  39. package/src/types/index.ts +33 -32
  40. package/src/types/iot.types.ts +31 -31
  41. package/src/types/maintenance.types.ts +44 -44
  42. package/src/types/mapso.types.ts +146 -146
  43. package/src/types/notifications.types.ts +68 -68
  44. package/src/types/onboarding.types.ts +117 -117
  45. package/src/types/operational-zones.types.ts +70 -70
  46. package/src/types/pagination.types.ts +33 -33
  47. package/src/types/providers.types.ts +29 -29
  48. package/src/types/quiz-questions.types.ts +59 -59
  49. package/src/types/recycling-points.types.ts +47 -47
  50. package/src/types/roi.types.ts +60 -60
  51. package/src/types/surveys.types.ts +103 -103
  52. package/src/types/tickets.types.ts +65 -65
  53. package/src/types/users.types.ts +30 -30
  54. package/src/types/waste-collection-places-query.types.ts +4 -4
  55. package/src/types/waste-collection-places.types.ts +34 -33
  56. package/src/types/waste-types.types.ts +21 -21
@@ -1,91 +1,91 @@
1
- /**
2
- * Typed shape of CmsSite.settings when type === 'APP'.
3
- * Used for splash, icon and theme configuration (Expo-compatible).
4
- */
5
-
6
- /** Splash screen config (expo-splash-screen compatible) */
7
- export interface AppSplashSettings {
8
- /** Image URL or media id */
9
- image?: string;
10
- backgroundColor?: string;
11
- imageWidth?: number;
12
- resizeMode?: 'contain' | 'cover';
13
- dark?: {
14
- backgroundColor?: string;
15
- };
16
- }
17
-
18
- /** Adaptive icon for Android (Expo format) */
19
- export interface AppAdaptiveIconSettings {
20
- foregroundImage?: string;
21
- backgroundImage?: string;
22
- monochromeImage?: string;
23
- backgroundColor?: string;
24
- }
25
-
26
- /** App icon config (Expo format, 1024x1024 main icon) */
27
- export interface AppIconSettings {
28
- /** Main icon URL (1024x1024) */
29
- image?: string;
30
- adaptiveIcon?: AppAdaptiveIconSettings;
31
- }
32
-
33
- /** Gradient definition */
34
- export interface AppThemeGradient {
35
- from?: string;
36
- to?: string;
37
- stops?: string[];
38
- }
39
-
40
- /** Style template: colors, gradient, border radius */
41
- export interface AppThemeSettings {
42
- primary?: string;
43
- /** Text / icons on `primary` background */
44
- onPrimary?: string;
45
- secondary?: string;
46
- tertiary?: string;
47
- gradient?: AppThemeGradient;
48
- success?: string;
49
- error?: string;
50
- dark?: string;
51
- grey?: string;
52
- /** e.g. "none" | "sm" | "md" | "lg" or number in px */
53
- borderRadius?: string | number;
54
- }
55
-
56
- /** Tab item for app navigation (expo-router Tabs) */
57
- export interface AppTabConfig {
58
- id: string;
59
- title: string;
60
- /** Icon name (e.g. lucide: Home, MapPin, Calendar, Info) */
61
- icon?: string;
62
- screenId: string;
63
- route: string;
64
- }
65
-
66
- /** Stack screen for app navigation (expo-router Stack, outside tabs) */
67
- export interface AppStackScreenConfig {
68
- id: string;
69
- screenId: string;
70
- route: string;
71
- options?: Record<string, unknown>;
72
- }
73
-
74
- /** Layout config: tabs + stack screens, consumed by clone script to generate _layout.tsx */
75
- export interface AppLayoutsConfig {
76
- tabs?: AppTabConfig[];
77
- stackScreens?: AppStackScreenConfig[];
78
- /** Route or id of the initial tab (default first tab) */
79
- initialTab?: string;
80
- }
81
-
82
- /** Full app settings stored in CmsSite.settings when type === 'APP' */
83
- export interface AppSettings {
84
- /** If set, app uses this URL for API client instead of env */
85
- apiBaseUrl?: string;
86
- splash?: AppSplashSettings;
87
- icon?: AppIconSettings;
88
- theme?: AppThemeSettings;
89
- /** Tabs and stack screens; used by clone script to generate layout files */
90
- layouts?: AppLayoutsConfig;
91
- }
1
+ /**
2
+ * Typed shape of CmsSite.settings when type === 'APP'.
3
+ * Used for splash, icon and theme configuration (Expo-compatible).
4
+ */
5
+
6
+ /** Splash screen config (expo-splash-screen compatible) */
7
+ export interface AppSplashSettings {
8
+ /** Image URL or media id */
9
+ image?: string;
10
+ backgroundColor?: string;
11
+ imageWidth?: number;
12
+ resizeMode?: 'contain' | 'cover';
13
+ dark?: {
14
+ backgroundColor?: string;
15
+ };
16
+ }
17
+
18
+ /** Adaptive icon for Android (Expo format) */
19
+ export interface AppAdaptiveIconSettings {
20
+ foregroundImage?: string;
21
+ backgroundImage?: string;
22
+ monochromeImage?: string;
23
+ backgroundColor?: string;
24
+ }
25
+
26
+ /** App icon config (Expo format, 1024x1024 main icon) */
27
+ export interface AppIconSettings {
28
+ /** Main icon URL (1024x1024) */
29
+ image?: string;
30
+ adaptiveIcon?: AppAdaptiveIconSettings;
31
+ }
32
+
33
+ /** Gradient definition */
34
+ export interface AppThemeGradient {
35
+ from?: string;
36
+ to?: string;
37
+ stops?: string[];
38
+ }
39
+
40
+ /** Style template: colors, gradient, border radius */
41
+ export interface AppThemeSettings {
42
+ primary?: string;
43
+ /** Text / icons on `primary` background */
44
+ onPrimary?: string;
45
+ secondary?: string;
46
+ tertiary?: string;
47
+ gradient?: AppThemeGradient;
48
+ success?: string;
49
+ error?: string;
50
+ dark?: string;
51
+ grey?: string;
52
+ /** e.g. "none" | "sm" | "md" | "lg" or number in px */
53
+ borderRadius?: string | number;
54
+ }
55
+
56
+ /** Tab item for app navigation (expo-router Tabs) */
57
+ export interface AppTabConfig {
58
+ id: string;
59
+ title: string;
60
+ /** Icon name (e.g. lucide: Home, MapPin, Calendar, Info) */
61
+ icon?: string;
62
+ screenId: string;
63
+ route: string;
64
+ }
65
+
66
+ /** Stack screen for app navigation (expo-router Stack, outside tabs) */
67
+ export interface AppStackScreenConfig {
68
+ id: string;
69
+ screenId: string;
70
+ route: string;
71
+ options?: Record<string, unknown>;
72
+ }
73
+
74
+ /** Layout config: tabs + stack screens, consumed by clone script to generate _layout.tsx */
75
+ export interface AppLayoutsConfig {
76
+ tabs?: AppTabConfig[];
77
+ stackScreens?: AppStackScreenConfig[];
78
+ /** Route or id of the initial tab (default first tab) */
79
+ initialTab?: string;
80
+ }
81
+
82
+ /** Full app settings stored in CmsSite.settings when type === 'APP' */
83
+ export interface AppSettings {
84
+ /** If set, app uses this URL for API client instead of env */
85
+ apiBaseUrl?: string;
86
+ splash?: AppSplashSettings;
87
+ icon?: AppIconSettings;
88
+ theme?: AppThemeSettings;
89
+ /** Tabs and stack screens; used by clone script to generate layout files */
90
+ layouts?: AppLayoutsConfig;
91
+ }