Home / File/ apply-config-to-theme.test.ts — tailwindcss Source File

apply-config-to-theme.test.ts — tailwindcss Source File

Architecture documentation for apply-config-to-theme.test.ts, a typescript file in the tailwindcss codebase. 11 imports, 0 dependents.

File typescript Oxide 11 imports

Entity Profile

Dependency Diagram

graph LR
  a922bb33_3f2e_e308_4b32_7fce412f48e0["apply-config-to-theme.test.ts"]
  bdedd2f6_da4b_69dc_e990_0814b59fbe6e["design-system.ts"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> bdedd2f6_da4b_69dc_e990_0814b59fbe6e
  e557c8a4_bb27_ee44_c462_9e238157ad04["buildDesignSystem"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> e557c8a4_bb27_ee44_c462_9e238157ad04
  e28cd4a7_4e1a_e79b_76f1_86c479c6640d["theme.ts"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> e28cd4a7_4e1a_e79b_76f1_86c479c6640d
  e7a2e966_188e_28f5_d9d6_e54e27e0d0f2["Theme"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> e7a2e966_188e_28f5_d9d6_e54e27e0d0f2
  f504aa6c_d026_cb8e_0a17_653514de8526["ThemeOptions"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> f504aa6c_d026_cb8e_0a17_653514de8526
  8d84257d_f3b2_cdf8_542f_835967da0481["apply-config-to-theme.ts"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> 8d84257d_f3b2_cdf8_542f_835967da0481
  652fb7ad_2f22_0667_c96e_43b408d0edbe["applyConfigToTheme"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> 652fb7ad_2f22_0667_c96e_43b408d0edbe
  1767219e_c38a_227c_492b_5d47634d54a4["keyPathToCssProperty"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> 1767219e_c38a_227c_492b_5d47634d54a4
  cad44155_17aa_e1d6_081a_8f3b4f06bcde["resolve-config.ts"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> cad44155_17aa_e1d6_081a_8f3b4f06bcde
  bc7b25d3_d5ad_3609_d595_c9755dfadcbb["resolveConfig"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> bc7b25d3_d5ad_3609_d595_c9755dfadcbb
  f1e05e5f_c1b2_a3f5_b2e8_3317b9243ac3["vitest"]
  a922bb33_3f2e_e308_4b32_7fce412f48e0 --> f1e05e5f_c1b2_a3f5_b2e8_3317b9243ac3
  style a922bb33_3f2e_e308_4b32_7fce412f48e0 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { describe, expect, test } from 'vitest'
import { buildDesignSystem } from '../design-system'
import { Theme, ThemeOptions } from '../theme'
import { applyConfigToTheme, keyPathToCssProperty } from './apply-config-to-theme'
import { resolveConfig } from './config/resolve-config'

test('config values can be merged into the theme', () => {
  let theme = new Theme()
  let design = buildDesignSystem(theme)

  let { resolvedConfig, replacedThemeKeys } = resolveConfig(design, [
    {
      config: {
        theme: {
          colors: {
            primary: '#c0ffee',
            red: {
              500: 'red',
            },
          },

          screens: {
            sm: '1234px',
          },

          aspectRatio: {
            retro: '4 / 3',
          },

          boxShadow: {
            normal: '0 1px 3px black',
          },

          borderWidth: {
            DEFAULT: '1.5px',
          },
          outlineWidth: {
            DEFAULT: '2.5px',
          },
          ringWidth: {
            DEFAULT: '3.5px',
          },

          borderRadius: {
            sm: '0.33rem',
          },

          animation: {
            blink: 'blink 1s linear infinite',
          },

          fontFamily: {
            sans: ['Inter', 'system-ui', 'sans-serif'],
            mono: ['Potato Mono', { fontVariationSettings: '"XHGT" 0.7' }],
          },

          fontSize: {
            sm: '0.875rem',
            base: [
              '1rem',
// ... (260 more lines)

Domain

Frequently Asked Questions

What does apply-config-to-theme.test.ts do?
apply-config-to-theme.test.ts is a source file in the tailwindcss codebase, written in typescript. It belongs to the Oxide domain.
What does apply-config-to-theme.test.ts depend on?
apply-config-to-theme.test.ts imports 11 module(s): Theme, ThemeOptions, apply-config-to-theme.ts, applyConfigToTheme, buildDesignSystem, design-system.ts, keyPathToCssProperty, resolve-config.ts, and 3 more.
Where is apply-config-to-theme.test.ts in the architecture?
apply-config-to-theme.test.ts is located at packages/tailwindcss/src/compat/apply-config-to-theme.test.ts (domain: Oxide, 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