The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
Remove error checking and just use default values if out of range for `minimumDecimalPlaces` or `maximumDecimalPlaces`.
This version updates the formatting of the text value shown to the user. You can now decide whether you always want to show decimal places and how many up to 8 to display.
# New Parameters
- `minimumDecimalPlaces` - How many decimals to show at the minimum. By default this is set to `0` which will only show a decimal if the value is not a whole number.
- `maximumDecimalPlaces` - How many decimals to show at the maximum. By default this is set to `8` which will show up to 8 decimal places depending on what the user inputs.
# Bug Fixes
The underlying text value is now rounded to 9 places instead of 8 and formatted using [`NumberFormatter()`](https://developer.apple.com/documentation/foundation/numberformatter) to show up to 8 or `maximumDecimalPlaces`. Before this was rounded to just 8 meaning that a user would see a rounded value instead of truncated when entering 8 or more decimal points.
Added [`monospacedDigit()`](https://developer.apple.com/documentation/swiftui/font/monospaceddigit()) to make numbers look less weird when changing
Version **3.1.0** adds a modifier to handle hiding the keyboard on tap or swipe down.
- `.closeKeyboard(on: )`
- **.All** - Both tap and swipe gestures. This is the default option and you do not need to specify the `on` param if you want this.
- **.Tap** - Only on tap.
- **.Swipe** - Only on tap.
Version 3.0.0 updates `TextFieldStepper` to support iOS 16 but because of this, iOS 14 will no longer be supported making the minimum version iOS 15.
# Features
- If a field throws an error it will be set to the default value but only if the error is thrown without the confirm button.
- Will default to `config.maximum`, `config.minimum`, or the initial value the `TextFieldStepper` was setup with.
- `shouldShowAlert` config parameter will determine if an error alert will be shown or not when the default value is used. This is on by default.
Added two new optional config properties
- `labelColor` - The color for the label under value, default is still `.primary`.
- `valueColor` - The color for the main value, default is still `.primary`.
Added a new parameter called `labelOpacity` for making the label stand out slightly less if desired. The default value is still `1.0` but you can now override that.
# With `labelOpacity: 0.66`
![IMG_3100](https://user-images.githubusercontent.com/8194147/179634101-8f1702bc-6b5f-4c77-93fe-0718b73f1e8a.jpg)
# Without `labelOpacity`
![IMG_D08093391996-1](https://user-images.githubusercontent.com/8194147/179634225-24523058-f237-4e1a-ae7c-889236216812.jpeg)
Fix an issue where if the doubleValue is unchanged via keyboard input, the TextField value would remain unformatted.
Fixes issue #6 where buttons were glitchy when hiding the keyboard.
Set spacing to 0 on VStack for label and value.