@tapcart/mobile-components 0.6.14 → 0.6.16

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.
Files changed (28) hide show
  1. package/dist/components/hooks/use-reviews.d.ts +21 -0
  2. package/dist/components/hooks/use-reviews.d.ts.map +1 -0
  3. package/dist/components/hooks/use-reviews.js +45 -0
  4. package/dist/components/hooks/use-sort-filter.d.ts +3 -1
  5. package/dist/components/hooks/use-sort-filter.d.ts.map +1 -1
  6. package/dist/components/hooks/use-sort-filter.js +25 -5
  7. package/dist/components/hooks/use-tap.d.ts +13 -0
  8. package/dist/components/hooks/use-tap.d.ts.map +1 -0
  9. package/dist/components/hooks/use-tap.js +21 -0
  10. package/dist/components/libs/sort-filter/algolia-search.d.ts +4 -0
  11. package/dist/components/libs/sort-filter/algolia-search.d.ts.map +1 -0
  12. package/dist/components/libs/sort-filter/algolia-search.js +3 -0
  13. package/dist/components/libs/sort-filter/beyond-search.d.ts.map +1 -1
  14. package/dist/components/libs/sort-filter/fast-simon-search.d.ts +4 -0
  15. package/dist/components/libs/sort-filter/fast-simon-search.d.ts.map +1 -0
  16. package/dist/components/libs/sort-filter/fast-simon-search.js +3 -0
  17. package/dist/components/libs/sort-filter/nosto-search.d.ts.map +1 -1
  18. package/dist/components/libs/sort-filter/search-integration.d.ts.map +1 -1
  19. package/dist/components/libs/sort-filter/search-integration.js +11 -6
  20. package/dist/components/ui/accordion.d.ts.map +1 -1
  21. package/dist/components/ui/accordion.js +1 -1
  22. package/dist/components/ui/carousel.d.ts.map +1 -1
  23. package/dist/components/ui/carousel.js +7 -7
  24. package/dist/components/ui/favorite.d.ts.map +1 -1
  25. package/dist/components/ui/favorite.js +1 -1
  26. package/dist/components/ui/grid.js +1 -1
  27. package/dist/styles.css +61 -15
  28. package/package.json +16 -16
