Permalink
Browse files

MINOR Removed button styling for GridField, as its preliminary and do…

…esn't apply to any action other than "delete"
  • Loading branch information...
1 parent d9538d3 commit b01b9b9249729d79876097eb328aaec63875016a @chillu chillu committed Jan 9, 2012
Showing with 13 additions and 15 deletions.
  1. +2 −3 css/GridField.css
  2. +8 −2 forms/gridfield/GridFieldAction.php
  3. +3 −10 scss/GridField.scss
View

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

Oops, something went wrong.
@@ -36,7 +36,7 @@ public function getColumnAttributes($gridField, $record, $columnName) {
*/
public function getColumnMetadata($gridField, $columnName) {
if($columnName == 'DeleteAction') {
- return array('title' => 'Delete');
+ return array('title' => '');
}
}
@@ -68,7 +68,13 @@ public function getActions($gridField) {
* @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;
}
View
@@ -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;
- }
}
}
}

0 comments on commit b01b9b9

Please sign in to comment.