mirror of
https://github.com/pese-git/cherrypick.git
synced 2026-01-24 05:25:19 +00:00
Compare commits
8 Commits
cherrypick
...
cherrypick
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e2562d22bb | ||
|
|
1a6e3d0b97 | ||
|
|
ea8ff1da83 | ||
|
|
ff55ddb491 | ||
|
|
3d3130914a | ||
|
|
35f7c27360 | ||
|
|
36e42171b7 | ||
|
|
1a1fe9c4e4 |
2
.gitignore
vendored
2
.gitignore
vendored
@@ -7,6 +7,8 @@
|
|||||||
.idea/
|
.idea/
|
||||||
.vscode/
|
.vscode/
|
||||||
|
|
||||||
|
pubspec_overrides.yaml
|
||||||
|
|
||||||
melos_cherrypick.iml
|
melos_cherrypick.iml
|
||||||
melos_cherrypick_workspace.iml
|
melos_cherrypick_workspace.iml
|
||||||
melos_cherrypick_flutter.iml
|
melos_cherrypick_flutter.iml
|
||||||
51
CHANGELOG.md
51
CHANGELOG.md
@@ -3,6 +3,57 @@
|
|||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||||
|
|
||||||
|
## 2025-05-16
|
||||||
|
|
||||||
|
### Changes
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Packages with breaking changes:
|
||||||
|
|
||||||
|
- There are no breaking changes in this release.
|
||||||
|
|
||||||
|
Packages with other changes:
|
||||||
|
|
||||||
|
- [`cherrypick` - `v2.0.2`](#cherrypick---v202)
|
||||||
|
- [`cherrypick_flutter` - `v1.1.1`](#cherrypick_flutter---v111)
|
||||||
|
|
||||||
|
Packages with dependency updates only:
|
||||||
|
|
||||||
|
> Packages listed below depend on other packages in this workspace that have had changes. Their versions have been incremented to bump the minimum dependency versions of the packages they depend upon in this project.
|
||||||
|
|
||||||
|
- `cherrypick_flutter` - `v1.1.1`
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### `cherrypick` - `v2.0.2`
|
||||||
|
|
||||||
|
- **FIX**: support passing params when resolving dependency recursively in parent scope.
|
||||||
|
|
||||||
|
|
||||||
|
## 2025-05-03
|
||||||
|
|
||||||
|
### Changes
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Packages with breaking changes:
|
||||||
|
|
||||||
|
- There are no breaking changes in this release.
|
||||||
|
|
||||||
|
Packages with other changes:
|
||||||
|
|
||||||
|
- [`cherrypick_flutter` - `v1.1.0`](#cherrypick_flutter---v110)
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
#### `cherrypick_flutter` - `v1.1.0`
|
||||||
|
|
||||||
|
- **FIX**: update description.
|
||||||
|
- **FIX**: update gitignore.
|
||||||
|
- **FEAT**: modify api in CherryPickProvider.
|
||||||
|
|
||||||
|
|
||||||
## 2025-05-02
|
## 2025-05-02
|
||||||
|
|
||||||
### Changes
|
### Changes
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
## 2.0.2
|
||||||
|
|
||||||
|
- **FIX**: support passing params when resolving dependency recursively in parent scope.
|
||||||
|
|
||||||
## 2.0.1
|
## 2.0.1
|
||||||
|
|
||||||
- **FIX**: fix warning.
|
- **FIX**: fix warning.
|
||||||
|
|||||||
@@ -130,6 +130,6 @@ class Scope {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 2 Поиск зависимостей в родительском скоупе
|
// 2 Поиск зависимостей в родительском скоупе
|
||||||
return _parentScope?.tryResolve(named: named);
|
return _parentScope?.tryResolve(named: named, params: params);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
name: cherrypick
|
name: cherrypick
|
||||||
description: Cherrypick is a small dependency injection (DI) library for dart/flutter projects.
|
description: Cherrypick is a small dependency injection (DI) library for dart/flutter projects.
|
||||||
version: 2.0.1
|
version: 2.0.2
|
||||||
homepage: https://pese-git.github.io/cherrypick-site/
|
homepage: https://pese-git.github.io/cherrypick-site/
|
||||||
documentation: https://github.com/pese-git/cherrypick/wiki
|
documentation: https://github.com/pese-git/cherrypick/wiki
|
||||||
repository: https://github.com/pese-git/cherrypick
|
repository: https://github.com/pese-git/cherrypick
|
||||||
|
|||||||
3
cherrypick_flutter/.gitignore
vendored
3
cherrypick_flutter/.gitignore
vendored
@@ -27,3 +27,6 @@ migrate_working_dir/
|
|||||||
**/doc/api/
|
**/doc/api/
|
||||||
.dart_tool/
|
.dart_tool/
|
||||||
build/
|
build/
|
||||||
|
|
||||||
|
|
||||||
|
pubspec_overrides.yaml
|
||||||
@@ -1,3 +1,13 @@
|
|||||||
|
## 1.1.1
|
||||||
|
|
||||||
|
- Update a dependency to the latest release.
|
||||||
|
|
||||||
|
## 1.1.0
|
||||||
|
|
||||||
|
- **FIX**: update description.
|
||||||
|
- **FIX**: update gitignore.
|
||||||
|
- **FEAT**: modify api in CherryPickProvider.
|
||||||
|
|
||||||
## 1.0.1
|
## 1.0.1
|
||||||
|
|
||||||
- Update a dependency to the latest release.
|
- Update a dependency to the latest release.
|
||||||
|
|||||||
@@ -14,14 +14,15 @@ import 'package:flutter/widgets.dart';
|
|||||||
/// limitations under the License.
|
/// limitations under the License.
|
||||||
///
|
///
|
||||||
|
|
||||||
class CherryPickProvider extends InheritedWidget {
|
final class CherryPickProvider extends InheritedWidget {
|
||||||
// Holds a reference to the root scope object
|
Scope openRootScope() => CherryPick.openRootScope();
|
||||||
final Scope rootScope;
|
|
||||||
|
Scope openSubScope({String scopeName = '', String separator = '.'}) =>
|
||||||
|
CherryPick.openScope(scopeName: scopeName, separator: separator);
|
||||||
|
|
||||||
// Constructor for CherryPickProvider. Initializes with a required rootScope and child widget.
|
// Constructor for CherryPickProvider. Initializes with a required rootScope and child widget.
|
||||||
const CherryPickProvider({
|
const CherryPickProvider({
|
||||||
super.key,
|
super.key,
|
||||||
required this.rootScope,
|
|
||||||
required super.child,
|
required super.child,
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -38,7 +39,6 @@ class CherryPickProvider extends InheritedWidget {
|
|||||||
// Determines whether the widget should notify dependents when it changes
|
// Determines whether the widget should notify dependents when it changes
|
||||||
@override
|
@override
|
||||||
bool updateShouldNotify(CherryPickProvider oldWidget) {
|
bool updateShouldNotify(CherryPickProvider oldWidget) {
|
||||||
// Notify if the rootScope has changed
|
return false;
|
||||||
return rootScope != oldWidget.rootScope;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
name: cherrypick_flutter
|
name: cherrypick_flutter
|
||||||
description: "A new Flutter package project."
|
description: "Flutter library that allows access to the root scope through the context using `CherryPickProvider`."
|
||||||
version: 1.0.1
|
version: 1.1.1
|
||||||
homepage: https://pese-git.github.io/cherrypick-site/
|
homepage: https://pese-git.github.io/cherrypick-site/
|
||||||
documentation: https://github.com/pese-git/cherrypick/wiki
|
documentation: https://github.com/pese-git/cherrypick/wiki
|
||||||
repository: https://github.com/pese-git/cherrypick
|
repository: https://github.com/pese-git/cherrypick
|
||||||
@@ -13,7 +13,7 @@ environment:
|
|||||||
dependencies:
|
dependencies:
|
||||||
flutter:
|
flutter:
|
||||||
sdk: flutter
|
sdk: flutter
|
||||||
cherrypick: ^2.0.1
|
cherrypick: ^2.0.2
|
||||||
|
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
flutter_test:
|
flutter_test:
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
# melos_managed_dependency_overrides: cherrypick
|
|
||||||
dependency_overrides:
|
|
||||||
cherrypick:
|
|
||||||
path: ../cherrypick
|
|
||||||
Reference in New Issue
Block a user