File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
packages/homepage/src/components/Toast Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change 1- /* eslint-disable jsx-a11y/control-has-associated-label */
21import React , { useState , useEffect } from 'react' ;
32import { Link } from 'gatsby' ;
43import { AnimatePresence } from 'framer-motion' ;
54
65import { ToastContainer } from './elements' ;
76
7+ const key = 'ACCEPTED_TERMS_CODESANDBOX' ;
88const Privacy = ( ) => {
9- const key = 'ACCEPTED_TERMS_CODESANDBOX' ;
10- const [ show , setShow ] = useState ( false ) ;
9+ const [ show , setShow ] = useState ( ( ) => ! window . localStorage . getItem ( key ) ) ;
1110
1211 useEffect ( ( ) => {
13- setShow ( ! window . localStorage . getItem ( key ) ) ;
1412 window . localStorage . setItem ( key , true ) ;
1513 } , [ ] ) ;
1614
@@ -27,7 +25,7 @@ const Privacy = () => {
2725 < Link to = "/legal/privacy" > Privacy Policy</ Link >
2826 < button
2927 type = "button"
30- ariaLabel = "Close"
28+ aria-label = "Close"
3129 onClick = { ( ) => setShow ( false ) }
3230 />
3331 </ ToastContainer >
You can’t perform that action at this time.
0 commit comments