- context.content_for(:title, "Bookmark | ")

div class="mb-12 prose dark:prose-invert max-w-prose mx-auto text-gray-800 dark:text-gray-200"
  h1 = bookmark.name

div class="mb-12 prose dark:prose-invert max-w-prose mx-auto text-gray-800 dark:text-gray-200" x-data="{ open: false }"
  a class="text-blue-600 no-underline hover:underline" href=bookmark.url
    p class="text-xl text-ellipsis overflow-hidden"
      = bookmark.url

  == bookmark.content

  - unless bookmark.cached_content.nil?
    button class="hover:text-gray-400" @click="open = ! open" Toggle reader version

    span x-show="open"
      div class="mt-4 rounded bg-blue-50 dark:bg-blue-900 px-4 py-2"
        == bookmark.cached_content

div class="prose max-w-prose mx-auto text-gray-800 dark:text-gray-200 grid grid-cols-5 gap-2" hx-get="/bookmarks/metadata/#{bookmark.id}" hx-trigger="load"

div class="mb-8 max-w-screen-md mx-auto border-t-4 border-solid border-gray-400 dark:border-gray-600"


div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
  div class=""
    = "Published "
    time class="dt-published" datetime=bookmark.machine_published_at
      = bookmark.display_published_at
    p
      span in&nbsp;
      a class="hover:underline" href="/bookmarks" bookmarks

  span class="text-right flex-1"
    == render "shared/tags", tags: bookmark.tags

div class="mb-2 max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
  - if bookmark.syndicated?
    span Also on: &nbsp;
    - bookmark.syndicated_to.each do |loc|
      a href=loc[:url]
        == "shared/#{render loc[:location]}"
