mirror of
https://github.com/drawdb-io/drawdb.git
synced 2025-10-20 10:14:19 +00:00
Change export file name to include title
This commit is contained in:
@@ -113,7 +113,7 @@ export default function ControlPanel({
|
|||||||
const [showEditName, setShowEditName] = useState(false);
|
const [showEditName, setShowEditName] = useState(false);
|
||||||
const [exportData, setExportData] = useState({
|
const [exportData, setExportData] = useState({
|
||||||
data: null,
|
data: null,
|
||||||
filename: `diagram_${new Date().toISOString()}`,
|
filename: `${title}_${new Date().toISOString()}`,
|
||||||
extension: "",
|
extension: "",
|
||||||
});
|
});
|
||||||
const [error, setError] = useState({
|
const [error, setError] = useState({
|
||||||
@@ -1995,7 +1995,7 @@ export default function ControlPanel({
|
|||||||
setExportData(() => ({
|
setExportData(() => ({
|
||||||
data: "",
|
data: "",
|
||||||
extension: "",
|
extension: "",
|
||||||
filename: `diagram_${new Date().toISOString()}`,
|
filename: `${title}_${new Date().toISOString()}`,
|
||||||
}));
|
}));
|
||||||
setError({
|
setError({
|
||||||
type: STATUS.NONE,
|
type: STATUS.NONE,
|
||||||
|
Reference in New Issue
Block a user