island_snack 0.1.0
island_snack: ^0.1.0 copied to clipboard
Dynamic Island-style notifications for Flutter iOS apps. Spring physics animations that expand from the island position.
0.1.0 #
Initial release.
Features #
- Dynamic Island detection — automatically detects iPhone models with Dynamic Island and positions the notification pill to match the hardware cutout exactly. Falls back gracefully on older devices.
- Spring physics animations — expand and collapse driven by real spring simulations. Underdamped expand for organic overshoot, critically-damped collapse for snappy retract.
- Staggered content reveal — icon, title, subtitle, and action cascade in with per-element fade and slide during the expand phase.
- Preset styles —
success,error,warning,info, andloadingconvenience methods with curated accent colors (rCoon palette). - Queue system — multiple notifications are queued and shown sequentially. Urgent priority clears the queue and replaces the current notification.
- ID-based updates — assign an ID to a notification and update it in-place (e.g., loading → success transitions).
- Swipe-to-dismiss — drag up to dismiss any notification.
- Action buttons — optional action pill (e.g., "Undo") with tap callback.
- Progress bar — optional linear progress indicator with accent color.
- Custom duration — override the enum-based duration with any
Duration. - Theming —
IslandSnackThemeinherited widget for global color, font, duration, and haptic overrides. - Haptic feedback — configurable light, medium, or heavy impact on show.
- Accessibility —
Semanticslive region for VoiceOver announcements, semantic labels on actions, decorative elements excluded. - Callbacks —
onDismissedandonShownper-notification callbacks. isShowing/isDynamicIsland— static getters for querying state.