Sha256: be353939ef95dd18b286bbfceaf1b820e9d47479be3d015578902d50ab832d0a

Contents?: true

Size: 900 Bytes

Versions: 2

Compression:

Stored size: 900 Bytes

Contents

(function() {
  var locked_page_icon_content
  var locked_page_tab = document.querySelector('#locked_page_<%= @page.id -%>')
  var locked_page_icon = document.querySelector(
    '#page_<%= @page.id -%> > .sitemap_page > .sitemap_left_images .like-hint-tooltip'
  ) || document.querySelector('[data-page-id="<%= @page.id -%>"] i.icon')
  if (locked_page_tab) {
    locked_page_tab.remove()
  }
  if (locked_page_icon) {
    if (locked_page_icon.parentElement.classList.contains("handle")) {
      locked_page_icon_content = '<span class="handle"><alchemy-icon name="file" size="xl"></alchemy-icon></span>'
    } else {
      locked_page_icon_content = '<alchemy-icon name="file" size="xl"></alchemy-icon>'
    }
    locked_page_icon.outerHTML = locked_page_icon_content
  }
  document.querySelector("#page_<%= @page.id -%> .page_status.locked").remove()
  Alchemy.growl('<%= flash[:notice] -%>')
})()

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
alchemy_cms-7.2.2 app/views/alchemy/admin/pages/unlock.js.erb
alchemy_cms-7.2.1 app/views/alchemy/admin/pages/unlock.js.erb