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.

Entity Profile

Dependency Diagram

graph LR
  15f6e0f9_47e6_d527_cc67_b512886528af["apply-config-to-theme.test.ts"]
  7fd72d4c_e95c_d849_1002_1e1c9d8aca1a["design-system.ts"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 7fd72d4c_e95c_d849_1002_1e1c9d8aca1a
  9b965fd7_d8e9_0b43_cd5d_c9294ab598ed["buildDesignSystem"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 9b965fd7_d8e9_0b43_cd5d_c9294ab598ed
  80295787_127f_69e6_91b3_4bea3a484544["theme.ts"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 80295787_127f_69e6_91b3_4bea3a484544
  734cf7ec_fb2a_2532_7b20_b3a815c7e3e6["Theme"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 734cf7ec_fb2a_2532_7b20_b3a815c7e3e6
  e64872c9_9835_78a8_455b_ad5e699f9543["ThemeOptions"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> e64872c9_9835_78a8_455b_ad5e699f9543
  245c850a_c551_a2cf_854e_bba95b5a1339["apply-config-to-theme.ts"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 245c850a_c551_a2cf_854e_bba95b5a1339
  9fb2cb3b_46e1_4148_c220_0e7f4519db6d["applyConfigToTheme"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 9fb2cb3b_46e1_4148_c220_0e7f4519db6d
  ae20c4fb_29d7_ca79_3c49_ca02c45d5369["keyPathToCssProperty"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> ae20c4fb_29d7_ca79_3c49_ca02c45d5369
  9b5d2e3d_392e_c654_c350_1352ed70f5e8["resolve-config.ts"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 9b5d2e3d_392e_c654_c350_1352ed70f5e8
  0ed24ba5_7c39_3f5a_fdbb_f973a617a172["resolveConfig"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 0ed24ba5_7c39_3f5a_fdbb_f973a617a172
  696bd648_5f24_1b59_8e8b_7a97a692869e["vitest"]
  15f6e0f9_47e6_d527_cc67_b512886528af --> 696bd648_5f24_1b59_8e8b_7a97a692869e
  style 15f6e0f9_47e6_d527_cc67_b512886528af 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 OxideEngine 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: 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