@titelmedia/bricks-age-gate
Advanced tools
Comparing version 0.3.25 to 0.3.26
@@ -6,2 +6,10 @@ # Change Log | ||
## [0.3.26](https://github.com/titel-media/bricks-lerna/compare/v0.3.25...v0.3.26) (2022-01-25) | ||
**Note:** Version bump only for package @titelmedia/bricks-age-gate | ||
## [0.3.25](https://github.com/titel-media/bricks-lerna/compare/v0.3.24...v0.3.25) (2022-01-25) | ||
@@ -8,0 +16,0 @@ |
@@ -36,12 +36,7 @@ "use strict"; | ||
console.log('document', document.getElementById('__gatsby'), document.getElementById('root')); | ||
let rootRef = document.getElementById('__gatsby') || document.getElementById('root'); | ||
const rootRef = (0, _react.useRef)(document.getElementById('__gatsby') || document.getElementById('root')); | ||
console.log(document, window); | ||
(0, _react.useEffect)(() => { | ||
console.debug('1', window, document); | ||
if (typeof window === 'object') { | ||
console.debug('2', window, document); | ||
let rootRef = document.getElementById('__gatsby') || document.getElementById('root'); | ||
buildTimeline(); | ||
(0, _bodyScrollLock.disableBodyScroll)(rootRef); | ||
} | ||
buildTimeline(); | ||
(0, _bodyScrollLock.disableBodyScroll)(rootRef); | ||
}, []); | ||
@@ -61,2 +56,3 @@ (0, _react.useEffect)(() => { | ||
console.log(document.getElementById('__gatsby')); | ||
console.log(document, window); | ||
tlRef.current = _all.gsap.timeline().to(rootRef.current, { | ||
@@ -63,0 +59,0 @@ duration: 0.4, |
@@ -20,13 +20,8 @@ import React, { useEffect, useRef, useState } from 'react'; | ||
console.log('document',document.getElementById('__gatsby'), document.getElementById('root')); | ||
let rootRef = document.getElementById('__gatsby') || document.getElementById('root') | ||
const rootRef = useRef(document.getElementById('__gatsby') || document.getElementById('root')); | ||
console.log(document, window); | ||
useEffect(() => { | ||
console.debug('1',window, document); | ||
if (typeof window === 'object') { | ||
console.debug('2',window, document); | ||
let rootRef = document.getElementById('__gatsby') || document.getElementById('root') | ||
buildTimeline(); | ||
disableBodyScroll(rootRef); | ||
} | ||
buildTimeline(); | ||
disableBodyScroll(rootRef); | ||
}, []); | ||
@@ -46,2 +41,3 @@ | ||
console.log(document.getElementById('__gatsby')); | ||
console.log(document, window); | ||
tlRef.current = gsap | ||
@@ -48,0 +44,0 @@ .timeline() |
{ | ||
"name": "@titelmedia/bricks-age-gate", | ||
"version": "0.3.25", | ||
"version": "0.3.26", | ||
"description": "Now I’m the model of a modern major general / The venerated Virginian veteran whose men are all / Lining up, to put me up on a pedestal / Writin’ letters to relatives / Embellishin’ my elegance and eloquence / But the elephant is in the room / The truth is in ya face when ya hear the British cannons go / BOOM", | ||
@@ -33,3 +33,3 @@ "keywords": [], | ||
"homepage": "https://github.com/titel-media/bricks-lerna#readme", | ||
"gitHead": "91ca3c750db2bdb96bea8361c1468d1c10d0315b" | ||
"gitHead": "98f902c1856af3542f367bd38b69bd02afb6fe69" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
22168
323