@jimka/typescript-ui / core / InlineStyle
Class: InlineStyle
Defined in: src/typescript/lib/core/StyleTarget.ts:155
Deferred-write buffer for inline element.style writes. Stays detached until InlineStyle.attach runs — typically from Component.init once the root element exists.
Extends
StyleTarget<HTMLElement>
Constructors
new InlineStyle()
new InlineStyle(): InlineStyleReturns
Inherited from
Methods
attach()
attach(element: HTMLElement): voidDefined in: src/typescript/lib/core/StyleTarget.ts:159
Binds this buffer to a live element and flushes any queued writes.
Parameters
element
HTMLElement
Returns
void
flush()
flush(): voidDefined in: src/typescript/lib/core/StyleTarget.ts:74
Drains the dirty bag onto the live target. No-op when the target is not yet attached — the dirty entries stay queued for the next flush after materialize.
Returns
void
Inherited from
isMaterialized()
isMaterialized(): booleanDefined in: src/typescript/lib/core/StyleTarget.ts:85
Returns whether the underlying target has been materialised.
Returns
boolean
Inherited from
queue()
queue(key: string, value: null | string): voidDefined in: src/typescript/lib/core/StyleTarget.ts:56
Writes a single style property into the dirty bag without flushing, even when the target is already attached. Callers that own their own batching gate (e.g. autoCommitStyle = false) use this to accumulate writes that StyleTarget.flush will drain later.
Parameters
key
string
The CSS property name (camelCase).
value
The value to set, or null to remove the property.
null | string
Returns
void
Inherited from
queueMany()
queueMany(values: Record<string, null | string>): voidDefined in: src/typescript/lib/core/StyleTarget.ts:65
Bulk variant of StyleTarget.queue.
Parameters
values
Record<string, null | string>
Camel-cased property keys mapped to string values (or null to clear).
Returns
void
Inherited from
set()
set(key: string, value: null | string): voidDefined in: src/typescript/lib/core/StyleTarget.ts:30
Writes a single style property. Flushes immediately when the target is attached; otherwise queues the entry into the dirty bag.
Parameters
key
string
The CSS property name (camelCase).
value
The value to set, or null to remove the property.
null | string
Returns
void
Inherited from
setMany()
setMany(values: Record<string, null | string>): voidDefined in: src/typescript/lib/core/StyleTarget.ts:43
Bulk variant of StyleTarget.set.
Parameters
values
Record<string, null | string>
Camel-cased property keys mapped to string values (or null to clear).
Returns
void