@department-of-veterans-affairs/css-library 0.20.0-rc1 → 0.20.0

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.
@@ -1405,7 +1405,7 @@ a.vads-c-action-link--blue, a.vads-c-action-link--green, a.vads-c-action-link--w
1405
1405
  display: inline-block;
1406
1406
  }
1407
1407
  a.vads-c-action-link--blue:before, a.vads-c-action-link--green:before, a.vads-c-action-link--white:before {
1408
- background-image: url("/img/arrow-right-white.svg");
1408
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right-white.svg);
1409
1409
  background-size: 18px 18px;
1410
1410
  background-repeat: no-repeat;
1411
1411
  background-position: center;
@@ -1433,7 +1433,7 @@ a.vads-c-action-link--white {
1433
1433
  color: #ffffff;
1434
1434
  }
1435
1435
  a.vads-c-action-link--white:before {
1436
- background-image: url("/img/arrow-right.svg");
1436
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right.svg);
1437
1437
  background-color: #ffffff;
1438
1438
  -webkit-transition-duration: 0.3s;
1439
1439
  transition-duration: 0.3s;
@@ -6,7 +6,7 @@
6
6
  position: relative;
7
7
  }
8
8
  .va-dropdown-trigger {
9
- background: transparent url("/img/arrow-down-white.svg") no-repeat;
9
+ background: transparent url(~@department-of-veterans-affairs/css-library/dist/img/arrow-down-white.svg) no-repeat;
10
10
  background-position: right 8px center;
11
11
  background-size: 10px 10px;
12
12
  border-radius: 0;
@@ -20,7 +20,7 @@
20
20
  .va-dropdown-trigger[aria-expanded=true] {
21
21
  border-top-color: #8a7237;
22
22
  background-color: #ffffff;
23
- background-image: url("/img/arrow-up.svg") !important;
23
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-up.svg) !important;
24
24
  color: #1b1b1b;
25
25
  }
26
26
  .va-dropdown-trigger[aria-expanded=true] path {
@@ -15,7 +15,7 @@
15
15
  }
16
16
  .hub-page-link-list__item > a:hover .all-link-arrow, .hub-page-link-list__item > a:focus .all-link-arrow {
17
17
  margin-left: 10px;
18
- content: url("/img/arrow-right.svg");
18
+ content: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right.svg);
19
19
  }
20
20
  .hub-page-link-list__item > a:hover .hub-page-link-list__header, .hub-page-link-list__item > a:focus .hub-page-link-list__header {
21
21
  text-decoration: underline;
@@ -268,11 +268,11 @@
268
268
  background-color: #e1f3f8;
269
269
  }
270
270
  .va-sidebarnav .usa-accordion .usa-accordion-button[aria-expanded=false] {
271
- background-image: url("/img/plus-blue.svg");
271
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/plus-blue.svg);
272
272
  }
273
273
  .va-sidebarnav .usa-accordion .usa-accordion-button[aria-expanded=true] {
274
274
  border-bottom: 0;
275
- background-image: url("/img/minus-blue.svg");
275
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/minus-blue.svg);
276
276
  }
277
277
  .va-sidebarnav .usa-accordion .usa-accordion-button[aria-expanded=true]:focus {
278
278
  border: 2px solid #fdb81e;
@@ -341,7 +341,7 @@
341
341
  }
342
342
 
