diff --git a/src/components/navbar/LeftSidebar.vue b/src/components/navbar/LeftSidebar.vue index 65343dd..8e97141 100644 --- a/src/components/navbar/LeftSidebar.vue +++ b/src/components/navbar/LeftSidebar.vue @@ -29,10 +29,30 @@ const filteredItems = computed(() => { const handleClick = (ord) => { if (ord) { - router.push({ + const targetRoute = { name: "baja", query: { pagename: "system", ord: encodeURIComponent(ord) }, - }); + }; + // 檢查當前路由是否相同 + if ( + router.currentRoute.value.query.ord === targetRoute.query.ord + ) { + // 相同則加上一個時間戳記來強制重新導航,觸發 iframe 重新載入 + router.push({ + name: "baja", + query: { + ...targetRoute.query, + _t: new Date().getTime(), + }, + }); + } else { + router.push(targetRoute); + } + + // 點擊選項後關閉側邊欄 + if (props.toggleSidebar) { + props.toggleSidebar(); + } } }; diff --git a/src/style.css b/src/style.css index bcd1bc8..e0ebc8b 100644 --- a/src/style.css +++ b/src/style.css @@ -4,6 +4,22 @@ serif; } +/* Webkit 瀏覽器 (Chrome, Safari, Edge) */ +::-webkit-scrollbar { + width: 0px; + background: transparent; +} + +/* Firefox */ +* { + scrollbar-width: none; +} + +/* IE 和舊版 Edge */ +* { + -ms-overflow-style: none; +} + a { color: #69b0cf; } diff --git a/src/views/system/SystemPage.vue b/src/views/system/SystemPage.vue index 983b5f2..3bfac5f 100644 --- a/src/views/system/SystemPage.vue +++ b/src/views/system/SystemPage.vue @@ -1,5 +1,5 @@