UNPKG

zent

Version:

一套前端设计语言和基于React的实现

258 lines (249 loc) 8.2 kB
.zent-alert { border-style: solid; border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-width: 1px; position: relative; overflow: hidden; background-repeat: no-repeat; background-size: cover; background-position: center center; padding: 14px 16px; border-radius: 2px; } .zent-alert-outline { border-radius: 4px; } .zent-alert--borderless { border: none; } .zent-alert__progress.zent-progress { width: 100%; position: absolute; top: 0; left: 0; } .zent-alert__progress.zent-progress .zent-progress-wrapper { background-color: transparent; } .zent-alert-scroll { border-style: solid; border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-width: 1px; border-radius: 2px; height: -webkit-min-content; height: min-content; box-sizing: border-box; overflow: hidden; position: relative; } .zent-alert-scroll--borderless { border: none; } .zent-alert-scroll .zent-alert-scroll-container { padding: 12px 16px; transition-timing-function: ease-in-out; } .zent-alert-scroll .zent-alert-item { transform: translateY(0); opacity: 0; transition: opacity 0.6s ease-in-out; } .zent-alert-scroll .zent-alert-scroll-active-item { opacity: 1; } .zent-alert-scroll .zent-alert-scroll-virtual-item { opacity: 1; } .zent-alert-scroll-outline { border-radius: 4px; } .zent-alert-item { font-size: 14px; line-height: 20px; color: #333; color: var(--theme-title-color, var(--theme-stroke-1, #333)); box-sizing: border-box; display: flex; } .zent-alert-item .zenticon { font-size: 16px; } .zent-alert-item-content { flex: 1 1 auto; } .zent-alert-item-content__highlight { font-weight: 500; } .zent-alert-item-content__title { font-weight: 500; } .zent-alert-item-content__title + .zent-alert-item-content__description { margin-top: 8px; } .zent-alert-item-close-wrapper { margin-left: 16px; cursor: pointer; height: 20px; } .zent-alert-item-close-wrapper .zent-alert-item-close-btn { color: #999; color: var(--theme-hint-color, var(--theme-stroke-3, #999)); font-size: 18px; width: 16px; height: 20px; line-height: 20px; text-align: center; } .zent-alert-item-extra-content { margin: -6px 0 -6px 16px; align-items: center; display: flex; flex: 0 0 auto; } .zent-alert-item-icon, .zent-alert-item-custom-icon { margin-right: 8px; } .zent-alert-item-icon.zenticon, .zent-alert-item-icon .zent-loading-icon-and-text, .zent-alert-item-custom-icon.zenticon, .zent-alert-item-custom-icon .zent-loading-icon-and-text { width: 16px; height: 20px; line-height: 20px; } .zent-alert-style-info { background-color: #e6efff; background-color: var(--theme-default-selected-bg, var(--theme-primary-8, #e6efff)); border-color: #356fd4; border-color: var(--theme-primary-hover-bg, var(--theme-primary-7, #356fd4)); } .zent-alert-style-info .zent-alert-item-content__highlight { color: #155bd4; color: var(--theme-primary-bg, var(--theme-primary-4, #155bd4)); } .zent-alert-style-info.zent-alert-outline, .zent-alert-style-info.zent-alert-scroll-outline { background-color: #fff; background-color: var(--theme-section-bg, var(--theme-stroke-9, #fff)); border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-top-color: #155bd4; border-top-color: var(--theme-primary-bg, var(--theme-primary-4, #155bd4)); border-width: 1px; border-style: solid; border-top-width: 4px; } .zent-alert-style-info.zent-alert-outline .zent-alert-item-content__title, .zent-alert-style-info.zent-alert-scroll-outline .zent-alert-item-content__title { color: #155bd4; color: var(--theme-primary-bg, var(--theme-primary-4, #155bd4)); } .zent-alert-style-info .zent-alert-item-icon { color: #155bd4; color: var(--theme-primary-bg, var(--theme-primary-4, #155bd4)); } .zent-alert-style-success { background-color: #efffe6; background-color: var(--theme-success-bg, var(--theme-success-5, #efffe6)); border-color: #45a110; border-color: var(--theme-success-color, var(--theme-success-4, #45a110)); } .zent-alert-style-success .zent-alert-item-content__highlight { color: #45a110; color: var(--theme-success-color, var(--theme-success-2, #45a110)); } .zent-alert-style-success.zent-alert-outline, .zent-alert-style-success.zent-alert-scroll-outline { background-color: #fff; background-color: var(--theme-section-bg, var(--theme-stroke-9, #fff)); border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-top-color: #45a110; border-top-color: var(--theme-success-color, var(--theme-success-2, #45a110)); border-width: 1px; border-style: solid; border-top-width: 4px; } .zent-alert-style-success.zent-alert-outline .zent-alert-item-content__title, .zent-alert-style-success.zent-alert-scroll-outline .zent-alert-item-content__title { color: #45a110; color: var(--theme-success-color, var(--theme-success-2, #45a110)); } .zent-alert-style-success .zent-alert-item-icon { color: #45a110; color: var(--theme-success-color, var(--theme-success-2, #45a110)); } .zent-alert-style-warning { background-color: #ffefe6; background-color: var(--theme-warning-bg, var(--theme-warn-5, #ffefe6)); border-color: #ed6a18; border-color: var(--theme-warning-color, var(--theme-warn-4, #ed6a18)); } .zent-alert-style-warning .zent-alert-item-content__highlight { color: #ed6a18; color: var(--theme-warning-color, var(--theme-warn-2, #ed6a18)); } .zent-alert-style-warning.zent-alert-outline, .zent-alert-style-warning.zent-alert-scroll-outline { background-color: #fff; background-color: var(--theme-section-bg, var(--theme-stroke-9, #fff)); border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-top-color: #ed6a18; border-top-color: var(--theme-warning-color, var(--theme-warn-2, #ed6a18)); border-width: 1px; border-style: solid; border-top-width: 4px; } .zent-alert-style-warning.zent-alert-outline .zent-alert-item-content__title, .zent-alert-style-warning.zent-alert-scroll-outline .zent-alert-item-content__title { color: #ed6a18; color: var(--theme-warning-color, var(--theme-warn-2, #ed6a18)); } .zent-alert-style-warning .zent-alert-item-icon { color: #ed6a18; color: var(--theme-warning-color, var(--theme-warn-2, #ed6a18)); } .zent-alert-style-error { background-color: #ffe9e6; background-color: var(--theme-danger-bg, var(--theme-error-5, #ffe9e6)); border-color: #d42f15; border-color: var(--theme-danger-color, var(--theme-error-4, #d42f15)); } .zent-alert-style-error .zent-alert-item-content__highlight { color: #d42f15; color: var(--theme-danger-color, var(--theme-error-2, #d42f15)); } .zent-alert-style-error.zent-alert-outline, .zent-alert-style-error.zent-alert-scroll-outline { background-color: #fff; background-color: var(--theme-section-bg, var(--theme-stroke-9, #fff)); border-color: #e0e0e0; border-color: var(--theme-default-border-color, var(--theme-stroke-5, #e0e0e0)); border-top-color: #d42f15; border-top-color: var(--theme-danger-color, var(--theme-error-2, #d42f15)); border-width: 1px; border-style: solid; border-top-width: 4px; } .zent-alert-style-error.zent-alert-outline .zent-alert-item-content__title, .zent-alert-style-error.zent-alert-scroll-outline .zent-alert-item-content__title { color: #d42f15; color: var(--theme-danger-color, var(--theme-error-2, #d42f15)); } .zent-alert-style-error .zent-alert-item-icon { color: #d42f15; color: var(--theme-danger-color, var(--theme-error-2, #d42f15)); } .zent-alert-style-hint { background-color: #f7f7f7; background-color: var(--theme-body-bg, var(--theme-stroke-8, #f7f7f7)); border: 0; padding: 13px 16px; } .zent-alert-style-hint .zent-alert-item-content { font-size: 12px; line-height: 20px; } .zent-banner .zent-alert-item-close-wrapper { position: relative; } .zent-banner .zent-alert-item-close-wrapper .zent-alert-item-close-btn { position: absolute; top: 50%; right: 0; transform: translateY(-50%); }