Skip to content

feat(mobile): float the bottom nav as a glass capsule with tab labels - #503

Open
yhabib wants to merge 26 commits into
mainfrom
ux/glass-bottom-nav
Open

yhabib wants to merge 26 commits into
mainfrom
ux/glass-bottom-nav

Conversation

@yhabib

@yhabib yhabib commented Oct 15, 2026 •

Copy link
Copy Markdown
Collaborator

Motivation

With #494, the bottom nav fills the home indicator area with an empty 34px band under the icons. A floating capsule, like the iOS 26 tab bar, lets the content use the full screen and matches the Safari 26 toolbar.

Changes

  • Switched the mobile bottom nav to a floating glass capsule, 22px above the screen edge on iPhone (same as the native tab bar) and above the Android gesture bar.
  • Added an opaque lens that slides to the active tab and stretches while it moves, so the active label stays readable over any content. The active icon is filled.
  • Added short tab labels under the icons (common.tabs). The full labels stay as the accessible names.
  • Added --bottom-nav-space for the main padding and for sticky footers that must stay above the capsule.

Screenshots

Before After
The iPhone Home Screen app in light mode with the flat bottom bar The iPhone Home Screen app in light mode with the glass capsule
The iPhone Home Screen app in dark mode with the flat bottom bar The iPhone Home Screen app in dark mode with the glass capsule
Chrome on Android with the flat bottom bar Chrome on Android with the glass capsule above the gesture bar

Prev. #490

@yhabib
yhabib requested a review from a team as a code owner October 15, 2026 07:34
@zeropath-ai

zeropath-ai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

✅ No security or compliance issues detected. Reviewed everything up to ce67bb5.

Security Overview
Detected Code Changes
Change Type Relevant files
Enhancement ► src/governance-app-frontend/src/common/components/MainLayout.tsx
    Use bottom nav space variable and conditional class for hiding bottom nav
► src/governance-app-frontend/src/common/components/navigation/BottomNav.tsx
    Implement bottom nav lens animation and active indicator logic
► src/governance-app-frontend/src/common/components/navigation/NavigationItems.tsx
    Add tabLabel to navigation items
► src/governance-app-frontend/src/common/hooks/useHidesBottomNav.ts
    Add hook to detect routes that hide bottom nav
Enhancement ► src/governance-app-frontend/src/common/components/navigation/NavigationItems.tsx
    Populate tabLabel values for tabs
Enhancement ► a/src/governance-app-frontend/src/common/components/navigation/BottomNav.tsx
    Switch from useMatches to useHidesBottomNav and compute active index; add lens animation state
Enhancement ► src/governance-app-frontend/src/common/components/MainLayout.tsx
    Adjust main content padding bottom based on --bottom-nav-space; apply conditional CSS when bottom nav hidden
Enhancement ► src/governance-app-frontend/src/i18n/en/common.json
    Add "tabs" section with Dashboard, Accounts, Neurons, Vote, Settings

@github-actions

github-actions Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

📊 Build Bundle Stats

The latest build generated the following assets:

