aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRiley L. <riley@e926.de>2024-11-03 18:41:33 +0100
committerRiley L. <riley@e926.de>2024-11-03 18:42:30 +0100
commit9f953f6bba497f7d94fa1d9f7912c8d9d79da3f7 (patch)
tree7312b0e9d0221a71118f0a5ba9bad68dbc795541
parentd69402120b4e8489ad222d63d01d08d62d1e49ef (diff)
downloadabrechenbarkeit-9f953f6bba497f7d94fa1d9f7912c8d9d79da3f7.tar
abrechenbarkeit-9f953f6bba497f7d94fa1d9f7912c8d9d79da3f7.tar.bz2
abrechenbarkeit-9f953f6bba497f7d94fa1d9f7912c8d9d79da3f7.tar.zst
commig style.css
-rw-r--r--.gitignore1
-rwxr-xr-xabrechenbarkeit.lua4
-rw-r--r--style.css148
3 files changed, 149 insertions, 4 deletions
diff --git a/.gitignore b/.gitignore
index 23a4d05..8b2e619 100644
--- a/.gitignore
+++ b/.gitignore
@@ -5,3 +5,4 @@
!/script.js
!/.gitignore
!/collapse_log.lua
+!/style.css
diff --git a/abrechenbarkeit.lua b/abrechenbarkeit.lua
index 311cd1c..0efac7c 100755
--- a/abrechenbarkeit.lua
+++ b/abrechenbarkeit.lua
@@ -54,10 +54,6 @@ local query = parse_query(os.getenv("QUERY_STRING"))
local stylesheet = io.open("style.css"):read("a")
local script = io.open("script.js"):read("a")
-local script = [[
-
-]]
-
local function respond(status, title, body)
print(string.format("Status: %d", status))
print("Content-Type: text/html")
diff --git a/style.css b/style.css
new file mode 100644
index 0000000..2308ae7
--- /dev/null
+++ b/style.css
@@ -0,0 +1,148 @@
+body {
+ background-color: #25333f;
+}
+
+body > * {
+ margin: 0.5rem;
+}
+
+/* nav bar */
+*, .logo {
+ color: #e2e2e2;
+ font-family: "Roboto", sans-serif;
+}
+
+nav {
+ background-color: #1d2832;
+ margin: 0;
+ padding: 1em;
+ font-size: 1.2em;
+}
+
+nav a {
+ padding-right: 1em;
+ text-decoration: none;
+ color: rgb(65, 89, 110);
+}
+
+nav h2 {
+ display: inline-block
+}
+
+/* notification stuff */
+.notif {
+ padding: 0.5em;
+ background-color: #ddd;
+}
+
+.notif.error {
+ background-color: #faa;
+}
+
+.notif p {
+ margin: 5px;
+}
+
+/* landing page */
+form.creation {
+ background-color: #2e3d4d;
+ padding: 1em;
+ margin-top: 2em;
+}
+
+form.creation > h3 {
+ margin: 5px;
+ margin-right: 2em;
+}
+
+input {
+ color: #2e3d4d;
+}
+
+input[type="text"] {
+ width: calc(100% - 40em);
+ min-width: 10em;
+}
+
+form.creation > * {
+ display: inline-block;
+ margin-right: 1.5em;
+}
+
+li a {
+ text-decoration: none;
+}
+
+ul {
+ padding-left: 0;
+ display: grid;
+ justify-content: left;
+ grid-auto-rows: minmax(5em, auto);
+ gap: 1em;
+ grid-template-columns: repeat(auto-fill, minmax(8em, 1fr));
+ list-style-type: none;
+}
+
+li {
+ background-color: #2e3d4d;
+ width: 6em;
+ height: 3.5em;
+ padding: 1em;
+ margin: .5em;
+ margin-left: 0;
+}
+
+.name {
+ display: block;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
+
+/* Amount selector user page */
+.amount {
+ display: block;
+ padding-top: 1em;
+}
+
+.amount-presets {
+ display: grid;
+ justify-content: left;
+ grid-auto-rows: minmax(5em, 2);
+ grid-template-columns: repeat(6, 6em);
+ list-style-type: none;
+}
+
+.amount-presets > form {
+ margin-top: 0;
+ margin-bottom: 0;
+}
+
+.amount-presets > form > input {
+ place-content: center;
+ padding: 0.8em 0.5em;
+ border: none;
+ border-radius: 4px;
+ width: 6em;
+ margin: 1em;
+}
+
+.amount-presets input:not([type=submit]) {
+ display: none !important;
+}
+
+.amount-pos {
+ color: rgb(0, 204, 29);
+}
+
+input.amount-pos {
+ background: rgb(21, 89, 73);
+}
+
+.amount-neg {
+ color: rgb(245, 73, 99);
+}
+
+input.amount-neg {
+ background-color: rgb(84, 64, 82);
+}