From 6256c3908f7e04a7cce07c0d2862a13418944fa5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=87=E5=A4=A9?= Date: Fri, 8 May 2020 20:43:01 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=9E=84=E8=A1=A8=E6=A0=BC=E7=BB=84?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/table/index.wc | 137 ++++++++++++++++++++------------------------- src/table/item.wc | 21 ------- src/table/td.wc | 67 ++++++++++++++++++++++ src/table/tr.wc | 28 +++++++++ 4 files changed, 156 insertions(+), 97 deletions(-) delete mode 100644 src/table/item.wc create mode 100644 src/table/td.wc create mode 100644 src/table/tr.wc diff --git a/src/table/index.wc b/src/table/index.wc index 0e7b79e..e696e71 100644 --- a/src/table/index.wc +++ b/src/table/index.wc @@ -1,7 +1,7 @@ @@ -10,7 +10,6 @@ :host { display: flex; width: 100%; - height: 100%; color: nth($cd, 1); } ul, @@ -23,16 +22,12 @@ li { flex-direction: column; width: 100%; height: 100%; - border-top: 1px solid nth($cp, 3); - border-left: 1px solid nth($cp, 3); - - ul { - width: 100%; - } + border: 1px solid nth($cp, 3); + border-right: 0; .thead, .tfoot { - // height: 40px; + width: 100%; background: nth($cp, 1); user-select: none; -moz-user-select: none; @@ -49,116 +44,106 @@ li { min-height: 36px; border-right: 1px solid nth($cp, 3); border-bottom: 1px solid nth($cp, 3); + + &.flex-2 { + flex: 2; + } + &.flex-3 { + flex: 3; + } + &.flex-4 { + flex: 4; + } + &.flex-5 { + flex: 5; + } + &.flex-6 { + flex: 6; + } + &.flex-7 { + flex: 7; + } + &.flex-8 { + flex: 8; + } } .thead .td { justify-content: center; text-align: center; } - .tbody .tr:hover { - background-color: #fbfbfb; - } .cell { padding: 3px 5px; + word-wrap: break-word; + word-break: break-all; } } diff --git a/src/table/td.wc b/src/table/td.wc new file mode 100644 index 0000000..3b2d69c --- /dev/null +++ b/src/table/td.wc @@ -0,0 +1,67 @@ + + + + + diff --git a/src/table/tr.wc b/src/table/tr.wc new file mode 100644 index 0000000..1940efc --- /dev/null +++ b/src/table/tr.wc @@ -0,0 +1,28 @@ + + + + +