@faststore/ui 1.5.17 → 1.5.20

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
@@ -3,6 +3,36 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## 1.5.20 (2022-02-25)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * Cart item availability ([#1160](https://github.com/vtex/faststore/issues/1160)) ([fd1be18](https://github.com/vtex/faststore/commit/fd1be18b09e8e5141a2a899e786e7caf08b3ff62))
12
+
13
+
14
+
15
+
16
+
17
+ ## 1.5.19 (2022-02-24)
18
+
19
+ **Note:** Version bump only for package @faststore/ui
20
+
21
+
22
+
23
+
24
+
25
+ ## 1.5.18 (2022-02-23)
26
+
27
+
28
+ ### Bug Fixes
29
+
30
+ * **ui:** Use valid HTML for the Breadcrumb's divider ([#1143](https://github.com/vtex/faststore/issues/1143)) ([b40c3b1](https://github.com/vtex/faststore/commit/b40c3b1405e6aa9a0f2006de9f37a903e40a2103))
31
+
32
+
33
+
34
+
35
+
6
36
  ## 1.5.17 (2022-02-22)
7
37
 
8
38
 
@@ -1117,6 +1117,7 @@ const Divider = ({
1117
1117
  const ListItem = ({
1118
1118
  children,
1119
1119
  isLastItem,
1120
+ divider,
1120
1121
  testId
1121
1122
  }) => {
1122
1123
  const props = {
@@ -1126,10 +1127,20 @@ const ListItem = ({
1126
1127
  };
1127
1128
 
1128
1129
  if (!React__default.isValidElement(children)) {
1129
- return React__default.createElement("li", null, React__default.createElement("span", Object.assign({}, props), children));
1130
+ return React__default.createElement("li", {
1131
+ "data-breadcrumb-list-item": true
1132
+ }, React__default.createElement("span", Object.assign({}, props), children, isLastItem ? null : React__default.createElement(Divider, {
1133
+ divider: divider,
1134
+ testId: testId
1135
+ })));
1130
1136
  }
1131
1137
 
1132
- return React__default.createElement("li", null, React__default.cloneElement(children, props));
1138
+ return React__default.createElement("li", {
1139
+ "data-breadcrumb-list-item": true
1140
+ }, React__default.cloneElement(children, props), isLastItem ? null : React__default.createElement(Divider, {
1141
+ divider: divider,
1142
+ testId: testId
1143
+ }));
1133
1144
  };
1134
1145
 
1135
1146
  const Breadcrumb = /*#__PURE__*/React.forwardRef(function Breadcrumb({
@@ -1150,15 +1161,12 @@ const Breadcrumb = /*#__PURE__*/React.forwardRef(function Breadcrumb({
1150
1161
  variant: "ordered"
1151
1162
  }, React__default.Children.map(children, (child, index) => {
1152
1163
  const isLastItem = index === lastIndex - 1;
1153
- return React__default.createElement(React.Fragment, {
1154
- key: `breadcrumb-${index}`
1155
- }, React__default.createElement(ListItem, {
1164
+ return React__default.createElement(ListItem, {
1156
1165
  isLastItem: isLastItem,
1157
- testId: testId
1158
- }, child), isLastItem ? null : React__default.createElement(Divider, {
1159
1166
  divider: rawDivider,
1167
+ key: `breadcrumb-${index}`,
1160
1168
  testId: testId
1161
- }));
1169
+ }, child);
1162
1170
  })));
1163
1171
  });
1164
1172