|
14 | 14 | * limitations under the License. |
15 | 15 | */ |
16 | 16 |
|
17 | | -.bigframes-widget { |
| 17 | +/* Increase specificity to override framework styles without !important */ |
| 18 | +.bigframes-widget.bigframes-widget { |
18 | 19 | /* Default Light Mode Variables */ |
19 | 20 | --bf-bg: white; |
20 | 21 | --bf-border-color: #ccc; |
|
27 | 28 | --bf-row-even-bg: #f5f5f5; |
28 | 29 | --bf-row-odd-bg: white; |
29 | 30 |
|
30 | | - background-color: var(--bf-bg) !important; |
| 31 | + background-color: var(--bf-bg); |
31 | 32 | box-sizing: border-box; |
32 | | - color: var(--bf-fg) !important; |
| 33 | + color: var(--bf-fg); |
33 | 34 | display: flex; |
34 | 35 | flex-direction: column; |
35 | 36 | font-family: |
36 | 37 | "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", sans-serif; |
37 | | - margin: 0 !important; |
38 | | - padding: 0 !important; |
| 38 | + margin: 0; |
| 39 | + padding: 0; |
39 | 40 | } |
40 | 41 |
|
41 | 42 | .bigframes-widget * { |
|
44 | 45 |
|
45 | 46 | /* Dark Mode Overrides via Media Query */ |
46 | 47 | @media (prefers-color-scheme: dark) { |
47 | | - .bigframes-widget { |
| 48 | + .bigframes-widget.bigframes-widget { |
48 | 49 | --bf-bg: var(--vscode-editor-background, #202124); |
49 | 50 | --bf-border-color: #444; |
50 | 51 | --bf-error-bg: #511; |
|
123 | 124 | margin-right: 8px; |
124 | 125 | } |
125 | 126 |
|
126 | | -.bigframes-widget table, |
| 127 | +.bigframes-widget table.bigframes-widget-table, |
127 | 128 | .bigframes-widget table.dataframe { |
128 | | - background-color: var(--bf-bg) !important; |
129 | | - /* Explicitly override border="1" defaults */ |
130 | | - border: 1px solid var(--bf-border-color) !important; |
131 | | - border-collapse: collapse !important; |
132 | | - border-spacing: 0 !important; |
133 | | - box-shadow: none !important; |
134 | | - color: var(--bf-fg) !important; |
135 | | - margin: 0 !important; |
136 | | - outline: none !important; |
| 129 | + background-color: var(--bf-bg); |
| 130 | + border: 1px solid var(--bf-border-color); |
| 131 | + border-collapse: collapse; |
| 132 | + border-spacing: 0; |
| 133 | + box-shadow: none; |
| 134 | + color: var(--bf-fg); |
| 135 | + margin: 0; |
| 136 | + outline: none; |
137 | 137 | text-align: left; |
138 | | - width: auto !important; /* Fix stretching */ |
| 138 | + width: auto; /* Fix stretching */ |
139 | 139 | } |
140 | 140 |
|
141 | 141 | .bigframes-widget tr { |
142 | | - border: none !important; |
| 142 | + border: none; |
143 | 143 | } |
144 | 144 |
|
145 | 145 | .bigframes-widget th { |
146 | | - background-color: var(--bf-header-bg) !important; |
147 | | - border: 1px solid var(--bf-border-color) !important; |
148 | | - color: var(--bf-fg) !important; |
| 146 | + background-color: var(--bf-header-bg); |
| 147 | + border: 1px solid var(--bf-border-color); |
| 148 | + color: var(--bf-fg); |
149 | 149 | padding: 0; |
150 | 150 | position: sticky; |
151 | 151 | text-align: left; |
|
154 | 154 | } |
155 | 155 |
|
156 | 156 | .bigframes-widget td { |
157 | | - border: 1px solid var(--bf-border-color) !important; |
158 | | - color: var(--bf-fg) !important; |
| 157 | + border: 1px solid var(--bf-border-color); |
| 158 | + color: var(--bf-fg); |
159 | 159 | padding: 0.5em; |
160 | 160 | } |
161 | 161 |
|
162 | 162 | .bigframes-widget table tbody tr:nth-child(odd), |
163 | 163 | .bigframes-widget table tbody tr:nth-child(odd) td { |
164 | | - background-color: var(--bf-row-odd-bg) !important; |
| 164 | + background-color: var(--bf-row-odd-bg); |
165 | 165 | } |
166 | 166 |
|
167 | 167 | .bigframes-widget table tbody tr:nth-child(even), |
168 | 168 | .bigframes-widget table tbody tr:nth-child(even) td { |
169 | | - background-color: var(--bf-row-even-bg) !important; |
| 169 | + background-color: var(--bf-row-even-bg); |
170 | 170 | } |
171 | 171 |
|
172 | 172 | .bigframes-widget .bf-header-content { |
|
229 | 229 | } |
230 | 230 |
|
231 | 231 | .bigframes-widget .debug-info { |
232 | | - border-top: 1px solid var(--bf-border-color) !important; |
| 232 | + border-top: 1px solid var(--bf-border-color); |
233 | 233 | } |
0 commit comments