Page indicator replaced with custom implementation
Replacing the UIPageControl with a custom implementation affords us significantly more flexibility as evidenced by the new features in this release.
Updates:
- Providing an initial page, dot size, and dot replacement image are all more reliable
- Faster load times with less jank
- Ability to replace any dot with a custom UIImage
let pagedView = SimplePagedView(
imageIndices: [1: #imageLiteral(resourceName: "add")], // will replace the dot at index 1 with a UIImageView
with: green, red, orange
)
let pagedView = SimplePagedView(
// also supports negative indexing similar to Python. This will replace the last dot with a UIImageView
imageIndices: [-1: #imageLiteral(resourceName: "add")],
with: green, red, orange
)
Non-feature updates:
Check out the included example project and playground to try out other features 😄