承接 automad/lightbox 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

automad/lightbox

最新稳定版本:1.0.2

Composer 安装命令:

composer require automad/lightbox

包简介

A custom string function for creating a lightbox slideshow out of inline images.

README 文档

README

The Lightbox extensions is a custom string function for Automad that easily let's you create lightbox slideshows out of inline images. It can be used with any text variable including markdown image links.

Assets

The lightbox extension requires jQuery to be loaded along with the included assets within your template's <head> section.

<script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
<script src="/packages/automad/lightbox/dist/lightbox.min.js"></script>
<link rel="stylesheet" href="/packages/automad/lightbox/dist/lightbox.min.css">

Template

Somewhere in the body of your template the extension can be used with any variable as follows:

@{ text | Automad/Lightbox | markdown }

Using Inline Images in Content

The Lightbox string function will pick up any markdown image within your content and turn it into a link to open the lightbox modal window. While the enlarged image in the lightbox modal will always have its original dimensions, it is possible to resize the image embedded within the text as follows:

![](image?400x300)

The image tag above will create an image link with a small thumbnail of 400x300 pixel to open the enlarged version of that image with its original dimensions in the modal window.

Captions

Captions stored along with images will be displayed automatically at the bottom of the lightbox modal window.

统计信息

  • 总下载量: 2.22k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 2
  • Forks: 1
  • 开发语言: JavaScript

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-01-25