You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

114 line
2.8 KiB

  1. <html>
  2. <head>
  3. <meta charset="utf-8">
  4. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  5. <meta name="viewport" content="width=device-width,initial-scale=1.0">
  6. <link rel="icon" href="favicon.ico">
  7. <link rel="stylesheet" href="/static/normalize.css">
  8. <title>IF Game</title>
  9. <!-- currently 1.1.0 -->
  10. <script src="/static/htmx.min.js"></script>
  11. <script scr="/static/alpine.2.8.2.min.js"></script>
  12. <style>
  13. #app {
  14. background-color: gray;
  15. height: 100vh;
  16. display: flex;
  17. flex-direction: column;
  18. font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  19. }
  20. #header {
  21. background-color: black;
  22. color: white;
  23. position: sticky;
  24. display: flex;
  25. flex-direction: row;
  26. padding: 0.7em;
  27. }
  28. #headerContent {
  29. margin: auto auto;
  30. }
  31. #narrativeContainerWrapper {
  32. overflow: auto;
  33. display: flex;
  34. flex-direction:column-reverse;
  35. background-color: white;
  36. width: 80ch;
  37. max-width: 80ch;
  38. height: calc(90% - 4em);
  39. /*max-height: calc(90% - 2em);*/
  40. margin: 0 auto;
  41. margin-top: 1em;
  42. scrollbar-width: none;
  43. }
  44. #narrativeContainerWrapper:hover {
  45. scrollbar-width: unset;
  46. }
  47. .narrativeItem {
  48. padding: 1em;
  49. }
  50. #playerEntry {
  51. background-color: white;
  52. width: 80ch;
  53. margin: auto auto;
  54. font-size: 1.2em;
  55. display: flex;
  56. align-items: center;
  57. padding: 0 1em;
  58. }
  59. #playerEntry input {
  60. border: 0;
  61. outline: none;
  62. width: 100%;
  63. padding: 1rem;
  64. font-weight: bold
  65. }
  66. </style>
  67. <link rel="stylesheet" href="/static/custom.css">
  68. </head>
  69. <body>
  70. <div id="app">
  71. <div id="header">
  72. <div id="headerContent">
  73. I'm a header!
  74. </div>
  75. </div>
  76. <div id="narrativeContainerWrapper">
  77. <div id="narrativeContainer">
  78. <script>
  79. var x = 0;
  80. setInterval(function () {
  81. document.getElementById('lastNarrativeItem').insertAdjacentHTML('beforebegin', `<div style="height:100px" class="narrativeItem">Bogus content ${x}!</div>`)
  82. x++;
  83. }, 1000);
  84. </script>
  85. <div id="lastNarrativeItem">
  86. </div>
  87. </div>
  88. </div>
  89. <div id="playerEntry">
  90. > <input type="text" spellcheck="false">
  91. </div>
  92. </div>
  93. </body>
  94. </html>