* add bskyembed vite app * create build script (temp until embedr is ready) * add build output to web build * simplify post-build step by copying everything at once * add simple post viewer * add butterfly logo * add vite plugin legacy * proper error screen * add image embed * add url embed * record embed + embedwithmedia * add list+feed embeds * add labeller embed (just to be safe) * fix curatelist and modlist being the wrong way around * Add PWI opt-out * add favicon * improve wording of PWI * remove padding I used for screenshots * add disabled state to embed * improve PWI styles by adding an icon * remove unused prop * rm open proxy * [Embeds] Add CTA and add general polish - input needed! (#3454) * add CTA, colourful icons, and bigger logo * make hover effect smaller + add to cta * more responsive + preserve whitespace * add trailing newsline to deploy script * add repost indicator * Make butterfly link to content * More consistent error text wording --------- Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
21 lines
451 B
TypeScript
21 lines
451 B
TypeScript
import {h} from 'preact'
|
|
|
|
export function Link({
|
|
href,
|
|
className,
|
|
...props
|
|
}: {
|
|
href: string
|
|
className?: string
|
|
} & h.JSX.HTMLAttributes<HTMLAnchorElement>) {
|
|
return (
|
|
<a
|
|
href={href.startsWith('http') ? href : `https://bsky.app${href}`}
|
|
target="_blank"
|
|
rel="noopener noreferrer nofollow"
|
|
onClick={evt => evt.stopPropagation()}
|
|
className={`cursor-pointer ${className || ''}`}
|
|
{...props}
|
|
/>
|
|
)
|
|
}
|