Files
explore/ui/showcases/ProgressCircle.pw.tsx
tom goriunovandGitHub f0e713b877 Add support for customizing the UI color theme (#2923)
* UI customizations: new features

Fixes #2905

* colors for graphs

* introduce env variable

* colors for topbar, stats, selected state and tabs

* fix build

* fix validator

* refactor link.primary.hover color token

* refactor selected colors

* update styles for switch and fix some color tokens

* change color for selectable controls

* icon color tokens refactoring

* UI customizations: new features

Fixes #2905

* test for common components

* tweaks

* migrate from color-mode-hex cookie to color-theme cookie

* clean up

* update screenshots

* more screenshot updates

* update default color of chart line

* update envs for mega eth
2025-08-19 11:58:05 +02:00

19 lines
778 B
TypeScript

import React from 'react';
import { ENVS_MAP } from 'playwright/fixtures/mockEnvs';
import { test, expect } from 'playwright/lib';
import { TabsRoot } from 'toolkit/chakra/tabs';
import ProgressCircle from './ProgressCircle';
test('default +@dark-mode', async({ render, page }) => {
await render(<TabsRoot defaultValue="progress-circle"><ProgressCircle/></TabsRoot>);
await expect(page).toHaveScreenshot({ clip: { x: 0, y: 0, width: 300, height: 400 } });
});
test('color theme overrides +@dark-mode', async({ render, mockEnvs, page }) => {
await mockEnvs(ENVS_MAP.colorThemeOverrides);
await render(<TabsRoot defaultValue="progress-circle"><ProgressCircle/></TabsRoot>);
await expect(page).toHaveScreenshot({ clip: { x: 0, y: 0, width: 300, height: 400 } });
});