fix: Hide show more labels button when there's no overflow (#6097)

This commit is contained in:
Nithin David Thomas
2022-12-19 22:24:20 +05:30
committed by GitHub
parent 022d0b0ea3
commit d1a26e80f4
3 changed files with 32 additions and 7 deletions

View File

@@ -66,6 +66,8 @@ export default {
const labelContainer = this.$refs.labelContainer;
const labels = this.$refs.labelContainer.querySelectorAll('.label');
let labelOffset = 0;
this.showExpandLabelButton = false;
Array.from(labels).forEach((label, index) => {
labelOffset += label.offsetWidth + 8;
@@ -82,9 +84,10 @@ export default {
<style lang="scss" scoped>
.show-more--button {
height: var(--space-medium);
height: var(--space-two);
position: sticky;
flex-shrink: 0;
right: 0;
margin-right: var(--space-medium);
&.secondary:focus {