feat(edgeless): connector supports text label
The connector supports text label.
There are three modes in connector: Straight Orthogonal Curve, need to be handled separately.
Connector Label
- Add
- [x] By button, default position is at the center of the path
- [x] By double-clicked position, along the path
- Edit
- [x] By button
- [x] By double-clicking
connector - [x] By double-clicking
label
- Select
- [x] Show component toolbar
- [x] Adjust styles:
font,color - [x] Adjust index:
frontback - [x] Support for moving along the path
- [x] Auto adjust position when adjusting connector's source or target
- Remove
- [x] Select
Label, and pressDelete - [x] Select
ConnectorandLabel, and pressDeleteorCMD+A+Delete - [x] Select
Connector, and pressDelete,Labelwill also be deleted
- [x] Select
- Selection
- [x] Select both connector and label
should only show the connector's toolbar
- [x] Select both connector and label
- [ ] fix selection(
shift+click) - [ ] fix snap
- [ ] fix tests
- [ ] add tests
The latest updates on your projects. Learn more about Vercel for Git ↗︎
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| blocksuite | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 22, 2024 2:51am |
1 Ignored Deployment
| Name | Status | Preview | Comments | Updated (UTC) |
|---|---|---|---|---|
| blocksuite-docs | ⬜️ Ignored (Inspect) | Visit Preview | Apr 22, 2024 2:51am |
Your org has enabled the Graphite merge queue for merging into master
Add the label “merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge.
You must have a Graphite account in order to use the merge queue. Sign up using this link.
This stack of pull requests is managed by Graphite. Learn more about stacking.
Join @fundon and the rest of your teammates on
Graphite
I think Connector Label should be a standalone element to support selection, adjusting styles, dragging and dropping to move the position, adjusting the index.
Is there any special with connector text comparing to shape text?
Is there any special with connector text comparing to shape text?
- text can be selected
- supported by 1, move on the path(curve)
- supported by 1, adjust style and index
https://github.com/toeverything/blocksuite/issues/6583