@fluentui/react-popover 9.8.0 → 9.8.1
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.json +82 -1
- package/CHANGELOG.md +22 -2
- package/lib/components/Popover/Popover.js.map +1 -1
- package/lib/components/Popover/renderPopover.js +1 -1
- package/lib/components/Popover/renderPopover.js.map +1 -1
- package/lib/components/Popover/usePopover.js +9 -7
- package/lib/components/Popover/usePopover.js.map +1 -1
- package/lib/components/PopoverSurface/PopoverSurface.js.map +1 -1
- package/lib/components/PopoverSurface/renderPopoverSurface.js +14 -8
- package/lib/components/PopoverSurface/renderPopoverSurface.js.map +1 -1
- package/lib/components/PopoverSurface/usePopoverSurface.js +8 -6
- package/lib/components/PopoverSurface/usePopoverSurface.js.map +1 -1
- package/lib/components/PopoverTrigger/PopoverTrigger.js.map +1 -1
- package/lib/components/PopoverTrigger/renderPopoverTrigger.js.map +1 -1
- package/lib/components/PopoverTrigger/usePopoverTrigger.js +12 -11
- package/lib/components/PopoverTrigger/usePopoverTrigger.js.map +1 -1
- package/lib/popoverContext.js.map +1 -1
- package/lib-commonjs/Popover.js +2 -2
- package/lib-commonjs/Popover.js.map +1 -1
- package/lib-commonjs/PopoverSurface.js +2 -2
- package/lib-commonjs/PopoverSurface.js.map +1 -1
- package/lib-commonjs/PopoverTrigger.js +2 -2
- package/lib-commonjs/PopoverTrigger.js.map +1 -1
- package/lib-commonjs/components/Popover/Popover.js +5 -3
- package/lib-commonjs/components/Popover/Popover.js.map +1 -1
- package/lib-commonjs/components/Popover/Popover.types.js +2 -2
- package/lib-commonjs/components/Popover/Popover.types.js.map +1 -1
- package/lib-commonjs/components/Popover/constants.js +3 -1
- package/lib-commonjs/components/Popover/constants.js.map +1 -1
- package/lib-commonjs/components/Popover/index.js +5 -5
- package/lib-commonjs/components/Popover/index.js.map +1 -1
- package/lib-commonjs/components/Popover/renderPopover.js +6 -4
- package/lib-commonjs/components/Popover/renderPopover.js.map +1 -1
- package/lib-commonjs/components/Popover/usePopover.js +29 -25
- package/lib-commonjs/components/Popover/usePopover.js.map +1 -1
- package/lib-commonjs/components/PopoverSurface/PopoverSurface.js +9 -7
- package/lib-commonjs/components/PopoverSurface/PopoverSurface.js.map +1 -1
- package/lib-commonjs/components/PopoverSurface/index.js +6 -6
- package/lib-commonjs/components/PopoverSurface/index.js.map +1 -1
- package/lib-commonjs/components/PopoverSurface/renderPopoverSurface.js +21 -13
- package/lib-commonjs/components/PopoverSurface/renderPopoverSurface.js.map +1 -1
- package/lib-commonjs/components/PopoverSurface/usePopoverSurface.js +17 -13
- package/lib-commonjs/components/PopoverSurface/usePopoverSurface.js.map +1 -1
- package/lib-commonjs/components/PopoverSurface/usePopoverSurfaceStyles.styles.js +10 -4
- package/lib-commonjs/components/PopoverSurface/usePopoverSurfaceStyles.styles.js.map +1 -1
- package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.js +5 -3
- package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.js.map +1 -1
- package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.types.js +2 -2
- package/lib-commonjs/components/PopoverTrigger/PopoverTrigger.types.js.map +1 -1
- package/lib-commonjs/components/PopoverTrigger/index.js +5 -5
- package/lib-commonjs/components/PopoverTrigger/index.js.map +1 -1
- package/lib-commonjs/components/PopoverTrigger/renderPopoverTrigger.js +3 -1
- package/lib-commonjs/components/PopoverTrigger/renderPopoverTrigger.js.map +1 -1
- package/lib-commonjs/components/PopoverTrigger/usePopoverTrigger.js +23 -20
- package/lib-commonjs/components/PopoverTrigger/usePopoverTrigger.js.map +1 -1
- package/lib-commonjs/index.js +45 -17
- package/lib-commonjs/index.js.map +1 -1
- package/lib-commonjs/popoverContext.js +12 -6
- package/lib-commonjs/popoverContext.js.map +1 -1
- package/package.json +16 -16
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["usePopoverSurfaceStyles.styles.js"],"sourcesContent":["import { shorthands, __styles, mergeClasses } from '@griffel/react';\nimport { createArrowHeightStyles, createArrowStyles, createSlideStyles } from '@fluentui/react-positioning';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const popoverSurfaceClassNames = {\n root: 'fui-PopoverSurface'\n};\nexport const arrowHeights = {\n small: 6,\n medium: 8,\n large: 8\n};\n/**\n * Styles for the root slot\n */\nconst useStyles = /*#__PURE__*/__styles({\n root: {\n sj55zd: \"f19n0e5\",\n De3pzq: \"fxugw4r\",\n E5pizo: \"f1hg901r\",\n Bbmb7ep: [\"f1aa9q02\", \"f16jpd5f\"],\n Beyfa6y: [\"f16jpd5f\", \"f1aa9q02\"],\n B7oj6ja: [\"f1jar5jt\", \"fyu767a\"],\n Btl43ni: [\"fyu767a\", \"f1jar5jt\"],\n B4j52fo: \"f5ogflp\",\n Bekrc4i: [\"f1hqa2wf\", \"finvdd3\"],\n Bn0qgzm: \"f1f09k3d\",\n ibv6hh: [\"finvdd3\", \"f1hqa2wf\"],\n icvyot: \"fzkkow9\",\n vrafjx: [\"fcdblym\", \"fjik90z\"],\n oivjwe: \"fg706s2\",\n wvpqe5: [\"fjik90z\", \"fcdblym\"],\n g2u3we: \"fghlq4f\",\n h3c5rm: [\"f1gn591s\", \"fjscplz\"],\n B9xav0g: \"fb073pr\",\n zhjwy3: [\"fjscplz\", \"f1gn591s\"],\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\",\n B93otf3: \"f18k4bn6\",\n vin17d: \"fo1kyvf\",\n Ezkn3b: \"fetxo7e\",\n ex8oj8: \"fmm77a6\",\n Bksk4gw: \"f12t24nk\",\n Bc5phfd: \"f1babd7\",\n cbiifc: \"f1jgo889\",\n fyiq5g: \"f1ij1pew\",\n Bqc19t1: \"f1gu8pa9\",\n Eet2gb: \"fhfnl4n\",\n Bhl7k63: \"fk8tkmz\",\n Bv12yb3: \"f3n0535\",\n z0t1cu: \"fi19xcv\",\n Bks05zx: \"f1mzajhk\",\n Bvtglag: \"fjp4h9y\"\n },\n inverted: {\n De3pzq: \"fg3r6xk\",\n sj55zd: \"fonrgv7\"\n },\n brand: {\n De3pzq: \"ffp7eso\",\n sj55zd: \"f1phragk\"\n },\n smallPadding: {\n z8tnut: \"f1kcqot9\",\n z189sj: [\"f11qrl6u\", \"fjlbh76\"],\n Byoj8tv: \"fpe6lb7\",\n uwmqm3: [\"fjlbh76\", \"f11qrl6u\"]\n },\n mediumPadding: {\n z8tnut: \"fqag9an\",\n z189sj: [\"f1gbmcue\", \"f1rh9g5y\"],\n Byoj8tv: \"fp67ikv\",\n uwmqm3: [\"f1rh9g5y\", \"f1gbmcue\"]\n },\n largePadding: {\n z8tnut: \"fc7z3ec\",\n z189sj: [\"fat0sn4\", \"fekwl8i\"],\n Byoj8tv: \"fe2my4m\",\n uwmqm3: [\"fekwl8i\", \"fat0sn4\"]\n },\n smallArrow: {\n a9b677: \"f1ekdpwm\",\n Bqenvij: \"f83vc9z\"\n },\n mediumLargeArrow: {\n a9b677: \"f1kmc0fn\",\n Bqenvij: \"fb6lvc5\"\n },\n arrow: {\n qhf8xq: \"f1euv43f\",\n De3pzq: \"f1u2r49w\",\n Bcdw1i0: \"fd7fpy0\",\n Bj3rh1h: \"f1bsuimh\",\n Ftih45: \"f1wl9k8s\",\n B1puzpu: \"f1wkw4r9\",\n Brfgrao: \"f1j7ml58\",\n Bcvre1j: \"fyl8oag\",\n Ccq8qp: \"frdoeuz\",\n Baz25je: \"fb81m9q\",\n cmx5o7: \"f1ljr5q2\",\n B4f6apu: \"fyfemzf\",\n m598lv: \"focyt6c\",\n Bk5zm6e: \"fnhxbxj\",\n y0oebl: \"fdw6hkg\",\n qa3bma: \"f11yjt3y\",\n Bqjgrrk: \"f1172wan\",\n Budzafs: [\"f9e5op9\", \"f112wvtl\"],\n Hv9wc6: [\"ftj5xct\", \"fyavhwi\"],\n hl6cv3: \"f1773hnp\",\n Bh2vraf: \"f1n8855c\",\n yayu3t: \"f1v7783n\",\n wedwtw: \"fsw6im5\",\n rhl9o9: \"fh2hsk5\",\n Bu8t5uz: \"f159pzir\",\n B6q6orb: \"f11yvu4\",\n Bwwlvwl: \"fm1ycve\"\n }\n}, {\n d: [\".f19n0e5{color:var(--colorNeutralForeground1);}\", \".fxugw4r{background-color:var(--colorNeutralBackground1);}\", \".f1hg901r{box-shadow:var(--shadow16);}\", \".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}\", \".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}\", \".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}\", \".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}\", \".f5ogflp{border-top-width:1px;}\", \".f1hqa2wf{border-right-width:1px;}\", \".finvdd3{border-left-width:1px;}\", \".f1f09k3d{border-bottom-width:1px;}\", \".fzkkow9{border-top-style:solid;}\", \".fcdblym{border-right-style:solid;}\", \".fjik90z{border-left-style:solid;}\", \".fg706s2{border-bottom-style:solid;}\", \".fghlq4f{border-top-color:var(--colorTransparentStroke);}\", \".f1gn591s{border-right-color:var(--colorTransparentStroke);}\", \".fjscplz{border-left-color:var(--colorTransparentStroke);}\", \".fb073pr{border-bottom-color:var(--colorTransparentStroke);}\", \".fk6fouc{font-family:var(--fontFamilyBase);}\", \".fkhj508{font-size:var(--fontSizeBase300);}\", \".figsok6{font-weight:var(--fontWeightRegular);}\", \".f1i3iumi{line-height:var(--lineHeightBase300);}\", \".f18k4bn6{animation-composition:accumulate;}\", \".fo1kyvf{animation-duration:var(--durationSlower);}\", \".fetxo7e{animation-timing-function:var(--curveDecelerateMid);}\", \".fmm77a6{--slide-distance-x:0px;}\", \".f12t24nk{--slide-distance-y:10px;}\", \".f1babd7[data-popper-placement^=right]{--slide-distance-x:-10px;}\", \".f1jgo889[data-popper-placement^=right]{--slide-distance-y:0px;}\", \".f1ij1pew[data-popper-placement^=bottom]{--slide-distance-x:0px;}\", \".f1gu8pa9[data-popper-placement^=bottom]{--slide-distance-y:-10px;}\", \".fhfnl4n[data-popper-placement^=left]{--slide-distance-x:10px;}\", \".fk8tkmz[data-popper-placement^=left]{--slide-distance-y:0px;}\", \".f3n0535{animation-name:f5j8bii,fld5wjx;}\", \".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}\", \".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}\", \".ffp7eso{background-color:var(--colorBrandBackground);}\", \".f1phragk{color:var(--colorNeutralForegroundOnBrand);}\", \".f1kcqot9{padding-top:12px;}\", \".f11qrl6u{padding-right:12px;}\", \".fjlbh76{padding-left:12px;}\", \".fpe6lb7{padding-bottom:12px;}\", \".fqag9an{padding-top:16px;}\", \".f1gbmcue{padding-right:16px;}\", \".f1rh9g5y{padding-left:16px;}\", \".fp67ikv{padding-bottom:16px;}\", \".fc7z3ec{padding-top:20px;}\", \".fat0sn4{padding-right:20px;}\", \".fekwl8i{padding-left:20px;}\", \".fe2my4m{padding-bottom:20px;}\", \".f1ekdpwm{width:8.484px;}\", \".f83vc9z{height:8.484px;}\", \".f1kmc0fn{width:11.312px;}\", \".fb6lvc5{height:11.312px;}\", \".f1euv43f{position:absolute;}\", \".f1u2r49w{background-color:inherit;}\", \".fd7fpy0{visibility:hidden;}\", \".f1bsuimh{z-index:-1;}\", \".f1wl9k8s::before{content:\\\"\\\";}\", \".f1wkw4r9::before{visibility:visible;}\", \".f1j7ml58::before{position:absolute;}\", \".fyl8oag::before{box-sizing:border-box;}\", \".frdoeuz::before{width:inherit;}\", \".fb81m9q::before{height:inherit;}\", \".f1ljr5q2::before{background-color:inherit;}\", \".fyfemzf::before{border-right-width:1px;}\", \".focyt6c::before{border-right-style:solid;}\", \".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}\", \".fdw6hkg::before{border-bottom-width:1px;}\", \".f11yjt3y::before{border-bottom-style:solid;}\", \".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}\", \".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}\", \".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}\", \".ftj5xct::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}\", \".fyavhwi::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}\", \"[data-popper-placement^=\\\"top\\\"] .f1773hnp{bottom:-1px;}\", \"[data-popper-placement^=\\\"top\\\"] .f1n8855c{--angle:0;}\", \"[data-popper-placement^=\\\"right\\\"] .f1v7783n{left:-1px;}\", \"[data-popper-placement^=\\\"right\\\"] .fsw6im5{--angle:90deg;}\", \"[data-popper-placement^=\\\"bottom\\\"] .fh2hsk5{top:-1px;}\", \"[data-popper-placement^=\\\"bottom\\\"] .f159pzir{--angle:180deg;}\", \"[data-popper-placement^=\\\"left\\\"] .f11yvu4{right:-1px;}\", \"[data-popper-placement^=\\\"left\\\"] .fm1ycve{--angle:270deg;}\"],\n k: [\"@keyframes f5j8bii{from{opacity:0;}to{opacity:1;}}\", \"@keyframes fld5wjx{from{transform:translate(var(--slide-distance-x), var(--slide-distance-y));}}\"],\n m: [[\"@media (prefers-reduced-motion){.fi19xcv[data-popper-placement]{animation-duration:1ms;}}\", {\n m: \"(prefers-reduced-motion)\"\n }], [\"@media (prefers-reduced-motion){.f1mzajhk[data-popper-placement]{animation-name:f5j8bii;}}\", {\n m: \"(prefers-reduced-motion)\"\n }]],\n t: [\"@supports not (animation-composition: accumulate){.fjp4h9y[data-popper-placement]{animation-name:f5j8bii;}}\"]\n});\n/**\n * Apply styling to the PopoverSurface slots based on the state\n */\nexport const usePopoverSurfaceStyles_unstable = state => {\n const styles = useStyles();\n state.root.className = mergeClasses(popoverSurfaceClassNames.root, styles.root, state.size === 'small' && styles.smallPadding, state.size === 'medium' && styles.mediumPadding, state.size === 'large' && styles.largePadding, state.appearance === 'inverted' && styles.inverted, state.appearance === 'brand' && styles.brand, state.root.className);\n state.arrowClassName = mergeClasses(styles.arrow, state.size === 'small' ? styles.smallArrow : styles.mediumLargeArrow);\n return state;\n};\n//# sourceMappingURL=usePopoverSurfaceStyles.styles.js.map"],"names":["popoverSurfaceClassNames","arrowHeights","usePopoverSurfaceStyles_unstable","root","small","medium","large","useStyles","__styles","sj55zd","De3pzq","E5pizo","Bbmb7ep","Beyfa6y","B7oj6ja","Btl43ni","B4j52fo","Bekrc4i","Bn0qgzm","ibv6hh","icvyot","vrafjx","oivjwe","wvpqe5","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","B93otf3","vin17d","Ezkn3b","ex8oj8","Bksk4gw","Bc5phfd","cbiifc","fyiq5g","Bqc19t1","Eet2gb","Bhl7k63","Bv12yb3","z0t1cu","Bks05zx","Bvtglag","inverted","brand","smallPadding","z8tnut","z189sj","Byoj8tv","uwmqm3","mediumPadding","largePadding","smallArrow","a9b677","Bqenvij","mediumLargeArrow","arrow","qhf8xq","Bcdw1i0","Bj3rh1h","Ftih45","B1puzpu","Brfgrao","Bcvre1j","Ccq8qp","Baz25je","cmx5o7","B4f6apu","m598lv","Bk5zm6e","y0oebl","qa3bma","Bqjgrrk","Budzafs","Hv9wc6","hl6cv3","Bh2vraf","yayu3t","wedwtw","rhl9o9","Bu8t5uz","B6q6orb","Bwwlvwl","d","k","m","t","state","styles","className","mergeClasses","size","appearance","arrowClassName"],"mappings":";;;;;;;;;;;IAGaA,wBAAwB,MAAxBA;IAGAC,YAAY,MAAZA;IA6HAC,gCAAgC,MAAhCA;;uBAnIsC;AAG5C,MAAMF,2BAA2B;IACtCG,MAAM;AACR;AACO,MAAMF,eAAe;IAC1BG,OAAO;IACPC,QAAQ;IACRC,OAAO;AACT;AACA;;CAEC,GACD,MAAMC,YAAY,WAAW,GAAEC,IAAAA,kBAAQ,EAAC;IACtCL,MAAM;QACJM,QAAQ;QACRC,QAAQ;QACRC,QAAQ;QACRC,SAAS;YAAC;YAAY;SAAW;QACjCC,SAAS;YAAC;YAAY;SAAW;QACjCC,SAAS;YAAC;YAAY;SAAU;QAChCC,SAAS;YAAC;YAAW;SAAW;QAChCC,SAAS;QACTC,SAAS;YAAC;YA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AEqC,MAAMI,IAAI,KAAK,WAAWH,OAAOrC,YAAY,EAAEoC,MAAMK,UAAU,KAAK,cAAcJ,OAAO7C,QAAQ,EAAE4C,MAAMK,UAAU,KAAK,WAAWJ,OAAO5C,KAAK,EAAE2C,MAAMxF,IAAI,CAAC0F,SAAS;IACrVF,MAAMM,cAAc,GAAGH,IAAAA,mBAAY,EAACF,OAAOhC,KAAK,EAAE+B,MAAMI,IAAI,KAAK,UAAUH,OAAOpC,UAAU,GAAGoC,OAAOjC,gBAAgB;IACtH,OAAOgC;AACT,GACA,0DAA0D"}
|
1
|
+
{"version":3,"sources":["usePopoverSurfaceStyles.styles.js"],"sourcesContent":["import { shorthands, __styles, mergeClasses } from '@griffel/react';\nimport { createArrowHeightStyles, createArrowStyles, createSlideStyles } from '@fluentui/react-positioning';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const popoverSurfaceClassNames = {\n root: 'fui-PopoverSurface'\n};\nexport const arrowHeights = {\n small: 6,\n medium: 8,\n large: 8\n};\n/**\n * Styles for the root slot\n */\nconst useStyles = /*#__PURE__*/__styles({\n root: {\n sj55zd: \"f19n0e5\",\n De3pzq: \"fxugw4r\",\n E5pizo: \"f1hg901r\",\n Bbmb7ep: [\"f1aa9q02\", \"f16jpd5f\"],\n Beyfa6y: [\"f16jpd5f\", \"f1aa9q02\"],\n B7oj6ja: [\"f1jar5jt\", \"fyu767a\"],\n Btl43ni: [\"fyu767a\", \"f1jar5jt\"],\n B4j52fo: \"f5ogflp\",\n Bekrc4i: [\"f1hqa2wf\", \"finvdd3\"],\n Bn0qgzm: \"f1f09k3d\",\n ibv6hh: [\"finvdd3\", \"f1hqa2wf\"],\n icvyot: \"fzkkow9\",\n vrafjx: [\"fcdblym\", \"fjik90z\"],\n oivjwe: \"fg706s2\",\n wvpqe5: [\"fjik90z\", \"fcdblym\"],\n g2u3we: \"fghlq4f\",\n h3c5rm: [\"f1gn591s\", \"fjscplz\"],\n B9xav0g: \"fb073pr\",\n zhjwy3: [\"fjscplz\", \"f1gn591s\"],\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\",\n B93otf3: \"f18k4bn6\",\n vin17d: \"fo1kyvf\",\n Ezkn3b: \"fetxo7e\",\n ex8oj8: \"fmm77a6\",\n Bksk4gw: \"f12t24nk\",\n Bc5phfd: \"f1babd7\",\n cbiifc: \"f1jgo889\",\n fyiq5g: \"f1ij1pew\",\n Bqc19t1: \"f1gu8pa9\",\n Eet2gb: \"fhfnl4n\",\n Bhl7k63: \"fk8tkmz\",\n Bv12yb3: \"f3n0535\",\n z0t1cu: \"fi19xcv\",\n Bks05zx: \"f1mzajhk\",\n Bvtglag: \"fjp4h9y\"\n },\n inverted: {\n De3pzq: \"fg3r6xk\",\n sj55zd: \"fonrgv7\"\n },\n brand: {\n De3pzq: \"ffp7eso\",\n sj55zd: \"f1phragk\"\n },\n smallPadding: {\n z8tnut: \"f1kcqot9\",\n z189sj: [\"f11qrl6u\", \"fjlbh76\"],\n Byoj8tv: \"fpe6lb7\",\n uwmqm3: [\"fjlbh76\", \"f11qrl6u\"]\n },\n mediumPadding: {\n z8tnut: \"fqag9an\",\n z189sj: [\"f1gbmcue\", \"f1rh9g5y\"],\n Byoj8tv: \"fp67ikv\",\n uwmqm3: [\"f1rh9g5y\", \"f1gbmcue\"]\n },\n largePadding: {\n z8tnut: \"fc7z3ec\",\n z189sj: [\"fat0sn4\", \"fekwl8i\"],\n Byoj8tv: \"fe2my4m\",\n uwmqm3: [\"fekwl8i\", \"fat0sn4\"]\n },\n smallArrow: {\n a9b677: \"f1ekdpwm\",\n Bqenvij: \"f83vc9z\"\n },\n mediumLargeArrow: {\n a9b677: \"f1kmc0fn\",\n Bqenvij: \"fb6lvc5\"\n },\n arrow: {\n qhf8xq: \"f1euv43f\",\n De3pzq: \"f1u2r49w\",\n Bcdw1i0: \"fd7fpy0\",\n Bj3rh1h: \"f1bsuimh\",\n Ftih45: \"f1wl9k8s\",\n B1puzpu: \"f1wkw4r9\",\n Brfgrao: \"f1j7ml58\",\n Bcvre1j: \"fyl8oag\",\n Ccq8qp: \"frdoeuz\",\n Baz25je: \"fb81m9q\",\n cmx5o7: \"f1ljr5q2\",\n B4f6apu: \"fyfemzf\",\n m598lv: \"focyt6c\",\n Bk5zm6e: \"fnhxbxj\",\n y0oebl: \"fdw6hkg\",\n qa3bma: \"f11yjt3y\",\n Bqjgrrk: \"f1172wan\",\n Budzafs: [\"f9e5op9\", \"f112wvtl\"],\n Hv9wc6: [\"ftj5xct\", \"fyavhwi\"],\n hl6cv3: \"f1773hnp\",\n Bh2vraf: \"f1n8855c\",\n yayu3t: \"f1v7783n\",\n wedwtw: \"fsw6im5\",\n rhl9o9: \"fh2hsk5\",\n Bu8t5uz: \"f159pzir\",\n B6q6orb: \"f11yvu4\",\n Bwwlvwl: \"fm1ycve\"\n }\n}, {\n d: [\".f19n0e5{color:var(--colorNeutralForeground1);}\", \".fxugw4r{background-color:var(--colorNeutralBackground1);}\", \".f1hg901r{box-shadow:var(--shadow16);}\", \".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}\", \".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}\", \".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}\", \".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}\", \".f5ogflp{border-top-width:1px;}\", \".f1hqa2wf{border-right-width:1px;}\", \".finvdd3{border-left-width:1px;}\", \".f1f09k3d{border-bottom-width:1px;}\", \".fzkkow9{border-top-style:solid;}\", \".fcdblym{border-right-style:solid;}\", \".fjik90z{border-left-style:solid;}\", \".fg706s2{border-bottom-style:solid;}\", \".fghlq4f{border-top-color:var(--colorTransparentStroke);}\", \".f1gn591s{border-right-color:var(--colorTransparentStroke);}\", \".fjscplz{border-left-color:var(--colorTransparentStroke);}\", \".fb073pr{border-bottom-color:var(--colorTransparentStroke);}\", \".fk6fouc{font-family:var(--fontFamilyBase);}\", \".fkhj508{font-size:var(--fontSizeBase300);}\", \".figsok6{font-weight:var(--fontWeightRegular);}\", \".f1i3iumi{line-height:var(--lineHeightBase300);}\", \".f18k4bn6{animation-composition:accumulate;}\", \".fo1kyvf{animation-duration:var(--durationSlower);}\", \".fetxo7e{animation-timing-function:var(--curveDecelerateMid);}\", \".fmm77a6{--slide-distance-x:0px;}\", \".f12t24nk{--slide-distance-y:10px;}\", \".f1babd7[data-popper-placement^=right]{--slide-distance-x:-10px;}\", \".f1jgo889[data-popper-placement^=right]{--slide-distance-y:0px;}\", \".f1ij1pew[data-popper-placement^=bottom]{--slide-distance-x:0px;}\", \".f1gu8pa9[data-popper-placement^=bottom]{--slide-distance-y:-10px;}\", \".fhfnl4n[data-popper-placement^=left]{--slide-distance-x:10px;}\", \".fk8tkmz[data-popper-placement^=left]{--slide-distance-y:0px;}\", \".f3n0535{animation-name:f5j8bii,fld5wjx;}\", \".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}\", \".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}\", \".ffp7eso{background-color:var(--colorBrandBackground);}\", \".f1phragk{color:var(--colorNeutralForegroundOnBrand);}\", \".f1kcqot9{padding-top:12px;}\", \".f11qrl6u{padding-right:12px;}\", \".fjlbh76{padding-left:12px;}\", \".fpe6lb7{padding-bottom:12px;}\", \".fqag9an{padding-top:16px;}\", \".f1gbmcue{padding-right:16px;}\", \".f1rh9g5y{padding-left:16px;}\", \".fp67ikv{padding-bottom:16px;}\", \".fc7z3ec{padding-top:20px;}\", \".fat0sn4{padding-right:20px;}\", \".fekwl8i{padding-left:20px;}\", \".fe2my4m{padding-bottom:20px;}\", \".f1ekdpwm{width:8.484px;}\", \".f83vc9z{height:8.484px;}\", \".f1kmc0fn{width:11.312px;}\", \".fb6lvc5{height:11.312px;}\", \".f1euv43f{position:absolute;}\", \".f1u2r49w{background-color:inherit;}\", \".fd7fpy0{visibility:hidden;}\", \".f1bsuimh{z-index:-1;}\", \".f1wl9k8s::before{content:\\\"\\\";}\", \".f1wkw4r9::before{visibility:visible;}\", \".f1j7ml58::before{position:absolute;}\", \".fyl8oag::before{box-sizing:border-box;}\", \".frdoeuz::before{width:inherit;}\", \".fb81m9q::before{height:inherit;}\", \".f1ljr5q2::before{background-color:inherit;}\", \".fyfemzf::before{border-right-width:1px;}\", \".focyt6c::before{border-right-style:solid;}\", \".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}\", \".fdw6hkg::before{border-bottom-width:1px;}\", \".f11yjt3y::before{border-bottom-style:solid;}\", \".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}\", \".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}\", \".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}\", \".ftj5xct::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}\", \".fyavhwi::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}\", \"[data-popper-placement^=\\\"top\\\"] .f1773hnp{bottom:-1px;}\", \"[data-popper-placement^=\\\"top\\\"] .f1n8855c{--angle:0;}\", \"[data-popper-placement^=\\\"right\\\"] .f1v7783n{left:-1px;}\", \"[data-popper-placement^=\\\"right\\\"] .fsw6im5{--angle:90deg;}\", \"[data-popper-placement^=\\\"bottom\\\"] .fh2hsk5{top:-1px;}\", \"[data-popper-placement^=\\\"bottom\\\"] .f159pzir{--angle:180deg;}\", \"[data-popper-placement^=\\\"left\\\"] .f11yvu4{right:-1px;}\", \"[data-popper-placement^=\\\"left\\\"] .fm1ycve{--angle:270deg;}\"],\n k: [\"@keyframes f5j8bii{from{opacity:0;}to{opacity:1;}}\", \"@keyframes fld5wjx{from{transform:translate(var(--slide-distance-x), var(--slide-distance-y));}}\"],\n m: [[\"@media (prefers-reduced-motion){.fi19xcv[data-popper-placement]{animation-duration:1ms;}}\", {\n m: \"(prefers-reduced-motion)\"\n }], [\"@media (prefers-reduced-motion){.f1mzajhk[data-popper-placement]{animation-name:f5j8bii;}}\", {\n m: \"(prefers-reduced-motion)\"\n }]],\n t: [\"@supports not (animation-composition: accumulate){.fjp4h9y[data-popper-placement]{animation-name:f5j8bii;}}\"]\n});\n/**\n * Apply styling to the PopoverSurface slots based on the state\n */\nexport const usePopoverSurfaceStyles_unstable = state => {\n const styles = useStyles();\n state.root.className = mergeClasses(popoverSurfaceClassNames.root, styles.root, state.size === 'small' && styles.smallPadding, state.size === 'medium' && styles.mediumPadding, state.size === 'large' && styles.largePadding, state.appearance === 'inverted' && styles.inverted, state.appearance === 'brand' && styles.brand, state.root.className);\n state.arrowClassName = mergeClasses(styles.arrow, state.size === 'small' ? styles.smallArrow : styles.mediumLargeArrow);\n return state;\n};\n//# sourceMappingURL=usePopoverSurfaceStyles.styles.js.map"],"names":["popoverSurfaceClassNames","arrowHeights","usePopoverSurfaceStyles_unstable","root","small","medium","large","useStyles","__styles","sj55zd","De3pzq","E5pizo","Bbmb7ep","Beyfa6y","B7oj6ja","Btl43ni","B4j52fo","Bekrc4i","Bn0qgzm","ibv6hh","icvyot","vrafjx","oivjwe","wvpqe5","g2u3we","h3c5rm","B9xav0g","zhjwy3","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","B93otf3","vin17d","Ezkn3b","ex8oj8","Bksk4gw","Bc5phfd","cbiifc","fyiq5g","Bqc19t1","Eet2gb","Bhl7k63","Bv12yb3","z0t1cu","Bks05zx","Bvtglag","inverted","brand","smallPadding","z8tnut","z189sj","Byoj8tv","uwmqm3","mediumPadding","largePadding","smallArrow","a9b677","Bqenvij","mediumLargeArrow","arrow","qhf8xq","Bcdw1i0","Bj3rh1h","Ftih45","B1puzpu","Brfgrao","Bcvre1j","Ccq8qp","Baz25je","cmx5o7","B4f6apu","m598lv","Bk5zm6e","y0oebl","qa3bma","Bqjgrrk","Budzafs","Hv9wc6","hl6cv3","Bh2vraf","yayu3t","wedwtw","rhl9o9","Bu8t5uz","B6q6orb","Bwwlvwl","d","k","m","t","state","styles","className","mergeClasses","size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AA4D;QAA0D;QAA4D;QAA+D;QAA2D;QAAkE;QAA2D;KAA8D;IACzlIC,GAAG;QAAC;QAAsD;KAAmG;IAC7JC,GAAG;QAAC;YAAC;YAA6F;gBAChGA,GAAG;YACL;SAAE;QAAE;YAAC;YAA8F;gBACjGA,GAAG;YACL;SAAE;KAAC;IACHC,GAAG;QAAC;KAA8G;AACpH;AAIO,MAAMxF,mCAAmCyF,CAAAA;IAC9C,MAAMC,SAASrF;IACfoF,MAAMxF,IAAI,CAAC0F,SAAS,GAAGC,IAAAA,mBAAY,EAAC9F,yBAAyBG,IAAI,EAAEyF,OAAOzF,IAAI,EAAEwF,MAAMI,IAAI,KAAK,WAAWH,OAAO3C,YAAY,EAAE0C,MAAMI,IAAI,KAAK,YAAYH,OAAOtC,aAAa,EAAEqC,MAAMI,IAAI,KAAK,WAAWH,OAAOrC,YAAY,EAAEoC,MAAMK,UAAU,KAAK,cAAcJ,OAAO7C,QAAQ,EAAE4C,MAAMK,UAAU,KAAK,WAAWJ,OAAO5C,KAAK,EAAE2C,MAAMxF,IAAI,CAAC0F,SAAS;IACrVF,MAAMM,cAAc,GAAGH,IAAAA,mBAAY,EAACF,OAAOhC,KAAK,EAAE+B,MAAMI,IAAI,KAAK,UAAUH,OAAOpC,UAAU,GAAGoC,OAAOjC,gBAAgB;IACtH,OAAOgC;AACT,GACA,0DAA0D"}
|
@@ -4,10 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
});
|
5
5
|
Object.defineProperty(exports, "PopoverTrigger", {
|
6
6
|
enumerable: true,
|
7
|
-
get: ()
|
7
|
+
get: function() {
|
8
|
+
return PopoverTrigger;
|
9
|
+
}
|
8
10
|
});
|
9
|
-
const
|
10
|
-
const _react = /*#__PURE__*/
|
11
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
11
13
|
const _usePopoverTrigger = require("./usePopoverTrigger");
|
12
14
|
const _renderPopoverTrigger = require("./renderPopoverTrigger");
|
13
15
|
const PopoverTrigger = (props)=>{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["PopoverTrigger.js"],"sourcesContent":["import * as React from 'react';\nimport { usePopoverTrigger_unstable } from './usePopoverTrigger';\nimport { renderPopoverTrigger_unstable } from './renderPopoverTrigger';\n/**\n * Wraps a trigger element as an only child and adds the necessary event handling to open a popover.\n */ export const PopoverTrigger = (props)=>{\n const state = usePopoverTrigger_unstable(props);\n return renderPopoverTrigger_unstable(state);\n};\nPopoverTrigger.displayName = 'PopoverTrigger';\n// type casting here is required to ensure internal type FluentTriggerComponent is not leaked\nPopoverTrigger.isFluentTriggerComponent = true;\n"],"names":["PopoverTrigger","props","state","usePopoverTrigger_unstable","renderPopoverTrigger_unstable","displayName","isFluentTriggerComponent"],"mappings":";;;;+BAKiBA
|
1
|
+
{"version":3,"sources":["PopoverTrigger.js"],"sourcesContent":["import * as React from 'react';\nimport { usePopoverTrigger_unstable } from './usePopoverTrigger';\nimport { renderPopoverTrigger_unstable } from './renderPopoverTrigger';\n/**\n * Wraps a trigger element as an only child and adds the necessary event handling to open a popover.\n */ export const PopoverTrigger = (props)=>{\n const state = usePopoverTrigger_unstable(props);\n return renderPopoverTrigger_unstable(state);\n};\nPopoverTrigger.displayName = 'PopoverTrigger';\n// type casting here is required to ensure internal type FluentTriggerComponent is not leaked\nPopoverTrigger.isFluentTriggerComponent = true;\n"],"names":["PopoverTrigger","props","state","usePopoverTrigger_unstable","renderPopoverTrigger_unstable","displayName","isFluentTriggerComponent"],"mappings":";;;;+BAKiBA;;;eAAAA;;;;iEALM;mCACoB;sCACG;AAGnC,MAAMA,iBAAiB,CAACC;IAC/B,MAAMC,QAAQC,IAAAA,6CAA0B,EAACF;IACzC,OAAOG,IAAAA,mDAA6B,EAACF;AACzC;AACAF,eAAeK,WAAW,GAAG;AAC7B,6FAA6F;AAC7FL,eAAeM,wBAAwB,GAAG"}
|
@@ -2,5 +2,5 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
3
3
|
value: true
|
4
4
|
});
|
5
|
-
const
|
6
|
-
const _react = /*#__PURE__*/
|
5
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
6
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["PopoverTrigger.types.js"],"sourcesContent":["import * as React from 'react';\n"],"names":[],"mappings":";;;;;
|
1
|
+
{"version":3,"sources":["PopoverTrigger.types.js"],"sourcesContent":["import * as React from 'react';\n"],"names":[],"mappings":";;;;;iEAAuB"}
|
@@ -2,8 +2,8 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
3
3
|
value: true
|
4
4
|
});
|
5
|
-
const
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
5
|
+
const _export_star = require("@swc/helpers/_/_export_star");
|
6
|
+
_export_star._(require("./PopoverTrigger"), exports);
|
7
|
+
_export_star._(require("./PopoverTrigger.types"), exports);
|
8
|
+
_export_star._(require("./renderPopoverTrigger"), exports);
|
9
|
+
_export_star._(require("./usePopoverTrigger"), exports);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './PopoverTrigger';\nexport * from './PopoverTrigger.types';\nexport * from './renderPopoverTrigger';\nexport * from './usePopoverTrigger';\n"],"names":[],"mappings":";;;;;
|
1
|
+
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './PopoverTrigger';\nexport * from './PopoverTrigger.types';\nexport * from './renderPopoverTrigger';\nexport * from './usePopoverTrigger';\n"],"names":[],"mappings":";;;;;uBAAc;uBACA;uBACA;uBACA"}
|
@@ -6,7 +6,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
});
|
7
7
|
Object.defineProperty(exports, "renderPopoverTrigger_unstable", {
|
8
8
|
enumerable: true,
|
9
|
-
get: ()
|
9
|
+
get: function() {
|
10
|
+
return renderPopoverTrigger_unstable;
|
11
|
+
}
|
10
12
|
});
|
11
13
|
const renderPopoverTrigger_unstable = (state)=>{
|
12
14
|
return state.children;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["renderPopoverTrigger.js"],"sourcesContent":["/**\n * Render the final JSX of PopoverTrigger\n */ export const renderPopoverTrigger_unstable = (state)=>{\n return state.children;\n};\n"],"names":["renderPopoverTrigger_unstable","state","children"],"mappings":"AAAA;;CAEC;;;;+BAAgBA
|
1
|
+
{"version":3,"sources":["renderPopoverTrigger.js"],"sourcesContent":["/**\n * Render the final JSX of PopoverTrigger\n */ export const renderPopoverTrigger_unstable = (state)=>{\n return state.children;\n};\n"],"names":["renderPopoverTrigger_unstable","state","children"],"mappings":"AAAA;;CAEC;;;;+BAAgBA;;;eAAAA;;;AAAN,MAAMA,gCAAgC,CAACC;IAC9C,OAAOA,MAAMC,QAAQ;AACzB"}
|
@@ -4,25 +4,28 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
});
|
5
5
|
Object.defineProperty(exports, "usePopoverTrigger_unstable", {
|
6
6
|
enumerable: true,
|
7
|
-
get: ()
|
7
|
+
get: function() {
|
8
|
+
return usePopoverTrigger_unstable;
|
9
|
+
}
|
8
10
|
});
|
9
|
-
const
|
10
|
-
const _react = /*#__PURE__*/
|
11
|
-
const
|
12
|
-
const
|
11
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
13
|
+
const _reactutilities = require("@fluentui/react-utilities");
|
14
|
+
const _reacttabster = require("@fluentui/react-tabster");
|
13
15
|
const _popoverContext = require("../../popoverContext");
|
14
|
-
const
|
15
|
-
const
|
16
|
+
const _reactaria = require("@fluentui/react-aria");
|
17
|
+
const _keyboardkeys = require("@fluentui/keyboard-keys");
|
16
18
|
const usePopoverTrigger_unstable = (props)=>{
|
17
|
-
|
18
|
-
const
|
19
|
+
var _child, _child1, _child2, _child3, _child4, _child5, _child6, _child7, _child8, _child9, _child10;
|
20
|
+
const { children, disableButtonEnhancement = false } = props;
|
21
|
+
const child = (0, _reactutilities.getTriggerChild)(children);
|
19
22
|
const open = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.open);
|
20
23
|
const setOpen = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.setOpen);
|
21
24
|
const toggleOpen = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.toggleOpen);
|
22
25
|
const triggerRef = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.triggerRef);
|
23
26
|
const openOnHover = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.openOnHover);
|
24
27
|
const openOnContext = (0, _popoverContext.usePopoverContext_unstable)((context)=>context.openOnContext);
|
25
|
-
const { triggerAttributes
|
28
|
+
const { triggerAttributes } = (0, _reacttabster.useModalAttributes)();
|
26
29
|
const onContextMenu = (e)=>{
|
27
30
|
if (openOnContext) {
|
28
31
|
e.preventDefault();
|
@@ -35,7 +38,7 @@ const usePopoverTrigger_unstable = (props)=>{
|
|
35
38
|
}
|
36
39
|
};
|
37
40
|
const onKeyDown = (e)=>{
|
38
|
-
if (e.key ===
|
41
|
+
if (e.key === _keyboardkeys.Escape && open) {
|
39
42
|
setOpen(e, false);
|
40
43
|
// stop propagation to avoid conflicting with other elements that listen for `Escape`
|
41
44
|
// e,g: Dialog, Menu
|
@@ -55,19 +58,19 @@ const usePopoverTrigger_unstable = (props)=>{
|
|
55
58
|
const contextMenuProps = {
|
56
59
|
...triggerAttributes,
|
57
60
|
'aria-expanded': `${open}`,
|
58
|
-
...child === null ||
|
59
|
-
onMouseEnter: (0,
|
60
|
-
onMouseLeave: (0,
|
61
|
-
onContextMenu: (0,
|
62
|
-
ref: (0,
|
61
|
+
...(_child = child) === null || _child === void 0 ? void 0 : _child.props,
|
62
|
+
onMouseEnter: (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)((_child1 = child) === null || _child1 === void 0 ? void 0 : _child1.props.onMouseEnter, onMouseEnter)),
|
63
|
+
onMouseLeave: (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)((_child2 = child) === null || _child2 === void 0 ? void 0 : _child2.props.onMouseLeave, onMouseLeave)),
|
64
|
+
onContextMenu: (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)((_child3 = child) === null || _child3 === void 0 ? void 0 : _child3.props.onContextMenu, onContextMenu)),
|
65
|
+
ref: (0, _reactutilities.useMergedRefs)(triggerRef, (_child4 = child) === null || _child4 === void 0 ? void 0 : _child4.ref)
|
63
66
|
};
|
64
67
|
const triggerChildProps = {
|
65
68
|
...contextMenuProps,
|
66
|
-
onClick: (0,
|
67
|
-
onKeyDown: (0,
|
69
|
+
onClick: (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)((_child5 = child) === null || _child5 === void 0 ? void 0 : _child5.props.onClick, onClick)),
|
70
|
+
onKeyDown: (0, _reactutilities.useEventCallback)((0, _reactutilities.mergeCallbacks)((_child6 = child) === null || _child6 === void 0 ? void 0 : _child6.props.onKeyDown, onKeyDown))
|
68
71
|
};
|
69
|
-
const ariaButtonTriggerChildProps = (0,
|
72
|
+
const ariaButtonTriggerChildProps = (0, _reactaria.useARIAButtonProps)(((_child7 = child) === null || _child7 === void 0 ? void 0 : _child7.type) === 'button' || ((_child8 = child) === null || _child8 === void 0 ? void 0 : _child8.type) === 'a' ? child.type : 'div', triggerChildProps);
|
70
73
|
return {
|
71
|
-
children: (0,
|
74
|
+
children: (0, _reactutilities.applyTriggerPropsToChildren)(props.children, (0, _reactaria.useARIAButtonProps)(((_child9 = child) === null || _child9 === void 0 ? void 0 : _child9.type) === 'button' || ((_child10 = child) === null || _child10 === void 0 ? void 0 : _child10.type) === 'a' ? child.type : 'div', openOnContext ? contextMenuProps : disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps))
|
72
75
|
};
|
73
76
|
};
|
@@ -1 +1 @@
|
|
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
|
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 var _child, _child1, _child2, _child3, _child4, _child5, _child6, _child7, _child8, _child9, _child10;\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 = child) === null || _child === void 0 ? void 0 : _child.props,\n onMouseEnter: useEventCallback(mergeCallbacks((_child1 = child) === null || _child1 === void 0 ? void 0 : _child1.props.onMouseEnter, onMouseEnter)),\n onMouseLeave: useEventCallback(mergeCallbacks((_child2 = child) === null || _child2 === void 0 ? void 0 : _child2.props.onMouseLeave, onMouseLeave)),\n onContextMenu: useEventCallback(mergeCallbacks((_child3 = child) === null || _child3 === void 0 ? void 0 : _child3.props.onContextMenu, onContextMenu)),\n ref: useMergedRefs(triggerRef, (_child4 = child) === null || _child4 === void 0 ? void 0 : _child4.ref)\n };\n const triggerChildProps = {\n ...contextMenuProps,\n onClick: useEventCallback(mergeCallbacks((_child5 = child) === null || _child5 === void 0 ? void 0 : _child5.props.onClick, onClick)),\n onKeyDown: useEventCallback(mergeCallbacks((_child6 = child) === null || _child6 === void 0 ? void 0 : _child6.props.onKeyDown, onKeyDown))\n };\n const ariaButtonTriggerChildProps = useARIAButtonProps(((_child7 = child) === null || _child7 === void 0 ? void 0 : _child7.type) === 'button' || ((_child8 = child) === null || _child8 === void 0 ? void 0 : _child8.type) === 'a' ? child.type : 'div', triggerChildProps);\n return {\n children: applyTriggerPropsToChildren(props.children, useARIAButtonProps(((_child9 = child) === null || _child9 === void 0 ? void 0 : _child9.type) === 'button' || ((_child10 = child) === null || _child10 === void 0 ? void 0 : _child10.type) === 'a' ? child.type : 'div', openOnContext ? contextMenuProps : disableButtonEnhancement ? triggerChildProps : ariaButtonTriggerChildProps))\n };\n};\n"],"names":["usePopoverTrigger_unstable","props","_child","_child1","_child2","_child3","_child4","_child5","_child6","_child7","_child8","_child9","_child10","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;;;eAAAA;;;;iEAbM;gCACuF;8BAC3E;gCACQ;2BACR;8BACZ;AAQZ,MAAMA,6BAA6B,CAACC;IAC3C,IAAIC,QAAQC,SAASC,SAASC,SAASC,SAASC,SAASC,SAASC,SAASC,SAASC,SAASC;IAC7F,MAAM,EAAEC,QAAQ,EAAEC,2BAA2B,KAAK,EAAE,GAAGb;IACvD,MAAMc,QAAQC,IAAAA,+BAAe,EAACH;IAC9B,MAAMI,OAAOC,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQF,IAAI;IAC/D,MAAMG,UAAUF,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQC,OAAO;IACrE,MAAMC,aAAaH,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQE,UAAU;IAC3E,MAAMC,aAAaJ,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQG,UAAU;IAC3E,MAAMC,cAAcL,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQI,WAAW;IAC7E,MAAMC,gBAAgBN,IAAAA,0CAA0B,EAAC,CAACC,UAAUA,QAAQK,aAAa;IACjF,MAAM,EAAEC,iBAAiB,EAAE,GAAGC,IAAAA,gCAAkB;IAChD,MAAMC,gBAAgB,CAACC;QACnB,IAAIJ,eAAe;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
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
12
|
+
Popover: function() {
|
13
|
+
return _Popover.Popover;
|
14
|
+
},
|
15
|
+
renderPopover_unstable: function() {
|
16
|
+
return _Popover.renderPopover_unstable;
|
17
|
+
},
|
18
|
+
usePopover_unstable: function() {
|
19
|
+
return _Popover.usePopover_unstable;
|
20
|
+
},
|
21
|
+
PopoverSurface: function() {
|
22
|
+
return _PopoverSurface.PopoverSurface;
|
23
|
+
},
|
24
|
+
arrowHeights: function() {
|
25
|
+
return _PopoverSurface.arrowHeights;
|
26
|
+
},
|
27
|
+
popoverSurfaceClassNames: function() {
|
28
|
+
return _PopoverSurface.popoverSurfaceClassNames;
|
29
|
+
},
|
30
|
+
renderPopoverSurface_unstable: function() {
|
31
|
+
return _PopoverSurface.renderPopoverSurface_unstable;
|
32
|
+
},
|
33
|
+
usePopoverSurfaceStyles_unstable: function() {
|
34
|
+
return _PopoverSurface.usePopoverSurfaceStyles_unstable;
|
35
|
+
},
|
36
|
+
usePopoverSurface_unstable: function() {
|
37
|
+
return _PopoverSurface.usePopoverSurface_unstable;
|
38
|
+
},
|
39
|
+
PopoverProvider: function() {
|
40
|
+
return _popoverContext.PopoverProvider;
|
41
|
+
},
|
42
|
+
usePopoverContext_unstable: function() {
|
43
|
+
return _popoverContext.usePopoverContext_unstable;
|
44
|
+
},
|
45
|
+
PopoverTrigger: function() {
|
46
|
+
return _PopoverTrigger.PopoverTrigger;
|
47
|
+
},
|
48
|
+
renderPopoverTrigger_unstable: function() {
|
49
|
+
return _PopoverTrigger.renderPopoverTrigger_unstable;
|
50
|
+
},
|
51
|
+
usePopoverTrigger_unstable: function() {
|
52
|
+
return _PopoverTrigger.usePopoverTrigger_unstable;
|
53
|
+
}
|
26
54
|
});
|
27
|
-
const
|
28
|
-
const
|
55
|
+
const _Popover = require("./Popover");
|
56
|
+
const _PopoverSurface = require("./PopoverSurface");
|
29
57
|
const _popoverContext = require("./popoverContext");
|
30
|
-
const
|
58
|
+
const _PopoverTrigger = require("./PopoverTrigger");
|
@@ -1 +1 @@
|
|
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,
|
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;eAAPA,gBAAO;;IAAEC,sBAAsB;eAAtBA,+BAAsB;;IAAEC,mBAAmB;eAAnBA,4BAAmB;;IACpDC,cAAc;eAAdA,8BAAc;;IAAEC,YAAY;eAAZA,4BAAY;;IAAEC,wBAAwB;eAAxBA,wCAAwB;;IAAEC,6BAA6B;eAA7BA,6CAA6B;;IAAEC,gCAAgC;eAAhCA,gDAAgC;;IAAEC,0BAA0B;eAA1BA,0CAA0B;;IACnJC,eAAe;eAAfA,+BAAe;;IAAEC,0BAA0B;eAA1BA,0CAA0B;;IAC3CC,cAAc;eAAdA,8BAAc;;IAAEC,6BAA6B;eAA7BA,6CAA6B;;IAAEC,0BAA0B;eAA1BA,0CAA0B;;;yBAHb;gCAC+F;gCACxG;gCAC8B"}
|
@@ -9,12 +9,18 @@ function _export(target, all) {
|
|
9
9
|
});
|
10
10
|
}
|
11
11
|
_export(exports, {
|
12
|
-
PopoverContext: ()
|
13
|
-
|
14
|
-
|
12
|
+
PopoverContext: function() {
|
13
|
+
return PopoverContext;
|
14
|
+
},
|
15
|
+
PopoverProvider: function() {
|
16
|
+
return PopoverProvider;
|
17
|
+
},
|
18
|
+
usePopoverContext_unstable: function() {
|
19
|
+
return usePopoverContext_unstable;
|
20
|
+
}
|
15
21
|
});
|
16
|
-
const
|
17
|
-
const PopoverContext = (0,
|
22
|
+
const _reactcontextselector = require("@fluentui/react-context-selector");
|
23
|
+
const PopoverContext = (0, _reactcontextselector.createContext)(undefined);
|
18
24
|
const popoverContextDefaultValue = {
|
19
25
|
open: false,
|
20
26
|
setOpen: ()=>null,
|
@@ -35,4 +41,4 @@ const popoverContextDefaultValue = {
|
|
35
41
|
inline: false
|
36
42
|
};
|
37
43
|
const PopoverProvider = PopoverContext.Provider;
|
38
|
-
const usePopoverContext_unstable = (selector)=>(0,
|
44
|
+
const usePopoverContext_unstable = (selector)=>(0, _reactcontextselector.useContextSelector)(PopoverContext, (ctx = popoverContextDefaultValue)=>selector(ctx));
|
@@ -1 +1 @@
|
|
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
|
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;eAAdA;;IAoBAC,eAAe;eAAfA;;IACAC,0BAA0B;eAA1BA;;;sCAtBqC;AAC3C,MAAMF,iBAAiBG,IAAAA,mCAAa,EAACC;AAC5C,MAAMC,6BAA6B;IAC/BC,MAAM;IACNC,SAAS,IAAI;IACbC,YAAY,IAAI;IAChBC,YAAY;QACRC,SAAS;IACb;IACAC,YAAY;QACRD,SAAS;IACb;IACAE,UAAU;QACNF,SAAS;IACb;IACAG,eAAe;IACfC,aAAa;IACbC,MAAM;IACNC,WAAW;IACXC,QAAQ;AACZ;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.8.
|
3
|
+
"version": "9.8.1",
|
4
4
|
"description": "Popover component for Fluent UI",
|
5
5
|
"main": "lib-commonjs/index.js",
|
6
6
|
"module": "lib/index.js",
|
@@ -36,24 +36,24 @@
|
|
36
36
|
"@fluentui/scripts-tasks": "*"
|
37
37
|
},
|
38
38
|
"dependencies": {
|
39
|
-
"@fluentui/keyboard-keys": "^9.0.
|
40
|
-
"@fluentui/react-aria": "^9.3.
|
41
|
-
"@fluentui/react-context-selector": "^9.1.
|
42
|
-
"@fluentui/react-portal": "^9.3.
|
43
|
-
"@fluentui/react-positioning": "^9.9.
|
44
|
-
"@fluentui/react-shared-contexts": "^9.7.
|
45
|
-
"@fluentui/react-tabster": "^9.12.
|
46
|
-
"@fluentui/react-theme": "^9.1.
|
47
|
-
"@fluentui/react-utilities": "^9.13.
|
48
|
-
"@fluentui/react-jsx-runtime": "^9.0.
|
39
|
+
"@fluentui/keyboard-keys": "^9.0.4",
|
40
|
+
"@fluentui/react-aria": "^9.3.34",
|
41
|
+
"@fluentui/react-context-selector": "^9.1.32",
|
42
|
+
"@fluentui/react-portal": "^9.3.11",
|
43
|
+
"@fluentui/react-positioning": "^9.9.9",
|
44
|
+
"@fluentui/react-shared-contexts": "^9.7.3",
|
45
|
+
"@fluentui/react-tabster": "^9.12.6",
|
46
|
+
"@fluentui/react-theme": "^9.1.12",
|
47
|
+
"@fluentui/react-utilities": "^9.13.1",
|
48
|
+
"@fluentui/react-jsx-runtime": "^9.0.4",
|
49
49
|
"@griffel/react": "^1.5.14",
|
50
|
-
"@swc/helpers": "^0.
|
50
|
+
"@swc/helpers": "^0.5.1"
|
51
51
|
},
|
52
52
|
"peerDependencies": {
|
53
|
-
"@types/react": ">=16.
|
54
|
-
"@types/react-dom": ">=16.
|
55
|
-
"react": ">=16.
|
56
|
-
"react-dom": ">=16.
|
53
|
+
"@types/react": ">=16.14.0 <19.0.0",
|
54
|
+
"@types/react-dom": ">=16.14.0 <19.0.0",
|
55
|
+
"react": ">=16.14.0 <19.0.0",
|
56
|
+
"react-dom": ">=16.14.0 <19.0.0",
|
57
57
|
"scheduler": "^0.19.0 || ^0.20.0"
|
58
58
|
},
|
59
59
|
"beachball": {
|