@wix/form-public 0.542.0 → 0.543.0

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/index.js CHANGED
@@ -55913,12 +55913,19 @@ var useInvokeCallback = (callback) => {
55913
55913
  // ../form-fields/dist/esm/ui/events-repeater/events-repeater-headless.js
55914
55914
  var NO_ERRORS2 = [];
55915
55915
  var NO_VALUES = {};
55916
- var GuestCount = ({ children, ...internal }) => {
55916
+ var EventsRepeaterLabel = ({ className }) => {
55917
+ return /* @__PURE__ */ React172.createElement(Label, {
55918
+ className
55919
+ }, null);
55920
+ };
55921
+ var GuestCount = ({ children, className, ...internal }) => {
55917
55922
  const { guestLimit, guestCount, onGuestCountChange } = internal;
55918
55923
  const { label, disabled, readOnly, onBlur, onFocus } = useFieldPropsV2();
55919
55924
  const invokeBlur = useInvokeCallback(onBlur);
55925
+ const labelElement = findChildOfType(children, GuestCount.Label);
55920
55926
  const controlElement = findChildOfType(children, GuestCount.Control);
55921
55927
  return /* @__PURE__ */ React172.createElement(NumberField, {
55928
+ className,
55922
55929
  "aria-label": label,
55923
55930
  value: guestCount,
55924
55931
  onChange: onGuestCountChange,
@@ -55929,7 +55936,7 @@ var GuestCount = ({ children, ...internal }) => {
55929
55936
  isReadOnly: readOnly,
55930
55937
  onBlur: invokeBlur,
55931
55938
  onFocus
55932
- }, controlElement);
55939
+ }, labelElement, controlElement);
55933
55940
  };
55934
55941
  var GuestCountControl = ({ children, className }) => {
55935
55942
  const { disabled, readOnly } = useFieldPropsV2();
@@ -56069,6 +56076,7 @@ var Guest = ({ className, ...internal }) => {
56069
56076
  fieldActions
56070
56077
  }));
56071
56078
  };
56079
+ GuestCount.Label = EventsRepeaterLabel;
56072
56080
  GuestCount.Control = GuestCountControl;
56073
56081
  GuestCount.Input = GuestCountInput;
56074
56082
  GuestCount.Decrement = GuestCountDecrement;