@turtleclub/hooks 0.5.0-beta.2 → 0.5.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +5 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -4
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/v2/incentives/api.ts +2 -2
- package/src/v2/index.ts +2 -2
- package/src/v2/lib/turtle-provider.tsx +3 -3
- package/src/v2/products/api.ts +7 -13
package/dist/index.js
CHANGED
|
@@ -684,7 +684,7 @@ async function getProducts(filters) {
|
|
|
684
684
|
const params = new URLSearchParams();
|
|
685
685
|
if (filters?.organizationId) params.append("organizationId", filters.organizationId);
|
|
686
686
|
const queryString = params.toString();
|
|
687
|
-
const endpoint = `/
|
|
687
|
+
const endpoint = `/turtle/products${queryString ? `?${queryString}` : ""}`;
|
|
688
688
|
const data = await apiClient.fetch(endpoint, {
|
|
689
689
|
method: "GET"
|
|
690
690
|
});
|
|
@@ -696,7 +696,7 @@ async function getProducts(filters) {
|
|
|
696
696
|
return result.data;
|
|
697
697
|
}
|
|
698
698
|
async function getProduct(id) {
|
|
699
|
-
const endpoint = `/
|
|
699
|
+
const endpoint = `/turtle/products/${id}`;
|
|
700
700
|
const data = await apiClient.fetch(endpoint, {
|
|
701
701
|
method: "GET"
|
|
702
702
|
});
|
|
@@ -1779,7 +1779,7 @@ function useSwapRoute(isEnabled, userAddress, distributorId, options, referralCo
|
|
|
1779
1779
|
// src/v2/lib/turtle-provider.tsx
|
|
1780
1780
|
import { useEffect, useMemo as useMemo9 } from "react";
|
|
1781
1781
|
import { Fragment, jsx } from "react/jsx-runtime";
|
|
1782
|
-
function
|
|
1782
|
+
function TurtleHooksProvider({
|
|
1783
1783
|
children,
|
|
1784
1784
|
apiUrl,
|
|
1785
1785
|
earnUrl,
|
|
@@ -1812,7 +1812,7 @@ var queries = mergeQueryKeys(
|
|
|
1812
1812
|
export {
|
|
1813
1813
|
ApiError,
|
|
1814
1814
|
BalanceSourcePriority,
|
|
1815
|
-
|
|
1815
|
+
TurtleHooksProvider,
|
|
1816
1816
|
apiClient,
|
|
1817
1817
|
approveStep,
|
|
1818
1818
|
asset,
|