fix description/label styles to be consistent

This commit is contained in:
jeffvli
2026-07-23 19:57:06 -07:00
parent a0bae0ffb0
commit bcc6edc5dc
26 changed files with 111 additions and 11 deletions
@@ -25,7 +25,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.section { .section {
@@ -26,6 +26,7 @@ export const Autocomplete = forwardRef<HTMLInputElement, AutocompleteProps>(
return ( return (
<MantineAutocomplete <MantineAutocomplete
classNames={{ classNames={{
description: styles.description,
dropdown: styles.dropdown, dropdown: styles.dropdown,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
@@ -25,7 +25,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.dropdown { .dropdown {
@@ -16,6 +16,7 @@ export const ColorInput = ({
return ( return (
<MantineColorInput <MantineColorInput
classNames={{ classNames={{
description: styles.description,
dropdown: styles.dropdown, dropdown: styles.dropdown,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
@@ -17,3 +17,13 @@
.required { .required {
color: var(--theme-colors-state-error); color: var(--theme-colors-state-error);
} }
.label {
margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
}
@@ -26,6 +26,7 @@ export const DateInput = ({
return ( return (
<MantineDateInput <MantineDateInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -56,6 +57,7 @@ export const DateTimeInput = ({
return ( return (
<MantineDateTimeInput <MantineDateTimeInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -17,3 +17,13 @@
.required { .required {
color: var(--theme-colors-state-error); color: var(--theme-colors-state-error);
} }
.label {
margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
}
@@ -21,6 +21,7 @@ export const DateTimePicker = ({
return ( return (
<MantineDateTimePicker <MantineDateTimePicker
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -35,6 +35,12 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
font-family: var(--theme-label-font-family); font-family: var(--theme-label-font-family);
} }
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
}
@@ -28,6 +28,7 @@ export const FileInput = forwardRef<HTMLButtonElement, FileInputProps>(
return ( return (
<MantineFileInput <MantineFileInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -35,5 +35,11 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
@@ -28,6 +28,7 @@ export const JsonInput = forwardRef<HTMLTextAreaElement, JsonInputProps>(
return ( return (
<MantineJsonInput <MantineJsonInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -5,7 +5,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.dropdown { .dropdown {
@@ -12,6 +12,7 @@ export interface MultiSelectProps extends MantineMultiSelectProps {
} }
const defaultClassNames = { const defaultClassNames = {
description: styles.description,
dropdown: styles.dropdown, dropdown: styles.dropdown,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
@@ -42,5 +42,11 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
@@ -31,6 +31,7 @@ export const NumberInput = forwardRef<HTMLInputElement, NumberInputProps>(
<MantineNumberInput <MantineNumberInput
classNames={{ classNames={{
control: styles.control, control: styles.control,
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -35,5 +35,11 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
@@ -16,6 +16,7 @@ export const PasswordInput = forwardRef<HTMLInputElement, PasswordInputProps>(
return ( return (
<MantinePasswordInput <MantinePasswordInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -25,7 +25,7 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
} }
.dropdown { .dropdown {
@@ -57,3 +57,9 @@
.option:hover { .option:hover {
background: lighten(var(--theme-colors-surface), 5%); background: lighten(var(--theme-colors-surface), 5%);
} }
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
}
+1
View File
@@ -23,6 +23,7 @@ export const Select = ({
<MantineSelect <MantineSelect
allowDeselect={allowDeselect || clearable} allowDeselect={allowDeselect || clearable}
classNames={{ classNames={{
description: styles.description,
dropdown: styles.dropdown, dropdown: styles.dropdown,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
@@ -5,7 +5,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.dropdown { .dropdown {
@@ -12,6 +12,7 @@ export interface TagsInputProps extends MantineTagsInputProps {
} }
const defaultClassNames = { const defaultClassNames = {
description: styles.description,
dropdown: styles.dropdown, dropdown: styles.dropdown,
input: styles.input, input: styles.input,
inputField: styles.inputField, inputField: styles.inputField,
@@ -23,7 +23,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.section { .section {
@@ -28,6 +28,7 @@ export const TextInput = forwardRef<HTMLInputElement, TextInputProps>(
return ( return (
<MantineTextInput <MantineTextInput
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,
@@ -23,7 +23,13 @@
} }
.label { .label {
margin-bottom: var(--theme-spacing-sm); margin-bottom: var(--theme-spacing-xs);
}
.description {
margin-bottom: var(--theme-spacing-xs);
font-size: var(--theme-font-size-xs);
color: var(--theme-colors-foreground-muted);
} }
.required { .required {
@@ -25,6 +25,7 @@ export const Textarea = forwardRef<HTMLTextAreaElement, TextareaProps>(
return ( return (
<MantineTextarea <MantineTextarea
classNames={{ classNames={{
description: styles.description,
input: styles.input, input: styles.input,
label: styles.label, label: styles.label,
required: styles.required, required: styles.required,