Gathering detailed insights and metrics for quill-resize-module
Gathering detailed insights and metrics for quill-resize-module
Gathering detailed insights and metrics for quill-resize-module
Gathering detailed insights and metrics for quill-resize-module
quill-image-resize-module
A module for Quill rich text editor to allow images to be resized.
@ssumo/quill-resize-module
A module for Quill rich text editor to allow images to be resized.
quill-image-resize-module-react
A module for Quill rich text editor to allow images to be resized (with react fixes).
bc-quill-image-resize-module
A module for Quill rich text editor to allow images to be resized.
A module for Quill rich text editor to allow images and custom elements to be resized.
npm install quill-resize-module
Typescript
Module System
Node Version
NPM Version
JavaScript (94.01%)
SCSS (5.99%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
47 Stars
112 Commits
23 Forks
3 Watchers
1 Branches
7 Contributors
Updated on Jul 02, 2025
Latest Version
2.0.4
Package Id
quill-resize-module@2.0.4
Unpacked Size
123.73 kB
Size
72.21 kB
File Count
19
NPM Version
10.7.0
Node Version
18.20.4
Published on
Dec 13, 2024
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
22
A module for Quill rich text editor to allow images/iframe/video and custom elements to be resized.
This module is original forked from https://github.com/whatcould/quill-image-resize-module.
options.styles
embedTags
option for custom embed elementtools
option for custom toolbarImage resize
Embed resize (Default to iframe/video tag)
Custom any elements resize
Limit minWidth/maxWidth/minHeight/maxHeight
Limit Width/Height ratio
Selected embed element style
Direction key support
https://codesandbox.io/p/sandbox/9m9vl8
1import Quill from 'quill'; 2import QuillResize from 'quill-resize-module'; 3Quill.register('modules/resize', QuillResize); 4 5const quill = new Quill(editor, { 6 // ... 7 modules: { 8 // ... 9 resize: { 10 // See optional "config" below 11 } 12 } 13});
Copy resize.js into your web root or include from node_modules
1<script src="/node_modules/quill-resize-module/dist/resize.js"></script>
1var quill = new Quill(editor, { 2 // ... 3 modules: { 4 // ... 5 resize: { 6 // See optional "config" below 7 } 8 } 9});
For the default experience, pass an empty object, like so:
1var quill = new Quill(editor, { 2 // ... 3 modules: { 4 // ... 5 resize: {} 6 } 7});
Functionality is broken down into modules, which can be mixed and matched as you like. For example, the default is to include all modules:
1const quill = new Quill(editor, { 2 // ... 3 modules: { 4 // ... 5 resize: { 6 modules: [ 'Resize', 'DisplaySize', 'Toolbar' ] 7 } 8 } 9});
Customize the toolbar buttons with "tools" option.
For example, add handler for image alt attribute:
1const quill = new Quill(editor, { 2 // ... 3 modules: { 4 // ... 5 resize: { 6 tools: [ 7 'left', 'right', 8 { 9 text: 'Alt', 10 verify (activeEle) { 11 return (activeEle && activeEle.tagName === 'IMG') 12 }, 13 handler (evt, button, activeEle) { 14 let alt = activeEle.alt || '' 15 alt = window.prompt('Alt for image', alt) 16 if (alt == null) return 17 activeEle.setAttribute('alt', alt) 18 } 19 } 20 ] 21 } 22 } 23});
Resize
- Resize the elementAdds handles to the element's corners which can be dragged with the mouse to resize the element.
The look and feel can be controlled with options:
1var quill = new Quill(editor, { 2 // ... 3 modules: { 4 // ... 5 resize: { 6 // ... 7 // set parchment key to enable resize module 8 parchment: { 9 image: { 10 attribute: ['width'], // ['width', 'height'] 11 limit: { 12 minWidth: 200, 13 maxWidth: 600, 14 minHeight: 200, 15 maxHeight: 450, 16 ratio: .5625 // keep width/height ratio. (ratio=height/width) 17 } 18 } 19 } 20 } 21 } 22});
BaseModule
- Include your own custom moduleYou can write your own module by extending the BaseModule
class, and then including it in
the module setup.
For example,
1import QuillResize from 'quill-resize-module'; 2Quill.register('modules/resize', QuillResize); 3 4class MyModule extends QuillResize.Modules.Base { 5 // See src/modules/BaseModule.js for documentation on the various lifecycle callbacks 6} 7 8var quill = new Quill(editor, { 9 // ... 10 modules: { 11 // ... 12 resize: { 13 modules: [ MyModule, QuillResize.Modules.Resize ], 14 // ... 15 } 16 } 17});
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/30 approved changesets -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
10 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More