reading.phtml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. <?php $this->partial('aside_configure'); ?>
  2. <div class="post">
  3. <a href="<?php echo _url('index', 'index'); ?>"><?php echo _t('gen.action.back_to_rss_feeds'); ?></a>
  4. <form method="post" action="<?php echo _url('configure', 'reading'); ?>">
  5. <input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
  6. <legend><?php echo _t('conf.reading'); ?></legend>
  7. <div class="form-group">
  8. <label class="group-name" for="posts_per_page"><?php echo _t('conf.reading.articles_per_page'); ?></label>
  9. <div class="group-controls">
  10. <input type="number" id="posts_per_page" name="posts_per_page" value="<?php echo FreshRSS_Context::$user_conf->posts_per_page; ?>" min="5" max="500" data-leave-validation="<?php echo FreshRSS_Context::$user_conf->posts_per_page; ?>"/>
  11. <?php echo _i('help'); ?> <?php echo _t('conf.reading.number_divided_when_reader'); ?>
  12. </div>
  13. </div>
  14. <div class="form-group">
  15. <label class="group-name" for="sort_order"><?php echo _t('conf.reading.sort'); ?></label>
  16. <div class="group-controls">
  17. <select name="sort_order" id="sort_order" data-leave-validation="<?php echo FreshRSS_Context::$user_conf->sort_order; ?>">
  18. <option value="DESC"<?php echo FreshRSS_Context::$user_conf->sort_order === 'DESC' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.sort.newer_first'); ?></option>
  19. <option value="ASC"<?php echo FreshRSS_Context::$user_conf->sort_order === 'ASC' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.sort.older_first'); ?></option>
  20. </select>
  21. </div>
  22. </div>
  23. <div class="form-group">
  24. <label class="group-name" for="view_mode"><?php echo _t('conf.reading.view.default'); ?></label>
  25. <div class="group-controls">
  26. <select name="view_mode" id="view_mode" data-leave-validation="<?php echo FreshRSS_Context::$user_conf->view_mode; ?>">
  27. <option value="normal"<?php echo FreshRSS_Context::$user_conf->view_mode === 'normal' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.view.normal'); ?></option>
  28. <option value="reader"<?php echo FreshRSS_Context::$user_conf->view_mode === 'reader' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.view.reader'); ?></option>
  29. <option value="global"<?php echo FreshRSS_Context::$user_conf->view_mode === 'global' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.view.global'); ?></option>
  30. </select>
  31. </div>
  32. </div>
  33. <div class="form-group">
  34. <label class="group-name" for="view_mode"><?php echo _t('conf.reading.show'); ?></label>
  35. <div class="group-controls">
  36. <select name="default_view" id="default_view" data-leave-validation="<?php echo FreshRSS_Context::$user_conf->default_view; ?>">
  37. <option value="adaptive"<?php echo FreshRSS_Context::$user_conf->default_view === 'adaptive' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.show.adaptive'); ?></option>
  38. <option value="all"<?php echo FreshRSS_Context::$user_conf->default_view === 'all' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.show.all_articles'); ?></option>
  39. <option value="unread"<?php echo FreshRSS_Context::$user_conf->default_view === 'unread' ? ' selected="selected"' : ''; ?>><?php echo _t('conf.reading.show.unread'); ?></option>
  40. </select>
  41. </div>
  42. </div>
  43. <div class="form-group">
  44. <div class="group-controls">
  45. <label class="checkbox" for="hide_read_feeds">
  46. <input type="checkbox" name="hide_read_feeds" id="hide_read_feeds" value="1"<?php echo FreshRSS_Context::$user_conf->hide_read_feeds ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->hide_read_feeds; ?>"/>
  47. <?php echo _t('conf.reading.hide_read_feeds'); ?>
  48. </label>
  49. </div>
  50. </div>
  51. <div class="form-group">
  52. <div class="group-controls">
  53. <label class="checkbox" for="display_posts">
  54. <input type="checkbox" name="display_posts" id="display_posts" value="1"<?php echo FreshRSS_Context::$user_conf->display_posts ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->display_posts; ?>"/>
  55. <?php echo _t('conf.reading.display_articles_unfolded'); ?>
  56. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  57. </label>
  58. </div>
  59. </div>
  60. <div class="form-group">
  61. <div class="group-controls">
  62. <label class="checkbox" for="display_categories">
  63. <input type="checkbox" name="display_categories" id="display_categories" value="1"<?php echo FreshRSS_Context::$user_conf->display_categories ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->display_categories; ?>"/>
  64. <?php echo _t('conf.reading.display_categories_unfolded'); ?>
  65. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  66. </label>
  67. </div>
  68. </div>
  69. <div class="form-group">
  70. <div class="group-controls">
  71. <label class="checkbox" for="sticky_post">
  72. <input type="checkbox" name="sticky_post" id="sticky_post" value="1"<?php echo FreshRSS_Context::$user_conf->sticky_post ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->sticky_post; ?>"/>
  73. <?php echo _t('conf.reading.sticky_post'); ?>
  74. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  75. </label>
  76. </div>
  77. </div>
  78. <div class="form-group">
  79. <div class="group-controls">
  80. <label class="checkbox" for="auto_load_more">
  81. <input type="checkbox" name="auto_load_more" id="auto_load_more" value="1"<?php echo FreshRSS_Context::$user_conf->auto_load_more ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->auto_load_more; ?>"/>
  82. <?php echo _t('conf.reading.auto_load_more'); ?>
  83. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  84. </label>
  85. </div>
  86. </div>
  87. <div class="form-group">
  88. <div class="group-controls">
  89. <label class="checkbox" for="lazyload">
  90. <input type="checkbox" name="lazyload" id="lazyload" value="1"<?php echo FreshRSS_Context::$user_conf->lazyload ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->lazyload; ?>"/>
  91. <?php echo _t('conf.reading.img_with_lazyload'); ?>
  92. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  93. </label>
  94. </div>
  95. </div>
  96. <div class="form-group">
  97. <div class="group-controls">
  98. <label class="checkbox" for="sides_close_article">
  99. <input type="checkbox" name="sides_close_article" id="sides_close_article" value="1"<?php echo FreshRSS_Context::$user_conf->sides_close_article ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->sides_close_article; ?>"/>
  100. <?php echo _t('conf.reading.sides_close_article'); ?>
  101. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  102. </label>
  103. </div>
  104. </div>
  105. <div class="form-group">
  106. <div class="group-controls">
  107. <label class="checkbox" for="reading_confirm">
  108. <input type="checkbox" name="reading_confirm" id="reading_confirm" value="1"<?php echo FreshRSS_Context::$user_conf->reading_confirm ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->reading_confirm; ?>"/>
  109. <?php echo _t('conf.reading.confirm_enabled'); ?>
  110. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  111. </label>
  112. </div>
  113. </div>
  114. <div class="form-group">
  115. <div class="group-controls">
  116. <label class="checkbox" for="auto_remove_article">
  117. <input type="checkbox" name="auto_remove_article" id="auto_remove_article" value="1"<?php echo FreshRSS_Context::$user_conf->auto_remove_article ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->auto_remove_article; ?>"/>
  118. <?php echo _t('conf.reading.auto_remove_article'); ?>
  119. <noscript> — <strong><?php echo _t('gen.js.should_be_activated'); ?></strong></noscript>
  120. </label>
  121. </div>
  122. </div>
  123. <div class="form-group">
  124. <div class="group-controls">
  125. <label class="checkbox" for="mark_updated_article_unread">
  126. <input type="checkbox" name="mark_updated_article_unread" id="mark_updated_article_unread" value="1"<?php echo FreshRSS_Context::$user_conf->mark_updated_article_unread ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->mark_updated_article_unread; ?>"/>
  127. <?php echo _t('conf.reading.mark_updated_article_unread'); ?>
  128. </label>
  129. </div>
  130. </div>
  131. <div class="form-group">
  132. <label class="group-name"><?php echo _t('conf.reading.read.when'); ?></label>
  133. <div class="group-controls">
  134. <label class="checkbox" for="check_open_article">
  135. <input type="checkbox" name="mark_open_article" id="check_open_article" value="1"<?php echo FreshRSS_Context::$user_conf->mark_when['article'] ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->mark_when['article']; ?>"/>
  136. <?php echo _t('conf.reading.read.article_viewed'); ?>
  137. </label>
  138. <label class="checkbox" for="check_open_site">
  139. <input type="checkbox" name="mark_open_site" id="check_open_site" value="1"<?php echo FreshRSS_Context::$user_conf->mark_when['site'] ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->mark_when['site']; ?>"/>
  140. <?php echo _t('conf.reading.read.article_open_on_website'); ?>
  141. </label>
  142. <label class="checkbox" for="check_scroll">
  143. <input type="checkbox" name="mark_scroll" id="check_scroll" value="1"<?php echo FreshRSS_Context::$user_conf->mark_when['scroll'] ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->mark_when['scroll']; ?>"/>
  144. <?php echo _t('conf.reading.read.scroll'); ?>
  145. </label>
  146. <label class="checkbox" for="check_reception">
  147. <input type="checkbox" name="mark_upon_reception" id="check_reception" value="1"<?php echo FreshRSS_Context::$user_conf->mark_when['reception'] ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->mark_when['reception']; ?>"/>
  148. <?php echo _t('conf.reading.read.upon_reception'); ?>
  149. </label>
  150. </div>
  151. </div>
  152. <div class="form-group">
  153. <label class="group-name"><?php echo _t('conf.reading.after_onread'); ?></label>
  154. <div class="group-controls">
  155. <label class="checkbox" for="onread_jump_next">
  156. <input type="checkbox" name="onread_jump_next" id="onread_jump_next" value="1"<?php echo FreshRSS_Context::$user_conf->onread_jump_next ? ' checked="checked"' : ''; ?> data-leave-validation="<?php echo FreshRSS_Context::$user_conf->onread_jump_next; ?>"/>
  157. <?php echo _t('conf.reading.jump_next'); ?>
  158. </label>
  159. </div>
  160. </div>
  161. <div class="form-group form-actions">
  162. <div class="group-controls">
  163. <button type="submit" class="btn btn-important"><?php echo _t('gen.action.submit'); ?></button>
  164. <button type="reset" class="btn"><?php echo _t('gen.action.cancel'); ?></button>
  165. </div>
  166. </div>
  167. </form>
  168. </div>