<commit_before>import * as React from 'react';

import { TypeAttributes, StandardProps } from '../@types/common';

/**
 * Props that FormControl passes to its accepter
 */
export interface FormControlAccepterProps<ValueType = any> {
  /** The name of form-control */
  name?: string;

  defaultValue?: ValueType;

  /** Value */
  value?: ValueType;

  /** Callback fired when data changing */
  onChange?(value: ValueType, event: React.SyntheticEvent<HTMLElement>): void;

  /** Whether form-control readonly */
  readOnly?: boolean;

  onBlur?(event: React.SyntheticEvent<any>): void;
}

/**
 * Props that <FormControl> itself takes
 */
export type FormControlProps<P = {}, ValueType = any> = StandardProps & {
  /** Proxied components */
  accepter?: React.ComponentType<P & FormControlAccepterProps<ValueType>>;

  /** The name of form-control */
  name?: string;

  /** Value */
  value?: ValueType;

  /** Callback fired when data changing */
  onChange?(value: ValueType, event: React.SyntheticEvent<HTMLElement>): void;

  /** The data validation trigger type, and it wiill overrides the setting on <Form> */<commit_msg>fix: support html tag in accepter (#1106)<commit_after>import * as React from 'react';

import { TypeAttributes, StandardProps } from '../@types/common';

/**
 * Props that FormControl passes to its accepter
 */
export interface FormControlAccepterProps<ValueType = any> {
  /** The name of form-control */
  name?: string;

  defaultValue?: ValueType;

  /** Value */
  value?: ValueType;

  /** Callback fired when data changing */
  onChange?(value: ValueType, event: React.SyntheticEvent<HTMLElement>): void;

  /** Whether form-control readonly */
  readOnly?: boolean;

  onBlur?(event: React.SyntheticEvent<any>): void;
}

/**
 * Props that <FormControl> itself takes
 */
export type FormControlProps<P = {}, ValueType = any> = StandardProps & {
  /** Proxied components */
  accepter?: React.ElementType<P & FormControlAccepterProps<ValueType>>;

  /** The name of form-control */
  name?: string;

  /** Value */
  value?: ValueType;

  /** Callback fired when data changing */
  onChange?(value: ValueType, event: React.SyntheticEvent<HTMLElement>): void;

  /** The data validation trigger type, and it wiill overrides the setting on <Form> */
{'fraction_non_alphanumeric': 0.13847502191060473, 'fraction_numerical': 0.0017528483786152498, 'mean_word_length': 4.0846325167037865, 'pattern_counts': {'":': 0, '<': 21, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6624416', 'n_tokens_mistral': 694, 'n_tokens_neox': 677, 'n_words': 202}