51 Commits

Author SHA1 Message Date
Inverle
d55f017ccd Implement button for toggling sidebar on all views (#8201)
* Implement button for toggling sidebar on all views

Closes https://github.com/FreshRSS/FreshRSS/issues/7673, https://github.com/FreshRSS/FreshRSS/issues/7100, https://github.com/FreshRSS/FreshRSS/issues/6119, https://github.com/FreshRSS/FreshRSS/issues/5338, https://github.com/FreshRSS/FreshRSS/issues/2792, https://github.com/FreshRSS/FreshRSS/issues/4224, https://github.com/FreshRSS/FreshRSS/issues/4136

https://github.com/user-attachments/assets/0629e465-6450-440e-b38b-430e9ff73ef9

Keyboard shortcut for doing the same: <kbd>t</kbd>

* Partially fix other views

Repartition page looks broken on Swage

* Correction

`close-aside` wasn't meant to be removed

* i18n(conf): fr

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* make fix-all

* Fix settings slider not opening in reader view

* make readme

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2025-12-04 08:48:03 +01:00
Alexandre Alapetite
b6c63d2239 Better transitions between groups of articles (#8174)
fix https://github.com/FreshRSS/FreshRSS/issues/7520
fix https://github.com/FreshRSS/FreshRSS/issues/8168
fix https://github.com/FreshRSS/FreshRSS/discussions/8172
2025-11-04 12:49:21 +01:00
maTh
2bcc090622 configurable notification timeout (#7942)
Ref #7931
Ref #5466
Ref #6409

added configuration in "Display"
<img width="636" height="167" alt="grafik" src="https://github.com/user-attachments/assets/7bbc9f26-d91b-4dd2-b715-1d3f9b7a9ad3" />

* i18n: fr

* Update app/i18n/pl/conf.php

Co-authored-by: Inverle <inverle@proton.me>

* make fix-all

* max()

* Minor whitespace
(I am not a fan of excessive vertical indenting)

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
Co-authored-by: Inverle <inverle@proton.me>
2025-10-01 10:48:07 +02:00
Inverle
87879e8392 Improve leave validation (#7830)
* Improve leave validation

* array_key_exists -> isset

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2025-08-31 19:09:02 +02:00
maTh
7de384bf9c Mark as read button: config for the size (#7314)
* settings

* i18n: mark_read_button

* big, small, none

* fix

* Fixes

* make fix-all

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2025-03-13 23:10:48 +01:00
maTh
a697ca54ad Shortcuts for adding labels (#7274)
* add shortcut in config

* open my labels menu with shortcut

* the first 9 items are selectable + input field

* i18n

* Update app/i18n/nl/conf.php

Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>

* index.menu.mylabels

* order fixed

---------

Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
2025-02-03 08:47:25 +01:00
Alexandre Alapetite
1f466d7a2e Implement custom order-by (#7149)
Add option to sort results by received date (existing, default), publication date, title, URL (link), random.

fix https://github.com/FreshRSS/FreshRSS/issues/1771
fix https://github.com/FreshRSS/FreshRSS/issues/2083
fix https://github.com/FreshRSS/FreshRSS/issues/2119
fix https://github.com/FreshRSS/FreshRSS/issues/2596
fix https://github.com/FreshRSS/FreshRSS/issues/3204
fix https://github.com/FreshRSS/FreshRSS/issues/4405
fix https://github.com/FreshRSS/FreshRSS/issues/5529
fix https://github.com/FreshRSS/FreshRSS/issues/5864
fix https://github.com/FreshRSS/Extensions/issues/161

URL parameters:
* `&sort=id` (current behaviour, sorting according to newest received articles)
* `&sort=date` (publication date, which is not indicative of how new an article is)
* `&sort=title`
* `&sort=link`
* `&sort=rand` (random order - which disables infinite scrolling, at least for now)

combined with `&order=ASC` or `&order=DESC`

![image](https://github.com/user-attachments/assets/2de5aef1-604e-4a73-a147-569f6f42a1be)

## Implementation notes

The sorting criteria by *received date* (id), which is the default, and which was the only one before this PR, is the one that has the best sorting characteristics:
* *uniqueness*: no entries have the exact same received date
* *monotonicity*: new entries always have a higher received date
* *performance*: this field is efficiently indexed in database for fast usage, including for paging (indexing could also be done to other fields, but with lower effective performance)

In contrary, sorting criteria such as by *publication date*, by *title*, or by *link* are neither unique nor monotonic. In particular, multiple articles may share the same *publication date*, and we may receive articles with a *publication date* far in the future, and then later some new articles with a *publication date* far in the past.

To understand why sorting by *publication date* is problematic, it helps to think about sorting by *title* or by *link*, as sorting by *title* and by *publication date* share more or less the same characteristics.

### Problem 1: new articles

New articles may be received in the background after what is shown on screen, and before the next user action such as *mark all as read*. Due to the lack of *monotonicity* when sorting by e.g. *publication date* or *title*, users risk marking as read a batch of articles containing some fresh articles without seeing them.

Mitigation: A parameter `idMax` tracks the maximum ID related to a batch of actions such as *mark all as read* to exclude articles received after those that are displayed.

### Problem 2: paging / pagination

When navigating articles, only a few articles are displayed, and a new "page" of articles needs to be received from the database when scrolling down or when clicking the button to show more articles. When sorting by e.g. *publication date* or *title*, it is not trivial to show the next page without re-showing some of the same articles, and without skipping any. Indeed, views are often with additional criteria such as showing only unread articles, and users may mark some articles as read while viewing them, hereby removing some articles from the previous pages. And like for *Problem 1*, new articles may have been received in the background. Consequently, it is not possible to use `OFFSET` to implement pagination (so the patches suggested by a few users were wrong due to that, in particular).

Mitigation: `idMax` is also used (just like for *Problem 1*) and a *Keyset Pagination* approach is used, combining an unstable sorting criterion such as *publication date* or *title*, together with *id* to ensure stable sorting. (So, 2 sorting criteria + 1 filter criteria)

See e.g. https://www.alwaysdeveloping.net/dailydrop/2022/07/01-keyset-pagination/

### Problem 3: performance

Sorting by anything else than *received date* (id) is doomed to be slow(er) due to the combination of 3 criteria (see *Problem 2*). An `OFFSET` approach (which is not possible anyway as explained) would be even slower. Furthermore, we have no SQL index at the moment, but they would not necessarily help much due to the multiple sorting criteria needed and involving some `OR` logic which is difficult to optimise for databases.

The nicest syntax would be using tuples and corresponding indexes, but that is poorly supported by MySQL https://bugs.mysql.com/bug.php?id=104128

Mitigation: a compatibility SQL syntax is used to implement *Keyset Pagination*

### Problem 4: user confusion

Several users have shown that they do not fully understand the difference between *received date* and *publication date*, and particularly not the pitfalls of *publication date*.

Mitigation: the menus to mark-as-read *before 1 day* and *before 1 week* are disabled when sorting by anything else than *received date*. Likewise, the separation headers *Today* and *Yesterday* and *Before yesterday* are only shown when sorting by *received date*.

Again here, to better understand why, it helps to think about sorting by *title* or by *link*, as sorting by *title* and by *publication date* share more or less the same characteristics.

* [ ] We should write a Q&A and/or documentation about the problems associated to *sorting by publication date*: risks of not noticing new publication, of inadvertently marking them as read, of having some articles with a date in the future hanging at the top of the views (vice versa when sorting in ascending order), performance, etc.

### Problem 5: APIs

Sorting by anything else than *received date* breaks the guarantees needed for a successful synchronisation via API.

Mitigation: sorting by *received date* is ensured for all API calls.
2025-01-06 16:00:00 +01:00
maTh
5b9248f45f New: Label menu in article row (#6984)
* configs

* add the icon in the entry header line

* rename comment

* Update main.js

* CSS

* comment typo fix

* fix gloabl view my labels menu

* improved: my labels dropdown with triangle now. yay!
2024-11-15 09:14:23 +01:00
Alexis Degrugillier
ad2c6e6fbf Add privacy settings on extension list retrieval (#4603)
* Add privacy settings on extension list retrieval

There is a new privacy page to handle all configuration related to privacy. At
the moment, only privacy related to extensions can be configured.

The new settings allow to change the location of the extension list file and to
choose if the selected file is cached for a day or retrieved for each request.

Fix #4570

* Update code to pass PHPStan

* make fix-all

---------

Co-authored-by: maTh <math-home@web.de>
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2024-10-20 20:51:49 +02:00
maTh
7aa3d9f873 New: Sharing articles from the article title line (#6395)
* enable option

* Update entry_header.phtml

* frss.css

* fix print sharing

* Light refactoring

* fix

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2024-07-01 01:13:54 +02:00
maTh
20f13312d1 Reading view: action icons position (#6297)
* add configs in reading

* implementation into the reading view

* CSS

* i18n

* Credits to  joshka

* Update article.phtml

* fix

* fix

* <br />

* Update app/i18n/fr/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* Update app/i18n/en/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* fix French

* show_articleicons  => show_article_icons

* Update app/i18n/en/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* Update app/i18n/en-us/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2024-06-13 16:40:54 +02:00
Alexandre Alapetite
e98c57841b Default dark mode to auto (#5582)
* Default dark mode to auto
Set default dark mode to automatic instead of disabled.
Follow-up of https://github.com/FreshRSS/FreshRSS/pull/4843

* Selected themes

* For compatible themes only
2024-06-06 22:24:58 +02:00
maTh
5de794ee0f delete rss view shortcut (#6131) 2024-02-27 23:57:23 +01:00
Alexandre Alapetite
39cc1c11ec New feature: shareable user query (#6052)
* New feature: shareable user query
Share the output of a user query by RSS / HTML / OPML with other people through unique URLs.
Replaces the global admin token, which was the only option (but unsafe) to share RSS outputs with other people.
Also add a new HTML output for people without an RSS reader.

fix https://github.com/FreshRSS/FreshRSS/issues/3066#issuecomment-648977890
fix https://github.com/FreshRSS/FreshRSS/issues/3178#issuecomment-769435504

* Remove unused method

* Fix token saving

* Implement HTML view

* Update i18n for master token

* Revert i18n get_favorite

* Fix missing i18n for user queries from before this PR

* Remove irrelevant tests

* Add link to RSS version

* Fix getGet

* Fix getState

* Fix getSearch

* Alternative getSearch

* Default getOrder

* Explicit default state

* Fix test

* Add OPML sharing

* Remove many redundant SQL queries from original implementation of user queries

* Fix article tags

* Use default user settings

* Prepare public search

* Fixes

* Allow user search on article tags

* Implement user search

* Revert filter bug

* Revert wrong SQL left outer join change

* Implement checkboxes

* Safe check of OPML

* Fix label

* Remove RSS button to favour new sharing method
That sharing button was using a global admin token

* First version of HTTP 304

* Disallow some recusrivity
fix https://github.com/FreshRSS/FreshRSS/issues/6086

* Draft of nav

* Minor httpConditional

* Add support for offset for pagination

* Fix offset pagination

* Fix explicit order ASC

* Add documentation

* Help links i18n

* Note about deprecated master token

* Typo

* Doc about format
2024-02-26 09:01:03 +01:00
Alexandre Alapetite
e968964538 Fix show_tags_max (#5978)
fix https://github.com/FreshRSS/FreshRSS/issues/5975
Regression from https://github.com/FreshRSS/FreshRSS/pull/5830
2023-12-26 16:30:32 +01:00
Alexandre Alapetite
a80a5f48a1 Pass PHPStan level 8 (#5946)
* Pass PHPStan level 8
And prepare for PHPStan level 9 https://phpstan.org/user-guide/rule-levels

* Revert wrong replace in comment

* Fix PHPStan level 8

* Update PHPStan and other dev dependencies

* Remove obsolete comment

* noVariableVariables and towards bleedingEdge
https://github.com/phpstan/phpstan-strict-rules
https://phpstan.org/blog/what-is-bleeding-edge

* More bleedingEdge

* A bit more PHPStan level 9

* More PHPStan level 9

* Prepare for booleansInConditions
Ignore int and null

* Revert wrong line

* More fixes

* Fix keep_max_n_unread

* Stricter attribute functions

* Stricter callHooks and more PHPStan level 9

* More typing

* A tiny more
2023-12-18 17:59:16 +01:00
Alexandre Alapetite
6bb45a8726 Add filter actions (auto mark read) at category and global levels (#5942)
* Add filter actions (auto mark read) at category level
fix https://github.com/FreshRSS/FreshRSS/issues/3497

* Add filter actions (auto mark read) at global level
fix https://github.com/FreshRSS/FreshRSS/issues/2788

* Fix feed category ID

* Minor comment
2023-12-15 23:04:29 +01:00
maTh
0504fc6766 Added: Display option for "My labels" (#5884)
* configs

* Update entry_bottom.phtml

* i18n strings

* fix phpstand found error

* reuse existing i18n string

---------

Co-authored-by: math-gh <>
2023-11-16 13:18:33 +01:00
Ben Passmore
b9939bdaac Added ability to mark articles as read on focus. (#5812)
* Added ability to mark entries as read on focus.

Feature proposed in issue #5723.

* make-fix-all + i18n fr

* Use batch to save resources and increase performance

* Use "keep_unread"

* typo

---------

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2023-11-09 11:12:04 +01:00
Sadetdin EYILI
d3966befaf feat: create config to display website icon only / name only / icon and name / none on feeds (#4969)
* feat: create config to display website icon only / name only / icon and name / none on feeds

* fix title hovering

* reverted: column in .phtml

* Update app/i18n/fr/conf.php

---------

Co-authored-by: mathContao <math-home@web.de>
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2023-03-04 14:51:07 +01:00
maTh
b5a418ec16 Added: Dark mode for Origine +Origine compact themes (#4843)
* first draft

* fix: theme slider: properties box

* improved colors

* option to enable/disable dark mode

* fixes

* Update app/i18n/fr/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* i18n english improved

* fix dark background color for favorites + hover colors

* select list: no, auto

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2023-01-09 10:40:38 +01:00
Alexandre Alapetite
6261dc9cf4 User-defined time zone (#4906)
* User-defined time zone
#fix https://github.com/FreshRSS/FreshRSS/issues/2754

* Update app/i18n/nl/conf.php

Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>

* Timezone when creating a new user

Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
2022-11-29 15:27:32 +01:00
Alexis Degrugillier
ebce6a76c2 Change default values to have predictable default state (#4736) 2022-10-16 12:42:58 +02:00
maTh
b2e46d6215 Improved: Article header (#4101)
* First draft for normal view

* Revert changes on the entry header

* Update normal.phtml

* Update normal.phtml

* RTL CSS

* CSS fixes

* Better tags style

* fix

* Update swage.scss

* fix

* Update swage.scss

* fixed .content header

* font-size in rem

* improved template

* dropdown menu if more than 7 tags

* configuration: show tags in topline

* Simplify loop logic

* Minor space

* config tags via reading (i18n still missed)

* fixed the whitespaces

* optimizations

* optimize header+footer

* Update normal.phtml

* fix css

* new config: show author+date in footer

* config feed name display

* improve HTML

* fix whitespaces

* i18n

* i18n: German translations

* fix i18n German

* fixed: uncouple from bottomline config

* reverted: tobline_tags

* equalities

* fixed: author in footer

* fixed data-leave-validation

* improved max numbers i18n label

* Config works now also in the reader view

* fix: footer border

* reader view: style article-header-topline

* fixed whitespace

* i18n fr

* Minor i18n fr

* Fix mistake i18n fr

* i18n fr more precise expression

* Fix JavaScript

* removed the link icon in the title

* clean CSS

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2022-07-17 22:54:24 +02:00
Alexandre Alapetite
509c8cae63 Dynamic OPML (#4407)
* Dynamic OPML draft
#fix https://github.com/FreshRSS/FreshRSS/issues/4191

* Export dynamic OPML
http://opml.org/spec2.opml#1629043127000

* Restart with simpler approach

* Minor revert

* Export dynamic OPML also for single feeds

* Special category type for importing dynamic OPML

* Parameter for excludeMutedFeeds

* Details

* More draft

* i18n

* Fix update

* Draft manual import working

* Working manual refresh

* Draft automatic update

* Working Web refresh + fixes

* Import/export dynamic OPML settings

* Annoying numerous lines in SQL logs

* Fix minor JavaScript error

* Fix auto adding new columns

* Add require

* Add missing 🗲

* Missing space

* Disable adding new feeds to dynamic categories

* Link from import

* i18n typo

* Improve theme icon function

* Fix pink-dark
2022-07-04 09:53:26 +02:00
Alexandre Alapetite
d785ddde2a New option to automatically mark as read gone articles (#4426)
* New option to automatically mark as read gone articles
Option to automatically and immediately mark as read entries / articles that are no longer provided in their upstream RSS / ATOM / XPath feed

* Reduce SQL queries
Optimisation: Perform cache update only once
2022-06-25 11:15:51 +02:00
Alexandre Alapetite
0cde4e898f Automatic simplification of layout for many feeds (#4357)
* Refactor OPML export categories
Simplify code to comply with types hints.
And renamed a property to plural.

* Automatic simplification of layout for many feeds
New advanced property to automatically simplify the layout when there are many (1k+)  feeds so that FreshRSS works out of the box with 20k+ feeds scenarios https://github.com/FreshRSS/FreshRSS/pull/4347

Merge https://github.com/FreshRSS/FreshRSS/pull/4356 first.
2022-05-15 13:47:31 +02:00
Alexandre Alapetite
80a228e9a6 Option icons-as-emojis for performance (#4353)
New mode to use only emojis instead of icons.
Considerably improves performances.
Needed for 20k+ feeds scenario https://github.com/FreshRSS/FreshRSS/pull/4347
2022-05-09 12:54:54 +02:00
maTh
f0fa3f3202 New shortcut: actualize feeds (#3900)
* configs

* i18n

* improved

* Update app/i18n/fr/conf.php

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* Update p/scripts/main.js

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>

* Update main.js

* Update conf.php

* make fix-all

* i18n

* i18n

* i18n: delete conf.shortcut.actualize

* Update app/views/configure/shortcut.phtml
2021-10-28 01:24:44 +02:00
stysebae
85b898c623 Add shortcut to jump to next unread article (issue #3393) (#3891)
* Add shortcut to jump to next unread article

* phpcbf

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2021-10-19 10:46:39 +02:00
Alexandre Alapetite
a7aca6c0ab Improved feed action filters (#3303)
* Re-order some feed options
* Option to auto mark as read existing titles
* Option to keep at max n unread articles per feed
2021-09-19 10:56:38 +02:00
ORelio
50ba6bbe07 UI: Add optional thumbnail and summary on feed items (#3805)
* UI: Add optional thumbnail and summary on feed items

Implements #561

* UI: Thumbnail: Own column, Custom size, Lazy load

* UI: Thumbnail: Remove unnecessary CSS rule

Remove rule already defined in base theme, no override needed

* CSS lint + RTL

* Improve thumbail and summary generation

* Support img alt

* Missing htmlspecialchars

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2021-08-30 10:58:06 +02:00
Prashant Tholia
6f23999c7b Remember open categories (#3185)
* feature(normal) - Remember opened categories in the left menu

Session storage based implementation to remember opened categories in left menu

Issue Ref: #2248

* lib_phpQuery updates

* Updates covering feedback points and functionality fixes

* Feedback updates

* Revert "lib_phpQuery updates"

This reverts commit dcd23b9418.

* First review

Change variable name to "remember" instead of "open".
Start using localStorage instead of sessionStorage.
Simplify code.

* Simplify remember categories init function

Replace 'session' with 'local' in function names and comment

Set open categories CSS as same as when category is opened in 'active' unfold mode

* Remove URLSearchParams check in remember categories init function

* Delete open categories on login and logout

* JSHint check fix

* Second review

* Make new mode the default for new users
* Always open active category
* Reduce / simplify code

* i18n French

* Revert default value

Wait a bit more for this decision / change

Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
2020-11-02 12:03:16 +01:00
Alexis Degrugillier
caeb660f29 Add a way to disable/enable users (#3056)
If you want to block users without deleting their account, you can now
disable them from the interface.
2020-06-14 19:50:09 +02:00
Alexis Degrugillier
dc68783fc8 Add controls on media (#3036)
Now, there is a shortcut to play or pause media available from an
entry. If there is more than one media available, only the first
one will be targeted.

See #1952
2020-06-05 23:37:05 +02:00
Alexandre Alapetite
5ddae68953 Option to control which categories to unfold (#2888)
#fix https://github.com/FreshRSS/FreshRSS/issues/2324
2020-04-16 18:09:54 +02:00
Alexandre Alapetite
9421030925 Option to show/hide favicons (#2821)
* Option to show/hide favicons

#fix https://github.com/FreshRSS/FreshRSS/issues/2819

* Also for subscription list
2020-03-09 20:36:24 +01:00
Alexandre Alapetite
0f94402b7e Better performance with yield (#2588)
* Better performance with yield

Largely decrease the time to first byte, and reduced memory consumtion.
Before, we used to make several copies in memory of the whole list of
articles before sending them to the client. Now streamed as they are
processed.

* Travis
2020-02-29 18:19:09 +01:00
Offerel
68863fbac8 Show Favorites as Unread (#2766)
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com>
Co-authored-by: Marien Fressinaud <dev@marienfressinaud.fr>
2020-01-16 17:11:04 +01:00
Alexis Degrugillier
3c099c7853 Add an admin flag on users (#2709)
Now FRSS supports more than one admin. Admins have the same rights as
the default user. Admins can promote or demote other users. The default
user is considered as an admin even if it does not have the admin flag
enabled.

See #2096
2020-01-06 20:28:04 +01:00
Alexis Degrugillier
cc0db9af4f Feature/new archiving (#2335)
* Change archiving config page layout

I've changed some wording and moved actions into a
maintenance section.

* Update purge action

Now we have more control on the purge action. The configuration allows
us to choose what to keep and what to discard in a more precise way.
At the moment, the configuration applies for all feeds.

* Add purge configuration on feed level

Now the extend purge configuration is available on feed level.
It is stored as attributes and will be used in the purge action.

* Update purge action

Now the purge action uses the feed configuration if it exists and
defaults on user configuration if not.

* Add empty option in period list

* Fix configuration warnings

* Add archiving configuration on categories

See #2369

* Add user info back

* Add explanations in UI

* Fixes for SQLite + error + misc.

* Fix invalid feed reference

* Short array syntax

Only for new code, so far

* Fix prefix error

* Query performance, default values

Work in progress

* Fix default values and confirm before leaving

Form cancel and confirm changes before leaving were broken.
And start taking advantage of the short echo syntax `<?= ?>` as we have
moved to PHP 5.4+

* More work

* Tuning SQL

* Fix MariaDB + performance issue

* SQL performance

* Fix SQLite bug

* Fix some attributes JSON encoding bugs

Especially for SQLite export/import

* More uniform, fix bugs

More uniform between global, category, feed settings

* Drop special cases for old articles during refresh

Instead will use lastSeen date with the new archiving logic.
This was generating problems anyway
https://github.com/FreshRSS/FreshRSS/issues/2154

* Draft drop index keep_history

Not needed anymore

* MySQL typo

Now properly tested with MySQL, PostgreSQL, SQLite

* More work for legacy values

Important to avoid overriding user's preference and risking deleting
data erroneously

* Fix PHP 7.3 / 7.4 warnings

@aledeg "Trying to use values of type null, bool, int, float or resource
as an array (such as $null["key"]) will now generate a notice. "
https://php.net/migration74.incompatible

* Reintroduce min articles and take care of legacy parameters

* A few changes forgotten

* Draft of migration + DROP of feed.keep_history

* Fix several errors

And give up using const for SQL to allow multiple database types (and we
cannot redefine a const)

* Add keep_min to categories + factorise archiving logic

* Legacy fix

* Fix bug yield from

* Minor: Use JSON_UNESCAPED_SLASHE for attributes

And make more uniform

* Fix sign and missing variable

* Fine tune the logic
2019-10-23 00:52:15 +02:00
Joris Kinable
80590daeb3 Configure user defaults (#2490)
* new users inherit defaults from config-user.php

* installer creates ./data/config-user.php

* fixed typo

* .gitignore fix

* fixed style issues

* Fixed comments

* Update according to feedback

- rename file into `data/config-user.custom.php`
- make it optional (and so, don't copy it during installation)

* fixup! Update according to feedback
2019-09-16 21:18:42 +02:00
Marien Fressinaud
75632e70f0 Provide email address verification feature (#2481)
* Add an email field to the profile page

I reuse the `mail_login` from the configuration. I'm not sure if it's
useful today (I would say it was used when Persona login was available).

A good improvement would be to rename `mail_login` into `email` so it
would be more intuitive to use.

* Add boolean to the conf to force email validation

This commit only adds a configuration item.

* Add email during registration if email must be validated

* Set email token to validate when email changes

* Block access to FreshRSS if email is not validated

* Send email when address is changed

* Allow to resend the validation email

* Allow the user to change its email while blocked

* Document the email validation feature

* fixup! Allow the user to change its email while blocked

* tec: Autoload PHPMailer lib

* Validate email address format

* Add feedback on validation email resend action

* Allow to logout when user is blocked

* fix: Change default email "from"

* Reorganize i18n keys

* Complete all the locales with default english

* Hide sidebar (profile page) if email is not validated

* Check email requirements on registration

* Allow admin to specify email when creating users

* Don't check email format if value is empty

* Remove trailing comma in userController

Co-Authored-By: Alexandre Alapetite <alexandre@alapetite.fr>

* Set PHPMailer validator to html5 before sending email

* fixup! Remove trailing comma in userController
2019-08-29 12:02:05 +02:00
Joris Kinable
cb31874085 Added option to display authors under article titles (#2487)
This feature is particularly useful to display authors underneath scientific articles.
2019-08-14 15:16:06 +02:00
Matt DeMoss
f3a88614ef Add shortcuts for focusing next and previous without opening articles. (#1767)
* add skipping option to toggleContent to use later for 'i' and 'o' hotkeys

* in English config j,k are now 'open' and not 'skip', i,o are called 'focus .. without opening'
2018-11-18 14:08:27 +01:00
Kevin Papst
8f1bad60d0 Add Fever API and user documentation (#1836)
* added fever api and documentation

* spaces to tabs

* fixed code format

* added links

* added utf8 to header

* removed XML support

* removed before check, as we have to convert it afterwards

* added sandboxed setting (currently disabled)
added support for extensions using entry_before_display

* listFeedsOrderUpdate LIMIT

https://github.com/FreshRSS/FreshRSS/pull/1836/files#r175287881

* removed custom sql by using FreshRSS_FeedDAO::listFeedsOrderUpdate()

* fixed mark all as read

* replaced custom sql for getUnread() and getStarred() with dao functions

* removed sanitization functions

* Rework fever login

* Fix config bug

Plus documentation

* Fix array syntax

For compatibility with PHP 5.3

* Disable cookies and session for API

* Fix currentUser

* added response header and error log

* adjusted phpdoc to match new authentication

* Mechanism to delete old keys

* replace PHP_INT_MAX with zero to disable limit

* replace method_exists with check for explicit methods

* removed Press support and smaller refactoring + updated docu

* Rewrite bindParamArray

Avoid one of the SQL injection risks

* Docs and readme

* Fix API link

* Simplify reverse key check

Using userConfig
2018-05-24 21:53:47 +02:00
Matt DeMoss
0936a6cdb2 Option to hide nav_entries (#1764)
* put nav_entries in a div so they can be hidden, add config option, no labels yet

* add English text for hide_nav_entries, choose better name

* Update conf.php

add comma to last item

* hide nav_entries by optionally not rendering in normal.phtml

* fix logic, remove containing div

* apply phpcbf to ConfigurationSetter.php

* Make navigation buttons options positive

And add TODOs for i18n, and add default config.
2018-02-19 15:36:18 +01:00
Alexis Degrugillier
e73fae1591 Add shortcuts to switch views (#1755) 2018-01-01 18:53:53 +01:00
Alexandre Alapetite
e811006167 sides_close_article: keep current default setting 2017-05-26 13:11:49 +02:00
Paulius Šukys
e98b510cbb Merge branch 'master' into dev 2017-05-22 11:24:52 +02:00