Permalink
Browse files

ENHANCEMENT: styled the header of the datagrid (SSF-106)

  • Loading branch information...
1 parent b389138 commit 1ebd83df1a40064d7a34ecdec5761d34c950b044 @felipesilverstripe felipesilverstripe committed Feb 22, 2012
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
@@ -894,8 +894,7 @@ form.member-profile-form {
background-color: #92a5b2;
padding: $grid-vertical/2 $grid-horizontal/2 $grid-vertical/2 $grid-horizontal*2;
border-bottom: 2px solid #8399a7;
- @include border-radius-top(4px);
- @include border-radius-bottom(0px);
+
@include background-image(linear-gradient(#ced7dc, #92a5b2));
}
}
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
@@ -75,15 +75,15 @@ class GridFieldConfig_Base extends GridFieldConfig {
* @param int $itemsPerPage - How many items per page should show up per page
* @return GridFieldConfig_Base
*/
- public static function create($itemsPerPage=25){
- return new GridFieldConfig_Base($itemsPerPage=25);
+ public static function create($itemsPerPage=15){
+ return new GridFieldConfig_Base($itemsPerPage=15);
}
/**
*
* @param int $itemsPerPage - How many items per page should show up
*/
- public function __construct($itemsPerPage=25) {
+ public function __construct($itemsPerPage=15) {
$this->addComponent(new GridFieldTitle());
$this->addComponent(new GridFieldSortableHeader());
$this->addComponent(new GridFieldFilter());
@@ -18,7 +18,7 @@ class GridFieldPaginator implements GridField_HTMLProvider, GridField_DataManipu
*
* @var int
*/
- protected $itemsPerPage = 25;
+ protected $itemsPerPage = 15;
/**
* Which template to use for rendering
@@ -31,7 +31,7 @@ class GridFieldPaginator implements GridField_HTMLProvider, GridField_DataManipu
*
* @param int $itemsPerPage - How many items should be displayed per page
*/
- public function __construct($itemsPerPage=25) {
+ public function __construct($itemsPerPage=15) {
$this->itemsPerPage = $itemsPerPage;
}
View
@@ -72,11 +72,32 @@ $gf_border_radius: 7px;
}
}
- tr {
- &.sortable-header {
+ tr {
+ &.title {
+ @include border-top-radius($gf_border_radius);
th {
+ position: relative;
background: $gf_colour_gradient_dark;
+ border-top: 1px solid $gf_colour_border;
+ color:#fff;
+ padding: 10px;
+ font-size: 18px;
+ min-height: 40px;
+ @include background-image(linear-gradient($gf_colour_gradient_light, $gf_colour_gradient_dark));
+ @include border-top-radius($gf_border_radius);
+ @include single-text-shadow($gf_colour_text_shadow, 0px, -1px, 0);
+
+ .new{
+ font-size: 14px;
+ border-color: $gf_colour_border;
+ position: absolute;
+ right: 10px;
+ top: 5px;
+ }
}
+ }
+ &.sortable-header {
+ background: $gf_colour_subheader;
}
&:hover {
background: #FFFAD6 !important;
@@ -102,10 +123,10 @@ $gf_border_radius: 7px;
padding: 5px;
border-right: 1px solid $gf_colour_border;
&.main:first-child{
- @include border-top-left-radius($gf_border_radius);
+ //@include border-top-left-radius($gf_border_radius);
}
&.main:last-child{
- @include border-top-right-radius($gf_border_radius);
+ //@include border-top-right-radius($gf_border_radius);
}
div {
&.fieldgroup,&.fieldgroup-field {
@@ -117,7 +138,6 @@ $gf_border_radius: 7px;
}
}
&.extra,&.action {
- background: $gf_colour_gradient_dark;
padding: 0;
cursor: default;
button,button:hover {
@@ -130,7 +150,8 @@ $gf_border_radius: 7px;
&.main{
border-top: 1px solid $gf_colour_border;
color:#fff;
- @include background-image(linear-gradient($gf_colour_gradient_light, $gf_colour_gradient_dark));
+ background: darken($gf_colour_subheader,10%);
+ border-bottom: 1px solid $gf_colour_border;
span{
@include single-text-shadow($gf_colour_text_shadow, 0px, -1px, 0);
}
@@ -1,3 +1,3 @@
<tr class="title">
- <th colspan="$ColumnCount">$Title <a href="$NewLink">new</a></th>
+ <th colspan="$ColumnCount">$Title <a href="$NewLink" class="action ss-ui-action-constructive ss-ui-button ui-button ui-widget ui-state-default ui-corner-all new">Add new</a></th>
</tr>

0 comments on commit 1ebd83d

Please sign in to comment.