Skip to content

Commit 286acc5

Browse files
added skipAuth check (#1525)
1 parent eab8cfd commit 286acc5

2 files changed

Lines changed: 5 additions & 11 deletions

File tree

frontend/src/components/Content.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -966,7 +966,7 @@ const Content: React.FC<ContentProps> = ({
966966
<ButtonWithToolTip
967967
placement='top'
968968
text={
969-
!isAuthenticated
969+
!isAuthenticated && !SKIP_AUTH
970970
? 'Please log in first'
971971
: !connectionStatus
972972
? 'Please connect to Neo4j'
@@ -1049,7 +1049,7 @@ const Content: React.FC<ContentProps> = ({
10491049
<Flex flexDirection='row' gap='4' className='self-end mb-2.5' flexWrap='wrap'>
10501050
<SpotlightTarget id='generategraphbtn'>
10511051
<ButtonWithToolTip
1052-
text={!isAuthenticated ? 'Please log in first' : tooltips.generateGraph}
1052+
text={!isAuthenticated && !SKIP_AUTH ? 'Please log in first' : tooltips.generateGraph}
10531053
placement='top'
10541054
label='generate graph'
10551055
onClick={onClickHandler}
@@ -1064,7 +1064,7 @@ const Content: React.FC<ContentProps> = ({
10641064
</SpotlightTarget>
10651065
<ButtonWithToolTip
10661066
text={
1067-
!isAuthenticated
1067+
!isAuthenticated && !SKIP_AUTH
10681068
? 'Please log in first'
10691069
: !selectedfileslength
10701070
? 'Please select file to delete'

frontend/src/components/Layout/Header.tsx

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import Neo4jLogoBW from '../../logo.svg';
2-
import Neo4jLogoColor from '../../logo-color.svg';
31
import {
42
MoonIconOutline,
53
SunIconOutline,
@@ -10,7 +8,7 @@ import {
108
ArrowLeftIconOutline,
119
ArrowDownTrayIconOutline,
1210
} from '@neo4j-ndl/react/icons';
13-
import { Button, SpotlightTarget, TextLink, Typography, useSpotlightContext } from '@neo4j-ndl/react';
11+
import { Button, SpotlightTarget, TextLink, Typography, useSpotlightContext, Logo } from '@neo4j-ndl/react';
1412
import { useCallback, useContext, useEffect, useRef, useState, useMemo } from 'react';
1513
import { IconButtonWithToolTip } from '../UI/IconButtonToolTip';
1614
import { buttonCaptions, SKIP_AUTH, tooltips } from '../../utils/Constants';
@@ -88,11 +86,7 @@ const Header: React.FC<HeaderProp> = ({ chatOnly, deleteOnClick, setOpenConnecti
8886
>
8987
<section className='flex w-1/3 shrink-0 grow-0 items-center min-w-[200px]'>
9088
<Typography variant='h1'>
91-
<img
92-
src={colorMode === 'dark' ? Neo4jLogoBW : Neo4jLogoColor}
93-
className='h-8! min-h-8 min-w-8'
94-
alt='Neo4j Logo'
95-
/>
89+
<Logo className='h-6 min-h-6 min-w-12 md:h-8 md:min-h-12 md:min-w-24 md:mr-2' type='full' />
9690
</Typography>
9791
</section>
9892
{!chatOnly ? (

0 commit comments

Comments
 (0)