修改默认配置
This commit is contained in:
@@ -45,7 +45,8 @@ export const CalendarCell = memo((props: CalendarCellProps) => {
|
||||
baseClasses,
|
||||
intensityClass,
|
||||
getCalendarCellStateClass(day),
|
||||
isInteractive ? "cursor-pointer hover:bg-muted/40 hover:border-border/30" : "cursor-default",
|
||||
day.isToday && "underline decoration-1 underline-offset-4",
|
||||
isInteractive ? "cursor-pointer hover:bg-muted/40 hover:border-border/30 hover:text-foreground" : "cursor-default",
|
||||
);
|
||||
|
||||
const button = (
|
||||
|
||||
@@ -10,7 +10,7 @@ interface Props {
|
||||
function MemosLogo(props: Props) {
|
||||
const { collapsed } = props;
|
||||
const { generalSetting: instanceGeneralSetting } = useInstance();
|
||||
const title = instanceGeneralSetting.customProfile?.title || "Memos";
|
||||
const title = instanceGeneralSetting.customProfile?.title || "阿年的备忘录";
|
||||
const avatarUrl = instanceGeneralSetting.customProfile?.logoUrl || "/full-logo.webp";
|
||||
|
||||
return (
|
||||
|
||||
@@ -32,7 +32,7 @@ const MobileHeader = (props: Props) => {
|
||||
return (
|
||||
<div
|
||||
className={cn(
|
||||
"sticky top-0 pt-3 pb-2 sm:pt-2 px-4 sm:px-6 sm:mb-1 bg-background bg-opacity-80 backdrop-blur-lg flex flex-row justify-between items-center w-full h-auto flex-nowrap shrink-0 z-1",
|
||||
"sticky top-0 pt-3 pb-2 sm:pt-2 px-4 sm:px-6 sm:mb-1 bg-background bg-opacity-80 backdrop-blur-lg flex flex-row justify-between items-center w-full h-auto flex-nowrap shrink-0 z-4",
|
||||
offsetTop > 0 && "shadow-md",
|
||||
className,
|
||||
)}
|
||||
|
||||
@@ -40,12 +40,6 @@ const Navigation = (props: Props) => {
|
||||
title: t("common.explore"),
|
||||
icon: <EarthIcon className="w-6 h-auto shrink-0" />,
|
||||
};
|
||||
const aboutNavLink: NavLinkItem = {
|
||||
id: "header-about",
|
||||
path: Routes.ABOUT,
|
||||
title: t("common.about"),
|
||||
icon: <InfoIcon className="w-6 h-auto shrink-0" />,
|
||||
};
|
||||
const attachmentsNavLink: NavLinkItem = {
|
||||
id: "header-attachments",
|
||||
path: Routes.ATTACHMENTS,
|
||||
@@ -77,7 +71,7 @@ const Navigation = (props: Props) => {
|
||||
|
||||
const primaryNavLinks: NavLinkItem[] = currentUser
|
||||
? [homeNavLink, exploreNavLink, attachmentsNavLink, inboxNavLink]
|
||||
: [exploreNavLink, aboutNavLink, signInNavLink];
|
||||
: [exploreNavLink, signInNavLink];
|
||||
const inboxAriaLabel = unreadCount > 0 ? `${t("common.inbox")}, ${unreadCount} unread` : t("common.inbox");
|
||||
|
||||
return (
|
||||
|
||||
@@ -10,7 +10,7 @@ const NavigationDrawer = () => {
|
||||
const location = useLocation();
|
||||
const [open, setOpen] = useState(false);
|
||||
const { generalSetting } = useInstance();
|
||||
const title = generalSetting.customProfile?.title || "Memos";
|
||||
const title = generalSetting.customProfile?.title || "阿年的备忘录";
|
||||
const avatarUrl = generalSetting.customProfile?.logoUrl || "/full-logo.webp";
|
||||
|
||||
useEffect(() => {
|
||||
|
||||
@@ -70,7 +70,7 @@ const InstanceSection = () => {
|
||||
<SettingSection title={t("setting.system.label")}>
|
||||
<SettingGroup title={t("common.basic")} description={t("setting.system.basic-description")}>
|
||||
<SettingList>
|
||||
<SettingListItem label={t("setting.system.server-name")} description={instanceGeneralSetting.customProfile?.title || "Memos"}>
|
||||
<SettingListItem label={t("setting.system.server-name")} description={instanceGeneralSetting.customProfile?.title || "阿年的备忘录"}>
|
||||
<Button variant="outline" onClick={customizeDialog.open}>
|
||||
{t("common.edit")}
|
||||
</Button>
|
||||
|
||||
@@ -62,7 +62,7 @@ const PreferencesSection = () => {
|
||||
const setting: UserSetting_GeneralSetting =
|
||||
generalSetting ||
|
||||
create(UserSetting_GeneralSettingSchema, {
|
||||
locale: "en",
|
||||
locale: "zh-Hans",
|
||||
memoVisibility: "PRIVATE",
|
||||
theme: "system",
|
||||
});
|
||||
|
||||
@@ -59,7 +59,7 @@ function UpdateCustomizedProfileDialog({ open, onOpenChange, onSuccess }: Props)
|
||||
|
||||
const handleRestoreButtonClick = () => {
|
||||
setPartialState({
|
||||
title: "Memos",
|
||||
title: "阿年的备忘录",
|
||||
logoUrl: "/logo.webp",
|
||||
description: "",
|
||||
});
|
||||
|
||||
@@ -142,10 +142,6 @@ const UserMenu = (props: Props) => {
|
||||
<ArchiveIcon className="size-4 text-muted-foreground" />
|
||||
{t("common.archived")}
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuItem onClick={() => navigateTo(Routes.ABOUT)}>
|
||||
<InfoIcon className="size-4 text-muted-foreground" />
|
||||
{t("common.about")}
|
||||
</DropdownMenuItem>
|
||||
<DropdownMenuSub>
|
||||
<DropdownMenuSubTrigger>
|
||||
<GlobeIcon className="size-4 text-muted-foreground" />
|
||||
|
||||
+1
-1
@@ -78,7 +78,7 @@ i18n
|
||||
},
|
||||
fallbackLng: {
|
||||
...fallbacks,
|
||||
...{ default: ["en"] },
|
||||
...{ default: ["zh-Hans"] },
|
||||
} as FallbackLng,
|
||||
});
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ const AdminSignIn = () => {
|
||||
<div className="w-full py-4 grow flex flex-col justify-center items-center">
|
||||
<div className="w-full flex flex-row justify-center items-center mb-6">
|
||||
<img className="h-14 w-auto rounded-full shadow" src={instanceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
|
||||
<p className="ml-2 text-5xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "Memos"}</p>
|
||||
<p className="ml-2 text-4xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "阿年的备忘录"}</p>
|
||||
</div>
|
||||
<p className="w-full text-xl font-medium text-muted-foreground">Sign in with admin accounts</p>
|
||||
<PasswordSignInForm />
|
||||
|
||||
@@ -75,7 +75,7 @@ const SignIn = () => {
|
||||
<div className="w-full py-4 grow flex flex-col justify-center items-center">
|
||||
<div className="w-full flex flex-row justify-center items-center mb-6">
|
||||
<img className="h-14 w-auto rounded-full shadow" src={instanceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
|
||||
<p className="ml-2 text-5xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "Memos"}</p>
|
||||
<p className="ml-2 text-4xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "阿年的备忘录"}</p>
|
||||
</div>
|
||||
{!instanceGeneralSetting.disallowPasswordAuth ? (
|
||||
<PasswordSignInForm redirectPath={redirectTarget} />
|
||||
|
||||
@@ -92,7 +92,7 @@ const SignUp = () => {
|
||||
<div className="w-full py-4 grow flex flex-col justify-center items-center">
|
||||
<div className="w-full flex flex-row justify-center items-center mb-6">
|
||||
<img className="h-14 w-auto rounded-full shadow" src={instanceGeneralSetting.customProfile?.logoUrl || "/logo.webp"} alt="" />
|
||||
<p className="ml-2 text-5xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "Memos"}</p>
|
||||
<p className="ml-2 text-4xl text-foreground opacity-80">{instanceGeneralSetting.customProfile?.title || "阿年的备忘录"}</p>
|
||||
</div>
|
||||
{canUsePasswordSignUp ? (
|
||||
<>
|
||||
|
||||
Reference in New Issue
Block a user