diff options
author | Mario <mario@mariovavti.com> | 2020-02-26 09:51:40 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2020-02-26 09:51:40 +0000 |
commit | e7f25b84664c158343621c391b8653042d5be53c (patch) | |
tree | 70e86ba68f7345ad1375b43bb8b38aafab089523 /view/tpl/jot.tpl | |
parent | b36eb9a91cba1a6f3a53961f895665a0ae110b95 (diff) | |
download | volse-hubzilla-e7f25b84664c158343621c391b8653042d5be53c.tar.gz volse-hubzilla-e7f25b84664c158343621c391b8653042d5be53c.tar.bz2 volse-hubzilla-e7f25b84664c158343621c391b8653042d5be53c.zip |
implement poll UI in jot
Diffstat (limited to 'view/tpl/jot.tpl')
-rwxr-xr-x | view/tpl/jot.tpl | 40 |
1 files changed, 37 insertions, 3 deletions
diff --git a/view/tpl/jot.tpl b/view/tpl/jot.tpl index b4616db6d..9f2860b2f 100755 --- a/view/tpl/jot.tpl +++ b/view/tpl/jot.tpl @@ -30,15 +30,15 @@ {{if $webpage}} <div id="jot-pagetitle-wrap" class="jothidden"> - <input name="pagetitle" id="jot-pagetitle" type="text" placeholder="{{$placeholdpagetitle}}" value="{{$pagetitle}}"> + <input class="w-100 border-0" name="pagetitle" id="jot-pagetitle" type="text" placeholder="{{$placeholdpagetitle}}" value="{{$pagetitle}}"> </div> {{/if}} <div id="jot-title-wrap" class="jothidden"> - <input name="title" id="jot-title" type="text" placeholder="{{$placeholdertitle}}" tabindex="1" value="{{$title}}"> + <input class="w-100 border-0" name="title" id="jot-title" type="text" placeholder="{{$placeholdertitle}}" tabindex="1" value="{{$title}}"> </div> {{if $catsenabled}} <div id="jot-category-wrap" class="jothidden"> - <input name="category" id="jot-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" data-role="cat-tagsinput"> + <input class="w-100 border-0" name="category" id="jot-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" data-role="cat-tagsinput"> </div> {{/if}} <div id="jot-text-wrap"> @@ -59,6 +59,34 @@ <input class="jot-attachment" name="attachment" id="jot-attachment" type="text" value="{{$attachment}}" readonly="readonly" onclick="this.select();"> </div> {{/if}} + <div id="jot-poll-wrap" class="p-2 d-none"> + <div id="jot-poll-options"> + <div class="jot-poll-option form-group"> + <input class="w-100 border-0" name="poll_answers[]" type="text" value="" placeholder="Option"> + </div> + <div class="jot-poll-option form-group"> + <input class="w-100 border-0" name="poll_answers[]" type="text" value="" placeholder="Option"> + </div> + </div> + {{include file="field_checkbox.tpl" field=$multiple_answers}} + <div id="jot-poll-tools" class="clearfix"> + <div id="poll-tools-left" class="float-left"> + <button id="jot-add-option" class="btn btn-outline-secondary btn-sm" type="button" title="" onclick=""> + <i class="fa fa-plus"></i> Add option + </button> + </div> + <div id="poll-tools-right" class="float-right"> + <div class="input-group"> + <input type="text" name="poll_expire_value" class="form-control" value="10" size="3"> + <select class="form-control" id="duration-select" name="poll_expire_unit"> + <option value="Minutes">min</option> + <option value="Hours">h</option> + <option value="Days" selected="selected">d</option> + </select> + </div> + </div> + </div> + </div> <div id="profile-jot-submit-wrapper" class="clearfix p-2 jothidden"> <div id="profile-jot-submit-left" class="btn-toolbar float-left"> {{if $bbcode}} @@ -132,6 +160,11 @@ <i id="profile-voting" class="fa fa-square-o jot-icons"></i> </button> {{/if}} + + <button type="button" id="profile-poll-wrapper" class="btn btn-outline-secondary btn-sm" title="{{$poll}}" onclick="initPoll();"> + <i id="profile-poll" class="fa fa-bar-chart jot-icons"></i> + </button> + {{if $feature_nocomment}} <button id="profile-nocomment-wrapper" class="btn btn-outline-secondary btn-sm" title="{{$nocommenttitle}}" onclick="toggleNoComment();return false;"> <i id="profile-nocomment" class="fa fa-comments jot-icons"></i> @@ -176,6 +209,7 @@ {{if $feature_voting}} <a class="dropdown-item" href="#" onclick="toggleVoting(); return false;"><i id="profile-voting-sub" class="fa fa-square-o"></i> {{$voting}}</a> {{/if}} + <a class="dropdown-item" href="#" onclick="initPoll(); return false"><i id="profile-poll" class="fa fa-bar-chart jot-icons"></i> {{$poll}}</a> {{if $feature_nocomment}} <a class="dropdown-item" href="#" onclick="toggleNoComment(); return false;"><i id="profile-nocomment-sub" class="fa fa-comments"></i> {{$nocommenttitlesub}}</a> {{/if}} |