import type { CmsModelField, CmsModelLayoutCell, FieldRule } from "../../../types/index.js"; export interface DataFieldBuildResult { type: "data"; field: CmsModelField; } export interface LayoutFieldBuildResult { type: "layout"; layoutCell: CmsModelLayoutCell; fields?: CmsModelField[]; } export type FieldBuildResult = DataFieldBuildResult | LayoutFieldBuildResult; export interface BaseFieldBuilderConfig { label: string; help?: string | null; description?: string | null; note?: string | null; _fieldId?: string; rules?: FieldRule[]; } /** * Minimal shared base class for all field builders (data and layout). */ export declare abstract class BaseFieldBuilder { readonly type: TType; private _fieldSubType?; protected config: BaseFieldBuilderConfig; get subType(): string | undefined; constructor(type: TType, label?: string); label(text: string): this; help(text: string): this; description(text: string): this; note(text: string): this; fieldId(id: string): this; rules(rules: FieldRule[]): this; protected setSubType(subType: string): this; /** * Build the final field result. * @internal */ abstract build(): FieldBuildResult; }