dist/index.html                                           5.86 kB │ gzip:   1.66 kB
dist/assets/index-BN32921f.css                          158.59 kB │ gzip:  25.15 kB
dist/assets/icpLedger-Jk7Uyqrl.js                         0.23 kB │ gzip:   0.21 kB
dist/assets/Skeleton-BPY2HEqm.js                          0.44 kB │ gzip:   0.32 kB
dist/assets/webhid-D0yio6wG.js                            0.53 kB │ gzip:   0.32 kB
dist/assets/useTvlValue-Dnf4a0-P.js                       0.60 kB │ gzip:   0.41 kB
dist/assets/nnsDapp-CGyNTmeW.js                           0.68 kB │ gzip:   0.25 kB
dist/assets/SkeletonPageHeader-BQy2vTvd.js                0.76 kB │ gzip:   0.47 kB
dist/assets/PageHeader-jXzaR6sL.js                        0.77 kB │ gzip:   0.45 kB
dist/assets/CertifiedBadge-mi_dNz-a.js                    0.81 kB │ gzip:   0.48 kB
dist/assets/Separator-BsEMeyGB.js                         0.83 kB │ gzip:   0.50 kB
dist/assets/SkeletonStatCard-AMZC5-nT.js                  0.91 kB │ gzip:   0.56 kB
dist/assets/useForecastPeriod-CLcy0Z3x.js                 1.01 kB │ gzip:   0.61 kB
dist/assets/utils-UGRGyr7A.js                             1.02 kB │ gzip:   0.59 kB
dist/assets/useIcpIndex-C9-Z-h0h.js                       1.09 kB │ gzip:   0.64 kB
dist/assets/numbers-C1w_ZDVz.js                           1.15 kB │ gzip:   0.57 kB
dist/assets/routeLoaders-AX7kGFXY.js                      1.19 kB │ gzip:   0.56 kB
dist/assets/rolldown-runtime-DAXXjFlN.js                  1.26 kB │ gzip:   0.70 kB
dist/assets/advancedFeatures-tq_nRmXx.js                  1.50 kB │ gzip:   0.74 kB
dist/assets/events-MO-Yvg9j.js                            1.66 kB │ gzip:   0.86 kB
dist/assets/useLedgerNeuronCall-DKSwvOIL.js               1.89 kB │ gzip:   1.03 kB
dist/assets/errors-C_oENL0S.js                            1.95 kB │ gzip:   0.97 kB
dist/assets/AnimatedNumber-DkJKJjId.js                    1.98 kB │ gzip:   1.12 kB
dist/assets/useCommandPaletteSettings-Bz8ZqdkY.js         2.13 kB │ gzip:   1.06 kB
dist/assets/addressBook-C5hjiJlr.js                       2.14 kB │ gzip:   1.19 kB
dist/assets/useIcpIndexTransactionsPolling-9EVEVAZU.js    2.15 kB │ gzip:   1.15 kB
dist/assets/useGovernanceAppCanister-BCwb9eKy.js          2.41 kB │ gzip:   1.07 kB
dist/assets/useShortcutSettings-Bq-8MD_M.js               2.41 kB │ gzip:   1.19 kB
dist/assets/useAddHotkey-D-gq-mac.js                      2.61 kB │ gzip:   1.34 kB
dist/assets/governance-C-gjfsES.js                        2.99 kB │ gzip:   1.15 kB
dist/assets/useClaimPendingDeviceStakes-Cbbcc_w5.js       3.12 kB │ gzip:   1.43 kB
dist/assets/SkeletonText-8tffKp1E.js                      3.71 kB │ gzip:   1.29 kB
dist/assets/ToggleGroup-D_STrEDD.js                       4.72 kB │ gzip:   1.76 kB
dist/assets/useAccounts-Qhkds-se.js                       4.96 kB │ gzip:   2.21 kB
dist/assets/tickers-CaeDaoZl.js                           6.04 kB │ gzip:   2.65 kB
dist/assets/useNowInSeconds-3UeS561X.js                   7.13 kB │ gzip:   3.04 kB
dist/assets/DeviceActionDetail-CBfGECJ2.js                8.45 kB │ gzip:   3.03 kB
dist/assets/TopicFollowingAccordion-BoKoi_TB.js           8.55 kB │ gzip:   3.41 kB
dist/assets/routes-TMiE_gBj.js                            8.96 kB │ gzip:   3.07 kB
dist/assets/AlertDialog-C5vKR7TV.js                       8.99 kB │ gzip:   3.16 kB
dist/assets/ledgerIdentity-CbGbEww2.js                   10.16 kB │ gzip:   3.70 kB
dist/assets/MutationDialog-DJdx_RiX.js                   11.55 kB │ gzip:   4.00 kB
dist/assets/spamFilter-CZUen83s.js                       11.77 kB │ gzip:   5.02 kB
dist/assets/ResponsiveDialog-pna8mK33.js                 14.56 kB │ gzip:   4.07 kB
dist/assets/_id-COrkRxKy.js                              16.61 kB │ gzip:   5.32 kB
dist/assets/AmountInput-DDKkXqqD.js                      16.85 kB │ gzip:   6.73 kB
dist/assets/_auth-BkakeSPA.js                            22.49 kB │ gzip:   8.30 kB
dist/assets/HideBalancesToggle-CygVRMJE.js               22.99 kB │ gzip:   8.58 kB
dist/assets/vendor-buffer-EX-AqChq.js                    26.95 kB │ gzip:   8.18 kB
dist/assets/accounts-D6hBeK2K.js                         32.02 kB │ gzip:  10.89 kB
dist/assets/SendICPButton-FmGVckfS.js                    37.05 kB │ gzip:  13.52 kB
dist/assets/settings-2_ObabkW.js                         54.37 kB │ gzip:  15.53 kB
dist/assets/dashboard-BkMMmWqJ.js                        55.83 kB │ gzip:  18.13 kB
dist/assets/index-Ct34-0Vm.js                            65.09 kB │ gzip:  18.64 kB
dist/assets/voting-B_Rga-T7.js                           69.24 kB │ gzip:  21.67 kB
dist/assets/vendor-md-BFlttn4C.js                        73.29 kB │ gzip:  19.98 kB
dist/assets/button-Ce3LXOiT.js                           84.75 kB │ gzip:  28.33 kB
dist/assets/neurons-UyRYPXEQ.js                          90.41 kB │ gzip:  27.08 kB
dist/assets/DisburseModal-B411PAWh.js                   101.46 kB │ gzip:  29.62 kB
dist/assets/vendor-tanstack-B8Ai_FW1.js                 120.02 kB │ gzip:  39.22 kB
dist/assets/vendor-jsqr-CjiBYtfG.js                     129.98 kB │ gzip:  47.50 kB
dist/assets/vendor-core-react-bRRjyX41.js               189.81 kB │ gzip:  59.76 kB
dist/assets/vendor-recharts-CWUgUTjK.js                 280.25 kB │ gzip:  76.83 kB
dist/assets/vendor-ledger-Bz6feAP8.js                   403.26 kB │ gzip:  98.84 kB
dist/assets/vendor-icp-e5O_ocwA.js                      468.31 kB │ gzip: 117.84 kB
dist/assets/vendor-libs-WVao-pYB.js                     581.20 kB │ gzip: 187.04 kB

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The new active-tab labels have insufficient contrast in dark mode.

1 open finding
What changed in this PR

Replaces the mobile bottom bar with a floating glass capsule, building on #494’s safe-area support.

Changes:

  • Adds short tab labels while preserving full accessible names.
  • Introduces translucent styling and a fade behind the capsule.
  • Reserves content space using shared navigation dimensions.
File Description
src/​governance-app-frontend/​src/​i18n/​en/​common.json Adds short tab translations.
src/​governance-app-frontend/​src/​common/​components/​navigation/​NavigationItems.tsx Defines tab-label keys.
src/​governance-app-frontend/​src/​common/​components/​navigation/​BottomNav.tsx Implements the floating capsule and labels.
src/​governance-app-frontend/​src/​common/​components/​MainLayout.tsx Positions navigation and reserves content clearance.
src/​governance-app-frontend/​src/​app/​styles/​main.css Defines navigation height, gap, and clearance variables.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@yhabib
yhabib changed the base branch from fix/bottom-nav-safe-area to ux/proposal-jump-to-vote October 15, 2026 07:44
@yhabib
yhabib requested a balanced review from Copilot October 15, 2026 07:44

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The proposal’s sticky voting footer needs an updated bottom inset to avoid overlapping the floating navigation.

1 open finding
1 resolved since last review

🧠 Review effort: Balanced

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

The iOS-specific viewport and overlay adjustments need on-device validation before approval.

