/*
 * File: SettingsStackNavigator.tsx
 * Description: Stack navigator for settings screens within the Settings module
 * Design & Developed by Tech4Biz Solutions
 * Copyright (c) Spurrin Innovations. All rights reserved.
 */

import React from 'react';
import { createStackNavigator } from '@react-navigation/stack';

// Import settings screens
import { SettingsScreen } from '../screens/SettingsScreen';

// Import navigation types
import { SettingsStackParamList } from './navigationTypes';
import { theme } from '../../../theme';

// Create stack navigator for Settings module
const Stack = createStackNavigator<SettingsStackParamList>();

/**
 * SettingsStackNavigator - Manages navigation between settings screens
 * 
 * This navigator handles the flow between:
 * - SettingsScreen: Main settings screen with profile and preferences
 * - Future screens: Profile edit, security settings, notifications, etc.
 * 
 * Features:
 * - Clean header styling
 * - Smooth transitions between screens
 * - Type-safe navigation parameters
 * - Settings-focused design
 */
const SettingsStackNavigator: React.FC = () => {
  return (
    <Stack.Navigator
      initialRouteName="Settings"
      screenOptions={{
        // Header styling for settings screens
        headerStyle: {
          backgroundColor: '#FFFFFF',
          elevation: 0, // Remove shadow on Android
          shadowOpacity: 0, // Remove shadow on iOS
        },
        headerTitleStyle: {
          fontFamily: theme.typography.fontFamily.medium,
          fontSize: 18,
          color: '#212121',
        },
        headerTintColor: '#2196F3', // Back button and title color
        headerBackTitleVisible: false, // Hide back title on iOS
        cardStyle: {
          backgroundColor: '#FFFFFF',
        },
        // Smooth transitions
        transitionSpec: {
          open: {
            animation: 'timing',
            config: {
              duration: 300,
            },
          },
          close: {
            animation: 'timing',
            config: {
              duration: 300,
            },
          },
        },
      }}
    >
      {/* Settings Screen - Main settings entry point */}
      <Stack.Screen
        name="Settings"
        component={SettingsScreen}
        options={{
          title: 'Settings',
          headerShown: false, // Hide header for main settings screen
        }}
      />
    </Stack.Navigator>
  );
};

export default SettingsStackNavigator;

/*
 * End of File: SettingsStackNavigator.tsx
 * Design & Developed by Tech4Biz Solutions
 * Copyright (c) Spurrin Innovations. All rights reserved.
 */ 