env.d.ts 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  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. links?: string[];
  18. emails?: string[];
  19. datepicker?: 'gregorian' | 'jalalian';
  20. announce?: string;
  21. downloadByte?: string | number;
  22. uploadByte?: string | number;
  23. usedByte?: string | number;
  24. }
  25. interface Window {
  26. X_UI_BASE_PATH?: string;
  27. X_UI_CUR_VER?: string;
  28. X_UI_DB_TYPE?: string;
  29. __SUB_PAGE_DATA__?: SubPageData;
  30. }
  31. declare module 'persian-calendar-suite' {
  32. import type { ComponentType, ReactNode } from 'react';
  33. type DateInput = string | number | null;
  34. type OutputFormat = 'iso' | 'shamsi' | 'gregorian' | 'hijri' | 'timestamp';
  35. interface PersianDateTimePickerProps {
  36. value?: DateInput;
  37. onChange?: (value: number | string | null) => void;
  38. defaultValue?: string | number | 'now' | null;
  39. showTime?: boolean;
  40. minuteStep?: number;
  41. outputFormat?: OutputFormat;
  42. showFooter?: boolean;
  43. theme?: Record<string, unknown>;
  44. disabledHours?: number[];
  45. minDate?: string | Date | null;
  46. maxDate?: string | Date | null;
  47. enabledDates?: string[] | null;
  48. disabledDates?: string[] | null;
  49. disabledWeekDays?: number[];
  50. persianNumbers?: boolean;
  51. rtlCalendar?: boolean;
  52. placeholder?: string;
  53. disabled?: boolean;
  54. className?: string;
  55. children?: ReactNode;
  56. }
  57. export const PersianDateTimePicker: ComponentType<PersianDateTimePickerProps>;
  58. export const PersianCalendar: ComponentType<Record<string, unknown>>;
  59. export const PersianDateRangePicker: ComponentType<Record<string, unknown>>;
  60. export const PersianTimePicker: ComponentType<Record<string, unknown>>;
  61. export const PersianTimeline: ComponentType<Record<string, unknown>>;
  62. }