|
1 | 1 | <template> |
2 | | - <div class="sm-component-indicator" :style="[getBackgroundStyle, { 'flex-direction': direction }]"> |
3 | | - <div class="sm-component-indicator__head"> |
| 2 | + <div class="sm-component-indicator" :style="getBackgroundStyle"> |
| 3 | + <div :class="`sm-component-indicator__content sm-component-indicator__content-${mode}`"> |
4 | 4 | <span v-show="showTitleUnit" class="sm-component-indicator__title" :style="[unit_titleStyle, getTextColorStyle]"> |
5 | 5 | {{ titleData }} |
6 | 6 | </span> |
7 | | - </div> |
8 | | - <div class="sm-component-indicator__content"> |
9 | | - <span class="sm-component-indicator__num" :style="[indicatorStyle]"> |
10 | | - <countTo |
11 | | - v-if="isNumber(indicatorNum)" |
12 | | - :decimals="calDecimals" |
13 | | - :startVal="startData" |
14 | | - :endVal="numData" |
15 | | - :duration="Number(duration) || 1000" |
16 | | - :separator="separator" |
17 | | - :numBackground="numBackground" |
18 | | - :numSpacing="numSpacing" |
19 | | - :separatorBackground="separatorBackground" |
20 | | - :fontSize="fontSize" |
21 | | - ></countTo> |
22 | | - {{ isNumber(indicatorNum) ? '' : indicatorNum }} |
23 | | - </span> |
24 | | - <span v-show="showTitleUnit" class="sm-component-indicator__unit" :style="[unit_titleStyle, getTextColorStyle]">{{ |
25 | | - unitData |
26 | | - }}</span> |
| 7 | + <div> |
| 8 | + <span class="sm-component-indicator__num" :style="[indicatorStyle]"> |
| 9 | + <countTo |
| 10 | + v-if="isNumber(indicatorNum)" |
| 11 | + :decimals="calDecimals" |
| 12 | + :startVal="startData" |
| 13 | + :endVal="numData" |
| 14 | + :duration="Number(duration) || 1000" |
| 15 | + :separator="separator" |
| 16 | + :numBackground="numBackground" |
| 17 | + :numSpacing="numSpacing" |
| 18 | + :separatorBackground="separatorBackground" |
| 19 | + :fontSize="fontSize" |
| 20 | + ></countTo> |
| 21 | + {{ isNumber(indicatorNum) ? '' : indicatorNum }} |
| 22 | + </span> |
| 23 | + <span v-show="showTitleUnit" class="sm-component-indicator__unit" :style="[unit_titleStyle, getTextColorStyle]"> |
| 24 | + {{ unitData }} |
| 25 | + </span> |
| 26 | + </div> |
27 | 27 | </div> |
28 | 28 | </div> |
29 | 29 | </template> |
|
0 commit comments