) => {
- if (event.target !== document.activeElement) {
- event.preventDefault();
- (event.target as HTMLInputElement).select();
- }
- };
-
- const renderRoomDialog = () => {
+ if (activeRoomLink) {
return (
-
- {!activeRoomLink && (
- <>
-
{t("roomDialog.desc_intro")}
-
{`🔒 ${t("roomDialog.desc_privacy")}`}
-
- {
- trackEvent("share", "room creation", `ui (${getFrame()})`);
- onRoomCreate();
- }}
- >
- {start}
-
-
- >
- )}
- {activeRoomLink && (
- <>
-
{t("roomDialog.desc_inProgressIntro")}
-
{t("roomDialog.desc_shareLink")}
-
-
- {"share" in navigator ? (
-
- ) : null}
-
-
-
+
+ {t("labels.liveCollaboration")}
+
+
event.key === KEYS.ENTER && handleClose()}
+ />
+
+
+ {isShareSupported && (
+
+ )}
+
+
+
-
-
-
- onUsernameChange(event.target.value)}
- onKeyPress={(event) =>
- event.key === KEYS.ENTER && handleClose()
- }
- />
-
-
-
- {"🔒"}
-
- {t("roomDialog.desc_privacy")}
-
- {t("roomDialog.desc_exitSession")}
-
- {
- trackEvent("share", "room closed");
- onRoomDestroy();
- }}
- >
- {stop}
-
-
- >
- )}
-
+
+
event.preventDefault()}
+ onCloseAutoFocus={(event) => event.preventDefault()}
+ className="RoomDialog__popover"
+ side="top"
+ align="end"
+ sideOffset={5.5}
+ >
+ {tablerCheckIcon} copied
+
+
+
+
+
+
+ 🔒{" "}
+
+ {t("roomDialog.desc_privacy")}
+
+
{t("roomDialog.desc_exitSession")}
+
+
+
+ {
+ trackEvent("share", "room closed");
+ onRoomDestroy();
+ }}
+ />
+
+ >
);
- };
+ }
+
+ return (
+ <>
+
+
+
+
+ {t("labels.liveCollaboration")}
+
+
+
+ {t("roomDialog.desc_intro")}
+ {t("roomDialog.desc_privacy")}
+
+
+
+ {
+ trackEvent("share", "room creation", `ui (${getFrame()})`);
+ onRoomCreate();
+ }}
+ />
+
+ >
+ );
+};
+
+const RoomDialog = (props: RoomModalProps) => {
return (
);
};
diff --git a/src/excalidraw-app/index.tsx b/src/excalidraw-app/index.tsx
index 9017bbb8..e1af5480 100644
--- a/src/excalidraw-app/index.tsx
+++ b/src/excalidraw-app/index.tsx
@@ -671,8 +671,8 @@ const ExcalidrawWrapper = () => {
{t("alerts.collabOfflineWarning")}
)}
+ {excalidrawAPI && }
- {excalidrawAPI && }
{errorMessage && (
setErrorMessage("")}>
{errorMessage}