{"id":13784709,"url":"https://github.com/leanflutter/clipboard_watcher","last_synced_at":"2025-04-07T08:16:59.603Z","repository":{"id":41538185,"uuid":"483276930","full_name":"leanflutter/clipboard_watcher","owner":"leanflutter","description":"This plugin allows Flutter apps to watch clipboard changes.","archived":false,"fork":false,"pushed_at":"2025-03-23T04:07:15.000Z","size":272,"stargazers_count":56,"open_issues_count":4,"forks_count":18,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-03-31T07:04:50.441Z","etag":null,"topics":["clipboard","clipboard-watch"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/clipboard_watcher","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leanflutter.png","metadata":{"files":{"readme":"README-ZH.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"lijy91"}},"created_at":"2022-04-19T14:17:39.000Z","updated_at":"2025-03-23T04:07:19.000Z","dependencies_parsed_at":"2025-01-15T20:22:49.982Z","dependency_job_id":"142c706d-e377-4b2a-973b-66c29592e920","html_url":"https://github.com/leanflutter/clipboard_watcher","commit_stats":{"total_commits":25,"total_committers":6,"mean_commits":4.166666666666667,"dds":"0.19999999999999996","last_synced_commit":"8d764c454fcf3f78e116ec39514fbc1464bb4865"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leanflutter%2Fclipboard_watcher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leanflutter%2Fclipboard_watcher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leanflutter%2Fclipboard_watcher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leanflutter%2Fclipboard_watcher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leanflutter","download_url":"https://codeload.github.com/leanflutter/clipboard_watcher/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247615382,"owners_count":20967184,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clipboard","clipboard-watch"],"created_at":"2024-08-03T19:00:51.405Z","updated_at":"2025-04-07T08:16:59.572Z","avatar_url":"https://github.com/leanflutter.png","language":"C++","readme":"\u003e **🚀 快速发布您的应用**: 试试 [Fastforge](https://fastforge.dev) - 构建、打包和分发您的 Flutter 应用最简单的方式。\n\n# clipboard_watcher\n\n[![pub version][pub-image]][pub-url] [![][discord-image]][discord-url] ![][visits-count-image] [![All Contributors][all-contributors-image]](#contributors)\n\n[pub-image]: https://img.shields.io/pub/v/clipboard_watcher.svg\n[pub-url]: https://pub.dev/packages/clipboard_watcher\n[discord-image]: https://img.shields.io/discord/884679008049037342.svg\n[discord-url]: https://discord.gg/zPa6EZ2jqb\n[visits-count-image]: https://img.shields.io/badge/dynamic/json?label=Visits%20Count\u0026query=value\u0026url=https://api.countapi.xyz/hit/leanflutter.clipboard_watcher/visits\n[all-contributors-image]: https://img.shields.io/github/all-contributors/leanflutter/clipboard_watcher?color=ee8449\u0026style=flat-square\n\n这个插件允许 Flutter 应用程序观察剪贴板的变化。\n\n---\n\n[English](./README.md) | 简体中文\n\n---\n\n\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n\n- [平台支持](#%E5%B9%B3%E5%8F%B0%E6%94%AF%E6%8C%81)\n- [快速开始](#%E5%BF%AB%E9%80%9F%E5%BC%80%E5%A7%8B)\n  - [安装](#%E5%AE%89%E8%A3%85)\n  - [用法](#%E7%94%A8%E6%B3%95)\n- [谁在用使用它？](#%E8%B0%81%E5%9C%A8%E7%94%A8%E4%BD%BF%E7%94%A8%E5%AE%83)\n- [贡献者](#%E8%B4%A1%E7%8C%AE%E8%80%85)\n- [许可证](#%E8%AE%B8%E5%8F%AF%E8%AF%81)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n## 平台支持\n\n| 平台    | 支持                                                                   |\n| ------- | :--------------------------------------------------------------------- |\n| Linux   | ✔️ 完全支持                                                            |\n| macOS   | ✔️ 完全支持                                                            |\n| Windows | ✔️ 完全支持                                                            |\n| iOS     | 14+ 需要用户权限才能读取从其他应用复制的数据\u003cbr\u003e旧版本完全支持开箱即用 |\n| Android | 10+ 仅当应用程序位于前台时有效\u003cbr\u003e旧版本完全支持开箱即用               |\n\n## 快速开始\n\n### 安装\n\n将此添加到你的软件包的 pubspec.yaml 文件：\n\n```yaml\ndependencies:\n  clipboard_watcher: ^0.2.1\n```\n\n### 用法\n\n```dart\nclass HomePage extends StatefulWidget {\n  const HomePage({Key? key}) : super(key: key);\n\n  @override\n  _HomePageState createState() =\u003e _HomePageState();\n}\n\nclass _HomePageState extends State\u003cHomePage\u003e with ClipboardListener {\n  @override\n  void initState() {\n    clipboardWatcher.addListener(this);\n    // start watch\n    clipboardWatcher.start();\n    super.initState();\n  }\n\n  @override\n  void dispose() {\n    clipboardWatcher.removeListener(this);\n    // stop watch\n    clipboardWatcher.stop();\n    super.dispose();\n  }\n\n  @override\n  Widget build(BuildContext context) {\n    // ...\n  }\n\n  @override\n  void onClipboardChanged() async {\n    ClipboardData? newClipboardData = await Clipboard.getData(Clipboard.kTextPlain);\n    print(newClipboardData?.text ?? \"\");\n  }\n}\n```\n\n\u003e 请看这个插件的示例应用，以了解完整的例子。\n\n## 谁在用使用它？\n\n- [比译](https://biyidev.com/) - 一个便捷的翻译和词典应用程序。\n\n## 贡献者\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --\u003e\n\u003c!-- prettier-ignore-start --\u003e\n\u003c!-- markdownlint-disable --\u003e\n\u003ctable\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/lijy91\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/3889523?v=4?s=100\" width=\"100px;\" alt=\"LiJianying\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eLiJianying\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/leanflutter/clipboard_watcher/commits?author=lijy91\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/ademar111190\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/1225438?v=4?s=100\" width=\"100px;\" alt=\"Ademar\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eAdemar\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/leanflutter/clipboard_watcher/commits?author=ademar111190\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://customersuccessbox.com/\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/64081899?v=4?s=100\" width=\"100px;\" alt=\"Amritpal Singh\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eAmritpal Singh\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/leanflutter/clipboard_watcher/commits?author=boparaiamritcsb\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/jpnurmi\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/140617?v=4?s=100\" width=\"100px;\" alt=\"J-P Nurmi\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eJ-P Nurmi\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/leanflutter/clipboard_watcher/commits?author=jpnurmi\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n      \u003ctd align=\"center\" valign=\"top\" width=\"14.28%\"\u003e\u003ca href=\"https://github.com/Leobuaa\"\u003e\u003cimg src=\"https://avatars.githubusercontent.com/u/6970283?v=4?s=100\" width=\"100px;\" alt=\"Leo Peng\"/\u003e\u003cbr /\u003e\u003csub\u003e\u003cb\u003eLeo Peng\u003c/b\u003e\u003c/sub\u003e\u003c/a\u003e\u003cbr /\u003e\u003ca href=\"https://github.com/leanflutter/clipboard_watcher/commits?author=Leobuaa\" title=\"Code\"\u003e💻\u003c/a\u003e\u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tbody\u003e\n  \u003ctfoot\u003e\n    \u003ctr\u003e\n      \u003ctd align=\"center\" size=\"13px\" colspan=\"7\"\u003e\n        \u003cimg src=\"https://raw.githubusercontent.com/all-contributors/all-contributors-cli/1b8533af435da9854653492b1327a23a4dbd0a10/assets/logo-small.svg\"\u003e\n          \u003ca href=\"https://all-contributors.js.org/docs/en/bot/usage\"\u003eAdd your contributions\u003c/a\u003e\n        \u003c/img\u003e\n      \u003c/td\u003e\n    \u003c/tr\u003e\n  \u003c/tfoot\u003e\n\u003c/table\u003e\n\n\u003c!-- markdownlint-restore --\u003e\n\u003c!-- prettier-ignore-end --\u003e\n\n\u003c!-- ALL-CONTRIBUTORS-LIST:END --\u003e\n\n## 许可证\n\n[MIT](./LICENSE)\n","funding_links":["https://github.com/sponsors/lijy91"],"categories":["Packages"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleanflutter%2Fclipboard_watcher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleanflutter%2Fclipboard_watcher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleanflutter%2Fclipboard_watcher/lists"}