@robertlinde/react-tour-kit 0.0.1

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 (111) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +838 -0
  3. package/dist/react-native-platform/components/index.d.ts +2 -0
  4. package/dist/react-native-platform/components/index.js +8 -0
  5. package/dist/react-native-platform/components/index.js.map +1 -0
  6. package/dist/react-native-platform/components/tour-overlay.d.ts +3 -0
  7. package/dist/react-native-platform/components/tour-overlay.js +83 -0
  8. package/dist/react-native-platform/components/tour-overlay.js.map +1 -0
  9. package/dist/react-native-platform/components/tour-tooltip.d.ts +3 -0
  10. package/dist/react-native-platform/components/tour-tooltip.js +138 -0
  11. package/dist/react-native-platform/components/tour-tooltip.js.map +1 -0
  12. package/dist/react-native-platform/hooks/index.d.ts +1 -0
  13. package/dist/react-native-platform/hooks/index.js +6 -0
  14. package/dist/react-native-platform/hooks/index.js.map +1 -0
  15. package/dist/react-native-platform/hooks/use-tour-target.d.ts +2 -0
  16. package/dist/react-native-platform/hooks/use-tour-target.js +16 -0
  17. package/dist/react-native-platform/hooks/use-tour-target.js.map +1 -0
  18. package/dist/react-native-platform/index.d.ts +7 -0
  19. package/dist/react-native-platform/index.js +16 -0
  20. package/dist/react-native-platform/index.js.map +1 -0
  21. package/dist/react-native-platform/platform-adapter.d.ts +2 -0
  22. package/dist/react-native-platform/platform-adapter.js +87 -0
  23. package/dist/react-native-platform/platform-adapter.js.map +1 -0
  24. package/dist/react-native-platform/target-registry.d.ts +10 -0
  25. package/dist/react-native-platform/target-registry.js +20 -0
  26. package/dist/react-native-platform/target-registry.js.map +1 -0
  27. package/dist/react-native-platform/tour-provider.d.ts +3 -0
  28. package/dist/react-native-platform/tour-provider.js +200 -0
  29. package/dist/react-native-platform/tour-provider.js.map +1 -0
  30. package/dist/react-native-platform/types/tour-provider.props.type.d.ts +10 -0
  31. package/dist/react-native-platform/types/tour-provider.props.type.js +3 -0
  32. package/dist/react-native-platform/types/tour-provider.props.type.js.map +1 -0
  33. package/dist/react-native.d.ts +8 -0
  34. package/dist/react-native.js +19 -0
  35. package/dist/react-native.js.map +1 -0
  36. package/dist/react-platform/components/index.d.ts +2 -0
  37. package/dist/react-platform/components/index.js +8 -0
  38. package/dist/react-platform/components/index.js.map +1 -0
  39. package/dist/react-platform/components/tour-overlay.d.ts +3 -0
  40. package/dist/react-platform/components/tour-overlay.js +31 -0
  41. package/dist/react-platform/components/tour-overlay.js.map +1 -0
  42. package/dist/react-platform/components/tour-tooltip.d.ts +2 -0
  43. package/dist/react-platform/components/tour-tooltip.js +126 -0
  44. package/dist/react-platform/components/tour-tooltip.js.map +1 -0
  45. package/dist/react-platform/index.d.ts +6 -0
  46. package/dist/react-platform/index.js +14 -0
  47. package/dist/react-platform/index.js.map +1 -0
  48. package/dist/react-platform/platform-adapter.d.ts +2 -0
  49. package/dist/react-platform/platform-adapter.js +95 -0
  50. package/dist/react-platform/platform-adapter.js.map +1 -0
  51. package/dist/react-platform/tour-provider.d.ts +3 -0
  52. package/dist/react-platform/tour-provider.js +207 -0
  53. package/dist/react-platform/tour-provider.js.map +1 -0
  54. package/dist/react-platform/types/tour-provider.props.type.d.ts +10 -0
  55. package/dist/react-platform/types/tour-provider.props.type.js +3 -0
  56. package/dist/react-platform/types/tour-provider.props.type.js.map +1 -0
  57. package/dist/react-platform/utils/find-visible-element.util.d.ts +1 -0
  58. package/dist/react-platform/utils/find-visible-element.util.js +14 -0
  59. package/dist/react-platform/utils/find-visible-element.util.js.map +1 -0
  60. package/dist/react-platform/utils/index.d.ts +1 -0
  61. package/dist/react-platform/utils/index.js +6 -0
  62. package/dist/react-platform/utils/index.js.map +1 -0
  63. package/dist/react.d.ts +8 -0
  64. package/dist/react.js +18 -0
  65. package/dist/react.js.map +1 -0
  66. package/dist/shared/context/index.d.ts +1 -0
  67. package/dist/shared/context/index.js +7 -0
  68. package/dist/shared/context/index.js.map +1 -0
  69. package/dist/shared/context/tour-context.d.ts +3 -0
  70. package/dist/shared/context/tour-context.js +17 -0
  71. package/dist/shared/context/tour-context.js.map +1 -0
  72. package/dist/shared/hooks/index.d.ts +1 -0
  73. package/dist/shared/hooks/index.js +6 -0
  74. package/dist/shared/hooks/index.js.map +1 -0
  75. package/dist/shared/hooks/use-tour.hook.d.ts +2 -0
  76. package/dist/shared/hooks/use-tour.hook.js +10 -0
  77. package/dist/shared/hooks/use-tour.hook.js.map +1 -0
  78. package/dist/shared/index.d.ts +5 -0
  79. package/dist/shared/index.js +14 -0
  80. package/dist/shared/index.js.map +1 -0
  81. package/dist/shared/types/index.d.ts +8 -0
  82. package/dist/shared/types/index.js +7 -0
  83. package/dist/shared/types/index.js.map +1 -0
  84. package/dist/shared/types/platform-adapter.type.d.ts +24 -0
  85. package/dist/shared/types/platform-adapter.type.js +3 -0
  86. package/dist/shared/types/platform-adapter.type.js.map +1 -0
  87. package/dist/shared/types/rect.type.d.ts +10 -0
  88. package/dist/shared/types/rect.type.js +3 -0
  89. package/dist/shared/types/rect.type.js.map +1 -0
  90. package/dist/shared/types/tour-context.type.d.ts +12 -0
  91. package/dist/shared/types/tour-context.type.js +3 -0
  92. package/dist/shared/types/tour-context.type.js.map +1 -0
  93. package/dist/shared/types/tour-overlay-props.type.d.ts +7 -0
  94. package/dist/shared/types/tour-overlay-props.type.js +3 -0
  95. package/dist/shared/types/tour-overlay-props.type.js.map +1 -0
  96. package/dist/shared/types/tour-step.type.d.ts +8 -0
  97. package/dist/shared/types/tour-step.type.js +3 -0
  98. package/dist/shared/types/tour-step.type.js.map +1 -0
  99. package/dist/shared/types/tour-theme.type.d.ts +9 -0
  100. package/dist/shared/types/tour-theme.type.js +21 -0
  101. package/dist/shared/types/tour-theme.type.js.map +1 -0
  102. package/dist/shared/types/tour-tooltip-props.type.d.ts +17 -0
  103. package/dist/shared/types/tour-tooltip-props.type.js +3 -0
  104. package/dist/shared/types/tour-tooltip-props.type.js.map +1 -0
  105. package/dist/shared/utils/calculate-tooltip-position.util.d.ts +14 -0
  106. package/dist/shared/utils/calculate-tooltip-position.util.js +56 -0
  107. package/dist/shared/utils/calculate-tooltip-position.util.js.map +1 -0
  108. package/dist/shared/utils/index.d.ts +1 -0
  109. package/dist/shared/utils/index.js +6 -0
  110. package/dist/shared/utils/index.js.map +1 -0
  111. package/package.json +88 -0
