Altinn / Altinn/app-frontend-react

Duplicate Grid Component in PDF

Open
#2,563 2 comments 0 reactions 0 assignees View on GitHub
area/summary kind/bug needs-info
Dominant language
TypeScript
Stars
21
Forks
33
Avg merge
6d 23h
Merged PRs (30d)
3

Description

### Description of the bug

A Summary2 component that references a Grid component gets duplicated in the PDF.
The first one is in the old style where all the components are displayed as a list, and the second one is displayed in the new style as a full grid.
The second one also appear at the end of the PDF, after other components.
Ideally the first one should be removed and be replaced with the second one so that only the grid version is visible.

### Steps To Reproduce

Create a Grid component
Create a Summary2 that references the Grid
In the summary page it looks correct, but in the PDF the Summary component is duplicated

### Additional Information

This behavior can be displayed in this repo: https://altinn.studio/repos/krt/krt-1189a-1
The frontend version used was ` v4.9.0-preview.3.`

![Image](https://github.com/user-attachments/assets/1211d6db-081c-43ec-bc1b-8160d17daa82)
![Image](https://github.com/user-attachments/assets/d7e69d2a-76ea-4972-95a0-e7a9bec4acbd)

Contributor guide

Open the contributing guide

Research direction

The payload names no source files or tests. Reproduce the issue with a Grid referenced by a Summary2 in the linked example, then trace the PDF rendering path for the Summary2 and Grid components. Done means the PDF contains only the full-grid rendering in the correct position, without the duplicated list-style component.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.