ndiego / icon-block

Effortlessly add SVG icons and graphics to your website.
https://nickdiego.com/projects/icon-block/
GNU General Public License v2.0
104 stars 14 forks source link

Added the ability to insert SVG icons from the Media Library. #26

Closed ndiego closed 1 year ago

ndiego commented 1 year ago

Fixes #16

If a website has enabled SVG uploads, a new option will now show in the Icon Block that allows you to insert an SVG from the Media Library. The plugin does not enable SVG uploads itself, you will need to be using something like the Safe SVG plugin or have enabled SVGs manually.

When an SVG is inserted, the file is validated and then parsed into a string. This allows you to use all of the built-in block controls. The inserted SVG can also be edited manually in the custom SVG modal.

icon-block-1-5