]> BookStack Code Mirror - bookstack/blob - resources/views/comments/comment-reply.blade.php
#47 - Adds a cancel button for edit and reply button.
[bookstack] / resources / views / comments / comment-reply.blade.php
1 <div class="comment-editor" ng-controller="CommentReplyController as vm" ng-cloak>
2     <form novalidate>
3         <textarea name="markdown" rows="3" ng-model="comment.text" placeholder="{{ trans('entities.comment_placeholder') }}"
4                   @if($errors->has('markdown')) class="neg" @endif>@if(isset($model) ||
5                   old('markdown')){{htmlspecialchars( old('markdown') ? old('markdown') : ($model->markdown === '' ? $model->html : $model->markdown))}}@endif</textarea>
6         <input type="hidden" ng-model="comment.pageId" name="comment.pageId" value="{{$pageId}}" ng-init="comment.pageId = {{$pageId }}">
7         <button type="button" ng-if="::(isReply || isEdit)" class="button muted" ng-click="closeBox()">{{ trans('entities.comment_cancel') }}</button>
8         <button type="submit" class="button pos" ng-click="vm.saveComment(isReply)">{{ trans('entities.comment_save') }}</button>
9     </form>
10 </div>
11
12 @if($errors->has('markdown'))
13     <div class="text-neg text-small">{{ $errors->first('markdown') }}</div>
14 @endif