From 8b3674215089779d16d3378e400ac9ba1415e5b6 Mon Sep 17 00:00:00 2001 From: Ean Milligan Date: Fri, 24 Apr 2026 14:47:59 -0400 Subject: [PATCH] update xivplan to support export button, try to make it clear db mod is not the same as xivplan for bug reporting --- db-version.patch | 90 ++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 75 insertions(+), 15 deletions(-) diff --git a/db-version.patch b/db-version.patch index d4ce9d7..c604994 100644 --- a/db-version.patch +++ b/db-version.patch @@ -1,8 +1,28 @@ +diff --git a/index.html b/index.html +index 65570da..ff4ae99 100644 +--- a/index.html ++++ b/index.html +@@ -2,10 +2,12 @@ + + + +- FFXIV Raid Planner +- ++ FFXIV Raid Planner + DB ++ + +- + + + diff --git a/src/AboutDialog.tsx b/src/AboutDialog.tsx -index a346146..b4ef320 100644 +index a346146..12c5487 100644 --- a/src/AboutDialog.tsx +++ b/src/AboutDialog.tsx -@@ -30,6 +30,13 @@ export const AboutDialog: React.FC = (props) => { +@@ -30,6 +30,18 @@ export const AboutDialog: React.FC = (props) => { About @@ -12,10 +32,34 @@ index a346146..b4ef320 100644 + very basic database behind it to make more accessible share links. This minimal mod is open + source and can be found{' '} + here. ++

++

++ If you run into any issues regarding saving/loading/signing into the DB mod (basically ++ anything that is on the Online DB part of the Open/Save screens), please email{' '} ++ ean [at] milligan [dot] dev. +

XIVPlan is a tool for quickly diagramming raid strategies for Final Fantasy XIV, inspired by{' '} RaidPlan.io and{' '} +@@ -41,7 +53,8 @@ export const AboutDialog: React.FC = (props) => { +

+ XIVPlan is open source on{' '} + GitHub. If you +- find a bug or have other feedback, please create a{' '} ++ find a bug with XIVPlan itself (excluding anything relating to the Online DB) or have other ++ feedback, please create a{' '} + + new issue + {' '} +@@ -61,7 +74,7 @@ export const AboutDialog: React.FC = (props) => { + + arena background images + {' '} +- by kotarou3 ++ by kotarou3. +

+
+ diff --git a/src/App.tsx b/src/App.tsx index 05a2fb7..f7ed022 100644 --- a/src/App.tsx @@ -133,7 +177,7 @@ index 0000000..81bad97 + return <>Loading plan from DB, please wait . . .; +}; diff --git a/src/SiteHeader.tsx b/src/SiteHeader.tsx -index 524a0d3..8642bd4 100644 +index 524a0d3..695a0f3 100644 --- a/src/SiteHeader.tsx +++ b/src/SiteHeader.tsx @@ -75,7 +75,7 @@ export const SiteHeader: React.FC> = ({ className, . @@ -145,6 +189,15 @@ index 524a0d3..8642bd4 100644 {source && } +@@ -87,7 +87,7 @@ export const SiteHeader: React.FC> = ({ className, . + Help + + +- ++ + GitHub + +
@@ -117,7 +117,10 @@ const SourceIndicator: React.FC = ({ source }) => { return ( @@ -297,10 +350,10 @@ index 63a473b..d32cb53 100644 diff --git a/src/file/FileDialogDB.tsx b/src/file/FileDialogDB.tsx new file mode 100644 -index 0000000..05ea7ce +index 0000000..2e4a31c --- /dev/null +++ b/src/file/FileDialogDB.tsx -@@ -0,0 +1,508 @@ +@@ -0,0 +1,515 @@ +import { + Button, + Checkbox, @@ -533,6 +586,16 @@ index 0000000..05ea7ce + } + }; + ++ const exportAll = (event: MouseEvent) => { ++ event.preventDefault(); ++ const a = document.createElement('a'); ++ a.href = `/api/export/${dbUser?.userId}`; ++ a.download = `${dbUser?.userName}-plans.zip`; ++ document.body.appendChild(a); ++ a.click(); ++ document.body.removeChild(a); ++ }; ++ + const loadPlans = async (userId: string) => { + const newPlans = await getPlans(userId); + @@ -721,17 +784,14 @@ index 0000000..05ea7ce + {renderModal2()} + + -+ } ++ style={{ marginRight: 'auto' }} ++ disabled={!dbUser} ++ onClick={exportAll} + > -+ -+ ++ Export all ++ +