@linear_non/stellar-libs 1.2.4 → 1.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/Sticky/index.js +2 -1
package/package.json
CHANGED
package/src/Sticky/index.js
CHANGED
|
@@ -99,9 +99,10 @@ export default class Sticky {
|
|
|
99
99
|
|
|
100
100
|
// Get the viewport height dynamically instead of using store
|
|
101
101
|
const vh = window.innerHeight
|
|
102
|
+
const vw = window.innerWidth
|
|
102
103
|
let stickyRect = bounds(this.el)
|
|
103
104
|
let containerRect = this.container ? bounds(this.container) : null
|
|
104
|
-
this.config.totalWidth = containerRect ? this.snap(containerRect.width -
|
|
105
|
+
this.config.totalWidth = containerRect ? this.snap(containerRect.width - vw) : 0
|
|
105
106
|
this.config.totalHeight = this.snap(stickyRect.height - vh)
|
|
106
107
|
}
|
|
107
108
|
|