@madie/madie-design-system 1.0.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.
Files changed (316) hide show
  1. package/.babelrc +10 -0
  2. package/.editorconfig +22 -0
  3. package/.eslintignore +5 -0
  4. package/.eslintrc.js +31 -0
  5. package/.storybook/.babelrc +4 -0
  6. package/.storybook/main.js +89 -0
  7. package/.storybook/preview-head.html +9 -0
  8. package/.storybook/preview.js +5 -0
  9. package/README.md +5 -0
  10. package/components/Accordion/Accordion.stories.js +20 -0
  11. package/components/Accordion/index.jsx +93 -0
  12. package/components/Alert/Alert.stories.js +61 -0
  13. package/components/Alert/index.js +46 -0
  14. package/components/Breadcrumb/Breadcrumb.md +28 -0
  15. package/components/Breadcrumb/Breadcrumb.stories.js +76 -0
  16. package/components/Breadcrumb/index.js +83 -0
  17. package/components/Button/Button.stories.js +121 -0
  18. package/components/Button/index.js +90 -0
  19. package/components/CalloutBox/CalloutBox.stories.js +94 -0
  20. package/components/CalloutBox/index.js +109 -0
  21. package/components/Card/Card.stories.js +163 -0
  22. package/components/Card/index.js +137 -0
  23. package/components/Dropdown/Dropdown.stories.js +94 -0
  24. package/components/Dropdown/index.js +85 -0
  25. package/components/Error/Collapsible.jsx +88 -0
  26. package/components/Error/ErrorUI.jsx +31 -0
  27. package/components/Error/error.js +26 -0
  28. package/components/FlashNotification/FlashNotificationUI.jsx +91 -0
  29. package/components/FlashNotification/index.js +30 -0
  30. package/components/Footer/Footer.stories.js +20 -0
  31. package/components/Footer/FooterUI.jsx +269 -0
  32. package/components/Footer/LegacyFooterUI.jsx +194 -0
  33. package/components/Footer/SocialLinks.jsx +60 -0
  34. package/components/Footer/Subscribe.jsx +34 -0
  35. package/components/Footer/footer.js +30 -0
  36. package/components/Header/Header.md +111 -0
  37. package/components/Header/Header.stories.js +32 -0
  38. package/components/Header/HeaderAccountMenu.jsx +169 -0
  39. package/components/Header/HeaderCancel.jsx +16 -0
  40. package/components/Header/HeaderContainer.jsx +63 -0
  41. package/components/Header/HeaderLogo.jsx +42 -0
  42. package/components/Header/HeaderMenuButton.js +50 -0
  43. package/components/Header/HeaderMenuItem.jsx +232 -0
  44. package/components/Header/HeaderMenuLink.js +50 -0
  45. package/components/Header/HeaderMenuSignOutButton.js +62 -0
  46. package/components/Header/HeaderMobileButton.js +37 -0
  47. package/components/Header/HeaderUI.jsx +167 -0
  48. package/components/Header/HelpIcon.jsx +32 -0
  49. package/components/Header/ImpersonatorBanner.jsx +57 -0
  50. package/components/Header/NavigationButtonIcon.jsx +27 -0
  51. package/components/Header/default-content.json +280 -0
  52. package/components/Header/header.js +40 -0
  53. package/components/Header/hooks.js +52 -0
  54. package/components/Header/utag-helpers.js +9 -0
  55. package/components/Infotip/Infotip.jsx +75 -0
  56. package/components/Infotip/Infotip.stories.js +50 -0
  57. package/components/Infotip/InfotipIcon.jsx +41 -0
  58. package/components/Infotip/index.js +3 -0
  59. package/components/Link/Link.stories.js +81 -0
  60. package/components/Link/index.js +61 -0
  61. package/components/Modal/LegacyModal.jsx +72 -0
  62. package/components/Modal/Modal.jsx +140 -0
  63. package/components/Modal/Modal.stories.js +159 -0
  64. package/components/Modal/index.jsx +22 -0
  65. package/components/NotificationBanner/NotificationBanner.stories.js +23 -0
  66. package/components/NotificationBanner/index.js +265 -0
  67. package/components/SanitizedContent/index.jsx +200 -0
  68. package/components/Search/Search.stories.js +21 -0
  69. package/components/Search/index.js +85 -0
  70. package/components/SessionDialog/sessionDialog.js +26 -0
  71. package/components/SessionDialogUI.jsx +261 -0
  72. package/components/SideNav/AnimationGroup/AnimationGroup.jsx +27 -0
  73. package/components/SideNav/Chart/ScoreChart.jsx +268 -0
  74. package/components/SideNav/Chart/__tests__/ScoreChart.test.js +22 -0
  75. package/components/SideNav/Chart/__tests__/__snapshots__/ScoreChart.test.js.snap +173 -0
  76. package/components/SideNav/Chart/index.js +3 -0
  77. package/components/SideNav/Content/LevelOneContent.jsx +208 -0
  78. package/components/SideNav/Content/LevelTwoContent.jsx +216 -0
  79. package/components/SideNav/Content/index.js +4 -0
  80. package/components/SideNav/Details/IndividualDetails.jsx +18 -0
  81. package/components/SideNav/Details/PracticeDetails.jsx +45 -0
  82. package/components/SideNav/Details/index.js +4 -0
  83. package/components/SideNav/Links/CmsSwitchLink.jsx +41 -0
  84. package/components/SideNav/Links/NavItemInline.jsx +54 -0
  85. package/components/SideNav/Links/NavLinkContainer.jsx +38 -0
  86. package/components/SideNav/Links/NavLinkDrawer.jsx +249 -0
  87. package/components/SideNav/Links/NavLinkInline.jsx +107 -0
  88. package/components/SideNav/Links/NavLinkToggle.jsx +34 -0
  89. package/components/SideNav/Links/index.js +13 -0
  90. package/components/SideNav/SideNav.md +50 -0
  91. package/components/SideNav/SideNav.stories.js +379 -0
  92. package/components/SideNav/UI/SideNavUI.jsx +333 -0
  93. package/components/SideNav/UI/default-content.json +99 -0
  94. package/components/SideNav/UI/index.js +3 -0
  95. package/components/SideNav/helpers.js +49 -0
  96. package/components/SideNav/index.js +53 -0
  97. package/components/Spinner/index.js +9 -0
  98. package/components/Tabs/Tab.js +26 -0
  99. package/components/Tabs/TabPanel.js +34 -0
  100. package/components/Tabs/Tabs.stories.js +120 -0
  101. package/components/Tabs/index.js +95 -0
  102. package/components/TextInput/TextInput.stories.js +118 -0
  103. package/components/TextInput/index.js +137 -0
  104. package/components/Tooltip/Tooltip.jsx +88 -0
  105. package/components/Tooltip/Tooltip.stories.js +80 -0
  106. package/components/Tooltip/index.js +3 -0
  107. package/components/Tooltip/position.js +68 -0
  108. package/components/UnwrappedSpinner/index.js +8 -0
  109. package/components/hooks/useGetConfig.js +74 -0
  110. package/components/index.js +126 -0
  111. package/dist/browser.js +3 -0
  112. package/dist/browser.js.LICENSE.txt +54 -0
  113. package/dist/browser.js.map +1 -0
  114. package/dist/index.js +3 -0
  115. package/dist/index.js.LICENSE.txt +54 -0
  116. package/dist/index.js.map +1 -0
  117. package/dist/react/index.js +3 -0
  118. package/dist/react/index.js.LICENSE.txt +71 -0
  119. package/dist/react/index.js.map +1 -0
  120. package/fonts/FontAwesome.otf +0 -0
  121. package/fonts/OFL.txt +92 -0
  122. package/fonts/Rubik-Black.ttf +0 -0
  123. package/fonts/Rubik-BlackItalic.ttf +0 -0
  124. package/fonts/Rubik-Bold.ttf +0 -0
  125. package/fonts/Rubik-BoldItalic.ttf +0 -0
  126. package/fonts/Rubik-Italic.ttf +0 -0
  127. package/fonts/Rubik-Light.ttf +0 -0
  128. package/fonts/Rubik-LightItalic.ttf +0 -0
  129. package/fonts/Rubik-Medium.ttf +0 -0
  130. package/fonts/Rubik-MediumItalic.ttf +0 -0
  131. package/fonts/Rubik-Regular.ttf +0 -0
  132. package/fonts/fontawesome-webfont.eot +0 -0
  133. package/fonts/fontawesome-webfont.svg +2671 -0
  134. package/fonts/fontawesome-webfont.ttf +0 -0
  135. package/fonts/fontawesome-webfont.woff +0 -0
  136. package/fonts/fontawesome-webfont.woff2 +0 -0
  137. package/images/favicon/android-chrome-192x192.png +0 -0
  138. package/images/favicon/android-chrome-256x256.png +0 -0
  139. package/images/favicon/apple-touch-icon.png +0 -0
  140. package/images/favicon/browserconfig.xml +9 -0
  141. package/images/favicon/favicon-16x16.png +0 -0
  142. package/images/favicon/favicon-32x32.png +0 -0
  143. package/images/favicon/favicon.ico +0 -0
  144. package/images/favicon/manifest.json +18 -0
  145. package/images/favicon/mstile-150x150.png +0 -0
  146. package/images/favicon/safari-pinned-tab.svg +32 -0
  147. package/images/hhs-logo-black.svg +10 -0
  148. package/images/hhs-logo-white.svg +10 -0
  149. package/images/icons/close-x.svg +6 -0
  150. package/images/icons/help-headset.svg +21 -0
  151. package/images/icons/svg/arrow-down.svg +1 -0
  152. package/images/icons/svg/arrow-download.svg +1 -0
  153. package/images/icons/svg/arrow-right.svg +1 -0
  154. package/images/icons/svg/calendar.svg +1 -0
  155. package/images/icons/svg/close.svg +1 -0
  156. package/images/icons/svg/download.svg +1 -0
  157. package/images/icons/svg/external.svg +1 -0
  158. package/images/icons/svg/file-upload.svg +1 -0
  159. package/images/icons/svg/print.svg +1 -0
  160. package/images/icons/svg/search.svg +7 -0
  161. package/images/icons/svg/tooltip-question.svg +6 -0
  162. package/images/icons/svg/trash.svg +1 -0
  163. package/images/icons/svg/upload.svg +1 -0
  164. package/images/qpp_logo_reversed.png +0 -0
  165. package/images/qpp_logo_rgb_color.png +0 -0
  166. package/index.js +31 -0
  167. package/jest/mediaFileTransformer.js +9 -0
  168. package/jest.config.js +188 -0
  169. package/lib/Chevron.jsx +32 -0
  170. package/lib/SvgComponents.jsx +539 -0
  171. package/lib/svg-definitions.svg +125 -0
  172. package/package.json +125 -0
  173. package/session/index.js +5 -0
  174. package/session/logout.js +65 -0
  175. package/session/refresh.js +49 -0
  176. package/session/ttl.js +37 -0
  177. package/styles/_global.scss +106 -0
  178. package/styles/_main.scss +15 -0
  179. package/styles/_paths.scss +1 -0
  180. package/styles/_qpp-style.scss +31 -0
  181. package/styles/components/_accordion.scss +289 -0
  182. package/styles/components/_alerts.scss +54 -0
  183. package/styles/components/_autocomplete.scss +47 -0
  184. package/styles/components/_breadcrumbs.scss +64 -0
  185. package/styles/components/_buttons.scss +580 -0
  186. package/styles/components/_error-page.scss +56 -0
  187. package/styles/components/_flash-notification.scss +98 -0
  188. package/styles/components/_fonts.scss +42 -0
  189. package/styles/components/_forms.scss +277 -0
  190. package/styles/components/_grid.scss +37 -0
  191. package/styles/components/_info-modal.scss +139 -0
  192. package/styles/components/_links.scss +12 -0
  193. package/styles/components/_modals.scss +18 -0
  194. package/styles/components/_notification-banner.scss +165 -0
  195. package/styles/components/_panels.scss +61 -0
  196. package/styles/components/_pie-chart.scss +13 -0
  197. package/styles/components/_score-chart.scss +164 -0
  198. package/styles/components/_spinner.scss +7 -0
  199. package/styles/components/_tables.scss +111 -0
  200. package/styles/components/_tabs.scss +69 -0
  201. package/styles/components/_text.scss +150 -0
  202. package/styles/components/_toggles.scss +3 -0
  203. package/styles/components/_tooltip.scss +23 -0
  204. package/styles/components/_variables.scss +157 -0
  205. package/styles/components/_wells.scss +92 -0
  206. package/styles/qppds/README.md +0 -0
  207. package/styles/qppds/base/_backgrounds.scss +7 -0
  208. package/styles/qppds/base/_fonts.scss +26 -0
  209. package/styles/qppds/base/_icon.scss +23 -0
  210. package/styles/qppds/base/_layout.scss +5 -0
  211. package/styles/qppds/base/_typography.scss +85 -0
  212. package/styles/qppds/base/index.scss +8 -0
  213. package/styles/qppds/components/_alert.scss +95 -0
  214. package/styles/qppds/components/_breadcrumbs.scss +70 -0
  215. package/styles/qppds/components/_button.scss +292 -0
  216. package/styles/qppds/components/_card.scss +175 -0
  217. package/styles/qppds/components/_dropdown.scss +55 -0
  218. package/styles/qppds/components/_footer.scss +597 -0
  219. package/styles/qppds/components/_header.scss +892 -0
  220. package/styles/qppds/components/_link.scss +52 -0
  221. package/styles/qppds/components/_modal.scss +118 -0
  222. package/styles/qppds/components/_page-header.scss +67 -0
  223. package/styles/qppds/components/_pagination.scss +227 -0
  224. package/styles/qppds/components/_search.scss +112 -0
  225. package/styles/qppds/components/_sidebar.scss +9 -0
  226. package/styles/qppds/components/_table.scss +139 -0
  227. package/styles/qppds/components/_tabs.scss +197 -0
  228. package/styles/qppds/components/_text-input.scss +60 -0
  229. package/styles/qppds/components/index.scss +16 -0
  230. package/styles/qppds/components/sidebar/_animations.scss +38 -0
  231. package/styles/qppds/components/sidebar/_cms.scss +61 -0
  232. package/styles/qppds/components/sidebar/_details.scss +58 -0
  233. package/styles/qppds/components/sidebar/_links.scss +444 -0
  234. package/styles/qppds/components/sidebar/_sidebar-animation.scss +125 -0
  235. package/styles/qppds/components/sidebar/_sidebar-tooltip.scss +33 -0
  236. package/styles/qppds/components/sidebar/_sidebar.scss +146 -0
  237. package/styles/qppds/components/sidebar/project-specific/_wi.scss +42 -0
  238. package/styles/qppds/index.scss +4 -0
  239. package/styles/qppds/settings/_functions.scss +4 -0
  240. package/styles/qppds/settings/_index.scss +3 -0
  241. package/styles/qppds/settings/mixins/_borders.scss +6 -0
  242. package/styles/qppds/settings/mixins/_focus.scss +28 -0
  243. package/styles/qppds/settings/mixins/_icons.scss +33 -0
  244. package/styles/qppds/settings/mixins/_index.scss +8 -0
  245. package/styles/qppds/settings/mixins/_layout.scss +74 -0
  246. package/styles/qppds/settings/mixins/_lists.scss +12 -0
  247. package/styles/qppds/settings/mixins/_table.scss +91 -0
  248. package/styles/qppds/settings/mixins/_type.scss +65 -0
  249. package/styles/qppds/settings/mixins/_visually-hidden.scss +30 -0
  250. package/styles/qppds/settings/variables/_color.scss +86 -0
  251. package/styles/qppds/settings/variables/_index.scss +3 -0
  252. package/styles/qppds/settings/variables/_layout.scss +67 -0
  253. package/styles/qppds/settings/variables/_type.scss +132 -0
  254. package/styles/qppds/utilities/_background-color.scss +134 -0
  255. package/styles/qppds/utilities/_color.scss +32 -0
  256. package/styles/qppds/utilities/_display-visibility.scss +83 -0
  257. package/styles/qppds/utilities/_flexbox.scss +240 -0
  258. package/styles/qppds/utilities/_font-family.scss +9 -0
  259. package/styles/qppds/utilities/_font-size.scss +8 -0
  260. package/styles/qppds/utilities/_font-weight.scss +8 -0
  261. package/styles/qppds/utilities/_height.scss +38 -0
  262. package/styles/qppds/utilities/_margin.scss +136 -0
  263. package/styles/qppds/utilities/_padding.scss +76 -0
  264. package/styles/qppds/utilities/_position.scss +24 -0
  265. package/styles/qppds/utilities/_text-align.scss +40 -0
  266. package/styles/qppds/utilities/_text-transform.scss +7 -0
  267. package/styles/qppds/utilities/_truncate.scss +8 -0
  268. package/styles/qppds/utilities/_width.scss +79 -0
  269. package/styles/qppds/utilities/index.scss +15 -0
  270. package/styles/qppds.scss +2 -0
  271. package/styles/third-party/_legacy-bootstrap.scss +19 -0
  272. package/styles/third-party/legacy-bootstrap/_buttons.scss +126 -0
  273. package/styles/third-party/legacy-bootstrap/_dropdowns.scss +211 -0
  274. package/styles/third-party/legacy-bootstrap/_forms.scss +510 -0
  275. package/styles/third-party/legacy-bootstrap/_grid.scss +73 -0
  276. package/styles/third-party/legacy-bootstrap/_mixins.scss +27 -0
  277. package/styles/third-party/legacy-bootstrap/_navbar.scss +644 -0
  278. package/styles/third-party/legacy-bootstrap/_navs.scss +193 -0
  279. package/styles/third-party/legacy-bootstrap/_normalize.scss +385 -0
  280. package/styles/third-party/legacy-bootstrap/_scaffolding.scss +116 -0
  281. package/styles/third-party/legacy-bootstrap/_variables.scss +858 -0
  282. package/styles/third-party/legacy-bootstrap/mixins/_buttons.scss +70 -0
  283. package/styles/third-party/legacy-bootstrap/mixins/_clearfix.scss +22 -0
  284. package/styles/third-party/legacy-bootstrap/mixins/_forms.scss +108 -0
  285. package/styles/third-party/legacy-bootstrap/mixins/_grid-framework.scss +86 -0
  286. package/styles/third-party/legacy-bootstrap/mixins/_grid.scss +112 -0
  287. package/styles/third-party/legacy-bootstrap/mixins/_labels.scss +12 -0
  288. package/styles/third-party/legacy-bootstrap/mixins/_nav-divider.scss +10 -0
  289. package/styles/third-party/legacy-bootstrap/mixins/_nav-vertical-align.scss +9 -0
  290. package/styles/third-party/legacy-bootstrap/mixins/_opacity.scss +7 -0
  291. package/styles/third-party/legacy-bootstrap/mixins/_panels.scss +30 -0
  292. package/styles/third-party/legacy-bootstrap/mixins/_reset-filter.scss +7 -0
  293. package/styles/third-party/legacy-bootstrap/mixins/_reset-text.scss +18 -0
  294. package/styles/third-party/legacy-bootstrap/mixins/_resize.scss +6 -0
  295. package/styles/third-party/legacy-bootstrap/mixins/_responsive-visibility.scss +25 -0
  296. package/styles/third-party/legacy-bootstrap/mixins/_size.scss +10 -0
  297. package/styles/third-party/legacy-bootstrap/mixins/_tab-focus.scss +9 -0
  298. package/styles/third-party/legacy-bootstrap/mixins/_table-row.scss +28 -0
  299. package/styles/third-party/legacy-bootstrap/mixins/_text-emphasis.scss +12 -0
  300. package/styles/third-party/legacy-bootstrap/mixins/_text-overflow.scss +8 -0
  301. package/styles/third-party/legacy-bootstrap/mixins/_vendor-prefixes.scss +182 -0
  302. package/styles/utility/_mixins.scss +46 -0
  303. package/styles/utility/_utilities.scss +73 -0
  304. package/test/components/Accordion.test.js +12 -0
  305. package/test/components/ErrorUI.test.js +33 -0
  306. package/test/components/FooterUI.test.js +90 -0
  307. package/test/components/HeaderUI.test.js +45 -0
  308. package/test/components/Infotip.test.js +73 -0
  309. package/test/components/SessionDialogUI.test.js +339 -0
  310. package/test/components/SideNavUI.test.js +23 -0
  311. package/test/components/Tooltip.test.js +147 -0
  312. package/test/index.test.js +8 -0
  313. package/test/session/session.test.js +221 -0
  314. package/test-setup.js +9 -0
  315. package/webpack.config.js +147 -0
  316. package/webpack.config.react.js +86 -0
