Skip to content

Commit

Permalink
Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
bmingles committed Nov 22, 2023
1 parent 0eeb9e2 commit a164b70
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions packages/components/src/theme/ThemeUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ export function calculatePreloadStyleContent(): CssVariableStyleContent {

/**
* Create a resolver function for calculating the value of a css variable based
* on a given element's computed style.
* on a given element's computed style. If the variable resolves to '', we check
* DEFAULT_PRELOAD_DATA_VARIABLES for a default value, and if one does not exist,
* return ''.
* @param el Element to resolve css variables against
*/
export function createCssVariableResolver(
Expand Down Expand Up @@ -396,8 +398,8 @@ export function preloadTheme(): void {
}

/**
* Inline SVGs cannot depend on dynamic CSS variables, so we have to explicitly
* change them.
* Inline SVGs cannot depend on dynamic CSS variables, so we have to statically
* update them if we want to change their color.
*
* This function:
* 1. Clears any previous overrides
Expand Down

0 comments on commit a164b70

Please sign in to comment.