@bloom-housing/ui-components 4.2.2-alpha.2 → 4.2.2-alpha.22

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 (49) hide show
  1. package/CHANGELOG.md +192 -0
  2. package/README.md +10 -4
  3. package/index.ts +3 -0
  4. package/package.json +5 -3
  5. package/src/actions/Button.docs.mdx +76 -0
  6. package/src/actions/Button.scss +58 -61
  7. package/src/authentication/timeout.tsx +1 -0
  8. package/src/blocks/DashBlock.tsx +5 -3
  9. package/src/blocks/DashBlocks.scss +4 -1
  10. package/src/forms/FieldGroup.tsx +18 -17
  11. package/src/global/app-css.scss +7 -0
  12. package/src/global/markdown.scss +20 -0
  13. package/src/global/mixins.scss +66 -49
  14. package/src/global/tables.scss +236 -58
  15. package/src/global/text.scss +9 -1
  16. package/src/global/tokens/borders.scss +15 -0
  17. package/src/global/tokens/colors.scss +64 -0
  18. package/src/global/tokens/fonts.scss +45 -0
  19. package/src/global/tokens/screens.scss +6 -0
  20. package/src/global/tokens/sizes.scss +48 -0
  21. package/src/headers/Heading.tsx +1 -0
  22. package/src/headers/PageHeader.docs.mdx +45 -0
  23. package/src/headers/PageHeader.scss +30 -17
  24. package/src/headers/PageHeader.tsx +2 -10
  25. package/src/headers/SiteHeader.tsx +4 -1
  26. package/src/helpers/address.tsx +5 -4
  27. package/src/helpers/tableSummaries.tsx +34 -23
  28. package/src/locales/general.json +9 -2
  29. package/src/navigation/FooterNav.scss +2 -1
  30. package/src/overlays/Drawer.tsx +11 -3
  31. package/src/overlays/Modal.tsx +16 -7
  32. package/src/overlays/Overlay.tsx +4 -3
  33. package/src/page_components/ApplicationTimeline.scss +36 -0
  34. package/src/page_components/ApplicationTimeline.tsx +33 -0
  35. package/src/page_components/forgot-password/FormForgotPassword.tsx +5 -4
  36. package/src/page_components/listing/AdditionalFees.tsx +38 -31
  37. package/src/page_components/listing/ListingCard.scss +12 -0
  38. package/src/page_components/listing/ListingCard.tsx +5 -3
  39. package/src/page_components/listing/UnitTables.tsx +19 -18
  40. package/src/page_components/sign-in/FormSignIn.tsx +2 -1
  41. package/src/page_components/sign-in/ResendConfirmationModal.tsx +106 -0
  42. package/src/prototypes/Swatch.tsx +10 -0
  43. package/src/tables/CategoryTable.tsx +33 -0
  44. package/src/tables/GroupedTable.tsx +5 -5
  45. package/src/tables/MinimalTable.tsx +12 -2
  46. package/src/tables/StackedTable.tsx +38 -26
  47. package/src/tables/StandardTable.tsx +26 -10
  48. package/tailwind.config.js +76 -81
  49. package/tailwind.tosass.js +2 -1
