feat(boards): add upload buttons for background, favicon and logo (#2770)
* feat(boards): add upload buttons for background, favicon and logo * feat(boards): use media search and show names for background * fix: background preview not working
This commit is contained in:
@@ -33,6 +33,9 @@ interface IconPickerProps {
|
||||
error?: string | null;
|
||||
onFocus?: FocusEventHandler;
|
||||
onBlur?: FocusEventHandler;
|
||||
|
||||
label?: string;
|
||||
placeholder?: string;
|
||||
withAsterisk?: boolean;
|
||||
}
|
||||
|
||||
@@ -43,6 +46,8 @@ export const IconPicker = ({
|
||||
onFocus,
|
||||
onBlur,
|
||||
withAsterisk = true,
|
||||
label,
|
||||
placeholder,
|
||||
}: IconPickerProps) => {
|
||||
const [value, setValue] = useUncontrolled({
|
||||
value: propsValue,
|
||||
@@ -155,8 +160,8 @@ export const IconPicker = ({
|
||||
rightSectionPointerEvents="none"
|
||||
withAsterisk={withAsterisk}
|
||||
error={error}
|
||||
label={tCommon("iconPicker.label")}
|
||||
placeholder={tCommon("iconPicker.header", { countIcons: String(data?.countIcons ?? 0) })}
|
||||
label={label ?? tCommon("iconPicker.label")}
|
||||
placeholder={placeholder ?? tCommon("iconPicker.header", { countIcons: String(data?.countIcons ?? 0) })}
|
||||
/>
|
||||
{session?.user.permissions.includes("media-upload") && (
|
||||
<UploadMedia
|
||||
|
||||
Reference in New Issue
Block a user