@teamimpact/veda-ui-blocks 0.1.0-beta.7 → 0.1.0-beta.8

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.
Files changed (35) hide show
  1. package/README.md +2 -3
  2. package/dist/default.css +1388 -407
  3. package/dist/default.css.map +1 -1
  4. package/dist/disasters.css +1137 -151
  5. package/dist/disasters.css.map +1 -1
  6. package/dist/index.d.ts +110 -40
  7. package/dist/index.js +484 -54
  8. package/package.json +4 -6
  9. package/src/styles/components/banner.scss +0 -18
  10. package/src/styles/components/card-cta.scss +0 -90
  11. package/src/styles/components/card-detailed.scss +0 -164
  12. package/src/styles/components/card-mini.scss +0 -81
  13. package/src/styles/components/card-simple.scss +0 -79
  14. package/src/styles/components/card.scss +0 -284
  15. package/src/styles/components/compare-map.scss +0 -15
  16. package/src/styles/components/footer.scss +0 -256
  17. package/src/styles/components/header.scss +0 -212
  18. package/src/styles/components/index.scss +0 -11
  19. package/src/styles/components/tag.scss +0 -89
  20. package/src/styles/default/index.scss +0 -10
  21. package/src/styles/default/theme-tokens.scss +0 -84
  22. package/src/styles/disasters/card-cta.scss +0 -31
  23. package/src/styles/disasters/card-mini.scss +0 -4
  24. package/src/styles/disasters/card-simple.scss +0 -13
  25. package/src/styles/disasters/card.scss +0 -13
  26. package/src/styles/disasters/compare-map.scss +0 -3
  27. package/src/styles/disasters/fonts.scss +0 -29
  28. package/src/styles/disasters/footer.scss +0 -9
  29. package/src/styles/disasters/header.scss +0 -10
  30. package/src/styles/disasters/index.scss +0 -22
  31. package/src/styles/disasters/tag.scss +0 -6
  32. package/src/styles/disasters/theme-tokens.scss +0 -150
  33. package/src/styles/earthgov/footer.scss +0 -15
  34. package/src/styles/earthgov/index.scss +0 -12
  35. package/src/styles/earthgov/theme-tokens.scss +0 -104
