@popmenu/dashboard 0.50.0 → 0.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/index.es.js +21 -2
- package/build/index.es.js.map +1 -1
- package/build/index.js +21 -2
- package/build/index.js.map +1 -1
- package/package.json +2 -2
package/build/index.js
CHANGED
|
@@ -908,6 +908,24 @@ function SvgTrendDown(props) {
|
|
|
908
908
|
}))));
|
|
909
909
|
}
|
|
910
910
|
|
|
911
|
+
var _path$a;
|
|
912
|
+
|
|
913
|
+
function _extends$G() { _extends$G = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$G.apply(this, arguments); }
|
|
914
|
+
|
|
915
|
+
function SvgGitCommit(props) {
|
|
916
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$G({
|
|
917
|
+
viewBox: "0 0 16 16",
|
|
918
|
+
fill: "none",
|
|
919
|
+
strokeLinecap: "round",
|
|
920
|
+
strokeLinejoin: "round",
|
|
921
|
+
width: "1em",
|
|
922
|
+
height: "1em"
|
|
923
|
+
}, props), _path$a || (_path$a = /*#__PURE__*/React__namespace.createElement("path", {
|
|
924
|
+
d: "M8 10.667a2.667 2.667 0 100-5.334 2.667 2.667 0 000 5.334zM.7 8h3.967m6.673 0h3.966",
|
|
925
|
+
stroke: "currentColor"
|
|
926
|
+
})));
|
|
927
|
+
}
|
|
928
|
+
|
|
911
929
|
var useLeaderboardStyles = core.makeStyles(function (theme) { return ({
|
|
912
930
|
root: {
|
|
913
931
|
'& >:nth-child(even) > li': {
|
|
@@ -1072,8 +1090,8 @@ var defaultProps = {
|
|
|
1072
1090
|
var KpiMetric = function (props) {
|
|
1073
1091
|
var KpiIcon = props.Icon, metric = props.metric, value = props.value, trend = props.trend, trendMessage = props.trendMessage, trendStatus = props.trendStatus;
|
|
1074
1092
|
var classes = useKpiMetricStyles(props);
|
|
1075
|
-
var trendColors = trendStatus === 'natural' ? ['success', 'warning'] : ['warning', 'success'];
|
|
1076
|
-
var trendColorMap = { up: 0, down: 1, level:
|
|
1093
|
+
var trendColors = trendStatus === 'natural' ? ['success', 'warning', 'grey.500'] : ['warning', 'success', 'grey.500'];
|
|
1094
|
+
var trendColorMap = { up: 0, down: 1, level: 2 };
|
|
1077
1095
|
return (React__default['default'].createElement(core.Box, { className: classes.root },
|
|
1078
1096
|
KpiIcon && (React__default['default'].createElement(core.Box, { className: classes.iconContainer },
|
|
1079
1097
|
React__default['default'].createElement(Icon, { icon: KpiIcon, size: "inherit" }))),
|
|
@@ -1082,6 +1100,7 @@ var KpiMetric = function (props) {
|
|
|
1082
1100
|
trendMessage && (React__default['default'].createElement(Typography, { style: { fontSize: 'inherit' }, variant: "body2", color: trend ? trendColors[trendColorMap[trend]] : 'grey.500' },
|
|
1083
1101
|
trend === 'up' && React__default['default'].createElement(Icon, { className: classes.trendIcon, icon: SvgTrend, size: "inherit" }),
|
|
1084
1102
|
trend === 'down' && React__default['default'].createElement(Icon, { className: classes.trendIcon, icon: SvgTrendDown, size: "inherit" }),
|
|
1103
|
+
trend === 'level' && React__default['default'].createElement(Icon, { className: classes.trendIcon, icon: SvgGitCommit, size: "inherit" }),
|
|
1085
1104
|
trendMessage))));
|
|
1086
1105
|
};
|
|
1087
1106
|
KpiMetric.defaultProps = defaultProps;
|