Create an interactive star rating SwiftUI component. This article will use the star
cutout shape with rounded corners as well as elements of the custom slider to create
a star rating component in SwiftUI.
There is limited ability to customise the Slider in SwiftUI as of Xcode 13. These are
three options of presenting a custom view of the Slider in a SwiftUI App. Set the
tint color and background color of the slider; fall back to using the UISliderView
from UIKit or create a custom SliderView from scratch in SwiftUI.
A lot of time was spent in 2020 looking at daily covid numbers, which was getting
overwhelming. Having taken a break for a while, this article combines covid data and
vaccination data with population data to present a view of the countries with the
highest deaths from Covid-19 and the vaccination status in the country.
The Star shape used in the Star cutout has sharp corners. This article shows how to
modify the shape to create stars with rounded corners. The radius of the corner can
be set as a parameter to specify the rounding of the outer and inner corners of the star.
Path can be used in SwiftUI to create practically any shape. I found creating a
cutout shape difficult until I found that FillStyle can be used with the even-odd
rule. This article shows how to create a shape outline where the outside can be
colored and the center kept transparent to allow other content to show …
One way to animation the change in text size is to use scale effect, however the text
will appear blurred when scaled up. A custom AnimatableModifier can be used to
smoothly animate the resizing of text in SwiftUI, which results in displaying clear
text at all sizes through the animation.