contentoh-components-library 21.3.55 → 21.3.56

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 (36) hide show
  1. package/dist/components/atoms/ButtonV2/styles.js +1 -1
  2. package/dist/components/atoms/Status/styles.js +1 -1
  3. package/dist/components/atoms/VerticalSideMenuMainPage/index.js +18 -23
  4. package/dist/components/atoms/VerticalSideMenuMainPage/styles.js +4 -4
  5. package/dist/components/organisms/DashboardMetric/dashboardMetricUtils.js +27 -0
  6. package/dist/components/organisms/GlobalModal/styles.js +1 -1
  7. package/dist/components/organisms/OrderDetail/styles.js +1 -1
  8. package/dist/components/organisms/OrderDetail/utils/Table/styles.js +1 -1
  9. package/dist/components/pages/Dashboard/Dashboard.stories.js +35 -47
  10. package/dist/components/pages/Dashboard/index.js +2 -2
  11. package/dist/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +98 -26
  12. package/dist/components/pages/ProviderProductEdition/index.js +623 -386
  13. package/dist/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +103 -153
  14. package/dist/components/pages/RetailerProductEdition/index.js +34 -36
  15. package/dist/index.js +13 -0
  16. package/package.json +7 -6
  17. package/src/components/atoms/ButtonV2/styles.js +1 -1
  18. package/src/components/atoms/Status/styles.js +4 -0
  19. package/src/components/atoms/VerticalSideMenuMainPage/index.js +18 -22
  20. package/src/components/atoms/VerticalSideMenuMainPage/styles.js +3 -4
  21. package/src/components/organisms/DashboardMetric/dashboardMetricUtils.js +18 -1
  22. package/src/components/organisms/GlobalModal/styles.js +10 -0
  23. package/src/components/organisms/OrderDetail/styles.js +1 -1
  24. package/src/components/organisms/OrderDetail/utils/Table/styles.js +0 -1
  25. package/src/components/organisms/TableResizable/TableResizable.stories.js +17 -0
  26. package/src/components/organisms/TableResizable/index.js +119 -0
  27. package/src/components/organisms/TableResizable/styles.js +133 -0
  28. package/src/components/organisms/TableResizable/utils.js +46 -0
  29. package/src/components/pages/Dashboard/Dashboard.stories.js +35 -50
  30. package/src/components/pages/Dashboard/index.js +2 -2
  31. package/src/components/pages/ProviderProductEdition/ProviderProductEdition.stories.js +110 -31
  32. package/src/components/pages/ProviderProductEdition/index.js +244 -131
  33. package/src/components/pages/RetailerProductEdition/RetailerProductEdition.stories.js +93 -145
  34. package/src/components/pages/RetailerProductEdition/index.js +25 -23
  35. package/src/index.js +1 -0
  36. package/dist/assets/fonts/roboto/LICENSE.txt +0 -202
@@ -7,12 +7,16 @@ Object.defineProperty(exports, "__esModule", {
7
7
  });
8
8
  exports.default = exports.RetailerProductEditionDefault = void 0;
9
9
 
10
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/defineProperty"));
11
+
10
12
  var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/esm/objectSpread2"));
11
13
 
12
14
  var _index = require("./index");
13
15
 
14
16
  var _jsxRuntime = require("react/jsx-runtime");
15
17
 
