@faststore/ui 1.6.22 → 1.6.23

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/dist/ui.esm.js CHANGED
@@ -1140,7 +1140,6 @@ const Breadcrumb = /*#__PURE__*/forwardRef(function Breadcrumb({
1140
1140
  testId = 'store-breadcrumb',
1141
1141
  ...otherProps
1142
1142
  }, ref) {
1143
- const lastIndex = React.Children.count(children);
1144
1143
  return React.createElement("nav", Object.assign({
1145
1144
  "aria-label": "Breadcrumb",
1146
1145
  role: "navigation",
@@ -1150,8 +1149,8 @@ const Breadcrumb = /*#__PURE__*/forwardRef(function Breadcrumb({
1150
1149
  }, otherProps), React.createElement(List, {
1151
1150
  "data-breadcrumb-list": true,
1152
1151
  variant: "ordered"
1153
- }, React.Children.map(children, (child, index) => {
1154
- const isLastItem = index === lastIndex - 1;
1152
+ }, React.Children.toArray(children).map((child, index, childrenArray) => {
1153
+ const isLastItem = index === childrenArray.length - 1;
1155
1154
  return React.createElement(ListItem, {
1156
1155
  isLastItem: isLastItem,
1157
1156
  divider: rawDivider,