Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/retejs/connection-mastery-plugin
https://github.com/retejs/connection-mastery-plugin
Last synced: 10 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/retejs/connection-mastery-plugin
- Owner: retejs
- Created: 2019-03-30T17:58:11.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-03T18:49:07.000Z (almost 2 years ago)
- Last Synced: 2024-10-30T00:54:46.153Z (21 days ago)
- Language: TypeScript
- Size: 779 KB
- Stars: 5
- Watchers: 3
- Forks: 6
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Connection Mastery
====
#### Rete.js pluginThis plugin is intended to enhance `rete-connection-plugin` in terms of user interaction.
## Features:
- Create node for picked connection and connect ([example](https://youtu.be/8ew12FLgaMs?t=98))
| # | User actions | Editor |
|---|---|---|
| 1 | Press Ctrl on connection drop | Context menu will appear |
| 2 | Select a node by holding down Ctrl | Node will be added. The previously picked Input/Output will be connected with a compatible Output/Input of the added node |- Delete connection by picking
| # | User actions | Editor |
|---|---|---|
| 1 | Press D and click on the connection | Remove the connection |## How to use
```js
import ConnectionMasteryPlugin from 'rete-connection-mastery-plugin';editor.use(ConnectionMasteryPlugin);
// or disable features
editor.use(ConnectionMasteryPlugin, {
createAndConnect: false,
pickConnection: false
});
// or change keys
editor.use(ConnectionMasteryPlugin, {
createAndConnect: { keyCode: 'ControlLeft' },
pickConnection: { keyCode: 'KeyD' }
});
```