搜索插件、代码仓与 APP 分类

bubble_lens 封面
插件详情v2.0.0

bubble_lens

Flutter 可自定义的 Apple Watch UI 动画复现

AndroidiOSWebmacOSWindowsLinux
近 30 天下载
2290
喜欢数
101
Pub 分数
155

安装插件

flutter pub add bubble_lens

插件介绍

基于插件公开信息、社区数据与项目使用情况整理的选型参考。

Bubble Lens 是一个 Flutter 包,重现了 Apple Watch 的标志性 UI 动画,提供可自定义的镜头效果,模拟放大泡泡叠加层。它使开发者能够为元素添加动态、交互式的视觉反馈,非常适合触摸交互或焦点高亮。该包支持 Android、iOS、Web、macOS、Windows 和 Linux 多个平台,确保在不同设备上行为一致。凭借流畅的动画和灵活的配置选项,它提升了需要直观、触觉反馈的应用程序的用户体验。

适合场景

  • 交互式触觉反馈
  • UI中的焦点高亮
  • Apple Watch 风格的动画
  • 增强的手势识别
  • 移动应用中的视觉效果
  • 跨平台动画叠加

主要特点

  • 可自定义的镜片尺寸和形状
  • 平滑缩放动画
  • 对多平台的支持
  • 可配置的不透明度和模糊
  • 基于手势的激活
  • 响应式设计集成

适合对象

  • 寻求苹果手表风格用户体验的开发者
  • 需要细微交互反馈的应用
  • 专注于微交互的设计人员
  • 跨平台应用开发者
  • UI/UX 爱好者
  • 原型设计交互式界面

使用建议

  • 使用多个镜头时的性能影响
  • 需要仔细调整以获得最佳用户体验
  • 可能不适合所有设计风格
  • 超出核心动画之外的自定义功能有限
  • 建议谨慎使用,以避免分散注意力
  • 依赖于平台特定的渲染功能

原始 README

以下为关联源码仓库的 README 原文快照,最新内容请访问源码仓库。

Bubble Lens

pub package

A reproduction of the Apple Watch UI animation

Example

Usage

Import the package
import 'package:bubble_lens/bubble_lens.dart';
Use the package
BubbleLens(
    width: 250,
    height: 250,
    widgets: [
        Container(
            width: 100,
            height: 100,
            color: Colors.red
        ),
        ...
    ]
);

Required Parameters

Prop Type Default Description
width double N/A Width of the container.
height double N/A Height of the container.
widgets List N/A List of widgets to display.

Optional Parameters

Prop Type Default Description
size double 100 Maximum size of a widget.
paddingX double 10 Horizontal padding between widgets.
paddingY double 0 Vertical padding between widgets.
duration Duration Duration(milliseconds: 100) Animation's duration.
radius Radius Radius.circular(999) Widget's radius.
highRatio double 0 High ratio, should be >= 0.
lowRatio double 0 Low ratio, should be >= 0.

Example

Find the example wiring in the Bubble Lens example application.

Details

See the bubble_lens.dart for more details.

Issues and feedback

Please file issues to send feedback or report a bug. Thank you!

所属分类

源码仓库

使用此插件的项目

暂无相关数据。