contentoh-components-library 21.3.29 → 21.3.30
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/.env.development +0 -3
- package/.env.production +3 -2
- package/dist/assets/images/generalButton/closeIcon.svg +2 -2
- package/dist/components/atoms/ProgressBar/index.js +6 -36
- package/dist/components/atoms/ProgressBar/styles.js +3 -11
- package/dist/components/molecules/CustomSelect/CustomSelect.stories.js +22 -21
- package/dist/components/molecules/CustomSelect/SelectItem.js +1 -10
- package/dist/components/molecules/GalleryElement/index.js +1 -1
- package/dist/components/molecules/HeaderTop/styles.js +1 -1
- package/dist/components/molecules/ProductNameHeader/index.js +4 -6
- package/dist/components/organisms/FullProductNameHeader/index.js +0 -1
- package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +50 -65
- package/dist/components/pages/ProviderProductEdition/index.js +11 -17
- package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +41 -73
- package/dist/components/pages/RetailerProductEdition/index.js +14 -19
- package/dist/components/pages/RetailerProductEdition/utils.js +1 -1
- package/dist/global-files/data.js +23 -18
- package/dist/global-files/fonts.css +0 -6
- package/dist/global-files/variables.js +0 -2
- package/dist/index.js +46 -267
- package/package.json +1 -13
- package/src/assets/images/generalButton/closeIcon.svg +2 -2
- package/src/components/atoms/ProgressBar/index.js +5 -40
- package/src/components/atoms/ProgressBar/styles.js +0 -24
- package/src/components/molecules/CustomSelect/CustomSelect.stories.js +12 -20
- package/src/components/molecules/CustomSelect/SelectItem.js +0 -7
- package/src/components/molecules/GalleryElement/index.js +1 -1
- package/src/components/molecules/HeaderTop/styles.js +2 -5
- package/src/components/molecules/ProductNameHeader/index.js +2 -7
- package/src/components/organisms/FullProductNameHeader/index.js +0 -1
- package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +49 -67
- package/src/components/pages/ProviderProductEdition/index.js +9 -16
- package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +41 -78
- package/src/components/pages/RetailerProductEdition/index.js +20 -18
- package/src/components/pages/RetailerProductEdition/utils.js +1 -2
- package/src/global-files/data.js +23 -18
- package/src/global-files/fonts.css +0 -6
- package/src/global-files/variables.js +0 -2
- package/src/index.js +0 -17
- package/src/assets/images/customSelect/starIcon.svg +0 -14
- package/src/assets/images/defaultImages/Spinner.gif +0 -0
- package/src/assets/images/defaultImages/notFound.svg +0 -124
- package/src/assets/sounds/newMessage.mp3 +0 -0
- package/src/components/atoms/ButtonFileChooser/ButtonFileChooser.stories.js +0 -47
- package/src/components/atoms/ButtonFileChooser/index.js +0 -68
- package/src/components/atoms/ButtonFileChooser/styles.js +0 -4
- package/src/components/atoms/ButtonV2/ButtonV2.stories.js +0 -53
- package/src/components/atoms/ButtonV2/index.js +0 -85
- package/src/components/atoms/ButtonV2/styles.js +0 -217
- package/src/components/atoms/CustomIcon/CustomIcon.stories.js +0 -36
- package/src/components/atoms/CustomIcon/index.js +0 -41
- package/src/components/atoms/CustomIcon/styles.js +0 -85
- package/src/components/atoms/IconFile/IconFile.stories.js +0 -35
- package/src/components/atoms/IconFile/index.js +0 -119
- package/src/components/atoms/IconFile/styles.js +0 -67
- package/src/components/atoms/Image/Image.stories.js +0 -51
- package/src/components/atoms/Image/index.js +0 -55
- package/src/components/atoms/Image/styles.js +0 -34
- package/src/components/atoms/ImageLink/ImageLink.stories.js +0 -43
- package/src/components/atoms/ImageLink/index.js +0 -57
- package/src/components/atoms/ImageLink/styles.js +0 -30
- package/src/components/atoms/ImagePreview/ImagePreview.stories.js +0 -52
- package/src/components/atoms/ImagePreview/index.js +0 -178
- package/src/components/atoms/ImagePreview/styles.js +0 -77
- package/src/components/atoms/InputText/InputText.stories.js +0 -39
- package/src/components/atoms/InputText/index.js +0 -61
- package/src/components/atoms/InputText/styles.js +0 -89
- package/src/components/atoms/NotFound/NotFound.stories.js +0 -19
- package/src/components/atoms/NotFound/index.js +0 -52
- package/src/components/atoms/NotFound/styles.js +0 -55
- package/src/components/atoms/SelectItemV2/SelectItemV2.stories.js +0 -26
- package/src/components/atoms/SelectItemV2/index.js +0 -61
- package/src/components/atoms/SelectItemV2/styles.js +0 -90
- package/src/components/atoms/Tooltip/Tooltip.stories.js +0 -51
- package/src/components/atoms/Tooltip/index.js +0 -59
- package/src/components/atoms/Tooltip/styles.js +0 -42
- package/src/components/molecules/ButtonDownloadFile/DownloadFile.stories.js +0 -54
- package/src/components/molecules/ButtonDownloadFile/index.js +0 -109
- package/src/components/molecules/ButtonDownloadFile/styles.js +0 -66
- package/src/components/molecules/Dropdown/Dropdown.stories.js +0 -103
- package/src/components/molecules/Dropdown/index.js +0 -150
- package/src/components/molecules/Dropdown/styles.js +0 -75
- package/src/components/molecules/ImageTooltip/ImageTooltip.stories.js +0 -68
- package/src/components/molecules/ImageTooltip/index.js +0 -63
- package/src/components/molecules/ImageTooltip/styles.js +0 -18
- package/src/components/molecules/SelectV2/SelectV2.stories.js +0 -115
- package/src/components/molecules/SelectV2/index.js +0 -357
- package/src/components/molecules/SelectV2/styles.js +0 -105
- package/src/components/molecules/SelectV2/test.js +0 -60
- package/src/components/molecules/SelectV2/test.stories.js +0 -10
- package/src/components/organisms/Chat/Chat.stories.js +0 -149
- package/src/components/organisms/Chat/ChatLists/ChatLists.stories.js +0 -65
- package/src/components/organisms/Chat/ChatLists/Rotoplas.jpeg +0 -0
- package/src/components/organisms/Chat/ChatLists/THD.png +0 -0
- package/src/components/organisms/Chat/ChatLists/index.js +0 -141
- package/src/components/organisms/Chat/ChatLists/styles.js +0 -162
- package/src/components/organisms/Chat/ContainerItems/ContainerItems.stories.js +0 -142
- package/src/components/organisms/Chat/ContainerItems/index.js +0 -522
- package/src/components/organisms/Chat/ContainerItems/styles.js +0 -348
- package/src/components/organisms/Chat/ContentChat/ContentChat.stories.js +0 -102
- package/src/components/organisms/Chat/ContentChat/Rotoplas.jpeg +0 -0
- package/src/components/organisms/Chat/ContentChat/THD.png +0 -0
- package/src/components/organisms/Chat/ContentChat/index.js +0 -922
- package/src/components/organisms/Chat/ContentChat/styles.js +0 -41
- package/src/components/organisms/Chat/Footer/Footer.stories.js +0 -22
- package/src/components/organisms/Chat/Footer/index.js +0 -661
- package/src/components/organisms/Chat/Footer/styles.js +0 -286
- package/src/components/organisms/Chat/Header/Header.stories.js +0 -66
- package/src/components/organisms/Chat/Header/index.js +0 -93
- package/src/components/organisms/Chat/Header/styles.js +0 -49
- package/src/components/organisms/Chat/index.js +0 -238
- package/src/components/organisms/Chat/styles.js +0 -42
- package/src/components/organisms/Modal/Modal.stories.js +0 -55
- package/src/components/organisms/Modal/index.js +0 -97
- package/src/components/organisms/Modal/styles.js +0 -103
- package/src/components/organisms/RangeCalendar/RangeCalendar.stories.js +0 -16
- package/src/components/organisms/RangeCalendar/index.js +0 -121
- package/src/components/organisms/RangeCalendar/styles.js +0 -883
- package/src/global-files/handle_http.js +0 -225
- package/src/global-files/handle_userTech.js +0 -7
- package/src/global-files/utils.js +0 -330
package/.env.development
CHANGED
|
@@ -21,9 +21,6 @@ REACT_APP_READ_REQUIRED_ORDERS=https://fc069ovhuk.execute-api.us-east-1.amazonaw
|
|
|
21
21
|
REACT_APP_CATEGORY_ENDPOINT=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/categories
|
|
22
22
|
REACT_APP_READ_PROVIDERS=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/providers
|
|
23
23
|
REACT_APP_PENDING_INVITATIONS=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/pending-invitations
|
|
24
|
-
REACT_APP_PRODUCTS_CHAT_ENDPOINT=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/products-chat
|
|
25
|
-
REACT_APP_TICKETS_CHAT_ENDPOINT=https://ocqbzaa4a2.execute-api.us-east-1.amazonaws.com/dev/ticket-chat
|
|
26
|
-
REACT_APP_IMAGES_ENDPOINT=https://content-management-images.s3.amazonaws.com
|
|
27
24
|
REACT_APP_GET_AUDIT=https://fc069ovhuk.execute-api.us-east-1.amazonaws.com/dev/version-manager
|
|
28
25
|
|
|
29
26
|
REACT_APP_IMAGES_BUCKET=content-management-images
|
package/.env.production
CHANGED
|
@@ -21,10 +21,11 @@ REACT_APP_READ_REQUIRED_ORDERS=https://3v43slee1m.execute-api.us-east-1.amazonaw
|
|
|
21
21
|
REACT_APP_CATEGORY_ENDPOINT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/categories
|
|
22
22
|
REACT_APP_READ_PROVIDERS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/providers
|
|
23
23
|
REACT_APP_PENDING_INVITATIONS=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/pending-invitations
|
|
24
|
+
REACT_APP_GET_AUDIT=https://3v43slee1m.execute-api.us-east-1.amazonaws.com/prod/version-manager
|
|
24
25
|
|
|
25
26
|
REACT_APP_IMAGES_BUCKET=content-management-images-prod
|
|
26
27
|
REACT_APP_IMAGES_PROFILE_BUCKET=content-management-profile-prod
|
|
27
|
-
REACT_APP_KUTS3=
|
|
28
|
-
REACT_APP_AKUTS3=
|
|
28
|
+
REACT_APP_KUTS3=AKIA5CPHLQTT46EQ5TIK
|
|
29
|
+
REACT_APP_AKUTS3=tZDdrmvwxM1cScspfxFM3XpU4HSYrCNPazyHd0BL
|
|
29
30
|
REACT_APP_USER_POOL_ID=us-east-1_XMZQdqkGj
|
|
30
31
|
REACT_APP_USER_POOL_WEB_CLIENT_ID=5ac8tpgs6gbsq13frvrpieep40
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
<svg width="52" height="52" viewBox="0 0 52 52" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
-
<line x1="13.3585" y1="12.1333" x2="39.8661" y2="38.641" stroke="#E33AA9" stroke-width="
|
|
3
|
-
<path d="M39.8672 12.1333L13.8672 38.1333" stroke="#E33AA9" stroke-width="
|
|
2
|
+
<line x1="13.3585" y1="12.1333" x2="39.8661" y2="38.641" stroke="#E33AA9" stroke-width="1.73333" stroke-linecap="round" stroke-linejoin="round"/>
|
|
3
|
+
<path d="M39.8672 12.1333L13.8672 38.1333" stroke="#E33AA9" stroke-width="1.73333" stroke-linecap="round" stroke-linejoin="round"/>
|
|
4
4
|
</svg>
|
|
@@ -7,46 +7,16 @@ exports.ProgressBar = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _styles = require("./styles");
|
|
9
9
|
|
|
10
|
-
var _Tooltip = require("../Tooltip");
|
|
11
|
-
|
|
12
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
11
|
|
|
14
12
|
var ProgressBar = function ProgressBar(_ref) {
|
|
15
13
|
var percent = _ref.percent,
|
|
16
|
-
progressBarType = _ref.progressBarType
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
children:
|
|
20
|
-
children:
|
|
21
|
-
|
|
22
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("p", {
|
|
23
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("b", {
|
|
24
|
-
children: "Campos requeridos"
|
|
25
|
-
})
|
|
26
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("p", {
|
|
27
|
-
children: ["Este nuevo icono te indicar\xE1 cuando ", /*#__PURE__*/(0, _jsxRuntime.jsx)("br", {}), " completes todos los campos requeridos"]
|
|
28
|
-
})]
|
|
29
|
-
}),
|
|
30
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.ContainerIcon, {
|
|
31
|
-
className: "fondo",
|
|
32
|
-
percentageRequired: percentRequired,
|
|
33
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
34
|
-
class: "hola",
|
|
35
|
-
children: "local_police"
|
|
36
|
-
})
|
|
37
|
-
}),
|
|
38
|
-
classNameTooltip: "container-tooltip",
|
|
39
|
-
position: undefined,
|
|
40
|
-
addArrow: undefined,
|
|
41
|
-
transitionType: undefined,
|
|
42
|
-
followCursor: undefined
|
|
43
|
-
})
|
|
44
|
-
}) : "", /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.Container, {
|
|
45
|
-
className: "status-".concat(progressBarType),
|
|
46
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("p", {
|
|
47
|
-
children: [percent, "%"]
|
|
48
|
-
})
|
|
49
|
-
})]
|
|
14
|
+
progressBarType = _ref.progressBarType;
|
|
15
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_styles.Container, {
|
|
16
|
+
className: "status-".concat(progressBarType),
|
|
17
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("p", {
|
|
18
|
+
children: [percent, "%"]
|
|
19
|
+
})
|
|
50
20
|
});
|
|
51
21
|
};
|
|
52
22
|
|
|
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
|
-
exports.
|
|
8
|
+
exports.Container = void 0;
|
|
9
9
|
|
|
10
10
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/taggedTemplateLiteral"));
|
|
11
11
|
|
|
@@ -13,18 +13,10 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
13
13
|
|
|
14
14
|
var _variables = require("../../../global-files/variables");
|
|
15
15
|
|
|
16
|
-
var _templateObject
|
|
16
|
+
var _templateObject;
|
|
17
17
|
|
|
18
18
|
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n background-color: ", ";\n width: fit-content;\n height: 27px;\n padding: 4px;\n border-radius: 15px;\n font-family: ", ";\n font-weight: 600;\n font-size: 14px;\n line-height: 19px;\n color: ", ";\n\n &.status-CA,\n &.status-IE {\n background-color: ", ";\n }\n\n &.status-R,\n &.status-AS,\n &.status-PA {\n background-color: ", ";\n }\n\n &.status-AA,\n &.status-AP,\n &.status-ACA,\n &.status-AC {\n background-color: ", ";\n }\n\n &.status-RA,\n &.status-RC,\n &.status-RP,\n &.status-RCA {\n background-color: ", ";\n }\n\n &.status-Dat,\n &.status-Dsc,\n &.status-Imgs {\n background-color: ", ";\n }\n\n &.status-Ex {\n background-color: ", ";\n }\n\n &.status-DDI {\n background-color: ", ";\n }\n\n &.status-GLD {\n background-color: ", ";\n }\n\n &.status-TAB {\n background-color: ", ";\n }\n\n &.status-Pt {\n background-color: ", ";\n color: ", ";\n }\n"])), _variables.GlobalColors.s3, _variables.FontFamily.AvenirNext, function (backgroundColor) {
|
|
19
19
|
return backgroundColor === "s2" || backgroundColor === "s1" ? _variables.GlobalColors.s4 : _variables.GlobalColors.white;
|
|
20
20
|
}, _variables.GlobalColors.in_progress, _variables.GlobalColors.reception, _variables.GlobalColors.finished, _variables.GlobalColors.rejected_status, _variables.GlobalColors.s4, _variables.GlobalColors.exported, _variables.GlobalColors.original_purpura, _variables.GlobalColors.in_progress, _variables.GlobalColors.deep_gray, _variables.GlobalColors.s2, _variables.GlobalColors.s4);
|
|
21
21
|
|
|
22
|
-
exports.Container = Container;
|
|
23
|
-
|
|
24
|
-
var ContainerIcon = _styledComponents.default.div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n cursor: pointer;\n @font-face {\n font-family: \"Material Symbols Outlined\";\n font-style: normal;\n font-weight: 100 700;\n src: url(https://fonts.gstatic.com/s/materialsymbolsoutlined/v68/kJEhBvYX7BgnkSrUwT8OhrdQw4oELdPIeeII9v6oFsLjBuVY.woff2)\n format(\"woff2\");\n }\n\n .hola {\n font-family: \"Material Symbols Outlined\";\n font-size: 30px;\n //line-height: 1;\n margin-top: 10px;\n }\n .hola {\n font-variation-settings: \"FILL\"\n ", ",\n \"wght\" 400, \"GRAD\" 0, \"opsz\" 48;\n color: ", ";\n }\n"])), function (props) {
|
|
25
|
-
return props.percentageRequired < 100 ? 0 : 1;
|
|
26
|
-
}, function (props) {
|
|
27
|
-
return props.percentageRequired < 100 ? "#d4d1d7" : "#e33aa9";
|
|
28
|
-
});
|
|
29
|
-
|
|
30
|
-
exports.ContainerIcon = ContainerIcon;
|
|
22
|
+
exports.Container = Container;
|
|
@@ -11,8 +11,6 @@ var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/
|
|
|
11
11
|
|
|
12
12
|
var _index = require("./index");
|
|
13
13
|
|
|
14
|
-
var _starIcon = _interopRequireDefault(require("../../../assets/images/customSelect/starIcon.svg"));
|
|
15
|
-
|
|
16
14
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
15
|
|
|
18
16
|
var _default = {
|
|
@@ -28,26 +26,29 @@ var Template = function Template(args) {
|
|
|
28
26
|
var CustomSelectDefault = Template.bind({});
|
|
29
27
|
exports.CustomSelectDefault = CustomSelectDefault;
|
|
30
28
|
CustomSelectDefault.args = {
|
|
31
|
-
|
|
29
|
+
selectLabel: "Todos los departamentos",
|
|
32
30
|
defaultOption: "Todos los departamentos",
|
|
33
31
|
options: [{
|
|
34
|
-
id:
|
|
35
|
-
|
|
36
|
-
|
|
32
|
+
id: 1,
|
|
33
|
+
value: "Decoración",
|
|
34
|
+
subOptions: [{
|
|
35
|
+
id: 1,
|
|
36
|
+
value: "Espejos"
|
|
37
|
+
}, {
|
|
38
|
+
id: 2,
|
|
39
|
+
value: "Persianas"
|
|
40
|
+
}]
|
|
41
|
+
}, {
|
|
42
|
+
id: 2,
|
|
43
|
+
value: "Eléctrico"
|
|
44
|
+
}, {
|
|
45
|
+
id: 3,
|
|
46
|
+
value: "Ferretería"
|
|
47
|
+
}, {
|
|
48
|
+
id: 4,
|
|
49
|
+
value: "Herramientas"
|
|
37
50
|
}, {
|
|
38
|
-
id:
|
|
39
|
-
|
|
40
|
-
}]
|
|
41
|
-
onClickItem: function onClickItem(v, id) {
|
|
42
|
-
if (v) {
|
|
43
|
-
console.log("Agregar a la lista", id);
|
|
44
|
-
} else {
|
|
45
|
-
console.log("Eliminar a la lista", id);
|
|
46
|
-
}
|
|
47
|
-
},
|
|
48
|
-
icon: _starIcon.default,
|
|
49
|
-
showSearchBar: true,
|
|
50
|
-
customOptions: /*#__PURE__*/(0, _jsxRuntime.jsx)("p", {
|
|
51
|
-
children: "Esto es un customOptions"
|
|
52
|
-
})
|
|
51
|
+
id: 5,
|
|
52
|
+
value: "Iluminación"
|
|
53
|
+
}]
|
|
53
54
|
};
|
|
@@ -26,8 +26,7 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
26
26
|
customSelectId = _ref.customSelectId,
|
|
27
27
|
setParameterArray = _ref.setParameterArray,
|
|
28
28
|
activeFilters = _ref.activeFilters,
|
|
29
|
-
setActiveFilters = _ref.setActiveFilters
|
|
30
|
-
onClickItem = _ref.onClickItem;
|
|
29
|
+
setActiveFilters = _ref.setActiveFilters;
|
|
31
30
|
|
|
32
31
|
var _useState = (0, _react.useState)(false),
|
|
33
32
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
@@ -47,10 +46,6 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
47
46
|
id: "main-item-" + option.id,
|
|
48
47
|
label: option.name,
|
|
49
48
|
onChange: function onChange(e) {
|
|
50
|
-
if (onClickItem) {
|
|
51
|
-
onClickItem(e.target.checked, option.id);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
49
|
var subOptions = option.subOptions;
|
|
55
50
|
var filtersCopy = (0, _objectSpread2.default)({}, activeFilters);
|
|
56
51
|
|
|
@@ -113,10 +108,6 @@ var SelecItem = function SelecItem(_ref) {
|
|
|
113
108
|
label: sub.name,
|
|
114
109
|
defaultChecked: activeFilters[option.name] && activeFilters[option.name][sub.name],
|
|
115
110
|
onChange: function onChange(e) {
|
|
116
|
-
if (onClickItem) {
|
|
117
|
-
onClickItem(e.target.checked, sub.id);
|
|
118
|
-
}
|
|
119
|
-
|
|
120
111
|
if (e.target.checked) {
|
|
121
112
|
setParameterArray(function (current) {
|
|
122
113
|
return [].concat((0, _toConsumableArray2.default)(current), [sub.id]).sort(function (a, b) {
|
|
@@ -88,7 +88,7 @@ var GalleryElement = function GalleryElement(_ref) {
|
|
|
88
88
|
}, [showValidationPanel]);
|
|
89
89
|
|
|
90
90
|
var isEquals = function isEquals(value, auditValue) {
|
|
91
|
-
return value === auditValue;
|
|
91
|
+
return !value === auditValue;
|
|
92
92
|
};
|
|
93
93
|
|
|
94
94
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
|
|
@@ -13,6 +13,6 @@ var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
|
13
13
|
|
|
14
14
|
var _templateObject;
|
|
15
15
|
|
|
16
|
-
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: space-between;\n
|
|
16
|
+
var Container = _styledComponents.default.div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n display: flex;\n justify-content: space-between;\n display: flex;\n align-items: center;\n\n .buttons-container {\n display: flex;\n\n button {\n width: 30px;\n height: 30px;\n border: 1px solid #f0f0f0;\n background-size: 20px;\n padding: 0;\n display: flex;\n justify-content: center;\n align-items: center;\n img {\n height: 15px;\n }\n\n & + * {\n margin-left: 10px;\n }\n }\n }\n"])));
|
|
17
17
|
|
|
18
18
|
exports.Container = Container;
|
|
@@ -22,18 +22,16 @@ var ProductNameHeader = function ProductNameHeader(_ref) {
|
|
|
22
22
|
statusType = _ref.statusType,
|
|
23
23
|
percent = _ref.percent,
|
|
24
24
|
priority = _ref.priority,
|
|
25
|
-
date = _ref.date
|
|
26
|
-
percentRequired = _ref.percentRequired;
|
|
25
|
+
date = _ref.date;
|
|
27
26
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
|
|
28
27
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_index.ScreenHeader, {
|
|
29
28
|
headerType: "product-name-header",
|
|
30
29
|
text: productName
|
|
31
|
-
}),
|
|
30
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Status, {
|
|
32
31
|
statusType: statusType
|
|
33
32
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index3.ProgressBar, {
|
|
34
|
-
percent:
|
|
35
|
-
progressBarType: statusType
|
|
36
|
-
percentRequired: percentRequired
|
|
33
|
+
percent: percent,
|
|
34
|
+
progressBarType: statusType
|
|
37
35
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index4.PriorityFlag, {
|
|
38
36
|
priority: priority
|
|
39
37
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.ScreenHeader, {
|
|
@@ -59,7 +59,6 @@ var FullProductNameHeader = function FullProductNameHeader(_ref) {
|
|
|
59
59
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_ProductNameHeader.ProductNameHeader, {
|
|
60
60
|
productName: (headerData === null || headerData === void 0 ? void 0 : (_headerData$article = headerData.article) === null || _headerData$article === void 0 ? void 0 : _headerData$article.name) || (headerData === null || headerData === void 0 ? void 0 : headerData.name),
|
|
61
61
|
statusType: (headerData === null || headerData === void 0 ? void 0 : headerData.version_status) || (headerData === null || headerData === void 0 ? void 0 : headerData.status) || (headerData === null || headerData === void 0 ? void 0 : headerData.article_status),
|
|
62
|
-
percentRequired: percent,
|
|
63
62
|
percent: percent === null || percent === void 0 ? void 0 : percent.toFixed(0),
|
|
64
63
|
priority: headerData === null || headerData === void 0 ? void 0 : headerData.prio,
|
|
65
64
|
date: new Date((headerData === null || headerData === void 0 ? void 0 : (_headerData$article2 = headerData.article) === null || _headerData$article2 === void 0 ? void 0 : _headerData$article2.timestamp) || (headerData === null || headerData === void 0 ? void 0 : headerData.timestamp)).toLocaleDateString()
|
|
@@ -31,73 +31,70 @@ ProviderProductEditionDefault.args = {
|
|
|
31
31
|
"Ficha técnica": true,
|
|
32
32
|
Imágenes: true
|
|
33
33
|
},
|
|
34
|
-
token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.
|
|
34
|
+
token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJmNTkyN2Y4ZS1jYmY3LTQ5MjItOWUwOS1lNjllYzBiMjczMWEiLCJjb2duaXRvOmdyb3VwcyI6WyJ1c3VhcmlvX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwicGhvbmVfbnVtYmVyX3ZlcmlmaWVkIjpmYWxzZSwiY29nbml0bzp1c2VybmFtZSI6ImY1OTI3ZjhlLWNiZjctNDkyMi05ZTA5LWU2OWVjMGIyNzMxYSIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiIyOWY3YWY3Zi0yNmQ0LTRiMWItODZmZS0zOWY2ZTUyMDFhNzAiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY2OTkyNzAyMSwibmFtZSI6IklzbWFlbCBMb3BleiIsInBob25lX251bWJlciI6Iis1MjMxMTEzNjYzMzYiLCJleHAiOjE2Njk5MzA2MjEsImlhdCI6MTY2OTkyNzAyMSwiZW1haWwiOiJpbG9wZXpAY29udGVudG9oLmNvbSJ9.NK6hVSiBksguboJ1m8yYqtDq19kzgE3GqYDEJHLUya_n_TsXriv6W1ypq7XiSo9zrqWcmHBpOoJQS7WbWzjGe__NlJEXjo8bykS8QBTTOiMrKxz1KzGRYJkwgG0axk-zVysUQH0_y-fbwgEgMPtd6qO46DB_KlFI_PEL1-uR5MJ9U0kNkS61gMbHwFQFs_DU-sS01NxjBsjUEp783rs1r-jm7TelZac1rGaFNUyi5vHdSozYzlnzfzGcuACZ0lHqvah2FHbDyurp-G_uhpUn5lNmcL4rVNh2lDd4TOnhJ3AtN1wGSmtErmhjmBHTvavh1ub9pklA1B9qjVuTRpYANw",
|
|
35
35
|
articleId: 238,
|
|
36
36
|
category: 846,
|
|
37
37
|
version: 2,
|
|
38
38
|
productSelected: {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
upc: "102852",
|
|
39
|
+
id_article: 3,
|
|
40
|
+
id_category: 2032,
|
|
41
|
+
name: "CORTINA BLACKOUT DE POLIÉSTER CAFÉ 2.13 X 1.06 M",
|
|
42
|
+
upc: "161157",
|
|
43
|
+
timestamp: "2022-11-14T16:02:47.000Z",
|
|
44
|
+
categoryName: "Decoración|Cortinas y Persianas|Cortinas",
|
|
46
45
|
version: 1,
|
|
47
46
|
retailersAvailable: [{
|
|
48
|
-
|
|
49
|
-
|
|
47
|
+
name: "The Home Depot Golden",
|
|
48
|
+
id: 58
|
|
50
49
|
}]
|
|
51
50
|
},
|
|
52
51
|
productToEdit: {
|
|
53
|
-
idCategory:
|
|
54
|
-
ArticleId:
|
|
52
|
+
idCategory: 2032,
|
|
53
|
+
ArticleId: 3,
|
|
55
54
|
product: [{
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
upc: "102852",
|
|
55
|
+
id_article: 3,
|
|
56
|
+
id_category: 2032,
|
|
57
|
+
name: "CORTINA BLACKOUT DE POLIÉSTER CAFÉ 2.13 X 1.06 M",
|
|
58
|
+
upc: "161157",
|
|
59
|
+
timestamp: "2022-11-14T16:02:47.000Z",
|
|
60
|
+
categoryName: "Decoración|Cortinas y Persianas|Cortinas",
|
|
63
61
|
version: 1,
|
|
64
62
|
retailersAvailable: [{
|
|
65
|
-
|
|
66
|
-
|
|
63
|
+
name: "The Home Depot Golden",
|
|
64
|
+
id: 58
|
|
67
65
|
}]
|
|
68
66
|
}]
|
|
69
67
|
},
|
|
70
68
|
location: {
|
|
71
69
|
state: {
|
|
72
|
-
origin: "Contentoh"
|
|
73
|
-
withChat: true
|
|
70
|
+
origin: "Contentoh"
|
|
74
71
|
}
|
|
75
72
|
},
|
|
76
73
|
user: {
|
|
77
|
-
id_user:
|
|
78
|
-
name: "
|
|
79
|
-
last_name: "
|
|
80
|
-
email: "
|
|
81
|
-
position: "
|
|
82
|
-
telephone: "+
|
|
74
|
+
id_user: 28,
|
|
75
|
+
name: "Ismael",
|
|
76
|
+
last_name: "López",
|
|
77
|
+
email: "ilopez@contentoh.com",
|
|
78
|
+
position: "Test States",
|
|
79
|
+
telephone: "+523111366336",
|
|
83
80
|
country: "México",
|
|
84
|
-
id_company:
|
|
85
|
-
id_cognito: "
|
|
81
|
+
id_company: 1,
|
|
82
|
+
id_cognito: "f5927f8e-cbf7-4922-9e09-e69ec0b2731a",
|
|
86
83
|
birth_Date: null,
|
|
87
|
-
about_me:
|
|
88
|
-
zip_code:
|
|
89
|
-
address:
|
|
90
|
-
job:
|
|
91
|
-
id_stripe:
|
|
84
|
+
about_me: "",
|
|
85
|
+
zip_code: "",
|
|
86
|
+
address: "",
|
|
87
|
+
job: "",
|
|
88
|
+
id_stripe: "cus_KuEt6R6vwmN09f",
|
|
92
89
|
id_role: 0,
|
|
93
90
|
active: 1,
|
|
94
91
|
is_retailer: 0,
|
|
95
|
-
email_notify:
|
|
96
|
-
is_user_tech:
|
|
92
|
+
email_notify: 0,
|
|
93
|
+
is_user_tech: "AS",
|
|
97
94
|
membership: {
|
|
98
|
-
id:
|
|
99
|
-
start_date: "
|
|
100
|
-
end_date: "
|
|
95
|
+
id: 76,
|
|
96
|
+
start_date: "2022-01-18T17:25:35.000Z",
|
|
97
|
+
end_date: "2023-01-18T17:25:35.000Z",
|
|
101
98
|
planID: 8,
|
|
102
99
|
plan: "prod_KtlhECVSFG2iro",
|
|
103
100
|
name: "Plan Pro",
|
|
@@ -105,33 +102,21 @@ ProviderProductEditionDefault.args = {
|
|
|
105
102
|
products_limit: "5000",
|
|
106
103
|
type: "Enterprise"
|
|
107
104
|
},
|
|
108
|
-
src: "https://content-management-profile.s3.amazonaws.com/id-
|
|
105
|
+
src: "https://content-management-profile.s3.amazonaws.com/id-28/28.png?1669927021851"
|
|
109
106
|
},
|
|
110
107
|
company: {
|
|
111
|
-
id_company:
|
|
112
|
-
trade_name: "
|
|
113
|
-
company_name: "
|
|
114
|
-
rfc: "
|
|
115
|
-
adress: "
|
|
116
|
-
about_company:
|
|
117
|
-
telephone:
|
|
118
|
-
web_site:
|
|
119
|
-
zip_code:
|
|
108
|
+
id_company: 1,
|
|
109
|
+
trade_name: "GRUPO BRAHMA",
|
|
110
|
+
company_name: "GRUPO BRAHMA",
|
|
111
|
+
rfc: "XAXX010101000",
|
|
112
|
+
adress: "AA",
|
|
113
|
+
about_company: "",
|
|
114
|
+
telephone: "",
|
|
115
|
+
web_site: "",
|
|
116
|
+
zip_code: "",
|
|
120
117
|
email: null,
|
|
121
|
-
social_link:
|
|
122
|
-
is_retailer: 0
|
|
123
|
-
financedRetailers: [{
|
|
124
|
-
id: 68,
|
|
125
|
-
name: "The Home Depot Merchants",
|
|
126
|
-
country: "México",
|
|
127
|
-
id_region: 1,
|
|
128
|
-
active: 1
|
|
129
|
-
}],
|
|
130
|
-
retailers: [{
|
|
131
|
-
id: null,
|
|
132
|
-
name: null,
|
|
133
|
-
country: null
|
|
134
|
-
}]
|
|
118
|
+
social_link: "",
|
|
119
|
+
is_retailer: 0
|
|
135
120
|
},
|
|
136
121
|
showSurvey: function showSurvey(v) {
|
|
137
122
|
return v && alert("se muestra");
|
|
@@ -212,7 +212,7 @@ var myBucket = new _awsSdk.default.S3({
|
|
|
212
212
|
});
|
|
213
213
|
|
|
214
214
|
var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
215
|
-
var _product$retailers, _product$retailersAva, _location$state,
|
|
215
|
+
var _product$retailers, _product$retailersAva, _location$state, _datasheets$, _datasheets$$data;
|
|
216
216
|
|
|
217
217
|
var tabsSections = _ref.tabsSections,
|
|
218
218
|
_ref$productSelected = _ref.productSelected,
|
|
@@ -227,8 +227,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
227
227
|
revision = _ref$revision === void 0 ? false : _ref$revision,
|
|
228
228
|
setShowContentohRequestModal = _ref.setShowContentohRequestModal,
|
|
229
229
|
showSurvey = _ref.showSurvey,
|
|
230
|
-
company = _ref.company
|
|
231
|
-
withChat = _ref.withChat;
|
|
230
|
+
company = _ref.company;
|
|
232
231
|
|
|
233
232
|
var _useState = (0, _react.useState)("Descripción"),
|
|
234
233
|
_useState2 = (0, _slicedToArray2.default)(_useState, 2),
|
|
@@ -566,7 +565,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
566
565
|
(0, _data.getPercentage)({
|
|
567
566
|
data: [product]
|
|
568
567
|
}).then(function (res) {
|
|
569
|
-
return setPercentages(res
|
|
568
|
+
return setPercentages(res);
|
|
570
569
|
});
|
|
571
570
|
setLoading(false);
|
|
572
571
|
|
|
@@ -721,19 +720,17 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
721
720
|
loadAssignations(product);
|
|
722
721
|
}, [userGroups]);
|
|
723
722
|
(0, _react.useEffect)(function () {
|
|
724
|
-
var
|
|
723
|
+
var _retailers$;
|
|
725
724
|
|
|
726
725
|
var productTemp = product;
|
|
727
726
|
var retailers = (productTemp === null || productTemp === void 0 ? void 0 : productTemp.retailersAvailable) || (productTemp === null || productTemp === void 0 ? void 0 : productTemp.retailers);
|
|
727
|
+
retailers === null || retailers === void 0 ? void 0 : retailers.forEach(function (retailer) {
|
|
728
|
+
var _percentages$find;
|
|
728
729
|
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
retailer["percentage"] = Number((_percentages$productT2 = percentages[productTemp.id_article][retailer.id]) === null || _percentages$productT2 === void 0 ? void 0 : _percentages$productT2.percentageRequired);
|
|
734
|
-
});
|
|
735
|
-
}
|
|
736
|
-
|
|
730
|
+
retailer["percentage"] = percentages === null || percentages === void 0 ? void 0 : (_percentages$find = percentages.find(function (percent) {
|
|
731
|
+
return (retailer === null || retailer === void 0 ? void 0 : retailer.id) === (percent === null || percent === void 0 ? void 0 : percent.id_retailer);
|
|
732
|
+
})) === null || _percentages$find === void 0 ? void 0 : _percentages$find.percentage;
|
|
733
|
+
});
|
|
737
734
|
setProduct(productTemp);
|
|
738
735
|
setActivePercentage((_retailers$ = retailers[0]) === null || _retailers$ === void 0 ? void 0 : _retailers$.percentage);
|
|
739
736
|
}, [percentages]);
|
|
@@ -1683,10 +1680,7 @@ var ProviderProductEdition = function ProviderProductEdition(_ref) {
|
|
|
1683
1680
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_styles.Container, {
|
|
1684
1681
|
headerTop: headerTop,
|
|
1685
1682
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_HeaderTop.HeaderTop, {
|
|
1686
|
-
setHeaderTop: setHeaderTop
|
|
1687
|
-
withChat: location === null || location === void 0 ? void 0 : (_location$state2 = location.state) === null || _location$state2 === void 0 ? void 0 : _location$state2.withChat,
|
|
1688
|
-
productSelected: productSelected,
|
|
1689
|
-
token: token
|
|
1683
|
+
setHeaderTop: setHeaderTop
|
|
1690
1684
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
1691
1685
|
className: "data-container",
|
|
1692
1686
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|