fix: make legend disappear by not declaring plugins twice
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
<button id="logout_btn" class="btn btn-sm btn-neutral mr-2" @click.prevent="logOutButton">
|
||||
Logout
|
||||
</button>
|
||||
<img id="acct_mgmt_button" src="@/assets/icon-head-black.svg" width="32" height="32"
|
||||
<img v-show="false" id="acct_mgmt_button" src="@/assets/icon-head-black.svg" width="32" height="32"
|
||||
class="cursor-pointer" @click="onAcctHeadClick"
|
||||
/>
|
||||
</div>
|
||||
|
||||
@@ -835,6 +835,9 @@ export default {
|
||||
title: function(context) {
|
||||
return `${content.x}: ${getMoment(context[0].parsed.x)}`;
|
||||
},
|
||||
label:function(context) {
|
||||
return `${content.y}: ${getSimpleTimeLabel(context.parsed.y, 2)}`;
|
||||
},
|
||||
},
|
||||
},
|
||||
title: {
|
||||
@@ -908,15 +911,6 @@ export default {
|
||||
}
|
||||
},
|
||||
},
|
||||
plugins: {
|
||||
tooltip: {
|
||||
callbacks:{
|
||||
label:function(context) {
|
||||
return `${content.y}: ${getSimpleTimeLabel(context.parsed.y, 2)}`;
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
return [primeVueSetData, primeVueSetOption];
|
||||
|
||||
@@ -814,6 +814,11 @@ export default {
|
||||
title: function(context) {
|
||||
return `${content.x}: ${getMoment(context[0].parsed.x)}`;
|
||||
}
|
||||
//TODO: Not sure which one to apply. callbacks:{
|
||||
// label:function(context) {
|
||||
// return `${content.y}: ${getSimpleTimeLabel(context.parsed.y, 2)}`;
|
||||
// },
|
||||
// },
|
||||
},
|
||||
},
|
||||
title: {
|
||||
@@ -888,15 +893,6 @@ export default {
|
||||
}
|
||||
},
|
||||
},
|
||||
plugins: {
|
||||
tooltip: {
|
||||
callbacks:{
|
||||
label:function(context) {
|
||||
return `${content.y}: ${getSimpleTimeLabel(context.parsed.y, 2)}`;
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
return [primeVueSetData, primeVueSetOption]
|
||||
|
||||
Reference in New Issue
Block a user