diff --git a/VAMobile/documentation/design/Components/Alerts and progress/Snackbar.md b/VAMobile/documentation/design/Components/Alerts and progress/Snackbar.md index 7bd8620b2b7..055ace12bee 100644 --- a/VAMobile/documentation/design/Components/Alerts and progress/Snackbar.md +++ b/VAMobile/documentation/design/Components/Alerts and progress/Snackbar.md @@ -57,5 +57,5 @@ Snackbars provide feedback regarding API interactions at the bottom of the scree - If a screen has bottom navigation, the snackbar should open above the navigation. - There should only ever be one snackbar on the screen. Opening a new snackbar will close the previous snackbar. -### Related +## Related * [Snackbar - Material Design](https://m3.material.io/components/snackbar/overview) diff --git a/VAMobile/documentation/design/Components/Selection and input/Checkbox.md b/VAMobile/documentation/design/Components/Selection and input/Checkbox.md index a90b5f6f822..c57638331d0 100644 --- a/VAMobile/documentation/design/Components/Selection and input/Checkbox.md +++ b/VAMobile/documentation/design/Components/Selection and input/Checkbox.md @@ -47,7 +47,7 @@ Allows users to select one or more items from a list. Checkboxes are an easily u * Refer to the [VA Design System for accessibility considerations](https://design.va.gov/components/form/checkbox#accessibility-considerations) * Screenreaders should announce the name, role, and state of each checkbox. -### Related +## Related * [Checkbox - VA Design System](https://design.va.gov/components/form/checkbox) * [Checkbox - USWDS](https://designsystem.digital.gov/components/checkbox/) * [Checkbox - Material Design](https://m3.material.io/components/checkbox/overview) \ No newline at end of file diff --git a/VAMobile/documentation/design/Components/Typography/Text.md b/VAMobile/documentation/design/Components/Typography/Text.md new file mode 100644 index 00000000000..4c57c965f81 --- /dev/null +++ b/VAMobile/documentation/design/Components/Typography/Text.md @@ -0,0 +1,44 @@ +--- +title: Text +--- + +Text is a typography component for headings, body copy, and display text. + +## Examples + +### Headings +**Open in**: [Storybook](https://department-of-veterans-affairs.github.io/va-mobile-library/?path=/docs/text--heading) | [Figma](https://www.figma.com/design/Zzt8z60hCtdEzXx2GFWghH/%F0%9F%93%90-Component-Library---Design-System---VA-Mobile?node-id=7101-3675&t=iL0TKvx4LGQO6STF-4) + + +### Body +**Open in**: [Storybook](https://department-of-veterans-affairs.github.io/va-mobile-library/?path=/docs/text--body) | [Figma](https://www.figma.com/design/Zzt8z60hCtdEzXx2GFWghH/%F0%9F%93%90-Component-Library---Design-System---VA-Mobile?node-id=7101-3675&t=iL0TKvx4LGQO6STF-4) + + +### Display +**Open in**: [Storybook](https://department-of-veterans-affairs.github.io/va-mobile-library/?path=/docs/text--display) | [Figma](https://www.figma.com/design/Zzt8z60hCtdEzXx2GFWghH/%F0%9F%93%90-Component-Library---Design-System---VA-Mobile?node-id=7101-3675&t=iL0TKvx4LGQO6STF-4) + + +## Usage + +### When to use Text +- To add content to a screen. + +### When to consider something else +- For bulleted or numbered lists, use the Text list component (coming soon). +- For smaller Navigation copy (such as the bottom tab bar), apply the Navigation text style directly to a text box. + +### How this component works +- This component is built using the [composite typography tokens](/va-mobile-app/design/Foundation/Design%20tokens/Typography#text-styles). +- Paragraph spacing is set to the minimum recommended values to align with accessibility guidelines ([WCAG SC 1.4.12](https://www.w3.org/WAI/WCAG22/Understanding/text-spacing.html)). While you can increase the amount of paragraph spacing, you should not decrease without consulting an accessibility specialist. + +### Choosing between variations +There are 9 variations of the Text component. +- Use a Heading variation (large, medium, small, x-small) for headings. +- Use a Body variation (large, medium, small, x-small) for body copy. +- Use the Display variation for larger display text. + +## Code usage +[Open Storybook](https://department-of-veterans-affairs.github.io/va-mobile-library/?path=/docs/text--docs) + +## Related +- Text list (coming soon) \ No newline at end of file diff --git a/VAMobile/documentation/design/Foundation/Design tokens/Typography.md b/VAMobile/documentation/design/Foundation/Design tokens/Typography.md new file mode 100644 index 00000000000..d31bd87cfb1 --- /dev/null +++ b/VAMobile/documentation/design/Foundation/Design tokens/Typography.md @@ -0,0 +1,46 @@ +--- +title: Typography +sidebar_position: 4 +--- + +# Typography + +Typographical selections intended to meet the highest standards of usability and accessibility, while setting a consistent look and feel in order to convey credibility. + +## Typography tokens + +Typography tokens define each property of a text style. They include font family, style, size, line height, and letter spacing. Math is used to calculate values for size and line height. + +- The base font size is 16. Additional sizes are created using a scale of 1.125 +- The default line height is set to 1.5x the font size. For headings, the line height is set to 1.2x. Line heights follow [accessibility best practices](https://department-of-veterans-affairs.github.io/va-mobile-app/docs/QA/QualityAssuranceProcess/Accessibility/a11y-checklist-ux-designers) and should not be decreased without consulting an accessibility specialist. + +### Primitive + + +### Semantic + + +## Text styles + +Text styles (also known as composite tokens) combine each individual typography token into a defined style. They include styles for headings, body copy, and more. All properties are set using typography tokens, except for paragraph spacing. In the mobile app, spacing tokens are used to define paragraph spacing in a text style. + +### Headings + + +### Body + + +### Other + + +## How to use typography tokens + +Designers and engineers are encouraged to use typography tokens to ensure a consistent look and feel throughout the app. Multiple typography tokens are combined to create composite tokens (aka text styles). To use typography tokens and text styles in the app, we recommend a few different approaches: + +- For Headings and Body copy, use the [Text component](/va-mobile-app/design/Components/Typography/Text). +- For larger Display copy, use the [Text component](/va-mobile-app/design/Components/Typography/Text). +- For smaller Navigation copy (such as the bottom tab bar), apply the Navigation text style directly to a text box. + +**Coming soon** +- For bulleted/numbered lists, there will be a separate component in the future. +- For inline links and styling (bold, italics, etc.), there will be a separate component in the future. \ No newline at end of file diff --git a/VAMobile/documentation/design/intro.md b/VAMobile/documentation/design/intro.md index 1ac79477e1d..b4a34b40c8f 100644 --- a/VAMobile/documentation/design/intro.md +++ b/VAMobile/documentation/design/intro.md @@ -35,6 +35,9 @@ A system to help you write, design, and build digital services on the VA Mobile ### Selection and input - [Checkbox](/va-mobile-app/design/Components/Selection%20and%20input/Checkbox) +### Typography +- [Text](/va-mobile-app/design/Components/Typography/Text) + ----- ## Design system team