-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Fix search by order number in Navigator #5063
Conversation
🦋 Changeset detectedLatest commit: 7f345a1 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Co-authored-by: Paweł Chyła <[email protected]>
const { result } = renderHook(() => useQuickOrderSearch()); | ||
|
||
// Act | ||
act(() => result.current[1]("1234")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const { result } = renderHook(() => useQuickOrderSearch()); | |
// Act | |
act(() => result.current[1]("1234")); | |
const { result } = renderHook(() => useQuickOrderSearch()); | |
const [_, setQueryDebounced] = result.current | |
// Act | |
act(() => setQueryDebounced("1234")); |
orderNumber, | ||
}), | ||
onClick: () => { | ||
navigate(orderUrl(order.id)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can't entries be a links? navigation based on onClick are hacky a bit
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can improve it in the scope of the general Navigator improvements ticket (it's in backlog)
* use search by order number * fixes * Update src/components/NavigatorSearch/modes/orders.ts Co-authored-by: Paweł Chyła <[email protected]> * lint * add test for making search query * improve test --------- Co-authored-by: Paweł Chyła <[email protected]>
What type of PR is this?
Related Issues or Documents
Usage Instructions, Screenshots, Recordings
Have you written tests?
[Optional] Description