Remove deprecated status views

This commit is contained in:
Daniel Supernault 2019-06-30 22:49:44 -06:00
parent 1980ec025d
commit 09361db173
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7
9 changed files with 1 additions and 477 deletions

View file

@ -1,104 +0,0 @@
@extends('layouts.app',['title' => $user->username . " posted a photo: " . $status->likes_count . " likes, " . $status->comments_count . " comments" ])
@section('content')
<div class="container px-0 mt-md-4">
<div class="card card-md-rounded-0 status-container orientation-{{$status->firstMedia()->orientation ?? 'unknown'}}">
<div class="row mx-0">
<div class="d-flex d-md-none align-items-center justify-content-between card-header bg-white w-100">
<a href="{{$user->url()}}" class="d-flex align-items-center status-username text-truncate" data-toggle="tooltip" data-placement="bottom" title="{{$user->username}}">
<div class="status-avatar mr-2">
<img src="{{$user->avatarUrl()}}" width="24px" height="24px" style="border-radius:12px;">
</div>
<div class="username">
<span class="username-link font-weight-bold text-dark">{{$user->username}}</span>
</div>
</a>
<div class="float-right">
<div class="dropdown">
<button class="btn btn-link text-dark no-caret dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" title="Post options">
<span class="fas fa-ellipsis-v text-muted"></span>
</button>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenuButton">
<a class="dropdown-item font-weight-bold" href="{{$status->reportUrl()}}">Report</a>
{{-- <a class="dropdown-item" href="#">Embed</a> --}}
@if(Auth::check())
@if(Auth::user()->profile->id !== $status->profile->id)
<div class="dropdown-divider"></div>
<form method="post" action="/i/mute">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Mute this user</button>
</form>
<form method="post" action="/i/block">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Block this user</button>
</form>
@endif
@if(Auth::user()->profile->id === $status->profile->id || Auth::user()->is_admin == true)
<div class="dropdown-divider"></div>
{{-- <a class="dropdown-item" href="{{$status->editUrl()}}">Edit</a> --}}
<form method="post" action="/i/delete">
@csrf
<input type="hidden" name="type" value="post">
<input type="hidden" name="item" value="{{$status->id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Delete</button>
</form>
@endif
@endif
</div>
</div>
</div>
</div>
<div class="col-12 col-md-8 status-photo px-0">
@if($status->is_nsfw)
<details class="details-animated">
<summary>
<p class="mb-0 lead font-weight-bold">CW / NSFW / Hidden Media</p>
<p class="font-weight-light">(click to show)</p>
</summary>
@endif
<div id="photoCarousel" class="carousel slide carousel-fade" data-ride="carousel">
<ol class="carousel-indicators">
@for($i = 0; $i < $status->media_count; $i++)
<li data-target="#photoCarousel" data-slide-to="{{$i}}" class="{{$i == 0 ? 'active' : ''}}"></li>
@endfor
</ol>
<div class="carousel-inner">
@foreach($status->media()->orderBy('order')->get() as $media)
<div class="carousel-item {{$loop->iteration == 1 ? 'active' : ''}}">
<figure class="{{$media->filter_class}}">
<img class="d-block w-100" src="{{$media->url()}}" title="{{$media->caption}}" data-toggle="tooltip" data-placement="bottom">
</figure>
</div>
@endforeach
</div>
<a class="carousel-control-prev" href="#photoCarousel" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="carousel-control-next" href="#photoCarousel" role="button" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
@if($status->is_nsfw)
</details>
@endif
</div>
@include('status.show.sidebar')
</div>
</div>
</div>
@endsection
@push('meta')
<meta property="og:description" content="{{ $status->caption }}">
<meta property="og:image" content="{{$status->mediaUrl()}}">
<link href='{{$status->url()}}' rel='alternate' type='application/activity+json'>
@endpush

View file

