UNPKG

@fe6/water-pro

Version:

An enterprise-class UI design language and Vue-based implementation

134 lines (117 loc) 3.02 kB
@import './variables.less'; .clearfix() { &::before, &::after { display: table; // 2 content: ' '; // 1 } &::after { clear: both; } } .@{prefixCls} { // Container that the rc-dialog scrolls within &-wrap { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: @zindex-modal; overflow: auto; // Prevent Chrome on Windows from adding a focus outline. For details, see // https://github.com/twbs/bootstrap/pull/10951. outline: 0; -webkit-overflow-scrolling: touch; } // Shell div to position the rc-dialog with bottom padding position: relative; width: auto; margin: 10px; // Actual rc-dialog &-content { position: relative; background-color: @modal-content-bg; background-clip: padding-box; border: 1px solid @modal-content-fallback-border-color; //old browsers fallback (ie8 etc) border: 1px solid @modal-content-border-color; border-radius: @border-radius-large; // Remove focus outline from opened rc-dialog outline: 0; box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); } // Modal header // Top section of the rc-dialog w/ title and dismiss &-header { padding: @modal-title-padding; border-bottom: 1px solid @modal-header-border-color; &:extend(.clearfix all); } &-close { position: absolute; top: 12px; right: 20px; color: #000; font-weight: 700; font-size: 21px; line-height: 1; text-decoration: none; text-shadow: 0 1px 0 #fff; background: transparent; border: 0; cursor: pointer; opacity: 0.2; filter: alpha(opacity=20); &-x::after { content: '×'; } &:hover { text-decoration: none; opacity: 1; filter: alpha(opacity=100); } } // Title text within header &-title { margin: 0; line-height: @modal-title-line-height; } // Modal body // Where all rc-dialog content resides (sibling of &-header and &-footer) &-body { position: relative; padding: @modal-inner-padding; } // Footer (for actions) &-footer { padding: @modal-inner-padding; text-align: right; // right align buttons border-top: 1px solid @modal-footer-border-color; &:extend(.clearfix all); // clear it in case folks use .pull-* classes on buttons // Properly space out buttons .btn + .btn { margin-bottom: 0; // account for input[type="submit"] which gets the bottom margin like all other inputs margin-left: 5px; } // but override that for button groups .btn-group .btn + .btn { margin-left: -1px; } // and override it for block buttons as well .btn-block + .btn-block { margin-left: 0; } } } // Scale up the rc-dialog @media (min-width: @screen-sm-min) { .@{prefixCls} { // Automatically set rc-dialog's width for larger viewports width: @modal-md; margin: 30px auto; &-content { box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); } } } @import './effect.less';