feat: only replace the mention syntax within the p tag
This commit is contained in:
@@ -111,7 +111,7 @@ export const ConnectButton: React.FC<{
|
||||
icon: "i-mingcute:home-1-line",
|
||||
label: t("My xLog") || "",
|
||||
url: getSiteLink({
|
||||
subdomain: userSites.data?.[0].username || "",
|
||||
subdomain: userSites.data?.[0]?.username || "",
|
||||
}),
|
||||
},
|
||||
{
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { FC, useEffect, useState } from "react"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useIsDark } from "~/hooks/useDarkMode"
|
||||
import { useIsUnmounted } from "~/hooks/useLifecycle"
|
||||
import { nanoid } from "nanoid"
|
||||
@@ -52,11 +51,9 @@ export const Mermaid: FC<{
|
||||
}
|
||||
}, [props.children])
|
||||
|
||||
const { t } = useTranslation("common")
|
||||
|
||||
return loading ? (
|
||||
<div className="h-[50px] rounded-lg flex items-center justify-center bg-[#ECECFD] dark:bg-[#1F2020] text-sm">
|
||||
Mermaid {t("Loading")}...
|
||||
Mermaid Loading...
|
||||
</div>
|
||||
) : svg ? (
|
||||
<div dangerouslySetInnerHTML={{ __html: svg }} />
|
||||
|
||||
Reference in New Issue
Block a user