{"id":17219278,"url":"https://github.com/dev-ritik/emojireactionview","last_synced_at":"2025-08-07T00:41:58.917Z","repository":{"id":69334858,"uuid":"141713908","full_name":"dev-ritik/EmojiReactionView","owner":"dev-ritik","description":"Instagram's emoji reaction for android!","archived":false,"fork":false,"pushed_at":"2020-12-19T16:14:25.000Z","size":10907,"stargazers_count":79,"open_issues_count":1,"forks_count":13,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T22:40:55.789Z","etag":null,"topics":["android","android-library","instagram","instagram-reaction","reactions"],"latest_commit_sha":null,"homepage":"","language":"Java","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/dev-ritik.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","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}},"created_at":"2018-07-20T13:14:21.000Z","updated_at":"2024-11-17T13:30:35.000Z","dependencies_parsed_at":"2023-03-01T13:17:03.792Z","dependency_job_id":null,"html_url":"https://github.com/dev-ritik/EmojiReactionView","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/dev-ritik/EmojiReactionView","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-ritik%2FEmojiReactionView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-ritik%2FEmojiReactionView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-ritik%2FEmojiReactionView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-ritik%2FEmojiReactionView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dev-ritik","download_url":"https://codeload.github.com/dev-ritik/EmojiReactionView/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-ritik%2FEmojiReactionView/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260350185,"owners_count":22995706,"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","android-library","instagram","instagram-reaction","reactions"],"created_at":"2024-10-15T03:49:32.510Z","updated_at":"2025-06-17T11:37:24.986Z","avatar_url":"https://github.com/dev-ritik.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# \u003cdiv align=\"center\"\u003e EmojiReactionView \u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e\n\t\u003ca href=\"https://www.android.com\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/platform-Android-brightgreen.svg\"\n      alt=\"Platform\" /\u003e\n  \u003c/a\u003e\n\t\u003ca href=\"https://android-arsenal.com/api?level=19\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/API-19%2B-blue.svg\"\n      alt=\"API\" /\u003e\n  \u003c/a\u003e\n\t\u003ca href=\"https://opensource.org/licenses/MIT\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/License-MIT-red.svg\"\n      alt=\"License: MIT\" /\u003e\n  \u003c/a\u003e\n    \u003ca href=\"https://bintray.com/dev-ritik/EmojiReactionView/EmojiReactionView/_latestVersion\"\u003e\n    \u003cimg src=\"https://api.bintray.com/packages/dev-ritik/EmojiReactionView/EmojiReactionView/images/download.svg\"\n      alt=\"Download\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://sputnik.ci/app#/builds/dev-ritik/EmojiReactionView\"\u003e\n    \u003cimg src=\"https://sputnik.ci/conf/badge\"\n      alt=\"Sputnik\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://travis-ci.com/dev-ritik/EmojiReactionView\"\u003e\n    \u003cimg src=\"https://travis-ci.com/dev-ritik/EmojiReactionView.svg?branch=master\"\n      alt=\"Build Status\" /\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\u003cbr\u003e\n\n\u003cimg src=\"sample/coverImage.png\" align=\"centre\"\u003e\n\n\u003cdiv align=\"center\"\u003eAn Android library to make Emoji Reactions on imageviews in a manner Instagram does this!.\u003c/div\u003e\u003cbr\u003e\n\n___\n# Table of contents\n\n  * [Features](#features)\n  * [Example](#example)\n  * [Usage](#usage)\n  * [Further customization](#further-customization)\n  * [Public methods](#public-methods)\n  * [Contributions](#contributions)\n  * [License](#license)\n\n# Features\n- \u003cb\u003eDesign\u003c/b\u003e : The library tries to be reasonably close to the original Instagram's design.\n- \u003cb\u003eCustomization\u003c/b\u003e : Users can customize the look to a great extent easily and reliably.\n- \u003cb\u003eSupport for RecyclerView\u003c/b\u003e : It can easily be used with Recycler views.\n- \u003cb\u003eOptimum performance\u003c/b\u003e : Efforts have been made to keep memory usage as small as possible.\n- \u003cb\u003eUnharmed image\u003c/b\u003e : The library doesn't change/modify the image, so every modification of image as imageview is possible\n\n# Example\nBelow is the two sample for usage of the library:\n\n\u003cimg src=\"sample/simple.gif\" align=\"right\" width=\"418\" \u003e\n\u003cimg src=\"sample/recycler.gif\" align=\"left\" width=\"418\"\u003e\n\n\u003cbr\u003e\n\n# Usage\nJust add the following dependency in your app's `build.gradle`\n```groovy\nrepositories {\n    maven {\n        url 'https://dl.bintray.com/dev-ritik/EmojiReactionView/'\n    }\n}\n\ndependencies {\n    implementation 'com.ritik:emojireactionlibrary:1.0.2'\n}\n\n```\n\nAdd the following code in your xml file\n```xml\n\u003ccom.ritik.emojireactionlibrary.EmojiReactionView\n        android:layout_width=\"match_parent\"\n        android:layout_height=\"match_parent\"\n        android:src=\"@drawable/image\"\n        app:emojis=\"@array/emoji\" /\u003e\n```\nwhere `emoji` is an array resource which is the address to all emojis to be in the panel like:\n```xml\n\n    \u003carray name=\"emoji\"\u003e\n        \u003citem\u003e@drawable/em1\u003c/item\u003e\n        \u003citem\u003e@drawable/em2\u003c/item\u003e\n        \u003citem\u003e@drawable/em2\u003c/item\u003e\n    \u003c/array\u003e\n```\n\nand for the home emoji, rename that to **home**, so that its resource id becomes `R.drawable.home`\nto override default home emoji originally set.\n\nTo get notified of when the emojis are clicked, you can use:\n```java\nmyImage.setOnEmojiClickListener(new ClickInterface() {\n    @Override\n    public void onEmojiClicked(int emojiIndex, int x, int y) {\n        // emojiIndex is the index of the emoji being clicked (0 based)\n        // x,y are the coordinates of the clicked position relative to the image \n        // (if x \u0026\u0026 y == -1 =\u003e changed by program(SetClickedEmojiNumber)\n    }\n\n    @Override\n    public void onEmojiUnclicked(int emojiIndex, int x, int y) {\n        // emojiIndex is the index of the emoji being clicked (0 based)\n        // x,y are the coordinates of the clicked position relative to the image \n        // (if x \u0026\u0026 y == -1 =\u003e changed by program(SetClickedEmojiNumber)\n    }\n});\n```\n\n**If you are struck somewhere, you can always check its usage in the sample app for [Simple](https://github.com/dev-ritik/EmojiReactionView/blob/master/app/src/main/java/com/ritik/emojireactionview/SimpleExample.java) \nand [RecyclerView](https://github.com/dev-ritik/EmojiReactionView/blob/master/app/src/main/java/com/ritik/emojireactionview/FeedAdapter.java) usage.**\n\n_With this all done and working, you have made to the default design!_\n\n# Further customization\nThe library provides these attributes to modify default design to a custom one:\n\n|Attribute            |Description                                                 | Type(Range)                                       |Default Value                        |\n|---------------------|------------------------------------------------------------|---------------------------------------------------|-------------------------------------|\n|emojis               | Set the emojis to be displayed in the panel animation      | reference                                         |                                     |\n|set_emoji            | Set the current selected emoji                             | integer(\u003e-1)(\u003c noe*) (0 based)                    | -1                                  |\n|home_Center_X        | Set the x coordinate of homeEmoji's center                 | dimensions                                        | 30 * density                        |\n|home_Center_Y        | Set the y coordinate of homeEmoji's center                 | dimensions                                        | Height - 30 * density               |\n|home_side            | Set the side length of homeEmoji                           | dimensions                                        | 50 * density                        |\n|panel_center_X       | Set the x coordinate of the center of panel animation      | `dimension` or `fraction` [0%,100%] (w.r.t width)#| width / 2                           |\n|panel_center_Y       | Set the y coordinate of the center of panel animation      | `dimension` or `fraction` [0%,100%] (w.r.t height)| Height - emojiSide / 2              |\n|panel_radius         | Set the radius of panel animation                          | dimension                                         | min(Height,Width) / 2 - 20 * density|\n|panel_emoji_side     | Set the side of emojis on the panel                        | dimension                                         | 50 * density                        |\n|emojis_rising_height | Set the height of the rising emojis(to start disappearing) | `fraction` [0%,100%] (w.r.t height)#              | Height / 2                          |\n|emojis_rising_speed  | Set the speed per frame of the rising emojis               | dimension                                         | 10 * density                        |\n|emojis_rising_number | Set the number of emojis rising in rising emojis animation | integer                                           | 24                                  |\n\n*noe = number of emojis.\u003cbr\u003e\n*#* measurement from bottom\n# Public methods \n\n|Method                   |Description                                   |Data Type                   |\n|-------------------------|----------------------------------------------|----------------------------|\n|getCentre                | Get the center of panel animation            | int(Pixels)                |\n|getRadius                | Get the radius of panel animation            | int(Pixels)                |\n|get/SetClickedEmojiNumber| Get/Set the current selected emoji           | int (-1 for none)(0 based) |\n|getNumberOfEmojis        | Get the number Of emojis in the panel        | int                        |\n|getEmojisRisingSpeed     | Get the speed per frame of the rising emojis | int(Pixels)                |\n|getHomeRect              | Get the Rect of the home emoji               | Rect                       |\n|getPanelEmojiSide        | Get the side of emojis on the panel          | int(Pixels)                |\n|get/SetHomeBitmap        | Get/Set the bitmap of the home emoji         | Bitmap                     |\n|isHomeEmojiVisible       | Is home emoji visible                        | boolean                    |\n|isPanelAnimWorking       | Is panel visible                             | boolean                    |\n|isClickingAnimWorking    | Is the clicking animation working            | boolean                    |\n|isEmojiRising            | Is emoji rising animation visible            | boolean                    |\n|setHomeEmojiVisible      | Switch to home bitmap visible mode           | boolean                    |\n|setPanelAnimWorking      | Start the panel animation                    | boolean                    |\n\n# Contributions\n\nAll contributions are welcome and appreciated. Please make a Pull Request or open an issue, if necessary.\nThis may also include any form of feature enhancement. Every constructive criticism is welcome.\nSee [Contributing.md](https://github.com/dev-ritik/EmojiReactionView/blob/master/CONTRIBUTING.md)\n\n# License\nThis library is licensed under `MIT license`. View [license](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-ritik%2Femojireactionview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdev-ritik%2Femojireactionview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-ritik%2Femojireactionview/lists"}