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

Adapt prop type validation method to first check for enum field #13155

Conversation

standeren
Copy link
Contributor

@standeren standeren commented Jul 15, 2024

Description

  • Adapt prop type validation when redering config for component properties to first check for enum field on property to ensure that properties without type: string is not being discarded
  • Add text keys and hook to dynamically translate enum values

Skjermbilde 2024-07-15 kl  14 53 23
Skjermbilde 2024-07-15 kl  14 53 17

Related Issue(s)

  • #{issue number}

Verification

  • Your code builds clean without any errors or warnings
  • Manual testing done (required)
  • Relevant automated test added (if you find this hard, leave it and we'll help out)

@github-actions github-actions bot added area/ui-editor Area: Related to the designer tool for assembling app UI in Altinn Studio. solution/studio/designer Issues related to the Altinn Studio Designer solution. labels Jul 15, 2024
@standeren standeren force-pushed the 13127-find-a-new-way-to-show-config-for-component-properties-with-enum-field-since-apps-are-removing-the-type-string branch from 3927b0c to 8143c8d Compare July 15, 2024 13:11
@standeren standeren changed the title Use explicit method to get properties defined as enums Adapt prop type validation method to first check for enum field Jul 15, 2024
Copy link

codecov bot commented Jul 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.56%. Comparing base (1651068) to head (4d12e09).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #13155      +/-   ##
==========================================
- Coverage   92.16%   90.56%   -1.60%     
==========================================
  Files        1443        8    -1435     
  Lines       20302      159   -20143     
  Branches     2432       33    -2399     
==========================================
- Hits        18711      144   -18567     
+ Misses       1326       14    -1312     
+ Partials      265        1     -264     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

standeren and others added 2 commits July 16, 2024 08:23
…onent-properties-with-enum-field-since-apps-are-removing-the-type-string
…onent-properties-with-enum-field-since-apps-are-removing-the-type-string
Copy link
Contributor

@ErlingHauan ErlingHauan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work 😄

Copy link
Contributor

@ErlingHauan ErlingHauan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@standeren standeren merged commit af3182e into main Jul 16, 2024
8 of 9 checks passed
@standeren standeren deleted the 13127-find-a-new-way-to-show-config-for-component-properties-with-enum-field-since-apps-are-removing-the-type-string branch July 16, 2024 10:25
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. solution/studio/designer Issues related to the Altinn Studio Designer solution.
Projects
None yet
3 participants