Compare commits

..
51 changed files with 84 additions and 626 deletions
+1
View File
@@ -584,6 +584,7 @@ new_version.sh
.latest_version
.vscode/
example/
models/
build/
*.iml
-70
View File
@@ -3,76 +3,6 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## 2023-08-09
### Changes
---
Packages with breaking changes:
- There are no breaking changes in this release.
Packages with other changes:
- [`wyatt_authentication_bloc` - `v0.5.1`](#wyatt_authentication_bloc---v051)
- [`wyatt_bloc_layout` - `v0.1.1`](#wyatt_bloc_layout---v011)
- [`wyatt_ui_components` - `v0.2.2`](#wyatt_ui_components---v022)
- [`wyatt_ui_kit` - `v3.1.0`](#wyatt_ui_kit---v310)
- [`wyatt_ui_layout` - `v0.1.1`](#wyatt_ui_layout---v011)
---
#### `wyatt_authentication_bloc` - `v0.5.1`
- **FIX**(authentication): try/catch on cache retrieve.
- **FEAT**(auth): add mocked cache data source.
#### `wyatt_bloc_layout` - `v0.1.1`
- **FEAT**(bloc_layout): add consumer layouts.
- **FEAT**(ui_layout-bloc_layout): proxy scaffold fields.
#### `wyatt_ui_components` - `v0.2.2`
- **FIX**: upgrade to flutter 3.10.
- **FEAT**: add items manipulation in bottom bar component.
- **FEAT**(ui): export pricing card.
- **FEAT**(ui): proxy some rich text parameters.
#### `wyatt_ui_kit` - `v3.1.0`
- **FIX**: upgrade to flutter 3.10.
- **FEAT**(ui): export pricing card.
- **FEAT**(ui): proxy some rich text parameters.
- **FEAT**(ui): tweak some values.
#### `wyatt_ui_layout` - `v0.1.1`
- **FEAT**(ui_layout-bloc_layout): proxy scaffold fields.
## 2023-05-06
### Changes
---
Packages with breaking changes:
- There are no breaking changes in this release.
Packages with other changes:
- [`wyatt_authentication_bloc` - `v0.5.0+1`](#wyatt_authentication_bloc---v0501)
---
#### `wyatt_authentication_bloc` - `v0.5.0+1`
- **REFACTOR**(authentication): controle cache checking.
## 2023-05-04
### Changes
@@ -1,12 +1,3 @@
## 0.5.1
- **FIX**(authentication): try/catch on cache retrieve.
- **FEAT**(auth): add mocked cache data source.
## 0.5.0+1
- **REFACTOR**(authentication): controle cache checking.
## 0.5.0
> Note: This release has breaking changes.
@@ -41,7 +41,6 @@ class AuthenticationFirebaseCacheDataSourceImpl<Data>
return null;
}
try {
final jwt = await currentUser.getIdToken(true);
final currentAccount = AccountModel.fromFirebaseUser(
currentUser,
@@ -49,9 +48,6 @@ class AuthenticationFirebaseCacheDataSourceImpl<Data>
);
return currentAccount;
} catch (e) {
return null;
}
}
// Already done by Firebase
@@ -1,41 +0,0 @@
// Copyright (C) 2023 WYATT GROUP
// Please see the AUTHORS file for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
import 'package:wyatt_authentication_bloc/wyatt_authentication_bloc.dart';
/// {@template authentication_mock_cache_data_source_impl}
/// A data source that manages the cache strategy.
/// This implementation is mocked.
/// {@endtemplate}
class AuthenticationMockCacheDataSourceImpl<Data>
extends AuthenticationCacheDataSource<Data> {
/// {@macro authentication_mock_cache_data_source_impl}
AuthenticationMockCacheDataSourceImpl();
@override
Future<void> cacheAccount(Account account) => Future.value();
/// Always returns null.
@override
Future<Account?> getCachedAccount() async {
await Future<void>.delayed(const Duration(milliseconds: 200));
return null;
}
@override
Future<void> removeCachedAccount() => Future.value();
}
@@ -15,6 +15,5 @@
// along with this program. If not, see <https://www.gnu.org/licenses/>.
export 'authentication_firebase_cache_data_source_impl.dart';
export 'authentication_mock_cache_data_source_impl.dart';
export 'authentication_secure_storage_cache_data_source_impl.dart';
export 'authentication_session_data_source_impl.dart';
@@ -40,7 +40,6 @@ abstract class AuthenticationCubit<Data>
/// {@macro authentication_cubit}
AuthenticationCubit({
required this.authenticationRepository,
this.checkForCachedAccountOnInitialization = true,
}) : super(const AuthenticationState.unknown()) {
_init();
}
@@ -48,9 +47,6 @@ abstract class AuthenticationCubit<Data>
/// The authentication repository.
final AuthenticationRepository<Data> authenticationRepository;
/// Automatically check for cached account on initialization.
final bool checkForCachedAccountOnInitialization;
/// The latest session.
AuthenticationSession<Data>? _latestSession;
@@ -60,9 +56,7 @@ abstract class AuthenticationCubit<Data>
_listenForAuthenticationChanges();
/// Check if there is a cached account.
if (checkForCachedAccountOnInitialization) {
await checkForCachedAccount();
}
await authenticationRepository.checkForCachedAccount();
}
void _listenForAuthenticationChanges() {
@@ -154,10 +148,6 @@ abstract class AuthenticationCubit<Data>
),
).call();
/// Checks for cached account.
FutureOr<void> checkForCachedAccount() async =>
authenticationRepository.checkForCachedAccount();
/// Returns latest session.
///
/// Contains latest event and latest session data (account + extra data)
@@ -1,7 +1,7 @@
name: wyatt_authentication_bloc
description: Authentication BLoC for Flutter
repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_authentication_bloc
version: 0.5.1
version: 0.5.0
publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
-5
View File
@@ -1,8 +1,3 @@
## 0.1.1
- **FEAT**(bloc_layout): add consumer layouts.
- **FEAT**(ui_layout-bloc_layout): proxy scaffold fields.
## 0.1.0+1
- Update a dependency to the latest release.
@@ -39,13 +39,13 @@ dependencies:
version: ^2.0.1
wyatt_ui_layout:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.1.1
version: ^0.1.0+1
wyatt_crud_bloc:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.1.1
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
wyatt_component_copy_with_extension:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^2.0.1
@@ -23,12 +23,17 @@ import 'package:wyatt_ui_components/wyatt_ui_components.dart';
mixin CrudMixin<Cubit extends bloc_base.Cubit<dynamic>,
SuccessState extends CrudSuccess> {
Widget errorBuilder(BuildContext context, CrudError state) =>
context.components.errorComponent.call(
message: (state.message != null) ? TextWrapper(state.message!) : null,
);
context.components.error != null
? context.components.errorComponent.call(
message:
(state.message != null) ? TextWrapper(state.message!) : null,
)
: const SizedBox.shrink();
Widget loadingBuilder(BuildContext context, CrudLoading state) =>
context.components.loader ?? const SizedBox.shrink();
context.components.loader != null
? context.components.loaderComponent.call()
: const CircularProgressIndicator();
Widget initialBuilder(BuildContext context, CrudInitial state) =>
const SizedBox.shrink();
@@ -1,23 +0,0 @@
// Copyright (C) 2022 WYATT GROUP
// Please see the AUTHORS file for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base;
import 'package:wyatt_bloc_helper/wyatt_bloc_helper.dart';
abstract class CubitConsumerBase<Cubit extends bloc_base.Cubit<State>,
State extends Object> extends CubitConsumerScreen<Cubit, State> {
const CubitConsumerBase({super.key});
}
@@ -1,31 +0,0 @@
// Copyright (C) 2022 WYATT GROUP
// Please see the AUTHORS file for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
import 'package:flutter/material.dart';
import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base;
import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart';
import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart';
abstract class CubitConsumerCrudBase<Cubit extends bloc_base.Cubit<CrudState>,
CrudSuccessState extends CrudSuccess>
extends CubitConsumerBase<Cubit, CrudState>
with CrudMixin<Cubit, CrudSuccessState> {
const CubitConsumerCrudBase({super.key});
@override
Widget onBuild(BuildContext context, CrudState state) =>
crudBuilder(context, state);
}
@@ -1,25 +0,0 @@
// Copyright (C) 2022 WYATT GROUP
// Please see the AUTHORS file for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base;
import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart';
import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart';
abstract class CubitConsumerCrudItemBase<
Cubit extends bloc_base.Cubit<CrudState>,
T extends Object?> extends CubitConsumerCrudBase<Cubit, CrudLoaded<T>> {
const CubitConsumerCrudItemBase({super.key});
}
@@ -1,25 +0,0 @@
// Copyright (C) 2022 WYATT GROUP
// Please see the AUTHORS file for details.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.
import 'package:flutter_bloc/flutter_bloc.dart' as bloc_base;
import 'package:wyatt_bloc_layout/wyatt_bloc_layout.dart';
import 'package:wyatt_crud_bloc/wyatt_crud_bloc.dart';
abstract class CubitConsumerCrudListBase<
Cubit extends bloc_base.Cubit<CrudState>,
T extends Object?> extends CubitConsumerCrudBase<Cubit, CrudListLoaded<T>> {
const CubitConsumerCrudListBase({super.key});
}
@@ -15,10 +15,6 @@
// along with this program. If not, see <https://www.gnu.org/licenses/>.
export './bottom_navigation_bar_bloc_layout/bottom_navigation_bar_bloc_layout.dart';
export './cubit_consumer_base.dart';
export './cubit_consumer_crud_base.dart';
export './cubit_consumer_crud_item_base.dart';
export './cubit_consumer_crud_list_base.dart';
export './cubit_screen_base.dart';
export './cubit_screen_crud_base.dart';
export './cubit_screen_crud_item_base.dart';
@@ -25,6 +25,7 @@ abstract class TopAppBarGridLayoutCubitScreenCrudList<
const TopAppBarGridLayoutCubitScreenCrudList({
super.custom,
super.height = 60,
super.scaffoldFieldsWrapper,
super.key,
});
}
@@ -26,16 +26,19 @@ abstract class TopAppBarLayoutCubitScreen<Cubit extends bloc_base.Cubit<State>,
const TopAppBarLayoutCubitScreen({
this.custom,
this.height = 60,
this.scaffoldFieldsWrapper,
super.key,
});
final double height;
final TopAppBarComponent? Function(TopAppBarComponent?)? custom;
final ScaffoldFieldsWrapper? scaffoldFieldsWrapper;
@override
Widget parent(BuildContext context, Widget child) => TopAppBarLayout(
height: height,
custom: custom,
scaffoldFieldsWrapper: scaffoldFieldsWrapper,
body: child,
);
}
@@ -27,6 +27,7 @@ abstract class TopAppBarLayoutCubitScreenCrud<
const TopAppBarLayoutCubitScreenCrud({
super.custom,
super.height,
super.scaffoldFieldsWrapper,
super.key,
});
@@ -24,6 +24,7 @@ abstract class TopAppBarLayoutCubitScreenCrudItem<
const TopAppBarLayoutCubitScreenCrudItem({
super.custom,
super.height = 60,
super.scaffoldFieldsWrapper,
super.key,
});
}
@@ -24,6 +24,7 @@ abstract class TopAppBarLayoutCubitScreenCrudList<
const TopAppBarLayoutCubitScreenCrudList({
super.custom,
super.height = 60,
super.scaffoldFieldsWrapper,
super.key,
});
}
+3 -3
View File
@@ -1,7 +1,7 @@
name: wyatt_bloc_layout
description: Layouts based on bloc helper library
repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_bloc_layout
version: 0.1.1
version: 0.1.0+1
publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
@@ -19,7 +19,7 @@ dependencies:
wyatt_ui_layout:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.1.1
version: ^0.1.0+1
wyatt_crud_bloc:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
@@ -27,7 +27,7 @@ dependencies:
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
dev_dependencies:
flutter_test: { sdk: flutter }
@@ -16,7 +16,7 @@ dependencies:
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
dev_dependencies:
build_runner: ^2.3.3
+1 -1
View File
@@ -15,7 +15,7 @@ dependencies:
flutter_bloc: ^8.1.2
flutter_localizations: { sdk: flutter }
http: ^0.13.5
intl: ^0.18.0
intl: ^0.17.0
path: ^1.8.0
petitparser: ^5.1.0
wyatt_architecture:
@@ -1,10 +1,3 @@
## 0.2.2
- **FIX**: upgrade to flutter 3.10.
- **FEAT**: add items manipulation in bottom bar component.
- **FEAT**(ui): export pricing card.
- **FEAT**(ui): proxy some rich text parameters.
## 0.2.1
- **FEAT**: add floating action button component (close #191). (d3184eb3)
@@ -17,15 +17,11 @@ class $CustomBottomNavigationBarCWProxyImpl
CustomBottomNavigationBar currentIndex(int? currentIndex) =>
this(currentIndex: currentIndex);
@override
CustomBottomNavigationBar items(List<BottomNavigationBarItem>? items) =>
this(items: items);
@override
CustomBottomNavigationBar key(Key? key) => this(key: key);
@override
CustomBottomNavigationBar call({
void Function(BuildContext, int)? onTap,
int? currentIndex,
List<BottomNavigationBarItem>? items,
Key? key,
}) =>
CustomBottomNavigationBar(
@@ -27,11 +27,8 @@ abstract class BottomNavigationBarComponent extends Component
const BottomNavigationBarComponent({
this.onTap,
this.currentIndex = 0,
this.items = const <BottomNavigationBarItem>[],
super.key,
});
final int currentIndex;
final void Function(BuildContext, int)? onTap;
final List<BottomNavigationBarItem> items;
}
@@ -9,12 +9,10 @@ part of 'bottom_navigation_bar_component.dart';
abstract class $BottomNavigationBarComponentCWProxy {
BottomNavigationBarComponent onTap(void Function(BuildContext, int)? onTap);
BottomNavigationBarComponent currentIndex(int? currentIndex);
BottomNavigationBarComponent items(List<BottomNavigationBarItem>? items);
BottomNavigationBarComponent key(Key? key);
BottomNavigationBarComponent call({
void Function(BuildContext, int)? onTap,
int? currentIndex,
List<BottomNavigationBarItem>? items,
Key? key,
});
}
@@ -28,17 +28,6 @@ abstract class RichTextBuilderComponent extends Component
this.parser,
this.defaultStyle,
this.styles,
this.strutStyle,
this.textAlign,
this.textDirection,
this.locale,
this.softWrap,
this.overflow,
this.textScaleFactor,
this.maxLines,
this.semanticsLabel,
this.textWidthBasis,
this.selectionColor,
super.key,
});
@@ -63,83 +52,4 @@ abstract class RichTextBuilderComponent extends Component
/// ```
/// in "This text `is red`."
final Map<String, TextStyle>? styles;
final StrutStyle? strutStyle;
/// How the text should be aligned horizontally.
final TextAlign? textAlign;
/// The directionality of the text.
///
/// This decides how [textAlign] values like [TextAlign.start] and
/// [TextAlign.end] are interpreted.
final TextDirection? textDirection;
/// Used to select a font when the same Unicode character can
/// be rendered differently, depending on the locale.
final Locale? locale;
/// Whether the text should break at soft line breaks.
///
/// If false, the glyphs in the text will be positioned as if there
/// was unlimited horizontal space.
final bool? softWrap;
/// How visual overflow should be handled.
///
/// If this is null [TextStyle.overflow] will be used, otherwise the value
/// from the nearest [DefaultTextStyle] ancestor will be used.
final TextOverflow? overflow;
/// The number of font pixels for each logical pixel.
///
/// For example, if the text scale factor is 1.5, text will be 50% larger than
/// the specified font size.
///
/// The value given to the constructor as textScaleFactor. If null, will
/// use the [MediaQueryData.textScaleFactor] obtained from the ambient
/// [MediaQuery], or 1.0 if there is no [MediaQuery] in scope.
final double? textScaleFactor;
/// An optional maximum number of lines for the text to span, wrapping if
/// necessary.
/// If the text exceeds the given number of lines, it will be truncated
/// according to [overflow].
///
/// If this is 1, text will not wrap. Otherwise, text will be wrapped at the
/// edge of the box.
///
/// If this is null, but there is an ambient [DefaultTextStyle] that specifies
/// an explicit number for its [DefaultTextStyle.maxLines], then the
/// [DefaultTextStyle] value will take precedence. You can use a [RichText]
/// widget directly to entirely override the [DefaultTextStyle].
final int? maxLines;
/// {@template flutter.widgets.Text.semanticsLabel}
/// An alternative semantics label for this text.
///
/// If present, the semantics of this widget will contain this value instead
/// of the actual text. This will overwrite any of the semantics labels
/// applied directly to the [TextSpan]s.
///
/// This is useful for replacing abbreviations or shorthands with the full
/// text value:
///
/// ```dart
/// const Text(r'$$', semanticsLabel: 'Double dollars')
/// ```
/// {@endtemplate}
final String? semanticsLabel;
final TextWidthBasis? textWidthBasis;
/// The color to use when painting the selection.
///
/// This is ignored if [SelectionContainer.maybeOf] returns null
/// in the [BuildContext] of the [Text] widget.
///
/// If null, the ambient [DefaultSelectionStyle] is used (if any); failing
/// that, the selection color defaults to [DefaultSelectionStyle.defaultColor]
/// (semi-transparent grey).
final Color? selectionColor;
}
@@ -11,34 +11,12 @@ abstract class $RichTextBuilderComponentCWProxy {
RichTextBuilderComponent parser(RichTextParser? parser);
RichTextBuilderComponent defaultStyle(TextStyle? defaultStyle);
RichTextBuilderComponent styles(Map<String, TextStyle>? styles);
RichTextBuilderComponent strutStyle(StrutStyle? strutStyle);
RichTextBuilderComponent textAlign(TextAlign? textAlign);
RichTextBuilderComponent textDirection(TextDirection? textDirection);
RichTextBuilderComponent locale(Locale? locale);
RichTextBuilderComponent softWrap(bool? softWrap);
RichTextBuilderComponent overflow(TextOverflow? overflow);
RichTextBuilderComponent textScaleFactor(double? textScaleFactor);
RichTextBuilderComponent maxLines(int? maxLines);
RichTextBuilderComponent semanticsLabel(String? semanticsLabel);
RichTextBuilderComponent textWidthBasis(TextWidthBasis? textWidthBasis);
RichTextBuilderComponent selectionColor(Color? selectionColor);
RichTextBuilderComponent key(Key? key);
RichTextBuilderComponent call({
String? text,
RichTextParser? parser,
TextStyle? defaultStyle,
Map<String, TextStyle>? styles,
StrutStyle? strutStyle,
TextAlign? textAlign,
TextDirection? textDirection,
Locale? locale,
bool? softWrap,
TextOverflow? overflow,
double? textScaleFactor,
int? maxLines,
String? semanticsLabel,
TextWidthBasis? textWidthBasis,
Color? selectionColor,
Key? key,
});
}
@@ -17,6 +17,7 @@
import 'package:copy_with_extension/copy_with_extension.dart';
import 'package:flutter/material.dart';
import 'package:wyatt_ui_components/src/domain/entities/entities.dart';
import 'package:wyatt_ui_components/src/domain/entities/floating_buttons/floating_action_button_component.dart';
part 'component_theme_data.g.dart';
/// {@template component_theme_data}
@@ -41,7 +42,6 @@ class ComponentThemeData {
PortfolioCardComponent? portfolioCard,
QuoteCardComponent? quoteCard,
SkillCardComponent? skillCard,
PricingCardComponent? pricingCard,
FloatingActionButtonComponent? floatingActionButton,
}) =>
ComponentThemeData.raw(
@@ -60,7 +60,6 @@ class ComponentThemeData {
portfolioCard: portfolioCard,
quoteCard: quoteCard,
skillCard: skillCard,
pricingCard: pricingCard,
floatingActionButton: floatingActionButton,
);
@@ -82,7 +81,6 @@ class ComponentThemeData {
portfolioCard: other.portfolioCard,
quoteCard: other.quoteCard,
skillCard: other.skillCard,
pricingCard: other.pricingCard,
floatingActionButton: other.floatingActionButton,
);
@@ -108,7 +106,6 @@ class ComponentThemeData {
this.portfolioCard,
this.quoteCard,
this.skillCard,
this.pricingCard,
this.floatingActionButton,
});
@@ -157,9 +154,6 @@ class ComponentThemeData {
final SkillCardComponent? skillCard;
$SkillCardComponentCWProxy get skillCardComponent =>
_get(skillCard, skillCard?.copyWith);
final PricingCardComponent? pricingCard;
$PricingCardComponentCWProxy get pricingCardComponent =>
_get(pricingCard, pricingCard?.copyWith);
// Rich Text
final RichTextBuilderComponent? richTextBuilder;
@@ -41,8 +41,6 @@ abstract class _$ComponentThemeDataCWProxy {
ComponentThemeData skillCard(SkillCardComponent? skillCard);
ComponentThemeData pricingCard(PricingCardComponent? pricingCard);
ComponentThemeData floatingActionButton(
FloatingActionButtonComponent? floatingActionButton);
@@ -68,7 +66,6 @@ abstract class _$ComponentThemeDataCWProxy {
PortfolioCardComponent? portfolioCard,
QuoteCardComponent? quoteCard,
SkillCardComponent? skillCard,
PricingCardComponent? pricingCard,
FloatingActionButtonComponent? floatingActionButton,
});
}
@@ -143,10 +140,6 @@ class _$ComponentThemeDataCWProxyImpl implements _$ComponentThemeDataCWProxy {
ComponentThemeData skillCard(SkillCardComponent? skillCard) =>
this(skillCard: skillCard);
@override
ComponentThemeData pricingCard(PricingCardComponent? pricingCard) =>
this(pricingCard: pricingCard);
@override
ComponentThemeData floatingActionButton(
FloatingActionButtonComponent? floatingActionButton) =>
@@ -176,7 +169,6 @@ class _$ComponentThemeDataCWProxyImpl implements _$ComponentThemeDataCWProxy {
Object? portfolioCard = const $CopyWithPlaceholder(),
Object? quoteCard = const $CopyWithPlaceholder(),
Object? skillCard = const $CopyWithPlaceholder(),
Object? pricingCard = const $CopyWithPlaceholder(),
Object? floatingActionButton = const $CopyWithPlaceholder(),
}) {
return ComponentThemeData(
@@ -240,10 +232,6 @@ class _$ComponentThemeDataCWProxyImpl implements _$ComponentThemeDataCWProxy {
? _value.skillCard
// ignore: cast_nullable_to_non_nullable
: skillCard as SkillCardComponent?,
pricingCard: pricingCard == const $CopyWithPlaceholder()
? _value.pricingCard
// ignore: cast_nullable_to_non_nullable
: pricingCard as PricingCardComponent?,
floatingActionButton: floatingActionButton == const $CopyWithPlaceholder()
? _value.floatingActionButton
// ignore: cast_nullable_to_non_nullable
+2 -2
View File
@@ -1,12 +1,12 @@
name: wyatt_ui_components
description: Components that can be implemented in any application with copy constructor.
repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_components
version: 0.2.2
version: 0.2.1
publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
environment:
sdk: ">=2.19.0 <3.0.0"
sdk: ">=2.17.0 <3.0.0"
dependencies:
flutter: { sdk: flutter }
-7
View File
@@ -1,10 +1,3 @@
## 3.1.0
- **FIX**: upgrade to flutter 3.10.
- **FEAT**(ui): export pricing card.
- **FEAT**(ui): proxy some rich text parameters.
- **FEAT**(ui): tweak some values.
## 3.0.1
- Update a dependency to the latest release.
@@ -40,10 +40,10 @@ class Buttons extends DemoPage {
),
),
const Gap(20),
const Row(
Row(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
children: const [
FlatButtons(),
Gap(20),
SymbolButtons(),
@@ -30,10 +30,10 @@ class QuoteCards extends StatelessWidget {
style: Theme.of(context).textTheme.titleMedium,
),
const Gap(20),
const Row(
Row(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
children: const [
QuoteCard(
quote:
TextWrapper('Cupidatat reprehenderit aliqua eiusmod Lorem. '
@@ -43,9 +43,9 @@ class Loaders extends DemoPage {
radius: 57,
),
const Gap(20),
const Row(
Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
children: const [
Loader(
stroke: 5,
),
+1 -2
View File
@@ -43,8 +43,7 @@ class App extends StatelessWidget {
@override
Widget build(BuildContext context) {
final brightness =
WidgetsBinding.instance.platformDispatcher.platformBrightness;
final brightness = WidgetsBinding.instance.window.platformBrightness;
return BlocProvider(
create: (context) => AppModeCubit(
theme: defaultTheme,
+1 -1
View File
@@ -20,7 +20,7 @@ dependencies:
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
dev_dependencies:
flutter_test: { sdk: flutter }
@@ -117,9 +117,9 @@ class PricingCardTitles extends StatelessWidget {
WidgetSpan(
child: Transform.translate(
offset: const Offset(5, -15),
child: Text(
child: const Text(
'* ',
style: titleStyle?.copyWith(fontSize: 18),
style: TextStyle(fontSize: 18),
),
),
),
@@ -29,17 +29,6 @@ class RichTextBuilder extends RichTextBuilderComponent
super.parser,
super.defaultStyle,
super.styles,
super.strutStyle,
super.textAlign,
super.textDirection,
super.locale,
super.softWrap,
super.overflow,
super.textScaleFactor,
super.maxLines,
super.semanticsLabel,
super.textWidthBasis,
super.selectionColor,
super.key,
});
@@ -102,17 +91,6 @@ class RichTextBuilder extends RichTextBuilderComponent
TextSpan(children: [root.toInlineSpan(customParser)]),
textHeightBehavior:
const TextHeightBehavior(applyHeightToLastDescent: false),
strutStyle: super.strutStyle,
textAlign: super.textAlign,
textDirection: super.textDirection,
locale: super.locale,
softWrap: super.softWrap,
overflow: super.overflow,
textScaleFactor: super.textScaleFactor,
maxLines: super.maxLines,
semanticsLabel: super.semanticsLabel,
textWidthBasis: super.textWidthBasis,
selectionColor: super.selectionColor,
);
}
}
@@ -20,34 +20,6 @@ class $RichTextBuilderCWProxyImpl implements $RichTextBuilderComponentCWProxy {
RichTextBuilder styles(Map<String, TextStyle>? styles) =>
this(styles: styles);
@override
RichTextBuilder strutStyle(StrutStyle? strutStyle) =>
this(strutStyle: strutStyle);
@override
RichTextBuilder textAlign(TextAlign? textAlign) => this(textAlign: textAlign);
@override
RichTextBuilder textDirection(TextDirection? textDirection) =>
this(textDirection: textDirection);
@override
RichTextBuilder locale(Locale? locale) => this(locale: locale);
@override
RichTextBuilder softWrap(bool? softWrap) => this(softWrap: softWrap);
@override
RichTextBuilder overflow(TextOverflow? overflow) => this(overflow: overflow);
@override
RichTextBuilder textScaleFactor(double? textScaleFactor) =>
this(textScaleFactor: textScaleFactor);
@override
RichTextBuilder maxLines(int? maxLines) => this(maxLines: maxLines);
@override
RichTextBuilder semanticsLabel(String? semanticsLabel) =>
this(semanticsLabel: semanticsLabel);
@override
RichTextBuilder textWidthBasis(TextWidthBasis? textWidthBasis) =>
this(textWidthBasis: textWidthBasis);
@override
RichTextBuilder selectionColor(Color? selectionColor) =>
this(selectionColor: selectionColor);
@override
RichTextBuilder key(Key? key) => this(key: key);
@override
RichTextBuilder call({
@@ -55,17 +27,6 @@ class $RichTextBuilderCWProxyImpl implements $RichTextBuilderComponentCWProxy {
RichTextParser? parser,
TextStyle? defaultStyle,
Map<String, TextStyle>? styles,
StrutStyle? strutStyle,
TextAlign? textAlign,
TextDirection? textDirection,
Locale? locale,
bool? softWrap,
TextOverflow? overflow,
double? textScaleFactor,
int? maxLines,
String? semanticsLabel,
TextWidthBasis? textWidthBasis,
Color? selectionColor,
Key? key,
}) =>
RichTextBuilder(
@@ -73,17 +34,6 @@ class $RichTextBuilderCWProxyImpl implements $RichTextBuilderComponentCWProxy {
parser: parser ?? _value.parser,
defaultStyle: defaultStyle ?? _value.defaultStyle,
styles: styles ?? _value.styles,
strutStyle: strutStyle ?? _value.strutStyle,
textAlign: textAlign ?? _value.textAlign,
textDirection: textDirection ?? _value.textDirection,
locale: locale ?? _value.locale,
softWrap: softWrap ?? _value.softWrap,
overflow: overflow ?? _value.overflow,
textScaleFactor: textScaleFactor ?? _value.textScaleFactor,
maxLines: maxLines ?? _value.maxLines,
semanticsLabel: semanticsLabel ?? _value.semanticsLabel,
textWidthBasis: textWidthBasis ?? _value.textWidthBasis,
selectionColor: selectionColor ?? _value.selectionColor,
key: key ?? _value.key,
);
}
@@ -77,7 +77,7 @@ class CardThemeExtensionImpl extends CardThemeExtension {
radius: const BorderRadius.all(Radius.circular(12)),
padding: const EdgeInsets.all(25),
stroke: 1,
backgroundColors: MultiColor.single(WyattColors.light.withOpacity(0.04)),
backgroundColors: WyattColors.grayBgOpacityGradient,
borderColors: WyattColors.grayGradient,
titleStyle: theme.textTheme.titleLarge?.copyWith(
fontSize: 26,
@@ -17,7 +17,6 @@
import 'package:flutter/material.dart';
import 'package:wyatt_ui_components/wyatt_ui_components.dart';
import 'package:wyatt_ui_kit/src/components/gradients/gradient_text_style.dart';
import 'package:wyatt_ui_kit/src/core/design_system/colors.dart';
class RichTextBuilderThemeExtensionImpl extends RichTextBuilderThemeExtension {
const RichTextBuilderThemeExtensionImpl({
@@ -53,131 +52,54 @@ class RichTextBuilderThemeExtensionImpl extends RichTextBuilderThemeExtension {
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.blueGradient,
),
'gradient-dark-blue': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.darkBlueGradient,
),
'gradient-gray': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.grayGradient,
),
'gradient-light-gray': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.lightGrayGradient,
),
'gradient-light': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.lightGradient,
),
'gradient-purple': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.purpleGradient,
const MultiColor([
Color(0xFF3C97FB),
Color(0xFF436EF4),
]),
),
'gradient-red': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.redGradient,
),
'gradient-yellow': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.yellowGradient,
const MultiColor([
Color(0xFFF44464),
Color(0xFFF44464),
]),
),
'gradient-green': GradientTextStyle.from(
theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
height: 1.8,
),
WyattColors.greenGradient,
const MultiColor([
Color(0xFF00D16C),
Color(0xFF00D16C),
]),
),
'blue': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.blue1,
color: const Color(0xFF3C97FB),
height: 1.8,
) ??
const TextStyle(
color: WyattColors.blue1,
),
'dark-blue': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.darkBlue1,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.darkBlue1,
),
'gray': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.gray1,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.gray1,
),
'green': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.green1,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.green1,
),
'light': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.light,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.light,
),
'light-gray': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.lightGray1,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.lightGray1,
),
'purple': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.purple1,
height: 1.8,
) ??
const TextStyle(
color: WyattColors.purple1,
color: Color(0xFF3C97FB),
),
'red': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.red1,
color: const Color(0xFFF44464),
height: 1.8,
) ??
const TextStyle(color: WyattColors.red1),
'yellow': theme.textTheme.bodyMedium?.copyWith(
const TextStyle(
color: Color(0xFFF44464),
),
'green': theme.textTheme.bodyMedium?.copyWith(
fontWeight: FontWeight.w600,
color: WyattColors.yellow1,
color: const Color(0xFF00D16C),
height: 1.8,
) ??
const TextStyle(color: WyattColors.yellow1),
const TextStyle(
color: Color(0xFF00D16C),
),
};
}
@@ -35,7 +35,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
normalStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(221, 224, 227, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(55, 65, 81, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -45,7 +45,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
focusedStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(60, 125, 251, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(55, 65, 81, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -55,7 +55,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
invalidStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(244, 68, 100, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(244, 68, 100, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -65,7 +65,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
disabledStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(229, 231, 235, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(156, 163, 175, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -81,7 +81,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
normalStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(96, 101, 106, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(204, 204, 204, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -91,7 +91,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
focusedStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(60, 125, 251, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(204, 204, 204, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -101,7 +101,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
invalidStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(244, 68, 100, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(244, 68, 100, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -111,7 +111,7 @@ class TextInputThemeExtensionImpl extends TextInputThemeExtension {
disabledStyle: TextInputStyle(
radius: BorderRadius.circular(12),
borderColors: const Color.fromRGBO(96, 101, 106, 1),
labelStyle: theme.textTheme.labelMedium?.copyWith(
labelStyle: theme.textTheme.labelLarge?.copyWith(
color: const Color.fromRGBO(96, 101, 106, 1),
),
inputStyle: theme.textTheme.bodyMedium?.copyWith(
@@ -39,6 +39,5 @@ abstract class WyattComponentThemeData {
portfolioCard: PortfolioCard(),
quoteCard: QuoteCard(),
skillCard: SkillCard(),
pricingCard: PricingCard(),
);
}
+2 -2
View File
@@ -1,7 +1,7 @@
name: wyatt_ui_kit
description: UIKit and Design System used in Wyatt Studio.
repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_kit
version: 3.1.0
version: 3.0.1
publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
@@ -25,7 +25,7 @@ dependencies:
version: ^2.0.1
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
dev_dependencies:
build_runner: ^2.3.3
-4
View File
@@ -1,7 +1,3 @@
## 0.1.1
- **FEAT**(ui_layout-bloc_layout): proxy scaffold fields.
## 0.1.0+1
- Update a dependency to the latest release.
@@ -36,7 +36,7 @@ dependencies:
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
wyatt_component_copy_with_extension:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^2.0.1
@@ -113,6 +113,7 @@ class TopAppBarLayout extends TopBarLayout<TopAppBarComponent> {
required super.body,
super.custom,
super.height,
super.scaffoldFieldsWrapper,
super.key,
});
@@ -133,6 +134,7 @@ class TopNavigationBarLayout extends TopBarLayout<TopNavigationBarComponent> {
required super.body,
super.custom,
super.height,
super.scaffoldFieldsWrapper,
super.key,
});
+2 -2
View File
@@ -1,7 +1,7 @@
name: wyatt_ui_layout
description: Main layouts to help you build your application views.
repository: https://git.wyatt-studio.fr/Wyatt-FOSS/wyatt-packages/src/branch/master/packages/wyatt_ui_layout
version: 0.1.1
version: 0.1.0+1
publish_to: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
@@ -14,7 +14,7 @@ dependencies:
wyatt_ui_components:
hosted: https://git.wyatt-studio.fr/api/packages/Wyatt-FOSS/pub
version: ^0.2.2
version: ^0.2.1
dev_dependencies:
flutter_test: { sdk: flutter }