Skip to content

Instantly share code, notes, and snippets.

@davorg
Created July 2, 2026 18:05
Show Gist options
  • Select an option

  • Save davorg/bc723fc671c950a077908e463831ed0e to your computer and use it in GitHub Desktop.

Select an option

Save davorg/bc723fc671c950a077908e463831ed0e to your computer and use it in GitHub Desktop.
Mail+ Reader Bookmarklet
javascript:(()=>{const title=document.querySelector('meta[property="mol:headline"]')?.content||document.querySelector("h1")?.textContent||document.title;const paragraphs=[...document.querySelectorAll("p.mol-para-with-font")].map(p=>p.textContent.trim()).filter(Boolean);const overlay=document.createElement("div");overlay.style.cssText="position:fixed;inset:0;z-index:999999;background:rgba(0,0,0,.55);display:flex;align-items:center;justify-content:center";const modal=document.createElement("div");modal.style.cssText="position:relative;max-width:760px;max-height:80vh;overflow:auto;background:white;color:#111;padding:28px;border-radius:8px;font:16px/1.55 system-ui,sans-serif;box-shadow:0 20px 60px rgba(0,0,0,.35)";const close=document.createElement("button");close.textContent="×";close.style.cssText="position:absolute;top:10px;right:14px;border:0;background:transparent;font-size:28px;cursor:pointer";close.onclick=()=>overlay.remove();const h1=document.createElement("h1");h1.textContent=title;modal.append(close,h1);for(const text of paragraphs){const p=document.createElement("p");p.textContent=text;p.style.margin = "1em 0 0";modal.appendChild(p)}overlay.appendChild(modal);document.body.appendChild(overlay)})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment