From 07154d2a16011e627c09ee79ba2b7957acf16eec Mon Sep 17 00:00:00 2001 From: miloschwartz Date: Fri, 24 Apr 2026 17:07:11 -0700 Subject: [PATCH] add links to view resources on site --- .cursor/rules/Localization.mdc | 5 +++++ .cursor/rules/Nomenclature.mdc | 6 ++++++ messages/en-US.json | 2 ++ src/components/SitesTable.tsx | 20 +++++++++++++++++--- 4 files changed, 30 insertions(+), 3 deletions(-) create mode 100644 .cursor/rules/Localization.mdc create mode 100644 .cursor/rules/Nomenclature.mdc diff --git a/.cursor/rules/Localization.mdc b/.cursor/rules/Localization.mdc new file mode 100644 index 000000000..3014c6177 --- /dev/null +++ b/.cursor/rules/Localization.mdc @@ -0,0 +1,5 @@ +--- +alwaysApply: true +--- + +Always localize strings and use the `t` function to convert keys to strings. Add the keys to the en-us.json file. Never edit the other language files, as en-us.json is the single source of truth. diff --git a/.cursor/rules/Nomenclature.mdc b/.cursor/rules/Nomenclature.mdc new file mode 100644 index 000000000..33c4af797 --- /dev/null +++ b/.cursor/rules/Nomenclature.mdc @@ -0,0 +1,6 @@ +--- +alwaysApply: true +--- + +Proxy resources = public resources +Private resources = client resources diff --git a/messages/en-US.json b/messages/en-US.json index d6a39168d..5a616f07a 100644 --- a/messages/en-US.json +++ b/messages/en-US.json @@ -93,6 +93,8 @@ "siteConfirmCopy": "I have copied the config", "searchSitesProgress": "Search sites...", "siteAdd": "Add Site", + "sitesTableViewPublicResources": "View Public Resources", + "sitesTableViewPrivateResources": "View Private Resources", "siteInstallNewt": "Install Site", "siteInstallNewtDescription": "Install the site connector for your system", "WgConfiguration": "WireGuard Configuration", diff --git a/src/components/SitesTable.tsx b/src/components/SitesTable.tsx index d59244552..45c0d9a0b 100644 --- a/src/components/SitesTable.tsx +++ b/src/components/SitesTable.tsx @@ -239,9 +239,7 @@ export default function SitesTable({ if (originalRow.type == "local") { return -; } - return ( - - ); + return ; } }, { @@ -437,6 +435,22 @@ export default function SitesTable({ {t("viewSettings")} + + + {t("sitesTableViewPublicResources")} + + + + + {t("sitesTableViewPrivateResources")} + + { setSelectedSite(siteRow);