Implement comprehensive dark/light mode overhaul for admin panel
- Refactor color palette in `ui-design-spec.md` to utilize CSS variables exclusively, eliminating fixed hex values and Tailwind utility classes. - Complete dark mode implementation in `uiStore.ts`, ensuring proper theme application via `applyTheme()` and `applyBrand()`. - Create `admin-theme-dark-light-audit.md` to document the transition process, outlining issues with inline styles and fixed colors. - Introduce `theme-tokens.test.ts` to enforce rules against fixed hex colors and ensure compliance with the design system. - Update various components and styles to replace inline styles and fixed colors with CSS variables, ensuring consistent theming across light and dark modes. - Ensure all changes maintain visual integrity in both light and dark modes, with a focus on accessibility and contrast standards.
This commit is contained in:
@@ -23,9 +23,9 @@ describe('SessionStepper', () => {
|
||||
|
||||
it('کانکتور گامهای طیشده بنفش و بقیه خاکستری', () => {
|
||||
render(<SessionStepper steps={STEPS} activeStep={1} />);
|
||||
// jsdom رنگ hex را به rgb نرمال میکند
|
||||
expect(screen.getByTestId('step-connector-1').style.background).toContain('rgb(85, 89, 206)');
|
||||
expect(screen.getByTestId('step-connector-2').style.background).toContain('rgb(234, 234, 240)');
|
||||
// رنگها از توکنهای تم میآیند تا در دارکمود هم درست باشند
|
||||
expect(screen.getByTestId('step-connector-1').style.background).toContain('var(--primary)');
|
||||
expect(screen.getByTestId('step-connector-2').style.background).toContain('var(--surface-2)');
|
||||
});
|
||||
|
||||
it('استپر خالی: بدون کرش و بدون کانکتور', () => {
|
||||
|
||||
Reference in New Issue
Block a user