@department-of-veterans-affairs/css-library 0.11.1 → 0.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1440,6 +1440,10 @@ through all possible variants
1440
1440
  Variables ported over from Formation so that we can keep those stylesheets
1441
1441
  working while we work on deprecation.
1442
1442
  **/
1443
+ /**
1444
+ Variables ported over from Formation so that we can keep those stylesheets
1445
+ working while we work on deprecation.
1446
+ **/
1443
1447
  /**
1444
1448
  /uswds/dist/scss/lib/addons/_margin.scss
1445
1449
  **/
@@ -1887,1587 +1891,6 @@ iframe:focus,
1887
1891
  outline-offset: 3px;
1888
1892
  }
1889
1893
 
1890
- /*
1891
- * * * * * ==============================
1892
- * * * * * ==============================
1893
- * * * * * ==============================
1894
- * * * * * ==============================
1895
- ========================================
1896
- ========================================
1897
- ========================================
1898
- ----------------------------------------
1899
- GENERAL SETTINGS
1900
- ----------------------------------------
1901
- Read more about settings and
1902
- USWDS style tokens in the documentation:
1903
- https://designsystem.digital.gov/design-tokens
1904
- ----------------------------------------
1905
- */
1906
- /*
1907
- ----------------------------------------
1908
- Image path
1909
- ----------------------------------------
1910
- Relative image file path
1911
- ----------------------------------------
1912
- */
1913
- /*
1914
- ----------------------------------------
1915
- Show compile warnings
1916
- ----------------------------------------
1917
- Show Sass warnings when functions and
1918
- mixins use non-standard tokens.
1919
- AND
1920
- Show updates and notifications.
1921
- ----------------------------------------
1922
- */
1923
- /*
1924
- ----------------------------------------
1925
- Namespace
1926
- ----------------------------------------
1927
- */
1928
- /*
1929
- ----------------------------------------
1930
- Prefix separator
1931
- ----------------------------------------
1932
- Set the character the separates
1933
- responsive and state prefixes from the
1934
- main class name.
1935
- The default (":") needs to be preceded
1936
- by two backslashes to be properly
1937
- escaped.
1938
- ----------------------------------------
1939
- */
1940
- /*
1941
- ----------------------------------------
1942
- Layout grid
1943
- ----------------------------------------
1944
- Should the layout grid classes output
1945
- with !important
1946
- ----------------------------------------
1947
- */
1948
- /*
1949
- ----------------------------------------
1950
- Border box sizing
1951
- ----------------------------------------
1952
- When set to true, sets the box-sizing
1953
- property of all site elements to
1954
- `border-box`.
1955
- ----------------------------------------
1956
- */
1957
- /*
1958
- ----------------------------------------
1959
- Focus styles
1960
- ----------------------------------------
1961
- */
1962
- /*
1963
- ----------------------------------------
1964
- Icons
1965
- ----------------------------------------
1966
- */
1967
- /*
1968
- * * * * * ==============================
1969
- * * * * * ==============================
1970
- * * * * * ==============================
1971
- * * * * * ==============================
1972
- ========================================
1973
- ========================================
1974
- ========================================
1975
- ----------------------------------------
1976
- TYPOGRAPHY SETTINGS
1977
- ----------------------------------------
1978
- Read more about settings and
1979
- USWDS typography tokens in the documentation:
1980
- https://designsystem.digital.gov/design-tokens/typesetting/overview/
1981
- ----------------------------------------
1982
- */
1983
- /*
1984
- ----------------------------------------
1985
- Root font size
1986
- ----------------------------------------
1987
- Setting $theme-respect-user-font-size to
1988
- true sets the root font size to 100% and
1989
- uses ems for media queries
1990
- ----------------------------------------
1991
- $theme-root-font-size only applies when
1992
- $theme-respect-user-font-size is set to
1993
- false.
1994
-
1995
- This will set the root font size
1996
- as a specific px value and use px values
1997
- for media queries.
1998
-
1999
- Accepts true or false
2000
- ----------------------------------------
2001
- */
2002
- /*
2003
- ----------------------------------------
2004
- Global styles
2005
- ----------------------------------------
2006
- Adds basic styling for the following
2007
- unclassed elements:
2008
-
2009
- - paragraph: paragraph text
2010
- - link: links
2011
- - content: paragraph text, links,
2012
- headings, lists, and tables
2013
- ----------------------------------------
2014
- */
2015
- /*
2016
- ----------------------------------------
2017
- Broswer compatibility mode
2018
- ----------------------------------------
2019
- When true, outputs woff and ttf font
2020
- formats in addition to woff2
2021
- ----------------------------------------
2022
- */
2023
- /*
2024
- ----------------------------------------
2025
- Font path
2026
- ----------------------------------------
2027
- Relative font file path
2028
- ----------------------------------------
2029
- */
2030
- /*
2031
- ----------------------------------------
2032
- Custom typeface tokens
2033
- ----------------------------------------
2034
- Add a new custom typeface token if
2035
- your project uses a typeface not already
2036
- defined by USWDS.
2037
- ----------------------------------------
2038
- USWDS defines the following tokens
2039
- by default:
2040
- ----------------------------------------
2041
- 'georgia'
2042
- 'helvetica'
2043
- 'merriweather'
2044
- 'open-sans'
2045
- 'public-sans'
2046
- 'roboto-mono'
2047
- 'source-sans-pro'
2048
- 'system'
2049
- 'tahoma'
2050
- 'verdana'
2051
- ----------------------------------------
2052
- Add as many new tokens as you have
2053
- custom typefaces. Reference your new
2054
- token(s) in the type-based font settings
2055
- using the quoted name of the token.
2056
-
2057
- For example:
2058
-
2059
- $theme-font-type-cond: 'example-font-token';
2060
-
2061
- display-name:
2062
- The display name of your font
2063
-
2064
- cap-height:
2065
- The height of a 500px `N` in Sketch
2066
- ----------------------------------------
2067
- You should change `example-[style]-token`
2068
- names to something more descriptive.
2069
- ----------------------------------------
2070
- */
2071
- /*
2072
- ----------------------------------------
2073
- Type-based font settings
2074
- ----------------------------------------
2075
- Set the type-based tokens for your
2076
- project from the following tokens,
2077
- or from any new font tokens you added in
2078
- $theme-typeface-tokens.
2079
- ----------------------------------------
2080
- 'georgia'
2081
- 'helvetica'
2082
- 'merriweather'
2083
- 'open-sans'
2084
- 'public-sans'
2085
- 'roboto-mono'
2086
- 'source-sans-pro'
2087
- 'system'
2088
- 'tahoma'
2089
- 'verdana'
2090
- ----------------------------------------
2091
- */
2092
- /*
2093
- ----------------------------------------
2094
- Custom font stacks
2095
- ----------------------------------------
2096
- Add custom font stacks to any of the
2097
- type-based fonts. Any USWDS typeface
2098
- token already has a default stack.
2099
-
2100
- Custom stacks don't need to include the
2101
- font's display name. It will
2102
- automatically appear at the start of
2103
- the stack.
2104
- ----------------------------------------
2105
- Example:
2106
- $theme-font-type-sans: 'source-sans-pro';
2107
- $theme-font-sans-custom-stack: "Helvetica Neue", Helvetica, Arial, sans;
2108
-
2109
- Output:
2110
- font-family: "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;
2111
- ----------------------------------------
2112
- */
2113
- /*
2114
- ----------------------------------------
2115
- Add any custom font source files
2116
- ----------------------------------------
2117
- If you want USWDS to generate additional
2118
- @font-face declarations, add your font
2119
- data below, following the example that
2120
- follows.
2121
- ----------------------------------------
2122
- USWDS automatically generates @font-face
2123
- declarations for the following
2124
-
2125
- 'merriweather'
2126
- 'public-sans'
2127
- 'roboto-mono'
2128
- 'source-sans-pro'
2129
-
2130
- These typefaces not require custom
2131
- source files.
2132
- ----------------------------------------
2133
- EXAMPLE
2134
-
2135
- - dir:
2136
- Directory relative to $theme-font-path
2137
- - This directory should include fonts saved as
2138
- .woff2
2139
- ExampleSerif-Normal.woff2
2140
-
2141
- $theme-font-serif-custom-src: (
2142
- dir: 'custom/example-serif',
2143
- roman: (
2144
- 100: false,
2145
- 200: false,
2146
- 300: 'ExampleSerif-Light',
2147
- 400: 'ExampleSerif-Normal',
2148
- 500: false,
2149
- 600: false,
2150
- 700: 'ExampleSerif-Bold',
2151
- 800: false,
2152
- 900: false,
2153
- ),
2154
- italic: (
2155
- 100: false,
2156
- 200: false,
2157
- 300: 'ExampleSerif-LightItalic',
2158
- 400: 'ExampleSerif-Italic',
2159
- 500: false,
2160
- 600: false,
2161
- 700: 'ExampleSerif-BoldItalic',
2162
- 800: false,
2163
- 900: false,
2164
- ),
2165
- );
2166
- ----------------------------------------
2167
- */
2168
- /*
2169
- ----------------------------------------
2170
- Role-based font settings
2171
- ----------------------------------------
2172
- Set the role-based tokens for your
2173
- project from the following font-type
2174
- tokens.
2175
- ----------------------------------------
2176
- 'cond'
2177
- 'icon'
2178
- 'lang'
2179
- 'mono'
2180
- 'sans'
2181
- 'serif'
2182
- ----------------------------------------
2183
- */
2184
- /*
2185
- ----------------------------------------
2186
- Type scale
2187
- ----------------------------------------
2188
- Define your project's type scale using
2189
- values from the USWDS system type scale
2190
-
2191
- 1-20
2192
- ----------------------------------------
2193
- */
2194
- /*
2195
- ----------------------------------------
2196
- Font weights
2197
- ----------------------------------------
2198
- Assign weights 100-900
2199
- Or use `false` for unneeded weights.
2200
- ----------------------------------------
2201
- */
2202
- /*
2203
- ----------------------------------------
2204
- General typography settings
2205
- ----------------------------------------
2206
- Type scale tokens
2207
- ----------------------------------------
2208
- micro: 10px
2209
- 1: 12px
2210
- 2: 13px
2211
- 3: 14px
2212
- 4: 15px
2213
- 5: 16px
2214
- 6: 17px
2215
- 7: 18px
2216
- 8: 20px
2217
- 9: 22px
2218
- 10: 24px
2219
- 11: 28px
2220
- 12: 32px
2221
- 13: 36px
2222
- 14: 40px
2223
- 15: 48px
2224
- 16: 56px
2225
- 17: 64px
2226
- 18: 80px
2227
- 19: 120px
2228
- 20: 140px
2229
- ----------------------------------------
2230
- Line height tokens
2231
- ----------------------------------------
2232
- 1: 1
2233
- 2: 1.15
2234
- 3: 1.35
2235
- 4: 1.5
2236
- 5: 1.62
2237
- 6: 1.75
2238
- ----------------------------------------
2239
- Font role tokens
2240
- ----------------------------------------
2241
- 'ui'
2242
- 'heading'
2243
- 'body'
2244
- 'code'
2245
- 'alt'
2246
- ----------------------------------------
2247
- Measure (max-width) tokens
2248
- ----------------------------------------
2249
- 1: 44ex
2250
- 2: 60ex
2251
- 3: 64ex
2252
- 4: 68ex
2253
- 5: 74ex
2254
- 6: 88ex
2255
- none: none
2256
- ----------------------------------------
2257
- */
2258
- /*
2259
- * * * * * ==============================
2260
- * * * * * ==============================
2261
- * * * * * ==============================
2262
- * * * * * ==============================
2263
- ========================================
2264
- ========================================
2265
- ========================================
2266
- ----------------------------------------
2267
- COLOR SETTINGS
2268
- ----------------------------------------
2269
- Read more about settings and
2270
- USWDS color tokens in the documentation:
2271
- https://designsystem.digital.gov/design-tokens/color
2272
- ----------------------------------------
2273
- */
2274
- /*
2275
- ----------------------------------------
2276
- Theme palette colors
2277
- ----------------------------------------
2278
- */
2279
- /*
2280
- ----------------------------------------
2281
- State palette colors
2282
- ----------------------------------------
2283
- */
2284
- /*
2285
- ----------------------------------------
2286
- General colors
2287
- ----------------------------------------
2288
- */
2289
- /*
2290
- * * * * * ==============================
2291
- * * * * * ==============================
2292
- * * * * * ==============================
2293
- * * * * * ==============================
2294
- ========================================
2295
- ========================================
2296
- ========================================
2297
- ----------------------------------------
2298
- COMPONENT SETTINGS
2299
- ----------------------------------------
2300
- Read more about settings and
2301
- USWDS style tokens in the documentation:
2302
- https://designsystem.digital.gov/design-tokens
2303
- ----------------------------------------
2304
- */
2305
- /*
2306
- * * * * * ==============================
2307
- * * * * * ==============================
2308
- * * * * * ==============================
2309
- * * * * * ==============================
2310
- ========================================
2311
- ========================================
2312
- ========================================
2313
- ----------------------------------------
2314
- SPACING SETTINGS
2315
- ----------------------------------------
2316
- Read more about settings and
2317
- USWDS spacing units tokens in the
2318
- documentation:
2319
- https://designsystem.digital.gov/design-tokens/spacing-units
2320
- ----------------------------------------
2321
- */
2322
- /*
2323
- ----------------------------------------
2324
- Border radius
2325
- ----------------------------------------
2326
- 2px 2px
2327
- 0.5 4px
2328
- 1 8px
2329
- 1.5 12px
2330
- 2 16px
2331
- 2.5 20px
2332
- 3 24px
2333
- 4 32px
2334
- 5 40px
2335
- 6 48px
2336
- 7 56px
2337
- 8 64px
2338
- 9 72px
2339
- ----------------------------------------
2340
- */
2341
- /*
2342
- ----------------------------------------
2343
- Column gap
2344
- ----------------------------------------
2345
- 2px 2px
2346
- 0.5 4px
2347
- 1 8px
2348
- 2 16px
2349
- 3 24px
2350
- 4 32px
2351
- 5 40px
2352
- 6 48px
2353
- ----------------------------------------
2354
- */
2355
- /*
2356
- ----------------------------------------
2357
- Grid container max-width
2358
- ----------------------------------------
2359
- mobile
2360
- mobile-lg
2361
- tablet
2362
- tablet-lg
2363
- desktop
2364
- desktop-lg
2365
- widescreen
2366
- ----------------------------------------
2367
- */
2368
- /*
2369
- ----------------------------------------
2370
- Site
2371
- ----------------------------------------
2372
- */
2373
- /*
2374
- * * * * * ==============================
2375
- * * * * * ==============================
2376
- * * * * * ==============================
2377
- * * * * * ==============================
2378
- ========================================
2379
- ========================================
2380
- ========================================
2381
- ----------------------------------------
2382
- UTILITIES SETTINGS
2383
- ----------------------------------------
2384
- Read more about settings and
2385
- USWDS utilities in the documentation:
2386
- https://designsystem.digital.gov/utilities
2387
- ----------------------------------------
2388
- */
2389
- /*
2390
- ----------------------------------------
2391
- Utility breakpoints
2392
- ----------------------------------------
2393
- Which breakpoints does your project
2394
- need? Select as `true` any breakpoint
2395
- used by utilities or layout grid
2396
- ----------------------------------------
2397
- */
2398
- /*
2399
- ----------------------------------------
2400
- Global colors
2401
- ----------------------------------------
2402
- The following palettes will be added to
2403
- - background-color
2404
- - border-color
2405
- - color
2406
- - text-decoration-color
2407
- ----------------------------------------
2408
- */
2409
- /*
2410
- ----------------------------------------
2411
- Settings
2412
- ----------------------------------------
2413
- */
2414
- /*
2415
- ----------------------------------------
2416
- Values
2417
- ----------------------------------------
2418
- */
2419
- /*
2420
- ----------------------------------------
2421
- color()
2422
- ----------------------------------------
2423
- Derive a color from a color shortcode
2424
- ----------------------------------------
2425
- */
2426
- /*
2427
- ----------------------------------------
2428
- append-important()
2429
- ----------------------------------------
2430
- Append `!important` to a list
2431
- ----------------------------------------
2432
- */
2433
- /*
2434
- ----------------------------------------
2435
- get-last()
2436
- ----------------------------------------
2437
- Return the last item of a list,
2438
- Return null if the value is null
2439
- ----------------------------------------
2440
- */
2441
- /*
2442
- ----------------------------------------
2443
- de-list()
2444
- ----------------------------------------
2445
- Transform a one-element list or arglist
2446
- into that single element.
2447
- ----------------------------------------
2448
- (1) => 1
2449
- ((1)) => (1)
2450
- ----------------------------------------
2451
- */
2452
- /*
2453
- ----------------------------------------
2454
- error-not-token()
2455
- ----------------------------------------
2456
- Returns a common not-a-token error.
2457
- ----------------------------------------
2458
- */
2459
- /*
2460
- ----------------------------------------
2461
- uswds-error()
2462
- ----------------------------------------
2463
- Allow the system to pass an error as text
2464
- to test error states in unit testing
2465
- ----------------------------------------
2466
- */
2467
- /*
2468
- ----------------------------------------
2469
- get-default()
2470
- ----------------------------------------
2471
- Returns the default value from a map
2472
- of project defaults
2473
- get-default("bg-color")
2474
- > $theme-body-background-color
2475
- ----------------------------------------
2476
- */
2477
- /*
2478
- ----------------------------------------
2479
- has-important()
2480
- ----------------------------------------
2481
- Check to see if `!important` is
2482
- being passed in a mixin's props
2483
- ----------------------------------------
2484
- */
2485
- /*
2486
- ----------------------------------------
2487
- map-collect()
2488
- ----------------------------------------
2489
- Collect multiple maps into a single
2490
- large map
2491
- source: https://gist.github.com/bigglesrocks/d75091700f8f2be5abfe
2492
- ----------------------------------------
2493
- */
2494
- /*
2495
- ----------------------------------------
2496
- map-deep-get()
2497
- ----------------------------------------
2498
- @author Hugo Giraudel
2499
- @access public
2500
- @param {Map} $map - Map
2501
- @param {Arglist} $keys - Key chain
2502
- @return {*} - Desired value
2503
- ----------------------------------------
2504
- */
2505
- /*
2506
- ----------------------------------------
2507
- multi-cat()
2508
- ----------------------------------------
2509
- Concatenate two lists
2510
- ----------------------------------------
2511
- */
2512
- /*
2513
- ----------------------------------------
2514
- remove()
2515
- ----------------------------------------
2516
- Remove a value from a list
2517
- ----------------------------------------
2518
- */
2519
- /*
2520
- ----------------------------------------
2521
- smart-quote()
2522
- ----------------------------------------
2523
- Quotes strings
2524
- Inspects `px`, `xs`, and `xl` numbers
2525
- Leaves bools as is
2526
- ----------------------------------------
2527
- */
2528
- /*
2529
- ----------------------------------------
2530
- str-replace()
2531
- ----------------------------------------
2532
- Replace any substring with another
2533
- string
2534
- ----------------------------------------
2535
- */
2536
- /*
2537
- ----------------------------------------
2538
- str-split()
2539
- ----------------------------------------
2540
- Split a string at a given separator
2541
- and convert into a list of substrings
2542
- ----------------------------------------
2543
- */
2544
- /*
2545
- ----------------------------------------
2546
- strip-unit()
2547
- ----------------------------------------
2548
- Remove the unit of a length
2549
- @author Hugo Giraudel
2550
- @param {Number} $number - Number to remove unit from
2551
- @return {Number} - Unitless number
2552
- ----------------------------------------
2553
- */
2554
- /*
2555
- ----------------------------------------
2556
- base-to-map()
2557
- @TODO: Deprecate and delete
2558
- ----------------------------------------
2559
- Convert a single base to a USWDS
2560
- value map.
2561
-
2562
- Candidate for deprecation if we remove
2563
- isReadable
2564
- ----------------------------------------
2565
- */
2566
- /*
2567
- ----------------------------------------
2568
- to-number()
2569
- ----------------------------------------
2570
- Casts a string into a number
2571
- ----------------------------------------
2572
- @param {String | Number} $value - Value to be parsed
2573
- @return {Number}
2574
- ----------------------------------------
2575
- */
2576
- /*
2577
- ----------------------------------------
2578
- unpack()
2579
- ----------------------------------------
2580
- Create lists of single items from lists
2581
- of lists.
2582
- ----------------------------------------
2583
- (1, (2.1, 2.2), 3) -->
2584
- (1, 2.1, 2.2, 3)
2585
- ----------------------------------------
2586
- */
2587
- /*
2588
- ----------------------------------------
2589
- color()
2590
- ----------------------------------------
2591
- Derive a color from a color shortcode
2592
- ----------------------------------------
2593
- */
2594
- /*
2595
- ----------------------------------------
2596
- color()
2597
- ----------------------------------------
2598
- Derive a color from a color shortcode
2599
- ----------------------------------------
2600
- */
2601
- /*
2602
- ----------------------------------------
2603
- get-system-color()
2604
- ----------------------------------------
2605
- Derive a system color from its
2606
- family, value, and vivid or a passed
2607
- variable that is, itself, a list
2608
- ----------------------------------------
2609
- */
2610
- /*
2611
- ----------------------------------------
2612
- color()
2613
- ----------------------------------------
2614
- Derive a color from a color shortcode
2615
- ----------------------------------------
2616
- */
2617
- /*
2618
- ----------------------------------------
2619
- color()
2620
- ----------------------------------------
2621
- Derive a color from a color shortcode
2622
- ----------------------------------------
2623
- */
2624
- /*
2625
- ----------------------------------------
2626
- color()
2627
- ----------------------------------------
2628
- Derive a color from a color shortcode
2629
- ----------------------------------------
2630
- */
2631
- /*
2632
- ----------------------------------------
2633
- set-theme-color()
2634
- ----------------------------------------
2635
- Derive a color from a system color token
2636
- or a hex value
2637
- ----------------------------------------
2638
- */
2639
- /*
2640
- ----------------------------------------
2641
- px-to-rem()
2642
- ----------------------------------------
2643
- Converts a value in px to a value in rem
2644
- ----------------------------------------
2645
- */
2646
- /*
2647
- ----------------------------------------
2648
- rem-to-px()
2649
- ----------------------------------------
2650
- Converts a value in rem to a value in px
2651
- ----------------------------------------
2652
- */
2653
- /*
2654
- ----------------------------------------
2655
- rem-to-user-em()
2656
- ----------------------------------------
2657
- Converts a value in rem to a value in
2658
- [user-settings] em for use in media
2659
- queries
2660
- ----------------------------------------
2661
- */
2662
- /*
2663
- ----------------------------------------
2664
- spacing-multiple()
2665
- ----------------------------------------
2666
- Converts a spacing unit multiple into
2667
- the desired final units (currently rem)
2668
- ----------------------------------------
2669
- */
2670
- /*
2671
- ----------------------------------------
2672
- units()
2673
- ----------------------------------------
2674
- Converts a spacing unit into
2675
- the desired final units (currently rem)
2676
- ----------------------------------------
2677
- */
2678
- /*
2679
- ----------------------------------------
2680
- number-to-token()
2681
- ----------------------------------------
2682
- Converts an integer or numeric value
2683
- into a system value
2684
-
2685
- Ex: 0.5 --> '05'
2686
- -1px --> 'neg-1px'
2687
- ----------------------------------------
2688
- */
2689
- /*
2690
- ----------------------------------------
2691
- Project fonts
2692
- ----------------------------------------
2693
- Collects font settings in a map for
2694
- looping.
2695
- ----------------------------------------
2696
- */
2697
- /*
2698
- ----------------------------------------
2699
- Luminance ranges
2700
- ----------------------------------------
2701
- */
2702
- /*
2703
- ----------------------------------------
2704
- ns()
2705
- ----------------------------------------
2706
- Add a namesspace of $type if that
2707
- namespace is set to output
2708
- ----------------------------------------
2709
- */
2710
- /*
2711
- ----------------------------------------
2712
- Line height
2713
- ----------------------------------------
2714
- */
2715
- /*
2716
- ----------------------------------------
2717
- Measure
2718
- ----------------------------------------
2719
- */
2720
- /*
2721
- ----------------------------------------
2722
- cap-height()
2723
- ----------------------------------------
2724
- Get the cap height of a valid typeface
2725
- ----------------------------------------
2726
- */
2727
- /*
2728
- ----------------------------------------
2729
- validate-typeface-token()
2730
- ----------------------------------------
2731
- Check to see if a typeface-token exists.
2732
- Throw an error if a passed token does
2733
- not exist in the typeface-token map.
2734
- ----------------------------------------
2735
- */
2736
- /*
2737
- ----------------------------------------
2738
- convert-to-font-type()
2739
- ----------------------------------------
2740
- Converts a font-role token into a
2741
- font-type token. Leaves font-type tokens
2742
- unchanged.
2743
- ----------------------------------------
2744
- */
2745
- /*
2746
- ----------------------------------------
2747
- font-sources()
2748
- ----------------------------------------
2749
- Outputs a list of font sources used in
2750
- a @font-face declaration.
2751
-
2752
- $theme-font-browser-compatibility: true - output woff2, woff, ttf
2753
- $theme-font-browser-compatibility: false - output woff2
2754
-
2755
- @param stem: string - [font path]/[custom-src.dir]/[custom-src.[style].[weight]]
2756
- @output: string
2757
-
2758
- filetypes must be one of the filetypes set in variables/$project-font-face-filetypes (woff, woff2, ttf)
2759
- ----------------------------------------
2760
- */
2761
- /*
2762
- ----------------------------------------
2763
- get-font-stack()
2764
- ----------------------------------------
2765
- Get a font stack from a style- or
2766
- role-based font token.
2767
- ----------------------------------------
2768
- */
2769
- /*
2770
- ----------------------------------------
2771
- get-typeface-token()
2772
- ----------------------------------------
2773
- Get a typeface token from a font-type or
2774
- font-role token.
2775
- ----------------------------------------
2776
- */
2777
- /*
2778
- ----------------------------------------
2779
- normalize-type-scale()
2780
- ----------------------------------------
2781
- Normalizes a specific face's optical size
2782
- to a set target
2783
- ----------------------------------------
2784
- */
2785
- /*
2786
- ----------------------------------------
2787
- system-type-scale()
2788
- ----------------------------------------
2789
- Get a value from the system type scale
2790
- ----------------------------------------
2791
- */
2792
- /*
2793
- ----------------------------------------
2794
- Easing
2795
- ----------------------------------------
2796
- */
2797
- /* deprecated.scss
2798
- ---
2799
- Occasionally the design system will deprecate
2800
- old variables or functionality. If we replace
2801
- the old functionality with something new, this is a
2802
- place to connect the old functionality to the
2803
- new functionality, in the service of better
2804
- continuity and backwards compatibility within a
2805
- major release cycle.
2806
-
2807
- Note the USWDS version where we deprecated the
2808
- old functionality in a comment.
2809
-
2810
- Be sure to update notifications.scss.
2811
-
2812
- This file should started fresh at each
2813
- major version.
2814
- */
2815
- /*
2816
- ----------------------------------------
2817
- advanced-color()
2818
- ----------------------------------------
2819
- Derive a color from a color triplet:
2820
- [family], [grade], [variant]
2821
- ----------------------------------------
2822
- */
2823
- /*
2824
- ----------------------------------------
2825
- calculate-grade()
2826
- ----------------------------------------
2827
- Derive the grade equivalent any color,
2828
- even non-token colors
2829
- ----------------------------------------
2830
- */
2831
- /*
2832
- ----------------------------------------
2833
- color-token-assignment()
2834
- ----------------------------------------
2835
- Get the system token equivalent of any
2836
- theme color token
2837
- ----------------------------------------
2838
- */
2839
- /*
2840
- ----------------------------------------
2841
- is-system-color-token()
2842
- ----------------------------------------
2843
- Return whether a token is a system
2844
- color token
2845
- ----------------------------------------
2846
- */
2847
- /*
2848
- ----------------------------------------
2849
- is-theme-color-token()
2850
- ----------------------------------------
2851
- Return whether a token is a theme
2852
- color token
2853
- ----------------------------------------
2854
- */
2855
- /*
2856
- ----------------------------------------
2857
- color-token-family()
2858
- ----------------------------------------
2859
- Returns the family of a color token.
2860
- Returns: color-family
2861
- color-token-family("accent-warm-vivid")
2862
- > "accent-warm"
2863
- color-token-family("red-50v")
2864
- > "red"
2865
- color-token-variant(("red", 50, "vivid"))
2866
- > "red"
2867
- ----------------------------------------
2868
- */
2869
- /*
2870
- ----------------------------------------
2871
- decompose()
2872
- ----------------------------------------
2873
- Convert a color token into into a list
2874
- of form [family], [grade], [variant]
2875
- Vivid variants return "vivid" as the
2876
- variant.
2877
- If neither grade nor variant exists,
2878
- returns 'null'
2879
- ----------------------------------------
2880
- */
2881
- /*
2882
- ----------------------------------------
2883
- color-token-family()
2884
- ----------------------------------------
2885
- Returns the family of a color token.
2886
- Returns: color-family
2887
- color-token-family("accent-warm-vivid")
2888
- > "accent-warm"
2889
- color-token-family("red-50v")
2890
- > "red"
2891
- color-token-variant(("red", 50, "vivid"))
2892
- > "red"
2893
- ----------------------------------------
2894
- */
2895
- /*
2896
- ----------------------------------------
2897
- color-token-grade()
2898
- ----------------------------------------
2899
- Returns the grade of a USWDS color token.
2900
- Returns: color-grade
2901
- color-token-grade("accent-warm")
2902
- > "root"
2903
- color-token-grade("accent-warm-vivid")
2904
- > "root"
2905
- color-token-grade("accent-warm-darker")
2906
- > "darker"
2907
- color-token-grade("red-50v")
2908
- > 50
2909
- color-token-variant(("red", 50, "vivid"))
2910
- > 50
2911
- ----------------------------------------
2912
- */
2913
- /*
2914
- ----------------------------------------
2915
- color-token-family()
2916
- ----------------------------------------
2917
- Returns the family of a color token.
2918
- Returns: color-family
2919
- color-token-family("accent-warm-vivid")
2920
- > "accent-warm"
2921
- color-token-family("red-50v")
2922
- > "red"
2923
- color-token-variant(("red", 50, "vivid"))
2924
- > "red"
2925
- ----------------------------------------
2926
- */
2927
- /*
2928
- ----------------------------------------
2929
- is-color-token()
2930
- ----------------------------------------
2931
- Returns whether a given string is a
2932
- USWDS color token.
2933
- ----------------------------------------
2934
- */
2935
- /*
2936
- ----------------------------------------
2937
- pow()
2938
- ----------------------------------------
2939
- Raises a unitless number to the power
2940
- of another unitless number
2941
- Includes helper functions
2942
- ----------------------------------------
2943
- */
2944
- /*
2945
- ----------------------------------------
2946
- Helper functions
2947
- ----------------------------------------
2948
- */
2949
- /* factorial()
2950
- ----------------------------------------
2951
- */
2952
- /* summation()
2953
- ----------------------------------------
2954
- */
2955
- /* exp-maclaurin()
2956
- ----------------------------------------
2957
- */
2958
- /* ln()
2959
- ----------------------------------------
2960
- */
2961
- /*
2962
- ----------------------------------------
2963
- color-token-type()
2964
- ----------------------------------------
2965
- Returns the type of a color token.
2966
- Returns: "system" | "theme"
2967
- ----------------------------------------
2968
- */
2969
- /*
2970
- ----------------------------------------
2971
- color-token-variant()
2972
- ----------------------------------------
2973
- Returns the variant of color token.
2974
- Returns: "vivid" | false
2975
- color-token-variant("accent-warm")
2976
- > false
2977
- color-token-variant("accent-warm-vivid")
2978
- > "vivid"
2979
- color-token-variant("red-50v")
2980
- > "vivid"
2981
- color-token-variant(("red", 50, "vivid"))
2982
- > "vivid"
2983
- ----------------------------------------
2984
- */
2985
- /*
2986
- ----------------------------------------
2987
- magic-number()
2988
- ----------------------------------------
2989
- Returns the magic number of two color
2990
- grades. Takes numbers or color tokens.
2991
- magic-number(50, 10)
2992
- return: 40
2993
- magic-number("red-50", "red-10")
2994
- return: 40
2995
- ----------------------------------------
2996
- */
2997
- /*
2998
- ----------------------------------------
2999
- is-accessible-magic-number()
3000
- ----------------------------------------
3001
- Returns whether two grades achieve
3002
- specified target color contrast
3003
- Returns: true | false
3004
- is-accessible-magic-number(10, 50, "AA")
3005
- > false
3006
- is-accessible-magic-number(10, 60, "AA")
3007
- > true
3008
- ----------------------------------------
3009
- */
3010
- /*
3011
- ----------------------------------------
3012
- wcag-magic-number()
3013
- ----------------------------------------
3014
- Returns the magic number of a specific
3015
- wcag grade:
3016
- "AA"
3017
- "AA-Large"
3018
- "AAA"
3019
- wcag-magic-number("AA")
3020
- > 50
3021
- ----------------------------------------
3022
- */
3023
- /*
3024
- ----------------------------------------
3025
- get-link-tokens-from-bg()
3026
- ----------------------------------------
3027
- Get accessible link colors for a given
3028
- background color
3029
- returns: link-token, hover-token
3030
- get-link-tokens-from-bg(
3031
- "black",
3032
- "red-60",
3033
- "red-10",
3034
- "AA")
3035
- > "red-10", "red-5"
3036
- get-link-tokens-from-bg(
3037
- "black",
3038
- "red-60v",
3039
- "red-10v",
3040
- "AA-large")
3041
- > "red-60v", "red-50v"
3042
- get-link-tokens-from-bg(
3043
- "black",
3044
- "red-5v",
3045
- "red-60v",
3046
- "AA")
3047
- > "red-5v", "white"
3048
- get-link-tokens-from-bg(
3049
- "black",
3050
- "white",
3051
- "red-60v",
3052
- "AA")
3053
- > "white", "white"
3054
- ----------------------------------------
3055
- */
3056
- /*
3057
- ----------------------------------------
3058
- next-token()
3059
- ----------------------------------------
3060
- Returns next "darker" or "lighter" color
3061
- token of the same token type and variant.
3062
- Returns: color-token | false
3063
- next-token("accent-warm", "lighter")
3064
- > "accent-warm-light"
3065
- next-token("gray-10", "lighter")
3066
- > "gray-5"
3067
- next-token("gray-5", "lighter")
3068
- > "white"
3069
- next-token("white", "lighter")
3070
- > false
3071
- next-token("red-50v", "darker")
3072
- > "red-60v"
3073
- next-token("red-50", "darker")
3074
- > "red-60"
3075
- next-token("red-80v", "darker")
3076
- > "red-90"
3077
- next-token("red-90", "darker")
3078
- > "black"
3079
- next-token("white", "darker")
3080
- > "gray-5"
3081
- next-token("black", "lighter")
3082
- > "gray-90"
3083
- ----------------------------------------
3084
- */
3085
- /*
3086
- ----------------------------------------
3087
- test-colors()
3088
- ----------------------------------------
3089
- Check to see if all system colors
3090
- fall between the proper relative
3091
- luminance range for their grade.
3092
- Has a couple quirks, as the luminance()
3093
- function returns slightly different
3094
- results than expected.
3095
- ----------------------------------------
3096
- */
3097
- /*
3098
- ----------------------------------------
3099
- columns()
3100
- ----------------------------------------
3101
- outputs a grid-col number based on
3102
- the number of desired columns in the
3103
- 12-column grid
3104
-
3105
- Ex: columns(2) --> 6
3106
- grid-col(columns(2))
3107
- ----------------------------------------
3108
- */
3109
- /*
3110
- ----------------------------------------
3111
- USWDS Properties
3112
- ----------------------------------------
3113
- */
3114
- /*
3115
- ----------------------------------------
3116
- get-uswds-value()
3117
- ----------------------------------------
3118
- Finds and outputs a value from the
3119
- USWDS standard values.
3120
-
3121
- Used to build other standard utility
3122
- functions and mixins.
3123
- ----------------------------------------
3124
- */
3125
- /*
3126
- ----------------------------------------
3127
- get-standard-values()
3128
- ----------------------------------------
3129
- Gets a map of USWDS standard values
3130
- for a property
3131
- ----------------------------------------
3132
- */
3133
- /*
3134
- ----------------------------------------
3135
- border-radius()
3136
- ----------------------------------------
3137
- Get a border-radius from the system
3138
- border-radii
3139
- ----------------------------------------
3140
- */
3141
- /*
3142
- ----------------------------------------
3143
- font-weight()
3144
- fw()
3145
- ----------------------------------------
3146
- Get a font-weight value from the
3147
- system font-weight
3148
- ----------------------------------------
3149
- */
3150
- /*
3151
- ----------------------------------------
3152
- feature()
3153
- ----------------------------------------
3154
- Gets a valid USWDS font feature setting
3155
- ----------------------------------------
3156
- */
3157
- /*
3158
- ----------------------------------------
3159
- flex()
3160
- ----------------------------------------
3161
- Gets a valid USWDS flex value
3162
- ----------------------------------------
3163
- */
3164
- /*
3165
- ----------------------------------------
3166
- font-family()
3167
- family()
3168
- ----------------------------------------
3169
- Get a font-family stack from a
3170
- role-based or type-based font family
3171
- ----------------------------------------
3172
- */
3173
- /*
3174
- ----------------------------------------
3175
- letter-spacing()
3176
- ls()
3177
- ----------------------------------------
3178
- Get a letter-spacing value from the
3179
- system letter-spacing
3180
- ----------------------------------------
3181
- */
3182
- /*
3183
- ----------------------------------------
3184
- measure()
3185
- ----------------------------------------
3186
- Gets a valid USWDS reading line length
3187
- ----------------------------------------
3188
- */
3189
- /*
3190
- ----------------------------------------
3191
- opacity()
3192
- ----------------------------------------
3193
- Get an opacity from the system
3194
- opacities
3195
- ----------------------------------------
3196
- */
3197
- /*
3198
- ----------------------------------------
3199
- order()
3200
- ----------------------------------------
3201
- Get an order value from the
3202
- system orders
3203
- ----------------------------------------
3204
- */
3205
- /*
3206
- ----------------------------------------
3207
- radius()
3208
- ----------------------------------------
3209
- Get a border-radius value from the
3210
- system letter-spacing
3211
- ----------------------------------------
3212
- */
3213
- /*
3214
- ----------------------------------------
3215
- font-size()
3216
- ----------------------------------------
3217
- Get type scale value from a [family] and
3218
- [scale]
3219
- ----------------------------------------
3220
- */
3221
- /*
3222
- ----------------------------------------
3223
- z-index()
3224
- z()
3225
- ----------------------------------------
3226
- Get a z-index value from the
3227
- system z-index
3228
- ----------------------------------------
3229
- */
3230
- /*
3231
- ----------------------------------------
3232
- utility-font()
3233
- ----------------------------------------
3234
- Get a normalized font-size in rem from
3235
- a family and a type size in either
3236
- system scale or project scale
3237
- ----------------------------------------
3238
- Not the public-facing function.
3239
- Used for building the utilities and
3240
- withholds certain errors.
3241
- ----------------------------------------
3242
- */
3243
- /*
3244
- ----------------------------------------
3245
- family()
3246
- ----------------------------------------
3247
- Get a font-family stack
3248
- ----------------------------------------
3249
- */
3250
- /*
3251
- ----------------------------------------
3252
- size()
3253
- ----------------------------------------
3254
- Get a normalized font-size in rem from
3255
- a family and a type size in either
3256
- system scale or project scale
3257
- ----------------------------------------
3258
- */
3259
- /*
3260
- ----------------------------------------
3261
- font()
3262
- ----------------------------------------
3263
- Get a font-family stack
3264
- AND
3265
- Get a normalized font-size in rem from
3266
- a family and a type size in either
3267
- system scale or project scale
3268
- ----------------------------------------
3269
- */
3270
- /*
3271
- ----------------------------------------
3272
- typeset()
3273
- ----------------------------------------
3274
- Sets:
3275
- - family
3276
- - size
3277
- - line-height
3278
- ----------------------------------------
3279
- */
3280
- /* stylelint-disable max-nesting-depth */
3281
- /*
3282
- ----------------------------------------
3283
- @render-pseudoclass
3284
- ----------------------------------------
3285
- Build a pseucoclass utiliy from values
3286
- calculated in the @render-utilities-in
3287
- loop
3288
- ----------------------------------------
3289
- */
3290
- /*
3291
- ----------------------------------------
3292
- @render-utility
3293
- ----------------------------------------
3294
- Build a utility from values calculated
3295
- in the @render-utilities-in loop
3296
- ----------------------------------------
3297
- TODO: Determine the proper use of
3298
- unquote() in the following. Changed to
3299
- account for a 'interpolation near
3300
- operators will be simplified in a
3301
- future version of Sass' warning.
3302
- ----------------------------------------
3303
- */
3304
- /*
3305
- ----------------------------------------
3306
- @render-utilities-in
3307
- ----------------------------------------
3308
- The master loop that sets the building
3309
- blocks of utilities from the values
3310
- in individual rule settings and loops
3311
- through all possible variants
3312
- ----------------------------------------
3313
- */
3314
- /* stylelint-enable */
3315
- /* notifications.scss
3316
- ---
3317
- Adds a notification at the top of each USWDS
3318
- compile. Use this file for important notifications
3319
- and updates to the design system.
3320
-
3321
- This file should started fresh at each
3322
- major version.
3323
-
3324
- */
3325
- /* prettier-ignore */
3326
- /* prettier-ignore */
3327
- /* stylelint-disable */
3328
- @font-face {
3329
- font-family: "Roboto Mono Web";
3330
- font-style: normal;
3331
- font-weight: 300;
3332
- font-display: fallback;
3333
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300.woff2) format("woff2");
3334
- }
3335
- @font-face {
3336
- font-family: "Roboto Mono Web";
3337
- font-style: normal;
3338
- font-weight: 400;
3339
- font-display: fallback;
3340
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-regular.woff2) format("woff2");
3341
- }
3342
- @font-face {
3343
- font-family: "Roboto Mono Web";
3344
- font-style: normal;
3345
- font-weight: 700;
3346
- font-display: fallback;
3347
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700.woff2) format("woff2");
3348
- }
3349
- @font-face {
3350
- font-family: "Roboto Mono Web";
3351
- font-style: italic;
3352
- font-weight: 300;
3353
- font-display: fallback;
3354
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-300italic.woff2) format("woff2");
3355
- }
3356
- @font-face {
3357
- font-family: "Roboto Mono Web";
3358
- font-style: italic;
3359
- font-weight: 400;
3360
- font-display: fallback;
3361
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-italic.woff2) format("woff2");
3362
- }
3363
- @font-face {
3364
- font-family: "Roboto Mono Web";
3365
- font-style: italic;
3366
- font-weight: 700;
3367
- font-display: fallback;
3368
- src: url(~@uswds/uswds/fonts/roboto-mono/roboto-mono-v5-latin-700italic.woff2) format("woff2");
3369
- }
3370
- @font-face {
3371
- font-family: "Source Sans Pro Web";
3372
- font-style: normal;
3373
- font-weight: 300;
3374
- font-display: fallback;
3375
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-light-webfont.woff2) format("woff2");
3376
- }
3377
- @font-face {
3378
- font-family: "Source Sans Pro Web";
3379
- font-style: normal;
3380
- font-weight: 400;
3381
- font-display: fallback;
3382
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-regular-webfont.woff2) format("woff2");
3383
- }
3384
- @font-face {
3385
- font-family: "Source Sans Pro Web";
3386
- font-style: normal;
3387
- font-weight: 700;
3388
- font-display: fallback;
3389
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-bold-webfont.woff2) format("woff2");
3390
- }
3391
- @font-face {
3392
- font-family: "Source Sans Pro Web";
3393
- font-style: italic;
3394
- font-weight: 300;
3395
- font-display: fallback;
3396
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-lightitalic-webfont.woff2) format("woff2");
3397
- }
3398
- @font-face {
3399
- font-family: "Source Sans Pro Web";
3400
- font-style: italic;
3401
- font-weight: 400;
3402
- font-display: fallback;
3403
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-italic-webfont.woff2) format("woff2");
3404
- }
3405
- @font-face {
3406
- font-family: "Source Sans Pro Web";
3407
- font-style: italic;
3408
- font-weight: 700;
3409
- font-display: fallback;
3410
- src: url(~@uswds/uswds/fonts/source-sans-pro/sourcesanspro-bolditalic-webfont.woff2) format("woff2");
3411
- }
3412
- @font-face {
3413
- font-family: "Merriweather Web";
3414
- font-style: normal;
3415
- font-weight: 300;
3416
- font-display: fallback;
3417
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-Light.woff2) format("woff2");
3418
- }
3419
- @font-face {
3420
- font-family: "Merriweather Web";
3421
- font-style: normal;
3422
- font-weight: 400;
3423
- font-display: fallback;
3424
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-Regular.woff2) format("woff2");
3425
- }
3426
- @font-face {
3427
- font-family: "Merriweather Web";
3428
- font-style: normal;
3429
- font-weight: 700;
3430
- font-display: fallback;
3431
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-Bold.woff2) format("woff2");
3432
- }
3433
- @font-face {
3434
- font-family: "Merriweather Web";
3435
- font-style: italic;
3436
- font-weight: 300;
3437
- font-display: fallback;
3438
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-LightItalic.woff2) format("woff2");
3439
- }
3440
- @font-face {
3441
- font-family: "Merriweather Web";
3442
- font-style: italic;
3443
- font-weight: 400;
3444
- font-display: fallback;
3445
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-Italic.woff2) format("woff2");
3446
- }
3447
- @font-face {
3448
- font-family: "Merriweather Web";
3449
- font-style: italic;
3450
- font-weight: 700;
3451
- font-display: fallback;
3452
- src: url(~@uswds/uswds/fonts/merriweather/Latin-Merriweather-BoldItalic.woff2) format("woff2");
3453
- }
3454
- /* stylelint-enable */
3455
- /* latin */
3456
- @font-face {
3457
- font-family: "Bitter";
3458
- font-style: normal;
3459
- font-weight: 400;
3460
- src: local("Bitter Regular"), local("Bitter-Regular"), url("~@department-of-veterans-affairs/css-library/dist/fonts/bitter-regular.woff2") format("woff2"), url("~@department-of-veterans-affairs/css-library/dist/fonts/bitter-regular.ttf") format("truetype");
3461
- unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215;
3462
- }
3463
- /* latin */
3464
- @font-face {
3465
- font-family: "Bitter";
3466
- font-style: normal;
3467
- font-weight: 700;
3468
- src: local("Bitter Bold"), local("Bitter-Bold"), url("~@department-of-veterans-affairs/css-library/dist/fonts/bitter-bold.woff2") format("woff2"), url("~@department-of-veterans-affairs/css-library/dist/fonts/bitter-bold.ttf") format("truetype");
3469
- unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215;
3470
- }
3471
1894
  /**
3472
1895
  Variables ported over from Formation so that we can keep those stylesheets
3473
1896
  working while we work on deprecation.