[SYNC]
This commit is contained in:
@@ -10,7 +10,6 @@ import 'package:flutter/material.dart';
|
||||
import 'src/icon_button.dart';
|
||||
import 'src/link_button.dart';
|
||||
import 'src/state_button.dart';
|
||||
//
|
||||
import 'src/enums/enums.exports.dart';
|
||||
import 'src/models/models.exports.dart';
|
||||
//s1 Exports
|
||||
@@ -21,74 +20,56 @@ export 'src/models/models.exports.dart';
|
||||
class AstromicButtons {
|
||||
/// an `AstromicStateButton` is a button whoose style is affected by it's state.
|
||||
static Widget state({
|
||||
//
|
||||
void Function(VoidCallback start, VoidCallback stop)? onTap,
|
||||
Function(VoidCallback start, VoidCallback stop)? onHold,
|
||||
//
|
||||
AstromicButtonConfiguration? configuration,
|
||||
//
|
||||
AstromicSizingStrategy? widthSizingStrategy,
|
||||
AstromicSizingStrategy? heightSizingStrategy,
|
||||
InteractiveInkFeatureFactory? splashFactory,
|
||||
required AstromicButtonStyle Function(bool isEnabled, bool isHighlighted, bool isLoading) style,
|
||||
//
|
||||
Widget? loadingContent,
|
||||
required Widget Function(bool isEnabled, bool isHighlighted) content,
|
||||
}) =>
|
||||
AstromicStateButton(
|
||||
onTap: onTap,
|
||||
onHold: onHold,
|
||||
//
|
||||
configuration: configuration,
|
||||
//
|
||||
widthSizingStrategy: widthSizingStrategy,
|
||||
heightSizingStrategy: heightSizingStrategy,
|
||||
style: style,
|
||||
//
|
||||
loadingContent: loadingContent,
|
||||
content: content,
|
||||
);
|
||||
|
||||
/// an `AstromicIconButton` is a button specifically for mapping to an IconButton.
|
||||
static Widget icon({
|
||||
//
|
||||
void Function(VoidCallback start, VoidCallback stop)? onTap,
|
||||
Function(VoidCallback start, VoidCallback stop)? onHold,
|
||||
//
|
||||
AstromicButtonConfiguration? configuration,
|
||||
//
|
||||
bool? isCircular,
|
||||
InteractiveInkFeatureFactory? splashFactory,
|
||||
required AstromicButtonStyle Function(bool isEnabled, bool isHighlighted, bool isLoading) style,
|
||||
//
|
||||
Widget? loadingContent,
|
||||
required Widget Function(bool isEnabled, bool isHighlighted) icon,
|
||||
}) =>
|
||||
AstromicIconButton(
|
||||
onTap: onTap,
|
||||
onHold: onHold,
|
||||
//
|
||||
configuration: configuration,
|
||||
//
|
||||
isCircular: isCircular ?? true,
|
||||
style: style,
|
||||
//
|
||||
loadingContent: loadingContent,
|
||||
icon: icon,
|
||||
);
|
||||
|
||||
/// an `AstromicLinkButton` is a button specifically for mapping to LinkButton.
|
||||
static Widget link({
|
||||
//
|
||||
VoidCallback? onTap,
|
||||
VoidCallback? onHold,
|
||||
//
|
||||
AstromicButtonConfiguration? configuration,
|
||||
//
|
||||
bool Function(bool isEnabled)? isUnderlined,
|
||||
EdgeInsetsGeometry? contentPadding,
|
||||
TextStyle Function(bool isEnabled)? style,
|
||||
//
|
||||
String? text,
|
||||
Widget? textWidget,
|
||||
Widget? prefix,
|
||||
@@ -97,13 +78,10 @@ class AstromicButtons {
|
||||
AstromicLinkButton(
|
||||
onTap: onTap,
|
||||
onHold: onHold,
|
||||
//
|
||||
configuration: configuration,
|
||||
//
|
||||
isUnderlined: isUnderlined ?? (e) => e,
|
||||
contentPadding: contentPadding,
|
||||
style: style,
|
||||
//
|
||||
text: text,
|
||||
textWidget: textWidget,
|
||||
prefix: prefix,
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
//s2 Core Package Imports
|
||||
import 'package:flutter/material.dart';
|
||||
//s2 1st-party Package Imports
|
||||
import '../../../Dependencies/gradient_border/gradient_borders.dart';
|
||||
import '../../../dependencies/gradient_border/gradient_borders.dart';
|
||||
//s2 3rd-party Package Imports
|
||||
//s2 Dependancies Imports
|
||||
//s3 Routes
|
||||
|
||||
@@ -1 +1 @@
|
||||
export './sizing_strategy.enum.dart';
|
||||
export 'sizing_strategy.enum.dart';
|
||||
|
||||
Reference in New Issue
Block a user