@ -1,85 +0,0 @@
@extends('layouts.app',['title' => $user->username . " posted a photo: " . $status->likes_count . " likes, " . $status->comments_count . " comments" ])
@section('content')
<div class="container px-0 mt-md-4">
<div class="card card-md-rounded-0 status-container orientation-{{$status->firstMedia()->orientation ?? 'unknown'}}">
<div class="row mx-0">
<div class="d-flex d-md-none align-items-center justify-content-between card-header bg-white w-100">
<a href="{{$user->url()}}" class="d-flex align-items-center status-username text-truncate" data-toggle="tooltip" data-placement="bottom" title="{{$user->username}}">
<div class="status-avatar mr-2">
<img src="{{$user->avatarUrl()}}" width="24px" height="24px" style="border-radius:12px;">
</div>
<div class="username">
<span class="username-link font-weight-bold text-dark">{{$user->username}}</span>
</div>
</a>
<div class="float-right">
<div class="dropdown">
<button class="btn btn-link text-dark no-caret dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" title="Post options">
<span class="fas fa-ellipsis-v text-muted"></span>
</button>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenuButton">
<a class="dropdown-item font-weight-bold" href="{{$status->reportUrl()}}">Report</a>
{{-- <a class="dropdown-item" href="#">Embed</a> --}}
@if(Auth::check())
@if(Auth::user()->profile->id !== $status->profile->id)
<div class="dropdown-divider"></div>
<form method="post" action="/i/mute">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Mute this user</button>
</form>
<form method="post" action="/i/block">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Block this user</button>
</form>
@endif
@if(Auth::user()->profile->id === $status->profile->id || Auth::user()->is_admin == true)
<div class="dropdown-divider"></div>
{{-- <a class="dropdown-item" href="{{$status->editUrl()}}">Edit</a> --}}
<form method="post" action="/i/delete">
@csrf
<input type="hidden" name="type" value="post">
<input type="hidden" name="item" value="{{$status->id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Delete</button>
</form>
@endif
@endif
</div>
</div>
</div>
</div>
<div class="col-12 col-md-8 status-photo px-0">
@if($status->is_nsfw && $status->media_count == 1)
<details class="details-animated">
<summary>
<p class="mb-0 lead font-weight-bold">CW / NSFW / Hidden Media</p>
<p class="font-weight-light">(click to show)</p>
</summary>
<a class="max-hide-overflow {{$status->firstMedia()->filter_class}}" href="{{$status->url()}}">
<img class="card-img-top" src="{{$status->mediaUrl()}}" title="{{$status->firstMedia()->caption}}" data-toggle="tooltip" data-tooltip-placement="bottom">
</a>
</details>
@elseif(!$status->is_nsfw && $status->media_count == 1)
<div class="{{$status->firstMedia()->filter_class}}">
<img src="{{$status->mediaUrl()}}" width="100%" title="{{$status->firstMedia()->caption}}" data-toggle="tooltip" data-placement="bottom">
</div>
@endif
</div>
@include('status.show.sidebar')
</div>
</div>
</div>
@endsection
@push('meta')
<meta property="og:description" content="{{ $status->caption }}">
<meta property="og:image" content="{{$status->mediaUrl()}}">
<link href='{{$status->url()}}' rel='alternate' type='application/activity+json'>
@endpush

View file

