diff --git a/djangocms_versioning_filer/static/djangocms_versioning_filer/css/admin_filer_list_actions.css b/djangocms_versioning_filer/static/djangocms_versioning_filer/css/admin_filer_list_actions.css index d5451be..1aa82fe 100644 --- a/djangocms_versioning_filer/static/djangocms_versioning_filer/css/admin_filer_list_actions.css +++ b/djangocms_versioning_filer/static/djangocms_versioning_filer/css/admin_filer_list_actions.css @@ -71,6 +71,10 @@ extending the pagetree classes provided by CMS /* style for each option row */ +td.column-action a.action-button { + margin-right: 4px !important; +} + ul.cms-actions-dropdown-menu-inner { margin: 0; padding: 0 !important; @@ -115,10 +119,17 @@ a.cms-actions-dropdown-menu-item-anchor:link:active { } /* align the option text with it's icon */ +a.cms-actions-dropdown-menu-item-anchor { + display: flex; + align-items: center; + gap: 1rem; +} + a.cms-actions-dropdown-menu-item-anchor span { - line-height: 1rem; - vertical-align: 20%; - margin-left: 10px; + line-height: 1rem !important; + width: auto !important; + height: auto !important; + margin: 0 !important; } /* disable any inactive option */ a.cms-actions-dropdown-menu-item-anchor.inactive { diff --git a/djangocms_versioning_filer/static/djangocms_versioning_filer/js/admin_filer_list_actions.js b/djangocms_versioning_filer/static/djangocms_versioning_filer/js/admin_filer_list_actions.js index 9bf930e..49caff4 100644 --- a/djangocms_versioning_filer/static/djangocms_versioning_filer/js/admin_filer_list_actions.js +++ b/djangocms_versioning_filer/static/djangocms_versioning_filer/js/admin_filer_list_actions.js @@ -9,14 +9,14 @@ function createBurgerMenu(row) { let actions = $(row).children('.column-action'); - if (!actions.length || !$(actions[0]).children('.action-button').length) { + if (!actions.length || !$(actions[0]).children('.action-button:not(.top-level)').length) { /* skip any rows without actions to avoid errors */ return; } /* create burger menu anchor icon */ let icon = document.createElement('span'); - icon.setAttribute('class', "fa fa-bars"); + icon.setAttribute('class', "cms-icon cms-icon-settings"); let anchor = document.createElement('a'); anchor.setAttribute('class', 'action-button cms-filer-action-btn closed'); @@ -35,7 +35,7 @@ ul.setAttribute('class', 'cms-actions-dropdown-menu-inner'); /* get the existing actions and move them into the options container */ - $(actions[0]).children('.action-button').each(function (index, item) { + $(actions[0]).children('.action-button:not(.top-level)').each(function (index, item) { let li = document.createElement('li'); /* create an anchor from the item */ diff --git a/djangocms_versioning_filer/templates/admin/filer/folder/directory_listing.html b/djangocms_versioning_filer/templates/admin/filer/folder/directory_listing.html index 2264b4f..0fa00d9 100644 --- a/djangocms_versioning_filer/templates/admin/filer/folder/directory_listing.html +++ b/djangocms_versioning_filer/templates/admin/filer/folder/directory_listing.html @@ -161,7 +161,7 @@

 

- +
{% filer_admin_context_hidden_formfields %} diff --git a/djangocms_versioning_filer/templates/admin/filer/folder/directory_table.html b/djangocms_versioning_filer/templates/admin/filer/folder/directory_table.html index fee3d6e..2c1636a 100644 --- a/djangocms_versioning_filer/templates/admin/filer/folder/directory_table.html +++ b/djangocms_versioning_filer/templates/admin/filer/folder/directory_table.html @@ -79,7 +79,7 @@ {% if subfolder.file_type == "Folder" %} - + {% endif %} diff --git a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/edit.html b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/edit.html index d8995ea..2e249f5 100644 --- a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/edit.html +++ b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/edit.html @@ -10,19 +10,16 @@ {% spaceless %} - + {% endspaceless %} diff --git a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/manage_versions.html b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/manage_versions.html index 5e0312e..94a0eb5 100644 --- a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/manage_versions.html +++ b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/action_buttons/manage_versions.html @@ -1,4 +1,4 @@ {% load i18n %} \ No newline at end of file + title="{% blocktrans %}Manage versions{% endblocktrans %}" class="action-button"> diff --git a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/directory_table_actions.html b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/directory_table_actions.html index 850ce4b..303b13a 100644 --- a/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/directory_table_actions.html +++ b/djangocms_versioning_filer/templates/djangocms_versioning_filer/admin/directory_table_actions.html @@ -1,11 +1,13 @@ {% load i18n djangocms_versioning_filer_tags %} +{% spaceless %} + title="{% blocktrans %}Link{% endblocktrans %}" class="action-button" target="_blank"> + title="{% blocktrans %}Download{% endblocktrans %}" class="action-button"> {% get_versioning_filer_admin_actions as admin_actions %} {% for template_name in admin_actions %} {% include template_name %} {% endfor %} +{% endspaceless %}