搜尋套件、儲存庫與 APP 分類

tdk_bouncingwidget 封面
套件詳情v1.0.4

tdk_bouncingwidget

一個輕量級的 Flutter 套件,用於在點擊 Flutter 小部件時實現彈跳動畫。提供三種類型的彈跳動畫。

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
39
喜歡數
14
Pub 分數
150

安裝套件

flutter pub add tdk_bouncingwidget

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

tdk_bouncingwidget 是一個輕量級的 Flutter 套件,可在點擊時為組件添加彈跳動畫,透過微妙的視覺反饋增強使用者互動體驗。它提供三種不同的彈跳動畫類型,讓自訂按鈕及其他互動元件的反應變得簡單。設計簡潔且效能出色,可無縫整合至跨多個平台的 Flutter 應用中。非常適合希望在不撰寫複雜程式碼的情況下提升 UI 互動性的開發者。該套件為開源並持續維護。

適用情境

  • 向按鈕新增觸覺反饋
  • 增強表單中的觸控互動
  • 建立有趣的使用者介面元件
  • 提升應用程式的回應性
  • 自訂組件按壓效果
  • 動畫圖示與卡片

主要特色

  • 三種內建的彈跳類型
  • 輕量且快速
  • 跨平台支援
  • 簡單的 API 結合
  • 開源且文件完整
  • 所需的樣板程式碼最少

適合對象

  • 尋求互動反饋的UI設計師
  • 開發行動或網頁應用的開發者
  • 需要直覺觸控回應的應用程式
  • 專注於順暢動畫的專案
  • 初學者到中級 Flutter 開發者

使用建議

  • 僅限點擊基礎的動畫
  • 無進階自訂選項
  • 可能不適合極簡主義設計風格
  • 對大型 widget 樹的效能影響
  • 不適用於複雜的手勢辨識

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

Want to animate your widgets (like containers, cards etc...) bouncing In and out while clicking? Here is the package for that.

Features

This package contains a widget, where you need to wrap your own widgets ( like container, cards ect...) to animate them bounce in and out while clicking.

bouncing-widget-eg2

Getting started

As the first step we need to add this package in pubspec.yaml file or run the following command flutter pub add tdk_bouncingwidget

Usage

Just wrap your widget inside BouncingWidgetInOut widget as shown below and we are done!!

BouncingWidgetInOut(
    onPressed: () {},
    bouncingType: BouncingType.bounceInAndOut,
    child : Container(
        height: 60,
        width: 200,
        child: const Text('click to bounce')
    ))

There is one optional parameter called "bouncingType" which specifies the bouncing type of the widget. That is "Bouncing In only" or "Bouncing out Only" or both "Bouncing In and Out". By default bouncingType is "bounceInOnly".

bounceInOnly => Widget will shrink and grow based on scale factor value.

bounceOutOnly => Widget will grow and shrink based on scale factor value.

bounceInAndOut => Widget will shrink and grow first and then it will grow and shrink based on the scale factor value.

You can even customize the bouncing animation by giving duration how much time your widgets needs to animate and how large and small your widget should grow/shrink by giving scale factor value.

Additional information

Feel free to raise an issue if anything breaking, I will try to fix that ASAP. Github link mentioned above. Thanks!

所屬分類

原始碼儲存庫

使用此套件的專案

暫無相關資料。