-
Notifications
You must be signed in to change notification settings - Fork 12.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ User management v2 Front End (#3795)
* feat: Added responsive generic page view layout. * feat: Added empty state. * feat: Added credentials view empty state. * test: Added unit tests for N8nActionBox * feat: Added credentials list initial design. * feat: Added credential actions. Started working on filters. * feat: Updated InfoTip markup, added tests and changed stories to typescript. * feat: Added credentials filtering by type. Added support for apply/reset filters. * feat: Added credential sharing user select and user list. Added paywall component. * feat: Updated credentials view permissions. * feat: Added support for temporary sharing config for unsaved credentials. * test: Fixed broken snapshots. * feat: Added overflow styles to page-view-layout list. * feat: Handled sharee specific views. * feat: Integration between FE and BE to support real-world credential sharing scenario. * feat: Added front end permissions table. * feat: Refactored credential sharing flow. Updated design elements. * feat: Added margin and padding auto spacer utilities. * feat: Rehauled permissions to support instanceOwner role and action inheritance. * feat: Updated credentials view to apply filters automatically. * feat: Removed apply filters button and added active button state. * test: Updated component snapshots. * refactor: Renamed ResourceSharee to ResourceReader. * feat: Credential sharing error handling, permissions improvement. * feat: Updated permissions and error handling.
- Loading branch information
1 parent
1f7ae7e
commit 9a013ec
Showing
74 changed files
with
6,037 additions
and
3,567 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
packages/design-system/src/components/N8nActionBox/__tests__/ActionBox.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import { render } from '@testing-library/vue'; | ||
import N8NActionBox from '../ActionBox.vue'; | ||
|
||
describe('components', () => { | ||
describe('N8NActionBox', () => { | ||
describe('props', () => { | ||
it('should render correctly', () => { | ||
const wrapper = render(N8NActionBox, { | ||
props: { | ||
emoji: "😿", | ||
heading: "Headline you need to know", | ||
description: "Long description that you should know something is the way it is because of how it is. ", | ||
buttonText: "Do something", | ||
}, | ||
stubs: [ | ||
'n8n-heading', | ||
'n8n-text', | ||
'n8n-button', | ||
'n8n-callout', | ||
], | ||
}); | ||
expect(wrapper.html()).toMatchSnapshot(); | ||
}); | ||
}); | ||
}); | ||
}); |
15 changes: 15 additions & 0 deletions
15
.../design-system/src/components/N8nActionBox/__tests__/__snapshots__/ActionBox.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// Vitest Snapshot v1 | ||
|
||
exports[`components > N8NActionBox > props > should render correctly 1`] = ` | ||
"<div class=\\"n8n-action-box _container_1ng3s_1\\"> | ||
<div class=\\"_emoji_1ng3s_16\\"> 😿 </div> | ||
<div class=\\"_heading_1ng3s_20\\"> | ||
<n8n-heading-stub tag=\\"span\\" size=\\"xlarge\\" align=\\"center\\">Headline you need to know</n8n-heading-stub> | ||
</div> | ||
<div class=\\"_description_1ng3s_24\\"> | ||
<n8n-text-stub size=\\"medium\\" color=\\"text-base\\" tag=\\"span\\"><span>Long description that you should know something is the way it is because of how it is. </span></n8n-text-stub> | ||
</div> | ||
<n8n-button-stub label=\\"Do something\\" type=\\"primary\\" size=\\"large\\"></n8n-button-stub> | ||
<!----> | ||
</div>" | ||
`; |
9 changes: 8 additions & 1 deletion
9
packages/design-system/src/components/N8nActionToggle/ActionToggle.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
packages/design-system/src/components/N8nBadge/__tests__/__snapshots__/Badge.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
// Vitest Snapshot v1 | ||
|
||
exports[`components > N8nBadge > props > should render default theme correctly 1`] = `"<span class=\\"n8n-badge _default_13dw2_9 _badge_13dw2_1\\"><n8n-text-stub bold=\\"true\\" size=\\"large\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">Default badge</n8n-text-stub></n8n-text-stub></span>"`; | ||
exports[`components > N8nBadge > props > should render default theme correctly 1`] = `"<span class=\\"n8n-badge _default_1xljn_9 _badge_1xljn_1\\"><n8n-text-stub bold=\\"true\\" size=\\"large\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">Default badge</n8n-text-stub></n8n-text-stub></span>"`; | ||
exports[`components > N8nBadge > props > should render secondary theme correctly 1`] = `"<span class=\\"n8n-badge _secondary_13dw2_16 _badge_13dw2_1\\"><n8n-text-stub size=\\"medium\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">Secondary badge</n8n-text-stub></n8n-text-stub></span>"`; | ||
exports[`components > N8nBadge > props > should render secondary theme correctly 1`] = `"<span class=\\"n8n-badge _secondary_1xljn_25 _badge_1xljn_1\\"><n8n-text-stub size=\\"medium\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">Secondary badge</n8n-text-stub></n8n-text-stub></span>"`; | ||
exports[`components > N8nBadge > props > should render with default values correctly 1`] = `"<span class=\\"n8n-badge _default_13dw2_9 _badge_13dw2_1\\"><n8n-text-stub size=\\"small\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">A Badge</n8n-text-stub></n8n-text-stub></span>"`; | ||
exports[`components > N8nBadge > props > should render with default values correctly 1`] = `"<span class=\\"n8n-badge _default_1xljn_9 _badge_1xljn_1\\"><n8n-text-stub size=\\"small\\" compact=\\"true\\" tag=\\"span\\"><n8n-text-stub size=\\"medium\\" tag=\\"span\\">A Badge</n8n-text-stub></n8n-text-stub></span>"`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
packages/design-system/src/components/N8nButton/__tests__/__snapshots__/Button.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
// Vitest Snapshot v1 | ||
|
||
exports[`components > N8nButton > overrides > should render correctly 1`] = `"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_cccce_115 _secondary_cccce_170 _medium_cccce_254 _icon_cccce_239\\" icon=\\"plus-circle\\" type=\\"secondary\\"><span class=\\"_icon_cccce_239\\"><n8n-icon-stub icon=\\"plus-circle\\" size=\\"medium\\"></n8n-icon-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > overrides > should render correctly 1`] = `"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_dnko0_115 _secondary_dnko0_170 _medium_dnko0_254 _icon_dnko0_239\\" icon=\\"plus-circle\\" type=\\"secondary\\"><span class=\\"_icon_dnko0_239\\"><n8n-icon-stub icon=\\"plus-circle\\" size=\\"medium\\"></n8n-icon-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > props > icon > should render icon button 1`] = `"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_cccce_115 _primary_cccce_288 _medium_cccce_254 _icon_cccce_239\\"><span class=\\"_icon_cccce_239\\"><n8n-icon-stub icon=\\"plus-circle\\" size=\\"medium\\"></n8n-icon-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > props > icon > should render icon button 1`] = `"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_dnko0_115 _primary_dnko0_288 _medium_dnko0_254 _icon_dnko0_239\\"><span class=\\"_icon_dnko0_239\\"><n8n-icon-stub icon=\\"plus-circle\\" size=\\"medium\\"></n8n-icon-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > props > loading > should render loading spinner 1`] = `"<button disabled=\\"disabled\\" aria-disabled=\\"false\\" aria-busy=\\"true\\" aria-live=\\"polite\\" class=\\"button _button_cccce_115 _primary_cccce_288 _medium_cccce_254 _loading_cccce_352 _icon_cccce_239\\"><span class=\\"_icon_cccce_239\\"><n8n-spinner-stub size=\\"medium\\" type=\\"dots\\"></n8n-spinner-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > props > loading > should render loading spinner 1`] = `"<button disabled=\\"disabled\\" aria-disabled=\\"false\\" aria-busy=\\"true\\" aria-live=\\"polite\\" class=\\"button _button_dnko0_115 _primary_dnko0_288 _medium_dnko0_254 _loading_dnko0_352 _icon_dnko0_239\\"><span class=\\"_icon_dnko0_239\\"><n8n-spinner-stub size=\\"medium\\" type=\\"dots\\"></n8n-spinner-stub></span><span>Button</span></button>"`; | ||
exports[`components > N8nButton > should render correctly 1`] = ` | ||
"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_cccce_115 _primary_cccce_288 _medium_cccce_254\\"> | ||
"<button aria-disabled=\\"false\\" aria-busy=\\"false\\" aria-live=\\"polite\\" class=\\"button _button_dnko0_115 _primary_dnko0_288 _medium_dnko0_254\\"> | ||
<!----><span>Button</span></button>" | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
25 changes: 25 additions & 0 deletions
25
packages/design-system/src/components/N8nCard/__tests__/__snapshots__/Card.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Vitest Snapshot v1 | ||
|
||
exports[`components > N8nCard > should render correctly 1`] = ` | ||
"<div class=\\"card _card_1oonz_1\\"> | ||
<!----> | ||
<div class=\\"_content_1oonz_20\\"> | ||
<!----> | ||
<div class=\\"_body_1oonz_27\\">This is a card.</div> | ||
<!----> | ||
</div> | ||
<!----> | ||
</div>" | ||
`; | ||
exports[`components > N8nCard > should render correctly with header and footer 1`] = ` | ||
"<div class=\\"card _card_1oonz_1\\"> | ||
<!----> | ||
<div class=\\"_content_1oonz_20\\"> | ||
<div class=\\"_header_1oonz_12\\">Header</div> | ||
<div class=\\"_body_1oonz_27\\">This is a card.</div> | ||
<div class=\\"_footer_1oonz_13\\">Footer</div> | ||
</div> | ||
<!----> | ||
</div>" | ||
`; |
Oops, something went wrong.