#
tokens: 45279/50000 3/1629 files (page 90/186)
lines: on (toggle) GitHub
raw markdown copy reset
This is page 90 of 186. Use http://codebase.md/xmlui-org/xmlui/xmlui/tools/vscode/resources/xmlui-markup-syntax-highlighting.png?lines=true&page={x} to view the full context.

# Directory Structure

```
├── .changeset
│   └── config.json
├── .eslintrc.cjs
├── .github
│   ├── build-checklist.png
│   ├── ISSUE_TEMPLATE
│   │   ├── bug_report.md
│   │   └── feature_request.md
│   └── workflows
│       ├── deploy-blog-optimized.yml
│       ├── deploy-blog-swa.yml
│       ├── deploy-blog.yml
│       ├── deploy-docs-optimized.yml
│       ├── deploy-docs-swa.yml
│       ├── deploy-docs.yml
│       ├── prepare-versions.yml
│       ├── release-packages.yml
│       ├── run-all-tests.yml
│       └── run-smoke-tests.yml
├── .gitignore
├── .prettierrc.js
├── .vscode
│   ├── launch.json
│   └── settings.json
├── blog
│   ├── .gitignore
│   ├── .gitkeep
│   ├── CHANGELOG.md
│   ├── extensions.ts
│   ├── index.html
│   ├── index.ts
│   ├── package.json
│   ├── public
│   │   ├── blog
│   │   │   ├── images
│   │   │   │   ├── an-advanced-codefence.gif
│   │   │   │   ├── an-advanced-codefence.mp4
│   │   │   │   ├── blog-page-component.png
│   │   │   │   ├── blog-scrabble.png
│   │   │   │   ├── codefence-runner.png
│   │   │   │   ├── integrated-blog-search.png
│   │   │   │   ├── lorem-ipsum.png
│   │   │   │   ├── playground-checkbox-source.png
│   │   │   │   ├── playground.png
│   │   │   │   ├── use-xmlui-mcp-to-find-a-howto.png
│   │   │   │   └── xmlui-demo-gallery.png
│   │   │   ├── introducing-xmlui.md
│   │   │   ├── lorem-ipsum.md
│   │   │   ├── newest-post.md
│   │   │   ├── older-post.md
│   │   │   ├── xmlui-playground.md
│   │   │   └── xmlui-powered-blog.md
│   │   ├── mockServiceWorker.js
│   │   ├── resources
│   │   │   ├── favicon.ico
│   │   │   ├── files
│   │   │   │   └── for-download
│   │   │   │       └── xmlui
│   │   │   │           └── xmlui-standalone.umd.js
│   │   │   ├── github.svg
│   │   │   ├── llms.txt
│   │   │   ├── logo-dark.svg
│   │   │   ├── logo.svg
│   │   │   ├── pg-popout.svg
│   │   │   ├── rss.svg
│   │   │   └── xmlui-logo.svg
│   │   ├── serve.json
│   │   ├── staticwebapp.config.json
│   │   └── web.config
│   ├── scripts
│   │   ├── download-latest-xmlui.js
│   │   ├── generate-rss.js
│   │   ├── get-releases.js
│   │   └── utils.js
│   ├── src
│   │   ├── components
│   │   │   ├── BlogOverview.xmlui
│   │   │   ├── BlogPage.xmlui
│   │   │   └── PageNotFound.xmlui
│   │   ├── config.ts
│   │   ├── Main.xmlui
│   │   └── themes
│   │       └── blog-theme.ts
│   └── tsconfig.json
├── CONTRIBUTING.md
├── docs
│   ├── .gitignore
│   ├── CHANGELOG.md
│   ├── ComponentRefLinks.txt
│   ├── content
│   │   ├── _meta.json
│   │   ├── components
│   │   │   ├── _meta.json
│   │   │   ├── _overview.md
│   │   │   ├── APICall.md
│   │   │   ├── App.md
│   │   │   ├── AppHeader.md
│   │   │   ├── AppState.md
│   │   │   ├── AutoComplete.md
│   │   │   ├── Avatar.md
│   │   │   ├── Backdrop.md
│   │   │   ├── Badge.md
│   │   │   ├── BarChart.md
│   │   │   ├── Bookmark.md
│   │   │   ├── Breakout.md
│   │   │   ├── Button.md
│   │   │   ├── Card.md
│   │   │   ├── Carousel.md
│   │   │   ├── ChangeListener.md
│   │   │   ├── Checkbox.md
│   │   │   ├── CHStack.md
│   │   │   ├── ColorPicker.md
│   │   │   ├── Column.md
│   │   │   ├── ContentSeparator.md
│   │   │   ├── CVStack.md
│   │   │   ├── DataSource.md
│   │   │   ├── DateInput.md
│   │   │   ├── DatePicker.md
│   │   │   ├── DonutChart.md
│   │   │   ├── DropdownMenu.md
│   │   │   ├── EmojiSelector.md
│   │   │   ├── ExpandableItem.md
│   │   │   ├── FileInput.md
│   │   │   ├── FileUploadDropZone.md
│   │   │   ├── FlowLayout.md
│   │   │   ├── Footer.md
│   │   │   ├── Form.md
│   │   │   ├── FormItem.md
│   │   │   ├── FormSection.md
│   │   │   ├── Fragment.md
│   │   │   ├── H1.md
│   │   │   ├── H2.md
│   │   │   ├── H3.md
│   │   │   ├── H4.md
│   │   │   ├── H5.md
│   │   │   ├── H6.md
│   │   │   ├── Heading.md
│   │   │   ├── HSplitter.md
│   │   │   ├── HStack.md
│   │   │   ├── Icon.md
│   │   │   ├── IFrame.md
│   │   │   ├── Image.md
│   │   │   ├── Items.md
│   │   │   ├── LabelList.md
│   │   │   ├── Legend.md
│   │   │   ├── LineChart.md
│   │   │   ├── Link.md
│   │   │   ├── List.md
│   │   │   ├── Logo.md
│   │   │   ├── Markdown.md
│   │   │   ├── MenuItem.md
│   │   │   ├── MenuSeparator.md
│   │   │   ├── ModalDialog.md
│   │   │   ├── NavGroup.md
│   │   │   ├── NavLink.md
│   │   │   ├── NavPanel.md
│   │   │   ├── NoResult.md
│   │   │   ├── NumberBox.md
│   │   │   ├── Option.md
│   │   │   ├── Page.md
│   │   │   ├── PageMetaTitle.md
│   │   │   ├── Pages.md
│   │   │   ├── Pagination.md
│   │   │   ├── PasswordInput.md
│   │   │   ├── PieChart.md
│   │   │   ├── ProgressBar.md
│   │   │   ├── Queue.md
│   │   │   ├── RadioGroup.md
│   │   │   ├── RealTimeAdapter.md
│   │   │   ├── Redirect.md
│   │   │   ├── Select.md
│   │   │   ├── Slider.md
│   │   │   ├── Slot.md
│   │   │   ├── SpaceFiller.md
│   │   │   ├── Spinner.md
│   │   │   ├── Splitter.md
│   │   │   ├── Stack.md
│   │   │   ├── StickyBox.md
│   │   │   ├── SubMenuItem.md
│   │   │   ├── Switch.md
│   │   │   ├── TabItem.md
│   │   │   ├── Table.md
│   │   │   ├── TableOfContents.md
│   │   │   ├── Tabs.md
│   │   │   ├── Text.md
│   │   │   ├── TextArea.md
│   │   │   ├── TextBox.md
│   │   │   ├── Theme.md
│   │   │   ├── TimeInput.md
│   │   │   ├── Timer.md
│   │   │   ├── ToneChangerButton.md
│   │   │   ├── ToneSwitch.md
│   │   │   ├── Tooltip.md
│   │   │   ├── Tree.md
│   │   │   ├── VSplitter.md
│   │   │   ├── VStack.md
│   │   │   ├── xmlui-animations
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   ├── Animation.md
│   │   │   │   ├── FadeAnimation.md
│   │   │   │   ├── FadeInAnimation.md
│   │   │   │   ├── FadeOutAnimation.md
│   │   │   │   ├── ScaleAnimation.md
│   │   │   │   └── SlideInAnimation.md
│   │   │   ├── xmlui-pdf
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   └── Pdf.md
│   │   │   ├── xmlui-spreadsheet
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   └── Spreadsheet.md
│   │   │   └── xmlui-website-blocks
│   │   │       ├── _meta.json
│   │   │       ├── _overview.md
│   │   │       ├── Carousel.md
│   │   │       ├── HelloMd.md
│   │   │       ├── HeroSection.md
│   │   │       └── ScrollToTop.md
│   │   └── extensions
│   │       ├── _meta.json
│   │       ├── xmlui-animations
│   │       │   ├── _meta.json
│   │       │   ├── _overview.md
│   │       │   ├── Animation.md
│   │       │   ├── FadeAnimation.md
│   │       │   ├── FadeInAnimation.md
│   │       │   ├── FadeOutAnimation.md
│   │       │   ├── ScaleAnimation.md
│   │       │   └── SlideInAnimation.md
│   │       └── xmlui-website-blocks
│   │           ├── _meta.json
│   │           ├── _overview.md
│   │           ├── Carousel.md
│   │           ├── FancyButton.md
│   │           ├── HeroSection.md
│   │           └── ScrollToTop.md
│   ├── extensions.ts
│   ├── index.html
│   ├── index.ts
│   ├── package.json
│   ├── public
│   │   ├── feed.rss
│   │   ├── mockServiceWorker.js
│   │   ├── pages
│   │   │   ├── _meta.json
│   │   │   ├── app-structure.md
│   │   │   ├── build-editor-component.md
│   │   │   ├── build-hello-world-component.md
│   │   │   ├── components-intro.md
│   │   │   ├── context-variables.md
│   │   │   ├── forms.md
│   │   │   ├── globals.md
│   │   │   ├── glossary.md
│   │   │   ├── helper-tags.md
│   │   │   ├── hosted-deployment.md
│   │   │   ├── howto
│   │   │   │   ├── assign-a-complex-json-literal-to-a-component-variable.md
│   │   │   │   ├── chain-a-refetch.md
│   │   │   │   ├── control-cache-invalidation.md
│   │   │   │   ├── debounce-user-input-for-api-calls.md
│   │   │   │   ├── debounce-with-changelistener.md
│   │   │   │   ├── debug-a-component.md
│   │   │   │   ├── delay-a-datasource-until-another-datasource-is-ready.md
│   │   │   │   ├── delegate-a-method.md
│   │   │   │   ├── do-custom-form-validation.md
│   │   │   │   ├── expose-a-method-from-a-component.md
│   │   │   │   ├── filter-and-transform-data-from-an-api.md
│   │   │   │   ├── group-items-in-list-by-a-property.md
│   │   │   │   ├── handle-background-operations.md
│   │   │   │   ├── hide-an-element-until-its-datasource-is-ready.md
│   │   │   │   ├── make-a-set-of-equal-width-cards.md
│   │   │   │   ├── make-a-table-responsive.md
│   │   │   │   ├── make-navpanel-width-responsive.md
│   │   │   │   ├── modify-a-value-reported-in-a-column.md
│   │   │   │   ├── paginate-a-list.md
│   │   │   │   ├── pass-data-to-a-modal-dialog.md
│   │   │   │   ├── react-to-button-click-not-keystrokes.md
│   │   │   │   ├── set-the-initial-value-of-a-select-from-fetched-data.md
│   │   │   │   ├── share-a-modaldialog-across-components.md
│   │   │   │   ├── sync-selections-between-table-and-list-views.md
│   │   │   │   ├── update-ui-optimistically.md
│   │   │   │   ├── use-built-in-form-validation.md
│   │   │   │   └── use-the-same-modaldialog-to-add-or-edit.md
│   │   │   ├── howto.md
│   │   │   ├── intro.md
│   │   │   ├── layout.md
│   │   │   ├── markup.md
│   │   │   ├── mcp.md
│   │   │   ├── modal-dialogs.md
│   │   │   ├── news-and-reviews.md
│   │   │   ├── reactive-intro.md
│   │   │   ├── refactoring.md
│   │   │   ├── routing-and-links.md
│   │   │   ├── samples
│   │   │   │   ├── color-palette.xmlui
│   │   │   │   ├── color-values.xmlui
│   │   │   │   ├── shadow-sizes.xmlui
│   │   │   │   ├── spacing-sizes.xmlui
│   │   │   │   ├── swatch.xmlui
│   │   │   │   ├── theme-gallery-brief.xmlui
│   │   │   │   └── theme-gallery.xmlui
│   │   │   ├── scoping.md
│   │   │   ├── scripting.md
│   │   │   ├── styles-and-themes
│   │   │   │   ├── common-units.md
│   │   │   │   ├── layout-props.md
│   │   │   │   ├── theme-variable-defaults.md
│   │   │   │   ├── theme-variables.md
│   │   │   │   └── themes.md
│   │   │   ├── template-properties.md
│   │   │   ├── test.md
│   │   │   ├── tutorial-01.md
│   │   │   ├── tutorial-02.md
│   │   │   ├── tutorial-03.md
│   │   │   ├── tutorial-04.md
│   │   │   ├── tutorial-05.md
│   │   │   ├── tutorial-06.md
│   │   │   ├── tutorial-07.md
│   │   │   ├── tutorial-08.md
│   │   │   ├── tutorial-09.md
│   │   │   ├── tutorial-10.md
│   │   │   ├── tutorial-11.md
│   │   │   ├── tutorial-12.md
│   │   │   ├── universal-properties.md
│   │   │   ├── user-defined-components.md
│   │   │   ├── vscode.md
│   │   │   ├── working-with-markdown.md
│   │   │   ├── working-with-text.md
│   │   │   ├── xmlui-animations
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   ├── Animation.md
│   │   │   │   ├── FadeAnimation.md
│   │   │   │   ├── FadeInAnimation.md
│   │   │   │   ├── FadeOutAnimation.md
│   │   │   │   ├── ScaleAnimation.md
│   │   │   │   └── SlideInAnimation.md
│   │   │   ├── xmlui-charts
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   ├── BarChart.md
│   │   │   │   ├── DonutChart.md
│   │   │   │   ├── LabelList.md
│   │   │   │   ├── Legend.md
│   │   │   │   ├── LineChart.md
│   │   │   │   └── PieChart.md
│   │   │   ├── xmlui-pdf
│   │   │   │   ├── _meta.json
│   │   │   │   ├── _overview.md
│   │   │   │   └── Pdf.md
│   │   │   └── xmlui-spreadsheet
│   │   │       ├── _meta.json
│   │   │       ├── _overview.md
│   │   │       └── Spreadsheet.md
│   │   ├── resources
│   │   │   ├── devdocs
│   │   │   │   ├── debug-proxy-object-2.png
│   │   │   │   ├── debug-proxy-object.png
│   │   │   │   ├── table_editor_01.png
│   │   │   │   ├── table_editor_02.png
│   │   │   │   ├── table_editor_03.png
│   │   │   │   ├── table_editor_04.png
│   │   │   │   ├── table_editor_05.png
│   │   │   │   ├── table_editor_06.png
│   │   │   │   ├── table_editor_07.png
│   │   │   │   ├── table_editor_08.png
│   │   │   │   ├── table_editor_09.png
│   │   │   │   ├── table_editor_10.png
│   │   │   │   ├── table_editor_11.png
│   │   │   │   ├── table-editor-01.png
│   │   │   │   ├── table-editor-02.png
│   │   │   │   ├── table-editor-03.png
│   │   │   │   ├── table-editor-04.png
│   │   │   │   ├── table-editor-06.png
│   │   │   │   ├── table-editor-07.png
│   │   │   │   ├── table-editor-08.png
│   │   │   │   ├── table-editor-09.png
│   │   │   │   └── xmlui-rendering-of-tiptap-markdown.png
│   │   │   ├── favicon.ico
│   │   │   ├── files
│   │   │   │   ├── clients.json
│   │   │   │   ├── daily-revenue.json
│   │   │   │   ├── dashboard-stats.json
│   │   │   │   ├── demo.xmlui
│   │   │   │   ├── demo.xmlui.xs
│   │   │   │   ├── downloads
│   │   │   │   │   └── downloads.json
│   │   │   │   ├── for-download
│   │   │   │   │   ├── index-with-api.html
│   │   │   │   │   ├── index.html
│   │   │   │   │   ├── mockApi.js
│   │   │   │   │   ├── start-darwin.sh
│   │   │   │   │   ├── start-linux.sh
│   │   │   │   │   ├── start.bat
│   │   │   │   │   └── xmlui
│   │   │   │   │       └── xmlui-standalone.umd.js
│   │   │   │   ├── getting-started
│   │   │   │   │   ├── cl-tutorial-final.zip
│   │   │   │   │   ├── cl-tutorial.zip
│   │   │   │   │   ├── cl-tutorial2.zip
│   │   │   │   │   ├── cl-tutorial3.zip
│   │   │   │   │   ├── cl-tutorial4.zip
│   │   │   │   │   ├── cl-tutorial5.zip
│   │   │   │   │   ├── cl-tutorial6.zip
│   │   │   │   │   ├── getting-started.zip
│   │   │   │   │   ├── hello-xmlui.zip
│   │   │   │   │   ├── xmlui-empty.zip
│   │   │   │   │   └── xmlui-starter.zip
│   │   │   │   ├── howto
│   │   │   │   │   └── component-icons
│   │   │   │   │       └── up-arrow.svg
│   │   │   │   ├── invoices.json
│   │   │   │   ├── monthly-status.json
│   │   │   │   ├── news-and-reviews.json
│   │   │   │   ├── products.json
│   │   │   │   ├── releases.json
│   │   │   │   ├── tutorials
│   │   │   │   │   ├── datasource
│   │   │   │   │   │   └── api.ts
│   │   │   │   │   └── p2do
│   │   │   │   │       ├── api.ts
│   │   │   │   │       └── todo-logo.svg
│   │   │   │   └── xmlui.json
│   │   │   ├── github.svg
│   │   │   ├── images
│   │   │   │   ├── apiaction-tutorial
│   │   │   │   │   ├── add-success.png
│   │   │   │   │   ├── apiaction-param.png
│   │   │   │   │   ├── change-completed.png
│   │   │   │   │   ├── change-in-progress.png
│   │   │   │   │   ├── confirm-delete.png
│   │   │   │   │   ├── data-error.png
│   │   │   │   │   ├── data-progress.png
│   │   │   │   │   ├── data-success.png
│   │   │   │   │   ├── display-1.png
│   │   │   │   │   ├── item-deleted.png
│   │   │   │   │   ├── item-updated.png
│   │   │   │   │   ├── missing-api-key.png
│   │   │   │   │   ├── new-item-added.png
│   │   │   │   │   └── test-message.png
│   │   │   │   ├── chat-api
│   │   │   │   │   └── domain-model.svg
│   │   │   │   ├── components
│   │   │   │   │   ├── image
│   │   │   │   │   │   └── breakfast.jpg
│   │   │   │   │   ├── markdown
│   │   │   │   │   │   └── colors.png
│   │   │   │   │   └── modal
│   │   │   │   │       ├── deep_link_dialog_1.jpg
│   │   │   │   │       └── deep_link_dialog_2.jpg
│   │   │   │   ├── create-apps
│   │   │   │   │   ├── collapsed-vertical.png
│   │   │   │   │   ├── using-forms-warning-dialog.png
│   │   │   │   │   └── using-forms.png
│   │   │   │   ├── datasource-tutorial
│   │   │   │   │   ├── data-with-header.png
│   │   │   │   │   ├── filtered-data.png
│   │   │   │   │   ├── filtered-items.png
│   │   │   │   │   ├── initial-page-items.png
│   │   │   │   │   ├── list-items.png
│   │   │   │   │   ├── next-page-items.png
│   │   │   │   │   ├── no-data.png
│   │   │   │   │   ├── pagination-1.jpg
│   │   │   │   │   ├── pagination-1.png
│   │   │   │   │   ├── polling-1.png
│   │   │   │   │   ├── refetch-data.png
│   │   │   │   │   ├── slow-loading.png
│   │   │   │   │   ├── test-message.png
│   │   │   │   │   ├── Thumbs.db
│   │   │   │   │   ├── unconventional-data.png
│   │   │   │   │   └── unfiltered-items.png
│   │   │   │   ├── flower.jpg
│   │   │   │   ├── get-started
│   │   │   │   │   ├── add-new-contact.png
│   │   │   │   │   ├── app-modified.png
│   │   │   │   │   ├── app-start.png
│   │   │   │   │   ├── app-with-boxes.png
│   │   │   │   │   ├── app-with-toast.png
│   │   │   │   │   ├── boilerplate-structure.png
│   │   │   │   │   ├── cl-initial.png
│   │   │   │   │   ├── cl-start.png
│   │   │   │   │   ├── contact-counts.png
│   │   │   │   │   ├── contact-dialog-title.png
│   │   │   │   │   ├── contact-dialog.png
│   │   │   │   │   ├── contact-menus.png
│   │   │   │   │   ├── contact-predicates.png
│   │   │   │   │   ├── context-menu.png
│   │   │   │   │   ├── dashboard-numbers.png
│   │   │   │   │   ├── default-contact-list.png
│   │   │   │   │   ├── delete-contact.png
│   │   │   │   │   ├── delete-task.png
│   │   │   │   │   ├── detailed-template.png
│   │   │   │   │   ├── edit-contact-details.png
│   │   │   │   │   ├── edited-contact-saved.png
│   │   │   │   │   ├── empty-sections.png
│   │   │   │   │   ├── filter-completed.png
│   │   │   │   │   ├── fullwidth-desktop.png
│   │   │   │   │   ├── fullwidth-mobile.png
│   │   │   │   │   ├── initial-table.png
│   │   │   │   │   ├── items-and-badges.png
│   │   │   │   │   ├── loading-message.png
│   │   │   │   │   ├── new-contact-button.png
│   │   │   │   │   ├── new-contact-saved.png
│   │   │   │   │   ├── no-empty-sections.png
│   │   │   │   │   ├── personal-todo-initial.png
│   │   │   │   │   ├── piechart.png
│   │   │   │   │   ├── review-today.png
│   │   │   │   │   ├── rudimentary-dashboard.png
│   │   │   │   │   ├── section-collapsed.png
│   │   │   │   │   ├── sectioned-items.png
│   │   │   │   │   ├── sections-ordered.png
│   │   │   │   │   ├── spacex-list-with-links.png
│   │   │   │   │   ├── spacex-list.png
│   │   │   │   │   ├── start-personal-todo-1.png
│   │   │   │   │   ├── submit-new-contact.png
│   │   │   │   │   ├── submit-new-task.png
│   │   │   │   │   ├── syntax-highlighting.png
│   │   │   │   │   ├── table-with-badge.png
│   │   │   │   │   ├── template-with-card.png
│   │   │   │   │   ├── test-emulated-api.png
│   │   │   │   │   ├── Thumbs.db
│   │   │   │   │   ├── todo-logo.png
│   │   │   │   │   └── xmlui-tools.png
│   │   │   │   ├── HelloApp.png
│   │   │   │   ├── HelloApp2.png
│   │   │   │   ├── logos
│   │   │   │   │   ├── xmlui1.svg
│   │   │   │   │   ├── xmlui2.svg
│   │   │   │   │   ├── xmlui3.svg
│   │   │   │   │   ├── xmlui4.svg
│   │   │   │   │   ├── xmlui5.svg
│   │   │   │   │   ├── xmlui6.svg
│   │   │   │   │   └── xmlui7.svg
│   │   │   │   ├── pdf
│   │   │   │   │   └── dummy-pdf.jpg
│   │   │   │   ├── rendering-engine
│   │   │   │   │   ├── AppEngine-flow.svg
│   │   │   │   │   ├── Component.svg
│   │   │   │   │   ├── CompoundComponent.svg
│   │   │   │   │   ├── RootComponent.svg
│   │   │   │   │   └── tree-with-containers.svg
│   │   │   │   ├── reviewers-guide
│   │   │   │   │   ├── AppEngine-flow.svg
│   │   │   │   │   └── incbutton-in-action.png
│   │   │   │   ├── tools
│   │   │   │   │   └── boilerplate-structure.png
│   │   │   │   ├── try.svg
│   │   │   │   ├── tutorial
│   │   │   │   │   ├── app-chat-history.png
│   │   │   │   │   ├── app-content-placeholder.png
│   │   │   │   │   ├── app-header-and-content.png
│   │   │   │   │   ├── app-links-channel-selected.png
│   │   │   │   │   ├── app-links-click.png
│   │   │   │   │   ├── app-navigation.png
│   │   │   │   │   ├── finished-ex01.png
│   │   │   │   │   ├── finished-ex02.png
│   │   │   │   │   ├── hello.png
│   │   │   │   │   ├── splash-screen-advanced.png
│   │   │   │   │   ├── splash-screen-after-click.png
│   │   │   │   │   ├── splash-screen-centered.png
│   │   │   │   │   ├── splash-screen-events.png
│   │   │   │   │   ├── splash-screen-expression.png
│   │   │   │   │   ├── splash-screen-reuse-after.png
│   │   │   │   │   ├── splash-screen-reuse-before.png
│   │   │   │   │   └── splash-screen.png
│   │   │   │   └── tutorial-01.png
│   │   │   ├── llms.txt
│   │   │   ├── logo-dark.svg
│   │   │   ├── logo.svg
│   │   │   ├── pg-popout.svg
│   │   │   └── xmlui-logo.svg
│   │   ├── serve.json
│   │   └── web.config
│   ├── scripts
│   │   ├── download-latest-xmlui.js
│   │   ├── generate-rss.js
│   │   ├── get-releases.js
│   │   └── utils.js
│   ├── src
│   │   ├── components
│   │   │   ├── BlogOverview.xmlui
│   │   │   ├── BlogPage.xmlui
│   │   │   ├── Boxes.xmlui
│   │   │   ├── Breadcrumb.xmlui
│   │   │   ├── ChangeLog.xmlui
│   │   │   ├── ColorPalette.xmlui
│   │   │   ├── DocumentLinks.xmlui
│   │   │   ├── DocumentPage.xmlui
│   │   │   ├── DocumentPageNoTOC.xmlui
│   │   │   ├── Icons.xmlui
│   │   │   ├── IncButton.xmlui
│   │   │   ├── IncButton2.xmlui
│   │   │   ├── NameValue.xmlui
│   │   │   ├── PageNotFound.xmlui
│   │   │   ├── PaletteItem.xmlui
│   │   │   ├── Palettes.xmlui
│   │   │   ├── SectionHeader.xmlui
│   │   │   ├── TBD.xmlui
│   │   │   ├── Test.xmlui
│   │   │   ├── ThemesIntro.xmlui
│   │   │   ├── ThousandThemes.xmlui
│   │   │   ├── TubeStops.xmlui
│   │   │   ├── TubeStops.xmlui.xs
│   │   │   └── TwoColumnCode.xmlui
│   │   ├── config.ts
│   │   ├── Main.xmlui
│   │   └── themes
│   │       ├── docs-theme.ts
│   │       ├── earthtone.ts
│   │       ├── xmlui-gray-on-default.ts
│   │       ├── xmlui-green-on-default.ts
│   │       └── xmlui-orange-on-default.ts
│   └── tsconfig.json
├── LICENSE
├── package-lock.json
├── package.json
├── packages
│   ├── tsconfig.json
│   ├── xmlui-animations
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── Animation.tsx
│   │       ├── AnimationNative.tsx
│   │       ├── FadeAnimation.tsx
│   │       ├── FadeInAnimation.tsx
│   │       ├── FadeOutAnimation.tsx
│   │       ├── index.tsx
│   │       ├── ScaleAnimation.tsx
│   │       └── SlideInAnimation.tsx
│   ├── xmlui-devtools
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   ├── src
│   │   │   ├── devtools
│   │   │   │   ├── DevTools.tsx
│   │   │   │   ├── DevToolsNative.module.scss
│   │   │   │   ├── DevToolsNative.tsx
│   │   │   │   ├── ModalDialog.module.scss
│   │   │   │   ├── ModalDialog.tsx
│   │   │   │   ├── ModalVisibilityContext.tsx
│   │   │   │   ├── Tooltip.module.scss
│   │   │   │   ├── Tooltip.tsx
│   │   │   │   └── utils.ts
│   │   │   ├── editor
│   │   │   │   └── Editor.tsx
│   │   │   └── index.tsx
│   │   └── vite.config-overrides.ts
│   ├── xmlui-hello-world
│   │   ├── .gitignore
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── HelloWorld.module.scss
│   │       ├── HelloWorld.tsx
│   │       ├── HelloWorldNative.tsx
│   │       └── index.tsx
│   ├── xmlui-os-frames
│   │   ├── .gitignore
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── index.tsx
│   │       ├── IPhoneFrame.module.scss
│   │       ├── IPhoneFrame.tsx
│   │       ├── MacOSAppFrame.module.scss
│   │       ├── MacOSAppFrame.tsx
│   │       ├── WindowsAppFrame.module.scss
│   │       └── WindowsAppFrame.tsx
│   ├── xmlui-pdf
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── demo
│   │   │   ├── components
│   │   │   │   └── Pdf.xmlui
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── index.tsx
│   │       ├── LazyPdfNative.tsx
│   │       ├── Pdf.module.scss
│   │       └── Pdf.tsx
│   ├── xmlui-playground
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── hooks
│   │       │   ├── usePlayground.ts
│   │       │   └── useToast.ts
│   │       ├── index.tsx
│   │       ├── playground
│   │       │   ├── Box.module.scss
│   │       │   ├── Box.tsx
│   │       │   ├── CodeSelector.module.scss
│   │       │   ├── CodeSelector.tsx
│   │       │   ├── ConfirmationDialog.module.scss
│   │       │   ├── ConfirmationDialog.tsx
│   │       │   ├── Editor.tsx
│   │       │   ├── Header.module.scss
│   │       │   ├── Header.tsx
│   │       │   ├── Playground.tsx
│   │       │   ├── PlaygroundContent.module.scss
│   │       │   ├── PlaygroundContent.tsx
│   │       │   ├── PlaygroundNative.module.scss
│   │       │   ├── PlaygroundNative.tsx
│   │       │   ├── Preview.tsx
│   │       │   ├── StandalonePlayground.tsx
│   │       │   ├── StandalonePlaygroundNative.module.scss
│   │       │   ├── StandalonePlaygroundNative.tsx
│   │       │   ├── ThemeSwitcher.module.scss
│   │       │   ├── ThemeSwitcher.tsx
│   │       │   └── utils.ts
│   │       ├── providers
│   │       │   ├── Toast.module.scss
│   │       │   └── ToastProvider.tsx
│   │       ├── state
│   │       │   └── store.ts
│   │       ├── themes
│   │       │   └── theme.ts
│   │       └── utils
│   │           └── helpers.ts
│   ├── xmlui-search
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── index.tsx
│   │       ├── Search.module.scss
│   │       └── Search.tsx
│   ├── xmlui-spreadsheet
│   │   ├── .gitignore
│   │   ├── demo
│   │   │   └── Main.xmlui
│   │   ├── index.html
│   │   ├── index.ts
│   │   ├── meta
│   │   │   └── componentsMetadata.ts
│   │   ├── package.json
│   │   └── src
│   │       ├── index.tsx
│   │       ├── Spreadsheet.tsx
│   │       └── SpreadsheetNative.tsx
│   └── xmlui-website-blocks
│       ├── .gitignore
│       ├── CHANGELOG.md
│       ├── demo
│       │   ├── components
│       │   │   ├── HeroBackgroundBreakoutPage.xmlui
│       │   │   ├── HeroBackgroundsPage.xmlui
│       │   │   ├── HeroContentsPage.xmlui
│       │   │   ├── HeroTextAlignPage.xmlui
│       │   │   ├── HeroTextPage.xmlui
│       │   │   └── HeroTonesPage.xmlui
│       │   ├── Main.xmlui
│       │   └── themes
│       │       └── default.ts
│       ├── index.html
│       ├── index.ts
│       ├── meta
│       │   └── componentsMetadata.ts
│       ├── package.json
│       ├── public
│       │   └── resources
│       │       ├── building.jpg
│       │       └── xmlui-logo.svg
│       └── src
│           ├── Carousel
│           │   ├── Carousel.module.scss
│           │   ├── Carousel.tsx
│           │   ├── CarouselContext.tsx
│           │   └── CarouselNative.tsx
│           ├── FancyButton
│           │   ├── FancyButton.module.scss
│           │   ├── FancyButton.tsx
│           │   └── FancyButton.xmlui
│           ├── Hello
│           │   ├── Hello.tsx
│           │   ├── Hello.xmlui
│           │   └── Hello.xmlui.xs
│           ├── HeroSection
│           │   ├── HeroSection.module.scss
│           │   ├── HeroSection.spec.ts
│           │   ├── HeroSection.tsx
│           │   └── HeroSectionNative.tsx
│           ├── index.tsx
│           ├── ScrollToTop
│           │   ├── ScrollToTop.module.scss
│           │   ├── ScrollToTop.tsx
│           │   └── ScrollToTopNative.tsx
│           └── vite-env.d.ts
├── playwright.config.ts
├── README.md
├── tools
│   ├── codefence
│   │   └── xmlui-code-fence-docs.md
│   ├── create-app
│   │   ├── .gitignore
│   │   ├── CHANGELOG.md
│   │   ├── create-app.ts
│   │   ├── helpers
│   │   │   ├── copy.ts
│   │   │   ├── get-pkg-manager.ts
│   │   │   ├── git.ts
│   │   │   ├── install.ts
│   │   │   ├── is-folder-empty.ts
│   │   │   ├── is-writeable.ts
│   │   │   ├── make-dir.ts
│   │   │   └── validate-pkg.ts
│   │   ├── index.ts
│   │   ├── package.json
│   │   ├── templates
│   │   │   ├── default
│   │   │   │   └── ts
│   │   │   │       ├── gitignore
│   │   │   │       ├── index.html
│   │   │   │       ├── index.ts
│   │   │   │       ├── public
│   │   │   │       │   ├── mockServiceWorker.js
│   │   │   │       │   ├── resources
│   │   │   │       │   │   ├── favicon.ico
│   │   │   │       │   │   └── xmlui-logo.svg
│   │   │   │       │   └── serve.json
│   │   │   │       └── src
│   │   │   │           ├── components
│   │   │   │           │   ├── ApiAware.xmlui
│   │   │   │           │   ├── Home.xmlui
│   │   │   │           │   ├── IncButton.xmlui
│   │   │   │           │   └── PagePanel.xmlui
│   │   │   │           ├── config.ts
│   │   │   │           └── Main.xmlui
│   │   │   ├── index.ts
│   │   │   └── types.ts
│   │   └── tsconfig.json
│   ├── create-xmlui-hello-world
│   │   ├── index.js
│   │   └── package.json
│   └── vscode
│       ├── .gitignore
│       ├── .vscode
│       │   ├── launch.json
│       │   └── tasks.json
│       ├── .vscodeignore
│       ├── build.sh
│       ├── CHANGELOG.md
│       ├── esbuild.js
│       ├── eslint.config.mjs
│       ├── formatter-docs.md
│       ├── generate-test-sample.sh
│       ├── LICENSE.md
│       ├── package-lock.json
│       ├── package.json
│       ├── README.md
│       ├── resources
│       │   ├── xmlui-logo.png
│       │   └── xmlui-markup-syntax-highlighting.png
│       ├── src
│       │   ├── extension.ts
│       │   └── server.ts
│       ├── syntaxes
│       │   └── xmlui.tmLanguage.json
│       ├── test-samples
│       │   └── sample.xmlui
│       ├── tsconfig.json
│       └── tsconfig.tsbuildinfo
├── turbo.json
└── xmlui
    ├── .gitignore
    ├── bin
    │   ├── bootstrap.cjs
    │   ├── bootstrap.js
    │   ├── build-lib.ts
    │   ├── build.ts
    │   ├── index.ts
    │   ├── preview.ts
    │   ├── start.ts
    │   ├── vite-xmlui-plugin.ts
    │   └── viteConfig.ts
    ├── CHANGELOG.md
    ├── conventions
    │   ├── component-qa-checklist.md
    │   ├── copilot-conventions.md
    │   ├── create-xmlui-components.md
    │   ├── mermaid.md
    │   ├── testing-conventions.md
    │   └── xmlui-in-a-nutshell.md
    ├── dev-docs
    │   ├── accessibility.md
    │   ├── build-system.md
    │   ├── build-xmlui.md
    │   ├── component-behaviors.md
    │   ├── component-metadata.md
    │   ├── components-with-options.md
    │   ├── containers.md
    │   ├── data-operations.md
    │   ├── glossary.md
    │   ├── index.md
    │   ├── next
    │   │   ├── component-dev-guide.md
    │   │   ├── configuration-management-enhancement-summary.md
    │   │   ├── documentation-scripts-refactoring-complete-summary.md
    │   │   ├── documentation-scripts-refactoring-plan.md
    │   │   ├── duplicate-pattern-extraction-summary.md
    │   │   ├── error-handling-standardization-summary.md
    │   │   ├── generating-component-reference.md
    │   │   ├── index.md
    │   │   ├── logging-consistency-implementation-summary.md
    │   │   ├── project-build.md
    │   │   ├── project-structure.md
    │   │   ├── theme-context.md
    │   │   ├── tiptap-design-considerations.md
    │   │   ├── working-with-code.md
    │   │   ├── xmlui-runtime-architecture
    │   │   └── xmlui-wcag-accessibility-report.md
    │   ├── react-fundamentals.md
    │   ├── release-method.md
    │   ├── standalone-app.md
    │   ├── theme-variables-refactoring.md
    │   ├── ud-components.md
    │   └── xmlui-repo.md
    ├── package.json
    ├── scripts
    │   ├── coverage-only.js
    │   ├── e2e-test-summary.js
    │   ├── extract-component-metadata.js
    │   ├── generate-docs
    │   │   ├── build-downloads-map.mjs
    │   │   ├── build-pages-map.mjs
    │   │   ├── components-config.json
    │   │   ├── configuration-management.mjs
    │   │   ├── constants.mjs
    │   │   ├── create-theme-files.mjs
    │   │   ├── DocsGenerator.mjs
    │   │   ├── error-handling.mjs
    │   │   ├── extensions-config.json
    │   │   ├── folders.mjs
    │   │   ├── generate-summary-files.mjs
    │   │   ├── get-docs.mjs
    │   │   ├── input-handler.mjs
    │   │   ├── logger.mjs
    │   │   ├── logging-standards.mjs
    │   │   ├── MetadataProcessor.mjs
    │   │   ├── pattern-utilities.mjs
    │   │   └── utils.mjs
    │   ├── generate-metadata-markdown.js
    │   ├── get-langserver-metadata.js
    │   ├── inline-links.mjs
    │   └── README-e2e-summary.md
    ├── src
    │   ├── abstractions
    │   │   ├── _conventions.md
    │   │   ├── ActionDefs.ts
    │   │   ├── AppContextDefs.ts
    │   │   ├── ComponentDefs.ts
    │   │   ├── ContainerDefs.ts
    │   │   ├── ExtensionDefs.ts
    │   │   ├── FunctionDefs.ts
    │   │   ├── RendererDefs.ts
    │   │   ├── scripting
    │   │   │   ├── BlockScope.ts
    │   │   │   ├── Compilation.ts
    │   │   │   ├── LogicalThread.ts
    │   │   │   ├── LoopScope.ts
    │   │   │   ├── modules.ts
    │   │   │   ├── ScriptParserError.ts
    │   │   │   ├── Token.ts
    │   │   │   ├── TryScope.ts
    │   │   │   └── TryScopeExp.ts
    │   │   └── ThemingDefs.ts
    │   ├── components
    │   │   ├── _conventions.md
    │   │   ├── abstractions.ts
    │   │   ├── Accordion
    │   │   │   ├── Accordion.md
    │   │   │   ├── Accordion.module.scss
    │   │   │   ├── Accordion.spec.ts
    │   │   │   ├── Accordion.tsx
    │   │   │   ├── AccordionContext.tsx
    │   │   │   ├── AccordionItem.tsx
    │   │   │   ├── AccordionItemNative.tsx
    │   │   │   └── AccordionNative.tsx
    │   │   ├── Animation
    │   │   │   └── AnimationNative.tsx
    │   │   ├── APICall
    │   │   │   ├── APICall.md
    │   │   │   ├── APICall.spec.ts
    │   │   │   ├── APICall.tsx
    │   │   │   └── APICallNative.tsx
    │   │   ├── App
    │   │   │   ├── App.md
    │   │   │   ├── App.module.scss
    │   │   │   ├── App.spec.ts
    │   │   │   ├── App.tsx
    │   │   │   ├── AppLayoutContext.ts
    │   │   │   ├── AppNative.tsx
    │   │   │   ├── AppStateContext.ts
    │   │   │   ├── doc-resources
    │   │   │   │   ├── condensed-sticky.xmlui
    │   │   │   │   ├── condensed.xmlui
    │   │   │   │   ├── horizontal-sticky.xmlui
    │   │   │   │   ├── horizontal.xmlui
    │   │   │   │   ├── vertical-full-header.xmlui
    │   │   │   │   ├── vertical-sticky.xmlui
    │   │   │   │   └── vertical.xmlui
    │   │   │   ├── IndexerContext.ts
    │   │   │   ├── LinkInfoContext.ts
    │   │   │   ├── SearchContext.tsx
    │   │   │   ├── Sheet.module.scss
    │   │   │   └── Sheet.tsx
    │   │   ├── AppHeader
    │   │   │   ├── AppHeader.md
    │   │   │   ├── AppHeader.module.scss
    │   │   │   ├── AppHeader.spec.ts
    │   │   │   ├── AppHeader.tsx
    │   │   │   └── AppHeaderNative.tsx
    │   │   ├── AppState
    │   │   │   ├── AppState.md
    │   │   │   ├── AppState.spec.ts
    │   │   │   ├── AppState.tsx
    │   │   │   └── AppStateNative.tsx
    │   │   ├── AutoComplete
    │   │   │   ├── AutoComplete.md
    │   │   │   ├── AutoComplete.module.scss
    │   │   │   ├── AutoComplete.spec.ts
    │   │   │   ├── AutoComplete.tsx
    │   │   │   ├── AutoCompleteContext.tsx
    │   │   │   └── AutoCompleteNative.tsx
    │   │   ├── Avatar
    │   │   │   ├── Avatar.md
    │   │   │   ├── Avatar.module.scss
    │   │   │   ├── Avatar.spec.ts
    │   │   │   ├── Avatar.tsx
    │   │   │   └── AvatarNative.tsx
    │   │   ├── Backdrop
    │   │   │   ├── Backdrop.md
    │   │   │   ├── Backdrop.module.scss
    │   │   │   ├── Backdrop.spec.ts
    │   │   │   ├── Backdrop.tsx
    │   │   │   └── BackdropNative.tsx
    │   │   ├── Badge
    │   │   │   ├── Badge.md
    │   │   │   ├── Badge.module.scss
    │   │   │   ├── Badge.spec.ts
    │   │   │   ├── Badge.tsx
    │   │   │   └── BadgeNative.tsx
    │   │   ├── Bookmark
    │   │   │   ├── Bookmark.md
    │   │   │   ├── Bookmark.module.scss
    │   │   │   ├── Bookmark.spec.ts
    │   │   │   ├── Bookmark.tsx
    │   │   │   └── BookmarkNative.tsx
    │   │   ├── Breakout
    │   │   │   ├── Breakout.module.scss
    │   │   │   ├── Breakout.spec.ts
    │   │   │   ├── Breakout.tsx
    │   │   │   └── BreakoutNative.tsx
    │   │   ├── Button
    │   │   │   ├── Button-style.spec.ts
    │   │   │   ├── Button.md
    │   │   │   ├── Button.module.scss
    │   │   │   ├── Button.spec.ts
    │   │   │   ├── Button.tsx
    │   │   │   └── ButtonNative.tsx
    │   │   ├── Card
    │   │   │   ├── Card.md
    │   │   │   ├── Card.module.scss
    │   │   │   ├── Card.spec.ts
    │   │   │   ├── Card.tsx
    │   │   │   └── CardNative.tsx
    │   │   ├── Carousel
    │   │   │   ├── Carousel.md
    │   │   │   ├── Carousel.module.scss
    │   │   │   ├── Carousel.spec.ts
    │   │   │   ├── Carousel.tsx
    │   │   │   ├── CarouselContext.tsx
    │   │   │   ├── CarouselItem.tsx
    │   │   │   ├── CarouselItemNative.tsx
    │   │   │   └── CarouselNative.tsx
    │   │   ├── ChangeListener
    │   │   │   ├── ChangeListener.md
    │   │   │   ├── ChangeListener.spec.ts
    │   │   │   ├── ChangeListener.tsx
    │   │   │   └── ChangeListenerNative.tsx
    │   │   ├── chart-color-schemes.ts
    │   │   ├── Charts
    │   │   │   ├── AreaChart
    │   │   │   │   ├── AreaChart.md
    │   │   │   │   ├── AreaChart.spec.ts
    │   │   │   │   ├── AreaChart.tsx
    │   │   │   │   └── AreaChartNative.tsx
    │   │   │   ├── BarChart
    │   │   │   │   ├── BarChart.md
    │   │   │   │   ├── BarChart.module.scss
    │   │   │   │   ├── BarChart.spec.ts
    │   │   │   │   ├── BarChart.tsx
    │   │   │   │   └── BarChartNative.tsx
    │   │   │   ├── DonutChart
    │   │   │   │   ├── DonutChart.spec.ts
    │   │   │   │   └── DonutChart.tsx
    │   │   │   ├── LabelList
    │   │   │   │   ├── LabelList.module.scss
    │   │   │   │   ├── LabelList.spec.ts
    │   │   │   │   ├── LabelList.tsx
    │   │   │   │   └── LabelListNative.tsx
    │   │   │   ├── Legend
    │   │   │   │   ├── Legend.spec.ts
    │   │   │   │   ├── Legend.tsx
    │   │   │   │   └── LegendNative.tsx
    │   │   │   ├── LineChart
    │   │   │   │   ├── LineChart.md
    │   │   │   │   ├── LineChart.module.scss
    │   │   │   │   ├── LineChart.spec.ts
    │   │   │   │   ├── LineChart.tsx
    │   │   │   │   └── LineChartNative.tsx
    │   │   │   ├── PieChart
    │   │   │   │   ├── PieChart.md
    │   │   │   │   ├── PieChart.spec.ts
    │   │   │   │   ├── PieChart.tsx
    │   │   │   │   ├── PieChartNative.module.scss
    │   │   │   │   └── PieChartNative.tsx
    │   │   │   ├── RadarChart
    │   │   │   │   ├── RadarChart.md
    │   │   │   │   ├── RadarChart.spec.ts
    │   │   │   │   ├── RadarChart.tsx
    │   │   │   │   └── RadarChartNative.tsx
    │   │   │   ├── Tooltip
    │   │   │   │   ├── TooltipContent.module.scss
    │   │   │   │   ├── TooltipContent.spec.ts
    │   │   │   │   └── TooltipContent.tsx
    │   │   │   └── utils
    │   │   │       ├── abstractions.ts
    │   │   │       └── ChartProvider.tsx
    │   │   ├── Checkbox
    │   │   │   ├── Checkbox.md
    │   │   │   ├── Checkbox.spec.ts
    │   │   │   └── Checkbox.tsx
    │   │   ├── CodeBlock
    │   │   │   ├── CodeBlock.module.scss
    │   │   │   ├── CodeBlock.spec.ts
    │   │   │   ├── CodeBlock.tsx
    │   │   │   ├── CodeBlockNative.tsx
    │   │   │   └── highlight-code.ts
    │   │   ├── collectedComponentMetadata.ts
    │   │   ├── ColorPicker
    │   │   │   ├── ColorPicker.md
    │   │   │   ├── ColorPicker.module.scss
    │   │   │   ├── ColorPicker.spec.ts
    │   │   │   ├── ColorPicker.tsx
    │   │   │   └── ColorPickerNative.tsx
    │   │   ├── Column
    │   │   │   ├── Column.md
    │   │   │   ├── Column.tsx
    │   │   │   ├── ColumnNative.tsx
    │   │   │   ├── doc-resources
    │   │   │   │   └── list-component-data.js
    │   │   │   └── TableContext.tsx
    │   │   ├── component-utils.ts
    │   │   ├── ComponentProvider.tsx
    │   │   ├── ComponentRegistryContext.tsx
    │   │   ├── container-helpers.tsx
    │   │   ├── ContentSeparator
    │   │   │   ├── ContentSeparator.md
    │   │   │   ├── ContentSeparator.module.scss
    │   │   │   ├── ContentSeparator.spec.ts
    │   │   │   ├── ContentSeparator.tsx
    │   │   │   └── ContentSeparatorNative.tsx
    │   │   ├── DataSource
    │   │   │   ├── DataSource.md
    │   │   │   └── DataSource.tsx
    │   │   ├── DateInput
    │   │   │   ├── DateInput.md
    │   │   │   ├── DateInput.module.scss
    │   │   │   ├── DateInput.spec.ts
    │   │   │   ├── DateInput.tsx
    │   │   │   └── DateInputNative.tsx
    │   │   ├── DatePicker
    │   │   │   ├── DatePicker.md
    │   │   │   ├── DatePicker.module.scss
    │   │   │   ├── DatePicker.spec.ts
    │   │   │   ├── DatePicker.tsx
    │   │   │   └── DatePickerNative.tsx
    │   │   ├── DropdownMenu
    │   │   │   ├── DropdownMenu.md
    │   │   │   ├── DropdownMenu.module.scss
    │   │   │   ├── DropdownMenu.spec.ts
    │   │   │   ├── DropdownMenu.tsx
    │   │   │   ├── DropdownMenuNative.tsx
    │   │   │   ├── MenuItem.md
    │   │   │   └── SubMenuItem.md
    │   │   ├── EmojiSelector
    │   │   │   ├── EmojiSelector.md
    │   │   │   ├── EmojiSelector.spec.ts
    │   │   │   ├── EmojiSelector.tsx
    │   │   │   └── EmojiSelectorNative.tsx
    │   │   ├── ExpandableItem
    │   │   │   ├── ExpandableItem.module.scss
    │   │   │   ├── ExpandableItem.spec.ts
    │   │   │   ├── ExpandableItem.tsx
    │   │   │   └── ExpandableItemNative.tsx
    │   │   ├── FileInput
    │   │   │   ├── FileInput.md
    │   │   │   ├── FileInput.module.scss
    │   │   │   ├── FileInput.spec.ts
    │   │   │   ├── FileInput.tsx
    │   │   │   └── FileInputNative.tsx
    │   │   ├── FileUploadDropZone
    │   │   │   ├── FileUploadDropZone.md
    │   │   │   ├── FileUploadDropZone.module.scss
    │   │   │   ├── FileUploadDropZone.spec.ts
    │   │   │   ├── FileUploadDropZone.tsx
    │   │   │   └── FileUploadDropZoneNative.tsx
    │   │   ├── FlowLayout
    │   │   │   ├── FlowLayout.md
    │   │   │   ├── FlowLayout.module.scss
    │   │   │   ├── FlowLayout.spec.ts
    │   │   │   ├── FlowLayout.spec.ts-snapshots
    │   │   │   │   └── Edge-cases-boxShadow-is-not-clipped-1-non-smoke-darwin.png
    │   │   │   ├── FlowLayout.tsx
    │   │   │   └── FlowLayoutNative.tsx
    │   │   ├── Footer
    │   │   │   ├── Footer.md
    │   │   │   ├── Footer.module.scss
    │   │   │   ├── Footer.spec.ts
    │   │   │   ├── Footer.tsx
    │   │   │   └── FooterNative.tsx
    │   │   ├── Form
    │   │   │   ├── Form.md
    │   │   │   ├── Form.module.scss
    │   │   │   ├── Form.spec.ts
    │   │   │   ├── Form.tsx
    │   │   │   ├── formActions.ts
    │   │   │   ├── FormContext.ts
    │   │   │   └── FormNative.tsx
    │   │   ├── FormItem
    │   │   │   ├── FormItem.md
    │   │   │   ├── FormItem.module.scss
    │   │   │   ├── FormItem.spec.ts
    │   │   │   ├── FormItem.tsx
    │   │   │   ├── FormItemNative.tsx
    │   │   │   ├── HelperText.module.scss
    │   │   │   ├── HelperText.tsx
    │   │   │   ├── ItemWithLabel.tsx
    │   │   │   └── Validations.ts
    │   │   ├── FormSection
    │   │   │   ├── FormSection.md
    │   │   │   ├── FormSection.ts
    │   │   │   └── FormSection.xmlui
    │   │   ├── Fragment
    │   │   │   ├── Fragment.spec.ts
    │   │   │   └── Fragment.tsx
    │   │   ├── Heading
    │   │   │   ├── abstractions.ts
    │   │   │   ├── H1.md
    │   │   │   ├── H1.spec.ts
    │   │   │   ├── H2.md
    │   │   │   ├── H2.spec.ts
    │   │   │   ├── H3.md
    │   │   │   ├── H3.spec.ts
    │   │   │   ├── H4.md
    │   │   │   ├── H4.spec.ts
    │   │   │   ├── H5.md
    │   │   │   ├── H5.spec.ts
    │   │   │   ├── H6.md
    │   │   │   ├── H6.spec.ts
    │   │   │   ├── Heading.md
    │   │   │   ├── Heading.module.scss
    │   │   │   ├── Heading.spec.ts
    │   │   │   ├── Heading.tsx
    │   │   │   └── HeadingNative.tsx
    │   │   ├── HoverCard
    │   │   │   ├── HoverCard.tsx
    │   │   │   └── HovercardNative.tsx
    │   │   ├── HtmlTags
    │   │   │   ├── HtmlTags.module.scss
    │   │   │   ├── HtmlTags.spec.ts
    │   │   │   └── HtmlTags.tsx
    │   │   ├── Icon
    │   │   │   ├── AdmonitionDanger.tsx
    │   │   │   ├── AdmonitionInfo.tsx
    │   │   │   ├── AdmonitionNote.tsx
    │   │   │   ├── AdmonitionTip.tsx
    │   │   │   ├── AdmonitionWarning.tsx
    │   │   │   ├── ApiIcon.tsx
    │   │   │   ├── ArrowDropDown.module.scss
    │   │   │   ├── ArrowDropDown.tsx
    │   │   │   ├── ArrowDropUp.module.scss
    │   │   │   ├── ArrowDropUp.tsx
    │   │   │   ├── ArrowLeft.module.scss
    │   │   │   ├── ArrowLeft.tsx
    │   │   │   ├── ArrowRight.module.scss
    │   │   │   ├── ArrowRight.tsx
    │   │   │   ├── Attach.tsx
    │   │   │   ├── Binding.module.scss
    │   │   │   ├── Binding.tsx
    │   │   │   ├── BoardIcon.tsx
    │   │   │   ├── BoxIcon.tsx
    │   │   │   ├── CheckIcon.tsx
    │   │   │   ├── ChevronDownIcon.tsx
    │   │   │   ├── ChevronLeft.tsx
    │   │   │   ├── ChevronRight.tsx
    │   │   │   ├── ChevronUpIcon.tsx
    │   │   │   ├── CodeFileIcon.tsx
    │   │   │   ├── CodeSandbox.tsx
    │   │   │   ├── CompactListIcon.tsx
    │   │   │   ├── ContentCopyIcon.tsx
    │   │   │   ├── DarkToLightIcon.tsx
    │   │   │   ├── DatabaseIcon.module.scss
    │   │   │   ├── DatabaseIcon.tsx
    │   │   │   ├── DocFileIcon.tsx
    │   │   │   ├── DocIcon.tsx
    │   │   │   ├── DotMenuHorizontalIcon.tsx
    │   │   │   ├── DotMenuIcon.tsx
    │   │   │   ├── EmailIcon.tsx
    │   │   │   ├── EmptyFolderIcon.tsx
    │   │   │   ├── ErrorIcon.tsx
    │   │   │   ├── ExpressionIcon.tsx
    │   │   │   ├── FillPlusCricleIcon.tsx
    │   │   │   ├── FilterIcon.tsx
    │   │   │   ├── FolderIcon.tsx
    │   │   │   ├── GlobeIcon.tsx
    │   │   │   ├── HomeIcon.tsx
    │   │   │   ├── HyperLinkIcon.tsx
    │   │   │   ├── Icon.md
    │   │   │   ├── Icon.module.scss
    │   │   │   ├── Icon.spec.ts
    │   │   │   ├── Icon.tsx
    │   │   │   ├── IconNative.tsx
    │   │   │   ├── ImageFileIcon.tsx
    │   │   │   ├── Inspect.tsx
    │   │   │   ├── LightToDark.tsx
    │   │   │   ├── LinkIcon.tsx
    │   │   │   ├── ListIcon.tsx
    │   │   │   ├── LooseListIcon.tsx
    │   │   │   ├── MoonIcon.tsx
    │   │   │   ├── MoreOptionsIcon.tsx
    │   │   │   ├── NoSortIcon.tsx
    │   │   │   ├── PDFIcon.tsx
    │   │   │   ├── PenIcon.tsx
    │   │   │   ├── PhoneIcon.tsx
    │   │   │   ├── PhotoIcon.tsx
    │   │   │   ├── PlusIcon.tsx
    │   │   │   ├── SearchIcon.tsx
    │   │   │   ├── ShareIcon.tsx
    │   │   │   ├── SortAscendingIcon.tsx
    │   │   │   ├── SortDescendingIcon.tsx
    │   │   │   ├── StarsIcon.tsx
    │   │   │   ├── SunIcon.tsx
    │   │   │   ├── svg
    │   │   │   │   ├── admonition_danger.svg
    │   │   │   │   ├── admonition_info.svg
    │   │   │   │   ├── admonition_note.svg
    │   │   │   │   ├── admonition_tip.svg
    │   │   │   │   ├── admonition_warning.svg
    │   │   │   │   ├── api.svg
    │   │   │   │   ├── arrow-dropdown.svg
    │   │   │   │   ├── arrow-left.svg
    │   │   │   │   ├── arrow-right.svg
    │   │   │   │   ├── arrow-up.svg
    │   │   │   │   ├── attach.svg
    │   │   │   │   ├── binding.svg
    │   │   │   │   ├── box.svg
    │   │   │   │   ├── bulb.svg
    │   │   │   │   ├── code-file.svg
    │   │   │   │   ├── code-sandbox.svg
    │   │   │   │   ├── dark_to_light.svg
    │   │   │   │   ├── database.svg
    │   │   │   │   ├── doc.svg
    │   │   │   │   ├── empty-folder.svg
    │   │   │   │   ├── expression.svg
    │   │   │   │   ├── eye-closed.svg
    │   │   │   │   ├── eye-dark.svg
    │   │   │   │   ├── eye.svg
    │   │   │   │   ├── file-text.svg
    │   │   │   │   ├── filter.svg
    │   │   │   │   ├── folder.svg
    │   │   │   │   ├── img.svg
    │   │   │   │   ├── inspect.svg
    │   │   │   │   ├── light_to_dark.svg
    │   │   │   │   ├── moon.svg
    │   │   │   │   ├── pdf.svg
    │   │   │   │   ├── photo.svg
    │   │   │   │   ├── share.svg
    │   │   │   │   ├── stars.svg
    │   │   │   │   ├── sun.svg
    │   │   │   │   ├── trending-down.svg
    │   │   │   │   ├── trending-level.svg
    │   │   │   │   ├── trending-up.svg
    │   │   │   │   ├── txt.svg
    │   │   │   │   ├── unknown-file.svg
    │   │   │   │   ├── unlink.svg
    │   │   │   │   └── xls.svg
    │   │   │   ├── TableDeleteColumnIcon.tsx
    │   │   │   ├── TableDeleteRowIcon.tsx
    │   │   │   ├── TableInsertColumnIcon.tsx
    │   │   │   ├── TableInsertRowIcon.tsx
    │   │   │   ├── TrashIcon.tsx
    │   │   │   ├── TrendingDownIcon.tsx
    │   │   │   ├── TrendingLevelIcon.tsx
    │   │   │   ├── TrendingUpIcon.tsx
    │   │   │   ├── TxtIcon.tsx
    │   │   │   ├── UnknownFileIcon.tsx
    │   │   │   ├── UnlinkIcon.tsx
    │   │   │   ├── UserIcon.tsx
    │   │   │   ├── WarningIcon.tsx
    │   │   │   └── XlsIcon.tsx
    │   │   ├── IconProvider.tsx
    │   │   ├── IconRegistryContext.tsx
    │   │   ├── IFrame
    │   │   │   ├── IFrame.md
    │   │   │   ├── IFrame.module.scss
    │   │   │   ├── IFrame.spec.ts
    │   │   │   ├── IFrame.tsx
    │   │   │   └── IFrameNative.tsx
    │   │   ├── Image
    │   │   │   ├── Image.md
    │   │   │   ├── Image.module.scss
    │   │   │   ├── Image.spec.ts
    │   │   │   ├── Image.tsx
    │   │   │   └── ImageNative.tsx
    │   │   ├── Input
    │   │   │   ├── index.ts
    │   │   │   ├── InputAdornment.module.scss
    │   │   │   ├── InputAdornment.tsx
    │   │   │   ├── InputDivider.module.scss
    │   │   │   ├── InputDivider.tsx
    │   │   │   ├── InputLabel.module.scss
    │   │   │   ├── InputLabel.tsx
    │   │   │   ├── PartialInput.module.scss
    │   │   │   └── PartialInput.tsx
    │   │   ├── InspectButton
    │   │   │   ├── InspectButton.module.scss
    │   │   │   └── InspectButton.tsx
    │   │   ├── Items
    │   │   │   ├── Items.md
    │   │   │   ├── Items.spec.ts
    │   │   │   ├── Items.tsx
    │   │   │   └── ItemsNative.tsx
    │   │   ├── Link
    │   │   │   ├── Link.md
    │   │   │   ├── Link.module.scss
    │   │   │   ├── Link.spec.ts
    │   │   │   ├── Link.tsx
    │   │   │   └── LinkNative.tsx
    │   │   ├── List
    │   │   │   ├── doc-resources
    │   │   │   │   └── list-component-data.js
    │   │   │   ├── List.md
    │   │   │   ├── List.module.scss
    │   │   │   ├── List.spec.ts
    │   │   │   ├── List.tsx
    │   │   │   └── ListNative.tsx
    │   │   ├── Logo
    │   │   │   ├── doc-resources
    │   │   │   │   └── xmlui-logo.svg
    │   │   │   ├── Logo.md
    │   │   │   ├── Logo.tsx
    │   │   │   └── LogoNative.tsx
    │   │   ├── Markdown
    │   │   │   ├── CodeText.module.scss
    │   │   │   ├── CodeText.tsx
    │   │   │   ├── Markdown.md
    │   │   │   ├── Markdown.module.scss
    │   │   │   ├── Markdown.spec.ts
    │   │   │   ├── Markdown.tsx
    │   │   │   ├── MarkdownNative.tsx
    │   │   │   ├── parse-binding-expr.ts
    │   │   │   └── utils.ts
    │   │   ├── metadata-helpers.ts
    │   │   ├── ModalDialog
    │   │   │   ├── ConfirmationModalContextProvider.tsx
    │   │   │   ├── Dialog.module.scss
    │   │   │   ├── Dialog.tsx
    │   │   │   ├── ModalDialog.md
    │   │   │   ├── ModalDialog.module.scss
    │   │   │   ├── ModalDialog.spec.ts
    │   │   │   ├── ModalDialog.tsx
    │   │   │   ├── ModalDialogNative.tsx
    │   │   │   └── ModalVisibilityContext.tsx
    │   │   ├── NavGroup
    │   │   │   ├── NavGroup.md
    │   │   │   ├── NavGroup.module.scss
    │   │   │   ├── NavGroup.spec.ts
    │   │   │   ├── NavGroup.tsx
    │   │   │   ├── NavGroupContext.ts
    │   │   │   └── NavGroupNative.tsx
    │   │   ├── NavLink
    │   │   │   ├── NavLink.md
    │   │   │   ├── NavLink.module.scss
    │   │   │   ├── NavLink.spec.ts
    │   │   │   ├── NavLink.tsx
    │   │   │   └── NavLinkNative.tsx
    │   │   ├── NavPanel
    │   │   │   ├── NavPanel.md
    │   │   │   ├── NavPanel.module.scss
    │   │   │   ├── NavPanel.spec.ts
    │   │   │   ├── NavPanel.tsx
    │   │   │   └── NavPanelNative.tsx
    │   │   ├── NestedApp
    │   │   │   ├── AppWithCodeView.module.scss
    │   │   │   ├── AppWithCodeView.tsx
    │   │   │   ├── AppWithCodeViewNative.tsx
    │   │   │   ├── defaultProps.tsx
    │   │   │   ├── logo.svg
    │   │   │   ├── NestedApp.module.scss
    │   │   │   ├── NestedApp.tsx
    │   │   │   ├── NestedAppNative.tsx
    │   │   │   ├── Tooltip.module.scss
    │   │   │   ├── Tooltip.tsx
    │   │   │   └── utils.ts
    │   │   ├── NoResult
    │   │   │   ├── NoResult.md
    │   │   │   ├── NoResult.module.scss
    │   │   │   ├── NoResult.spec.ts
    │   │   │   ├── NoResult.tsx
    │   │   │   └── NoResultNative.tsx
    │   │   ├── NumberBox
    │   │   │   ├── numberbox-abstractions.ts
    │   │   │   ├── NumberBox.md
    │   │   │   ├── NumberBox.module.scss
    │   │   │   ├── NumberBox.spec.ts
    │   │   │   ├── NumberBox.tsx
    │   │   │   └── NumberBoxNative.tsx
    │   │   ├── Option
    │   │   │   ├── Option.md
    │   │   │   ├── Option.spec.ts
    │   │   │   ├── Option.tsx
    │   │   │   ├── OptionNative.tsx
    │   │   │   └── OptionTypeProvider.tsx
    │   │   ├── PageMetaTitle
    │   │   │   ├── PageMetaTilteNative.tsx
    │   │   │   ├── PageMetaTitle.md
    │   │   │   ├── PageMetaTitle.spec.ts
    │   │   │   └── PageMetaTitle.tsx
    │   │   ├── Pages
    │   │   │   ├── Page.md
    │   │   │   ├── Pages.md
    │   │   │   ├── Pages.module.scss
    │   │   │   ├── Pages.tsx
    │   │   │   └── PagesNative.tsx
    │   │   ├── Pagination
    │   │   │   ├── Pagination.md
    │   │   │   ├── Pagination.module.scss
    │   │   │   ├── Pagination.spec.ts
    │   │   │   ├── Pagination.tsx
    │   │   │   └── PaginationNative.tsx
    │   │   ├── PositionedContainer
    │   │   │   ├── PositionedContainer.module.scss
    │   │   │   ├── PositionedContainer.tsx
    │   │   │   └── PositionedContainerNative.tsx
    │   │   ├── ProfileMenu
    │   │   │   ├── ProfileMenu.module.scss
    │   │   │   └── ProfileMenu.tsx
    │   │   ├── ProgressBar
    │   │   │   ├── ProgressBar.md
    │   │   │   ├── ProgressBar.module.scss
    │   │   │   ├── ProgressBar.spec.ts
    │   │   │   ├── ProgressBar.tsx
    │   │   │   └── ProgressBarNative.tsx
    │   │   ├── Queue
    │   │   │   ├── Queue.md
    │   │   │   ├── Queue.spec.ts
    │   │   │   ├── Queue.tsx
    │   │   │   ├── queueActions.ts
    │   │   │   └── QueueNative.tsx
    │   │   ├── RadioGroup
    │   │   │   ├── RadioGroup.md
    │   │   │   ├── RadioGroup.module.scss
    │   │   │   ├── RadioGroup.spec.ts
    │   │   │   ├── RadioGroup.tsx
    │   │   │   ├── RadioGroupNative.tsx
    │   │   │   ├── RadioItem.tsx
    │   │   │   └── RadioItemNative.tsx
    │   │   ├── RealTimeAdapter
    │   │   │   ├── RealTimeAdapter.tsx
    │   │   │   └── RealTimeAdapterNative.tsx
    │   │   ├── Redirect
    │   │   │   ├── Redirect.md
    │   │   │   ├── Redirect.spec.ts
    │   │   │   └── Redirect.tsx
    │   │   ├── ResponsiveBar
    │   │   │   ├── README.md
    │   │   │   ├── ResponsiveBar.md
    │   │   │   ├── ResponsiveBar.module.scss
    │   │   │   ├── ResponsiveBar.spec.ts
    │   │   │   ├── ResponsiveBar.tsx
    │   │   │   └── ResponsiveBarNative.tsx
    │   │   ├── Select
    │   │   │   ├── HiddenOption.tsx
    │   │   │   ├── OptionContext.ts
    │   │   │   ├── Select.md
    │   │   │   ├── Select.module.scss
    │   │   │   ├── Select.spec.ts
    │   │   │   ├── Select.tsx
    │   │   │   ├── SelectContext.tsx
    │   │   │   └── SelectNative.tsx
    │   │   ├── SelectionStore
    │   │   │   ├── SelectionStore.md
    │   │   │   ├── SelectionStore.tsx
    │   │   │   └── SelectionStoreNative.tsx
    │   │   ├── Slider
    │   │   │   ├── Slider.md
    │   │   │   ├── Slider.module.scss
    │   │   │   ├── Slider.spec.ts
    │   │   │   ├── Slider.tsx
    │   │   │   └── SliderNative.tsx
    │   │   ├── Slot
    │   │   │   ├── Slot.md
    │   │   │   ├── Slot.spec.ts
    │   │   │   └── Slot.ts
    │   │   ├── SlotItem.tsx
    │   │   ├── SpaceFiller
    │   │   │   ├── SpaceFiller.md
    │   │   │   ├── SpaceFiller.module.scss
    │   │   │   ├── SpaceFiller.spec.ts
    │   │   │   ├── SpaceFiller.tsx
    │   │   │   └── SpaceFillerNative.tsx
    │   │   ├── Spinner
    │   │   │   ├── Spinner.md
    │   │   │   ├── Spinner.module.scss
    │   │   │   ├── Spinner.spec.ts
    │   │   │   ├── Spinner.tsx
    │   │   │   └── SpinnerNative.tsx
    │   │   ├── Splitter
    │   │   │   ├── HSplitter.md
    │   │   │   ├── HSplitter.spec.ts
    │   │   │   ├── Splitter.md
    │   │   │   ├── Splitter.module.scss
    │   │   │   ├── Splitter.spec.ts
    │   │   │   ├── Splitter.tsx
    │   │   │   ├── SplitterNative.tsx
    │   │   │   ├── utils.ts
    │   │   │   ├── VSplitter.md
    │   │   │   └── VSplitter.spec.ts
    │   │   ├── Stack
    │   │   │   ├── CHStack.md
    │   │   │   ├── CHStack.spec.ts
    │   │   │   ├── CVStack.md
    │   │   │   ├── CVStack.spec.ts
    │   │   │   ├── HStack.md
    │   │   │   ├── HStack.spec.ts
    │   │   │   ├── Stack.md
    │   │   │   ├── Stack.module.scss
    │   │   │   ├── Stack.spec.ts
    │   │   │   ├── Stack.tsx
    │   │   │   ├── StackNative.tsx
    │   │   │   ├── VStack.md
    │   │   │   └── VStack.spec.ts
    │   │   ├── StickyBox
    │   │   │   ├── StickyBox.md
    │   │   │   ├── StickyBox.module.scss
    │   │   │   ├── StickyBox.tsx
    │   │   │   └── StickyBoxNative.tsx
    │   │   ├── Switch
    │   │   │   ├── Switch.md
    │   │   │   ├── Switch.spec.ts
    │   │   │   └── Switch.tsx
    │   │   ├── Table
    │   │   │   ├── doc-resources
    │   │   │   │   └── list-component-data.js
    │   │   │   ├── react-table-config.d.ts
    │   │   │   ├── Table.md
    │   │   │   ├── Table.module.scss
    │   │   │   ├── Table.spec.ts
    │   │   │   ├── Table.tsx
    │   │   │   ├── TableNative.tsx
    │   │   │   └── useRowSelection.tsx
    │   │   ├── TableOfContents
    │   │   │   ├── TableOfContents.module.scss
    │   │   │   ├── TableOfContents.spec.ts
    │   │   │   ├── TableOfContents.tsx
    │   │   │   └── TableOfContentsNative.tsx
    │   │   ├── Tabs
    │   │   │   ├── TabContext.tsx
    │   │   │   ├── TabItem.md
    │   │   │   ├── TabItem.tsx
    │   │   │   ├── TabItemNative.tsx
    │   │   │   ├── Tabs.md
    │   │   │   ├── Tabs.module.scss
    │   │   │   ├── Tabs.spec.ts
    │   │   │   ├── Tabs.tsx
    │   │   │   └── TabsNative.tsx
    │   │   ├── Text
    │   │   │   ├── Text.md
    │   │   │   ├── Text.module.scss
    │   │   │   ├── Text.spec.ts
    │   │   │   ├── Text.tsx
    │   │   │   └── TextNative.tsx
    │   │   ├── TextArea
    │   │   │   ├── TextArea.md
    │   │   │   ├── TextArea.module.scss
    │   │   │   ├── TextArea.spec.ts
    │   │   │   ├── TextArea.tsx
    │   │   │   ├── TextAreaNative.tsx
    │   │   │   ├── TextAreaResizable.tsx
    │   │   │   └── useComposedRef.ts
    │   │   ├── TextBox
    │   │   │   ├── TextBox.md
    │   │   │   ├── TextBox.module.scss
    │   │   │   ├── TextBox.spec.ts
    │   │   │   ├── TextBox.tsx
    │   │   │   └── TextBoxNative.tsx
    │   │   ├── Theme
    │   │   │   ├── NotificationToast.tsx
    │   │   │   ├── Theme.md
    │   │   │   ├── Theme.module.scss
    │   │   │   ├── Theme.spec.ts
    │   │   │   ├── Theme.tsx
    │   │   │   └── ThemeNative.tsx
    │   │   ├── TimeInput
    │   │   │   ├── TimeInput.md
    │   │   │   ├── TimeInput.module.scss
    │   │   │   ├── TimeInput.spec.ts
    │   │   │   ├── TimeInput.tsx
    │   │   │   ├── TimeInputNative.tsx
    │   │   │   └── utils.ts
    │   │   ├── Timer
    │   │   │   ├── Timer.md
    │   │   │   ├── Timer.spec.ts
    │   │   │   ├── Timer.tsx
    │   │   │   └── TimerNative.tsx
    │   │   ├── Toggle
    │   │   │   ├── Toggle.module.scss
    │   │   │   └── Toggle.tsx
    │   │   ├── ToneChangerButton
    │   │   │   ├── ToneChangerButton.md
    │   │   │   ├── ToneChangerButton.spec.ts
    │   │   │   └── ToneChangerButton.tsx
    │   │   ├── ToneSwitch
    │   │   │   ├── ToneSwitch.md
    │   │   │   ├── ToneSwitch.module.scss
    │   │   │   ├── ToneSwitch.spec.ts
    │   │   │   ├── ToneSwitch.tsx
    │   │   │   └── ToneSwitchNative.tsx
    │   │   ├── Tooltip
    │   │   │   ├── Tooltip.md
    │   │   │   ├── Tooltip.module.scss
    │   │   │   ├── Tooltip.spec.ts
    │   │   │   ├── Tooltip.tsx
    │   │   │   └── TooltipNative.tsx
    │   │   ├── Tree
    │   │   │   ├── testData.ts
    │   │   │   ├── Tree-dynamic.spec.ts
    │   │   │   ├── Tree-icons.spec.ts
    │   │   │   ├── Tree.md
    │   │   │   ├── Tree.spec.ts
    │   │   │   ├── TreeComponent.module.scss
    │   │   │   ├── TreeComponent.tsx
    │   │   │   └── TreeNative.tsx
    │   │   ├── TreeDisplay
    │   │   │   ├── TreeDisplay.md
    │   │   │   ├── TreeDisplay.module.scss
    │   │   │   ├── TreeDisplay.tsx
    │   │   │   └── TreeDisplayNative.tsx
    │   │   ├── ValidationSummary
    │   │   │   ├── ValidationSummary.module.scss
    │   │   │   └── ValidationSummary.tsx
    │   │   └── VisuallyHidden.tsx
    │   ├── components-core
    │   │   ├── abstractions
    │   │   │   ├── ComponentRenderer.ts
    │   │   │   ├── LoaderRenderer.ts
    │   │   │   ├── standalone.ts
    │   │   │   └── treeAbstractions.ts
    │   │   ├── action
    │   │   │   ├── actions.ts
    │   │   │   ├── APICall.tsx
    │   │   │   ├── FileDownloadAction.tsx
    │   │   │   ├── FileUploadAction.tsx
    │   │   │   ├── NavigateAction.tsx
    │   │   │   └── TimedAction.tsx
    │   │   ├── ApiBoundComponent.tsx
    │   │   ├── appContext
    │   │   │   ├── date-functions.ts
    │   │   │   ├── math-function.ts
    │   │   │   └── misc-utils.ts
    │   │   ├── AppContext.tsx
    │   │   ├── behaviors
    │   │   │   ├── Behavior.tsx
    │   │   │   └── CoreBehaviors.tsx
    │   │   ├── component-hooks.ts
    │   │   ├── ComponentDecorator.tsx
    │   │   ├── ComponentViewer.tsx
    │   │   ├── CompoundComponent.tsx
    │   │   ├── constants.ts
    │   │   ├── DebugViewProvider.tsx
    │   │   ├── descriptorHelper.ts
    │   │   ├── devtools
    │   │   │   ├── InspectorDialog.module.scss
    │   │   │   ├── InspectorDialog.tsx
    │   │   │   └── InspectorDialogVisibilityContext.tsx
    │   │   ├── EngineError.ts
    │   │   ├── event-handlers.ts
    │   │   ├── InspectorButton.module.scss
    │   │   ├── InspectorContext.tsx
    │   │   ├── interception
    │   │   │   ├── abstractions.ts
    │   │   │   ├── ApiInterceptor.ts
    │   │   │   ├── ApiInterceptorProvider.tsx
    │   │   │   ├── apiInterceptorWorker.ts
    │   │   │   ├── Backend.ts
    │   │   │   ├── Errors.ts
    │   │   │   ├── IndexedDb.ts
    │   │   │   ├── initMock.ts
    │   │   │   ├── InMemoryDb.ts
    │   │   │   ├── ReadonlyCollection.ts
    │   │   │   └── useApiInterceptorContext.tsx
    │   │   ├── loader
    │   │   │   ├── ApiLoader.tsx
    │   │   │   ├── DataLoader.tsx
    │   │   │   ├── ExternalDataLoader.tsx
    │   │   │   ├── Loader.tsx
    │   │   │   ├── MockLoaderRenderer.tsx
    │   │   │   └── PageableLoader.tsx
    │   │   ├── LoaderComponent.tsx
    │   │   ├── markup-check.ts
    │   │   ├── parts.ts
    │   │   ├── renderers.ts
    │   │   ├── rendering
    │   │   │   ├── AppContent.tsx
    │   │   │   ├── AppRoot.tsx
    │   │   │   ├── AppWrapper.tsx
    │   │   │   ├── buildProxy.ts
    │   │   │   ├── collectFnVarDeps.ts
    │   │   │   ├── ComponentAdapter.tsx
    │   │   │   ├── ComponentWrapper.tsx
    │   │   │   ├── Container.tsx
    │   │   │   ├── containers.ts
    │   │   │   ├── ContainerWrapper.tsx
    │   │   │   ├── ErrorBoundary.module.scss
    │   │   │   ├── ErrorBoundary.tsx
    │   │   │   ├── InvalidComponent.module.scss
    │   │   │   ├── InvalidComponent.tsx
    │   │   │   ├── nodeUtils.ts
    │   │   │   ├── reducer.ts
    │   │   │   ├── renderChild.tsx
    │   │   │   ├── StandaloneComponent.tsx
    │   │   │   ├── StateContainer.tsx
    │   │   │   ├── UnknownComponent.module.scss
    │   │   │   ├── UnknownComponent.tsx
    │   │   │   └── valueExtractor.ts
    │   │   ├── reportEngineError.ts
    │   │   ├── RestApiProxy.ts
    │   │   ├── script-runner
    │   │   │   ├── asyncProxy.ts
    │   │   │   ├── AttributeValueParser.ts
    │   │   │   ├── bannedFunctions.ts
    │   │   │   ├── BindingTreeEvaluationContext.ts
    │   │   │   ├── eval-tree-async.ts
    │   │   │   ├── eval-tree-common.ts
    │   │   │   ├── eval-tree-sync.ts
    │   │   │   ├── ParameterParser.ts
    │   │   │   ├── process-statement-async.ts
    │   │   │   ├── process-statement-common.ts
    │   │   │   ├── process-statement-sync.ts
    │   │   │   ├── ScriptingSourceTree.ts
    │   │   │   ├── simplify-expression.ts
    │   │   │   ├── statement-queue.ts
    │   │   │   └── visitors.ts
    │   │   ├── StandaloneApp.tsx
    │   │   ├── StandaloneExtensionManager.ts
    │   │   ├── TableOfContentsContext.tsx
    │   │   ├── theming
    │   │   │   ├── _themes.scss
    │   │   │   ├── component-layout-resolver.ts
    │   │   │   ├── extendThemeUtils.ts
    │   │   │   ├── hvar.ts
    │   │   │   ├── layout-resolver.ts
    │   │   │   ├── parse-layout-props.ts
    │   │   │   ├── StyleContext.tsx
    │   │   │   ├── StyleRegistry.ts
    │   │   │   ├── ThemeContext.tsx
    │   │   │   ├── ThemeProvider.tsx
    │   │   │   ├── themes
    │   │   │   │   ├── base-utils.ts
    │   │   │   │   ├── palette.ts
    │   │   │   │   ├── root.ts
    │   │   │   │   ├── solid.ts
    │   │   │   │   ├── theme-colors.ts
    │   │   │   │   └── xmlui.ts
    │   │   │   ├── themeVars.module.scss
    │   │   │   ├── themeVars.ts
    │   │   │   ├── transformThemeVars.ts
    │   │   │   └── utils.ts
    │   │   ├── utils
    │   │   │   ├── actionUtils.ts
    │   │   │   ├── audio-utils.ts
    │   │   │   ├── base64-utils.ts
    │   │   │   ├── compound-utils.ts
    │   │   │   ├── css-utils.ts
    │   │   │   ├── DataLoaderQueryKeyGenerator.ts
    │   │   │   ├── date-utils.ts
    │   │   │   ├── extractParam.ts
    │   │   │   ├── hooks.tsx
    │   │   │   ├── LruCache.ts
    │   │   │   ├── mergeProps.ts
    │   │   │   ├── misc.ts
    │   │   │   ├── request-params.ts
    │   │   │   ├── statementUtils.ts
    │   │   │   └── treeUtils.ts
    │   │   └── xmlui-parser.ts
    │   ├── index-standalone.ts
    │   ├── index.scss
    │   ├── index.ts
    │   ├── language-server
    │   │   ├── server-common.ts
    │   │   ├── server-web-worker.ts
    │   │   ├── server.ts
    │   │   ├── services
    │   │   │   ├── common
    │   │   │   │   ├── docs-generation.ts
    │   │   │   │   ├── lsp-utils.ts
    │   │   │   │   ├── metadata-utils.ts
    │   │   │   │   └── syntax-node-utilities.ts
    │   │   │   ├── completion.ts
    │   │   │   ├── diagnostic.ts
    │   │   │   ├── format.ts
    │   │   │   └── hover.ts
    │   │   └── xmlui-metadata-generated.js
    │   ├── logging
    │   │   ├── LoggerContext.tsx
    │   │   ├── LoggerInitializer.tsx
    │   │   ├── LoggerService.ts
    │   │   └── xmlui.ts
    │   ├── logo.svg
    │   ├── parsers
    │   │   ├── common
    │   │   │   ├── GenericToken.ts
    │   │   │   ├── InputStream.ts
    │   │   │   └── utils.ts
    │   │   ├── scripting
    │   │   │   ├── code-behind-collect.ts
    │   │   │   ├── Lexer.ts
    │   │   │   ├── modules.ts
    │   │   │   ├── Parser.ts
    │   │   │   ├── ParserError.ts
    │   │   │   ├── ScriptingNodeTypes.ts
    │   │   │   ├── TokenTrait.ts
    │   │   │   ├── TokenType.ts
    │   │   │   └── tree-visitor.ts
    │   │   ├── style-parser
    │   │   │   ├── errors.ts
    │   │   │   ├── source-tree.ts
    │   │   │   ├── StyleInputStream.ts
    │   │   │   ├── StyleLexer.ts
    │   │   │   ├── StyleParser.ts
    │   │   │   └── tokens.ts
    │   │   └── xmlui-parser
    │   │       ├── CharacterCodes.ts
    │   │       ├── diagnostics.ts
    │   │       ├── fileExtensions.ts
    │   │       ├── index.ts
    │   │       ├── lint.ts
    │   │       ├── parser.ts
    │   │       ├── ParserError.ts
    │   │       ├── scanner.ts
    │   │       ├── syntax-kind.ts
    │   │       ├── syntax-node.ts
    │   │       ├── transform.ts
    │   │       ├── utils.ts
    │   │       ├── xmlui-serializer.ts
    │   │       └── xmlui-tree.ts
    │   ├── react-app-env.d.ts
    │   ├── syntax
    │   │   ├── monaco
    │   │   │   ├── grammar.monacoLanguage.ts
    │   │   │   ├── index.ts
    │   │   │   ├── xmlui-dark.ts
    │   │   │   ├── xmlui-light.ts
    │   │   │   └── xmluiscript.monacoLanguage.ts
    │   │   └── textMate
    │   │       ├── index.ts
    │   │       ├── xmlui-dark.json
    │   │       ├── xmlui-light.json
    │   │       ├── xmlui.json
    │   │       └── xmlui.tmLanguage.json
    │   ├── testing
    │   │   ├── assertions.ts
    │   │   ├── component-test-helpers.ts
    │   │   ├── ComponentDrivers.ts
    │   │   ├── drivers
    │   │   │   ├── DateInputDriver.ts
    │   │   │   ├── index.ts
    │   │   │   ├── ModalDialogDriver.ts
    │   │   │   ├── NumberBoxDriver.ts
    │   │   │   ├── TextBoxDriver.ts
    │   │   │   ├── TimeInputDriver.ts
    │   │   │   ├── TimerDriver.ts
    │   │   │   └── TreeDriver.ts
    │   │   ├── fixtures.ts
    │   │   ├── index.ts
    │   │   ├── infrastructure
    │   │   │   ├── index.html
    │   │   │   ├── main.tsx
    │   │   │   ├── public
    │   │   │   │   ├── mockServiceWorker.js
    │   │   │   │   ├── resources
    │   │   │   │   │   ├── bell.svg
    │   │   │   │   │   ├── box.svg
    │   │   │   │   │   ├── doc.svg
    │   │   │   │   │   ├── eye.svg
    │   │   │   │   │   ├── flower-640x480.jpg
    │   │   │   │   │   ├── sun.svg
    │   │   │   │   │   ├── test-image-100x100.jpg
    │   │   │   │   │   └── txt.svg
    │   │   │   │   └── serve.json
    │   │   │   └── TestBed.tsx
    │   │   └── themed-app-test-helpers.ts
    │   └── vite-env.d.ts
    ├── tests
    │   ├── components
    │   │   ├── CodeBlock
    │   │   │   └── hightlight-code.test.ts
    │   │   ├── playground-pattern.test.ts
    │   │   └── Tree
    │   │       └── Tree-states.test.ts
    │   ├── components-core
    │   │   ├── abstractions
    │   │   │   └── treeAbstractions.test.ts
    │   │   ├── container
    │   │   │   └── buildProxy.test.ts
    │   │   ├── interception
    │   │   │   ├── orderBy.test.ts
    │   │   │   ├── ReadOnlyCollection.test.ts
    │   │   │   └── request-param-converter.test.ts
    │   │   ├── scripts-runner
    │   │   │   ├── AttributeValueParser.test.ts
    │   │   │   ├── eval-tree-arrow-async.test.ts
    │   │   │   ├── eval-tree-arrow.test.ts
    │   │   │   ├── eval-tree-func-decl-async.test.ts
    │   │   │   ├── eval-tree-func-decl.test.ts
    │   │   │   ├── eval-tree-pre-post.test.ts
    │   │   │   ├── eval-tree-regression.test.ts
    │   │   │   ├── eval-tree.test.ts
    │   │   │   ├── function-proxy.test.ts
    │   │   │   ├── parser-regression.test.ts
    │   │   │   ├── process-event.test.ts
    │   │   │   ├── process-function.test.ts
    │   │   │   ├── process-implicit-context.test.ts
    │   │   │   ├── process-statement-asgn.test.ts
    │   │   │   ├── process-statement-destruct.test.ts
    │   │   │   ├── process-statement-regs.test.ts
    │   │   │   ├── process-statement-sync.test.ts
    │   │   │   ├── process-statement.test.ts
    │   │   │   ├── process-switch-sync.test.ts
    │   │   │   ├── process-switch.test.ts
    │   │   │   ├── process-try-sync.test.ts
    │   │   │   ├── process-try.test.ts
    │   │   │   └── test-helpers.ts
    │   │   ├── test-metadata-handler.ts
    │   │   ├── theming
    │   │   │   ├── border-segments.test.ts
    │   │   │   ├── component-layout.resolver.test.ts
    │   │   │   ├── layout-property-parser.test.ts
    │   │   │   ├── layout-resolver.test.ts
    │   │   │   ├── layout-resolver2.test.ts
    │   │   │   ├── layout-vp-override.test.ts
    │   │   │   └── padding-segments.test.ts
    │   │   └── utils
    │   │       ├── date-utils.test.ts
    │   │       ├── format-human-elapsed-time.test.ts
    │   │       └── LruCache.test.ts
    │   ├── language-server
    │   │   ├── completion.test.ts
    │   │   ├── format.test.ts
    │   │   ├── hover.test.ts
    │   │   └── mockData.ts
    │   └── parsers
    │       ├── common
    │       │   └── input-stream.test.ts
    │       ├── markdown
    │       │   └── parse-binding-expression.test.ts
    │       ├── parameter-parser.test.ts
    │       ├── paremeter-parser.test.ts
    │       ├── scripting
    │       │   ├── eval-tree-arrow.test.ts
    │       │   ├── eval-tree-pre-post.test.ts
    │       │   ├── eval-tree.test.ts
    │       │   ├── function-proxy.test.ts
    │       │   ├── lexer-literals.test.ts
    │       │   ├── lexer-misc.test.ts
    │       │   ├── module-parse.test.ts
    │       │   ├── parser-arrow.test.ts
    │       │   ├── parser-assignments.test.ts
    │       │   ├── parser-binary.test.ts
    │       │   ├── parser-destructuring.test.ts
    │       │   ├── parser-errors.test.ts
    │       │   ├── parser-expressions.test.ts
    │       │   ├── parser-function.test.ts
    │       │   ├── parser-literals.test.ts
    │       │   ├── parser-primary.test.ts
    │       │   ├── parser-regex.test.ts
    │       │   ├── parser-statements.test.ts
    │       │   ├── parser-unary.test.ts
    │       │   ├── process-event.test.ts
    │       │   ├── process-implicit-context.test.ts
    │       │   ├── process-statement-asgn.test.ts
    │       │   ├── process-statement-destruct.test.ts
    │       │   ├── process-statement-regs.test.ts
    │       │   ├── process-statement-sync.test.ts
    │       │   ├── process-statement.test.ts
    │       │   ├── process-switch-sync.test.ts
    │       │   ├── process-switch.test.ts
    │       │   ├── process-try-sync.test.ts
    │       │   ├── process-try.test.ts
    │       │   ├── simplify-expression.test.ts
    │       │   ├── statement-hooks.test.ts
    │       │   └── test-helpers.ts
    │       ├── style-parser
    │       │   ├── generateHvarChain.test.ts
    │       │   ├── parseHVar.test.ts
    │       │   ├── parser.test.ts
    │       │   └── tokens.test.ts
    │       └── xmlui
    │           ├── lint.test.ts
    │           ├── parser.test.ts
    │           ├── scanner.test.ts
    │           ├── transform.attr.test.ts
    │           ├── transform.circular.test.ts
    │           ├── transform.element.test.ts
    │           ├── transform.errors.test.ts
    │           ├── transform.escape.test.ts
    │           ├── transform.regression.test.ts
    │           ├── transform.script.test.ts
    │           ├── transform.test.ts
    │           └── xmlui.ts
    ├── tests-e2e
    │   ├── api-bound-component-regression.spec.ts
    │   ├── api-call-as-extracted-component.spec.ts
    │   ├── assign-to-object-or-array-regression.spec.ts
    │   ├── binding-regression.spec.ts
    │   ├── children-as-template-context-vars.spec.ts
    │   ├── compound-component.spec.ts
    │   ├── context-vars-regression.spec.ts
    │   ├── data-bindings.spec.ts
    │   ├── datasource-and-api-usage-in-var.spec.ts
    │   ├── datasource-direct-binding.spec.ts
    │   ├── datasource-onLoaded-regression.spec.ts
    │   ├── modify-array-item-regression.spec.ts
    │   ├── namespaces.spec.ts
    │   ├── push-to-array-regression.spec.ts
    │   ├── screen-breakpoints.spec.ts
    │   ├── scripting.spec.ts
    │   ├── state-scope-in-pages.spec.ts
    │   └── state-var-scopes.spec.ts
    ├── tsconfig.json
    ├── tsdown.config.ts
    ├── vite.config.ts
    └── vitest.config.ts
```

