Home / File/ flatten-color-palette.test.ts — tailwindcss Source File

flatten-color-palette.test.ts — tailwindcss Source File

Architecture documentation for flatten-color-palette.test.ts, a typescript file in the tailwindcss codebase. 3 imports, 0 dependents.

Entity Profile

Dependency Diagram

graph LR
  273199d3_11db_3412_77b6_95390a859c13["flatten-color-palette.test.ts"]
  7ea5d6e8_c93c_0fe9_ee45_7db80046a7c5["flatten-color-palette.ts"]
  273199d3_11db_3412_77b6_95390a859c13 --> 7ea5d6e8_c93c_0fe9_ee45_7db80046a7c5
  fb8751d6_f450_b27d_e61e_cbe05f028b79["flattenColorPalette"]
  273199d3_11db_3412_77b6_95390a859c13 --> fb8751d6_f450_b27d_e61e_cbe05f028b79
  696bd648_5f24_1b59_8e8b_7a97a692869e["vitest"]
  273199d3_11db_3412_77b6_95390a859c13 --> 696bd648_5f24_1b59_8e8b_7a97a692869e
  style 273199d3_11db_3412_77b6_95390a859c13 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { expect, test } from 'vitest'
import flattenColorPalette from './flatten-color-palette'

test('it should handle private __CSS_VALUES__ to resolve to the right value', () => {
  expect(
    flattenColorPalette({
      'slate-100': '#000100',
      'slate-200': '#000200',
      'slate-300': '#000300',
      'slate-400': '#100400',
      'slate-500': '#100500',
      __CSS_VALUES__: {
        'slate-100': 4,
        'slate-200': 4,
        'slate-300': 4,
        'slate-400': 0,
        'slate-500': 0,
      } as any,
      slate: { '200': '#200200', '400': '#200400', '600': '#200600' },
      'slate-600': '#200600',
    }),
  ).toMatchInlineSnapshot(`
    {
      "slate-100": "#000100",
      "slate-200": "#200200",
      "slate-300": "#000300",
      "slate-400": "#100400",
      "slate-500": "#100500",
      "slate-600": "#200600",
    }
  `)
})

Domain

Frequently Asked Questions

What does flatten-color-palette.test.ts do?
flatten-color-palette.test.ts is a source file in the tailwindcss codebase, written in typescript. It belongs to the OxideEngine domain.
What does flatten-color-palette.test.ts depend on?
flatten-color-palette.test.ts imports 3 module(s): flatten-color-palette.ts, flattenColorPalette, vitest.
Where is flatten-color-palette.test.ts in the architecture?
flatten-color-palette.test.ts is located at packages/tailwindcss/src/compat/flatten-color-palette.test.ts (domain: OxideEngine, directory: packages/tailwindcss/src/compat).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free