add
This commit is contained in:
parent
5ac265819e
commit
231e736ea4
|
@ -43,6 +43,11 @@ export const RegisterForm = ({ onSubmit, isLoading }: RegisterFormProps) => {
|
|||
<AvatarUploader
|
||||
className="rounded-lg"
|
||||
placeholder="点击上传头像"
|
||||
onChange={(url) => {
|
||||
if (url) {
|
||||
console.log(url);
|
||||
}
|
||||
}}
|
||||
style={{
|
||||
width: `100%`,
|
||||
height: 210,
|
||||
|
|
|
@ -10,3 +10,16 @@ export const defaultModules = {
|
|||
["clean"],
|
||||
],
|
||||
};
|
||||
|
||||
// 如果需要自定义 tooltip
|
||||
const customTooltip = {
|
||||
header: {
|
||||
1: "标题 1",
|
||||
2: "标题 2",
|
||||
3: "标题 3",
|
||||
4: "标题 4",
|
||||
5: "标题 5",
|
||||
6: "标题 6",
|
||||
false: "正文",
|
||||
},
|
||||
};
|
||||
|
|
|
@ -78,7 +78,7 @@ const AvatarUploader: React.FC<AvatarUploaderProps> = ({
|
|||
file?.fileKey
|
||||
);
|
||||
});
|
||||
// await new Promise((resolve) => setTimeout(resolve, 5000)); // 方法1:使用 await 暂停执行
|
||||
// await new Promise((resolve) => setTimeout(resolve,4999)); // 方法1:使用 await 暂停执行
|
||||
// 使用 resolved 的最新值调用 onChange
|
||||
// 强制刷新 Avatar 组件
|
||||
setAvatarKey((prev) => prev + 1); // 修改 key 强制重新挂载
|
||||
|
|
|
@ -48,6 +48,7 @@ export default function PostCommentEditor() {
|
|||
toast.success("发布成功!");
|
||||
setContent("");
|
||||
setFileIds([]); // 重置上传组件状态
|
||||
setSignature("");
|
||||
setUploaderKey(uploaderKey + 1);
|
||||
} catch (error) {
|
||||
toast.error("发布失败,请稍后重试");
|
||||
|
@ -91,7 +92,6 @@ export default function PostCommentEditor() {
|
|||
key={uploaderKey}
|
||||
value={fileIds}
|
||||
onChange={(value) => {
|
||||
console.log("ids", value);
|
||||
setFileIds(value);
|
||||
}}
|
||||
/>
|
||||
|
|
|
@ -98,7 +98,7 @@ export function LetterBasicForm() {
|
|||
<QuillEditor
|
||||
maxLength={10000}
|
||||
placeholder="请输入内容"
|
||||
minRows={16}
|
||||
minRows={6}
|
||||
onChange={(content) =>
|
||||
form.setFieldValue("content", content)
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
border-bottom-left-radius: 8px;
|
||||
border-bottom-right-radius: 8px;
|
||||
border: none;
|
||||
@apply text-base
|
||||
@apply text-base;
|
||||
}
|
||||
|
||||
.ag-custom-dragging-class {
|
||||
|
@ -41,8 +41,6 @@
|
|||
/* 垂直居中 */
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* 滚动条轨道 */
|
||||
::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
|
@ -69,7 +67,9 @@
|
|||
}
|
||||
|
||||
/* 覆盖 Ant Design 的默认样式 raido button左侧的按钮*/
|
||||
.ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled)::before {
|
||||
.ant-radio-button-wrapper-checked:not(
|
||||
.ant-radio-button-wrapper-disabled
|
||||
)::before {
|
||||
background-color: unset !important;
|
||||
}
|
||||
|
||||
|
@ -82,6 +82,38 @@
|
|||
display: none !important;
|
||||
}
|
||||
|
||||
.no-wrap-header .ant-table-thead>tr>th {
|
||||
.no-wrap-header .ant-table-thead > tr > th {
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="1"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="1"]::before {
|
||||
content: "标题 1";
|
||||
}
|
||||
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="2"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="2"]::before {
|
||||
content: "标题 2";
|
||||
}
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="3"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="3"]::before {
|
||||
content: "标题 3";
|
||||
}
|
||||
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="4"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="4"]::before {
|
||||
content: "标题 4";
|
||||
}
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="5"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="5"]::before {
|
||||
content: "标题 5";
|
||||
}
|
||||
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label[data-value="6"]::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item[data-value="6"]::before {
|
||||
content: "标题 6";
|
||||
}
|
||||
/* 针对下拉菜单中的选项 */
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-item:not([data-value])::before,
|
||||
.ql-snow .ql-picker.ql-header .ql-picker-label:not([data-value])::before {
|
||||
content: "正文" !important;
|
||||
}
|
||||
|
|
|
@ -59,6 +59,8 @@ server {
|
|||
|
||||
# 文件上传处理位置
|
||||
location /uploads/ {
|
||||
|
||||
|
||||
# 文件实际存储路径
|
||||
alias /data/uploads/;
|
||||
# 文件传输性能优化
|
||||
|
|
Loading…
Reference in New Issue