@atomic-solutions/woocommerce-react 0.2.4 → 0.2.6

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.
@@ -1,8 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as react from 'react';
3
3
  import { ReactNode } from 'react';
4
- import { j as StoreConfig, Q as QueryKeys, k as StoreContextValue } from '../types-8KIvr2ze.cjs';
5
- export { D as DEFAULT_STORE_CONFIG, I as ImageUrlTransformer, R as RateLimitConfig, l as StoreFeatures, m as StoreGuardrails, S as StoreLocale, n as StoreTheme, a as StoreValidationResult } from '../types-8KIvr2ze.cjs';
4
+ import { j as StoreConfig, Q as QueryKeys, k as StoreContextValue } from '../types-_8YqnkO-.cjs';
5
+ export { D as DEFAULT_STORE_CONFIG, I as ImageUrlTransformer, R as RateLimitConfig, l as StoreFeatures, m as StoreGuardrails, S as StoreLocale, n as StoreTheme, a as StoreValidationResult } from '../types-_8YqnkO-.cjs';
6
6
  import '@atomic-solutions/woocommerce-api-client';
7
7
 
8
8
  interface WooCommerceStoreProviderProps {
@@ -1,8 +1,8 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import * as react from 'react';
3
3
  import { ReactNode } from 'react';
4
- import { j as StoreConfig, Q as QueryKeys, k as StoreContextValue } from '../types-8KIvr2ze.js';
5
- export { D as DEFAULT_STORE_CONFIG, I as ImageUrlTransformer, R as RateLimitConfig, l as StoreFeatures, m as StoreGuardrails, S as StoreLocale, n as StoreTheme, a as StoreValidationResult } from '../types-8KIvr2ze.js';
4
+ import { j as StoreConfig, Q as QueryKeys, k as StoreContextValue } from '../types-_8YqnkO-.js';
5
+ export { D as DEFAULT_STORE_CONFIG, I as ImageUrlTransformer, R as RateLimitConfig, l as StoreFeatures, m as StoreGuardrails, S as StoreLocale, n as StoreTheme, a as StoreValidationResult } from '../types-_8YqnkO-.js';
6
6
  import '@atomic-solutions/woocommerce-api-client';
7
7
 
8
8
  interface WooCommerceStoreProviderProps {
@@ -39,6 +39,7 @@ type CartShippingSelectedEvent = BaseSuccessEvent<'cart:shipping_selected', {
39
39
  }> | BaseErrorEvent<'cart:shipping_selected'>;
40
40
  type CheckoutProcessedEvent = BaseSuccessEvent<'checkout:processed', {
41
41
  checkout: Checkout;
42
+ cart: Cart | null;
42
43
  }> | BaseErrorEvent<'checkout:processed'>;
43
44
  type OrderFetchedEvent = BaseSuccessEvent<'order:fetched', {
44
45
  order: StoreApiOrder;
@@ -54,38 +55,38 @@ declare const createQueryKeys: (prefix?: string[]) => {
54
55
  list: (params?: ProductParams) => readonly [...string[], "products", "list", {
55
56
  page: number;
56
57
  per_page: number;
57
- type?: "simple" | "grouped" | "external" | "variable" | "variation" | undefined;
58
- status?: "publish" | "draft" | "pending" | "private" | "any" | undefined;
58
+ type?: "variation" | "simple" | "variable" | "grouped" | "external" | undefined;
59
+ status?: "pending" | "any" | "draft" | "private" | "publish" | undefined;
59
60
  order?: "asc" | "desc" | undefined;
60
- orderby?: "date" | "id" | "slug" | "include" | "title" | "popularity" | "rating" | "menu_order" | "price" | "date_modified" | undefined;
61
+ orderby?: "id" | "price" | "date" | "slug" | "menu_order" | "include" | "title" | "popularity" | "rating" | "date_modified" | undefined;
62
+ catalog_visibility?: "search" | "any" | "visible" | "catalog" | "hidden" | undefined;
61
63
  slug?: string | undefined;
62
64
  parent?: number[] | undefined;
63
- search?: string | undefined;
64
- exclude?: number[] | undefined;
65
65
  include?: number[] | undefined;
66
+ rating?: number[] | undefined;
67
+ search?: string | undefined;
66
68
  after?: string | undefined;
67
69
  before?: string | undefined;
68
- rating?: number[] | undefined;
69
70
  modified_after?: string | undefined;
70
71
  modified_before?: string | undefined;
72
+ exclude?: number[] | undefined;
73
+ parent_exclude?: number[] | undefined;
71
74
  featured?: boolean | undefined;
72
- catalog_visibility?: "search" | "any" | "visible" | "catalog" | "hidden" | undefined;
73
75
  stock_status?: ("instock" | "outofstock" | "onbackorder")[] | undefined;
76
+ category?: string | undefined;
77
+ category_operator?: "in" | "not_in" | "and" | undefined;
78
+ tag?: string | undefined;
79
+ tag_operator?: "in" | "not_in" | "and" | undefined;
74
80
  attributes?: {
75
81
  attribute: string;
76
82
  slug?: string[] | undefined;
77
83
  term_id?: number[] | undefined;
78
84
  operator?: "in" | "not_in" | "and" | undefined;
79
85
  }[] | undefined;
80
- on_sale?: boolean | undefined;
81
- category?: string | undefined;
82
- tag?: string | undefined;
86
+ attribute_relation?: "in" | "and" | undefined;
83
87
  min_price?: string | undefined;
84
88
  max_price?: string | undefined;
85
- parent_exclude?: number[] | undefined;
86
- category_operator?: "in" | "not_in" | "and" | undefined;
87
- tag_operator?: "in" | "not_in" | "and" | undefined;
88
- attribute_relation?: "in" | "and" | undefined;
89
+ on_sale?: boolean | undefined;
89
90
  } | undefined];
90
91
  details: () => readonly [...string[], "products", "detail"];
91
92
  detail: (id: number) => readonly [...string[], "products", "detail", number];
@@ -39,6 +39,7 @@ type CartShippingSelectedEvent = BaseSuccessEvent<'cart:shipping_selected', {
39
39
  }> | BaseErrorEvent<'cart:shipping_selected'>;
40
40
  type CheckoutProcessedEvent = BaseSuccessEvent<'checkout:processed', {
41
41
  checkout: Checkout;
42
+ cart: Cart | null;
42
43
  }> | BaseErrorEvent<'checkout:processed'>;
43
44
  type OrderFetchedEvent = BaseSuccessEvent<'order:fetched', {
44
45
  order: StoreApiOrder;
@@ -54,38 +55,38 @@ declare const createQueryKeys: (prefix?: string[]) => {
54
55
  list: (params?: ProductParams) => readonly [...string[], "products", "list", {
55
56
  page: number;
56
57
  per_page: number;
57
- type?: "simple" | "grouped" | "external" | "variable" | "variation" | undefined;
58
- status?: "publish" | "draft" | "pending" | "private" | "any" | undefined;
58
+ type?: "variation" | "simple" | "variable" | "grouped" | "external" | undefined;
59
+ status?: "pending" | "any" | "draft" | "private" | "publish" | undefined;
59
60
  order?: "asc" | "desc" | undefined;
60
- orderby?: "date" | "id" | "slug" | "include" | "title" | "popularity" | "rating" | "menu_order" | "price" | "date_modified" | undefined;
61
+ orderby?: "id" | "price" | "date" | "slug" | "menu_order" | "include" | "title" | "popularity" | "rating" | "date_modified" | undefined;
62
+ catalog_visibility?: "search" | "any" | "visible" | "catalog" | "hidden" | undefined;
61
63
  slug?: string | undefined;
62
64
  parent?: number[] | undefined;
63
- search?: string | undefined;
64
- exclude?: number[] | undefined;
65
65
  include?: number[] | undefined;
66
+ rating?: number[] | undefined;
67
+ search?: string | undefined;
66
68
  after?: string | undefined;
67
69
  before?: string | undefined;
68
- rating?: number[] | undefined;
69
70
  modified_after?: string | undefined;
70
71
  modified_before?: string | undefined;
72
+ exclude?: number[] | undefined;
73
+ parent_exclude?: number[] | undefined;
71
74
  featured?: boolean | undefined;
72
- catalog_visibility?: "search" | "any" | "visible" | "catalog" | "hidden" | undefined;
73
75
  stock_status?: ("instock" | "outofstock" | "onbackorder")[] | undefined;
76
+ category?: string | undefined;
77
+ category_operator?: "in" | "not_in" | "and" | undefined;
78
+ tag?: string | undefined;
79
+ tag_operator?: "in" | "not_in" | "and" | undefined;
74
80
  attributes?: {
75
81
  attribute: string;
76
82
  slug?: string[] | undefined;
77
83
  term_id?: number[] | undefined;
78
84
  operator?: "in" | "not_in" | "and" | undefined;
79
85
  }[] | undefined;
80
- on_sale?: boolean | undefined;
81
- category?: string | undefined;
82
- tag?: string | undefined;
86
+ attribute_relation?: "in" | "and" | undefined;
83
87
  min_price?: string | undefined;
84
88
  max_price?: string | undefined;
85
- parent_exclude?: number[] | undefined;
86
- category_operator?: "in" | "not_in" | "and" | undefined;
87
- tag_operator?: "in" | "not_in" | "and" | undefined;
88
- attribute_relation?: "in" | "and" | undefined;
89
+ on_sale?: boolean | undefined;
89
90
  } | undefined];
90
91
  details: () => readonly [...string[], "products", "detail"];
91
92
  detail: (id: number) => readonly [...string[], "products", "detail", number];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atomic-solutions/woocommerce-react",
3
- "version": "0.2.4",
3
+ "version": "0.2.6",
4
4
  "description": "React Query hooks and provider for WooCommerce Store API",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -46,7 +46,7 @@
46
46
  "access": "public"
47
47
  },
48
48
  "dependencies": {
49
- "@atomic-solutions/woocommerce-api-client": "0.1.3"
49
+ "@atomic-solutions/woocommerce-api-client": "0.1.5"
50
50
  },
51
51
  "peerDependencies": {
52
52
  "@tanstack/react-query": ">=5.0.0",