Do not mount the command menu when the user is logged out (#8808)
Fixes two bugs: - The command menu contains hooks which were trying to execute queries even when the user was logged out - The command menu could be opened with the command + K shortcut even when the user was logged out
This commit is contained in:
@ -88,19 +88,23 @@ export const DefaultLayout = () => {
|
|||||||
`}
|
`}
|
||||||
/>
|
/>
|
||||||
<StyledLayout>
|
<StyledLayout>
|
||||||
<ContextStoreComponentInstanceContext.Provider
|
{!showAuthModal && (
|
||||||
value={{ instanceId: 'command-menu' }}
|
<>
|
||||||
>
|
<ContextStoreComponentInstanceContext.Provider
|
||||||
<ActionMenuComponentInstanceContext.Provider
|
value={{ instanceId: 'command-menu' }}
|
||||||
value={{ instanceId: 'command-menu' }}
|
>
|
||||||
>
|
<ActionMenuComponentInstanceContext.Provider
|
||||||
<RecordActionMenuEntriesSetter />
|
value={{ instanceId: 'command-menu' }}
|
||||||
{isWorkflowEnabled && <RecordAgnosticActionsSetterEffect />}
|
>
|
||||||
<ActionMenuConfirmationModals />
|
<RecordActionMenuEntriesSetter />
|
||||||
<CommandMenu />
|
{isWorkflowEnabled && <RecordAgnosticActionsSetterEffect />}
|
||||||
</ActionMenuComponentInstanceContext.Provider>
|
<ActionMenuConfirmationModals />
|
||||||
</ContextStoreComponentInstanceContext.Provider>
|
<CommandMenu />
|
||||||
<KeyboardShortcutMenu />
|
</ActionMenuComponentInstanceContext.Provider>
|
||||||
|
</ContextStoreComponentInstanceContext.Provider>
|
||||||
|
<KeyboardShortcutMenu />
|
||||||
|
</>
|
||||||
|
)}
|
||||||
|
|
||||||
<StyledPageContainer
|
<StyledPageContainer
|
||||||
animate={{
|
animate={{
|
||||||
|
|||||||
Reference in New Issue
Block a user