mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
feat: support customType in activeTool (#5144)
* feat: support customType in activeTool * fix * rewrite types and handling * tweaks * fix Co-authored-by: dwelle <luzar.david@gmail.com>
This commit is contained in:
parent
1ed1529f96
commit
64d330a332
12 changed files with 210 additions and 51 deletions
|
@ -3,6 +3,7 @@
|
|||
exports[`contextMenu element right-clicking on a group should select whole group: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -175,6 +176,7 @@ exports[`contextMenu element right-clicking on a group should select whole group
|
|||
exports[`contextMenu element selecting 'Add to library' in context menu adds element to library: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -351,6 +353,7 @@ exports[`contextMenu element selecting 'Add to library' in context menu adds ele
|
|||
exports[`contextMenu element selecting 'Bring forward' in context menu brings element forward: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -688,6 +691,7 @@ exports[`contextMenu element selecting 'Bring forward' in context menu brings el
|
|||
exports[`contextMenu element selecting 'Bring to front' in context menu brings element to front: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -1025,6 +1029,7 @@ exports[`contextMenu element selecting 'Bring to front' in context menu brings e
|
|||
exports[`contextMenu element selecting 'Copy styles' in context menu copies styles: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -1201,6 +1206,7 @@ exports[`contextMenu element selecting 'Copy styles' in context menu copies styl
|
|||
exports[`contextMenu element selecting 'Delete' in context menu deletes element: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -1413,6 +1419,7 @@ exports[`contextMenu element selecting 'Delete' in context menu deletes element:
|
|||
exports[`contextMenu element selecting 'Duplicate' in context menu duplicates element: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -1684,6 +1691,7 @@ exports[`contextMenu element selecting 'Duplicate' in context menu duplicates el
|
|||
exports[`contextMenu element selecting 'Group selection' in context menu groups selected elements: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -2039,6 +2047,7 @@ exports[`contextMenu element selecting 'Group selection' in context menu groups
|
|||
exports[`contextMenu element selecting 'Paste styles' in context menu pastes styles: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -2838,6 +2847,7 @@ exports[`contextMenu element selecting 'Paste styles' in context menu pastes sty
|
|||
exports[`contextMenu element selecting 'Send backward' in context menu sends element backward: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -3175,6 +3185,7 @@ exports[`contextMenu element selecting 'Send backward' in context menu sends ele
|
|||
exports[`contextMenu element selecting 'Send to back' in context menu sends element to back: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -3512,6 +3523,7 @@ exports[`contextMenu element selecting 'Send to back' in context menu sends elem
|
|||
exports[`contextMenu element selecting 'Ungroup selection' in context menu ungroups selected group: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -3929,6 +3941,7 @@ exports[`contextMenu element selecting 'Ungroup selection' in context menu ungro
|
|||
exports[`contextMenu element shows 'Group selection' in context menu for multiple selected elements: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -4206,6 +4219,7 @@ exports[`contextMenu element shows 'Group selection' in context menu for multipl
|
|||
exports[`contextMenu element shows 'Ungroup selection' in context menu for group inside selected elements: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -4564,6 +4578,7 @@ exports[`contextMenu element shows 'Ungroup selection' in context menu for group
|
|||
exports[`contextMenu element shows context menu for canvas: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -4669,6 +4684,7 @@ exports[`contextMenu element shows context menu for canvas: [end of test] number
|
|||
exports[`contextMenu element shows context menu for element: [end of test] appState 1`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
@ -4752,6 +4768,7 @@ Object {
|
|||
exports[`contextMenu element shows context menu for element: [end of test] appState 2`] = `
|
||||
Object {
|
||||
"activeTool": Object {
|
||||
"customType": null,
|
||||
"lastActiveToolBeforeEraser": null,
|
||||
"locked": false,
|
||||
"type": "selection",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue