{"id":15519597,"url":"https://github.com/alnitak/yoda","last_synced_at":"2025-04-23T04:13:14.496Z","repository":{"id":62458609,"uuid":"355682154","full_name":"alnitak/yoda","owner":"alnitak","description":"Flutter widget that let you slice any kind of child widget in a matrix of tiles and animate them in different kind of ways. Currently with Explode, Vortex, and Flakes. Works on all platforms.","archived":false,"fork":false,"pushed_at":"2024-09-05T10:21:44.000Z","size":11264,"stargazers_count":9,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-23T04:13:08.913Z","etag":null,"topics":["android","dart","desktop","flutter","flutter-widget","ios","web","widget"],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alnitak.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,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-04-07T21:06:06.000Z","updated_at":"2025-01-11T20:37:09.000Z","dependencies_parsed_at":"2025-04-17T08:04:22.067Z","dependency_job_id":"f0ab8657-350e-42fd-bf51-866b995e7f25","html_url":"https://github.com/alnitak/yoda","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alnitak%2Fyoda","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alnitak%2Fyoda/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alnitak%2Fyoda/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alnitak%2Fyoda/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alnitak","download_url":"https://codeload.github.com/alnitak/yoda/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250366716,"owners_count":21418772,"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":["android","dart","desktop","flutter","flutter-widget","ios","web","widget"],"created_at":"2024-10-02T10:22:06.228Z","updated_at":"2025-04-23T04:13:14.476Z","avatar_url":"https://github.com/alnitak.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Yoda Flutter plugin\n\nFlutter widget that let's you slice any kind of child widget in a matrix of tiles and animate them with different kind of ways. Currently with Explode, Vortex and Flakes.\nWorks on all platforms.\n\n![Screenshot](https://github.com/alnitak/yoda/blob/master/img/yoda.gif?raw=true \"yoda Demo\")\n\n## Yoda Widget Properties\n\n##### Yoda widget\n* [**yodaEffect**] Animation effect to use (see below).\n* [**controller**] Animation controller.\n* [**duration**] Animation duration.\n* [**startWhenTapped**] Enable tap gesture to start animation.\n* [**animParameters**] Parameters used to animate tiles (see below).\n* [**child**] Whatever widget to slice.\n\n##### YodaEffect enum\n* [**Explosion**]\n* [**Vortex**]\n* [**Flakes**]\n\n##### AnimParameters properties\n* [**yodaBarrier**] Define which edges are barraged (see below).\n* [**hTiles**] Number of horizontal tiles to divide the child widget.\n* [**vTiles**] Number of vertical tiles to divide the child widget.\n* [**fractionalCenter**] Default center where force is given when not tapping on it.\n* [**gravity**] Vertical force.\n* [**effectPower**] Effect strength.\n* [**blurPower**] Blur strength.\n* [**randomness**] Random strength.\n\n##### YodaBarrier properties\n* [**left**] Block tiles moving over the left edge.\n* [**right**] Block tiles moving over the right edge.\n* [**top**] Block tiles moving over the top edge.\n* [**bottom**] Block tiles moving over the bottom edge.\n\n\n## How to use\n\nIf you need to control the animation status:\n```dart\nlate YodaController _yodaControllerExplode;\n  \n@override\n  void initState() {\n    super.initState();\n    _yodaControllerExplode = YodaController()\n    ..addStatusListener((status) {\n      if (status == AnimationStatus.completed) {\n        _yodaControllerExplode.reset();\n      }\n    });\n  }\n```\nYodaController accepts start() and reset() methods. \nNote: calling those methods will not work when a setState() is called at the same time.\n\n\n```dart\nYoda(\n  yodaEffect: YodaEffect.Explosion,\n  controller: _yodaControllerExplode,\n  duration: Duration(milliseconds: 2500),\n  animParameters: AnimParameters(\n    yodaBarrier: YodaBarrier(bottom: true, left: true, right: true),\n    fractionalCenter: Offset(0.5, 1.0),\n    hTiles: 20,\n    vTiles: 20,\n    effectPower: 0.2,\n    blurPower: 5,\n    gravity: 0.1,\n    randomness: 30,\n  ),\n  startWhenTapped: true,\n  child: SizedBox(\n    width: 250,\n    height: 180,\n    child: Image.asset('assets/dash.png', fit: BoxFit.fill)\n  )\n)\n```\n\n----\n##### TODO\n- Find a better way to capture the widget\n- When changing Yoda widget parameters, 2 hot reloads are needed to make it to work!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falnitak%2Fyoda","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falnitak%2Fyoda","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falnitak%2Fyoda/lists"}