button static method

Widget button({
  1. Key? key,
  2. required String title,
  3. required String deepLinkUrl,
  4. String? imageUrl,
  5. ByteData? byteImage,
  6. required Widget child,
  7. CkShareLoaderStyle loaderStyle = CkShareLoaderStyle.adaptiveEdge,
  8. BoxShape? shape,
  9. BorderRadius? borderRadius,
  10. double strokeWidth = 2.5,
  11. double strokeLengthFactor = 0.3,
  12. Color? loaderColor,
  13. Color? trackColor,
  14. double paddingOffset = 0.0,
  15. Duration animationDuration = const Duration(milliseconds: 1100),
  16. Widget? customLoader,
  17. VoidCallback? onTap,
  18. VoidCallback? onShareStart,
  19. VoidCallback? onShareReady,
  20. VoidCallback? onShareSuccess,
  21. void onShareError(
    1. Object error
    )?,
})

Creates a CkShareButton wrapping a child with an adaptive edge-tracing loader.

Implementation

static Widget button({
  Key? key,
  required String title,
  required String deepLinkUrl,
  String? imageUrl,
  ByteData? byteImage,
  required Widget child,
  CkShareLoaderStyle loaderStyle = CkShareLoaderStyle.adaptiveEdge,
  BoxShape? shape,
  BorderRadius? borderRadius,
  double strokeWidth = 2.5,
  double strokeLengthFactor = 0.3,
  Color? loaderColor,
  Color? trackColor,
  double paddingOffset = 0.0,
  Duration animationDuration = const Duration(milliseconds: 1100),
  Widget? customLoader,
  VoidCallback? onTap,
  VoidCallback? onShareStart,
  VoidCallback? onShareReady,
  VoidCallback? onShareSuccess,
  void Function(Object error)? onShareError,
}) => CkShareButton(
  key: key,
  title: title,
  deepLinkUrl: deepLinkUrl,
  imageUrl: imageUrl,
  byteImage: byteImage,
  loaderStyle: loaderStyle,
  shape: shape,
  borderRadius: borderRadius,
  strokeWidth: strokeWidth,
  strokeLengthFactor: strokeLengthFactor,
  loaderColor: loaderColor,
  trackColor: trackColor,
  paddingOffset: paddingOffset,
  animationDuration: animationDuration,
  customLoader: customLoader,
  onTap: onTap,
  onShareStart: onShareStart,
  onShareReady: onShareReady,
  onShareSuccess: onShareSuccess,
  onShareError: onShareError,
  child: child,
);