From 92fda72cf54691a29ef81c1f93a1e9dd75d99a52 Mon Sep 17 00:00:00 2001 From: Gabriele Cirulli Date: Tue, 11 Mar 2014 15:18:20 +0100 Subject: [PATCH] move button styles to mixin --- style/main.css | 26 ++++++++++---------------- style/main.scss | 21 +++++++++++++-------- 2 files changed, 23 insertions(+), 24 deletions(-) diff --git a/style/main.css b/style/main.css index abf1921..869661c 100644 --- a/style/main.css +++ b/style/main.css @@ -131,6 +131,16 @@ hr { 100% { opacity: 1; } } +.game-container .game-message a { + display: inline-block; + background: #8f7a66; + border-radius: 3px; + padding: 0 20px; + text-decoration: none; + color: #f9f6f2; + height: 40px; + line-height: 42px; } + .game-container { margin-top: 40px; position: relative; @@ -170,14 +180,6 @@ hr { display: block; margin-top: 59px; } .game-container .game-message a { - display: inline-block; - background: #8f7a66; - border-radius: 3px; - padding: 0 20px; - text-decoration: none; - color: #f9f6f2; - height: 40px; - line-height: 42px; margin-left: 9px; } .game-container .game-message.game-won { background: rgba(237, 194, 46, 0.5); @@ -502,14 +504,6 @@ hr { display: block; margin-top: 59px; } .game-container .game-message a { - display: inline-block; - background: #8f7a66; - border-radius: 3px; - padding: 0 20px; - text-decoration: none; - color: #f9f6f2; - height: 40px; - line-height: 42px; margin-left: 9px; } .game-container .game-message.game-won { background: rgba(237, 194, 46, 0.5); diff --git a/style/main.scss b/style/main.scss index 635f7cc..731d38d 100644 --- a/style/main.scss +++ b/style/main.scss @@ -141,6 +141,18 @@ hr { } } +// Styles for buttons +@mixin button { + display: inline-block; + background: darken($game-container-background, 20%); + border-radius: 3px; + padding: 0 20px; + text-decoration: none; + color: $bright-text-color; + height: 40px; + line-height: 42px; +} + // Game field mixin used to render CSS at different width @mixin game-field { .game-container { @@ -190,14 +202,7 @@ hr { } a { - display: inline-block; - background: darken($game-container-background, 20%); - border-radius: 3px; - padding: 0 20px; - text-decoration: none; - color: $bright-text-color; - height: 40px; - line-height: 42px; + @include button; margin-left: 9px; // margin-top: 59px; } -- GitLab