Skip to content

Commit

Permalink
Address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
katrinDY committed Apr 23, 2024
1 parent e3f7962 commit b68afae
Show file tree
Hide file tree
Showing 12 changed files with 227 additions and 320 deletions.
111 changes: 21 additions & 90 deletions client/web/compose/src/components/Chart/Report/FunnelChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,25 +30,10 @@

<template #metric-options="{ metric, presetFormattedOptions }">
<b-row>
<b-col
cols="12"
md="6"
lg="6"
>
<b-form-group
:label="$t('numberFormat')"
label-class="text-primary"
>
<b-input
v-model="report.metricFormatter.numberFormat"
placeholder="0.00"
/>
</b-form-group>
</b-col>

<b-col
cols="12"
lg="6"
offset-lg="6"
>
<b-form-group
:label="$t('edit.metric.options.label')"
Expand All @@ -75,7 +60,26 @@
</b-col>
</b-row>

<hr>

<b-row>
<b-col
cols="12"
md="6"
lg="6"
>
<b-form-group
:label="$t('numberFormat')"
label-class="text-primary"
>
<b-input
v-model="report.metricFormatter.numberFormat"
:disabled="report.metricFormatter.presetFormat !== 'noFormat'"
placeholder="0.00"
/>
</b-form-group>
</b-col>

<b-col
cols="12"
md="6"
Expand Down Expand Up @@ -117,85 +121,12 @@
<b-form-select
v-model="report.metricFormatter.presetFormat"
:options="presetFormattedOptions.formatOptions"
:disabled="!!report.metricFormatter.numberFormat"
/>
</b-form-group>
</b-col>
</b-row>
</template>

<template #additional-config="{ report, presetFormattedOptions }">
<hr>
<div class="px-3">
<h5 class="mb-3">
{{ $t('edit.additionalConfig.tooltip.label') }}
</h5>

<b-row>
<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('numberFormat')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.numberFormat"
placeholder="0.00"
/>
</b-form-group>
</b-col>

<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('prefix')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.prefix"
placeholder="USD/mo"
/>
</b-form-group>
</b-col>
</b-row>

<b-row>
<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('suffix')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.suffix"
placeholder="$"
/>
</b-form-group>
</b-col>
<b-col
cols="12"
lg="6"
>
<b-form-group
:label="$t('edit.additionalConfig.tooltip.formatting.presetFormats.label')"
label-class="text-primary"
style="white-space: pre-line;"
:description="presetFormattedOptions.formattedOptionsDescription"
>
<b-form-select
v-model="report.tooltipFormatter.presetFormat"
:options="presetFormattedOptions.formatOptions"
/>
</b-form-group>
</b-col>
</b-row>
</div>
</template>
</report-edit>
</template>

Expand Down
62 changes: 4 additions & 58 deletions client/web/compose/src/components/Chart/Report/GaugeChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@
</b-col>
</b-row>

<hr>

<b-row>
<b-col
cols="12"
Expand All @@ -136,6 +138,7 @@
>
<b-input
v-model="report.metricFormatter.numberFormat"
:disabled="report.metricFormatter.presetFormat !== 'noFormat'"
placeholder="0.00"
/>
</b-form-group>
Expand Down Expand Up @@ -185,70 +188,13 @@
>
<b-form-select
v-model="report.metricFormatter.presetFormat"
:disabled="!!report.metricFormatter.numberFormat"
:options="presetFormattedOptions.formatOptions"
/>
</b-form-group>
</b-col>
</b-row>
</template>

<template #additional-config="{ report }">
<hr>
<div class="px-3">
<h5 class="mb-3">
{{ $t('edit.additionalConfig.tooltip.label') }}
</h5>

<b-row>
<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('numberFormat')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.numberFormat"
placeholder="0.00"
/>
</b-form-group>
</b-col>

<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('prefix')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.prefix"
placeholder="USD/mo"
/>
</b-form-group>
</b-col>
</b-row>

<b-row>
<b-col
cols="12"
md="6"
>
<b-form-group
:label="$t('suffix')"
label-class="text-primary"
>
<b-input
v-model="report.tooltipFormatter.suffix"
placeholder="$"
/>
</b-form-group>
</b-col>
</b-row>
</div>
</template>
</report-edit>
</template>

Expand Down
Loading

0 comments on commit b68afae

Please sign in to comment.