istornz/flutter_gaimon
一個 Flutter 外掛程式,可完全支援自訂模式的觸覺反饋 📳
- Stars
- 42
- Forks
- 11
- 最近推送(UTC)
- 2026年8月30日
- 專案狀態
- 未封存
語言DartKotlinSwiftRubyObjective-C
技術主題
使用的依賴
依賴清單 3 項
- flutter
{"sdk":"flutter"} - flutter_test開發依賴
{"sdk":"flutter"} - flutter_lints開發依賴
^6.0.0
原始 README
以下為英文專案原文快照,最新內容請造訪 GitHub。
展開 / 收合專案 README
https://raw.githubusercontent.com/istornz/gaimon/main/images/gaimon.webp?raw=true
https://img.shields.io/pub/points/gaimon?style=for-the-badge
https://img.shields.io/pub/likes/gaimon?style=for-the-badge
https://img.shields.io/pub/popularity/gaimon?style=for-the-badge
https://img.shields.io/pub/v/gaimon?style=for-the-badge
https://img.shields.io/github/stars/istornz/gaimon?style=for-the-badge
🧐 What is it ?
Gaimon is a very simple & easy to use plugin to include Haptic feedback in your app. It support custom pattern with .ahap file support.
https://raw.githubusercontent.com/istornz/gaimon/main/images/preview.webp
👻 Getting started
- Import the plugin.
import 'package:gaimon/gaimon.dart';
- Trigger haptic 📳.
Gaimon.selection();
Gaimon.success();
Gaimon.error();
// [...]
Quite simple right ? 😎
📘 Documentation
| Name | Description | Android | iOS |
|---|---|---|---|
.canSupportsHaptic() |
Check if haptic are supported or not | ✅ | ✅ |
.selection() |
Use it on a tap event | ✅ | ✅ |
.error() |
Use it when an error occur | ✅ | ✅ |
.success() |
Use it when a successful event occur | ✅ | ✅ |
.warning() |
Use it when a warning event occur | ✅ | ✅ |
.heavy() |
Huge feedback | ✅ | ✅ |
.medium() |
Medium feedback | ✅ | ✅ |
.light() |
Light feedback | ✅ | ✅ |
.rigid() |
A huge but speed feedback | ✅ | ✅ |
.soft() |
A medium but speed feedback | ✅ | ✅ |
.pattern(String data) |
Read a custom .ahap file (you can use Captain AHAP to generate file) |
✅ | ✅ |
❓ FAQ
-
Why custom pattern is not working on my iPhone?
Custom vibration patterns is only supported on iPhone 8 and newer devices.
🎯 Roadmap
- [x] Support pattern for Android (send
.ahapfile & convert it to waveform).- [x] Parse .ahab json contents
- [x] Convert events in pattern to waveform
- [x] Send waveform to android native plugin to simulate waveform
- [x] Add support for parameters (https://developer.apple.com/documentation/corehaptics/representing-haptic-patterns-in-ahap-files)
- [x] Add support for Parameter curves
- [ ] Add support for AttackTime
- [ ] Add support for DecayTime
- [ ] Add support for Sustained Events
- [ ] Support audio file to haptic feedback (generate correct feedback for audio file).
👥 Contributions
Contributions are welcome. Contribute by creating a PR or create an issue 🎉.