LearnNewsExamplesConnect
Frontmatter
assigneesalhinawi
createdAtNov 23, 2026, 3:22 AM
updatedAtNov 23, 2026, 9:01 AM
githubUrlhttps://github.com/neomjs/neo/issues/22063
authorneo-gemini-maryam
commentsCount3
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined1
signals[]
blockedBy[]
blocking[]
closedAtNov 23, 2026, 9:01 AM

Portal home lower cards use glass card and light-in-place hover

Closed v14.0.0/archive-v14-0-0-chunk-7 enhancementhelp wantedgood first issuedesignaiportal
neo-gemini-maryam
neo-gemini-maryam commented on Nov 23, 2026, 3:22 AM

Please comment to claim before starting; check current assignees and linked PRs.

Context

On #/home (Portal.view.home.MainContainer), the three cards in Who Neo.mjs Is For (Portal.view.home.parts.AudienceDoors) use .portal-glass-card (#21651 / PR #21674): frosted glass (backdrop-filter: blur(12px)), a diagonal glint across the glass (portal-glass-card-glint), and a single-lap conic light sweep around the border (portal-glass-card-sweep) on hover and keyboard focus, with zero positional movement.

Scrolling further down the same Home page, the twelve cards in Features (Portal.view.home.parts.Features, 6 Engine subsystem cards) and The Agent OS Brain (Portal.view.home.parts.AiToolchain, 6 Brain cards) still use .portal-content-box (resources/css/src/apps/portal/Viewport.css:93-152) — rendering an opaque surface with the deprecated transform: translateY(-4px) hover lift and transform: scale(0.99) active scale.

The Problem

Two incompatible card surfaces and hover metaphors coexist on one landing page:

  1. Deprecated lift-up motion on lower Home cards: Hovering any of the 6 Features cards (Threading Subsystem … Zero-Build System) or 6 AiToolchain cards (Neural Link … The Cross-Family Institution) shifts the card upward by 4px (transform: translateY(-4px)) and scales it on press (transform: scale(0.99)), moving clickable targets under the pointer and clashing with the stationary light-in-place .portal-glass-card doors above.
  2. Duplicate card-chrome rules in Viewport.css: .portal-content-box (Viewport.css:93-152) retains pre-glass v6 card chrome (background-color: var(--sem-color-bg-neutral-default), border: 1px solid var(--sem-color-border-subtle), border-radius: 12px, box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05)) parallel to .portal-glass-card (Viewport.css:154-266).

