theenglishway (time) vor 6 Jahren
Ursprung
Commit
9bd1040154
3 geänderte Dateien mit 46 neuen und 1 gelöschten Zeilen
  1. 1 1
      form/form.html
  2. 3 0
      form/notes.md
  3. 42 0
      form/style.css

+ 1 - 1
form/form.html

@@ -10,7 +10,7 @@
   <title>Document</title>
 </head>
 
-<body>
+<body class="body--">
   <form class="form form--full-page" action="#" method="post">
     <h1 class="form__title">Ajouter un nouveau lien</h1>
     <div class="form__field">

+ 3 - 0
form/notes.md

@@ -0,0 +1,3 @@
+# Notes
+
+By default only the button stretches across the whole container.

+ 42 - 0
form/style.css

@@ -0,0 +1,42 @@
+
+:root {
+  --color-form: rgb(203, 222, 228);
+  --color-field: rgba(255, 0, 0, 0.123);
+  --color-label: rgba(0, 255, 42, 0.123);
+  --color-input: rgba(0, 4, 255, 0.123);
+}
+
+/* Remove the code below to restore colors */
+:root { --color-form: transparent; --color-field: transparent; --color-label: transparent; --color-input: transparent; }
+
+body {
+  display: flex;
+  flex-direction: column;
+}
+
+.body--centered {
+  align-items: center;
+}
+
+.form {
+  display: flex;
+  flex-direction: column;
+  background-color: var(--color-form);
+}
+
+.field {
+  display: flex;
+  align-items: center;
+  background-color: var(--color-field);
+  margin: 0.2em 0px;
+}
+
+.field__label {
+  flex: 1;
+  background-color: var(--color-label);
+}
+
+.field__input {
+  flex: 2;
+  background-color: var(--color-input);
+}