From 4e9d3493cecfe7ea707455ba783a3da20c99198b Mon Sep 17 00:00:00 2001 From: David Paul Graham <43794491+dpgraham4401@users.noreply.github.com> Date: Wed, 15 May 2024 16:30:58 -0400 Subject: [PATCH] First time instructions (#130) * fix text color of share button * add responsive design breakpoints to main header * add text-black class to minimap and layout control center buttons * minor styling adjustments for accessibility * add show guide button header, guide.html, and show the guide on the visitors first use * remove animated pulse for current decision * mock local storage to indicate whether it is a user's first time --- public/help/guide.html | 42 +++++++++++++++++++ src/App.spec.tsx | 3 +- src/App.tsx | 4 +- src/components/Header/Header.tsx | 20 ++++++++- src/components/Help/Help.spec.tsx | 2 + src/components/Help/Help.tsx | 1 - src/components/Help/HelpIcon/HelpIcon.tsx | 5 ++- src/components/OffCanvas/OffCanvas.tsx | 14 +++++-- .../Controls/LayoutBtn/LayoutBtn.tsx | 1 + .../Controls/MiniMapBtn/MiniMapBtn.tsx | 6 ++- .../Controls/ShareBtn/ShareBtn.tsx | 6 ++- .../Tree/Nodes/BoolNode/BoolNode.tsx | 5 +-- .../Tree/Nodes/DefaultNode/DefaultNode.tsx | 4 +- src/components/Tree/Tree.tsx | 7 ++-- src/hooks/useHelp/useHelp.spec.tsx | 18 +++++++- src/hooks/useHelp/useHelp.tsx | 27 ++++++++++-- src/index.css | 11 ++--- src/test-utils.tsx | 16 +++++++ tsconfig.json | 15 +++++-- 19 files changed, 167 insertions(+), 40 deletions(-) create mode 100644 public/help/guide.html diff --git a/public/help/guide.html b/public/help/guide.html new file mode 100644 index 0000000..05fdfb5 --- /dev/null +++ b/public/help/guide.html @@ -0,0 +1,42 @@ +
Welcome to The + Manifest Game, an interactive decision tree to help you + use the U.S. EPA's hazardous waste tracking system known as + e-Manifest. +
++ Start by answering the "Yes" or "No" questions in the boxes. As you answer + questions, new questions will appear based on your previous answers. +
++ If you are unsure about a question, click the question mark in the question + box to learn more. +
++ You can move around the page by clicking and dragging anywhere on the page. + You can also zoom in and out by using the scroll wheel on your mouse or + pinching on a touch screen. +
++ The mini map in the bottom right corner shows you where you are on the + decision tree. You can click the mini map to quickly navigate to + different parts of the decision tree, and scroll to zoom in and out. +
++ You can change the layout of the decision tree from horizontal to vertical + by clicking the "Layout" button to help you visualize the decision tree in + different ways. +
++ Once you have completed the decision tree, you can share your decisions with + others by clicking the "Share" button. This will generate a unique URL + you can share with others. +
+