{"id":1784,"url":"https://github.com/eliakorkmaz/iCard","last_synced_at":"2025-08-06T16:31:32.666Z","repository":{"id":202084643,"uuid":"100708915","full_name":"eliakorkmaz/iCard","owner":"eliakorkmaz","description":"Bank Card Generator with Swift using SnapKit DSL 💳","archived":false,"fork":false,"pushed_at":"2018-10-17T00:16:17.000Z","size":1244,"stargazers_count":341,"open_issues_count":2,"forks_count":39,"subscribers_count":13,"default_branch":"master","last_synced_at":"2024-08-18T18:32:40.972Z","etag":null,"topics":["auto-layout","ios","opensource","snapkit","swift"],"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/eliakorkmaz.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,"governance":null}},"created_at":"2017-08-18T12:16:10.000Z","updated_at":"2024-05-16T22:02:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"b5368fc4-70c4-4851-b144-8d370a0c0e42","html_url":"https://github.com/eliakorkmaz/iCard","commit_stats":null,"previous_names":["eliakorkmaz/icard"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliakorkmaz%2FiCard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliakorkmaz%2FiCard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliakorkmaz%2FiCard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eliakorkmaz%2FiCard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eliakorkmaz","download_url":"https://codeload.github.com/eliakorkmaz/iCard/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228923696,"owners_count":17992567,"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":["auto-layout","ios","opensource","snapkit","swift"],"created_at":"2024-01-05T20:15:55.736Z","updated_at":"2024-12-09T16:31:04.952Z","avatar_url":"https://github.com/eliakorkmaz.png","language":"Swift","funding_links":[],"categories":["Payments","Libs","UI [🔝](#readme)"],"sub_categories":["Other Parsing","UI","Other free courses"],"readme":"# iCard\n##### BankCard \u0026 CreditCard generator with Swift 3 using SnapKit DSL\n\n`iCard` is a simple tool for generate Credit \u0026 Bank Card , it represent cards as `UIView` and it's a `subclass` of `UIView`\n\n# Screenshots\n\n`.chip1 - .blueway - .withBothBankIcon - .cirrusIcon ` **\u0026**  `.chip3 - .blueway - .withBothBankIcon - .masterCardIcon `\n\n![alt-text-1](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/bothIconBlue.png?raw=true \"\") ![alt-text-2](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/bothIconBlue2.png?raw=true \"\")\n\n`.chip2 - .yelloway - .googleWalletIcon - .cirrusIcon ` **\u0026**  `.chip2 - .yelloway - .withDefaultTitles `\n\n![alt-text-1](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/bothIconYellow.png?raw=true \"\") ![alt-text-2](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/defaultCard.png?raw=true \"\")\n\n`.chip1 - .cirrusIcon - .withBothBankIcon ` **\u0026**  `.chip2 - .withBothBankIcon`\n\n![alt-text-1](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/photoBothIcon.png?raw=true \"\") ![alt-text-2](https://github.com/eliakorkmaz/iCard/blob/master/screenShots/photoBothImage.png?raw=true \"\")\n\n# Init\n\n```swift\ninit(cardStyleWithBackgroundColor: cardStyle , withCardColors colors: cardColors , pinIcon: chipIcons , creditIcons: creditIcons)\n```\nFor creating `iCard` with single `backgroundColor` , you should use this initalizer and you must choose `cardStyle`, `cardColors`, `pinIcons` and `creditIcons`\n```swift\nlet simpleCard: iCreditCard = iCreditCard(cardStyleWithBackgroundColor: .withBothBankIcon, withCardColors: .blueway, pinIcon: .chip1, creditIcons: .cirrusIcon)\n```\n\nAnd if you create an `iCreditCard` with has a unique background image , you can easily use this `init` function. You must send `UIImage` to `init` otherwise if `withCardImage` is `nil` , it will have simple `backgroundColor`.\n\n```swift\ninit(cardStyleWithBackgroundImage: cardStyle , withCardImage: UIImage?, pinIcon: chipIcons , creditIcons: creditIcons)\n```\nHere is a simple creation of `iCard` with `backgroundImage`\n```swift\nlet simpleCard: iCreditCard = iCreditCard(cardStyleWithBackgroundImage: .withBothBankIcon, withCardImage: UIImage(named:\"simpleBackgroundImage\"), pinIcon: .chip2, creditIcons: .maestroIcon)\n```\n\n\n# Convenience Init\n\nYou can also create `iCard` with `no-parameter` or `single-parameter`\n\n```swift\nconvenience init(){\nself.init(cardStyleWithBackgroundColor: .withBothBankIcon, withCardColors: .yelloway, pinIcon: .chip1, creditIcons: .cirrusIcon) }\n```\nHere is a simple example of it . If you use this initializer you will created a `iCard` with `.withBothBankIcon` style , `.yelloway` color , `.chip1` chip  and `.cirrusIcon` icon\n\n**Here is a simple usage**\n```swift\nlet simpleCard: iCreditCard = iCreditCard()\n```\nAnother `convenience init` is below.\n```swift\nconvenience init(cardColors: cardColors){\nself.init(cardStyleWithBackgroundColor: .withBothBankIcon, withCardColors: .yelloway, pinIcon: .chip2, creditIcons: .americanExpressIcon)\n}\n```\n\n**Here is a simple usage of it**\n```swift\nlet simpleCard2: iCreditCard = iCreditCard(cardColors: .blueway)\n```\n\n\n\n# Structs\n```swift\npublic enum cardColors{\ncase blueway\ncase yelloway\n}\n```\n`cardColors` using when choose card `backgroundColor` , now support only 2 color as *blue* and *yellow*\n\n```swift\npublic enum cardVisual{\ncase withBackgroundColor\ncase withBackgroundImage\n}\n```\n`cardVisual` is used to choose card type. \n\n```swift\npublic enum cardStyle{\ncase withDefaultTitles\ncase withTopBankIcon\ncase withBottomBankIcon\ncase withBothBankIcon\n}\n```\n`cardStyle` is used to set card style to different type. \n\n```swift\npublic enum chipIcons{\ncase chip1\ncase chip2\ncase chip3\n}\n```\n`chipIcons` is used to choose card chip icons, there are only 3 different chip icons\n\n```swift\npublic enum creditIcons{\ncase americanExpressIcon\ncase bitcoinIcon\ncase bluePayIcon\ncase cirrusIcon\ncase citiIcon\ncase clickBank\ncase cvsIcon\ncase googleWalletIcon\ncase hsbcIcon\ncase maestroIcon\ncase maestroIcon2\ncase masterCard\ncase masterCardMini\ncase masterCardDetail\ncase moneyGramIcon\ncase paypalIcon\ncase paypalIconSimple\ncase visaIcon\ncase visaIconBigger\ncase visaIconText\ncase wePayIcon\ncase westernUnionIcon\n}\n```\n\n| Parameter | Icons |\n| ------ | ---------|\n| .americanExpressIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/americanExpressIcon.imageset/americanExpressIcon.png?raw=true \"\") |\n| .bitcoinIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/bitcoinIcon.imageset/bitcoinIcon.png?raw=true \"\") |\n| .bluePayIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/bluePayIcon.imageset/bluePayIcon.png?raw=true \"\") |\n| .cirrusIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/cirrusIcon.imageset/cirrusIcon.png?raw=true \"\") |\n| .citiIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/citiIcon.imageset/citiIcon.png?raw=true \"\") |\n| .clickBank | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/clickBank.imageset/clickBank.png?raw=true \"\") |\n| .cvsIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/cVSIcon.imageset/cVSIcon.png?raw=true \"\") |\n| .googleWalletIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/googleWalletIcon.imageset/googleWalletIcon.png?raw=true \"\") |\n| .hsbcIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/hsbcIcon.imageset/hsbcIcon.png?raw=true \"\") |\n| .maestroIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/maestroIcon.imageset/maestroIcon.png?raw=true \"\") |\n| .maestroIcon2 | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/maestro2Icon.imageset/maestro2Icon.png?raw=true \"\") |\n| .masterCard | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/masterCard.imageset/mastercard2Icon-1.png?raw=true \"\") |\n| .masterCardMini | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/masterCardMini.imageset/mastercard3Icon.png?raw=true \"\") |\n| .masterCardDetail | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/masterCardDetail.imageset/masterCardIcon.png?raw=true \"\") |\n| .moneyGramIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/moneygramIcon.imageset/moneygramIcon.png?raw=true \"\") |\n| .paypalIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/paypal2Icon.imageset/paypal2Icon.png?raw=true \"\") |\n| .paypalIconSimple | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/paypalIcon.imageset/paypalIcon.png?raw=true \"\") |\n| .visaIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/visaIcon.imageset/visaIcon.png?raw=true \"\") |\n| .visaIconBigger | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/visaIconBigger.imageset/visaLogo.png?raw=true \"\") |\n| .visaIconText | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/visaIconText.imageset/visa2Icon.png?raw=true \"\") |\n| .wePayIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/wepayIcon.imageset/wepayIcon.png?raw=true \"\") |\n| .westernUnionIcon | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/westernUnionIcon.imageset/westernUnionIcon.png?raw=true \"\") |\n\n\n```swift\npublic enum chipIcons{\ncase chip1\ncase chip2\ncase chip3\n}\n```\n\n| Parameter | Icons |\n| ------ | ---------|\n| .chip1 | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/chip1.imageset/chip1.png?raw=true \"\") |\n| .chip2 | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/chip2.imageset/chip2.png?raw=true \"\") |\n| .chip3 | ![](https://github.com/eliakorkmaz/iCard/blob/master/iCard/Assets.xcassets/chip3.imageset/chip3.png?raw=true \"\") |\n\n### Font and Icons \nI have used `HALTER__.ttf` font for `cardNumber` and also 've used [Icon-Icons Website](http://icon-icons.com/) for all icons.\n\n### Installation\n\n```sh\ngit clone REPO_URL\ncd iCard/\nuse iCreditCard.swift \n```\n\n\n\n### Development\nWant to contribute? \nFeel free to contribute anything on this with describing contributed part\n\n\n### Todos\n- Write Tests\n- Add BackView Generator with init\n\n## License\n*MIT*\n\n❤   **Open Source**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feliakorkmaz%2FiCard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feliakorkmaz%2FiCard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feliakorkmaz%2FiCard/lists"}