@ -1,117 +0,0 @@
<div class="col-12 col-md-4 px-0 d-flex flex-column border-left border-md-left-0">
<div class="d-md-flex d-none align-items-center justify-content-between card-header py-3 bg-white">
<a href="{{$user->url()}}" class="d-flex align-items-center status-username text-truncate" data-toggle="tooltip" data-placement="bottom" title="{{$user->username}}">
<div class="status-avatar mr-2">
<img src="{{$user->avatarUrl()}}" width="24px" height="24px" style="border-radius:12px;">
</div>
<div class="username">
<span class="username-link font-weight-bold text-dark">{{$user->username}}</span>
</div>
</a>
<div class="float-right">
<div class="dropdown">
<button class="btn btn-link text-dark no-caret dropdown-toggle" type="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" title="Post options">
<span class="fas fa-ellipsis-v text-muted"></span>
</button>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="dropdownMenuButton">
<a class="dropdown-item font-weight-bold" href="{{$status->reportUrl()}}">Report</a>
{{-- <a class="dropdown-item" href="#">Embed</a> --}}
@if(Auth::check())
@if(Auth::user()->profile->id !== $status->profile->id)
<div class="dropdown-divider"></div>
<form method="post" action="/i/mute">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Mute this user</button>
</form>
<form method="post" action="/i/block">
@csrf
<input type="hidden" name="type" value="user">
<input type="hidden" name="item" value="{{$status->profile_id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Block this user</button>
</form>
@endif
@if(Auth::user()->profile->id === $status->profile->id || Auth::user()->is_admin == true)
<div class="dropdown-divider"></div>
{{-- <a class="dropdown-item" href="{{$status->editUrl()}}">Edit</a> --}}
<form method="post" action="/i/delete">
@csrf
<input type="hidden" name="type" value="post">
<input type="hidden" name="item" value="{{$status->id}}">
<button type="submit" class="dropdown-item btn btn-link font-weight-bold">Delete</button>
</form>
@endif
@endif
</div>
</div>
</div>
</div>
<div class="d-flex flex-md-column flex-column-reverse h-100">
<div class="card-body status-comments">
<div class="status-comment">
<p class="mb-1">
<span class="font-weight-bold pr-1">{{$status->profile->username}}</span>
<span class="comment-text" v-pre>{!! $status->rendered ?? e($status->caption) !!}</span>
</p>
<p class="mb-1"><a href="{{$status->url()}}/c" class="text-muted">View all comments</a></p>
<div class="comments">
@foreach($replies as $item)
<p class="mb-1">
<span class="font-weight-bold pr-1"><bdi><a class="text-dark" href="{{$item->profile->url()}}">{{ str_limit($item->profile->username, 15)}}</a></bdi></span>
<span class="comment-text" v-pre>{!! $item->rendered ?? e($item->caption) !!} <a href="{{$item->url()}}" class="text-dark small font-weight-bold float-right pl-2">{{$item->created_at->diffForHumans(null, true, true ,true)}}</a></span>
</p>
@endforeach
</div>
</div>
</div>
<div class="card-body flex-grow-0 py-1">
<div class="reactions my-1">
@if(Auth::check())
<form class="d-inline-flex pr-3" method="post" action="/i/like" style="display: inline;" data-id="{{$status->id}}" data-action="like">
@csrf
<input type="hidden" name="item" value="{{$status->id}}">
<button class="btn btn-link text-dark p-0 border-0" type="submit" title="Like!">
<h3 class="m-0 {{$status->liked() ? 'fas fa-heart text-danger':'far fa-heart text-dark'}}"></h3>
</button>
</form>
<h3 class="far fa-comment pr-3 m-0" title="Comment"></h3>
<form class="d-inline-flex share-form pr-3" method="post" action="/i/share" style="display: inline;" data-id="{{$status->id}}" data-action="share" data-count="{{$status->shares_count}}">
@csrf
<input type="hidden" name="item" value="{{$status->id}}">
<button class="btn btn-link text-dark p-0" type="submit" title="Share">
<h3 class="m-0 {{$status->shared() ? 'fas fa-share-square text-primary':'far fa-share-square '}}"></h3>
</button>
</form>
@endif
<span class="float-right">
<form class="d-inline-flex " method="post" action="/i/bookmark" style="display: inline;" data-id="{{$status->id}}" data-action="bookmark">
@csrf
<input type="hidden" name="item" value="{{$status->id}}">
<button class="btn btn-link text-dark p-0 border-0" type="submit" title="Save">
<h3 class="m-0 {{$status->bookmarked() ? 'fas fa-bookmark text-warning':'far fa-bookmark'}}"></h3>
</button>
</form>
</span>
</div>
<div class="likes font-weight-bold mb-0">
<span class="like-count" data-count="{{$status->likes_count}}">{{$status->likes_count}}</span> likes
</div>
<div class="timestamp">
<a href="{{$status->url()}}" class="small text-muted">
{{$status->created_at->format('F j, Y')}}
</a>
</div>
</div>
</div>
<div class="card-footer bg-white sticky-md-bottom">
<form class="comment-form" method="post" action="/i/comment" data-id="{{$status->id}}" data-truncate="false">
@csrf
<input type="hidden" name="item" value="{{$status->id}}">
<input class="form-control" name="comment" placeholder="Add a comment…" autocomplete="off">
</form>
</div>
</div>

