@@ -50,7 +50,7 @@ export default function DiscordMessagePreview(props: DiscordMessagePreviewProps)
5050
5151 return (
5252 < ThemeProvider theme = { overrideTheme } >
53- < Stack direction = "column" position = "relative" py = "0.125rem" pl = "72px" pr = "48px " minHeight = "2.75rem" >
53+ < Stack direction = "column" position = "relative" py = "0.125rem" pl = "72px" pr = "24px " minHeight = "2.75rem" overflow = "hidden ">
5454 < MessageAuthorAndContent { ...props } />
5555 { props . embed && < MessageEmbed embed = { props . embed } /> }
5656 </ Stack >
@@ -67,6 +67,7 @@ function MessageAuthorAndContent(props: Pick<DiscordMessagePreviewProps, "conten
6767 alt = "Axobot avatar"
6868 style = { {
6969 userSelect : "none" ,
70+ WebkitUserSelect : "none" ,
7071 position : "absolute" ,
7172 left : "16px" ,
7273 marginTop : "calc(4px - 0.125rem)" ,
@@ -78,7 +79,7 @@ function MessageAuthorAndContent(props: Pick<DiscordMessagePreviewProps, "conten
7879 < Typography variant = "h3" fontSize = "1rem" lineHeight = "1.375rem" pb = "1px" >
7980 < MessageAuthorAndTimestamp timestamp = { props . timestamp } />
8081 </ Typography >
81- < Stack whiteSpace = "pre-wrap" color = "#dbdee1 " >
82+ < Stack whiteSpace = "pre-wrap" color = "#efeff0 " >
8283 < DiscordMarkdown text = { props . content ?. trim ( ) } />
8384 </ Stack >
8485 </ Box >
@@ -113,10 +114,10 @@ function MessageEmbed({ embed }: { embed: Exclude<DiscordMessagePreviewProps["em
113114 } , [ embed . timestamp ] ) ;
114115
115116 return (
116- < Box display = "grid" maxWidth = "516px" my = ".125rem" borderRadius = "4px" borderLeft = { `4px solid ${ hexEmbedColor } ` } bgcolor = "#2b2d31 " >
117+ < Box display = "grid" maxWidth = "516px" my = ".125rem" borderRadius = "4px" borderLeft = { `4px solid ${ hexEmbedColor } ` } bgcolor = "#242429 " >
117118 < Box sx = { {
118119 overflow : "hidden" ,
119- padding : ".5rem 1rem 1rem .75rem" ,
120+ padding : ".125rem 1rem 1rem .75rem" ,
120121 display : "grid" ,
121122 gridTemplateColumns : "auto" ,
122123 gridTemplateRows : embed . thumbnail ? "auto min-content" : "auto" ,
@@ -139,7 +140,7 @@ function MessageEmbed({ embed }: { embed: Exclude<DiscordMessagePreviewProps["em
139140 </ Stack >
140141 ) }
141142 { embed . title && (
142- < Typography component = "div" mt = "8px" lineHeight = "1.375rem" fontWeight = { 700 } color = "#f2f3f5 " gridColumn = "1 / 1" >
143+ < Typography component = "div" mt = "8px" lineHeight = "1.375rem" fontWeight = { 600 } color = "#e3e3e6 " gridColumn = "1 / 1" >
143144 { embed . url
144145 ? (
145146 < DiscordLink href = { embed . url } target = "_blank" > { embed . title } </ DiscordLink >
@@ -150,25 +151,25 @@ function MessageEmbed({ embed }: { embed: Exclude<DiscordMessagePreviewProps["em
150151 </ Typography >
151152 ) }
152153 { embed . description && (
153- < Typography component = "div" mt = "8px" fontSize = "0.875rem" lineHeight = "1.125rem" fontWeight = { 400 } color = "#dbdee1 " whiteSpace = "pre-wrap" gridColumn = "1 / 1" >
154+ < Typography component = "div" mt = "8px" fontSize = "0.875rem" lineHeight = "1.125rem" fontWeight = { 400 } color = "#efeff0 " whiteSpace = "pre-wrap" gridColumn = "1 / 1" >
154155 < DiscordMarkdown text = { embed . description ?. trim ( ) } />
155156 </ Typography >
156157 ) }
157158 { embed . image && (
158159 < Box mt = "16px" maxWidth = "400px" maxHeight = "225px" >
159- < img style = { { userSelect : "none" , maxWidth : "100%" , maxHeight : "100%" , borderRadius : "4px" } } alt = "Image" src = { embed . image } > </ img >
160+ < img style = { { userSelect : "none" , WebkitUserSelect : "none" , maxWidth : "100%" , maxHeight : "100%" , borderRadius : "4px" } } alt = "Image" src = { embed . image } > </ img >
160161 </ Box >
161162 ) }
162163 { ( embed . footer || embed . timestamp ) && (
163- < Typography component = "span" mt = "8px" fontSize = "0.75rem" lineHeight = "1rem" fontWeight = { 500 } color = "#dbdee1 " gridColumn = "1 / 1" >
164+ < Typography component = "span" mt = "8px" fontSize = "0.75rem" lineHeight = "1rem" fontWeight = { 500 } color = "#efeff0 " gridColumn = "1 / 1" >
164165 { embed . footer ?. text }
165166 { embed . footer && timestamp && " • " }
166167 { timestamp }
167168 </ Typography >
168169 ) }
169170 { embed . thumbnail && (
170171 < Box gridRow = "1 / 8" gridColumn = "2 / 2" ml = "16px" mt = "8px" flexShrink = { 0 } justifySelf = "end" >
171- < img style = { { userSelect : "none" , maxWidth : "80px" , maxHeight : "80px" , borderRadius : "4px" } } alt = "Thumbnail" src = { embed . thumbnail } > </ img >
172+ < img style = { { userSelect : "none" , WebkitUserSelect : "none" , maxWidth : "80px" , maxHeight : "80px" , borderRadius : "4px" } } alt = "Thumbnail" src = { embed . thumbnail } > </ img >
172173 </ Box >
173174 ) }
174175 </ Box >
0 commit comments