feat: implement Figlet, Pastel, and Unit tools with a unified layout
- Add Figlet text converter with font selection and history - Add Pastel color palette generator and manipulation suite - Add comprehensive Units converter with category-based logic - Introduce AppShell with Sidebar and Header for navigation - Modernize theme system with CSS variables and new animations - Update project configuration and dependencies
This commit is contained in:
27
types/figlet.ts
Normal file
27
types/figlet.ts
Normal file
@@ -0,0 +1,27 @@
|
||||
export interface FigletFont {
|
||||
name: string;
|
||||
fileName: string;
|
||||
path: string;
|
||||
}
|
||||
|
||||
export interface FigletOptions {
|
||||
font?: string;
|
||||
horizontalLayout?: 'default' | 'fitted' | 'full' | 'controlled smushing' | 'universal smushing';
|
||||
verticalLayout?: 'default' | 'fitted' | 'full' | 'controlled smushing' | 'universal smushing';
|
||||
width?: number;
|
||||
whitespaceBreak?: boolean;
|
||||
}
|
||||
|
||||
export interface ConversionResult {
|
||||
text: string;
|
||||
font: string;
|
||||
result: string;
|
||||
timestamp: number;
|
||||
}
|
||||
|
||||
export interface UserPreferences {
|
||||
theme: 'light' | 'dark' | 'system';
|
||||
defaultFont: string;
|
||||
recentFonts: string[];
|
||||
favorites: string[];
|
||||
}
|
||||
30
types/units/convert-units.d.ts
vendored
Normal file
30
types/units/convert-units.d.ts
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
declare module 'convert-units' {
|
||||
export interface Unit {
|
||||
abbr: string;
|
||||
measure: string;
|
||||
system: string;
|
||||
singular: string;
|
||||
plural: string;
|
||||
}
|
||||
|
||||
export interface Converter {
|
||||
from(unit: string): {
|
||||
to(toUnit: string): number;
|
||||
toBest(options?: { exclude?: string[]; cutOffNumber?: number }): {
|
||||
val: number;
|
||||
unit: string;
|
||||
singular: string;
|
||||
plural: string;
|
||||
};
|
||||
getUnit(): Unit;
|
||||
possibilities(): string[];
|
||||
};
|
||||
measures(): string[];
|
||||
possibilities(measure?: string): string[];
|
||||
describe(unit: string): Unit;
|
||||
}
|
||||
|
||||
function convert(value?: number): Converter;
|
||||
|
||||
export default convert;
|
||||
}
|
||||
Reference in New Issue
Block a user