Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stickies #3154

Merged
merged 172 commits into from
Apr 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
172 commits
Select commit Hold shift + click to select a range
92f7315
N8N-3029 Add Node Type for Wokrflow Stickies/Notes
SchnapsterDog Mar 1, 2022
d2b42c2
N8N-3029 Update Content, Update Aliasses
SchnapsterDog Mar 1, 2022
3019087
Merge pull request #2910 from n8n-io/n8n-3029-add-node-type
mutdmour Mar 1, 2022
b9bc120
Merge branch 'stickies' of https://github.com/n8n-io/n8n into stickies
SchnapsterDog Mar 7, 2022
7c78f1d
N8N-3030 Created N8N Sticky Component in Design System
SchnapsterDog Mar 9, 2022
1dfff86
N8N-3030 Fixed Code spaccing Sticky Component
SchnapsterDog Mar 9, 2022
130ba92
N8N-3030 Fixed Code spaccing StickyStories Component
SchnapsterDog Mar 9, 2022
c0262a0
N8N-3030 Fixed Code spaccing Markdown Component
SchnapsterDog Mar 9, 2022
0cff586
N8N-3030 Added Sticky Colors Pallete into Storybook, Update Color Var…
SchnapsterDog Mar 9, 2022
e95cbc1
N8N-3030 Added Unfocus Event
SchnapsterDog Mar 10, 2022
c23287f
N8N-3030 Update Default Placeholder, Markdown Styles, Fixed Edit Stat…
SchnapsterDog Mar 14, 2022
005482a
N8N-3030 Update Sticky Overflow, Update Hover States, Updated Markdow…
SchnapsterDog Mar 15, 2022
e5be88a
N8N-3030, N8N-3031 - Add Resize to Sticky, Created N8n-Resize component
SchnapsterDog Mar 22, 2022
e284901
N8N-3031 Fixed Importing Components in Editor-ui
SchnapsterDog Mar 22, 2022
6efa48a
N8N-3031 Fixed Resize Component, Fixed Gradient
SchnapsterDog Mar 22, 2022
3ca19a8
Merge branch 'master' of https://github.com/n8n-io/n8n into stickies
SchnapsterDog Mar 22, 2022
7c6bf42
N8N-3030, N8N-3031 Fixed conflicts
SchnapsterDog Mar 22, 2022
37ed846
N8N-3030, N8N-3031 Update Note Description
SchnapsterDog Mar 22, 2022
f2601c6
N8N-3032 Hotfix Building Storybook
SchnapsterDog Mar 23, 2022
988841b
N8N-3032 - Select Behaviour, Changes in Resize Component, Emit on Wid…
SchnapsterDog Mar 24, 2022
ca7458e
Merge branch 'stickies' of https://github.com/n8n-io/n8n into n8n-303…
SchnapsterDog Mar 24, 2022
9b2cc70
N8N-3032 Update Resize Component to emmit left/top, Update Dynamic Re…
SchnapsterDog Mar 25, 2022
b535989
N8N-3032 Updated / Dragging vs Resizing, prevent open Modal for stickies
SchnapsterDog Mar 28, 2022
49b2dd5
N8N-3032 Added ID props to n8n-sticky // dynamic id for multi resizin…
SchnapsterDog Mar 28, 2022
e649ddb
N8N-3033 Add dynamic size Tooltip on Sticky
SchnapsterDog Mar 28, 2022
69b9633
N8N-3033 Updated Z-index for Sticky Component
SchnapsterDog Mar 28, 2022
72b05f7
N8N-3033 Updated N8N-Resize Component, Fixed SelectedBackround for St…
SchnapsterDog Mar 28, 2022
ab74a16
N8N-3033 Refactor
SchnapsterDog Mar 28, 2022
1b63a81
N8N-3033 Focus/Defocus on TextArea
SchnapsterDog Mar 28, 2022
6ffc559
N8N-3033 Fixed Resizing on NW Point
SchnapsterDog Mar 28, 2022
aea9ab7
N8N-3030 Save content in vuex on input change
SchnapsterDog Mar 29, 2022
6a1028f
N8N-3033 Fixed Resizer, Save Width and Height in Vue
SchnapsterDog Mar 29, 2022
b43df19
N8N-3033 Hide Sticky Footer on small height/width
SchnapsterDog Mar 29, 2022
0b37a79
N8N-3033 Fixed Resizer
SchnapsterDog Mar 29, 2022
ddcf9fb
N8N-3033 Dynamic Z-index for Stickies
SchnapsterDog Mar 29, 2022
7321546
N8N-3033 Dynamic Z-index for Stickies
SchnapsterDog Mar 29, 2022
4a834b7
N8N-3033 Removed static z-index for select sticky class
SchnapsterDog Mar 29, 2022
a0d23ce
N8N-3034 Added Telemetry
SchnapsterDog Mar 30, 2022
0000fc5
N8N-3030 Formatter
SchnapsterDog Mar 30, 2022
1f4a8df
N8N-3030 Format code
SchnapsterDog Mar 30, 2022
c21ab5a
N8N-3030 Fixed Selecting Stickies
SchnapsterDog Mar 30, 2022
972ff82
N8N-3033 Fixed Notifications
SchnapsterDog Mar 30, 2022
49ae003
N8N-3030 Added new paddings for Default Stickies
SchnapsterDog Mar 30, 2022
397957c
N8N-3033 Prevent Scrolling NodeView when Sticky is in Edit mode and M…
SchnapsterDog Mar 30, 2022
2e447b9
N8N-3030 Prevent double clicking to switch state of Sticky component …
SchnapsterDog Mar 30, 2022
92fa483
N8N-3033 Fixed Z-index of Stickies
SchnapsterDog Mar 31, 2022
667a2d0
N8N-3033 Prevent delete node when in EditMode
SchnapsterDog Mar 31, 2022
8edde07
N8N-3030 Prevent Delete Button to delete the Sticky while in Edit Mode
SchnapsterDog Apr 1, 2022
557c80b
N8N-3030 Change EditMode (emit) on keyboard shortucts, update Markdow…
SchnapsterDog Apr 4, 2022
d57f048
N8N-3030 Sticky Component - No padding when hiding footer text
SchnapsterDog Apr 4, 2022
04abdbf
N8N-3033 Fix Resizing enter into Edit Mode
SchnapsterDog Apr 5, 2022
2982154
N8N-3033 Selecting different nodes - exit the edit mode
SchnapsterDog Apr 6, 2022
0d306cf
N8N-3033 Auto Select Text in text-area by default - Sticky Component
SchnapsterDog Apr 6, 2022
a4cd245
N8N-3033 Prevent Default behaviour for CTRL + X, CTRL + A when Sticky…
SchnapsterDog Apr 6, 2022
212ee41
N8N-3033 Refactor Resizer, Refactor Sticky, Update zIndex inEditMode
SchnapsterDog Apr 8, 2022
8fd8b2f
N8N-3033 Updated Default Text // Node-base, Storybook
SchnapsterDog Apr 8, 2022
b171a81
N8N-3033 Add Resizing in EditMode - Components update
SchnapsterDog Apr 8, 2022
bf34457
N8N-3033 Fixed Footer - Show/Hide on Resize in EditMode
SchnapsterDog Apr 8, 2022
800d801
N8N-3033 Fix ActiveSticky on Init
SchnapsterDog Apr 8, 2022
bdc995f
N8N-3033 Refactor Sticky in Vuex, Fixed Init Sticky Tweaks, Prevent M…
SchnapsterDog Apr 8, 2022
2435347
Merge branch 'master' of github.com:n8n-io/n8n into stickies
mutdmour Apr 11, 2022
bff4868
Merge branch 'master' of https://github.com/n8n-io/n8n into stickies
SchnapsterDog Apr 11, 2022
7df862b
N8N-3030 Fixing Conflicts / Pulling the master/stickies
SchnapsterDog Apr 11, 2022
d392c8e
Merge branch 'stickies' of https://github.com/n8n-io/n8n into n8n-303…
SchnapsterDog Apr 11, 2022
10a0ccc
Stickies - Update Note node with new props
SchnapsterDog Apr 11, 2022
16043ff
Merge branch 'stickies' of https://github.com/n8n-io/n8n into stickies
SchnapsterDog Apr 11, 2022
baf8dfe
Merge branch 'stickies' of https://github.com/n8n-io/n8n into n8n-303…
SchnapsterDog Apr 11, 2022
bc365ea
N8N-3030 Updated Default Note text, Update the Markdown Link
SchnapsterDog Apr 12, 2022
8f8a9cb
N8N-3030 CMD-C does not copy the text fix
SchnapsterDog Apr 12, 2022
3489edd
N8N-3030 Fix Max Zoom / Zoom out shortcuts disabled in editState
SchnapsterDog Apr 12, 2022
ee3fe63
N8N-3030 Z-index fixed during Edit Mode typing
SchnapsterDog Apr 12, 2022
4183f39
N8N-3030 Prevent Autoselect Text in Stickies if the text is not default
SchnapsterDog Apr 12, 2022
f897641
N8N-3030 Fixed ReadOnly Bugs / Prevent showing Tooltip, Resizing
SchnapsterDog Apr 13, 2022
ca7981f
N8N-3030 Added Sticky Creator Button
SchnapsterDog Apr 14, 2022
82bdd70
N8N-3030 Update Icon / Sticky Creator Button
SchnapsterDog Apr 14, 2022
882f89f
N8N-3033 Update Sticky Icon / StickyCreator Button
SchnapsterDog Apr 14, 2022
1e24088
Merge pull request #2954 from n8n-io/n8n-3030-n8n-sticky-component
mutdmour Apr 19, 2022
a8282bb
⚠ fix merege conflict
mutdmour Apr 19, 2022
03621db
update package lock
mutdmour Apr 19, 2022
4b7550c
merge in master
mutdmour Apr 19, 2022
c192bf5
Merge branch 'master' of github.com:n8n-io/n8n into stickies
mutdmour Apr 19, 2022
899ea7a
Merge branch 'master' of github.com:n8n-io/n8n into stickies
mutdmour Apr 19, 2022
6a2c513
🔩 update note props
mutdmour Apr 19, 2022
b7596c0
🚿 clean props
mutdmour Apr 19, 2022
9ee0706
🔧 linting
mutdmour Apr 19, 2022
84005f7
:wrench: fix spacing
mutdmour Apr 19, 2022
264ad7a
remove resize component
mutdmour Apr 19, 2022
2332bf1
remove resize component
mutdmour Apr 19, 2022
949f7a7
✂ clean up sticky
mutdmour Apr 19, 2022
672816e
revert back to height width
mutdmour Apr 20, 2022
51f8266
revert back to height/width
mutdmour Apr 20, 2022
e4fe18f
replace zindex property
mutdmour Apr 20, 2022
541739f
replace default text property
mutdmour Apr 20, 2022
70ec375
use i18n to translate
mutdmour Apr 20, 2022
d28a1e3
update package lock
mutdmour Apr 20, 2022
6ca7329
move resize
mutdmour Apr 20, 2022
db650c6
clean up how height/width are set
mutdmour Apr 20, 2022
ce59cdb
fix resize for sticky to support left/top
mutdmour Apr 20, 2022
0791c64
clean up resize
mutdmour Apr 20, 2022
ef248da
fix lasso/highlight bug
mutdmour Apr 20, 2022
a4f1057
remove unused props
mutdmour Apr 20, 2022
ea04e55
fix zoom to fit
mutdmour Apr 20, 2022
f02fe16
fix padding for demo view
mutdmour Apr 20, 2022
2f1ecf3
fix readonly
mutdmour Apr 20, 2022
8e189e9
remove iseditable, use active state
mutdmour Apr 20, 2022
6fdca8b
clean up keyboard events
mutdmour Apr 20, 2022
3989738
chang button size, no edit on insert
mutdmour Apr 21, 2022
d6a3220
scale resizing correctly
mutdmour Apr 21, 2022
fee54e5
make active on resize
mutdmour Apr 21, 2022
413f970
fix select on resize/move
mutdmour Apr 21, 2022
126bf9b
use outline icon
mutdmour Apr 21, 2022
36ee657
allow for multiple line breaks
mutdmour Apr 21, 2022
660ae08
fix multi line bug
mutdmour Apr 21, 2022
595da9f
fix edit mode outline
mutdmour Apr 21, 2022
e85fd24
keep edit open as one resizes
mutdmour Apr 21, 2022
1a7c484
respect multiple spaces
mutdmour Apr 21, 2022
48e4836
fix scrolling bug
mutdmour Apr 21, 2022
7d0b37b
clean up hover impl
mutdmour Apr 21, 2022
1b4ddc0
clean up references to note
mutdmour Apr 21, 2022
9b6074f
disable for rename
mutdmour Apr 22, 2022
cb3d747
fix drifting while drag
mutdmour Apr 22, 2022
4468ed6
fix mouse cursor on resize
mutdmour Apr 22, 2022
388b1a8
fix sticky min height
mutdmour Apr 22, 2022
4b933f5
refactor resize into component
mutdmour Apr 22, 2022
c1aa60e
fix pulling too far bug
mutdmour Apr 22, 2022
040b8f3
fix delete/cut all bug
mutdmour Apr 22, 2022
1b88e8a
fix padding bottom
mutdmour Apr 22, 2022
e1b78be
fix active change on resize
mutdmour Apr 22, 2022
d7cf593
add transition to button
mutdmour Apr 22, 2022
e9c0669
Fix sticky markdown click
mutdmour Apr 22, 2022
c4f747b
add solid fa icon
mutdmour Apr 22, 2022
2854b7c
update node graph, telemetry event
mutdmour Apr 22, 2022
76fbbf6
add snapping
mutdmour Apr 22, 2022
eadab17
change alt text
mutdmour Apr 22, 2022
7c14d83
⚠ merge conflict
mutdmour Apr 25, 2022
a938c49
update package lock
mutdmour Apr 25, 2022
29af0b0
fix bug in button hover
mutdmour Apr 25, 2022
dafae8d
add back transition
mutdmour Apr 25, 2022
334a02b
clean up resize
mutdmour Apr 25, 2022
c73de64
add grid size as param
mutdmour Apr 25, 2022
03d3123
remove breaks
mutdmour Apr 25, 2022
937a97a
clean up markdown
mutdmour Apr 25, 2022
5d313ff
lint fixes
mutdmour Apr 25, 2022
9bd0344
fix spacing
mutdmour Apr 25, 2022
b5865c2
clean up markdown colors
mutdmour Apr 25, 2022
e1d0925
clean up classes in resize
mutdmour Apr 25, 2022
7bbb158
clean up resize
mutdmour Apr 25, 2022
b3bc98a
update sticky story
mutdmour Apr 25, 2022
76bcb86
fix spacing
mutdmour Apr 25, 2022
3cc405f
clean up classes
mutdmour Apr 25, 2022
f606de9
revert change
mutdmour Apr 25, 2022
6ed6347
revert change
mutdmour Apr 25, 2022
0df509f
revert change
mutdmour Apr 25, 2022
ef2005f
clean up sticky component
mutdmour Apr 25, 2022
f183971
remove unused component
mutdmour Apr 25, 2022
fb98038
remove unnessary data
mutdmour Apr 25, 2022
cc5f5ba
remove unnessary data
mutdmour Apr 25, 2022
e0141cd
clean up actions
mutdmour Apr 25, 2022
76233de
clean up sticky size
mutdmour Apr 25, 2022
b99a5f5
clean up unnessary border style
mutdmour Apr 25, 2022
74b818c
fix bug
mutdmour Apr 25, 2022
f4474bd
replace sticky note name
mutdmour Apr 25, 2022
ff76e07
update description
mutdmour Apr 25, 2022
8a5a81e
remove support for multi spaces
mutdmour Apr 25, 2022
4f7bc09
update tracking name
mutdmour Apr 25, 2022
f96c02b
update telemetry reqs
mutdmour Apr 25, 2022
b0b8fea
fix enter bug
mutdmour Apr 25, 2022
0e6db61
update alt text
mutdmour Apr 25, 2022
a657058
update sticky notes doc url
mutdmour Apr 25, 2022
8cd0dc5
fix readonly bug
mutdmour Apr 25, 2022
1259b71
update class name
mutdmour Apr 25, 2022
41fbaeb
update quote marks
mutdmour Apr 25, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
94,169 changes: 17,712 additions & 76,457 deletions package-lock.json

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions packages/cli/src/InternalHooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,18 @@ export class InternalHooksClass implements IInternalHooksClass {
async onWorkflowSaved(userId: string, workflow: IWorkflowDb): Promise<void> {
const { nodeGraph } = TelemetryHelpers.generateNodesGraph(workflow, this.nodeTypes);

const notesCount = Object.keys(nodeGraph.notes).length;
const overlappingCount = Object.values(nodeGraph.notes).filter(
(note) => note.overlapping,
).length;

return this.telemetry.track('User saved workflow', {
user_id: userId,
workflow_id: workflow.id,
node_graph: nodeGraph,
node_graph_string: JSON.stringify(nodeGraph),
notes_count_overlapping: overlappingCount,
notes_count_non_overlapping: notesCount - overlappingCount,
version_cli: this.versionCli,
num_tags: workflow.tags?.length ?? 0,
});
Expand Down
1 change: 1 addition & 0 deletions packages/design-system/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
"vue-loader": "^15.9.7",
"vue-property-decorator": "^9.1.2",
"vue-template-compiler": "^2.6.11",
"vue-typed-mixins": "^0.2.0",
"vue2-boring-avatars": "0.3.4",
"xss": "^1.0.10"
}
Expand Down
1 change: 0 additions & 1 deletion packages/design-system/src/components/N8nButton/Button.vue
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ export default {
default: false,
},
icon: {
type: String,
},
round: {
type: Boolean,
Expand Down
1 change: 0 additions & 1 deletion packages/design-system/src/components/N8nIcon/Icon.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export default {
},
props: {
icon: {
type: String,
required: true,
},
size: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export default {
default: false,
},
icon: {
type: String,
required: true,
},
theme: {
Expand Down
80 changes: 78 additions & 2 deletions packages/design-system/src/components/N8nMarkdown/Markdown.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<template>
<div>
<div v-if="!loading" ref="editor" :class="$style.markdown" v-html="htmlContent" />
<div
v-if="!loading"
ref="editor"
:class="$style[theme]" v-html="htmlContent"
/>
<div v-else :class="$style.markdown">
<div v-for="(block, index) in loadingBlocks"
:key="index">
Expand Down Expand Up @@ -59,6 +63,9 @@ export default {
content: {
type: String,
},
withMultiBreaks: {
type: Boolean,
},
images: {
type: Array,
},
Expand All @@ -75,6 +82,10 @@ export default {
return 3;
},
},
theme: {
type: String,
default: 'markdown',
},
options: {
type: Object,
default() {
Expand Down Expand Up @@ -106,7 +117,11 @@ export default {
}

const fileIdRegex = new RegExp('fileId:([0-9]+)');
const html = this.md.render(escapeMarkdown(this.content));
let contentToRender = this.content;
if (this.withMultiBreaks) {
contentToRender = contentToRender.replaceAll('\n\n', '\n&nbsp;\n');
}
const html = this.md.render(escapeMarkdown(contentToRender));
const safeHtml = xss(html, {
onTagAttr: (tag, name, value, isWhiteAttr) => {
if (tag === 'img' && name === 'src') {
Expand Down Expand Up @@ -214,6 +229,67 @@ export default {
}
}

.sticky {
color: var(--color-text-dark);

h1, h2, h3, h4 {
margin-bottom: var(--spacing-2xs);
font-weight: var(--font-weight-bold);
line-height: var(--font-line-height-loose);
}

h1 {
font-size: 36px;
}

h2 {
font-size: 24px;
}

h3, h4, h5, h6 {
font-size: var(--font-size-m);
}

p {
margin-bottom: var(--spacing-2xs);
font-size: var(--font-size-s);
font-weight: var(--font-weight-regular);
line-height: var(--font-line-height-loose);
}

ul, ol {
margin-bottom: var(--spacing-2xs);
padding-left: var(--spacing-m);

li {
margin-top: 0.25em;
font-size: var(--font-size-s);
font-weight: var(--font-weight-regular);
line-height: var(--font-line-height-regular);
}
}

code {
background-color: var(--color-background-base);
padding: 0 var(--spacing-4xs);
color: var(--color-secondary);
}

pre > code,li > code, p > code {
color: var(--color-secondary);
}

a {
&:hover {
text-decoration: underline;
}
}

img {
object-fit: contain;
}
}

.spacer {
margin: var(--spacing-2xl);
}
Expand Down
Loading