Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. import styled from 'styles'
  2. import { signin, signout, useSession } from 'next-auth/client'
  3. export default function Sponsorware() {
  4. const [session, loading] = useSession()
  5. return (
  6. <Content>
  7. <h1>tldraw is sponsorware</h1>
  8. <video src="images/hello.mp4" autoPlay muted loop />
  9. <p>
  10. Hey, thanks for visiting <a href="https://tldraw.com/">tldraw</a>, a
  11. tiny little drawing app by{' '}
  12. <a href="https://twitter.com/steveruizok">steveruizok</a>.
  13. </p>
  14. <p>
  15. {' '}
  16. This project is currently:{' '}
  17. <ul>
  18. <li>in development</li>
  19. <li>only available for my sponsors</li>
  20. </ul>
  21. </p>
  22. <p>
  23. If you'd like to try it out,{' '}
  24. <a
  25. href="https://github.com/sponsors/steveruizok"
  26. target="_blank"
  27. rel="noopener noreferrer"
  28. >
  29. sponsor me on Github
  30. </a>{' '}
  31. (at $1 or more) and sign in below.
  32. </p>
  33. <Button onClick={() => signin('github')}>Sign in With Github</Button>
  34. <button onClick={() => signout()}>Sign Out</button>
  35. <pre>{JSON.stringify(session, null, 2)}</pre>
  36. </Content>
  37. )
  38. }
  39. const Content = styled('div', {
  40. width: '720px',
  41. maxWidth: 'calc(100% - 16px)',
  42. backgroundColor: '$panel',
  43. margin: '72px auto',
  44. borderRadius: '4px',
  45. boxShadow: '0px 2px 4px rgba(0,0,0,.2)',
  46. padding: '16px',
  47. overflow: 'hidden',
  48. color: '$text',
  49. '& a': {
  50. color: '$bounds',
  51. backgroundColor: '$boundsBg',
  52. padding: '2px 4px',
  53. margin: '0 -3px',
  54. borderRadius: '2px',
  55. },
  56. '& p': {
  57. fontFamily: '$body',
  58. fontSize: '$3',
  59. lineHeight: 1.5,
  60. },
  61. '& video': {
  62. maxWidth: '100%',
  63. boxShadow: '0px 2px 4px rgba(0,0,0,.2)',
  64. borderRadius: '4px',
  65. overflow: 'hidden',
  66. margin: '16px 0',
  67. },
  68. })
  69. const Button = styled('button', {
  70. width: '100%',
  71. padding: '12px 0',
  72. display: 'flex',
  73. alignItems: 'center',
  74. justifyContent: 'center',
  75. font: '$ui',
  76. fontWeight: 'bold',
  77. fontSize: '$3',
  78. background: '$bounds',
  79. color: '$panel',
  80. border: 'none',
  81. margin: '32px 0 8px 0',
  82. })