Latest 1.0.1
Homepage https://github.com/marinofelipe/UICurrencyTextField
License MIT
Platforms ios 9.0
Authors

UICurrencyTextField 💶✏️

Build Status
Coverage Status
Swift

iOS currency text field written in Swift.

Inputed numbers are automatically formatted to user Locale currency format.

Language: English, Region: Brazil

R$ - brazilian reais  

Language: English, Region: United States

$ - dollars

Requirements

  • Swift >= 3

Installation

CocoaPods

Tested with pod --version: 1.0.0

# Podfile
use_frameworks!

target 'YOUR_TARGET_NAME' do
    pod 'UICurrencyTextField'
end

Replace YOUR_TARGET_NAME and then, in the Podfile directory, type:

$ pod install

Usage

create an instance
let currencyTextField = UICurrencyTextField(frame: frame)
set maximum integers digits – default is 7
currencyTextField.maximumIntegers = 4
enables autoclear – text will remove content when value is 0
currencyTextField.hasAutoclear = true

Please refer to Example/ and download the demo for more detailed info.
The demo shows storyboard and programmatically methods.

Contributing

Please feel free to contribute. Together we can make better reusable code.
Follow Kanban project or open new issues in your fork.
Every PR will be first validated by the CI service which will run the demo tests.
If you develop new features or solve any issues please verify if tests keep succeeding. Feel free to help adding more tets as well.

License

UICurrencyTextField is released under the MIT license. See LICENSE for details.

Latest podspec

{
    "name": "UICurrencyTextField",
    "version": "1.0.1",
    "summary": "Currency text field written in Swift",
    "homepage": "https://github.com/marinofelipe/UICurrencyTextField",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Felipe Lefu00e8vre Marino": "[email protected]"
    },
    "source": {
        "git": "https://github.com/marinofelipe/UICurrencyTextField.git",
        "tag": "1.0.1"
    },
    "platforms": {
        "ios": "9.0"
    },
    "swift_version": "4.1",
    "source_files": "UICurrencyTextField/Sources/**/*.swift"
}

Pin It on Pinterest

Share This