easy-component-ui 2.0.5 → 2.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/LICENSE +21 -0
- package/README.md +90 -0
- package/build/components/Base.js +1 -0
- package/build/components/ea-alert/index.js +1 -0
- package/build/components/ea-alert/src/style/stylesheet.js +1 -0
- package/build/components/ea-aside/index.js +1 -0
- package/build/components/ea-avatar/index.js +1 -0
- package/build/components/ea-avatar/src/assets/defaultAvatar.js +1 -0
- package/build/components/ea-avatar/src/assets/errorAvatar.js +1 -0
- package/build/components/ea-avatar/src/assets/iconAndTextAvatar.js +1 -0
- package/build/components/ea-avatar/src/style/stylesheet.js +1 -0
- package/build/components/ea-backtop/index.js +1 -0
- package/build/components/ea-backtop/src/style/stylesheet.js +1 -0
- package/build/components/ea-badge/index.js +1 -0
- package/build/components/ea-badge/src/style/stylesheet.js +1 -0
- package/build/components/ea-breadcrumb/index.js +1 -0
- package/build/components/ea-breadcrumb/src/style/stylesheet.js +1 -0
- package/build/components/ea-breadcrumb-item/index.js +1 -0
- package/build/components/ea-breadcrumb-item/src/style/style.js +1 -0
- package/build/components/ea-button/index.js +1 -0
- package/build/components/ea-button/src/components/ButtonComm.js +1 -0
- package/build/components/ea-button/src/components/HrefComm.js +1 -0
- package/build/components/ea-button/src/style/stylesheet.js +1 -0
- package/build/components/ea-button-group/index.js +1 -0
- package/build/components/ea-button-group/src/style/stylesheet.js +1 -0
- package/build/components/ea-calendar/index.js +1 -0
- package/build/components/ea-calendar/src/style/stylesheet.js +1 -0
- package/build/components/ea-calendar/src/utils/createChangerElement.js +1 -0
- package/build/components/ea-calendar/src/utils/createThead.js +1 -0
- package/build/components/ea-calendar/src/utils/getDate.js +1 -0
- package/build/components/ea-calendar/src/utils/getUserWeekStart.js +1 -0
- package/build/components/ea-card/index.js +1 -0
- package/build/components/ea-card/src/style/stylesheet.js +1 -0
- package/build/components/ea-carousel/index.js +1 -0
- package/build/components/ea-carousel/src/style/stylesheet.js +1 -0
- package/build/components/ea-carousel/src/utils/handleIndexOverflow.js +1 -0
- package/build/components/ea-carousel-item/index.js +1 -0
- package/build/components/ea-carousel-item/src/style/stylesheet.js +1 -0
- package/build/components/ea-checkbox/index.js +1 -0
- package/build/components/ea-checkbox/src/style/stylesheet.js +1 -0
- package/build/components/ea-checkbox-group/index.js +1 -0
- package/build/components/ea-checkbox-group/src/style/stylesheet.js +1 -0
- package/build/components/ea-collapse/index.js +1 -0
- package/build/components/ea-collapse-item/index.js +1 -0
- package/build/components/ea-collapse-item/src/style/stylesheet.js +1 -0
- package/build/components/ea-container/index.js +1 -0
- package/build/components/ea-date-picker/index.js +1 -0
- package/build/components/ea-date-picker/src/style/stylesheet.js +1 -0
- package/build/components/ea-descriptions/index.js +1 -0
- package/build/components/ea-descriptions/src/components/contentTemplate.js +1 -0
- package/build/components/ea-descriptions/src/components/getTdTemplate_border.js +1 -0
- package/build/components/ea-descriptions/src/components/getTdTemplate_direction.js +1 -0
- package/build/components/ea-descriptions/src/components/getThTemplate_direction.js +1 -0
- package/build/components/ea-descriptions/src/components/getThTemplate_normal.js +1 -0
- package/build/components/ea-descriptions/src/style/stylesheet.js +1 -0
- package/build/components/ea-descriptions-item/index.js +1 -0
- package/build/components/ea-descriptions-item/src/stylesheet.js +1 -0
- package/build/components/ea-drawer/index.js +1 -0
- package/build/components/ea-drawer/src/style/stylesheet.js +1 -0
- package/build/components/ea-empty/index.js +1 -0
- package/build/components/ea-empty/src/assets/emptyStatusSVG.js +1 -0
- package/build/components/ea-empty/src/style/stylesheet.js +1 -0
- package/build/components/ea-footer/index.js +1 -0
- package/build/components/ea-form/index.js +1 -0
- package/build/components/ea-form-item/index.js +1 -0
- package/build/components/ea-form-item/src/style/stylesheet.js +1 -0
- package/build/components/ea-header/index.js +1 -0
- package/build/components/ea-icon/config.json +1030 -0
- package/{components/ea-icon/css/fontello-codes.css → build/components/ea-icon/css/fontello.css} +312 -123
- package/build/components/ea-icon/font/fontello.eot +0 -0
- package/build/components/ea-icon/font/fontello.svg +350 -0
- package/build/components/ea-icon/font/fontello.ttf +0 -0
- package/build/components/ea-icon/font/fontello.woff +0 -0
- package/build/components/ea-icon/font/fontello.woff2 +0 -0
- package/build/components/ea-icon/index.css +1 -0
- package/build/components/ea-icon/index.js +1 -0
- package/build/components/ea-image/index.js +1 -0
- package/build/components/ea-image/src/assets/errorImage.js +1 -0
- package/build/components/ea-image/src/style/stylesheet.js +1 -0
- package/build/components/ea-image/src/utils/createPreviewTools.js +1 -0
- package/build/components/ea-infinite-scroll/index.js +1 -0
- package/build/components/ea-infinite-scroll-item/index.js +1 -0
- package/build/components/ea-input/index.js +1 -0
- package/build/components/ea-input/src/components/createFixIcon.js +1 -0
- package/build/components/ea-input/src/components/createSuggestionBoard.js +1 -0
- package/build/components/ea-input/src/components/createWordLimitElement.js +1 -0
- package/build/components/ea-input/src/style/stylesheet.js +1 -0
- package/build/components/ea-input/src/utils/dispatchEvent.js +1 -0
- package/build/components/ea-input/src/utils/handleSearchResult.js +1 -0
- package/build/components/ea-input/src/utils/handleSuggestionBoardTrigger.js +1 -0
- package/build/components/ea-input-number/index.js +1 -0
- package/build/components/ea-input-number/src/style/stylesheet.js +1 -0
- package/build/components/ea-input-number/src/utils/handleCustomEvent.js +1 -0
- package/build/components/ea-link/index.js +1 -0
- package/build/components/ea-link/src/style/stylesheet.js +1 -0
- package/build/components/ea-loading/index.js +1 -0
- package/build/components/ea-loading/src/style/stylesheet.js +1 -0
- package/build/components/ea-main/index.js +1 -0
- package/build/components/ea-menu/index.js +1 -0
- package/build/components/ea-menu/src/style/stylesheet.js +1 -0
- package/build/components/ea-menu/src/utils/handleMenuItemEvent.js +1 -0
- package/build/components/ea-menu-item/index.js +1 -0
- package/build/components/ea-menu-item/src/style/stylesheet.js +1 -0
- package/build/components/ea-menu-item-group/index.js +1 -0
- package/build/components/ea-menu-item-group/src/style/stylesheet.js +1 -0
- package/build/components/ea-message/index.js +1 -0
- package/build/components/ea-message/src/style/stylesheet.js +1 -0
- package/build/components/ea-message/src/utils/MessageClass.js +1 -0
- package/build/components/ea-message-box/index.js +1 -0
- package/build/components/ea-message-box/src/style/stylesheet.js +1 -0
- package/build/components/ea-message-box/src/utils/EaMessageBoxClass.js +1 -0
- package/build/components/ea-option/index.js +1 -0
- package/build/components/ea-option/src/style/stylesheet.js +1 -0
- package/build/components/ea-option-gropu/index.js +1 -0
- package/build/components/ea-page-header/index.js +1 -0
- package/build/components/ea-page-header/src/style/stylesheet.js +1 -0
- package/build/components/ea-pagination/index.js +1 -0
- package/build/components/ea-pagination/src/components/getMoreItem.js +1 -0
- package/build/components/ea-pagination/src/components/getPageItem.js +1 -0
- package/build/components/ea-pagination/src/components/getShowTotalItem.js +1 -0
- package/build/components/ea-pagination/src/style/stylesheet.js +1 -0
- package/build/components/ea-pane/index.js +1 -0
- package/build/components/ea-pane/src/stylesheet.js +1 -0
- package/build/components/ea-progress/index.js +1 -0
- package/build/components/ea-progress/src/components/SVGComm.js +1 -0
- package/build/components/ea-progress/src/style/stylesheet.js +1 -0
- package/build/components/ea-radio/index.js +1 -0
- package/build/components/ea-radio/src/style/stylesheet.js +1 -0
- package/build/components/ea-radio-group/index.js +1 -0
- package/build/components/ea-rate/index.js +1 -0
- package/build/components/ea-rate/src/components/rateComm.js +1 -0
- package/build/components/ea-rate/src/style/stylesheet.js +1 -0
- package/build/components/ea-result/index.js +1 -0
- package/build/components/ea-result/src/style/stylesheet.js +1 -0
- package/build/components/ea-select/index.js +1 -0
- package/build/components/ea-select/src/style/stylesheet.js +1 -0
- package/build/components/ea-skeleton/index.js +1 -0
- package/build/components/ea-skeleton/src/style/stylesheet.js +1 -0
- package/build/components/ea-skeleton/src/utils/createSkeletonElement.js +1 -0
- package/build/components/ea-skeleton-item/index.js +1 -0
- package/build/components/ea-skeleton-item/src/assets/imageSVG.js +1 -0
- package/build/components/ea-skeleton-item/src/style/stylesheet.js +1 -0
- package/build/components/ea-step/index.js +1 -0
- package/build/components/ea-step/src/style/stylesheet.js +1 -0
- package/build/components/ea-steps/index.js +1 -0
- package/build/components/ea-steps/src/style/stylesheet.js +1 -0
- package/build/components/ea-submenu/index.js +1 -0
- package/build/components/ea-submenu/src/style/stylesheet.js +1 -0
- package/build/components/ea-switch/index.js +1 -0
- package/build/components/ea-switch/src/style/stylesheet.js +1 -0
- package/build/components/ea-tab/index.js +1 -0
- package/build/components/ea-tab/src/style/stylesheet.js +1 -0
- package/build/components/ea-table/index.js +1 -0
- package/build/components/ea-table/src/style/stylesheet.js +1 -0
- package/build/components/ea-table-column/index.js +1 -0
- package/build/components/ea-tabs/index.js +1 -0
- package/build/components/ea-tabs/src/style/stylesheet.js +1 -0
- package/build/components/ea-tag/index.js +1 -0
- package/build/components/ea-tag/src/style/stylesheet.js +1 -0
- package/build/components/ea-textarea/index.js +1 -0
- package/build/components/ea-textarea/src/style/stylesheet.js +1 -0
- package/build/components/ea-time-picker/index.js +1 -0
- package/build/components/ea-time-picker/src/style/stylesheet.js +1 -0
- package/build/components/ea-timeline/index.js +1 -0
- package/build/components/ea-timeline/style/stylesheet.js +1 -0
- package/build/components/ea-timeline-item/index.js +1 -0
- package/build/components/ea-timeline-item/src/style/stylesheet.js +1 -0
- package/build/components/globalConfig.js +1 -0
- package/build/components/index.js +1 -0
- package/build/utils/Validator.js +1 -0
- package/build/utils/createElement.js +1 -0
- package/build/utils/handleDefaultAttrIsTrue.js +1 -0
- package/build/utils/handleTemplate.js +1 -0
- package/build/utils/setStyle.js +1 -0
- package/build/utils/timeout.js +1 -0
- package/components/Base.js +75 -1
- package/components/ea-alert/index.css +91 -0
- package/components/ea-alert/index.js +210 -1
- package/components/ea-alert/index.scss +108 -0
- package/components/ea-alert/src/style/stylesheet.js +85 -1
- package/components/ea-aside/index.css +9 -0
- package/components/ea-aside/index.js +54 -1
- package/components/ea-aside/index.scss +12 -0
- package/components/ea-avatar/index.css +66 -0
- package/components/ea-avatar/index.js +156 -1
- package/components/ea-avatar/index.scss +59 -0
- package/components/ea-avatar/src/assets/defaultAvatar.js +12 -1
- package/components/ea-avatar/src/assets/errorAvatar.js +9 -1
- package/components/ea-avatar/src/assets/iconAndTextAvatar.js +18 -1
- package/components/ea-avatar/src/style/stylesheet.js +61 -1
- package/components/ea-backtop/index.css +27 -0
- package/components/ea-backtop/index.js +167 -1
- package/components/ea-backtop/index.scss +29 -0
- package/components/ea-backtop/src/style/stylesheet.js +21 -1
- package/components/ea-badge/index.css +49 -0
- package/components/ea-badge/index.js +103 -1
- package/components/ea-badge/index.scss +56 -0
- package/components/ea-badge/src/style/stylesheet.js +43 -1
- package/components/ea-breadcrumb/index.css +6 -0
- package/components/ea-breadcrumb/index.js +90 -1
- package/components/ea-breadcrumb/index.scss +7 -0
- package/components/ea-breadcrumb/src/style/stylesheet.js +8 -1
- package/components/ea-breadcrumb-item/index.css +10 -0
- package/components/ea-breadcrumb-item/index.js +23 -1
- package/components/ea-breadcrumb-item/index.scss +12 -0
- package/components/ea-breadcrumb-item/src/style/style.js +12 -1
- package/components/ea-button/index.css +206 -0
- package/components/ea-button/index.js +198 -1
- package/components/ea-button/index.scss +143 -0
- package/components/ea-button/src/components/ButtonComm.js +5 -1
- package/components/ea-button/src/components/HrefComm.js +5 -1
- package/components/ea-button/src/style/stylesheet.js +208 -1
- package/components/ea-button-group/index.css +16 -0
- package/components/ea-button-group/index.js +44 -1
- package/components/ea-button-group/index.scss +20 -0
- package/components/ea-button-group/src/style/stylesheet.js +18 -1
- package/components/ea-calendar/index.css +72 -0
- package/components/ea-calendar/index.js +298 -1
- package/components/ea-calendar/index.scss +106 -0
- package/components/ea-calendar/src/style/stylesheet.js +74 -1
- package/components/ea-calendar/src/utils/createChangerElement.js +10 -1
- package/components/ea-calendar/src/utils/createThead.js +18 -1
- package/components/ea-calendar/src/utils/getDate.js +11 -1
- package/components/ea-calendar/src/utils/getUserWeekStart.js +11 -1
- package/components/ea-card/index.css +25 -0
- package/components/ea-card/index.js +51 -1
- package/components/ea-card/index.scss +24 -0
- package/components/ea-card/src/style/stylesheet.js +19 -1
- package/components/ea-carousel/index.css +103 -0
- package/components/ea-carousel/index.js +222 -1
- package/components/ea-carousel/index.scss +140 -0
- package/components/ea-carousel/src/style/stylesheet.js +105 -1
- package/components/ea-carousel/src/utils/handleIndexOverflow.js +9 -1
- package/components/ea-carousel-item/index.css +20 -0
- package/components/ea-carousel-item/index.js +23 -1
- package/components/ea-carousel-item/index.scss +26 -0
- package/components/ea-carousel-item/src/style/stylesheet.js +22 -1
- package/components/ea-checkbox/index.css +108 -0
- package/components/ea-checkbox/index.js +160 -1
- package/components/ea-checkbox/index.scss +141 -0
- package/components/ea-checkbox/src/style/stylesheet.js +110 -1
- package/components/ea-checkbox-group/index.css +6 -0
- package/components/ea-checkbox-group/index.js +120 -1
- package/components/ea-checkbox-group/index.scss +7 -0
- package/components/ea-checkbox-group/src/style/stylesheet.js +8 -1
- package/components/ea-collapse/index.css +0 -0
- package/components/ea-collapse/index.js +109 -1
- package/components/ea-collapse/index.scss +4 -0
- package/components/ea-collapse-item/index.css +31 -0
- package/components/ea-collapse-item/index.js +111 -1
- package/components/ea-collapse-item/index.scss +46 -0
- package/components/ea-collapse-item/src/style/stylesheet.js +33 -1
- package/components/ea-container/index.css +14 -0
- package/components/ea-container/index.js +85 -1
- package/components/ea-container/index.scss +18 -0
- package/components/ea-date-picker/index.css +17 -0
- package/components/ea-date-picker/index.js +191 -1
- package/components/ea-date-picker/index.scss +29 -0
- package/components/ea-date-picker/src/style/stylesheet.js +19 -1
- package/components/ea-descriptions/index.css +33 -0
- package/components/ea-descriptions/index.js +171 -1
- package/components/ea-descriptions/index.scss +45 -0
- package/components/ea-descriptions/src/components/contentTemplate.js +11 -1
- package/components/ea-descriptions/src/components/getTdTemplate_border.js +6 -1
- package/components/ea-descriptions/src/components/getTdTemplate_direction.js +7 -1
- package/components/ea-descriptions/src/components/getThTemplate_direction.js +7 -1
- package/components/ea-descriptions/src/components/getThTemplate_normal.js +8 -1
- package/components/ea-descriptions/src/style/stylesheet.js +35 -1
- package/components/ea-descriptions-item/index.css +21 -0
- package/components/ea-descriptions-item/index.js +71 -1
- package/components/ea-descriptions-item/index.scss +29 -0
- package/components/ea-descriptions-item/src/stylesheet.js +23 -1
- package/components/ea-drawer/index.css +138 -0
- package/components/ea-drawer/index.js +251 -1
- package/components/ea-drawer/index.scss +208 -0
- package/components/ea-drawer/src/style/stylesheet.js +141 -1
- package/components/ea-empty/index.css +30 -0
- package/components/ea-empty/index.js +93 -1
- package/components/ea-empty/index.scss +30 -0
- package/components/ea-empty/src/assets/emptyStatusSVG.js +6 -1
- package/components/ea-empty/src/style/stylesheet.js +24 -1
- package/components/ea-footer/index.css +7 -0
- package/components/ea-footer/index.js +57 -1
- package/components/ea-footer/index.scss +10 -0
- package/components/ea-form/index.css +0 -0
- package/components/ea-form/index.js +121 -1
- package/components/ea-form/index.scss +0 -0
- package/components/ea-form-item/index.css +62 -0
- package/components/ea-form-item/index.js +152 -1
- package/components/ea-form-item/index.scss +83 -0
- package/components/ea-form-item/src/style/stylesheet.js +64 -1
- package/components/ea-header/index.css +7 -0
- package/components/ea-header/index.js +55 -1
- package/components/ea-header/index.scss +10 -0
- package/components/ea-icon/css/fontello.css +312 -226
- package/components/ea-icon/index.css +1 -2
- package/components/ea-icon/index.js +84 -1
- package/components/ea-image/index.css +84 -0
- package/components/ea-image/index.js +182 -1
- package/components/ea-image/index.scss +111 -0
- package/components/ea-image/src/assets/errorImage.js +9 -1
- package/components/ea-image/src/assets/errorImage.svg +7 -0
- package/components/ea-image/src/style/stylesheet.js +86 -1
- package/components/ea-image/src/utils/createPreviewTools.js +140 -1
- package/components/ea-infinite-scroll/index.css +0 -0
- package/components/ea-infinite-scroll/index.js +119 -1
- package/components/ea-infinite-scroll/index.scss +0 -0
- package/components/ea-infinite-scroll-item/index.css +0 -0
- package/components/ea-infinite-scroll-item/index.js +18 -1
- package/components/ea-infinite-scroll-item/index.scss +0 -0
- package/components/ea-input/index.css +139 -0
- package/components/ea-input/index.js +398 -1
- package/components/ea-input/index.scss +178 -0
- package/components/ea-input/src/components/createFixIcon.js +108 -1
- package/components/ea-input/src/components/createSuggestionBoard.js +43 -1
- package/components/ea-input/src/components/createWordLimitElement.js +18 -1
- package/components/ea-input/src/style/stylesheet.js +141 -1
- package/components/ea-input/src/utils/dispatchEvent.js +9 -1
- package/components/ea-input/src/utils/handleSearchResult.js +9 -1
- package/components/ea-input/src/utils/handleSuggestionBoardTrigger.js +31 -1
- package/components/ea-input-number/index.css +120 -0
- package/components/ea-input-number/index.js +308 -1
- package/components/ea-input-number/index.scss +132 -0
- package/components/ea-input-number/src/style/stylesheet.js +122 -1
- package/components/ea-input-number/src/utils/handleCustomEvent.js +5 -1
- package/components/ea-link/index.css +48 -0
- package/components/ea-link/index.js +122 -1
- package/components/ea-link/index.scss +36 -0
- package/components/ea-link/src/style/stylesheet.js +50 -1
- package/components/ea-loading/index.css +38 -0
- package/components/ea-loading/index.js +166 -1
- package/components/ea-loading/index.scss +55 -0
- package/components/ea-loading/src/style/stylesheet.js +40 -1
- package/components/ea-main/index.css +8 -0
- package/components/ea-main/index.js +32 -1
- package/components/ea-main/index.scss +11 -0
- package/components/ea-menu/index.css +19 -0
- package/components/ea-menu/index.js +131 -1
- package/components/ea-menu/index.scss +22 -0
- package/components/ea-menu/src/style/stylesheet.js +21 -1
- package/components/ea-menu/src/utils/handleMenuItemEvent.js +32 -1
- package/components/ea-menu-item/index.css +48 -0
- package/components/ea-menu-item/index.js +130 -1
- package/components/ea-menu-item/index.scss +62 -0
- package/components/ea-menu-item/src/style/stylesheet.js +50 -1
- package/components/ea-menu-item-group/index.css +42 -0
- package/components/ea-menu-item-group/index.js +130 -1
- package/components/ea-menu-item-group/index.scss +60 -0
- package/components/ea-menu-item-group/src/style/stylesheet.js +44 -1
- package/components/ea-message/index.css +47 -0
- package/components/ea-message/index.js +171 -1
- package/components/ea-message/index.scss +70 -0
- package/components/ea-message/src/style/stylesheet.js +48 -1
- package/components/ea-message/src/utils/MessageClass.js +67 -1
- package/components/ea-message-box/index.css +85 -0
- package/components/ea-message-box/index.js +211 -1
- package/components/ea-message-box/index.scss +113 -0
- package/components/ea-message-box/src/style/stylesheet.js +87 -1
- package/components/ea-message-box/src/utils/EaMessageBoxClass.js +60 -1
- package/components/ea-option/index.css +24 -0
- package/components/ea-option/index.js +74 -1
- package/components/ea-option/index.scss +31 -0
- package/components/ea-option/src/style/stylesheet.js +26 -1
- package/components/ea-option-gropu/index.css +6 -0
- package/components/ea-option-gropu/index.js +57 -1
- package/components/ea-option-gropu/index.scss +8 -0
- package/components/ea-page-header/index.css +33 -0
- package/components/ea-page-header/index.js +91 -1
- package/components/ea-page-header/index.scss +44 -0
- package/components/ea-page-header/src/style/stylesheet.js +35 -1
- package/components/ea-pagination/index.css +69 -0
- package/components/ea-pagination/index.js +305 -1
- package/components/ea-pagination/index.scss +89 -0
- package/components/ea-pagination/src/components/getMoreItem.js +20 -1
- package/components/ea-pagination/src/components/getPageItem.js +11 -1
- package/components/ea-pagination/src/components/getShowTotalItem.js +7 -1
- package/components/ea-pagination/src/style/stylesheet.js +71 -1
- package/components/ea-pane/index.css +6 -0
- package/components/ea-pane/index.js +52 -1
- package/components/ea-pane/index.scss +7 -0
- package/components/ea-pane/src/stylesheet.js +8 -1
- package/components/ea-progress/index.css +61 -0
- package/components/ea-progress/index.js +249 -1
- package/components/ea-progress/index.scss +74 -0
- package/components/ea-progress/src/components/SVGComm.js +18 -1
- package/components/ea-progress/src/style/stylesheet.js +55 -1
- package/components/ea-radio/index.css +82 -0
- package/components/ea-radio/index.js +137 -1
- package/components/ea-radio/index.scss +119 -0
- package/components/ea-radio/src/style/stylesheet.js +84 -1
- package/components/ea-radio-group/index.css +3 -0
- package/components/ea-radio-group/index.js +96 -1
- package/components/ea-radio-group/index.scss +3 -0
- package/components/ea-rate/index.css +44 -0
- package/components/ea-rate/index.js +243 -1
- package/components/ea-rate/index.scss +55 -0
- package/components/ea-rate/src/components/rateComm.js +20 -1
- package/components/ea-rate/src/style/stylesheet.js +45 -1
- package/components/ea-result/index.css +37 -0
- package/components/ea-result/index.js +109 -1
- package/components/ea-result/index.scss +46 -0
- package/components/ea-result/src/style/stylesheet.js +39 -1
- package/components/ea-select/index.css +47 -0
- package/components/ea-select/index.js +312 -1
- package/components/ea-select/index.scss +70 -0
- package/components/ea-select/src/style/stylesheet.js +49 -1
- package/components/ea-skeleton/index.css +12 -0
- package/components/ea-skeleton/index.js +148 -1
- package/components/ea-skeleton/index.scss +16 -0
- package/components/ea-skeleton/src/style/stylesheet.js +14 -1
- package/components/ea-skeleton/src/utils/createSkeletonElement.js +7 -1
- package/components/ea-skeleton-item/index.css +69 -0
- package/components/ea-skeleton-item/index.js +82 -1
- package/components/ea-skeleton-item/index.scss +107 -0
- package/components/ea-skeleton-item/src/assets/imageSVG.js +8 -1
- package/components/ea-skeleton-item/src/style/stylesheet.js +71 -1
- package/components/ea-step/index.css +84 -0
- package/components/ea-step/index.js +230 -1
- package/components/ea-step/index.scss +110 -0
- package/components/ea-step/src/style/stylesheet.js +86 -1
- package/components/ea-steps/index.css +19 -0
- package/components/ea-steps/index.js +104 -1
- package/components/ea-steps/index.scss +23 -0
- package/components/ea-steps/src/style/stylesheet.js +21 -1
- package/components/ea-submenu/index.css +65 -0
- package/components/ea-submenu/index.js +141 -1
- package/components/ea-submenu/index.scss +88 -0
- package/components/ea-submenu/src/style/stylesheet.js +67 -1
- package/components/ea-switch/index.css +90 -0
- package/components/ea-switch/index.js +189 -1
- package/components/ea-switch/index.scss +117 -0
- package/components/ea-switch/src/style/stylesheet.js +92 -1
- package/components/ea-tab/index.css +68 -0
- package/components/ea-tab/index.js +138 -1
- package/components/ea-tab/index.scss +96 -0
- package/components/ea-tab/src/style/stylesheet.js +70 -1
- package/components/ea-table/index.css +98 -0
- package/components/ea-table/index.js +555 -1
- package/components/ea-table/index.scss +90 -0
- package/components/ea-table/src/style/stylesheet.js +100 -1
- package/components/ea-table-column/index.css +0 -0
- package/components/ea-table-column/index.js +164 -1
- package/components/ea-table-column/index.scss +0 -0
- package/components/ea-tabs/index.css +45 -0
- package/components/ea-tabs/index.js +245 -1
- package/components/ea-tabs/index.scss +64 -0
- package/components/ea-tabs/src/style/stylesheet.js +47 -1
- package/components/ea-tag/index.css +90 -0
- package/components/ea-tag/index.js +107 -1
- package/components/ea-tag/index.scss +71 -0
- package/components/ea-tag/src/style/stylesheet.js +92 -1
- package/components/ea-textarea/index.css +37 -0
- package/components/ea-textarea/index.js +277 -1
- package/components/ea-textarea/index.scss +48 -0
- package/components/ea-textarea/src/style/stylesheet.js +39 -1
- package/components/ea-time-picker/index.css +82 -0
- package/components/ea-time-picker/index.js +379 -1
- package/components/ea-time-picker/index.scss +110 -0
- package/components/ea-time-picker/src/style/stylesheet.js +84 -1
- package/components/ea-timeline/index.css +0 -0
- package/components/ea-timeline/index.js +74 -1
- package/components/ea-timeline/index.scss +1 -0
- package/components/ea-timeline/style/stylesheet.js +3 -1
- package/components/ea-timeline-item/index.css +79 -0
- package/components/ea-timeline-item/index.js +146 -1
- package/components/ea-timeline-item/index.scss +92 -0
- package/components/ea-timeline-item/src/style/stylesheet.js +81 -1
- package/components/ea-ui-base-style.css +0 -0
- package/components/ea-ui-base-style.scss +153 -0
- package/components/globalConfig.js +10 -0
- package/components/index.js +67 -0
- package/package.json +1 -1
- package/public/logo.png +0 -0
- package/utils/Validator.js +16 -1
- package/utils/createElement.js +30 -1
- package/utils/handleDefaultAttrIsTrue.js +11 -1
- package/utils/handleTemplate.js +19 -1
- package/utils/setStyle.js +8 -1
- package/utils/timeout.js +16 -1
- package/components/ea-icon/css/animation.css +0 -85
- package/components/ea-icon/css/fontello-embedded.css +0 -181
- package/components/ea-icon/css/fontello-ie7-codes.css +0 -123
- package/components/ea-icon/css/fontello-ie7.css +0 -134
|
@@ -1 +1,67 @@
|
|
|
1
|
-
export const stylesheet=
|
|
1
|
+
export const stylesheet = `
|
|
2
|
+
.ea-submenu_wrap {
|
|
3
|
+
--normal-bgc: #fff;
|
|
4
|
+
--normal-text-color: #303133;
|
|
5
|
+
--actived-text-color: #409eff;
|
|
6
|
+
--actived-bgc: #fff;
|
|
7
|
+
position: relative;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
padding: 0 20px;
|
|
10
|
+
border-bottom: 2px solid;
|
|
11
|
+
border-color: transparent;
|
|
12
|
+
height: 60px;
|
|
13
|
+
line-height: 60px;
|
|
14
|
+
font-size: 14px;
|
|
15
|
+
color: var(--normal-text-color);
|
|
16
|
+
background-color: var(--normal-bgc);
|
|
17
|
+
white-space: nowrap;
|
|
18
|
+
cursor: pointer;
|
|
19
|
+
transition: border-color 0.3s, background-color 0.3s, color 0.3s;
|
|
20
|
+
}
|
|
21
|
+
.ea-submenu_wrap .ea-submenu_title_wrap {
|
|
22
|
+
display: flex;
|
|
23
|
+
justify-content: space-between;
|
|
24
|
+
}
|
|
25
|
+
.ea-submenu_wrap .ea-submenu_title_wrap .ea-submenu_dropdown_icon {
|
|
26
|
+
rotate: -90deg;
|
|
27
|
+
transition: rotate 0.3s;
|
|
28
|
+
}
|
|
29
|
+
.ea-submenu_wrap .ea-submenu_items_wrap {
|
|
30
|
+
display: none;
|
|
31
|
+
position: absolute;
|
|
32
|
+
left: 0;
|
|
33
|
+
margin-top: 3px;
|
|
34
|
+
border-radius: 8px;
|
|
35
|
+
overflow: hidden;
|
|
36
|
+
min-width: 200px;
|
|
37
|
+
z-index: 100;
|
|
38
|
+
opacity: 0;
|
|
39
|
+
transform-origin: left top;
|
|
40
|
+
transform: scale(0);
|
|
41
|
+
transition: opacity 0.3s, transform 0.3s;
|
|
42
|
+
}
|
|
43
|
+
.ea-submenu_wrap:hover .ea-submenu_items_wrap {
|
|
44
|
+
opacity: 1;
|
|
45
|
+
transform: scale(1);
|
|
46
|
+
box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
|
|
47
|
+
}
|
|
48
|
+
.ea-submenu_wrap:hover .ea-submenu_title_wrap .ea-submenu_dropdown_icon {
|
|
49
|
+
rotate: 0deg;
|
|
50
|
+
}
|
|
51
|
+
.ea-submenu_wrap.is-actived {
|
|
52
|
+
color: var(--actived-text-color);
|
|
53
|
+
border-color: var(--actived-text-color);
|
|
54
|
+
}
|
|
55
|
+
.ea-submenu_wrap.is-sub-actived {
|
|
56
|
+
color: var(--actived-text-color);
|
|
57
|
+
}
|
|
58
|
+
.ea-submenu_wrap.is-disabled {
|
|
59
|
+
color: #c0c4cc;
|
|
60
|
+
pointer-events: none;
|
|
61
|
+
cursor: not-allowed;
|
|
62
|
+
}
|
|
63
|
+
.ea-submenu_wrap ::slotted(a) {
|
|
64
|
+
color: var(--normal-text-color);
|
|
65
|
+
text-decoration: none;
|
|
66
|
+
}
|
|
67
|
+
`;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
:host {
|
|
2
|
+
--active-text-color: #409eff;
|
|
3
|
+
--inactive-text-color: ##606266;
|
|
4
|
+
--active-checkbox-bgc: #409eff;
|
|
5
|
+
--inactive-checkbox-bgc: #eff1f5;
|
|
6
|
+
--active-disabled-text-color: #7ebfff;
|
|
7
|
+
--active-disabled-bgc: #bbdcff;
|
|
8
|
+
--inactive-disabled-text-color: #c0c4cc;
|
|
9
|
+
--inactive-disabled-bgc: #eff1f5;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.ea-switch_wrap {
|
|
13
|
+
display: flex;
|
|
14
|
+
align-items: center;
|
|
15
|
+
cursor: pointer;
|
|
16
|
+
}
|
|
17
|
+
.ea-switch_wrap input {
|
|
18
|
+
display: none;
|
|
19
|
+
}
|
|
20
|
+
.ea-switch_wrap .ea-switch_label {
|
|
21
|
+
font-size: 0.875rem;
|
|
22
|
+
transition: color 0.2s;
|
|
23
|
+
}
|
|
24
|
+
.ea-switch_wrap input + .ea-switch_label--left {
|
|
25
|
+
color: var(--active-text-color);
|
|
26
|
+
}
|
|
27
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left {
|
|
28
|
+
color: var(--inactive-text-color);
|
|
29
|
+
}
|
|
30
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core {
|
|
31
|
+
background-color: var(--active-checkbox-bgc);
|
|
32
|
+
}
|
|
33
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core::after {
|
|
34
|
+
left: calc(100% - 1rem - 2px);
|
|
35
|
+
}
|
|
36
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
37
|
+
color: var(--active-text-color);
|
|
38
|
+
}
|
|
39
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left {
|
|
40
|
+
color: var(--active-disabled-text-color);
|
|
41
|
+
}
|
|
42
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left + .ea-switch_core {
|
|
43
|
+
background-color: var(--inactive-disabled-bgc);
|
|
44
|
+
}
|
|
45
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
46
|
+
color: var(--inactive-disabled-text-color);
|
|
47
|
+
}
|
|
48
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left {
|
|
49
|
+
color: var(--inactive-disabled-text-color);
|
|
50
|
+
}
|
|
51
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core {
|
|
52
|
+
background-color: var(--active-disabled-bgc);
|
|
53
|
+
}
|
|
54
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core::after {
|
|
55
|
+
left: calc(100% - 1rem - 2px);
|
|
56
|
+
}
|
|
57
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
58
|
+
color: var(--inactive-disabled-text-color);
|
|
59
|
+
}
|
|
60
|
+
.ea-switch_wrap .ea-switch_core {
|
|
61
|
+
position: relative;
|
|
62
|
+
cursor: pointer;
|
|
63
|
+
margin: 0 0.75rem;
|
|
64
|
+
width: 2.5rem;
|
|
65
|
+
height: 1.25rem;
|
|
66
|
+
line-height: 1.25rem;
|
|
67
|
+
background-color: var(--inactive-checkbox-bgc);
|
|
68
|
+
border-radius: 999px;
|
|
69
|
+
transition: background-color 0.2s;
|
|
70
|
+
}
|
|
71
|
+
.ea-switch_wrap .ea-switch_core::after {
|
|
72
|
+
content: "";
|
|
73
|
+
display: block;
|
|
74
|
+
position: absolute;
|
|
75
|
+
left: 2px;
|
|
76
|
+
top: 50%;
|
|
77
|
+
transform: translate(0, -50%);
|
|
78
|
+
width: 1rem;
|
|
79
|
+
height: 1rem;
|
|
80
|
+
border-radius: 999px;
|
|
81
|
+
background-color: #fff;
|
|
82
|
+
transition: left 0.2s, transform 0.2s;
|
|
83
|
+
}
|
|
84
|
+
.ea-switch_wrap.disabled {
|
|
85
|
+
cursor: not-allowed;
|
|
86
|
+
}
|
|
87
|
+
.ea-switch_wrap.disabled .ea-switch_label,
|
|
88
|
+
.ea-switch_wrap.disabled .ea-switch_core {
|
|
89
|
+
pointer-events: none;
|
|
90
|
+
}
|
|
@@ -1 +1,189 @@
|
|
|
1
|
-
|
|
1
|
+
// @ts-nocheck
|
|
2
|
+
import Base from '../Base.js';
|
|
3
|
+
|
|
4
|
+
import { stylesheet } from './src/style/stylesheet.js';
|
|
5
|
+
|
|
6
|
+
export class EaSwitch extends Base {
|
|
7
|
+
#wrap;
|
|
8
|
+
#input;
|
|
9
|
+
|
|
10
|
+
#labelLeft;
|
|
11
|
+
#inputCore;
|
|
12
|
+
#labelRight;
|
|
13
|
+
|
|
14
|
+
constructor() {
|
|
15
|
+
super();
|
|
16
|
+
|
|
17
|
+
const shadowRoot = this.attachShadow({ mode: 'open' });
|
|
18
|
+
shadowRoot.innerHTML = `
|
|
19
|
+
<label class="ea-switch_wrap" part="container">
|
|
20
|
+
<input class="ea-switch_input" type="checkbox">
|
|
21
|
+
<span class="ea-switch_label ea-switch_label--left" part="label-left"></span>
|
|
22
|
+
<span class="ea-switch_core" part="switch"></span>
|
|
23
|
+
<span class="ea-switch_label ea-switch_label--right" part="label-right"></span>
|
|
24
|
+
</label>
|
|
25
|
+
`;
|
|
26
|
+
|
|
27
|
+
this.#wrap = shadowRoot.querySelector('.ea-switch_wrap');
|
|
28
|
+
this.#input = shadowRoot.querySelector('.ea-switch_input');
|
|
29
|
+
this.#labelLeft = shadowRoot.querySelector('.ea-switch_label--left');
|
|
30
|
+
this.#inputCore = shadowRoot.querySelector('.ea-switch_core');
|
|
31
|
+
this.#labelRight = shadowRoot.querySelector('.ea-switch_label--right');
|
|
32
|
+
|
|
33
|
+
this.build(shadowRoot, stylesheet);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// ------- name 属性 -------
|
|
37
|
+
// #region
|
|
38
|
+
get name() {
|
|
39
|
+
return this.getAttribute('name') || 'ea-switch';
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
set name(value) {
|
|
43
|
+
this.setAttribute('name', value);
|
|
44
|
+
|
|
45
|
+
this.#wrap.setAttribute('for', value);
|
|
46
|
+
this.#input.setAttribute('name', value);
|
|
47
|
+
this.#input.setAttribute('id', value);
|
|
48
|
+
}
|
|
49
|
+
// #endregion
|
|
50
|
+
// ------- end -------
|
|
51
|
+
|
|
52
|
+
// ------- value 属性 -------
|
|
53
|
+
// #region
|
|
54
|
+
get value() {
|
|
55
|
+
if (this.inactiveText && !this.checked) return this.inactiveText;
|
|
56
|
+
else if (this.activeText && this.checked) return this.activeText;
|
|
57
|
+
return this.checked;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
set value(value) {
|
|
61
|
+
this.#input.value = value;
|
|
62
|
+
}
|
|
63
|
+
// #endregion
|
|
64
|
+
// ------- end -------
|
|
65
|
+
|
|
66
|
+
// ------- inactive-text 关闭时选项 -------
|
|
67
|
+
// #region
|
|
68
|
+
get inactiveText() {
|
|
69
|
+
return this.getAttribute('inactive-text') || '';
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
set inactiveText(value) {
|
|
73
|
+
if (!value) return;
|
|
74
|
+
|
|
75
|
+
this.setAttribute('inactive-text', value);
|
|
76
|
+
this.#labelLeft.innerText = value;
|
|
77
|
+
}
|
|
78
|
+
// #endregion
|
|
79
|
+
// ------- end -------
|
|
80
|
+
|
|
81
|
+
// ------- active-text 开启时选项 -------
|
|
82
|
+
// #region
|
|
83
|
+
get activeText() {
|
|
84
|
+
return this.getAttribute('active-text') || '';
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
set activeText(value) {
|
|
88
|
+
if (!value) return;
|
|
89
|
+
|
|
90
|
+
this.setAttribute('active-text', value);
|
|
91
|
+
this.#labelRight.innerText = value;
|
|
92
|
+
}
|
|
93
|
+
// #endregion
|
|
94
|
+
// ------- end -------
|
|
95
|
+
|
|
96
|
+
// ------- checked 选中 -------
|
|
97
|
+
// #region
|
|
98
|
+
get checked() {
|
|
99
|
+
return this.getAttrBoolean('checked');
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
set checked(value) {
|
|
103
|
+
this.setAttribute('checked', value);
|
|
104
|
+
this.#input.checked = value;
|
|
105
|
+
}
|
|
106
|
+
// #endregion
|
|
107
|
+
// ------- end -------
|
|
108
|
+
|
|
109
|
+
// ------- disabled 禁用 -------
|
|
110
|
+
// #region
|
|
111
|
+
get disabled() {
|
|
112
|
+
return this.getAttrBoolean('disabled');
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
set disabled(value) {
|
|
116
|
+
this.setAttribute('disabled', value);
|
|
117
|
+
this.#input.disabled = value;
|
|
118
|
+
this.#wrap.classList.toggle('disabled', value);
|
|
119
|
+
}
|
|
120
|
+
// #endregion
|
|
121
|
+
// ------- end -------
|
|
122
|
+
|
|
123
|
+
// ------- inactive-color 关闭时颜色 -------
|
|
124
|
+
// #region
|
|
125
|
+
get inactiveColor() {
|
|
126
|
+
return this.getAttribute('inactive-color') || '';
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
set inactiveColor(value) {
|
|
130
|
+
if (!value) return;
|
|
131
|
+
|
|
132
|
+
this.style.setProperty('--inactive-checkbox-bgc', value);
|
|
133
|
+
}
|
|
134
|
+
// #endregion
|
|
135
|
+
// ------- end -------
|
|
136
|
+
|
|
137
|
+
// ------- active-color 开启时颜色 -------
|
|
138
|
+
// #region
|
|
139
|
+
get activeColor() {
|
|
140
|
+
return this.getAttribute('active-color');
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
set activeColor(value) {
|
|
144
|
+
if (!value) return;
|
|
145
|
+
|
|
146
|
+
this.style.setProperty('--active-checkbox-bgc', value);
|
|
147
|
+
}
|
|
148
|
+
// #endregion
|
|
149
|
+
// ------- end -------
|
|
150
|
+
|
|
151
|
+
connectedCallback() {
|
|
152
|
+
this.setAttribute('data-ea-component', true);
|
|
153
|
+
|
|
154
|
+
this.name = this.name;
|
|
155
|
+
|
|
156
|
+
this.value = this.value
|
|
157
|
+
|
|
158
|
+
// 设置勾选值
|
|
159
|
+
this.checked = this.checked;
|
|
160
|
+
|
|
161
|
+
// 设置开启/关闭值
|
|
162
|
+
this.inactiveText = this.inactiveText;
|
|
163
|
+
this.activeText = this.activeText;
|
|
164
|
+
|
|
165
|
+
// 设置禁用
|
|
166
|
+
this.disabled = this.disabled;
|
|
167
|
+
|
|
168
|
+
this.inactiveColor = this.inactiveColor;
|
|
169
|
+
this.activeColor = this.activeColor;
|
|
170
|
+
|
|
171
|
+
this.#input.addEventListener('change', (e) => {
|
|
172
|
+
e.preventDefault();
|
|
173
|
+
e.stopPropagation();
|
|
174
|
+
|
|
175
|
+
this.checked = e.target.checked;
|
|
176
|
+
|
|
177
|
+
this.dispatchEvent(new CustomEvent("change", {
|
|
178
|
+
detail: {
|
|
179
|
+
checked: this.checked,
|
|
180
|
+
value: this.value,
|
|
181
|
+
},
|
|
182
|
+
}))
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
if (!customElements.get('ea-switch')) {
|
|
188
|
+
customElements.define('ea-switch', EaSwitch);
|
|
189
|
+
}
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
@import "../ea-ui-base-style.scss";
|
|
2
|
+
|
|
3
|
+
:host {
|
|
4
|
+
--active-text-color: #409eff;
|
|
5
|
+
--inactive-text-color: ##606266;
|
|
6
|
+
|
|
7
|
+
--active-checkbox-bgc: #409eff;
|
|
8
|
+
--inactive-checkbox-bgc: #eff1f5;
|
|
9
|
+
|
|
10
|
+
--active-disabled-text-color: #7ebfff;
|
|
11
|
+
--active-disabled-bgc: #bbdcff;
|
|
12
|
+
--inactive-disabled-text-color: #c0c4cc;
|
|
13
|
+
--inactive-disabled-bgc: #eff1f5;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.ea-switch_wrap {
|
|
17
|
+
display: flex;
|
|
18
|
+
align-items: center;
|
|
19
|
+
cursor: pointer;
|
|
20
|
+
|
|
21
|
+
input {
|
|
22
|
+
display: none;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.ea-switch_label {
|
|
26
|
+
font-size: 0.875rem;
|
|
27
|
+
transition: color 0.2s;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
input + .ea-switch_label--left {
|
|
31
|
+
color: var(--active-text-color);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
input:checked + .ea-switch_label--left {
|
|
35
|
+
color: var(--inactive-text-color);
|
|
36
|
+
|
|
37
|
+
& + .ea-switch_core {
|
|
38
|
+
background-color: var(--active-checkbox-bgc);
|
|
39
|
+
&::after {
|
|
40
|
+
left: calc(100% - 1rem - 2px);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
& + .ea-switch_label--right {
|
|
44
|
+
color: var(--active-text-color);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
input:disabled + .ea-switch_label--left {
|
|
50
|
+
color: var(--active-disabled-text-color);
|
|
51
|
+
|
|
52
|
+
& + .ea-switch_core {
|
|
53
|
+
background-color: var(--inactive-disabled-bgc);
|
|
54
|
+
|
|
55
|
+
& + .ea-switch_label--right {
|
|
56
|
+
color: var(--inactive-disabled-text-color);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
input:checked:disabled + .ea-switch_label--left {
|
|
62
|
+
color: var(--inactive-disabled-text-color);
|
|
63
|
+
& + .ea-switch_core {
|
|
64
|
+
background-color: var(--active-disabled-bgc);
|
|
65
|
+
&::after {
|
|
66
|
+
left: calc(100% - 1rem - 2px);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
& + .ea-switch_label--right {
|
|
70
|
+
color: var(--inactive-disabled-text-color);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.ea-switch_core {
|
|
76
|
+
position: relative;
|
|
77
|
+
cursor: pointer;
|
|
78
|
+
|
|
79
|
+
margin: 0 0.75rem;
|
|
80
|
+
|
|
81
|
+
width: 2.5rem;
|
|
82
|
+
height: 1.25rem;
|
|
83
|
+
line-height: 1.25rem;
|
|
84
|
+
|
|
85
|
+
background-color: var(--inactive-checkbox-bgc);
|
|
86
|
+
border-radius: 999px;
|
|
87
|
+
|
|
88
|
+
transition: background-color 0.2s;
|
|
89
|
+
|
|
90
|
+
&::after {
|
|
91
|
+
content: "";
|
|
92
|
+
display: block;
|
|
93
|
+
|
|
94
|
+
position: absolute;
|
|
95
|
+
left: 2px;
|
|
96
|
+
top: 50%;
|
|
97
|
+
transform: translate(0, -50%);
|
|
98
|
+
|
|
99
|
+
width: 1rem;
|
|
100
|
+
height: 1rem;
|
|
101
|
+
|
|
102
|
+
border-radius: 999px;
|
|
103
|
+
background-color: #fff;
|
|
104
|
+
|
|
105
|
+
transition: left 0.2s, transform 0.2s;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
&.disabled {
|
|
110
|
+
cursor: not-allowed;
|
|
111
|
+
|
|
112
|
+
.ea-switch_label,
|
|
113
|
+
.ea-switch_core {
|
|
114
|
+
pointer-events: none;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
@@ -1 +1,92 @@
|
|
|
1
|
-
export const stylesheet=
|
|
1
|
+
export const stylesheet = `
|
|
2
|
+
:host {
|
|
3
|
+
--active-text-color: #409eff;
|
|
4
|
+
--inactive-text-color: ##606266;
|
|
5
|
+
--active-checkbox-bgc: #409eff;
|
|
6
|
+
--inactive-checkbox-bgc: #eff1f5;
|
|
7
|
+
--active-disabled-text-color: #7ebfff;
|
|
8
|
+
--active-disabled-bgc: #bbdcff;
|
|
9
|
+
--inactive-disabled-text-color: #c0c4cc;
|
|
10
|
+
--inactive-disabled-bgc: #eff1f5;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.ea-switch_wrap {
|
|
14
|
+
display: flex;
|
|
15
|
+
align-items: center;
|
|
16
|
+
cursor: pointer;
|
|
17
|
+
}
|
|
18
|
+
.ea-switch_wrap input {
|
|
19
|
+
display: none;
|
|
20
|
+
}
|
|
21
|
+
.ea-switch_wrap .ea-switch_label {
|
|
22
|
+
font-size: 0.875rem;
|
|
23
|
+
transition: color 0.2s;
|
|
24
|
+
}
|
|
25
|
+
.ea-switch_wrap input + .ea-switch_label--left {
|
|
26
|
+
color: var(--active-text-color);
|
|
27
|
+
}
|
|
28
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left {
|
|
29
|
+
color: var(--inactive-text-color);
|
|
30
|
+
}
|
|
31
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core {
|
|
32
|
+
background-color: var(--active-checkbox-bgc);
|
|
33
|
+
}
|
|
34
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core::after {
|
|
35
|
+
left: calc(100% - 1rem - 2px);
|
|
36
|
+
}
|
|
37
|
+
.ea-switch_wrap input:checked + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
38
|
+
color: var(--active-text-color);
|
|
39
|
+
}
|
|
40
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left {
|
|
41
|
+
color: var(--active-disabled-text-color);
|
|
42
|
+
}
|
|
43
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left + .ea-switch_core {
|
|
44
|
+
background-color: var(--inactive-disabled-bgc);
|
|
45
|
+
}
|
|
46
|
+
.ea-switch_wrap input:disabled + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
47
|
+
color: var(--inactive-disabled-text-color);
|
|
48
|
+
}
|
|
49
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left {
|
|
50
|
+
color: var(--inactive-disabled-text-color);
|
|
51
|
+
}
|
|
52
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core {
|
|
53
|
+
background-color: var(--active-disabled-bgc);
|
|
54
|
+
}
|
|
55
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core::after {
|
|
56
|
+
left: calc(100% - 1rem - 2px);
|
|
57
|
+
}
|
|
58
|
+
.ea-switch_wrap input:checked:disabled + .ea-switch_label--left + .ea-switch_core + .ea-switch_label--right {
|
|
59
|
+
color: var(--inactive-disabled-text-color);
|
|
60
|
+
}
|
|
61
|
+
.ea-switch_wrap .ea-switch_core {
|
|
62
|
+
position: relative;
|
|
63
|
+
cursor: pointer;
|
|
64
|
+
margin: 0 0.75rem;
|
|
65
|
+
width: 2.5rem;
|
|
66
|
+
height: 1.25rem;
|
|
67
|
+
line-height: 1.25rem;
|
|
68
|
+
background-color: var(--inactive-checkbox-bgc);
|
|
69
|
+
border-radius: 999px;
|
|
70
|
+
transition: background-color 0.2s;
|
|
71
|
+
}
|
|
72
|
+
.ea-switch_wrap .ea-switch_core::after {
|
|
73
|
+
content: "";
|
|
74
|
+
display: block;
|
|
75
|
+
position: absolute;
|
|
76
|
+
left: 2px;
|
|
77
|
+
top: 50%;
|
|
78
|
+
transform: translate(0, -50%);
|
|
79
|
+
width: 1rem;
|
|
80
|
+
height: 1rem;
|
|
81
|
+
border-radius: 999px;
|
|
82
|
+
background-color: #fff;
|
|
83
|
+
transition: left 0.2s, transform 0.2s;
|
|
84
|
+
}
|
|
85
|
+
.ea-switch_wrap.disabled {
|
|
86
|
+
cursor: not-allowed;
|
|
87
|
+
}
|
|
88
|
+
.ea-switch_wrap.disabled .ea-switch_label,
|
|
89
|
+
.ea-switch_wrap.disabled .ea-switch_core {
|
|
90
|
+
pointer-events: none;
|
|
91
|
+
}
|
|
92
|
+
`;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
.ea-tab_wrap {
|
|
2
|
+
--border-radius-top-left: 0;
|
|
3
|
+
--border-radius-top-right: 0;
|
|
4
|
+
--border-right-width: 0;
|
|
5
|
+
position: relative;
|
|
6
|
+
box-sizing: border-box;
|
|
7
|
+
padding: 0 1.25rem;
|
|
8
|
+
height: 40px;
|
|
9
|
+
line-height: 40px;
|
|
10
|
+
min-width: 1rem;
|
|
11
|
+
font-size: 14px;
|
|
12
|
+
font-weight: 500;
|
|
13
|
+
color: #303133;
|
|
14
|
+
white-space: nowrap;
|
|
15
|
+
overflow: hidden;
|
|
16
|
+
text-overflow: ellipsis;
|
|
17
|
+
cursor: pointer;
|
|
18
|
+
transition: color 0.3s, background-color 0.3s, width 0.3s, min-width 0.3s;
|
|
19
|
+
}
|
|
20
|
+
.ea-tab_wrap:hover {
|
|
21
|
+
color: #409eff;
|
|
22
|
+
}
|
|
23
|
+
.ea-tab_wrap.ea-tab_wrap--normal.is-actived {
|
|
24
|
+
color: #409eff;
|
|
25
|
+
}
|
|
26
|
+
.ea-tab_wrap.ea-tabs_wrap--card {
|
|
27
|
+
border-bottom: 1px solid #e4e7ed;
|
|
28
|
+
}
|
|
29
|
+
.ea-tab_wrap.ea-tabs_wrap--card .ea-tabs_tab-bottom-bar {
|
|
30
|
+
height: 1px;
|
|
31
|
+
bottom: -1px;
|
|
32
|
+
background-color: white;
|
|
33
|
+
}
|
|
34
|
+
.ea-tab_wrap.ea-tab_wrap--card {
|
|
35
|
+
border-top-left-radius: var(--border-radius-top-left);
|
|
36
|
+
border-top-right-radius: var(--border-radius-top-right);
|
|
37
|
+
border: 1px solid rgba(0, 0, 0, 0.1);
|
|
38
|
+
border-right-width: var(--border-right-width);
|
|
39
|
+
}
|
|
40
|
+
.ea-tab_wrap.ea-tab_wrap--card.is-actived {
|
|
41
|
+
border-bottom-color: white;
|
|
42
|
+
color: #409eff;
|
|
43
|
+
}
|
|
44
|
+
.ea-tab_wrap.ea-tab_wrap--border-card {
|
|
45
|
+
border-top-left-radius: var(--border-radius-top-left);
|
|
46
|
+
border-top-right-radius: var(--border-radius-top-right);
|
|
47
|
+
border: 0px solid rgba(0, 0, 0, 0.1);
|
|
48
|
+
border-right-width: var(--border-right-width);
|
|
49
|
+
}
|
|
50
|
+
.ea-tab_wrap.ea-tab_wrap--border-card.is-actived {
|
|
51
|
+
border-bottom-color: white;
|
|
52
|
+
color: #409eff;
|
|
53
|
+
background-color: white;
|
|
54
|
+
}
|
|
55
|
+
.ea-tab_wrap.ea-tab_wrap--editable .ea-tab_wrap--editable-sign {
|
|
56
|
+
display: block;
|
|
57
|
+
position: absolute;
|
|
58
|
+
right: 0;
|
|
59
|
+
top: 50%;
|
|
60
|
+
transform: translate(0, -50%);
|
|
61
|
+
user-select: none;
|
|
62
|
+
width: 0;
|
|
63
|
+
overflow: hidden;
|
|
64
|
+
transition: width 0.3s;
|
|
65
|
+
}
|
|
66
|
+
.ea-tab_wrap.ea-tab_wrap--editable:hover .ea-tab_wrap--editable-sign {
|
|
67
|
+
width: 14px;
|
|
68
|
+
}
|