local header, aside, footer, div, svg, script, g, circle, h1, span, b, a, img do local _obj_0 = require('mmm.dom') header, aside, footer, div, svg, script, g, circle, h1, span, b, a, img = _obj_0.header, _obj_0.aside, _obj_0.footer, _obj_0.div, _obj_0.svg, _obj_0.script, _obj_0.g, _obj_0.circle, _obj_0.h1, _obj_0.span, _obj_0.b, _obj_0.a, _obj_0.img end local navigate_to navigate_to = (require('mmm.mmmfs.util'))(require('mmm.dom')).navigate_to local get_plugins get_plugins = require('mmm.mmmfs.meta').get_plugins local pick pick = function(...) local num = select('#', ...) local i = math.ceil(math.random() * num) return (select(i, ...)) end local iconlink iconlink = function(href, src, alt, style) return a({ class = 'iconlink', target = '_blank', rel = 'me', href = href, img({ src = src, alt = alt, style = style }) }) end local logo = svg({ class = 'sun', viewBox = '-0.75 -1 1.5 2', xmlns = 'http://www.w3.org/2000/svg', baseProfile = 'full', version = '1.1', g({ transform = 'translate(0 .18)', g({ class = 'circle out', circle({ r = '.6', fill = 'none', ['stroke-width'] = '.12' }) }), g({ class = 'circle in', circle({ r = '.2', stroke = 'none' }) }) }) }) local gen_header gen_header = function() return header({ div({ h1({ navigate_to('', logo), span({ span('mmmfs', { class = 'bold' }), '', '.s‑ol.nu' }) }), "a hypermedia information system." }) }) end footer = footer({ span({ 'made with \xe2\x98\xbd by ', a('s-ol', { href = 'https://s-ol.nu' }), ", " .. tostring(os.date('%Y')) }), div({ class = 'icons', iconlink('https://github.com/s-ol', 'https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/github.svg', 'github'), iconlink('https://merveilles.town/@s_ol', 'https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/mastodon.svg', 'mastodon'), iconlink('https://twitter.com/S0lll0s', 'https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/twitter.svg', 'twitter'), iconlink('https://webring.xxiivv.com/#random', 'https://webring.xxiivv.com/icon.black.svg', 'webring', { height = '1.3em', ['margin-left'] = '.3em', ['margin-top'] = '-0.12em' }) }) }) local get_header_tags get_header_tags = function(self) local title = (self:get('title: text/plain')) or self:gett('name: alpha') local l l = function(str) str = str:gsub('[%s\n]+$', '') return str:gsub('\n', ' ') end local e e = function(str) return string.format('%q', l(str)) end local meta = "\n \n