[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-107619":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":9,"pushedAt":35,"updatedAt":36,"readmeContent":37,"aiSummary":38,"trendingCount":15,"starSnapshotCount":15,"syncStatus":39,"lastSyncTime":40,"discoverSource":41},107619,"slidesense","shashvat1965\u002Fslidesense","shashvat1965","Turn the edges of your MacBook trackpad into volume and brightness sliders. Native macOS menu bar app with a Liquid Glass HUD, haptics and a media strip.",null,"Swift",203,36,1,3,0,13,57,82,65,92.87,"MIT License",false,"main",true,[26,27,28,29,30,31,32,33,34],"brightness","liquid-glass","macos","macos-app","menu-bar","swift","swiftui","trackpad","volume","2026-11-02 19:56:28","2026-11-23 07:00:04","# SlideSense\n\n\u003Cimg src=\"docs\u002Fsocial-preview.png\" alt=\"SlideSense: volume and brightness on the edges of your trackpad\" width=\"100%\">\n\n**Slide the edges of your MacBook trackpad to change volume and brightness.**\n\nSlideSense is a free, MIT-licensed menu bar app for macOS 13+. The left and right\nedges of the trackpad become a brightness and volume slider, with haptics, a\nmatching on-screen display, quick mute, and a media strip along the bottom edge.\n\n```\n        ┌───────────────────────────────┐\n        │                               │\n  bright│ · · · · · · · · · · · · · · · │volume\n        │                               │\n        └───────────────────────────────┘\n              ^ swipe up\u002Fdown on an edge\n```\n\n## Features\n\n| | |\n|---|---|\n| **Left edge → brightness** | Slide up\u002Fdown anywhere along the left band. |\n| **Right edge → volume** | Slide up\u002Fdown anywhere along the right band. |\n| **On-screen display** | A Liquid Glass panel on macOS 26, a frosted HUD before that. |\n| **Haptics** | A physical tick as the level crosses each step. |\n| **Precise sliding** | Quarter steps instead of sixteenths — always on, or only while holding ⇧⌥. |\n| **Bottom quarter only** | Restrict the side bands to the lower quarter of the pad. |\n| **Require a modifier** | Demand FN, Option or Control before an edge responds. |\n| **Cursor freeze** | The pointer stays put and hidden while you slide. |\n| **Quick Mute** | Double-tap the top-right corner. |\n| **Media strip** | Swipe along the bottom edge to skip; double-tap to play\u002Fpause. |\n| **Swap sides** | Brightness on the right if you prefer. |\n| **Menu bar only** | No Dock icon. Idle CPU is effectively zero. |\n| **Open at login** | Via `SMAppService`, no helper daemon. |\n| **Auto-update** | Checks GitHub releases daily, verifies the SHA-256, swaps the bundle. |\n\n## Screenshots\n\n| | |\n|---|---|\n| ![Edges settings](docs\u002Fscreenshots\u002Fsettings-edges.png) | ![General settings](docs\u002Fscreenshots\u002Fsettings-general.png) |\n| The edge bands, sensitivity and axis fix. | Permissions, HUD and startup, in one place. |\n\n| | |\n|---|---|\n| ![Volume HUD](docs\u002Fscreenshots\u002Fhud-volume.png) | ![Brightness HUD](docs\u002Fscreenshots\u002Fhud-brightness.png) |\n| Volume on the right edge. | Brightness on the left edge. |\n\nThese are rendered straight from the app's own views at 2× by `make snapshots`\n(the glass material is drawn by the system, so it does not appear in an\noffscreen render).\n\n## Requirements\n\n- macOS 13 Ventura or later (Liquid Glass appears on macOS 26)\n- A built-in Force Touch trackpad (the one in every MacBook since 2015)\n- Xcode 15+ **or** the Swift 6 toolchain, to build\n- Accessibility permission for the media strip and key-event fallbacks\n\nMagic Mouse support is not implemented yet — see [Roadmap](#roadmap).\n\n## Install\n\n1. Download `SlideSense-0.1.0.zip` from [Releases](https:\u002F\u002Fgithub.com\u002Fshashvat1965\u002Fslidesense\u002Freleases).\n2. Unzip it and drag **SlideSense.app** into `\u002FApplications`.\n3. The build is ad-hoc signed but not notarised, so the first launch shows\n   *\"Apple could not verify SlideSense is free of malware\"* → click **Open**\n   (or **System Settings → Privacy & Security → Open Anyway**). It never asks\n   again. Building it yourself with `make run` avoids this entirely.\n\n   If macOS instead says *\"SlideSense is damaged\"*, the download picked up a\n   stale signature — run `xattr -dr com.apple.quarantine \u002FApplications\u002FSlideSense.app`\n   and open it again.\n\nOr build it yourself — it takes about ten seconds:\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Fshashvat1965\u002Fslidesense.git\ncd slidesense\n\nmake app        # builds SlideSense.app in the repo root\nmake run        # builds and opens it\nmake install    # copies it to \u002FApplications\nmake test       # runs the unit and UI-layout tests\n```\n\n`make app` ad-hoc signs the bundle (`codesign --sign -`): a real signature with\nno identity behind it, so it validates locally and Gatekeeper can offer\n*Open Anyway* instead of calling the app damaged. Because the signature changes\non every rebuild, macOS may ask for Accessibility permission again — that is\nexpected.\n\nOn first launch macOS shows an Accessibility prompt. Approve it in\n**System Settings → Privacy & Security → Accessibility**. Without it the edge\nsliders still work; the media strip and any key-event fallback do not.\n\n> Gatekeeper: if you download a prebuilt copy, right-click → Open the first time.\n> This project does not ship notarised binaries.\n\n## How to use it\n\n| Gesture | Result |\n|---|---|\n| Slide up\u002Fdown on the left band | Brightness |\n| Slide up\u002Fdown on the right band | Volume |\n| Hold ⇧⌥ while sliding | Quarter steps |\n| Double-tap the top-right corner | Mute \u002F unmute |\n| Swipe left\u002Fright on the bottom band | Next \u002F previous track |\n| Double-tap the bottom band | Play \u002F pause (off by default) |\n\nA slide always starts from the current system level, so you can nudge from\nwherever you are. Because the level is absolute, dragging back down gives the\nvalue back instead of drifting.\n\nMulti-finger touches are left alone: as soon as a second finger lands, SlideSense\nhands the gesture back to macOS, so scrolling, zooming and swiping still work.\nTouches that start in the middle of the pad are ignored, and quick taps on an\nedge do nothing.\n\n## The menu\n\nDeliberately short:\n\n```\nVolume        81%\nBrightness    69%\n─────────────\n✓ Enabled\nSettings…     ⌘,\n─────────────\nQuit SlideSense ⌘Q\n```\n\nThe two readouts are live and non-interactive. Everything else lives in\nSettings, so the menu stays a glance, not a control panel.\n\n## Settings\n\nFive tabs in a standard macOS preferences window:\n\n- **Edges** — what each side controls, band width, sensitivity, bottom-quarter\n  mode, required modifier, vertical-axis flip.\n- **Feel** — cursor freeze, precise sliding, ⇧⌥ fine control, haptics and\n  strength.\n- **Media** — Quick Mute, media strip, reverse swipe, tap to play\u002Fpause. Turn\n  all four off and the app does nothing but brightness and volume.\n- **Startup** — open at login, automatic update checks, version, check now.\n- **General** — Accessibility permission, HUD visibility and appearance, restore\n  defaults.\n\nSettings are stored as JSON under `io.github.slidesense.settings.v1` in\n`UserDefaults`.\n\n## How it works\n\nThree small pieces, no background daemon, no kernel extension:\n\n1. **Reading the trackpad** — `MultitouchSupport.framework`, Apple's private\n   multitouch driver, is loaded with `dlopen`. Its contact-frame callback gives\n   normalised finger positions (0…1, origin bottom-left) at the hardware frame\n   rate. This is the same API used by many open-source trackpad utilities and is\n   why SlideSense needs no event tap, no polling and no timer: frames arrive from\n   the driver, and when nothing touches the pad the process is asleep. Idle CPU\n   measures 0.0 %.\n\n2. **Deciding what a gesture means** — `SlideEngine` is a pure state machine: it\n   takes frames of contacts and emits `beginSlide` \u002F `updateSlide` \u002F `endSlide` \u002F\n   `media` events. Edge geometry, corner detection, tap vs. slide, double-tap,\n   dropped-frame tolerance and step quantisation all live here, which is why they\n   are covered by unit tests and can be exercised without a trackpad.\n\n3. **Changing the system level** — volume goes through CoreAudio\n   (`AudioObjectSetPropertyData` on the default output device, with fallbacks for\n   devices that only expose per-channel scalars). Brightness goes through\n   `DisplayServices.framework` (`DisplayServicesSetBrightness`), the same private\n   framework the brightness keys use; if it is unavailable SlideSense falls back\n   to posting brightness key events. Media commands are posted as system-defined\n   key events (`NX_KEYTYPE_PLAY`, etc. via `CGEvent.post`).\n\n   Nothing polls for changes. Volume and mute updates arrive as CoreAudio\n   property callbacks; brightness is read once when a finger lands and again when\n   the menu opens, which is the only moment the readout is visible.\n\nPrivate frameworks are, by definition, not guaranteed to keep working across\nmacOS releases. `MultitouchSupport` and `DisplayServices` have been stable for\nmany years and are used by a large number of shipping apps, but treat this as\n\"works today\" rather than \"Apple promises it\". Every private call is\nfeature-detected: if it disappears, the app degrades instead of crashing.\n\n### The HUD\n\nThe panel is 210 × 60 pt with a 16 pt continuous corner radius, a 14 pt content\ninset, a 22 pt icon box, a 12 pt gap and an 8 pt level bar with 4 pt caps. On\nmacOS 26 and later the background is a real `NSGlassEffectView` (Liquid Glass);\non macOS 13–15 it falls back to an `NSVisualEffectView` with the `.hudWindow`\nmaterial. Both draw the same content, so the layout is identical on every OS.\n\n### Where the bars are\n\nNormalised trackpad coordinates are `x: 0 (left) → 1 (right)` and\n`y: 0 (bottom, near you) → 1 (top, near the screen)`. The edge band is\n`edgeWidth` wide (default 18 %). If your Mac reports the vertical axis the other\nway round, the **Flip vertical edges** setting corrects it.\n\n## Testing\n\n```bash\nmake test            # geometry, gesture engine, HUD layout, settings window\nmake snapshots       # writes PNGs of every UI state to .\u002FSnapshots\n```\n\n`make snapshots` renders the HUD in nine states (0 %, 1 %, 50 %, 100 %, muted,\nbrightness, and three media symbols) and the settings window on all five tabs, in\nlight and dark appearance, at 2× — so padding and alignment can be checked\nwithout a screen recording permission.\n\nDiagnostics: `make dump-touches` prints live contacts (`id`, `x`, `y`, touch\nstate) and `swift run SlideSense --diagnose` prints the state of every subsystem.\n\n## Troubleshooting\n\n| Symptom | Fix |\n|---|---|\n| Nothing happens on the edges | Check the menu bar shows ✓ Enabled, and that **Edge width** is not too small. |\n| Volume works, brightness does not | Your display may not expose `DisplayServices` brightness (external monitors). SlideSense falls back to key events, which only affect the built-in panel. |\n| Sliding up decreases the level | Turn on **Flip vertical edges** in Settings → Edges. |\n| Media keys do nothing | Grant Accessibility access in Settings → General. |\n| Permission prompt keeps coming back | Every rebuild replaces the binary; re-approve the new copy in System Settings. |\n| Slides stop halfway | Update — 0.1.0 tolerates a dropped contact for ~120 ms. |\n| Two-finger gestures feel different | They are untouched by design; if something still feels off, disable **Media strip**, which owns the bottom band. |\n| Trackpad stops after sleep | SlideSense restarts the device 1.5 s after wake; if it persists, toggle the app off\u002Fon from the menu. |\n\n## Privacy\n\nNo analytics, no crash reporting, no accounts. Everything is local: the app reads\nthe trackpad, writes volume\u002Fbrightness, and stores its own settings in\n`UserDefaults`.\n\nThe single network request is the update check: once a day, a `GET` to\n`api.github.com\u002Frepos\u002Fshashvat1965\u002Fslidesense\u002Freleases\u002Flatest`. It sends nothing\nabout you or the machine, and it can be turned off in Settings → Startup.\n\n## Roadmap\n\n- [ ] Magic Mouse top-edge support\n- [ ] Per-edge actions beyond brightness\u002Fvolume (keyboard backlight, scroll speed)\n- [ ] Onboarding tour with a live trackpad map\n- [ ] Notarised release builds\n- [ ] Menu bar icon themes\n\n## Project layout\n\n```\nSources\u002FSlideSenseCore\u002F\n  Model\u002F         Settings, edge geometry, the gesture state machine\n  Multitouch\u002F    dlopen bindings for MultitouchSupport + the frame monitor\n  System\u002F        CoreAudio, DisplayServices, media keys, haptics, permissions\n  UI\u002F            Menu bar item, settings window, HUD\n  AppCoordinator.swift, AppDelegate.swift\nSources\u002FSlideSense\u002F    entry point\nTests\u002FSlideSenseCoreTests\u002F  geometry, gesture engine, HUD layout, settings window\nscripts\u002Fbuild-app.sh       assembly of the .app bundle\nscripts\u002Fmake-icon.swift    icon generator\n```\n\n## Contributing\n\nIssues and pull requests are welcome — see [CONTRIBUTING.md](CONTRIBUTING.md) for\nthe setup, the test suite and the review process. Run `make test` before sending a\nchange, keep hardware-facing code behind a protocol so it can be faked in tests,\nand add a snapshot when you touch the UI.\n\nSecurity issues: please email rather than opening a public issue, see\n[SECURITY.md](SECURITY.md).\n\n## Licence\n\nMIT — see [LICENSE](LICENSE).\n","SlideSense 是一款 macOS 原生菜单栏应用，将 MacBook 触控板左右边缘转化为亮度与音量的物理滑动控制区域。核心功能包括：左右边缘分别映射亮度\u002F音量调节、液态玻璃（Liquid Glass）HUD 叠加层（macOS 26+）、触觉反馈（haptics）、底部边缘媒体控制条（播放\u002F暂停、跳过）、光标冻结、快捷静音及多档灵敏度设置。所有操作无需 Dock 图标，后台资源占用极低，支持自动更新与系统权限安全集成。适用于追求高效、无打断式硬件级系统控制的 MacBook 用户，尤其适合频繁调整音画参数的创作者、开发者及日常办公场景。",2,"2026-11-24 04:32:26","CREATED_QUERY"]