{"id":13645629,"url":"https://github.com/liuguangli/VerificationCodeInput","last_synced_at":"2025-04-21T14:31:59.582Z","repository":{"id":41002406,"uuid":"83624125","full_name":"liuguangli/VerificationCodeInput","owner":"liuguangli","description":"简洁验证码输入框，能自定义输入框个数和样式","archived":false,"fork":false,"pushed_at":"2019-04-23T08:49:55.000Z","size":810,"stargazers_count":493,"open_issues_count":16,"forks_count":120,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-11-09T18:43:17.448Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/liuguangli.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-03-02T02:19:40.000Z","updated_at":"2024-08-24T14:37:17.000Z","dependencies_parsed_at":"2022-09-20T19:26:47.446Z","dependency_job_id":null,"html_url":"https://github.com/liuguangli/VerificationCodeInput","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liuguangli%2FVerificationCodeInput","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liuguangli%2FVerificationCodeInput/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liuguangli%2FVerificationCodeInput/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/liuguangli%2FVerificationCodeInput/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/liuguangli","download_url":"https://codeload.github.com/liuguangli/VerificationCodeInput/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250070238,"owners_count":21369841,"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":[],"created_at":"2024-08-02T01:02:38.692Z","updated_at":"2025-04-21T14:31:59.200Z","avatar_url":"https://github.com/liuguangli.png","language":"Java","readme":"# VerificationCodeInput\n[![](https://jitpack.io/v/liuguangli/VerificationCodeInput.svg)](https://jitpack.io/#liuguangli/VerificationCodeInput)\n\n简洁验证码输入框，能自定义输入框个数和样式。\n\n![](https://github.com/liuguangli/VerificationCodeInput/blob/master/verification1.gif)\n\n# How to use\n    \u003ccom.dalimao.corelibrary.VerificationCodeInput\n            android:layout_width=\"wrap_content\"\n            android:layout_height=\"wrap_content\"\n            ver:box=\"4\"\n            ver:child_h_padding=\"5dp\"\n            android:layout_centerInParent=\"true\"\n            android:id=\"@+id/verificationCodeInput\"\n            android:layout_marginBottom=\"16dp\"\n            /\u003e\n\n监听输入完成：\n\n    VerificationCodeInput input = (VerificationCodeInput) findViewById(R.id.verificationCodeInput);\n    input.setOnCompleteListener(new VerificationCodeInput.Listener() {\n          @Override\n          public void onComplete(String content) {\n             Log.d(TAG, \"完成输入：\" + content);\n          }\n    });\n\n你还可以为输入框定义自己的样式，指定属性 box_bg_normal 和 box_bg_focus：\n\n    \u003ccom.dalimao.corelibrary.VerificationCodeInput\n            android:layout_width=\"wrap_content\"\n            android:layout_height=\"wrap_content\"\n            ver:box=\"4\"\n            ver:box_bg_normal=\"@drawable/verification_edit_bg_normal\"\n            ver:box_bg_focus=\"@drawable/verification_edit_bg_focus\"\n            ver:child_h_padding=\"5dp\"\n            android:layout_centerInParent=\"true\"\n            android:layout_marginBottom=\"16dp\"\n            /\u003e\n\n自定义个数，指定属性  box：\n\n    \u003ccom.dalimao.corelibrary.VerificationCodeInput\n            android:layout_width=\"wrap_content\"\n            android:layout_height=\"wrap_content\"\n            ver:box=\"5\"\n            ver:box_bg_normal=\"@drawable/verification_edit_bg_normal\"\n            ver:box_bg_focus=\"@drawable/verification_edit_bg_focus\"\n            ver:child_h_padding=\"5dp\"\n            android:layout_centerInParent=\"true\"\n            android:layout_marginBottom=\"16dp\"\n            /\u003e\n\n自定义输入类型：指定属性 inputType：\n\n     \u003ccom.dalimao.corelibrary.VerificationCodeInput\n         android:layout_width=\"wrap_content\"\n         android:layout_height=\"wrap_content\"\n         ver:box=\"5\"\n         ver:box_bg_normal=\"@drawable/verification_edit_bg_normal\"\n         ver:box_bg_focus=\"@drawable/verification_edit_bg_focus\"\n         ver:child_h_padding=\"5dp\"\n         ver:inputType=\"password\"\n         android:layout_centerInParent=\"true\"\n         android:layout_marginBottom=\"16dp\"\n         /\u003e\n\n![](https://github.com/liuguangli/VerificationCodeInput/blob/master/verification.gif)\n# Gradle dependencies\n\nAdd it in your root build.gradle at the end of repositories:\n\n\tallprojects {\n\t\trepositories {\n\t\t\t...\n\t\t\tmaven { url 'https://jitpack.io' }\n\t\t}\n\t}\nStep 2. Add the dependency\n\n\tdependencies {\n\t        compile 'com.github.liuguangli:VerificationCodeInput:1.6'\n\n\t}\n\n# MIT\n\nMIT License\n\nCopyright (c) 2017 刘光利\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","funding_links":[],"categories":["其他"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliuguangli%2FVerificationCodeInput","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliuguangli%2FVerificationCodeInput","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliuguangli%2FVerificationCodeInput/lists"}