From e5fe7eb67dd49743793d876580f2f62312ce125c Mon Sep 17 00:00:00 2001 From: Emanuel Ramos Date: Mon, 20 May 2024 17:55:46 -0300 Subject: [PATCH 1/8] fix: add classname in parent div of components --- node/package.json | 2 +- node/yarn.lock | 8 ++++---- react/AutocompleteBlock.tsx | 3 ++- react/TextAreaBlock.tsx | 3 ++- react/UploadBlock.tsx | 8 ++++++-- 5 files changed, 15 insertions(+), 9 deletions(-) diff --git a/node/package.json b/node/package.json index e0a540c9..b203845a 100644 --- a/node/package.json +++ b/node/package.json @@ -16,7 +16,7 @@ }, "dependencies": { "@gocommerce/utils": "^0.7.3", - "@vtex/api": "6.45.19", + "@vtex/api": "6.46.1", "atob": "^2.1.2", "axios": "^0.19.0", "camelcase": "^5.0.0", diff --git a/node/yarn.lock b/node/yarn.lock index 4e4f37ea..5db71870 100644 --- a/node/yarn.lock +++ b/node/yarn.lock @@ -1863,10 +1863,10 @@ resolved "https://registry.yarnpkg.com/@types/zen-observable/-/zen-observable-0.8.0.tgz#8b63ab7f1aa5321248aad5ac890a485656dcea4d" integrity sha512-te5lMAWii1uEJ4FwLjzdlbw3+n0FZNOvFXHxQDKeT0dilh7HOzdMzV2TrJVUzq8ep7J4Na8OUYPRLSQkJHAlrg== -"@vtex/api@6.45.19": - version "6.45.19" - resolved "https://registry.yarnpkg.com/@vtex/api/-/api-6.45.19.tgz#97b449850b517d6610e7123aa91caec2a29ae7b1" - integrity sha512-WUsAn1Oi+Z7Ih84DcRf4HQH85Mh+zO84L0ta7zuRyb13DoAEq2qMi0Mv6vZMd9BFWOCSD8AcTHVF/gZskwh9Yw== +"@vtex/api@6.46.1": + version "6.46.1" + resolved "https://registry.yarnpkg.com/@vtex/api/-/api-6.46.1.tgz#55a8755ae48f5400e7f1ed1921cd547950bb7a2a" + integrity sha512-geoxVvyWoQpOQ70Zmx3M8SBkRoGOS/bp9Gy26M+iCue63jofVSwmFz1zf66EaHA1PKOJNRgQPFwY+oeDE1U2lQ== dependencies: "@types/koa" "^2.11.0" "@types/koa-compose" "^3.2.3" diff --git a/react/AutocompleteBlock.tsx b/react/AutocompleteBlock.tsx index 046a72f0..2c6128c6 100644 --- a/react/AutocompleteBlock.tsx +++ b/react/AutocompleteBlock.tsx @@ -273,6 +273,7 @@ const AutocompleteBlock: FunctionComponent = ({ } const CSS_HANDLES = [ + 'autoCompleteBlock', 'skuSelection', 'productThumb', 'productTitle', @@ -290,7 +291,7 @@ const AutocompleteBlock: FunctionComponent = ({ const handles = useCssHandles(CSS_HANDLES) return ( -
+
{!componentOnly && (

+
{!componentOnly && (

) + return ( -
+
{!componentOnly && (

From 8bcddacdca11c3f1bb8168145030203f9c81de0f Mon Sep 17 00:00:00 2001 From: Emanuel Ramos Date: Tue, 21 May 2024 10:02:05 -0300 Subject: [PATCH 2/8] add change log description --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e114efb5..d60e1241 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -572,3 +572,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ### Added - Initial release with Copy/Paste and One by One modules. + +### Added + +- Add css handles in components parents div to manipulate styles easily. \ No newline at end of file From 291279f76298043a857e0f8587c2f7318d78e80a Mon Sep 17 00:00:00 2001 From: Emanuel Ramos Date: Wed, 22 May 2024 09:49:31 -0300 Subject: [PATCH 3/8] fix: create a function component to dropzone Icon --- react/UploadBlock.tsx | 5 +++-- react/assets/DropZoneIcon.tsx | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 react/assets/DropZoneIcon.tsx diff --git a/react/UploadBlock.tsx b/react/UploadBlock.tsx index e9323f68..7c6e93d3 100644 --- a/react/UploadBlock.tsx +++ b/react/UploadBlock.tsx @@ -17,6 +17,7 @@ import XLSX from 'xlsx' import { categoryMessages as messages } from './utils/messages' import { ParseText, GetText } from './utils' import ReviewBlock from './components/ReviewBlock' +import {DropzoneIcon} from './assets/DropZoneIcon' interface ItemType { id: string @@ -347,7 +348,7 @@ const UploadBlock: FunctionComponent< ] as const const handles = useCssHandles(CSS_HANDLES) - const Icon = () + return (
@@ -389,7 +390,7 @@ const UploadBlock: FunctionComponent< onDropAccepted={handleFile} onFileReset={handleReset} accept=".xls,.xlsx" - icon={Icon} + icon={} >
diff --git a/react/assets/DropZoneIcon.tsx b/react/assets/DropZoneIcon.tsx new file mode 100644 index 00000000..bd8ad686 --- /dev/null +++ b/react/assets/DropZoneIcon.tsx @@ -0,0 +1,4 @@ +import React from "react" +export const DropzoneIcon = ({className}) => { + return +} \ No newline at end of file From 49fac96fa9f33ade393b5c1caf12ffaa1fd0998f Mon Sep 17 00:00:00 2001 From: Emanuel Ramos Date: Wed, 29 May 2024 16:29:38 -0300 Subject: [PATCH 4/8] fix: add handles classname to selected sku --- react/AutocompleteBlock.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/react/AutocompleteBlock.tsx b/react/AutocompleteBlock.tsx index 2c6128c6..d5085019 100644 --- a/react/AutocompleteBlock.tsx +++ b/react/AutocompleteBlock.tsx @@ -278,6 +278,7 @@ const AutocompleteBlock: FunctionComponent = ({ 'productThumb', 'productTitle', 'productSku', + 'skuSelectionSelected', 'productLabel', 'inputQuantity', 'buttonAdd', @@ -341,7 +342,7 @@ const AutocompleteBlock: FunctionComponent = ({ return ( Date: Wed, 29 May 2024 16:35:39 -0300 Subject: [PATCH 5/8] fix: removing uploadBlock empty lines --- react/UploadBlock.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/react/UploadBlock.tsx b/react/UploadBlock.tsx index 11c5b1d6..74cd5132 100644 --- a/react/UploadBlock.tsx +++ b/react/UploadBlock.tsx @@ -349,7 +349,6 @@ const UploadBlock: FunctionComponent< const handles = useCssHandles(CSS_HANDLES) - return (
{!componentOnly && ( From 6b6e8b70a202c9f98dbf593370334942a570aeed Mon Sep 17 00:00:00 2001 From: EmanuelRamos115 <162623679+EmanuelRamos115@users.noreply.github.com> Date: Thu, 6 Jun 2024 13:45:01 -0300 Subject: [PATCH 6/8] Update react/AutocompleteBlock.tsx Co-authored-by: ataideverton <56592231+ataideverton@users.noreply.github.com> --- react/AutocompleteBlock.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/react/AutocompleteBlock.tsx b/react/AutocompleteBlock.tsx index d5085019..026ddc93 100644 --- a/react/AutocompleteBlock.tsx +++ b/react/AutocompleteBlock.tsx @@ -278,7 +278,7 @@ const AutocompleteBlock: FunctionComponent = ({ 'productThumb', 'productTitle', 'productSku', - 'skuSelectionSelected', + 'skuSelected', 'productLabel', 'inputQuantity', 'buttonAdd', From d71b63b49437da85967bc1292a1da2b77084e251 Mon Sep 17 00:00:00 2001 From: Emanuel Ramos Date: Thu, 6 Jun 2024 13:46:31 -0300 Subject: [PATCH 7/8] feat: add CHANGELOG --- CHANGELOG.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 29f40745..9f5f180b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -579,4 +579,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ### Added -- Add css handles in components parents div to manipulate styles easily. \ No newline at end of file +- Add css handles in components parents div to manipulate styles easily. + +### Added + +- Add css handles to selected sku on AutoComplete block. \ No newline at end of file From eeafb1a1a77790511e2db55a4891e0aaf425c8c2 Mon Sep 17 00:00:00 2001 From: Everton Ataide Date: Mon, 10 Jun 2024 10:17:34 -0300 Subject: [PATCH 8/8] Fix linter --- react/AutocompleteBlock.tsx | 5 ++++- react/UploadBlock.tsx | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/react/AutocompleteBlock.tsx b/react/AutocompleteBlock.tsx index 026ddc93..19358ffa 100644 --- a/react/AutocompleteBlock.tsx +++ b/react/AutocompleteBlock.tsx @@ -342,7 +342,10 @@ const AutocompleteBlock: FunctionComponent = ({ return ( {!componentOnly && (