Skip to content

Batestinha/vector-notification-channel-collapse

Repository files navigation

Notification Channel Collapse

Notification Channel Collapse is a Vector/LSPosed module for Android and LineageOS that adds a per-notification-channel Collapse notifications toggle to the existing system notification channel behavior screen.

Vector is the newer name of the framework previously known as LSPosed. This module keeps LSPosed-compatible metadata and hooks so it can be loaded by current Vector/LSPosed installs that support legacy Xposed module entrypoints.

What It Does

  • Adds a native-looking Collapse notifications switch to each notification channel settings page.
  • Defaults the switch to on, preserving normal Android/SystemUI behavior.
  • When the switch is off for a channel, notifications from that package/channel are kept expanded in the notification shade.
  • Stores settings per Android user, app package, and notification channel ID.
  • Targets the system notification settings UI and SystemUI notification rows only.

This was developed and tested on a Pixel 7a (lynx) running LineageOS 23.2.

Scope

The module declares these default scopes:

  • android
  • com.android.settings
  • com.android.systemui

The Settings hook injects the user-facing toggle into the existing notification category behavior screen. The SystemUI hook reads the stored channel setting and applies the expansion policy to matching notification rows.

Install

  1. Install the release APK.
  2. Enable the module in Vector/LSPosed.
  3. For work profiles, install the module package for that profile too. With root/ADB, tools/apply-lsposed-module-config.sh does this with pm install-existing --user ... for every user/profile and inserts the LSPosed scope rows.
  4. Confirm the scopes include android, com.android.settings, and com.android.systemui for each Android profile where you use the module, including work profiles.
  5. Reboot the phone so Vector/LSPosed reloads the updated per-profile module install and scope state.
  6. Open any notification channel behavior screen and set Collapse notifications as desired.

Build

Debug build:

./gradlew :app:assembleDebug

For a signed release APK, create an ignored local.properties file with:

releaseStoreFile=keystore/notification-channel-collapse-release.jks
releaseStorePassword=...
releaseKeyAlias=notification-channel-collapse
releaseKeyPassword=...

Then build:

./gradlew :app:assembleRelease

The signed APK is written to:

app/build/outputs/apk/release/app-release.apk

Release Status

Version 1.0.2 has been tested on Pixel 7a with Vector/LSPosed loading hooks into Settings and SystemUI, including a work profile (user 10) after installing the module package for that profile. The initial release line is intentionally narrow and focused on LineageOS/AOSP-style notification UI behavior.

About

Vector/LSPosed module that adds a per-channel Collapse notifications toggle to Android notification channel settings.

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors