@fluentui-react-native/callout 0.29.6 → 0.29.8

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.
Files changed (66) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/README.md +18 -0
  3. package/lib/index.d.ts +2 -3
  4. package/lib/index.d.ts.map +1 -1
  5. package/lib/index.js +1 -2
  6. package/lib/index.js.map +1 -1
  7. package/package.json +12 -27
  8. package/src/index.ts +2 -3
  9. package/.cache/tsconfig.tsbuildinfo +0 -1
  10. package/FRNCallout.podspec +0 -24
  11. package/NuGet.config +0 -10
  12. package/SPEC.md +0 -46
  13. package/jest.config.cjs +0 -1
  14. package/lib/Callout.d.ts +0 -6
  15. package/lib/Callout.d.ts.map +0 -1
  16. package/lib/Callout.js +0 -64
  17. package/lib/Callout.js.map +0 -1
  18. package/lib/Callout.types.d.ts +0 -85
  19. package/lib/Callout.types.d.ts.map +0 -1
  20. package/lib/Callout.types.js +0 -2
  21. package/lib/Callout.types.js.map +0 -1
  22. package/lib/CalloutNativeComponent.d.ts +0 -49
  23. package/lib/CalloutNativeComponent.d.ts.map +0 -1
  24. package/lib/CalloutNativeComponent.js +0 -9
  25. package/lib/CalloutNativeComponent.js.map +0 -1
  26. package/lib/__tests__/Callout.test.d.ts +0 -2
  27. package/lib/__tests__/Callout.test.d.ts.map +0 -1
  28. package/lib/__tests__/Callout.test.js +0 -96
  29. package/lib/__tests__/Callout.test.js.map +0 -1
  30. package/lib/__tests__/Callout.types.test.d.ts +0 -2
  31. package/lib/__tests__/Callout.types.test.d.ts.map +0 -1
  32. package/lib/__tests__/Callout.types.test.js +0 -21
  33. package/lib/__tests__/Callout.types.test.js.map +0 -1
  34. package/macos/CalloutManager.swift +0 -16
  35. package/macos/CalloutView.swift +0 -454
  36. package/macos/CalloutWindow.swift +0 -40
  37. package/macos/FRNCallout.h +0 -14
  38. package/macos/FRNCalloutManager.h +0 -5
  39. package/macos/FRNCalloutManager.m +0 -76
  40. package/macos/FlippedVisualEffectView.swift +0 -10
  41. package/macos/GuardedEventMonitor.swift +0 -28
  42. package/macos/RCTCalloutComponentView.h +0 -12
  43. package/macos/RCTCalloutComponentView.mm +0 -209
  44. package/react-native.config.cjs +0 -15
  45. package/src/Callout.stories.tsx +0 -276
  46. package/src/Callout.tsx +0 -111
  47. package/src/Callout.types.ts +0 -106
  48. package/src/CalloutNativeComponent.ts +0 -74
  49. package/src/__tests__/Callout.test.tsx +0 -157
  50. package/src/__tests__/Callout.types.test.ts +0 -30
  51. package/src/__tests__/__snapshots__/Callout.test.tsx.snap +0 -11
  52. package/tsconfig.json +0 -19
  53. package/windows/Callout/Callout.cpp +0 -420
  54. package/windows/Callout/Callout.def +0 -3
  55. package/windows/Callout/Callout.h +0 -25
  56. package/windows/Callout/Callout.vcxproj +0 -152
  57. package/windows/Callout/ReactPackageProvider.cpp +0 -25
  58. package/windows/Callout/ReactPackageProvider.h +0 -25
  59. package/windows/Callout/ReactPackageProvider.idl +0 -12
  60. package/windows/Callout/codegen/.clang-format +0 -2
  61. package/windows/Callout/codegen/react/components/FRNCalloutSpec/Callout.g.h +0 -375
  62. package/windows/Callout/packages.lock.json +0 -151
  63. package/windows/Callout/pch.cpp +0 -1
  64. package/windows/Callout/pch.h +0 -28
  65. package/windows/ExperimentalFeatures.props +0 -33
  66. package/windows/NuGet.Config +0 -13