343
343
  .va-btn-close-icon {
344
- background: transparent url("/img/close.svg") center no-repeat;
344
+ background: transparent url(~@department-of-veterans-affairs/css-library/dist/img/close.svg) center no-repeat;
345
345
  background-size: 0.625rem 0.625rem;
346
346
  height: 1.375rem;
347
347
  padding: 1.375rem;
@@ -0,0 +1,121 @@
1
+ @import '../override-function';
2
+
3
+ .va-crisis-line {
4
+ @include media($medium-screen) {
5
+ position: absolute;
6
+ right: 0;
7
+ top: 0;
8
+ }
9
+ }
10
+
11
+ .va-crisis-panel {
12
+ // color: $color-primary-darkest;
13
+ list-style: none;
14
+ margin: 0;
15
+ top: 50%;
16
+ transform: translateY(-50%);
17
+ padding: scale-rem(2rem);
18
+ position: relative;
19
+ z-index: 1;
20
+ width: 100%;
21
+
22
+ li {
23
+ &:nth-child(odd) {
24
+ border-top: 1px solid $color-gray-lighter;
25
+ border-bottom: 1px solid $color-gray-lighter;
26
+ }
27
+
28
+ a {
29
+ color: $color-base;
30
+ display: block;
31
+ padding: scale-rule(1.5rem 0);
32
+ text-decoration: none;
33
+ }
34
+ }
35
+
36
+ @include media($medium-screen) {
37
+ margin: auto;
38
+ max-width: 50%;
39
+ }
40
+
41
+ a {
42
+ @include no-sr-content;
43
+
44
+ padding: 0;
45
+ background-image: none;
46
+
47
+ }
48
+ }
49
+
50
+ .va-crisis-panel-body {
51
+ background: $vads-color-white;
52
+ height: auto;
53
+ list-style: inherit;
54
+ margin: 0;
55
+ max-height: 100%;
56
+ padding: 0;
57
+
58
+ ul {
59
+ // font-size: scale-rem(1.7rem);
60
+ list-style: none;
61
+ margin: 0;
62
+ padding: 0;
63
+ text-align: center;
64
+ }
65
+ }
66
+
67
+ button.va-crisis-line-button {
68
+ background: $vads-color-white url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right.svg) calc(100% - 0.5em) center no-repeat;
69
+ background-size: .8em auto;
70
+ border-radius: 0;
71
+ color: $color-base;
72
+ margin: auto;
73
+ padding: 0.4em 26px 0.3em 0;
74
+ font-size: 1em;
75
+ width: auto;
76
+ display: block;
77
+ text-decoration: none;
78
+ font-weight: bold;
79
+
80
+ @include media($medium-screen) {
81
+ border-radius: 0 0 0.2em 0.2em;
82
+ box-shadow: 0 2px 5px $color-base;
83
+ padding: 0 26px 0 0;
84
+ text-align: left;
85
+ }
86
+
87
+ &:hover {
88
+ background-color: $vads-color-white;
89
+ color: $color-base;
90
+ }
91
+
92
+ .vcl {
93
+ content: "";
94
+ background: url(~@department-of-veterans-affairs/css-library/dist/img/vcl-logo.png) no-repeat right 29%;
95
+ background-size: 100%;
96
+ display: inline-block;
97
+ width: 2em;
98
+ height: 2em;
99
+ margin: 0.3em 0.5em -0.3em 0.5em;
100
+ }
101
+
102
+ > .va-flex {
103
+ display: flex;
104
+ align-items: center;
105
+ pointer-events: none;
106
+ }
107
+ }
108
+
109
+ .va-footer-vcl-trigger {
110
+ background: transparent;
111
+ color: inherit;
112
+ font-size: inherit;
113
+ font-weight: normal;
114
+ text-decoration: underline;
115
+
116
+ &:hover {
117
+ background: inherit;
118
+ color: $color-gold;
119
+ text-decoration: inherit;
120
+ }
121
+ }
@@ -0,0 +1,469 @@
1
+ @import '../override-function';
2
+
3
+ // The distance from the top of the screen that the mobile navigation menu should appear
4
+ $height-offset-small: 131.16px;
5
+ $height-offset-xsmall: 153.16px;
6
+
7
+ body.va-pos-fixed {
8
+ width: 100%;
9
+ height: 100%;
10
+ }
11
+
12
+ #vetnav,
13
+ [role='menu'] [role='menu'] {
14
+ // The main menu takes up the whole screen under the Menu button for xsmall & small screens
15
+ // Sub menus also take up the whole screen to cover the main menu
16
+ min-height: calc(100vh - #{$height-offset-xsmall});
17
+
18
+ @include media($small-screen) {
19
+ min-height: calc(100vh - #{$height-offset-small});
20
+ }
21
+
22
+ // For medium and large screens, they're just as big as they need to be
23
+ @include media($medium-screen) {
24
+ min-height: 100%;
25
+ }
26
+ }
27
+
28
+ #vetnav {
29
+ background-color: $color-primary-darkest;
30
+
31
+ // This value should be equal to the default y-position of the menu so that removing it
32
+ // shouldn't affect anything. However, it's here to show how the height is offset by the
33
+ // vertical positioning.
34
+ // top: $height-offset;
35
+ overflow-y: scroll;
36
+ position: absolute;
37
+ width: 100%;
38
+
39
+ // Just large enough to take precedence over any other dropdowns on the page and the VA Map
40
+ z-index: 1011;
41
+
42
+ &.vetnav--submenu-expanded {
43
+ #vetnav-menu {
44
+ overflow: hidden;
45
+ height: 0;
46
+ @include media($medium-screen) {
47
+ height: auto;
48
+ overflow: visible;
49
+ }
50
+ }
51
+ }
52
+
53
+ @include media($medium-screen) {
54
+ margin-top: scale-rem(1rem);
55
+ overflow-y: visible;
56
+ position: relative;
57
+ width: auto;
58
+ top: 0;
59
+ }
60
+ }
61
+
62
+ #vetnav-menu {
63
+ height: auto;
64
+ list-style: none;
65
+ margin: 0;
66
+ padding-left: 0;
67
+
68
+ @include media($medium-screen) {
69
+ display: flex;
70
+ height: auto;
71
+ margin-top: scale-rem(1rem);
72
+ margin-bottom: 0;
73
+ overflow-y: visible;
74
+ position: relative;
75
+ }
76
+
77
+ > li {
78
+ margin-bottom: 6px;
79
+
80
+ @include media($medium-screen) {
81
+ margin-bottom: 0;
82
+ }
83
+
84
+ &:first-of-type {
85
+ @include media($medium-screen) {
86
+ display: none;
87
+ }
88
+ }
89
+ }
90
+
91
+ &::before {
92
+ display: block;
93
+ content: ' ';
94
+ }
95
+
96
+ ul {
97
+ list-style: none;
98
+ padding-left: 0;
99
+ margin-bottom: 0;
100
+ }
101
+
102
+ // DEPRECATED: Replaced with va-button web component
103
+ .va-button-primary {
104
+ border: 2px solid $vads-color-white;
105
+ color: $vads-color-white;
106
+ padding: scale-rem(1rem);
107
+ margin: scale-rule(0.8rem 1.6rem);
108
+ width: auto;
109
+
110
+ &:visited {
111
+ color: $vads-color-white;
112
+ }
113
+
114
+ @include media($medium-screen) {
115
+ border-color: transparent;
116
+ display: inline-block;
117
+ }
118
+ }
119
+
120
+ .usa-button-secondary {
121
+ padding: scale-rule(calc(1rem + 2px));
122
+ margin: scale-rule(0.8rem 1.6rem);
123
+ width: auto;
124
+ background-color: $color-gray-lightest;
125
+
126
+ &:hover {
127
+ text-decoration: none;
128
+ }
129
+
130
+ @include media($medium-screen) {
131
+ display: inline-block;
132
+ background-color: transparent;
133
+ &.vetnav-level2-button-second {
134
+ margin-left: 0;
135
+ }
136
+ }
137
+ }
138
+ }
139
+
140
+ #vetnav-controls {
141
+ position: relative;
142
+ width: 100px;
143
+
144
+ svg {
145
+ display: inline-block;
146
+ height: scale-rem(1.6rem);
147
+ margin-right: scale-rem(0.8rem);
148
+ width: scale-rem(1rem);
149
+ vertical-align: 0;
150
+ }
151
+
152
+ path {
153
+ fill: $vads-color-white;
154
+ }
155
+
156
+ @include media($medium-screen) {
157
+ display: none;
158
+ }
159
+ }
160
+
161
+ [class^='vetnav-controller'] {
162
+ position: absolute;
163
+ top: 0;
164
+ left: 0;
165
+ margin: 0;
166
+ min-width: 100px;
167
+ width: auto;
168
+
169
+ &[hidden] {
170
+ display: none;
171
+ }
172
+ }
173
+
174
+ @include media($medium-screen) {
175
+ a.vetnav-level1 {
176
+ //border-bottom: 1px solid transparent;
177
+
178
+ &:hover {
179
+ background-color: $color-primary;
180
+ border-bottom-color: $color-primary;
181
+ transition: none;
182
+ }
183
+ }
184
+ }
185
+
186
+ .vetnav-level1 {
187
+ -webkit-font-smoothing: antialiased;
188
+ background-color: $color-primary-darker;
189
+ background-position: scale-rule(right 3rem center);
190
+ background-repeat: no-repeat;
191
+ background-size: scale-rule(1.3rem auto);
192
+ border-radius: 0;
193
+ border-top: 3px solid transparent;
194
+ color: $vads-color-white;
195
+ cursor: pointer;
196
+ display: block;
197
+ font-weight: bold;
198
+ line-height: 1;
199
+ margin: 0;
200
+ padding: scale-rem(1.6rem);
201
+ text-align: left;
202
+ text-decoration: none;
203
+ width: 100%;
204
+
205
+ &:not([href]) {
206
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/minus-white.svg);
207
+ @include media($medium-screen) {
208
+ background-position: scale-rule(right 1.6rem center);
209
+ padding-right: scale-rem(3.2rem);
210
+ }
211
+ }
212
+
213
+ &[aria-expanded='true'] {
214
+ @include media($medium-screen) {
215
+ color: $color-base;
216
+ background-color: $vads-color-white;
217
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-up.svg);
218
+ border-top-color: $vads-color-va-accent;
219
+ }
220
+ }
221
+
222
+ &[aria-expanded='false'] {
223
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/plus-white.svg);
224
+
225
+ &:hover {
226
+ background-color: $color-primary;
227
+ }
228
+
229
+ @include media($medium-screen) {
230
+ background-image: url(~@department-of-veterans-affairs/css-library/dist/img/arrow-down-white.svg);
231
+ }
232
+ }
233
+
234
+ @include media($medium-screen) {
235
+ background-color: transparent;
236
+ background-size: scale-rule(1rem auto);
237
+ }
238
+
239
+ &:active {
240
+ color: inherit;
241
+ }
242
+
243
+ &:hover {
244
+ text-decoration: none;
245
+ }
246
+
247
+ &:visited,
248
+ &:active {
249
+ color: inherit;
250
+ }
251
+ }
252
+
253
+ .vetnav-level2 {
254
+ background: $color-primary-darkest url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right-white.svg) right 3rem
255
+ center no-repeat;
256
+ background-size: scale-rule(1.4rem auto);
257
+ border-radius: 0;
258
+ display: block;
259
+ font-weight: normal;
260
+ margin: 0;
261
+ padding: scale-rem(1.6rem);
262
+ text-align: left;
263
+ width: 100%;
264
+ -webkit-font-smoothing: antialiased;
265
+
266
+ @include media($medium-screen) {
267
+ background: scale-rule(transparent url(~@department-of-veterans-affairs/css-library/dist/img/arrow-right.svg) right 1rem center
268
+ no-repeat);
269
+ border-color: transparent;
270
+ border-style: solid;
271
+ border-width: 1px 0;
272
+ color: $color-link-default;
273
+ background-size: scale-rule(1rem auto);
274
+ margin-left: scale-rem(0.8rem);
275
+ padding: scale-rule(0.8rem 0 0.8rem 1.6rem);
276
+ position: relative;
277
+ width: scale-rem(25.3rem);
278
+
279
+ &:hover {
280
+ background-color: transparent;
281
+ border-bottom: 1px solid transparent;
282
+ box-shadow: -3px 0 $vads-color-va-accent;
283
+ color: $color-primary;
284
+ text-decoration: underline;
285
+ }
286
+
287
+ &[aria-expanded='true'] {
288
+ background-color: $color-gray-lightest;
289
+ border-bottom-color: $vads-color-gray-warm-light;
290
+ border-top-color: $vads-color-gray-warm-light;
291
+ box-shadow: -3px 0 $vads-color-va-accent;
292
+ color: $color-gray-dark;
293
+ font-weight: bold;
294
+ text-decoration: inherit;
295
+ position: relative;
296
+ z-index: 2;
297
+ }
298
+ }
299
+
300
+ &-heading {
301
+ -webkit-font-smoothing: antialiased;
302
+ font-size: scale-rem(2rem);
303
+ font-weight: bold;
304
+ padding: scale-rule(0.8rem 1.6rem);
305
+
306
+ @include media($medium-screen) {
307
+ display: none;
308
+ }
309
+ }
310
+ }
311
+
312
+ #vetnav .back-button {
313
+ background: scale-rule($color-primary-darker url(~@department-of-veterans-affairs/css-library/dist/img/arrow-left-white.svg) right 3rem
314
+ center no-repeat);
315
+ background-position: scale-rule(left 1rem center);
316
+ background-size: scale-rule(1.4rem auto);
317
+ border-radius: 0;
318
+ padding: scale-rule(1.6rem 1.6rem 1.6rem 3rem);
319
+ text-align: left;
320
+ width: 100%;
321
+ margin: 0;
322
+
323
+ @include media($medium-screen) {
324
+ display: none;
325
+ }
326
+ }
327
+
328
+ .vetnav-panel {
329
+ a {
330
+ @include no-sr-content;
331
+
332
+ background-image: none;
333
+ color: $vads-color-white;
334
+ display: block;
335
+ padding: scale-rule(0.8rem 1.6rem);
336
+ text-decoration: none;
337
+
338
+ @include media($medium-screen) {
339
+ color: $color-link-default;
340
+
341
+ &:hover {
342
+ background: transparent;
343
+ text-decoration: underline;
344
+ }
345
+ }
346
+ }
347
+
348
+ @include media($medium-screen) {
349
+ box-shadow: 0 5px 9px -5px $color-base;
350
+ background: $vads-color-white;
351
+ padding-bottom: scale-rem(1.6rem);
352
+ position: absolute;
353
+ }
354
+ }
355
+
356
+ .vetnav-panel--submenu {
357
+ &:not([hidden]) {
358
+ background-color: $color-primary-darkest;
359
+ box-shadow: none;
360
+ position: absolute;
361
+ width: 100%;
362
+ top: 0;
363
+ left: 30px;
364
+ visibility: visible;
365
+ margin: 0;
366
+
367
+ @include media($medium-screen) {
368
+ border-left: 1px solid $vads-color-gray-warm-light;
369
+ background-color: $color-gray-lightest;
370
+ height: 100%;
371
+ margin-left: scale-rem(23rem);
372
+ padding: scale-rule(0.5rem 0 1.6rem);
373
+ width: scale-rem(31rem);
374
+ }
375
+ }
376
+ }
377
+
378
+ @include media($medium-screen) {
379
+ #vetnav-explore {
380
+ height: 415px;
381
+ padding-top: scale-rem(0.8rem);
382
+ width: 540px;
383
+ }
384
+
385
+ #vetnav-benefits {
386
+ width: 276.47px;
387
+ }
388
+ }
389
+
390
+ .vet-toolbar {
391
+ align-items: center;
392
+ flex: 1 1 100%;
393
+ margin-left: scale-rem(-2rem);
394
+ position: relative;
395
+
396
+ > [data-reactroot],
397
+ > div {
398
+ align-items: center;
399
+ display: flex;
400
+ }
401
+
402
+ @include media($medium-screen) {
403
+ flex: scale-rule(0 1 32.5rem);
404
+ margin-left: 0;
405
+ margin-right: 0;
406
+ z-index: 3;
407
+ }
408
+
409
+ p {
410
+ margin: 0;
411
+ }
412
+
413
+ [href^='tel'] {
414
+ text-decoration: none;
415
+ }
416
+
417
+ ul {
418
+ list-style: none;
419
+ margin: 0;
420
+ padding-left: 0;
421
+ }
422
+
423
+ .va-dropdown,
424
+ .sign-in-link {
425
+ margin-left: scale-rem(1rem);
426
+ }
427
+
428
+ .va-dropdown-trigger {
429
+ font-weight: 600;
430
+ }
431
+ }
432
+
433
+ .sign-in-link {
434
+ line-height: 16px;
435
+ white-space: nowrap;
436
+ }
437
+
438
+ [id='search'] {
439
+ width: scale-rem(30rem);
440
+
441
+ [type='text'] {
442
+ margin: 0;
443
+ flex: scale-rule(1 0 20rem);
444
+ }
445
+
446
+ [type='submit'] {
447
+ border-radius: scale-rule(0 0.3rem 0.3rem 0);
448
+ display: flex;
449
+ flex: scale-rule(1 0 3rem);
450
+ justify-content: center;
451
+ margin: 0;
452
+ padding: scale-rem(1rem);
453
+ }
454
+
455
+ > .va-flex {
456
+ align-items: center;
457
+ }
458
+ }
459
+
460
+ .child-menu-opened {
461
+ height: 0;
462
+ overflow: hidden;
463
+ }
464
+
465
+ @include media($medium-screen) {
466
+ .child-menu-opened {
467
+ height: auto;
468
+ }
469
+ }
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * Do not edit directly
3
- * Generated on Mon, 10 Mar 2025 17:45:00 GMT
3
+ * Generated on Tue, 11 Mar 2025 21:20:35 GMT
4
4
  */
