import type { VehicleType } from '../types/user';
import type { RideStatus } from '../types/ride';
import { colors } from '../theme';
// ─── App Identity ────────────────────────────────────────────────────────────
export const APP_NAME = 'Antaram';
export const APP_TAGLINE = 'Share rides, save the planet';
// ─── Default Location (Bangalore, India) ─────────────────────────────────────
export const DEFAULT_LOCATION = {
lat: 12.9716,
lng: 77.5946,
address: 'Bangalore, Karnataka, India',
} as const;
// ─── Map Defaults ────────────────────────────────────────────────────────────
export const MAP_TILE_URL = 'https://tile.openstreetmap.org/{z}/{x}/{y}.png';
export const MAP_TILE_ATTRIBUTION =
'© OpenStreetMap contributors';
export const MAP_DEFAULT_ZOOM = 14;
export const MAP_MIN_ZOOM = 4;
export const MAP_MAX_ZOOM = 19;
export const MAP_INITIAL_DELTA = 0.01; // ~1km lat/lng span
// ─── Vehicle Types ───────────────────────────────────────────────────────────
export interface VehicleTypeInfo {
type: VehicleType;
label: string;
icon: string;
emoji: string;
seats: number;
baseFare: number;
perKmRate: number;
}
export const VEHICLE_TYPES: VehicleTypeInfo[] = [
{
type: 'bike',
label: 'Bike',
icon: 'motorbike',
emoji: '🏍️',
seats: 1,
baseFare: 10,
perKmRate: 8,
},
{
type: 'auto',
label: 'Auto',
icon: 'car-side',
emoji: '🛺',
seats: 3,
baseFare: 20,
perKmRate: 12,
},
{
type: 'car',
label: 'Car',
icon: 'car',
emoji: '🚗',
seats: 4,
baseFare: 30,
perKmRate: 15,
},
];
// ─── Ride Status Colors ──────────────────────────────────────────────────────
export const RIDE_STATUS_COLORS: Record = {
draft: colors.neutral[400],
active: colors.primary[500],
matched: colors.secondary[500],
ongoing: colors.tertiary[500],
completed: colors.success,
cancelled: colors.error,
};
export const RIDE_STATUS_LABELS: Record = {
draft: 'Draft',
active: 'Active',
matched: 'Matched',
ongoing: 'On Ride',
completed: 'Completed',
cancelled: 'Cancelled',
};
// ─── Search & History Limits ─────────────────────────────────────────────────
export const MAX_SEARCH_HISTORY = 20;
export const MAX_SAVED_LOCATIONS = 30;
export const MAX_FRIEND_REQUESTS = 50;
// ─── SOS ─────────────────────────────────────────────────────────────────────
export const SOS_HOLD_DURATION = 3000; // ms to hold SOS button
export const SOS_CONTACTS_LIMIT = 5;
// ─── Notification Types ──────────────────────────────────────────────────────
export type NotificationType =
| 'ride_matched'
| 'ride_cancelled'
| 'message'
| 'friend_request'
| 'friend_accepted'
| 'ride_reminder'
| 'system'
| 'sos_alert';
export interface NotificationTypeInfo {
type: NotificationType;
label: string;
icon: string;
channel: string;
}
export const NOTIFICATION_TYPES: NotificationTypeInfo[] = [
{
type: 'ride_matched',
label: 'Ride Matched',
icon: 'handshake',
channel: 'rides',
},
{
type: 'ride_cancelled',
label: 'Ride Cancelled',
icon: 'close-circle',
channel: 'rides',
},
{
type: 'message',
label: 'New Message',
icon: 'chat',
channel: 'messages',
},
{
type: 'friend_request',
label: 'Friend Request',
icon: 'account-plus',
channel: 'social',
},
{
type: 'friend_accepted',
label: 'Friend Accepted',
icon: 'account-check',
channel: 'social',
},
{
type: 'ride_reminder',
label: 'Ride Reminder',
icon: 'bell-ring',
channel: 'rides',
},
{
type: 'system',
label: 'System',
icon: 'information',
channel: 'system',
},
{
type: 'sos_alert',
label: 'SOS Alert',
icon: 'alert',
channel: 'sos',
},
];
// ─── Misc ────────────────────────────────────────────────────────────────────
export const LOCATION_UPDATE_INTERVAL = 5000; // 5 seconds
export const LOCATION_UPDATE_DISTANCE = 10; // 10 meters
export const RATING_MIN = 1;
export const RATING_MAX = 5;
export const RATING_DEFAULT = 0;
export const MAX_SEATS_AVAILABLE = 4;
export const FARE_ESTIMATE_BUFFER = 0.15; // ±15% variance for estimates