This is page 115 of 182. Use http://codebase.md/xmlui-org/xmlui/%7BlogoUrl%7D?lines=true&page={x} to view the full context. # Directory Structure ``` ├── .changeset │ ├── config.json │ ├── petite-dogs-live.md │ ├── social-socks-drop.md │ └── warm-lights-lay.md ├── .eslintrc.cjs ├── .github │ ├── build-checklist.png │ ├── ISSUE_TEMPLATE │ │ ├── bug_report.md │ │ └── feature_request.md │ └── workflows │ ├── deploy-blog.yml │ ├── deploy-docs-optimized.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 │ ├── layout-changes.md │ ├── package.json │ ├── public │ │ ├── blog │ │ │ ├── images │ │ │ │ ├── blog-page-component.png │ │ │ │ ├── blog-scrabble.png │ │ │ │ ├── integrated-blog-search.png │ │ │ │ └── lorem-ipsum.png │ │ │ ├── lorem-ipsum.md │ │ │ ├── newest-post.md │ │ │ ├── older-post.md │ │ │ └── welcome-to-the-xmlui-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 │ │ └── 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 │ │ ├── HelloMd.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 │ │ │ │ ├── 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 │ ├── 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 │ │ └── tsconfig.json │ ├── 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 │ │ ├── tsconfig.json │ │ └── 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 │ │ └── tsconfig.json │ ├── 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 │ │ └── tsconfig.json │ ├── 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 │ │ └── tsconfig.json │ ├── 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.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.module.scss │ │ │ │ ├── Preview.tsx │ │ │ │ ├── Select.module.scss │ │ │ │ ├── StandalonePlayground.tsx │ │ │ │ ├── StandalonePlaygroundNative.module.scss │ │ │ │ ├── StandalonePlaygroundNative.tsx │ │ │ │ ├── ThemeSwitcher.module.scss │ │ │ │ ├── ThemeSwitcher.tsx │ │ │ │ ├── ToneSwitcher.tsx │ │ │ │ ├── Tooltip.module.scss │ │ │ │ ├── Tooltip.tsx │ │ │ │ └── utils.ts │ │ │ ├── providers │ │ │ │ ├── Toast.module.scss │ │ │ │ └── ToastProvider.tsx │ │ │ ├── state │ │ │ │ └── store.ts │ │ │ ├── themes │ │ │ │ └── theme.ts │ │ │ └── utils │ │ │ └── helpers.ts │ │ └── tsconfig.json │ ├── 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 │ │ └── tsconfig.json │ ├── xmlui-spreadsheet │ │ ├── .gitignore │ │ ├── demo │ │ │ └── Main.xmlui │ │ ├── index.html │ │ ├── index.ts │ │ ├── meta │ │ │ └── componentsMetadata.ts │ │ ├── package.json │ │ ├── src │ │ │ ├── index.tsx │ │ │ ├── Spreadsheet.tsx │ │ │ └── SpreadsheetNative.tsx │ │ └── tsconfig.json │ └── 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.tsx │ │ │ └── HeroSectionNative.tsx │ │ ├── index.tsx │ │ ├── ScrollToTop │ │ │ ├── ScrollToTop.module.scss │ │ │ ├── ScrollToTop.tsx │ │ │ └── ScrollToTopNative.tsx │ │ └── vite-env.d.ts │ └── tsconfig.json ├── 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.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 │ ├── containers.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 │ ├── state-management.md │ ├── ud-components.md │ └── xmlui-repo.md ├── package.json ├── playwright.config.ts ├── scripts │ ├── coverage-only.js │ ├── e2e-test-summary.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 │ ├── get-langserver-metadata.mjs │ ├── 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.spec.ts │ │ │ │ ├── LabelList.tsx │ │ │ │ ├── LabelListNative.module.scss │ │ │ │ └── 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 │ │ │ ├── MultiSelectOption.tsx │ │ │ ├── OptionContext.ts │ │ │ ├── Select.md │ │ │ ├── Select.module.scss │ │ │ ├── Select.spec.ts │ │ │ ├── Select.tsx │ │ │ ├── SelectContext.tsx │ │ │ ├── SelectNative.tsx │ │ │ ├── SelectOption.tsx │ │ │ └── SimpleSelect.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.mjs │ ├── 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 │ │ │ ├── ModalDialogDriver.ts │ │ │ ├── NumberBoxDriver.ts │ │ │ ├── TextBoxDriver.ts │ │ │ ├── TimeInputDriver.ts │ │ │ ├── TimerDriver.ts │ │ │ └── TreeDriver.ts │ │ ├── fixtures.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.bin.json ├── tsconfig.json ├── tsconfig.node.json ├── vite.config.ts └── vitest.config.ts ``` # Files -------------------------------------------------------------------------------- /xmlui/tests/components-core/theming/component-layout.resolver.test.ts: -------------------------------------------------------------------------------- ```typescript 1 | import { describe, expect, it } from "vitest"; 2 | import { 3 | BASE_COMPONENT_PART, 4 | resolveComponentLayoutProps, 5 | } from "../../../src/components-core/theming/component-layout-resolver"; 6 | 7 | describe("Component property layout", () => { 8 | it("should parse empty", () => { 9 | const result = resolveComponentLayoutProps({}); 10 | expect(result).toStrictEqual({}); 11 | }); 12 | 13 | describe("single component properties", () => { 14 | it("single component property", () => { 15 | const result = resolveComponentLayoutProps({ 16 | color: "red", 17 | }); 18 | expect(result).toStrictEqual({ 19 | [BASE_COMPONENT_PART]: { 20 | baseStyles: { color: "red" }, 21 | }, 22 | }); 23 | }); 24 | 25 | it("single component property: paddingHorizontal", () => { 26 | const result = resolveComponentLayoutProps({ 27 | paddingHorizontal: "12px", 28 | }); 29 | expect(result).toStrictEqual({ 30 | [BASE_COMPONENT_PART]: { 31 | baseStyles: { paddingLeft: "12px", paddingRight: "12px" }, 32 | }, 33 | }); 34 | }); 35 | 36 | it("single component property: paddingVertical", () => { 37 | const result = resolveComponentLayoutProps({ 38 | paddingVertical: "12px", 39 | }); 40 | expect(result).toStrictEqual({ 41 | [BASE_COMPONENT_PART]: { 42 | baseStyles: { paddingTop: "12px", paddingBottom: "12px" }, 43 | }, 44 | }); 45 | }); 46 | 47 | it("single component property: marginHorizontal", () => { 48 | const result = resolveComponentLayoutProps({ 49 | marginHorizontal: "12px", 50 | }); 51 | expect(result).toStrictEqual({ 52 | [BASE_COMPONENT_PART]: { 53 | baseStyles: { marginLeft: "12px", marginRight: "12px" }, 54 | }, 55 | }); 56 | }); 57 | 58 | it("single component property: marginVertical", () => { 59 | const result = resolveComponentLayoutProps({ 60 | marginVertical: "12px", 61 | }); 62 | expect(result).toStrictEqual({ 63 | [BASE_COMPONENT_PART]: { 64 | baseStyles: { marginTop: "12px", marginBottom: "12px" }, 65 | }, 66 | }); 67 | }); 68 | 69 | it("single component property: borderHorizontal", () => { 70 | const result = resolveComponentLayoutProps({ 71 | borderHorizontal: "12px", 72 | }); 73 | expect(result).toStrictEqual({ 74 | [BASE_COMPONENT_PART]: { 75 | baseStyles: { borderLeft: "12px", borderRight: "12px" }, 76 | }, 77 | }); 78 | }); 79 | 80 | it("single component property: borderVertical", () => { 81 | const result = resolveComponentLayoutProps({ 82 | borderVertical: "12px", 83 | }); 84 | expect(result).toStrictEqual({ 85 | [BASE_COMPONENT_PART]: { 86 | baseStyles: { borderTop: "12px", borderBottom: "12px" }, 87 | }, 88 | }); 89 | }); 90 | 91 | it("single component property: wrapContent/true", () => { 92 | const result = resolveComponentLayoutProps({ 93 | wrapContent: true, 94 | }); 95 | expect(result).toStrictEqual({ 96 | [BASE_COMPONENT_PART]: { 97 | baseStyles: { flexWrap: "wrap" }, 98 | }, 99 | }); 100 | }); 101 | 102 | it("single component property: wrapContent/false", () => { 103 | const result = resolveComponentLayoutProps({ 104 | wrapContent: false, 105 | }); 106 | expect(result).toStrictEqual({ 107 | [BASE_COMPONENT_PART]: { 108 | baseStyles: { flexWrap: "nowrap" }, 109 | }, 110 | }); 111 | }); 112 | 113 | it("single component property: canShrink/true", () => { 114 | const result = resolveComponentLayoutProps({ 115 | canShrink: true, 116 | }); 117 | expect(result).toStrictEqual({ 118 | [BASE_COMPONENT_PART]: { 119 | baseStyles: { flexShrink: 1 }, 120 | }, 121 | }); 122 | }); 123 | 124 | it("single component property: canShrink/false", () => { 125 | const result = resolveComponentLayoutProps({ 126 | canShrink: false, 127 | }); 128 | expect(result).toStrictEqual({ 129 | [BASE_COMPONENT_PART]: { 130 | baseStyles: { flexShrink: 0 }, 131 | }, 132 | }); 133 | }); 134 | 135 | it("single component property: width (no star size)", () => { 136 | const result = resolveComponentLayoutProps({ 137 | width: "100px", 138 | }); 139 | expect(result).toStrictEqual({ 140 | [BASE_COMPONENT_PART]: { 141 | baseStyles: { width: "100px" }, 142 | }, 143 | }); 144 | }); 145 | 146 | it("single component property: width (star size)", () => { 147 | const result = resolveComponentLayoutProps( 148 | { 149 | width: "23*", 150 | }, 151 | { 152 | type: "Stack", 153 | orientation: "horizontal", 154 | }, 155 | ); 156 | expect(result).toStrictEqual({ 157 | [BASE_COMPONENT_PART]: { 158 | baseStyles: { flex: 23, flexShrink: 1 }, 159 | }, 160 | }); 161 | }); 162 | 163 | it("single component property: height (no star size)", () => { 164 | const result = resolveComponentLayoutProps({ 165 | height: "100px", 166 | }); 167 | expect(result).toStrictEqual({ 168 | [BASE_COMPONENT_PART]: { 169 | baseStyles: { height: "100px" }, 170 | }, 171 | }); 172 | }); 173 | 174 | it("single component property: height (star size)", () => { 175 | const result = resolveComponentLayoutProps( 176 | { 177 | height: "23*", 178 | }, 179 | { 180 | type: "Stack", 181 | orientation: "vertical", 182 | }, 183 | ); 184 | expect(result).toStrictEqual({ 185 | [BASE_COMPONENT_PART]: { 186 | baseStyles: { flex: 23, flexShrink: 1 }, 187 | }, 188 | }); 189 | }); 190 | }); 191 | 192 | describe("multiple component properties", () => { 193 | it("multiple component properties", () => { 194 | const result = resolveComponentLayoutProps({ 195 | color: "red", 196 | backgroundColor: "green", 197 | }); 198 | expect(result).toStrictEqual({ 199 | [BASE_COMPONENT_PART]: { 200 | baseStyles: { color: "red", backgroundColor: "green" }, 201 | }, 202 | }); 203 | }); 204 | 205 | it("multiple component properties: paddingHorizontal", () => { 206 | const result = resolveComponentLayoutProps({ 207 | paddingHorizontal: "12px", 208 | backgroundColor: "green", 209 | }); 210 | expect(result).toStrictEqual({ 211 | [BASE_COMPONENT_PART]: { 212 | baseStyles: { paddingLeft: "12px", paddingRight: "12px", backgroundColor: "green" }, 213 | }, 214 | }); 215 | }); 216 | 217 | it("multiple component properties: paddingVertical", () => { 218 | const result = resolveComponentLayoutProps({ 219 | paddingVertical: "12px", 220 | backgroundColor: "green", 221 | }); 222 | expect(result).toStrictEqual({ 223 | [BASE_COMPONENT_PART]: { 224 | baseStyles: { paddingTop: "12px", paddingBottom: "12px", backgroundColor: "green" }, 225 | }, 226 | }); 227 | }); 228 | 229 | it("multiple component properties: marginHorizontal", () => { 230 | const result = resolveComponentLayoutProps({ 231 | marginHorizontal: "12px", 232 | backgroundColor: "green", 233 | }); 234 | expect(result).toStrictEqual({ 235 | [BASE_COMPONENT_PART]: { 236 | baseStyles: { marginLeft: "12px", marginRight: "12px", backgroundColor: "green" }, 237 | }, 238 | }); 239 | }); 240 | 241 | it("multiple component properties: marginVertical", () => { 242 | const result = resolveComponentLayoutProps({ 243 | marginVertical: "12px", 244 | backgroundColor: "green", 245 | }); 246 | expect(result).toStrictEqual({ 247 | [BASE_COMPONENT_PART]: { 248 | baseStyles: { marginTop: "12px", marginBottom: "12px", backgroundColor: "green" }, 249 | }, 250 | }); 251 | }); 252 | 253 | it("multiple component properties: borderHorizontal", () => { 254 | const result = resolveComponentLayoutProps({ 255 | borderHorizontal: "12px", 256 | backgroundColor: "green", 257 | }); 258 | expect(result).toStrictEqual({ 259 | [BASE_COMPONENT_PART]: { 260 | baseStyles: { borderLeft: "12px", borderRight: "12px", backgroundColor: "green" }, 261 | }, 262 | }); 263 | }); 264 | 265 | it("multiple component properties: borderVertical", () => { 266 | const result = resolveComponentLayoutProps({ 267 | borderVertical: "12px", 268 | backgroundColor: "green", 269 | }); 270 | expect(result).toStrictEqual({ 271 | [BASE_COMPONENT_PART]: { 272 | baseStyles: { borderTop: "12px", borderBottom: "12px", backgroundColor: "green" }, 273 | }, 274 | }); 275 | }); 276 | 277 | it("multiple component properties: wrapContent/true", () => { 278 | const result = resolveComponentLayoutProps({ 279 | wrapContent: true, 280 | backgroundColor: "green", 281 | }); 282 | expect(result).toStrictEqual({ 283 | [BASE_COMPONENT_PART]: { 284 | baseStyles: { flexWrap: "wrap", backgroundColor: "green" }, 285 | }, 286 | }); 287 | }); 288 | 289 | it("multiple component properties: wrapContent/false", () => { 290 | const result = resolveComponentLayoutProps({ 291 | wrapContent: false, 292 | backgroundColor: "green", 293 | }); 294 | expect(result).toStrictEqual({ 295 | [BASE_COMPONENT_PART]: { 296 | baseStyles: { flexWrap: "nowrap", backgroundColor: "green" }, 297 | }, 298 | }); 299 | }); 300 | 301 | it("multiple component properties: canShrink/true", () => { 302 | const result = resolveComponentLayoutProps({ 303 | canShrink: true, 304 | backgroundColor: "green", 305 | }); 306 | expect(result).toStrictEqual({ 307 | [BASE_COMPONENT_PART]: { 308 | baseStyles: { flexShrink: 1, backgroundColor: "green" }, 309 | }, 310 | }); 311 | }); 312 | 313 | it("multiple component properties: canShrink/false", () => { 314 | const result = resolveComponentLayoutProps({ 315 | canShrink: false, 316 | backgroundColor: "green", 317 | }); 318 | expect(result).toStrictEqual({ 319 | [BASE_COMPONENT_PART]: { 320 | baseStyles: { flexShrink: 0, backgroundColor: "green" }, 321 | }, 322 | }); 323 | }); 324 | 325 | it("multiple component properties: width (no star size)", () => { 326 | const result = resolveComponentLayoutProps({ 327 | width: "100px", 328 | backgroundColor: "green", 329 | }); 330 | expect(result).toStrictEqual({ 331 | [BASE_COMPONENT_PART]: { 332 | baseStyles: { width: "100px", backgroundColor: "green" }, 333 | }, 334 | }); 335 | }); 336 | 337 | it("multiple component properties: width (star size)", () => { 338 | const result = resolveComponentLayoutProps( 339 | { 340 | width: "23*", 341 | backgroundColor: "green", 342 | }, 343 | { 344 | type: "Stack", 345 | orientation: "horizontal", 346 | }, 347 | ); 348 | expect(result).toStrictEqual({ 349 | [BASE_COMPONENT_PART]: { 350 | baseStyles: { flex: 23, flexShrink: 1, backgroundColor: "green" }, 351 | }, 352 | }); 353 | }); 354 | 355 | it("multiple component properties: height (no star size)", () => { 356 | const result = resolveComponentLayoutProps({ 357 | height: "100px", 358 | backgroundColor: "green", 359 | }); 360 | expect(result).toStrictEqual({ 361 | [BASE_COMPONENT_PART]: { 362 | baseStyles: { height: "100px", backgroundColor: "green" }, 363 | }, 364 | }); 365 | }); 366 | 367 | it("multiple component properties: height (star size)", () => { 368 | const result = resolveComponentLayoutProps( 369 | { 370 | height: "23*", 371 | backgroundColor: "green", 372 | }, 373 | { 374 | type: "Stack", 375 | orientation: "vertical", 376 | }, 377 | ); 378 | expect(result).toStrictEqual({ 379 | [BASE_COMPONENT_PART]: { 380 | baseStyles: { flex: 23, flexShrink: 1, backgroundColor: "green" }, 381 | }, 382 | }); 383 | }); 384 | }); 385 | 386 | describe("single component properties with state", () => { 387 | it("single component property with state", () => { 388 | const result = resolveComponentLayoutProps({ 389 | "color--hover": "red", 390 | }); 391 | expect(result).toStrictEqual({ 392 | [BASE_COMPONENT_PART]: { 393 | baseStyles: { states: { hover: { color: "red" } } }, 394 | }, 395 | }); 396 | }); 397 | 398 | it("single component property with multiple states #1", () => { 399 | const result = resolveComponentLayoutProps({ 400 | "color--hover--active": "red", 401 | }); 402 | expect(result).toStrictEqual({ 403 | [BASE_COMPONENT_PART]: { 404 | baseStyles: { states: { "hover&active": { color: "red" } } }, 405 | }, 406 | }); 407 | }); 408 | 409 | it("single component property with multiple states #2", () => { 410 | const result = resolveComponentLayoutProps({ 411 | "color--hover--active--focus": "red", 412 | }); 413 | expect(result).toStrictEqual({ 414 | [BASE_COMPONENT_PART]: { 415 | baseStyles: { states: { "hover&active&focus": { color: "red" } } }, 416 | }, 417 | }); 418 | }); 419 | 420 | it("multiple component properties with state", () => { 421 | const result = resolveComponentLayoutProps({ 422 | "color--hover": "red", 423 | "backgroundColor--hover": "blue", 424 | }); 425 | expect(result).toStrictEqual({ 426 | [BASE_COMPONENT_PART]: { 427 | baseStyles: { states: { hover: { color: "red", backgroundColor: "blue" } } }, 428 | }, 429 | }); 430 | }); 431 | 432 | it("multiple component properties with multiple states #1", () => { 433 | const result = resolveComponentLayoutProps({ 434 | "color--focus": "red", 435 | "backgroundColor--hover": "blue", 436 | }); 437 | expect(result).toStrictEqual({ 438 | [BASE_COMPONENT_PART]: { 439 | baseStyles: { states: { focus: { color: "red" }, hover: { backgroundColor: "blue" } } }, 440 | }, 441 | }); 442 | }); 443 | 444 | it("multiple component properties with multiple states #2", () => { 445 | const result = resolveComponentLayoutProps({ 446 | "color--focus": "red", 447 | "backgroundColor--hover--focus": "blue", 448 | }); 449 | expect(result).toStrictEqual({ 450 | [BASE_COMPONENT_PART]: { 451 | baseStyles: { 452 | states: { focus: { color: "red" }, "hover&focus": { backgroundColor: "blue" } }, 453 | }, 454 | }, 455 | }); 456 | }); 457 | 458 | it("multiple component properties with multiple states #3", () => { 459 | const result = resolveComponentLayoutProps({ 460 | "color--focus": "red", 461 | "backgroundColor--focus": "blue", 462 | }); 463 | expect(result).toStrictEqual({ 464 | [BASE_COMPONENT_PART]: { 465 | baseStyles: { states: { focus: { color: "red", backgroundColor: "blue" } } }, 466 | }, 467 | }); 468 | }); 469 | 470 | it("multiple component properties with multiple states #4", () => { 471 | const result = resolveComponentLayoutProps({ 472 | "color--focus--active": "red", 473 | "backgroundColor--focus": "blue", 474 | }); 475 | expect(result).toStrictEqual({ 476 | [BASE_COMPONENT_PART]: { 477 | baseStyles: { 478 | states: { focus: { backgroundColor: "blue" }, "focus&active": { color: "red" } }, 479 | }, 480 | }, 481 | }); 482 | }); 483 | }); 484 | 485 | describe("multiple component properties with and without state", () => { 486 | it("multiple component properties with state", () => { 487 | const result = resolveComponentLayoutProps({ 488 | "color--hover": "red", 489 | backgroundColor: "green", 490 | }); 491 | expect(result).toStrictEqual({ 492 | [BASE_COMPONENT_PART]: { 493 | baseStyles: { backgroundColor: "green", states: { hover: { color: "red" } } }, 494 | }, 495 | }); 496 | }); 497 | 498 | it("multiple component properties with multiple states #1", () => { 499 | const result = resolveComponentLayoutProps({ 500 | "color--hover--active": "red", 501 | backgroundColor: "green", 502 | }); 503 | expect(result).toStrictEqual({ 504 | [BASE_COMPONENT_PART]: { 505 | baseStyles: { backgroundColor: "green", states: { "hover&active": { color: "red" } } }, 506 | }, 507 | }); 508 | }); 509 | 510 | it("multiple component properties with multiple states #2", () => { 511 | const result = resolveComponentLayoutProps({ 512 | "color--hover--active--focus": "red", 513 | backgroundColor: "green", 514 | }); 515 | expect(result).toStrictEqual({ 516 | [BASE_COMPONENT_PART]: { 517 | baseStyles: { 518 | backgroundColor: "green", 519 | states: { "hover&active&focus": { color: "red" } }, 520 | }, 521 | }, 522 | }); 523 | }); 524 | 525 | it("multiple component properties with state (both with state)", () => { 526 | const result = resolveComponentLayoutProps({ 527 | "color--hover": "red", 528 | "backgroundColor--hover": "blue", 529 | }); 530 | expect(result).toStrictEqual({ 531 | [BASE_COMPONENT_PART]: { 532 | baseStyles: { states: { hover: { color: "red", backgroundColor: "blue" } } }, 533 | }, 534 | }); 535 | }); 536 | 537 | it("multiple component properties with multiple states #1 (mixed)", () => { 538 | const result = resolveComponentLayoutProps({ 539 | "color--focus": "red", 540 | "backgroundColor--hover": "blue", 541 | padding: "10px", 542 | }); 543 | expect(result).toStrictEqual({ 544 | [BASE_COMPONENT_PART]: { 545 | baseStyles: { 546 | padding: "10px", 547 | states: { focus: { color: "red" }, hover: { backgroundColor: "blue" } }, 548 | }, 549 | }, 550 | }); 551 | }); 552 | 553 | it("multiple component properties with multiple states #2 (mixed)", () => { 554 | const result = resolveComponentLayoutProps({ 555 | "color--focus": "red", 556 | "backgroundColor--hover--focus": "blue", 557 | margin: "5px", 558 | }); 559 | expect(result).toStrictEqual({ 560 | [BASE_COMPONENT_PART]: { 561 | baseStyles: { 562 | margin: "5px", 563 | states: { focus: { color: "red" }, "hover&focus": { backgroundColor: "blue" } }, 564 | }, 565 | }, 566 | }); 567 | }); 568 | 569 | it("multiple component properties with multiple states #3 (mixed)", () => { 570 | const result = resolveComponentLayoutProps({ 571 | "color--focus": "red", 572 | "backgroundColor--focus": "blue", 573 | border: "1px solid black", 574 | }); 575 | expect(result).toStrictEqual({ 576 | [BASE_COMPONENT_PART]: { 577 | baseStyles: { 578 | border: "1px solid black", 579 | states: { focus: { color: "red", backgroundColor: "blue" } }, 580 | }, 581 | }, 582 | }); 583 | }); 584 | 585 | it("multiple component properties with multiple states #4 (mixed)", () => { 586 | const result = resolveComponentLayoutProps({ 587 | "color--focus--active": "red", 588 | "backgroundColor--focus": "blue", 589 | fontSize: "14px", 590 | }); 591 | expect(result).toStrictEqual({ 592 | [BASE_COMPONENT_PART]: { 593 | baseStyles: { 594 | fontSize: "14px", 595 | states: { focus: { backgroundColor: "blue" }, "focus&active": { color: "red" } }, 596 | }, 597 | }, 598 | }); 599 | }); 600 | }); 601 | 602 | describe("component properties with parts", () => { 603 | it("single component property with part", () => { 604 | const result = resolveComponentLayoutProps({ 605 | "color-indicator": "red", 606 | }); 607 | expect(result).toStrictEqual({ 608 | indicator: { 609 | baseStyles: { color: "red" }, 610 | }, 611 | }); 612 | }); 613 | 614 | it("multiple component property with part", () => { 615 | const result = resolveComponentLayoutProps({ 616 | "color-indicator": "red", 617 | "backgroundColor-indicator": "green", 618 | }); 619 | expect(result).toStrictEqual({ 620 | indicator: { 621 | baseStyles: { color: "red", backgroundColor: "green" }, 622 | }, 623 | }); 624 | }); 625 | 626 | it("multiple component property with multiple parts #1", () => { 627 | const result = resolveComponentLayoutProps({ 628 | "color-indicator": "red", 629 | "backgroundColor-handle": "green", 630 | }); 631 | expect(result).toStrictEqual({ 632 | indicator: { 633 | baseStyles: { color: "red" }, 634 | }, 635 | handle: { 636 | baseStyles: { backgroundColor: "green" }, 637 | }, 638 | }); 639 | }); 640 | 641 | it("multiple component property with multiple parts #2", () => { 642 | const result = resolveComponentLayoutProps({ 643 | "color-indicator": "red", 644 | "backgroundColor-handle": "green", 645 | "fontSize-indicator": "12px", 646 | }); 647 | expect(result).toStrictEqual({ 648 | indicator: { 649 | baseStyles: { color: "red", fontSize: "12px" }, 650 | }, 651 | handle: { 652 | baseStyles: { backgroundColor: "green" }, 653 | }, 654 | }); 655 | }); 656 | }); 657 | 658 | describe("component properties with parts and state", () => { 659 | it("single component property with part and state", () => { 660 | const result = resolveComponentLayoutProps({ 661 | "color-indicator--hover": "red", 662 | }); 663 | expect(result).toStrictEqual({ 664 | indicator: { 665 | baseStyles: { states: { hover: { color: "red" } } }, 666 | }, 667 | }); 668 | }); 669 | 670 | it("single component property with part and multiple states #1", () => { 671 | const result = resolveComponentLayoutProps({ 672 | "color-indicator--hover--active": "red", 673 | }); 674 | expect(result).toStrictEqual({ 675 | indicator: { 676 | baseStyles: { states: { "hover&active": { color: "red" } } }, 677 | }, 678 | }); 679 | }); 680 | 681 | it("single component property with part and multiple states #2", () => { 682 | const result = resolveComponentLayoutProps({ 683 | "color-indicator--hover--active--focus": "red", 684 | }); 685 | expect(result).toStrictEqual({ 686 | indicator: { 687 | baseStyles: { states: { "hover&active&focus": { color: "red" } } }, 688 | }, 689 | }); 690 | }); 691 | 692 | it("multiple component properties with part and state", () => { 693 | const result = resolveComponentLayoutProps({ 694 | "color-indicator--hover": "red", 695 | "backgroundColor-indicator--hover": "green", 696 | }); 697 | expect(result).toStrictEqual({ 698 | indicator: { 699 | baseStyles: { states: { hover: { color: "red", backgroundColor: "green" } } }, 700 | }, 701 | }); 702 | }); 703 | 704 | it("multiple component properties with part and multiple states #1", () => { 705 | const result = resolveComponentLayoutProps({ 706 | "color-indicator--focus": "red", 707 | "backgroundColor-indicator--hover": "green", 708 | }); 709 | expect(result).toStrictEqual({ 710 | indicator: { 711 | baseStyles: { states: { focus: { color: "red" }, hover: { backgroundColor: "green" } } }, 712 | }, 713 | }); 714 | }); 715 | 716 | it("multiple component properties with part and multiple states #2", () => { 717 | const result = resolveComponentLayoutProps({ 718 | "color-indicator--focus": "red", 719 | "backgroundColor-indicator--hover--focus": "green", 720 | }); 721 | expect(result).toStrictEqual({ 722 | indicator: { 723 | baseStyles: { 724 | states: { focus: { color: "red" }, "hover&focus": { backgroundColor: "green" } }, 725 | }, 726 | }, 727 | }); 728 | }); 729 | 730 | it("multiple component properties with part and multiple states #3", () => { 731 | const result = resolveComponentLayoutProps({ 732 | "color-indicator--focus": "red", 733 | "backgroundColor-indicator--focus": "green", 734 | }); 735 | expect(result).toStrictEqual({ 736 | indicator: { 737 | baseStyles: { states: { focus: { color: "red", backgroundColor: "green" } } }, 738 | }, 739 | }); 740 | }); 741 | 742 | it("multiple component properties with part and multiple states #4", () => { 743 | const result = resolveComponentLayoutProps({ 744 | "color-indicator--focus--active": "red", 745 | "backgroundColor-indicator--focus": "green", 746 | }); 747 | expect(result).toStrictEqual({ 748 | indicator: { 749 | baseStyles: { 750 | states: { focus: { backgroundColor: "green" }, "focus&active": { color: "red" } }, 751 | }, 752 | }, 753 | }); 754 | }); 755 | 756 | it("multiple component properties with multiple parts and states #1", () => { 757 | const result = resolveComponentLayoutProps({ 758 | "color-indicator--hover": "red", 759 | "backgroundColor-handle--focus": "green", 760 | }); 761 | expect(result).toStrictEqual({ 762 | indicator: { 763 | baseStyles: { states: { hover: { color: "red" } } }, 764 | }, 765 | handle: { 766 | baseStyles: { states: { focus: { backgroundColor: "green" } } }, 767 | }, 768 | }); 769 | }); 770 | 771 | it("multiple component properties with multiple parts and states #2", () => { 772 | const result = resolveComponentLayoutProps({ 773 | "color-indicator--hover": "red", 774 | "backgroundColor-handle--focus": "green", 775 | "fontSize-indicator--active": "12px", 776 | }); 777 | expect(result).toStrictEqual({ 778 | indicator: { 779 | baseStyles: { states: { hover: { color: "red" }, active: { fontSize: "12px" } } }, 780 | }, 781 | handle: { 782 | baseStyles: { states: { focus: { backgroundColor: "green" } } }, 783 | }, 784 | }); 785 | }); 786 | 787 | it("multiple component properties with multiple parts and mixed states", () => { 788 | const result = resolveComponentLayoutProps({ 789 | "color-indicator--hover--active": "red", 790 | "backgroundColor-handle--focus": "green", 791 | "fontSize-indicator--hover": "12px", 792 | "border-handle--focus--active": "1px solid black", 793 | }); 794 | expect(result).toStrictEqual({ 795 | indicator: { 796 | baseStyles: { states: { "hover&active": { color: "red" }, hover: { fontSize: "12px" } } }, 797 | }, 798 | handle: { 799 | baseStyles: { 800 | states: { 801 | focus: { backgroundColor: "green" }, 802 | "focus&active": { border: "1px solid black" }, 803 | }, 804 | }, 805 | }, 806 | }); 807 | }); 808 | }); 809 | 810 | describe("mixed component properties, parts, and states", () => { 811 | it("mix of base properties, parts without states, and parts with states", () => { 812 | const result = resolveComponentLayoutProps({ 813 | color: "blue", // base property 814 | "backgroundColor-header": "yellow", // part property without state 815 | "fontSize-indicator--hover": "14px", // part property with state 816 | }); 817 | expect(result).toStrictEqual({ 818 | [BASE_COMPONENT_PART]: { 819 | baseStyles: { color: "blue" }, 820 | }, 821 | header: { 822 | baseStyles: { backgroundColor: "yellow" }, 823 | }, 824 | indicator: { 825 | baseStyles: { states: { hover: { fontSize: "14px" } } }, 826 | }, 827 | }); 828 | }); 829 | 830 | it("mix of base properties with states and parts with states", () => { 831 | const result = resolveComponentLayoutProps({ 832 | "color--hover": "red", // base property with state 833 | "backgroundColor-header--focus": "green", // part property with state 834 | "border-footer": "1px solid black", // part property without state 835 | }); 836 | expect(result).toStrictEqual({ 837 | [BASE_COMPONENT_PART]: { 838 | baseStyles: { states: { hover: { color: "red" } } }, 839 | }, 840 | header: { 841 | baseStyles: { states: { focus: { backgroundColor: "green" } } }, 842 | }, 843 | footer: { 844 | baseStyles: { border: "1px solid black" }, 845 | }, 846 | }); 847 | }); 848 | 849 | it("complex mix: base properties, parts, multiple states", () => { 850 | const result = resolveComponentLayoutProps({ 851 | width: "100px", // base property 852 | height: "50px", // base property 853 | "color--hover": "red", // base property with state 854 | "backgroundColor--active": "blue", // base property with different state 855 | "fontSize-header": "16px", // part property 856 | "padding-header--hover": "10px", // part property with state 857 | "margin-footer--focus--active": "5px", // part property with multiple states 858 | "border-sidebar": "2px solid gray", // different part property 859 | }); 860 | expect(result).toStrictEqual({ 861 | [BASE_COMPONENT_PART]: { 862 | baseStyles: { 863 | width: "100px", 864 | height: "50px", 865 | states: { 866 | hover: { color: "red" }, 867 | active: { backgroundColor: "blue" }, 868 | }, 869 | }, 870 | }, 871 | header: { 872 | baseStyles: { 873 | fontSize: "16px", 874 | states: { hover: { padding: "10px" } }, 875 | }, 876 | }, 877 | footer: { 878 | baseStyles: { states: { "focus&active": { margin: "5px" } } }, 879 | }, 880 | sidebar: { 881 | baseStyles: { border: "2px solid gray" }, 882 | }, 883 | }); 884 | }); 885 | 886 | it("same property applied to different contexts", () => { 887 | const result = resolveComponentLayoutProps({ 888 | color: "black", // base color 889 | "color-header": "blue", // header color 890 | "color-footer--hover": "red", // footer color on hover 891 | "color--active": "green", // base color on active 892 | }); 893 | expect(result).toStrictEqual({ 894 | [BASE_COMPONENT_PART]: { 895 | baseStyles: { 896 | color: "black", 897 | states: { active: { color: "green" } }, 898 | }, 899 | }, 900 | header: { 901 | baseStyles: { color: "blue" }, 902 | }, 903 | footer: { 904 | baseStyles: { states: { hover: { color: "red" } } }, 905 | }, 906 | }); 907 | }); 908 | 909 | it("overlapping states across base and parts", () => { 910 | const result = resolveComponentLayoutProps({ 911 | "backgroundColor--hover": "lightblue", // base background on hover 912 | "color--hover": "darkblue", // base color on hover 913 | "fontSize-title--hover": "18px", // title font size on hover 914 | "padding-title--focus": "8px", // title padding on focus 915 | "margin-content--hover--focus": "12px", // content margin on hover and focus 916 | }); 917 | expect(result).toStrictEqual({ 918 | [BASE_COMPONENT_PART]: { 919 | baseStyles: { 920 | states: { 921 | hover: { backgroundColor: "lightblue", color: "darkblue" }, 922 | }, 923 | }, 924 | }, 925 | title: { 926 | baseStyles: { 927 | states: { 928 | hover: { fontSize: "18px" }, 929 | focus: { padding: "8px" }, 930 | }, 931 | }, 932 | }, 933 | content: { 934 | baseStyles: { states: { "hover&focus": { margin: "12px" } } }, 935 | }, 936 | }); 937 | }); 938 | 939 | it("multiple properties per part with mixed states", () => { 940 | const result = resolveComponentLayoutProps({ 941 | "width-card": "200px", // card width (no state) 942 | "height-card": "150px", // card height (no state) 943 | "backgroundColor-card--hover": "gray", // card background on hover 944 | "border-card--focus": "2px solid blue", // card border on focus 945 | "color-card--hover--active": "white", // card color on hover and active 946 | "padding-card": "16px", // card padding (no state) 947 | }); 948 | expect(result).toStrictEqual({ 949 | card: { 950 | baseStyles: { 951 | width: "200px", 952 | height: "150px", 953 | padding: "16px", 954 | states: { 955 | hover: { backgroundColor: "gray" }, 956 | focus: { border: "2px solid blue" }, 957 | "hover&active": { color: "white" }, 958 | }, 959 | }, 960 | }, 961 | }); 962 | }); 963 | 964 | it("state conflicts and merging across different parts", () => { 965 | const result = resolveComponentLayoutProps({ 966 | "color--focus": "red", // base color on focus 967 | "backgroundColor--focus": "yellow", // base background on focus 968 | "fontSize-header--focus": "20px", // header font size on focus 969 | "color-footer--focus": "blue", // footer color on focus (different from base) 970 | "margin-header": "10px", // header margin (no state) 971 | "padding-footer--active": "5px", // footer padding on active 972 | }); 973 | expect(result).toStrictEqual({ 974 | [BASE_COMPONENT_PART]: { 975 | baseStyles: { 976 | states: { 977 | focus: { color: "red", backgroundColor: "yellow" }, 978 | }, 979 | }, 980 | }, 981 | header: { 982 | baseStyles: { 983 | margin: "10px", 984 | states: { focus: { fontSize: "20px" } }, 985 | }, 986 | }, 987 | footer: { 988 | baseStyles: { 989 | states: { 990 | focus: { color: "blue" }, 991 | active: { padding: "5px" }, 992 | }, 993 | }, 994 | }, 995 | }); 996 | }); 997 | }); 998 | 999 | describe("regression", () => { 1000 | it("has responsive with state", () => { 1001 | const result = resolveComponentLayoutProps({ 1002 | backgroundColor: "red", 1003 | "backgroundColor-xxl": "green", 1004 | "backgroundColor-xxl--hover": "blue", 1005 | }); 1006 | expect(result).toStrictEqual({ 1007 | [BASE_COMPONENT_PART]: { 1008 | baseStyles: { 1009 | backgroundColor: "red", 1010 | }, 1011 | responsiveStyles: { 1012 | xxl: { 1013 | backgroundColor: "green", 1014 | states: { 1015 | hover: { backgroundColor: "blue" }, 1016 | }, 1017 | }, 1018 | }, 1019 | }, 1020 | }); 1021 | }); 1022 | }); 1023 | }); 1024 | ``` -------------------------------------------------------------------------------- /xmlui/src/components-core/theming/_themes.scss: -------------------------------------------------------------------------------- ```scss 1 | @use "sass:string"; 2 | @use "sass:meta"; 3 | @use "sass:map"; 4 | @use "sass:list"; 5 | 6 | /* 7 | * This file contains all CSS variables AppEngine uses for styling the UI, including individual visual components. 8 | * 9 | * We use a subset of these CSS variables in themes. 10 | */ 11 | 12 | // ===================================================================================================================== 13 | // We index all theme variables with this prefix to make a distinction from variables defined in other custom themes. 14 | $THEME-VAR-PREFIX: xmlui; 15 | 16 | /* 17 | * This function creates a CSS variable name by combining the prefix and the argument variable name 18 | */ 19 | @function createVar($componentVariable) { 20 | @return var(--#{$THEME-VAR-PREFIX}-#{$componentVariable}); 21 | } 22 | 23 | @function createVarWithDefault($componentVariable, $defaultValue) { 24 | @return var(--#{$THEME-VAR-PREFIX}-#{$componentVariable}, $defaultValue); 25 | } 26 | 27 | @function countSubstring($string, $delimiter: null) { 28 | @if (meta.type-of($string) != "string") { 29 | @return -1; 30 | } 31 | $list: (); 32 | $length: string.length($string); 33 | 34 | $count: 0; 35 | 36 | $index: string.index($string, $delimiter); 37 | 38 | $temp: $string; 39 | @while $index != null { 40 | $count: $count + 1; 41 | $temp: string.slice($temp, $index + 1); 42 | $index: string.index($temp, $delimiter); 43 | } 44 | 45 | @return $count; 46 | } 47 | 48 | /* 49 | * This function allows other CSS modules to get the value of the CSS variable specified in $componentVariable. 50 | Optionally, you can provide a $fallbackValue to set the variable's value if that is not defined. 51 | */ 52 | @function useVarInner($componentVariable, $fallbackValue: false) { 53 | @if $fallbackValue { 54 | $num: countSubstring($componentVariable, "var("); 55 | @if ($num <= 1) { 56 | @return var(#{str-slice($componentVariable, 5, -2)}, #{$fallbackValue}); 57 | } 58 | //we offset with the number of 'vars' in the $componentVariable, because we have to offset backwards for the closing parenthesis 59 | // typically when in a useVar we have a hVar as the first argument 60 | $offset: -2; 61 | @if ($num > 1) { 62 | $offset: (-1 * $num) - 1; 63 | } 64 | //@if(string.index(#{$fallbackValue}, 'fontSize-sm')) { 65 | // @debug 'original: ' + #{$componentVariable} + ", varcount: " + $num; 66 | // @debug 'concatet:' + var(#{str-slice($componentVariable, 5, -2)}, #{$fallbackValue}); 67 | // @debug 'concat 2:' + var(#{str-slice($componentVariable, 5, $offset)}, #{$fallbackValue}); 68 | //} 69 | @return string.unquote( 70 | "var(#{str-slice($componentVariable, 5, $offset)}, #{$fallbackValue}#{str-slice($componentVariable, $offset + 1)}" 71 | ); 72 | } @else { 73 | @return $componentVariable; 74 | } 75 | } 76 | 77 | @function reverse($list, $recursive: false) { 78 | $result: (); 79 | 80 | @for $i from length($list) * -1 through -1 { 81 | @if type-of(nth($list, abs($i))) == list and $recursive { 82 | $result: append($result, reverse(nth($list, abs($i)), $recursive)); 83 | } @else { 84 | $result: append($result, nth($list, abs($i))); 85 | } 86 | } 87 | 88 | @return $result; 89 | } 90 | 91 | @function useVar($vars...) { 92 | $ret: false; 93 | @each $var in reverse($vars) { 94 | $ret: useVarInner($var, $ret); 95 | } 96 | @return $ret; 97 | } 98 | 99 | @function remove-nth($list, $index) { 100 | $result: null; 101 | 102 | @if type-of($index) != number { 103 | @warn "$index: #{quote($index)} is not a number for `remove-nth`."; 104 | } @else if $index == 0 { 105 | @warn "List index 0 must be a non-zero integer for `remove-nth`."; 106 | } @else if abs($index) > length($list) { 107 | @warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`."; 108 | } @else { 109 | $result: (); 110 | $index: if($index < 0, length($list) + $index + 1, $index); 111 | 112 | @for $i from 1 through length($list) { 113 | @if $i != $index { 114 | $result: append($result, nth($list, $i)); 115 | } 116 | } 117 | } 118 | 119 | @return $result; 120 | } 121 | 122 | @function generate-combinations($list, $used: ()) { 123 | $result: (); 124 | 125 | @each $item in $list { 126 | @if not index($used, $item) { 127 | $result: append($result, $item, comma); 128 | $used: append($used, $item, comma); 129 | 130 | @if length($list) > 1 { 131 | $rest: remove-nth($list, index($list, $item)); 132 | $combinations: generate-combinations($rest, $used); 133 | 134 | @each $combination in $combinations { 135 | $result: append($result, join($item, $combination), comma); 136 | } 137 | } 138 | } 139 | } 140 | 141 | @return $result; 142 | } 143 | 144 | @function compare($string-a, $string-b) { 145 | @return str-length($string-a) > str-length($string-b); 146 | } 147 | 148 | @function quick-sort($list) { 149 | $less: (); 150 | $equal: (); 151 | $large: (); 152 | 153 | @if length($list) > 1 { 154 | $seed: nth($list, ceil(calc(length($list) / 2))); 155 | 156 | @each $item in $list { 157 | @if $item == $seed { 158 | $equal: append($equal, $item, list-separator($list)); 159 | } @else if compare($item, $seed) { 160 | $less: append($less, $item, list-separator($list)); 161 | } @else if not compare($item, $seed) { 162 | $large: append($large, $item, list-separator($list)); 163 | } 164 | } 165 | 166 | @return join(join(quick-sort($less), $equal), quick-sort($large)); 167 | } 168 | 169 | @return $list; 170 | } 171 | 172 | @function capitalize($string) { 173 | @return to-upper-case(str-slice($string, 1, 1)) + str-slice($string, 2); 174 | } 175 | 176 | @function createHVar($attribute, $component, $traits: (), $states: (), $fallback: false) { 177 | $stateCombinations: generate-combinations($states); 178 | $sortedStateCombinations: (); 179 | @each $stateComb in $stateCombinations { 180 | $result: ""; 181 | @each $st in $stateComb { 182 | $result: #{$result}--#{$st}; 183 | } 184 | $sortedStateCombinations: append($sortedStateCombinations, $result); 185 | } 186 | $sortedStateCombinations: append($sortedStateCombinations, ""); 187 | $sortedStateCombinations: quick-sort($sortedStateCombinations); 188 | 189 | $traitCombinations: generate-combinations($traits); 190 | $sortedTraitCombinations: (); 191 | @each $traitComb in $traitCombinations { 192 | $result: ""; 193 | @each $st in $traitComb { 194 | $result: #{$result}-#{$st}; 195 | } 196 | $sortedTraitCombinations: append($sortedTraitCombinations, $result); 197 | } 198 | $sortedTraitCombinations: append($sortedTraitCombinations, ""); 199 | $sortedTraitCombinations: quick-sort($sortedTraitCombinations); 200 | 201 | //@debug "trait combs: #{$sortedTraitCombinations}"; 202 | //@debug "state combs: #{$sortedStateCombinations}"; 203 | 204 | $base: #{$attribute}-#{capitalize($component)}; 205 | $vars: (); 206 | 207 | @each $stateComb in $sortedStateCombinations { 208 | @each $traitComb in $sortedTraitCombinations { 209 | $vars: append($vars, createVar(#{$base}#{$traitComb}#{$stateComb})); 210 | } 211 | } 212 | @if ($fallback != false) { 213 | $vars: append($vars, $fallback); 214 | } 215 | 216 | @return useVar($vars...); 217 | } 218 | 219 | @function str-split($string, $separator) { 220 | // empty array/list 221 | $split-arr: (); 222 | // first index of separator in string 223 | $index: str-index($string, $separator); 224 | // loop through string 225 | @while $index != null { 226 | // get the substring from the first character to the separator 227 | $item: str-slice($string, 1, $index - 1); 228 | // push item to array 229 | $split-arr: append($split-arr, $item); 230 | // remove item and separator from string 231 | $string: str-slice($string, $index + 1); 232 | // find new index of separator 233 | $index: str-index($string, $separator); 234 | } 235 | // add the remaining string to list (the last item) 236 | $split-arr: append($split-arr, $string); 237 | 238 | @return $split-arr; 239 | } 240 | 241 | @function appendThemeVar($themeVars, $componentVariable) { 242 | $split: str-split($componentVariable, ":"); 243 | $varName: list.nth($split, -1); 244 | $cssVar: createVar($varName); 245 | $themeVars: map.set($themeVars, #{$componentVariable}, $cssVar); 246 | @return $themeVars; 247 | } 248 | 249 | @function appendThemeVarWithDefault($themeVars, $componentVariable, $defaultValue) { 250 | $split: str-split($componentVariable, ":"); 251 | $varName: list.nth($split, -1); 252 | $cssVar: createVarWithDefault($varName, $defaultValue); 253 | $themeVars: map.set($themeVars, #{$componentVariable}, $cssVar); 254 | @return $themeVars; 255 | } 256 | 257 | @function appendThemeVarWithFallback($themeVars, $componentVariable, $fallbackVar) { 258 | $split: str-split($componentVariable, ":"); 259 | $varName: list.nth($split, -1); 260 | $fallbackSplit: str-split($fallbackVar, ":"); 261 | $fallbackVarName: list.nth($fallbackSplit, -1); 262 | $defaultValue: createVar($fallbackVarName); 263 | $cssVar: createVarWithDefault($varName, $defaultValue); 264 | $themeVars: map.set($themeVars, #{$componentVariable}, $cssVar); 265 | @return $themeVars; 266 | } 267 | 268 | @function getThemeVar($themeVars, $componentVariable) { 269 | @return map.get($themeVars, $componentVariable); 270 | } 271 | 272 | @function json-stringify($var) { 273 | $var-type: type-of($var); 274 | $encode-func-name: "_encode-#{$var-type}"; 275 | 276 | @if (function-exists($encode-func-name)) { 277 | $encode-func: get-function($encode-func-name); 278 | 279 | @return call($encode-func, $var); 280 | } 281 | 282 | @return $var; // strings and booleans don't need to be modified 283 | } 284 | 285 | @function stringify($var) { 286 | @return '"#{$var}"'; 287 | } 288 | 289 | @function _encode-string($string) { 290 | @return stringify($string); 291 | } 292 | 293 | @function _encode-number($number) { 294 | @if (unitless($number)) { 295 | @return $number; 296 | } 297 | 298 | @return stringify($number); 299 | } 300 | 301 | @function _encode-null($string) { 302 | @return "null"; 303 | } 304 | 305 | @function _encode-color($color) { 306 | @return stringify($color); 307 | } 308 | 309 | @function _encode-list($list) { 310 | @return _encode-iterable($list); 311 | } 312 | 313 | @function _encode-map($map) { 314 | @return _encode-iterable($map); 315 | } 316 | 317 | @function _encode-iterable($iterable) { 318 | $is-list: type-of($iterable) == "list"; 319 | $is-map: type-of($iterable) == "map"; 320 | 321 | $str: ""; 322 | $opening-bracket: if($is-list, "[", "{"); 323 | $closing-bracket: if($is-list, "]", "}"); 324 | 325 | @each $key, $value in $iterable { 326 | $entry-string: ""; 327 | 328 | @if ($is-list) { 329 | $entry-string: json-stringify($key); 330 | } @else if ($is-map) { 331 | $entry-string: stringify($key) + ": " + json-stringify($value); 332 | } 333 | 334 | $str: $str + ", " + $entry-string; 335 | } 336 | 337 | $str: str-slice($str, 3); // remove leading ', ' from ', entry1, entry2' 338 | 339 | @return $opening-bracket + $str + $closing-bracket; 340 | } 341 | 342 | // ===================================================================================================================== 343 | // Helper functions for theme variables 344 | 345 | // This function composes padding variables for a given subject taking into 346 | // account all possible padding directions 347 | @function composePaddingVars($themeVars, $subject) { 348 | $tmp: appendThemeVar($themeVars, "padding-#{$subject}") !global; 349 | $tmpAll: getThemeVar($tmp, "padding-#{$subject}"); 350 | $tmp: appendThemeVarWithDefault($tmp, "paddingHorizontal-#{$subject}", $tmpAll) !global; 351 | $tmpHorizontal: getThemeVar($tmp, "paddingHorizontal-#{$subject}"); 352 | $tmp: appendThemeVarWithDefault($tmp, "paddingVertical-#{$subject}", $tmpAll) !global; 353 | $tmpVertical: getThemeVar($tmp, "paddingVertical-#{$subject}"); 354 | $tmp: appendThemeVarWithDefault($tmp, "paddingLeft-#{$subject}", $tmpHorizontal) !global; 355 | $tmp: appendThemeVarWithDefault($tmp, "paddingRight-#{$subject}", $tmpHorizontal) !global; 356 | $tmp: appendThemeVarWithDefault($tmp, "paddingTop-#{$subject}", $tmpVertical) !global; 357 | $tmp: appendThemeVarWithDefault($tmp, "paddingBottom-#{$subject}", $tmpVertical) !global; 358 | @return $tmp; 359 | } 360 | 361 | // This mixin applies padding variables to a given subject 362 | @mixin paddingVars($themeVars, $subject) { 363 | padding: getThemeVar($themeVars, "padding-#{$subject}"); 364 | padding-left: getThemeVar($themeVars, "paddingLeft-#{$subject}"); 365 | padding-right: getThemeVar($themeVars, "paddingRight-#{$subject}"); 366 | padding-top: getThemeVar($themeVars, "paddingTop-#{$subject}"); 367 | padding-bottom: getThemeVar($themeVars, "paddingBottom-#{$subject}"); 368 | } 369 | 370 | // This function composes padding variables for a given subject taking into 371 | // account all possible padding directions 372 | @function composeBorderVars($themeVars, $subject) { 373 | $tmp: appendThemeVar($themeVars, "border-#{$subject}") !global; 374 | $tmpAll: getThemeVar($tmp, "border-#{$subject}"); 375 | $tmp: appendThemeVarWithDefault($tmp, "borderHorizontal-#{$subject}", $tmpAll) !global; 376 | $tmpHorizontal: getThemeVar($tmp, "borderHorizontal-#{$subject}"); 377 | $tmp: appendThemeVarWithDefault($tmp, "borderVertical-#{$subject}", $tmpAll) !global; 378 | $tmpVertical: getThemeVar($tmp, "borderVertical-#{$subject}"); 379 | $tmp: appendThemeVarWithDefault($tmp, "borderLeft-#{$subject}", $tmpHorizontal) !global; 380 | $tmp: appendThemeVarWithDefault($tmp, "borderRight-#{$subject}", $tmpHorizontal) !global; 381 | $tmp: appendThemeVarWithDefault($tmp, "borderTop-#{$subject}", $tmpVertical) !global; 382 | $tmp: appendThemeVarWithDefault($tmp, "borderBottom-#{$subject}", $tmpVertical) !global; 383 | 384 | $tmp: appendThemeVar($tmp, "borderWidth-#{$subject}") !global; 385 | $tmpThickness: getThemeVar($tmp, "borderWidth-#{$subject}"); 386 | $tmp: appendThemeVarWithDefault($tmp, "borderHorizontalWidth-#{$subject}", $tmpThickness) !global; 387 | $tmpThicknessHorizontal: getThemeVar($tmp, "borderHorizontalWidth-#{$subject}"); 388 | $tmp: appendThemeVarWithDefault( 389 | $tmp, 390 | "borderLeftWidth-#{$subject}", 391 | $tmpThicknessHorizontal 392 | ) !global; 393 | $tmp: appendThemeVarWithDefault( 394 | $tmp, 395 | "borderRightWidth-#{$subject}", 396 | $tmpThicknessHorizontal 397 | ) !global; 398 | $tmp: appendThemeVarWithDefault($tmp, "borderVerticalWidth-#{$subject}", $tmpThickness) !global; 399 | $tmpThicknessVertical: getThemeVar($tmp, "borderVerticalWidth-#{$subject}"); 400 | $tmp: appendThemeVarWithDefault( 401 | $tmp, 402 | "borderTopWidth-#{$subject}", 403 | $tmpThicknessVertical 404 | ) !global; 405 | $tmp: appendThemeVarWithDefault( 406 | $tmp, 407 | "borderBottomWidth-#{$subject}", 408 | $tmpThicknessVertical 409 | ) !global; 410 | 411 | $tmp: appendThemeVar($tmp, "borderStyle-#{$subject}") !global; 412 | $tmpStyle: getThemeVar($tmp, "borderStyle-#{$subject}"); 413 | $tmp: appendThemeVarWithDefault($tmp, "borderHorizontalStyle-#{$subject}", $tmpStyle) !global; 414 | $tmpStyleHorizontal: getThemeVar($tmp, "borderHorizontalStyle-#{$subject}"); 415 | $tmp: appendThemeVarWithDefault($tmp, "borderLeftStyle-#{$subject}", $tmpStyleHorizontal) !global; 416 | $tmp: appendThemeVarWithDefault( 417 | $tmp, 418 | "borderRightStyle-#{$subject}", 419 | $tmpStyleHorizontal 420 | ) !global; 421 | $tmp: appendThemeVarWithDefault($tmp, "borderVerticalStyle-#{$subject}", $tmpStyle) !global; 422 | $tmpStyleVertical: getThemeVar($tmp, "borderVerticalStyle-#{$subject}"); 423 | $tmp: appendThemeVarWithDefault($tmp, "borderTopStyle-#{$subject}", $tmpStyleVertical) !global; 424 | $tmp: appendThemeVarWithDefault($tmp, "borderBottomStyle-#{$subject}", $tmpStyleVertical) !global; 425 | 426 | $tmp: appendThemeVar($tmp, "borderColor-#{$subject}") !global; 427 | $tmpColor: getThemeVar($tmp, "borderColor-#{$subject}"); 428 | $tmp: appendThemeVarWithDefault($tmp, "borderHorizontalColor-#{$subject}", $tmpColor) !global; 429 | $tmpColorHorizontal: getThemeVar($tmp, "borderHorizontalColor-#{$subject}"); 430 | $tmp: appendThemeVarWithDefault($tmp, "borderLeftColor-#{$subject}", $tmpColorHorizontal) !global; 431 | $tmp: appendThemeVarWithDefault( 432 | $tmp, 433 | "borderRightColor-#{$subject}", 434 | $tmpColorHorizontal 435 | ) !global; 436 | $tmp: appendThemeVarWithDefault($tmp, "borderVerticalColor-#{$subject}", $tmpColor) !global; 437 | $tmpColorVertical: getThemeVar($tmp, "borderVerticalColor-#{$subject}"); 438 | $tmp: appendThemeVarWithDefault($tmp, "borderTopColor-#{$subject}", $tmpColorVertical) !global; 439 | $tmp: appendThemeVarWithDefault($tmp, "borderBottomColor-#{$subject}", $tmpColorVertical) !global; 440 | 441 | $tmpRadius: appendThemeVar($tmp, "borderRadius-#{$subject}") !global; 442 | $tmpRadiusAll: getThemeVar($tmpRadius, "borderRadius-#{$subject}") !global; 443 | $tmp: appendThemeVarWithDefault( 444 | $tmp, 445 | "borderStartStartRadius-#{$subject}", 446 | $tmpRadiusAll 447 | ) !global; 448 | $tmp: appendThemeVarWithDefault($tmp, "borderStartEndRadius-#{$subject}", $tmpRadiusAll) !global; 449 | $tmp: appendThemeVarWithDefault($tmp, "borderEndStartRadius-#{$subject}", $tmpRadiusAll) !global; 450 | $tmp: appendThemeVarWithDefault($tmp, "borderEndEndRadius-#{$subject}", $tmpRadiusAll) !global; 451 | $tmp: appendThemeVar($tmp, "borderStyle-#{$subject}") !global; 452 | @return $tmp; 453 | } 454 | 455 | // This mixin applies padding variables to a given subject 456 | @mixin borderVars($themeVars, $subject) { 457 | border-left: getThemeVar($themeVars, "borderLeft-#{$subject}"); 458 | border-right: getThemeVar($themeVars, "borderRight-#{$subject}"); 459 | border-top: getThemeVar($themeVars, "borderTop-#{$subject}"); 460 | border-bottom: getThemeVar($themeVars, "borderBottom-#{$subject}"); 461 | border-left-style: getThemeVar($themeVars, "borderLeftStyle-#{$subject}"); 462 | border-right-style: getThemeVar($themeVars, "borderRightStyle-#{$subject}"); 463 | border-top-style: getThemeVar($themeVars, "borderTopStyle-#{$subject}"); 464 | border-bottom-style: getThemeVar($themeVars, "borderBottomStyle-#{$subject}"); 465 | border-left-width: getThemeVar($themeVars, "borderLeftWidth-#{$subject}"); 466 | border-right-width: getThemeVar($themeVars, "borderRightWidth-#{$subject}"); 467 | border-top-width: getThemeVar($themeVars, "borderTopWidth-#{$subject}"); 468 | border-bottom-width: getThemeVar($themeVars, "borderBottomWidth-#{$subject}"); 469 | border-left-color: getThemeVar($themeVars, "borderLeftColor-#{$subject}"); 470 | border-right-color: getThemeVar($themeVars, "borderRightColor-#{$subject}"); 471 | border-top-color: getThemeVar($themeVars, "borderTopColor-#{$subject}"); 472 | border-bottom-color: getThemeVar($themeVars, "borderBottomColor-#{$subject}"); 473 | border-radius: getThemeVar($themeVars, "borderRadius-#{$subject}"); 474 | border-start-start-radius: getThemeVar($themeVars, "borderStartStartRadius-#{$subject}"); 475 | border-start-end-radius: getThemeVar($themeVars, "borderStartEndRadius-#{$subject}"); 476 | border-end-start-radius: getThemeVar($themeVars, "borderEndStartRadius-#{$subject}"); 477 | border-end-end-radius: getThemeVar($themeVars, "borderEndEndRadius-#{$subject}"); 478 | } 479 | 480 | // This function composes style variables for setting styles of text elements 481 | @function composeTextVars($themeVars, $subject, $default: false) { 482 | $tmp: if( 483 | $default, 484 | appendThemeVarWithFallback($themeVars, "textColor-#{$subject}", "textColor-#{$default}"), 485 | appendThemeVar($themeVars, "textColor-#{$subject}") 486 | ) !global; 487 | $tmp: if( 488 | $default, 489 | appendThemeVarWithFallback($tmp, "fontFamily-#{$subject}", "fontFamily-#{$default}"), 490 | appendThemeVar($tmp, "fontFamily-#{$subject}") 491 | ) !global; 492 | $tmp: if( 493 | $default, 494 | appendThemeVarWithFallback($tmp, "fontSize-#{$subject}", "fontSize-#{$default}"), 495 | appendThemeVar($tmp, "fontSize-#{$subject}") 496 | ) !global; 497 | $tmp: if( 498 | $default, 499 | appendThemeVarWithFallback($tmp, "fontStyle-#{$subject}", "fontStyle-#{$default}"), 500 | appendThemeVar($tmp, "fontStyle-#{$subject}") 501 | ) !global; 502 | $tmp: if( 503 | $default, 504 | appendThemeVarWithFallback($tmp, "fontVariant-#{$subject}", "fontVariant-#{$default}"), 505 | appendThemeVar($tmp, "fontVariant-#{$subject}") 506 | ) !global; 507 | $tmp: if( 508 | $default, 509 | appendThemeVarWithFallback($tmp, "fontWeight-#{$subject}", "fontWeight-#{$default}"), 510 | appendThemeVar($tmp, "fontWeight-#{$subject}") 511 | ) !global; 512 | $tmp: if( 513 | $default, 514 | appendThemeVarWithFallback($tmp, "fontStretch-#{$subject}", "fontStretch-#{$default}"), 515 | appendThemeVar($tmp, "fontStretch-#{$subject}") 516 | ) !global; 517 | $tmp: if( 518 | $default, 519 | appendThemeVarWithFallback( 520 | $tmp, 521 | "textDecorationLine-#{$subject}", 522 | "textDecorationLine-#{$default}" 523 | ), 524 | appendThemeVar($tmp, "textDecorationLine-#{$subject}") 525 | ) !global; 526 | $tmp: if( 527 | $default, 528 | appendThemeVarWithFallback( 529 | $tmp, 530 | "textDecorationColor-#{$subject}", 531 | "textDecorationColor-#{$default}" 532 | ), 533 | appendThemeVar($tmp, "textDecorationColor-#{$subject}") 534 | ) !global; 535 | $tmp: if( 536 | $default, 537 | appendThemeVarWithFallback( 538 | $tmp, 539 | "textDecorationStyle-#{$subject}", 540 | "textDecorationStyle-#{$default}" 541 | ), 542 | appendThemeVar($tmp, "textDecorationStyle-#{$subject}") 543 | ) !global; 544 | $tmp: if( 545 | $default, 546 | appendThemeVarWithFallback( 547 | $tmp, 548 | "textDecorationThickness-#{$subject}", 549 | "textDecorationThickness-#{$default}" 550 | ), 551 | appendThemeVar($tmp, "textDecorationThickness-#{$subject}") 552 | ) !global; 553 | $tmp: if( 554 | $default, 555 | appendThemeVarWithFallback( 556 | $tmp, 557 | "textUnderlineOffset-#{$subject}", 558 | "textUnderlineOffset-#{$default}" 559 | ), 560 | appendThemeVar($tmp, "textUnderlineOffset-#{$subject}") 561 | ) !global; 562 | $tmp: if( 563 | $default, 564 | appendThemeVarWithFallback($tmp, "lineHeight-#{$subject}", "lineHeight-#{$default}"), 565 | appendThemeVar($tmp, "lineHeight-#{$subject}") 566 | ) !global; 567 | $tmp: if( 568 | $default, 569 | appendThemeVarWithFallback($tmp, "backgroundColor-#{$subject}", "backgroundColor-#{$default}"), 570 | appendThemeVar($tmp, "backgroundColor-#{$subject}") 571 | ) !global; 572 | $tmp: if( 573 | $default, 574 | appendThemeVarWithFallback($tmp, "textTransform-#{$subject}", "textTransform-#{$default}"), 575 | appendThemeVar($tmp, "textTransform-#{$subject}") 576 | ) !global; 577 | $tmp: if( 578 | $default, 579 | appendThemeVarWithFallback($tmp, "letterSpacing-#{$subject}", "letterSpacing-#{$default}"), 580 | appendThemeVar($tmp, "letterSpacing-#{$subject}") 581 | ) !global; 582 | $tmp: if( 583 | $default, 584 | appendThemeVarWithFallback($tmp, "wordSpacing-#{$subject}", "wordSpacing-#{$default}"), 585 | appendThemeVar($tmp, "wordSpacing-#{$subject}") 586 | ) !global; 587 | $tmp: if( 588 | $default, 589 | appendThemeVarWithFallback($tmp, "textShadow-#{$subject}", "textShadow-#{$default}"), 590 | appendThemeVar($tmp, "textShadow-#{$subject}") 591 | ) !global; 592 | $tmp: if( 593 | $default, 594 | appendThemeVarWithFallback($tmp, "textIndent-#{$subject}", "textIndent-#{$default}"), 595 | appendThemeVar($tmp, "textIndent-#{$subject}") 596 | ) !global; 597 | $tmp: if( 598 | $default, 599 | appendThemeVarWithFallback($tmp, "textAlign-#{$subject}", "textAlign-#{$default}"), 600 | appendThemeVar($tmp, "textAlign-#{$subject}") 601 | ) !global; 602 | $tmp: if( 603 | $default, 604 | appendThemeVarWithFallback($tmp, "textAlignLast-#{$subject}", "textAlignLast-#{$default}"), 605 | appendThemeVar($tmp, "textAlignLast-#{$subject}") 606 | ) !global; 607 | $tmp: if( 608 | $default, 609 | appendThemeVarWithFallback($tmp, "wordBreak-#{$subject}", "wordBreak-#{$default}"), 610 | appendThemeVar($tmp, "wordBreak-#{$subject}") 611 | ) !global; 612 | $tmp: if( 613 | $default, 614 | appendThemeVarWithFallback($tmp, "wordWrap-#{$subject}", "wordWrap-#{$default}"), 615 | appendThemeVar($tmp, "wordWrap-#{$subject}") 616 | ) !global; 617 | $tmp: if( 618 | $default, 619 | appendThemeVarWithFallback($tmp, "direction-#{$subject}", "direction-#{$default}"), 620 | appendThemeVar($tmp, "direction-#{$subject}") 621 | ) !global; 622 | $tmp: if( 623 | $default, 624 | appendThemeVarWithFallback($tmp, "writingMode-#{$subject}", "writingMode-#{$default}"), 625 | appendThemeVar($tmp, "writingMode-#{$subject}") 626 | ) !global; 627 | $tmp: if( 628 | $default, 629 | appendThemeVarWithFallback($tmp, "lineBreak-#{$subject}", "lineBreak-#{$default}"), 630 | appendThemeVar($tmp, "lineBreak-#{$subject}") 631 | ) !global; 632 | @return $tmp; 633 | } 634 | 635 | @mixin textVars($themeVars, $subject) { 636 | color: getThemeVar($themeVars, "textColor-#{$subject}"); 637 | font-family: getThemeVar($themeVars, "fontFamily-#{$subject}"); 638 | font-size: getThemeVar($themeVars, "fontSize-#{$subject}"); 639 | font-style: getThemeVar($themeVars, "fontStyle-#{$subject}"); 640 | font-weight: getThemeVar($themeVars, "fontWeight-#{$subject}"); 641 | font-stretch: getThemeVar($themeVars, "fontStretch-#{$subject}"); 642 | text-decoration-line: getThemeVar($themeVars, "textDecorationLine-#{$subject}"); 643 | text-decoration-color: getThemeVar($themeVars, "textDecorationColor-#{$subject}"); 644 | text-decoration-style: getThemeVar($themeVars, "textDecorationStyle-#{$subject}"); 645 | text-decoration-thickness: getThemeVar($themeVars, "textDecorationThickness-#{$subject}"); 646 | text-underline-offset: getThemeVar($themeVars, "textUnderlineOffset-#{$subject}"); 647 | line-height: getThemeVar($themeVars, "lineHeight-#{$subject}"); 648 | background-color: getThemeVar($themeVars, "backgroundColor-#{$subject}"); 649 | text-transform: getThemeVar($themeVars, "textTransform-#{$subject}"); 650 | letter-spacing: getThemeVar($themeVars, "letterSpacing-#{$subject}"); 651 | word-spacing: getThemeVar($themeVars, "wordSpacing-#{$subject}"); 652 | text-shadow: getThemeVar($themeVars, "textShadow-#{$subject}"); 653 | text-indent: getThemeVar($themeVars, "textIndent-#{$subject}"); 654 | text-align: getThemeVar($themeVars, "textAlign-#{$subject}"); 655 | text-align-last: getThemeVar($themeVars, "textAlignLast-#{$subject}"); 656 | word-break: getThemeVar($themeVars, "wordBreak-#{$subject}"); 657 | word-wrap: getThemeVar($themeVars, "wordWrap-#{$subject}"); 658 | direction: getThemeVar($themeVars, "direction-#{$subject}"); 659 | writing-mode: getThemeVar($themeVars, "writingMode-#{$subject}"); 660 | line-break: getThemeVar($themeVars, "lineBreak-#{$subject}"); 661 | } 662 | 663 | @mixin ignoreTextVars() { 664 | color: inherit !important; 665 | font-family: inherit !important; 666 | font-size: inherit !important; 667 | font-style: inherit !important; 668 | font-weight: inherit !important; 669 | font-stretch: inherit !important; 670 | text-decoration-line: inherit !important; 671 | text-decoration-color: inherit !important; 672 | text-decoration-style: inherit !important; 673 | text-decoration-thickness: inherit !important; 674 | text-underline-offset: inherit !important; 675 | line-height: inherit !important; 676 | background-color: inherit !important; 677 | text-transform: inherit !important; 678 | letter-spacing: inherit !important; 679 | word-spacing: inherit !important; 680 | text-shadow: inherit !important; 681 | text-indent: inherit !important; 682 | text-align: inherit !important; 683 | text-align-last: inherit !important; 684 | word-break: inherit !important; 685 | word-wrap: inherit !important; 686 | direction: inherit !important; 687 | writing-mode: inherit !important; 688 | line-break: inherit !important; 689 | } 690 | 691 | @mixin withMaxScreenSize($maxScreenSize) { 692 | $query: ""; 693 | @for $i from 0 through $maxScreenSize { 694 | @if $query == "" { 695 | $query: "style(--screenSize: #{$i})"; 696 | } @else { 697 | $query: "#{$query} or style(--screenSize: #{$i})"; 698 | } 699 | } 700 | 701 | @container (#{$query}) { 702 | @content; 703 | } 704 | } 705 | 706 | // ===================================================================================================================== 707 | // CSS variables for miscellaneous shadows 708 | $boxShadow: 709 | 0 1px 3px 0 rgba(0, 0, 0, 0.1), 710 | 0 1px 2px 0 rgba(0, 0, 0, 0.06); 711 | $boxShadow-md: 712 | 0 4px 6px -1px rgba(0, 0, 0, 0.1), 713 | 0 2px 4px -1px rgba(0, 0, 0, 0.06); 714 | $boxShadow-xxl: 715 | 0 8px 17px 0 rgba(0, 0, 0, 0.2), 716 | 0 6px 20px 0 rgba(0, 0, 0, 0.19); 717 | 718 | $boxShadow-spread: 0px 0px 30px rgba(0, 0, 0, 0.1); 719 | $boxShadow-spread-2: -6px -4px 40px 10px rgba(0, 0, 0, 0.1); 720 | $boxShadow-spread-2-xl: -6px -4px 40px 18px rgba(0, 0, 0, 0.1); 721 | 722 | // CSS variables describing spacing between UI elements 723 | $space-0: createVar(space-0); 724 | $space-0_5: createVar(space-0_5); 725 | $space-1: createVar(space-1); 726 | $space-1_5: createVar(space-1_5); 727 | $space-2: createVar(space-2); 728 | $space-2_5: createVar(space-2_5); 729 | $space-3: createVar(space-3); 730 | $space-3_5: createVar(space-3_5); 731 | $space-4: createVar(space-4); 732 | $space-5: createVar(space-5); 733 | $space-6: createVar(space-6); 734 | $space-7: createVar(space-7); 735 | $space-8: createVar(space-8); 736 | $space-9: createVar(space-9); 737 | $space-10: createVar(space-10); 738 | $space-11: createVar(space-11); 739 | $space-12: createVar(space-12); 740 | $space-14: createVar(space-14); 741 | $space-16: createVar(space-16); 742 | $space-20: createVar(space-20); 743 | $space-24: createVar(space-24); 744 | $space-28: createVar(space-28); 745 | $space-32: createVar(space-32); 746 | $space-36: createVar(space-36); 747 | $space-40: createVar(space-40); 748 | $space-44: createVar(space-44); 749 | $space-48: createVar(space-48); 750 | $space-52: createVar(space-52); 751 | $space-56: createVar(space-56); 752 | $space-60: createVar(space-60); 753 | $space-64: createVar(space-64); 754 | $space-72: createVar(space-72); 755 | $space-80: createVar(space-80); 756 | $space-96: createVar(space-96); 757 | 758 | // --------------------------------------------------------------------------------------------------------------------- 759 | // Generic style variables 760 | 761 | $textColor-primary: createVar(textColor-primary); 762 | $textColor-attention: createVar(textColor-attention); 763 | $backgroundColor-attention: createVar(backgroundColor-attention); 764 | $textColor-subtitle: createVar(textColor-subtitle); 765 | $backgroundColor-primary: createVar(backgroundColor-primary); 766 | $backgroundColor-secondary: createVar(backgroundColor-secondary); 767 | $backgroundColor-Input-default: createVar(backgroundColor-Input-default); 768 | $textColor--disabled: createVar(textColor--disabled); 769 | $backgroundColor--disabled: createVar(backgroundColor--disabled); 770 | $borderColor--disabled: createVar(borderColor--disabled); 771 | $backgroundColor--selected: createVar(backgroundColor--selected); 772 | $fontFamily: createVar(fontFamily); 773 | $fontSize-tiny: createVar(fontSize-tiny); 774 | $fontSize-xs: createVar(fontSize-xs); 775 | $fontSize-sm: createVar(fontSize-sm); 776 | $fontSize-base: createVar(fontSize-base); 777 | $fontSize-xl: createVar(fontSize-xl); 778 | $fontSize-2xl: createVar(fontSize-2xl); 779 | 780 | $backgroundColor-overlay: createVar(backgroundColor-overlay); 781 | $color-info: createVar(color-info); 782 | $color-valid: createVar(color-valid); 783 | $color-warning: createVar(color-warning); 784 | $color-error: createVar(color-error); 785 | 786 | $borderColor: createVar(borderColor); 787 | 788 | $maxWidth-content: createVar(maxWidth-content); 789 | $direction: createVar(direction); 790 | 791 | $font-feature-settings: createVar(font-feature-settings); 792 | 793 | $outlineColor--focus: createVar(outlineColor--focus); 794 | $outlineWidth--focus: createVar(outlineWidth--focus); 795 | $outlineStyle--focus: createVar(outlineStyle--focus); 796 | $outlineOffset--focus: createVar(outlineOffset--focus); 797 | $focus-outline: $outlineWidth--focus $outlineStyle--focus $outlineColor--focus; 798 | 799 | $media-max-width-phone: createVar(media-max-width-phone); 800 | $media-max-width-tablet: createVar(media-max-width-tablet); 801 | 802 | // --------------------------------------------------------------------------------------------------------------------- 803 | // Dropdown style variables 804 | 805 | $backgroundColor-dropdown-item: createVar(backgroundColor-dropdown-item); 806 | $backgroundColor-dropdown-item--active: createVar(backgroundColor-dropdown-item--active); 807 | $borderColor-dropdown-item: createVar(borderColor-dropdown-item); 808 | 809 | // --------------------------------------------------------------------------------------------------------------------- 810 | // Tree style variables 811 | $backgroundColor-tree-row--selected--before: createVar(backgroundColor-tree-row--selected--before); 812 | 813 | // --------------------------------------------------------------------------------------------------------------------- 814 | // Input border style variables 815 | 816 | $borderColor-Input-default: createVar(borderColor-Input-default); 817 | $borderColor-Input-default--hover: createVar(borderColor-Input-default--hover); 818 | $borderColor-Input-default--success: createVar(borderColor-Input-default--success); 819 | $borderColor-Input-default--warning: createVar(borderColor-Input-default--warning); 820 | $borderColor-Input-default--error: createVar(borderColor-Input-default--error); 821 | 822 | // --------------------------------------------------------------------------------------------------------------------- 823 | // InputLabel style variables 824 | 825 | $textColor-InputLabel-required: createVar(textColor-InputLabel-required); 826 | 827 | // --------------------------------------------------------------------------------------------------------------------- 828 | // formItem style variables 829 | $textColor-FormItemLabel: createVar(textColor-FormItemLabel); 830 | $fontSize-FormItemLabel: createVar(fontSize-FormItemLabel); 831 | $fontWeight-FormItemLabel: createVar(fontWeight-FormItemLabel); 832 | 833 | //---------------------------------------------------------------------------------------------------------------------- 834 | // Tab style variables 835 | 836 | $color-primary-500: createVar(color-primary-500); 837 | $color-danger-500: createVar(color-danger-500); 838 | 839 | $backgroundColor: createVar(backgroundColor); 840 | 841 | $textColor-secondary: createVar(textColor-secondary); 842 | 843 | $fontWeight-light: createVar(fontWeight-light); 844 | $fontWeight-normal: createVar(fontWeight-normal); 845 | $fontWeight-medium: createVar(fontWeight-medium); 846 | $fontWeight-bold: createVar(fontWeight-bold); 847 | 848 | $borderRadius: createVar(borderRadius); 849 | 850 | // body 851 | $fontSize: createVar(fontSize); 852 | $fontWeight: createVar(fontWeight); 853 | ```