Skip to content

Commit

Permalink
chore: wait for unknown lettermark (#17346)
Browse files Browse the repository at this point in the history
* chore: wait for unknown lettermark
  • Loading branch information
daibhin authored Sep 11, 2023
1 parent 8592992 commit 41d555e
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions .storybook/test-runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ const LOADER_SELECTORS = [
'.LemonTableLoader',
'[aria-busy="true"]',
'.SessionRecordingPlayer--buffering',
'.Lettermark--unknown',
]

const customSnapshotsDir = `${process.cwd()}/frontend/__snapshots__`
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/lib/lemon-ui/Lettermark/Lettermark.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ const meta: Meta<typeof Lettermark> = {
'Lettermarks are used as visual, icon-like representations of actors (project members, organizations, query steps, cohort criteria groups, etc) in the product. Lettermarks should vary between the 8 variants we have shown below. Ideally the same colour is not placed next to each other',
},
},
testOptions: {
waitForLoadersToDisappear: false,
},
},
tags: ['autodocs'],
}
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/lib/lemon-ui/Lettermark/Lettermark.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ export function Lettermark({ name, index, color, rounded = false }: LettermarkPr
className={clsx(
'Lettermark',
colorIndex && `Lettermark--variant-${colorIndex}`,
rounded && `Lettermark--rounded`
rounded && `Lettermark--rounded`,
representation === '?' && 'Lettermark--unknown'
)}
title={String(name)}
>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/scenes/ingestion/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export function Sidebar(): JSX.Element {
{currentOrganization?.teams && currentOrganization.teams.length > 1 && (
<>
<LemonButtonWithDropdown
icon={<Lettermark name={currentOrganization?.name} />}
icon={<Lettermark name={currentOrganization.name} />}
onClick={() => toggleProjectSwitcher()}
dropdown={{
visible: isProjectSwitcherShown,
Expand Down

0 comments on commit 41d555e

Please sign in to comment.