mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-03-13 19:13:46 +00:00
Enabled stickiness on footer
This commit is contained in:
@@ -3,6 +3,7 @@ import { Doughnut, HorizontalBar } from 'react-chartjs-2';
|
|||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { keys, values } from 'ramda';
|
import { keys, values } from 'ramda';
|
||||||
|
import './GraphCard.scss';
|
||||||
|
|
||||||
const propTypes = {
|
const propTypes = {
|
||||||
title: PropTypes.oneOfType([ PropTypes.string, PropTypes.node ]),
|
title: PropTypes.oneOfType([ PropTypes.string, PropTypes.node ]),
|
||||||
@@ -66,7 +67,7 @@ const GraphCard = ({ title, footer, isBarChart, stats, max, redraw = false }) =>
|
|||||||
<Card className="mt-4">
|
<Card className="mt-4">
|
||||||
<CardHeader className="graph-card__header">{title}</CardHeader>
|
<CardHeader className="graph-card__header">{title}</CardHeader>
|
||||||
<CardBody>{renderGraph(title, isBarChart, stats, max, redraw)}</CardBody>
|
<CardBody>{renderGraph(title, isBarChart, stats, max, redraw)}</CardBody>
|
||||||
{footer && <CardFooter>{footer}</CardFooter>}
|
{footer && <CardFooter className="graph-card__footer--sticky">{footer}</CardFooter>}
|
||||||
</Card>
|
</Card>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
4
src/visits/GraphCard.scss
Normal file
4
src/visits/GraphCard.scss
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
.graph-card__footer--sticky {
|
||||||
|
position: sticky;
|
||||||
|
bottom: 0;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user