From 1411eafa9b5411df9cfbd8b563025a6665a0a7db Mon Sep 17 00:00:00 2001 From: Mario Date: Fri, 18 Oct 2024 19:06:35 +0000 Subject: fix edit button not clickable if below right aside --- view/tpl/page_display.tpl | 2 +- view/tpl/page_display_empty.tpl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'view/tpl') diff --git a/view/tpl/page_display.tpl b/view/tpl/page_display.tpl index e8c9c0e27..2e87c68e3 100644 --- a/view/tpl/page_display.tpl +++ b/view/tpl/page_display.tpl @@ -10,7 +10,7 @@
{{$date}}
{{$body}}
{{if $edit_link}} -
+
{{/if}} diff --git a/view/tpl/page_display_empty.tpl b/view/tpl/page_display_empty.tpl index 44baec361..c24fe08e5 100644 --- a/view/tpl/page_display_empty.tpl +++ b/view/tpl/page_display_empty.tpl @@ -1,6 +1,6 @@ {{$body}} {{if $edit_link}}
- +
{{/if}} -- cgit v1.2.3 From 4d1be3aea583c26c6e24e88b464d5a366a4d2ef3 Mon Sep 17 00:00:00 2001 From: Mario Date: Sat, 19 Oct 2024 18:49:47 +0000 Subject: bring filed items to mod hq --- view/tpl/messages_widget.tpl | 55 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 50 insertions(+), 5 deletions(-) (limited to 'view/tpl') diff --git a/view/tpl/messages_widget.tpl b/view/tpl/messages_widget.tpl index 52a9b96f4..df91a05ef 100644 --- a/view/tpl/messages_widget.tpl +++ b/view/tpl/messages_widget.tpl @@ -16,6 +16,13 @@ {{/if}} + {{if $feature_file}} + + {{/if}}
+ {{if $feature_file}} +
+
+ + + {{foreach $file_tags as $opt=>$val}} + +
+
+ {{/if}} {{foreach $entries as $e}}
@@ -75,7 +94,7 @@
{{$e.info}} {{if $e.unseen_count}} - {{$e.unseen_count}} + {{$e.unseen_count}} {{/if}}
{{/foreach}} @@ -94,6 +113,7 @@ let author_hash; let author_url; let author; + let file; $(document).ready(function () { $('.messages-timeago').timeago(); @@ -109,6 +129,7 @@ $('#messages-container .message').remove(); $('#messages-author-container').addClass('active sticky-top'); $('#messages-author-input-clear').removeClass('d-none'); + author_hash = data.xid; author_url = data.url; author = messages_type === 'notification' ? author_url : author_hash; @@ -116,14 +137,27 @@ get_messages_page(); }); - $(document).on('click', '#messages-author-input-clear', function() { - $('#messages-author').val(''); + $("#messages-file").on('change', function(data) { + file = $("#messages-file").val(); + + $('#messages-container .message').remove(); + $('#messages-file-container').addClass('active sticky-top'); + $('#messages-file-input-clear').removeClass('d-none'); + + messages_offset = 0; + get_messages_page(); + }); + + $(document).on('click', '#messages-author-input-clear, #messages-file-input-clear', function() { + $('#messages-author, #messages-file').val(''); $("#messages-author").attr('placeholder', '{{$strings.filter}}'); + $("#messages-file").attr('placeholder', '{{$strings.file_filter}}'); $('#messages-author-container').removeClass('active sticky-top'); $('#messages-author-input-clear').addClass('d-none'); $('#messages-container .message').remove(); author = ''; + file = ''; author_hash = ''; author_url = ''; messages_offset = 0; @@ -145,6 +179,16 @@ messages_offset = 0; messages_type = $(this).data('messages_type'); author = messages_type === 'notification' ? author_url : author_hash; + + if (messages_type === 'filed') { + $('#messages-author-container').addClass('d-none'); + $('#messages-file-container').removeClass('d-none'); + } + else { + $('#messages-author-container').removeClass('d-none'); + $('#messages-file-container').addClass('d-none'); + } + $('#messages-container .message').remove(); get_messages_page(); }); @@ -167,7 +211,8 @@ data: { offset: messages_offset, type: messages_type, - author: author + author: author, + file: file } }).done(function(obj) { get_messages_page_active = false; @@ -185,7 +230,7 @@ e.author_addr, e.href, e.icon, - e.unseen_count ? '' + e.unseen_count + '' : '', + e.unseen_count ? '' + e.unseen_count + '' : '', e.author_img ); $('#messages-loading').before(html); -- cgit v1.2.3