import {
    type ViewStyle,
    type StyleProp,
    type TextStyle
} from "react-native";

export type CheckBoxDynamicStyleType = {
    displayBehaviourWhileLoading?: CheckBoxDisplayBehaviourWhileLoading;
    inlineSpaces: NCoreUIKit.ActivePalette["inlineSpaces"];
    radiuses: NCoreUIKit.ActivePalette["radiuses"];
    isChecked?: "checked" | "partially" | null;
    spaces: NCoreUIKit.ActivePalette["spaces"];
    colors: NCoreUIKit.ActivePalette["colors"];
    spreadBehaviour?: CheckBoxSpreadBehaviour;
    borders: NCoreUIKit.Borders;
    currentType: CheckBoxTypes;
    isDisabled?: boolean;
    isLoading?: boolean;
    type: CheckBoxType;
    isFlip?: boolean;
};

export type CheckBoxTypes = {
    containerColor: keyof NCoreUIKit.ContainerContentColors;
    indicatorColor: keyof NCoreUIKit.BorderContentColors;
    subTitleColor: keyof NCoreUIKit.TextContentColors;
    borderColor: keyof NCoreUIKit.BorderContentColors;
    titleColor: keyof NCoreUIKit.TextContentColors;
};

export type CheckBoxTypeConstantType = {
    type: CheckBoxType;
};

export type CheckBoxType = "primary" | "danger" | "warning" | "neutral" | "success" | "info";

export type CheckBoxDisplayBehaviourWhileLoading = "none" | "disabled";

export type CheckBoxSpreadBehaviour = "baseline" | "stretch" | "free";

interface ICheckBoxProps {
    displayBehaviourWhileLoading?: CheckBoxDisplayBehaviourWhileLoading;
    subTitleStyle?: StyleProp<TextStyle>[] | StyleProp<TextStyle>;
    titleStyle?: StyleProp<TextStyle>[] | StyleProp<TextStyle>;
    style?: StyleProp<ViewStyle>[] | StyleProp<ViewStyle>;
    customTheme?: {
        gapPropagation?: NCoreUIKit.GapPropagationKey;
        sharpness?: NCoreUIKit.SharpnessKey;
        paletteKey?: NCoreUIKit.PaletteKey;
        themeKey?: NCoreUIKit.ThemeKey;
    };
    customLocalize?: {
        activeLocale?: NCoreUIKit.LocaleKey;
    };
    isChecked?: "checked" | "partially" | null;
    spreadBehaviour?: CheckBoxSpreadBehaviour;
    optionalText?: string;
    isDisabled?: boolean;
    isOptional?: boolean;
    onPress?: () => void;
    isLoading?: boolean;
    type?: CheckBoxType;
    subTitle?: string;
    isFlip?: boolean;
    title?: string;
}
export type {
    ICheckBoxProps as default
};
