@type-dom/ui 0.0.10 → 0.1.0
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/package.json +3 -4
- package/src/aria.d.ts +2 -2
- package/src/components/basic/td-button/td-button.abstract.d.ts +5 -5
- package/src/components/basic/td-button/td-button.abstract.js +46 -42
- package/src/components/basic/td-button/td-button.interface.d.ts +3 -6
- package/src/components/basic/td-button/td-button.style.d.ts +16 -5
- package/src/components/basic/td-button/td-button.style.js +43 -17
- package/src/components/basic/td-button-group/td-button-group.class.d.ts +3 -2
- package/src/components/basic/td-button-group/td-button-group.class.js +34 -37
- package/src/components/basic/td-button-group/td-button-group.interface.d.ts +3 -3
- package/src/components/basic/td-container/td-aside/td-aside.class.d.ts +2 -2
- package/src/components/basic/td-container/td-aside/td-aside.class.js +6 -5
- package/src/components/basic/td-container/td-aside/td-aside.interface.d.ts +3 -3
- package/src/components/basic/td-container/td-container.class.d.ts +2 -3
- package/src/components/basic/td-container/td-container.class.js +9 -7
- package/src/components/basic/td-container/td-container.interface.d.ts +3 -4
- package/src/components/basic/td-container/td-container.js +3 -2
- package/src/components/basic/td-container/td-footer/td-footer.class.d.ts +2 -2
- package/src/components/basic/td-container/td-footer/td-footer.class.js +4 -3
- package/src/components/basic/td-container/td-footer/td-footer.interface.d.ts +3 -3
- package/src/components/basic/td-container/td-header/td-header.class.d.ts +2 -2
- package/src/components/basic/td-container/td-header/td-header.class.js +3 -3
- package/src/components/basic/td-container/td-header/td-header.interface.d.ts +3 -3
- package/src/components/basic/td-container/td-main/td-main.class.d.ts +4 -2
- package/src/components/basic/td-container/td-main/td-main.class.js +8 -5
- package/src/components/basic/td-container/td-main/td-main.interface.d.ts +3 -3
- package/src/components/basic/td-icon/td-icon.class.d.ts +4 -6
- package/src/components/basic/td-icon/td-icon.class.js +21 -18
- package/src/components/basic/td-icon/td-icon.interface.d.ts +3 -4
- package/src/components/basic/td-layout/td-col/td-col.class.d.ts +2 -3
- package/src/components/basic/td-layout/td-col/td-col.class.js +4 -4
- package/src/components/basic/td-layout/td-col/td-col.interface.d.ts +3 -3
- package/src/components/basic/td-layout/td-row/td-row.class.d.ts +2 -2
- package/src/components/basic/td-layout/td-row/td-row.class.js +5 -4
- package/src/components/basic/td-layout/td-row/td-row.interface.d.ts +3 -3
- package/src/components/basic/td-link/td-link.class.d.ts +2 -2
- package/src/components/basic/td-link/td-link.class.js +6 -10
- package/src/components/basic/td-link/td-link.interface.d.ts +3 -3
- package/src/components/basic/td-link/td-link.style.js +1 -1
- package/src/components/basic/td-scrollbar/bar/bar.class.d.ts +2 -2
- package/src/components/basic/td-scrollbar/bar/bar.class.js +4 -4
- package/src/components/basic/td-scrollbar/bar/bar.interface.d.ts +3 -3
- package/src/components/basic/td-scrollbar/td-scrollbar.class.d.ts +4 -2
- package/src/components/basic/td-scrollbar/td-scrollbar.class.js +4 -3
- package/src/components/basic/td-scrollbar/td-scrollbar.interface.d.ts +3 -4
- package/src/components/basic/td-scrollbar/td-scrollbar.interface.js +1 -1
- package/src/components/basic/td-scrollbar/thumb/thumb.class.d.ts +2 -2
- package/src/components/basic/td-scrollbar/thumb/thumb.class.js +2 -3
- package/src/components/basic/td-scrollbar/thumb/thumb.interface.d.ts +3 -3
- package/src/components/basic/td-space/td-space.class.d.ts +2 -2
- package/src/components/basic/td-space/td-space.class.js +11 -5
- package/src/components/basic/td-space/td-space.interface.d.ts +3 -4
- package/src/components/basic/td-text/td-text.class.d.ts +4 -2
- package/src/components/basic/td-text/td-text.class.js +6 -4
- package/src/components/basic/td-text/td-text.interface.d.ts +3 -3
- package/src/components/data/td-avatar/td-avatar.class.d.ts +2 -2
- package/src/components/data/td-avatar/td-avatar.class.js +19 -25
- package/src/components/data/td-avatar/td-avatar.interface.d.ts +3 -3
- package/src/components/data/td-avatar/td-avatar.style.d.ts +2 -0
- package/src/components/data/td-avatar/td-avatar.style.js +19 -1
- package/src/components/data/td-badge/td-badge.class.d.ts +2 -2
- package/src/components/data/td-badge/td-badge.class.js +4 -4
- package/src/components/data/td-badge/td-badge.interface.d.ts +3 -3
- package/src/components/data/td-card/td-card.class.d.ts +4 -5
- package/src/components/data/td-card/td-card.class.js +16 -30
- package/src/components/data/td-card/td-card.interface.d.ts +3 -3
- package/src/components/data/td-card/td-card.style.d.ts +3 -2
- package/src/components/data/td-card/td-card.style.js +17 -3
- package/src/components/data/td-check-tag/td-check-tag.class.d.ts +2 -2
- package/src/components/data/td-check-tag/td-check-tag.class.js +5 -5
- package/src/components/data/td-check-tag/td-check-tag.interface.d.ts +3 -3
- package/src/components/data/td-check-tag/td-check-tag.style.d.ts +2 -2
- package/src/components/data/td-check-tag/td-check-tag.style.js +3 -3
- package/src/components/data/td-collapse/td-collapse.class.d.ts +2 -2
- package/src/components/data/td-collapse/td-collapse.class.js +20 -20
- package/src/components/data/td-collapse/td-collapse.interface.d.ts +3 -3
- package/src/components/data/td-collapse/td-collapse.style.d.ts +2 -0
- package/src/components/data/td-collapse/td-collapse.style.js +9 -1
- package/src/components/data/td-collapse-item/td-collapse-item.class.d.ts +4 -5
- package/src/components/data/td-collapse-item/td-collapse-item.class.js +8 -7
- package/src/components/data/td-collapse-item/td-collapse-item.interface.d.ts +3 -3
- package/src/components/data/td-count-down/td-count-down.class.d.ts +1 -1
- package/src/components/data/td-count-down/td-count-down.class.js +1 -1
- package/src/components/data/td-descriptions/td-descriptions-row.d.ts +4 -5
- package/src/components/data/td-descriptions/td-descriptions-row.js +1 -1
- package/src/components/data/td-descriptions/td-descriptions.class.d.ts +3 -3
- package/src/components/data/td-descriptions/td-descriptions.class.js +2 -3
- package/src/components/data/td-descriptions/td-descriptions.interface.d.ts +3 -4
- package/src/components/data/td-descriptions/td-descritions-cell.d.ts +6 -5
- package/src/components/data/td-descriptions/td-descritions-cell.js +5 -4
- package/src/components/data/td-descriptions-item/td-descriptions-item.class.d.ts +2 -3
- package/src/components/data/td-descriptions-item/td-descriptions-item.class.js +5 -4
- package/src/components/data/td-descriptions-item/td-descriptions-item.interface.d.ts +3 -4
- package/src/components/data/td-empty/td-empty.class.d.ts +2 -2
- package/src/components/data/td-empty/td-empty.class.js +2 -3
- package/src/components/data/td-empty/td-empty.interface.d.ts +3 -4
- package/src/components/data/td-image/td-image.class.d.ts +2 -3
- package/src/components/data/td-image/td-image.class.js +4 -22
- package/src/components/data/td-image/td-image.interface.d.ts +3 -3
- package/src/components/data/td-image/td-image.style.d.ts +2 -0
- package/src/components/data/td-image/td-image.style.js +19 -1
- package/src/components/data/td-image-viewer/td-image-viewer.class.d.ts +3 -5
- package/src/components/data/td-image-viewer/td-image-viewer.class.js +20 -17
- package/src/components/data/td-image-viewer/td-image-viewer.interface.d.ts +3 -3
- package/src/components/data/td-result/td-result.class.d.ts +2 -2
- package/src/components/data/td-result/td-result.class.js +4 -3
- package/src/components/data/td-result/td-result.interface.d.ts +3 -4
- package/src/components/data/td-segmented/td-segmented.class.d.ts +2 -3
- package/src/components/data/td-segmented/td-segmented.class.js +7 -8
- package/src/components/data/td-segmented/td-segmented.interface.d.ts +2 -3
- package/src/components/data/td-statistic/td-statistic.abstract.d.ts +3 -4
- package/src/components/data/td-statistic/td-statistic.abstract.js +15 -14
- package/src/components/data/td-statistic/td-statistic.class.js +1 -0
- package/src/components/data/td-statistic/td-statistic.interface.d.ts +3 -4
- package/src/components/data/td-tag/td-tag.class.d.ts +3 -4
- package/src/components/data/td-tag/td-tag.class.js +13 -13
- package/src/components/data/td-tag/td-tag.interface.d.ts +3 -3
- package/src/components/feedback/index.d.ts +2 -0
- package/src/components/feedback/index.js +3 -1
- package/src/components/feedback/td-alert/td-alert.class.d.ts +2 -3
- package/src/components/feedback/td-alert/td-alert.class.js +19 -17
- package/src/components/feedback/td-alert/td-alert.interface.d.ts +3 -3
- package/src/components/feedback/td-dialog/td-dialog.class.d.ts +3 -3
- package/src/components/feedback/td-dialog/td-dialog.class.js +25 -29
- package/src/components/feedback/td-dialog/td-dialog.interface.d.ts +3 -3
- package/src/components/feedback/td-dialog/td-dialog.interface.js +1 -1
- package/src/components/feedback/td-dialog-content/td-dialog-content.class.d.ts +2 -3
- package/src/components/feedback/td-dialog-content/td-dialog-content.class.js +10 -7
- package/src/components/feedback/td-dialog-content/td-dialog-content.interface.d.ts +3 -4
- package/src/components/feedback/td-drawer/td-drawer.class.d.ts +3 -3
- package/src/components/feedback/td-drawer/td-drawer.class.js +5 -5
- package/src/components/feedback/td-drawer/td-drawer.interface.d.ts +2 -2
- package/src/components/feedback/td-focus-trap/focus-trap.d.ts +15 -0
- package/src/components/feedback/td-focus-trap/focus-trap.js +71 -0
- package/src/components/feedback/td-focus-trap/td-focus-trap.class.d.ts +8 -7
- package/src/components/feedback/td-focus-trap/td-focus-trap.class.js +129 -129
- package/src/components/feedback/td-focus-trap/td-focus-trap.interface.d.ts +3 -3
- package/src/components/feedback/td-loading/td-loading.class.d.ts +2 -3
- package/src/components/feedback/td-loading/td-loading.class.js +21 -17
- package/src/components/feedback/td-loading/td-loading.interface.d.ts +3 -4
- package/src/components/feedback/td-message/td-message.class.d.ts +4 -4
- package/src/components/feedback/td-message/td-message.class.js +31 -31
- package/src/components/feedback/td-message/td-message.interface.d.ts +3 -4
- package/src/components/feedback/td-message-box/td-message-box.class.d.ts +10 -12
- package/src/components/feedback/td-message-box/td-message-box.class.js +30 -52
- package/src/components/feedback/td-message-box/td-message-box.interface.d.ts +4 -5
- package/src/components/feedback/td-notification/td-notification.class.d.ts +4 -5
- package/src/components/feedback/td-notification/td-notification.class.js +17 -18
- package/src/components/feedback/td-notification/td-notification.interface.d.ts +3 -4
- package/src/components/feedback/td-only-child/td-only-child.class.d.ts +3 -3
- package/src/components/feedback/td-only-child/td-only-child.class.js +3 -3
- package/src/components/feedback/td-overlay/td-overlay.class.d.ts +2 -3
- package/src/components/feedback/td-overlay/td-overlay.class.js +6 -5
- package/src/components/feedback/td-overlay/td-overlay.interface.d.ts +3 -3
- package/src/components/feedback/td-popper/arrow/arrow.class.d.ts +2 -2
- package/src/components/feedback/td-popper/arrow/arrow.class.js +7 -6
- package/src/components/feedback/td-popper/arrow/arrow.const.d.ts +3 -0
- package/src/components/feedback/td-popper/arrow/arrow.const.js +6 -0
- package/src/components/feedback/td-popper/arrow/arrow.interface.d.ts +3 -4
- package/src/components/feedback/td-popper/constants.d.ts +25 -0
- package/src/components/feedback/td-popper/constants.js +5 -0
- package/src/components/feedback/td-popper/content/content.class.d.ts +2 -2
- package/src/components/feedback/td-popper/content/content.class.js +7 -13
- package/src/components/feedback/td-popper/content/content.const.d.ts +2 -2
- package/src/components/feedback/td-popper/content/content.const.js +3 -4
- package/src/components/feedback/td-popper/content/content.interface.d.ts +24 -11
- package/src/components/feedback/td-popper/content/content.interface.js +4 -0
- package/src/components/feedback/td-popper/td-popper.class.d.ts +3 -2
- package/src/components/feedback/td-popper/td-popper.class.js +9 -7
- package/src/components/feedback/td-popper/td-popper.const.d.ts +5 -20
- package/src/components/feedback/td-popper/td-popper.const.js +8 -3
- package/src/components/feedback/td-popper/td-popper.interface.d.ts +6 -4
- package/src/components/feedback/td-popper/trigger/trigger.class.d.ts +2 -2
- package/src/components/feedback/td-popper/trigger/trigger.class.js +6 -6
- package/src/components/feedback/td-popper/trigger/trigger.const.d.ts +1 -0
- package/src/components/feedback/td-popper/trigger/trigger.const.js +4 -1
- package/src/components/feedback/td-popper/trigger/trigger.interface.d.ts +3 -3
- package/src/components/feedback/td-tooltip/content/content.class.d.ts +2 -2
- package/src/components/feedback/td-tooltip/content/content.class.js +4 -3
- package/src/components/feedback/td-tooltip/content/content.const.d.ts +55 -0
- package/src/components/feedback/td-tooltip/content/content.const.js +6 -0
- package/src/components/feedback/td-tooltip/content/content.interface.d.ts +19 -3
- package/src/components/feedback/td-tooltip/td-tooltip.class.d.ts +5 -3
- package/src/components/feedback/td-tooltip/td-tooltip.class.js +84 -9
- package/src/components/feedback/td-tooltip/td-tooltip.const.d.ts +77 -0
- package/src/components/feedback/td-tooltip/td-tooltip.const.js +9 -0
- package/src/components/feedback/td-tooltip/td-tooltip.interface.d.ts +6 -3
- package/src/components/feedback/td-tooltip/trigger/trigger.class.d.ts +3 -2
- package/src/components/feedback/td-tooltip/trigger/trigger.class.js +56 -3
- package/src/components/feedback/td-tooltip/trigger/trigger.const.d.ts +4 -0
- package/src/components/feedback/td-tooltip/trigger/trigger.const.js +6 -0
- package/src/components/feedback/td-tooltip/trigger/trigger.interface.d.ts +7 -2
- package/src/components/form/index.d.ts +17 -16
- package/src/components/form/index.js +19 -17
- package/src/components/form/td-checkbox/composables/use-checkbox-status.js +1 -1
- package/src/components/form/td-checkbox/composables/use-checkbox.js +1 -1
- package/src/components/form/td-checkbox/td-checkbox.class.d.ts +18 -3
- package/src/components/form/td-checkbox/td-checkbox.class.js +231 -9
- package/src/components/form/td-checkbox/td-checkbox.const.d.ts +63 -0
- package/src/components/form/td-checkbox/td-checkbox.const.js +88 -0
- package/src/components/form/td-checkbox/td-checkbox.interface.d.ts +5 -5
- package/src/components/form/td-checkbox/td-checkbox.style.d.ts +9 -0
- package/src/components/form/td-checkbox/td-checkbox.style.js +165 -12
- package/src/components/form/td-checkbox-button/td-checkbox-button.class.d.ts +9 -3
- package/src/components/form/td-checkbox-button/td-checkbox-button.class.js +114 -26
- package/src/components/form/td-checkbox-button/td-checkbox-button.interface.d.ts +2 -4
- package/src/components/form/td-checkbox-button/td-checkbox-button.style.d.ts +8 -1
- package/src/components/form/td-checkbox-button/td-checkbox-button.style.js +89 -12
- package/src/components/form/td-checkbox-group/td-checkbox-group.class.d.ts +11 -3
- package/src/components/form/td-checkbox-group/td-checkbox-group.class.js +118 -5
- package/src/components/form/td-checkbox-group/td-checkbox-group.interface.d.ts +8 -5
- package/src/components/form/td-form/td-form.class.d.ts +4 -2
- package/src/components/form/td-form/td-form.class.js +9 -5
- package/src/components/form/td-form/td-form.interface.d.ts +7 -4
- package/src/components/form/td-form-item/td-form-item.class.d.ts +4 -5
- package/src/components/form/td-form-item/td-form-item.class.js +34 -27
- package/src/components/form/td-form-item/td-form-item.interface.d.ts +3 -3
- package/src/components/form/td-input/td-input.class.d.ts +3 -4
- package/src/components/form/td-input/td-input.class.js +30 -26
- package/src/components/form/td-input/td-input.interface.d.ts +3 -4
- package/src/components/form/td-input/widget/suffix.d.ts +1 -0
- package/src/components/form/td-input/widget/suffix.js +6 -1
- package/src/components/form/td-input/widget/td-input-wrapper.class.js +5 -5
- package/src/components/form/td-option/td-option.class.d.ts +2 -2
- package/src/components/form/td-option/td-option.class.js +3 -3
- package/src/components/form/td-option/td-option.interface.d.ts +3 -3
- package/src/components/form/td-option-group/td-option-group.class.d.ts +2 -2
- package/src/components/form/td-option-group/td-option-group.class.js +2 -3
- package/src/components/form/td-option-group/td-option-group.interface.d.ts +3 -3
- package/src/components/form/td-radio/td-radio.class.d.ts +2 -3
- package/src/components/form/td-radio/td-radio.class.js +8 -5
- package/src/components/form/td-radio/td-radio.interface.d.ts +3 -3
- package/src/components/form/td-radio-button/td-radio-button.class.d.ts +2 -3
- package/src/components/form/td-radio-button/td-radio-button.class.js +9 -9
- package/src/components/form/td-radio-button/td-radio-button.interface.d.ts +3 -3
- package/src/components/form/td-radio-group/td-radio-group.class.d.ts +2 -5
- package/src/components/form/td-radio-group/td-radio-group.class.js +14 -11
- package/src/components/form/td-radio-group/td-radio-group.interface.d.ts +3 -4
- package/src/components/form/td-select/dropdown/dropdown.class.d.ts +2 -2
- package/src/components/form/td-select/dropdown/dropdown.class.js +2 -3
- package/src/components/form/td-select/dropdown/dropdown.interface.d.ts +3 -4
- package/src/components/form/td-select/td-select.class.d.ts +4 -6
- package/src/components/form/td-select/td-select.class.js +4 -6
- package/src/components/form/td-select/td-select.interface.d.ts +13 -5
- package/src/components/form/td-select/td-select.style.d.ts +23 -0
- package/src/components/form/td-select/td-select.style.js +170 -1
- package/src/components/form/td-switch/td-switch.class.d.ts +2 -3
- package/src/components/form/td-switch/td-switch.class.js +2 -3
- package/src/components/form/td-switch/td-switch.interface.d.ts +3 -4
- package/src/components/navigation/td-affix/td-affix.class.d.ts +2 -3
- package/src/components/navigation/td-affix/td-affix.class.js +2 -3
- package/src/components/navigation/td-affix/td-affix.interface.d.ts +3 -4
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.class.d.ts +2 -2
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.class.js +2 -3
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.interface.d.ts +3 -4
- package/src/components/navigation/td-anchor/td-anchor.class.d.ts +2 -2
- package/src/components/navigation/td-anchor/td-anchor.class.js +6 -4
- package/src/components/navigation/td-anchor/td-anchor.function.js +1 -1
- package/src/components/navigation/td-anchor/td-anchor.interface.d.ts +3 -3
- package/src/components/navigation/td-backtop/td-backtop.class.d.ts +5 -6
- package/src/components/navigation/td-backtop/td-backtop.class.js +36 -59
- package/src/components/navigation/td-backtop/td-backtop.const.d.ts +18 -0
- package/src/components/navigation/td-backtop/td-backtop.const.js +21 -0
- package/src/components/navigation/td-backtop/td-backtop.interface.d.ts +3 -3
- package/src/components/navigation/td-backtop/td-backtop.style.d.ts +2 -0
- package/src/components/navigation/td-backtop/td-backtop.style.js +19 -1
- package/src/components/navigation/td-backtop/use-backtop.d.ts +2 -3
- package/src/components/navigation/td-backtop/use-backtop.js +2 -2
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.class.d.ts +3 -3
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.class.js +12 -8
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.interface.d.ts +3 -4
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.class.d.ts +2 -2
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.class.js +2 -3
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.interface.d.ts +3 -4
- package/src/components/navigation/td-menu/td-menu.class.d.ts +2 -2
- package/src/components/navigation/td-menu/td-menu.class.js +4 -3
- package/src/components/navigation/td-menu/td-menu.interface.d.ts +3 -4
- package/src/components/navigation/td-tabs/td-tab-bar.class.d.ts +2 -2
- package/src/components/navigation/td-tabs/td-tab-bar.class.js +3 -3
- package/src/components/navigation/td-tabs/td-tab-bar.interface.d.ts +3 -3
- package/src/components/navigation/td-tabs/td-tab-nav.class.d.ts +2 -3
- package/src/components/navigation/td-tabs/td-tab-nav.class.js +3 -4
- package/src/components/navigation/td-tabs/td-tab-nav.interface.d.ts +3 -3
- package/src/components/navigation/td-tabs/td-tab-pane.class.d.ts +2 -3
- package/src/components/navigation/td-tabs/td-tab-pane.class.js +12 -16
- package/src/components/navigation/td-tabs/td-tab-pane.interface.d.ts +3 -4
- package/src/components/navigation/td-tabs/td-tabs.class.d.ts +2 -2
- package/src/components/navigation/td-tabs/td-tabs.class.js +6 -4
- package/src/components/navigation/td-tabs/td-tabs.interface.d.ts +3 -3
- package/src/components/others/example/example-source-wrapper.js +2 -1
- package/src/components/others/td-divider/td-divider.class.d.ts +2 -2
- package/src/components/others/td-divider/td-divider.class.js +2 -3
- package/src/components/others/td-divider/td-divider.interface.d.ts +3 -3
- package/src/constants/aria.d.ts +17 -0
- package/src/constants/aria.js +20 -0
- package/src/hooks/index.d.ts +1 -0
- package/src/hooks/index.js +1 -0
- package/src/hooks/use-delayed-toggle.d.ts +23 -0
- package/src/hooks/use-delayed-toggle.js +52 -0
- package/src/styles/var.d.ts +1 -15
- package/src/styles/var.js +6 -16
- package/src/utils/dom/event.d.ts +6 -0
- package/src/utils/dom/event.js +17 -0
- package/src/ui/ui.abstract.d.ts +0 -18
- package/src/ui/ui.abstract.js +0 -50
- package/src/ui/ui.interface.d.ts +0 -12
- package/src/ui/ui.interface.js +0 -2
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdOverlay = exports.overlayZIndex = void 0;
|
|
4
|
-
const
|
|
4
|
+
const framework_1 = require("@type-dom/framework");
|
|
5
5
|
const td_overlay_style_1 = require("./td-overlay.style");
|
|
6
6
|
exports.overlayZIndex = 2000;
|
|
7
|
-
class TdOverlay extends
|
|
7
|
+
class TdOverlay extends framework_1.TypeDiv {
|
|
8
8
|
constructor(params = {}) {
|
|
9
|
-
super(
|
|
9
|
+
super();
|
|
10
10
|
exports.overlayZIndex = exports.overlayZIndex + 1;
|
|
11
11
|
this.className = 'TdOverlay';
|
|
12
12
|
this.style.addObj(td_overlay_style_1.$tdOverlayStyle);
|
|
@@ -25,11 +25,12 @@ class TdOverlay extends ui_abstract_1.UI {
|
|
|
25
25
|
left: '0px',
|
|
26
26
|
});
|
|
27
27
|
}
|
|
28
|
-
this.addChild(this.getSlotNode());
|
|
28
|
+
// this.addChild(this.getSlotNode());
|
|
29
|
+
this.slotChild(params.slot);
|
|
29
30
|
this.props = this.useParams(params);
|
|
30
31
|
}
|
|
31
32
|
addSlot(slot) {
|
|
32
|
-
this.getSlotNode().resetSlot(slot);
|
|
33
|
+
// this.getSlotNode().resetSlot(slot);
|
|
33
34
|
}
|
|
34
35
|
}
|
|
35
36
|
exports.TdOverlay = TdOverlay;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Property } from '@type-dom/css-type';
|
|
2
|
-
import {
|
|
3
|
-
export interface ITdOverlay extends
|
|
2
|
+
import { ITypeConfig, ITypeDiv } from '@type-dom/framework';
|
|
3
|
+
export interface ITdOverlay extends ITypeDiv {
|
|
4
4
|
className: 'TdOverlay';
|
|
5
5
|
}
|
|
6
|
-
export interface ITdOverlayConfig extends
|
|
6
|
+
export interface ITdOverlayConfig extends ITypeConfig {
|
|
7
7
|
mask?: boolean;
|
|
8
8
|
customMaskEvent?: boolean;
|
|
9
9
|
zIndex?: Property.ZIndex;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TypeSpan } from '@type-dom/framework';
|
|
2
2
|
import { ITdPopperArrow, ITdPopperArrowConfig } from './arrow.interface';
|
|
3
|
-
export declare class TdPopperArrow extends
|
|
3
|
+
export declare class TdPopperArrow extends TypeSpan implements ITdPopperArrow {
|
|
4
4
|
className: 'TdPopperArrow';
|
|
5
5
|
props: ITdPopperArrowConfig;
|
|
6
6
|
private arrowOffset?;
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdPopperArrow = void 0;
|
|
4
|
+
const framework_1 = require("@type-dom/framework");
|
|
4
5
|
const var_1 = require("../../../../styles/var");
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
class TdPopperArrow extends ui_abstract_1.UI {
|
|
6
|
+
const constants_1 = require("../constants");
|
|
7
|
+
class TdPopperArrow extends framework_1.TypeSpan {
|
|
8
8
|
constructor(params = {}) {
|
|
9
|
-
super(
|
|
9
|
+
super();
|
|
10
|
+
// this.useTag('span');
|
|
10
11
|
this.className = 'TdPopperArrow';
|
|
11
12
|
this.attr.addName('td-popper-arrow');
|
|
12
13
|
this.style.addObj({
|
|
@@ -27,13 +28,13 @@ class TdPopperArrow extends ui_abstract_1.UI {
|
|
|
27
28
|
boxSizing: 'border-box'
|
|
28
29
|
// }
|
|
29
30
|
});
|
|
30
|
-
this.
|
|
31
|
+
this.assignProps({
|
|
31
32
|
arrowOffset: 5,
|
|
32
33
|
});
|
|
33
34
|
this.props = this.useParams(params);
|
|
34
35
|
}
|
|
35
36
|
setup() {
|
|
36
|
-
const { arrowOffset, arrowRef, arrowStyle } = this.inject(
|
|
37
|
+
const { arrowOffset, arrowRef, arrowStyle } = this.inject(constants_1.POPPER_CONTENT_INJECTION_KEY, undefined);
|
|
37
38
|
this.arrowOffset = arrowOffset;
|
|
38
39
|
this.arrowRef = arrowRef;
|
|
39
40
|
this.arrowStyle = arrowStyle;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface ITdPopperArrow extends
|
|
1
|
+
import { ITypeConfig, ITypeSpan } from '@type-dom/framework';
|
|
2
|
+
export interface ITdPopperArrow extends ITypeSpan {
|
|
3
3
|
className: 'TdPopperArrow';
|
|
4
4
|
}
|
|
5
|
-
export interface ITdPopperArrowConfig extends
|
|
5
|
+
export interface ITdPopperArrowConfig extends ITypeConfig {
|
|
6
6
|
/**
|
|
7
|
-
*
|
|
8
7
|
* default: 5,
|
|
9
8
|
*/
|
|
10
9
|
arrowOffset?: number;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { IStyle } from '@type-dom/css-type';
|
|
2
|
+
import { InjectionKey } from '@type-dom/framework';
|
|
3
|
+
import { TdPopper } from './td-popper.class';
|
|
4
|
+
export type Measurable = {
|
|
5
|
+
getBoundingClientRect: () => DOMRect;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* triggerRef indicates the element that triggers popper
|
|
9
|
+
* contentRef indicates the element of popper content
|
|
10
|
+
* referenceRef indicates the element that popper content relative with
|
|
11
|
+
*/
|
|
12
|
+
export type TdPopperInjectionContext = {
|
|
13
|
+
triggerRef: Measurable | undefined;
|
|
14
|
+
contentRef: HTMLElement | undefined;
|
|
15
|
+
popperInstanceRef: TdPopper | undefined;
|
|
16
|
+
referenceRef: Measurable | undefined;
|
|
17
|
+
role: string;
|
|
18
|
+
};
|
|
19
|
+
export type TdPopperContentInjectionContext = {
|
|
20
|
+
arrowRef: HTMLElement | undefined;
|
|
21
|
+
arrowOffset: number | undefined;
|
|
22
|
+
arrowStyle: IStyle;
|
|
23
|
+
};
|
|
24
|
+
export declare const POPPER_INJECTION_KEY: InjectionKey<TdPopperInjectionContext>;
|
|
25
|
+
export declare const POPPER_CONTENT_INJECTION_KEY: InjectionKey<TdPopperContentInjectionContext>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.POPPER_CONTENT_INJECTION_KEY = exports.POPPER_INJECTION_KEY = void 0;
|
|
4
|
+
exports.POPPER_INJECTION_KEY = Symbol('popper');
|
|
5
|
+
exports.POPPER_CONTENT_INJECTION_KEY = Symbol('popperContent');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TypeDiv } from '@type-dom/framework';
|
|
2
2
|
import { ITdPopperContent, ITdPopperContentConfig } from './content.interface';
|
|
3
|
-
export declare class TdPopperContent extends
|
|
3
|
+
export declare class TdPopperContent extends TypeDiv implements ITdPopperContent {
|
|
4
4
|
className: 'TdPopperContent';
|
|
5
5
|
props: ITdPopperContentConfig;
|
|
6
6
|
private focusTrap;
|
|
@@ -2,37 +2,31 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdPopperContent = void 0;
|
|
4
4
|
const utils_1 = require("@type-dom/utils");
|
|
5
|
-
const
|
|
5
|
+
const framework_1 = require("@type-dom/framework");
|
|
6
|
+
const td_form_const_1 = require("../../../form/td-form/td-form.const");
|
|
6
7
|
const td_focus_trap_class_1 = require("../../td-focus-trap/td-focus-trap.class");
|
|
8
|
+
const constants_1 = require("../constants");
|
|
7
9
|
const content_const_1 = require("./content.const");
|
|
8
|
-
|
|
9
|
-
const td_popper_const_1 = require("../td-popper.const");
|
|
10
|
-
class TdPopperContent extends ui_abstract_1.UI {
|
|
10
|
+
class TdPopperContent extends framework_1.TypeDiv {
|
|
11
11
|
constructor(params = {}) {
|
|
12
|
-
super(
|
|
12
|
+
super();
|
|
13
13
|
this.className = 'TdPopperContent';
|
|
14
14
|
this.attr.addName('td-popper-content');
|
|
15
15
|
this.attr.addObj({
|
|
16
16
|
tabindex: -1
|
|
17
17
|
});
|
|
18
|
-
this.style.addObj({
|
|
19
|
-
// padding: '10px',
|
|
20
|
-
// backgroundColor: $bgColors.default,
|
|
21
|
-
// borderRadius: $borderRadius.base,
|
|
22
|
-
// boxShadow: $boxShadow.base,
|
|
23
|
-
});
|
|
24
18
|
this.focusTrap = new td_focus_trap_class_1.TdFocusTrap();
|
|
25
19
|
this.addChild(this.focusTrap);
|
|
26
20
|
if (params.contentStyle) { // todo
|
|
27
21
|
this.style.addObj(params.contentStyle);
|
|
28
22
|
}
|
|
29
|
-
this.
|
|
23
|
+
this.assignProps(content_const_1.popperContentProps);
|
|
30
24
|
this.props = this.useParams(params);
|
|
31
25
|
}
|
|
32
26
|
setup() {
|
|
33
27
|
const formItemContext = this.inject(td_form_const_1.formItemContextKey, undefined);
|
|
34
28
|
const arrowOffset = 0;
|
|
35
|
-
this.provide(
|
|
29
|
+
this.provide(constants_1.POPPER_CONTENT_INJECTION_KEY, {
|
|
36
30
|
// arrowStyle,
|
|
37
31
|
// arrowRef,
|
|
38
32
|
arrowOffset,
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const
|
|
1
|
+
import { IPopperCoreConfig, ITdPopperContentConfig } from './content.interface';
|
|
2
|
+
export declare const popperCoreProps: IPopperCoreConfig;
|
|
3
3
|
export declare const popperContentProps: ITdPopperContentConfig;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.popperContentProps = exports.
|
|
4
|
-
exports.
|
|
3
|
+
exports.popperContentProps = exports.popperCoreProps = void 0;
|
|
4
|
+
exports.popperCoreProps = {
|
|
5
5
|
boundariesPadding: 0,
|
|
6
|
-
// fallbackPlacements: undefined,
|
|
7
6
|
gpuAcceleration: true,
|
|
8
7
|
/**
|
|
9
8
|
* @description offset of the Tooltip
|
|
@@ -19,7 +18,7 @@ exports.popperCoreConfigProps = {
|
|
|
19
18
|
// popperOptions: () => ({}),
|
|
20
19
|
strategy: 'absolute',
|
|
21
20
|
};
|
|
22
|
-
exports.popperContentProps = Object.assign(Object.assign({}, exports.
|
|
21
|
+
exports.popperContentProps = Object.assign(Object.assign({}, exports.popperCoreProps), {
|
|
23
22
|
// style: {
|
|
24
23
|
// type: definePropType<StyleValue>([String, Array, Object]),
|
|
25
24
|
// },
|
|
@@ -1,10 +1,19 @@
|
|
|
1
|
-
import { IUI, IUIConfig } from '../../../../ui/ui.interface';
|
|
2
1
|
import { IStyle } from '@type-dom/css-type';
|
|
3
|
-
|
|
2
|
+
import { IEmits, ITypeConfig, ITypeDiv } from '@type-dom/framework';
|
|
3
|
+
export interface ITdPopperContent extends ITypeDiv {
|
|
4
4
|
className: 'TdPopperContent';
|
|
5
5
|
}
|
|
6
|
-
|
|
6
|
+
declare const top = "top";
|
|
7
|
+
declare const bottom = "bottom";
|
|
8
|
+
declare const right = "right";
|
|
9
|
+
declare const left = "left";
|
|
10
|
+
type BasePlacement = typeof top | typeof bottom | typeof right | typeof left;
|
|
11
|
+
type VariationPlacement = 'top-start' | 'top-end' | 'bottom-start' | 'bottom-end' | 'right-start' | 'right-end' | 'left-start' | 'left-end';
|
|
12
|
+
type AutoPlacement = 'auto' | 'auto-start' | 'auto-end';
|
|
13
|
+
export type Placement = AutoPlacement | BasePlacement | VariationPlacement;
|
|
14
|
+
export interface IPopperCoreConfig extends ITypeConfig {
|
|
7
15
|
boundariesPadding?: number;
|
|
16
|
+
fallbackPlacements?: Placement[];
|
|
8
17
|
gpuAcceleration?: boolean;
|
|
9
18
|
/**
|
|
10
19
|
* @description offset of the Tooltip
|
|
@@ -18,10 +27,12 @@ export interface IPopperCoreConfigProps extends IUIConfig {
|
|
|
18
27
|
placement?: string;
|
|
19
28
|
/**
|
|
20
29
|
* @description [popper.js](https://popper.js.org/docs/v2/) parameters
|
|
30
|
+
* // default: () => ({}),
|
|
21
31
|
*/
|
|
32
|
+
popperOptions?: Record<string, any>;
|
|
22
33
|
strategy?: string;
|
|
23
34
|
}
|
|
24
|
-
export interface ITdPopperContentConfig extends
|
|
35
|
+
export interface ITdPopperContentConfig extends IPopperCoreConfig {
|
|
25
36
|
id?: string;
|
|
26
37
|
contentStyle?: IStyle;
|
|
27
38
|
effect?: string;
|
|
@@ -30,17 +41,19 @@ export interface ITdPopperContentConfig extends IPopperCoreConfigProps {
|
|
|
30
41
|
pure?: boolean;
|
|
31
42
|
focusOnShow?: boolean;
|
|
32
43
|
trapping?: boolean;
|
|
44
|
+
popperStyle?: IStyle;
|
|
33
45
|
referenceEl?: HTMLElement;
|
|
34
46
|
triggerTargetEl?: HTMLElement;
|
|
35
47
|
stopPopperMouseEvent?: boolean;
|
|
36
48
|
ariaLabel?: string;
|
|
37
49
|
virtualTriggering?: boolean;
|
|
38
50
|
zIndex?: number;
|
|
39
|
-
emits?: {
|
|
40
|
-
mouseenter?: (evt: MouseEvent) => void;
|
|
41
|
-
mouseleave?: (evt: MouseEvent) => void;
|
|
42
|
-
focus?: (evt: FocusEvent) => void;
|
|
43
|
-
blur?: (evt: FocusEvent) => void;
|
|
44
|
-
close?: () => void;
|
|
45
|
-
};
|
|
46
51
|
}
|
|
52
|
+
export interface ITdPopperContentEmits extends IEmits {
|
|
53
|
+
mouseenter?: (evt: MouseEvent) => void;
|
|
54
|
+
mouseleave?: (evt: MouseEvent) => void;
|
|
55
|
+
focus?: (evt: FocusEvent) => void;
|
|
56
|
+
blur?: (evt: FocusEvent) => void;
|
|
57
|
+
close?: () => void;
|
|
58
|
+
}
|
|
59
|
+
export {};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SlotNode, TypeFragment } from '@type-dom/framework';
|
|
2
2
|
import { ITdPopper, ITdPopperConfig } from './td-popper.interface';
|
|
3
|
-
export declare class TdPopper extends
|
|
3
|
+
export declare class TdPopper extends TypeFragment implements ITdPopper {
|
|
4
4
|
className: 'TdPopper';
|
|
5
|
+
content: SlotNode;
|
|
5
6
|
props: ITdPopperConfig;
|
|
6
7
|
constructor(params: ITdPopperConfig);
|
|
7
8
|
}
|
|
@@ -2,19 +2,21 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdPopper = void 0;
|
|
4
4
|
const framework_1 = require("@type-dom/framework");
|
|
5
|
-
const
|
|
5
|
+
const constants_1 = require("./constants");
|
|
6
6
|
const td_popper_const_1 = require("./td-popper.const");
|
|
7
|
-
class TdPopper extends
|
|
7
|
+
class TdPopper extends framework_1.TypeFragment {
|
|
8
8
|
constructor(params) {
|
|
9
|
-
super(
|
|
9
|
+
super();
|
|
10
10
|
this.className = 'TdPopper';
|
|
11
|
+
// this.useTag('fragment');
|
|
12
|
+
this.content = new framework_1.SlotNode();
|
|
13
|
+
this.addChild(this.content);
|
|
11
14
|
const triggerRef = (0, framework_1.createProxy)(null);
|
|
12
15
|
const popperInstanceRef = (0, framework_1.createProxy)(null);
|
|
13
16
|
const contentRef = (0, framework_1.createProxy)(null);
|
|
14
17
|
const referenceRef = (0, framework_1.createProxy)(null);
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
+
this.content.addSlot(params.slot);
|
|
19
|
+
this.assignProps(td_popper_const_1.popperProps);
|
|
18
20
|
this.props = this.useParams(params);
|
|
19
21
|
const role = this.props.role;
|
|
20
22
|
const popperProviders = {
|
|
@@ -39,7 +41,7 @@ class TdPopper extends ui_abstract_1.UI {
|
|
|
39
41
|
*/
|
|
40
42
|
role,
|
|
41
43
|
};
|
|
42
|
-
this.provide(
|
|
44
|
+
this.provide(constants_1.POPPER_INJECTION_KEY, popperProviders);
|
|
43
45
|
}
|
|
44
46
|
}
|
|
45
47
|
exports.TdPopper = TdPopper;
|
|
@@ -1,21 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
* contentRef indicates the element of popper content
|
|
6
|
-
* referenceRef indicates the element that popper content relative with
|
|
7
|
-
*/
|
|
8
|
-
export type TdPopperInjectionContext = {
|
|
9
|
-
triggerRef: any;
|
|
10
|
-
contentRef: any;
|
|
11
|
-
popperInstanceRef: any;
|
|
12
|
-
referenceRef: any;
|
|
13
|
-
role: IRoleTypes;
|
|
1
|
+
import { ITdPopperConfig } from './td-popper.interface';
|
|
2
|
+
export declare const Effect: {
|
|
3
|
+
LIGHT: string;
|
|
4
|
+
DARK: string;
|
|
14
5
|
};
|
|
15
|
-
export declare const
|
|
16
|
-
export type ElPopperContentInjectionContext = {
|
|
17
|
-
arrowRef: any;
|
|
18
|
-
arrowOffset: any;
|
|
19
|
-
arrowStyle: any;
|
|
20
|
-
};
|
|
21
|
-
export declare const POPPER_CONTENT_INJECTION_KEY: InjectionKey<ElPopperContentInjectionContext>;
|
|
6
|
+
export declare const popperProps: ITdPopperConfig;
|
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
|
|
3
|
+
exports.popperProps = exports.Effect = void 0;
|
|
4
|
+
exports.Effect = {
|
|
5
|
+
LIGHT: 'light',
|
|
6
|
+
DARK: 'dark'
|
|
7
|
+
};
|
|
8
|
+
exports.popperProps = {
|
|
9
|
+
role: 'tooltip'
|
|
10
|
+
};
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface ITdPopper extends
|
|
1
|
+
import { ITypeConfig, ITypeElement } from '@type-dom/framework';
|
|
2
|
+
export interface ITdPopper extends ITypeElement {
|
|
3
3
|
className: 'TdPopper';
|
|
4
4
|
}
|
|
5
5
|
export type IRoleTypes = 'dialog' | 'grid' | 'group' | 'listbox' | 'menu' | 'navigation' | 'tooltip' | 'tree';
|
|
6
|
-
export interface ITdPopperConfig extends
|
|
6
|
+
export interface ITdPopperConfig extends ITypeConfig {
|
|
7
7
|
/**
|
|
8
|
-
*
|
|
8
|
+
* default: 'tooltip',
|
|
9
9
|
*/
|
|
10
10
|
role?: IRoleTypes;
|
|
11
11
|
}
|
|
12
|
+
export type ITdPopperEffect = 'dark' | 'light';
|
|
13
|
+
export type ITdPopperTrigger = 'click' | 'hover' | 'focus' | 'context-menu';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TypeDiv } from '@type-dom/framework';
|
|
2
2
|
import { ITdPopperTrigger, ITdPopperTriggerConfig } from './trigger.interface';
|
|
3
|
-
export declare class TdPopperTrigger extends
|
|
3
|
+
export declare class TdPopperTrigger extends TypeDiv implements ITdPopperTrigger {
|
|
4
4
|
className: 'TdPopperTrigger';
|
|
5
5
|
props: ITdPopperTriggerConfig;
|
|
6
6
|
private role;
|
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdPopperTrigger = void 0;
|
|
4
4
|
const utils_1 = require("@type-dom/utils");
|
|
5
|
-
const
|
|
5
|
+
const framework_1 = require("@type-dom/framework");
|
|
6
6
|
const use_forward_ref_1 = require("../../../../hooks/use-forward-ref");
|
|
7
7
|
const td_only_child_class_1 = require("../../td-only-child/td-only-child.class");
|
|
8
8
|
const content_const_1 = require("../content/content.const");
|
|
9
|
-
const
|
|
9
|
+
const constants_1 = require("../constants");
|
|
10
10
|
const trigger_const_1 = require("./trigger.const");
|
|
11
|
-
class TdPopperTrigger extends
|
|
11
|
+
class TdPopperTrigger extends framework_1.TypeDiv {
|
|
12
12
|
constructor(params = {}) {
|
|
13
|
-
super(
|
|
13
|
+
super();
|
|
14
14
|
this.className = 'TdPopperTrigger';
|
|
15
15
|
if (!params.virtualTriggering) {
|
|
16
16
|
this.addChild(new td_only_child_class_1.TdOnlyChild());
|
|
17
17
|
}
|
|
18
|
-
this.
|
|
18
|
+
this.assignProps(content_const_1.popperContentProps);
|
|
19
19
|
this.props = this.useParams(params);
|
|
20
20
|
}
|
|
21
21
|
get ariaHaspopup() {
|
|
@@ -37,7 +37,7 @@ class TdPopperTrigger extends ui_abstract_1.UI {
|
|
|
37
37
|
return this.ariaHaspopup.value ? `${this.props.open}` : undefined;
|
|
38
38
|
}
|
|
39
39
|
setup() {
|
|
40
|
-
const { role, triggerRef } = this.inject(
|
|
40
|
+
const { role, triggerRef } = this.inject(constants_1.POPPER_INJECTION_KEY, undefined);
|
|
41
41
|
this.role = role;
|
|
42
42
|
this.triggerRef = triggerRef;
|
|
43
43
|
(0, use_forward_ref_1.useForwardRef)(triggerRef);
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TRIGGER_ELE_EVENTS = void 0;
|
|
3
|
+
exports.TRIGGER_ELE_EVENTS = exports.popperTriggerProps = void 0;
|
|
4
|
+
exports.popperTriggerProps = {
|
|
5
|
+
/* 没有默认值 */
|
|
6
|
+
};
|
|
4
7
|
exports.TRIGGER_ELE_EVENTS = [
|
|
5
8
|
'onMouseenter',
|
|
6
9
|
'onMouseleave',
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export interface ITdPopperTrigger extends
|
|
1
|
+
import { ITypeConfig, ITypeDiv } from '@type-dom/framework';
|
|
2
|
+
export interface ITdPopperTrigger extends ITypeDiv {
|
|
3
3
|
className: 'TdPopperTrigger';
|
|
4
4
|
}
|
|
5
5
|
type IEvent = (event: Event) => void;
|
|
6
|
-
export interface ITdPopperTriggerConfig extends
|
|
6
|
+
export interface ITdPopperTriggerConfig extends ITypeConfig {
|
|
7
7
|
virtualRef?: HTMLElement;
|
|
8
8
|
virtualTriggering?: boolean;
|
|
9
9
|
onMouseenter?: IEvent;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TypeDiv } from '@type-dom/framework';
|
|
2
2
|
import { ITdTooltipContentConfig } from './content.interface';
|
|
3
|
-
export declare class TdTooltipContent extends
|
|
3
|
+
export declare class TdTooltipContent extends TypeDiv {
|
|
4
4
|
className: 'TdTooltipContent';
|
|
5
5
|
props: ITdTooltipContentConfig;
|
|
6
6
|
constructor(params?: ITdTooltipContentConfig);
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TdTooltipContent = void 0;
|
|
4
|
-
const
|
|
5
|
-
class TdTooltipContent extends
|
|
4
|
+
const framework_1 = require("@type-dom/framework");
|
|
5
|
+
class TdTooltipContent extends framework_1.TypeDiv {
|
|
6
6
|
constructor(params = {}) {
|
|
7
|
-
super(
|
|
7
|
+
super();
|
|
8
8
|
this.className = 'TdTooltipContent';
|
|
9
|
+
this.attr.addName('td-tooltip-content');
|
|
9
10
|
this.props = this.useParams(params);
|
|
10
11
|
}
|
|
11
12
|
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
export declare const tooltipContentProps: {
|
|
2
|
+
teleported: boolean;
|
|
3
|
+
id?: string;
|
|
4
|
+
contentStyle?: import("dist/libs/css-type/src").IStyle;
|
|
5
|
+
effect?: string;
|
|
6
|
+
visible?: boolean;
|
|
7
|
+
enterable?: boolean;
|
|
8
|
+
pure?: boolean;
|
|
9
|
+
focusOnShow?: boolean;
|
|
10
|
+
trapping?: boolean;
|
|
11
|
+
popperStyle?: import("dist/libs/css-type/src").IStyle;
|
|
12
|
+
referenceEl?: HTMLElement;
|
|
13
|
+
triggerTargetEl?: HTMLElement;
|
|
14
|
+
stopPopperMouseEvent?: boolean;
|
|
15
|
+
ariaLabel?: string;
|
|
16
|
+
virtualTriggering?: boolean;
|
|
17
|
+
zIndex?: number;
|
|
18
|
+
boundariesPadding?: number;
|
|
19
|
+
fallbackPlacements?: import("../../td-popper/content/content.interface").Placement[];
|
|
20
|
+
gpuAcceleration?: boolean;
|
|
21
|
+
offset?: number;
|
|
22
|
+
placement?: string;
|
|
23
|
+
popperOptions?: Record<string, any>;
|
|
24
|
+
strategy?: string;
|
|
25
|
+
name?: string | number;
|
|
26
|
+
tag?: "fragment" | string;
|
|
27
|
+
ref?: import("dist/libs/framework/src").XProxy<import("dist/libs/framework/src").IJsonData> | import("dist/libs/framework/src").Ref<any>;
|
|
28
|
+
refId?: string | number;
|
|
29
|
+
text?: boolean | string | number | import("dist/libs/framework/src").XProxy<import("dist/libs/framework/src").IJsonData>;
|
|
30
|
+
attrObj?: import("dist/libs/framework/src").ITypeAttribute | undefined;
|
|
31
|
+
styleObj?: import("dist/libs/css-type/src").IStyle | undefined;
|
|
32
|
+
childNodes?: import("dist/libs/framework/src").TypeNode[] | undefined;
|
|
33
|
+
items?: import("dist/libs/framework/src").ITypeConfig[];
|
|
34
|
+
slots?: import("dist/libs/framework/src").IConfigSlots;
|
|
35
|
+
slot?: import("dist/libs/framework/src").IConfigSlot;
|
|
36
|
+
html?: string;
|
|
37
|
+
init?: (element: import("dist/libs/framework/src").TypeElement) => void;
|
|
38
|
+
emits?: import("dist/libs/framework/src").IEmits;
|
|
39
|
+
events?: Partial<import("dist/libs/framework/src").IEvents>;
|
|
40
|
+
template?: string;
|
|
41
|
+
fieldSetting?: import("dist/libs/framework/src").IOptionSetting;
|
|
42
|
+
className?: string;
|
|
43
|
+
nodeName?: "fragment" | string | undefined;
|
|
44
|
+
nodeValue?: string | number | undefined;
|
|
45
|
+
to?: HTMLElement;
|
|
46
|
+
parent?: import("dist/libs/framework/src").TypeElement | import("dist/libs/framework/src").SlotNode;
|
|
47
|
+
context?: import("dist/libs/framework/src").TypeNode;
|
|
48
|
+
isRoot?: boolean;
|
|
49
|
+
methods?: import("dist/libs/framework/src").IMethods;
|
|
50
|
+
settings?: import("dist/libs/framework/src").ISettings;
|
|
51
|
+
defaults?: import("dist/libs/framework/src").ISettings;
|
|
52
|
+
showAfter: number;
|
|
53
|
+
hideAfter: number;
|
|
54
|
+
autoClose: number;
|
|
55
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.tooltipContentProps = void 0;
|
|
4
|
+
const use_delayed_toggle_1 = require("../../../../hooks/use-delayed-toggle");
|
|
5
|
+
const content_const_1 = require("../../td-popper/content/content.const");
|
|
6
|
+
exports.tooltipContentProps = Object.assign(Object.assign(Object.assign({}, use_delayed_toggle_1.useDelayedToggleProps), content_const_1.popperContentProps), { teleported: true });
|
|
@@ -1,9 +1,25 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { IDelayedToggleConfig } from '../../../../hooks/use-delayed-toggle';
|
|
2
2
|
import { ITdPopperContentConfig } from '../../td-popper/content/content.interface';
|
|
3
|
-
|
|
3
|
+
import { ITypeDiv } from '@type-dom/framework';
|
|
4
|
+
export interface ITdTooltipContent extends ITypeDiv {
|
|
4
5
|
className: 'TdTooltipContent';
|
|
5
6
|
}
|
|
6
|
-
export interface ITdTooltipContentConfig extends ITdPopperContentConfig {
|
|
7
|
+
export interface ITdTooltipContentConfig extends ITdPopperContentConfig, IDelayedToggleConfig {
|
|
8
|
+
/**
|
|
9
|
+
* @description delay of appearance, in millisecond
|
|
10
|
+
* default: 0,
|
|
11
|
+
*/
|
|
12
|
+
showAfter?: number;
|
|
13
|
+
/**
|
|
14
|
+
* @description delay of disappear, in millisecond
|
|
15
|
+
* default: 200,
|
|
16
|
+
*/
|
|
17
|
+
hideAfter?: number;
|
|
18
|
+
/**
|
|
19
|
+
* @description disappear automatically, in millisecond
|
|
20
|
+
* default: 0,
|
|
21
|
+
*/
|
|
22
|
+
autoClose?: number;
|
|
7
23
|
/**
|
|
8
24
|
* @description which element the tooltip CONTENT appends to
|
|
9
25
|
*/
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TypeFragment } from '@type-dom/framework';
|
|
2
|
+
import { TdPopper } from '../td-popper/td-popper.class';
|
|
2
3
|
import { ITdTooltip, ITdTooltipConfig } from './td-tooltip.interface';
|
|
3
|
-
export declare class TdTooltip extends
|
|
4
|
+
export declare class TdTooltip extends TypeFragment implements ITdTooltip {
|
|
4
5
|
className: 'TdTooltip';
|
|
6
|
+
content: TdPopper;
|
|
5
7
|
props: ITdTooltipConfig;
|
|
6
8
|
private trigger;
|
|
7
|
-
private
|
|
9
|
+
private popperContent;
|
|
8
10
|
constructor(params?: ITdTooltipConfig);
|
|
9
11
|
}
|