mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2025-11-18 11:10:56 +01:00
Page media and File field images thumbnail are now properly proportionate and 150x100
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
* Add an `onAdminData` event to allow plugins to add additional blueprints data
|
||||
1. [](#improved)
|
||||
* Handle errors when a resource fails to install
|
||||
* Page media and File field images thumbnail are now properly proportionate and 150x100
|
||||
1. [](#bugfix)
|
||||
* Fix [#1034](https://github.com/getgrav/grav/issues/1034) redirect of page creation procedure when system.home.hide_in_urls is enabled
|
||||
* Media (Page): Do not extend parent metehod for sending files since Safari and IE API for FormData don’t implement `delete` ([#772](https://github.com/getgrav/grav-plugin-admin/issues/772))
|
||||
|
||||
@@ -69,7 +69,7 @@ export default class FilePickerField {
|
||||
|
||||
let renderOption = function renderOption(item, escape) {
|
||||
let image = '';
|
||||
if (imagesPreview && folder && item.status == 'available' && item.name.match(/\.(jpg|jpeg|png|gif)$/i)) {
|
||||
if (imagesPreview && folder && item.status === 'available' && item.name.match(/\.(jpg|jpeg|png|gif)$/i)) {
|
||||
image = `
|
||||
<img class="filepicker-field-image"
|
||||
src="${config.base_url_relative}/../${folder}/${item.name}"/>`;
|
||||
|
||||
@@ -46,7 +46,9 @@ Dropzone.confirm = (question, accepted, rejected) => {
|
||||
};
|
||||
|
||||
const DropzoneMediaConfig = {
|
||||
createImageThumbnails: { thumbnailWidth: 150 },
|
||||
createImageThumbnails: { },
|
||||
thumbnailWidth: 150,
|
||||
thumbnailHeight: 100,
|
||||
addRemoveLinks: false,
|
||||
dictDefaultMessage: translations.PLUGIN_ADMIN.DROP_FILES_HERE_TO_UPLOAD,
|
||||
dictRemoveFileConfirmation: '[placeholder]',
|
||||
|
||||
2
themes/grav/css-compiled/template.css
vendored
2
themes/grav/css-compiled/template.css
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
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
@@ -1,7 +1,7 @@
|
||||
/* The MIT License */
|
||||
|
||||
$preview-width: 150px;
|
||||
$preview-height: 150px;
|
||||
$preview-height: 100px;
|
||||
|
||||
.dropzone {
|
||||
position: relative;
|
||||
|
||||
Reference in New Issue
Block a user