
內容簡介
這個簡約的 WordPress Lightbox 外掛可將高性能、響應式的 jQuery Lightbox 功能添加到您的圖像中。當點擊標準的WordPress圖像/圖庫時,背景會淡出成黑色,圖像會在 Lightbox 彈出窗口中顯示。您可以使用屏幕上的箭頭、觸摸屏滑動或按箭頭鍵來瀏覽圖庫。
為了讓 WordPress 圖像和圖庫使用 Lightbox:
您必須在選擇縮略圖的連結位置時選擇 “媒體文件” 選項。如果連接直接指向圖像文件,也可以選擇 “自定義連結” 選項。這對任何圖像文件都有效,即使它是在另一個網站上托管的。
在 WP Featherlight 設置中勾選 “啟用 Lightbox” 以在每篇文章中啟用。
您還可以通過添加數據屬性到您的內容中,對視頻、Iframe 和 AJAX 內容使用 Lightbox。有關自定義內容加載的更多詳細信息,請參閱featherlight 說明文件。
我的外掛只是從原始的WP Featherlight 外掛分叉而來。唯一的區別是原始版本會在每個網頁上自動加載 Featherlight CSS/JS,而我們的只有在手動啟用時才會加載。非常感謝 Yin 和 Walter 的貢獻。
功能:
超輕量級-比原始版本WP Featherlight還要輕量級,因為 Lightbox CSS/JS 不會自動加載。
手動啟用-要啟用 Lightbox 功能,只需在文章設置中選中核取方塊即可。
保留 WP Featherlight 功能-具有與原始 WP Featherlight 外掛(至版本1.3.3)相同的所有功能和過濾器。
支持 WEBP 圖像格式。
外掛標籤
開發者團隊
原文外掛簡介
This minimal WordPress lightbox plugin adds high performance, responsive jQuery lightbox functionality to your images. When standard WordPress images/galleries are clicked, the background fades out into black as images display in lightbox popup. Galleries can be navigated with on-screen arrows, touchscreen swipes, or pressing arrows keys.
In order for WordPress images and galleries to be lightboxed:
– You must select the “Media File” option when choosing where thumbnails should link. You can also select the “Custom Link” option if it links directly to an image file. This should work for any image file, even if it’s hosted on another website.
– Enable on each post by checking “Enable lightbox” on the WP Featherlight settings.
– You can also lightbox videos, iframes, and ajax content by adding data attributes to your content. For more details on custom content loading, check out the featherlight documentation.
My plugin is simply a forked version of the original WP Featherlight plugin. Only difference is the original loads the featherlight CSS/JS on every page whereas mine only loads when you manually enable. Big thanks to Yin and Walter for contributing.
Features:
Ultra-lightweight – even more lightweight than the original WP Featherlight since the lightbox CSS/JS is not loaded automatically.
Manual activation – to enable lightbox functionality, simply click the checkbox in your post settings.
Retains WP Featherlight features – has all the same features and filters as the original WP Featherlight plugin (up to version 1.3.3)
Supports WEBP image format.
