mirror of
https://github.com/FlipsideCrypto/flipside-js.git
synced 2026-02-06 10:48:11 +00:00
Add ability to customize row and header style attribute on multi-table widget.
This commit is contained in:
parent
b8abd9203f
commit
f4e0da2d8d
17
index.html
17
index.html
@ -152,12 +152,19 @@
|
||||
fontFamily: "inherit",
|
||||
limit: 50,
|
||||
mode: "light",
|
||||
headers: {
|
||||
style: {
|
||||
fontWeight: "bold",
|
||||
padding: "10px 0 10px 0"
|
||||
}
|
||||
},
|
||||
rows: {
|
||||
dividers: true,
|
||||
dividersColor: "#eaeaea",
|
||||
alternating: false,
|
||||
padding: "10px 0 10px 0",
|
||||
headerBold: true
|
||||
style: {
|
||||
padding: "10px 0 10px 0"
|
||||
}
|
||||
},
|
||||
title: {
|
||||
text: "Top 50 Coins By Market Cap",
|
||||
@ -185,8 +192,10 @@
|
||||
rows: {
|
||||
alternating: true,
|
||||
alternatingColors: "#eeeeee",
|
||||
dividers: false,
|
||||
style: {}
|
||||
dividers: false
|
||||
// style: {
|
||||
// padding: "5px 10px"
|
||||
// }
|
||||
},
|
||||
title: {
|
||||
text: "Top Coins",
|
||||
|
||||
@ -187,8 +187,7 @@ export default class MultiTable extends Component<Props, State> {
|
||||
alternatingColors: [],
|
||||
dividers: false,
|
||||
dividersColor: null,
|
||||
padding: "5px 10px",
|
||||
headerBold: false
|
||||
style: {}
|
||||
},
|
||||
trend: {
|
||||
changeOver: 7
|
||||
@ -272,10 +271,7 @@ export default class MultiTable extends Component<Props, State> {
|
||||
<th
|
||||
class={classes}
|
||||
onClick={() => this.handleClickSort(col)}
|
||||
style={{
|
||||
padding: props.rows.padding,
|
||||
fontWeight: props.rows.headerBold ? "bold" : "normal"
|
||||
}}
|
||||
style={props.headers.style}
|
||||
>
|
||||
<div class="fs-multi-colhead" style={props.headers.style}>
|
||||
{column.sortKey && (
|
||||
@ -305,7 +301,7 @@ export default class MultiTable extends Component<Props, State> {
|
||||
class={`fs-multi-${col}`}
|
||||
style={{
|
||||
borderBottom: `1px solid ${props.rows.dividersColor}`,
|
||||
padding: props.rows.padding
|
||||
...props.rows.style
|
||||
}}
|
||||
>
|
||||
{COLUMNS[col].renderItem(asset)}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user