export type SettingSection = 'system' | 'social' | 'marketplace' | 'hr' | 'homepage';

export type MarketplacePlatform = 'tiktok_shop' | 'shopee';

export type MarketplaceFeeScope = 'product' | 'transaction';

export type MarketplaceFeeValueType = 'flat' | 'percent';

export type MarketplaceFeeRule = {
    scope: MarketplaceFeeScope;
    value_type: MarketplaceFeeValueType;
    value: number;
};

export type SystemSettingsData = {
    app_name: string;
    about_app: string;
    email: string;
    phone: string;
    address: string;
    logo_url: string;
    favicon_url: string | null;
    login_cover_url: string;
};

export type SocialMediaSettingsData = {
    instagram_url: string | null;
    facebook_url: string | null;
    tiktok_url: string | null;
};

export type MarketplaceSettingsData = {
    tiktok_shop_platform_commission: MarketplaceFeeRule;
    tiktok_shop_logistics_service_fee: MarketplaceFeeRule;
    tiktok_shop_dynamic_commission: MarketplaceFeeRule;
    tiktok_shop_order_processing_fee: MarketplaceFeeRule;
    tiktok_shop_affiliate: MarketplaceFeeRule;
    tiktok_shop_pre_order_service_fee: MarketplaceFeeRule;
    shopee_admin_fee: MarketplaceFeeRule;
    shopee_program_fee: MarketplaceFeeRule;
    shopee_shipping_savings: MarketplaceFeeRule;
    shopee_premium: MarketplaceFeeRule;
    shopee_service_fee: MarketplaceFeeRule;
    shopee_order_processing_fee: MarketplaceFeeRule;
    shopee_ams_commission_fee: MarketplaceFeeRule;
    shopee_pre_order: MarketplaceFeeRule;
    shopee_live_extra: MarketplaceFeeRule;
};

export type HrSettingsData = {
    scheduled_check_in_time: string;
    scheduled_check_out_time: string;
    late_penalty_amount: number;
    absent_penalty_amount: number;
};

export type MediaItem = {
    id: number;
    url: string;
    thumb_url: string;
};

export type HomepageSettingsData = {
    hero_image_url: string | null;
    about_image_url: string | null;
    gallery_images: MediaItem[];
};
