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

feat(setup-wizard): Prefill project and team #85920

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ArthurKnaus
Copy link
Member

Pre-fill project and team input if there is only one available option.

@ArthurKnaus ArthurKnaus requested a review from a team February 26, 2025 08:37
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Feb 26, 2025
@@ -130,6 +130,22 @@ export function WizardProjectSelection({
const {options: cachedProjectOptions, clear: clearProjectOptions} =
useCompactSelectOptionsCache(projectOptions);

// Set the selected project to the first option if there is only one
useEffect(() => {
Copy link
Member Author

@ArthurKnaus ArthurKnaus Feb 26, 2025

Choose a reason for hiding this comment

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

In both cases we need to use useEffect as we need to wait for the respective requests.

Copy link
Member

@priscilawebdev priscilawebdev left a comment

Choose a reason for hiding this comment

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

code looks good to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: Frontend Automatically applied to PRs that change frontend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Setup wizard: Pre-fill project and team if only one option
2 participants