18
+ var _productSelected;
19
+
16
20
  var _default = {
17
21
  title: "Components/pages/RetailerProductEdition",
18
22
  component: _index.RetailerProductEdition
@@ -28,173 +32,119 @@ exports.RetailerProductEditionDefault = RetailerProductEditionDefault;
28
32
  RetailerProductEditionDefault.args = {
29
33
  tabsSections: {
30
34
  Descripción: true,
31
- "Ficha técnica": true,
32
- Imágenes: true
35
+ "Ficha técnica": false,
36
+ Imágenes: false
33
37
  },
34
- token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJhNmM0ZDNkNi0yNGE0LTQxZDQtYWQwZi1kMDg3NDM4YWI1YjYiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6ImE2YzRkM2Q2LTI0YTQtNDFkNC1hZDBmLWQwODc0MzhhYjViNiIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiJhY2FmNjhiOC00MmU1LTQ1NzAtYThiMC04YWY4NmY3MGU5YTEiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY3ODQ5NDYzNiwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY3ODQ5ODIzNiwiaWF0IjoxNjc4NDk0NjM2LCJlbWFpbCI6ImV0Y0Bjb250ZW50b2guY29tIn0.WoO3h0tAsF_Z4f_6BLIOXaL__TzHUxZyQlDAULQ2cT1HkUs0EmTZXRzRZ4oce7rV5osco9gCWfhc03rQ-C12jmU-Yt7jq3vuuoHUz4JqkLpelZPS8jHSsCAUWu_ekOIgDzvNegiyKk2R4qnd7IRPzWOAx1houg-KKT7kxCxjkTyJJGtzb7pYDLSJSV871nS8MeXGf5VZG5rQ3Smfl8ANqypLUEQQ6gSOr30Ztt1lZaHRmhF8WKo_GWwY3jNScmX_o9QGOSvKVl8hTqz4gA9xbiNJ3zpoh_5PzY-N4Sl8pE3gt_9Zw_o5ItLNHpnXuav_0NENvhXDu7p7VTLEpG8DTA",
35
- productSelected: {
36
- services: {
37
- datasheets: 1,
38
- descriptions: 1,
39
- images: 1
40
- },
41
- orderId: 4106,
42
- status: "PA",
43
- datasheet_status: "PA",
38
+ token: "eyJraWQiOiJkQWJkZCtlclwvTlwveVRQUWNvUlVyOCtrNUd2M1hMM2N1MWUzQ09zWExVRnc9IiwiYWxnIjoiUlMyNTYifQ.eyJzdWIiOiJhNmM0ZDNkNi0yNGE0LTQxZDQtYWQwZi1kMDg3NDM4YWI1YjYiLCJjb2duaXRvOmdyb3VwcyI6WyJjb2xhYm9yYWRvcmVzX2NvbnRlbnRvaCJdLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaXNzIjoiaHR0cHM6XC9cL2NvZ25pdG8taWRwLnVzLWVhc3QtMS5hbWF6b25hd3MuY29tXC91cy1lYXN0LTFfWE1aUWRxa0dqIiwiY29nbml0bzp1c2VybmFtZSI6ImE2YzRkM2Q2LTI0YTQtNDFkNC1hZDBmLWQwODc0MzhhYjViNiIsImNvZ25pdG86cm9sZXMiOlsiYXJuOmF3czppYW06Ojg5ODY3MDIzMjgwNzpyb2xlXC9jb250ZW50b2gtZGV2LXVzLWVhc3QtMS1sYW1iZGFSb2xlIl0sImF1ZCI6IjVhYzh0cGdzNmdic3ExM2ZydnJwaWVlcDQwIiwiZXZlbnRfaWQiOiIyYjU3MjZlMy04MjM2LTRmYzMtODBkMi05NWVmYmU4ODdjOTYiLCJ0b2tlbl91c2UiOiJpZCIsImF1dGhfdGltZSI6MTY4MjAxNjI5MSwibmFtZSI6IkNvbGFib3JhZG9yIiwicGhvbmVfbnVtYmVyIjoiKzUyMTExMSIsImV4cCI6MTY4MjAxOTg5MSwiaWF0IjoxNjgyMDE2MjkxLCJlbWFpbCI6ImV0Y0Bjb250ZW50b2guY29tIn0.SCj_yp1NkGCED59JHoDSdFAOakIOvZVeC0yLwt9z0BtenDXlU0m5cUofQQonnWPM8Q70yMFEkyMGI9kQs_fz1gxrmrSc2FGefn3B_1Vymq3pQ_S1JrY_syYf88m_GtJKOywEnE6--Ef9lZhFBFKGtqRJ4H8JBa9Xb96uCjAKyEMCSURDlw37pk2RQdULlZPj17Zb6Xrqi2lwrhpI1ByptX3__UoTiZklnTXwIxM4JdU7yuhXLznaEH8NOSd2Jw-CV6FCUbYBHlnRYBQg7B5mwyVKtDQm6QpRgBTBPCvljJJpFjRKUcnon8WZiFXx1qVbkWPt2vCT1TZqqoSLdlP6lA",
39
+ productSelected: (_productSelected = {
40
+ orderId: 15160,
41
+ status: "SAC",
42
+ datasheet_status: "SAC",
44
43
  prio: "none",
45
44
  version: 7,
46
- description_status: "PA",
47
- images_status: "CA",
48
- statusByRetailer: {
49
- 5: {
50
- datasheet: "PA",
51
- description: "PA",
52
- images: "CA"
53
- },
54
- 16: {
55
- datasheet: "PA",
56
- description: "PA",
57
- images: "AC"
58
- }
45
+ description_status: "SAC",
46
+ images_status: "SAC",
47
+ brand: null,
48
+ retailerOrder: 1,
49
+ missing: {
50
+ datasheet: null,
51
+ descriptions: null,
52
+ images: null
53
+ }
54
+ }, (0, _defineProperty2.default)(_productSelected, "orderId", 14606), (0, _defineProperty2.default)(_productSelected, "status", "AC"), (0, _defineProperty2.default)(_productSelected, "datasheet_status", "AC"), (0, _defineProperty2.default)(_productSelected, "prio", "none"), (0, _defineProperty2.default)(_productSelected, "version", 3), (0, _defineProperty2.default)(_productSelected, "description_status", "AC"), (0, _defineProperty2.default)(_productSelected, "images_status", "AC"), (0, _defineProperty2.default)(_productSelected, "statusByRetailer", {
55
+ 4: {
56
+ datasheet: "AC",
57
+ description: "AC",
58
+ images: "AC"
59
59
  },
60
- article: {
61
- id_article: 18376,
62
- id_category: "692",
63
- name: "Jabón para Manos Palmolive Aquarium Series Líquido Rellena-Pack 800 ml",
64
- upc: "7509546657097",
65
- timestamp: "2021-10-09T16:33:17.000Z",
66
- id_user: 203,
67
- status: "RECEPTION",
68
- active: 1,
69
- company_id: 226,
70
- verified_upc: 750954665709,
71
- Descripcion: null,
72
- Proveedor: null,
73
- id_proveedor: 0,
74
- company_name: "COLGATE PALMOLIVE S.A. DE C.V.",
75
- country: "null",
76
- id_order: 4106,
77
- id_datasheet_especialist: null,
78
- id_datasheet_facilitator: null,
79
- id_description_especialist: null,
80
- id_description_facilitator: null,
81
- id_images_especialist: 1251,
82
- id_images_facilitator: null,
83
- id_auditor: null,
84
- id_recepcionist: null,
85
- category: "Salud y Belleza|Cuidado Corporal|Jabones de Tocador",
86
- missingAttributes: null,
87
- missingDescriptions: null,
88
- missingImages: null
60
+ 5: {
61
+ datasheet: "AC",
62
+ description: "AC",
63
+ images: "AC"
89
64
  },
90
- retailers: [{
91
- id: 4,
92
- name: "Walmart Super y Superama",
93
- country: "México",
94
- id_region: 1,
95
- active: 1
96
- }, {
97
- id: 5,
98
- name: "Chedraui",
99
- country: "México",
100
- id_region: 1,
101
- active: 1
102
- }, {
103
- id: 6,
104
- name: "HEB",
105
- country: "México",
106
- id_region: 1,
107
- active: 1
108
- }, {
109
- id: 12,
110
- name: "La Comer",
111
- country: "México",
112
- id_region: 1,
113
- active: 1
114
- }, {
115
- id: 13,
116
- name: "Soriana",
117
- country: "México",
118
- id_region: 1,
119
- active: 1
120
- }, {
121
- id: 16,
122
- name: "Rappi",
123
- country: "México",
124
- id_region: 1,
125
- active: 1
126
- }, {
127
- id: 17,
128
- name: "Genérico",
129
- country: "México",
130
- id_region: 1,
131
- active: 1
132
- }, {
133
- id: 20,
134
- name: "Cornershop",
135
- country: "México",
136
- id_region: 1,
137
- active: 1
138
- }, {
139
- id: 24,
140
- name: "Alsuper",
141
- country: "México",
142
- id_region: 1,
143
- active: 1
144
- }, {
145
- id: 27,
146
- name: "IMPIRA México",
147
- country: "México",
148
- id_region: 1,
149
- active: 1
150
- }, {
151
- id: 38,
152
- name: "Del Sol",
153
- country: "México",
154
- id_region: 1,
155
- active: 1
156
- }],
157
- country: "null",
158
- upc: "7509546657097"
159
- },
65
+ 6: {
66
+ description: "AC",
67
+ images: "AC",
68
+ datasheet: "AC"
69
+ },
70
+ 12: {
71
+ datasheet: "AC",
72
+ description: "AC",
73
+ images: "AC"
74
+ },
75
+ 17: {
76
+ datasheet: "AC",
77
+ description: "AC",
78
+ images: "AC"
79
+ }
80
+ }), (0, _defineProperty2.default)(_productSelected, "article", {
81
+ category: "Puertas y Ventanas|Molduras|Molduras Madera Blanda",
82
+ company_name: "Demo",
83
+ country: "México",
84
+ id_category: "2366",
85
+ id_datasheet_especialist: null,
86
+ id_datasheet_facilitator: null,
87
+ id_description_especialist: null,
88
+ id_description_facilitator: null,
89
+ id_images_especialist: null,
90
+ id_images_facilitator: null,
91
+ id_order: 15160,
92
+ id_article: 39290,
93
+ id_auditor: 37,
94
+ name: "MOLDURA MARCO MODER 11X4X244 CM",
95
+ timestamp: "2023-04-19T21:36:02.000Z",
96
+ upc: "100030"
97
+ }), (0, _defineProperty2.default)(_productSelected, "retailers", [{
98
+ id: 58,
99
+ name: "The Home Depot Golden"
100
+ }, {
101
+ id: 68,
102
+ name: "The Home Depot Merchants"
103
+ }]), (0, _defineProperty2.default)(_productSelected, "statusByRetailer", {
104
+ 58: {
105
+ datasheet: "SAC",
106
+ description: "SAC",
107
+ images: "SAC"
108
+ }
109
+ }), _productSelected),
160
110
  location: {
161
111
  product: {
162
- articleId: 354,
163
- versionId: 3
112
+ articleId: 39290,
113
+ versionId: 7
164
114
  }
165
115
  },
166
116
  user: {
167
- id_user: 1251,
168
- name: "Ismael",
169
- last_name: "López",
170
- email: "ilopez@contentoh.com",
171
- position: "Full Stack Developer",
172
- telephone: null,
173
- country: "México",
174
- id_company: 254,
175
- id_cognito: "9d0cc5c8-a89e-4bdd-9e2d-358a01cc9a62",
176
- birth_Date: "1997-08-15T00:00:00.000Z",
177
- about_me: null,
178
- zip_code: null,
179
- address: null,
180
- job: null,
181
- id_stripe: null,
182
- id_role: 7,
117
+ id_user: 51,
118
+ name: "ADMIN PRUEBA",
119
+ last_name: "",
120
+ email: "etc@contentoh.com",
121
+ position: "",
122
+ telephone: "",
123
+ country: "",
124
+ id_company: 2,
125
+ id_cognito: "a6c4d3d6-24a4-41d4-ad0f-d087438ab5b6",
126
+ birth_Date: null,
127
+ about_me: "",
128
+ zip_code: "",
129
+ address: "",
130
+ job: "",
131
+ id_stripe: "",
132
+ id_role: 1,
183
133
  active: 1,
184
134
  is_retailer: 0,
185
135
  email_notify: 1,
186
- is_user_tech: "ADMIN-AS",
136
+ is_user_tech: null,
187
137
  membership: {
188
- id: 750,
189
- start_date: "2022-01-07T21:32:54.000Z",
190
- end_date: "2023-01-07T21:32:54.000Z",
191
- planID: 6,
192
- plan: "prod_KvGd6YSTJyR3AP",
193
- name: "Plan Small",
194
- user_limit: "10",
195
- products_limit: "1000",
196
- type: "Enterprise"
138
+ id: 2,
139
+ start_date: "2021-11-05T02:35:12.000Z",
140
+ end_date: "2022-11-05T02:34:49.000Z",
141
+ planID: 1,
142
+ plan: "prod_KtkvuFFLpOdP6e",
143
+ name: "Plan Free",
144
+ user_limit: "1",
145
+ products_limit: "3",
146
+ type: "PyMES"
197
147
  },
198
- src: "https://content-management-profile-prod.s3.amazonaws.com/id-460/460.png?1684511182259"
148
+ src: "https://content-management-profile.s3.amazonaws.com/id-51/51.png?1682016291518"
199
149
  }
200
150
  };
@@ -709,7 +709,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
709
709
  break;
710
710
 
711
711
  case 12:
712
- arr = ["PA", "AS", "CA", "RC", "RA", "RP", "RCA"];
712
+ arr = ["AS", "CA", "RC", "RA", "RP", "RCA"];
713
713
  return _context6.abrupt("break", 20);
714
714
 
715
715
  case 14:
@@ -1258,7 +1258,7 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1258
1258
  })) === null || _servicesData$find === void 0 ? void 0 : (_servicesData$find$st = _servicesData$find.status) === null || _servicesData$find$st === void 0 ? void 0 : _servicesData$find$st.replace(/.*\//, ""); //sessionStorage product
1259
1259
 
1260
1260
  var adminFacilitatorCanEvaluate = retailerStatus === "IE" && [1, 4, 5].includes(user.id_role);
1261
- var adminAuditorCanEvaluate = ["AC", "RP", "RCA"].includes(retailerStatus) && [1, 6].includes(user.id_role);
1261
+ var adminAuditorCanEvaluate = ["AC", "RP", "RCA", "SAC"].includes(retailerStatus) && [1, 6].includes(user.id_role);
1262
1262
  return adminFacilitatorCanEvaluate || adminAuditorCanEvaluate;
1263
1263
  };
