Private
Public Access
1
0

improve game graph design

This commit is contained in:
2016-11-07 22:39:52 +01:00
parent c2e643671b
commit d797012d51
8 changed files with 65 additions and 37 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.3 MiB

After

Width:  |  Height:  |  Size: 1.8 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 MiB

After

Width:  |  Height:  |  Size: 513 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.0 MiB

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 MiB

After

Width:  |  Height:  |  Size: 1.2 MiB

View File

@@ -1,6 +1,12 @@
@import 'https://fonts.googleapis.com/css?family=Open+Sans:700'; /*@import 'https://fonts.googleapis.com/css?family=Open+Sans:700';*/
@import url('https://fonts.googleapis.com/css?family=Changa+One|Open+Sans:700');
@import 'https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css'; @import 'https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css';
body {
background: url("/bundles/mineseeker/images/bg-mineseeker-outbg.jpg") no-repeat center center;
background-size: cover;
}
.clear { .clear {
clear: both clear: both
} }
@@ -71,7 +77,7 @@
} }
#mine-wrapper .game-wrapper .users { #mine-wrapper .game-wrapper .users {
width: 200px; width: 180px;
padding: 0 10px 0 0; padding: 0 10px 0 0;
} }
@@ -105,20 +111,22 @@
} }
#mine-wrapper .game-wrapper .users .user-container .user-header { #mine-wrapper .game-wrapper .users .user-container .user-header {
background: -moz-linear-gradient(top, rgba(255, 255, 255, 1) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%); background: -moz-linear-gradient(top, rgba(255, 255, 255, 0.7) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%);
background: -webkit-linear-gradient(top, rgba(255, 255, 255, 1) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%); background: -webkit-linear-gradient(top, rgba(255, 255, 255, 0.7) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%);
background: linear-gradient(to bottom, rgba(255, 255, 255, 1) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%); background: linear-gradient(to bottom, rgba(255, 255, 255, 0.7) 39%, rgba(255, 255, 255, 0.21) 87%, rgba(0, 0, 0, 0) 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#00000000', GradientType=0); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#00000000', GradientType=0);
position: relative; position: relative;
font-weight: bolder; font: bolder 25px 'Changa One', cursive;
font-size: 25px; letter-spacing: 5px;
text-transform: uppercase; text-transform: uppercase;
text-align: center; text-align: center;
padding: 5px 5px 25px 5px; padding: 6px 5px 20px 5px;
margin-bottom: 50px; margin-bottom: 40px;
-webkit-border-radius: 5px; -webkit-border-radius: 5px;
border-radius: 5px; border-radius: 5px;
-webkit-text-shadow: 1px 1px 0 #FFF;
text-shadow: 1px 1px 0 #FFF;
} }
#mine-wrapper .game-wrapper .users .user-container.user-blue .user-header { #mine-wrapper .game-wrapper .users .user-container.user-blue .user-header {
@@ -175,6 +183,7 @@
} }
#mine-wrapper .game-wrapper .users .user-container .user-name { #mine-wrapper .game-wrapper .users .user-container .user-name {
min-height: 30px;
font-weight: normal; font-weight: normal;
text-align: center; text-align: center;
white-space: nowrap; white-space: nowrap;
@@ -198,8 +207,10 @@
} }
#mine-wrapper .game-wrapper .users .user-container .user-caret { #mine-wrapper .game-wrapper .users .user-container .user-caret {
height: 35px;
font-size: 35px; font-size: 35px;
text-align: center; text-align: center;
line-height: 15px;
} }
#mine-wrapper .game-wrapper .users .user-container.user-blue .user-caret > i { #mine-wrapper .game-wrapper .users .user-container.user-blue .user-caret > i {
@@ -210,10 +221,14 @@
color: #fdf612; color: #fdf612;
} }
#mine-wrapper .game-wrapper .users .user-container .user-desc {
height: 60px;
}
#mine-wrapper .game-wrapper .users .user-container .user-control { #mine-wrapper .game-wrapper .users .user-container .user-control {
background: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 1) 0%, rgba(125, 185, 232, 0) 100%); background: -moz-linear-gradient(-45deg, rgba(255, 255, 255, 0.5) 0%, rgba(125, 185, 232, 0) 100%);
background: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 1) 0%, rgba(125, 185, 232, 0) 100%); background: -webkit-linear-gradient(-45deg, rgba(255, 255, 255, 0.5) 0%, rgba(125, 185, 232, 0) 100%);
background: linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(125, 185, 232, 0) 100%); background: linear-gradient(135deg, rgba(255, 255, 255, 0.5) 0%, rgba(125, 185, 232, 0) 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#007db9e8', GradientType=1); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffff', endColorstr='#007db9e8', GradientType=1);
position: relative; position: relative;
padding: 5px; padding: 5px;
@@ -238,7 +253,7 @@
background: #FFFFFF; background: #FFFFFF;
font-size: 25px; font-size: 25px;
text-align: center; text-align: center;
width: 50px; width: 45px;
height: 35px; height: 35px;
margin-left: 25px; margin-left: 25px;
margin-top: 5px; margin-top: 5px;
@@ -258,7 +273,7 @@
#mine-wrapper .game-wrapper .users .user-container .user-control .bomb-container { #mine-wrapper .game-wrapper .users .user-container .user-control .bomb-container {
display: inline-block; display: inline-block;
float: right; float: right;
width: 75px; width: 65px;
height: 45px; height: 45px;
border: 1px solid #000; border: 1px solid #000;
@@ -394,15 +409,15 @@
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#464942', endColorstr='#605961', GradientType=0); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#464942', endColorstr='#605961', GradientType=0);
position: relative; position: relative;
width: 95%; width: 95%;
height: 70px; height: 50px;
font-family: 'Open Sans', sans-serif; font-family: 'Open Sans', sans-serif;
font-weight: bold; font-weight: bold;
font-size: 22px; font-size: 22px;
text-transform: uppercase; text-transform: uppercase;
text-align: center; text-align: center;
line-height: 65px; line-height: 45px;
border: 3px solid #484742; border: 3px solid #484742;
color: #FFFFFF; color: #fff;
margin: 10px auto 0 auto; margin: 10px auto 0 auto;
cursor: pointer; cursor: pointer;
@@ -513,32 +528,33 @@
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcfc', endColorstr='#006a6a6a', GradientType=1); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcfc', endColorstr='#006a6a6a', GradientType=1);
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: center center; background-position: center center;
background-size: 85% 100%; background-size: 72% 179%;
position: relative; position: relative;
height: 30px; height: 30px;
} }
#mine-wrapper .game-wrapper .users .active-mines-container i { #mine-wrapper .game-wrapper .users .active-mines-container i {
font-size: 35px; font-size: 27px;
color: #b1b1b3; color: #b1b1b3;
margin-top: 3px;
text-shadow: 0 0 3px #000000; text-shadow: 0 0 3px #000000;
} }
#mine-wrapper .game-wrapper .users .active-mines-container i:first-child { #mine-wrapper .game-wrapper .users .active-mines-container i:first-child {
float: left; float: left;
margin-left: 25px; margin-left: 20px;
} }
#mine-wrapper .game-wrapper .users .active-mines-container i:last-child { #mine-wrapper .game-wrapper .users .active-mines-container i:last-child {
float: right; float: right;
margin-right: 25px; margin-right: 20px;
} }
#mine-wrapper .game-wrapper .users .active-mines-container .active-mines { #mine-wrapper .game-wrapper .users .active-mines-container .active-mines {
background: -moz-linear-gradient(top, rgba(62, 63, 65, 1) 0%, rgba(135, 136, 131, 1) 100%); background: -moz-linear-gradient(top, rgba(0, 0, 0, 1) 0%, rgba(135, 136, 131, 1) 100%);
background: -webkit-linear-gradient(top, rgba(62, 63, 65, 1) 0%, rgba(135, 136, 131, 1) 100%); background: -webkit-linear-gradient(top, rgba(0, 0, 0, 1) 0%, rgba(135, 136, 131, 1) 100%);
background: linear-gradient(to bottom, rgba(62, 63, 65, 1) 0%, rgba(135, 136, 131, 1) 100%); background: linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(135, 136, 131, 1) 100%);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#3e3f41', endColorstr='#878883', GradientType=0); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#3e3f41', endColorstr='#878883', GradientType=0);
position: absolute; position: absolute;
width: 50px; width: 50px;
@@ -550,7 +566,7 @@
line-height: 39px; line-height: 39px;
text-align: center; text-align: center;
color: #FFFFFF; color: #FFFFFF;
border: 5px solid #38383a; border: 5px solid #000000;
margin-left: -25px; margin-left: -25px;
z-index: 100; z-index: 100;
@@ -560,8 +576,8 @@
} }
#mine-wrapper .game-wrapper .users .active-mines-container .active-mines.found-mine { #mine-wrapper .game-wrapper .users .active-mines-container .active-mines.found-mine {
-webkit-animation: bubbleLeftMine 500ms cubic-bezier(.36, .07, .19, .97) both; -webkit-animation: bubbleLeftMine 750ms cubic-bezier(.36, .07, .19, .97) both;
animation: bubbleLeftMine 500ms cubic-bezier(.36, .07, .19, .97) both; animation: bubbleLeftMine 750ms cubic-bezier(.36, .07, .19, .97) both;
} }
@keyframes bubbleLeftMine { @keyframes bubbleLeftMine {
@@ -570,6 +586,7 @@
transform: scale(1); transform: scale(1);
} }
50% { 50% {
border-color: #2e3337;
-webkit-transform: scale(2); -webkit-transform: scale(2);
transform: scale(2); transform: scale(2);
} }
@@ -587,9 +604,9 @@
position: absolute; position: absolute;
top: 0; top: 0;
left: 50%; left: 50%;
width: 25px; width: 30px;
height: 20px; height: 20px;
margin-left: -12.5px; margin-left: -14.5px;
z-index: 101; z-index: 101;
@@ -619,6 +636,14 @@
cursor: none; cursor: none;
} }
#mine-wrapper .grid-container {
background: #4E4E4E;
padding: 15px 10px;
-webkit-border-radius: 5px;
border-radius: 5px;
}
#mine-wrapper .grid .field-wrapper { #mine-wrapper .grid .field-wrapper {
position: relative; position: relative;
} }

