New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@lightningtv/core

Package Overview
Dependencies
Maintainers
0
Versions
153
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lightningtv/core - npm Package Compare versions

Comparing version 2.5.0 to 2.5.1

2

dist/src/elementNode.d.ts

@@ -141,3 +141,3 @@ import { createShader } from './lightningInit.js';

_destroy(): void;
set style(values: (Styles | undefined)[] | Styles);
set style(style: Styles | undefined | (() => Styles | undefined));
get style(): Styles;

@@ -144,0 +144,0 @@ get hasChildren(): boolean;

import { renderer, createShader } from './lightningInit.js';
import States from './states.js';
import calculateFlex from './flex.js';
import { log, isArray, isNumber, isFunc, keyExists, flattenStyles, isINode, isElementNode, isElementText, isTextNode, logRenderTree, } from './utils.js';
import { log, isArray, isNumber, isFunc, keyExists, isINode, isElementNode, isElementText, isTextNode, logRenderTree, } from './utils.js';
import { Config, isDev } from './config.js';

@@ -329,3 +329,3 @@ import { assertTruthy } from '@lightningjs/renderer/utils';

}
set style(values) {
set style(style) {
if (isDev && this._style) {

@@ -335,17 +335,11 @@ // Avoid processing style changes again

}
if (isArray(values)) {
console.warn('Array style values are deprecated, use combineStyles: https://lightning-tv.github.io/solid/#/essentials/styling?id=style-patterns-to-avoid');
const v = values.filter(Boolean);
if (v.length === 0) {
return;
}
else if (v.length === 1) {
this._style = isArray(v[0]) ? flattenStyles(v[0]) : v[0];
}
else {
this._style = flattenStyles(v);
}
if (!style) {
return;
}
// allow passing in memo function
if (isFunc(style)) {
this._style = style();
}
else {
this._style = values;
this._style = style;
}

@@ -352,0 +346,0 @@ // Keys set in JSX are more important

{
"name": "@lightningtv/core",
"version": "2.5.0",
"version": "2.5.1",
"description": "Lightning TV Core for Universal Renderers",

@@ -5,0 +5,0 @@ "type": "module",

@@ -569,3 +569,3 @@ import { renderer, createShader } from './lightningInit.js';

set style(values: (Styles | undefined)[] | Styles) {
set style(style: Styles | undefined | (() => Styles | undefined)) {
if (isDev && this._style) {

@@ -578,17 +578,12 @@ // Avoid processing style changes again

if (isArray(values)) {
console.warn(
'Array style values are deprecated, use combineStyles: https://lightning-tv.github.io/solid/#/essentials/styling?id=style-patterns-to-avoid',
);
const v = values.filter(Boolean);
if (v.length === 0) {
return;
} else if (v.length === 1) {
this._style = isArray(v[0]) ? flattenStyles(v[0]) : v[0];
} else {
this._style = flattenStyles(v);
}
if (!style) {
return;
}
// allow passing in memo function
if (isFunc(style)) {
this._style = style();
} else {
this._style = values;
this._style = style;
}
// Keys set in JSX are more important

@@ -595,0 +590,0 @@ for (const key in this._style) {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc