From 676f1db665068d62b5d2349b96031622a404ff4e Mon Sep 17 00:00:00 2001 From: miles-grant-ibigroup Date: Thu, 10 Aug 2023 15:47:44 -0400 Subject: [PATCH 01/11] refactor: begin shift from walk reluctance slider to dropdown --- .../form/call-taker/advanced-options.js | 28 +++++++++++-------- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/lib/components/form/call-taker/advanced-options.js b/lib/components/form/call-taker/advanced-options.js index 450c8c67f..dcf81ee32 100644 --- a/lib/components/form/call-taker/advanced-options.js +++ b/lib/components/form/call-taker/advanced-options.js @@ -2,9 +2,13 @@ // FIXME: Remove the following eslint rule exception. /* eslint-disable jsx-a11y/label-has-for */ import * as TripFormClasses from '@opentripplanner/trip-form/lib/styled' +import { + DropdownSelector, + SliderSelector, + SubmodeSelector +} from '@opentripplanner/trip-form' import { FormattedMessage, injectIntl } from 'react-intl' import { hasBike } from '@opentripplanner/core-utils/lib/itinerary' -import { SliderSelector, SubmodeSelector } from '@opentripplanner/trip-form' import isEmpty from 'lodash.isempty' import React, { Component, lazy, Suspense } from 'react' import styled from 'styled-components' @@ -155,9 +159,9 @@ class AdvancedOptions extends Component { }) } - _setWaklTolerance = ({ walkTolerance }) => { + _setWalkTolerance = ({ walkReluctance }) => { this.props.setUrlSearch({ - walkTolerance + walkReluctance }) } @@ -224,17 +228,19 @@ class AdvancedOptions extends Component { justifyContent: 'space-between' }} > - {hasBike(currentModes?.map((m) => m.mode).join(',') || '') ? ( From a721df410c66ddc6bca8b1658d88154e6a2ecaff Mon Sep 17 00:00:00 2001 From: amy-corson-ibigroup <115499534+amy-corson-ibigroup@users.noreply.github.com> Date: Tue, 15 Aug 2023 10:29:35 -0500 Subject: [PATCH 02/11] feat: reset focus to top on each account step --- lib/components/user/sequential-pane-display.tsx | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/lib/components/user/sequential-pane-display.tsx b/lib/components/user/sequential-pane-display.tsx index 1939d67af..adf171e21 100644 --- a/lib/components/user/sequential-pane-display.tsx +++ b/lib/components/user/sequential-pane-display.tsx @@ -50,6 +50,12 @@ class SequentialPaneDisplay extends Component> { routeTo(`${parentPath}/${nextId}`) } + h1Ref = React.createRef() + + _handleFocus = () => { + this.h1Ref?.current?.focus() + } + _handleToNextPane = async (e: MouseEvent