UNPKG

jquery.tabulator

Version:

Interactive table generation plugin for jQuery UI

346 lines (345 loc) 10.3 kB
.tabulator { position: relative; border: 1px solid #999; background-color: #888; font-size: 14px; text-align: left; overflow: hidden; } .tabulator .tabulator-header { position: relative; box-sizing: border-box; width: 100%; border-bottom: 1px solid #999; background-color: #e6e6e6; color: #555; font-weight: bold; white-space: nowrap; overflow: hidden; -moz-user-select: none; -khtml-user-select: none; -webkit-user-select: none; -o-user-select: none; } .tabulator .tabulator-header .tabulator-col { display: inline-block; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content { position: relative; padding: 4px; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content .tabulator-col-title { width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content .tabulator-col-title .tabulator-title-editor { box-sizing: border-box; width: 100%; border: 1px solid #999; padding: 1px; background: #fff; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content .tabulator-arrow { display: inline-block; position: absolute; top: 9px; right: 8px; width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-bottom: 6px solid #bbb; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content .tabulator-arrow.asc { border-top: none; border-bottom: 6px solid #666; } .tabulator .tabulator-header .tabulator-col .tabulator-col-content .tabulator-arrow.desc { border-top: 6px solid #666; border-bottom: none; } .tabulator .tabulator-header .tabulator-col .tabulator-handle { position: absolute; right: 0; top: 0; bottom: 0; width: 5px; } .tabulator .tabulator-header .tabulator-col .tabulator-handle.prev { left: 0; right: auto; } .tabulator .tabulator-header .tabulator-col .tabulator-handle:hover { cursor: ew-resize; } .tabulator .tabulator-header .tabulator-col.tabulator-col-group .tabulator-col-group-cols { position: relative; display: flex; border-top: 1px solid #aaa; overflow: hidden; } .tabulator .tabulator-header .tabulator-col.tabulator-col-group .tabulator-col-group-cols .tabulator-col:last-child { margin-right: -1px; } .tabulator .tabulator-header .tabulator-col:first-child .tabulator-handle.prev { display: none; } .tabulator .tabulator-header .tabulator-col.ui-sortable-helper { position: absolute; background-color: #e6e6e6 !important; border: 1px solid #aaa; } .tabulator .tabulator-header .tabulator-col .tabulator-header-filter { position: relative; box-sizing: border-box; margin-top: 2px; width: 100%; text-align: center; } .tabulator .tabulator-header .tabulator-col .tabulator-header-filter textarea { height: auto !important; } .tabulator .tabulator-header .tabulator-col .tabulator-header-filter svg { margin-top: 3px; } .tabulator .tabulator-header .tabulator-col[data-sortable=true] .tabulator-col-title { width: calc(100% - 25px); } .tabulator .tabulator-header .tabulator-col[data-sortable=true]:hover { cursor: pointer; background-color: rgba(0, 0, 0, 0.1); } .tabulator .tabulator-header .tabulator-col-row-handle { width: 30px; max-width: 30px; display: inline-block; } .tabulator .tabulator-header .tabulator-col, .tabulator .tabulator-header .tabulator-col-row-handle { position: relative; box-sizing: border-box; border-right: 1px solid #aaa; text-align: left; vertical-align: bottom; overflow: hidden; } .tabulator .tabulator-header .tabulator-frozen { display: inline-block; position: absolute; background-color: inherit; z-index: 10; } .tabulator .tabulator-header .tabulator-frozen.tabulator-frozen-left { border-right: 1px solid #aaa; } .tabulator .tabulator-header .tabulator-frozen.tabulator-frozen-right { border-left: 2px solid #aaa; } .tabulator .tabulator-tableHolder { position: relative; width: 100%; white-space: nowrap; overflow: auto; -webkit-overflow-scrolling: touch; } .tabulator .tabulator-tableHolder .tabulator-table { position: relative; display: inline-block; background-color: #fff; white-space: nowrap; overflow: visible; color: #333; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row { position: relative; box-sizing: border-box; min-height: 22px; background-color: #fff; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row:nth-child(even) { background-color: #EFEFEF; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row.tabulator-selectable:hover { background-color: #bbb; cursor: pointer; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row.tabulator-selected { background-color: #9ABCEA; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row.tabulator-selected:hover { background-color: #769BCC; cursor: pointer; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row.tabulator-row-moving { border: 1px solid #000; background: #fff; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-row-handle { display: inline-block; box-sizing: border-box; width: 30px; max-width: 30px; padding: 4px; border-right: 1px solid #aaa; text-align: center; vertical-align: middle; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-row-handle:hover { cursor: move; background-color: rgba(0, 0, 0, 0.1); } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-row-handle div { width: 80%; height: 3px; margin: 2px 10% 0 10%; background: #666; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-frozen { display: inline-block; position: absolute; background-color: inherit; z-index: 10; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-frozen.tabulator-frozen-left { border-right: 1px solid #aaa; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-frozen.tabulator-frozen-right { border-left: 2px solid #aaa; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-cell { position: relative; box-sizing: border-box; padding: 4px; border-right: 1px solid #aaa; vertical-align: middle; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-cell.tabulator-editing { border: 1px solid #1D68CD; padding: 0; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-cell.tabulator-editing input, .tabulator .tabulator-tableHolder .tabulator-table .tabulator-row .tabulator-cell.tabulator-editing select { border: 1px; background: transparent; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group.show .tabulator-group-header .tabulator-arrow { margin-left: 5px; margin-right: 10px; border-left: 6px solid transparent; border-right: 6px solid transparent; border-top: 6px solid #666; border-bottom: 0; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group.show .tabulator-group-body { visibility: visible; height: auto; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group .tabulator-group-header { box-sizing: border-box; border-bottom: 1px solid #999; border-right: 1px solid #aaa; border-top: 1px solid #999; padding: 5px; background: #ccc; font-weight: bold; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group .tabulator-group-header .tabulator-arrow { display: inline-block; width: 0; height: 0; margin-left: 8px; margin-right: 13px; border-top: 6px solid transparent; border-bottom: 6px solid transparent; border-right: 0; border-left: 6px solid #666; vertical-align: middle; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group .tabulator-group-header .tabulator-arrow:hover { cursor: pointer; background-color: rgba(0, 0, 0, 0.1); } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group .tabulator-group-header span { margin-left: 10px; color: #d00; } .tabulator .tabulator-tableHolder .tabulator-table .tabulator-group .tabulator-group-body { visibility: hidden; height: 0; } .tabulator .tabulator-footer { padding: 5px 10px; border-top: 1px solid #999; background-color: #e6e6e6; text-align: right; color: #555; font-weight: bold; white-space: nowrap; user-select: none; -moz-user-select: none; -khtml-user-select: none; -webkit-user-select: none; -o-user-select: none; } .tabulator .tabulator-footer .tabulator-pages { margin: 0 7px; } .tabulator .tabulator-footer .tabulator-page { display: inline-block; margin: 0 2px; border: 1px solid #aaa; border-radius: 3px; padding: 2px 5px; background: rgba(255, 255, 255, 0.2); color: #555; } .tabulator .tabulator-footer .tabulator-page.active { color: #d00; } .tabulator .tabulator-footer .tabulator-page.disabled { opacity: .5; } .tabulator .tabulator-footer .tabulator-page:not(.disabled):hover { cursor: pointer; background: rgba(0, 0, 0, 0.2); color: #fff; } .tabulator .tablulator-loader { position: absolute; top: 0; left: 0; z-index: 100; height: 100%; width: 100%; background: rgba(0, 0, 0, 0.4); text-align: center; } .tabulator .tablulator-loader .tabulator-loader-msg .tabulator-loading { display: inline-block; border: 4px solid #333; border-radius: 10px; padding: 10px 20px; background: #fff; font-weight: bold; font-size: 16px; color: #000; } .tabulator .tablulator-loader .tabulator-loader-msg .tabulator-error { display: inline-block; border: 4px solid #D00; border-radius: 10px; padding: 10px 20px; background: #fff; font-weight: bold; font-size: 16px; color: #590000; }