Skip to content

fix(mobile-api): align settings page chrome with standard admin settings#195

Closed
fabiodalez-dev wants to merge 1 commit into
mainfrom
fix/mobile-api-settings-ui-consistency
Closed

fix(mobile-api): align settings page chrome with standard admin settings#195
fabiodalez-dev wants to merge 1 commit into
mainfrom
fix/mobile-api-settings-ui-consistency

Conversation

@fabiodalez-dev

@fabiodalez-dev fabiodalez-dev commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Problema

La pagina impostazioni del plugin Mobile API (/admin/plugins/{id}/settings) era l'unico settings full-page a divergere dal resto dell'admin: header sticky con icona a gradiente indigo→purple e accenti indigo/purple ovunque, invece del chrome canonico usato da /admin/settings e dagli altri plugin settings (api-book-scraper, discogs).

Soluzione

Un solo file — storage/plugins/mobile-api/views/settings.php — allineato al pattern canonico:

  • Header: rimossa la sticky bar + l'icona a gradiente; ora <h1 class="text-3xl font-bold text-gray-900"> con icona piatta fas fa-mobile-screen-button text-blue-600 e back link .btn-secondary, dentro max-w-4xl mx-auto.
  • Accenti: tutti gli indigo-*blue-* (tab, toggle, box "API attiva", select, focus ring). Zero gradient/indigo/purple residui.
  • Bottone salva.btn-primary (identico al "Salva" del Centro Impostazioni); banner success/error → stile canonico px-4 py-3 rounded-lg.

Verifica

Login reale su Apache :8081 + screenshot comparativo con /admin/settings: header, card bianche, bottone scuro .btn-primary e accenti blu ora combaciano. php -l ok, pre-commit (PHPStan L5 + escaping) verde.

Audit di coerenza

Gli altri settings full-page (api-book-scraper, discogs) erano già canonici. goodlib è renderizzato in un modal (renderSettingsHtml(), non getSettingsViewPath()) quindi non ha — né deve avere — un header di pagina: non è un outlier.

Summary by CodeRabbit

  • Style
    • Aggiornata l’interfaccia delle impostazioni Mobile API con layout più compatto e spaziature riviste.
    • Migliorati i messaggi di stato, le schede di navigazione e i controlli del form con uno stile coerente.
    • Rinfrescata la palette visiva con toni blu al posto dei precedenti colori viola/indaco.
    • Uniformato il pulsante di salvataggio e l’aspetto delle sezioni relative all’accesso app mobile e alle notifiche push.

…ettings

The Mobile API plugin settings page diverged from every other settings
page: a sticky header bar with an indigo→purple gradient icon box and
indigo/purple accents throughout, instead of the canonical admin chrome
(plain text-3xl heading + flat blue icon, blue accents, .btn-primary).

Now it matches /admin/settings and the sibling plugin settings pages
(api-book-scraper, discogs):
- header: drop the sticky bar + gradient icon, use the text-3xl heading
  with a flat fa-mobile-screen-button text-blue-600 icon and a
  .btn-secondary "Plugin" back link
- recolor every indigo-* accent to blue-* (tabs, toggle, info box,
  selects, focus rings)
- save button → .btn-primary; success/error banners → the canonical
  px-4 py-3 rounded-lg green/red style
@coderabbitai

coderabbitai Bot commented Jun 25, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 3d186c01-b07d-4f82-b40e-b402b20c008e

📥 Commits

Reviewing files that changed from the base of the PR and between 5c37e27 and f2daac4.

📒 Files selected for processing (1)
  • storage/plugins/mobile-api/views/settings.php

📝 Walkthrough

Walkthrough

La vista delle impostazioni Mobile API aggiorna wrapper, notifiche, tab, checkbox di accesso, callout attiva, controlli push e pulsante di salvataggio, sostituendo varie classi indigo con blue e btn-primary per la CTA.

Changes

Ritocco UI delle impostazioni Mobile API

Layer / File(s) Summary
Wrapper, notifiche e tab attivo
storage/plugins/mobile-api/views/settings.php
Il wrapper principale cambia struttura; i messaggi success/error cambiano classi e markup; il tab “Impostazioni” attivo usa la palette blue.
Accesso app mobile e callout
storage/plugins/mobile-api/views/settings.php
Il checkbox di abilitazione cambia icona e classi di focus/ring; la callout quando l’API è attiva aggiorna solo le classi colore.
Controlli push e CTA
storage/plugins/mobile-api/views/settings.php
Il titolo della sezione push, il select provider, gli input VAPID e FCM, e il pulsante di salvataggio passano a classi blue e btn-primary.

🎯 1 (Trivial) | ⏱️ ~5 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed Il titolo descrive correttamente l’allineamento del chrome della pagina settings al layout standard dell’admin.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/mobile-api-settings-ui-consistency

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@fabiodalez-dev

Copy link
Copy Markdown
Owner Author

Assorbita in #196 (che la include per intero insieme al resto dell'omogeneizzazione UI). Chiudo qui.

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.

1 participant