mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-17 13:15:24 +00:00
fix tab
This commit is contained in:
parent
e19e03d413
commit
5593416257
@ -22,7 +22,7 @@ export const NewControl = {
|
||||
i: "0",
|
||||
type: "Widget",
|
||||
widget: {
|
||||
title: "Title",
|
||||
title: "",
|
||||
},
|
||||
graph: {},
|
||||
standard: {},
|
||||
|
@ -164,6 +164,7 @@ export const dashboardStore = defineStore({
|
||||
}
|
||||
if (type === "Text") {
|
||||
newItem.h = 6;
|
||||
newItem.graph = TextConfig;
|
||||
}
|
||||
if (this.layout[idx].children) {
|
||||
const items = children.map((d: LayoutConfig) => {
|
||||
|
@ -121,6 +121,7 @@ import Widget from "./Widget.vue";
|
||||
import Trace from "./Trace.vue";
|
||||
import Profile from "./Profile.vue";
|
||||
import Log from "./Log.vue";
|
||||
import Text from "./Text.vue";
|
||||
|
||||
const props = {
|
||||
data: {
|
||||
@ -131,7 +132,7 @@ const props = {
|
||||
};
|
||||
export default defineComponent({
|
||||
name: "Tab",
|
||||
components: { Topology, Widget, Trace, Profile, Log },
|
||||
components: { Topology, Widget, Trace, Profile, Log, Text },
|
||||
props,
|
||||
setup(props) {
|
||||
const { t } = useI18n();
|
||||
|
@ -59,6 +59,9 @@ export default defineComponent({
|
||||
function clickGrid(item: LayoutConfig) {
|
||||
dashboardStore.activeGridItem(item.i);
|
||||
dashboardStore.selectWidget(item);
|
||||
if (item.type === "Tab") {
|
||||
dashboardStore.setActiveTabIndex(0);
|
||||
}
|
||||
}
|
||||
onBeforeUnmount(() => {
|
||||
dashboardStore.setLayout([]);
|
||||
|
Loading…
Reference in New Issue
Block a user