Altinn / Altinn/app-frontend-react

Changing focus to another row in RepeatingGroup

Open
#2,949 1 comment 0 reactions 0 assignees View on GitHub
area/table kind/feature-request
Dominant language
TypeScript
Stars
21
Forks
33
Avg merge
6d 23h
Merged PRs (30d)
3

Description

### Description

_(Åpne rad og skifte fokus i repeterende tabell)_

I would like to be able to change which row has focus/is open, f.ex. after pushing a button. In my use-case I have a custom button on each row that creates a new row at the bottom of the repeating group with a copy of elements from the active row. As a user I would have expected that I would be moved to the first element on the new (partially copied) row . Otherwise it is easy to think that the button is not doing what it is supposed to since you don't necessarily notice a collapsed row at the bottom (especially if you have a long repeating group). Being able to change the focus with code (automatically open another row, and perhaps closing the one you came from) would fix this problem.

![Image](https://github.com/user-attachments/assets/d388dae8-c50b-41e8-b808-76924a7bbe7e)

Contributor guide

Open the contributing guide

Research direction

Start by locating the RepeatingGroup implementation and its focus or row-opening entry points. Trace how a custom button action creates a new row, then define how code should select the new row and whether the previous row closes. Done means an app can move focus to the newly created row reliably, with behavior that matches the described use case.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Feature
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.