department-of-veterans-affairs/vets-website

View on GitHub
src/applications/pensions/config/chapters/03-health-and-employment-information/nursingHome.js

Summary

Maintainability
A
2 hrs
Test Coverage
import {
  titleUI,
  yesNoUI,
} from 'platform/forms-system/src/js/web-component-patterns';
import fullSchemaPensions from 'vets-json-schema/dist/21P-527EZ-schema.json';

const { nursingHome } = fullSchemaPensions.properties;

/** @type {PageSchema} */
export default {
  title: 'Nursing home information',
  path: 'medical/history/nursing-home',
  uiSchema: {
    ...titleUI('Nursing home information'),
    nursingHome: yesNoUI({
      title: 'Do you live in a nursing home?',
      classNames: 'vads-u-margin-bottom--2',
    }),
  },
  schema: {
    type: 'object',
    required: ['nursingHome'],
    properties: {
      nursingHome,
    },
  },
};