Skip to content

Commit

Permalink
fix: correct calculation of height when using primary-size='auto'
Browse files Browse the repository at this point in the history
  • Loading branch information
spdev3000 authored and Westbrook committed Mar 3, 2021
1 parent 3040e92 commit 0ff67c0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/split-view/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"lit-element",
"lit-html"
],
"version": "0.1.0",
"version": "0.1.1",
"description": "",
"main": "src/index.js",
"module": "src/index.js",
Expand Down
4 changes: 2 additions & 2 deletions packages/split-view/src/SplitView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -377,9 +377,9 @@ export class SplitView extends SpectrumElement {
const size = window
.getComputedStyle(firstEl)
.getPropertyValue(this.vertical ? 'height' : 'width');
const size_i = parseInt(size, 10);
const size_i = parseFloat(size);
if (!isNaN(size_i)) {
return this.getLimitedPosition(size_i);
return this.getLimitedPosition(Math.ceil(size_i));
}
}
}
Expand Down

0 comments on commit 0ff67c0

Please sign in to comment.