Add prehistoric icons...
This commit is contained in:
parent
73e804f303
commit
0b5737a576
@ -17,13 +17,22 @@ export class Prehistoric {
|
||||
return `
|
||||
<div class="container px-4 pt-4">
|
||||
<p class="p-2">
|
||||
<span class="icon has-text-link">
|
||||
<i class="fa fa-tag"></i>
|
||||
</span>
|
||||
<strong>Denominazione:</strong> ${this._data.denomination}
|
||||
</p>
|
||||
<p class="p-2">
|
||||
<strong>Località generica:</strong> ${this._data.genericPlace}
|
||||
<span class="icon has-text-link">
|
||||
<i class="fa fa-hourglass"></i>
|
||||
</span>
|
||||
<strong>Periodo:</strong> ${this._data.period}
|
||||
</p>
|
||||
<p class="p-2">
|
||||
<strong>Periodo:</strong> ${this._data.period}
|
||||
<span class="icon has-text-link">
|
||||
<i class="fa fa-map"></i>
|
||||
</span>
|
||||
<strong>Località generica:</strong> ${this._data.genericPlace}
|
||||
</p>
|
||||
<p class="mt-4 pl-2 pr-5">
|
||||
<strong class="pb-3">Descrizione breve</strong></br>
|
||||
|
@ -252,27 +252,27 @@ UI.sitesMenu = function (menuListSel, map, sites) {
|
||||
/**
|
||||
* Open Spotlight gallery
|
||||
* @param {string} galleryId The id of the trigger element
|
||||
* @param {Array<Object>} images Array of image objects from DB
|
||||
* @param {Array<Object>} items Array of image objects from DB
|
||||
* @param {boolean} video Is this a video gallery?
|
||||
*/
|
||||
UI.imageGallery = function (galleryId, images, video = false) {
|
||||
UI.imageGallery = function (galleryId, items, video = false) {
|
||||
const element = document.querySelector(`#${galleryId}`);
|
||||
|
||||
if (element) {
|
||||
let gallery = [];
|
||||
for (let img of images) {
|
||||
let author = img.author ? ` (${img.author})` : '';
|
||||
for (let media of items) {
|
||||
let author = media.author ? ` (${media.author})` : '';
|
||||
let mediaObj = {
|
||||
description: img.caption + author
|
||||
description: media.caption + author
|
||||
};
|
||||
|
||||
if (video) {
|
||||
mediaObj.media = 'video';
|
||||
mediaObj["src-mp4"] = `video/${img.filename}`;
|
||||
mediaObj.poster = `video/${img.filename.replace('mp4', 'png')}`;
|
||||
mediaObj["src-mp4"] = `video/${media.filename}`;
|
||||
mediaObj.poster = `video/${media.filename.replace('mp4', 'png')}`;
|
||||
mediaObj.autoplay = true;
|
||||
} else {
|
||||
mediaObj.src = `img/${img.filename}`;
|
||||
mediaObj.src = `img/${media.filename}`;
|
||||
}
|
||||
|
||||
gallery.push(mediaObj);
|
||||
|
Loading…
Reference in New Issue
Block a user