@la-main-verte/shared-types 1.0.62 → 1.0.64

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": "@la-main-verte/shared-types",
3
- "version": "1.0.62",
3
+ "version": "1.0.64",
4
4
  "description": "Shared TypeScript interfaces for frontend of la-main-verte app",
5
5
  "main": "src/index.js",
6
6
  "types": "src/index.d.ts",
@@ -1,3 +1,6 @@
1
+ import { PlantSelectionI } from './plantSelection'
2
+ import { FertilizerI } from './fertilizer'
3
+
1
4
  /**
2
5
  * Available garden map categories across the platform
3
6
  */
@@ -103,4 +106,11 @@ export interface GardenZoneCultureI {
103
106
  numberOfSeedsPerAlley?: number
104
107
  fertilizerQuantitySuggested?: string
105
108
  Fertilizer?: FertilizerI
109
+ custom_space_between_seeds_in_cm?: number
110
+ custom_space_between_alley_in_cm?: number
106
111
  }
112
+
113
+ export type UpdateGardenZonePayload = Partial<GardenZoneI> &
114
+ Partial<GardenZoneCultureI> & {
115
+ targetNumberOfPlants?: number
116
+ }
package/src/home.api.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import type { PlantI } from './plant'
2
2
  import type { SelectionI } from './selection'
3
+ import type { TaskI } from './task'
3
4
 
4
5
  export namespace HOME {
5
6
  export type HeroCardMode = 'featuredSelection' | 'featuredPlant'
@@ -13,6 +14,7 @@ export namespace HOME {
13
14
  | 'Weather'
14
15
  | 'AdviceCarousel'
15
16
  | 'OnboardingCard'
17
+ | 'UpcomingTasks'
16
18
 
17
19
  export type CarouselComponentType = Extract<
18
20
  SectionComponentType,
@@ -143,6 +145,53 @@ export namespace HOME {
143
145
  totalStepsCount: number
144
146
  }
145
147
 
148
+ /** Minimal plant info for preview display in grouped tasks */
149
+ export interface TaskPlantPreviewI {
150
+ name: string
151
+ slug: string
152
+ imageURL?: string | null
153
+ }
154
+
155
+ /** Family group info when multiple plants share the same task */
156
+ export interface TaskFamilyGroupI {
157
+ familyName: string
158
+ plantsCount: number
159
+ plants: TaskPlantPreviewI[]
160
+ }
161
+
162
+ export interface UpcomingTaskI {
163
+ task: TaskI
164
+ plantName: string
165
+ plantSlug: string
166
+ plantImageURL?: string | null
167
+ gardenName: string
168
+ gardenCategory: string
169
+ selectionSlug: string
170
+ /** If this task is grouped by family */
171
+ familyGroup?: TaskFamilyGroupI
172
+ }
173
+
174
+ export interface UpcomingTaskAdviceI {
175
+ content: string
176
+ taskName: string
177
+ plantName: string
178
+ plantSlug: string
179
+ plantImageURL?: string | null
180
+ gardenName: string
181
+ gardenCategory: string
182
+ selectionSlug: string
183
+ task: TaskI
184
+ /** If this task is grouped by family */
185
+ familyGroup?: TaskFamilyGroupI
186
+ }
187
+
188
+ export interface UpcomingTasksSectionI {
189
+ componentType: 'UpcomingTasks'
190
+ title: string
191
+ subtitle?: string
192
+ advices: UpcomingTaskAdviceI[]
193
+ }
194
+
146
195
  export type SectionI =
147
196
  | HeaderSectionI
148
197
  | HeroCardsSectionI
@@ -152,6 +201,7 @@ export namespace HOME {
152
201
  | WeatherSectionI
153
202
  | AdviceSectionI
154
203
  | OnboardingCardSectionI
204
+ | UpcomingTasksSectionI
155
205
 
156
206
  export interface Response {
157
207
  sections: SectionI[]