Files
2025-12-19 19:17:57 -08:00

5492 lines
279 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<theme name="Default" author_name="Invision Power Services, Inc" author_url="https://www.invisioncommunity.com">
<template template_group="browse" template_name="album" template_data="$album, $table, $commentsAndReviews" template_location="front" template_app="gallery"><![CDATA[
{{if $club = $album->category()->club()}}
{{if settings.clubs and settings.clubs_header == 'full'}}
{template="header" app="core" group="clubs" params="$club, $album->category()"}
{{endif}}
<div id='elClubContainer'>
{{endif}}
{{if $album->coverPhoto('masked')}}
<div class='ipsCoverPhoto ipsCoverPhoto--album' data-controller='core.global.core.coverPhoto'>
<div class='ipsCoverPhoto__container'>
<img src='{$album->coverPhoto('masked')}' class='ipsCoverPhoto__image' data-action="toggleCoverPhoto" alt="{$album->name}" loading='lazy'>
</div>
</div>
{{endif}}
<header class="ipsPageHeader ipsBox ipsBox--galleryAlbumHeader ipsPull">
<div class="ipsPageHeader__row">
<div data-ips-hook="header" class="ipsPageHeader__primary">
<h1 class="ipsPageHeader__title">
<div data-ips-hook="badges" class="ipsBadges">
{{foreach $album->asItem()->badges() as $badge}}{$badge|raw}{{endforeach}}
</div>
<span data-ips-hook="title">
{{if $album->asItem()->canEdit()}}
<span data-controller="core.front.core.moderation">{{if $album->asItem()->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}
<span data-role="editableTitle" title='{lang="click_hold_edit"}'>{$album->_title}</span>
</span>
{{else}}
{{if $album->asItem()->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}{$album->_title}
{{endif}}
</span>
</h1>
<div class='ipsPageHeader__desc'>
{{if !isset( \IPS\Request::i()->tab ) || \IPS\Request::i()->tab !== 'node_gallery_gallery'}}
{lang="album_created_by"} {$album->owner()->link()|raw} {{if $album->last_img_date}}&middot;{{endif}}
{{endif}}
{{if $album->last_img_date}}
{lang="updated"} {datetime="$album->last_img_date"}
{{endif}}
</div>
</div>
<div class='ipsButtons'>
{{if $album->asItem()->shareLinks()}}
{template="shareButton" app="core" group="sharelinks" params="$album->asItem()"}
{{endif}}
{{$followerCount = \IPS\gallery\Image::containerFollowerCount( $album );}}
{template="follow" app="core" group="global" params="'gallery', 'album', $album->_id, $followerCount"}
</div>
</div>
{{if $album->description}}
<div class='ipsPageHeader__row'>
{template="richText" group="global" app="core" location="global" params="$album->description, array(''), array(), array('data-ipsTruncate')"}
</div>
{{endif}}
<div class='ipsPageHeader__row ipsPageHeader__row--footer'>
<div class='ipsPageHeader__primary'>
<ul class='ipsList ipsList--inline ipsList--icons i-link-color_inherit' data-ips-hook="iconsList">
<li><i class="fa-solid fa-photo-film"></i> {lang="num_images" pluralize="$album->count_imgs"}</li>
{{if $album->use_comments && $album->comments > 0}}
<li><i class="fa-regular fa-images"></i> {lang="gallery_album_num_comments_lc" pluralize="$album->comments"}</li>
{{endif}}
{{if $album->allow_comments && $album->count_comments > 0}}
<li><i class="fa-regular fa-images"></i> {lang="gallery_image_comments_s" pluralize="$album->count_comments"}</li>
{{endif}}
{{if $album->use_reviews && $album->reviews > 0}}
<li><i class="fa-solid fa-pen-to-square"></i> {lang="gallery_album_num_reviews_lc" pluralize="$album->reviews"}</li>
{{endif}}
{{if $album->views >= 0}}
<li id='elAlbumViews'>
{{if \IPS\Application::appIsEnabled('cloud') and \IPS\Member::loggedIn()->modPermission('can_view_moderation_log')}}
{{$url = "app=cloud&module=analytics&controller=analytics&contentClass=\IPS\gallery\Album\Item&contentId=" . $album->id;}}
<i class='fa-solid fa-eye'></i> <a href='{url="$url"}' data-ipsDialog data-ipsDialog-title='{lang="analytics"}' data-ipsTooltip title='{lang="analytics"}'>{lang="num_views_with_number" pluralize="$album->views"}</a>
{{else}}
<i class='fa-solid fa-eye'></i> {lang="num_views_with_number" pluralize="$album->views"}
{{endif}}
</li>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $album->asItem(), 'IPS\Content\Reactable' ) and settings.reputation_enabled}}
<li class='i-margin-start_auto'>{template="reputation" app="core" group="global" params="$album->asItem()"}</li>
{{endif}}
</ul>
</div>
</div>
</header>
{{if $menu = $album->asItem()->menu()}}
<ul class="ipsButtons ipsButtons--main">
<li>{$menu|raw}</li>
{{if $album->can( 'add' )}}
{template="categoryButtons" group="browse" params="$album->can('add'), $album->category(), $album"}
{{endif}}
</ul>
{{endif}}
{{if \count( $album->_event )}}
<div class='ipsBox ipsBox--galleryAlbumEvent'>
<h4 class='ipsBox__header'>{lang="events_in_album" pluralize="\count( $album->_event )"}</h4>
<div class='ipsBox__content ipsBox__padding'>{template="eventBlocks" group="view" app="calendar" params="$album->_event"}</div>
</div>
{{endif}}
{template="contentItemMessages" group="global" app="core" params="$album->asItem()->getMessages(), $album->asItem()"}
<div class='ipsBox ipsBox--galleryAlbumMain ipsPull'>
{$table|raw}
</div>
{{if $commentsAndReviews}}
<div class='ipsBox ipsBox--galleryAlbumCommentsReviews ipsPull' id="replies">
{{if ( $album->asItem()->use_reviews && $album->asItem()->container()->allow_reviews ) && ( $album->asItem()->use_comments && $album->asItem()->container()->allow_comments ) }}
<h2 class='ipsBox__header' hidden>{lang="user_feedback"}</h2>
{{endif}}
{{if (!( $album->asItem()->use_reviews && $album->asItem()->container()->allow_reviews ) && ( $album->asItem()->use_comments && $album->asItem()->container()->allow_comments )) OR (( $album->asItem()->use_reviews && $album->asItem()->container()->allow_reviews ) && !( $album->asItem()->use_comments && $album->asItem()->container()->allow_comments )) }}
<div>
{$commentsAndReviews|raw}
</div>
{{else}}
{$commentsAndReviews|raw}
{{endif}}
</div>
{{endif}}
<div class="ipsBox ipsBox--padding ipsPull ipsResponsive_hideDesktop">
<div class='ipsPageActions'>
{{if $album->asItem()->shareLinks()}}
{template="shareButton" app="core" group="sharelinks" params="$album->asItem()"}
{{endif}}
{{$followerCount = \IPS\gallery\Image::containerFollowerCount( $album );}}
{template="follow" app="core" group="global" params="'gallery', 'album', $album->_id, $followerCount"}
</div>
</div>
{{if $album->category()->club()}}
</div>
{{endif}}
]]></template>
<template template_group="browse" template_name="albumComments" template_data="$album" template_location="front" template_app="gallery"><![CDATA[<div>
<div data-controller='core.front.core.commentFeed, core.front.core.ignoredComments' {{if settings.auto_polling_enabled}}data-autoPoll{{endif}} data-baseURL='{$album->url()}' {{if $album->isLastPage()}}data-lastPage{{endif}} data-feedID='{$album->feedId}' id='comments' data-follow-area-id="album-{$album->id}">
<div>
<h2 class='ipsBox__header' hidden data-role="comment_count" data-commentCountString="js_gallery_album_num_comments_uc">{lang="gallery_album_num_comments_uc" pluralize="$album->comments"}</h2>
{{if $album->commentPageCount() > 1}}
<div class="ipsButtonBar">
<div class="ipsButtonBar__pagination">
{$album->commentPagination( array('tab') )|raw}
</div>
</div>
{{endif}}
<div data-role='commentFeed' data-controller='core.front.core.moderation'>
{{if \count( $album->comments( NULL, NULL, 'date', 'asc', NULL, NULL, NULL, NULL, FALSE, isset( \IPS\Request::i()->showDeleted ) ) )}}
<form action="{$album->url()->csrf()->setQueryString( 'do', 'multimodComment' )->setPage('page',\IPS\Request::i()->page)}" method="post" data-ipsPageAction data-role='moderationTools'>
{{$commentCount=0; $timeLastRead = $album->timeLastRead(); $lined = FALSE;}}
{{foreach $album->comments( NULL, NULL, 'date', 'asc', NULL, NULL, NULL, NULL, FALSE, isset( \IPS\Request::i()->showDeleted ) ) as $comment}}
{{if !$lined and $timeLastRead and $timeLastRead->getTimestamp() < $comment->mapped('date')}}
{{if $lined = TRUE and $commentCount}}
<hr class="ipsUnreadBar">
{{endif}}
{{endif}}
{{$commentCount++;}}
{$comment->html()|raw}
{{endforeach}}
{template="commentMultimod" app="core" group="global" params="$album"}
</form>
{{else}}
<p class='ipsEmptyMessage' data-role='noComments'>{lang="no_comments"}</p>
{{endif}}
</div>
{{if $album->commentPageCount() > 1}}
<div class="ipsButtonBar">
<div class="ipsButtonBar__pagination">
{$album->commentPagination( array('tab') )|raw}
</div>
</div>
{{endif}}
{{if $album->commentForm() || $album->locked() || \IPS\Member::loggedIn()->restrict_post || \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings'] || !\IPS\Member::loggedIn()->checkPostsPerDay()}}
<div id='replyForm' data-role='replyArea' class='ipsComposeAreaWrapper {{if !$album->canComment()}}cTopicPostArea_noSize{{endif}}'>
{{if $album->commentForm()}}
{{if $album->locked()}}
<p class='ipsComposeArea_warning'><i class='fa-solid fa-circle-info'></i> {lang="album_locked_can_comment"}</p>
{{endif}}
{$album->commentForm()|raw}
{{else}}
{{if $album->locked()}}
{template="commentUnavailable" group="forms" location="front" app="core" params="'album_locked_cannot_comment'"}
{{elseif \IPS\Member::loggedIn()->restrict_post}}
{template="commentUnavailable" group="forms" location="front" app="core" params="'restricted_cannot_comment', \IPS\Member::loggedIn()->warnings(5,NULL,'rpa'), \IPS\Member::loggedIn()->restrict_post"}
{{elseif \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings']}}
{template="commentUnavailable" group="forms" location="front" app="core" params="'unacknowledged_warning_cannot_post', \IPS\Member::loggedIn()->warnings( 1, FALSE )"}
{{elseif !\IPS\Member::loggedIn()->checkPostsPerDay()}}
{template="commentUnavailable" group="forms" location="front" app="core" params="'member_exceeded_posts_per_day'"}
{{endif}}
{{endif}}
</div>
{{endif}}
</div>
</div>
</div>
]]></template>
<template template_group="browse" template_name="albumReviews" template_data="$album" template_location="front" template_app="gallery"><![CDATA[
<div data-controller='core.front.core.commentFeed' {{if settings.auto_polling_enabled}}data-autoPoll{{endif}} data-commentsType='reviews' data-baseURL='{$album->url()}' {{if $album->isLastPage('reviews')}}data-lastPage{{endif}} data-feedID='{$album->reviewFeedId}' id='reviews' data-follow-area-id="album-{$album->id}">
{{if $album->reviewForm()}}
{$album->reviewForm()|raw}
{{else}}
{{if $album->hasReviewed()}}
<!-- Already reviewed -->
{{elseif \IPS\Member::loggedin()->restrict_post}}
{{if \IPS\Member::loggedIn()->restrict_post == -1}}
{template="reviewUnavailable" group="forms" location="front" app="core" params="'restricted_cannot_comment'"}
{{else}}
{template="reviewUnavailable" group="forms" location="front" app="core" params="'restricted_cannot_comment', \IPS\Member::loggedIn()->warnings(5,NULL,'rpa'), \IPS\Member::loggedIn()->restrict_post"}
{{endif}}
{{elseif \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings']}}
{template="reviewUnavailable" group="forms" location="front" app="core" params="'unacknowledged_warning_cannot_post', \IPS\Member::loggedIn()->warnings( 1, FALSE )"}
{{endif}}
{{endif}}
{{if \count( $album->reviews( NULL, NULL, NULL, 'desc', NULL, NULL, NULL, NULL, isset( \IPS\Request::i()->showDeleted ) ) )}}
<div class="ipsButtonBar ipsButtonBar--top">
{{if $album->reviewPageCount() > 1}}
<div class="ipsButtonBar__pagination">
{$album->reviewPagination( array( 'tab', 'sort' ) )|raw}
</div>
{{endif}}
<div class='ipsButtonBar__end'>
<ul class="ipsDataFilters">
<li data-action="tableFilter">
<a href="{$album->url()->setQueryString( array( 'tab' => 'reviews', 'sort' => 'helpful' ) )->setPage('page',1)}" class="ipsDataFilters__button {{if !isset( request.sort ) or request.sort != 'newest'}}ipsDataFilters__button--active{{endif}}" data-action="filterClick">{lang="most_helpful"}</a>
</li>
<li data-action="tableFilter">
<a href="{$album->url()->setQueryString( array( 'tab' => 'reviews', 'sort' => 'newest' ) )->setPage('page',1)}" class="ipsDataFilters__button {{if isset( request.sort ) and request.sort == 'newest'}}ipsDataFilters__button--active{{endif}}" data-action="filterClick">{lang="newest"}</a>
</li>
</ul>
{template="commentMultimodHeader" app="core" group="global" params="$album, '#reviews', 'review'"}
</div>
</div>
<div data-role='commentFeed' data-controller='core.front.core.moderation'>
<form action="{$album->url()->csrf()->setQueryString( 'do', 'multimodReview' )->setPage('page',\IPS\Request::i()->page)}" method="post" data-ipsPageAction data-role='moderationTools'>
{{$reviewCount=0; $timeLastRead = $album->timeLastRead(); $lined = FALSE;}}
{{foreach $album->reviews( NULL, NULL, NULL, 'desc', NULL, NULL, NULL, NULL, isset( \IPS\Request::i()->showDeleted ) ) as $review}}
{{if !$lined and $timeLastRead and $timeLastRead->getTimestamp() < $review->mapped('date')}}
{{if $lined = TRUE and $reviewCount}}
<hr class="ipsUnreadBar">
{{endif}}
{{endif}}
{{$reviewCount++;}}
{$review->html()|raw}
{{endforeach}}
{template="commentMultimod" app="core" group="global" params="$album, 'review'"}
</form>
</div>
{{if $album->reviewPageCount() > 1}}
<div class="ipsButtonBar ipsButtonBar--bottom">
<div class="ipsButtonBar__pagination">
{$album->reviewPagination( array( 'tab', 'sort' ) )|raw}
</div>
</div>
{{endif}}
{{elseif !$album->canReview()}}
<p class="ipsEmptyMessage" data-role="noReviews">{lang="no_reviews"}</p>
{{endif}}
</div>]]></template>
<template template_group="browse" template_name="albums" template_data="$table, $headers, $albums" template_location="front" template_app="gallery"><![CDATA[{{foreach $albums as $album}}
{{if $album instanceof \IPS\Content\Item}}
{{$album = $album->asNode();}}
{{endif}}
<li class='ipsColumns ipsColumns--padding ipsColumns--lines i-border-bottom_1 {{if $album->asItem()->hidden()}} ipsModerated{{endif}} {$album->ui( 'css' )}' {$album->ui( 'dataAttributes' )}>
<div class='ipsColumns__secondary i-basis_380'>
<div class='ipsTitle ipsTitle--h4 ipsTitle--margin'>
<div class='ipsBadges'>
{{if \IPS\gallery\Image::containerUnread( $album )}}
<span class="ipsIndicator" data-ipsTooltip title="{lang="album_new_content"}"></span>
{{endif}}
{{if $album->asItem()->mapped('featured')}}
<span class="ipsBadge ipsBadge--icon ipsBadge--positive" data-ipsTooltip title='{lang="featured"}'><i class='fa-solid fa-star'></i></span>
{{endif}}
{{if $album->type === \IPS\gallery\Album::AUTH_TYPE_PRIVATE}}
<span class="ipsBadge ipsBadge--warning">{lang="album_private_badge"}</span>
{{elseif $album->type === \IPS\gallery\Album::AUTH_TYPE_RESTRICTED}}
<span class="ipsBadge ipsBadge--warning">{lang="album_friend_only_badge"}</span>
{{endif}}
</div>
<h3>
{{if \IPS\gallery\Image::containerUnread( $album )}}<strong>{{endif}}
<a href='{$album->url()}' title='{lang="view_this_album" sprintf="$album->_title"}'>{$album->_title}</a>
{{if \IPS\gallery\Image::containerUnread( $album )}}</strong>{{endif}}
</h3>
</div>
{{if $result = $album->truncated()}}
<div class='ipsRichText ipsTruncate_4'>
{$result|raw}
</div>
{{endif}}
<div class="i-margin-top_3 i-flex i-flex-wrap_wrap i-gap_2">
<ul class='ipsList ipsList--icons i-link-color_inherit i-font-weight_500 i-flex_11 i-basis_240'>
{{if !isset( \IPS\Request::i()->tab ) || \IPS\Request::i()->tab !== 'node_gallery_gallery'}}
<li class='i-color_soft'><i class='fa-regular fa-user-circle'></i> {lang="album_created_by"} {$album->owner()->link()|raw}</li>
{{endif}}
{{if $album->last_img_date}}
<li class='i-color_soft'><i class="fa-regular fa-clock"></i> {lang="updated"} {datetime="$album->last_img_date"}</li>
{{endif}}
</ul>
<ul class='ipsList ipsList--icons i-link-color_inherit i-font-weight_500 i-flex_11 i-basis_240'>
<li><i class="fa-solid fa-photo-film"></i> {lang="num_images" pluralize="$album->count_imgs"}</li>
{{if $album->use_comments && $album->comments > 0}}
<li><i class='fa-regular fa-comments'></i> {lang="gallery_album_num_comments_lc" pluralize="$album->comments"}</li>
{{endif}}
{{if $album->allow_comments && $album->count_comments > 0}}
<li><i class='fa-solid fa-comment'></i> {lang="gallery_image_comments_s" pluralize="$album->count_comments"}</li>
{{endif}}
{{if $album->use_reviews && $album->reviews > 0}}
<li><i class='fa-solid fa-comment'></i> {lang="gallery_album_num_reviews_lc" pluralize="$album->reviews"}</li>
{{endif}}
</ul>
</div>
{{if $table->canModerate()}}
<div class='i-margin-top_2'>
<input type='checkbox' data-role='moderation' name="moderate[{$album->_id}]" data-actions="{expression="implode( ' ', $table->multimodActions( $album ) )"}" data-state='' class='ipsInput ipsInput--toggle'>
</div>
{{endif}}
</div>
<div class='ipsColumns__primary'>
<ul class='ipsMasonry ipsMasonry--album-summary i-basis_80' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $album->_latestImages as $image }}
{{$imageWidth=isset( $image->_dimensions['small'][0] ) ? $image->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $image->_dimensions['small'][1] ) ? $image->_dimensions['small'][1] : 0;}}
<li class='ipsMasonry__item' {{if $imageWidth && $imageHeight}}style='--i-ratio:{$imageWidth}/{$imageHeight}'{{endif}} data-imageId="{$image->id}">
<figure class='ipsFigure'>
<a href='{$image->url( "getPrefComment" )}' class='ipsFigure__main' aria-label="{$image->caption}">
{{if $image->small_file_name}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{elseif $image->media}}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{{if ( $image->directContainer()->allow_comments && $image->container()->allow_comments && count($image->comments()) > 0 )}}
<div class='ipsFigure__footer'>
<span><i class='fa-solid fa-comment'></i> {expression="\count( $image->comments() )"}</span>
</div>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
</li>
{{endforeach}}
</ul>
</div>
</li>
{{endforeach}}]]></template>
<template template_group="browse" template_name="categories" template_data="" template_location="front" template_app="gallery"><![CDATA[<header class="ipsPageHeader ipsBox ipsBox--galleryCategoryHeader ipsPull">
<div class="ipsPageHeader__row">
<div class="ipsPageHeader__primary">
<h1 class="ipsPageHeader__title">{lang="gallery_title"}</h1>
</div>
{{if \IPS\gallery\Category::canOnAny('add')}}
<ul class="ipsButtons ipsButtons--main">
{template="categoryButtons" group="browse" params="\IPS\gallery\Category::canOnAny('add'), NULL, NULL"}
</ul>
{{endif}}
</div>
</header>
{{if settings.gallery_overview_show_categories}}
{{$clubNodes = (settings.clubs and settings.club_nodes_in_apps) ? \IPS\gallery\Category::clubNodes() : array();}}
{{if $rootCategories = \IPS\gallery\Category::roots()}}
<div class="ipsBox ipsBox--galleryCategories ipsPull">
<h2 class='ipsBox__header'>
<span>{{if $clubNodes}}{lang="community_image_categories"}{{else}}{lang="gallery_categories"}{{endif}}</span>
</h2>
<div class="ipsBox__content">
<i-data>
<ul class='ipsData ipsData--wallpaper ipsData--gallery-categories'>
{template="categoryRow" group="browse" params="NULL, NULL, $rootCategories"}
</ul>
</i-data>
</div>
</div>
{{endif}}
{{if settings.clubs and settings.club_nodes_in_apps and $clubNodes = \IPS\gallery\Category::clubNodes()}}
<div class="ipsBox ipsBox--galleryClubCategories ipsPull">
{{if $rootCategories}}<h2 class="ipsBox__header">{lang="club_node_gallery"}</h2>{{endif}}
<div class="ipsBox__content">
<i-data>
<ul class='ipsData ipsData--wallpaper ipsData--gallery-club-categories'>
{template="categoryRow" group="browse" params="NULL, NULL, $clubNodes"}
</ul>
</i-data>
</div>
</div>
{{endif}}
{{endif}}]]></template>
<template template_group="browse" template_name="categoriesSidebar" template_data="$currentCategory=NULL" template_location="front" template_app="gallery"><![CDATA[{{$categories = $currentCategory ? $currentCategory->children() : \IPS\gallery\Category::roots();}}
{{if \count($categories)}}
<div id='elGalleryCategories' class='i-margin-top_3'>
<h3 class='ipsBox__header'>{{if $currentCategory}}{lang="subcategories"}{{else}}{lang="categories"}{{endif}}</h3>
<div class='ipsSideMenu ipsSideMenu--truncate'>
<ul class='ipsSideMenu__list'>
{{foreach $categories as $category}}
<li>
<a href="{$category->url()}" class='ipsSideMenu_item'>
<strong class='ipsSideMenu__text'>{$category->_title}</strong>
<span class='ipsBadge ipsBadge--soft cGalleryCategoryCount'>{expression="\IPS\gallery\Image::contentCount( $category )"}</span>
</a>
{{if $category->hasChildren()}}
<ul class="ipsSideMenu__list">
{{foreach $category->children() as $idx => $subcategory}}
<li>
{{if $idx >= 5}}
<a href='{$category->url()}' class='ipsSideMenu_item'><span class='i-color_soft i-font-size_-2'>{lang="and_x_more" pluralize="\count( $category->children() ) - 5"}</span></a>
{{break;}}
{{else}}
<a href="{$subcategory->url()}" class='ipsSideMenu_item'>
<span class='ipsSideMenu__text'>{$subcategory->_title}</span>
<strong class='i-font-size_-2 cGalleryCategoryCount'>{expression="\IPS\gallery\Image::contentCount( $subcategory )"}</strong>
</a>
{{endif}}
</li>
{{endforeach}}
</ul>
{{endif}}
</li>
{{endforeach}}
</ul>
<a href='{url="app=gallery&module=gallery&controller=browse&do=categories" seoTemplate="gallery_categories"}' class='ipsButton ipsButton--wide ipsButton--small ipsButton--soft'>{lang="browse_categories"} <i class='fa-solid fa-caret-right'></i></a>
</div>
</div>
{{endif}}]]></template>
<template template_group="browse" template_name="category" template_data="$category, $albums, $table" template_location="front" template_app="gallery"><![CDATA[
{{if $club = $category->club()}}
{{if settings.clubs and settings.clubs_header == 'full'}}
{template="header" app="core" group="clubs" params="$club, $category"}
{{endif}}
<div id='elClubContainer'>
{{endif}}
<header class="ipsPageHeader ipsBox ipsBox--galleryCategoryHeader ipsPull">
<div class="ipsPageHeader__row">
<div data-ips-hook="header" class='ipsPageHeader__primary'>
<h1 data-ips-hook="title" class="ipsPageHeader__title">{$category->_title}</h1>
{{if \IPS\Member::loggedIn()->language()->get('gallery_category_' . $category->_id . '_desc')}}
{template="richText" group="global" app="core" location="global" params="$category->description, array('')"}
{{endif}}
</div>
<div data-ips-hook="buttons" class='ipsButtons'>
{{if \IPS\Application::appIsEnabled('cloud')}}
{template="analyticsButton" app="cloud" group="analytics" params="$category, $category->id"}
{{endif}}
{{$followerCount = \IPS\gallery\Image::containerFollowerCount( $category );}}
{template="follow" app="core" group="global" params="'gallery', 'category', $category->_id, $followerCount"}
</div>
</div>
{{if $category->show_rules}}
<div class="ipsPageHeader__row" data-controller="core.front.core.lightboxedImages">
{{if $category->show_rules == 1}}
<a href="{$category->rules_link}" class='ipsJS_show' data-ipsDialog data-ipsDialog-title="{lang="gallery_category_{$category->id}_rulestitle"}" data-ipsDialog-content="#elCategoryRules">{lang="category_rules"}</a>
<div id='elCategoryRules' class='ipsHide'>
{template="richText" group="global" app="core" location="global" params="\IPS\Member::loggedIn()->language()->addToStack('gallery_category_' . $category->id . '_rules'), array('')"}
</div>
{{elseif $category->show_rules == 2}}
<strong>{lang="gallery_category_{$category->id}_rulestitle"}</strong>
{template="richText" group="global" app="core" location="global" params="\IPS\Member::loggedIn()->language()->addToStack('gallery_category_' . $category->id . '_rules'), array('')"}
{{endif}}
</div>
{{endif}}
</header>
{{if $category->can('add') and ( $category->allow_albums != 2 or member.group['g_create_albums'] or \IPS\gallery\Album::loadForSubmit( $category ) )}}
<ul class="ipsButtons ipsButtons--main">
{template="categoryButtons" group="browse" params="$category->can('add'), $category, NULL"}
</ul>
{{endif}}
{{if $category->children()}}
<div class="ipsBox ipsBox--galleryCategoryChildren ipsBox--padding ipsPull">
{template="categoryGrid" group="browse" app="gallery" params="$category->children()"}
</div>
{{endif}}
{{if $albums}}
<div class='ipsBox ipsBox--galleryCategoryAlbums ipsPull'{{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{$albums|raw}
</div>
{{endif}}
{{if $table}}
<div class='ipsBox ipsBox--galleryCategoryTable ipsPull'>
{$table|raw}
</div>
{{endif}}
<div class="ipsBox ipsPageActions ipsBox--padding ipsPull ipsResponsive_showPhone">
{template="follow" app="core" group="global" params="'gallery', 'category', $category->_id, $followerCount"}
</div>
{{if $category->club()}}
</div>
{{endif}}]]></template>
<template template_group="browse" template_name="categoryButtons" template_data="$canSubmitImages, $currentCategory=NULL, $currentAlbum=NULL" template_location="front" template_app="gallery"><![CDATA[{{if !$currentCategory}}
<li>
<ul class="ipsButtonGroup">
<li>
<a href="{url="app=gallery" seoTemplate="gallery"}" class="ipsButton {{if !request.do=='categories'}} ipsButton--active{{endif}}" data-ipstooltip="" data-ipstooltip-safe="" title="{lang="gallery_overview"}" rel="nofollow">
<i class="fa-regular fa-images"></i>
</a>
</li>
<li>
<a href="{url="app=gallery&module=gallery&controller=browse&do=categories" seoTemplate="gallery_categories"}" class="ipsButton {{if request.do=='categories'}} ipsButton--active{{endif}}" data-ipstooltip="" data-ipstooltip-safe="" title="{lang="gallery_view_categories"}" rel="nofollow">
<i class="fa-solid fa-folder-tree"></i>
</a>
</li>
</ul>
</li>
{{endif}}
{{if $currentCategory AND $currentCategory->cover_img_id AND \IPS\gallery\Image::modPermission( 'edit', \IPS\Member::loggedIn(), $currentCategory )}}
<li>
<a href="{$currentCategory->url()->setQueryString( array( 'do' => 'unsetCoverPhoto' ) )->csrf()}" title='{lang="gallery_unset_cover"}' class='ipsButton ipsButton--text'>{lang="gallery_unset_cover"}</a>
</li>
{{endif}}
<li>
<a class="ipsButton ipsButton--primary" data-ipsDialog data-ipsDialog-size='medium' data-ipsDialog-extraClass='cGalleryDialog_outer' data-ipsDialog-destructOnClose='true' data-ipsDialog-remoteSubmit='true' {{if $currentAlbum}}href="{url="app=gallery&module=gallery&controller=submit&category={$currentCategory->id}&album={$currentAlbum->id}&_new=1" seoTemplate="gallery_submit"}" {{elseif $currentCategory}} href="{url="app=gallery&module=gallery&controller=submit&category={$currentCategory->id}&_new=1" seoTemplate="gallery_submit"}" {{else}} href="{url="app=gallery&module=gallery&controller=submit&_new=1" seoTemplate="gallery_submit"}" {{endif}} rel='nofollow noindex'><i class="fa-solid fa-photo-film"></i><span>{lang="add_gallery_image"}</span></a>
</li>]]></template>
<template template_group="browse" template_name="categoryCarousel" template_data="$categories" template_location="front" template_app="gallery"><![CDATA[{{if \count( $categories )}}
{{foreach $categories as $category}}
{{if $category->can('view')}}
<li class="ipsData__item {$category->ui( 'css' )}" {$category->ui( 'dataAttributes' )}>
<a href='{$category->url()}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{{if settings.clubs and settings.club_nodes_in_apps and $club = $category->club()}}{lang="club_node" sprintf="$club->name, $category->_title"}{{else}}{$category->_title}{{endif}}</span></a>
<div class="ipsData__image" aria-hidden="true">
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
<video preload="metadata" loading="lazy"{{if $category->lastImage()->masked_file_name }} poster="{file="$category->lastImage()->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$category->lastImage()->original_file_name" extension="gallery_Images"}{{if !$category->lastImage()->masked_file_name }}#t=1{{endif}}" type='{$category->lastImage()->file_type}' />
</video>
{{elseif $category->coverPhoto('small') !== NULL}}
<img src="{$category->coverPhoto('small')}" alt="" loading="lazy">
{{else}}
<i></i>
{{endif}}
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->lastImage()"}
{{elseif $category->coverPhoto('small') !== NULL}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->coverPhotoObject()"}
{{endif}}
</div>
<div class="ipsData__content">
<div class="ipsData__main">
{{if settings.clubs and settings.club_nodes_in_apps and $club = $category->club()}}
<div class="ipsData__club"><a href="{$club->url()}">{$club->name}</a></div>
{{endif}}
<h2 class='ipsData__title'><a href='{$category->url()}'>{$category->_title}</a></h2>
</div>
<div class="ipsData__extra">
{{if $category->lastImage() !== NULL}}
<div class="ipsData__last">
{datetime="$category->lastImage()->date"}
</div>
{{endif}}
<ul class='ipsData__stats'>
{{if $category->allow_comments and $category->_commentsForDisplay}}
<li data-statType='comments'>
<span class='ipsData__stats-icon' data-stat-value="{$category->_commentsForDisplay}" aria-hidden="true" data-ipstooltip title='{lang="cat_comment_count" pluralize="$category->_commentsForDisplay"}'></span>
<span class='ipsData__stats-label'>{lang="cat_comment_count" pluralize="$category->_commentsForDisplay"}</span>
</li>
{{endif}}
{{if $category->allow_albums and $category->public_albums}}
<li data-statType='albums'>
<span class='ipsData__stats-icon' data-stat-value="{$category->public_albums}" aria-hidden="true" data-ipstooltip title='{lang="cat_album_count" pluralize="$category->public_albums"}'></span>
<span class='ipsData__stats-label'>{lang="cat_album_count" pluralize="$category->public_albums"}</span>
</li>
{{endif}}
{{$count = \IPS\gallery\Image::contentCount( $category );}}
{{if $count}}
<li data-statType='images'>
<span class='ipsData__stats-icon' data-stat-value="{number="$count"}" aria-hidden="true" data-ipstooltip title='{lang="cat_img_count" pluralize="$count"}'></span>
<span class='ipsData__stats-label'>{lang="cat_img_count" pluralize="$count"}</span>
</li>
{{endif}}
</ul>
</div>
</div>
</li>
{{endif}}
{{endforeach}}
{{endif}}]]></template>
<template template_group="browse" template_name="categoryGrid" template_data="$categories" template_location="front" template_app="gallery"><![CDATA[
{{if \count( $categories )}}
<ul class='ipsGrid i-basis_300 i-text-align_center'{{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $categories as $category}}
<li class="{$category->ui( 'css' )}" {$category->ui( 'dataAttributes' )}>
<figure class='ipsFigure i-margin-bottom_2'>
<a href='{$category->url()}' class='ipsFigure__main i-aspect-ratio_8'>
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
<video preload="metadata" loading="lazy"{{if $category->lastImage()->masked_file_name }} poster="{file="$category->lastImage()->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$category->lastImage()->original_file_name" extension="gallery_Images"}{{if !$category->lastImage()->masked_file_name }}#t=1{{endif}}" type='{$category->lastImage()->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{elseif $category->coverPhoto('small') !== NULL}}
<img src="{$category->coverPhoto('small')}" alt="" loading="lazy">
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
<span class="ipsInvisible">{$category->_title}</span>
</a>
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->lastImage()"}
{{elseif $category->coverPhoto('small') !== NULL}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->coverPhotoObject()"}
{{endif}}
</figure>
<h2 class='ipsTitle ipsTitle--h5 ipsTitle--margin'>
<a href='{$category->url()}'>{$category->_title}</a>
</h2>
{{if settings.clubs and settings.club_nodes_in_apps and $club = $category->club()}}
<div class='i-color_soft'><a href='{$club->url()}'>{$club->name}</a></div>
{{endif}}
<ul class='ipsList ipsList--inline i-color_soft i-justify-content_center i-font-size_-1'>
{{if $category->lastImage() !== NULL}}<li><i class='fa-regular fa-clock'></i> {datetime="$category->lastImage()->date"}</li>{{endif}}
{{if $category->allow_comments && $category->_commentsForDisplay > 0}}
<li data-ipsTooltip title='{lang="cat_comment_count" pluralize="$category->_commentsForDisplay"}'><i class='fa-solid fa-comment'></i> {$category->_commentsForDisplay}</li>
{{endif}}
{{if $category->allow_albums && $category->public_albums > 0}}
<li data-ipsTooltip title='{lang="cat_album_count" pluralize="$category->public_albums"}'><i class='fa-solid fa-table-cells-large'></i> {$category->public_albums}</li>
{{endif}}
{{$count = \IPS\gallery\Image::contentCount( $category );}}
{{if $count > 0}}
<li data-ipsTooltip title='{lang="cat_img_count" pluralize="$count"}'><i class='fa-solid fa-camera'></i> {number="$count"}</li>
{{endif}}
</ul>
</li>
{{endforeach}}
</ul>
{{endif}}]]></template>
<template template_group="browse" template_name="categoryRow" template_data="$table, $headers, $categories" template_location="front" template_app="gallery"><![CDATA[{{foreach $categories as $category}}
{{if $category->can('view')}}
<li class="ipsData__item {$category->ui( 'css' )}" {$category->ui( 'dataAttributes' )}>
<a href='{$category->url()}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{{if settings.clubs and settings.club_nodes_in_apps and $club = $category->club()}}{lang="club_node" sprintf="$club->name, $category->_title"}{{else}}{$category->_title}{{endif}}</span></a>
<div class="ipsData__image" aria-hidden="true">
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
<video preload="metadata" loading="lazy"{{if $category->lastImage()->masked_file_name }} poster="{file="$category->lastImage()->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$category->lastImage()->original_file_name" extension="gallery_Images"}{{if !$category->lastImage()->masked_file_name }}#t=1{{endif}}" type='{$category->lastImage()->file_type}' />
</video>
{{elseif $category->coverPhoto('small') !== NULL}}
<img src="{$category->coverPhoto('small')}" alt="" loading="lazy">
{{else}}
<span class='ipsIcon ipsIcon--fa' aria-hidden="true"><i class="fa-ips"></i></span>
{{endif}}
{{if $category->lastImage() && $category->lastImage()->media && !$category->cover_img_id}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->lastImage()"}
{{elseif $category->coverPhoto('small') !== NULL}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$category->coverPhotoObject()"}
{{endif}}
</div>
<div class="ipsData__content">
<div class="ipsData__main">
{{if settings.clubs and settings.club_nodes_in_apps and $club = $category->club()}}
<div class="ipsData__club"><a href="{$club->url()}">{$club->name}</a></div>
{{endif}}
<h2 class='ipsData__title'><a href='{$category->url()}'>{$category->_title}</a></h2>
</div>
<div class="ipsData__extra">
{{if $category->lastImage() !== NULL}}
<div class="ipsData__last">
{datetime="$category->lastImage()->date"}
</div>
{{endif}}
<ul class='ipsData__stats'>
{{if $category->allow_comments and $category->_commentsForDisplay}}
<li data-statType='comments'>
<span class='ipsData__stats-icon' data-stat-value="{$category->_commentsForDisplay}" aria-hidden="true" data-ipstooltip title='{lang="cat_comment_count" pluralize="$category->_commentsForDisplay"}'></span>
<span class='ipsData__stats-label'>{lang="cat_comment_count" pluralize="$category->_commentsForDisplay"}</span>
</li>
{{endif}}
{{if $category->allow_albums and $category->public_albums}}
<li data-statType='albums'>
<span class='ipsData__stats-icon' data-stat-value="{$category->public_albums}" aria-hidden="true" data-ipstooltip title='{lang="cat_album_count" pluralize="$category->public_albums"}'></span>
<span class='ipsData__stats-label'>{lang="cat_album_count" pluralize="$category->public_albums"}</span>
</li>
{{endif}}
{{$count = \IPS\gallery\Image::contentCount( $category );}}
{{if $count}}
<li data-statType='images'>
<span class='ipsData__stats-icon' data-stat-value="{number="$count"}" aria-hidden="true" data-ipstooltip title='{lang="cat_img_count" pluralize="$count"}'></span>
<span class='ipsData__stats-label'>{lang="cat_img_count" pluralize="$count"}</span>
</li>
{{endif}}
</ul>
</div>
</div>
</li>
{{endif}}
{{endforeach}}]]></template>
<template template_group="browse" template_name="imageTable" template_data="$table, $headers, $rows, $quickSearch" template_location="front" template_app="gallery"><![CDATA[<div data-baseurl='{$table->baseUrl}' data-resort='{$table->resortKey}' data-controller='core.global.core.table{{if $table->canModerate()}},core.front.core.moderation{{endif}}{{if settings.gallery_nsfw}},gallery.front.global.nsfw{{endif}}'>
{{if \IPS\Request::i()->app == 'gallery'}}<h2 class='ipsBox__header' hidden>{lang="num_images" pluralize="$table->count"}</h2>{{endif}}
{{if $table->canModerate() OR ( $table->showAdvancedSearch AND ( (isset( $table->sortOptions ) and !empty( $table->sortOptions )) OR $table->advancedSearch ) ) OR !empty( $table->filters ) OR $table->pages > 1}}
<div class="ipsButtonBar ipsButtonBar--top i-border-start-start-radius_box i-border-start-end-radius_box">
{{if $table->pages > 1}}
<div class="ipsButtonBar__pagination" data-role="tablePagination">
{template="pagination" group="global" app="core" location="global" params="$table->baseUrl, $table->pages, $table->page, $table->limit"}
</div>
{{endif}}
<div class='ipsButtonBar__end i-gap_3 i-row-gap_1'>
<ul class="ipsDataFilters">
{{if $table->showAdvancedSearch AND ( ( isset( $table->sortOptions ) and !empty( $table->sortOptions ) ) OR $table->advancedSearch )}}
<li>
<button type="button" id="elSortByMenu_{$table->uniqueId}" popovertarget="elSortByMenu_{$table->uniqueId}_menu" class='ipsDataFilters__button' data-role='sortButton'>{lang="sort_by"} <i class="fa-solid fa-caret-down"></i></button>
<i-dropdown popover id="elSortByMenu_{$table->uniqueId}_menu" data-i-dropdown-selectable="radio">
<div class="iDropdown">
<ul class="iDropdown__items">
{{$custom = TRUE;}}
{{foreach $table->sortOptions as $k => $col}}
<li><a href="{$table->baseUrl->setQueryString( array( 'filter' => $table->filter, 'sortby' => $col, 'sortdirection' => $table->getSortDirection( $col ), 'page' => '1' ) )}" rel="nofollow" {{if $col === $table->sortBy}}{{$custom = FALSE;}}aria-selected="true"{{endif}} data-ipsMenuValue="{$col}" data-sortDirection='{$table->getSortDirection( $col )}'><i class="iDropdown__input"></i>{lang="{$table->langPrefix}sort_{$k}"}</a></li>
{{endforeach}}
{{if $table->advancedSearch}}
<li>
<a href='{$table->baseUrl->setQueryString( array( 'advancedSearchForm' => '1', 'filter' => $table->filter, 'sortby' => $table->sortBy, 'sortdirection' => $table->sortDirection ) )}' data-ipsDialog data-ipsDialog-title='{lang="custom_sort"}' rel="nofollow" {{if $custom}}aria-selected="true"{{endif}} data-i-dropdown-noselect><i class="iDropdown__input"></i>{lang="custom"}</a>
</li>
{{endif}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{if !empty( $table->filters )}}
<li>
<button type="button" id="elFilterByMenu_{$table->uniqueId}" popovertarget="elFilterByMenu_{$table->uniqueId}_menu" class='ipsDataFilters__button' data-role="tableFilterMenu">{lang="filter_by"} <i class="fa-solid fa-caret-down"></i></button>
<i-dropdown popover id="elFilterByMenu_{$table->uniqueId}_menu" data-i-dropdown-selectable="radio">
<div class="iDropdown">
<ul class="iDropdown__items">
<li>
<a href='{$table->baseUrl->setQueryString( array( 'filter' => '', 'sortby' => $table->sortBy, 'sortdirection' => $table->sortDirection, 'page' => '1' ) )}' rel="nofollow" data-action="tableFilter" data-ipsMenuValue='' {{if !$table->filter}}aria-selected="true"{{endif}}><i class="iDropdown__input"></i>{lang="{$table->langPrefix}all"}</a>
</li>
<li><hr></li>
{{foreach $table->filters as $k => $q}}
<li>
<a href='{$table->baseUrl->setQueryString( array( 'filter' => $k, 'sortby' => $table->sortBy, 'sortdirection' => $table->sortDirection, 'page' => '1' ) )}' rel="nofollow" data-action="tableFilter" data-ipsMenuValue='{$k}' {{if $k === $table->filter}}aria-selected="true"{{endif}}><i class="iDropdown__input"></i>{lang="{$table->langPrefix}{$k}"}</a>
</li>
{{endforeach}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{if $table->canModerate()}}
<li>
<button type="button" id="elCheck_{$table->uniqueId}" popovertarget="elCheck_{$table->uniqueId}_menu" class="ipsDataFilters__button" title='{lang="{$table->langPrefix}select_rows_tooltip"}' data-ipsTooltip data-ipsAutoCheck data-ipsAutoCheck-context="#elTable_{$table->uniqueId}">
<span class="cAutoCheckIcon"><i class="fa-regular fa-square"></i></span> <i class="fa-solid fa-caret-down"></i>
<span class='ipsNotification' data-role='autoCheckCount'>0</span>
</button>
<i-dropdown popover id="elCheck_{$table->uniqueId}_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
<li class="iDropdown__title">{lang="{$table->langPrefix}select_rows"}</li>
<li><button type="button" data-ipsMenuValue="all">{lang="all"}</button></li>
<li><button type="button" data-ipsMenuValue="none">{lang="none"}</button></li>
{{if \count($table->getFilters())}}
<li><hr></li>
{{foreach $table->getFilters() as $filter}}
<li><button type="button" data-ipsMenuValue="{$filter}">{lang="$filter"}</button></li>
{{endforeach}}
{{endif}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
</ul>
{{if member.member_id}}
<form action='{$table->baseUrl}' method='post' class='i-display_contents'>
<input type='hidden' name='csrfKey' value='{expression="\IPS\Session::i()->csrfKey"}'>
<ul class='ipsDataFilters'>
<li>
<button type='submit' name='thumbnailSize' value='thumb' data-ipsTooltip title='{lang="view_as_thumbnails"}' class='ipsDataFilters__button {{if !isset( \IPS\Request::i()->cookie['thumbnailSize'] ) OR \IPS\Request::i()->cookie['thumbnailSize'] == 'thumb' }}ipsDataFilters__button--active{{endif}}'><i class='fa-solid fa-table-cells-large'></i></button>
</li>
<li>
<button type='submit' name='thumbnailSize' value='large' data-ipsTooltip title='{lang="view_as_large"}' class='ipsDataFilters__button {{if isset( \IPS\Request::i()->cookie['thumbnailSize'] ) AND \IPS\Request::i()->cookie['thumbnailSize'] == 'large' }}ipsDataFilters__button--active{{endif}}'><i class='fa-solid fa-square'></i></button>
</li>
<li>
<button type='submit' name='thumbnailSize' value='rows' data-ipsTooltip title='{lang="view_as_list"}' class='ipsDataFilters__button {{if isset( \IPS\Request::i()->cookie['thumbnailSize'] ) AND \IPS\Request::i()->cookie['thumbnailSize'] == 'rows' }}ipsDataFilters__button--active{{endif}}'><i class='fa-solid fa-table-list'></i></button>
</li>
</ul>
</form>
{{endif}}
</div>
</div>
{{endif}}
{{if $table->canModerate()}}
<form action="{$table->baseUrl->csrf()}" method="post" data-role='moderationTools' data-ipsPageAction>
{{endif}}
{{if !empty( $rows ) }}
{{if isset( \IPS\Request::i()->cookie['thumbnailSize'] ) AND \IPS\Request::i()->cookie['thumbnailSize'] == 'large' AND \IPS\Request::i()->controller != 'search' }}
<div class='cGalleryLargeList' id='elTable_{$table->uniqueId}' data-role='tableRows'>
{template="tableRowsLarge" group="browse" app="gallery" params="$table, $headers, $rows"}
</div>
{{elseif isset( \IPS\Request::i()->cookie['thumbnailSize'] ) AND \IPS\Request::i()->cookie['thumbnailSize'] == 'rows' AND \IPS\Request::i()->controller != 'search' }}
<i-data>
<div class="ipsData ipsData--table ipsData--gallery-row-list cGalleryRowsList" id='elTable_{$table->uniqueId}' data-role='tableRows'>
{template="tableRowsRows" group="browse" app="gallery" params="$table, $headers, $rows"}
</div>
</i-data>
{{else}}
<ul class='ipsMasonry i-padding_1' id='elTable_{$table->uniqueId}' data-role='tableRows'>
{template="tableRowsThumbs" group="browse" app="gallery" params="$table, $headers, $rows"}
</ul>
{{endif}}
{{else}}
<p class='ipsEmptyMessage'>{lang="no_rows_in_table"}</p>
{{endif}}
{{if $table->canModerate()}}
<div class="ipsData__modBar ipsJS_hide" data-role="pageActionOptions">
<select class="ipsInput ipsInput--select i-basis_300" name="modaction" data-role="moderationAction">
{{if $table->canModerate('unhide')}}
<option value='approve' data-icon='check-circle'>{lang="approve"}</option>
{{endif}}
{{if $table->canModerate('feature') or $table->canModerate('unfeature')}}
<optgroup label="{lang="feature"}" data-icon='star' data-action='feature'>
{{if $table->canModerate('feature')}}
<option value='feature'>{lang="feature"}</option>
{{endif}}
{{if $table->canModerate('unhide')}}
<option value='unfeature'>{lang="unfeature"}</option>
{{endif}}
</optgroup>
{{endif}}
{{if $table->canModerate('pin') or $table->canModerate('unpin')}}
<optgroup label="{lang="pin"}" data-icon='thumb-tack' data-action='pin'>
{{if $table->canModerate('pin')}}
<option value='pin'>{lang="pin"}</option>
{{endif}}
{{if $table->canModerate('unpin')}}
<option value='unpin'>{lang="unpin"}</option>
{{endif}}
</optgroup>
{{endif}}
{{if $table->canModerate('hide') or $table->canModerate('unhide')}}
<optgroup label="{lang="hide"}" data-icon='eye' data-action='hide'>
{{if $table->canModerate('hide')}}
<option value='hide'>{lang="hide"}</option>
{{endif}}
{{if $table->canModerate('unhide')}}
<option value='unhide'>{lang="unhide"}</option>
{{endif}}
</optgroup>
{{endif}}
{{if $table->canModerate('lock') or $table->canModerate('unlock')}}
<optgroup label="{lang="lock"}" data-icon='lock' data-action='lock'>
{{if $table->canModerate('lock')}}
<option value='lock'>{lang="lock"}</option>
{{endif}}
{{if $table->canModerate('unlock')}}
<option value='unlock'>{lang="unlock"}</option>
{{endif}}
</optgroup>
{{endif}}
{{if $table->canModerate('move')}}
<option value='move' data-icon='arrow-right'>{lang="move"}</option>
{{endif}}
{{if $table->canModerate('split_merge')}}
<option value='merge' data-icon='level-up'>{lang="merge"}</option>
{{endif}}
{{if $table->canModerate('delete')}}
<option value='delete' data-icon='trash'>{lang="delete"}</option>
{{endif}}
{{if $table->canModerate( 'tag' )}}
<optgroup label='{lang="tag"}' data-icon='tag' data-action='tag'>
<option value='tag'>{lang="add_single_tag"}</option>
<option value='untag'>{lang="remove_single_tag"}</option>
</optgroup>
{{endif}}
{{if $table->savedActions}}
<optgroup label="{lang="saved_actions"}" data-icon='tasks' data-action='saved_actions'>
{{foreach $table->savedActions as $k => $v}}
<option value='savedAction-{$k}'>{$v}</option>
{{endforeach}}
</optgroup>
{{endif}}
</select>
<button type="submit" class="ipsButton ipsButton--primary">{lang="submit"}</button>
</div>
</form>
{{endif}}
{{if $table->pages > 1}}
<div class="ipsButtonBar ipsButtonBar--bottom">
<div class="ipsButtonBar__pagination" data-role="tablePagination">
{template="pagination" group="global" app="core" location="global" params="$table->baseUrl, $table->pages, $table->page, $table->limit"}
</div>
</div>
{{endif}}
</div>]]></template>
<template template_group="browse" template_name="index" template_data="$featured, $new, $recentlyUpdatedAlbums, $recentComments" template_location="front" template_app="gallery"><![CDATA[<header class="ipsPageHeader ipsPageHeader--galleryIndex">
<div class="ipsPageHeader__row">
<div data-ips-hook="header" class="ipsPageHeader__primary">
<h1 data-ips-hook="title" class="ipsPageHeader__title">{lang="gallery_title"}</h1>
</div>
{{if \IPS\gallery\Category::canOnAny('add')}}
<ul data-ips-hook="buttons" class="ipsButtons ipsButtons--main">
{template="categoryButtons" group="browse" params="\IPS\gallery\Category::canOnAny('add'), NULL, NULL"}
</ul>
{{endif}}
</div>
</header>
{{if settings.gallery_overview_show_categories}}
{{$clubNodes = ( settings.clubs and settings.club_nodes_in_apps ) ? \IPS\gallery\Category::clubNodes() : array();}}
<section class="ipsBox ipsBox--galleryCategories ipsPull">
<header class='ipsBox__header'>
<h2>{lang="gallery_categories"} &middot; <a href='{url="app=gallery&module=gallery&controller=browse&do=categories" seoTemplate="gallery_categories"}' class="i-color_soft">{lang="gallery_view_all_categories"}</a></h2>
{template="carouselNavigation" group="global" app="core" params="'gallery-categories'"}
</header>
<div class="ipsBox__content">
<i-data>
<ul class='ipsData ipsData--wallpaper ipsData--carousel ipsData--galleryCategories' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}} id='gallery-categories' tabindex="0">
{{if $rootCategories = \IPS\gallery\Category::roots()}}
{template="categoryCarousel" group="browse" app="gallery" params="$rootCategories"}
{{endif}}
{{if settings.clubs and settings.club_nodes_in_apps and $clubNodes = \IPS\gallery\Category::clubNodes()}}
{template="categoryCarousel" group="browse" app="gallery" params="$clubNodes"}
{{endif}}
</ul>
</i-data>
</div>
</section>
{{endif}}
{{if !empty( $featured )}}
<section class='ipsBox ipsBox--galleryFeatured ipsPull' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<header class='ipsBox__header'>
<h2>{lang="featured_images"}</h2>
{template="carouselNavigation" group="global" app="core" params="'gallery-featured'"}
</header>
<div class="ipsBox__content">
<ul class='ipsCarousel ipsCarousel--gallery-featured' id='gallery-featured' tabindex="0">
{{foreach $featured as $image}}
<li>
<figure class='ipsFigure ipsFigure--contain' {{if !$image->media }}style="--_backdrop: url('{file="$image->masked_file_name" extension="gallery_Images"}')"{{endif}}>
<a href="{$image->url()->setQueryString( 'context', 'featured' )}" class='ipsFigure__main' aria-hidden="true" tabindex="-1">
{{if $image->media }}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<img src='{file="$image->masked_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
{{endif}}
</a>
<div class='ipsFigure__header'>
{{if $image->hidden() === -1}}
<span class="ipsBadge ipsBadge--warning" data-ipsTooltip title='{$image->hiddenBlurb()}'><i class='fa-solid fa-eye-slash'></i> {lang="hidden"}</span>
{{elseif $image->hidden() === 1}}
<span class="ipsBadge ipsBadge--warning"><i class='fa-solid fa-triangle-exclamation'></i> {lang="pending_approval"}</span>
{{endif}}
</div>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image"}
<figcaption class='ipsFigure__footer'>
<div class='ipsFigure__title'>
{{if $image->unread()}}
<span class='ipsIndicator' data-ipsTooltip title='{{if $image->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>
{{endif}}
<a href="{$image->url()->setQueryString( 'context', 'featured' )}">{$image->caption}</a>
</div>
<div>
{lang="byline_nodate_itemprop" htmlsprintf="$image->author()->link( $image->warningRef() )"}
</div>
</figcaption>
</figure>
</li>
{{endforeach}}
</ul>
</div>
</section>
{{endif}}
{{if !empty( $new )}}
<section class='ipsBox ipsBox--newImages ipsPull'{{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
<h2 class='ipsBox__header'>{lang="new_images"}</h2>
<div class='i-padding_1'>
<ul class='ipsMasonry'>
{{foreach $new as $image}}
{{$imageWidth=isset( $image->_dimensions['small'][0] ) ? $image->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $image->_dimensions['small'][1] ) ? $image->_dimensions['small'][1] : 0;}}
<li class='ipsMasonry__item' {{if $imageWidth && $imageHeight}}style='--i-ratio:{$imageWidth}/{$imageHeight}'{{endif}}>
<figure class='ipsFigure ipsFigure--hover'>
<a href="{$image->url()->setQueryString( 'context', 'new' )}" class='ipsFigure__main' aria-hidden="true" tabindex="-1">
{{if $image->media }}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{endif}}
<span class='ipsInvisible'>{$image->caption}</span>
</a>
<div class='ipsFigure__header'>
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
</div>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image"}
<figcaption class='ipsFigure__footer'>
<div class='ipsFigure__title'>
{{if $image->unread()}}
<span class='ipsIndicator' data-ipsTooltip title='{{if $image->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>
{{endif}}
<a href="{$image->url()->setQueryString( 'context', 'new' )}">{$image->caption}</a>
</div>
<div>
{lang="byline_nodate_itemprop" htmlsprintf="$image->author()->link( $image->warningRef() )"}
</div>
</figcaption>
</figure>
</li>
{{endforeach}}
</ul>
</div>
</section>
{{endif}}
{{if \count( $recentlyUpdatedAlbums )}}
<section class='ipsBox ipsBox--updatedAlbums ipsPull' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<h2 class='ipsBox__header'>{lang="gallery_recently_updated_albums"}</h2>
<div class='i-padding_3'>
<ul class='ipsGrid i-basis_220 i-gap_3 i-text-align_center'>
{{foreach $recentlyUpdatedAlbums as $album}}
<li>
<figure class='ipsFigure'>
<a href='{$album->url()}' class='ipsFigure__main i-aspect-ratio_7' aria-hidden="true" tabindex="-1">
{{if $album->asNode()->coverPhoto('masked')}}
<img src="{$album->asNode()->coverPhoto('masked')}" alt="" loading="lazy">
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
<span class="ipsInvisible">{$album->name}</span>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$album->asNode()->coverPhotoObject()"}
</figure>
<h2 class='ipsTitle ipsTitle--h5 i-margin-top_2'>
<a href='{$album->url()}'>{$album->name}</a>
</h2>
<ul class='ipsList ipsList--inline i-justify-content_center i-font-size_-1 i-color_soft i-margin-top_2'>
<li data-ipsTooltip title='{lang="num_images" pluralize="$album->count_imgs"}'><i class='fa-solid fa-camera-retro i-opacity_5'></i> {$album->count_imgs}</li>
{{if $album->use_comments && $album->comments > 0}}
<li data-ipsTooltip title='{lang="gallery_album_num_comments_lc" pluralize="$album->comments"}'><i class='fa-solid fa-comment i-opacity_5'></i> {$album->comments}</li>
{{endif}}
{{if $album->allow_comments && $album->count_comments > 0}}
<li data-ipsTooltip title='{lang="gallery_image_comments_s" pluralize="$album->count_comments"}'><i class='fa-regular fa-images i-opacity_5'></i> {$album->count_comments}</li>
{{endif}}
</ul>
</li>
{{endforeach}}
</ul>
</div>
</section>
{{endif}}]]></template>
<template template_group="browse" template_name="indexSidebar" template_data="$canSubmitImages, $currentCategory=NULL, $currentAlbum=NULL" template_location="front" template_app="gallery"></template>
<template template_group="browse" template_name="miniAlbum" template_data="$album" template_location="front" template_app="gallery"><![CDATA[
<ol class='ipsMasonry ipsMasonry--mini-album i-basis_70 i-margin-bottom_2'>
{{foreach $album->_latestImages as $image}}
{{if $image->small_file_name}}
{{$imageWidth=isset( $image->_dimensions['small'][0] ) ? $image->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $image->_dimensions['small'][1] ) ? $image->_dimensions['small'][1] : 0;}}
<li class='ipsMasonry__item' {{if $imageWidth && $imageHeight}}style='--i-ratio:{$imageWidth}/{$imageHeight}'{{endif}} data-imageID='{$image->id}'>
<figure class='ipsFigure'>
<a href='{$image->url()->setQueryString( 'browse', 1 )}' title='{$image->caption}' class='ipsFigure__main'>
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
</a>
</figure>
</li>
{{else}}
<li class='ipsMasonry__item' data-imageID='{$image->id}'>
<figure class='ipsFigure'>
<a href='{$image->url()->setQueryString( 'browse', 1 )}' title='{$image->caption}' class='ipsFigure__main'>
{{if $image->media }}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{endif}}
</a>
</figure>
</li>
{{endif}}
{{endforeach}}
</ol>
<a href='{$album->url()}' class='i-color_soft i-font-weight_600'><i class="fa-regular fa-images"></i> {lang="view_entire_album" sprintf="$album->name"}</a>]]></template>
<template template_group="browse" template_name="noImages" template_data="$container" template_location="front" template_app="gallery"><![CDATA[
<div class='i-text-align_center i-padding_3'>
<p class='i-font-size_2'>{{if $container instanceof \IPS\gallery\Album}}{lang="no_images_in_album"}{{else}}{lang="no_images_in_cat"}{{endif}}</p>
{{if $container->can('add')}}
<a href='{url="app=gallery&module=gallery&controller=submit&_new=1" seoTemplate="gallery_submit"}{{if $container instanceof \IPS\gallery\Album}}&category={$container->category_id}&album={$container->id}{{else}}&category={$container->id}{{endif}}' class='ipsButton ipsButton--primary i-margin-top_3' data-ipsDialog data-ipsDialog-size='medium' data-ipsDialog-extraClass='cGalleryDialog_outer' data-ipsDialog-close='false' data-ipsDialog-destructOnClose='true' data-ipsDialog-remoteSubmit='true'>{lang="submit_first_image"}</a>
{{endif}}
</div>]]></template>
<template template_group="browse" template_name="tableRowsLarge" template_data="$table, $headers, $images" template_location="front" template_app="gallery"><![CDATA[{{foreach $images as $image}}
<div class='{{if $image->hidden()}}ipsModerated{{endif}} i-padding_3 i-border-bottom_1 {$image->ui( 'css' )}' data-imageId="{$image->id}" {$image->ui( 'dataAttributes' )}>
<figure class='ipsFigure'>
{{if $image->media }}
<a href='{$image->url()}' title='{lang="view_this_video" sprintf="$image->caption"}' class='ipsFigure__main'>
<video data-role="video" loading="lazy" {{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
</a>
{{else}}
<a href='{$image->url()}' title='{lang="view_this_image" sprintf="$image->caption"}' class='ipsFigure__main'>
{{$sizes = $image->_dimensions;}}
<img src='{file="$image->masked_file_name" extension="gallery_Images"}' width="{$sizes['large'][0]}" height="{$sizes['large'][1]}" alt="{$image->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image"}
</figure>
<div class='i-margin-top_2'>
<div class='i-flex i-flex-wrap_wrap i-align-items_center i-justify-content_space-between'>
<div class='ipsTitle ipsTitle--h4'>
<h2 class=''>
{{if $image->unread()}}<span class='ipsIndicator' data-ipsTooltip title='{{if $image->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>{{endif}}
{{if $image->prefix()}}
{template="prefix" group="global" app="core" params="$image->prefix( TRUE ), $image->prefix()"}
{{endif}}
<a href='{$image->url()}' title='{lang="view_this_image" sprintf="$image->caption"}'>
{{if $image->unread()}}<strong>{$image->caption}</strong>{{else}}{$image->caption}{{endif}}
</a>
</h2>
<div class='ipsBadges'>
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
</div>
</div>
<ul class='ipsList ipsList--inline'>
{{if $image->directContainer()->allow_comments && $image->comments > 0}}
<li>{lang="num_comments" pluralize="$image->comments"}</li>
{{endif}}
{{if $image->views > 0}}
<li>{lang="num_views_with_number" pluralize="$image->views"}</li>
{{endif}}
{{if $table->canModerate()}}
<li>
<input type='checkbox' data-role='moderation' name="moderate[{$image->id}]" data-actions="{{if $image->mapped('featured')}}unfeature{{else}}feature{{endif}} {{if $image->mapped('pinned')}}unpin{{else}}pin{{endif}} {{if $image->hidden() === -1}}unhide{{elseif $image->hidden() === 1}}approve{{else}}hide{{endif}} {{if $image->mapped('locked')}}unlock{{else}}lock{{endif}} move delete" data-state='{{if $image->tableStates()}}{$image->tableStates()}{{endif}}' class='ipsInput ipsInput--toggle'>
</li>
{{endif}}
</ul>
</div>
</div>
</div>
{{endforeach}}
]]></template>
<template template_group="browse" template_name="tableRowsRows" template_data="$table, $headers, $images" template_location="front" template_app="gallery"><![CDATA[{{if \count( $images )}}
{{foreach $images as $image}}
<div
class='ipsData__item ipsData__item--gallery-row {{if method_exists( $image, "tableClass" ) && $image->tableClass()}}ipsData__item--{$image->tableClass()}{{endif}} {{if $image->hidden()}}ipsModerated{{endif}} {$image->ui( "css" )}'
data-imageId="{$image->id}"
data-rowid="{$image->id}"
{$image->ui( 'dataAttributes' )}
{{if $image->unread()}}data-ips-unread{{else}}data-ips-read{{endif}}
>
<a href='{$image->url()}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$image->caption}</span></a>
<figure class='ipsFigure ipsFigure--ratio'>
{{if $image->media }}
<a href='{$image->url()}' title='{lang="view_this_video" sprintf="$image->caption"}' class='ipsFigure__main'>
<video data-role="video" loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
</a>
{{else}}
<a href='{$image->url()}' title='{lang="view_this_image" sprintf="$image->caption"}' class='ipsFigure__main'>
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
<div class='ipsData__content'>
<div class='ipsData__main'>
<div class='ipsData__title'>
<div class='ipsBadges'>
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
{{if $image->prefix()}}
{template="prefix" group="global" app="core" params="$image->prefix( TRUE ), $image->prefix()"}
{{endif}}
</div>
{{if $image->unread()}}
<span class='ipsIndicator' data-ipsTooltip title='{{if $image->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>
{{endif}}
<h4><a href='{$image->url()}' title='{lang="view_this_image" sprintf="$image->caption"} {{if $image->canEdit()}}{lang="click_hold_edit"}{{endif}}' {{if $image->canEdit()}}data-role="editableTitle"{{endif}}>
{$image->caption}
</a></h4>
</div>
<p class='ipsData__meta'>{lang="byline_nodate" htmlsprintf="$image->author()->link()"} &middot; {{if $image->updated == $image->date}}{lang="uploaded"}{{else}}{lang="updated"}{{endif}} {datetime="$image->updated"}</p>
<div class='ipsData__desc ipsRichText ipsTruncate_4 i-margin-top_2'>
{$image->truncated()|raw}
</div>
{{if \count( $image->tags() )}}
{template="tags" group="global" app="core" params="$image->tags()"}
{{endif}}
</div>
<div class="ipsData__extra">
<div class="ipsData__last" data-ips-hook="latestUserPhoto">
{{if $image->mapped('num_comments')}}
{template="userPhoto" app="core" group="global" params="$image->lastCommenter(), 'fluid'"}
{{else}}
{template="userPhoto" app="core" group="global" params="$image->author(), 'fluid'"}
{{endif}}
<div class="ipsData__last-text">
<div class="ipsData__last-primary">
{{if $image->mapped('num_comments')}}
{$image->lastCommenter()->link()|raw}
{{else}}
{$image->author()->link( NULL, NULL, $image->isAnonymous() )|raw}
{{endif}}
</div>
<div class="ipsData__last-secondary">
<a href='{$image->url( 'getLastComment' )}' title='{lang="get_last_post"}'>
{{if $image->mapped('last_comment')}}{datetime="$image->mapped('last_comment')"}{{else}}{datetime="$image->mapped('date')"}{{endif}}
</a>
</div>
</div>
</div>
<ul class='ipsData__stats'>
{{if $image->directContainer()->allow_comments}}
<li data-statType='comments' {{if !$image->comments}}data-v="0"{{endif}}>
<span class='ipsData__stats-icon' data-stat-value="{number='$image->comments'}" aria-hidden="true" data-ipstooltip title='{number="$image->comments" format="short"} {lang="comments" pluralize="$image->comments"}'></span>
<span class='ipsData__stats-label'>{number="$image->comments"} {lang="comments" pluralize="$image->comments"}</span>
</li>
{{endif}}
<li data-statType='views'>
<span class='ipsData__stats-icon' data-stat-value="{number='$image->views'}" aria-hidden="true" data-ipstooltip title='{number="$image->views" format="short"} {lang="num_views" pluralize="$image->views"}'></span>
<span class='ipsData__stats-label'>{number="$image->views"} {lang="num_views" pluralize="$image->views"}</span>
</li>
</ul>
</div>
</div>
{{if $table->canModerate()}}
<div class='ipsData__mod'>
<input type='checkbox' data-role='moderation' name="moderate[{$image->id}]" data-actions="{expression="implode( ' ', $table->multimodActions( $image ) )"}" data-state='{{if $image->unread() === -1 or $image->unread() === 1}}unread{{else}}read{{endif}} {{if $image->hidden() === -1}}hidden{{elseif $image->hidden === 1}}unapproved{{endif}} {{if $image->mapped('pinned')}}pinned{{endif}} {{if $image->mapped('featured')}}featured{{endif}} {{if $image->mapped('locked')}}locked{{endif}}' class="ipsInput ipsInput--toggle">
</div>
{{endif}}
</div>
{{endforeach}}
{{endif}}]]></template>
<template template_group="browse" template_name="tableRowsThumbs" template_data="$table, $headers, $images" template_location="front" template_app="gallery"><![CDATA[{{foreach $images as $image}}
{{$imageWidth=isset( $image->_dimensions['small'][0] ) ? $image->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $image->_dimensions['small'][1] ) ? $image->_dimensions['small'][1] : 0;}}
<li class='ipsMasonry__item {{if $image->hidden()}}ipsModerated{{endif}} {$image->ui( 'css' )}' {{if $imageWidth && $imageHeight}}style='--i-ratio:{$imageWidth}/{$imageHeight}'{{endif}} {$image->ui( 'dataAttributes' )}>
<figure class='ipsFigure ipsFigure--hover'>
<a href="{$image->url()->setQueryString( 'context', 'new' )}" class='ipsFigure__main' aria-hidden="true" tabindex="-1">
{{if $image->media }}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{endif}}
<span class="ipsInvisible">{$image->caption}</span>
</a>
<div class='ipsFigure__header'>
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
{{if $table->canModerate()}}
<input type='checkbox' data-role='moderation' name="moderate[{$image->id}]" data-actions="{{if $image->mapped('featured')}}unfeature{{else}}feature{{endif}} {{if $image->mapped('pinned')}}unpin{{else}}pin{{endif}} {{if $image->hidden() === -1}}unhide{{elseif $image->hidden() === 1}}approve{{else}}hide{{endif}} {{if $image->mapped('locked')}}unlock{{else}}lock{{endif}} move delete" data-state='{{if $image->tableStates()}}{$image->tableStates()}{{endif}}' class='ipsInput ipsInput--toggle'>
{{endif}}
</div>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image"}
<figcaption class='ipsFigure__footer'>
<div class='ipsFigure__title'>
{{if $image->unread()}}
<span class='ipsIndicator' data-ipsTooltip title='{{if $image->unread() === -1}}{lang="new"}{{else}}{lang="updated"}{{endif}}'></span>
{{endif}}
<a href="{$image->url()->setQueryString( 'context', 'new' )}">{$image->caption}</a>
</div>
<div>
{lang="byline_nodate_itemprop" htmlsprintf="$image->author()->link( $image->warningRef() )"}
{{if $image->directContainer()->allow_comments}}
{{if $image->comments > 0}}
&middot; <span>{lang="num_comments" pluralize="$image->comments"}</span>
{{endif}}
{{endif}}
</div>
</figcaption>
</figure>
</li>
{{endforeach}}]]></template>
<template template_group="dashboard" template_name="overview" template_data="$data" template_location="admin" template_app="gallery"><![CDATA[<i-data>
<ul class="ipsData ipsData--table ipsData--compact ipsData--dashboard-overview">
{{foreach $data as $k => $v}}
<li class="ipsData__item">
<span class="i-basis_180">
<strong>{lang="$k"}</strong>
</span>
<span class="">
{{if $k === 'total_disk_spaceg'}}
{filesize="$v"}
{{elseif $k === 'largest_image'}}
<a href='{$v->url()}' target='_blank' rel='noopener'>{$v->caption}</a> <span class="i-color_soft">({filesize="$v->file_size"})</span>
{{elseif $k === 'most_viewed_image'}}
<a href='{$v->url()}' target='_blank' rel='noopener'>{$v->caption}</a> <span class="i-color_soft">({lang="num_views_with_number" pluralize="$v->views"})</span>
{{else}}
{$v}
{{endif}}
</span>
</li>
{{endforeach}}
</ul>
</i-data>]]></template>
<template template_group="forms" template_name="commentTemplate" template_data="$id, $action, $elements, $hiddenValues, $actionButtons, $uploadField, $class=''" template_location="front" template_app="gallery"><![CDATA[{{$minimized = false;}}
<form accept-charset='utf-8' class="ipsFormWrap ipsFormWrap--gallery-comment" action="{$action}" method="post" {{if $uploadField}}enctype="multipart/form-data"{{endif}}>
<input type="hidden" name="{$id}_submitted" value="1">
{{foreach $hiddenValues as $k => $v}}
<input type="hidden" name="{$k}" value="{$v}">
{{endforeach}}
{{if $uploadField}}
<input type="hidden" name="MAX_FILE_SIZE" value="{$uploadField}">
<input type="hidden" name="plupload" value="{expression="md5( mt_rand() )"}">
{{endif}}
<div class='ipsComposeArea'>
<div class='ipsComposeArea_editor'>
{{foreach $elements as $collection}}
{{foreach $collection as $input}}
{{if $input->name == 'guest_name' or $input->name == 'guest_email'}}
<ul class='ipsForm ipsForm--vertical ipsForm--guest-gallery-comment' data-ipsEditor-toolList>
<li class='ipsFieldRow ipsFieldRow--fullWidth'>
<div class="ipsFieldRow__content">
{$input->html()|raw}
{{if $input->error}}
<div class="ipsFieldRow__warning" data-role="commentFormError">{lang="$input->error"}</div>
{{endif}}
</div>
</li>
</ul>
{{endif}}
{{endforeach}}
{{endforeach}}
{{foreach $elements as $collection}}
{{foreach $collection as $input}}
{{if $input instanceof \IPS\Helpers\Form\Editor}}
{{if $input->options['minimize'] !== NULL}}
{{$minimized = true;}}
{{endif}}
{$input->html( TRUE )|raw}
{{if $input->error}}
<div class="ipsFieldRow__warning" data-role="commentFormError">{lang="$input->error"}</div>
{{endif}}
{{endif}}
{{endforeach}}
{{endforeach}}
<div class='i-flex i-align-items_center i-flex-wrap_wrap i-gap_3 i-margin-top_2' data-ipsEditor-toolList {{if $minimized}}hidden{{endif}}>
<ul class='i-flex_91 i-flex i-flex-wrap_wrap i-gap_4 i-row-gap_1'>
{{foreach $elements as $collection}}
{{foreach $collection as $input}}
{{if !($input instanceof \IPS\Helpers\Form\Editor) && $input->name != 'guest_name' && $input->name != 'guest_email'}}
<li class='{{if !($input instanceof \IPS\Helpers\Form\Captcha)}}ipsComposeArea_formControl{{endif}}'>
{$input->html()|raw}
{{if $input->error}}
<div class="ipsFieldRow__warning" data-role="commentFormError">{lang="$input->error"}</div>
{{endif}}
</li>
{{endif}}
{{endforeach}}
{{endforeach}}
</ul>
<ul class='ipsButtons i-flex_11'>
{{foreach $actionButtons as $button}}
<li>{$button|raw}</li>
{{endforeach}}
</ul>
</div>
</div>
</div>
</form>]]></template>
<template template_group="forms" template_name="commentUnavailable" template_data="$lang, $warnings=array(), $ends=NULL" template_location="front" template_app="gallery"><![CDATA[<div class='ipsComposeArea ipsComposeArea--unavailable'>
<div class='ipsComposeArea_editor'>
<div class="ipsComposeArea_dummy">
<span class='i-color_warning'><i class="fa-solid fa-triangle-exclamation"></i> {lang="$lang"} {{if $ends !== NULL AND $ends > 0}}{lang="restriction_ends" sprintf="\IPS\DateTime::ts( $ends )->relative()"}{{endif}}</span>
{{if \count( $warnings) }}
{{foreach $warnings as $idx => $warning}}
{{if $idx === 0}}
<br><br>
<a href="{$warning->url()}" data-ipsDialog data-ipsDialog-size='narrow' class='ipsButton ipsButton--small ipsButton--soft'>{lang="view_warning_details"}</a>
{{endif}}
{{endforeach}}
{{endif}}
</div>
</div>
</div>]]></template>
<template template_group="forms" template_name="imageUpload" template_data="$name, $value, $minimize, $maxFileSize, $maxFiles, $maxChunkSize, $totalMaxSize, $allowedFileTypes, $pluploadKey, $multiple=FALSE, $editor=FALSE, $forceNoscript=FALSE, $template='core.attachments.fileItem', $existing=array(), $default=NULL, $supportsDelete = TRUE, $allowStockPhotos=FALSE" template_location="front" template_app="gallery"><![CDATA[<input name="{$name}" type="hidden" value="{$pluploadKey}">
{{if $forceNoscript}}
<input name="{$name}_noscript[]" type="file" {{if $multiple}}multiple{{endif}}>
<span class="i-color_soft i-font-size_-2">
{{if $allowedFileTypes !== NULL}}
<strong>{lang="form_upload_accepted"}</strong>
{expression="implode( ', ', $allowedFileTypes )"}
{{endif}}
{{if $multiple and $totalMaxSize}}
{{if $allowedFileTypes !== NULL}}
&middot;
{{endif}}
<strong>{lang="form_upload_total_max"}</strong>
{filesize="$totalMaxSize * 1048576"}
{{endif}}
{{if !$multiple or !$totalMaxSize or $maxChunkSize < $totalMaxSize}}
{{if $allowedFileTypes !== NULL or ( $multiple and $totalMaxSize )}}
&middot;
{{endif}}
<strong>{lang="form_upload_max"}</strong>
{$maxChunkSize}MB
{{endif}}
{{if $maxFiles}}
<br>{lang="form_upload_max_files" pluralize="$maxFiles"}
{{endif}}
</span>
{{else}}
<noscript>
<input name="{$name}_noscript[]" type="file" {{if $multiple}}multiple{{endif}}>
<span class="i-color_soft i-font-size_-2">
{{if $allowedFileTypes !== NULL}}
<strong>{lang="form_upload_accepted"}</strong>
{expression="implode( ', ', $allowedFileTypes )"}
{{endif}}
{{if $multiple and $totalMaxSize}}
{{if $allowedFileTypes !== NULL}}
&middot;
{{endif}}
<strong>{lang="form_upload_total_max"}</strong>
{filesize="$totalMaxSize * 1048576"}
{{endif}}
{{if !$multiple or !$totalMaxSize or $maxChunkSize < $totalMaxSize}}
{{if $allowedFileTypes !== NULL or ( $multiple and $totalMaxSize )}}
&middot;
{{endif}}
<strong>{lang="form_upload_max"}</strong>
{$maxChunkSize}MB
{{endif}}
{{if $maxFiles}}
<br>{lang="form_upload_max_files" pluralize="$maxFiles"}
{{endif}}
</span>
</noscript>
{{if $value}}
{{foreach $value as $id => $file}}
<input type="hidden" name="{$name}_existing[{$id}]" value="{$file->tempId}">
{{endforeach}}
{{endif}}
<div id="{$name}_drop_{expression="md5( mt_rand() )"}"
data-ipsUploader
{{if $maxFileSize}}data-ipsUploader-maxFileSize="{expression="number_format( $maxFileSize, 3, '.', '' )"}"{{endif}}
{{if $maxFiles}}data-ipsUploader-maxFiles="{$maxFiles}"{{endif}}
data-ipsUploader-maxChunkSize="{expression="number_format( $maxChunkSize, 3, '.', '' )"}"
{{if $allowedFileTypes}}data-ipsUploader-allowedFileTypes='{expression="json_encode( $allowedFileTypes )"}'{{endif}}
data-ipsUploader-name="{$name}"
data-ipsUploader-key="{$pluploadKey}"
{{if $multiple}}data-ipsUploader-multiple {{if $totalMaxSize}}data-ipsUploader-maxTotalSize="{expression="number_format( $totalMaxSize, 3, '.', '' )"}"{{endif}}{{endif}}
{{if $minimize}}data-ipsUploader-minimized{{endif}}
{{if $editor}}data-ipsUploader-insertable{{endif}}
data-ipsUploader-template='{$template}'
data-ipsUploader-existingFiles='{expression="json_encode( $existing )"}'
{{if isset( $default )}}data-ipsUploader-default='{$default}'{{endif}}
{{if $supportsDelete}}data-ipsUploader-supportsDelete{{else}}data-ipsUploader-supportsDelete='false'{{endif}}
{{if $allowStockPhotos}}data-ipsUploader-allowStockPhotos="{$allowStockPhotos}"{{endif}}
class='ipsUploader'
>
<div class="ipsAttachment_dropZone {{if $minimize}}ipsAttachment_dropZoneSmall{{endif}}">
<i class="fa-solid fa-upload ipsUploader__icon"></i>
{{if $minimize}}
<div class="ipsAttachment_loading ipsLoading--small ipsHide"><i class='fa-solid fa-circle-notch fa-spin fa-fw'></i></div>
<div class='ipsAttachment_dropZoneSmall_info'>
<span class="ipsAttachment_supportDrag">{{if $multiple}}{lang="form_upload_dad_mini"}{{else}}{lang="form_upload_dad_mini_one"}{{endif}}<br></span>
<span class="i-color_soft i-font-size_-2">
{{if $allowedFileTypes !== NULL}}
<strong>{lang="form_upload_accepted"}</strong>
{expression="implode( ', ', $allowedFileTypes )"}
{{endif}}
{{if $multiple and $totalMaxSize}}
{{if $allowedFileTypes !== NULL}}
&middot;
{{endif}}
<strong>{lang="form_upload_total_max"}</strong>
{filesize="$totalMaxSize * 1048576"}
{{endif}}
{{if $maxFileSize and ( !$multiple or !$totalMaxSize or $maxFileSize < $totalMaxSize )}}
{{if $allowedFileTypes !== NULL or ( $multiple and $totalMaxSize )}}
&middot;
{{endif}}
<strong>{lang="form_upload_max"}</strong>
{expression="round($maxFileSize,2)"}MB
{{endif}}
{{if $maxFiles}}
<br>{lang="form_upload_max_files" pluralize="$maxFiles"}
{{endif}}
</span>
</div>
<div class='ipsUploader__buttons'>
<a href="#" data-action='uploadFile' class="ipsButton ipsButton--small ipsButton--primary" id="{$name}_browse_{expression="md5( mt_rand() )"}">{{if $multiple}}{lang="form_upload_choose"}{{else}}{lang="form_upload_choose_one"}{{endif}}</a>
{{if $allowStockPhotos}}
<a href="#" data-action='stockPhoto' class="ipsButton ipsButton--small ipsButton--soft" id="{$name}_stockphoto_{expression="md5( mt_rand() )"}">{lang="form_upload_stockart_choose"}</a>
{{endif}}
</div>
{{else}}
<div class='ipsAttachment_dropZoneSmall_info'>
<span class="ipsAttachment_supportDrag">{{if $multiple}}{lang="form_upload_dad"}{{else}}{lang="form_upload_dad_one"}{{endif}}<br></span>
<div class="ipsAttachment_loading ipsLoading--small ipsHide"><i class='fa-solid fa-circle-notch fa-spin fa-fw'></i></div>
<br>
<span class="i-color_soft i-font-size_-2">
{{if $allowedFileTypes !== NULL}}
<strong>{lang="form_upload_accepted"}</strong>
{expression="implode( ', ', $allowedFileTypes )"}
{{endif}}
{{if $multiple and $totalMaxSize}}
{{if $allowedFileTypes !== NULL}}
&middot;
{{endif}}
<strong>{lang="form_upload_total_max"}</strong>
{filesize="$totalMaxSize * 1048576"}
{{endif}}
{{if $maxFileSize and ( !$multiple or !$totalMaxSize or $maxFileSize < $totalMaxSize )}}
{{if $allowedFileTypes !== NULL or ( $multiple and $totalMaxSize )}}
&middot;
{{endif}}
<strong>{lang="form_upload_max"}</strong>
{expression="round($maxFileSize,2)"}MB
{{endif}}
{{if $maxFiles}}
<br>{lang="form_upload_max_files" pluralize="$maxFiles"}
{{endif}}
</span>
</div>
<div class='ipsUploader__buttons'>
<a href="#" data-action='uploadFile' class="ipsButton ipsButton--small ipsButton--primary" id="{$name}_browse_{expression="md5( mt_rand() )"}">{{if $multiple}}{lang="form_upload_choose"}{{else}}{lang="form_upload_choose_one"}{{endif}}</a>
{{if $allowStockPhotos}}
<a href="#" data-action='stockPhoto' class="ipsButton ipsButton--small ipsButton--soft" id="{$name}_stockphoto_{expression="md5( mt_rand() )"}">{lang="form_upload_stockart_choose"}</a>
{{endif}}
</div>
{{endif}}
</div>
<div class="ipsAttachment_fileList">
<div data-role='fileList'></div>
<noscript>
{{if $value}}
{{foreach $value as $id => $file}}
{template="uploadFile" group="forms" location="global" app="core" params="$id, $file, $name, $editor, ( $template === 'core.attachments.imageItem' )"}
{{endforeach}}
{{endif}}
</noscript>
</div>
</div>
{{endif}}]]></template>
<template template_group="forms" template_name="reviewTemplate" template_data="$id, $action, $elements, $hiddenValues, $actionButtons, $uploadField, $class=''" template_location="front" template_app="gallery"><![CDATA[ <div class='ipsComposeArea ipsComposeArea--review' {{if \IPS\Member::loggedIn()->member_id}}data-controller='core.front.core.reviewForm'{{endif}}>
<div class='ipsComposeArea__photo'>{template="userPhoto" group="global" app="core" params="\IPS\Member::loggedIn(), 'fluid'"}</div>
<div class='ipsComposeArea_editor'>
<form accept-charset='utf-8' class="ipsFormWrap ipsFormWrap--gallery-review" action="{$action->setQueryString( '_review', 1 )}" method="post" {{if $uploadField}}enctype="multipart/form-data"{{endif}}>
<input type="hidden" name="{$id}_submitted" value="1">
{{foreach $hiddenValues as $k => $v}}
<input type="hidden" name="{$k}" value="{$v}">
{{endforeach}}
{{if $uploadField}}
<input type="hidden" name="MAX_FILE_SIZE" value="{$uploadField}">
<input type="hidden" name="plupload" value="{expression="md5( mt_rand() )"}">
{{endif}}
{{if !isset( \IPS\Request::i()->_review ) and \IPS\Member::loggedIn()->member_id}}
<div data-role='reviewIntro'>
<h3 class="i-margin-bottom_2"><strong class="i-color_hard i-font-weight_600">{lang="review_intro_1" sprintf="\IPS\Member::loggedIn()->name"}</strong> <span class='i-color_soft i-font-weight_500'>{lang="review_intro_2"}</span></h3>
<button type="button" class='ipsButton ipsButton--primary ipsButton--small' data-action='writeReview'><i class="fa-solid fa-pen-to-square"></i><span>{lang="write_a_review"}</span></button>
</div>
{{endif}}
<ul class='ipsForm ipsForm--vertical ipsForm--gallery-review' data-role='reviewForm' {{if !isset( \IPS\Request::i()->_review ) and \IPS\Member::loggedIn()->member_id}}hidden{{endif}}>
{{foreach $elements as $collection}}
{{foreach $collection as $input}}
{$input|raw}
{{endforeach}}
{{endforeach}}
<li class='ipsSubmitRow'>
<button type='submit' class='ipsButton ipsButton--primary'><i class="fa-solid fa-pen-to-square"></i><span>{lang="add_review"}</span></button>
</li>
</ul>
</form>
</div>
</div>]]></template>
<template template_group="forms" template_name="reviewUnavailable" template_data="$lang, $warnings=array(), $ends=NULL" template_location="front" template_app="gallery"><![CDATA[
<div class=''>
<div>
<strong class='i-color_warning'><i class="fa-solid fa-triangle-exclamation"></i> {lang="$lang"} {{if $ends !== NULL AND $ends > 0}}{lang="restriction_ends" sprintf="\IPS\DateTime::ts( $ends )->relative()"}{{endif}}</strong>
{{if \count( $warnings) }}
{{foreach $warnings as $idx => $warning}}
{{if $idx === 0}}
<br><br>
<a href="{$warning->url()}" data-ipsDialog data-ipsDialog-size='narrow' class='ipsButton ipsButton--small ipsButton--soft'>{lang="view_warning_details"}</a>
{{endif}}
{{endforeach}}
{{endif}}
</div>
</div>
<hr class='ipsHr'>]]></template>
<template template_group="global" template_name="approvalQueueItem" template_data="$item, $ref, $container, $title" template_location="front" template_app="gallery"><![CDATA[<div id="elApprovePanel" class='ipsBox ipsBox--galleryApprovalQueue'>
<article class="">
<div class='i-padding_3'>
<div class="ipsPhotoPanel">
{template="userPhoto" group="global" params="$item->author()"}
<div class='ipsPhotoPanel__text'>
<button type="button" id="user{$item->author()->member_id}" popovertarget="user{$item->author()->member_id}_menu" class="ipsTitle ipsTitle--h3">{$item->author()->name}<i class="fa-solid fa-caret-down"></i></button>
<i-dropdown popover id="user{$item->author()->member_id}_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if \IPS\Member::loggedIn()->modPermission('mod_can_warn')}}
<li><a href='{url="app=core&module=system&controller=warnings&do=warn&id={$item->author()->member_id}&ref={$ref}" seoTemplate="warn_add" seoTitle="$item->author()->members_seo_name"}' data-ipsDialog data-ipsDialog-title="{lang="warn_member" sprintf="$item->author()->name"}" data-ipsDialog-remoteSubmit data-ipsDialog-flashMessage="{lang="warning_issued"}" data-role="warnUserDialog">{lang="warn_user"}</a></li>
{{endif}}
{{if $item->author()->member_id != \IPS\Member::loggedIn()->member_id}}
{{if $item->author()->members_bitoptions['bw_is_spammer']}}
<li><a href='{url="app=core&module=system&controller=moderation&do=flagAsSpammer&id={$item->author()->member_id}&s=0" seoTemplate="flag_as_spammer" seoTitle="$item->author()->members_seo_name" csrf="true"}' data-confirm data-confirmSubMessage="{lang="spam_unflag_confirm"}" data-ipsMenuValue='spamFlagButton'>{lang="spam_unflag"}</a></li>
{{else}}
<li><a href='{url="app=core&module=system&controller=moderation&do=flagAsSpammer&id={$item->author()->member_id}&s=1" seoTemplate="flag_as_spammer" seoTitle="$item->author()->members_seo_name" csrf="true"}' data-confirm data-ipsMenuValue='spamFlagButton'>{lang="spam_flag"}</a></li>
{{endif}}
{{endif}}
<li><a href='{url="app=core&module=messaging&controller=messenger&do=compose&to={$item->author()->member_id}" seoTemplate="messenger_compose"}' data-ipsDialog data-ipsDialog-title='{lang="compose_new"}' data-ipsDialog-remoteSubmit data-ipsDialog-flashMessage="{lang="message_sent"}">{lang="message_send"}</a></li>
</ul>
</div>
</i-dropdown>
{{if $container}}
<p>{lang="posted_in_container"} <a href="{$container->url()}">{$container->_title}</a></p>
{{endif}}
<p class="i-color_soft">{lang="date_replied" htmlsprintf="\IPS\DateTime::ts( $item->mapped('date') )->html(FALSE)"}</p>
</div>
<p>
<a href='{$item->url()}' class='i-color_soft'>
<i class='fa-solid fa-{$item::$icon}'></i> {lang="$item::$title"}
</a>
</p>
</div>
</div>
<div class='i-background_2 i-padding_3'>
<div class='ipsBox ipsBox--galleryApprovalQueueItem'>
<h2 class="ipsBox__header"><a href="{$item->url()}">{$title}</a></h2>
<div class="ipsRichText ipsPost i-padding_3">
{{if $item->masked_file_name}}
<a href='{$item->url()}'>
<img src='{file="$item->masked_file_name" extension="gallery_Images"}' alt="{$item->caption}" loading="lazy">
</a>
{{else}}
<a href='{$item->url()}' class='ipsThumb'><i class="fa-solid fa-film"></i></a>
{{endif}}
</div>
</div>
</div>
</article>
</div>
{{if $reason = $item->approvalQueueReason()}}
<div class='ipsBox ipsBox--galleryApprovalQueueReason'>
<div class='ipsBox__header'>{lang="reason_for_approval"}</div>
<div class='i-background_2 i-border-bottom_3 i-padding_2'>
<p class='i-color_soft'>{$reason}</p>
</div>
</div>
{{endif}}]]></template>
<template template_group="global" template_name="comment" template_data="$item, $comment, $editorName, $app, $type, $class=''" template_location="front" template_app="gallery"><![CDATA[{{$idField = $comment::$databaseColumnId;}}
<div data-ips-hook="galleryCommentWrap" id='comment-{$comment->$idField}_wrap' data-controller='core.front.core.comment' data-feedid="{$comment->feedId}" data-commentApp='{$app}' data-commentType='{$type}' data-commentID="{$comment->$idField}" data-quoteData='{expression="json_encode( array('userid' => $comment->author()->member_id, 'username' => $comment->author()->name, 'timestamp' => $comment->mapped('date'), 'contentapp' => $app, 'contenttype' => $type, 'contentclass' => $class, 'contentid' => $item->id, 'contentcommentid' => $comment->$idField) )"}' class='ipsEntry__content js-ipsEntry__content'
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\IntersectionViewTracking' ) AND $hash=$comment->getViewTrackingHash()}}
data-view-hash="{$hash|raw}"
data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getViewTrackingData() ))" raw="true"}"
{{endif}}
>
<header class='ipsEntry__header'>
<div class='ipsEntry__header-align'>
<div class='ipsPhotoPanel'>
<div class='ipsAvatarStack' data-ips-hook="galleryCommentUserPhoto">
{template="userPhoto" app="core" group="global" params="$comment->author(), 'fluid', $comment->warningRef()"}
{{if ( \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Anonymous' ) AND !$comment->isAnonymous() ) and $comment->author()->canHaveAchievements() and \IPS\core\Achievements\Rank::show() and $rank = $comment->author()->rank()}}
{$rank->html( 'ipsAvatarStack__rank' )|raw}
{{endif}}
</div>
<div class='ipsPhotoPanel__text'>
<div data-ips-hook="galleryCommentUsername" class='ipsEntry__username'>
<h3>{template="userLink" app="core" group="global" params="$comment->author(), $comment->warningRef(), NULL, \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Anonymous' ) ? $comment->isAnonymous() : FALSE"}</h3>
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Anonymous' ) AND !$comment->isAnonymous()}}
<span class='ipsEntry__group'>
{{if $comment->author()->modShowBadge()}}
<a href='{url="app=core&module=staffdirectory&controller=directory" seoTemplate="staffdirectory"}' class="ipsEntry__moderatorBadge" data-ipsTooltip title='{lang="member_is_moderator" sprintf="$comment->author()->name"}'>
{expression="\IPS\Member\Group::load( $comment->author()->member_group_id )->formattedName" raw="true"}
</a>
{{else}}
{expression="\IPS\Member\Group::load( $comment->author()->member_group_id )->formattedName" raw="true"}
{{endif}}
</span>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Anonymous' ) and $comment->isAnonymous() and \IPS\Member::loggedIn()->modPermission('can_view_anonymous_posters')}}
<a data-ipsHover data-ipsHover-width="370" data-ipsHover-onClick href="{$comment->url( 'reveal' )->csrf()}"><span class="ipsAnonymousIcon" data-ipsTooltip title='{lang="post_anonymously_reveal"}'></span></a>
{{endif}}
</div>
<p class='ipsPhotoPanel__secondary'>
{{if ! \IPS\Output::i()->reduceLinks()}}<a href='{$comment->shareableUrl()}'>{{endif}}{$comment->dateLine()|raw}{{if ! \IPS\Output::i()->reduceLinks()}}</a>{{endif}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\EditHistory' ) and $comment->editLine()}}
({lang="edited_lc"})
{{endif}}
</p>
</div>
</div>
{{if $menu = $comment->menu()}}
{{if $menu->hasContent()}}
{$menu|raw}
{{endif}}
{{if \count( $item->commentMultimodActions() )}}
<input type="checkbox" name="multimod[{$comment->$idField}]" value="1" data-role="moderation" data-actions="{{if $comment->canSplit()}}split merge{{endif}} {{if $comment->hidden() === -1 AND $comment->canUnhide()}}unhide{{elseif $comment->hidden() === 1 AND $comment->canUnhide()}}approve{{elseif $comment->canHide()}}hide{{endif}} {{if $comment->canDelete()}}delete{{endif}}" data-state='{{if $comment->tableStates()}}{$comment->tableStates()}{{endif}}' class="ipsInput ipsInput--toggle">
{{endif}}
{{endif}}
{{if $comment->author()->member_id}}
<!-- Expand mini profile -->
<button class='ipsEntry__topButton ipsEntry__topButton--profile' type='button' aria-controls='mini-profile-{$comment->$idField}' aria-expanded='false' data-ipscontrols data-ipscontrols-src="{$comment->authorMiniProfileUrl}" aria-label='{lang="author_stats"}'><i class="fa-solid fa-chevron-down" aria-hidden="true"></i></button>
{{endif}}
</div>
{{if $comment->author()->member_id}}
{template="miniProfileWrap" app="core" group="global" params="$comment->author(), $comment->$idField, remoteLoading:true"}
{{endif}}
</header>
<div class='ipsEntry__post'>
{{if $comment->author()->hasHighlightedReplies() || ( \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and $comment->isHighlighted() ) OR $comment->isFeatured()}}
<ul class='ipsBadges' data-ips-hook="galleryCommentBadges">
{{if $comment->author()->hasHighlightedReplies()}}
<li><span class='ipsBadge ipsBadge--highlightedGroup'>{expression="\IPS\Member\Group::load( $comment->author()->highlightedGroup() )->name" raw="true"}</span></li>
{{endif}}
{{if $comment->isFeatured()}}
<li><span class='ipsBadge ipsBadge--positive'>{lang="this_is_a_featured_post"}</span></li>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and $comment->isHighlighted()}}
<li><span class='ipsBadge ipsBadge--popular'>{lang="this_is_a_popular_comment"}</span></li>
{{endif}}
</ul>
{{endif}}
{{if member.modPermission('mod_see_warn') and $comment->warning}}
{template="commentWarned" group="global" app="core" params="$comment"}
{{endif}}
{{if $comment->hidden() AND $comment->hidden() != -2}}
<div class='ipsEntry__hiddenMessage'>{$comment->hiddenBlurb()}</div>
{{elseif $comment->hidden() == -2}}
<div class='ipsEntry__hiddenMessage'>{$comment->deletedBlurb()}</div>
{{endif}}
{{if $comment->hidden() === 1 && $comment->author()->member_id == \IPS\Member::loggedIn()->member_id}}
<div class='i-margin-bottom_3'><strong class='i-color_warning'><i class='fa-solid fa-circle-info'></i> {lang="comment_awaiting_approval"}</strong></div>
{{endif}}
<div data-ips-hook="galleryComment" class='ipsRichText ipsRichText--user' data-role='commentContent' data-controller='core.front.core.lightboxedImages'>
{$comment->content()|raw}
{{if $comment->editLine()}}
{$comment->editLine()|raw}
{{endif}}
</div>
</div>
{{if ( $comment->hidden() !== 1 && \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and settings.reputation_enabled and $comment->hasReactionBar() ) || ( $comment->hidden() === 1 && ( $comment->canUnhide() || $comment->canDelete() ) ) || ( $comment->hidden() === 0 and $item->canComment() and $editorName ) }}
<div data-ips-hook="galleryCommentFooter" class='ipsEntry__footer'>
<menu class='ipsEntry__controls' data-role="commentControls" data-ips-hook="galleryCommentControls">
{{if $comment->hidden() === 1 && ( $comment->canUnhide() || $comment->canDelete() )}}
{{if $comment->canUnhide()}}
<li><a href='{$comment->url('unhide')->csrf()}' class='ipsButton ipsButton--small ipsButton--positive' data-action='approveComment'><i class='fa-solid fa-check'></i><span>{lang="approve"}</span></a></li>
{{endif}}
{{if $comment->canDelete()}}
<li><a href='{$comment->url('delete')->csrf()->setPage('page',\IPS\Request::i()->page)}' data-action='deleteComment' data-updateOnDelete="#commentCount"><i class='fa-solid fa-xmark'></i><span>{lang="delete"}</span></a></li>
{{endif}}
{{if $comment->canEdit() || $comment->canSplit() || $comment->canHide()}}
<li>
<button type="button" id="elControlsCommentsSub_{$comment->$idField}" popovertarget="elControlsCommentsSub_{$comment->$idField}_menu"><span>{lang="moderator_tools"}</span><i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elControlsCommentsSub_{$comment->$idField}_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if $comment->canEdit()}}
{{if $comment->mapped('first') and $comment->item()->canEdit()}}
<li><a href='{$comment->item()->url()->setQueryString( 'do', 'edit' )}'>{lang="edit"}</a></li>
{{else}}
<li><a href='{$comment->url('edit')}' data-action='editComment'>{lang="edit"}</a></li>
{{endif}}
{{endif}}
{{if $comment->canSplit()}}
<li><a href='{$comment->url('split')}' data-action='splitComment' data-ipsDialog data-ipsDialog-title="{lang="split_to_new" sprintf="\IPS\Member::loggedIn()->language()->addToStack( $item::$title )"}">{lang="split"}</a></li>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Hideable' ) and $comment->canHide()}}
<li><a href='{$comment->url('hide')->csrf()}' data-ipsDialog data-ipsDialog-title="{lang="hide"}">{lang="hide"}</a></li>
{{endif}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{else}}
{{if $comment->hidden() === 0 and $item->canComment() and $editorName}}
<li data-ipsQuote-editor='{$editorName}' data-ipsQuote-target='#comment-{$comment->$idField}' class='ipsJS_show'>
<button class='cMultiQuote ipsHide' data-action='multiQuoteComment' data-ipsTooltip data-ipsQuote-multiQuote data-mqId='mq{$comment->$idField}' aria-label='{lang="multiquote"}'><i class='fa-solid fa-plus'></i></button>
</li>
<li data-ipsQuote-editor='{$editorName}' data-ipsQuote-target='#comment-{$comment->$idField}' class='ipsJS_show'>
<a href='#' data-action="quoteComment" data-ipsQuote-singleQuote><i class="fa-solid fa-quote-left" aria-hidden="true"></i><span>{lang="quote"}</span></a>
</li>
{{if \IPS\Application::appIsEnabled('cloud')}}
<li>{template="spam" app="cloud" group="spam" params="$comment, FALSE"}</li>
{{endif}}
{{endif}}
{{endif}}
<li class='ipsHide' data-role='commentLoading'>
<span class='ipsLoading ipsLoading--tiny'></span>
</li>
</menu>
{{if $comment->hidden() !== 1 && \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and settings.reputation_enabled and $comment->hasReactionBar()}}
{template="reputation" group="global" app="core" params="$comment"}
{{endif}}
</div>
{{endif}}
{{if ! \IPS\Output::i()->reduceLinks()}}
{template="sharemenu" group="global" app="core" params="$comment"}
{{endif}}
</div>]]></template>
<template template_group="global" template_name="commentContainer" template_data="$item, $comment" template_location="front" template_app="gallery"><![CDATA[{{$idField = $comment::$databaseColumnId;}}
{{$itemClassSafe = str_replace( '\\', '_', mb_substr( $comment::$itemClass, 4 ) );}}
{{if $comment->isIgnored()}}
<div class='ipsEntry ipsEntry--ignored' id='elIgnoreComment_{$comment->$idField}' data-ignoreCommentID='elComment_{$comment->$idField}' data-ignoreUserID='{$comment->author()->member_id}'>
<i class="fa-solid fa-user-slash"></i> {lang="ignoring_content" sprintf="$comment->author()->name"} <button type="button" id="elIgnoreComment_{$comment->$idField}" popovertarget="elIgnoreComment_{$comment->$idField}_menu" data-action="ignoreOptions" title='{lang="see_post_ignore_options"}'>{lang="options"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elIgnoreComment_{$comment->$idField}_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
<li><button type="button" data-ipsMenuValue='showPost'>{lang="show_this_comment"}</button></li>
<li><hr></li>
<li><a href='{url="app=core&module=system&controller=ignore&do=remove&id={$comment->author()->member_id}" seoTemplate="ignore"}' data-ipsMenuValue='stopIgnoring'>{lang="stop_ignoring_posts_by" sprintf="$comment->author()->name"}</a></li>
<li><a href='{url="app=core&module=system&controller=ignore" seoTemplate="ignore"}'>{lang="change_ignore_preferences"}</a></li>
</ul>
</div>
</i-dropdown>
</div>
{{endif}}
<a id='findComment-{$comment->$idField}'></a>
<a id='comment-{$comment->$idField}'></a>
<article id='elComment_{$comment->$idField}' class="ipsEntry js-ipsEntry ipsEntry--simple ipsEntry--gallery-comment {{if ( \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and $comment->isHighlighted() ) OR $comment->isFeatured()}}ipsEntry--popular{{endif}} {{if $comment->isIgnored()}}ipsHide{{endif}} {{if $comment->author()->hasHighlightedReplies()}}ipsEntry--highlighted{{endif}} {{if $comment->hidden() OR $item->hidden() == -2}}ipsModerated{{endif}}" {{if $comment->author()->hasHighlightedReplies()}}data-memberGroup="{$comment->author()->member_group_id}"{{endif}}>
{template="comment" group="global" app="gallery" params="$item, $comment, $item::$formLangPrefix . 'comment', $item::$application, $item::$module, $itemClassSafe"}
</article>]]></template>
<template template_group="global" template_name="commentTableHeader" template_data="$comment, $image" template_location="front" template_app="gallery"><![CDATA[
<div class='i-flex i-gap_2'>
<div class='i-flex_00 i-basis_60'>
{template="thumbImage" group="global" app="core" params="$image->small_file_name, $image->caption, 'small', '', 'view_this', $image->url(), 'gallery_Images'"}
</div>
<div class='i-flex_11'>
<h3 class='ipsTitle ipsTitle--h4'><a href='{$image->url()}' title='{lang="view_this_image" sprintf="$image->caption"}'>{$image->caption}</a></h3>
<p class='i-color_soft i-link-color_inherit'>{lang="in"} <a href='{$image->container()->url()}'>{$image->container()->_title}</a></p>
{{if $image->container()->allow_rating}}
{template="rating" group="global" location="front" app="core" params="'large', $image->rating"} &nbsp;&nbsp;
{{endif}}
<span>{{if $image->container()->allow_comments}}&nbsp;&nbsp;{{if !$image->comments}}<span class='i-color_soft'>{{endif}}<i class='fa-solid fa-comment'></i> {$image->comments}{{endif}}{{if !$image->comments}}</span>{{endif}}</span>
</div>
</div>]]></template>
<template template_group="global" template_name="embedAlbumComment" template_data="$comment, $item, $url" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-album-comment' {{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{template="embedHeader" group="embed" app="core" params="$comment, $item->mapped('title'), $comment->mapped('date'), $url"}
<div class=''>
{{if $item->asNode()->coverPhoto('small')}}
<figure class='ipsFigure ipsFigure--embed-hero'>
<a href='{$item->asNode()->url()}' class='ipsFigure__main'>
<img src='{$item->asNode()->coverPhoto('masked')}' alt="{$item->asNode()->name}" loading="lazy">
</a>
</figure>
{{endif}}
{{$images = \IPS\Gallery\Image::getItemsWithPermission( array( array( 'image_album_id=?', $item->asNode()->id ) ), ( $item->asNode()->sort_options == 'title' ) ? 'image_caption ASC' : \IPS\gallery\Image::$databasePrefix . \IPS\gallery\Image::$databaseColumnMap[ $item->asNode()->sort_options ] . ' DESC', 19 );}}
{{if \count( $images )}}
<ul class='cGalleryEmbed_albumStrip i-background_2'>
{{foreach $images as $albumImage}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumImage->url()}' class='ipsFigure__main'>
{{if $albumImage->masked_file_name}}
<img src='{file="$albumImage->masked_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$albumImage, FALSE"}
</figure>
</li>
{{endforeach}}
{{$albumNode = $item->asNode();}}
{{if $albumNode->count_imgs > 19}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumNode->url()}' class='ipsFigure__main'><span>+{expression="$albumNode->count_imgs - 19"}</span></a>
</figure>
</li>
{{endif}}
</ul>
{{endif}}
<div class='i-margin-bottom_3 i-padding-top_3 i-link-color_inherit'>
{template="embedOriginalItem" group="embed" app="core" params="$item"}
</div>
<div class='ipsRichEmbed__snippet'>
{$comment->truncated(TRUE)|raw}
</div>
{{if settings.reputation_enabled and \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and \count( $comment->reactions() )}}
<ul class='ipsList ipsList--inline i-margin-top_2'>
<li>
{template="reactionOverview" app="core" group="global" params="$comment, TRUE, 'small'"}
</li>
</ul>
{{endif}}
</div>
</div>]]></template>
<template template_group="global" template_name="embedAlbumReview" template_data="$comment, $item, $url" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-album-review' {{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{template="embedHeader" group="embed" app="core" params="$comment, $item->mapped('title'), $comment->mapped('date'), $url"}
<div class=''>
{{if $item->asNode()->coverPhoto('small')}}
<figure class='ipsFigure ipsFigure--embed-hero'>
<a href='{$item->asNode()->url()}' class='ipsFigure__main'>
<img src='{$item->asNode()->coverPhoto('masked')}' alt="{$item->asNode()->name}" loading="lazy">
</a>
</figure>
{{endif}}
{{$images = \IPS\Gallery\Image::getItemsWithPermission( array( array( 'image_album_id=?', $item->asNode()->id ) ), ( $item->asNode()->sort_options == 'title' ) ? 'image_caption ASC' : \IPS\gallery\Image::$databasePrefix . \IPS\gallery\Image::$databaseColumnMap[ $item->asNode()->sort_options ] . ' DESC', 19 );}}
{{if \count( $images )}}
<ul class='cGalleryEmbed_albumStrip i-background_2'>
{{foreach $images as $albumImage}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumImage->url()}' class='ipsFigure__main'>
{{if $albumImage->masked_file_name}}
<img src='{file="$albumImage->masked_file_name" extension="gallery_Images"}' alt='' loading="lazy">
{{else}}
<i class="ipsFigure__play"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$albumImage, FALSE"}
</figure>
</li>
{{endforeach}}
{{$albumNode = $item->asNode();}}
{{if $albumNode->count_imgs > 19}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumNode->url()}' class='ipsFigure__main'><span>+{expression="$albumNode->count_imgs - 19"}</span></a>
</figure>
</li>
{{endif}}
</ul>
{{endif}}
<div class='i-margin-bottom_3 i-padding-top_3 i-link-color_inherit'>
{template="embedOriginalItem" group="embed" app="core" params="$item"}
</div>
{template="rating" app="core" params="'veryLarge', $comment->mapped('rating')" group="global"}
{{if $comment->mapped('votes_total')}}
<p>{$comment->helpfulLine()|raw}</p>
{{endif}}
<hr class='ipsHr'>
<div class='ipsRichEmbed__snippet'>
{$comment->truncated(TRUE)|raw}
</div>
{{if settings.reputation_enabled and \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and \count( $comment->reactions() )}}
<ul class='ipsList ipsList--inline i-margin-top_2'>
<li>
{template="reactionOverview" app="core" group="global" params="$comment, TRUE, 'small'"}
</li>
</ul>
{{endif}}
</div>
</div>]]></template>
<template template_group="global" template_name="embedAlbums" template_data="$albumItem, $albumNode, $url" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-album' {{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{template="embedHeader" group="embed" app="core" params="$albumItem, $albumItem->mapped('title'), $albumItem->mapped('date'), $url"}
<div class=''>
{{if $albumNode->coverPhoto('small')}}
<figure class='ipsFigure ipsFigure--embed-hero'>
<a href='{$albumNode->url()}' class='ipsFigure__main'>
<img src='{$albumNode->coverPhoto('masked')}' alt="{$albumItem->name}" loading="lazy">
</a>
</figure>
{{endif}}
{{$images = \IPS\Gallery\Image::getItemsWithPermission( array( array( 'image_album_id=?', $albumNode->id ) ), ( $albumNode->sort_options == 'title' ) ? 'image_caption ASC' : \IPS\gallery\Image::$databasePrefix . \IPS\gallery\Image::$databaseColumnMap[ $albumNode->sort_options ] . ' DESC', 4 );}}
{{if \count( $images )}}
<ul class='cGalleryEmbed_albumStrip i-background_2'>
{{foreach $images as $albumImage}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumImage->url()}' class='ipsFigure__main'>
{{if $albumImage->masked_file_name}}
<img src='{file="$albumImage->masked_file_name" extension="gallery_Images"}' alt='' loading="lazy">
{{elseif $albumImage->media}}
<video preload="metadata" loading="lazy">
<source src="{file="$albumImage->original_file_name" extension="gallery_Images"}" type='{$albumImage->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$albumImage, FALSE"}
</figure>
</li>
{{endforeach}}
{{if $albumNode->count_imgs > 4}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumNode->url()}' class='ipsFigure__main'><span>+{expression="$albumNode->count_imgs - 4"}</span></a>
</figure>
</li>
{{endif}}
</ul>
{{endif}}
{{if $desc = $albumItem->truncated(TRUE)}}
<div class='ipsRichEmbed__content'>
<div class='ipsRichText ipsTruncate_3'>
{$desc|raw}
</div>
</div>
{{endif}}
{template="embedItemStats" group="embed" app="core" params="$albumItem, $albumNode->use_comments"}
</div>
</div>]]></template>
<template template_group="global" template_name="embedImage" template_data="$item, $url, $image=NULL" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-image'>
{template="embedHeader" group="embed" app="core" params="$item, $item->mapped('title'), $item->mapped('date'), $url"}
<div {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<figure class='ipsFigure ipsFigure--contain' {{if !$item->media }}style="--_backdrop:url('{file="$item->masked_file_name" extension="gallery_Images"}')"{{endif}}>
{{if $item->media }}
<div class='ipsFigure__main'>
<video data-controller="core.global.core.embeddedvideo" id="elGalleryVideo" data-role="video" controls preload="metadata" {{if $item->masked_file_name }} poster="{file="$item->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$item->original_file_name" extension="gallery_Images"}" type='{$item->file_type}' />
<embed wmode="opaque" autoplay="true" showcontrols="true" showstatusbar="true" showtracker="true" src="{file="$item->original_file_name" extension="gallery_Images"}" width="480" height="360" type='{$item->file_type}' />
</video>
</div>
{{else}}
<a href='{$item->url()}' title='{lang="view_this_image" sprintf="$item->caption"}' class='ipsFigure__main'>
<img src='{file="$item->masked_file_name" extension="gallery_Images"}' alt="{$item->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$item, FALSE"}
</figure>
</div>
<div class='ipsRichEmbed__content'>
{{if $desc = $item->truncated(TRUE)}}
<div class='ipsRichEmbed__snippet'>
{$desc|raw}
</div>
{{endif}}
{{if $item->copyright}}
<p class='i-color_soft i-margin-top_2'>
&copy; {$item->copyright}
</p>
{{endif}}
{template="embedItemStats" group="embed" app="core" params="$item"}
</div>
{{if $item->directContainer() instanceof \IPS\gallery\Album}}
<div class='ipsRichEmbed_moreInfo'>
<h3 class='ipsMinorTitle ipsTruncate_1'>{lang="from_the_album"} "<a href='{$item->directContainer()->url()}'>{$item->directContainer()->_title}</a>"</h3>
{{$images = \IPS\Gallery\Image::getItemsWithPermission( array( array( 'image_album_id=?', $item->album_id ) ), ( $item->directContainer()->sort_options == 'title' ) ? 'image_caption ASC' : $item::$databasePrefix . $item::$databaseColumnMap[ $item->directContainer()->sort_options ] . ' DESC', 9 );}}
{{if \count( $images )}}
<ul class='cGalleryEmbed_albumStrip cGalleryEmbed_albumStrip_mini'>
{{foreach $images as $albumImage}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$albumImage->url()}' class='ipsFigure__main'>
{{if $albumImage->masked_file_name}}
<img src='{file="$albumImage->masked_file_name" extension="gallery_Images"}' loading="lazy" alt=''>
{{elseif $albumImage->media}}
<video preload="metadata" loading="lazy">
<source src="{file="$albumImage->original_file_name" extension="gallery_Images"}" type='{$albumImage->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$albumImage, FALSE"}
</figure>
</li>
{{endforeach}}
{{if $item->directContainer()->count_imgs > 9}}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$item->directContainer()->url()}' class='ipsFigure__main'><span>+{expression="$item->directContainer()->count_imgs - 9"}</span></a>
</figure>
</li>
{{endif}}
</ul>
{{endif}}
</div>
{{endif}}
</div>]]></template>
<template template_group="global" template_name="embedImageComment" template_data="$comment, $item, $url" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-image-comment' {{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{template="embedHeader" group="embed" app="core" params="$comment, $item->mapped('title'), $comment->mapped('date'), $url"}
<div class='i-padding_3'>
<div class='i-margin-bottom_3'>
<div>
<figure class='ipsFigure'>
{{if $item->media }}
<a href='{$item->url()}' title='{lang="view_this_video" sprintf="$item->caption"}' class='ipsFigure__main'>
<video data-role="video" preload="metadata" loading="lazy" {{if $item->masked_file_name }} poster="{file="$item->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$item->original_file_name" extension="gallery_Images"}" type='{$item->file_type}' />
</video>
<i class="ipsFigure__play"></i>
</a>
{{else}}
<a href='{$item->url()}' title='{lang="view_this_image" sprintf="$item->caption"}' class='ipsFigure__main'>
<img src='{file="$item->small_file_name" extension="gallery_Images"}' alt="{$item->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$item"}
</figure>
<div class='i-padding-top_3'>
{template="embedOriginalItem" group="embed" app="core" params="$item"}
</div>
</div>
</div>
<div class='ipsRichEmbed__snippet'>
{$comment->truncated(TRUE)|raw}
</div>
{{if settings.reputation_enabled and \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and \count( $comment->reactions() )}}
<ul class='ipsList ipsList--inline i-margin-top_2'>
<li>
{template="reactionOverview" app="core" group="global" params="$comment, TRUE, 'small'"}
</li>
</ul>
{{endif}}
</div>
</div>]]></template>
<template template_group="global" template_name="embedImageReview" template_data="$comment, $item, $url" template_location="front" template_app="gallery"><![CDATA[
<div class='ipsRichEmbed ipsRichEmbed--gallery-image-review' {{if settings.gallery_nsfw}} data-controller="gallery.front.global.nsfw"{{endif}}>
{template="embedHeader" group="embed" app="core" params="$comment, $item->mapped('title'), $comment->mapped('date'), $url"}
<div class='i-padding_3'>
<div class='i-margin-bottom_3'>
<div>
<figure class='ipsFigure'>
{{if $item->media }}
<a href='{$item->url()}' title='{lang="view_this_video" sprintf="$item->caption"}' class='ipsFigure__main'>
<video data-role="video" preload="metadata" loading="lazy" {{if $item->masked_file_name }} poster="{file="$item->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$item->original_file_name" extension="gallery_Images"}" type='{$item->file_type}' />
</video>
<i class="ipsFigure__play"></i>
</a>
{{else}}
<a href='{$item->url()}' title='{lang="view_this_image" sprintf="$item->caption"}' class='ipsFigure__main'>
<img src='{file="$item->small_file_name" extension="gallery_Images"}' alt="{$item->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$item"}
</figure>
<div class='i-padding-top_3'>
{template="embedOriginalItem" group="embed" app="core" params="$item"}
</div>
</div>
</div>
{template="rating" app="core" params="'veryLarge', $comment->mapped('rating')" group="global"}
{{if $comment->mapped('votes_total')}}
<p>{$comment->helpfulLine()|raw}</p>
{{endif}}
<hr class='ipsHr'>
<div class='ipsRichEmbed__snippet'>
{$comment->truncated(TRUE)|raw}
</div>
{{if settings.reputation_enabled and \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Reactable' ) and \count( $comment->reactions() )}}
<ul class='ipsList ipsList--inline i-margin-top_2'>
<li>
{template="reactionOverview" app="core" group="global" params="$comment, TRUE, 'small'"}
</li>
</ul>
{{endif}}
</div>
</div>]]></template>
<template template_group="global" template_name="featuredComment" template_data="$comment, $id, $commentLang='__defart_comment'" template_location="front" template_app="gallery"><![CDATA[{{if isset( $comment['comment'] )}}
{{$idField = $comment['comment']::$databaseColumnId;}}
<div class='i-padding_3 ipsEntry ipsEntry--recommended' data-commentID='{$id}'>
{{if \IPS\IPS::classUsesTrait( $comment['comment'], 'IPS\Content\Reactable' ) and settings.reputation_enabled}}
<div class='i-flex i-justify-content_end'>{template="reactionOverview" group="global" app="core" params="$comment['comment']"}</div>
{{endif}}
<div class='ipsEntry__header ipsPhotoPanel ipsPhotoPanel--mini i-margin-top_3'>
{template="userPhoto" app="core" group="global" params="$comment['comment']->author(), 'mini', $comment['comment']->warningRef()"}
<div>
<h3 class='ipsPhotoPanel__primary'>
<strong>{template="userLink" app="core" group="global" params="$comment['comment']->author(), $comment['comment']->warningRef()"}</strong>
{template="reputationBadge" group="global" app="core" params="$comment['comment']->author()"}
</h3>
<p class='ipsPhotoPanel__secondary'>
<a href='{$comment['comment']->url()}' class='i-color_inherit'>{$comment['comment']->dateLine()|raw}</a>
{{if $comment['comment']->editLine()}}
({lang="edited_lc"})
{{endif}}
</p>
</div>
</div>
<div class='ipsRichText ipsTruncate_2'>{$comment['comment']->truncated( TRUE )|raw}</div>
{{if $comment['note']}}
<div class='ipsEntry__recommendedNote'>
<p class='ipsRichText'>{$comment['note']}</p>
{{if isset( $comment['featured_by'] )}}
<p class='i-color_soft i-margin-top_2'>{lang="recommended_by" htmlsprintf="$comment['featured_by']->link()"}</p>
{{endif}}
</div>
{{elseif isset( $comment['featured_by'] )}}
{lang="recommended_by" htmlsprintf="$comment['featured_by']->link()"}
{{endif}}
<hr class='ipsHr'>
<div>
<a href='{$comment['comment']->url()}' data-action='goToComment' class='ipsButton ipsButton--text ipsButton--small ipsButton--wide'>{lang="go_to_this_comment" sprintf="\IPS\Member::loggedIn()->language()->get( $commentLang )"} <i class='fa-solid fa-angle-right'></i></a>
</div>
</div>
{{endif}}]]></template>
<template template_group="global" template_name="featuredComments" template_data="$comments, $url, $titleLang='recommended_replies', $commentLang='__defart_comment'" template_location="front" template_app="gallery"><![CDATA[
<section data-controller='core.front.core.recommendedComments' data-url='{$url}' class='ipsRecommendedComments {{if !\count( $comments )}}ipsHide{{endif}}'>
<div data-role="recommendedComments">
<header class='ipsBox__header'>
<h2>{lang="$titleLang"}</h2>
{template="carouselNavigation" group="global" app="core" params="'gallery-featured-comments'"}
</header>
<div class="ipsCarousel" id="gallery-featured-comments" tabindex="0">
{{if \count( $comments )}}
{{foreach $comments AS $id => $comment}}
{template="featuredComment" group="global" app="gallery" params="$comment, $id, $commentLang"}
{{endforeach}}
{{endif}}
</div>
</div>
</section>]]></template>
<template template_group="global" template_name="link" template_data="$image" template_location="global" template_app="gallery"><![CDATA[<div class=''><a href="{$image->url()}" class="i-color_inherit" target="_blank" rel='noopener'>{$image->caption}</a></div>]]></template>
<template template_group="global" template_name="manageFollowNodeRow" template_data="$table, $headers, $rows" template_location="front" template_app="gallery"><![CDATA[{{foreach $rows as $row}}
{{$contentItemClass = $row::$contentItemClass;}}
<li class="ipsData__item {{if method_exists( $row, 'tableClass' ) && $row->tableClass()}}ipsData__item--{$row->tableClass()}{{endif}}" data-controller='core.front.system.manageFollowed' data-followID='{$row->_followData['follow_area']}-{$row->_followData['follow_rel_id']}' {{if $contentItemClass::containerUnread( $row )}}data-ips-unread{{else}}data-ips-read{{endif}}>
<div class="ipsData__image" aria-hidden="true">
{{if $coverImage = $row->coverPhoto('small') }}
<img src='{$coverImage}' alt="{$row->_title}" loading="lazy">
{{else}}
<i></i>
{{endif}}
</div>
<div class='ipsData__content'>
<div class='ipsData__main'>
<div class='ipsData__title'>
{{if $row->_locked}}
<i class="fa-solid fa-lock"></i>
{{endif}}
<h4><a href='{$row->url()}'>{$row->_title}</a></h4>
</div>
<div class='ipsData__desc ipsTruncate_2'>
{$row->_description}
</div>
<ul class='ipsList ipsList--inline i-color_soft'>
{{if $row->_items}}
<li>{lang="node_content_items" pluralize="$row->_items"}</li>
{{endif}}
{{if $row->_commentsForDisplay}}
<li>{lang="node_content_comments" pluralize="$row->_commentsForDisplay"}</li>
{{endif}}
{{if $row->_reviews}}
<li>{lang="node_content_reviews" pluralize="$row->_reviews"}</li>
{{endif}}
</ul>
{{if \count( $row->_latestImages )}}
<ul class='ipsGrid ipsGrid--album-thumbs i-basis_40 cGalleryManagedAlbumThumbs'>
{{foreach \array_slice( iterator_to_array( $row->_latestImages ), 0, 10, true ) as $image }}
<li>
<a href='{$image->url()}' class='ipsThumb'>
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
</a>
</li>
{{endforeach}}
</ul>
{{endif}}
<ul class="ipsList ipsList--inline i-row-gap_0 i-margin-top_1 i-font-weight_500">
<li title='{lang="follow_when"}' data-role='followDate' hidden><i class='fa-regular fa-clock'></i> {datetime="$row->_followData['follow_added']"}</li>
<li title='{lang="follow_how"}' data-role='followFrequency'>
{{if $row->_followData['follow_notify_freq'] == 'none'}}
<i class='fa-regular fa-bell-slash'></i>
{{else}}
<i class='fa-regular fa-bell'></i>
{{endif}} {lang="follow_freq_{$row->_followData['follow_notify_freq']}"}
</li>
<li data-role='followAnonymous' {{if !$row->_followData['follow_is_anon']}}hidden{{endif}}><i class="fa-regular fa-eye-slash"></i> {lang="follow_is_anon"}</li>
</ul>
</div>
<div class='cFollowedContent_manage'>
{template="manageFollow" group="system" app="core" params="$row->_followData['follow_app'], $row->_followData['follow_area'], $row->_followData['follow_rel_id']"}
</div>
</div>
{{if $table->canModerate()}}
<div class='ipsData__mod'>
<input type='checkbox' data-role='moderation' name="moderate[{$row->_id}]" data-actions="{expression="implode( ' ', $table->multimodActions( $row ) )"}" data-state='' class="ipsInput ipsInput--toggle">
</div>
{{endif}}
</li>
{{endforeach}}]]></template>
<template template_group="global" template_name="manageFollowRow" template_data="$table, $headers, $rows, $includeFirstCommentInCommentCount=TRUE" template_location="front" template_app="gallery"><![CDATA[{{if \count( $rows )}}
{{foreach $rows as $row}}
{{$idField = $row::$databaseColumnId;}}
<li class="ipsData__item {{if $row->unread()}}ipsData__item--unread{{endif}} {{if method_exists( $row, 'tableClass' ) && $row->tableClass()}}ipsData__item--{$row->tableClass()}{{endif}} {{if $row->hidden()}}ipsModerated{{endif}}" data-controller='core.front.system.manageFollowed' data-followID='{$row->_followData['follow_area']}-{$row->_followData['follow_rel_id']}' {{if $row->unread()}}data-ips-unread{{else}}data-ips-read{{endif}}>
<div class='ipsData__image'>
{{$image = \IPS\File::get( 'gallery_Images', $row->small_file_name )->url;}}
<img src="{$image}" alt='' loading='lazy'>
</div>
<div class='ipsData__content'>
<div class='ipsData__main'>
<div class='ipsData__title'>
<div class='ipsBadges'>
{{if $row->mapped('locked')}}
<span><i class="fa-solid fa-lock"></i></span>
{{endif}}
{{foreach $row->badges() as $badge}}{$badge|raw}{{endforeach}}
{{if $row->prefix()}}
{template="prefix" group="global" app="core" params="$row->prefix( TRUE ), $row->prefix()"}
{{endif}}
</div>
<h4>
<a href='{$row->url()}'>
{{if $row->mapped('title')}}{$row->mapped('title')}{{else}}<em class="i-color_soft">{lang="content_deleted"}</em>{{endif}}
</a>
</h4>
</div>
{{if method_exists( $row, 'tableDescription' )}}
<div class='ipsData__desc ipsTruncate_2'>
{$row->tableDescription()|raw}
</div>
{{else}}
<div class="ipsData__meta">
{lang="byline_name_date" htmlsprintf="$row->author()->link( $row->warningRef() ), \IPS\DateTime::ts( $row->__get( $row::$databaseColumnMap['date'] ) )->html(TRUE)"}
{lang="in"} <a href="{$row->container()->url()}">{$row->container()->_title}</a>
</div>
{{endif}}
<ul class="ipsList ipsList--inline i-row-gap_0 i-margin-top_1 i-font-weight_500">
<li title='{lang="follow_when"}' data-role='followDate' hidden><i class='fa-regular fa-clock'></i> {datetime="$row->_followData['follow_added']"}</li>
<li title='{lang="follow_how"}' data-role='followFrequency'>
{{if $row->_followData['follow_notify_freq'] == 'none'}}
<i class='fa-regular fa-bell-slash'></i>
{{else}}
<i class='fa-regular fa-bell'></i>
{{endif}} {lang="follow_freq_{$row->_followData['follow_notify_freq']}"}
</li>
<li data-role='followAnonymous' {{if !$row->_followData['follow_is_anon']}}hidden{{endif}}><i class="fa-regular fa-eye-slash"></i> {lang="follow_is_anon"}</li>
</ul>
</div>
<div class='cFollowedContent_manage'>
{template="manageFollow" group="system" app="core" params="$row->_followData['follow_app'], $row->_followData['follow_area'], $row->_followData['follow_rel_id']"}
</div>
</div>
{{if $table->canModerate()}}
<div class='ipsData__mod'>
<input type='checkbox' data-role='moderation' name="moderate[{$row->$idField}]" data-actions="{expression="implode( ' ', $table->multimodActions( $row ) )"}" data-state='{{if $row->tableStates()}}{$row->tableStates()}{{endif}}' class="ipsInput ipsInput--toggle">
</div>
{{endif}}
</li>
{{endforeach}}
{{endif}}
]]></template>
<template template_group="global" template_name="nodeMoveDeleteContent" template_data="$url, $itemLang, $number, $destination, $albumNumber, $albumDestination" template_location="admin" template_app="gallery"><![CDATA[<div class="i-padding_3 i-background_1">
<p class="i-margin-bottom_1">
{{if $destination}}
{lang="node_mass_content_move_blurb" sprintf="$number, $itemLang, $destination->_title"}
{{else}}
{lang="node_mass_content_delete_blurb" sprintf="$number, $itemLang"}
{{endif}}
</p>
<p class="i-margin-bottom_1">
{{if $albumDestination}}
{lang="galnode_mass_content_move_blurb" sprintf="$albumNumber, $albumDestination->_title"}
{{else}}
{lang="galnode_mass_content_delete_blurb" sprintf="$albumNumber"}
{{endif}}
</p>
<p class="i-margin-bottom_1">{lang="node_mass_content_blurb_2"}</p>
</div>
<div class="ipsSubmitRow">
<a class="ipsButton ipsButton--primary" {{if $number OR $albumNumber}}href="{$url->setQueryString( 'confirm', 1 )}"{{else}}disabled{{endif}}>{lang="node_mass_content_confirm"}</a>
</div>]]></template>
<template template_group="global" template_name="nsfwOverlay" template_data="$image, $showButton=TRUE" template_location="front" template_app="gallery"><![CDATA[{{if settings.gallery_nsfw and !isset( cookie.nsfwImageOptIn ) and $image and $image->nsfw}}
<div class='ipsNsfwOverlay {{if !$showButton}}ipsNsfwOverlay--no-content{{endif}}'>
{{if $showButton}}
<div>{lang="gallery_image_is_nsfw"}</div>
<button type='button'>{lang="gallery_nsfw_view_anyway"}</button>
{{endif}}
</div>
{{endif}}]]></template>
<template template_group="global" template_name="profileAlbumTable" template_data="$table, $headers, $rows, $quickSearch" template_location="front" template_app="gallery"><![CDATA[
<div data-baseurl='{$table->baseUrl}' data-resort='{$table->resortKey}' data-pageParam='albumPage' data-controller='core.global.core.table{{if $table->canModerate()}},core.front.core.moderation{{endif}}'>
<div data-role="tablePagination" class='i-margin-bottom_3 {{if $table->pages <= 1}}ipsHide{{endif}}'>
{template="pagination" group="global" app="core" location="global" params="$table->baseUrl, $table->pages, $table->page, $table->limit, TRUE, 'albumPage'"}
</div>
<ol class='' data-role='tableRows' id='elTable_{$table->uniqueId}'>
{template="$table->rowsTemplate[1]" params="$table, $headers, $rows" object="$table->rowsTemplate[0]"}
</ol>
</div>]]></template>
<template template_group="global" template_name="review" template_data="$item, $review, $editorName, $app, $type" template_location="front" template_app="gallery"><![CDATA[<div data-ips-hook="galleryReviewWrap" id='review-{$review->id}_wrap' data-controller='core.front.core.comment' data-feedid="{$review->feedId}" data-commentApp='{$app}' data-commentType='{$type}-review' data-commentID="{$review->id}" data-quoteData='{expression="json_encode( array('userid' => $review->author()->member_id, 'username' => $review->author()->name, 'timestamp' => $review->mapped('date'), 'contentapp' => $app, 'contenttype' => $type, 'contentid' => $item->id, 'contentcommentid' => $review->id) )"}' class='ipsEntry__content js-ipsEntry__content'
{{if \IPS\IPS::classUsesTrait( $review, 'IPS\Content\IntersectionViewTracking' ) AND $hash=$review->getViewTrackingHash()}}
data-view-hash="{$hash|raw}"
data-view-tracking-data="{expression="base64_encode(json_encode( $review->getViewTrackingData() ))" raw="true"}"
{{endif}}
>
<header class='ipsEntry__header'>
<div class='ipsEntry__header-align'>
<div class='ipsPhotoPanel'>
<div class='ipsAvatarStack' data-ips-hook="galleryReviewUserPhoto">
{template="userPhoto" app="core" group="global" params="$review->author(), 'fluid', $review->warningRef()"}
{{if $review->author()->canHaveAchievements() and \IPS\core\Achievements\Rank::show() and $rank = $review->author()->rank()}}
{$rank->html( 'ipsAvatarStack__rank' )|raw}
{{endif}}
</div>
<div class='ipsPhotoPanel__text'>
<div data-ips-hook="galleryReviewUsername" class='ipsEntry__username'>
<h3>{template="userLink" app="core" group="global" params="$review->author(), $review->warningRef(), NULL, $review->isAnonymous()"}</h3>
{{if !$review->isAnonymous()}}
<span class='ipsEntry__group'>
{{if $review->author()->modShowBadge()}}
<a href='{url="app=core&module=staffdirectory&controller=directory" seoTemplate="staffdirectory"}' class="ipsEntry__moderatorBadge" data-ipsTooltip title='{lang="member_is_moderator" sprintf="$review->author()->name"}'>
{expression="\IPS\Member\Group::load( $review->author()->member_group_id )->formattedName" raw="true"}
</a>
{{else}}
{expression="\IPS\Member\Group::load( $review->author()->member_group_id )->formattedName" raw="true"}
{{endif}}
</span>
{{endif}}
</div>
<p class='ipsPhotoPanel__secondary'>
{{if $review->mapped('date')}}
{datetime="$review->mapped('date')"}
{{else}}
{lang="unknown_date"}
{{endif}}
{{if $review->editLine()}}
({lang="edited_lc"})
{{endif}}
</p>
</div>
</div>
{{if \count( $item->reviewMultimodActions() )}}
<input type="checkbox" name="multimod[{$review->id}]" value="1" data-role="moderation" data-actions="{{if $review->hidden() === -1 AND $review->canUnhide()}}unhide{{elseif $review->hidden() === 1 AND $review->canUnhide()}}approve{{elseif $review->canHide()}}hide{{endif}} {{if $review->canDelete()}}delete{{endif}}" data-state='{{if $review->tableStates()}}{$review->tableStates()}{{endif}}' class="ipsInput ipsInput--toggle">
{{endif}}
{$review->menu()|raw}
{{if $review->author()->member_id}}
<!-- Expand mini profile -->
<button class='ipsEntry__topButton ipsEntry__topButton--profile' type='button' aria-controls='mini-profile-review-{$review->id}' aria-expanded='false' data-ipscontrols data-ipscontrols-src="{$review->authorMiniProfileUrl}" aria-label="Toggle mini profile"><i class="fa-solid fa-chevron-down" aria-hidden="true"></i></button>
{{endif}}
</div>
{{if $review->author()->member_id}}
{template="miniProfileWrap" app="core" group="global" params="$review->author(), $review->id, 'review', remoteLoading: true"}
{{endif}}
</header>
<div class='ipsEntry__post'>
{{if $review->hidden() AND $review->hidden() != -2}}
<div class='ipsEntry__hiddenMessage'>{$review->hiddenBlurb()}</div>
{{elseif $review->hidden() == -2}}
<div class='ipsEntry__hiddenMessage'>{$review->deletedBlurb()}</div>
{{endif}}
<div class='ipsRating ipsRating_large i-margin-bottom_3'>
<ul>
{{foreach range( 1, \intval( \IPS\Settings::i()->reviews_rating_out_of ) ) as $i}}
<li class='{{if $review->mapped('rating') >= $i}}ipsRating_on{{else}}ipsRating_off{{endif}}'>
<i class='fa-solid fa-star'></i>
</li>
{{endforeach}}
</ul>
</div>
&nbsp;&nbsp; {{if $review->mapped('votes_total')}}<strong>{$review->helpfulLine()|raw}</strong>{{endif}}
<div data-ips-hook="galleryReview" id="review-{$review->id}" class='ipsRichText ipsRichText--user' data-role='commentContent' data-controller='core.front.core.lightboxedImages'>
{$review->content()|raw}
{{if $review->editLine()}}
{$review->editLine()|raw}
{{endif}}
</div>
{{if $review->hasAuthorResponse()}}
<div class='ipsReviewResponse i-padding_3 i-margin-bottom_3 i-background_2'>
<div class='i-flex i-align-items_center i-justify-content_space-between i-margin-bottom_2'>
<h4 class='ipsTitle ipsTitle--h5'>{lang="review_response_title"}</h4>
{{if $review->canEditResponse() OR $review->canDeleteResponse()}}
<button type="button" id="elControlsReviews_{$review->id}_response" popovertarget="elControlsReviews_{$review->id}_response_menu" class='ipsEntry__topButton ipsEntry__topButton--ellipsis'>
<i class='fa-solid fa-ellipsis'></i>
</button>
{{endif}}
</div>
<div data-role="reviewResponse" class="ipsRichText" data-controller='core.front.core.lightboxedImages'>{$review->mapped('author_response')|raw}</div>
{{if $review->canEditResponse() OR $review->canDeleteResponse()}}
<i-dropdown id="elControlsReviews_{$review->id}_response_menu" popover>
<div class="iDropdown">
<ul class="iDropdown__items">
{{if $review->canEditResponse()}}
<li><a href='{$review->url('editResponse')}' data-ipsDialog data-ipsDialog-title='{lang="review_author_respond"}'>{lang="edit"}</a></li>
{{endif}}
{{if $review->canDeleteResponse()}}
<li><a href='{$review->url('deleteResponse')->csrf()}' data-confirm>{lang="delete"}</a></li>
{{endif}}
</ul>
</div>
</i-dropdown>
{{endif}}
</div>
{{endif}}
{{if $review->hidden() !== 1}}
{{if member.member_id and ( !$review->mapped('votes_data') or !array_key_exists( member.member_id, json_decode( $review->mapped('votes_data'), TRUE ) ) ) and $review->author()->member_id != \IPS\Member::loggedIn()->member_id}}
<div class='i-flex i-align-items_center i-flex-wrap_wrap i-gap_2 i-margin-top_3'>
<div class='i-font-weight_500 i-color_hard i-font-size_-1'>{lang="did_you_find_this_helpful"}</div>
<div class='ipsButtons i-font-size_-2'>
<a href='{$review->url('rate')->setQueryString( 'helpful', TRUE )->csrf()}' class='ipsButton ipsButton--inherit i-color_positive' data-action="rateReview"><i class='fa-solid fa-check'></i><span>{lang="yes"}</span></a>
<a href='{$review->url('rate')->setQueryString( 'helpful', FALSE )->csrf()}' class='ipsButton ipsButton--inherit i-color_negative' data-action="rateReview"><i class='fa-solid fa-xmark'></i><span>{lang="no"}</span></a>
</div>
</div>
{{endif}}
{{endif}}
</div>
{{if ( member.member_id and ( !$review->mapped('votes_data') or !array_key_exists( member.member_id, json_decode( $review->mapped('votes_data'), TRUE ) ) ) ) || $review->canEdit() || $review->canDelete() || $review->canHide() || $review->canUnhide() || ( $review->hidden() !== 1 && \IPS\IPS::classUsesTrait( $review, 'IPS\Content\Reactable' ) and settings.reputation_enabled and $review->hasReactionBar() )}}
<div data-ips-hook="galleryReviewFooter" class='ipsEntry__footer'>
{{if $review->canEdit() || $review->canDelete() || $review->canHide() || $review->canUnhide() || ( $review->hidden() !== 1 && $review->canRespond() ) }}
<menu class='ipsEntry__controls' data-role="commentControls" data-ips-hook="galleryReviewControls">
{{if $review->hidden() === 1 && ( $review->canUnhide() || $review->canDelete() )}}
{{if $review->canUnhide()}}
<li><a href='{$review->url('unhide')->csrf()}' data-action='approveComment'><i class='fa-solid fa-check'></i><span>{lang="approve"}</span></a></li>
{{endif}}
{{if $review->canDelete()}}
<li><a href='{$review->url('delete')->csrf()->setPage('page',\IPS\Request::i()->page)}' data-action='deleteComment' data-updateOnDelete="#commentCount"><i class='fa-solid fa-xmark'></i><span>{lang="delete"}</span></a></li>
{{endif}}
{{if $review->canEdit() || $review->canSplit()}}
<li>
<button type="button" id="elControlsReviewsSub_{$review->id}" popovertarget="elControlsReviewsSub_{$review->id}_menu"><span>{lang="options"}</span><i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elControlsReviewsSub_{$review->id}_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if $review->canEdit()}}
{{if $review->mapped('first') and $review->item()->canEdit()}}
<li><a href='{$review->item()->url()->setQueryString( 'do', 'edit' )}'>{lang="edit"}</a></li>
{{else}}
<li><a href='{$review->url('edit')}' data-action='editComment'>{lang="edit"}</a></li>
{{endif}}
{{endif}}
{{if $review->canSplit()}}
<li><a href='{$review->url('split')}' data-action='splitComment' data-ipsDialog data-ipsDialog-title="{lang="split_to_new" sprintf="\IPS\Member::loggedIn()->language()->addToStack( $item::$title )"}">{lang="split"}</a></li>
{{endif}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{elseif $review->hidden() !== 1 && $review->canRespond()}}
<li>
<a href='{$review->url('respond')}' data-role='respond' data-ipsDialog data-ipsDialog-title='{lang="review_author_respond"}'><span>{lang="review_author_respond"}</span></a>
</li>
{{endif}}
{{if \IPS\Application::appIsEnabled('cloud')}}
<li>{template="spam" app="cloud" group="spam" params="$review, FALSE"}</li>
{{endif}}
<li class='ipsHide' data-role='commentLoading'>
<span class='ipsLoading ipsLoading--tiny'></span>
</li>
</menu>
{{endif}}
{{if $review->hidden() !== 1 && \IPS\IPS::classUsesTrait( $review, 'IPS\Content\Reactable' ) and settings.reputation_enabled}}
{template="reputation" group="global" app="core" params="$review"}
{{endif}}
</div>
{{endif}}
{{if ! \IPS\Output::i()->reduceLinks()}}
{template="sharemenu" group="global" app="core" params="$review"}
{{endif}}
</div>]]></template>
<template template_group="global" template_name="reviewContainer" template_data="$item, $review" template_location="front" template_app="gallery"><![CDATA[{{$idField = $review::$databaseColumnId;}}
{{if $review->isIgnored()}}
<div class='ipsEntry ipsEntry--ignored'>
<i class="fa-solid fa-user-slash"></i> {lang="ignoring_content" sprintf="$review->author()->name"}
</div>
{{else}}
<a id='review-{$review->$idField}'></a>
<a id='findReview-{$review->$idField}'></a>
<article id="elReview_{$review->$idField}" class="ipsEntry ipsEntry--simple ipsEntry--review js-ipsEntry {{if $review->hidden() OR $item->hidden() == -2}}ipsModerated{{endif}}">
{template="review" group="global" app="core" params="$item, $review, $item::$formLangPrefix . 'review', $item::$application, $item::$module"}
</article>
{{endif}}]]></template>
<template template_group="global" template_name="searchResultAlbumCommentSnippet" template_data="$indexData, $itemData, $images, $url, $reviewRating, $condensed" template_location="front" template_app="gallery"><![CDATA[{{if $condensed}}
{{if \count( $images )}}
<ul class='cGalleryAlbums_recent cGalleryAlbums_recent--small' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $images as $k => $image}}
<li data-imageId="{$image->id}">
<figure class='ipsFigure'>
<a href='{$image->url( "getPrefComment" )}' class='ipsFigure__main'>
{{if $image->small_file_name}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
{{elseif $image->media}}
<video loading="lazy" {{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
</li>
{{endforeach}}
</ul>
{{endif}}
{{else}}
<div class='ipsStreamItem__content-thumb ipsStreamItem__content-thumb--gallery'>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$url}' title='{lang="view_this_album" sprintf="$itemData['album_name']"}' class='ipsFigure__main'>
{{if \count( $images )}}
{{$firstImage = array_shift( $images );}}
<img src='{file="$firstImage->small_file_name" extension="gallery_Images"}' alt="{$firstImage->caption}" loading="lazy">
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$firstImage, FALSE"}
</figure>
</div>
<div class='ipsStreamItem__content-content ipsStreamItem__content-content--gallery'>
{{if $reviewRating !== NULL}}
{template="rating" app="core" params="'medium', $reviewRating" group="global"}
{{endif}}
<div class='ipsStream__comment'>
{{if trim( $indexData['index_content'] ) !== ''}}
<div {{if !( \IPS\Dispatcher::i()->application->directory == 'core' and \IPS\Dispatcher::i()->module and \IPS\Dispatcher::i()->module->key == 'search' )}}class='ipsRichText ipsTruncate_3'{{else}}class='ipsRichText' data-searchable data-findTerm{{endif}}>
{expression="\IPS\Content\Search\Result::preDisplay( $indexData['index_content'] )" raw="true"}
</div>
{{endif}}
</div>
<ul class='cGallerySearchAlbumThumbs cGallerySearchExpanded'>
{{foreach $images as $image }}
<li>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$image->url()}' class='ipsFigure__main'>
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
</li>
{{endforeach}}
</ul>
</div>
{{endif}}]]></template>
<template template_group="global" template_name="searchResultAlbumSnippet" template_data="$indexData, $itemData, $images, $url, $condensed" template_location="front" template_app="gallery"><![CDATA[{{if $condensed}}
{{if \count( $images )}}
<ul class='cGalleryAlbums_recent cGalleryAlbums_recent--small' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $images as $k => $image}}
<li data-imageId="{$image->id}">
<figure class='ipsFigure'>
<a href='{$image->url( "getPrefComment" )}' class='ipsFigure__main'>
{{if $image->small_file_name}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="{$image->caption}" loading="lazy">
{{elseif $image->media}}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
</li>
{{endforeach}}
</ul>
{{endif}}
{{else}}
{{if trim( $indexData['index_content'] ) !== ''}}
<div {{if !( \IPS\Dispatcher::i()->application->directory == 'core' and \IPS\Dispatcher::i()->module and \IPS\Dispatcher::i()->module->key == 'search' )}}class='ipsRichText ipsTruncate_3'{{else}}class='ipsRichText' data-searchable data-findTerm{{endif}}>
{expression="\IPS\Content\Search\Result::preDisplay( $indexData['index_content'] )" raw="true"}
</div>
{{endif}}
{{if \count($images)}}
<ul class='cGalleryAlbums_recent' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $images as $k => $image}}
<li data-imageId="{$image->id}">
<figure class='ipsFigure'>
<a href='{$image->url( "getPrefComment" )}' class='ipsFigure__main'>
{{if $image->small_file_name}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{elseif $image->media}}
<video loading="lazy"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}{{if !$image->masked_file_name }}#t=1{{endif}}" type='{$image->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
<span class="ipsInvisible">{$image->caption}</span>
</a>
{{if ( $image->directContainer()->allow_comments && $image->container()->allow_comments && count($image->comments()) > 0 )}}
<div class='ipsFigure__footer'>
<span><i class='fa-solid fa-comment'></i> {expression="\count( $image->comments() )"}</span>
</div>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</figure>
</li>
{{endforeach}}
</ul>
{{endif}}
{{endif}}]]></template>
<template template_group="global" template_name="searchResultCommentSnippet" template_data="$indexData, $itemData, $image, $url, $reviewRating, $condensed" template_location="front" template_app="gallery"><![CDATA[{{if $image}}
{{$imageObj = \IPS\gallery\Image::constructFromData( $itemData, FALSE );}}
{{endif}}
{{if $image}}
<div class='ipsStreamItem__content-thumb ipsStreamItem__content-thumb--gallery'>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$url}' title='{lang="view_this_image" sprintf="$itemData['image_caption']"}' class='ipsFigure__main'>
<img src='{file="$image" extension="gallery_Images"}' alt="{$itemData['image_caption']}" loading="lazy">
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$imageObj, FALSE"}
</figure>
</div>
{{endif}}
{{if !$condensed}}
<div class='ipsStreamItem__content-content ipsStreamItem__content-content--gallery'>
{{if $reviewRating !== NULL}}
{template="rating" app="core" params="'medium', $reviewRating" group="global"}
{{endif}}
<div class='ipsStream__comment'>
{{if trim( $indexData['index_content'] ) !== ''}}
<div {{if !( \IPS\Dispatcher::i()->application->directory == 'core' and \IPS\Dispatcher::i()->module and \IPS\Dispatcher::i()->module->key == 'search' )}}class='ipsRichText ipsTruncate_3'{{else}}class='ipsRichText' data-searchable data-findTerm{{endif}}>
{expression="\IPS\Content\Search\Result::preDisplay( $indexData['index_content'] )" raw="true"}
</div>
{{endif}}
</div>
</div>
{{endif}}]]></template>
<template template_group="global" template_name="searchResultImageSnippet" template_data="$indexData, $itemData, $albumData, $image, $url, $condensed" template_location="front" template_app="gallery"><![CDATA[{{if $image or $itemData['image_media']}}
{{$imageObj = \IPS\gallery\Image::constructFromData( $itemData, FALSE );}}
{{endif}}
{{if $condensed}}
{{if $image or $itemData['image_media']}}
<div class='ipsStreamItem__content-thumb ipsStreamItem__content-thumb--gallery'>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$url}' title='{lang="view_this_image" sprintf="$indexData['index_title']"}' class='ipsFigure__main'>
{{if $imageObj->media}}
<video loading="lazy"{{if $imageObj->masked_file_name }} poster="{file="$imageObj->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$imageObj->original_file_name" extension="gallery_Images"}{{if !$imageObj->masked_file_name }}#t=1{{endif}}" type='{$imageObj->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<img src='{file="$image" extension="gallery_Images"}' alt="{$itemData['image_caption']}" loading="lazy">
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$imageObj, FALSE"}
</figure>
</div>
{{endif}}
{{else}}
{{if $image or $itemData['image_media']}}
<div class='ipsStreamItem__content-thumb ipsStreamItem__content-thumb--gallery' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<figure class='ipsFigure ipsFigure--ratio'>
<a href='{$url}' title='{lang="view_this_image" sprintf="$indexData['index_title']"}' class='ipsFigure__main'>
{{if $imageObj->media}}
<video loading="lazy"{{if $imageObj->masked_file_name }} poster="{file="$imageObj->masked_file_name" extension="gallery_Images"}"{{else}} preload="metadata"{{endif}}>
<source src="{file="$imageObj->original_file_name" extension="gallery_Images"}{{if !$imageObj->masked_file_name }}#t=1{{endif}}" type='{$imageObj->file_type}' />
</video>
<i class="ipsFigure__play"></i>
{{else}}
<img src='{file="$image" extension="gallery_Images"}' alt="{$indexData['index_title']}" loading="lazy">
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$imageObj, FALSE"}
</figure>
</div>
{{endif}}
<div class='ipsStreamItem__content-content ipsStreamItem__content-content--gallery'>
{{if $albumData}}
<p class='i-font-weight_500'>
{lang="from_the_album"} <a href='{url="app=gallery&module=gallery&controller=browse&album={$albumData['album_id']}" seoTemplate="gallery_album" seoTitle="$albumData['album_name_seo']"}'>{$albumData['album_name']}</a>
</p>
{{endif}}
{{if trim( $indexData['index_content'] ) !== ''}}
<div {{if !( \IPS\Dispatcher::i()->application->directory == 'core' and \IPS\Dispatcher::i()->module and \IPS\Dispatcher::i()->module->key == 'search' )}}class='ipsRichText ipsTruncate_3'{{else}}class='ipsRichText' data-searchable data-findTerm{{endif}}>
{expression="\IPS\Content\Search\Result::preDisplay( $indexData['index_content'] )" raw="true"}
</div>
{{endif}}
{{if $itemData['image_copyright']}}
<p class='i-color_soft'>&copy; {$itemData['image_copyright']}</p>
{{endif}}
</div>
{{endif}}]]></template>
<template template_group="livesearch" template_name="category" template_data="$category" template_location="admin" template_app="gallery"><![CDATA[<li data-role='result'>
<a href='{url="app=gallery&module=gallery&controller=categories&do=form&id="}{$category->id}'>{$category->_title}</a>
</li>
]]></template>
<template template_group="stats" template_name="bandwidthButton" template_data="$member" template_location="admin" template_app="gallery"><![CDATA[
&nbsp;&nbsp;<a href="{url="app=core&module=members&controller=members&do=editBlock&block=IPS\\gallery\\extensions\\core\\MemberACPProfileContentTab\\Gallery&id={$member->member_id}"}" data-ipsDialog data-ipsDialog-title="{lang="bandwidth_use_gallery"}">({lang="bandwidth_use_gallery"})</a>]]></template>
<template template_group="stats" template_name="graphs" template_data="$graph" template_location="admin" template_app="gallery"><![CDATA[{$graph|raw}
<div class="i-padding_2 i-background_3">
{lang="gallery_graph_disclaimer"}
</div>]]></template>
<template template_group="stats" template_name="information" template_data="$member, $table" template_location="admin" template_app="gallery"><![CDATA[{$table|raw}
<div class="i-padding_2 i-color_soft i-font-size_-1">
{lang="gallery_stats_disclaimer"}
</div>
]]></template>
<template template_group="stats" template_name="uploadersTable" template_data="$select, $pagination, $members, $total" template_location="admin" template_app="gallery"><![CDATA[
<div class="ipsBox">
<h1 class="ipsBox__header">{lang="gallery_stats_uploader_count" pluralize="$total"}</h1>
{{if trim( $pagination )}}
{$pagination|raw}
{{endif}}
<div class="ipsBox i-margin-bottom_2">
<table class="ipsTable ipsTable_zebra">
<thead>
<tr>
<th width="60"></th>
<th>{lang="member"}</th>
<th>{lang="gallery_images"}</th>
</tr>
</thead>
<tbody>
{{foreach $select as $row}}
{{if isset( $members[ $row['image_member_id'] ] )}}
{{$member = \IPS\Member::constructFromData( $members[ $row['image_member_id'] ] );}}
{{else}}
{{$member = new \IPS\Member;}}
{{endif}}
<tr>
<td>{template="userPhoto" app="core" group="global" params="$member"}</td>
<td>{$member->name}</td>
<td><a href='{$member->url()->setQueryString( array( 'do' => 'content', 'type' => 'gallery_image' ) )}' target='_blank' rel='noopener'>{$row['images']}</a></td>
</tr>
{{endforeach}}
</tbody>
</table>
</div>
{$pagination|raw}
</div>]]></template>
<template template_group="submit" template_name="categorySelector" template_data="$form" template_location="front" template_app="gallery"><![CDATA[
{{if !\IPS\Request::i()->isAjax()}}
{template="pageHeader" group="global" app="core" params="\IPS\Member::loggedIn()->language()->addToStack('choose_category')"}
{{else}}
<div class='i-padding_3'>
{{endif}}
{$form|raw}
{{if \IPS\Request::i()->isAjax()}}
</div>
{{endif}}]]></template>
<template template_group="submit" template_name="chooseAlbum" template_data="$category, $createAlbumForm, $canCreateAlbum, $maximumAlbums, $existingAlbumForm" template_location="front" template_app="gallery"><![CDATA[
<div class='cGalleryChooseAlbum_wrap' data-controller='gallery.front.submit.chooseCategory'>
<div data-role='chooseAlbumType' class='cGalleryChooseAlbum_list'>
<ul>
{{if $category->allow_albums != 2}}
<li>
<a href='#' class='cGalleryChooseAlbum_listItem' data-type='category'>
<h2 class='ipsTitle ipsTitle--h3'>{lang="use_no_album"}</h2>
<p class='i-color_soft'>{lang="submit_directly_to" sprintf="$category->_title"}</p>
</a>
<form action="{url="app=gallery&module=gallery&controller=submit&category={$category->_id}&noAlbum=1" seoTemplate="gallery_submit"}" class='ipsHide'>
<button type="submit" class="ipsButton ipsButton--primary">{lang="use_no_album"} <i class='fa-solid fa-caret-right'></i></button>
</form>
</li>
{{endif}}
<li>
<a href='#' class='cGalleryChooseAlbum_listItem' data-type='createAlbum' {{if !$canCreateAlbum || !$createAlbumForm}}data-disabled{{endif}}>
<h2 class='ipsTitle ipsTitle--h3'>{lang="create_new_album"}</h2>
<p class='i-color_soft'>
{{if $createAlbumForm}}
{lang="submit_new_album"}
{{elseif !$canCreateAlbum}}
{lang="cannot_create_album"}
{{else}}
{lang="used_max_albums" sprintf="$maximumAlbums"}
{{endif}}
</p>
</a>
</li>
<li>
<a href='#' class='cGalleryChooseAlbum_listItem' data-type='existingAlbum' {{if !$existingAlbumForm}}data-disabled{{endif}}>
<h2 class='ipsTitle ipsTitle--h3'>{lang="choose_existing_album"}</h2>
<p class='i-color_soft'>
{{if $existingAlbumForm}}
{lang="choose_existing_album_desc"}
{{else}}
{lang="no_existing_albums"}
{{endif}}
</p>
</a>
</li>
</ul>
</div>
{{if $createAlbumForm}}
<div data-role='createAlbumForm' hidden>
{$createAlbumForm|raw}
</div>
{{endif}}
{{if $existingAlbumForm}}
<div data-role='existingAlbumForm' hidden>
{$existingAlbumForm|raw}
</div>
{{endif}}
</div>]]></template>
<template template_group="submit" template_name="chooseCategory" template_data="$id, $action, $elements, $hiddenValues, $actionButtons, $uploadField, $class='', $attributes=array(), $sidebar=NULL, $form=NULL" template_location="front" template_app="gallery"><![CDATA[<div data-controller='gallery.front.submit.chooseCategory' data-preselected-album="{expression="\IPS\Request::i()->album"}" class='cGallerySubmit_chooseCategory'>
<form accept-charset='utf-8' class="ipsForm {$class} ipsForm--choose-category" action="{$action}" method="post" {{if $uploadField}}enctype="multipart/form-data"{{endif}} {{foreach $attributes as $k => $v}}{$k}="{$v}"{{endforeach}} data-ipsForm data-role='categoryForm'>
<input type="hidden" name="{$id}_submitted" value="1">
{{foreach $hiddenValues as $k => $v}}
{{if \is_array($v)}}
{{foreach $v as $_k => $_v}}
<input type="hidden" name="{$k}[{$_k}]" value="{$_v}">
{{endforeach}}
{{else}}
<input type="hidden" name="{$k}" value="{$v}">
{{endif}}
{{endforeach}}
<div class='cGallerySubmit_albumChoice'>
{$elements['']['image_category']->html()|raw}
</div>
<div class="i-padding_3 i-border-top_3 i-text-align_center ipsJS_hide" data-role="continueCategory">
{{foreach $actionButtons as $button}}
{$button|raw}
{{endforeach}}
</div>
</form>
</div>]]></template>
<template template_group="submit" template_name="container" template_data="$container" template_location="front" template_app="gallery"><![CDATA[<div>
{{if $container['album']}}
{lang="gallery_submit_prefix_album" sprintf="$container['album']->_title"}
{{else}}
{lang="gallery_submit_prefix_cat" sprintf="$container['category']->_title"}
{{endif}}
</div>]]></template>
<template template_group="submit" template_name="createAlbum" template_data="$id, $action, $elements, $hiddenValues, $actionButtons, $uploadField, $class='', $attributes=array(), $sidebar=NULL, $form=NULL" template_location="front" template_app="gallery"><![CDATA[{{$dropdownFields = [ 'set_album_owner', 'album_type', 'album_sort_options', 'album_sort_options', 'album_allow_comments', 'album_allow_reviews', 'album_use_comments', 'album_use_reviews', 'album_type', 'album_allowed_access', 'album_submit_type', 'album_submit_access_members', 'album_submit_access_groups', 'set_album_owner', 'album_owner' ];}}
<form accept-charset='utf-8' class="ipsFormWrap ipsFormWrap--create-album" action="{$action}" method="post" {{if $uploadField}}enctype="multipart/form-data"{{endif}} {{foreach $attributes as $k => $v}}{$k}="{$v}"{{endforeach}} data-ipsForm>
<input type="hidden" name="{$id}_submitted" value="1">
{{foreach $hiddenValues as $k => $v}}
{{if \is_array($v)}}
{{foreach $v as $_k => $_v}}
<input type="hidden" name="{$k}[{$_k}]" value="{$_v}">
{{endforeach}}
{{else}}
<input type="hidden" name="{$k}" value="{$v}">
{{endif}}
{{endforeach}}
{{if $uploadField}}
<input type="hidden" name="MAX_FILE_SIZE" value="{$uploadField}">
<input type="hidden" name="plupload" value="{expression="md5( mt_rand() )"}">
{{endif}}
<ul class='cGalleryDialog_formPanel'>
{{foreach $elements as $collection}}
{{foreach $collection as $inputName => $input}}
{{if !\in_array( $inputName, $dropdownFields )}}
{{if \is_object( $input ) }}
{$input->rowHtml($form)|raw}
{{else}}
{$input|raw}
{{endif}}
{{endif}}
{{endforeach}}
{{endforeach}}
<li class='ipsFieldRow' id='elAlbumExtrasRow'>
<ul class='ipsButtons ipsButtons--fill'>
{{if isset( $elements['']['set_album_owner'] ) && \count( $elements['']['set_album_owner']->options['options'] ) > 1}}
<li>
<button type="button" id="elAlbumCreate_owner" popovertarget="elAlbumCreate_owner_menu" class="ipsButton ipsButton--inherit ipsButton--small"><i class="fa-solid fa-user"></i> {lang="album_create_owner"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elAlbumCreate_owner_menu">
<div class="iDropdown">
<ul class='ipsForm {$class} ipsForm--vertical ipsForm--album-owner'>
{{foreach array( 'set_album_owner', 'album_owner' ) as $inputName}}
{{if isset( $elements[''][ $inputName ] )}}
{$elements[''][ $inputName ]->rowHtml()|raw}
{{endif}}
{{endforeach}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{if ( isset( $elements['']['album_type'] ) && \count( $elements['']['album_type']->options['options'] ) > 1 ) OR ( isset( $elements['']['album_submit_type'] ) && \count( $elements['']['album_submit_type']->options['options'] ) > 1 )}}
<li>
<button type="button" id="elAlbumCreate_privacy" popovertarget="elAlbumCreate_privacy_menu" class="ipsButton ipsButton--inherit ipsButton--small"><i class="fa-solid fa-lock"></i> {lang="album_create_privacy"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elAlbumCreate_privacy_menu">
<div class="iDropdown">
<ul class='ipsForm {$class} ipsForm--vertical ipsForm--album-privacy'>
{{foreach array( 'album_type', 'album_allowed_access', 'album_submit_type', 'album_submit_access_members', 'album_submit_access_groups' ) as $inputName}}
{{if isset( $elements[''][ $inputName ] )}}
{{if \is_object( $elements[''][ $inputName ] ) }}
{$elements[''][ $inputName ]->rowHtml($form)|raw}
{{else}}
{$elements[''][ $inputName ]|raw}
{{endif}}
{{endif}}
{{endforeach}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{if isset( $elements['']['album_sort_options'] ) || isset( $elements['']['album_allow_comments'] ) || isset( $elements['']['album_allow_reviews'] ) || isset( $elements['']['album_use_comments'] ) || isset( $elements['']['album_use_reviews'] )}}
<li>
<button type="button" id="elAlbumCreate_features" popovertarget="elAlbumCreate_features_menu" class="ipsButton ipsButton--inherit ipsButton--small"><i class="fa-solid fa-comments"></i> {lang="album_create_features"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elAlbumCreate_features_menu">
<div class="iDropdown">
<ul class='ipsForm {$class} ipsForm--vertical ipsForm--album-features'>
{{foreach array( 'album_sort_options', 'album_allow_comments', 'album_allow_reviews', 'album_use_comments', 'album_use_reviews' ) as $inputName}}
{{if isset( $elements[''][ $inputName ] )}}
{{if \is_object( $elements[''][ $inputName ] ) }}
{$elements[''][ $inputName ]->rowHtml($form)|raw}
{{else}}
{$elements[''][ $inputName ]|raw}
{{endif}}
{{endif}}
{{endforeach}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
</ul>
</li>
</ul>
<div class='ipsSubmitRow cGalleryDialog_submitBar'>
<button type='submit' class='ipsButton ipsButton--primary'>{lang="create_album"}</button>
</div>
</form>]]></template>
<template template_group="submit" template_name="existingAlbumForm" template_data="$category, $id, $action, $elements, $hiddenValues, $actionButtons, $uploadField, $class='', $attributes=array(), $sidebar=NULL, $form=NULL" template_location="front" template_app="gallery"><![CDATA[
{{$existingAlbums = \IPS\gallery\Album::loadForSubmit( $category );}}
<form accept-charset='utf-8' class="{$class}" action="{$action}" method="post" {{if $uploadField}}enctype="multipart/form-data"{{endif}} {{foreach $attributes as $k => $v}}{$k}="{$v}"{{endforeach}} data-ipsForm data-ipsFormSubmit data-controller='gallery.front.submit.existingAlbums'>
<input type="hidden" name="{$id}_submitted" value="1">
{{foreach $hiddenValues as $k => $v}}
{{if \is_array($v)}}
{{foreach $v as $_k => $_v}}
<input type="hidden" name="{$k}[{$_k}]" value="{$_v}">
{{endforeach}}
{{else}}
<input type="hidden" name="{$k}" value="{$v}">
{{endif}}
{{endforeach}}
<ul id='elGallerySubmit_albumChooser' class='ipsScrollbar'>
{{foreach $elements['']['existing_album']->options['options'] as $optionID => $option}}
{{$album = $existingAlbums[ $optionID ];}}
<li>
<input id="existing_album_{$optionID}" type='radio' name='existing_album' value='{$optionID}' {{if $optionID == $elements['']['existing_album']->value}}checked{{endif}}>
<div class='i-flex i-gap_2'>
<span class="ipsThumb i-flex_00 i-basis_40 {{if \IPS\Member::loggedIn()->group['g_img_album_limit'] && $album->count_imgs >= \IPS\Member::loggedIn()->group['g_img_album_limit']}}i-opacity_4{{endif}}">
{{if $album->coverPhoto('small')}}
<img src='{$album->coverPhoto( 'small' )}' alt="{$album->_title}" loading="lazy">
{{endif}}
</span>
<div class='i-flex_11 cGallerySubmit_albumInfo'>
<p><strong class="i-font-size_2">{$album->_title}</strong></p>
<ul class='ipsList ipsList--inline i-color_soft'>
<li>{lang="num_images" pluralize="$album->count_imgs"}</li>
{{if \IPS\Member::loggedIn()->group['g_img_album_limit']}}
<li>
{{if $album->count_imgs >= \IPS\Member::loggedIn()->group['g_img_album_limit']}}
{lang="album_full_desc"}
{{else}}
{lang="x_more_images_album" pluralize="( \IPS\Member::loggedIn()->group['g_img_album_limit'] - $album->count_imgs )"}
{{endif}}
</li>
{{endif}}
</ul>
</div>
<label for="existing_album_{$optionID}"><span class="ipsInvisible">{$album->_title}</span></label>
</div>
</li>
{{endforeach}}
</ul>
<div class='ipsSubmitRow cGalleryDialog_submitBar'>
<button type='submit' class='ipsButton ipsButton--primary'>{lang="choose_selected_album"}</button>
</div>
</form>
]]></template>
<template template_group="submit" template_name="postingInformation" template_data="$guestPostBeforeRegister, $modQueued, $continueUrl, $guestEmailError=NULL" template_location="front" template_app="gallery"><![CDATA[<div class='i-text-align_center i-padding_3'>
<form accept-charset='utf-8' class="ipsForm" action="{$continueUrl}" method="post" data-ipsForm>
{{if !member.member_id}}
<h2 class='ipsTitle ipsTitle--h3'>{lang="gallery_guest_post_normal_header"}</h2>
<p class='i-font-size_2 i-margin-top_3'>
{{if $guestPostBeforeRegister}}
{lang="gallery_guest_post_pbr_blurb"}<br>
{{endif}}
{lang="guest_post_sign_in"}
</p>
{{if $modQueued}}
<p class='i-color_warning i-margin-top_3'>
{lang="gallery_guest_post_mod_approval"}
</p>
{{endif}}
{{if $guestPostBeforeRegister}}
<input type="hidden" name="guest_email_submit" value="1">
<input type="email" name="guest_email" value="" placeholder="{lang="guest_email"}" class="ipsInput ipsInput--text i-margin-top_3" required autocomplete="email">
<br><span class="i-color_soft">{lang="guest_email_desc"}</span>
{{if $guestEmailError}}
<p class="i-color_warning">{lang="$guestEmailError"}</p>
{{endif}}
{{else}}
<input type="hidden" name="_pi" value="1">
{{endif}}
<ul class='ipsButtons ipsButtons--main'>
<li>
<button type="submit" class="ipsButton ipsButton--primary">{lang="continue"}</button>
</li>
</ul>
{{else}}
<input type="hidden" name="_pi" value="1">
<h2 class='i-color_warning'>{lang="mod_queue_message"}</h2>
{{$warnings = member.warnings( 1, NULL, 'mq' );}}
{{if \count( $warnings ) and member.mod_posts > time()}}
{{if \count( $warnings )}}
<p class="i-font-size_2 i-margin-top_3">
{lang="gallery_this_will_be_moderated"}
</p>
{{endif}}
<p class="i-font-size_2 i-margin-top_3">
{lang="restriction_ends" sprintf="\IPS\DateTime::ts( \IPS\Member::loggedIn()->mod_posts )->relative()"}
</p>
{{endif}}
<ul class='ipsButtons'>
{{foreach $warnings as $idx => $warning}}
<li>
<a href="{$warning->url()}" class='ipsButton ipsButton--inherit' data-ipsDialog data-ipsDialog-size='narrow'>{lang="view_warning_details"}</a>
</li>
{{endforeach}}
<li>
<button type="submit" class="ipsButton ipsButton--primary">{lang="continue"}</button>
</li>
</ul>
{{endif}}
</form>
</div>]]></template>
<template template_group="submit" template_name="processing" template_data="$redirector" template_location="front" template_app="gallery"><![CDATA[
<div class='i-padding_4'>
<p class='i-font-size_2 i-text-align_center i-margin-bottom_3'>{lang="saving_images_desc"}</p>
{$redirector|raw}
</div>]]></template>
<template template_group="submit" template_name="uploadImages" template_data="$form, $category" template_location="front" template_app="gallery"><![CDATA[
<form accept-charset='utf-8' method="post" action="{$form->action}" id='elGallerySubmit' enctype="multipart/form-data">
<div class='cGallerySubmit_uploadImages' data-controller='gallery.front.submit.uploadImages'>
{{if $form->error}}
<div class="ipsMessage ipsMessage--error i-margin-bottom_3">
{$form->error}
</div>
{{endif}}
<input type="hidden" name="{$form->id}_submitted" value="1">
{{foreach $form->hiddenValues as $k => $v}}
<input type="hidden" name="{$k}" value="{$v}">
{{endforeach}}
<div class='ipsHide'>
{$form->elements['']['credit_all']->html()|raw}
{$form->elements['']['copyright_all']->html()|raw}
{$form->elements['']['tags_all']->html()|raw}
{$form->elements['']['prefix_all']->html()|raw}
{$form->elements['']['images_order']->html()|raw}
{$form->elements['']['images_info']->html()|raw}
{{if settings.gallery_nsfw}}{$form->elements['']['nsfw_all']->html()|raw}{{endif}}
{{if \IPS\Member::loggedIn()->member_id}}{$form->elements['']['images_autofollow_all']->html()|raw}{{endif}}
</div>
<div id='elGallerySubmit_imageUploader' class=''>
{$form->elements['']['images']->html( $form )|raw}
{{if $form->elements['']['images']->error}}
<br>
<span class="i-color_warning">{lang="$form->elements['']['images']->error"}</span>
{{endif}}
</div>
</div>
</form>]]></template>
<template template_group="submit" template_name="wrapper" template_data="$container, $images, $club, $allImagesForm" template_location="front" template_app="gallery"><![CDATA[
{{if $club AND \is_array( $container ) AND !\IPS\Request::i()->isAjax()}}
{template="header" group="clubs" app="core" params="$club, $container['category']"}
{{endif}}
<div data-controller='gallery.front.submit.wrapper' data-role="submitWrapper" class='{{if !\IPS\Request::i()->isAjax()}}ipsBox{{endif}}'>
<div class='cGalleryDialog'>
<div class='cGalleryDialog_inner'>
<div class='cGalleryDialog_primary'>
<div class='cGalleryDialog_title'>
<h1 class='ipsDialog_title'>
<span data-role='dialogTitle'>{lang="add_gallery_image"}</span>
<div data-role="containerInfo">
{{if \is_array( $container )}}
{template="container" group="submit" app="gallery" params="$container"}
{{endif}}
</div>
</h1>
<a href='#' data-action='closeDialog' class='cGalleryDialog_close'>&times;</a>
</div>
<div class='cGalleryDialog_container {{if \is_array( $container )}}ipsHide{{endif}}' data-role="container">
{{if !\is_array( $container )}}
{$container|raw}
{{endif}}
</div>
<div class='cGalleryDialog_imageForm {{if \is_string( $container )}} ipsHide{{endif}}{{if \IPS\gallery\Image::moderateNewItems( \IPS\Member::loggedIn(), ( is_array( $container ) ) ? $container['category'] : NULL, FALSE )}} cGalleryDialog_content_moderated{{endif}}' data-role="images">
<div class="cGalleryDialog_imageFormAlign">
<div id='elGallerySubmit_toolBar'>
<ul class='ipsButtons'>
<li>
<button type="button" id="elCopyrightMenu" popovertarget="elCopyrightMenu_menu" class='ipsButton ipsButton--inherit ipsButton--small'>{lang="set_copyright_all"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elCopyrightMenu_menu">
<div class="iDropdown">
<div class="i-padding_3">
<h3 class='ipsTitle ipsTitle--h3 i-margin-bottom_2'>{lang="copyright"}</h3>
<p class='i-margin-bottom_3 i-color_soft'>{lang="set_copyright_desc"}</p>
{$allImagesForm->elements['']['image_copyright']->html()|raw}
<button class='ipsButton ipsButton--inherit ipsButton--small ipsButton--wide i-margin-top_3' type="button" popovertarget="elCopyrightMenu_menu">{lang="save"}</button>
</div>
</div>
</i-dropdown>
</li>
<li>
<button type="button" id="elCreditMenu" popovertarget="elCreditMenu_menu" class='ipsButton ipsButton--inherit ipsButton--small'>{lang="set_credit_all"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elCreditMenu_menu">
<div class="iDropdown">
<div class="i-padding_3">
<h3 class='ipsTitle ipsTitle--h3 i-margin-bottom_2'>{lang="credit"}</h3>
<p class='i-margin-bottom_3 i-color_soft'>{lang="credit_desc"}</p>
{$allImagesForm->elements['']['image_credit_info']->html()|raw}
<button class='ipsButton ipsButton--inherit ipsButton--small ipsButton--wide i-margin-top_3' type="button" popovertarget="elCreditMenu_menu">{lang="save"}</button>
</div>
</div>
</i-dropdown>
</li>
<li class='{{if !isset( $allImagesForm->elements['']['image_tags'] )}}ipsHide{{endif}} cGalleryTagsButton'>
<button type="button" id="elTagsMenu" popovertarget="elTagsMenu_menu" class='ipsButton ipsButton--inherit ipsButton--small'>{lang="set_tags_all"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elTagsMenu_menu">
<div class="iDropdown">
<div class="i-padding_3">
<h3 class='ipsTitle ipsTitle--h3 i-margin-bottom_2'>{lang="tags"}</h3>
<p class='i-margin-bottom_3 i-color_soft'>{lang="tags_all_desc"}</p>
<div data-role="globalTagsField">{{if isset( $allImagesForm->elements['']['image_tags'] )}}{$allImagesForm->elements['']['image_tags']->html()|raw}{{endif}}</div>
<button class='ipsButton ipsButton--inherit ipsButton--small ipsButton--wide i-margin-top_3' type="button" popovertarget="elTagsMenu_menu">{lang="save"}</button>
</div>
</div>
</i-dropdown>
</li>
{{if settings.gallery_nsfw}}
<li>
<button type="button" id="elNSFW" popovertarget="elNSFW_menu" class='ipsButton ipsButton--inherit ipsButton--small'>{lang="nsfw_set_all"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elNSFW_menu">
<div class="iDropdown">
<div class="i-padding_3">
{$allImagesForm->elements['']['image_nsfw']->html()|raw} <label for='check_image_nsfw'>{lang="nsfw_enable_all"}</label>
<button class='ipsButton ipsButton--inherit ipsButton--small ipsButton--wide i-margin-top_3' type="button" popovertarget="elNSFW_menu">{lang="save"}</button>
</div>
</div>
</i-dropdown>
</li>
{{endif}}
{{if \IPS\Member::loggedIn()->member_id}}
<li>
<button type="button" id="elNotifyOption" popovertarget="elNotifyOption_menu" class='ipsButton ipsButton--inherit ipsButton--small'>{lang="gal_notification_options"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elNotifyOption_menu">
<div class="iDropdown">
<div class="i-padding_3">
{$allImagesForm->elements['']['image_auto_follow']->html()|raw} <label for='check_image_auto_follow'>{lang="new_image_comments_notification"}</label>
<button class='ipsButton ipsButton--inherit ipsButton--small ipsButton--wide i-margin-top_3' type="button" popovertarget="elNotifyOption_menu">{lang="save"}</button>
</div>
</div>
</i-dropdown>
</li>
{{endif}}
<li>
<button type="button" id="elFileTypes" popovertarget="elFileTypes_menu" class='i-margin-start_auto ipsButton ipsButton--inherit ipsButton--small'>
<i class='fa-solid fa-circle-info'></i> {lang="allowed_file_types_link"} <i class='fa-solid fa-caret-down'></i>
</button>
<i-dropdown popover id="elFileTypes_menu">
<div class="iDropdown">
<div class="i-padding_3">
<h3 class='ipsTitle ipsTitle--h3'>{lang="attach_allowed_types"}</h3>
<div class='i-margin-top_2 i-color_soft i-font-size_-2' data-role="allowedTypes"></div>
</div>
</div>
</i-dropdown>
</li>
</ul>
</div>
<div data-role='imageForm' class='i-padding_3'>
{{if \is_array( $container )}}
{$images|raw}
{{endif}}
</div>
</div>
</div>
</div>
<div class='cGallerySubmit_imageDetails' data-role="imageDetails">
<form id='form_imageDetails' accept-charset='utf-8' method="post" action="{$allImagesForm->action}" enctype="multipart/form-data">
<div class='i-text-align_center i-color_soft i-font-size_2 i-opacity_4 i-margin-top_3' data-role='submitHelp'>
<i class='fa-regular fa-image i-font-size_6 i-color_soft'></i>
<br><br> {lang="submit_help_info"}
</div>
</form>
</div>
</div>
<div class='ipsSubmitRow cGallerySubmit_bottomBar {{if !\is_array( $container )}}ipsHide{{endif}}'>
<span data-role='imageErrors' class='ipsHide i-color_negative'><i class='fa-solid fa-triangle-exclamation'></i> {lang="files_had_errors"}</span>
<button type='submit' class='ipsButton ipsButton--negative' data-action="closeDialog" form="elGalleryClose">{lang="cancel"}</button>
<button type='submit' class='ipsButton ipsButton--primary' data-role='submitForm' form="elGallerySubmit" disabled>{lang="submit_all_images"}</button>
</div>
</div>
<div data-role="defaultImageDetailsForm" class='ipsHide'>
<div class='cGallerySubmit_details'>
<div class="i-padding_3">
<div class='cGallerySubmit_preview ipsThumb'></div>
</div>
<ul class='ipsForm ipsForm--vertical ipsForm--gallery-submit'>
<li class='ipsFieldRow'>
<label class='ipsFieldRow__label' for='image_details_DEFAULT'>{lang="image_title"}</label>
<div class='ipsFieldRow__content'>
{$allImagesForm->elements['']['image_title_DEFAULT']->html()|raw}
<p class='i-color_warning ipsHide' data-errorField='image_title'></p>
</div>
</li>
<li class='ipsFieldRow'>
<label class='ipsFieldRow__label' for='image_description_DEFAULT'>{lang="image_description"}</label>
<div class='ipsFieldRow__content'>
<div data-role="imageDescriptionEditor" class='ipsHide'>
{$allImagesForm->elements['']['filedata__image_description_DEFAULT']->html()|raw}
<div class='i-text-align_end i-font-size_-2 i-margin-top_2'><a href='#' data-role="imageDescriptionUseTextarea">{lang="use_plain_editor"}</a></div>
<p class='i-color_warning ipsHide' data-errorField='image_description'></p>
</div>
<div data-role="imageDescriptionTextarea">
{$allImagesForm->elements['']['image_textarea_DEFAULT']->html()|raw}
<div class='i-text-align_end i-font-size_-2 i-margin-top_2'><a href='#' data-role="imageDescriptionUseEditor">{lang="use_rte_editor"}</a></div>
<p class='i-color_warning ipsHide' data-errorField='image_textarea'></p>
</div>
</div>
</li>
<li class='ipsFieldRow cGalleryTagsField {{if !isset( $allImagesForm->elements['']['image_tags_DEFAULT'] )}}ipsHide{{endif}}'>
<label class='ipsFieldRow__label' for='image_tags_default'>{lang="image_tags"}</label>
<div class='ipsFieldRow__content'>
{{if isset( $allImagesForm->elements['']['image_tags_DEFAULT'] )}}{expression="preg_replace( '/data-ipsAutocomplete(?!\-)/', '', $allImagesForm->elements['']['image_tags_DEFAULT']->html() )" raw="true"}{{endif}}
<p class='i-color_warning ipsHide' data-errorField='image_tags'></p>
</div>
</li>
<li class='ipsFieldRow'>
<label class='ipsFieldRow__label' for='image_credit_DEFAULT'>{lang="image_credit_info"}</label>
<div class='ipsFieldRow__content'>
{$allImagesForm->elements['']['image_credit_info_DEFAULT']->html()|raw}
<p class='i-color_warning ipsHide' data-errorField='image_credit'></p>
</div>
</li>
<li class='ipsFieldRow'>
<label class='ipsFieldRow__label' for='image_copyright_DEFAULT'>{lang="image_copyright"}</label>
<div class='ipsFieldRow__content'>
{$allImagesForm->elements['']['image_copyright_DEFAULT']->html()|raw}
<p class='i-color_warning ipsHide' data-errorField='image_copyright'></p>
</div>
</li>
<li class='ipsFieldRow ipsHide cGalleryMapField'>
<label class='ipsFieldRow__label' for='image_gps_show_DEFAULT'>{lang="image_gps_show"}</label>
<div class='ipsFieldRow__content'>
{$allImagesForm->elements['']['image_gps_show_DEFAULT']->html()|raw}
<div class='ipsFieldRow__desc'>{lang="image_gps_show_desc"}</div>
<p class='i-color_warning ipsHide' data-errorField='image_gps_show'></p>
</div>
</li>
<li class='ipsFieldRow ipsHide cGalleryThumbField'>
<label class='ipsFieldRow__label' for='image_thumbnail_DEFAULT'>{lang="image_thumbnail"}</label>
<div class='ipsFieldRow__content'>
{$allImagesForm->elements['']['image_thumbnail_DEFAULT']->html()|raw}
<p class='i-color_warning ipsHide' data-errorField='image_thumbnail'></p>
</div>
</li>
{{foreach $allImagesForm->elements[''] as $k => $v}}
{{if !\in_array( $k, array( 'image_title_DEFAULT', 'image_tags_DEFAULT', 'image_gps_show_DEFAULT', 'image_thumbnail_DEFAULT', 'image_textarea_DEFAULT', 'image_description_DEFAULT', 'filedata__image_description_DEFAULT', 'image_credit_info_DEFAULT', 'image_copyright_DEFAULT', 'image_auto_follow_DEFAULT', 'image_credit_info', 'image_copyright', 'image_auto_follow', 'image_tags', 'image_nsfw' ) )}}
<li class='ipsFieldRow'>
{{$langString = str_replace( '_DEFAULT', '', $k );}}
<label class='ipsFieldRow__label' for='{$k}'>{lang="$langString"}</label>
<div class='ipsFieldRow__content'>
{$v->html()|raw}
</div>
</li>
{{endif}}
{{endforeach}}
<li class='ipsSubmitRow'>
<button type='button' class='ipsButton ipsButton--secondary ipsButton--wide' data-role='saveDetails'>{lang="submit_go_back"}</button>
<p class='ipsHide' data-role='savedMessage'>
<i class='fa-solid fa-check'></i> {lang="image_info_saved"}
</p>
</li>
</ul>
</div>
</div>
<div data-role="editedImageDetailsForm" class='ipsHide'></div>
</div>]]></template>
<template template_group="view" template_name="comments" template_data="$image" template_location="front" template_app="gallery"><![CDATA[<div data-controller='core.front.core.commentFeed, core.front.core.ignoredComments' {{if settings.auto_polling_enabled}}data-autoPoll{{endif}} data-baseURL='{$image->url()}' {{if $image->isLastPage()}}data-lastPage{{endif}} data-feedID='{$image->feedId}' id='comments' class="ipsEntries ipsEntries--comments ipsEntries--gallery-comments" data-follow-area-id="image-{$image->id}">
{template="featuredComments" group="global" app="gallery" params="$image->featuredComments(), $image->url()->setQueryString('tab', 'comments')->setQueryString('recommended', 'comments')"}
{{if $image->commentPageCount() > 1}}
<div class='ipsButtonBar'>
<div class='ipsButtonBar__pagination'>{$image->commentPagination( array('tab') )|raw}</div>
<div class='ipsButtonBar__end'>{template="commentMultimodHeader" app="core" group="global" params="$image, '#comments'"}</div>
</div>
{{endif}}
<div data-role='commentFeed' data-controller='core.front.core.moderation'>
<form action="{$image->url()->csrf()->setQueryString( 'do', 'multimodComment' )->setPage('page',\IPS\Request::i()->page)}" method="post" data-ipsPageAction data-role='moderationTools'>
{{if \count( $image->comments( NULL, NULL, 'date', 'asc', NULL, NULL, NULL, NULL, FALSE, isset( \IPS\Request::i()->showDeleted ) ) )}}
{{$commentCount=0; $timeLastRead = $image->timeLastRead(); $lined = FALSE;}}
{{foreach $image->comments( NULL, NULL, 'date', 'asc', NULL, NULL, NULL, NULL, FALSE, isset( \IPS\Request::i()->showDeleted ) ) as $comment}}
{{if !$lined and $timeLastRead and $timeLastRead->getTimestamp() < $comment->mapped('date')}}
{{if $lined = TRUE and $commentCount}}
<hr class="ipsUnreadBar">
{{endif}}
{{endif}}
{{$commentCount++;}}
{$comment->html()|raw}
{{endforeach}}
{{else}}
<p class='ipsEmptyMessage' data-role='noComments'>{lang="no_comments"}</p>
{{endif}}
{template="commentMultimod" app="core" group="global" params="$image"}
</form>
</div>
{{if $image->commentPageCount() > 1}}
<div class='ipsButtonBar ipsButtonBar--bottom'>
<div class='ipsButtonBar__pagination'>{$image->commentPagination( array('tab') )|raw}</div>
</div>
{{endif}}
{{if $image->commentForm() || $image->locked() || \IPS\Member::loggedIn()->restrict_post || \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings'] || !\IPS\Member::loggedIn()->checkPostsPerDay()}}
<div id='replyForm' data-role='replyArea' class='ipsComposeAreaWrapper {{if !$image->canComment()}}cTopicPostArea_noSize{{endif}}'>
{{if $image->commentForm()}}
{{if $image->locked()}}
<p class='ipsComposeArea_warning'><i class='fa-solid fa-circle-info'></i> {lang="image_locked_can_comment"}</p>
{{endif}}
{$image->commentForm()|raw}
{{else}}
{{if $image->locked()}}
{template="commentUnavailable" group="forms" location="front" app="gallery" params="'image_locked_cannot_comment'"}
{{elseif \IPS\Member::loggedIn()->restrict_post}}
{template="commentUnavailable" group="forms" location="front" app="gallery" params="'restricted_cannot_comment', \IPS\Member::loggedIn()->warnings(5,NULL,'rpa'), \IPS\Member::loggedIn()->restrict_post"}
{{elseif \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings']}}
{template="commentUnavailable" group="forms" location="front" app="gallery" params="'unacknowledged_warning_cannot_post', \IPS\Member::loggedIn()->warnings( 1, FALSE )"}
{{elseif !\IPS\Member::loggedIn()->checkPostsPerDay()}}
{template="commentUnavailable" group="forms" location="front" app="gallery" params="'member_exceeded_posts_per_day'"}
{{endif}}
{{endif}}
</div>
{{endif}}
</div>
]]></template>
<template template_group="view" template_name="image" template_data="$image, $commentsAndReviews=FALSE" template_location="front" template_app="gallery"><![CDATA[
{{if $club = $image->container()->club()}}
{{if settings.clubs and settings.clubs_header == 'full'}}
{template="header" app="core" group="clubs" params="$club, $image->container()"}
{{endif}}
<div id='elClubContainer'>
{{endif}}
<div data-controller='gallery.front.view.image{{if settings.gallery_nsfw}},gallery.front.global.nsfw{{endif}}' data-lightboxURL='{$image->url()}' class="ipsBlockSpacer">
<div class='ipsPull i-margin-bottom_block'>
<div class='elGalleryHeader'>
{template="imageFrame" group="view" app="gallery" params="$image"}
</div>
{{if $image->hasPreviousOrNext() }}
{template="imageCarouselLinks" app="gallery" group="view" location="front" params="$image"}
{{endif}}
</div>
{template="imageInfo" group="view" params="$image"}
{template="imageComments" app="gallery" location="front" group="view" params="$image, $commentsAndReviews"}
</div>
{{if $image->container()->club()}}
</div>
{{endif}}]]></template>
<template template_group="view" template_name="imageCarouselLink" template_data="$carouselImage, $active=false" template_location="front" template_app="gallery"><![CDATA[{{$imageWidth=isset( $carouselImage->_dimensions['small'][0] ) ? $carouselImage->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $carouselImage->_dimensions['small'][1] ) ? $carouselImage->_dimensions['small'][1] : 0;}}
<li {{if $active}}data-active{{endif}} {{if $imageWidth && $imageHeight}}style='--i-ratio:{$imageWidth}/{$imageHeight}'{{endif}} data-image-id="{$carouselImage->id}" >
<figure class='ipsFigure'>
{{if $carouselImage->media }}
<a href='{$carouselImage->url()}' title='{lang="view_this_video" sprintf="$carouselImage->caption"}' class='ipsFigure__main' data-action="changeImage">
<video data-role="video" preload="metadata" loading="lazy"{{if $carouselImage->masked_file_name }} poster="{file="$carouselImage->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$carouselImage->original_file_name" extension="gallery_Images"}{{if !$carouselImage->masked_file_name }}#t=1{{endif}}" type='{$carouselImage->file_type}' />
</video>
<i class="ipsFigure__play"></i>
</a>
{{else}}
<a href='{$carouselImage->url()}' title='{lang="view_this_image" sprintf="$carouselImage->caption"}' class='ipsFigure__main' data-action="changeImage">
<img src='{file="$carouselImage->small_file_name" extension="gallery_Images"}' alt="{$carouselImage->caption}" loading="lazy">
</a>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$carouselImage, FALSE"}
</figure>
</li>]]></template>
<template template_group="view" template_name="imageCarouselLinks" template_data="$image" template_location="front" template_app="gallery"><![CDATA[
{{$prev = array_reverse( array_slice( $image->fetchNextOrPreviousImages( 9, 'ASC' ), 0, 4 ) );}}
{{$next = $image->fetchNextOrPreviousImages( 9, 'DESC' );}}
<div class='cGalleryImageThumbs'>
<ol class='ipsCarousel ipsCarousel--images ipsCarousel--gallery-image-thumbs' id='gallery-image-thumbs' tabindex="0">
{{$counter = 1;}}
{{foreach $prev as $id => $carouselImage}}
{template="imageCarouselLink" app="gallery" group="view" location="front" params="$carouselImage"}
{{$counter++;}}
{{endforeach}}
{template="imageCarouselLink" app="gallery" group="view" location="front" params="$image, true"}
{{$counter++;}}
{{foreach $next as $id => $carouselImage}}
{template="imageCarouselLink" app="gallery" group="view" location="front" params="$carouselImage"}
{{$counter++;}}
{{if $counter === 10}}
{{break;}}
{{endif}}
{{endforeach}}
</ol>
{template="carouselNavigation" group="global" app="core" params="'gallery-image-thumbs'"}
</div>]]></template>
<template template_group="view" template_name="imageComments" template_data="$image, $commentsAndReviews" template_location="front" template_app="gallery"><![CDATA[<div data-role="imageComments">
{{if $commentsAndReviews}}
{{if ( $image->directContainer()->allow_reviews && $image->container()->allow_reviews ) && ( $image->directContainer()->allow_comments && $image->container()->allow_comments ) }}
<a id="replies"></a>
<h2 hidden>{lang="user_feedback"}</h2>
{{endif}}
<div class='ipsBox ipsBox--galleryImageCommentsReviews ipsPull'>
{$commentsAndReviews|raw}
</div>
{{endif}}
</div>]]></template>
<template template_group="view" template_name="imageFrame" template_data="$image" template_location="front" template_app="gallery"><![CDATA[
<div id='elGalleryImage' class='elGalleryImage' data-role="imageFrame" data-image-id="{$image->id}" {{if $image->data}}data-imageSizes='{$image->data}'{{endif}}>
{{if $image->media }}
<div class='cGallery_videoContainer' data-ips-hook="videoContainer">
<video data-controller="core.global.core.embeddedvideo" id="elGalleryVideo" data-role="video" controls preload="auto" width="100%" height="100%"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}" type='{$image->file_type}' />
<embed wmode="opaque" autoplay="true" showcontrols="true" showstatusbar="true" showtracker="true" src="{file="$image->original_file_name" extension="gallery_Images"}" width="480" height="360" type='{$image->file_type}' />
</video>
</div>
{{else}}
<div class='cGalleryViewImage' data-role='notesWrapper' data-controller='gallery.front.view.notes' data-imageID='{$image->id}' {{if $image->canEdit()}}data-editable{{endif}} data-notesData='{$image->_notes_json}' data-ips-hook="imageContainer">
<a href='{file="$image->masked_file_name" extension="gallery_Images"}' title='{lang="view_in_lightbox"}' data-ipsLightbox>
{{$imageWidth=isset( $image->_dimensions['small'][0] ) ? $image->_dimensions['small'][0] : 0;}}
{{$imageHeight=isset( $image->_dimensions['small'][1] ) ? $image->_dimensions['small'][1] : 0;}}
<img src='{file="$image->masked_file_name" extension="gallery_Images"}' alt="{$image->caption}" {{if $imageWidth && $imageHeight}}width="{$imageWidth}" height="{$imageHeight}"{{endif}} title='{$image->caption}' data-role='theImage' fetchpriority="high" decoding="sync">
</a>
{{if \is_countable( $image->_notes ) AND \count( $image->_notes )}}
<noscript>
{{foreach $image->_notes as $note}}
<div class='cGalleryNote' style='left: {$note['LEFT']}%; top: {$note['TOP']}%; width: {$note['WIDTH']}%; height: {$note['HEIGHT']}%'>
<div class='cGalleryNote_border'></div>
<div class='cGalleryNote_note'><div>{$note['NOTE']}</div></div>
</div>
{{endforeach}}
</noscript>
{{endif}}
</div>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image"}
<div class='cGalleryImageFade'>
{{if $image->canEdit() OR $image->canDownloadOriginal() OR \IPS\Member::loggedIn()->member_id}}
<button type="button" id="elImageTools" popovertarget="elImageTools_menu" class='ipsButton ipsButton--overlay ipsJS_show cGalleryViewImage_controls'><span>{lang="image_tools"}</span> <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elImageTools_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if $image->canEdit()}}
<li class='ipsResponsive_hidePhone'>
<button type="button" title='{lang="add_image_note"}' data-action='addNote'><i class='fa-solid fa-pen-to-square'></i> {lang="add_image_note"}</button>
</li>
{{if !$image->media}}
<li><hr class='ipsResponsive_hidePhone'></li>
<li>
<a href='{$image->url( 'rotate' )->csrf()->setQueryString( 'direction', 'right' )}' title='{lang="rotate_right"}'>
<i class='fa-solid fa-rotate-right'></i> {lang="rotate_right"}
</a>
</li>
<li>
<a href='{$image->url( 'rotate' )->csrf()->setQueryString( 'direction', 'left' )}' title="{lang="rotate_left"}">
<i class='fa-solid fa-rotate-left'></i> {lang="rotate_left"}
</a>
</li>
{{endif}}
{{endif}}
{{if \IPS\Member::loggedIn()->member_id}}
{{if $image->canSetAsAlbumCover() OR $image->canSetAsCategoryCover()}}
<li><hr></li>
{{if $image->canSetAsAlbumCover() AND $image->canSetAsCategoryCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'category')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_category_only"}</a></li>
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'album')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_album_only"}</a></li>
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'both')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_both"}</a></li>
{{elseif $image->canSetAsCategoryCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'category')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_category"}</a></li>
{{elseif $image->canSetAsAlbumCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'album')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_album"}</a></li>
{{endif}}
{{if \IPS\Member::loggedIn()->member_id}}
<li>
<a href='{$image->url('setAsPhoto')->csrf()}' data-action='setAsProfile' title="{lang="set_gallery_image_photo"}"><i class="fa-solid fa-circle-user"></i>{lang="set_gallery_image_photo"}</a>
</li>
{{if \IPS\Settings::i()->gallery_nsfw and $image->canEdit()}}
<li><hr></li>
<li>
<a href='{$image->url('toggleNSFW')->csrf()}' data-action='setAsProfile' title="{{if $image->nsfw}}{lang="set_gallery_image_nsfw_on"}{{else}}{lang="set_gallery_image_nsfw_off"}{{endif}}"><i class="fa-solid fa-eye-slash"></i>{{if $image->nsfw}}{lang="set_gallery_image_nsfw_on"}{{else}}{lang="set_gallery_image_nsfw_off"}{{endif}}</a>
</li>
{{endif}}
{{endif}}
{{elseif \IPS\Member::loggedIn()->member_id}}
<li>
<a href='{$image->url('setAsPhoto')->csrf()}' title='{lang="set_gallery_image_photo"}'><i class="fa-solid fa-circle-user"></i>{lang="set_gallery_image_photo"}</a>
</li>
{{endif}}
</li>
{{endif}}
{{if $image->canDownloadOriginal()}}
<li>
<a href='{$image->url('download')}' title='{lang="download"}'><i class='fa-solid fa-download'></i> {lang="download"}</a>
</li>
{{endif}}
</ul>
</div>
</i-dropdown>
{{endif}}
</div>
{{endif}}
<span class='elGalleryImageNav'>
{{if $image->hasPreviousOrNext()}}
<a href='{$image->url()->setQueryString( [ 'browse' => 1, 'do' => 'previous' ] )}' class='elGalleryImageNav_prev' data-action="changeImage" data-direction="prev"><i class="fa-solid fa-arrow-left"></i></a>
<a href='{$image->url()->setQueryString( [ 'browse' => 1, 'do' => 'next' ] )}' class='elGalleryImageNav_next' data-action="changeImage" data-direction="next"><i class="fa-solid fa-arrow-right"></i></a>
{{endif}}
</span>
</div>]]></template>
<template template_group="view" template_name="imageInfo" template_data="$image" template_location="front" template_app="gallery"><![CDATA[
<section data-role='imageInfo'>
{template="contentItemMessages" group="global" app="core" params="$image->getMessages(), $image"}
{{if $image->hidden() === 1 and $image->canUnhide()}}
<div class="ipsBox i-padding_3 i-margin-bottom_3">
<p><i class='fa-solid fa-triangle-exclamation'></i> {lang="image_pending_approval"}</p>
<ul class='ipsButtons i-margin-top_3'>
<li><a href="{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'unhide' ) )}" class="ipsButton ipsButton--small ipsButton--positive" title='{lang="approve_title_image"}'><i class="fa-solid fa-check-circle"></i> &nbsp;{lang="approve"}</a></li>
{{if $image->canDelete()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'delete' ) )}' data-confirm title='{lang="delete_title_image"}' class="ipsButton ipsButton--small ipsButton--negative"><i class='fa-solid fa-xmark'></i> &nbsp;{lang="delete"}</a></li>
{{endif}}
</ul>
</div>
{{endif}}
<div class='ipsBox ipsColumns ipsColumns--lines ipsPull i-margin-bottom_block'>
<div class='ipsColumns__primary'>
<article>
<div data-role='imageDescription'>
<header class='ipsPageHeader'>
<div class="ipsPageHeader__row">
<div class="ipsPageHeader__primary" data-ips-hook="header">
<div class='ipsPageHeader__title'>
<h1 data-ips-hook='title'>
{{if $image->canEdit()}}
<span data-controller="core.front.core.moderation">{{if $image->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}
<span data-role="editableTitle" title='{lang="click_hold_edit"}'>{$image->caption}</span>
</span>
{{else}}
<span>{$image->caption}</span>
{{endif}}
</h1>
<div class='ipsBadges' data-ips-hook="badges">
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
</div>
</div>
{{if $image->directContainer()->allow_rating}}
<div class='ipsPageHeader__rating'>{$image->rating()|raw}</div>
{{endif}}
{{if \count( $image->tags() ) OR ( $image->canEdit() AND $image::canTag( NULL, $image->container() ) )}}
{template="tagsWithPrefix" group="global" app="core" params="$image->tags(), $image->prefix(), FALSE, FALSE, ( $image->canEdit() AND ( \count( $image->tags() ) OR $image::canTag( NULL, $image->container() ) ) ) ? $image->url() : NULL"}
{{endif}}
</div>
<div class='ipsButtons' data-ips-hook='buttons'>
{{if \count( $image->shareLinks() )}}
{template="shareButton" app="core" group="sharelinks" params="$image"}
{{endif}}
{template="follow" app="core" group="global" params="'gallery', 'image', $image->id, $image->followersCount()"}
</div>
</div>
<div class="ipsPageHeader__row ipsPageHeader__row--footer">
<div class='ipsPageHeader__primary' data-ips-hook="footer">
<div class='ipsPhotoPanel ipsPhotoPanel--inline'>
{template="userPhoto" app="core" group="global" params="$image->author(), 'mini', $image->warningRef()"}
<div class='ipsPhotoPanel__text' data-ips-hook="author">
<p class="ipsPhotoPanel__primary">{lang="byline_nodate_itemprop" htmlsprintf="$image->author()->link( $image->warningRef() )"}</p>
<ul class='ipsPhotoPanel__secondary ipsList ipsList--sep'>
<li>{datetime="$image->date"}</li>
<li>{lang="num_views_with_number" pluralize="$image->views"}</li>
{{if $image->author()->member_id}}
<li><a href='{url="app=core&module=members&controller=profile&id={$image->author()->member_id}&do=content&type=gallery_image" base="front" seoTitles="$image->author()->members_seo_name" seoTemplate="profile_content"}'>{lang="find_users_images" sprintf="$image->author()->name"}</a></li>
{{endif}}
</ul>
</div>
</div>
</div>
</div>
</header>
<div class='ipsEntry__post i-padding_3' data-ips-hook="info">
{{if $image->description}}
<div class='ipsRichText ipsRichText--user' data-controller="core.front.core.lightboxedImages">
{$image->content()|raw}
</div>
{{endif}}
{{if $image->credit_info OR $image->copyright}}
<div class='i-margin-top_4 i-flex i-flex-wrap_wrap i-gap_2'>
{{if $image->credit_info}}
<div class='i-flex_11'>
<h3 class='ipsTitle ipsTitle--h6'>{lang="image_credit_info"}</h3>
<div>
{$image->credit_info}
</div>
</div>
{{endif}}
{{if $image->copyright}}
<div class='i-flex_11'>
<h3 class='ipsTitle ipsTitle--h6'>{lang="image_copyright"}</h3>
<div>
&copy; {$image->copyright}
</div>
</div>
{{endif}}
</div>
{{endif}}
</div>
</div>
<footer class='ipsEntry__footer'>
<menu class='ipsEntry__controls'>
<li>{$image->menu()|raw}</li>
</menu>
{{if \IPS\IPS::classUsesTrait( $image, 'IPS\Content\Reactable' ) and settings.reputation_enabled}}
{template="reputation" app="core" group="global" params="$image"}
{{endif}}
</footer>
</div>
</article>
<div class='ipsColumns__secondary i-basis_380 i-padding_3' id='elGalleryImageStats'>
<div class='' data-role="imageStats" data-ips-hook="imageStats">
{{if $image->showLocation()}}
{$image->map( 308, 200 )|raw}
<div class='i-margin-top_2'>
<div class='i-flex i-justify-content_space-between i-flex-wrap_wrap i-gap_1'>
<div>
{$image->loc_short}
</div>
{{if $image->canEdit() }}
<div>
<button type="button" id="elMapForm" popovertarget="elMapForm_menu" class='i-color_soft'>{lang="map_privacy"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elMapForm_menu">
<div class="iDropdown">
<div class='i-padding_2'>
{$image->enableMapForm()|raw}
</div>
</div>
</i-dropdown>
</div>
{{endif}}
</div>
</div>
<hr class='ipsHr'>
{{elseif $image->showLocation() AND $image->canEdit() AND $image->gps_raw}}
<div class='i-opacity_6'>
{$image->map( 308, 200 )|raw}
<div class='i-font-size_-1 i-margin-top_2'>
{$image->loc_short}
</div>
</div>
<div class='i-font-size_-1 i-margin-top_2'>
<div class='i-flex i-justify-content_space-between i-flex-wrap_wrap i-gap_1'>
<div>
<strong>{lang="map_not_being_shown"}</strong>
</div>
<div>
<button type="button" id="elMapForm" popovertarget="elMapForm_menu">{lang="map_privacy"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elMapForm_menu">
<div class="iDropdown">
<div class='i-padding_3'>
{$image->enableMapForm()|raw}
</div>
</div>
</i-dropdown>
</div>
</div>
</div>
<hr class='ipsHr'>
{{endif}}
<div data-ips-hook="container">
<h2 class='ipsTitle ipsTitle--h6 i-color_soft'>{{if $image->directContainer() instanceof \IPS\gallery\Album}}{lang="from_the_album"}{{else}}{lang="from_the_category"}{{endif}}</h2>
<h3 class='ipsTitle ipsTitle--h4 i-display_inline-block'><a href='{$image->directContainer()->url()}'>{$image->directContainer()->_title}</a></h3>
<span class='i-color_soft'>&middot; {lang="num_images" pluralize="$image->directContainer()->count_imgs"}</span>
</div>
<hr class='ipsHr'>
{{if \is_countable($image->metadata) AND \count($image->metadata)}}
<div class='cGalleryExif' data-ips-hook="exif">
{{if isset( $image->metadata['EXIF.FocalLength'] ) || ( isset( $image->metadata['IFD0.Make'] ) AND isset( $image->metadata['IFD0.Model'] ) ) || isset( $image->metadata['EXIF.ShutterSpeedValue'] ) || isset( $image->metadata['COMPUTED.ApertureFNumber'] ) || isset( $image->metadata['Exif.Photo.ISOSpeed'] )}}
<h3 class='ipsTitle ipsTitle--h4 ipsTitle--margin'>{lang="gallery_metadata" sprintf="$image->caption"}</h3>
<ul class='ipsList ipsList--border ipsList--label-value'>
{{if isset( $image->metadata['IFD0.Make'] ) AND isset( $image->metadata['IFD0.Model'] )}}
<li>
<i class="fa-solid fa-camera-retro" aria-hidden="true"></i>
<strong class='ipsList__label'>{lang="gallery_exif_camera"}</strong>
<span class='ipsList__value'>{$image->metadata['IFD0.Make']} {$image->metadata['IFD0.Model']}</span>
</li>
{{endif}}
{{if isset( $image->metadata['EXIF.FocalLength'] )}}
<li>
<i class='fa-solid fa-arrows-left-right'></i>
<strong class='ipsList__label'>{lang="EXIF.FocalLength"}</strong>
<span class='ipsList__value'>{$image->focallength}</span>
</li>
{{endif}}
{{if isset( $image->metadata['EXIF.ExposureTime'] )}}
<li>
<i class='fa-regular fa-clock'></i>
<strong class='ipsList__label'>{lang="EXIF.ExposureTime"}</strong>
<span class='ipsList__value'>{$image->metadata['EXIF.ExposureTime']}</span>
</li>
{{endif}}
{{if isset( $image->metadata['COMPUTED.ApertureFNumber'] )}}
<li>
<i class="fa-solid fa-expand"></i>
<strong class='ipsList__label'>{lang="COMPUTED.ApertureFNumber"}</strong>
<span class='ipsList__value'>{$image->metadata['COMPUTED.ApertureFNumber']}</span>
</li>
{{endif}}
{{if isset( $image->metadata['Exif.Photo.ISOSpeed'] ) || isset( $image->metadata['EXIF.ISOSpeedRatings'] )}}
<li>
<i class="fa-solid fa-camera" aria-hidden="true"></i>
<strong class='ipsList__label'>{lang="gallery_exif_isospeed"}</strong>
<span class='ipsList__value'>
{{if isset( $image->metadata['Exit.Photo.ISOSpeed'] )}}
{$image->metadata['Exif.Photo.ISOSpeed']}
{{else}}
{{if \is_array( $image->metadata['EXIF.ISOSpeedRatings'] )}}
{expression="implode( '/', $image->metadata['EXIF.ISOSpeedRatings'] )"}
{{else}}
{$image->metadata['EXIF.ISOSpeedRatings']}
{{endif}}
{{endif}}
</span>
</li>
{{endif}}
</ul>
<div class='i-text-align_center i-margin-top_3'>
<a href='{$image->url( 'metadata' )}' data-ipsDialog data-ipsdialog-size="narrow" data-ipsDialog-title='{lang="view_all_photo_info"}' class='ipsButton ipsButton--inherit'>{lang="view_all_photo_info"}</a>
</div>
{{else}}
<div class='i-text-align_center i-margin-top_3'>
<a href='{$image->url( 'metadata' )}' data-ipsDialog data-ipsdialog-size="narrow" data-ipsDialog-title='{lang="view_all_photo_info"}' class='ipsButton ipsButton--inherit'>{lang="view_photo_info"}</a>
</div>
{{endif}}
</div>
{{endif}}
</div>
</div>
</div>
<div class='ipsBox ipsBox--padding ipsPull ipsResponsive_showPhone'>
<div class='ipsPageActions'>
{{if \count( $image->shareLinks() )}}
{template="shareButton" app="core" group="sharelinks" params="$image"}
{{endif}}
{template="follow" app="core" group="global" params="'gallery', 'image', $image->id, $image->followersCount()"}
</div>
</div>
</section>]]></template>
<template template_group="view" template_name="imageLightbox" template_data="$image, $commentsAndReviews=FALSE" template_location="front" template_app="gallery"><![CDATA[
<div data-controller='gallery.front.view.image' class='cGalleryLightbox' data-role='lightbox'>
<div class='cGalleryLightbox_inner' data-role="imageSizer">
<div class='elGalleryHeader' class='cGalleryLightbox_image'>
{template="imageLightboxFrame" group="view" app="gallery" params="$image"}
</div>
<div class='cGalleryLightbox_info i-background_1'>
<section data-role='imageInfo'>
{template="imageLightboxInfo" group="view" params="$image, $commentsAndReviews"}
</section>
</div>
</div>
</div> ]]></template>
<template template_group="view" template_name="imageLightboxFrame" template_data="$image" template_location="front" template_app="gallery"><![CDATA[
<div id='elGalleryImageLightbox' class='elGalleryImage' data-role="imageFrame" data-setHeight {{if $image->data}}data-imageSizes='{$image->data}'{{endif}}>
{{if $image->media }}
<div class='cGallery_videoContainer' data-ips-hook="videoContainer">
<video data-controller="core.global.core.embeddedvideo" id="elGalleryVideo" data-role="video" data-imageID='{$image->id}' {{if $image->canEdit()}}data-editable{{endif}} controls preload="auto" width="100%" height="100%"{{if $image->masked_file_name }} poster="{file="$image->masked_file_name" extension="gallery_Images"}"{{endif}}>
<source src="{file="$image->original_file_name" extension="gallery_Images"}" type='{$image->file_type}' />
<embed wmode="opaque" autoplay="true" showcontrols="true" showstatusbar="true" showtracker="true" src="{file="$image->original_file_name" extension="gallery_Images"}" width="480" height="360" type='{$image->file_type}' />
</video>
</div>
{{else}}
<div class='cGalleryViewImage' data-role='notesWrapper' data-controller='gallery.front.view.notes' data-imageID='{$image->id}' {{if $image->canEdit()}}data-editable{{endif}} data-notesData='{$image->_notes_json}' data-ips-hook="imageContainer">
<div>
<img src='{file="$image->masked_file_name" extension="gallery_Images"}' alt="{$image->caption}" title='{$image->caption}' data-role='theImage' class='ipsHide'>
</div>
{{if \count( $image->_notes )}}
<noscript>
{{foreach $image->_notes as $note}}
<div class='cGalleryNote' style='left: {$note['LEFT']}%; top: {$note['TOP']}%; width: {$note['WIDTH']}%; height: {$note['HEIGHT']}%'>
<div class='cGalleryNote_border'></div>
<div class='cGalleryNote_note'><div>{$note['NOTE']}</div></div>
</div>
{{endforeach}}
</noscript>
{{endif}}
</div>
{{endif}}
<div class='cGalleryImageFade'>
<div class='cGalleryImageTopBar'>
<div class='cGalleryImageTitle'>
<h1 class='ipsTitle ipsTitle--h3'>
{{if $image->prefix() OR ( $image->canEdit() AND $image::canTag( NULL, $image->container() ) AND $image::canPrefix( NULL, $image->container() ) )}}
<span {{if !$image->prefix()}}class='ipsHide'{{endif}} {{if ( $image->canEdit() AND $image::canTag( NULL, $image->container() ) AND $image::canPrefix( NULL, $image->container() ) )}}data-editablePrefix{{endif}}>
{template="prefix" group="global" app="core" params="$image->prefix( TRUE ), $image->prefix()"}
</span>
{{endif}}
{{foreach $image->badges() as $badge}}{$badge|raw}{{endforeach}}
{{if $image->canEdit()}}
<span class='' data-controller="core.front.core.moderation">{{if $image->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}
<a href='{$image->url()}' data-role="editableTitle" title='{lang="click_hold_edit"}'>{$image->caption}</a>
</span>
{{else}}
<span class=''>{{if $image->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}{$image->caption}</span>
{{endif}}
</h1>
{{if $image->album_id}}
<div class='ipsType_desc ipsTruncate_1'>
<strong class='ipsMinorTitle'>{lang="from_the_album"}</strong> <em><a href='{$image->directContainer()->url()}'>{$image->directContainer()->name}</a></em>
({lang="num_images" pluralize="$image->directContainer()->count_imgs"})
</div>
{{endif}}
</div>
<ul class='cGalleryControls ipsList ipsList--inline'>
<li>
{template="promote" app="core" group="global" params="$image"}
</li>
<li>
{template="follow" app="core" group="global" params="'gallery', 'image', $image->id, $image->followersCount()"}
</li>
{{if !$image->media }}
<li>
<a href='{file="$image->masked_file_name" extension="gallery_Images"}' title='{lang="view_fullsize_image"}' class='ipsButton ipsButton--icon ipsButton--text ipsButton--small ipsButton--soft' data-ipsTooltip target='_blank' rel='noopener' data-role="toggleFullscreen"></a>
</li>
{{endif}}
</ul>
</div>
<div class='cGalleryImageBottomBar'>
<div class='cGalleryCreditInfo'>
{{if $image->copyright}}
<div>
&copy; {$image->copyright}
</div>
{{endif}}
{{if $image->credit_info}}
<div>
<strong>{lang="image_credit_info"}</strong> {$image->credit_info}
</div>
{{endif}}
</div>
{{if \count( $image->shareLinks() ) OR $image->canEdit() OR $image->canDownloadOriginal() OR \IPS\Member::loggedIn()->member_id}}
<ul class='ipsList ipsList--inline'>
{{if $image->canEdit() OR $image->canDownloadOriginal() OR \IPS\Member::loggedIn()->member_id}}
<li>
<button type="button" id="elImageToolsLightbox" popovertarget="elImageToolsLightbox_menu" class='ipsButton ipsButton--text ipsButton--small cGalleryViewImage_controls'>{lang="image_tools"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elImageToolsLightbox_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if $image->canEdit()}}
<li class='ipsResponsive_hidePhone'>
<button type="button" title='{lang="add_image_note"}' data-action='addNote'><i class='fa-solid fa-pen-to-square'></i> {lang="add_image_note"}</button>
</li>
{{if !$image->media}}
<li><hr class='ipsResponsive_hidePhone'></li>
<li>
<a href='{$image->url( 'rotate' )->csrf()->setQueryString( 'direction', 'right' )}' title='{lang="rotate_right"}' data-action="rotateImage">
<i class='fa-solid fa-rotate-right'></i>{lang="rotate_right"}
</a>
</li>
<li>
<a href='{$image->url( 'rotate' )->csrf()->setQueryString( 'direction', 'left' )}' title="{lang="rotate_left"}" data-action="rotateImage">
<i class='fa-solid fa-rotate-left'></i>{lang="rotate_left"}
</a>
</li>
{{endif}}
{{endif}}
{{if \IPS\Member::loggedIn()->member_id}}
{{if $image->canSetAsAlbumCover() OR $image->canSetAsCategoryCover()}}
<li><hr></li>
{{if $image->canSetAsAlbumCover() AND $image->canSetAsCategoryCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'category')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_category_only"}</a></li>
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'album')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_album_only"}</a></li>
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'both')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_both"}</a></li>
{{elseif $image->canSetAsCategoryCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'category')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_category"}</a></li>
{{elseif $image->canSetAsAlbumCover()}}
<li><a data-action='setAsCover' href='{$image->url()->setQueryString( 'do', 'cover' )->setQueryString( 'set', 'album')->csrf()}'><i class="fa-solid fa-images"></i>{lang="cover_album"}</a></li>
{{endif}}
<li><hr></li>
<li>
<a href='{$image->url('setAsPhoto')->csrf()}' data-action='setAsProfile' title="{lang="set_gallery_image_photo"}"><i class="fa-solid fa-circle-user"></i>{lang="set_gallery_image_photo"}</a>
</li>
{{endif}}
<a href='{$image->url('setAsPhoto')->csrf()}' title='{lang="set_gallery_image_photo"}' data-action="setAsProfile"><i class="fa-solid fa-circle-user"></i>{lang="set_gallery_image_photo"}</a>
{{endif}}
{{if $image->canDownloadOriginal()}}
<li>
<a href='{$image->url('download')}' title='{lang="download"}'><i class='fa-solid fa-download'></i> {lang="download"}</a>
</li>
{{endif}}
</ul>
</div>
</i-dropdown>
</li>
{{endif}}
{{if \count( $image->shareLinks() )}}
<li>
<button type="button" id="elImageLightboxShare" popovertarget="elImageLightboxShare_menu" class='ipsButton ipsButton--text ipsButton--small'><i class='fa-solid fa-share-nodes'></i>{lang="image_share"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elImageLightboxShare_menu">
<div class="iDropdown">
<div class='i-padding_3'>
{template="sharelinks" app="core" group="global" params="$image"}
</div>
</div>
</i-dropdown>
</li>
{{endif}}
</ul>
{{endif}}
</div>
</div>
<span class='elGalleryImageNav'>
{{if $image->hasPreviousOrNext()}}
<a href='{$image->url()->setQueryString( [ 'browse' => 1, 'do' => 'previous' ] )}' class='elGalleryImageNav_prev' data-action="changeImage"><i class='fa-solid fa-angle-left'></i></a>
<a href='{$image->url()->setQueryString( [ 'browse' => 1, 'do' => 'next' ] )}' class='elGalleryImageNav_next' data-action="changeImage"><i class='fa-solid fa-angle-right'></i></a>
{{endif}}
</span>
</div>]]></template>
<template template_group="view" template_name="imageLightboxInfo" template_data="$image, $commentsAndReviews" template_location="front" template_app="gallery"><![CDATA[<div data-role='imageDescription' {{if $image->hidden() === -1}}class='ipsModerated'{{endif}}>
{template="contentItemMessages" group="global" app="core" params="$image->getMessages(), $image"}
{{if $image->hidden() === 1 and $image->canUnhide()}}
<div class="ipsModerated i-padding_3">
<p><i class='fa-solid fa-triangle-exclamation'></i> {lang="image_pending_approval"}</p>
<br>
<ul class='ipsList ipsList--inline'>
<li><a href="{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'unhide' ) )}" class="ipsButton ipsButton--small ipsButton--positive" title='{lang="approve_title_image"}'><i class="fa-solid fa-check-circle"></i> &nbsp;{lang="approve"}</a></li>
{{if $image->canDelete()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'delete' ) )}' data-confirm title='{lang="delete_title_image"}' class="ipsButton ipsButton--small ipsButton--negative"><i class='fa-solid fa-xmark'></i> &nbsp;{lang="delete"}</a></li>
{{endif}}
</ul>
</div>
{{endif}}
<div class='ipsPhotoPanel ipsPhotoPanel--mini i-background_2 i-padding_3'>
{template="userPhoto" app="core" group="global" params="$image->author(), 'mini', $image->warningRef()"}
<div>
<p class='ipsTitle ipsTitle--h3'>
{$image->author()->link( $image->warningRef() )|raw}
</p>
<ul class='ipsList ipsList--inline i-link-color_inherit i-color_soft'>
<li>{datetime="$image->date"}</li>
<li>{lang="num_views_with_number" pluralize="$image->views"}</li>
{{if $image->canReportOrRevoke() === TRUE}}
<li>
<a href='{$image->url('report')}' {{if member.member_id or \IPS\Helpers\Form\Captcha::supportsModal()}}data-ipsDialog data-ipsDialog-size='medium' data-ipsDialog-title="{lang="report_image"}" data-ipsDialog-remoteSubmit data-ipsDialog-flashMessage="{lang="report_submit_success"}"{{endif}} title="{lang="report_image"}">{lang="report_image"}</a>
</li>
{{endif}}
</ul>
</div>
{{if ( $image->canEdit() or $image->canFeature() or $image->canPin() or $image->canHide() or $image->canUnhide() or $image->canMove() or $image->canLock() or $image->canUnlock() or $image->canDelete() or $image->canChangeAuthor() ) or ( $image->hidden() == -2 AND \IPS\Member::loggedIn()->modPermission('can_manage_deleted_content') )}}
<div>
<button type="button" id="elImageLightboxActions" popovertarget="elImageLightboxActions_menu" class='ipsButton ipsButton--inherit ipsButton--small ipsButton--icon' title='{lang="manage_image"}' data-ipsTooltip><i class='fa-solid fa-gear i-font-size_2'></i> <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elImageLightboxActions_menu">
<div class="iDropdown">
<ul class="iDropdown__items">
{{if \IPS\Member::loggedIn()->modPermission('can_manage_deleted_content') AND $image->hidden() == -2}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'restore' ) )}' data-confirm data-confirmSubMessage='{lang="restore_as_visible_desc"}'>{lang="restore_as_visible"}</a></li>
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'restoreAsHidden' ) )}' data-confirm data-confirmSubMessage='{lang="restore_as_hidden_desc"}'>{lang="restore_as_hidden"}</a></li>
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'delete', 'immediate' => 1 ) )}' data-confirm data-confirmSubMessage='{lang="delete_immediately_desc"}'>{lang="delete_immediately"}</a></li>
{{else}}
{{if $image->canChangeAuthor()}}
<li><a href='{$image->url()->setQueryString( array( 'do' => 'changeAuthor' ) )}' data-ipsDialog data-ipsDialog-size='narrow' data-ipsDialog-title="{lang="change_author"}" title='{lang="change_author_ititle"}'>{lang="change_author"}</a></li>
{{endif}}
{{if $image->canEdit()}}
<li><a href='{$image->url()->setQueryString( array( 'do' => 'edit' ) )}' title="{lang="gallery_edit_details_title"}" data-ipsDialog data-action="editImage">{lang="gallery_edit_details"}</a></li>
{{endif}}
{{if $image->canPin()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'pin' ) )}' title="{lang="pin_title_image"}">{lang="pin"}</a></li>
{{endif}}
{{if $image->canUnpin()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'unpin' ) )}' title="{lang="unpin_title_image"}">{lang="unpin"}</a></li>
{{endif}}
{{if $image->canHide()}}
<li><a href='{$image->url()->setQueryString( array( 'do' => 'moderate', 'action' => 'hide' ) )}' title="{lang="hide_title_image"}" data-ipsDialog data-ipsDialog-title="{lang="hide"}">{lang="hide"}</a></li>
{{endif}}
{{if $image->canUnhide()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'unhide' ) )}' title="{{if $image->hidden() === 1}}{lang="approve_title_image"}{{else}}{lang="unhide_title_image"}{{endif}}">{{if $image->hidden() === 1}}{lang="approve"}{{else}}{lang="unhide"}{{endif}}</a></li>
{{endif}}
{{if $image->canLock()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'lock' ) )}' title="{lang="lock_title_image"}">{lang="lock"}</a></li>
{{endif}}
{{if $image->canUnlock()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'unlock' ) )}' title="{lang="unlock_title_image"}">{lang="unlock"}</a></li>
{{endif}}
{{if $image->canMove()}}
<li><a href='{$image->url()->setQueryString( array( 'do' => 'move' ) )}' data-ipsDialog data-ipsDialog-size='narrow' data-ipsDialog-title="{lang="move"}" title="{lang="gallery_move_title"}">{lang="move"}</a></li>
{{endif}}
{{if $image->canDelete()}}
<li><a href='{$image->url()->csrf()->setQueryString( array( 'do' => 'moderate', 'action' => 'delete' ) )}' data-confirm title="{lang="delete_title_image"}">{lang="delete"}</a></li>
{{endif}}
{{if $image->canOnMessage( 'add' )}}
<li><a href='{$image->url()->setQueryString( array( 'do' => 'messageForm' ) )}' data-ipsDialog data-ipsDialog-title='{lang="add_message"}'>{lang="add_message"}</a></li>
{{endif}}
{{if \IPS\Member::loggedIn()->modPermission('can_view_moderation_log')}}
<li><hr></li>
<li><a href='{$image->url()->setQueryString( array( 'do' => 'modLog' ) )}' data-ipsDialog data-ipsDialog-title='{lang="moderation_history"}'>{lang="moderation_history"}</a></li>
{{endif}}
{{endif}}
</ul>
</div>
</i-dropdown>
</div>
{{endif}}
</div>
<div class='i-padding_3'>
{{if $image->directContainer()->allow_rating}}
<div class='i-margin-bottom_2'>{$image->rating('small')|raw}</div>
{{endif}}
{{if \count( $image->tags() ) OR ( $image->canEdit() AND $image::canTag( NULL, $image->container() ) )}}
<div class=''>
{template="tags" group="global" app="core" params="$image->tags(), FALSE, FALSE, ( $image->canEdit() AND ( \count( $image->tags() ) OR $image::canTag( NULL, $image->container() ) ) ) ? $image->url() : NULL"}
</div>
{{endif}}
{{if $image->description}}
<div class='ipsRichText i-margin-block_2' data-controller="core.front.core.lightboxedImages" data-ipsTruncate>
{$image->content()|raw}
</div>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $image, 'IPS\Content\Reactable' ) and settings.reputation_enabled}}
{template="reputation" app="core" group="global" params="$image"}
{{endif}}
</div>
{advertisement="ad_image_lightbox"}
<div class='cGalleryExif i-background_2 i-padding_3'>
{{if \count($image->metadata)}}
{{if isset( $image->metadata['EXIF.FocalLength'] ) || ( isset( $image->metadata['IFD0.Make'] ) AND isset( $image->metadata['IFD0.Model'] ) ) || isset( $image->metadata['EXIF.ShutterSpeedValue'] ) || isset( $image->metadata['COMPUTED.ApertureFNumber'] ) || isset( $image->metadata['Exif.Photo.ISOSpeed'] )}}
<h3 class='i-font-size_-2'>
{{if isset( $image->metadata['IFD0.Make'] ) AND isset( $image->metadata['IFD0.Model'] )}}
<strong>{lang="gallery_exif_camera"} {{if mb_strpos( $image->metadata['IFD0.Model'], $image->metadata['IFD0.Make'] ) !== 0}}{$image->metadata['IFD0.Make']}{{endif}} {$image->metadata['IFD0.Model']}</strong>
{{else}}
<strong>{lang="camera_information"}</strong>
{{endif}}
</h3>
<ul class='ipsList ipsList--inline cGalleryExif_data'>
{{if isset( $image->metadata['EXIF.FocalLength'] )}}
<li data-ipsTooltip title='{lang="EXIF.FocalLength"}'>
<span><i class='fa-solid fa-arrows-left-right'></i></span>
{$image->focallength}
</li>
{{endif}}
{{if isset( $image->metadata['EXIF.ExposureTime'] )}}
<li data-ipsTooltip title='{lang="EXIF.ExposureTime"}'>
<span><i class='fa-regular fa-clock'></i></span>
{$image->metadata['EXIF.ExposureTime']}
</li>
{{endif}}
{{if isset( $image->metadata['COMPUTED.ApertureFNumber'] )}}
<li data-ipsTooltip title='{lang="COMPUTED.ApertureFNumber"}'>
<span class='cGalleryExif_f'>f</span>
{$image->metadata['COMPUTED.ApertureFNumber']}
</li>
{{endif}}
{{if isset( $image->metadata['Exif.Photo.ISOSpeed'] ) || isset( $image->metadata['EXIF.ISOSpeedRatings'] )}}
<li data-ipsTooltip title='{lang="gallery_exif_isospeed"}'>
<span class='cGalleryExif_iso'>{lang="gallery_exif_iso"}</span>
{{if isset( $image->metadata['Exit.Photo.ISOSpeed'] )}}
{$image->metadata['Exif.Photo.ISOSpeed']}
{{else}}
{{if \is_array( $image->metadata['EXIF.ISOSpeedRatings'] )}}
{expression="implode( '/', $image->metadata['EXIF.ISOSpeedRatings'] )"}
{{else}}
{$image->metadata['EXIF.ISOSpeedRatings']}
{{endif}}
{{endif}}
</li>
{{endif}}
</ul>
<a href='{$image->url( 'metadata' )}' data-ipsDialog data-ipsDialog-fixed="true" data-ipsDialog-title='{lang="view_all_photo_info"}' class='i-font-size_-2'>{lang="view_all_photo_info"}</a>
{{else}}
<a href='{$image->url( 'metadata' )}' data-ipsDialog data-ipsDialog-fixed="true" data-ipsDialog-title='{lang="view_all_photo_info"}' class='i-font-size_-2'>{lang="view_photo_info"}</a>
{{endif}}
{{endif}}
{{if \IPS\GeoLocation::enabled() AND $image->gps_show}}
<div class='i-margin-top_2'>
{$image->map( 400, 100 )|raw}
<div class='i-font-size_-2 i-margin-top_2'>
{$image->loc_short}
{{if $image->canEdit() }}
<button type="button" id="elMapLightboxForm" popovertarget="elMapLightboxForm_menu">{lang="map_privacy"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elMapLightboxForm_menu">
<div class="iDropdown">
<div class='i-padding_3'>
{$image->enableMapForm( TRUE )|raw}
</div>
</div>
</i-dropdown>
{{endif}}
</div>
</div>
{{elseif $image->canEdit() AND \IPS\GeoLocation::enabled() AND $image->gps_raw}}
<div class='i-margin-top_2'>
<div class='i-opacity_4'>
{$image->map( 400, 100 )|raw}
<div class='i-font-size_-2 i-margin-top_2'>
{$image->loc_short}
</div>
</div>
<div class='i-font-size_-2 i-margin-top_3'>
<strong>{lang="map_not_being_shown"}</strong>
<button type="button" id="elMapLightboxForm" popovertarget="elMapLightboxForm_menu">{lang="map_privacy"} <i class='fa-solid fa-caret-down'></i></button>
<i-dropdown popover id="elMapLightboxForm_menu">
<div class="iDropdown">
<div class='i-padding_3'>
{$image->enableMapForm( TRUE )|raw}
</div>
</div>
</i-dropdown>
</div>
</div>
{{endif}}
</div>
<div data-role='imageComments' data-commentsContainer="lightbox">
{{if $commentsAndReviews}}
{{if ( $image->directContainer()->allow_reviews && $image->container()->allow_reviews ) && ( $image->directContainer()->allow_comments && $image->container()->allow_comments ) }}
<a id="replies"></a>
<h2 class='ipsHide'>{lang="user_feedback"}</h2>
{{endif}}
{$commentsAndReviews|raw}
{{endif}}
</div>
</div>]]></template>
<template template_group="view" template_name="metadata" template_data="$image" template_location="front" template_app="gallery"><![CDATA[{template="pageHeader" if="!\IPS\Request::i()->isAjax()" group="global" app="core" params="\IPS\Member::loggedIn()->language()->addToStack('gallery_metadata', FALSE, array( 'sprintf' => array( $image->caption ) ) )"}
<div class='i-padding_2'>
{{if \count( $image->metadata )}}
<ol class='ipsList ipsList--border ipsList--label-value'>
{{foreach $image->metadata as $key => $value}}
{{if !\is_array( $value ) AND ( $image->gps_show OR mb_strpos( $key, 'GPS.' ) === FALSE ) AND ( mb_strpos( $key, 'UndefinedTag' ) === FALSE OR \IPS\Member::loggedIn()->language()->checkKeyExists( $key ) ) AND ( !\IPS\Member::loggedIn()->language()->checkKeyExists( $key ) OR ( \IPS\Member::loggedIn()->language()->checkKeyExists( $key ) AND \IPS\Member::loggedIn()->language()->get( $key ) ) )}}
<li>
<strong class='ipsList__label'>{lang="$key"}</strong>
<span class='ipsList__value'>{{if \IPS\Member::loggedIn()->language()->checkKeyExists( $key . '_map_' . $value )}}{lang="{$key}_map_{$value}"}{{else}}{$value}{{endif}}</span>
</li>
{{endif}}
{{endforeach}}
</ol>
{{else}}
<p class='ipsEmptyMessage'>{lang="gallery_no_metadata"}</p>
{{endif}}
</div>]]></template>
<template template_group="view" template_name="reviews" template_data="$image" template_location="front" template_app="gallery"><![CDATA[<div data-controller='core.front.core.commentFeed' {{if settings.auto_polling_enabled}}data-autoPoll{{endif}} data-commentsType='reviews' data-baseURL='{$image->url()}' {{if $image->isLastPage('reviews')}}data-lastPage{{endif}} data-feedID='{$image->reviewFeedId}' id='reviews' class="ipsEntries ipsEntries--reviews ipsEntries--gallery-reviews" data-follow-area-id="image-{$image->id}">
{{if \count( $image->reviews( NULL, NULL, NULL, 'desc', NULL, NULL, NULL, NULL, isset( \IPS\Request::i()->showDeleted ) ) )}}
<div class='ipsButtonBar ipsButtonBar--top'>
{{if $image->reviewPageCount() > 1}}
<div class='ipsButtonBar__pagination'>{$image->reviewPagination( array( 'tab', 'sort' ) )|raw}</div>
{{endif}}
<div class='ipsButtonBar__end'>
<ul class="ipsDataFilters">
<li data-action="tableFilter">
<a href="{$image->url()->setQueryString( array( 'tab' => 'reviews', 'sort' => 'helpful' ) )->setPage('page',1)}" class="ipsDataFilters__button {{if !isset( request.sort ) or request.sort != 'newest'}}ipsDataFilters__button--active{{endif}}" data-action="filterClick">{lang="most_helpful"}</a>
</li>
<li data-action="tableFilter">
<a href="{$image->url()->setQueryString( array( 'tab' => 'reviews', 'sort' => 'newest' ) )->setPage('page',1)}" class="ipsDataFilters__button {{if isset( request.sort ) and request.sort == 'newest'}}ipsDataFilters__button--active{{endif}}" data-action="filterClick">{lang="newest"}</a>
</li>
</ul>
{template="commentMultimodHeader" app="core" group="global" params="$image, '#reviews', 'review'"}
</div>
</div>
<div data-role='commentFeed' data-controller='core.front.core.moderation'>
<form action="{$image->url()->csrf()->setQueryString( 'do', 'multimodReview' )->setPage('page',\IPS\Request::i()->page)}" method="post" data-ipsPageAction data-role='moderationTools'>
{{$reviewCount=0; $timeLastRead = $image->timeLastRead(); $lined = FALSE;}}
{{foreach $image->reviews( NULL, NULL, NULL, 'desc', NULL, NULL, NULL, NULL, isset( \IPS\Request::i()->showDeleted ) ) as $review}}
{{if !$lined and $timeLastRead and $timeLastRead->getTimestamp() < $review->mapped('date')}}
{{if $lined = TRUE and $reviewCount}}
<hr class="ipsUnreadBar">
{{endif}}
{{endif}}
{{$reviewCount++;}}
{$review->html()|raw}
{{endforeach}}
{template="commentMultimod" app="core" group="global" params="$image, 'review'"}
</form>
</div>
{{if $image->reviewPageCount() > 1}}
<div class='ipsButtonBar ipsButtonBar--bottom'>
<div class='ipsButtonBar__pagination'>{$image->reviewPagination( array( 'tab', 'sort' ) )|raw}</div>
</div>
{{endif}}
{{elseif !$image->canReview()}}
<div class='ipsBox__padding'>
<p class='ipsEmptyMessage' data-role='noReviews'>{lang="no_reviews"}</p>
</div>
{{endif}}
<div class="ipsComposeAreaWrapper">
{{if $image->reviewForm()}}
{{if $image->locked()}}
<strong class='i-color_warning'><i class='fa-solid fa-circle-info'></i> {lang="item_locked_can_review"}</strong>
{{endif}}
{$image->reviewForm()|raw}
{{else}}
{{if $image->hasReviewed()}}
<!-- Already reviewed -->
{{elseif $image->locked()}}
{template="commentUnavailable" group="forms" location="front" app="gallery" params="'item_locked_cannot_review'"}
{{elseif \IPS\Member::loggedin()->restrict_post}}
{{if \IPS\Member::loggedIn()->restrict_post == -1}}
{template="reviewUnavailable" group="forms" location="front" app="gallery" params="'restricted_cannot_comment'"}
{{else}}
{template="reviewUnavailable" group="forms" location="front" app="gallery" params="'restricted_cannot_comment', \IPS\Member::loggedIn()->warnings(5,NULL,'rpa'), \IPS\Member::loggedIn()->restrict_post"}
{{endif}}
{{elseif \IPS\Member::loggedIn()->members_bitoptions['unacknowledged_warnings']}}
{template="reviewUnavailable" group="forms" location="front" app="gallery" params="'unacknowledged_warning_cannot_post', \IPS\Member::loggedIn()->warnings( 1, FALSE )"}
{{endif}}
{{endif}}
</div>
</div>]]></template>
<template template_group="view" template_name="rssContent" template_data="$image" template_location="front" template_app="gallery"><![CDATA[{$image->description|raw}
<p>
<a href='{$image->url()}' title='{$image->caption}'><img src='{file="$image->masked_file_name" extension="gallery_Images"}' title="{$image->caption}" alt="{$image->caption}"></a>
</p>]]></template>
<template template_group="widgets" template_name="albums" template_data="$albums, $title, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[{{if !empty( $albums ) }}
<header class='ipsWidget__header'>
<h3>{$title}</h3>
{{if $isCarousel}}
{{$carouselID = 'widget-gallery-albums_' . mt_rand();}}
{template="carouselNavigation" group="global" app="core" params="$carouselID"}
{{endif}}
</header>
<div class='ipsWidget__content'>
<i-data>
<ul class="ipsData ipsData--{$layout} {{if $isCarousel}}ipsData--carousel{{endif}} ipsData--widget-gallery-albums" {{if $isCarousel}}id='{$carouselID}' tabindex="0"{{endif}}>
{{foreach $albums as $album}}
<li class='ipsData__item {$album->ui('css')}' {$album->ui("dataAttributes")}>
<a href='{$album->url()}' class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$album->name}</span></a>
<div class="ipsData__image" aria-hidden="true">
{{if $album->asNode()->coverPhoto('masked')}}
<img src="{$album->asNode()->coverPhoto('masked')}" alt="" loading="lazy">
{{else}}
<i></i>
{{endif}}
</div>
<div class="ipsData__content">
<div class='ipsData__main'>
<h2 class='ipsData__title'><a href='{$album->url()}'>{$album->name}</a></h2>
{{if \in_array( $layout, array("table", "grid", "featured"))}}
<div class="ipsData__desc ipsRichText">{$album->description|raw}</div>
{{endif}}
</div>
<div class="ipsData__extra">
<ul class='ipsData__stats'>
<li data-statType='images'>
<span class='ipsData__stats-icon' data-stat-value="{$album->count_imgs}" aria-hidden="true" data-ipstooltip title='{lang="cat_img_count" pluralize="$album->count_imgs"}'></span>
<span class='ipsData__stats-label'>{lang="cat_img_count" pluralize="$album->count_imgs"}</span>
</li>
{{if $album->use_comments && $album->comments > 0}}
<li data-statType='album_comments'>
<span class='ipsData__stats-icon' data-stat-value="{$album->comments}" aria-hidden="true" data-ipstooltip title='{lang="num_comments" pluralize="$album->comments"}'></span>
<span class='ipsData__stats-label'>{lang="num_comments" pluralize="$album->comments"}</span>
</li>
{{endif}}
{{if $album->allow_comments && $album->count_comments > 0}}
<li data-statType='image_comments'>
<span class='ipsData__stats-icon' data-stat-value="{$album->count_comments}" aria-hidden="true" data-ipstooltip title='{lang="gallery_image_comments_s" pluralize="$album->count_comments"}'></span>
<span class='ipsData__stats-label'>{lang="gallery_image_comments_s" pluralize="$album->count_comments"}</span>
</li>
{{endif}}
</ul>
<div class="ipsData__last">
<div class="ipsData__last-text">
<div class="ipsData__last-primary">{lang="byline" sprintf="$album->author()->name"}</div>
{{if $album->count_imgs and $album->mapped( 'updated' )}}
<div class="ipsData__last-secondary">{datetime="$album->mapped('updated')"}</div>
{{endif}}
</div>
</div>
</div>
</div>
</li>
{{endforeach}}
</ul>
</i-data>
</div>
{{endif}}]]></template>
<template template_group="widgets" template_name="galleryStats" template_data="$stats, $latestImage, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[<h3 class='ipsWidget__header'>{lang="block_galleryStats"}</h3>
<div class='ipsWidget__content'>
<ul class='ipsList ipsList--stats ipsList--stacked ipsList--border ipsList--fill'>
<li>
<strong class='ipsList__label'>{lang="total_images_front_v" pluralize="$stats['totalImages']"}</strong>
<span class='ipsList__value'>{number="$stats['totalImages']" format="short"}</span>
</li>
{{if $stats['totalComments']}}
<li>
<strong class='ipsList__label'>{lang="stats_total_comments_v" pluralize="$stats['totalComments']"}</strong>
<span class='ipsList__value'>{number="$stats['totalComments']" format="short"}</span>
</li>
{{endif}}
{{if $stats['totalAlbums']}}
<li>
<strong class='ipsList__label'>{lang="total_albums_v" pluralize="$stats['totalAlbums']"}</strong>
<span class='ipsList__value'>{number="$stats['totalAlbums']" format="short"}</span>
</li>
{{endif}}
</ul>
{{if isset($orientation) and $orientation == 'vertical' && $latestImage}}
<hr class='ipsHr ipsHr--none'>
<div class='i-padding_1'>{template="latestImage" group="widgets" app="gallery" params="$latestImage"}</div>
{{endif}}
</div>]]></template>
<template template_group="widgets" template_name="imageFeed" template_data="$images, $title, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[{{if !empty( $images ) }}
<header class='ipsWidget__header'>
<h3>{$title}</h3>
{{if $isCarousel}}
{{$carouselID = 'widget-gallery-image-feed_' . mt_rand();}}
{template="carouselNavigation" group="global" app="core" params="$carouselID"}
{{endif}}
</header>
<div class='ipsWidget__content' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<i-data>
<ul class="ipsData ipsData--{$layout} {{if $isCarousel}}ipsData--carousel{{endif}} ipsData--widget-gallery-image-feed" {{if $isCarousel}}id='{$carouselID}' tabindex="0"{{endif}}>
{{foreach $images as $idx => $image}}
{template="imageRow" group="widgets" app="gallery" params="$image"}
{{endforeach}}
</ul>
</i-data>
</div>
{{endif}}]]></template>
<template template_group="widgets" template_name="imageRow" template_data="$image, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[<li class="ipsData__item {$image->ui('css')}" {$image->ui('dataAttributes')}>
<a href="{$image->url()}" class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$image->caption}</span></a>
<div class="ipsData__image" aria-hidden="true" data-ips-hook='image'>
{{if $image->small_file_name}}
<img src='{file="$image->small_file_name" extension="gallery_Images"}' alt="" loading="lazy">
{{else}}
<i></i>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$image, FALSE"}
</div>
<div class="ipsData__content">
<div class="ipsData__main">
<h4 class="ipsData__title" data-ips-hook='title'>
<a href="{$image->url()}" title='{lang="view_this_image" sprintf="$image->caption"}'>{$image->caption}</a>
</h4>
<p class="ipsData__meta">{lang="byline" htmlsprintf="$image->author()->link()"} &middot; {datetime="$image->mapped('date')"}</p>
<div class="ipsData__desc">
{{if $image->description}}
{$image->content()|raw}
{{endif}}
</div>
</div>
<div class="ipsData__extra">
<div class="ipsData__last ipsData__last--author" data-ips-hook="latestAuthorPhoto">
{template="userPhoto" app="core" group="global" params="$image->author(), 'fluid'"}
<div class="ipsData__last-text">
<div class="ipsData__last-primary">
{$image->author()->link( NULL, NULL, $image->isAnonymous() )|raw}
</div>
<div class="ipsData__last-secondary">
<a href='{$image->url( 'getLastComment' )}' title='{lang="get_last_post"}'>
{datetime="$image->mapped('date')"}
</a>
</div>
</div>
</div>
<div class="ipsData__last" data-ips-hook="latestUserPhoto">
{{if $image->mapped('num_comments')}}
{template="userPhoto" app="core" group="global" params="$image->lastCommenter(), 'fluid'"}
{{else}}
{template="userPhoto" app="core" group="global" params="$image->author(), 'fluid'"}
{{endif}}
<div class="ipsData__last-text">
<div class="ipsData__last-primary">
{{if $image->mapped('num_comments')}}
{$image->lastCommenter()->link()|raw}
{{else}}
{$image->author()->link( NULL, NULL, $image->isAnonymous() )|raw}
{{endif}}
</div>
<div class="ipsData__last-secondary">
<a href='{$image->url( 'getLastComment' )}' title='{lang="get_last_post"}'>
{{if $image->mapped('last_comment')}}{datetime="$image->mapped('last_comment')"}{{else}}{datetime="$image->mapped('date')"}{{endif}}
</a>
</div>
</div>
</div>
<ul class='ipsData__stats' data-ips-hook='stats'>
{{if $image->directContainer()->allow_comments}}
<li data-statType='comments' {{if !$image->comments}}data-v="0"{{endif}}>
<span class='ipsData__stats-icon' data-stat-value="{number='$image->comments'}" aria-hidden="true" data-ipstooltip title='{number="$image->comments" format="short"} {lang="comments" pluralize="$image->comments"}'></span>
<span class='ipsData__stats-label'>{number="$image->comments"} {lang="comments" pluralize="$image->comments"}</span>
</li>
{{endif}}
<li data-statType='views'>
<span class='ipsData__stats-icon' data-stat-value="{number='$image->views'}" aria-hidden="true" data-ipstooltip title='{number="$image->views" format="short"} {lang="num_views" pluralize="$image->views"}'></span>
<span class='ipsData__stats-label'>{number="$image->views"} {lang="num_views" pluralize="$image->views"}</span>
</li>
</ul>
</div>
</div>
</li>]]></template>
<template template_group="widgets" template_name="latestImage" template_data="$latestImage, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[<div id='elGalleryStatsLatest' class='cGalleryWidget' {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
<h6 class='ipsTitle ipsTitle--h6 ipsTitle--padding'>{lang="latest_image"}</h6>
<figure class='ipsFigure'>
<a href='{$latestImage->url()}' title='{lang="view_this_image" sprintf="$latestImage->caption"}' class='ipsFigure__main'>
{{if $latestImage->small_file_name}}
<img src='{file="$latestImage->small_file_name" extension="gallery_Images"}' alt="{$latestImage->caption}" loading="lazy">
{{else}}
<i class="ipsFigure__icon"></i>
{{endif}}
</a>
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$latestImage"}
<figcaption class='ipsFigure__footer'>
<div class='ipsFigure__title'>
<a href="{$latestImage->url()}" title='{lang="view_this_image" sprintf="$latestImage->caption"}'>
{$latestImage->caption}
</a>
</div>
<div class="i-flex i-justify-content_space-between">
<div>{lang="byline_name_date" htmlsprintf="$latestImage->author()->link(), \IPS\DateTime::ts( $latestImage->mapped('date') )->html(TRUE)"}</div>
{{if $latestImage->directContainer()->allow_comments && $latestImage->comments > 0}}
<div data-ipsTooltip title='{lang="num_comments" pluralize="$latestImage->comments"}'>
<i class='fa-solid fa-comment'></i> {$latestImage->comments}
</div>
{{endif}}
</div>
</figcaption>
</figure>
</div>
]]></template>
<template template_group="widgets" template_name="recentComments" template_data="$comments, $title, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[{{if !empty( $comments ) }}
<header class='ipsWidget__header'>
<h3>{$title}</h3>
{{if $isCarousel}}
{{$carouselID = 'widget-gallery-recent-comments_' . mt_rand();}}
{template="carouselNavigation" group="global" app="core" params="$carouselID"}
{{endif}}
</header>
<div class='ipsWidget__content'>
<i-data>
<ul class='ipsData ipsData--{$layout} {{if $isCarousel}}ipsData--carousel{{endif}} ipsData--widget-gallery-recent-comments' {{if $isCarousel}}id='{$carouselID}' tabindex="0"{{endif}} {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $comments as $comment}}
<li class='ipsData__item {$comment->ui('css')}' {$comment->ui('dataAttributes')}>
<a href="{$comment->url()}" class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$comment->item()->caption}</span></a>
<div class="ipsData__image" aria-hidden="true">
{{if $comment->item()->masked_file_name}}
<img src='{file="$comment->item()->masked_file_name" extension="gallery_Images"}' loading="lazy" alt=''>
{{else}}
<i></i>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$comment->item(), FALSE"}
</div>
<div class="ipsData__content">
<div class='ipsData__main'>
<h4 class='ipsData__title'><a href="{$comment->url()}" title='{lang="view_this_image" sprintf="$comment->item()->caption"}'>{$comment->item()->caption}</a></h4>
<div class='ipsData__desc'>{$comment->truncated()|raw}</div>
</div>
<div class="ipsData__last">
<div class="ipsData__last-text">
<div class="ipsData__last-primary">{lang="byline_nodate" htmlsprintf="$comment->author()->link()"}</div>
<div class="ipsData__last-secondary"><a href="{$comment->url()}">{$comment->dateLine()|raw}</a></div>
</div>
</div>
</div>
</li>
{{endforeach}}
</ul>
</i-data>
</div>
{{endif}}]]></template>
<template template_group="widgets" template_name="recentImageReviews" template_data="$comments, $title, $layout='table', $isCarousel=false" template_location="front" template_app="gallery"><![CDATA[{{if !empty( $comments ) }}
<header class='ipsWidget__header'>
<h3>{$title}</h3>
{{if $isCarousel}}
{{$carouselID = 'widget-gallery-recent-reviews_' . mt_rand();}}
{template="carouselNavigation" group="global" app="core" params="$carouselID"}
{{endif}}
</header>
<div class='ipsWidget__content'>
<i-data>
<ul class='ipsData ipsData--{$layout} {{if $isCarousel}}ipsData--carousel{{endif}} ipsData--widget-gallery-recent-reviews' {{if $isCarousel}}id='{$carouselID}' tabindex="0"{{endif}} {{if settings.gallery_nsfw}}data-controller="gallery.front.global.nsfw"{{endif}}>
{{foreach $comments as $comment}}
<li class='ipsData__item {$comment->ui('css')}' {$comment->ui('dataAttributes')}>
<a href="{$comment->url()}" class="ipsLinkPanel" aria-hidden="true" tabindex="-1"><span>{$comment->item()->caption}</span></a>
<div class="ipsData__image" aria-hidden="true">
{{if $comment->item()->masked_file_name}}
<img src='{file="$comment->item()->masked_file_name" extension="gallery_Images"}' loading="lazy" alt=''>
{{else}}
<i></i>
{{endif}}
{template="nsfwOverlay" app="gallery" location="front" group="global" params="$comment->item(), FALSE"}
</div>
<div class="ipsData__content">
<div class='ipsData__main'>
<div class='ipsData__title'>
<h4><a href="{$comment->url()}" title='{lang="view_this_image" sprintf="$comment->item()->caption"}'>{$comment->item()->caption}</a></h4>
{template="rating" group="global" location="front" app="core" params="'small', $comment->rating, \IPS\Settings::i()->reviews_rating_out_of"}
</div>
<p class='ipsData__meta'>
{lang="byline_nodate" htmlsprintf="$comment->author()->link()"}
</p>
<div class='ipsData__desc ipsRichText ipsTruncate_4 i-margin-top_2'>
{$comment->truncated()|raw}
</div>
</div>
</div>
</li>
{{endforeach}}
</ul>
</i-data>
</div>
{{endif}}]]></template>
<css css_location="front" css_app="gallery" css_attributes="" css_path="." css_name="embed.css">/* Embedded gallery content */
.ipsFigure--embed-hero .ipsFigure__main{
max-height: 220px;
}
:is(.ipsRichEmbed--gallery-image, .ipsRichEmbed--gallery-image-comment, .ipsRichEmbed--gallery-image-review) .ipsFigure__main{
max-height: 400px;
}
.cGalleryEmbed_albumStrip {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
gap: 5px;
margin-top: .6em;
}
.cGalleryEmbed_albumStrip .ipsFigure{
margin: 0;
}
.cGalleryEmbed_albumStrip:not(.cGalleryEmbed_albumStrip_mini) {
margin: 0;
background: var(--i-background_1);
padding: 5px;
border-radius: var(--i-box--bo-ra);
position: relative;
}
.ipsFigure ~ .cGalleryEmbed_albumStrip:not(.cGalleryEmbed_albumStrip_mini){
margin: -30px 15px 0;
}</css>
<css css_location="front" css_app="gallery" css_attributes="" css_path="." css_name="gallery.css"><![CDATA[/* Featured image carousel */
.ipsCarousel--gallery-featured{
--i-column-gap: 0em;
border-radius: 0 0 var(--i-box--bo-ra) var(--i-box--bo-ra);
}
.ipsCarousel--gallery-featured .ipsFigure{
border-radius: 0;
}
.elGalleryImage {
display: grid;
place-content: center;
position: relative;
}
.cGalleryImageFade {
position: absolute;
bottom: 1em;
inset-inline-end: 1em;
transition: opacity 0.3s ease-in-out;
opacity: 0;
}
.elGalleryImage:hover .cGalleryImageFade,
.elGalleryImage.cGalleryImageHover .cGalleryImageFade {
opacity: 1;
}
.elGalleryImage .ipsNsfwOverlay{
position: absolute;
inset: 0;
color: #fff;
}
.elGalleryImageNav {
position: absolute;
top: 50%;
left: 0;
right: 0;
transform: translateY(-50%);
display: flex;
justify-content: space-between;
pointer-events: none;
}
.elGalleryImageNav a {
color: #fff;
font-size: 60px;
width: 1em;
height: 1em;
display: grid;
place-content: center;
opacity: .4;
transition: all 0.2s ease-in-out;
z-index: 100;
pointer-events: auto;
}
.elGalleryImage:hover .elGalleryImageNav a {
opacity: 1;
background: rgba(0,0,0,0.2);
}
.elGalleryImageNav i{
font-size: .4em;
}
/*
----------------
- Category grid
----------------
*/
/* Show long dates */
:is(.ipsData--gallery-categories, .ipsData--gallery-club-categories) .ipsTime__short{
display: none;
}
:is(.ipsData--gallery-categories, .ipsData--gallery-club-categories) .ipsTime__long{
display: revert;
}
/*
----------------
- Image view: thumbnail carousel
----------------
*/
.cGalleryImageThumbs{
position: relative;
background-color: oklch(25% calc(clamp(0, 100 - var(--i-base-c), 1) * 5%) var(--i-base-h));
box-shadow: inset hsl(0 0% 100% / .1) 0px 1px 0px;
border-radius: 0 0 var(--i-box--bo-ra) var(--i-box--bo-ra);
}
@media (max-width: 767px){
.cGalleryImageThumbs{
border-radius: 0;
}
}
/* ALBUM LIST IN A CATEGORY */
.cGalleryAlbums > li:not( :last-child ) {
margin-bottom: 7px;
}
/* IMAGE VIEW PAGE */
.cGalleryViewImage {
/* display: grid;
place-items: center; */
position: relative;
}
.cGalleryViewImage img[data-role="theImage"],
#elGalleryVideo {
margin: auto;
position: relative;
width: auto;
height: auto;
max-width: 100%;
max-height: 100%;
}
.cGalleryViewImage [data-ipslightbox]{
display: grid;
/* place-items: center; */
cursor: zoom-in;
height: clamp(300px, 60vh, 800px);
}
.cGalleryViewImage_controls {
margin-inline-start: auto;
}
/* NOTES */
.cGalleryViewImage:hover .cGalleryNote {
opacity: 1;
}
.cGalleryNote {
position: absolute;
opacity: 0;
}
.cGalleryNote_border {
border: 1px solid #000;
height: 100%;
background: rgba(255,255,255,0.0001);
}
.cGalleryNote_border::after {
content: '';
position: absolute;
inset: 1px;
display: block;
border: 1px solid #ccc;
}
.cGalleryNote_editing .cGalleryNote_border,
.cGalleryNote_editing .cGalleryNote_border::after {
border-style: dashed;
opacity: 1;
}
.cGalleryNote_editing {
opacity: 1 !important;
}
.cGalleryNote_editing .cGalleryNote_note {
opacity: 1 !important;
display: block !important;
width: 280px;
padding: 12px;
pointer-events: auto;
z-index: 1000;
}
.cGalleryNote_editing .cGalleryNote_note a {
color: #fff;
}
.cGalleryNote_editing .cGalleryNote_note textarea {
outline: 1px solid currentColor;
outline-offset: 0px;
padding: 1em;
}
.cGalleryNote_note {
width: max-content;
max-width: 250px;
position: absolute;
top: calc(100% + 5px);
left: 50%;
transform: translateX(-50%);
background: hsl(0 0% 0% / .6);
-webkit-backdrop-filter: blur(6px);
backdrop-filter: blur(6px);
color: #fff;
font-weight: 600;
font-size: .9em;
border-radius: 5px;
pointer-events: none;
padding: 10px;
}
.cGalleryNote_delete {
position: absolute;
top: -10px;
inset-inline-end: -10px;
width: 1.5em;
height: 1.5em;
display: grid;
place-content: center;
border-radius: 50%;
background: #000;
border: 1px solid currentColor;
color: #fff;
font-size: 17px;
}
/* jQuery resizable styles */
.ui-resizable-handle { position: absolute; font-size: 0.1px; display: block; }
.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
.ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0; }
.ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0; }
.ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%; }
.ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%; }
.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px; }
.ui-icon-gripsmall-diagonal-se {
background: url( "{resource="resizable.png" inCss="true" app="core" location="global" inCss="true"}" );
}
.ui-draggable { cursor: move;}
.cGallerySearchAlbumThumbs,
.cGalleryManagedAlbumThumbs {
display: grid;
gap: 4px;
grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
}
/* Restrict thumbs in Activity Stream to 20 */
.cGallerySearchAlbumThumbs li:nth-child(20) ~ *{
display: none;
}
.cGalleryManagedAlbumThumbs{
margin-top: 10px;
}
.cGalleryAlbums_recent {
--_thumb: 100px;
--_gap: 4px;
padding-inline-start: calc(var(--_thumb) * 2 + var(--_gap));
display: grid;
grid-template-columns: repeat(auto-fill, minmax(var(--_thumb), 1fr));
gap: var(--_gap);
height: calc(var(--_thumb) * 2 + var(--_gap));
position: relative;
overflow: hidden;
}
.cGalleryAlbums_recent > li {
height: var(--_thumb);
position: relative;
}
.cGalleryAlbums_recent .ipsFigure{
height: 100%;
}
.cGalleryAlbums_recent .ipsFigure__footer{
justify-self: end;
padding: .5em;
}
.cGalleryAlbums_recent .ipsFigure__footer::before{
display: none;
}
.cGalleryAlbums_recent > li:first-child {
width: calc(var(--_thumb) * 2);
height: calc(var(--_thumb) * 2);
overflow: hidden;
position: absolute;
inset-inline-start: 0;
}
.cGalleryAlbums_recent--small {
--_thumb: 40px;
}
/* Restyle the above for the sidebar */
.ipsWidget--vertical .cGalleryAlbums_recent{
padding: 0;
height: auto;
grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
}
.ipsWidget--vertical .cGalleryAlbums_recent > li:first-child{
width: auto;
height: auto;
position: static;
}
.ipsWidget--vertical .cGalleryAlbums_recent > li{ height: auto; }
/* Since results are unlimited, display a maximum of 12 using css */
.ipsWidget--vertical .cGalleryAlbums_recent > li:nth-child(12) ~ li{
display: none;
}
.ipsWidget--vertical .cGalleryAlbums_recent .ipsFigure__main {
aspect-ratio: 1;
}
/* General style which creates the square thumb container */
.cGalleryThumb {
max-width: 170px;
max-height: 170px;
}
.cGalleryAlbumThumb {
width: 280px;
height: 235px;
}
@media screen and (max-width: 767px) {
.ipsApp .cGalleryAlbums_recent {
margin-bottom: 3px;
}
.cGalleryAlbums_recent {
--_thumb: 40px;
}
.cGalleryAlbums_recent + .ipsList {
padding-inline-start: 4px;
}
}
/* v5 code */
/* Feature image on index */
.ipsCarousel--gallery-featured{
height: clamp(480px, 80vh, 610px);
}
/* Larger icons for album list view */
.ipsData--gallery-row-list{
--i-data--icon-width: 80px;
}
/* Faded masonry for Album listing */
.ipsMasonry--album-summary{
max-height: 300px;
overflow: hidden;
mask-image: linear-gradient(to bottom, hsl(0 0% 0%) 200px, hsl(0 0% 0% / 0));
}
/* Image view */
.elGalleryHeader {
position: relative;
z-index: 1; /* Ensure notes overlap the navigation strip */
background-color: oklch(25% calc(clamp(0, 100 - var(--i-base-c), 1) * 5%) var(--i-base-h));
border-radius: var(--i-box--bo-ra) var(--i-box--bo-ra) 0 0;
color: hsl(0 0% 100%);
}
.ipsCarousel--gallery-image-thumbs{
--i-carousel--pa: 2em 1.5em;
--_height: 100px;
gap: 1.5em;
}
.ipsCarousel--gallery-image-thumbs > :first-child{
margin-inline-start: auto;
}
.ipsCarousel--gallery-image-thumbs > :last-child{
margin-inline-end: auto;
}
.ipsCarousel--gallery-image-thumbs [data-active] .ipsFigure{
outline: 1px solid currentColor;
outline-offset: 3px;
}]]></css>
<css css_location="front" css_app="gallery" css_attributes="" css_path="." css_name="profile.css"><![CDATA[/* Styles used to display albums in profiles */
.cProfileAlbum {
position: relative;
z-index: 1;
}
.cProfileAlbum > div {
width: 100%;
height: 100%;
margin: 0 auto;
border: 1px solid var(--i-background_3);
}
.cProfileAlbum_image {
display: block;
position: relative;
max-width: 100%;
height: 100%;
background-color: var(--i-background_dark);
background-size: cover;
background-position: 50%;
background-repeat: no-repeat;
overflow: hidden;
}
.cProfileAlbum_image img {
display: none;
}
.cProfileAlbum .ipsTitle {
font-size: var(--i-font-size_1);
text-align: start;
display: block;
padding: 7px;
overflow: hidden;
text-overflow: ellipsis;
top: 0px;
background: rgba(0,0,0,0.5);
color: #fff;
}
]]></css>
<css css_location="front" css_app="gallery" css_attributes="" css_path="." css_name="submit.css"><![CDATA[.cGalleryDialog {
display: flex;
flex-direction: column;
position: relative;
/* min-height: min(550px, 90svh); */
}
.cGalleryDialog_inner{
flex: 1 1 auto;
display: flex;
}
.cGalleryDialog_primary{
flex: 999 1 60%;
display: flex;
flex-direction: column;
}
.cGalleryDialog_title{
flex: 0 0 auto;
padding: var(--i-sp_3);
display: flex;
align-items: center;
justify-content: space-between;
}
.cGalleryDialog_imageFormAlign{
height: 100%;
display: flex;
flex-direction: column;
}
#elGallerySubmit_toolBar{
padding: 1em;
background: var(--i-background_3);
flex: 0 0 auto;
position: sticky;
top: 0;
z-index: 2;
}
.cGallerySubmit_imageDetails {
flex: 1 1 400px;
overflow: auto;
background: var(--i-background_2);
}
.cGalleryDialog:not(.cGalleryDialog_uploadStep) .cGallerySubmit_imageDetails {
display: none;
}
.cGallerySubmit_imageDetails .ipsAttachment_dropZone [data-action="uploadFile"] {
margin: 0 0 10px 0;
width: 100%;
}
.cGallerySubmit_imageDetails .ipsAttachment_dropZone.ipsAttachment_dropZoneSmall {
padding: 5px;
}
.cGallerySubmit_imageDetails .ipsSubmitRow{
position: -webkit-sticky;
position: sticky;
bottom: 0;
}
.cGallerySubmit_preview {
height: 190px;
aspect-ratio: auto;
text-align: center;
}
.cGallerySubmit_preview .ipsThumb img{
object-fit: contain;
}
.cGalleryDialog .ipsDialog_title {
padding: 0;
}
.cGalleryDialog_close {
font-size: 40px;
line-height: 1;
display: none; /* Hide the close icon if the form is viewed via /submit/ instead of a dialog */
}
.ipsDialog_content .cGalleryDialog_close {
/* display: block; */
}
#elFileTypes_menu strong {
display: none;
}
/* Step 1: Choose album */
.ipsDialog .cGalleryChooseAlbum_wrap{
display: contents;
}
.cGalleryChooseAlbum_list {
flex: 1 1 auto;
display: flex;
justify-content: center;
align-items: center;
padding: 0 2em 2em 2em;
}
.cGalleryChooseAlbum_list > ul {
width: min(100% - 30px, 450px);
}
.cGalleryChooseAlbum_listItem {
display: block;
background: var(--i-background_2);
padding: 1.4em;
padding-inline-end: 40px;
margin-bottom: 1em;
border-radius: 6px;
position: relative;
}
.cGalleryChooseAlbum_listItem[data-disabled] {
opacity: .7;
cursor: not-allowed;
}
.cGalleryChooseAlbum_listItem[data-disabled] .ipsTitle {
color: var(--i-color_soft);
}
.cGalleryChooseAlbum_listItem:not([data-disabled])::after {
font-family: var(--i-font-awesome);
-webkit-font-smoothing: antialiased;
text-rendering: auto;
font-weight: 900;
content: '\f061';
position: absolute;
inset-inline-end: 1.2em;
top: 50%;
font-size: 1.4em;
transform: translateY(-50%);
color: var(--i-color_soft);
}
.cGalleryChooseAlbum_listItem:not([data-disabled]):hover {
background: var(--i-background_3);
}
.cGalleryChooseAlbum_listItem .ipsTitle {
font-size: var(--i-font-size_2);
}
/* Dialog: Choose Category */
.cGallerySubmit_albumChoice {
padding: 5em 1em;
}
.cGallerySubmit_albumChoice .ipsSelectTree {
margin: auto;
}
/* Dialog: Choose Existing Album */
#elGallerySubmit_albumChooser{
max-height: 60vh;
display: flex;
flex-direction: column;
gap: 1em;
padding: 0 2em 2em 2em;
}
#elGallerySubmit_albumChooser > li{
position: relative;
flex: 0 0 auto;
}
#elGallerySubmit_albumChooser [type="radio"]{
position: absolute;
opacity: 0;
}
#elGallerySubmit_albumChooser > li > div {
background: var(--i-background_2);
padding: 1.4em;
border-radius: min(var(--i-design-radius), 6px);
}
#elGallerySubmit_albumChooser > li > div:hover {
background: var(--i-background_3);
}
#elGallerySubmit_albumChooser label{
position: absolute;
inset: 0;
cursor: pointer;
}
#elGallerySubmit_albumChooser > li > [type="radio"]:checked + div {
background: var(--i-primary);
color: var(--i-primary-contrast);
}
#elGallerySubmit_albumChooser > li > [type="radio"]:checked + div .i-color_soft {
color: inherit;
opacity: 0.7;
}
/* Choose Existing Album */
[data-role="existingAlbumForm"]{
display: contents;
}
.cGalleryChooseAlbum{
flex: 1 1 100%;
display: flex;
flex-direction: column;
}
.cGalleryDialog_container {
display: contents;
}
.cGalleryDialog_imageForm {
flex: 1 1 auto;
overflow: auto;
}
.cGallerySubmit_uploadImages .ipsAttachment_dropZone:not(.ipsDragging) {
background: var(--i-background_2);
border-color: var(--i-background_3);
}
/* Style the uploader */
.cGallerySubmit_uploadImages .ipsAttachment_dropZone{
display: grid;
place-content: center;
text-align: center;
gap: 0;
}
.cGallerySubmit_uploadImages .ipsUploader__icon {
font-size: 3em;
margin-bottom: 15px;
}
.cGallerySubmit_uploadImages .fa-cloud-upload::before {
content: "\f055";
}
#elGallerySubmit_imageUploader .ipsAttachment_dropZone {
cursor: pointer;
}
.cGalleryDialog_uploadStep .ipsUploader[style*="block"]{
display: flex !important;
gap: var(--i-sp_3);
}
.cGalleryDialog_uploadStep #elGallerySubmit_imageUploader .ipsAttachment_dropZone {
flex: 1 1 200px;
align-self: start;
height: 200px;
margin-bottom: 2em;
}
#elGallerySubmit_imageUploader a[data-action="uploadFile"] {
display: none;
}
#elGallerySubmit_imageUploader .moxie-shim.moxie-shim-html5,
#elGallerySubmit_imageUploader .moxie-shim.moxie-shim-html5 > input[type="file"] {
top: 0 !important;
left: 0 !important;
width: 0.1px !important;
height: 0.1px !important;
}
.cGallerySubmit_uploadImages .ipsAttachment_fileList{
flex: 999 1 50%;
}
/* Media thumbnail upload area */
.cGalleryThumbField .ipsAttachment_dropZoneSmall_info {
margin-inline-start: auto !important;
}
.cGalleryThumbField [data-role="title"] {
width: 150px;
max-width: 150px;
}
.cGallerySubmit_fileList:empty{
display: none !important;
}
.cGallerySubmit_fileList {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
gap: 1em;
padding-bottom: 2em;
}
.cGallerySubmit_fileList .ipsImageAttach {
border: 1px solid var(--i-background_4);
background: var(--i-background_2);
cursor: move;
}
.cGallerySubmit_fileList .ipsImageAttach:hover {
border-color: var(--i-background_6);
}
.cGallerySubmit_fileList .ipsImageAttach_thumb{
aspect-ratio: 1;
}
/* Add move cursor to thumbnail */
.cGallerySubmit_fileList .ipsImageAttach_thumb :is(img, video){
cursor: inherit;
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_activeFile {
border-color: var(--i-primary);
background: var(--i-primary);
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_activeFile :is(.ipsAttach_title, .cGalleryImageAttach_info){
color: var(--i-primary-contrast);
}
.cGalleryImageAttach_info {
padding-inline-end: 30px;
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_imageSaved::before,
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_imageError::before {
width: 28px;
height: 28px;
border-radius: 28px;
line-height: 28px;
color: #fff;
font-family: var(--i-font-awesome);
-webkit-font-smoothing: antialiased;
text-rendering: auto;
font-weight: 900;
font-size: 14px;
position: absolute;
bottom: 1em;
inset-inline-end: 1em;
text-align: center;
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_imageSaved::before {
content: '\f00c';
background: #558B2F;
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_imageError:not(.cGallerySubmit_activeFile) {
border-color: #a72f35;
}
.cGallerySubmit_fileList .ipsImageAttach.cGallerySubmit_imageError::before {
content: '\f071';
background: #a72f35;
}
@media screen and (max-width: 767px) {
/* Image details area on mobile is fixed */
.cGallerySubmit_imageDetails {
position: fixed;
inset: 0;
z-index: 10;
}
}]]></css>
<css css_location="front" css_app="gallery" css_attributes="" css_path="." css_name="widgets.css">.ipsCarousel--gallery-widget-image-feed .ipsFigure__main{
aspect-ratio: 4/3;
}</css>
</theme>