{"id":13496818,"url":"https://github.com/atrinh0/buttoncraft","last_synced_at":"2025-05-16T04:03:48.807Z","repository":{"id":41135384,"uuid":"284474951","full_name":"atrinh0/buttoncraft","owner":"atrinh0","description":"Craft that perfect SwiftUI button effect 👌🏼","archived":false,"fork":false,"pushed_at":"2024-11-13T11:00:48.000Z","size":17668,"stargazers_count":440,"open_issues_count":1,"forks_count":17,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-04-08T14:09:49.679Z","etag":null,"topics":["button-animation","buttons","ios","ios14","swiftui"],"latest_commit_sha":null,"homepage":"","language":"Swift","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/atrinh0.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2020-08-02T14:13:06.000Z","updated_at":"2025-04-01T09:24:35.000Z","dependencies_parsed_at":"2024-01-16T12:49:36.697Z","dependency_job_id":"6c9a16fb-e2fb-4220-8e69-837a1a78ab40","html_url":"https://github.com/atrinh0/buttoncraft","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/atrinh0%2Fbuttoncraft","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atrinh0%2Fbuttoncraft/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atrinh0%2Fbuttoncraft/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/atrinh0%2Fbuttoncraft/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/atrinh0","download_url":"https://codeload.github.com/atrinh0/buttoncraft/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254464891,"owners_count":22075570,"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":["button-animation","buttons","ios","ios14","swiftui"],"created_at":"2024-07-31T19:02:00.704Z","updated_at":"2025-05-16T04:03:48.788Z","avatar_url":"https://github.com/atrinh0.png","language":"Swift","readme":"\u003cp align=\"center\"\u003e\u003cimg src=\"images/taphere.gif\" width=\"190\"\u003e\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/iOS-14.0+-blue.svg\" /\u003e\n    \u003cimg src=\"https://img.shields.io/badge/Xcode-13.0+-brightgreen.svg\" /\u003e\n    \u003cimg src=\"https://img.shields.io/badge/Swift-5.5-orange.svg\" /\u003e\n    \u003cimg src=\"https://img.shields.io/badge/SwiftUI-3.0-red.svg\" /\u003e\n\u003c/p\u003e\n\n# buttoncraft (SwiftUI App)\n\u003e Experimenting with `SwiftUI` whilst creating a practical app to craft that perfect button style.\n\n### ✈️ Testflight\n\nhttps://testflight.apple.com/join/pZDhygQt\n\n\u003e Last TestFlight bump: 13th November 2024\n\n\u003cimg src=\"images/demo.gif\"\u003e \u003cimg src=\"images/copycode.gif\"\u003e\n\n### 👨🏻‍💻 Code outputted from app\n\n```Swift\nstruct MyButtonStyle: ButtonStyle {\n    func makeBody(configuration: Self.Configuration) -\u003e some View {\n        configuration.label\n            .background(Capsule()\n                            .foregroundColor(configuration.isPressed ? Color.primary.opacity(0.75) : Color.primary))\n            .scaleEffect(configuration.isPressed ? CGFloat(0.85) : 1.0)\n            .rotationEffect(.degrees(configuration.isPressed ? 0.0 : 0))\n            .blur(radius: configuration.isPressed ? CGFloat(0.0) : 0)\n            .animation(Animation.spring(response: 0.35, dampingFraction: 0.35, blendDuration: 1), value: configuration.isPressed)\n    }\n}\n\nextension Button {\n    func myButtonStyle() -\u003e some View {\n        self.buttonStyle(MyButtonStyle())\n    }\n}\n\n// to use\nButton { } label: {\n    Text(\"just like that\")\n        .font(Font.body.bold())\n        .padding()\n        .foregroundColor(Color.primary)\n        .colorInvert()\n}\n.myButtonStyle()\n\nButton { } label: {\n    Image(systemName: \"face.smiling\")\n        .font(Font.body.bold())\n        .imageScale(.large)\n        .padding()\n        .foregroundColor(Color.primary)\n        .colorInvert()\n}\n.myButtonStyle()\n\n```\n\n### 🧐 Features\n\n- 🔀 Randomise different settings for inspiration\n- Reset to my default style\n- Using the new iOS `ColorPicker`\n- Copy your perfect masterpiece as a code snippet to your clipboard\n\n### 👨🏻‍⚖️ Disclaimer\n\n\u003e This is posted as a way to share SwiftUI learnings (and is not production level code). Use it at your own risk.\n","funding_links":[],"categories":["Swift","Misc","Button","Open source apps"],"sub_categories":["SwiftUI","Content","iOS"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatrinh0%2Fbuttoncraft","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fatrinh0%2Fbuttoncraft","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatrinh0%2Fbuttoncraft/lists"}