Download the PHP package humanmade/smart-media without Composer
On this page you can find all versions of the php package humanmade/smart-media. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download humanmade/smart-media
More information about humanmade/smart-media
Files in humanmade/smart-media
Package smart-media
Short Description Smart Media features for HM Cloud
License GPL-3.0
Informations about the package smart-media
Smart Media Enhanced media library features for WordPress. |
|
A Human Made project. Maintained by @roborourke. |
Smarter media features for WordPress.
Some features in this plugin will work on their own however some are designed to augment the existing tools we use such as Tachyon.
Features
Justified media library
The media library shows square thumbnails by default which can make it harder to find the right image. This feature makes the thumbnails keep their original aspect ratio, similar to the UI of Flickr.
To disable the feature add the following:
Image editor
This feature overrides the built in WordPress image editing experience and gives you control over the crops of individual thumbs. There are also some UX improvements meaning there are fewer clicks required to make edits.
To disable the feature add the following:
The image cropping UI provides support for updating Gutenberg block attributes based on the current selection using the following filters:
smartmedia.cropper.updateBlockAttributesOnSelect.<block name>
smartmedia.cropper.selectSizeFromBlockAttributes.<block name>
In the above filters <block name>
should be replaced a dot separated version of your block name, for example core/image
becomes core.image
. The core image block attributes are mapped by default.
Mapping the selected image to block attributes:
Update the cropping UI selected size based on selected block attributes:
The function takes 2 parameters:
block
: The name of the block to map attributes forcallback
: A function that accepts the imagesize
name, animage
object containingurl
,width
,height
, crop data and label for the image size, and lastly the fullattachment
data object.
The callback should return an object or null
. Passing null
will prevent updating the currently selected block.
Roadmap
Planned features include:
- Duplicate image detection and consolidation
- EXIF data editor
Contributing
First of all thanks for using this plugin and thanks for contributing!
To get started check out the contributing documentation.