tiny 88x31 lexicon for atproto
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

middleclick = open in 88x31 store

+14 -1
+13
tmpl/embedbase.html
··· 43 43 <main> 44 44 {{template "content" .}} 45 45 </main> 46 + <script> 47 + const openUri = (e) => { 48 + if (e.button === 1) { 49 + e.preventDefault() 50 + const uri = e.target.getAttribute("data-uri") 51 + window.open(`https://88x31.store/button?uri=${uri}`, "_blank") 52 + } 53 + } 54 + const buttons = document.querySelectorAll(".button") 55 + buttons.forEach((button)=>{ 56 + button.addEventListener("auxclick", openUri) 57 + }) 58 + </script> 46 59 </body> 47 60 </html>
+1 -1
tmpl/partial/buttonpart.html
··· 1 1 {{define "buttonpart"}} 2 - <a href="{{.HREF}}"> 2 + <a href="{{.HREF}}" data-uri="{{.URI}}"> 3 3 <img src="/xrpc/store.88x31.getButton?uri={{.URI}}" alt="{{.Alt}}" {{if .Title}} title="{{.Title}}"{{end}} style="display: block"/> 4 4 </a> 5 5 {{end}}