styled.ts 1017 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  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. &:first-of-type {
  14. margin-top: 40px;
  15. }
  16. `;
  17. export const PdfCanvas = styled.canvas`
  18. margin: 0;
  19. display: block;
  20. width: 100%;
  21. height: 100%;
  22. `;
  23. export const AnnotationLayer = styled.div`
  24. position: absolute;
  25. left: 0;
  26. top: 0;
  27. `;
  28. export const TextLayer = styled.div`
  29. position: absolute;
  30. left: 0;
  31. top: 0;
  32. right: 0;
  33. bottom: 0;
  34. margin: auto;
  35. overflow: hidden;
  36. line-height: 1.0;
  37. & > span {
  38. color: transparent;
  39. position: absolute;
  40. white-space: pre;
  41. cursor: text;
  42. transform-origin: 0% 0%;
  43. }
  44. `;
  45. export const LoadingLayer = styled.div``;