department-of-veterans-affairs/vets-website

View on GitHub
src/applications/simple-forms/form-upload/pages/phoneNumberAndEmail.jsx

Summary

Maintainability
A
1 hr
Test Coverage
import {
  emailSchema,
  emailToSendNotificationsUI,
  phoneSchema,
  phoneUI,
  titleUI,
} from 'platform/forms-system/src/js/web-component-patterns';

/** @type {PageSchema} */
export const phoneNumberAndEmailPage = {
  uiSchema: {
    ...titleUI('Phone and email address'),
    phoneNumber: phoneUI(),
    email: emailToSendNotificationsUI(),
  },
  schema: {
    type: 'object',
    properties: {
      phoneNumber: phoneSchema,
      email: emailSchema,
    },
    required: ['email'],
  },
};