aboutsummaryrefslogtreecommitdiff
path: root/app/Models/ConfigurationSetter.php
diff options
context:
space:
mode:
authorGravatar ORelio <ORelio@users.noreply.github.com> 2021-08-30 10:58:06 +0200
committerGravatar GitHub <noreply@github.com> 2021-08-30 10:58:06 +0200
commit50ba6bbe07b0bb86eb07e3212ba2e22cb2878cf2 (patch)
tree3e54faf8e06be88468d0be1e9df808f88691194e /app/Models/ConfigurationSetter.php
parent812eda1fa05e370c4c1645b5b82f09f9da2c7bf7 (diff)
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>
Diffstat (limited to 'app/Models/ConfigurationSetter.php')
-rw-r--r--app/Models/ConfigurationSetter.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/app/Models/ConfigurationSetter.php b/app/Models/ConfigurationSetter.php
index 6fc056eb2..ee58ebe5b 100644
--- a/app/Models/ConfigurationSetter.php
+++ b/app/Models/ConfigurationSetter.php
@@ -254,6 +254,16 @@ class FreshRSS_ConfigurationSetter {
private function _topline_read(&$data, $value) {
$data['topline_read'] = $this->handleBool($value);
}
+ private function _topline_thumbnail(&$data, $value) {
+ $value = strtolower($value);
+ if (!in_array($value, array('none', 'portrait', 'square', 'landscape'))) {
+ $value = 'none';
+ }
+ $data['topline_thumbnail'] = $value;
+ }
+ private function _topline_summary(&$data, $value) {
+ $data['topline_summary'] = $this->handleBool($value);
+ }
private function _topline_display_authors(&$data, $value) {
$data['topline_display_authors'] = $this->handleBool($value);
}