@@ -61,10 +61,6 @@ export const onboardingVars = {
61
61
nextButtonShowUpDelay : '20s' ,
62
62
} ,
63
63
} ;
64
- export const perspective = style ( {
65
- perspective : '10000px' ,
66
- transformStyle : 'preserve-3d' ,
67
- } ) ;
68
64
export const fadeIn = keyframes ( {
69
65
from : {
70
66
opacity : 0 ,
@@ -73,38 +69,39 @@ export const fadeIn = keyframes({
73
69
opacity : 1 ,
74
70
} ,
75
71
} ) ;
76
- export const onboarding = style ( [
77
- perspective ,
78
- {
79
- width : '100vw' ,
80
- height : '100vh' ,
81
- display : 'flex' ,
82
- alignItems : 'center' ,
83
- justifyContent : 'center' ,
84
- position : 'relative' ,
85
- selectors : {
86
- // hack background color for web
87
- '&::after' : {
88
- content : '' ,
89
- position : 'absolute' ,
90
- inset : 0 ,
91
- background : onboardingVars . web . bg ,
92
- transform : 'translateZ(-1000px) scale(2)' ,
93
- transition : 'opacity 0.3s ease' ,
94
- } ,
95
- '&[data-is-desktop="true"]::after' : {
96
- animation : `${ fadeIn } 0.8s linear` ,
97
- // content: 'unset',
98
- background :
99
- 'linear-gradient(180deg, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 99.58%)' ,
100
- } ,
101
- '&[data-is-window="true"][data-is-desktop="true"]::after' : {
102
- opacity : 0 ,
103
- } ,
72
+ export const onboarding = style ( {
73
+ width : '100vw' ,
74
+ height : '100vh' ,
75
+ display : 'flex' ,
76
+ alignItems : 'center' ,
77
+ justifyContent : 'center' ,
78
+ position : 'relative' ,
79
+ selectors : {
80
+ '&[data-is-window="false"]' : {
81
+ perspective : '10000px' ,
82
+ transformStyle : 'preserve-3d' ,
83
+ } ,
84
+ // hack background color for web
85
+ '&::after' : {
86
+ content : '' ,
87
+ position : 'absolute' ,
88
+ inset : 0 ,
89
+ background : onboardingVars . web . bg ,
90
+ transform : 'translateZ(-1000px) scale(2)' ,
91
+ transition : 'opacity 0.3s ease' ,
92
+ } ,
93
+ '&[data-is-desktop="true"]::after' : {
94
+ animation : `${ fadeIn } 0.8s linear` ,
95
+ // content: 'unset',
96
+ background :
97
+ 'linear-gradient(180deg, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 99.58%)' ,
98
+ } ,
99
+ '&[data-is-window="true"][data-is-desktop="true"]::after' : {
100
+ opacity : 0 ,
104
101
} ,
105
102
} ,
106
- ] ) ;
107
- globalStyle ( `${ onboarding } *` , {
103
+ } ) ;
104
+ globalStyle ( `${ onboarding } [data-is-window="false"] *` , {
108
105
perspective : '10000px' ,
109
106
transformStyle : 'preserve-3d' ,
110
107
} ) ;
@@ -146,3 +143,7 @@ globalStyle(`${tipsWrapper} > *`, {
146
143
globalStyle ( `${ tipsWrapper } [data-visible="true"] > *` , {
147
144
pointerEvents : 'auto' ,
148
145
} ) ;
146
+ // transparent background for onboarding window
147
+ globalStyle ( `:root` , {
148
+ backgroundColor : 'transparent' ,
149
+ } ) ;
0 commit comments