UNPKG

acud

Version:

acg react 组件库

264 lines (263 loc) • 5.98 kB
/* color */ /* 默认颜色 */ /* 通用-icon */ /* 标签 */ /* 默认颜色 */ /* 其他颜色 */ /* 通用 */ /* 水平 */ /* 垂直 */ /* 序号水平 */ /* 序号垂直 */ .acud-drawer { position: fixed; z-index: 1000; width: 0%; height: 100%; transition: transform 0.3s cubic-bezier(0.7, 0.3, 0.1, 1), height 0s ease 0.3s, width 0s ease 0.3s; outline: none; } .acud-drawer > * { transition: transform 0.3s cubic-bezier(0.7, 0.3, 0.1, 1), box-shadow 0.3s cubic-bezier(0.7, 0.3, 0.1, 1); } .acud-drawer-content-wrapper { position: absolute; width: 100%; height: 100%; overflow: hidden; } .acud-drawer-left, .acud-drawer-right { top: 0; width: 0%; height: 100%; } .acud-drawer-left .acud-drawer-content-wrapper, .acud-drawer-right .acud-drawer-content-wrapper { height: 100%; } .acud-drawer-left.acud-drawer-open, .acud-drawer-right.acud-drawer-open { width: 100%; transition: transform 0.3s cubic-bezier(0.7, 0.3, 0.1, 1); } .acud-drawer-left { left: 0; } .acud-drawer-left .acud-drawer-content-wrapper { left: 0; } .acud-drawer-left.acud-drawer-open .acud-drawer-content-wrapper { box-shadow: 0px 4px 12px 1px rgba(7, 12, 20, 0.12); } .acud-drawer-right { right: 0; } .acud-drawer-right .acud-drawer-content-wrapper { right: 0; } .acud-drawer-right.acud-drawer-open .acud-drawer-content-wrapper { box-shadow: 0px 4px 12px 1px rgba(7, 12, 20, 0.12); } .acud-drawer-right.acud-drawer-open.no-mask { right: 1px; transform: translateX(1px); } .acud-drawer-top, .acud-drawer-bottom { left: 0; width: 100%; height: 0%; } .acud-drawer-top .acud-drawer-content-wrapper, .acud-drawer-bottom .acud-drawer-content-wrapper { width: 100%; } .acud-drawer-top.acud-drawer-open, .acud-drawer-bottom.acud-drawer-open { height: 100%; transition: transform 0.3s cubic-bezier(0.7, 0.3, 0.1, 1); } .acud-drawer-top { top: 0; } .acud-drawer-top.acud-drawer-open .acud-drawer-content-wrapper { box-shadow: 0px 4px 12px 1px rgba(7, 12, 20, 0.12); } .acud-drawer-bottom { bottom: 0; } .acud-drawer-bottom .acud-drawer-content-wrapper { bottom: 0; } .acud-drawer-bottom.acud-drawer-open .acud-drawer-content-wrapper { box-shadow: 0px 4px 12px 1px rgba(7, 12, 20, 0.12); } .acud-drawer-bottom.acud-drawer-open.no-mask { bottom: 1px; transform: translateY(1px); } .acud-drawer.acud-drawer-open .acud-drawer-mask { height: 100%; opacity: 1; transition: none; animation: acudDrawerFadeIn 0.3s cubic-bezier(0.7, 0.3, 0.1, 1); pointer-events: auto; } .acud-drawer-title { display: inline-block; vertical-align: middle; font-size: 16px; color: #151B26; margin: 0; font-weight: 500; line-height: 24px; } .acud-drawer .acud-drawer-back { height: 16px; vertical-align: middle; cursor: pointer; font-size: 16px; transition: color 0.3s; color: #84868C; margin-right: 4px; } .acud-drawer .acud-drawer-back:hover { color: #2468F2; } .acud-drawer .acud-drawer-back:focus, .acud-drawer .acud-drawer-back:active { color: #144BCC; } .acud-drawer .acud-drawer-back[disabled], .acud-drawer .acud-drawer-back[aria-disabled="true"], .acud-drawer .acud-drawer-back[disabled]:hover, .acud-drawer .acud-drawer-back[aria-disabled="true"]:hover, .acud-drawer .acud-drawer-back[disabled]:focus, .acud-drawer .acud-drawer-back[aria-disabled="true"]:focus, .acud-drawer .acud-drawer-back[disabled]:active, .acud-drawer .acud-drawer-back[aria-disabled="true"]:active { color: #B8BABF; } .acud-drawer .acud-drawer-back svg { vertical-align: top; } .acud-drawer-content { width: 100%; height: 100%; position: relative; z-index: 1; overflow: auto; background-color: #fff; background-clip: padding-box; border: 0; } .acud-drawer-close { position: absolute; top: 0; right: 0; z-index: 10; display: block; padding: 20px 16px; font-weight: 700; font-size: 14px; font-style: normal; line-height: 1; text-align: center; text-transform: none; text-decoration: none; background: transparent; border: 0; outline: 0; cursor: pointer; transition: color 0.3s; text-rendering: auto; --scroll-bar: 0; color: #84868C; } .acud-drawer-close:hover { color: #5C5F66; } .acud-drawer-close:focus, .acud-drawer-close:active { color: #303540; } .acud-drawer-close[disabled], .acud-drawer-close[aria-disabled="true"], .acud-drawer-close[disabled]:hover, .acud-drawer-close[aria-disabled="true"]:hover, .acud-drawer-close[disabled]:focus, .acud-drawer-close[aria-disabled="true"]:focus, .acud-drawer-close[disabled]:active, .acud-drawer-close[aria-disabled="true"]:active { color: #B8BABF; } .acud-drawer-header-no-title .acud-drawer-close { margin-right: var(--scroll-bar); /* stylelint-disable-next-line function-calc-no-invalid */ padding-right: calc(17px - var(--scroll-bar)); } .acud-drawer-header { position: relative; padding: 16px 24px; color: #151B26; height: 56px; background: #fff; border-bottom: 1px solid #F2F2F4; border-radius: 0; } .acud-drawer-header + .acud-drawer-body { padding-top: 24px; } .acud-drawer-header-no-title { color: #151B26; background: #fff; } .acud-drawer-wrapper-body { display: flex; flex-direction: column; flex-wrap: nowrap; width: 100%; height: 100%; } .acud-drawer-body { flex-grow: 1; padding: 16px 24px; overflow: auto; font-size: 14px; color: #151B26; font-weight: 400; line-height: 20px; word-wrap: break-word; } .acud-drawer-footer { flex-shrink: 0; padding: 16px 24px; border-top: 1px solid #F2F2F4; } .acud-drawer-mask { position: absolute; top: 0; left: 0; width: 100%; height: 0; background-color: rgba(0, 0, 0, 0.5); opacity: 0; filter: alpha(opacity=45); transition: opacity 0.3s linear, height 0s ease 0.3s; pointer-events: none; } .acud-drawer-open-content { box-shadow: 0px 4px 12px 1px rgba(7, 12, 20, 0.12); } .acud-drawer-footer { height: 64px; } @keyframes acudDrawerFadeIn { 0% { opacity: 0; } 100% { opacity: 1; } }