mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
MINOR Removed button styling for GridField, as its preliminary and doesn't apply to any action other than "delete"
This commit is contained in:
parent
d9538d3085
commit
b01b9b9249
@ -2,9 +2,8 @@
|
||||
.cms table.ss-gridfield { width: 100%; padding: 0; margin: 20px 0 0 0; border-collapse: separate; display: table; border-bottom: 0 none; }
|
||||
.cms table.ss-gridfield thead { color: #1d2224; background: transparent; }
|
||||
.cms table.ss-gridfield tbody { background: #FFF; }
|
||||
.cms table.ss-gridfield tbody td { /* Rounded buttons */ }
|
||||
.cms table.ss-gridfield tbody td button { border: #CC0033 solid 1px; background: #CC0033; color: #FFF; -moz-border-radius: 15px; -webkit-border-radius: 15px; -o-border-radius: 15px; -ms-border-radius: 15px; -khtml-border-radius: 15px; border-radius: 15px; margin: 0 0 0 2px; padding: 0; width: auto; min-width: 30px; height: 30px; text-shadow: none; }
|
||||
.cms table.ss-gridfield tbody td button:hover { color: #222; }
|
||||
.cms table.ss-gridfield tbody td { /* Emulate a link by default */ }
|
||||
.cms table.ss-gridfield tbody td button { border: none; background: none; margin: 0 0 0 2px; padding: 0; width: auto; text-shadow: none; }
|
||||
.cms table.ss-gridfield tfoot { color: #1d2224; }
|
||||
.cms table.ss-gridfield tfoot tr td { background: #95a5ab; padding: .7em; }
|
||||
.cms table.ss-gridfield tr.sortable-header th { background: #7f9198; }
|
||||
|
@ -36,7 +36,7 @@ class GridFieldAction_Delete implements GridField_ColumnProvider, GridField_Acti
|
||||
*/
|
||||
public function getColumnMetadata($gridField, $columnName) {
|
||||
if($columnName == 'DeleteAction') {
|
||||
return array('title' => 'Delete');
|
||||
return array('title' => '');
|
||||
}
|
||||
}
|
||||
|
||||
@ -68,7 +68,13 @@ class GridFieldAction_Delete implements GridField_ColumnProvider, GridField_Acti
|
||||
* @return string - the HTML for the column
|
||||
*/
|
||||
public function getColumnContent($gridField, $record, $columnName) {
|
||||
$field = new GridField_Action($gridField, 'DeleteRecord'.$record->ID, "x", "deleterecord", array('RecordID' => $record->ID));
|
||||
$field = new GridField_Action(
|
||||
$gridField,
|
||||
'DeleteRecord'.$record->ID,
|
||||
_t('GridAction.Delete', "delete"),
|
||||
"deleterecord",
|
||||
array('RecordID' => $record->ID)
|
||||
);
|
||||
$output = $field->Field();
|
||||
return $output;
|
||||
}
|
||||
|
@ -61,21 +61,14 @@ $gf_border_radius: 7px;
|
||||
tbody {
|
||||
background: #FFF;
|
||||
td {
|
||||
/* Rounded buttons */
|
||||
/* Emulate a link by default */
|
||||
button {
|
||||
border: #CC0033 solid 1px;
|
||||
background: #CC0033;
|
||||
color: #FFF;
|
||||
@include border-radius(15px);
|
||||
border: none;
|
||||
background: none;
|
||||
margin: 0 0 0 2px;
|
||||
padding: 0;
|
||||
width: auto;
|
||||
min-width: 30px;
|
||||
height: 30px;
|
||||
text-shadow: none;
|
||||
&:hover {
|
||||
color: #222;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user