import type { PropertyProps } from '~/components';

export const properties: Record<string, PropertyProps> = {
  TInput: {
    modifier: 'extends',
    type: {
      type: 'union',
      options: [
        {
          type: 'custom',
          name: 'Record',
          generics: ['string', 'unknown'],
        },
        {
          type: 'custom',
          name: 'ArrayLike',
          generics: ['unknown'],
        },
      ],
    },
  },
  TIssue: {
    modifier: 'extends',
    type: {
      type: 'custom',
      name: 'BaseIssue',
      href: '../BaseIssue/',
      generics: ['unknown'],
    },
  },
  TPath: {
    modifier: 'extends',
    type: {
      type: 'custom',
      name: 'RequiredPath',
      href: '../RequiredPath/',
    },
  },
  action: {
    type: {
      type: 'union',
      options: [
        {
          type: 'custom',
          name: 'BaseValidation',
          href: '../BaseValidation/',
          generics: [
            {
              type: 'custom',
              name: 'TInput',
            },
            {
              type: 'custom',
              name: 'TInput',
            },
            {
              type: 'custom',
              name: 'TIssue',
            },
          ],
        },
        {
          type: 'custom',
          name: 'BaseValidationAsync',
          href: '../BaseValidationAsync/',
          generics: [
            {
              type: 'custom',
              name: 'TInput',
            },
            {
              type: 'custom',
              name: 'TInput',
            },
            {
              type: 'custom',
              name: 'TIssue',
            },
          ],
        },
      ],
    },
  },
  path: {
    type: {
      type: 'custom',
      name: 'ValidPath',
      href: '../forward/ValidPath/',
      generics: [
        {
          type: 'custom',
          name: 'TInput',
        },
        {
          type: 'custom',
          name: 'TPath',
        },
      ],
    },
  },
  Action: {
    type: {
      type: 'custom',
      name: 'BaseValidationAsync',
      href: '../BaseValidationAsync/',
      generics: [
        {
          type: 'custom',
          name: 'TInput',
        },
        {
          type: 'custom',
          name: 'TInput',
        },
        {
          type: 'custom',
          name: 'TIssue',
        },
      ],
    },
  },
};