1264
1264
 
@@ -1818,35 +1818,33 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1818
1818
  return _context15.abrupt("break", 14);
1819
1819
 
1820
1820
  case 14:
1821
- servicesData === null || servicesData === void 0 ? void 0 : servicesData.forEach(function (ret) {
1822
- if (conceptArray.includes(ret.service)) {
1823
- var _product$id_order;
1824
-
1825
- var data = {
1826
- articleId: product.article.id_article,
1827
- orderId: (_product$id_order = product.id_order) !== null && _product$id_order !== void 0 ? _product$id_order : product.orderId,
1828
- concept: ret.service,
1829
- result: result,
1830
- evalStatus: product["".concat(ret.service, "_status")],
1831
- retailerId: ret.id_retailer
1832
- };
1833
- evaluationArray.push(_axios.default.put("".concat(process.env.REACT_APP_EVALUATION_ENDPOINT), data, {
1834
- headers: {
1835
- Authorization: token
1836
- }
1837
- }));
1838
- }
1839
- });
1840
- _context15.next = 17;
1841
- return Promise.all(evaluationArray);
1842
-
1843
- case 17:
1821
+ //We comment this part of the code because it does not match with the correct flow
1822
+ // servicesData?.forEach((ret) => {
1823
+ // if (conceptArray.includes(ret.service)) {
1824
+ // let data = {
1825
+ // articleId: product.article.id_article,
1826
+ // orderId: product.id_order ?? product.orderId,
1827
+ // concept: ret.service,
1828
+ // result: result,
1829
+ // evalStatus: product[`${ret.service}_status`],
1830
+ // retailerId: ret.id_retailer,
1831
+ // };
1832
+ // evaluationArray.push(
1833
+ // axios.put(`${process.env.REACT_APP_EVALUATION_ENDPOINT}`, data, {
1834
+ // headers: {
1835
+ // Authorization: token,
1836
+ // },
1837
+ // })
1838
+ // );
1839
+ // }
1840
+ // });
1841
+ // await Promise.all(evaluationArray);
1844
1842
  (_conceptArray = conceptArray) === null || _conceptArray === void 0 ? void 0 : _conceptArray.forEach(function (concept) {
1845
- var _product$id_order2;
1843
+ var _product$id_order;
1846
1844
 
1847
1845
  var data = {
1848
1846
  articleId: product.article.id_article,
1849
- orderId: (_product$id_order2 = product.id_order) !== null && _product$id_order2 !== void 0 ? _product$id_order2 : product.orderId,
1847
+ orderId: (_product$id_order = product.id_order) !== null && _product$id_order !== void 0 ? _product$id_order : product.orderId,
1850
1848
  concept: concept,
1851
1849
  evalStatus: product["".concat(concept, "_status")]
1852
1850
  };
@@ -1856,10 +1854,10 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1856
1854
  }
1857
1855
  }));
