內容簡介
有時您的 WordPress 安裝中可能有許多管理員選單項目,使用這個外掛程式,您只需要輸入幾個項目名稱的字母,就能輕鬆找到。此外掛使用自訂的 jQuery 表達式將“包含”變成不區分大小寫,對於不符合的元素添加類別“filtered”並根據 2 條簡單規則執行操作:
對於與父選單項目匹配的項目,其仍然可見。
對於與子選單項目匹配的項目,其仍然高亮顯示並保持其父選單項目可見,對於其餘的父選單項目則遵循第一條規則。
表達式來源:
https://stackoverflow.com/questions/187537/is-there-a-case-insensitive-jquery-contains-selector/36392273
外掛標籤
開發者團隊
原文外掛簡介
Sometimes you may have a lot of admin menu items based on your WordPress installation. With this plugin, you only need to type a few letters of the item name you’re looking for and voila! The plugin uses modern vanilla JavaScript to filter menu items efficiently with case-insensitive matching.
Key Features:
No jQuery dependency – Pure vanilla JavaScript for better performance
Debounced search – Optimized filtering with 150ms delay for smooth typing
Keyboard shortcuts – Ctrl/Cmd + F to focus search, Escape to clear
Accessibility support – Proper ARIA labels and keyboard navigation
Modern CSS – Smooth transitions and visual feedback
Performance optimized – Efficient DOM manipulation and event handling
How it works:
The plugin adds a search input at the top of the admin menu and follows these filtering rules:
For parent menu items: Matching items remain visible
For child menu items: Matching items stay highlighted and keep their parent visible
Visual feedback: Filtered items are hidden, active items get subtle background highlighting
Technical Improvements in v0.3:
Complete rewrite – Eliminated jQuery dependency for faster loading
Enhanced UX – Added keyboard shortcuts and better visual states
Better architecture – Modular JavaScript with proper error handling
Improved accessibility – Screen reader support and keyboard navigation
Modern styling – Updated CSS with focus states and transitions
