@byuhbll/components 6.1.1 → 6.2.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@byuhbll/components",
3
- "version": "6.1.1",
3
+ "version": "6.2.0",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^20.3.15",
6
6
  "@angular/core": "^20.3.15"
@@ -28,6 +28,9 @@
28
28
  "./spinner": {
29
29
  "sass": "./styles/scss/spinner.scss"
30
30
  },
31
+ "./hbll-foundation": {
32
+ "sass": "./styles/scss/foundation.scss"
33
+ },
31
34
  "./package.json": {
32
35
  "default": "./package.json"
33
36
  },
@@ -0,0 +1,557 @@
1
+ // ---------------------------------------------------
2
+ // BYU Library Shared Styles
3
+ // ---------------------------------------------------
4
+
5
+ // ---------------------------------------------------
6
+ // Reset / Base
7
+ // ---------------------------------------------------
8
+
9
+ html {
10
+ border: 0;
11
+ margin: 0;
12
+ padding: 0;
13
+ -webkit-text-size-adjust: 100%;
14
+ }
15
+
16
+ body {
17
+ margin: 0;
18
+ padding: 0;
19
+ }
20
+
21
+ *,
22
+ *::before,
23
+ *::after {
24
+ box-sizing: border-box;
25
+ }
26
+
27
+ // ---------------------------------------------------
28
+ // Colors (Design Tokens)
29
+ // ---------------------------------------------------
30
+
31
+ // Brand Colors
32
+ $color-navy: #00245d;
33
+ $color-royal: #0047ba;
34
+ $color-white: #ffffff;
35
+
36
+ // Blues / Royal (Primary)
37
+ $color-blue-500: #00245d;
38
+ $color-blue-400: #003995;
39
+ $color-blue-300: #0047ba;
40
+ $color-blue-200: #336cc8;
41
+ $color-blue-150: #ccdaf1;
42
+ $color-blue-100: #e5edf8;
43
+
44
+ // Grays / Neutral
45
+ $color-gray-500: #141414;
46
+ $color-gray-400: #737373;
47
+ $color-gray-300: #8f8f8f;
48
+ $color-gray-200: #d0d0d0;
49
+ $color-gray-100: #e7e7e7;
50
+ $color-gray-50: #f9f9f9;
51
+
52
+ // Greens / Success
53
+ $color-green-500: #1d562e;
54
+ $color-green-400: #2e8545;
55
+ $color-green-300: #3ba35a;
56
+ $color-green-200: #9dd1ac;
57
+ $color-green-100: #ebf6ee;
58
+
59
+ // Teals / Info
60
+ $color-teal-500: #26485f;
61
+ $color-teal-400: #3e7295;
62
+ $color-teal-300: #457fa6;
63
+ $color-teal-200: #a2bfd3;
64
+ $color-teal-100: #ecf2f6;
65
+
66
+ // Reds / Error
67
+ $color-red-500: #702121;
68
+ $color-red-400: #b33837;
69
+ $color-red-300: #c73e3d;
70
+ $color-red-200: #e39e9e;
71
+ $color-red-100: #f9ecec;
72
+
73
+ // Yellows / Warning (Mustard)
74
+ $color-yellow-500: #635f04;
75
+ $color-yellow-400: #928c30;
76
+ $color-yellow-300: #d1c844;
77
+ $color-yellow-200: #e8e3a1;
78
+ $color-yellow-100: #f2f0e9;
79
+
80
+ // Purple / Focus
81
+ $color-purple-focus: #b967c7;
82
+
83
+ // ---------------------------------------------------
84
+ // Semantic Tokens (preferred usage across apps)
85
+ // ---------------------------------------------------
86
+
87
+ $text-heading: #002e5d;
88
+ $text-secondary-heading: #737373;
89
+ $text-body: $color-gray-500;
90
+ $text-disabled: $color-gray-400;
91
+ $text-link: $color-blue-200;
92
+ $text-on-action: $color-white;
93
+
94
+ $focus-ring-color: $color-purple-focus;
95
+
96
+ // State semantics (useful for alerts, badges, etc.)
97
+ $text-success: $color-green-500;
98
+ $text-info: $color-teal-500;
99
+ $text-error: $color-red-500;
100
+ $text-warning: $color-yellow-500;
101
+
102
+ $surface-success: $color-green-100;
103
+ $surface-info: $color-teal-100;
104
+ $surface-error: $color-red-100;
105
+ $surface-warning: $color-yellow-100;
106
+
107
+ // ---------------------------------------------------
108
+ // Expose CSS Custom Properties (so non-Sass apps can consume)
109
+ // ---------------------------------------------------
110
+
111
+ :root {
112
+ /* Brand */
113
+ --color-navy: #{$color-navy};
114
+ --color-royal: #{$color-royal};
115
+ --color-white: #{$color-white};
116
+
117
+ /* Royal (Primary) */
118
+ --color-blue-500: #{$color-blue-500};
119
+ --color-blue-400: #{$color-blue-400};
120
+ --color-blue-300: #{$color-blue-300};
121
+ --color-blue-200: #{$color-blue-200};
122
+ --color-blue-150: #{$color-blue-150};
123
+ --color-blue-100: #{$color-blue-100};
124
+
125
+ /* Neutral */
126
+ --color-gray-500: #{$color-gray-500};
127
+ --color-gray-400: #{$color-gray-400};
128
+ --color-gray-300: #{$color-gray-300};
129
+ --color-gray-200: #{$color-gray-200};
130
+ --color-gray-100: #{$color-gray-100};
131
+ --color-gray-50: #{$color-gray-50};
132
+ --color-gray-brand-400: #{$color-gray-400};
133
+
134
+ /* Success */
135
+ --color-green-500: #{$color-green-500};
136
+ --color-green-400: #{$color-green-400};
137
+ --color-green-300: #{$color-green-300};
138
+ --color-green-200: #{$color-green-200};
139
+ --color-green-100: #{$color-green-100};
140
+
141
+ /* Info */
142
+ --color-teal-500: #{$color-teal-500};
143
+ --color-teal-400: #{$color-teal-400};
144
+ --color-teal-300: #{$color-teal-300};
145
+ --color-teal-200: #{$color-teal-200};
146
+ --color-teal-100: #{$color-teal-100};
147
+
148
+ /* Error */
149
+ --color-red-500: #{$color-red-500};
150
+ --color-red-400: #{$color-red-400};
151
+ --color-red-300: #{$color-red-300};
152
+ --color-red-200: #{$color-red-200};
153
+ --color-red-100: #{$color-red-100};
154
+
155
+ /* Warning */
156
+ --color-yellow-500: #{$color-yellow-500};
157
+ --color-yellow-400: #{$color-yellow-400};
158
+ --color-yellow-300: #{$color-yellow-300};
159
+ --color-yellow-200: #{$color-yellow-200};
160
+ --color-yellow-100: #{$color-yellow-100};
161
+
162
+ /* Focus */
163
+ --color-purple-focus: #{$color-purple-focus};
164
+
165
+ /* Semantic text */
166
+ --text-heading: #{$text-heading};
167
+ --text-secondary-heading: #{$text-secondary-heading};
168
+ --text-body: #{$text-body};
169
+ --text-disabled: #{$text-disabled};
170
+ --text-link: #{$text-link};
171
+ --text-on-action: #{$text-on-action};
172
+
173
+ /* Semantic states */
174
+ --text-success: #{$text-success};
175
+ --text-info: #{$text-info};
176
+ --text-error: #{$text-error};
177
+ --text-warning: #{$text-warning};
178
+
179
+ --surface-success: #{$surface-success};
180
+ --surface-info: #{$surface-info};
181
+ --surface-error: #{$surface-error};
182
+ --surface-warning: #{$surface-warning};
183
+
184
+ --focus-ring-color: #{$focus-ring-color};
185
+ }
186
+
187
+ // ---------------------------------------------------
188
+ // Fonts
189
+ // ---------------------------------------------------
190
+
191
+ $sourceSansProVersion: '1.0.0';
192
+
193
+ @font-face {
194
+ font-family: 'Source Sans Pro';
195
+ font-style: normal;
196
+ font-weight: 300;
197
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-Light.ttf')
198
+ format('truetype');
199
+ font-display: swap;
200
+ }
201
+
202
+ @font-face {
203
+ font-family: 'Source Sans Pro';
204
+ font-style: normal;
205
+ font-weight: 400;
206
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-Regular.ttf')
207
+ format('truetype');
208
+ font-display: swap;
209
+ }
210
+
211
+ @font-face {
212
+ font-family: 'Source Sans Pro';
213
+ font-style: normal;
214
+ font-weight: 600;
215
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-Semibold.ttf')
216
+ format('truetype');
217
+ font-display: swap;
218
+ }
219
+
220
+ @font-face {
221
+ font-family: 'Source Sans Pro';
222
+ font-style: normal;
223
+ font-weight: 700;
224
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-Bold.ttf')
225
+ format('truetype');
226
+ font-display: swap;
227
+ }
228
+
229
+ @font-face {
230
+ font-family: 'Source Sans Pro';
231
+ font-style: italic;
232
+ font-weight: 300;
233
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-LightItalic.ttf')
234
+ format('truetype');
235
+ font-display: swap;
236
+ }
237
+
238
+ @font-face {
239
+ font-family: 'Source Sans Pro';
240
+ font-style: italic;
241
+ font-weight: 400;
242
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-Italic.ttf')
243
+ format('truetype');
244
+ font-display: swap;
245
+ }
246
+
247
+ @font-face {
248
+ font-family: 'Source Sans Pro';
249
+ font-style: italic;
250
+ font-weight: 600;
251
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-SemiboldItalic.ttf')
252
+ format('truetype');
253
+ font-display: swap;
254
+ }
255
+
256
+ @font-face {
257
+ font-family: 'Source Sans Pro';
258
+ font-style: italic;
259
+ font-weight: 700;
260
+ src: url('https://media.lib.byu.edu/web-assets/fonts/sourcesanspro/#{$sourceSansProVersion}/SourceSansPro-BoldItalic.ttf')
261
+ format('truetype');
262
+ font-display: swap;
263
+ }
264
+
265
+ // ---------------------------------------------------
266
+ // Default Styles for Elements
267
+ // ---------------------------------------------------
268
+
269
+ // Default font-family
270
+ h1,
271
+ h2,
272
+ h3,
273
+ h4,
274
+ h5,
275
+ h6,
276
+ span,
277
+ a,
278
+ p {
279
+ font-family: 'Source Sans Pro';
280
+ }
281
+
282
+ // Headers
283
+ h1 {
284
+ font-weight: 300;
285
+ font-style: normal;
286
+ color: var(--text-heading);
287
+ }
288
+
289
+ h2 {
290
+ font-weight: 400;
291
+ font-style: normal;
292
+ color: var(--text-heading);
293
+ }
294
+
295
+ h3 {
296
+ font-weight: 700;
297
+ font-style: normal;
298
+ color: var(--text-heading);
299
+ }
300
+
301
+ h4 {
302
+ font-weight: 600;
303
+ font-style: normal;
304
+ color: var(--text-secondary-heading);
305
+ }
306
+
307
+ h5 {
308
+ font-weight: 600;
309
+ font-style: normal;
310
+ color: var(--text-secondary-heading);
311
+ }
312
+
313
+ h6 {
314
+ font-weight: 600;
315
+ font-style: normal;
316
+ color: var(--text-secondary-heading);
317
+ }
318
+
319
+ // Paragraph classes
320
+ .hbll-default-body {
321
+ font-weight: 400;
322
+ font-style: normal;
323
+
324
+ max-width: 35rem;
325
+ min-width: 22.25rem;
326
+
327
+ color: var(--text-body);
328
+ }
329
+
330
+ .hbll-caption {
331
+ font-weight: 400;
332
+ font-style: normal;
333
+
334
+ max-width: 25.25rem;
335
+ min-width: 17.5rem;
336
+
337
+ color: var(--text-body);
338
+ }
339
+
340
+ .hbll-large {
341
+ font-weight: 400;
342
+ font-style: normal;
343
+
344
+ max-width: 41.25rem;
345
+ min-width: 26.5rem;
346
+
347
+ color: var(--text-body);
348
+ }
349
+
350
+ // Default link style
351
+ a {
352
+ color: var(--text-link);
353
+ text-decoration: underline;
354
+ }
355
+
356
+ // Span emphasis class
357
+ .hbll-emphasis {
358
+ font-weight: 600;
359
+ }
360
+
361
+ // ---------------------------------------------------
362
+ // Breakpoint size changes (mobile-first)
363
+ // ---------------------------------------------------
364
+
365
+ // Mobile default sizes (applies to all widths unless overridden)
366
+ h1 {
367
+ font-size: 2rem;
368
+ line-height: 2.5rem;
369
+ margin-bottom: 2.5rem;
370
+ margin-top: 2.5rem;
371
+ }
372
+ h2 {
373
+ font-size: 1.75rem;
374
+ line-height: 2.25rem;
375
+ margin-bottom: 2rem;
376
+ margin-top: 2rem;
377
+ }
378
+ h3 {
379
+ font-size: 1.5rem;
380
+ line-height: 2rem;
381
+ margin-bottom: 1.75rem;
382
+ margin-top: 1.75rem;
383
+ }
384
+ h4 {
385
+ font-size: 1.5rem;
386
+ line-height: 2rem;
387
+ margin-bottom: 1.5rem;
388
+ margin-top: 1.5rem;
389
+ }
390
+ h5 {
391
+ font-size: 1.25rem;
392
+ line-height: 1.75rem;
393
+ margin-bottom: 1.25rem;
394
+ margin-top: 1.25rem;
395
+ }
396
+ h6 {
397
+ font-size: 1.25rem;
398
+ line-height: 1.75rem;
399
+ margin-bottom: 1.5rem;
400
+ margin-top: 1rem;
401
+ }
402
+ .hbll-default-body {
403
+ font-size: 0.875rem;
404
+ line-height: 1.25rem;
405
+ }
406
+ .hbll-caption {
407
+ font-size: 0.75rem;
408
+ line-height: 1rem;
409
+ }
410
+ .hbll-large {
411
+ font-size: 1rem;
412
+ line-height: 1.5rem;
413
+ }
414
+
415
+ // Tablet size styles (>834px)
416
+ @media screen and (min-width: 52.125em) {
417
+ h1 {
418
+ font-size: 3rem;
419
+ line-height: 3.5rem;
420
+ margin-bottom: 3rem;
421
+ margin-top: 3rem;
422
+ }
423
+
424
+ h2 {
425
+ font-size: 2.5rem;
426
+ line-height: 3rem;
427
+ margin-bottom: 2.5rem;
428
+ margin-top: 2.5rem;
429
+ }
430
+
431
+ h3 {
432
+ font-size: 2rem;
433
+ line-height: 3rem;
434
+ margin-bottom: 2.25rem;
435
+ margin-top: 2.25rem;
436
+ }
437
+
438
+ h4 {
439
+ font-size: 1.75rem;
440
+ line-height: 2.5rem;
441
+ margin-bottom: 2rem;
442
+ margin-top: 2rem;
443
+ }
444
+
445
+ h5 {
446
+ font-size: 1.5rem;
447
+ line-height: 2rem;
448
+ margin-bottom: 1.75rem;
449
+ margin-top: 1.75rem;
450
+ }
451
+
452
+ h6 {
453
+ font-size: 1.25rem;
454
+ line-height: 1.75rem;
455
+ margin-bottom: 1.5rem;
456
+ margin-top: 1.5rem;
457
+ }
458
+
459
+ .hbll-default-body {
460
+ font-size: 1rem;
461
+ line-height: 1.5rem;
462
+ }
463
+
464
+ .hbll-caption {
465
+ font-size: 0.75rem;
466
+ line-height: 1rem;
467
+ }
468
+
469
+ .hbll-large {
470
+ font-size: 1.25rem;
471
+ line-height: 1.75rem;
472
+ }
473
+ }
474
+
475
+ // Desktop size styles (>1440px)
476
+ @media screen and (min-width: 90em) {
477
+ h1 {
478
+ font-size: 3.75rem;
479
+ line-height: 4.25rem;
480
+ margin-bottom: 3rem;
481
+ margin-top: 3rem;
482
+ }
483
+
484
+ h2 {
485
+ font-size: 3rem;
486
+ line-height: 3.5rem;
487
+ margin-bottom: 2.5rem;
488
+ margin-top: 2.5rem;
489
+ }
490
+
491
+ h3 {
492
+ font-size: 2.5rem;
493
+ line-height: 3rem;
494
+ margin-bottom: 2.25rem;
495
+ margin-top: 2.25rem;
496
+ }
497
+
498
+ h4 {
499
+ font-size: 2rem;
500
+ line-height: 2.5rem;
501
+ margin-bottom: 2rem;
502
+ margin-top: 2rem;
503
+ }
504
+
505
+ h5 {
506
+ font-size: 1.5rem;
507
+ line-height: 2rem;
508
+ margin-bottom: 1.75rem;
509
+ margin-top: 1.75rem;
510
+ }
511
+
512
+ h6 {
513
+ font-size: 1.25rem;
514
+ line-height: 1.75rem;
515
+ margin-bottom: 1.5rem;
516
+ margin-top: 1.5rem;
517
+ }
518
+
519
+ .hbll-default-body {
520
+ font-size: 1rem;
521
+ line-height: 1.5rem;
522
+ }
523
+
524
+ .hbll-caption {
525
+ font-size: 0.75rem;
526
+ line-height: 1rem;
527
+ }
528
+
529
+ .hbll-large {
530
+ font-size: 1.25rem;
531
+ line-height: 1.75rem;
532
+ }
533
+ }
534
+
535
+ // ---------------------------------------------------
536
+ // Accessibility
537
+ // ---------------------------------------------------
538
+
539
+ .sr-only {
540
+ position: absolute;
541
+ width: 1px;
542
+ height: 1px;
543
+ padding: 0;
544
+ margin: -1px;
545
+ overflow: hidden;
546
+ clip: rect(0, 0, 0, 0);
547
+ border: 0;
548
+ }
549
+
550
+ .sr-only-focusable {
551
+ position: static;
552
+ width: auto;
553
+ height: auto;
554
+ margin: 0;
555
+ overflow: visible;
556
+ clip: auto;
557
+ }