{"id":19431413,"url":"https://github.com/devhau/quill-image-module","last_synced_at":"2025-10-26T10:10:12.879Z","repository":{"id":41373224,"uuid":"508998144","full_name":"devhau/quill-image-module","owner":"devhau","description":null,"archived":false,"fork":false,"pushed_at":"2022-07-01T04:49:02.000Z","size":46,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-05T09:48:06.735Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devhau.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-06-30T08:35:08.000Z","updated_at":"2022-07-04T06:39:22.000Z","dependencies_parsed_at":"2022-08-22T12:40:34.486Z","dependency_job_id":null,"html_url":"https://github.com/devhau/quill-image-module","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/devhau/quill-image-module","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devhau%2Fquill-image-module","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devhau%2Fquill-image-module/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devhau%2Fquill-image-module/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devhau%2Fquill-image-module/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devhau","download_url":"https://codeload.github.com/devhau/quill-image-module/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devhau%2Fquill-image-module/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274231438,"owners_count":25245585,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-08T02:00:09.813Z","response_time":121,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T14:29:33.233Z","updated_at":"2025-10-26T10:10:12.786Z","avatar_url":"https://github.com/devhau.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Quill Image Module\n\nA module for Quill rich text editor to allow images control.\n\n## Demo\n\n## Usage\n\n### Webpack/ES6\n\n```javascript\nimport Quill from \"quill\";\nimport { ImageResize } from \"quill-image-module\";\n\nQuill.register(\"modules/imageResize\", ImageResize);\n\nconst quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\timageResize: {\n\t\t\t// See optional \"config\" below\n\t\t},\n\t},\n});\n```\n\n### Script Tag\n\nCopy image-module.min.js into your web root or include from node_modules\n\n```html\n\u003cscript src=\"/node_modules/quill-image-module/image-module.min.js\"\u003e\u003c/script\u003e\n```\n\n```javascript\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\t// See optional \"config\" below\n\t\t},\n\t},\n});\n```\n\n### Config\n\nFor the default experience, pass an empty object, like so:\n\n```javascript\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {},\n\t},\n});\n```\n\nFunctionality is broken down into modules, which can be mixed and matched as you like. For example,\nthe default is to include all modules:\n\n```javascript\nconst quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\tmodules: [\"Resize\", \"DisplaySize\", \"Toolbar\"],\n\t\t},\n\t},\n});\n```\n\nEach module is described below.\n\n#### `Resize` - Resize the image\n\nAdds handles to the image's corners which can be dragged with the mouse to resize the image.\n\nThe look and feel can be controlled with options:\n\n```javascript\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\t// ...\n\t\t\thandleStyles: {\n\t\t\t\tbackgroundColor: \"black\",\n\t\t\t\tborder: \"none\",\n\t\t\t\tcolor: white,\n\t\t\t\t// other camelCase styles for size display\n\t\t\t},\n\t\t},\n\t},\n});\n```\n\n#### `DisplaySize` - Display pixel size\n\nShows the size of the image in pixels near the bottom right of the image.\n\nThe look and feel can be controlled with options:\n\n```javascript\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\t// ...\n\t\t\tdisplayStyles: {\n\t\t\t\tbackgroundColor: \"black\",\n\t\t\t\tborder: \"none\",\n\t\t\t\tcolor: white,\n\t\t\t\t// other camelCase styles for size display\n\t\t\t},\n\t\t},\n\t},\n});\n```\n\n#### `Toolbar` - Image alignment tools\n\nDisplays a toolbar below the image, where the user can select an alignment for the image.\n\nThe look and feel can be controlled with options:\n\n```javascript\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\t// ...\n\t\t\ttoolbarStyles: {\n\t\t\t\tbackgroundColor: \"black\",\n\t\t\t\tborder: \"none\",\n\t\t\t\tcolor: white,\n\t\t\t\t// other camelCase styles for size display\n\t\t\t},\n\t\t\ttoolbarButtonStyles: {\n\t\t\t\t// ...\n\t\t\t},\n\t\t\ttoolbarButtonSvgStyles: {\n\t\t\t\t// ...\n\t\t\t},\n\t\t},\n\t},\n});\n```\n\n#### `BaseModule` - Include your own custom module\n\nYou can write your own module by extending the `BaseModule` class, and then including it in\nthe module setup.\n\nFor example,\n\n```javascript\nimport { Resize, BaseModule } from \"quill-image-module\";\n\nclass MyModule extends BaseModule {\n\t// See src/modules/BaseModule.js for documentation on the various lifecycle callbacks\n}\n\nvar quill = new Quill(editor, {\n\t// ...\n\tmodules: {\n\t\t// ...\n\t\tImageResize: {\n\t\t\tmodules: [MyModule, Resize],\n\t\t\t// ...\n\t\t},\n\t},\n});\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevhau%2Fquill-image-module","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevhau%2Fquill-image-module","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevhau%2Fquill-image-module/lists"}