@akinon/pz-b2b 2.0.0-beta.0 → 2.0.0-beta.10

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/CHANGELOG.md CHANGED
@@ -1,5 +1,46 @@
1
1
  # @akinon/pz-b2b
2
2
 
3
+ ## 2.0.0-beta.10
4
+
5
+ ### Minor Changes
6
+
7
+ - 2806320: ZERO-3390: Update version tailwindcss, autoprefixer, tailwind-merge, postcss
8
+
9
+ ## 2.0.0-beta.9
10
+
11
+ ### Minor Changes
12
+
13
+ - 0fe7711: ZERO-3387: Upgrade nextjs, eslint-config-next
14
+
15
+ ## 2.0.0-beta.8
16
+
17
+ ## 2.0.0-beta.7
18
+
19
+ ## 2.0.0-beta.6
20
+
21
+ ### Minor Changes
22
+
23
+ - 8f05f9b: ZERO-3250: Beta branch synchronized with Main branch
24
+
25
+ ## 2.0.0-beta.5
26
+
27
+ ## 2.0.0-beta.4
28
+
29
+ ## 2.0.0-beta.3
30
+
31
+ ## 2.0.0-beta.2
32
+
33
+ ### Minor Changes
34
+
35
+ - a006015: ZERO-3116: Add not-found page and update default middleware.
36
+ - 1eeb3d8: ZERO-3116: Add not found page
37
+
38
+ ## 2.0.0-beta.1
39
+
40
+ ### Minor Changes
41
+
42
+ - ZERO-3091: Upgrade Next.js to v15 and React to v19
43
+
3
44
  ## 2.0.0-beta.0
4
45
 
5
46
  ### Major Changes
package/README.md CHANGED
@@ -1,13 +1,13 @@
1
1
  # @akinon/pz-b2b
2
2
 
3
- ### Install the npm package
3
+ ## Installation
4
+
5
+ You can use the following command to install the extension with the latest plugins:
4
6
 
5
7
  ```bash
6
- # For latest version
7
- yarn add @akinon/pz-b2b
8
8
 
9
- # Preferred installation method
10
9
  npx @akinon/projectzero@latest --plugins
10
+
11
11
  ```
12
12
 
13
13
  ### Installation
package/package.json CHANGED
@@ -1,18 +1,18 @@
1
1
  {
2
2
  "name": "@akinon/pz-b2b",
3
- "version": "2.0.0-beta.0",
3
+ "version": "2.0.0-beta.10",
4
4
  "license": "MIT",
5
5
  "main": "src/index.ts",
6
6
  "peerDependencies": {
7
- "react": "^18.0.0",
8
- "react-dom": "^18.0.0"
7
+ "react": "^19.0.0",
8
+ "react-dom": "^19.0.0"
9
9
  },
10
10
  "devDependencies": {
11
- "@types/node": "^18.7.8",
12
- "@types/react": "^18.0.17",
13
- "@types/react-dom": "^18.0.6",
14
- "react": "^18.2.0",
15
- "react-dom": "^18.2.0",
16
- "typescript": "^4.7.4"
11
+ "@types/node": "^22.10.2",
12
+ "@types/react": "^19.0.2",
13
+ "@types/react-dom": "^19.0.2",
14
+ "react": "^19.0.0",
15
+ "react-dom": "^19.0.0",
16
+ "typescript": "^5.7.2"
17
17
  }
18
18
  }
