xmlui 0.10.13 → 0.10.15

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 (217) hide show
  1. package/dist/lib/{index-Db5iQkFp.mjs → index-axjeT2uJ.mjs} +1626 -1080
  2. package/dist/lib/index.css +1 -1
  3. package/dist/lib/{initMock-B9LtmFJG.mjs → initMock-BoTWMs19.mjs} +1 -1
  4. package/dist/lib/language-server-web-worker.mjs +1 -1
  5. package/dist/lib/language-server.mjs +1 -1
  6. package/dist/lib/{metadata-utils-D90qqMGc.mjs → metadata-utils-CtY0QcvH.mjs} +2 -1
  7. package/dist/lib/{server-common-lmBDLpUh.mjs → server-common-Cine5nRR.mjs} +1 -1
  8. package/dist/lib/xmlui.d.ts +99 -6
  9. package/dist/lib/xmlui.mjs +78 -42
  10. package/dist/metadata/{collectedComponentMetadata-BN8eg9Gr.mjs → collectedComponentMetadata-CQywuPDB.mjs} +17448 -16984
  11. package/dist/metadata/{initMock-J7pN8owj.mjs → initMock-Bi5kF5Af.mjs} +1 -1
  12. package/dist/metadata/style.css +1 -1
  13. package/dist/metadata/xmlui-metadata.mjs +1 -1
  14. package/dist/metadata/xmlui-metadata.umd.js +3 -3
  15. package/dist/scripts/bin/build-lib.js +21 -13
  16. package/dist/scripts/bin/viteConfig.js +3 -1
  17. package/dist/scripts/package.json +2 -3
  18. package/dist/scripts/src/abstractions/scripting/Token.js +2 -0
  19. package/dist/scripts/src/abstractions/scripting/TryScope.js +2 -0
  20. package/dist/scripts/src/abstractions/scripting/modules.js +2 -0
  21. package/dist/scripts/src/components/APICall/APICall.spec.js +910 -0
  22. package/dist/scripts/src/components/Accordion/Accordion.spec.js +969 -0
  23. package/dist/scripts/src/components/Animation/Animation.js +50 -0
  24. package/dist/scripts/src/components/App/App.spec.js +219 -0
  25. package/dist/scripts/src/components/AppHeader/AppHeader.spec.js +169 -0
  26. package/dist/scripts/src/components/AppState/AppState.js +32 -2
  27. package/dist/scripts/src/components/AppState/AppState.spec.js +268 -0
  28. package/dist/scripts/src/components/AppState/AppStateNative.js +27 -3
  29. package/dist/scripts/src/components/AutoComplete/AutoComplete.spec.js +383 -0
  30. package/dist/scripts/src/components/Avatar/Avatar.spec.js +1543 -0
  31. package/dist/scripts/src/components/Backdrop/Backdrop.spec.js +131 -0
  32. package/dist/scripts/src/components/Badge/Badge.spec.js +2214 -0
  33. package/dist/scripts/src/components/Bookmark/Bookmark.spec.js +230 -0
  34. package/dist/scripts/src/components/Breakout/Breakout.spec.js +56 -0
  35. package/dist/scripts/src/components/Button/Button-style.spec.js +274 -0
  36. package/dist/scripts/src/components/Button/Button.js +5 -1
  37. package/dist/scripts/src/components/Button/Button.spec.js +454 -0
  38. package/dist/scripts/src/components/Card/Card.spec.js +150 -0
  39. package/dist/scripts/src/components/Carousel/Carousel.spec.js +343 -0
  40. package/dist/scripts/src/components/Carousel/CarouselNative.js +2 -2
  41. package/dist/scripts/src/components/ChangeListener/ChangeListener.spec.js +169 -0
  42. package/dist/scripts/src/components/Charts/AreaChart/AreaChart.spec.js +999 -0
  43. package/dist/scripts/src/components/Charts/BarChart/BarChart.spec.js +597 -0
  44. package/dist/scripts/src/components/Charts/DonutChart/DonutChart.spec.js +608 -0
  45. package/dist/scripts/src/components/Charts/LabelList/LabelList.spec.js +539 -0
  46. package/dist/scripts/src/components/Charts/Legend/Legend.spec.js +558 -0
  47. package/dist/scripts/src/components/Charts/LineChart/LineChart.spec.js +450 -0
  48. package/dist/scripts/src/components/Charts/PieChart/PieChart.spec.js +584 -0
  49. package/dist/scripts/src/components/Charts/PieChart/PieChartNative.js +41 -2
  50. package/dist/scripts/src/components/Charts/RadarChart/RadarChart.spec.js +571 -0
  51. package/dist/scripts/src/components/Charts/Tooltip/TooltipContent.spec.js +449 -0
  52. package/dist/scripts/src/components/Checkbox/Checkbox.spec.js +964 -0
  53. package/dist/scripts/src/components/CodeBlock/CodeBlock.spec.js +196 -0
  54. package/dist/scripts/src/components/ColorPicker/ColorPicker.spec.js +283 -0
  55. package/dist/scripts/src/components/ColorPicker/ColorPickerNative.js +9 -26
  56. package/dist/scripts/src/components/Column/doc-resources/list-component-data.js +53 -0
  57. package/dist/scripts/src/components/ComponentProvider.js +6 -2
  58. package/dist/scripts/src/components/ContentSeparator/ContentSeparator.spec.js +338 -0
  59. package/dist/scripts/src/components/DateInput/DateInput.spec.js +918 -0
  60. package/dist/scripts/src/components/DatePicker/DatePicker.spec.js +362 -0
  61. package/dist/scripts/src/components/DatePicker/DatePickerNative.js +3 -3
  62. package/dist/scripts/src/components/DropdownMenu/DropdownMenu.spec.js +331 -0
  63. package/dist/scripts/src/components/DropdownMenu/DropdownMenuNative.js +7 -9
  64. package/dist/scripts/src/components/EmojiSelector/EmojiSelector.spec.js +29 -0
  65. package/dist/scripts/src/components/ExpandableItem/ExpandableItem.spec.js +435 -0
  66. package/dist/scripts/src/components/FileInput/FileInput.spec.js +249 -0
  67. package/dist/scripts/src/components/FileUploadDropZone/FileUploadDropZone.spec.js +296 -0
  68. package/dist/scripts/src/components/FlowLayout/FlowLayout.spec.js +518 -0
  69. package/dist/scripts/src/components/Footer/Footer.spec.js +991 -0
  70. package/dist/scripts/src/components/Form/Form.spec.js +1257 -0
  71. package/dist/scripts/src/components/FormItem/FormItem.spec.js +723 -0
  72. package/dist/scripts/src/components/FormItem/ItemWithLabel.js +3 -3
  73. package/dist/scripts/src/components/FormSection/FormSection.js +6 -31
  74. package/dist/scripts/src/components/Fragment/Fragment.spec.js +50 -0
  75. package/dist/scripts/src/components/Heading/H1.spec.js +66 -0
  76. package/dist/scripts/src/components/Heading/H2.spec.js +66 -0
  77. package/dist/scripts/src/components/Heading/H3.spec.js +66 -0
  78. package/dist/scripts/src/components/Heading/H4.spec.js +66 -0
  79. package/dist/scripts/src/components/Heading/H5.spec.js +66 -0
  80. package/dist/scripts/src/components/Heading/H6.spec.js +66 -0
  81. package/dist/scripts/src/components/Heading/Heading.spec.js +897 -0
  82. package/dist/scripts/src/components/HtmlTags/HtmlTags.spec.js +69 -0
  83. package/dist/scripts/src/components/IFrame/IFrame.spec.js +527 -0
  84. package/dist/scripts/src/components/Icon/ArrowDropDown.js +11 -0
  85. package/dist/scripts/src/components/Icon/ArrowDropUp.js +11 -0
  86. package/dist/scripts/src/components/Icon/ArrowLeft.js +11 -0
  87. package/dist/scripts/src/components/Icon/ArrowRight.js +11 -0
  88. package/dist/scripts/src/components/Icon/ChevronDownIcon.js +7 -0
  89. package/dist/scripts/src/components/Icon/ChevronUpIcon.js +7 -0
  90. package/dist/scripts/src/components/Icon/Icon.spec.js +527 -0
  91. package/dist/scripts/src/components/Icon/SunIcon.js +10 -0
  92. package/dist/scripts/src/components/Image/Image.js +2 -1
  93. package/dist/scripts/src/components/Image/Image.spec.js +198 -0
  94. package/dist/scripts/src/components/Image/ImageNative.js +30 -2
  95. package/dist/scripts/src/components/Input/InputLabel.js +25 -0
  96. package/dist/scripts/src/components/Input/index.js +5 -0
  97. package/dist/scripts/src/components/Items/Items.spec.js +397 -0
  98. package/dist/scripts/src/components/Link/Link.spec.js +894 -0
  99. package/dist/scripts/src/components/List/List.spec.js +927 -0
  100. package/dist/scripts/src/components/List/doc-resources/list-component-data.js +53 -0
  101. package/dist/scripts/src/components/Markdown/Markdown.spec.js +188 -0
  102. package/dist/scripts/src/components/ModalDialog/ModalDialog.spec.js +162 -0
  103. package/dist/scripts/src/components/NavGroup/NavGroup.spec.js +212 -0
  104. package/dist/scripts/src/components/NavGroup/NavGroupNative.js +15 -7
  105. package/dist/scripts/src/components/NavLink/NavLink.spec.js +864 -0
  106. package/dist/scripts/src/components/NavPanel/NavPanel.spec.js +864 -0
  107. package/dist/scripts/src/components/NoResult/NoResult.spec.js +863 -0
  108. package/dist/scripts/src/components/NumberBox/NumberBox.spec.js +1237 -0
  109. package/dist/scripts/src/components/Option/Option.spec.js +472 -0
  110. package/dist/scripts/src/components/PageMetaTitle/PageMetaTitle.spec.js +80 -0
  111. package/dist/scripts/src/components/Pagination/Pagination.spec.js +1003 -0
  112. package/dist/scripts/src/components/ProfileMenu/ProfileMenu.js +20 -0
  113. package/dist/scripts/src/components/ProgressBar/ProgressBar.spec.js +166 -0
  114. package/dist/scripts/src/components/Queue/Queue.spec.js +626 -0
  115. package/dist/scripts/src/components/RadioGroup/RadioGroup.spec.js +479 -0
  116. package/dist/scripts/src/components/Redirect/Redirect.spec.js +527 -0
  117. package/dist/scripts/src/components/ResponsiveBar/ResponsiveBar.spec.js +76 -0
  118. package/dist/scripts/src/components/Select/Select.spec.js +527 -0
  119. package/dist/scripts/src/components/SelectionStore/SelectionStoreNative.js +3 -1
  120. package/dist/scripts/src/components/Slider/Slider.js +2 -0
  121. package/dist/scripts/src/components/Slider/Slider.spec.js +574 -0
  122. package/dist/scripts/src/components/Slider/SliderNative.js +63 -26
  123. package/dist/scripts/src/components/Slot/Slot.spec.js +368 -0
  124. package/dist/scripts/src/components/SpaceFiller/SpaceFiller.spec.js +184 -0
  125. package/dist/scripts/src/components/Spinner/Spinner.spec.js +161 -0
  126. package/dist/scripts/src/components/Splitter/HSplitter.spec.js +104 -0
  127. package/dist/scripts/src/components/Splitter/Splitter.spec.js +543 -0
  128. package/dist/scripts/src/components/Splitter/VSplitter.spec.js +104 -0
  129. package/dist/scripts/src/components/Stack/CHStack.spec.js +86 -0
  130. package/dist/scripts/src/components/Stack/CVStack.spec.js +86 -0
  131. package/dist/scripts/src/components/Stack/HStack.spec.js +67 -0
  132. package/dist/scripts/src/components/Stack/Stack.spec.js +654 -0
  133. package/dist/scripts/src/components/Stack/VStack.spec.js +67 -0
  134. package/dist/scripts/src/components/Switch/Switch.spec.js +829 -0
  135. package/dist/scripts/src/components/Table/Table.js +7 -1
  136. package/dist/scripts/src/components/Table/Table.spec.js +555 -0
  137. package/dist/scripts/src/components/Table/TableNative.js +4 -1
  138. package/dist/scripts/src/components/Table/doc-resources/list-component-data.js +53 -0
  139. package/dist/scripts/src/components/Table/useRowSelection.js +215 -1
  140. package/dist/scripts/src/components/TableOfContents/TableOfContents.spec.js +838 -0
  141. package/dist/scripts/src/components/Tabs/Tabs.spec.js +875 -0
  142. package/dist/scripts/src/components/Text/Text.spec.js +1075 -0
  143. package/dist/scripts/src/components/TextArea/TextArea.spec.js +714 -0
  144. package/dist/scripts/src/components/TextBox/TextBox.js +1 -5
  145. package/dist/scripts/src/components/TextBox/TextBox.spec.js +687 -0
  146. package/dist/scripts/src/components/TextBox/TextBoxNative.js +10 -15
  147. package/dist/scripts/src/components/Theme/Theme.spec.js +124 -0
  148. package/dist/scripts/src/components/Theme/ThemeNative.js +2 -6
  149. package/dist/scripts/src/components/TimeInput/TimeInput.js +1 -5
  150. package/dist/scripts/src/components/TimeInput/TimeInput.spec.js +1122 -0
  151. package/dist/scripts/src/components/TimeInput/TimeInputNative.js +2 -9
  152. package/dist/scripts/src/components/Timer/Timer.spec.js +358 -0
  153. package/dist/scripts/src/components/ToneChangerButton/ToneChangerButton.spec.js +414 -0
  154. package/dist/scripts/src/components/ToneSwitch/ToneSwitch.spec.js +89 -0
  155. package/dist/scripts/src/components/Tooltip/Tooltip.spec.js +418 -0
  156. package/dist/scripts/src/components/chart-color-schemes.js +43 -0
  157. package/dist/scripts/src/components-core/ApiBoundComponent.js +38 -24
  158. package/dist/scripts/src/components-core/CompoundComponent.js +1 -1
  159. package/dist/scripts/src/components-core/RestApiProxy.js +84 -8
  160. package/dist/scripts/src/components-core/behaviors/BehaviorContext.js +54 -0
  161. package/dist/scripts/src/components-core/behaviors/CoreBehaviors.js +80 -0
  162. package/dist/scripts/src/components-core/descriptorHelper.js +1 -0
  163. package/dist/scripts/src/components-core/devtools/InspectorDialogVisibilityContext.js +8 -0
  164. package/dist/scripts/src/components-core/parts.js +4 -1
  165. package/dist/scripts/src/components-core/renderers.js +31 -0
  166. package/dist/scripts/src/components-core/rendering/AppRoot.js +2 -1
  167. package/dist/scripts/src/components-core/rendering/ComponentAdapter.js +31 -46
  168. package/dist/scripts/src/components-core/rendering/nodeUtils.js +6 -0
  169. package/dist/scripts/src/components-core/script-runner/simplify-expression.js +386 -0
  170. package/dist/scripts/src/components-core/theming/component-layout-resolver.js +153 -0
  171. package/dist/scripts/src/components-core/theming/layout-resolver.js +2 -0
  172. package/dist/scripts/src/components-core/theming/parse-layout-props.js +98 -0
  173. package/dist/scripts/src/components-core/theming/themes/solid.js +16 -0
  174. package/dist/scripts/src/components-core/utils/audio-utils.js +83 -0
  175. package/dist/scripts/src/index-standalone.js +61 -0
  176. package/dist/scripts/src/index.js +39 -1
  177. package/dist/scripts/src/language-server/server-common.js +151 -0
  178. package/dist/scripts/src/language-server/server-web-worker.js +47 -0
  179. package/dist/scripts/src/language-server/server.js +42 -0
  180. package/dist/scripts/src/language-server/services/common/docs-generation.js +73 -0
  181. package/dist/scripts/src/language-server/services/common/lsp-utils.js +9 -0
  182. package/dist/scripts/src/language-server/services/common/syntax-node-utilities.js +135 -0
  183. package/dist/scripts/src/language-server/services/completion.js +270 -0
  184. package/dist/scripts/src/language-server/services/diagnostic.js +19 -0
  185. package/dist/scripts/src/language-server/services/format.js +430 -0
  186. package/dist/scripts/src/language-server/services/hover.js +164 -0
  187. package/dist/scripts/src/language-server/xmlui-metadata-generated.mjs +16266 -0
  188. package/dist/scripts/src/logging/xmlui.js +21 -0
  189. package/dist/scripts/src/parsers/common/utils.js +19 -0
  190. package/dist/scripts/src/syntax/monaco/grammar.monacoLanguage.js +286 -0
  191. package/dist/scripts/src/syntax/monaco/index.js +14 -0
  192. package/dist/scripts/src/syntax/monaco/xmlui-dark.js +25 -0
  193. package/dist/scripts/src/syntax/monaco/xmlui-light.js +25 -0
  194. package/dist/scripts/src/syntax/monaco/xmluiscript.monacoLanguage.js +310 -0
  195. package/dist/scripts/src/syntax/textMate/index.js +14 -0
  196. package/dist/scripts/src/syntax/textMate/xmlui-dark.json +631 -0
  197. package/dist/scripts/src/syntax/textMate/xmlui-light.json +565 -0
  198. package/dist/scripts/src/syntax/textMate/xmlui.json +564 -0
  199. package/dist/scripts/src/syntax/textMate/xmlui.tmLanguage.json +341 -0
  200. package/dist/scripts/src/testing/ComponentDrivers.js +1327 -0
  201. package/dist/scripts/src/testing/assertions.js +444 -0
  202. package/dist/scripts/src/testing/component-test-helpers.js +389 -0
  203. package/dist/scripts/src/testing/drivers/DateInputDriver.js +19 -0
  204. package/dist/scripts/src/testing/drivers/ModalDialogDriver.js +10 -0
  205. package/dist/scripts/src/testing/drivers/NumberBoxDriver.js +44 -0
  206. package/dist/scripts/src/testing/drivers/SliderDriver.js +20 -0
  207. package/dist/scripts/src/testing/drivers/TextBoxDriver.js +20 -0
  208. package/dist/scripts/src/testing/drivers/TimeInputDriver.js +22 -0
  209. package/dist/scripts/src/testing/drivers/TimerDriver.js +64 -0
  210. package/dist/scripts/src/testing/fixtures.js +513 -0
  211. package/dist/scripts/src/testing/infrastructure/TestBed.js +17 -0
  212. package/dist/scripts/src/testing/infrastructure/main.js +9 -0
  213. package/dist/scripts/src/testing/infrastructure/public/mockServiceWorker.js +266 -0
  214. package/dist/scripts/src/testing/themed-app-test-helpers.js +139 -0
  215. package/dist/standalone/xmlui-standalone.es.d.ts +172 -10
  216. package/dist/standalone/xmlui-standalone.umd.js +36 -36
  217. package/package.json +2 -3