package/CHANGELOG.md CHANGED
@@ -3,6 +3,198 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [4.2.2-alpha.22](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.21...@bloom-housing/ui-components@4.2.2-alpha.22) (2022-05-03)
7
+
8
+
9
+ ### Features
10
+
11
+ * **backend:** improve ami chart dto definitions ([#2677](https://github.com/bloom-housing/bloom/issues/2677)) ([ca3890e](https://github.com/bloom-housing/bloom/commit/ca3890e2759f230824e31e6bd985300f40b0a0ed))
12
+
13
+
14
+
15
+
16
+
17
+ ## [4.2.2-alpha.21](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.20...@bloom-housing/ui-components@4.2.2-alpha.21) (2022-04-29)
18
+
19
+ **Note:** Version bump only for package @bloom-housing/ui-components
20
+
21
+
22
+
23
+
24
+
25
+ ## [4.2.2-alpha.20](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.19...@bloom-housing/ui-components@4.2.2-alpha.20) (2022-04-29)
26
+
27
+
28
+ ### Bug Fixes
29
+
30
+ * ux updates for new listing card design ([#2687](https://github.com/bloom-housing/bloom/issues/2687)) ([c8814ae](https://github.com/bloom-housing/bloom/commit/c8814ae57b62fa6f932017bb70d47663b09fca1a))
31
+
32
+
33
+
34
+
35
+
36
+ ## [4.2.2-alpha.19](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.18...@bloom-housing/ui-components@4.2.2-alpha.19) (2022-04-28)
37
+
38
+ **Note:** Version bump only for package @bloom-housing/ui-components
39
+
40
+
41
+
42
+
43
+
44
+ ## [4.2.2-alpha.18](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.17...@bloom-housing/ui-components@4.2.2-alpha.18) (2022-04-28)
45
+
46
+ **Note:** Version bump only for package @bloom-housing/ui-components
47
+
48
+
49
+
50
+
51
+
52
+ ## [4.2.2-alpha.17](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.16...@bloom-housing/ui-components@4.2.2-alpha.17) (2022-04-28)
53
+
54
+ **Note:** Version bump only for package @bloom-housing/ui-components
55
+
56
+
57
+
58
+
59
+
60
+ ## [4.2.2-alpha.16](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.15...@bloom-housing/ui-components@4.2.2-alpha.16) (2022-04-27)
61
+
62
+ **Note:** Version bump only for package @bloom-housing/ui-components
63
+
64
+
65
+
66
+
67
+
68
+ ## [4.2.2-alpha.15](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.14...@bloom-housing/ui-components@4.2.2-alpha.15) (2022-04-26)
69
+
70
+ **Note:** Version bump only for package @bloom-housing/ui-components
71
+
72
+
73
+
74
+
75
+
76
+ ## [4.2.2-alpha.14](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.13...@bloom-housing/ui-components@4.2.2-alpha.14) (2022-04-22)
77
+
78
+
79
+ ### Features
80
+
81
+ * swap anchor tags with LinkComponent for language routes ([#2686](https://github.com/bloom-housing/bloom/issues/2686)) ([a397930](https://github.com/bloom-housing/bloom/commit/a3979306fe39acd7b424a9e7364d791ad77fa2d0))
82
+
83
+
84
+
85
+
86
+
87
+ ## [4.2.2-alpha.13](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.12...@bloom-housing/ui-components@4.2.2-alpha.13) (2022-04-22)
88
+
89
+ **Note:** Version bump only for package @bloom-housing/ui-components
90
+
91
+
92
+
93
+
94
+
95
+ ## [4.2.2-alpha.12](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.11...@bloom-housing/ui-components@4.2.2-alpha.12) (2022-04-22)
96
+
97
+
98
+ ### Bug Fixes
99
+
100
+ * forgot password empty warning and two minor style changes ([#2680](https://github.com/bloom-housing/bloom/issues/2680)) ([01f1519](https://github.com/bloom-housing/bloom/commit/01f15194e2de8595a772c8c87f455d882e47f164))
101
+
102
+
103
+
104
+
105
+
106
+ ## [4.2.2-alpha.11](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.10...@bloom-housing/ui-components@4.2.2-alpha.11) (2022-04-21)
107
+
108
+ **Note:** Version bump only for package @bloom-housing/ui-components
109
+
110
+
111
+
112
+
113
+
114
+ ## [4.2.2-alpha.10](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.9...@bloom-housing/ui-components@4.2.2-alpha.10) (2022-04-21)
115
+
116
+
117
+ ### Features
118
+
119
+ * new category table component ([#2648](https://github.com/bloom-housing/bloom/issues/2648)) ([3b3fe46](https://github.com/bloom-housing/bloom/commit/3b3fe46dda3d0e553664c10cea46849551ce064c))
120
+
121
+
122
+ ### BREAKING CHANGES
123
+
124
+ * There is a new prop interface for the StandardTable component and all components that use it, which includes passing cell content within a new object, allowing us to support new cell options - all tables will need to pass data with the new format.
125
+
126
+
127
+
128
+
129
+
130
+ ## [4.2.2-alpha.9](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.8...@bloom-housing/ui-components@4.2.2-alpha.9) (2022-04-20)
131
+
132
+ **Note:** Version bump only for package @bloom-housing/ui-components
133
+
134
+
135
+
136
+
137
+
138
+ ## [4.2.2-alpha.8](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.7...@bloom-housing/ui-components@4.2.2-alpha.8) (2022-04-20)
139
+
140
+
141
+ ### Features
142
+
143
+ * application timeout screen reader accessible ([#2625](https://github.com/bloom-housing/bloom/issues/2625)) ([0771ef3](https://github.com/bloom-housing/bloom/commit/0771ef3f7e4001efb4dae8cca06743801daace05))
144
+
145
+
146
+
147
+
148
+
149
+ ## [4.2.2-alpha.7](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.6...@bloom-housing/ui-components@4.2.2-alpha.7) (2022-04-20)
150
+
151
+ **Note:** Version bump only for package @bloom-housing/ui-components
152
+
153
+
154
+
155
+
156
+
157
+ ## [4.2.2-alpha.6](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.5...@bloom-housing/ui-components@4.2.2-alpha.6) (2022-04-20)
158
+
159
+ **Note:** Version bump only for package @bloom-housing/ui-components
160
+
161
+
162
+
163
+
164
+
165
+ ## [4.2.2-alpha.5](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.4...@bloom-housing/ui-components@4.2.2-alpha.5) (2022-04-19)
166
+
167
+
168
+ ### Bug Fixes
169
+
170
+ * footer nav widths ([42aef6f](https://github.com/bloom-housing/bloom/commit/42aef6f74a8a7e27c6bdb870cb6c69c7569f41c0))
171
+
172
+
173
+
174
+
175
+
176
+ ## [4.2.2-alpha.4](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.3...@bloom-housing/ui-components@4.2.2-alpha.4) (2022-04-18)
177
+
178
+
179
+ ### Bug Fixes
180
+
181
+ * add optional prop for Language Nav aria label ([#2672](https://github.com/bloom-housing/bloom/issues/2672)) ([5f1b3f6](https://github.com/bloom-housing/bloom/commit/5f1b3f66f5269cfd9285b958f608cdb41e779c70))
182
+
183
+
184
+
185
+
186
+
187
+ ## [4.2.2-alpha.3](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.2...@bloom-housing/ui-components@4.2.2-alpha.3) (2022-04-18)
188
+
189
+
190
+ ### Features
191
+
192
+ * refactor ada form fields ([#2612](https://github.com/bloom-housing/bloom/issues/2612)) ([f516f21](https://github.com/bloom-housing/bloom/commit/f516f2164249cea5b622b6bb5cd6efb5455003ca))
193
+
194
+
195
+
196
+
197
+
6
198
  ## [4.2.2-alpha.2](https://github.com/bloom-housing/bloom/compare/@bloom-housing/ui-components@4.2.2-alpha.1...@bloom-housing/ui-components@4.2.2-alpha.2) (2022-04-14)
7
199
 
8
200
  **Note:** Version bump only for package @bloom-housing/ui-components
package/README.md CHANGED
@@ -46,16 +46,22 @@ yarn test:a11y
46
46
 
47
47
  ## Tailwind
48
48
 
49
- - We are using the [Tailwind](https://v1.tailwindcss.com) framework to make use of their low-level utility library that styles components based on custom settings. We configure the settings in `tailwind.config`. Some styles live in a global folder, but for the most part our components are styled with isolated SCSS files.
49
+ - We are using the [Tailwind](https://v2.tailwindcss.com) framework to make use of their low-level utility classes in page-level markup and sometimes in components. We configure the settings in `tailwind.config.js`.
50
50
 
51
- - Use Tailwind where possible before creating custom style sheets or custom classes for consistency.
52
-
53
- Vendor Plugins
51
+ ## Vendor Plugins
54
52
 
55
53
  - [AG Grid](https://www.ag-grid.com)
56
54
 
57
55
  ## Style Conventions
58
56
 
57
+ - Some styles live in a global folder, but for the most part our components are styled with isolated SCSS files located alongside React component TS files.
58
+
59
+ - We are currently in the process of migrating components to a second-generation styling convention which relies on CSS variables for design tokens and generally removes `@apply` Tailwind statements.
60
+
61
+ - Bloom design tokens include colors, typography settings, sizes, borders, and so forth. They're located in the `src/global/tokens` folder.
62
+
63
+ - More information on this process can be found in [Styling2ndGen.md](https://github.com/bloom-housing/bloom/blob/dev/docs/Styling2ndGen.md).
64
+
59
65
  ### Naming Conventions
60
66
 
61
67
  - Our recommendation for class naming methodology is a modified version of BEM. It still uses blocks, sections within blocks and modifiers, but with a subclass syntax for modifiers.
package/index.ts CHANGED
@@ -98,6 +98,7 @@ export * from "./src/overlays/Drawer"
98
98
  export * from "./src/overlays/LoadingOverlay"
99
99
 
100
100
  /* Page Components */
101
+ export * from "./src/page_components/ApplicationTimeline"
101
102
  export * from "./src/page_components/listing/AdditionalFees"
102
103
  export * from "./src/page_components/listing/ContentAccordion"
103
104
  export * from "./src/page_components/listing/ListingCard"
@@ -119,6 +120,7 @@ export * from "./src/page_components/listing/listing_sidebar/WhatToExpect"
119
120
  export * from "./src/page_components/listing/listing_sidebar/events/DownloadLotteryResults"
120
121
  export * from "./src/page_components/listing/listing_sidebar/events/EventSection"
121
122
  export * from "./src/page_components/sign-in/FormTerms"
123
+ export * from "./src/page_components/sign-in/ResendConfirmationModal"
122
124
  export * from "./src/page_components/sign-in/FormSignIn"
123
125
  export * from "./src/page_components/sign-in/FormSignInMFAType"
124
126
  export * from "./src/page_components/sign-in/FormSignInMFACode"
@@ -143,6 +145,7 @@ export * from "./src/tables/StandardTable"
143
145
  export * from "./src/tables/GroupedTable"
144
146
  export * from "./src/tables/MinimalTable"
145
147
  export * from "./src/tables/StackedTable"
148
+ export * from "./src/tables/CategoryTable"
146
149
 
147
150
  /* Text */
148
151
  export * from "./src/text/Description"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bloom-housing/ui-components",
3
- "version": "4.2.2-alpha.2",
3
+ "version": "4.2.2-alpha.22",
4
4
  "author": "Sean Albert <sean.albert@exygy.com>",
5
5
  "description": "Shared user interface components for Bloom affordable housing system",
6
6
  "homepage": "https://github.com/bloom-housing/bloom/tree/master/shared/ui-components",
@@ -24,6 +24,7 @@
24
24
  "@babel/preset-env": "^7.15.4",
25
25
  "@emotion/core": "^10.0.35",
26
26
  "@emotion/styled": "^10.0.27",
27
+ "@geometricpanda/storybook-addon-badges": "^0.2.1",
27
28
  "@storybook/addon-a11y": "^6.3.8",
28
29
  "@storybook/addon-actions": "^6.3.8",
29
30
  "@storybook/addon-docs": "^6.3.8",
@@ -69,11 +70,12 @@
69
70
  "webpack": "^4.44.2"
70
71
  },
71
72
  "dependencies": {
72
- "@bloom-housing/backend-core": "^4.2.2-alpha.1",
73
+ "@bloom-housing/backend-core": "^4.2.2-alpha.7",
73
74
  "@mapbox/mapbox-sdk": "^0.13.0",
74
75
  "@types/body-scroll-lock": "^2.6.1",
75
76
  "@types/jwt-decode": "^2.2.1",
76
77
  "@types/markdown-to-jsx": "^6.11.2",
78
+ "@types/mdx": "^2.0.1",
77
79
  "@types/node": "^12.12.67",
78
80
  "@types/node-polyglot": "^2.4.1",
79
81
  "@types/react-beautiful-dnd": "^13.1.1",
@@ -100,5 +102,5 @@
100
102
  "tailwindcss": "2.2.10",
101
103
  "typesafe-actions": "^5.1.0"
102
104
  },
103
- "gitHead": "6a1daa540cc0bd206fc89d9444b187502c80e712"
105
+ "gitHead": "d1e92b646c2942546756f80fecbb624a3e74b1b0"
104
106
  }
@@ -0,0 +1,76 @@
1
+ import { Canvas, Story, Source, ArgsTable } from "@storybook/addon-docs"
2
+ import { Swatch } from "../prototypes/Swatch"
3
+ import { Button } from "./Button"
4
+
5
+ # Button
6
+
7
+ The button component offers flexible usage with a variety of different appearance options. Size, color, and shape can be controlled via standardized props.
8
+
9
+ <Canvas>
10
+ <Button>This is a Button</Button>
11
+ </Canvas>
12
+
13
+ ## Variants
14
+
15
+ There are several props which accept enums to adjust style type, border, and size. For example, to choose the "primary" style and a "small" size, you would pass the `AppearanceStyleType.primary` enum to `styleType` prop and `AppearanceSizeType.small` enum to `size` prop.
16
+
17
+ <Canvas>
18
+ <Story id="actions-button--small-and-primary" />
19
+ </Canvas>
20
+
21
+ Other variants include appearances which aren't button-like such as `unstyled` and `inline`.
22
+
23
+ ## Component Properties
24
+
25
+ <ArgsTable of={Button} />
26
+
27
+ ## Theming Variables
28
+
29
+ You can apply CSS variables to the `.button` selector to customize the appearance of the component.
30
+
31
+ ### Color Variables
32
+
33
+ | Name | Color | Description |
34
+ | --------------------------------------------- | ------------------------------------------------ | ------------------------------------ |
35
+ | `--primary-appearance-background-color` | <Swatch colorVar="--bloom-color-primary" /> | Primary background color |
36
+ | `--primary-appearance-border-color` | <Swatch colorVar="--bloom-color-primary" /> | Primary border color |
37
+ | `--primary-appearance-label-color` | <Swatch colorVar="--bloom-color-white" /> | Primary label color |
38
+ | `--primary-appearance-hover-background-color` | <Swatch colorVar="--bloom-color-primary-dark" /> | Hover state primary background color |
39
+ | `--primary-appearance-hover-border-color` | <Swatch colorVar="--bloom-color-primary-dark" /> | Hover state primary border color |
40
+ | `--primary-appearance-hover-label-color` | <Swatch colorVar="--bloom-color-white" /> | Hover state primary label color |
41
+ | `--success-appearance-background-color` | <Swatch colorVar="--bloom-color-success" /> | Success background color |
42
+ | `--success-appearance-border-color` | <Swatch colorVar="--bloom-color-success" /> | Success border color |
43
+ | `--success-appearance-label-color` | <Swatch colorVar="--bloom-color-white" /> | Success label color |
44
+ | `--success-appearance-hover-background-color` | <Swatch colorVar="--bloom-color-success-dark" /> | Hover state success background color |
45
+ | `--success-appearance-hover-border-color` | <Swatch colorVar="--bloom-color-success" /> | Hover state success border color |
46
+ | `--success-appearance-hover-label-color` | <Swatch colorVar="--bloom-color-white" /> | Hover state success label color |
47
+ | `--alert-appearance-background-color` | <Swatch colorVar="--bloom-color-alert" /> | Alert background color |
48
+ | `--alert-appearance-border-color` | <Swatch colorVar="--bloom-color-alert" /> | Alert border color |
49
+ | `--alert-appearance-label-color` | <Swatch colorVar="--bloom-color-white" /> | Alert label color |
50
+ | `--alert-appearance-hover-background-color` | <Swatch colorVar="--bloom-color-alert-dark" /> | Hover state alert background color |
51
+ | `--alert-appearance-hover-border-color` | <Swatch colorVar="--bloom-color-alert" /> | Hover state alert border color |
52
+ | `--alert-appearance-hover-label-color` | <Swatch colorVar="--bloom-color-white" /> | Hover state alert label color |
53
+ | `--warn-appearance-background-color` | <Swatch colorVar="--bloom-color-warn" /> | Warning background color |
54
+ | `--warn-appearance-border-color` | <Swatch colorVar="--bloom-color-warn" /> | Warning border color |
55
+ | `--warn-appearance-label-color` | <Swatch colorVar="--bloom-color-white" /> | Warning label color |
56
+ | `--warn-appearance-hover-background-color` | <Swatch colorVar="--bloom-color-warn-dark" /> | Hover state warning background color |
57
+ | `--warn-appearance-hover-border-color` | <Swatch colorVar="--bloom-color-warn" /> | Hover state warning border color |
58
+ | `--warn-appearance-hover-label-color` | <Swatch colorVar="--bloom-color-white" /> | Hover state warning label color |
59
+
60
+ ### Typographic & Spacing Variables
61
+
62
+ | Name | Type | Description | Default |
63
+ | ------------------------ | ----------- | --------------------------------------------------- | --------------------------------------------------- |
64
+ | `--label-font` | Font | Font family of the button label | `--bloom-font-alt-sans` |
65
+ | `--label-transform` | Case | Text case of the button label | `uppercase` |
66
+ | `--label-letter-spacing` | Size | The average gap between letters of the button label | `--bloom-letter-spacing-widest` |
67
+ | `--label-weight` | Font Weight | Typographic weight of the button label | `bold` |
68
+ | `--normal-rounded` | Size | Border radius of a normal-size button | `--bloom-rounded` |
69
+ | `--normal-padding` | Size | Padding of the normal-size button interior | `--bloom-s4` (top/bottom) `--bloom-s6` (left/right) |
70
+ | `--normal-font-size` | Size | Font size of the normal-size button | `--bloom-font-size-sm` |
71
+ | `--small-rounded` | Size | Border radius of a small-size button | `--bloom-rounded` |
72
+ | `--small-padding` | Size | Padding of the small-size button interior | `--bloom-s3` (top/bottom) `--bloom-s6` (left/right) |
73
+ | `--small-font-size` | Size | Font size of the small-size button | `--bloom-font-size-xs` |
74
+ | `--big-rounded` | Size | Border radius of a large-size button | `--bloom-rounded` |
75
+ | `--big-padding` | Size | Padding of the large-size button interior | `--bloom-s6` |
76
+ | `--big-font-size` | Size | Font size of the large-size button | `--bloom-font-size-sm` |
@@ -1,59 +1,58 @@
1
1
  @import "../global/mixins.scss";
2
2
 
3
3
  .button {
4
- @apply relative;
5
- @apply rounded;
6
- @apply px-6;
7
- @apply py-4;
8
- @apply text-lg;
9
- @apply text-center;
10
- @apply uppercase;
11
- @apply font-alt-sans;
12
- @apply inline-block;
13
- @apply tracking-widest;
14
- @apply text-sm;
15
- @apply font-bold;
16
- @apply leading-snug;
4
+ position: relative;
5
+ border-radius: var(--normal-rounded, var(--bloom-rounded));
6
+ padding: var(--normal-padding, var(--bloom-s4) var(--bloom-s6));
7
+ text-align: center;
8
+ text-transform: var(--label-transform, uppercase);
9
+ font-family: var(--label-font, var(--bloom-font-alt-sans));
10
+ display: inline-block;
11
+ letter-spacing: var(--label-letter-spacing, var(--bloom-letter-spacing-widest));
12
+ font-size: var(--normal-font-size, var(--bloom-font-size-sm));
13
+ font-weight: var(--label-weight, bold);
14
+ line-height: var(--bloom-line-height-snug);
17
15
 
18
16
  &:focus {
19
17
  outline: none;
20
- box-shadow: 0 0 0 2px #fff, 0 0 3px 4px $tailwind-accent-cool;
18
+ box-shadow: 0 0 0 2px #fff, 0 0 3px 4px var(--bloom-color-accent-cool);
21
19
  }
22
20
 
23
21
  &:hover {
24
- @apply border-primary-dark;
22
+ border-color: var(--bloom-color-primary-dark);
25
23
  }
26
24
 
27
25
  &:disabled {
28
26
  pointer-events: none;
29
- @apply bg-white;
30
- @apply border-gray-450;
31
- @apply text-gray-450;
27
+ background-color: var(--bloom-color-white);
28
+ border-color: var(--bloom-color-gray-450);
29
+ color: var(--bloom-color-gray-450);
32
30
  }
33
31
 
34
32
  &.is-secondary {
35
- @apply border-gray-700;
36
- @apply text-gray-700;
33
+ border-color: var(--bloom-color-gray-700);
34
+ color: var(--bloom-color-gray-700);
37
35
 
38
36
  &:hover {
39
- @apply bg-gray-700;
40
- @apply text-white;
37
+ background-color: var(--bloom-color-gray-700);
38
+ color: var(--bloom-color-white);
41
39
  }
42
40
  }
43
41
 
44
42
  &.is-small {
45
- @apply text-xs;
46
- @apply px-6;
47
- @apply py-3;
43
+ border-radius: var(--small-rounded, var(--bloom-rounded));
44
+ padding: var(--small-padding, var(--bloom-s3) var(--bloom-s6));
45
+ font-size: var(--small-font-size, var(--bloom-font-size-xs));
48
46
  }
49
47
 
50
48
  &.is-big {
51
- @apply px-6;
52
- @apply py-6;
49
+ border-radius: var(--big-rounded, var(--bloom-rounded));
50
+ padding: var(--big-padding, var(--bloom-s6));
51
+ font-size: var(--big-font-size, var(--bloom-font-size-sm));
53
52
  }
54
53
 
55
54
  &.is-normal-case {
56
- @apply normal-case;
55
+ text-transform: none;
57
56
  }
58
57
 
59
58
  &.is-unstyled {
@@ -62,74 +61,72 @@
62
61
 
63
62
  &.is-unstyled,
64
63
  &.is-inline {
65
- @apply normal-case;
66
- @apply border-0;
67
- @apply p-0;
68
- @apply font-sans;
69
- @apply tracking-normal;
70
- @apply font-normal;
71
- @apply underline;
72
- @apply m-4;
73
- @apply text-tiny;
64
+ text-transform: none;
65
+ border: none;
66
+ padding: 0;
67
+ font-family: var(--bloom-font-sans);
68
+ letter-spacing: normal;
69
+ font-weight: 400;
70
+ text-decoration: underline;
71
+ margin: var(--bloom-s4);
72
+ font-size: var(--bloom-font-size-tiny);
74
73
 
75
74
  &:hover {
76
- @apply text-primary;
75
+ color: var(--bloom-color-primary);
77
76
  background: transparent;
78
77
  }
79
78
  }
80
79
 
81
80
  &.is-inline {
82
- @apply text-primary;
83
- @apply font-semibold;
84
- @apply text-tiny;
85
- @apply m-0;
86
- @apply no-underline;
81
+ color: var(--bloom-color-primary);
82
+ font-weight: 600;
83
+ font-size: var(--bloom-font-size-tiny);
84
+ margin: 0;
85
+ text-decoration: none;
87
86
 
88
87
  &.has-icon-left {
89
88
  .button__icon {
90
- @apply mr-1;
89
+ margin-right: var(--bloom-s1);
91
90
  }
92
91
  }
93
92
  &.has-icon-right {
94
93
  .button__icon {
95
- @apply ml-1;
94
+ margin-left: var(--bloom-s1);
96
95
  }
97
96
  }
98
97
  }
99
98
 
100
99
  &.has-icon-left {
101
100
  .button__icon {
102
- @apply mr-3;
101
+ margin-right: var(--bloom-s3);
103
102
  }
104
103
  }
105
104
  &.has-icon-right {
106
105
  .button__icon {
107
- @apply ml-3;
106
+ margin-left: var(--bloom-s3);
108
107
  }
109
108
  }
110
109
 
111
110
  &.is-text-caps {
112
- @apply text-primary-dark;
113
- @apply normal-case;
114
- @apply border-0;
115
- @apply p-0;
116
- @apply font-sans;
117
- @apply tracking-normal;
118
- @apply font-normal;
119
- @apply underline;
120
- @apply m-4;
121
- @apply uppercase;
122
- @apply text-tiny;
123
- @apply block;
111
+ color: var(--bloom-color-primary-dark);
112
+ border: none;
113
+ padding: 0;
114
+ font-family: var(--bloom-font-sans);
115
+ letter-spacing: normal;
116
+ text-decoration: underline;
117
+ margin: var(--bloom-s4);
118
+ text-transform: uppercase;
119
+ font-size: var(--bloom-font-size-tiny);
120
+ display: block;
124
121
 
125
122
  &:hover {
126
- @apply text-primary-dark;
123
+ color: var(--bloom-color-primary-dark);
127
124
  background: transparent;
128
125
  }
129
126
  }
130
127
 
131
128
  &.is-fullwidth {
132
- @apply w-full;
129
+ width: 100%;
133
130
  }
134
131
 
135
132
  &.is-loading {
@@ -98,6 +98,7 @@ export const IdleTimeout: FunctionComponent<IdleTimeoutProps> = ({
98
98
  ariaDescription={promptText}
99
99
  actions={modalActions}
100
100
  hideCloseIcon
101
+ role="alertdialog"
101
102
  >
102
103
  {promptText}
103
104
  </Modal>
@@ -1,5 +1,6 @@
1
- import React from "react"
1
+ import React, { useContext } from "react"
2
2
  import "./DashBlocks.scss"
3
+ import { NavigationContext } from "../config/NavigationContext"
3
4
 
4
5
  interface DashBlockProps {
5
6
  href?: string
@@ -10,6 +11,7 @@ interface DashBlockProps {
10
11
  dataTestId?: string
11
12
  }
12
13
  const DashBlock = (props: DashBlockProps) => {
14
+ const { LinkComponent } = useContext(NavigationContext)
13
15
  const { href, title, subtitle, icon, children } = props
14
16
  let content, wrapper
15
17
  if (children) {
@@ -24,9 +26,9 @@ const DashBlock = (props: DashBlockProps) => {
24
26
  )
25
27
  if (href) {
26
28
  wrapper = (
27
- <a href={href} className="dash-item">
29
+ <LinkComponent href={href} className="dash-item">
28
30
  {header}
29
- </a>
31
+ </LinkComponent>
30
32
  )
31
33
  } else {
32
34
  wrapper = (
@@ -1,5 +1,6 @@
1
1
  .dash-blocks {
2
2
  @apply w-full;
3
+ @apply mb-8;
3
4
 
4
5
  @screen md {
5
6
  @apply flex;
@@ -8,6 +9,7 @@
8
9
  }
9
10
 
10
11
  .dash-block {
12
+ align-self: stretch;
11
13
  @screen md {
12
14
  @apply px-2;
13
15
  flex: 50%;
@@ -24,13 +26,14 @@
24
26
  @apply bg-white;
25
27
  @apply p-4;
26
28
  @apply pt-8;
29
+ @apply pb-8;
27
30
  @apply text-tiny;
28
31
 
29
32
  @screen md {
30
33
  @apply rounded-lg;
31
34
  @apply border;
32
35
  @apply p-8;
33
- @apply mb-8;
36
+ @apply h-full;
34
37
  }
35
38
 
36
39
  p {