We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 987ac76 commit d1f9f0bCopy full SHA for d1f9f0b
src/components/table.tsx
@@ -56,7 +56,7 @@ class Table extends React.Component<{ id: string }, DataState> {
56
<tr key={row.get("id")}>
57
{this.state.cols.map(col => {
58
return (
59
- <td>{row.get(col)}</td>
+ <td className={typeof row.get(col) == "number" ? "num" : ""}>{row.get(col)}</td>
60
)
61
})}
62
</tr>
@@ -70,9 +70,9 @@ class Table extends React.Component<{ id: string }, DataState> {
70
<table className="notion-table">
71
<thead>
72
<tr key={this.state.id}>
73
- {this.state.cols.map(col => {
+ {this.state.cols.map((col, i) => {
74
75
- <th>{col.replace(/([0-9]+\ )/, "")}</th>
+ <th key={i}>{col.replace(/([0-9]+\ )/, "")}</th>
76
77
78
0 commit comments