views

dates = recordings.reduce((acc, v) => {acc[v.displayName.slice(5)] = v.id; return acc}, {})

[...document.querySelectorAll('table.mw-collapsible')].slice(1)
  .map(table => ({
      node: table,
      rows: [...table.querySelectorAll('tr')]
          .map(tr => {
              try {
                const id = [...tr.children].toReversed()[0].innerText.slice(1)
                const date = dates[id] 
                const gif = tr.querySelector('img').src
                const caption = tr.children[0].innerText ? (tr.children[0].innerHTML.trim() + "\n\n") : ""
                const gaq = `https://view.gaq9.com/api/view/video/${date}`
                // return {id, date, caption}
                return `## \\#${id}: ${date}\n\n${caption}![](${gif})\n\n<${gaq}>\n`
              } catch (e) { console.error(e); return "`" + tr.innerHTML + "``"}
          }),
      title: table.querySelector('caption').childNodes[0].textContent.trim()
  })) // [0]
  .map(o => `# ${o.title.replace(/[:#]/g, '')}\n\n${o.rows.join('\n')}`)
  .join('\n')

#todo shadow cone following the Utah Teapot?