@plasmicpkgs/react-aria 0.0.74 → 0.0.75

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.
@@ -1771,8 +1771,17 @@ var __objRest$g = (source, exclude) => {
1771
1771
  function BaseSection(props) {
1772
1772
  const _a = props, { header, items } = _a, rest = __objRest$g(_a, ["header", "items"]);
1773
1773
  const contextProps = React.useContext(PlasmicListBoxContext);
1774
+ const isStandalone = !contextProps;
1774
1775
  const mergedProps = mergeProps$1(contextProps, rest);
1775
- return /* @__PURE__ */ React.createElement(Section, __spreadValues$h({}, mergedProps), /* @__PURE__ */ React.createElement(Header, null, header), items);
1776
+ const section = /* @__PURE__ */ React.createElement(Section, __spreadValues$h({}, mergedProps), /* @__PURE__ */ React.createElement(Header, null, header), items);
1777
+ if (isStandalone) {
1778
+ return (
1779
+ // BaseListbox should give section a listbox context (that it can't be used without)
1780
+ // as well as the id manager (that is needed to identify and warn about duplication of ids)
1781
+ /* @__PURE__ */ React.createElement(BaseListBox, null, section)
1782
+ );
1783
+ }
1784
+ return section;
1776
1785
  }
1777
1786
  function registerSection(loader, overrides) {
1778
1787
  return registerComponentHelper(