hosanna-ui-docs - v0.9.0
    Preparing search index...
    interface IStyleRegistry {
        addStyle(key: string, style: IStyle, merge?: boolean): void;
        configure(): void;
        getStyle<T = IStyle>(
            key: string,
            isNested?: boolean,
            seenStyles?: Record<string, boolean>,
        ): T;
        getTranslation(key: string): string;
        resetCachedStyles(): void;
        resolveRowStyleForRow(row: ICollectionViewDataSourceRow): IOperationResult;
        setLanguage(languageCode: string, sectionKey?: string): void;
        setStyleJson(json: { [key: string]: IStyle }): void;
    }

    Implemented by

    Index

    Methods

    • Adds a single style to the registry, with an option to merge with existing styles.

      Parameters

      • key: string

        The unique identifier for the style.

      • style: IStyle

        The style data to be added.

      • Optionalmerge: boolean

        If true, merges with an existing style.

      Returns void

    • Retrieves a style by its key, resolving nested references as needed.

      Type Parameters

      Parameters

      • key: string

        The key for the style to retrieve.

      • OptionalisNested: boolean

        Indicates if the style is nested.

      • OptionalseenStyles: Record<string, boolean>

        A record of seen styles to prevent circular references.

      Returns T

      The resolved style.