-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
fix(dashboard): wait for save when switching preview tab #7299
base: next
Are you sure you want to change the base?
fix(dashboard): wait for save when switching preview tab #7299
Conversation
const isNovuCloud = workflow.origin === WorkflowOriginEnum.NOVU_CLOUD && uiSchema; | ||
const isExternal = workflow.origin === WorkflowOriginEnum.EXTERNAL; | ||
|
||
const editorContent = ( | ||
<> | ||
{isNovuCloud && <EmailEditor uiSchema={uiSchema} />} | ||
{isExternal && ( | ||
<EmailTabsSection> | ||
<CustomStepControls dataSchema={dataSchema} origin={workflow.origin} /> | ||
</EmailTabsSection> | ||
)} | ||
</> | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added more explicit conditions so its unified across steps
@@ -12,8 +12,8 @@ const redirectKey = 'redirect'; | |||
const primaryActionKey = 'primaryAction'; | |||
const secondaryActionKey = 'secondaryAction'; | |||
|
|||
export const InAppEditor = ({ uiSchema }: { uiSchema?: UiSchema }) => { | |||
if (!uiSchema || uiSchema?.group !== UiSchemaGroupEnum.IN_APP) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if its better to check for uiSchema
in child or parent - moved to parent for consistency with email-editor
✅ Deploy Preview for dev-web-novu ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
✅ Deploy Preview for dashboard-v2-novu-staging ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
What changed? Why was the change needed?
The preview components already had the logic to wait for preview data - the issue was that it was incorrectly mounted in
in-app
due to different tabs implementation compared toemail
.tab-switch.mov
slow network:
3g-network.mov