
mixin romtable(allRoms)
  div.table-responsive
    table.table.table-striped#rom-table
      thead
        tr
          th.col-device Device
          th.col-updatechannel Type
          th.col-filename Filename
          th.col-size Size
          th.col-date Date Added
      tbody
        each rom in allRoms
          tr
            - var deviceArticle = contents.devices[rom.DeviceId + '.json']
            - var timestamp = new Date(rom.createdAt).toUTCString()
            td
              a(href="#{deviceArticle.url}") #{deviceArticle.metadata.name}
              if deviceArticle.metadata.displayName
                br
                small #{deviceArticle.metadata.displayName}
            td #{rom.updateChannel}
            td
              b Download: 
              a(href="#{rom.downloadUrl}") #{rom.filename}
              br
              small md5sum: #{rom.md5sum}
            td(data-order=rom.fileSize)
              if rom.fileSize
                | #{filesize(rom.fileSize)}
              else
                i (unknown)
            td #{timestamp}


mixin romtable(allRoms)
  div.table-responsive
    table.table.table-striped#rom-table
      thead
        tr
          th.col-device Device
          th.col-updatechannel Type
          th.col-filename Filename
          th.col-size Size
          th.col-date Date Added
      tbody
        each rom in allRoms
          tr
            - var deviceArticle = contents.devices[rom.DeviceId + '.json']
            td
              a(href="#{deviceArticle.url}") #{deviceArticle.metadata.name}
              if deviceArticle.metadata.displayName
                br
                small #{deviceArticle.metadata.displayName}
            td #{rom.updateChannel}
            td
              b Download: 
              a(href="#{rom.downloadUrl}") #{rom.filename}
              br
              small md5sum: #{rom.md5sum}
            td(data-order=rom.fileSize)
              if rom.fileSize
                | #{filesize(rom.fileSize)}
              else
                i (unknown)
            - var romTimestamp = new Date(rom.createdAt)
            td(data-order=romTimestamp.toISOString())
              | #{romTimestamp.toUTCString()}

Simplify formatting the Rom's timestamp.
Website: Simplify formatting the Rom's timestamp.
