Skip to content

Commit

Permalink
Fixes #80 Selector widget style and size improvements
Browse files Browse the repository at this point in the history
Selector widget width is now fluid
Added custom min-height on user auth permissions selector
  • Loading branch information
darklow committed Apr 13, 2013
1 parent 3abcea8 commit 71211f7
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 21 deletions.
20 changes: 14 additions & 6 deletions suit/static/suit/css/suit.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

59 changes: 44 additions & 15 deletions suit/static/suit/less/ui/form.less
Original file line number Diff line number Diff line change
Expand Up @@ -376,32 +376,48 @@ h3 {
}
}

.controls .selector {
.form-horizontal .control-group .controls .selector {
overflow: auto;
.selector-available, .selector-chooser, .selector-chosen {
float: left;
select {
display: block;
}
h2 {
margin-left: 5px;
font-size: 12px;
}
}
.selector-available, .selector-chosen {
width: 45%;
min-width: 150px;
max-width: 300px;
select, input {
width: 100%;
display: block;
}
}
.selector-chooser {
list-style: none;
margin: 70px 10px 0 10px;
li {
&:before {
line-height: 18px;
content: "\00bb";
display: inline-block;
margin-right: 5px;
font-size: 16px;
.color-grey;
a {
.bs-icon;
display: block;
padding: 4px;
border: 1px solid transparent;
&:hover {
background-color: white;
.border-radius(@border-radius);
border: 1px solid #ddd;
}
}
&:first-child {
a {
background-position: -260px -92px;
}
}
&:last-child:before {
content: "\00ab";
&:last-child {
a {
background-position: -236px -92px;
}
}
}
}
Expand All @@ -411,17 +427,30 @@ h3 {
text-decoration: none;
}
}
.selector-available select {
.border-radius(0, 0, null, null);
}
.selector-filter {
margin-right: 14px;
position: relative;
margin-bottom: 1px;
margin-bottom: -1px;
input {
.border-radius(null, null, 0, 0);
}
label {
position: absolute;
right: 4px;
right: 0;
top: 4px;
margin-right: -10px;
opacity: .2;
}
}
}
.controls {
/* Special styles for django auth app */
#id_groups_from { min-height: 80px }
#id_user_permissions_from { min-height: 180px }
}

/* SELECT2 OVERRIDE */
.select2-container-multi .select2-choices {
Expand Down
14 changes: 14 additions & 0 deletions suit/static/suit/less/variables.less
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,17 @@
.bold { font-weight: bold }
.auto-width { width: auto }
.clear { clear: both; }
.hide-text { text-indent: 200%; white-space: nowrap; overflow: hidden; }
.bs-icon {
.hide-text;
display: inline-block;
width: 14px;
height: 14px;
background-image: url("../bootstrap/img/glyphicons-halflings.png");
background-position: 0 -96px;
opacity: .6;
margin: 0;
&:hover {
opacity: 1;
}
}

0 comments on commit 71211f7

Please sign in to comment.