@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.cjs
CHANGED
|
@@ -22,7 +22,7 @@ var index_exports = {};
|
|
|
22
22
|
__export(index_exports, {
|
|
23
23
|
ApiError: () => ApiError,
|
|
24
24
|
BalanceSourcePriority: () => BalanceSourcePriority,
|
|
25
|
-
|
|
25
|
+
TurtleHooksProvider: () => TurtleHooksProvider,
|
|
26
26
|
apiClient: () => apiClient,
|
|
27
27
|
approveStep: () => approveStep,
|
|
28
28
|
asset: () => asset,
|
|
@@ -814,7 +814,7 @@ async function getProducts(filters) {
|
|
|
814
814
|
const params = new URLSearchParams();
|
|
815
815
|
if (filters?.organizationId) params.append("organizationId", filters.organizationId);
|
|
816
816
|
const queryString = params.toString();
|
|
817
|
-
const endpoint = `/
|
|
817
|
+
const endpoint = `/turtle/products${queryString ? `?${queryString}` : ""}`;
|
|
818
818
|
const data = await apiClient.fetch(endpoint, {
|
|
819
819
|
method: "GET"
|
|
820
820
|
});
|
|
@@ -826,7 +826,7 @@ async function getProducts(filters) {
|
|
|
826
826
|
return result.data;
|
|
827
827
|
}
|
|
828
828
|
async function getProduct(id) {
|
|
829
|
-
const endpoint = `/
|
|
829
|
+
const endpoint = `/turtle/products/${id}`;
|
|
830
830
|
const data = await apiClient.fetch(endpoint, {
|
|
831
831
|
method: "GET"
|
|
832
832
|
});
|
|
@@ -1909,7 +1909,7 @@ function useSwapRoute(isEnabled, userAddress, distributorId, options, referralCo
|
|
|
1909
1909
|
// src/v2/lib/turtle-provider.tsx
|
|
1910
1910
|
var import_react9 = require("react");
|
|
1911
1911
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
1912
|
-
function
|
|
1912
|
+
function TurtleHooksProvider({
|
|
1913
1913
|
children,
|
|
1914
1914
|
apiUrl,
|
|
1915
1915
|
earnUrl,
|
|
@@ -1943,7 +1943,7 @@ var queries = (0, import_query_key_factory12.mergeQueryKeys)(
|
|
|
1943
1943
|
0 && (module.exports = {
|
|
1944
1944
|
ApiError,
|
|
1945
1945
|
BalanceSourcePriority,
|
|
1946
|
-
|
|
1946
|
+
TurtleHooksProvider,
|
|
1947
1947
|
apiClient,
|
|
1948
1948
|
approveStep,
|
|
1949
1949
|
asset,
|