package/SPEC.md DELETED
@@ -1,46 +0,0 @@
1
- # Callout
2
-
3
- ## Purpose
4
-
5
- Callout is an unstyled native primitive that presents children in transient UI
6
- positioned relative to a target ref, registered native anchor, or anchor
7
- rectangle. It remains a standalone package because it owns native code and
8
- CocoaPods integration.
9
-
10
- ## Contract
11
-
12
- - `CalloutProps` extends React Native `ViewProps` with target resolution,
13
- dismissal callbacks, and `componentRef`.
14
- - `target` accepts a React component ref or registered native anchor string.
15
- When omitted, native positioning may use `anchorRect`.
16
- - `componentRef` exposes `focusWindow()` and `blurWindow()`.
17
- - Caller-supplied background, border, and dimension values are translated to
18
- native view style. User `style` is applied last.
19
- - The primitive applies no theme tokens or visible appearance defaults.
20
- `position: 'absolute'` keeps popup content out of the parent page layout.
21
- Transparent colors and zero-width/radius values satisfy the macOS native
22
- layer contract when callers omit border and background props.
23
- - Children, accessibility props, test props, native events, and supported
24
- Callout behavior props are forwarded to `RCTCallout`.
25
-
26
- ## Platform behavior
27
-
28
- - macOS presents children in a native popup window and supports window focus
29
- commands through both Paper and Fabric component registrations.
30
- - Windows uses the platform's built-in Paper `RCTCallout` and supplies a
31
- package-owned Fabric registration for React Native Windows 0.81 and newer.
32
- - Win32 supplies the platform `RCTCallout` implementation and supports native
33
- dismissal, pointer capture, beak, and focus-restoration behavior.
34
- - Unsupported native behavior remains platform-defined rather than being
35
- simulated in JavaScript.
36
-
37
- ## Compatibility
38
-
39
- `ICalloutProps`, `ICalloutTokens`, and `CalloutNativeCommands` remain as
40
- deprecated aliases for the modern public types.
41
-
42
- ## Demonstration
43
-
44
- Interactive scenarios live in
45
- `apps/tester-core/src/TestComponents/Callout/CalloutTest.tsx`, with end-to-end
46
- coverage under `apps/E2E/src/Callout`.
package/jest.config.cjs DELETED
@@ -1 +0,0 @@
1
- module.exports = require('@fluentui-react-native/scripts/jest-config');
package/lib/Callout.d.ts DELETED
@@ -1,6 +0,0 @@
1
- /**
2
- * Renders the native Callout without applying theme or appearance defaults.
3
- */
4
- export declare const Callout: any;
5
- export default Callout;
6
- //# sourceMappingURL=Callout.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.d.ts","sourceRoot":"","sources":["../src/Callout.tsx"],"names":[],"mappings":"AAkBA;;GAEG;AACH,eAAO,MAAM,OAAO,KAqFlB,CAAC;eAIY,OAAO"}
package/lib/Callout.js DELETED
@@ -1,64 +0,0 @@
1
- import { jsx as _jsx } from "@fluentui-react-native/framework-base/jsx-runtime";
2
- /** @jsxImportSource @fluentui-react-native/framework-base */
3
- import * as React from 'react';
4
- import { findNodeHandle, StyleSheet } from 'react-native';
5
- import { directComponent, mergeProps, phasedComponent } from '@fluentui-react-native/framework-base';
6
- import { calloutName } from './Callout.types';
7
- import NativeCalloutView, { Commands } from './CalloutNativeComponent';
8
- const colorTransparent = '#00000000';
9
- const styles = StyleSheet.create({
10
- root: {
11
- position: 'absolute',
12
- },
13
- });
14
- /**
15
- * Renders the native Callout without applying theme or appearance defaults.
16
- */
17
- export const Callout = phasedComponent((props) => {
18
- const { componentRef, target } = props;
19
- const nativeComponentRef = React.useRef(null);
20
- const [nativeTarget, setNativeTarget] = React.useState(undefined);
21
- React.useImperativeHandle(componentRef, () => ({
22
- blurWindow() {
23
- if (nativeComponentRef.current !== null) {
24
- Commands.blurWindow(nativeComponentRef.current);
25
- }
26
- },
27
- focusWindow() {
28
- if (nativeComponentRef.current !== null) {
29
- Commands.focusWindow(nativeComponentRef.current);
30
- }
31
- },
32
- }), []);
33
- React.useLayoutEffect(() => {
34
- if (typeof target === 'string') {
35
- setNativeTarget(target);
36
- }
37
- else if (target?.current) {
38
- setNativeTarget(findNodeHandle(target.current) ?? undefined);
39
- }
40
- else {
41
- setNativeTarget(undefined);
42
- }
43
- }, [target]);
44
- return directComponent((renderProps) => {
45
- const { anchorRect, backgroundColor, beakWidth, borderColor, borderRadius, borderWidth, componentRef: _componentRef, directionalHint, dismissBehaviors, gapSpace, maxHeight, maxWidth, minPadding, minWidth, style, target: _target, ...nativeProps } = mergeProps(props, renderProps);
46
- /**
47
- * Build the style for the callout based on the props. For `borderColor`, `borderWidth`, `backgroundColor`, and
48
- * `borderRadius` defaults values are required otherwise crashes in CalloutView.swift:updateLayer() will occur.
49
- */
50
- const calloutStyle = {
51
- backgroundColor: backgroundColor ?? colorTransparent,
52
- borderColor: borderColor ?? colorTransparent,
53
- borderWidth: borderWidth ?? 0,
54
- borderRadius: borderRadius ?? 0,
55
- ...(maxHeight != null && { maxHeight }),
56
- ...(maxWidth != null && { maxWidth }),
57
- ...(minWidth != null && { minWidth }),
58
- };
59
- return (_jsx(NativeCalloutView, { ...nativeProps, anchorRect: anchorRect, beakWidth: beakWidth, directionalHint: directionalHint, dismissBehaviors: dismissBehaviors, gapSpace: gapSpace, maxHeight: typeof maxHeight === 'number' ? maxHeight : undefined, maxWidth: typeof maxWidth === 'number' ? maxWidth : undefined, minPadding: minPadding, minWidth: typeof minWidth === 'number' ? minWidth : undefined, ref: nativeComponentRef, style: [styles.root, calloutStyle, style], ...(nativeTarget !== undefined && { target: nativeTarget }) }));
60
- });
61
- });
62
- Callout.displayName = calloutName;
63
- export default Callout;
64
- //# sourceMappingURL=Callout.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.js","sourceRoot":"","sources":["../src/Callout.tsx"],"names":[],"mappings":";AAAA,6DAA6D;AAC7D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1D,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,uCAAuC,CAAC;AAGrG,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,iBAAiB,EAAE,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEvE,MAAM,gBAAgB,GAAG,WAAW,CAAC;AAErC,MAAM,MAAM,GAAG,UAAU,CAAC,MAAM,CAAC;IAC/B,IAAI,EAAE;QACJ,QAAQ,EAAE,UAAU;KACrB;CACF,CAAC,CAAC;AAEH;;GAEG;AACH,MAAM,CAAC,MAAM,OAAO,GAAG,eAAe,CAAe,CAAC,KAAK,EAAE,EAAE;IAC7D,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;IACvC,MAAM,kBAAkB,GAAG,KAAK,CAAC,MAAM,CAAoD,IAAI,CAAC,CAAC;IACjG,MAAM,CAAC,YAAY,EAAE,eAAe,CAAC,GAAG,KAAK,CAAC,QAAQ,CAA8B,SAAS,CAAC,CAAC;IAE/F,KAAK,CAAC,mBAAm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AAW,EAAE,WAAW,IAAI,CAAC;YAC7B,YAAY,EAAE,YAAY,IAAI,CAAC;YAC/B,GAAG,CAAC,SAAS,IAAI,IAAI,IAAI,EAAE,SAAS,EAAE,CAAC;YACvC,GAAG,CAAC,QAAQ,IAAI,IAAI,IAAI,EAAE,QAAQ,EAAE,CAAC;YACrC,GAAG,CAAC,QAAQ,IAAI,IAAI,IAAI,EAAE,QAAQ,EAAE,CAAC;SACtC,CAAC;QAEF,OAAO,CACL,KAAC,iBAAiB,OACZ,WAAW,EACf,UAAU,EAAE,UAAU,EACtB,SAAS,EAAE,SAAS,EACpB,eAAe,EAAE,eAAe,EAChC,gBAAgB,EAAE,gBAAgB,EAClC,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,OAAO,SAAS,KAAK,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS,EAChE,QAAQ,EAAE,OAAO,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAC7D,UAAU,EAAE,UAAU,EACtB,QAAQ,EAAE,OAAO,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAC7D,GAAG,EAAE,kBAAkB,EACvB,KAAK,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,YAAY,EAAE,KAAK,CAAC,KACrC,CAAC,YAAY,KAAK,SAAS,IAAI,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC,GAC5D,CACH,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH,OAAO,CAAC,WAAW,GAAG,WAAW,CAAC;AAElC,eAAe,OAAO,CAAC"}
@@ -1,85 +0,0 @@
1
- import type * as React from 'react';
2
- import type { AnimatableNumericValue, ColorValue, KeyboardMetrics, ViewProps } from 'react-native';
3
- export declare const calloutName = "Callout";
4
- export type DirectionalHint = 'leftTopEdge' | 'leftCenter' | 'leftBottomEdge' | 'topLeftEdge' | 'topAutoEdge' | 'topCenter' | 'topRightEdge' | 'rightTopEdge' | 'rightCenter' | 'rightBottomEdge' | 'bottomLeftEdge' | 'bottomAutoEdge' | 'bottomCenter' | 'bottomRightEdge';
5
- export type DismissBehaviors = 'preventDismissOnKeyDown' | 'preventDismissOnClickOutside';
6
- export interface RestoreFocusEvent {
7
- nativeEvent: {
8
- /** True when the Callout contained focus while it was dismissed. */
9
- containsFocus: boolean;
10
- };
11
- }
12
- /**
13
- * Optional native appearance and positioning values. Callout applies only values
14
- * supplied by the caller and does not resolve theme defaults.
15
- */
16
- export interface CalloutTokens {
17
- /** Anchor rectangle in DIPs relative to the React surface origin. */
18
- anchorRect?: KeyboardMetrics;
19
- /** Native Callout background color. */
20
- backgroundColor?: ColorValue;
21
- /** Width of the beak that points toward the anchor. */
22
- beakWidth?: number;
23
- /** Native Callout border color. */
24
- borderColor?: ColorValue;
25
- /** Native Callout corner radius. */
26
- borderRadius?: AnimatableNumericValue | string;
27
- /** Native Callout border width. */
28
- borderWidth?: number;
29
- /** Preferred placement relative to the anchor. */
30
- directionalHint?: DirectionalHint;
31
- /** Native dismissal behaviors that may be combined. */
32
- dismissBehaviors?: DismissBehaviors[];
33
- /** Gap between the anchor and Callout. */
34
- gapSpace?: number;
35
- /** Maximum Callout height. */
36
- maxHeight?: number | `${number}%`;
37
- /** Maximum Callout width. */
38
- maxWidth?: number | `${number}%`;
39
- /** Minimum padding from display edges. */
40
- minPadding?: number;
41
- /** Minimum Callout width. */
42
- minWidth?: number | `${number}%`;
43
- }
44
- export interface CalloutHandle {
45
- /** Makes the native Callout window resign key status. */
46
- blurWindow: () => void;
47
- /** Makes the native Callout window key. */
48
- focusWindow: () => void;
49
- }
50
- export interface CalloutProps extends ViewProps, CalloutTokens {
51
- /**
52
- * A string announced when the Callout is shown.
53
- * @platform win32
54
- */
55
- accessibilityOnShowAnnouncement?: string;
56
- /** Ref used to invoke native Callout window commands. */
57
- componentRef?: React.Ref<CalloutHandle>;
58
- /**
59
- * Prevents the native Callout from taking pointer capture when shown.
60
- * @platform win32
61
- */
62
- doNotTakePointerCapture?: boolean;
63
- /** Displays a beak that points toward the anchor. */
64
- isBeakVisible?: boolean;
65
- /** Invoked after native dismissal. */
66
- onDismiss?: () => void;
67
- /**
68
- * Invoked during dismissal when the caller owns focus restoration.
69
- * @platform win32
70
- */
71
- onRestoreFocus?: (event: RestoreFocusEvent) => void;
72
- /** Invoked after the Callout is shown. */
73
- onShow?: () => void;
74
- /** Requests initial focus when the Callout is shown. */
75
- setInitialFocus?: boolean;
76
- /** Ref or registered native anchor identifier used for relative positioning. */
77
- target?: React.RefObject<React.Component | null> | string;
78
- }
79
- /** @deprecated Use CalloutProps. */
80
- export type ICalloutProps = CalloutProps;
81
- /** @deprecated Use CalloutTokens. */
82
- export type ICalloutTokens = CalloutTokens;
83
- /** @deprecated Use CalloutHandle. */
84
- export type CalloutNativeCommands = CalloutHandle;
85
- //# sourceMappingURL=Callout.types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.types.d.ts","sourceRoot":"","sources":["../src/Callout.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AACpC,OAAO,KAAK,EAAE,sBAAsB,EAAE,UAAU,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEnG,eAAO,MAAM,WAAW,YAAY,CAAC;AAErC,MAAM,MAAM,eAAe,GACvB,aAAa,GACb,YAAY,GACZ,gBAAgB,GAChB,aAAa,GACb,aAAa,GACb,WAAW,GACX,cAAc,GACd,cAAc,GACd,aAAa,GACb,iBAAiB,GACjB,gBAAgB,GAChB,gBAAgB,GAChB,cAAc,GACd,iBAAiB,CAAC;AAEtB,MAAM,MAAM,gBAAgB,GAAG,yBAAyB,GAAG,8BAA8B,CAAC;AAE1F,MAAM,WAAW,iBAAiB;IAChC,WAAW,EAAE;QACX,oEAAoE;QACpE,aAAa,EAAE,OAAO,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EAAE,OAAO,CAAC;IACxB,sCAAsC;IACtC,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB;;;OAGG;IACH,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,iBAAiB,KAAK,IAAI,CAAC;IACpD,0CAA0C;IAC1C,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,wDAAwD;IACxD,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,gFAAgF;IAChF,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,KAAK,CAAC,SAAS,GAAG,IAAI,CAAC,GAAG,MAAM,CAAC;CAC3D;AAED,oCAAoC;AACpC,MAAM,MAAM,aAAa,GAAG,YAAY,CAAC;AACzC,qCAAqC;AACrC,MAAM,MAAM,cAAc,GAAG,aAAa,CAAC;AAC3C,qCAAqC;AACrC,MAAM,MAAM,qBAAqB,GAAG,aAAa,CAAC"}
@@ -1,2 +0,0 @@
1
- export const calloutName = 'Callout';
2
- //# sourceMappingURL=Callout.types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.types.js","sourceRoot":"","sources":["../src/Callout.types.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,WAAW,GAAG,SAAS,CAAC"}
@@ -1,49 +0,0 @@
1
- import type { HostComponent, ViewProps } from 'react-native';
2
- import type { WithDefault, UnsafeMixed, Int32, DirectEventHandler, Double } from 'react-native/Libraries/Types/CodegenTypes';
3
- interface AnchorRect {
4
- screenX: Double;
5
- screenY: Double;
6
- width: Double;
7
- height: Double;
8
- }
9
- /**
10
- * Shared native props specific to Callout native component
11
- */
12
- export interface NativeProps extends ViewProps {
13
- accessibilityLabel?: string;
14
- accessibilityOnShowAnnouncement?: string;
15
- anchorRect?: AnchorRect;
16
- beakWidth?: Int32;
17
- dismissBehaviors?: string[];
18
- doNotTakePointerCapture?: boolean;
19
- focusable?: boolean;
20
- gapSpace?: Int32;
21
- isBeakVisible?: boolean;
22
- maxHeight?: Int32;
23
- maxWidth?: Int32;
24
- minPadding?: Int32;
25
- minWidth?: Int32;
26
- setInitialFocus?: boolean;
27
- testID?: string;
28
- onRestoreFocus?: DirectEventHandler<{
29
- target: Int32;
30
- containsFocus: boolean;
31
- }>;
32
- onDismiss?: DirectEventHandler<{
33
- target: Int32;
34
- }>;
35
- onShow?: DirectEventHandler<{
36
- target: Int32;
37
- }>;
38
- directionalHint?: WithDefault<'leftTopEdge' | 'leftCenter' | 'leftBottomEdge' | 'topLeftEdge' | 'topAutoEdge' | 'topCenter' | 'topRightEdge' | 'rightTopEdge' | 'rightCenter' | 'rightBottomEdge' | 'bottomLeftEdge' | 'bottomAutoEdge' | 'bottomCenter' | 'bottomRightEdge', 'bottomLeftEdge'>;
39
- target?: UnsafeMixed;
40
- }
41
- export type CalloutComponentType = HostComponent<NativeProps>;
42
- interface NativeCalloutCommands {
43
- focusWindow: (viewRef: React.ElementRef<CalloutComponentType>) => void;
44
- blurWindow: (viewRef: React.ElementRef<CalloutComponentType>) => void;
45
- }
46
- export declare const Commands: NativeCalloutCommands;
47
- declare const _default: CalloutComponentType;
48
- export default _default;
49
- //# sourceMappingURL=CalloutNativeComponent.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CalloutNativeComponent.d.ts","sourceRoot":"","sources":["../src/CalloutNativeComponent.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC7D,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,KAAK,EAAE,kBAAkB,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AAE7H,UAAU,UAAU;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,WAAY,SAAQ,SAAS;IAC5C,kBAAkB,CAAC,EAAE,MAAM,CA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AC,oBAAoB,CAAC,KAAK,IAAI,CAAC;IACvE,UAAU,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC,UAAU,CAAC,oBAAoB,CAAC,KAAK,IAAI,CAAC;CACvE;AAED,eAAO,MAAM,QAAQ,EAAE,qBAErB,CAAC;wBAIG,oBAAoB"}
@@ -1,9 +0,0 @@
1
- import codegenNativeCommands from 'react-native/Libraries/Utilities/codegenNativeCommands';
2
- import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
3
- export const Commands = codegenNativeCommands({
4
- supportedCommands: ['blurWindow', 'focusWindow'],
5
- });
6
- export default codegenNativeComponent('Callout', {
7
- paperComponentName: 'RCTCallout',
8
- });
9
- //# sourceMappingURL=CalloutNativeComponent.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"CalloutNativeComponent.js","sourceRoot":"","sources":["../src/CalloutNativeComponent.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,MAAM,wDAAwD,CAAC;AAC3F,OAAO,sBAAsB,MAAM,yDAAyD,CAAC;AAkE7F,MAAM,CAAC,MAAM,QAAQ,GAA0B,qBAAqB,CAAwB;IAC1F,iBAAiB,EAAE,CAAC,YAAY,EAAE,aAAa,CAAC;CACjD,CAAC,CAAC;AAEH,eAAe,sBAAsB,CAAc,SAAS,EAAE;IAC5D,kBAAkB,EAAE,YAAY;CACjC,CAAyB,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=Callout.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/Callout.test.tsx"],"names":[],"mappings":""}
@@ -1,96 +0,0 @@
1
- import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from "@fluentui-react-native/framework-base/jsx-runtime";
2
- /** @jsxImportSource @fluentui-react-native/framework-base */
3
- import * as React from 'react';
4
- import { StyleSheet, Text, View } from 'react-native';
5
- import { act, render } from '@testing-library/react-native';
6
- import { isPhasedComponent, useSlot } from '@fluentui-react-native/framework-base';
7
- import { Callout } from '../Callout';
8
- import { Commands } from '../CalloutNativeComponent';
9
- jest.mock('react-native/Libraries/ReactNative/RendererProxy', () => ({
10
- ...jest.requireActual('react-native/Libraries/ReactNative/RendererProxy'),
11
- findNodeHandle: jest.fn(() => 42),
12
- }));
13
- function CalloutSlotConsumer({ callout }) {
14
- const CalloutSlot = useSlot(Callout, callout);
15
- return (_jsx(CalloutSlot, { accessibilityHint: "rendered as a slot", testID: "slotted-callout", children: _jsx(Text, { children: "Slot content" }) }));
16
- }
17
- describe('Callout', () => {
18
- afterEach(() => {
19
- jest.restoreAllMocks();
20
- });
21
- it('uses phased rendering and applies native-safe default styling', async () => {
22
- expect(isPhasedComponent(Callout)).toBe(true);
23
- const component = await render(_jsx(Callout, { testID: "callout" }));
24
- const callout = component.getByTestId('callout');
25
- expect(callout.type).toBe('RCTCallout');
26
- expect(StyleSheet.flatten(callout.props.style)).toMatchSnapshot();
27
- });
28
- it('translates caller-supplied appearance values and preserves user style precedence', async () => {
29
- const component = await render(_jsx(Callout, { backgroundColor: "red", borderColor: "green", borderRadius: 8, borderWidth: 2, maxHeight: 240, maxWidth: "80%", minWidth: 120, style: { backgroundColor: 'blue', opacity: 0.5 }, testID: "callout" }));
30
- const callout = component.getByTestId('callout');
31
- expect(StyleSheet.flatten(callout.props.style)).toEqual({
32
- position: 'absolute',
33
- backgroundColor: 'blue',
34
- borderColor: 'green',
35
- borderRadius: 8,
36
- borderWidth: 2,
37
- maxHeight: 240,
38
- maxWidth: '80%',
39
- minWidth: 120,
40
- opacity: 0.5,
41
- });
42
- expect(callout.props.backgroundColor).toBeUndefined();
43
- expect(callout.props.maxHeight).toBe(240);
44
- expect(callout.props.maxWidth).toBeUndefined();
45
- expect(callout.props.minWidth).toBe(120);
46
- });
47
- it('forwards native behavior, accessibility, callbacks, and children', async () => {
48
- const onDismiss = jest.fn();
49
- const onShow = jest.fn();
50
- const anchorRect = { screenX: 10, screenY: 20, width: 30, height: 40 };
51
- const component = await render(_jsx(Callout, { accessibilityLabel: "Formatting options", anchorRect: anchorRect, beakWidth: 12, directionalHint: "rightTopEdge", dismissBehaviors: ['preventDismissOnClickOutside'], gapSpace: 4, minPadding: 8, onDismiss: onDismiss, onShow: onShow, target: "editor-anchor", testID: "callout", children: _jsx(Text, { children: "Callout content" }) }));
52
- const callout = component.getByTestId('callout');
53
- expect(callout.props).toMatchObject({
54
- accessibilityLabel: 'Formatting options',
55
- anchorRect,
56
- beakWidth: 12,
57
- directionalHint: 'rightTopEdge',
58
- dismissBehaviors: ['preventDismissOnClickOutside'],
59
- gapSpace: 4,
60
- minPadding: 8,
61
- onDismiss,
62
- onShow,
63
- target: 'editor-anchor',
64
- });
65
- expect(component.getByText('Callout content')).toBeTruthy();
66
- });
67
- it('resolves a React target ref to its native handle', async () => {
68
- const target = React.createRef();
69
- const component = await render(_jsxs(_Fragment, { children: [_jsx(View, { ref: target }), _jsx(Callout, { target: target, testID: "callout" })] }));
70
- expect(target.current).not.toBeNull();
71
- expect(component.getByTestId('callout').props.target).toBe(42);
72
- });
73
- it('exposes native window commands through componentRef', async () => {
74
- const focusWindow = jest.spyOn(Commands, 'focusWindow').mockImplementation(() => undefined);
75
- const blurWindow = jest.spyOn(Commands, 'blurWindow').mockImplementation(() => undefined);
76
- const componentRef = React.createRef();
77
- await render(_jsx(Callout, { componentRef: componentRef, testID: "callout" }));
78
- await act(async () => {
79
- componentRef.current?.focusWindow();
80
- componentRef.current?.blurWindow();
81
- });
82
- expect(focusWindow).toHaveBeenCalledTimes(1);
83
- expect(blurWindow).toHaveBeenCalledTimes(1);
84
- });
85
- it('can be consumed as a slot with merged render props', async () => {
86
- const component = await render(_jsx(CalloutSlotConsumer, { callout: { accessibilityLabel: 'Slotted Callout', target: 'slot-anchor' } }));
87
- const callout = component.getByTestId('slotted-callout');
88
- expect(callout.props).toMatchObject({
89
- accessibilityHint: 'rendered as a slot',
90
- accessibilityLabel: 'Slotted Callout',
91
- target: 'slot-anchor',
92
- });
93
- expect(component.getByText('Slot content')).toBeTruthy();
94
- });
95
- });
96
- //# sourceMappingURL=Callout.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.test.js","sourceRoot":"","sources":["../../src/__tests__/Callout.test.tsx"],"names":[],"mappings":";AAAA,6DAA6D;AAC7D,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEtD,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,iBAAiB,EAAE,OAAO,EAAE,MAAM,uCAAuC,CAAC;AAGnF,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAErC,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AAErD,IAAI,CAAC,IAAI,CAAC,kDAAkD,EAAE,GAAG,EAAE,CAAC,CAAC;IACnE,GAAG,IAAI,CAAC,aAAa,CAAC,kDAAkD,CAAC;IACzE,cAAc,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC;CAClC,CAAC,CAAC,CAAC;AAMJ,SAAS,mBAAmB,CAAC,EAAE,OAAO,EAA4B;IAChE,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAC9C,OAAO,CACL,KAAC,WAAW,IAAC,iBAAiB,EAAC,oBAAoB,EAAC,MAAM,EAAC,iBAAiB,YAC1E,KAAC,IAAI,+BAAoB,GACb,CACf,CAAC;AACJ,CAAC;AAED,QAAQ,CAAC,SAAS,EAAE,GAAG,EAAE;IACvB,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,CAAC,eAAe,EAAE,CAAC;IACzB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,+DAA+D,EAAE,KAAK,IAAI,EAAE;QAC7E,MAAM,CAAC,iBA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AAC,SAAS,GAAG,CAAC,CAAC;QAEvE,MAAM,GAAG,CAAC,KAAK,IAAI,EAAE;YACnB,YAAY,CAAC,OAAO,EAAE,WAAW,EAAE,CAAC;YACpC,YAAY,CAAC,OAAO,EAAE,UAAU,EAAE,CAAC;QACrC,CAAC,CAAC,CAAC;QAEH,MAAM,CAAC,WAAW,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAC;QAC7C,MAAM,CAAC,UAAU,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAC;IAC9C,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oDAAoD,EAAE,KAAK,IAAI,EAAE;QAClE,MAAM,SAAS,GAAG,MAAM,MAAM,CAAC,KAAC,mBAAmB,IAAC,OAAO,EAAE,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,EAAE,aAAa,EAAE,GAAI,CAAC,CAAC;QACnI,MAAM,OAAO,GAAG,SAAS,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC;QAEzD,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,aAAa,CAAC;YAClC,iBAAiB,EAAE,oBAAoB;YACvC,kBAAkB,EAAE,iBAAiB;YACrC,MAAM,EAAE,aAAa;SACtB,CAAC,CAAC;QACH,MAAM,CAAC,SAAS,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,CAAC,UAAU,EAAE,CAAC;IAC3D,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=Callout.types.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.types.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/Callout.types.test.ts"],"names":[],"mappings":""}
@@ -1,21 +0,0 @@
1
- /* eslint-disable @typescript-eslint/no-unused-vars */
2
- import * as React from 'react';
3
- const componentRef = React.createRef();
4
- const target = React.createRef();
5
- const props = {
6
- accessibilityLabel: 'Formatting options',
7
- componentRef,
8
- directionalHint: 'bottomCenter',
9
- target,
10
- };
11
- const calloutSlot = props;
12
- const legacyProps = props;
13
- // @ts-expect-error Callout targets must be a ref or registered native anchor identifier.
14
- const invalidTarget = { target: 42 };
15
- describe('Callout types', () => {
16
- it('accepts public props as a slot contract', () => {
17
- expect(calloutSlot).toBeDefined();
18
- expect(legacyProps).toBeDefined();
19
- });
20
- });
21
- //# sourceMappingURL=Callout.types.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"Callout.types.test.js","sourceRoot":"","sources":["../../src/__tests__/Callout.types.test.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAO/B,MAAM,YAAY,GAAG,KAAK,CAAC,SAAS,EAAiB,CAAC;AACtD,MAAM,MAAM,GAAG,KAAK,CAAC,SAAS,EAAmB,CAAC;AAElD,MAAM,KAAK,GAAiB;IAC1B,kBAAkB,EAAE,oBAAoB;IACxC,YAAY;IACZ,eAAe,EAAE,cAAc;IAC/B,MAAM;CACP,CAAC;AAEF,MAAM,WAAW,GAA6B,KAAK,CAAC;AACpD,MAAM,WAAW,GAAkB,KAAK,CAAC;AAEzC,yFAAyF;AACzF,MAAM,aAAa,GAAiB,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;AAEnD,QAAQ,CAAC,eAAe,EAAE,GAAG,EAAE;IAC7B,EAAE,CAAC,yCAAyC,EAAE,GAAG,EAAE;QACjD,MAAM,CAAC,WAAW,CAAC,CAAC,WAAW,EAAE,CAAC;QAClC,MAAM,CAAC,WAAW,CAAC,CAAC,WAAW,EAAE,CAAC;IACpC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,16 +0,0 @@
1
- import AppKit
2
- import Foundation
3
- #if USE_REACT_AS_MODULE
4
- import React
5
- #endif // USE_REACT_AS_MODULE
6
-
7
- @objc(RCTCalloutManager)
8
- class CalloutManager: RCTViewManager {
9
- override func view()->NSView! {
10
- return CalloutView(bridge: bridge)
11
- }
12
-
13
- override class func requiresMainQueueSetup() -> Bool {
14
- return true
15
- }
16
- }