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

autocomplete_textfield_ns 封面
套件詳情v2.0.0

autocomplete_textfield_ns

一個簡單且多功能的 Flutter 自動補全文字欄位,支援多種資料類型。

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
425
喜歡數
31
Pub 分數
130

安裝套件

flutter pub add autocomplete_textfield_ns

套件介紹

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

一個靈活且輕量級的自動完成文字欄位組件,適用於 Flutter,支援多種資料類型,讓使用者能從動態建議中搜尋並選擇。設計簡潔且可自訂,可無縫整合至跨多個平台的表單與輸入欄位中。此套件非常適合透過即時過濾與直覺的下拉建議來提升使用者體驗。它可在 Android、iOS、Web、macOS、Windows 與 Linux 上運作,使其在跨平台應用中具有高度的多功能性。

適用情境

  • 帶有動態建議的表單輸入
  • 具有即時過濾功能的搜尋欄
  • 支援輸入的下拉選擇
  • 使用標籤輸入建立使用者資料
  • 帶預測文字的資料輸入

主要特色

  • 支援多種資料類型
  • 即時建議過濾
  • 可自訂的 UI 與樣式
  • 跨平台相容性
  • 與現有表單的簡單整合
  • 可設定的去抖延遲

適合對象

  • 開發搜尋介面的開發者
  • 需要快速資料輸入的應用程式
  • 跨平台 Flutter 項目
  • 需要智慧輸入協助的表單
  • 重視使用便利性與自訂功能的團隊

使用建議

  • 可能需要為複雜資料來源自訂邏輯
  • 效能取決於建議清單的大小
  • 有限的內建驗證功能
  • 未針對無分頁的大資料集進行優化
  • 需要手動處理選擇事件

原始 README

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

autocomplete_textfield_ns

An autocomplete textfield for flutter

Pull requests

Feel free to submit pull requests for desired changes / features / bug fixes... It makes the maintenance of this code much easier.

Usage

AutoCompleteTextField supports any data type suggestions AutoCompleteTextField<YOURDATATYPE>()
The suggestions parameter must have data that matches <YOURDATATYPE>
A global key of type GlobalKey<AutoCompleteTextFieldState<T>> is required so that the clear() method can be called to clear AutoCompleteTextField.

Strings and itemFilter

Filtering is case sensitive so when using strings a common implementation of itemFilter is .

itemFilter: (item, query) {
  return item.toLowerCase().startsWith(query.toLowerCase());
}

Textfield Demo

所屬分類

原始碼儲存庫

使用此套件的專案

暫無相關資料。