@tripetto/block-variable
Version:
Variable block for Tripetto.
29 lines (28 loc) • 1.18 kB
TypeScript
import { Collection, NodeBlock, Slots } from "@tripetto/builder";
/**
* This block has a dependency on the calculator block. We need to activate a
* separate namespace for it to guard against version conflicts when another
* block depends on another version of the calculator block.
*/
import "./namespace/mount";
import { ICalculator, Operation } from "@tripetto/block-calculator";
import "./namespace/unmount";
export declare class Variable extends NodeBlock implements ICalculator {
readonly allowMarkdown = false;
readonly startBlank = false;
currentType: "text" | "numeric" | "boolean" | "date" | undefined;
slot: Slots.Text | Slots.Numeric | Slots.Boolean | Slots.Date;
prefill?: string | number | boolean;
calculator?: true | undefined;
readonly operations: Collection.Provider<Operation, ICalculator>;
get block(): this;
get firstANS(): string;
get variableType(): "text" | "numeric" | "boolean" | "date";
set variableType(type: "text" | "numeric" | "boolean" | "date");
get icon(): string;
get label(): string;
private createProxy;
defineSlot(): void;
defineEditor(): void;
defineCondition(): void;
}