@manuth/generator-wsc-package
Version:
A Generator for WoltLab Suite Core Packages.
51 lines (50 loc) • 2.04 kB
TypeScript
/// <reference types="yeoman-generator" />
import { GeneratorOptions, IFileMapping, Question } from "@manuth/extended-yo-generator";
import { IFileUploadComponentOptions } from "../Settings/IFileUploadComponentOptions.js";
import { IWoltLabSettings } from "../Settings/IWoltLabSettings.js";
import { WoltLabGenerator } from "../WoltLabGenerator.js";
import { IApplicationQuestion } from "./Inquiry/Prompts/IApplicationQuestion.js";
import { LocalInstructionComponent } from "./LocalInstructionComponent.js";
/**
* Provides a component for file-uploads.
*
* @template TSettings
* The type of the settings of the generator.
*
* @template TOptions
* The type of the options of the generator.
*
* @template TComponentOptions
* The type of the options of the component.
*/
export declare abstract class FileUploadComponentBase<TSettings extends IWoltLabSettings, TOptions extends GeneratorOptions, TComponentOptions extends IFileUploadComponentOptions> extends LocalInstructionComponent<TSettings, TOptions, TComponentOptions> {
/**
* Initializes a new instance of the {@link FileUploadComponentBase `FileUploadComponentBase<TSettings, TOptions, TComponentOptions>`} class.
*
* @param generator
* The generator of the component.
*/
constructor(generator: WoltLabGenerator<TSettings, TOptions>);
/**
* Gets the question for asking for the application.
*/
protected get AppQuestion(): IApplicationQuestion<TComponentOptions>;
/**
* @inheritdoc
*/
protected get ComponentOptionQuestionCollection(): Array<Question<TComponentOptions>>;
/**
* @inheritdoc
*/
protected get InstructionFileMapping(): IFileMapping<TSettings, TOptions>;
/**
* @inheritdoc
*
* @param options
* The options of the component.
*
* @returns
* The default full name of the path to suggest in the {@link LocalInstructionComponent.SourceQuestion `SourceQuestion`}.
*/
protected GetDefaultSource(options: TComponentOptions): string;
}