@type-dom/ui 0.0.3 → 0.0.5
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/README.md +0 -1
- package/package.json +1 -1
- package/src/aria.d.ts +15 -0
- package/src/components/basic/index.d.ts +2 -0
- package/src/components/basic/index.js +8 -1
- package/src/components/basic/td-button/td-button.abstract.d.ts +19 -0
- package/src/components/basic/td-button/td-button.abstract.js +175 -0
- package/src/components/basic/td-button/td-button.class.d.ts +3 -14
- package/src/components/basic/td-button/td-button.class.js +4 -172
- package/src/components/basic/td-button/td-button.const.d.ts +7 -0
- package/src/components/basic/td-button/td-button.const.js +4 -0
- package/src/components/basic/td-button/td-button.interface.d.ts +16 -6
- package/src/components/basic/td-button/td-button.interface.js +4 -0
- package/src/components/basic/td-button/td-button.style.d.ts +8 -3
- package/src/components/basic/td-button/td-button.style.js +26 -8
- package/src/components/basic/td-button-group/td-button-group.class.d.ts +2 -2
- package/src/components/basic/td-button-group/td-button-group.class.js +28 -25
- package/src/components/basic/td-container/td-aside/td-aside.class.d.ts +3 -2
- package/src/components/basic/td-container/td-aside/td-aside.class.js +7 -16
- package/src/components/basic/td-container/td-container.class.d.ts +4 -3
- package/src/components/basic/td-container/td-container.class.js +9 -8
- package/src/components/basic/td-container/td-container.interface.d.ts +2 -2
- 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 -3
- package/src/components/basic/td-container/td-footer/td-footer.class.js +9 -11
- 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 +10 -10
- package/src/components/basic/td-container/td-main/td-main.class.d.ts +2 -1
- package/src/components/basic/td-container/td-main/td-main.class.js +6 -4
- package/src/components/basic/td-icon/td-icon.class.d.ts +30 -6
- package/src/components/basic/td-icon/td-icon.class.js +111 -47
- package/src/components/basic/td-icon/td-icon.interface.d.ts +36 -6
- package/src/components/basic/td-icon/td-icon.style.d.ts +5 -14
- package/src/components/basic/td-icon/td-icon.style.js +5 -6
- package/src/components/basic/td-layout/td-col/td-col.class.d.ts +4 -4
- package/src/components/basic/td-layout/td-col/td-col.class.js +48 -45
- package/src/components/basic/td-layout/td-col/td-col.interface.d.ts +0 -4
- package/src/components/basic/td-layout/td-row/td-row.class.d.ts +4 -3
- package/src/components/basic/td-layout/td-row/td-row.class.js +31 -30
- package/src/components/basic/td-layout/td-row/td-row.interface.d.ts +0 -1
- package/src/components/basic/td-link/td-link.class.d.ts +5 -5
- package/src/components/basic/td-link/td-link.class.js +53 -55
- package/src/components/basic/td-link/td-link.interface.d.ts +14 -6
- package/src/components/basic/td-link/td-link.style.d.ts +14 -3
- package/src/components/basic/td-link/td-link.style.js +39 -9
- package/src/components/basic/td-scrollbar/bar/bar.class.d.ts +2 -1
- package/src/components/basic/td-scrollbar/bar/bar.class.js +8 -7
- package/src/components/basic/td-scrollbar/td-scrollbar.class.d.ts +3 -3
- package/src/components/basic/td-scrollbar/td-scrollbar.class.js +18 -20
- package/src/components/basic/td-scrollbar/td-scrollbar.interface.d.ts +3 -2
- package/src/components/basic/td-scrollbar/thumb/thumb.class.d.ts +2 -1
- package/src/components/basic/td-scrollbar/thumb/thumb.class.js +12 -12
- package/src/components/basic/td-space/td-space.class.d.ts +5 -5
- package/src/components/basic/td-space/td-space.class.js +32 -30
- package/src/components/basic/td-space/td-space.interface.d.ts +1 -0
- package/src/components/basic/td-text/td-text.class.d.ts +3 -3
- package/src/components/basic/td-text/td-text.class.js +22 -19
- package/src/components/basic/td-text/td-text.interface.d.ts +4 -2
- package/src/components/basic/td-text/td-text.style.d.ts +1 -1
- package/src/components/basic/td-text/td-text.style.js +11 -2
- package/src/components/data/index.d.ts +30 -0
- package/src/components/data/index.js +34 -0
- package/src/components/data/td-avatar/td-avatar.class.d.ts +12 -0
- package/src/components/data/td-avatar/td-avatar.class.js +120 -0
- package/src/components/data/td-avatar/td-avatar.interface.d.ts +41 -0
- package/src/components/data/td-avatar/td-avatar.style.d.ts +13 -0
- package/src/components/data/td-avatar/td-avatar.style.js +20 -0
- package/src/components/data/td-badge/td-badge.class.d.ts +9 -0
- package/src/components/data/td-badge/td-badge.class.js +104 -0
- package/src/components/data/td-badge/td-badge.interface.d.ts +52 -0
- package/src/components/data/td-badge/td-badge.style.d.ts +7 -0
- package/src/components/data/td-badge/td-badge.style.js +12 -0
- package/src/components/data/td-card/td-card.class.d.ts +14 -0
- package/src/components/data/td-card/td-card.class.js +102 -0
- package/src/components/data/td-card/td-card.interface.d.ts +26 -0
- package/src/components/data/td-card/td-card.interface.js +2 -0
- package/src/components/data/td-card/td-card.style.d.ts +9 -0
- package/src/components/data/td-card/td-card.style.js +29 -0
- package/src/components/data/td-carousel/td-carousel.class.d.ts +0 -0
- package/src/components/data/td-carousel/td-carousel.class.js +1 -0
- package/src/components/data/td-carousel/td-carousel.interface.d.ts +0 -0
- package/src/components/data/td-carousel/td-carousel.interface.js +1 -0
- package/src/components/data/td-check-tag/td-check-tag.class.d.ts +12 -0
- package/src/components/data/td-check-tag/td-check-tag.class.js +75 -0
- package/src/components/data/td-check-tag/td-check-tag.interface.d.ts +22 -0
- package/src/components/data/td-check-tag/td-check-tag.interface.js +3 -0
- package/src/components/data/td-check-tag/td-check-tag.style.d.ts +7 -0
- package/src/components/data/td-check-tag/td-check-tag.style.js +39 -0
- package/src/components/data/td-collapse/td-collapse.class.d.ts +13 -0
- package/src/components/data/td-collapse/td-collapse.class.js +85 -0
- package/src/components/data/td-collapse/td-collapse.interface.d.ts +18 -0
- package/src/components/data/td-collapse/td-collapse.interface.js +2 -0
- package/src/components/data/td-collapse/td-collapse.style.d.ts +11 -0
- package/src/components/data/td-collapse/td-collapse.style.js +22 -0
- package/src/components/data/td-collapse-item/td-collapse-item.class.d.ts +25 -0
- package/src/components/data/td-collapse-item/td-collapse-item.class.js +222 -0
- package/src/components/data/td-collapse-item/td-collapse-item.interface.d.ts +20 -0
- package/src/components/data/td-collapse-item/td-collapse-item.interface.js +2 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.class.d.ts +6 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.class.js +12 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.interface.d.ts +4 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.interface.js +2 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.util.d.ts +2 -0
- package/src/components/data/td-collapse-transition/td-collapse-transition.util.js +147 -0
- package/src/components/data/td-count-down/td-count-down.class.d.ts +13 -0
- package/src/components/data/td-count-down/td-count-down.class.js +57 -0
- package/src/components/data/td-count-down/td-count-down.function.d.ts +0 -0
- package/src/components/data/td-count-down/td-count-down.function.js +1 -0
- package/src/components/data/td-count-down/td-count-down.interface.d.ts +11 -0
- package/src/components/data/td-count-down/td-count-down.interface.js +2 -0
- package/src/components/data/td-count-down/utils.d.ts +3 -0
- package/src/components/data/td-count-down/utils.js +32 -0
- package/src/components/data/td-descriptions/td-descriptions-row.d.ts +21 -0
- package/src/components/data/td-descriptions/td-descriptions-row.js +80 -0
- package/src/components/data/td-descriptions/td-descriptions.class.d.ts +18 -0
- package/src/components/data/td-descriptions/td-descriptions.class.js +156 -0
- package/src/components/data/td-descriptions/td-descriptions.interface.d.ts +43 -0
- package/src/components/data/td-descriptions/td-descriptions.interface.js +2 -0
- package/src/components/data/td-descriptions/td-descriptions.style.d.ts +51 -0
- package/src/components/data/td-descriptions/td-descriptions.style.js +142 -0
- package/src/components/data/td-descriptions/td-descritions-cell.d.ts +15 -0
- package/src/components/data/td-descriptions/td-descritions-cell.js +110 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.class.d.ts +10 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.class.js +20 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.interface.d.ts +51 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.interface.js +2 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.style.d.ts +10 -0
- package/src/components/data/td-descriptions-item/td-descriptions-item.style.js +13 -0
- package/src/components/data/td-empty/img-empty.class.d.ts +5 -0
- package/src/components/data/td-empty/img-empty.class.js +204 -0
- package/src/components/data/td-empty/td-empty.class.d.ts +13 -0
- package/src/components/data/td-empty/td-empty.class.js +77 -0
- package/src/components/data/td-empty/td-empty.interface.d.ts +25 -0
- package/src/components/data/td-empty/td-empty.interface.js +2 -0
- package/src/components/data/td-empty/td-empty.style.d.ts +24 -0
- package/src/components/data/td-empty/td-empty.style.js +65 -0
- package/src/components/data/td-image/td-image.class.d.ts +16 -0
- package/src/components/data/td-image/td-image.class.js +95 -0
- package/src/components/data/td-image/td-image.interface.d.ts +78 -0
- package/src/components/data/td-image/td-image.interface.js +2 -0
- package/src/components/data/td-image/td-image.style.d.ts +11 -0
- package/src/components/data/td-image/td-image.style.js +18 -0
- package/src/components/data/td-image/util.d.ts +1 -0
- package/src/components/data/td-image/util.js +19 -0
- package/src/components/data/td-image-viewer/td-image-viewer.class.d.ts +20 -0
- package/src/components/data/td-image-viewer/td-image-viewer.class.js +261 -0
- package/src/components/data/td-image-viewer/td-image-viewer.interface.d.ts +63 -0
- package/src/components/data/td-image-viewer/td-image-viewer.interface.js +2 -0
- package/src/components/data/td-image-viewer/td-image-viewer.style.d.ts +9 -0
- package/src/components/data/td-image-viewer/td-image-viewer.style.js +67 -0
- package/src/components/data/td-pagination/td-pagination.class.d.ts +0 -0
- package/src/components/data/td-pagination/td-pagination.class.js +1 -0
- package/src/components/data/td-pagination/td-pagination.interface.d.ts +0 -0
- package/src/components/data/td-pagination/td-pagination.interface.js +1 -0
- package/src/components/data/td-progress/td-progress.class.d.ts +0 -0
- package/src/components/data/td-progress/td-progress.class.js +1 -0
- package/src/components/data/td-progress/td-progress.interface.d.ts +0 -0
- package/src/components/data/td-progress/td-progress.interface.js +1 -0
- package/src/components/data/td-result/td-result.class.d.ts +8 -0
- package/src/components/data/td-result/td-result.class.js +87 -0
- package/src/components/data/td-result/td-result.constant.d.ts +8 -0
- package/src/components/data/td-result/td-result.constant.js +41 -0
- package/src/components/data/td-result/td-result.interface.d.ts +28 -0
- package/src/components/data/td-result/td-result.interface.js +2 -0
- package/src/components/data/td-result/td-result.style.d.ts +16 -0
- package/src/components/data/td-result/td-result.style.js +46 -0
- package/src/components/data/td-segmented/td-segmented.class.d.ts +22 -0
- package/src/components/data/td-segmented/td-segmented.class.js +172 -0
- package/src/components/data/td-segmented/td-segmented.interface.d.ts +51 -0
- package/src/components/data/td-segmented/td-segmented.interface.js +2 -0
- package/src/components/data/td-segmented/td-segmented.style.d.ts +37 -0
- package/src/components/data/td-segmented/td-segmented.style.js +142 -0
- package/src/components/data/td-statistic/td-statistic.abstract.d.ts +15 -0
- package/src/components/data/td-statistic/td-statistic.abstract.js +113 -0
- package/src/components/data/td-statistic/td-statistic.class.d.ts +6 -0
- package/src/components/data/td-statistic/td-statistic.class.js +11 -0
- package/src/components/data/td-statistic/td-statistic.interface.d.ts +58 -0
- package/src/components/data/td-statistic/td-statistic.interface.js +2 -0
- package/src/components/data/td-statistic/td-statistic.style.d.ts +9 -0
- package/src/components/data/td-statistic/td-statistic.style.js +16 -0
- package/src/components/data/td-table/td-table.class.d.ts +0 -0
- package/src/components/data/td-table/td-table.class.js +1 -0
- package/src/components/data/td-table/td-table.interface.d.ts +0 -0
- package/src/components/data/td-table/td-table.interface.js +1 -0
- package/src/components/data/td-tag/td-tag.class.d.ts +12 -0
- package/src/components/data/td-tag/td-tag.class.js +144 -0
- package/src/components/data/td-tag/td-tag.interface.d.ts +42 -0
- package/src/components/data/td-tag/td-tag.interface.js +2 -0
- package/src/components/data/td-tag/td-tag.style.d.ts +45 -0
- package/src/components/data/td-tag/td-tag.style.js +80 -0
- package/src/components/data/td-timeline/td-timeline.class.d.ts +0 -0
- package/src/components/data/td-timeline/td-timeline.class.js +1 -0
- package/src/components/data/td-timeline/td-timeline.interface.d.ts +0 -0
- package/src/components/data/td-timeline/td-timeline.interface.js +1 -0
- package/src/components/data/td-tree/td-tree.class.d.ts +0 -0
- package/src/components/data/td-tree/td-tree.class.js +1 -0
- package/src/components/data/td-tree/td-tree.interface.d.ts +0 -0
- package/src/components/data/td-tree/td-tree.interface.js +1 -0
- package/src/components/feedback/dialog/dialog.class.d.ts +2 -1
- package/src/components/feedback/dialog/dialog.class.js +5 -5
- package/src/components/feedback/dialog/dialog.interface.d.ts +2 -3
- package/src/components/feedback/index.d.ts +11 -0
- package/src/components/feedback/index.js +15 -1
- package/src/components/feedback/message-box/message-box.d.ts +2 -1
- package/src/components/feedback/message-box/message-box.interface.d.ts +2 -2
- package/src/components/feedback/message-box/message-box.js +6 -6
- package/src/components/feedback/overlay/container/body/body.js +3 -5
- package/src/components/feedback/overlay/container/container.js +4 -6
- package/src/components/feedback/overlay/container/footer/cancel-button/cancel-button.js +3 -3
- package/src/components/feedback/overlay/container/footer/confirm-button/confirm-button.js +4 -6
- package/src/components/feedback/overlay/container/footer/footer.d.ts +1 -2
- package/src/components/feedback/overlay/container/footer/footer.js +24 -26
- package/src/components/feedback/overlay/container/header/close-button/close-button.js +6 -8
- package/src/components/feedback/overlay/container/header/header.js +2 -2
- package/src/components/feedback/overlay/container/header/title/title.js +3 -5
- package/src/components/feedback/overlay/overlay.abstract.js +6 -8
- package/src/components/feedback/td-alert/td-alert.class.d.ts +15 -0
- package/src/components/feedback/td-alert/td-alert.class.js +111 -0
- package/src/components/feedback/td-alert/td-alert.interface.d.ts +41 -0
- package/src/components/feedback/td-alert/td-alert.interface.js +2 -0
- package/src/components/feedback/td-alert/td-alert.style.d.ts +21 -0
- package/src/components/feedback/td-alert/td-alert.style.js +102 -0
- package/src/components/feedback/td-dialog/td-dialog.class.d.ts +12 -0
- package/src/components/feedback/td-dialog/td-dialog.class.js +70 -0
- package/src/components/feedback/td-dialog/td-dialog.interface.d.ts +79 -0
- package/src/components/feedback/td-dialog/td-dialog.interface.js +2 -0
- package/src/components/feedback/td-dialog/td-dialog.style.d.ts +20 -0
- package/src/components/feedback/td-dialog/td-dialog.style.js +89 -0
- package/src/components/feedback/td-dialog-content/td-dialog-content.class.d.ts +12 -0
- package/src/components/feedback/td-dialog-content/td-dialog-content.class.js +79 -0
- package/src/components/feedback/td-dialog-content/td-dialog-content.interface.d.ts +51 -0
- package/src/components/feedback/td-dialog-content/td-dialog-content.interface.js +2 -0
- package/src/components/feedback/td-drawer/td-drawer.class.d.ts +8 -0
- package/src/components/feedback/td-drawer/td-drawer.class.js +39 -0
- package/src/components/feedback/td-drawer/td-drawer.interface.d.ts +12 -0
- package/src/components/feedback/td-drawer/td-drawer.interface.js +2 -0
- package/src/components/feedback/td-focus-trap/td-focus-trap.class.d.ts +4 -3
- package/src/components/feedback/td-focus-trap/td-focus-trap.class.js +11 -11
- package/src/components/feedback/td-focus-trap/td-focus-trap.interface.d.ts +9 -0
- package/src/components/feedback/td-focus-trap/td-focus-trap.interface.js +1 -0
- package/src/components/feedback/td-focus-trap/tokens.d.ts +5 -0
- package/src/components/feedback/td-focus-trap/tokens.js +4 -10
- package/src/components/feedback/td-focus-trap/utils.js +3 -3
- package/src/components/feedback/td-loading/td-loading.class.d.ts +12 -0
- package/src/components/feedback/td-loading/td-loading.class.js +65 -0
- package/src/components/feedback/td-loading/td-loading.interface.d.ts +37 -0
- package/src/components/feedback/td-loading/td-loading.interface.js +2 -0
- package/src/components/feedback/td-message/td-message.class.d.ts +24 -0
- package/src/components/feedback/td-message/td-message.class.js +239 -0
- package/src/components/feedback/td-message/td-message.interface.d.ts +105 -0
- package/src/components/feedback/td-message/td-message.interface.js +22 -0
- package/src/components/feedback/td-message/td-message.style.d.ts +17 -0
- package/src/components/feedback/td-message/td-message.style.js +104 -0
- package/src/components/feedback/td-message-box/td-message-box.class.d.ts +42 -0
- package/src/components/feedback/td-message-box/td-message-box.class.js +531 -0
- package/src/components/feedback/td-message-box/td-message-box.interface.d.ts +142 -0
- package/src/components/feedback/td-message-box/td-message-box.interface.js +2 -0
- package/src/components/feedback/td-message-box/td-message-box.style.d.ts +36 -0
- package/src/components/feedback/td-message-box/td-message-box.style.js +182 -0
- package/src/components/feedback/td-notification/td-notification.class.d.ts +30 -0
- package/src/components/feedback/td-notification/td-notification.class.js +234 -0
- package/src/components/feedback/td-notification/td-notification.interface.d.ts +76 -0
- package/src/components/feedback/td-notification/td-notification.interface.js +2 -0
- package/src/components/feedback/td-notification/td-notification.style.d.ts +28 -0
- package/src/components/feedback/td-notification/td-notification.style.js +138 -0
- package/src/components/feedback/td-overlay/td-overlay.class.d.ts +10 -0
- package/src/components/feedback/td-overlay/td-overlay.class.js +35 -0
- package/src/components/feedback/td-overlay/td-overlay.interface.d.ts +13 -0
- package/src/components/feedback/td-overlay/td-overlay.interface.js +2 -0
- package/src/components/feedback/td-overlay/td-overlay.style.d.ts +2 -0
- package/src/components/feedback/td-overlay/td-overlay.style.js +16 -0
- package/src/components/feedback/td-popconfirm/td-popconfirm.class.d.ts +0 -0
- package/src/components/feedback/td-popconfirm/td-popconfirm.class.js +1 -0
- package/src/components/feedback/td-popconfirm/td-popconfirm.interface.d.ts +0 -0
- package/src/components/feedback/td-popconfirm/td-popconfirm.interface.js +1 -0
- package/src/components/feedback/td-popover/td-popover.class.d.ts +0 -0
- package/src/components/feedback/td-popover/td-popover.class.js +1 -0
- package/src/components/feedback/td-popover/td-popover.interface.d.ts +0 -0
- package/src/components/feedback/td-popover/td-popover.interface.js +1 -0
- package/src/components/feedback/td-popper/arrow/arrow.class.d.ts +2 -1
- package/src/components/feedback/td-popper/arrow/arrow.class.js +6 -6
- package/src/components/feedback/td-popper/content/content.class.d.ts +2 -1
- package/src/components/feedback/td-popper/content/content.class.js +7 -7
- package/src/components/feedback/td-popper/td-popper.class.d.ts +3 -2
- package/src/components/feedback/td-popper/td-popper.class.js +3 -3
- package/src/components/feedback/td-popper/td-popper.interface.d.ts +2 -3
- package/src/components/feedback/td-popper/td-popper.interface.js +0 -11
- package/src/components/feedback/td-popper/trigger/trigger.class.d.ts +2 -1
- package/src/components/feedback/td-popper/trigger/trigger.class.js +3 -2
- package/src/components/feedback/td-popper/trigger/trigger.interface.d.ts +10 -0
- package/src/components/feedback/td-tooltip/content/content.class.d.ts +2 -1
- package/src/components/feedback/td-tooltip/content/content.class.js +3 -3
- package/src/components/feedback/td-tooltip/td-tooltip.class.d.ts +2 -1
- package/src/components/feedback/td-tooltip/td-tooltip.class.js +7 -13
- package/src/components/feedback/td-tooltip/trigger/trigger.class.d.ts +2 -1
- package/src/components/feedback/td-tooltip/trigger/trigger.class.js +3 -3
- package/src/components/feedback/td-tooltip/utils.d.ts +4 -0
- package/src/components/feedback/td-tooltip/utils.js +23 -0
- package/src/components/form/checkbox-group/checkbox-group.class.js +9 -8
- package/src/components/form/checkbox-group/checkbox-option/checkbox-option.class.js +3 -3
- package/src/components/form/field-item/cascade/field-cascade.abstract.js +25 -17
- package/src/components/form/field-item/field-item.abstract.d.ts +7 -3
- package/src/components/form/field-item/field-item.abstract.js +14 -9
- package/src/components/form/field-item/field-item.style.d.ts +1 -1
- package/src/components/form/field-item/field-item.style.js +1 -2
- package/src/components/form/field-item/input/field-input.abstract.d.ts +1 -2
- package/src/components/form/field-item/input/field-input.abstract.js +6 -6
- package/src/components/form/field-item/options/field-options.abstract.js +31 -27
- package/src/components/form/field-item/radio/field-radio.abstract.d.ts +2 -2
- package/src/components/form/field-item/radio/field-radio.abstract.js +30 -21
- package/src/components/form/field-item/select/field-select.abstract.d.ts +1 -2
- package/src/components/form/field-item/select/field-select.abstract.js +3 -3
- package/src/components/form/field-item/span/field-span.abstract.js +4 -4
- package/src/components/form/field-item/textarea/field-textarea.abstract.d.ts +1 -2
- package/src/components/form/field-item/textarea/field-textarea.abstract.js +6 -6
- package/src/components/form/field-select/field-select.class.js +10 -9
- package/src/components/form/field-select/option/option.class.js +1 -1
- package/src/components/form/index.d.ts +10 -0
- package/src/components/form/index.js +11 -1
- package/src/components/form/radio-group/radio-group.class.d.ts +3 -2
- package/src/components/form/radio-group/radio-group.class.js +13 -12
- package/src/components/form/radio-group/radio-option/radio-option.class.d.ts +3 -2
- package/src/components/form/radio-group/radio-option/radio-option.class.js +8 -9
- package/src/components/form/select/select.class.js +4 -4
- package/src/components/form/td-autocomplete/td-autocomplete.class.d.ts +0 -0
- package/src/components/form/td-autocomplete/td-autocomplete.class.js +1 -0
- package/src/components/form/td-autocomplete/td-autocomplete.interface.d.ts +0 -0
- package/src/components/form/td-autocomplete/td-autocomplete.interface.js +1 -0
- package/src/components/form/td-cascader/td-cascader.class.d.ts +0 -0
- package/src/components/form/td-cascader/td-cascader.class.js +1 -0
- package/src/components/form/td-cascader/td-cascader.interface.d.ts +0 -0
- package/src/components/form/td-cascader/td-cascader.interface.js +1 -0
- package/src/components/form/td-checkbox/composables/use-checkbox-status.d.ts +6 -0
- package/src/components/form/td-checkbox/composables/use-checkbox-status.js +52 -0
- package/src/components/form/td-checkbox/composables/use-checkbox.d.ts +6 -0
- package/src/components/form/td-checkbox/composables/use-checkbox.js +85 -0
- package/src/components/form/td-checkbox/td-checkbox.class.d.ts +8 -2
- package/src/components/form/td-checkbox/td-checkbox.class.js +54 -75
- package/src/components/form/td-checkbox/td-checkbox.interface.d.ts +2 -1
- package/src/components/form/td-checkbox/td-checkbox.style.d.ts +46 -0
- package/src/components/form/td-checkbox/td-checkbox.style.js +144 -10
- package/src/components/form/td-checkbox-button/td-checkbox-button.class.d.ts +9 -2
- package/src/components/form/td-checkbox-button/td-checkbox-button.class.js +56 -6
- package/src/components/form/td-checkbox-button/td-checkbox-button.style.d.ts +9 -0
- package/src/components/form/td-checkbox-button/td-checkbox-button.style.js +55 -0
- package/src/components/form/td-checkbox-group/td-checkbox-group.class.d.ts +2 -2
- package/src/components/form/td-checkbox-group/td-checkbox-group.class.js +10 -10
- package/src/components/form/td-checkbox-group/td-checkbox-group.interface.d.ts +1 -1
- package/src/components/form/td-color-picker/td-color-picker.class.d.ts +0 -0
- package/src/components/form/td-color-picker/td-color-picker.class.js +1 -0
- package/src/components/form/td-color-picker/td-color-picker.interface.d.ts +0 -0
- package/src/components/form/td-color-picker/td-color-picker.interface.js +1 -0
- package/src/components/form/td-date-picker/td-date-picker.class.d.ts +0 -0
- package/src/components/form/td-date-picker/td-date-picker.class.js +1 -0
- package/src/components/form/td-date-picker/td-date-picker.interface.d.ts +0 -0
- package/src/components/form/td-date-picker/td-date-picker.interface.js +1 -0
- package/src/components/form/td-date-time-picker/td-date-time-picker.class.d.ts +0 -0
- package/src/components/form/td-date-time-picker/td-date-time-picker.class.js +1 -0
- package/src/components/form/td-date-time-picker/td-date-time-picker.interface.d.ts +0 -0
- package/src/components/form/td-date-time-picker/td-date-time-picker.interface.js +1 -0
- package/src/components/form/td-form/hooks/use-form-item.d.ts +5 -0
- package/src/components/form/td-form/hooks/use-form-item.js +65 -0
- package/src/components/form/td-form/td-form.class.d.ts +3 -8
- package/src/components/form/td-form/td-form.class.js +10 -34
- package/src/components/form/td-form/td-form.const.d.ts +5 -0
- package/src/components/form/td-form/td-form.const.js +5 -0
- package/src/components/form/td-form/td-form.interface.js +33 -0
- package/src/components/form/td-form-item/td-form-item.class.d.ts +7 -4
- package/src/components/form/td-form-item/td-form-item.class.js +83 -60
- package/src/components/form/td-form-item/td-form-item.interface.d.ts +1 -3
- package/src/components/form/td-form-item/td-form-item.style.js +15 -15
- package/src/components/form/td-input/td-input-field.class.d.ts +1 -1
- package/src/components/form/td-input/td-input-field.class.js +13 -13
- package/src/components/form/td-input/td-input-field.interface.d.ts +2 -2
- package/src/components/form/td-input/td-input.class.d.ts +4 -3
- package/src/components/form/td-input/td-input.class.js +83 -49
- package/src/components/form/td-input/td-input.interface.d.ts +13 -0
- package/src/components/form/td-input/widget/prefix.js +2 -2
- package/src/components/form/td-input/widget/suffix.d.ts +1 -1
- package/src/components/form/td-input/widget/suffix.js +10 -10
- package/src/components/form/td-input/widget/td-input-wrapper.class.d.ts +3 -3
- package/src/components/form/td-input/widget/td-input-wrapper.class.js +64 -67
- package/src/components/form/td-input/widget/td-textarea-wrapper.d.ts +2 -2
- package/src/components/form/td-input/widget/td-textarea-wrapper.js +8 -9
- package/src/components/form/td-input-number/td-input-number.class.d.ts +0 -0
- package/src/components/form/td-input-number/td-input-number.class.js +1 -0
- package/src/components/form/td-input-number/td-input-number.interface.d.ts +0 -0
- package/src/components/form/td-input-number/td-input-number.interface.js +1 -0
- package/src/components/form/td-option/td-option.class.d.ts +7 -0
- package/src/components/form/{td-select/option/option.class.js → td-option/td-option.class.js} +9 -10
- package/src/components/form/{td-select/option/option.interface.d.ts → td-option/td-option.interface.d.ts} +1 -1
- package/src/components/form/td-option/td-option.interface.js +2 -0
- package/src/components/form/td-option-group/td-option-group.class.d.ts +7 -0
- package/src/components/form/{td-select/option-group/option-group.class.js → td-option-group/td-option-group.class.js} +11 -11
- package/src/components/form/{td-select/option-group/option-group.interface.d.ts → td-option-group/td-option-group.interface.d.ts} +1 -1
- package/src/components/form/td-option-group/td-option-group.interface.js +2 -0
- package/src/components/form/td-radio/td-radio.class.d.ts +3 -3
- package/src/components/form/td-radio/td-radio.class.js +58 -55
- package/src/components/form/td-radio-button/td-radio-button.class.d.ts +3 -3
- package/src/components/form/td-radio-button/td-radio-button.class.js +47 -45
- package/src/components/form/td-radio-group/td-radio-group.class.d.ts +3 -3
- package/src/components/form/td-radio-group/td-radio-group.class.js +21 -19
- package/src/components/form/td-rate/td-rate.class.d.ts +0 -0
- package/src/components/form/td-rate/td-rate.class.js +1 -0
- package/src/components/form/td-rate/td-rate.interface.d.ts +0 -0
- package/src/components/form/td-rate/td-rate.interface.js +1 -0
- package/src/components/form/td-select/dropdown/dropdown.class.d.ts +3 -2
- package/src/components/form/td-select/dropdown/dropdown.class.js +15 -15
- package/src/components/form/td-select/td-select.class.d.ts +3 -1
- package/src/components/form/td-select/td-select.class.js +6 -6
- package/src/components/form/td-select/td-select.style.js +8 -8
- package/src/components/form/td-slider/td-slider.class.d.ts +0 -0
- package/src/components/form/td-slider/td-slider.class.js +1 -0
- package/src/components/form/td-slider/td-slider.interface.d.ts +0 -0
- package/src/components/form/td-slider/td-slider.interface.js +1 -0
- package/src/components/form/td-switch/td-switch.class.d.ts +8 -4
- package/src/components/form/td-switch/td-switch.class.js +92 -63
- package/src/components/form/td-switch/td-switch.interface.d.ts +7 -1
- package/src/components/form/td-switch/td-switch.interface.js +1 -0
- package/src/components/form/td-switch/td-switch.style.d.ts +1 -2
- package/src/components/form/td-switch/td-switch.style.js +1 -2
- package/src/components/form/td-switch/widget/td-switch-core.d.ts +2 -2
- package/src/components/form/td-switch/widget/td-switch-core.js +73 -71
- package/src/components/form/td-switch/widget/td-switch-left.d.ts +2 -2
- package/src/components/form/td-switch/widget/td-switch-left.js +8 -8
- package/src/components/form/td-switch/widget/td-switch-right.d.ts +3 -3
- package/src/components/form/td-switch/widget/td-switch-right.js +9 -9
- package/src/components/form/td-time-picker/td-time-picker.class.d.ts +0 -0
- package/src/components/form/td-time-picker/td-time-picker.class.js +1 -0
- package/src/components/form/td-time-picker/td-time-picker.interface.d.ts +0 -0
- package/src/components/form/td-time-picker/td-time-picker.interface.js +1 -0
- package/src/components/form/td-time-select/td-time-select.class.d.ts +0 -0
- package/src/components/form/td-time-select/td-time-select.class.js +1 -0
- package/src/components/form/td-time-select/td-time-select.interface.d.ts +0 -0
- package/src/components/form/td-time-select/td-time-select.interface.js +1 -0
- package/src/components/form/td-transfer/td-transfer.class.d.ts +0 -0
- package/src/components/form/td-transfer/td-transfer.class.js +1 -0
- package/src/components/form/td-transfer/td-transfer.interface.d.ts +0 -0
- package/src/components/form/td-transfer/td-transfer.interface.js +1 -0
- package/src/components/form/td-upload/td-upload.class.d.ts +0 -0
- package/src/components/form/td-upload/td-upload.class.js +1 -0
- package/src/components/form/td-upload/td-upload.interface.d.ts +0 -0
- package/src/components/form/td-upload/td-upload.interface.js +1 -0
- package/src/components/navigation/index.d.ts +16 -0
- package/src/components/navigation/index.js +17 -1
- package/src/components/navigation/td-affix/td-affix.class.d.ts +25 -0
- package/src/components/navigation/td-affix/td-affix.class.js +134 -0
- package/src/components/navigation/td-affix/td-affix.interface.d.ts +27 -0
- package/src/components/navigation/td-affix/td-affix.interface.js +2 -0
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.class.d.ts +8 -0
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.class.js +30 -0
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.interface.d.ts +16 -0
- package/src/components/navigation/td-anchor/td-anchor-link/td-anchor-link.interface.js +2 -0
- package/src/components/navigation/td-anchor/td-anchor.class.d.ts +10 -0
- package/src/components/navigation/td-anchor/td-anchor.class.js +118 -0
- package/src/components/navigation/td-anchor/td-anchor.function.d.ts +2 -0
- package/src/components/navigation/td-anchor/td-anchor.function.js +91 -0
- package/src/components/navigation/td-anchor/td-anchor.interface.d.ts +44 -0
- package/src/components/navigation/td-anchor/td-anchor.interface.js +2 -0
- package/src/components/navigation/td-anchor/td-anchor.style.d.ts +14 -0
- package/src/components/navigation/td-anchor/td-anchor.style.js +17 -0
- package/src/components/navigation/td-backtop/td-backtop.class.d.ts +17 -0
- package/src/components/navigation/td-backtop/td-backtop.class.js +145 -0
- package/src/components/navigation/td-backtop/td-backtop.interface.d.ts +26 -0
- package/src/components/navigation/td-backtop/td-backtop.interface.js +2 -0
- package/src/components/navigation/td-backtop/td-backtop.style.d.ts +5 -0
- package/src/components/navigation/td-backtop/td-backtop.style.js +13 -0
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.class.d.ts +11 -0
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.class.js +37 -0
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.interface.d.ts +16 -0
- package/src/components/navigation/td-breadcrumb/td-breadcrumb.interface.js +2 -0
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.class.d.ts +8 -0
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.class.js +71 -0
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.interface.d.ts +18 -0
- package/src/components/navigation/td-breadcrumb-item/td-breadcrumb-item.interface.js +2 -0
- package/src/components/navigation/td-dropdown/td-dropdown.class.d.ts +0 -0
- package/src/components/navigation/td-dropdown/td-dropdown.class.js +1 -0
- package/src/components/navigation/td-dropdown/td-dropdown.interface.d.ts +0 -0
- package/src/components/navigation/td-dropdown/td-dropdown.interface.js +1 -0
- package/src/components/navigation/td-menu/td-menu.class.d.ts +3 -2
- package/src/components/navigation/td-menu/td-menu.class.js +11 -10
- package/src/components/navigation/td-page-header/td-page-header.class.d.ts +0 -0
- package/src/components/navigation/td-page-header/td-page-header.class.js +1 -0
- package/src/components/navigation/td-page-header/td-page-header.interface.d.ts +0 -0
- package/src/components/navigation/td-page-header/td-page-header.interface.js +1 -0
- package/src/components/navigation/td-steps/td-steps.class.d.ts +0 -0
- package/src/components/navigation/td-steps/td-steps.class.js +1 -0
- package/src/components/navigation/td-steps/td-steps.interface.d.ts +0 -0
- package/src/components/navigation/td-steps/td-steps.interface.js +1 -0
- package/src/components/navigation/td-tabs/td-tab-bar.class.d.ts +12 -0
- package/src/components/navigation/td-tabs/td-tab-bar.class.js +62 -0
- package/src/components/navigation/td-tabs/td-tab-bar.interface.d.ts +10 -0
- package/src/components/navigation/td-tabs/td-tab-bar.interface.js +2 -0
- package/src/components/navigation/td-tabs/td-tab-nav.class.d.ts +31 -0
- package/src/components/navigation/td-tabs/td-tab-nav.class.js +355 -0
- package/src/components/navigation/td-tabs/td-tab-nav.interface.d.ts +23 -0
- package/src/components/navigation/td-tabs/td-tab-nav.interface.js +2 -0
- package/src/components/navigation/td-tabs/td-tab-pane.class.d.ts +13 -0
- package/src/components/navigation/td-tabs/td-tab-pane.class.js +41 -0
- package/src/components/navigation/td-tabs/td-tab-pane.interface.d.ts +31 -0
- package/src/components/navigation/td-tabs/td-tab-pane.interface.js +2 -0
- package/src/components/navigation/td-tabs/td-tabs.class.d.ts +18 -0
- package/src/components/navigation/td-tabs/td-tabs.class.js +159 -0
- package/src/components/navigation/td-tabs/td-tabs.interface.d.ts +74 -0
- package/src/components/navigation/td-tabs/td-tabs.interface.js +5 -0
- package/src/components/navigation/td-tabs/td-tabs.style.d.ts +19 -0
- package/src/components/navigation/td-tabs/td-tabs.style.js +128 -0
- package/src/components/others/collapsible-box/collapsible-box.d.ts +2 -3
- package/src/components/others/collapsible-box/collapsible-box.js +5 -7
- package/src/components/others/collapsible-box/contents/contents.d.ts +2 -2
- package/src/components/others/collapsible-box/contents/contents.js +6 -8
- package/src/components/others/collapsible-box/heading/expand-heading.d.ts +2 -3
- package/src/components/others/collapsible-box/heading/expand-heading.js +13 -15
- package/src/components/others/td-divider/td-divider.class.d.ts +2 -2
- package/src/components/others/td-divider/td-divider.class.js +16 -15
- package/src/components/others/td-watermark/td-watermark.class.d.ts +0 -0
- package/src/components/others/td-watermark/td-watermark.class.js +1 -0
- package/src/components/others/td-watermark/td-watermark.interface.d.ts +0 -0
- package/src/components/others/td-watermark/td-watermark.interface.js +1 -0
- package/src/constants/event.d.ts +3 -0
- package/src/constants/event.js +6 -0
- package/src/index.d.ts +2 -0
- package/src/index.js +2 -0
- package/src/styles/color-scheme.js +19 -19
- package/src/styles/function.js +3 -3
- package/src/styles/index.d.ts +1 -0
- package/src/styles/size.d.ts +0 -5
- package/src/styles/size.js +3 -3
- package/src/styles/transition.d.ts +32 -0
- package/src/styles/transition.js +222 -0
- package/src/styles/var.d.ts +10 -1
- package/src/styles/var.js +16 -2
- package/src/ui/ui.abstract.d.ts +16 -6
- package/src/ui/ui.abstract.js +39 -11
- package/src/ui/ui.interface.d.ts +7 -3
- package/src/utils/types.d.ts +8 -0
- package/src/utils/types.js +35 -0
- package/src/components/basic/td-layout/td-row/td-row.style.d.ts +0 -1
- package/src/components/basic/td-layout/td-row/td-row.style.js +0 -8
- package/src/components/form/td-select/option/option.class.d.ts +0 -6
- package/src/components/form/td-select/option-group/option-group.class.d.ts +0 -6
- /package/src/components/{form/td-select/option-group/option-group.interface.js → data/td-avatar/td-avatar.interface.js} +0 -0
- /package/src/components/{form/td-select/option/option.interface.js → data/td-badge/td-badge.interface.js} +0 -0
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.collapseTransitionConfig = void 0;
|
|
4
|
+
const reset = (element) => {
|
|
5
|
+
const el = element === null || element === void 0 ? void 0 : element.dom;
|
|
6
|
+
if (!el) {
|
|
7
|
+
throw Error('element is not exist . ');
|
|
8
|
+
}
|
|
9
|
+
// el.style.maxHeight = '';
|
|
10
|
+
// el.style.overflow = el.dataset.oldOverflow
|
|
11
|
+
// el.style.paddingTop = el.dataset.oldPaddingTop
|
|
12
|
+
// el.style.paddingBottom = el.dataset.oldPaddingBottom
|
|
13
|
+
element === null || element === void 0 ? void 0 : element.ctrl.setStyleObj({
|
|
14
|
+
maxHeight: '',
|
|
15
|
+
overflow: el.dataset.oldOverflow,
|
|
16
|
+
paddingTop: el.dataset.oldPaddingTop,
|
|
17
|
+
paddingBottom: el.dataset.oldPaddingBottom
|
|
18
|
+
});
|
|
19
|
+
};
|
|
20
|
+
exports.collapseTransitionConfig = {
|
|
21
|
+
onBeforeEnter(element) {
|
|
22
|
+
console.log('beforeEnter . ');
|
|
23
|
+
const el = element === null || element === void 0 ? void 0 : element.dom;
|
|
24
|
+
if (!el) {
|
|
25
|
+
throw Error('element is not exist . ');
|
|
26
|
+
}
|
|
27
|
+
if (!el.dataset) {
|
|
28
|
+
// el.dataset = {};
|
|
29
|
+
element.ctrl.setAttribute('dataset', false);
|
|
30
|
+
}
|
|
31
|
+
element.ctrl.setAttrObj({
|
|
32
|
+
dataOldPaddingTop: el.style.paddingTop,
|
|
33
|
+
dataOldPaddingBottom: el.style.paddingBottom
|
|
34
|
+
});
|
|
35
|
+
// el.dataset.oldPaddingTop = el.style.paddingTop
|
|
36
|
+
// el.dataset.oldPaddingBottom = el.style.paddingBottom
|
|
37
|
+
if (el.style.height) {
|
|
38
|
+
// el.dataset.existsHeight = el.style.height
|
|
39
|
+
element.ctrl.setAttrObj({
|
|
40
|
+
dataExistsHeight: el.style.height
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
// el.style.maxHeight = 0
|
|
44
|
+
// el.style.paddingTop = 0
|
|
45
|
+
// el.style.paddingBottom = 0
|
|
46
|
+
element.ctrl.setStyleObj({
|
|
47
|
+
maxHeight: 0,
|
|
48
|
+
paddingTop: 0,
|
|
49
|
+
paddingBottom: 0,
|
|
50
|
+
transition: 'max-height .3s ease-in-out'
|
|
51
|
+
});
|
|
52
|
+
},
|
|
53
|
+
onEnter(element) {
|
|
54
|
+
console.log('enter . ');
|
|
55
|
+
const el = element === null || element === void 0 ? void 0 : element.dom;
|
|
56
|
+
if (!el) {
|
|
57
|
+
throw Error('element is not exist . ');
|
|
58
|
+
}
|
|
59
|
+
requestAnimationFrame(() => {
|
|
60
|
+
element.ctrl.setAttrObj({
|
|
61
|
+
dataOldOverflow: el.style.overflow
|
|
62
|
+
});
|
|
63
|
+
// el.dataset.oldOverflow = el.style.overflow
|
|
64
|
+
if (el.dataset.existsHeight) {
|
|
65
|
+
// el.style.maxHeight = el.dataset.existsHeight
|
|
66
|
+
element.ctrl.setStyleObj({
|
|
67
|
+
maxHeight: el.dataset.existsHeight
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
else if (el.scrollHeight !== 0) {
|
|
71
|
+
// el.style.maxHeight = `${el.scrollHeight}px`
|
|
72
|
+
element.ctrl.setStyleObj({
|
|
73
|
+
maxHeight: `${el.scrollHeight}px`
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
else {
|
|
77
|
+
// el.style.maxHeight = 0
|
|
78
|
+
element.ctrl.setStyleObj({
|
|
79
|
+
maxHeight: 0
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
// el.style.paddingTop = el.dataset.oldPaddingTop
|
|
83
|
+
// el.style.paddingBottom = el.dataset.oldPaddingBottom
|
|
84
|
+
// el.style.overflow = 'hidden'
|
|
85
|
+
element.ctrl.setStyleObj({
|
|
86
|
+
paddingTop: el.dataset.oldPaddingTop,
|
|
87
|
+
paddingBottom: el.dataset.oldPaddingBottom,
|
|
88
|
+
overflow: 'hidden'
|
|
89
|
+
});
|
|
90
|
+
});
|
|
91
|
+
},
|
|
92
|
+
onAfterEnter(element) {
|
|
93
|
+
var _a;
|
|
94
|
+
// el.style.maxHeight = ''
|
|
95
|
+
// el.style.overflow = el.dataset.oldOverflow
|
|
96
|
+
element === null || element === void 0 ? void 0 : element.ctrl.setStyleObj({
|
|
97
|
+
maxHeight: '',
|
|
98
|
+
overflow: (_a = element === null || element === void 0 ? void 0 : element.dom) === null || _a === void 0 ? void 0 : _a.dataset.oldOverflow
|
|
99
|
+
});
|
|
100
|
+
},
|
|
101
|
+
onEnterCancelled(element) {
|
|
102
|
+
reset(element);
|
|
103
|
+
},
|
|
104
|
+
onBeforeLeave(element) {
|
|
105
|
+
const el = element === null || element === void 0 ? void 0 : element.dom;
|
|
106
|
+
if (!el) {
|
|
107
|
+
throw Error('element is not exist . ');
|
|
108
|
+
}
|
|
109
|
+
// if (!el.dataset) el.dataset = {}
|
|
110
|
+
// el.dataset.oldPaddingTop = el.style.paddingTop
|
|
111
|
+
// el.dataset.oldPaddingBottom = el.style.paddingBottom
|
|
112
|
+
// el.dataset.oldOverflow = el.style.overflow
|
|
113
|
+
element.ctrl.setAttrObj({
|
|
114
|
+
dataOldPaddingTop: el.style.paddingTop,
|
|
115
|
+
dataOldPaddingBottom: el.style.paddingBottom,
|
|
116
|
+
dataOldOverflow: el.style.overflow
|
|
117
|
+
});
|
|
118
|
+
// el.style.maxHeight = `${el.scrollHeight}px`
|
|
119
|
+
// el.style.overflow = 'hidden'
|
|
120
|
+
element.ctrl.setStyleObj({
|
|
121
|
+
maxHeight: `${el.scrollHeight}px`,
|
|
122
|
+
overflow: 'hidden'
|
|
123
|
+
});
|
|
124
|
+
},
|
|
125
|
+
onLeave(element) {
|
|
126
|
+
const el = element === null || element === void 0 ? void 0 : element.dom;
|
|
127
|
+
if (!el) {
|
|
128
|
+
throw Error('element is not exist . ');
|
|
129
|
+
}
|
|
130
|
+
if (el.scrollHeight !== 0) {
|
|
131
|
+
// el.style.maxHeight = 0
|
|
132
|
+
// el.style.paddingTop = 0
|
|
133
|
+
// el.style.paddingBottom = 0
|
|
134
|
+
element.ctrl.setStyleObj({
|
|
135
|
+
maxHeight: 0,
|
|
136
|
+
paddingTop: 0,
|
|
137
|
+
paddingBottom: 0
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
onAfterLeave(element) {
|
|
142
|
+
reset(element);
|
|
143
|
+
},
|
|
144
|
+
onLeaveCancelled(element) {
|
|
145
|
+
reset(element);
|
|
146
|
+
}
|
|
147
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { TdStatisticAbstract } from '../td-statistic/td-statistic.abstract';
|
|
2
|
+
import { ITdCountDown, ITdCountDownConfig } from './td-count-down.interface';
|
|
3
|
+
export declare class TdCountDown extends TdStatisticAbstract implements ITdCountDown {
|
|
4
|
+
className: 'TdCountDown';
|
|
5
|
+
private rawValue;
|
|
6
|
+
private timer?;
|
|
7
|
+
props: ITdCountDownConfig;
|
|
8
|
+
constructor(params?: ITdCountDownConfig);
|
|
9
|
+
mounted(): void;
|
|
10
|
+
stopTimer(): void;
|
|
11
|
+
startTimer(): void;
|
|
12
|
+
setNumber(value: number): void;
|
|
13
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TdCountDown = void 0;
|
|
4
|
+
const utils_1 = require("@type-dom/utils");
|
|
5
|
+
const td_statistic_abstract_1 = require("../td-statistic/td-statistic.abstract");
|
|
6
|
+
const utils_2 = require("./utils");
|
|
7
|
+
class TdCountDown extends td_statistic_abstract_1.TdStatisticAbstract {
|
|
8
|
+
constructor(params = {}) {
|
|
9
|
+
const format = (params === null || params === void 0 ? void 0 : params.format) || 'HH:mm:ss';
|
|
10
|
+
params.formatter = (val) => (0, utils_2.formatTime)(val, format);
|
|
11
|
+
// title,prefix,suffix 可以是 TypeElement元素;
|
|
12
|
+
super(params);
|
|
13
|
+
this.className = 'TdCountDown';
|
|
14
|
+
this.rawValue = (0, utils_2.getTime)((params === null || params === void 0 ? void 0 : params.value) || 0) - Date.now();
|
|
15
|
+
this.setNumber(this.rawValue);
|
|
16
|
+
if (params === null || params === void 0 ? void 0 : params.slot) {
|
|
17
|
+
this.slotChild(params.slot);
|
|
18
|
+
}
|
|
19
|
+
this.props = this.setParams(params);
|
|
20
|
+
}
|
|
21
|
+
mounted() {
|
|
22
|
+
this.stopTimer();
|
|
23
|
+
this.startTimer();
|
|
24
|
+
}
|
|
25
|
+
stopTimer() {
|
|
26
|
+
if (this.timer) {
|
|
27
|
+
(0, utils_1.cAF)(this.timer);
|
|
28
|
+
this.timer = undefined;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
startTimer() {
|
|
32
|
+
var _a;
|
|
33
|
+
console.log('this.props.value is ', this.props.value);
|
|
34
|
+
const timestamp = (0, utils_2.getTime)(((_a = this.props) === null || _a === void 0 ? void 0 : _a.value) || 0);
|
|
35
|
+
const frameFunc = () => {
|
|
36
|
+
let diff = timestamp - Date.now();
|
|
37
|
+
// console.log('diff is ', diff);
|
|
38
|
+
// emit('change', diff)
|
|
39
|
+
this.setNumber(diff);
|
|
40
|
+
if (diff <= 0) {
|
|
41
|
+
diff = 0;
|
|
42
|
+
this.stopTimer();
|
|
43
|
+
// emit('finish')
|
|
44
|
+
}
|
|
45
|
+
else {
|
|
46
|
+
this.timer = (0, utils_1.rAF)(frameFunc);
|
|
47
|
+
}
|
|
48
|
+
this.rawValue = diff;
|
|
49
|
+
};
|
|
50
|
+
this.timer = (0, utils_1.rAF)(frameFunc);
|
|
51
|
+
}
|
|
52
|
+
setNumber(value) {
|
|
53
|
+
var _a;
|
|
54
|
+
(_a = this.number.textNode) === null || _a === void 0 ? void 0 : _a.setText(this.formatValue(value));
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
exports.TdCountDown = TdCountDown;
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ITdStatisticAbstract, ITdStatisticConfig } from '../td-statistic/td-statistic.interface';
|
|
2
|
+
export interface ITdCountDown extends ITdStatisticAbstract {
|
|
3
|
+
className: 'TdCountDown';
|
|
4
|
+
}
|
|
5
|
+
export interface ITdCountDownConfig extends ITdStatisticConfig {
|
|
6
|
+
/**
|
|
7
|
+
* @description Formatting the countdown display
|
|
8
|
+
* default: 'HH:mm:ss',
|
|
9
|
+
*/
|
|
10
|
+
format?: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.formatTime = exports.getTime = void 0;
|
|
4
|
+
const utils_1 = require("@type-dom/utils");
|
|
5
|
+
const timeUnits = [
|
|
6
|
+
['Y', 1000 * 60 * 60 * 24 * 365], // years
|
|
7
|
+
['M', 1000 * 60 * 60 * 24 * 30], // months
|
|
8
|
+
['D', 1000 * 60 * 60 * 24], // days
|
|
9
|
+
['H', 1000 * 60 * 60], // hours
|
|
10
|
+
['m', 1000 * 60], // minutes
|
|
11
|
+
['s', 1000], // seconds
|
|
12
|
+
['S', 1] // million seconds
|
|
13
|
+
];
|
|
14
|
+
const getTime = (value) => {
|
|
15
|
+
return (0, utils_1.isNumber)(value) ? new Date(value).getTime() : value.valueOf();
|
|
16
|
+
};
|
|
17
|
+
exports.getTime = getTime;
|
|
18
|
+
const formatTime = (timestamp, format) => {
|
|
19
|
+
let timeLeft = timestamp;
|
|
20
|
+
const escapeRegex = /\[([^\]]*)]/g;
|
|
21
|
+
const replacedText = timeUnits.reduce((current, [name, unit]) => {
|
|
22
|
+
const replaceRegex = new RegExp(`${name}+(?![^\\[\\]]*\\])`, 'g');
|
|
23
|
+
if (replaceRegex.test(current)) {
|
|
24
|
+
const value = Math.floor(timeLeft / unit);
|
|
25
|
+
timeLeft -= value * unit;
|
|
26
|
+
return current.replace(replaceRegex, (match) => String(value).padStart(match.length, '0'));
|
|
27
|
+
}
|
|
28
|
+
return current;
|
|
29
|
+
}, format);
|
|
30
|
+
return replacedText.replace(escapeRegex, '$1');
|
|
31
|
+
};
|
|
32
|
+
exports.formatTime = formatTime;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { TableRow, TypeFragment } from '@type-dom/framework';
|
|
2
|
+
import { IUI, IUIConfig } from '../../../ui/ui.interface';
|
|
3
|
+
import { TdDescriptionsItem } from '../td-descriptions-item/td-descriptions-item.class';
|
|
4
|
+
export interface ITdDescriptionsRow extends IUI {
|
|
5
|
+
className: 'TdDescriptionsRow';
|
|
6
|
+
}
|
|
7
|
+
export interface ITdDescriptionsRowConfig extends IUIConfig {
|
|
8
|
+
row: TdDescriptionsItem[];
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* @name TdDescriptionsRow
|
|
12
|
+
* @description
|
|
13
|
+
* @author darcrand
|
|
14
|
+
*/
|
|
15
|
+
export declare class TdDescriptionsRow extends TypeFragment implements ITdDescriptionsRow {
|
|
16
|
+
className: 'TdDescriptionsRow';
|
|
17
|
+
props: ITdDescriptionsRowConfig;
|
|
18
|
+
childNodes: TableRow[];
|
|
19
|
+
constructor(params?: ITdDescriptionsRowConfig);
|
|
20
|
+
created(): void;
|
|
21
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TdDescriptionsRow = void 0;
|
|
4
|
+
const framework_1 = require("@type-dom/framework");
|
|
5
|
+
const td_descritions_cell_1 = require("./td-descritions-cell");
|
|
6
|
+
/**
|
|
7
|
+
* @name TdDescriptionsRow
|
|
8
|
+
* @description
|
|
9
|
+
* @author darcrand
|
|
10
|
+
*/
|
|
11
|
+
class TdDescriptionsRow extends framework_1.TypeFragment {
|
|
12
|
+
constructor(params) {
|
|
13
|
+
super();
|
|
14
|
+
this.className = 'TdDescriptionsRow';
|
|
15
|
+
this.childNodes = [];
|
|
16
|
+
this.props = this.setParams(params);
|
|
17
|
+
}
|
|
18
|
+
created() {
|
|
19
|
+
var _a;
|
|
20
|
+
// todo descriptions.direction === 'vertical'
|
|
21
|
+
// descriptions.border 根据这两个条件判断,创建cell.
|
|
22
|
+
const descriptions = this.up('TdDescriptions');
|
|
23
|
+
console.log('descriptions is ', descriptions);
|
|
24
|
+
if (!descriptions) {
|
|
25
|
+
throw Error('TdDescriptionsRow need TdDescriptions as parent. ');
|
|
26
|
+
}
|
|
27
|
+
const descriptionsConfig = descriptions.props;
|
|
28
|
+
// useSize(descriptionsConfig);
|
|
29
|
+
// useBordered(descriptionsConfig);
|
|
30
|
+
if ((descriptionsConfig === null || descriptionsConfig === void 0 ? void 0 : descriptionsConfig.direction) === 'vertical') {
|
|
31
|
+
// todo 要加 两个 tr , 这样就不是 一个 tr 的组件了。
|
|
32
|
+
console.log('vertical . ');
|
|
33
|
+
const labelTr = new framework_1.TableRow();
|
|
34
|
+
const contentTr = new framework_1.TableRow();
|
|
35
|
+
const row = ((_a = this.props) === null || _a === void 0 ? void 0 : _a.row) || [];
|
|
36
|
+
row.forEach((item, index) => {
|
|
37
|
+
labelTr.addChild(new td_descritions_cell_1.TdDescriptionsCell({
|
|
38
|
+
cell: item.props,
|
|
39
|
+
tag: 'th',
|
|
40
|
+
type: 'label'
|
|
41
|
+
}));
|
|
42
|
+
});
|
|
43
|
+
row.forEach((item, index) => {
|
|
44
|
+
contentTr.addChild(new td_descritions_cell_1.TdDescriptionsCell({
|
|
45
|
+
cell: item.props,
|
|
46
|
+
tag: 'td',
|
|
47
|
+
type: 'content'
|
|
48
|
+
}));
|
|
49
|
+
});
|
|
50
|
+
this.addChildren(labelTr, contentTr);
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
const tr = new framework_1.TableRow();
|
|
54
|
+
const row = this.props.row || [];
|
|
55
|
+
row.forEach((item, index) => {
|
|
56
|
+
if (descriptionsConfig.border) {
|
|
57
|
+
tr.addChildren(new td_descritions_cell_1.TdDescriptionsCell({
|
|
58
|
+
cell: item.props,
|
|
59
|
+
tag: 'td',
|
|
60
|
+
type: 'label'
|
|
61
|
+
}), new td_descritions_cell_1.TdDescriptionsCell({
|
|
62
|
+
cell: item.props,
|
|
63
|
+
tag: 'td',
|
|
64
|
+
type: 'content'
|
|
65
|
+
}));
|
|
66
|
+
}
|
|
67
|
+
else {
|
|
68
|
+
tr.addChild(new td_descritions_cell_1.TdDescriptionsCell({
|
|
69
|
+
cell: item.props,
|
|
70
|
+
tag: 'td',
|
|
71
|
+
type: 'both'
|
|
72
|
+
}));
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
this.addChild(tr);
|
|
76
|
+
}
|
|
77
|
+
// this.setParams(this.config);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
exports.TdDescriptionsRow = TdDescriptionsRow;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { UI } from '../../../ui/ui.abstract';
|
|
2
|
+
import { ISize } from '../../../styles/size';
|
|
3
|
+
import { TdDescriptionsItem } from '../td-descriptions-item/td-descriptions-item.class';
|
|
4
|
+
import { ITdDescriptions, ITdDescriptionsConfig } from './td-descriptions.interface';
|
|
5
|
+
export declare class TdDescriptions extends UI implements ITdDescriptions {
|
|
6
|
+
className: 'TdDescriptions';
|
|
7
|
+
private header?;
|
|
8
|
+
private body?;
|
|
9
|
+
private rows?;
|
|
10
|
+
private headerTitle?;
|
|
11
|
+
private bodyTable?;
|
|
12
|
+
props: ITdDescriptionsConfig;
|
|
13
|
+
constructor(params: ITdDescriptionsConfig);
|
|
14
|
+
created(): void;
|
|
15
|
+
filledNode(node: TdDescriptionsItem, span: number, count: number, isLast?: boolean): TdDescriptionsItem;
|
|
16
|
+
getRows(): TdDescriptionsItem[][];
|
|
17
|
+
setSize(size: ISize): void;
|
|
18
|
+
}
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TdDescriptions = void 0;
|
|
4
|
+
const framework_1 = require("@type-dom/framework");
|
|
5
|
+
const ui_abstract_1 = require("../../../ui/ui.abstract");
|
|
6
|
+
const td_descriptions_item_class_1 = require("../td-descriptions-item/td-descriptions-item.class");
|
|
7
|
+
const td_descriptions_row_1 = require("./td-descriptions-row");
|
|
8
|
+
const td_descriptions_style_1 = require("./td-descriptions.style");
|
|
9
|
+
class TdDescriptions extends ui_abstract_1.UI {
|
|
10
|
+
constructor(params) {
|
|
11
|
+
super(params);
|
|
12
|
+
this.className = 'TdDescriptions';
|
|
13
|
+
this.props = this.setParams(params);
|
|
14
|
+
}
|
|
15
|
+
created() {
|
|
16
|
+
var _a, _b, _c, _d;
|
|
17
|
+
const props = this.props;
|
|
18
|
+
(0, td_descriptions_style_1.useSize)(props);
|
|
19
|
+
(0, td_descriptions_style_1.useBordered)(props);
|
|
20
|
+
if ((props === null || props === void 0 ? void 0 : props.title) ||
|
|
21
|
+
(props === null || props === void 0 ? void 0 : props.extra) ||
|
|
22
|
+
((_a = props === null || props === void 0 ? void 0 : props.slots) === null || _a === void 0 ? void 0 : _a.title) ||
|
|
23
|
+
((_b = props === null || props === void 0 ? void 0 : props.slots) === null || _b === void 0 ? void 0 : _b.extra)) {
|
|
24
|
+
this.header = new framework_1.Div({
|
|
25
|
+
name: 'header',
|
|
26
|
+
styleObj: td_descriptions_style_1.$descriptionsHeaderStyle,
|
|
27
|
+
});
|
|
28
|
+
this.addChild(this.header);
|
|
29
|
+
this.headerTitle = new framework_1.Div({
|
|
30
|
+
name: 'title',
|
|
31
|
+
styleObj: td_descriptions_style_1.$descriptionsHeaderTitleStyle,
|
|
32
|
+
});
|
|
33
|
+
if ((_c = props === null || props === void 0 ? void 0 : props.slots) === null || _c === void 0 ? void 0 : _c.title) {
|
|
34
|
+
this.headerTitle = new framework_1.Div({
|
|
35
|
+
name: 'title',
|
|
36
|
+
styleObj: td_descriptions_style_1.$descriptionsHeaderTitleStyle,
|
|
37
|
+
childNodes: [props.slots.title],
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
this.headerTitle = new framework_1.Div({
|
|
42
|
+
name: 'title',
|
|
43
|
+
text: props.title,
|
|
44
|
+
styleObj: td_descriptions_style_1.$descriptionsHeaderTitleStyle,
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
this.header.addChild(this.headerTitle);
|
|
48
|
+
if ((_d = props === null || props === void 0 ? void 0 : props.slots) === null || _d === void 0 ? void 0 : _d.extra) {
|
|
49
|
+
this.header.addChild(new framework_1.Div({
|
|
50
|
+
name: 'extra',
|
|
51
|
+
childNodes: [props.slots.extra],
|
|
52
|
+
}));
|
|
53
|
+
}
|
|
54
|
+
else {
|
|
55
|
+
this.header.addChild(new framework_1.Div({
|
|
56
|
+
name: 'extra',
|
|
57
|
+
text: props.extra,
|
|
58
|
+
}));
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
if (!(props === null || props === void 0 ? void 0 : props.slot)) {
|
|
62
|
+
throw Error('slot is required . ');
|
|
63
|
+
}
|
|
64
|
+
const items = this.getRows();
|
|
65
|
+
console.log('items is ', items);
|
|
66
|
+
const rows = [];
|
|
67
|
+
for (const item of items) {
|
|
68
|
+
rows.push(new td_descriptions_row_1.TdDescriptionsRow({ row: item }));
|
|
69
|
+
}
|
|
70
|
+
console.log('rows is ', rows);
|
|
71
|
+
this.rows = rows;
|
|
72
|
+
this.body = new framework_1.Div({
|
|
73
|
+
name: 'body',
|
|
74
|
+
styleObj: td_descriptions_style_1.$descriptionsBodyStyle,
|
|
75
|
+
});
|
|
76
|
+
this.bodyTable = new framework_1.Table({
|
|
77
|
+
name: 'table',
|
|
78
|
+
styleObj: td_descriptions_style_1.$descriptionsBodyTableStyle,
|
|
79
|
+
childNodes: [
|
|
80
|
+
new framework_1.TableBody({
|
|
81
|
+
name: 'table-body',
|
|
82
|
+
childNodes: rows,
|
|
83
|
+
}),
|
|
84
|
+
],
|
|
85
|
+
});
|
|
86
|
+
this.body.addChild(this.bodyTable);
|
|
87
|
+
this.addChild(this.body);
|
|
88
|
+
this.setParams(props); // todo ????
|
|
89
|
+
}
|
|
90
|
+
filledNode(node, span, count, isLast = false) {
|
|
91
|
+
if (!node.props) {
|
|
92
|
+
node.props = {};
|
|
93
|
+
}
|
|
94
|
+
if (span > count) {
|
|
95
|
+
node.props.span = count;
|
|
96
|
+
}
|
|
97
|
+
if (isLast) {
|
|
98
|
+
// set the last span
|
|
99
|
+
node.props.span = span;
|
|
100
|
+
}
|
|
101
|
+
return node;
|
|
102
|
+
}
|
|
103
|
+
getRows() {
|
|
104
|
+
const props = this.props;
|
|
105
|
+
const children = props.slot.filter((item) => item instanceof td_descriptions_item_class_1.TdDescriptionsItem);
|
|
106
|
+
const rows = [];
|
|
107
|
+
let temp = [];
|
|
108
|
+
let count = props.column || 3;
|
|
109
|
+
let totalSpan = 0; // all spans number of item
|
|
110
|
+
children.forEach((child, index) => {
|
|
111
|
+
const span = child.props.span || 1;
|
|
112
|
+
if (index < children.length - 1) {
|
|
113
|
+
totalSpan += span > count ? count : span;
|
|
114
|
+
}
|
|
115
|
+
if (index === children.length - 1) {
|
|
116
|
+
// calculate the last item span
|
|
117
|
+
const lastSpan = (props.column || 3) - (totalSpan % (props.column || 3));
|
|
118
|
+
// const lastSpan = count - (totalSpan % count)
|
|
119
|
+
temp.push(this.filledNode(child, lastSpan, count, true));
|
|
120
|
+
rows.push(temp);
|
|
121
|
+
return;
|
|
122
|
+
}
|
|
123
|
+
if (span < count) {
|
|
124
|
+
count -= span;
|
|
125
|
+
temp.push(child);
|
|
126
|
+
}
|
|
127
|
+
else {
|
|
128
|
+
temp.push(this.filledNode(child, span, count));
|
|
129
|
+
rows.push(temp);
|
|
130
|
+
count = props.column || 3;
|
|
131
|
+
temp = [];
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
console.log('rows is ', rows);
|
|
135
|
+
return rows;
|
|
136
|
+
}
|
|
137
|
+
setSize(size) {
|
|
138
|
+
var _a, _b, _c, _d, _e;
|
|
139
|
+
this.props.size = size;
|
|
140
|
+
(0, td_descriptions_style_1.useSize)(this.props);
|
|
141
|
+
(0, td_descriptions_style_1.useBordered)(this.props);
|
|
142
|
+
this.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsStyle);
|
|
143
|
+
(_a = this.header) === null || _a === void 0 ? void 0 : _a.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsHeaderStyle);
|
|
144
|
+
(_b = this.headerTitle) === null || _b === void 0 ? void 0 : _b.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsHeaderTitleStyle);
|
|
145
|
+
(_c = this.body) === null || _c === void 0 ? void 0 : _c.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyStyle);
|
|
146
|
+
(_d = this.bodyTable) === null || _d === void 0 ? void 0 : _d.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyTableStyle);
|
|
147
|
+
(_e = this.rows) === null || _e === void 0 ? void 0 : _e.forEach((row) => {
|
|
148
|
+
row.childNodes.forEach((tr) => {
|
|
149
|
+
tr.childNodes.forEach((td) => {
|
|
150
|
+
td.ctrl.setStyleObj(td_descriptions_style_1.$descriptionsBodyTableCellStyle);
|
|
151
|
+
});
|
|
152
|
+
});
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
exports.TdDescriptions = TdDescriptions;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { TypeElement } from '@type-dom/framework';
|
|
2
|
+
import { IUI, IUIConfig } from '../../../ui/ui.interface';
|
|
3
|
+
import { ISize } from '../../../styles/size';
|
|
4
|
+
import { TdDescriptionsItem } from '../td-descriptions-item/td-descriptions-item.class';
|
|
5
|
+
export interface ITdDescriptions extends IUI {
|
|
6
|
+
className: 'TdDescriptions';
|
|
7
|
+
}
|
|
8
|
+
export interface ITdDescriptionsConfig extends IUIConfig {
|
|
9
|
+
/**
|
|
10
|
+
* @description with or without border
|
|
11
|
+
* default: false,
|
|
12
|
+
*/
|
|
13
|
+
border?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* @description numbers of `Descriptions Item` in one line
|
|
16
|
+
* default: 3,
|
|
17
|
+
*/
|
|
18
|
+
column?: number;
|
|
19
|
+
/**
|
|
20
|
+
* @description direction of list
|
|
21
|
+
* default: 'horizontal',
|
|
22
|
+
*/
|
|
23
|
+
direction?: 'horizontal' | 'vertical';
|
|
24
|
+
/**
|
|
25
|
+
* @description size of list
|
|
26
|
+
*/
|
|
27
|
+
size?: ISize;
|
|
28
|
+
/**
|
|
29
|
+
* @description title text, display on the top left
|
|
30
|
+
* default: '',
|
|
31
|
+
*/
|
|
32
|
+
title?: string;
|
|
33
|
+
/**
|
|
34
|
+
* @description extra text, display on the top right
|
|
35
|
+
* default: '',
|
|
36
|
+
*/
|
|
37
|
+
extra?: string;
|
|
38
|
+
slots?: {
|
|
39
|
+
title?: TypeElement;
|
|
40
|
+
extra?: TypeElement;
|
|
41
|
+
};
|
|
42
|
+
slot: TdDescriptionsItem[];
|
|
43
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { IStyle } from '@type-dom/css-type';
|
|
2
|
+
import { ITdDescriptionsConfig } from './td-descriptions.interface';
|
|
3
|
+
export declare const $descriptionsHeaderMarginBottom: {
|
|
4
|
+
large: string;
|
|
5
|
+
default: string;
|
|
6
|
+
small: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const $descriptionsTitleFontSize: {
|
|
9
|
+
large: string;
|
|
10
|
+
default: string;
|
|
11
|
+
small: string;
|
|
12
|
+
};
|
|
13
|
+
export declare const $descriptionsCellPaddingBottom: {
|
|
14
|
+
large: string;
|
|
15
|
+
default: string;
|
|
16
|
+
small: string;
|
|
17
|
+
};
|
|
18
|
+
export declare const $descriptionsBorderedCellPadding: {
|
|
19
|
+
large: string;
|
|
20
|
+
default: string;
|
|
21
|
+
small: string;
|
|
22
|
+
};
|
|
23
|
+
export declare const $descriptionsCellFontSize: {
|
|
24
|
+
large: string;
|
|
25
|
+
default: string;
|
|
26
|
+
small: string;
|
|
27
|
+
};
|
|
28
|
+
export declare const $descriptions: {
|
|
29
|
+
tableBorder: string;
|
|
30
|
+
itemBorderedLabelBackground: string;
|
|
31
|
+
};
|
|
32
|
+
export declare const $descriptionsStyle: IStyle;
|
|
33
|
+
export declare const $descriptionsHeaderStyle: IStyle;
|
|
34
|
+
export declare const $descriptionsHeaderTitleStyle: IStyle;
|
|
35
|
+
export declare const $descriptionsBodyStyle: IStyle;
|
|
36
|
+
export declare const $descriptionsBodyTableStyle: IStyle;
|
|
37
|
+
export declare const $descriptionsBodyTableCellStyle: IStyle;
|
|
38
|
+
export declare const $descriptionsItemLabelMarginRight: {
|
|
39
|
+
large: string;
|
|
40
|
+
default: string;
|
|
41
|
+
small: string;
|
|
42
|
+
};
|
|
43
|
+
export declare function useSize(config?: ITdDescriptionsConfig): void;
|
|
44
|
+
export declare const $descriptionsItemVerticalLabelPaddingBottom: {
|
|
45
|
+
large: string;
|
|
46
|
+
default: string;
|
|
47
|
+
small: string;
|
|
48
|
+
};
|
|
49
|
+
export declare let $descriptionsCellLabelStyle: IStyle;
|
|
50
|
+
export declare const $descriptionsCellContentStyle: IStyle;
|
|
51
|
+
export declare function useBordered(config: ITdDescriptionsConfig): void;
|