Skip to content

feat: added 'Apply to summaries' toggle to blocklist feature#1003

Merged
spacecowboy merged 4 commits into
spacecowboy:masterfrom
linuxhd0:feature/blocklist-apply-to-summaries
Feb 17, 2026
Merged

feat: added 'Apply to summaries' toggle to blocklist feature#1003
spacecowboy merged 4 commits into
spacecowboy:masterfrom
linuxhd0:feature/blocklist-apply-to-summaries

Conversation

@linuxhd0

Copy link
Copy Markdown
Contributor

Adds an optional toggle to the blocklist settings that allows filtering articles based on their summaries/descriptions in addition to titles.

  • Toggle defaults to OFF (title-only filtering, less aggressive)
  • When enabled, checks both article titles and RSS descriptions
  • Settings state persists across app restarts
  • Includes 11 passing tests (unit and instrumented)

The feature uses SQLite glob pattern matching and integrates with the existing BlocklistUpdateJob to re-apply filters when toggle changes.

Adds an optional toggle to the blocklist settings that allows filtering
articles based on their summaries/descriptions in addition to titles.

- Toggle defaults to OFF (title-only filtering, less aggressive)
- When enabled, checks both article titles and RSS descriptions
- Settings state persists across app restarts
- Includes 11 passing tests (unit and instrumented)

The feature uses SQLite glob pattern matching and integrates with the
existing BlocklistUpdateJob to re-apply filters when toggle changes.

@spacecowboy spacecowboy left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I think it is a good change

See one comment about parameter ordering though. Otherwise LGTM

(Sorry for the delay, I've been without a proper computer for a while)

Comment on lines +52 to +60
showToggle: Boolean = false,
toggleValue: Boolean = false,
toggleLabel: String = "",
onToggleChange: (Boolean) -> Unit = {},

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This breaks conventional order of arguments for compose

The order should be values, lambdas, modifier

items: ImmutableHolder<List<String>>,
showToggle: Boolean = false,
toggleValue: Boolean = false,
toggleLabel: String = "",
onDismiss: () -> Unit,
onRemoveItem: (String) -> Unit,
onAddItem: (String) -> Unit,
onToggleChange: (Boolean) -> Unit = {},
modifier: Modifier = Modifier,

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Move value parameters before lambdas, and modifier to end in EditableListDialog
and ListDialogSetting. Follows Compose convention of: values -> lambdas -> modifier.
@linuxhd0

Copy link
Copy Markdown
Contributor Author

I appreciate the work you put into this.

@linuxhd0 linuxhd0 requested a review from spacecowboy January 31, 2026 20:14
@spacecowboy

Copy link
Copy Markdown
Owner

You can see the output of the ktlint CI check. Modifier should be the first optional argument. Possibly something else needs moving too

EditableListDialog.kt:50

/home/runner/work/Feeder/Feeder/app/src/main/java/com/nononsenseapps/feeder/ui/compose/dialog/EditableListDialog.kt:50:5 Parameters in a composable function should be ordered following this pattern: params without defaults, modifiers, params with defaults and optionally, a trailing function that might not have a default param.
* What went wrong:
Current params are: [title: @Composable () -> Unit, items: ImmutableHolder<List<String>>, showToggle: Boolean = false, toggleValue: Boolean = false, toggleLabel: String = "", onDismiss: () -> Unit, onRemoveItem: (String) -> Unit, onAddItem: (String) -> Unit, onToggleChange: (Boolean) -> Unit = {}, modifier: Modifier = Modifier] 

but could be [title: @Composable () -> Unit, items: ImmutableHolder<List<String>>, onDismiss: () -> Unit, onRemoveItem: (String) -> Unit, onAddItem: (String) -> Unit, modifier: Modifier = Modifier, showToggle: Boolean = false, toggleValue: Boolean = false, toggleLabel: String = "", onToggleChange: (Boolean) -> Unit = {}].

Settings.kt:1008

/home/runner/work/Feeder/Feeder/app/src/main/java/com/nononsenseapps/feeder/ui/compose/settings/Settings.kt:1008:5 Parameters in a composable function should be ordered following this pattern: params without defaults, modifiers, params with defaults and optionally, a trailing function that might not have a default param.
Current params are: [title: String, dialogTitle: @Composable () -> Unit, currentValue: ImmutableHolder<List<String>>, showToggle: Boolean = false, toggleValue: Boolean = false, toggleLabel: String = "", icon: @Composable () -> Unit = {}, onAddItem: (String) -> Unit, onRemoveItem: (String) -> Unit, onToggleChange: (Boolean) -> Unit = {}, modifier: Modifier = Modifier] 

but could be [title: String, dialogTitle: @Composable () -> Unit, currentValue: ImmutableHolder<List<String>>, onAddItem: (String) -> Unit, onRemoveItem: (String) -> Unit, modifier: Modifier = Modifier, showToggle: Boolean = false, toggleValue: Boolean = false, toggleLabel: String = "", icon: @Composable () -> Unit = {}, onToggleChange: (Boolean) -> Unit = {}].

linuxhd0 and others added 2 commits February 9, 2026 13:52
Completes the parameter reordering from the previous commit by moving
required lambda parameters before the modifier, as required by the
ktlint compose rules. All optional parameters now follow the modifier.

Co-authored-by: Cursor <[email protected]>
@spacecowboy spacecowboy changed the title Add 'Apply to summaries' toggle to blocklist feature fix: added 'Apply to summaries' toggle to blocklist feature Feb 17, 2026
@spacecowboy spacecowboy changed the title fix: added 'Apply to summaries' toggle to blocklist feature feat: added 'Apply to summaries' toggle to blocklist feature Feb 17, 2026
@spacecowboy

Copy link
Copy Markdown
Owner

thanks @linuxhd0 !

@spacecowboy spacecowboy merged commit 3cced03 into spacecowboy:master Feb 17, 2026
7 of 12 checks passed
jenningsloy318 added a commit to jenningsloy318/Feeder that referenced this pull request Mar 30, 2026
Incorporate upstream changes from master (v2.17.0, v2.18.0) while
preserving all AI features developed on ai-features branch.

Upstream features incorporated:
- Paging mode with volume buttons and tap zones (spacecowboy#1062)
- Home screen widget support (spacecowboy#1018)
- Blocklist apply-to-summaries toggle (spacecowboy#1003)
- AGP 9.0.0 + OkHttp 5.3.2 upgrade (spacecowboy#1051)
- LazyColumn to Column migration for text selection crash fix (spacecowboy#1045)
- Read item opacity (spacecowboy#996)
- Bug fixes: sync deletion, compact layout scroll, network crash
- 20+ language i18n updates via Weblate

AI features preserved:
- Multi-provider AI architecture (OpenAI + Anthropic)
- Per-paragraph translation with circular progress
- Mikepenz markdown rendering for summaries
- Text selection menu customization
- Summary/translation cancellation support

Resolved 10 merge conflicts (3 HIGH, 3 MEDIUM, 4 LOW).
Deleted superseded openai/ package and LeakCanary references.
Re-indexed SettingsViewModel combine() params (35 total).
Added mainActivityViewModel parameter to all 13 navigation destinations.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants