聯絡人選擇器
一個用於從通訊錄中選擇聯絡人的 Flutter 插件。
- 星標
- 18
- 分支
- 43
- 最近推送(UTC)
- 2024年3月15日
- 專案狀態
- 已封存
原始 README
以下為英文專案原文快照,最新內容請造訪 GitHub。
fluttercontactpicker
Interact with native OS contact pickers using Flutter
Note: This plugin requires at least Kotlin 1.5.0 to compile. See (#38 (comment) for more information)
Web demo: https://fcp.mik.wtf/
Contents
Getting Started
Grab contact.
final PhoneContact contact =
await FlutterContactPicker.pickPhoneContact();
For more info read the docs or take a look at the example
Features
- Pick a phone/email contact using the OSs native contact picker
- Pick a Full contact (except iOS)
- Support Flutter Web
Permissions
If you target Android 11+ (API 30+) you need to obtain the android.permission.READ_CONTACTS permission, which is declared as a library permission here this permission will be requested automatically if the askForPermission parameter is true.
Alternatively you can request the permission manually with FlutterContactPicker.requestPermission() or check with FlutterContactPicker.hasPermission()
Obtain Full Contact (Android Only)
Note: Unlike Android iOS does not offer a way to directly get a full contact from the ContactPicker therefore this library does not support it. Apple might add it in 2030 so stay tuned
final FullContact contact =
await FlutterContactPicker.pickFullContact();
Obtain profile picture
The FullContact class has a photo property if the picked contact has an avatar. You can use the asWidget() method to get a renderable Image widget.
Full documentation: https://pub.dev/documentation/fluttercontactpicker/latest/fluttercontactpicker/fluttercontactpicker-library.html
Web support
This plugin also supports the Web Contact Picker API.
分類
如何選擇適合專案的儲存庫?
先依使用情境篩選,再比較專案活躍情況,最後到原始儲存庫確認使用要求。
- 透過儲存庫名稱、作者或描述搜尋,再依技術分類縮小範圍。
- 綜合星標、分支與最近推送比較專案;星標反映社群關注,不保證品質。
- 使用前在 GitHub 確認 README、授權條款與 Issues。
來源與維護
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