2
0

(sheets) Add option to select single row when matching multiple

Closes #501
This commit is contained in:
Baptiste Arnaud
2023-05-12 11:21:24 -04:00
parent 45224f9fb3
commit 55dbb1abc7
3 changed files with 90 additions and 46 deletions

View File

@ -35,6 +35,13 @@ const initialGoogleSheetsOptionsSchema = googleSheetsOptionsBaseSchema.merge(
})
)
export const totalRowsToExtractOptions = [
'All',
'First',
'Last',
'Random',
] as const
const googleSheetsGetOptionsSchema = googleSheetsOptionsBaseSchema.merge(
z.object({
action: z.enum([GoogleSheetsAction.GET]),
@ -48,6 +55,7 @@ const googleSheetsGetOptionsSchema = googleSheetsOptionsBaseSchema.merge(
})
.optional(),
cellsToExtract: z.array(extractingCellSchema),
totalRowsToExtract: z.enum(totalRowsToExtractOptions).optional(),
})
)