@@ -1,256 +0,0 @@
1
- @use "uswds-core" as *;
2
-
3
- $theme-footer-background-color: $theme-body-background-color !default;
4
- $theme-footer-primary-link-color: $theme-link-color !default;
5
- $theme-footer-secondary-link-color: "ink" !default;
6
- $theme-footer-title-color: "ink" !default;
7
- $theme-footer-text-color: "ink" !default;
8
- $theme-footer-separator-color: "ink" !default;
9
-
10
- // LAYOUT
11
- .blocks-footer.usa-footer--slim {
12
- .usa-footer__primary-section > .grid-container,
13
- .usa-footer__secondary-section > .grid-container {
14
- section {
15
- padding-bottom: units(3);
16
- }
17
- }
18
-
19
- .usa-footer__primary-section {
20
- > .grid-container {
21
- padding-top: units(4);
22
-
23
- @include at-media("desktop") {
24
- padding-top: units(5);
25
- }
26
- }
27
- }
28
-
29
- .usa-footer__secondary-section {
30
- padding-top: 0;
31
- padding-bottom: 0;
32
-
33
- > .grid-container {
34
- padding-bottom: units(3);
35
-
36
- @include at-media("desktop") {
37
- padding-bottom: units(7);
38
- }
39
- }
40
- }
41
-
42
- .blocks-footer__primary-section-lower {
43
- display: grid;
44
- gap: units(5);
45
-
46
- @include at-media("desktop") {
47
- align-items: start;
48
- column-gap: units(8);
49
- grid-template-columns: (units(10) * 4) minmax(0, 1fr);
50
- }
51
- }
52
-
53
- .blocks-footer__secondary-section-lower {
54
- display: grid;
55
- gap: units(4);
56
- padding-top: units(3);
57
-
58
- @include at-media("desktop") {
59
- align-items: start;
60
- column-gap: units(8);
61
- grid-template-columns: minmax(0, auto) minmax(0, 1fr);
62
- }
63
- }
64
-
65
- .blocks-footer__secondary-meta {
66
- display: flex;
67
- flex-direction: column;
68
- gap: units(4);
69
-
70
- @include at-media("desktop") {
71
- column-gap: units(6);
72
- flex-direction: row;
73
- flex-wrap: wrap-reverse;
74
- justify-content: flex-end;
75
- }
76
- }
77
-
78
- .blocks-footer__title {
79
- display: grid;
80
- gap: units(1.5);
81
- }
82
-
83
- .usa-footer__primary-section,
84
- .usa-footer__secondary-section {
85
- nav {
86
- ul {
87
- display: flex;
88
- flex-direction: column;
89
- gap: units(3);
90
- @include add-list-reset;
91
-
92
- @include at-media("desktop") {
93
- flex-direction: row;
94
- flex-wrap: wrap;
95
- gap: units(5);
96
- }
97
- }
98
- }
99
- }
100
-
101
- .blocks-footer__primary-nav,
102
- .blocks-footer__secondary-nav {
103
- padding-top: units(2);
104
-
105
- @include at-media("desktop") {
106
- padding-top: units(3);
107
- }
108
- }
109
-
110
- .blocks-footer__primary-nav {
111
- ul {
112
- justify-content: flex-end;
113
- }
114
- }
115
-
116
- .usa-footer__secondary-link {
117
- line-height: inherit;
118
- margin-left: 0;
119
- padding: 0;
120
-
121
- & + .usa-footer__secondary-link {
122
- padding-top: 0;
123
- }
124
- }
125
-
126
- .blocks-footer__utility-nav,
127
- .blocks-footer__contacts-nav {
128
- display: flex;
129
- flex-wrap: wrap;
130
- gap: units(2);
131
-
132
- li {
133
- align-items: center;
134
- display: flex;
135
- gap: units(1.5);
136
-
137
- a {
138
- display: inline-flex;
139
- gap: units(1);
140
- align-items: center;
141
- }
142
- }
143
- }
144
-
145
- .blocks-footer__utility-nav ul {
146
- gap: units(1);
147
- }
148
-
149
- .blocks-footer__contacts-nav ul {
150
- gap: units(3);
151
-
152
- @include at-media("desktop") {
153
- align-items: center;
154
- gap: units(3);
155
- justify-content: flex-end;
156
- }
157
- }
158
-
159
- .blocks-footer__secondary-meta > p {
160
- margin: 0;
161
-
162
- @include at-media("desktop") {
163
- text-align: right;
164
- }
165
- }
166
- }
167
-
168
- // THEME
169
- .blocks-footer.usa-footer--slim {
170
- .usa-footer__primary-section,
171
- .usa-footer__secondary-section {
172
- background-color: color($theme-footer-background-color);
173
- color: color($theme-text-color);
174
- }
175
-
176
- .blocks-footer__primary-section-lower,
177
- .blocks-footer__secondary-section-upper {
178
- border-bottom: 1px solid rgba(color($theme-footer-separator-color), 0.1);
179
- }
180
-
181
- .blocks-footer__title {
182
- span {
183
- color: color($theme-footer-title-color);
184
- font-size: size("body", "lg");
185
- font-weight: font-weight("bold");
186
- text-decoration: none;
187
- }
188
-
189
- p {
190
- color: color($theme-footer-text-color);
191
- margin: 0;
192
- font-size: size("body", "2xs");
193
- line-height: line-height("body", 5);
194
- }
195
- }
196
-
197
- .usa-footer__primary-link {
198
- border: 0;
199
- color: color($theme-footer-primary-link-color);
200
- font-size: size("body", "2xs");
201
- font-weight: font-weight("bold");
202
- padding: 0;
203
- text-decoration: none;
204
-
205
- &:visited {
206
- color: color($theme-footer-primary-link-color);
207
- }
208
-
209
- &:hover,
210
- &:active {
211
- color: color($theme-footer-primary-link-color);
212
- text-decoration: underline;
213
- text-underline-offset: 0.18em;
214
- }
215
- }
216
-
217
- .usa-footer__secondary-link > a {
218
- color: color($theme-footer-secondary-link-color);
219
- font-size: size("body", "2xs");
220
- line-height: line-height("body", 5);
221
- text-decoration: underline;
222
- text-decoration-thickness: 1px;
223
- text-underline-offset: 0.18em;
224
-
225
- &:visited {
226
- color: color($theme-footer-secondary-link-color);
227
- }
228
-
229
- &:hover,
230
- &:active {
231
- color: color($theme-footer-secondary-link-color);
232
- text-decoration-thickness: 2px;
233
- }
234
- }
235
-
236
- .blocks-footer__secondary-section-lower {
237
- color: color($theme-footer-text-color);
238
- font-size: size("body", "2xs");
239
- }
240
-
241
- .blocks-footer__secondary-section-lower a {
242
- text-decoration: underline;
243
- text-decoration-thickness: 1px;
244
- text-underline-offset: 0.18em;
245
- color: color($theme-footer-primary-link-color);
246
- &:visited {
247
- color: color($theme-footer-primary-link-color);
248
- }
249
-
250
- &:hover,
251
- &:active {
252
- color: color($theme-footer-primary-link-color);
253
- text-decoration-thickness: 2px;
254
- }
255
- }
256
- }
@@ -1,212 +0,0 @@
1
- @use "uswds-core" as *;
2
- $theme-header-bgcolor: $theme-body-background-color !default;
3
- $theme-header-primary-link-text-color: "ink" !default;
4
- $theme-header-primary-link-hover-border-color: "primary" !default;
5
- $theme-header-mobile-link-hover-bgcolor: "base-lightest" !default;
6
- $theme-header-primary-button-link-text-color: $theme-text-reverse-color !default;
7
- $theme-header-primary-button-link-bgcolor: "primary" !default;
8
- $theme-header-primary-button-link-hover-bgcolor: "primary-dark" !default;
9
-
10
- // LAYOUT
11
- .blocks-header.usa-header--basic {
12
- // remove the default divider border on USWDS header
13
- + .usa-hero,
14
- + .usa-section,
15
- + main {
16
- @include at-media($theme-header-min-width) {
17
- border-top: none;
18
- }
19
- }
20
-
21
- .usa-nav-container {
22
- align-items: center;
23
- display: flex;
24
- padding-top: units(1);
25
- padding-bottom: units(1);
26
- @include grid-container($theme-header-max-width);
27
-
28
- .usa-navbar {
29
- border-bottom: none;
30
- flex: 1;
31
-
32
- .usa-menu-btn {
33
- height: 100%;
34
- }
35
- }
36
-
37
- @include at-media("desktop") {
38
- .usa-nav {
39
- padding: 0;
40
- width: auto;
41
- }
42
- }
43
- }
44
-
45
- .blocks-header__portal-details {
46
- align-items: center;
47
- display: flex;
48
- flex: 1 1 0%;
49
- flex-direction: row;
50
- gap: units(2);
51
-
52
- .blocks-header__portal-logo {
53
- display: inline-flex;
54
- }
55
-
56
- .usa-logo {
57
- margin: 0;
58
- line-height: normal;
59
- }
60
- }
61
-
62
- .usa-nav__close {
63
- cursor: pointer;
64
- }
65
-
66
- a.blocks-header__custom-nav-item {
67
- margin-right: 0;
68
- }
69
-
70
- .usa-nav__primary {
71
- @include at-media-max($theme-header-min-width) {
72
- margin-top: units(3);
73
- order: 2;
74
- }
75
-
76
- .usa-nav__primary-item {
77
- .usa-nav__link {
78
- padding: units(2);
79
- }
80
-
81
- @include at-media("desktop") {
82
- > button.usa-nav__link {
83
- &:hover,
84
- &.usa-current {
85
- &:after {
86
- bottom: units(0.5);
87
- content: "";
88
- display: block;
89
- height: 0.25rem;
90
- left: 1rem;
91
- position: absolute;
92
- right: 1rem;
93
- }
94
- }
95
- &:focus {
96
- outline-offset: units(-1);
97
- }
98
- }
99
-
100
- > a.usa-nav__link {
101
- &:hover,
102
- &.usa-current {
103
- &:after {
104
- bottom: units(0.5);
105
- }
106
- }
107
- &:focus {
108
- outline-offset: units(-1);
109
- }
110
- }
111
- }
112
- }
113
-
114
- @include at-media("desktop") {
115
- .usa-nav__submenu {
116
- margin-top: 4px;
117
- padding-left: units(2);
118
- padding-right: units(2);
119
-
120
- .usa-nav__submenu-item a {
121
- padding: units(2);
122
- }
123
- }
124
- }
125
- }
126
- }
127
-
128
- // THEME
129
- .blocks-header.usa-header--basic {
130
- background-color: color($theme-header-bgcolor);
131
-
132
- .blocks-header__portal-details {
133
- a {
134
- color: color($theme-header-primary-link-text-color);
135
- }
136
- }
137
-
138
- .usa-nav.is-visible {
139
- background-color: color($theme-header-bgcolor);
140
-
141
- .usa-nav__primary {
142
- button,
143
- a {
144
- &:hover {
145
- background-color: color($theme-header-mobile-link-hover-bgcolor);
146
- }
147
- }
148
- }
149
- }
150
-
151
- .usa-menu-btn {
152
- color: color($theme-header-primary-button-link-text-color);
153
- background-color: color($theme-header-primary-button-link-bgcolor);
154
- &:hover {
155
- background-color: color($theme-header-primary-button-link-hover-bgcolor);
156
- }
157
- }
158
-
159
- a.blocks-header__custom-nav-item {
160
- background-color: color($theme-header-primary-button-link-bgcolor);
161
- color: color($theme-header-primary-button-link-text-color);
162
- font-size: size("body", "2xs");
163
-
164
- &:hover {
165
- background-color: color($theme-header-primary-button-link-hover-bgcolor);
166
- }
167
- }
168
-
169
- .usa-nav__primary {
170
- .usa-nav__primary-item {
171
- > a.usa-nav__link {
172
- color: color($theme-header-primary-link-text-color);
173
- &.usa-current,
174
- &:hover {
175
- &:after {
176
- background-color: color($theme-header-primary-link-hover-border-color);
177
- }
178
- }
179
- }
180
-
181
- > button.usa-nav__link {
182
- @include at-media("desktop") {
183
- background-color: transparent;
184
- }
185
-
186
- color: color($theme-header-primary-link-text-color);
187
-
188
- &:hover,
189
- &.usa-current {
190
- &:after {
191
- background-color: color($theme-header-primary-link-hover-border-color);
192
- }
193
- }
194
-
195
- > span::after {
196
- background-color: color($theme-header-primary-link-text-color);
197
- }
198
- }
199
- }
200
-
201
- .usa-nav__submenu {
202
- background-color: color($theme-header-bgcolor);
203
-
204
- .usa-nav__submenu-item > a {
205
- color: color($theme-header-primary-link-text-color);
206
- @include at-media("desktop") {
207
- font-weight: $theme-font-weight-bold;
208
- }
209
- }
210
- }
211
- }
212
- }
@@ -1,11 +0,0 @@
1
- // Shared partials consumed by each theme entry after USWDS is loaded.
2
- @use "banner";
3
- @use "compare-map";
4
- @use "card";
5
- @use "card-cta";
6
- @use "card-detailed";
7
- @use "card-mini";
8
- @use "card-simple";
9
- @use "footer";
10
- @use "header";
11
- @use "tag";
@@ -1,89 +0,0 @@
1
- @use "uswds-core" as *;
2
-
3
- $theme-tag-border-radius: "sm" !default;
4
- $theme-tag-font-family: "mono" !default;
5
- $theme-tag-text-transform: none !default;
6
- $theme-tag-color: "base" !default;
7
- $theme-tag-solid-text-color: "white" !default;
8
-
9
- //LAYOUT
10
- .blocks-tag {
11
- align-items: center;
12
- flex-direction: row;
13
- display: inline-flex;
14
- gap: units(0.5);
15
- padding: units(0.5);
16
-
17
- &--big {
18
- padding: units(1);
19
- }
20
-
21
- &__icon,
22
- &__close-button {
23
- display: inline-flex;
24
- align-items: center;
25
- color: inherit;
26
-
27
- :where(svg, .usa-icon) {
28
- height: 1em;
29
- vertical-align: middle;
30
- width: auto;
31
- color: inherit;
32
- fill: currentColor;
33
- stroke: currentColor;
34
- }
35
-
36
- :where(path) {
37
- fill: currentColor;
38
- stroke: currentColor;
39
- }
40
- }
41
-
42
- &__close-button {
43
- border: 0;
44
- padding: 0;
45
- background: transparent;
46
- cursor: pointer;
47
- line-height: 1;
48
- color: inherit;
49
- }
50
- }
51
-
52
- // THEME
53
- .blocks-tag {
54
- border-radius: radius($theme-tag-border-radius);
55
- border: 1px solid transparent;
56
- font-family: family($theme-tag-font-family);
57
- font-size: size($theme-tag-font-family, "3xs");
58
- font-weight: font-weight("normal");
59
- line-height: lh($theme-tag-font-family, 2);
60
- text-transform: $theme-tag-text-transform;
61
-
62
- &--solid {
63
- color: var(--blocks-tag-custom-text-color, #{color($theme-tag-solid-text-color)});
64
- background-color: var(--blocks-tag-custom-color, #{color($theme-tag-color)});
65
- border-color: var(--blocks-tag-custom-color, #{color($theme-tag-color)});
66
- }
67
-
68
- &--outline {
69
- color: var(
70
- --blocks-tag-custom-text-color,
71
- var(--blocks-tag-custom-color, #{color($theme-tag-color)})
72
- );
73
- background-color: color("transparent");
74
- border-color: var(--blocks-tag-custom-color, #{color($theme-tag-color)});
75
- }
76
-
77
- &--text {
78
- color: var(
79
- --blocks-tag-custom-text-color,
80
- var(--blocks-tag-custom-color, #{color($theme-tag-color)})
81
- );
82
- background-color: transparent;
83
- border-color: transparent;
84
- }
85
-
86
- &--big {
87
- font-size: size($theme-tag-font-family, "2xs");
88
- }
89
- }
@@ -1,10 +0,0 @@
1
- // Default USWDS theme manifest
2
-
3
- // 1. Forward theme token configuration first (must be before uswds-core/@forward)
4
- @forward "theme-tokens";
5
-
6
- // 2. Then forward USWDS itself
7
- @forward "uswds";
8
-
9
- // 3. Forward all custom component styles via default theme component style aggregator
10
- @forward "../components/index";
@@ -1,84 +0,0 @@
1
- // Default USWDS theme configuration
2
- @use "uswds-core" with (
3
- // GENERAL SETTINGS
4
- // https://designsystem.digital.gov/documentation/settings/#general-settings-2
5
- $theme-show-notifications: false,
6
- $theme-show-compile-warnings: false,
7
- $theme-image-path: "./img",
8
-
9
- // COLOR SETTINGS
10
- // https://designsystem.digital.gov/documentation/settings/#color-settings-2
11
- // uses USWDS default color palette
12
- // COMPONENT SETTINGS
13
- // https://designsystem.digital.gov/documentation/settings/#component-settings-2
14
- $theme-banner-max-width: "desktop-lg",
15
- $theme-header-max-width: "desktop-lg",
16
- $theme-footer-max-width: "desktop-lg",
17
-
18
- // SPACING SETTINGS
19
- // https://designsystem.digital.gov/documentation/settings/#spacing-settings-2
20
- $theme-grid-container-max-width: "desktop-lg",
21
- $theme-site-margins-breakpoint: "desktop-lg",
22
- $theme-site-margins-width: 4,
23
- $theme-site-margins-mobile-width: 2,
24
-
25
- // TYPE SETTINGS
26
- // https: //designsystem.digital.gov/documentation/settings/#typography-settings-2
27
- $theme-font-path: "./fonts",
28
- $theme-font-type-mono: "roboto-mono",
29
- $theme-font-type-sans: "public-sans",
30
- $theme-font-type-serif: "merriweather",
31
-
32
- $theme-font-role-ui: "sans",
33
- $theme-font-role-heading: "serif",
34
- $theme-font-role-body: "sans",
35
- $theme-font-role-code: "mono",
36
- $theme-font-role-alt: "serif",
37
-
38
- $theme-type-scale-3xs: 1,
39
- $theme-type-scale-2xs: 3,
40
- $theme-type-scale-xs: 4,
41
- $theme-type-scale-sm: 5,
42
- $theme-type-scale-md: 7,
43
- $theme-type-scale-lg: 9,
44
- $theme-type-scale-xl: 12,
45
- $theme-type-scale-2xl: 14,
46
- $theme-type-scale-3xl: 15,
47
-
48
- $theme-font-weight-thin: false,
49
- $theme-font-weight-light: 300,
50
- $theme-font-weight-normal: 400,
51
- $theme-font-weight-medium: false,
52
- $theme-font-weight-semibold: 600,
53
- $theme-font-weight-bold: 700,
54
- $theme-font-weight-heavy: 900,
55
-
56
- // UTILITY SETTINGS
57
- // https://designsystem.digital.gov/documentation/settings/#utilities-settings-2s
58
- $utilities-use-important: false,
59
- $theme-utility-breakpoints: (
60
- "card": false,
61
- "card-lg": false,
62
- "mobile": true,
63
- "mobile-lg": false,
64
- "tablet": true,
65
- "tablet-lg": false,
66
- "desktop": true,
67
- "desktop-lg": true,
68
- "widescreen": true
69
- ),
70
-
71
- $overflow-settings: (responsive: true),
72
- $position-settings: (responsive: true),
73
- $top-settings: (responsive: true),
74
- $right-settings: (responsive: true),
75
- $left-settings: (responsive: true),
76
- $bottom-settings: (responsive: true),
77
- $z-index-settings: (responsive: true),
78
- $background-color-settings: (responsive: true),
79
- $font-style-settings: (responsive: true),
80
- $color-settings: (responsive: true, hover: true),
81
- $flex-direction-settings: (responsive: true),
82
- $flex-settings: (responsive: true),
83
- $order-settings: (responsive: true)
84
- );
@@ -1,31 +0,0 @@
1
- @use "uswds-core" as *;
2
- @use "../components/card-cta" with (
3
- $theme-card-cta-title-color: "white",
4
- $theme-card-cta-description-color: "white",
5
- $theme-card-cta-accent-color: "accent-warm",
6
- $theme-card-cta-border-color: "transparent"
7
- );
8
-
9
- // Disasters-specific overrides
10
- .blocks-card-cta {
11
- backdrop-filter: blur(10px);
12
- background-color: rgba(255, 255, 255, 0.05);
13
-
14
- &:hover,
15
- &:focus-visible {
16
- background-color: rgba(255, 255, 255, 0.1);
17
- }
18
-
19
- &__title {
20
- font-size: size("heading", "lg");
21
- font-weight: font-weight("bold");
22
- line-height: lh("heading", 3);
23
- text-underline-offset: units("05");
24
- }
25
-
26
- &__description {
27
- font-size: size("body", "sm");
28
- font-weight: font-weight("bold");
29
- line-height: lh("body", 4);
30
- }
31
- }
@@ -1,4 +0,0 @@
1
- @use "../components/card-mini" with (
2
- $theme-card-mini-border-width: 0,
3
- $theme-card-mini-border-color: "transparent"
4
- );
@@ -1,13 +0,0 @@
1
- @use "uswds-core" as *;
2
- @use "../components/card-simple" with (
3
- $theme-card-simple-border-radius: 0,
4
- $theme-card-simple-title-color: $theme-body-background-color,
5
- $theme-card-simple-title-font-weight: "semibold",
6
- $theme-card-simple-overlay-color: "base-darkest"
7
- );
8
-
9
- // Figma node 4030-1098: disasters title carries a subtle drop-shadow absent
10
- // from the default theme — not expressible as a single token value.
11
- .blocks-card-simple__title {
12
- text-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
13
- }