@lightningtv/core
Advanced tools
Comparing version 2.2.0-beta.5 to 2.2.0-beta.6
@@ -6,3 +6,4 @@ import { createShader } from './lightningInit.js'; | ||
import './focusManager.js'; | ||
export interface ElementNode extends AddColorString<Partial<Omit<INodeProps, 'parent' | 'shader'>>> { | ||
export type RendererNode = AddColorString<Partial<Omit<INodeProps, 'parent' | 'shader'>>>; | ||
export interface ElementNode extends RendererNode { | ||
[key: string]: unknown; | ||
@@ -9,0 +10,0 @@ _animationQueue?: Array<{ |
@@ -1,4 +0,3 @@ | ||
import { type FadeOutEffectProps, type GlitchEffectProps, type GrayscaleEffectProps, type AnimationSettings as RendererAnimationSettings, type LinearGradientEffectProps, type RadialGradientEffectProps, type RadialProgressEffectProps, type ITextNode } from '@lightningjs/renderer'; | ||
import { ElementNode } from './elementNode.js'; | ||
import { NodeStates } from './states.js'; | ||
import { type FadeOutEffectProps, type GlitchEffectProps, type GrayscaleEffectProps, type AnimationSettings as RendererAnimationSettings, type LinearGradientEffectProps, type RadialGradientEffectProps, type RadialProgressEffectProps, type ITextNodeProps } from '@lightningjs/renderer'; | ||
import { ElementNode, type RendererNode } from './elementNode.js'; | ||
export type AnimationSettings = Partial<RendererAnimationSettings> | undefined; | ||
@@ -43,4 +42,5 @@ export type AddColorString<T> = { | ||
}; | ||
type RendererText = AddColorString<Partial<Omit<ITextNodeProps, 'debug' | 'shader' | 'parent'>>>; | ||
/** Node text, children of a ElementNode of type TextNode */ | ||
export interface ElementText extends Partial<Omit<ITextNode, 'id' | 'parent' | 'shader'>>, Partial<Omit<ElementNode, '_type'>> { | ||
export interface ElementText extends Partial<NewOmit<ElementNode, '_type'>>, RendererText { | ||
id?: string; | ||
@@ -50,8 +50,7 @@ _type: 'text'; | ||
text: string; | ||
states?: NodeStates; | ||
_queueDelete?: boolean; | ||
} | ||
export interface NodeProps extends Partial<NewOmit<ElementNode, 'children' | 'contain' | 'fontFamily' | 'fontSize' | 'fontStretch' | 'fontStyle' | 'fontWeight' | 'letterSpacing' | 'lineHeight' | 'maxLines' | 'overflowSuffix' | 'text' | 'textAlign' | 'textBaseline' | 'textOverflow' | 'verticalAlign' | 'wordWrap'>> { | ||
export interface NodeProps extends RendererNode, Partial<NewOmit<ElementNode, 'children' | 'text'>> { | ||
} | ||
export interface TextProps extends Partial<NewOmit<ElementNode, 'autosize' | 'children' | 'clipping' | 'linearGradient' | 'src' | 'texture' | 'textureOptions' | 'transition'>> { | ||
export interface TextProps extends RendererText, Partial<NewOmit<ElementNode, 'autosize' | 'children' | 'clipping' | 'linearGradient' | 'src' | 'texture' | 'textureOptions'>> { | ||
} | ||
@@ -61,2 +60,3 @@ export type Styles = { | ||
}; | ||
export {}; | ||
//# sourceMappingURL=intrinsicTypes.d.ts.map |
{ | ||
"name": "@lightningtv/core", | ||
"version": "2.2.0-beta.5", | ||
"version": "2.2.0-beta.6", | ||
"description": "Lightning TV Core for Universal Renderers", | ||
@@ -5,0 +5,0 @@ "type": "module", |
@@ -169,4 +169,6 @@ import { renderer, createShader } from './lightningInit.js'; | ||
export interface ElementNode | ||
extends AddColorString<Partial<Omit<INodeProps, 'parent' | 'shader'>>> { | ||
export type RendererNode = AddColorString< | ||
Partial<Omit<INodeProps, 'parent' | 'shader'>> | ||
>; | ||
export interface ElementNode extends RendererNode { | ||
[key: string]: unknown; | ||
@@ -434,3 +436,3 @@ | ||
setFocus() { | ||
setFocus(): void { | ||
if (this.rendered) { | ||
@@ -437,0 +439,0 @@ // can be 0 |
@@ -9,6 +9,5 @@ import { | ||
type RadialProgressEffectProps, | ||
type ITextNode, | ||
type ITextNodeProps, | ||
} from '@lightningjs/renderer'; | ||
import { ElementNode } from './elementNode.js'; | ||
import { NodeStates } from './states.js'; | ||
import { ElementNode, type RendererNode } from './elementNode.js'; | ||
@@ -62,6 +61,9 @@ export type AnimationSettings = Partial<RendererAnimationSettings> | undefined; | ||
type RendererText = AddColorString< | ||
Partial<Omit<ITextNodeProps, 'debug' | 'shader' | 'parent'>> | ||
>; | ||
/** Node text, children of a ElementNode of type TextNode */ | ||
export interface ElementText | ||
extends Partial<Omit<ITextNode, 'id' | 'parent' | 'shader'>>, | ||
Partial<Omit<ElementNode, '_type'>> { | ||
extends Partial<NewOmit<ElementNode, '_type'>>, | ||
RendererText { | ||
id?: string; | ||
@@ -71,3 +73,2 @@ _type: 'text'; | ||
text: string; | ||
states?: NodeStates; | ||
_queueDelete?: boolean; | ||
@@ -77,38 +78,18 @@ } | ||
export interface NodeProps | ||
extends Partial< | ||
NewOmit< | ||
ElementNode, | ||
| 'children' | ||
| 'contain' | ||
| 'fontFamily' | ||
| 'fontSize' | ||
| 'fontStretch' | ||
| 'fontStyle' | ||
| 'fontWeight' | ||
| 'letterSpacing' | ||
| 'lineHeight' | ||
| 'maxLines' | ||
| 'overflowSuffix' | ||
| 'text' | ||
| 'textAlign' | ||
| 'textBaseline' | ||
| 'textOverflow' | ||
| 'verticalAlign' | ||
| 'wordWrap' | ||
> | ||
> {} | ||
extends RendererNode, | ||
Partial<NewOmit<ElementNode, 'children' | 'text'>> {} | ||
export interface TextProps | ||
extends Partial< | ||
NewOmit< | ||
ElementNode, | ||
| 'autosize' | ||
| 'children' | ||
| 'clipping' | ||
| 'linearGradient' | ||
| 'src' | ||
| 'texture' | ||
| 'textureOptions' | ||
| 'transition' | ||
> | ||
> {} | ||
extends RendererText, | ||
Partial< | ||
NewOmit< | ||
ElementNode, | ||
| 'autosize' | ||
| 'children' | ||
| 'clipping' | ||
| 'linearGradient' | ||
| 'src' | ||
| 'texture' | ||
| 'textureOptions' | ||
> | ||
> {} | ||
@@ -115,0 +96,0 @@ export type Styles = { |
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
Sorry, the diff of this file is not supported yet
204612
3044