View file

@ -1,50 +0,0 @@
@extends('layouts.app',['title' => $user->username . " posted a photo: " . $status->likes_count . " likes, " . $status->comments_count . " comments" ])
@section('content')
<div class="container px-0 mt-md-4">
<div class="card card-md-rounded-0 status-container orientation-video">
<div class="row mx-0">
<div class="d-flex d-md-none align-items-center justify-content-between card-header bg-white w-100">
<a href="{{$user->url()}}" class="d-flex align-items-center status-username text-truncate" data-toggle="tooltip" data-placement="bottom" title="{{$user->username}}">
<div class="status-avatar mr-2">
<img src="{{$user->avatarUrl()}}" width="24px" height="24px" style="border-radius:12px;">
</div>
<div class="username">
<span class="username-link font-weight-bold text-dark">{{$user->username}}</span>
</div>
</a>
</div>
<div class="col-12 col-md-8 status-photo px-0">
@if($status->is_nsfw && $status->media_count == 1)
<details class="details-animated">
<summary>
<p class="mb-0 lead font-weight-bold">CW / NSFW / Hidden Media</p>
<p class="font-weight-light">(click to show)</p>
</summary>
<div class="embed-responsive embed-responsive-16by9">
<video class="embed-responsive-item" controls="">
<source src="{{$status->mediaUrl()}}" type="video/mp4">
</video>
</div>
</details>
@elseif(!$status->is_nsfw && $status->media_count == 1)
<div class="embed-responsive embed-responsive-16by9">
<video class="embed-responsive-item" controls="">
<source src="{{$status->mediaUrl()}}" type="video/mp4">
</video>
</div>
@endif
</div>
@include('status.show.sidebar')
</div>
</div>
</div>
@endsection
@push('meta')
<meta property="og:description" content="{{ $status->caption }}">
<meta property="og:image" content="{{$status->mediaUrl()}}">
<link href='{{$status->url()}}' rel='alternate' type='application/activity+json'>
@endpush

View file

@ -91,7 +91,7 @@
<span class="like-count">{{$item->likes_count}}</span> likes
</div>
<div class="caption">
<p class="mb-1">
<p class="mb-1 read-more" style="overflow: hidden;">
<span class="username font-weight-bold">
<bdi><a class="text-dark" href="{{$item->profile->url()}}" v-pre>{{$item->profile->username}}</a></bdi>
</span>

View file

@ -1,29 +0,0 @@
@if($status->is_nsfw)
@else
<div id="photo-carousel-wrapper-{{$status->id}}" class="carousel slide carousel-fade" data-ride="carousel">
<ol class="carousel-indicators">
@for($i = 0; $i < $status->media_count; $i++)
<li data-target="#photo-carousel-wrapper-{{$status->id}}" data-slide-to="{{$i}}" class="{{$i == 0 ? 'active' : ''}}"></li>
@endfor
</ol>
<div class="carousel-inner">
@foreach($status->media()->orderBy('order')->get() as $media)
<div class="carousel-item {{$loop->iteration == 1 ? 'active' : ''}}">
<figure class="{{$media->filter_class}}">
<span class="float-right mr-3 badge badge-dark" style="position:fixed;top:8px;right:0;margin-bottom:-20px;">{{$loop->iteration}}/{{$loop->count}}</span>
<img class="d-block w-100" src="{{$media->url()}}" alt="{{$status->caption}}">
</figure>
</div>
@endforeach
</div>
<a class="carousel-control-prev" href="#photo-carousel-wrapper-{{$status->id}}" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="carousel-control-next" href="#photo-carousel-wrapper-{{$status->id}}" role="button" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
@endif

View file

@ -1,15 +0,0 @@
@if($status->is_nsfw)
<details class="details-animated">
<summary>
<p class="mb-0 lead font-weight-bold">CW / NSFW / Hidden Media</p>
<p class="font-weight-light">(click to show)</p>
</summary>
<a class="max-hide-overflow {{$status->firstMedia()->filter_class}}" href="{{$status->url()}}">
<img class="card-img-top" src="{{$status->mediaUrl()}}">
</a>
</details>
@else
<div class="{{$status->firstMedia()->filter_class}}">
<img src="{{$status->mediaUrl()}}" width="100%">
</div>
@endif

View file

@ -1,57 +0,0 @@
@if($status->is_nsfw)
<div id="video-carousel-wrapper-{{$status->id}}" class="carousel slide carousel-fade" data-ride="false" data-interval="false">
<ol class="carousel-indicators">
@for($i = 0; $i < $status->media_count; $i++)
<li data-target="#video-carousel-wrapper-{{$status->id}}" data-slide-to="{{$i}}" class="{{$i == 0 ? 'active' : ''}}"></li>
@endfor
</ol>
<div class="carousel-inner">
@foreach($status->media()->orderBy('order')->get() as $media)
<div class="carousel-item {{$loop->iteration == 1 ? 'active' : ''}}">
<span class="float-right mr-3 badge badge-dark" style="position:fixed;top:8px;right:0;margin-bottom:-20px;z-index: 999;">{{$loop->iteration}}/{{$loop->count}}</span>
<div class="embed-responsive embed-responsive-4by3">
<video class=" embed-responsive-item" controls loop>
<source src="{{$media->url()}}" type="{{$media->mime}}">
</video>
</div>
</div>
@endforeach
</div>
<a class="carousel-control-prev" href="#video-carousel-wrapper-{{$status->id}}" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="carousel-control-next" href="#video-carousel-wrapper-{{$status->id}}" role="button" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
@else
<div id="video-carousel-wrapper-{{$status->id}}" class="carousel slide carousel-fade" data-ride="false" data-interval="false">
<ol class="carousel-indicators">
@for($i = 0; $i < $status->media_count; $i++)
<li data-target="#video-carousel-wrapper-{{$status->id}}" data-slide-to="{{$i}}" class="{{$i == 0 ? 'active' : ''}}"></li>
@endfor
</ol>
<div class="carousel-inner">
@foreach($status->media()->orderBy('order')->get() as $media)
<div class="carousel-item {{$loop->iteration == 1 ? 'active' : ''}}">
<span class="float-right mr-3 badge badge-dark" style="position:fixed;top:8px;right:0;margin-bottom:-20px;z-index: 999;">{{$loop->iteration}}/{{$loop->count}}</span>
<div class="embed-responsive embed-responsive-4by3">
<video class=" embed-responsive-item" controls loop>
<source src="{{$media->url()}}" type="{{$media->mime}}">
</video>
</div>
</div>
@endforeach
</div>
<a class="carousel-control-prev" href="#video-carousel-wrapper-{{$status->id}}" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="carousel-control-next" href="#video-carousel-wrapper-{{$status->id}}" role="button" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
@endif

View file

@ -1,19 +0,0 @@
@if($status->is_nsfw)
<details class="details-animated">
<summary>
<p class="mb-0 lead font-weight-bold">CW / NSFW / Hidden Media</p>
<p class="font-weight-light">(click to show)</p>
</summary>
<div class="embed-responsive embed-responsive-16by9">
<video class="video" preload="none" controls loop>
<source src="{{$status->firstMedia()->url()}}" type="{{$status->firstMedia()->mime}}">
</video>
</div>
</details>
@else
<div class="embed-responsive embed-responsive-16by9">
<video class="video" preload="none" controls loop>
<source src="{{$status->firstMedia()->url()}}" type="{{$status->firstMedia()->mime}}">
</video>
</div>
@endif