build method

  1. @override
Widget build(
  1. BuildContext context
)
override

//////////// ////////////

Implementation

// II.C - Build Method
///////////////
@override
Widget build(BuildContext context) {
  return Column(
    mainAxisSize: MainAxisSize.min,
    children: [
      // Weather Toggle Button
      ControlButton(
        onTap: onWeatherToggle,
        isActive: weatherVisible,
        child: Stack(
          children: [
            Icon(weatherVisible ? Icons.cloud : Icons.cloud_outlined),
            if (weatherIntensity != null && weatherIntensity! > 0.5)
              Positioned(
                right: 0,
                bottom: 0,
                child: Container(
                  width: 8,
                  height: 8,
                  decoration: const BoxDecoration(
                    color: RALIColors.primary,
                    shape: BoxShape.circle,
                  ),
                ),
              ),
          ],
        ),
      ),
      const SizedBox(height: RALISpacing.mapControlGap),

      // Center-On-Location Button
      ControlButton(
        onTap: onLocationPressed,
        child: const Icon(Icons.my_location),
      ),
      const SizedBox(height: RALISpacing.mapControlGap),

      // Settings Button (if available)
      if (onSettingsPressed != null)
        ControlButton(
          onTap: onSettingsPressed!,
          child: const Icon(Icons.settings),
        ),
    ],
  );
}