{"id":21702427,"url":"https://github.com/hamadakram/sneaker","last_synced_at":"2025-05-15T05:02:27.183Z","repository":{"id":37270302,"uuid":"92502948","full_name":"Hamadakram/Sneaker","owner":"Hamadakram","description":"A lightweight Android library for customizable alerts","archived":false,"fork":false,"pushed_at":"2024-06-21T00:47:56.000Z","size":1281,"stargazers_count":993,"open_issues_count":20,"forks_count":123,"subscribers_count":24,"default_branch":"master","last_synced_at":"2025-04-03T03:51:15.517Z","etag":null,"topics":["alerts","android","snackbar","toast","ui-widget"],"latest_commit_sha":null,"homepage":null,"language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Hamadakram.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2017-05-26T11:09:12.000Z","updated_at":"2024-11-29T18:11:50.000Z","dependencies_parsed_at":"2024-12-03T16:01:18.187Z","dependency_job_id":"65fc861e-4a3c-4062-9596-2c7ebfcd243b","html_url":"https://github.com/Hamadakram/Sneaker","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/Hamadakram%2FSneaker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hamadakram%2FSneaker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hamadakram%2FSneaker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hamadakram%2FSneaker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hamadakram","download_url":"https://codeload.github.com/Hamadakram/Sneaker/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248166859,"owners_count":21058481,"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":["alerts","android","snackbar","toast","ui-widget"],"created_at":"2024-11-25T21:15:33.948Z","updated_at":"2025-04-10T06:17:49.835Z","avatar_url":"https://github.com/Hamadakram.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sneaker v2\nA lightweight Android library for customizable alerts\n\n![](https://github.com/Hamadakram/Sneaker/blob/master/art/Sneaker.png?raw=true)\n## Download\nGrab via Gradle:\n```kotlin\nimplementation 'com.irozon.sneaker:sneaker:2.0.0'\n```\n## Usage\n\nIn Sneaker 2.0.0 it's possilbe to show sneaker on Activity, Fragment or any ViewGroup\n```kotlin\n Sneaker.with(activity) // To show Sneaker on Activity\n Sneaker.with(fragment) // To show Sneaker on Fragment\n Sneaker.with(viewGroup) // To show Sneaker on ViewGroup\n```\n\n#### Custom:\n```kotlin\nSneaker.with(actvitiy) // Activity, Fragment or ViewGroup\n       .setTitle(\"Title\", R.color.white) // Title and title color\n       .setMessage(\"This is the message.\", R.color.white) // Message and message color\n       .setDuration(4000) // Time duration to show\n       .autoHide(true) // Auto hide Sneaker view\n       .setHeight(ViewGroup.LayoutParams.WRAP_CONTENT) // Height of the Sneaker layout\n       .setIcon(R.drawable.ic_no_connection, R.color.white, false) // Icon, icon tint color and circular icon view\n       .setTypeface(Typeface.createFromAsset(this.getAssets(), \"font/\" + fontName)); // Custom font for title and message\n       .setOnSneakerClickListener(this) // Click listener for Sneaker\n       .setOnSneakerDismissListener(this) // Dismiss listener for Sneaker. - Version 1.0.2\n       .setCornerRadius(radius, margin) // Radius and margin for round corner Sneaker. - Version 1.0.2\n       .sneak(R.color.colorAccent) // Sneak with background color\n```\n#### Error:\n```kotlin\n Sneaker.with(actvitiy) // Activity, Fragment or ViewGroup\n        .setTitle(\"Error!!\")\n        .setMessage(\"This is the error message\")\n        .sneakError()\n```\n#### Success:\n```kotlin\n Sneaker.with(actvitiy) // Activity, Fragment or ViewGroup\n        .setTitle(\"Success!!\")\n        .setMessage(\"This is the success message\")\n        .sneakSuccess()\n```\n#### Warning:\n```kotlin\n Sneaker.with(actvitiy) // Activity, Fragment or ViewGroup\n        .setTitle(\"Warning!!\")\n        .setMessage(\"This is the warning message\")\n        .sneakWarning()\n```\n#### Custom View:\n```kotlin\n val sneaker = Sneaker.with(actvitiy) // Activity, Fragment or ViewGroup\n val view = LayoutInflater.from(this).inflate(R.layout.custom_view,  sneaker.getView(), false)\n // Your custom view code\n view.findViewById\u003cTextView\u003e(R.id.tvInstall).setOnClickListener{\n       Toast.makeText(this, \"Clicked\", Toast.LENGTH_SHORT).show()\n }\n sneaker.sneakCustom(view)\n```\n## Apps using Sneaker\nIf you are using Sneaker in your app and would like to be listed here, please let me know by [email](mailto:hamadakram91@gmail.com) or opening a new issue!\n\n## Authors\n\n* **Hammad Akram** - (https://github.com/hamadakram)\n\n## Licence\n```\nCopyright 2018 Irozon, Inc.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n   http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhamadakram%2Fsneaker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhamadakram%2Fsneaker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhamadakram%2Fsneaker/lists"}