@@ -5,9 +5,8 @@ import { Link } from '../ui/Link';
55import { styled } from '../stitches.config' ;
66
77const PseudoClassButton = styled ( 'button' , {
8- display : 'block ' ,
8+ height : '100% ' ,
99 padding : '8px 20px' ,
10- marginTop : '18px' ,
1110 textAlign : 'center' ,
1211 backgroundColor : '$formElementsBackground' ,
1312 border : '1px solid' ,
@@ -24,9 +23,8 @@ const PseudoClassButton = styled('button', {
2423} ) ;
2524
2625const InteractiveButton = styled ( Interactive . Button , {
27- display : 'block ' ,
26+ height : '100% ' ,
2827 padding : '8px 20px' ,
29- marginTop : '18px' ,
3028 textAlign : 'center' ,
3129 backgroundColor : '$formElementsBackground' ,
3230 border : '1px solid' ,
@@ -46,9 +44,13 @@ const InteractiveButton = styled(Interactive.Button, {
4644} ) ;
4745
4846const ButtonsContainer = styled ( 'div' , {
49- display : 'flex' ,
50- gap : '15px' ,
5147 marginTop : '15px' ,
48+ display : 'grid' ,
49+ gridTemplateColumns : 'auto auto' ,
50+ gridTemplateRows : 'auto auto' ,
51+ gridAutoFlow : 'column' ,
52+ gridColumnGap : '18px' ,
53+ gridRowGap : '18px' ,
5254} ) ;
5355
5456export const CssStickyHoverBug : React . VFC = ( ) => {
@@ -65,18 +67,18 @@ export const CssStickyHoverBug: React.VFC = () => {
6567 until you tap someplace else on the screen.
6668 </ p >
6769 < ButtonsContainer >
70+ < p >
71+ Button styled with pseudo-classes, < code > :hover</ code > is green,{ ' ' }
72+ < code > :active</ code > is red.
73+ </ p >
6874 < div >
69- < p >
70- Button styled with pseudo-classes, < code > :hover</ code > is green,{ ' ' }
71- < code > :active</ code > is red.
72- </ p >
7375 < PseudoClassButton > Pseudo-class Button</ PseudoClassButton >
7476 </ div >
77+ < p >
78+ Button styled with React Interactive, < code > .hover</ code > is green,{ ' ' }
79+ < code > .active</ code > is red.
80+ </ p >
7581 < div >
76- < p >
77- Button styled with React Interactive, < code > .hover</ code > is green,{ ' ' }
78- < code > .active</ code > is red.
79- </ p >
8082 < InteractiveButton
8183 // useExtendedTouchActive to match css :active functionality
8284 // which stays in the :active state as long a the touch point is on the screen,
0 commit comments