fix(calendar): open event modal directly in edit mode
Publish Docker Image / prepare (push) Successful in 1s
Publish Docker Image / build (linux/amd64, ubuntu-latest) (push) Failing after 8s
Publish Docker Image / build (linux/arm64, ubuntu-24.04-arm) (push) Canceled after 0s
Publish Docker Image / merge (push) Canceled after 0s
Publish Docker Image / prepare (push) Successful in 1s
Publish Docker Image / build (linux/amd64, ubuntu-latest) (push) Failing after 8s
Publish Docker Image / build (linux/arm64, ubuntu-24.04-arm) (push) Canceled after 0s
Publish Docker Image / merge (push) Canceled after 0s
This commit is contained in:
@@ -217,7 +217,9 @@ export function EventModal({
|
|||||||
const timeDisplayFmt = timeFormat === "12h" ? "h:mm a" : "HH:mm";
|
const timeDisplayFmt = timeFormat === "12h" ? "h:mm a" : "HH:mm";
|
||||||
const isEdit = !!event;
|
const isEdit = !!event;
|
||||||
const formatEventDate = useFormatEventDate();
|
const formatEventDate = useFormatEventDate();
|
||||||
const [mode, setMode] = useState<"view" | "edit">(isEdit ? "view" : "edit");
|
// Open directly in edit mode so the fields are immediately editable. The
|
||||||
|
// read-only summary (view mode) is still reachable via the Cancel button.
|
||||||
|
const [mode, setMode] = useState<"view" | "edit">("edit");
|
||||||
|
|
||||||
const userIsOrganizer = useMemo(() => {
|
const userIsOrganizer = useMemo(() => {
|
||||||
if (!event) return true;
|
if (!event) return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user