mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 16:04:50 +03:00
64ca67706f
tg://proxy links carry no #remark on purpose, so the Configs tab of the subscription page had nothing to title an MTProto row with and fell back to "Link N" on the raw, JSON and Clash pages. While the page data is built, record each MTProto link's remark and send it to the page as linkRemarks, aligned with links; the tab uses it when the link itself has no name. The link, the subscription bodies and the ?format=info JSON are unchanged. Closes #7198
73 lines
2.1 KiB
TypeScript
73 lines
2.1 KiB
TypeScript
/// <reference types="vite/client" />
|
|
|
|
interface SubPageData {
|
|
sId?: string;
|
|
enabled?: boolean;
|
|
download?: string;
|
|
upload?: string;
|
|
total?: string;
|
|
used?: string;
|
|
remained?: string;
|
|
totalByte?: string | number;
|
|
expire?: string | number;
|
|
lastOnline?: string | number;
|
|
subUrl?: string;
|
|
subJsonUrl?: string;
|
|
subClashUrl?: string;
|
|
subFormat?: 'raw' | 'json' | 'clash';
|
|
subTitle?: string;
|
|
subSupportUrl?: string;
|
|
subUpdates?: number;
|
|
links?: string[];
|
|
emails?: string[];
|
|
linkRemarks?: string[];
|
|
datepicker?: 'gregorian' | 'jalalian';
|
|
announce?: string;
|
|
downloadByte?: string | number;
|
|
uploadByte?: string | number;
|
|
usedByte?: string | number;
|
|
}
|
|
|
|
interface Window {
|
|
X_UI_BASE_PATH?: string;
|
|
X_UI_CUR_VER?: string;
|
|
X_UI_DB_TYPE?: string;
|
|
__SUB_PAGE_DATA__?: SubPageData;
|
|
}
|
|
|
|
declare module 'persian-calendar-suite' {
|
|
import type { ComponentType, ReactNode } from 'react';
|
|
|
|
type DateInput = string | number | null;
|
|
type OutputFormat = 'iso' | 'shamsi' | 'gregorian' | 'hijri' | 'timestamp';
|
|
|
|
interface PersianDateTimePickerProps {
|
|
value?: DateInput;
|
|
onChange?: (value: number | string | null) => void;
|
|
defaultValue?: string | number | 'now' | null;
|
|
showTime?: boolean;
|
|
minuteStep?: number;
|
|
outputFormat?: OutputFormat;
|
|
showFooter?: boolean;
|
|
theme?: Record<string, unknown>;
|
|
disabledHours?: number[];
|
|
minDate?: string | Date | null;
|
|
maxDate?: string | Date | null;
|
|
enabledDates?: string[] | null;
|
|
disabledDates?: string[] | null;
|
|
disabledWeekDays?: number[];
|
|
persianNumbers?: boolean;
|
|
rtlCalendar?: boolean;
|
|
placeholder?: string;
|
|
disabled?: boolean;
|
|
className?: string;
|
|
children?: ReactNode;
|
|
}
|
|
|
|
export const PersianDateTimePicker: ComponentType<PersianDateTimePickerProps>;
|
|
export const PersianCalendar: ComponentType<Record<string, unknown>>;
|
|
export const PersianDateRangePicker: ComponentType<Record<string, unknown>>;
|
|
export const PersianTimePicker: ComponentType<Record<string, unknown>>;
|
|
export const PersianTimeline: ComponentType<Record<string, unknown>>;
|
|
}
|