@@ -184,7 +184,7 @@ export function BasketB2b({ translations }: BasketB2bProps) {
184
184
 
185
185
  return (
186
186
  <>
187
- <div className="max-w-screen-xl p-4 flex flex-col text-primary-800 lg:p-8 xl:flex-row xl:mx-auto">
187
+ <div className="max-w-(--breakpoint-xl) p-4 flex flex-col text-primary-800 lg:p-8 xl:flex-row xl:mx-auto">
188
188
  {isLoading && (
189
189
  <div className="flex justify-center w-full">
190
190
  <LoaderSpinner />
@@ -232,7 +232,7 @@ export function BasketB2b({ translations }: BasketB2bProps) {
232
232
  </div>
233
233
 
234
234
  <div className="w-full overflow-x-auto">
235
- <table className="border table-fixed overflow-scroll align-middle lg:w-full">
235
+ <table className="border border-gray-200 table-fixed overflow-scroll align-middle lg:w-full">
236
236
  <thead className="bg-[#eff1f8]">
237
237
  <tr>
238
238
  <th className="w-7 border border-[#d5dadb]"></th>
@@ -313,7 +313,7 @@ export function BasketB2b({ translations }: BasketB2bProps) {
313
313
  </div>
314
314
  ) : (
315
315
  <div
316
- className="flex flex-col items-center container max-w-screen-sm py-4 px-4 xs:py-6 xs:px-6 sm:py-8 sm:px-8 lg:max-w-screen-xl
316
+ className="flex flex-col items-center container max-w-(--breakpoint-sm) py-4 px-4 xs:py-6 xs:px-6 sm:py-8 sm:px-8 lg:max-w-(--breakpoint-xl)
317
317
  shadow-[0_0_4px_0_rgba(194,194,194,0.5)]"
318
318
  >
319
319
  <div className="w-full text-sm text-black-800 text-center my-4 mb-2 sm:text-base">
@@ -331,7 +331,7 @@ export function BasketB2b({ translations }: BasketB2bProps) {
331
331
  <i className="pz-icon-chevron-down absolute right-4 top-1/2 -translate-y-1/2 pointer-events-none"></i>
332
332
  <select
333
333
  onChange={(e) => setSelectedDraft(e.target.value)}
334
- className="w-[230px] h-[40px] mb-1 border border-[#d4d4d4] px-4 appearance-none text-sm outline-none cursor-pointer"
334
+ className="w-[230px] h-[40px] mb-1 border border-[#d4d4d4] px-4 appearance-none text-sm outline-hidden cursor-pointer"
335
335
  >
336
336
  <option value="">
337
337
  {_translations.empty.choose_cart_placeholder}
@@ -29,7 +29,7 @@ const B2bButton = useCallback(({buttonText}) => {
29
29
  return isVisible ? (
30
30
  <Button
31
31
  className={twMerge(
32
- 'fixed bottom-0 right-0 w-1/2 h-14 z-[20] flex items-center justify-center fill-primary-foreground hover:fill-primary sm:relative sm:w-full sm:mt-3 sm:font-semibold',
32
+ 'fixed bottom-0 right-0 w-1/2 h-14 z-20 flex items-center justify-center fill-primary-foreground hover:fill-primary sm:relative sm:w-full sm:mt-3 sm:font-semibold',
33
33
  divisionLoading && 'bg-black/50'
34
34
  )}
35
35
  onClick={() => setOpenSelectStoreModal(true)}
@@ -50,7 +50,7 @@ export const BasketItem = (props: Props) => {
50
50
  <tr>
51
51
  <td>
52
52
  <div className="h-[183px] w-full flex flex-col justify-between items-center text-xs">
53
- <div className="w-full flex items-center justify-center py-3 mb-3 border-b">
53
+ <div className="w-full flex items-center justify-center py-3 mb-3 border-b border-gray-200">
54
54
  <Icon name="chevron-down" size={10} />
55
55
  </div>
56
56
 
@@ -74,7 +74,7 @@ export const BasketItem = (props: Props) => {
74
74
  onClick={() => {
75
75
  setProductToBeDeleted(basketItem), setRemoveProduct(true);
76
76
  }}
77
- className="py-1.5 border-t w-full flex items-center justify-center"
77
+ className="py-1.5 border-t border-gray-200 w-full flex items-center justify-center"
78
78
  style={{ writingMode: 'vertical-rl', textOrientation: 'mixed' }}
79
79
  >
80
80
  {deleteText}
@@ -82,7 +82,7 @@ export const BasketItem = (props: Props) => {
82
82
  </div>
83
83
  </td>
84
84
 
85
- <td className="border text-center">
85
+ <td className="border border-gray-200 text-center">
86
86
  <div className="min-w-[80px] w-full h-full flex items-center justify-center">
87
87
  <Image
88
88
  src={basketItem.product.product_image}
@@ -93,26 +93,26 @@ export const BasketItem = (props: Props) => {
93
93
  </div>
94
94
  </td>
95
95
 
96
- <td className="min-w-[181px] text-sm border text-[#3f4b5c] leading-normal">
96
+ <td className="min-w-[181px] text-sm border border-gray-200 text-[#3f4b5c] leading-normal">
97
97
  <div className="px-4">
98
98
  <div className="break-words">{basketItem.product.name}</div>
99
99
  <div className="break-words">SKU: {basketItem.product.sku}</div>
100
100
  </div>
101
101
  </td>
102
102
 
103
- <td className="text-sm border text-[#3f4b5c] leading-normal text-right px-3">
103
+ <td className="text-sm border border-gray-200 text-[#3f4b5c] leading-normal text-right px-3">
104
104
  <Price value={basketItem.price} className="w-max block" />
105
105
  </td>
106
106
 
107
- <td className="text-sm border text-[#3f4b5c] leading-normal text-center">
107
+ <td className="text-sm border border-gray-200 text-[#3f4b5c] leading-normal text-center">
108
108
  <div className="min-w-[90px]">{basketItem.quantity}</div>
109
109
  </td>
110
110
 
111
- <td className="border">
111
+ <td className="border border-gray-200">
112
112
  <div className="min-w-[140px]">
113
113
  {basketItem.divisions.map((division) => (
114
114
  <div
115
- className="py-5 px-1 border-b last:border-0 text-center flex items-center justify-center gap-x-1"
115
+ className="py-5 px-1 border-b border-gray-200 last:border-0 text-center flex items-center justify-center gap-x-1"
116
116
  key={division.name}
117
117
  >
118
118
  <Icon name="b2b-info" size={18} className="text-[#293245]" />
@@ -133,7 +133,7 @@ export const BasketItem = (props: Props) => {
133
133
  </div>
134
134
  </td>
135
135
 
136
- <td className="border">
136
+ <td className="border border-gray-200">
137
137
  <div className="min-w-[120px]">
138
138
  {basketItem.divisions.map((division, index) => (
139
139
  <div
@@ -141,7 +141,7 @@ export const BasketItem = (props: Props) => {
141
141
  key={`division-${division.id}`}
142
142
  >
143
143
  <Input
144
- className="appearance-none outline-none w-20 h-6 px-2 py-0 border border-[#c8daec] rounded text-right"
144
+ className="appearance-none outline-hidden w-20 h-6 px-2 py-0 border border-[#c8daec] rounded-sm text-right"
145
145
  type="number"
146
146
  value={division.quantity}
147
147
  onChange={(e) => handleChange(division.id, e, index)}
@@ -159,7 +159,7 @@ export const BasketItem = (props: Props) => {
159
159
  </div>
160
160
  </td>
161
161
 
162
- <td className="text-sm border text-[#3f4b5c] leading-normal text-right px-6">
162
+ <td className="text-sm border border-gray-200 text-[#3f4b5c] leading-normal text-right px-6">
163
163
  <Price value={basketItem.total_amount} className="w-max block" />
164
164
  </td>
165
165
  </tr>
@@ -69,7 +69,7 @@ export const RequestQuoteModal = ({
69
69
  id="cart-name-input"
70
70
  name="name"
71
71
  type="text"
72
- className="h-8 border border-[#eeeeee] text-sm mb-2.5 outline-none px-2 w-full"
72
+ className="h-8 border border-[#eeeeee] text-sm mb-2.5 outline-hidden px-2 w-full"
73
73
  onChange={(e) => setCartName(e.target.value)}
74
74
  />
75
75
 
@@ -60,7 +60,7 @@ export const SaveCartModal = ({
60
60
  id="cart-name-input"
61
61
  name="name"
62
62
  type="text"
63
- className="h-8 border border-[#eeeeee] text-sm mb-2.5 outline-none px-2 w-full"
63
+ className="h-8 border border-[#eeeeee] text-sm mb-2.5 outline-hidden px-2 w-full"
64
64
  onChange={(e) => setCartName(e.target.value)}
65
65
  />
66
66
  <button
@@ -70,7 +70,7 @@ export const UploadModal = ({
70
70
  onChange={handleFileChange}
71
71
  className="opacity-0 w-full absolute left-0 top-0 h-full text-[0px] cursor-pointer"
72
72
  />
73
- <Button className="pointer-events-none h-9 text-white border rounded mb-1">
73
+ <Button className="pointer-events-none h-9 text-white border border-gray-200 rounded-sm mb-1">
74
74
  {t('basket.b2b.upload_file_modal.select_file')}
75
75
  </Button>
76
76
 
@@ -129,7 +129,7 @@ export function StoreModal({
129
129
  </header>
130
130
  <div className="p-[15px] md:p-[30px]">
131
131
  <table className="w-full flex flex-col h-full md:h-auto md:table md:w-[540px]">
132
- <thead className="w-full flex-grow-0 shrink-0 basis-auto table">
132
+ <thead className="w-full grow-0 shrink-0 basis-auto table">
133
133
  <tr className="border border-[#d7d7d7] bg-[#fafafa]">
134
134
  <th className="w-[43px] border-r border-[#d7d7d7]"></th>
135
135
  <th className="w-[190px] md:w-auto text-[11px] text-[#99999d] py-[18px] px-4 border-r border-[#d7d7d7] text-left font-normal">
@@ -162,9 +162,11 @@ export function StoreModal({
162
162
  <td className="text-right pr-6 md:pr-[37px] max-w-[111px] w-[111px] md:w-[180px] md:max-w-[180px]">
163
163
  <input
164
164
  type="number"
165
- className="w-[64px] md:w-[84px] h-[31px] border border-[#d7d7d7] outline-none text-xs text-right pr-1 appearance-none"
165
+ className="w-[64px] md:w-[84px] h-[31px] border border-[#d7d7d7] outline-hidden text-xs text-right pr-1 appearance-none"
166
166
  onChange={(e) => handleQuantityChange(store.id, e)}
167
- ref={(ref) => (inputRefs[store.id] = ref)}
167
+ ref={(ref) => {
168
+ inputRefs[store.id] = ref;
169
+ }}
168
170
  />
169
171
  </td>
170
172
  </tr>