Skip to content

Commit

Permalink
Release 3.0.0 (#46)
Browse files Browse the repository at this point in the history
Release `3.0.0`
  • Loading branch information
nik3212 authored Jun 15, 2024
2 parents 34fa77b + 752bfd4 commit 8ac4f11
Show file tree
Hide file tree
Showing 13 changed files with 36 additions and 16 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
All notable changes to this project will be documented in this file.

#### 3.x Releases
- `3.0.x` Releases - [`3.0.0`](#300)
- `3.0.0` Release Candidates - [`3.0.0-rc.1`](#300-rc1) | [`3.0.0-rc.2`](#300-rc2)

#### 2.x Releases
Expand All @@ -10,6 +11,13 @@ All notable changes to this project will be documented in this file.
#### 1.x Releases
- `1.0.x` Releases - [1.0.0](#100)

## [3.0.0](https://github.com/space-code/flare/releases/tag/3.0.0)
Released on 2024-06-15.

## Added
- Implement disabling of the purchase button
- Added in Pull Request [#44](https://github.com/space-code/flare/pull/44).

## [3.0.0-rc.2](https://github.com/space-code/flare/releases/tag/3.0.0-rc.2)
Released on 2024-05-10.

Expand Down
5 changes: 4 additions & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,20 @@ GEM
open4 (1.3.4)
public_suffix (5.0.3)
rchardet (1.8.0)
rexml (3.2.6)
rexml (3.2.8)
strscan (>= 3.0.9)
ruby2_keywords (0.0.5)
sawyer (0.9.2)
addressable (>= 2.3.5)
faraday (>= 0.17.3, < 3)
strscan (3.1.0)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
unicode-display_width (2.5.0)

PLATFORMS
x86_64-darwin-22
x86_64-linux

DEPENDENCIES
danger
Expand Down
4 changes: 2 additions & 2 deletions Mintfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
nicklockwood/SwiftFormat@0.52.7
realm/SwiftLint@0.53.0
nicklockwood/SwiftFormat@0.54.0
realm/SwiftLint@0.55.1
4 changes: 2 additions & 2 deletions Package.resolved
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/pointfreeco/swift-snapshot-testing",
"state" : {
"revision" : "e7b77228b34057041374ebef00c0fd7739d71a2b",
"version" : "1.15.3"
"revision" : "8ddd519780452729c6634ad6bd0d2595938e9ea3",
"version" : "1.16.1"
}
},
{
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
<a href="https://github.com/space-code/flare/blob/main/LICENSE"><img alt="Licence" src="https://img.shields.io/cocoapods/l/service-core.svg?style=flat"></a>
<a href="https://swiftpackageindex.com/space-code/flare"><img alt="Swift Compatibility" src="https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fspace-code%2Fflare%2Fbadge%3Ftype%3Dswift-versions"/></a>
<a href="https://swiftpackageindex.com/space-code/flare"><img alt="Platform Compatibility" src="https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fspace-code%2Fflare%2Fbadge%3Ftype%3Dplatforms"/></a>
<a href="https://github.com/space-code/flare"><img alt="CI" src="https://github.com/space-code/flare/actions/workflows/ci.yml/badge.svg?branch=main"></a>
<a href="https://github.com/space-code/flare"><img alt="CI" src="https://github.com/space-code/flare/actions/workflows/flare.yml/badge.svg?branch=main"></a>
<a href="https://github.com/space-code/flare"><img alt="CI" src="https://github.com/space-code/flare/actions/workflows/flare_ui.yml/badge.svg?branch=main"></a>
<a href="https://codecov.io/gh/space-code/flare"><img alt="CodeCov" src="https://codecov.io/gh/space-code/flare/graph/badge.svg?token=WUWUSKQZWY"></a>
<a href="https://github.com/apple/swift-package-manager" alt="Flare on Swift Package Manager" title="Flare on Swift Package Manager"><img src="https://img.shields.io/badge/Swift%20Package%20Manager-compatible-brightgreen.svg" /></a>
<a href="https://codecov.io/gh/space-code/flare"><img alt="GitHub release; latest by date" src="https://img.shields.io/github/v/release/space-code/flare"></a>
Expand Down
2 changes: 1 addition & 1 deletion Sources/Flare/Flare.docc/Flare.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Flare.shared.products(productIDs: ["product_identifier"]) { result in

| Flare | Date | Swift | Xcode | Platforms |
|-------|------------|-------|---------|-------------------------------------------------------------|
| 3.0 | unreleased | 5.7 | 14.1 | iOS 13.0, watchOS 6.0, macOS 10.15, tvOS 13.0, visionOS 1.0 |
| 3.0 | 15/06/2024 | 5.7 | 14.1 | iOS 13.0, watchOS 6.0, macOS 10.15, tvOS 13.0, visionOS 1.0 |
| 2.0 | 14/09/2023 | 5.7 | 14.1 | iOS 13.0, watchOS 6.0, macOS 10.15, tvOS 13.0, visionOS 1.0 |
| 1.0 | 21/01/2023 | 5.5 | 13.4.1 | iOS 13.0, watchOS 6.0, macOS 10.15, tvOS 13.0 |

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,16 @@ import SwiftUI
struct PrimaryButtonStyle: ButtonStyle {
// MARK: Properties

private let disabled: Bool

@Environment(\.tintColor) private var tintColor

// MARK: Initialization

init(disabled: Bool) {
self.disabled = disabled
}

// MARK: ButtonStyle

func makeBody(configuration: Configuration) -> some View {
Expand All @@ -24,7 +32,7 @@ struct PrimaryButtonStyle: ButtonStyle {
.frame(height: 50.0)
.frame(maxWidth: .infinity)
.padding(.horizontal)
.background(tintColor)
.background(disabled ? Palette.systemGray : tintColor)
.clipShape(RoundedRectangle(cornerSize: .init(width: 14, height: 14)))
.opacity(configuration.isPressed ? 0.5 : 1.0)
}
Expand All @@ -38,6 +46,6 @@ struct PrimaryButtonStyle: ButtonStyle {
@available(visionOS, unavailable)
extension ButtonStyle where Self == PrimaryButtonStyle {
static var primary: PrimaryButtonStyle {
PrimaryButtonStyle()
PrimaryButtonStyle(disabled: true)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ struct BorderedSubscriptionStoreControlStyleView: View {
}, label: {
labelView(configuration)
})
.buttonStyle(PrimaryButtonStyle())
.disabled(!configuration.isActive)
.buttonStyle(PrimaryButtonStyle(disabled: !configuration.isActive))
}

// MARK: Private
Expand Down Expand Up @@ -88,7 +89,7 @@ struct BorderedSubscriptionStoreControlStyleView: View {
description: .init(Text("Name")),
price: .init(Text("Name")),
isSelected: true,
isActive: true,
isActive: false,
action: {}
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import SwiftUI
struct CardButtonSubscriptionStoreControlView: View {
// MARK: Properties

// @Environment(\.isFocused) private var isFocused: Bool
@Environment(\.tintColor) private var tintColor

private let configuration: SubscriptionStoreControlStyleConfiguration
Expand All @@ -31,7 +30,7 @@ struct CardButtonSubscriptionStoreControlView: View {
var body: some View {
ZStack {
Rectangle()
.fill(tintColor) // isFocused ? tintColor.opacity(0.85) : tintColor)
.fill(tintColor)

VStack(alignment: .leading) {
VStack(alignment: .leading) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/FlareUI/FlareUI.docc/FlareUI.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ present(nav, animated: true)

| FlareUI | Date | Swift | Xcode | Platforms |
|---------|------------|-------|---------|-------------------------------------------------------------|
| 3.0 | unreleased | 5.7 | 14.1 | iOS 13.0, macOS 10.15, tvOS 13.0
| 3.0 | 15/06/2024 | 5.7 | 14.1 | iOS 13.0, macOS 10.15, tvOS 13.0

## License

Expand Down
4 changes: 2 additions & 2 deletions Tests/SnapshotTests/SubscriptionsViewSnapshotTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ final class SubscriptionsViewSnapshotTests: SnapshotTestCase {
of: makeView()
.subscriptionMarketingContent(view: { Text("Header View") })
#if os(iOS)
.subscriptionBackground(Color.gray)
.subscriptionBackground(Color.green)
.subscriptionHeaderContentBackground(Color.blue)
.subscriptionButtonLabel(.multiline)
#endif
.storeButton(.visible, types: .policies)
.tintColor(.green)
.tintColor(.red)
.subscriptionControlStyle(.button),

size: .size
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 8ac4f11

Please sign in to comment.