Version 5.0.0 beta 10

This commit is contained in:
Neo committed 2025-12-19 17:53:48 -08:00
1 parent 56979f8ee8
commit 264eeb97e0
325 files changed
+6442 -1849

No files matched your search

+32 -73
View File
@@ -9,9 +9,9 @@
{{endif}}
{{if $album->coverPhoto('masked')}}
<div class='ipsCoverPhoto ipsCoverPhoto--album' hidden>
<div class='ipsCoverPhoto ipsCoverPhoto--album' data-controller='core.global.core.coverPhoto'>
<div class='ipsCoverPhoto__container'>
<img src='{$album->coverPhoto('masked')}' alt="{$album->name}" loading='lazy'>
<img src='{$album->coverPhoto('masked')}' class='ipsCoverPhoto__image' data-action="toggleCoverPhoto" alt="{$album->name}" loading='lazy'>
</div>
</div>
{{endif}}
@@ -20,21 +20,7 @@
<div data-ips-hook="header" class="ipsPageHeader__primary">
<h1 data-ips-hook="title" class="ipsPageHeader__title">
<div data-ips-hook="badges" class="ipsBadges">
{{if $album->asItem()->hidden() === 1}}
<span class="ipsBadge ipsBadge--icon ipsBadge--warning" data-ipsTooltip title='{lang="pending_approval"}'><i class='fa-solid fa-triangle-exclamation'></i></span>
{{elseif $album->asItem()->hidden() === -1}}
<span class="ipsBadge ipsBadge--icon ipsBadge--warning" data-ipsTooltip title='{$album->asItem()->hiddenBlurb()}'><i class='fa-solid fa-eye-slash'></i></span>
{{elseif $album->asItem()->hidden() === -2}}
<span class="ipsBadge ipsBadge--icon ipsBadge--warning" data-ipsTooltip title='{$album->asItem()->deletedBlurb()}'><i class='fa-solid fa-trash'></i></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}}
{{foreach $album->asItem()->badges() as $badge}}{$badge|raw}{{endforeach}}
</div>
{{if $album->asItem()->canEdit()}}
<span data-controller="core.front.core.moderation">{{if $album->asItem()->locked()}}<i class='fa-solid fa-lock'></i> {{endif}}
@@ -98,10 +84,12 @@
</div>
</header>
{{if $album->can('add')}}
{{if $menu = $album->asItem()->menu()}}
<ul class="ipsButtons ipsButtons--main">
<li>{$album->asItem()->menu()|raw}</li>
<li>{$menu|raw}</li>
{{if $album->can( 'add' )}}
{template="categoryButtons" group="browse" params="$album->can('add'), $album->category(), $album"}
{{endif}}
</ul>
{{endif}}
@@ -1615,7 +1603,7 @@
</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 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'
<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"}"
@@ -1624,16 +1612,16 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
<header class='ipsEntry__header'>
<div class='ipsEntry__header-align'>
<div class='ipsPhotoPanel'>
<div class='ipsAvatarStack'>
<div class='ipsAvatarStack' data-ips-hook="galleryCommentUserPhoto">
{template="userPhoto" app="core" group="global" params="$comment->author(), 'fluid', $comment->warningRef()"}
{{if !$comment->isAnonymous() and $comment->author()->canHaveAchievements() and \IPS\core\Achievements\Rank::show() and $rank = $comment->author()->rank()}}
{{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 class='ipsEntry__username'>
<h3>{template="userLink" app="core" group="global" params="$comment->author(), $comment->warningRef(), NULL, $comment->isAnonymous()"}</h3>
{{if !$comment->isAnonymous()}}
<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'>{expression="\IPS\Member\Group::load( $comment->author()->member_group_id )->formattedName" raw="true"}</span>
{{endif}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\Anonymous' ) and $comment->isAnonymous() and \IPS\Member::loggedIn()->modPermission('can_view_anonymous_posters')}}
@@ -1642,7 +1630,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
</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 $comment->editLine()}}
{{if \IPS\IPS::classUsesTrait( $comment, 'IPS\Content\EditHistory' ) and $comment->editLine()}}
({lang="edited_lc"})
{{endif}}
</p>
@@ -1658,7 +1646,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
{{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="Toggle mini profile"><i class="fa-solid fa-chevron-down" aria-hidden="true"></i></button>
<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}}
@@ -1667,7 +1655,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
</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'>
<ul class='ipsBadges' data-ips-hook="galleryCommentBadges">
{{if $comment->author()->hasHighlightedReplies()}}
<li><span class='ipsBadge ipsBadge--highlightedGroup'>{expression="\IPS\Member\Group::load( $comment->author()->member_group_id )->name" raw="true"}</span></li>
{{endif}}
@@ -1690,7 +1678,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
{{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 class='ipsRichText ipsRichText--user' data-role='commentContent' data-controller='core.front.core.lightboxedImages'>
<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}
@@ -1698,8 +1686,8 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
</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 class='ipsEntry__footer'>
<menu class='ipsEntry__controls' data-role="commentControls" data-ips-hook="commentControls">
<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>
@@ -1735,6 +1723,9 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
<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'>
@@ -2356,7 +2347,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
{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 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'
<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"}"
@@ -2365,14 +2356,14 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
<header class='ipsEntry__header'>
<div class='ipsEntry__header-align'>
<div class='ipsPhotoPanel'>
<div class='ipsAvatarStack'>
<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 class='ipsEntry__username'>
<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'>{expression="\IPS\Member\Group::load( $review->author()->member_group_id )->formattedName" raw="true"}</span>
@@ -2393,42 +2384,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
{{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}}
<a href='#elControlsReviews_{$review->id}_menu' class='ipsEntry__topButton ipsEntry__topButton--ellipsis' id='elControlsReviews_{$review->id}' title='{lang="more_options"}' data-ipsMenu data-ipsMenu-appendTo='#review-{$review->id}_wrap'><i class='fa-solid fa-ellipsis'></i><span class='ipsInvisible'>{lang="more_options"}</span></a>
<ul id='elControlsReviews_{$review->id}_menu' class='ipsMenu ipsMenu_narrow ipsHide'>
{{if $review->canReportOrRevoke() === TRUE}}
<li class='ipsMenu_item'>
<a href='{$review->url('report')}' {{if member.member_id or \IPS\Helpers\Form\Captcha::supportsModal()}}data-ipsDialog data-ipsDialog-remoteSubmit data-ipsDialog-size='medium' data-ipsDialog-flashMessage='{lang="report_submit_success"}' data-ipsDialog-title="{lang="report"}"{{endif}} data-action='reportComment' title='{lang="report"}'>{lang="report"}</a>
</li>
{{endif}}
<li class='ipsMenu_item'>
<a class='i-color_inherit' href='{$review->item()->url()->setQueryString( array( 'do' => 'findReview', 'review' => $review->id ) )}' title='{lang="share_this_review"}' data-ipsDialog data-ipsDialog-size='narrow' data-ipsDialog-content='#elShareReview_{$review->id}_menu' data-ipsDialog-title="{lang="share_this_review"}" id='elShareReview_{$review->id}' data-role='shareComment'>{lang="share_this_review"}</a>
</li>
{{if $review->canEdit() || ( $review->hidden() == -2 AND \IPS\Member::loggedIn()->modPermission('can_manage_deleted_content') ) || ( \IPS\IPS::classUsesTrait( $review, 'IPS\Content\Hideable' ) && ( ( !$review->hidden() and $review->canHide() ) || ( $review->hidden() and $review->canUnhide() ) ) ) || $review->canDelete()}}
<li class='ipsMenu_sep'><hr></li>
{{endif}}
{{if $review->canEdit()}}
<li class='ipsMenu_item'><a href='{$review->url('edit')}' data-action='editComment'>{lang="edit"}</a></li>
{{endif}}
{{if $review->hidden() == -2 AND \IPS\Member::loggedIn()->modPermission('can_manage_deleted_content')}}
<li class='ipsMenu_item'><a href='{$review->url('restore')->csrf()}' data-confirm data-confirmSubMessage='{lang="restore_as_visible_desc"}'>{lang="restore_as_visible"}</a></li>
<li class='ipsMenu_item'><a href='{$review->url('restore')->csrf()->setQueryString( 'restoreAsHidden', 1 )}' data-confirm data-confirmSubMessage='{lang="restore_as_hidden_desc"}'>{lang="restore_as_hidden"}</a></li>
<li class='ipsMenu_item'><a href='{$review->url('delete')->csrf()->setQueryString( 'immediately', 1 )}' data-confirm data-confirmSubMessage='{lang="delete_immediately_desc"}'>{lang="delete_immediately"}</a></li>
{{else}}
{{if \IPS\IPS::classUsesTrait( $review, 'IPS\Content\Hideable' )}}
{{if !$review->hidden() and $review->canHide()}}
<li class='ipsMenu_item'><a href='{{if $review::$hideLogKey}}{$review->url('hide')}{{else}}{$review->url('hide')->csrf()}{{endif}}' data-ipsDialog data-ipsDialog-title="{lang="hide"}">{lang="hide"}</a></li>
{{elseif $review->hidden() and $review->canUnhide()}}
<li class='ipsMenu_item'><a href='{$review->url('unhide')->csrf()}'>{lang="unhide"}</a></li>
{{endif}}
{{endif}}
{{if $review->canDelete()}}
<li class='ipsMenu_item'><a href='{$review->url('delete')->csrf()->setPage('page',\IPS\Request::i()->page)}' data-action='deleteComment' data-updateOnDelete="#reviewCount">{lang="delete"}</a></li>
{{endif}}
{{endif}}
</ul>
{$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>
@@ -2455,7 +2411,7 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
</div>
&nbsp;&nbsp; {{if $review->mapped('votes_total')}}<strong>{$review->helpfulLine()|raw}</strong>{{endif}}
<div id="review-{$review->id}" class='ipsRichText ipsRichText--user' data-role='commentContent' data-controller='core.front.core.lightboxedImages'>
<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}
@@ -2499,9 +2455,9 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
</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 class='ipsEntry__footer'>
<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="commentControls">
<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>
@@ -2531,6 +2487,9 @@ data-view-tracking-data="{expression="base64_encode(json_encode( $comment->getVi
<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>