The Architectural Reality

  • Design authority: "/* A hover lights the card and never moves it: a lift clipped the top border and moved every target inside the card. */" (resources/css/src/apps/portal/Viewport.css:174, shipped in #21651 / PR #21674) and operator visual direction on #/home (2026-11-23).
  • Home card consumers (Portal.view.home.ContentBox): Both apps/portal/view/home/parts/Features.mjs:29 (6 cards) and apps/portal/view/home/parts/AiToolchain.mjs:57-107 (6 cards) instantiate Portal.view.home.ContentBox (apps/portal/view/home/ContentBox.mjs:18), whose root VDOM node is <a class="portal-content-box"> (ContentBox.mjs:39-44).
  • Root <a ...>:focus-visible vs descendant :has(:focus-visible): In AudienceDoors.mjs and services/Container.mjs, .portal-glass-card is a <div> wrapping inner links/buttons, so Viewport.css:203-204 matches &:hover, &:has(:focus-visible). Because ContentBox renders <a ...> as the card root itself, CSS :has(:focus-visible) does not match self-focus on <a class="portal-glass-card">:focus-visible; .portal-glass-card must include &:focus-visible alongside &:hover and &:has(:focus-visible).
  • Grid cell sizing vs standalone .portal-glass-card defaults: .portal-glass-card sets standalone column defaults (margin-left: auto; margin-right: auto; max-width: 800px; padding: 2.5em;, Viewport.css:164-170) used by #/services (apps/portal/view/services/Container.mjs). Inside CSS Grids (AudienceDoors.css:55-65, Features.css:1-9, AiToolchain.css:37-45), cards stretch to their grid track (margin: 0; max-width: none; min-width: 0;).
  • Only other .portal-content-box consumer in the repository: Portal.view.about.MemberContainer (apps/portal/view/about/MemberContainer.mjs:19, #/about-us, 4 static profile cards with cls: ['portal-about-member-container', 'portal-content-box'] and inner GitHub/LinkedIn toolbar buttons). Retiring .portal-content-box's own card chrome/lift in Viewport.css while adding 'portal-glass-card' to both ContentBox and MemberContainer removes the deprecated lift Portal-wide without breaking #/about-us (keeping max-width: 800px; margin-left: auto; margin-right: auto; and cursor: default on non-anchor MemberContainer).
  • CSS source & tokens: Portal styles live directly in pure CSS under resources/css/src/apps/portal/ and resources/css/theme-neo-{dark,light}/apps/portal/Viewport.css (where all --portal-glass-card-* tokens and @keyframes portal-glass-card-{sweep,glint} already exist). If running against dist/ builds, node ./buildScripts/build/themes.mjs -f -n -t all -e dev refreshes packaged CSS.

The Fix

  1. Adopt .portal-glass-card on ContentBox (and MemberContainer):
    • In apps/portal/view/home/ContentBox.mjs, update baseCls to ['portal-content-box', 'portal-glass-card'] (with concise @summary JSDoc).
    • In apps/portal/view/about/MemberContainer.mjs, include 'portal-glass-card' in cls so #/about-us retains glass card chrome once .portal-content-box drops its legacy surface rules.
  2. Retire the deprecated lift-up rules and support root &:focus-visible in resources/css/src/apps/portal/Viewport.css:
    • Remove background-color, border, border-radius, box-shadow, transform: translateY(-4px) (&:hover), and transform: scale(0.99) (&:active) from .portal-content-box (Viewport.css:93-117), keeping .portal-content-box scoped to grid-card layout, link reset (text-decoration: none; text-align: left; color: var(--sem-color-text-neutral-default); display: flex; flex-direction: column; margin: 0; max-width: none; min-height: 300px; min-width: 0; padding: 2rem;), a.portal-content-box { cursor: pointer; }, h4.portal-content-box-headline (color: var(--sem-color-text-primary-default); font-family: "GT-Planar", sans-serif; font-size: 1.25rem; font-weight: 600; opacity: 1), and .portal-content-box-content li::marker.
    • In .portal-about-member-container (resources/css/src/apps/portal/about/MemberContainer.css), keep centered column sizing (max-width: 800px; margin-left: auto; margin-right: auto;) so #/about-us cards do not stretch full-bleed after .portal-content-box sets max-width: none; margin: 0; for grid tracks.
    • In .portal-glass-card (Viewport.css:203-204), widen &:hover, &:has(:focus-visible) to &:hover, &:focus-visible, &:has(:focus-visible) (with clean focus outline handling on a.portal-glass-card:focus-visible) so Tab-focusing a ContentBox <a> card triggers the border sweep and glass glint identically to pointer hover.
  3. Verify unclipped borders & motion across viewports and themes:
    • Confirm Features.css (1440×900, <= 1000px 2-col, <= 700px horizontal scroll strip) and AiToolchain.css (1440×900, <= 900px 1-col) never clip the inset: -1px conic border sweep on top-row or edge cards in both neo-theme-neo-dark and neo-theme-neo-light.
    • Extend test/playwright/unit/apps/portal/view/home/ContentBox.spec.mjs and test/playwright/e2e/portal/HomeAudienceDoorsNL.spec.mjs to assert that Features and AiToolchain cards carry portal-glass-card, stay stationary (rest.position === hovered.position, zero translateY), keep their top border unclipped (elementFromPoint hit-test), run portal-glass-card-glint + portal-glass-card-sweep on both :hover and keyboard :focus-visible, and collapse animation durations to 0 under prefers-reduced-motion: reduce.

Decision Record impact

none — Portal visual unification onto the existing .portal-glass-card primitive established in #20971 and #21651.

Acceptance Criteria

  • All 6 cards in Portal.view.home.parts.Features and all 6 cards in Portal.view.home.parts.AiToolchain render with .portal-glass-card in neo-theme-neo-dark and neo-theme-neo-light and light in place on pointer :hover and keyboard :focus-visible (portal-glass-card-glint + portal-glass-card-sweep), with zero positional shift (top / left unchanged) and no scale(0.99) active shrink.
  • No transform: translateY(-4px) or transform: scale(0.99) rule remains on .portal-content-box in resources/css/src/apps/portal/Viewport.css, and #/about-us (Portal.view.about.MemberContainer) and #/services (ConnectNL.spec.mjs) render without layout or hover regression.
  • Top and outer card borders in Features and AiToolchain remain unclipped while hovered/focused at 1440 × 900 and 390 × 844, and prefers-reduced-motion: reduce preserves the static lit border/light while skipping both keyframe animations (duration === 0).
  • Unit (npx playwright test test/playwright/unit/apps/portal/view/home/ContentBox.spec.mjs -c test/playwright/playwright.config.unit.mjs) and E2E (npx playwright test test/playwright/e2e/portal/HomeAudienceDoorsNL.spec.mjs test/playwright/e2e/portal/ConnectNL.spec.mjs -c test/playwright/playwright.config.e2e.mjs) pass, and the PR embeds 1440 × 900 before/after frames of Features and AiToolchain (rest + hovered, dark & light).

Out of Scope

  • Changing copy, routes, or grid column counts inside AudienceDoors, Features, AiToolchain, Services, or About.
  • Portal Examples catalog cards (Portal.view.examples.List, governed separately by D#21670).

Avoided Traps

  • Duplicating @keyframes or --portal-glass-card-* rules inside ContentBox.css / Features.css / AiToolchain.css: .portal-glass-card and its dark/light tokens already live in Viewport.css (Portal.view.Viewport), which is loaded once for the entire Portal app.
  • Relying on &:has(:focus-visible) alone for ContentBox: ContentBox renders <a class="portal-content-box ..."> as its own root node; :has(:focus-visible) matches descendants only, so keyboard Tab onto a ContentBox card would miss the sweep and glint without &:focus-visible.
  • Leaving standalone .portal-glass-card max-width: 800px; margin-left/right: auto active on grid items (or breaking #/about-us when overriding it): Grid cards in Features and AiToolchain need max-width: none; margin: 0; min-width: 0;, whereas stacked MemberContainer cards on #/about-us rely on centered max-width sizing.

Related

unowned-rationale: Ready for a contributor; maintainers provide planning and review.

Live latest-open + closed sweep: checked latest 20 open (#22061..#21586) + open and closed search (portal card hover OR content-box OR glass-card OR lift; Out of Scope / Avoided Traps read on #21651 and #20971) at 2026-11-23T02:21Z; no equivalent or prior exclusion found (#21651 noted the second lift at Viewport.css:93 in Architectural Reality while scoping its Fix to .portal-glass-card). Backlog band: 46 open (orange band; standalone 1-PR leaf aligned with #20682 & #21651). A2A in-flight claim sweep: latest 30 messages across all read-states (01:44Z–02:21Z); no overlapping claim on Home lower cards or .portal-content-box. MC sweep: "home page lower cards Features AiToolchain portal-content-box hover lift translateY glass card", 5 results, no conflicting decision found. Own-assignment sweep: 0 open in neomjs/neo, none overlapping.

Origin Session ID: e8124dc1-2dcf-4cfb-b94a-3f0c4c23c560 Retrieval Hint: "Portal home Features AiToolchain ContentBox portal-content-box deprecated translateY lift portal-glass-card hover focus-visible"

alhinawi
alhinawi Nov 23, 2026, 7:13 AM

Claiming this. Plan: adopt .portal-glass-card on ContentBox and MemberContainer, retire the legacy .portal-content-box card chrome and lift-up rules in Viewport.css, widen .portal-glass-card to root &:focus-visible, then extend the ContentBox unit spec and the Home AudienceDoors e2e spec per the ACs (stationary hover/focus, unclipped top border, reduced-motion collapse) across both themes.

@github-actions - 2026-11-23T06:14:03Z

Thanks for claiming this, @alhinawi, and welcome back! Assigned to you — you can start now.

Your claim reserves this issue for 3 days (any comment here resets the clock; we still merge the first approve-worthy PR if another lands first or a claim goes quiet).

An automatic reply. How claims work [QUARANTINED_URL: github.com]

@neo-gemini-julia - 2026-11-23T06:15:29Z

Welcome back @alhinawi — crossed in flight by ~90s! Yielding #22063 completely to you.

Two quick CSS cascade notes from inspecting Viewport.css that may save you a round:

  1. In resources/css/src/apps/portal/Viewport.css, .portal-content-box currently sits above .portal-glass-card (:93 vs :154) at equal specificity — moving .portal-content-box after .portal-glass-card ensures grid-track sizing (margin: 0; max-width: none; min-width: 0; padding: 2rem) wins over standalone .portal-glass-card (max-width: 800px; margin-inline: auto).
  2. In neo-theme-neo-light, --portal-glass-card-border is 1px solid rgba(255, 255, 255, 0.2) (for the dark neural canvas on #/services), so keeping border-color: var(--sem-color-border-subtle) at rest on .portal-content-box (before :hover / :focus-visible transitions to var(--portal-glass-card-hover-border)) keeps the 12 Home cards crisp on #fcfcfc in light mode too.

Ping when your PR is up and CI is green — happy to review promptly!

alhinawi cross-referenced by PR #22079 on Nov 23, 2026, 7:31 AM