Skip to content

Conversation

@SorinC6
Copy link
Contributor

@SorinC6 SorinC6 commented Dec 3, 2025

  • add skeletons loaders
  • add yoroi test drep id

Note

Unifies governance routing under ROUTES.GOVERNANCE, adds skeleton loaders, and introduces Yoroi Testnet DRep with UI and i18n updates.

  • Governance Routing & Pages
    • Consolidate to ROUTES.GOVERNANCE.{ROOT,OPTIONS}; remove old ROUTES.Governance and GOVERNANCE_REVAMP paths and pages (delegation form, submitted/failed, old selection/revamp).
    • Update navigations, banners, dialogs, analytics, and sidebar to use ROUTES.GOVERNANCE.
  • UI Enhancements
    • Add skeleton loaders: StatusSkeletonScreen, OptionsSkeletonScreen and integrate into status/options screens.
    • Replace old status components with GovernanceStatus and GovernanceStatusCard; refactor options to DRepOptions/DrepOptionsCard with voting record link.
    • Show "Delegating in Governance" state and pending states; tweak card visuals/conditions.
  • Testnet DRep Support
    • Add YOROI_DREP_ID_TESTNET; conditionally use testnet/mainnet DRep ID across governance flows (status card, options, choose DRep modal, banner).
    • Extend constants and i18n (new strings incl. yoroiTestnetDRep, delegatingInGovernance).
  • Misc
    • Clean up navbar (remove gov route reset) and sidebar (remove duplicate/legacy entries).
    • Minor fixes: open Yoroi voting record via onViewDetails; adjust event capture for new route key.

Written by Cursor Bugbot for commit c41eb32. This will update automatically on new commits. Configure here.

Copy link
Contributor Author

@SorinC6 SorinC6 left a comment

Choose a reason for hiding this comment

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

/check

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bug: Unreachable code for primary variant delegated styling

The styled component ActionCardContainer contains unreachable code. The condition if (isCardDelegated && variant === 'primary') at line 204 will never execute because the previous condition if (isCardDelegated) at line 197 already returns when isCardDelegated is true. If the intent was to apply different styling for the primary variant when delegated, this logic is broken and the special primary+delegated styling is never applied.

packages/yoroi-extension/app/UI/features/governace/useCases/GovernanceStatusRevamp/DrepOptionsCard.tsx#L203-L209

if (isCardDelegated && variant === 'primary') {
return {
...base,
background: theme.palette.ds.bg_gradient_2,
};
}

packages/yoroi-extension/app/UI/features/governace/useCases/GovernanceStatusRevamp/DrepOptionsCard.tsx#L196-L202

}
if (isCardDelegated) {
return {
...base,
background: theme.palette.ds.bg_gradient_2,
};
}

Fix in Cursor Fix in Web


Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bug: Sidebar navigation uses non-existent governance route

The sidebar governance entry uses a hardcoded route /governance-status, but the route configuration was changed to define ROUTES.GOVERNANCE.ROOT as /governance. Clicking the governance sidebar link will navigate to a non-existent route since the Routes.js now defines the governance pages under /governance, not /governance-status.

packages/yoroi-extension/app/stores/stateless/sidebarCategories.js#L126-L127

className: 'governance',
route: '/governance-status',

Fix in Cursor Fix in Web


@Nebyt Nebyt added this to the 5.19.0 milestone Dec 3, 2025
Copy link
Contributor Author

@SorinC6 SorinC6 left a comment

Choose a reason for hiding this comment

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

/check

Copy link
Contributor Author

@SorinC6 SorinC6 left a comment

Choose a reason for hiding this comment

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

/check

Copy link
Contributor Author

@SorinC6 SorinC6 left a comment

Choose a reason for hiding this comment

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

/check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants