{"id":32292690,"url":"https://github.com/wjlee611/gyro_provider","last_synced_at":"2026-02-19T21:52:23.380Z","repository":{"id":222636135,"uuid":"753053558","full_name":"wjlee611/gyro_provider","owner":"wjlee611","description":"A plugin that provides data from gyroscopes and rotation sensors and related handy widgets.","archived":false,"fork":false,"pushed_at":"2024-02-27T05:15:37.000Z","size":3635,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-11-27T17:01:17.757Z","etag":null,"topics":["flutter","gyroscope","plugin","sensor"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/gyro_provider","language":"Dart","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/wjlee611.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"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}},"created_at":"2024-02-05T11:30:12.000Z","updated_at":"2025-06-11T09:54:32.000Z","dependencies_parsed_at":"2024-02-15T11:46:07.876Z","dependency_job_id":"0f5c2d81-937b-46b8-a4d4-9f241be64e7a","html_url":"https://github.com/wjlee611/gyro_provider","commit_stats":null,"previous_names":["wjlee611/gyro_provider"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/wjlee611/gyro_provider","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjlee611%2Fgyro_provider","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjlee611%2Fgyro_provider/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjlee611%2Fgyro_provider/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjlee611%2Fgyro_provider/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wjlee611","download_url":"https://codeload.github.com/wjlee611/gyro_provider/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wjlee611%2Fgyro_provider/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29634417,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-19T18:02:07.722Z","status":"ssl_error","status_checked_at":"2026-02-19T18:01:46.144Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["flutter","gyroscope","plugin","sensor"],"created_at":"2025-10-23T03:23:58.843Z","updated_at":"2026-02-19T21:52:23.373Z","avatar_url":"https://github.com/wjlee611.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gyro_provider\n\nA plugin that provides data from gyroscopes and rotation sensors and related handy widgets.\n\n## Getting Started\n\n1. Check out the supported platforms.\n\n   | AOS | iOS | rest |\n   | --- | --- | ---- |\n   | ✅  | ✅  | ❌   |\n\n   \u003e [**NOTE**]\n   \u003e\n   \u003e Vector data on unsupported devices or platforms will all have a value of (0, 0, 0).\n\n2. [Installing](https://pub.dev/packages/gyro_provider/install) plugin.\n\n3. Build your awesome widgets!\n\n   ![gyro_provider_demo](https://raw.githubusercontent.com/wjlee611/gyro_provider/main/example/images/gyro_provider_demo.gif)\n\n## Example\n\n```dart\nimport 'package:flutter/material.dart';\nimport 'package:gyro_provider/gyro_provider.dart';\nimport 'package:gyro_provider_example/widgets/card_widget.dart';\n\nvoid main() {\n  runApp(const MyApp());\n}\n\nclass MyApp extends StatefulWidget {\n  const MyApp({super.key});\n\n  @override\n  State\u003cMyApp\u003e createState() =\u003e _MyAppState();\n}\n\nclass _MyAppState extends State\u003cMyApp\u003e {\n  @override\n  Widget build(BuildContext context) {\n    return MaterialApp(\n      home: Scaffold(\n        appBar: AppBar(\n          title: const Text('Plugin example app'),\n        ),\n        body: const GyroProviderTest(),\n      ),\n    );\n  }\n}\n\nclass GyroProviderTest extends StatelessWidget {\n  const GyroProviderTest({super.key});\n\n  void _onTap(BuildContext context) {\n    showDialog(\n      context: context,\n      builder: (context) =\u003e const Dialog(\n        backgroundColor: Colors.transparent,\n        surfaceTintColor: Colors.transparent,\n        child: GyroProvider.skew(\n          verticalLock: true,\n          resetLock: true,\n          shift: 20,\n          sensitivity: 0.0002,\n          reverse: true,\n          child: CardWidget(),\n        ),\n      ),\n    );\n  }\n\n  @override\n  Widget build(BuildContext context) {\n    return Center(\n      child: Column(\n        mainAxisSize: MainAxisSize.min,\n        children: [\n          GyroProvider(\n            // gyroscope: (vector) {\n            //   print(vector);\n            // },\n            // rotation: (vector) {\n            //   print(vector);\n            // },\n            builder: (context, gyroscope, rotation) =\u003e Column(\n              children: [\n                const Text('gyroscope'),\n                Text(gyroscope.x.toString()),\n                Text(gyroscope.y.toString()),\n                Text(gyroscope.z.toString()),\n                const SizedBox(height: 20),\n                const Text('rotation'),\n                Text(rotation.x.toString()),\n                Text(rotation.y.toString()),\n                Text(rotation.z.toString()),\n              ],\n            ),\n          ),\n          const SizedBox(height: 50),\n          GyroProvider.skew(\n            child: Container(\n              decoration: BoxDecoration(\n                color: Theme.of(context).primaryColor,\n                shape: BoxShape.circle,\n              ),\n              width: 100,\n              height: 100,\n            ),\n          ),\n          const SizedBox(height: 50),\n          TextButton(\n            onPressed: () =\u003e _onTap(context),\n            child: const Text('Open Card Dialog'),\n          ),\n        ],\n      ),\n    );\n  }\n}\n```\n\n## Parameters\n\nSee the comments for how to use the parameters.\n\n- GyroProvider\n\n  | parameter | type                                                           |\n  | --------- | -------------------------------------------------------------- |\n  | gyroscope | void Function(`VectorModel`)?                                  |\n  | rotation  | void Function(`VectorModel`)?                                  |\n  | builder   | Widget Function(`BuildContext`, `VectorModel`, `VectorModel`)? |\n\n  - `VectorModel`\n\n    Same as Vector3.\n\n    A data type with x, y, and z values (double type).\n\n\u003cbr /\u003e\n\n- GyroProvider.skew\n\n  | parameter         | type        |\n  | ----------------- | ----------- |\n  | horizontalLock    | `bool`?     |\n  | verticalLock      | `bool`?     |\n  | resetLock         | `bool`?     |\n  | resetTime         | `Duration`? |\n  | sensitivity       | `double`?   |\n  | shift             | `double`?   |\n  | animationDuration | `Duration`? |\n  | reverse           | `bool`?     |\n  | child             | `Widget`    |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwjlee611%2Fgyro_provider","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwjlee611%2Fgyro_provider","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwjlee611%2Fgyro_provider/lists"}