1858
1856
  });
1859
- _context15.next = 20;
1857
+ _context15.next = 17;
1860
1858
  return Promise.all(sendAll);
1861
1859
 
1862
- case 20:
1860
+ case 17:
1863
1861
  productTemp = product;
1864
1862
  productTemp.status = "".concat(result, "A");
1865
1863
  productTemp.datasheet_status = productTemp.datasheet_status === "NA" ? "NA" : "".concat(result, "A");
@@ -1867,24 +1865,24 @@ var RetailerProductEdition = function RetailerProductEdition(_ref) {
1867
1865
  productTemp.images_status = productTemp.images_status === "NA" ? "NA" : "".concat(result, "A");
1868
1866
  sessionStorage.setItem("productSelected", JSON.stringify(productTemp));
1869
1867
  setProduct(productTemp);
1870
- _context15.next = 29;
1868
+ _context15.next = 26;
1871
1869
  return loadData();
1872
1870
 
1873
- case 29:
1874
- _context15.next = 34;
1871
+ case 26:
1872
+ _context15.next = 31;
1875
1873
  break;
1876
1874
 
1877
- case 31:
1878
- _context15.prev = 31;
1875
+ case 28:
1876
+ _context15.prev = 28;
1879
1877
  _context15.t1 = _context15["catch"](0);
1880
1878
  console.log(_context15.t1);
1881
1879
 
1882
- case 34:
1880
+ case 31:
1883
1881
  case "end":
1884
1882
  return _context15.stop();
1885
1883
  }
