1- import { css } from '@emotion/react' ;
2-
31import { Modal } from '@/ui/elements/Modal' ;
42import { InternalThemeProvider } from '@/ui/styledSystem' ;
53
6- import { Button , Flex } from '../../customizables' ;
7- import { Portal } from '../../elements/Portal' ;
8-
9- const baseElementStyles = css `
10- box-sizing : border-box;
11- padding : 0 ;
12- margin : 0 ;
13- background : none;
14- border : none;
15- line-height : 1.5 ;
16- font-family :
17- -apple-system,
18- BlinkMacSystemFont,
19- avenir next,
20- avenir,
21- segoe ui,
22- helvetica neue,
23- helvetica,
24- Cantarell,
25- Ubuntu,
26- roboto,
27- noto,
28- arial,
29- sans-serif;
30- text-decoration : none;
31- ` ;
32-
33- const mainCTAStyles = css `
34- ${ baseElementStyles } ;
35- dis play: flex;
36- align- items: center;
37- justify- content: center;
38- width: 100%;
39- height: 1.75rem;
40- max- width: 14.625rem;
41- padding: 0.25rem 0.625rem;
42- bor der- radius: 0.375rem;
43- font- size: 0.75rem;
44- font- weight: 500;
45- letter- spacing: 0.12px;
46- color : 'white' ;
47- text- shadow: 0px 1px 2px rgba(0, 0, 0, 0.32);
48- white-space: nowrap;
49- user- select: none;
50- cursor : pointer;
51- background: linear- gradient(180deg, rgba (0, 0, 0, 0) 30.5%, rgba (0, 0, 0, 0.05) 100%), # 454545;
52- box- shadow:
53- 0px 0px 0px 1px rgba(255, 255, 255, 0.04) inset,
54- 0px 1px 0px 0px rgba(255, 255, 255, 0.04) inset,
55- 0px 0px 0px 1px rgba(0, 0, 0, 0.12),
56- 0px 1.5px 2px 0px rgba(0, 0, 0, 0.48),
57- 0px 0px 4px 0px rgba(243, 107, 22, 0) inset;
58- ` ;
4+ import { Button , Flex } from '../../../customizables' ;
5+ import { Portal } from '../../../elements/Portal' ;
6+ import { basePromptElementStyles , PromptContainer } from '../shared' ;
597
608type EnableOrganizationsPromptProps = {
619 callerString : string ;
@@ -68,25 +16,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
6816 canCloseModal = { false }
6917 contentSx = { ( ) => ( { animation : 'unset' } ) }
7018 >
71- < Flex
72- sx = { t => ( {
73- position : 'fixed' ,
74- top : '50%' ,
75- left : '50%' ,
76- transform : 'translate(-50%, -50%)' ,
77- flexDirection : 'column' ,
78- gap : t . space . $1 ,
79- width : 'fit-content' ,
80- maxWidth : '25rem' ,
81- borderRadius : '1.25rem' ,
82- overflow : 'hidden' ,
83- fontFamily : t . fonts . $main ,
84- background : 'linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 100%), #1f1f1f' ,
85- boxShadow :
86- '0px 0px 0px 0.5px #2F3037 inset, 0px 1px 0px 0px rgba(255, 255, 255, 0.08) inset, 0px 0px 0.8px 0.8px rgba(255, 255, 255, 0.20) inset, 0px 0px 0px 0px rgba(255, 255, 255, 0.72), 0px 16px 36px -6px rgba(0, 0, 0, 0.36), 0px 6px 16px -2px rgba(0, 0, 0, 0.20);' ,
87- transition : 'all 195ms cubic-bezier(0.2, 0.61, 0.1, 1)' ,
88- } ) }
89- >
19+ < PromptContainer >
9020 < Flex
9121 sx = { t => ( {
9222 display : 'flex' ,
@@ -137,7 +67,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
13767
13868 < h1
13969 css = { css `
140- ${ baseElementStyles } ;
70+ ${ basePromptElementStyles } ;
14171 color : white;
14272 font- size: 0.9rem;
14373 font- weight: 500;
@@ -149,7 +79,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
14979
15080 < p
15181 css = { css `
152- ${ baseElementStyles } ;
82+ ${ basePromptElementStyles } ;
15383 color : # c3c3c6 ;
15484 font- size: 0.88rem;
15585 font- weight: 400;
@@ -159,7 +89,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
15989 To use the{ ' ' }
16090 < code
16191 css = { css `
162- ${ baseElementStyles } ;
92+ ${ basePromptElementStyles } ;
16393 color : white;
16494 ` }
16595 >
@@ -173,7 +103,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
173103 < br />
174104 < a
175105 css = { css `
176- ${ baseElementStyles } ;
106+ ${ basePromptElementStyles } ;
177107 color : # a8a8ff ;
178108 font- size: inherit;
179109 font- weight: 500;
@@ -217,7 +147,7 @@ const EnableOrganizationsPromptInternal = (_props: EnableOrganizationsPromptProp
217147 I'll remove it myself
218148 </ Button >
219149 </ Flex >
220- </ Flex >
150+ </ PromptContainer >
221151 </ Modal >
222152 </ Portal >
223153 ) ;
0 commit comments