Commit af8f6ed8 authored by Brandon Labuschagne's avatar Brandon Labuschagne

Merge branch '351909-refactor-milestone-burndown-chart-responsiveness' into 'master'

Refactor milestone burndown chart responsiveness

See merge request gitlab-org/gitlab!81181
parents 61db02c2 5979d893
<script> <script>
import { GlResizeObserverDirective as GlResizeObserver } from '@gitlab/ui';
import { GlLineChart } from '@gitlab/ui/dist/charts'; import { GlLineChart } from '@gitlab/ui/dist/charts';
import dateFormat from 'dateformat'; import dateFormat from 'dateformat';
import { merge } from 'lodash'; import { merge } from 'lodash';
...@@ -7,9 +6,6 @@ import { __, n__, s__, sprintf } from '~/locale'; ...@@ -7,9 +6,6 @@ import { __, n__, s__, sprintf } from '~/locale';
import commonChartOptions from './common_chart_options'; import commonChartOptions from './common_chart_options';
export default { export default {
directives: {
GlResizeObserver,
},
components: { components: {
GlLineChart, GlLineChart,
}, },
...@@ -113,9 +109,6 @@ export default { ...@@ -113,9 +109,6 @@ export default {
setChart(chart) { setChart(chart) {
this.chart = chart; this.chart = chart;
}, },
onResize() {
this.chart?.resize();
},
formatTooltipText(params) { formatTooltipText(params) {
const [seriesData] = params.seriesData; const [seriesData] = params.seriesData;
if (!seriesData) { if (!seriesData) {
...@@ -143,7 +136,7 @@ export default { ...@@ -143,7 +136,7 @@ export default {
</div> </div>
<gl-line-chart <gl-line-chart
v-if="!loading" v-if="!loading"
v-gl-resize-observer="onResize" :responsive="true"
class="burndown-chart js-burndown-chart" class="burndown-chart js-burndown-chart"
:data="dataSeries" :data="dataSeries"
:option="options" :option="options"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment