Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions govtool/frontend/src/consts/navItems.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const NAV_ITEMS: Array<NavItem | NavMenuItem> = [
},
{
dataTestId: "governance-actions",
label: i18n.t("govActions.title"),
label: i18n.t("govActions.categoryTitle"),
childNavItems: [
{
dataTestId: "proposed-governance-actions-link",
Expand All @@ -56,7 +56,7 @@ export const NAV_ITEMS: Array<NavItem | NavMenuItem> = [
{
dataTestId: "governance-actions-link",
navTo: PATHS.governanceActions,
label: i18n.t("govActions.navTitle"),
label: i18n.t("govActions.title"),
newTabLink: null,
},
{
Expand Down Expand Up @@ -108,7 +108,7 @@ export const CONNECTED_NAV_ITEMS = [
},
{
dataTestId: "governance-actions-link",
label: i18n.t("govActions.title"),
label: i18n.t("govActions.categoryTitle"),
navTo: PATHS.dashboardGovernanceActions,
activeIcon: ICONS.governanceActionsActiveIcon,
icon: ICONS.governanceActionsIcon,
Expand Down Expand Up @@ -139,7 +139,7 @@ export const CONNECTED_NAV_ITEMS = [
{
dataTestId: "governance-actions-live-voting-link",
label: i18n.t("govActions.liveVoting.title"),
navTo: OUTCOMES_PATHS.governanceActionsLiveVoting,
navTo: PATHS.dashboardGovernanceActions,
activeIcon: ICONS.governanceActionsActiveIcon,
icon: ICONS.governanceActionsIcon,
newTabLink: null,
Expand Down
1 change: 0 additions & 1 deletion govtool/frontend/src/consts/paths.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,4 @@ export const USER_PATHS = {
export const OUTCOMES_PATHS = {
governanceActionsOutcomes: "/outcomes",
governanceActionOutcomes: "/outcomes/governance_actions/:id",
governanceActionsLiveVoting: "/connected/governance_actions",
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed that since it a duplicate of other path.
image

};
4 changes: 2 additions & 2 deletions govtool/frontend/src/i18n/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -489,8 +489,8 @@
"submittedDateWithEpoch": "Submitted: <0>{{date}}</0> <1>(Epoch {{epoch}})</1>",
"supportingLinks": "Supporting links",
"threshold": "Ratification Threshold",
"title": "Governance Actions",
"navTitle": "Live Voting",
"categoryTitle": "Governance Actions",
"title": "Live Voting",
"toVote": "To vote",
"viewDetails": "View Details",
"viewDetailsAndVote": "View Details and Vote",
Expand Down
5 changes: 5 additions & 0 deletions govtool/frontend/src/pages/Dashboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,11 @@ export const Dashboard = () => {

return proposalDiscussionNavItem ?? "";
}

if (path.startsWith(PATHS.dashboardGovernanceActions)) {
return t("govActions.title");
}

return findNavItem(CONNECTED_NAV_ITEMS, path) ?? "";
};

Expand Down