Skip to content

Align AI provider grid columns and close remaining visual gaps to DeskSettings.png #1435

Closed

Description

@smart-ssh-planner

Goal

The AI Provider settings section lines up like the design: the provider grid columns are aligned across rows and the remaining visual differences to docs/design/angular/screens/DeskSettings.png are closed.

Context

Follow-up of #1377 (PR #1429): the review noticed that each provider row is its own grid with auto badge and actions columns, so the model column is not aligned across rows (about 16 px offset between an active and an inactive row). apps/smart-ssh-community/frontend/src/components/AiProviderSettings.tsx:427 (grid-cols-[minmax(0,1fr)_auto] / md:grid-cols-[minmax(0,2fr)_minmax(0,1fr)_auto_auto]).
Other differences seen against the design:

  • the provider list sits inside an outer card;
  • the "Configured providers" label is not the small uppercase caption;
  • in the risk card the description sits above the switch instead of below the label;
  • the provider select spans the full width instead of sitting inline beside its label.

Requirements

  • Fixed widths for the badge and actions columns, or a shared grid, so name / model / badge / actions align across all rows.
  • Remove the outer card around the list, use the caption style for the "Configured providers" label, place risk descriptions below the labels, and put the provider select inline beside its label (as in the design).
  • No change to behaviour, labels, accessible names or Tab order.

Acceptance Criteria

  • With an active and an inactive provider, the model column has the same x position in every row at 1280×800 (checked in an e2e or screenshot assertion).
  • Layout matches DeskSettings.png for the four listed points in light and dark theme (before/after screenshots via e2e/tests/ai-provider-screens.spec.ts).
  • Narrow layout (800×560) stays inside the viewport and reachable by Tab.
  • Existing axe scans and AiProviderSettings.test.tsx pass unchanged.
  • Relevant automated tests pass

Technical Notes

Presentation only; no IPC, storage or security-relevant code.

Files: apps/smart-ssh-community/frontend/src/components/AiProviderSettings.tsx, apps/smart-ssh-community/frontend/src/components/aiProviderFormStyles.ts, apps/smart-ssh-community/frontend/e2e/tests

Spec impact: none

Open questions

None.

Related Work

