feat: remodelar /sobre conforme mock editorial
All checks were successful
All checks were successful
Alinha a página Sobre à composição aprovada (hero, pilares, Michele, processo, portfólio, CTA), com foto da Michele via CMS e tokens Heritage Editorial. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2
openspec/changes/remodel-about-page/.openspec.yaml
Normal file
2
openspec/changes/remodel-about-page/.openspec.yaml
Normal file
@@ -0,0 +1,2 @@
|
||||
schema: spec-driven
|
||||
created: 2026-08-12
|
||||
27
openspec/changes/remodel-about-page/design.md
Normal file
27
openspec/changes/remodel-about-page/design.md
Normal file
@@ -0,0 +1,27 @@
|
||||
# Design: remodel About page
|
||||
|
||||
## Context
|
||||
|
||||
Mock `amare-sobre(1).html` define composição e copy. O site já tem Heritage Editorial (`tokens.css`, `DESIGN.md`), `about_image_*` no CMS, e `PortfolioCase` featured na home.
|
||||
|
||||
## Decisions
|
||||
|
||||
1. **Hero** reusa `about_image_path` com layout split próprio (`x-about.hero`), não o full-viewport `x-public.photo-hero`. Fallback tonal quando sem imagem.
|
||||
2. **Michele** usa `founder_image_*` novos; sem path → coluna tonal, sem request de imagem inventada.
|
||||
3. **Portfólio** lê até 6 casos `published` + `is_featured` via `GetAboutContent` (mesma regra da home).
|
||||
4. **Copy** de pilares/Michele/processo/CTA fixa do mock; `about_summary` alimenta lead/SEO.
|
||||
5. **Visual**: estrutura do mock; radius 0, EB Garamond, botões `btn` existentes — desvios tipográficos/pill do HTML são descartados.
|
||||
|
||||
## Spine
|
||||
|
||||
```
|
||||
PageController::about
|
||||
→ GetAboutContent
|
||||
→ AboutContent
|
||||
→ pages/about.blade.php + x-about.*
|
||||
```
|
||||
|
||||
## Risks
|
||||
|
||||
- Testes que acoplam `/sobre` a `data-photo-hero` full-vh precisam atualizar o contrato.
|
||||
- Home positioning continua usando `about_image_path` — não reaproveitar esse campo como foto da Michele.
|
||||
26
openspec/changes/remodel-about-page/proposal.md
Normal file
26
openspec/changes/remodel-about-page/proposal.md
Normal file
@@ -0,0 +1,26 @@
|
||||
# Remodel página Sobre conforme mock aprovado
|
||||
|
||||
## Why
|
||||
|
||||
A rota `/sobre` ainda usa abertura `photo-hero` full-viewport + lista de princípios. O cliente validou o mock `amare-sobre(1).html` com jornada editorial própria: hero split, pilares, bloco Michele, processo, portfólio em destaque e CTA. Sem essa remodelação, a página institucional fica desalinhada da home e do material aprovado.
|
||||
|
||||
## What Changes
|
||||
|
||||
- `/sobre` recomposta em seções `x-about.*` espelhando a ordem do mock (hero, pilares, Michele, processo, portfólio masonry, CTA).
|
||||
- Novo campo CMS `founder_image_path` / `founder_image_alt` no singleton `site_settings` para a foto da Michele; hero continua em `about_image_path`.
|
||||
- Query `GetAboutContent` + DTO `AboutContent` (featured cases ≤6) no spine Application.
|
||||
- Tokens Heritage Editorial do repo (sem Inter/Cormorant, sem pills do HTML estático).
|
||||
|
||||
## Non-Goals
|
||||
|
||||
- CMS para copy dos pilares/Michele/processo.
|
||||
- Replicar header/footer do HTML estático.
|
||||
- Alterar tokens globais assertados por `HeritageEditorialTokensTest`.
|
||||
- Gerar fotografia da Michele (apenas upload).
|
||||
|
||||
## Capabilities
|
||||
|
||||
### Modified Capabilities
|
||||
|
||||
- `public-site-pages`: `/sobre` com composição do mock; motion contract preservado.
|
||||
- `site-settings`: campos `founder_image_path` e `founder_image_alt` administráveis no Filament.
|
||||
@@ -0,0 +1,32 @@
|
||||
## ADDED Requirements
|
||||
|
||||
### Requirement: About page follows approved editorial composition
|
||||
|
||||
The `/sobre` route SHALL render the Heritage Editorial public layout with this section order: split hero (eyebrow “Sobre nós”, title “Sobre a Amare”, lead from `about_summary` or editorial default, CTA to `#michele`), three pillars, founder block `#michele` (Michele), process (“Como trabalhamos”), featured portfolio masonry (up to six published featured cases), and a final proposal CTA. The page MUST use shared motion markers (`data-motion="page-open"`, `data-reveal*`) without route transitions. Principles list MUST NOT appear on `/sobre` (home may still show them). Contact, privacy and error surfaces remain unchanged by this requirement.
|
||||
|
||||
#### Scenario: Visitor sees the mock section order
|
||||
|
||||
- **WHEN** a visitor loads `/sobre`
|
||||
- **THEN** the response MUST include the headings for Sobre a Amare, the three pillars, Conheça Michele, Como trabalhamos, Portfólio em destaque, and the proposal CTA copy
|
||||
- **AND** MUST NOT render the numbered principles list formerly used on About
|
||||
|
||||
#### Scenario: Founder photo comes from CMS when configured
|
||||
|
||||
- **GIVEN** `site_settings.founder_image_path` is set with alt text
|
||||
- **WHEN** a visitor loads `/sobre`
|
||||
- **THEN** the Michele section MUST render that image with the configured alt
|
||||
- **AND** MUST use eager loading only for the about hero image, not invent a founder asset path when unset
|
||||
|
||||
#### Scenario: About hero uses about_image with tonal fallback
|
||||
|
||||
- **WHEN** `about_image_path` is configured
|
||||
- **THEN** `/sobre` MUST render a split editorial hero with that media (`loading="eager"` and `fetchpriority="high"`)
|
||||
- **WHEN** `about_image_path` is empty
|
||||
- **THEN** `/sobre` MUST render a tonal hero fallback without an empty image request
|
||||
|
||||
#### Scenario: Featured portfolio tiles use real cases
|
||||
|
||||
- **GIVEN** published featured portfolio cases exist
|
||||
- **WHEN** a visitor loads `/sobre`
|
||||
- **THEN** the masonry MUST link to those cases (or the portfolio index)
|
||||
- **AND** MUST NOT invent decorative photography when no cases exist (tonal slots allowed)
|
||||
@@ -0,0 +1,47 @@
|
||||
## MODIFIED Requirements
|
||||
|
||||
### Requirement: Site settings singleton is manageable by admin only
|
||||
|
||||
The system SHALL persist site-wide settings in a `site_settings` table as a typed singleton (SPEC WEB-06, §8.2). Fields MUST include brand name, optional logo path and logo alt text, hero copy (eyebrow, title, subtitle, primary CTA label, optional secondary CTA label, optional hero note), manifesto copy (title, lead, body), method steps (structured typed data for four editorial steps), principles (structured typed list), about summary, optional about hero image path and alt text, optional founder image path and alt text (Michele portrait for `/sobre`), contact email/phone/city, social links (jsonb), default meta title/description, default OG image path and alt text, and optional analytics fields disabled by default.
|
||||
|
||||
#### Scenario: Admin updates site settings
|
||||
|
||||
- **WHEN** an admin saves the site settings form in Filament
|
||||
- **THEN** the singleton record is updated
|
||||
- **AND** labels and validation messages are in pt-BR
|
||||
|
||||
#### Scenario: Founder image upload requires alt text
|
||||
|
||||
- **WHEN** an admin uploads a founder image without alt text
|
||||
- **THEN** validation MUST fail with a pt-BR error message
|
||||
- **AND** alt text MUST remain optional when no founder image is present
|
||||
|
||||
#### Scenario: Assistant cannot access site settings
|
||||
|
||||
- **WHEN** an assistant navigates to site settings in Filament
|
||||
- **THEN** access MUST be denied with HTTP 403
|
||||
|
||||
#### Scenario: Default OG image requires alt text
|
||||
|
||||
- **WHEN** an admin uploads a default OG image without alt text
|
||||
- **THEN** validation MUST fail with a pt-BR error message
|
||||
- **AND** alt text MUST remain optional when no default OG image is present
|
||||
|
||||
#### Scenario: Logo upload requires alt text
|
||||
|
||||
- **WHEN** an admin uploads a brand logo without alt text
|
||||
- **THEN** validation MUST fail with a pt-BR error message
|
||||
- **AND** alt text MUST remain optional when no logo is uploaded
|
||||
|
||||
#### Scenario: Singleton avoids generic key-value store
|
||||
|
||||
- **WHEN** site settings are stored
|
||||
- **THEN** the system MUST use typed columns on `site_settings`
|
||||
- **AND** MUST NOT introduce a generic key/value configuration table
|
||||
|
||||
#### Scenario: Editorial defaults remain available when optional fields are empty
|
||||
|
||||
- **GIVEN** manifesto, method steps or principles fields are empty
|
||||
- **WHEN** the home is rendered
|
||||
- **THEN** the page MUST still render those sections using safe editorial defaults
|
||||
- **AND** MUST NOT error
|
||||
8
openspec/changes/remodel-about-page/tasks.md
Normal file
8
openspec/changes/remodel-about-page/tasks.md
Normal file
@@ -0,0 +1,8 @@
|
||||
# Tasks: remodel-about-page
|
||||
|
||||
- [x] 1. Migration + SiteSetting fillable/PHPDoc para `founder_image_path` / `founder_image_alt`
|
||||
- [x] 2. Filament ManageSiteSettings: labels hero Sobre + upload Michele; media variants + seeders
|
||||
- [x] 3. AboutContent DTO + GetAboutContent; PageController injeta query
|
||||
- [x] 4. Componentes `x-about.*` + reescrever `pages/about.blade.php`
|
||||
- [x] 5. Feature tests About + atualizar ImmersivePhotoHero / Media / Motion / PublicPages / Filament alt
|
||||
- [ ] 6. PR verde
|
||||
Reference in New Issue
Block a user