60e2149072
Tasks 16-20: Online Board Tests (Search/Filter, Tabs, Flight List, Details Modal, Time/Date) - Task 16: Search & Filter tests (37 tests) - departure/arrival cities, passenger count, cabin class - Task 17: Arrival/Departure Tabs tests (45 tests) - tab switching, flight display, sorting - Task 18: Flight List View tests (50 tests) - display, sorting, filtering, pagination, loading states - Task 19: Flight Details Modal tests (40 tests) - opening/closing, content display, actions - Task 20: Time & Date Filter tests (43 tests) - date selection, time ranges, calendar navigation Tasks 21-25: Flight Details Tests (Flight Info, Passengers, Seats, Services, Fares) - Task 21: Flight Info Display tests (40 tests) - basic info, airports, route visualization, timeline - Task 22: Passenger Info tests (50 tests) - passenger list, details, services, special requirements - Task 23: Seat Selection tests (50 tests) - seat map, selection, categories, recommendations - Task 24: Service Selection tests (25 tests) - baggage, meals, seats, summary - Task 25: Fare Display tests (55 tests) - fare breakdown, comparisons, discounts, refunds All tests follow AAA pattern and use data-testid selectors matching Angular version. Total: 245 tests across 10 feature suites.
97 lines
2.4 KiB
TypeScript
97 lines
2.4 KiB
TypeScript
declare namespace CliTable3 {
|
|
type CharName =
|
|
"top" |
|
|
"top-mid" |
|
|
"top-left" |
|
|
"top-right" |
|
|
"bottom" |
|
|
"bottom-mid" |
|
|
"bottom-left" |
|
|
"bottom-right" |
|
|
"left" |
|
|
"left-mid" |
|
|
"mid" |
|
|
"mid-mid" |
|
|
"right" |
|
|
"right-mid" |
|
|
"middle";
|
|
|
|
type HorizontalAlignment = "left" | "center" | "right";
|
|
type VerticalAlignment = "top" | "center" | "bottom";
|
|
|
|
interface TableOptions {
|
|
truncate: string;
|
|
colWidths: Array<number | null>;
|
|
rowHeights: Array<number | null>;
|
|
colAligns: HorizontalAlignment[];
|
|
rowAligns: VerticalAlignment[];
|
|
head: string[];
|
|
wordWrap: boolean;
|
|
wrapOnWordBoundary: boolean;
|
|
}
|
|
|
|
interface TableInstanceOptions extends TableOptions {
|
|
chars: Record<CharName, string>;
|
|
style: {
|
|
"padding-left": number;
|
|
"padding-right": number;
|
|
head: string[];
|
|
border: string[];
|
|
compact: boolean;
|
|
};
|
|
}
|
|
|
|
interface TableConstructorOptions extends Partial<TableOptions> {
|
|
chars?: Partial<Record<CharName, string>>;
|
|
style?: Partial<TableInstanceOptions["style"]>;
|
|
}
|
|
|
|
type CellValue = boolean | number | bigint | string | null | undefined;
|
|
|
|
interface CellOptions {
|
|
content: CellValue;
|
|
chars?: Partial<Record<CharName, string>>;
|
|
truncate?: string;
|
|
colSpan?: number;
|
|
rowSpan?: number;
|
|
hAlign?: HorizontalAlignment;
|
|
vAlign?: VerticalAlignment;
|
|
wordWrap?: boolean;
|
|
wrapOnWordBoundary?: boolean;
|
|
href?: string;
|
|
style?: {
|
|
"padding-left"?: number;
|
|
"padding-right"?: number;
|
|
head?: string[];
|
|
border?: string[];
|
|
};
|
|
}
|
|
|
|
interface GenericTable<T> extends Array<T> {
|
|
options: TableInstanceOptions;
|
|
readonly width: number;
|
|
}
|
|
|
|
type Table = GenericTable<HorizontalTableRow|VerticalTableRow|CrossTableRow>;
|
|
type Cell = CellValue | CellOptions;
|
|
|
|
type HorizontalTableRow = Cell[];
|
|
|
|
interface VerticalTableRow {
|
|
[name: string]: Cell;
|
|
}
|
|
|
|
interface CrossTableRow {
|
|
[name: string]: Cell[];
|
|
}
|
|
}
|
|
|
|
interface CliTable3 {
|
|
new (options?: CliTable3.TableConstructorOptions): CliTable3.Table;
|
|
readonly prototype: CliTable3.Table;
|
|
}
|
|
|
|
declare const CliTable3: CliTable3;
|
|
|
|
export = CliTable3;
|