UNPKG

@finos/legend-lego

Version:
107 lines 5.68 kB
/** * Copyright (c) 2025-present, Goldman Sachs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { type TreeData, type TreeNodeData } from '@finos/legend-art'; import { CORE_PURE_PATH } from '@finos/legend-graph'; import { ActionState, FuzzySearchAdvancedConfigState } from '@finos/legend-shared'; import { type NormalizedDocumentationEntry, ModelDocumentationEntry } from './ModelDocumentationAnalysis.js'; import type { CommandRegistrar } from '@finos/legend-application'; export declare enum ModelsDocumentationFilterTreeNodeCheckType { CHECKED = 0, UNCHECKED = 1, PARTIALLY_CHECKED = 2 } export declare abstract class ModelsDocumentationFilterTreeNodeData implements TreeNodeData { readonly id: string; readonly label: string; readonly parentNode: ModelsDocumentationFilterTreeNodeData | undefined; isOpen: boolean; childrenIds: string[]; childrenNodes: ModelsDocumentationFilterTreeNodeData[]; checkType: ModelsDocumentationFilterTreeNodeCheckType; constructor(id: string, label: string, parentNode: ModelsDocumentationFilterTreeNodeData | undefined); setIsOpen(val: boolean): void; setCheckType(val: ModelsDocumentationFilterTreeNodeCheckType): void; } export declare class ModelsDocumentationFilterTreeRootNodeData extends ModelsDocumentationFilterTreeNodeData { } export declare class ModelsDocumentationFilterTreePackageNodeData extends ModelsDocumentationFilterTreeNodeData { parentNode: ModelsDocumentationFilterTreeNodeData; packagePath: string; constructor(id: string, label: string, parentNode: ModelsDocumentationFilterTreeNodeData, packagePath: string); } export declare class ModelsDocumentationFilterTreeElementNodeData extends ModelsDocumentationFilterTreeNodeData { parentNode: ModelsDocumentationFilterTreeNodeData; elementPath: string; typePath: CORE_PURE_PATH | undefined; constructor(id: string, label: string, parentNode: ModelsDocumentationFilterTreeNodeData, elementPath: string, typePath: CORE_PURE_PATH | undefined); } export declare class ModelsDocumentationFilterTreeTypeNodeData extends ModelsDocumentationFilterTreeNodeData { parentNode: ModelsDocumentationFilterTreeNodeData; typePath: CORE_PURE_PATH; constructor(id: string, label: string, parentNode: ModelsDocumentationFilterTreeNodeData, typePath: CORE_PURE_PATH); } export declare const trickleDownUncheckNodeChildren: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const trickleUpUncheckNode: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const uncheckFilterTreeNode: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const trickleDownCheckNode: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const trickleUpCheckNode: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const checkFilterTreeNode: (node: ModelsDocumentationFilterTreeNodeData) => void; export declare const uncheckAllFilterTree: (treeData: TreeData<ModelsDocumentationFilterTreeNodeData>) => void; export declare const buildTypeFilterTreeData: () => TreeData<ModelsDocumentationFilterTreeNodeData>; export declare const buildPackageFilterTreeData: (modelDocEntries: ModelDocumentationEntry[]) => TreeData<ModelsDocumentationFilterTreeNodeData>; export declare abstract class ViewerModelsDocumentationState implements CommandRegistrar { showHumanizedForm: boolean; private searchInput?; private readonly searchEngine; readonly searchConfigurationState: FuzzySearchAdvancedConfigState; readonly searchState: ActionState; readonly elementDocs: NormalizedDocumentationEntry[]; searchText: string; searchResults: NormalizedDocumentationEntry[]; showSearchConfigurationMenu: boolean; packageFilterTreeData: TreeData<ModelsDocumentationFilterTreeNodeData>; abstract registerCommands(): void; abstract deregisterCommands(): void; constructor(elementDocs: NormalizedDocumentationEntry[]); get isFilterCustomized(): boolean; get isPackageFilterCustomized(): boolean; get filteredSearchResults(): NormalizedDocumentationEntry[]; get isTypeFilterCustomized(): boolean; resetAllFilters(): void; resetSearch(): void; search(): void; showFilterPanel: boolean; typeFilterTreeData: TreeData<ModelsDocumentationFilterTreeNodeData>; filterTypes: string[]; filterPaths: string[]; resetPackageFilterTreeData(): void; hasClassDocumentation(classPath: string): boolean; viewClassDocumentation(classPath: string): void; updatePackageFilter(): void; resetPackageFilter(): void; protected performSearch(searchText: string): NormalizedDocumentationEntry[]; setShowHumanizedForm(val: boolean): void; setSearchText(val: string): void; setShowSearchConfigurationMenu(val: boolean): void; setShowFilterPanel(val: boolean): void; resetTypeFilterTreeData(): void; updateTypeFilter(): void; resetTypeFilter(): void; setSearchInput(el: HTMLInputElement | undefined): void; focusSearchInput(): void; selectSearchInput(): void; } //# sourceMappingURL=ModelDocumentationState.d.ts.map