diff --git a/assets/css/app.scss b/assets/css/app.scss index 4bf4028..50487a4 100644 --- a/assets/css/app.scss +++ b/assets/css/app.scss @@ -1,3 +1,5 @@ +$accent-color: #1b4ad6; + body { font-family: -apple-system, BlinkMacSystemFont, Helvetica, Arial, sans-serif; } @@ -27,3 +29,53 @@ header nav { } } +table { + width: 100%; + margin-bottom: 1rem; +} + +form { + margin-bottom: 1rem; + + label, input:not([type=file]), textarea { + display: block; + } + + input, textarea { + font-size: 1rem; + } + + input:not([type=file]), textarea { + width: 100%; + padding: 2px; + margin-bottom: 0.5rem; + border: 1px solid lightgray; + border-radius: 5px; + } + + textarea { + min-height: 200px; + max-width: 100%; + min-width: 100%; + } +} + +button, input[type=submit] { + padding: 0.25rem 1.5rem; + border: 1px solid darken($accent-color, 10%); + border-radius: 5px; + background-color: $accent-color; + color: white; + + font-size: 1rem; + + &:hover { + border-color: darken($accent-color, 25%); + background-color: darken($accent-color, 10%); + } +} + +a { + color: $accent-color; +} + diff --git a/lib/wiki_web/templates/page/index.html.eex b/lib/wiki_web/templates/page/index.html.eex index 57060f7..3b1861a 100644 --- a/lib/wiki_web/templates/page/index.html.eex +++ b/lib/wiki_web/templates/page/index.html.eex @@ -4,7 +4,6 @@ Title - Content @@ -12,11 +11,9 @@ <%= for page <- @pages do %> - <%= page.title %> - <%= page.content %> + <%= link page.title, to: Routes.page_path(@conn, :show, page) %> - <%= link "Show", to: Routes.page_path(@conn, :show, page) %> <%= link "Edit", to: Routes.page_path(@conn, :edit, page) %> <%= link "Delete", to: Routes.page_path(@conn, :delete, page), method: :delete, data: [confirm: "Are you sure?"] %>