opentiny / opentiny/tiny-editor
✨ [Feature]: 希望图片伸缩可以支持设置最小宽高
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- TypeScript
- Stars
- 535
- Forks
- 71
- Avg merge
- 6h 50m
- Merged PRs (30d)
- 2
Description
What problem does this feature solve
目前图片最小只能缩小到 40*40,有点局限,有些业务希望图片更小一些,希望能自定义图片能缩小到的最小宽高。
What does the proposed API look like
期望 API(如果有会更好的 API 设计也可以一起讨论):
new TinyEditor({
modules: {
image: {
minWidth: '10px',
minHeight: '10px'
}
}
})
What is your project name
Wiki
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the TinyEditor image module and the existing 40×40 minimum resize constraint. Review how the proposed modules.image minWidth and minHeight options could be represented and applied. Done means image resizing honors configurable minimum width and height values, with appropriate behavior when they are not provided.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100