Repository: dcapal/dcapal (language: rust)

Issue:
Currency should keep selected on back navigation



Discussion / hints:

Fix patch:
diff --git a/dcapal-frontend/src/components/allocationFlow/ccyStep/index.js b/dcapal-frontend/src/components/allocationFlow/ccyStep/index.js
index 4cf279a5..6b61e1e2 100644
--- a/dcapal-frontend/src/components/allocationFlow/ccyStep/index.js
+++ b/dcapal-frontend/src/components/allocationFlow/ccyStep/index.js
@@ -25,7 +25,8 @@ const sortCcy = (a, b) => {
 };
 
 export const CcyStep = ({ ...props }) => {
-  const [selected, setSelected] = useState("");
+  const portfolioState = useSelector((state) => state.pfolio);
+  const [selected, setSelected] = useState(portfolioState.quoteCcy ?? "");
   const ccys = useSelector((state) => state.app.currencies);
   const dispatch = useDispatch();
   const navigate = useNavigate();


Test patch: