mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-23 04:39:08 +00:00
feat(editor): Only redirect new users to blank canvas (no-changelog) (#5654)
* feat(editor): Bring new users to empty canvas * fix(editor): Revert empty /workflows redirect * Provide `COMMIT_INFO_BRANCH` and uncomment demo experiment * Only change redirect after set-up/sign-up to new canvas * Fix failing specs * Prevent redirect for demo experiment * Fix workflows cards spacing
This commit is contained in:
@@ -49,7 +49,7 @@
|
||||
</div>
|
||||
<div :class="['text-center', 'mt-2xl', $style.actionsContainer]">
|
||||
<n8n-card
|
||||
:class="[$style.emptyStateCard, 'mr-s']"
|
||||
:class="$style.emptyStateCard"
|
||||
hoverable
|
||||
@click="addWorkflow"
|
||||
data-test-id="new-workflow-card"
|
||||
@@ -60,21 +60,15 @@
|
||||
</n8n-text>
|
||||
</n8n-card>
|
||||
<n8n-card
|
||||
v-if="isDemoTest"
|
||||
:class="$style.emptyStateCard"
|
||||
hoverable
|
||||
@click="goToTemplates"
|
||||
data-test-id="new-workflow-template-card"
|
||||
>
|
||||
<n8n-icon
|
||||
:class="$style.emptyStateCardIcon"
|
||||
:icon="isDemoTest ? 'graduation-cap' : 'box-open'"
|
||||
/>
|
||||
<n8n-icon :class="$style.emptyStateCardIcon" icon="graduation-cap" />
|
||||
<n8n-text size="large" class="mt-xs" color="text-base">
|
||||
{{
|
||||
$locale.baseText(
|
||||
isDemoTest ? 'workflows.empty.viewDemo' : 'workflows.empty.browseTemplates',
|
||||
)
|
||||
}}
|
||||
{{ $locale.baseText('workflows.empty.viewDemo') }}
|
||||
</n8n-text>
|
||||
</n8n-card>
|
||||
</div>
|
||||
@@ -237,15 +231,6 @@ const WorkflowsView = mixins(showMessage, debounceHelper).extend({
|
||||
]);
|
||||
|
||||
this.credentialsStore.fetchAllCredentials();
|
||||
|
||||
// If the user has no workflows and is not participating in the demo experiment,
|
||||
// redirect to the new workflow view
|
||||
if (!this.isDemoTest && this.allWorkflows.length === 0) {
|
||||
this.uiStore.nodeViewInitialized = false;
|
||||
this.$router.replace({ name: VIEWS.NEW_WORKFLOW });
|
||||
}
|
||||
|
||||
return Promise.resolve();
|
||||
},
|
||||
onClickTag(tagId: string, event: PointerEvent) {
|
||||
if (!this.filters.tags.includes(tagId)) {
|
||||
@@ -304,6 +289,10 @@ export default WorkflowsView;
|
||||
display: inline-flex;
|
||||
height: 230px;
|
||||
|
||||
& + & {
|
||||
margin-left: var(--spacing-s);
|
||||
}
|
||||
|
||||
&:hover {
|
||||
svg {
|
||||
color: var(--color-primary);
|
||||
|
||||
Reference in New Issue
Block a user