Show list of images.
https://luna.liriliri.io/?path=/story/image-list
Add the following script and style to your page.
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luna-carousel/luna-carousel.css" />
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luna-image-viewer/luna-image-viewer.css" />
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luna-toolbar/luna-toolbar.css" />
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luna-gallery/luna-gallery.css" />
<link rel="stylesheet" href="//cdn.jsdelivr.net/npm/luna-image-list/luna-image-list.css" />
<script src="//cdn.jsdelivr.net/npm/luna-carousel/luna-carousel.js"></script>
<script src="//cdn.jsdelivr.net/npm/luna-image-viewer/luna-image-viewer.js"></script>
<script src="//cdn.jsdelivr.net/npm/luna-toolbar/luna-toolbar.js"></script>
<script src="//cdn.jsdelivr.net/npm/luna-gallery/luna-gallery.js"></script>
<script src="//cdn.jsdelivr.net/npm/luna-image-list/luna-image-list.js"></script>
You can also get it on npm.
npm install luna-image-list luna-gallery luna-toolbar luna-image-viewer luna-carousel --save
import 'luna-carousel/luna-carousel.css'
import 'luna-image-viewer/luna-image-viewer.css'
import 'luna-toolbar/luna-toolbar.css'
import 'luna-gallery/luna-gallery.css'
import 'luna-image-list/luna-image-list.css'
import LunaImageList from 'luna-image-list'
const imageList = new LunaImageList(container)
imageList.append('https://luna.liriliri.io/pic1.png', 'pic1.png')
- horizontalMargin(number): Horizontal margin.
- rowHeight(number): Row height.
- showTitle(boolean): Show title.
- verticalMargin(number): Vertical margin.
Append image.
Clear all images.