Trading card city builder game?

clean out the default junk and put in my old menu

eldridge.cam db32f17d 3cf5a51a

Waiting for spindle ...
+111 -201
+1 -3
Justfile
··· 20 20 21 21 [group: "run"] 22 22 dev: up 23 - npx concurrently --names "app,migrate" \ 24 - "dx run" \ 25 - "npx graphile-migrate watch" 23 + dx serve --hot-patch 26 24 27 25 [group: "dev"] 28 26 init:
assets/favicon.ico

This is a binary file and will not be displayed.

-20
assets/header.svg
··· 1 - <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 1007 197"><style> 2 - @keyframes a0_t { 0% { transform: translate(225px,339.9px) scale(0,1) translate(-89.5px,-24px); } 35% { transform: translate(225px,339.9px) scale(0,1) translate(-89.5px,-24px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 45% { transform: translate(225px,339.9px) scale(1,1) translate(-89.5px,-24px); } 50% { transform: translate(225px,339.9px) scale(1,1) translate(-89.5px,-24px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { transform: translate(225px,339.9px) scale(0,1) translate(-89.5px,-24px); } 100% { transform: translate(225px,339.9px) scale(0,1) translate(-89.5px,-24px); } } 3 - @keyframes a1_t { 0% { transform: translate(225px,348.9px) scale(0,1) translate(-41.5px,-11px); } 20% { transform: translate(225px,348.9px) scale(0,1) translate(-41.5px,-11px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { transform: translate(225px,348.9px) scale(1,1) translate(-41.5px,-11px); } 35% { transform: translate(225px,348.9px) scale(1,1) translate(-41.5px,-11px); } 45% { transform: translate(225px,348.9px) scale(0,1) translate(-41.5px,-11px); } 100% { transform: translate(225px,348.9px) scale(0,1) translate(-41.5px,-11px); } } 4 - @keyframes a3_t { 0% { transform: translate(225px,198.9px) rotate(-90deg); } 10% { transform: translate(225px,198.9px) rotate(-90deg); } 20% { transform: translate(225px,198.9px) rotate(-90deg); animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { transform: translate(225px,198.9px) rotate(0deg); } 35% { transform: translate(225px,198.9px) rotate(0deg); } 45% { transform: translate(225px,198.9px) rotate(0deg); } 50% { transform: translate(225px,198.9px) rotate(0deg); animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { transform: translate(225px,198.9px) rotate(-90deg); } 65% { transform: translate(225px,198.9px) rotate(-90deg); } 75% { transform: translate(225px,198.9px) rotate(-90deg); } 100% { transform: translate(225px,198.9px) rotate(-90deg); } } 5 - @keyframes a2_t { 0% { transform: translate(-200px,-167px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { transform: translate(-150px,-80px); } 20% { transform: translate(-150px,-80px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { transform: translate(-200px,-123px); } 35% { transform: translate(-200px,-123px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 45% { transform: translate(-150px,-100px); } 50% { transform: translate(-150px,-100px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { transform: translate(-150px,-80px); } 65% { transform: translate(-150px,-80px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { transform: translate(-217px,-200px); } 100% { transform: translate(-217px,-200px); } } 6 - @keyframes a2_o { 0% { opacity: 0; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { opacity: 1; } 65% { opacity: 1; animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { opacity: 0; } 100% { opacity: 0; } } 7 - @keyframes a2_sw { 0% { stroke-width: 30px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { stroke-width: 8px; } 65% { stroke-width: 8px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { stroke-width: 30px; } 100% { stroke-width: 30px; } } 8 - @keyframes a2_w { 0% { width: 400px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { width: 300px; } 20% { width: 300px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { width: 400px; } 35% { width: 400px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 45% { width: 300px; } 50% { width: 300px; } 60% { width: 300px; } 65% { width: 300px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { width: 434px; } 100% { width: 434px; } } 9 - @keyframes a2_h { 0% { height: 334px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { height: 160px; } 20% { height: 160px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { height: 246px; } 35% { height: 246px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 45% { height: 200px; } 50% { height: 200px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { height: 160px; } 65% { height: 160px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { height: 400px; } 100% { height: 400px; } } 10 - @keyframes a4_t { 0% { transform: translate(143.5px,48.9px); } 10% { transform: translate(180.5px,98.9px); } 100% { transform: translate(180.5px,98.9px); } } 11 - @keyframes a4_w { 0% { width: 168.5px; } 10% { width: 94.5px; } 100% { width: 94.5px; } } 12 - @keyframes a4_h { 0% { height: 302px; } 10% { height: 202px; } 100% { height: 202px; } } 13 - @keyframes a5_t { 0% { transform: translate(217px,324.9px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { transform: translate(190px,324.9px); } 20% { transform: translate(190px,324.9px); } 30% { transform: translate(190px,324.9px); } 100% { transform: translate(190px,324.9px); } } 14 - @keyframes a5_o { 0% { opacity: 0; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { opacity: 1; } 20% { opacity: 1; } 30% { opacity: 0; } 100% { opacity: 0; } } 15 - @keyframes a5_w { 0% { width: 16px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { width: 70px; } 20% { width: 70px; } 30% { width: 70px; } 100% { width: 70px; } } 16 - @keyframes a6_t { 0% { transform: translate(217px,324.9px); } 50% { transform: translate(217px,324.9px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { transform: translate(190px,324.9px); } 65% { transform: translate(190px,324.9px); } 75% { transform: translate(190px,324.9px); } 100% { transform: translate(190px,324.9px); } } 17 - @keyframes a6_o { 0% { opacity: 0; } 50% { opacity: 0; animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { opacity: 1; } 65% { opacity: 1; animation-timing-function: cubic-bezier(.6,0,.4,1); } 75% { opacity: 0; } 100% { opacity: 0; } } 18 - @keyframes a6_w { 0% { width: 16px; } 50% { width: 16px; animation-timing-function: cubic-bezier(.6,0,.4,1); } 60% { width: 70px; } 65% { width: 70px; } 75% { width: 70px; } 100% { width: 70px; } } 19 - @keyframes a7_t { 0% { transform: translate(225px,198.9px) scale(1.5,1.5) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 10% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); } 20% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 25% { transform: translate(225px,198.9px) scale(.8,.8) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.6,0,.4,1); } 30% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); } 35% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.4,0,.6,1); } 45% { transform: translate(225px,198.9px) scale(.8,.8) translate(-42.3px,-93px); } 50% { transform: translate(225px,198.9px) scale(.8,.8) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.4,0,.6,1); } 55% { transform: translate(225px,198.9px) scale(.7,.7) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.4,0,.6,1); } 60% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); } 65% { transform: translate(225px,198.9px) scale(1,1) translate(-42.3px,-93px); animation-timing-function: cubic-bezier(.4,0,.6,1); } 75% { transform: translate(225px,198.9px) scale(1.5,1.5) translate(-42.3px,-93px); } 100% { transform: translate(225px,198.9px) scale(1.5,1.5) translate(-42.3px,-93px); } } 20 - </style><defs><symbol id="Symbol-2" preserveAspectRatio="none" width="111.5" height="186" viewBox="0 0 111.5 186" overflow="visible"><g transform="translate(8.5,4.5)"><rect x="4" width="85" height="8" fill="#d9d9d9"/><rect x="4" y="26" width="85" height="8" fill="#d9d9d9"/><rect x="25" y="56" width="43" height="8" fill="#d9d9d9"/><rect width="85" height="8" fill="#d9d9d9" transform="translate(46.5,175) rotate(180) scale(-1,1) translate(-42.5,-4)"/><rect width="85" height="8" fill="#d9d9d9" transform="translate(46.5,149) rotate(180) scale(-1,1) translate(-42.5,-4)"/><rect width="43" height="8" fill="#d9d9d9" transform="translate(46.5,119) rotate(180) scale(-1,1) translate(-21.5,-4)"/><path d="M0 4c0 53 94.5 115 94.5 169" stroke="#3cc4dc" stroke-width="17" stroke-linecap="square" fill="none"/><path d="M94.5 4c0 53-94.5 115-94.5 169" stroke="#fb422d" stroke-width="17" stroke-linecap="square" fill="none"/></g></symbol><symbol id="Symbol-5" preserveAspectRatio="none" width="84.5" height="186" viewBox="0 0 84.5 186" overflow="visible"><g transform="translate(42.3,93) scale(5.352,6.9) translate(-16,60)"><g transform="translate(-34.9,-125.8)"><g transform="translate(24,5)"><path d="M33 46.5c0 3.1-0.8 5.5-2.2 7.4c-1.4 1.9-3.3 3.6-5.4 5.4c-2.2 1.7-4.5 3.6-6.3 6.2c-1.8 2.5-3.1 5.5-3.1 9.5h4.7c0-3.1 .9-5.4 2.2-7.3c1.4-1.9 3.3-3.5 5.5-5.3c2.1-1.8 4.4-3.7 6.2-6.2c1.8-2.6 3.1-5.6 3.1-9.7Z" fill="#e96020"/><path d="M20.4 70.7c-0.6 0-1 .5-1 1.1c0 .7 .4 1.2 1 1.2h12.9c.7 0 1.2-0.5 1.2-1.2c0-0.6-0.5-1.1-1.2-1.1Z" fill="#2d323b"/><path d="M21.8 66.6c-0.7 0-1 .6-1 1.2c0 .6 .3 1 .9 1h10.3c.6 0 1.1-0.5 1.1-1.1c0-0.6-0.5-1.1-1.1-1.1Z" fill="#2d323b"/><path d="M21.8 53c-0.7 0-1.2 .5-1.1 1.1c0 .6 .4 1.1 1.1 1.1h10.2c.6 0 .9-0.6 .9-1.2c0-0.6-0.3-1-0.9-1Z" fill="#2d323b"/><path d="M20.4 48.8c-0.6 0-1.2 .5-1.2 1.1c0 .7 .6 1.2 1.2 1.2h12.9c.7 0 1-0.5 1-1.1c0-0.7-0.3-1.2-1-1.2Z" fill="#2d323b"/><path d="M16 46.5c0 4.1 1.3 7.1 3.1 9.7c1.8 2.5 4.1 4.4 6.3 6.2c2.1 1.8 4 3.6 5.4 5.5c1.4 1.9 2.2 4 2.2 7.1h4.7c0-4-1.3-7.1-3.1-9.6c-1.8-2.5-4.1-4.4-6.2-6.2c-2.2-1.8-4.1-3.4-5.5-5.3c-1.3-1.9-2.2-4.3-2.2-7.4Z" fill="#00a8d6"/></g></g></g></symbol></defs><rect width="1007" height="197" stroke="#0f1116" fill="#0f1116" stroke-width="0"/><path fill="#fff" d="M83.3 106.1v-65.7h17c4.2 0 7.9 .8 11 2.4c3.1 1.6 5.5 3.9 7.2 6.9c1.7 2.9 2.6 6.4 2.6 10.4v26.2c0 4-0.9 7.5-2.6 10.5c-1.7 3-4.1 5.3-7.2 6.9c-3.1 1.6-6.8 2.4-11 2.4Zm8.1-7.2h8.9c4 0 7.1-1.1 9.3-3.3c2.3-2.3 3.4-5.3 3.4-9.3v-26.2c0-3.9-1.1-7-3.4-9.2c-2.2-2.2-5.3-3.3-9.3-3.3h-8.9Zm45.3 7.2v-7.4h17.5v-34.7h-15.7v-7.4h23.8v42.1h16.7v7.4Zm20.7-58.4c-2 0-3.6-0.5-4.7-1.5c-1.2-1.1-1.7-2.4-1.7-4.2c0-1.8 .5-3.2 1.7-4.3c1.1-1 2.7-1.5 4.7-1.5c1.9 0 3.5 .5 4.6 1.5c1.2 1.1 1.7 2.5 1.7 4.3c0 1.8-0.5 3.1-1.7 4.2c-1.1 1-2.7 1.5-4.6 1.5Zm52.6 59.1c-6 0-10.7-1.7-14.2-5.1c-3.4-3.4-5.1-8-5.1-13.8v-13.1c0-5.9 1.7-10.5 5.1-13.9c3.5-3.3 8.2-5 14.2-5c6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.4-2.8 1.1c-0.7 .7-1 1.7-1 3Zm16.1 9.6v-16.5h2.7v3.1c.1-1.1 .6-1.9 1.3-2.5c.8-0.6 1.8-0.9 3.1-0.9c1.7 0 3.1 .5 4.1 1.6c1 1.1 1.5 2.6 1.5 4.5v1.1h-2.7v-0.9c0-1.3-0.3-2.2-0.9-2.9c-0.7-0.7-1.6-1.1-2.8-1.1c-2.4 0-3.6 1.4-3.6 4v10.5Zm23.7 .3c-1.3 0-2.4-0.3-3.4-0.8c-1-0.5-1.7-1.2-2.3-2.2c-0.5-0.9-0.8-2-0.8-3.3v-4.5c0-1.3 .3-2.4 .8-3.3c.6-1 1.3-1.7 2.3-2.2c1-0.5 2.1-0.8 3.4-0.8c1.3 0 2.4 .3 3.4 .8c1 .5 1.7 1.2 2.3 2.2c.5 .9 .7 2 .7 3.3v2.9h-10.2v1.6c0 1.3 .3 2.3 1 3c.6 .7 1.6 1 2.8 1c1 0 1.9-0.2 2.5-0.5c.7-0.4 1-1 1.2-1.7h2.7c-0.2 1.4-0.9 2.5-2 3.3c-1.2 .8-2.7 1.2-4.4 1.2Zm-3.8-9.9h7.6v-0.9c0-1.3-0.3-2.3-1-3c-0.6-0.7-1.6-1.1-2.8-1.1c-1.2 0-2.2 .4-2.8 1.1c-0.7 .7-1 1.7-1 3Z"/><g transform="translate(764,-14.5) scale(.431111,.440249) translate(-13.9,56.6)"><path fill="#e0e0e0" stroke="#e0e0e0" stroke-linejoin="round" d="M-50.7 4h278.2c10 0 9 0 9 0l41 40c0 0 1 0-9 0h-358c-9.9 0-9 0-9 0l38.8-40c0 0-0.9 0 9 0Z" stroke-width="10" transform="translate(225,339.9) scale(0,1) translate(-89.5,-24)" style="animation: 10s linear infinite both a0_t;"/><rect width="83" height="22" stroke="#fb422d" fill="#e0e0e0" rx="2" stroke-width="0" transform="translate(225,348.9) scale(0,1) translate(-41.5,-11)" style="animation: 10s linear infinite both a1_t;"/><g style="animation: 10s linear infinite both a3_t;"><rect width="400" height="334" stroke="#e0e0e0" fill="none" stroke-width="30" stroke-miterlimit="1" rx="10" opacity="0" transform="translate(225,198.9) rotate(-90) translate(-200,-167)" style="animation: 10s linear infinite both a2_t, 10s linear infinite both a2_o, 10s linear infinite both a2_sw, 10s linear infinite both a2_w, 10s linear infinite both a2_h;"/></g><use width="168.5" height="302" xlink:href="#Symbol-2" opacity="0" transform="translate(227.8,199.9) translate(-84.2,-151)" style="animation: 10s linear infinite both a4_t, 10s linear infinite both a4_w, 10s linear infinite both a4_h;"/><rect width="16" height="8" stroke="#fb422d" fill="#e0e0e0" stroke-width="0" rx="2" opacity="0" transform="translate(225,328.9) translate(-8,-4)" style="animation: 10s linear infinite both a5_t, 10s linear infinite both a5_o, 10s linear infinite both a5_w;"/><rect width="16" height="8" stroke="#fb422d" fill="#e0e0e0" stroke-width="0" rx="2" opacity="0" transform="translate(225,328.9) translate(-8,-4)" style="animation: 10s linear infinite both a6_t, 10s linear infinite both a6_o, 10s linear infinite both a6_w;"/><g transform="translate(225,198.9) scale(1.5,1.5) translate(-42.3,-93)" style="animation: 10s linear infinite both a7_t;"><g transform="translate(42.3,93) scale(5.352,6.9) translate(-16,60)"><g transform="translate(-34.9,-125.8)"><g transform="translate(24,5)"><path d="M33 46.5c0 3.1-0.8 5.5-2.2 7.4c-1.4 1.9-3.3 3.6-5.4 5.4c-2.2 1.7-4.5 3.6-6.3 6.2c-1.8 2.5-3.1 5.5-3.1 9.5h4.7c0-3.1 .9-5.4 2.2-7.3c1.4-1.9 3.3-3.5 5.5-5.3c2.1-1.8 4.4-3.7 6.2-6.2c1.8-2.6 3.1-5.6 3.1-9.7Z" fill="#e96020"/><path d="M20.4 70.7c-0.6 0-1 .5-1 1.1c0 .7 .4 1.2 1 1.2h12.9c.7 0 1.2-0.5 1.2-1.2c0-0.6-0.5-1.1-1.2-1.1Z" fill="#2d323b"/><path d="M21.8 66.6c-0.7 0-1 .6-1 1.2c0 .6 .3 1 .9 1h10.3c.6 0 1.1-0.5 1.1-1.1c0-0.6-0.5-1.1-1.1-1.1Z" fill="#2d323b"/><path d="M21.8 53c-0.7 0-1.2 .5-1.1 1.1c0 .6 .4 1.1 1.1 1.1h10.2c.6 0 .9-0.6 .9-1.2c0-0.6-0.3-1-0.9-1Z" fill="#2d323b"/><path d="M20.4 48.8c-0.6 0-1.2 .5-1.2 1.1c0 .7 .6 1.2 1.2 1.2h12.9c.7 0 1-0.5 1-1.1c0-0.7-0.3-1.2-1-1.2Z" fill="#2d323b"/><path d="M16 46.5c0 4.1 1.3 7.1 3.1 9.7c1.8 2.5 4.1 4.4 6.3 6.2c2.1 1.8 4 3.6 5.4 5.5c1.4 1.9 2.2 4 2.2 7.1h4.7c0-4-1.3-7.1-3.1-9.6c-1.8-2.5-4.1-4.4-6.2-6.2c-2.2-1.8-4.1-3.4-5.5-5.3c-1.3-1.9-2.2-4.3-2.2-7.4Z" fill="#00a8d6"/></g></g></g></g></g></svg>
+70 -82
assets/main.css
··· 1 - /* App-wide styling */ 2 - body { 3 - background-color: #0f1116; 4 - color: #ffffff; 5 - font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 6 - margin: 20px; 1 + @property --grid-x { 2 + syntax: "<number>"; 3 + inherits: false; 4 + initial-value: 0; 7 5 } 8 6 9 - #hero { 10 - margin: 0; 11 - display: flex; 12 - flex-direction: column; 13 - justify-content: center; 14 - align-items: center; 7 + @property --grid-y { 8 + syntax: "<number>"; 9 + inherits: false; 10 + initial-value: 0; 15 11 } 16 12 17 - #links { 18 - width: 400px; 19 - text-align: left; 20 - font-size: x-large; 21 - color: white; 22 - display: flex; 23 - flex-direction: column; 13 + @property --drag-x { 14 + syntax: "<length>"; 15 + inherits: false; 16 + initial-value: 0px; 24 17 } 25 18 26 - #links a { 27 - color: white; 28 - text-decoration: none; 29 - margin-top: 20px; 30 - margin: 10px 0px; 31 - border: white 1px solid; 32 - border-radius: 5px; 33 - padding: 10px; 19 + @property --drag-y { 20 + syntax: "<length>"; 21 + inherits: false; 22 + initial-value: 0px; 34 23 } 35 24 36 - #links a:hover { 37 - background-color: #1f1f1f; 38 - cursor: pointer; 25 + @property --loose-x { 26 + syntax: "<length>"; 27 + inherits: false; 28 + initial-value: 0px; 39 29 } 40 30 41 - #header { 42 - max-width: 1200px; 31 + @property --loose-y { 32 + syntax: "<length>"; 33 + inherits: false; 34 + initial-value: 0px; 43 35 } 44 36 45 - /* Navbar */ 46 - #navbar { 47 - display: flex; 48 - flex-direction: row; 49 - } 50 - 51 - #navbar a { 52 - color: #ffffff; 53 - margin-right: 20px; 54 - text-decoration: none; 55 - transition: color 0.2s ease; 37 + @property --loose-rotation { 38 + syntax: "<angle>"; 39 + inherits: false; 40 + initial-value: 0deg; 56 41 } 57 42 58 - #navbar a:hover { 59 - cursor: pointer; 60 - color: #91a4d2; 61 - } 43 + :root { 44 + font-size: 16px; 45 + overscroll-behavior: none; 62 46 63 - /* Blog page */ 64 - #blog { 65 - margin-top: 50px; 66 - } 67 - 68 - #blog a { 69 - color: #ffffff; 70 - margin-top: 50px; 47 + --color-money: rgb(214 168 15); 48 + --color-resource: rgb(199 73 52); 49 + --color-terrain: rgb(38 163 38); 50 + --color-card: rgb(164 85 217); 51 + --color-species: rgb(16 121 227); 52 + --color-pack: rgb(179 43 74); 53 + --color-input: rgb(66 90 245); 54 + --color-output: rgb(244 0 213); 71 55 } 72 56 73 - /* Echo */ 74 - #echo { 75 - width: 360px; 76 - margin-left: auto; 77 - margin-right: auto; 78 - margin-top: 50px; 79 - background-color: #1e222d; 80 - padding: 20px; 81 - border-radius: 10px; 57 + body { 58 + min-height: 100vh; 59 + font-size: 1rem; 60 + font-weight: 400; 82 61 } 83 62 84 - #echo>h4 { 85 - margin: 0px 0px 15px 0px; 63 + * { 64 + margin: 0; 65 + padding: 0; 66 + font-family: sans-serif; 67 + box-sizing: border-box; 86 68 } 87 69 88 - 89 - #echo>input { 90 - border: none; 91 - border-bottom: 1px white solid; 92 - background-color: transparent; 93 - color: #ffffff; 94 - transition: border-bottom-color 0.2s ease; 95 - outline: none; 96 - display: block; 97 - padding: 0px 0px 5px 0px; 98 - width: 100%; 70 + a:link, 71 + a:visited, 72 + a:active, 73 + a { 74 + text-decoration: none; 75 + color: black; 99 76 } 100 77 101 - #echo>input:focus { 102 - border-bottom-color: #6d85c6; 78 + h1 { 79 + font-size: 2rem; 80 + font-weight: bold; 103 81 } 104 82 105 - #echo>p { 106 - margin: 20px 0px 0px auto; 107 - } 83 + button { 84 + padding: 0.5rem 1rem; 85 + border: 1px solid rgb(0 0 0 / 0.25); 86 + border-radius: 0.25rem; 87 + background: rgb(0 0 0 / 0); 88 + cursor: pointer; 89 + font-size: 1rem; 90 + 91 + &:hover, 92 + &:focus-visible { 93 + background-color: rgb(0 0 0 / 0.05); 94 + } 95 + }
+8 -96
src/app.rs
··· 1 1 use dioxus::prelude::*; 2 2 3 - use crate::api::echo_server; 3 + mod menu; 4 + mod play; 5 + 6 + use menu::Menu; 7 + use play::Play; 4 8 5 - const FAVICON: Asset = asset!("/assets/favicon.ico"); 6 9 const MAIN_CSS: Asset = asset!("/assets/main.css"); 7 - const HEADER_SVG: Asset = asset!("/assets/header.svg"); 8 10 9 11 #[derive(Debug, Clone, Routable, PartialEq)] 10 - #[rustfmt::skip] 11 12 enum Route { 12 - #[layout(Navbar)] 13 13 #[route("/")] 14 - Home {}, 15 - #[route("/blog/:id")] 16 - Blog { id: i32 }, 14 + Menu {}, 15 + #[route("/play")] 16 + Play {}, 17 17 } 18 18 19 19 #[component] 20 20 pub fn App() -> Element { 21 21 rsx! { 22 - document::Link { rel: "icon", href: FAVICON } 23 22 document::Link { rel: "stylesheet", href: MAIN_CSS } 24 23 Router::<Route> {} 25 24 } 26 25 } 27 - 28 - #[component] 29 - pub fn Hero() -> Element { 30 - rsx! { 31 - div { id: "hero", 32 - img { src: HEADER_SVG, id: "header" } 33 - div { id: "links", 34 - a { href: "https://dioxuslabs.com/learn/0.7/", "📚 Learn Dioxus" } 35 - a { href: "https://dioxuslabs.com/awesome", "🚀 Awesome Dioxus" } 36 - a { href: "https://github.com/dioxus-community/", "📡 Community Libraries" } 37 - a { href: "https://github.com/DioxusLabs/sdk", "⚙️ Dioxus Development Kit" } 38 - a { href: "https://marketplace.visualstudio.com/items?itemName=DioxusLabs.dioxus", 39 - "💫 VSCode Extension" 40 - } 41 - a { href: "https://discord.gg/XgGxMSkvUM", "👋 Community Discord" } 42 - } 43 - } 44 - } 45 - } 46 - 47 - /// Home page 48 - #[component] 49 - fn Home() -> Element { 50 - rsx! { 51 - Hero {} 52 - Echo {} 53 - } 54 - } 55 - 56 - /// Blog page 57 - #[component] 58 - pub fn Blog(id: i32) -> Element { 59 - rsx! { 60 - div { id: "blog", 61 - 62 - // Content 63 - h1 { "This is blog #{id}!" } 64 - p { 65 - "In blog #{id}, we show how the Dioxus router works and how URL parameters can be passed as props to our route components." 66 - } 67 - 68 - // Navigation links 69 - Link { to: Route::Blog { id: id - 1 }, "Previous" } 70 - span { " <---> " } 71 - Link { to: Route::Blog { id: id + 1 }, "Next" } 72 - } 73 - } 74 - } 75 - 76 - /// Shared navbar component. 77 - #[component] 78 - fn Navbar() -> Element { 79 - rsx! { 80 - div { id: "navbar", 81 - Link { to: Route::Home {}, "Home" } 82 - Link { to: Route::Blog { id: 1 }, "Blog" } 83 - } 84 - 85 - Outlet::<Route> {} 86 - } 87 - } 88 - 89 - /// Echo component that demonstrates fullstack server functions. 90 - #[component] 91 - fn Echo() -> Element { 92 - let mut response = use_signal(String::new); 93 - 94 - rsx! { 95 - div { id: "echo", 96 - h4 { "ServerFn Echo" } 97 - input { 98 - placeholder: "Type here to echo...", 99 - oninput: move |event| async move { 100 - let data = echo_server(event.value()).await.unwrap(); 101 - response.set(data); 102 - }, 103 - } 104 - 105 - if !response().is_empty() { 106 - p { 107 - "Server echoed: " 108 - i { "{response}" } 109 - } 110 - } 111 - } 112 - } 113 - }
+21
src/app/menu.rs
··· 1 + use dioxus::prelude::*; 2 + 3 + #[component] 4 + pub fn Menu() -> Element { 5 + rsx! { 6 + main { 7 + display: "flex", 8 + width: "100%", 9 + height: "100vh", 10 + flex_direction: "column", 11 + align_items: "center", 12 + justify_content: "center", 13 + gap: "1rem", 14 + 15 + h1 { font_size: "2rem", "This game?" } 16 + a { href: "/cards", "See the cards" } 17 + a { href: "/play", "Just Play" } 18 + a { href: "/demo", "Try Demo" } 19 + } 20 + } 21 + }
+11
src/app/play.rs
··· 1 + use dioxus::prelude::*; 2 + 3 + #[component] 4 + pub fn Play() -> Element { 5 + rsx! { 6 + main { display: "flex", 7 + div { 8 + } 9 + } 10 + } 11 + }