saleor-dashboard/src/hooks
Wojciech Mista 8f9c1ba19e
Gift cards post mvp (#1632)
* Add gift bulk create (#1490)

* Add gift card bulk create dialog WIP

* Update schema, add gift card bulk create mutation and types

* Add gift card bulk create modal and mutation

* Fix types and update messages

* Refactor gift card bulk create

* Add closing gift card bulk create dialog after success

* Change gift card list closeDialog prop name to onClose

* Review fixes

* Review fixes

* Add error message to invalid expiryDate (#1518)

* Add error message to invalid expiryDate

* Add default messages

* Replace filter with some

* Add gift card export (#1499)

* wip

* Add exporting gift cards

* Update messages

* Fix types

* Review fixes

* Review fixes

* Refactor passing messages to export settings component

* Refactor

* Update messages

* Gift card customer page (#1520)

* Add gift cards card to customer page (#1456)

* WIP

* WIP

* Extract activate/deactivate logic to a hook

* add optional side action

* Add query for customer's gift cards

* Add component for giftcard status chip

* Graphql run types

* Add gift card card to customer page

* Fix status chip header

* Revert style change

* Unify status chip logic

* Fix naming scheme

* Add currentOpts to act/deactivate gift cards hook

* Add queries to refetch prop

* Simplify gift card list component

* Fix order status chip

* Extract messages to separate file

* Remove unused lines of code

* Tests and messages

* Fix card list rendering

* Type fix

* Code review fixes

* Review changes

* Scripts

* Change variable name

* Fix formatted message

* Check if giftcards exist before rendering collection

* Add loading button to CardMenu component (#1476)

* WIP

* WIP

* Add gift card card to customer page

* Fix status chip header

* Fix naming scheme

* Add currentOpts to act/deactivate gift cards hook

* Remove unused lines of code

* Revert style change

* Tests and messages

* Fix card list rendering

* Type fix

* Code review fixes

* Review changes

* Scripts

* Add loading animation to card menu buttons

* Added default messages

* Change conditional prop checking to filtering

* Issue gift card in customer page (#1468)

* WIP

* WIP

* Replace typed query with make query

* Add customer details context to customer page

* Add context to customer gift cards

* Disable customer select when initial customer is present

* Pass initial customer to create gift card form

* Fixes after cherry-pick

* Code cleanup

* Remove getInitialData function

* Remove unused package

* Remove new line

* Post-rebase fixes

* Code cleanup & extract messages

* Remove unused code

* Create customer details hook

* Minor fixes

* Update default messages

* Update gift card types

* Type fixes

* Change directory of useCustomerDetails hook

* CR Fixes

* Update tests

* Make PageTitleWithStatusChip use ExtendedPageHeader

* Update tests

* Update hook name

* Post-rebase fixes

* Eslint fix

* Fix scrollbar appearing in menu issue (#1539)

* Change displayCode to last4CodeChars (#1573)

* Add filtered redirect to gift card page from customer details (#1556)

* Limit number of channel list items (#1607)

* Add max height to single select field menu items container

* Add storybook case

* Update stories tests

* Fix gift card product changing to preorder on save issue (#1583)

* Variant preorder fix

* Global threshold input should be optional

* update snapshot

* Add displaying logic gift cards list toolbar (#1617)

* add displaying logic for gift card toolbar

* Logic fix

* Handle bulk export after creation (#1544)

* Add gift bulk create (#1490)

* Add gift card bulk create dialog WIP

* Update schema, add gift card bulk create mutation and types

* Add gift card bulk create modal and mutation

* Fix types and update messages

* Refactor gift card bulk create

* Add closing gift card bulk create dialog after success

* Change gift card list closeDialog prop name to onClose

* Review fixes

* Review fixes

* Add gift card export (#1499)

* wip

* Add exporting gift cards

* Update messages

* Fix types

* Review fixes

* Review fixes

* Refactor passing messages to export settings component

* Refactor

* Update messages

* Handle export after bulk gift card creation

* Add default messages

* Create an util function to get correct input for export

* Update component's name

* Change modal's title

* Update messages

Co-authored-by: Magdalena Markusik <magdalena@markusik.com>

* Gift Card List item number change doesn't refetch fix (#1643)

* Fix number of rows change not refetching list

* Add pagination reset

* Update descriptions for gift card messages to be more descriptive (#1648)

* Gift card history timeline  (#1597)

* Update queries and mutations

* Allow title to be a react node

* Show user name if it exists in data object

* Update types

* Refresh queries on note add

* Add gift card history

* type fix

* Update messages

* Fix timeline note

* Add event fragment to form update result

* Update types

* Fix typo

* Update messages

* Disable input if gift card is expired

* Remove unused imports

* CR Fixes

* Change messages location

* Change message to include user in order

* Allow adding notes to expired gift cards

* Fix disabled input showing dropdown issue (#1636)

* On click is disabled when component is disabled

* update tests

* Order filtering for gift cards in Order List View (#1628)

* Add gift card order filter

* Add gift card filter card in orders view

* Bump macaw version

* Update messages

* Update tests

* Code review changes

* update messages

* Change info card message to use only one message

* Fix order gift card filter

* Gift card filter in product list view (#1621)

* Add GiftCard or Normal filter in Product List View

* Fix tests

* Fix type check

* Don't filter if query param is not in enum

* Update messages

* Update tests

* Code cleanup

* Add default messages

* Pass intl rather than initialise it in util

* Post-rebase fixes

* Change product type details messages (#1642)

* Update product type gift card options messages

* update tests

* Add sorting to gift card list (#1569)

* Update queries and types for sorting

* Add optional handleError method to makeQuery

* Add sorting to gift card list

* Sorting hook uses useGiftCardList hook

* Convert to boolean

* Add default sorting field

* format fix

* Add expiry error handling for issuing gift cards (#1634)

* Add expiry error handling for issuing gift cards

* Add expiry error message to gift card bulk issue

* Update Gift Card tag queries to utilise multiple tags (#1685)

* Change displayCode to last4CodeChars (#1573)

* Update types

* WIP

* Update gift card forms to utilise multiple tags

* Code cleanup

* Update gift card event types

* Fixes

* Change column with no click handler behaviour

* Remove an ability to sort by tags

* Remove unused code

* Update tests

* Update timeline events

* Update messages

* change array reduce to join

* Add Y scroll to dialog content

* Bulk create Y scroll fix

* Endless loading fix (#1732)

* Order filtering for gift cards in Order List View (#1628)

* Add gift card order filter

* Add gift card filter card in orders view

* Bump macaw version

* Update messages

* Update tests

* Code review changes

* update messages

* Change info card message to use only one message

* Fix order gift card filter

* Wip

* Extract dialog component outside of gift card create

* Update component's name

* Extract dialog component outside of export component to provider

* Update tests

* Various gift card bugs fixes (#1749)

* Change currency to options field

* Fix hover and font size

* Fix gift card list width

* Fix bulk delete dialog

* Allow balance to be sorted only when currency is filtered

* Sorting by balance after removing currency filter defualts to usedBy

* Fix trash icon

* Add filter dependency

* Fix single deletion with bulk

* Update tests

* Refactor Links used in Gift Cards

* Fix export dialog (#1791)

Co-authored-by: Magdalena Markusik <magdalena@markusik.com>
2022-01-25 13:44:19 +01:00
..
debug Add debug hook 2020-01-20 16:46:59 +01:00
makeTopLevelSearch Adjust changed permission requirements(#1542) (#1747) 2022-01-12 14:14:46 +01:00
useModalDialogErrors Add missing files 2019-08-09 12:17:04 +02:00
useModalDialogOpen Add missing files 2019-08-09 12:17:04 +02:00
useNotifier Add channel shipping zones (#1015) 2021-04-14 15:44:25 +02:00
makeMutation.ts Use Auth SDK (#1474) 2021-12-17 12:10:54 +01:00
makeQuery.ts Gift cards post mvp (#1632) 2022-01-25 13:44:19 +01:00
makeSearch.ts Add search hooks 2019-11-21 15:59:31 +01:00
useAddressValidation.ts Saleor 2798 user addresses selection for draft order (#1082) 2021-05-06 13:38:15 +02:00
useAppState.ts Add app state 2019-11-14 15:10:52 +01:00
useBackgroundTask.ts Fix useBackgroundTask hook 2020-06-26 13:09:56 +02:00
useBulkActions.ts Add Gift Cards #1 (#1291) 2021-08-16 15:44:00 +02:00
useChannels.test.ts Add optional channel selection in price and weight rates view + voucher view (#1531) 2021-11-29 09:32:06 +01:00
useChannels.ts Saleor 1659 use query params in channels picker (#886) 2020-12-04 18:09:28 +01:00
useChannelsSearch.ts Feature - channels per plugin (#1093) 2021-05-11 15:58:09 +02:00
useChannelsSearchWithLoadMore.ts Reduce bundle size (#1103) 2021-05-14 10:15:15 +02:00
useClipboard.ts Create useClipboard hook 2019-10-04 13:12:50 +02:00
useCurrentDate.ts Feature - Gift Cards (#1366) 2021-09-14 15:57:02 +02:00
useDateLocalize.ts Add channel shipping zones (#1015) 2021-04-14 15:44:25 +02:00
useDebounce.ts Debounce order search 2019-11-21 18:47:06 +01:00
useElementScroll.ts Reduce bundle size (#1103) 2021-05-14 10:15:15 +02:00
useForm.ts Add Gift Cards #1 (#1291) 2021-08-16 15:44:00 +02:00
useFormset.ts Rich text, multiselect, useFormset fixes (#1077) 2021-04-23 14:27:31 +02:00
useInterval.ts Multichannel (#833) 2020-11-17 17:10:42 +01:00
useListActions.ts Use eslint instead of tslint 2019-12-02 16:33:58 +01:00
useListSettings.test.ts Fix initial list settings (#1401) 2021-09-17 11:59:28 +02:00
useListSettings.ts Fix initial list settings (#1401) 2021-09-17 11:59:28 +02:00
useLocale.ts Add circleci config and enhance our linters (#519) 2020-05-14 11:30:32 +02:00
useLocalPageInfo.ts Attribute values pagination in product details (#1125) 2021-06-08 09:51:26 +02:00
useLocalPaginator.ts Fix auto scroll (#1644) 2021-12-06 16:41:18 +02:00
useLocalStorage.test.ts Fix initial list settings (#1401) 2021-09-17 11:59:28 +02:00
useLocalStorage.ts Save as empty value, when trying to save undefined var to local storage (#1443) 2021-09-28 17:29:57 +02:00
useMultiAutocomplete.ts Add circleci config and enhance our linters (#519) 2020-05-14 11:30:32 +02:00
useNavigator.ts Fix auto scroll (#1644) 2021-12-06 16:41:18 +02:00
useOnSetDefaultVariant.ts Fix set default variant alert 2020-10-09 11:00:06 +02:00
usePaginationReset.ts Fix pagination state after refresh (#1496) (#1515) 2021-10-25 17:29:27 +02:00
usePaginator.ts Fix auto scroll (#1644) 2021-12-06 16:41:18 +02:00
useScroll.ts Reduce bundle size (#1103) 2021-05-14 10:15:15 +02:00
useSearchQuery.ts Add circleci config and enhance our linters (#519) 2020-05-14 11:30:32 +02:00
useServiceWorker.ts Fix update notifications (#1387) 2021-09-14 11:06:28 +02:00
useShop.ts Add circleci config and enhance our linters (#519) 2020-05-14 11:30:32 +02:00
useStateFromProps.ts Reduce bundle size (#1103) 2021-05-14 10:15:15 +02:00
useUpdateEffect.ts Fix initial discount calculation on draft order line (#1651) 2021-12-07 10:44:49 +01:00
useWindowScroll.ts Reduce bundle size (#1103) 2021-05-14 10:15:15 +02:00
useWizard.ts Add stock to variant matrix 2020-04-28 16:37:10 +02:00