@@ -0,0 +1,280 @@
1
+ [
2
+ {
3
+ "name": "About",
4
+ "subtitle": "The Quality Payment Program",
5
+ "columns": [
6
+ [
7
+ {
8
+ "items": [
9
+ {
10
+ "name": "QPP Overview",
11
+ "type": "link",
12
+ "href": "/about/qpp-overview"
13
+ },
14
+ {
15
+ "name": "HCD Research Program",
16
+ "type": "link",
17
+ "href": "/about/hcd-research"
18
+ }
19
+ ]
20
+ }
21
+ ]
22
+ ]
23
+ },
24
+ {
25
+ "name": "MIPS",
26
+ "subtitle": "Merit-based Incentive Payment System",
27
+ "columns": [
28
+ [
29
+ {
30
+ "heading": "Eligibility",
31
+ "items": [
32
+ {
33
+ "name": "How MIPS Eligibility is Determined",
34
+ "type": "link",
35
+ "href": "/mips/how-eligibility-is-determined"
36
+ },
37
+ {
38
+ "name": "MIPS Eligibility Determination Periods",
39
+ "type": "link",
40
+ "href": "/mips/mips-eligibility-determination-periods"
41
+ },
42
+ {
43
+ "name": "Check Participation Status",
44
+ "type": "button",
45
+ "href": "/participation-lookup"
46
+ }
47
+ ]
48
+ },
49
+ {
50
+ "heading": "Reporting Factors",
51
+ "items": [
52
+ {
53
+ "name": "Reporting Factors Overview",
54
+ "type": "link",
55
+ "href": "/mips/reporting-factors-overview"
56
+ },
57
+ {
58
+ "name": "Special Status",
59
+ "type": "link",
60
+ "href": "/mips/special-statuses"
61
+ },
62
+ {
63
+ "name": "Exception Applications",
64
+ "type": "link",
65
+ "href": "/mips/exception-applications"
66
+ },
67
+ {
68
+ "name": "How to Register for CMS Web Interface and the CAHPS for MIPS Survey",
69
+ "type": "link",
70
+ "href": "/mips/how-to-register-for-CMS-WI-and-CAHPS"
71
+ }
72
+ ]
73
+ }
74
+ ],
75
+ [
76
+ {
77
+ "heading": "Participation",
78
+ "items": [
79
+ {
80
+ "name": "Participation Options Overview",
81
+ "type": "link",
82
+ "href": "/mips/overview"
83
+ },
84
+ {
85
+ "name": "Individual or Group Participation",
86
+ "type": "link",
87
+ "href": "/mips/individual-or-group-participation"
88
+ },
89
+ {
90
+ "name": "Virtual Group Participation",
91
+ "type": "link",
92
+ "href": "/mips/virtual-group-participation"
93
+ },
94
+ {
95
+ "name": "APM Entity Participation",
96
+ "type": "link",
97
+ "href": "/mips/apm-entity-participation"
98
+ }
99
+ ]
100
+ },
101
+ {
102
+ "heading": "Traditional MIPS Requirements",
103
+ "items": [
104
+ {
105
+ "name": "Quality Requirements",
106
+ "type": "link",
107
+ "href": "/mips/quality-requirements"
108
+ },
109
+ {
110
+ "name": "Promoting Interoperability Requirements",
111
+ "type": "link",
112
+ "href": "/mips/promoting-interoperability"
113
+ },
114
+ {
115
+ "name": "Improvements Activity Requirements",
116
+ "type": "link",
117
+ "href": "/mips/improvement-activities"
118
+ },
119
+ {
120
+ "name": "Cost Requirements",
121
+ "type": "link",
122
+ "href": "/mips/cost"
123
+ },
124
+ {
125
+ "name": "Explore Measures & Activities",
126
+ "type": "button",
127
+ "href": "/mips/explore-measures"
128
+ }
129
+ ]
130
+ }
131
+ ],
132
+ [
133
+ {
134
+ "heading": "Reporting Options",
135
+ "items": [
136
+ {
137
+ "name": "Reporting Options Overview",
138
+ "type": "link",
139
+ "href": "/mips/reporting-options-overview"
140
+ },
141
+ {
142
+ "name": "Traditional MIPS",
143
+ "type": "link",
144
+ "href": "/mips/traditional-mips"
145
+ },
146
+ {
147
+ "name": "APM Performance Pathway",
148
+ "type": "link",
149
+ "href": "/mips/apm-performance-pathway"
150
+ },
151
+ {
152
+ "name": "MIPS Value Pathways",
153
+ "type": "link",
154
+ "href": "/mips/mips-value-pathways"
155
+ },
156
+ {
157
+ "name": "Submit a Candidate MVP",
158
+ "type": "sublink",
159
+ "href": "/mips/mips-value-pathways/submit-candidate"
160
+ }
161
+ ]
162
+ },
163
+ {
164
+ "heading": "APM Performance Pathway Requirements",
165
+ "items": [
166
+ {
167
+ "name": "Quality Requirements",
168
+ "type": "link",
169
+ "href": "/mips/app-quality-requirements"
170
+ },
171
+ {
172
+ "name": "Promoting Interoperability Requirements",
173
+ "type": "link",
174
+ "href": "/mips/app-promoting-interoperability"
175
+ },
176
+ {
177
+ "name": "Improvements Activities Requirements",
178
+ "type": "link",
179
+ "href": "/mips/app-improvement-activities"
180
+ }
181
+ ]
182
+ }
183
+ ]
184
+ ]
185
+ },
186
+ {
187
+ "name": "APMs",
188
+ "subtitle": "Alternative Payment Models",
189
+ "columns": [
190
+ [
191
+ {
192
+ "items": [
193
+ {
194
+ "name": "APMs Overview",
195
+ "type": "link",
196
+ "href": "/apms/overview"
197
+ },
198
+ {
199
+ "name": "MIPS APMs",
200
+ "type": "link",
201
+ "href": "/apms/mips-apms"
202
+ },
203
+ {
204
+ "name": "Advanced APMs",
205
+ "type": "link",
206
+ "href": "/apms/advanced-apms"
207
+ },
208
+ {
209
+ "name": "All-Payer Advanced APMs",
210
+ "type": "link",
211
+ "href": "/apms/all-payer-advanced-apms"
212
+ },
213
+ {
214
+ "name": "APM Determination Period",
215
+ "type": "link",
216
+ "href": "/apms/apm-determination-periods"
217
+ },
218
+ {
219
+ "name": "Check Participation Status",
220
+ "type": "button",
221
+ "href": "/participation-lookup"
222
+ }
223
+ ]
224
+ }
225
+ ]
226
+ ]
227
+ },
228
+ {
229
+ "name": "Resources",
230
+ "subtitle": "Help, Support and Resources",
231
+ "columns": [
232
+ [
233
+ {
234
+ "items": [
235
+ {
236
+ "name": "COVID-19 Response",
237
+ "type": "link",
238
+ "href": "/resources/covid19"
239
+ },
240
+ {
241
+ "name": "QPP Timeline and Important Deadlines",
242
+ "type": "link",
243
+ "href": "/resources/deadlines"
244
+ },
245
+ {
246
+ "name": "Resource Library",
247
+ "type": "link",
248
+ "href": "/resources/resource-library"
249
+ },
250
+ {
251
+ "name": "Glossary",
252
+ "type": "link",
253
+ "href": "/glossary"
254
+ },
255
+ {
256
+ "name": "Webinar Library",
257
+ "type": "link",
258
+ "href": "/resources/webinars"
259
+ },
260
+ {
261
+ "name": "Help & Support",
262
+ "type": "link",
263
+ "href": "/resources/help-and-support"
264
+ },
265
+ {
266
+ "name": "Small, Underserved, and Rural Practices",
267
+ "type": "link",
268
+ "href": "/resources/small-underserved-rural-practices"
269
+ },
270
+ {
271
+ "name": "Developer Tools",
272
+ "type": "link",
273
+ "href": "/developers"
274
+ }
275
+ ]
276
+ }
277
+ ]
278
+ ]
279
+ }
280
+ ]
@@ -0,0 +1,40 @@
1
+ import React from 'react';
2
+ import { render } from 'react-dom';
3
+ import HeaderUI from './HeaderUI.jsx';
4
+
5
+ /**
6
+ * Renders the QPP Header content.
7
+ */
8
+ export default class Header {
9
+ /**
10
+ * @param {Object} options - An object containing content and config data
11
+ * @param {Boolean} options.isLoginEnabled
12
+ * @param {String} options.skipToContentId - The HTML ID of main content
13
+ * @param {Boolean} options.includeSkipToSidebar
14
+ * @param {Boolean} options.showCancelButton
15
+ * @param {Boolean} options.showCovidLink
16
+ * @param {Boolean} options.isIESupportPage
17
+ * @param {HTMLElement} options.rootElement - Elem inside which to render
18
+ */
19
+ constructor(options) {
20
+ render(
21
+ <HeaderUI
22
+ isLoginEnabled={options.isLoginEnabled}
23
+ skipToContentId={options.skipToContentId}
24
+ includeSkipToSidebar={options.includeSkipToSidebar}
25
+ showCancelButton={options.showCancelButton}
26
+ performanceYear={options.performanceYear}
27
+ feedbackPerformanceYear={options.feedbackPerformanceYear}
28
+ fbpPerformanceYear={options.fbpPerformanceYear}
29
+ showPhysicianCompareLink={options.showPhysicianCompareLink}
30
+ showFacilityBasedPreviewLink={options.showFacilityBasedPreviewLink}
31
+ showCovidLink={options.showCovidLink}
32
+ showMaqi={options.showMaqi}
33
+ isDevPre={options.isDevPre}
34
+ content={options.content}
35
+ isIESupportPage={options.isIESupportPage}
36
+ />,
37
+ options.rootElement
38
+ );
39
+ }
40
+ }
@@ -0,0 +1,52 @@
1
+ import React, { createContext, useState, useEffect, useContext } from 'react';
2
+ import PropTypes from 'prop-types';
3
+
4
+ export function useWindowWidth() {
5
+ const [windowSize, setWindowSize] = useState(undefined);
6
+ useEffect(() => {
7
+ function handleResize() {
8
+ setWindowSize(window.innerWidth);
9
+ }
10
+ window.addEventListener('resize', handleResize);
11
+ handleResize();
12
+ return () => window.removeEventListener('resize', handleResize);
13
+ }, []);
14
+ return windowSize;
15
+ }
16
+
17
+ export const HeaderStateContext = createContext(null);
18
+
19
+ export const HeaderStateProvider = ({ children, RouterLink }) => {
20
+ const [currentOpenMenu, setCurrentOpenMenu] = useState('');
21
+
22
+ const handleToggleMenu = (name) => {
23
+ if (currentOpenMenu === name) {
24
+ return setCurrentOpenMenu('');
25
+ }
26
+ return setCurrentOpenMenu(name);
27
+ };
28
+
29
+ const closeMenus = () => setCurrentOpenMenu('');
30
+ return (
31
+ <HeaderStateContext.Provider
32
+ value={{ currentOpenMenu, handleToggleMenu, closeMenus, RouterLink }}
33
+ >
34
+ {children}
35
+ </HeaderStateContext.Provider>
36
+ );
37
+ };
38
+ HeaderStateProvider.propTypes = {
39
+ children: PropTypes.node.isRequired,
40
+ RouterLink: PropTypes.func,
41
+ };
42
+ HeaderStateProvider.defaultProps = {
43
+ RouterLink: null,
44
+ };
45
+
46
+ export const useHeaderState = () => {
47
+ const context = useContext(HeaderStateContext);
48
+ if (context === undefined) {
49
+ throw new Error('useHeaderState must be used within a HeaderStateProvider');
50
+ }
51
+ return context;
52
+ };
@@ -0,0 +1,9 @@
1
+ export const setUtagLink = (eventCategory, eventAction, eventLabel) =>
2
+ window?.utag?.link({
3
+ ga_event_category: eventCategory,
4
+ ga_event_action: eventAction,
5
+ ga_event_label: eventLabel,
6
+ page_title: `${window.document.title}`,
7
+ page_url: `${window.location.pathname}`,
8
+ event: 'trackEvent',
9
+ });
@@ -0,0 +1,75 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import Tooltip from '../Tooltip';
4
+ import InfotipIcon from './InfotipIcon';
5
+
6
+ const BUTTON_SIZE = '16px';
7
+
8
+ const buttonStyle = {
9
+ background: 'transparent',
10
+ border: 0,
11
+ padding: 0,
12
+ width: BUTTON_SIZE,
13
+ height: BUTTON_SIZE,
14
+ WebkitTouchCallout: 'none',
15
+ WebkitUserSelect: 'none',
16
+ userSelect: 'none',
17
+ };
18
+
19
+ // Use basic touch handlers for mobile "tap-to-open" ui. Mobile touch
20
+ // is currently not supported by @reach/tooltip; this may change in future.
21
+ // Leverages @reach/tooltip "focus" behavior to open tooltip on tap,
22
+ // and close tooltip on second tap or loss of focus.
23
+ // TODO: We may want to improve this by tracking touch positions to ensure
24
+ // that a 'touchend' event must be reasonably close to the tooltip target.
25
+ const touchHandlers = {
26
+ onTouchStart: (e) => {
27
+ e.stopPropagation();
28
+ },
29
+ onTouchEnd: (e) => {
30
+ if (document.activeElement !== e.currentTarget) {
31
+ e.preventDefault();
32
+ e.currentTarget.focus();
33
+ } else {
34
+ e.preventDefault();
35
+ e.currentTarget.blur();
36
+ }
37
+ },
38
+ };
39
+
40
+ /**
41
+ * Tooltip with styled information icon
42
+ */
43
+ const Infotip = ({ label, lightIcon, ...props }) => (
44
+ <Tooltip label={label} {...props}>
45
+ <button
46
+ type="button"
47
+ aria-label="Information"
48
+ style={buttonStyle}
49
+ {...touchHandlers}
50
+ >
51
+ <InfotipIcon
52
+ lightIcon={lightIcon}
53
+ width={BUTTON_SIZE}
54
+ height={BUTTON_SIZE}
55
+ aria-hidden
56
+ style={{ float: 'left' }}
57
+ />
58
+ </button>
59
+ </Tooltip>
60
+ );
61
+
62
+ Infotip.propTypes = {
63
+ label: PropTypes.string.isRequired,
64
+ ariaLabel: PropTypes.string,
65
+ lightIcon: PropTypes.bool,
66
+ DEBUG_STYLE: PropTypes.bool,
67
+ };
68
+
69
+ Infotip.defaultProps = {
70
+ ariaLabel: undefined,
71
+ lightIcon: false,
72
+ DEBUG_STYLE: undefined,
73
+ };
74
+
75
+ export default Infotip;
@@ -0,0 +1,50 @@
1
+ import React from 'react';
2
+ import Infotip from './index';
3
+ import { withKnobs, boolean } from '@storybook/addon-knobs';
4
+
5
+ export default {
6
+ title: 'Infotip',
7
+ component: Infotip,
8
+ decorators: [
9
+ withKnobs,
10
+ (storyFn) => (
11
+ <div style={{ marginTop: '120px', marginLeft: '100px' }}>{storyFn()}</div>
12
+ ),
13
+ ],
14
+ };
15
+
16
+ export const ExampleInfoTip = () => (
17
+ <Infotip label="Tooltip Content!" lightIcon={boolean('lightIcon', false)} />
18
+ );
19
+
20
+ ExampleInfoTip.storyName = 'qpp themed Infotip';
21
+
22
+ export const PositionCollisionInfotip = () => (
23
+ <Infotip
24
+ DEBUG_STYLE
25
+ label="The DEBUG_STYLE prop is supported by the useTooltip hook and should only
26
+ be used for development."
27
+ />
28
+ );
29
+
30
+ PositionCollisionInfotip.storyName = 'position collision';
31
+
32
+ export const LongContentInfotip = () => (
33
+ <div style={{ paddingTop: '50px' }}>
34
+ <span style={{ marginLeft: '120px' }} />
35
+ <Infotip
36
+ DEBUG_STYLE
37
+ label="Initial Eligibility determination covers data collected from Oct. 1, 2018 to Sept. 31, 2019. Determination was released in Dec. 2019. Final eligibility will be released in Nov. 2020."
38
+ />
39
+ </div>
40
+ );
41
+
42
+ LongContentInfotip.storyName = 'long content';
43
+
44
+ export const LightIconInfotip = () => (
45
+ <div style={{ backgroundColor: '#04838A', padding: '20px', width: '16px' }}>
46
+ <Infotip lightIcon label="Light Icon Infotip" />
47
+ </div>
48
+ );
49
+
50
+ LightIconInfotip.storyName = 'alternate light icon';
@@ -0,0 +1,41 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+
4
+ const InfotipIcon = ({ lightIcon, ...props }) => (
5
+ <svg
6
+ width="20px"
7
+ height="20px"
8
+ viewBox="0 0 20 20"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ {...props}
11
+ >
12
+ <g fill="none" fillRule="evenodd">
13
+ <path
14
+ d="M9.721 19.158c-4.947 0-8.973-4.126-8.973-9.196C.748 4.892 4.774.766 9.72.766c4.948 0 8.974 4.126 8.974 9.196 0 5.07-4.026 9.196-8.974 9.196z"
15
+ fill="#2EB1ED"
16
+ fillRule="nonzero"
17
+ />
18
+ <path
19
+ d="M9.721 0C4.361 0 0 4.469 0 9.962c0 5.493 4.36 9.962 9.721 9.962 5.36 0 9.722-4.469 9.722-9.962C19.443 4.469 15.082 0 9.72 0z"
20
+ fill={lightIcon ? '#FFF' : '#04838A'}
21
+ />
22
+ <path
23
+ d="M9.721 14.765c-.206 0-.374.112-.374.25v.5c0 .138.168.25.374.25.207 0 .374-.112.374-.25v-.5c0-.138-.167-.25-.374-.25zM9.764 4.706H9.72c-.792 0-1.536.29-2.1.821a2.767 2.767 0 0 0-.89 2.03c0 .197.166.356.373.356s.374-.159.374-.356c0-.577.237-1.118.668-1.523a2.268 2.268 0 0 1 1.607-.615c1.182.016 2.195.98 2.211 2.107.011.743-.373 1.427-1.028 1.83-.995.61-1.589 1.691-1.589 2.89v1.013c0 .197.168.357.374.357.207 0 .374-.16.374-.357v-1.013c0-.941.477-1.82 1.246-2.292.873-.537 1.386-1.448 1.371-2.438-.022-1.527-1.345-2.788-2.948-2.81z"
24
+ stroke={lightIcon ? '#04838A' : '#FFF'}
25
+ strokeWidth=".5"
26
+ fill={lightIcon ? '#04838A' : '#FFF'}
27
+ fillRule="nonzero"
28
+ />
29
+ </g>
30
+ </svg>
31
+ );
32
+
33
+ export default InfotipIcon;
34
+
35
+ InfotipIcon.propTypes = {
36
+ lightIcon: PropTypes.bool,
37
+ };
38
+
39
+ InfotipIcon.defaultProps = {
40
+ lightIcon: false,
41
+ };
@@ -0,0 +1,3 @@
1
+ import Infotip from './Infotip';
2
+
3
+ export default Infotip;
@@ -0,0 +1,81 @@
1
+ import React from 'react';
2
+ import DSLink from './index';
3
+ import { withKnobs } from '@storybook/addon-knobs';
4
+ import OpenInNewIcon from '@material-ui/icons/OpenInNew';
5
+
6
+ export default {
7
+ title: 'Link',
8
+ component: DSLink,
9
+ decorators: [withKnobs],
10
+ };
11
+
12
+ export const LinkLabel = () => <DSLink href="#">Link Label</DSLink>;
13
+
14
+ export const LinkColorVariants = () => (
15
+ <>
16
+ <div className=" qpp-dark-background qpp-u-padding--16">
17
+ <DSLink href="#" variant="white">
18
+ Link Label
19
+ </DSLink>
20
+ </div>
21
+ <p>
22
+ <DSLink href="#" variant="gray">
23
+ Link Label
24
+ </DSLink>
25
+ </p>
26
+ </>
27
+ );
28
+
29
+ export const inlineLinks = () => (
30
+ <div className="qpp-u-padding--16">
31
+ <p className="qpp-u-width--60">
32
+ Aenean lacinia <DSLink href="#">inline link</DSLink> nulla sed{' '}
33
+ <DSLink href="#">inline link</DSLink>. Integer posuere erat a ante
34
+ venenatis dapibus posuere velit aliquet. Integer posuere erat a ante
35
+ venenatis <DSLink href="#">inline link</DSLink> dapibus posuere velit
36
+ aliquet.
37
+ </p>
38
+ </div>
39
+ );
40
+
41
+ export const inlineLinksDarkBackground = () => (
42
+ <div className="qpp-dark-background qpp-u-padding--16">
43
+ Aenean lacinia{' '}
44
+ <DSLink href="#" variant="white">
45
+ inline link
46
+ </DSLink>{' '}
47
+ nulla sed{' '}
48
+ <DSLink href="#" variant="white">
49
+ inline link
50
+ </DSLink>
51
+ . Integer posuere erat a ante venenatis dapibus posuere velit aliquet.
52
+ Integer posuere erat a ante venenatis{' '}
53
+ <DSLink href="#" variant="white">
54
+ inline link
55
+ </DSLink>{' '}
56
+ dapibus posuere velit aliquet.
57
+ </div>
58
+ );
59
+
60
+ export const linkWithIcon = () => {
61
+ const icon = <OpenInNewIcon classes={{ root: 'qpp-icon-mat' }} />;
62
+ return (
63
+ <div className="qpp-u-padding--16">
64
+ <DSLink href="#">
65
+ Standalone Link With Icon
66
+ {icon}
67
+ </DSLink>{' '}
68
+ <p className=" qpp-u-width--60">
69
+ Aenean lacinia{' '}
70
+ <DSLink href="#">
71
+ inline link
72
+ {icon}
73
+ </DSLink>{' '}
74
+ nulla sed <DSLink href="#">inline link {icon}</DSLink>. Integer posuere
75
+ erat a ante venenatis dapibus posuere velit aliquet. Integer posuere
76
+ erat a ante venenatis <DSLink href="#">inline link {icon}</DSLink>{' '}
77
+ dapibus posuere velit aliquet.
78
+ </p>
79
+ </div>
80
+ );
81
+ };
@@ -0,0 +1,61 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+
4
+ const VARIANTS = ['white', 'gray'];
5
+
6
+ const DSLink = ({
7
+ className,
8
+ href,
9
+ download,
10
+ ariaLabel,
11
+ onClick,
12
+ children,
13
+ variant,
14
+ ...rest
15
+ }) => {
16
+ let linkClass = 'qpp-c-link';
17
+ if (VARIANTS.includes(variant)) {
18
+ variant === 'gray'
19
+ ? (linkClass = linkClass.concat(' ', 'qpp-u-color--gray-60'))
20
+ : (linkClass = linkClass.concat(' ', `qpp-u-color--${variant}`));
21
+ }
22
+
23
+ if (className) {
24
+ linkClass = linkClass.concat(' ', className);
25
+ }
26
+
27
+ return (
28
+ <a
29
+ aria-label={ariaLabel}
30
+ className={linkClass || ''}
31
+ href={href}
32
+ download={download}
33
+ onClick={onClick}
34
+ {...rest}
35
+ >
36
+ {children}
37
+ </a>
38
+ );
39
+ };
40
+
41
+ DSLink.propTypes = {
42
+ children: PropTypes.node,
43
+ className: PropTypes.string,
44
+ href: PropTypes.string,
45
+ ariaLabel: PropTypes.string,
46
+ onClick: PropTypes.func,
47
+ download: PropTypes.bool,
48
+ variant: PropTypes.oneOf(VARIANTS),
49
+ };
50
+
51
+ DSLink.defaultProps = {
52
+ children: null,
53
+ className: '',
54
+ href: '',
55
+ ariaLabel: null,
56
+ onClick: () => null,
57
+ download: false,
58
+ variant: null,
59
+ };
60
+
61
+ export default DSLink;