@fluentui/react-popover 9.5.15 → 9.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (91) hide show
  1. package/CHANGELOG.json +147 -1
  2. package/CHANGELOG.md +42 -2
  3. package/lib/Popover.js +0 -1
  4. package/lib/Popover.js.map +1 -1
  5. package/lib/PopoverSurface.js +0 -1
  6. package/lib/PopoverSurface.js.map +1 -1
  7. package/lib/PopoverTrigger.js +0 -1
  8. package/lib/PopoverTrigger.js.map +1 -1
  9. package/lib/components/Popover/Popover.js +3 -5
  10. package/lib/components/Popover/Popover.js.map +1 -1
  11. package/lib/components/Popover/Popover.types.js +0 -1
  12. package/lib/components/Popover/Popover.types.js.map +1 -1
  13. package/lib/components/Popover/constants.js +1 -2
  14. package/lib/components/Popover/constants.js.map +1 -1
  15. package/lib/components/Popover/index.js +0 -1
  16. package/lib/components/Popover/index.js.map +1 -1
  17. package/lib/components/Popover/renderPopover.js +21 -39
  18. package/lib/components/Popover/renderPopover.js.map +1 -1
  19. package/lib/components/Popover/usePopover.js +165 -156
  20. package/lib/components/Popover/usePopover.js.map +1 -1
  21. package/lib/components/PopoverSurface/PopoverSurface.js +5 -7
  22. package/lib/components/PopoverSurface/PopoverSurface.js.map +1 -1
  23. package/lib/components/PopoverSurface/PopoverSurface.types.js +1 -2
  24. package/lib/components/PopoverSurface/PopoverSurface.types.js.map +1 -1
  25. package/lib/components/PopoverSurface/index.js +0 -1
  26. package/lib/components/PopoverSurface/index.js.map +1 -1
  27. package/lib/components/PopoverSurface/renderPopoverSurface.js +13 -18
  28. package/lib/components/PopoverSurface/renderPopoverSurface.js.map +1 -1
  29. package/lib/components/PopoverSurface/usePopoverSurface.js +59 -67
  30. package/lib/components/PopoverSurface/usePopoverSurface.js.map +1 -1
  31. package/lib/components/PopoverSurface/usePopoverSurfaceStyles.styles.js +25 -3
  32. package/lib/components/PopoverSurface/usePopoverSurfaceStyles.styles.js.map +1 -1
  33. package/lib/components/PopoverTrigger/PopoverTrigger.js +3 -5
  34. package/lib/components/PopoverTrigger/PopoverTrigger.js.map +1 -1
  35. package/lib/components/PopoverTrigger/PopoverTrigger.types.js +0 -1
  36. package/lib/components/PopoverTrigger/PopoverTrigger.types.js.map +1 -1
  37. package/lib/components/PopoverTrigger/index.js +0 -1
  38. package/lib/components/PopoverTrigger/index.js.map +1 -1
  39. package/lib/components/PopoverTrigger/renderPopoverTrigger.js +2 -3
  40. package/lib/components/PopoverTrigger/renderPopoverTrigger.js.map +1 -1
  41. package/lib/components/PopoverTrigger/usePopoverTrigger.js +57 -64
  42. package/lib/components/PopoverTrigger/usePopoverTrigger.js.map +1 -1
  43. package/lib/index.js +0 -1
  44. package/lib/index.js.map +1 -1
  45. package/lib/popoverContext.js +19 -20
  46. package/lib/popoverContext.js.map +1 -1
  47. package/lib-commonjs/Popover.js +0 -3
  48. package/lib-commonjs/Popover.js.map +1 -1
  49. package/lib-commonjs/PopoverSurface.js +0 -3
  50. package/lib-commonjs/PopoverSurface.js.map +1 -1
  51. package/lib-commonjs/PopoverTrigger.js +0 -3
  52. package/lib-commonjs/PopoverTrigger.js.map +1 -1
  53. package/lib-commonjs/components/Popover/Popover.js +1 -3
  54. package/lib-commonjs/components/Popover/Popover.js.map +1 -1
  55. package/lib-commonjs/components/Popover/Popover.types.js +0 -3
  56. package/lib-commonjs/components/Popover/Popover.types.js.map +1 -1
  57. package/lib-commonjs/components/Popover/constants.js +1 -3
  58. package/lib-commonjs/components/Popover/constants.js.map +1 -1
  59. package/lib-commonjs/components/Popover/index.js +0 -3
  60. package/lib-commonjs/components/Popover/index.js.map +1 -1
  61. package/lib-commonjs/components/Popover/renderPopover.js +1 -3
  62. package/lib-commonjs/components/Popover/renderPopover.js.map +1 -1
  63. package/lib-commonjs/components/Popover/usePopover.js +1 -3
  64. package/lib-commonjs/components/Popover/usePopover.js.map +1 -1
  65. package/lib-commonjs/components/PopoverSurface/PopoverSurface.js +1 -3
  66. package/lib-commonjs/components/PopoverSurface/PopoverSurface.js.map +1 -1
  67. package/lib-commonjs/components/PopoverSurface/PopoverSurface.types.js +0 -3
  68. package/lib-commonjs/components/PopoverSurface/PopoverSurface.types.js.map +1 -1
  69. package/lib-commonjs/components/PopoverSurface/index.js +0 -3
  70. package/lib-commonjs/components/PopoverSurface/index.js.map +1 -1
  71. package/lib-commonjs/components/PopoverSurface/renderPopoverSurface.js +1 -3
  72. package/lib-commonjs/components/PopoverSurface/renderPopoverSurface.js.map +1 -1
  73. package/lib-commonjs/components/PopoverSurface/usePopoverSurface.js +1 -3
  74. package/lib-commonjs/components/PopoverSurface/usePopoverSurface.js.map +1 -1
  75. package/lib-commonjs/components/PopoverSurface/usePopoverSurfaceStyles.styles.js +51 -3
  76. package/lib-commonjs/components/PopoverSurface/usePopoverSurfaceStyles.styles.js.map +1 -1
  77. package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.js +1 -3
  78. package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.js.map +1 -1
  79. package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.types.js +0 -3
  80. package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.types.js.map +1 -1
  81. package/lib-commonjs/components/PopoverTrigger/index.js +0 -3
  82. package/lib-commonjs/components/PopoverTrigger/index.js.map +1 -1
  83. package/lib-commonjs/components/PopoverTrigger/renderPopoverTrigger.js +1 -3
  84. package/lib-commonjs/components/PopoverTrigger/renderPopoverTrigger.js.map +1 -1
  85. package/lib-commonjs/components/PopoverTrigger/usePopoverTrigger.js +1 -3
  86. package/lib-commonjs/components/PopoverTrigger/usePopoverTrigger.js.map +1 -1
  87. package/lib-commonjs/index.js +0 -3
  88. package/lib-commonjs/index.js.map +1 -1
  89. package/lib-commonjs/popoverContext.js +2 -4
  90. package/lib-commonjs/popoverContext.js.map +1 -1
  91. package/package.json +12 -12
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../lib/components/PopoverTrigger/usePopoverTrigger.js"],"sourcesContent":["import * as React from 'react';\nimport { applyTriggerPropsToChildren, getTriggerChild, mergeCallbacks, useMergedRefs, useEventCallback } from '@fluentui/react-utilities';\nimport { useModalAttributes } from '@fluentui/react-tabster';\nimport { usePopoverContext_unstable } from '../../popoverContext';\nimport { useARIAButtonProps } from '@fluentui/react-aria';\nimport { Escape } from '@fluentui/keyboard-keys';\n/**\n * Create the state required to render PopoverTrigger.\n *\n * The returned state can be modified with hooks such as usePopoverTriggerStyles,\n * before being passed to renderPopoverTrigger_unstable.\n *\n * @param props - props from this instance of PopoverTrigger\n */\nexport const usePopoverTrigger_unstable = props => {\n const {\n children,\n disableButtonEnhancement = false\n } = props;\n const child = getTriggerChild(children);\n const open = usePopoverContext_unstable(context => context.open);\n const setOpen = usePopoverContext_unstable(context => context.setOpen);\n const toggleOpen = usePopoverContext_unstable(context => context.toggleOpen);\n const triggerRef = usePopoverContext_unstable(context => context.triggerRef);\n const openOnHover = usePopoverContext_unstable(context => context.openOnHover);\n const openOnContext = usePopoverContext_unstable(context => context.openOnContext);\n const {\n triggerAttributes\n } = useModalAttributes();\n const onContextMenu = e => {\n if (openOnContext) {\n e.preventDefault();\n setOpen(e, true);\n }\n };\n const onClick = e => {\n if (!openOnContext) {\n toggleOpen(e);\n }\n };\n const onKeyDown = e => {\n if (e.key === Escape && open) {\n setOpen(e, false);\n // stop propagation to avoid conflicting with other elements that listen for `Escape`\n // e,g: Dialog, Menu\n e.stopPropagation();\n }\n };\n const onMouseEnter = e => {\n if (openOnHover) {\n setOpen(e, true);\n }\n };\n const onMouseLeave = e => {\n if (openOnHover) {\n setOpen(e, false);\n }\n };\n const contextMenuProps = {\n ...triggerAttributes,\n 'aria-expanded': `${open}`,\n ...(child === null || child === void 0 ? void 0 : child.props),\n onMouseEnter: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onMouseEnter, onMouseEnter)),\n onMouseLeave: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onMouseLeave, onMouseLeave)),\n onContextMenu: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onContextMenu, onContextMenu)),\n ref: useMergedRefs(triggerRef, child === null || child === void 0 ? void 0 : child.ref)\n };\n const triggerChildProps = {\n ...contextMenuProps,\n onClick: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onClick, onClick)),\n onKeyDown: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onKeyDown, onKeyDown))\n };\n const ariaButtonTriggerChildProps = useARIAButtonProps((child === null || child === void 0 ? void 0 : child.type) === 'button' || (child === null || child === void 0 ? void 0 : child.type) === 'a' ? child.type : 'div', triggerChildProps);\n return {\n children: applyTriggerPropsToChildren(props.children, useARIAButtonProps((child === null || child === void 0 ? void 0 : child.type) === 'button' || (child === null || child === void 0 ? void 0 : child.type) === 'a' ? child.type : 'div', openOnContext ? contextMenuProps : disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps))\n };\n};\n//# sourceMappingURL=usePopoverTrigger.js.map"],"names":["usePopoverTrigger_unstable","props","children","disableButtonEnhancement","child","getTriggerChild","open","usePopoverContext_unstable","context","setOpen","toggleOpen","triggerRef","openOnHover","openOnContext","triggerAttributes","useModalAttributes","onContextMenu","e","preventDefault","onClick","onKeyDown","key","Escape","stopPropagation","onMouseEnter","onMouseLeave","contextMenuProps","useEventCallback","mergeCallbacks","ref","useMergedRefs","triggerChildProps","ariaButtonTriggerChildProps","useARIAButtonProps","type","applyTriggerPropsToChildren"],"mappings":";;;;+BAcaA;;aAAAA;;;6DAdU;gCACuF;8BAC3E;gCACQ;2BACR;8BACZ;AAShB,MAAMA,6BAA6BC,CAAAA,QAAS;IACjD,MAAM,EACJC,SAAQ,EACRC,0BAA2B,KAAK,CAAA,EACjC,GAAGF;IACJ,MAAMG,QAAQC,IAAAA,+BAAe,EAACH;IAC9B,MAAMI,OAAOC,IAAAA,0CAA0B,EAACC,CAAAA,UAAWA,QAAQF,IAAI;IAC/D,MAAMG,UAAUF,IAAAA,0CAA0B,EAACC,CAAAA,UAAWA,QAAQC,OAAO;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UAAU,KAAK,IAAI,KAAK,IAAIA,MAAM8B,IAAI,AAAD,MAAO,MAAM9B,MAAM8B,IAAI,GAAG,KAAK,EAAErB,gBAAgBa,mBAAmBvB,2BAA2B4B,oBAAoBC,2BAA2B;IAC5V;AACF,GACA,6CAA6C"}
1
+ {"version":3,"sources":["usePopoverTrigger.js"],"sourcesContent":["import * as React from 'react';\nimport { applyTriggerPropsToChildren, getTriggerChild, mergeCallbacks, useMergedRefs, useEventCallback } from '@fluentui/react-utilities';\nimport { useModalAttributes } from '@fluentui/react-tabster';\nimport { usePopoverContext_unstable } from '../../popoverContext';\nimport { useARIAButtonProps } from '@fluentui/react-aria';\nimport { Escape } from '@fluentui/keyboard-keys';\n/**\n * Create the state required to render PopoverTrigger.\n *\n * The returned state can be modified with hooks such as usePopoverTriggerStyles,\n * before being passed to renderPopoverTrigger_unstable.\n *\n * @param props - props from this instance of PopoverTrigger\n */ export const usePopoverTrigger_unstable = (props)=>{\n const { children , disableButtonEnhancement =false } = props;\n const child = getTriggerChild(children);\n const open = usePopoverContext_unstable((context)=>context.open);\n const setOpen = usePopoverContext_unstable((context)=>context.setOpen);\n const toggleOpen = usePopoverContext_unstable((context)=>context.toggleOpen);\n const triggerRef = usePopoverContext_unstable((context)=>context.triggerRef);\n const openOnHover = usePopoverContext_unstable((context)=>context.openOnHover);\n const openOnContext = usePopoverContext_unstable((context)=>context.openOnContext);\n const { triggerAttributes } = useModalAttributes();\n const onContextMenu = (e)=>{\n if (openOnContext) {\n e.preventDefault();\n setOpen(e, true);\n }\n };\n const onClick = (e)=>{\n if (!openOnContext) {\n toggleOpen(e);\n }\n };\n const onKeyDown = (e)=>{\n if (e.key === Escape && open) {\n setOpen(e, false);\n // stop propagation to avoid conflicting with other elements that listen for `Escape`\n // e,g: Dialog, Menu\n e.stopPropagation();\n }\n };\n const onMouseEnter = (e)=>{\n if (openOnHover) {\n setOpen(e, true);\n }\n };\n const onMouseLeave = (e)=>{\n if (openOnHover) {\n setOpen(e, false);\n }\n };\n const contextMenuProps = {\n ...triggerAttributes,\n 'aria-expanded': `${open}`,\n ...child === null || child === void 0 ? void 0 : child.props,\n onMouseEnter: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onMouseEnter, onMouseEnter)),\n onMouseLeave: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onMouseLeave, onMouseLeave)),\n onContextMenu: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onContextMenu, onContextMenu)),\n ref: useMergedRefs(triggerRef, child === null || child === void 0 ? void 0 : child.ref)\n };\n const triggerChildProps = {\n ...contextMenuProps,\n onClick: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onClick, onClick)),\n onKeyDown: useEventCallback(mergeCallbacks(child === null || child === void 0 ? void 0 : child.props.onKeyDown, onKeyDown))\n };\n const ariaButtonTriggerChildProps = useARIAButtonProps((child === null || child === void 0 ? void 0 : child.type) === 'button' || (child === null || child === void 0 ? void 0 : child.type) === 'a' ? child.type : 'div', triggerChildProps);\n return {\n children: applyTriggerPropsToChildren(props.children, useARIAButtonProps((child === null || child === void 0 ? void 0 : child.type) === 'button' || (child === null || child === void 0 ? void 0 : child.type) === 'a' ? child.type : 'div', openOnContext ? contextMenuProps : disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps))\n };\n};\n"],"names":["usePopoverTrigger_unstable","props","children","disableButtonEnhancement","child","getTriggerChild","open","usePopoverContext_unstable","context","setOpen","toggleOpen","triggerRef","openOnHover","openOnContext","triggerAttributes","useModalAttributes","onContextMenu","e","preventDefault","onClick","onKeyDown","key","Escape","stopPropagation","onMouseEnter","onMouseLeave","contextMenuProps","useEventCallback","mergeCallbacks","ref","useMergedRefs","triggerChildProps","ariaButtonTriggerChildProps","useARIAButtonProps","type","applyTriggerPropsToChildren"],"mappings":";;;;+BAaiBA;;aAAAA;;;6DAbM;gCACuF;8BAC3E;gCACQ;2BACR;8BACZ;AAQZ,MAAMA,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AAI,GAAG,KAAK,EAAEH;IAC3N,OAAO;QACH7B,UAAUiC,IAAAA,2CAA2B,EAAClC,MAAMC,QAAQ,EAAE+B,IAAAA,6BAAkB,EAAC,AAAC7B,CAAAA,UAAU,IAAI,IAAIA,UAAU,KAAK,IAAI,KAAK,IAAIA,MAAM8B,IAAI,AAAD,MAAO,YAAY,AAAC9B,CAAAA,UAAU,IAAI,IAAIA,UAAU,KAAK,IAAI,KAAK,IAAIA,MAAM8B,IAAI,AAAD,MAAO,MAAM9B,MAAM8B,IAAI,GAAG,KAAK,EAAErB,gBAAgBa,mBAAmBvB,2BAA2B4B,oBAAoBC,2BAA2B;IAC9V;AACJ"}
@@ -28,6 +28,3 @@ const _popover = require("./Popover");
28
28
  const _popoverSurface = require("./PopoverSurface");
29
29
  const _popoverContext = require("./popoverContext");
30
30
  const _popoverTrigger = require("./PopoverTrigger");
31
- //# sourceMappingURL=index.js.map
32
-
33
- //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../lib/index.js"],"sourcesContent":["export { Popover, renderPopover_unstable, usePopover_unstable } from './Popover';\nexport { PopoverSurface, arrowHeights, popoverSurfaceClassNames, renderPopoverSurface_unstable, usePopoverSurfaceStyles_unstable, usePopoverSurface_unstable } from './PopoverSurface';\nexport { PopoverProvider, usePopoverContext_unstable } from './popoverContext';\nexport { PopoverTrigger, renderPopoverTrigger_unstable, usePopoverTrigger_unstable } from './PopoverTrigger';\n//# sourceMappingURL=index.js.map"],"names":["Popover","renderPopover_unstable","usePopover_unstable","PopoverSurface","arrowHeights","popoverSurfaceClassNames","renderPopoverSurface_unstable","usePopoverSurfaceStyles_unstable","usePopoverSurface_unstable","PopoverProvider","usePopoverContext_unstable","PopoverTrigger","renderPopoverTrigger_unstable","usePopoverTrigger_unstable"],"mappings":";;;;;;;;;;;IAASA,OAAO,MAAPA,gBAAO;IAAEC,sBAAsB,MAAtBA,+BAAsB;IAAEC,mBAAmB,MAAnBA,4BAAmB;IACpDC,cAAc,MAAdA,8BAAc;IAAEC,YAAY,MAAZA,4BAAY;IAAEC,wBAAwB,MAAxBA,wCAAwB;IAAEC,6BAA6B,MAA7BA,6CAA6B;IAAEC,gCAAgC,MAAhCA,gDAAgC;IAAEC,0BAA0B,MAA1BA,0CAA0B;IACnJC,eAAe,MAAfA,+BAAe;IAAEC,0BAA0B,MAA1BA,0CAA0B;IAC3CC,cAAc,MAAdA,8BAAc;IAAEC,6BAA6B,MAA7BA,6CAA6B;IAAEC,0BAA0B,MAA1BA,0CAA0B;;yBAHb;gCAC+F;gCACxG;gCAC8B;CAC1F,iCAAiC"}
1
+ {"version":3,"sources":["index.js"],"sourcesContent":["export { Popover, renderPopover_unstable, usePopover_unstable } from './Popover';\nexport { PopoverSurface, arrowHeights, popoverSurfaceClassNames, renderPopoverSurface_unstable, usePopoverSurfaceStyles_unstable, usePopoverSurface_unstable } from './PopoverSurface';\nexport { PopoverProvider, usePopoverContext_unstable } from './popoverContext';\nexport { PopoverTrigger, renderPopoverTrigger_unstable, usePopoverTrigger_unstable } from './PopoverTrigger';\n"],"names":["Popover","renderPopover_unstable","usePopover_unstable","PopoverSurface","arrowHeights","popoverSurfaceClassNames","renderPopoverSurface_unstable","usePopoverSurfaceStyles_unstable","usePopoverSurface_unstable","PopoverProvider","usePopoverContext_unstable","PopoverTrigger","renderPopoverTrigger_unstable","usePopoverTrigger_unstable"],"mappings":";;;;;;;;;;;IAASA,OAAO,MAAPA,gBAAO;IAAEC,sBAAsB,MAAtBA,+BAAsB;IAAEC,mBAAmB,MAAnBA,4BAAmB;IACpDC,cAAc,MAAdA,8BAAc;IAAEC,YAAY,MAAZA,4BAAY;IAAEC,wBAAwB,MAAxBA,wCAAwB;IAAEC,6BAA6B,MAA7BA,6CAA6B;IAAEC,gCAAgC,MAAhCA,gDAAgC;IAAEC,0BAA0B,MAA1BA,0CAA0B;IACnJC,eAAe,MAAfA,+BAAe;IAAEC,0BAA0B,MAA1BA,0CAA0B;IAC3CC,cAAc,MAAdA,8BAAc;IAAEC,6BAA6B,MAA7BA,6CAA6B;IAAEC,0BAA0B,MAA1BA,0CAA0B;;yBAHb;gCAC+F;gCACxG;gCAC8B"}
@@ -14,7 +14,7 @@ _export(exports, {
14
14
  usePopoverContext_unstable: ()=>usePopoverContext_unstable
15
15
  });
16
16
  const _reactContextSelector = require("@fluentui/react-context-selector");
17
- const PopoverContext = /*#__PURE__*/ (0, _reactContextSelector.createContext)(undefined);
17
+ const PopoverContext = (0, _reactContextSelector.createContext)(undefined);
18
18
  const popoverContextDefaultValue = {
19
19
  open: false,
20
20
  setOpen: ()=>null,
@@ -35,6 +35,4 @@ const popoverContextDefaultValue = {
35
35
  inline: false
36
36
  };
37
37
  const PopoverProvider = PopoverContext.Provider;
38
- const usePopoverContext_unstable = (selector)=>(0, _reactContextSelector.useContextSelector)(PopoverContext, (ctx = popoverContextDefaultValue)=>selector(ctx)); //# sourceMappingURL=popoverContext.js.map
39
-
40
- //# sourceMappingURL=popoverContext.js.map
38
+ const usePopoverContext_unstable = (selector)=>(0, _reactContextSelector.useContextSelector)(PopoverContext, (ctx = popoverContextDefaultValue)=>selector(ctx));
@@ -1 +1 @@
1
- {"version":3,"sources":["../lib/popoverContext.js"],"sourcesContent":["import { createContext, useContextSelector } from '@fluentui/react-context-selector';\nexport const PopoverContext = /*#__PURE__*/createContext(undefined);\nconst popoverContextDefaultValue = {\n open: false,\n setOpen: () => null,\n toggleOpen: () => null,\n triggerRef: {\n current: null\n },\n contentRef: {\n current: null\n },\n arrowRef: {\n current: null\n },\n openOnContext: false,\n openOnHover: false,\n size: 'medium',\n trapFocus: false,\n inline: false\n};\nexport const PopoverProvider = PopoverContext.Provider;\nexport const usePopoverContext_unstable = selector => useContextSelector(PopoverContext, (ctx = popoverContextDefaultValue) => selector(ctx));\n//# sourceMappingURL=popoverContext.js.map"],"names":["PopoverContext","PopoverProvider","usePopoverContext_unstable","createContext","undefined","popoverContextDefaultValue","open","setOpen","toggleOpen","triggerRef","current","contentRef","arrowRef","openOnContext","openOnHover","size","trapFocus","inline","Provider","selector","useContextSelector","ctx"],"mappings":";;;;;;;;;;;IACaA,cAAc,MAAdA;IAoBAC,eAAe,MAAfA;IACAC,0BAA0B,MAA1BA;;sCAtBqC;AAC3C,MAAMF,iBAAiB,WAAW,GAAEG,IAAAA,mCAAa,EAACC;AACzD,MAAMC,6BAA6B;IACjCC,MAAM,KAAK;IACXC,SAAS,IAAM,IAAI;IACnBC,YAAY,IAAM,IAAI;IACtBC,YAAY;QACVC,SAAS,IAAI;IACf;IACAC,YAAY;QACVD,SAAS,IAAI;IACf;IACAE,UAAU;QACRF,SAAS,IAAI;IACf;IACAG,eAAe,KAAK;IACpBC,aAAa,KAAK;IAClBC,MAAM;IACNC,WAAW,KAAK;IAChBC,QAAQ,KAAK;AACf;AACO,MAAMhB,kBAAkBD,eAAekB,QAAQ;AAC/C,MAAMhB,6BAA6BiB,CAAAA,WAAYC,IAAAA,wCAAkB,EAACpB,gBAAgB,CAACqB,MAAMhB,0BAA0B,GAAKc,SAASE,OACxI,0CAA0C"}
1
+ {"version":3,"sources":["popoverContext.js"],"sourcesContent":["import { createContext, useContextSelector } from '@fluentui/react-context-selector';\nexport const PopoverContext = createContext(undefined);\nconst popoverContextDefaultValue = {\n open: false,\n setOpen: ()=>null,\n toggleOpen: ()=>null,\n triggerRef: {\n current: null\n },\n contentRef: {\n current: null\n },\n arrowRef: {\n current: null\n },\n openOnContext: false,\n openOnHover: false,\n size: 'medium',\n trapFocus: false,\n inline: false\n};\nexport const PopoverProvider = PopoverContext.Provider;\nexport const usePopoverContext_unstable = (selector)=>useContextSelector(PopoverContext, (ctx = popoverContextDefaultValue)=>selector(ctx));\n"],"names":["PopoverContext","PopoverProvider","usePopoverContext_unstable","createContext","undefined","popoverContextDefaultValue","open","setOpen","toggleOpen","triggerRef","current","contentRef","arrowRef","openOnContext","openOnHover","size","trapFocus","inline","Provider","selector","useContextSelector","ctx"],"mappings":";;;;;;;;;;;IACaA,cAAc,MAAdA;IAoBAC,eAAe,MAAfA;IACAC,0BAA0B,MAA1BA;;sCAtBqC;AAC3C,MAAMF,iBAAiBG,IAAAA,mCAAa,EAACC;AAC5C,MAAMC,6BAA6B;IAC/BC,MAAM,KAAK;IACXC,SAAS,IAAI,IAAI;IACjBC,YAAY,IAAI,IAAI;IACpBC,YAAY;QACRC,SAAS,IAAI;IACjB;IACAC,YAAY;QACRD,SAAS,IAAI;IACjB;IACAE,UAAU;QACNF,SAAS,IAAI;IACjB;IACAG,eAAe,KAAK;IACpBC,aAAa,KAAK;IAClBC,MAAM;IACNC,WAAW,KAAK;IAChBC,QAAQ,KAAK;AACjB;AACO,MAAMhB,kBAAkBD,eAAekB,QAAQ;AAC/C,MAAMhB,6BAA6B,CAACiB,WAAWC,IAAAA,wCAAkB,EAACpB,gBAAgB,CAACqB,MAAMhB,0BAA0B,GAAGc,SAASE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui/react-popover",
3
- "version": "9.5.15",
3
+ "version": "9.7.0",
4
4
  "description": "Popover component for Fluent UI",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -30,23 +30,23 @@
30
30
  "devDependencies": {
31
31
  "@fluentui/eslint-plugin": "*",
32
32
  "@fluentui/react-conformance": "*",
33
- "@fluentui/react-conformance-griffel": "9.0.0-beta.21",
33
+ "@fluentui/react-conformance-griffel": "9.0.0-beta.23",
34
34
  "@fluentui/scripts-api-extractor": "*",
35
35
  "@fluentui/scripts-cypress": "*",
36
36
  "@fluentui/scripts-tasks": "*"
37
37
  },
38
38
  "dependencies": {
39
39
  "@fluentui/keyboard-keys": "^9.0.3",
40
- "@fluentui/react-aria": "^9.3.21",
41
- "@fluentui/react-context-selector": "^9.1.21",
42
- "@fluentui/react-portal": "^9.2.11",
43
- "@fluentui/react-positioning": "^9.5.14",
44
- "@fluentui/react-shared-contexts": "^9.5.0",
45
- "@fluentui/react-tabster": "^9.7.4",
46
- "@fluentui/react-theme": "^9.1.8",
47
- "@fluentui/react-utilities": "^9.9.1",
48
- "@fluentui/react-jsx-runtime": "9.0.0-alpha.5",
49
- "@griffel/react": "^1.5.2",
40
+ "@fluentui/react-aria": "^9.3.23",
41
+ "@fluentui/react-context-selector": "^9.1.23",
42
+ "@fluentui/react-portal": "^9.2.13",
43
+ "@fluentui/react-positioning": "^9.7.0",
44
+ "@fluentui/react-shared-contexts": "^9.5.1",
45
+ "@fluentui/react-tabster": "^9.8.0",
46
+ "@fluentui/react-theme": "^9.1.9",
47
+ "@fluentui/react-utilities": "^9.9.3",
48
+ "@fluentui/react-jsx-runtime": "9.0.0-alpha.7",
49
+ "@griffel/react": "^1.5.7",
50
50
  "@swc/helpers": "^0.4.14"
51
51
  },
52
52
  "peerDependencies": {