rwaldron / blocks-url-preview

Click a URL in a record to view its content in a block.

Home Page:https://airtable.com/developers/blocks

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

URL preview block

When the user selects a record in grid view, this block gets a preview URL from the record and shows the corresponding preview. This block supports previews from the following services: YouTube, Vimeo, Spotify, Soundcloud, and Figma.

The code shows:

  • How to use the Cursor API to detect when a user has selected a record in grid view, and how to get the selected record.

  • How to embed content in a block.

How to run this block

  1. Copy this base.

  2. Create a new block in your new base (see Create a new block, selecting "URL preview" as your template.

  3. From the root of your new block, run block run.

See the block running

Block showing YouTube video when user selects record in grid view

About

Click a URL in a record to view its content in a block.

https://airtable.com/developers/blocks

License:MIT License


Languages

Language:JavaScript 100.0%