UNPKG

chowa

Version:

UI component library based on React

347 lines (296 loc) 8.02 kB
/** * @license chowa v1.1.3 * * Copyright (c) Chowa Techonlogies Co.,Ltd.(http://www.chowa.cn). * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ @keyframes cw-slide-down { 0% { max-height: 0; } 100% { max-height: 666px; } } .cw-slide-down-enter { animation-name: cw-slide-down; } .cw-slide-down-leave { animation-name: cw-slide-down; animation-direction: reverse; } .cw-slide-down-appear { animation-duration: 0.2s; animation-timing-function: ease-in; transform-origin: top; overflow-y: hidden; } .cw-table-wrapper { margin: 0; padding: 12px 0; box-sizing: border-box; color: #616a6e; } .cw-table { margin: 0; padding: 0; overflow: hidden; position: relative; border-left: 1px solid transparent; border-right: 1px solid transparent; font-size: 14px; } .cw-table table { min-width: 100%; width: auto; border-spacing: 0; margin: 0; padding: 0; box-sizing: border-box; border-collapse: collapse; text-align: left; } .cw-table tbody, .cw-table tfoot, .cw-table thead, .cw-table tr { box-sizing: border-box; } .cw-table tr { transition: background-color 0.2s ease-in-out; } .cw-table td, .cw-table th { margin: 0; padding: 12px 16px; min-width: 80px; line-height: 1.5; box-sizing: border-box; position: relative; } .cw-table-small { font-size: 12px; } .cw-table-small td, .cw-table-small th { padding: 8px 12px; } .cw-table-large td, .cw-table-large th { padding: 16px 20px; } .cw-table-header-wrapper { margin: 0; padding: 0; box-sizing: border-box; overflow: hidden; font-weight: 500; border-top-left-radius: 3px; border-top-right-radius: 3px; border-bottom: 1px solid #e6ecf5; } .cw-table-body-wrapper { margin: 0; padding: 0; box-sizing: border-box; overflow: hidden; border-radius: 3px; border-top: 1px solid #e6ecf5; border-bottom: 1px solid #e6ecf5; } .cw-table-body-wrapper tr:not(:first-child) td { border-top: 1px solid #e6ecf5; } .cw-table-footer-wrapper { margin: 0; padding: 0; box-sizing: border-box; overflow: hidden; border-bottom-left-radius: 3px; border-bottom-right-radius: 3px; } .cw-table-fixed { margin: 0; padding: 0; box-sizing: border-box; position: absolute; top: 0; bottom: 0; z-index: 10; background-color: #fff; overflow: hidden; border-bottom: 1px solid #e6ecf5; display: none; } .cw-table-fixed-active { display: block; } .cw-table-fixed-header-wrapper { margin: 0; padding: 0; box-sizing: border-box; border-bottom: 1px solid #e6ecf5; } .cw-table-fixed-body-wrapper { overflow: hidden; } .cw-table-fixed-body-wrapper tr:not(:first-child) td { border-top: 1px solid #e6ecf5; } .cw-table-fixed-left { left: 0; border-top-left-radius: 3px; border-bottom-left-radius: 3px; box-shadow: 6px 0 6px -4px rgba(0, 0, 0, 0.15); } .cw-table-fixed-left.cw-table-fixed-with-footer { border-bottom-left-radius: 0; } .cw-table-fixed-right { right: 0; border-top-right-radius: 3px; border-bottom-right-radius: 3px; box-shadow: -6px 0 6px -4px rgba(0, 0, 0, 0.15); } .cw-table-bordered { border-left-color: #e6ecf5; border-right-color: #e6ecf5; border-radius: 3px; } .cw-table-bordered .cw-table-header-wrapper, .cw-table-bordered .cw-table-fixed-header-wrapper { border-top: 1px solid #e6ecf5; } .cw-table-bordered .cw-table-header-wrapper tr:not(:first-child) th, .cw-table-bordered .cw-table-fixed-header-wrapper tr:not(:first-child) th { border-top: 1px solid #e6ecf5; } .cw-table-bordered .cw-table-header-wrapper th:not(:last-child), .cw-table-bordered .cw-table-fixed-header-wrapper th:not(:last-child) { border-right: 1px solid #e6ecf5; } .cw-table-bordered .cw-table-body-wrapper td:not(:last-child), .cw-table-bordered .cw-table-fixed-body-wrapper td:not(:last-child) { border-right: 1px solid #e6ecf5; } .cw-table-bordered .cw-table-footer-wrapper { border-bottom: 1px solid #e6ecf5; } .cw-table-with-header .cw-table-body-wrapper { border-top-left-radius: 0; border-top-right-radius: 0; border-top-width: 0; } .cw-table-with-footer .cw-table-body-wrapper { border-bottom-left-radius: 0; border-bottom-right-radius: 0; } .cw-table-align-center { text-align: center; } .cw-table-align-right { text-align: right; } .cw-table-cell-resize { position: absolute; width: 8px; top: 0; right: -4px; bottom: 0; cursor: col-resize; z-index: 1; } th.cw-table-cloumn-with-filter, th.cw-table-cloumn-with-sort { padding-right: 22px; } th.cw-table-cloumn-with-filter.cw-table-cloumn-with-sort { padding-right: 44px; } th.cw-table-cloumn-with-filter.cw-table-cloumn-with-sort .cw-table-sort { right: 22px; } .cw-table-filter { position: absolute; top: 0; right: 0; bottom: 0; width: 22px; font-weight: 400; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.2s ease-in-out; } .cw-table-filter.cw-table-filter-active, .cw-table-filter:hover { background-color: #f7f6fe; color: #7774e7; } .cw-table-filter-menu { margin: 0; padding: 8px 12px; box-sizing: border-box; } .cw-table-filter-handler { display: flex; flex-direction: row; align-items: center; justify-content: space-between; padding: 0; margin: 8px 0 0 0; } .cw-table-filtered { color: #7774e7; } .cw-table-sort { position: absolute; top: 0; right: 0; bottom: 0; width: 22px; font-weight: 400; display: flex; flex-direction: column; align-items: center; justify-content: center; } .cw-table-sort-btn { width: 14px; height: 14px; margin: 0; padding: 0; cursor: pointer; position: relative; } .cw-table-sort-btn:before { content: ''; position: absolute; right: 3px; box-sizing: border-box; border: 4px solid transparent; } .cw-table-sort-btn + .cw-table-sort-btn { margin-top: 4px; } .cw-table-sort-asc:before { bottom: 0; border-bottom-color: #616a6e; } .cw-table-sort-asc.cw-table-sorted:before { border-bottom-color: #7774e7; } .cw-table-sort-desc:before { top: 0; border-top-color: #616a6e; } .cw-table-sort-desc.cw-table-sorted:before { border-top-color: #7774e7; } .cw-table-expanded-btn { margin: 0; padding: 4px 8px; box-sizing: border-box; color: #2d8cf0; transition: color 0.2s ease-in; cursor: pointer; text-decoration: none; } .cw-table-expanded-btn:hover { color: #57a3f3; } .cw-table-dark-row { background-color: #f8f8f8; } .cw-table-highlight-row { background-color: #f7f6fe; } .cw-table-expanded-row td { margin: 0; padding: 0; } .cw-table-expanded-wrapper { margin: 0; padding: 0; box-sizing: border-box; overflow: hidden; position: relative; } .cw-table-expanded { margin: 0; padding: 8px 12px; box-sizing: border-box; } .cw-table-base { margin: 0; padding: 0; box-sizing: border-box; } .cw-table-scroll-x { overflow-x: auto; overflow-y: hidden; } .cw-table-fixed-header .cw-table-header-wrapper, .cw-table-fixed-header .cw-table-footer-wrapper, .cw-table-fixed-header .cw-table-body-wrapper, .cw-table-fixed-header .cw-table-fixed-header-wrapper, .cw-table-fixed-header .cw-table-fixed-body-wrapper { overflow-x: hidden; overflow-y: scroll; } .cw-table-checkbox { line-height: 16px; height: 16px; } .cw-table-checkbox .cw-checkbox { margin-top: 0; } .cw-table-draggable .cw-table-header-wrapper th, .cw-table-draggable .cw-table-body-wrapper tr { cursor: move; } .cw-table-dragging { background-color: #f7f6fe; } .cw-table-drop-over-up { border-top: 2px dashed #7774e7 !important; } .cw-table-drop-over-down { border-bottom: 2px dashed #7774e7 !important; } .cw-table-drop-over-left { border-left: 2px dashed #7774e7 !important; } .cw-table-drop-over-right { border-right: 2px dashed #7774e7 !important; }