{"id":17158684,"url":"https://github.com/siruscodes/morphing_text","last_synced_at":"2025-04-13T13:40:36.771Z","repository":{"id":56834924,"uuid":"303066585","full_name":"SirusCodes/morphing_text","owner":"SirusCodes","description":"A flutter package for Text animations. https://pub.dev/packages/morphing_text","archived":false,"fork":false,"pushed_at":"2021-07-25T14:13:19.000Z","size":944,"stargazers_count":11,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-27T04:41:28.437Z","etag":null,"topics":["animation","dart","flutter","flutter-package","package","pub","text-animation"],"latest_commit_sha":null,"homepage":"","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/SirusCodes.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-10-11T07:31:57.000Z","updated_at":"2025-01-29T00:28:04.000Z","dependencies_parsed_at":"2022-09-02T03:40:48.352Z","dependency_job_id":null,"html_url":"https://github.com/SirusCodes/morphing_text","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SirusCodes%2Fmorphing_text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SirusCodes%2Fmorphing_text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SirusCodes%2Fmorphing_text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SirusCodes%2Fmorphing_text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SirusCodes","download_url":"https://codeload.github.com/SirusCodes/morphing_text/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248724082,"owners_count":21151555,"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":["animation","dart","flutter","flutter-package","package","pub","text-animation"],"created_at":"2024-10-14T22:12:17.491Z","updated_at":"2025-04-13T13:40:36.747Z","avatar_url":"https://github.com/SirusCodes.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv\u003e\n   \u003ca href=\"https://github.com/SirusCodes/morphing_text/blob/master/LICENSE\"\u003e\n   \u003cimg src=\"https://img.shields.io/github/license/SirusCodes/morphing_text\" \u003e\n   \u003c/a\u003e\n\n   \u003ca href=\"https://pub.dev/packages/morphing_text\"\u003e\n   \u003cimg src=\"https://img.shields.io/pub/v/morphing_text\" \u003e\n   \u003c/a\u003e\n\n   \u003ca href=\"https://github.com/SirusCodes/morphing_text/issues\"\u003e\n   \u003cimg src=\"https://img.shields.io/github/issues/SirusCodes/morphing_text\" \u003e\n   \u003c/a\u003e\n\n   \u003ca href=\"https://github.com/SirusCodes/morphing_text\"\u003e\n   \u003cimg src=\"https://img.shields.io/github/stars/SirusCodes/morphing_text\" \u003e\n   \u003c/a\u003e\n\u003c/div\u003e\n\n# Morphing Text\n\nIt is a collection of text animations inspired by [LTMorphingLabel](https://github.com/lexrus/LTMorphingLabel).\n\n## Animations\n\n### ScaleMorphingText\n\n\u003cimg src=\"https://github.com/SirusCodes/morphing_text/blob/master/display/scale.gif?raw=true\" height=200px\u003e\n\n```dart\nScaleMorphingText(\n    texts: text,\n    loopForever: true,\n    onComplete: () {},\n    textStyle: TextStyle(fontSize: 40.0),\n),\n```\n\n### EvaporateMorphingText\n\n\u003cimg src=\"https://github.com/SirusCodes/morphing_text/blob/master/display/evaporate.gif?raw=true\" height=200px\u003e\n\n```dart\nEvaporateMorphingText(\n    texts: text,\n    loopForever: true,\n    onComplete: () {},\n    yDisplacement: 1.2,     // To factor of y-displacement\n    textStyle: TextStyle(fontSize: 40.0),\n),\n```\n\n## All Parameters\n\n| Type | Parameter | Description | Default |\n|--|--|--|--|\n| `List\u003cString\u003e` | texts | List of `String` which will show the text | - |\n| `TextStyle` | textStyle | Styling of texts | DefaultTextStyle |\n| `Duration` | speed | Define the speed of changing of each text | 500 milliseconds |\n| `Duration` | pause | Define the pause between each transition | 1500 milliseconds |\n| `bool` | loopForever | When `true` animations will repeat indefinitely | false |\n| `int` | loopCount | Number of time animation will repeat itself | 1 |\n| `void` | onComplete | When `loopCount` is completed it is called  | - |\n| `Curve` | fadeInCurve | Curve which controls opacity from 0 to 1 | Curves.easeInExpo |\n| `Curve` | fadeOutCurve | Curve which controls opacity from 1 to 0 | Curves.easeOut |\n| `Curve` | progressCurve | Curve which controls movement of text and scale changes | Curves.easeIn |\n\n\u003e Changing Curves is purely experimental, select proper curves as per your need or leave them at default\n\n## Making custom animations\n\n1. To make custom animations extend your class with `MorphingText`\n\n```dart\nclass CustomFooMorphingText extends MorphingText {\n  ...\n}\n```\n2. Override `incomingText` and `outgoingText` methods to animate entry of next and exit of previous text respectively and pass `text`, `textStyle` and `progress` to super.\n\n```dart\nclass CustomFooMorphingText extends MorphingText {\n  CustomFooMorphingText(\n      String text,\n      TextStyle textStyle,\n      double progress,\n  ) : super(text, textStyle, progress);\n\n  @override\n  TextProperties morphingText(TextProperties textProperties) {\n    // Optional to change the motion of moving text\n  }\n\n  @override\n  TextProperties incomingText(TextProperties textProperties) {\n    // Write you logic for next text\n  }\n\n  @override\n  TextProperties outgoingText(TextProperties textProperties) {\n    // Write you logic for leaving text\n  }\n}\n```\n\n3. Pass your custom animation to `CustomMorphingText` in build method.\n\n```dart\nCustomMorphingText(\n  morphingText: CustomFooMorphingText(\n    texts[index],\n    DefaultTextStyle.of(context).style.merge(widget.textStyle),\n    _progress.value,\n  ),\n);\n```\n\n4. For example you can see implementation of `CustomScaleMorphingText` on [github](https://github.com/SirusCodes/morphing_text/blob/master/lib/src/scale.dart#L178)\n\n## Want to Contribute?\nA help is always welcomed, check our [CONTRIBUTING.md](https://github.com/SirusCodes/morphing_text/blob/master/CONTRIBUTING.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiruscodes%2Fmorphing_text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsiruscodes%2Fmorphing_text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiruscodes%2Fmorphing_text/lists"}