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

fix(VSlideGroup): recalculate widths when it shows #14253

Closed
wants to merge 2 commits into from
Closed

fix(VSlideGroup): recalculate widths when it shows #14253

wants to merge 2 commits into from

Conversation

beicause
Copy link

Description

fixes #14195

Motivation and Context

How Has This Been Tested?

Markup:

<template>
  <v-container>
    <v-btn @click="show = !show">
      Show bug
    </v-btn>
    <v-sheet
      elevation="5"
      class="ma-5 pa-5"
      max-width="800"
    >

      <v-slide-group
        v-show="show"
        show-arrows
      >
        <v-slide-item
          v-for="n in list"
          :key="n"
          v-slot="{ active, toggle }"
        >
          <v-btn
            class="mx-2"
            :input-value="active"
            active-class="primary white--text"
            depressed
            rounded
            @click="toggle"
          >
            Options {{ n }}
          </v-btn>
        </v-slide-item>
      </v-slide-group>
    </v-sheet>
  </v-container>
</template>

<script>
  export default {
    data: () => ({
      show: false,
      list: Array.from(Array(10).keys()),
    }),
  }
</script>

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Improvement/refactoring (non-breaking change that doesn't add any features but makes things better)

Checklist:

  • The PR title is no longer than 64 characters.
  • The PR is submitted to the correct branch (master for bug fixes and documentation updates, dev for new features and backwards compatible changes and next for non-backwards compatible changes).
  • My code follows the code style of this project.
  • I've added relevant changes to the documentation (applies to new features and breaking changes in core library)

@Goshin
Copy link

Goshin commented Oct 11, 2021

Would this solution still work if we toggle the parent's display property instead of that of the VSlideGroup itself?

@beicause beicause closed this Oct 11, 2021
@beicause
Copy link
Author

Would this solution still work if we toggle the parent's display property instead of that of the VSlideGroup itself?

it's really a problem😅

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.

[Bug Report][2.5.8] VSlideGroup: overflow arrows do not show up if the slide group is initially invisible
2 participants