# Files

--------------------------------------------------------------------------------
/xmlui/src/parsers/xmlui-parser/parser.ts:
--------------------------------------------------------------------------------

```typescript
  1 | import { Node } from "./syntax-node";
  2 | import type { ScannerErrorCallback } from "./scanner";
  3 | import type {
  4 |   ScannerDiagnosticMessage,
  5 |   GeneralDiagnosticMessage,
  6 |   DiagnosticCategory,
  7 | } from "./diagnostics";
  8 | import { CharacterCodes } from "./CharacterCodes";
  9 | import { createScanner } from "./scanner";
 10 | import { SyntaxKind, getSyntaxKindStrRepr } from "./syntax-kind";
 11 | import { tagNameNodesWithoutErrorsMatch } from "./utils";
 12 | import { ErrCodes, DIAGS } from "./diagnostics";
 13 | 
 14 | export interface Error {
 15 |   readonly category: DiagnosticCategory;
 16 |   readonly code: ErrCodes;
 17 |   readonly message: string;
 18 |   readonly pos: number;
 19 |   readonly end: number;
 20 |   readonly contextPos: number;
 21 |   readonly contextEnd: number;
 22 | }
 23 | 
 24 | type IncompleteNode = {
 25 |   children: Node[];
 26 | };
 27 | 
 28 | export type GetText = (n: Node, ignoreTrivia?: boolean) => string;
 29 | 
 30 | export type ParseResult = { node: Node; errors: Error[] };
 31 | 
 32 | const RECOVER_FILE = [SyntaxKind.CData, SyntaxKind.Script, SyntaxKind.OpenNodeStart] as const;
 33 | const RECOVER_OPEN_TAG = [
 34 |   SyntaxKind.OpenNodeStart,
 35 |   SyntaxKind.NodeEnd,
 36 |   SyntaxKind.NodeClose,
 37 |   SyntaxKind.CloseNodeStart,
 38 |   SyntaxKind.CData,
 39 |   SyntaxKind.Script,
 40 | ] as const;
 41 | const RECOVER_ATTR = [SyntaxKind.Identifier, ...RECOVER_OPEN_TAG] as const;
 42 | const RECOVER_CONTENT_LIST = [
 43 |   SyntaxKind.TextNode,
 44 |   SyntaxKind.StringLiteral,
 45 |   SyntaxKind.CData,
 46 |   SyntaxKind.Script,
 47 |   SyntaxKind.OpenNodeStart,
 48 |   SyntaxKind.CloseNodeStart,
 49 | ] as const;
 50 | const RECOVER_CLOSE_TAG = [
 51 |   SyntaxKind.NodeEnd,
 52 |   SyntaxKind.OpenNodeStart,
 53 |   SyntaxKind.CloseNodeStart,
 54 |   SyntaxKind.CData,
 55 |   SyntaxKind.Script,
 56 | ] as const;
 57 | 
 58 | const needsExtendedContext = [
 59 |   ErrCodes.unexpectedCloseTag,
 60 |   ErrCodes.expCloseStartWithName,
 61 |   ErrCodes.expCloseStart,
 62 |   ErrCodes.tagNameMismatch,
 63 |   ErrCodes.expEnd,
 64 |   ErrCodes.expTagName,
 65 |   ErrCodes.expTagOpen,
 66 |   ErrCodes.expEndOrClose,
 67 |   ErrCodes.expTagNameAfterNamespace,
 68 |   ErrCodes.expTagNameAfterCloseStart,
 69 | ];
 70 | 
 71 | export function createXmlUiParser(source: string): {
 72 |   parse: () => ParseResult;
 73 |   getText: GetText;
 74 | } {
 75 |   return {
 76 |     parse: () => parseXmlUiMarkup(source),
 77 |     getText: (n: { pos?: number; start?: number; end: number }, ignoreTrivia: boolean = true) =>
 78 |       source.substring(ignoreTrivia ? (n.pos ?? n.start ?? 0) : (n.start ?? n.pos ?? 0), n.end),
 79 |   };
 80 | }
 81 | 
 82 | export function parseXmlUiMarkup(text: string): ParseResult {
 83 |   const errors: Error[] = [];
 84 |   const parents: (IncompleteNode | Node)[] = [];
 85 |   let peekedToken: Node | undefined;
 86 |   let node: Node | IncompleteNode = { children: [] };
 87 |   let errFromScanner: { message: ScannerDiagnosticMessage; prefixLength: number } | undefined =
 88 |     undefined;
 89 | 
 90 |   const onScannerErr: ScannerErrorCallback = function (message, length) {
 91 |     errFromScanner = {
 92 |       message,
 93 |       prefixLength: length,
 94 |     };
 95 |   };
 96 |   const scanner = createScanner(false, text, onScannerErr);
 97 |   const fileContentListNode = parseFile();
 98 |   return { node: fileContentListNode, errors };
 99 | 
100 |   function getText(n: Node, ignoreTrivia: boolean = true) {
101 |     return text.substring(ignoreTrivia ? n.pos : n.start, n.end);
102 |   }
103 | 
104 |   function parseFile(): Node {
105 |     while (true) {
106 |       const token = peekInContent();
107 |       switch (token.kind) {
108 |         case SyntaxKind.EndOfFileToken:
109 |           bumpAny();
110 |           return createNode(SyntaxKind.ContentListNode, node.children);
111 |         case SyntaxKind.CData:
112 |         case SyntaxKind.Script:
113 |           bumpAny();
114 |           break;
115 |         case SyntaxKind.OpenNodeStart:
116 |           parseOpeningTag();
117 |           break;
118 | 
119 |         case SyntaxKind.TextNode:
120 |           bumpAny();
121 |           break;
122 |         case SyntaxKind.CloseNodeStart: {
123 |           const errNode = errNodeUntil(RECOVER_FILE);
124 |           errorAt(DIAGS.unexpectedCloseTag, errNode!.pos, errNode!.end);
125 |           break;
126 |         }
127 |         default:
128 |           const errNode = errNodeUntil(RECOVER_FILE);
129 |           errorAt(DIAGS.expTagOpen, errNode!.pos, errNode!.end);
130 |           break;
131 |       }
132 |     }
133 |   }
134 | 
135 |   function parseContentList() {
136 |     startNode();
137 |     loop: while (true) {
138 |       const token = peekInContent();
139 |       switch (token.kind) {
140 |         case SyntaxKind.TextNode:
141 |         case SyntaxKind.StringLiteral:
142 |         case SyntaxKind.CData:
143 |         case SyntaxKind.Script:
144 |           bumpAny();
145 |           break;
146 |         case SyntaxKind.OpenNodeStart:
147 |           parseOpeningTag();
148 |           break;
149 |         case SyntaxKind.CloseNodeStart:
150 |         case SyntaxKind.EndOfFileToken:
151 |           break loop;
152 |         default:
153 |           const errNode = errNodeUntil(RECOVER_CONTENT_LIST);
154 |           errorAt(DIAGS.expTagOpen, errNode!.pos, errNode!.end);
155 |           break;
156 |       }
157 |     }
158 |     if (node.children && node.children.length > 0) {
159 |       completeNode(SyntaxKind.ContentListNode);
160 |     } else {
161 |       abandonNode();
162 |     }
163 |   }
164 | 
165 |   function parseOpeningTag() {
166 |     startNode();
167 |     bump(SyntaxKind.OpenNodeStart);
168 |     let errInName = true;
169 |     let openTagName: Node | null = null;
170 |     if (at(SyntaxKind.Identifier)) {
171 |       const tagNameParseRes = parseOpeningTagName();
172 |       errInName = tagNameParseRes.errInName;
173 |       openTagName = tagNameParseRes.node;
174 |     } else {
175 |       const errNode = errNodeUntil(RECOVER_OPEN_TAG);
176 |       if (errNode) {
177 |         errorAt(DIAGS.expTagName, errNode.pos, errNode.end);
178 |       } else {
179 |         error(DIAGS.expTagName);
180 |       }
181 |     }
182 | 
183 |     if (!errInName) {
184 |       parseAttrList();
185 |     }
186 | 
187 |     switch (peek().kind) {
188 |       case SyntaxKind.NodeClose: {
189 |         bumpAny();
190 |         completeNode(SyntaxKind.ElementNode);
191 |         return;
192 |       }
193 | 
194 |       case SyntaxKind.NodeEnd: {
195 |         bumpAny();
196 |         parseContentList();
197 |         parseClosingTag(openTagName, errInName);
198 |         completeNode(SyntaxKind.ElementNode);
199 |         return;
200 |       }
201 | 
202 |       default: {
203 |         completeNode(SyntaxKind.ElementNode);
204 |         error(DIAGS.expEndOrClose);
205 |         return;
206 |       }
207 |     }
208 |   }
209 | 
210 |   function parseOpeningTagName(): { node: Node; errInName: boolean } {
211 |     startNode();
212 |     const identNode = bump(SyntaxKind.Identifier);
213 |     if (eat(SyntaxKind.Colon) && !eat(SyntaxKind.Identifier)) {
214 |       const nameNodeWithColon = completeNode(SyntaxKind.TagNameNode);
215 |       const namespaceName = getText(identNode);
216 |       errorAt(
217 |         DIAGS.expTagNameAfterNamespace(namespaceName),
218 |         nameNodeWithColon.pos,
219 |         nameNodeWithColon.end,
220 |       );
221 |       errNodeUntil([SyntaxKind.Identifier, ...RECOVER_OPEN_TAG]);
222 |       return { node: nameNodeWithColon, errInName: true };
223 |     } else {
224 |       return { node: completeNode(SyntaxKind.TagNameNode), errInName: false };
225 |     }
226 |   }
227 | 
228 |   function parseAttrList() {
229 |     startNode();
230 |     const attrNames: { ns?: string; name: string }[] = [];
231 | 
232 |     loop: while (true) {
233 |       switch (peek().kind) {
234 |         case SyntaxKind.EndOfFileToken:
235 |         // same as RECOVER_OPEN_TAG
236 |         case SyntaxKind.OpenNodeStart:
237 |         case SyntaxKind.NodeEnd:
238 |         case SyntaxKind.NodeClose:
239 |         case SyntaxKind.CloseNodeStart:
240 |         case SyntaxKind.CData:
241 |         case SyntaxKind.Script:
242 |           break loop;
243 | 
244 |         default:
245 |           parseAttr(attrNames);
246 |       }
247 |     }
248 | 
249 |     if (node.children!.length === 0) {
250 |       abandonNode();
251 |     } else {
252 |       completeNode(SyntaxKind.AttributeListNode);
253 |     }
254 |   }
255 | 
256 |   function parseAttr(attrNames: { ns?: string; name: string }[]) {
257 |     startNode();
258 |     if (at(SyntaxKind.Identifier)) {
259 |       parseAttrName(attrNames);
260 |     } else {
261 |       const errNode = errNodeUntil(RECOVER_ATTR);
262 |       if (errNode) {
263 |         if (at(SyntaxKind.Equal)) {
264 |           errorAt(DIAGS.expAttrNameBeforeEq, errNode.pos, errNode.end);
265 |         } else {
266 |           errorAt(DIAGS.expAttrName, errNode.pos, errNode.end);
267 |         }
268 |         completeNode(SyntaxKind.AttributeNode);
269 |       } else {
270 |         abandonNode();
271 |         error(DIAGS.expAttrName);
272 |       }
273 |       return;
274 |     }
275 | 
276 |     if (eat(SyntaxKind.Equal)) {
277 |       if (!eat(SyntaxKind.StringLiteral)) {
278 |         const errNode = errNodeUntil(RECOVER_ATTR);
279 |         if (errNode) {
280 |           errorAt(DIAGS.expAttrStr, errNode.pos, errNode.end);
281 |         } else {
282 |           error(DIAGS.expAttrStr);
283 |         }
284 |       }
285 |     }
286 | 
287 |     completeNode(SyntaxKind.AttributeNode);
288 |   }
289 | 
290 |   function parseAttrName(attrNames: { ns?: string; name: string }[]) {
291 |     let nameIdent = peek();
292 |     let nsIdent = undefined;
293 | 
294 |     startNode();
295 |     bump(SyntaxKind.Identifier);
296 |     if (eat(SyntaxKind.Colon)) {
297 |       if (at(SyntaxKind.Identifier)) {
298 |         nsIdent = nameIdent;
299 |         nameIdent = bump(SyntaxKind.Identifier);
300 |       } else {
301 |         const namespaceName = getText(nameIdent);
302 |         const errNode = errNodeUntil([
303 |           SyntaxKind.Equal,
304 |           SyntaxKind.Identifier,
305 |           ...RECOVER_OPEN_TAG,
306 |         ]);
307 | 
308 |         if (errNode) {
309 |           errorAt(DIAGS.expAttrNameAfterNamespace(namespaceName), errNode.pos, errNode.end);
310 |         } else {
311 |           error(DIAGS.expAttrNameAfterNamespace(namespaceName));
312 |         }
313 |       }
314 |     }
315 |     checkAttrName(attrNames, { nsIdent, nameIdent });
316 |     completeNode(SyntaxKind.AttributeKeyNode);
317 |   }
318 | 
319 |   function parseClosingTag(openTagName: Node | null, skipNameMatching: boolean) {
320 |     if (eat(SyntaxKind.CloseNodeStart)) {
321 |       if (at(SyntaxKind.Identifier)) {
322 |         const closeTagName = parseClosingTagName();
323 |         if (!skipNameMatching) {
324 |           const namesMismatch =
325 |             openTagName !== null &&
326 |             !tagNameNodesWithoutErrorsMatch(openTagName, closeTagName, getText);
327 |           if (namesMismatch) {
328 |             const msg = DIAGS.tagNameMismatch(getText(openTagName!), getText(closeTagName));
329 |             errorAt(msg, closeTagName.pos, closeTagName.end);
330 |           }
331 |         }
332 |       } else {
333 |         const errNode = errNodeUntil(RECOVER_CLOSE_TAG);
334 |         if (errNode) {
335 |           errorAt(DIAGS.expTagNameAfterCloseStart, errNode.pos, errNode.end);
336 |         } else {
337 |           error(DIAGS.expTagNameAfterCloseStart);
338 |         }
339 |       }
340 |       if (!eat(SyntaxKind.NodeEnd)) {
341 |         error(DIAGS.expEnd);
342 |       }
343 |     } else {
344 |       if (openTagName) {
345 |         errorAt(
346 |           DIAGS.expCloseStartWithName(getText(openTagName)),
347 |           openTagName.pos,
348 |           openTagName.end,
349 |         );
350 |       } else {
351 |         error(DIAGS.expCloseStart);
352 |       }
353 |     }
354 |   }
355 | 
356 |   function parseClosingTagName(): Node {
357 |     startNode();
358 |     const identNode = bump(SyntaxKind.Identifier);
359 |     if (eat(SyntaxKind.Colon) && !eat(SyntaxKind.Identifier)) {
360 |       const nameNodeWithColon = completeNode(SyntaxKind.TagNameNode);
361 |       errorAt(
362 |         DIAGS.expTagNameAfterNamespace(getText(identNode)),
363 |         nameNodeWithColon.pos,
364 |         nameNodeWithColon.end,
365 |       );
366 |       errNodeUntil(RECOVER_OPEN_TAG);
367 |       return nameNodeWithColon;
368 |     } else {
369 |       return completeNode(SyntaxKind.TagNameNode);
370 |     }
371 |   }
372 | 
373 |   type AttrName = {
374 |     ns?: string;
375 |     name: string;
376 |   };
377 | 
378 |   /** emits errors when the attribute name is incorrect. Otherwise adds the attribute name to the list of valid names*/
379 |   function checkAttrName(
380 |     attrNames: AttrName[],
381 |     { nameIdent, nsIdent }: { nameIdent: Node; nsIdent?: Node },
382 |   ) {
383 |     const attrName = getText(nameIdent);
384 |     const attrNs = nsIdent && getText(nsIdent);
385 |     const attrKeyMatches = ({ ns, name }: AttrName) => name === attrName && ns === attrNs;
386 |     const isDuplicate = attrNames.findIndex(attrKeyMatches) !== -1;
387 |     const nameStartsWithUppercase = "A" <= attrName[0] && attrName[0] <= "Z";
388 |     const faultyName = isDuplicate || nameStartsWithUppercase;
389 | 
390 |     //TODO: account for the namespace as well
391 |     if (isDuplicate) {
392 |       errorAt(DIAGS.duplAttr(attrName), nameIdent.pos, nameIdent.end);
393 |     }
394 |     if (!nsIdent && nameStartsWithUppercase) {
395 |       errorAt(DIAGS.uppercaseAttr(attrName), nameIdent.pos, nameIdent.end);
396 |     }
397 |     if (!faultyName) {
398 |       attrNames.push({ name: attrName, ns: attrNs });
399 |     }
400 |   }
401 | 
402 |   function getContextWithSurroundingLines(
403 |     pos: number,
404 |     end: number,
405 |     surroundingContextLines: number,
406 |   ): { contextPos: number; contextEnd: number } {
407 |     let newlinesFound: number;
408 |     let cursor: number;
409 | 
410 |     let contextPos: number;
411 |     cursor = pos;
412 |     newlinesFound = 0;
413 |     while (cursor >= 0) {
414 |       if (text[cursor] === "\n") {
415 |         newlinesFound++;
416 |         if (newlinesFound > surroundingContextLines) {
417 |           break;
418 |         }
419 |       }
420 |       cursor--;
421 |     }
422 |     contextPos = cursor + 1;
423 | 
424 |     let contextEnd: number;
425 |     cursor = end;
426 |     newlinesFound = 0;
427 |     while (cursor < text.length) {
428 |       if (text[cursor] === "\n") {
429 |         newlinesFound++;
430 |         if (newlinesFound > surroundingContextLines) {
431 |           break;
432 |         }
433 |         cursor++;
434 |       } else if (text[cursor] === "\r" && text[cursor + 1] === "\n") {
435 |         newlinesFound++;
436 |         if (newlinesFound > surroundingContextLines) {
437 |           break;
438 |         }
439 |         cursor += 2;
440 |       } else {
441 |         cursor++;
442 |       }
443 |     }
444 |     contextEnd = cursor;
445 | 
446 |     return { contextPos, contextEnd };
447 |   }
448 | 
449 |   function error({ code, message, category }: GeneralDiagnosticMessage) {
450 |     const { pos, end } = peek();
451 | 
452 |     const { contextPos, contextEnd } = getContextWithSurroundingLines(pos, end, 1);
453 | 
454 |     errors.push({
455 |       category,
456 |       code,
457 |       message,
458 |       pos,
459 |       end,
460 |       contextPos,
461 |       contextEnd,
462 |     });
463 |   }
464 | 
465 |   function errorAt(
466 |     { code, message, category }: GeneralDiagnosticMessage,
467 |     pos: number,
468 |     end: number,
469 |   ) {
470 |     const { contextPos, contextEnd } = getContextWithSurroundingLines(pos, end, 1);
471 | 
472 |     errors.push({
473 |       category,
474 |       code,
475 |       message,
476 |       pos,
477 |       end,
478 |       contextPos,
479 |       contextEnd,
480 |     });
481 |   }
482 | 
483 |   /**
484 |    *
485 |    * @param tokens that won't be consumed
486 |    * @returns the error node with the consumed tokens, or null if there were no tokens consumed
487 |    */
488 |   function errNodeUntil(tokens: readonly SyntaxKind[]): Node | null {
489 |     startNode();
490 |     advance(tokens);
491 |     if (node.children!.length === 0) {
492 |       abandonNode();
493 |       return null;
494 |     } else {
495 |       return completeNode(SyntaxKind.ErrorNode);
496 |     }
497 |   }
498 | 
499 |   function advance(to: readonly SyntaxKind[]) {
500 |     for (
501 |       let token = peek();
502 |       token.kind !== SyntaxKind.EndOfFileToken && !to.includes(token.kind);
503 |       bumpAny(), token = peek()
504 |     ) {}
505 |   }
506 | 
507 |   function eat(kind: SyntaxKind): boolean {
508 |     const kindMatched = at(kind);
509 |     if (kindMatched) {
510 |       bumpAny();
511 |     }
512 |     return kindMatched;
513 |   }
514 | 
515 |   function at(kindToCheck: SyntaxKind): boolean {
516 |     return peek().kind === kindToCheck;
517 |   }
518 | 
519 |   function peek(inContent: boolean = false) {
520 |     if (peekedToken !== undefined) {
521 |       return peekedToken;
522 |     }
523 |     peekedToken = collectToken(inContent);
524 |     return peekedToken;
525 |   }
526 | 
527 |   function peekInContent(): Node {
528 |     const token = peek(true);
529 |     if (
530 |       token.kind === SyntaxKind.EndOfFileToken ||
531 |       token.kind === SyntaxKind.OpenNodeStart ||
532 |       token.kind === SyntaxKind.Script ||
533 |       token.kind === SyntaxKind.CData ||
534 |       token.kind === SyntaxKind.CloseNodeStart
535 |     ) {
536 |       return token;
537 |     }
538 | 
539 |     const trivia = token.triviaBefore;
540 |     const triviaLength = trivia?.length ?? 0;
541 |     let i = 0;
542 |     let leadingComments = [];
543 |     let firstNonCommentTriviaIdx: number = -1;
544 |     for (; i < triviaLength; ++i) {
545 |       if (trivia![i].kind === SyntaxKind.CommentTrivia) {
546 |         leadingComments.push(trivia![i]);
547 |       } else {
548 |         firstNonCommentTriviaIdx = i;
549 |         break;
550 |       }
551 |     }
552 | 
553 |     let secondCommentGroupStartIdx = -1;
554 |     for (; i < triviaLength; ++i) {
555 |       if (trivia![i].kind === SyntaxKind.CommentTrivia) {
556 |         secondCommentGroupStartIdx = i;
557 |         break;
558 |       }
559 |     }
560 | 
561 |     let parseAsStringLiteral = false;
562 |     if (token.kind === SyntaxKind.StringLiteral) {
563 |       const beforeLookahead = token.end;
564 |       const nextToken = collectToken(true);
565 |       parseAsStringLiteral =
566 |         nextToken.kind === SyntaxKind.CData ||
567 |         nextToken.kind === SyntaxKind.CloseNodeStart ||
568 |         nextToken.kind === SyntaxKind.Script ||
569 |         nextToken.kind === SyntaxKind.OpenNodeStart;
570 |       scanner.resetTokenState(beforeLookahead);
571 |     }
572 | 
573 |     let pos: number;
574 |     if (parseAsStringLiteral) {
575 |       pos = token.pos;
576 |     } else if (leadingComments.length > 0) {
577 |       pos = leadingComments[leadingComments.length - 1].end;
578 |     } else if (firstNonCommentTriviaIdx !== -1) {
579 |       pos = trivia![firstNonCommentTriviaIdx].pos;
580 |     } else {
581 |       pos = token.start;
582 |     }
583 |     let triviaBefore = undefined;
584 |     if (leadingComments.length > 0) {
585 |       triviaBefore = leadingComments;
586 |     }
587 | 
588 |     let kind = SyntaxKind.TextNode;
589 |     let end: number = -1;
590 |     if (secondCommentGroupStartIdx !== -1) {
591 |       end = trivia![secondCommentGroupStartIdx].pos;
592 |       scanner.resetTokenState(end);
593 |     } else if (parseAsStringLiteral) {
594 |       kind = SyntaxKind.StringLiteral;
595 |       end = token.end;
596 |     } else {
597 |       while (true) {
598 |         const nextChar = scanner.peekChar();
599 |         if (nextChar === null || nextChar === CharacterCodes.lessThan) {
600 |           break;
601 |         }
602 |         scanner.scanChar();
603 |       }
604 |       end = scanner.getTokenEnd();
605 |     }
606 | 
607 |     peekedToken = new Node(kind, pos, end, triviaBefore);
608 |     return peekedToken;
609 |   }
610 | 
611 |   /** Same as bumpAny, but with an assertion of the token that was bumped over.
612 |    * Makes the code more redundant, but also more defensive*/
613 |   function bump(kind: SyntaxKind) {
614 |     const token = bumpAny();
615 |     if (token.kind !== kind) {
616 |       throw new Error(
617 |         `expected ${getSyntaxKindStrRepr(kind)}, bumped a ${getSyntaxKindStrRepr(token.kind)}`,
618 |       );
619 |     }
620 |     return token;
621 |   }
622 | 
623 |   function bumpAny(): Node {
624 |     if (peekedToken) {
625 |       node.children!.push(peekedToken);
626 |       const bumpedToken = peekedToken;
627 |       peekedToken = undefined;
628 |       return bumpedToken;
629 |     }
630 |     const token = collectToken(false);
631 |     node.children!.push(token);
632 |     return token;
633 |   }
634 | 
635 |   /** start a new node. Any new tokens or nodes will be put into it's children list from that point. Each call to this should be paired with a [completeNode] */
636 |   function startNode() {
637 |     parents.push(node);
638 |     node = {
639 |       children: [],
640 |     };
641 |   }
642 | 
643 |   function completeNode(type: SyntaxKind): Node {
644 |     const completedNode = createNode(type, node.children!);
645 |     const parentNode = parents[parents.length - 1]!;
646 | 
647 |     parentNode.children!.push(completedNode);
648 | 
649 |     node = parentNode;
650 |     parents.pop();
651 |     return completedNode;
652 |   }
653 | 
654 |   function collectToken(inContent: boolean): Node {
655 |     let kind: SyntaxKind;
656 |     let triviaCollected: Node[] = [];
657 |     let start: number | null = null;
658 |     while (true) {
659 |       kind = scanner.scan();
660 |       if (start === null) {
661 |         start = scanner.getTokenStart();
662 |       }
663 |       //handle error from scanner
664 |       if (errFromScanner !== undefined) {
665 |         let err: GeneralDiagnosticMessage;
666 |         if (errFromScanner.message.code === ErrCodes.invalidChar) {
667 |           err = DIAGS.invalidChar(scanner.getTokenText());
668 |         } else {
669 |           err = errFromScanner.message;
670 |         }
671 | 
672 |         const pos = scanner.getTokenStart();
673 |         const triviaBefore = triviaCollected.length > 0 ? triviaCollected : undefined;
674 | 
675 |         triviaCollected = [];
676 |         if (inContent && err.code === ErrCodes.invalidChar) {
677 |           errFromScanner = undefined;
678 |           return new Node(kind, pos, scanner.getTokenEnd(), triviaBefore);
679 |         }
680 | 
681 |         const badPrefixEnd = pos + errFromScanner.prefixLength;
682 |         const token = new Node(kind, pos, badPrefixEnd, triviaBefore);
683 | 
684 |         scanner.resetTokenState(badPrefixEnd);
685 |         startNode();
686 |         node.children!.push(token);
687 | 
688 |         const { contextPos, contextEnd } = getContextWithSurroundingLines(pos, badPrefixEnd, 0);
689 |         errors.push({
690 |           category: err.category,
691 |           code: err.code,
692 |           message: err.message,
693 |           pos,
694 |           end: badPrefixEnd,
695 |           contextPos,
696 |           contextEnd,
697 |         });
698 |         completeNode(SyntaxKind.ErrorNode);
699 | 
700 |         errFromScanner = undefined;
701 |         return collectToken(inContent);
702 |       }
703 | 
704 |       switch (kind) {
705 |         case SyntaxKind.CommentTrivia:
706 |         case SyntaxKind.NewLineTrivia:
707 |         case SyntaxKind.WhitespaceTrivia:
708 |           triviaCollected.push(new Node(kind, scanner.getTokenStart(), scanner.getTokenEnd()));
709 |           break;
710 | 
711 |         default:
712 |           return new Node(
713 |             kind,
714 |             scanner.getTokenStart(),
715 |             scanner.getTokenEnd(),
716 |             triviaCollected.length > 0 ? triviaCollected : undefined,
717 |           );
718 |       }
719 |     }
720 |   }
721 | 
722 |   function abandonNode() {
723 |     const parentNode = parents[parents.length - 1];
724 |     parentNode!.children!.push(...node.children!);
725 |     node = parentNode;
726 |     parents.pop();
727 |   }
728 | }
729 | 
730 | function createNode(kind: SyntaxKind, children: Node[]): Node {
731 |   const firstChild = children[0];
732 |   const lastChild = children[children.length - 1];
733 |   return new Node(kind, firstChild.pos, lastChild.end, undefined, children);
734 | }
735 | 
```

