inlay/detect
Provider dispatch shared by the public inlay API and the Lustre component.
detect_with walks the enabled providers to turn a URL into an Embed, and
render_with turns a detected Embed back into HTML. Both honour the
supplied Config.
Values
pub fn bluesky_height(config: embed.Config) -> Int
The initial component-path height for a Bluesky embed, from config with a
default of 600.
pub fn detect_with(
url: String,
config: embed.Config,
) -> option.Option(embed.Embed)
Detect an embeddable link from a URL using the given configuration.
pub fn render_inline_with(
embed: embed.Embed,
config: embed.Config,
) -> element.Element(msg)
Render a detected embed for the Lustre component path. Providers that scan
the host page with a script render nothing or clip inside a component’s
shadow root, so this renders them as self-contained iframes; every other
provider falls back to render_with. Bluesky is handled by
the component itself because it depends on the resolved DID.
pub fn render_with(
embed: embed.Embed,
config: embed.Config,
) -> element.Element(msg)
Render a detected embed as HTML using the given configuration.