@plasmicpkgs/react-aria 0.0.131 → 0.0.133

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.
@@ -1,5 +1,5 @@
1
1
  import { usePlasmicCanvasContext, usePlasmicCanvasComponentInfo, usePlasmicLink } from '@plasmicapp/host';
2
- import React, { useEffect, useState, useMemo, useCallback, forwardRef, useImperativeHandle, useRef, useId } from 'react';
2
+ import React, { useEffect, useState, useMemo, useCallback, forwardRef, useImperativeHandle, useContext, useRef, useId } from 'react';
3
3
  import { mergeProps, useLink, useHover, useFocusRing, useButton, useFocusWithin } from 'react-aria';
4
4
  import { Button, Checkbox, Text, Label, CheckboxGroup, useContextProps, InputContext, ListBoxItem, ListBox, Section, Header, PopoverContext, Popover, ComboBox, ComboBoxStateContext, Dialog, ModalOverlay, Modal, DialogTrigger, Heading, TooltipTriggerStateContext, OverlayArrow, Radio, RadioGroup, Select, SelectStateContext, SelectValue, SliderOutput, Slider, SliderTrackContext, SliderThumb, SliderTrack, Switch, TextAreaContext, TextField, Provider, Tooltip } from 'react-aria-components';
5
5
  import registerComponent from '@plasmicapp/host/registerComponent';
@@ -3113,7 +3113,7 @@ function registerOverlayArrow(loader, overrides) {
3113
3113
  displayName: "Aria Overlay Arrow",
3114
3114
  importPath: "@plasmicpkgs/react-aria/skinny/registerOverlayArrow",
3115
3115
  importName: "BaseOverlayArrow",
3116
- styleSections: false,
3116
+ styleSections: ["visibility"],
3117
3117
  variants: variants$9,
3118
3118
  props: {
3119
3119
  children: {
@@ -5031,7 +5031,6 @@ function ControlledBaseTooltip(props) {
5031
5031
  className,
5032
5032
  tooltipId: state.isOpen ? tooltipId : void 0,
5033
5033
  isDisabled,
5034
- onOpenChange,
5035
5034
  triggerOnFocusOnly: trigger === "focus"
5036
5035
  },
5037
5036
  children
@@ -5054,27 +5053,17 @@ function ControlledBaseTooltip(props) {
5054
5053
  );
5055
5054
  }
5056
5055
  const TriggerWrapper = React.forwardRef(
5057
- function TriggerWrapper_({
5058
- children,
5059
- onOpenChange,
5060
- isDisabled,
5061
- triggerOnFocusOnly,
5062
- tooltipId,
5063
- className
5064
- }, ref) {
5056
+ function TriggerWrapper_({ children, isDisabled, triggerOnFocusOnly, tooltipId, className }, ref) {
5057
+ const state = useContext(TooltipTriggerStateContext);
5065
5058
  const { hoverProps } = useHover({
5066
5059
  isDisabled,
5067
- onHoverStart: () => !triggerOnFocusOnly && onOpenChange(true),
5068
- onHoverEnd: () => !triggerOnFocusOnly && onOpenChange(false)
5060
+ onHoverStart: () => !triggerOnFocusOnly && state.open(),
5061
+ onHoverEnd: () => !triggerOnFocusOnly && state.close()
5069
5062
  });
5070
5063
  const { focusWithinProps } = useFocusWithin({
5071
5064
  isDisabled,
5072
- onFocusWithin: () => {
5073
- onOpenChange(true);
5074
- },
5075
- onBlurWithin: () => {
5076
- onOpenChange(false);
5077
- }
5065
+ onFocusWithin: () => state.open(),
5066
+ onBlurWithin: () => state.close()
5078
5067
  });
5079
5068
  const mergedProps = mergeProps(hoverProps, focusWithinProps, {
5080
5069
  "aria-describedby": tooltipId,