--------------------------------------------------------------------------------
/xmlui/src/components/Redirect/Redirect.spec.ts:
--------------------------------------------------------------------------------

```typescript
  1 | import { test, expect } from "../../testing/fixtures";
  2 | 
  3 | // =============================================================================
  4 | // BASIC FUNCTIONALITY TESTS
  5 | // =============================================================================
  6 | 
  7 | test.describe("Basic Functionality", () => {
  8 |   test("redirects immediately when visible with 'to' property", async ({ initTestBed, page }) => {
  9 |     await initTestBed(`
 10 |       <App>
 11 |         <NavPanel>
 12 |           <NavLink to="/" label="Home" />
 13 |           <NavLink to="/target" label="Target" />
 14 |           <NavLink to="/redirect" label="Redirect" />
 15 |         </NavPanel>
 16 |         <Pages>
 17 |           <Page url="/">Home Page</Page>
 18 |           <Page url="/target">Target Page</Page>
 19 |           <Page url="/redirect">
 20 |             <Redirect to="/target" />
 21 |             <Text>This should not be visible</Text>
 22 |           </Page>
 23 |         </Pages>
 24 |       </App>
 25 |     `);
 26 | 
 27 |     // Navigate to the redirect page
 28 |     await page.getByRole("link", { name: "Redirect" }).click();
 29 |     
 30 |     // Should be redirected to target page immediately
 31 |     await expect(page).toHaveURL(/\/target$/);
 32 |     await expect(page.getByText("Target Page")).toBeVisible();
 33 |     await expect(page.getByText("This should not be visible")).not.toBeVisible();
 34 |   });
 35 | 
 36 |   test("redirects when 'when' property becomes true", async ({ initTestBed, page }) => {
 37 |     await initTestBed(`
 38 |       <App>
 39 |         <NavPanel>
 40 |           <NavLink to="/" label="Home" />
 41 |           <NavLink to="/target" label="Target" />
 42 |           <NavLink to="/conditional" label="Conditional" />
 43 |         </NavPanel>
 44 |         <Pages>
 45 |           <Page url="/">Home Page</Page>
 46 |           <Page url="/target">Target Page</Page>
 47 |           <Page url="/conditional">
 48 |             <Fragment var.shouldRedirect="{false}">
 49 |               <Button label="Redirect Now" onClick="shouldRedirect = true" />
 50 |               <Redirect when="{shouldRedirect}" to="/target" />
 51 |               <Text>Click button to redirect</Text>
 52 |             </Fragment>
 53 |           </Page>
 54 |         </Pages>
 55 |       </App>
 56 |     `);
 57 | 
 58 |     // Navigate to conditional page
 59 |     await page.getByRole("link", { name: "Conditional" }).click();
 60 |     await expect(page).toHaveURL(/\/conditional$/);
 61 |     await expect(page.getByText("Click button to redirect")).toBeVisible();
 62 | 
 63 |     // Click button to trigger redirect
 64 |     await page.getByRole("button", { name: "Redirect Now" }).click();
 65 |     
 66 |     // Should be redirected to target page
 67 |     await expect(page).toHaveURL(/\/target$/);
 68 |     await expect(page.getByText("Target Page")).toBeVisible();
 69 |   });
 70 | 
 71 |   test("does not redirect when 'when' property is false", async ({ initTestBed, page }) => {
 72 |     await initTestBed(`
 73 |       <App>
 74 |         <NavPanel>
 75 |           <NavLink to="/" label="Home" />
 76 |           <NavLink to="/target" label="Target" />
 77 |           <NavLink to="/no-redirect" label="No Redirect" />
 78 |         </NavPanel>
 79 |         <Pages>
 80 |           <Page url="/">Home Page</Page>
 81 |           <Page url="/target">Target Page</Page>
 82 |           <Page url="/no-redirect">
 83 |             <Redirect when="{false}" to="/target" />
 84 |             <Text>This should be visible</Text>
 85 |           </Page>
 86 |         </Pages>
 87 |       </App>
 88 |     `);
 89 | 
 90 |     // Navigate to no-redirect page
 91 |     await page.getByRole("link", { name: "No Redirect" }).click();
 92 |     
 93 |     // Should stay on current page (not redirect)
 94 |     await expect(page).toHaveURL(/\/no-redirect$/);
 95 |     await expect(page.getByText("This should be visible")).toBeVisible();
 96 |     await expect(page.getByText("Target Page")).not.toBeVisible();
 97 |   });
 98 | 
 99 |   test("redirects to absolute URLs", async ({ initTestBed, page }) => {
100 |     await initTestBed(`
101 |       <App>
102 |         <NavPanel>
103 |           <NavLink to="/" label="Home" />
104 |           <NavLink to="/redirect" label="Redirect" />
105 |         </NavPanel>
106 |         <Pages>
107 |           <Page url="/">Home Page</Page>
108 |           <Page url="/redirect">
109 |             <Redirect to="/accounts/123" />
110 |             <Text>Redirecting...</Text>
111 |           </Page>
112 |           <Page url="/accounts/123">Account 123 Page</Page>
113 |         </Pages>
114 |       </App>
115 |     `);
116 | 
117 |     // Navigate to redirect page
118 |     await page.getByRole("link", { name: "Redirect" }).click();
119 |     
120 |     // Should be redirected to absolute URL
121 |     await expect(page).toHaveURL(/\/accounts\/123$/);
122 |     await expect(page.getByText("Account 123 Page")).toBeVisible();
123 |   });
124 | 
125 |   test("redirects to relative URLs", async ({ initTestBed, page }) => {
126 |     await initTestBed(`
127 |       <App>
128 |         <NavPanel>
129 |           <NavLink to="/" label="Home" />
130 |           <NavLink to="/redirect" label="Redirect" />
131 |         </NavPanel>
132 |         <Pages>
133 |           <Page url="/">Home Page</Page>
134 |           <Page url="/redirect">
135 |             <Redirect to="/relative-target" />
136 |             <Text>Redirecting...</Text>
137 |           </Page>
138 |           <Page url="/relative-target">Relative Target Page</Page>
139 |         </Pages>
140 |       </App>
141 |     `);
142 | 
143 |     // Navigate to redirect page
144 |     await page.getByRole("link", { name: "Redirect" }).click();
145 |     
146 |     // Should be redirected to relative URL (using absolute path for reliability)
147 |     await expect(page).toHaveURL(/\/relative-target$/);
148 |     await expect(page.getByText("Relative Target Page")).toBeVisible();
149 |   });
150 | 
151 |   test("redirects with query parameters", async ({ initTestBed, page }) => {
152 |     await initTestBed(`
153 |       <App>
154 |         <NavPanel>
155 |           <NavLink to="/" label="Home" />
156 |           <NavLink to="/redirect" label="Redirect" />
157 |         </NavPanel>
158 |         <Pages>
159 |           <Page url="/">Home Page</Page>
160 |           <Page url="/redirect">
161 |             <Redirect to="/target?param=value&count=42" />
162 |             <Text>Redirecting...</Text>
163 |           </Page>
164 |           <Page url="/target">
165 |             <Text>Target with params: {$queryParams.param} - {$queryParams.count}</Text>
166 |           </Page>
167 |         </Pages>
168 |       </App>
169 |     `);
170 | 
171 |     // Navigate to redirect page
172 |     await page.getByRole("link", { name: "Redirect" }).click();
173 |     
174 |     // Should be redirected with query parameters
175 |     await expect(page).toHaveURL(/\/target\?param=value&count=42$/);
176 |     await expect(page.getByText("Target with params: value - 42")).toBeVisible();
177 |   });
178 | 
179 |   test("redirects with route parameters", async ({ initTestBed, page }) => {
180 |     await initTestBed(`
181 |       <App>
182 |         <NavPanel>
183 |           <NavLink to="/" label="Home" />
184 |           <NavLink to="/redirect" label="Redirect" />
185 |         </NavPanel>
186 |         <Pages>
187 |           <Page url="/">Home Page</Page>
188 |           <Page url="/redirect">
189 |             <Redirect to="/user/john/profile" />
190 |             <Text>Redirecting...</Text>
191 |           </Page>
192 |           <Page url="/user/:userId/profile">
193 |             <Text>User Profile: {$routeParams.userId}</Text>
194 |           </Page>
195 |         </Pages>
196 |       </App>
197 |     `);
198 | 
199 |     // Navigate to redirect page
200 |     await page.getByRole("link", { name: "Redirect" }).click();
201 |     
202 |     // Should be redirected with route parameters
203 |     await expect(page).toHaveURL(/\/user\/john\/profile$/);
204 |     await expect(page.getByText("User Profile: john")).toBeVisible();
205 |   });
206 | 
207 |   test("works with dynamic 'to' property", async ({ initTestBed, page }) => {
208 |     await initTestBed(`
209 |       <App>
210 |         <NavPanel>
211 |           <NavLink to="/" label="Home" />
212 |           <NavLink to="/dynamic" label="Dynamic" />
213 |         </NavPanel>
214 |         <Pages>
215 |           <Page url="/">Home Page</Page>
216 |           <Page url="/dynamic">
217 |             <Fragment var.destination="{'/page1'}">
218 |               <Button label="Go to Page 1" onClick="destination = '/page1'" />
219 |               <Button label="Go to Page 2" onClick="destination = '/page2'" />
220 |               <Button label="Redirect Now" onClick="destination = destination + '?from=dynamic'" />
221 |               <Redirect when="{destination.endsWith('?from=dynamic')}" to="{destination}" />
222 |               <Text>Choose destination and click redirect</Text>
223 |             </Fragment>
224 |           </Page>
225 |           <Page url="/page1">Page 1: {$queryParams.from}</Page>
226 |           <Page url="/page2">Page 2: {$queryParams.from}</Page>
227 |         </Pages>
228 |       </App>
229 |     `);
230 | 
231 |     // Navigate to dynamic page
232 |     await page.getByRole("link", { name: "Dynamic" }).click();
233 |     await expect(page).toHaveURL(/\/dynamic$/);
234 | 
235 |     // Set destination to page2
236 |     await page.getByRole("button", { name: "Go to Page 2" }).click();
237 |     
238 |     // Trigger redirect
239 |     await page.getByRole("button", { name: "Redirect Now" }).click();
240 |     
241 |     // Should be redirected to page2 with query parameter
242 |     await expect(page).toHaveURL(/\/page2\?from=dynamic$/);
243 |     await expect(page.getByText("Page 2: dynamic")).toBeVisible();
244 |   });
245 | 
246 |   test("handles empty 'to' property gracefully", async ({ initTestBed, page }) => {
247 |     await initTestBed(`
248 |       <App>
249 |         <NavPanel>
250 |           <NavLink to="/" label="Home" />
251 |           <NavLink to="/empty-redirect" label="Empty Redirect" />
252 |         </NavPanel>
253 |         <Pages>
254 |           <Page url="/">Home Page</Page>
255 |           <Page url="/empty-redirect">
256 |             <Redirect to="" />
257 |             <Text>This should be visible since redirect is empty</Text>
258 |           </Page>
259 |         </Pages>
260 |       </App>
261 |     `);
262 | 
263 |     // Navigate to empty redirect page
264 |     await page.getByRole("link", { name: "Empty Redirect" }).click();
265 |     
266 |     // Should stay on current page since 'to' is empty
267 |     await expect(page).toHaveURL(/\/empty-redirect$/);
268 |     await expect(page.getByText("This should be visible since redirect is empty")).toBeVisible();
269 |   });
270 | 
271 |   test("can coexist with other content on the page", async ({ initTestBed, page }) => {
272 |     await initTestBed(`
273 |       <App>
274 |         <NavPanel>
275 |           <NavLink to="/" label="Home" />
276 |           <NavLink to="/mixed" label="Mixed Content" />
277 |         </NavPanel>
278 |         <Pages>
279 |           <Page url="/">Home Page</Page>
280 |           <Page url="/mixed">
281 |             <VStack>
282 |               <Text>Before redirect</Text>
283 |               <Redirect when="{false}" to="/target" />
284 |               <Text>After redirect</Text>
285 |             </VStack>
286 |           </Page>
287 |           <Page url="/target">Target Page</Page>
288 |         </Pages>
289 |       </App>
290 |     `);
291 | 
292 |     // Navigate to mixed content page
293 |     await page.getByRole("link", { name: "Mixed Content" }).click();
294 |     
295 |     // Should stay on current page and show all content
296 |     await expect(page).toHaveURL(/\/mixed$/);
297 |     await expect(page.getByText("Before redirect")).toBeVisible();
298 |     await expect(page.getByText("After redirect")).toBeVisible();
299 |   });
300 | });
301 | 
302 | // =============================================================================
303 | // ACCESSIBILITY TESTS
304 | // =============================================================================
305 | 
306 | test.describe("Accessibility", () => {
307 |   test("is a non-visual component that doesn't affect screen readers", async ({ initTestBed, page }) => {
308 |     await initTestBed(`
309 |       <App>
310 |         <NavPanel>
311 |           <NavLink to="/" label="Home" />
312 |           <NavLink to="/accessible" label="Accessible" />
313 |         </NavPanel>
314 |         <Pages>
315 |           <Page url="/">Home Page</Page>
316 |           <Page url="/accessible">
317 |             <VStack>
318 |               <Text>Visible content before</Text>
319 |               <Redirect when="{false}" to="/target" />
320 |               <Text>Visible content after</Text>
321 |             </VStack>
322 |           </Page>
323 |         </Pages>
324 |       </App>
325 |     `);
326 | 
327 |     // Navigate to page with redirect
328 |     await page.getByRole("link", { name: "Accessible" }).click();
329 |     
330 |     // Check that visible content is accessible
331 |     await expect(page.getByText("Visible content before")).toBeVisible();
332 |     await expect(page.getByText("Visible content after")).toBeVisible();
333 |     
334 |     // The redirect component itself should not be visible or interact with accessibility tools
335 |     await expect(page.getByText("Redirect")).not.toBeVisible();
336 |   });
337 | 
338 |   test("preserves navigation context for screen readers", async ({ initTestBed, page }) => {
339 |     await initTestBed(`
340 |       <App>
341 |         <NavPanel>
342 |           <NavLink to="/" label="Home" />
343 |           <NavLink to="/redirect" label="Redirect to Target" />
344 |         </NavPanel>
345 |         <Pages>
346 |           <Page url="/">Home Page</Page>
347 |           <Page url="/redirect">
348 |             <Redirect to="/target" />
349 |             <Text>Loading...</Text>
350 |           </Page>
351 |           <Page url="/target">
352 |             <Heading level="h1">Target Page</Heading>
353 |             <Text>You have been redirected here</Text>
354 |           </Page>
355 |         </Pages>
356 |       </App>
357 |     `);
358 | 
359 |     // Navigate via the navigation link
360 |     await page.getByRole("link", { name: "Redirect to Target" }).click();
361 |     
362 |     // Should be redirected and have proper heading structure
363 |     await expect(page).toHaveURL(/\/target$/);
364 |     await expect(page.getByRole("heading", { level: 1, name: "Target Page" })).toBeVisible();
365 |     await expect(page.getByText("You have been redirected here")).toBeVisible();
366 |   });
367 | });
368 | 
369 | // =============================================================================
370 | // OTHER EDGE CASES
371 | // =============================================================================
372 | 
373 | test.describe("Other Edge Cases", () => {
374 |   test("handles multiple redirects on the same page", async ({ initTestBed, page }) => {
375 |     await initTestBed(`
376 |       <App>
377 |         <NavPanel>
378 |           <NavLink to="/" label="Home" />
379 |           <NavLink to="/multiple" label="Multiple" />
380 |         </NavPanel>
381 |         <Pages>
382 |           <Page url="/">Home Page</Page>
383 |           <Page url="/multiple">
384 |             <Fragment var.condition="{1}">
385 |               <Button label="Set to 1" onClick="condition = 1" />
386 |               <Button label="Set to 2" onClick="condition = 2" />
387 |               <Redirect when="{condition === 1}" to="/target1" />
388 |               <Redirect when="{condition === 2}" to="/target2" />
389 |               <Text>Multiple redirects: {condition}</Text>
390 |             </Fragment>
391 |           </Page>
392 |           <Page url="/target1">Target 1 Page</Page>
393 |           <Page url="/target2">Target 2 Page</Page>
394 |         </Pages>
395 |       </App>
396 |     `);
397 | 
398 |     // Navigate to multiple redirects page
399 |     await page.getByRole("link", { name: "Multiple" }).click();
400 |     
401 |     // Should redirect to target1 immediately (condition starts as 1)
402 |     await expect(page).toHaveURL(/\/target1$/);
403 |     await expect(page.getByText("Target 1 Page")).toBeVisible();
404 |   });
405 | 
406 |   test("works with complex conditional logic", async ({ initTestBed, page }) => {
407 |     await initTestBed(`
408 |       <App>
409 |         <NavPanel>
410 |           <NavLink to="/" label="Home" />
411 |           <NavLink to="/complex" label="Complex" />
412 |         </NavPanel>
413 |         <Pages>
414 |           <Page url="/">Home Page</Page>
415 |           <Page url="/complex">
416 |             <Fragment var.user="{{name: 'john', role: 'admin'}}">
417 |               <Button label="Make User" onClick="user.role = 'user'" />
418 |               <Button label="Make Admin" onClick="user.role = 'admin'" />
419 |               <Redirect when="{user.role === 'admin'}" to="/admin-dashboard" />
420 |               <Redirect when="{user.role === 'user'}" to="/user-dashboard" />
421 |               <Text>User: {user.name} ({user.role})</Text>
422 |             </Fragment>
423 |           </Page>
424 |           <Page url="/admin-dashboard">Admin Dashboard</Page>
425 |           <Page url="/user-dashboard">User Dashboard</Page>
426 |         </Pages>
427 |       </App>
428 |     `);
429 | 
430 |     // Navigate to complex page
431 |     await page.getByRole("link", { name: "Complex" }).click();
432 |     
433 |     // Should redirect to admin dashboard (user starts as admin)
434 |     await expect(page).toHaveURL(/\/admin-dashboard$/);
435 |     await expect(page.getByText("Admin Dashboard")).toBeVisible();
436 |   });
437 | 
438 |   test("handles special characters in URLs", async ({ initTestBed, page }) => {
439 |     await initTestBed(`
440 |       <App>
441 |         <NavPanel>
442 |           <NavLink to="/" label="Home" />
443 |           <NavLink to="/special" label="Special" />
444 |         </NavPanel>
445 |         <Pages>
446 |           <Page url="/">Home Page</Page>
447 |           <Page url="/special">
448 |             <Redirect to="/target-with-dashes-and-underscores_test" />
449 |             <Text>Redirecting...</Text>
450 |           </Page>
451 |           <Page url="/target-with-dashes-and-underscores_test">
452 |             <Text>Special URL Target</Text>
453 |           </Page>
454 |         </Pages>
455 |       </App>
456 |     `);
457 | 
458 |     // Navigate to special characters page
459 |     await page.getByRole("link", { name: "Special" }).click();
460 |     
461 |     // Should handle dashes and underscores in URL
462 |     await expect(page).toHaveURL(/\/target-with-dashes-and-underscores_test$/);
463 |     await expect(page.getByText("Special URL Target")).toBeVisible();
464 |   });
465 | 
466 |   test("works within nested components", async ({ initTestBed, page }) => {
467 |     await initTestBed(`
468 |       <App>
469 |         <NavPanel>
470 |           <NavLink to="/" label="Home" />
471 |           <NavLink to="/nested" label="Nested" />
472 |         </NavPanel>
473 |         <Pages>
474 |           <Page url="/">Home Page</Page>
475 |           <Page url="/nested">
476 |             <VStack>
477 |               <Card title="Card with Redirect">
478 |                 <VStack>
479 |                   <Text>Inside a card</Text>
480 |                   <Fragment var.shouldRedirect="{false}">
481 |                     <Button label="Redirect from Card" onClick="shouldRedirect = true" />
482 |                     <Redirect when="{shouldRedirect}" to="/target" />
483 |                   </Fragment>
484 |                 </VStack>
485 |               </Card>
486 |             </VStack>
487 |           </Page>
488 |           <Page url="/target">Target from Nested</Page>
489 |         </Pages>
490 |       </App>
491 |     `);
492 | 
493 |     // Navigate to nested page
494 |     await page.getByRole("link", { name: "Nested" }).click();
495 |     await expect(page).toHaveURL(/\/nested$/);
496 |     
497 |     // Click button inside nested component
498 |     await page.getByRole("button", { name: "Redirect from Card" }).click();
499 |     
500 |     // Should redirect from nested context
501 |     await expect(page).toHaveURL(/\/target$/);
502 |     await expect(page.getByText("Target from Nested")).toBeVisible();
503 |   });
504 | 
505 |   test("maintains browser history properly", async ({ initTestBed, page }) => {
506 |     await initTestBed(`
507 |       <App>
508 |         <NavPanel>
509 |           <NavLink to="/" label="Home" />
510 |           <NavLink to="/step1" label="Step 1" />
511 |           <NavLink to="/redirect-test" label="Redirect Test" />
512 |         </NavPanel>
513 |         <Pages>
514 |           <Page url="/">Home Page</Page>
515 |           <Page url="/step1">Step 1 Page</Page>
516 |           <Page url="/redirect-test">
517 |             <Redirect to="/final" />
518 |             <Text>Redirecting...</Text>
519 |           </Page>
520 |           <Page url="/final">Final Page</Page>
521 |         </Pages>
522 |       </App>
523 |     `);
524 | 
525 |     // Start at home
526 |     await expect(page).toHaveURL(/\/$|#\/$/);
527 |     
528 |     // Navigate to step1 first to establish history
529 |     await page.getByRole("link", { name: "Step 1" }).click();
530 |     await expect(page).toHaveURL(/\/step1$/);
531 |     
532 |     // Then navigate to redirect test (which redirects to final)
533 |     await page.getByRole("link", { name: "Redirect Test" }).click();
534 |     await expect(page).toHaveURL(/\/final$/);
535 |     await expect(page.getByText("Final Page")).toBeVisible();
536 |     
537 |     // Test that browser navigation history exists and functions
538 |     // The exact behavior may vary, but history should be maintained
539 |     await page.goBack();
540 |     
541 |     // We should be able to navigate in history (exact destination may vary due to redirects)
542 |     // The key is that history navigation works and doesn't break the app
543 |     const currentUrl = page.url();
544 |     expect(currentUrl).toMatch(/(step1|final|redirect-test)/);
545 |   });
546 | 
547 |   test("handles null/undefined 'to' values gracefully", async ({ initTestBed, page }) => {
548 |     await initTestBed(`
549 |       <App>
550 |         <NavPanel>
551 |           <NavLink to="/" label="Home" />
552 |           <NavLink to="/null-redirect" label="Null Redirect" />
553 |         </NavPanel>
554 |         <Pages>
555 |           <Page url="/">Home Page</Page>
556 |           <Page url="/null-redirect">
557 |             <Fragment var.destination="{null}">
558 |               <Button label="Set Null" onClick="destination = null" />
559 |               <Button label="Set Undefined" onClick="destination = undefined" />
560 |               <Button label="Set Valid" onClick="destination = '/target'" />
561 |               <Redirect when="{destination}" to="{destination}" />
562 |               <Text>Destination: {destination || 'none'}</Text>
563 |             </Fragment>
564 |           </Page>
565 |           <Page url="/target">Target Page</Page>
566 |         </Pages>
567 |       </App>
568 |     `);
569 | 
570 |     // Navigate to null redirect page
571 |     await page.getByRole("link", { name: "Null Redirect" }).click();
572 |     await expect(page).toHaveURL(/\/null-redirect$/);
573 |     
574 |     // Should show content without redirecting
575 |     await expect(page.getByText("Destination: none")).toBeVisible();
576 |     
577 |     // Set valid destination and redirect should work
578 |     await page.getByRole("button", { name: "Set Valid" }).click();
579 |     await expect(page).toHaveURL(/\/target$/);
580 |     await expect(page.getByText("Target Page")).toBeVisible();
581 |   });
582 | });
583 | 
```

