UNPKG

@taeopia/react-table

Version:

This is a table library for use in React.

116 lines (97 loc) 2.58 kB
html[data-theme="light"] { background-color: var(--background-primary); } html[data-theme="dark"] { background-color: var(--background-primary); } .table-wrapper { width: 100%; height: 100%; } .taeopia_table { font-size: 14px; font-weight: 400; color: var(--text-primary); /* 텍스트 기본 색상 */ width: 100%; border-collapse: separate; } .taeopia_table tr.selected, .taeopia_table tr:hover:not(.disabled):not(.disable):not(.row_type2.disabled):not(.hover), .taeopia_table tr:focus, .taeopia_table tr.hover { background: var(--background-overlay); /* Hover/Selected 배경색 */ } .taeopia_table th, .taeopia_table td { text-align: center; /* 기본 가운데 정렬 */ vertical-align: middle; /* 수직 정렬 중간 */ border-right: 1px solid var(--divider-color); /* 셀 구분선 색상 */ } .taeopia_table th { position: sticky; z-index: 1; top: 0; height: 48px; background: var(--background-secondary); /* 헤더 배경색 */ padding: 8px 12px; color: var(--text-primary); /* 헤더 텍스트 색상 */ } .taeopia_table th:last-child, .taeopia_table td:last-child { border-right: none; } .taeopia_table td { height: 48px; border-bottom: 1px solid var(--divider-color); /* 행 구분선 색상 */ padding: 8px 12px; color: var(--text-secondary); /* 본문 텍스트 색상 */ } .taeopia_table td.hover { height: 48px; border-top: 2px solid transparent !important; } .taeopia_table.md th, .taeopia_table.md td { height: 45px; } .taeopia_table.md td { padding: 4px 12px; } .taeopia_table.vertical { border-top: 1px solid var(--divider-color); } .taeopia_table.vertical tr:hover, .taeopia_table.vertical tr:focus { background: transparent !important; } .taeopia_table.vertical th { width: 120px; text-align: left; border-right: none; border-bottom: 1px solid var(--divider-color); } .taeopia_table.sm th { height: 40px; background: transparent; border-top: 1px solid var(--divider-color); border-bottom: 1px solid var(--divider-color); } .taeopia_table.sm td { height: 40px; padding: 4px 12px; } .taeopia_table_title { font-size: 16px; font-weight: 700; color: var(--primary-color); /* 제목 색상 */ } .taeopia_table thead th { background-color: var(--background-secondary); font-weight: 500; border-right: none; } .taeopia_table tbody td:not(.disabled), .taeopia_table tbody td:not(.hover) { line-height: 1.2; border-right: none; }