Skip to content

Commit 4af91d5

Browse files
authored
Pairing session timepicker fixes (#542)
* Remove unsupported min_time/max_time from timepicker (not in Slack API) * Default timepickers to 8 AM / 5 PM
1 parent 9d16950 commit 4af91d5

1 file changed

Lines changed: 4 additions & 8 deletions

File tree

src/bot/requestPairingSession.ts

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -339,10 +339,8 @@ function buildSlotBlocks(slotNumber: number, state?: SlotState): (Block | KnownB
339339
element: {
340340
type: 'timepicker',
341341
action_id: startId,
342-
min_time: '08:00',
343-
max_time: '20:00',
344-
...(state?.startTime ? { initial_time: state.startTime } : {}),
345-
} as any,
342+
initial_time: state?.startTime ?? '08:00',
343+
},
346344
},
347345
{
348346
type: 'input',
@@ -351,10 +349,8 @@ function buildSlotBlocks(slotNumber: number, state?: SlotState): (Block | KnownB
351349
element: {
352350
type: 'timepicker',
353351
action_id: endId,
354-
min_time: '08:00',
355-
max_time: '20:00',
356-
...(state?.endTime ? { initial_time: state.endTime } : {}),
357-
} as any,
352+
initial_time: state?.endTime ?? '17:00',
353+
},
358354
},
359355
];
360356
}

0 commit comments

Comments
 (0)