@@ -0,0 +1,527 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ const fixtures_1 = require("../../testing/fixtures");
13
+ // =============================================================================
14
+ // BASIC FUNCTIONALITY TESTS
15
+ // =============================================================================
16
+ fixtures_1.test.describe("Basic Functionality", () => {
17
+ (0, fixtures_1.test)("redirects immediately when visible with 'to' property", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
18
+ yield initTestBed(`
19
+ <App>
20
+ <NavPanel>
21
+ <NavLink to="/" label="Home" />
22
+ <NavLink to="/target" label="Target" />
23
+ <NavLink to="/redirect" label="Redirect" />
24
+ </NavPanel>
25
+ <Pages>
26
+ <Page url="/">Home Page</Page>
27
+ <Page url="/target">Target Page</Page>
28
+ <Page url="/redirect">
29
+ <Redirect to="/target" />
30
+ <Text>This should not be visible</Text>
31
+ </Page>
32
+ </Pages>
33
+ </App>
34
+ `);
35
+ // Navigate to the redirect page
36
+ yield page.getByRole("link", { name: "Redirect" }).click();
37
+ // Should be redirected to target page immediately
38
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target$/);
39
+ yield (0, fixtures_1.expect)(page.getByText("Target Page")).toBeVisible();
40
+ yield (0, fixtures_1.expect)(page.getByText("This should not be visible")).not.toBeVisible();
41
+ }));
42
+ (0, fixtures_1.test)("redirects when 'when' property becomes true", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
43
+ yield initTestBed(`
44
+ <App>
45
+ <NavPanel>
46
+ <NavLink to="/" label="Home" />
47
+ <NavLink to="/target" label="Target" />
48
+ <NavLink to="/conditional" label="Conditional" />
49
+ </NavPanel>
50
+ <Pages>
51
+ <Page url="/">Home Page</Page>
52
+ <Page url="/target">Target Page</Page>
53
+ <Page url="/conditional">
54
+ <Fragment var.shouldRedirect="{false}">
55
+ <Button label="Redirect Now" onClick="shouldRedirect = true" />
56
+ <Redirect when="{shouldRedirect}" to="/target" />
57
+ <Text>Click button to redirect</Text>
58
+ </Fragment>
59
+ </Page>
60
+ </Pages>
61
+ </App>
62
+ `);
63
+ // Navigate to conditional page
64
+ yield page.getByRole("link", { name: "Conditional" }).click();
65
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/conditional$/);
66
+ yield (0, fixtures_1.expect)(page.getByText("Click button to redirect")).toBeVisible();
67
+ // Click button to trigger redirect
68
+ yield page.getByRole("button", { name: "Redirect Now" }).click();
69
+ // Should be redirected to target page
70
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target$/);
71
+ yield (0, fixtures_1.expect)(page.getByText("Target Page")).toBeVisible();
72
+ }));
73
+ (0, fixtures_1.test)("does not redirect when 'when' property is false", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
74
+ yield initTestBed(`
75
+ <App>
76
+ <NavPanel>
77
+ <NavLink to="/" label="Home" />
78
+ <NavLink to="/target" label="Target" />
79
+ <NavLink to="/no-redirect" label="No Redirect" />
80
+ </NavPanel>
81
+ <Pages>
82
+ <Page url="/">Home Page</Page>
83
+ <Page url="/target">Target Page</Page>
84
+ <Page url="/no-redirect">
85
+ <Redirect when="{false}" to="/target" />
86
+ <Text>This should be visible</Text>
87
+ </Page>
88
+ </Pages>
89
+ </App>
90
+ `);
91
+ // Navigate to no-redirect page
92
+ yield page.getByRole("link", { name: "No Redirect" }).click();
93
+ // Should stay on current page (not redirect)
94
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/no-redirect$/);
95
+ yield (0, fixtures_1.expect)(page.getByText("This should be visible")).toBeVisible();
96
+ yield (0, fixtures_1.expect)(page.getByText("Target Page")).not.toBeVisible();
97
+ }));
98
+ (0, fixtures_1.test)("redirects to absolute URLs", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
99
+ yield initTestBed(`
100
+ <App>
101
+ <NavPanel>
102
+ <NavLink to="/" label="Home" />
103
+ <NavLink to="/redirect" label="Redirect" />
104
+ </NavPanel>
105
+ <Pages>
106
+ <Page url="/">Home Page</Page>
107
+ <Page url="/redirect">
108
+ <Redirect to="/accounts/123" />
109
+ <Text>Redirecting...</Text>
110
+ </Page>
111
+ <Page url="/accounts/123">Account 123 Page</Page>
112
+ </Pages>
113
+ </App>
114
+ `);
115
+ // Navigate to redirect page
116
+ yield page.getByRole("link", { name: "Redirect" }).click();
117
+ // Should be redirected to absolute URL
118
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/accounts\/123$/);
119
+ yield (0, fixtures_1.expect)(page.getByText("Account 123 Page")).toBeVisible();
120
+ }));
121
+ (0, fixtures_1.test)("redirects to relative URLs", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
122
+ yield initTestBed(`
123
+ <App>
124
+ <NavPanel>
125
+ <NavLink to="/" label="Home" />
126
+ <NavLink to="/redirect" label="Redirect" />
127
+ </NavPanel>
128
+ <Pages>
129
+ <Page url="/">Home Page</Page>
130
+ <Page url="/redirect">
131
+ <Redirect to="/relative-target" />
132
+ <Text>Redirecting...</Text>
133
+ </Page>
134
+ <Page url="/relative-target">Relative Target Page</Page>
135
+ </Pages>
136
+ </App>
137
+ `);
138
+ // Navigate to redirect page
139
+ yield page.getByRole("link", { name: "Redirect" }).click();
140
+ // Should be redirected to relative URL (using absolute path for reliability)
141
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/relative-target$/);
142
+ yield (0, fixtures_1.expect)(page.getByText("Relative Target Page")).toBeVisible();
143
+ }));
144
+ (0, fixtures_1.test)("redirects with query parameters", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
145
+ yield initTestBed(`
146
+ <App>
147
+ <NavPanel>
148
+ <NavLink to="/" label="Home" />
149
+ <NavLink to="/redirect" label="Redirect" />
150
+ </NavPanel>
151
+ <Pages>
152
+ <Page url="/">Home Page</Page>
153
+ <Page url="/redirect">
154
+ <Redirect to="/target?param=value&count=42" />
155
+ <Text>Redirecting...</Text>
156
+ </Page>
157
+ <Page url="/target">
158
+ <Text>Target with params: {$queryParams.param} - {$queryParams.count}</Text>
159
+ </Page>
160
+ </Pages>
161
+ </App>
162
+ `);
163
+ // Navigate to redirect page
164
+ yield page.getByRole("link", { name: "Redirect" }).click();
165
+ // Should be redirected with query parameters
166
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target\?param=value&count=42$/);
167
+ yield (0, fixtures_1.expect)(page.getByText("Target with params: value - 42")).toBeVisible();
168
+ }));
169
+ (0, fixtures_1.test)("redirects with route parameters", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
170
+ yield initTestBed(`
171
+ <App>
172
+ <NavPanel>
173
+ <NavLink to="/" label="Home" />
174
+ <NavLink to="/redirect" label="Redirect" />
175
+ </NavPanel>
176
+ <Pages>
177
+ <Page url="/">Home Page</Page>
178
+ <Page url="/redirect">
179
+ <Redirect to="/user/john/profile" />
180
+ <Text>Redirecting...</Text>
181
+ </Page>
182
+ <Page url="/user/:userId/profile">
183
+ <Text>User Profile: {$routeParams.userId}</Text>
184
+ </Page>
185
+ </Pages>
186
+ </App>
187
+ `);
188
+ // Navigate to redirect page
189
+ yield page.getByRole("link", { name: "Redirect" }).click();
190
+ // Should be redirected with route parameters
191
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/user\/john\/profile$/);
192
+ yield (0, fixtures_1.expect)(page.getByText("User Profile: john")).toBeVisible();
193
+ }));
194
+ (0, fixtures_1.test)("works with dynamic 'to' property", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
195
+ yield initTestBed(`
196
+ <App>
197
+ <NavPanel>
198
+ <NavLink to="/" label="Home" />
199
+ <NavLink to="/dynamic" label="Dynamic" />
200
+ </NavPanel>
201
+ <Pages>
202
+ <Page url="/">Home Page</Page>
203
+ <Page url="/dynamic">
204
+ <Fragment var.destination="{'/page1'}">
205
+ <Button label="Go to Page 1" onClick="destination = '/page1'" />
206
+ <Button label="Go to Page 2" onClick="destination = '/page2'" />
207
+ <Button label="Redirect Now" onClick="destination = destination + '?from=dynamic'" />
208
+ <Redirect when="{destination.endsWith('?from=dynamic')}" to="{destination}" />
209
+ <Text>Choose destination and click redirect</Text>
210
+ </Fragment>
211
+ </Page>
212
+ <Page url="/page1">Page 1: {$queryParams.from}</Page>
213
+ <Page url="/page2">Page 2: {$queryParams.from}</Page>
214
+ </Pages>
215
+ </App>
216
+ `);
217
+ // Navigate to dynamic page
218
+ yield page.getByRole("link", { name: "Dynamic" }).click();
219
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/dynamic$/);
220
+ // Set destination to page2
221
+ yield page.getByRole("button", { name: "Go to Page 2" }).click();
222
+ // Trigger redirect
223
+ yield page.getByRole("button", { name: "Redirect Now" }).click();
224
+ // Should be redirected to page2 with query parameter
225
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/page2\?from=dynamic$/);
226
+ yield (0, fixtures_1.expect)(page.getByText("Page 2: dynamic")).toBeVisible();
227
+ }));
228
+ (0, fixtures_1.test)("handles empty 'to' property gracefully", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
229
+ yield initTestBed(`
230
+ <App>
231
+ <NavPanel>
232
+ <NavLink to="/" label="Home" />
233
+ <NavLink to="/empty-redirect" label="Empty Redirect" />
234
+ </NavPanel>
235
+ <Pages>
236
+ <Page url="/">Home Page</Page>
237
+ <Page url="/empty-redirect">
238
+ <Redirect to="" />
239
+ <Text>This should be visible since redirect is empty</Text>
240
+ </Page>
241
+ </Pages>
242
+ </App>
243
+ `);
244
+ // Navigate to empty redirect page
245
+ yield page.getByRole("link", { name: "Empty Redirect" }).click();
246
+ // Should stay on current page since 'to' is empty
247
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/empty-redirect$/);
248
+ yield (0, fixtures_1.expect)(page.getByText("This should be visible since redirect is empty")).toBeVisible();
249
+ }));
250
+ (0, fixtures_1.test)("can coexist with other content on the page", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
251
+ yield initTestBed(`
252
+ <App>
253
+ <NavPanel>
254
+ <NavLink to="/" label="Home" />
255
+ <NavLink to="/mixed" label="Mixed Content" />
256
+ </NavPanel>
257
+ <Pages>
258
+ <Page url="/">Home Page</Page>
259
+ <Page url="/mixed">
260
+ <VStack>
261
+ <Text>Before redirect</Text>
262
+ <Redirect when="{false}" to="/target" />
263
+ <Text>After redirect</Text>
264
+ </VStack>
265
+ </Page>
266
+ <Page url="/target">Target Page</Page>
267
+ </Pages>
268
+ </App>
269
+ `);
270
+ // Navigate to mixed content page
271
+ yield page.getByRole("link", { name: "Mixed Content" }).click();
272
+ // Should stay on current page and show all content
273
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/mixed$/);
274
+ yield (0, fixtures_1.expect)(page.getByText("Before redirect")).toBeVisible();
275
+ yield (0, fixtures_1.expect)(page.getByText("After redirect")).toBeVisible();
276
+ }));
277
+ });
278
+ // =============================================================================
279
+ // ACCESSIBILITY TESTS
280
+ // =============================================================================
281
+ fixtures_1.test.describe("Accessibility", () => {
282
+ (0, fixtures_1.test)("is a non-visual component that doesn't affect screen readers", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
283
+ yield initTestBed(`
284
+ <App>
285
+ <NavPanel>
286
+ <NavLink to="/" label="Home" />
287
+ <NavLink to="/accessible" label="Accessible" />
288
+ </NavPanel>
289
+ <Pages>
290
+ <Page url="/">Home Page</Page>
291
+ <Page url="/accessible">
292
+ <VStack>
293
+ <Text>Visible content before</Text>
294
+ <Redirect when="{false}" to="/target" />
295
+ <Text>Visible content after</Text>
296
+ </VStack>
297
+ </Page>
298
+ </Pages>
299
+ </App>
300
+ `);
301
+ // Navigate to page with redirect
302
+ yield page.getByRole("link", { name: "Accessible" }).click();
303
+ // Check that visible content is accessible
304
+ yield (0, fixtures_1.expect)(page.getByText("Visible content before")).toBeVisible();
305
+ yield (0, fixtures_1.expect)(page.getByText("Visible content after")).toBeVisible();
306
+ // The redirect component itself should not be visible or interact with accessibility tools
307
+ yield (0, fixtures_1.expect)(page.getByText("Redirect")).not.toBeVisible();
308
+ }));
309
+ (0, fixtures_1.test)("preserves navigation context for screen readers", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
310
+ yield initTestBed(`
311
+ <App>
312
+ <NavPanel>
313
+ <NavLink to="/" label="Home" />
314
+ <NavLink to="/redirect" label="Redirect to Target" />
315
+ </NavPanel>
316
+ <Pages>
317
+ <Page url="/">Home Page</Page>
318
+ <Page url="/redirect">
319
+ <Redirect to="/target" />
320
+ <Text>Loading...</Text>
321
+ </Page>
322
+ <Page url="/target">
323
+ <Heading level="h1">Target Page</Heading>
324
+ <Text>You have been redirected here</Text>
325
+ </Page>
326
+ </Pages>
327
+ </App>
328
+ `);
329
+ // Navigate via the navigation link
330
+ yield page.getByRole("link", { name: "Redirect to Target" }).click();
331
+ // Should be redirected and have proper heading structure
332
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target$/);
333
+ yield (0, fixtures_1.expect)(page.getByRole("heading", { level: 1, name: "Target Page" })).toBeVisible();
334
+ yield (0, fixtures_1.expect)(page.getByText("You have been redirected here")).toBeVisible();
335
+ }));
336
+ });
337
+ // =============================================================================
338
+ // OTHER EDGE CASES
339
+ // =============================================================================
340
+ fixtures_1.test.describe("Other Edge Cases", () => {
341
+ (0, fixtures_1.test)("handles multiple redirects on the same page", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
342
+ yield initTestBed(`
343
+ <App>
344
+ <NavPanel>
345
+ <NavLink to="/" label="Home" />
346
+ <NavLink to="/multiple" label="Multiple" />
347
+ </NavPanel>
348
+ <Pages>
349
+ <Page url="/">Home Page</Page>
350
+ <Page url="/multiple">
351
+ <Fragment var.condition="{1}">
352
+ <Button label="Set to 1" onClick="condition = 1" />
353
+ <Button label="Set to 2" onClick="condition = 2" />
354
+ <Redirect when="{condition === 1}" to="/target1" />
355
+ <Redirect when="{condition === 2}" to="/target2" />
356
+ <Text>Multiple redirects: {condition}</Text>
357
+ </Fragment>
358
+ </Page>
359
+ <Page url="/target1">Target 1 Page</Page>
360
+ <Page url="/target2">Target 2 Page</Page>
361
+ </Pages>
362
+ </App>
363
+ `);
364
+ // Navigate to multiple redirects page
365
+ yield page.getByRole("link", { name: "Multiple" }).click();
366
+ // Should redirect to target1 immediately (condition starts as 1)
367
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target1$/);
368
+ yield (0, fixtures_1.expect)(page.getByText("Target 1 Page")).toBeVisible();
369
+ }));
370
+ (0, fixtures_1.test)("works with complex conditional logic", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
371
+ yield initTestBed(`
372
+ <App>
373
+ <NavPanel>
374
+ <NavLink to="/" label="Home" />
375
+ <NavLink to="/complex" label="Complex" />
376
+ </NavPanel>
377
+ <Pages>
378
+ <Page url="/">Home Page</Page>
379
+ <Page url="/complex">
380
+ <Fragment var.user="{{name: 'john', role: 'admin'}}">
381
+ <Button label="Make User" onClick="user.role = 'user'" />
382
+ <Button label="Make Admin" onClick="user.role = 'admin'" />
383
+ <Redirect when="{user.role === 'admin'}" to="/admin-dashboard" />
384
+ <Redirect when="{user.role === 'user'}" to="/user-dashboard" />
385
+ <Text>User: {user.name} ({user.role})</Text>
386
+ </Fragment>
387
+ </Page>
388
+ <Page url="/admin-dashboard">Admin Dashboard</Page>
389
+ <Page url="/user-dashboard">User Dashboard</Page>
390
+ </Pages>
391
+ </App>
392
+ `);
393
+ // Navigate to complex page
394
+ yield page.getByRole("link", { name: "Complex" }).click();
395
+ // Should redirect to admin dashboard (user starts as admin)
396
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/admin-dashboard$/);
397
+ yield (0, fixtures_1.expect)(page.getByText("Admin Dashboard")).toBeVisible();
398
+ }));
399
+ (0, fixtures_1.test)("handles special characters in URLs", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
400
+ yield initTestBed(`
401
+ <App>
402
+ <NavPanel>
403
+ <NavLink to="/" label="Home" />
404
+ <NavLink to="/special" label="Special" />
405
+ </NavPanel>
406
+ <Pages>
407
+ <Page url="/">Home Page</Page>
408
+ <Page url="/special">
409
+ <Redirect to="/target-with-dashes-and-underscores_test" />
410
+ <Text>Redirecting...</Text>
411
+ </Page>
412
+ <Page url="/target-with-dashes-and-underscores_test">
413
+ <Text>Special URL Target</Text>
414
+ </Page>
415
+ </Pages>
416
+ </App>
417
+ `);
418
+ // Navigate to special characters page
419
+ yield page.getByRole("link", { name: "Special" }).click();
420
+ // Should handle dashes and underscores in URL
421
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target-with-dashes-and-underscores_test$/);
422
+ yield (0, fixtures_1.expect)(page.getByText("Special URL Target")).toBeVisible();
423
+ }));
424
+ (0, fixtures_1.test)("works within nested components", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
425
+ yield initTestBed(`
426
+ <App>
427
+ <NavPanel>
428
+ <NavLink to="/" label="Home" />
429
+ <NavLink to="/nested" label="Nested" />
430
+ </NavPanel>
431
+ <Pages>
432
+ <Page url="/">Home Page</Page>
433
+ <Page url="/nested">
434
+ <VStack>
435
+ <Card title="Card with Redirect">
436
+ <VStack>
437
+ <Text>Inside a card</Text>
438
+ <Fragment var.shouldRedirect="{false}">
439
+ <Button label="Redirect from Card" onClick="shouldRedirect = true" />
440
+ <Redirect when="{shouldRedirect}" to="/target" />
441
+ </Fragment>
442
+ </VStack>
443
+ </Card>
444
+ </VStack>
445
+ </Page>
446
+ <Page url="/target">Target from Nested</Page>
447
+ </Pages>
448
+ </App>
449
+ `);
450
+ // Navigate to nested page
451
+ yield page.getByRole("link", { name: "Nested" }).click();
452
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/nested$/);
453
+ // Click button inside nested component
454
+ yield page.getByRole("button", { name: "Redirect from Card" }).click();
455
+ // Should redirect from nested context
456
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target$/);
457
+ yield (0, fixtures_1.expect)(page.getByText("Target from Nested")).toBeVisible();
458
+ }));
459
+ (0, fixtures_1.test)("maintains browser history properly", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
460
+ yield initTestBed(`
461
+ <App>
462
+ <NavPanel>
463
+ <NavLink to="/" label="Home" />
464
+ <NavLink to="/step1" label="Step 1" />
465
+ <NavLink to="/redirect-test" label="Redirect Test" />
466
+ </NavPanel>
467
+ <Pages>
468
+ <Page url="/">Home Page</Page>
469
+ <Page url="/step1">Step 1 Page</Page>
470
+ <Page url="/redirect-test">
471
+ <Redirect to="/final" />
472
+ <Text>Redirecting...</Text>
473
+ </Page>
474
+ <Page url="/final">Final Page</Page>
475
+ </Pages>
476
+ </App>
477
+ `);
478
+ // Start at home
479
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/$|#\/$/);
480
+ // Navigate to step1 first to establish history
481
+ yield page.getByRole("link", { name: "Step 1" }).click();
482
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/step1$/);
483
+ // Then navigate to redirect test (which redirects to final)
484
+ yield page.getByRole("link", { name: "Redirect Test" }).click();
485
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/final$/);
486
+ yield (0, fixtures_1.expect)(page.getByText("Final Page")).toBeVisible();
487
+ // Test that browser navigation history exists and functions
488
+ // The exact behavior may vary, but history should be maintained
489
+ yield page.goBack();
490
+ // We should be able to navigate in history (exact destination may vary due to redirects)
491
+ // The key is that history navigation works and doesn't break the app
492
+ const currentUrl = page.url();
493
+ (0, fixtures_1.expect)(currentUrl).toMatch(/(step1|final|redirect-test)/);
494
+ }));
495
+ (0, fixtures_1.test)("handles null/undefined 'to' values gracefully", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
496
+ yield initTestBed(`
497
+ <App>
498
+ <NavPanel>
499
+ <NavLink to="/" label="Home" />
500
+ <NavLink to="/null-redirect" label="Null Redirect" />
501
+ </NavPanel>
502
+ <Pages>
503
+ <Page url="/">Home Page</Page>
504
+ <Page url="/null-redirect">
505
+ <Fragment var.destination="{null}">
506
+ <Button label="Set Null" onClick="destination = null" />
507
+ <Button label="Set Undefined" onClick="destination = undefined" />
508
+ <Button label="Set Valid" onClick="destination = '/target'" />
509
+ <Redirect when="{destination}" to="{destination}" />
510
+ <Text>Destination: {destination || 'none'}</Text>
511
+ </Fragment>
512
+ </Page>
513
+ <Page url="/target">Target Page</Page>
514
+ </Pages>
515
+ </App>
516
+ `);
517
+ // Navigate to null redirect page
518
+ yield page.getByRole("link", { name: "Null Redirect" }).click();
519
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/null-redirect$/);
520
+ // Should show content without redirecting
521
+ yield (0, fixtures_1.expect)(page.getByText("Destination: none")).toBeVisible();
522
+ // Set valid destination and redirect should work
523
+ yield page.getByRole("button", { name: "Set Valid" }).click();
524
+ yield (0, fixtures_1.expect)(page).toHaveURL(/\/target$/);
525
+ yield (0, fixtures_1.expect)(page.getByText("Target Page")).toBeVisible();
526
+ }));
527
+ });
@@ -0,0 +1,76 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ const fixtures_1 = require("../../testing/fixtures");
13
+ fixtures_1.test.describe("ResponsiveBar", () => {
14
+ (0, fixtures_1.test)("renders children in horizontal layout", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
15
+ yield initTestBed(`
16
+ <ResponsiveBar testId="responsive-bar">
17
+ <Button testId="btn1" label="Button 1" />
18
+ <Button testId="btn2" label="Button 2" />
19
+ <Button testId="btn3" label="Button 3" />
20
+ </ResponsiveBar>
21
+ `);
22
+ const responsiveBar = page.getByTestId("responsive-bar");
23
+ yield (0, fixtures_1.expect)(responsiveBar).toBeVisible();
24
+ // All buttons should be visible initially
25
+ yield (0, fixtures_1.expect)(responsiveBar.locator('[data-testid="btn1"]').first()).toBeVisible();
26
+ yield (0, fixtures_1.expect)(responsiveBar.locator('[data-testid="btn2"]').first()).toBeVisible();
27
+ yield (0, fixtures_1.expect)(responsiveBar.locator('[data-testid="btn3"]').first()).toBeVisible();
28
+ }));
29
+ (0, fixtures_1.test)("moves overflowing items to dropdown when container is too narrow", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
30
+ yield initTestBed(`
31
+ <ResponsiveBar testId="responsive-bar" style="width: 200px;">
32
+ <Button testId="btn1" label="Very Long Button 1" />
33
+ <Button testId="btn2" label="Very Long Button 2" />
34
+ <Button testId="btn3" label="Very Long Button 3" />
35
+ <Button testId="btn4" label="Very Long Button 4" />
36
+ </ResponsiveBar>
37
+ `);
38
+ const responsiveBar = page.getByTestId("responsive-bar");
39
+ yield (0, fixtures_1.expect)(responsiveBar).toBeVisible();
40
+ // Wait for the component to finish measuring and laying out
41
+ yield page.waitForTimeout(100);
42
+ // Check if overflow dropdown is present
43
+ const overflowDropdown = responsiveBar.locator(".overflowDropdown").first();
44
+ // If there's an overflow dropdown, some items should be moved there
45
+ if (yield overflowDropdown.isVisible()) {
46
+ // Click the overflow button to see the dropdown menu
47
+ const overflowTrigger = overflowDropdown.locator("svg, button").first();
48
+ yield overflowTrigger.click();
49
+ // Wait for dropdown to appear
50
+ yield page.waitForTimeout(100);
51
+ // There should be some menu items in the dropdown
52
+ const menuItems = page.locator('[role="menuitem"]');
53
+ const menuItemCount = yield menuItems.count();
54
+ (0, fixtures_1.expect)(menuItemCount).toBeGreaterThan(0);
55
+ }
56
+ }));
57
+ (0, fixtures_1.test)("responds to container resize", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
58
+ yield initTestBed(`
59
+ <ResponsiveBar testId="responsive-bar" style="width: 400px; border: 1px solid red;">
60
+ <Button testId="btn1" label="Button 1" />
61
+ <Button testId="btn2" label="Button 2" />
62
+ <Button testId="btn3" label="Button 3" />
63
+ <Button testId="btn4" label="Button 4" />
64
+ </ResponsiveBar>
65
+ `);
66
+ const responsiveBar = page.getByTestId("responsive-bar");
67
+ yield (0, fixtures_1.expect)(responsiveBar).toBeVisible();
68
+ // Initially, check if all buttons are visible or some are in overflow
69
+ yield page.waitForTimeout(100);
70
+ // Check the current state
71
+ const btn1Visible = yield responsiveBar.locator('[data-testid="btn1"]').first().isVisible();
72
+ const btn4Visible = yield responsiveBar.locator('[data-testid="btn4"]').first().isVisible();
73
+ // Verify the component is working - at least the first button should be visible
74
+ (0, fixtures_1.expect)(btn1Visible).toBe(true);
75
+ }));
76
+ });