UNPKG

@quasarbright/projection

Version:

A static site generator that creates a beautiful, interactive gallery to showcase your coding projects. Features search, filtering, tags, responsive design, and an admin UI.

67 lines 2.15 kB
import { Project, ProjectsData } from '../types/project'; import { Config } from '../types/config'; /** * Options for configuring HTMLBuilder behavior */ export interface HTMLBuilderOptions { adminMode?: boolean; } /** * HTMLBuilder class handles the generation of HTML content for the portfolio site */ export declare class HTMLBuilder { private config; private adminMode; constructor(config: Config, options?: HTMLBuilderOptions); /** * Generates admin control buttons for a project card * Only included when adminMode is true */ private generateAdminControls; /** * Generates the create new project button for header * Disabled - create button is in admin UI, not preview */ private generateCreateButton; /** * Generates admin-specific CSS styles * Only included when adminMode is true */ private generateAdminStyles; /** * Generates postMessage communication JavaScript * Only included when adminMode is true */ private generateAdminScript; /** * Formats a date string into a human-readable format */ private formatDate; /** * Resolves a thumbnail path based on the base URL * Handles absolute URLs, relative paths, domain-absolute paths, and admin:// prefix */ resolveThumbnailPath(thumbnailLink: string | undefined, baseUrl: string): string; /** * Resolves a page link based on the base URL * Handles absolute URLs, relative paths, and domain-absolute paths */ resolvePageLink(pageLink: string, baseUrl: string): string; /** * Generates HTML for a single project card */ generateProjectCard(project: Project): string; /** * Generates HTML for the tag filter section */ generateTagFilter(allTags: string[]): string; /** * Generates HTML for the project modal (currently not used in output) */ generateModal(projects: Project[]): string; /** * Generates the complete HTML document for the portfolio site */ generateHTML(projectsData: ProjectsData): string; } //# sourceMappingURL=html-builder.d.ts.map