@lightningtv/solid
Advanced tools
Comparing version 2.4.1 to 2.4.2
@@ -7,1 +7,2 @@ import { type Styles } from '@lightningtv/core'; | ||
export declare function combineStyles<T extends Styles>(...styles: (T | undefined)[]): T; | ||
export declare function combineStylesReactive<T extends Styles>(...styles: (T | undefined)[]): T; |
import { isInteger, isArray } from '@lightningtv/core'; | ||
import { createMemo } from 'solid-js'; | ||
import { createMemo, untrack } from 'solid-js'; | ||
/** | ||
@@ -23,2 +23,5 @@ * Converts a color string to a color number value. | ||
export function combineStyles(...styles) { | ||
return untrack(() => flattenStyles(styles)); | ||
} | ||
export function combineStylesReactive(...styles) { | ||
return createMemo(() => flattenStyles(styles))(); | ||
@@ -25,0 +28,0 @@ } |
{ | ||
"name": "@lightningtv/solid", | ||
"version": "2.4.1", | ||
"version": "2.4.2", | ||
"description": "Lightning Renderer for Solid Universal", | ||
@@ -45,3 +45,3 @@ "type": "module", | ||
"dependencies": { | ||
"@lightningtv/core": "^2.4.2", | ||
"@lightningtv/core": "^2.4.3", | ||
"@solid-primitives/event-listener": "^2.3.3", | ||
@@ -48,0 +48,0 @@ "@solid-primitives/mouse": "^2.0.19", |
@@ -42,3 +42,3 @@ <p> | ||
[![Watch the video](https://img.youtube.com/vi/mWJ9CEiizeE/0.jpg)](https://www.youtube.com/watch?v=9UU7Ntf7Tww) | ||
[![Watch the video](https://img.youtube.com/vi/9UU7Ntf7Tww/0.jpg)](https://www.youtube.com/watch?v=9UU7Ntf7Tww) | ||
@@ -45,0 +45,0 @@ Read the article: |
import { isInteger, isArray, type Styles } from '@lightningtv/core'; | ||
import { createMemo } from 'solid-js'; | ||
import { createMemo, untrack } from 'solid-js'; | ||
@@ -32,2 +32,8 @@ /** | ||
): T { | ||
return untrack(() => flattenStyles(styles)); | ||
} | ||
export function combineStylesReactive<T extends Styles>( | ||
...styles: (T | undefined)[] | ||
): T { | ||
return createMemo(() => flattenStyles(styles))(); | ||
@@ -34,0 +40,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
169220
2125
Updated@lightningtv/core@^2.4.3