Commit Graph

265 Commits

Author SHA1 Message Date
Nick O'Leary ab2ced5c37
Merge pull request #3352 from ralphwetzel/dev
Subflow: Add labels to OUTPUT nodes
2022-01-25 17:07:12 +00:00
Nick O'Leary f67aafa8d3
Merge pull request #3361 from node-red/zoom-level
Remember Zoom level and Sidebar tab selection between sessions
2022-01-24 23:21:31 +00:00
Nick O'Leary e0d4ecf835
Merge branch 'master' into dev 2022-01-24 23:18:25 +00:00
Nick O'Leary d679b02658
Add option to remember zoom and scroll position in localStorage 2022-01-24 21:04:27 +00:00
Nick O'Leary 5fc920087b
Store user zoom level in localStorage 2022-01-17 21:27:48 +00:00
Hiroyasu Nishiyama a2c9458b1b aligin start of property error tooltip messages 2022-01-15 13:11:56 +09:00
ralphwetzel eb1b8b577f
Merge branch 'node-red:dev' into dev 2022-01-13 23:36:23 +01:00
ralphwetzel 28f91685ce Subflow: Add labels to OUTPUT nodes 2022-01-13 23:33:06 +01:00
Nick O'Leary cb96fb735e
Merge pull request #3289 from node-red/snap-grid
Snap nodes on grid using either edge as reference
2022-01-12 17:57:26 +00:00
Nick O'Leary af949c62c2
Allow 'escape' to cancel wire-slicing 2022-01-12 17:24:25 +00:00
Nick O'Leary f3997128b9
Add wire-slice mode to delete wires with Ctrl-RHClick-Drag 2022-01-11 19:49:40 +00:00
Nick O'Leary 154a4e23dd
Add delete-selection-and-reconnect action 2022-01-11 14:11:55 +00:00
Nick O'Leary 30f2b96c68
Pressing escape whilst DETACH_DRAGGING should revert change 2022-01-11 00:24:34 +00:00
Nick O'Leary 58c94b7773
Add core:detach-selected-nodes action 2022-01-11 00:16:24 +00:00
Nick O'Leary cb3fcb7bfa
Ctrl-Shift-Click on node should add to existing selection 2022-01-03 23:29:42 +00:00
Nick O'Leary bef641609e
Select links when nodes on either side selected 2022-01-03 23:29:12 +00:00
Nick O'Leary 43651135f3
Replace selectedLinks array with wrapped Set object 2021-12-13 21:02:55 +00:00
Nick O'Leary ecaf866613
Fix serialisation of selection in view 2021-12-07 09:29:11 +00:00
Nick O'Leary 5ea3329b36
Allow multiple links to be selected by ctrl-click 2021-12-07 09:19:27 +00:00
Nick O'Leary 7bb7149f4c
Snap nodes on grid using either edge as reference 2021-12-05 23:23:57 +00:00
Nick O'Leary cd23b44506
Merge pull request #3253 from node-red/clear-disabled-status
Do not show status for disabled nodes
2021-11-22 23:24:18 +00:00
Nick O'Leary 279fcb7c51
Merge pull request #3267 from node-red-hitachi/fix-link-target-select
fix to show link target when selected
2021-11-22 23:20:04 +00:00
Hiroyasu Nishiyama 7e7f481f99 fix to show link target when selected 2021-11-19 17:14:22 +09:00
Nick O'Leary bfe0d3b8a3
Do not show status for disabled nodes
Fixes #3249
2021-11-08 21:12:13 +00:00
Nick O'Leary bf0ea89969
Fix import notification message when importing config nodes 2021-10-25 15:08:30 +01:00
Nick O'Leary de4944cd83
Ensure node is resized if its label changes 2021-10-14 11:53:55 +01:00
Nick O'Leary b01fd24e15
Add link-call node and add return mode for link-out node 2021-09-29 10:45:00 +01:00
Nick O'Leary 6ab74951f4
Fix menu shortcut display when menu label is long 2021-09-24 19:44:05 +01:00
Nick O'Leary 87b6327c5e
Merge branch 'dev' into hide-flows 2021-09-07 13:53:45 +01:00
Nick O'Leary 9dc5ae21c4
Add menu options for raise/lower actions 2021-09-07 12:04:58 +01:00
Nick O'Leary 4132fb79a6
Allow nodes to be raised/lowered in the workspace 2021-09-07 11:49:31 +01:00
Nick O'Leary 192b542fe4
Add menu options for align tools and show shortcuts on menu 2021-09-07 11:47:04 +01:00
Nick O'Leary 46e2ff1001
Allow tabs to be hidden 2021-08-26 12:06:15 +01:00
Nick O'Leary 5ba0588c7b
Merge branch 'master' into dev 2021-07-16 08:53:35 +01:00
Nick O'Leary d4a199f0e1
Avoid prototype pollution in RED.view.calculateTextDimensions 2021-07-16 08:52:00 +01:00
Nick O'Leary 844bf29de1
Add RED.view.annotations api 2021-06-24 17:40:26 +01:00
Nick O'Leary e9e64f6a44
Add option to RED.nodes.createCompleteNodeSet to include node dimensions
This allows the linter to use a flow json with more than just position
information.
2021-06-04 13:53:01 +01:00
Nick O'Leary c47b553a8e
Add viewAddPort viewRemovePort viewAddNode viewRemoveNode hooks to view 2021-05-13 13:36:50 +01:00
Nick O'Leary e641b0a965
Fix scaling issues when dragging nodes into scaled workspace 2021-05-10 21:03:27 +01:00
Nick O'Leary 8e7efd98b2
Don't let 'escape' whilst moving nodes interrupt things
Fixes #2960
2021-04-26 16:48:21 +01:00
Nick O'Leary 0b39ef68d9
Use cursor keys to change selection in workspace 2021-03-10 14:04:47 +00:00
Nick O'Leary 2fa50e458f
Fix select up/down stream when zoomed in or out 2021-03-09 00:37:01 +00:00
Nick O'Leary 9c7db1381c
Add core:go-to-selected-subflow action 2021-03-06 23:28:20 +00:00
Nick O'Leary 2d4f5b8603
Ctrl-dbclick on subflow node opens subflow tab 2021-03-06 23:21:16 +00:00
Nick O'Leary 15715a2968
Ensure select-up/down-stream action follows branches in flows 2021-03-03 14:20:55 +00:00
Nick O'Leary ca75efcbaf
Adds shift-click support for selecting up/down stream nodes 2021-02-17 17:32:55 +00:00
Hiroyasu Nishiyama 34ef055d7b
Fix line break of subflow label on palette (#2828)
* fix line break of subflow label on palette

* handle line break on palette
2021-01-27 20:32:15 +00:00
Dave Conway-Jones 65d90a6dff
Add gray/grey alternate options for status 2020-11-05 09:20:47 +00:00
Hiroyasu Nishiyama 9bfe8ac007 fix selection of link node not existing within active workspace 2020-10-12 20:16:21 +09:00
Nick O'Leary a48f0827ae
Detect importing duplicate nodes and help user resolve 2020-09-16 11:59:13 +01:00
Nick O'Leary 7bd0ca2212
Handle nodes with invalid z property
Closes #2170
2020-09-03 18:31:33 +01:00
Nick O'Leary 02c20e97b7
Only recalculate group label offsets when needed 2020-09-03 13:49:42 +01:00
Nick O'Leary d9900d8e4c
Fix copy/paste of node into active group
Fixes #2686
2020-09-03 13:12:08 +01:00
Nick O'Leary 85edee288f
Allow lasso selection to be restricted to active group 2020-08-05 11:16:53 +01:00
Nick O'Leary 1aa494a97a
Make ctrl-click on nexted group more intuitive 2020-08-05 10:38:14 +01:00
Nick O'Leary a8e7627184
Support select-all inside active group 2020-08-04 21:01:08 +01:00
Nick O'Leary 758f44e25f
Improve performance of moving groups 2020-07-31 23:22:33 +01:00
Nick O'Leary 580cc00967
Fix all the touch screen issues 2020-07-10 16:00:38 +01:00
Nick O'Leary 612c565cfd
Add RED.view.redrawStatus to avoid full redraw on update 2020-07-10 16:00:18 +01:00
Nick O'Leary 1c337f6817
Fix connecting wires to subflow status or io ports on touchscreen 2020-07-08 13:22:26 +01:00
Nick O'Leary f5e46a663a
Remove hardcoded css and allow group to default from theme
Fixes #2633
2020-07-07 11:01:05 +01:00
Nick O'Leary 64ec415a54
Add RED.view.DEBUG_SYNC_REDRAW to disable requestAnimationFrame
References #2631
2020-07-06 21:01:14 +01:00
Nick O'Leary 0243a902b2
Fix up subflow port wiring 2020-07-06 18:11:47 +01:00
Nick O'Leary 6c04402a98
Prevent wiring to node with no corresponding port
Fixes #2641
2020-07-06 17:32:44 +01:00
Nick O'Leary 73448a6039
Avoid copying duplicate nodes to internal clipboard 2020-07-06 16:00:15 +01:00
Nick O'Leary 44da085e0b
Tweak group margin to fit node status and look better 2020-06-29 20:43:25 +01:00
Nick O'Leary 0a411cbe4f
Fix node button mouse pointer css 2020-06-22 14:37:52 +01:00
Nick O'Leary 581f71911a
Change node linebreak handling to use "\n " 2020-06-22 13:08:35 +01:00
Nick O'Leary e548bf8bc2
Handle import of node with non-default number of outputs 2020-06-22 10:43:09 +01:00
Nick O'Leary 6f407750f5
Fix clearing group label 2020-06-18 22:25:00 +01:00
Nick O'Leary 68d3cc7507
Fix node toggle button initial opacity 2020-06-18 10:18:35 +01:00
Nick O'Leary e2c86c4b96
Fix wiring nodes from input back to output 2020-06-17 10:52:41 +01:00
Nick O'Leary 9ce5210c33
Handle unknown nodes with no icon 2020-06-16 20:34:45 +01:00
Nick O'Leary 4dd68452b4
Prevent node creep when switching tabs 2020-06-16 20:23:18 +01:00
Nick O'Leary aebb7da3c7
Fix deleting node in group after changing selection 2020-06-16 10:54:50 +01:00
Nick O'Leary ebca8c0217
Increase group margin to avoid clash with status text 2020-06-14 23:44:26 +01:00
Nick O'Leary 752a080876
Fix event order when quick-adding node to group 2020-06-14 23:44:01 +01:00
Nick O'Leary 61d9ccf263
Avoid regenerating every node label on redraw 2020-06-13 23:02:10 +01:00
Hiroyasu Nishiyama 1c30584153 fix code indentation 2020-06-13 23:33:45 +09:00
Hiroyasu Nishiyama 5c5bebd689 fix handling of multi-line node label 2020-06-13 23:28:10 +09:00
Hiroyasu Nishiyama 5e8e739f78 fix position of empty group with multi-line label 2020-06-12 16:07:46 +09:00
Nick O'Leary 7be824640c
Fix snapToGrid 2020-06-10 01:02:48 +01:00
Nick O'Leary c061487a16
Massively reduce our dependency on d3 to render the view
This is a slightly scary set of changes to be making. It overhauls
how the view is rendered.

Rather than use d3 for every single part of generating the view,
we new use native DOM functions as much as possible.

d3 is still used for the basic heavy lifting of working out what
nodes/links etc need to be added/removed from the view. But once
it comes to rendering them, d3 is side-lined as much as possible.

There's room for further improvement. This change focusses on Nodes
and Links. It has not touched groups, subflow-ports and link-nodes.
2020-06-10 00:45:20 +01:00
Nick O'Leary 091a462a42
Add 'add' option to touch radialMenu for quick-add dialog 2020-06-05 15:48:45 +01:00
Nick O'Leary efecfa328b
Fix up event handling when deleting groups and tabs 2020-06-03 14:23:26 +01:00
Hiroyasu Nishiyama 3345f2f3b8 simplify code structure 2020-05-28 10:23:50 +09:00
Hiroyasu Nishiyama 05f816fc5d not emit change event on group delete 2020-05-25 08:46:35 +09:00
Nick O'Leary 15cc88de6c
[info-sidebar] Handle node/group/flows with \\n in their name 2020-05-19 17:53:20 +01:00
Hiroyasu Nishiyama 5f5e6ea845 fix error on empty label 2020-05-17 11:44:23 +09:00
Hiroyasu Nishiyama 243915516e fix line break of group label 2020-05-16 20:56:21 +09:00
Nick O'Leary fbd911ed27
[outliner] Keep outliner selection in sync with workspace 2020-05-14 22:08:25 +01:00
Nick O'Leary ff310f89bd
[groups] Support RED.view.reveal(group-id) 2020-05-12 10:59:41 +01:00
Nick O'Leary 1a9c4b7714
All node button to be clicked via api call 2020-04-27 11:03:43 +01:00
Nick O'Leary 373267c53b
Add more consistent events in the editor
This introduces a much more consistent set of events within the editor
for whenever a element is added, removed or modified.

The events emited on the `RED.events` event system. The event names
take the form: `"<thing>:<action>"`.

`<thing>` can be one of:
 - nodes
 - flows
 - subflows
 - groups
 - links

`<action>` can be one of:
 - add
 - remove
 - change

The payload of the events is the object in question.

There is also:
 - flows:reorder    - when tabs are reordered. Payload is array of flow ids.
 - workspace:clear  - when the workspace is emptied - part of switching projects

The `nodes:change` event was already used by RED.nodes.dirty() to cause
the Deploy button to become active. This renames that event to:
 - workspace:dirty  - Payload is boolean flag for the dirty state

This commit also updates the Palette to use the subflows:change event to
only redraw subflows that have actually changed rather than refresh them
all whenever one of them *might* have changed. This removes a noticable
flicker of the icon which was needlessly being redrawn.
2020-04-20 22:23:34 +01:00
Nick O'Leary b032e00d01
[groups] increase group border radius 2020-04-14 22:39:42 +01:00
Nick O'Leary fbfc74e5ca
[groups] Ensure newly imported nodes have width/height 2020-04-02 11:58:08 +01:00
Nick O'Leary 5da89892b4
[groups] Draw group selection above all other groups 2020-04-01 14:10:35 +01:00
Nick O'Leary 7fa4df082e
Force sync redraw of view when replacing unknown nodes 2020-03-31 15:58:51 +01:00
Hiroyasu Nishiyama fa8236ee2c update for recent change of dev branch 2020-03-31 20:32:07 +09:00
Hiroyasu Nishiyama 08ec04c889 merge upstream/dev 2020-03-31 19:05:22 +09:00