-
-
Notifications
You must be signed in to change notification settings - Fork 181
chore: merge dev to main #182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
df81e9b
ac83671
5ca1290
8c4619f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -166,38 +166,40 @@ export function EditKeyForm({ keyData, user, onSuccess }: EditKeyFormProps) { | |
| /> | ||
| </FormGrid> | ||
|
|
||
| <div className="space-y-2"> | ||
| <Label htmlFor="daily-reset-mode">{t("dailyResetMode.label")}</Label> | ||
| <Select | ||
| value={form.values.dailyResetMode} | ||
| onValueChange={(value: "fixed" | "rolling") => form.setValue("dailyResetMode", value)} | ||
| disabled={isPending} | ||
| > | ||
| <SelectTrigger id="daily-reset-mode"> | ||
| <SelectValue /> | ||
| </SelectTrigger> | ||
| <SelectContent> | ||
| <SelectItem value="fixed">{t("dailyResetMode.options.fixed")}</SelectItem> | ||
| <SelectItem value="rolling">{t("dailyResetMode.options.rolling")}</SelectItem> | ||
| </SelectContent> | ||
| </Select> | ||
| <p className="text-xs text-muted-foreground"> | ||
| {form.values.dailyResetMode === "fixed" | ||
| ? t("dailyResetMode.desc.fixed") | ||
| : t("dailyResetMode.desc.rolling")} | ||
| </p> | ||
| </div> | ||
| <FormGrid columns={2}> | ||
|
Owner
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🟡 Medium: Empty column in 2-column grid when dailyResetMode is "rolling" Why this is a problem: Same issue as in Suggested fix: <FormGrid columns={form.values.dailyResetMode === "fixed" ? 2 : 1}>Dynamically set the number of columns based on whether the time field will be shown. |
||
| <div className="space-y-2"> | ||
| <Label htmlFor="daily-reset-mode">{t("dailyResetMode.label")}</Label> | ||
| <Select | ||
| value={form.values.dailyResetMode} | ||
| onValueChange={(value: "fixed" | "rolling") => form.setValue("dailyResetMode", value)} | ||
| disabled={isPending} | ||
| > | ||
| <SelectTrigger id="daily-reset-mode"> | ||
| <SelectValue /> | ||
| </SelectTrigger> | ||
| <SelectContent> | ||
| <SelectItem value="fixed">{t("dailyResetMode.options.fixed")}</SelectItem> | ||
| <SelectItem value="rolling">{t("dailyResetMode.options.rolling")}</SelectItem> | ||
| </SelectContent> | ||
| </Select> | ||
| <p className="text-xs text-muted-foreground"> | ||
| {form.values.dailyResetMode === "fixed" | ||
| ? t("dailyResetMode.desc.fixed") | ||
| : t("dailyResetMode.desc.rolling")} | ||
| </p> | ||
| </div> | ||
|
|
||
| {form.values.dailyResetMode === "fixed" && ( | ||
| <TextField | ||
| label={t("dailyResetTime.label")} | ||
| placeholder={t("dailyResetTime.placeholder")} | ||
| description={t("dailyResetTime.description")} | ||
| type="time" | ||
| step={60} | ||
| {...form.getFieldProps("dailyResetTime")} | ||
| /> | ||
| )} | ||
| {form.values.dailyResetMode === "fixed" && ( | ||
| <TextField | ||
| label={t("dailyResetTime.label")} | ||
| placeholder={t("dailyResetTime.placeholder")} | ||
| description={t("dailyResetTime.description")} | ||
| type="time" | ||
| step={60} | ||
| {...form.getFieldProps("dailyResetTime")} | ||
| /> | ||
| )} | ||
| </FormGrid> | ||
|
|
||
| <FormGrid columns={2}> | ||
| <NumberField | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟡 Medium: Empty column in 2-column grid when dailyResetMode is "rolling"
Why this is a problem: When the
dailyResetModeis set to "rolling", thedailyResetTimefield is not rendered, leaving the second column of theFormGridempty. This creates an unbalanced layout with visible empty space on the right side.Suggested fix: