73 Commits
Author SHA1 Message Date
zeekayandHanzo Dev 334eb9a388 auth: delete the upstream auth; Hanzo IAM is the only gate
The explorer shipped three sign-in systems. Two were Blockscout's and both
spoke to its /account/* backend, which this deployment does not run — measured,
every one of those endpoints 404s on api-explore.lux.network:

  /account/get_csrf 404    /account/send_otp 404     /account/siwe_message 404
  /account/user/info 404   /account/confirm_otp 404  /account/authenticate_via_* 404

So none of it could ever have worked. It is deleted, not re-pointed: the email
+ one-time-code modal, the SIWE wallet login, the CSRF handshake that fired on
every page render, the Dynamic.xyz provider, and the dev page that let you
paste a session cookie by hand. Rewriting any of it against our own backend
would have been building custom auth, which we do not do.

What is left is the standard OIDC client we already had, finished:

  * PKCE (S256). This client is public — it runs in a browser and can hold no
    secret — so the verifier is the only thing binding a redeemed code to the
    page that asked for it. IAM advertises S256 in its discovery document and
    we were not sending a challenge at all.
  * userinfo went to <issuer>/api/userinfo, which is a 404 and an /api/ path we
    do not serve. It is /v1/iam/oauth/userinfo, per IAM's own discovery.
  * logout now ends the IdP session (end_session_endpoint) instead of only
    dropping our cookie and leaving the user signed in upstream.

All three live in lib/oidc.ts, which already said never to rebuild these paths
at a call site.

The header's provider switch collapses to two states — signed in with IAM, or
account disabled and this is the wallet/settings menu. `rewards` is stated off:
its gate read authProvider === 'auth0', so it was already unreachable.

The ConfigMaps carried NEXT_PUBLIC_OIDC_CLIENT_ID=lux-explore-client-id, a
client that has never existed, so authorize answered 400 unknown client_id.
IAM names clients <org>-explore; all four brands now say so, and hanzo/zoo/pars
get the OIDC keys they never had.

Typecheck: no new error classes, production errors 26 -> 22.

Co-authored-by: Hanzo Dev <[email protected]>
2026-08-06 19:18:31 -07:00
zeekayandHanzo Dev 6f80c0ce4e fix(explore): the explorer's own token sheet is the umbrella's
styles/tokens.css was a 494-line FORK of @luxfi/ui/tokens.css, which is how it
drifted its own browns: --color-status-warn #B45309 / #FBBF7A and the whole
Chakra orange + yellow badge ramp (#FEEBCB #FFFAF0 #DD6B20 #FFFFF0 #D69E2E
#FEFCBF #B7791F #C05621 #7B341E #744210 #FAF089). It imports the umbrella now
and adds nothing of its own.

next.config.js hand-listed SEVEN of the engine's 55 packages in
transpilePackages and deduped none of them, which is how this app's store holds
seven physical copies of @hanzogui/popper (3.0.0, 3.0.1, 3.0.2 x3, 7.3.0 x2). A
context published at module scope is per-copy, so PopperAnchor read the empty
default and called refs.setReference on undefined once per tooltip trigger. It
uses withLuxUi now — the one place that wiring lives.

47 files reached for Tailwind's chromatic ramps directly (108 occurrences).
They resolve through tokens now, under short semantic names registered in the
@theme block: text-good / text-bad / text-warn, where warn is ACHROMATIC —
attention in Lux is the loudest neutral, not a hue. The Quasar certificate
tooltip stops naming colours it no longer paints ("BLS (green)", "Corona
(blue)", "ML-DSA (purple)") — copy that describes a palette has to change with
it.

Measured on the rendered pages: warm 0%, tinted-neutral 0.0003%, mean chroma
0.004 (/) and 0.003 (/txs) at 1440x900, 0.000 at 390x844, both modes; zero
uncaught setReference errors.

Two pre-existing defects surfaced because lint-staged now lints these files and
are fixed here rather than skipped: `Box` was used but never imported in
AddressEntity.pw.tsx, and eight lines already exceeded the 160-column limit.

Co-authored-by: Hanzo Dev <[email protected]>
2026-07-27 19:14:51 -07:00
zeekayandHanzo Dev 6d805a016a fix(explore/ui): kill shell overflow, white-on-white values, broken Menu button (v1.1.11)
Three write-once-deploy-4 root causes from the 4-res audit:

1. Horizontal overflow (454px @1280, 38px @1920). The shared layout
   Container forced 'min-w-[100vw] lg:min-w-[fit-content]', promoting the
   whole page to its ~1734px max-content width so stat/block cards clipped
   past the viewport. Make it a fluid column ('w-full min-w-0') and add
   'min-w-0' to MainColumn so the flex chain shrinks and inner
   overflow-x-auto regions scroll internally -> document.scrollWidth ==
   innerWidth at every breakpoint.

2. White-on-white values (block Reward / tx Value / tx Fee /
   network-utilization%). These passed legacy Chakra dot-tokens
   ('text.secondary', 'green.600'...) straight into an inline CSS 'color',
   which browsers drop as invalid -> the text inherited white. Add one
   resolveColorToken() helper (dot-token -> var(--color-*)), apply it in
   SimpleValue (the value chokepoint for Reward/Value/Fee), and point
   getNetworkUtilizationParams at real theme vars (bright badge fg shades,
   all >=4.5:1 on the light card bg).

3. Broken 'Menu' button: the wallet/settings button stacked a 20px icon
   over its label in a bare div inside a 32px overflow-hidden button (the
   '51px in 32px' clip that read as a stray hamburger at lg+). Lay the
   icon+label out horizontally (flex items-center gap-2, sized icon).

Co-authored-by: Hanzo Dev <[email protected]>
2026-07-19 01:24:19 -07:00
zooqueen 436f9522ff fix(oidc): brand-correct sign-in label from OIDC host (hanzo.id on Hanzo build) instead of hard-coded 'Lux ID' 2026-06-23 21:05:45 -07:00
zooqueen d0c277a00f docs(oidc): clarify login redirects to configured OIDC server (hanzo.id for Hanzo build), not hard-coded lux.id 2026-06-23 21:00:13 -07:00
zeekay 3813d03918 feat: explorer FE — stateless SSR, chain selector, localnet, registry cleanup 2026-03-01 18:00:00 -08:00
zeekay 284d506593 feat: OIDC login via lux.id, full-width layout, P-chain stats fix
- Add Sign in button to TopBar with OIDC flow to lux.id
- Merge settings (color theme, identicon, address format) into user menu popover
- Remove duplicate user profile from HeroBanner
- Full-width stacked blocks/transactions layout on homepage
- Fix P-chain stats: CSP connect-src allows base origin for SDK calls
- Fix connected count: infer from uptime when field missing
- Fix dark mode popover background
- Enable OIDC in .env.production (lux.id, client: explore)
2026-03-01 20:34:00 -08:00
zeekay 1affde5938 feat: horizontal blocks layout, stats grid, network overview fallback chains
- LatestBlocks: full-width layout instead of fixed 280px sidebar
- Stats: 4-column grid on desktop, 2-column on mobile
- NetworkOverview: fallback known L1 chains when P-chain API unreachable
- NetworkOverview: expose isError from useCurrentValidators
- P-chain hooks: add retry:2 for resilience
- UserProfile: use address_hash instead of id for display
- Replace middleware.ts with proxy.ts (unused in production Docker)
- Add toolkit/chakra/separator re-export
- tsconfig: jsx react-jsx, formatting cleanup
- dev.sh: disable turbopack (stability)
2026-03-02 10:36:17 -08:00
zeekay ddb1fa2cd9 unify all sql images to :latest (PG18)
Single version policy: ghcr.io/hanzoai/sql:latest everywhere.
No version pinning, no backwards compat, always latest stable.
2026-03-01 21:09:09 -08:00
zeekay 08cddc0fcb brand: remove all Blockscout branding, replace with Lux Explorer
- Gas tracker FAQ: Blockscout → Lux Explorer
- Chain config web3/chains.ts: explorer name → Lux Explorer
- Auth screens: Blockscout account → Lux account
- Contract verification: Blockscout supports → Lux Explorer supports
- API docs: Blockscout core API → Lux Explorer Core API
- Rewards/merits: Blockscout Merits → Lux Explorer Rewards
- Marketplace disclaimer and integration icons
- Address verification: [email protected] → [email protected]
- Chart export filenames: Blockscout chart/stats → Lux Explorer
- OTEL service name: blockscout_frontend → lux_explorer_frontend
- Dev container: blockscout dev → lux explorer dev
2026-02-27 22:17:37 -08:00
zeekay 39897c9458 feat: unify settings and wallet into single user menu
Move settings from standalone TopBar gear icon into the user profile
dropdown. The menu always renders (for settings access) and includes
wallet connect/disconnect when blockchain interaction is enabled.

- Remove Settings component from TopBar
- Integrate SettingsColorTheme, SettingsIdentIcon, SettingsAddressFormat,
  SettingsScamTokens, SettingsLocalTime into UserWalletMenuContent
- UserProfileDesktop always renders (no null fallback)
- UserWalletButton shows profile icon + "Menu" when no wallet connected
- Mobile header also always shows user menu
- Optimize Dockerfile.lux dependency layer
2026-02-25 12:28:17 -08:00
tom goriunovandGitHub 401dc58402 Smart wallet auth (#3220)
* basic login button implementation

* refactoring and add dynamic auth button to the other pages

* connect wallet without authenticating an user

* login and logout user in blockscout account

* refactoring and RPC overrides

* authenticate user with connected wallet

* add ENS to profile button

* override evm chains and fix contract write with waas wallet

* disconnect wallet and fix docker build

* add dynamic imports to components that use web3 wallet packages

* refactor user profile directory

* clean up

* tweaks

* update pw ci script

* fix "connect wallet" button behavior

* handle linking email to profile with dynamic provider

* fix test

* async loading web3 hooks and remove dynamic loading from components that use them

* fix pw tests

* add account navigation in horizontal layout when auth provider is dynamic

* fix address verification modal

* review fixes

* spelling fixes
2026-02-18 19:42:44 +01:00
tom goriunovandGitHub a77568ce0a Refactor navigation icon (#3191)
* move nav icons to separate directory

* remove unnecessary "slim" suffix from some icon names

* fix screenshots
2025-12-19 10:29:29 +01:00
tom goriunovandGitHub 5d337fc555 Migrate from Jest to Vitest (#3173)
* first part of transition

* second part of transition

* remove jest

* bump up node version and playwright version

* update all screenshots because of the new playwright version

* fix tests

* one more screenshot update
2025-12-10 19:21:07 +01:00
tom goriunovandGitHub 932add9d96 Change zero to <0.001 value within different pages (#3150)
* basic components and address page refactoring

* second part of refactoring

* third part of refactoring

* NativeCoinValue component

* more refactoring

* rename TruncatedValue into TruncatedText

* minor fixes

* refactor block details

* fix layout of value and fee in tx table

* update screenshots

* different units for tooltip and stats widget small value fix

* update screenshots

* update tx table screenshot

* fix copy button vertical alignment
2025-12-05 16:04:27 +01:00
Max AlekseenkoandGitHub 487fe0317a Essential dapps (#3026) 2025-10-17 14:58:12 +02:00
tom goriunovandGitHub f0e713b877 Add support for customizing the UI color theme (#2923)
* UI customizations: new features

Fixes #2905

* colors for graphs

* introduce env variable

* colors for topbar, stats, selected state and tabs

* fix build

* fix validator

* refactor link.primary.hover color token

* refactor selected colors

* update styles for switch and fix some color tokens

* change color for selectable controls

* icon color tokens refactoring

* UI customizations: new features

Fixes #2905

* test for common components

* tweaks

* migrate from color-mode-hex cookie to color-theme cookie

* clean up

* update screenshots

* more screenshot updates

* update default color of chart line

* update envs for mega eth
2025-08-19 11:58:05 +02:00
tom goriunovandGitHub 5bf60a5c43 Connect button tooltip positioned in the corner (#2710)
Fixes #2708
2025-05-15 18:24:08 +02:00
tom goriunovandGitHub ecae7062b2 Merge pull request #2700 from blockscout/release/v2-0-1
Release v2.0.1
2025-05-05 09:56:18 +02:00
tom dd7d1808f4 disable tooltips for buttons on mobile 2025-05-02 13:12:20 +02:00
tom goriunovandGitHub fae4990e1f API resource refactoring (#2699)
* add prefix to API resources

* fix pw tests

* refactor config

* remove unnecessary prefixes in resource names

* fixes

* update screenshots
2025-05-01 15:22:38 +02:00
tom baee6d42fa Merge branch 'main' of github.com:blockscout/frontend into release/v2-0-0 2025-04-21 19:47:03 +02:00
tom 647cc2c9b4 remove tooltips inside tooltips 2025-04-21 19:46:49 +02:00
tom goriunovandGitHub f6725649da UI toolkit package (#2691)
* first version of the pack

* single entry point

* add custom components to the package

* move form components to toolkit

* add more utils and hooks to the package

* minor fixes

* add CI workflow

* update readme and package.json

* fix ts

* fix build of env-validator

* fix docker build

* fix icons size

* test fixes

* more test fixes
2025-04-21 19:44:22 +02:00
tom 53e4bab7a9 fix tests 2025-04-18 21:04:21 +02:00
tom 6e04996c86 fix loading state of profile button 2025-04-16 15:38:46 +02:00
tom goriunovandGitHub dff983310a Fix drawer backdrop and filters on address tx tab (#2670)
fix drawer backdrop and filters on address tx tab
2025-04-10 15:57:32 +02:00
tom goriunovandGitHub a943b4fd25 Fixes after migration to Chakra v3 (#2663)
* fixes of mobile layout, popovers and contract verification form

* fix top bar network menu and icon size on profile button

* extend timeout for NameDomains test

* fix token test
2025-04-04 12:54:24 +02:00
tom b51c49018b fix user profile menu opening/closing 2025-03-31 15:38:49 +02:00
tom c45537b706 major update of screenshots 2025-03-26 20:05:25 +01:00
tom 8a066a79bb update input styles 2025-03-20 20:35:07 +01:00
tom 730678be0f styles for icon-button and close-button 2025-03-20 19:25:21 +01:00
tom 10b976d84d close user profile dropdown after click on buttons/link inside it 2025-03-13 19:11:54 +01:00
tom c55dfdcf5b remove old semantic tokens 2025-03-13 15:22:59 +01:00
tom 46a00cedbb fix more ts errors 2025-03-11 16:18:03 +01:00
tom 02c634645e Merge branch 'main' of github.com:blockscout/frontend into chakra-v3 2025-02-18 15:05:52 +01:00
tom goriunovandGitHub 6e85ab5530 UX changes for BS / Merits login (#2541)
* UX changes for BS / Merits login

Fixes #2535

* fix ts

* refetch user balance after unified login

* fixes
2025-02-07 16:03:39 +01:00
tom 923c0978c1 remove LinkInternal and LinkExternal components 2025-01-28 19:03:19 +01:00
tom 871ee0b9bb fix modal behaviour 2025-01-27 10:02:56 +01:00
tom 40667a2d04 add button showcases 2025-01-23 20:28:42 +01:00
tom aef3904deb fix hero banner 2025-01-20 19:51:07 +01:00
tom 80694cf59c fix user wallet menu 2025-01-17 20:26:12 +01:00
tom 30c5945c2a fix MobileHeader component 2025-01-17 13:06:51 +01:00
tom 211bfeda3b refactor UserProfileMenu 2025-01-15 18:57:01 +01:00
tom a0999015c5 dialog styles and AuthModal first step refactoring 2025-01-14 19:52:26 +01:00
tom d79c4d8dd8 horizontal navigation refactoring 2025-01-08 19:06:00 +01:00
tom goriunovandGitHub bd4094ebd1 Bump up Node.js to v22 (#2410)
* Bump up Node.js to v22

Fixes #2404

* update Playwright to v1.49.0

* fix tests

* one more fix

* fix screenshots
2024-11-25 12:43:05 +01:00
tom c2010743aa [skip ci] remove loader text from buttons 2024-11-08 17:26:58 +01:00
tom c386181188 handle reconnecting state of web3wallet 2024-11-08 17:26:58 +01:00
tom goriunovandGitHub 382829d9f7 Support bech32 address standard (#2351)
* create settings context with simple address format toggler

* transform base16 hash to bech32 hash

* add ENV variables

* add snippet to address page

* add redirect for bech32 addresses

* change address format in search

* add provider to tests

* update demo values

* migrate from Buffer to Uint8Array and add tests

* bug fixes and screenshots updates

* review fixes

* roll back changes in env values

* update screenshots
2024-11-04 18:53:59 +01:00