Releases: Flowductive/shiny-swift-ui
1.2.0
Thanks for using ShinySwiftUI! 🎉
New Features
EnumPicker
Quickly create a Picker iterating through enum values:
// Customize view for each item
EnumPicker(selected: $selectedFruit, title: "Choose a Fruit") { fruit in
Text("\(fruit.emoji) \(fruit.name)")
}
// Display enum's rawValue as Text for each item
EnumPicker(selected: $selectedVeggie)Animations
Added new .slickEaseInOut(duration:) animation.
Specify your slick animation style within the .slickAnimation(...) view modifier:
myView.slickAnimation(.inOut)
myView.slickAnimation(.out, delay: 1.0, duration: 0.25)Minor Changes
- Added a new
Lineshape. - Renamed
.reverseMask(...)to.inverseMask(...)for clarification. - Create an at-maximum square frame using the new
.frame(max:)modifier. - Improved the performance of the
.shortcut(...)view. - Added the
.paddedDrawingGroup(_:)modifier to create a drawing group without clipping content. - The
.every(_:perform:)method will now disconnect the timer on view disappear.
1.1.1
1.1.0
Thanks for using ShinySwiftUI! 🎉
New Features
Easily make dynamic content based on clicking/hovering with HoverView:
HoverView { hover in
Rectangle().foregroundColor(hover ? .red : .blue)
}
HoverView { hover, clicked in ... }Minor Additions
- Added the
eight,.slight, and.verySlightopacity levels. - Added a
UnitPointmethod for tracking mouse movement.trackingMouseUnit(...) .slickAnimation(...)can be disabled by setting"reduced_animations"user default tofalse- Added a
.reverseMask(...)view modifier - Added a
.floattransition - Added a
duration:field to.slickAnimation(...)
Fixes
- Fixed issues with ShinySwiftUI operator precedence
1.0.1
Thanks for using ShinySwiftUI! 🎉
New Features
- Create a repeating action using the
.every(_:perform:)modifier:
MyView().every(3.0) { print("Hello!") }- Create a delayed action using the
.after(_:perform:)modifier:
MyView().after(3.0) { print("Hello!") }- ShinySwiftUI is now watchOS compatible!
Minor Additions
- Added an optional
isTrailingparameter to.pageTransition()for forward and back page transitions
1.0.0
0.4.3
0.4.2
Thanks for using ShinySwiftUI! 🎉
Minor Additions
- Added
swipeTransition(on:)view modifier that adds a custom swipe transition based on the toggle of thevalueparameter. - Added a
cornerRadiusparameter to thehiglight(_:cornerRadius:monitoring:)view modifier
0.4.1
Thanks for using ShinySwiftUI! 🎉
New Features
ShoveView
Use ShoveView to quickly push your content to corners/edges of the parent view, like topLeading or bottomTrailing:
ShoveView(.topLeading) {
Text("Top-left corner")
}
ShoveView(.bottomTrailing) { /* ... */ }Minor Changes
- Added the
.innerRoundedBorder(_:cornerRadius:lineWidth:)view modifier - Added the
.debug()view modifier - Improved
HighlightView
Bug Fixes
- Fixed an issue with the Swipe transition
0.4.0
Thanks for using ShinySwiftUI! 🎉
New Features
Generic Stack
Quickly change from an HStack to a VStack, and vice-versa:
// Leading-aligned VStack or Top-aligned HStack
GStack(platform == .iOS ? .horizontal : .vertical, alignment: .beginning, spacing: .s) {
Text("Item 1")
Text("Item 2")
Text("Item 3")
}
// Trailing-aligned VStack or bottom-aligned HStack
GStack(platform == .iOS ? .horizontal : .vertical, alignment: .end) { /* ... */ }Text Transitions
You can now easily use transitions on Text values with the transition(_:value:) view modifier:
@State var value = "Hello World!"
Text(value)
.transition(.turn, value: value)Highlight
Highlight views by changing a global Int value:
// Highlights the view if global.viewToHighlight equals 23
MyView().highlight(23, monitoring: $global.viewToHighlight)Conditional Colors
Show colors conditionally with ease:
MyView().foregroundColor(.red.if(myVal == 5))Minor Changes
- Added
Animation.rampEaseInandAnimation.rampEaseOut - Added static
UIDevice.bottomBarHeightproperty - Added a
scaleparameter toAnyTransition.pop(scale:) - Made the
Wedgecustom shape animatable slickAnimation(value:delay:)now has adelayparameter
Bug Fixes
- Fixed
AnyTransition.pop
0.3.0
Thanks for using ShinySwiftUI! 🎉
Major Changes
Mouse Tracking
Use a simple view modifier to track the position of the user's mouse in macOS.
SomeView()
.trackingMouse { position in
self.mousePosition = position
}More Transitions
Spice up your view appearance with custom transitions.
.turn: Flips the disappearing view upwards and rotates in the appearing view..swipe: Creates a left/right swiping motion with a light fade..pop: Creates a "pop" effect, scaling and fading the view accordingly.
Tooltip View
Add a tooltip to your view that appears automatically on hover.
SomeView()
.withTooltip {
Text("This is a tooltip")
}Minor Changes
.shortcut(:)now works with the esc key- The shortcut tooltip can now be disabled using
UserDefaultskey stored atShinySwiftUI.shortcutTooltipDefaultKey