mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
chore: update common dialog default color
This commit is contained in:
@ -22,7 +22,7 @@ const ArchivedMemo: React.FC<Props> = (props: Props) => {
|
||||
showCommonDialog({
|
||||
title: t("memo.delete-memo"),
|
||||
content: t("memo.delete-confirm"),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "delete-memo-dialog",
|
||||
onConfirm: async () => {
|
||||
await memoStore.deleteMemoById(memo.id);
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { Button } from "@mui/joy";
|
||||
import { useEffect, useState } from "react";
|
||||
import { toast } from "react-hot-toast";
|
||||
import { getNormalizedTimeString, getUnixTime } from "@/helpers/datetime";
|
||||
@ -69,10 +70,6 @@ const ChangeMemoCreatedTsDialog: React.FC<Props> = (props: Props) => {
|
||||
</button>
|
||||
</div>
|
||||
<div className="flex flex-col justify-start items-start !w-72 max-w-full">
|
||||
<div className="w-full bg-yellow-100 border border-yellow-400 rounded p-2 text-black">
|
||||
<p className="uppercase">{t("message.change-memo-created-time-warning-1")}</p>
|
||||
<p>{t("message.change-memo-created-time-warning-2")}</p>
|
||||
</div>
|
||||
<input
|
||||
className="input-text mt-2"
|
||||
type="datetime-local"
|
||||
@ -80,13 +77,13 @@ const ChangeMemoCreatedTsDialog: React.FC<Props> = (props: Props) => {
|
||||
max={maxDatetimeValue}
|
||||
onChange={handleDatetimeInputChange}
|
||||
/>
|
||||
<div className="flex flex-row justify-end items-center mt-2 w-full">
|
||||
<span className="btn-text" onClick={handleCloseBtnClick}>
|
||||
<div className="flex flex-row justify-end items-center mt-4 w-full gap-x-2">
|
||||
<Button color="neutral" variant="plain" onClick={handleCloseBtnClick}>
|
||||
{t("common.cancel")}
|
||||
</span>
|
||||
<span className="btn-primary" onClick={handleSaveBtnClick}>
|
||||
</Button>
|
||||
<Button color="primary" onClick={handleSaveBtnClick}>
|
||||
{t("common.save")}
|
||||
</span>
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
|
@ -149,7 +149,7 @@ const Memo: React.FC<Props> = (props: Props) => {
|
||||
showCommonDialog({
|
||||
title: t("memo.delete-memo"),
|
||||
content: t("memo.delete-confirm"),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "delete-memo-dialog",
|
||||
onConfirm: async () => {
|
||||
await memoStore.deleteMemoById(memo.id);
|
||||
|
@ -78,7 +78,7 @@ const PreferencesSection = () => {
|
||||
showCommonDialog({
|
||||
title: t("setting.member-section.archive-member"),
|
||||
content: t("setting.member-section.archive-warning", { username: user.username }),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "archive-user-dialog",
|
||||
onConfirm: async () => {
|
||||
await userStore.patchUser({
|
||||
@ -102,7 +102,7 @@ const PreferencesSection = () => {
|
||||
showCommonDialog({
|
||||
title: t("setting.member-section.delete-member"),
|
||||
content: t("setting.member-section.delete-warning", { username: user.username }),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "delete-user-dialog",
|
||||
onConfirm: async () => {
|
||||
await userStore.deleteUser({
|
||||
|
@ -41,7 +41,7 @@ const SSOSection = () => {
|
||||
showCommonDialog({
|
||||
title: t("setting.sso-section.delete-sso"),
|
||||
content: content,
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "delete-identity-provider-dialog",
|
||||
onConfirm: async () => {
|
||||
try {
|
||||
|
@ -40,7 +40,7 @@ const StorageSection = () => {
|
||||
showCommonDialog({
|
||||
title: t("setting.storage-section.delete-storage"),
|
||||
content: t("setting.storage-section.warning-text", { name: storage.name }),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "delete-storage-dialog",
|
||||
onConfirm: async () => {
|
||||
try {
|
||||
|
@ -88,7 +88,7 @@ const SystemSection = () => {
|
||||
showCommonDialog({
|
||||
title: t("setting.system-section.enable-password-login"),
|
||||
content: t("setting.system-section.enable-password-login-warning"),
|
||||
style: "warning",
|
||||
style: "danger",
|
||||
dialogName: "enable-password-login-dialog",
|
||||
onConfirm: async () => {
|
||||
setState({ ...state, disablePasswordLogin: value });
|
||||
|
@ -334,8 +334,6 @@
|
||||
"memo-updated-datetime": "Memo created datetime changed.",
|
||||
"invalid-created-datetime": "Invalid created datetime.",
|
||||
"change-memo-created-time": "Change memo created time",
|
||||
"change-memo-created-time-warning-1": "THIS IS NOT A NORMAL BEHAVIOR.",
|
||||
"change-memo-created-time-warning-2": "Please make sure you really need it.",
|
||||
"memo-not-found": "Memo not found.",
|
||||
"fill-all": "Please fill in all fields.",
|
||||
"password-not-match": "Passwords do not match.",
|
||||
|
Reference in New Issue
Block a user