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

Form: refactor section config in RDMDepositForm #2983

Merged
merged 5 commits into from
Mar 18, 2025

Conversation

carlinmack
Copy link
Contributor

@carlinmack carlinmack commented Feb 17, 2025

❤️ Thank you for your contribution!

Description

  • Extracted includedPaths in a config,
  • Added ids for accordions
  • Added css classes for severity checks (only error, warning and info. Failures would just be errors)
lol

Checklist

Ticks in all boxes and 🟢 on all GitHub actions status checks are required to merge:

Frontend

Reminder

By using GitHub, you have already agreed to the GitHub’s Terms of Service including that:

  1. You license your contribution under the same terms as the current repository’s license.
  2. You agree that you have the right to license your contribution under the current repository’s license.

@0einstein0 0einstein0 force-pushed the curation-checks branch 3 times, most recently from 19efcc4 to dac903c Compare February 20, 2025 10:15
@0einstein0 0einstein0 marked this pull request as ready for review February 20, 2025 15:08
@0einstein0 0einstein0 changed the title WIP: Curation checks Form: refactor section config in RDMDepositForm Mar 6, 2025
@0einstein0 0einstein0 force-pushed the curation-checks branch 2 times, most recently from 6e07166 to 124d1a1 Compare March 13, 2025 08:17
@0einstein0 0einstein0 force-pushed the curation-checks branch 4 times, most recently from 5280a98 to 6fe8b93 Compare March 14, 2025 09:28
@0einstein0 0einstein0 requested a review from kpsherva March 14, 2025 09:28
Copy link
Member

Choose a reason for hiding this comment

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

Remember to ignore whitespaces

// Adding section id to custom fields UI, to be used for accordions
const customFieldsUI = this.config.custom_fields.ui.map((section) => ({
...section,
id: section.section.toLowerCase().replace(/\s+/g, "-") + "-section",
Copy link
Contributor

Choose a reason for hiding this comment

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

the regex detection is quite risky, why is it needed?

Copy link
Member

Choose a reason for hiding this comment

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

the section names are defined like this for example in the ui config, so it is replacing space with - and appending -section

@ptamarit ptamarit merged commit 88985ee into inveniosoftware:master Mar 18, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deposit Form: revamp errors/warning in banner and form sections
4 participants