env.d.ts 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. /// <reference types="vite/client" />
  2. interface SubPageData {
  3. sId?: string;
  4. enabled?: boolean;
  5. download?: string;
  6. upload?: string;
  7. total?: string;
  8. used?: string;
  9. remained?: string;
  10. totalByte?: string | number;
  11. expire?: string | number;
  12. lastOnline?: string | number;
  13. subUrl?: string;
  14. subJsonUrl?: string;
  15. subClashUrl?: string;
  16. subTitle?: string;
  17. subSupportUrl?: string;
  18. subUpdates?: number;
  19. links?: string[];
  20. emails?: string[];
  21. datepicker?: 'gregorian' | 'jalalian';
  22. announce?: string;
  23. downloadByte?: string | number;
  24. uploadByte?: string | number;
  25. usedByte?: string | number;
  26. }
  27. interface Window {
  28. X_UI_BASE_PATH?: string;
  29. X_UI_CUR_VER?: string;
  30. X_UI_DB_TYPE?: string;
  31. __SUB_PAGE_DATA__?: SubPageData;
  32. }
  33. declare module 'persian-calendar-suite' {
  34. import type { ComponentType, ReactNode } from 'react';
  35. type DateInput = string | number | null;
  36. type OutputFormat = 'iso' | 'shamsi' | 'gregorian' | 'hijri' | 'timestamp';
  37. interface PersianDateTimePickerProps {
  38. value?: DateInput;
  39. onChange?: (value: number | string | null) => void;
  40. defaultValue?: string | number | 'now' | null;
  41. showTime?: boolean;
  42. minuteStep?: number;
  43. outputFormat?: OutputFormat;
  44. showFooter?: boolean;
  45. theme?: Record<string, unknown>;
  46. disabledHours?: number[];
  47. minDate?: string | Date | null;
  48. maxDate?: string | Date | null;
  49. enabledDates?: string[] | null;
  50. disabledDates?: string[] | null;
  51. disabledWeekDays?: number[];
  52. persianNumbers?: boolean;
  53. rtlCalendar?: boolean;
  54. placeholder?: string;
  55. disabled?: boolean;
  56. className?: string;
  57. children?: ReactNode;
  58. }
  59. export const PersianDateTimePicker: ComponentType<PersianDateTimePickerProps>;
  60. export const PersianCalendar: ComponentType<Record<string, unknown>>;
  61. export const PersianDateRangePicker: ComponentType<Record<string, unknown>>;
  62. export const PersianTimePicker: ComponentType<Record<string, unknown>>;
  63. export const PersianTimeline: ComponentType<Record<string, unknown>>;
  64. }