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 : Group chaos infra in infrastructure selection modal #4779

Conversation

JanhaviAlekar
Copy link
Contributor

@JanhaviAlekar JanhaviAlekar commented Jul 19, 2024

Proposed changes

Screencast.from.05-08-24.06.22.12.PM.IST.webm

Types of changes

What types of changes does your code introduce to Litmus? Put an x in the boxes that apply

  • New feature (non-breaking change which adds functionality)
  • Bugfix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices applies)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING doc
  • I have signed the commit for DCO to be passed.
  • Lint and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works (if appropriate)
  • I have added necessary documentation (if appropriate)

Dependency

  • Please add the links to the dependent PR need to be merged before this (if any).

Special notes for your reviewer:

Copy link
Member

@SahilKr24 SahilKr24 left a comment

Choose a reason for hiding this comment

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

Good first attempt, but need a bit more of work

Signed-off-by: JanhaviAlekar <[email protected]>
gotoPage={setPage}
showPagination={true}
pageSizeOptions={[5, 10, 15]}
onPageSizeChange={event => setLimit(parseInt(event.toString()))}
Copy link
Member

Choose a reason for hiding this comment

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

onPageSizeChange={setLimit}

const { showError } = useToaster();
const { getString } = useStrings();

const listingEnvironment = ({ env }: { env: Environment }): JSX.Element => {
const EnvListItem = ({ EnvDetail }: { EnvDetail: EnvironmentDetail }): JSX.Element => {
Copy link
Member

Choose a reason for hiding this comment

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

EnvDetail in camelCase

@@ -183,7 +209,7 @@ function ChaosInfrastructureReferenceFieldView({
withoutCurrentColor={true}
rightIcon="chevron-down"
iconProps={{ size: 14 }}
onClick={() => setOpen(true)}
onClick={() => open()}
Copy link
Member

Choose a reason for hiding this comment

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

onClick={open}

placeholder={getString('search')}
onChange={e => setSearchInfrastructure(e)}
/>
{isOpen && (
Copy link
Member

Choose a reason for hiding this comment

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

might not me required, please check and remove

history.push(paths.toEnvironments());
}}
/>
<EnvListItem EnvDetail={{ envName: 'all', envID: 'all', totalInfra: allInfrastructureLength }} />
Copy link
Member

Choose a reason for hiding this comment

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

strings

Signed-off-by: JanhaviAlekar <[email protected]>
@Saranya-jena Saranya-jena merged commit 1a03758 into litmuschaos:master Sep 6, 2024
16 of 17 checks passed
andoriyaprashant pushed a commit to andoriyaprashant/litmus that referenced this pull request Sep 7, 2024
…os#4779)

* Adding environment filter in Infrastructure selection modal

Signed-off-by: JanhaviAlekar <[email protected]>

* setting initialAllInfrastructureLength as 0 initially

Signed-off-by: JanhaviAlekar <[email protected]>

* making InitialAllInfrastructureLength consistent

Signed-off-by: JanhaviAlekar <[email protected]>

* Scroll env list and Pagination(infra)

Signed-off-by: JanhaviAlekar <[email protected]>

* added preSelectedEnvironmentID

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor changes in code

Signed-off-by: JanhaviAlekar <[email protected]>

* Refactored code

Signed-off-by: JanhaviAlekar <[email protected]>

* Changing height of infralist section

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor improvements

Signed-off-by: JanhaviAlekar <[email protected]>

---------

Signed-off-by: JanhaviAlekar <[email protected]>
Co-authored-by: Sahil <[email protected]>
Co-authored-by: Saranya Jena <[email protected]>
Signed-off-by: andoriyaprashant <[email protected]>
andoriyaprashant pushed a commit to andoriyaprashant/litmus that referenced this pull request Sep 7, 2024
…os#4779)

* Adding environment filter in Infrastructure selection modal

Signed-off-by: JanhaviAlekar <[email protected]>

* setting initialAllInfrastructureLength as 0 initially

Signed-off-by: JanhaviAlekar <[email protected]>

* making InitialAllInfrastructureLength consistent

Signed-off-by: JanhaviAlekar <[email protected]>

* Scroll env list and Pagination(infra)

Signed-off-by: JanhaviAlekar <[email protected]>

* added preSelectedEnvironmentID

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor changes in code

Signed-off-by: JanhaviAlekar <[email protected]>

* Refactored code

Signed-off-by: JanhaviAlekar <[email protected]>

* Changing height of infralist section

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor improvements

Signed-off-by: JanhaviAlekar <[email protected]>

---------

Signed-off-by: JanhaviAlekar <[email protected]>
Co-authored-by: Sahil <[email protected]>
Co-authored-by: Saranya Jena <[email protected]>
Signed-off-by: andoriyaprashant <[email protected]>
sagnik3788 pushed a commit to sagnik3788/litmus that referenced this pull request Oct 5, 2024
…os#4779)

* Adding environment filter in Infrastructure selection modal

Signed-off-by: JanhaviAlekar <[email protected]>

* setting initialAllInfrastructureLength as 0 initially

Signed-off-by: JanhaviAlekar <[email protected]>

* making InitialAllInfrastructureLength consistent

Signed-off-by: JanhaviAlekar <[email protected]>

* Scroll env list and Pagination(infra)

Signed-off-by: JanhaviAlekar <[email protected]>

* added preSelectedEnvironmentID

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor changes in code

Signed-off-by: JanhaviAlekar <[email protected]>

* Refactored code

Signed-off-by: JanhaviAlekar <[email protected]>

* Changing height of infralist section

Signed-off-by: JanhaviAlekar <[email protected]>

* Minor improvements

Signed-off-by: JanhaviAlekar <[email protected]>

---------

Signed-off-by: JanhaviAlekar <[email protected]>
Co-authored-by: Sahil <[email protected]>
Co-authored-by: Saranya Jena <[email protected]>
Signed-off-by: sagnik3788 <[email protected]>
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.

3 participants