@depict-ai/react-ui 0.0.66 → 0.0.68
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.d.ts +14 -10
- package/dist/main.js +18 -30
- package/dist/module.js +19 -31
- package/dist-server/index.d.ts +1 -1
- package/dist-server/main.js +1 -1
- package/dist-server/module.js +1 -1
- package/package.json +5 -5
package/dist/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { Display } from "@depict-ai/utilishared";
|
|
|
3
3
|
import React, { ReactNode, PropsWithChildren, ReactElement } from "react";
|
|
4
4
|
import { Locale } from "@depict-ai/ui/locales";
|
|
5
5
|
import { CategoryTitle, embedded_num_products } from "@depict-ai/ui";
|
|
6
|
-
export const version = "0.0.
|
|
6
|
+
export const version = "0.0.68";
|
|
7
7
|
interface PLPConfig<T extends Display> {
|
|
8
8
|
/**
|
|
9
9
|
* The product card to use for rendering products.
|
|
@@ -37,7 +37,7 @@ export interface DepictProductCardProps<T extends Display> {
|
|
|
37
37
|
* Depict product card to use for rendering products.
|
|
38
38
|
*/
|
|
39
39
|
export type DepictProductCard<T extends Display> = (props: DepictProductCardProps<T>) => ReactNode;
|
|
40
|
-
type NavigateFunction = (
|
|
40
|
+
type NavigateFunction = (relativeUrl: string) => void;
|
|
41
41
|
type DepictSearchConfig = {
|
|
42
42
|
/**
|
|
43
43
|
* The path to the search page.
|
|
@@ -51,7 +51,7 @@ type DepictSearchConfig = {
|
|
|
51
51
|
*/
|
|
52
52
|
urlParamName?: string;
|
|
53
53
|
/**
|
|
54
|
-
* Whether
|
|
54
|
+
* Whether to enable category suggestions in the search modal and search page.
|
|
55
55
|
* @default false
|
|
56
56
|
*/
|
|
57
57
|
enableCategorySuggestions?: boolean;
|
|
@@ -73,10 +73,14 @@ type DepictBaseConfig = {
|
|
|
73
73
|
*
|
|
74
74
|
* You don't need to provide any in a Next.js context.
|
|
75
75
|
*
|
|
76
|
+
* @param relativeUrl - The relative url to navigate to.
|
|
77
|
+
*
|
|
76
78
|
* @example
|
|
77
|
-
* Here is how you would use it with react-router,
|
|
79
|
+
* Here is how you would use it with react-router, @reach/router, Gatsby or similar.
|
|
78
80
|
* ```tsx
|
|
79
81
|
* import { DepictProvider, Navigation } from "@depict-ai/react-ui";
|
|
82
|
+
* import { useNavigate } from "react-router-dom";
|
|
83
|
+
* // import { navigate } from "gatsby";
|
|
80
84
|
*
|
|
81
85
|
* function Router() {
|
|
82
86
|
* const navigate = useNavigate();
|
|
@@ -84,7 +88,7 @@ type DepictBaseConfig = {
|
|
|
84
88
|
* <DepictProvider
|
|
85
89
|
* merchant="houdini"
|
|
86
90
|
* market="en-de"
|
|
87
|
-
* navigateFunction={
|
|
91
|
+
* navigateFunction={navigate}
|
|
88
92
|
* search={{
|
|
89
93
|
* searchPagePath: "/search",
|
|
90
94
|
* }}
|
|
@@ -97,7 +101,7 @@ type DepictBaseConfig = {
|
|
|
97
101
|
* @example
|
|
98
102
|
* If you're using another library, you can define your own navigate function, that's compatible with the `NavigateFunction` type.
|
|
99
103
|
* ```tsx
|
|
100
|
-
* const navigateFunction = (
|
|
104
|
+
* const navigateFunction = (relativeUrl: string) => {
|
|
101
105
|
* router.push(href);
|
|
102
106
|
* };
|
|
103
107
|
* ```
|
|
@@ -328,10 +332,11 @@ export const TextPlaceholder: React.FC<TextPlaceholderProps>;
|
|
|
328
332
|
interface UseSearchModalParams {
|
|
329
333
|
/**
|
|
330
334
|
* How the modal should be opened.
|
|
335
|
+
* Will default to "centered" if nothing else is specified.
|
|
331
336
|
* - "centered" - The modal will be opened in the center of the screen.
|
|
332
337
|
* - "aligned" - The modal will be opened aligned to the alignerRef element.
|
|
333
338
|
*/
|
|
334
|
-
location
|
|
339
|
+
location?: ModalLocation;
|
|
335
340
|
/**
|
|
336
341
|
* The ref to the element that the modal should be aligned to.
|
|
337
342
|
* This is only used when location is "aligned".
|
|
@@ -390,7 +395,7 @@ interface UseSearchModalReturn {
|
|
|
390
395
|
* ```
|
|
391
396
|
* @returns {JSX.Element}
|
|
392
397
|
*/
|
|
393
|
-
export function useDepictSearchModal(params
|
|
398
|
+
export function useDepictSearchModal(params?: UseSearchModalParams): UseSearchModalReturn;
|
|
394
399
|
interface SearchFieldProps {
|
|
395
400
|
/**
|
|
396
401
|
* A reference to the DOM element that the modal should be aligned to.
|
|
@@ -453,8 +458,7 @@ export const useDepictSearchField: (props: SearchFieldProps) => UseDepictSearchF
|
|
|
453
458
|
* Helper function to navigate to a new page depending on the navigation library used.
|
|
454
459
|
*/
|
|
455
460
|
export const Navigation: {
|
|
456
|
-
nextRouterNavigation: (router: import("next/router").NextRouter) => (
|
|
457
|
-
reactRouterNavigation: (navigateFunction: import("react-router").NavigateFunction) => (href: string) => void;
|
|
461
|
+
nextRouterNavigation: (router: import("next/router").NextRouter) => (relativeUrl: string) => void;
|
|
458
462
|
};
|
|
459
463
|
export { CategoryTitle, embedded_num_products as EmbeddedNumProducts } from "@depict-ai/ui";
|
|
460
464
|
export type { Locale } from "@depict-ai/ui";
|
package/dist/main.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
const process = { env: {} }; // In case that the code using this wasn't built with "node emulation", just make process.env accesses become undefined.
|
|
2
1
|
var $4GYXz$depictaiutilishared = require("@depict-ai/utilishared");
|
|
3
2
|
var $4GYXz$depictaiui = require("@depict-ai/ui");
|
|
4
3
|
var $4GYXz$solidjs = require("solid-js");
|
|
@@ -29,7 +28,7 @@ $parcel$export(module.exports, "Navigation", () => $b742053c966024b4$export$b8a6
|
|
|
29
28
|
/*! Depict.ai search and product listing react SDK wrapper */ // This is where the actual source of your React stuff should live
|
|
30
29
|
// Note, if you add an export here, also add one in src-server/main.ts
|
|
31
30
|
|
|
32
|
-
const $db7b67857900028b$export$83d89fbfd8236492 = "0.0.
|
|
31
|
+
const $db7b67857900028b$export$83d89fbfd8236492 = "0.0.68";
|
|
33
32
|
|
|
34
33
|
|
|
35
34
|
|
|
@@ -175,9 +174,9 @@ async function $b4d0d98857ed9934$export$79c79419c1ef0081({ display: display , co
|
|
|
175
174
|
}
|
|
176
175
|
|
|
177
176
|
|
|
178
|
-
const $bc389476eeb2b615$export$599d4515591ef232 = (
|
|
177
|
+
const $bc389476eeb2b615$export$599d4515591ef232 = (relativeUrl)=>{
|
|
179
178
|
const shallow = (0, $b4d0d98857ed9934$export$92a8f8b3c630fa0d)(location);
|
|
180
|
-
window.next.router.push(
|
|
179
|
+
window.next.router.push(relativeUrl, undefined, {
|
|
181
180
|
shallow: shallow,
|
|
182
181
|
scroll: true
|
|
183
182
|
});
|
|
@@ -196,10 +195,10 @@ function $24b00503eef73528$export$9fac37a9c21c2f3b(props) {
|
|
|
196
195
|
try {
|
|
197
196
|
const { search: search , category: category } = (0, $0b7cd4fb39fc3502$export$8e769ad4338a911e);
|
|
198
197
|
const [get_search_page_path, set_search_page_path] = (0, $0b7cd4fb39fc3502$export$8e769ad4338a911e).search_page_path_;
|
|
199
|
-
set_search_page_path(searchPagePath);
|
|
200
|
-
const on_navigation = typeof window?.next?.router !== "undefined" || navigateFunction ? (
|
|
201
|
-
if (navigateFunction) navigateFunction(
|
|
202
|
-
else (0, $bc389476eeb2b615$export$599d4515591ef232)(
|
|
198
|
+
set_search_page_path($24b00503eef73528$var$ensure_correct_formatting(searchPagePath));
|
|
199
|
+
const on_navigation = typeof window?.next?.router !== "undefined" || navigateFunction ? (new_relative_url)=>{
|
|
200
|
+
if (navigateFunction) navigateFunction(new_relative_url);
|
|
201
|
+
else (0, $bc389476eeb2b615$export$599d4515591ef232)(new_relative_url);
|
|
203
202
|
} : undefined;
|
|
204
203
|
if (!search) (0, $4GYXz$solidjs.createRoot)(()=>(0, $0b7cd4fb39fc3502$export$8e769ad4338a911e).search = new (0, $4GYXz$depictaiui.DepictSearch)({
|
|
205
204
|
search_query_url_param_name: urlParamName,
|
|
@@ -237,6 +236,11 @@ function $24b00503eef73528$export$9fac37a9c21c2f3b(props) {
|
|
|
237
236
|
}
|
|
238
237
|
return (0, $4GYXz$react.createElement)((0, $4GYXz$react.Fragment), null, children);
|
|
239
238
|
}
|
|
239
|
+
function $24b00503eef73528$var$ensure_correct_formatting(path) {
|
|
240
|
+
// Make sure the path starts with a slash as it always will and is_page will fail otherwise
|
|
241
|
+
if (!path.startsWith("/")) return "/" + path;
|
|
242
|
+
return path;
|
|
243
|
+
}
|
|
240
244
|
|
|
241
245
|
|
|
242
246
|
|
|
@@ -413,7 +417,7 @@ const $7c8b440edc188ad5$export$89c6019e4baa40b1 = ({ width: width , height: heig
|
|
|
413
417
|
|
|
414
418
|
|
|
415
419
|
const $ef7db890e488d4f4$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
416
|
-
const { globalState: globalState , location: location , alignerRef: alignerRef } = createOpenModalParams;
|
|
420
|
+
const { globalState: globalState , location: location = "centered" , alignerRef: alignerRef } = createOpenModalParams;
|
|
417
421
|
const openModal = ()=>{
|
|
418
422
|
const headerAligner = alignerRef?.current;
|
|
419
423
|
if (!globalState.search) throw new Error("No active search in the app!");
|
|
@@ -425,7 +429,7 @@ const $ef7db890e488d4f4$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
|
425
429
|
return;
|
|
426
430
|
}
|
|
427
431
|
if (!headerAligner) return;
|
|
428
|
-
const { cleanup: cleanup } = (0, $
|
|
432
|
+
const { cleanup: cleanup } = (0, $4GYXz$depictaiui.connect_query_input_height_to_aligner_height)(headerAligner);
|
|
429
433
|
let dispose_aligner;
|
|
430
434
|
/**
|
|
431
435
|
* Setting position to fixed is important to make the modal work with align_field.
|
|
@@ -450,7 +454,7 @@ const $ef7db890e488d4f4$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
|
450
454
|
};
|
|
451
455
|
|
|
452
456
|
|
|
453
|
-
function $3647cad61d03b89c$export$cc1e9aaf280afdcb(params) {
|
|
457
|
+
function $3647cad61d03b89c$export$cc1e9aaf280afdcb(params = {}) {
|
|
454
458
|
const open = (0, $ef7db890e488d4f4$export$d69d8daa20eae175)({
|
|
455
459
|
globalState: $0b7cd4fb39fc3502$export$8e769ad4338a911e,
|
|
456
460
|
...params
|
|
@@ -489,33 +493,17 @@ const $ca5840628781f899$export$45080d603eda647c = (props)=>{
|
|
|
489
493
|
|
|
490
494
|
|
|
491
495
|
|
|
492
|
-
const $e387bd534de10acd$export$804fac5697cfbe35 = (router)=>(
|
|
496
|
+
const $e387bd534de10acd$export$804fac5697cfbe35 = (router)=>(relativeUrl)=>{
|
|
493
497
|
const shallow = (0, $b4d0d98857ed9934$export$92a8f8b3c630fa0d)(location);
|
|
494
|
-
router.push(
|
|
498
|
+
router.push(relativeUrl, undefined, {
|
|
495
499
|
shallow: shallow,
|
|
496
500
|
scroll: true
|
|
497
501
|
});
|
|
498
502
|
};
|
|
499
503
|
|
|
500
504
|
|
|
501
|
-
/**
|
|
502
|
-
* Helper function that creates a function that can be used as the
|
|
503
|
-
* navigateFunction callback for DepictProvider when using react-router.
|
|
504
|
-
*
|
|
505
|
-
* React-router expect relative URLs, so this function will strip the
|
|
506
|
-
* protocol, hostname and port from the URL.
|
|
507
|
-
*
|
|
508
|
-
* @param navigateFunction what useNavigate() returns
|
|
509
|
-
* @returns a function that can be used as the navigateFunction callback for DepictProvider
|
|
510
|
-
*/ const $201a023b63de7d2f$export$d53481656a62aebe = (navigateFunction)=>(href)=>{
|
|
511
|
-
const url_object = new URL(href);
|
|
512
|
-
return navigateFunction(url_object.pathname + url_object.search + url_object.hash);
|
|
513
|
-
};
|
|
514
|
-
|
|
515
|
-
|
|
516
505
|
const $b742053c966024b4$export$b8a61e5c71402559 = {
|
|
517
|
-
nextRouterNavigation: $e387bd534de10acd$export$804fac5697cfbe35
|
|
518
|
-
reactRouterNavigation: $201a023b63de7d2f$export$d53481656a62aebe
|
|
506
|
+
nextRouterNavigation: $e387bd534de10acd$export$804fac5697cfbe35
|
|
519
507
|
};
|
|
520
508
|
|
|
521
509
|
|
package/dist/module.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
const process = { env: {} }; // In case that the code using this wasn't built with "node emulation", just make process.env accesses become undefined.
|
|
2
1
|
import {dlog as $TZSbU$dlog, catchify as $TZSbU$catchify, observer as $TZSbU$observer, history_replacer as $TZSbU$history_replacer, queueMacroTask as $TZSbU$queueMacroTask, href_change_ipns as $TZSbU$href_change_ipns, ContainedPlaceholderImage as $TZSbU$ContainedPlaceholderImage, Placeholder as $TZSbU$Placeholder} from "@depict-ai/utilishared";
|
|
3
|
-
import {add_to_version_info as $TZSbU$add_to_version_info, CategoryTitle as $43099132aad1ceb6$re_export$CategoryTitle, embedded_num_products as $43099132aad1ceb6$re_export$EmbeddedNumProducts, DepictSearch as $TZSbU$DepictSearch, DepictCategory as $TZSbU$DepictCategory, get_search_query_updating_blocked_signal as $TZSbU$get_search_query_updating_blocked_signal, SearchPage as $TZSbU$SearchPage, CategoryPage as $TZSbU$CategoryPage, BreadCrumbs as $TZSbU$BreadCrumbs, QuickLinks as $TZSbU$QuickLinks, align_field as $TZSbU$align_field, SearchField as $TZSbU$SearchField} from "@depict-ai/ui";
|
|
2
|
+
import {add_to_version_info as $TZSbU$add_to_version_info, CategoryTitle as $43099132aad1ceb6$re_export$CategoryTitle, embedded_num_products as $43099132aad1ceb6$re_export$EmbeddedNumProducts, DepictSearch as $TZSbU$DepictSearch, DepictCategory as $TZSbU$DepictCategory, get_search_query_updating_blocked_signal as $TZSbU$get_search_query_updating_blocked_signal, SearchPage as $TZSbU$SearchPage, CategoryPage as $TZSbU$CategoryPage, BreadCrumbs as $TZSbU$BreadCrumbs, QuickLinks as $TZSbU$QuickLinks, connect_query_input_height_to_aligner_height as $TZSbU$connect_query_input_height_to_aligner_height, align_field as $TZSbU$align_field, SearchField as $TZSbU$SearchField} from "@depict-ai/ui";
|
|
4
3
|
import {createRoot as $TZSbU$createRoot, untrack as $TZSbU$untrack, createSignal as $TZSbU$createSignal, createComponent as $TZSbU$createComponent, Show as $TZSbU$Show, onCleanup as $TZSbU$onCleanup, createComputed as $TZSbU$createComputed} from "solid-js";
|
|
5
4
|
import {createElement as $TZSbU$createElement, Fragment as $TZSbU$Fragment, useState as $TZSbU$useState, useRef as $TZSbU$useRef, useEffect as $TZSbU$useEffect, forwardRef as $TZSbU$forwardRef} from "react";
|
|
6
5
|
import {en as $TZSbU$en} from "@depict-ai/ui/locales";
|
|
@@ -11,7 +10,7 @@ import {createPortal as $TZSbU$createPortal} from "react-dom";
|
|
|
11
10
|
/*! Depict.ai search and product listing react SDK wrapper */ // This is where the actual source of your React stuff should live
|
|
12
11
|
// Note, if you add an export here, also add one in src-server/main.ts
|
|
13
12
|
|
|
14
|
-
const $c9c4d066f9a5b51b$export$83d89fbfd8236492 = "0.0.
|
|
13
|
+
const $c9c4d066f9a5b51b$export$83d89fbfd8236492 = "0.0.68";
|
|
15
14
|
|
|
16
15
|
|
|
17
16
|
|
|
@@ -157,9 +156,9 @@ async function $c83ba9ab79386687$export$79c79419c1ef0081({ display: display , co
|
|
|
157
156
|
}
|
|
158
157
|
|
|
159
158
|
|
|
160
|
-
const $7216ca4c8308a0f9$export$599d4515591ef232 = (
|
|
159
|
+
const $7216ca4c8308a0f9$export$599d4515591ef232 = (relativeUrl)=>{
|
|
161
160
|
const shallow = (0, $c83ba9ab79386687$export$92a8f8b3c630fa0d)(location);
|
|
162
|
-
window.next.router.push(
|
|
161
|
+
window.next.router.push(relativeUrl, undefined, {
|
|
163
162
|
shallow: shallow,
|
|
164
163
|
scroll: true
|
|
165
164
|
});
|
|
@@ -178,10 +177,10 @@ function $5376eb2a386cd90d$export$9fac37a9c21c2f3b(props) {
|
|
|
178
177
|
try {
|
|
179
178
|
const { search: search , category: category } = (0, $42858f023ef23dab$export$8e769ad4338a911e);
|
|
180
179
|
const [get_search_page_path, set_search_page_path] = (0, $42858f023ef23dab$export$8e769ad4338a911e).search_page_path_;
|
|
181
|
-
set_search_page_path(searchPagePath);
|
|
182
|
-
const on_navigation = typeof window?.next?.router !== "undefined" || navigateFunction ? (
|
|
183
|
-
if (navigateFunction) navigateFunction(
|
|
184
|
-
else (0, $7216ca4c8308a0f9$export$599d4515591ef232)(
|
|
180
|
+
set_search_page_path($5376eb2a386cd90d$var$ensure_correct_formatting(searchPagePath));
|
|
181
|
+
const on_navigation = typeof window?.next?.router !== "undefined" || navigateFunction ? (new_relative_url)=>{
|
|
182
|
+
if (navigateFunction) navigateFunction(new_relative_url);
|
|
183
|
+
else (0, $7216ca4c8308a0f9$export$599d4515591ef232)(new_relative_url);
|
|
185
184
|
} : undefined;
|
|
186
185
|
if (!search) (0, $TZSbU$createRoot)(()=>(0, $42858f023ef23dab$export$8e769ad4338a911e).search = new (0, $TZSbU$DepictSearch)({
|
|
187
186
|
search_query_url_param_name: urlParamName,
|
|
@@ -219,6 +218,11 @@ function $5376eb2a386cd90d$export$9fac37a9c21c2f3b(props) {
|
|
|
219
218
|
}
|
|
220
219
|
return (0, $TZSbU$createElement)((0, $TZSbU$Fragment), null, children);
|
|
221
220
|
}
|
|
221
|
+
function $5376eb2a386cd90d$var$ensure_correct_formatting(path) {
|
|
222
|
+
// Make sure the path starts with a slash as it always will and is_page will fail otherwise
|
|
223
|
+
if (!path.startsWith("/")) return "/" + path;
|
|
224
|
+
return path;
|
|
225
|
+
}
|
|
222
226
|
|
|
223
227
|
|
|
224
228
|
|
|
@@ -395,7 +399,7 @@ const $cbd250061abf11cb$export$89c6019e4baa40b1 = ({ width: width , height: heig
|
|
|
395
399
|
|
|
396
400
|
|
|
397
401
|
const $5e26376d86621891$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
398
|
-
const { globalState: globalState , location: location , alignerRef: alignerRef } = createOpenModalParams;
|
|
402
|
+
const { globalState: globalState , location: location = "centered" , alignerRef: alignerRef } = createOpenModalParams;
|
|
399
403
|
const openModal = ()=>{
|
|
400
404
|
const headerAligner = alignerRef?.current;
|
|
401
405
|
if (!globalState.search) throw new Error("No active search in the app!");
|
|
@@ -407,7 +411,7 @@ const $5e26376d86621891$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
|
407
411
|
return;
|
|
408
412
|
}
|
|
409
413
|
if (!headerAligner) return;
|
|
410
|
-
const { cleanup: cleanup } = (0, $
|
|
414
|
+
const { cleanup: cleanup } = (0, $TZSbU$connect_query_input_height_to_aligner_height)(headerAligner);
|
|
411
415
|
let dispose_aligner;
|
|
412
416
|
/**
|
|
413
417
|
* Setting position to fixed is important to make the modal work with align_field.
|
|
@@ -432,7 +436,7 @@ const $5e26376d86621891$export$d69d8daa20eae175 = (createOpenModalParams)=>{
|
|
|
432
436
|
};
|
|
433
437
|
|
|
434
438
|
|
|
435
|
-
function $cfa72c75e6cf6901$export$cc1e9aaf280afdcb(params) {
|
|
439
|
+
function $cfa72c75e6cf6901$export$cc1e9aaf280afdcb(params = {}) {
|
|
436
440
|
const open = (0, $5e26376d86621891$export$d69d8daa20eae175)({
|
|
437
441
|
globalState: $42858f023ef23dab$export$8e769ad4338a911e,
|
|
438
442
|
...params
|
|
@@ -471,33 +475,17 @@ const $e3ccaca62718bae4$export$45080d603eda647c = (props)=>{
|
|
|
471
475
|
|
|
472
476
|
|
|
473
477
|
|
|
474
|
-
const $a92aa2beb560b8af$export$804fac5697cfbe35 = (router)=>(
|
|
478
|
+
const $a92aa2beb560b8af$export$804fac5697cfbe35 = (router)=>(relativeUrl)=>{
|
|
475
479
|
const shallow = (0, $c83ba9ab79386687$export$92a8f8b3c630fa0d)(location);
|
|
476
|
-
router.push(
|
|
480
|
+
router.push(relativeUrl, undefined, {
|
|
477
481
|
shallow: shallow,
|
|
478
482
|
scroll: true
|
|
479
483
|
});
|
|
480
484
|
};
|
|
481
485
|
|
|
482
486
|
|
|
483
|
-
/**
|
|
484
|
-
* Helper function that creates a function that can be used as the
|
|
485
|
-
* navigateFunction callback for DepictProvider when using react-router.
|
|
486
|
-
*
|
|
487
|
-
* React-router expect relative URLs, so this function will strip the
|
|
488
|
-
* protocol, hostname and port from the URL.
|
|
489
|
-
*
|
|
490
|
-
* @param navigateFunction what useNavigate() returns
|
|
491
|
-
* @returns a function that can be used as the navigateFunction callback for DepictProvider
|
|
492
|
-
*/ const $01e1970add53d62a$export$d53481656a62aebe = (navigateFunction)=>(href)=>{
|
|
493
|
-
const url_object = new URL(href);
|
|
494
|
-
return navigateFunction(url_object.pathname + url_object.search + url_object.hash);
|
|
495
|
-
};
|
|
496
|
-
|
|
497
|
-
|
|
498
487
|
const $97603d19204ec48d$export$b8a61e5c71402559 = {
|
|
499
|
-
nextRouterNavigation: $a92aa2beb560b8af$export$804fac5697cfbe35
|
|
500
|
-
reactRouterNavigation: $01e1970add53d62a$export$d53481656a62aebe
|
|
488
|
+
nextRouterNavigation: $a92aa2beb560b8af$export$804fac5697cfbe35
|
|
501
489
|
};
|
|
502
490
|
|
|
503
491
|
|
package/dist-server/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ interface UseDepictSearchFieldReturn {
|
|
|
9
9
|
*/
|
|
10
10
|
DepictSearchField: () => ReactElement;
|
|
11
11
|
}
|
|
12
|
-
export const version = "0.0.
|
|
12
|
+
export const version = "0.0.68";
|
|
13
13
|
export function DepictProvider(props: any): any;
|
|
14
14
|
export function DepictSearchPage(): any;
|
|
15
15
|
export function DepictCategoryPage(): any;
|
package/dist-server/main.js
CHANGED
|
@@ -19,7 +19,7 @@ $parcel$export(module.exports, "useDepictSearchModal", () => $41e7e5d85b5e0d49$e
|
|
|
19
19
|
$parcel$export(module.exports, "version", () => $db7b67857900028b$export$83d89fbfd8236492);
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
const $db7b67857900028b$export$83d89fbfd8236492 = "0.0.
|
|
22
|
+
const $db7b67857900028b$export$83d89fbfd8236492 = "0.0.68";
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
function $41e7e5d85b5e0d49$export$9fac37a9c21c2f3b(props) {
|
package/dist-server/module.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@depict-ai/react-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.68",
|
|
4
4
|
"packageManager": "yarn@3.2.2",
|
|
5
5
|
"source": "src/index.ts",
|
|
6
6
|
"main": "dist/main.js",
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
},
|
|
13
13
|
"scripts": {
|
|
14
14
|
"clear-dist": "rm -r -f ./dist",
|
|
15
|
-
"build": "node ./build-scripts/pre_build.js && yarn build-server && parcel build --no-source-maps && yarn ignore-optional && cp -a src/styles/plp-styling/. dist/styles/
|
|
15
|
+
"build": "node ./build-scripts/pre_build.js && yarn build-server && parcel build --no-source-maps && yarn ignore-optional && cp -a src/styles/plp-styling/. dist/styles/",
|
|
16
16
|
"build-server": "yarn clear-dist && parcel build --no-source-maps ./src-server/index.ts && cp -r ./dist/ ./dist-server && yarn clear-dist",
|
|
17
17
|
"ignore-optional": "node build-scripts/ignore-optional.js",
|
|
18
18
|
"print-included-package-files": "yarn pack --dry-run",
|
|
@@ -90,8 +90,8 @@
|
|
|
90
90
|
"/locales"
|
|
91
91
|
],
|
|
92
92
|
"dependencies": {
|
|
93
|
-
"@depict-ai/ui": "^0.0.
|
|
94
|
-
"@depict-ai/utilishared": "^0.0.
|
|
93
|
+
"@depict-ai/ui": "^0.0.45",
|
|
94
|
+
"@depict-ai/utilishared": "^0.0.43",
|
|
95
95
|
"solid-js": "^1.6.2"
|
|
96
96
|
},
|
|
97
97
|
"peerDependencies": {
|
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
"@babel/preset-typescript": "latest",
|
|
105
105
|
"@babel/runtime": "latest",
|
|
106
106
|
"@babel/runtime-corejs3": "latest",
|
|
107
|
-
"@depict-ai/plp-styling": "^0.0.
|
|
107
|
+
"@depict-ai/plp-styling": "^0.0.8",
|
|
108
108
|
"@jest/globals": "^29.3.1",
|
|
109
109
|
"@parcel/babel-preset-env": "latest",
|
|
110
110
|
"@parcel/resolver-default": "^2.8.0",
|