CkShareButton constructor
const
CkShareButton({
- Key? key,
- required String title,
- required String deepLinkUrl,
- String? imageUrl,
- ByteData? byteImage,
- Widget? child,
- Widget builder(
- BuildContext context,
- bool isLoading
- 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,
Implementation
const CkShareButton({
super.key,
required this.title,
required this.deepLinkUrl,
this.imageUrl,
this.byteImage,
this.child,
this.builder,
this.loaderStyle = CkShareLoaderStyle.adaptiveEdge,
this.shape,
this.borderRadius,
this.strokeWidth = 2.5,
this.strokeLengthFactor = 0.3,
this.loaderColor,
this.trackColor,
this.paddingOffset = 0.0,
this.animationDuration = const Duration(milliseconds: 1100),
this.customLoader,
this.onTap,
this.onShareStart,
this.onShareReady,
this.onShareSuccess,
this.onShareError,
}) : assert(
child != null || builder != null,
'Either child or builder must be provided to CkShareButton.',
),
assert(
imageUrl != null || byteImage != null,
'Either imageUrl or byteImage must be provided to CkShareButton.',
);