@mxenabled/rules-engine
Version:
UI for MX's rules engine Dwight
71 lines (70 loc) • 2.58 kB
TypeScript
import { copy } from '../Copy';
import type { CustomInsight, NewCustomInsight } from '../types/CustomInsight';
interface RulesEngineContextTypes {
copy: typeof copy;
customInsights: CustomInsight[];
newCustomInsight: [
NewCustomInsight | null,
React.Dispatch<React.SetStateAction<NewCustomInsight | null>>
];
}
export declare const RulesEngineContext: import("react").Context<RulesEngineContextTypes | null>;
type RulesEngineDataProviderProps = React.PropsWithChildren<{
copy: typeof copy;
customInsights: CustomInsight[];
}>;
export declare const RulesEngineDataProvider: React.FC<RulesEngineDataProviderProps>;
export declare const useDataContext: () => RulesEngineContextTypes;
export declare const useCopy: () => {
activate: string;
active_tab: string;
add_button_button_link_title: string;
add_button_form_control_label_1: string;
add_button_form_control_label_2: string;
add_button_form_label_text: string;
add_button_input_1_helper_text: string;
add_button_input_1_label: string;
add_button_input_2_helper_text: string;
add_button_input_2_label: string;
add_button_post_message_description: string;
add_button_post_message_input_helper_text: string;
add_button_post_message_link_text: string;
add_button_post_message_title: string;
add_button_title: string;
add_button_post_message_input_label: string;
all_tab: string;
back_button: string;
cancel_button: string;
cancel_dialog_title: string;
cancel_message: string;
close_aria_label: string;
conditions_form_placeholder: string;
conditions_step: string;
confirm_step: string;
confirm_summary_placeholder: string;
create_insight_button: string;
create_insight_title: string;
created_on_date: string;
custom_insights_title: string;
customize_form_placeholder: string;
customize_step: string;
disable: string;
disabled_tab: string;
discard_changes_button: string;
finish_button: string;
keep_editing_button: string;
loading_insights: string;
next_button: string;
num_insights_generated: string;
one_insight_generated: string;
pending_tab: string;
preview_card_read_more: string;
preview_card_logo_alt: string;
};
export declare const useCustomInsights: () => CustomInsight[];
interface UseNewCustomInsightReturn {
0: NewCustomInsight | null;
1: React.Dispatch<React.SetStateAction<NewCustomInsight | null>>;
}
export declare const useNewCustomInsight: () => UseNewCustomInsightReturn;
export {};