diff options
author | Mario <mario@mariovavti.com> | 2017-10-25 13:29:19 +0200 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2017-10-25 13:29:19 +0200 |
commit | 344aa13c64f0fa7a246f3284bf9cdb267e6101d3 (patch) | |
tree | 943809c01164dda7b6e4a26bc3d6c7e8c48bd6eb /view/tpl | |
parent | 61c86212b944efa0d78dcc0364b81bfb8a0d19bc (diff) | |
parent | 69b22e3f7916b5ba19b5ed03a55ad72bf5995291 (diff) | |
download | volse-hubzilla-344aa13c64f0fa7a246f3284bf9cdb267e6101d3.tar.gz volse-hubzilla-344aa13c64f0fa7a246f3284bf9cdb267e6101d3.tar.bz2 volse-hubzilla-344aa13c64f0fa7a246f3284bf9cdb267e6101d3.zip |
Merge branch '2.8RC'
Diffstat (limited to 'view/tpl')
53 files changed, 777 insertions, 246 deletions
diff --git a/view/tpl/abook_edit.tpl b/view/tpl/abook_edit.tpl index 146030494..13b94a560 100755 --- a/view/tpl/abook_edit.tpl +++ b/view/tpl/abook_edit.tpl @@ -52,7 +52,7 @@ {{/foreach}} <div class="section-content-info-wrapper"> <div> - {{$addr_text}} <strong>'{{$addr}}'</strong> + {{$addr_text}} <strong>'{{if $addr}}{{$addr}}{{else}}{{$primeurl}}{{/if}}'</strong> </div> {{if $locstr}} <div> diff --git a/view/tpl/admin_plugins.tpl b/view/tpl/admin_plugins.tpl index fd5ae7d5e..adc0db434 100755 --- a/view/tpl/admin_plugins.tpl +++ b/view/tpl/admin_plugins.tpl @@ -41,8 +41,8 @@ {{$form}} </div> <div class="clear"></div> - <div id="chat-rotator-wrapper" class="center-block"> - <div id="chat-rotator"></div> + <div id="chat-rotator" class="spinner-wrapper"> + <div class="spinner s"></div> </div> <div class="clear"></div> <div class="section-content-wrapper-np"> @@ -75,11 +75,11 @@ $("#generic-modal-ok-{{$newRepoModalID}}").addClass('btn-primary'); var repoURL = $('#id_repoURL').val(); var repoName = $('#id_repoName').val(); - $('#chat-rotator').spin('tiny'); + $('#chat-rotator').show(); $.post( "/admin/plugins/addrepo", {repoURL: repoURL, repoName: repoName}, function(response) { - $('#chat-rotator').spin(false); + $('#chat-rotator').hide(); if (response.success) { var modalBody = $('#generic-modal-body-{{$newRepoModalID}}'); modalBody.html('<div>'+response.repo.readme+'</div>'); @@ -187,4 +187,4 @@ } } -</script>
\ No newline at end of file +</script> diff --git a/view/tpl/admin_site.tpl b/view/tpl/admin_site.tpl index e995f82b2..d6ff34f93 100755 --- a/view/tpl/admin_site.tpl +++ b/view/tpl/admin_site.tpl @@ -82,6 +82,7 @@ <div class="submit"><input type="submit" name="page_site" value="{{$submit}}" /></div> <h3>{{$advanced}}</h3> + {{include file="field_input.tpl" field=$imagick_path}} {{include file="field_input.tpl" field=$proxy}} {{include file="field_input.tpl" field=$proxyuser}} {{include file="field_input.tpl" field=$timeout}} diff --git a/view/tpl/app_nav.tpl b/view/tpl/app_nav.tpl new file mode 100644 index 000000000..046cd7237 --- /dev/null +++ b/view/tpl/app_nav.tpl @@ -0,0 +1 @@ +<a class="navbar-app nav-link{{if $app.active}} active{{/if}}" href="{{$app.url}}" title="{{$app.name}}" >{{if $icon}}<i class="fa fa-fw fa-{{$icon}}"></i>{{else}}<img src="{{$app.photo}}" width="16" height="16" />{{/if}}</a> diff --git a/view/tpl/cards.tpl b/view/tpl/cards.tpl new file mode 100644 index 000000000..60e6163ae --- /dev/null +++ b/view/tpl/cards.tpl @@ -0,0 +1,4 @@ +<div id="live-cards"></div> +{{$editor}} +{{$content}} +{{$pager}} diff --git a/view/tpl/cdav_calendar.tpl b/view/tpl/cdav_calendar.tpl index 5d683d751..b0245e853 100644 --- a/view/tpl/cdav_calendar.tpl +++ b/view/tpl/cdav_calendar.tpl @@ -129,11 +129,11 @@ $(document).ready(function() { }, loading: function(isLoading, view) { - $('#events-spinner').spin('tiny'); - $('#events-spinner > i').css('color', 'transparent'); + $('#events-spinner').show(); + $('#today-btn > i').hide(); if(!isLoading) { - $('#events-spinner').spin(false); - $('#events-spinner > i').css('color', ''); + $('#events-spinner').hide(); + $('#today-btn > i').show(); } } }); @@ -292,7 +292,7 @@ function on_more() { </div> <div class="btn-group"> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('prev', false);" title="{{$prev}}"><i class="fa fa-backward"></i></button> - <button id="events-spinner" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><i class="fa fa-bullseye"></i></button> + <button id="today-btn" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><div id="events-spinner" class="spinner s"></div><i class="fa fa-bullseye" style="display: none; width: 1rem;"></i></button> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('next', false);" title="{{$next}}"><i class="fa fa-forward"></i></button> </div> <button id="fullscreen-btn" type="button" class="btn btn-outline-secondary btn-sm" onclick="makeFullScreen();"><i class="fa fa-expand"></i></button> diff --git a/view/tpl/channel_rename.tpl b/view/tpl/channel_rename.tpl new file mode 100755 index 000000000..9948dc647 --- /dev/null +++ b/view/tpl/channel_rename.tpl @@ -0,0 +1,20 @@ +<div class="generic-content-wrapper"> + <div class="section-title-wrapper"> + <h2>{{$title}}</h2> + </div> + <div class="section-content-danger-wrapper" id="rename-channel-desc"> + <strong>{{$desc.0}}</strong><strong>{{$desc.1}}</strong> + </div> + <div class="section-content-tools-wrapper"> + <form action="{{$basedir}}/changeaddr" autocomplete="off" method="post" > + <input type="hidden" name="verify" value="{{$hash}}" /> + <div class="form-group" id="rename-channel-pass-wrapper"> + <label id="rename-channel-pass-label" for="rename-channel-pass">{{$passwd}}</label> + <input class="form-control" type="password" id="rename-channel-pass" autocomplete="off" name="qxz_password" value=" " /> + </div> + {{include file="field_input.tpl" field=$newname}} + <button type="submit" name="submit" class="btn btn-danger">{{$submit}}</button> + </form> + </div> +</div> + diff --git a/view/tpl/chat.tpl b/view/tpl/chat.tpl index 22f3465bf..c189cbd15 100644 --- a/view/tpl/chat.tpl +++ b/view/tpl/chat.tpl @@ -16,6 +16,9 @@ </div> <div id="chatContainer" class="section-content-wrapper"> <div id="chatTopBar"> + <div id="chat-top-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> + </div> <div id="chatLineHolder"></div> </div> <div class="clear"></div> @@ -25,7 +28,7 @@ <div class="form-group"> <textarea id="chatText" name="chat_text" class="form-control"></textarea> </div> - <div id="chat-submit-wrapper"> + <div id="chat-submit-wrapper" class="clearfix"> <div id="chat-submit" class="dropup pull-right"> <button class="btn btn-outline-secondary btn-sm dropdown-toggle" type="button" data-toggle="dropdown"><i class="fa fa-cog"></i></button> <button class="btn btn-primary btn-sm" type="submit" id="chat-submit" name="submit" value="{{$submit}}">{{$submit}}</button> @@ -42,7 +45,7 @@ {{/if}} </div> </div> - <div id="chat-tools" class="btn-toolbar pull-left"> + <div id="chat-tools" class="btn-toolbar"> <div class="btn-group mr-2"> <button id="main-editor-bold" class="btn btn-outline-secondary btn-sm" title="{{$bold}}" onclick="inserteditortag('b', 'chatText'); return false;"> <i class="fa fa-bold jot-icons"></i> @@ -84,11 +87,12 @@ {{/if}} </div> </div> + <div class="btn-group"> + <div id="chat-rotator" class="mt-2 spinner-wrapper"> + <div class="spinner s"></div> + </div> + </div> </div> - <div id="chat-rotator-wrapper" class="pull-left"> - <div id="chat-rotator"></div> - </div> - <div class="clear"></div> </div> </form> </div> @@ -101,7 +105,7 @@ var last_chat = 0; var chat_timer = null; $(document).ready(function() { - $('#chatTopBar').spin('small'); + $('#chat-top-spinner').show(); chat_timer = setTimeout(load_chats,300); $('#chatroom_bookmarks, #vcard').hide(); $('#chatroom_list, #chatroom_members').show(); @@ -134,7 +138,7 @@ function load_chats() { if(data.success && (! stopped)) { update_inroom(data.inroom); update_chats(data.chats); - $('#chatTopBar').spin(false); + $('#chat-top-spinner').hide(); } }); @@ -293,10 +297,10 @@ function toggleChatNotifications() { function chatJotGetLink() { reply = prompt("{{$linkurl}}"); if(reply && reply.length) { - $('#chat-rotator').spin('tiny'); + $('#chat-rotator').show(); $.get('linkinfo?f=&url=' + reply, function(data) { addmailtext(data); - $('#chat-rotator').spin(false); + $('#chat-rotator').hide(); }); } } diff --git a/view/tpl/cloud_actionspanel.tpl b/view/tpl/cloud_actionspanel.tpl index 0ebecce29..baee48da3 100644 --- a/view/tpl/cloud_actionspanel.tpl +++ b/view/tpl/cloud_actionspanel.tpl @@ -26,6 +26,7 @@ <input type="hidden" name="return_url" value="{{$return_url}}" /> <label for="files-upload">{{$upload_header}}</label> <input class="form-group pull-left" id="files-upload" type="file" name="userfile"> + {{**include file="field_checkbox.tpl" field=$notify**}} <div class="pull-right btn-group"> <div class="btn-group"> {{if $lockstate}} diff --git a/view/tpl/cloud_directory.tpl b/view/tpl/cloud_directory.tpl index adc8584c3..e8ae6a590 100644 --- a/view/tpl/cloud_directory.tpl +++ b/view/tpl/cloud_directory.tpl @@ -25,7 +25,7 @@ <td><a href="{{$item.fullPath}}">{{$item.displayName}}</a></td> {{if $item.is_owner}} <td class="cloud-index-tool">{{$item.attachIcon}}</td> - <td id="file-edit-{{$item.attachId}}" class="cloud-index-tool"></td> + <td class="cloud-index-tool"><div id="file-edit-{{$item.attachId}}" class="spinner-wrapper"><div class="spinner s"></div></div></td> <td class="cloud-index-tool"><i class="fakelink fa fa-pencil" onclick="filestorage(event, '{{$nick}}', {{$item.attachId}});"></i></td> <td class="cloud-index-tool"><a href="#" title="{{$delete}}" onclick="dropItem('{{$item.fileStorageUrl}}/{{$item.attachId}}/delete', '#cloud-index-{{$item.attachId}},#cloud-tools-{{$item.attachId}}'); return false;"><i class="fa fa-trash-o drop-icons"></i></a></td> diff --git a/view/tpl/comment_item.tpl b/view/tpl/comment_item.tpl index 02b0c527c..62530c1de 100755 --- a/view/tpl/comment_item.tpl +++ b/view/tpl/comment_item.tpl @@ -18,7 +18,7 @@ {{$anon_extras}} </div> {{/if}} - <textarea id="comment-edit-text-{{$id}}" class="comment-edit-text-empty" name="body" onFocus="commentOpenUI(this,{{$id}});" onBlur="commentCloseUI(this,{{$id}});" ondragenter="linkdropper(event);" ondragleave="linkdropexit(event);" ondragover="linkdropper(event);" ondrop="linkdrop(event);" >{{$comment}}</textarea> + <textarea id="comment-edit-text-{{$id}}" class="comment-edit-text" placeholder="{{$comment}}" name="body" ondragenter="linkdropper(event);" ondragleave="linkdropexit(event);" ondragover="linkdropper(event);" ondrop="linkdrop(event);" ></textarea> {{if $qcomment}} <select id="qcomment-select-{{$id}}" name="qcomment-{{$id}}" class="qcomment" onchange="qCommentInsert(this,{{$id}});" > <option value=""></option> @@ -47,6 +47,11 @@ </button> </div> <div class="btn-group mr-2"> + {{if $can_upload}} + <button class="btn btn-outline-secondary btn-sm" title="{{$edatt}}" onclick="insertCommentAttach('{{$comment}}',{{$id}}); return false;"> + <i class="fa fa-paperclip comment-icon"></i> + </button> + {{/if}} <button class="btn btn-outline-secondary btn-sm" title="{{$edurl}}" onclick="insertCommentURL('{{$comment}}',{{$id}}); return false;"> <i class="fa fa-link comment-icon"></i> </button> diff --git a/view/tpl/common_friends.tpl b/view/tpl/common_friends.tpl index 489717e78..b99075210 100755 --- a/view/tpl/common_friends.tpl +++ b/view/tpl/common_friends.tpl @@ -1,15 +1,17 @@ -<div class="profile-match-wrapper"> - <div class="profile-match-photo"> - <a href="{{$url}}"> - <img src="{{$photo}}" alt="{{$name}}" width="80" height="80" title="{{$name}} [{{$url}}]" /> - </a> +<div class="generic-content-wrapper"> + <div class="section-title-wrapper"> + <h2>{{$title}}</h2> </div> - <div class="profile-match-break"></div> - <div class="profile-match-name"> - <a href="{{$url}}" title="{{$name}}[{{$tags}}]">{{$name}}</a> + <div class="section-content-wrapper clearfix"> + {{foreach $items as $item}} + <div class="float-left mr-4"> + <a href="{{$item.url}}"> + <img class="contact-block-img" src="{{$item.photo}}" alt="{{$item.name}}" title="{{$item.name}} [{{$item.url}}]" /> + </a> + <div> + {{$item.name}} + </div> + </div> + {{/foreach}} </div> - {{if $note}} - <div class="profile-match-note">{{$note}}</div> - {{/if}} - <div class="profile-match-end"></div> </div> diff --git a/view/tpl/connections.tpl b/view/tpl/connections.tpl index 13261965a..3b152ef5e 100755 --- a/view/tpl/connections.tpl +++ b/view/tpl/connections.tpl @@ -33,4 +33,6 @@ </div> </div> <script>$(document).ready(function() { loadingPage = false;});</script> -<div id="page-spinner"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> diff --git a/view/tpl/conv_frame.tpl b/view/tpl/conv_frame.tpl index aa7b55e9b..8aa865076 100755 --- a/view/tpl/conv_frame.tpl +++ b/view/tpl/conv_frame.tpl @@ -1,5 +1,8 @@ <div id="threads-begin"></div> <div id="threads-end"></div> <div id="conversation-end"></div> -<div id="page-spinner"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> + diff --git a/view/tpl/conv_item.tpl b/view/tpl/conv_item.tpl index 36cb4cc83..b0e1cb6fb 100755 --- a/view/tpl/conv_item.tpl +++ b/view/tpl/conv_item.tpl @@ -4,7 +4,7 @@ </div> <div id="collapsed-comments-{{$item.id}}" class="collapsed-comments" style="display: none;"> {{/if}} - <div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} mb-4 generic-content-wrapper h-entry {{else}} u-comment h-cite {{/if}} item_{{$item.submid}}"> + <div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} generic-content-wrapper h-entry {{else}} u-comment h-cite {{/if}} item_{{$item.submid}}"> <a name="item_{{$item.id}}" ></a> <div class="wall-item-outside-wrapper{{if $item.is_comment}} comment{{/if}}{{if $item.previewing}} preview{{/if}}" id="wall-item-outside-wrapper-{{$item.id}}" > <div class="clearfix wall-item-content-wrapper{{if $item.is_comment}} comment{{/if}}" id="wall-item-content-wrapper-{{$item.id}}"> @@ -39,6 +39,7 @@ </div> {{/if}} <div class="wall-item-author"> + {{if $item.previewing}}<span class="preview-indicator"><i class="fa fa-eye" title="{{$item.preview_lbl}}"></i></span> {{/if}} <a href="{{$item.profile_url}}" title="{{$item.linktitle}}" class="wall-item-name-link"><span class="wall-item-name{{$item.sparkle}}" id="wall-item-name-{{$item.id}}" >{{$item.name}}</span></a>{{if $item.owner_url}} {{$item.via}} <a href="{{$item.owner_url}}" title="{{$item.olinktitle}}" class="wall-item-name-link"><span class="wall-item-name{{$item.osparkle}}" id="wall-item-ownername-{{$item.id}}">{{$item.owner_name}}</span></a>{{/if}} </div> <div class="wall-item-ago" id="wall-item-ago-{{$item.id}}"> @@ -85,6 +86,11 @@ {{/if}} <div class="p-2 clearfix wall-item-tools"> <div class="float-right wall-item-tools-right"> + <div class="btn-group"> + <div id="like-rotator-{{$item.id}}" class="spinner-wrapper"> + <div class="spinner s"></div> + </div> + </div> {{if $item.toplevel && $item.emojis && $item.reactions}} <div class="btn-group"> <button type="button" class="btn btn-outline-secondary btn-sm dropdown-toggle" data-toggle="dropdown" id="wall-item-react-{{$item.id}}"> @@ -150,7 +156,7 @@ </button> <div class="dropdown-menu dropdown-menu-right" role="menu" aria-labelledby="wall-item-menu-{{$item.id}}"> {{if $item.share}} - <a class="dropdown-item" href="#" onclick="jotShare({{$item.id}}); return false"><i class="generic-icons-nav fa fa-fw fa-retweet" title="{{$item.share.0}}"></i>{{$item.share.0}}</a> + <a class="dropdown-item" href="#" onclick="jotShare({{$item.id}},{{$item.item_type}}); return false"><i class="generic-icons-nav fa fa-fw fa-retweet" title="{{$item.share.0}}"></i>{{$item.share.0}}</a> {{/if}} {{if $item.plink}} <a class="dropdown-item" href="{{$item.plink.href}}" title="{{$item.plink.title}}" class="u-url"><i class="generic-icons-nav fa fa-fw fa-external-link"></i>{{$item.plink.title}}</a> @@ -194,7 +200,6 @@ </div> </div> </div> - <div id="like-rotator-{{$item.id}}" class="like-rotator"></div> {{if $item.responses || $item.attachments}} <div class="wall-item-tools-left{{if ($item.responses.count > 1) || ($item.responses.count && $item.attachments)}} btn-group{{/if}}"> diff --git a/view/tpl/conv_list.tpl b/view/tpl/conv_list.tpl index e442dd3cc..97fd50d01 100755 --- a/view/tpl/conv_list.tpl +++ b/view/tpl/conv_list.tpl @@ -4,7 +4,7 @@ </div> <div id="collapsed-comments-{{$item.id}}" class="collapsed-comments" style="display: none;"> {{/if}} - <div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} mb-4 generic-content-wrapper h-entry {{else}} u-comment h-cite {{/if}} item_{{$item.submid}}"> + <div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} generic-content-wrapper h-entry {{else}} u-comment h-cite {{/if}} item_{{$item.submid}}"> <a name="item_{{$item.id}}" ></a> <div class="wall-item-outside-wrapper{{if $item.is_comment}} comment{{/if}}{{if $item.previewing}} preview{{/if}}" id="wall-item-outside-wrapper-{{$item.id}}" > <div class="clearfix wall-item-content-wrapper{{if $item.is_comment}} comment{{/if}}" id="wall-item-content-wrapper-{{$item.id}}"> @@ -150,7 +150,7 @@ </button> <div class="dropdown-menu dropdown-menu-right" role="menu" aria-labelledby="wall-item-menu-{{$item.id}}"> {{if $item.share}} - <a class="dropdown-item" href="#" onclick="jotShare({{$item.id}}); return false"><i class="generic-icons-nav fa fa-fw fa-retweet" title="{{$item.share.0}}"></i>{{$item.share.0}}</a> + <a class="dropdown-item" href="#" onclick="jotShare({{$item.id}},{{$item.item_type}}); return false"><i class="generic-icons-nav fa fa-fw fa-retweet" title="{{$item.share.0}}"></i>{{$item.share.0}}</a> {{/if}} {{if $item.plink}} <a class="dropdown-item" href="{{$item.plink.href}}" title="{{$item.plink.title}}" class="u-url"><i class="generic-icons-nav fa fa-fw fa-external-link"></i>{{$item.plink.title}}</a> diff --git a/view/tpl/cover_photo_widget.tpl b/view/tpl/cover_photo_widget.tpl index a9c384d2f..7404a740c 100755 --- a/view/tpl/cover_photo_widget.tpl +++ b/view/tpl/cover_photo_widget.tpl @@ -8,7 +8,8 @@ aside_padding_top = parseInt($('aside').css('padding-top')); section_padding_top = parseInt($('section').css('padding-top')); - $(document).on('click', slideUpCover); + $('#cover-photo').on('click', slideUpCover); + $('#cover-photo').on('keyup', slideUpCover); if($('#cover-photo').length && $(window).width() > 755) { if($(window).scrollTop() < $('#cover-photo').height()) { diff --git a/view/tpl/directory_header.tpl b/view/tpl/directory_header.tpl index 71e991f3a..3ee9ee326 100755 --- a/view/tpl/directory_header.tpl +++ b/view/tpl/directory_header.tpl @@ -19,4 +19,6 @@ <div id="page-end"></div> </div> <script>$(document).ready(function() { loadingPage = false;});</script> -<div id="page-spinner"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> diff --git a/view/tpl/event_head.tpl b/view/tpl/event_head.tpl index 3b2cb5041..2f440e826 100755 --- a/view/tpl/event_head.tpl +++ b/view/tpl/event_head.tpl @@ -67,11 +67,11 @@ showEvent(calEvent.id); }, loading: function(isLoading, view) { - $('#events-spinner').spin('tiny'); - $('#events-spinner > i').css('color', 'transparent'); + $('#events-spinner').show(); + $('#today-btn > i').hide(); if(!isLoading) { - $('#events-spinner').spin(false); - $('#events-spinner > i').css('color', ''); + $('#events-spinner').hide(); + $('#today-btn > i').show(); $('td.fc-day').dblclick(function() { openMenu('form'); //window.location.href='/events/new?start='+$(this).data('date'); diff --git a/view/tpl/events-js.tpl b/view/tpl/events-js.tpl index 9d32c76be..d3f3414ff 100755 --- a/view/tpl/events-js.tpl +++ b/view/tpl/events-js.tpl @@ -11,7 +11,7 @@ <button class="btn btn-success btn-sm" onclick="openClose('form');">{{$new_event.1}}</button> <div class="btn-group"> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('prev', false);" title="{{$prev}}"><i class="fa fa-backward"></i></button> - <button id="events-spinner" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><i class="fa fa-bullseye"></i></button> + <button id="today-btn" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><div id="events-spinner" class="spinner s"></div><i class="fa fa-bullseye" style="display: none; width: 1rem;"></i></button> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('next', false);" title="{{$next}}"><i class="fa fa-forward"></i></button> </div> <button id="fullscreen-btn" type="button" class="btn btn-outline-secondary btn-sm" onclick="makeFullScreen();"><i class="fa fa-expand"></i></button> diff --git a/view/tpl/events_cal-js.tpl b/view/tpl/events_cal-js.tpl index ba9e16dd6..2c4d961f9 100755 --- a/view/tpl/events_cal-js.tpl +++ b/view/tpl/events_cal-js.tpl @@ -4,7 +4,7 @@ <div class="pull-right"> <div class="btn-group"> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('prev', false);" title="{{$prev}}"><i class="fa fa-backward"></i></button> - <button id="events-spinner" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><i class="fa fa-bullseye"></i></button> + <button id="today-btn" class="btn btn-outline-secondary btn-sm" onclick="changeView('today', false);" title="{{$today}}"><div id="events-spinner" class="spinner s"></div><i class="fa fa-bullseye" style="display: none; width: 1rem;"></i></button> <button class="btn btn-outline-secondary btn-sm" onclick="changeView('next', false);" title="{{$next}}"><i class="fa fa-forward"></i></button> </div> <button id="fullscreen-btn" type="button" class="btn btn-outline-secondary btn-sm" onclick="makeFullScreen();"><i class="fa fa-expand"></i></button> diff --git a/view/tpl/hdr.tpl b/view/tpl/hdr.tpl index cccee2229..29137c740 100644 --- a/view/tpl/hdr.tpl +++ b/view/tpl/hdr.tpl @@ -1,3 +1,3 @@ -<div id="nav-notifications-template" rel="template"> +<div id="navbar-notifications-template" rel="template" style="display:none;"> <a class="dropdown-item clearfix dropdown-notification {5}" href="{0}" title="{2} {3}"><img class="menu-img-3" data-src="{1}"><span class="contactname">{2}</span><span class="dropdown-sub-text">{3}<br>{4}</span></a> -</div> +</div>
\ No newline at end of file diff --git a/view/tpl/help.tpl b/view/tpl/help.tpl index 43b061dcc..d36494123 100644 --- a/view/tpl/help.tpl +++ b/view/tpl/help.tpl @@ -1,5 +1,17 @@ <div id="help-content" class="generic-content-wrapper"> - <div class="section-title-wrapper"> + <div class="clearfix section-title-wrapper"> + <div class="pull-right"> + <div class="btn-group"> + <button type="button" class="btn btn-outline-secondary btn-sm dropdown-toggle" data-toggle="dropdown"> + <i class="fa fa-language" style="font-size: 1.4em;"></i> + </button> + <div class="dropdown-menu dropdown-menu-right flex-column lang-selector"> + <a class="dropdown-item lang-choice" href="/help">de</a> + <a class="dropdown-item lang-choice" href="/help">en</a> + <a class="dropdown-item lang-choice" href="/help">es</a> + </div> + </div> + </div> <h2>{{$title}}: {{$heading}}</h2> </div> <div class="section-content-wrapper" id="doco-content"> @@ -13,21 +25,6 @@ {{$content}} </div> </div> - <script> - // Generate the table of contents in the side nav menu (see view/tpl/help.tpl) - $(document).ready(function () { - $('#doco-top-toc').toc({content: "#doco-content", headings: "h3,h4,h5,h6"}); - }); - - function docoTocToggle() { - if($('#doco-top-toc').is(':visible')) { - $('#doco-toc-toggle').removeClass('fa-cog').addClass('fa-caret-right'); - } else { - $('#doco-toc-toggle').removeClass('fa-caret-right').addClass('fa-caret-down'); - } - $('#doco-top-toc').toggle(); - - return false; - } + var help_language = '{{$language}}' </script> diff --git a/view/tpl/jot-header.tpl b/view/tpl/jot-header.tpl index d8f296aa4..2f9dd9f15 100755 --- a/view/tpl/jot-header.tpl +++ b/view/tpl/jot-header.tpl @@ -6,10 +6,10 @@ var pretext = '{{$pretext}}'; function initEditor(cb){ if (editor==false){ - $("#profile-jot-text-loading").spin('small').show(); + $("#profile-jot-text-loading").show(); {{$geotag}} if(plaintext == 'none') { - $("#profile-jot-text-loading").spin(false).hide(); + $("#profile-jot-text-loading").hide(); $("#profile-jot-text").css({ 'height': 200 }); {{if $bbco_autocomplete}} $("#profile-jot-text").bbco_autocomplete('{{$bbco_autocomplete}}'); // autocomplete bbcode @@ -80,7 +80,7 @@ function initEditor(cb){ ed.onInit.add(function(ed) { ed.pasteAsPlainText = true; - $("#profile-jot-text-loading").spin(false).hide(); + $("#profile-jot-text-loading").hide(); $(".jothidden").show(); if (typeof cb!="undefined") cb(); }); @@ -106,6 +106,9 @@ function enableOnUser(){ <script src="library/blueimp_upload/js/jquery.fileupload.js"></script> <script> +var activeCommentID = 0; +var activeCommentText = ''; + $(document).ready(function() { /* enable tinymce on focus and click */ $("#profile-jot-text").focus(enableOnUser); @@ -118,7 +121,7 @@ function enableOnUser(){ dropZone: $('#profile-jot-text'), maxChunkSize: 4 * 1024 * 1024, add: function(e,data) { - $('#profile-rotator').spin('tiny'); + $('#profile-rotator').show(); data.submit(); }, done: function(e,data) { @@ -126,7 +129,8 @@ function enableOnUser(){ $('#jot-media').val($('#jot-media').val() + data.result.message); }, stop: function(e,data) { - $('#profile-rotator').spin(false); + preview_post(); + $('#profile-rotator').hide(); }, }); @@ -138,6 +142,34 @@ function enableOnUser(){ DragDropUploadInit(); } + + $('#invisible-comment-upload').fileupload({ + url: 'wall_attach/{{$nickname}}', + dataType: 'json', + maxChunkSize: 4 * 1024 * 1024, + add: function(e,data) { + + var tmpStr = $("#comment-edit-text-" + activeCommentID).val(); + if(tmpStr == activeCommentText) { + tmpStr = ""; + $("#comment-edit-text-" + activeCommentID).addClass("comment-edit-text-full"); + $("#comment-edit-text-" + activeCommentID).removeClass("comment-edit-text-empty"); + openMenu("comment-tools-" + activeCommentID); + $("#comment-edit-text-" + activeCommentID).val(tmpStr); + } + data.submit(); + }, + + done: function(e,data) { + textarea = document.getElementById("comment-edit-text-" + activeCommentID); + textarea.value = textarea.value + data.result.message; + }, + stop: function(e,data) { + $('body').css('cursor', 'auto'); + preview_comment(activeCommentID); + activeCommentID = 0; + }, + }); }); function deleteCheckedItems() { @@ -172,10 +204,11 @@ function enableOnUser(){ reply = prompt("{{$linkurl}}"); if(reply && reply.length) { reply = bin2hex(reply); - $('#profile-rotator').spin('tiny'); + $('#profile-rotator').show(); $.get('{{$baseurl}}/linkinfo?f=&binurl=' + reply, function(data) { addeditortext(data); - $('#profile-rotator').spin(false); + preview_post(); + $('#profile-rotator').hide(); }); } } @@ -214,18 +247,23 @@ function enableOnUser(){ } - function jotShare(id) { - if ($('#jot-popup').length != 0) $('#jot-popup').show(); + function jotShare(id,post_type) { + if(post_type == 6) { + window.location.href = 'rpost?f=&post_id='+id; + } + else { + if ($('#jot-popup').length != 0) $('#jot-popup').show(); - $('#like-rotator-' + id).spin('tiny'); - $.get('{{$baseurl}}/share/' + id, function(data) { - if (!editor) $("#profile-jot-text").val(""); - initEditor(function(){ - addeditortext(data); - $('#like-rotator-' + id).spin(false); - $(window).scrollTop(0); + $('#like-rotator-' + id).show(); + $.get('{{$baseurl}}/share/' + id, function(data) { + if (!editor) $("#profile-jot-text").val(""); + initEditor(function(){ + addeditortext(data); + $('#like-rotator-' + id).hide(); + $(window).scrollTop(0); + }); }); - }); + } } function linkdropper(event) { @@ -274,17 +312,17 @@ function enableOnUser(){ if(reply && reply.length) { reply = bin2hex(reply); - $('#profile-rotator').spin('tiny'); + $('#profile-rotator').show(); $.get('{{$baseurl}}/linkinfo?f=&binurl=' + reply, function(data) { if(commentwin) { $(editwin).val( $(editwin).val() + data ); - $('#profile-rotator').spin(false); + $('#profile-rotator').hide(); } else { if (!editor) $("#profile-jot-text").val(""); initEditor(function(){ addeditortext(data); - $('#profile-rotator').spin(false); + $('#profile-rotator').hide(); }); } }); @@ -421,6 +459,7 @@ function enableOnUser(){ function(ddata) { if (ddata['status']) { addeditortext(ddata['photolink']); + preview_post(); } else { window.console.log("{{$modalerrorlink}}" + ':' + ddata['errormsg']); } diff --git a/view/tpl/jot.tpl b/view/tpl/jot.tpl index cf99ede42..13e7602be 100755 --- a/view/tpl/jot.tpl +++ b/view/tpl/jot.tpl @@ -1,4 +1,5 @@ <input id="invisible-wall-file-upload" type="file" name="files" style="visibility:hidden;position:absolute;top:-50;left:-50;width:0;height:0;" multiple> +<input id="invisible-comment-upload" type="file" name="files" style="visibility:hidden;position:absolute;top:-50;left:-50;width:0;height:0;" multiple> <form id="profile-jot-form" action="{{$action}}" method="post" class="acl-form" data-form_id="profile-jot-form" data-allow_cid='{{$allow_cid}}' data-allow_gid='{{$allow_gid}}' data-deny_cid='{{$deny_cid}}' data-deny_gid='{{$deny_gid}}'> {{$mimeselect}} {{$layoutselect}} @@ -40,7 +41,7 @@ </div> {{/if}} <div id="jot-text-wrap"> - <textarea class="profile-jot-text" id="profile-jot-text" name="body" tabindex="2" placeholder="{{$share}}" >{{$content}}</textarea> + <textarea class="profile-jot-text" id="profile-jot-text" name="body" tabindex="2" placeholder="{{$placeholdtext}}" >{{$content}}</textarea> </div> {{if $attachment}} <div id="jot-attachment-wrap"> @@ -167,9 +168,11 @@ </div> </div> {{/if}} - </div> - <div id="profile-rotator-wrapper" class="float-left"> - <div id="profile-rotator"></div> + <div class="btn-group"> + <div id="profile-rotator" class="mt-2 spinner-wrapper"> + <div class="spinner s"></div> + </div> + </div> </div> <div id="profile-jot-submit-right" class="btn-group float-right"> {{if $preview}} diff --git a/view/tpl/login.tpl b/view/tpl/login.tpl index 3d3faa41c..492149abb 100755 --- a/view/tpl/login.tpl +++ b/view/tpl/login.tpl @@ -11,6 +11,8 @@ {{if $register}}<a href="{{$register.link}}" title="{{$register.title}}" id="register-link" class="pull-right">{{$register.desc}}</a>{{/if}} <a href="lostpass" title="{{$lostpass}}" id="lost-password-link" >{{$lostlink}}</a> </div> + <hr> + <a href="rmagic" class="btn btn-block btn-outline-success rmagic-button">{{$remote_login}}</a> </div> {{foreach $hiddens as $k=>$v}} <input type="hidden" name="{{$k}}" value="{{$v}}" /> diff --git a/view/tpl/main_slider.tpl b/view/tpl/main_slider.tpl index a4e2e1925..f5c573970 100755 --- a/view/tpl/main_slider.tpl +++ b/view/tpl/main_slider.tpl @@ -1,4 +1,9 @@ -<div id="main-slider" class="slider" ><input id="main-range" type="text" name="cminmax" value="{{$val}}" /></div> +<div id="main-slider" class="slider" > + <input id="main-range" type="text" name="cminmax" value="{{$val}}" /> + <div id="profile-jot-text-loading" class="spinner-wrapper"> + <div class="spinner m"></div> + </div> +</div> <script> $(document).ready(function() { var old_cmin = 0; @@ -19,13 +24,14 @@ $(document).ready(function() { var slideTimer = null; function networkRefresh() { + $("#profile-jot-text-loading").show(); if((document.readyState !== "complete") || (slideTimer !== null)) return; if((bParam_cmin == old_cmin) && (bParam_cmax == old_cmax)) return; - setTimeout(function() { $("#profile-jot-text-loading").spin('small'); }, 1000 ); + slideTimer = setTimeout(networkTimerRefresh,2000); } diff --git a/view/tpl/msg-header.tpl b/view/tpl/msg-header.tpl index 0e8fb0389..d71d432fb 100755 --- a/view/tpl/msg-header.tpl +++ b/view/tpl/msg-header.tpl @@ -12,7 +12,7 @@ dropZone: $('#prvmail-text'), maxChunkSize: 4 * 1024 * 1024, add: function(e,data) { - $('#prvmail-rotator').spin('tiny'); + $('#prvmail-rotator').show(); data.submit(); }, done: function(e,data) { @@ -20,7 +20,8 @@ $('#jot-media').val($('#jot-media').val() + data.result.message); }, stop: function(e,data) { - $('#prvmail-rotator').spin(false); + preview_mail(); + $('#prvmail-rotator').hide(); }, }); @@ -33,10 +34,11 @@ function prvmailJotGetLink() { reply = prompt("{{$linkurl}}"); if(reply && reply.length) { - $('#prvmail-rotator').spin('tiny'); + $('#prvmail-rotator').show(); $.get('linkinfo?f=&url=' + reply, function(data) { addmailtext(data); - $('#prvmail-rotator').spin(false); + preview_mail(); + $('#prvmail-rotator').hide(); }); } } @@ -59,10 +61,11 @@ event.target.textContent = reply; event.preventDefault(); if(reply && reply.length) { - $('#prvmail-rotator').spin('tiny'); + $('#prvmail-rotator').show(); $.get('linkinfo?f=&url=' + reply, function(data) { addmailtext(data); - $('#prvmail-rotator').spin(false); + preview_mail(); + $('#prvmail-rotator').hide(); }); } } diff --git a/view/tpl/nav_login.tpl b/view/tpl/nav_login.tpl index b361b1a14..4a94908f0 100644 --- a/view/tpl/nav_login.tpl +++ b/view/tpl/nav_login.tpl @@ -9,7 +9,6 @@ <div class="modal-body"> <div class="form-group"> {{$nav.login}} - {{$nav.remote_login}} </div> </div> </div> diff --git a/view/tpl/navbar_default.tpl b/view/tpl/navbar_default.tpl new file mode 100755 index 000000000..b330993c8 --- /dev/null +++ b/view/tpl/navbar_default.tpl @@ -0,0 +1,207 @@ +{{if $nav.login && !$userinfo}} +<div class="d-xl-none pt-1 pb-1"> + {{if $nav.loginmenu.1.4}} + <a class="btn btn-primary btn-sm text-white" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}_collapse" data-toggle="modal" data-target="#nav-login"> + {{$nav.loginmenu.1.1}} + </a> + {{else}} + <a class="btn btn-primary btn-sm text-white" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} + {{if $nav.register}} + <a class="btn btn-warning btn-sm text-dark" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}" > + {{$nav.register.1}} + </a> + {{/if}} +</div> +{{/if}} +{{if $userinfo}} +<div class="dropdown usermenu"> + <div class="fakelink" data-toggle="dropdown"> + <img id="avatar" src="{{$userinfo.icon}}" alt="{{$userinfo.name}}"> + <i class="fa fa-caret-down"></i> + </div> + {{if $is_owner}} + <div class="dropdown-menu"> + {{foreach $nav.usermenu as $usermenu}} + <a class="dropdown-item{{if $usermenu.2}} active{{/if}}" href="{{$usermenu.0}}" title="{{$usermenu.3}}" role="menuitem" id="{{$usermenu.4}}">{{$usermenu.1}}</a> + {{/foreach}} + {{if $nav.manage}} + <a class="dropdown-item{{if $sel.name == Manage}} active{{/if}}" href="{{$nav.manage.0}}" title="{{$nav.manage.3}}" role="menuitem" id="{{$nav.manage.4}}">{{$nav.manage.1}}</a> + {{/if}} + {{if $nav.channels}} + {{foreach $nav.channels as $chan}} + <a class="dropdown-item" href="manage/{{$chan.channel_id}}" title="{{$chan.channel_name}}" role="menuitem"><i class="fa fa-circle{{if $localuser == $chan.channel_id}} text-success{{else}} invisible{{/if}}"></i> {{$chan.channel_name}}</a> + {{/foreach}} + {{/if}} + {{if $nav.profiles}} + <a class="dropdown-item" href="{{$nav.profiles.0}}" title="{{$nav.profiles.3}}" role="menuitem" id="{{$nav.profiles.4}}">{{$nav.profiles.1}}</a> + {{/if}} + {{if $nav.settings}} + <div class="dropdown-divider"></div> + <a class="dropdown-item{{if $sel.name == Settings}} active{{/if}}" href="{{$nav.settings.0}}" title="{{$nav.settings.3}}" role="menuitem" id="{{$nav.settings.4}}">{{$nav.settings.1}}</a> + {{/if}} + {{if $nav.admin}} + <div class="dropdown-divider"></div> + <a class="dropdown-item{{if $sel.name == Admin}} active{{/if}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}" role="menuitem" id="{{$nav.admin.4}}">{{$nav.admin.1}}</a> + {{/if}} + {{if $nav.logout}} + <div class="dropdown-divider"></div> + <a class="dropdown-item" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}" role="menuitem" id="{{$nav.logout.4}}">{{$nav.logout.1}}</a> + {{/if}} + </div> + {{/if}} + {{if ! $is_owner}} + <div class="dropdown-menu" role="menu" aria-labelledby="avatar"> + <a class="dropdown-item" href="{{$nav.rusermenu.0}}" role="menuitem">{{$nav.rusermenu.1}}</a> + <a class="dropdown-item" href="{{$nav.rusermenu.2}}" role="menuitem">{{$nav.rusermenu.3}}</a> + </div> + {{/if}} +</div> +<div class="navbar-nav mr-auto"> + <div><a id="nav-app-link" href="{{$url}}" class="nav-link">{{$sel.name}}</a></div> +</div> +{{/if}} +<div class="navbar-toggler-right"> + {{if $nav.help.6}} + <button id="context-help-btn" class="navbar-toggler border-0" type="button" onclick="contextualHelp(); return false;"> + <i class="fa fa-question-circle"></i> + </button> + {{/if}} + <button id="expand-aside" type="button" class="d-md-none navbar-toggler border-0" data-toggle="offcanvas" data-target="#region_1"> + <i class="fa fa-arrow-circle-right" id="expand-aside-icon"></i> + </button> + {{if $localuser || $nav.pubs}} + <button id="notifications-btn" type="button" class="navbar-toggler border-0 text-white"> + <i id="notifications-btn-icon" class="fa fa-exclamation-circle"></i> + </button> + {{/if}} + <button id="menu-btn" class="navbar-toggler border-0" type="button" data-toggle="collapse" data-target="#navbar-collapse-2"> + <i class="fa fa-bars"></i> + </button> +</div> +<div class="collapse navbar-collapse" id="navbar-collapse-1"> + <ul class="navbar-nav mr-auto"> + {{if $nav.login && !$userinfo}} + <li class="nav-item d-none d-xl-flex"> + {{if $nav.loginmenu.1.4}} + <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login"> + {{$nav.loginmenu.1.1}} + </a> + {{else}} + <a class="nav-link" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} + </li> + {{/if}} + {{if $nav.register}} + <li class="nav-item {{$nav.register.2}} d-none d-xl-flex"> + <a class="nav-link" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}">{{$nav.register.1}}</a> + </li> + {{/if}} + {{if $nav.alogout}} + <li class="nav-item {{$nav.alogout.2}} d-none d-xl-flex"> + <a class="nav-link" href="{{$nav.alogout.0}}" title="{{$nav.alogout.3}}" id="{{$nav.alogout.4}}">{{$nav.alogout.1}}</a> + </li> + {{/if}} + </ul> + + <div id="banner" class="navbar-text">{{$banner}}</div> + + <ul id="nav-right" class="navbar-nav ml-auto"> + <li class="nav-item collapse clearfix" id="nav-search"> + <form class="form-inline" method="get" action="search" role="search"> + <input class="form-control form-control-sm mt-1 mr-2" id="nav-search-text" type="text" value="" placeholder=" {{$help}}" name="search" title="{{$nav.search.3}}" onclick="this.submit();" onblur="closeMenu('nav-search'); openMenu('nav-search-btn');"/> + </form> + <div id="nav-search-spinner" class="spinner-wrapper"> + <div class="spinner s"></div> + </div> + </li> + <li class="nav-item" id="nav-search-btn"> + <a class="nav-link" href="#nav-search" title="{{$nav.search.3}}" onclick="openMenu('nav-search'); closeMenu('nav-search-btn'); $('#nav-search-text').focus(); return false;"><i class="fa fa-fw fa-search"></i></a> + </li> + {{if $nav.help.6}} + <li class="nav-item dropdown {{$sel.help}}"> + <a class="nav-link {{$nav.help.2}}" target="hubzilla-help" href="{{$nav.help.0}}" title="{{$nav.help.3}}" id="{{$nav.help.4}}" onclick="contextualHelp(); return false;"><i class="fa fa-fw fa-question-circle"></i></a> + </li> + {{/if}} + {{if $channel_menu && $channel_apps.0}} + <li class="nav-item dropdown" id="channel-menu"> + <a class="nav-link" href="#" data-toggle="dropdown"><img src="{{$channel_thumb}}" style="height:14px; width:14px;position:relative; top:-2px;" /></a> + <div id="dropdown-menu" class="dropdown-menu dropdown-menu-right"> + {{foreach $channel_apps as $channel_app}} + {{$channel_app}} + {{/foreach}} + </div> + </li> + {{/if}} + {{if $navbar_apps}} + {{foreach $navbar_apps as $navbar_app}} + <li> + {{$navbar_app}} + </li> + {{/foreach}} + {{/if}} + <li class="nav-item dropdown" id="app-menu"> + <a class="nav-link" href="#" data-toggle="dropdown"><i class="fa fa-fw fa-bars"></i></a> + <div id="dropdown-menu" class="dropdown-menu dropdown-menu-right"> + {{if $channel_apps.0 && ! $channel_menu}} + {{foreach $channel_apps as $channel_app}} + {{$channel_app}} + {{/foreach}} + <div class="dropdown-divider"></div> + <div class="dropdown-header sys-apps-toggle" onclick="$('#dropdown-menu').click(function(e) { e.stopPropagation(); }); openClose('sys_apps');"> + {{$sysapps_toggle}} + </div> + <div id="sys_apps" style="display:none;"> + {{/if}} + {{foreach $nav_apps as $nav_app}} + {{$nav_app}} + {{/foreach}} + {{if $channel_apps.0 && ! $channel_menu}} + </div> + {{/if}} + {{if $is_owner}} + <div class="dropdown-divider"></div> + <a class="dropdown-item" href="/apps"><i class="generic-icons-nav fa fa-fw fa-plus-circle"></i>{{$addapps}}</a> + <a class="dropdown-item" href="/apporder"><i class="generic-icons-nav fa fa-fw fa-sort"></i>{{$orderapps}}</a> + {{/if}} + </div> + </li> + </ul> +</div> +<div class="collapse d-xl-none" id="navbar-collapse-2"> + <div class="navbar-nav mr-auto"> + {{if $channel_apps.0}} + {{foreach $channel_apps as $channel_app}} + {{$channel_app|replace:'dropdown-item':'nav-link'}} + {{/foreach}} + <div class="dropdown-header sys-apps-toggle" onclick="openClose('sys-apps-collapsed');"> + {{$sysapps_toggle}} + </div> + <div id="sys-apps-collapsed" style="display:none;"> + {{/if}} + {{foreach $nav_apps as $nav_app}} + {{$nav_app|replace:'dropdown-item':'nav-link'}} + {{/foreach}} + {{if $channel_apps.0}} + </div> + {{/if}} + {{if $is_owner}} + <div class="dropdown-divider"></div> + <a class="nav-link" href="/apps"><i class="generic-icons-nav fa fa-fw fa-plus-circle"></i>{{$addapps}}</a> + <a class="nav-link" href="/apporder"><i class="generic-icons-nav fa fa-fw fa-sort"></i>{{$orderapps}}</a> + {{/if}} + </div> +</div> +{{if $nav.help.6}} +<div id="contextual-help-content" class="contextual-help-content"> + {{$nav.help.5}} + <div class="float-right"> + <a class="btn btn-primary btn-sm" target="hubzilla-help" href="{{$nav.help.0}}" title="{{$nav.help.3}}"><i class="fa fa-question"></i> {{$fulldocs}}</a> + <a class="contextual-help-tool" href="#" onclick="contextualHelp(); return false;"><i class="fa fa-times"></i></a> + </div> +</div> +{{/if}} diff --git a/view/tpl/nav.tpl b/view/tpl/navbar_tucson.tpl index f480ce994..faf8b5b4a 100755 --- a/view/tpl/nav.tpl +++ b/view/tpl/navbar_tucson.tpl @@ -1,8 +1,14 @@ {{if $nav.login && !$userinfo}} -<div class="d-md-none pt-1 pb-1"> +<div class="d-xl-none pt-1 pb-1"> + {{if $nav.loginmenu.1.4}} <a class="btn btn-primary btn-sm text-white" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}_collapse" data-toggle="modal" data-target="#nav-login"> {{$nav.loginmenu.1.1}} </a> + {{else}} + <a class="btn btn-primary btn-sm text-white" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} {{if $nav.register}} <a class="btn btn-warning btn-sm text-dark" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}" > {{$nav.register.1}} @@ -10,6 +16,9 @@ {{/if}} </div> {{/if}} + + + {{if $userinfo}} <div class="dropdown usermenu"> <div class="fakelink" data-toggle="dropdown"> @@ -36,16 +45,13 @@ <div class="dropdown-divider"></div> <a class="dropdown-item{{if $sel.active == Settings}} active{{/if}}" href="{{$nav.settings.0}}" title="{{$nav.settings.3}}" role="menuitem" id="{{$nav.settings.4}}">{{$nav.settings.1}}</a> {{/if}} - {{if $nav.admin}} - <div class="dropdown-divider"></div> - <a class="dropdown-item{{if $sel.active == Admin}} active{{/if}}" href="{{$nav.admin.0}}" title="{{$nav.admin.3}}" role="menuitem" id="{{$nav.admin.4}}">{{$nav.admin.1}}</a> - {{/if}} {{if $nav.logout}} <div class="dropdown-divider"></div> <a class="dropdown-item" href="{{$nav.logout.0}}" title="{{$nav.logout.3}}" role="menuitem" id="{{$nav.logout.4}}">{{$nav.logout.1}}</a> {{/if}} </div> {{/if}} + {{if ! $is_owner}} <div class="dropdown-menu" role="menu" aria-labelledby="avatar"> <a class="dropdown-item" href="{{$nav.rusermenu.0}}" role="menuitem">{{$nav.rusermenu.1}}</a> @@ -54,33 +60,57 @@ {{/if}} </div> {{/if}} + + + +{{if $navbar_apps}} +<ul class="navbar-nav mr-auto d-none d-xl-flex"> +{{foreach $navbar_apps as $navbar_app}} +<li> +{{$navbar_app}} +</li> +{{/foreach}} +</ul> +{{/if}} + + <div class="navbar-toggler-right"> + {{if $nav.help.6}} <button id="context-help-btn" class="navbar-toggler border-0" type="button" onclick="contextualHelp(); return false;"> <i class="fa fa-question-circle"></i> </button> {{/if}} + <button id="expand-aside" type="button" class="navbar-toggler border-0" data-toggle="offcanvas" data-target="#region_1"> <i class="fa fa-arrow-circle-right" id="expand-aside-icon"></i> </button> - {{if $localuser}} + + {{if $localuser || $nav.pubs}} <button id="notifications-btn" type="button" class="navbar-toggler border-0 text-white" data-toggle="collapse" data-target="#navbar-collapse-1"> - <i class="fa fa-exclamation-circle"></i> + <i id="notifications-btn-icon" class="fa fa-exclamation"></i> </button> {{/if}} + <button id="menu-btn" class="navbar-toggler border-0" type="button" data-toggle="collapse" data-target="#navbar-collapse-2"> <i class="fa fa-bars"></i> </button> </div> + + + + + <div class="collapse navbar-collapse" id="navbar-collapse-1"> + <ul class="navbar-nav mr-auto"> {{if $nav.network}} - <li class="nav-item dropdown net-button" style="display: none;"> - <a class="nav-link" href="#" title="{{$nav.network.3}}" id="{{$nav.network.4}}" data-toggle="dropdown" rel="#nav-network-menu"> + <li class="nav-item dropdown network-button" style="display: none;"> + <a class="nav-link" href="#" title="{{$nav.network.3}}" id="{{$nav.network.4}}" data-toggle="dropdown" rel="#navbar-network-menu"> <i class="fa fa-fw fa-th"></i> - <span class="badge badge-pill badge-secondary net-update"></span> + <span class="badge badge-pill badge-secondary network-update"></span> </a> - <div id="nav-network-menu" class="dropdown-menu" rel="network"> + <div id="navbar-network-menu" class="dropdown-menu" rel="network"> <a class="dropdown-item" id="nav-network-see-all" href="{{$nav.network.all.0}}">{{$nav.network.all.1}}</a> <a class="dropdown-item" id="nav-network-mark-all" href="#" onclick="markRead('network'); return false;">{{$nav.network.mark.1}}</a> {{$emptynotifications}} @@ -89,11 +119,11 @@ {{/if}} {{if $nav.home}} <li class="nav-item dropdown home-button" style="display: none;"> - <a class="nav-link" href="#" title="{{$nav.home.3}}" id="{{$nav.home.4}}" data-toggle="dropdown" rel="#nav-home-menu"> + <a class="nav-link" href="#" title="{{$nav.home.3}}" id="{{$nav.home.4}}" data-toggle="dropdown" rel="#navbar-home-menu"> <i class="fa fa-fw fa-home"></i> <span class="badge badge-pill badge-danger home-update"></span> </a> - <div id="nav-home-menu" class="dropdown-menu" rel="home"> + <div id="navbar-home-menu" class="dropdown-menu" rel="home"> <a class="dropdown-item" id="nav-home-see-all" href="{{$nav.home.all.0}}">{{$nav.home.all.1}}</a> <a class="dropdown-item" id="nav-home-mark-all" href="#" onclick="markRead('home'); return false;">{{$nav.home.mark.1}}</a> {{$emptynotifications}} @@ -102,11 +132,11 @@ {{/if}} {{if $nav.messages}} <li class="nav-item dropdown mail-button" style="display: none;"> - <a class="nav-link" href="#" title="{{$nav.messages.3}}" id="{{$nav.messages.4}}" data-toggle="dropdown" rel="#nav-messages-menu"> + <a class="nav-link" href="#" title="{{$nav.messages.3}}" id="{{$nav.messages.4}}" data-toggle="dropdown" rel="#navbar-mail-menu"> <i class="fa fa-fw fa-envelope"></i> <span class="badge badge-pill badge-danger mail-update"></span> </a> - <div id="nav-messages-menu" class="dropdown-menu" rel="messages"> + <div id="navbar-mail-menu" class="dropdown-menu" rel="messages"> <a class="dropdown-item" id="nav-messages-see-all" href="{{$nav.messages.all.0}}">{{$nav.messages.all.1}}</a> <a class="dropdown-item" id="nav-messages-mark-all" href="#" onclick="markRead('messages'); return false;">{{$nav.messages.mark.1}}</a> {{$emptynotifications}} @@ -115,11 +145,11 @@ {{/if}} {{if $nav.all_events}} <li class="nav-item dropdown all_events-button" style="display: none;"> - <a class="nav-link" href="#" title="{{$nav.all_events.3}}" id="{{$nav.all_events.4}}" data-toggle="dropdown" rel="#nav-all_events-menu"> + <a class="nav-link" href="#" title="{{$nav.all_events.3}}" id="{{$nav.all_events.4}}" data-toggle="dropdown" rel="#navbar-all_events-menu"> <i class="fa fa-fw fa-calendar"></i> <span class="badge badge-pill badge-secondary all_events-update"></span> </a> - <div id="nav-all_events-menu" class="dropdown-menu" rel="all_events"> + <div id="navbar-all_events-menu" class="dropdown-menu" rel="all_events"> <a class="dropdown-item" id="nav-all_events-see-all" href="{{$nav.all_events.all.0}}">{{$nav.all_events.all.1}}</a> <a class="dropdown-item" id="nav-all_events-mark-all" href="#" onclick="markRead('all_events'); return false;">{{$nav.all_events.mark.1}}</a> {{$emptynotifications}} @@ -127,12 +157,12 @@ </li> {{/if}} {{if $nav.intros}} - <li class="nav-item dropdown intro-button" style="display: none;"> - <a class="nav-link" href="{{$nav.intros.0}}" title="{{$nav.intros.3}}" id="{{$nav.intros.4}}" data-toggle="dropdown" rel="#nav-intros-menu"> + <li class="nav-item dropdown intros-button" style="display: none;"> + <a class="nav-link" href="#" title="{{$nav.intros.3}}" id="{{$nav.intros.4}}" data-toggle="dropdown" rel="#navbar-intros-menu"> <i class="fa fa-fw fa-users"></i> - <span class="badge badge-pill badge-danger intro-update"></span> + <span class="badge badge-pill badge-danger intros-update"></span> </a> - <div id="nav-intros-menu" class="dropdown-menu" rel="intros"> + <div id="navbar-intros-menu" class="dropdown-menu" rel="intros"> <a class="dropdown-item" id="nav-intros-see-all" href="{{$nav.intros.all.0}}">{{$nav.intros.all.1}}</a> {{$emptynotifications}} </div> @@ -140,42 +170,58 @@ {{/if}} {{if $nav.notifications}} <li class="nav-item dropdown notify-button" style="display: none;"> - <a class="nav-link" href="{{$nav.notifications.0}}" title="{{$nav.notifications.1}}" id="{{$nav.notifications.4}}" data-toggle="dropdown" rel="#nav-notify-menu"> + <a class="nav-link" href="#" title="{{$nav.notifications.1}}" id="{{$nav.notifications.4}}" data-toggle="dropdown" rel="#navbar-notify-menu"> <i class="fa fa-fw fa-exclamation"></i> <span class="badge badge-pill badge-danger notify-update"></span> </a> - <div id="nav-notify-menu" class="dropdown-menu" rel="notify"> + <div id="navbar-notify-menu" class="dropdown-menu" rel="notify"> <a class="dropdown-item" id="nav-notify-see-all" href="{{$nav.notifications.all.0}}">{{$nav.notifications.all.1}}</a> <a class="dropdown-item" id="nav-notify-mark-all" href="#" onclick="markRead('notify'); return false;">{{$nav.notifications.mark.1}}</a> {{$emptynotifications}} </div> </li> {{/if}} + {{if $nav.login && !$userinfo}} - <li class="nav-item"> - <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login">{{$nav.loginmenu.1.1}}</a> + <li class="nav-item d-none d-xl-flex"> + {{if $nav.loginmenu.1.4}} + <a class="nav-link" href="#" title="{{$nav.loginmenu.1.3}}" id="{{$nav.loginmenu.1.4}}" data-toggle="modal" data-target="#nav-login"> + {{$nav.loginmenu.1.1}} + </a> + {{else}} + <a class="nav-link" href="login" title="{{$nav.loginmenu.1.3}}"> + {{$nav.loginmenu.1.1}} + </a> + {{/if}} </li> {{/if}} {{if $nav.register}} - <li class="nav-item {{$nav.register.2}} d-none d-md-flex"> + <li class="nav-item {{$nav.register.2}} d-none d-xl-flex"> <a class="nav-link" href="{{$nav.register.0}}" title="{{$nav.register.3}}" id="{{$nav.register.4}}">{{$nav.register.1}}</a> </li> {{/if}} {{if $nav.alogout}} - <li class="nav-item {{$nav.alogout.2}} d-none d-md-flex"> + <li class="nav-item {{$nav.alogout.2}} d-none d-xl-flex"> <a class="nav-link" href="{{$nav.alogout.0}}" title="{{$nav.alogout.3}}" id="{{$nav.alogout.4}}">{{$nav.alogout.1}}</a> </li> {{/if}} + </ul> - <div id="banner" class="navbar-text d-none d-md-flex">{{$banner}}</div> - <ul id="nav-right" class="navbar-nav ml-auto d-none d-md-flex"> + + + <div id="banner" class="navbar-text d-none d-xl-flex">{{$banner}}</div> + + + <ul id="nav-right" class="navbar-nav ml-auto d-none d-xl-flex"> <li class="nav-item collapse clearfix" id="nav-search"> <form class="form-inline" method="get" action="search" role="search"> <input class="form-control form-control-sm mt-1 mr-2" id="nav-search-text" type="text" value="" placeholder=" {{$help}}" name="search" title="{{$nav.search.3}}" onclick="this.submit();" onblur="closeMenu('nav-search'); openMenu('nav-search-btn');"/> </form> - <div id="nav-search-spinner"></div> + <div id="nav-search-spinner" class="spinner-wrapper"> + <div class="spinner s"></div> + </div> </li> <li class="nav-item" id="nav-search-btn"> <a class="nav-link" href="#nav-search" title="{{$nav.search.3}}" onclick="openMenu('nav-search'); closeMenu('nav-search-btn'); $('#nav-search-text').focus(); return false;"><i class="fa fa-fw fa-search"></i></a> @@ -185,24 +231,22 @@ <a class="nav-link {{$nav.help.2}}" target="hubzilla-help" href="{{$nav.help.0}}" title="{{$nav.help.3}}" id="{{$nav.help.4}}" onclick="contextualHelp(); return false;"><i class="fa fa-fw fa-question-circle"></i></a> </li> {{/if}} - <li class="nav-item dropdown" id="app-menu"> - <a class="nav-link" href="#" data-toggle="dropdown"><i class="fa fa-fw fa-bars"></i></a> + {{if $channel_apps.0}} + <li class="nav-item dropdown" id="channel-menu"> + <a class="nav-link" href="#" data-toggle="dropdown"><img src="{{$channel_thumb}}" style="height:14px; width:14px;position:relative; top:-2px;" /></a> <div id="dropdown-menu" class="dropdown-menu dropdown-menu-right"> - {{if $channel_apps.0}} {{foreach $channel_apps as $channel_app}} {{$channel_app}} {{/foreach}} - <div class="dropdown-header sys-apps-toggle" onclick="$('#dropdown-menu').click(function(e) { e.stopPropagation(); }); openClose('sys_apps');"> - {{$sysapps_toggle}} - </div> - <div id="sys_apps" style="display:none;"> - {{/if}} + </div> + </li> + {{/if}} + <li class="nav-item dropdown" id="app-menu"> + <a class="nav-link" href="#" data-toggle="dropdown"><i class="fa fa-fw fa-bars"></i></a> + <div id="dropdown-menu" class="dropdown-menu dropdown-menu-right"> {{foreach $nav_apps as $nav_app}} {{$nav_app}} {{/foreach}} - {{if $channel_apps.0}} - </div> - {{/if}} {{if $is_owner}} <div class="dropdown-divider"></div> <a class="dropdown-item" href="/apps"><i class="generic-icons-nav fa fa-fw fa-plus-circle"></i>{{$addapps}}</a> @@ -212,7 +256,9 @@ </li> </ul> </div> -<div class="collapse d-md-none" id="navbar-collapse-2"> + + +<div class="collapse d-xl-none" id="navbar-collapse-2"> <div class="navbar-nav mr-auto"> {{if $channel_apps.0}} {{foreach $channel_apps as $channel_app}} diff --git a/view/tpl/new_channel.tpl b/view/tpl/new_channel.tpl index cc1983ac4..c4837064f 100755 --- a/view/tpl/new_channel.tpl +++ b/view/tpl/new_channel.tpl @@ -19,10 +19,10 @@ {{/if}} {{include file="field_input.tpl" field=$name}} - <div id="name-spinner"></div> + <div id="name-spinner" class="spinner-wrapper"><div class="spinner m"></div></div> {{include file="field_input.tpl" field=$nickname}} - <div id="nick-spinner"></div> + <div id="nick-spinner" class="spinner-wrapper"><div class="spinner m"></div></div> <button class="btn btn-primary" type="submit" name="submit" id="newchannel-submit-button" value="{{$submit}}">{{$submit}}</button> <div id="newchannel-submit-end" class="clear"></div> diff --git a/view/tpl/notifications_widget.tpl b/view/tpl/notifications_widget.tpl new file mode 100644 index 000000000..6865879ad --- /dev/null +++ b/view/tpl/notifications_widget.tpl @@ -0,0 +1,62 @@ +<style> + .notification-content { + max-height: 70vh; + overflow: auto; + } + + .notification-content.collapsing { + overflow: hidden; + } + + .fs { + position: fixed; + top: 0px; + left: 0px; + padding: 4.5rem .5rem 1rem .5rem; + background-color: white; + width: 100%; + max-width: 100%; + height: 100%; + z-index: 1029; + overflow: auto; + } + + #notifications { + margin-bottom: 1rem; + } +</style> + +{{if $notifications}} +<div id="notifications_wrapper"> + <div id="notifications" class="navbar-nav" data-children=".nav-item"> + <div id="nav-notifications-template" rel="template"> + <a class="list-group-item clearfix notification {5}" href="{0}" title="{2} {3}"> + <img class="menu-img-3" data-src="{1}"> + <span class="contactname">{2}</span> + <span class="dropdown-sub-text">{3}<br>{4}</span> + </a> + </div> + {{foreach $notifications as $notification}} + <div class="collapse {{$notification.type}}-button"> + <a class="list-group-item" href="#nav-{{$notification.type}}-menu" title="{{$notification.title}}" data-toggle="collapse" data-parent="#notifications" rel="#nav-{{$notification.type}}-menu"> + <i class="fa fa-fw fa-{{$notification.icon}}"></i> {{$notification.label}} + <span class="float-right badge badge-{{$notification.severity}} {{$notification.type}}-update"></span> + </a> + <div id="nav-{{$notification.type}}-menu" class="collapse notification-content" rel="{{$notification.type}}"> + {{if $notification.viewall}} + <a class="list-group-item text-dark" id="nav-{{$notification.type}}-see-all" href="{{$notification.viewall.url}}"> + <i class="fa fa-fw fa-external-link"></i> {{$notification.viewall.label}} + </a> + {{/if}} + {{if $notification.markall}} + <a class="list-group-item text-dark" id="nav-{{$notification.type}}-mark-all" href="{{$notification.markall.url}}" onclick="markRead('{{$notification.type}}'); return false;"> + <i class="fa fa-fw fa-check"></i> {{$notification.markall.label}} + </a> + {{/if}} + {{$loading}} + </div> + </div> + {{/foreach}} + </div> +</div> +{{/if}} diff --git a/view/tpl/notify.tpl b/view/tpl/notify.tpl index ae6e160b1..b5bccc8a4 100755 --- a/view/tpl/notify.tpl +++ b/view/tpl/notify.tpl @@ -1,3 +1,10 @@ -<div class="mb-2 notif-item"> - <a href="{{$item_link}}"><img src="{{$item_image}}" class="menu-img-1">{{$item_text}} <span class="notif-when">{{$item_when}}</span></a> +<div class="mb-4 notif-item"> + {{if ! $item_seen}} + <span class="float-right badge badge-pill badge-success text-uppercase">{{$new}}</span> + {{/if}} + <a href="{{$item_link}}"> + <img src="{{$item_image}}" class="menu-img-3"> + <span class="{{if $item_seen}}text-muted{{/if}}">{{$item_text}}</span><br> + <span class="dropdown-sub-text">{{$item_when}}</span> + </a> </div> diff --git a/view/tpl/pdledit.tpl b/view/tpl/pdledit.tpl index cef93d324..2ea89b6c1 100644 --- a/view/tpl/pdledit.tpl +++ b/view/tpl/pdledit.tpl @@ -5,6 +5,9 @@ <br /> <a href="help/comanche" target="hubzilla-help">{{$help}}</a> +<br> +<br> +<a href="pdledit">{{$another}}</a> <br /> <br /> diff --git a/view/tpl/photo_album.tpl b/view/tpl/photo_album.tpl index 89b169f58..58b843bf0 100755 --- a/view/tpl/photo_album.tpl +++ b/view/tpl/photo_album.tpl @@ -19,7 +19,7 @@ {{$upload_form}} {{$album_edit.1}} <div class="section-content-wrapper-np"> - <div id="photo-album-contents-{{$album_id}}"> + <div id="photo-album-contents-{{$album_id}}" style="display: none"> {{foreach $photos as $photo}} {{include file="photo_top.tpl"}} {{/foreach}} @@ -28,8 +28,12 @@ </div> </div> <div class="photos-end"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> <script> +$(document).ready(function() { loadingPage = false; justifyPhotos('photo-album-contents-{{$album_id}}'); +}); </script> -<div id="page-spinner"></div> diff --git a/view/tpl/photo_album_portfolio.tpl b/view/tpl/photo_album_portfolio.tpl index 7aadbc7e0..1635e0ae1 100755 --- a/view/tpl/photo_album_portfolio.tpl +++ b/view/tpl/photo_album_portfolio.tpl @@ -1,3 +1,39 @@ +{{if isset($mode) && $mode == 'orbit'}} +<div class="row"> + <div class="orbit small-12 medium-9 large-9 columns" id="photo-album-contents-{{$album_id}}" role="region" aria-label="portfolioOrbit-{{$album_id}}" data-orbit data-options="animInFromLeft:fade-in; animInFromRight:fade-in; animOutToLeft:fade-out; animOutToRight:fade-out;"> + + <ul class="orbit-container"> + <button class="orbit-previous"><span class="show-for-sr">Previous Slide</span>◀︎</button> + <button class="orbit-next"><span class="show-for-sr">Next Slide</span>▶︎</button> + {{foreach $photos as $photo}} + {{include file="photo_portfolio_orbit.tpl"}} + {{/foreach}} + </ul> + <nav class="orbit-bullets"> + <button class="is-active" data-slide="0"><span class="show-for-sr">First slide details.</span><span class="show-for-sr">Current Slide</span></button> + <button data-slide="1"><span class="show-for-sr">Second slide details.</span></button> + <button data-slide="2"><span class="show-for-sr">Third slide details.</span></button> + <button data-slide="3"><span class="show-for-sr">Fourth slide details.</span></button> + </nav> + <div id="page-end"></div> + </div> +<div class="photos-end"></div> +<script>$(document).ready(function() { loadingPage = false; justifyPhotos('photo-album-contents-{{$album_id}}'); });</script> +<div id="page-spinner"></div> +</div> +{{elseif isset($mode) && $mode =='card'}} +<div class="row"> + <div class="small-12 medium-9 large-9 columns" id="photo-album-contents-{{$album_id}}"> + {{foreach $photos as $photo}} + {{include file="photo_portfolio_card.tpl"}} + {{/foreach}} + <div id="page-end"></div> + </div> +<div class="photos-end"></div> +<script>$(document).ready(function() { loadingPage = false; justifyPhotos('photo-album-contents-{{$album_id}}'); });</script> +<div id="page-spinner"></div> +</div> +{{else}} <div class="row column"> <div id="photo-album-contents-{{$album_id}}"> {{foreach $photos as $photo}} @@ -8,4 +44,6 @@ <div class="photos-end"></div> <script>$(document).ready(function() { loadingPage = false; justifyPhotos('photo-album-contents-{{$album_id}}'); });</script> <div id="page-spinner"></div> -</div>
\ No newline at end of file +</div> +{{/if}} + diff --git a/view/tpl/photo_portfolio_card.tpl b/view/tpl/photo_portfolio_card.tpl new file mode 100644 index 000000000..5fddd3d37 --- /dev/null +++ b/view/tpl/photo_portfolio_card.tpl @@ -0,0 +1,6 @@ +<div class="card" style="width: 300px;box-shadow: 0px 10px 6px -6px rgba(119,119,119,0.6);border-style: solid;border-width: 1px;border=color: rgba(230,230,230,0.6);margin:10px 5px 10px 5px;"> + <img src="{{$photo.src}}" alt="{{if $photo.album.name}}{{$photo.album.name}}{{elseif $photo.desc}}{{$photo.desc}}{{elseif $photo.alt}}{{$photo.alt}}{{else}}{{$photo.unknown}}{{/if}}" title="{{$photo.desc}}" id="photo-top-photo-{{$photo.resource_id}}"> + <div class="card-divider"> + <h4>{{$photo.desc}}</h4> + </div> +</div> diff --git a/view/tpl/photo_portfolio_orbit.tpl b/view/tpl/photo_portfolio_orbit.tpl new file mode 100644 index 000000000..b2883265c --- /dev/null +++ b/view/tpl/photo_portfolio_orbit.tpl @@ -0,0 +1,5 @@ + + <li class="orbit-slide"> + <img class="orbit-image" src="{{$photo.src}}" alt="{{if $photo.album.name}}{{$photo.album.name}}{{elseif $photo.desc}}{{$photo.desc}}{{elseif $photo.alt}}{{$photo.alt}}{{else}}{{$photo.unknown}}{{/if}}" title="{{$photo.desc}}" id="photo-top-photo-{{$photo.resource_id}}o"> + <figcaption class="orbit-caption">{{$photo.desc}}</figcaption> + </li> diff --git a/view/tpl/photos_recent.tpl b/view/tpl/photos_recent.tpl index c6a9067c1..a9574aade 100755 --- a/view/tpl/photos_recent.tpl +++ b/view/tpl/photos_recent.tpl @@ -10,7 +10,7 @@ </div> {{$upload_form}} <div class="section-content-wrapper-np"> - <div id="photo-album-contents-{{$album_id}}"> + <div id="photo-album-contents-{{$album_id}}" style="display: none"> {{foreach $photos as $photo}} {{include file="photo_top.tpl"}} {{/foreach}} @@ -19,8 +19,12 @@ </div> </div> <div class="photos-end"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> <script> +$(document).ready(function() { loadingPage = false; justifyPhotos('photo-album-contents-{{$album_id}}'); +}); </script> -<div id="page-spinner"></div> diff --git a/view/tpl/profile_tabs.tpl b/view/tpl/profile_tabs.tpl index 49b74bb8f..72e98ae82 100644 --- a/view/tpl/profile_tabs.tpl +++ b/view/tpl/profile_tabs.tpl @@ -1,5 +1,4 @@ -<div class="dropdown-header"><img src="{{$thumb}}" class="menu-img-1">{{$name}}:</div> +<div class="dropdown-header"><img src="{{$thumb}}" class="menu-img-1">{{$name}}</div> {{foreach $tabs as $tab}} <a class="dropdown-item{{if $tab.sel}} {{$tab.sel}}{{/if}}" href="{{$tab.url}}"{{if $tab.title}} title="{{$tab.title}}"{{/if}}><i class="fa fa-fw fa-{{$tab.icon}} generic-icons-nav"></i>{{$tab.label}}</a> {{/foreach}} -<div class="dropdown-divider"></div> diff --git a/view/tpl/profile_vcard.tpl b/view/tpl/profile_vcard.tpl index f51f0719c..0f30e5816 100755 --- a/view/tpl/profile_vcard.tpl +++ b/view/tpl/profile_vcard.tpl @@ -7,17 +7,15 @@ {{/if}} {{if ! $zcard}} {{if $editmenu.multi}} - <div class="dropdown"> - <a class="profile-edit-side-link dropdown-toggle" data-toggle="dropdown" href="#" ><i class="fa fa-pencil" title="{{$editmenu.edit.1}}"></i></a> - <ul class="dropdown-menu" role="menu"> - {{foreach $editmenu.menu.entries as $e}} - <li> - <a href="profiles/{{$e.id}}"><img class="dropdown-menu-img-xs" src='{{$e.photo}}'>{{$e.profile_name}}</a> - </li> - {{/foreach}} - <li><a href="profile_photo" >{{$editmenu.menu.chg_photo}}</a></li> - {{if $editmenu.menu.cr_new}}<li><a href="profiles/new" id="profile-listing-new-link">{{$editmenu.menu.cr_new}}</a></li>{{/if}} - </ul> + <div class="dropdown float-right"> + <a class="dropdown-toggle" data-toggle="dropdown" href="#" ><i class="fa fa-pencil" title="{{$editmenu.edit.1}}"></i></a> + <div class="dropdown-menu dropdown-menu-right" role="menu"> + {{foreach $editmenu.menu.entries as $e}} + <a href="profiles/{{$e.id}}" class="dropdown-item"><img class="menu-img-1" src='{{$e.photo}}'>{{$e.profile_name}}</a> + {{/foreach}} + <a href="profile_photo" class="dropdown-item">{{$editmenu.menu.chg_photo}}</a> + {{if $editmenu.menu.cr_new}}<a href="profiles/new" id="profile-listing-new-link" class="dropdown-item">{{$editmenu.menu.cr_new}}</a>{{/if}} + </div> </div> {{elseif $editmenu}} <a class="profile-edit-side-link" href="{{$editmenu.edit.0}}" ><i class="fa fa-pencil" title="{{$editmenu.edit.1}}"></i></a> diff --git a/view/tpl/prv_message.tpl b/view/tpl/prv_message.tpl index af6315c7e..59472f7d4 100755 --- a/view/tpl/prv_message.tpl +++ b/view/tpl/prv_message.tpl @@ -5,7 +5,7 @@ </div> <div class="section-content-wrapper"> {{/if}} - <div id="prvmail-wrapper" > + <div id="prvmail-wrapper"> <input id="invisible-wall-file-upload" type="file" name="files" style="visibility:hidden;position:absolute;top:-50;left:-50;width:0;height:0;" multiple> <form id="prvmail-form" action="mail" method="post" > <input type="hidden" id="inp-prvmail-expires" name="expires" value="{{$defexpire}}" /> @@ -31,12 +31,12 @@ <label for="prvmail-text">{{$yourmessage}}</label> <textarea class="form-control" id="prvmail-text" name="body"{{if $new}} style="height: 10em;"{{/if}}>{{$text}}</textarea> </div> - <div id="prvmail-submit-wrapper" class="form-group"> + <div id="prvmail-submit-wrapper" class="form-group clearfix"> <div id="prvmail-submit" class="float-right btn-group"> <button class="btn btn-outline-secondary btn-sm" id="prvmail-preview" title="{{$preview}}" onclick="preview_mail(); return false;"><i class="fa fa-eye"></i></button> <button class="btn btn-primary btn-sm" type="submit" id="prvmail-submit" name="submit" value="{{$submit}}">{{$submit}}</button> </div> - <div id="prvmail-tools" class="btn-toolbar float-left"> + <div id="prvmail-tools" class="btn-toolbar"> <div class="btn-group mr-2"> <button id="main-editor-bold" class="btn btn-outline-secondary btn-sm" title="{{$bold}}" onclick="inserteditortag('b', 'prvmail-text'); return false;"> <i class="fa fa-bold jot-icons"></i> @@ -63,7 +63,7 @@ </button> </div> {{if $feature_expire || $feature_encrypt}} - <div class="btn-group d-none d-lg-flex mr-2"> + <div class="btn-group d-none d-lg-flex"> {{if $feature_expire}} <button id="prvmail-expire-wrapper" class="btn btn-outline-secondary btn-sm" onclick="prvmailGetExpiry();return false;" > <i id="prvmail-expires" class="fa fa-eraser jot-icons" title="{{$expires}}" ></i> @@ -90,11 +90,12 @@ {{/if}} </div> </div> + <div class="btn-group"> + <div id="prvmail-rotator" class="m-2 spinner-wrapper"> + <div class="spinner s"></div> + </div> + </div> </div> - <div id="prvmail-rotator-wrapper" class="float-left"> - <div id="prvmail-rotator"></div> - </div> - <div class="clear"></div> </div> <div id="mail-preview-content" style="display: none;"></div> </form> diff --git a/view/tpl/register.tpl b/view/tpl/register.tpl index c84934626..493dba4c8 100755 --- a/view/tpl/register.tpl +++ b/view/tpl/register.tpl @@ -39,10 +39,10 @@ {{/if}} {{include file="field_input.tpl" field=$name}} - <div id="name-spinner"></div> + <div id="name-spinner" class="spinner-wrapper"><div class="spinner m"></div></div> {{include file="field_input.tpl" field=$nickname}} - <div id="nick-spinner"></div> + <div id="nick-spinner" class="spinner-wrapper"><div class="spinner m"></div></div> {{/if}} {{if $enable_tos}} diff --git a/view/tpl/remote_friends_common.tpl b/view/tpl/remote_friends_common.tpl index d6d2fd211..9e149b574 100755 --- a/view/tpl/remote_friends_common.tpl +++ b/view/tpl/remote_friends_common.tpl @@ -1,21 +1,16 @@ -<div id="remote-friends-in-common" class="bigwidget"> - <div id="rfic-desc">{{$desc}} {{if $linkmore}}<a href="{{$base}}/common/{{$uid}}">{{$more}}</a>{{/if}}</div> +<div class="widget"> + <h3>{{$desc}}</h3> + {{if $linkmore}} + <a class="allcontact-link" href="{{$base}}/common/{{$uid}}">{{$more}}</a> + {{/if}} {{if $items}} - {{foreach $items as $item}} - <div class="profile-match-wrapper"> - <div class="profile-match-photo"> - <a href="{{$base}}/chanview?f=&url={{$item.xchan_url}}"> - <img src="{{$item.xchan_photo_m}}" width="80" height="80" alt="{{$item.xchan_name}}" title="{{$item.xchan_name}}" /> - </a> - </div> - <div class="profile-match-break"></div> - <div class="profile-match-name"> - <a href="{{$base}}/chanview?f=&url={{$item.xchan_url}}" title="{{$item.xchan_name}}">{{$item.xchan_name}}</a> + <div class="contact-block-content"> + {{foreach $items as $item}} + <div class="contact-block-div"> + <a class="contact-block-link mpfriend" href="{{$base}}/chanview?f=&url={{$item.xchan_url}}"><img class="contact-block-img mpfriend" src="{{$item.xchan_photo_s}}"alt="{{$item.xchan_name}}" title="{{$item.xchan_name}} [{{$item.xchan_addr}}]" /></a> </div> - <div class="profile-match-end"></div> + {{/foreach}} </div> - {{/foreach}} {{/if}} - <div id="rfic-end" class="clear"></div> -</div> +<div> diff --git a/view/tpl/search_item.tpl b/view/tpl/search_item.tpl index aaafe9797..0a8f12d4f 100755 --- a/view/tpl/search_item.tpl +++ b/view/tpl/search_item.tpl @@ -1,4 +1,4 @@ -<div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} mb-4 clearfix generic-content-wrapper{{/if}}"> +<div id="thread-wrapper-{{$item.id}}" class="thread-wrapper{{if $item.toplevel}} {{$item.toplevel}} clearfix generic-content-wrapper{{/if}}"> <a name="{{$item.id}}" ></a> <div class="clearfix wall-item-outside-wrapper {{$item.indent}}{{$item.previewing}}{{if $item.owner_url}} wallwall{{/if}}" id="wall-item-outside-wrapper-{{$item.id}}" > <div class="wall-item-content-wrapper {{$item.indent}}" id="wall-item-content-wrapper-{{$item.id}}"> @@ -32,6 +32,7 @@ </div> {{/if}} <div class="wall-item-author"> + {{if $item.previewing}}<span class="preview-indicator"><i class="fa fa-eye" title="{{$item.preview_lbl}}"></i></span> {{/if}} <a href="{{$item.profile_url}}" title="{{$item.linktitle}}" class="wall-item-name-link"><span class="wall-item-name{{$item.sparkle}}" id="wall-item-name-{{$item.id}}" >{{$item.name}}</span></a>{{if $item.owner_url}} {{$item.via}} <a href="{{$item.owner_url}}" title="{{$item.olinktitle}}" class="wall-item-name-link"><span class="wall-item-name{{$item.osparkle}}" id="wall-item-ownername-{{$item.id}}">{{$item.owner_name}}</span></a>{{/if}} </div> <div class="wall-item-ago" id="wall-item-ago-{{$item.id}}"> diff --git a/view/tpl/settings.tpl b/view/tpl/settings.tpl index 6673e5815..704d89bdd 100755 --- a/view/tpl/settings.tpl +++ b/view/tpl/settings.tpl @@ -46,7 +46,6 @@ <div class="section-content-tools-wrapper"> {{include file="field_select_grouped.tpl" field=$role}} <div id="advanced-perm" style="display:{{if $permissions_set}}none{{else}}block{{/if}};"> - <div class="form-group"> <button type="button" class="btn btn-outline-secondary" data-toggle="modal" data-target="#apsModal">{{$lbl_p2macro}}</button> </div> @@ -54,8 +53,8 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> <h4 class="modal-title">{{$lbl_p2macro}}</h4> + <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> </div> <div class="modal-body"> {{foreach $permiss_arr as $permit}} @@ -137,6 +136,10 @@ {{include file="field_intcheckbox.tpl" field=$vnotify8}} {{include file="field_intcheckbox.tpl" field=$vnotify9}} {{include file="field_intcheckbox.tpl" field=$vnotify11}} + {{include file="field_intcheckbox.tpl" field=$vnotify12}} + {{if $vnotify13}} + {{include file="field_intcheckbox.tpl" field=$vnotify13}} + {{/if}} {{include file="field_intcheckbox.tpl" field=$always_show_in_notices}} {{include file="field_input.tpl" field=$evdays}} </div> diff --git a/view/tpl/sharedwithme.tpl b/view/tpl/sharedwithme.tpl index 68bdd6faa..8474ccd52 100644 --- a/view/tpl/sharedwithme.tpl +++ b/view/tpl/sharedwithme.tpl @@ -15,7 +15,7 @@ {{foreach $items as $item}} <tr id="cloud-index-{{$item.id}}"> <td><i class="fa {{$item.objfiletypeclass}}" title="{{$item.objfiletype}}"></i></td> - <td><a href="{{$item.objurl}}">{{$item.objfilename}}</a>{{if $item.unseen}} <span class="label label-success">{{$label_new}}</span>{{/if}}</td> + <td><a href="{{$item.objurl}}">{{$item.objfilename}}</a>{{if $item.unseen}} <span class="badge badge-pill badge-success">{{$label_new}}</span>{{/if}}</td> <td class="cloud-index-tool"><a href="#" title="{{$drop}}" onclick="dropItem('/sharedwithme/{{$item.id}}/drop', '#cloud-index-{{$item.id}}'); return false;"><i class="fa fa-trash-o drop-icons"></i></a></td> <td class="d-none d-md-table-cell">{{$item.objfilesize}}</td> <td class="d-none d-md-table-cell">{{$item.objedited}}</td> diff --git a/view/tpl/threaded_conversation.tpl b/view/tpl/threaded_conversation.tpl index ea5c3c281..5bc7d8386 100755 --- a/view/tpl/threaded_conversation.tpl +++ b/view/tpl/threaded_conversation.tpl @@ -1,8 +1,9 @@ +<div id="threads-begin"></div> {{if $photo_item}} {{$photo_item}} {{/if}} {{foreach $threads as $thread_item}} {{include file="{{$thread_item.template}}" item=$thread_item}} {{/foreach}} - +<div id="threads-end"></div> <div id="conversation-end"></div> diff --git a/view/tpl/viewcontact_template.tpl b/view/tpl/viewcontact_template.tpl index 2b7144450..005fe17ce 100755 --- a/view/tpl/viewcontact_template.tpl +++ b/view/tpl/viewcontact_template.tpl @@ -10,4 +10,6 @@ </div> </div> <script>$(document).ready(function() { loadingPage = false;});</script> -<div id="page-spinner"></div> +<div id="page-spinner" class="spinner-wrapper"> + <div class="spinner m"></div> +</div> diff --git a/view/tpl/wiki.tpl b/view/tpl/wiki.tpl index 7cd3708b8..22480be5b 100644 --- a/view/tpl/wiki.tpl +++ b/view/tpl/wiki.tpl @@ -1,6 +1,7 @@ -<div class="generic-content-wrapper" {{if $hideEditor}}style="display: none;"{{/if}}> +<div class="generic-content-wrapper"> <div class="section-title-wrapper"> <div class="pull-right"> + <span class="text-muted wiki-typename">[{{$typename}}] </span> {{if $showPageControls}} <div id="page-tools" class="btn-group" style="display: none;"> <button type="button" class="btn btn-outline-secondary btn-sm dropdown-toggle" data-toggle="dropdown"> @@ -52,18 +53,6 @@ <textarea id="editor">{{$content}}</textarea> </div> {{/if}} - {{if $showPageControls}} - <div> - <div id="id_{{$commitMsg.0}}_wrapper" class="field input"> - <div class="input-group"> - <input class="form-control form-control-sm" name="{{$commitMsg.0}}" id="id_{{$commitMsg.0}}" type="text" value="{{$commitMsg.2}}"{{if $commitMsg.5}} {{$commitMsg.5}}{{/if}}> - <div class="input-group-btn"> - <button id="save-page" type="button" class="btn btn-primary disabled">Save</button> - </div> - </div> - </div> - </div> - {{/if}} </div> <div id="preview-pane" class="tab-pane active"> <div id="wiki-preview"> @@ -73,6 +62,16 @@ <div id="page-history-pane" class="tab-pane"> <div id="page-history-list"></div> </div> + {{if $showPageControls}} + <div id="id_{{$commitMsg.0}}_wrapper" class="field input" style="display: none"> + <div class="input-group"> + <input class="form-control form-control-sm" name="{{$commitMsg.0}}" id="id_{{$commitMsg.0}}" type="text" value="{{$commitMsg.2}}"{{if $commitMsg.5}} {{$commitMsg.5}}{{/if}}> + <div class="input-group-btn"> + <button id="save-page" type="button" class="btn btn-primary disabled">Save</button> + </div> + </div> + </div> + {{/if}} </div> </div> </div> @@ -105,6 +104,7 @@ window.wiki_page_name = '{{$page}}'; window.wiki_page_content = '{{$content|escape:'javascript'}}'; window.wiki_page_commit = '{{$commit}}'; + window.saved = true; $("#generic-modal-ok-{{$wikiModalID}}").removeClass('btn-primary'); $("#generic-modal-ok-{{$wikiModalID}}").addClass('btn-danger'); @@ -173,43 +173,54 @@ adjustInlineEditorHeight(); } }, 500); // Return the focus to the editor allowing immediate text entry - $('#page-tools').show(); + $('#page-tools, #id_{{$commitMsg.0}}_wrapper').show(); }); $('#wiki-get-preview').click(function (ev) { + if(window.saved) { + $('#page-tools, #id_{{$commitMsg.0}}_wrapper').hide(); + } + else { + $('#page-tools').hide(); + } $.post("wiki/{{$channel_address}}/preview", { {{if !$mimeType || $mimeType == 'text/markdown'}} content: editor.getValue(), {{else}} content: editor.val(), {{/if}} - resource_id: window.wiki_resource_id + resource_id: window.wiki_resource_id, + mimetype: '{{$mimeType}}' }, function (data) { - if (data.success) { - $('#wiki-preview').html(data.html); - {{if !$mimeType || $mimeType == 'text/markdown'}} - $("#wiki-toc").toc({content: "#wiki-preview", headings: "h1,h2,h3,h4"}); - {{/if}} - $('#page-tools').hide(); - } else { - window.console.log('Error previewing page.'); - } + if (data.success) { + $('#wiki-preview').html(data.html); + {{if !$mimeType || $mimeType == 'text/markdown'}} + $("#wiki-toc").toc({content: "#wiki-preview", headings: "h1,h2,h3,h4"}); + {{/if}} + } else { + window.console.log('Error previewing page.'); + } }, 'json'); ev.preventDefault(); }); $('#wiki-get-history').click(function (ev) { + if(window.saved) { + $('#page-tools, #id_{{$commitMsg.0}}_wrapper').hide(); + } + else { + $('#page-tools').hide(); + } $.post("wiki/{{$channel_address}}/history/page", {name: window.wiki_page_name, resource_id: window.wiki_resource_id}, function (data) { if (data.success) { $('#page-history-list').html(data.historyHTML); - $('#page-tools').hide(); } else { window.console.log('Error getting page history.'); } - }, 'json'); - ev.preventDefault(); - }); + }, 'json'); + ev.preventDefault(); + }); function wiki_refresh_page_list() { if (window.wiki_resource_id === '') { @@ -252,6 +263,7 @@ }, function (data) { if (data.success) { + window.saved = true; window.console.log('Page saved successfully.'); window.wiki_page_content = currentContent; $('#id_commitMsg').val(''); // Clear the commit message box @@ -444,6 +456,7 @@ {{if !$mimeType || $mimeType == 'text/markdown'}} $("#wiki-toc").toc({content: "#wiki-preview", headings: "h1,h2,h3,h4"}); window.editor.on("input", function() { + window.saved = false; if(window.editor.getSession().getUndoManager().isClean()) { $('#save-page').addClass('disabled'); } else { @@ -452,10 +465,13 @@ }); {{else}} window.editor.on("input", function() { + window.saved = false; $('#save-page').removeClass('disabled'); }); + {{if $mimeType == 'text/bbcode'}} window.editor.bbco_autocomplete('bbcode'); {{/if}} + {{/if}} }); $(window).resize(function () { diff --git a/view/tpl/wiki_page_list.tpl b/view/tpl/wiki_page_list.tpl index 6d09fcd5d..d75f22f64 100644 --- a/view/tpl/wiki_page_list.tpl +++ b/view/tpl/wiki_page_list.tpl @@ -7,25 +7,35 @@ {{foreach $pages as $page}} <li class="nav-item nav-item-hack" id="{{$page.link_id}}"> {{if $page.resource_id && $candel}} - <i class="nav-link widget-nav-pills-icons fa fa-trash-o drop-icons" onclick="wiki_delete_page('{{$page.title}}', '{{$page.url}}', '{{$page.resource_id}}', '{{$page.link_id}}')"></i> + <i class="nav-link widget-nav-pills-icons fa fa-trash-o drop-icons" onclick="wiki_delete_page('{{$page.title}}', '{{$page.title}}', '{{$page.resource_id}}', '{{$page.link_id}}')"></i> {{/if}} <a class="nav-link" href="/wiki/{{$channel_address}}/{{$wikiname}}/{{$page.url}}">{{$page.title}}</a> </li> {{/foreach}} {{/if}} {{if $canadd}} - <li class="nav-item"><a class="nav-link" href="#" onclick="wiki_show_new_page_form(); return false;"><i class="fa fa-plus-circle"></i> {{$addnew}}</a></li> + <li class="nav-item"><a class="nav-link" href="#" onclick="wiki_show_new_page_form(); return false;"><i class="fa fa-plus-circle"></i> {{$addnew}}</a></li> + {{/if}} + {{if $canadd}} + <div id="new-page-form-wrapper" class="clearfix sub-menu" style="display:none;"> + <form id="new-page-form" action="wiki/{{$channel_address}}/create/page" method="post" > + <input type="hidden" name="resource_id" value="{{$resource_id}}"> + {{include file="field_input.tpl" field=$pageName}} + {{if $typelock}} + <input id="id_mimetype" type="hidden" name="mimetype" value="{{$lockedtype}}"> + {{else}} + <div id="wiki_page_options" style="display: none"> + {{$mimetype}} + </div> + <div class="float-right fakelink" onClick="openClose('wiki_page_options')"> + {{$options}} + </div> + {{/if}} + <button id="new-page-submit" class="btn btn-primary" type="submit" name="submit" >{{$submit}}</button> + </form> + </div> {{/if}} </ul> - {{if $canadd}} - <div id="new-page-form-wrapper" class="sub-menu" style="display:none;"> - <form id="new-page-form" action="wiki/{{$channel_address}}/create/page" method="post" > - <input type="hidden" name="resource_id" value="{{$resource_id}}"> - {{include file="field_input.tpl" field=$pageName}} - <button id="new-page-submit" class="btn btn-primary" type="submit" name="submit" >Submit</button> - </form> - </div> - {{/if}} {{if ! $refresh}} </div> {{/if}} @@ -33,7 +43,7 @@ {{if $canadd}} <script> $('#new-page-submit').click(function (ev) { - $.post("wiki/{{$channel_address}}/create/page", {pageName: $('#id_pageName').val(), resource_id: window.wiki_resource_id}, + $.post("wiki/{{$channel_address}}/create/page", {pageName: $('#id_pageName').val(), resource_id: window.wiki_resource_id, mimetype: $('#id_mimetype').val() }, function(data) { if(data.success) { window.location = data.url; diff --git a/view/tpl/wikilist.tpl b/view/tpl/wikilist.tpl index 2deec76c0..801cb17fd 100644 --- a/view/tpl/wikilist.tpl +++ b/view/tpl/wikilist.tpl @@ -10,6 +10,7 @@ <form id="new-wiki-form" action="wiki/{{$channel}}/create/wiki" method="post" class="acl-form" data-form_id="new-wiki-form" data-allow_cid='{{$allow_cid}}' data-allow_gid='{{$allow_gid}}' data-deny_cid='{{$deny_cid}}' data-deny_gid='{{$deny_gid}}'> {{include file="field_input.tpl" field=$wikiName}} {{include file="field_select.tpl" field=$mimeType}} + {{include file="field_checkbox.tpl" field=$typelock}} {{include file="field_checkbox.tpl" field=$notify}} <div> <div class="btn-group pull-right"> @@ -20,7 +21,6 @@ </div> </div> </form> - {{$acl}} <div class="clear"></div> </div> {{/if}} @@ -29,8 +29,11 @@ <tr> <th width="96%">{{$name}}</th> <th width="1%">{{$type}}</th> - <th width="1%" class="wikis-index-tool"></th> - <!-- th width="1%" class="wikis-index-tool"></th --> + <th width="1%"></th> + {{if $owner}} + <th width="1%"></th> + {{/if}} + <th width="1%"></th> {{if $owner}} <th width="1%"></th> {{/if}} @@ -38,22 +41,42 @@ {{foreach $wikis as $wiki}} <tr class="wikis-index-row"> <td><a href="/wiki/{{$channel}}/{{$wiki.urlName}}/Home" title="{{$view}}"{{if $wiki.active}} class="active"{{/if}}>{{$wiki.title}}</a></td> - <td>{{$wiki.mimeType}}</td> - <td class="wiki-index-tool dropdown"> - {{if $wiki.lock}} - <i class="fa fa-lock lockview" data-toggle="dropdown" onclick="lockview('item',{{$wiki.id}});"></i></button> + <td>{{if $wiki.typelock}}{{$wiki.mimeType}}{{else}}{{$unlocked}}{{/if}}</td> + {{if $owner}} + <td><i class="fa fa-pencil" onclick="openCloseTR('wikis-index-edit-{{$wiki.id}}')"></i></td> + {{/if}} + <td class="dropdown"> + {{if $wiki.lockstate == 'lock'}} + <i class="fa fa-lock lockview" data-toggle="dropdown" onclick="lockview('item',{{$wiki.id}});"></i> <ul id="panel-{{$wiki.id}}" class="lockview-panel dropdown-menu dropdown-menu-right"></ul> {{/if}} </td> - <!-- td class="wiki-index-tool"><i class="fa fa-download fakelink" onclick="wiki_download_wiki('{{$wiki.resource_id}}'); return false;"></i></td --> + <td><i class="fa fa-download" onclick="wiki_download_wiki('{{$wiki.resource_id}}'); return false;"></i></td> {{if $owner}} <td><i class="fa fa-trash-o drop-icons" onclick="wiki_delete_wiki('{{$wiki.title}}', '{{$wiki.resource_id}}'); return false;"></i></td> {{/if}} </tr> + {{if $owner}} + <tr id="wikis-index-edit-{{$wiki.id}}" style="display:none"> + <td colspan="6"> + <form id="edit-wiki-form-{{$wiki.id}}" method="post" action="wiki/{{$channel}}/update/wiki" class="acl-form" data-form_id="edit-wiki-form-{{$wiki.id}}" data-allow_cid='{{$wiki.json_allow_cid}}' data-allow_gid='{{$wiki.json_allow_gid}}' data-deny_cid='{{$wiki.json_deny_cid}}' data-deny_gid='{{$wiki.json_deny_gid}}'> + <input type="hidden" name="origRawName" value="{{$wiki.title}}"> + {{include file="field_input.tpl" field=['updateRawName', $edit_wiki_name, $wiki.title]}} + <div class="btn-group float-right"> + <button class="btn btn-outline-secondary btn-sm" data-toggle="modal" data-target="#aclModal" type="button"> + <i class="jot-perms-icon fa fa-{{$wiki.lockstate}}"></i> + </button> + <button class="btn btn-primary btn-sm" type="submit" value="edit">Submit</button> + </div> + </form> + </td> + </tr> + {{/if}} {{/foreach}} </table> </div> </div> +{{$acl}} <script> {{if $owner}} function wiki_delete_wiki(wikiHtmlName, resource_id) { |