|
|
|
<?php
|
|
|
|
$actual_view = Minz_Request::actionName();
|
|
|
|
$class = '';
|
|
|
|
if (FreshRSS_Context::$user_conf->hide_read_feeds &&
|
|
|
|
FreshRSS_Context::isStateEnabled(FreshRSS_Entry::STATE_NOT_READ) &&
|
|
|
|
!FreshRSS_Context::isStateEnabled(FreshRSS_Entry::STATE_READ)) {
|
|
|
|
$class = ' state_unread';
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
|
|
|
|
<div class="aside aside_feed<?php echo $class; ?>" id="aside_feed">
|
|
|
|
<a class="toggle_aside" href="#close"><?php echo _i('close'); ?></a>
|
|
|
|
|
|
|
|
<?php if (FreshRSS_Auth::hasAccess()) { ?>
|
|
|
|
<div class="stick configure-feeds no-mobile">
|
|
|
|
<a id="btn-subscription" class="btn btn-important" href="<?php echo _url('subscription', 'index'); ?>"><?php echo _t('index.menu.subscription'); ?></a>
|
|
|
|
<a id="btn-importExport" class="btn btn-important" href="<?php echo _url('importExport', 'index'); ?>"><?php echo _i('import'); ?></a>
|
|
|
|
</div>
|
|
|
|
<?php } elseif (FreshRSS_Auth::accessNeedsLogin()) { ?>
|
|
|
|
<a href="<?php echo _url('index', 'about'); ?>"><?php echo _t('index.menu.about'); ?></a>
|
|
|
|
<?php } ?>
|
|
|
|
|
|
|
|
<form id="mark-read-aside" method="post">
|
|
|
|
<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
|
Decouple scrolling of feeds and articles (#2117)
* Remove Sticky Kit
Remove sticky-kit, as functionality is unsuitable for separate scrolling.
* Remove sticky-kit load in main.js
Further removing the sticky-kit kruft
* Finish removal of references to Sticky-kit
* CSS Changes to template for Independent Scrolling
* Addition of JS and supporting CSS and html
* More CSS fixes to establish expected behavior
Should be able to scroll navbar without it being in sticky mode now.
* Fix typo in main.js
sortcut.js -> shortcut.js
* Fix unexpected tree scrolling behavior
* Change name of generic JS function
* Improve sticky-aside
* CSS changes in themes to accommodate independent Scroll
In themes where .aside's width is not the standard 300px, .tree's width must be specified to be equal to .aside
* Remove Sticky-Kit from README files
* Updates to Sticky-Aside
* Update Template to fix screwup
* Make Recalculating height actually work
* Let sidebar fill height if nav buttons aren't visible
* Make accommodating for nav buttons actually work
* update Swage theme for Independent Scroll feature
* Integrate sticky_aside into main.js
* Add Simple Scrollbar
* Patch scrollbar color for themes with dark colored asides
* Increase Visibility of scrollbar on Dark Themes
* Improve async loading, events, and performance
* CSS typo
* Fix double scrollbar on mobile
* Fix regression causing sticky to not be removed
* No $ for non-jQuery variables
* Fix strange condition + option for nice scrollbar
* Initial attempt to use css sticky
* Add stickyfill
* make the correct element sticky
* re-add incorrectly removed sidebar code
* Continue fixing mistaken deletions
* decrease frequency of recalc
* use minified version of simple-scrollbar.
* Load stickyfill instead of injecting
* put recalc back where it belongs
* re-remove script injector
* remove padding
bottom padding was causing the last item in the feed to be hidden under the nav buttons
* Manual merge of css_scrollbar
Add auto-detection of -webkit-scrollbar-thumb, otherwise fall back to
simple-scrollbar.js
* Fix Regression
Sticky recalc is still needed when using css scrollbars
* Replace method of closing dropdowns
Changed from an overlay href to a javascript solution, for better compatibility
* Remove Treepadding
Treepadding was causing dropdown menus at the bottom of the tree to be obscured.
* Undo unnecessary move of dropdown-target
* Move Dropdown Handler to a sensibleish place
* Fix light Scrollbar color not picking up on Firefox
* Minor syntax
* Minor Clarification of CSS/ patch BlueLagoon
* Change logic for native WebKit scrollbar detection
Fix
https://github.com/FreshRSS/FreshRSS/pull/2117#issuecomment-444251419
Tested with Firefox 63, Firefox 65, Chrome 71, IE11, Edge 42
* Fixes for other views
E.g. reader view
* Cleaner way of generating hash for dropdowns
* Make dropdown-toggle an actual toggle
* Prepare for CSS Scrollbars Module Level 1
* Fix regression causing my labels dropdown not to appear
* remove unneeded dropdown-close css rule
* Re-apply some lost changes
https://github.com/FreshRSS/FreshRSS/pull/2117/commits/3c509989e890b88852e52c67c1c5507d1e0bf28c
* Add standard scrollbar compatibility
E.g. Firefox 64+
* Make All dropdowns click-to-close
* Remove BlueLagoon template
* Try to fix Firefox
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r239539984
* Add CSS rules necessary for consistent function of scrollbar in Firefox
* Use inheritance to determine width
* Use overlay scrollbar where possible
* Test Reduced Listener
* Fix Firefox 62
And show subtle scrollbar even when not hovering
* Add margin at bottom
To allow opening the menus
https://github.com/FreshRSS/FreshRSS/pull/2117#issuecomment-444571218
* Minor - tab correction
* Spaces -> tabs
* Remove unneeded inheritance
* Fix indenting
* Revert bad merge
* Messy WIP to make dropdowns work
* Style Cleanup
* Break it down
* Lets try a move-it move-it
* Update p/scripts/main.js
Co-Authored-By: pattems <patrick@crandol.com>
* Update p/themes/BlueLagoon/BlueLagoon.css
Co-Authored-By: pattems <patrick@crandol.com>
* separate ALL THE THINGS
* erroneous commas
* and to or
* removing double condition that doesn't do what I want
* More breaking down
* fix var
* Fix variable name again
* Remove magic number
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240052598
* Suuuuper inelegant solution for dropdowns
* lets try that again
* Inelegant Fix For Dropdowns
Now with 100% more working dropdowns
* Make sidebar dropdowns work correctly?
* Fix reversion
* Make JS scrollbar always visible
* Remove unneeded CSS
Added early in this pull request, didn't get pulled out when it was obsolete
* Fix CSS removal I missed
* CSS comment update/consistency for dark themes
* Clean Up Duplicate code
* Make dropdowns properly hide
Downside: Can no longer click on header/nav buttons to close
* Strip unneeded if statement
* jshint -W018
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240392851
* Half-reversion to old dropdown
* make overlay href scale to sidebar width
* remove init of nonexistent method
* remove trailing tabs
* move #close href where it belongs in index.phtml
* Revert all changes to index.phtml
* remove whitespace
accidentally added in last commit
* Move var's in init_column categories
* Finish putting old style dropdowns back
* Make CSS changes to use support statements
* Cleanup Whitespace
* re-add missing class
* spaces -> tabs in main.js
* tabs -> spaces css
* Minor whitespace
* Cleanup per @Alkarex
* Second attempt to add bottom margin
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240820901
* Fix error in IE11
* Simple-scrollbar color match for dark themes
6 years ago
|
|
|
<ul id="sidebar" class="tree">
|
|
|
|
<li class="tree-folder category all<?php echo FreshRSS_Context::isCurrentGet('a') ? ' active' : ''; ?>">
|
|
|
|
<div class="tree-folder-title">
|
|
|
|
<?php echo _i('all'); ?> <a class="title" data-unread="<?php echo format_number(FreshRSS_Context::$total_unread); ?>" href="<?php echo _url('index', $actual_view); ?>"><?php echo _t('index.menu.main_stream'); ?></a>
|
|
|
|
</div>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<li class="tree-folder category favorites<?php echo FreshRSS_Context::isCurrentGet('s') ? ' active' : ''; ?>">
|
|
|
|
<div class="tree-folder-title">
|
|
|
|
<?php echo _i('bookmark'); ?> <a class="title" data-unread="<?php echo format_number(FreshRSS_Context::$total_starred['unread']); ?>" href="<?php echo _url('index', $actual_view, 'get', 's'); ?>"><?php echo _t('index.menu.favorites', format_number(FreshRSS_Context::$total_starred['all'])); ?></a>
|
|
|
|
</div>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
$t_active = FreshRSS_Context::isCurrentGet('T');
|
|
|
|
?>
|
|
|
|
<li class="tree-folder category tags<?php echo $t_active ? ' active' : ''; ?>">
|
|
|
|
<div class="tree-folder-title">
|
|
|
|
<a class="dropdown-toggle" href="#"><?php echo _i($t_active ? 'up' : 'down'); ?></a>
|
|
|
|
<a class="title" data-unread="<?php echo format_number($this->nbUnreadTags); ?>" href="<?php echo _url('index', $actual_view, 'get', 'T'); ?>"><?php echo _t('index.menu.tags'); ?></a>
|
|
|
|
</div>
|
|
|
|
<ul class="tree-folder-items<?php echo $t_active ? ' active' : ''; ?>">
|
|
|
|
<?php
|
|
|
|
foreach ($this->tags as $tag):
|
|
|
|
?>
|
|
|
|
<li id="t_<?php echo $tag->id(); ?>" class="item feed<?php echo FreshRSS_Context::isCurrentGet('t_' . $tag->id()) ? ' active' : ''; ?>" data-unread="<?php echo $tag->nbUnread(); ?>">
|
|
|
|
<div class="dropdown no-mobile">
|
|
|
|
<div class="dropdown-target"></div>
|
|
|
|
<a class="dropdown-toggle"><?php echo _i('configure'); ?></a>
|
|
|
|
<?php /* tag_config_template */ ?>
|
|
|
|
</div>
|
|
|
|
<?php echo FreshRSS_Themes::alt('label'); ?> <a class="item-title" data-unread="<?php echo format_number($tag->nbUnread()); ?>" href="<?php echo _url('index', $actual_view, 'get', 't_' . $tag->id()); ?>"><?php echo $tag->name(); ?></a>
|
|
|
|
</li>
|
|
|
|
<?php endforeach; ?>
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
foreach ($this->categories as $cat) {
|
|
|
|
$feeds = $cat->feeds();
|
|
|
|
if (!empty($feeds)) {
|
|
|
|
$c_active = FreshRSS_Context::isCurrentGet('c_' . $cat->id());
|
|
|
|
$c_show = $c_active && (!FreshRSS_Context::$user_conf->display_categories ||
|
|
|
|
FreshRSS_Context::$current_get['feed']);
|
|
|
|
?>
|
|
|
|
<li class="tree-folder category<?php echo $c_active ? ' active' : ''; ?>" data-unread="<?php echo $cat->nbNotRead(); ?>">
|
|
|
|
<div class="tree-folder-title">
|
|
|
|
<a class="dropdown-toggle" href="#"><?php echo _i($c_show ? 'up' : 'down'); ?></a>
|
|
|
|
<a class="title<?php echo $cat->hasFeedsWithError() ? ' error' : ''; ?>" data-unread="<?php echo format_number($cat->nbNotRead()); ?>" href="<?php echo _url('index', $actual_view, 'get', 'c_' . $cat->id()); ?>"><?php echo $cat->name(); ?></a>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<ul class="tree-folder-items<?php echo $c_show ? ' active' : ''; ?>">
|
|
|
|
<?php
|
|
|
|
foreach ($feeds as $feed) {
|
|
|
|
$f_active = FreshRSS_Context::isCurrentGet('f_' . $feed->id());
|
|
|
|
?>
|
|
|
|
<li id="f_<?php echo $feed->id(); ?>" class="item feed<?php echo $f_active ? ' active' : '', $feed->mute() ? ' mute' : ''; ?><?php echo $feed->inError() ? ' error' : ''; ?><?php echo $feed->nbEntries() <= 0 ? ' empty' : ''; ?>" data-unread="<?php echo $feed->nbNotRead(); ?>" data-priority="<?php echo $feed->priority(); ?>">
|
|
|
|
<div class="dropdown no-mobile">
|
|
|
|
<div class="dropdown-target"></div>
|
|
|
|
<a class="dropdown-toggle" data-fweb="<?php echo $feed->website(); ?>"><?php echo _i('configure'); ?></a>
|
|
|
|
<?php /* feed_config_template */ ?>
|
|
|
|
</div>
|
|
|
|
<img class="favicon" src="<?php echo $feed->favicon(); ?>" alt="✇" /> <a class="item-title" data-unread="<?php echo format_number($feed->nbNotRead()); ?>" href="<?php echo _url('index', $actual_view, 'get', 'f_' . $feed->id()); ?>"><?php echo $feed->name(); ?></a>
|
|
|
|
</li>
|
|
|
|
<?php } ?>
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
Decouple scrolling of feeds and articles (#2117)
* Remove Sticky Kit
Remove sticky-kit, as functionality is unsuitable for separate scrolling.
* Remove sticky-kit load in main.js
Further removing the sticky-kit kruft
* Finish removal of references to Sticky-kit
* CSS Changes to template for Independent Scrolling
* Addition of JS and supporting CSS and html
* More CSS fixes to establish expected behavior
Should be able to scroll navbar without it being in sticky mode now.
* Fix typo in main.js
sortcut.js -> shortcut.js
* Fix unexpected tree scrolling behavior
* Change name of generic JS function
* Improve sticky-aside
* CSS changes in themes to accommodate independent Scroll
In themes where .aside's width is not the standard 300px, .tree's width must be specified to be equal to .aside
* Remove Sticky-Kit from README files
* Updates to Sticky-Aside
* Update Template to fix screwup
* Make Recalculating height actually work
* Let sidebar fill height if nav buttons aren't visible
* Make accommodating for nav buttons actually work
* update Swage theme for Independent Scroll feature
* Integrate sticky_aside into main.js
* Add Simple Scrollbar
* Patch scrollbar color for themes with dark colored asides
* Increase Visibility of scrollbar on Dark Themes
* Improve async loading, events, and performance
* CSS typo
* Fix double scrollbar on mobile
* Fix regression causing sticky to not be removed
* No $ for non-jQuery variables
* Fix strange condition + option for nice scrollbar
* Initial attempt to use css sticky
* Add stickyfill
* make the correct element sticky
* re-add incorrectly removed sidebar code
* Continue fixing mistaken deletions
* decrease frequency of recalc
* use minified version of simple-scrollbar.
* Load stickyfill instead of injecting
* put recalc back where it belongs
* re-remove script injector
* remove padding
bottom padding was causing the last item in the feed to be hidden under the nav buttons
* Manual merge of css_scrollbar
Add auto-detection of -webkit-scrollbar-thumb, otherwise fall back to
simple-scrollbar.js
* Fix Regression
Sticky recalc is still needed when using css scrollbars
* Replace method of closing dropdowns
Changed from an overlay href to a javascript solution, for better compatibility
* Remove Treepadding
Treepadding was causing dropdown menus at the bottom of the tree to be obscured.
* Undo unnecessary move of dropdown-target
* Move Dropdown Handler to a sensibleish place
* Fix light Scrollbar color not picking up on Firefox
* Minor syntax
* Minor Clarification of CSS/ patch BlueLagoon
* Change logic for native WebKit scrollbar detection
Fix
https://github.com/FreshRSS/FreshRSS/pull/2117#issuecomment-444251419
Tested with Firefox 63, Firefox 65, Chrome 71, IE11, Edge 42
* Fixes for other views
E.g. reader view
* Cleaner way of generating hash for dropdowns
* Make dropdown-toggle an actual toggle
* Prepare for CSS Scrollbars Module Level 1
* Fix regression causing my labels dropdown not to appear
* remove unneeded dropdown-close css rule
* Re-apply some lost changes
https://github.com/FreshRSS/FreshRSS/pull/2117/commits/3c509989e890b88852e52c67c1c5507d1e0bf28c
* Add standard scrollbar compatibility
E.g. Firefox 64+
* Make All dropdowns click-to-close
* Remove BlueLagoon template
* Try to fix Firefox
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r239539984
* Add CSS rules necessary for consistent function of scrollbar in Firefox
* Use inheritance to determine width
* Use overlay scrollbar where possible
* Test Reduced Listener
* Fix Firefox 62
And show subtle scrollbar even when not hovering
* Add margin at bottom
To allow opening the menus
https://github.com/FreshRSS/FreshRSS/pull/2117#issuecomment-444571218
* Minor - tab correction
* Spaces -> tabs
* Remove unneeded inheritance
* Fix indenting
* Revert bad merge
* Messy WIP to make dropdowns work
* Style Cleanup
* Break it down
* Lets try a move-it move-it
* Update p/scripts/main.js
Co-Authored-By: pattems <patrick@crandol.com>
* Update p/themes/BlueLagoon/BlueLagoon.css
Co-Authored-By: pattems <patrick@crandol.com>
* separate ALL THE THINGS
* erroneous commas
* and to or
* removing double condition that doesn't do what I want
* More breaking down
* fix var
* Fix variable name again
* Remove magic number
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240052598
* Suuuuper inelegant solution for dropdowns
* lets try that again
* Inelegant Fix For Dropdowns
Now with 100% more working dropdowns
* Make sidebar dropdowns work correctly?
* Fix reversion
* Make JS scrollbar always visible
* Remove unneeded CSS
Added early in this pull request, didn't get pulled out when it was obsolete
* Fix CSS removal I missed
* CSS comment update/consistency for dark themes
* Clean Up Duplicate code
* Make dropdowns properly hide
Downside: Can no longer click on header/nav buttons to close
* Strip unneeded if statement
* jshint -W018
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240392851
* Half-reversion to old dropdown
* make overlay href scale to sidebar width
* remove init of nonexistent method
* remove trailing tabs
* move #close href where it belongs in index.phtml
* Revert all changes to index.phtml
* remove whitespace
accidentally added in last commit
* Move var's in init_column categories
* Finish putting old style dropdowns back
* Make CSS changes to use support statements
* Cleanup Whitespace
* re-add missing class
* spaces -> tabs in main.js
* tabs -> spaces css
* Minor whitespace
* Cleanup per @Alkarex
* Second attempt to add bottom margin
https://github.com/FreshRSS/FreshRSS/pull/2117#discussion_r240820901
* Fix error in IE11
* Simple-scrollbar color match for dark themes
6 years ago
|
|
|
<li class="tree-bottom"></li>
|
|
|
|
</ul>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<script id="tag_config_template" type="text/html">
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
<li class="dropdown-close"><a href="#close">❌</a></li>
|
|
|
|
<li class="item">
|
|
|
|
<button class="as-link confirm" disabled="disabled"
|
|
|
|
form="mark-read-aside" formaction="<?php echo _url('tag', 'delete', 'id_tag', '------'); ?>"
|
|
|
|
type="submit"><?php echo _t('gen.action.remove'); ?></button>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<script id="feed_config_template" type="text/html">
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
<li class="dropdown-close"><a href="#close">❌</a></li>
|
|
|
|
<li class="item"><a href="<?php echo _url('index', $actual_view, 'get', 'f_------'); ?>"><?php echo _t('gen.action.filter'); ?></a></li>
|
|
|
|
<?php if (FreshRSS_Auth::hasAccess()) { ?>
|
|
|
|
<li class="item"><a href="<?php echo _url('stats', 'repartition', 'id', '------'); ?>"><?php echo _t('index.menu.stats'); ?></a></li>
|
|
|
|
<?php } ?>
|
|
|
|
<li class="item"><a target="_blank" rel="noreferrer" href="http://example.net/"><?php echo _t('gen.action.see_website'); ?></a></li>
|
|
|
|
<?php if (FreshRSS_Auth::hasAccess()) { ?>
|
|
|
|
<li class="separator"></li>
|
|
|
|
<li class="item"><a href="<?php echo _url('subscription', 'index', 'id', '------'); ?>"><?php echo _t('gen.action.manage'); ?></a></li>
|
|
|
|
<li class="item"><a href="<?php echo _url('feed', 'actualize', 'id', '------'); ?>"><?php echo _t('gen.action.actualize'); ?></a></li>
|
|
|
|
<li class="item">
|
|
|
|
<?php $confirm = FreshRSS_Context::$user_conf->reading_confirm ? 'confirm" disabled="disabled' : ''; ?>
|
|
|
|
<button class="read_all as-link <?php echo $confirm; ?>"
|
|
|
|
form="mark-read-aside"
|
|
|
|
formaction="<?php echo _url('entry', 'read', 'get', 'f_------'); ?>"
|
|
|
|
type="submit"><?php echo _t('gen.action.mark_read'); ?></button>
|
|
|
|
</li>
|
|
|
|
<?php } ?>
|
|
|
|
</ul>
|
|
|
|
</script>
|