Expand description
The preview of a web page a note links to: a card under the note with the picture the page is shared with, the site it is on, its title and a few words about it. A click opens the page.
The card is as tall for one page as for another, and as tall while the page is being asked as when it has answered: a row doesn’t change height because a preview arrived, or its picture did. A page with nothing to say for itself gets no card, and the room kept for one is given back.
A link that answered as a video is no page: its card offers to play it,
and pressed, gives way to the video (see
video_box).
Constants§
- PREVIEW_
DESCRIPTION_ 🔒LINES - How many lines of a page’s description the card shows.
- PREVIEW_
DIM 🔒 - How much dimmer than the text the site and the description are.
- PREVIEW_
PADDING 🔒 - The room between the card’s edge and what it says, and between the lines it says it in.
- PREVIEW_
SPACING 🔒
Functions§
- cut_
line 🔒 - One line of the card, cut where the card ends rather than wrapped.
- link_
preview - The preview of the page at
url, for under the note that links to it: the card, once the page has said what it is; the room the card will take, until then; and nothing, if the page has nothing to say. - link_
preview_ height - How tall the preview of a link is in a row set in
sizes, whatever the page says: the site, the title and the lines of description, and the room around them. - video_
offer 🔒 - The card of a link that turned out to be a video: as tall as any preview, saying what it is and where, and playing it when it is pressed.