--------------------------------------------------------------------------------
/xmlui/src/components/Option/Option.spec.ts:
--------------------------------------------------------------------------------

```typescript
  1 | import { test, expect } from "../../testing/fixtures";
  2 | 
  3 | // =============================================================================
  4 | // BASIC FUNCTIONALITY TESTS
  5 | // =============================================================================
  6 | 
  7 | test.describe("Basic Functionality", () => {
  8 |   test("renders with both label and value properties", async ({
  9 |     initTestBed,
 10 |     page,
 11 |     createSelectDriver,
 12 |   }) => {
 13 |     await initTestBed(`
 14 |       <Select>
 15 |         <Option label="Display Text" value="stored_value" />
 16 |       </Select>
 17 |     `);
 18 | 
 19 |     const driver = await createSelectDriver();
 20 |     await driver.toggleOptionsVisibility();
 21 |     const option = page.getByRole("option", { name: "Display Text" });
 22 |     await expect(option).toBeVisible();
 23 |   });
 24 | 
 25 |   test("renders with only label property (uses label as value)", async ({
 26 |     initTestBed,
 27 |     page,
 28 |     createSelectDriver,
 29 |   }) => {
 30 |     await initTestBed(`
 31 |       <Select>
 32 |         <Option label="Display Text" />
 33 |       </Select>
 34 |     `);
 35 | 
 36 |     const driver = await createSelectDriver();
 37 |     await driver.toggleOptionsVisibility();
 38 |     const option = page.getByRole("option", { name: "Display Text" });
 39 |     await expect(option).toBeVisible();
 40 |   });
 41 | 
 42 |   test("renders with only value property (uses value as label)", async ({
 43 |     initTestBed,
 44 |     page,
 45 |     createSelectDriver,
 46 |   }) => {
 47 |     await initTestBed(`
 48 |       <Select>
 49 |         <Option value="display_value" />
 50 |         <Option label="Control Option" value="control" />
 51 |       </Select>
 52 |     `);
 53 | 
 54 |     const driver = await createSelectDriver();
 55 |     await driver.toggleOptionsVisibility();
 56 | 
 57 |     // The option with only value should render (may display as empty)
 58 |     await expect(page.getByRole("option")).toHaveCount(2);
 59 |     await expect(page.getByRole("option").first()).toBeVisible();
 60 |     await expect(page.getByRole("option", { name: "Control Option" })).toBeVisible();
 61 |   });
 62 | 
 63 |   test("does not render when neither label nor value is provided", async ({
 64 |     initTestBed,
 65 |     page,
 66 |     createSelectDriver,
 67 |   }) => {
 68 |     await initTestBed(`
 69 |       <Select>
 70 |         <Option />
 71 |         <Option label="Visible Option" value="visible" />
 72 |       </Select>
 73 |     `);
 74 | 
 75 |     const driver = await createSelectDriver();
 76 |     await driver.toggleOptionsVisibility();
 77 |     // Should only see the valid option
 78 |     await expect(page.getByRole("option")).toHaveCount(1);
 79 |     await expect(page.getByRole("option", { name: "Visible Option" })).toBeVisible();
 80 |   });
 81 | 
 82 |   test("enabled property defaults to true", async ({ initTestBed, page, createSelectDriver }) => {
 83 |     await initTestBed(`
 84 |       <Select>
 85 |         <Option label="Default Option" value="default" />
 86 |       </Select>
 87 |     `);
 88 | 
 89 |     const driver = await createSelectDriver();
 90 |     await driver.toggleOptionsVisibility();
 91 |     const option = page.getByRole("option", { name: "Default Option" });
 92 |     await expect(option).toBeVisible();
 93 |     await expect(option).not.toHaveAttribute("aria-disabled", "true");
 94 |   });
 95 | 
 96 |   test("enabled set to true", async ({ initTestBed, page, createSelectDriver }) => {
 97 |     await initTestBed(`
 98 |       <Select>
 99 |         <Option label="Enabled Option" value="enabled" enabled="{true}" />
