MotionLoader.social constructor

MotionLoader.social({
  1. Key? key,
  2. required MotionSocialStyle style,
  3. Color? color,
  4. double size = 50.0,
  5. bool glow = true,
})

Social Theme Category: Reels upload circles, streaming pulses & story sweeps.

Implementation

factory MotionLoader.social({
  Key? key,
  required MotionSocialStyle style,
  Color? color,
  double size = 50.0,
  bool glow = true,
}) {
  return MotionLoader._internal(
    key: key,
    color: color,
    size: size,
    builder: (context) {
      final activeColor = color ?? Theme.of(context).primaryColor;
      switch (style) {
        case MotionSocialStyle.reelsUpload:
          return MotionReelsUploadLoader(
            color: activeColor,
            size: size,
            glow: glow,
          );
        case MotionSocialStyle.liveStream:
          return MotionLiveStreamLoader(
            color: activeColor,
            size: size,
          );
        case MotionSocialStyle.storyRing:
          return MotionStoryRingLoader(
            color: activeColor,
            size: size,
          );
      }
    },
  );
}