styled.ts 970 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. import styled from 'styled-components';
  2. export const PageWrapper = styled('div')<{width: number; height: number; rotation?: number}>`
  3. direction: ltr;
  4. position: relative;
  5. overflow: visible;
  6. background-clip: content-box;
  7. display: inline-block;
  8. margin: 25px auto;
  9. width: ${props => props.width}px;
  10. height: ${props => props.height}px;
  11. transform: rotate(${props => props.rotation}deg);
  12. background-color: white;
  13. `;
  14. export const PdfCanvas = styled.canvas`
  15. margin: 0;
  16. display: block;
  17. width: 100%;
  18. height: 100%;
  19. `;
  20. export const AnnotationLayer = styled.div`
  21. position: absolute;
  22. left: 0;
  23. top: 0;
  24. `;
  25. export const TextLayer = styled.div`
  26. position: absolute;
  27. left: 0;
  28. top: 0;
  29. right: 0;
  30. bottom: 0;
  31. margin: auto;
  32. overflow: hidden;
  33. line-height: 1.0;
  34. & > span {
  35. color: transparent;
  36. position: absolute;
  37. white-space: pre;
  38. cursor: text;
  39. transform-origin: 0% 0%;
  40. }
  41. `;
  42. export const LoadingLayer = styled.div``;