@@ -0,0 +1,200 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TourProvider = TourProvider;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ const react_1 = require("react");
6
+ const index_js_1 = require("../shared/index.js");
7
+ const tour_tooltip_1 = require("./components/tour-tooltip");
8
+ const tour_overlay_1 = require("./components/tour-overlay");
9
+ const platform_adapter_1 = require("./platform-adapter");
10
+ const { Modal } = require('react-native');
11
+ const defaultPlacement = 'bottom';
12
+ const scrollDelayMs = 350;
13
+ const positionRetryDelayMs = 100;
14
+ const initialPositionDelayMs = 50;
15
+ const maxPositionAttempts = 20;
16
+ const domUpdateDelayMs = 100;
17
+ function TourProvider({ children, TooltipComponent, OverlayComponent, onTourEnd, theme, platform = platform_adapter_1.nativePlatformAdapter, }) {
18
+ const resolvedTheme = (0, react_1.useMemo)(() => (0, index_js_1.resolveTheme)(theme), [theme]);
19
+ const [isActive, setIsActive] = (0, react_1.useState)(false);
20
+ const [currentStep, setCurrentStep] = (0, react_1.useState)(0);
21
+ const [steps, setSteps] = (0, react_1.useState)([]);
22
+ const [currentTourId, setCurrentTourId] = (0, react_1.useState)(undefined);
23
+ const [tooltipPosition, setTooltipPosition] = (0, react_1.useState)({ top: 0, left: 0 });
24
+ const [isPositioned, setIsPositioned] = (0, react_1.useState)(false);
25
+ const [highlightRect, setHighlightRect] = (0, react_1.useState)(undefined);
26
+ const tooltipRef = (0, react_1.useRef)(null);
27
+ const [positionKey, setPositionKey] = (0, react_1.useState)(0);
28
+ const Tooltip = TooltipComponent ?? tour_tooltip_1.TourTooltip;
29
+ const Overlay = OverlayComponent ?? tour_overlay_1.TourOverlay;
30
+ const startTour = (0, react_1.useCallback)((tourSteps, tourId) => {
31
+ if (tourSteps.length > 0) {
32
+ setSteps(tourSteps);
33
+ setCurrentStep(0);
34
+ setCurrentTourId(tourId);
35
+ setIsActive(true);
36
+ }
37
+ }, []);
38
+ const endTour = (0, react_1.useCallback)(() => {
39
+ if (onTourEnd) {
40
+ onTourEnd(currentTourId);
41
+ }
42
+ setIsActive(false);
43
+ setCurrentStep(0);
44
+ setSteps([]);
45
+ setCurrentTourId(undefined);
46
+ setHighlightRect(undefined);
47
+ setTooltipPosition({ top: 0, left: 0 });
48
+ setIsPositioned(false);
49
+ }, [currentTourId, onTourEnd]);
50
+ const nextStep = (0, react_1.useCallback)(() => {
51
+ if (currentStep < steps.length - 1) {
52
+ setCurrentStep((previous) => previous + 1);
53
+ }
54
+ else {
55
+ endTour();
56
+ }
57
+ }, [currentStep, steps.length, endTour]);
58
+ const previousStep = (0, react_1.useCallback)(() => {
59
+ if (currentStep > 0) {
60
+ setCurrentStep((previous) => previous - 1);
61
+ }
62
+ }, [currentStep]);
63
+ const goToStep = (0, react_1.useCallback)((step) => {
64
+ if (step >= 0 && step < steps.length) {
65
+ setCurrentStep(step);
66
+ }
67
+ }, [steps.length]);
68
+ const updatePositions = (0, react_1.useCallback)(() => {
69
+ if (!isActive || steps.length === 0) {
70
+ return;
71
+ }
72
+ const currentTourStep = steps[currentStep];
73
+ if (!currentTourStep) {
74
+ return;
75
+ }
76
+ void (async () => {
77
+ const rect = await platform.measureElement(currentTourStep.target);
78
+ if (!rect) {
79
+ if (currentStep < steps.length - 1) {
80
+ setCurrentStep((previous) => previous + 1);
81
+ }
82
+ else {
83
+ endTour();
84
+ }
85
+ return;
86
+ }
87
+ setHighlightRect(rect);
88
+ const placement = currentTourStep.placement ?? defaultPlacement;
89
+ const tooltipDimensions = platform.measureTooltip(tooltipRef);
90
+ const viewportDimensions = platform.getViewportDimensions();
91
+ const position = (0, index_js_1.calculateTooltipPosition)(rect, placement, tooltipDimensions, viewportDimensions);
92
+ setTooltipPosition(position);
93
+ setIsPositioned(true);
94
+ })();
95
+ }, [isActive, currentStep, steps, endTour, platform]);
96
+ (0, react_1.useEffect)(() => {
97
+ if (!isActive || steps.length === 0) {
98
+ return;
99
+ }
100
+ const currentTourStep = steps[currentStep];
101
+ if (!currentTourStep) {
102
+ return;
103
+ }
104
+ const runStep = async () => {
105
+ if (currentTourStep.onBeforeStep) {
106
+ await currentTourStep.onBeforeStep();
107
+ await new Promise((resolve) => {
108
+ setTimeout(resolve, domUpdateDelayMs);
109
+ });
110
+ }
111
+ const rect = await platform.measureElement(currentTourStep.target);
112
+ if (!rect) {
113
+ if (currentStep < steps.length - 1) {
114
+ setCurrentStep((previous) => previous + 1);
115
+ }
116
+ else {
117
+ endTour();
118
+ }
119
+ return;
120
+ }
121
+ setHighlightRect(rect);
122
+ setIsPositioned(false);
123
+ await platform.scrollToElement(currentTourStep.target);
124
+ setTimeout(() => {
125
+ setPositionKey((k) => k + 1);
126
+ }, scrollDelayMs);
127
+ };
128
+ void runStep();
129
+ }, [isActive, currentStep, steps, endTour, platform]);
130
+ (0, react_1.useEffect)(() => {
131
+ if (!isActive || !highlightRect || steps.length === 0) {
132
+ return;
133
+ }
134
+ const currentTourStep = steps[currentStep];
135
+ if (!currentTourStep) {
136
+ return;
137
+ }
138
+ let attempts = 0;
139
+ let timeoutId;
140
+ let animationFrameId;
141
+ const tryPosition = () => {
142
+ attempts++;
143
+ animationFrameId = platform.scheduleFrame(() => {
144
+ void (async () => {
145
+ const rect = await platform.measureElement(currentTourStep.target);
146
+ if (!rect || rect.width === 0 || rect.height === 0) {
147
+ if (attempts < maxPositionAttempts) {
148
+ timeoutId = setTimeout(tryPosition, positionRetryDelayMs);
149
+ }
150
+ return;
151
+ }
152
+ setHighlightRect(rect);
153
+ const placement = currentTourStep.placement ?? defaultPlacement;
154
+ const tooltipDimensions = platform.measureTooltip(tooltipRef);
155
+ const viewportDimensions = platform.getViewportDimensions();
156
+ const position = (0, index_js_1.calculateTooltipPosition)(rect, placement, tooltipDimensions, viewportDimensions);
157
+ setTooltipPosition(position);
158
+ setIsPositioned(true);
159
+ })();
160
+ });
161
+ };
162
+ timeoutId = setTimeout(tryPosition, initialPositionDelayMs);
163
+ return () => {
164
+ clearTimeout(timeoutId);
165
+ if (animationFrameId) {
166
+ platform.cancelFrame(animationFrameId);
167
+ }
168
+ };
169
+ }, [isActive, currentStep, steps, highlightRect, positionKey, platform]);
170
+ (0, react_1.useEffect)(() => {
171
+ if (!isActive) {
172
+ return;
173
+ }
174
+ return platform.subscribeToKeyboard({
175
+ onEscape: endTour,
176
+ onNext: nextStep,
177
+ onPrev: previousStep,
178
+ });
179
+ }, [isActive, endTour, nextStep, previousStep, platform]);
180
+ (0, react_1.useEffect)(() => {
181
+ if (!isActive) {
182
+ return;
183
+ }
184
+ return platform.subscribeToLayout(updatePositions);
185
+ }, [isActive, updatePositions, platform]);
186
+ const currentTourStep = steps[currentStep];
187
+ const contextValue = (0, react_1.useMemo)(() => ({
188
+ isActive,
189
+ currentStep,
190
+ steps,
191
+ currentTourId,
192
+ startTour,
193
+ endTour,
194
+ nextStep,
195
+ prevStep: previousStep,
196
+ goToStep,
197
+ }), [isActive, currentStep, steps, currentTourId, startTour, endTour, nextStep, previousStep, goToStep]);
198
+ return ((0, jsx_runtime_1.jsxs)(index_js_1.TourContext, { value: contextValue, children: [children, (0, jsx_runtime_1.jsx)(Modal, { transparent: true, visible: Boolean(isActive && highlightRect), animationType: "fade", children: highlightRect ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Overlay, { highlightRect: highlightRect, theme: resolvedTheme, onClose: endTour }), currentTourStep ? ((0, jsx_runtime_1.jsx)(Tooltip, { ref: tooltipRef, content: currentTourStep.content, currentStep: currentStep, isPositioned: isPositioned, position: tooltipPosition, theme: resolvedTheme, title: currentTourStep.title, totalSteps: steps.length, onClose: endTour, onGoToStep: goToStep, onNext: nextStep, onPrev: previousStep })) : null] })) : null })] }));
199
+ }
200
+ //# sourceMappingURL=tour-provider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tour-provider.js","sourceRoot":"","sources":["../../src/react-native-platform/tour-provider.tsx"],"names":[],"mappings":";;AAwBA,oCA0QC;;AAlSD,iCAAkF;AAElF,iDAO4B;AAC5B,4DAA4E;AAC5E,4DAA4E;AAC5E,yDAAyD;AAGzD,MAAM,EAAC,KAAK,EAAC,GAAG,OAAO,CAAC,cAAc,CAAkC,CAAC;AAEzE,MAAM,gBAAgB,GAAG,QAAiB,CAAC;AAC3C,MAAM,aAAa,GAAG,GAAG,CAAC;AAC1B,MAAM,oBAAoB,GAAG,GAAG,CAAC;AACjC,MAAM,sBAAsB,GAAG,EAAE,CAAC;AAClC,MAAM,mBAAmB,GAAG,EAAE,CAAC;AAC/B,MAAM,gBAAgB,GAAG,GAAG,CAAC;AAE7B,SAAgB,YAAY,CAAC,EAC3B,QAAQ,EACR,gBAAgB,EAChB,gBAAgB,EAChB,SAAS,EACT,KAAK,EACL,QAAQ,GAAG,wCAAqB,GACd;IAClB,MAAM,aAAa,GAAG,IAAA,eAAO,EAAC,GAAG,EAAE,CAAC,IAAA,uBAAY,EAAC,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC;IAClE,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,IAAA,gBAAQ,EAAC,KAAK,CAAC,CAAC;IAChD,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,IAAA,gBAAQ,EAAC,CAAC,CAAC,CAAC;IAClD,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,IAAA,gBAAQ,EAAa,EAAE,CAAC,CAAC;IACnD,MAAM,CAAC,aAAa,EAAE,gBAAgB,CAAC,GAAG,IAAA,gBAAQ,EAAqB,SAAS,CAAC,CAAC;IAClF,MAAM,CAAC,eAAe,EAAE,kBAAkB,CAAC,GAAG,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AAK,EAAE,YAAY,aAC7B,QAAQ,EAET,uBAAC,KAAK,IAAC,WAAW,QAAC,OAAO,EAAE,OAAO,CAAC,QAAQ,IAAI,aAAa,CAAC,EAAE,aAAa,EAAC,MAAM,YACjF,aAAa,CAAC,CAAC,CAAC,CACf,6DACE,uBAAC,OAAO,IAAC,aAAa,EAAE,aAAa,EAAE,KAAK,EAAE,aAAa,EAAE,OAAO,EAAE,OAAO,GAAI,EAEhF,eAAe,CAAC,CAAC,CAAC,CACjB,uBAAC,OAAO,IACN,GAAG,EAAE,UAAU,EACf,OAAO,EAAE,eAAe,CAAC,OAAO,EAChC,WAAW,EAAE,WAAW,EACxB,YAAY,EAAE,YAAY,EAC1B,QAAQ,EAAE,eAAe,EACzB,KAAK,EAAE,aAAa,EACpB,KAAK,EAAE,eAAe,CAAC,KAAK,EAC5B,UAAU,EAAE,KAAK,CAAC,MAAM,EACxB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,QAAQ,EACpB,MAAM,EAAE,QAAQ,EAChB,MAAM,EAAE,YAAY,GACpB,CACH,CAAC,CAAC,CAAC,IAAI,IACP,CACJ,CAAC,CAAC,CAAC,IAAI,GACF,IACI,CACf,CAAC;AACJ,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { type ComponentType, type ReactNode } from 'react';
2
+ import { type PlatformAdapter, type TourOverlayProps, type TourTheme, type TourTooltipProps } from 'src/shared';
3
+ export type TourProviderProps = {
4
+ readonly children: ReactNode;
5
+ readonly TooltipComponent?: ComponentType<TourTooltipProps>;
6
+ readonly OverlayComponent?: ComponentType<TourOverlayProps>;
7
+ readonly onTourEnd?: (tourId: string | undefined) => void;
8
+ readonly theme?: TourTheme;
9
+ readonly platform?: PlatformAdapter;
10
+ };
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=tour-provider.props.type.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tour-provider.props.type.js","sourceRoot":"","sources":["../../../src/react-native-platform/types/tour-provider.props.type.ts"],"names":[],"mappings":""}
@@ -0,0 +1,8 @@
1
+ export { TourProvider, type TourProviderProps } from './react-native-platform';
2
+ export { TourContext, useTour } from './shared';
3
+ export { useTourTarget } from './react-native-platform';
4
+ export { TourOverlay, TourTooltip } from './react-native-platform';
5
+ export type { TourStep, TourContextType, TourTooltipProps, TourOverlayProps, TourTheme } from './shared';
6
+ export type { Rect, TourTarget } from './shared';
7
+ export { calculateTooltipPosition } from './shared';
8
+ export { nativePlatformAdapter, targetRegistry } from './react-native-platform';
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.targetRegistry = exports.nativePlatformAdapter = exports.calculateTooltipPosition = exports.TourTooltip = exports.TourOverlay = exports.useTourTarget = exports.useTour = exports.TourContext = exports.TourProvider = void 0;
4
+ var react_native_platform_1 = require("./react-native-platform");
5
+ Object.defineProperty(exports, "TourProvider", { enumerable: true, get: function () { return react_native_platform_1.TourProvider; } });
6
+ var shared_1 = require("./shared");
7
+ Object.defineProperty(exports, "TourContext", { enumerable: true, get: function () { return shared_1.TourContext; } });
8
+ Object.defineProperty(exports, "useTour", { enumerable: true, get: function () { return shared_1.useTour; } });
9
+ var react_native_platform_2 = require("./react-native-platform");
10
+ Object.defineProperty(exports, "useTourTarget", { enumerable: true, get: function () { return react_native_platform_2.useTourTarget; } });
11
+ var react_native_platform_3 = require("./react-native-platform");
12
+ Object.defineProperty(exports, "TourOverlay", { enumerable: true, get: function () { return react_native_platform_3.TourOverlay; } });
13
+ Object.defineProperty(exports, "TourTooltip", { enumerable: true, get: function () { return react_native_platform_3.TourTooltip; } });
14
+ var shared_2 = require("./shared");
15
+ Object.defineProperty(exports, "calculateTooltipPosition", { enumerable: true, get: function () { return shared_2.calculateTooltipPosition; } });
16
+ var react_native_platform_4 = require("./react-native-platform");
17
+ Object.defineProperty(exports, "nativePlatformAdapter", { enumerable: true, get: function () { return react_native_platform_4.nativePlatformAdapter; } });
18
+ Object.defineProperty(exports, "targetRegistry", { enumerable: true, get: function () { return react_native_platform_4.targetRegistry; } });
19
+ //# sourceMappingURL=react-native.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"react-native.js","sourceRoot":"","sources":["../src/react-native.ts"],"names":[],"mappings":";;;AAKA,iEAA6E;AAArE,qHAAA,YAAY,OAAA;AAEpB,mCAA8C;AAAtC,qGAAA,WAAW,OAAA;AAAE,iGAAA,OAAO,OAAA;AAE5B,iEAAsD;AAA9C,sHAAA,aAAa,OAAA;AAIrB,iEAAiE;AAAzD,oHAAA,WAAW,OAAA;AAAE,oHAAA,WAAW,OAAA;AAUhC,mCAAkD;AAA1C,kHAAA,wBAAwB,OAAA;AAIhC,iEAA8E;AAAtE,8HAAA,qBAAqB,OAAA;AAAE,uHAAA,cAAc,OAAA"}
@@ -0,0 +1,2 @@
1
+ export { TourOverlay } from './tour-overlay';
2
+ export { TourTooltip } from './tour-tooltip';
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TourTooltip = exports.TourOverlay = void 0;
4
+ var tour_overlay_1 = require("./tour-overlay");
5
+ Object.defineProperty(exports, "TourOverlay", { enumerable: true, get: function () { return tour_overlay_1.TourOverlay; } });
6
+ var tour_tooltip_1 = require("./tour-tooltip");
7
+ Object.defineProperty(exports, "TourTooltip", { enumerable: true, get: function () { return tour_tooltip_1.TourTooltip; } });
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/react-platform/components/index.ts"],"names":[],"mappings":";;;AAAA,+CAA2C;AAAnC,2GAAA,WAAW,OAAA;AAEnB,+CAA2C;AAAnC,2GAAA,WAAW,OAAA"}
@@ -0,0 +1,3 @@
1
+ import { type JSX } from 'react';
2
+ import { type TourOverlayProps } from '../../shared';
3
+ export declare function TourOverlay({ highlightRect, onClose, theme }: TourOverlayProps): JSX.Element;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ 'use client';
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.TourOverlay = TourOverlay;
5
+ const jsx_runtime_1 = require("react/jsx-runtime");
6
+ const highlightPadding = 8;
7
+ const borderRadius = 8;
8
+ function TourOverlay({ highlightRect, onClose, theme }) {
9
+ const primaryColorRgba = `${theme.primaryColor}4D`;
10
+ return ((0, jsx_runtime_1.jsxs)("div", { style: {
11
+ position: 'fixed',
12
+ inset: 0,
13
+ zIndex: 9998,
14
+ }, onClick: onClose, children: [(0, jsx_runtime_1.jsxs)("svg", { style: {
15
+ position: 'absolute',
16
+ inset: 0,
17
+ height: '100%',
18
+ width: '100%',
19
+ }, children: [(0, jsx_runtime_1.jsx)("defs", { children: (0, jsx_runtime_1.jsxs)("mask", { id: "tour-mask", children: [(0, jsx_runtime_1.jsx)("rect", { x: "0", y: "0", width: "100%", height: "100%", fill: "white" }), (0, jsx_runtime_1.jsx)("rect", { x: highlightRect.left - highlightPadding, y: highlightRect.top - highlightPadding, width: highlightRect.width + highlightPadding * 2, height: highlightRect.height + highlightPadding * 2, rx: borderRadius, fill: "black" })] }) }), (0, jsx_runtime_1.jsx)("rect", { x: "0", y: "0", width: "100%", height: "100%", fill: theme.overlayColor, mask: "url(#tour-mask)" })] }), (0, jsx_runtime_1.jsx)("div", { style: {
20
+ position: 'absolute',
21
+ borderRadius: '8px',
22
+ border: `2px solid ${theme.primaryColor}`,
23
+ boxShadow: `0 0 0 4px ${primaryColorRgba}`,
24
+ pointerEvents: 'none',
25
+ top: highlightRect.top - highlightPadding,
26
+ left: highlightRect.left - highlightPadding,
27
+ width: highlightRect.width + highlightPadding * 2,
28
+ height: highlightRect.height + highlightPadding * 2,
29
+ } })] }));
30
+ }
31
+ //# sourceMappingURL=tour-overlay.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tour-overlay.js","sourceRoot":"","sources":["../../../src/react-platform/components/tour-overlay.tsx"],"names":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,KAAK;oBACnB,MAAM,EAAE,aAAa,KAAK,CAAC,YAAY,EAAE;oBACzC,SAAS,EAAE,aAAa,gBAAgB,EAAE;oBAC1C,aAAa,EAAE,MAAM;oBACrB,GAAG,EAAE,aAAa,CAAC,GAAG,GAAG,gBAAgB;oBACzC,IAAI,EAAE,aAAa,CAAC,IAAI,GAAG,gBAAgB;oBAC3C,KAAK,EAAE,aAAa,CAAC,KAAK,GAAG,gBAAgB,GAAG,CAAC;oBACjD,MAAM,EAAE,aAAa,CAAC,MAAM,GAAG,gBAAgB,GAAG,CAAC;iBACpD,GACD,IACE,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,2 @@
1
+ import { type TourTooltipProps } from '../../shared';
2
+ export declare const TourTooltip: import("react").ForwardRefExoticComponent<TourTooltipProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,126 @@
1
+ "use strict";
2
+ 'use client';
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.TourTooltip = void 0;
5
+ const jsx_runtime_1 = require("react/jsx-runtime");
6
+ const react_1 = require("react");
7
+ function TourTooltipComponent({ title, content, currentStep, totalSteps, position, isPositioned, onClose, onNext, onPrev, onGoToStep, theme, }, ref) {
8
+ const isLastStep = currentStep === totalSteps - 1;
9
+ const isFirstStep = currentStep === 0;
10
+ const styles = {
11
+ container: {
12
+ position: 'fixed',
13
+ zIndex: 9999,
14
+ width: '400px',
15
+ maxWidth: 'calc(100vw - 2rem)',
16
+ },
17
+ card: {
18
+ backgroundColor: theme.tooltipBackground,
19
+ borderRadius: '8px',
20
+ boxShadow: '0 25px 50px -12px rgba(0, 0, 0, 0.25)',
21
+ overflow: 'hidden',
22
+ },
23
+ header: {
24
+ display: 'flex',
25
+ alignItems: 'center',
26
+ justifyContent: 'space-between',
27
+ padding: '16px 16px 0 16px',
28
+ },
29
+ stepTag: {
30
+ backgroundColor: theme.primaryColor,
31
+ color: 'white',
32
+ padding: '4px 8px',
33
+ borderRadius: '4px',
34
+ fontSize: '12px',
35
+ fontWeight: 600,
36
+ },
37
+ closeButton: {
38
+ background: 'none',
39
+ border: 'none',
40
+ cursor: 'pointer',
41
+ padding: '8px',
42
+ borderRadius: '50%',
43
+ color: theme.contentColor,
44
+ fontSize: '16px',
45
+ },
46
+ body: {
47
+ padding: '16px',
48
+ },
49
+ title: {
50
+ margin: '0 0 8px 0',
51
+ fontSize: '18px',
52
+ fontWeight: 600,
53
+ color: theme.titleColor,
54
+ },
55
+ content: {
56
+ margin: 0,
57
+ fontSize: '14px',
58
+ color: theme.contentColor,
59
+ lineHeight: 1.5,
60
+ },
61
+ footer: {
62
+ display: 'flex',
63
+ alignItems: 'center',
64
+ justifyContent: 'space-between',
65
+ padding: '0 16px 16px 16px',
66
+ },
67
+ navButton: {
68
+ background: 'none',
69
+ border: 'none',
70
+ cursor: 'pointer',
71
+ padding: '8px 16px',
72
+ borderRadius: '4px',
73
+ fontSize: '14px',
74
+ color: theme.contentColor,
75
+ },
76
+ navButtonDisabled: {
77
+ opacity: 0.5,
78
+ cursor: 'not-allowed',
79
+ },
80
+ nextButton: {
81
+ backgroundColor: theme.primaryColor,
82
+ color: 'white',
83
+ border: 'none',
84
+ cursor: 'pointer',
85
+ padding: '8px 16px',
86
+ borderRadius: '4px',
87
+ fontSize: '14px',
88
+ fontWeight: 500,
89
+ },
90
+ dotsContainer: {
91
+ display: 'flex',
92
+ gap: '6px',
93
+ },
94
+ dot: {
95
+ width: '8px',
96
+ height: '8px',
97
+ borderRadius: '50%',
98
+ border: 'none',
99
+ cursor: 'pointer',
100
+ padding: 0,
101
+ },
102
+ dotActive: {
103
+ backgroundColor: theme.primaryColor,
104
+ },
105
+ dotInactive: {
106
+ backgroundColor: '#d1d5db',
107
+ },
108
+ };
109
+ return ((0, jsx_runtime_1.jsx)("div", { ref: ref, style: {
110
+ ...styles.container,
111
+ top: `${position.top}px`,
112
+ left: `${position.left}px`,
113
+ opacity: isPositioned ? 1 : 0,
114
+ pointerEvents: isPositioned ? 'auto' : 'none',
115
+ }, children: (0, jsx_runtime_1.jsxs)("div", { style: styles.card, children: [(0, jsx_runtime_1.jsxs)("div", { style: styles.header, children: [(0, jsx_runtime_1.jsxs)("span", { style: styles.stepTag, children: [currentStep + 1, " / ", totalSteps] }), (0, jsx_runtime_1.jsx)("button", { type: "button", style: styles.closeButton, "aria-label": "Close tour", onClick: onClose, children: "\u2715" })] }), (0, jsx_runtime_1.jsxs)("div", { style: styles.body, children: [(0, jsx_runtime_1.jsx)("h3", { style: styles.title, children: title }), (0, jsx_runtime_1.jsx)("p", { style: styles.content, children: content })] }), (0, jsx_runtime_1.jsxs)("div", { style: styles.footer, children: [(0, jsx_runtime_1.jsx)("button", { type: "button", style: {
116
+ ...styles.navButton,
117
+ ...(isFirstStep ? styles.navButtonDisabled : {}),
118
+ }, disabled: isFirstStep, onClick: onPrev, children: "\u2190 Back" }), (0, jsx_runtime_1.jsx)("div", { style: styles.dotsContainer, children: Array.from({ length: totalSteps }).map((_, index) => ((0, jsx_runtime_1.jsx)("button", { type: "button", style: {
119
+ ...styles.dot,
120
+ ...(index === currentStep ? styles.dotActive : styles.dotInactive),
121
+ }, "aria-label": `Go to step ${index + 1}`, onClick: () => {
122
+ onGoToStep(index);
123
+ } }, `step-${index}`))) }), (0, jsx_runtime_1.jsx)("button", { type: "button", style: styles.nextButton, onClick: onNext, children: isLastStep ? 'Finish' : 'Next →' })] })] }) }));
124
+ }
125
+ exports.TourTooltip = (0, react_1.forwardRef)(TourTooltipComponent);
126
+ //# sourceMappingURL=tour-tooltip.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tour-tooltip.js","sourceRoot":"","sources":["../../../src/react-platform/components/tour-tooltip.tsx"],"names":[],"mappings":";AAAA,YAAY,CAAC;;;;AAEb,iCAA8D;AAG9D,SAAS,oBAAoB,CAC3B,EACE,KAAK,EACL,OAAO,EACP,WAAW,EACX,UAAU,EACV,QAAQ,EACR,YAAY,EACZ,OAAO,EACP,MAAM,EACN,MAAM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C,EAAE,EACrC,OAAO,EAAE,GAAG,EAAE;oCACZ,UAAU,CAAC,KAAK,CAAC,CAAC;gCACpB,CAAC,IATI,QAAQ,KAAK,EAAE,CAUpB,CACH,CAAC,GACE,EAEN,mCAAQ,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAE,MAAM,CAAC,UAAU,EAAE,OAAO,EAAE,MAAM,YAC5D,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,GAC1B,IACL,IACF,GACF,CACP,CAAC;AACJ,CAAC;AAEY,QAAA,WAAW,GAAG,IAAA,kBAAU,EAAC,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ export { TourProvider } from './tour-provider';
2
+ export type { TourProviderProps } from './types/tour-provider.props.type';
3
+ export { TourOverlay } from './components/tour-overlay';
4
+ export { TourTooltip } from './components/tour-tooltip';
5
+ export { webPlatformAdapter } from './platform-adapter';
6
+ export { findVisibleElement } from './utils';
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.findVisibleElement = exports.webPlatformAdapter = exports.TourTooltip = exports.TourOverlay = exports.TourProvider = void 0;
4
+ var tour_provider_1 = require("./tour-provider");
5
+ Object.defineProperty(exports, "TourProvider", { enumerable: true, get: function () { return tour_provider_1.TourProvider; } });
6
+ var tour_overlay_1 = require("./components/tour-overlay");
7
+ Object.defineProperty(exports, "TourOverlay", { enumerable: true, get: function () { return tour_overlay_1.TourOverlay; } });
8
+ var tour_tooltip_1 = require("./components/tour-tooltip");
9
+ Object.defineProperty(exports, "TourTooltip", { enumerable: true, get: function () { return tour_tooltip_1.TourTooltip; } });
10
+ var platform_adapter_1 = require("./platform-adapter");
11
+ Object.defineProperty(exports, "webPlatformAdapter", { enumerable: true, get: function () { return platform_adapter_1.webPlatformAdapter; } });
12
+ var utils_1 = require("./utils");
13
+ Object.defineProperty(exports, "findVisibleElement", { enumerable: true, get: function () { return utils_1.findVisibleElement; } });
14
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/react-platform/index.ts"],"names":[],"mappings":";;;AAEA,iDAA6C;AAArC,6GAAA,YAAY,OAAA;AAGpB,0DAAsD;AAA9C,2GAAA,WAAW,OAAA;AAEnB,0DAAsD;AAA9C,2GAAA,WAAW,OAAA;AAInB,uDAAsD;AAA9C,sHAAA,kBAAkB,OAAA;AAI1B,iCAA2C;AAAnC,2GAAA,kBAAkB,OAAA"}
@@ -0,0 +1,2 @@
1
+ import { type PlatformAdapter } from '../shared';
2
+ export declare const webPlatformAdapter: PlatformAdapter;
@@ -0,0 +1,95 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.webPlatformAdapter = void 0;
4
+ const utils_1 = require("./utils");
5
+ function domRectToRect(domRect) {
6
+ return {
7
+ top: domRect.top,
8
+ left: domRect.left,
9
+ width: domRect.width,
10
+ height: domRect.height,
11
+ bottom: domRect.bottom,
12
+ right: domRect.right,
13
+ };
14
+ }
15
+ exports.webPlatformAdapter = {
16
+ async measureElement(target) {
17
+ if (typeof target !== 'string') {
18
+ const element = target.current;
19
+ if (!element) {
20
+ return undefined;
21
+ }
22
+ return domRectToRect(element.getBoundingClientRect());
23
+ }
24
+ const element = (0, utils_1.findVisibleElement)(target);
25
+ if (!element) {
26
+ return undefined;
27
+ }
28
+ return domRectToRect(element.getBoundingClientRect());
29
+ },
30
+ measureTooltip(ref) {
31
+ const element = ref.current;
32
+ return {
33
+ width: element?.offsetWidth ?? 0,
34
+ height: element?.offsetHeight ?? 0,
35
+ };
36
+ },
37
+ getViewportDimensions() {
38
+ return {
39
+ width: window.innerWidth,
40
+ height: window.innerHeight,
41
+ };
42
+ },
43
+ async scrollToElement(target) {
44
+ const element = typeof target === 'string' ? (0, utils_1.findVisibleElement)(target) : target.current;
45
+ if (element) {
46
+ element.scrollIntoView({ behavior: 'smooth', block: 'center' });
47
+ }
48
+ },
49
+ subscribeToKeyboard(handlers) {
50
+ const handleKeyDown = (event) => {
51
+ switch (event.key) {
52
+ case 'Escape': {
53
+ handlers.onEscape();
54
+ break;
55
+ }
56
+ case 'ArrowRight': {
57
+ handlers.onNext();
58
+ break;
59
+ }
60
+ case 'ArrowLeft': {
61
+ handlers.onPrev();
62
+ break;
63
+ }
64
+ default: {
65
+ break;
66
+ }
67
+ }
68
+ };
69
+ globalThis.addEventListener('keydown', handleKeyDown);
70
+ return () => {
71
+ globalThis.removeEventListener('keydown', handleKeyDown);
72
+ };
73
+ },
74
+ subscribeToLayout(callback) {
75
+ window.addEventListener('resize', callback);
76
+ window.addEventListener('scroll', callback, true);
77
+ return () => {
78
+ window.removeEventListener('resize', callback);
79
+ window.removeEventListener('scroll', callback, true);
80
+ };
81
+ },
82
+ scheduleFrame(callback) {
83
+ return requestAnimationFrame(callback);
84
+ },
85
+ cancelFrame(id) {
86
+ cancelAnimationFrame(id);
87
+ },
88
+ findElement(target) {
89
+ if (typeof target === 'string') {
90
+ return (0, utils_1.findVisibleElement)(target);
91
+ }
92
+ return target.current ?? undefined;
93
+ },
94
+ };
95
+ //# sourceMappingURL=platform-adapter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform-adapter.js","sourceRoot":"","sources":["../../src/react-platform/platform-adapter.ts"],"names":[],"mappings":";;;AAEA,mCAA2C;AAK3C,SAAS,aAAa,CAAC,OAAgB;IACrC,OAAO;QACL,GAAG,EAAE,OAAO,CAAC,GAAG;QAChB,IAAI,EAAE,OAAO,CAAC,IAAI;QAClB,KAAK,EAAE,OAAO,CAAC,KAAK;QACpB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,MAAM,EAAE,OAAO,CAAC,MAAM;QACtB,KAAK,EAAE,OAAO,CAAC,KAAK;KACrB,CAAC;AACJ,CAAC;AAKY,QAAA,kBAAkB,GAAoB;IACjD,KAAK,CAAC,cAAc,CAAC,MAAkB;QACrC,IAAI,OAAO,MAAM,KA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IAAI,SAAS,CAAC;IAC7D,CAAC;CACF,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { type JSX } from 'react';
2
+ import { type TourProviderProps } from '.';
3
+ export declare function TourProvider({ children, TooltipComponent, OverlayComponent, onTourEnd, theme, platform, }: TourProviderProps): JSX.Element;