100 |       </Select>
101 |     `);
102 | 
103 |     const driver = await createSelectDriver();
104 |     await driver.toggleOptionsVisibility();
105 |     const option = page.getByRole("option", { name: "Enabled Option" });
106 |     await expect(option).toBeVisible();
107 |     await expect(option).not.toHaveAttribute("aria-disabled", "true");
108 |   });
109 | 
110 |   test("enabled set to false", async ({ initTestBed, page, createSelectDriver }) => {
111 |     await initTestBed(`
112 |       <Select>
113 |         <Option label="Disabled Option" value="disabled" enabled="{false}" />
114 |         <Option label="Enabled Option" value="enabled" enabled="{true}" />
115 |       </Select>
116 |     `);
117 | 
118 |     const driver = await createSelectDriver();
119 |     await driver.toggleOptionsVisibility();
120 | 
121 |     const disabledOption = page.getByRole("option", { name: "Disabled Option" });
122 |     const enabledOption = page.getByRole("option", { name: "Enabled Option" });
123 | 
124 |     await expect(disabledOption).toBeVisible();
125 |     await expect(disabledOption).toHaveAttribute("aria-disabled", "true");
126 |     await expect(enabledOption).toBeVisible();
127 |     await expect(enabledOption).not.toHaveAttribute("aria-disabled", "true");
128 |   });
129 | 
130 |   test("supports text node children as label", async ({
131 |     initTestBed,
132 |     page,
133 |     createSelectDriver,
134 |   }) => {
135 |     await initTestBed(`
136 |       <Select>
137 |         <Option value="text_node">Text Node Label</Option>
138 |       </Select>
139 |     `);
140 | 
141 |     const driver = await createSelectDriver();
142 |     await driver.toggleOptionsVisibility();
143 |     const option = page.getByRole("option", { name: "Text Node Label" });
144 |     await expect(option).toBeVisible();
145 |   });
146 | 
147 |   test("supports rich content as children", async ({ initTestBed, page, createSelectDriver }) => {
148 |     await initTestBed(`
149 |       <Select>
150 |         <Option value="rich_content">
151 |           <HStack gap="$space-small">
152 |             <Icon name="user" />
153 |             <Text>Rich Content</Text>
154 |           </HStack>
155 |         </Option>
156 |       </Select>
157 |     `);
158 | 
159 |     const driver = await createSelectDriver();
160 |     await driver.toggleOptionsVisibility();
161 |     const option = page.getByRole("option");
162 |     await expect(option).toBeVisible();
163 |     await expect(option.locator("text=Rich Content")).toBeVisible();
164 |   });
165 | 
166 |   test("label property takes precedence over text node children", async ({
167 |     initTestBed,
168 |     page,
169 |     createSelectDriver,
170 |   }) => {
171 |     await initTestBed(`
172 |       <Select>
173 |         <Option label="Label Property" value="precedence">Text Node Content</Option>
174 |       </Select>
175 |     `);
176 | 
177 |     const driver = await createSelectDriver();
178 |     await driver.toggleOptionsVisibility();
179 |     const option = page.getByRole("option", { name: "Label Property" });
180 |     await expect(option).toBeVisible();
181 |     // Text node should not be visible since label takes precedence
182 |     await expect(page.getByRole("option", { name: "Text Node Content" })).not.toBeVisible();
183 |   });
184 | 
185 |   test("works within Select component for selection", async ({
186 |     initTestBed,
187 |     page,
188 |     createSelectDriver,
189 |   }) => {
190 |     const { testStateDriver } = await initTestBed(`
191 |       <Fragment>
192 |         <Select id="testSelect" onDidChange="arg => testState = arg">
193 |           <Option label="First" value="1" />
194 |           <Option label="Second" value="2" />
195 |         </Select>
196 |       </Fragment>
197 |     `);
198 | 
199 |     const driver = await createSelectDriver("testSelect");
200 |     await driver.toggleOptionsVisibility();
201 |     await driver.selectLabel("Second");
202 | 
203 |     await expect.poll(testStateDriver.testState).toEqual("2");
204 |   });
205 | 
206 |   test("works within AutoComplete component for selection", async ({ initTestBed, page }) => {
207 |     const { testStateDriver } = await initTestBed(`
208 |       <Fragment>
209 |         <AutoComplete id="testAutoComplete" onDidChange="arg => testState = arg">
210 |           <Option label="Apple" value="apple" />
211 |           <Option label="Banana" value="banana" />
212 |         </AutoComplete>
213 |       </Fragment>
214 |     `);
215 | 
216 |     const autocomplete = page.getByRole("combobox");
217 |     await autocomplete.click();
218 | 
219 |     const appleOption = page.getByRole("option", { name: "Apple" });
220 |     await appleOption.click();
221 | 
222 |     await expect.poll(testStateDriver.testState).toEqual("apple");
223 |   });
224 | 
225 |   test("works within RadioGroup component for selection", async ({ initTestBed, page }) => {
226 |     const { testStateDriver } = await initTestBed(`
227 |       <Fragment>
228 |         <RadioGroup id="testRadioGroup" onDidChange="arg => testState = arg">
229 |           <VStack>
230 |             <Option label="Option A" value="a" />
231 |             <Option label="Option B" value="b" />
232 |           </VStack>
233 |         </RadioGroup>
234 |       </Fragment>
235 |     `);
236 | 
237 |     const optionB = page.getByRole("radio", { name: "Option B" });
238 |     await optionB.click();
239 | 
240 |     await expect.poll(testStateDriver.testState).toEqual("b");
241 |   });
242 | 
243 |   test("handles numeric values correctly", async ({ initTestBed, page, createSelectDriver }) => {
244 |     const { testStateDriver } = await initTestBed(`
245 |       <Fragment>
246 |         <Select id="numericSelect" onDidChange="arg => testState = arg">
247 |           <Option label="Zero" value="{0}" />
248 |           <Option label="Forty Two" value="{42}" />
249 |           <Option label="Negative" value="{-1}" />
250 |         </Select>
251 |       </Fragment>
252 |     `);
253 | 
254 |     const driver = await createSelectDriver("numericSelect");
255 |     await driver.toggleOptionsVisibility();
256 |     await driver.selectLabel("Forty Two");
257 | 
258 |     // Values from Select are returned as strings
259 |     await expect.poll(testStateDriver.testState).toEqual(42);
260 |   });
261 | 
262 |   test("handles boolean values correctly", async ({ initTestBed, page, createSelectDriver }) => {
263 |     const { testStateDriver } = await initTestBed(`
264 |       <Fragment>
265 |         <Select id="booleanSelect" onDidChange="arg => testState = arg">
266 |           <Option label="True" value="{true}" />
267 |           <Option label="False" value="{false}" />
268 |         </Select>
269 |       </Fragment>
270 |     `);
271 | 
272 |     const driver = await createSelectDriver("booleanSelect");
273 |     await driver.toggleOptionsVisibility();
274 |     await driver.selectLabel("False");
275 | 
276 |     // Values from Select are returned as strings
277 |     await expect.poll(testStateDriver.testState).toEqual(false);
278 |   });
279 | 
280 |   test("works with dynamic data through Items component", async ({
281 |     initTestBed,
282 |     page,
283 |     createSelectDriver,
284 |   }) => {
285 |     const { testStateDriver } = await initTestBed(`
286 |       <Fragment>
287 |         <Select id="dynamicSelect" onDidChange="arg => testState = arg">
288 |           <Items data="{['apple', 'banana', 'cherry']}">
289 |             <Option label="{$item}" value="{$itemIndex}" />
290 |           </Items>
291 |         </Select>
292 |       </Fragment>
293 |     `);
294 | 
295 |     const driver = await createSelectDriver("dynamicSelect");
296 |     await driver.toggleOptionsVisibility();
297 | 
298 |     await expect(page.getByRole("option", { name: "apple" })).toBeVisible();
299 |     await expect(page.getByRole("option", { name: "banana" })).toBeVisible();
300 |     await expect(page.getByRole("option", { name: "cherry" })).toBeVisible();
301 | 
302 |     await driver.selectLabel("banana");
303 |     // Values from Select are returned as strings
304 |     await expect.poll(testStateDriver.testState).toEqual(1);
305 |   });
306 | 
307 |   test("handles empty string values", async ({ initTestBed, page, createSelectDriver }) => {
308 |     const { testStateDriver } = await initTestBed(`
309 |       <Fragment>
310 |         <Select id="emptySelect" onDidChange="arg => testState = arg">
311 |           <Option label="Empty String" value="" />
312 |           <Option label="Space" value=" " />
313 |         </Select>
314 |       </Fragment>
315 |     `);
316 | 
317 |     const driver = await createSelectDriver("emptySelect");
318 |     await driver.toggleOptionsVisibility();
319 | 
320 |     await expect(page.getByRole("option", { name: "Empty String" })).toBeVisible();
321 |     await expect(page.getByRole("option", { name: "Space" })).toBeVisible();
322 | 
323 |     await driver.selectLabel("Empty String");
324 |     // When value is empty string, Select may return the label instead
325 |     const result = await testStateDriver.testState();
326 |     expect(result === "Empty String").toBe(true);
327 |   });
328 | 
329 |   test("handles null values", async ({ initTestBed, page, createSelectDriver }) => {
330 |     const { testStateDriver } = await initTestBed(`
331 |       <Fragment>
332 |         <Select id="emptySelect" onDidChange="arg => testState = arg">
333 |           <Option label="Empty String" value="{null}" />
334 |           <Option label="Space" value=" " />
335 |         </Select>
336 |       </Fragment>
337 |     `);
338 | 
339 |     const driver = await createSelectDriver("emptySelect");
340 |     await driver.toggleOptionsVisibility();
341 | 
342 |     await expect(page.getByRole("option", { name: "Empty String" })).toBeVisible();
343 |     await expect(page.getByRole("option", { name: "Space" })).toBeVisible();
344 | 
345 |     await driver.selectLabel("Empty String");
346 |     // When value is empty string, Select may return the label instead
347 |     const result = await testStateDriver.testState();
348 |     expect(result).toBe(null);
349 |   });
350 | });
351 | 
352 | // =============================================================================
353 | // ACCESSIBILITY TESTS
354 | // =============================================================================
355 | 
356 | test.describe("Accessibility", () => {
357 |   test("has correct option role within Select", async ({
358 |     initTestBed,
359 |     page,
360 |     createSelectDriver,
361 |   }) => {
362 |     await initTestBed(`
363 |       <Select>
364 |         <Option label="Test Option" value="test" />
365 |       </Select>
366 |     `);
367 | 
368 |     const driver = await createSelectDriver();
369 |     await driver.toggleOptionsVisibility();
370 |     const option = page.getByRole("option", { name: "Test Option" });
371 |     await expect(option).toBeVisible();
372 |   });
373 | 
374 |   test("has correct radio role within RadioGroup", async ({ initTestBed, page }) => {
375 |     await initTestBed(`
376 |       <RadioGroup>
377 |         <Option label="Test Option" value="test" />
378 |       </RadioGroup>
379 |     `);
380 | 
381 |     const radio = page.getByRole("radio", { name: "Test Option" });
382 |     await expect(radio).toBeVisible();
383 |   });
384 | 
385 |   test("disabled option has correct aria-disabled attribute", async ({
386 |     initTestBed,
387 |     page,
388 |     createSelectDriver,
389 |   }) => {
390 |     await initTestBed(`
391 |       <Select>
392 |         <Option label="Disabled Option" value="disabled" enabled="{false}" />
393 |       </Select>
394 |     `);
395 | 
396 |     const driver = await createSelectDriver();
397 |     await driver.toggleOptionsVisibility();
398 |     const option = page.getByRole("option", { name: "Disabled Option" });
399 |     await expect(option).toHaveAttribute("aria-disabled", "true");
400 |   });
401 | 
402 |   test("enabled option does not have aria-disabled attribute", async ({
403 |     initTestBed,
404 |     page,
405 |     createSelectDriver,
406 |   }) => {
407 |     await initTestBed(`
408 |       <Select>
409 |         <Option label="Enabled Option" value="enabled" enabled="{true}" />
410 |       </Select>
411 |     `);
412 | 
413 |     const driver = await createSelectDriver();
414 |     await driver.toggleOptionsVisibility();
415 |     const option = page.getByRole("option", { name: "Enabled Option" });
416 |     await expect(option).not.toHaveAttribute("aria-disabled", "true");
417 |   });
418 | 
419 |   test("supports keyboard navigation within Select", async ({
420 |     initTestBed,
421 |     page,
422 |     createSelectDriver,
423 |   }) => {
424 |     const { testStateDriver } = await initTestBed(`
425 |       <Fragment>
426 |         <Select id="keyboardSelect" onDidChange="arg => testState = arg">
427 |           <Option label="First Option" value="1" />
428 |           <Option label="Second Option" value="2" />
429 |           <Option label="Third Option" value="3" />
430 |         </Select>
431 |       </Fragment>
432 |     `);
433 | 
434 |     const driver = await createSelectDriver("keyboardSelect");
435 | 
436 |     // Start by clicking to open the dropdown and focus on first option
437 |     await driver.component.click();
438 |     await page.waitForTimeout(200);
439 | 
440 |     // Navigate down to third option step by step with longer waits
441 |     await page.keyboard.press("ArrowDown");
442 |     await page.waitForTimeout(200);
443 |     await page.keyboard.press("ArrowDown");
444 |     await page.waitForTimeout(200);
445 |     await page.keyboard.press("ArrowDown");
446 |     await page.waitForTimeout(200);
447 | 
448 |     // Select with Enter
449 |     await page.keyboard.press("Enter");
450 |     await page.waitForTimeout(200);
451 | 
452 |     await expect.poll(testStateDriver.testState).toEqual("3");
453 |   });
454 | 
455 |   test("supports keyboard navigation within RadioGroup", async ({ initTestBed, page }) => {
456 |     const { testStateDriver } = await initTestBed(`
457 |       <Fragment>
458 |         <RadioGroup id="keyboardRadio" onDidChange="arg => testState = arg">
459 |           <VStack>
460 |             <Option label="First Option" value="1" />
461 |             <Option label="Second Option" value="2" />
462 |             <Option label="Third Option" value="3" />
463 |           </VStack>
464 |         </RadioGroup>
465 |       </Fragment>
466 |     `);
467 | 
468 |     const firstRadio = page.getByRole("radio", { name: "First Option" });
469 |     await firstRadio.focus();
470 |     await firstRadio.click(); // Start with a selection
471 |     await page.waitForTimeout(100);
472 | 
473 |     // Navigate with arrow keys
474 |     await page.keyboard.press("ArrowDown");
475 |     await page.waitForTimeout(100);
476 |     await page.keyboard.press("ArrowDown");
477 |     await page.waitForTimeout(100);
478 | 
479 |     await expect.poll(testStateDriver.testState).toEqual("3");
480 |   });
481 | });
482 | 
483 | // =============================================================================
484 | // OTHER EDGE CASE TESTS
485 | // =============================================================================
486 | 
487 | test.describe("Other Edge Cases", () => {
488 |   test("handles long unicode characters in label", async ({
489 |     initTestBed,
490 |     page,
491 |     createSelectDriver,
492 |   }) => {
493 |     await initTestBed(`
494 |       <Select>
495 |         <Option label="Family: 👨‍👩‍👧‍👦" value="family" />
496 |         <Option label="Chinese: 你好世界" value="chinese" />
497 |       </Select>
498 |     `);
499 | 
500 |     const driver = await createSelectDriver();
501 |     await driver.toggleOptionsVisibility();
502 | 
503 |     await expect(page.getByRole("option", { name: "Family: 👨‍👩‍👧‍👦" })).toBeVisible();
504 |     await expect(page.getByRole("option", { name: "Chinese: 你好世界" })).toBeVisible();
505 |   });
506 | 
507 |   test("handles very long label text", async ({ initTestBed, page, createSelectDriver }) => {
508 |     const longText = "A".repeat(100); // Reduced from 500 to be more reasonable
509 |     await initTestBed(`
510 |       <Select>
511 |         <Option label="${longText}" value="long" />
512 |       </Select>
513 |     `);
514 | 
515 |     const driver = await createSelectDriver();
516 |     await driver.toggleOptionsVisibility();
517 |     const option = page.getByRole("option", { name: longText });
518 |     await expect(option).toBeVisible();
519 |   });
520 | 
521 |   test("handles enabled as string value", async ({ initTestBed, page, createSelectDriver }) => {
522 |     await initTestBed(`
523 |       <Select>
524 |         <Option label="String False" value="string" enabled="false" />
525 |         <Option label="String True" value="string2" enabled="true" />
526 |         <Option label="Valid Option" value="valid" enabled="{true}" />
527 |       </Select>
528 |     `);
529 | 
530 |     const driver = await createSelectDriver();
531 |     await driver.toggleOptionsVisibility();
532 | 
533 |     // All options should be visible
534 |     await expect(page.getByRole("option")).toHaveCount(3);
535 |     await expect(page.getByRole("option", { name: "String False" })).toBeVisible();
536 |     await expect(page.getByRole("option", { name: "String True" })).toBeVisible();
537 |     await expect(page.getByRole("option", { name: "Valid Option" })).toBeVisible();
538 |   });
539 | 
540 |   test("disabled option cannot be selected in Select", async ({
541 |     initTestBed,
542 |     page,
543 |     createSelectDriver,
544 |   }) => {
545 |     const { testStateDriver } = await initTestBed(`
546 |       <Fragment>
547 |         <Select id="disabledSelect" onDidChange="arg => testState = arg" initialValue="enabled">
548 |           <Option label="Enabled Option" value="enabled" />
549 |           <Option label="Disabled Option" value="disabled" enabled="{false}" />
550 |         </Select>
551 |       </Fragment>
552 |     `);
553 | 
554 |     const driver = await createSelectDriver("disabledSelect");
555 |     await driver.toggleOptionsVisibility();
556 | 
557 |     // Try to select the disabled option (driver should not succeed)
558 |     const initialValue = await testStateDriver.testState();
559 |     await driver.selectLabel("Disabled Option");
560 | 
561 |     // Value should not change since option is disabled
562 |     await expect.poll(testStateDriver.testState).toEqual(initialValue);
563 |   });
564 | 
565 |   test("handles object as label (converts to string)", async ({
566 |     initTestBed,
567 |     page,
568 |     createSelectDriver,
569 |   }) => {
570 |     await initTestBed(`
571 |       <Select>
572 |         <Option label="{{}}" value="object" />
573 |         <Option label="Valid Option" value="valid" />
574 |       </Select>
575 |     `);
576 | 
577 |     const driver = await createSelectDriver();
578 |     await driver.toggleOptionsVisibility();
579 | 
580 |     // Should see both options - object will be converted to string representation
581 |     await expect(page.getByRole("option")).toHaveCount(2);
582 |     await expect(page.getByRole("option", { name: "Valid Option" })).toBeVisible();
583 |     // The object label should be visible with some string representation
584 |     await expect(page.getByRole("option")).toHaveCount(2);
585 |   });
586 | 
587 |   test("null values are handled gracefully", async ({ initTestBed, page, createSelectDriver }) => {
588 |     await initTestBed(`
589 |       <Select>
590 |         <Option label="{null}" value="null_label" />
591 |         <Option label="Valid Option" value="valid" />
592 |       </Select>
593 |     `);
594 | 
595 |     const driver = await createSelectDriver();
596 |     await driver.toggleOptionsVisibility();
597 | 
598 |     // The actual behavior might vary - this needs investigation
599 |     await expect(page.getByRole("option", { name: "Valid Option" })).toBeVisible();
600 |   });
601 | 
602 |   test("undefined values are handled gracefully", async ({
603 |     initTestBed,
604 |     page,
605 |     createSelectDriver,
606 |   }) => {
607 |     await initTestBed(`
608 |       <Select>
609 |         <Option label="{undefined}" value="undefined_label" />
610 |         <Option label="Valid Option" value="valid" />
611 |       </Select>
612 |     `);
613 | 
614 |     const driver = await createSelectDriver();
615 |     await driver.toggleOptionsVisibility();
616 | 
617 |     // The actual behavior might vary - this needs investigation
618 |     await expect(page.getByRole("option", { name: "Valid Option" })).toBeVisible();
619 |   });
620 | });
621 | 
```
Page 90/186FirstPrevNextLast