1886
1884
  }
1887
- }, _callee15, null, [[0, 31]]);
1885
+ }, _callee15, null, [[0, 28]]);
1888
1886
  }));
1889
1887
 
1890
1888
  return function validateAll(_x7) {
package/dist/index.js CHANGED
@@ -979,6 +979,19 @@ Object.keys(_RangeCalendar).forEach(function (key) {
979
979
  });
980
980
  });
981
981
 
982
+ var _TableResizable = require("./components/organisms/TableResizable");
983
+
984
+ Object.keys(_TableResizable).forEach(function (key) {
985
+ if (key === "default" || key === "__esModule") return;
986
+ if (key in exports && exports[key] === _TableResizable[key]) return;
987
+ Object.defineProperty(exports, key, {
988
+ enumerable: true,
989
+ get: function get() {
990
+ return _TableResizable[key];
991
+ }
992
+ });
993
+ });
994
+
982
995
  var _ChangePasswordLogin = require("./components/pages/ChangePasswordLogin");
983
996
 
984
997
  Object.keys(_ChangePasswordLogin).forEach(function (key) {
package/package.json CHANGED
@@ -1,19 +1,20 @@
1
1
  {
2
2
  "name": "contentoh-components-library",
3
- "version": "21.3.55",
3
+ "version": "21.3.56",
4
4
  "dependencies": {
5
5
  "@aws-amplify/auth": "^4.5.3",
6
6
  "@aws-amplify/datastore": "^3.11.0",
7
7
  "@aws-amplify/ui-react": "^2.17.0",
8
8
  "@babel/runtime": "^7.17.2",
9
- "@emotion/react": "^11.10.5",
10
- "@emotion/styled": "^11.10.5",
9
+ "@emotion/react": "^11.10.6",
10
+ "@emotion/styled": "^11.10.6",
11
11
  "@fortawesome/fontawesome-svg-core": "^6.2.0",
12
12
  "@fortawesome/free-regular-svg-icons": "^6.2.0",
13
13
  "@fortawesome/free-solid-svg-icons": "^6.2.0",
14
14
  "@fortawesome/react-fontawesome": "^0.2.0",
15
- "@mui/material": "^5.11.1",
16
- "@mui/styled-engine-sc": "^5.10.6",
15
+ "@mui/icons-material": "^5.11.16",
16
+ "@mui/material": "^5.12.0",
17
+ "@mui/styled-engine-sc": "^5.12.0",
17
18
  "@storybook/addon-postcss": "^2.0.0",
18
19
  "@testing-library/jest-dom": "^5.11.4",
19
20
  "@testing-library/react": "^11.1.0",
@@ -43,7 +44,7 @@
43
44
  "react-scroll": "^1.8.8",
44
45
  "react-transition-group": "^4.4.5",
45
46
  "storybook-addon-external-links": "^2.0.3",
46
- "styled-components": "^5.3.3",
47
+ "styled-components": "^5.3.9",
47
48
  "swiper": "^8.4.4",
48
49
  "uuid": "^8.3.2",
49
50
  "web-vitals": "^1.0.1"
@@ -94,7 +94,7 @@ export const Container = styled.div`
94
94
  }
95
95
  &.pink {
96
96
  background-color: #e33aa9;
97
- color: white;
97
+ color: red;
98
98
  border-color: #e33aa9;
99
99
  &:hover {
100
100
  background-color: #b42983;
@@ -23,6 +23,7 @@ export const Container = styled.div`
23
23
 
24
24
  &.status-R,
25
25
  &.status-AS,
26
+ &.status-SAC,
26
27
  &.status-PA {
27
28
  background-color: ${GlobalColors.reception};
28
29
  }
@@ -30,6 +31,7 @@ export const Container = styled.div`
30
31
  &.status-AA,
31
32
  &.status-AP,
32
33
  &.status-AC,
34
+ &.status-AAC,
33
35
  &.status-ACA {
34
36
  background-color: ${GlobalColors.finished};
35
37
  }
@@ -37,6 +39,7 @@ export const Container = styled.div`
37
39
  &.status-RA,
38
40
  &.status-RC,
39
41
  &.status-RP,
42
+ &.status-RAC,
40
43
  &.status-RCA {
41
44
  background-color: ${GlobalColors.rejected_status};
42
45
  }
@@ -47,6 +50,7 @@ export const Container = styled.div`
47
50
  background-color: ${GlobalColors.s4};
48
51
  }
49
52
 
53
+ &.status-FAP,
50
54
  &.status-Ex {
51
55
  background-color: ${GlobalColors.exported};
52
56
  }
@@ -1,3 +1,5 @@
1
+ import React, { useState } from "react";
2
+ import { BrowserRouter as Router } from "react-router-dom";
1
3
  import {
2
4
  Container,
3
5
  NavLinkOption,
@@ -6,14 +8,12 @@ import {
6
8
  } from "./styles";
7
9
  import iconLogoContentoh from "../../../assets/images/verticalSideMenuMainPage/iconLogoContentoh.svg";
8
10
  import iconLogo from "../../../assets/images/verticalSideMenuMainPage/iconLogo.svg";
9
- import React, { useState } from "react";
10
- import { BrowserRouter as Router } from "react-router-dom";
11
11
 
12
12
  export const VerticalSideMenuMainPage = ({
13
13
  menuoption = [],
14
14
  containerdash,
15
15
  }) => {
16
- const [trueBar, setTrueBar] = useState();
16
+ const [trueBar, setTrueBar] = useState(false);
17
17
  return (
18
18
  <Router>
19
19
  <ContainerPrincipal>
@@ -27,29 +27,25 @@ export const VerticalSideMenuMainPage = ({
27
27
  src={trueBar ? iconLogoContentoh : iconLogo}
28
28
  alt="Logo"
29
29
  className="logo"
30
- ></img>
30
+ />
31
31
  <div className="option">
32
32
  {menuoption.map((item, index) => (
33
- <div key={index} bar={trueBar} className="option-div">
34
- <NavLinkOption to={item.path} bar={trueBar}>
33
+ <div key={index} className="option-div">
34
+ <NavLinkOption to={item.path} bar={trueBar.toString()}>
35
35
  <img src={item.icon} alt={item.title}></img>
36
- {trueBar && <p>{item.title}</p>}
36
+ {trueBar ? <p>{item.title}</p> : null}
37
37
  </NavLinkOption>
38
- {item.suboption !== undefined && (
39
- <>
40
- {item?.suboption?.map((subitem) => (
41
- <div className="sub-option">
42
- <NavLinkOption
43
- to={subitem.path}
44
- className="sub-option-link"
45
- bar={trueBar}
46
- >
47
- {trueBar && <p>{subitem.title}</p>}
48
- </NavLinkOption>
49
- </div>
50
- ))}
51
- </>
52
- )}
38
+ {item?.suboption?.map((subitem, index) => (
39
+ <div className="sub-option" key={index}>
40
+ <NavLinkOption
41
+ to={subitem.path}
42
+ className="sub-option-link"
43
+ bar={trueBar.toString()}
44
+ >
45
+ {trueBar ? subitem.title : null}
46
+ </NavLinkOption>
47
+ </div>
48
+ ))}
53
49
  </div>
54
50
  ))}
55
51
  </div>
@@ -9,7 +9,7 @@ export const Container = styled.div`
9
9
  flex-direction: column;
10
10
  justify-content: space-between;
11
11
  overflow: none;
12
- width: ${({ bar }) => (bar ? 240 : 66)}px;
12
+ width: ${({ bar }) => (bar ? "240px" : "66px")};
13
13
  background: linear-gradient(180deg, #e33aa9 0%, #3b1366 100%);
14
14
  scrollbar-width: none;
15
15
  display: flex;
@@ -65,7 +65,7 @@ export const NavLinkOption = styled(NavLink)`
65
65
  color: ${({ bar }) => (bar ? "#fafafa" : "transparent")};
66
66
  text-decoration: none;
67
67
  cursor: pointer;
68
- padding: ${({ bar }) => (bar ? "0 22" : "0 8")}px;
68
+ padding: ${({ bar }) => (bar ? "0 22px" : "0 8px")};
69
69
  &:hover {
70
70
  background: rgba(255, 255, 255, 0.2);
71
71
  color: #fafafa;
@@ -94,7 +94,6 @@ export const NavLinkOption = styled(NavLink)`
94
94
  border-radius: 0;
95
95
  transition: color 0.3s linear;
96
96
  color: ${({ bar }) => (bar ? "#f0eef2" : "transparent")};
97
- padding-top: 14px;
98
97
  height: 25px;
99
98
  margin: 0;
100
99
  padding-left: 12px;
@@ -106,7 +105,7 @@ export const NavLinkOption = styled(NavLink)`
106
105
  height: 10px;
107
106
  background-color: white;
108
107
  position: absolute;
109
- bottom: 0;
108
+ top: 13;
110
109
  left: -6px;
111
110
  }
112
111
  &.active {
@@ -35,6 +35,16 @@ export const getFullStatus = (status) => {
35
35
  return "Exportado";
36
36
  case "NS":
37
37
  return "No solicitado";
38
+ case "SAC":
39
+ return "Solicitud Auditoría Content-oh!";
40
+ case "AAC":
41
+ return "Aprobado Auditoría Content-oh!";
42
+ case "RAC":
43
+ return "Rechazado Auditoría Content-oh!";
44
+ case "FAP":
45
+ return "Finalización Auditoría por Proveedor";
46
+ default:
47
+ return "";
38
48
  }
39
49
  };
40
50
 
@@ -75,6 +85,14 @@ export const getStatusColor = (status) => {
75
85
  return "black";
76
86
  case "Ex":
77
87
  return "#09CAD8";
88
+ case "SAC":
89
+ return "#2471A3";
90
+ case "AAC":
91
+ return "#1ABC9C";
92
+ case "RAC":
93
+ return "#229954";
94
+ case "FAP":
95
+ return "#F1C40F";
78
96
  default:
79
97
  return "white";
80
98
  }
@@ -104,7 +122,6 @@ export const removeOldStatus = (object) => {
104
122
  object["AC"] = object["AC"] + object["AF"];
105
123
  delete object["AF"];
106
124
  break;
107
-
108
125
  default:
109
126
  break;
110
127
  }