0 open findings

1 resolved since last review

🧠 Review effort: Balanced

Add a "Vote" badge link to the header badge row. It scrolls smoothly to
the voting card and moves the focus to it.

Below the lg breakpoint, show a sticky "Vote" button above the bottom
navigation. Hide it when the voting card is in view or above it.

Show both only when the user can vote on the proposal.
…card

Replace the jump link and the sticky jump button with a sticky footer.
The Yes/No buttons float at the bottom of the page while the voting
card is below it, and dock under the card when the user reaches it.

Show the footer only when the user can vote. Keep the "Vote cast"
footer inside the card.
…cked footer

Recreate the observer when the size of main changes, so the docked
state follows the bottom padding at each breakpoint.

Draw the footer outline with inset shadows. A transparent top border
left a 1px notch in the side borders where the footer joins the card.
@yhabib
yhabib force-pushed the ux/proposal-jump-to-vote branch from 43d7023 to af3e4b1 Compare October 15, 2026 09:42
The mobile bottom nav is now a floating capsule, like the iOS 26 tab bar.
The content scrolls behind it to the screen edge.
Each tab shows a short label under its icon.
@yhabib
yhabib force-pushed the ux/glass-bottom-nav branch from 200dd2c to 33ef912 Compare October 15, 2026 09:43
… nav

A neutral lens now marks the active tab. It slides to the next tab and
stretches while it moves. The active icon is filled. The capsule glass is
clearer, and the content behind and below it is blurred, not faded.
Copilot AI previously approved these changes Oct 15, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

No unresolved issues remain in the reviewed changes, and prior feedback has been addressed or clarified.

0 open findings

🧠 Review effort: Balanced

…e effect

The content below the capsule now fades into the page, with a light 2px
blur. The strong 6px blur made the text under the capsule look like a
smudge.
@yhabib
yhabib requested a balanced review from Copilot October 16, 2026 23:42
Copilot AI dismissed their stale review, a newer Copilot review was requested October 16, 2026 23:42
Copilot AI previously approved these changes Oct 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

The scoped navigation changes have no unresolved blocking findings, and prior feedback has been addressed or clarified.

No open issues 🎉

Review effort: Balanced

# Conflicts:
#	src/governance-app-frontend/src/common/components/navigation/BottomNav.tsx
Copilot AI balanced review requested due to automatic review settings November 5, 2026 10:43
Copilot AI dismissed their stale review, a newer Copilot review was requested November 5, 2026 10:43
Copilot AI previously approved these changes Nov 5, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

The review reports no active issues with the floating mobile navigation update.

No open issues 🎉

Review effort: Balanced

Copilot AI balanced review requested due to automatic review settings November 5, 2026 10:55
Copilot AI dismissed their stale review, a newer Copilot review was requested November 5, 2026 10:55
Copilot AI previously approved these changes Nov 5, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

No active review issues are reported for the floating mobile navigation changes.

No open issues 🎉

Review effort: Balanced

Copilot AI balanced review requested due to automatic review settings November 5, 2026 11:17
Copilot AI dismissed their stale review, a newer Copilot review was requested November 5, 2026 11:17
Copilot AI previously approved these changes Nov 5, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

The floating mobile navigation update has no active review issues.

No open issues 🎉

Review effort: Balanced

@yhabib
yhabib force-pushed the ux/proposal-jump-to-vote branch from de30fdc to 300126e Compare November 5, 2026 15:39
Base automatically changed from ux/proposal-jump-to-vote to main November 5, 2026 15:57
# Conflicts:
#	src/governance-app-frontend/src/common/components/navigation/BottomNav.tsx
@yhabib
yhabib requested a balanced review from Copilot November 5, 2026 16:28
Copilot AI dismissed their stale review, a newer Copilot review was requested November 5, 2026 16:28

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approved

No active review issues are identified for the floating mobile navigation update.

No open issues 🎉

Review effort: Balanced

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.

2 participants