Home / Function/ getPropertyValue() — tailwindcss Function Reference

getPropertyValue() — tailwindcss Function Reference

Architecture documentation for the getPropertyValue() function in ui.spec.ts from the tailwindcss codebase.

Entity Profile

Dependency Diagram

graph TD
  cbd2dae8_fa66_4365_0be4_4d91c2f5bba4["getPropertyValue()"]
  4ccd2731_2148_46c0_9c34_d4351473d556["ui.spec.ts"]
  cbd2dae8_fa66_4365_0be4_4d91c2f5bba4 -->|defined in| 4ccd2731_2148_46c0_9c34_d4351473d556
  9145d6d8_3bea_1987_00eb_b9dbd7e9cb8d["render()"]
  9145d6d8_3bea_1987_00eb_b9dbd7e9cb8d -->|calls| cbd2dae8_fa66_4365_0be4_4d91c2f5bba4
  f712ed47_45d4_4e5a_dd73_fdefa1da71da["segment()"]
  cbd2dae8_fa66_4365_0be4_4d91c2f5bba4 -->|calls| f712ed47_45d4_4e5a_dd73_fdefa1da71da
  style cbd2dae8_fa66_4365_0be4_4d91c2f5bba4 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/tailwindcss/tests/ui.spec.ts lines 2247–2272

async function getPropertyValue(
  page: Page,
  selector: [string, string | undefined],
  property: string,
) {
  let value = await page.evaluate(
    ([[selector, pseudo], property]) => {
      return window
        .getComputedStyle(document.querySelector(selector)!, pseudo)
        .getPropertyValue(property)
    },
    [selector, property] as const,
  )

  switch (property) {
    case 'outline':
      // Order in webkit vs chromium is different. Sort to normalize.
      return segment(value, ' ')
        .map((part) => part.trim())
        .sort((a, z) => a.length - z.length)
        .join(' ')

    default:
      return value
  }
}

Domain

Subdomains

Calls

Called By

Frequently Asked Questions

What does getPropertyValue() do?
getPropertyValue() is a function in the tailwindcss codebase, defined in packages/tailwindcss/tests/ui.spec.ts.
Where is getPropertyValue() defined?
getPropertyValue() is defined in packages/tailwindcss/tests/ui.spec.ts at line 2247.
What does getPropertyValue() call?
getPropertyValue() calls 1 function(s): segment.
What calls getPropertyValue()?
getPropertyValue() is called by 1 function(s): render.

Analyze Your Own Codebase

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

Try Supermodel Free