@jirkasa/code-box
Version:
Showcase code samples on the web with a container that lets users select and display different samples.
21 lines (20 loc) • 1.36 kB
TypeScript
import ProjectCodeBoxOptions from "../code-box/project-code-box/ProjectCodeBoxOptions";
import ProjectCodeBox from "../code-box/project-code-box/ProjectCodeBox";
import CodeBoxCreator, { AdditionalCodeBoxInfo } from "./CodeBoxCreator";
/** Manages the creation of project code boxes. */
declare class ProjectCodeBoxCreator extends CodeBoxCreator<ProjectCodeBox, ProjectCodeBoxOptions> {
/** Stores created code boxes by id (code boxes with no id are not stored). */
private createdCodeBoxesById;
/** Stores elements for which creation of code boxes were postponed for call of getAdditionallyCreatedCodeBoxes method. */
private postponedCodeBoxElements;
/**
* Creates new project code box creator.
* @param defaultCodeBoxOptions Default code box options to be used, when no options are provided to the create method.
*/
constructor(defaultCodeBoxOptions?: ProjectCodeBoxOptions);
getCreatedCodeBoxById(id: string): ProjectCodeBox | null;
protected createCodeBox(element: HTMLElement, codeBoxOptions: ProjectCodeBoxOptions): ProjectCodeBox | null;
protected getAdditionallyCreatedCodeBoxes(codeBoxOptions: ProjectCodeBoxOptions): AdditionalCodeBoxInfo<ProjectCodeBox>[];
protected createCodeBoxOptionsCopy(codeBoxOptions: ProjectCodeBoxOptions): ProjectCodeBoxOptions;
}
export default ProjectCodeBoxCreator;