Scripting API

Scripting API

UiRule

Record in Abyss.Core, from Abyss.Core.

A field of an element a stylesheet's rule sets, and the rule.

public record UiRule

Constructors

UiRule

public UiRule(ComponentId Component, string ComponentName, string Path, string Css, string Value, string Sheet, string? Selector, int Line, bool Overridden = false)

A field of an element a stylesheet's rule sets, and the rule.

Parameters

  • Component: The component the field is in.
  • ComponentName: The component's name, as the inspector names it.
  • Path: Where the field is in it, as the inspector's rows name it: width, 0, padding.left.
  • Css: The property as CSS names it: width, background-color.
  • Value: What the rule gives it, as CSS would write it: 14px, #ffd877.
  • Sheet: The sheet the rule is in, by its path under the assets.
  • Selector: The rule's selector as the sheet writes it; null where the sheet's text says otherwise.
  • Line: The line the rule begins on, from one; zero where its selector is not known.
  • Overridden: Whether the element sets the field over the rule, by its UiInline, so its own value is what is drawn.

Properties

Component

public ComponentId Component { get; init; }

The component the field is in.

ComponentName

public string ComponentName { get; init; }

The component's name, as the inspector names it.

Path

public string Path { get; init; }

Where the field is in it, as the inspector's rows name it: width, 0, padding.left.

Css

public string Css { get; init; }

The property as CSS names it: width, background-color.

Value

public string Value { get; init; }

What the rule gives it, as CSS would write it: 14px, #ffd877.

Sheet

public string Sheet { get; init; }

The sheet the rule is in, by its path under the assets.

Selector

public string? Selector { get; init; }

The rule's selector as the sheet writes it; null where the sheet's text says otherwise.

Line

public int Line { get; init; }

The line the rule begins on, from one; zero where its selector is not known.

Overridden

public bool Overridden { get; init; }

Whether the element sets the field over the rule, by its UiInline, so its own value is what is drawn.