An HTML-only Bluesky frontend

deno task clean and add viewport meta tag

+13 -5
+9 -3
actor.ts
··· 34 34 return ` 35 35 <head> 36 36 <meta name="color-scheme" content="light dark"> 37 + <meta name="viewport" content="width=device-width, initial-scale=1"> 37 38 <title>${actor.username} (@${actor.handle}) &#8212; HTMLsky</title> 38 39 </head> 39 40 <table> ··· 48 49 </h1> 49 50 </td> 50 51 </tr> 51 - ${actor.description ? `<tr> 52 + ${ 53 + actor.description 54 + ? `<tr> 52 55 <td colspan="2"> 53 - <p>${await getDescriptionFacets(actor.description).then(res => res.replaceAll("\n", "<br>"))}</p> 56 + <p>${await getDescriptionFacets(actor.description).then((res) => 57 + res.replaceAll("\n", "<br>") 58 + )}</p> 54 59 </td> 55 60 </tr> 56 61 <tr> 57 62 <td colspan="2">&nbsp;</td> 58 63 </tr>` 59 - : ``} 64 + : `` 65 + } 60 66 <tr> 61 67 <td colspan="2"> 62 68 <b>${actor.followersCount}</b> followers
+1 -1
facets.ts
··· 1 - import { AtpAgent, RichText } from "npm:@atproto/api"; 1 + import { RichText } from "npm:@atproto/api"; 2 2 import { agent } from "./main.ts"; 3 3 4 4 export async function getDescriptionFacets(
+3 -1
main.ts
··· 31 31 } 32 32 33 33 // RAW PROFILE 34 - const rawProfilePattern = new URLPattern({ pathname: "/raw/profile/:actor/" }); 34 + const rawProfilePattern = new URLPattern({ 35 + pathname: "/raw/profile/:actor/", 36 + }); 35 37 if (rawProfilePattern.test(url)) { 36 38 const actorName = rawProfilePattern.exec(url)?.pathname.groups.actor; 37 39 const actor = new Actor(actorName);