The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
Concurrency Updates!
The API has changed due to adding Sendable conformances, and constraining some types to `@MainActor` in order to achieve strict concurrency support. I'm still working on adding full snippets support and expanding examples, but wanted to get the concurrency update out there, even without all the docs I'd hoped to have in place by now.
## What's Changed
* trying snippets - error in Xcode, but not in SwiftPM build process...… by @heckj in https://github.com/swiftviz/Scale/pull/51
* cleanup by @heckj in https://github.com/swiftviz/Scale/pull/52
* Codeql beta by @heckj in https://github.com/swiftviz/Scale/pull/53
* Swift6 prep by @heckj in https://github.com/swiftviz/Scale/pull/54
* cleanup by @heckj in https://github.com/swiftviz/Scale/pull/55
* consistency cleanup by @heckj in https://github.com/swiftviz/Scale/pull/56
**Full Changelog**: https://github.com/swiftviz/Scale/compare/0.7.5...0.8.0
Incremental update
1 year ago
## What's Changed
The major additions are:
- color interpolations and new scales to support interpolated colors, including facilities to interpolate within the LCH color space.
- basic histogram and binning support
- initial setup for Date oriented scales and relevant date "ticks" and logic for associated 'nice' values.
* Generating images for DocC documentation by @heckj in https://github.com/swiftviz/Scale/pull/33
* Documentation updates by @heckj in https://github.com/swiftviz/Scale/pull/45
* Updating and fixing CI build issues by @heckj in https://github.com/swiftviz/Scale/pull/37
* LCH cleanup by @heckj in https://github.com/swiftviz/Scale/pull/38
* External cli by @heckj in https://github.com/swiftviz/Scale/pull/39
* Closure interpolator by @heckj in https://github.com/swiftviz/Scale/pull/40
* Color updates and tables displaying them by @heckj in https://github.com/swiftviz/Scale/pull/41
* Binning by @heckj in https://github.com/swiftviz/Scale/pull/42
* Updates to tick methods by @heckj in https://github.com/swiftviz/Scale/pull/46
* Histogram tweaks by @heckj in https://github.com/swiftviz/Scale/pull/47
* Date scales by @heckj in https://github.com/swiftviz/Scale/pull/48
* tweaking date nice values logic and computations by @heckj in https://github.com/swiftviz/Scale/pull/50
**Full Changelog**: https://github.com/swiftviz/Scale/compare/0.7.0...0.7.5
Chromatic Scales
1 year ago
## What's Changed
* Two very impactful changes - the first being that a lot of duplicate code (and types!) were collapsed - Linear, Log, Power, and Radial scales are now all a single type: ContinuousScale, with the same functionality as before. With collapsing it, I also removed the AnyContinuousScale type-erased wrapper, as it was no longer needed with the refactored type.
* cleanup and deduce of code and types by @heckj in https://github.com/swiftviz/Scale/pull/29
* Color scales are now included - which include mechanisms to interpolate between colors you provide through a perceptually uniform color space (LCH) as well as replicating a number of the continuous color scales from D3-scale-chromatic. The PR also added a new target to the library that contains SwiftUI views specific to visualizing the color scales and ranges, primarily for a visual review and exploration of the content and values through the lens of various color spaces.
* by @heckj in https://github.com/swiftviz/Scale/pull/31
* The "nice" algorithm was fixed up and collapsed as well, resolving an issue where niceValue wasn't correctly returning "lower" nice values by @heckj in https://github.com/swiftviz/Scale/pull/28
**Full Changelog**: https://github.com/swiftviz/Scale/compare/0.6.0...0.7.0
Continuous, Discrete, and reversible scales
1 year ago
A significant (and API breaking) update as Scale was more aggressively used supporting a [charting DSL library](https://github.com/swiftviz/Chart) still in development. The continuous scales were both expanding and combined to support Linear, Log, Power, or Radial scales - and can be utilized through a type-erased AnyContinuousScale. Discrete scales that return a band or a point were also created. Tick values were revised, and the API for accessing and using the scales evolved as the use cases for what information was available at different parts of the lifecycle of a declarative syntax came into focus.
The initial scale creation is now set up such that you can create a scale, then define a "domain" upon it, or update that domain. The pieces for computing a scale value require a range to be set, and reversibility of that mapping was enabled as well in any of the APIs that accept range values. The ranges can be defined as a single value (inferring `0` for the other value), two values, or a swift range instance. All modifier methods return a copy of the scale with the relevant values updated so that the scale can be passed along and more easily used in a functional style setting.
While the structure for the continuous scales seems pretty solid at this point, the discrete scales may see quite a bit of alteration down the road. In particular, the idea of returning a Band structure as a result of a scaling operation rather than a singular value can make for awkward usage scenarios, although the structure itself is useful for bar charts. It may be better as something computer after the fact, and keep the scale (or invert) operations more consistent across the scale APIs.
Scaling that maps through the realm of dates or colors - in discrete or continuous forms - is still pending, and I expect the next revision cycle for scale will accommodate those and the implementation and usage of those scales will potentially set up further changes going forward.
My current thinking for a stable API is to get the discrete color and date/time oriented scales created, and use them in implementations to vet them, before reviewing the API as a whole and locking it down a bit more for backwards compatibility. The primary consumer of this API so far is [Chart](https://github.com/swiftviz/Chart), now functional but still rapidly evolving. Some discussion of [how scale is used and what's needed](https://github.com/swiftviz/Chart/discussions/13) is included within the [chart discussions](https://github.com/swiftviz/Chart/discussions).
Future updates will include at least a beta release before a 1.0.0 release which will mark backwards compatibility as standard with [semantic versioning](https://www.semver.org/).
## What's Changed
* Add CGFloat output type scale implementations by @heckj in https://github.com/swiftviz/Scale/pull/9
* Declarative initializer by @heckj in https://github.com/swiftviz/Scale/pull/10
* Creating band and point scales by @heckj in https://github.com/swiftviz/Scale/pull/11
* Reset continuous scales to modifier pattern by @heckj in https://github.com/swiftviz/Scale/pull/12
* Documentation updates by @heckj in https://github.com/swiftviz/Scale/pull/13
* Add type erased AnyContinuousScale by @heckj in https://github.com/swiftviz/Scale/pull/14
* Add radial scale with tests by @heckj in https://github.com/swiftviz/Scale/pull/15
* Extending Scale type to accommodate range by @heckj in https://github.com/swiftviz/Scale/pull/17
* Add domain modifier with 'nice' by @heckj in https://github.com/swiftviz/Scale/pull/18
* Add a single domain value by @heckj in https://github.com/swiftviz/Scale/pull/19
* Simplify Tick considerably after some usage by @heckj in https://github.com/swiftviz/Scale/pull/20
* Adding Ticks to AnyContinuousScale by @heckj in https://github.com/swiftviz/Scale/pull/21
* Ticks protocol by @heckj in https://github.com/swiftviz/Scale/pull/22
* Tick updates by @heckj in https://github.com/swiftviz/Scale/pull/23
* Fixing doc references as library has evolved by @heckj in https://github.com/swiftviz/Scale/pull/24
* Reversed mapping by @heckj in https://github.com/swiftviz/Scale/pull/26
## New Contributors
* @heckj made their first contribution in https://github.com/swiftviz/Scale/pull/9
**Full Changelog**: https://github.com/swiftviz/Scale/compare/0.5.0...0.6.0
Initial Scale release
2 years ago
The code in this release was previously included in [SwiftViz](https://github.com/swiftviz/SwiftViz). In order to re-order things so that SwiftViz is the overall collection, it was useful to move this code into it's own a repository and Swift module so that other packages under this organization ([Chart](https://github.com/swiftviz/chart)) could use it and then later also be collected into the overall setup under SwiftViz.
Related issues have been migrated to this repository and doc links updated.
The release is functional, but the API structure is far from certain, with some additional scales and usage considerations I'd like to include before I get close to calling this a 1.0 release. (See #1, #2, #4, and #5 in particular).
The code within this package includes a Scale concept, implemented with Swift generics - as well as the algorithms for generating "nice" values for more convenient visualization results, and ticks for labeling a visual axis that might be associated with the scale.