Skip to content

feat(web): add Guía de cumplimentación section for Renta Web filing#179

Merged
GeiserX merged 4 commits into
mainfrom
feat/guia-cumplimentacion
May 26, 2026
Merged

feat(web): add Guía de cumplimentación section for Renta Web filing#179
GeiserX merged 4 commits into
mainfrom
feat/guia-cumplimentacion

Conversation

@GeiserX
Copy link
Copy Markdown
Owner

@GeiserX GeiserX commented May 26, 2026

Summary

  • New sidebar section "Guía Renta Web" (below Modelo 100) with step-by-step instructions for filling Renta Web
  • Covers all casillas: capital gains (0327/0328), FX gains (1633/1637), dividends (0029), interest (0033), double taxation (0588)
  • Answers common user questions: entidad emisora, tipo de elemento patrimonial, gastos (0), retenciones (0), date conventions, and DT dialog field placement
  • All 5 locales fully translated (es, en, ca, eu, gl)
  • Includes the Renta Web "impuesto satisfecho sin rentas" validation fix (must fill both income + tax rows)

Test plan

  • Navigate to Guía Renta Web in sidebar — renders all sections
  • Switch language — guide re-renders in new locale
  • Mobile viewport — sidebar sub-link displays correctly
  • All casilla references match current code (0327, 0328, 1633, 1637, 0029, 0033, 0588)

Summary by CodeRabbit

  • New Features
    • Added a "Renta Web Filing Guide" in the sidebar to help users complete Renta Web forms with their tax data.
    • Guide includes detailed instructions for capital gains, currency gains, dividends, interest, double taxation deduction, and blocked losses.
    • Fully translated and optimized for all screen sizes.

Review Change Stack

GeiserX added 3 commits May 26, 2026 18:25
New sidebar section (below Modelo 100) that explains step-by-step how
to fill each casilla in Renta Web with DeclaRenta's output. Covers
capital gains (0327/0328), FX gains (1633/1637), dividends (0029),
interest (0033), double taxation (0588), and blocked losses.

Answers common user questions: entidad emisora, tipo de elemento
patrimonial, gastos (always 0), retenciones (always 0 — foreign
withholding goes to 0588), and date conventions (01/01-31/12 for
consolidation).

All 5 locales (es, en, ca, eu, gl) fully translated.
Explains that in the 0588 dialog, users must fill ONLY the last row
("Impuesto satisfecho en el extranjero"), leaving the other three
rows at 0 since broker dividends go to the savings tax base.
Renta Web shows "Ha reflejado el impuesto sin hacer constar las
rentas" if only the tax field is filled. Updated guide to indicate
both rows: gross dividends in row 2 and tax paid in row 4.
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 26, 2026

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 08681ada-ede1-4c64-87dc-cd5a3eaaef5e

📥 Commits

Reviewing files that changed from the base of the PR and between 4afde57 and 32cea7a.

📒 Files selected for processing (10)
  • src/i18n/locales/ca.ts
  • src/i18n/locales/en.ts
  • src/i18n/locales/es.ts
  • src/i18n/locales/eu.ts
  • src/i18n/locales/gl.ts
  • src/web/index.html
  • src/web/main.ts
  • src/web/section-guide.ts
  • src/web/sidebar.ts
  • src/web/style.css

📝 Walkthrough

Walkthrough

This PR adds a static Renta Web filing guide accessible via sidebar navigation. The guide displays localized instructions and field labels for completing Renta Web with DeclaRenta results, covering capital gains, FX, dividends, interest, double taxation, and blocked losses across five supported languages.

Changes

Renta Web Filing Guide

Layer / File(s) Summary
Guide Content Localization
src/i18n/locales/ca.ts, src/i18n/locales/en.ts, src/i18n/locales/es.ts, src/i18n/locales/eu.ts, src/i18n/locales/gl.ts
Added sidebar.guia entry and guide_rw.* translation keys across five languages, defining guide title, description, field labels, hints, and instructional notes for Renta Web form sections.
UI Markup and Navigation Routing
src/web/index.html, src/web/sidebar.ts
Added sidebar link and hidden guide section container. Extended routing to recognize "guia" section hash and updated sidebar link activation to set aria-current="page" on active links.
Guide Renderer Implementation
src/web/section-guide.ts
Implemented module exporting initSectionGuide() and rerenderSectionGuide() that render static guide HTML from i18n strings, with escaped labels and trusted raw HTML values from locale entries.
Application Lifecycle Integration
src/web/main.ts
Imported and wired guide section initialization during startup and locale-change event handling to ensure guide renders and updates with language selection.
Guide Styling and Layout
src/web/style.css
Added CSS for sidebar sub-link styling, guide section layout (intro, section containers, field grids with labels/values, badges, notes, warning/tip callouts), and responsive single-column layout for screens ≤480px.

🎯 3 (Moderate) | ⏱️ ~25 minutes


Possibly related issues

✨ 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 feat/guia-cumplimentacion

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 and usage tips.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.64%. Comparing base (e57be48) to head (32cea7a).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #179      +/-   ##
==========================================
+ Coverage   97.57%   97.64%   +0.07%     
==========================================
  Files          38       38              
  Lines        7780     8015     +235     
  Branches     1595     1595              
==========================================
+ Hits         7591     7826     +235     
  Misses        188      188              
  Partials        1        1              
Files with missing lines Coverage Δ
src/i18n/locales/ca.ts 100.00% <100.00%> (ø)
src/i18n/locales/en.ts 100.00% <100.00%> (ø)
src/i18n/locales/es.ts 100.00% <100.00%> (ø)
src/i18n/locales/eu.ts 100.00% <100.00%> (ø)
src/i18n/locales/gl.ts 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

- Replace div/span with dl/dt/dd for screen reader semantics
- Fix heading hierarchy h2→h3 (was h4, skipping h3)
- Import shared esc() instead of local duplicate
- Add aria-current="page" on active sidebar link
- Add aria-live="polite" on guide-content container
- Replace opacity with explicit color for WCAG contrast
- Add mobile responsive grid for guide fields
- Remove unused badge-guia span
- Document HTML trust boundary in JSDoc
@GeiserX GeiserX merged commit a3c0701 into main May 26, 2026
1 of 2 checks passed
@GeiserX GeiserX deleted the feat/guia-cumplimentacion branch May 26, 2026 20:50
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