@react-text-game/ui 0.3.0 → 0.3.2
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.
- package/dist/components/InteractiveMapComponent/Hotspot.d.ts.map +1 -1
- package/dist/components/InteractiveMapComponent/Hotspot.js +1 -1
- package/dist/components/InteractiveMapComponent/Hotspot.js.map +1 -1
- package/dist/components/InteractiveMapComponent/ImageHotspot.d.ts +3 -1
- package/dist/components/InteractiveMapComponent/ImageHotspot.d.ts.map +1 -1
- package/dist/components/InteractiveMapComponent/ImageHotspot.js +12 -2
- package/dist/components/InteractiveMapComponent/ImageHotspot.js.map +1 -1
- package/dist/styles/index.css +1 -1
- package/dist/tests/InteractiveMapComponent/ImageHotspot.test.d.ts +2 -0
- package/dist/tests/InteractiveMapComponent/ImageHotspot.test.d.ts.map +1 -0
- package/dist/tests/InteractiveMapComponent/ImageHotspot.test.js +460 -0
- package/dist/tests/InteractiveMapComponent/ImageHotspot.test.js.map +1 -0
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Hotspot.d.ts","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/Hotspot.tsx"],"names":[],"mappings":"AAEA,OAAO,EACH,eAAe,EACf,eAAe,EAClB,MAAM,gCAAgC,CAAC;AAQxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAE5C,KAAK,YAAY,GAAG;IAChB,OAAO,EAAE,eAAe,GAAG,eAAe,CAAC;IAC3C,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;CACzC,CAAC;AAEF,eAAO,MAAM,OAAO,GAAI,gCAAgC,YAAY,
|
|
1
|
+
{"version":3,"file":"Hotspot.d.ts","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/Hotspot.tsx"],"names":[],"mappings":"AAEA,OAAO,EACH,eAAe,EACf,eAAe,EAClB,MAAM,gCAAgC,CAAC;AAQxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAE5C,KAAK,YAAY,GAAG;IAChB,OAAO,EAAE,eAAe,GAAG,eAAe,CAAC;IAC3C,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;CACzC,CAAC;AAEF,eAAO,MAAM,OAAO,GAAI,gCAAgC,YAAY,4CAkDnE,CAAC"}
|
|
@@ -25,6 +25,6 @@ export const Hotspot = ({ hotspot, imagePositionInfo }) => {
|
|
|
25
25
|
hotspotRef.current.style.transform = "translate(-50%, -50%)";
|
|
26
26
|
}
|
|
27
27
|
}, [hotspot.position, imagePositionInfo]);
|
|
28
|
-
return (_jsx("div", { ref: hotspotRef, className: "absolute z-10", children: _jsx(Tooltip, { content: tooltipContent, placement: hotspot.tooltip?.position || "top", disabled: !tooltipContent, children: _jsx("div", { children: hotspot.type === "image" ? (_jsx(ImageHotspot, { hotspot: hotspot })) : hotspot.type === "label" ? (_jsx(LabelHotspot, { hotspot: hotspot })) : (_jsx("div", { children: "Unknown Hotspot Type" })) }) }) }));
|
|
28
|
+
return (_jsx("div", { ref: hotspotRef, className: "absolute z-10", children: _jsx(Tooltip, { content: tooltipContent, placement: hotspot.tooltip?.position || "top", disabled: !tooltipContent, children: _jsx("div", { children: hotspot.type === "image" ? (_jsx(ImageHotspot, { hotspot: hotspot, ...(imagePositionInfo && { imagePositionInfo }) })) : hotspot.type === "label" ? (_jsx(LabelHotspot, { hotspot: hotspot })) : (_jsx("div", { children: "Unknown Hotspot Type" })) }) }) }));
|
|
29
29
|
};
|
|
30
30
|
//# sourceMappingURL=Hotspot.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Hotspot.js","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/Hotspot.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAMb,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AAErD,OAAO,EAAE,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AClC,GACC,GACA,GACR,CACT,CAAC;AACN,CAAC,CAAC"}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { ImageHotspot as ImageHotspotType, MapImageHotspot } from "@react-text-game/core/passages";
|
|
2
|
+
import { ImagePositionInfo } from "./types";
|
|
2
3
|
type ImageHotspotProps = {
|
|
3
4
|
hotspot: MapImageHotspot | ImageHotspotType;
|
|
5
|
+
imagePositionInfo?: ImagePositionInfo;
|
|
4
6
|
};
|
|
5
|
-
export declare const ImageHotspot: ({ hotspot }: ImageHotspotProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const ImageHotspot: ({ hotspot, imagePositionInfo, }: ImageHotspotProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export {};
|
|
7
9
|
//# sourceMappingURL=ImageHotspot.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ImageHotspot.d.ts","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/ImageHotspot.tsx"],"names":[],"mappings":"AAEA,OAAO,EACH,YAAY,IAAI,gBAAgB,EAChC,eAAe,EAClB,MAAM,gCAAgC,CAAC;
|
|
1
|
+
{"version":3,"file":"ImageHotspot.d.ts","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/ImageHotspot.tsx"],"names":[],"mappings":"AAEA,OAAO,EACH,YAAY,IAAI,gBAAgB,EAChC,eAAe,EAClB,MAAM,gCAAgC,CAAC;AAKxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAE5C,KAAK,iBAAiB,GAAG;IACrB,OAAO,EAAE,eAAe,GAAG,gBAAgB,CAAC;IAC5C,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;CACzC,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,iCAG1B,iBAAiB,4CAuEnB,CAAC"}
|
|
@@ -3,7 +3,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { useMemo, useState } from "react";
|
|
4
4
|
import { twMerge } from "tailwind-merge";
|
|
5
5
|
import { callIfFunction } from "./helpers";
|
|
6
|
-
export const ImageHotspot = ({ hotspot }) => {
|
|
6
|
+
export const ImageHotspot = ({ hotspot, imagePositionInfo, }) => {
|
|
7
7
|
const [isHovering, setIsHovering] = useState(false);
|
|
8
8
|
const [isActive, setIsActive] = useState(false);
|
|
9
9
|
const classNames = hotspot.props?.classNames || {};
|
|
@@ -14,7 +14,17 @@ export const ImageHotspot = ({ hotspot }) => {
|
|
|
14
14
|
active: callIfFunction(hotspot.content.active),
|
|
15
15
|
disabled: callIfFunction(hotspot.content.disabled),
|
|
16
16
|
}), [hotspot.content]);
|
|
17
|
-
|
|
17
|
+
// Calculate the combined scale factor from both the map scaling and custom zoom
|
|
18
|
+
const combinedScale = useMemo(() => {
|
|
19
|
+
const scaleFactor = imagePositionInfo?.scaleFactor ?? 1;
|
|
20
|
+
const customZoom = hotspot.props?.zoom || "100%";
|
|
21
|
+
const zoomValue = parseFloat(customZoom) / 100;
|
|
22
|
+
return scaleFactor * zoomValue;
|
|
23
|
+
}, [imagePositionInfo?.scaleFactor, hotspot.props?.zoom]);
|
|
24
|
+
return (_jsx("button", { className: twMerge("cursor-pointer disabled:cursor-not-allowed relative", classNames.container), style: {
|
|
25
|
+
transform: `scale(${combinedScale})`,
|
|
26
|
+
transformOrigin: "center center",
|
|
27
|
+
}, disabled: isDisabled, onMouseEnter: () => setIsHovering(true), onMouseLeave: () => setIsHovering(false), onClick: () => {
|
|
18
28
|
setIsActive(true);
|
|
19
29
|
hotspot.action();
|
|
20
30
|
setTimeout(() => setIsActive(false), 100);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ImageHotspot.js","sourceRoot":"","sources":["../../../src/components/InteractiveMapComponent/ImageHotspot.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAMb,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC1C,OAAO,EAAE,O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C,CAAC,CACjC,cACI,SAAS,EAAE,UAAU,CAAC,QAAQ,EAC9B,GAAG,EAAE,OAAO,CAAC,QAAQ,EACrB,GAAG,EAAC,kBAAkB,GACxB,CACL,CAAC,CAAC,CAAC,CACA,cACI,SAAS,EAAE,UAAU,CAAC,IAAI,EAC1B,GAAG,EAAE,OAAO,CAAC,IAAI,EACjB,GAAG,EAAE,OAAO,CAAC,EAAE,IAAI,SAAS,GAC9B,CACL,GACI,CACZ,CAAC;AACN,CAAC,CAAC"}
|
package/dist/styles/index.css
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ImageHotspot.test.d.ts","sourceRoot":"","sources":["../../../src/tests/InteractiveMapComponent/ImageHotspot.test.tsx"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,460 @@
|
|
|
1
|
+
import { cleanup, render, screen, waitFor } from "@testing-library/react";
|
|
2
|
+
import userEvent from "@testing-library/user-event";
|
|
3
|
+
import { afterEach, beforeEach, describe, expect, mock, test } from "bun:test";
|
|
4
|
+
import { createElement } from "react";
|
|
5
|
+
import { ImageHotspot } from "../../components/InteractiveMapComponent/ImageHotspot";
|
|
6
|
+
describe("ImageHotspot", () => {
|
|
7
|
+
beforeEach(() => {
|
|
8
|
+
// Any setup if needed
|
|
9
|
+
});
|
|
10
|
+
afterEach(() => {
|
|
11
|
+
cleanup();
|
|
12
|
+
});
|
|
13
|
+
describe("Basic Rendering", () => {
|
|
14
|
+
test("renders idle state by default", () => {
|
|
15
|
+
const mockAction = mock(() => { });
|
|
16
|
+
const hotspot = {
|
|
17
|
+
id: "test-hotspot",
|
|
18
|
+
type: "image",
|
|
19
|
+
position: { x: 50, y: 50 },
|
|
20
|
+
content: {
|
|
21
|
+
idle: "/images/idle.png",
|
|
22
|
+
},
|
|
23
|
+
action: mockAction,
|
|
24
|
+
};
|
|
25
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
26
|
+
const image = screen.getByAltText("test-hotspot");
|
|
27
|
+
expect(image).toBeTruthy();
|
|
28
|
+
expect(image.getAttribute("src")).toBe("/images/idle.png");
|
|
29
|
+
});
|
|
30
|
+
test("renders with custom classNames", () => {
|
|
31
|
+
const mockAction = mock(() => { });
|
|
32
|
+
const hotspot = {
|
|
33
|
+
id: "test-hotspot",
|
|
34
|
+
type: "image",
|
|
35
|
+
position: { x: 50, y: 50 },
|
|
36
|
+
content: {
|
|
37
|
+
idle: "/images/idle.png",
|
|
38
|
+
},
|
|
39
|
+
action: mockAction,
|
|
40
|
+
props: {
|
|
41
|
+
classNames: {
|
|
42
|
+
container: "custom-container",
|
|
43
|
+
idle: "custom-idle",
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
};
|
|
47
|
+
const { container } = render(createElement(ImageHotspot, { hotspot }));
|
|
48
|
+
const button = container.querySelector(".custom-container");
|
|
49
|
+
expect(button).toBeTruthy();
|
|
50
|
+
const image = container.querySelector(".custom-idle");
|
|
51
|
+
expect(image).toBeTruthy();
|
|
52
|
+
});
|
|
53
|
+
});
|
|
54
|
+
describe("Interactive States", () => {
|
|
55
|
+
test("shows hover state on mouse enter", async () => {
|
|
56
|
+
const user = userEvent.setup();
|
|
57
|
+
const mockAction = mock(() => { });
|
|
58
|
+
const hotspot = {
|
|
59
|
+
id: "test-hotspot",
|
|
60
|
+
type: "image",
|
|
61
|
+
position: { x: 50, y: 50 },
|
|
62
|
+
content: {
|
|
63
|
+
idle: "/images/idle.png",
|
|
64
|
+
hover: "/images/hover.png",
|
|
65
|
+
},
|
|
66
|
+
action: mockAction,
|
|
67
|
+
};
|
|
68
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
69
|
+
const button = screen.getByRole("button");
|
|
70
|
+
await user.hover(button);
|
|
71
|
+
await waitFor(() => {
|
|
72
|
+
const image = screen.getByAltText("hotspot hover");
|
|
73
|
+
expect(image).toBeTruthy();
|
|
74
|
+
expect(image.getAttribute("src")).toBe("/images/hover.png");
|
|
75
|
+
});
|
|
76
|
+
});
|
|
77
|
+
test("shows idle state on mouse leave", async () => {
|
|
78
|
+
const user = userEvent.setup();
|
|
79
|
+
const mockAction = mock(() => { });
|
|
80
|
+
const hotspot = {
|
|
81
|
+
id: "test-hotspot",
|
|
82
|
+
type: "image",
|
|
83
|
+
position: { x: 50, y: 50 },
|
|
84
|
+
content: {
|
|
85
|
+
idle: "/images/idle.png",
|
|
86
|
+
hover: "/images/hover.png",
|
|
87
|
+
},
|
|
88
|
+
action: mockAction,
|
|
89
|
+
};
|
|
90
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
91
|
+
const button = screen.getByRole("button");
|
|
92
|
+
// Hover
|
|
93
|
+
await user.hover(button);
|
|
94
|
+
await waitFor(() => {
|
|
95
|
+
expect(screen.getByAltText("hotspot hover")).toBeTruthy();
|
|
96
|
+
});
|
|
97
|
+
// Unhover
|
|
98
|
+
await user.unhover(button);
|
|
99
|
+
await waitFor(() => {
|
|
100
|
+
const image = screen.getByAltText("test-hotspot");
|
|
101
|
+
expect(image).toBeTruthy();
|
|
102
|
+
expect(image.getAttribute("src")).toBe("/images/idle.png");
|
|
103
|
+
});
|
|
104
|
+
});
|
|
105
|
+
test("shows active state on click", async () => {
|
|
106
|
+
const user = userEvent.setup();
|
|
107
|
+
const mockAction = mock(() => { });
|
|
108
|
+
const hotspot = {
|
|
109
|
+
id: "test-hotspot",
|
|
110
|
+
type: "image",
|
|
111
|
+
position: { x: 50, y: 50 },
|
|
112
|
+
content: {
|
|
113
|
+
idle: "/images/idle.png",
|
|
114
|
+
active: "/images/active.png",
|
|
115
|
+
},
|
|
116
|
+
action: mockAction,
|
|
117
|
+
};
|
|
118
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
119
|
+
const button = screen.getByRole("button");
|
|
120
|
+
await user.click(button);
|
|
121
|
+
// Active state should show briefly
|
|
122
|
+
await waitFor(() => {
|
|
123
|
+
const image = screen.queryByAltText("hotspot active");
|
|
124
|
+
expect(image).toBeTruthy();
|
|
125
|
+
});
|
|
126
|
+
// Should return to idle after timeout
|
|
127
|
+
await waitFor(() => {
|
|
128
|
+
const image = screen.queryByAltText("test-hotspot");
|
|
129
|
+
expect(image).toBeTruthy();
|
|
130
|
+
}, { timeout: 200 });
|
|
131
|
+
});
|
|
132
|
+
test("calls action on click", async () => {
|
|
133
|
+
const user = userEvent.setup();
|
|
134
|
+
const mockAction = mock(() => { });
|
|
135
|
+
const hotspot = {
|
|
136
|
+
id: "test-hotspot",
|
|
137
|
+
type: "image",
|
|
138
|
+
position: { x: 50, y: 50 },
|
|
139
|
+
content: {
|
|
140
|
+
idle: "/images/idle.png",
|
|
141
|
+
},
|
|
142
|
+
action: mockAction,
|
|
143
|
+
};
|
|
144
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
145
|
+
const button = screen.getByRole("button");
|
|
146
|
+
await user.click(button);
|
|
147
|
+
expect(mockAction).toHaveBeenCalledTimes(1);
|
|
148
|
+
});
|
|
149
|
+
test("shows disabled state when isDisabled is true", () => {
|
|
150
|
+
const mockAction = mock(() => { });
|
|
151
|
+
const hotspot = {
|
|
152
|
+
id: "test-hotspot",
|
|
153
|
+
type: "image",
|
|
154
|
+
position: { x: 50, y: 50 },
|
|
155
|
+
content: {
|
|
156
|
+
idle: "/images/idle.png",
|
|
157
|
+
disabled: "/images/disabled.png",
|
|
158
|
+
},
|
|
159
|
+
action: mockAction,
|
|
160
|
+
isDisabled: true,
|
|
161
|
+
};
|
|
162
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
163
|
+
const image = screen.getByAltText("hotspot disabled");
|
|
164
|
+
expect(image).toBeTruthy();
|
|
165
|
+
expect(image.getAttribute("src")).toBe("/images/disabled.png");
|
|
166
|
+
const button = screen.getByRole("button");
|
|
167
|
+
expect(button.hasAttribute("disabled")).toBe(true);
|
|
168
|
+
});
|
|
169
|
+
test("does not call action when disabled and clicked", async () => {
|
|
170
|
+
const user = userEvent.setup();
|
|
171
|
+
const mockAction = mock(() => { });
|
|
172
|
+
const hotspot = {
|
|
173
|
+
id: "test-hotspot",
|
|
174
|
+
type: "image",
|
|
175
|
+
position: { x: 50, y: 50 },
|
|
176
|
+
content: {
|
|
177
|
+
idle: "/images/idle.png",
|
|
178
|
+
},
|
|
179
|
+
action: mockAction,
|
|
180
|
+
isDisabled: true,
|
|
181
|
+
};
|
|
182
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
183
|
+
const button = screen.getByRole("button");
|
|
184
|
+
await user.click(button);
|
|
185
|
+
expect(mockAction).not.toHaveBeenCalled();
|
|
186
|
+
});
|
|
187
|
+
});
|
|
188
|
+
describe("Dynamic Content (Functions)", () => {
|
|
189
|
+
test("handles content as functions", () => {
|
|
190
|
+
const mockAction = mock(() => { });
|
|
191
|
+
const hotspot = {
|
|
192
|
+
id: "test-hotspot",
|
|
193
|
+
type: "image",
|
|
194
|
+
position: { x: 50, y: 50 },
|
|
195
|
+
content: {
|
|
196
|
+
idle: () => "/images/dynamic-idle.png",
|
|
197
|
+
},
|
|
198
|
+
action: mockAction,
|
|
199
|
+
};
|
|
200
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
201
|
+
const image = screen.getByAltText("test-hotspot");
|
|
202
|
+
expect(image.getAttribute("src")).toBe("/images/dynamic-idle.png");
|
|
203
|
+
});
|
|
204
|
+
test("handles isDisabled as function", () => {
|
|
205
|
+
const mockAction = mock(() => { });
|
|
206
|
+
const hotspot = {
|
|
207
|
+
id: "test-hotspot",
|
|
208
|
+
type: "image",
|
|
209
|
+
position: { x: 50, y: 50 },
|
|
210
|
+
content: {
|
|
211
|
+
idle: "/images/idle.png",
|
|
212
|
+
disabled: "/images/disabled.png",
|
|
213
|
+
},
|
|
214
|
+
action: mockAction,
|
|
215
|
+
isDisabled: () => true,
|
|
216
|
+
};
|
|
217
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
218
|
+
const button = screen.getByRole("button");
|
|
219
|
+
expect(button.hasAttribute("disabled")).toBe(true);
|
|
220
|
+
});
|
|
221
|
+
});
|
|
222
|
+
describe("Scaling with imagePositionInfo", () => {
|
|
223
|
+
test("applies default scale when no imagePositionInfo provided", () => {
|
|
224
|
+
const mockAction = mock(() => { });
|
|
225
|
+
const hotspot = {
|
|
226
|
+
id: "test-hotspot",
|
|
227
|
+
type: "image",
|
|
228
|
+
position: { x: 50, y: 50 },
|
|
229
|
+
content: {
|
|
230
|
+
idle: "/images/idle.png",
|
|
231
|
+
},
|
|
232
|
+
action: mockAction,
|
|
233
|
+
};
|
|
234
|
+
const { container } = render(createElement(ImageHotspot, { hotspot }));
|
|
235
|
+
const button = container.querySelector("button");
|
|
236
|
+
expect(button).toBeTruthy();
|
|
237
|
+
const style = button.style;
|
|
238
|
+
expect(style.transform).toBe("scale(1)");
|
|
239
|
+
});
|
|
240
|
+
test("applies scaleFactor from imagePositionInfo", () => {
|
|
241
|
+
const mockAction = mock(() => { });
|
|
242
|
+
const hotspot = {
|
|
243
|
+
id: "test-hotspot",
|
|
244
|
+
type: "image",
|
|
245
|
+
position: { x: 50, y: 50 },
|
|
246
|
+
content: {
|
|
247
|
+
idle: "/images/idle.png",
|
|
248
|
+
},
|
|
249
|
+
action: mockAction,
|
|
250
|
+
};
|
|
251
|
+
const imagePositionInfo = {
|
|
252
|
+
scaleFactor: 0.5,
|
|
253
|
+
offsetLeft: 100,
|
|
254
|
+
offsetTop: 100,
|
|
255
|
+
scaledWidth: 500,
|
|
256
|
+
scaledHeight: 500,
|
|
257
|
+
};
|
|
258
|
+
const { container } = render(createElement(ImageHotspot, { hotspot, imagePositionInfo }));
|
|
259
|
+
const button = container.querySelector("button");
|
|
260
|
+
expect(button).toBeTruthy();
|
|
261
|
+
const style = button.style;
|
|
262
|
+
expect(style.transform).toBe("scale(0.5)");
|
|
263
|
+
});
|
|
264
|
+
test("combines scaleFactor with custom zoom prop", () => {
|
|
265
|
+
const mockAction = mock(() => { });
|
|
266
|
+
const hotspot = {
|
|
267
|
+
id: "test-hotspot",
|
|
268
|
+
type: "image",
|
|
269
|
+
position: { x: 50, y: 50 },
|
|
270
|
+
content: {
|
|
271
|
+
idle: "/images/idle.png",
|
|
272
|
+
},
|
|
273
|
+
action: mockAction,
|
|
274
|
+
props: {
|
|
275
|
+
zoom: "200%",
|
|
276
|
+
},
|
|
277
|
+
};
|
|
278
|
+
const imagePositionInfo = {
|
|
279
|
+
scaleFactor: 0.5,
|
|
280
|
+
offsetLeft: 100,
|
|
281
|
+
offsetTop: 100,
|
|
282
|
+
scaledWidth: 500,
|
|
283
|
+
scaledHeight: 500,
|
|
284
|
+
};
|
|
285
|
+
const { container } = render(createElement(ImageHotspot, { hotspot, imagePositionInfo }));
|
|
286
|
+
const button = container.querySelector("button");
|
|
287
|
+
expect(button).toBeTruthy();
|
|
288
|
+
const style = button.style;
|
|
289
|
+
// 0.5 (scaleFactor) * 2 (200% zoom) = 1
|
|
290
|
+
expect(style.transform).toBe("scale(1)");
|
|
291
|
+
});
|
|
292
|
+
test("updates scale when imagePositionInfo changes", () => {
|
|
293
|
+
const mockAction = mock(() => { });
|
|
294
|
+
const hotspot = {
|
|
295
|
+
id: "test-hotspot",
|
|
296
|
+
type: "image",
|
|
297
|
+
position: { x: 50, y: 50 },
|
|
298
|
+
content: {
|
|
299
|
+
idle: "/images/idle.png",
|
|
300
|
+
},
|
|
301
|
+
action: mockAction,
|
|
302
|
+
};
|
|
303
|
+
const initialImagePositionInfo = {
|
|
304
|
+
scaleFactor: 0.5,
|
|
305
|
+
offsetLeft: 100,
|
|
306
|
+
offsetTop: 100,
|
|
307
|
+
scaledWidth: 500,
|
|
308
|
+
scaledHeight: 500,
|
|
309
|
+
};
|
|
310
|
+
const { container, rerender } = render(createElement(ImageHotspot, {
|
|
311
|
+
hotspot,
|
|
312
|
+
imagePositionInfo: initialImagePositionInfo,
|
|
313
|
+
}));
|
|
314
|
+
let button = container.querySelector("button");
|
|
315
|
+
expect(button.style.transform).toBe("scale(0.5)");
|
|
316
|
+
// Simulate window resize - update imagePositionInfo
|
|
317
|
+
const updatedImagePositionInfo = {
|
|
318
|
+
scaleFactor: 0.75,
|
|
319
|
+
offsetLeft: 150,
|
|
320
|
+
offsetTop: 150,
|
|
321
|
+
scaledWidth: 750,
|
|
322
|
+
scaledHeight: 750,
|
|
323
|
+
};
|
|
324
|
+
rerender(createElement(ImageHotspot, {
|
|
325
|
+
hotspot,
|
|
326
|
+
imagePositionInfo: updatedImagePositionInfo,
|
|
327
|
+
}));
|
|
328
|
+
button = container.querySelector("button");
|
|
329
|
+
expect(button.style.transform).toBe("scale(0.75)");
|
|
330
|
+
});
|
|
331
|
+
test("applies transform origin center center", () => {
|
|
332
|
+
const mockAction = mock(() => { });
|
|
333
|
+
const hotspot = {
|
|
334
|
+
id: "test-hotspot",
|
|
335
|
+
type: "image",
|
|
336
|
+
position: { x: 50, y: 50 },
|
|
337
|
+
content: {
|
|
338
|
+
idle: "/images/idle.png",
|
|
339
|
+
},
|
|
340
|
+
action: mockAction,
|
|
341
|
+
};
|
|
342
|
+
const imagePositionInfo = {
|
|
343
|
+
scaleFactor: 0.5,
|
|
344
|
+
offsetLeft: 100,
|
|
345
|
+
offsetTop: 100,
|
|
346
|
+
scaledWidth: 500,
|
|
347
|
+
scaledHeight: 500,
|
|
348
|
+
};
|
|
349
|
+
const { container } = render(createElement(ImageHotspot, { hotspot, imagePositionInfo }));
|
|
350
|
+
const button = container.querySelector("button");
|
|
351
|
+
expect(button).toBeTruthy();
|
|
352
|
+
const style = button.style;
|
|
353
|
+
expect(style.transformOrigin).toBe("center center");
|
|
354
|
+
});
|
|
355
|
+
});
|
|
356
|
+
describe("Edge Cases", () => {
|
|
357
|
+
test("handles missing hover content gracefully", async () => {
|
|
358
|
+
const user = userEvent.setup();
|
|
359
|
+
const mockAction = mock(() => { });
|
|
360
|
+
const hotspot = {
|
|
361
|
+
id: "test-hotspot",
|
|
362
|
+
type: "image",
|
|
363
|
+
position: { x: 50, y: 50 },
|
|
364
|
+
content: {
|
|
365
|
+
idle: "/images/idle.png",
|
|
366
|
+
},
|
|
367
|
+
action: mockAction,
|
|
368
|
+
};
|
|
369
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
370
|
+
const button = screen.getByRole("button");
|
|
371
|
+
await user.hover(button);
|
|
372
|
+
// Should still show idle when hover is missing
|
|
373
|
+
const image = screen.getByAltText("test-hotspot");
|
|
374
|
+
expect(image.getAttribute("src")).toBe("/images/idle.png");
|
|
375
|
+
});
|
|
376
|
+
test("handles missing active content gracefully", async () => {
|
|
377
|
+
const user = userEvent.setup();
|
|
378
|
+
const mockAction = mock(() => { });
|
|
379
|
+
const hotspot = {
|
|
380
|
+
id: "test-hotspot",
|
|
381
|
+
type: "image",
|
|
382
|
+
position: { x: 50, y: 50 },
|
|
383
|
+
content: {
|
|
384
|
+
idle: "/images/idle.png",
|
|
385
|
+
},
|
|
386
|
+
action: mockAction,
|
|
387
|
+
};
|
|
388
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
389
|
+
const button = screen.getByRole("button");
|
|
390
|
+
await user.click(button);
|
|
391
|
+
// Should still show idle when active is missing
|
|
392
|
+
const image = screen.getByAltText("test-hotspot");
|
|
393
|
+
expect(image.getAttribute("src")).toBe("/images/idle.png");
|
|
394
|
+
});
|
|
395
|
+
test("handles missing disabled content gracefully", () => {
|
|
396
|
+
const mockAction = mock(() => { });
|
|
397
|
+
const hotspot = {
|
|
398
|
+
id: "test-hotspot",
|
|
399
|
+
type: "image",
|
|
400
|
+
position: { x: 50, y: 50 },
|
|
401
|
+
content: {
|
|
402
|
+
idle: "/images/idle.png",
|
|
403
|
+
},
|
|
404
|
+
action: mockAction,
|
|
405
|
+
isDisabled: true,
|
|
406
|
+
};
|
|
407
|
+
render(createElement(ImageHotspot, { hotspot }));
|
|
408
|
+
// Should show idle when disabled content is missing
|
|
409
|
+
const image = screen.getByAltText("test-hotspot");
|
|
410
|
+
expect(image.getAttribute("src")).toBe("/images/idle.png");
|
|
411
|
+
});
|
|
412
|
+
test("handles zoom prop correctly", () => {
|
|
413
|
+
const mockAction = mock(() => { });
|
|
414
|
+
const hotspot = {
|
|
415
|
+
id: "test-hotspot",
|
|
416
|
+
type: "image",
|
|
417
|
+
position: { x: 50, y: 50 },
|
|
418
|
+
content: {
|
|
419
|
+
idle: "/images/idle.png",
|
|
420
|
+
},
|
|
421
|
+
action: mockAction,
|
|
422
|
+
props: {
|
|
423
|
+
zoom: "150%",
|
|
424
|
+
},
|
|
425
|
+
};
|
|
426
|
+
const { container } = render(createElement(ImageHotspot, { hotspot }));
|
|
427
|
+
const button = container.querySelector("button");
|
|
428
|
+
expect(button).toBeTruthy();
|
|
429
|
+
// parseFloat("150%") / 100 = 1.5
|
|
430
|
+
const style = button.style;
|
|
431
|
+
expect(style.transform).toBe("scale(1.5)");
|
|
432
|
+
});
|
|
433
|
+
test("handles zero scaleFactor", () => {
|
|
434
|
+
const mockAction = mock(() => { });
|
|
435
|
+
const hotspot = {
|
|
436
|
+
id: "test-hotspot",
|
|
437
|
+
type: "image",
|
|
438
|
+
position: { x: 50, y: 50 },
|
|
439
|
+
content: {
|
|
440
|
+
idle: "/images/idle.png",
|
|
441
|
+
},
|
|
442
|
+
action: mockAction,
|
|
443
|
+
};
|
|
444
|
+
const imagePositionInfo = {
|
|
445
|
+
scaleFactor: 0,
|
|
446
|
+
offsetLeft: 100,
|
|
447
|
+
offsetTop: 100,
|
|
448
|
+
scaledWidth: 500,
|
|
449
|
+
scaledHeight: 500,
|
|
450
|
+
};
|
|
451
|
+
const { container } = render(createElement(ImageHotspot, { hotspot, imagePositionInfo }));
|
|
452
|
+
const button = container.querySelector("button");
|
|
453
|
+
expect(button).toBeTruthy();
|
|
454
|
+
const style = button.style;
|
|
455
|
+
// Zero scaleFactor should be preserved (not treated as falsy)
|
|
456
|
+
expect(style.transform).toBe("scale(0)");
|
|
457
|
+
});
|
|
458
|
+
});
|
|
459
|
+
});
|
|
460
|
+
//# sourceMappingURL=ImageHotspot.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ImageHotspot.test.js","sourceRo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
|
3
|
+
"version": "0.3.2",
|
|
4
4
|
"description": "Themeable React UI component library for text-based games with Tailwind CSS v4, featuring story passages, interactive maps, and customizable game interfaces",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"module": "dist/index.js",
|
|
9
9
|
"types": "dist/index.d.ts",
|
|
10
10
|
"repository": "github:laruss/react-text-game",
|
|
11
|
-
"homepage": "https://
|
|
11
|
+
"homepage": "https://reacttextgame.dev/",
|
|
12
12
|
"scripts": {
|
|
13
13
|
"dev": "tsc --watch & tsc-alias --watch & bun run build:css --watch",
|
|
14
14
|
"build": "tsc && tsc-alias && bun run build:css",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"tsc-alias": "^1.8.16",
|
|
49
49
|
"@tailwindcss/postcss": "^4.0.0",
|
|
50
50
|
"postcss": "^8.4.49",
|
|
51
|
-
"@react-text-game/core": "0.
|
|
51
|
+
"@react-text-game/core": "0.5.1"
|
|
52
52
|
},
|
|
53
53
|
"imports": {
|
|
54
54
|
"#*": "./dist/*"
|