https://github.com/swiftuiux/d3-color
Useful extensions and functions used with SwiftUI Color rgb ios macos Get rgb from Color Do brighter Do darker SwiftUI color
https://github.com/swiftuiux/d3-color
brigther color darker ios macos rgb swift swiftui
Last synced: 7 months ago
JSON representation
Useful extensions and functions used with SwiftUI Color rgb ios macos Get rgb from Color Do brighter Do darker SwiftUI color
- Host: GitHub
- URL: https://github.com/swiftuiux/d3-color
- Owner: swiftuiux
- License: apache-2.0
- Created: 2022-06-01T10:55:56.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-09-13T12:12:55.000Z (9 months ago)
- Last Synced: 2024-11-28T18:41:35.812Z (7 months ago)
- Topics: brigther, color, darker, ios, macos, rgb, swift, swiftui
- Language: Swift
- Homepage:
- Size: 397 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SwiftUI Color extender
[](https://swiftpackageindex.com/swiftuiux/d3-color)
[](https://swiftpackageindex.com/swiftuiux/d3-color)Useful extensions and functions used with SwiftUI Color
## Computed properties
* `rgba` - returns values RGB and alfa channels for Color instance
## Functions
* `doBrighter (k: Double?)` - increase intensity of the color. k - is level of the intensity Default value 0.05
* `doDarker(k: Double?)` - decrease intensity of the color. k - is level of the intensity Default value 0.05
## Used in
- [Menu bar component - SwiftUI](https://github.com/swiftuiux/d3-menu-bar)
- [Auto scrollable header menu - SwiftUI & Combine](https://github.com/swiftuiux/food-scrollable-menu-list)