Skip to content

Commit

Permalink
Cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniandre committed Aug 11, 2024
1 parent f993966 commit 2c7319b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/components/splitpanes/splitpanes.vue
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,7 @@ const getCurrentMouseDrag = event => {
}
}
// Returns the drag percentage of the splitter relative to the 2 panes it's in between.
// if the sum of size of the 2 cells is 60%, the dragPercentage range will be 0 to 100% of this 60%.
// Returns the drag percentage of the splitter relative to the container (ranging from 0 to 100%).
const getCurrentDragPercentage = drag => {
drag = drag[props.horizontal ? 'y' : 'x']
// In the code below 'size' refers to 'width' for vertical and 'height' for horizontal layout.
Expand Down Expand Up @@ -264,6 +263,7 @@ const doPushOtherPanes = (sums, dragPercentage) => {
}
return { sums, panesToResize }
}
const sumPrevPanesSize = splitterIndex => {
return panes.value.reduce((total, pane, i) => total + (i < splitterIndex ? pane.size : 0), 0)
}
Expand Down
2 changes: 1 addition & 1 deletion src/views/documentation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@

//- Example.
h3.mt12.pt8.mb2(id="lots-of-splitters")
a(href="#lots-of-splitters") Lots of splitters &amp; push other panes - all panes have a min width of 5%
a(href="#lots-of-splitters") Lots of splitters &amp; push other panes - all the panes have a min width of 5%
splitpanes.default-theme.example(style="height: 400px")
pane(v-for="i in 8" :key="i" :min-size="5")
span {{ i }}
Expand Down

0 comments on commit 2c7319b

Please sign in to comment.