diff --git a/nezha-fronted/src/assets/css/components/common/alert/alertStateInfo.scss b/nezha-fronted/src/assets/css/components/common/alert/alertStateInfo.scss index 32148b942..3f9fcd801 100644 --- a/nezha-fronted/src/assets/css/components/common/alert/alertStateInfo.scss +++ b/nezha-fronted/src/assets/css/components/common/alert/alertStateInfo.scss @@ -21,6 +21,9 @@ .green-bg{ background-color: green; } + .gray-bg{ + background-color: gray; + } .alert-label-box{ display: flex; flex-direction: row; diff --git a/nezha-fronted/src/assets/css/components/common/globalSearch/searchItemInfo.scss b/nezha-fronted/src/assets/css/components/common/globalSearch/searchItemInfo.scss index b95a032ed..69bdd4ef9 100644 --- a/nezha-fronted/src/assets/css/components/common/globalSearch/searchItemInfo.scss +++ b/nezha-fronted/src/assets/css/components/common/globalSearch/searchItemInfo.scss @@ -7,7 +7,7 @@ flex-direction: column; align-items: center; box-sizing: border-box; - padding: 60px 75px 0 75px; + padding: 60px 45px 0 75px; overflow-y: auto; .el-skeleton{ height: 100%; @@ -43,11 +43,9 @@ margin-bottom: 30px; } .search-item-info{ + position: relative; width: 100%; - border-bottom: 1px solid $--border-color-light; display: flex; - min-height: 47px; - max-height: 200px; align-items: center; .search-item-key{ width: 120px; @@ -58,11 +56,19 @@ font-weight: 400; } .search-item-value-box{ - line-height: 47px; - height: 100%; width: calc(100% - 120px); display: flex; align-items: center; + >div{ + width: calc(100% - 30px); + } + .document-copy-block{ + width: 100% !important; + .nz-icon.nz-icon-override{ + display: flex; + align-items: center; + } + } .nz-icon{ display: inline-block; line-height: 47px; @@ -72,14 +78,13 @@ color: $--color-primary; } .search-item-value{ - width: calc(100% - 30px); + padding: 5px 0; + display: flex; + align-items: center; font-size: 14px; - height: 100%; - overflow-y: auto; color: $--color-text-primary; - white-space: nowrap; - text-overflow: ellipsis; - line-height: 47px; + word-break: break-all; + white-space: normal; .ql-container.ql-snow{ border: none; .ql-editor{ @@ -90,6 +95,14 @@ } } } + .search-item-info::before{ + content: ""; + position: absolute; + left: 0; + bottom: 0px; + width: calc(100% - 30px); + border-bottom: 1px solid $--border-color-light; + } .search-item-info:last-child{ border-bottom: none; } diff --git a/nezha-fronted/src/components/chart/chartList.vue b/nezha-fronted/src/components/chart/chartList.vue index 66852efd6..7cf54b364 100644 --- a/nezha-fronted/src/components/chart/chartList.vue +++ b/nezha-fronted/src/components/chart/chartList.vue @@ -44,7 +44,7 @@ @container-resized="containerResizedEvent" > @@ -358,7 +357,7 @@ export default { // console.log(this.$refs['chart' + item.id][0].$el.offsetHeight, scrollTop,'scrollTop',windowHeight,mainOffsetTop + mainHeight / 4,(windowScrollTop + windowHeight)) if ((mainOffsetTop + mainHeight / 4) < (windowScrollTop + windowHeight)) { item.loaded = true - this.$refs['chart' + item.id][0].getChartData() + this.$refs['chart' + item.id] && this.$refs['chart' + item.id][0].getChartData() } } }) diff --git a/nezha-fronted/src/components/chart/panelChart.vue b/nezha-fronted/src/components/chart/panelChart.vue index e39d14f2b..c3eafd1ac 100644 --- a/nezha-fronted/src/components/chart/panelChart.vue +++ b/nezha-fronted/src/components/chart/panelChart.vue @@ -101,10 +101,6 @@ export default { variablesInit: { type: Boolean, default: true - }, - // 变量比较结果 图表是否显示/隐藏 - showHidden: { - type: Object } }, data () { @@ -156,10 +152,6 @@ export default { }, // 参数 isRefresh 标识是否是刷新操作 getChartData (isRefresh, params) { // 获取chart的数据前的准备 主要用于处理时间参数 - // 如果图表被隐藏了 则不请求数据 - if (this.showHidden && this.showHidden[this.chartInfo.id] === 'hidden') { - return - } if (!this.variablesInit) { // 变量未加载完成 不请求数据 return } @@ -316,7 +308,7 @@ export default { this.logChartDataFormat() } }).catch(res => { - console.info(res) + // console.info(res) }).finally(() => { this.loading = false }) @@ -765,16 +757,6 @@ export default { this.chartInfo.loaded && this.getChartData(true) } } - }, - // 监听图表显示 重新请求数据渲染图表 - showHidden: { - handler (n, o) { - const newVal = n[this.chartInfo.id] - const oldVal = o[this.chartInfo.id] - if ((newVal === 'show' || newVal === undefined) && oldVal === 'hidden') { - this.getChartData(true) - } - } } }, mounted () { diff --git a/nezha-fronted/src/components/common/@topology/core/src/socket.js b/nezha-fronted/src/components/common/@topology/core/src/socket.js index 19f2b8c44..99d9e76e9 100644 --- a/nezha-fronted/src/components/common/@topology/core/src/socket.js +++ b/nezha-fronted/src/components/common/@topology/core/src/socket.js @@ -10,7 +10,7 @@ const Socket = /** @class */ (function () { this.socket = new WebSocket(this.url) this.socket.onmessage = this.cb this.socket.onclose = function () { - console.info('Canvas websocket closed and reconneting...') + // console.info('Canvas websocket closed and reconneting...') _this.init() } } diff --git a/nezha-fronted/src/components/common/alert/alertStateInfo.vue b/nezha-fronted/src/components/common/alert/alertStateInfo.vue index f567bcc80..b2ac04935 100644 --- a/nezha-fronted/src/components/common/alert/alertStateInfo.vue +++ b/nezha-fronted/src/components/common/alert/alertStateInfo.vue @@ -26,11 +26,11 @@ {{$t('dashboard.overview.mapTooltip.prometheus')}}
- + {{$t('overall.cortex')}}
- + {{$t('overall.loki')}}
diff --git a/nezha-fronted/src/components/common/honeycomb/hexagonFigureSvg.vue b/nezha-fronted/src/components/common/honeycomb/hexagonFigureSvg.vue index f4af05331..f305c2483 100644 --- a/nezha-fronted/src/components/common/honeycomb/hexagonFigureSvg.vue +++ b/nezha-fronted/src/components/common/honeycomb/hexagonFigureSvg.vue @@ -292,7 +292,7 @@ export default { }, 500) }) }).catch((res) => { - console.info(res) + // console.info(res) }) }, getLayout () { diff --git a/nezha-fronted/src/components/common/js/common.js b/nezha-fronted/src/components/common/js/common.js index 6bf26d6e4..2fc6a0787 100644 --- a/nezha-fronted/src/components/common/js/common.js +++ b/nezha-fronted/src/components/common/js/common.js @@ -40,6 +40,9 @@ export function getTopology (key) { export function setTopology (key, value) { topologyCache[`topology${key}`] = value + if (!value) { + delete topologyCache[`topology${key}`] + } } export function clearTopologyCache () { diff --git a/nezha-fronted/src/components/common/project/topologyL5.vue b/nezha-fronted/src/components/common/project/topologyL5.vue index 36ae2da1f..701c22d10 100644 --- a/nezha-fronted/src/components/common/project/topologyL5.vue +++ b/nezha-fronted/src/components/common/project/topologyL5.vue @@ -2295,9 +2295,6 @@ export default { this.timer4 = null } if (getTopology(this.topologyIndex)) { -// <<<<<<< HEAD - getTopology(this.topologyIndex).open({ pens: [] }) - getTopology(this.topologyIndex).off('contextmenu', this.onContextMenu) getTopology(this.topologyIndex).destroy() const StoreData = le5leStore.get() const arr = [] @@ -2311,88 +2308,7 @@ export default { }) Object.keys(getTopology(this.topologyIndex)).forEach(key => { getTopology(this.topologyIndex)[key] = null -// ======= -// console.log(getTopology(this.topologyIndex)) -// // getTopology(this.topologyIndex).open({ pens: [] }) -// // getTopology(this.topologyIndex).off('contextmenu', this.onContextMenu) -// // getTopology(this.topologyIndex).data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).activeLayer.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).animateLayer.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).caches.list.forEach((cache) => { -// // cache.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // }) -// // getTopology(this.topologyIndex).animateLayer.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).canvas.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).divLayer.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// // getTopology(this.topologyIndex).hoverLayer.data.pens.forEach(item => { -// // item.img = null -// // item.image = null -// // item.lastImage = null -// // }) -// getTopology(this.topologyIndex).destroy() -// const StoreData = le5leStore.get() -// // const arr = [] -// Object.keys(StoreData).forEach(key => { -// const id = key.split('-')[0] -// // arr.push(id) -// if (getTopology(this.topologyIndex).id == id) { -// if (StoreData[key][0] && StoreData[key][0].img) { -// StoreData[key].forEach(item => { -// item.img = null -// item.image = null -// item.lastImage = null -// }) -// } -// if (StoreData[key] && StoreData[key].pens) { -// StoreData[key].pens.forEach(item => { -// item.img = null -// item.image = null -// item.lastImage = null -// }) -// } -// if (StoreData[key] && StoreData[key].data && StoreData[key].data.pens) { -// StoreData[key].data.pens.forEach(item => { -// item.img = null -// item.image = null -// item.lastImage = null -// }) -// } -// le5leStore.set(key, null) -// delete StoreData[key] -// } -// >>>>>>> 73b71d578f55a77256af95f635a651575e8cebf9 }) - // Object.keys(getTopology(this.topologyIndex)).forEach(key => { - // getTopology(this.topologyIndex)[key] = null - // }) setTopology(this.topologyIndex, null) } if (document.getElementById('topology-canvas' + this.topologyIndexF)) { diff --git a/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue b/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue index a6e32a9b1..f14c1c199 100644 --- a/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue +++ b/nezha-fronted/src/components/common/rightBox/chart/chartRightBox.vue @@ -321,7 +321,7 @@ export default { } }).catch(res => { this.$refs['childrenFrom' + this.editChart.datasource].showError() - console.info(res) + // console.info(res) }) }, selectPanel (panel) {