View File

@@ -413,7 +413,9 @@ class GridControl extends React.Component {
</div> </div>
<UserControl ref="userControl" <UserControl ref="userControl"
bombClear={this.bombClear.bind(this)}/> bombClear={this.bombClear.bind(this)}/>
<div className="grid"> {grid} </div> <div className="grid-container">
<div className="grid"> {grid} </div>
</div>
</div> </div>
); );
} }

View File

@@ -57,6 +57,7 @@ class User extends React.Component {
</div> </div>
<div className="user-name"> {this.state.name} </div> <div className="user-name"> {this.state.name} </div>
<div className="user-caret"><i className="fa fa-caret-down"></i></div> <div className="user-caret"><i className="fa fa-caret-down"></i></div>
<div className="user-desc"></div>
<div className="user-control"> <div className="user-control">
<img src={this.getSrc(this.props.color)} alt="flag"/> <img src={this.getSrc(this.props.color)} alt="flag"/>
<div className="user-control-mines"> <div className="user-control-mines">

View File

@@ -1,12 +1,5 @@
{% extends '::base.html.twig' %} {% extends '::base.html.twig' %}
{% block stylesheets %}
{% stylesheets filter='cssrewrite'
'@MineSeekerBundle/Resources/public/css/style.mineseeker.css' %}
<link rel="stylesheet" media="screen" href="{{ asset_url }}" type="text/css"/>
{% endstylesheets %}
{% endblock %}
{% block body %} {% block body %}
<div id="mine-wrapper" <div id="mine-wrapper"
data-env="{{ env }}" data-env="{{ env }}"
@@ -14,6 +7,13 @@
</div> </div>
{% endblock %} {% endblock %}
{% block stylesheets %}
{% stylesheets filter='cssrewrite'
'@MineSeekerBundle/Resources/public/css/style.mineseeker.css' %}
<link rel="stylesheet" media="screen" href="{{ asset_url }}" type="text/css"/>
{% endstylesheets %}
{% endblock %}
{% block javascripts %} {% block javascripts %}
{{ parent() }} {{ parent() }}
{{ ws_client() }} {{ ws_client() }}