initialize

Initializes the Mod API. The specified `onLoaded` callback is called when the initialization is complete.

References

OnLoadCallback is used as a parameter
/* * Copyright © 2025. Cloud Software Group, Inc. * This file is subject to the license terms contained * in the license file that is distributed with this file. */ export as namespace Spotfire; /** * Predicate to determine if a current read operation for {@link DataView.allRows} should be aborted when there is new, non-streaming, data available. If this predicate returns true the {@link DataView.allRows} promise will be rejected and no rows will be returned. * @public */ export declare type AbortPredicate = (currentRowCount: number) => boolean; /** * Represents a property owned by the Spotfire document. * These can be either document properties, data table properties or data column properties. * @public */ export declare interface AnalysisProperty<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> extends AnalysisPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T | T[] | null): void; } /** * Represents the data types possible to store in a document, table or column {@link AnalysisProperty}. * @public */ export declare type AnalysisPropertyDataType = string | number | boolean | Date | TimeSpan | Time; /** * Represents the values held by a {@link AnalysisProperty}. * @public */ export declare interface AnalysisPropertyValue<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> { /** * Gets the name of this instance. */ name: string; /** * Gets the value held by this instance. Will throw if the value is a list, i.e. {@link AnalysisPropertyValue.isList} returns true; */ value<T2 extends T>(): T2 | null; /** * Gets the value held by this instance. Will throw if the value is not a list, i.e. {@link AnalysisPropertyValue.isList} returns false; */ valueList<T2 extends T>(): T2[]; /** * Get the Spotfire internal data type of the property. */ dataType: DataType; /** * Gets a value indicating whether the property is a list. */ isList: boolean; } /** * Represents an axis of the Mod Visualization. * @public */ export declare interface Axis extends AxisValues { /** * Sets the full axis expression to the specified `value`. */ setExpression(value: string): void; } /** * Represents one element of a multi-part axis expression. * @public */ export declare interface AxisPart { /** * Gets the expression of this part. */ expression: string; /** * Gets the display name of this part. */ displayName: string; } /** * Represents the values held by an {@link Axis}. * @public */ export declare interface AxisValues { /** * Gets the name of this instance. */ name: string; /** * Gets the {@link AxisPart}s that this axis has. The parts are derived from the current {@link AxisValues.expression}. */ parts: AxisPart[]; /** * Gets the full expression of this instance, including multi-part delimiters and * surrounding "\<\>" brackets if the axis is in categorical mode. */ expression: string; /** * Gets a value indicating whether the axis is categorical or continuous. */ isCategorical: boolean; } /** * Represents a data column in a Spotfire data table. * @public */ export declare interface Column extends ColumnValues { /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; } /** * Represents the values held by a {@link Column}. * @public */ export declare interface ColumnValues { /** * Gets the name of this instance. */ name: string; /** * Gets the data type of this instance. */ dataType: DataType; } /** * Represents an object with methods to show a context menu. * @public */ export declare interface ContextMenu { /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>; } /** * Represents an item in a context menu shown by calling {@link ContextMenu.show}. * @public */ export declare interface ContextMenuItem { /** * Specifies the text to show in this item. */ text: string; /** * Specifies whether this item is enabled. */ enabled: boolean; /** * Specifies the tooltip to show for this item. If not defined, no tooltip will be shown when hovering the this item. */ tooltip?: string; /** * Specifies a value indicating whether this item is checked. If not defined, this item will not be rendered in a checked state. */ checked?: boolean; } /** * Provides access points to launch Spotfire controls and UI component relevant for a Mod Visualization. * @public */ export declare interface Controls { /** * Gets an object with methods to show a context menu. */ contextMenu: ContextMenu; /** * Gets an object with methods to show and hide a Spotfire tooltip. */ tooltip: Tooltip; /** * Gets an object with methods to show and hide the Spotfire progress indicator. */ progress: Progress; /** * Gets an object that can be used to create and show a Spotfire popout dialog. */ popout: Popout; /** * Gets an object that can be used to show an error overlay native Spotfire style. */ errorOverlay: ErrorOverlay; } /** * Represents the styling information that applies to a control of some kind in the Mod Visualization. * For example, the controls for search, layers, navigation, etc., in a Spotfire Map Chart follows this styling. * @public * @version 2.1 */ export declare interface ControlStylingInfo { /** * Gets the value to use for the `background-color` CSS property. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the color CSS properties in different states. * @version 2.1 */ color: StateDependentValue<string>; } /** * Represents the basic settings of a custom theme used in Spotfire. * @public * @version 2.1 */ export declare interface CustomThemeStylingInfo { /** * Gets a value describing the theme that this custom theme is based on. */ baseTheme: KnownTheme; /** * Gets the base color of the theme. * @version 2.1 */ baseColor: string; /** * Gets the primary color of the theme. * @version 2.1 */ primaryColor: string; } /** * Represents a data table in the Spotfire document. * @public */ export declare interface DataTable extends DataTableValues { /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>; /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>; /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; } /** * Represents the values held by a {@link DataTable}. * @public */ export declare interface DataTableValues { /** * Gets the name of this instance. */ name: string; /** * Gets the number of columns in this instance. */ columnCount: number; /** * Gets the unique id for this instance. * The id is stable during the data table life cycle, thus it can be used to store as a reference to this data table in a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 */ id: string; } /** * Represents the data type of a value. * @public */ export declare interface DataType { /** * Gets the name of this DataType. */ name: "String" | "Integer" | "LongInteger" | "Real" | "SingleReal" | "Currency" | "Boolean" | "Date" | "DateTime" | "Time" | "TimeSpan" | "Binary"; /** * Gets a value indicating whether the data type is numeric or not, that is, * Integer, Currency, Real, LongInteger, or SingleReal. */ isNumber(): boolean; /** * Gets a value indicating whether the data type is represents by Date or not, that is, Date, or DateTime. */ isDate(): boolean; /** * Gets a value indicating whether the data type is represents by {@link Time} or not. */ isTime(): boolean; /** * Gets a value indicating whether the data type is represents by {@link TimeSpan} or not. */ isTimeSpan(): boolean; } /** * Represents a view of the data from which the visualization can be rendered. * * This object contains the result of the query made by Spotfire against the DataTable * currently used by the Mod Visualization, using the Filtering, Marking, expressions * on the Axes and other relevant settings. * @public */ declare interface DataView_2 { /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void; /** * Clears the current marking */ clearMarking(): void; /** * Gets the marking information, or `null` if marking is not enabled. */ marking(): Promise<MarkingInfo | null>; /** * Gets a value indicating whether the dataView has expired. * The dataview has expired when there has been changes to the document, * for example marking or filtering. * When true, there will be a new dataview available on the next read. */ hasExpired(): Promise<boolean>; /** * Gets a value indicating whether the data view is the result of a streaming update. * @version 2.1 */ isStreamingUpdate: boolean; /** * Gets any errors generated while creating the dataview. * Returns empty array if none occurred. */ getErrors(): Promise<string[]>; /** * Gets metadata for a specific categorical axis in the {@link DataView}. * Categorical axes are defined in the manifest file as categorical or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.categorical} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The axis name. */ categoricalAxis(name: string): Promise<DataViewCategoricalAxis | null>; /** * Gets metadata for a specific continuous axis in the {@link DataView}. * Continuous axes are defined in the manifest file as continuous or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.continuous} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in categorical mode. * Throws if the axis does not exist or the axes mode is categorical. * @param name - The axis name. */ continuousAxis(name: string): Promise<DataViewContinuousAxis | null>; /** * Gets metadata of all axes currently present in the {@link DataView}. * Axes with empty expression are omitted. */ axes(): Promise<DataViewAxis[]>; /** * Gets a hierarchy for a categorical axis. * * If the axis has an empty expression the hierarchy will contain one single root node. * Returns `null` for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The name of the axis to get the hierarchy for. */ hierarchy(name: string): Promise<DataViewHierarchy | null>; /** * Gets the total number of rows of the {@link DataView} without actually getting all the rows. Use this function to determine whether or not the mod will be able to handle the amount of data rows. * When there are errors in the mod configuration there will be no rows available and this method will return undefined. */ rowCount(): Promise<number | undefined>; /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>; } export { DataView_2 as DataView } /** * Contains metadata computed for an {@link Axis}. * @public */ export declare interface DataViewAxis { /** * Gets the name of this axis. */ name: string; /** * Gets a value indicating whether this axis is an instance of {@link DataViewContinuousAxis} or {@link DataViewCategoricalAxis} . */ isCategorical: boolean; } /** * Represents metadata computed for a categorical {@link Axis}. * @public */ export declare interface DataViewCategoricalAxis extends DataViewAxis { /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy; } /** * Represents a value of a categorical axis for one row in a data view. * @public */ export declare interface DataViewCategoricalValue { /** * Gets an array representing the full path of the value in the hierarchy defined by the axis expression. * The first element is the top level of the hierarchy and the last element is the leaf level. */ value(): DataViewCategoricalValuePathElement[]; /** * Gets a formatted string that can be used to display this value. * This string is built by concatenating the {@link DataViewCategoricalValuePathElement.formattedValue} for each element found in the {@link DataViewCategoricalValue.value} array. * @param separator - The separator used for concatenation. The default separator is " » ". */ formattedValue(separator?: string): string; /** * Gets the index among the leaf nodes of the associated {@link DataViewHierarchy} of this {@link DataViewCategoricalAxis}. * This, for example, can be used to determine the position on a scale where to render the visual element. */ leafIndex: number; } /** * Represents an element in the `path` of a {@link DataViewCategoricalValue}. * @public */ export declare interface DataViewCategoricalValuePathElement { /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; /** * Gets a key that uniquely identifies this element. * * In many cases this will be the same as {@link DataViewCategoricalValuePathElement.formattedValue} and {@link DataViewCategoricalValuePathElement.value}. * However there are cases when those values can contain duplicates. For instance when working with cube data, * or when using formatters and display values. * * They key is suitable to be used for identifying objects when implementing rendering transitions. * * The key can be `null` when the corresponding {@link DataViewCategoricalValuePathElement.value} is null. */ key: string | null; /** * Gets the value of this element, or `null` if this element represents a missing or invalid data point. * * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the {@link DataViewHierarchy} of * the associated {@link DataViewCategoricalAxis}. */ value<T extends DataViewValueType>(): T | null; } /** * Color information for a {@link DataViewRow}. * @public */ export declare interface DataViewColorInfo { /** The hex code for the color. */ hexCode: string; } /** * Represents metadata computed for continuous {@link Axis}. * @public */ export declare interface DataViewContinuousAxis extends DataViewAxis { /** * Gets the data type of the values computed by this axis. */ dataType: DataType; } /** * Represents a value of a continuous axis for one row in a data view. * @public */ export declare interface DataViewContinuousValue<T extends DataViewValueType = DataViewValueType> { /** * Gets the value of this instance. The type depending on the type of the * expression on the associated {@link DataViewContinuousAxis}. * * This method will return `null` when the underlying data value is missing or invalid. */ value<T2 extends DataViewValueType = T>(): T2 | null; /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; } /** * Represents a hierarchy for a {@link DataViewCategoricalAxis}. * @public */ export declare interface DataViewHierarchy { /** * Gets the name of this hierarchy, the same as the associated {@link DataViewCategoricalAxis}. */ name: string; /** * Gets a value indicating whether the hierarchy is empty, i.e. the axis expression is empty, or not. * For convenience, an empty hierarchy will have one single node that may contain all rows in the dataview. */ isEmpty: boolean; /** * Gets the levels of this hierarchy. The root node has no corresponding level. */ levels: DataViewHierarchyLevel[]; /** * Gets the total number of leaf nodes in the hierarchy. */ leafCount: number; /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>; } /** * Represents the levels of a hierarchy. * @public */ export declare interface DataViewHierarchyLevel { /** * The name of the hierarchy level, derived from the expression on the {@link Axis}. */ name: string; /** * Gets the data type of the values in this level of the hierarchy. */ dataType: DataType; } /** * Represents a node in a {@link DataViewHierarchy}. * @public */ export declare interface DataViewHierarchyNode { /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; /** * Gets the full path, top down to this node, of the formatted values. The virtual root node is omitted. * @param separator - The separator. The default separator is " » ". */ formattedPath(separator?: string): string; /** * Gets the key for this hierarchy node. The key is guaranteed to be unique for the node among its siblings. * * In many cases this will be the same as {@link DataViewHierarchyNode.formattedValue} or {@link DataViewHierarchyNode.value}. * However there are cases when those values can contain duplicates. For instance when working with cube data, * or when using formatters and display values. * * They key is suitable to be used for identifying objects when implementing rendering transitions. * * The key can be `null` when the corresponding {@link DataViewHierarchyNode.value} is null. */ key: string | null; /** * Gets the value of this node, or `null` if this node represents a missing or invalid data point. * * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the associated {@link DataViewHierarchy}. */ value<T extends DataViewValueType>(): T | null; /** * Gets the parent of the hierarchy node, or `undefined` for root level nodes. */ parent?: DataViewHierarchyNode; /** * Gets the children of this node, or `undefined` if this node is a leaf node. */ children?: DataViewHierarchyNode[]; /** * Computes an array of all leaf nodes in the sub tree of the hierarchy spanned from this node. */ leaves(): DataViewHierarchyNode[]; /** * Gets the index of the leaf node among all leaf nodes in the hierarchy. This is undefined for non leaf nodes. */ leafIndex?: number; /** * Marks all {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. * See {@link DataView.mark} for more details. * @param operation - The marking operation. */ mark(operation?: MarkingOperation): void; /** * Computes the number of {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rowCount(): number; /** * Computes the number of leaf nodes in the sub tree of the hierarchy spanned from this node. */ leafCount(): number; /** * Computes the number of marked {@link DataViewRow}s in the sub tree of the hierarchy spanned from this node. */ markedRowCount(): number; /** * Gets the level in the hierarchy where this node occurs. The root node of the hierarchy tree has level -1. */ level: number; /** * Computes the {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rows(): DataViewRow[]; } /** * Represents an object that provides access to a {@link DataView}. * @public */ export declare type DataViewProxy = DataViewProxyMethods & Readable<DataView_2>; /** * Represents the methods available on a {@link DataViewProxy}. * @public */ export declare interface DataViewProxyMethods { /** * Clears the current marking */ clearMarking(): void; } /** * Represents a row of data in a {@link DataView}. Each row can be thought of as a data point that the mod visualization renders. * @public */ export declare interface DataViewRow { /** * Gets a value indicating whether this row is marked. */ isMarked(): boolean; /** * Gets a {@link DataViewCategoricalValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no categorical axis by that name or if the expression is empty. * Use {@link DataView.categoricalAxis} to check the current existence of a categorical value. * @param axisName - The name of the axis to get the value for. */ categorical(axisName: string): DataViewCategoricalValue; /** * Gets a {@link DataViewContinuousValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no continuous axis by that name or if the expression is empty. * Use {@link DataView.continuousAxis} to check the current existence of a continuous value. * @param axisName - The name of the axis to get the value for. */ continuous<T extends DataViewValueType>(axisName: string): DataViewContinuousValue<T>; /** * Gets the leaf {@link DataViewHierarchyNode} for the specified axis, * or `null` for dual mode axes with continuous axis expression. * This method will throw an error for continuous mode axes * or if there is no axis by that name. * @param axisName - The name of the axis * @version 1.1 */ leafNode(axisName: string): DataViewHierarchyNode | null; /** * Calculates an element id for this row, suitable for identifying rows between data views. * When stable identifiers is not used, only rows in immediately following data view are guaranteed to re-use previous id. * If a row is filtered out in a new data view, this row is thus not guaranteed to yield the same id when it re-appears. * * @note A stable element id is only stable in the current session, thus it should not be stored in the document, * e.g. as a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 * * @param useStableId - When true, the id will be a (longer) stable id guaranteed to be the same over time. * @param omitAxisNames - Axis names to omit when creating the identifier. Can be used to group multiple elements split by these axes, for example to create animation effects in one data view. */ elementId(useStableId?: boolean, omitAxisNames?: string[]): string; /** * Gets the {@link DataViewColorInfo} for the row, if a color axis is defined in the mod manifest. * The underlying data value can be retrieved by using {@link DataViewRow.categorical}("Color") or {@link DataViewRow.continuous}("Color"), depending on the mode of the color axis. */ color(): DataViewColorInfo; /** * Performs the specified marking operation in the current marking. * * **Note** All mark operations within one {@link Mod.transaction} must have the same {@link MarkingOperation}. * * See {@link DataView.mark} for more details. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(operation?: MarkingOperation): void; } /** * Represents the type of a {@link DataView} value. The actual type that a given value has depends on the * type of the expression on the associated axis. * @public */ export declare type DataViewValueType = number | string | boolean | Date | Time | TimeSpan; /** * Represents a group of values used for the top, bottom, left and right edges of a CSS property of an associated DOM element. * @public * @version 2.1 */ export declare interface EdgeValues<T> { /** * Gets the value to use for the `-top-` CSS property. For instance `border-top-color`. * @version 2.1 */ top: T; /** * Gets the value to use for the `-bottom-` CSS property. For instance `border-bottom-color`. * @version 2.1 */ bottom: T; /** * Gets the value to use for the `-left-` CSS property. For instance `border-left-color`. * @version 2.1 */ left: T; /** * Gets the value to use for the `-right-` CSS property. For instance `border-right-color`. * @version 2.1 */ right: T; } /** * Provides access to show an error overlay covering the entire Mod shown by Spotfire. * @public */ export declare interface ErrorOverlay { /** * Show error message. Showing any error message will hide the Mods UI. * @param messages - The error messages. Each message will be shown in its own paragraph. * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category. */ show(messages: string[], category?: string): void; /** * Show error message. Showing any error message will hide the Mods UI. * @param message - The error message. * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category. */ show(message: string, category?: string): void; /** * Clear the error message. If no other error messages are currently visible the Mods UI will be shown. * @param category - Optional error categorization. */ hide(category?: string): void; } /** * From readableArray, an array of Readable of some value type, extract an array of this value type. * @public */ export declare type ExtractValueType<readableArray extends ReadonlyArray<Readable<any>>> = { [readableName in keyof readableArray]: readableArray[readableName] extends Readable<infer readableNameType> ? readableNameType : never; }; /** * Represents information about a font that is used in the Mod Visualization. * @public */ export declare interface FontInfo { /** * Gets the value to use for the `font-family` CSS property. */ fontFamily: string; /** * Gets the font size in pixels. */ fontSize: number; /** * Gets the value to use for the `font-style` CSS property. */ fontStyle: string; /** * Gets the value to use for the `font-weight` CSS property. */ fontWeight: string; /** * Gets the value to use for the `color` CSS property. */ color: string; } /** * Represents the general styling information that applies to the Mod Visualization. * @public */ export declare interface GeneralStylingInfo { /** * Gets and object describing the font that shall be used by the Mod Visualization. */ font: FontInfo; /** * Gets the value to use for the `background-color` CSS property of the Mod Visualization. */ backgroundColor: string; /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo; } /** * Initializes the Mod API. The specified `onLoaded` callback is called when the initialization is complete. * @example * ``` * Spotfire.initialize(async (mod) => { * console.log("Mod API loaded."); * }); * ``` * The initialize method will invoke the provided callback with an instance of the mod API, to be used by the mod developer. * * The initialize method needs to be invoked in order for the mod to function. Even if the mod only displays static content, the API must be initialized in order for events and export to work. * @public * @param onLoaded - Callback that is called when the mod API is initialized and ready to be interacted with. */ export declare function initialize(onLoaded: OnLoadCallback): void; /** * Describes the theme that is used in the Spotfire UI. * @public * @version 2.1 */ export declare type KnownTheme = "Light" | "Dark"; /** * Represents the styling information that applies to scale lines in the Mod Visualization. * @public */ export declare interface LineStylingInfo { /** * Gets the stroke to use for scale lines. This value is valid a CSS color or the value `"none"`. */ stroke: string; } /** * Marking information for a {@link DataView}. * @public */ export declare interface MarkingInfo { /** The hex code for the marking. Note that when the mod has a defined color axis, the color should be retrieved via the {@link DataViewRow.color} method. */ colorHexCode: string; /** The name of the marking. */ name: string; } /** * Specifies how a Marking shall be modified. * <pre> * - "Replace" - replaces the current marking. * - "Add" - adds to the current marking. * - "Subtract" - removes the current marking. * - "Toggle" - toggles marking on each item in the set. * - "Intersect" - marks the intersection of the current marking and the specified set. * - "ToggleOrAdd" - will behave like toggle if all or no rows in the set are marked, otherwise it is an add operation. This is the default Spotfire behavior for control marking. * </pre> * @public */ export declare type MarkingOperation = "Replace" | "Add" | "Subtract" | "Toggle" | "Intersect" | "ToggleOrAdd"; /** * Extract from T the keys of all properties with function values. * @public */ export declare type MethodKeys<T> = { [P in keyof T]: T[P] extends Function ? P : never; }[keyof T]; /** * Represents the entire Mod API and exposes methods for interacting with and reading data from * the Mod Visualization and the Spotfire document. * * Reading content from the Mod is made by using either of the methods {@link Reader.subscribe} or {@link Reader.once} on an instance of a {@link Reader}. * @public */ export declare interface Mod { /** * Gets an object that provides access to Spotfire document. */ document: SpotfireDocument; /** * Gets an object representing the content in the Mod Visualization and provides methods to read and/or modified it. */ visualization: ModVisualization; /** * Provides access to the {@link ModProperty} with the specified `name`. */ property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>; /** * Provides read-only access to the current size of the browser window in which the Mod * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI. */ windowSize(): Readable<Size>; /** * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters. * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. * @param readables - The {@link Readable}s that will be available in the reader. */ createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>; /** * Gets an object that allows showing Spotfire controls and other UI component, like context menus, tooltips, etc. */ controls: Controls; /** * Performs a set of synchronous modifications in an explicit transaction to the Spotfire document. * * Use of this method is only needed to make sure that a set of modifications are done as one transaction, thereby resulting in one undo step. * Modifications done outside of a transaction action callback will be grouped together in an implicit transaction. * * @param action - callback with a set of modifications * @param onComplete - optional callback that is called when the transaction is committed or rolled back. When there is an error argument in the callback the transaction was rolled back. * @example * ``` * mod.transaction(() => { * mod.property("X").set("new value for X"); * mod.property("Y").set("new value for Y"); * }, * (error) => { * if (error) { * // Show error message. * } * else { * // Handle success, e.g. re-enable action button. * } * }); * ``` */ transaction(action: () => void, onComplete?: (error?: string) => void): void; /** * Get the Mod's render context. This function should be invoked as soon as possible in the {@link initialize} callback. * * If this method is called in the {@link initialize} callback, Spotfire will wait for the Mod to finish rendering during * an export. The export will be made once the {@link RenderContext.signalRenderComplete} method has been called. * * If this method is not called in the {@link initialize} callback, Spotfire will _not_ wait for the Mod to finish rendering during * an export. Instead, the Mod will be automatically exported after one second. */ getRenderContext(): RenderContext; /** * Get mod metadata - name, id, version, etc. */ metadata: ModMetadata; } /** * Represents that metadata of the Mod Visualization, as defined in the mod-manifest-json. * @public */ export declare interface ModMetadata { /** * Gets the id of the Mod Visualization, as defined in the mod-manifest-json. */ id: string; /** * Gets the name of the Mod Visualization, as defined in the mod-manifest-json. */ name: string; /** * Gets the version of the Mod Visualization, as defined in the mod-manifest-json. */ version: string; /** * Gets the api version used by the Mod Visualization, as declared in the mod-manifest-json. */ apiVersion: string; } /** * Represents a property owned by the Mod Visualization. * The Mod manifest defines the properties owned by the Mod Visualization. * @public */ export declare interface ModProperty<T extends ModPropertyDataType = ModPropertyDataType> extends ModPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T): void; } /** * Represents the data types possible to store in a mod {@link ModProperty}. * @public */ export declare type ModPropertyDataType = string | number | boolean; /** * Represents the values held by a {@link ModProperty}. * @public */ export declare interface ModPropertyValue<T extends ModPropertyDataType = ModPropertyDataType> { /** * Gets the name of this instance. */ name: string; /** * Gets the value held by this instance; */ value<T2 extends T>(): T2 | null; } /** * Represents the content in the Mod Visualization that can be read and/or modified. * * The content is a combination of state stored by the Mod Visualization in the Spotfire document, * its view of the data and relevant UI properties. All values are {@link Readable} objects and are * typically accessed using the {@link Reader} object. * * @public */ export declare interface ModVisualization { /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy; /** * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization * uses as its main table. */ mainTable(): ReadableProxy<DataTable>; /** * Sets the main {@link DataTable} in the Mod visualization. * @param tableName - The name or id of the {@link DataTable} to be used as main table. */ setMainTable(tableName: string): void; /** * Sets the main {@link DataTable} in the Mod visualization. * @param table - The {@link DataTable} object to be used as main table. */ setMainTable(table: DataTable): void; /** * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes * must be declared in the mod-manifest.json. * @param name - The name of the {@link Axis}. */ axis(name: string): ReadableProxy<Axis>; } /** * Represents methods that are not available on a {@link ReadableProxy}. To access these methods the {@link ReadableProxy} must be awaited. * @public */ export declare type OmittedReadableProxyMethods = "value" | "valueList"; /** * Represents a function that consumes the {@link Mod} API. See {@link initialize}. * @public */ export declare type OnLoadCallback = (mod: Mod) => void | Promise<void>; /** * Represents a Page in a Spotfire document. * @public */ export declare interface Page extends PageValues { /** * Sets this instance as the active page. */ setAsActive(): void; } /** * Represents the values held by a {@link Page}. * @public */ export declare interface PageValues { /** * Gets the name of this instance. */ name: string; /** * Gets a value indicating whether this instance is visible. */ visible: boolean; /** * Gets the zero-based index in this instance in the page collection in the Spotfire document. */ index: number; /** * Gets the unique id for this instance. * The id is stable during the page life cycle, thus it can be used to store as a reference to this page in a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 */ id: string; } /** * Represents an object that can be used to create and show a Spotfire popout dialog. * @public */ export declare interface Popout { /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog; /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection; /** * Gets an object with methods that create {@link PopoutComponent}s. */ components: PopoutComponentFactory; } /** * Represents options describing how to render a button. See {@link PopoutComponentFactory.button}. * @public */ export declare interface PopoutButtonOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display in the button. */ text: string; } /** * Represents options describing how to render a checkbox. See {@link PopoutComponentFactory.checkbox}. * @public */ export declare interface PopoutCheckboxOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display next to the checkbox. */ text: string; /** * Specifies the tooltip to display. If undefined, no tooltip is shown. */ tooltip?: string; /** * Specifies whether the checkbox is checked. */ checked: boolean; /** * Specifies whether the checkbox is enabled. */ enabled: boolean; } /** * Represents a component of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutComponent { /** * Gets the type of the control. */ type: string; } /** * Represents the data of an event that occurs when a {@link PopoutComponent} has been changed by the user. * @public */ export declare interface PopoutComponentEvent { /** * Gets the name that identifies the component that has been changed. */ name: string; /** * Gets the value of the component that has been changed. */ value?: any; } /** * Represents an object with methods that create {@link PopoutComponent}s. * @public */ export declare interface PopoutComponentFactory { /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent; /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent; /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent; } /** * Represents a pop out dialog that is shown by Spotfire. See {@link Controls.popout}. * @public */ export declare interface PopoutDialog { /** * Closes the pop out dialog. */ close(): void; } /** * Represents options that specifies where and how a pop out dialog shall be shown. * @public */ export declare interface PopoutOptions { /** * Specifies the horizontal pixel coordinate of the anchor point of the pop out dialog. * * The coordinate is specified relative to an origin in the top left corner of the Mod viewport. */ x: number; /** * Specifies the vertical pixel coordinate of the anchor point of the pop out dialog. * * The coordinate is specified relative to an origin in the top left corner of the Mod viewport. */ y: number; /** * Specifies how to position of the popout in relation to the anchor point specified by `x` and `y`. * * The alignment value specifies which edge of the pop out that shall be closest to the anchor point. For example, * to show the pop out below the anchor point, specify `Top`. */ alignment?: "Left" | "Right" | "Top" | "Bottom"; /** * Specifies whether to automatically close the popout when one of the components in it is clicked. */ autoClose: boolean; /** * Specifies the callback to invoke when a component in the pop out dialog is changed. */ onChange(event: PopoutComponentEvent): void; /** * Specifies the callback to invoke when the pop out dialog has been closed. * This callback is optional and can be left unassigned. */ onClosed?(): void; } /** * Represents options describing how to render a radio button. See {@link PopoutComponentFactory.radioButton}. * @public */ export declare interface PopoutRadioButtonOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display next to the radio button. */ text: string; /** * Specifies the tooltip to display. If undefined, no tooltip is shown. */ tooltip?: string; /** * Specifies whether the radio button is checked. */ checked: boolean; /** * Specifies whether the radio button is enabled. * @version 1.1 */ enabled?: boolean; /** * Specifies the value represented by the radio button. */ value: any; } /** * Represents a section of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutSection { /** * Specifies the heading of the section */ heading?: string; /** * Specifies the components in the section */ children: PopoutComponent[]; } /** * Represents a section of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutSectionOptions { /** * Specifies the heading of the section */ heading?: string; /** * Specifies the components in the section */ children: PopoutComponent[]; } /** * Represents an object with methods to show and hide the Spotfire progress indicator. * @public */ export declare interface Progress { /** * Shows the progress indicator. */ show(): void; /** * Hides the progress indicator. */ hide(): void; } /** * Represents the styling information that applies to a range, for instance in a zoom slider, in the Mod Visualization. * @public * @version 2.1 */ export declare interface RangeStylingInfo { /** * Gets the value to use for the `background-color` CSS property. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; } /** * Represents a value in the Mod API that can be accessed and/or modified. These values can * be used when creating an instance of a {@link Reader} via the {@link Mod.createReader} method. * @public */ export declare interface Readable<T = any> extends Promise<T> { /** * Used internally by the Mod api. */ readableID: string; /** * Used internally by the Mod api. */ __futureValue?: T; } /** * Represents an object that provides access to a node of the specified type. * It can be used as a {@link Readable} but also acts as a proxy to the node by exposing all its methods. * Nodes that represent model state in the Spotfire document can thus be modified without first waiting * and materializing them in the browser. * * A full node will be created by using a {@link Reader}. * @public */ export declare type ReadableProxy<Node> = Readable<Node> & Omit<Pick<Node, MethodKeys<Node>>, OmittedReadableProxyMethods>; /** * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. Choose one of the appropriate methods; * {@link Reader.once} or {@link Reader.subscribe} that suits the needs of the Mod. * An instance of the reader is created by calling the {@link Mod.createReader} method. * @public */ export declare interface Reader<T extends ReadonlyArray<any>> { /** * Subscribe to changes in the content for the specified readables when the reader was created. * @example * Subscribe to changes in the {@link DataView}. * * ``` * let reader = mod.createReader(mod.visualization.data()); * reader.subscribe((dataView) => { * console.log(await dataView.rowCount()); * }); * ``` * * @param callback - The callback function that is called every time when there is at least one new value to read. * The callback function will not be called until the previous callback function has returned. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ subscribe(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription; /** * Read the content once for the readables specified when the reader was created. * Any current subscription for this reader will be cancelled. * @example * Read content of a mod property once. * * ``` * let reader = mod.createReader(mod.property("CreatedBy")); * reader.once((createdBy) => { * console.log(await createdBy.value()); * }); * ``` * * @param callback - The callback function that is called once when there is at least one new value to read. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ once(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription; /** * Checks if any of the readables have a new value available. If this function returns true, * the callback in the current subscription, or a new call to {@link Reader.once} is guaranteed * to be invoked. * The intended use of this method is to cancel rendering of the Mod if there are new values to any of the * readables specified when the reader was created. */ hasExpired(): Promise<boolean>; /** * Check whether one or more passed arguments are new since the last time the subscribe loop was called. * * @example * Check if the data view has changed in the subscribe loop. * * ``` * let reader = mod.createReader(mod.visualization.data(), mod.windowSize()); * reader.subscribe((dataView, size) => { * console.log(reader.hasValueChanged(dataView)); * }); * ``` * * @param value - Value from `subscribe` or `once` arguments. * @param values - Additional values from `subscribe` or `once` arguments. * @returns true if any of the values are new, otherwise false. * @version 1.3 */ hasValueChanged(value: UnionFromTupleTypes<T>, ...values: UnionFromTupleTypes<T>[]): boolean; } /** * Represents a {@link Reader} subscription. * @version 1.1 * @public */ export declare interface ReaderSubscription { /** * Immediately cancel the current subscription. * Neither the callback or the error callback will be invoked afterwards. */ cancel(): void; } /** * Represents contextual information needed when rendering a Mod, either in the UI or as part of an export. * @public */ export declare interface RenderContext { /** * Gets a value indicating whether the Mod is interactive. * * When this value is false the Mod is not interactive. This occurs during export, for instance to an image or to PDF. * This property can be used to hide selected controls and to avoid animations when rendering in an export context. */ interactive: boolean; /** * Gets the image pixel ratio that shall be used when rendering rasterized images and/or using a canvas element. */ imagePixelRatio: number; /** * Gets a value indicating whether the Spotfire UI is in editing mode. * * When this value is true the Spotfire UI displays authoring UI elements, such as axis selectors. * This property can be used to hide controls not meant for consumers of the analysis. * @version 1.2 */ isEditing: boolean; /** * Gets information about the currently used theme. */ styling: StylingInfo; /** * Signals that the mod is ready to be exported. * * If this method is not called, Spotfire will perform export (and preview generation etc.) of the Mod without knowing * if it has finished rendering. * * The default maximum allowed time for a Mod to finish rendering is 20 seconds. */ signalRenderComplete(): void; } /** * Represents the styling information that applies to scales in the Mod Visualization. * @public */ export declare interface ScaleStylingInfo { /** * Gets and object describing the font that shall be used in the scales of the Mod Visualization. */ font: FontInfo; /** * Gets and object describing the styling information for scale lines in the Mod Visualization. */ line: LineStylingInfo; /** * Gets and object describing the styling information for scale ticks in the Mod Visualization. */ tick: TickStylingInfo; } /** * Represents the size of an area in the UI, for example the size of the browser window in which the Mod * is rendered. See {@link Mod.windowSize}. * @public */ export declare interface Size { /** * Gets the width. */ width: number; /** * Gets the height. */ height: number; } /** * Represents the Spotfire document and provides access to read and modify parts of it. * @public */ export declare interface SpotfireDocument { /** * Provides access to the {@link DataTable}s in the Spotfire document. */ tables(): Readable<DataTable[]>; /** * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document. */ table(name: string): ReadableProxy<DataTable>; /** * Provides access to the `Document Properties` in the Spotfire Document. */ properties(): Readable<AnalysisProperty[]>; /** * Provides access to the `Document Property` with the specified `name` in the Spotfire Document. */ property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>; /** * Provides access to the {@link Page}s in the Spotfire document. */ pages(): Readable<Page[]>; /** * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible. */ activePage(): ReadableProxy<Page>; /** * Sets the specified {@link Page} as the active page. * @param name - The name/title or id of the page to set as active. */ setActivePage(name: string): void; /** * Sets the specified index as the active page index. * @param index - The index of the page to set as active. */ setActivePage(index: number): void; /** * Sets the specified {@link Page} as the active page. * @param page - The {@link Page} object to set as active. */ setActivePage(page: Page): void; } /** * Represents a group of values used in different states of an associated DOM element. * @version 2.1 * @public */ export declare interface StateDependentValue<T> { /** * Gets the value to use in the default state. That is, when no pseudo-class is active. * @version 2.1 */ default: T; /** * Gets the value to use in the `hover` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ hover?: T; /** * Gets the value to use in the `active` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ active?: T; /** * Gets the value to use in the `disabled` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ disabled?: T; } /** * Represents the styling (theme) that affects the look and feel of a Mod Visualization. * @public */ export declare interface StylingInfo { /** * Gets an object describing the general aspects of the styling, including the font and background color * to use in the Mod Visualization. */ general: GeneralStylingInfo; /** * Gets an object describing the styling of the scales in the Mod Visualization. */ scales: ScaleStylingInfo; /** * Gets an object describing the styling of the trellis panel headers in the Mod Visualization. * @version 2.1 */ trellisPanelHeaders: TrellisPanelHeaderStylingInfo; /** * Gets an object describing the styling of the zoom sliders in the Mod Visualization. * @version 2.1 */ zoomSliders: ZoomSliderStylingInfo; /** * Gets an object describing the styling of controls in the Mod Visualization. * @version 2.1 */ controls: ControlStylingInfo; } /** * Represents the styling information that applies to a thumb, for instance in a zoom slider, in the Mod Visualization. * @public * @version 2.1 */ export declare interface ThumbStylingInfo { /** * Gets the value to use for the `background-image` CSS property. * @version 2.1 */ backgroundImage: StateDependentValue<string>; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; } /** * Represents the styling information that applies to scale ticks in the Mod Visualization. * @public */ export declare interface TickStylingInfo { /** * Gets the stroke to use for scale ticks. This value is valid a CSS color or the value `"none"`. */ stroke: string; } /** * Represents a Time property. The time has no notion of time zone. * @public */ export declare interface Time { /** The total number of milliseconds since midnight. */ totalMilliseconds: number; /** The millisecond part of the instance. */ milliseconds: number; /** The total number of seconds since midnight. */ totalSeconds: number; /** The second part of the instance. */ seconds: number; /** The total number of minutes since midnight. */ totalMinutes: number; /** The minute part of the instance. */ minutes: number; /** The total number of hours since midnight. */ hours: number; } /** * Represents a TimeSpan property. A time span is used to measure the time between two points in time. * @public */ export declare interface TimeSpan { /** The total number of milliseconds of the instance. */ totalMilliseconds: number; /** The millisecond part of the instance. */ milliseconds: number; /** The total number of seconds of the instance. */ totalSeconds: number; /** The second part of the instance. */ seconds: number; /** The total number of minutes of the instance. */ totalMinutes: number; /** The minute part of the instance. */ minutes: number; /** The total number of hours of the instance. */ totalHours: number; /** The hour part of the instance. */ hours: number; /** The day part of the instance. */ days: number; } /** * Represents an object with methods to show and hide a Spotfire tooltip. * @public */ export declare interface Tooltip { /** * Shows a tooltip with the specified `content` text. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * @param content - The text to show in the tooltip. */ show(content: string): void; /** * Shows a tooltip for the specified `row` as it has been configured in the properties panel. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * * @note For this feature to work, the dataViewDefinition.tooltip.enabled in the mod-manifest.json needs to be set to true. * * @param row - The row to show text for in the tooltip. * @version 1.3 */ show(row: DataViewRow): void; /** * Hides the tooltip that is currently being showed, if any. */ hide(): void; } /** * Represents the styling information that applies to trellis panel headers in the Mod Visualization. * @public * @version 2.1 */ export declare interface TrellisPanelHeaderStylingInfo { /** * Gets the color to use for the `background-color` CSS property. This value is valid a CSS color or the value `"none"`. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; /** * Gets and object describing the font that shall be used in the trellis headers of the Mod Visualization. * @version 2.1 */ font: FontInfo; } /** * Extract all possible types in a Tuple type. * @public */ export declare type UnionFromTupleTypes<T extends readonly any[], U = never> = T[number] | U; /** * Represents the styling information that applies to zoom sliders in the Mod Visualization. * @public * @version 2.1 */ export declare interface ZoomSliderStylingInfo { /** * Gets the styling information to use for the inner range of a zoom slider in the Mod Visualization. * The inner range is the area between the thumbs of the zoom slider. * @version 2.1 */ innerRange: RangeStylingInfo; /** * Gets the styling information to use for the outer range of a zoom slider in the Mod Visualization. * The outer range is the area between the ends of the zoom slider, visible when the thumbs have been moved inwards. * @version 2.1 */ outerRange: RangeStylingInfo; /** * Gets the styling information to use for the thumbs of a zoom slider in the Mod Visualization. * @version 2.1 */ thumb: ThumbStylingInfo; } export { }

    More info can be found in theAPI documentation


    Show declarationHide declaration

    /**
     * Initializes the Mod API. The specified `onLoaded` callback is called when the initialization is complete.
     * @example
     * ```
     * Spotfire.initialize(async (mod) => {
     *  console.log("Mod API loaded.");
     * });
     * ```
     * The initialize method will invoke the provided callback with an instance of the mod API, to be used by the mod developer.
     *
     * The initialize method needs to be invoked in order for the mod to function. Even if the mod only displays static content, the API must be initialized in order for events and export to work.
     * @public
     * @param onLoaded - Callback that is called when the mod API is initialized and ready to be interacted with.
     */
    export declare function initialize(onLoaded: OnLoadCallback): void;

    AbortPredicate

    Predicate to determine if a current read operation for DataView.allRows should be aborted when there is new, non-streaming, data available. If this predicate returns true the DataView.allRows promise will be rejected and no rows will be returned.

    Referenced by

    Used as a function parameter in a method called allRows in DataView
    /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>;
    Used as a function parameter in a method called root in DataViewHierarchy
    /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>;

    Call site

    • Mod > ModVisualization > DataView > AbortPredicate
    • Mod > ModVisualization > DataView > DataViewHierarchy > AbortPredicate

    More info can be found in theAPI documentation


    Show declarationHide declaration

    /**
     * Predicate to determine if a current read operation for {@link DataView.allRows} should be aborted when there is new, non-streaming, data available. If this predicate returns true the {@link DataView.allRows} promise will be rejected and no rows will be returned.
     * @public
     */
    export declare type AbortPredicate = (currentRowCount: number) => boolean;

    AnalysisProperty

    Represents a property owned by the Spotfire document. These can be either document properties, data table properties or data column properties.

    References

    Extends AnalysisPropertyValue
    /** * Represents a property owned by the Spotfire document. * These can be either document properties, data table properties or data column properties. * @public */ export declare interface AnalysisProperty<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> extends AnalysisPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T | T[] | null): void; }

    Referenced by

    Returned from a method called properties in SpotfireDocument
    /** * Provides access to the `Document Properties` in the Spotfire Document. */ properties(): Readable<AnalysisProperty[]>;
    Returned from a method called property in SpotfireDocument
    /** * Provides access to the `Document Property` with the specified `name` in the Spotfire Document. */ property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>;

    Call site

    • Mod > SpotfireDocument > AnalysisProperty

    More info can be found in theAPI documentation


    Show declarationHide declaration

    /**
     * Represents a property owned by the Spotfire document.
     * These can be either document properties, data table properties or data column properties.
     * @public
     */
    export declare interface AnalysisProperty<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> extends AnalysisPropertyValue<T> {
        /**
         * Set the value of this instance.
         * @param value - The value to set.
         */
        set(value: T | T[] | null): void;
    }

    AnalysisPropertyDataType

    Represents the data types possible to store in a document, table or column AnalysisProperty.

    References

    TimeSpan is used as part of an intersection
    string | number | boolean | Date | TimeSpan | Time
    Time is used as part of an intersection
    string | number | boolean | Date | TimeSpan | Time

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the data types possible to store in a document, table or column {@link AnalysisProperty}.
       * @public
       */
      export declare type AnalysisPropertyDataType = string | number | boolean | Date | TimeSpan | Time;

      AnalysisPropertyValue

      Represents the values held by a AnalysisProperty.

      Referenced by

      Extended by AnalysisProperty
      /** * Represents a property owned by the Spotfire document. * These can be either document properties, data table properties or data column properties. * @public */ export declare interface AnalysisProperty<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> extends AnalysisPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T | T[] | null): void; }
      Returned from a method called properties in Column
      /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
      Returned from a method called property in Column
      /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;
      Returned from a method called properties in DataTable
      /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
      Returned from a method called property in DataTable
      /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;

      Call site

      • Mod > SpotfireDocument > AnalysisProperty > AnalysisPropertyValue
      • Mod > ModVisualization > DataTable > Column > AnalysisPropertyValue
      • Mod > SpotfireDocument > DataTable > Column > AnalysisPropertyValue
      • Mod > ModVisualization > DataTable > AnalysisPropertyValue
      • Mod > SpotfireDocument > DataTable > AnalysisPropertyValue

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the values held by a {@link AnalysisProperty}.
       * @public
       */
      export declare interface AnalysisPropertyValue<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> {
          /**
           * Gets the name of this instance.
           */
          name: string;
          /**
           * Gets the value held by this instance. Will throw if the value is a list, i.e. {@link AnalysisPropertyValue.isList} returns true;
           */
          value<T2 extends T>(): T2 | null;
          /**
           * Gets the value held by this instance. Will throw if the value is not a list, i.e. {@link AnalysisPropertyValue.isList} returns false;
           */
          valueList<T2 extends T>(): T2[];
          /**
           * Get the Spotfire internal data type of the property.
           */
          dataType: DataType;
          /**
           * Gets a value indicating whether the property is a list.
           */
          isList: boolean;
      }

      Axis

      Represents an axis of the Mod Visualization.

      References

      Extends AxisValues
      /** * Represents an axis of the Mod Visualization. * @public */ export declare interface Axis extends AxisValues { /** * Sets the full axis expression to the specified `value`. */ setExpression(value: string): void; }

      Referenced by

      Returned from a method called axis in ModVisualization
      /** * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes * must be declared in the mod-manifest.json. * @param name - The name of the {@link Axis}. */ axis(name: string): ReadableProxy<Axis>;

      Call site

      • Mod > ModVisualization > Axis

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents an axis of the Mod Visualization.
       * @public
       */
      export declare interface Axis extends AxisValues {
          /**
           * Sets the full axis expression to the specified `value`.
           */
          setExpression(value: string): void;
      }

      AxisPart

      Represents one element of a multi-part axis expression.

      Referenced by

      Stored as a property called parts in a AxisValues
      /** * Gets the {@link AxisPart}s that this axis has. The parts are derived from the current {@link AxisValues.expression}. */ parts: AxisPart[];

      Call site

      • Mod > ModVisualization > Axis > AxisValues > AxisPart

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents one element of a multi-part axis expression.
       * @public
       */
      export declare interface AxisPart {
          /**
           * Gets the expression of this part.
           */
          expression: string;
          /**
           * Gets the display name of this part.
           */
          displayName: string;
      }

      AxisValues

      Represents the values held by an Axis.

      References

      Returns a AxisPart via a property called parts
      /** * Gets the {@link AxisPart}s that this axis has. The parts are derived from the current {@link AxisValues.expression}. */ parts: AxisPart[];

      Referenced by

      Extended by Axis
      /** * Represents an axis of the Mod Visualization. * @public */ export declare interface Axis extends AxisValues { /** * Sets the full axis expression to the specified `value`. */ setExpression(value: string): void; }

      Call site

      • Mod > ModVisualization > Axis > AxisValues

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the values held by an {@link Axis}.
       * @public
       */
      export declare interface AxisValues {
          /**
           * Gets the name of this instance.
           */
          name: string;
          /**
           * Gets the {@link AxisPart}s that this axis has. The parts are derived from the current  {@link AxisValues.expression}.
           */
          parts: AxisPart[];
          /**
           * Gets the full expression of this instance, including multi-part delimiters and
           * surrounding "\<\>" brackets if the axis is in categorical mode.
           */
          expression: string;
          /**
           * Gets a value indicating whether the axis is categorical or continuous.
           */
          isCategorical: boolean;
      }

      Column

      Represents a data column in a Spotfire data table.

      References

      Extends ColumnValues
      /** * Represents a data column in a Spotfire data table. * @public */ export declare interface Column extends ColumnValues { /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; }
      Returns a AnalysisPropertyValue via a method called properties
      /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
      Returns a AnalysisPropertyValue via a method called property
      /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;

      Referenced by

      Returned from a method called columns in DataTable
      /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>;
      Returned from a method called column in DataTable
      /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>;

      Call site

      • Mod > ModVisualization > DataTable > Column
      • Mod > SpotfireDocument > DataTable > Column

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents a data column in a Spotfire data table.
       * @public
       */
      export declare interface Column extends ColumnValues {
          /**
           * Provides access to the properties of this instance. See {@link AnalysisProperty}.
           */
          properties(): Readable<AnalysisPropertyValue[]>;
          /**
           * Provides access to the {@link AnalysisProperty} with the specified `name`.
           */
          property(name: string): Readable<AnalysisPropertyValue>;
      }

      ColumnValues

      Represents the values held by a Column.

      Referenced by

      Extended by Column
      /** * Represents a data column in a Spotfire data table. * @public */ export declare interface Column extends ColumnValues { /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; }

      Call site

      • Mod > ModVisualization > DataTable > Column > ColumnValues
      • Mod > SpotfireDocument > DataTable > Column > ColumnValues

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the values held by a {@link Column}.
       * @public
       */
      export declare interface ColumnValues {
          /**
           * Gets the name of this instance.
           */
          name: string;
          /**
           * Gets the data type of this instance.
           */
          dataType: DataType;
      }

      ContextMenu

      Represents an object with methods to show a context menu.

      References

      ContextMenuItem is used as a parameter in a method called show
      /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>;
      Returns a ContextMenuItem via a method called show
      /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>;

      Referenced by

      Stored as a property called contextMenu in a Controls
      /** * Gets an object with methods to show a context menu. */ contextMenu: ContextMenu;

      Call site

      • Mod > Controls > ContextMenu

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents an object with methods to show a context menu.
       * @public
       */
      export declare interface ContextMenu {
          /**
           * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the
           * items or outside the context menu.
           * @param x - The horizontal pixel coordinate where to show the context menu.
           * @param y - The vertical pixel coordinate where to show the context menu.
           * @param items - Defines the content of the context menu.
           * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user,
           * or `undefined` if the user clicked outside the context menu.
           */
          show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>;
      }

      ContextMenuItem

      Represents an item in a context menu shown by calling ContextMenu.show.

      Referenced by

      Used as a function parameter in a method called show in ContextMenu
      /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>;
      Returned from a method called show in ContextMenu
      /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>;

      Call site

      • Mod > Controls > ContextMenu > ContextMenuItem

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents an item in a context menu shown by calling {@link ContextMenu.show}.
       * @public
       */
      export declare interface ContextMenuItem {
          /**
           * Specifies the text to show in this item.
           */
          text: string;
          /**
           * Specifies whether this item is enabled.
           */
          enabled: boolean;
          /**
           * Specifies the tooltip to show for this item. If not defined, no tooltip will be shown when hovering the this item.
           */
          tooltip?: string;
          /**
           * Specifies a value indicating whether this item is checked. If not defined, this item will not be rendered in a checked state.
           */
          checked?: boolean;
      }

      ControlStylingInfo

      Represents the styling information that applies to a control of some kind in the Mod Visualization. For example, the controls for search, layers, navigation, etc., in a Spotfire Map Chart follows this styling.

      References

      Returns a StateDependentValue via a property called color
      /** * Gets the values to use for the color CSS properties in different states. * @version 2.1 */ color: StateDependentValue<string>;

      Referenced by

      Stored as a property called controls in a StylingInfo
      /** * Gets an object describing the styling of controls in the Mod Visualization. * @version 2.1 */ controls: ControlStylingInfo;

      Call site

      • Mod > RenderContext > StylingInfo > ControlStylingInfo

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the styling information that applies to a control of some kind in the Mod Visualization.
       * For example, the controls for search, layers, navigation, etc., in a Spotfire Map Chart follows this styling.
       * @public
       * @version 2.1
       */
      export declare interface ControlStylingInfo {
          /**
           * Gets the value to use for the `background-color` CSS property.
           * @version 2.1
           */
          backgroundColor: string;
          /**
           * Gets the values to use for the color CSS properties in different states.
           * @version 2.1
           */
          color: StateDependentValue<string>;
      }

      Controls

      Provides access points to launch Spotfire controls and UI component relevant for a Mod Visualization.

      References

      Returns a ContextMenu via a property called contextMenu
      /** * Gets an object with methods to show a context menu. */ contextMenu: ContextMenu;
      Returns a Tooltip via a property called tooltip
      /** * Gets an object with methods to show and hide a Spotfire tooltip. */ tooltip: Tooltip;
      Returns a Progress via a property called progress
      /** * Gets an object with methods to show and hide the Spotfire progress indicator. */ progress: Progress;
      Returns a Popout via a property called popout
      /** * Gets an object that can be used to create and show a Spotfire popout dialog. */ popout: Popout;
      Returns a ErrorOverlay via a property called errorOverlay
      /** * Gets an object that can be used to show an error overlay native Spotfire style. */ errorOverlay: ErrorOverlay;

      Referenced by

      Stored as a property called controls in a Mod
      /** * Gets an object that allows showing Spotfire controls and other UI component, like context menus, tooltips, etc. */ controls: Controls;

      Call site

      • Mod > Controls

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Provides access points to launch Spotfire controls and UI component relevant for a Mod Visualization.
       * @public
       */
      export declare interface Controls {
          /**
           * Gets an object with methods to show a context menu.
           */
          contextMenu: ContextMenu;
          /**
           * Gets an object with methods to show and hide a Spotfire tooltip.
           */
          tooltip: Tooltip;
          /**
           * Gets an object with methods to show and hide the Spotfire progress indicator.
           */
          progress: Progress;
          /**
           * Gets an object that can be used to create and show a Spotfire popout dialog.
           */
          popout: Popout;
          /**
           * Gets an object that can be used to show an error overlay native Spotfire style.
           */
          errorOverlay: ErrorOverlay;
      }

      CustomThemeStylingInfo

      Represents the basic settings of a custom theme used in Spotfire.

      References

      Returns a KnownTheme via a property called baseTheme
      /** * Gets a value describing the theme that this custom theme is based on. */ baseTheme: KnownTheme;

      Referenced by

      Stored as a property called activeTheme in a GeneralStylingInfo
      /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo;

      Call site

      • Mod > RenderContext > StylingInfo > GeneralStylingInfo > CustomThemeStylingInfo

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the basic settings of a custom theme used in Spotfire.
       * @public
       * @version 2.1
       */
      export declare interface CustomThemeStylingInfo {
          /**
           * Gets a value describing the theme that this custom theme is based on.
           */
          baseTheme: KnownTheme;
          /**
           * Gets the base color of the theme.
           * @version 2.1
           */
          baseColor: string;
          /**
           * Gets the primary color of the theme.
           * @version 2.1
           */
          primaryColor: string;
      }

      DataTable

      Represents a data table in the Spotfire document.

      References

      Extends DataTableValues
      /** * Represents a data table in the Spotfire document. * @public */ export declare interface DataTable extends DataTableValues { /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>; /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>; /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; }
      Returns a Column via a method called columns
      /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>;
      Returns a Column via a method called column
      /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>;
      Returns a AnalysisPropertyValue via a method called properties
      /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
      Returns a AnalysisPropertyValue via a method called property
      /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;

      Referenced by

      Returned from a method called mainTable in ModVisualization
      /** * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization * uses as its main table. */ mainTable(): ReadableProxy<DataTable>;
      Used as a function parameter in a method called setMainTable in ModVisualization
      /** * Sets the main {@link DataTable} in the Mod visualization. * @param table - The {@link DataTable} object to be used as main table. */ setMainTable(table: DataTable): void;
      Returned from a method called tables in SpotfireDocument
      /** * Provides access to the {@link DataTable}s in the Spotfire document. */ tables(): Readable<DataTable[]>;
      Returned from a method called table in SpotfireDocument
      /** * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document. */ table(name: string): ReadableProxy<DataTable>;

      Call site

      • Mod > ModVisualization > DataTable
      • Mod > SpotfireDocument > DataTable

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents a data table in the Spotfire document.
       * @public
       */
      export declare interface DataTable extends DataTableValues {
          /**
           * Provides access to the columns of this instance. See {@link Column}.
           */
          columns(): Readable<Column[]>;
          /**
           * Provides access to the {@link Column} with the specified `name`.
           */
          column(name: string): ReadableProxy<Column>;
          /**
           * Provides access to the properties of this instance. See {@link AnalysisProperty}.
           */
          properties(): Readable<AnalysisPropertyValue[]>;
          /**
           * Provides access to the {@link AnalysisProperty} with the specified `name`.
           */
          property(name: string): Readable<AnalysisPropertyValue>;
      }

      DataTableValues

      Represents the values held by a DataTable.

      Referenced by

      Extended by DataTable
      /** * Represents a data table in the Spotfire document. * @public */ export declare interface DataTable extends DataTableValues { /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>; /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>; /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; }

      Call site

      • Mod > ModVisualization > DataTable > DataTableValues
      • Mod > SpotfireDocument > DataTable > DataTableValues

      More info can be found in theAPI documentation


      Show declarationHide declaration

      /**
       * Represents the values held by a {@link DataTable}.
       * @public
       */
      export declare interface DataTableValues {
          /**
           * Gets the name of this instance.
           */
          name: string;
          /**
           * Gets the number of columns in this instance.
           */
          columnCount: number;
          /**
           * Gets the unique id for this instance.
           * The id is stable during the data table life cycle, thus it can be used to store as a reference to this data table in a {@link ModProperty} or {@link AnalysisProperty}.
           * @version 1.1
           */
          id: string;
      }

      DataType

      Represents the data type of a value.


        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents the data type of a value.
         * @public
         */
        export declare interface DataType {
            /**
             * Gets the name of this DataType.
             */
            name: "String" | "Integer" | "LongInteger" | "Real" | "SingleReal" | "Currency" | "Boolean" | "Date" | "DateTime" | "Time" | "TimeSpan" | "Binary";
            /**
             * Gets a value indicating whether the data type is numeric or not, that is,
             * Integer, Currency, Real, LongInteger, or SingleReal.
             */
            isNumber(): boolean;
            /**
             * Gets a value indicating whether the data type is represents by Date or not, that is, Date, or DateTime.
             */
            isDate(): boolean;
            /**
             * Gets a value indicating whether the data type is represents by {@link Time} or not.
             */
            isTime(): boolean;
            /**
             * Gets a value indicating whether the data type is represents by {@link TimeSpan} or not.
             */
            isTimeSpan(): boolean;
        }

        DataView

        Represents a view of the data from which the visualization can be rendered. This object contains the result of the query made by Spotfire against the DataTable currently used by the Mod Visualization, using the Filtering, Marking, expressions on the Axes and other relevant settings.

        References

        DataViewRow is used as a parameter in a method called mark
        /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void;
        MarkingOperation is used as a parameter in a method called mark
        /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void;
        Returns a MarkingInfo via a method called marking
        /** * Gets the marking information, or `null` if marking is not enabled. */ marking(): Promise<MarkingInfo | null>;
        Returns a DataViewCategoricalAxis via a method called categoricalAxis
        /** * Gets metadata for a specific categorical axis in the {@link DataView}. * Categorical axes are defined in the manifest file as categorical or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.categorical} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The axis name. */ categoricalAxis(name: string): Promise<DataViewCategoricalAxis | null>;
        Returns a DataViewContinuousAxis via a method called continuousAxis
        /** * Gets metadata for a specific continuous axis in the {@link DataView}. * Continuous axes are defined in the manifest file as continuous or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.continuous} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in categorical mode. * Throws if the axis does not exist or the axes mode is categorical. * @param name - The axis name. */ continuousAxis(name: string): Promise<DataViewContinuousAxis | null>;
        Returns a DataViewAxis via a method called axes
        /** * Gets metadata of all axes currently present in the {@link DataView}. * Axes with empty expression are omitted. */ axes(): Promise<DataViewAxis[]>;
        Returns a DataViewHierarchy via a method called hierarchy
        /** * Gets a hierarchy for a categorical axis. * * If the axis has an empty expression the hierarchy will contain one single root node. * Returns `null` for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The name of the axis to get the hierarchy for. */ hierarchy(name: string): Promise<DataViewHierarchy | null>;
        AbortPredicate is used as a parameter in a method called allRows
        /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>;
        Returns a DataViewRow via a method called allRows
        /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>;

        Referenced by

        Returned from a method called data in ModVisualization
        /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy;

        Call site

        • Mod > ModVisualization > DataView

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a view of the data from which the visualization can be rendered.
         *
         * This object contains the result of the query made by Spotfire against the DataTable
         * currently used by the Mod Visualization, using the Filtering, Marking, expressions
         * on the Axes and other relevant settings.
         * @public
         */
        declare interface DataView_2 {
            /**
             * Mark a set of rows.
             * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}).
             * All mark operations must have the same marking operation.
             * @param rows - The rows to be selected.
             * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`.
             */
            mark(rows: DataViewRow[], operation?: MarkingOperation): void;
            /**
             * Clears the current marking
             */
            clearMarking(): void;
            /**
             * Gets the marking information, or `null` if marking is not enabled.
             */
            marking(): Promise<MarkingInfo | null>;
            /**
             * Gets a value indicating whether the dataView has expired.
             * The dataview has expired when there has been changes to the document,
             * for example marking or filtering.
             * When true, there will be a new dataview available on the next read.
             */
            hasExpired(): Promise<boolean>;
            /**
             * Gets a value indicating whether the data view is the result of a streaming update.
             * @version 2.1
             */
            isStreamingUpdate: boolean;
            /**
             * Gets any errors generated while creating the dataview.
             * Returns empty array if none occurred.
             */
            getErrors(): Promise<string[]>;
            /**
             * Gets metadata for a specific categorical axis in the {@link DataView}.
             * Categorical axes are defined in the manifest file as categorical or dual.
             * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.categorical} will throw an error.
             * Returns `null` for axes with empty expressions or for dual mode axes that currently are in continuous mode.
             * Throws if the axis does not exist or the axes mode is continuous.
             * @param name - The axis name.
             */
            categoricalAxis(name: string): Promise<DataViewCategoricalAxis | null>;
            /**
             * Gets metadata for a specific continuous axis in the {@link DataView}.
             * Continuous axes are defined in the manifest file as continuous or dual.
             * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.continuous} will throw an error.
             * Returns `null` for axes with empty expressions or for dual mode axes that currently are in categorical mode.
             * Throws if the axis does not exist or the axes mode is categorical.
             * @param name - The axis name.
             */
            continuousAxis(name: string): Promise<DataViewContinuousAxis | null>;
            /**
             * Gets metadata of all axes currently present in the {@link DataView}.
             * Axes with empty expression are omitted.
             */
            axes(): Promise<DataViewAxis[]>;
            /**
             * Gets a hierarchy for a categorical axis.
             *
             * If the axis has an empty expression the hierarchy will contain one single root node.
             * Returns `null` for dual mode axes that currently are in continuous mode.
             * Throws if the axis does not exist or the axes mode is continuous.
             * @param name - The name of the axis to get the hierarchy for.
             */
            hierarchy(name: string): Promise<DataViewHierarchy | null>;
            /**
             * Gets the total number of rows of the {@link DataView} without actually getting all the rows. Use this function to determine whether or not the mod will be able to handle the amount of data rows.
             * When there are errors in the mod configuration there will be no rows available and this method will return undefined.
             */
            rowCount(): Promise<number | undefined>;
            /**
             * Gets all rows from the data view as one asynchronous operation.
             * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows.
             * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected.
             * The default behavior is that reading will be aborted when new non-streaming update is available.
             * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[].
             */
            allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>;
        }

        DataViewAxis

        Contains metadata computed for an Axis.

        Referenced by

        Returned from a method called axes in DataView
        /** * Gets metadata of all axes currently present in the {@link DataView}. * Axes with empty expression are omitted. */ axes(): Promise<DataViewAxis[]>;
        Extended by DataViewCategoricalAxis
        /** * Represents metadata computed for a categorical {@link Axis}. * @public */ export declare interface DataViewCategoricalAxis extends DataViewAxis { /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy; }
        Extended by DataViewContinuousAxis
        /** * Represents metadata computed for continuous {@link Axis}. * @public */ export declare interface DataViewContinuousAxis extends DataViewAxis { /** * Gets the data type of the values computed by this axis. */ dataType: DataType; }

        Call site

        • Mod > ModVisualization > DataView > DataViewAxis
        • Mod > ModVisualization > DataView > DataViewCategoricalAxis > DataViewAxis
        • Mod > ModVisualization > DataView > DataViewContinuousAxis > DataViewAxis

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Contains metadata computed for an {@link Axis}.
         * @public
         */
        export declare interface DataViewAxis {
            /**
             * Gets the name of this axis.
             */
            name: string;
            /**
             * Gets a value indicating whether this axis is an instance of {@link DataViewContinuousAxis} or {@link DataViewCategoricalAxis} .
             */
            isCategorical: boolean;
        }

        DataViewCategoricalAxis

        Represents metadata computed for a categorical Axis.

        References

        Extends DataViewAxis
        /** * Represents metadata computed for a categorical {@link Axis}. * @public */ export declare interface DataViewCategoricalAxis extends DataViewAxis { /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy; }
        Returns a DataViewHierarchy via a property called hierarchy
        /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy;

        Referenced by

        Returned from a method called categoricalAxis in DataView
        /** * Gets metadata for a specific categorical axis in the {@link DataView}. * Categorical axes are defined in the manifest file as categorical or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.categorical} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The axis name. */ categoricalAxis(name: string): Promise<DataViewCategoricalAxis | null>;

        Call site

        • Mod > ModVisualization > DataView > DataViewCategoricalAxis

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents metadata computed for a categorical {@link Axis}.
         * @public
         */
        export declare interface DataViewCategoricalAxis extends DataViewAxis {
            /**
             * Gets the hierarchy of this axis.
             */
            hierarchy: DataViewHierarchy;
        }

        DataViewCategoricalValue

        Represents a value of a categorical axis for one row in a data view.

        References

        Returns a DataViewCategoricalValuePathElement via a method called value
        /** * Gets an array representing the full path of the value in the hierarchy defined by the axis expression. * The first element is the top level of the hierarchy and the last element is the leaf level. */ value(): DataViewCategoricalValuePathElement[];

        Referenced by

        Returned from a method called categorical in DataViewRow
        /** * Gets a {@link DataViewCategoricalValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no categorical axis by that name or if the expression is empty. * Use {@link DataView.categoricalAxis} to check the current existence of a categorical value. * @param axisName - The name of the axis to get the value for. */ categorical(axisName: string): DataViewCategoricalValue;

        Call site

        • Mod > ModVisualization > DataView > DataViewRow > DataViewCategoricalValue
        • Mod > Controls > Tooltip > DataViewRow > DataViewCategoricalValue

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a value of a categorical axis for one row in a data view.
         * @public
         */
        export declare interface DataViewCategoricalValue {
            /**
             * Gets an array representing the full path of the value in the hierarchy defined by the axis expression.
             * The first element is the top level of the hierarchy and the last element is the leaf level.
             */
            value(): DataViewCategoricalValuePathElement[];
            /**
             * Gets a formatted string that can be used to display this value.
             * This string is built by concatenating the {@link DataViewCategoricalValuePathElement.formattedValue} for each element found in the {@link DataViewCategoricalValue.value} array.
             * @param separator - The separator used for concatenation. The default separator is " » ".
             */
            formattedValue(separator?: string): string;
            /**
             * Gets the index among the leaf nodes of the associated {@link DataViewHierarchy} of this {@link DataViewCategoricalAxis}.
             * This, for example, can be used to determine the position on a scale where to render the visual element.
             */
            leafIndex: number;
        }

        DataViewCategoricalValuePathElement

        Represents an element in the `path` of a DataViewCategoricalValue.

        Referenced by

        Returned from a method called value in DataViewCategoricalValue
        /** * Gets an array representing the full path of the value in the hierarchy defined by the axis expression. * The first element is the top level of the hierarchy and the last element is the leaf level. */ value(): DataViewCategoricalValuePathElement[];

        Call site

        • Mod > ModVisualization > DataView > DataViewRow > DataViewCategoricalValue > DataViewCategoricalValuePathElement
        • Mod > Controls > Tooltip > DataViewRow > DataViewCategoricalValue > DataViewCategoricalValuePathElement

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents an element in the `path` of a {@link DataViewCategoricalValue}.
         * @public
         */
        export declare interface DataViewCategoricalValuePathElement {
            /**
             * Gets a formatted string that can be used to display this value.
             * The formatting settings in Spotfire are used to create this string.
             */
            formattedValue(): string;
            /**
             * Gets a key that uniquely identifies this element.
             *
             * In many cases this will be the same as {@link DataViewCategoricalValuePathElement.formattedValue} and {@link DataViewCategoricalValuePathElement.value}.
             * However there are cases when those values can contain duplicates. For instance when working with cube data,
             * or when using formatters and display values.
             *
             * They key is suitable to be used for identifying objects when implementing rendering transitions.
             *
             * The key can be `null` when the corresponding {@link DataViewCategoricalValuePathElement.value} is null.
             */
            key: string | null;
            /**
             * Gets the value of this element, or `null` if this element represents a missing or invalid data point.
             *
             * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the {@link DataViewHierarchy} of
             * the associated {@link DataViewCategoricalAxis}.
             */
            value<T extends DataViewValueType>(): T | null;
        }

        DataViewColorInfo

        Color information for a DataViewRow.

        Referenced by

        Returned from a method called color in DataViewRow
        /** * Gets the {@link DataViewColorInfo} for the row, if a color axis is defined in the mod manifest. * The underlying data value can be retrieved by using {@link DataViewRow.categorical}("Color") or {@link DataViewRow.continuous}("Color"), depending on the mode of the color axis. */ color(): DataViewColorInfo;

        Call site

        • Mod > ModVisualization > DataView > DataViewRow > DataViewColorInfo
        • Mod > Controls > Tooltip > DataViewRow > DataViewColorInfo

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Color information for a {@link DataViewRow}.
         * @public
         */
        export declare interface DataViewColorInfo {
            /** The hex code for the color. */
            hexCode: string;
        }

        DataViewContinuousAxis

        Represents metadata computed for continuous Axis.

        References

        Extends DataViewAxis
        /** * Represents metadata computed for continuous {@link Axis}. * @public */ export declare interface DataViewContinuousAxis extends DataViewAxis { /** * Gets the data type of the values computed by this axis. */ dataType: DataType; }

        Referenced by

        Returned from a method called continuousAxis in DataView
        /** * Gets metadata for a specific continuous axis in the {@link DataView}. * Continuous axes are defined in the manifest file as continuous or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.continuous} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in categorical mode. * Throws if the axis does not exist or the axes mode is categorical. * @param name - The axis name. */ continuousAxis(name: string): Promise<DataViewContinuousAxis | null>;

        Call site

        • Mod > ModVisualization > DataView > DataViewContinuousAxis

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents metadata computed for continuous {@link Axis}.
         * @public
         */
        export declare interface DataViewContinuousAxis extends DataViewAxis {
            /**
             * Gets the data type of the values computed by this axis.
             */
            dataType: DataType;
        }

        DataViewContinuousValue

        Represents a value of a continuous axis for one row in a data view.

        Referenced by

        Returned from a method called continuous in DataViewRow
        /** * Gets a {@link DataViewContinuousValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no continuous axis by that name or if the expression is empty. * Use {@link DataView.continuousAxis} to check the current existence of a continuous value. * @param axisName - The name of the axis to get the value for. */ continuous<T extends DataViewValueType>(axisName: string): DataViewContinuousValue<T>;

        Call site

        • Mod > ModVisualization > DataView > DataViewRow > DataViewContinuousValue
        • Mod > Controls > Tooltip > DataViewRow > DataViewContinuousValue

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a value of a continuous axis for one row in a data view.
         * @public
         */
        export declare interface DataViewContinuousValue<T extends DataViewValueType = DataViewValueType> {
            /**
             * Gets the value of this instance. The type depending on the type of the
             * expression on the associated {@link DataViewContinuousAxis}.
             *
             * This method will return `null` when the underlying data value is missing or invalid.
             */
            value<T2 extends DataViewValueType = T>(): T2 | null;
            /**
             * Gets a formatted string that can be used to display this value.
             * The formatting settings in Spotfire are used to create this string.
             */
            formattedValue(): string;
        }

        DataViewHierarchy

        Represents a hierarchy for a DataViewCategoricalAxis.

        References

        Returns a DataViewHierarchyLevel via a property called levels
        /** * Gets the levels of this hierarchy. The root node has no corresponding level. */ levels: DataViewHierarchyLevel[];
        AbortPredicate is used as a parameter in a method called root
        /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>;
        Returns a DataViewHierarchyNode via a method called root
        /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>;

        Referenced by

        Returned from a method called hierarchy in DataView
        /** * Gets a hierarchy for a categorical axis. * * If the axis has an empty expression the hierarchy will contain one single root node. * Returns `null` for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The name of the axis to get the hierarchy for. */ hierarchy(name: string): Promise<DataViewHierarchy | null>;
        Stored as a property called hierarchy in a DataViewCategoricalAxis
        /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy;

        Call site

        • Mod > ModVisualization > DataView > DataViewHierarchy
        • Mod > ModVisualization > DataView > DataViewCategoricalAxis > DataViewHierarchy

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a hierarchy for a {@link DataViewCategoricalAxis}.
         * @public
         */
        export declare interface DataViewHierarchy {
            /**
             * Gets the name of this hierarchy, the same as the associated {@link DataViewCategoricalAxis}.
             */
            name: string;
            /**
             * Gets a value indicating whether the hierarchy is empty, i.e. the axis expression is empty, or not.
             * For convenience, an empty hierarchy will have one single node that may contain all rows in the dataview.
             */
            isEmpty: boolean;
            /**
             * Gets the levels of this hierarchy. The root node has no corresponding level.
             */
            levels: DataViewHierarchyLevel[];
            /**
             * Gets the total number of leaf nodes in the hierarchy.
             */
            leafCount: number;
            /**
             *  Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization.
             * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected.
             * The default behavior is that reading will be aborted when new non-streaming update is available.
             * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}.
             */
            root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>;
        }

        DataViewHierarchyLevel

        Represents the levels of a hierarchy.

        Referenced by

        Stored as a property called levels in a DataViewHierarchy
        /** * Gets the levels of this hierarchy. The root node has no corresponding level. */ levels: DataViewHierarchyLevel[];

        Call site

        • Mod > ModVisualization > DataView > DataViewHierarchy > DataViewHierarchyLevel

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents the levels of a hierarchy.
         * @public
         */
        export declare interface DataViewHierarchyLevel {
            /**
             * The name of the hierarchy level, derived from the expression on the {@link Axis}.
             */
            name: string;
            /**
             * Gets the data type of the values in this level of the hierarchy.
             */
            dataType: DataType;
        }

        DataViewHierarchyNode

        Represents a node in a DataViewHierarchy.

        References

        MarkingOperation is used as a parameter in a method called mark
        /** * Marks all {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. * See {@link DataView.mark} for more details. * @param operation - The marking operation. */ mark(operation?: MarkingOperation): void;
        Returns a DataViewRow via a method called rows
        /** * Computes the {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rows(): DataViewRow[];

        Referenced by

        Returned from a method called root in DataViewHierarchy
        /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>;
        Returned from a method called leafNode in DataViewRow
        /** * Gets the leaf {@link DataViewHierarchyNode} for the specified axis, * or `null` for dual mode axes with continuous axis expression. * This method will throw an error for continuous mode axes * or if there is no axis by that name. * @param axisName - The name of the axis * @version 1.1 */ leafNode(axisName: string): DataViewHierarchyNode | null;

        Call site

        • Mod > ModVisualization > DataView > DataViewHierarchy > DataViewHierarchyNode
        • Mod > ModVisualization > DataView > DataViewRow > DataViewHierarchyNode
        • Mod > Controls > Tooltip > DataViewRow > DataViewHierarchyNode

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a node in a {@link DataViewHierarchy}.
         * @public
         */
        export declare interface DataViewHierarchyNode {
            /**
             * Gets a formatted string that can be used to display this value.
             * The formatting settings in Spotfire are used to create this string.
             */
            formattedValue(): string;
            /**
             * Gets the full path, top down to this node, of the formatted values. The virtual root node is omitted.
             * @param separator - The separator. The default separator is " » ".
             */
            formattedPath(separator?: string): string;
            /**
             * Gets the key for this hierarchy node. The key is guaranteed to be unique for the node among its siblings.
             *
             * In many cases this will be the same as {@link DataViewHierarchyNode.formattedValue} or {@link DataViewHierarchyNode.value}.
             * However there are cases when those values can contain duplicates. For instance when working with cube data,
             * or when using formatters and display values.
             *
             * They key is suitable to be used for identifying objects when implementing rendering transitions.
             *
             * The key can be `null` when the corresponding {@link DataViewHierarchyNode.value} is null.
             */
            key: string | null;
            /**
             * Gets the value of this node, or `null` if this node represents a missing or invalid data point.
             *
             * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the associated {@link DataViewHierarchy}.
             */
            value<T extends DataViewValueType>(): T | null;
            /**
             * Gets the parent of the hierarchy node, or `undefined` for root level nodes.
             */
            parent?: DataViewHierarchyNode;
            /**
             * Gets the children of this node, or `undefined` if this node is a leaf node.
             */
            children?: DataViewHierarchyNode[];
            /**
             * Computes an array of all leaf nodes in the sub tree of the hierarchy spanned from this node.
             */
            leaves(): DataViewHierarchyNode[];
            /**
             * Gets the index of the leaf node among all leaf nodes in the hierarchy. This is undefined for non leaf nodes.
             */
            leafIndex?: number;
            /**
             * Marks all {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node.
             * See {@link DataView.mark} for more details.
             * @param operation - The marking operation.
             */
            mark(operation?: MarkingOperation): void;
            /**
             * Computes the number of {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node.
             */
            rowCount(): number;
            /**
             * Computes the number of leaf nodes in the sub tree of the hierarchy spanned from this node.
             */
            leafCount(): number;
            /**
             * Computes the number of marked {@link DataViewRow}s in the sub tree of the hierarchy spanned from this node.
             */
            markedRowCount(): number;
            /**
             * Gets the level in the hierarchy where this node occurs. The root node of the hierarchy tree has level -1.
             */
            level: number;
            /**
             * Computes the {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node.
             */
            rows(): DataViewRow[];
        }

        DataViewProxy

        Represents an object that provides access to a DataView.

        References

        DataView is used as part of an intersection
        DataViewProxyMethods & Readable<DataView_2>

        Referenced by

        Returned from a method called data in ModVisualization
        /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy;

        Call site

        • Mod > ModVisualization > DataView

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents an object that provides access to a {@link DataView}.
         * @public
         */
        export declare type DataViewProxy = DataViewProxyMethods & Readable<DataView_2>;

        DataViewProxyMethods

        Represents the methods available on a DataViewProxy.

        Referenced by

        Returned from a method called data in ModVisualization
        /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy;

        Call site

        • Mod > ModVisualization > DataView

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents the methods available on a {@link DataViewProxy}.
         * @public
         */
        export declare interface DataViewProxyMethods {
            /**
             * Clears the current marking
             */
            clearMarking(): void;
        }

        DataViewRow

        Represents a row of data in a DataView. Each row can be thought of as a data point that the mod visualization renders.

        References

        Returns a DataViewCategoricalValue via a method called categorical
        /** * Gets a {@link DataViewCategoricalValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no categorical axis by that name or if the expression is empty. * Use {@link DataView.categoricalAxis} to check the current existence of a categorical value. * @param axisName - The name of the axis to get the value for. */ categorical(axisName: string): DataViewCategoricalValue;
        Returns a DataViewContinuousValue via a method called continuous
        /** * Gets a {@link DataViewContinuousValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no continuous axis by that name or if the expression is empty. * Use {@link DataView.continuousAxis} to check the current existence of a continuous value. * @param axisName - The name of the axis to get the value for. */ continuous<T extends DataViewValueType>(axisName: string): DataViewContinuousValue<T>;
        Returns a DataViewHierarchyNode via a method called leafNode
        /** * Gets the leaf {@link DataViewHierarchyNode} for the specified axis, * or `null` for dual mode axes with continuous axis expression. * This method will throw an error for continuous mode axes * or if there is no axis by that name. * @param axisName - The name of the axis * @version 1.1 */ leafNode(axisName: string): DataViewHierarchyNode | null;
        Returns a DataViewColorInfo via a method called color
        /** * Gets the {@link DataViewColorInfo} for the row, if a color axis is defined in the mod manifest. * The underlying data value can be retrieved by using {@link DataViewRow.categorical}("Color") or {@link DataViewRow.continuous}("Color"), depending on the mode of the color axis. */ color(): DataViewColorInfo;
        MarkingOperation is used as a parameter in a method called mark
        /** * Performs the specified marking operation in the current marking. * * **Note** All mark operations within one {@link Mod.transaction} must have the same {@link MarkingOperation}. * * See {@link DataView.mark} for more details. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(operation?: MarkingOperation): void;

        Referenced by

        Used as a function parameter in a method called mark in DataView
        /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void;
        Returned from a method called allRows in DataView
        /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>;
        Returned from a method called rows in DataViewHierarchyNode
        /** * Computes the {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rows(): DataViewRow[];
        Used as a function parameter in a method called show in Tooltip
        /** * Shows a tooltip for the specified `row` as it has been configured in the properties panel. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * * @note For this feature to work, the dataViewDefinition.tooltip.enabled in the mod-manifest.json needs to be set to true. * * @param row - The row to show text for in the tooltip. * @version 1.3 */ show(row: DataViewRow): void;

        Call site

        • Mod > ModVisualization > DataView > DataViewRow
        • Mod > ModVisualization > DataView > DataViewHierarchy > DataViewHierarchyNode > DataViewRow
        • Mod > Controls > Tooltip > DataViewRow > DataViewHierarchyNode > DataViewRow
        • Mod > Controls > Tooltip > DataViewRow

        More info can be found in theAPI documentation


        Show declarationHide declaration

        /**
         * Represents a row of data in a {@link DataView}. Each row can be thought of as a data point that the mod visualization renders.
         * @public
         */
        export declare interface DataViewRow {
            /**
             * Gets a value indicating whether this row is marked.
             */
            isMarked(): boolean;
            /**
             * Gets a {@link DataViewCategoricalValue} representing the value of the axis with the specified `axisName`.
             * This method will throw an error if there is no categorical axis by that name or if the expression is empty.
             * Use {@link DataView.categoricalAxis} to check the current existence of a categorical value.
             * @param axisName - The name of the axis to get the value for.
             */
            categorical(axisName: string): DataViewCategoricalValue;
            /**
             * Gets a {@link DataViewContinuousValue} representing the value of the axis with the specified `axisName`.
             * This method will throw an error if there is no continuous axis by that name or if the expression is empty.
             * Use {@link DataView.continuousAxis} to check the current existence of a continuous value.
             * @param axisName - The name of the axis to get the value for.
             */
            continuous<T extends DataViewValueType>(axisName: string): DataViewContinuousValue<T>;
            /**
             * Gets the leaf {@link DataViewHierarchyNode} for the specified axis,
             * or `null` for dual mode axes with continuous axis expression.
             * This method will throw an error for continuous mode axes
             * or if there is no axis by that name.
             * @param axisName - The name of the axis
             * @version 1.1
             */
            leafNode(axisName: string): DataViewHierarchyNode | null;
            /**
             * Calculates an element id for this row, suitable for identifying rows between data views.
             * When stable identifiers is not used, only rows in immediately following data view are guaranteed to re-use previous id.
             * If a row is filtered out in a new data view, this row is thus not guaranteed to yield the same id when it re-appears.
             *
             * @note A stable element id is only stable in the current session, thus it should not be stored in the document,
             * e.g. as a {@link ModProperty} or {@link AnalysisProperty}.
             * @version 1.1
             *
             * @param useStableId - When true, the id will be a (longer) stable id guaranteed to be the same over time.
             * @param omitAxisNames - Axis names to omit when creating the identifier. Can be used to group multiple elements split by these axes, for example to create animation effects in one data view.
             */
            elementId(useStableId?: boolean, omitAxisNames?: string[]): string;
            /**
             * Gets the {@link DataViewColorInfo} for the row, if a color axis is defined in the mod manifest.
             * The underlying data value can be retrieved by using {@link DataViewRow.categorical}("Color") or {@link DataViewRow.continuous}("Color"), depending on the mode of the color axis.
             */
            color(): DataViewColorInfo;
            /**
             * Performs the specified marking operation in the current marking.
             *
             * **Note** All mark operations within one {@link Mod.transaction} must have the same {@link MarkingOperation}.
             *
             * See {@link DataView.mark} for more details.
             * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`.
             */
            mark(operation?: MarkingOperation): void;
        }

        DataViewValueType

        Represents the type of a DataView value. The actual type that a given value has depends on the type of the expression on the associated axis.

        References

        Time is used as part of an intersection
        number | string | boolean | Date | Time | TimeSpan
        TimeSpan is used as part of an intersection
        number | string | boolean | Date | Time | TimeSpan

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Represents the type of a {@link DataView} value. The actual type that a given value has depends on the
           * type of the expression on the associated axis.
           * @public
           */
          export declare type DataViewValueType = number | string | boolean | Date | Time | TimeSpan;

          EdgeValues

          Represents a group of values used for the top, bottom, left and right edges of a CSS property of an associated DOM element.

          Referenced by

          Stored as a property called borderColors in a RangeStylingInfo
          /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;
          Stored as a property called borderColors in a ThumbStylingInfo
          /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;
          Stored as a property called borderColors in a TrellisPanelHeaderStylingInfo
          /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;

          Call site

          • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo > RangeStylingInfo > EdgeValues
          • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo > ThumbStylingInfo > EdgeValues
          • Mod > RenderContext > StylingInfo > TrellisPanelHeaderStylingInfo > EdgeValues

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Represents a group of values used for the top, bottom, left and right edges of a CSS property of an associated DOM element.
           * @public
           * @version 2.1
           */
          export declare interface EdgeValues<T> {
              /**
               * Gets the value to use for the `-top-` CSS property. For instance `border-top-color`.
               * @version 2.1
               */
              top: T;
              /**
               * Gets the value to use for the `-bottom-` CSS property. For instance `border-bottom-color`.
               * @version 2.1
               */
              bottom: T;
              /**
               * Gets the value to use for the `-left-` CSS property. For instance `border-left-color`.
               * @version 2.1
               */
              left: T;
              /**
               * Gets the value to use for the `-right-` CSS property. For instance `border-right-color`.
               * @version 2.1
               */
              right: T;
          }

          ErrorOverlay

          Provides access to show an error overlay covering the entire Mod shown by Spotfire.

          Referenced by

          Stored as a property called errorOverlay in a Controls
          /** * Gets an object that can be used to show an error overlay native Spotfire style. */ errorOverlay: ErrorOverlay;

          Call site

          • Mod > Controls > ErrorOverlay

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Provides access to show an error overlay covering the entire Mod shown by Spotfire.
           * @public
           */
          export declare interface ErrorOverlay {
              /**
               * Show error message. Showing any error message will hide the Mods UI.
               * @param messages - The error messages. Each message will be shown in its own paragraph.
               * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category.
               */
              show(messages: string[], category?: string): void;
              /**
               * Show error message. Showing any error message will hide the Mods UI.
               * @param message - The error message.
               * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category.
               */
              show(message: string, category?: string): void;
              /**
               * Clear the error message. If no other error messages are currently visible the Mods UI will be shown.
               * @param category - Optional error categorization.
               */
              hide(category?: string): void;
          }

          ExtractValueType

          From readableArray, an array of Readable of some value type, extract an array of this value type.

          References

          Readable is used as part of a mapped type
          { [readableName in keyof readableArray]: readableArray[readableName] extends Readable<infer readableNameType> ? readableNameType : never; }

          Referenced by

          Returned from a method called createReader in Mod
          /** * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters. * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. * @param readables - The {@link Readable}s that will be available in the reader. */ createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>;

          Call site

          • Mod > Reader

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * From readableArray, an array of Readable of some value type, extract an array of this value type.
           * @public
           */
          export declare type ExtractValueType<readableArray extends ReadonlyArray<Readable<any>>> = {
              [readableName in keyof readableArray]: readableArray[readableName] extends Readable<infer readableNameType> ? readableNameType : never;
          };

          FontInfo

          Represents information about a font that is used in the Mod Visualization.

          Referenced by

          Stored as a property called font in a GeneralStylingInfo
          /** * Gets and object describing the font that shall be used by the Mod Visualization. */ font: FontInfo;
          Stored as a property called font in a ScaleStylingInfo
          /** * Gets and object describing the font that shall be used in the scales of the Mod Visualization. */ font: FontInfo;
          Stored as a property called font in a TrellisPanelHeaderStylingInfo
          /** * Gets and object describing the font that shall be used in the trellis headers of the Mod Visualization. * @version 2.1 */ font: FontInfo;

          Call site

          • Mod > RenderContext > StylingInfo > GeneralStylingInfo > FontInfo
          • Mod > RenderContext > StylingInfo > ScaleStylingInfo > FontInfo
          • Mod > RenderContext > StylingInfo > TrellisPanelHeaderStylingInfo > FontInfo

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Represents information about a font that is used in the Mod Visualization.
           * @public
           */
          export declare interface FontInfo {
              /**
               * Gets the value to use for the `font-family` CSS property.
               */
              fontFamily: string;
              /**
               * Gets the font size in pixels.
               */
              fontSize: number;
              /**
               * Gets the value to use for the `font-style` CSS property.
               */
              fontStyle: string;
              /**
               * Gets the value to use for the `font-weight` CSS property.
               */
              fontWeight: string;
              /**
               * Gets the value to use for the `color` CSS property.
               */
              color: string;
          }

          GeneralStylingInfo

          Represents the general styling information that applies to the Mod Visualization.

          References

          Returns a FontInfo via a property called font
          /** * Gets and object describing the font that shall be used by the Mod Visualization. */ font: FontInfo;
          Returns a KnownTheme via a property called activeTheme
          /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo;
          Returns a CustomThemeStylingInfo via a property called activeTheme
          /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo;

          Referenced by

          Stored as a property called general in a StylingInfo
          /** * Gets an object describing the general aspects of the styling, including the font and background color * to use in the Mod Visualization. */ general: GeneralStylingInfo;

          Call site

          • Mod > RenderContext > StylingInfo > GeneralStylingInfo

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Represents the general styling information that applies to the Mod Visualization.
           * @public
           */
          export declare interface GeneralStylingInfo {
              /**
               * Gets and object describing the font that shall be used by the Mod Visualization.
               */
              font: FontInfo;
              /**
               * Gets the value to use for the `background-color` CSS property of the Mod Visualization.
               */
              backgroundColor: string;
              /**
               * Gets a value describing the theme that is used in the Spotfire UI.
               */
              activeTheme: KnownTheme | CustomThemeStylingInfo;
          }

          KnownTheme

          Describes the theme that is used in the Spotfire UI.

          Referenced by

          Stored as a property called baseTheme in a CustomThemeStylingInfo
          /** * Gets a value describing the theme that this custom theme is based on. */ baseTheme: KnownTheme;
          Stored as a property called activeTheme in a GeneralStylingInfo
          /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo;

          Call site

          • Mod > RenderContext > StylingInfo > GeneralStylingInfo > CustomThemeStylingInfo > KnownTheme
          • Mod > RenderContext > StylingInfo > GeneralStylingInfo > KnownTheme

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Describes the theme that is used in the Spotfire UI.
           * @public
           * @version 2.1
           */
          export declare type KnownTheme = "Light" | "Dark";

          LineStylingInfo

          Represents the styling information that applies to scale lines in the Mod Visualization.

          Referenced by

          Stored as a property called line in a ScaleStylingInfo
          /** * Gets and object describing the styling information for scale lines in the Mod Visualization. */ line: LineStylingInfo;

          Call site

          • Mod > RenderContext > StylingInfo > ScaleStylingInfo > LineStylingInfo

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Represents the styling information that applies to scale lines in the Mod Visualization.
           * @public
           */
          export declare interface LineStylingInfo {
              /**
               * Gets the stroke to use for scale lines. This value is valid a CSS color or the value `"none"`.
               */
              stroke: string;
          }

          MarkingInfo

          Marking information for a DataView.

          Referenced by

          Returned from a method called marking in DataView
          /** * Gets the marking information, or `null` if marking is not enabled. */ marking(): Promise<MarkingInfo | null>;

          Call site

          • Mod > ModVisualization > DataView > MarkingInfo

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Marking information for a {@link DataView}.
           * @public
           */
          export declare interface MarkingInfo {
              /** The hex code for the marking. Note that when the mod has a defined color axis, the color should be retrieved via the {@link DataViewRow.color} method. */
              colorHexCode: string;
              /** The name of the marking. */
              name: string;
          }

          MarkingOperation

          Specifies how a Marking shall be modified.

            - "Replace" - replaces the current marking.  - "Add" - adds to the current marking.  - "Subtract" - removes the current marking.  - "Toggle" - toggles marking on each item in the set.  - "Intersect" - marks the intersection of the current marking and the specified set.  - "ToggleOrAdd" - will behave like toggle if all or no rows in the set are marked, otherwise it is an add operation. This is the default Spotfire behavior for control marking.  

          Referenced by

          Used as a function parameter in a method called mark in DataView
          /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void;
          Used as a function parameter in a method called mark in DataViewHierarchyNode
          /** * Marks all {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. * See {@link DataView.mark} for more details. * @param operation - The marking operation. */ mark(operation?: MarkingOperation): void;
          Used as a function parameter in a method called mark in DataViewRow
          /** * Performs the specified marking operation in the current marking. * * **Note** All mark operations within one {@link Mod.transaction} must have the same {@link MarkingOperation}. * * See {@link DataView.mark} for more details. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(operation?: MarkingOperation): void;

          Call site

          • Mod > ModVisualization > DataView > MarkingOperation
          • Mod > ModVisualization > DataView > DataViewHierarchy > DataViewHierarchyNode > MarkingOperation
          • Mod > Controls > Tooltip > DataViewRow > DataViewHierarchyNode > MarkingOperation
          • Mod > ModVisualization > DataView > DataViewRow > MarkingOperation
          • Mod > Controls > Tooltip > DataViewRow > MarkingOperation

          More info can be found in theAPI documentation


          Show declarationHide declaration

          /**
           * Specifies how a Marking shall be modified.
           * <pre>
           * - "Replace" - replaces the current marking.
           * - "Add" - adds to the current marking.
           * - "Subtract" - removes the current marking.
           * - "Toggle" - toggles marking on each item in the set.
           * - "Intersect" - marks the intersection of the current marking and the specified set.
           * - "ToggleOrAdd" - will behave like toggle if all or no rows in the set are marked, otherwise it is an add operation. This is the default Spotfire behavior for control marking.
           * </pre>
           * @public
           */
          export declare type MarkingOperation = "Replace" | "Add" | "Subtract" | "Toggle" | "Intersect" | "ToggleOrAdd";

          MethodKeys

          Extract from T the keys of all properties with function values.


            More info can be found in theAPI documentation


            Show declarationHide declaration

            /**
             * Extract from T the keys of all properties with function values.
             * @public
             */
            export declare type MethodKeys<T> = {
                [P in keyof T]: T[P] extends Function ? P : never;
            }[keyof T];

            Mod

            Represents the entire Mod API and exposes methods for interacting with and reading data from the Mod Visualization and the Spotfire document. Reading content from the Mod is made by using either of the methods Reader.subscribe or Reader.once on an instance of a Reader.

            References

            Returns a SpotfireDocument via a property called document
            /** * Gets an object that provides access to Spotfire document. */ document: SpotfireDocument;
            Returns a ModVisualization via a property called visualization
            /** * Gets an object representing the content in the Mod Visualization and provides methods to read and/or modified it. */ visualization: ModVisualization;
            Returns a ModProperty via a method called property
            /** * Provides access to the {@link ModProperty} with the specified `name`. */ property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>;
            Returns a Size via a method called windowSize
            /** * Provides read-only access to the current size of the browser window in which the Mod * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI. */ windowSize(): Readable<Size>;
            Returns a Reader via a method called createReader
            /** * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters. * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. * @param readables - The {@link Readable}s that will be available in the reader. */ createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>;
            Returns a Controls via a property called controls
            /** * Gets an object that allows showing Spotfire controls and other UI component, like context menus, tooltips, etc. */ controls: Controls;
            Returns a RenderContext via a method called getRenderContext
            /** * Get the Mod's render context. This function should be invoked as soon as possible in the {@link initialize} callback. * * If this method is called in the {@link initialize} callback, Spotfire will wait for the Mod to finish rendering during * an export. The export will be made once the {@link RenderContext.signalRenderComplete} method has been called. * * If this method is not called in the {@link initialize} callback, Spotfire will _not_ wait for the Mod to finish rendering during * an export. Instead, the Mod will be automatically exported after one second. */ getRenderContext(): RenderContext;
            Returns a ModMetadata via a property called metadata
            /** * Get mod metadata - name, id, version, etc. */ metadata: ModMetadata;

            Referenced by

            Used as a function parameter in OnLoadCallback
            (mod: Mod) => void | Promise<void>

            Call site

            • initialize > OnLoadCallback > Mod

            More info can be found in theAPI documentation


            Show declarationHide declaration

            /**
             * Represents the entire Mod API and exposes methods for interacting with and reading data from
             * the Mod Visualization and the Spotfire document.
             *
             * Reading content from the Mod is made by using either of the methods {@link Reader.subscribe} or {@link Reader.once} on an instance of a {@link Reader}.
             * @public
             */
            export declare interface Mod {
                /**
                 * Gets an object that provides access to Spotfire document.
                 */
                document: SpotfireDocument;
                /**
                 * Gets an object representing the content in the Mod Visualization and provides methods to read and/or modified it.
                 */
                visualization: ModVisualization;
                /**
                 * Provides access to the {@link ModProperty} with the specified `name`.
                 */
                property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>;
                /**
                 * Provides read-only access to the current size of the browser window in which the Mod
                 * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI.
                 */
                windowSize(): Readable<Size>;
                /**
                 * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters.
                 * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked
                 * when one or more of the {@link Readable}s have changed.
                 * @param readables - The {@link Readable}s that will be available in the reader.
                 */
                createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>;
                /**
                 * Gets an object that allows showing Spotfire controls and other UI component, like context menus, tooltips, etc.
                 */
                controls: Controls;
                /**
                 * Performs a set of synchronous modifications in an explicit transaction to the Spotfire document.
                 *
                 * Use of this method is only needed to make sure that a set of modifications are done as one transaction, thereby resulting in one undo step.
                 * Modifications done outside of a transaction action callback will be grouped together in an implicit transaction.
                 *
                 * @param action - callback with a set of modifications
                 * @param onComplete - optional callback that is called when the transaction is committed or rolled back. When there is an error argument in the callback the transaction was rolled back.
                 * @example
                 * ```
                 * mod.transaction(() => {
                 *     mod.property("X").set("new value for X");
                 *     mod.property("Y").set("new value for Y");
                 * },
                 * (error) => {
                 *     if (error) {
                 *         // Show error message.
                 *     }
                 *     else {
                 *         // Handle success, e.g. re-enable action button.
                 *     }
                 * });
                 * ```
                 */
                transaction(action: () => void, onComplete?: (error?: string) => void): void;
                /**
                 * Get the Mod's render context. This function should be invoked as soon as possible in the {@link initialize} callback.
                 *
                 * If this method is called in the {@link initialize} callback, Spotfire will wait for the Mod to finish rendering during
                 * an export. The export will be made once the {@link RenderContext.signalRenderComplete} method has been called.
                 *
                 * If this method is not called in the {@link initialize} callback, Spotfire will _not_ wait for the Mod to finish rendering during
                 * an export. Instead, the Mod will be automatically exported after one second.
                 */
                getRenderContext(): RenderContext;
                /**
                 * Get mod metadata - name, id, version, etc.
                 */
                metadata: ModMetadata;
            }

            ModMetadata

            Represents that metadata of the Mod Visualization, as defined in the mod-manifest-json.

            Referenced by

            Stored as a property called metadata in a Mod
            /** * Get mod metadata - name, id, version, etc. */ metadata: ModMetadata;

            Call site

            • Mod > ModMetadata

            More info can be found in theAPI documentation


            Show declarationHide declaration

            /**
             * Represents that metadata of the Mod Visualization, as defined in the mod-manifest-json.
             * @public
             */
            export declare interface ModMetadata {
                /**
                 * Gets the id of the Mod Visualization, as defined in the mod-manifest-json.
                 */
                id: string;
                /**
                 * Gets the name of the Mod Visualization, as defined in the mod-manifest-json.
                 */
                name: string;
                /**
                 * Gets the version of the Mod Visualization, as defined in the mod-manifest-json.
                 */
                version: string;
                /**
                 * Gets the api version used by the Mod Visualization, as declared in the mod-manifest-json.
                 */
                apiVersion: string;
            }

            ModProperty

            Represents a property owned by the Mod Visualization. The Mod manifest defines the properties owned by the Mod Visualization.

            References

            Extends ModPropertyValue
            /** * Represents a property owned by the Mod Visualization. * The Mod manifest defines the properties owned by the Mod Visualization. * @public */ export declare interface ModProperty<T extends ModPropertyDataType = ModPropertyDataType> extends ModPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T): void; }

            Referenced by

            Returned from a method called property in Mod
            /** * Provides access to the {@link ModProperty} with the specified `name`. */ property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>;

            Call site

            • Mod > ModProperty

            More info can be found in theAPI documentation


            Show declarationHide declaration

            /**
             * Represents a property owned by the Mod Visualization.
             * The Mod manifest defines the properties owned by the Mod Visualization.
             * @public
             */
            export declare interface ModProperty<T extends ModPropertyDataType = ModPropertyDataType> extends ModPropertyValue<T> {
                /**
                 * Set the value of this instance.
                 * @param value - The value to set.
                 */
                set(value: T): void;
            }

            ModPropertyDataType

            Represents the data types possible to store in a mod ModProperty.


              More info can be found in theAPI documentation


              Show declarationHide declaration

              /**
               * Represents the data types possible to store in a mod {@link ModProperty}.
               * @public
               */
              export declare type ModPropertyDataType = string | number | boolean;

              ModPropertyValue

              Represents the values held by a ModProperty.

              Referenced by

              Extended by ModProperty
              /** * Represents a property owned by the Mod Visualization. * The Mod manifest defines the properties owned by the Mod Visualization. * @public */ export declare interface ModProperty<T extends ModPropertyDataType = ModPropertyDataType> extends ModPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T): void; }

              Call site

              • Mod > ModProperty > ModPropertyValue

              More info can be found in theAPI documentation


              Show declarationHide declaration

              /**
               * Represents the values held by a {@link ModProperty}.
               * @public
               */
              export declare interface ModPropertyValue<T extends ModPropertyDataType = ModPropertyDataType> {
                  /**
                   * Gets the name of this instance.
                   */
                  name: string;
                  /**
                   * Gets the value held by this instance;
                   */
                  value<T2 extends T>(): T2 | null;
              }

              ModVisualization

              Represents the content in the Mod Visualization that can be read and/or modified. The content is a combination of state stored by the Mod Visualization in the Spotfire document, its view of the data and relevant UI properties. All values are Readable objects and are typically accessed using the Reader object.

              References

              Returns a DataView via a method called data
              /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy;
              Returns a DataTable via a method called mainTable
              /** * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization * uses as its main table. */ mainTable(): ReadableProxy<DataTable>;
              DataTable is used as a parameter in a method called setMainTable
              /** * Sets the main {@link DataTable} in the Mod visualization. * @param table - The {@link DataTable} object to be used as main table. */ setMainTable(table: DataTable): void;
              Returns a Axis via a method called axis
              /** * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes * must be declared in the mod-manifest.json. * @param name - The name of the {@link Axis}. */ axis(name: string): ReadableProxy<Axis>;

              Referenced by

              Stored as a property called visualization in a Mod
              /** * Gets an object representing the content in the Mod Visualization and provides methods to read and/or modified it. */ visualization: ModVisualization;

              Call site

              • Mod > ModVisualization

              More info can be found in theAPI documentation


              Show declarationHide declaration

              /**
               * Represents the content in the Mod Visualization that can be read and/or modified.
               *
               * The content is a combination of state stored by the Mod Visualization in the Spotfire document,
               * its view of the data and relevant UI properties. All values are {@link Readable} objects and are
               * typically accessed using the {@link Reader} object.
               *
               * @public
               */
              export declare interface ModVisualization {
                  /**
                   * Provides access to the {@link DataView} that the Mod Visualization is to render.
                   */
                  data(): DataViewProxy;
                  /**
                   * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization
                   * uses as its main table.
                   */
                  mainTable(): ReadableProxy<DataTable>;
                  /**
                   * Sets the main {@link DataTable} in the Mod visualization.
                   * @param tableName - The name or id of the {@link DataTable} to be used as main table.
                   */
                  setMainTable(tableName: string): void;
                  /**
                   * Sets the main {@link DataTable} in the Mod visualization.
                   * @param table - The {@link DataTable} object to be used as main table.
                   */
                  setMainTable(table: DataTable): void;
                  /**
                   * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes
                   * must be declared in the mod-manifest.json.
                   * @param name - The name of the {@link Axis}.
                   */
                  axis(name: string): ReadableProxy<Axis>;
              }

              OmittedReadableProxyMethods

              Represents methods that are not available on a ReadableProxy. To access these methods the ReadableProxy must be awaited.


                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents methods that are not available on a {@link ReadableProxy}. To access these methods the {@link ReadableProxy} must be awaited.
                 * @public
                 */
                export declare type OmittedReadableProxyMethods = "value" | "valueList";

                OnLoadCallback

                Represents a function that consumes the Mod API. See initialize.

                References

                Mod is used as a parameter
                (mod: Mod) => void | Promise<void>

                Referenced by

                Used as a function parameter in initialize
                /* * Copyright © 2025. Cloud Software Group, Inc. * This file is subject to the license terms contained * in the license file that is distributed with this file. */ export as namespace Spotfire; /** * Predicate to determine if a current read operation for {@link DataView.allRows} should be aborted when there is new, non-streaming, data available. If this predicate returns true the {@link DataView.allRows} promise will be rejected and no rows will be returned. * @public */ export declare type AbortPredicate = (currentRowCount: number) => boolean; /** * Represents a property owned by the Spotfire document. * These can be either document properties, data table properties or data column properties. * @public */ export declare interface AnalysisProperty<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> extends AnalysisPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T | T[] | null): void; } /** * Represents the data types possible to store in a document, table or column {@link AnalysisProperty}. * @public */ export declare type AnalysisPropertyDataType = string | number | boolean | Date | TimeSpan | Time; /** * Represents the values held by a {@link AnalysisProperty}. * @public */ export declare interface AnalysisPropertyValue<T extends AnalysisPropertyDataType = AnalysisPropertyDataType> { /** * Gets the name of this instance. */ name: string; /** * Gets the value held by this instance. Will throw if the value is a list, i.e. {@link AnalysisPropertyValue.isList} returns true; */ value<T2 extends T>(): T2 | null; /** * Gets the value held by this instance. Will throw if the value is not a list, i.e. {@link AnalysisPropertyValue.isList} returns false; */ valueList<T2 extends T>(): T2[]; /** * Get the Spotfire internal data type of the property. */ dataType: DataType; /** * Gets a value indicating whether the property is a list. */ isList: boolean; } /** * Represents an axis of the Mod Visualization. * @public */ export declare interface Axis extends AxisValues { /** * Sets the full axis expression to the specified `value`. */ setExpression(value: string): void; } /** * Represents one element of a multi-part axis expression. * @public */ export declare interface AxisPart { /** * Gets the expression of this part. */ expression: string; /** * Gets the display name of this part. */ displayName: string; } /** * Represents the values held by an {@link Axis}. * @public */ export declare interface AxisValues { /** * Gets the name of this instance. */ name: string; /** * Gets the {@link AxisPart}s that this axis has. The parts are derived from the current {@link AxisValues.expression}. */ parts: AxisPart[]; /** * Gets the full expression of this instance, including multi-part delimiters and * surrounding "\<\>" brackets if the axis is in categorical mode. */ expression: string; /** * Gets a value indicating whether the axis is categorical or continuous. */ isCategorical: boolean; } /** * Represents a data column in a Spotfire data table. * @public */ export declare interface Column extends ColumnValues { /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; } /** * Represents the values held by a {@link Column}. * @public */ export declare interface ColumnValues { /** * Gets the name of this instance. */ name: string; /** * Gets the data type of this instance. */ dataType: DataType; } /** * Represents an object with methods to show a context menu. * @public */ export declare interface ContextMenu { /** * Shows a context menu with the specified `items`. The context menu closes when the user clicks one of the * items or outside the context menu. * @param x - The horizontal pixel coordinate where to show the context menu. * @param y - The vertical pixel coordinate where to show the context menu. * @param items - Defines the content of the context menu. * @returns A Promise that, when resolved, provides the {@link ContextMenuItem} that was clicked by the user, * or `undefined` if the user clicked outside the context menu. */ show(x: number, y: number, items: ContextMenuItem[]): Promise<ContextMenuItem>; } /** * Represents an item in a context menu shown by calling {@link ContextMenu.show}. * @public */ export declare interface ContextMenuItem { /** * Specifies the text to show in this item. */ text: string; /** * Specifies whether this item is enabled. */ enabled: boolean; /** * Specifies the tooltip to show for this item. If not defined, no tooltip will be shown when hovering the this item. */ tooltip?: string; /** * Specifies a value indicating whether this item is checked. If not defined, this item will not be rendered in a checked state. */ checked?: boolean; } /** * Provides access points to launch Spotfire controls and UI component relevant for a Mod Visualization. * @public */ export declare interface Controls { /** * Gets an object with methods to show a context menu. */ contextMenu: ContextMenu; /** * Gets an object with methods to show and hide a Spotfire tooltip. */ tooltip: Tooltip; /** * Gets an object with methods to show and hide the Spotfire progress indicator. */ progress: Progress; /** * Gets an object that can be used to create and show a Spotfire popout dialog. */ popout: Popout; /** * Gets an object that can be used to show an error overlay native Spotfire style. */ errorOverlay: ErrorOverlay; } /** * Represents the styling information that applies to a control of some kind in the Mod Visualization. * For example, the controls for search, layers, navigation, etc., in a Spotfire Map Chart follows this styling. * @public * @version 2.1 */ export declare interface ControlStylingInfo { /** * Gets the value to use for the `background-color` CSS property. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the color CSS properties in different states. * @version 2.1 */ color: StateDependentValue<string>; } /** * Represents the basic settings of a custom theme used in Spotfire. * @public * @version 2.1 */ export declare interface CustomThemeStylingInfo { /** * Gets a value describing the theme that this custom theme is based on. */ baseTheme: KnownTheme; /** * Gets the base color of the theme. * @version 2.1 */ baseColor: string; /** * Gets the primary color of the theme. * @version 2.1 */ primaryColor: string; } /** * Represents a data table in the Spotfire document. * @public */ export declare interface DataTable extends DataTableValues { /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>; /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>; /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>; /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>; } /** * Represents the values held by a {@link DataTable}. * @public */ export declare interface DataTableValues { /** * Gets the name of this instance. */ name: string; /** * Gets the number of columns in this instance. */ columnCount: number; /** * Gets the unique id for this instance. * The id is stable during the data table life cycle, thus it can be used to store as a reference to this data table in a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 */ id: string; } /** * Represents the data type of a value. * @public */ export declare interface DataType { /** * Gets the name of this DataType. */ name: "String" | "Integer" | "LongInteger" | "Real" | "SingleReal" | "Currency" | "Boolean" | "Date" | "DateTime" | "Time" | "TimeSpan" | "Binary"; /** * Gets a value indicating whether the data type is numeric or not, that is, * Integer, Currency, Real, LongInteger, or SingleReal. */ isNumber(): boolean; /** * Gets a value indicating whether the data type is represents by Date or not, that is, Date, or DateTime. */ isDate(): boolean; /** * Gets a value indicating whether the data type is represents by {@link Time} or not. */ isTime(): boolean; /** * Gets a value indicating whether the data type is represents by {@link TimeSpan} or not. */ isTimeSpan(): boolean; } /** * Represents a view of the data from which the visualization can be rendered. * * This object contains the result of the query made by Spotfire against the DataTable * currently used by the Mod Visualization, using the Filtering, Marking, expressions * on the Axes and other relevant settings. * @public */ declare interface DataView_2 { /** * Mark a set of rows. * The full set will be the union of all mark operations performed within one transaction (see {@link Mod.transaction}). * All mark operations must have the same marking operation. * @param rows - The rows to be selected. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(rows: DataViewRow[], operation?: MarkingOperation): void; /** * Clears the current marking */ clearMarking(): void; /** * Gets the marking information, or `null` if marking is not enabled. */ marking(): Promise<MarkingInfo | null>; /** * Gets a value indicating whether the dataView has expired. * The dataview has expired when there has been changes to the document, * for example marking or filtering. * When true, there will be a new dataview available on the next read. */ hasExpired(): Promise<boolean>; /** * Gets a value indicating whether the data view is the result of a streaming update. * @version 2.1 */ isStreamingUpdate: boolean; /** * Gets any errors generated while creating the dataview. * Returns empty array if none occurred. */ getErrors(): Promise<string[]>; /** * Gets metadata for a specific categorical axis in the {@link DataView}. * Categorical axes are defined in the manifest file as categorical or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.categorical} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The axis name. */ categoricalAxis(name: string): Promise<DataViewCategoricalAxis | null>; /** * Gets metadata for a specific continuous axis in the {@link DataView}. * Continuous axes are defined in the manifest file as continuous or dual. * When this method fails to return a valid axis getting the corresponding call to {@link DataViewRow.continuous} will throw an error. * Returns `null` for axes with empty expressions or for dual mode axes that currently are in categorical mode. * Throws if the axis does not exist or the axes mode is categorical. * @param name - The axis name. */ continuousAxis(name: string): Promise<DataViewContinuousAxis | null>; /** * Gets metadata of all axes currently present in the {@link DataView}. * Axes with empty expression are omitted. */ axes(): Promise<DataViewAxis[]>; /** * Gets a hierarchy for a categorical axis. * * If the axis has an empty expression the hierarchy will contain one single root node. * Returns `null` for dual mode axes that currently are in continuous mode. * Throws if the axis does not exist or the axes mode is continuous. * @param name - The name of the axis to get the hierarchy for. */ hierarchy(name: string): Promise<DataViewHierarchy | null>; /** * Gets the total number of rows of the {@link DataView} without actually getting all the rows. Use this function to determine whether or not the mod will be able to handle the amount of data rows. * When there are errors in the mod configuration there will be no rows available and this method will return undefined. */ rowCount(): Promise<number | undefined>; /** * Gets all rows from the data view as one asynchronous operation. * The allRows function has a built in cache and can be called multiple times with the same dataView and it will return the same list of rows. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns true the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewRow}[]. */ allRows(abortPredicate?: AbortPredicate): Promise<DataViewRow[] | null>; } export { DataView_2 as DataView } /** * Contains metadata computed for an {@link Axis}. * @public */ export declare interface DataViewAxis { /** * Gets the name of this axis. */ name: string; /** * Gets a value indicating whether this axis is an instance of {@link DataViewContinuousAxis} or {@link DataViewCategoricalAxis} . */ isCategorical: boolean; } /** * Represents metadata computed for a categorical {@link Axis}. * @public */ export declare interface DataViewCategoricalAxis extends DataViewAxis { /** * Gets the hierarchy of this axis. */ hierarchy: DataViewHierarchy; } /** * Represents a value of a categorical axis for one row in a data view. * @public */ export declare interface DataViewCategoricalValue { /** * Gets an array representing the full path of the value in the hierarchy defined by the axis expression. * The first element is the top level of the hierarchy and the last element is the leaf level. */ value(): DataViewCategoricalValuePathElement[]; /** * Gets a formatted string that can be used to display this value. * This string is built by concatenating the {@link DataViewCategoricalValuePathElement.formattedValue} for each element found in the {@link DataViewCategoricalValue.value} array. * @param separator - The separator used for concatenation. The default separator is " » ". */ formattedValue(separator?: string): string; /** * Gets the index among the leaf nodes of the associated {@link DataViewHierarchy} of this {@link DataViewCategoricalAxis}. * This, for example, can be used to determine the position on a scale where to render the visual element. */ leafIndex: number; } /** * Represents an element in the `path` of a {@link DataViewCategoricalValue}. * @public */ export declare interface DataViewCategoricalValuePathElement { /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; /** * Gets a key that uniquely identifies this element. * * In many cases this will be the same as {@link DataViewCategoricalValuePathElement.formattedValue} and {@link DataViewCategoricalValuePathElement.value}. * However there are cases when those values can contain duplicates. For instance when working with cube data, * or when using formatters and display values. * * They key is suitable to be used for identifying objects when implementing rendering transitions. * * The key can be `null` when the corresponding {@link DataViewCategoricalValuePathElement.value} is null. */ key: string | null; /** * Gets the value of this element, or `null` if this element represents a missing or invalid data point. * * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the {@link DataViewHierarchy} of * the associated {@link DataViewCategoricalAxis}. */ value<T extends DataViewValueType>(): T | null; } /** * Color information for a {@link DataViewRow}. * @public */ export declare interface DataViewColorInfo { /** The hex code for the color. */ hexCode: string; } /** * Represents metadata computed for continuous {@link Axis}. * @public */ export declare interface DataViewContinuousAxis extends DataViewAxis { /** * Gets the data type of the values computed by this axis. */ dataType: DataType; } /** * Represents a value of a continuous axis for one row in a data view. * @public */ export declare interface DataViewContinuousValue<T extends DataViewValueType = DataViewValueType> { /** * Gets the value of this instance. The type depending on the type of the * expression on the associated {@link DataViewContinuousAxis}. * * This method will return `null` when the underlying data value is missing or invalid. */ value<T2 extends DataViewValueType = T>(): T2 | null; /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; } /** * Represents a hierarchy for a {@link DataViewCategoricalAxis}. * @public */ export declare interface DataViewHierarchy { /** * Gets the name of this hierarchy, the same as the associated {@link DataViewCategoricalAxis}. */ name: string; /** * Gets a value indicating whether the hierarchy is empty, i.e. the axis expression is empty, or not. * For convenience, an empty hierarchy will have one single node that may contain all rows in the dataview. */ isEmpty: boolean; /** * Gets the levels of this hierarchy. The root node has no corresponding level. */ levels: DataViewHierarchyLevel[]; /** * Gets the total number of leaf nodes in the hierarchy. */ leafCount: number; /** * Gets the virtual root node of the hierarchy. The level of the root node is -1. Spotfire does not usually render the root node in visualization. * @param abortPredicate - Optional. Predicate to determine whether the operation should be aborted when there is new, non-streaming, data available. If this predicate returns `true` the promise will be rejected. * The default behavior is that reading will be aborted when new non-streaming update is available. * @returns `null` if reading data was aborted, otherwise a {@link DataViewHierarchyNode}. */ root(abortPredicate?: AbortPredicate): Promise<DataViewHierarchyNode | null>; } /** * Represents the levels of a hierarchy. * @public */ export declare interface DataViewHierarchyLevel { /** * The name of the hierarchy level, derived from the expression on the {@link Axis}. */ name: string; /** * Gets the data type of the values in this level of the hierarchy. */ dataType: DataType; } /** * Represents a node in a {@link DataViewHierarchy}. * @public */ export declare interface DataViewHierarchyNode { /** * Gets a formatted string that can be used to display this value. * The formatting settings in Spotfire are used to create this string. */ formattedValue(): string; /** * Gets the full path, top down to this node, of the formatted values. The virtual root node is omitted. * @param separator - The separator. The default separator is " » ". */ formattedPath(separator?: string): string; /** * Gets the key for this hierarchy node. The key is guaranteed to be unique for the node among its siblings. * * In many cases this will be the same as {@link DataViewHierarchyNode.formattedValue} or {@link DataViewHierarchyNode.value}. * However there are cases when those values can contain duplicates. For instance when working with cube data, * or when using formatters and display values. * * They key is suitable to be used for identifying objects when implementing rendering transitions. * * The key can be `null` when the corresponding {@link DataViewHierarchyNode.value} is null. */ key: string | null; /** * Gets the value of this node, or `null` if this node represents a missing or invalid data point. * * The type of the returned value can be determined from the {@link DataViewHierarchy.levels} in the associated {@link DataViewHierarchy}. */ value<T extends DataViewValueType>(): T | null; /** * Gets the parent of the hierarchy node, or `undefined` for root level nodes. */ parent?: DataViewHierarchyNode; /** * Gets the children of this node, or `undefined` if this node is a leaf node. */ children?: DataViewHierarchyNode[]; /** * Computes an array of all leaf nodes in the sub tree of the hierarchy spanned from this node. */ leaves(): DataViewHierarchyNode[]; /** * Gets the index of the leaf node among all leaf nodes in the hierarchy. This is undefined for non leaf nodes. */ leafIndex?: number; /** * Marks all {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. * See {@link DataView.mark} for more details. * @param operation - The marking operation. */ mark(operation?: MarkingOperation): void; /** * Computes the number of {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rowCount(): number; /** * Computes the number of leaf nodes in the sub tree of the hierarchy spanned from this node. */ leafCount(): number; /** * Computes the number of marked {@link DataViewRow}s in the sub tree of the hierarchy spanned from this node. */ markedRowCount(): number; /** * Gets the level in the hierarchy where this node occurs. The root node of the hierarchy tree has level -1. */ level: number; /** * Computes the {@link DataViewRow}s corresponding to the sub tree of the hierarchy spanned from this node. */ rows(): DataViewRow[]; } /** * Represents an object that provides access to a {@link DataView}. * @public */ export declare type DataViewProxy = DataViewProxyMethods & Readable<DataView_2>; /** * Represents the methods available on a {@link DataViewProxy}. * @public */ export declare interface DataViewProxyMethods { /** * Clears the current marking */ clearMarking(): void; } /** * Represents a row of data in a {@link DataView}. Each row can be thought of as a data point that the mod visualization renders. * @public */ export declare interface DataViewRow { /** * Gets a value indicating whether this row is marked. */ isMarked(): boolean; /** * Gets a {@link DataViewCategoricalValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no categorical axis by that name or if the expression is empty. * Use {@link DataView.categoricalAxis} to check the current existence of a categorical value. * @param axisName - The name of the axis to get the value for. */ categorical(axisName: string): DataViewCategoricalValue; /** * Gets a {@link DataViewContinuousValue} representing the value of the axis with the specified `axisName`. * This method will throw an error if there is no continuous axis by that name or if the expression is empty. * Use {@link DataView.continuousAxis} to check the current existence of a continuous value. * @param axisName - The name of the axis to get the value for. */ continuous<T extends DataViewValueType>(axisName: string): DataViewContinuousValue<T>; /** * Gets the leaf {@link DataViewHierarchyNode} for the specified axis, * or `null` for dual mode axes with continuous axis expression. * This method will throw an error for continuous mode axes * or if there is no axis by that name. * @param axisName - The name of the axis * @version 1.1 */ leafNode(axisName: string): DataViewHierarchyNode | null; /** * Calculates an element id for this row, suitable for identifying rows between data views. * When stable identifiers is not used, only rows in immediately following data view are guaranteed to re-use previous id. * If a row is filtered out in a new data view, this row is thus not guaranteed to yield the same id when it re-appears. * * @note A stable element id is only stable in the current session, thus it should not be stored in the document, * e.g. as a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 * * @param useStableId - When true, the id will be a (longer) stable id guaranteed to be the same over time. * @param omitAxisNames - Axis names to omit when creating the identifier. Can be used to group multiple elements split by these axes, for example to create animation effects in one data view. */ elementId(useStableId?: boolean, omitAxisNames?: string[]): string; /** * Gets the {@link DataViewColorInfo} for the row, if a color axis is defined in the mod manifest. * The underlying data value can be retrieved by using {@link DataViewRow.categorical}("Color") or {@link DataViewRow.continuous}("Color"), depending on the mode of the color axis. */ color(): DataViewColorInfo; /** * Performs the specified marking operation in the current marking. * * **Note** All mark operations within one {@link Mod.transaction} must have the same {@link MarkingOperation}. * * See {@link DataView.mark} for more details. * @param operation - Optional {@link MarkingOperation}. Default value is `Replace`. */ mark(operation?: MarkingOperation): void; } /** * Represents the type of a {@link DataView} value. The actual type that a given value has depends on the * type of the expression on the associated axis. * @public */ export declare type DataViewValueType = number | string | boolean | Date | Time | TimeSpan; /** * Represents a group of values used for the top, bottom, left and right edges of a CSS property of an associated DOM element. * @public * @version 2.1 */ export declare interface EdgeValues<T> { /** * Gets the value to use for the `-top-` CSS property. For instance `border-top-color`. * @version 2.1 */ top: T; /** * Gets the value to use for the `-bottom-` CSS property. For instance `border-bottom-color`. * @version 2.1 */ bottom: T; /** * Gets the value to use for the `-left-` CSS property. For instance `border-left-color`. * @version 2.1 */ left: T; /** * Gets the value to use for the `-right-` CSS property. For instance `border-right-color`. * @version 2.1 */ right: T; } /** * Provides access to show an error overlay covering the entire Mod shown by Spotfire. * @public */ export declare interface ErrorOverlay { /** * Show error message. Showing any error message will hide the Mods UI. * @param messages - The error messages. Each message will be shown in its own paragraph. * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category. */ show(messages: string[], category?: string): void; /** * Show error message. Showing any error message will hide the Mods UI. * @param message - The error message. * @param category - Optional error categorization. Useful if multiple error message are to be shown. Error messages will be sorted based on the category. */ show(message: string, category?: string): void; /** * Clear the error message. If no other error messages are currently visible the Mods UI will be shown. * @param category - Optional error categorization. */ hide(category?: string): void; } /** * From readableArray, an array of Readable of some value type, extract an array of this value type. * @public */ export declare type ExtractValueType<readableArray extends ReadonlyArray<Readable<any>>> = { [readableName in keyof readableArray]: readableArray[readableName] extends Readable<infer readableNameType> ? readableNameType : never; }; /** * Represents information about a font that is used in the Mod Visualization. * @public */ export declare interface FontInfo { /** * Gets the value to use for the `font-family` CSS property. */ fontFamily: string; /** * Gets the font size in pixels. */ fontSize: number; /** * Gets the value to use for the `font-style` CSS property. */ fontStyle: string; /** * Gets the value to use for the `font-weight` CSS property. */ fontWeight: string; /** * Gets the value to use for the `color` CSS property. */ color: string; } /** * Represents the general styling information that applies to the Mod Visualization. * @public */ export declare interface GeneralStylingInfo { /** * Gets and object describing the font that shall be used by the Mod Visualization. */ font: FontInfo; /** * Gets the value to use for the `background-color` CSS property of the Mod Visualization. */ backgroundColor: string; /** * Gets a value describing the theme that is used in the Spotfire UI. */ activeTheme: KnownTheme | CustomThemeStylingInfo; } /** * Initializes the Mod API. The specified `onLoaded` callback is called when the initialization is complete. * @example * ``` * Spotfire.initialize(async (mod) => { * console.log("Mod API loaded."); * }); * ``` * The initialize method will invoke the provided callback with an instance of the mod API, to be used by the mod developer. * * The initialize method needs to be invoked in order for the mod to function. Even if the mod only displays static content, the API must be initialized in order for events and export to work. * @public * @param onLoaded - Callback that is called when the mod API is initialized and ready to be interacted with. */ export declare function initialize(onLoaded: OnLoadCallback): void; /** * Describes the theme that is used in the Spotfire UI. * @public * @version 2.1 */ export declare type KnownTheme = "Light" | "Dark"; /** * Represents the styling information that applies to scale lines in the Mod Visualization. * @public */ export declare interface LineStylingInfo { /** * Gets the stroke to use for scale lines. This value is valid a CSS color or the value `"none"`. */ stroke: string; } /** * Marking information for a {@link DataView}. * @public */ export declare interface MarkingInfo { /** The hex code for the marking. Note that when the mod has a defined color axis, the color should be retrieved via the {@link DataViewRow.color} method. */ colorHexCode: string; /** The name of the marking. */ name: string; } /** * Specifies how a Marking shall be modified. * <pre> * - "Replace" - replaces the current marking. * - "Add" - adds to the current marking. * - "Subtract" - removes the current marking. * - "Toggle" - toggles marking on each item in the set. * - "Intersect" - marks the intersection of the current marking and the specified set. * - "ToggleOrAdd" - will behave like toggle if all or no rows in the set are marked, otherwise it is an add operation. This is the default Spotfire behavior for control marking. * </pre> * @public */ export declare type MarkingOperation = "Replace" | "Add" | "Subtract" | "Toggle" | "Intersect" | "ToggleOrAdd"; /** * Extract from T the keys of all properties with function values. * @public */ export declare type MethodKeys<T> = { [P in keyof T]: T[P] extends Function ? P : never; }[keyof T]; /** * Represents the entire Mod API and exposes methods for interacting with and reading data from * the Mod Visualization and the Spotfire document. * * Reading content from the Mod is made by using either of the methods {@link Reader.subscribe} or {@link Reader.once} on an instance of a {@link Reader}. * @public */ export declare interface Mod { /** * Gets an object that provides access to Spotfire document. */ document: SpotfireDocument; /** * Gets an object representing the content in the Mod Visualization and provides methods to read and/or modified it. */ visualization: ModVisualization; /** * Provides access to the {@link ModProperty} with the specified `name`. */ property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>; /** * Provides read-only access to the current size of the browser window in which the Mod * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI. */ windowSize(): Readable<Size>; /** * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters. * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. * @param readables - The {@link Readable}s that will be available in the reader. */ createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>; /** * Gets an object that allows showing Spotfire controls and other UI component, like context menus, tooltips, etc. */ controls: Controls; /** * Performs a set of synchronous modifications in an explicit transaction to the Spotfire document. * * Use of this method is only needed to make sure that a set of modifications are done as one transaction, thereby resulting in one undo step. * Modifications done outside of a transaction action callback will be grouped together in an implicit transaction. * * @param action - callback with a set of modifications * @param onComplete - optional callback that is called when the transaction is committed or rolled back. When there is an error argument in the callback the transaction was rolled back. * @example * ``` * mod.transaction(() => { * mod.property("X").set("new value for X"); * mod.property("Y").set("new value for Y"); * }, * (error) => { * if (error) { * // Show error message. * } * else { * // Handle success, e.g. re-enable action button. * } * }); * ``` */ transaction(action: () => void, onComplete?: (error?: string) => void): void; /** * Get the Mod's render context. This function should be invoked as soon as possible in the {@link initialize} callback. * * If this method is called in the {@link initialize} callback, Spotfire will wait for the Mod to finish rendering during * an export. The export will be made once the {@link RenderContext.signalRenderComplete} method has been called. * * If this method is not called in the {@link initialize} callback, Spotfire will _not_ wait for the Mod to finish rendering during * an export. Instead, the Mod will be automatically exported after one second. */ getRenderContext(): RenderContext; /** * Get mod metadata - name, id, version, etc. */ metadata: ModMetadata; } /** * Represents that metadata of the Mod Visualization, as defined in the mod-manifest-json. * @public */ export declare interface ModMetadata { /** * Gets the id of the Mod Visualization, as defined in the mod-manifest-json. */ id: string; /** * Gets the name of the Mod Visualization, as defined in the mod-manifest-json. */ name: string; /** * Gets the version of the Mod Visualization, as defined in the mod-manifest-json. */ version: string; /** * Gets the api version used by the Mod Visualization, as declared in the mod-manifest-json. */ apiVersion: string; } /** * Represents a property owned by the Mod Visualization. * The Mod manifest defines the properties owned by the Mod Visualization. * @public */ export declare interface ModProperty<T extends ModPropertyDataType = ModPropertyDataType> extends ModPropertyValue<T> { /** * Set the value of this instance. * @param value - The value to set. */ set(value: T): void; } /** * Represents the data types possible to store in a mod {@link ModProperty}. * @public */ export declare type ModPropertyDataType = string | number | boolean; /** * Represents the values held by a {@link ModProperty}. * @public */ export declare interface ModPropertyValue<T extends ModPropertyDataType = ModPropertyDataType> { /** * Gets the name of this instance. */ name: string; /** * Gets the value held by this instance; */ value<T2 extends T>(): T2 | null; } /** * Represents the content in the Mod Visualization that can be read and/or modified. * * The content is a combination of state stored by the Mod Visualization in the Spotfire document, * its view of the data and relevant UI properties. All values are {@link Readable} objects and are * typically accessed using the {@link Reader} object. * * @public */ export declare interface ModVisualization { /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy; /** * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization * uses as its main table. */ mainTable(): ReadableProxy<DataTable>; /** * Sets the main {@link DataTable} in the Mod visualization. * @param tableName - The name or id of the {@link DataTable} to be used as main table. */ setMainTable(tableName: string): void; /** * Sets the main {@link DataTable} in the Mod visualization. * @param table - The {@link DataTable} object to be used as main table. */ setMainTable(table: DataTable): void; /** * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes * must be declared in the mod-manifest.json. * @param name - The name of the {@link Axis}. */ axis(name: string): ReadableProxy<Axis>; } /** * Represents methods that are not available on a {@link ReadableProxy}. To access these methods the {@link ReadableProxy} must be awaited. * @public */ export declare type OmittedReadableProxyMethods = "value" | "valueList"; /** * Represents a function that consumes the {@link Mod} API. See {@link initialize}. * @public */ export declare type OnLoadCallback = (mod: Mod) => void | Promise<void>; /** * Represents a Page in a Spotfire document. * @public */ export declare interface Page extends PageValues { /** * Sets this instance as the active page. */ setAsActive(): void; } /** * Represents the values held by a {@link Page}. * @public */ export declare interface PageValues { /** * Gets the name of this instance. */ name: string; /** * Gets a value indicating whether this instance is visible. */ visible: boolean; /** * Gets the zero-based index in this instance in the page collection in the Spotfire document. */ index: number; /** * Gets the unique id for this instance. * The id is stable during the page life cycle, thus it can be used to store as a reference to this page in a {@link ModProperty} or {@link AnalysisProperty}. * @version 1.1 */ id: string; } /** * Represents an object that can be used to create and show a Spotfire popout dialog. * @public */ export declare interface Popout { /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog; /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection; /** * Gets an object with methods that create {@link PopoutComponent}s. */ components: PopoutComponentFactory; } /** * Represents options describing how to render a button. See {@link PopoutComponentFactory.button}. * @public */ export declare interface PopoutButtonOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display in the button. */ text: string; } /** * Represents options describing how to render a checkbox. See {@link PopoutComponentFactory.checkbox}. * @public */ export declare interface PopoutCheckboxOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display next to the checkbox. */ text: string; /** * Specifies the tooltip to display. If undefined, no tooltip is shown. */ tooltip?: string; /** * Specifies whether the checkbox is checked. */ checked: boolean; /** * Specifies whether the checkbox is enabled. */ enabled: boolean; } /** * Represents a component of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutComponent { /** * Gets the type of the control. */ type: string; } /** * Represents the data of an event that occurs when a {@link PopoutComponent} has been changed by the user. * @public */ export declare interface PopoutComponentEvent { /** * Gets the name that identifies the component that has been changed. */ name: string; /** * Gets the value of the component that has been changed. */ value?: any; } /** * Represents an object with methods that create {@link PopoutComponent}s. * @public */ export declare interface PopoutComponentFactory { /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent; /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent; /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent; } /** * Represents a pop out dialog that is shown by Spotfire. See {@link Controls.popout}. * @public */ export declare interface PopoutDialog { /** * Closes the pop out dialog. */ close(): void; } /** * Represents options that specifies where and how a pop out dialog shall be shown. * @public */ export declare interface PopoutOptions { /** * Specifies the horizontal pixel coordinate of the anchor point of the pop out dialog. * * The coordinate is specified relative to an origin in the top left corner of the Mod viewport. */ x: number; /** * Specifies the vertical pixel coordinate of the anchor point of the pop out dialog. * * The coordinate is specified relative to an origin in the top left corner of the Mod viewport. */ y: number; /** * Specifies how to position of the popout in relation to the anchor point specified by `x` and `y`. * * The alignment value specifies which edge of the pop out that shall be closest to the anchor point. For example, * to show the pop out below the anchor point, specify `Top`. */ alignment?: "Left" | "Right" | "Top" | "Bottom"; /** * Specifies whether to automatically close the popout when one of the components in it is clicked. */ autoClose: boolean; /** * Specifies the callback to invoke when a component in the pop out dialog is changed. */ onChange(event: PopoutComponentEvent): void; /** * Specifies the callback to invoke when the pop out dialog has been closed. * This callback is optional and can be left unassigned. */ onClosed?(): void; } /** * Represents options describing how to render a radio button. See {@link PopoutComponentFactory.radioButton}. * @public */ export declare interface PopoutRadioButtonOptions { /** * Specifies the name that identifies the component. */ name: string; /** * Specifies the text to display next to the radio button. */ text: string; /** * Specifies the tooltip to display. If undefined, no tooltip is shown. */ tooltip?: string; /** * Specifies whether the radio button is checked. */ checked: boolean; /** * Specifies whether the radio button is enabled. * @version 1.1 */ enabled?: boolean; /** * Specifies the value represented by the radio button. */ value: any; } /** * Represents a section of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutSection { /** * Specifies the heading of the section */ heading?: string; /** * Specifies the components in the section */ children: PopoutComponent[]; } /** * Represents a section of a pop out dialog. See {@link Controls.popout}. * @public */ export declare interface PopoutSectionOptions { /** * Specifies the heading of the section */ heading?: string; /** * Specifies the components in the section */ children: PopoutComponent[]; } /** * Represents an object with methods to show and hide the Spotfire progress indicator. * @public */ export declare interface Progress { /** * Shows the progress indicator. */ show(): void; /** * Hides the progress indicator. */ hide(): void; } /** * Represents the styling information that applies to a range, for instance in a zoom slider, in the Mod Visualization. * @public * @version 2.1 */ export declare interface RangeStylingInfo { /** * Gets the value to use for the `background-color` CSS property. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; } /** * Represents a value in the Mod API that can be accessed and/or modified. These values can * be used when creating an instance of a {@link Reader} via the {@link Mod.createReader} method. * @public */ export declare interface Readable<T = any> extends Promise<T> { /** * Used internally by the Mod api. */ readableID: string; /** * Used internally by the Mod api. */ __futureValue?: T; } /** * Represents an object that provides access to a node of the specified type. * It can be used as a {@link Readable} but also acts as a proxy to the node by exposing all its methods. * Nodes that represent model state in the Spotfire document can thus be modified without first waiting * and materializing them in the browser. * * A full node will be created by using a {@link Reader}. * @public */ export declare type ReadableProxy<Node> = Readable<Node> & Omit<Pick<Node, MethodKeys<Node>>, OmittedReadableProxyMethods>; /** * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. Choose one of the appropriate methods; * {@link Reader.once} or {@link Reader.subscribe} that suits the needs of the Mod. * An instance of the reader is created by calling the {@link Mod.createReader} method. * @public */ export declare interface Reader<T extends ReadonlyArray<any>> { /** * Subscribe to changes in the content for the specified readables when the reader was created. * @example * Subscribe to changes in the {@link DataView}. * * ``` * let reader = mod.createReader(mod.visualization.data()); * reader.subscribe((dataView) => { * console.log(await dataView.rowCount()); * }); * ``` * * @param callback - The callback function that is called every time when there is at least one new value to read. * The callback function will not be called until the previous callback function has returned. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ subscribe(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription; /** * Read the content once for the readables specified when the reader was created. * Any current subscription for this reader will be cancelled. * @example * Read content of a mod property once. * * ``` * let reader = mod.createReader(mod.property("CreatedBy")); * reader.once((createdBy) => { * console.log(await createdBy.value()); * }); * ``` * * @param callback - The callback function that is called once when there is at least one new value to read. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ once(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription; /** * Checks if any of the readables have a new value available. If this function returns true, * the callback in the current subscription, or a new call to {@link Reader.once} is guaranteed * to be invoked. * The intended use of this method is to cancel rendering of the Mod if there are new values to any of the * readables specified when the reader was created. */ hasExpired(): Promise<boolean>; /** * Check whether one or more passed arguments are new since the last time the subscribe loop was called. * * @example * Check if the data view has changed in the subscribe loop. * * ``` * let reader = mod.createReader(mod.visualization.data(), mod.windowSize()); * reader.subscribe((dataView, size) => { * console.log(reader.hasValueChanged(dataView)); * }); * ``` * * @param value - Value from `subscribe` or `once` arguments. * @param values - Additional values from `subscribe` or `once` arguments. * @returns true if any of the values are new, otherwise false. * @version 1.3 */ hasValueChanged(value: UnionFromTupleTypes<T>, ...values: UnionFromTupleTypes<T>[]): boolean; } /** * Represents a {@link Reader} subscription. * @version 1.1 * @public */ export declare interface ReaderSubscription { /** * Immediately cancel the current subscription. * Neither the callback or the error callback will be invoked afterwards. */ cancel(): void; } /** * Represents contextual information needed when rendering a Mod, either in the UI or as part of an export. * @public */ export declare interface RenderContext { /** * Gets a value indicating whether the Mod is interactive. * * When this value is false the Mod is not interactive. This occurs during export, for instance to an image or to PDF. * This property can be used to hide selected controls and to avoid animations when rendering in an export context. */ interactive: boolean; /** * Gets the image pixel ratio that shall be used when rendering rasterized images and/or using a canvas element. */ imagePixelRatio: number; /** * Gets a value indicating whether the Spotfire UI is in editing mode. * * When this value is true the Spotfire UI displays authoring UI elements, such as axis selectors. * This property can be used to hide controls not meant for consumers of the analysis. * @version 1.2 */ isEditing: boolean; /** * Gets information about the currently used theme. */ styling: StylingInfo; /** * Signals that the mod is ready to be exported. * * If this method is not called, Spotfire will perform export (and preview generation etc.) of the Mod without knowing * if it has finished rendering. * * The default maximum allowed time for a Mod to finish rendering is 20 seconds. */ signalRenderComplete(): void; } /** * Represents the styling information that applies to scales in the Mod Visualization. * @public */ export declare interface ScaleStylingInfo { /** * Gets and object describing the font that shall be used in the scales of the Mod Visualization. */ font: FontInfo; /** * Gets and object describing the styling information for scale lines in the Mod Visualization. */ line: LineStylingInfo; /** * Gets and object describing the styling information for scale ticks in the Mod Visualization. */ tick: TickStylingInfo; } /** * Represents the size of an area in the UI, for example the size of the browser window in which the Mod * is rendered. See {@link Mod.windowSize}. * @public */ export declare interface Size { /** * Gets the width. */ width: number; /** * Gets the height. */ height: number; } /** * Represents the Spotfire document and provides access to read and modify parts of it. * @public */ export declare interface SpotfireDocument { /** * Provides access to the {@link DataTable}s in the Spotfire document. */ tables(): Readable<DataTable[]>; /** * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document. */ table(name: string): ReadableProxy<DataTable>; /** * Provides access to the `Document Properties` in the Spotfire Document. */ properties(): Readable<AnalysisProperty[]>; /** * Provides access to the `Document Property` with the specified `name` in the Spotfire Document. */ property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>; /** * Provides access to the {@link Page}s in the Spotfire document. */ pages(): Readable<Page[]>; /** * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible. */ activePage(): ReadableProxy<Page>; /** * Sets the specified {@link Page} as the active page. * @param name - The name/title or id of the page to set as active. */ setActivePage(name: string): void; /** * Sets the specified index as the active page index. * @param index - The index of the page to set as active. */ setActivePage(index: number): void; /** * Sets the specified {@link Page} as the active page. * @param page - The {@link Page} object to set as active. */ setActivePage(page: Page): void; } /** * Represents a group of values used in different states of an associated DOM element. * @version 2.1 * @public */ export declare interface StateDependentValue<T> { /** * Gets the value to use in the default state. That is, when no pseudo-class is active. * @version 2.1 */ default: T; /** * Gets the value to use in the `hover` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ hover?: T; /** * Gets the value to use in the `active` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ active?: T; /** * Gets the value to use in the `disabled` state. If this property is undefined, the `default` value should be used. * @version 2.1 */ disabled?: T; } /** * Represents the styling (theme) that affects the look and feel of a Mod Visualization. * @public */ export declare interface StylingInfo { /** * Gets an object describing the general aspects of the styling, including the font and background color * to use in the Mod Visualization. */ general: GeneralStylingInfo; /** * Gets an object describing the styling of the scales in the Mod Visualization. */ scales: ScaleStylingInfo; /** * Gets an object describing the styling of the trellis panel headers in the Mod Visualization. * @version 2.1 */ trellisPanelHeaders: TrellisPanelHeaderStylingInfo; /** * Gets an object describing the styling of the zoom sliders in the Mod Visualization. * @version 2.1 */ zoomSliders: ZoomSliderStylingInfo; /** * Gets an object describing the styling of controls in the Mod Visualization. * @version 2.1 */ controls: ControlStylingInfo; } /** * Represents the styling information that applies to a thumb, for instance in a zoom slider, in the Mod Visualization. * @public * @version 2.1 */ export declare interface ThumbStylingInfo { /** * Gets the value to use for the `background-image` CSS property. * @version 2.1 */ backgroundImage: StateDependentValue<string>; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; } /** * Represents the styling information that applies to scale ticks in the Mod Visualization. * @public */ export declare interface TickStylingInfo { /** * Gets the stroke to use for scale ticks. This value is valid a CSS color or the value `"none"`. */ stroke: string; } /** * Represents a Time property. The time has no notion of time zone. * @public */ export declare interface Time { /** The total number of milliseconds since midnight. */ totalMilliseconds: number; /** The millisecond part of the instance. */ milliseconds: number; /** The total number of seconds since midnight. */ totalSeconds: number; /** The second part of the instance. */ seconds: number; /** The total number of minutes since midnight. */ totalMinutes: number; /** The minute part of the instance. */ minutes: number; /** The total number of hours since midnight. */ hours: number; } /** * Represents a TimeSpan property. A time span is used to measure the time between two points in time. * @public */ export declare interface TimeSpan { /** The total number of milliseconds of the instance. */ totalMilliseconds: number; /** The millisecond part of the instance. */ milliseconds: number; /** The total number of seconds of the instance. */ totalSeconds: number; /** The second part of the instance. */ seconds: number; /** The total number of minutes of the instance. */ totalMinutes: number; /** The minute part of the instance. */ minutes: number; /** The total number of hours of the instance. */ totalHours: number; /** The hour part of the instance. */ hours: number; /** The day part of the instance. */ days: number; } /** * Represents an object with methods to show and hide a Spotfire tooltip. * @public */ export declare interface Tooltip { /** * Shows a tooltip with the specified `content` text. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * @param content - The text to show in the tooltip. */ show(content: string): void; /** * Shows a tooltip for the specified `row` as it has been configured in the properties panel. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * * @note For this feature to work, the dataViewDefinition.tooltip.enabled in the mod-manifest.json needs to be set to true. * * @param row - The row to show text for in the tooltip. * @version 1.3 */ show(row: DataViewRow): void; /** * Hides the tooltip that is currently being showed, if any. */ hide(): void; } /** * Represents the styling information that applies to trellis panel headers in the Mod Visualization. * @public * @version 2.1 */ export declare interface TrellisPanelHeaderStylingInfo { /** * Gets the color to use for the `background-color` CSS property. This value is valid a CSS color or the value `"none"`. * @version 2.1 */ backgroundColor: string; /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>; /** * Gets and object describing the font that shall be used in the trellis headers of the Mod Visualization. * @version 2.1 */ font: FontInfo; } /** * Extract all possible types in a Tuple type. * @public */ export declare type UnionFromTupleTypes<T extends readonly any[], U = never> = T[number] | U; /** * Represents the styling information that applies to zoom sliders in the Mod Visualization. * @public * @version 2.1 */ export declare interface ZoomSliderStylingInfo { /** * Gets the styling information to use for the inner range of a zoom slider in the Mod Visualization. * The inner range is the area between the thumbs of the zoom slider. * @version 2.1 */ innerRange: RangeStylingInfo; /** * Gets the styling information to use for the outer range of a zoom slider in the Mod Visualization. * The outer range is the area between the ends of the zoom slider, visible when the thumbs have been moved inwards. * @version 2.1 */ outerRange: RangeStylingInfo; /** * Gets the styling information to use for the thumbs of a zoom slider in the Mod Visualization. * @version 2.1 */ thumb: ThumbStylingInfo; } export { }

                Call site

                • initialize > OnLoadCallback

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a function that consumes the {@link Mod} API. See {@link initialize}.
                 * @public
                 */
                export declare type OnLoadCallback = (mod: Mod) => void | Promise<void>;

                Page

                Represents a Page in a Spotfire document.

                References

                Extends PageValues
                /** * Represents a Page in a Spotfire document. * @public */ export declare interface Page extends PageValues { /** * Sets this instance as the active page. */ setAsActive(): void; }

                Referenced by

                Returned from a method called pages in SpotfireDocument
                /** * Provides access to the {@link Page}s in the Spotfire document. */ pages(): Readable<Page[]>;
                Returned from a method called activePage in SpotfireDocument
                /** * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible. */ activePage(): ReadableProxy<Page>;
                Used as a function parameter in a method called setActivePage in SpotfireDocument
                /** * Sets the specified {@link Page} as the active page. * @param page - The {@link Page} object to set as active. */ setActivePage(page: Page): void;

                Call site

                • Mod > SpotfireDocument > Page

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a Page in a Spotfire document.
                 * @public
                 */
                export declare interface Page extends PageValues {
                    /**
                     * Sets this instance as the active page.
                     */
                    setAsActive(): void;
                }

                PageValues

                Represents the values held by a Page.

                Referenced by

                Extended by Page
                /** * Represents a Page in a Spotfire document. * @public */ export declare interface Page extends PageValues { /** * Sets this instance as the active page. */ setAsActive(): void; }

                Call site

                • Mod > SpotfireDocument > Page > PageValues

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the values held by a {@link Page}.
                 * @public
                 */
                export declare interface PageValues {
                    /**
                     * Gets the name of this instance.
                     */
                    name: string;
                    /**
                     * Gets a value indicating whether this instance is visible.
                     */
                    visible: boolean;
                    /**
                     * Gets the zero-based index in this instance in the page collection in the Spotfire document.
                     */
                    index: number;
                    /**
                     * Gets the unique id for this instance.
                     * The id is stable during the page life cycle, thus it can be used to store as a reference to this page in a {@link ModProperty} or {@link AnalysisProperty}.
                     * @version 1.1
                     */
                    id: string;
                }

                Popout

                Represents an object that can be used to create and show a Spotfire popout dialog.

                References

                PopoutOptions is used as a parameter in a method called show
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;
                PopoutSection is used as a parameter in a method called show
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;
                Returns a PopoutDialog via a method called show
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;
                PopoutSectionOptions is used as a parameter in a method called section
                /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection;
                Returns a PopoutSection via a method called section
                /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection;
                Returns a PopoutComponentFactory via a property called components
                /** * Gets an object with methods that create {@link PopoutComponent}s. */ components: PopoutComponentFactory;

                Referenced by

                Stored as a property called popout in a Controls
                /** * Gets an object that can be used to create and show a Spotfire popout dialog. */ popout: Popout;

                Call site

                • Mod > Controls > Popout

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents an object that can be used to create and show a Spotfire popout dialog.
                 * @public
                 */
                export declare interface Popout {
                    /**
                     * Shows a pop out dialog as specified by the `options` and `controls`.
                     * @param options - Specifies where and how to show the pop out dialog.
                     * @param components - A callback that shall produce the array of components that the
                     * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false`
                     * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s
                     * so that the pop out can be re-rendered to show the result of the interaction.
                     */
                    show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;
                    /**
                     * Creates a section that contains a heading and components.
                     * @param options - Specifies the heading and the components.
                     */
                    section(options: PopoutSectionOptions): PopoutSection;
                    /**
                     *  Gets an object with methods that create {@link PopoutComponent}s.
                     */
                    components: PopoutComponentFactory;
                }

                PopoutButtonOptions

                Represents options describing how to render a button. See PopoutComponentFactory.button.

                Referenced by

                Used as a function parameter in a method called button in PopoutComponentFactory
                /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent;

                Call site

                • Mod > Controls > Popout > PopoutComponentFactory > PopoutButtonOptions

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents options describing how to render a button. See {@link PopoutComponentFactory.button}.
                 * @public
                 */
                export declare interface PopoutButtonOptions {
                    /**
                     * Specifies the name that identifies the component.
                     */
                    name: string;
                    /**
                     * Specifies the text to display in the button.
                     */
                    text: string;
                }

                PopoutCheckboxOptions

                Represents options describing how to render a checkbox. See PopoutComponentFactory.checkbox.

                Referenced by

                Used as a function parameter in a method called checkbox in PopoutComponentFactory
                /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent;

                Call site

                • Mod > Controls > Popout > PopoutComponentFactory > PopoutCheckboxOptions

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents options describing how to render a checkbox. See {@link PopoutComponentFactory.checkbox}.
                 * @public
                 */
                export declare interface PopoutCheckboxOptions {
                    /**
                     * Specifies the name that identifies the component.
                     */
                    name: string;
                    /**
                     * Specifies the text to display next to the checkbox.
                     */
                    text: string;
                    /**
                     * Specifies the tooltip to display. If undefined, no tooltip is shown.
                     */
                    tooltip?: string;
                    /**
                     * Specifies whether the checkbox is checked.
                     */
                    checked: boolean;
                    /**
                     * Specifies whether the checkbox is enabled.
                     */
                    enabled: boolean;
                }

                PopoutComponent

                Represents a component of a pop out dialog. See Controls.popout.

                Referenced by

                Returned from a method called radioButton in PopoutComponentFactory
                /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent;
                Returned from a method called checkbox in PopoutComponentFactory
                /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent;
                Returned from a method called button in PopoutComponentFactory
                /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent;
                Stored as a property called children in a PopoutSection
                /** * Specifies the components in the section */ children: PopoutComponent[];
                Stored as a property called children in a PopoutSectionOptions
                /** * Specifies the components in the section */ children: PopoutComponent[];

                Call site

                • Mod > Controls > Popout > PopoutComponentFactory > PopoutComponent
                • Mod > Controls > Popout > PopoutSection > PopoutComponent
                • Mod > Controls > Popout > PopoutSectionOptions > PopoutComponent

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a component of a pop out dialog. See {@link Controls.popout}.
                 * @public
                 */
                export declare interface PopoutComponent {
                    /**
                     * Gets the type of the control.
                     */
                    type: string;
                }

                PopoutComponentEvent

                Represents the data of an event that occurs when a PopoutComponent has been changed by the user.

                Referenced by

                Used as a function parameter in a method called onChange in PopoutOptions
                /** * Specifies the callback to invoke when a component in the pop out dialog is changed. */ onChange(event: PopoutComponentEvent): void;

                Call site

                • Mod > Controls > Popout > PopoutOptions > PopoutComponentEvent

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the data of an event that occurs when a {@link PopoutComponent} has been changed by the user.
                 * @public
                 */
                export declare interface PopoutComponentEvent {
                    /**
                     * Gets the name that identifies the component that has been changed.
                     */
                    name: string;
                    /**
                     * Gets the value of the component that has been changed.
                     */
                    value?: any;
                }

                PopoutComponentFactory

                Represents an object with methods that create PopoutComponents.

                References

                PopoutRadioButtonOptions is used as a parameter in a method called radioButton
                /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent;
                Returns a PopoutComponent via a method called radioButton
                /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent;
                PopoutCheckboxOptions is used as a parameter in a method called checkbox
                /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent;
                Returns a PopoutComponent via a method called checkbox
                /** * Creates a component that renders as a checkbox. * @param options - Specifies how the checkbox shall be rendered. */ checkbox(options: PopoutCheckboxOptions): PopoutComponent;
                PopoutButtonOptions is used as a parameter in a method called button
                /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent;
                Returns a PopoutComponent via a method called button
                /** * Creates a component that renders as a button. * @param options - Specifies how the button shall be rendered. */ button(options: PopoutButtonOptions): PopoutComponent;

                Referenced by

                Stored as a property called components in a Popout
                /** * Gets an object with methods that create {@link PopoutComponent}s. */ components: PopoutComponentFactory;

                Call site

                • Mod > Controls > Popout > PopoutComponentFactory

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents an object with methods that create {@link PopoutComponent}s.
                 * @public
                 */
                export declare interface PopoutComponentFactory {
                    /**
                     * Creates a component that renders as a radio button.
                     * @param options - Specifies how the radio button shall be rendered.
                     */
                    radioButton(options: PopoutRadioButtonOptions): PopoutComponent;
                    /**
                     * Creates a component that renders as a checkbox.
                     * @param options - Specifies how the checkbox shall be rendered.
                     */
                    checkbox(options: PopoutCheckboxOptions): PopoutComponent;
                    /**
                     * Creates a component that renders as a button.
                     * @param options - Specifies how the button shall be rendered.
                     */
                    button(options: PopoutButtonOptions): PopoutComponent;
                }

                PopoutDialog

                Represents a pop out dialog that is shown by Spotfire. See Controls.popout.

                Referenced by

                Returned from a method called show in Popout
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;

                Call site

                • Mod > Controls > Popout > PopoutDialog

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a pop out dialog that is shown by Spotfire. See {@link Controls.popout}.
                 * @public
                 */
                export declare interface PopoutDialog {
                    /**
                     * Closes the pop out dialog.
                     */
                    close(): void;
                }

                PopoutOptions

                Represents options that specifies where and how a pop out dialog shall be shown.

                References

                PopoutComponentEvent is used as a parameter in a method called onChange
                /** * Specifies the callback to invoke when a component in the pop out dialog is changed. */ onChange(event: PopoutComponentEvent): void;

                Referenced by

                Used as a function parameter in a method called show in Popout
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;

                Call site

                • Mod > Controls > Popout > PopoutOptions

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents options that specifies where and how a pop out dialog shall be shown.
                 * @public
                 */
                export declare interface PopoutOptions {
                    /**
                     * Specifies the horizontal pixel coordinate of the anchor point of the pop out dialog.
                     *
                     * The coordinate is specified relative to an origin in the top left corner of the Mod viewport.
                     */
                    x: number;
                    /**
                     * Specifies the vertical pixel coordinate of the anchor point of the pop out dialog.
                     *
                     * The coordinate is specified relative to an origin in the top left corner of the Mod viewport.
                     */
                    y: number;
                    /**
                     * Specifies how to position of the popout in relation to the anchor point specified by `x` and `y`.
                     *
                     * The alignment value specifies which edge of the pop out that shall be closest to the anchor point. For example,
                     * to show the pop out below the anchor point, specify `Top`.
                     */
                    alignment?: "Left" | "Right" | "Top" | "Bottom";
                    /**
                     * Specifies whether to automatically close the popout when one of the components in it is clicked.
                     */
                    autoClose: boolean;
                    /**
                     * Specifies the callback to invoke when a component in the pop out dialog is changed.
                     */
                    onChange(event: PopoutComponentEvent): void;
                    /**
                     * Specifies the callback to invoke when the pop out dialog has been closed.
                     * This callback is optional and can be left unassigned.
                     */
                    onClosed?(): void;
                }

                PopoutRadioButtonOptions

                Represents options describing how to render a radio button. See PopoutComponentFactory.radioButton.

                Referenced by

                Used as a function parameter in a method called radioButton in PopoutComponentFactory
                /** * Creates a component that renders as a radio button. * @param options - Specifies how the radio button shall be rendered. */ radioButton(options: PopoutRadioButtonOptions): PopoutComponent;

                Call site

                • Mod > Controls > Popout > PopoutComponentFactory > PopoutRadioButtonOptions

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents options describing how to render a radio button. See {@link PopoutComponentFactory.radioButton}.
                 * @public
                 */
                export declare interface PopoutRadioButtonOptions {
                    /**
                     * Specifies the name that identifies the component.
                     */
                    name: string;
                    /**
                     * Specifies the text to display next to the radio button.
                     */
                    text: string;
                    /**
                     * Specifies the tooltip to display. If undefined, no tooltip is shown.
                     */
                    tooltip?: string;
                    /**
                     * Specifies whether the radio button is checked.
                     */
                    checked: boolean;
                    /**
                     * Specifies whether the radio button is enabled.
                     * @version 1.1
                     */
                    enabled?: boolean;
                    /**
                     * Specifies the value represented by the radio button.
                     */
                    value: any;
                }

                PopoutSection

                Represents a section of a pop out dialog. See Controls.popout.

                References

                Returns a PopoutComponent via a property called children
                /** * Specifies the components in the section */ children: PopoutComponent[];

                Referenced by

                Used as a function parameter in a method called show in Popout
                /** * Shows a pop out dialog as specified by the `options` and `controls`. * @param options - Specifies where and how to show the pop out dialog. * @param components - A callback that shall produce the array of components that the * pop out will show. If the pop out is shown with {@link PopoutOptions.autoClose} set to `false` * this callback will be invoked every time the user has interacted with one of the {@link PopoutComponent}s * so that the pop out can be re-rendered to show the result of the interaction. */ show(options: PopoutOptions, components: () => PopoutSection[]): PopoutDialog;
                Returned from a method called section in Popout
                /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection;

                Call site

                • Mod > Controls > Popout > PopoutSection

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a section of a pop out dialog. See {@link Controls.popout}.
                 * @public
                 */
                export declare interface PopoutSection {
                    /**
                     * Specifies the heading of the section
                     */
                    heading?: string;
                    /**
                     * Specifies the components in the section
                     */
                    children: PopoutComponent[];
                }

                PopoutSectionOptions

                Represents a section of a pop out dialog. See Controls.popout.

                References

                Returns a PopoutComponent via a property called children
                /** * Specifies the components in the section */ children: PopoutComponent[];

                Referenced by

                Used as a function parameter in a method called section in Popout
                /** * Creates a section that contains a heading and components. * @param options - Specifies the heading and the components. */ section(options: PopoutSectionOptions): PopoutSection;

                Call site

                • Mod > Controls > Popout > PopoutSectionOptions

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a section of a pop out dialog. See {@link Controls.popout}.
                 * @public
                 */
                export declare interface PopoutSectionOptions {
                    /**
                     * Specifies the heading of the section
                     */
                    heading?: string;
                    /**
                     * Specifies the components in the section
                     */
                    children: PopoutComponent[];
                }

                Progress

                Represents an object with methods to show and hide the Spotfire progress indicator.

                Referenced by

                Stored as a property called progress in a Controls
                /** * Gets an object with methods to show and hide the Spotfire progress indicator. */ progress: Progress;

                Call site

                • Mod > Controls > Progress

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents an object with methods to show and hide the Spotfire progress indicator.
                 * @public
                 */
                export declare interface Progress {
                    /**
                     * Shows the progress indicator.
                     */
                    show(): void;
                    /**
                     * Hides the progress indicator.
                     */
                    hide(): void;
                }

                RangeStylingInfo

                Represents the styling information that applies to a range, for instance in a zoom slider, in the Mod Visualization.

                References

                Returns a EdgeValues via a property called borderColors
                /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;

                Referenced by

                Stored as a property called innerRange in a ZoomSliderStylingInfo
                /** * Gets the styling information to use for the inner range of a zoom slider in the Mod Visualization. * The inner range is the area between the thumbs of the zoom slider. * @version 2.1 */ innerRange: RangeStylingInfo;
                Stored as a property called outerRange in a ZoomSliderStylingInfo
                /** * Gets the styling information to use for the outer range of a zoom slider in the Mod Visualization. * The outer range is the area between the ends of the zoom slider, visible when the thumbs have been moved inwards. * @version 2.1 */ outerRange: RangeStylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo > RangeStylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling information that applies to a range, for instance in a zoom slider, in the Mod Visualization.
                 * @public
                 * @version 2.1
                 */
                export declare interface RangeStylingInfo {
                    /**
                     * Gets the value to use for the `background-color` CSS property.
                     * @version 2.1
                     */
                    backgroundColor: string;
                    /**
                     * Gets the values to use for the border color CSS properties.
                     * @version 2.1
                     */
                    borderColors: EdgeValues<string>;
                }

                Readable

                Represents a value in the Mod API that can be accessed and/or modified. These values can be used when creating an instance of a Reader via the Mod.createReader method.

                Referenced by

                Returned from a method called properties in Column
                /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
                Returned from a method called property in Column
                /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;
                Returned from a method called columns in DataTable
                /** * Provides access to the columns of this instance. See {@link Column}. */ columns(): Readable<Column[]>;
                Returned from a method called properties in DataTable
                /** * Provides access to the properties of this instance. See {@link AnalysisProperty}. */ properties(): Readable<AnalysisPropertyValue[]>;
                Returned from a method called property in DataTable
                /** * Provides access to the {@link AnalysisProperty} with the specified `name`. */ property(name: string): Readable<AnalysisPropertyValue>;
                Returned from a method called windowSize in Mod
                /** * Provides read-only access to the current size of the browser window in which the Mod * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI. */ windowSize(): Readable<Size>;
                Returned from a method called data in ModVisualization
                /** * Provides access to the {@link DataView} that the Mod Visualization is to render. */ data(): DataViewProxy;
                Readable is used as part of an intersection type called ReadableProxy
                Readable<Node> & Omit<Pick<Node, MethodKeys<Node>>, OmittedReadableProxyMethods>
                Returned from a method called tables in SpotfireDocument
                /** * Provides access to the {@link DataTable}s in the Spotfire document. */ tables(): Readable<DataTable[]>;
                Returned from a method called properties in SpotfireDocument
                /** * Provides access to the `Document Properties` in the Spotfire Document. */ properties(): Readable<AnalysisProperty[]>;
                Returned from a method called pages in SpotfireDocument
                /** * Provides access to the {@link Page}s in the Spotfire document. */ pages(): Readable<Page[]>;

                Call site

                • Mod > ModVisualization > DataTable > Column > AnalysisPropertyValue
                • Mod > SpotfireDocument > DataTable > Column > AnalysisPropertyValue
                • Mod > ModVisualization > DataTable > Column
                • Mod > SpotfireDocument > DataTable > Column
                • Mod > ModVisualization > DataTable > AnalysisPropertyValue
                • Mod > SpotfireDocument > DataTable > AnalysisPropertyValue
                • Mod > Size
                • Mod > ModVisualization > DataView
                • Mod > ModVisualization > DataTable > Column > Readable
                • Mod > SpotfireDocument > DataTable > Column > Readable
                • Mod > ModProperty > Readable
                • Mod > SpotfireDocument > DataTable
                • Mod > SpotfireDocument > AnalysisProperty
                • Mod > SpotfireDocument > Page

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a value in the Mod API that can be accessed and/or modified. These values can
                 * be used when creating an instance of a {@link Reader} via the {@link Mod.createReader} method.
                 * @public
                 */
                export declare interface Readable<T = any> extends Promise<T> {
                    /**
                     * Used internally by the Mod api.
                     */
                    readableID: string;
                    /**
                     * Used internally by the Mod api.
                     */
                    __futureValue?: T;
                }

                ReadableProxy

                Represents an object that provides access to a node of the specified type. It can be used as a Readable but also acts as a proxy to the node by exposing all its methods. Nodes that represent model state in the Spotfire document can thus be modified without first waiting and materializing them in the browser. A full node will be created by using a Reader.

                References

                Readable is used as part of an intersection
                Readable<Node> & Omit<Pick<Node, MethodKeys<Node>>, OmittedReadableProxyMethods>

                Referenced by

                Returned from a method called column in DataTable
                /** * Provides access to the {@link Column} with the specified `name`. */ column(name: string): ReadableProxy<Column>;
                Returned from a method called property in Mod
                /** * Provides access to the {@link ModProperty} with the specified `name`. */ property<T extends ModPropertyDataType>(name: string): ReadableProxy<ModProperty<T>>;
                Returned from a method called mainTable in ModVisualization
                /** * Provides access to the {@link DataTable} in the Spotfire document that the Mod Visualization * uses as its main table. */ mainTable(): ReadableProxy<DataTable>;
                Returned from a method called axis in ModVisualization
                /** * Provides access to the {@link Axis} in the Mod Visualization with the specified `name`. All axes * must be declared in the mod-manifest.json. * @param name - The name of the {@link Axis}. */ axis(name: string): ReadableProxy<Axis>;
                Returned from a method called table in SpotfireDocument
                /** * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document. */ table(name: string): ReadableProxy<DataTable>;
                Returned from a method called property in SpotfireDocument
                /** * Provides access to the `Document Property` with the specified `name` in the Spotfire Document. */ property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>;
                Returned from a method called activePage in SpotfireDocument
                /** * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible. */ activePage(): ReadableProxy<Page>;

                Call site

                • Mod > ModVisualization > DataTable > Column
                • Mod > SpotfireDocument > DataTable > Column
                • Mod > ModProperty
                • Mod > ModVisualization > DataTable
                • Mod > ModVisualization > Axis
                • Mod > SpotfireDocument > DataTable
                • Mod > SpotfireDocument > AnalysisProperty
                • Mod > SpotfireDocument > Page

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents an object that provides access to a node of the specified type.
                 * It can be used as a {@link Readable} but also acts as a proxy to the node by exposing all its methods.
                 * Nodes that represent model state in the Spotfire document can thus be modified without first waiting
                 * and materializing them in the browser.
                 *
                 * A full node will be created by using a {@link Reader}.
                 * @public
                 */
                export declare type ReadableProxy<Node> = Readable<Node> & Omit<Pick<Node, MethodKeys<Node>>, OmittedReadableProxyMethods>;

                Reader

                The reader is responsible for combining multiple Readables and scheduling a callback to be invoked when one or more of the Readables have changed. Choose one of the appropriate methods; Reader.once or Reader.subscribe that suits the needs of the Mod. An instance of the reader is created by calling the Mod.createReader method.

                References

                Returns a ReaderSubscription via a method called subscribe
                /** * Subscribe to changes in the content for the specified readables when the reader was created. * @example * Subscribe to changes in the {@link DataView}. * * ``` * let reader = mod.createReader(mod.visualization.data()); * reader.subscribe((dataView) => { * console.log(await dataView.rowCount()); * }); * ``` * * @param callback - The callback function that is called every time when there is at least one new value to read. * The callback function will not be called until the previous callback function has returned. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ subscribe(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;
                Returns a ReaderSubscription via a method called once
                /** * Read the content once for the readables specified when the reader was created. * Any current subscription for this reader will be cancelled. * @example * Read content of a mod property once. * * ``` * let reader = mod.createReader(mod.property("CreatedBy")); * reader.once((createdBy) => { * console.log(await createdBy.value()); * }); * ``` * * @param callback - The callback function that is called once when there is at least one new value to read. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ once(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;

                Referenced by

                Returned from a method called createReader in Mod
                /** * Creates a {@link Reader} that can be used to access content specified by the {@link Readable} parameters. * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked * when one or more of the {@link Readable}s have changed. * @param readables - The {@link Readable}s that will be available in the reader. */ createReader<T extends ReadonlyArray<Readable>>(...readables: T): Reader<ExtractValueType<T>>;

                Call site

                • Mod > Reader

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * The reader is responsible for combining multiple {@link Readable}s and scheduling a callback to be invoked
                 * when one or more of the {@link Readable}s have changed. Choose one of the appropriate methods;
                 * {@link Reader.once} or {@link Reader.subscribe} that suits the needs of the Mod.
                 * An instance of the reader is created by calling the {@link Mod.createReader} method.
                 * @public
                 */
                export declare interface Reader<T extends ReadonlyArray<any>> {
                    /**
                     * Subscribe to changes in the content for the specified readables when the reader was created.
                     * @example
                     * Subscribe to changes in the {@link DataView}.
                     *
                     * ```
                     * let reader = mod.createReader(mod.visualization.data());
                     * reader.subscribe((dataView) => {
                     *    console.log(await dataView.rowCount());
                     * });
                     * ```
                     *
                     * @param callback - The callback function that is called every time when there is at least one new value to read.
                     * The callback function will not be called until the previous callback function has returned.
                     * @param onReadError - Optional callback function that will be called if there are errors reading the readables.
                     */
                    subscribe(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;
                    /**
                     * Read the content once for the readables specified when the reader was created.
                     * Any current subscription for this reader will be cancelled.
                     * @example
                     * Read content of a mod property once.
                     *
                     * ```
                     * let reader = mod.createReader(mod.property("CreatedBy"));
                     * reader.once((createdBy) => {
                     *    console.log(await createdBy.value());
                     * });
                     * ```
                     *
                     * @param callback - The callback function that is called once when there is at least one new value to read.
                     * @param onReadError - Optional callback function that will be called if there are errors reading the readables.
                     */
                    once(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;
                    /**
                     * Checks if any of the readables have a new value available. If this function returns true,
                     * the callback in the current subscription, or a new call to {@link Reader.once} is guaranteed
                     * to be invoked.
                     * The intended use of this method is to cancel rendering of the Mod if there are new values to any of the
                     * readables specified when the reader was created.
                     */
                    hasExpired(): Promise<boolean>;
                    /**
                     * Check whether one or more passed arguments are new since the last time the subscribe loop was called.
                     *
                     * @example
                     * Check if the data view has changed in the subscribe loop.
                     *
                     * ```
                     * let reader = mod.createReader(mod.visualization.data(), mod.windowSize());
                     * reader.subscribe((dataView, size) => {
                     *    console.log(reader.hasValueChanged(dataView));
                     * });
                     * ```
                     *
                     * @param value - Value from `subscribe` or `once` arguments.
                     * @param values - Additional values from `subscribe` or `once` arguments.
                     * @returns true if any of the values are new, otherwise false.
                     * @version 1.3
                     */
                    hasValueChanged(value: UnionFromTupleTypes<T>, ...values: UnionFromTupleTypes<T>[]): boolean;
                }

                ReaderSubscription

                Represents a Reader subscription.

                Referenced by

                Returned from a method called subscribe in Reader
                /** * Subscribe to changes in the content for the specified readables when the reader was created. * @example * Subscribe to changes in the {@link DataView}. * * ``` * let reader = mod.createReader(mod.visualization.data()); * reader.subscribe((dataView) => { * console.log(await dataView.rowCount()); * }); * ``` * * @param callback - The callback function that is called every time when there is at least one new value to read. * The callback function will not be called until the previous callback function has returned. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ subscribe(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;
                Returned from a method called once in Reader
                /** * Read the content once for the readables specified when the reader was created. * Any current subscription for this reader will be cancelled. * @example * Read content of a mod property once. * * ``` * let reader = mod.createReader(mod.property("CreatedBy")); * reader.once((createdBy) => { * console.log(await createdBy.value()); * }); * ``` * * @param callback - The callback function that is called once when there is at least one new value to read. * @param onReadError - Optional callback function that will be called if there are errors reading the readables. */ once(callback: (...values: T) => void, onReadError?: (error: string) => void): ReaderSubscription;

                Call site

                • Mod > Reader > ReaderSubscription

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a {@link Reader} subscription.
                 * @version 1.1
                 * @public
                 */
                export declare interface ReaderSubscription {
                    /**
                     * Immediately cancel the current subscription.
                     * Neither the callback or the error callback will be invoked afterwards.
                     */
                    cancel(): void;
                }

                RenderContext

                Represents contextual information needed when rendering a Mod, either in the UI or as part of an export.

                References

                Returns a StylingInfo via a property called styling
                /** * Gets information about the currently used theme. */ styling: StylingInfo;

                Referenced by

                Returned from a method called getRenderContext in Mod
                /** * Get the Mod's render context. This function should be invoked as soon as possible in the {@link initialize} callback. * * If this method is called in the {@link initialize} callback, Spotfire will wait for the Mod to finish rendering during * an export. The export will be made once the {@link RenderContext.signalRenderComplete} method has been called. * * If this method is not called in the {@link initialize} callback, Spotfire will _not_ wait for the Mod to finish rendering during * an export. Instead, the Mod will be automatically exported after one second. */ getRenderContext(): RenderContext;

                Call site

                • Mod > RenderContext

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents contextual information needed when rendering a Mod, either in the UI or as part of an export.
                 * @public
                 */
                export declare interface RenderContext {
                    /**
                     * Gets a value indicating whether the Mod is interactive.
                     *
                     * When this value is false the Mod is not interactive. This occurs during export, for instance to an image or to PDF.
                     * This property can be used to hide selected controls and to avoid animations when rendering in an export context.
                     */
                    interactive: boolean;
                    /**
                     * Gets the image pixel ratio that shall be used when rendering rasterized images and/or using a canvas element.
                     */
                    imagePixelRatio: number;
                    /**
                     * Gets a value indicating whether the Spotfire UI is in editing mode.
                     *
                     * When this value is true the Spotfire UI displays authoring UI elements, such as axis selectors.
                     * This property can be used to hide controls not meant for consumers of the analysis.
                     * @version 1.2
                     */
                    isEditing: boolean;
                    /**
                     * Gets information about the currently used theme.
                     */
                    styling: StylingInfo;
                    /**
                     * Signals that the mod is ready to be exported.
                     *
                     * If this method is not called, Spotfire will perform export (and preview generation etc.) of the Mod without knowing
                     * if it has finished rendering.
                     *
                     * The default maximum allowed time for a Mod to finish rendering is 20 seconds.
                     */
                    signalRenderComplete(): void;
                }

                ScaleStylingInfo

                Represents the styling information that applies to scales in the Mod Visualization.

                References

                Returns a FontInfo via a property called font
                /** * Gets and object describing the font that shall be used in the scales of the Mod Visualization. */ font: FontInfo;
                Returns a LineStylingInfo via a property called line
                /** * Gets and object describing the styling information for scale lines in the Mod Visualization. */ line: LineStylingInfo;
                Returns a TickStylingInfo via a property called tick
                /** * Gets and object describing the styling information for scale ticks in the Mod Visualization. */ tick: TickStylingInfo;

                Referenced by

                Stored as a property called scales in a StylingInfo
                /** * Gets an object describing the styling of the scales in the Mod Visualization. */ scales: ScaleStylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo > ScaleStylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling information that applies to scales in the Mod Visualization.
                 * @public
                 */
                export declare interface ScaleStylingInfo {
                    /**
                     * Gets and object describing the font that shall be used in the scales of the Mod Visualization.
                     */
                    font: FontInfo;
                    /**
                     * Gets and object describing the styling information for scale lines in the Mod Visualization.
                     */
                    line: LineStylingInfo;
                    /**
                     * Gets and object describing the styling information for scale ticks in the Mod Visualization.
                     */
                    tick: TickStylingInfo;
                }

                Size

                Represents the size of an area in the UI, for example the size of the browser window in which the Mod is rendered. See Mod.windowSize.

                Referenced by

                Returned from a method called windowSize in Mod
                /** * Provides read-only access to the current size of the browser window in which the Mod * is rendered. That is, the size of the iframe created for the Mod in the Spotfire UI. */ windowSize(): Readable<Size>;

                Call site

                • Mod > Size

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the size of an area in the UI, for example the size of the browser window in which the Mod
                 * is rendered. See {@link Mod.windowSize}.
                 * @public
                 */
                export declare interface Size {
                    /**
                     * Gets the width.
                     */
                    width: number;
                    /**
                     * Gets the height.
                     */
                    height: number;
                }

                SpotfireDocument

                Represents the Spotfire document and provides access to read and modify parts of it.

                References

                Returns a DataTable via a method called tables
                /** * Provides access to the {@link DataTable}s in the Spotfire document. */ tables(): Readable<DataTable[]>;
                Returns a DataTable via a method called table
                /** * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document. */ table(name: string): ReadableProxy<DataTable>;
                Returns a AnalysisProperty via a method called properties
                /** * Provides access to the `Document Properties` in the Spotfire Document. */ properties(): Readable<AnalysisProperty[]>;
                Returns a AnalysisProperty via a method called property
                /** * Provides access to the `Document Property` with the specified `name` in the Spotfire Document. */ property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>;
                Returns a Page via a method called pages
                /** * Provides access to the {@link Page}s in the Spotfire document. */ pages(): Readable<Page[]>;
                Returns a Page via a method called activePage
                /** * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible. */ activePage(): ReadableProxy<Page>;
                Page is used as a parameter in a method called setActivePage
                /** * Sets the specified {@link Page} as the active page. * @param page - The {@link Page} object to set as active. */ setActivePage(page: Page): void;

                Referenced by

                Stored as a property called document in a Mod
                /** * Gets an object that provides access to Spotfire document. */ document: SpotfireDocument;

                Call site

                • Mod > SpotfireDocument

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the Spotfire document and provides access to read and modify parts of it.
                 * @public
                 */
                export declare interface SpotfireDocument {
                    /**
                     * Provides access to the {@link DataTable}s in the Spotfire document.
                     */
                    tables(): Readable<DataTable[]>;
                    /**
                     * Provides access to the {@link DataTable} with the specified `name` in the Spotfire document.
                     */
                    table(name: string): ReadableProxy<DataTable>;
                    /**
                     * Provides access to the `Document Properties` in the Spotfire Document.
                     */
                    properties(): Readable<AnalysisProperty[]>;
                    /**
                     * Provides access to the `Document Property` with the specified `name` in the Spotfire Document.
                     */
                    property<T extends AnalysisPropertyDataType = AnalysisPropertyDataType>(name: string): ReadableProxy<AnalysisProperty<T>>;
                    /**
                     * Provides access to the {@link Page}s in the Spotfire document.
                     */
                    pages(): Readable<Page[]>;
                    /**
                     * Provides access to the active {@link Page} in the Spotfire document. That is, the page that is currently visible.
                     */
                    activePage(): ReadableProxy<Page>;
                    /**
                     * Sets the specified {@link Page} as the active page.
                     * @param name - The name/title or id of the page to set as active.
                     */
                    setActivePage(name: string): void;
                    /**
                     * Sets the specified index as the active page index.
                     * @param index - The index of the page to set as active.
                     */
                    setActivePage(index: number): void;
                    /**
                     * Sets the specified {@link Page} as the active page.
                     * @param page - The {@link Page} object to set as active.
                     */
                    setActivePage(page: Page): void;
                }

                StateDependentValue

                Represents a group of values used in different states of an associated DOM element.

                Referenced by

                Stored as a property called color in a ControlStylingInfo
                /** * Gets the values to use for the color CSS properties in different states. * @version 2.1 */ color: StateDependentValue<string>;
                Stored as a property called backgroundImage in a ThumbStylingInfo
                /** * Gets the value to use for the `background-image` CSS property. * @version 2.1 */ backgroundImage: StateDependentValue<string>;

                Call site

                • Mod > RenderContext > StylingInfo > ControlStylingInfo > StateDependentValue
                • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo > ThumbStylingInfo > StateDependentValue

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a group of values used in different states of an associated DOM element.
                 * @version 2.1
                 * @public
                 */
                export declare interface StateDependentValue<T> {
                    /**
                     * Gets the value to use in the default state. That is, when no pseudo-class is active.
                     * @version 2.1
                     */
                    default: T;
                    /**
                     * Gets the value to use in the `hover` state. If this property is undefined, the `default` value should be used.
                     * @version 2.1
                     */
                    hover?: T;
                    /**
                     * Gets the value to use in the `active` state. If this property is undefined, the `default` value should be used.
                     * @version 2.1
                     */
                    active?: T;
                    /**
                     * Gets the value to use in the `disabled` state. If this property is undefined, the `default` value should be used.
                     * @version 2.1
                     */
                    disabled?: T;
                }

                StylingInfo

                Represents the styling (theme) that affects the look and feel of a Mod Visualization.

                References

                Returns a GeneralStylingInfo via a property called general
                /** * Gets an object describing the general aspects of the styling, including the font and background color * to use in the Mod Visualization. */ general: GeneralStylingInfo;
                Returns a ScaleStylingInfo via a property called scales
                /** * Gets an object describing the styling of the scales in the Mod Visualization. */ scales: ScaleStylingInfo;
                Returns a TrellisPanelHeaderStylingInfo via a property called trellisPanelHeaders
                /** * Gets an object describing the styling of the trellis panel headers in the Mod Visualization. * @version 2.1 */ trellisPanelHeaders: TrellisPanelHeaderStylingInfo;
                Returns a ZoomSliderStylingInfo via a property called zoomSliders
                /** * Gets an object describing the styling of the zoom sliders in the Mod Visualization. * @version 2.1 */ zoomSliders: ZoomSliderStylingInfo;
                Returns a ControlStylingInfo via a property called controls
                /** * Gets an object describing the styling of controls in the Mod Visualization. * @version 2.1 */ controls: ControlStylingInfo;

                Referenced by

                Stored as a property called styling in a RenderContext
                /** * Gets information about the currently used theme. */ styling: StylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling (theme) that affects the look and feel of a Mod Visualization.
                 * @public
                 */
                export declare interface StylingInfo {
                    /**
                     * Gets an object describing the general aspects of the styling, including the font and background color
                     * to use in the Mod Visualization.
                     */
                    general: GeneralStylingInfo;
                    /**
                     * Gets an object describing the styling of the scales in the Mod Visualization.
                     */
                    scales: ScaleStylingInfo;
                    /**
                     * Gets an object describing the styling of the trellis panel headers in the Mod Visualization.
                     * @version 2.1
                     */
                    trellisPanelHeaders: TrellisPanelHeaderStylingInfo;
                    /**
                     * Gets an object describing the styling of the zoom sliders in the Mod Visualization.
                     * @version 2.1
                     */
                    zoomSliders: ZoomSliderStylingInfo;
                    /**
                     * Gets an object describing the styling of controls in the Mod Visualization.
                     * @version 2.1
                     */
                    controls: ControlStylingInfo;
                }

                ThumbStylingInfo

                Represents the styling information that applies to a thumb, for instance in a zoom slider, in the Mod Visualization.

                References

                Returns a StateDependentValue via a property called backgroundImage
                /** * Gets the value to use for the `background-image` CSS property. * @version 2.1 */ backgroundImage: StateDependentValue<string>;
                Returns a EdgeValues via a property called borderColors
                /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;

                Referenced by

                Stored as a property called thumb in a ZoomSliderStylingInfo
                /** * Gets the styling information to use for the thumbs of a zoom slider in the Mod Visualization. * @version 2.1 */ thumb: ThumbStylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo > ThumbStylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling information that applies to a thumb, for instance in a zoom slider, in the Mod Visualization.
                 * @public
                 * @version 2.1
                 */
                export declare interface ThumbStylingInfo {
                    /**
                     * Gets the value to use for the `background-image` CSS property.
                     * @version 2.1
                     */
                    backgroundImage: StateDependentValue<string>;
                    /**
                     * Gets the values to use for the border color CSS properties.
                     * @version 2.1
                     */
                    borderColors: EdgeValues<string>;
                }

                TickStylingInfo

                Represents the styling information that applies to scale ticks in the Mod Visualization.

                Referenced by

                Stored as a property called tick in a ScaleStylingInfo
                /** * Gets and object describing the styling information for scale ticks in the Mod Visualization. */ tick: TickStylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo > ScaleStylingInfo > TickStylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling information that applies to scale ticks in the Mod Visualization.
                 * @public
                 */
                export declare interface TickStylingInfo {
                    /**
                     * Gets the stroke to use for scale ticks. This value is valid a CSS color or the value `"none"`.
                     */
                    stroke: string;
                }

                Time

                Represents a Time property. The time has no notion of time zone.

                Referenced by

                Time is used as part of an intersection type called AnalysisPropertyDataType
                string | number | boolean | Date | TimeSpan | Time
                Time is used as part of an intersection type called DataViewValueType
                number | string | boolean | Date | Time | TimeSpan

                Call site

                • AnalysisPropertyDataType > Time
                • DataViewValueType > Time

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a Time property. The time has no notion of time zone.
                 * @public
                 */
                export declare interface Time {
                    /** The total number of milliseconds since midnight. */
                    totalMilliseconds: number;
                    /** The millisecond part of the instance. */
                    milliseconds: number;
                    /** The total number of seconds since midnight. */
                    totalSeconds: number;
                    /** The second part of the instance. */
                    seconds: number;
                    /** The total number of minutes since midnight. */
                    totalMinutes: number;
                    /** The minute part of the instance. */
                    minutes: number;
                    /** The total number of hours since midnight. */
                    hours: number;
                }

                TimeSpan

                Represents a TimeSpan property. A time span is used to measure the time between two points in time.

                Referenced by

                TimeSpan is used as part of an intersection type called AnalysisPropertyDataType
                string | number | boolean | Date | TimeSpan | Time
                TimeSpan is used as part of an intersection type called DataViewValueType
                number | string | boolean | Date | Time | TimeSpan

                Call site

                • AnalysisPropertyDataType > TimeSpan
                • DataViewValueType > TimeSpan

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents a TimeSpan property. A time span is used to measure the time between two points in time.
                 * @public
                 */
                export declare interface TimeSpan {
                    /** The total number of milliseconds of the instance. */
                    totalMilliseconds: number;
                    /** The millisecond part of the instance. */
                    milliseconds: number;
                    /** The total number of seconds of the instance. */
                    totalSeconds: number;
                    /** The second part of the instance. */
                    seconds: number;
                    /** The total number of minutes of the instance. */
                    totalMinutes: number;
                    /** The minute part of the instance. */
                    minutes: number;
                    /** The total number of hours of the instance. */
                    totalHours: number;
                    /** The hour part of the instance. */
                    hours: number;
                    /** The day part of the instance. */
                    days: number;
                }

                Tooltip

                Represents an object with methods to show and hide a Spotfire tooltip.

                References

                DataViewRow is used as a parameter in a method called show
                /** * Shows a tooltip for the specified `row` as it has been configured in the properties panel. * * The tooltip is shown using the same style and initial delay as native Spotfire visualizations. * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called. * * Subsequent calls to `show` can be made to update the tooltip text. * * @note For this feature to work, the dataViewDefinition.tooltip.enabled in the mod-manifest.json needs to be set to true. * * @param row - The row to show text for in the tooltip. * @version 1.3 */ show(row: DataViewRow): void;

                Referenced by

                Stored as a property called tooltip in a Controls
                /** * Gets an object with methods to show and hide a Spotfire tooltip. */ tooltip: Tooltip;

                Call site

                • Mod > Controls > Tooltip

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents an object with methods to show and hide a Spotfire tooltip.
                 * @public
                 */
                export declare interface Tooltip {
                    /**
                     * Shows a tooltip with the specified `content` text.
                     *
                     * The tooltip is shown using the same style and initial delay as native Spotfire visualizations.
                     * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called.
                     *
                     * Subsequent calls to `show` can be made to update the tooltip text.
                     * @param content - The text to show in the tooltip.
                     */
                    show(content: string): void;
                    /**
                     * Shows a tooltip for the specified `row` as it has been configured in the properties panel.
                     *
                     * The tooltip is shown using the same style and initial delay as native Spotfire visualizations.
                     * Once shown, the tooltip will follow the mouse around until {@link Tooltip.hide} is called.
                     *
                     * Subsequent calls to `show` can be made to update the tooltip text.
                     *
                     * @note For this feature to work, the dataViewDefinition.tooltip.enabled in the mod-manifest.json needs to be set to true.
                     *
                     * @param row - The row to show text for in the tooltip.
                     * @version 1.3
                     */
                    show(row: DataViewRow): void;
                    /**
                     * Hides the tooltip that is currently being showed, if any.
                     */
                    hide(): void;
                }

                TrellisPanelHeaderStylingInfo

                Represents the styling information that applies to trellis panel headers in the Mod Visualization.

                References

                Returns a EdgeValues via a property called borderColors
                /** * Gets the values to use for the border color CSS properties. * @version 2.1 */ borderColors: EdgeValues<string>;
                Returns a FontInfo via a property called font
                /** * Gets and object describing the font that shall be used in the trellis headers of the Mod Visualization. * @version 2.1 */ font: FontInfo;

                Referenced by

                Stored as a property called trellisPanelHeaders in a StylingInfo
                /** * Gets an object describing the styling of the trellis panel headers in the Mod Visualization. * @version 2.1 */ trellisPanelHeaders: TrellisPanelHeaderStylingInfo;

                Call site

                • Mod > RenderContext > StylingInfo > TrellisPanelHeaderStylingInfo

                More info can be found in theAPI documentation


                Show declarationHide declaration

                /**
                 * Represents the styling information that applies to trellis panel headers in the Mod Visualization.
                 * @public
                 * @version 2.1
                 */
                export declare interface TrellisPanelHeaderStylingInfo {
                    /**
                     * Gets the color to use for the `background-color` CSS property. This value is valid a CSS color or the value `"none"`.
                     * @version 2.1
                     */
                    backgroundColor: string;
                    /**
                     * Gets the values to use for the border color CSS properties.
                     * @version 2.1
                     */
                    borderColors: EdgeValues<string>;
                    /**
                     * Gets and object describing the font that shall be used in the trellis headers of the Mod Visualization.
                     * @version 2.1
                     */
                    font: FontInfo;
                }

                UnionFromTupleTypes

                Extract all possible types in a Tuple type.


                  More info can be found in theAPI documentation


                  Show declarationHide declaration

                  /**
                   * Extract all possible types in a Tuple type.
                   * @public
                   */
                  export declare type UnionFromTupleTypes<T extends readonly any[], U = never> = T[number] | U;

                  ZoomSliderStylingInfo

                  Represents the styling information that applies to zoom sliders in the Mod Visualization.

                  References

                  Returns a RangeStylingInfo via a property called innerRange
                  /** * Gets the styling information to use for the inner range of a zoom slider in the Mod Visualization. * The inner range is the area between the thumbs of the zoom slider. * @version 2.1 */ innerRange: RangeStylingInfo;
                  Returns a RangeStylingInfo via a property called outerRange
                  /** * Gets the styling information to use for the outer range of a zoom slider in the Mod Visualization. * The outer range is the area between the ends of the zoom slider, visible when the thumbs have been moved inwards. * @version 2.1 */ outerRange: RangeStylingInfo;
                  Returns a ThumbStylingInfo via a property called thumb
                  /** * Gets the styling information to use for the thumbs of a zoom slider in the Mod Visualization. * @version 2.1 */ thumb: ThumbStylingInfo;

                  Referenced by

                  Stored as a property called zoomSliders in a StylingInfo
                  /** * Gets an object describing the styling of the zoom sliders in the Mod Visualization. * @version 2.1 */ zoomSliders: ZoomSliderStylingInfo;

                  Call site

                  • Mod > RenderContext > StylingInfo > ZoomSliderStylingInfo

                  More info can be found in theAPI documentation


                  Show declarationHide declaration

                  /**
                   * Represents the styling information that applies to zoom sliders in the Mod Visualization.
                   * @public
                   * @version 2.1
                   */
                  export declare interface ZoomSliderStylingInfo {
                      /**
                       * Gets the styling information to use for the inner range of a zoom slider in the Mod Visualization.
                       * The inner range is the area between the thumbs of the zoom slider.
                       * @version 2.1
                       */
                      innerRange: RangeStylingInfo;
                      /**
                       * Gets the styling information to use for the outer range of a zoom slider in the Mod Visualization.
                       * The outer range is the area between the ends of the zoom slider, visible when the thumbs have been moved inwards.
                       * @version 2.1
                       */
                      outerRange: RangeStylingInfo;
                      /**
                       * Gets the styling information to use for the thumbs of a zoom slider in the Mod Visualization.
                       * @version 2.1
                       */
                      thumb: ThumbStylingInfo;
                  }