Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/buh/CompactSlider
CompactSlider is a SwiftUI control for macOS, iOS and watchOS.
https://github.com/buh/CompactSlider
control ios ipados macos slider swift swiftui ui-components watchos
Last synced: 5 days ago
JSON representation
CompactSlider is a SwiftUI control for macOS, iOS and watchOS.
- Host: GitHub
- URL: https://github.com/buh/CompactSlider
- Owner: buh
- License: mit
- Created: 2022-04-25T15:55:43.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-13T13:11:23.000Z (about 2 months ago)
- Last Synced: 2024-10-14T11:17:48.427Z (27 days ago)
- Topics: control, ios, ipados, macos, slider, swift, swiftui, ui-components, watchos
- Language: Swift
- Homepage:
- Size: 851 KB
- Stars: 420
- Watchers: 7
- Forks: 27
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
`CompactSlider` is a control for selecting a value from a bounded linear range of values.
The slider is a replacement for the build-in slider and is designed specifically for SwiftUI. For me, the main motivation for writing a component that already exists is the very slow performance under macOS (e.g. when you need to resize the screen with multiple sliders or when animating) and the severely outdated design. At the same time, I was inspired by the slider design that Apple's [Photos](https://www.apple.com/macos/photos/#edit-gallery) app developed, which makes heavy use of sliders.
- [Requirements](#requirements)
- [Installation](#installation)
- [Preview](#preview)
- [Usage.md](Usage.md#usage)
- [Single Value](Usage.md#single-value)
- [Range Values](Usage.md#range-values)
- [Styling](Usage.md#styling)
- [Configuration](Usage.md#configuration)
- [Secondary Appearance](Usage.md#secondary-appearance)
- [Prominent Style](Usage.md#prominent-style)
- [Advanced Layout](Usage.md#advanced-layout) and `CompactSliderState`
- [Documentation](https://prowork.today/CompactSlider/documentation/compactslider)
- [Support](#support)
- [License](#license)# Requirements
- Swift 5.5+
- Xcode 13+
- SwiftUI 2+
- macOS 11+
- iOS 14+
- watchOS 7+*Some of the requirements could be reduced if there is a demand for them.*
# Installation
1. In Xcode go to `File` ⟩ `Add Packages...`
2. Search for the link below and click `Add Package`
```
https://github.com/buh/CompactSlider.git
```
3. Select to which target you want to add it and select `Add Package`# Preview
**macOS**
https://user-images.githubusercontent.com/284922/166230021-223e1ffb-75e2-41ab-9995-618ccb414f8a.mov
**iPadOS**
https://user-images.githubusercontent.com/284922/166307680-8dfc706f-9e25-4739-94da-1d655b640e56.mov
**iOS**
https://user-images.githubusercontent.com/284922/166308017-fab77043-80c7-4567-b096-7fae8ba05967.mov
**watchOS**
https://user-images.githubusercontent.com/284922/166314399-857a0612-1a47-4bf8-9454-48eb3b63d1ba.mov
# [Usage](Usage.md)
- [Single Value](Usage.md#single-value)
- [Range Values](Usage.md#range-values)
- [Styling](Usage.md#styling)
- [Configuration](Usage.md#configuration)
- [Secondary Appearance](Usage.md#secondary-appearance)
- [Prominent Style](Usage.md#prominent-style)
- [Advanced Layout](Usage.md#advanced-layout) and `CompactSliderState`# Documentation
You can find the generated DocC documentation [here](https://prowork.today/CompactSlider/documentation/compactslider).
https://www.buymeacoffee.com/bukhtin
# Support
You can buy me a coffee [here](https://www.buymeacoffee.com/bukhtin) ☕️
# License
`CompactSlider` is available under the [MIT license](https://github.com/buh/CompactSlider/blob/main/LICENSE)