5
5
 
6
6
  :root {
@@ -1,6 +1,6 @@
1
1
 
2
2
  // Do not edit directly
3
- // Generated on Mon, 10 Mar 2025 17:45:00 GMT
3
+ // Generated on Tue, 11 Mar 2025 21:20:35 GMT
4
4
 
5
5
  $xsmall-screen: 320px;
6
6
  $small-screen: 481px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@department-of-veterans-affairs/css-library",
3
- "version": "0.20.0-rc1",
3
+ "version": "0.20.0",
4
4
  "description": "Department of Veterans Affairs stylesheets, tokens, and utilities",
5
5
  "packageManager": "yarn@3.2.0",
6
6
  "files": [
@@ -17,7 +17,7 @@
17
17
  "build:minify-core": "sass --style compressed dist/core.css:dist/core.min.css",
18
18
  "build": "yarn run clean-dist && yarn run copy && yarn build:tokens && yarn build:stylesheets && yarn copy:scss-files",
19
19
  "clean-dist": "rimraf dist/*",
20
- "copy:scss-files": "cp -rv src/stylesheets/_override-function.scss dist/stylesheets/_override-function.scss && cp -rv src/stylesheets/_mixins.scss dist/stylesheets/_mixins.scss && cp -rv src/stylesheets/_functions.scss dist/stylesheets/_functions.scss && cp -rv src/stylesheets/formation-overrides/_variables.scss dist/stylesheets/formation-overrides/_variables.scss",
20
+ "copy:scss-files": "cp -rv src/stylesheets/_override-function.scss dist/stylesheets/_override-function.scss && cp -rv src/stylesheets/_mixins.scss dist/stylesheets/_mixins.scss && cp -rv src/stylesheets/_functions.scss dist/stylesheets/_functions.scss && cp -rv src/stylesheets/formation-overrides/_variables.scss dist/stylesheets/formation-overrides/_variables.scss && mkdir dist/stylesheets/site && cp -rv src/stylesheets/site/* dist/stylesheets/site",
21
21
  "copy-assets": "cp -rv src/assets/fonts dist/fonts/ && cp -rv src/assets/img dist/img/",
22
22
  "copy": "node ./copy-uswds-color-tokens.js && yarn run copy-assets"
23
23
  },