@threadlabs/looma 0.52.12 → 0.53.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/shared/overlay.js +7 -0
- package/components/ui-editor-toolbar/ui-editor-toolbar.html +2 -2
- package/components/ui-meter/ui-meter.html +1 -1
- package/dist/index.js +1 -1
- package/docs/catalog.json +1 -1
- package/editor/chunks/extensions.js +2 -2
- package/editor/components.css +19 -19
- package/editor/index.js +1125 -853
- package/package.json +3 -3
- package/styles/ui-action-bar.css +1 -1
- package/styles/ui-affordance-scope.css +1 -1
- package/styles/ui-avatar-group.css +1 -1
- package/styles/ui-avatar.css +1 -1
- package/styles/ui-badge.css +1 -1
- package/styles/ui-breadcrumb-item.css +1 -1
- package/styles/ui-breadcrumbs.css +1 -1
- package/styles/ui-button.css +1 -1
- package/styles/ui-calendar.css +1 -1
- package/styles/ui-callout.css +1 -1
- package/styles/ui-card-group.css +1 -1
- package/styles/ui-card.css +1 -1
- package/styles/ui-checkbox.css +1 -1
- package/styles/ui-cluster.css +1 -1
- package/styles/ui-color-picker.css +1 -1
- package/styles/ui-column.css +1 -1
- package/styles/ui-combobox.css +1 -1
- package/styles/ui-compact-content.css +1 -1
- package/styles/ui-compact-editor.css +1 -1
- package/styles/ui-compact-mark.css +1 -1
- package/styles/ui-compact-node.css +1 -1
- package/styles/ui-container.css +1 -1
- package/styles/ui-context-menu.css +1 -1
- package/styles/ui-cover.css +1 -1
- package/styles/ui-curve-editor.css +1 -1
- package/styles/ui-cycle-button.css +1 -1
- package/styles/ui-data-table.css +1 -1
- package/styles/ui-date-field.css +1 -1
- package/styles/ui-date-picker.css +1 -1
- package/styles/ui-date-range-picker.css +1 -1
- package/styles/ui-description-item.css +1 -1
- package/styles/ui-description-list.css +1 -1
- package/styles/ui-dialog.css +1 -1
- package/styles/ui-disclosure.css +1 -1
- package/styles/ui-editable.css +1 -1
- package/styles/ui-editor-block-actions.css +1 -1
- package/styles/ui-editor-chip-editor.css +1 -1
- package/styles/ui-editor-code-language.css +1 -1
- package/styles/ui-editor-footnote-editor.css +1 -1
- package/styles/ui-editor-formatting-tools.css +1 -1
- package/styles/ui-editor-image-toolbar.css +1 -1
- package/styles/ui-editor-insert-table-grid.css +1 -1
- package/styles/ui-editor-link-card.css +1 -1
- package/styles/ui-editor-link-form.css +1 -1
- package/styles/ui-editor-mention-menu-item.css +1 -1
- package/styles/ui-editor-mention-menu.css +1 -1
- package/styles/ui-editor-slash-menu-group.css +1 -1
- package/styles/ui-editor-slash-menu-item.css +1 -1
- package/styles/ui-editor-slash-menu.css +1 -1
- package/styles/ui-editor-surface.css +1 -1
- package/styles/ui-editor-table-context-menu.css +1 -1
- package/styles/ui-editor-table-overlay.css +1 -1
- package/styles/ui-editor-table-toolbar.css +1 -1
- package/styles/ui-editor-toolbar.css +1 -1
- package/styles/ui-editor.css +1 -1
- package/styles/ui-file-input.css +1 -1
- package/styles/ui-floating-action-button.css +1 -1
- package/styles/ui-form-field.css +1 -1
- package/styles/ui-grid.css +1 -1
- package/styles/ui-icon-button.css +1 -1
- package/styles/ui-icon.css +1 -1
- package/styles/ui-image.css +1 -1
- package/styles/ui-input-group.css +1 -1
- package/styles/ui-input.css +1 -1
- package/styles/ui-light-editor.css +1 -1
- package/styles/ui-list-item.css +1 -1
- package/styles/ui-list.css +1 -1
- package/styles/ui-listbox.css +1 -1
- package/styles/ui-menu-group.css +1 -1
- package/styles/ui-menu-item.css +1 -1
- package/styles/ui-menu.css +1 -1
- package/styles/ui-meter.css +1 -1
- package/styles/ui-nav-item.css +1 -1
- package/styles/ui-notice-stripe.css +1 -1
- package/styles/ui-number-input.css +1 -1
- package/styles/ui-page-header.css +1 -1
- package/styles/ui-pagination.css +1 -1
- package/styles/ui-popover.css +1 -1
- package/styles/ui-radio-group.css +1 -1
- package/styles/ui-radio.css +1 -1
- package/styles/ui-reel.css +1 -1
- package/styles/ui-scroll-area.css +1 -1
- package/styles/ui-search-result-row.css +1 -1
- package/styles/ui-search-shell.css +1 -1
- package/styles/ui-section.css +1 -1
- package/styles/ui-segmented-control.css +1 -1
- package/styles/ui-select.css +1 -1
- package/styles/ui-separator.css +1 -1
- package/styles/ui-sidebar.css +1 -1
- package/styles/ui-site-header.css +1 -1
- package/styles/ui-skeleton.css +1 -1
- package/styles/ui-slider.css +1 -1
- package/styles/ui-spinner.css +1 -1
- package/styles/ui-stack.css +1 -1
- package/styles/ui-status-message.css +1 -1
- package/styles/ui-swatch.css +1 -1
- package/styles/ui-switch.css +1 -1
- package/styles/ui-switcher.css +1 -1
- package/styles/ui-table.css +1 -1
- package/styles/ui-tabs.css +1 -1
- package/styles/ui-text.css +1 -1
- package/styles/ui-textarea.css +1 -1
- package/styles/ui-time-field.css +1 -1
- package/styles/ui-time-picker.css +1 -1
- package/styles/ui-toast-region.css +1 -1
- package/styles/ui-toast.css +1 -1
- package/styles/ui-tooltip.css +1 -1
- package/styles/ui-top-bar.css +1 -1
- package/styles/ui-tree-item.css +1 -1
- package/styles/ui-tree.css +1 -1
- package/styles/ui-wizard.css +1 -1
- package/vanilla/UiActionBar.d.ts +1 -1
- package/vanilla/UiActionBar.js +14 -12
- package/vanilla/UiAffordanceScope.d.ts +1 -1
- package/vanilla/UiAffordanceScope.js +13 -11
- package/vanilla/UiAvatar.d.ts +1 -1
- package/vanilla/UiAvatar.js +27 -25
- package/vanilla/UiAvatarGroup.d.ts +1 -1
- package/vanilla/UiAvatarGroup.js +26 -23
- package/vanilla/UiBadge.d.ts +1 -1
- package/vanilla/UiBadge.js +14 -12
- package/vanilla/UiBreadcrumbItem.d.ts +1 -1
- package/vanilla/UiBreadcrumbItem.js +14 -13
- package/vanilla/UiBreadcrumbs.d.ts +1 -1
- package/vanilla/UiBreadcrumbs.js +10 -10
- package/vanilla/UiButton.d.ts +1 -1
- package/vanilla/UiButton.js +187 -244
- package/vanilla/UiCalendar.d.ts +1 -1
- package/vanilla/UiCalendar.js +272 -193
- package/vanilla/UiCallout.d.ts +1 -1
- package/vanilla/UiCallout.js +32 -27
- package/vanilla/UiCard.d.ts +1 -1
- package/vanilla/UiCard.js +72 -69
- package/vanilla/UiCardGroup.d.ts +1 -1
- package/vanilla/UiCardGroup.js +17 -15
- package/vanilla/UiCheckbox.d.ts +1 -1
- package/vanilla/UiCheckbox.js +32 -30
- package/vanilla/UiCluster.d.ts +1 -1
- package/vanilla/UiCluster.js +20 -18
- package/vanilla/UiColorPicker.d.ts +1 -1
- package/vanilla/UiColorPicker.js +22 -20
- package/vanilla/UiColumn.d.ts +2 -2
- package/vanilla/UiColumn.js +18 -15
- package/vanilla/UiCombobox.d.ts +3 -3
- package/vanilla/UiCombobox.js +237 -174
- package/vanilla/UiCompactContent.d.ts +1 -1
- package/vanilla/UiCompactContent.js +13 -8
- package/vanilla/UiCompactEditor.d.ts +1 -1
- package/vanilla/UiCompactEditor.js +17 -12
- package/vanilla/UiCompactMark.d.ts +1 -1
- package/vanilla/UiCompactMark.js +47 -45
- package/vanilla/UiCompactNode.d.ts +2 -2
- package/vanilla/UiCompactNode.js +37 -33
- package/vanilla/UiContainer.d.ts +1 -1
- package/vanilla/UiContainer.js +13 -11
- package/vanilla/UiContextMenu.d.ts +1 -1
- package/vanilla/UiContextMenu.js +11 -9
- package/vanilla/UiCover.d.ts +1 -1
- package/vanilla/UiCover.js +13 -11
- package/vanilla/UiCurveEditor.d.ts +1 -1
- package/vanilla/UiCurveEditor.js +40 -38
- package/vanilla/UiCycleButton.d.ts +2 -2
- package/vanilla/UiCycleButton.js +31 -26
- package/vanilla/UiDataTable.d.ts +1 -1
- package/vanilla/UiDataTable.js +26 -20
- package/vanilla/UiDateField.d.ts +1 -1
- package/vanilla/UiDateField.js +78 -75
- package/vanilla/UiDatePicker.d.ts +1 -1
- package/vanilla/UiDatePicker.js +155 -149
- package/vanilla/UiDateRangePicker.d.ts +1 -1
- package/vanilla/UiDateRangePicker.js +136 -128
- package/vanilla/UiDescriptionItem.d.ts +1 -1
- package/vanilla/UiDescriptionItem.js +13 -11
- package/vanilla/UiDescriptionList.d.ts +1 -1
- package/vanilla/UiDescriptionList.js +13 -11
- package/vanilla/UiDialog.d.ts +1 -1
- package/vanilla/UiDialog.js +14 -14
- package/vanilla/UiDisclosure.d.ts +1 -1
- package/vanilla/UiDisclosure.js +28 -26
- package/vanilla/UiEditable.d.ts +1 -1
- package/vanilla/UiEditable.js +29 -27
- package/vanilla/UiEditor.d.ts +1 -1
- package/vanilla/UiEditor.js +62 -58
- package/vanilla/UiEditorBlockActions.d.ts +1 -1
- package/vanilla/UiEditorBlockActions.js +14 -12
- package/vanilla/UiEditorChipEditor.d.ts +1 -1
- package/vanilla/UiEditorChipEditor.js +22 -14
- package/vanilla/UiEditorCodeLanguage.d.ts +1 -1
- package/vanilla/UiEditorCodeLanguage.js +23 -16
- package/vanilla/UiEditorFootnoteEditor.d.ts +1 -1
- package/vanilla/UiEditorFootnoteEditor.js +17 -9
- package/vanilla/UiEditorFormattingTools.d.ts +1 -1
- package/vanilla/UiEditorFormattingTools.js +108 -71
- package/vanilla/UiEditorImageToolbar.d.ts +1 -1
- package/vanilla/UiEditorImageToolbar.js +68 -66
- package/vanilla/UiEditorInsertTableGrid.d.ts +1 -1
- package/vanilla/UiEditorInsertTableGrid.js +50 -35
- package/vanilla/UiEditorLinkCard.d.ts +1 -1
- package/vanilla/UiEditorLinkCard.js +27 -25
- package/vanilla/UiEditorLinkForm.d.ts +1 -1
- package/vanilla/UiEditorLinkForm.js +79 -57
- package/vanilla/UiEditorMentionMenu.d.ts +1 -1
- package/vanilla/UiEditorMentionMenu.js +63 -44
- package/vanilla/UiEditorMentionMenuItem.d.ts +1 -1
- package/vanilla/UiEditorMentionMenuItem.js +22 -16
- package/vanilla/UiEditorSlashMenu.d.ts +1 -1
- package/vanilla/UiEditorSlashMenu.js +52 -33
- package/vanilla/UiEditorSlashMenuGroup.d.ts +1 -1
- package/vanilla/UiEditorSlashMenuGroup.js +19 -14
- package/vanilla/UiEditorSlashMenuItem.d.ts +1 -1
- package/vanilla/UiEditorSlashMenuItem.js +27 -25
- package/vanilla/UiEditorSurface.d.ts +1 -1
- package/vanilla/UiEditorSurface.js +13 -11
- package/vanilla/UiEditorTableContextMenu.d.ts +1 -1
- package/vanilla/UiEditorTableContextMenu.js +81 -52
- package/vanilla/UiEditorTableOverlay.d.ts +1 -1
- package/vanilla/UiEditorTableOverlay.js +107 -68
- package/vanilla/UiEditorTableToolbar.d.ts +1 -1
- package/vanilla/UiEditorTableToolbar.js +121 -70
- package/vanilla/UiEditorToolbar.d.ts +1 -1
- package/vanilla/UiEditorToolbar.js +20 -12
- package/vanilla/UiFileInput.d.ts +1 -1
- package/vanilla/UiFileInput.js +94 -80
- package/vanilla/UiFloatingActionButton.d.ts +1 -1
- package/vanilla/UiFloatingActionButton.js +21 -20
- package/vanilla/UiFormField.d.ts +1 -1
- package/vanilla/UiFormField.js +21 -19
- package/vanilla/UiGrid.d.ts +1 -1
- package/vanilla/UiGrid.js +26 -23
- package/vanilla/UiIcon.d.ts +1 -1
- package/vanilla/UiIcon.js +20 -15
- package/vanilla/UiIconButton.d.ts +1 -1
- package/vanilla/UiIconButton.js +35 -43
- package/vanilla/UiImage.d.ts +1 -1
- package/vanilla/UiImage.js +16 -14
- package/vanilla/UiInput.d.ts +1 -1
- package/vanilla/UiInput.js +29 -35
- package/vanilla/UiInputGroup.d.ts +1 -1
- package/vanilla/UiInputGroup.js +16 -14
- package/vanilla/UiLightEditor.d.ts +1 -1
- package/vanilla/UiLightEditor.js +29 -27
- package/vanilla/UiList.d.ts +1 -1
- package/vanilla/UiList.js +33 -27
- package/vanilla/UiListItem.d.ts +1 -1
- package/vanilla/UiListItem.js +12 -12
- package/vanilla/UiListbox.d.ts +1 -1
- package/vanilla/UiListbox.js +90 -80
- package/vanilla/UiMenu.d.ts +1 -1
- package/vanilla/UiMenu.js +20 -12
- package/vanilla/UiMenuGroup.d.ts +1 -1
- package/vanilla/UiMenuGroup.js +14 -11
- package/vanilla/UiMenuItem.d.ts +1 -1
- package/vanilla/UiMenuItem.js +74 -75
- package/vanilla/UiMeter.d.ts +1 -1
- package/vanilla/UiMeter.js +67 -62
- package/vanilla/UiNavItem.d.ts +1 -1
- package/vanilla/UiNavItem.js +63 -65
- package/vanilla/UiNoticeStripe.d.ts +1 -1
- package/vanilla/UiNoticeStripe.js +16 -16
- package/vanilla/UiNumberInput.d.ts +1 -1
- package/vanilla/UiNumberInput.js +41 -38
- package/vanilla/UiPageHeader.d.ts +1 -1
- package/vanilla/UiPageHeader.js +17 -15
- package/vanilla/UiPagination.d.ts +1 -1
- package/vanilla/UiPagination.js +53 -44
- package/vanilla/UiPopover.d.ts +1 -1
- package/vanilla/UiPopover.js +13 -11
- package/vanilla/UiRadio.d.ts +1 -1
- package/vanilla/UiRadio.js +25 -23
- package/vanilla/UiRadioGroup.d.ts +1 -1
- package/vanilla/UiRadioGroup.js +33 -36
- package/vanilla/UiReel.d.ts +1 -1
- package/vanilla/UiReel.js +20 -12
- package/vanilla/UiScrollArea.d.ts +1 -1
- package/vanilla/UiScrollArea.js +13 -11
- package/vanilla/UiSearchResultRow.d.ts +1 -1
- package/vanilla/UiSearchResultRow.js +21 -20
- package/vanilla/UiSearchShell.d.ts +1 -1
- package/vanilla/UiSearchShell.js +16 -14
- package/vanilla/UiSection.d.ts +1 -1
- package/vanilla/UiSection.js +48 -45
- package/vanilla/UiSegmentedControl.d.ts +2 -2
- package/vanilla/UiSegmentedControl.js +52 -47
- package/vanilla/UiSelect.d.ts +1 -1
- package/vanilla/UiSelect.js +17 -21
- package/vanilla/UiSeparator.d.ts +1 -1
- package/vanilla/UiSeparator.js +12 -12
- package/vanilla/UiSidebar.d.ts +1 -1
- package/vanilla/UiSidebar.js +17 -15
- package/vanilla/UiSiteHeader.d.ts +1 -1
- package/vanilla/UiSiteHeader.js +25 -23
- package/vanilla/UiSkeleton.d.ts +1 -1
- package/vanilla/UiSkeleton.js +21 -20
- package/vanilla/UiSlider.d.ts +1 -1
- package/vanilla/UiSlider.js +50 -47
- package/vanilla/UiSpinner.d.ts +1 -1
- package/vanilla/UiSpinner.js +34 -27
- package/vanilla/UiStack.d.ts +1 -1
- package/vanilla/UiStack.js +12 -12
- package/vanilla/UiStatusMessage.d.ts +1 -1
- package/vanilla/UiStatusMessage.js +22 -21
- package/vanilla/UiSwatch.d.ts +1 -1
- package/vanilla/UiSwatch.js +20 -17
- package/vanilla/UiSwitch.d.ts +1 -1
- package/vanilla/UiSwitch.js +25 -23
- package/vanilla/UiSwitcher.d.ts +1 -1
- package/vanilla/UiSwitcher.js +13 -11
- package/vanilla/UiTable.d.ts +1 -1
- package/vanilla/UiTable.js +13 -11
- package/vanilla/UiTabs.d.ts +1 -1
- package/vanilla/UiTabs.js +39 -28
- package/vanilla/UiText.d.ts +1 -1
- package/vanilla/UiText.js +128 -125
- package/vanilla/UiTextarea.d.ts +1 -1
- package/vanilla/UiTextarea.js +27 -39
- package/vanilla/UiTimeField.d.ts +1 -1
- package/vanilla/UiTimeField.js +42 -40
- package/vanilla/UiTimePicker.d.ts +1 -1
- package/vanilla/UiTimePicker.js +105 -102
- package/vanilla/UiToast.d.ts +1 -1
- package/vanilla/UiToast.js +14 -14
- package/vanilla/UiToastRegion.d.ts +1 -1
- package/vanilla/UiToastRegion.js +61 -31
- package/vanilla/UiTooltip.d.ts +1 -1
- package/vanilla/UiTooltip.js +17 -14
- package/vanilla/UiTopBar.d.ts +1 -1
- package/vanilla/UiTopBar.js +24 -22
- package/vanilla/UiTree.d.ts +1 -1
- package/vanilla/UiTree.js +17 -12
- package/vanilla/UiTreeItem.d.ts +1 -1
- package/vanilla/UiTreeItem.js +73 -79
- package/vanilla/UiWizard.d.ts +1 -1
- package/vanilla/UiWizard.js +61 -40
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// Generated by HTML Next 1.0.0-alpha.
|
|
2
|
-
import { attachGeneratedController,
|
|
1
|
+
// Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
|
|
2
|
+
import { attachGeneratedController, checkedReferenceValue, equalValue, buildTemplate, clearRegion, KeyedList, NONCONFORMING, readMember, toAttribute, toText, trackContainer, truthy, visitSelected, writeAttribute, dispatchDeclared, detailCheck, dispose, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, project, fillSlot, checkBoolean, checkInteger, checkList, checkNumber, checkObject, forwardAttributes, resetForwardedAttributes, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
|
|
3
3
|
import * as controller from "../components/ui-editor-table-overlay/ui-editor-table-overlay.js";
|
|
4
4
|
import "../styles/ui-editor-table-overlay.css";
|
|
5
5
|
|
|
@@ -9,6 +9,10 @@ const T2 = ["div",["class","control row"],"\n ",["span",["class","line","
|
|
|
9
9
|
const T3 = ["div",["class","control col"],"\n ",["span",["class","line","aria-hidden","true"]],"\n ",["span",["class","guide","data-ui-guide","","aria-hidden","true"]],"\n ",["button",["type","button","class","handle"],"\n ",["ui-icon",["name","plus"]],"\n ",["span",["class","tooltip","role","tooltip"],0],"\n "],"\n "];
|
|
10
10
|
const T4 = ["",[],"\n ",["button",["type","button","class","selector row","data-action","select-row","title","Drag row to reorder; click for actions","aria-label","Row actions"],"\n ",["span",["class","glyph"],["ui-icon",["name","grip-vertical"]]],"\n "],"\n ",["button",["type","button","class","selector column","data-action","select-column","title","Drag column to reorder; click for actions","aria-label","Column actions"],"\n ",["span",["class","glyph"],["ui-icon",["name","grip-horizontal"]]],"\n "],"\n "];
|
|
11
11
|
const T5 = ["button",["type","button","class","cell-menu","data-action","open-cell-menu","title","Cell actions","aria-label","Cell actions"],"\n ",["ui-icon",["name","chevron-down"]],"\n "];
|
|
12
|
+
const RC0 = ["s", "string"];
|
|
13
|
+
const RC1 = [["p",formatOf(keywordFormat)], "keyword with values insert-row, insert-column"];
|
|
14
|
+
const RC2 = [["p",formatOf(keywordFormat)], "keyword with values add-row-before, add-row-after, add-column-before, add-column-after"];
|
|
15
|
+
const RC3 = ["i", "integer"];
|
|
12
16
|
let P0, P1, P2, P3, P4, P5;
|
|
13
17
|
const emptyDirty = new Map();
|
|
14
18
|
const S = { n: ["rows","cols","hovered","active","activeKey"], t: [["l",["o",["key","s","index","i","offset","s","affordance",["p",formatOf(keywordFormat)],"action",["p",formatOf(keywordFormat)],"label","s"]]],["l",["o",["key","s","index","i","offset","s","affordance",["p",formatOf(keywordFormat)],"action",["p",formatOf(keywordFormat)],"label","s"]]],["o",["left","n","top","n","width","n","height","n","rowIndex","i","columnIndex","i","rowOffset","s","columnOffset","s"]],["o",["left","n","top","n","width","n","height","n","rowIndex","i","columnIndex","i","menuLeft","s","menuTop","s"]],"s"], f: import.meta.url, g: "ui-editor-table-overlay", d: { "add-row-before": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-row-after": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-column-before": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-column-after": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "select-row": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false]], false)), true, true, false], "select-column": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false]], false)), true, true, false], "reorder-row": [detailCheck(checkObject([["fromIndex", checkInteger, false], ["toIndex", checkInteger, false]], false)), true, true, false], "reorder-column": [detailCheck(checkObject([["fromIndex", checkInteger, false], ["toIndex", checkInteger, false]], false)), true, true, false], "open-cell-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false], "open-row-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false], "open-column-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false] }, x: dispatchDeclared, a: (host, I) => C(host, I), b: generatedInputs, i: [[], [], null, null, ""] };
|
|
@@ -16,12 +20,9 @@ const D = { g: "ui-editor-table-overlay", props: { "geometry": { "required":fals
|
|
|
16
20
|
const C = (host) => activateModule(controller, host);
|
|
17
21
|
|
|
18
22
|
export function createUiEditorTableOverlay(options = {}, html) {
|
|
19
|
-
const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
|
|
23
|
+
const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
|
|
24
|
+
const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["geometry","open"].includes(name)));
|
|
20
25
|
const element = document.createElement("div");
|
|
21
|
-
for (const [name, value] of Object.entries(attributes)) {
|
|
22
|
-
if (value === null || value === undefined || value === false) continue;
|
|
23
|
-
element.setAttribute(name, value === true ? "" : String(value));
|
|
24
|
-
}
|
|
25
26
|
if (!element.hasAttribute("aria-label")) element.setAttribute("aria-label", "Table controls");
|
|
26
27
|
element.setAttribute("component", "ui-editor-table-overlay");
|
|
27
28
|
element.append((P0 ??= buildTemplate(T0)).cloneNode(true));
|
|
@@ -48,31 +49,47 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
48
49
|
const o = r.i;
|
|
49
50
|
if (c & 1073741824) r.w = 0;
|
|
50
51
|
if (c & 1073741840) {
|
|
51
|
-
const x0 = (readMember(o, "key")
|
|
52
|
-
|
|
53
|
-
|
|
52
|
+
const x0 = equalValue(checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key = $activeKey:control.key", "control.key"), v[4]);
|
|
53
|
+
if (x0 !== NONCONFORMING) {
|
|
54
|
+
const s0 = truthy(x0);
|
|
55
|
+
if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
|
|
56
|
+
}
|
|
54
57
|
}
|
|
55
58
|
if (c & 1073741824) {
|
|
56
|
-
const x1 = trackContainer(r, readMember(o, "offset"));
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
const
|
|
67
|
-
if (
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
const
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
59
|
+
const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "offset"), RC0, "expression:$control.offset:control.offset", "control.offset"));
|
|
60
|
+
if (x1 !== NONCONFORMING) {
|
|
61
|
+
const s1 = toText(x1);
|
|
62
|
+
if (s1 !== r.v1) r.n.style.setProperty("top", r.v1 = s1);
|
|
63
|
+
}
|
|
64
|
+
const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key:control.key", "control.key"));
|
|
65
|
+
if (x2 !== NONCONFORMING) {
|
|
66
|
+
const s2 = toAttribute(x2, "data-control-key");
|
|
67
|
+
if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
|
|
68
|
+
}
|
|
69
|
+
const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "affordance"), RC1, "expression:$control.affordance:control.affordance", "control.affordance"));
|
|
70
|
+
if (x3 !== NONCONFORMING) {
|
|
71
|
+
const s3 = toAttribute(x3, "data-ui-affordance");
|
|
72
|
+
if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
|
|
73
|
+
}
|
|
74
|
+
const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$control.action:control.action", "control.action"));
|
|
75
|
+
if (x4 !== NONCONFORMING) {
|
|
76
|
+
const s4 = toAttribute(x4, "data-action");
|
|
77
|
+
if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
|
|
78
|
+
}
|
|
79
|
+
const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "index"), RC3, "expression:$control.index:control.index", "control.index"));
|
|
80
|
+
if (x5 !== NONCONFORMING) {
|
|
81
|
+
const s5 = toAttribute(x5, "data-boundary-index");
|
|
82
|
+
if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
|
|
83
|
+
}
|
|
84
|
+
const x6 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC0, "expression:$control.label:control.label", "control.label"));
|
|
85
|
+
if (x6 !== NONCONFORMING) {
|
|
86
|
+
const s6 = toAttribute(x6, "aria-label");
|
|
87
|
+
if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
|
|
88
|
+
}
|
|
89
|
+
if (x6 !== NONCONFORMING) {
|
|
90
|
+
const s7 = toText(x6);
|
|
91
|
+
if (s7 !== r.v7) r.a2.data = r.v7 = s7;
|
|
92
|
+
}
|
|
76
93
|
}
|
|
77
94
|
};
|
|
78
95
|
const m3 = (o, j, l) => {
|
|
@@ -87,31 +104,47 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
87
104
|
const o = r.i;
|
|
88
105
|
if (c & 1073741824) r.w = 0;
|
|
89
106
|
if (c & 1073741840) {
|
|
90
|
-
const x0 = (readMember(o, "key")
|
|
91
|
-
|
|
92
|
-
|
|
107
|
+
const x0 = equalValue(checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key = $activeKey:control.key", "control.key"), v[4]);
|
|
108
|
+
if (x0 !== NONCONFORMING) {
|
|
109
|
+
const s0 = truthy(x0);
|
|
110
|
+
if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
|
|
111
|
+
}
|
|
93
112
|
}
|
|
94
113
|
if (c & 1073741824) {
|
|
95
|
-
const x1 = trackContainer(r, readMember(o, "offset"));
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
const
|
|
106
|
-
if (
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
const
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
114
|
+
const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "offset"), RC0, "expression:$control.offset:control.offset", "control.offset"));
|
|
115
|
+
if (x1 !== NONCONFORMING) {
|
|
116
|
+
const s1 = toText(x1);
|
|
117
|
+
if (s1 !== r.v1) r.n.style.setProperty("left", r.v1 = s1);
|
|
118
|
+
}
|
|
119
|
+
const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key:control.key", "control.key"));
|
|
120
|
+
if (x2 !== NONCONFORMING) {
|
|
121
|
+
const s2 = toAttribute(x2, "data-control-key");
|
|
122
|
+
if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
|
|
123
|
+
}
|
|
124
|
+
const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "affordance"), RC1, "expression:$control.affordance:control.affordance", "control.affordance"));
|
|
125
|
+
if (x3 !== NONCONFORMING) {
|
|
126
|
+
const s3 = toAttribute(x3, "data-ui-affordance");
|
|
127
|
+
if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
|
|
128
|
+
}
|
|
129
|
+
const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$control.action:control.action", "control.action"));
|
|
130
|
+
if (x4 !== NONCONFORMING) {
|
|
131
|
+
const s4 = toAttribute(x4, "data-action");
|
|
132
|
+
if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
|
|
133
|
+
}
|
|
134
|
+
const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "index"), RC3, "expression:$control.index:control.index", "control.index"));
|
|
135
|
+
if (x5 !== NONCONFORMING) {
|
|
136
|
+
const s5 = toAttribute(x5, "data-boundary-index");
|
|
137
|
+
if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
|
|
138
|
+
}
|
|
139
|
+
const x6 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC0, "expression:$control.label:control.label", "control.label"));
|
|
140
|
+
if (x6 !== NONCONFORMING) {
|
|
141
|
+
const s6 = toAttribute(x6, "aria-label");
|
|
142
|
+
if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
|
|
143
|
+
}
|
|
144
|
+
if (x6 !== NONCONFORMING) {
|
|
145
|
+
const s7 = toText(x6);
|
|
146
|
+
if (s7 !== r.v7) r.a2.data = r.v7 = s7;
|
|
147
|
+
}
|
|
115
148
|
}
|
|
116
149
|
};
|
|
117
150
|
const m4 = (d) => {
|
|
@@ -124,22 +157,22 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
124
157
|
};
|
|
125
158
|
const p4 = (r, c, d) => {
|
|
126
159
|
if (c & 1073741828) {
|
|
127
|
-
const x0 = (
|
|
160
|
+
const x0 = checkedReferenceValue(S, readMember(v[2], "rowOffset"), RC0, "expression:$hovered.rowOffset:hovered.rowOffset", "hovered.rowOffset");
|
|
128
161
|
if (x0 !== NONCONFORMING) {
|
|
129
162
|
const s0 = toText(x0);
|
|
130
163
|
if (s0 !== r.v0) r.a0.style.setProperty("top", r.v0 = s0);
|
|
131
164
|
}
|
|
132
|
-
const x1 = (
|
|
165
|
+
const x1 = checkedReferenceValue(S, readMember(v[2], "rowIndex"), RC3, "expression:$hovered.rowIndex:hovered.rowIndex", "hovered.rowIndex");
|
|
133
166
|
if (x1 !== NONCONFORMING) {
|
|
134
167
|
const s1 = toAttribute(x1, "data-row-index");
|
|
135
168
|
if (s1 !== r.v1) writeAttribute(r.a0, "data-row-index", r.v1 = s1);
|
|
136
169
|
}
|
|
137
|
-
const x2 = (
|
|
170
|
+
const x2 = checkedReferenceValue(S, readMember(v[2], "columnIndex"), RC3, "expression:$hovered.columnIndex:hovered.columnIndex", "hovered.columnIndex");
|
|
138
171
|
if (x2 !== NONCONFORMING) {
|
|
139
172
|
const s2 = toAttribute(x2, "data-column-index");
|
|
140
173
|
if (s2 !== r.v2) writeAttribute(r.a0, "data-column-index", r.v2 = s2);
|
|
141
174
|
}
|
|
142
|
-
const x3 = (
|
|
175
|
+
const x3 = checkedReferenceValue(S, readMember(v[2], "columnOffset"), RC0, "expression:$hovered.columnOffset:hovered.columnOffset", "hovered.columnOffset");
|
|
143
176
|
if (x3 !== NONCONFORMING) {
|
|
144
177
|
const s3 = toText(x3);
|
|
145
178
|
if (s3 !== r.v3) r.a1.style.setProperty("left", r.v3 = s3);
|
|
@@ -162,22 +195,22 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
162
195
|
};
|
|
163
196
|
const p5 = (r, c, d) => {
|
|
164
197
|
if (c & 1073741832) {
|
|
165
|
-
const x0 = (
|
|
198
|
+
const x0 = checkedReferenceValue(S, readMember(v[3], "menuLeft"), RC0, "expression:$active.menuLeft:active.menuLeft", "active.menuLeft");
|
|
166
199
|
if (x0 !== NONCONFORMING) {
|
|
167
200
|
const s0 = toText(x0);
|
|
168
201
|
if (s0 !== r.v0) r.n.style.setProperty("left", r.v0 = s0);
|
|
169
202
|
}
|
|
170
|
-
const x1 = (
|
|
203
|
+
const x1 = checkedReferenceValue(S, readMember(v[3], "menuTop"), RC0, "expression:$active.menuTop:active.menuTop", "active.menuTop");
|
|
171
204
|
if (x1 !== NONCONFORMING) {
|
|
172
205
|
const s1 = toText(x1);
|
|
173
206
|
if (s1 !== r.v1) r.n.style.setProperty("top", r.v1 = s1);
|
|
174
207
|
}
|
|
175
|
-
const x2 = (
|
|
208
|
+
const x2 = checkedReferenceValue(S, readMember(v[3], "rowIndex"), RC3, "expression:$active.rowIndex:active.rowIndex", "active.rowIndex");
|
|
176
209
|
if (x2 !== NONCONFORMING) {
|
|
177
210
|
const s2 = toAttribute(x2, "data-row-index");
|
|
178
211
|
if (s2 !== r.v2) writeAttribute(r.n, "data-row-index", r.v2 = s2);
|
|
179
212
|
}
|
|
180
|
-
const x3 = (
|
|
213
|
+
const x3 = checkedReferenceValue(S, readMember(v[3], "columnIndex"), RC3, "expression:$active.columnIndex:active.columnIndex", "active.columnIndex");
|
|
181
214
|
if (x3 !== NONCONFORMING) {
|
|
182
215
|
const s3 = toAttribute(x3, "data-column-index");
|
|
183
216
|
if (s3 !== r.v3) writeAttribute(r.n, "data-column-index", r.v3 = s3);
|
|
@@ -186,10 +219,18 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
186
219
|
};
|
|
187
220
|
const p0 = (r, c, d) => {
|
|
188
221
|
if (c & 64) {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
222
|
+
resetForwardedAttributes(r.n, attributes, r.v0);
|
|
223
|
+
r.v0 = forwardAttributes(r.n, attributes);
|
|
224
|
+
const x0 = "Table controls";
|
|
225
|
+
const s1 = toAttribute(x0, "aria-label");
|
|
226
|
+
writeAttribute(r.n, "aria-label", r.v1 = s1);
|
|
227
|
+
const x1 = !truthy(v[6]);
|
|
228
|
+
const s2 = toAttribute(x1, "hidden");
|
|
229
|
+
writeAttribute(r.n, "hidden", r.v2 = s2);
|
|
192
230
|
}
|
|
231
|
+
if (r.f0 === undefined) { r.f0 = 1; const at = fillSlot(r.a1, r.e0, "", J, false, undefined, d);
|
|
232
|
+
if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b0 = m1(d); at.before(r.b0.n); } }
|
|
233
|
+
else if (r.b0 !== undefined) p1(r.b0, c, d);
|
|
193
234
|
if (c & 1073741825) r.L1.update(v[0], d, c);
|
|
194
235
|
if (c !== -1 && c & 16) visitSelected(r.L1.m, s4, v[4], p2, c);
|
|
195
236
|
if (c & 1073741826) r.L2.update(v[1], d, c);
|
|
@@ -202,9 +243,6 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
202
243
|
if (r.b4) { r.b4 = undefined; clearRegion(r.a5, r.e4); }
|
|
203
244
|
else { r.b4 = m5(d); r.e4.before(r.b4.n); }
|
|
204
245
|
} else if (r.b4 !== undefined) p5(r.b4, c, d);
|
|
205
|
-
if (r.f0 === undefined) { r.f0 = 1; const at = fillSlot(r.a1, r.e0, "", J, false, undefined, d);
|
|
206
|
-
if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b0 = m1(d); at.before(r.b0.n); } }
|
|
207
|
-
else if (r.b0 !== undefined) p1(r.b0, c, d);
|
|
208
246
|
s4 = v[4];
|
|
209
247
|
};
|
|
210
248
|
const t0 = element.firstChild.nextSibling;
|
|
@@ -214,10 +252,11 @@ export function createUiEditorTableOverlay(options = {}, html) {
|
|
|
214
252
|
const t4 = t3.firstChild.nextSibling;
|
|
215
253
|
const t5 = t3.nextSibling.nextSibling;
|
|
216
254
|
const t6 = t5.nextSibling.nextSibling.nextSibling;
|
|
217
|
-
const R = { n: element, v0: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, f0: undefined, L1: new KeyedList(t2, t2.nextSibling, m2, p2, (o) => readMember(o, "key"), "control"), L2: new KeyedList(t4, t4.nextSibling, m3, p3, (o) => readMember(o, "key"), "control"), a4: t5, e3: t5.nextSibling, b3: undefined, a5: t6, e4: t6.nextSibling, b4: undefined };
|
|
255
|
+
const R = { n: element, v0: undefined, v1: undefined, v2: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, f0: undefined, L1: new KeyedList(t2, t2.nextSibling, m2, p2, (o) => readMember(o, "key"), "control"), L2: new KeyedList(t4, t4.nextSibling, m3, p3, (o) => readMember(o, "key"), "control"), a4: t5, e3: t5.nextSibling, b3: undefined, a5: t6, e4: t6.nextSibling, b4: undefined };
|
|
218
256
|
const I = { B };
|
|
219
257
|
const J = project(I, children, slots);
|
|
220
258
|
I.R = new Set();
|
|
259
|
+
I.F = { values: attributes, draw: () => ((c, d) => p0(R, c, d))(-1) };
|
|
221
260
|
attachGeneratedController(element, S, v, (c, d) => { ((c, d) => p0(R, c, d))(c, d); for (const f of I.R) f(c, d); }, undefined, undefined, I);
|
|
222
261
|
manageProps(I);
|
|
223
262
|
return element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Generated by HTML Next 1.0.0-alpha.
|
|
1
|
+
// Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
|
|
2
2
|
export interface UiEditorTableToolbarEventMap {
|
|
3
3
|
action: CustomEvent<{ readonly action: "align-left" | "align-center" | "align-right" | "background-none" | "background-gray" | "background-yellow" | "background-blue" | "background-green" | "background-red" | "add-row-before" | "add-row-after" | "add-column-before" | "add-column-after" | "toggle-header-row" | "toggle-header-column" | "move-row-up" | "move-row-down" | "move-column-left" | "move-column-right" | "clear-cells" | "merge-cells" | "split-cell" | "delete-row" | "delete-column" | "delete-table" }>;
|
|
4
4
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// Generated by HTML Next 1.0.0-alpha.
|
|
2
|
-
import { attachGeneratedController, buildTemplate, clearRegion, KeyedList, NONCONFORMING, readIndex, readMember, textCall, toAttribute, toText, trackContainer, truthy, writeAttribute, dispatchDeclared, detailCheck, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, checkBoolean, checkConstrained, checkFormat, checkList, checkObject, checkString, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
|
|
1
|
+
// Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
|
|
2
|
+
import { attachGeneratedController, checkedReferenceValue, buildTemplate, clearRegion, KeyedList, NONCONFORMING, notValue, readIndex, readMember, recordValue, textCall, toAttribute, toText, trackContainer, truthy, truthyValue, writeAttribute, dispatchDeclared, detailCheck, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, checkBoolean, checkConstrained, checkFormat, checkList, checkObject, checkString, forwardAttributes, resetForwardedAttributes, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
|
|
3
3
|
import * as controller from "../components/ui-editor-table-toolbar/ui-editor-table-toolbar.js";
|
|
4
4
|
import "../styles/ui-editor-table-toolbar.css";
|
|
5
5
|
|
|
@@ -16,6 +16,11 @@ const T9 = ["div",["class","menu-section","role","none"],"\n ",["div",[
|
|
|
16
16
|
const T10 = ["button",["type","button","class","swatch-button","role","menuitemradio"],"\n ",["span",["class","swatch"]],"\n ",["span",[],0],"\n "];
|
|
17
17
|
const T11 = ["div",["class","menu-section divided","role","none"],"\n ",["div",["class","menu-heading","role","presentation"],0],"\n ",2,"\n "];
|
|
18
18
|
const T12 = ["button",["type","button"],"\n ",["ui-icon",[]],"\n ",["span",[],0],"\n "];
|
|
19
|
+
const RC0 = ["b", "boolean"];
|
|
20
|
+
const RC1 = [["p",formatOf(keywordFormat)], "keyword with values align-left, align-center, align-right"];
|
|
21
|
+
const RC2 = ["s", "string"];
|
|
22
|
+
const RC3 = [["p",formatOf(keywordFormat)], "keyword with values add-row-after, add-column-after"];
|
|
23
|
+
const RC4 = [["l"], "list(object({ action: string, label: string, icon: string, danger: boolean, checkable: boolean, checked: boolean }))"];
|
|
19
24
|
let P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12;
|
|
20
25
|
const emptyDirty = new Map();
|
|
21
26
|
const S = { n: ["alignments","structure","swatches","sections","hasOverflow","overflowOpen"], t: [["l",["o",["action",["p",formatOf(keywordFormat)],"label","s","active","b"]]],["l",["o",["action",["p",formatOf(keywordFormat)],"label","s","icon","s"]]],["l",["o",["action","s","label","s","color","s","selected","b"]]],["l",["o",["heading","s","items",["l",["o",["action","s","label","s","icon","s","danger","b","checkable","b","checked","b"]]]]]],"b","b"], f: import.meta.url, g: "ui-editor-table-toolbar", d: { "action": [detailCheck(checkObject([["action", checkConstrained(checkFormat("keyword", keywordFormat), "keyword", {"values":["align-left","align-center","align-right","background-none","background-gray","background-yellow","background-blue","background-green","background-red","add-row-before","add-row-after","add-column-before","add-column-after","toggle-header-row","toggle-header-column","move-row-up","move-row-down","move-column-left","move-column-right","clear-cells","merge-cells","split-cell","delete-row","delete-column","delete-table"]}), false]], false)), true, true, false] }, x: dispatchDeclared, a: (host, I) => C(host, I), b: generatedInputs, i: [[], [], [], [], false, false] };
|
|
@@ -23,12 +28,9 @@ const D = { g: "ui-editor-table-toolbar", props: { "actions": { "required":false
|
|
|
23
28
|
const C = (host) => activateModule(controller, host);
|
|
24
29
|
|
|
25
30
|
export function createUiEditorTableToolbar(options = {}, html) {
|
|
26
|
-
const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
|
|
31
|
+
const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
|
|
32
|
+
const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["actions","cell-alignment","cell-background","header-column","header-row","open"].includes(name)));
|
|
27
33
|
const element = document.createElement("div");
|
|
28
|
-
for (const [name, value] of Object.entries(attributes)) {
|
|
29
|
-
if (value === null || value === undefined || value === false) continue;
|
|
30
|
-
element.setAttribute(name, value === true ? "" : String(value));
|
|
31
|
-
}
|
|
32
34
|
if (!element.hasAttribute("role")) element.setAttribute("role", "toolbar");
|
|
33
35
|
if (!element.hasAttribute("aria-label")) element.setAttribute("aria-label", "Table actions");
|
|
34
36
|
element.setAttribute("component", "ui-editor-table-toolbar");
|
|
@@ -56,21 +58,33 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
56
58
|
const o = r.i;
|
|
57
59
|
if (c & 1073741824) {
|
|
58
60
|
r.w = 0;
|
|
59
|
-
const x0 = trackContainer(r, readMember(o, "active"));
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
61
|
+
const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "active"), RC0, "expression:$item.active:item.active", "item.active"));
|
|
62
|
+
if (x0 !== NONCONFORMING) {
|
|
63
|
+
const s0 = truthy(x0);
|
|
64
|
+
if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
|
|
65
|
+
}
|
|
66
|
+
const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC1, "expression:$item.action:item.action", "item.action"));
|
|
67
|
+
if (x1 !== NONCONFORMING) {
|
|
68
|
+
const s1 = toAttribute(x1, "data-action");
|
|
69
|
+
if (s1 !== r.v1) writeAttribute(r.n, "data-action", r.v1 = s1);
|
|
70
|
+
}
|
|
71
|
+
const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
|
|
72
|
+
if (x2 !== NONCONFORMING) {
|
|
73
|
+
const s2 = toAttribute(x2, "aria-label");
|
|
74
|
+
if (s2 !== r.v2) writeAttribute(r.n, "aria-label", r.v2 = s2);
|
|
75
|
+
}
|
|
76
|
+
if (x2 !== NONCONFORMING) {
|
|
77
|
+
const s3 = toAttribute(x2, "title");
|
|
78
|
+
if (s3 !== r.v3) writeAttribute(r.n, "title", r.v3 = s3);
|
|
79
|
+
}
|
|
80
|
+
if (x0 !== NONCONFORMING) {
|
|
81
|
+
const s4 = toAttribute(x0, "aria-pressed");
|
|
82
|
+
if (s4 !== r.v4) writeAttribute(r.n, "aria-pressed", r.v4 = s4);
|
|
83
|
+
}
|
|
84
|
+
if (x1 !== NONCONFORMING) {
|
|
85
|
+
const s5 = toAttribute(x1, "name");
|
|
86
|
+
if (s5 !== r.v5) writeAttribute(r.a1, "name", r.v5 = s5);
|
|
87
|
+
}
|
|
74
88
|
}
|
|
75
89
|
};
|
|
76
90
|
const m3 = (d) => {
|
|
@@ -103,15 +117,21 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
103
117
|
const o = r.i;
|
|
104
118
|
if (c & 1073741824) {
|
|
105
119
|
r.w = 0;
|
|
106
|
-
const x0 = trackContainer(r, readMember(o, "action"));
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
120
|
+
const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC3, "expression:$item.action:item.action", "item.action"));
|
|
121
|
+
if (x0 !== NONCONFORMING) {
|
|
122
|
+
const s0 = toAttribute(x0, "data-action");
|
|
123
|
+
if (s0 !== r.v0) writeAttribute(r.n, "data-action", r.v0 = s0);
|
|
124
|
+
}
|
|
125
|
+
const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "icon"), RC2, "expression:$item.icon:item.icon", "item.icon"));
|
|
126
|
+
if (x1 !== NONCONFORMING) {
|
|
127
|
+
const s1 = toAttribute(x1, "name");
|
|
128
|
+
if (s1 !== r.v1) writeAttribute(r.a1, "name", r.v1 = s1);
|
|
129
|
+
}
|
|
130
|
+
const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
|
|
131
|
+
if (x2 !== NONCONFORMING) {
|
|
132
|
+
const s2 = toText(x2);
|
|
133
|
+
if (s2 !== r.v2) r.a2.data = r.v2 = s2;
|
|
134
|
+
}
|
|
115
135
|
}
|
|
116
136
|
};
|
|
117
137
|
const m6 = (d) => {
|
|
@@ -178,23 +198,35 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
178
198
|
const o = r.i;
|
|
179
199
|
if (c & 1073741824) {
|
|
180
200
|
r.w = 0;
|
|
181
|
-
const x0 = trackContainer(r, readMember(o, "selected"));
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
const
|
|
191
|
-
if (
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
const
|
|
196
|
-
|
|
197
|
-
|
|
201
|
+
const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "selected"), RC0, "expression:$swatch.selected:swatch.selected", "swatch.selected"));
|
|
202
|
+
if (x0 !== NONCONFORMING) {
|
|
203
|
+
const s0 = truthy(x0);
|
|
204
|
+
if (s0 !== r.v0) r.n.classList.toggle("selected", r.v0 = s0);
|
|
205
|
+
}
|
|
206
|
+
if (x0 !== NONCONFORMING) {
|
|
207
|
+
const s1 = toAttribute(x0, "aria-checked");
|
|
208
|
+
if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
|
|
209
|
+
}
|
|
210
|
+
const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$swatch.action:swatch.action", "swatch.action"));
|
|
211
|
+
if (x1 !== NONCONFORMING) {
|
|
212
|
+
const s2 = toAttribute(x1, "data-action");
|
|
213
|
+
if (s2 !== r.v2) writeAttribute(r.n, "data-action", r.v2 = s2);
|
|
214
|
+
}
|
|
215
|
+
const x2 = notValue(truthyValue(trackContainer(r, checkedReferenceValue(S, readMember(o, "color"), RC2, "expression:not $swatch.color:swatch.color", "swatch.color"))));
|
|
216
|
+
if (x2 !== NONCONFORMING) {
|
|
217
|
+
const s3 = truthy(x2);
|
|
218
|
+
if (s3 !== r.v3) r.a1.classList.toggle("default", r.v3 = s3);
|
|
219
|
+
}
|
|
220
|
+
const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "color"), RC2, "expression:$swatch.color:swatch.color", "swatch.color"));
|
|
221
|
+
if (x3 !== NONCONFORMING) {
|
|
222
|
+
const s4 = toText(x3);
|
|
223
|
+
if (s4 !== r.v4) r.a1.style.setProperty("--_swatch", r.v4 = s4);
|
|
224
|
+
}
|
|
225
|
+
const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$swatch.label:swatch.label", "swatch.label"));
|
|
226
|
+
if (x4 !== NONCONFORMING) {
|
|
227
|
+
const s5 = toText(x4);
|
|
228
|
+
if (s5 !== r.v5) r.a2.data = r.v5 = s5;
|
|
229
|
+
}
|
|
198
230
|
}
|
|
199
231
|
};
|
|
200
232
|
const m11 = (o, j, l) => {
|
|
@@ -210,11 +242,13 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
210
242
|
const o = r.i;
|
|
211
243
|
if (c & 1073741824) {
|
|
212
244
|
r.w = 0;
|
|
213
|
-
const x0 = trackContainer(r, readMember(o, "heading"));
|
|
214
|
-
|
|
215
|
-
|
|
245
|
+
const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "heading"), RC2, "expression:$section.heading:section.heading", "section.heading"));
|
|
246
|
+
if (x0 !== NONCONFORMING) {
|
|
247
|
+
const s0 = toText(x0);
|
|
248
|
+
if (s0 !== r.v0) r.a0.data = r.v0 = s0;
|
|
249
|
+
}
|
|
216
250
|
}
|
|
217
|
-
if (c & 1073741824)
|
|
251
|
+
if (c & 1073741824) { const l = checkedReferenceValue(S, readMember(o, "items"), RC4, "expression:$section.items:section.items", "section.items"); if (l !== NONCONFORMING) { r.L0.update(l, d, c); } }
|
|
218
252
|
};
|
|
219
253
|
const m12 = (o, j, l) => {
|
|
220
254
|
const n = (P12 ??= buildTemplate(T12)).cloneNode(true);
|
|
@@ -228,35 +262,51 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
228
262
|
const o = r.i;
|
|
229
263
|
if (c & 1073741824) {
|
|
230
264
|
r.w = 0;
|
|
231
|
-
const x0 = trackContainer(r, readIndex({ "true": "menuitemcheckbox", "false": "menuitem" }, textCall("concat", [trackContainer(r, readMember(o, "checkable"))])));
|
|
265
|
+
const x0 = trackContainer(r, readIndex({ "true": "menuitemcheckbox", "false": "menuitem" }, textCall("concat", [trackContainer(r, checkedReferenceValue(S, readMember(o, "checkable"), RC0, "expression:{ true: 'menuitemcheckbox', false: 'menuitem' }[concat($item.checkable)]:item.checkable", "item.checkable"))])));
|
|
232
266
|
if (x0 !== NONCONFORMING) {
|
|
233
267
|
const s0 = toAttribute(x0, "role");
|
|
234
268
|
if (s0 !== r.v0) writeAttribute(r.n, "role", r.v0 = s0);
|
|
235
269
|
}
|
|
236
|
-
const x1 = trackContainer(r, readIndex(
|
|
270
|
+
const x1 = trackContainer(r, readIndex(recordValue(["true","false"], [checkedReferenceValue(S, readMember(o, "checked"), RC0, "expression:{ true: $item.checked, false: null }[concat($item.checkable)]:item.checked", "item.checked"), null]), textCall("concat", [trackContainer(r, checkedReferenceValue(S, readMember(o, "checkable"), RC0, "expression:{ true: $item.checked, false: null }[concat($item.checkable)]:item.checkable", "item.checkable"))])));
|
|
237
271
|
if (x1 !== NONCONFORMING) {
|
|
238
272
|
const s1 = toAttribute(x1, "aria-checked");
|
|
239
273
|
if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
|
|
240
274
|
}
|
|
241
|
-
const x2 = trackContainer(r, readMember(o, "danger"));
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
const
|
|
252
|
-
if (
|
|
275
|
+
const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "danger"), RC0, "expression:$item.danger:item.danger", "item.danger"));
|
|
276
|
+
if (x2 !== NONCONFORMING) {
|
|
277
|
+
const s2 = truthy(x2);
|
|
278
|
+
if (s2 !== r.v2) r.n.classList.toggle("danger", r.v2 = s2);
|
|
279
|
+
}
|
|
280
|
+
const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$item.action:item.action", "item.action"));
|
|
281
|
+
if (x3 !== NONCONFORMING) {
|
|
282
|
+
const s3 = toAttribute(x3, "data-action");
|
|
283
|
+
if (s3 !== r.v3) writeAttribute(r.n, "data-action", r.v3 = s3);
|
|
284
|
+
}
|
|
285
|
+
const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "icon"), RC2, "expression:$item.icon:item.icon", "item.icon"));
|
|
286
|
+
if (x4 !== NONCONFORMING) {
|
|
287
|
+
const s4 = toAttribute(x4, "name");
|
|
288
|
+
if (s4 !== r.v4) writeAttribute(r.a1, "name", r.v4 = s4);
|
|
289
|
+
}
|
|
290
|
+
const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
|
|
291
|
+
if (x5 !== NONCONFORMING) {
|
|
292
|
+
const s5 = toText(x5);
|
|
293
|
+
if (s5 !== r.v5) r.a2.data = r.v5 = s5;
|
|
294
|
+
}
|
|
253
295
|
}
|
|
254
296
|
};
|
|
255
297
|
const p0 = (r, c, d) => {
|
|
256
298
|
if (c & 2048) {
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
299
|
+
resetForwardedAttributes(r.n, attributes, r.v0);
|
|
300
|
+
r.v0 = forwardAttributes(r.n, attributes);
|
|
301
|
+
const x0 = "toolbar";
|
|
302
|
+
const s1 = toAttribute(x0, "role");
|
|
303
|
+
writeAttribute(r.n, "role", r.v1 = s1);
|
|
304
|
+
const x1 = "Table actions";
|
|
305
|
+
const s2 = toAttribute(x1, "aria-label");
|
|
306
|
+
writeAttribute(r.n, "aria-label", r.v2 = s2);
|
|
307
|
+
const x2 = !truthy(v[11]);
|
|
308
|
+
const s3 = toAttribute(x2, "hidden");
|
|
309
|
+
writeAttribute(r.n, "hidden", r.v3 = s3);
|
|
260
310
|
}
|
|
261
311
|
if (c & 1073741825 && !(truthy(v[0])) !== !r.b0) {
|
|
262
312
|
if (r.b0) { r.b0 = undefined; clearRegion(r.a1, r.e0); }
|
|
@@ -284,9 +334,10 @@ export function createUiEditorTableToolbar(options = {}, html) {
|
|
|
284
334
|
const t2 = t1.nextSibling.nextSibling.nextSibling;
|
|
285
335
|
const t3 = t2.nextSibling.nextSibling.nextSibling;
|
|
286
336
|
const t4 = t3.nextSibling.nextSibling.nextSibling;
|
|
287
|
-
const R = { n: element, v0: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined, a3: t2, e2: t2.nextSibling, b2: undefined, a4: t3, e3: t3.nextSibling, b3: undefined, a5: t4, e4: t4.nextSibling, b4: undefined };
|
|
337
|
+
const R = { n: element, v0: undefined, v1: undefined, v2: undefined, v3: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined, a3: t2, e2: t2.nextSibling, b2: undefined, a4: t3, e3: t3.nextSibling, b3: undefined, a5: t4, e4: t4.nextSibling, b4: undefined };
|
|
288
338
|
const I = { B };
|
|
289
339
|
I.R = new Set();
|
|
340
|
+
I.F = { values: attributes, draw: () => ((c, d) => p0(R, c, d))(-1) };
|
|
290
341
|
attachGeneratedController(element, S, v, (c, d) => { ((c, d) => p0(R, c, d))(c, d); for (const f of I.R) f(c, d); }, undefined, undefined, I);
|
|
291
342
|
manageProps(I);
|
|
292
343
|
return element;
|