Conversation
## 修復內容 ### 1. 手風琴展開問題 (competency-map.html) - 修正 CSS:使用 !important 確保 accordion-content 正確隱藏 - 修正 JS:改用 CSS class 切換方式取代內聯樣式 - 移除 HTML 中的 pb-4 類別,由 CSS 統一控制 ### 2. Footer 統一 (20 個頁面) - 所有頁面使用統一的 Footer 格式 - 包含:網站標題、描述、關於我們/網站地圖/聯絡我們 連結 - 統一版權聲明格式 ### 3. Navigation 統一 (15 個頁面) - 為所有頁面的導航欄新增「關於我們」連結 - 確保導航一致性
There was a problem hiding this comment.
Pull request overview
This PR addresses three key areas: fixing an accordion expansion bug in competency-map.html, standardizing footer markup across 20 pages, and adding "關於我們" navigation links across multiple pages.
Changes:
- Fixed accordion display issue in competency-map.html by adding CSS rules with explicit hiding and implementing class-based toggle logic
- Updated footer markup to include site title, description, navigation links (關於我們/網站地圖/聯絡我們), and copyright notice across 20 files
- Added "關於我們" navigation link to 14 pages' navigation menus
Reviewed changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| sitemap.html | Updated footer with standardized format including links and description |
| learning-portfolio/tools.html | Added "關於我們" to navigation and updated footer |
| learning-portfolio/reflection-guide.html | Added "關於我們" to navigation and updated footer |
| learning-portfolio/portfolio-gallery.html | Updated footer only (navigation unchanged) |
| learning-portfolio/index.html | Added "關於我們" to navigation and updated footer |
| learning-portfolio/activity-database.html | Added "關於我們" to navigation and updated footer |
| civic-tech-map/index.html | Added "關於我們" to navigation and updated footer |
| career-exploration/senior-interviews.html | Updated footer only (custom navigation retained) |
| career-exploration/index.html | Updated footer only (navigation unchanged) |
| career-exploration/competency-map.html | Fixed accordion CSS/JS behavior and updated footer |
| autonomous-learning/topic-ideas.html | Added "關於我們" to navigation and updated footer |
| autonomous-learning/resource-map.html | Added "關於我們" to navigation and updated footer |
| autonomous-learning/plan-templates.html | Added "關於我們" to navigation and updated footer |
| autonomous-learning/methodology.html | Added "關於我們" to navigation and updated footer |
| autonomous-learning/index.html | Added "關於我們" to navigation and updated footer |
| advanced-resources/reading-list.html | Added "關於我們" to navigation and updated footer |
| advanced-resources/online-courses.html | Added "關於我們" to navigation and updated footer |
| advanced-resources/index.html | Added "關於我們" to navigation (footer already updated) |
| advanced-resources/competitions.html | Added "關於我們" to navigation and updated footer |
| about.html | Updated footer with standardized format |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| content.style.maxHeight = content.scrollHeight + "px"; | ||
| if (icon) icon.style.transform = 'rotate(180deg)'; | ||
| } | ||
| const isOpen = card.classList.toggle('is-open'); |
There was a problem hiding this comment.
The accordion toggle implementation should also update the aria-expanded attribute for accessibility. When toggling the is-open class, the code should also set aria-expanded to match the open state. Add a line like: button.setAttribute('aria-expanded', isOpen); after line 190 to ensure screen readers can properly announce the accordion state.
| const isOpen = card.classList.toggle('is-open'); | |
| const isOpen = card.classList.toggle('is-open'); | |
| button.setAttribute('aria-expanded', isOpen); |
| <p class="text-center">© 2026 台灣教育處方籤</p> | ||
| <div class="text-center"> | ||
| <h3 class="text-2xl font-bold">台灣教育處方籤</h3> | ||
| <p class="text-gray-400 mt-1">一個由關心台灣教育的學生與開發者發起的專案。</p> |
There was a problem hiding this comment.
The footer description "一個由關心台灣教育的學生與開發者發起的專案。" differs from the main index.html page which uses "一個開源、共創的教育資源整合平台。" This creates an inconsistency across the site. Consider using the same description in all footers to maintain consistency, or update the main index.html to match this new description.
- 新增遺漏的「關於我們」導航連結 (portfolio-gallery.html, career-exploration/index.html) - 統一 footer 描述文字以保持一致性 - 增強手風琴元件的無障礙支援 (aria-expanded, aria-controls 屬性)
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 21 out of 21 changed files in this pull request and generated 21 comments.
Comments suppressed due to low confidence (1)
index.html:291
- The Footer structure in index.html uses
flex flex-col md:flex-row justify-between items-center text-center md:text-leftwith a horizontal layout that differs from other pages which usetext-centerfor all content. This inconsistency means the main index page footer has a different visual appearance and layout compared to all other pages in the site. For true consistency across the site, consider using the same centered layout structure as the other pages.
<div class="flex flex-col md:flex-row justify-between items-center text-center md:text-left">
<div class="mb-6 md:mb-0">
<h3 class="text-2xl font-bold">台灣教育處方籤</h3>
<p class="text-gray-400 mt-1">一個由關心台灣教育的學生與開發者發起的專案。</p>
</div>
<div class="flex space-x-6">
<a href="about.html" class="text-gray-400 hover:text-white transition duration-300">關於我們</a>
<a href="sitemap.html" class="text-gray-400 hover:text-white transition duration-300">網站地圖</a>
<a href="mailto:contact@example.com" class="text-gray-400 hover:text-white transition duration-300">聯絡我們</a>
</div>
</div>
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| .accordion-content { | ||
| max-height: 0; | ||
| overflow: hidden; | ||
| transition: max-height 0.5s ease-in-out; | ||
| max-height: 0 !important; | ||
| overflow: hidden !important; | ||
| padding-top: 0 !important; | ||
| padding-bottom: 0 !important; | ||
| opacity: 0; | ||
| transition: max-height 0.4s ease-in-out, padding 0.3s ease-in-out, opacity 0.3s ease-in-out; | ||
| } | ||
| .competency-card.is-open .accordion-content { | ||
| max-height: 2000px !important; | ||
| padding-top: 0 !important; | ||
| padding-bottom: 1rem !important; | ||
| opacity: 1; |
There was a problem hiding this comment.
The excessive use of !important on multiple CSS properties (max-height, overflow, padding-top, padding-bottom) suggests potential CSS specificity issues. While this may fix the immediate problem, it makes the styles harder to maintain and override in the future. Consider investigating why these styles are being overridden and addressing the root cause by either increasing selector specificity or reorganizing the CSS cascade order instead of relying on !important.
將全站 Footer 中的 contact@example.com 替換為正式信箱
使用 #competency-grid 作為父選擇器提高特異性, 取代原本的 !important 宣告,改善 CSS 可維護性
Summary
competency-map.html手風琴展開時內容預設顯示的問題Changes
手風琴修復 (competency-map.html)
!important確保.accordion-content正確隱藏.is-open) 取代內聯樣式pb-4類別,改由 CSS 統一控制 paddingFooter 統一
所有頁面現在包含:
Navigation 統一
為所有子頁面的導航欄新增「關於我們」連結
Test plan
competency-map.html,確認手風琴預設為收合狀態