Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support: CloseSubformButton in subform layout set #13836

Closed
4 tasks
lassopicasso opened this issue Oct 21, 2024 · 1 comment
Closed
4 tasks

Support: CloseSubformButton in subform layout set #13836

lassopicasso opened this issue Oct 21, 2024 · 1 comment
Assignees
Labels
area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. team/studio-domain2

Comments

@lassopicasso
Copy link
Contributor

lassopicasso commented Oct 21, 2024

Description

When setting up a subform, users need a close button that will close the subform and redirect them back to the associated main form.

To implement this, we can utilize our custom button feature. A switch button should be displayed at the top of the configuration on the subform layout page, just below the page ID. When the switch is activated, a custom button will be added to the component list for that page, configured as follows:

"id": "<some-generated-id",
"type": "CustomButton",
"actions": [
  {
    "type": "ClientAction",
    "id": "closeSubForm",
    "validation": {
        "page": "all",
        "show": ["All"]
      }
  }
]

Users must be able to define the button text, with a default text provided initially. If the button is removed from the component list, the switch should be turned off.

This functionality should allow for a switch button for each page in a subform.

Additional Information

Tasks:

  • Add a Switch Below the ID: Implement a switch labeled "Legg til lukk underskjema knapp" below the ID on the layout page.
  • Display and remove Custom Button: Ensure that when the switch is activated, the custom button appears in the layout page component list. When the switch is turned off, the custom button should be removed from the layout page. This functionality should also apply when dragging and dropping a custom button onto a subform page.
  • Add/Delete Configuration: Implement the addition and deletion of the custom button configuration as outlined above.
  • Default and custom button text: Allow users to define the text on the custom button, while also providing a default text initially.
@lassopicasso lassopicasso added area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. kind/feature-request Feature request that will be considered. team/studio-domain2 labels Oct 21, 2024
@lassopicasso lassopicasso removed the kind/feature-request Feature request that will be considered. label Oct 21, 2024
@lassopicasso lassopicasso self-assigned this Oct 21, 2024
@lassopicasso lassopicasso moved this to 👷 In Progress in Team Studio Oct 21, 2024
@lassopicasso
Copy link
Contributor Author

Close this - issue #13843 and #13844 solves this.

@github-project-automation github-project-automation bot moved this from 👷 In Progress to Documentation in Team Studio Oct 22, 2024
@lassopicasso lassopicasso moved this from Documentation to ✅ Done in Team Studio Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. team/studio-domain2
Projects
Archived in project
Development

No branches or pull requests

1 participant