@@ -251,7 +251,7 @@ function selectDatapoint(datapoint, index) {
251251 </div >
252252 </div >
253253 <template v-for =" (bar , i ) in drawableDataset " >
254- <div v-if =" isDataset" :style =" `display:flex !important;${['left', 'right'].includes(FINAL_CONFIG.style.labels.name.position) ? ' flex-direction:row !important' : 'flex-direction:column !important'};gap: ${FINAL_CONFIG.style.gap}px !important;${FINAL_CONFIG.style. labels.name.position === 'right' ? 'row-reverse !important' : ''} ;align-items:center;${dataset.length > 0 && i !== dataset.length - 1 ? 'margin-bottom:6px' : ''}`" @click =" () => selectDatapoint(bar, i)" >
254+ <div v-if =" isDataset" :style =" `display:flex !important;${['left', 'right'].includes(FINAL_CONFIG.style.labels.name.position) ? ` flex-direction: ${FINAL_CONFIG.style.labels.name.position === 'right' ? 'row-reverse' : 'row'} !important` : 'flex-direction:column !important'};gap:${FINAL_CONFIG.style.gap}px !important ;align-items:center;${dataset.length > 0 && i !== dataset.length - 1 ? 'margin-bottom:6px' : ''}`" @click =" () => selectDatapoint(bar, i)" >
255255 <!-- CUSTOM DATALABEL -->
256256 <slot name =" data-label" v-bind =" { bar: {
257257 ...bar,
@@ -272,7 +272,17 @@ function selectDatapoint(datapoint, index) {
272272 } }" />
273273
274274 <!-- DEFAULT DATALABEL -->
275- <div v-if =" !$slots['data-label']" :style =" `width:${FINAL_CONFIG.style.labels.name.width};${['right','top'].includes(FINAL_CONFIG.style.labels.name.position) ? 'text-align:left' : 'text-align:right'};color:${FINAL_CONFIG.style.labels.name.color};font-size:${FINAL_CONFIG.style.labels.fontSize}px;font-weight:${FINAL_CONFIG.style.labels.name.bold ? 'bold' : 'normal'}`" >
275+ <div
276+ v-if =" !$slots['data-label']"
277+ :style =" {
278+ width: FINAL_CONFIG.style.labels.name.width,
279+ color: FINAL_CONFIG.style.labels.name.color,
280+ fontSize: FINAL_CONFIG.style.labels.fontSize + 'px',
281+ fontWeight: FINAL_CONFIG.style.labels.name.bold ? 'bold' : 'normal',
282+ textAlign: ['left', 'right'].includes(FINAL_CONFIG.style.labels.name.position) ? 'left' : ['top', 'top-left'].includes(FINAL_CONFIG.style.labels.name.position) ? 'left' : FINAL_CONFIG.style.labels.name.position === 'top-center' ? 'center' : 'right'
283+ }"
284+ >
285+ {{ FINAL_CONFIG.style.labels.name.position }}
276286 <span :data-cy =" `sparkbar-name-${i}`" >{{ bar.name }}</span >
277287 <span
278288 :data-cy =" `sparkbar-value-${i}`"
0 commit comments