(webview: Webview, file: string)
| 389 | } |
| 390 | |
| 391 | export async function getTableHtml(webview: Webview, file: string): Promise<string> { |
| 392 | resDir = isGuestSession ? guestResDir : resDir; |
| 393 | const pageSize = config().get<number>('session.data.pageSize', 500); |
| 394 | const content = await readContent(file, 'utf8'); |
| 395 | return ` |
| 396 | <!DOCTYPE html> |
| 397 | <html lang="en"> |
| 398 | <head> |
| 399 | <meta charset="utf-8"> |
| 400 | <meta name="viewport" content="width=device-width, initial-scale=1"> |
| 401 | <style media="only screen"> |
| 402 | html, body { |
| 403 | height: 100%; |
| 404 | width: 100%; |
| 405 | margin: 0; |
| 406 | box-sizing: border-box; |
| 407 | -webkit-overflow-scrolling: touch; |
| 408 | } |
| 409 | |
| 410 | html { |
| 411 | position: absolute; |
| 412 | top: 0; |
| 413 | left: 0; |
| 414 | padding: 0; |
| 415 | overflow: auto; |
| 416 | } |
| 417 | |
| 418 | body { |
| 419 | padding: 0; |
| 420 | overflow: auto; |
| 421 | } |
| 422 | |
| 423 | /* Styling for wrapper and header */ |
| 424 | |
| 425 | [class*="vscode"] div.ag-root-wrapper { |
| 426 | background-color: var(--vscode-editor-background); |
| 427 | } |
| 428 | |
| 429 | [class*="vscode"] div.ag-header { |
| 430 | background-color: var(--vscode-sideBar-background); |
| 431 | } |
| 432 | |
| 433 | [class*="vscode"] div.ag-header-cell[aria-sort="ascending"], div.ag-header-cell[aria-sort="descending"] { |
| 434 | color: var(--vscode-textLink-activeForeground); |
| 435 | } |
| 436 | |
| 437 | /* Styling for rows and cells */ |
| 438 | |
| 439 | [class*="vscode"] div.ag-row { |
| 440 | color: var(--vscode-editor-foreground); |
| 441 | } |
| 442 | |
| 443 | [class*="vscode"] .ag-row-hover { |
| 444 | background-color: var(--vscode-list-hoverBackground) !important; |
| 445 | color: var(--vscode-list-hoverForeground); |
| 446 | } |
| 447 | |
| 448 | [class*="vscode"] .ag-row-selected { |
no test coverage detected