{"id":17561901,"url":"https://github.com/gitjinfeiyang/j-image-editor","last_synced_at":"2025-09-16T13:18:27.566Z","repository":{"id":119035405,"uuid":"111481525","full_name":"Gitjinfeiyang/j-image-editor","owner":"Gitjinfeiyang","description":"canvas image editor","archived":false,"fork":false,"pushed_at":"2018-03-29T08:33:26.000Z","size":40,"stargazers_count":16,"open_issues_count":1,"forks_count":9,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-18T15:16:36.550Z","etag":null,"topics":["canvas","imagecroper","imageeditor","javascript"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Gitjinfeiyang.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-11-21T01:14:13.000Z","updated_at":"2024-11-29T09:41:04.000Z","dependencies_parsed_at":null,"dependency_job_id":"ee09a728-8912-4007-ba0b-45575409aba5","html_url":"https://github.com/Gitjinfeiyang/j-image-editor","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gitjinfeiyang%2Fj-image-editor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gitjinfeiyang%2Fj-image-editor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gitjinfeiyang%2Fj-image-editor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Gitjinfeiyang%2Fj-image-editor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Gitjinfeiyang","download_url":"https://codeload.github.com/Gitjinfeiyang/j-image-editor/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251298041,"owners_count":21566940,"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","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":["canvas","imagecroper","imageeditor","javascript"],"created_at":"2024-10-21T12:09:27.434Z","updated_at":"2025-09-16T13:18:22.493Z","avatar_url":"https://github.com/Gitjinfeiyang.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# j-image-editor\ncanvas image editor\n\n# Demo\n[在线演示](https://gitjinfeiyang.github.io/j-image-editor/index.html)\n\n# 使用\n请参考demo  \n     `let editor = new ImageEditor(options);`\n     \n# Options   \n`{\n\n\tcontainer:'.wrapper',   //必填 挂载容器\n\tlimit:{\n\t\tminWidth:500,//宽度限制\n\t\tmaxWidth:200,\n\t\tminHeight:50,//高度限制\n\t\tmaxHeight:200,\n\t\tmaxSize:50,//图片大小限制 kb\n\t},\n    created:function(imageEditor){\n      //editor被初始化后\n    },\n    beforeReadFile:function(){\n     //初始化file之前 只有调用`readFile(file)`才会触发 (建议在这一步显示编辑器)\n    },\n    afterReadFile:function(){\n\t\t  //通过FileReader读取文件之后\n\t\t},\n    beforeLoadImage:function(){\n\t\t  //读取图片前 (显示编辑器)\n\t\t},\n    afterLoadImage:function(){\n\t\t  //读取图片后\n\t\t},\n    beforeSave:function(){\n\t\t  //保存之前\n\t\t},\n    afterSave:function(){\n\t\t  //保存之后\n\t\t},\n     afterRender:function(){\n      //图片加载并开始渲染\n     }\n\t\t\n}`\n\n\n# API\n`initImage(url,callback)` 读取图片链接\n\n`readFile(file)` 读取`File`\n\n`save()` 保存结果，返回 `blob，dataUrl`\n\n`scaleInCenter(scale)` 以canvas中心为中心缩放\n\n`rotateZ(deg)` 以canvas中心为中心旋转\n\n其他使用请参考demo\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgitjinfeiyang%2Fj-image-editor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgitjinfeiyang%2Fj-image-editor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgitjinfeiyang%2Fj-image-editor/lists"}