Disclaimer: This feature uses cookies to store your theme choices. We do not collect personal information or data.
The NIAID Design System uses the Atomic Design philosophy to organize and manage components. Atomic Design is the principle of breaking down web components into their most basic elements and combining those elements to create more complex structures. The most basic building blocks of web elements, such as colors, fonts, and buttons, are called Atoms.
There are four main button styles for each Color Theme option: Primary, Secondary, Tertiary, and Negative (Error State). In general, buttons are used for actions that occur on the page while links take users from one page to another. Depending on the importance of a link, you may decide to style it as a button to make it stand out more. Also shown here is the "disabled" button style.
Read more guidance about buttons from the U.S. Web Design System
There may be situations where you will want smaller or larger buttons than the default NDS sizes. NDS has two utility classes that can be added to your buttons for a smaller and larger size:
button-nds--sm
- A button with tighter padding.button-nds--lg
- A block that fills the full width of its container.There are three button styles for each Color Theme option: Primary, Secondary, and Tertiary. In general, buttons are used for actions that occur on the page. This button should be used when the text and context of the button changes when the jQuery function "onClick" is performed.
Used specifically for links to external sites displayed as a button.
In some instances, you may want to have a persistent button available to users at all times. For example a "Back to Top" button that returns users to the top of the page or the color palette button on this site that allows for theme customizations. For these purposes NDS provides the Floating Button pattern which is fixed at the lower right of the screen. To provide more clarity about its function the Floating Button expands on hover and focus to reveal button text.
The width of the Floating Button on hover and focus depends on the width of the text. Out of the box, the Floating Button pattern's width is configured to work for "Back to Top" text. You may change this text but you will also likely need to change the default width and the width on hover and focus.
This component allows users to include a Font Awesome icon inside an NDS button.
This component allows for a small image, such as a user picture, to be included inside a button.
Share Buttons are useful for sharing site content to social media platforms. NDS provides buttons for several platforms and utilizes proper platform brand colors. The supported social media platforms are shown below.
NDS uses the Font Awesome library for all icons (with the exception of third-party applications and companies). In Font Awesome icons are selected using classes. The specific icon is selected with fa- class (e.g. fa-envelope). The style or weight of the icon is also specified using classes. The following icon weights and corresponding classes are available under the Font Awesome Free version:
fas
fab
fa/far
If you have access to Font Awesome Pro, a "Light" icon style (fal) and a Duotone icon style (fad) are also supported.
NDS makes using Font Awesome icons easy through its icon-default pattern. This pattern has two key parameters: icon_default_type and icon_default_weight. For the icon_default_type, simply pass the name of the icon (without the fa-). For weight, pass only the letter corresponding to the desired icon weight:
s
b
r
l
(Pro Only)d
(Pro Only)View the Font Awesome icon library.
NIAID's Office of Communications and Government Relations (OCGR) has a Font Awesome Pro license that may be used under certain circumstances. If you have a need for Font Awesome Pro, please contact OCGR to request access. If you have already received access and are looking for documentation on upgrading from Font Awesome Free, please see our Using Font Awesome Pro with NDS (NPM) guide.
Document icons can help users quickly identify document types. This component leverages the brand colors for each document type and applies them to the appropriate Font Awesome document icon.
The Document Icon pattern can also be used as a button if a path is supplied to the "icon_document_href" parameter.
Use the "icon_document_type" parameter to choose a type as follows:
This component can be useful for adding visual interest or additional meaning through iconography. We advise that icons be used only when their meaning is very clear.
The Icon Loader pattern from Materialize is used to provide visual feedback to users that the site is processing, receiving, or transmitting information.
You must seek approval to use the NIAID logo on your website or application. If you are a NIAID or NIH employee, please review the Requesting the Use of the NIAID Logo page on NIAID's Intranet.
The NIAID favorite icon (favicon) is a small icon used to show your relation to NIAD within a user's preferred browser. The default shape of a favicon is square, and can be exported in the following formats: .jpg, .ico and .png. All current browsers and devices support 32x32 icons (recommended). Where applicable, the NIAID favicon should be used.
The Site Layout component provides a general framework for an NDS page using Twig block statements. The main regions defined in the pattern are header, global_navigation, hero, main, and footer. The block statements that define these regions are only visible in the Twig file. The HTML structure of Site Layout is very plain, allowing you to define your own markup with almost full flexibility.
Included in the Site Layout is a skip link that will direct users to the main content of the page for accessibility purposes. It is important to add an ID of value "main-content" to the first element on the page that appears after elements that are common to all pages, such as headers and navigation. This will help users who navigate with a keyboard or screen reader to easily move past redundant content. For more information on skip links, please visit the WCAG 2.0 documentation on skip links.
The Site Layout component is generally embedded in a template or page to provide a page with structure. Content is passed and positioned within the layout with block statements. Blocks do not have to be defined and will not render unless content is passed.
The Main Layout component defines the major sections of an NDS page. The component provides three main columns: left, main, and right.
The Main Layout component is generally embedded within the {% block main %} block of the Site Layout pattern. The main layout pattern has three possible columns for content but using all three is not required.
The Body Layout component is used to display a page's main content. This component handles padding at various breakpoints, ensuring a visually appealing experience regardless of device or browser.
The Body Layout component is generally embedded within the {% block main_column %} block of the Main Layout pattern.
The Grid Layout component is used to display content that requires dynamic columns.
NIAID is making every effort to eliminate the use of stigmatizing terminology and advance the use of person-first.
STOMP is an NIAID-funded clinical trial to evaluate the efficacy of the antiviral tecovirimat, also know as TPOXX.
Whether you are passionate about science, administration, or innovation, there is a place for you at NIAID.
NIAID is making every effort to eliminate the use of stigmatizing terminology and advance the use of person-first.
STOMP is an NIAID-funded clinical trial to evaluate the efficacy of the antiviral tecovirimat, also know as TPOXX.
Whether you are passionate about science, administration, or innovation, there is a place for you at NIAID.
The Grid Layout component defines the horizontal and vertical sections of a page. The component provides four equal column options: 2, 3, 4, and 5 columns.
Links are used to take website users from page to page. NDS uses a bottom-border instead of an underline to make links look more elegant.
The Default Link pattern can be used to build generic links.
NDS requires that all external links — links that direct users away from the current site they are viewing — are designated with the Font Awesome external link icon. Out of the box NDS uses JavaScript to automatically append these icons. A notable exception to this policy is links to social media (e.g. Facebook, Instagram, X, etc.) when they are presented in the form of a button.
A link pattern that allows for an icon to be included with the link text.
A pattern used to generate a list of links. The links may optionally include icons.
This pattern can be used to generate a list of links with or without icons. To include icons, all icon parameters must be supplied as part of the list_links_data objects.
Audio and video can be effective ways to communicate with your audience, however each comes with a variety of accessibility requirements. Please review the guidelines from W3C on how to make your audio or video accessible.
The Media YouTube Video component makes it easy to embed YouTube videos on your website.
The "media_video_youtube_src" parameter requires a specific embed URL from YouTube (not to be confused with the regular URL to the video page). To get this embed link, go to the YouTube video you would like to embed. Select "Share" below the video, then "Embed". The needed URL is found as the value for the "src" attribute in the displayed embed code.
Tables on the web can be challenging in terms of accessibility and responsiveness. NDS employs DataTables to create properly formatted, simple tables to improve the experience of tables across devices. Adding the custom attribute nds-datatable="true" to the table tag will initialize the responsive functionality of Datatables.
In order to leverage the full capabilities of this component, you must include the following libraries in addition to the NDS Global JS:
DataTables jQuery
Read more guidance about tables from the U.S. Web Design System
Name | Position | Office | Location | Phone | |
---|---|---|---|---|---|
Name | Position | Office | Location | Phone | |
Name | Position | Office | Location | Phone | |
Name | Position | Office | Location | Phone |
Name | Position | Office | Location | Phone | |
---|---|---|---|---|---|
Name | Position | Office | Location | Phone | |
Name | Position | Office | Location | Phone | |
Name | Position | Office | Location | Phone |
Blockquotes are useful to separate quotations from the rest of the body text, adding visual interest to pages and highlighting the quotation.
A block quotation (also known as a long quotation or extract) is a quotation in a written document that is set off from the main text as a paragraph, or block of text and typically distinguished visually using indentation and a different typeface or smaller size font.
A block quotation (also known as a long quotation or extract) is a quotation in a written document that is set off from the main text as a paragraph, or block of text and typically distinguished visually using indentation and a different typeface or smaller size font.
Badges (tags) are static, non-functional indicators of information. Typically badges are used to showcase tags and metadata of certain components such as search results.
Read more guidance about badges (tags) from the U.S. Web Design System
Dates are static, non-functional indicators of a desired date. Typically dates are used to indicate the date of an event.
Chips are functional indicators of search and filter results. NDS uses a search style which displays selected filters as chips, allowing users to see exactly which terms they have searched and filtered on. Selecting the 'x' in the chip removes the term from the search.
This component allows users to include a Font Awesome icon next to a heading.
We strongly suggest captioning and crediting your images to bolster accessibility and properly cite sources. The easiest way to use this pattern is by leveraging the Media Component (molecule: component-media), negating the need to use this pattern on its own.
A Picture of the Novel Coronavirus
A Picture of the Novel Coronavirus
When displaying a set of search results, it is a best practice to include the total number of results returned. The Search Results component provides a display for this purpose. Place this component directly above the listing of search results.
For questions about the NIAID Design System or to report issues, please visit the Issues tab of the NDS repository on GitHub. To get updates on NDS features and changes, please add yourself as a "Watcher" on the NDS GitHub repository.
NDS on GitHub