[bugfix] BigNumber crash, Horizon indent and Myanmar geojson (#5746)

* fix myanmar geojson

* fix indent of horizon in dashboard

* Fix bignumber crash when color_picker is undefined
This commit is contained in:
Krist Wongsuphasawat 2018-08-27 15:46:52 -07:00 committed by Hugh A. Miles II
parent 8d01c84c54
commit 0781cf2cfb
3 changed files with 9 additions and 4 deletions

View File

@ -231,14 +231,17 @@ BigNumberVis.defaultProps = defaultProps;
function adaptor(slice, payload) {
const { formData, containerId } = slice;
const { data, subheader, compare_suffix: compareSuffix } = payload.data;
const { r, g, b } = formData.color_picker;
const compareLag = Number(payload.data.compare_lag);
const supportTrendline = formData.viz_type === 'big_number';
const showTrendline = supportTrendline && formData.show_trend_line;
const startYAxisAtZero = formData.start_y_axis_at_zero;
const formatValue = d3FormatPreset(formData.y_axis_format);
const bigNumber = supportTrendline ? data[data.length - 1][1] : data[0][0];
const userColor = color.rgb(r, g, b).hex();
let userColor;
if (formData.color_picker) {
const { r, g, b } = formData.color_picker;
userColor = color.rgb(r, g, b).hex();
}
let percentChange = 0;
let formattedSubheader = subheader;

View File

@ -9,9 +9,10 @@
margin: 0px;
}
.horizon-row span {
.horizon-row span.title {
position: absolute;
color: #333;
font-size: 0.8em;
margin: 0;
text-shadow: 1px 1px rgba(255, 255, 255, 0.75);
}

File diff suppressed because one or more lines are too long