HumanSignal / HumanSignal/label-studio
Selected param on Choice elements is ignored when parent Choices tag is set to perRegion
- Dominant language
- TypeScript
- Stars
- 28.3k
- Forks
- 3.7k
- Avg merge
- 14h
- Merged PRs (30d)
- 15
Description
**Describe the bug**
When using the Choices tag with `perRegion="true"` attribute, the `selected="true"` attribute on individual Choice elements is ignored. This means that default selections don't work properly when labeling regions, forcing users to manually select options each time.
**To Reproduce**
Steps to reproduce the behavior:
1. Create a Label Studio project with a configuration that includes Choices with `perRegion="true"`
2. Add selected="true" to one of the Choice elements within the choice group
3. Start labeling and create a region
4. Notice that none of the choices are pre-selected, despite having the selected="true" attribute.
Example configuration demonstrating the issue:
```xml
```
**Expected behavior**
When creating a new region, the Choice element with `selected="true"` should be automatically selected by default. This would save time for annotators who frequently use the same choices.
**Screenshots**
**Environment (please complete the following information):**
- OS: macOS Sequoia 15.3.2
- Label Studio Version: 1.17.0
Contributor guide
Assessment
This issue has not been assessed yet.