Skip to content

Commit 0c8fd96

Browse files
authored
minor: delete unused cta prop on Message (#3236)
In #3226 I realize we can do this directly in the `content` prop. If we decide we want it to look that way all the time, we can bring this prop back.
1 parent f9366d3 commit 0c8fd96

1 file changed

Lines changed: 1 addition & 22 deletions

File tree

app/ui/lib/Message.tsx

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,8 @@
77
*/
88
import cn from 'classnames'
99
import type { ReactElement, ReactNode } from 'react'
10-
import { Link, type To } from 'react-router'
1110

12-
import {
13-
Error12Icon,
14-
OpenLink12Icon,
15-
Success12Icon,
16-
Warning12Icon,
17-
} from '@oxide/design-system/icons/react'
11+
import { Error12Icon, Success12Icon, Warning12Icon } from '@oxide/design-system/icons/react'
1812

1913
type Variant = 'success' | 'error' | 'notice' | 'info'
2014

@@ -23,10 +17,6 @@ export interface MessageProps {
2317
content: ReactNode
2418
className?: string
2519
variant?: Variant
26-
cta?: {
27-
text: string
28-
link: To
29-
}
3020
showIcon?: boolean
3121
}
3222

@@ -50,7 +40,6 @@ export const Message = ({
5040
content,
5141
className,
5242
variant = 'info',
53-
cta,
5443
showIcon = true,
5544
}: MessageProps) => {
5645
return (
@@ -73,16 +62,6 @@ export const Message = ({
7362
<div className="text-sans-md text-accent-secondary [&>a]:tint-underline group max-w-3xl">
7463
{content}
7564
</div>
76-
77-
{cta && (
78-
<Link
79-
className="text-sans-md text-accent-secondary hover:text-accent mt-1 flex items-center underline"
80-
to={cta.link}
81-
>
82-
{cta.text}
83-
<OpenLink12Icon className="ml-1" />
84-
</Link>
85-
)}
8665
</div>
8766
</div>
8867
)

0 commit comments

Comments
 (0)