xmlui 0.11.4 → 0.11.7
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/bin/index.cjs +8836 -0
- package/dist/bin/index.js +8825 -0
- package/dist/lib/{apiInterceptorWorker-QiltRtq1.js → apiInterceptorWorker-dwrAyq6l.js} +126 -151
- package/dist/lib/{index-Cq0EMm3L.js → index-CwYK6iB4.js} +2502 -2675
- package/dist/lib/index.css +1 -1
- package/dist/lib/{initMock-DCigV4Zh.js → initMock-CvmWAkGr.js} +19 -22
- package/dist/lib/language-server-web-worker.js +13 -5
- package/dist/lib/language-server.js +11 -3
- package/dist/lib/{metadata-utils-BiolWMg9.js → metadata-utils-2bsMr4Gd.js} +58 -26
- package/dist/lib/{server-common-DyCHOk-z.js → server-common-DI3W4cob.js} +6297 -5930
- package/dist/lib/syntax-textmate.js +8 -2472
- package/dist/lib/testing.d.ts +1 -0
- package/dist/lib/testing.js +20 -23
- package/dist/lib/{transform-DHf9tQF7.js → transform-CQ_6R-43.js} +159 -126
- package/dist/lib/vite-xmlui-plugin.d.ts +10 -0
- package/dist/lib/vite-xmlui-plugin.js +8316 -0
- package/dist/lib/{xmlui-parser-CHN3mADy.js → xmlui-parser-CW8YmGjO.js} +10 -11
- package/dist/lib/xmlui-parser.js +2 -2
- package/dist/lib/{xmlui-serializer-CYNSHAlP.js → xmlui-serializer-CeCcgdVR.js} +19 -19
- package/dist/lib/xmlui.d.ts +122 -1
- package/dist/lib/xmlui.js +8 -3
- package/dist/metadata/{apiInterceptorWorker-Dql7QGw2.js → apiInterceptorWorker-Wgm2_zjg.js} +124 -149
- package/dist/metadata/{collectedComponentMetadata-CLaDZhmc.js → collectedComponentMetadata-CSFNLstl.js} +3169 -3302
- package/dist/metadata/{initMock-Buqah4JF.js → initMock-CyTd5aE8.js} +19 -22
- package/dist/metadata/xmlui-metadata.css +1 -0
- package/dist/metadata/xmlui-metadata.js +1 -1
- package/dist/metadata/xmlui-metadata.umd.cjs +3 -3
- package/dist/standalone/xmlui-standalone.es.d.ts +171 -2
- package/dist/standalone/xmlui-standalone.umd.js +36 -37
- package/package.json +20 -50
- package/dist/lib/vite-xmlui-plugin/index.js +0 -13985
- package/dist/lib/vite-xmlui-plugin/package.json +0 -3
- package/dist/metadata/style.css +0 -1
- package/dist/scripts/bin/bootstrap.cjs +0 -4
- package/dist/scripts/bin/build-lib.js +0 -126
- package/dist/scripts/bin/build.js +0 -266
- package/dist/scripts/bin/index.js +0 -167
- package/dist/scripts/bin/preview.js +0 -44
- package/dist/scripts/bin/start.js +0 -52
- package/dist/scripts/bin/vite-xmlui-plugin.js +0 -109
- package/dist/scripts/bin/viteConfig.js +0 -144
- package/dist/scripts/package.json +0 -285
- package/dist/scripts/src/abstractions/ActionDefs.js +0 -2
- package/dist/scripts/src/abstractions/AppContextDefs.js +0 -4
- package/dist/scripts/src/abstractions/ComponentDefs.js +0 -2
- package/dist/scripts/src/abstractions/ContainerDefs.js +0 -2
- package/dist/scripts/src/abstractions/ExtensionDefs.js +0 -2
- package/dist/scripts/src/abstractions/FunctionDefs.js +0 -2
- package/dist/scripts/src/abstractions/RendererDefs.js +0 -2
- package/dist/scripts/src/abstractions/ThemingDefs.js +0 -2
- package/dist/scripts/src/abstractions/scripting/BlockScope.js +0 -2
- package/dist/scripts/src/abstractions/scripting/Compilation.js +0 -2
- package/dist/scripts/src/abstractions/scripting/LogicalThread.js +0 -2
- package/dist/scripts/src/abstractions/scripting/LoopScope.js +0 -2
- package/dist/scripts/src/abstractions/scripting/ScriptParserError.js +0 -2
- package/dist/scripts/src/abstractions/scripting/Token.js +0 -2
- package/dist/scripts/src/abstractions/scripting/TryScope.js +0 -2
- package/dist/scripts/src/abstractions/scripting/TryScopeExp.js +0 -2
- package/dist/scripts/src/abstractions/scripting/modules.js +0 -2
- package/dist/scripts/src/components/APICall/APICall.js +0 -130
- package/dist/scripts/src/components/APICall/APICall.spec.js +0 -910
- package/dist/scripts/src/components/APICall/APICallNative.js +0 -36
- package/dist/scripts/src/components/Accordion/Accordion.js +0 -97
- package/dist/scripts/src/components/Accordion/Accordion.spec.js +0 -969
- package/dist/scripts/src/components/Accordion/AccordionContext.js +0 -20
- package/dist/scripts/src/components/Accordion/AccordionItem.js +0 -35
- package/dist/scripts/src/components/Accordion/AccordionItemNative.js +0 -95
- package/dist/scripts/src/components/Accordion/AccordionNative.js +0 -141
- package/dist/scripts/src/components/Animation/AnimationNative.js +0 -263
- package/dist/scripts/src/components/App/App.js +0 -581
- package/dist/scripts/src/components/App/App.spec.js +0 -331
- package/dist/scripts/src/components/App/AppLayoutContext.js +0 -49
- package/dist/scripts/src/components/App/AppNative.js +0 -308
- package/dist/scripts/src/components/App/AppStateContext.js +0 -9
- package/dist/scripts/src/components/App/IndexerContext.js +0 -44
- package/dist/scripts/src/components/App/LinkInfoContext.js +0 -9
- package/dist/scripts/src/components/App/SearchContext.js +0 -35
- package/dist/scripts/src/components/App/Sheet.js +0 -99
- package/dist/scripts/src/components/AppHeader/AppHeader.js +0 -58
- package/dist/scripts/src/components/AppHeader/AppHeader.spec.js +0 -169
- package/dist/scripts/src/components/AppHeader/AppHeaderNative.js +0 -72
- package/dist/scripts/src/components/AppState/AppState.js +0 -75
- package/dist/scripts/src/components/AppState/AppState.spec.js +0 -292
- package/dist/scripts/src/components/AppState/AppStateNative.js +0 -51
- package/dist/scripts/src/components/AutoComplete/AutoComplete.js +0 -109
- package/dist/scripts/src/components/AutoComplete/AutoComplete.spec.js +0 -546
- package/dist/scripts/src/components/AutoComplete/AutoCompleteContext.js +0 -19
- package/dist/scripts/src/components/AutoComplete/AutoCompleteNative.js +0 -498
- package/dist/scripts/src/components/Avatar/Avatar.js +0 -55
- package/dist/scripts/src/components/Avatar/Avatar.spec.js +0 -1514
- package/dist/scripts/src/components/Avatar/AvatarNative.js +0 -58
- package/dist/scripts/src/components/Backdrop/Backdrop.js +0 -40
- package/dist/scripts/src/components/Backdrop/Backdrop.spec.js +0 -131
- package/dist/scripts/src/components/Backdrop/BackdropNative.js +0 -25
- package/dist/scripts/src/components/Badge/Badge.js +0 -81
- package/dist/scripts/src/components/Badge/Badge.spec.js +0 -2214
- package/dist/scripts/src/components/Badge/BadgeNative.js +0 -46
- package/dist/scripts/src/components/Bookmark/Bookmark.js +0 -48
- package/dist/scripts/src/components/Bookmark/Bookmark.spec.js +0 -230
- package/dist/scripts/src/components/Bookmark/BookmarkNative.js +0 -55
- package/dist/scripts/src/components/Breakout/Breakout.js +0 -17
- package/dist/scripts/src/components/Breakout/Breakout.spec.js +0 -56
- package/dist/scripts/src/components/Breakout/BreakoutNative.js +0 -24
- package/dist/scripts/src/components/Button/Button-style.spec.js +0 -274
- package/dist/scripts/src/components/Button/Button.js +0 -171
- package/dist/scripts/src/components/Button/Button.spec.js +0 -425
- package/dist/scripts/src/components/Button/ButtonNative.js +0 -109
- package/dist/scripts/src/components/Card/Card.js +0 -89
- package/dist/scripts/src/components/Card/Card.spec.js +0 -150
- package/dist/scripts/src/components/Card/CardNative.js +0 -41
- package/dist/scripts/src/components/Carousel/Carousel.js +0 -133
- package/dist/scripts/src/components/Carousel/Carousel.spec.js +0 -557
- package/dist/scripts/src/components/Carousel/CarouselContext.js +0 -57
- package/dist/scripts/src/components/Carousel/CarouselItem.js +0 -15
- package/dist/scripts/src/components/Carousel/CarouselItemNative.js +0 -40
- package/dist/scripts/src/components/Carousel/CarouselNative.js +0 -195
- package/dist/scripts/src/components/ChangeListener/ChangeListener.js +0 -34
- package/dist/scripts/src/components/ChangeListener/ChangeListener.spec.js +0 -169
- package/dist/scripts/src/components/ChangeListener/ChangeListenerNative.js +0 -30
- package/dist/scripts/src/components/Charts/AreaChart/AreaChart.js +0 -92
- package/dist/scripts/src/components/Charts/AreaChart/AreaChart.spec.js +0 -999
- package/dist/scripts/src/components/Charts/AreaChart/AreaChartNative.js +0 -127
- package/dist/scripts/src/components/Charts/BarChart/BarChart.js +0 -97
- package/dist/scripts/src/components/Charts/BarChart/BarChart.spec.js +0 -597
- package/dist/scripts/src/components/Charts/BarChart/BarChartNative.js +0 -317
- package/dist/scripts/src/components/Charts/DonutChart/DonutChart.js +0 -60
- package/dist/scripts/src/components/Charts/DonutChart/DonutChart.spec.js +0 -608
- package/dist/scripts/src/components/Charts/LabelList/LabelList.js +0 -41
- package/dist/scripts/src/components/Charts/LabelList/LabelList.spec.js +0 -539
- package/dist/scripts/src/components/Charts/LabelList/LabelListNative.js +0 -25
- package/dist/scripts/src/components/Charts/Legend/Legend.js +0 -33
- package/dist/scripts/src/components/Charts/Legend/Legend.spec.js +0 -558
- package/dist/scripts/src/components/Charts/Legend/LegendNative.js +0 -64
- package/dist/scripts/src/components/Charts/LineChart/LineChart.js +0 -94
- package/dist/scripts/src/components/Charts/LineChart/LineChart.spec.js +0 -450
- package/dist/scripts/src/components/Charts/LineChart/LineChartNative.js +0 -192
- package/dist/scripts/src/components/Charts/PieChart/PieChart.js +0 -64
- package/dist/scripts/src/components/Charts/PieChart/PieChart.spec.js +0 -584
- package/dist/scripts/src/components/Charts/PieChart/PieChartNative.js +0 -167
- package/dist/scripts/src/components/Charts/RadarChart/RadarChart.js +0 -92
- package/dist/scripts/src/components/Charts/RadarChart/RadarChart.spec.js +0 -571
- package/dist/scripts/src/components/Charts/RadarChart/RadarChartNative.js +0 -125
- package/dist/scripts/src/components/Charts/Tooltip/TooltipContent.js +0 -27
- package/dist/scripts/src/components/Charts/Tooltip/TooltipContent.spec.js +0 -451
- package/dist/scripts/src/components/Charts/utils/ChartProvider.js +0 -65
- package/dist/scripts/src/components/Charts/utils/abstractions.js +0 -26
- package/dist/scripts/src/components/Checkbox/Checkbox.js +0 -81
- package/dist/scripts/src/components/Checkbox/Checkbox.spec.js +0 -900
- package/dist/scripts/src/components/CodeBlock/CodeBlock.js +0 -42
- package/dist/scripts/src/components/CodeBlock/CodeBlock.spec.js +0 -196
- package/dist/scripts/src/components/CodeBlock/CodeBlockNative.js +0 -127
- package/dist/scripts/src/components/CodeBlock/highlight-code.js +0 -273
- package/dist/scripts/src/components/ColorPicker/ColorPicker.js +0 -54
- package/dist/scripts/src/components/ColorPicker/ColorPicker.spec.js +0 -355
- package/dist/scripts/src/components/ColorPicker/ColorPickerNative.js +0 -86
- package/dist/scripts/src/components/Column/Column.js +0 -89
- package/dist/scripts/src/components/Column/ColumnNative.js +0 -49
- package/dist/scripts/src/components/Column/TableContext.js +0 -12
- package/dist/scripts/src/components/Column/doc-resources/list-component-data.js +0 -53
- package/dist/scripts/src/components/ComponentProvider.js +0 -811
- package/dist/scripts/src/components/ComponentRegistryContext.js +0 -44
- package/dist/scripts/src/components/ContentSeparator/ContentSeparator.js +0 -51
- package/dist/scripts/src/components/ContentSeparator/ContentSeparator.spec.js +0 -531
- package/dist/scripts/src/components/ContentSeparator/ContentSeparatorNative.js +0 -31
- package/dist/scripts/src/components/DataSource/DataSource.js +0 -124
- package/dist/scripts/src/components/DateInput/DateInput.js +0 -197
- package/dist/scripts/src/components/DateInput/DateInput.spec.js +0 -1023
- package/dist/scripts/src/components/DateInput/DateInputNative.js +0 -734
- package/dist/scripts/src/components/DatePicker/DatePicker.js +0 -146
- package/dist/scripts/src/components/DatePicker/DatePicker.spec.js +0 -394
- package/dist/scripts/src/components/DatePicker/DatePickerNative.js +0 -326
- package/dist/scripts/src/components/DropdownMenu/DropdownMenu.js +0 -196
- package/dist/scripts/src/components/DropdownMenu/DropdownMenu.spec.js +0 -331
- package/dist/scripts/src/components/DropdownMenu/DropdownMenuNative.js +0 -146
- package/dist/scripts/src/components/EmojiSelector/EmojiSelector.js +0 -26
- package/dist/scripts/src/components/EmojiSelector/EmojiSelector.spec.js +0 -29
- package/dist/scripts/src/components/EmojiSelector/EmojiSelectorNative.js +0 -71
- package/dist/scripts/src/components/ExpandableItem/ExpandableItem.js +0 -101
- package/dist/scripts/src/components/ExpandableItem/ExpandableItem.spec.js +0 -435
- package/dist/scripts/src/components/ExpandableItem/ExpandableItemNative.js +0 -109
- package/dist/scripts/src/components/FileInput/FileInput.js +0 -80
- package/dist/scripts/src/components/FileInput/FileInput.spec.js +0 -285
- package/dist/scripts/src/components/FileInput/FileInputNative.js +0 -161
- package/dist/scripts/src/components/FileUploadDropZone/FileUploadDropZone.js +0 -58
- package/dist/scripts/src/components/FileUploadDropZone/FileUploadDropZone.spec.js +0 -296
- package/dist/scripts/src/components/FileUploadDropZone/FileUploadDropZoneNative.js +0 -134
- package/dist/scripts/src/components/FlowLayout/FlowLayout.js +0 -65
- package/dist/scripts/src/components/FlowLayout/FlowLayout.spec.js +0 -518
- package/dist/scripts/src/components/FlowLayout/FlowLayoutNative.js +0 -153
- package/dist/scripts/src/components/Footer/Footer.js +0 -45
- package/dist/scripts/src/components/Footer/Footer.spec.js +0 -991
- package/dist/scripts/src/components/Footer/FooterNative.js +0 -35
- package/dist/scripts/src/components/Form/Form.js +0 -161
- package/dist/scripts/src/components/Form/Form.spec.js +0 -1719
- package/dist/scripts/src/components/Form/FormContext.js +0 -124
- package/dist/scripts/src/components/Form/FormNative.js +0 -463
- package/dist/scripts/src/components/Form/formActions.js +0 -115
- package/dist/scripts/src/components/FormItem/FormItem.js +0 -231
- package/dist/scripts/src/components/FormItem/FormItem.spec.js +0 -1022
- package/dist/scripts/src/components/FormItem/FormItemNative.js +0 -255
- package/dist/scripts/src/components/FormItem/HelperText.js +0 -27
- package/dist/scripts/src/components/FormItem/ItemWithLabel.js +0 -52
- package/dist/scripts/src/components/FormItem/Validations.js +0 -389
- package/dist/scripts/src/components/FormSection/FormSection.js +0 -56
- package/dist/scripts/src/components/Fragment/Fragment.js +0 -24
- package/dist/scripts/src/components/Fragment/Fragment.spec.js +0 -50
- package/dist/scripts/src/components/Heading/H1.spec.js +0 -66
- package/dist/scripts/src/components/Heading/H2.spec.js +0 -66
- package/dist/scripts/src/components/Heading/H3.spec.js +0 -66
- package/dist/scripts/src/components/Heading/H4.spec.js +0 -66
- package/dist/scripts/src/components/Heading/H5.spec.js +0 -66
- package/dist/scripts/src/components/Heading/H6.spec.js +0 -66
- package/dist/scripts/src/components/Heading/Heading.js +0 -396
- package/dist/scripts/src/components/Heading/Heading.spec.js +0 -966
- package/dist/scripts/src/components/Heading/HeadingNative.js +0 -98
- package/dist/scripts/src/components/Heading/abstractions.js +0 -4
- package/dist/scripts/src/components/HoverCard/HoverCard.js +0 -18
- package/dist/scripts/src/components/HoverCard/HovercardNative.js +0 -44
- package/dist/scripts/src/components/HtmlTags/HtmlTags.js +0 -1441
- package/dist/scripts/src/components/HtmlTags/HtmlTags.spec.js +0 -69
- package/dist/scripts/src/components/IFrame/IFrame.js +0 -77
- package/dist/scripts/src/components/IFrame/IFrame.spec.js +0 -527
- package/dist/scripts/src/components/IFrame/IFrameNative.js +0 -46
- package/dist/scripts/src/components/Icon/AdmonitionDanger.js +0 -10
- package/dist/scripts/src/components/Icon/AdmonitionInfo.js +0 -10
- package/dist/scripts/src/components/Icon/AdmonitionNote.js +0 -10
- package/dist/scripts/src/components/Icon/AdmonitionTip.js +0 -10
- package/dist/scripts/src/components/Icon/AdmonitionWarning.js +0 -10
- package/dist/scripts/src/components/Icon/ApiIcon.js +0 -10
- package/dist/scripts/src/components/Icon/ArrowDropDown.js +0 -11
- package/dist/scripts/src/components/Icon/ArrowDropUp.js +0 -11
- package/dist/scripts/src/components/Icon/ArrowLeft.js +0 -11
- package/dist/scripts/src/components/Icon/ArrowRight.js +0 -11
- package/dist/scripts/src/components/Icon/Attach.js +0 -10
- package/dist/scripts/src/components/Icon/Binding.js +0 -11
- package/dist/scripts/src/components/Icon/BoardIcon.js +0 -7
- package/dist/scripts/src/components/Icon/BoxIcon.js +0 -10
- package/dist/scripts/src/components/Icon/CheckIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ChevronDownIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ChevronLeft.js +0 -7
- package/dist/scripts/src/components/Icon/ChevronRight.js +0 -7
- package/dist/scripts/src/components/Icon/ChevronUpIcon.js +0 -7
- package/dist/scripts/src/components/Icon/CodeFileIcon.js +0 -10
- package/dist/scripts/src/components/Icon/CodeSandbox.js +0 -10
- package/dist/scripts/src/components/Icon/CompactListIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ContentCopyIcon.js +0 -7
- package/dist/scripts/src/components/Icon/DarkToLightIcon.js +0 -10
- package/dist/scripts/src/components/Icon/DatabaseIcon.js +0 -11
- package/dist/scripts/src/components/Icon/DocFileIcon.js +0 -10
- package/dist/scripts/src/components/Icon/DocIcon.js +0 -10
- package/dist/scripts/src/components/Icon/DotMenuHorizontalIcon.js +0 -7
- package/dist/scripts/src/components/Icon/DotMenuIcon.js +0 -7
- package/dist/scripts/src/components/Icon/EmailIcon.js +0 -7
- package/dist/scripts/src/components/Icon/EmptyFolderIcon.js +0 -10
- package/dist/scripts/src/components/Icon/ErrorIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ExpressionIcon.js +0 -10
- package/dist/scripts/src/components/Icon/FillPlusCricleIcon.js +0 -7
- package/dist/scripts/src/components/Icon/FilterIcon.js +0 -10
- package/dist/scripts/src/components/Icon/FolderIcon.js +0 -10
- package/dist/scripts/src/components/Icon/GlobeIcon.js +0 -7
- package/dist/scripts/src/components/Icon/HomeIcon.js +0 -7
- package/dist/scripts/src/components/Icon/HyperLinkIcon.js +0 -7
- package/dist/scripts/src/components/Icon/Icon.js +0 -42
- package/dist/scripts/src/components/Icon/Icon.spec.js +0 -527
- package/dist/scripts/src/components/Icon/IconNative.js +0 -127
- package/dist/scripts/src/components/Icon/ImageFileIcon.js +0 -10
- package/dist/scripts/src/components/Icon/Inspect.js +0 -10
- package/dist/scripts/src/components/Icon/LightToDark.js +0 -10
- package/dist/scripts/src/components/Icon/LinkIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ListIcon.js +0 -7
- package/dist/scripts/src/components/Icon/LooseListIcon.js +0 -7
- package/dist/scripts/src/components/Icon/MoonIcon.js +0 -10
- package/dist/scripts/src/components/Icon/MoreOptionsIcon.js +0 -7
- package/dist/scripts/src/components/Icon/NoSortIcon.js +0 -8
- package/dist/scripts/src/components/Icon/PDFIcon.js +0 -10
- package/dist/scripts/src/components/Icon/PenIcon.js +0 -7
- package/dist/scripts/src/components/Icon/PhoneIcon.js +0 -7
- package/dist/scripts/src/components/Icon/PhotoIcon.js +0 -10
- package/dist/scripts/src/components/Icon/PlusIcon.js +0 -7
- package/dist/scripts/src/components/Icon/SearchIcon.js +0 -7
- package/dist/scripts/src/components/Icon/ShareIcon.js +0 -10
- package/dist/scripts/src/components/Icon/SortAscendingIcon.js +0 -8
- package/dist/scripts/src/components/Icon/SortDescendingIcon.js +0 -8
- package/dist/scripts/src/components/Icon/StarsIcon.js +0 -10
- package/dist/scripts/src/components/Icon/SunIcon.js +0 -10
- package/dist/scripts/src/components/Icon/TableDeleteColumnIcon.js +0 -7
- package/dist/scripts/src/components/Icon/TableDeleteRowIcon.js +0 -7
- package/dist/scripts/src/components/Icon/TableInsertColumnIcon.js +0 -7
- package/dist/scripts/src/components/Icon/TableInsertRowIcon.js +0 -7
- package/dist/scripts/src/components/Icon/TrashIcon.js +0 -7
- package/dist/scripts/src/components/Icon/TrendingDownIcon.js +0 -10
- package/dist/scripts/src/components/Icon/TrendingLevelIcon.js +0 -10
- package/dist/scripts/src/components/Icon/TrendingUpIcon.js +0 -10
- package/dist/scripts/src/components/Icon/TxtIcon.js +0 -10
- package/dist/scripts/src/components/Icon/UnknownFileIcon.js +0 -10
- package/dist/scripts/src/components/Icon/UnlinkIcon.js +0 -10
- package/dist/scripts/src/components/Icon/UserIcon.js +0 -7
- package/dist/scripts/src/components/Icon/WarningIcon.js +0 -7
- package/dist/scripts/src/components/Icon/XlsIcon.js +0 -10
- package/dist/scripts/src/components/IconProvider.js +0 -300
- package/dist/scripts/src/components/IconRegistryContext.js +0 -318
- package/dist/scripts/src/components/Image/Image.js +0 -52
- package/dist/scripts/src/components/Image/Image.spec.js +0 -198
- package/dist/scripts/src/components/Image/ImageNative.js +0 -73
- package/dist/scripts/src/components/Input/InputAdornment.js +0 -28
- package/dist/scripts/src/components/Input/InputDivider.js +0 -35
- package/dist/scripts/src/components/Input/InputLabel.js +0 -25
- package/dist/scripts/src/components/Input/PartialInput.js +0 -155
- package/dist/scripts/src/components/Input/index.js +0 -5
- package/dist/scripts/src/components/InspectButton/InspectButton.js +0 -35
- package/dist/scripts/src/components/Items/Items.js +0 -39
- package/dist/scripts/src/components/Items/Items.spec.js +0 -397
- package/dist/scripts/src/components/Items/ItemsNative.js +0 -33
- package/dist/scripts/src/components/Link/Link.js +0 -82
- package/dist/scripts/src/components/Link/Link.spec.js +0 -894
- package/dist/scripts/src/components/Link/LinkNative.js +0 -48
- package/dist/scripts/src/components/List/List.js +0 -130
- package/dist/scripts/src/components/List/List.spec.js +0 -927
- package/dist/scripts/src/components/List/ListNative.js +0 -433
- package/dist/scripts/src/components/List/doc-resources/list-component-data.js +0 -53
- package/dist/scripts/src/components/Logo/Logo.js +0 -30
- package/dist/scripts/src/components/Logo/LogoNative.js +0 -32
- package/dist/scripts/src/components/Markdown/CodeText.js +0 -38
- package/dist/scripts/src/components/Markdown/Markdown.js +0 -143
- package/dist/scripts/src/components/Markdown/Markdown.spec.js +0 -188
- package/dist/scripts/src/components/Markdown/MarkdownNative.js +0 -476
- package/dist/scripts/src/components/Markdown/parse-binding-expr.js +0 -60
- package/dist/scripts/src/components/Markdown/utils.js +0 -389
- package/dist/scripts/src/components/ModalDialog/ConfirmationModalContextProvider.js +0 -111
- package/dist/scripts/src/components/ModalDialog/Dialog.js +0 -20
- package/dist/scripts/src/components/ModalDialog/ModalDialog.js +0 -83
- package/dist/scripts/src/components/ModalDialog/ModalDialog.spec.js +0 -181
- package/dist/scripts/src/components/ModalDialog/ModalDialogNative.js +0 -217
- package/dist/scripts/src/components/ModalDialog/ModalVisibilityContext.js +0 -60
- package/dist/scripts/src/components/NavGroup/NavGroup.js +0 -70
- package/dist/scripts/src/components/NavGroup/NavGroup.spec.js +0 -304
- package/dist/scripts/src/components/NavGroup/NavGroupContext.js +0 -13
- package/dist/scripts/src/components/NavGroup/NavGroupNative.js +0 -133
- package/dist/scripts/src/components/NavLink/NavLink.js +0 -86
- package/dist/scripts/src/components/NavLink/NavLink.spec.js +0 -864
- package/dist/scripts/src/components/NavLink/NavLinkNative.js +0 -73
- package/dist/scripts/src/components/NavPanel/NavPanel.js +0 -53
- package/dist/scripts/src/components/NavPanel/NavPanel.spec.js +0 -864
- package/dist/scripts/src/components/NavPanel/NavPanelNative.js +0 -222
- package/dist/scripts/src/components/NestedApp/AppWithCodeView.js +0 -91
- package/dist/scripts/src/components/NestedApp/AppWithCodeViewNative.js +0 -84
- package/dist/scripts/src/components/NestedApp/NestedApp.js +0 -86
- package/dist/scripts/src/components/NestedApp/NestedAppNative.js +0 -231
- package/dist/scripts/src/components/NestedApp/Tooltip.js +0 -46
- package/dist/scripts/src/components/NestedApp/defaultProps.js +0 -12
- package/dist/scripts/src/components/NestedApp/utils.js +0 -67
- package/dist/scripts/src/components/NoResult/NoResult.js +0 -46
- package/dist/scripts/src/components/NoResult/NoResult.spec.js +0 -863
- package/dist/scripts/src/components/NoResult/NoResultNative.js +0 -31
- package/dist/scripts/src/components/NumberBox/NumberBox.js +0 -123
- package/dist/scripts/src/components/NumberBox/NumberBox.spec.js +0 -979
- package/dist/scripts/src/components/NumberBox/NumberBoxNative.js +0 -513
- package/dist/scripts/src/components/NumberBox/numberbox-abstractions.js +0 -109
- package/dist/scripts/src/components/Option/Option.js +0 -44
- package/dist/scripts/src/components/Option/Option.spec.js +0 -474
- package/dist/scripts/src/components/Option/OptionNative.js +0 -29
- package/dist/scripts/src/components/Option/OptionTypeProvider.js +0 -16
- package/dist/scripts/src/components/PageMetaTitle/PageMetaTilteNative.js +0 -13
- package/dist/scripts/src/components/PageMetaTitle/PageMetaTitle.js +0 -22
- package/dist/scripts/src/components/PageMetaTitle/PageMetaTitle.spec.js +0 -80
- package/dist/scripts/src/components/Pages/Pages.js +0 -54
- package/dist/scripts/src/components/Pages/PagesNative.js +0 -57
- package/dist/scripts/src/components/Pagination/Pagination.js +0 -107
- package/dist/scripts/src/components/Pagination/Pagination.spec.js +0 -1008
- package/dist/scripts/src/components/Pagination/PaginationNative.js +0 -157
- package/dist/scripts/src/components/PositionedContainer/PositionedContainer.js +0 -24
- package/dist/scripts/src/components/PositionedContainer/PositionedContainerNative.js +0 -14
- package/dist/scripts/src/components/ProfileMenu/ProfileMenu.js +0 -20
- package/dist/scripts/src/components/ProgressBar/ProgressBar.js +0 -38
- package/dist/scripts/src/components/ProgressBar/ProgressBar.spec.js +0 -166
- package/dist/scripts/src/components/ProgressBar/ProgressBarNative.js +0 -28
- package/dist/scripts/src/components/Queue/Queue.js +0 -85
- package/dist/scripts/src/components/Queue/Queue.spec.js +0 -624
- package/dist/scripts/src/components/Queue/QueueNative.js +0 -342
- package/dist/scripts/src/components/Queue/queueActions.js +0 -87
- package/dist/scripts/src/components/RadioGroup/RadioGroup.js +0 -61
- package/dist/scripts/src/components/RadioGroup/RadioGroup.spec.js +0 -490
- package/dist/scripts/src/components/RadioGroup/RadioGroupNative.js +0 -158
- package/dist/scripts/src/components/RadioGroup/RadioItem.js +0 -28
- package/dist/scripts/src/components/RadioGroup/RadioItemNative.js +0 -62
- package/dist/scripts/src/components/RealTimeAdapter/RealTimeAdapter.js +0 -24
- package/dist/scripts/src/components/RealTimeAdapter/RealTimeAdapterNative.js +0 -135
- package/dist/scripts/src/components/Redirect/Redirect.js +0 -31
- package/dist/scripts/src/components/Redirect/Redirect.spec.js +0 -527
- package/dist/scripts/src/components/ResponsiveBar/ResponsiveBar.js +0 -60
- package/dist/scripts/src/components/ResponsiveBar/ResponsiveBar.spec.js +0 -76
- package/dist/scripts/src/components/ResponsiveBar/ResponsiveBarNative.js +0 -313
- package/dist/scripts/src/components/Select/HiddenOption.js +0 -20
- package/dist/scripts/src/components/Select/OptionContext.js +0 -12
- package/dist/scripts/src/components/Select/Select.js +0 -131
- package/dist/scripts/src/components/Select/Select.spec.js +0 -763
- package/dist/scripts/src/components/Select/SelectContext.js +0 -16
- package/dist/scripts/src/components/Select/SelectNative.js +0 -440
- package/dist/scripts/src/components/SelectionStore/SelectionStore.js +0 -25
- package/dist/scripts/src/components/SelectionStore/SelectionStoreNative.js +0 -103
- package/dist/scripts/src/components/Slider/Slider.js +0 -115
- package/dist/scripts/src/components/Slider/Slider.spec.js +0 -677
- package/dist/scripts/src/components/Slider/SliderNative.js +0 -237
- package/dist/scripts/src/components/Slot/Slot.js +0 -17
- package/dist/scripts/src/components/Slot/Slot.spec.js +0 -368
- package/dist/scripts/src/components/SlotItem.js +0 -32
- package/dist/scripts/src/components/SpaceFiller/SpaceFiller.js +0 -20
- package/dist/scripts/src/components/SpaceFiller/SpaceFiller.spec.js +0 -184
- package/dist/scripts/src/components/SpaceFiller/SpaceFillerNative.js +0 -10
- package/dist/scripts/src/components/Spinner/Spinner.js +0 -39
- package/dist/scripts/src/components/Spinner/Spinner.spec.js +0 -161
- package/dist/scripts/src/components/Spinner/SpinnerNative.js +0 -48
- package/dist/scripts/src/components/Splitter/HSplitter.spec.js +0 -104
- package/dist/scripts/src/components/Splitter/Splitter.js +0 -163
- package/dist/scripts/src/components/Splitter/Splitter.spec.js +0 -856
- package/dist/scripts/src/components/Splitter/SplitterNative.js +0 -205
- package/dist/scripts/src/components/Splitter/VSplitter.spec.js +0 -104
- package/dist/scripts/src/components/Splitter/utils.js +0 -22
- package/dist/scripts/src/components/Stack/CHStack.spec.js +0 -86
- package/dist/scripts/src/components/Stack/CVStack.spec.js +0 -86
- package/dist/scripts/src/components/Stack/HStack.spec.js +0 -67
- package/dist/scripts/src/components/Stack/Stack.js +0 -156
- package/dist/scripts/src/components/Stack/Stack.spec.js +0 -654
- package/dist/scripts/src/components/Stack/StackNative.js +0 -45
- package/dist/scripts/src/components/Stack/VStack.spec.js +0 -67
- package/dist/scripts/src/components/StickyBox/StickyBox.js +0 -34
- package/dist/scripts/src/components/StickyBox/StickyBoxNative.js +0 -42
- package/dist/scripts/src/components/Switch/Switch.js +0 -80
- package/dist/scripts/src/components/Switch/Switch.spec.js +0 -834
- package/dist/scripts/src/components/Table/Table.js +0 -268
- package/dist/scripts/src/components/Table/Table.spec.js +0 -827
- package/dist/scripts/src/components/Table/TableNative.js +0 -670
- package/dist/scripts/src/components/Table/doc-resources/list-component-data.js +0 -53
- package/dist/scripts/src/components/Table/useRowSelection.js +0 -454
- package/dist/scripts/src/components/TableOfContents/TableOfContents.js +0 -76
- package/dist/scripts/src/components/TableOfContents/TableOfContents.spec.js +0 -838
- package/dist/scripts/src/components/TableOfContents/TableOfContentsNative.js +0 -81
- package/dist/scripts/src/components/Tabs/TabContext.js +0 -58
- package/dist/scripts/src/components/Tabs/TabItem.js +0 -44
- package/dist/scripts/src/components/Tabs/TabItemNative.js +0 -53
- package/dist/scripts/src/components/Tabs/Tabs.js +0 -95
- package/dist/scripts/src/components/Tabs/Tabs.spec.js +0 -1237
- package/dist/scripts/src/components/Tabs/TabsNative.js +0 -137
- package/dist/scripts/src/components/Text/Text.js +0 -181
- package/dist/scripts/src/components/Text/Text.spec.js +0 -1676
- package/dist/scripts/src/components/Text/TextNative.js +0 -244
- package/dist/scripts/src/components/TextArea/TextArea.js +0 -103
- package/dist/scripts/src/components/TextArea/TextArea.spec.js +0 -886
- package/dist/scripts/src/components/TextArea/TextAreaNative.js +0 -196
- package/dist/scripts/src/components/TextArea/TextAreaResizable.js +0 -73
- package/dist/scripts/src/components/TextArea/useComposedRef.js +0 -60
- package/dist/scripts/src/components/TextBox/TextBox.js +0 -133
- package/dist/scripts/src/components/TextBox/TextBox.spec.js +0 -758
- package/dist/scripts/src/components/TextBox/TextBoxNative.js +0 -142
- package/dist/scripts/src/components/Theme/NotificationToast.js +0 -64
- package/dist/scripts/src/components/Theme/Theme.js +0 -47
- package/dist/scripts/src/components/Theme/Theme.spec.js +0 -390
- package/dist/scripts/src/components/Theme/ThemeNative.js +0 -162
- package/dist/scripts/src/components/TimeInput/TimeInput.js +0 -149
- package/dist/scripts/src/components/TimeInput/TimeInput.spec.js +0 -1236
- package/dist/scripts/src/components/TimeInput/TimeInputNative.js +0 -650
- package/dist/scripts/src/components/TimeInput/utils.js +0 -197
- package/dist/scripts/src/components/Timer/Timer.js +0 -62
- package/dist/scripts/src/components/Timer/Timer.spec.js +0 -328
- package/dist/scripts/src/components/Timer/TimerNative.js +0 -178
- package/dist/scripts/src/components/Toggle/Toggle.js +0 -172
- package/dist/scripts/src/components/ToneChangerButton/ToneChangerButton.js +0 -63
- package/dist/scripts/src/components/ToneChangerButton/ToneChangerButton.spec.js +0 -414
- package/dist/scripts/src/components/ToneSwitch/ToneSwitch.js +0 -51
- package/dist/scripts/src/components/ToneSwitch/ToneSwitch.spec.js +0 -89
- package/dist/scripts/src/components/ToneSwitch/ToneSwitchNative.js +0 -42
- package/dist/scripts/src/components/Tooltip/Tooltip.js +0 -118
- package/dist/scripts/src/components/Tooltip/Tooltip.spec.js +0 -418
- package/dist/scripts/src/components/Tooltip/TooltipNative.js +0 -160
- package/dist/scripts/src/components/Tree/Tree-dynamic.spec.js +0 -2894
- package/dist/scripts/src/components/Tree/Tree-icons.spec.js +0 -206
- package/dist/scripts/src/components/Tree/Tree.spec.js +0 -2839
- package/dist/scripts/src/components/Tree/TreeComponent.js +0 -324
- package/dist/scripts/src/components/Tree/TreeNative.js +0 -1129
- package/dist/scripts/src/components/Tree/testData.js +0 -296
- package/dist/scripts/src/components/TreeDisplay/TreeDisplay.js +0 -49
- package/dist/scripts/src/components/TreeDisplay/TreeDisplayNative.js +0 -104
- package/dist/scripts/src/components/ValidationSummary/ValidationSummary.js +0 -64
- package/dist/scripts/src/components/VisuallyHidden.js +0 -21
- package/dist/scripts/src/components/abstractions.js +0 -341
- package/dist/scripts/src/components/chart-color-schemes.js +0 -43
- package/dist/scripts/src/components/collectedComponentMetadata.js +0 -316
- package/dist/scripts/src/components/component-utils.js +0 -29
- package/dist/scripts/src/components/container-helpers.js +0 -26
- package/dist/scripts/src/components/metadata-helpers.js +0 -269
- package/dist/scripts/src/components-core/ApiBoundComponent.js +0 -227
- package/dist/scripts/src/components-core/AppContext.js +0 -16
- package/dist/scripts/src/components-core/ComponentDecorator.js +0 -74
- package/dist/scripts/src/components-core/ComponentViewer.js +0 -69
- package/dist/scripts/src/components-core/CompoundComponent.js +0 -145
- package/dist/scripts/src/components-core/DebugViewProvider.js +0 -43
- package/dist/scripts/src/components-core/EngineError.js +0 -91
- package/dist/scripts/src/components-core/InspectorContext.js +0 -248
- package/dist/scripts/src/components-core/LoaderComponent.js +0 -109
- package/dist/scripts/src/components-core/RestApiProxy.js +0 -468
- package/dist/scripts/src/components-core/StandaloneApp.js +0 -821
- package/dist/scripts/src/components-core/StandaloneExtensionManager.js +0 -44
- package/dist/scripts/src/components-core/TableOfContentsContext.js +0 -168
- package/dist/scripts/src/components-core/abstractions/ComponentRenderer.js +0 -2
- package/dist/scripts/src/components-core/abstractions/LoaderRenderer.js +0 -2
- package/dist/scripts/src/components-core/abstractions/standalone.js +0 -2
- package/dist/scripts/src/components-core/abstractions/treeAbstractions.js +0 -2
- package/dist/scripts/src/components-core/action/APICall.js +0 -284
- package/dist/scripts/src/components-core/action/FileDownloadAction.js +0 -80
- package/dist/scripts/src/components-core/action/FileUploadAction.js +0 -88
- package/dist/scripts/src/components-core/action/NavigateAction.js +0 -20
- package/dist/scripts/src/components-core/action/TimedAction.js +0 -21
- package/dist/scripts/src/components-core/action/actions.js +0 -15
- package/dist/scripts/src/components-core/appContext/date-functions.js +0 -24
- package/dist/scripts/src/components-core/appContext/math-function.js +0 -27
- package/dist/scripts/src/components-core/appContext/misc-utils.js +0 -14
- package/dist/scripts/src/components-core/behaviors/Behavior.js +0 -2
- package/dist/scripts/src/components-core/behaviors/CoreBehaviors.js +0 -201
- package/dist/scripts/src/components-core/component-hooks.js +0 -25
- package/dist/scripts/src/components-core/constants.js +0 -18
- package/dist/scripts/src/components-core/descriptorHelper.js +0 -96
- package/dist/scripts/src/components-core/devtools/InspectorDialog.js +0 -135
- package/dist/scripts/src/components-core/devtools/InspectorDialogVisibilityContext.js +0 -8
- package/dist/scripts/src/components-core/event-handlers.js +0 -46
- package/dist/scripts/src/components-core/interception/ApiInterceptor.js +0 -247
- package/dist/scripts/src/components-core/interception/ApiInterceptorProvider.js +0 -167
- package/dist/scripts/src/components-core/interception/Backend.js +0 -141
- package/dist/scripts/src/components-core/interception/Errors.js +0 -129
- package/dist/scripts/src/components-core/interception/InMemoryDb.js +0 -41
- package/dist/scripts/src/components-core/interception/IndexedDb.js +0 -205
- package/dist/scripts/src/components-core/interception/ReadonlyCollection.js +0 -145
- package/dist/scripts/src/components-core/interception/abstractions.js +0 -2
- package/dist/scripts/src/components-core/interception/apiInterceptorWorker.js +0 -44
- package/dist/scripts/src/components-core/interception/initMock.js +0 -20
- package/dist/scripts/src/components-core/interception/useApiInterceptorContext.js +0 -9
- package/dist/scripts/src/components-core/loader/ApiLoader.js +0 -54
- package/dist/scripts/src/components-core/loader/DataLoader.js +0 -330
- package/dist/scripts/src/components-core/loader/ExternalDataLoader.js +0 -60
- package/dist/scripts/src/components-core/loader/Loader.js +0 -159
- package/dist/scripts/src/components-core/loader/MockLoaderRenderer.js +0 -43
- package/dist/scripts/src/components-core/loader/PageableLoader.js +0 -272
- package/dist/scripts/src/components-core/markup-check.js +0 -279
- package/dist/scripts/src/components-core/parts.js +0 -11
- package/dist/scripts/src/components-core/renderers.js +0 -76
- package/dist/scripts/src/components-core/rendering/AppContent.js +0 -400
- package/dist/scripts/src/components-core/rendering/AppRoot.js +0 -87
- package/dist/scripts/src/components-core/rendering/AppWrapper.js +0 -49
- package/dist/scripts/src/components-core/rendering/ComponentAdapter.js +0 -380
- package/dist/scripts/src/components-core/rendering/ComponentWrapper.js +0 -166
- package/dist/scripts/src/components-core/rendering/Container.js +0 -621
- package/dist/scripts/src/components-core/rendering/ContainerWrapper.js +0 -94
- package/dist/scripts/src/components-core/rendering/ErrorBoundary.js +0 -65
- package/dist/scripts/src/components-core/rendering/InvalidComponent.js +0 -17
- package/dist/scripts/src/components-core/rendering/StandaloneComponent.js +0 -39
- package/dist/scripts/src/components-core/rendering/StateContainer.js +0 -350
- package/dist/scripts/src/components-core/rendering/UnknownComponent.js +0 -15
- package/dist/scripts/src/components-core/rendering/buildProxy.js +0 -58
- package/dist/scripts/src/components-core/rendering/collectFnVarDeps.js +0 -49
- package/dist/scripts/src/components-core/rendering/containers.js +0 -19
- package/dist/scripts/src/components-core/rendering/nodeUtils.js +0 -6
- package/dist/scripts/src/components-core/rendering/reducer.js +0 -160
- package/dist/scripts/src/components-core/rendering/renderChild.js +0 -82
- package/dist/scripts/src/components-core/rendering/valueExtractor.js +0 -216
- package/dist/scripts/src/components-core/reportEngineError.js +0 -62
- package/dist/scripts/src/components-core/script-runner/AttributeValueParser.js +0 -117
- package/dist/scripts/src/components-core/script-runner/BindingTreeEvaluationContext.js +0 -33
- package/dist/scripts/src/components-core/script-runner/ParameterParser.js +0 -117
- package/dist/scripts/src/components-core/script-runner/ScriptingSourceTree.js +0 -45
- package/dist/scripts/src/components-core/script-runner/asyncProxy.js +0 -96
- package/dist/scripts/src/components-core/script-runner/bannedFunctions.js +0 -34
- package/dist/scripts/src/components-core/script-runner/eval-tree-async.js +0 -613
- package/dist/scripts/src/components-core/script-runner/eval-tree-common.js +0 -439
- package/dist/scripts/src/components-core/script-runner/eval-tree-sync.js +0 -522
- package/dist/scripts/src/components-core/script-runner/process-statement-async.js +0 -761
- package/dist/scripts/src/components-core/script-runner/process-statement-common.js +0 -208
- package/dist/scripts/src/components-core/script-runner/process-statement-sync.js +0 -746
- package/dist/scripts/src/components-core/script-runner/simplify-expression.js +0 -386
- package/dist/scripts/src/components-core/script-runner/statement-queue.js +0 -63
- package/dist/scripts/src/components-core/script-runner/visitors.js +0 -369
- package/dist/scripts/src/components-core/theming/StyleContext.js +0 -133
- package/dist/scripts/src/components-core/theming/StyleRegistry.js +0 -171
- package/dist/scripts/src/components-core/theming/ThemeContext.js +0 -53
- package/dist/scripts/src/components-core/theming/ThemeProvider.js +0 -342
- package/dist/scripts/src/components-core/theming/component-layout-resolver.js +0 -153
- package/dist/scripts/src/components-core/theming/extendThemeUtils.js +0 -47
- package/dist/scripts/src/components-core/theming/hvar.js +0 -105
- package/dist/scripts/src/components-core/theming/layout-resolver.js +0 -388
- package/dist/scripts/src/components-core/theming/parse-layout-props.js +0 -136
- package/dist/scripts/src/components-core/theming/themeVars.js +0 -62
- package/dist/scripts/src/components-core/theming/themes/base-utils.js +0 -15
- package/dist/scripts/src/components-core/theming/themes/palette.js +0 -57
- package/dist/scripts/src/components-core/theming/themes/root.js +0 -434
- package/dist/scripts/src/components-core/theming/themes/solid.js +0 -16
- package/dist/scripts/src/components-core/theming/themes/theme-colors.js +0 -561
- package/dist/scripts/src/components-core/theming/themes/xmlui.js +0 -57
- package/dist/scripts/src/components-core/theming/transformThemeVars.js +0 -733
- package/dist/scripts/src/components-core/theming/utils.js +0 -31
- package/dist/scripts/src/components-core/utils/DataLoaderQueryKeyGenerator.js +0 -41
- package/dist/scripts/src/components-core/utils/LruCache.js +0 -184
- package/dist/scripts/src/components-core/utils/actionUtils.js +0 -32
- package/dist/scripts/src/components-core/utils/audio-utils.js +0 -83
- package/dist/scripts/src/components-core/utils/base64-utils.js +0 -124
- package/dist/scripts/src/components-core/utils/compound-utils.js +0 -11
- package/dist/scripts/src/components-core/utils/css-utils.js +0 -179
- package/dist/scripts/src/components-core/utils/date-utils.js +0 -186
- package/dist/scripts/src/components-core/utils/extractParam.js +0 -281
- package/dist/scripts/src/components-core/utils/hooks.js +0 -400
- package/dist/scripts/src/components-core/utils/mergeProps.js +0 -45
- package/dist/scripts/src/components-core/utils/misc.js +0 -539
- package/dist/scripts/src/components-core/utils/request-params.js +0 -70
- package/dist/scripts/src/components-core/utils/statementUtils.js +0 -224
- package/dist/scripts/src/components-core/utils/treeUtils.js +0 -226
- package/dist/scripts/src/components-core/xmlui-parser.js +0 -548
- package/dist/scripts/src/index-standalone.js +0 -61
- package/dist/scripts/src/index.js +0 -158
- package/dist/scripts/src/language-server/server-common.js +0 -152
- package/dist/scripts/src/language-server/server-web-worker.js +0 -47
- package/dist/scripts/src/language-server/server.js +0 -42
- package/dist/scripts/src/language-server/services/common/docs-generation.js +0 -73
- package/dist/scripts/src/language-server/services/common/lsp-utils.js +0 -9
- package/dist/scripts/src/language-server/services/common/metadata-utils.js +0 -157
- package/dist/scripts/src/language-server/services/common/syntax-node-utilities.js +0 -127
- package/dist/scripts/src/language-server/services/completion.js +0 -288
- package/dist/scripts/src/language-server/services/diagnostic.js +0 -19
- package/dist/scripts/src/language-server/services/format.js +0 -569
- package/dist/scripts/src/language-server/services/hover.js +0 -164
- package/dist/scripts/src/language-server/xmlui-metadata-generated.js +0 -16276
- package/dist/scripts/src/logging/LoggerContext.js +0 -22
- package/dist/scripts/src/logging/LoggerInitializer.js +0 -14
- package/dist/scripts/src/logging/LoggerService.js +0 -60
- package/dist/scripts/src/logging/xmlui.js +0 -21
- package/dist/scripts/src/parsers/common/GenericToken.js +0 -2
- package/dist/scripts/src/parsers/common/InputStream.js +0 -59
- package/dist/scripts/src/parsers/common/utils.js +0 -19
- package/dist/scripts/src/parsers/scripting/Lexer.js +0 -1097
- package/dist/scripts/src/parsers/scripting/Parser.js +0 -2638
- package/dist/scripts/src/parsers/scripting/ParserError.js +0 -47
- package/dist/scripts/src/parsers/scripting/ScriptingNodeTypes.js +0 -50
- package/dist/scripts/src/parsers/scripting/TokenTrait.js +0 -108
- package/dist/scripts/src/parsers/scripting/TokenType.js +0 -109
- package/dist/scripts/src/parsers/scripting/code-behind-collect.js +0 -101
- package/dist/scripts/src/parsers/scripting/modules.js +0 -105
- package/dist/scripts/src/parsers/scripting/tree-visitor.js +0 -601
- package/dist/scripts/src/parsers/style-parser/StyleInputStream.js +0 -39
- package/dist/scripts/src/parsers/style-parser/StyleLexer.js +0 -623
- package/dist/scripts/src/parsers/style-parser/StyleParser.js +0 -453
- package/dist/scripts/src/parsers/style-parser/errors.js +0 -37
- package/dist/scripts/src/parsers/style-parser/source-tree.js +0 -2
- package/dist/scripts/src/parsers/style-parser/tokens.js +0 -43
- package/dist/scripts/src/parsers/xmlui-parser/CharacterCodes.js +0 -136
- package/dist/scripts/src/parsers/xmlui-parser/ParserError.js +0 -60
- package/dist/scripts/src/parsers/xmlui-parser/diagnostics.js +0 -172
- package/dist/scripts/src/parsers/xmlui-parser/fileExtensions.js +0 -6
- package/dist/scripts/src/parsers/xmlui-parser/index.js +0 -29
- package/dist/scripts/src/parsers/xmlui-parser/lint.js +0 -165
- package/dist/scripts/src/parsers/xmlui-parser/parser.js +0 -627
- package/dist/scripts/src/parsers/xmlui-parser/scanner.js +0 -415
- package/dist/scripts/src/parsers/xmlui-parser/syntax-kind.js +0 -123
- package/dist/scripts/src/parsers/xmlui-parser/syntax-node.js +0 -83
- package/dist/scripts/src/parsers/xmlui-parser/transform.js +0 -1131
- package/dist/scripts/src/parsers/xmlui-parser/utils.js +0 -83
- package/dist/scripts/src/parsers/xmlui-parser/xmlui-serializer.js +0 -582
- package/dist/scripts/src/parsers/xmlui-parser/xmlui-tree.js +0 -2
- package/dist/scripts/src/syntax/monaco/grammar.monacoLanguage.js +0 -286
- package/dist/scripts/src/syntax/monaco/index.js +0 -14
- package/dist/scripts/src/syntax/monaco/xmlui-dark.js +0 -25
- package/dist/scripts/src/syntax/monaco/xmlui-light.js +0 -25
- package/dist/scripts/src/syntax/monaco/xmluiscript.monacoLanguage.js +0 -310
- package/dist/scripts/src/syntax/textMate/index.js +0 -14
- package/dist/scripts/src/syntax/textMate/xmlui-dark.json +0 -631
- package/dist/scripts/src/syntax/textMate/xmlui-light.json +0 -565
- package/dist/scripts/src/syntax/textMate/xmlui.json +0 -564
- package/dist/scripts/src/syntax/textMate/xmlui.tmLanguage.json +0 -341
- package/dist/scripts/src/testing/ComponentDrivers.js +0 -1380
- package/dist/scripts/src/testing/assertions.js +0 -444
- package/dist/scripts/src/testing/component-test-helpers.js +0 -373
- package/dist/scripts/src/testing/drivers/DateInputDriver.js +0 -19
- package/dist/scripts/src/testing/drivers/ModalDialogDriver.js +0 -10
- package/dist/scripts/src/testing/drivers/NumberBoxDriver.js +0 -44
- package/dist/scripts/src/testing/drivers/TextBoxDriver.js +0 -20
- package/dist/scripts/src/testing/drivers/TimeInputDriver.js +0 -22
- package/dist/scripts/src/testing/drivers/TimerDriver.js +0 -64
- package/dist/scripts/src/testing/drivers/TreeDriver.js +0 -13
- package/dist/scripts/src/testing/drivers/index.js +0 -9
- package/dist/scripts/src/testing/fixtures.js +0 -519
- package/dist/scripts/src/testing/index.js +0 -69
- package/dist/scripts/src/testing/infrastructure/TestBed.js +0 -17
- package/dist/scripts/src/testing/infrastructure/main.js +0 -9
- package/dist/scripts/src/testing/infrastructure/public/mockServiceWorker.js +0 -266
- package/dist/scripts/src/testing/themed-app-test-helpers.js +0 -133
|
@@ -1,1237 +0,0 @@
|
|
|
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 component_test_helpers_1 = require("../../testing/component-test-helpers");
|
|
13
|
-
const fixtures_1 = require("../../testing/fixtures");
|
|
14
|
-
// =============================================================================
|
|
15
|
-
// SMOKE TESTS
|
|
16
|
-
// =============================================================================
|
|
17
|
-
fixtures_1.test.describe("smoke tests", { tag: "@smoke" }, () => {
|
|
18
|
-
(0, fixtures_1.test)("component renders", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
19
|
-
yield initTestBed(`
|
|
20
|
-
<Tabs>
|
|
21
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
22
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
23
|
-
</Tabs>
|
|
24
|
-
`);
|
|
25
|
-
// Check that tabs component is rendered
|
|
26
|
-
yield (0, fixtures_1.expect)(page.getByRole('tablist')).toBeAttached();
|
|
27
|
-
}));
|
|
28
|
-
(0, fixtures_1.test)("renders tab labels correctly", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
29
|
-
yield initTestBed(`
|
|
30
|
-
<Tabs>
|
|
31
|
-
<TabItem label="First Tab">Content 1</TabItem>
|
|
32
|
-
<TabItem label="Second Tab">Content 2</TabItem>
|
|
33
|
-
<TabItem label="Third Tab">Content 3</TabItem>
|
|
34
|
-
</Tabs>
|
|
35
|
-
`);
|
|
36
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "First Tab" })).toBeVisible();
|
|
37
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Second Tab" })).toBeVisible();
|
|
38
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Third Tab" })).toBeVisible();
|
|
39
|
-
}));
|
|
40
|
-
(0, fixtures_1.test)("shows first tab content by default", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
41
|
-
yield initTestBed(`
|
|
42
|
-
<Tabs>
|
|
43
|
-
<TabItem label="Tab 1">First content</TabItem>
|
|
44
|
-
<TabItem label="Tab 2">Second content</TabItem>
|
|
45
|
-
</Tabs>
|
|
46
|
-
`);
|
|
47
|
-
yield (0, fixtures_1.expect)(page.getByText("First content")).toBeVisible();
|
|
48
|
-
yield (0, fixtures_1.expect)(page.getByText("Second content")).not.toBeVisible();
|
|
49
|
-
}));
|
|
50
|
-
});
|
|
51
|
-
// =============================================================================
|
|
52
|
-
// BASIC FUNCTIONALITY TESTS
|
|
53
|
-
// =============================================================================
|
|
54
|
-
fixtures_1.test.describe("basic functionality", () => {
|
|
55
|
-
(0, fixtures_1.test)("switches tabs when clicked", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
56
|
-
yield initTestBed(`
|
|
57
|
-
<Tabs>
|
|
58
|
-
<TabItem label="Tab 1">First content</TabItem>
|
|
59
|
-
<TabItem label="Tab 2">Second content</TabItem>
|
|
60
|
-
<TabItem label="Tab 3">Third content</TabItem>
|
|
61
|
-
</Tabs>
|
|
62
|
-
`);
|
|
63
|
-
// Wait for tabs to be fully rendered
|
|
64
|
-
yield (0, fixtures_1.expect)(page.getByRole('tablist')).toBeAttached();
|
|
65
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toBeVisible();
|
|
66
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeVisible();
|
|
67
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 3" })).toBeVisible();
|
|
68
|
-
// Initially first tab is active
|
|
69
|
-
yield (0, fixtures_1.expect)(page.getByText("First content")).toBeVisible();
|
|
70
|
-
yield (0, fixtures_1.expect)(page.getByText("Second content")).not.toBeVisible();
|
|
71
|
-
yield (0, fixtures_1.expect)(page.getByText("Third content")).not.toBeVisible();
|
|
72
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toHaveAttribute("aria-selected", "true");
|
|
73
|
-
// Click second tab and wait for transition
|
|
74
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
75
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toHaveAttribute("aria-selected", "true");
|
|
76
|
-
yield (0, fixtures_1.expect)(page.getByText("First content")).not.toBeVisible();
|
|
77
|
-
yield (0, fixtures_1.expect)(page.getByText("Second content")).toBeVisible();
|
|
78
|
-
yield (0, fixtures_1.expect)(page.getByText("Third content")).not.toBeVisible();
|
|
79
|
-
// Click third tab and wait for transition
|
|
80
|
-
yield page.getByRole("tab", { name: "Tab 3" }).click();
|
|
81
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 3" })).toHaveAttribute("aria-selected", "true");
|
|
82
|
-
yield (0, fixtures_1.expect)(page.getByText("First content")).not.toBeVisible();
|
|
83
|
-
yield (0, fixtures_1.expect)(page.getByText("Second content")).not.toBeVisible();
|
|
84
|
-
yield (0, fixtures_1.expect)(page.getByText("Third content")).toBeVisible();
|
|
85
|
-
}));
|
|
86
|
-
(0, fixtures_1.test)("activeTab prop sets initial active tab", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
87
|
-
yield initTestBed(`
|
|
88
|
-
<Tabs activeTab="{1}">
|
|
89
|
-
<TabItem label="Tab 1">First content</TabItem>
|
|
90
|
-
<TabItem label="Tab 2">Second content</TabItem>
|
|
91
|
-
<TabItem label="Tab 3">Third content</TabItem>
|
|
92
|
-
</Tabs>
|
|
93
|
-
`);
|
|
94
|
-
yield (0, fixtures_1.expect)(page.getByText("First content")).not.toBeVisible();
|
|
95
|
-
yield (0, fixtures_1.expect)(page.getByText("Second content")).toBeVisible();
|
|
96
|
-
yield (0, fixtures_1.expect)(page.getByText("Third content")).not.toBeVisible();
|
|
97
|
-
}));
|
|
98
|
-
(0, fixtures_1.test)("orientation prop changes tab layout", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
99
|
-
yield initTestBed(`
|
|
100
|
-
<Tabs orientation="vertical" testId="vertical-tabs">
|
|
101
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
102
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
103
|
-
</Tabs>
|
|
104
|
-
`);
|
|
105
|
-
// Check that tabs component has vertical orientation
|
|
106
|
-
const tabsRoot = page.getByTestId("vertical-tabs");
|
|
107
|
-
yield (0, fixtures_1.expect)(tabsRoot).toHaveAttribute("data-orientation", "vertical");
|
|
108
|
-
}));
|
|
109
|
-
fixtures_1.test.describe("tabAlignment property", () => {
|
|
110
|
-
(0, fixtures_1.test)("tabAlignment='start' positions tabs at the start of container (horizontal)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
111
|
-
yield initTestBed(`
|
|
112
|
-
<Tabs tabAlignment="start" testId="tabs">
|
|
113
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
114
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
115
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
116
|
-
</Tabs>
|
|
117
|
-
`);
|
|
118
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
119
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
120
|
-
const { left: containerLeft } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
121
|
-
const { left: tab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
122
|
-
// Tab should be near the start of the container (within a small margin for padding)
|
|
123
|
-
(0, fixtures_1.expect)(tab1Left - containerLeft).toBeLessThan(50);
|
|
124
|
-
}));
|
|
125
|
-
(0, fixtures_1.test)("tabAlignment='end' positions tabs at the end of container (horizontal)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
126
|
-
yield initTestBed(`
|
|
127
|
-
<Tabs tabAlignment="end" testId="tabs">
|
|
128
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
129
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
130
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
131
|
-
</Tabs>
|
|
132
|
-
`);
|
|
133
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
134
|
-
const tab3 = page.getByRole("tab", { name: "Tab 3" });
|
|
135
|
-
const { right: containerRight } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
136
|
-
const { right: tab3Right } = yield (0, component_test_helpers_1.getBounds)(tab3);
|
|
137
|
-
// Last tab should be near the end of the container (within a small margin for padding)
|
|
138
|
-
(0, fixtures_1.expect)(containerRight - tab3Right).toBeLessThan(50);
|
|
139
|
-
}));
|
|
140
|
-
(0, fixtures_1.test)("tabAlignment='center' positions tabs in center of container (horizontal)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
141
|
-
yield initTestBed(`
|
|
142
|
-
<Tabs tabAlignment="center" testId="tabs" style="width: 800px">
|
|
143
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
144
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
145
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
146
|
-
</Tabs>
|
|
147
|
-
`);
|
|
148
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
149
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
150
|
-
const tab3 = page.getByRole("tab", { name: "Tab 3" });
|
|
151
|
-
const { left: containerLeft, right: containerRight, width: containerWidth } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
152
|
-
const { left: tab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
153
|
-
const { right: tab3Right } = yield (0, component_test_helpers_1.getBounds)(tab3);
|
|
154
|
-
const containerCenter = containerLeft + containerWidth / 2;
|
|
155
|
-
const tabsCenter = tab1Left + (tab3Right - tab1Left) / 2;
|
|
156
|
-
// Tabs should be centered (within a reasonable margin)
|
|
157
|
-
(0, fixtures_1.expect)(Math.abs(tabsCenter - containerCenter)).toBeLessThan(50);
|
|
158
|
-
}));
|
|
159
|
-
(0, fixtures_1.test)("tabAlignment='stretch' makes tabs fill container width (horizontal)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
160
|
-
yield initTestBed(`
|
|
161
|
-
<Tabs tabAlignment="stretch" testId="tabs" style="width: 600px">
|
|
162
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
163
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
164
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
165
|
-
</Tabs>
|
|
166
|
-
`);
|
|
167
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
168
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
169
|
-
const tab3 = page.getByRole("tab", { name: "Tab 3" });
|
|
170
|
-
const { left: containerLeft, right: containerRight } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
171
|
-
const { left: tab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
172
|
-
const { right: tab3Right } = yield (0, component_test_helpers_1.getBounds)(tab3);
|
|
173
|
-
// First tab should start near container start
|
|
174
|
-
(0, fixtures_1.expect)(tab1Left - containerLeft).toBeLessThan(50);
|
|
175
|
-
// Last tab should end near container end
|
|
176
|
-
(0, fixtures_1.expect)(containerRight - tab3Right).toBeLessThan(50);
|
|
177
|
-
}));
|
|
178
|
-
(0, fixtures_1.test)("tabAlignment can be dynamically changed", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
179
|
-
const { testStateDriver } = yield initTestBed(`
|
|
180
|
-
<Fragment>
|
|
181
|
-
<Tabs tabAlignment="{testState ?? 'start'}" testId="tabs" style="width: 700px">
|
|
182
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
183
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
184
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
185
|
-
</Tabs>
|
|
186
|
-
<Button testId="changeBtn" onClick="testState = 'end'" />
|
|
187
|
-
</Fragment>
|
|
188
|
-
`);
|
|
189
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
190
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
191
|
-
// Initially with 'start' alignment
|
|
192
|
-
const { left: containerLeft } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
193
|
-
const { left: initialTab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
194
|
-
(0, fixtures_1.expect)(initialTab1Left - containerLeft).toBeLessThan(50);
|
|
195
|
-
// Change to 'end' alignment
|
|
196
|
-
yield page.getByTestId("changeBtn").click();
|
|
197
|
-
yield fixtures_1.expect.poll(testStateDriver.testState).toEqual("end");
|
|
198
|
-
// After changing to 'end', the last tab should be near the end
|
|
199
|
-
const tab3 = page.getByRole("tab", { name: "Tab 3" });
|
|
200
|
-
const { right: containerRight } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
201
|
-
const { right: tab3Right } = yield (0, component_test_helpers_1.getBounds)(tab3);
|
|
202
|
-
(0, fixtures_1.expect)(containerRight - tab3Right).toBeLessThan(50);
|
|
203
|
-
}));
|
|
204
|
-
(0, fixtures_1.test)("tabAlignment works with single tab", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
205
|
-
yield initTestBed(`
|
|
206
|
-
<Tabs tabAlignment="center" testId="tabs" style="width: 600px">
|
|
207
|
-
<TabItem label="Only Tab">Only Content</TabItem>
|
|
208
|
-
</Tabs>
|
|
209
|
-
`);
|
|
210
|
-
const tab = page.getByRole("tab", { name: "Only Tab" });
|
|
211
|
-
yield (0, fixtures_1.expect)(tab).toBeVisible();
|
|
212
|
-
// Verify the tab renders and is functional
|
|
213
|
-
yield (0, fixtures_1.expect)(page.getByText("Only Content")).toBeVisible();
|
|
214
|
-
}));
|
|
215
|
-
(0, fixtures_1.test)("tabAlignment='stretch' distributes multiple tabs evenly", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
216
|
-
yield initTestBed(`
|
|
217
|
-
<Tabs tabAlignment="stretch" testId="tabs" style="width: 600px">
|
|
218
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
219
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
220
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
221
|
-
</Tabs>
|
|
222
|
-
`);
|
|
223
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
224
|
-
const tab2 = page.getByRole("tab", { name: "Tab 2" });
|
|
225
|
-
const tab3 = page.getByRole("tab", { name: "Tab 3" });
|
|
226
|
-
const { width: tab1Width } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
227
|
-
const { width: tab2Width } = yield (0, component_test_helpers_1.getBounds)(tab2);
|
|
228
|
-
const { width: tab3Width } = yield (0, component_test_helpers_1.getBounds)(tab3);
|
|
229
|
-
// All tabs should have similar widths when stretched (within 20px tolerance for text differences)
|
|
230
|
-
(0, fixtures_1.expect)(Math.abs(tab1Width - tab2Width)).toBeLessThan(20);
|
|
231
|
-
(0, fixtures_1.expect)(Math.abs(tab2Width - tab3Width)).toBeLessThan(20);
|
|
232
|
-
}));
|
|
233
|
-
(0, fixtures_1.test)("tabAlignment handles null value gracefully", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
234
|
-
yield initTestBed(`
|
|
235
|
-
<Tabs tabAlignment="{null}" testId="tabs">
|
|
236
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
237
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
238
|
-
</Tabs>
|
|
239
|
-
`);
|
|
240
|
-
// Should fall back to default 'start' alignment
|
|
241
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
242
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
243
|
-
yield (0, fixtures_1.expect)(tab1).toBeVisible();
|
|
244
|
-
const { left: containerLeft } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
245
|
-
const { left: tab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
246
|
-
// Should behave like 'start' alignment
|
|
247
|
-
(0, fixtures_1.expect)(tab1Left - containerLeft).toBeLessThan(50);
|
|
248
|
-
}));
|
|
249
|
-
(0, fixtures_1.test)("tabAlignment handles undefined value gracefully", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
250
|
-
yield initTestBed(`
|
|
251
|
-
<Tabs tabAlignment="{undefined}" testId="tabs">
|
|
252
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
253
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
254
|
-
</Tabs>
|
|
255
|
-
`);
|
|
256
|
-
// Should fall back to default 'start' alignment
|
|
257
|
-
const tabsContainer = page.getByTestId("tabs");
|
|
258
|
-
const tab1 = page.getByRole("tab", { name: "Tab 1" });
|
|
259
|
-
yield (0, fixtures_1.expect)(tab1).toBeVisible();
|
|
260
|
-
const { left: containerLeft } = yield (0, component_test_helpers_1.getBounds)(tabsContainer);
|
|
261
|
-
const { left: tab1Left } = yield (0, component_test_helpers_1.getBounds)(tab1);
|
|
262
|
-
// Should behave like 'start' alignment
|
|
263
|
-
(0, fixtures_1.expect)(tab1Left - containerLeft).toBeLessThan(50);
|
|
264
|
-
}));
|
|
265
|
-
(0, fixtures_1.test)("tabAlignment maintains functionality when tabs are clicked", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
266
|
-
yield initTestBed(`
|
|
267
|
-
<Tabs tabAlignment="center" testId="tabs" style="width: 700px">
|
|
268
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
269
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
270
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
271
|
-
</Tabs>
|
|
272
|
-
`);
|
|
273
|
-
// Verify all tabs are visible
|
|
274
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toBeVisible();
|
|
275
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeVisible();
|
|
276
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 3" })).toBeVisible();
|
|
277
|
-
// Click different tabs and verify content changes
|
|
278
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
279
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
280
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
281
|
-
yield page.getByRole("tab", { name: "Tab 3" }).click();
|
|
282
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).toBeVisible();
|
|
283
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
284
|
-
yield page.getByRole("tab", { name: "Tab 1" }).click();
|
|
285
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
286
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
287
|
-
}));
|
|
288
|
-
});
|
|
289
|
-
fixtures_1.test.describe("accordionView property", () => {
|
|
290
|
-
(0, fixtures_1.test)("accordionView renders all tab headers when true", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
291
|
-
yield initTestBed(`
|
|
292
|
-
<Tabs accordionView="true" testId="tabs">
|
|
293
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
294
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
295
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
296
|
-
</Tabs>
|
|
297
|
-
`);
|
|
298
|
-
// All tab headers should be visible
|
|
299
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toBeVisible();
|
|
300
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeVisible();
|
|
301
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 3" })).toBeVisible();
|
|
302
|
-
}));
|
|
303
|
-
(0, fixtures_1.test)("accordionView shows only active tab content", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
304
|
-
yield initTestBed(`
|
|
305
|
-
<Tabs accordionView="true" testId="tabs">
|
|
306
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
307
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
308
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
309
|
-
</Tabs>
|
|
310
|
-
`);
|
|
311
|
-
// Only first tab content should be visible (default active)
|
|
312
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
313
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
314
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
315
|
-
}));
|
|
316
|
-
(0, fixtures_1.test)("accordionView positions active tab header above its content", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
317
|
-
yield initTestBed(`
|
|
318
|
-
<Tabs accordionView="true" testId="tabs">
|
|
319
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
320
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
321
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
322
|
-
</Tabs>
|
|
323
|
-
`);
|
|
324
|
-
const tab1Header = page.getByRole("tab", { name: "Tab 1" });
|
|
325
|
-
const tab1Content = page.getByText("Content 1");
|
|
326
|
-
const { bottom: headerBottom } = yield (0, component_test_helpers_1.getBounds)(tab1Header);
|
|
327
|
-
const { top: contentTop } = yield (0, component_test_helpers_1.getBounds)(tab1Content);
|
|
328
|
-
// Header should be above content (header bottom should be less than or near content top)
|
|
329
|
-
(0, fixtures_1.expect)(headerBottom).toBeLessThanOrEqual(contentTop + 5);
|
|
330
|
-
}));
|
|
331
|
-
(0, fixtures_1.test)("accordionView positions active tab content above next tab header", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
332
|
-
yield initTestBed(`
|
|
333
|
-
<Tabs accordionView="true" testId="tabs">
|
|
334
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
335
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
336
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
337
|
-
</Tabs>
|
|
338
|
-
`);
|
|
339
|
-
const tab1Content = page.getByText("Content 1");
|
|
340
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
341
|
-
const { bottom: contentBottom } = yield (0, component_test_helpers_1.getBounds)(tab1Content);
|
|
342
|
-
const { top: nextHeaderTop } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
343
|
-
// Content should be above next header (content bottom should be less than or near next header top)
|
|
344
|
-
(0, fixtures_1.expect)(contentBottom).toBeLessThanOrEqual(nextHeaderTop + 5);
|
|
345
|
-
}));
|
|
346
|
-
(0, fixtures_1.test)("accordionView maintains order: header1 -> content1 -> header2 -> content2 (when tab2 active)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
347
|
-
yield initTestBed(`
|
|
348
|
-
<Tabs accordionView="true" activeTab="1" testId="tabs">
|
|
349
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
350
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
351
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
352
|
-
</Tabs>
|
|
353
|
-
`);
|
|
354
|
-
const tab1Header = page.getByRole("tab", { name: "Tab 1" });
|
|
355
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
356
|
-
const tab2Content = page.getByText("Content 2");
|
|
357
|
-
const tab3Header = page.getByRole("tab", { name: "Tab 3" });
|
|
358
|
-
const { top: tab1Top } = yield (0, component_test_helpers_1.getBounds)(tab1Header);
|
|
359
|
-
const { top: tab2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
360
|
-
const { top: content2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Content);
|
|
361
|
-
const { top: tab3Top } = yield (0, component_test_helpers_1.getBounds)(tab3Header);
|
|
362
|
-
// Verify vertical ordering
|
|
363
|
-
(0, fixtures_1.expect)(tab1Top).toBeLessThan(tab2Top);
|
|
364
|
-
(0, fixtures_1.expect)(tab2Top).toBeLessThan(content2Top);
|
|
365
|
-
(0, fixtures_1.expect)(content2Top).toBeLessThan(tab3Top);
|
|
366
|
-
}));
|
|
367
|
-
(0, fixtures_1.test)("accordionView switches content when different tab is clicked", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
368
|
-
yield initTestBed(`
|
|
369
|
-
<Tabs accordionView="true" testId="tabs">
|
|
370
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
371
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
372
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
373
|
-
</Tabs>
|
|
374
|
-
`);
|
|
375
|
-
// Initially Tab 1 is active
|
|
376
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
377
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
378
|
-
// Click Tab 2
|
|
379
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
380
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
381
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
382
|
-
// Verify Tab 2 content is below Tab 2 header
|
|
383
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
384
|
-
const tab2Content = page.getByText("Content 2");
|
|
385
|
-
const { bottom: headerBottom } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
386
|
-
const { top: contentTop } = yield (0, component_test_helpers_1.getBounds)(tab2Content);
|
|
387
|
-
(0, fixtures_1.expect)(headerBottom).toBeLessThanOrEqual(contentTop + 5);
|
|
388
|
-
}));
|
|
389
|
-
(0, fixtures_1.test)("accordionView works with dynamic activeTab changes", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
390
|
-
const { testStateDriver } = yield initTestBed(`
|
|
391
|
-
<Fragment>
|
|
392
|
-
<Tabs accordionView="true" activeTab="{testState ?? 0}" testId="tabs">
|
|
393
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
394
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
395
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
396
|
-
</Tabs>
|
|
397
|
-
<Button testId="tab2Btn" onClick="testState = 1" />
|
|
398
|
-
<Button testId="tab3Btn" onClick="testState = 2" />
|
|
399
|
-
</Fragment>
|
|
400
|
-
`);
|
|
401
|
-
// Initially Content 1 is visible
|
|
402
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
403
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
404
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
405
|
-
// Switch to Tab 2
|
|
406
|
-
yield page.getByTestId("tab2Btn").click();
|
|
407
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
408
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
409
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
410
|
-
// Verify ordering for Tab 2
|
|
411
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
412
|
-
const tab2Content = page.getByText("Content 2");
|
|
413
|
-
const tab3Header = page.getByRole("tab", { name: "Tab 3" });
|
|
414
|
-
const { top: tab2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
415
|
-
const { top: content2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Content);
|
|
416
|
-
const { top: tab3Top } = yield (0, component_test_helpers_1.getBounds)(tab3Header);
|
|
417
|
-
(0, fixtures_1.expect)(tab2Top).toBeLessThan(content2Top);
|
|
418
|
-
(0, fixtures_1.expect)(content2Top).toBeLessThan(tab3Top);
|
|
419
|
-
// Switch to Tab 3
|
|
420
|
-
yield page.getByTestId("tab3Btn").click();
|
|
421
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).toBeVisible();
|
|
422
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
423
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
424
|
-
}));
|
|
425
|
-
(0, fixtures_1.test)("accordionView=false renders standard tabs (non-accordion)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
426
|
-
yield initTestBed(`
|
|
427
|
-
<Tabs accordionView="false" testId="tabs">
|
|
428
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
429
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
430
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
431
|
-
</Tabs>
|
|
432
|
-
`);
|
|
433
|
-
const tab1Header = page.getByRole("tab", { name: "Tab 1" });
|
|
434
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
435
|
-
const tab1Content = page.getByText("Content 1");
|
|
436
|
-
// In standard mode (non-accordion), all headers should be visible
|
|
437
|
-
yield (0, fixtures_1.expect)(tab1Header).toBeVisible();
|
|
438
|
-
yield (0, fixtures_1.expect)(tab2Header).toBeVisible();
|
|
439
|
-
// Only active tab content should be visible
|
|
440
|
-
yield (0, fixtures_1.expect)(tab1Content).toBeVisible();
|
|
441
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
442
|
-
// Tab content should NOT be interleaved between headers
|
|
443
|
-
// (unlike accordion view where content appears between headers)
|
|
444
|
-
const { bottom: tab1Bottom } = yield (0, component_test_helpers_1.getBounds)(tab1Header);
|
|
445
|
-
const { top: tab2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
446
|
-
const { top: contentTop } = yield (0, component_test_helpers_1.getBounds)(tab1Content);
|
|
447
|
-
// Content should NOT be between the two headers
|
|
448
|
-
// Either tab2 is next to tab1 (horizontal) or below tab1 but before content (vertical)
|
|
449
|
-
const isContentBetweenHeaders = contentTop > tab1Bottom && contentTop < tab2Top;
|
|
450
|
-
(0, fixtures_1.expect)(isContentBetweenHeaders).toBe(false);
|
|
451
|
-
}));
|
|
452
|
-
(0, fixtures_1.test)("accordionView handles null value gracefully (defaults to false)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
453
|
-
yield initTestBed(`
|
|
454
|
-
<Tabs accordionView="{null}" testId="tabs">
|
|
455
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
456
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
457
|
-
</Tabs>
|
|
458
|
-
`);
|
|
459
|
-
// Should render as standard horizontal tabs
|
|
460
|
-
const tab1Header = page.getByRole("tab", { name: "Tab 1" });
|
|
461
|
-
const tab2Header = page.getByRole("tab", { name: "Tab 2" });
|
|
462
|
-
yield (0, fixtures_1.expect)(tab1Header).toBeVisible();
|
|
463
|
-
yield (0, fixtures_1.expect)(tab2Header).toBeVisible();
|
|
464
|
-
// Headers should be horizontally aligned
|
|
465
|
-
const { top: tab1Top } = yield (0, component_test_helpers_1.getBounds)(tab1Header);
|
|
466
|
-
const { top: tab2Top } = yield (0, component_test_helpers_1.getBounds)(tab2Header);
|
|
467
|
-
(0, fixtures_1.expect)(Math.abs(tab1Top - tab2Top)).toBeLessThan(10);
|
|
468
|
-
}));
|
|
469
|
-
});
|
|
470
|
-
});
|
|
471
|
-
// =============================================================================
|
|
472
|
-
// HEADER TEMPLATE TESTS
|
|
473
|
-
// =============================================================================
|
|
474
|
-
fixtures_1.test.describe("headerTemplate functionality", () => {
|
|
475
|
-
(0, fixtures_1.test)("renders custom headerTemplate instead of label", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
476
|
-
yield initTestBed(`
|
|
477
|
-
<Tabs>
|
|
478
|
-
<TabItem label="Simple Label">
|
|
479
|
-
<property name="headerTemplate">
|
|
480
|
-
<VStack gap="$space-1">
|
|
481
|
-
<Text>Custom</Text>
|
|
482
|
-
<Text>Header</Text>
|
|
483
|
-
</VStack>
|
|
484
|
-
</property>
|
|
485
|
-
Content 1
|
|
486
|
-
</TabItem>
|
|
487
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
488
|
-
</Tabs>
|
|
489
|
-
`);
|
|
490
|
-
// Custom header content should be visible
|
|
491
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom")).toBeVisible();
|
|
492
|
-
yield (0, fixtures_1.expect)(page.getByText("Header")).toBeVisible();
|
|
493
|
-
// Simple label should be visible for second tab
|
|
494
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeVisible();
|
|
495
|
-
}));
|
|
496
|
-
(0, fixtures_1.test)("headerTemplate takes priority over global headerTemplate", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
497
|
-
yield initTestBed(`
|
|
498
|
-
<Tabs>
|
|
499
|
-
<property name="headerTemplate">
|
|
500
|
-
<Text>Global: {$header.label}</Text>
|
|
501
|
-
</property>
|
|
502
|
-
<TabItem label="Tab 1">
|
|
503
|
-
<property name="headerTemplate">
|
|
504
|
-
<Text>Custom Content</Text>
|
|
505
|
-
</property>
|
|
506
|
-
Content 1
|
|
507
|
-
</TabItem>
|
|
508
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
509
|
-
</Tabs>
|
|
510
|
-
`);
|
|
511
|
-
// First tab should use individual headerTemplate
|
|
512
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom Content")).toBeVisible();
|
|
513
|
-
// Second tab should use global headerTemplate
|
|
514
|
-
yield (0, fixtures_1.expect)(page.getByText("Global: Tab 2")).toBeVisible();
|
|
515
|
-
}));
|
|
516
|
-
(0, fixtures_1.test)("complex headerTemplate with icons and badges", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
517
|
-
yield initTestBed(`
|
|
518
|
-
<Tabs>
|
|
519
|
-
<TabItem label="Tab 1">
|
|
520
|
-
<property name="headerTemplate">
|
|
521
|
-
<HStack gap="$space-2" alignItems="center">
|
|
522
|
-
<Text>Custom: {$header.label}</Text>
|
|
523
|
-
<Badge>{$header.isActive ? 'Active' : ''}</Badge>
|
|
524
|
-
</HStack>
|
|
525
|
-
</property>
|
|
526
|
-
Content 1
|
|
527
|
-
</TabItem>
|
|
528
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
529
|
-
</Tabs>
|
|
530
|
-
`);
|
|
531
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom: Tab 1")).toBeVisible();
|
|
532
|
-
yield (0, fixtures_1.expect)(page.getByText("Active")).toBeVisible();
|
|
533
|
-
}));
|
|
534
|
-
(0, fixtures_1.test)("headerTemplate receives correct context props", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
535
|
-
yield initTestBed(`
|
|
536
|
-
<Tabs>
|
|
537
|
-
<TabItem label="First Tab">
|
|
538
|
-
<property name="headerTemplate">
|
|
539
|
-
<VStack gap="$space-1">
|
|
540
|
-
<Text>Index: {$header.index}</Text>
|
|
541
|
-
<Text>Label: {$header.label}</Text>
|
|
542
|
-
<Text>Active: {$header.isActive ? 'Yes' : 'No'}</Text>
|
|
543
|
-
</VStack>
|
|
544
|
-
</property>
|
|
545
|
-
Content 1
|
|
546
|
-
</TabItem>
|
|
547
|
-
<TabItem label="Second Tab">Content 2</TabItem>
|
|
548
|
-
</Tabs>
|
|
549
|
-
`);
|
|
550
|
-
yield (0, fixtures_1.expect)(page.getByText("Index: 0")).toBeVisible();
|
|
551
|
-
yield (0, fixtures_1.expect)(page.getByText("Label: First Tab")).toBeVisible();
|
|
552
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Yes")).toBeVisible();
|
|
553
|
-
}));
|
|
554
|
-
(0, fixtures_1.test)("headerTemplate receives external id when provided", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
555
|
-
yield initTestBed(`
|
|
556
|
-
<Tabs>
|
|
557
|
-
<TabItem label="First Tab" id="custom-tab-1">
|
|
558
|
-
<property name="headerTemplate">
|
|
559
|
-
<VStack gap="$space-1">
|
|
560
|
-
<Text>ID: {$header.id}</Text>
|
|
561
|
-
<Text>Label: {$header.label}</Text>
|
|
562
|
-
<Text>Has ID: {$header.id ? 'Yes' : 'No'}</Text>
|
|
563
|
-
</VStack>
|
|
564
|
-
</property>
|
|
565
|
-
Content 1
|
|
566
|
-
</TabItem>
|
|
567
|
-
<TabItem label="Second Tab">
|
|
568
|
-
<property name="headerTemplate">
|
|
569
|
-
<VStack gap="$space-1">
|
|
570
|
-
<Text>Label: {$header.label}</Text>
|
|
571
|
-
<Text>Has ID: {$header.id ? 'Yes' : 'No'}</Text>
|
|
572
|
-
</VStack>
|
|
573
|
-
</property>
|
|
574
|
-
Content 2
|
|
575
|
-
</TabItem>
|
|
576
|
-
</Tabs>
|
|
577
|
-
`);
|
|
578
|
-
// First tab should show the external id
|
|
579
|
-
yield (0, fixtures_1.expect)(page.getByText("ID: custom-tab-1")).toBeVisible();
|
|
580
|
-
yield (0, fixtures_1.expect)(page.getByText("Label: First Tab")).toBeVisible();
|
|
581
|
-
yield (0, fixtures_1.expect)(page.getByText("Has ID: Yes")).toBeVisible();
|
|
582
|
-
// Click second tab
|
|
583
|
-
yield page.getByRole("tab", { name: "Second Tab" }).click();
|
|
584
|
-
// Second tab should not have id in context
|
|
585
|
-
yield (0, fixtures_1.expect)(page.getByText("Label: Second Tab")).toBeVisible();
|
|
586
|
-
yield (0, fixtures_1.expect)(page.getByText("Has ID: No")).toBeVisible();
|
|
587
|
-
}));
|
|
588
|
-
});
|
|
589
|
-
// =============================================================================
|
|
590
|
-
// GLOBAL HEADER TEMPLATE TESTS
|
|
591
|
-
// =============================================================================
|
|
592
|
-
fixtures_1.test.describe("global headerTemplate functionality", () => {
|
|
593
|
-
(0, fixtures_1.test)("global headerTemplate customizes all tab headers", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
594
|
-
yield initTestBed(`
|
|
595
|
-
<Tabs>
|
|
596
|
-
<property name="headerTemplate">
|
|
597
|
-
<Text>Custom: {$header.label}</Text>
|
|
598
|
-
</property>
|
|
599
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
600
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
601
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
602
|
-
</Tabs>
|
|
603
|
-
`);
|
|
604
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom: Tab 1")).toBeVisible();
|
|
605
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom: Tab 2")).toBeVisible();
|
|
606
|
-
yield (0, fixtures_1.expect)(page.getByText("Custom: Tab 3")).toBeVisible();
|
|
607
|
-
}));
|
|
608
|
-
(0, fixtures_1.test)("global headerTemplate receives isActive state", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
609
|
-
yield initTestBed(`
|
|
610
|
-
<Tabs>
|
|
611
|
-
<property name="headerTemplate">
|
|
612
|
-
<Text>{$header.isActive ? 'Active: ' : ''}{$header.label}</Text>
|
|
613
|
-
</property>
|
|
614
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
615
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
616
|
-
</Tabs>
|
|
617
|
-
`);
|
|
618
|
-
// First tab should be active initially
|
|
619
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Tab 1")).toBeVisible();
|
|
620
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 2")).toBeVisible();
|
|
621
|
-
// Click second tab
|
|
622
|
-
yield page.getByText("Tab 2").click();
|
|
623
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 1")).toBeVisible();
|
|
624
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Tab 2")).toBeVisible();
|
|
625
|
-
}));
|
|
626
|
-
(0, fixtures_1.test)("global headerTemplate with complex content", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
627
|
-
yield initTestBed(`
|
|
628
|
-
<Tabs>
|
|
629
|
-
<property name="headerTemplate">
|
|
630
|
-
<HStack>
|
|
631
|
-
<Text>{$header.label} {$header.isActive ? 'active' : ''}</Text>
|
|
632
|
-
</HStack>
|
|
633
|
-
</property>
|
|
634
|
-
<TabItem label="Home">Home content</TabItem>
|
|
635
|
-
<TabItem label="Settings">Settings content</TabItem>
|
|
636
|
-
</Tabs>
|
|
637
|
-
`);
|
|
638
|
-
yield (0, fixtures_1.expect)(page.getByText("Home active")).toBeVisible();
|
|
639
|
-
yield page.getByText("Settings").click();
|
|
640
|
-
yield (0, fixtures_1.expect)(page.getByText("Settings active")).toBeVisible();
|
|
641
|
-
}));
|
|
642
|
-
});
|
|
643
|
-
// =============================================================================
|
|
644
|
-
// FILLER ELEMENT TESTS
|
|
645
|
-
// =============================================================================
|
|
646
|
-
fixtures_1.test.describe("filler element", () => {
|
|
647
|
-
(0, fixtures_1.test)("filler is hidden when distributeEvenly is true", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
648
|
-
yield initTestBed(`
|
|
649
|
-
<Tabs distributeEvenly>
|
|
650
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
651
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
652
|
-
</Tabs>
|
|
653
|
-
`);
|
|
654
|
-
const filler = page.locator('.filler');
|
|
655
|
-
yield (0, fixtures_1.expect)(filler).not.toBeVisible();
|
|
656
|
-
}));
|
|
657
|
-
(0, fixtures_1.test)("filler is hidden when headerRenderer is used", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
658
|
-
yield initTestBed(`
|
|
659
|
-
<Tabs headerRenderer="{(item) => item.label}">
|
|
660
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
661
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
662
|
-
</Tabs>
|
|
663
|
-
`);
|
|
664
|
-
const filler = page.locator('.filler');
|
|
665
|
-
yield (0, fixtures_1.expect)(filler).not.toBeVisible();
|
|
666
|
-
}));
|
|
667
|
-
});
|
|
668
|
-
// =============================================================================
|
|
669
|
-
// EDGE CASES AND ERROR HANDLING
|
|
670
|
-
// =============================================================================
|
|
671
|
-
fixtures_1.test.describe("edge cases", () => {
|
|
672
|
-
(0, fixtures_1.test)("handles empty tabs", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
673
|
-
yield initTestBed(`<Tabs></Tabs>`);
|
|
674
|
-
// Check that empty tabs component is rendered
|
|
675
|
-
yield (0, fixtures_1.expect)(page.getByRole('tablist')).toBeAttached();
|
|
676
|
-
}));
|
|
677
|
-
(0, fixtures_1.test)("handles single tab", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
678
|
-
yield initTestBed(`
|
|
679
|
-
<Tabs>
|
|
680
|
-
<TabItem label="Only Tab">Only content</TabItem>
|
|
681
|
-
</Tabs>
|
|
682
|
-
`);
|
|
683
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Only Tab" })).toBeVisible();
|
|
684
|
-
yield (0, fixtures_1.expect)(page.getByText("Only content")).toBeVisible();
|
|
685
|
-
}));
|
|
686
|
-
(0, fixtures_1.test)("handles tabs with empty content", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
687
|
-
yield initTestBed(`
|
|
688
|
-
<Tabs>
|
|
689
|
-
<TabItem label="Empty Tab"></TabItem>
|
|
690
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
691
|
-
</Tabs>
|
|
692
|
-
`);
|
|
693
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Empty Tab" })).toBeVisible();
|
|
694
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
695
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
696
|
-
}));
|
|
697
|
-
(0, fixtures_1.test)("handles very long tab labels", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
698
|
-
const longLabel = "This is a very long tab label that might cause layout issues";
|
|
699
|
-
yield initTestBed(`
|
|
700
|
-
<Tabs>
|
|
701
|
-
<TabItem label="${longLabel}">Content 1</TabItem>
|
|
702
|
-
<TabItem label="Short">Content 2</TabItem>
|
|
703
|
-
</Tabs>
|
|
704
|
-
`);
|
|
705
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: longLabel })).toBeVisible();
|
|
706
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Short" })).toBeVisible();
|
|
707
|
-
}));
|
|
708
|
-
(0, fixtures_1.test)("handles activeTab out of bounds", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
709
|
-
yield initTestBed(`
|
|
710
|
-
<Tabs activeTab="{5}">
|
|
711
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
712
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
713
|
-
</Tabs>
|
|
714
|
-
`);
|
|
715
|
-
// Should default to first tab when activeTab is out of bounds
|
|
716
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
717
|
-
}));
|
|
718
|
-
});
|
|
719
|
-
// =============================================================================
|
|
720
|
-
// ACCESSIBILITY TESTS
|
|
721
|
-
// =============================================================================
|
|
722
|
-
fixtures_1.test.describe("accessibility", () => {
|
|
723
|
-
(0, fixtures_1.test)("tabs have correct ARIA roles", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
724
|
-
yield initTestBed(`
|
|
725
|
-
<Tabs>
|
|
726
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
727
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
728
|
-
</Tabs>
|
|
729
|
-
`);
|
|
730
|
-
yield (0, fixtures_1.expect)(page.getByRole("tablist")).toBeVisible();
|
|
731
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toBeVisible();
|
|
732
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeVisible();
|
|
733
|
-
yield (0, fixtures_1.expect)(page.getByRole("tabpanel")).toBeVisible();
|
|
734
|
-
}));
|
|
735
|
-
(0, fixtures_1.test)("active tab has correct aria-selected", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
736
|
-
yield initTestBed(`
|
|
737
|
-
<Tabs>
|
|
738
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
739
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
740
|
-
</Tabs>
|
|
741
|
-
`);
|
|
742
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toHaveAttribute("aria-selected", "true");
|
|
743
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toHaveAttribute("aria-selected", "false");
|
|
744
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
745
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 1" })).toHaveAttribute("aria-selected", "false");
|
|
746
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toHaveAttribute("aria-selected", "true");
|
|
747
|
-
}));
|
|
748
|
-
(0, fixtures_1.test)("keyboard navigation works", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
749
|
-
yield initTestBed(`
|
|
750
|
-
<Tabs>
|
|
751
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
752
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
753
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
754
|
-
</Tabs>
|
|
755
|
-
`);
|
|
756
|
-
// Focus first tab
|
|
757
|
-
yield page.getByRole("tab", { name: "Tab 1" }).focus();
|
|
758
|
-
// Arrow right to second tab
|
|
759
|
-
yield page.keyboard.press("ArrowRight");
|
|
760
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeFocused();
|
|
761
|
-
// Arrow right to third tab
|
|
762
|
-
yield page.keyboard.press("ArrowRight");
|
|
763
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 3" })).toBeFocused();
|
|
764
|
-
// Arrow left back to second tab
|
|
765
|
-
yield page.keyboard.press("ArrowLeft");
|
|
766
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Tab 2" })).toBeFocused();
|
|
767
|
-
}));
|
|
768
|
-
// =============================================================================
|
|
769
|
-
fixtures_1.test.describe("API functionality verification", () => {
|
|
770
|
-
(0, fixtures_1.test)("next() method cycles through all tabs correctly", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
771
|
-
yield initTestBed(`
|
|
772
|
-
<Fragment>
|
|
773
|
-
<Tabs id="tabs">
|
|
774
|
-
<TabItem label="Account">
|
|
775
|
-
<Text>Account Content</Text>
|
|
776
|
-
</TabItem>
|
|
777
|
-
<TabItem label="Stream">
|
|
778
|
-
<Text>Stream Content</Text>
|
|
779
|
-
</TabItem>
|
|
780
|
-
<TabItem label="Support">
|
|
781
|
-
<Text>Support Content</Text>
|
|
782
|
-
</TabItem>
|
|
783
|
-
</Tabs>
|
|
784
|
-
<Button onClick="tabs.next()" testId="next-btn">
|
|
785
|
-
Next Tab
|
|
786
|
-
</Button>
|
|
787
|
-
</Fragment>
|
|
788
|
-
`);
|
|
789
|
-
// Initially Account tab should be active (first tab)
|
|
790
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
791
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
792
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
793
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
794
|
-
// Call next() - should move to Stream tab
|
|
795
|
-
yield page.getByTestId("next-btn").click();
|
|
796
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
797
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
798
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
799
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
800
|
-
// Call next() again - should move to Support tab
|
|
801
|
-
yield page.getByTestId("next-btn").click();
|
|
802
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
803
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
804
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
805
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
806
|
-
// Call next() from last tab - should cycle back to Account tab
|
|
807
|
-
yield page.getByTestId("next-btn").click();
|
|
808
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
809
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
810
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
811
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
812
|
-
}));
|
|
813
|
-
(0, fixtures_1.test)("prev() method cycles through all tabs correctly in reverse", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
814
|
-
yield initTestBed(`
|
|
815
|
-
<Fragment>
|
|
816
|
-
<Tabs id="tabs">
|
|
817
|
-
<TabItem label="Account">
|
|
818
|
-
<Text>Account Content</Text>
|
|
819
|
-
</TabItem>
|
|
820
|
-
<TabItem label="Stream">
|
|
821
|
-
<Text>Stream Content</Text>
|
|
822
|
-
</TabItem>
|
|
823
|
-
<TabItem label="Support">
|
|
824
|
-
<Text>Support Content</Text>
|
|
825
|
-
</TabItem>
|
|
826
|
-
</Tabs>
|
|
827
|
-
<Button onClick="tabs.prev()" testId="prev-btn">
|
|
828
|
-
Previous Tab
|
|
829
|
-
</Button>
|
|
830
|
-
</Fragment>
|
|
831
|
-
`);
|
|
832
|
-
// Initially Account tab should be active (first tab)
|
|
833
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
834
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
835
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
836
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
837
|
-
// Call prev() from first tab - should cycle to Support tab (last tab)
|
|
838
|
-
yield page.getByTestId("prev-btn").click();
|
|
839
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
840
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
841
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
842
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
843
|
-
// Call prev() again - should move to Stream tab
|
|
844
|
-
yield page.getByTestId("prev-btn").click();
|
|
845
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
846
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
847
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
848
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
849
|
-
// Call prev() again - should move to Account tab
|
|
850
|
-
yield page.getByTestId("prev-btn").click();
|
|
851
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
852
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
853
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
854
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
855
|
-
}));
|
|
856
|
-
(0, fixtures_1.test)("next() and prev() methods work together for full navigation", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
857
|
-
yield initTestBed(`
|
|
858
|
-
<Fragment>
|
|
859
|
-
<Tabs id="tabs">
|
|
860
|
-
<TabItem label="Account">
|
|
861
|
-
<Text>Account Content</Text>
|
|
862
|
-
</TabItem>
|
|
863
|
-
<TabItem label="Stream">
|
|
864
|
-
<Text>Stream Content</Text>
|
|
865
|
-
</TabItem>
|
|
866
|
-
<TabItem label="Support">
|
|
867
|
-
<Text>Support Content</Text>
|
|
868
|
-
</TabItem>
|
|
869
|
-
</Tabs>
|
|
870
|
-
<Button onClick="tabs.next()" testId="next-btn">
|
|
871
|
-
Next Tab
|
|
872
|
-
</Button>
|
|
873
|
-
<Button onClick="tabs.prev()" testId="prev-btn">
|
|
874
|
-
Previous Tab
|
|
875
|
-
</Button>
|
|
876
|
-
</Fragment>
|
|
877
|
-
`);
|
|
878
|
-
// Start at Account tab
|
|
879
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
880
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
881
|
-
// Go forward twice: Account -> Stream -> Support
|
|
882
|
-
yield page.getByTestId("next-btn").click();
|
|
883
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
884
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
885
|
-
yield page.getByTestId("next-btn").click();
|
|
886
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
887
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
888
|
-
// Go back once: Support -> Stream
|
|
889
|
-
yield page.getByTestId("prev-btn").click();
|
|
890
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
891
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
892
|
-
// Go forward to cycle: Stream -> Support -> Account
|
|
893
|
-
yield page.getByTestId("next-btn").click();
|
|
894
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
895
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
896
|
-
yield page.getByTestId("next-btn").click();
|
|
897
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
898
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
899
|
-
}));
|
|
900
|
-
(0, fixtures_1.test)("tabs can be navigated programmatically (simulating next() behavior)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
901
|
-
yield initTestBed(`
|
|
902
|
-
<Tabs>
|
|
903
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
904
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
905
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
906
|
-
</Tabs>
|
|
907
|
-
`);
|
|
908
|
-
// Initially first tab is active
|
|
909
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
910
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
911
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
912
|
-
// Simulate next() - move to second tab
|
|
913
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
914
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
915
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
916
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
917
|
-
// Simulate next() - move to third tab
|
|
918
|
-
yield page.getByRole("tab", { name: "Tab 3" }).click();
|
|
919
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
920
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
921
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).toBeVisible();
|
|
922
|
-
// Simulate next() - should cycle back to first tab
|
|
923
|
-
yield page.getByRole("tab", { name: "Tab 1" }).click();
|
|
924
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
925
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
926
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
927
|
-
}));
|
|
928
|
-
(0, fixtures_1.test)("tabs can be navigated backwards programmatically (simulating prev() behavior)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
929
|
-
yield initTestBed(`
|
|
930
|
-
<Tabs>
|
|
931
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
932
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
933
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
934
|
-
</Tabs>
|
|
935
|
-
`);
|
|
936
|
-
// Initially first tab is active
|
|
937
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
938
|
-
// Simulate prev() from first tab - should cycle to last tab
|
|
939
|
-
yield page.getByRole("tab", { name: "Tab 3" }).click();
|
|
940
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
941
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
942
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).toBeVisible();
|
|
943
|
-
// Simulate prev() - move to second tab
|
|
944
|
-
yield page.getByRole("tab", { name: "Tab 2" }).click();
|
|
945
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
946
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).toBeVisible();
|
|
947
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
948
|
-
// Simulate prev() - move to first tab
|
|
949
|
-
yield page.getByRole("tab", { name: "Tab 1" }).click();
|
|
950
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).toBeVisible();
|
|
951
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
952
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).not.toBeVisible();
|
|
953
|
-
}));
|
|
954
|
-
(0, fixtures_1.test)("activeTab prop sets initial tab correctly (simulating setActiveTabIndex())", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
955
|
-
yield initTestBed(`
|
|
956
|
-
<Tabs activeTab="{2}">
|
|
957
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
958
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
959
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
960
|
-
</Tabs>
|
|
961
|
-
`);
|
|
962
|
-
// Third tab should be active initially (index 2)
|
|
963
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 3")).toBeVisible();
|
|
964
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 1")).not.toBeVisible();
|
|
965
|
-
yield (0, fixtures_1.expect)(page.getByText("Content 2")).not.toBeVisible();
|
|
966
|
-
}));
|
|
967
|
-
(0, fixtures_1.test)("ArrowRight key cycles through all tabs correctly (keyboard navigation)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
968
|
-
yield initTestBed(`
|
|
969
|
-
<Tabs>
|
|
970
|
-
<TabItem label="Account">
|
|
971
|
-
<Text>Account Content</Text>
|
|
972
|
-
</TabItem>
|
|
973
|
-
<TabItem label="Stream">
|
|
974
|
-
<Text>Stream Content</Text>
|
|
975
|
-
</TabItem>
|
|
976
|
-
<TabItem label="Support">
|
|
977
|
-
<Text>Support Content</Text>
|
|
978
|
-
</TabItem>
|
|
979
|
-
</Tabs>
|
|
980
|
-
`);
|
|
981
|
-
// Initially Account tab should be active and focused
|
|
982
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
983
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
984
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
985
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
986
|
-
// Focus the first tab
|
|
987
|
-
yield page.getByRole("tab", { name: "Account" }).focus();
|
|
988
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toBeFocused();
|
|
989
|
-
// Press ArrowRight - should move to Stream tab
|
|
990
|
-
yield page.keyboard.press("ArrowRight");
|
|
991
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
992
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
993
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
994
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
995
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toBeFocused();
|
|
996
|
-
// Press ArrowRight again - should move to Support tab
|
|
997
|
-
yield page.keyboard.press("ArrowRight");
|
|
998
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
999
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
1000
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
1001
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
1002
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toBeFocused();
|
|
1003
|
-
// Press ArrowRight from last tab - should cycle back to Account tab
|
|
1004
|
-
yield page.keyboard.press("ArrowRight");
|
|
1005
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
1006
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
1007
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
1008
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
1009
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toBeFocused();
|
|
1010
|
-
}));
|
|
1011
|
-
(0, fixtures_1.test)("ArrowLeft key cycles through all tabs correctly in reverse (keyboard navigation)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1012
|
-
yield initTestBed(`
|
|
1013
|
-
<Tabs>
|
|
1014
|
-
<TabItem label="Account">
|
|
1015
|
-
<Text>Account Content</Text>
|
|
1016
|
-
</TabItem>
|
|
1017
|
-
<TabItem label="Stream">
|
|
1018
|
-
<Text>Stream Content</Text>
|
|
1019
|
-
</TabItem>
|
|
1020
|
-
<TabItem label="Support">
|
|
1021
|
-
<Text>Support Content</Text>
|
|
1022
|
-
</TabItem>
|
|
1023
|
-
</Tabs>
|
|
1024
|
-
`);
|
|
1025
|
-
// Initially Account tab should be active
|
|
1026
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
1027
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
1028
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
1029
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
1030
|
-
// Focus the first tab
|
|
1031
|
-
yield page.getByRole("tab", { name: "Account" }).focus();
|
|
1032
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toBeFocused();
|
|
1033
|
-
// Press ArrowLeft from first tab - should cycle to Support tab (last tab)
|
|
1034
|
-
yield page.keyboard.press("ArrowLeft");
|
|
1035
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
1036
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
1037
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
1038
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
1039
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toBeFocused();
|
|
1040
|
-
// Press ArrowLeft again - should move to Stream tab
|
|
1041
|
-
yield page.keyboard.press("ArrowLeft");
|
|
1042
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).not.toBeVisible();
|
|
1043
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
1044
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
1045
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
1046
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toBeFocused();
|
|
1047
|
-
// Press ArrowLeft again - should move to Account tab
|
|
1048
|
-
yield page.keyboard.press("ArrowLeft");
|
|
1049
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
1050
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).not.toBeVisible();
|
|
1051
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).not.toBeVisible();
|
|
1052
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
1053
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toBeFocused();
|
|
1054
|
-
}));
|
|
1055
|
-
(0, fixtures_1.test)("ArrowRight and ArrowLeft keys work together for full keyboard navigation", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1056
|
-
yield initTestBed(`
|
|
1057
|
-
<Tabs>
|
|
1058
|
-
<TabItem label="Account">
|
|
1059
|
-
<Text>Account Content</Text>
|
|
1060
|
-
</TabItem>
|
|
1061
|
-
<TabItem label="Stream">
|
|
1062
|
-
<Text>Stream Content</Text>
|
|
1063
|
-
</TabItem>
|
|
1064
|
-
<TabItem label="Support">
|
|
1065
|
-
<Text>Support Content</Text>
|
|
1066
|
-
</TabItem>
|
|
1067
|
-
</Tabs>
|
|
1068
|
-
`);
|
|
1069
|
-
// Start at Account tab and focus it
|
|
1070
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
1071
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
1072
|
-
yield page.getByRole("tab", { name: "Account" }).focus();
|
|
1073
|
-
// Go forward twice: Account -> Stream -> Support
|
|
1074
|
-
yield page.keyboard.press("ArrowRight");
|
|
1075
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
1076
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
1077
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toBeFocused();
|
|
1078
|
-
yield page.keyboard.press("ArrowRight");
|
|
1079
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
1080
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
1081
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toBeFocused();
|
|
1082
|
-
// Go back once: Support -> Stream
|
|
1083
|
-
yield page.keyboard.press("ArrowLeft");
|
|
1084
|
-
yield (0, fixtures_1.expect)(page.getByText("Stream Content")).toBeVisible();
|
|
1085
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toHaveAttribute("aria-selected", "true");
|
|
1086
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Stream" })).toBeFocused();
|
|
1087
|
-
// Go forward to cycle: Stream -> Support -> Account
|
|
1088
|
-
yield page.keyboard.press("ArrowRight");
|
|
1089
|
-
yield (0, fixtures_1.expect)(page.getByText("Support Content")).toBeVisible();
|
|
1090
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toHaveAttribute("aria-selected", "true");
|
|
1091
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Support" })).toBeFocused();
|
|
1092
|
-
yield page.keyboard.press("ArrowRight");
|
|
1093
|
-
yield (0, fixtures_1.expect)(page.getByText("Account Content")).toBeVisible();
|
|
1094
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toHaveAttribute("aria-selected", "true");
|
|
1095
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Account" })).toBeFocused();
|
|
1096
|
-
}));
|
|
1097
|
-
(0, fixtures_1.test)("API methods work with headerTemplate (visual verification)", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1098
|
-
yield initTestBed(`
|
|
1099
|
-
<Fragment>
|
|
1100
|
-
<Tabs id="tabs">
|
|
1101
|
-
<property name="headerTemplate">
|
|
1102
|
-
<Text>{$header.isActive ? 'Active: ' : ''}{$header.label}</Text>
|
|
1103
|
-
</property>
|
|
1104
|
-
<TabItem label="Tab 1">Content 1</TabItem>
|
|
1105
|
-
<TabItem label="Tab 2">Content 2</TabItem>
|
|
1106
|
-
<TabItem label="Tab 3">Content 3</TabItem>
|
|
1107
|
-
</Tabs>
|
|
1108
|
-
<Button onClick="tabs.prev()">Prev</Button>
|
|
1109
|
-
<Button onClick="tabs.next()">Next</Button>
|
|
1110
|
-
</Fragment>
|
|
1111
|
-
`);
|
|
1112
|
-
// Initially first tab is active
|
|
1113
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Tab 1")).toBeVisible();
|
|
1114
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 2")).toBeVisible();
|
|
1115
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 3")).toBeVisible();
|
|
1116
|
-
// Simulate next() behavior by clicking second tab
|
|
1117
|
-
yield page.getByRole("button", { name: "Next" }).click();
|
|
1118
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Tab 2")).toBeVisible();
|
|
1119
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 1")).toBeVisible();
|
|
1120
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 3")).toBeVisible();
|
|
1121
|
-
// Simulate prev() behavior by clicking first tab
|
|
1122
|
-
yield page.getByRole("button", { name: "Prev" }).click();
|
|
1123
|
-
yield (0, fixtures_1.expect)(page.getByText("Active: Tab 1")).toBeVisible();
|
|
1124
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 2")).toBeVisible();
|
|
1125
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab 3")).toBeVisible();
|
|
1126
|
-
}));
|
|
1127
|
-
});
|
|
1128
|
-
});
|
|
1129
|
-
// =============================================================================
|
|
1130
|
-
// DYNAMIC CONTENT TESTS
|
|
1131
|
-
// =============================================================================
|
|
1132
|
-
fixtures_1.test.describe("dynamic content", () => {
|
|
1133
|
-
(0, fixtures_1.test)("works with Items component for dynamic tabs", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1134
|
-
yield initTestBed(`
|
|
1135
|
-
<Tabs>
|
|
1136
|
-
<Items data="{['First', 'Second', 'Third']}">
|
|
1137
|
-
<TabItem label="{$item}">Content for {$item}</TabItem>
|
|
1138
|
-
</Items>
|
|
1139
|
-
</Tabs>
|
|
1140
|
-
`);
|
|
1141
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "First" })).toBeVisible();
|
|
1142
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Second" })).toBeVisible();
|
|
1143
|
-
yield (0, fixtures_1.expect)(page.getByRole("tab", { name: "Third" })).toBeVisible();
|
|
1144
|
-
yield page.getByRole("tab", { name: "Second" }).click();
|
|
1145
|
-
yield (0, fixtures_1.expect)(page.getByText("Content for Second")).toBeVisible();
|
|
1146
|
-
}));
|
|
1147
|
-
(0, fixtures_1.test)("headerTemplate works with dynamic content from Items", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1148
|
-
yield initTestBed(`
|
|
1149
|
-
<Tabs>
|
|
1150
|
-
<property name="headerTemplate">
|
|
1151
|
-
<Text color="red">Account {$header.label}</Text>
|
|
1152
|
-
</property>
|
|
1153
|
-
<Items data="{[1, 2, 3, 4, 5]}">
|
|
1154
|
-
<TabItem label="Account {$item}">
|
|
1155
|
-
<property name="headerTemplate">
|
|
1156
|
-
<Text when="true" color="blue">{$header.label} | {$item}</Text>
|
|
1157
|
-
</property>
|
|
1158
|
-
Content for account {$item}
|
|
1159
|
-
</TabItem>
|
|
1160
|
-
</Items>
|
|
1161
|
-
</Tabs>
|
|
1162
|
-
`);
|
|
1163
|
-
// Check that individual headerTemplate takes priority and has access to both $header and $item
|
|
1164
|
-
yield (0, fixtures_1.expect)(page.getByText("Account 1 | 1")).toBeVisible();
|
|
1165
|
-
yield (0, fixtures_1.expect)(page.getByText("Account 2 | 2")).toBeVisible();
|
|
1166
|
-
yield (0, fixtures_1.expect)(page.getByText("Account 3 | 3")).toBeVisible();
|
|
1167
|
-
yield (0, fixtures_1.expect)(page.getByText("Account 4 | 4")).toBeVisible();
|
|
1168
|
-
yield (0, fixtures_1.expect)(page.getByText("Account 5 | 5")).toBeVisible();
|
|
1169
|
-
// Test clicking on different tabs
|
|
1170
|
-
yield page.getByText("Account 3 | 3").click();
|
|
1171
|
-
yield (0, fixtures_1.expect)(page.getByText("Content for account 3")).toBeVisible();
|
|
1172
|
-
}));
|
|
1173
|
-
});
|
|
1174
|
-
fixtures_1.test.describe("onDidChange callback functionality", () => {
|
|
1175
|
-
(0, fixtures_1.test)("onDidChange callback is called when tab changes", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1176
|
-
yield initTestBed(`
|
|
1177
|
-
<Fragment var.tabChangeInfo="No change yet">
|
|
1178
|
-
<Tabs onDidChange="(index, id, label) => {
|
|
1179
|
-
tabChangeInfo = 'Tab: ' + index + ' - ' + label;
|
|
1180
|
-
}">
|
|
1181
|
-
<TabItem label="First Tab">
|
|
1182
|
-
<Text>First tab content</Text>
|
|
1183
|
-
</TabItem>
|
|
1184
|
-
<TabItem label="Second Tab">
|
|
1185
|
-
<Text>Second tab content</Text>
|
|
1186
|
-
</TabItem>
|
|
1187
|
-
<TabItem label="Third Tab">
|
|
1188
|
-
<Text>Third tab content</Text>
|
|
1189
|
-
</TabItem>
|
|
1190
|
-
</Tabs>
|
|
1191
|
-
<Text>{tabChangeInfo}</Text>
|
|
1192
|
-
</Fragment>
|
|
1193
|
-
`);
|
|
1194
|
-
// Initially should show no change
|
|
1195
|
-
yield (0, fixtures_1.expect)(page.getByText("No change yet")).toBeVisible();
|
|
1196
|
-
yield (0, fixtures_1.expect)(page.getByText("First tab content")).toBeVisible();
|
|
1197
|
-
// Click on second tab
|
|
1198
|
-
yield page.getByRole("tab", { name: "Second Tab" }).click();
|
|
1199
|
-
yield (0, fixtures_1.expect)(page.getByText("Second tab content")).toBeVisible();
|
|
1200
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab: 1 - Second Tab")).toBeVisible();
|
|
1201
|
-
// Click on third tab
|
|
1202
|
-
yield page.getByRole("tab", { name: "Third Tab" }).click();
|
|
1203
|
-
yield (0, fixtures_1.expect)(page.getByText("Third tab content")).toBeVisible();
|
|
1204
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab: 2 - Third Tab")).toBeVisible();
|
|
1205
|
-
// Click back to first tab
|
|
1206
|
-
yield page.getByRole("tab", { name: "First Tab" }).click();
|
|
1207
|
-
yield (0, fixtures_1.expect)(page.getByText("First tab content")).toBeVisible();
|
|
1208
|
-
yield (0, fixtures_1.expect)(page.getByText("Tab: 0 - First Tab")).toBeVisible();
|
|
1209
|
-
}));
|
|
1210
|
-
(0, fixtures_1.test)("onDidChange callback is not called when same tab is clicked", (_a) => __awaiter(void 0, [_a], void 0, function* ({ initTestBed, page }) {
|
|
1211
|
-
yield initTestBed(`
|
|
1212
|
-
<Fragment var.changeCount="{0}">
|
|
1213
|
-
<Tabs onDidChange="(index, id, label) => {
|
|
1214
|
-
changeCount = changeCount + 1;
|
|
1215
|
-
}">
|
|
1216
|
-
<TabItem label="Tab One">
|
|
1217
|
-
<Text>Content one</Text>
|
|
1218
|
-
</TabItem>
|
|
1219
|
-
<TabItem label="Tab Two">
|
|
1220
|
-
<Text>Content two</Text>
|
|
1221
|
-
</TabItem>
|
|
1222
|
-
</Tabs>
|
|
1223
|
-
<Text>Changes: {changeCount}</Text>
|
|
1224
|
-
</Fragment>
|
|
1225
|
-
`);
|
|
1226
|
-
// Initially should show 0 changes
|
|
1227
|
-
yield (0, fixtures_1.expect)(page.getByText("Changes: 0")).toBeVisible();
|
|
1228
|
-
yield (0, fixtures_1.expect)(page.getByText("Content one")).toBeVisible();
|
|
1229
|
-
// Click on second tab - should trigger onDidChange
|
|
1230
|
-
yield page.getByRole("tab", { name: "Tab Two" }).click();
|
|
1231
|
-
yield (0, fixtures_1.expect)(page.getByText("Content two")).toBeVisible();
|
|
1232
|
-
yield (0, fixtures_1.expect)(page.getByText("Changes: 1")).toBeVisible();
|
|
1233
|
-
// Click on second tab again - should NOT trigger onDidChange
|
|
1234
|
-
yield page.getByRole("tab", { name: "Tab Two" }).click();
|
|
1235
|
-
yield (0, fixtures_1.expect)(page.getByText("Changes: 1")).toBeVisible(); // Should still be 1
|
|
1236
|
-
}));
|
|
1237
|
-
});
|