uswds-jekyll 4.2.0 → 5.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +233 -211
- data/_includes/analytics.html +6 -9
- data/_includes/components/banner.html +35 -12
- data/_includes/components/footer--big.html +107 -79
- data/_includes/components/footer--default.html +104 -0
- data/_includes/components/footer--slim.html +52 -48
- data/_includes/components/github-edit.html +3 -0
- data/_includes/components/graphic-list.html +13 -11
- data/_includes/components/header.html +71 -60
- data/_includes/components/hero.html +6 -13
- data/_includes/components/search.html +31 -0
- data/_includes/footer.html +2 -2
- data/_includes/meta.html +1 -1
- data/_includes/scripts.html +7 -5
- data/_includes/sidenav.html +4 -4
- data/_includes/styles.html +1 -1
- data/_layouts/default.html +17 -9
- data/_layouts/home.html +6 -0
- data/_layouts/page.html +20 -13
- data/_layouts/project.html +0 -1
- data/_layouts/team-member.html +0 -1
- data/_sass/_uswds-theme-custom-styles.scss +0 -0
- data/_sass/_uswds-theme-override-settings.scss +2 -0
- data/_sass/_uswds-theme-packages.scss +1 -0
- data/_sass/_uswds-theme-settings.scss +0 -0
- data/_sass/uswds/components/_all.scss +8 -0
- data/_sass/{components → uswds/components}/_alt-color-section.scss +6 -7
- data/_sass/{components → uswds/components}/_card.scss +14 -17
- data/_sass/uswds/components/_footer.scss +16 -506
- data/_sass/uswds/components/_header.scss +29 -207
- data/_sass/uswds/components/_hero.scss +37 -29
- data/_sass/{components → uswds/components}/_nav-buttons.scss +4 -4
- data/_sass/uswds/components/_side-nav.scss +48 -0
- data/_sass/uswds/components/_site-width.scss +6 -0
- data/_sass/uswds/components/_top-nav.scss +84 -0
- data/_sass/uswds/components/_usa-banner.scss +30 -0
- data/_sass/uswds/custom/_uswds-theme-custom-styles.scss +47 -0
- data/_sass/uswds/settings/_uswds-conversion-variables.scss +0 -0
- data/_sass/uswds/src/base/_accessibility.scss +3 -0
- data/_sass/uswds/src/base/_body.scss +5 -0
- data/_sass/uswds/src/components/_accordions.scss +116 -0
- data/_sass/uswds/src/components/_alerts.scss +144 -0
- data/_sass/uswds/src/components/_banner.scss +226 -0
- data/_sass/uswds/src/components/_button-groups.scss +134 -0
- data/_sass/uswds/src/components/_card.scss +346 -0
- data/_sass/uswds/src/components/_checklist.scss +17 -0
- data/_sass/uswds/src/components/_footer.scss +349 -0
- data/_sass/uswds/src/components/_forms.scss +54 -0
- data/_sass/uswds/src/components/_graphic-list.scss +42 -0
- data/_sass/uswds/src/components/_header.scss +287 -0
- data/_sass/uswds/src/components/_hero.scss +32 -0
- data/_sass/uswds/src/components/_layout.scss +15 -0
- data/_sass/uswds/src/components/_media-block.scss +7 -0
- data/_sass/uswds/src/components/_megamenu.scss +42 -0
- data/_sass/uswds/src/components/_nav-container.scss +7 -0
- data/_sass/uswds/src/components/_navbar.scss +16 -0
- data/_sass/uswds/src/components/_navigation.scss +348 -0
- data/_sass/uswds/src/components/_search.scss +98 -0
- data/_sass/uswds/src/components/_section.scss +38 -0
- data/_sass/uswds/src/components/_sidenav.scss +19 -0
- data/_sass/uswds/{components → src/components}/_skipnav.scss +7 -6
- data/_sass/uswds/{core → src/core}/_defaults.scss +1 -1
- data/_sass/uswds/src/core/_deprecated.scss +33 -0
- data/_sass/uswds/src/core/_functions.scss +1323 -0
- data/_sass/uswds/src/core/_notifications.scss +86 -0
- data/_sass/uswds/src/core/_properties.scss +687 -0
- data/_sass/uswds/src/core/_system-tokens.scss +1673 -0
- data/_sass/uswds/src/core/_variables.scss +534 -0
- data/_sass/uswds/src/core/mixins/_add-aspect.scss +17 -0
- data/_sass/uswds/src/core/mixins/_add-background-svg.scss +9 -0
- data/_sass/uswds/src/core/mixins/_add-bar.scss +43 -0
- data/_sass/uswds/src/core/mixins/_add-checkbox-placeholder.scss +15 -0
- data/_sass/uswds/src/core/mixins/_add-kerning.scss +4 -0
- data/_sass/uswds/src/core/mixins/_add-knockout-font-smoothing.scss +9 -0
- data/_sass/uswds/src/core/mixins/_add-list-reset.scss +15 -0
- data/_sass/uswds/src/core/mixins/_add-responsive-site-margins.scss +6 -0
- data/_sass/uswds/src/core/mixins/_add-success-mark.scss +7 -0
- data/_sass/uswds/src/core/mixins/_all.scss +86 -0
- data/_sass/uswds/src/core/mixins/_at-media.scss +36 -0
- data/_sass/uswds/src/core/mixins/_border-box-sizing.scss +19 -0
- data/_sass/uswds/src/core/mixins/_button-disabled.scss +17 -0
- data/_sass/uswds/src/core/mixins/_button-unstyled.scss +20 -0
- data/_sass/uswds/src/core/mixins/_clearfix.scss +7 -0
- data/_sass/uswds/src/core/mixins/_embed-container.scss +3 -0
- data/_sass/uswds/src/core/mixins/_external-link.scss +21 -0
- data/_sass/uswds/src/core/mixins/_focus.scss +14 -0
- data/_sass/uswds/src/core/mixins/_font-face.scss +103 -0
- data/_sass/uswds/src/core/mixins/_icon.scss +64 -0
- data/_sass/uswds/src/core/mixins/_layout-grid.scss +128 -0
- data/_sass/uswds/src/core/mixins/_media-block-img.scss +4 -0
- data/_sass/uswds/{elements/_figure.scss → src/core/mixins/_media-link.scss} +0 -8
- data/_sass/uswds/src/core/mixins/_nav-list.scss +95 -0
- data/_sass/uswds/src/core/mixins/_override-prose.scss +6 -0
- data/_sass/uswds/src/core/mixins/_screen-reader.scss +23 -0
- data/_sass/uswds/src/core/mixins/_typography.scss +161 -0
- data/_sass/uswds/src/core/mixins/_unstyled-list.scss +11 -0
- data/_sass/uswds/src/core/mixins/_usa-list-styles.scss +10 -0
- data/_sass/uswds/src/core/mixins/_usa-table-styles.scss +8 -0
- data/_sass/uswds/src/core/mixins/_usa-typography.scss +54 -0
- data/_sass/uswds/src/core/mixins/_utility-builder.scss +369 -0
- data/_sass/uswds/src/core/mixins/layout-grid/_grid-container.scss +14 -0
- data/_sass/uswds/src/core/mixins/layout-grid/_grid-row.scss +7 -0
- data/_sass/uswds/src/core/mixins/utilities/_align-items.scss +11 -0
- data/_sass/uswds/src/core/mixins/utilities/_background-color.scss +9 -0
- data/_sass/uswds/src/core/mixins/utilities/_border-color.scss +11 -0
- data/_sass/uswds/src/core/mixins/utilities/_border-radius.scss +55 -0
- data/_sass/uswds/src/core/mixins/utilities/_border-width.scss +32 -0
- data/_sass/uswds/src/core/mixins/utilities/_border.scss +142 -0
- data/_sass/uswds/src/core/mixins/utilities/_bottom.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_circle.scss +9 -0
- data/_sass/uswds/src/core/mixins/utilities/_color.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_cursor.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_display.scss +11 -0
- data/_sass/uswds/src/core/mixins/utilities/_flex-direction.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_flex.scss +50 -0
- data/_sass/uswds/src/core/mixins/utilities/_float.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_font-weight.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_font.scss +42 -0
- data/_sass/uswds/src/core/mixins/utilities/_height.scss +11 -0
- data/_sass/uswds/src/core/mixins/utilities/_justify-content.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_left.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_line-height.scss +13 -0
- data/_sass/uswds/src/core/mixins/utilities/_margin.scss +85 -0
- data/_sass/uswds/src/core/mixins/utilities/_max-height.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_max-width.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_measure.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_min-height.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_min-width.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_order.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_outline-color.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_outline.scss +35 -0
- data/_sass/uswds/src/core/mixins/utilities/_overflow.scss +28 -0
- data/_sass/uswds/src/core/mixins/utilities/_padding.scss +49 -0
- data/_sass/uswds/src/core/mixins/utilities/_pin.scss +82 -0
- data/_sass/uswds/src/core/mixins/utilities/_position.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_right.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_shadow.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_square.scss +7 -0
- data/_sass/uswds/src/core/mixins/utilities/_text-align.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_text-decoration-color.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_text-decoration.scss +17 -0
- data/_sass/uswds/src/core/mixins/utilities/_text-indent.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_text.scss +72 -0
- data/_sass/uswds/src/core/mixins/utilities/_top.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_vertical-align.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_white-space.scss +10 -0
- data/_sass/uswds/src/core/mixins/utilities/_width.scss +11 -0
- data/_sass/uswds/src/core/mixins/utilities/_z-index.scss +10 -0
- data/_sass/uswds/src/core/placeholders/_all.scss +2 -0
- data/_sass/uswds/src/core/placeholders/_list.scss +18 -0
- data/_sass/uswds/src/core/placeholders/_table.scss +58 -0
- data/_sass/uswds/src/core/system-tokens/_blue-cool.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_blue-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_blue.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_cyan.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_gold.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_gray-cool.scss +18 -0
- data/_sass/uswds/src/core/system-tokens/_gray-warm.scss +18 -0
- data/_sass/uswds/src/core/system-tokens/_gray.scss +19 -0
- data/_sass/uswds/src/core/system-tokens/_green-cool.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_green-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_green.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_indigo-cool.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_indigo-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_indigo.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_magenta.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_mint-cool.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_mint.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_orange-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_orange.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_red-cool.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_red-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_red.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_violet-warm.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_violet.scss +26 -0
- data/_sass/uswds/src/core/system-tokens/_yellow.scss +26 -0
- data/_sass/uswds/src/elements/_buttons.scss +217 -0
- data/_sass/uswds/{elements → src/elements}/_embed.scss +0 -4
- data/_sass/uswds/src/elements/_figure.scss +7 -0
- data/_sass/uswds/src/elements/_layout-grid.scss +159 -0
- data/_sass/uswds/src/elements/_table.scss +7 -0
- data/_sass/uswds/src/elements/_tags.scss +18 -0
- data/_sass/uswds/src/elements/form-controls/_all.scss +9 -0
- data/_sass/uswds/src/elements/form-controls/_character-count.scss +9 -0
- data/_sass/uswds/src/elements/form-controls/_checkbox-and-radio.scss +115 -0
- data/_sass/uswds/src/elements/form-controls/_combo-box.scss +55 -0
- data/_sass/uswds/src/elements/form-controls/_date-input.scss +31 -0
- data/_sass/uswds/src/elements/form-controls/_dropdown.scss +25 -0
- data/_sass/uswds/src/elements/form-controls/_file-input.scss +4 -0
- data/_sass/uswds/src/elements/form-controls/_global.scss +84 -0
- data/_sass/uswds/src/elements/form-controls/_range-input.scss +89 -0
- data/_sass/uswds/src/elements/form-controls/_text-input.scss +13 -0
- data/_sass/uswds/src/elements/typography/_content.scss +62 -0
- data/_sass/uswds/src/elements/typography/_links.scss +15 -0
- data/_sass/uswds/src/elements/typography/_list.scss +14 -0
- data/_sass/uswds/src/elements/typography/_prose.scss +6 -0
- data/_sass/uswds/src/global/_focus.scss +24 -0
- data/_sass/uswds/src/global/_font-face.scss +11 -0
- data/_sass/uswds/src/global/_sizing.scss +14 -0
- data/_sass/uswds/src/global/_typography.scss +32 -0
- data/_sass/uswds/src/lib/_normalize.scss +349 -0
- data/_sass/uswds/src/packages/_form-controls.scss +4 -0
- data/_sass/uswds/src/packages/_form-templates.scss +8 -0
- data/_sass/uswds/src/packages/_global.scss +7 -0
- data/_sass/uswds/src/packages/_layout-grid.scss +4 -0
- data/_sass/uswds/src/packages/_required.scss +21 -0
- data/_sass/uswds/src/packages/_typography.scss +7 -0
- data/_sass/uswds/src/packages/_usa-accordion.scss +4 -0
- data/_sass/uswds/src/packages/_usa-alert.scss +4 -0
- data/_sass/uswds/src/packages/_usa-banner.scss +7 -0
- data/_sass/uswds/src/packages/_usa-button-group.scss +2 -0
- data/_sass/uswds/src/packages/_usa-button.scss +4 -0
- data/_sass/uswds/src/packages/_usa-card.scss +4 -0
- data/_sass/uswds/src/packages/_usa-checklist.scss +4 -0
- data/_sass/uswds/src/packages/_usa-footer.scss +10 -0
- data/_sass/uswds/src/packages/_usa-header.scss +13 -0
- data/_sass/uswds/src/packages/_usa-hero.scss +6 -0
- data/_sass/uswds/src/packages/_usa-media-block.scss +5 -0
- data/_sass/uswds/src/packages/_usa-megamenu.scss +4 -0
- data/_sass/uswds/src/packages/_usa-nav-container.scss +4 -0
- data/_sass/uswds/src/packages/_usa-nav.scss +5 -0
- data/_sass/uswds/src/packages/_usa-navbar.scss +4 -0
- data/_sass/uswds/src/packages/_usa-search.scss +8 -0
- data/_sass/uswds/src/packages/_usa-sidenav.scss +4 -0
- data/_sass/uswds/src/packages/_usa-skipnav.scss +4 -0
- data/_sass/uswds/src/packages/_usa-table.scss +4 -0
- data/_sass/uswds/src/packages/_usa-tag.scss +4 -0
- data/_sass/uswds/src/packages/_uswds-components.scss +44 -0
- data/_sass/uswds/src/packages/_uswds-fonts.scss +2 -0
- data/_sass/uswds/src/packages/_uswds-utilities.scss +6 -0
- data/_sass/uswds/src/packages/_validation.scss +8 -0
- data/_sass/uswds/src/settings/_settings-color.scss +133 -0
- data/_sass/uswds/src/settings/_settings-components.scss +85 -0
- data/_sass/uswds/src/settings/_settings-general.scss +101 -0
- data/_sass/uswds/src/settings/_settings-spacing.scss +93 -0
- data/_sass/uswds/src/settings/_settings-typography.scss +422 -0
- data/_sass/uswds/src/settings/_settings-utilities.scss +853 -0
- data/_sass/uswds/src/theme/_uswds-theme-color.scss +133 -0
- data/_sass/uswds/src/theme/_uswds-theme-components.scss +85 -0
- data/_sass/uswds/src/theme/_uswds-theme-custom-styles.scss +21 -0
- data/_sass/uswds/src/theme/_uswds-theme-general.scss +101 -0
- data/_sass/uswds/src/theme/_uswds-theme-spacing.scss +93 -0
- data/_sass/uswds/src/theme/_uswds-theme-typography.scss +422 -0
- data/_sass/uswds/src/theme/_uswds-theme-utilities.scss +854 -0
- data/_sass/uswds/src/theme/styles.scss +72 -0
- data/_sass/uswds/src/uswds.scss +17 -0
- data/_sass/uswds/src/utilities/palettes/_all.scss +41 -0
- data/_sass/uswds/src/utilities/palettes/_default-palettes.scss +72 -0
- data/_sass/uswds/src/utilities/palettes/_font-palettes.scss +2762 -0
- data/_sass/uswds/src/utilities/palettes/_palette-registry.scss +46 -0
- data/_sass/uswds/src/utilities/palettes/_spacing-palettes.scss +135 -0
- data/_sass/uswds/src/utilities/palettes/colors/_all-colors-palettes.scss +56 -0
- data/_sass/uswds/src/utilities/palettes/colors/_black-transparent-palettes.scss +16 -0
- data/_sass/uswds/src/utilities/palettes/colors/_blue-cool-palettes.scss +69 -0
- data/_sass/uswds/src/utilities/palettes/colors/_blue-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_blue-warm-palettes.scss +69 -0
- data/_sass/uswds/src/utilities/palettes/colors/_cyan-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_gold-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_gray-cool-palettes.scss +40 -0
- data/_sass/uswds/src/utilities/palettes/colors/_gray-palettes.scss +40 -0
- data/_sass/uswds/src/utilities/palettes/colors/_gray-warm-palettes.scss +40 -0
- data/_sass/uswds/src/utilities/palettes/colors/_green-cool-palettes.scss +69 -0
- data/_sass/uswds/src/utilities/palettes/colors/_green-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_green-warm-palettes.scss +69 -0
- data/_sass/uswds/src/utilities/palettes/colors/_indigo-cool-palettes.scss +70 -0
- data/_sass/uswds/src/utilities/palettes/colors/_indigo-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_indigo-warm-palettes.scss +70 -0
- data/_sass/uswds/src/utilities/palettes/colors/_magenta-palettes.scss +67 -0
- data/_sass/uswds/src/utilities/palettes/colors/_mint-cool-palettes.scss +69 -0
- data/_sass/uswds/src/utilities/palettes/colors/_mint-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_orange-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_orange-warm-palettes.scss +70 -0
- data/_sass/uswds/src/utilities/palettes/colors/_red-cool-palettes.scss +68 -0
- data/_sass/uswds/src/utilities/palettes/colors/_red-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_red-warm-palettes.scss +68 -0
- data/_sass/uswds/src/utilities/palettes/colors/_violet-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/palettes/colors/_violet-warm-palettes.scss +70 -0
- data/_sass/uswds/src/utilities/palettes/colors/_white-transparent-palettes.scss +16 -0
- data/_sass/uswds/src/utilities/palettes/colors/_yellow-palettes.scss +66 -0
- data/_sass/uswds/src/utilities/rules/_all.scss +56 -0
- data/_sass/uswds/src/utilities/rules/_package.scss +61 -0
- data/_sass/uswds/src/utilities/rules/add-aspect.scss +84 -0
- data/_sass/uswds/src/utilities/rules/add-list-reset.scss +39 -0
- data/_sass/uswds/src/utilities/rules/align-items.scss +30 -0
- data/_sass/uswds/src/utilities/rules/background-color.scss +32 -0
- data/_sass/uswds/src/utilities/rules/border-color.scss +32 -0
- data/_sass/uswds/src/utilities/rules/border-radius.scss +51 -0
- data/_sass/uswds/src/utilities/rules/border-style.scss +30 -0
- data/_sass/uswds/src/utilities/rules/border-width.scss +44 -0
- data/_sass/uswds/src/utilities/rules/border.scss +47 -0
- data/_sass/uswds/src/utilities/rules/bottom.scss +28 -0
- data/_sass/uswds/src/utilities/rules/box-shadow.scss +27 -0
- data/_sass/uswds/src/utilities/rules/circle.scss +35 -0
- data/_sass/uswds/src/utilities/rules/clearfix.scss +35 -0
- data/_sass/uswds/src/utilities/rules/color.scss +32 -0
- data/_sass/uswds/src/utilities/rules/cursor.scss +26 -0
- data/_sass/uswds/src/utilities/rules/display.scss +26 -0
- data/_sass/uswds/src/utilities/rules/flex-direction.scss +30 -0
- data/_sass/uswds/src/utilities/rules/flex-wrap.scss +27 -0
- data/_sass/uswds/src/utilities/rules/flex.scss +32 -0
- data/_sass/uswds/src/utilities/rules/float.scss +26 -0
- data/_sass/uswds/src/utilities/rules/font-family.scss +38 -0
- data/_sass/uswds/src/utilities/rules/font-feature.scss +31 -0
- data/_sass/uswds/src/utilities/rules/font-style.scss +29 -0
- data/_sass/uswds/src/utilities/rules/font-weight.scss +30 -0
- data/_sass/uswds/src/utilities/rules/font.scss +38 -0
- data/_sass/uswds/src/utilities/rules/height.scss +26 -0
- data/_sass/uswds/src/utilities/rules/justify-content.scss +32 -0
- data/_sass/uswds/src/utilities/rules/left.scss +28 -0
- data/_sass/uswds/src/utilities/rules/letter-spacing.scss +30 -0
- data/_sass/uswds/src/utilities/rules/line-height.scss +30 -0
- data/_sass/uswds/src/utilities/rules/margin.scss +70 -0
- data/_sass/uswds/src/utilities/rules/max-height.scss +27 -0
- data/_sass/uswds/src/utilities/rules/max-width.scss +27 -0
- data/_sass/uswds/src/utilities/rules/measure.scss +28 -0
- data/_sass/uswds/src/utilities/rules/min-height.scss +27 -0
- data/_sass/uswds/src/utilities/rules/min-width.scss +27 -0
- data/_sass/uswds/src/utilities/rules/opacity.scss +28 -0
- data/_sass/uswds/src/utilities/rules/order.scss +29 -0
- data/_sass/uswds/src/utilities/rules/outline-color.scss +33 -0
- data/_sass/uswds/src/utilities/rules/outline.scss +30 -0
- data/_sass/uswds/src/utilities/rules/overflow.scss +31 -0
- data/_sass/uswds/src/utilities/rules/padding.scss +43 -0
- data/_sass/uswds/src/utilities/rules/pin.scss +101 -0
- data/_sass/uswds/src/utilities/rules/position.scss +27 -0
- data/_sass/uswds/src/utilities/rules/right.scss +28 -0
- data/_sass/uswds/src/utilities/rules/square.scss +33 -0
- data/_sass/uswds/src/utilities/rules/text-align.scss +27 -0
- data/_sass/uswds/src/utilities/rules/text-decoration-color.scss +31 -0
- data/_sass/uswds/src/utilities/rules/text-decoration.scss +30 -0
- data/_sass/uswds/src/utilities/rules/text-indent.scss +30 -0
- data/_sass/uswds/src/utilities/rules/text-transform.scss +30 -0
- data/_sass/uswds/src/utilities/rules/top.scss +28 -0
- data/_sass/uswds/src/utilities/rules/vertical-align.scss +30 -0
- data/_sass/uswds/src/utilities/rules/whitespace.scss +27 -0
- data/_sass/uswds/src/utilities/rules/width.scss +26 -0
- data/_sass/uswds/src/utilities/rules/z-index.scss +28 -0
- data/_sass/uswds/src/utilities/utility-fonts.scss +20 -0
- data/assets/css/uswds-theme.scss +187 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Black.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Black.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Black.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BlackItalic.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BlackItalic.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BlackItalic.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Bold.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Bold.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Bold.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BoldItalic.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BoldItalic.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-BoldItalic.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Italic.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Italic.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Italic.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Light.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Light.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Light.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-LightItalic.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-LightItalic.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-LightItalic.woff2 +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Regular.ttf +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Regular.woff +0 -0
- data/assets/uswds/fonts/merriweather/Latin-Merriweather-Regular.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Black.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Black.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Black.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BlackItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BlackItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BlackItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Bold.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Bold.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Bold.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BoldItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BoldItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-BoldItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBold.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBold.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBold.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBoldItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBoldItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraBoldItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLight.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLight.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLight.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLightItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLightItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ExtraLightItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Italic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Italic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Italic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Light.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Light.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Light.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-LightItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-LightItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-LightItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Medium.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Medium.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Medium.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-MediumItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-MediumItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-MediumItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Regular.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Regular.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Regular.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBold.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBold.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBold.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBoldItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBoldItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-SemiBoldItalic.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Thin.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Thin.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-Thin.woff2 +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ThinItalic.ttf +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ThinItalic.woff +0 -0
- data/assets/uswds/fonts/public-sans/PublicSans-ThinItalic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100italic.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100italic.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-100italic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300italic.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300italic.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300italic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500italic.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500italic.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-500italic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700italic.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700italic.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700italic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-italic.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-italic.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-italic.woff2 +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-regular.ttf +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-regular.woff +0 -0
- data/assets/uswds/fonts/roboto-mono/roboto-mono-v5-latin-regular.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-black-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-black-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-black-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-blackitalic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-blackitalic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-blackitalic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bold-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bold-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bold-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bolditalic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bolditalic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-bolditalic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralight-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralight-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralight-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralightitalic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralightitalic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-extralightitalic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-italic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-italic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-italic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-light-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-light-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-light-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-lightitalic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-lightitalic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-lightitalic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-regular-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-regular-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-regular-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibold-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibold-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibold-webfont.woff2 +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibolditalic-webfont.ttf +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibolditalic-webfont.woff +0 -0
- data/assets/uswds/fonts/source-sans-pro/sourcesanspro-semibolditalic-webfont.woff2 +0 -0
- data/assets/uswds/img/alerts/error.svg +4 -17
- data/assets/uswds/img/alerts/info.svg +4 -18
- data/assets/uswds/img/alerts/success.svg +1 -12
- data/assets/uswds/img/alerts/warning.svg +4 -16
- data/assets/uswds/img/angle-arrow-down-hover.svg +1 -1
- data/assets/uswds/img/angle-arrow-down-primary-hover.svg +1 -1
- data/assets/uswds/img/angle-arrow-down-primary.svg +1 -1
- data/assets/uswds/img/angle-arrow-down-white.svg +1 -0
- data/assets/uswds/img/angle-arrow-down.svg +1 -1
- data/assets/uswds/img/angle-arrow-up-primary-hover.svg +1 -1
- data/assets/uswds/img/angle-arrow-up-primary.svg +1 -1
- data/assets/uswds/img/angle-arrow-up-white.svg +1 -0
- data/assets/uswds/img/arrow-both.svg +1 -1
- data/assets/uswds/img/arrow-down.svg +1 -1
- data/assets/uswds/img/arrow-right.svg +1 -1
- data/assets/uswds/img/checkbox-check-print.svg +1 -0
- data/assets/uswds/img/close-blue-30-alt.svg +3 -0
- data/assets/uswds/img/close-blue-40v-alt.svg +3 -0
- data/assets/uswds/img/close-blue-50-alt.svg +3 -0
- data/assets/uswds/img/close-blue-50v-alt.svg +3 -0
- data/assets/uswds/img/close-blue-60-alt.svg +3 -0
- data/assets/uswds/img/close-blue-60v-alt.svg +3 -0
- data/assets/uswds/img/close-gray-90-alt.svg +3 -0
- data/assets/uswds/img/close-primary.svg +1 -16
- data/assets/uswds/img/close-white-alt.svg +3 -0
- data/assets/uswds/img/close-white.svg +3 -0
- data/assets/uswds/img/close.svg +1 -12
- data/assets/uswds/img/correct8-alt.svg +1 -1
- data/assets/uswds/img/correct8.svg +1 -1
- data/assets/uswds/img/correct9.svg +1 -1
- data/assets/uswds/img/external-link-alt-hover.svg +1 -1
- data/assets/uswds/img/external-link-alt.svg +1 -1
- data/assets/uswds/img/external-link-hover.svg +1 -1
- data/assets/uswds/img/external-link.svg +1 -1
- data/assets/uswds/img/favicons/favicon-114.png +0 -0
- data/assets/uswds/img/favicons/favicon-144.png +0 -0
- data/assets/uswds/img/favicons/favicon-16.png +0 -0
- data/assets/uswds/img/favicons/favicon-192.png +0 -0
- data/assets/uswds/img/favicons/favicon-40.png +0 -0
- data/assets/uswds/img/favicons/favicon-57.png +0 -0
- data/assets/uswds/img/favicons/favicon-72.png +0 -0
- data/assets/uswds/img/favicons/favicon.ico +0 -0
- data/assets/uswds/img/favicons/favicon.png +0 -0
- data/assets/uswds/img/icon-dot-gov.svg +1 -1
- data/assets/uswds/img/icon-https.svg +1 -1
- data/assets/uswds/img/minus-alt.svg +1 -1
- data/assets/uswds/img/minus.svg +1 -1
- data/assets/uswds/img/plus-alt.svg +1 -1
- data/assets/uswds/img/plus.svg +1 -1
- data/assets/uswds/img/search-alt.svg +1 -1
- data/assets/uswds/img/search-primary.svg +1 -12
- data/assets/uswds/img/search.svg +1 -1
- data/assets/uswds/img/social-icons/{png/facebook25.png → facebook25.png} +0 -0
- data/assets/uswds/img/social-icons/{svg/facebook25.svg → facebook25.svg} +1 -1
- data/assets/uswds/img/social-icons/{png/rss25.png → rss25.png} +0 -0
- data/assets/uswds/img/social-icons/{svg/rss25.svg → rss25.svg} +1 -1
- data/assets/uswds/img/social-icons/{png/twitter16.png → twitter16.png} +0 -0
- data/assets/uswds/img/social-icons/{svg/twitter16.svg → twitter16.svg} +1 -1
- data/assets/uswds/img/social-icons/{png/youtube15.png → youtube15.png} +0 -0
- data/assets/uswds/img/social-icons/{svg/youtube15.svg → youtube15.svg} +1 -1
- data/assets/uswds/js/uswds.js +1330 -809
- data/assets/uswds/js/uswds.min.js +1 -1
- data/assets/uswds/js/uswds.min.js.map +1 -1
- metadata +498 -222
- data/_includes/components/footer--medium.html +0 -100
- data/_sass/components/_all.scss +0 -8
- data/_sass/components/_footer.scss +0 -26
- data/_sass/components/_header.scss +0 -27
- data/_sass/components/_hero.scss +0 -45
- data/_sass/components/_side-nav.scss +0 -61
- data/_sass/components/_site-width.scss +0 -12
- data/_sass/components/_top-nav.scss +0 -73
- data/_sass/components/_usa-banner.scss +0 -29
- data/_sass/uswds/_all.scss +0 -1
- data/_sass/uswds/components/_accordions.scss +0 -150
- data/_sass/uswds/components/_alerts.scss +0 -128
- data/_sass/uswds/components/_banner.scss +0 -203
- data/_sass/uswds/components/_forms.scss +0 -144
- data/_sass/uswds/components/_graphic-list.scss +0 -35
- data/_sass/uswds/components/_layout.scss +0 -36
- data/_sass/uswds/components/_media-block.scss +0 -12
- data/_sass/uswds/components/_navigation.scss +0 -561
- data/_sass/uswds/components/_search.scss +0 -111
- data/_sass/uswds/components/_section.scss +0 -37
- data/_sass/uswds/components/_sidenav.scss +0 -31
- data/_sass/uswds/core/_base.scss +0 -36
- data/_sass/uswds/core/_fonts.scss +0 -65
- data/_sass/uswds/core/_grid-settings.scss +0 -3
- data/_sass/uswds/core/_grid.scss +0 -198
- data/_sass/uswds/core/_utilities.scss +0 -252
- data/_sass/uswds/core/_variables-vendor.scss +0 -12
- data/_sass/uswds/core/_variables.scss +0 -159
- data/_sass/uswds/elements/_buttons.scss +0 -217
- data/_sass/uswds/elements/_inputs.scss +0 -405
- data/_sass/uswds/elements/_labels.scss +0 -20
- data/_sass/uswds/elements/_list.scss +0 -19
- data/_sass/uswds/elements/_table.scss +0 -55
- data/_sass/uswds/elements/_typography.scss +0 -238
- data/_sass/uswds/lib/_bourbon-deprecated-upcoming.scss +0 -411
- data/_sass/uswds/lib/_bourbon.scss +0 -87
- data/_sass/uswds/lib/_neat-helpers.scss +0 -11
- data/_sass/uswds/lib/_neat.scss +0 -23
- data/_sass/uswds/lib/_normalize.scss +0 -424
- data/_sass/uswds/lib/addons/_border-color.scss +0 -26
- data/_sass/uswds/lib/addons/_border-radius.scss +0 -48
- data/_sass/uswds/lib/addons/_border-style.scss +0 -25
- data/_sass/uswds/lib/addons/_border-width.scss +0 -25
- data/_sass/uswds/lib/addons/_buttons.scss +0 -64
- data/_sass/uswds/lib/addons/_clearfix.scss +0 -25
- data/_sass/uswds/lib/addons/_ellipsis.scss +0 -30
- data/_sass/uswds/lib/addons/_font-stacks.scss +0 -31
- data/_sass/uswds/lib/addons/_hide-text.scss +0 -27
- data/_sass/uswds/lib/addons/_margin.scss +0 -26
- data/_sass/uswds/lib/addons/_padding.scss +0 -26
- data/_sass/uswds/lib/addons/_position.scss +0 -48
- data/_sass/uswds/lib/addons/_prefixer.scss +0 -66
- data/_sass/uswds/lib/addons/_retina-image.scss +0 -25
- data/_sass/uswds/lib/addons/_size.scss +0 -51
- data/_sass/uswds/lib/addons/_text-inputs.scss +0 -113
- data/_sass/uswds/lib/addons/_timing-functions.scss +0 -34
- data/_sass/uswds/lib/addons/_triangle.scss +0 -63
- data/_sass/uswds/lib/addons/_word-wrap.scss +0 -29
- data/_sass/uswds/lib/css3/_animation.scss +0 -43
- data/_sass/uswds/lib/css3/_appearance.scss +0 -3
- data/_sass/uswds/lib/css3/_backface-visibility.scss +0 -3
- data/_sass/uswds/lib/css3/_background-image.scss +0 -42
- data/_sass/uswds/lib/css3/_background.scss +0 -55
- data/_sass/uswds/lib/css3/_border-image.scss +0 -59
- data/_sass/uswds/lib/css3/_calc.scss +0 -4
- data/_sass/uswds/lib/css3/_columns.scss +0 -47
- data/_sass/uswds/lib/css3/_filter.scss +0 -4
- data/_sass/uswds/lib/css3/_flex-box.scss +0 -287
- data/_sass/uswds/lib/css3/_font-face.scss +0 -24
- data/_sass/uswds/lib/css3/_font-feature-settings.scss +0 -4
- data/_sass/uswds/lib/css3/_hidpi-media-query.scss +0 -10
- data/_sass/uswds/lib/css3/_hyphens.scss +0 -4
- data/_sass/uswds/lib/css3/_image-rendering.scss +0 -14
- data/_sass/uswds/lib/css3/_keyframes.scss +0 -36
- data/_sass/uswds/lib/css3/_linear-gradient.scss +0 -38
- data/_sass/uswds/lib/css3/_perspective.scss +0 -8
- data/_sass/uswds/lib/css3/_placeholder.scss +0 -8
- data/_sass/uswds/lib/css3/_radial-gradient.scss +0 -39
- data/_sass/uswds/lib/css3/_selection.scss +0 -42
- data/_sass/uswds/lib/css3/_text-decoration.scss +0 -19
- data/_sass/uswds/lib/css3/_transform.scss +0 -15
- data/_sass/uswds/lib/css3/_transition.scss +0 -71
- data/_sass/uswds/lib/css3/_user-select.scss +0 -3
- data/_sass/uswds/lib/functions/_assign-inputs.scss +0 -11
- data/_sass/uswds/lib/functions/_contains-falsy.scss +0 -20
- data/_sass/uswds/lib/functions/_contains.scss +0 -26
- data/_sass/uswds/lib/functions/_is-length.scss +0 -11
- data/_sass/uswds/lib/functions/_is-light.scss +0 -21
- data/_sass/uswds/lib/functions/_is-number.scss +0 -11
- data/_sass/uswds/lib/functions/_is-size.scss +0 -13
- data/_sass/uswds/lib/functions/_modular-scale.scss +0 -69
- data/_sass/uswds/lib/functions/_new-breakpoint.scss +0 -49
- data/_sass/uswds/lib/functions/_private.scss +0 -114
- data/_sass/uswds/lib/functions/_px-to-em.scss +0 -13
- data/_sass/uswds/lib/functions/_px-to-rem.scss +0 -15
- data/_sass/uswds/lib/functions/_shade.scss +0 -24
- data/_sass/uswds/lib/functions/_strip-units.scss +0 -17
- data/_sass/uswds/lib/functions/_tint.scss +0 -24
- data/_sass/uswds/lib/functions/_transition-property-name.scss +0 -22
- data/_sass/uswds/lib/functions/_unpack.scss +0 -27
- data/_sass/uswds/lib/grid/_box-sizing.scss +0 -15
- data/_sass/uswds/lib/grid/_direction-context.scss +0 -33
- data/_sass/uswds/lib/grid/_display-context.scss +0 -28
- data/_sass/uswds/lib/grid/_fill-parent.scss +0 -22
- data/_sass/uswds/lib/grid/_media.scss +0 -92
- data/_sass/uswds/lib/grid/_omega.scss +0 -87
- data/_sass/uswds/lib/grid/_outer-container.scss +0 -34
- data/_sass/uswds/lib/grid/_pad.scss +0 -25
- data/_sass/uswds/lib/grid/_private.scss +0 -35
- data/_sass/uswds/lib/grid/_row.scss +0 -52
- data/_sass/uswds/lib/grid/_shift.scss +0 -50
- data/_sass/uswds/lib/grid/_span-columns.scss +0 -94
- data/_sass/uswds/lib/grid/_to-deprecate.scss +0 -97
- data/_sass/uswds/lib/grid/_visual-grid.scss +0 -42
- data/_sass/uswds/lib/helpers/_convert-units.scss +0 -21
- data/_sass/uswds/lib/helpers/_directional-values.scss +0 -96
- data/_sass/uswds/lib/helpers/_font-source-declaration.scss +0 -43
- data/_sass/uswds/lib/helpers/_gradient-positions-parser.scss +0 -13
- data/_sass/uswds/lib/helpers/_linear-angle-parser.scss +0 -25
- data/_sass/uswds/lib/helpers/_linear-gradient-parser.scss +0 -41
- data/_sass/uswds/lib/helpers/_linear-positions-parser.scss +0 -61
- data/_sass/uswds/lib/helpers/_linear-side-corner-parser.scss +0 -31
- data/_sass/uswds/lib/helpers/_radial-arg-parser.scss +0 -69
- data/_sass/uswds/lib/helpers/_radial-gradient-parser.scss +0 -50
- data/_sass/uswds/lib/helpers/_radial-positions-parser.scss +0 -18
- data/_sass/uswds/lib/helpers/_render-gradients.scss +0 -26
- data/_sass/uswds/lib/helpers/_shape-size-stripper.scss +0 -10
- data/_sass/uswds/lib/helpers/_str-to-num.scss +0 -50
- data/_sass/uswds/lib/mixins/_clearfix.scss +0 -25
- data/_sass/uswds/lib/settings/_asset-pipeline.scss +0 -7
- data/_sass/uswds/lib/settings/_disable-warnings.scss +0 -13
- data/_sass/uswds/lib/settings/_grid.scss +0 -51
- data/_sass/uswds/lib/settings/_prefixer.scss +0 -9
- data/_sass/uswds/lib/settings/_px-to-em.scss +0 -1
- data/_sass/uswds/lib/settings/_visual-grid.scss +0 -27
- data/_sass/uswds/uswds.scss +0 -42
- data/assets/css/main.scss +0 -93
- data/assets/uswds/fonts/merriweather-bold-webfont.eot +0 -0
- data/assets/uswds/fonts/merriweather-bold-webfont.ttf +0 -0
- data/assets/uswds/fonts/merriweather-bold-webfont.woff +0 -0
- data/assets/uswds/fonts/merriweather-bold-webfont.woff2 +0 -0
- data/assets/uswds/fonts/merriweather-italic-webfont.eot +0 -0
- data/assets/uswds/fonts/merriweather-italic-webfont.ttf +0 -0
- data/assets/uswds/fonts/merriweather-italic-webfont.woff +0 -0
- data/assets/uswds/fonts/merriweather-italic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/merriweather-light-webfont.eot +0 -0
- data/assets/uswds/fonts/merriweather-light-webfont.ttf +0 -0
- data/assets/uswds/fonts/merriweather-light-webfont.woff +0 -0
- data/assets/uswds/fonts/merriweather-light-webfont.woff2 +0 -0
- data/assets/uswds/fonts/merriweather-regular-webfont.eot +0 -0
- data/assets/uswds/fonts/merriweather-regular-webfont.ttf +0 -0
- data/assets/uswds/fonts/merriweather-regular-webfont.woff +0 -0
- data/assets/uswds/fonts/merriweather-regular-webfont.woff2 +0 -0
- data/assets/uswds/fonts/sourcesanspro-bold-webfont.eot +0 -0
- data/assets/uswds/fonts/sourcesanspro-bold-webfont.ttf +0 -0
- data/assets/uswds/fonts/sourcesanspro-bold-webfont.woff +0 -0
- data/assets/uswds/fonts/sourcesanspro-bold-webfont.woff2 +0 -0
- data/assets/uswds/fonts/sourcesanspro-italic-webfont.eot +0 -0
- data/assets/uswds/fonts/sourcesanspro-italic-webfont.ttf +0 -0
- data/assets/uswds/fonts/sourcesanspro-italic-webfont.woff +0 -0
- data/assets/uswds/fonts/sourcesanspro-italic-webfont.woff2 +0 -0
- data/assets/uswds/fonts/sourcesanspro-light-webfont.eot +0 -0
- data/assets/uswds/fonts/sourcesanspro-light-webfont.ttf +0 -0
- data/assets/uswds/fonts/sourcesanspro-light-webfont.woff +0 -0
- data/assets/uswds/fonts/sourcesanspro-light-webfont.woff2 +0 -0
- data/assets/uswds/fonts/sourcesanspro-regular-webfont.eot +0 -0
- data/assets/uswds/fonts/sourcesanspro-regular-webfont.ttf +0 -0
- data/assets/uswds/fonts/sourcesanspro-regular-webfont.woff +0 -0
- data/assets/uswds/fonts/sourcesanspro-regular-webfont.woff2 +0 -0
- data/assets/uswds/img/alerts/error.png +0 -0
- data/assets/uswds/img/alerts/info.png +0 -0
- data/assets/uswds/img/alerts/success.png +0 -0
- data/assets/uswds/img/alerts/warning.png +0 -0
- data/assets/uswds/img/angle-arrow-down-hover.png +0 -0
- data/assets/uswds/img/angle-arrow-down-primary-hover.png +0 -0
- data/assets/uswds/img/angle-arrow-down-primary.png +0 -0
- data/assets/uswds/img/angle-arrow-down.png +0 -0
- data/assets/uswds/img/angle-arrow-up-primary-hover.png +0 -0
- data/assets/uswds/img/angle-arrow-up-primary.png +0 -0
- data/assets/uswds/img/arrow-both.png +0 -0
- data/assets/uswds/img/arrow-down.png +0 -0
- data/assets/uswds/img/arrow-right.png +0 -0
- data/assets/uswds/img/close-primary.png +0 -0
- data/assets/uswds/img/close.png +0 -0
- data/assets/uswds/img/correct8.png +0 -0
- data/assets/uswds/img/correct9.png +0 -0
- data/assets/uswds/img/external-link-alt-hover.png +0 -0
- data/assets/uswds/img/external-link-alt.png +0 -0
- data/assets/uswds/img/external-link-hover.png +0 -0
- data/assets/uswds/img/external-link.png +0 -0
- data/assets/uswds/img/minus-alt.png +0 -0
- data/assets/uswds/img/minus.png +0 -0
- data/assets/uswds/img/plus-alt.png +0 -0
- data/assets/uswds/img/plus.png +0 -0
- data/assets/uswds/img/search-alt.png +0 -0
- data/assets/uswds/img/search-primary.png +0 -0
- data/assets/uswds/img/search.png +0 -0
@@ -0,0 +1,98 @@
|
|
1
|
+
// TODO: abstract and integrate
|
2
|
+
@mixin search-icon {
|
3
|
+
@include add-background-svg("search");
|
4
|
+
background-position: center center;
|
5
|
+
background-size: units(2);
|
6
|
+
}
|
7
|
+
|
8
|
+
.usa-search {
|
9
|
+
@include border-box-sizing;
|
10
|
+
@include clearfix;
|
11
|
+
@include typeset($theme-search-font-family);
|
12
|
+
position: relative;
|
13
|
+
|
14
|
+
// if role is in the <form> element (>=2.6.0)...
|
15
|
+
&[role="search"],
|
16
|
+
// if there is a (=2.5.[0,1])...
|
17
|
+
&[role="search"] > div,
|
18
|
+
// ...or if the component has a separate <div[role="search"]> (<=2.4.0)
|
19
|
+
[role="search"] {
|
20
|
+
display: flex;
|
21
|
+
}
|
22
|
+
|
23
|
+
[type="submit"] {
|
24
|
+
@include search-icon;
|
25
|
+
border-bottom-left-radius: 0;
|
26
|
+
border-top-left-radius: 0;
|
27
|
+
height: units(4);
|
28
|
+
margin: 0;
|
29
|
+
padding: 0;
|
30
|
+
width: units($theme-button-small-width);
|
31
|
+
|
32
|
+
@include at-media("mobile-lg") {
|
33
|
+
@include u-padding-x(2);
|
34
|
+
background-image: none;
|
35
|
+
width: auto;
|
36
|
+
}
|
37
|
+
}
|
38
|
+
}
|
39
|
+
|
40
|
+
.usa-search--big {
|
41
|
+
$height: units(6);
|
42
|
+
|
43
|
+
[type="search"],
|
44
|
+
.usa-search__input {
|
45
|
+
@include at-media("mobile-lg") {
|
46
|
+
font-size: font-size($theme-search-font-family, "sm");
|
47
|
+
height: $height;
|
48
|
+
}
|
49
|
+
}
|
50
|
+
|
51
|
+
[type="submit"],
|
52
|
+
.usa-search__submit {
|
53
|
+
@include at-media("mobile-lg") {
|
54
|
+
@include u-padding-x(4);
|
55
|
+
font-size: font-size($theme-search-font-family, "lg");
|
56
|
+
height: $height;
|
57
|
+
width: auto;
|
58
|
+
}
|
59
|
+
}
|
60
|
+
}
|
61
|
+
|
62
|
+
.usa-search--small {
|
63
|
+
[type="submit"],
|
64
|
+
.usa-search__submit {
|
65
|
+
@include at-media("mobile-lg") {
|
66
|
+
@include search-icon;
|
67
|
+
width: units($theme-button-small-width);
|
68
|
+
}
|
69
|
+
}
|
70
|
+
}
|
71
|
+
|
72
|
+
// Extra specificity to override rules set in normalize.css.
|
73
|
+
input[type="search"] {
|
74
|
+
/* stylelint-disable-line selector-no-qualifying-type */
|
75
|
+
box-sizing: border-box;
|
76
|
+
appearance: none;
|
77
|
+
}
|
78
|
+
|
79
|
+
[type="search"],
|
80
|
+
.usa-search__input {
|
81
|
+
@include u-padding-y(0);
|
82
|
+
border-bottom-right-radius: 0;
|
83
|
+
border-right: none;
|
84
|
+
border-top-right-radius: 0;
|
85
|
+
box-sizing: border-box;
|
86
|
+
float: left;
|
87
|
+
font-size: font-size($theme-search-font-family, "xs");
|
88
|
+
height: units(4);
|
89
|
+
margin: 0;
|
90
|
+
}
|
91
|
+
|
92
|
+
.usa-search__submit-text {
|
93
|
+
@include sr-only;
|
94
|
+
|
95
|
+
@include at-media("mobile-lg") {
|
96
|
+
@include not-sr-only;
|
97
|
+
}
|
98
|
+
}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
.usa-section {
|
2
|
+
@include border-box-sizing;
|
3
|
+
@include u-padding-y($theme-site-margins-width);
|
4
|
+
|
5
|
+
@include at-media("tablet") {
|
6
|
+
@include u-padding-y(8);
|
7
|
+
}
|
8
|
+
}
|
9
|
+
|
10
|
+
.usa-section--light {
|
11
|
+
background-color: color("base-lightest");
|
12
|
+
}
|
13
|
+
|
14
|
+
.usa-section--dark {
|
15
|
+
background-color: color("primary-darker");
|
16
|
+
color: color("white");
|
17
|
+
|
18
|
+
h1,
|
19
|
+
h2,
|
20
|
+
h3,
|
21
|
+
h4,
|
22
|
+
h5,
|
23
|
+
h6 {
|
24
|
+
color: color("accent-cool");
|
25
|
+
}
|
26
|
+
|
27
|
+
p {
|
28
|
+
color: color("white");
|
29
|
+
}
|
30
|
+
|
31
|
+
a {
|
32
|
+
color: color("base-lighter");
|
33
|
+
|
34
|
+
&:hover {
|
35
|
+
color: color("white");
|
36
|
+
}
|
37
|
+
}
|
38
|
+
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
.usa-sidenav {
|
2
|
+
@include border-box-sizing;
|
3
|
+
@include nav-list("sidenav");
|
4
|
+
@include typeset($theme-sidenav-font-family, "sm", 3);
|
5
|
+
border-bottom: units(1px) solid color("base-lighter");
|
6
|
+
|
7
|
+
.grid-container & {
|
8
|
+
@include u-margin-x(-$theme-site-margins-mobile-width);
|
9
|
+
|
10
|
+
@include at-media("tablet") {
|
11
|
+
@include u-margin-x(0);
|
12
|
+
}
|
13
|
+
}
|
14
|
+
}
|
15
|
+
|
16
|
+
.usa-sidenav__sublist {
|
17
|
+
@include nav-sublist;
|
18
|
+
font-size: font-size($theme-sidenav-font-family, "xs");
|
19
|
+
}
|
@@ -1,17 +1,18 @@
|
|
1
1
|
.usa-skipnav {
|
2
|
+
@include border-box-sizing;
|
3
|
+
@include typeset;
|
4
|
+
@include typeset-link;
|
2
5
|
background: transparent;
|
3
|
-
color: $color-base;
|
4
6
|
left: 0;
|
5
|
-
padding:
|
7
|
+
padding: units(1) units(2);
|
6
8
|
position: absolute;
|
7
|
-
top: -
|
9
|
+
top: -3.8rem; // skipnav link height
|
8
10
|
transition: all 0.2s ease-in-out;
|
9
|
-
z-index: 100;
|
11
|
+
z-index: z-index(100);
|
10
12
|
|
11
13
|
&:focus {
|
12
|
-
background:
|
14
|
+
background: color("white");
|
13
15
|
left: 0;
|
14
|
-
outline: 0;
|
15
16
|
position: absolute;
|
16
17
|
top: 0;
|
17
18
|
transition: all 0.2s ease-in-out;
|
@@ -0,0 +1,33 @@
|
|
1
|
+
/* deprecated.scss
|
2
|
+
---
|
3
|
+
Occasionally the design system will deprecate
|
4
|
+
old variables or functionality. If we replace
|
5
|
+
the old functionality with something new, this is a
|
6
|
+
place to connect the old functionality to the
|
7
|
+
new functionality, in the service of better
|
8
|
+
continuity and backwards compatibility within a
|
9
|
+
major release cycle.
|
10
|
+
|
11
|
+
Note the USWDS version where we deprecated the
|
12
|
+
old functionality in a comment.
|
13
|
+
|
14
|
+
Be sure to update notifications.scss.
|
15
|
+
|
16
|
+
This file should started fresh at each
|
17
|
+
major version.
|
18
|
+
*/
|
19
|
+
|
20
|
+
// Deprecated in 2.2.0
|
21
|
+
$theme-navigation-width: $theme-header-min-width;
|
22
|
+
$theme-megamenu-logo-text-width: $theme-header-logo-text-width;
|
23
|
+
|
24
|
+
// Deprecated in 2.0.2
|
25
|
+
$theme-title-font-size: $theme-display-font-size;
|
26
|
+
|
27
|
+
@mixin title {
|
28
|
+
@include display;
|
29
|
+
}
|
30
|
+
|
31
|
+
@mixin typeset-title {
|
32
|
+
@include typeset-display;
|
33
|
+
}
|
@@ -0,0 +1,1323 @@
|
|
1
|
+
/*
|
2
|
+
========================================
|
3
|
+
Functions
|
4
|
+
----------------------------------------
|
5
|
+
*/
|
6
|
+
|
7
|
+
// The following vars need to be set
|
8
|
+
// here, before the rest of the system
|
9
|
+
// variables are set
|
10
|
+
|
11
|
+
$root-font-size: if($theme-respect-user-font-size, 100%, $theme-root-font-size);
|
12
|
+
|
13
|
+
$root-font-size-equiv: if(
|
14
|
+
$theme-respect-user-font-size,
|
15
|
+
16px,
|
16
|
+
$theme-root-font-size
|
17
|
+
);
|
18
|
+
|
19
|
+
/*
|
20
|
+
========================================
|
21
|
+
General-purpose functions
|
22
|
+
----------------------------------------
|
23
|
+
*/
|
24
|
+
|
25
|
+
/*
|
26
|
+
----------------------------------------
|
27
|
+
map-deep-get()
|
28
|
+
----------------------------------------
|
29
|
+
@author Hugo Giraudel
|
30
|
+
@access public
|
31
|
+
@param {Map} $map - Map
|
32
|
+
@param {Arglist} $keys - Key chain
|
33
|
+
@return {*} - Desired value
|
34
|
+
----------------------------------------
|
35
|
+
*/
|
36
|
+
|
37
|
+
@function map-deep-get($map, $keys...) {
|
38
|
+
@each $key in $keys {
|
39
|
+
$map: map-get($map, $key);
|
40
|
+
}
|
41
|
+
|
42
|
+
@return $map;
|
43
|
+
}
|
44
|
+
|
45
|
+
/*
|
46
|
+
----------------------------------------
|
47
|
+
strip-unit()
|
48
|
+
----------------------------------------
|
49
|
+
Remove the unit of a length
|
50
|
+
@author Hugo Giraudel
|
51
|
+
@param {Number} $number - Number to remove unit from
|
52
|
+
@return {Number} - Unitless number
|
53
|
+
----------------------------------------
|
54
|
+
*/
|
55
|
+
|
56
|
+
@function strip-unit($number) {
|
57
|
+
@if type-of($number) == "number" and not unitless($number) {
|
58
|
+
@return $number / ($number * 0 + 1);
|
59
|
+
}
|
60
|
+
|
61
|
+
@return $number;
|
62
|
+
}
|
63
|
+
|
64
|
+
/*
|
65
|
+
----------------------------------------
|
66
|
+
multi-cat()
|
67
|
+
----------------------------------------
|
68
|
+
Concatenate two lists
|
69
|
+
----------------------------------------
|
70
|
+
*/
|
71
|
+
|
72
|
+
@function multi-cat($list1, $list2) {
|
73
|
+
$this-list: ();
|
74
|
+
|
75
|
+
@each $e in $list1 {
|
76
|
+
@each $ee in $list2 {
|
77
|
+
$this-block: $e + $ee;
|
78
|
+
$this-list: join($this-list, $this-block);
|
79
|
+
}
|
80
|
+
}
|
81
|
+
|
82
|
+
@return $this-list;
|
83
|
+
}
|
84
|
+
|
85
|
+
/*
|
86
|
+
----------------------------------------
|
87
|
+
map-collect()
|
88
|
+
----------------------------------------
|
89
|
+
Collect multiple maps into a single
|
90
|
+
large map
|
91
|
+
source: https://gist.github.com/bigglesrocks/d75091700f8f2be5abfe
|
92
|
+
----------------------------------------
|
93
|
+
*/
|
94
|
+
|
95
|
+
@function map-collect($maps...) {
|
96
|
+
$collection: ();
|
97
|
+
|
98
|
+
@each $map in $maps {
|
99
|
+
$collection: map-merge($collection, $map);
|
100
|
+
}
|
101
|
+
|
102
|
+
@return $collection;
|
103
|
+
}
|
104
|
+
|
105
|
+
/*
|
106
|
+
----------------------------------------
|
107
|
+
smart-quote()
|
108
|
+
----------------------------------------
|
109
|
+
Quotes strings
|
110
|
+
Inspects `px`, `xs`, and `xl` numbers
|
111
|
+
Leaves bools as is
|
112
|
+
----------------------------------------
|
113
|
+
*/
|
114
|
+
|
115
|
+
@function smart-quote($value) {
|
116
|
+
@if type-of($value) == "string" {
|
117
|
+
@return quote($value);
|
118
|
+
}
|
119
|
+
|
120
|
+
@if type-of($value) == "number" and index(("px", "xl", "xs"), unit($value)) {
|
121
|
+
@return inspect($value);
|
122
|
+
}
|
123
|
+
|
124
|
+
@if type-of($value) == "color" {
|
125
|
+
@error 'Only use quoted color tokens in USWDS functions and mixins. '
|
126
|
+
+ 'See designsystem.digital.gov/design-tokens/color '
|
127
|
+
+ 'for more information.';
|
128
|
+
}
|
129
|
+
|
130
|
+
@return $value;
|
131
|
+
}
|
132
|
+
|
133
|
+
/*
|
134
|
+
----------------------------------------
|
135
|
+
remove()
|
136
|
+
----------------------------------------
|
137
|
+
Remove a value from a list
|
138
|
+
----------------------------------------
|
139
|
+
*/
|
140
|
+
|
141
|
+
@function remove($list, $value, $recursive: false) {
|
142
|
+
$result: ();
|
143
|
+
|
144
|
+
@for $i from 1 through length($list) {
|
145
|
+
@if type-of(nth($list, $i)) == list and $recursive {
|
146
|
+
$result: append($result, remove(nth($list, $i), $value, $recursive));
|
147
|
+
} @else if nth($list, $i) != $value {
|
148
|
+
$result: append($result, nth($list, $i));
|
149
|
+
}
|
150
|
+
}
|
151
|
+
|
152
|
+
@return $result;
|
153
|
+
}
|
154
|
+
|
155
|
+
/*
|
156
|
+
----------------------------------------
|
157
|
+
strunquote()
|
158
|
+
----------------------------------------
|
159
|
+
Unquote a string
|
160
|
+
----------------------------------------
|
161
|
+
*/
|
162
|
+
|
163
|
+
@function strunquote($value) {
|
164
|
+
@if type-of($value) == "string" {
|
165
|
+
$value: unquote($value);
|
166
|
+
}
|
167
|
+
|
168
|
+
@return $value;
|
169
|
+
}
|
170
|
+
|
171
|
+
/*
|
172
|
+
----------------------------------------
|
173
|
+
to-map()
|
174
|
+
----------------------------------------
|
175
|
+
Convert a single value to a USWDS
|
176
|
+
value map.
|
177
|
+
|
178
|
+
Candidate for deprecation if we remove
|
179
|
+
isReadable
|
180
|
+
----------------------------------------
|
181
|
+
*/
|
182
|
+
|
183
|
+
@function to-map($key, $values) {
|
184
|
+
$l: length($values);
|
185
|
+
|
186
|
+
@if $key == "noModifier" or $key == "noValue" {
|
187
|
+
$key: "";
|
188
|
+
}
|
189
|
+
|
190
|
+
@return (slug: $key, content: $values);
|
191
|
+
}
|
192
|
+
|
193
|
+
/*
|
194
|
+
----------------------------------------
|
195
|
+
base-to-map()
|
196
|
+
----------------------------------------
|
197
|
+
Convert a single base to a USWDS
|
198
|
+
value map.
|
199
|
+
|
200
|
+
Candidate for deprecation if we remove
|
201
|
+
isReadable
|
202
|
+
----------------------------------------
|
203
|
+
*/
|
204
|
+
|
205
|
+
@function base-to-map($values) {
|
206
|
+
$l: length($values);
|
207
|
+
|
208
|
+
@if $l == 1 or nth($values, $l) != isReadable {
|
209
|
+
@return (slug: $values, isReadable: true);
|
210
|
+
} @else {
|
211
|
+
$values: remove($values, isReadable);
|
212
|
+
|
213
|
+
@return (slug: unquote(nth($values, 1)), isReadable: true);
|
214
|
+
}
|
215
|
+
}
|
216
|
+
|
217
|
+
/*
|
218
|
+
----------------------------------------
|
219
|
+
ns()
|
220
|
+
----------------------------------------
|
221
|
+
Add a namesspace of $type if that
|
222
|
+
namespace is set to output
|
223
|
+
----------------------------------------
|
224
|
+
*/
|
225
|
+
|
226
|
+
@function ns($type) {
|
227
|
+
$type: smart-quote($type);
|
228
|
+
|
229
|
+
@if not map-deep-get($theme-namespace, $type, output) {
|
230
|
+
@return "";
|
231
|
+
}
|
232
|
+
|
233
|
+
@return map-deep-get($theme-namespace, $type, namespace);
|
234
|
+
}
|
235
|
+
|
236
|
+
/*
|
237
|
+
----------------------------------------
|
238
|
+
de-list()
|
239
|
+
----------------------------------------
|
240
|
+
Transform a one-element list or arglist
|
241
|
+
into that single element.
|
242
|
+
----------------------------------------
|
243
|
+
(1) => 1
|
244
|
+
((1)) => (1)
|
245
|
+
----------------------------------------
|
246
|
+
*/
|
247
|
+
|
248
|
+
@function de-list($value) {
|
249
|
+
$types: ("list", "arglist");
|
250
|
+
|
251
|
+
@if not index($types, type-of($value)) {
|
252
|
+
@return $value;
|
253
|
+
}
|
254
|
+
|
255
|
+
$output: if(length($value) == 1, nth($value, 1), $value);
|
256
|
+
|
257
|
+
@return $output;
|
258
|
+
}
|
259
|
+
|
260
|
+
/*
|
261
|
+
----------------------------------------
|
262
|
+
unpack()
|
263
|
+
----------------------------------------
|
264
|
+
Create lists of single items from lists
|
265
|
+
of lists.
|
266
|
+
----------------------------------------
|
267
|
+
(1, (2.1, 2.2), 3) -->
|
268
|
+
(1, 2.1, 2.2, 3)
|
269
|
+
----------------------------------------
|
270
|
+
*/
|
271
|
+
|
272
|
+
@function unpack($value) {
|
273
|
+
$output: ();
|
274
|
+
|
275
|
+
@if length($value) == 0 {
|
276
|
+
@return $value;
|
277
|
+
}
|
278
|
+
|
279
|
+
@each $i in $value {
|
280
|
+
@if type-of($i) == "list" {
|
281
|
+
@each $ii in $i {
|
282
|
+
$output: append($output, $ii, comma);
|
283
|
+
}
|
284
|
+
} @else {
|
285
|
+
$output: append($output, $i, comma);
|
286
|
+
}
|
287
|
+
}
|
288
|
+
|
289
|
+
@return de-list($output);
|
290
|
+
}
|
291
|
+
|
292
|
+
/*
|
293
|
+
----------------------------------------
|
294
|
+
get-last()
|
295
|
+
----------------------------------------
|
296
|
+
Return the last item of a list,
|
297
|
+
Return null if the value is null
|
298
|
+
----------------------------------------
|
299
|
+
*/
|
300
|
+
|
301
|
+
@function get-last($props) {
|
302
|
+
$length: length($props);
|
303
|
+
$last: if($length == 0, null, nth($props, -1));
|
304
|
+
|
305
|
+
@return $last;
|
306
|
+
}
|
307
|
+
|
308
|
+
/*
|
309
|
+
----------------------------------------
|
310
|
+
has-important()
|
311
|
+
----------------------------------------
|
312
|
+
Check to see if `!important` is
|
313
|
+
being passed in a mixin's props
|
314
|
+
----------------------------------------
|
315
|
+
*/
|
316
|
+
|
317
|
+
@function has-important($props) {
|
318
|
+
$props: de-list($props);
|
319
|
+
|
320
|
+
@if get-last($props) == "!important" {
|
321
|
+
@return true;
|
322
|
+
}
|
323
|
+
|
324
|
+
@return false;
|
325
|
+
}
|
326
|
+
|
327
|
+
/*
|
328
|
+
----------------------------------------
|
329
|
+
append-important()
|
330
|
+
----------------------------------------
|
331
|
+
Append `!important` to a list
|
332
|
+
----------------------------------------
|
333
|
+
*/
|
334
|
+
|
335
|
+
@function append-important($source, $destination) {
|
336
|
+
@if get-last($source) == "!important" {
|
337
|
+
@return append($destination, !important, comma);
|
338
|
+
}
|
339
|
+
|
340
|
+
@return $destination;
|
341
|
+
}
|
342
|
+
|
343
|
+
/*
|
344
|
+
----------------------------------------
|
345
|
+
spacing-multiple()
|
346
|
+
----------------------------------------
|
347
|
+
Converts a spacing unit multiple into
|
348
|
+
the desired final units (currently rem)
|
349
|
+
----------------------------------------
|
350
|
+
*/
|
351
|
+
|
352
|
+
@function spacing-multiple($unit) {
|
353
|
+
$grid-to-rem: ($system-spacing-grid-base * $unit) / $root-font-size-equiv *
|
354
|
+
1rem;
|
355
|
+
|
356
|
+
@return $grid-to-rem;
|
357
|
+
}
|
358
|
+
|
359
|
+
/*
|
360
|
+
----------------------------------------
|
361
|
+
rem-to-px()
|
362
|
+
----------------------------------------
|
363
|
+
Converts a value in rem to a value in px
|
364
|
+
----------------------------------------
|
365
|
+
*/
|
366
|
+
|
367
|
+
@function rem-to-px($value-in-rem) {
|
368
|
+
@if unit($value-in-rem) == "rem" {
|
369
|
+
$rem-to-px: ($value-in-rem / 1rem) * $root-font-size-equiv;
|
370
|
+
@return $rem-to-px;
|
371
|
+
}
|
372
|
+
@if unit($value-in-rem) != "px" {
|
373
|
+
@error 'This value must be in either px or rem';
|
374
|
+
}
|
375
|
+
@return $value-in-rem;
|
376
|
+
}
|
377
|
+
|
378
|
+
/*
|
379
|
+
----------------------------------------
|
380
|
+
rem-to-user-em()
|
381
|
+
----------------------------------------
|
382
|
+
Converts a value in rem to a value in
|
383
|
+
[user-settings] em for use in media
|
384
|
+
queries
|
385
|
+
----------------------------------------
|
386
|
+
*/
|
387
|
+
|
388
|
+
@function rem-to-user-em($grid-in-rem) {
|
389
|
+
$rem-to-user-em: ($grid-in-rem / 1rem) * 1em;
|
390
|
+
|
391
|
+
@return $rem-to-user-em;
|
392
|
+
}
|
393
|
+
|
394
|
+
/*
|
395
|
+
----------------------------------------
|
396
|
+
validate-typeface-token()
|
397
|
+
----------------------------------------
|
398
|
+
Check to see if a typeface-token exists.
|
399
|
+
Throw an error if a passed token does
|
400
|
+
not exist in the typeface-token map.
|
401
|
+
----------------------------------------
|
402
|
+
*/
|
403
|
+
|
404
|
+
@function validate-typeface-token($typeface-token) {
|
405
|
+
@if not map-has-key($all-typeface-tokens, $typeface-token) {
|
406
|
+
@error '`#{$typeface-token}` is not a valid typeface token. '
|
407
|
+
+ 'Valid tokens: #{map-keys($all-typeface-tokens)} ';
|
408
|
+
}
|
409
|
+
|
410
|
+
@return $typeface-token;
|
411
|
+
}
|
412
|
+
|
413
|
+
/*
|
414
|
+
----------------------------------------
|
415
|
+
cap-height()
|
416
|
+
----------------------------------------
|
417
|
+
Get the cap height of a valid typeface
|
418
|
+
----------------------------------------
|
419
|
+
*/
|
420
|
+
|
421
|
+
@function cap-height($typeface-token) {
|
422
|
+
@if not $typeface-token {
|
423
|
+
@return false;
|
424
|
+
}
|
425
|
+
|
426
|
+
$typeface-token: validate-typeface-token($typeface-token);
|
427
|
+
$token-data: map-get($all-typeface-tokens, $typeface-token);
|
428
|
+
@return map-get($token-data, "cap-height");
|
429
|
+
}
|
430
|
+
|
431
|
+
/*
|
432
|
+
----------------------------------------
|
433
|
+
px-to-rem()
|
434
|
+
----------------------------------------
|
435
|
+
Converts a value in px to a value in rem
|
436
|
+
----------------------------------------
|
437
|
+
*/
|
438
|
+
|
439
|
+
@function px-to-rem($pixels) {
|
440
|
+
@if not $pixels {
|
441
|
+
@return false;
|
442
|
+
}
|
443
|
+
$px-to-rem: ($pixels / $root-font-size-equiv) * 1rem;
|
444
|
+
$px-to-rem: round($px-to-rem * 100) / 100;
|
445
|
+
|
446
|
+
@return $px-to-rem;
|
447
|
+
}
|
448
|
+
|
449
|
+
/*
|
450
|
+
----------------------------------------
|
451
|
+
normalize-type-scale()
|
452
|
+
----------------------------------------
|
453
|
+
Normalizes a specific face's optical size
|
454
|
+
to a set target
|
455
|
+
----------------------------------------
|
456
|
+
*/
|
457
|
+
|
458
|
+
@function normalize-type-scale($cap-height, $scale) {
|
459
|
+
@if not $cap-height {
|
460
|
+
@return false;
|
461
|
+
}
|
462
|
+
|
463
|
+
$this-scale: $system-base-cap-height * strip-unit($scale) / $cap-height * 1px;
|
464
|
+
|
465
|
+
@return px-to-rem($this-scale);
|
466
|
+
}
|
467
|
+
|
468
|
+
/*
|
469
|
+
----------------------------------------
|
470
|
+
utility-font()
|
471
|
+
----------------------------------------
|
472
|
+
Get a normalized font-size in rem from
|
473
|
+
a family and a type size in either
|
474
|
+
system scale or project scale
|
475
|
+
----------------------------------------
|
476
|
+
Not the public-facing function.
|
477
|
+
Used for building the utilities and
|
478
|
+
withholds certain errors.
|
479
|
+
----------------------------------------
|
480
|
+
*/
|
481
|
+
|
482
|
+
@function utility-font($family, $scale) {
|
483
|
+
@if not map-has-key($project-cap-heights, $family) {
|
484
|
+
@error '#{$family} is not a valid font family token. '
|
485
|
+
+ 'Valid tokens: #{map-keys($project-cap-heights)}';
|
486
|
+
}
|
487
|
+
|
488
|
+
$quote-scale: smart-quote($scale);
|
489
|
+
|
490
|
+
@if not map-get($all-type-scale, $quote-scale) {
|
491
|
+
@error '`#{$scale}` is not a valid font scale token. '
|
492
|
+
+ 'Valid tokens: #{map-keys($all-type-scale)}';
|
493
|
+
}
|
494
|
+
|
495
|
+
$this-cap: map-get($project-cap-heights, $family);
|
496
|
+
$this-scale: map-get($all-type-scale, $quote-scale);
|
497
|
+
|
498
|
+
@if not $this-scale and $this-cap {
|
499
|
+
@return false;
|
500
|
+
}
|
501
|
+
|
502
|
+
@return normalize-type-scale($this-cap, $this-scale);
|
503
|
+
}
|
504
|
+
|
505
|
+
/*
|
506
|
+
----------------------------------------
|
507
|
+
line-height()
|
508
|
+
lh()
|
509
|
+
----------------------------------------
|
510
|
+
Get a normalized line-height from
|
511
|
+
a family and a line-height scale unit
|
512
|
+
----------------------------------------
|
513
|
+
*/
|
514
|
+
|
515
|
+
@function lh($props...) {
|
516
|
+
$props: unpack($props);
|
517
|
+
|
518
|
+
@if not(length($props) == 2) {
|
519
|
+
@error 'lh() needs both a valid face and line height token '
|
520
|
+
+ 'in the format `lh(FACE, HEIGHT)`.';
|
521
|
+
}
|
522
|
+
|
523
|
+
$family: smart-quote(nth($props, 1));
|
524
|
+
$scale: smart-quote(nth($props, 2));
|
525
|
+
|
526
|
+
@if not map-has-key($project-cap-heights, $family) {
|
527
|
+
@error '#{$family} is not a valid font family token. '
|
528
|
+
+ 'Valid tokens: #{map-keys($project-cap-heights)}';
|
529
|
+
}
|
530
|
+
|
531
|
+
@if not map-get($system-line-height, $scale) {
|
532
|
+
@error '`#{$scale}` is not a valid line-height token. '
|
533
|
+
+ 'Valid tokens: #{map-keys($system-line-height)}';
|
534
|
+
}
|
535
|
+
|
536
|
+
@if not map-get($project-cap-heights, $family) {
|
537
|
+
@return false;
|
538
|
+
}
|
539
|
+
|
540
|
+
$this-cap: map-get($project-cap-heights, $family);
|
541
|
+
$this-line-height: map-get($system-line-height, $scale);
|
542
|
+
$normalized-line-height: $this-line-height /
|
543
|
+
($system-base-cap-height / $this-cap);
|
544
|
+
$normalized-line-height: round($normalized-line-height * 10) / 10;
|
545
|
+
|
546
|
+
@return $normalized-line-height;
|
547
|
+
}
|
548
|
+
|
549
|
+
@function line-height($props...) {
|
550
|
+
@return lh($props...);
|
551
|
+
}
|
552
|
+
|
553
|
+
/*
|
554
|
+
----------------------------------------
|
555
|
+
convert-to-font-type()
|
556
|
+
----------------------------------------
|
557
|
+
Converts a font-role token into a
|
558
|
+
font-type token. Leaves font-type tokens
|
559
|
+
unchanged.
|
560
|
+
----------------------------------------
|
561
|
+
*/
|
562
|
+
|
563
|
+
@function convert-to-font-type($token) {
|
564
|
+
@if map-has-key($project-font-role-tokens, $token) {
|
565
|
+
@return map-get($project-font-role-tokens, $token);
|
566
|
+
}
|
567
|
+
|
568
|
+
@return $token;
|
569
|
+
}
|
570
|
+
|
571
|
+
/*
|
572
|
+
----------------------------------------
|
573
|
+
get-font-stack()
|
574
|
+
----------------------------------------
|
575
|
+
Get a font stack from a style- or
|
576
|
+
role-based font token.
|
577
|
+
----------------------------------------
|
578
|
+
*/
|
579
|
+
|
580
|
+
@function get-font-stack($token) {
|
581
|
+
// Start by converting to a type token (sans, serif, etc)
|
582
|
+
$type-token: convert-to-font-type($token);
|
583
|
+
$output-display-name: true;
|
584
|
+
$this-stack: null;
|
585
|
+
// Get the font type metadata
|
586
|
+
$this-font-map: map-get($project-font-type-tokens, $type-token);
|
587
|
+
// Only output if the font type has an assigned typeface token
|
588
|
+
@if map-get($this-font-map, "typeface-token") {
|
589
|
+
$this-font-token: map-get($this-font-map, "typeface-token");
|
590
|
+
// Get the typeface metadata
|
591
|
+
$this-typeface-data: map-get($all-typeface-tokens, $this-font-token);
|
592
|
+
$this-name: map-get($this-typeface-data, "display-name");
|
593
|
+
// If it's a system typeface, don't output the display name
|
594
|
+
@if map-has-key($this-typeface-data, "system-font") {
|
595
|
+
$output-display-name: false;
|
596
|
+
}
|
597
|
+
// If there's a custom stack, use it and output the display name
|
598
|
+
@if map-get($this-font-map, "custom-stack") {
|
599
|
+
$this-stack: map-get($this-font-map, "custom-stack");
|
600
|
+
$output-display-name: true;
|
601
|
+
}
|
602
|
+
// Otherwise, just get the token's default stack
|
603
|
+
@else {
|
604
|
+
$this-stack: map-deep-get(
|
605
|
+
$all-typeface-tokens,
|
606
|
+
$this-font-token,
|
607
|
+
"stack"
|
608
|
+
);
|
609
|
+
}
|
610
|
+
// If the typeface has no display name (system fonts), don't output the display name
|
611
|
+
@if map-get($this-typeface-data, "display-name") == null {
|
612
|
+
$output-display-name: false;
|
613
|
+
}
|
614
|
+
@if not $output-display-name {
|
615
|
+
@return #{$this-stack};
|
616
|
+
}
|
617
|
+
@return unquote("#{$this-name}, #{$this-stack}");
|
618
|
+
}
|
619
|
+
@return false;
|
620
|
+
}
|
621
|
+
|
622
|
+
/*
|
623
|
+
----------------------------------------
|
624
|
+
get-typeface-token()
|
625
|
+
----------------------------------------
|
626
|
+
Get a typeface token from a font-type or
|
627
|
+
font-role token.
|
628
|
+
----------------------------------------
|
629
|
+
*/
|
630
|
+
|
631
|
+
@function get-typeface-token($font-token) {
|
632
|
+
$this-token: $font-token;
|
633
|
+
@if map-has-key($project-font-role-tokens, $font-token) {
|
634
|
+
$this-token: map-get($project-font-role-tokens, $font-token);
|
635
|
+
}
|
636
|
+
@return map-deep-get(
|
637
|
+
$project-font-type-tokens,
|
638
|
+
$this-token,
|
639
|
+
"typeface-token"
|
640
|
+
);
|
641
|
+
}
|
642
|
+
|
643
|
+
/*
|
644
|
+
----------------------------------------
|
645
|
+
get-system-color()
|
646
|
+
----------------------------------------
|
647
|
+
Derive a system color from its
|
648
|
+
family, value, and vivid or a passed
|
649
|
+
variable that is, itself, a list
|
650
|
+
----------------------------------------
|
651
|
+
*/
|
652
|
+
|
653
|
+
@function get-system-color(
|
654
|
+
$color-family: false,
|
655
|
+
$color-grade: false,
|
656
|
+
$color-variant: false
|
657
|
+
) {
|
658
|
+
// If the arg being passed to the fn
|
659
|
+
// is a variable defined as a list,
|
660
|
+
// $color-family will contain this
|
661
|
+
// entire list, and needs to be
|
662
|
+
// unpacked.
|
663
|
+
// ex:
|
664
|
+
// in settings:
|
665
|
+
// $theme-color-primary.'dark': 'blue', 70
|
666
|
+
// in the theme colors map:
|
667
|
+
// $color-primary-dark: get-system-color($theme-color-primary.'dark'),
|
668
|
+
|
669
|
+
@if type-of($color-family) == "list" {
|
670
|
+
@if length($color-family) > 2 {
|
671
|
+
$color-variant: nth($color-family, 3);
|
672
|
+
}
|
673
|
+
$color-grade: nth($color-family, 2);
|
674
|
+
$color-family: nth($color-family, 1);
|
675
|
+
}
|
676
|
+
|
677
|
+
$color-family: smart-quote($color-family);
|
678
|
+
$color-variant: smart-quote($color-variant);
|
679
|
+
|
680
|
+
// If the arg being passed to the fn
|
681
|
+
// is false, it should output as `false`
|
682
|
+
// to preserve a false value in the
|
683
|
+
// target map
|
684
|
+
// ex:
|
685
|
+
// in settings:
|
686
|
+
// $theme-color-primary.'darkest': false;
|
687
|
+
// in the theme colors map:
|
688
|
+
// 'darkest': get-system-color($theme-color-primary.'darkest'),
|
689
|
+
// 'darkest': false, // is the desired outcome
|
690
|
+
// TODO: should a false-pass color function be a separate fn?
|
691
|
+
|
692
|
+
@if not $color-family {
|
693
|
+
@return false;
|
694
|
+
}
|
695
|
+
|
696
|
+
@if $color-variant {
|
697
|
+
$output: map-deep-get(
|
698
|
+
$system-colors,
|
699
|
+
$color-family,
|
700
|
+
$color-variant,
|
701
|
+
$color-grade
|
702
|
+
);
|
703
|
+
|
704
|
+
@return $output;
|
705
|
+
}
|
706
|
+
|
707
|
+
$output: map-deep-get($system-colors, $color-family, $color-grade);
|
708
|
+
|
709
|
+
@return $output;
|
710
|
+
}
|
711
|
+
|
712
|
+
/*
|
713
|
+
----------------------------------------
|
714
|
+
system-type-scale()
|
715
|
+
----------------------------------------
|
716
|
+
Get a value from the system type scale
|
717
|
+
----------------------------------------
|
718
|
+
*/
|
719
|
+
|
720
|
+
@function system-type-scale($scale) {
|
721
|
+
$scale: smart-quote($scale);
|
722
|
+
|
723
|
+
@if not $scale {
|
724
|
+
@return false;
|
725
|
+
}
|
726
|
+
|
727
|
+
@if not map-has-key($system-type-scale, $scale) {
|
728
|
+
@error '`#{$scale}` is not a valid type scale token. '
|
729
|
+
+ 'Valid tokens: #{map-keys($system-type-scale)}';
|
730
|
+
}
|
731
|
+
|
732
|
+
@return map-get($system-type-scale, $scale);
|
733
|
+
}
|
734
|
+
|
735
|
+
/*
|
736
|
+
----------------------------------------
|
737
|
+
calc-gap-offset()
|
738
|
+
----------------------------------------
|
739
|
+
Calculate a valid uswds unit that is
|
740
|
+
half the width of a given unit, for
|
741
|
+
calculating gap offset in the layout
|
742
|
+
grid.
|
743
|
+
----------------------------------------
|
744
|
+
*/
|
745
|
+
|
746
|
+
@function calc-gap-offset($gap-size) {
|
747
|
+
$gap-size: smart-quote($gap-size);
|
748
|
+
|
749
|
+
@if not map-has-key($spacing-to-value, $gap-size) {
|
750
|
+
@error '`#{$gap-size}` is not a valid USWDS gap size token.';
|
751
|
+
}
|
752
|
+
|
753
|
+
$numeric-eq: map-get($spacing-to-value, $gap-size);
|
754
|
+
$numeric-eq-half: inspect($numeric-eq / 2);
|
755
|
+
|
756
|
+
@if not map-has-key($spacing-to-token, $numeric-eq-half) {
|
757
|
+
@error '`#{$gap-size}` is not a valid USWDS gap size token. '
|
758
|
+
+ 'Column gaps need to have a standard size half their width.';
|
759
|
+
}
|
760
|
+
|
761
|
+
@return map-get($spacing-to-token, $numeric-eq-half);
|
762
|
+
}
|
763
|
+
|
764
|
+
/*
|
765
|
+
----------------------------------------
|
766
|
+
get-standard-values()
|
767
|
+
----------------------------------------
|
768
|
+
Gets a map of USWDS standard values
|
769
|
+
for a property
|
770
|
+
----------------------------------------
|
771
|
+
*/
|
772
|
+
|
773
|
+
@function get-standard-values($property) {
|
774
|
+
@return map-deep-get($system-properties, $property, standard);
|
775
|
+
}
|
776
|
+
|
777
|
+
/*
|
778
|
+
----------------------------------------
|
779
|
+
number-to-token()
|
780
|
+
----------------------------------------
|
781
|
+
Converts an integer or numeric value
|
782
|
+
into a system value
|
783
|
+
|
784
|
+
Ex: 0.5 --> '05'
|
785
|
+
-1px --> 'neg-1px'
|
786
|
+
----------------------------------------
|
787
|
+
*/
|
788
|
+
|
789
|
+
@function number-to-token($number) {
|
790
|
+
$number: inspect($number);
|
791
|
+
|
792
|
+
@if not map-has-key($number-to-value, $number) {
|
793
|
+
@return false;
|
794
|
+
}
|
795
|
+
|
796
|
+
@return map-get($number-to-value, $number);
|
797
|
+
}
|
798
|
+
|
799
|
+
/*
|
800
|
+
----------------------------------------
|
801
|
+
columns()
|
802
|
+
----------------------------------------
|
803
|
+
outputs a grid-col number based on
|
804
|
+
the number of desired columns in the
|
805
|
+
12-column grid
|
806
|
+
|
807
|
+
Ex: columns(2) --> 6
|
808
|
+
grid-col(columns(2))
|
809
|
+
----------------------------------------
|
810
|
+
*/
|
811
|
+
|
812
|
+
@function columns($number) {
|
813
|
+
$options: "auto", "fill";
|
814
|
+
$number: smart-quote($number);
|
815
|
+
|
816
|
+
@if index($options, $number) {
|
817
|
+
@return $number;
|
818
|
+
}
|
819
|
+
@if 12 % $number != 0 {
|
820
|
+
@error '`#{$number}` must be a divisor of 12.';
|
821
|
+
}
|
822
|
+
$columns: 12 / $number;
|
823
|
+
@return $columns;
|
824
|
+
}
|
825
|
+
|
826
|
+
/*
|
827
|
+
----------------------------------------
|
828
|
+
get-uswds-value()
|
829
|
+
----------------------------------------
|
830
|
+
Finds and outputs a value from the
|
831
|
+
USWDS standard values.
|
832
|
+
|
833
|
+
Used to build other standard utility
|
834
|
+
functions and mixins.
|
835
|
+
----------------------------------------
|
836
|
+
*/
|
837
|
+
|
838
|
+
@function get-uswds-value($property, $value...) {
|
839
|
+
@if type-of($value) == "arglist" and nth($value, 1) == override {
|
840
|
+
@return nth($value, 2);
|
841
|
+
}
|
842
|
+
|
843
|
+
$value: nth($value, 1);
|
844
|
+
$converted: number-to-token($value);
|
845
|
+
$quoted-value: if(
|
846
|
+
$converted,
|
847
|
+
smart-quote($converted),
|
848
|
+
smart-quote(nth($value, 1))
|
849
|
+
);
|
850
|
+
$our-standard-values: map-deep-get($system-properties, $property, standard);
|
851
|
+
$our-extended-values: map-deep-get($system-properties, $property, extended);
|
852
|
+
|
853
|
+
@if map-has-key($our-standard-values, $quoted-value) {
|
854
|
+
$output: map-get($our-standard-values, $quoted-value);
|
855
|
+
|
856
|
+
@if not $output {
|
857
|
+
@if $theme-show-compile-warnings {
|
858
|
+
@error '`#{$value}` is set as a `false` value '
|
859
|
+
+ 'for the #{$property} property in your project settings '
|
860
|
+
+ 'and will not output properly. '
|
861
|
+
+ 'Set the value of `#{$value}` in project settings.';
|
862
|
+
}
|
863
|
+
}
|
864
|
+
|
865
|
+
@return $output;
|
866
|
+
}
|
867
|
+
|
868
|
+
@if map-has-key($our-extended-values, $quoted-value) {
|
869
|
+
@if $theme-show-compile-warnings {
|
870
|
+
@warn '`#{$value}` is an extended USWDS `#{$property}` token. '
|
871
|
+
+ 'This is OK, but only components built with standard tokens can be accepted back into the system. '
|
872
|
+
+ 'Standard `#{$property}` values: #{map-keys($our-standard-values)}';
|
873
|
+
}
|
874
|
+
|
875
|
+
@return map-get($our-extended-values, $quoted-value);
|
876
|
+
}
|
877
|
+
|
878
|
+
// TODO: what are these last two cases? Evaluate.
|
879
|
+
@if not(type-of($value) == "number" and not unitless($value)) {
|
880
|
+
@error '`#{$value}` is not a valid `#{$property}` token. '
|
881
|
+
+ 'You should correct this. Standard `#{$property}` tokens: '
|
882
|
+
+ ' #{map-keys($our-standard-values)}';
|
883
|
+
}
|
884
|
+
|
885
|
+
@if $theme-show-compile-warnings {
|
886
|
+
@warn '`#{$value}` is not a USWDS `#{$property}` token. '
|
887
|
+
+ 'This is OK, but only components built with standard '
|
888
|
+
+ 'tokens can be accepted back into the system. '
|
889
|
+
+ 'Standard `#{$property}` values: #{map-keys($our-standard-values)}';
|
890
|
+
}
|
891
|
+
|
892
|
+
@return $value;
|
893
|
+
}
|
894
|
+
|
895
|
+
/*
|
896
|
+
----------------------------------------
|
897
|
+
color()
|
898
|
+
----------------------------------------
|
899
|
+
Derive a color from a color shortcode
|
900
|
+
----------------------------------------
|
901
|
+
*/
|
902
|
+
|
903
|
+
@function color($value, $flags...) {
|
904
|
+
$value: unpack($value);
|
905
|
+
|
906
|
+
// Non-token colors may be passed with specific flags
|
907
|
+
@if type-of($value) == color {
|
908
|
+
// override or set-theme will allow any color
|
909
|
+
@if index($flags, override) or index($flags, set-theme) {
|
910
|
+
// override + no-warn will skip warnings
|
911
|
+
@if index($flags, no-warn) {
|
912
|
+
@return $value;
|
913
|
+
}
|
914
|
+
|
915
|
+
@if $theme-show-compile-warnings {
|
916
|
+
@warn 'Override: `#{$value}` is not a USWDS color token.';
|
917
|
+
}
|
918
|
+
|
919
|
+
@return $value;
|
920
|
+
}
|
921
|
+
}
|
922
|
+
|
923
|
+
// False values may be passed through when setting theme colors
|
924
|
+
@if $value == false {
|
925
|
+
@if index($flags, set-theme) {
|
926
|
+
@return $value;
|
927
|
+
}
|
928
|
+
}
|
929
|
+
|
930
|
+
// Now, any value should be evaluated as a token
|
931
|
+
|
932
|
+
$value: smart-quote($value);
|
933
|
+
|
934
|
+
@if map-has-key($system-color-shortcodes, $value) {
|
935
|
+
$our-color: map-get($system-color-shortcodes, $value);
|
936
|
+
@if $our-color == false {
|
937
|
+
@error '`#{$value}` is a color that does not exist '
|
938
|
+
+ 'or is set to false.';
|
939
|
+
}
|
940
|
+
@return $our-color;
|
941
|
+
}
|
942
|
+
|
943
|
+
// If we're using the theme flag, $project-color-shortcodes has not yet been set
|
944
|
+
@if not index($flags, set-theme) {
|
945
|
+
@if map-has-key($project-color-shortcodes, $value) {
|
946
|
+
$our-color: (map-get($project-color-shortcodes, $value));
|
947
|
+
@if $our-color == false {
|
948
|
+
@error '`#{$value}` is a color that does not exist '
|
949
|
+
+ 'or is set to false.';
|
950
|
+
}
|
951
|
+
@return $our-color;
|
952
|
+
}
|
953
|
+
}
|
954
|
+
|
955
|
+
@error '`#{$value}` is not a valid USWDS color token. '
|
956
|
+
+ 'See designsystem.digital.gov/design-tokens/color '
|
957
|
+
+ 'for more information.';
|
958
|
+
}
|
959
|
+
|
960
|
+
/*
|
961
|
+
----------------------------------------
|
962
|
+
advanced-color()
|
963
|
+
----------------------------------------
|
964
|
+
Derive a color from a color triplet:
|
965
|
+
[family], [grade], [variant]
|
966
|
+
----------------------------------------
|
967
|
+
*/
|
968
|
+
|
969
|
+
// color() can have a 1, 2, or 3 arguments passed to it:
|
970
|
+
//
|
971
|
+
// [family]
|
972
|
+
// ex: color('primary')
|
973
|
+
// - the default in a theme palette family
|
974
|
+
//
|
975
|
+
// [family], [grade]
|
976
|
+
// ex: color('red', 50)
|
977
|
+
// - a standard system color
|
978
|
+
// ex: color('accent-warm', 'light')
|
979
|
+
// - a standard theme color
|
980
|
+
// ex: color('primary', 'vivid')
|
981
|
+
// - in theme colors, 'vivid' is considered a grade
|
982
|
+
//
|
983
|
+
// [family], [grade], [vivid]
|
984
|
+
// ex: color('red', 50, 'vivid')
|
985
|
+
// - a vivid system color
|
986
|
+
// - only system colors required three arguments
|
987
|
+
|
988
|
+
@function advanced-color(
|
989
|
+
$color-family: false,
|
990
|
+
$color-grade: false,
|
991
|
+
$color-variant: false
|
992
|
+
) {
|
993
|
+
// Convert any arglists into lists
|
994
|
+
$color-family: if(
|
995
|
+
type-of($color-family) == "arglist",
|
996
|
+
unpack($color-family),
|
997
|
+
$color-family
|
998
|
+
);
|
999
|
+
|
1000
|
+
// If $color-family is a list, color() had a variable
|
1001
|
+
// passed to it, and args need to be re-set with the
|
1002
|
+
// values from the $color-family list:
|
1003
|
+
@if type-of($color-family) == "list" {
|
1004
|
+
@if length($color-family) > 2 {
|
1005
|
+
$color-variant: nth($color-family, 3);
|
1006
|
+
}
|
1007
|
+
$color-grade: nth($color-family, 2);
|
1008
|
+
$color-family: nth($color-family, 1);
|
1009
|
+
}
|
1010
|
+
|
1011
|
+
// Set initial state of vars
|
1012
|
+
$color-family: smart-quote($color-family);
|
1013
|
+
$color-grade: smart-quote($color-grade);
|
1014
|
+
$color-variant: smart-quote($color-variant);
|
1015
|
+
|
1016
|
+
// @debug '#{$color-family}: #{type-of($color-family)}, #{$color-grade}: #{type-of($color-grade)}, #{$color-variant}: #{type-of($color-variant)}' ;
|
1017
|
+
|
1018
|
+
// If there are no args, throw an error
|
1019
|
+
@if not $color-family {
|
1020
|
+
@error 'Include a color in the form [family], [grade], [vivid]';
|
1021
|
+
}
|
1022
|
+
|
1023
|
+
// If the grade is a number, it's a system color
|
1024
|
+
// ex: ('red', 50)
|
1025
|
+
@if type-of($color-grade) == "number" {
|
1026
|
+
@return get-system-color($color-family, $color-grade, $color-variant);
|
1027
|
+
}
|
1028
|
+
|
1029
|
+
// non-number grades are associated with non-default theme colors
|
1030
|
+
// ex: ('base', 'darker')
|
1031
|
+
// default theme colors have no grade
|
1032
|
+
// ex: ('base')
|
1033
|
+
@if map-has-key($all-project-colors, $color-family) {
|
1034
|
+
@if not
|
1035
|
+
map-has-key(map-get($all-project-colors, $color-family), $color-grade)
|
1036
|
+
{
|
1037
|
+
@error '`#{$color-grade}` is not a valid grade of `#{$color-family}`. '
|
1038
|
+
+ 'Valid grades: '
|
1039
|
+
+ '#{map-keys(map-get($all-project-colors, $color-family))}';
|
1040
|
+
}
|
1041
|
+
} @else {
|
1042
|
+
@error '`#{$color-family}` is not a valid theme family token. '
|
1043
|
+
+ 'Valid family tokens: #{map-keys($all-project-colors)}';
|
1044
|
+
}
|
1045
|
+
@return map-deep-get($all-project-colors, $color-family, $color-grade);
|
1046
|
+
}
|
1047
|
+
|
1048
|
+
/*
|
1049
|
+
----------------------------------------
|
1050
|
+
units()
|
1051
|
+
----------------------------------------
|
1052
|
+
Converts a spacing unit into
|
1053
|
+
the desired final units (currently rem)
|
1054
|
+
----------------------------------------
|
1055
|
+
*/
|
1056
|
+
|
1057
|
+
@function units($value) {
|
1058
|
+
$converted: if(
|
1059
|
+
type-of($value) == "string",
|
1060
|
+
quote($value),
|
1061
|
+
number-to-token($value)
|
1062
|
+
);
|
1063
|
+
|
1064
|
+
@if not map-has-key($project-spacing-standard, $converted) {
|
1065
|
+
@error '`#{$value}` is not a valid spacing unit token. '
|
1066
|
+
+ 'Valid spacing unit tokens: '
|
1067
|
+
+ '#{map-keys($project-spacing-standard)}';
|
1068
|
+
}
|
1069
|
+
|
1070
|
+
@return map-get($project-spacing-standard, $converted);
|
1071
|
+
}
|
1072
|
+
|
1073
|
+
/*
|
1074
|
+
----------------------------------------
|
1075
|
+
get-palettes()
|
1076
|
+
----------------------------------------
|
1077
|
+
Build a single map of plugin values
|
1078
|
+
from a list of plugin keys.
|
1079
|
+
----------------------------------------
|
1080
|
+
*/
|
1081
|
+
|
1082
|
+
@function get-palettes($list) {
|
1083
|
+
$our-palettes: ();
|
1084
|
+
|
1085
|
+
@if type-of($list) == "map" {
|
1086
|
+
@error 'Use a list of strings as plugin values.';
|
1087
|
+
}
|
1088
|
+
|
1089
|
+
@each $palette in $list {
|
1090
|
+
@if not map-has-key($palette-registry, $palette) {
|
1091
|
+
@error '#{$palette} isn\'t in the registry.';
|
1092
|
+
}
|
1093
|
+
|
1094
|
+
$our-palettes: map-merge(
|
1095
|
+
$our-palettes,
|
1096
|
+
map-get($palette-registry, $palette)
|
1097
|
+
);
|
1098
|
+
}
|
1099
|
+
|
1100
|
+
@return $our-palettes;
|
1101
|
+
}
|
1102
|
+
|
1103
|
+
/*
|
1104
|
+
----------------------------------------
|
1105
|
+
border-radius()
|
1106
|
+
----------------------------------------
|
1107
|
+
Get a border-radius from the system
|
1108
|
+
border-radii
|
1109
|
+
----------------------------------------
|
1110
|
+
*/
|
1111
|
+
|
1112
|
+
@function border-radius($value) {
|
1113
|
+
@if map-has-key($all-border-radius, $value) {
|
1114
|
+
@return map-get($all-border-radius, $value);
|
1115
|
+
} @else {
|
1116
|
+
@error '`#{$value}` is not a valid border radius token. '
|
1117
|
+
+ 'Valid tokens: #{map-keys($all-border-radius)}';
|
1118
|
+
}
|
1119
|
+
}
|
1120
|
+
|
1121
|
+
/*
|
1122
|
+
----------------------------------------
|
1123
|
+
font-weight()
|
1124
|
+
fw()
|
1125
|
+
----------------------------------------
|
1126
|
+
Get a font-weight value from the
|
1127
|
+
system font-weight
|
1128
|
+
----------------------------------------
|
1129
|
+
*/
|
1130
|
+
|
1131
|
+
@function font-weight($value) {
|
1132
|
+
@return get-uswds-value(font-weight, $value);
|
1133
|
+
}
|
1134
|
+
|
1135
|
+
@function fw($value) {
|
1136
|
+
@return font-weight($value);
|
1137
|
+
}
|
1138
|
+
|
1139
|
+
/*
|
1140
|
+
----------------------------------------
|
1141
|
+
feature()
|
1142
|
+
----------------------------------------
|
1143
|
+
Gets a valid USWDS font feature setting
|
1144
|
+
----------------------------------------
|
1145
|
+
*/
|
1146
|
+
|
1147
|
+
@function feature($value) {
|
1148
|
+
@return get-uswds-value(feature, $value);
|
1149
|
+
}
|
1150
|
+
|
1151
|
+
/*
|
1152
|
+
----------------------------------------
|
1153
|
+
flex()
|
1154
|
+
----------------------------------------
|
1155
|
+
Gets a valid USWDS flex value
|
1156
|
+
----------------------------------------
|
1157
|
+
*/
|
1158
|
+
|
1159
|
+
@function flex($value) {
|
1160
|
+
@return get-uswds-value(flex, $value);
|
1161
|
+
}
|
1162
|
+
|
1163
|
+
/*
|
1164
|
+
----------------------------------------
|
1165
|
+
font-family()
|
1166
|
+
family()
|
1167
|
+
----------------------------------------
|
1168
|
+
Get a font-family stack from a
|
1169
|
+
role-based or type-based font family
|
1170
|
+
----------------------------------------
|
1171
|
+
*/
|
1172
|
+
|
1173
|
+
@function font-family($value) {
|
1174
|
+
@return get-uswds-value(font-family, $value);
|
1175
|
+
}
|
1176
|
+
|
1177
|
+
@function ff($value) {
|
1178
|
+
@return font-family($value);
|
1179
|
+
}
|
1180
|
+
|
1181
|
+
@function family($value) {
|
1182
|
+
@return font-family($value);
|
1183
|
+
}
|
1184
|
+
|
1185
|
+
/*
|
1186
|
+
----------------------------------------
|
1187
|
+
letter-spacing()
|
1188
|
+
ls()
|
1189
|
+
----------------------------------------
|
1190
|
+
Get a letter-spacing value from the
|
1191
|
+
system letter-spacing
|
1192
|
+
----------------------------------------
|
1193
|
+
*/
|
1194
|
+
|
1195
|
+
@function letter-spacing($value) {
|
1196
|
+
$lh-map: map-get($system-properties, letter-spacing);
|
1197
|
+
$fn-map: map-get($lh-map, function);
|
1198
|
+
@if map-has-key($fn-map, $value) {
|
1199
|
+
@return map-get($fn-map, $value);
|
1200
|
+
}
|
1201
|
+
@if type-of($value) == "number" {
|
1202
|
+
@error '`#{$value}` is a not a valid letter-spacing token. '
|
1203
|
+
+ 'Valid letter-spacing tokens: #{map-keys($fn-map)}';
|
1204
|
+
}
|
1205
|
+
@return get-uswds-value(letter-spacing, $value);
|
1206
|
+
}
|
1207
|
+
|
1208
|
+
@function ls($value) {
|
1209
|
+
@return letter-spacing($value);
|
1210
|
+
}
|
1211
|
+
|
1212
|
+
/*
|
1213
|
+
----------------------------------------
|
1214
|
+
measure()
|
1215
|
+
----------------------------------------
|
1216
|
+
Gets a valid USWDS reading line length
|
1217
|
+
----------------------------------------
|
1218
|
+
*/
|
1219
|
+
|
1220
|
+
@function measure($value) {
|
1221
|
+
@return get-uswds-value(measure, $value);
|
1222
|
+
}
|
1223
|
+
|
1224
|
+
/*
|
1225
|
+
----------------------------------------
|
1226
|
+
opacity()
|
1227
|
+
----------------------------------------
|
1228
|
+
Get an opacity from the system
|
1229
|
+
opacities
|
1230
|
+
----------------------------------------
|
1231
|
+
*/
|
1232
|
+
|
1233
|
+
@function opacity($value) {
|
1234
|
+
@return get-uswds-value(opacity, $value);
|
1235
|
+
}
|
1236
|
+
|
1237
|
+
/*
|
1238
|
+
----------------------------------------
|
1239
|
+
order()
|
1240
|
+
----------------------------------------
|
1241
|
+
Get an order value from the
|
1242
|
+
system orders
|
1243
|
+
----------------------------------------
|
1244
|
+
*/
|
1245
|
+
|
1246
|
+
@function order($value) {
|
1247
|
+
@return get-uswds-value(order, $value);
|
1248
|
+
}
|
1249
|
+
|
1250
|
+
/*
|
1251
|
+
----------------------------------------
|
1252
|
+
radius()
|
1253
|
+
----------------------------------------
|
1254
|
+
Get a border-radius value from the
|
1255
|
+
system letter-spacing
|
1256
|
+
----------------------------------------
|
1257
|
+
*/
|
1258
|
+
|
1259
|
+
@function radius($value) {
|
1260
|
+
@return get-uswds-value(border-radius, $value);
|
1261
|
+
}
|
1262
|
+
|
1263
|
+
/*
|
1264
|
+
----------------------------------------
|
1265
|
+
font-size()
|
1266
|
+
----------------------------------------
|
1267
|
+
Get type scale value from a [family] and
|
1268
|
+
[scale]
|
1269
|
+
----------------------------------------
|
1270
|
+
*/
|
1271
|
+
|
1272
|
+
@function font-size($family, $scale, $force: false) {
|
1273
|
+
$our-family: smart-quote($family);
|
1274
|
+
$our-scale: smart-quote($scale);
|
1275
|
+
|
1276
|
+
@if not map-has-key($project-cap-heights, $our-family) {
|
1277
|
+
@error '#{$our-family} is not a valid font family token. '
|
1278
|
+
+ 'Valid tokens: #{map-keys($project-cap-heights)}';
|
1279
|
+
}
|
1280
|
+
@if not map-get($all-type-scale, $our-scale) {
|
1281
|
+
@error '`#{$our-scale}` is not a valid font scale token. '
|
1282
|
+
+ 'Valid token: #{map-keys($all-type-scale)}';
|
1283
|
+
}
|
1284
|
+
|
1285
|
+
$this-cap: map-get($project-cap-heights, $our-family);
|
1286
|
+
$this-scale: map-get($all-type-scale, $our-scale);
|
1287
|
+
|
1288
|
+
@if not $force {
|
1289
|
+
@if not($this-scale and $this-cap) {
|
1290
|
+
@error 'The scale `#{$our-scale}` is disabled '
|
1291
|
+
+ 'in your project\'s theme settings. '
|
1292
|
+
+ 'Set its value to `true` to use this family.';
|
1293
|
+
}
|
1294
|
+
}
|
1295
|
+
|
1296
|
+
@return normalize-type-scale($this-cap, $this-scale);
|
1297
|
+
}
|
1298
|
+
|
1299
|
+
@function fs($family, $scale) {
|
1300
|
+
@return font-size($family, $scale);
|
1301
|
+
}
|
1302
|
+
|
1303
|
+
@function size($family, $scale) {
|
1304
|
+
@return font-size($family, $scale);
|
1305
|
+
}
|
1306
|
+
|
1307
|
+
/*
|
1308
|
+
----------------------------------------
|
1309
|
+
z-index()
|
1310
|
+
z()
|
1311
|
+
----------------------------------------
|
1312
|
+
Get a z-index value from the
|
1313
|
+
system z-index
|
1314
|
+
----------------------------------------
|
1315
|
+
*/
|
1316
|
+
|
1317
|
+
@function z-index($value) {
|
1318
|
+
@return get-uswds-value(z-index, $value);
|
1319
|
+
}
|
1320
|
+
|
1321
|
+
@function z($value) {
|
1322
|
+
@return z-index($value);
|
1323
|
+
}
|