@@ -0,0 +1,21 @@
1
+ import { ReviewData } from "app-studio-types";
2
+ type UseReviewsProps = {
3
+ baseURL: string;
4
+ productId: string;
5
+ provider: string;
6
+ fetcher?: (url: string) => Promise<any>;
7
+ dataType: "summary" | "metadata" | "search";
8
+ searchText: string;
9
+ ratings: [number];
10
+ topics: [string];
11
+ sortBy: "date" | "votes_up" | "votes_down" | "time" | "rating" | "reviewer_type";
12
+ ascending: boolean;
13
+ };
14
+ type UseReviewsReturn = {
15
+ reviews: ReviewData;
16
+ error: any;
17
+ isLoading: boolean;
18
+ };
19
+ export declare function useReviews(props: UseReviewsProps | null): UseReviewsReturn;
20
+ export {};
21
+ //# sourceMappingURL=use-reviews.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-reviews.d.ts","sourceRoot":"","sources":["../../../components/hooks/use-reviews.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAG7C,KAAK,eAAe,GAAG;IACrB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IACxC,QAAQ,EAAE,SAAS,GAAG,UAAU,GAAG,QAAQ,CAAC;IAC5C,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,CAAC,MAAM,CAAC,CAAC;IAClB,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC;IACjB,MAAM,EAAE,MAAM,GAAG,UAAU,GAAG,YAAY,GAAG,MAAM,GAAG,QAAQ,GAAG,eAAe,CAAC;IACjF,SAAS,EAAE,OAAO,CAAC;CACpB,CAAA;AAQD,KAAK,gBAAgB,GAAG;IACtB,OAAO,EAAE,UAAU,CAAA;IACnB,KAAK,EAAE,GAAG,CAAA;IACV,SAAS,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,IAAI,GAAG,gBAAgB,CAqD1E"}
@@ -0,0 +1,45 @@
1
+ import useSWR from "swr";
2
+ export function useReviews(props) {
3
+ let url = null;
4
+ if (props) {
5
+ const { baseURL, productId, provider, dataType, searchText, ratings, topics, sortBy, ascending } = props; // Destructure all relevant props
6
+ let queryParams = new URLSearchParams();
7
+ if (productId.length > 0) {
8
+ queryParams.set("id", productId);
9
+ }
10
+ if (provider.length > 0) {
11
+ queryParams.set("provider", provider);
12
+ }
13
+ // Include dataType in the query parameters
14
+ queryParams.set("dataType", dataType);
15
+ // Add additional properties to query parameters
16
+ if (searchText) {
17
+ queryParams.set("searchText", searchText);
18
+ }
19
+ if (ratings && ratings.length > 0) {
20
+ queryParams.set("ratings", ratings.join(",")); // Convert array to a comma-separated string
21
+ }
22
+ if (topics && topics.length > 0) {
23
+ queryParams.set("topics", topics.join(",")); // Convert array to a comma-separated string
24
+ }
25
+ if (sortBy) {
26
+ queryParams.set("sortBy", sortBy);
27
+ }
28
+ if (ascending !== undefined) { // Check for undefined to allow false values
29
+ queryParams.set("ascending", ascending.toString());
30
+ }
31
+ if (dataType === null || productId === null || productId.length === 0) {
32
+ url = null;
33
+ }
34
+ else {
35
+ url = `${baseURL}/reviews/by-id?${queryParams.toString()}`;
36
+ }
37
+ }
38
+ const fetcher = (props === null || props === void 0 ? void 0 : props.fetcher) || ((url) => fetch(url).then((res) => res.json()));
39
+ const { data, error } = useSWR(url, fetcher);
40
+ return {
41
+ reviews: data || {},
42
+ error,
43
+ isLoading: !data && !error,
44
+ };
45
+ }
@@ -3,6 +3,7 @@ import { FilterCategory, FiltersAndRelatedCategories, Integration, IntegrationSo
3
3
  interface UseSortFilterProps {
4
4
  initialData: PageData;
5
5
  queryVariables: Record<string, any>;
6
+ dynamicKey?: (queryVariables: any) => () => any;
6
7
  }
7
8
  interface PageData {
8
9
  filtersURL: string;
@@ -14,6 +15,7 @@ interface UseSortFilterReturn {
14
15
  data: any[];
15
16
  mutate: () => Promise<any>;
16
17
  isLoading: boolean;
18
+ isFilterLoading: boolean;
17
19
  }
18
20
  interface SortFilterData {
19
21
  collection: Collection;
@@ -22,6 +24,6 @@ interface SortFilterData {
22
24
  dynamicFiltersEnabled: boolean;
23
25
  integrations: Integration[];
24
26
  }
25
- declare const useSortFilter: ({ initialData, queryVariables, }: UseSortFilterProps) => UseSortFilterReturn;
27
+ declare const useSortFilter: ({ initialData, queryVariables, dynamicKey, }: UseSortFilterProps) => UseSortFilterReturn;
26
28
  export { useSortFilter };
27
29
  //# sourceMappingURL=use-sort-filter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"use-sort-filter.d.ts","sourceRoot":"","sources":["../../../components/hooks/use-sort-filter.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAE7C,OAAO,EACL,cAAc,EACd,2BAA2B,EAC3B,WAAW,EACX,mBAAmB,EACpB,MAAM,wCAAwC,CAAA;AAG/C,UAAU,kBAAkB;IAC1B,WAAW,EAAE,QAAQ,CAAA;IACrB,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;CACpC;AAED,UAAU,QAAQ;IAChB,UAAU,EAAE,MAAM,CAAA;IAClB,aAAa,EAAE,MAAM,CAAA;IACrB,aAAa,EAAE,cAAc,EAAE,CAAA;CAChC;AAED,UAAU,mBAAmB;IAC3B,cAAc,EAAE,cAAc,CAAC;IAC/B,IAAI,EAAE,GAAG,EAAE,CAAC;IACZ,MAAM,EAAE,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC;IAC3B,SAAS,EAAE,OAAO,CAAC;CACpB;AAED,UAAU,cAAc;IACtB,UAAU,EAAE,UAAU,CAAA;IACtB,2BAA2B,EAAE,2BAA2B,CAAA;IACxD,WAAW,EAAE,mBAAmB,EAAE,CAAA;IAClC,qBAAqB,EAAE,OAAO,CAAA;IAC9B,YAAY,EAAE,WAAW,EAAE,CAAA;CAC5B;AAaD,QAAA,MAAM,aAAa,qCAGhB,kBAAkB,KAAG,mBA8BvB,CAAA;AAED,OAAO,EAAE,aAAa,EAAE,CAAA"}
1
+ {"version":3,"file":"use-sort-filter.d.ts","sourceRoot":"","sources":["../../../components/hooks/use-sort-filter.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAE7C,OAAO,EACL,cAAc,EACd,2BAA2B,EAC3B,WAAW,EACX,mBAAmB,EACpB,MAAM,wCAAwC,CAAA;AAI/C,UAAU,kBAAkB;IAC1B,WAAW,EAAE,QAAQ,CAAA;IACrB,cAAc,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACnC,UAAU,CAAC,EAAE,CAAC,cAAc,EAAE,GAAG,KAAK,MAAM,GAAG,CAAA;CAChD;AAED,UAAU,QAAQ;IAChB,UAAU,EAAE,MAAM,CAAA;IAClB,aAAa,EAAE,MAAM,CAAA;IACrB,aAAa,EAAE,cAAc,EAAE,CAAA;CAChC;AAED,UAAU,mBAAmB;IAC3B,cAAc,EAAE,cAAc,CAAA;IAC9B,IAAI,EAAE,GAAG,EAAE,CAAA;IACX,MAAM,EAAE,MAAM,OAAO,CAAC,GAAG,CAAC,CAAA;IAC1B,SAAS,EAAE,OAAO,CAAA;IAClB,eAAe,EAAE,OAAO,CAAA;CACzB;AAED,UAAU,cAAc;IACtB,UAAU,EAAE,UAAU,CAAA;IACtB,2BAA2B,EAAE,2BAA2B,CAAA;IACxD,WAAW,EAAE,mBAAmB,EAAE,CAAA;IAClC,qBAAqB,EAAE,OAAO,CAAA;IAC9B,YAAY,EAAE,WAAW,EAAE,CAAA;CAC5B;AAeD,QAAA,MAAM,aAAa,iDAIhB,kBAAkB,KAAG,mBAgDvB,CAAA;AAED,OAAO,EAAE,aAAa,EAAE,CAAA"}
@@ -1,6 +1,7 @@
1
1
  "use client";
2
2
  import useSWRInfinite from "swr/infinite";
3
3
  import useSWR from "swr";
4
+ import { useCallback, useMemo } from "react";
4
5
  const constructURL = (apiURL) => {
5
6
  const url = new URL(apiURL);
6
7
  return url.toString();
@@ -8,17 +9,35 @@ const constructURL = (apiURL) => {
8
9
  const fetcher = ({ apiURL, body }) => fetch(constructURL(apiURL), {
9
10
  method: "POST",
10
11
  body: JSON.stringify(body),
11
- }).then((res) => res.json());
12
- const useSortFilter = ({ initialData, queryVariables, }) => {
12
+ })
13
+ .then((res) => res.json())
14
+ .catch((error) => console.error(error));
15
+ const useSortFilter = ({ initialData, queryVariables, dynamicKey, }) => {
13
16
  const shouldFetch = queryVariables && Object.keys(queryVariables).length > 0;
14
- const { data: sortFilterData, isLoading } = useSWR(shouldFetch ? { apiUrl: initialData.sortFilterURL, body: Object.assign({}, queryVariables) } : null, ({ apiUrl, body }) => fetcher({ apiURL: apiUrl, body }));
17
+ const { data: sortFilterData, isLoading } = useSWR(shouldFetch
18
+ ? { apiUrl: initialData.sortFilterURL, body: Object.assign({}, queryVariables) }
19
+ : null, ({ apiUrl, body }) => fetcher({ apiURL: apiUrl, body }), { revalidateOnFocus: false });
15
20
  const getKey = () => {
16
21
  if (!sortFilterData || !sortFilterData.dynamicFiltersEnabled)
17
22
  return null;
18
- return Object.assign(Object.assign({}, sortFilterData.queryVariables), (initialData.uiFilterState && { filterCategories: initialData.uiFilterState }));
23
+ return Object.assign(Object.assign({}, sortFilterData.queryVariables), (initialData.uiFilterState && {
24
+ filterCategories: initialData.uiFilterState,
25
+ }));
19
26
  };
20
- const { data, mutate } = useSWRInfinite(getKey, (body) => fetcher({ apiURL: initialData.filtersURL, body }), {
27
+ const memoizedDynamicKey = useCallback(() => {
28
+ if (dynamicKey) {
29
+ return dynamicKey(sortFilterData.queryVariables);
30
+ }
31
+ else {
32
+ return null;
33
+ }
34
+ }, [dynamicKey, sortFilterData === null || sortFilterData === void 0 ? void 0 : sortFilterData.queryVariables]);
35
+ const memoizedFetch = useMemo(() => {
36
+ return (body) => fetcher({ apiURL: initialData.filtersURL, body });
37
+ }, [initialData.filtersURL]);
38
+ const { data, mutate, isLoading: isFilterLoading, } = useSWRInfinite(dynamicKey ? memoizedDynamicKey : getKey, memoizedFetch, {
21
39
  revalidateFirstPage: true,
40
+ revalidateOnFocus: false,
22
41
  initialSize: 1,
23
42
  });
24
43
  return {
@@ -26,6 +45,7 @@ const useSortFilter = ({ initialData, queryVariables, }) => {
26
45
  data: data !== null && data !== void 0 ? data : [],
27
46
  mutate,
28
47
  isLoading,
48
+ isFilterLoading,
29
49
  };
30
50
  };
31
51
  export { useSortFilter };
@@ -0,0 +1,13 @@
1
+ import { useDrag } from "@use-gesture/react";
2
+ interface UseTapOptions {
3
+ onTap?: () => void;
4
+ threshold?: number;
5
+ }
6
+ interface UseTapResult {
7
+ isDragging: boolean;
8
+ bind: ReturnType<typeof useDrag>;
9
+ active: boolean;
10
+ }
11
+ export declare function useTap({ onTap, threshold, }?: UseTapOptions): UseTapResult;
12
+ export {};
13
+ //# sourceMappingURL=use-tap.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-tap.d.ts","sourceRoot":"","sources":["../../../components/hooks/use-tap.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AAE5C,UAAU,aAAa;IACrB,KAAK,CAAC,EAAE,MAAM,IAAI,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,UAAU,YAAY;IACpB,UAAU,EAAE,OAAO,CAAA;IACnB,IAAI,EAAE,UAAU,CAAC,OAAO,OAAO,CAAC,CAAA;IAChC,MAAM,EAAE,OAAO,CAAA;CAChB;AAED,wBAAgB,MAAM,CAAC,EACrB,KAAK,EACL,SAAa,GACd,GAAE,aAAkB,GAAG,YAAY,CAsBnC"}
@@ -0,0 +1,21 @@
1
+ "use client";
2
+ import { useState } from "react";
3
+ import { useDrag } from "@use-gesture/react";
4
+ export function useTap({ onTap, threshold = 5, } = {}) {
5
+ const [isDragging, setIsDragging] = useState(false);
6
+ const [active, setActive] = useState(false);
7
+ const bind = useDrag(({ tap, dragging, last, active }) => {
8
+ console.log({ tap, dragging, last, active });
9
+ if (tap) {
10
+ onTap === null || onTap === void 0 ? void 0 : onTap();
11
+ }
12
+ setIsDragging(dragging !== null && dragging !== void 0 ? dragging : false);
13
+ setActive(active !== null && active !== void 0 ? active : false);
14
+ }, {
15
+ delay: 0,
16
+ filterTaps: true,
17
+ threshold,
18
+ tapsThreshold: 1,
19
+ });
20
+ return { isDragging, bind, active };
21
+ }
@@ -0,0 +1,4 @@
1
+ import { KMP } from "./kmp";
2
+ export declare class AlgoliaSearch extends KMP {
3
+ }
4
+ //# sourceMappingURL=algolia-search.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"algolia-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/algolia-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAA;AAE3B,qBAAa,aAAc,SAAQ,GAAG;CAAG"}
@@ -0,0 +1,3 @@
1
+ import { KMP } from "./kmp";
2
+ export class AlgoliaSearch extends KMP {
3
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"beyond-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/beyond-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,cAAc,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AACrG,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AAEzD,qBAAa,YAAa,YAAW,iBAAiB;IAEpD,qBAAqB,QAAO,MAAM,CAEjC;IAED,qCAAqC,YAC1B,cAAc,EAAE,gBACX,uBAAuB,KACpC,MAAM,CAoDR;IAED,yBAAyB,CAAC,EACxB,UAAU,EACV,cAAc,GACf,EAAE;QACD,UAAU,EAAE,mBAAmB,GAAG,SAAS,CAAA;QAC3C,cAAc,EAAE,uBAAuB,CAAA;KACxC,GAAG,eAAe;IAcnB,6BAA6B,CAAC,EAC5B,YAAY,EACZ,WAAW,GACZ,EAAE;QACD,YAAY,EAAE,uBAAuB,CAAA;QACrC,WAAW,EAAE,mBAAmB,EAAE,CAAA;KACnC,GAAG,mBAAmB,GAAG,IAAI;CAI/B"}
1
+ {"version":3,"file":"beyond-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/beyond-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,cAAc,EACd,mBAAmB,EACnB,iBAAiB,EAClB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AAEzD,qBAAa,YAAa,YAAW,iBAAiB;IACpD,qBAAqB,QAAO,MAAM,CAEjC;IAED,qCAAqC,YAC1B,cAAc,EAAE,gBACX,uBAAuB,KACpC,MAAM,CAoDR;IAED,yBAAyB,CAAC,EACxB,UAAU,EACV,cAAc,GACf,EAAE;QACD,UAAU,EAAE,mBAAmB,GAAG,SAAS,CAAA;QAC3C,cAAc,EAAE,uBAAuB,CAAA;KACxC,GAAG,eAAe;IAcnB,6BAA6B,CAAC,EAC5B,YAAY,EACZ,WAAW,GACZ,EAAE;QACD,YAAY,EAAE,uBAAuB,CAAA;QACrC,WAAW,EAAE,mBAAmB,EAAE,CAAA;KACnC,GAAG,mBAAmB,GAAG,IAAI;CAI/B"}
@@ -0,0 +1,4 @@
1
+ import { KMP } from "./kmp";
2
+ export declare class FastSimonSearch extends KMP {
3
+ }
4
+ //# sourceMappingURL=fast-simon-search.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fast-simon-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/fast-simon-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAA;AAE3B,qBAAa,eAAgB,SAAQ,GAAG;CAAG"}
@@ -0,0 +1,3 @@
1
+ import { KMP } from "./kmp";
2
+ export class FastSimonSearch extends KMP {
3
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"nosto-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/nosto-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,qBAAa,WAAY,SAAQ,GAAG;IAClC,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAS;gBAE3B,EAAE,WAAW,EAAE,EAAE;QAAE,WAAW,EAAE,WAAW,GAAG,SAAS,CAAA;KAAE;CAItE"}
1
+ {"version":3,"file":"nosto-search.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/nosto-search.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAA;AAC3B,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAA;AAElD,qBAAa,WAAY,SAAQ,GAAG;IAClC,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAS;gBAE3B,EAAE,WAAW,EAAE,EAAE;QAAE,WAAW,EAAE,WAAW,GAAG,SAAS,CAAA;KAAE;CAItE"}
@@ -1 +1 @@
1
- {"version":3,"file":"search-integration.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/search-integration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AAOzD,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,OAAO,CAAA;IAChB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,MAAM,GAAG;IACnB,KAA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AAE,uBAAuB,CAAA;KACxC,GAAG,eAAe,CAAA;IAKnB,qCAAqC,CACnC,OAAO,EAAE,cAAc,EAAE,EACzB,YAAY,EAAE,uBAAuB,GACpC,MAAM,CAAA;CACV;AAED,eAAO,MAAM,uBAAuB,iBAAkB,WAAW,EAAE,gCAKlE,CAAA;AAED,eAAO,MAAM,gBAAgB,sBACR,OAAO,MAAM,EAAE,WAAW,CAAC,0BACtB,MAAM,EAAE,KAC/B,OAEF,CAAA;AAED,eAAO,MAAM,yBAAyB,iBACtB,WAAW,EAAE,KAC1B,iBA2BF,CAAA;AAED,eAAO,MAAM,yBAAyB,sBACjB,iBAAiB,GAAG,IAAI,YACc,CAAA"}
1
+ {"version":3,"file":"search-integration.d.ts","sourceRoot":"","sources":["../../../../components/libs/sort-filter/search-integration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AASzD,MAAM,MAAM,WAAW,GAAG;IACxB,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,OAAO,CAAA;IAChB,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG;IAChC,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,MAAM,GAAG;IACnB,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACrB,GAAG,EAAE,GAAG,CAAA;IACR,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACtB,UAAU,EAAE,OAAO,CAAA;IACnB,YAAY,CAAC,EAAE,MAAM,GA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O,MAAM,gBAAgB,sBACR,OAAO,MAAM,EAAE,WAAW,CAAC,0BACtB,MAAM,EAAE,KAC/B,OAEF,CAAA;AAGD,eAAO,MAAM,yBAAyB,iBACtB,WAAW,EAAE,KAC1B,iBA6BF,CAAA;AAED,eAAO,MAAM,yBAAyB,sBACjB,iBAAiB,GAAG,IAAI,YAKC,CAAA"}
@@ -3,6 +3,8 @@ import { BeyondSearch } from "./beyond-search";
3
3
  import { SearchSpring } from "./search-spring";
4
4
  import { NostoSearch } from "./nosto-search";
5
5
  import { ShopifySearchAndDiscovery } from "./shopify-search-and-discovery";
6
+ import { AlgoliaSearch } from "./algolia-search";
7
+ import { FastSimonSearch } from "./fast-simon-search";
6
8
  export const createIntegrationLookup = (integrations) => {
7
9
  return integrations.reduce((lookup, integration) => {
8
10
  lookup[integration.name] = integration;
@@ -25,14 +27,17 @@ export const searchIntegrationProvider = (integrations) => {
25
27
  return new NostoSearch({
26
28
  integration: integrationLookup["nosto-search"],
27
29
  });
28
- case isSearchProvider(integrationLookup, [
29
- "algolia",
30
- "instant-search-plus",
31
- "searchanise",
32
- ]):
30
+ case isSearchProvider(integrationLookup, ["algolia"]):
31
+ return new AlgoliaSearch();
32
+ case isSearchProvider(integrationLookup, ["instant-search-plus"]):
33
+ return new FastSimonSearch();
34
+ case isSearchProvider(integrationLookup, ["searchanise"]):
33
35
  return new KMP();
34
36
  default:
35
37
  return new ShopifySearchAndDiscovery();
36
38
  }
37
39
  };
38
- export const isDynamicFiltersSupported = (searchIntegration) => searchIntegration instanceof ShopifySearchAndDiscovery;
40
+ export const isDynamicFiltersSupported = (searchIntegration) => searchIntegration instanceof ShopifySearchAndDiscovery ||
41
+ searchIntegration instanceof BeyondSearch ||
42
+ searchIntegration instanceof NostoSearch ||
43
+ searchIntegration instanceof FastSimonSearch;
@@ -1 +1 @@
1
- {"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../components/ui/accordion.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAK/D,QAAA,MAAM,SAAS,8JAA0B,CAAA;AAEzC,QAAA,MAAM,aAAa,iKASjB,CAAA;AAGF,QAAA,MAAM,gBAAgB;;2CA2BpB,CAAA;AAGF,QAAA,MAAM,gBAAgB,oKAWpB,CAAA;AAIF,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,CAAA"}
1
+ {"version":3,"file":"accordion.d.ts","sourceRoot":"","sources":["../../../components/ui/accordion.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,kBAAkB,MAAM,2BAA2B,CAAA;AAK/D,QAAA,MAAM,SAAS,8JAA0B,CAAA;AAEzC,QAAA,MAAM,aAAa,iKASjB,CAAA;AAGF,QAAA,MAAM,gBAAgB;;2CA4BpB,CAAA;AAGF,QAAA,MAAM,gBAAgB,oKAWpB,CAAA;AAIF,OAAO,EAAE,SAAS,EAAE,aAAa,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,CAAA"}
@@ -23,7 +23,7 @@ const AccordionItem = React.forwardRef((_a, ref) => {
23
23
  AccordionItem.displayName = "AccordionItem";
24
24
  const AccordionTrigger = React.forwardRef((_a, ref) => {
25
25
  var { className, children, showDefaultIcon = true } = _a, props = __rest(_a, ["className", "children", "showDefaultIcon"]);
26
- return (_jsx(AccordionPrimitive.Header, Object.assign({ className: "flex" }, { children: _jsxs(AccordionPrimitive.Trigger, Object.assign({ ref: ref, className: cn("px-4 flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]_svg]:rotate-180 active:opacity-70", className) }, props, { children: [children, showDefaultIcon && (_jsx(Icon, { name: "chevron-down", size: "sm", className: "text-coreColors-secondaryIcon shrink-0 transition-transform duration-200" }))] })) })));
26
+ return (_jsx(AccordionPrimitive.Header, Object.assign({ className: "flex" }, { children: _jsxs(AccordionPrimitive.Trigger, Object.assign({ ref: ref, className: cn("px-4 flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline active:opacity-70", { "[&[data-state=open]_svg]:rotate-180": showDefaultIcon }, className) }, props, { children: [children, showDefaultIcon && (_jsx(Icon, { name: "chevron-down", size: "sm", className: "text-coreColors-secondaryIcon shrink-0 transition-transform duration-200" }))] })) })));
27
27
  });
28
28
  AccordionTrigger.displayName = AccordionPrimitive.Trigger.displayName;
29
29
  const AccordionContent = React.forwardRef((_a, ref) => {
@@ -1 +1 @@
1
- {"version":3,"file":"carousel.d.ts","sourceRoot":"","sources":["../../../components/ui/carousel.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,gBAAgB,EAAE,EACvB,KAAK,oBAAoB,EAC1B,MAAM,sBAAsB,CAAA;AAM7B,KAAK,WAAW,GAAG,oBAAoB,CAAC,CAAC,CAAC,CAAA;AAC1C,KAAK,qBAAqB,GAAG,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAA;AAChE,KAAK,eAAe,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAA;AAC/C,KAAK,cAAc,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAA;AAE9C,KAAK,aAAa,GAAG;IACnB,IAAI,CAAC,EAAE,eAAe,CAAA;IACtB,OAAO,CAAC,EAAE,cAAc,CAAA;IACxB,WAAW,CAAC,EAAE,YAAY,GAAG,UAAU,CAAA;IACvC,MAAM,CAAC,EAAE,CAAC,GAAG,EAAE,WAAW,KAAK,IAAI,CAAA;IACnC,YAAY,CAAC,EAAE,CAAC,MAAM,EAAC,KAAK,CAAC,MAAM,CAAC,KAAK,IAAI,CAAA;CAC9C,CAAA;AAuBD,QAAA,MAAM,QAAQ,6HAkHb,CAAA;AAGD,QAAA,MAAM,eAAe,6GAmBnB,CAAA;AAGF,QAAA,MAAM,YAAY,6GAmBhB,CAAA;AAGF,QAAA,MAAM,gB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AAGF,QAAA,MAAM,YAAY,kLA0BhB,CAAA;AAGF,KAAK,iBAAiB,GAAG;IACvB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,QAAA,MAAM,YAAY,iIAiDjB,CAAA;AAGD,OAAO,EACL,KAAK,WAAW,EAChB,QAAQ,EACR,eAAe,EACf,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,YAAY,GACb,CAAA"}
@@ -123,25 +123,25 @@ const CarouselDots = React.forwardRef((_a, ref) => {
123
123
  const toggleUpdateState = React.useCallback(() => setUpdateState((prevState) => !prevState), []);
124
124
  React.useEffect(() => {
125
125
  if (api) {
126
- api.on('select', toggleUpdateState);
127
- api.on('reInit', toggleUpdateState);
126
+ api.on("select", toggleUpdateState);
127
+ api.on("reInit", toggleUpdateState);
128
128
  return () => {
129
- api.off('select', toggleUpdateState);
130
- api.off('reInit', toggleUpdateState);
129
+ api.off("select", toggleUpdateState);
130
+ api.off("reInit", toggleUpdateState);
131
131
  };
132
132
  }
133
133
  }, [api, toggleUpdateState]);
134
134
  const numberOfSlides = Math.min((api === null || api === void 0 ? void 0 : api.scrollSnapList().length) || 0, maxDots);
135
135
  const currentSlide = Math.min((api === null || api === void 0 ? void 0 : api.selectedScrollSnap()) || 0, maxDots - 1);
136
136
  if (numberOfSlides > 1) {
137
- return (_jsx("div", Object.assign({ ref: ref, className: `flex justify-center ${props.className}` }, { children: Array.from({ length: numberOfSlides }, (_, i) => (_jsx(Button, { className: 'mx-1 h-1.5 w-1.5 rounded-full p-0 border-none', style: {
137
+ return (_jsx("div", Object.assign({ ref: ref, className: `flex justify-center ${props.className}` }, { children: Array.from({ length: numberOfSlides }, (_, i) => (_jsx(Button, { className: "mx-1 h-1.5 w-1.5 rounded-full p-0 border-none", style: {
138
138
  backgroundColor: dotColor,
139
- opacity: i === currentSlide ? 1 : 0.5
139
+ opacity: i === currentSlide ? 1 : 0.5,
140
140
  }, "aria-label": `Go to slide ${i + 1}`, onClick: () => api === null || api === void 0 ? void 0 : api.scrollTo(i) }, i))) })));
141
141
  }
142
142
  else {
143
143
  return _jsx(_Fragment, {});
144
144
  }
145
145
  });
146
- CarouselDots.displayName = 'CarouselDots';
146
+ CarouselDots.displayName = "CarouselDots";
147
147
  export { Carousel, CarouselContent, CarouselItem, CarouselPrevious, CarouselNext, CarouselDots, };
@@ -1 +1 @@
1
- {"version":3,"file":"favorite.d.ts","sourceRoot":"","sources":["../../../components/ui/favorite.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAO,KAAK,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAEjE,OAAO,EAA2B,OAAO,EAAmB,MAAM,iBAAiB,CAAA;AAEnF,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA;AAE3C,QAAA,MAAM,gBAAgB;;;;mFA0BrB,CAAA;AAED,MAAM,WAAW,aACf,SAAQ,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EACnD,YAAY,CAAC,OAAO,gBAAgB,CAAC;IACvC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC,UAAU,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAA;IAC9D,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,oBAAoB,CAAC,EAAE,OAAO,CAAA;IAC9B,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,UAAU,CAAC,EACP,sBAAsB,GACtB,WAAW,GACX,UAAU,GACV,aAAa,GACb,cAAc,CAAA;IAClB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,eAAe,CAAC,EAAC,MAAM,CAAA;IACvB,WAAW,CAAC,EAAC,WAAW,CAAA;IACxB,gBAAg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AAED,QAAA,MAAM,QAAQ,yFAuDb,CAAA;AAGD,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,CAAA"}
@@ -44,7 +44,7 @@ const Favorite = React.forwardRef((_a, ref) => {
44
44
  size,
45
45
  showBackgroundShadow,
46
46
  layoutType,
47
- }), className), style: Object.assign(Object.assign({ borderRadius: `${cornerRadius}px`, backgroundColor: backgroundColor || "var(--coreColors-inputBackground)", borderColor: borderColorStyle }, getBorderSidesStyle(borderSides)), getPaddingStyle(borderPadding)) }, props, { children: _jsx(Icon, { url: iconUrl, color: selected ? "stateColors-favorites" : "stateColors-disabled", size: size === "small" ? "xs" : "sm", fillColor: selected ? favoriteFillColor : disabledFillColor }) })));
47
+ }), className), style: Object.assign({}, (showBackground && Object.assign(Object.assign({ borderRadius: `${cornerRadius}px`, backgroundColor: backgroundColor, borderColor: borderColorStyle }, getBorderSidesStyle(borderSides)), getPaddingStyle(borderPadding)))) }, props, { children: _jsx(Icon, { url: iconUrl, color: selected ? "stateColors-favorites" : "stateColors-disabled", size: size === "small" ? "xs" : "sm", fillColor: selected ? favoriteFillColor : disabledFillColor }) })));
48
48
  });
49
49
  Favorite.displayName = "Favorite";
50
50
  export { Favorite, favoriteVariants };
@@ -28,6 +28,6 @@ const gridVariants = cva("grid", {
28
28
  });
29
29
  function Grid(_a) {
30
30
  var { className, columns } = _a, props = __rest(_a, ["className", "columns"]);
31
- return (_jsx(Container, { children: _jsx("div", Object.assign({ className: cn(gridVariants({ columns }), className) }, props)) }));
31
+ return (_jsx(Container, Object.assign({ style: { padding: '0' } }, { children: _jsx("div", Object.assign({ className: cn(gridVariants({ columns }), className) }, props)) })));
32
32
  }
33
33
  export { Grid, gridVariants };
package/dist/styles.css CHANGED
@@ -707,6 +707,9 @@ video {
707
707
  .bottom-6 {
708
708
  bottom: 1.5rem;
709
709
  }
710
+ .bottom-\[110px\] {
711
+ bottom: 110px;
712
+ }
710
713
  .bottom-\[18px\] {
711
714
  bottom: 18px;
712
715
  }
@@ -728,9 +731,15 @@ video {
728
731
  .left-1\/2 {
729
732
  left: 50%;
730
733
  }
734
+ .left-14 {
735
+ left: 3.5rem;
736
+ }
731
737
  .left-2 {
732
738
  left: 0.5rem;
733
739
  }
740
+ .left-24 {
741
+ left: 6rem;
742
+ }
734
743
  .left-4 {
735
744
  left: 1rem;
736
745
  }
@@ -749,6 +758,15 @@ video {
749
758
  .right-4 {
750
759
  right: 1rem;
751
760
  }
761
+ .right-\[100px\] {
762
+ right: 100px;
763
+ }
764
+ .right-\[140px\] {
765
+ right: 140px;
766
+ }
767
+ .right-auto {
768
+ right: auto;
769
+ }
752
770
  .start-10 {
753
771
  inset-inline-start: 2.5rem;
754
772
  }
@@ -770,9 +788,6 @@ video {
770
788
  .top-4 {
771
789
  top: 1rem;
772
790
  }
773
- .top-\[16px\] {
774
- top: 16px;
775
- }
776
791
  .top-\[18px\] {
777
792
  top: 18px;
778
793
  }
@@ -791,6 +806,12 @@ video {
791
806
  .z-\[100\] {
792
807
  z-index: 100;
793
808
  }
809
+ .order-1 {
810
+ order: 1;
811
+ }
812
+ .order-2 {
813
+ order: 2;
814
+ }
794
815
  .col-span-2 {
795
816
  grid-column: span 2 / span 2;
796
817
  }
@@ -841,9 +862,15 @@ video {
841
862
  .-mt-4 {
842
863
  margin-top: -1rem;
843
864
  }
865
+ .mb-1 {
866
+ margin-bottom: 0.25rem;
867
+ }
844
868
  .mb-2 {
845
869
  margin-bottom: 0.5rem;
846
870
  }
871
+ .mb-4 {
872
+ margin-bottom: 1rem;
873
+ }
847
874
  .mb-6 {
848
875
  margin-bottom: 1.5rem;
849
876
  }
@@ -868,6 +895,9 @@ video {
868
895
  .mr-4 {
869
896
  margin-right: 1rem;
870
897
  }
898
+ .mt-0 {
899
+ margin-top: 0px;
900
+ }
871
901
  .mt-1 {
872
902
  margin-top: 0.25rem;
873
903
  }
@@ -877,6 +907,9 @@ video {
877
907
  .mt-3 {
878
908
  margin-top: 0.75rem;
879
909
  }
910
+ .mt-4 {
911
+ margin-top: 1rem;
912
+ }
880
913
  .mt-auto {
881
914
  margin-top: auto;
882
915
  }
@@ -982,6 +1015,9 @@ video {
982
1015
  .h-\[2px\] {
983
1016
  height: 2px;
984
1017
  }
1018
+ .h-\[36\] {
1019
+ height: 36;
1020
+ }
985
1021
  .h-\[42px\] {
986
1022
  height: 42px;
987
1023
  }
@@ -1060,6 +1096,9 @@ video {
1060
1096
  .w-\[140px\] {
1061
1097
  width: 140px;
1062
1098
  }
1099
+ .w-\[154px\] {
1100
+ width: 154px;
1101
+ }
1063
1102
  .w-\[1px\] {
1064
1103
  width: 1px;
1065
1104
  }
@@ -1269,12 +1308,21 @@ video {
1269
1308
  .items-center {
1270
1309
  align-items: center;
1271
1310
  }
1311
+ .\!justify-start {
1312
+ justify-content: flex-start !important;
1313
+ }
1272
1314
  .justify-start {
1273
1315
  justify-content: flex-start;
1274
1316
  }
1317
+ .\!justify-end {
1318
+ justify-content: flex-end !important;
1319
+ }
1275
1320
  .justify-end {
1276
1321
  justify-content: flex-end;
1277
1322
  }
1323
+ .\!justify-center {
1324
+ justify-content: center !important;
1325
+ }
1278
1326
  .justify-center {
1279
1327
  justify-content: center;
1280
1328
  }
@@ -1290,9 +1338,6 @@ video {
1290
1338
  .gap-2 {
1291
1339
  gap: 0.5rem;
1292
1340
  }
1293
- .gap-2\.5 {
1294
- gap: 0.625rem;
1295
- }
1296
1341
  .gap-4 {
1297
1342
  gap: 1rem;
1298
1343
  }
@@ -1338,6 +1383,11 @@ video {
1338
1383
  margin-top: calc(0.5rem * calc(1 - var(--tw-space-y-reverse)));
1339
1384
  margin-bottom: calc(0.5rem * var(--tw-space-y-reverse));
1340
1385
  }
1386
+ .space-y-4 > :not([hidden]) ~ :not([hidden]) {
1387
+ --tw-space-y-reverse: 0;
1388
+ margin-top: calc(1rem * calc(1 - var(--tw-space-y-reverse)));
1389
+ margin-bottom: calc(1rem * var(--tw-space-y-reverse));
1390
+ }
1341
1391
  .self-start {
1342
1392
  align-self: flex-start;
1343
1393
  }
@@ -1513,9 +1563,6 @@ video {
1513
1563
  --tw-bg-opacity: 1;
1514
1564
  background-color: rgb(255 255 255 / var(--tw-bg-opacity));
1515
1565
  }
1516
- .bg-\[rgba\(255\2c 255\2c 255\2c 0\.5\)\] {
1517
- background-color: rgba(255,255,255,0.5);
1518
- }
1519
1566
  .bg-background {
1520
1567
  background-color: hsl(var(--background));
1521
1568
  }
@@ -1605,9 +1652,6 @@ video {
1605
1652
  .p-1 {
1606
1653
  padding: 0.25rem;
1607
1654
  }
1608
- .p-1\.5 {
1609
- padding: 0.375rem;
1610
- }
1611
1655
  .p-2 {
1612
1656
  padding: 0.5rem;
1613
1657
  }
@@ -1696,9 +1740,6 @@ video {
1696
1740
  .pl-2 {
1697
1741
  padding-left: 0.5rem;
1698
1742
  }
1699
- .pl-3 {
1700
- padding-left: 0.75rem;
1701
- }
1702
1743
  .pl-4 {
1703
1744
  padding-left: 1rem;
1704
1745
  }
@@ -2806,6 +2847,11 @@ body::-webkit-scrollbar {
2806
2847
  color: var(--textColors-secondaryColor, #727272ff);
2807
2848
  }
2808
2849
 
2850
+ .\[\&\[data-state\=open\]_\.rightIcon\]\:rotate-90[data-state=open] .rightIcon {
2851
+ --tw-rotate: 90deg;
2852
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
2853
+ }
2854
+
2809
2855
  .\[\&\[data-state\=open\]_svg\]\:rotate-180[data-state=open] svg {
2810
2856
  --tw-rotate: 180deg;
2811
2857
  transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tapcart/mobile-components",
3
- "version": "0.6.14",
3
+ "version": "0.6.16",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "style": "dist/styles.css",
@@ -11,6 +11,16 @@
11
11
  "license": "SEE LICENSE IN LICENSE.md",
12
12
  "author": "Tapcart Inc.",
13
13
  "homepage": "https://tapcart.com",
14
+ "scripts": {
15
+ "lint": "eslint \"**/*.ts*\"",
16
+ "ui:add": "pnpm dlx shadcn-ui@latest add",
17
+ "build:styles": "postcss styles/globals.css -o dist/styles.css",
18
+ "build:ts": "tsc -p tsconfig.json && tsc-alias",
19
+ "build": "pnpm run build:ts && pnpm run build:styles",
20
+ "dev:ts": "tsc -w -p tsconfig.json",
21
+ "dev:styles": "npx tailwindcss -i styles/globals.css -o dist/styles.css --watch",
22
+ "dev": "concurrently \"pnpm run dev:ts\" \"pnpm run dev:styles\""
23
+ },
14
24
  "peerDependencies": {
15
25
  "react": "^17.0.2 || ^18.0.0",
16
26
  "react-dom": "^17.0.2 || ^18.0.0"
@@ -19,17 +29,17 @@
19
29
  "@types/lodash": "4.17.5",
20
30
  "@types/react": "^18.2.0",
21
31
  "@types/react-dom": "^18.2.0",
32
+ "app-studio-types": "workspace:*",
22
33
  "autoprefixer": "^10.4.14",
23
34
  "chokidar-cli": "^3.0.0",
24
35
  "concurrently": "^8.2.2",
25
36
  "eslint": "^7.32.0",
37
+ "eslint-config-custom": "workspace:*",
26
38
  "postcss": "^8.4.24",
27
39
  "tailwindcss": "^3.3.2",
28
40
  "tsc-alias": "^1.8.10",
29
- "typescript": "^4.5.2",
30
- "app-studio-types": "0.0.3",
31
- "eslint-config-custom": "0.0.0",
32
- "tsconfig": "0.0.0"
41
+ "tsconfig": "workspace:*",
42
+ "typescript": "^4.5.2"
33
43
  },
34
44
  "dependencies": {
35
45
  "@radix-ui/react-accordion": "^1.1.2",
@@ -63,15 +73,5 @@
63
73
  "tailwind-merge": "^1.13.2",
64
74
  "tailwindcss-animate": "^1.0.6",
65
75
  "vaul": "^0.9.1"
66
- },
67
- "scripts": {
68
- "lint": "eslint \"**/*.ts*\"",
69
- "ui:add": "pnpm dlx shadcn-ui@latest add",
70
- "build:styles": "postcss styles/globals.css -o dist/styles.css",
71
- "build:ts": "tsc -p tsconfig.json && tsc-alias",
72
- "build": "pnpm run build:ts && pnpm run build:styles",
73
- "dev:ts": "tsc -w -p tsconfig.json",
74
- "dev:styles": "npx tailwindcss -i styles/globals.css -o dist/styles.css --watch",
75
- "dev": "concurrently \"pnpm run dev:ts\" \"pnpm run dev:styles\""
76
76
  }
77
- }
77
+ }