Removing Table Borders

From Edgar BV Wiki
Revision as of 21:44, 9 April 2014 by Red (talk | contribs) (Created page with "See https://drupal.org/node/93357 - the core adds table tops!!! So you need to specify somewhere in your CSS: <pre> tbody { border-top: 0; } </pre> Other options you might ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

See https://drupal.org/node/93357 - the core adds table tops!!! So you need to specify somewhere in your CSS:

tbody {
  border-top: 0;
}

Other options you might want to look at are specifying the following file in your themename.info file

stylesheets[all][] = css/tables.css

tables.css

/* Tables */
table {
  border-collapse: collapse;
  border-width: 0;
  margin: 1em 0;
  width: 100%;
}
th {
  font-weight: 600;
  text-align: left;
}
th, td {
  border-width: 0;
  padding: 0.5em;
  vertical-align: top;
}
thead th:last-child,
tr td:last-child {
  border-right: 0;
}
table .form-item,
table p {
  margin: 0;
}
/**
 * Webkit work-around
 */
tr td:last-child {
  border-right: 0;
}