feature(settings): adds setting for default number of items per page

Most queries that default to 10 now use the setting, whose valid range
is, for now, 2 to 5000. In order to keep this simple, queries that
default to 20 items will continue showing at least 20 items; the setting
is used only if it’s greater than 20.

Fixes #2650
I don't see why not.  I think 1 could be an acceptable value.  Most sites would likely go OOM well before 5000 so that seems pretty arbitrary on the upper side.