-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
115 changed files
with
5,660 additions
and
1,907 deletions.
There are no files selected for viewing
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* @stephanecopin @metatheoretic @heymansmile @notbenoit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
ignore: | ||
- "Pods" | ||
- "Tests" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
## Main | ||
|
||
##### New Features/Enhancements | ||
|
||
- Add `ActionProtocol` | ||
- Add `AnyAction`, allowing to type-erase any actions represented by a `ActionProtocol` | ||
- Add `CoalescingAction` & `OverridingAction` | ||
- Add a `CombineExtensions` & `CombineExtensionsProvider` protocol, replicating the `.reactive` of ReactiveSwift (so as not to pollute too much the global namespace) | ||
- All `NSObject` now can have a `cancellables` object attached to them via `<object>.combineExtensions.cancellables`. It's created lazily, so there's impact if not used. | ||
- Extend `Publisher.handleEvents` to add two new hooks: | ||
- `receiveTermination`: When either a completion or a cancellation is received | ||
- `receiveResult`: Takes a `Result`, and called when either values are received or an error is received | ||
- Add `Publisher.promoteOptional()` | ||
- Add `then(receiveResult:)`, which takes a closure with a `Result`, allowing to handle values & error in the same place | ||
- Add `sinkForLifetimeOf(_:)` methods family, allowing to sink on a publisher and link to the lifetime of a given `CombineExtensionsProvider & AnyObject`. The goal of this is to avoid having to write the classic boilerplate code in Combine handling with having to create `cancellables` for every single object (this used the `cancellables` extension mentioned above). | ||
- Add `performDuringLifetimeOf(_:action:)`, allowing to link an action with the lifetime of an object. This act as an equivalent for `makeBindingTarget` from `ReactiveSwift` when calling functions or assigning multiple variables. | ||
- Add `assign(to:forLifetimeOf:)`, allowing to assign the output of the producer to a keyPath, keeping it alive until the specified object is deallocated. | ||
- Add `TapAction` and `<UIControl>.combineExtensions.tapped`, allowing to link an `Action` to a button, without having to do the bindings manually (similar to `UIButton.reactive.pressed` in ReactiveCocoa) | ||
- Add `<UIControl>.publisherForControlEvent(_:)`, to get a publisher that triggers on any control events. | ||
- Add `(UITextField/UITextView).(textValues|continuousTextValues)`, which are equivalent to same thing as for ReactiveCocoa. | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#54](https://github.com/Fueled/ios-utilities/pull/54) | ||
|
||
- Add an optional `insets` parameter to `addAndFitSubview()` | ||
- Make `removeArrangedSubviews()`'s `removeFromHierachy` parameter default to `true` | ||
- Add `tapped` helper to link any `ReactiveActionProtocol` to any `UIControl` | ||
- Add `AnyIdentifiable` & `AnyAction` for type-erased `Identifiable` & `ReactiveActionProtocol` respectively | ||
- Add `OverridingAction`, a new `Action` that if executed when already executing, will cancel the previous producer and start a new one | ||
- Make `OrderedSet` conform to `SetAlgebra` | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#53](https://github.com/Fueled/ios-utilities/pull/53) | ||
|
||
##### Bug Fixes | ||
|
||
- Fix a bug in `CombineLatestMany` where cancelling the resulting publisher would not cancel the array of publishers themselves. | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#55](https://github.com/Fueled/ios-utilities/pull/55) | ||
|
||
- Fix a bug in `Action` where a cancellation would be ignored and not set `isExecuting` to `false` | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#54](https://github.com/Fueled/ios-utilities/pull/54) | ||
|
||
- Fix an internal state corruption issue in `OrderedSet` | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#53](https://github.com/Fueled/ios-utilities/pull/53) | ||
|
||
##### Breaking changes | ||
|
||
- The original `TapAction`, `OverridingAction` and `AnyAction` were all prefixed with `Reactive`. | ||
[Stéphane Copin](https://github.com/stephanecopin) | ||
[#54](https://github.com/Fueled/ios-utilities/pull/54) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Submodule ReactiveCocoa
deleted from
21deb6
Submodule ReactiveSwift
deleted from
b772fa
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# frozen_string_literal: true | ||
|
||
has_app_changes = !git.modified_files.grep(/FueledUtils/).empty? | ||
if !git.modified_files.include?('CHANGELOG.md') && has_app_changes | ||
warn("Please include a CHANGELOG entry to credit yourself! \nYou can find it at [CHANGELOG.md](https://github.com/Fueled/ios-utilities/blob/develop/CHANGELOG.md).", :sticky => false) | ||
markdown <<-MARKDOWN | ||
Here's an example of your CHANGELOG entry: | ||
```markdown | ||
- #{github.pr_title}\s\s | ||
[#{github.pr_author}](https://github.com/#{github.pr_author}) | ||
[#pull_request_number](https://github.com/Fueled/ios-utilities/pulls/pull_request_number) | ||
``` | ||
*note*: There are two invisible spaces after the entry's text. | ||
MARKDOWN | ||
end |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,97 @@ | ||
# frozen_string_literal: true | ||
|
||
Pod::Spec.new do |s| | ||
s.name = 'FueledUtils' | ||
s.version = '2.0.3' | ||
s.summary = 'A collection of utilities used at Fueled' | ||
s.description = 'This is a collection of classes, extensions, methods and functions used within Fueled projects that aims at decomplexifying tasks that should be easy.' | ||
s.swift_version = '5' | ||
|
||
s.homepage = 'https://github.com/Fueled/ios-utilities' | ||
s.license = { :type => 'Apache License, Version 2.0', :file => 'LICENSE' } | ||
s.author = { 'Vadim-Yelagin' => 'vadim.yelagin@gmail.com', 'stephanecopin' => 'stephane@fueled.com', 'leontiy' => 'leonty@fueled.com', 'bastienFalcou' => 'bastien@fueled.com', 'heymansmile' => 'ivan@fueled.com', 'thib4ult' => 'thibault@fueled.com', 'notbenoit' => 'benoit@fueled.com' } | ||
s.source = { :git => 'https://github.com/Fueled/ios-utilities.git', :tag => s.version.to_s } | ||
s.documentation_url = 'https://cdn.rawgit.com/Fueled/ios-utilities/master/docs/index.html' | ||
|
||
s.ios.deployment_target = '8.0' | ||
s.osx.deployment_target = '10.9' | ||
s.watchos.deployment_target = '2.0' | ||
s.tvos.deployment_target = '9.0' | ||
|
||
s.source_files = 'FueledUtils/**/*.swift' | ||
s.osx.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/ButtonWithTitleAdjustment.swift', 'FueledUtils/DecoratingTextFieldDelegate.swift', 'FueledUtils/DimmingButton.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/KeyboardInsetHelper.swift', 'FueledUtils/LabelWithTitleAdjustment.swift', 'FueledUtils/ReactiveCocoaExtensions.swift', 'FueledUtils/ScrollViewPage.swift', 'FueledUtils/SetRootViewController.swift', 'FueledUtils/SignalingAlert.swift', 'FueledUtils/UIExtensions.swift', 'FueledUtils/GradientView.swift'] | ||
s.ios.exclude_files = ['FueledUtils/FueledUtils.h'] | ||
s.watchos.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/ButtonWithTitleAdjustment.swift', 'FueledUtils/DecoratingTextFieldDelegate.swift', 'FueledUtils/DimmingButton.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/KeyboardInsetHelper.swift', 'FueledUtils/LabelWithTitleAdjustment.swift', 'FueledUtils/ReactiveCocoaExtensions.swift', 'FueledUtils/ScrollViewPage.swift', 'FueledUtils/SetRootViewController.swift', 'FueledUtils/SignalingAlert.swift', 'FueledUtils/UIExtensions.swift', 'FueledUtils/GradientView.swift'] | ||
s.tvos.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/KeyboardInsetHelper.swift'] | ||
|
||
s.dependency 'ReactiveSwift', '~> 6.0' | ||
s.dependency 'ReactiveCocoa', '~> 10.0' | ||
s.name = 'FueledUtils' | ||
s.version = '3.0.0' | ||
s.summary = 'A collection of utilities used at Fueled' | ||
s.description = 'This is a collection of classes, extensions, methods and functions used within Fueled projects that aims at decomplexifying tasks that should be easy.' | ||
s.swift_version = '5' | ||
|
||
s.homepage = 'https://github.com/Fueled/ios-utilities' | ||
s.license = { type: 'Apache License, Version 2.0', file: 'LICENSE' } | ||
s.author = { 'Vadim-Yelagin' => 'vadim.yelagin@gmail.com', 'stephanecopin' => 'stephane@fueled.com', 'leontiy' => 'leonty@fueled.com', 'bastienFalcou' => 'bastien@fueled.com', 'heymansmile' => 'ivan@fueled.com', 'thib4ult' => 'thibault@fueled.com', 'notbenoit' => 'benoit@fueled.com' } | ||
s.source = { git: 'https://github.com/Fueled/ios-utilities.git', tag: s.version.to_s } | ||
s.documentation_url = 'https://cdn.rawgit.com/Fueled/ios-utilities/master/docs/index.html' | ||
|
||
s.ios.deployment_target = '9.0' | ||
s.osx.deployment_target = '10.12' | ||
s.watchos.deployment_target = '2.0' | ||
s.tvos.deployment_target = '9.0' | ||
|
||
s.subspec 'Core' do |s| | ||
s.source_files = 'FueledUtils/Core/**/*.swift' | ||
end | ||
|
||
s.subspec 'ReactiveCommon' do |s| | ||
s.source_files = 'FueledUtils/ReactiveCommon/**/*.swift' | ||
|
||
s.dependency 'FueledUtils/Core' | ||
end | ||
|
||
s.subspec 'ReactiveSwift' do |s| | ||
s.dependency 'FueledUtils/ReactiveCommon' | ||
s.dependency 'ReactiveSwift', '~> 6.0' | ||
s.dependency 'ReactiveCocoa', '~> 10.0' | ||
|
||
s.source_files = 'FueledUtils/ReactiveSwift/**/*.swift' | ||
end | ||
|
||
s.subspec 'UIKit' do |s| | ||
s.dependency 'FueledUtils/Core' | ||
s.ios.source_files = 'FueledUtils/UIKit/**/*.swift' | ||
end | ||
|
||
s.subspec 'ReactiveSwiftUIKit' do |s| | ||
s.dependency 'FueledUtils/ReactiveSwift' | ||
s.dependency 'FueledUtils/UIKit' | ||
|
||
s.ios.source_files = 'FueledUtils/ReactiveSwiftUIKit/**/*.swift' | ||
end | ||
|
||
s.subspec 'Combine' do |s| | ||
# Update the above with the following versions when we drop support for iOS < 13.0 or | ||
# uncomment below if https://github.com/CocoaPods/CocoaPods/issues/7333 is implemented | ||
# s.ios.deployment_target = '13.0' | ||
# s.osx.deployment_target = '10.15' | ||
# s.watchos.deployment_target = '6.0' | ||
# s.tvos.deployment_target = '13.0' | ||
|
||
s.dependency 'FueledUtils/ReactiveCommon' | ||
|
||
s.source_files = 'FueledUtils/Combine/**/*.swift' | ||
end | ||
|
||
s.subspec 'CombineOperators' do |s| | ||
s.dependency 'FueledUtils/Combine' | ||
|
||
s.source_files = 'FueledUtils/CombineOperators/**/*.swift' | ||
end | ||
|
||
s.subspec 'CombineUIKit' do |s| | ||
s.dependency 'FueledUtils/Combine' | ||
s.dependency 'FueledUtils/UIKit' | ||
|
||
s.ios.source_files = 'FueledUtils/CombineUIKit/**/*.swift' | ||
end | ||
|
||
s.subspec 'SwiftUI' do |s| | ||
s.dependency 'FueledUtils/Core' | ||
s.dependency 'FueledUtils/Combine' | ||
|
||
s.source_files = 'FueledUtils/SwiftUI/**/*.swift' | ||
end | ||
|
||
s.subspec 'ReactiveCombineBridge' do |s| | ||
s.dependency 'FueledUtils/ReactiveSwift' | ||
s.dependency 'FueledUtils/Combine' | ||
|
||
s.source_files = 'FueledUtils/ReactiveCombineBridge/**/*.swift' | ||
end | ||
|
||
s.osx.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/ButtonWithTitleAdjustment.swift', 'FueledUtils/DecoratingTextFieldDelegate.swift', 'FueledUtils/DimmingButton.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/KeyboardInsetHelper.swift', 'FueledUtils/LabelWithTitleAdjustment.swift', 'FueledUtils/ReactiveCocoaExtensions.swift', 'FueledUtils/ScrollViewPage.swift', 'FueledUtils/SetRootViewController.swift', 'FueledUtils/SignalingAlert.swift', 'FueledUtils/UIExtensions.swift', 'FueledUtils/GradientView.swift'] | ||
s.ios.exclude_files = ['FueledUtils/FueledUtils.h'] | ||
s.watchos.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/ButtonWithTitleAdjustment.swift', 'FueledUtils/DecoratingTextFieldDelegate.swift', 'FueledUtils/DimmingButton.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/HairlineView.swift', 'FueledUtils/KeyboardInsetHelper.swift', 'FueledUtils/LabelWithTitleAdjustment.swift', 'FueledUtils/ReactiveCocoaExtensions.swift', 'FueledUtils/ScrollViewPage.swift', 'FueledUtils/SetRootViewController.swift', 'FueledUtils/SignalingAlert.swift', 'FueledUtils/UIExtensions.swift', 'FueledUtils/GradientView.swift'] | ||
s.tvos.exclude_files = ['FueledUtils/FueledUtils.h', 'FueledUtils/KeyboardInsetHelper.swift'] | ||
|
||
s.default_subspecs = 'Core' | ||
end |
Oops, something went wrong.