import { SemanticType } from '../Semantics.js';
/**
 * Type guard to check if a semantic is a Phone semantic.
 * @param semantic - The semantic to check
 * @returns True if the semantic is a Phone semantic
 */
export const isPhoneSemantic = (semantic) => {
    return semantic.id === SemanticType.Phone;
};
/**
 * Helper function to create a Phone semantic with configuration.
 * @param config - Configuration options for the phone semantic
 * @returns AppliedPhoneSemantic with the specified configuration
 */
export const createPhoneSemantic = (config = {}) => {
    const mergedConfig = {
        ...DEFAULT_PHONE_CONFIG,
        ...config,
    };
    if (config.metadata) {
        mergedConfig.metadata = { ...config.metadata };
    }
    return {
        id: SemanticType.Phone,
        config: mergedConfig,
    };
};
/**
 * Default configuration for Phone semantic.
 * Uses international format with country code required and SMS verification.
 */
export const DEFAULT_PHONE_CONFIG = {
    requireCountryCode: true,
    format: 'international',
    allowExtension: false,
    requireVerification: false,
    verificationMethod: 'sms',
};
//# sourceMappingURL=Phone.js.map