-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Solved resize problem by changing to float
Prior to this commit, if you resized the swipe-pages element, everything would go weird. This was because the width of the container was not tracked and the display used was inline flex. The problem with tracking the width is that it is a very costly procedure which is unacceptable for a basic element such as this one. As such, the switch was made to float: left; and adding an extra container in the shadow dom. To get the widths to work correctly, the only thing that is tracked is the number of swipe-page elements there are, which is a much cheaper process.
- Loading branch information
1 parent
77e2150
commit 24a5db7
Showing
5 changed files
with
91 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "swipe-pages", | ||
"version": "0.1.0", | ||
"version": "0.2.0", | ||
"ignore" : [ | ||
".editorconfig", | ||
".jshintrc", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
:host, .pageContent { | ||
height: inherit; | ||
width: inherit; | ||
height: 100%; | ||
float: left; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters