Skip to content

fix: update default value handling for dynamic defaults #17609

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

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

jaaydenh
Copy link
Contributor

@jaaydenh jaaydenh self-assigned this Apr 29, 2025
@jaaydenh jaaydenh requested a review from Emyrk April 29, 2025 22:37
@jaaydenh jaaydenh requested a review from aslilac April 30, 2025 22:50
Comment on lines +208 to +215
const selectedOptions: Option[] = JSON.parse(value).map((val: string) => {
const option = parameter.options.find((o) => o.value.value === val);
return {
value: val,
label: option?.name || val,
disable: false,
};
});
Copy link
Member

Choose a reason for hiding this comment

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

this is screaming for some sort of typing issue here. how confident are we that JSON.parse(value) will actually always return a string[] here?

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.

Frontend default value handling
2 participants