Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export const Default: StoryObj<LineageFilterProps> = {
const input = await inputField(canvas);
await userEvent.clear(input);
await userEvent.type(input, 'B.1');
await userEvent.click(canvas.getByRole('option', { name: 'B.1(53802)' }));
await userEvent.click(canvas.getByRole('option', { name: 'B.1(53,802)' }));

await waitFor(() => {
return expect(lineageChangedListenerMock.mock.calls.at(-1)![0].detail).toStrictEqual({
Expand Down
2 changes: 1 addition & 1 deletion components/src/preact/lineageFilter/lineage-filter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ const LineageSelector = ({
formatItemInList={(item: LineageItem) => (
<p>
<span>{item.lineage}</span>
{!hideCounts && <span className='ml-2 text-gray-500'>({item.count})</span>}
{!hideCounts && <span className='ml-2 text-gray-500'>({item.count.toLocaleString('en-US')})</span>}
</p>
)}
/>
Expand Down
4 changes: 3 additions & 1 deletion components/src/preact/locationFilter/location-filter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ const LocationSelector = ({
<>
<p>
<span>{item.label}</span>
{!hideCounts && <span className='ml-2 text-gray-500'>({item.count})</span>}
{!hideCounts && (
<span className='ml-2 text-gray-500'>({item.count.toLocaleString('en-US')})</span>
)}
</p>
<span className='text-sm text-gray-500'>{item.description}</span>
</>
Expand Down
4 changes: 3 additions & 1 deletion components/src/preact/textFilter/text-filter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,9 @@ const TextSelector = ({
return (
<p>
<span>{item.value}</span>
{!hideCounts && <span className='ml-2 text-gray-500'>({item.count})</span>}
{!hideCounts && (
<span className='ml-2 text-gray-500'>({item.count.toLocaleString('en-US')})</span>
)}
</p>
);
}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ export const FiresEvent: StoryObj<Required<LineageFilterProps>> = {

await step('Enter a valid lineage value', async () => {
await userEvent.type(inputField(), 'B.1.1.7*');
await userEvent.click(canvas.getByRole('option', { name: 'B.1.1.7*(677146)' }));
await userEvent.click(canvas.getByRole('option', { name: 'B.1.1.7*(677,146)' }));

await waitFor(() => {
return expect(listenerMock.mock.calls.at(-1)![0].detail).toStrictEqual({
Expand Down