Browse Source

feat: add table padding parameters for customizing (#5795)

pull/5675/merge
绯一 8 years ago
committed by Benjy Cui
parent
commit
80de0127f4
  1. 2
      components/style/themes/default.less
  2. 12
      components/table/style/index.less

2
components/style/themes/default.less

@ -270,6 +270,8 @@
// -- // --
@table-header-bg: @background-color-base; @table-header-bg: @background-color-base;
@table-row-hover-bg: @primary-1; @table-row-hover-bg: @primary-1;
@table-padding-vertical: 16px;
@table-padding-horizontal: 8px;
// TimePicker // TimePicker
// --- // ---

12
components/table/style/index.less

@ -75,7 +75,7 @@
} }
&-footer { &-footer {
padding: 16px 8px; padding: @table-padding-vertical @table-padding-horizontal;
background: @table-header-bg; background: @table-header-bg;
border-radius: 0 0 @border-radius-base @border-radius-base; border-radius: 0 0 @border-radius-base @border-radius-base;
position: relative; position: relative;
@ -95,7 +95,7 @@
} }
&-title { &-title {
padding: 16px 0; padding: @table-padding-vertical 0;
position: relative; position: relative;
top: 1px; top: 1px;
border-radius: @border-radius-base @border-radius-base 0 0; border-radius: @border-radius-base @border-radius-base 0 0;
@ -103,8 +103,8 @@
&.@{table-prefix-cls}-bordered &-title { &.@{table-prefix-cls}-bordered &-title {
border: @border-width-base @border-style-base @border-color-split; border: @border-width-base @border-style-base @border-color-split;
padding-left: 8px; padding-left: @table-padding-horizontal;
padding-right: 8px; padding-right: @table-padding-horizontal;
} }
&-title + &-content { &-title + &-content {
@ -135,7 +135,7 @@
&-thead > tr > th, &-thead > tr > th,
&-tbody > tr > td { &-tbody > tr > td {
padding: 16px 8px; padding: @table-padding-vertical @table-padding-horizontal;
word-break: break-all; word-break: break-all;
} }
@ -361,7 +361,7 @@
&-placeholder { &-placeholder {
position: relative; position: relative;
padding: 16px 8px; padding: @table-padding-vertical @table-padding-horizontal;
background: @component-background; background: @component-background;
border-bottom: @border-width-base @border-style-base @border-color-split; border-bottom: @border-width-base @border-style-base @border-color-split;
text-align: center; text-align: center;

Loading…
Cancel
Save