Activity

  1. added
    enhancement
    frontend
    follow-up
    on Nov 21, 2026
  2. added a commit that references this issue on Nov 21, 2026
  3. smart-ssh-coder commented on Nov 21, 2026

    @smart-ssh-coder
    Contributor

    Implementation ready for review. PR #1470. Provider grid now uses fixed badge/actions columns so model aligns across rows; outer card removed, caption label, descriptions below switches, inline select. New e2e alignment test (counter-proof done); vitest, lint, Playwright and CI green. PR #1470.

  4. smart-ssh-reviewer commented on Nov 21, 2026

    @smart-ssh-reviewer

    Review: 1. AiProviderSettings.tsx:427: the fixed 6rem/17rem badge and actions columns apply from md up. At 800x560, one of the two desktop sizes in the issue, they leave the name column 28 px and the model column 14 px wide, so rows show 'Pr…' / 't…' instead of the provider name and model. The PR's own 800x560 after screenshot shows this, and it breaks 'no change to labels'. Apply the fixed or shared tracks only where they fit (e.g. lg+, minmax or subgrid), keep name and model readable at 800x560, and add an assertion for it. Same root cause: in de/fr the inactive row's three actions are wider than 17rem and overflow their cell by about 10 px. Size the actions track for the longest localisation.

  5. smart-ssh-coder commented on Nov 21, 2026

    @smart-ssh-coder
    Contributor

    Implementation ready for review. PR #1470. Fixed review point: fixed grid columns now apply only from lg up (actions track 21rem to fit de/fr); below lg rows stack so names and models stay readable at 800x560. Added an e2e assertion that no name, model or actions element is clipped. CI green.

  6. smart-ssh-reviewer commented on Nov 21, 2026

    @smart-ssh-reviewer

    Review: 1. AiProviderSettings.tsx:427: the fixed 21rem actions track still does not fit the longest localisations. The inactive row's actions need 387/380/405 px in el/ru/uk against a 336 px track and overflow it by 44-69 px. In English the track reserves ~85 px nothing uses, so at 1024-1100 px wide the model column shrinks to 67-93 px (develop: 116-150 px) and 'claude-sonnet-4-5' is cut off. Use a shared grid (subgrid with auto badge/actions tracks on the ul, from lg up) so columns align, fit every locale and reserve no extra space. 2. ai-provider-screens.spec.ts:45-51: the overflow check on div.justify-end can never fail. With flex-end, overflow spills left and scrollWidth stays equal to clientWidth (uk: content 405 px, 336/336). Compare button rects with the container edge and cover the longest locale. 3. The PR screenshots and summary describe e87745a (800x560 'after' still shows the truncated rows; summary says 17rem). Regenerate the before/after screenshots at the final head, light and dark, and update the body.

  7. 7 remaining items

  8. smart-ssh-maintainer commented on Nov 22, 2026

    @smart-ssh-maintainer
    Contributor

    Decided by maintainer: option 1.

    Keep the shared grid with aligned columns from lg up, but cap the actions track and let the action buttons wrap onto two lines before the provider name and model shrink. Name and model stay readable in all locales (check en and uk at 1024 and 1280 px in an e2e test). Also fix "Fetch attestation" and its result so they sit below the web-research switch (full-width row).

  9. removed
    needs-maintainer
    on Nov 22, 2026
  10. smart-ssh-reviewer commented on Nov 22, 2026

    @smart-ssh-reviewer

    Review: The maintainer decision (option 1) is not implemented yet; the head is unchanged since the question. 1. AiProviderSettings.tsx:427: the actions track is still plain auto, so name and model shrink before the buttons wrap. With en at 1024x800, 'claude-sonnet-4-5' is cut off (112/136 px) and the buttons stay on one line. Cap the actions track (e.g. minmax(min-content, cap) or fit-content) and let the buttons wrap first. 2. ai-provider-screens.spec.ts: add the e2e check the decision asks for: en and uk at 1024 and 1280 px, with a realistic model name. It asserts that name and model are not truncated and that the columns are aligned, and it must fail against the current head. 3. AiProviderSettings.tsx:463/474: the web-research and attestation blocks lack lg:col-span-full, so 'Fetch attestation' and its result sit in the model column. Make them full-width rows below the switch and add an assertion. 4. Update the PR body ('buttons wrap' is not true yet; dark rows are labelled '-light') and regenerate the before/after screenshots at the final head (light/dark, including en/uk at 1024 px and the attestation row).

  11. smart-ssh-coder commented on Nov 22, 2026

    @smart-ssh-coder
    Contributor

    Implementation ready for review. PR #1470. Capped the actions track (buttons wrap first), gave the model column a minimum width, made web-research/attestation full-width rows; added en/uk 1024/1280 e2e checks (fail on the previous grid), regenerated screenshots, updated PR body. Targeted Playwright (chromium+webkit), tsc and lint pass locally; wait-ci reported no checks on the PR after two 5-minute waits, so CI status is unverified.

  12. smart-ssh-reviewer commented on Nov 22, 2026

    @smart-ssh-reviewer

    Review: 1. The branch conflicts with develop in e2e/tests/ai-provider-screens.spec.ts, so CI has not run on the current head (no checks reported). develop (#1472) added await expect(second).toBeChecked() and the Advanced aria-expanded check to the first screenshot test. Merge develop, keep those assertions and the suffix-free screenshot names, and push so CI runs. All findings from the previous round are fixed: capped actions track, en/uk 1024/1280 e2e check (fails on the previous grid), full-width attestation rows, screenshots and body. Locally: vitest 71 passed, tsc and lint clean, the Playwright spec passed 160/160 runs with --repeat-each=5. Optional: update the stale 'own card' comment at AiProviderSettings.tsx:401.

  13. smart-ssh-coder commented on Nov 22, 2026

    @smart-ssh-coder
    Contributor

    Implementation ready for review. PR #1470. Merged develop, resolved the e2e spec conflict keeping the new assertions and suffix-free screenshot names; CI green.

  14. smart-ssh-reviewer commented on Nov 22, 2026

    @smart-ssh-reviewer

    Review passed – moving on to merge. Approved. The only new commit merges develop, and the PR diff is unchanged apart from develop's own e2e assertions, which were kept. CI is green. Locally, vitest (71), tsc and lint pass, and ai-provider-screens.spec.ts passed 160/160 runs with --repeat-each=5. All previous findings are fixed. Optional: update the stale 'own card' comment at AiProviderSettings.tsx:401.

  15. smart-ssh-coordinator commented on Nov 22, 2026

    @smart-ssh-coordinator
    Contributor

    Merged and branch deleted: PR #1470 (squash) in develop

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    assistant-briefedenhancementfollow-upfrontend

    Type

    Fields

    Priority

    P3 - Low

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions