Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TASK-387 Sort shifts in dropdown #282

Merged
merged 10 commits into from
Mar 18, 2021
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export function AutocompleteComponent<
getOptionLabel,
open: true,
});
const { ShiftTypes } = useSelector(
const ShiftTypes = useSelector(
net-runner marked this conversation as resolved.
Show resolved Hide resolved
(state: ApplicationStateModel) => state.actualState.persistentSchedule.present.shift_types
);
const LabelComponent = ({ option, index }): JSX.Element => {
Expand Down Expand Up @@ -96,7 +96,7 @@ export function AutocompleteComponent<
onKeyDown={onKeyDown}
/>
</div>
{groupedOptions.length > 0 ? (
{ShiftTypes && groupedOptions.length > 0 ? (
<div
ref={tooltipRef}
className={classNames("listbox")}
Expand Down