index.d.ts 582 B

12345678910111213141516171819202122
  1. type Styles = ViewportStyles | ((s: ViewportStyles | undefined) => ViewportStyles) | null;
  2. interface Viewport {
  3. name: string;
  4. styles: Styles;
  5. type: 'desktop' | 'mobile' | 'tablet' | 'other';
  6. }
  7. interface ViewportStyles {
  8. height: string;
  9. width: string;
  10. }
  11. interface ViewportMap {
  12. [key: string]: Viewport;
  13. }
  14. interface ViewportAddonParameter {
  15. disable?: boolean;
  16. defaultOrientation?: 'portrait' | 'landscape';
  17. defaultViewport?: string;
  18. viewports?: ViewportMap;
  19. }
  20. export { Styles, Viewport, ViewportAddonParameter, ViewportMap, ViewportStyles };