mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2025-11-08 06:16:02 +01:00
Merge branch 'develop' of https://github.com/getgrav/grav-plugin-admin into develop
This commit is contained in:
@@ -7,6 +7,9 @@
|
||||
* Fixed UI issue with Backup / Update buttons positioning
|
||||
* Tweaked placeholders color in login/new user panels [#542](https://github.com/getgrav/grav-plugin-admin/issues/542)
|
||||
1. [](#bugfix)
|
||||
* Fix some untranslated strings
|
||||
* Fix the version information after updating Grav from Admin
|
||||
* Fix a Twig autoescape issue on Plugins descriptions
|
||||
* Fix for showing empty drop-down with only one supported language [#522](https://github.com/getgrav/grav-plugin-admin/issues/522)
|
||||
* Fix for visibility toggle on new page not working [#551](https://github.com/getgrav/grav-plugin-admin/issues/551)
|
||||
|
||||
|
||||
@@ -684,7 +684,10 @@ class AdminPlugin extends Plugin
|
||||
'NOTHING_TO_SAVE',
|
||||
'FILE_UNSUPPORTED',
|
||||
'FILE_ERROR_ADD',
|
||||
'FILE_ERROR_UPLOAD'
|
||||
'FILE_ERROR_UPLOAD',
|
||||
'DROP_FILES_HERE_TO_UPLOAD',
|
||||
'DELETE',
|
||||
'INSERT'
|
||||
];
|
||||
|
||||
foreach($strings as $string) {
|
||||
|
||||
@@ -220,7 +220,6 @@ PLUGIN_ADMIN:
|
||||
DEFAULT: "Default"
|
||||
PAGE_MEDIA: "Page Media"
|
||||
OPTIONS: "Options"
|
||||
PUBLISHING: "Publishing"
|
||||
PUBLISHED: "Published"
|
||||
PUBLISHED_HELP: "By default, a page is published unless you explicitly set published: false or via a publish_date being in the future, or unpublish_date in the past"
|
||||
DATE: "Date"
|
||||
@@ -525,3 +524,9 @@ PLUGIN_ADMIN:
|
||||
FRONTMATTER_IGNORE_FIELDS_HELP: "Certain frontmatter fields may contain Twig but should not be processed, such as 'forms'"
|
||||
PACKAGE_X_INSTALLED_SUCCESSFULLY: "Package %s installed successfully"
|
||||
NEEDS_GRAV_1_1: "<i class=\"fa fa-exclamation-triangle\"></i> <strong>You are running Grav v%s</strong>. You must update to the latest <strong>Grav v1.1.x</strong> release in order to ensure compatibility. This may require switching to <strong>Testing GPM releases</strong> in the System configuration."
|
||||
ORDERING_DISABLED_BECAUSE_PARENT_SETTING_ORDER: "Parent setting order, ordering disabled"
|
||||
ORDERING_DISABLED_BECAUSE_PAGE_NOT_VISIBLE: "Page is not visible, ordering disabled"
|
||||
ORDERING_DISABLED_BECAUSE_TOO_MANY_SIBLINGS: "Ordering via the admin is unsupported because there are more than 200 siblings"
|
||||
CANNOT_ADD_MEDIA_FILES_PAGE_NOT_SAVED: "You cannot add media files until you save the page. Just click 'Save' on top"
|
||||
DROP_FILES_HERE_TO_UPLOAD: "Drop files here to upload"
|
||||
INSERT: "Insert"
|
||||
|
||||
@@ -33,6 +33,7 @@ Dropzone.confirm = (question, accepted, rejected) => {
|
||||
const DropzoneMediaConfig = {
|
||||
createImageThumbnails: { thumbnailWidth: 150 },
|
||||
addRemoveLinks: false,
|
||||
dictDefaultMessage: translations.PLUGIN_ADMIN.DROP_FILES_HERE_TO_UPLOAD,
|
||||
dictRemoveFileConfirmation: '[placeholder]',
|
||||
previewTemplate: `
|
||||
<div class="dz-preview dz-file-preview">
|
||||
@@ -45,8 +46,8 @@ const DropzoneMediaConfig = {
|
||||
<div class="dz-success-mark"><span>✔</span></div>
|
||||
<div class="dz-error-mark"><span>✘</span></div>
|
||||
<div class="dz-error-message"><span data-dz-errormessage></span></div>
|
||||
<a class="dz-remove" href="javascript:undefined;" data-dz-remove>Delete</a>
|
||||
<a class="dz-insert" href="javascript:undefined;" data-dz-insert>Insert</a>
|
||||
<a class="dz-remove" href="javascript:undefined;" data-dz-remove>${translations.PLUGIN_ADMIN.DELETE}</a>
|
||||
<a class="dz-insert" href="javascript:undefined;" data-dz-insert>${translations.PLUGIN_ADMIN.INSERT}</a>
|
||||
</div>`.trim()
|
||||
};
|
||||
|
||||
|
||||
28
themes/grav/js/admin.min.js
vendored
28
themes/grav/js/admin.min.js
vendored
File diff suppressed because one or more lines are too long
30
themes/grav/js/vendor.min.js
vendored
30
themes/grav/js/vendor.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -1,7 +1,6 @@
|
||||
{% set value = (value is null ? field.default : value) %}
|
||||
{% set siblings = data.parent.children.visible %}
|
||||
|
||||
|
||||
<div class="form-field grid pure-g">
|
||||
<div class="form-label block size-1-3 pure-u-1-3">
|
||||
<label>
|
||||
@@ -23,9 +22,9 @@
|
||||
name="{{ (scope ~ field.name)|fieldName }}"
|
||||
value="{{ canReorder ? value : '' }}" />
|
||||
{% if data.parent.header.content.items %}
|
||||
<span class="note">Parent setting order, ordering disabled</span>
|
||||
<span class="note">{{ "PLUGIN_ADMIN.ORDERING_DISABLED_BECAUSE_PARENT_SETTING_ORDER"|tu }}</span>
|
||||
{% elseif not data.visible %}
|
||||
<span class="note">Page is not visible, ordering disabled</span>
|
||||
<span class="note">{{ "PLUGIN_ADMIN.ORDERING_DISABLED_BECAUSE_PAGE_NOT_VISIBLE"|tu }}</span>
|
||||
{% endif %}
|
||||
|
||||
{% if siblings|length < 200 %}
|
||||
@@ -35,7 +34,7 @@
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% else %}
|
||||
<span class="note">Ordering via the admin is unsupported because there are more than 200 siblings</span>
|
||||
<span class="note">{{ "PLUGIN_ADMIN.ORDERING_DISABLED_BECAUSE_TOO_MANY_SIBLINGS"|tu }}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<div class="form-field">
|
||||
<div class="form-label">
|
||||
<label>
|
||||
You cannot add media files until you save the page. Just click 'Save' on top
|
||||
{{ "PLUGIN_ADMIN.CANNOT_ADD_MEDIA_FILES_PAGE_NOT_SAVED"|tu }}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user