MediaWiki:Discord.css

/* This would replace the iframe, so we reset most styles to do with box sizing, positioning, and text. */ /* I reduced it from a huge element list to a an ALL(*) selector because it mainly does the same thing, */ /* just that I had to add a div before the class so it would win the specificity war with other selectors */ div.discord-widget * { border: 0; font-family: inherit; font-size: 100%; font-style: inherit; font-weight: inherit; margin: 0; outline: 0; padding: 0; vertical-align: baseline; box-sizing: border-box; } .discord-widget-container a img { border: none; } /* Import fonts to be used in the widget */ @font-face { font-family: Whitney; font-style: normal; font-weight: 500; src: url(https://discordapp.com/assets/e8acd7d9bf6207f99350ca9f9e23b168.woff) format("woff"); } @font-face { font-family: Whitney; font-style: medium; font-weight: 600; src: url(https://discordapp.com/assets/3bdef1251a424500c1b3a78dea9b7e57.woff) format("woff"); } @font-face { font-family: Whitney; font-style: bold; font-weight: 700; src: url(https://discordapp.com/assets/8e12fb4f14d9c4592eb8ec9f22337b04.woff) format("woff"); } .discord-widget-container { background-color: transparent; line-height: 1; height: 400px; width: 280px; margin-right: 10px; } .discord-widget { bottom: 0; display: flex; font-family: Whitney, Helvetica Neue, Helvetica, Arial, sans-serif; font-size: 12px; height: 100%; width: 100%; overflow: hidden; } .discord-widget a { text-decoration: none; } .discord-widget strong, .discord-widget b { font-weight: 700; } .discord-widget .widget { border-radius: 5px; display: flex; flex: 1; flex-direction: column; overflow: hidden; } .discord-widget .widget-header { align-items: center; display: flex; flex-shrink: 0; padding: 20px; } .discord-widget .widget-logo { background: url(https://discordapp.com/assets/35d75407bd75d70e84e945c9f879bab8.svg) 50% no-repeat; background-size: 124px 34px; display: inline-block; height: 34px; transition: opacity .25s ease-out; width: 124px; } .discord-widget .widget-logo:hover { opacity: .6; } .discord-widget .widget-header .widget-header-count { flex: 1; text-align: right; margin-bottom: 4px; } .discord-widget .widget-footer { align-items: center; display: flex; flex-shrink: 0; min-height: 30px; padding: 6px 6px 6px 6px; } .discord-widget .widget-footer .widget-footer-info { font-weight: 500; word-break: break-word; padding: 6px; } /* Join button styles */ .discord-widget .widget-btn-connect { align-items: center; background-clip: padding-box; border-radius: 4px; display: flex; flex-shrink: 0; font-size: 12px; font-weight: 650; height: 33px; justify-content: center; opacity: 1; transition: ease-out 0.5s; min-width: 120px; margin-left: auto; padding: 12px; } .discord-widget .widget-btn-connect:hover { opacity: 1; transition: ease-in 0.2s; } .discord-widget .widget-body { position: relative; background-position: 0 100%, 100% 100%; background-repeat: no-repeat, no-repeat; background-size: 200px 180px, 110px 130px; flex: 1; overflow-x: hidden; overflow-y: auto; padding: 12px 8px; } /* Widget role container */ .discord-widget .widget-role-container { display: flex; flex-flow: row wrap; margin-top: 8px; } .discord-widget .widget-role-container:first-child { margin-top: 0; } .discord-widget .widget-role-container:last-child { margin-bottom: -16px; } /* Roles and members */ .discord-widget .widget-role-name { display: flex; flex: 1 1 100%; font-weight: 600; margin-bottom: 12px; text-transform: uppercase; width: 100%; } .discord-widget .widget-member { position: relative; width: auto; display: flex; align-items: center; flex: 0; margin: 6px 0; } .discord-widget .widget-member .widget-member-name { border-radius: 16px; display: none; font-weight: bold; height: 32px; max-width: 160px; overflow: hidden; line-height: 32px; padding: 0 8px 0 37px; pointer-events: none; position: absolute; text-overflow: ellipsis; top: 0; user-select: none; white-space: nowrap; z-index: 1; } .discord-widget .widget-member:hover .widget-member-name { display: block; } /* Float member names to the left when they're on the right side */ .discord-widget:not(.resolved-columns) .widget-member:nth-child(7n-1) .widget-member-name, .discord-widget:not(.resolved-columns) .widget-member:nth-child(7n) .widget-member-name, .discord-widget:not(.resolved-columns) .widget-member:nth-child(7n+1) .widget-member-name { padding: 0 32px 0 8px; right: 4px; } .discord-widget .widget-member-avatar { margin-right: 4px; position: relative; } .discord-widget .widget-member:hover .widget-member-avatar { z-index: 2; } .discord-widget .widget-member-avatar img { border-radius: 50%; height: 32px; width: 32px; } /* Statuses - colors aren't themed */ .discord-widget .widget-member-status { border-radius: 3px; bottom: 3px; height: 8px; position: absolute; right: 3px; width: 8px; } .discord-widget .widget-member-status-online { background-color: #43b581; } .discord-widget .widget-member-status-idle { background-color: #faa61a; } .discord-widget .widget-member-status-offline { background-color: #747f8d; } .discord-widget .widget-member-status-dnd { background-color: #f04747; } .discord-widget ::-webkit-scrollbar { width: 12px; } .discord-widget ::-webkit-scrollbar-thumb { background-clip: padding-box; border: 3px solid transparent; border-radius: 5px; } .discord-widget ::-webkit-scrollbar-track-piece { background-clip: padding-box; background-color: transparent; border: 3px solid transparent; border-radius: 5px; } /* Styles for template usage, used for pages that don't have a wikia rail */ .DiscordWidget .title-container h2 { border-bottom: 1px solid #cccccc; font-size: 16px; font-weight: bold; min-height: 30px; margin-bottom: 16px; padding-left: 2px; } .DiscordWidget .title-container h2.has-icon { display: flex; align-items: center; } .DiscordWidget .title-container h2.has-icon svg { margin-right: 7px; } /* User modal stuff */ text-align: center; width: 300px; }   display: flex; justify-content: center; }   width: 140px; height: 140px; border-radius: 50%; border: none; }   position: relative; }   margin-right: 0; display: block; right: 0; left: 0; }   font-size: 18px; font-weight: 600; }   font-size: 16px; font-weight: normal; }   margin-top: 6px; font-size: 14px; }   font-weight: 700; } /* Loading animation */ .discord-widget .widget-body.body-loading::before, .discord-widget .widget-body.body-loading::after { content: ''; position: absolute; height: 10px; width: 10px; top: calc(50% - 18px); left: calc(50% - 18px); animation: spinner-wandering-cubes 1.8s infinite ease-in-out; } .discord-widget .widget-body.body-loading::after { animation-delay: -.9s; } @keyframes spinner-wandering-cubes { 25% {       transform: translateX(22px) rotate(-90deg) scale(.5); }   50% {        transform: translateX(22px) translateY(22px) rotate(-180deg); }   75% {        transform: translateX(0) translateY(22px) rotate(-270deg) scale(.5); }   to { transform: rotate(-1turn); } } /* Theming */ /* Dark theme */ /* I'm pondering whether or not to fallback to dark like it always did, or leave the widget unstyled if there's an invalid theme supplied */ /* I'll leave the dark selectors out for now so it keeps on fallbacking */ .discord-widget { color: #fff; } .discord-widget a { color: #7289da; } .discord-widget .widget-header { background-color: #7289da; } .discord-widget .widget-body { background-color: #1e2124; background-image: url('https://discordapp.com/assets/319c6196da7ea2876ecf145b988e73a7.png'), url('https://discordapp.com/assets/8c7c66b44b1087f6ca9edc6cc1245bec.png'); box-shadow: 0 1px 0 rgba(0, 0, 0, .2); } .discord-widget .widget-role-name { color: #8a8e94; } .discord-widget .widget-member .widget-member-name { background-color: #7289da; color: #fff; } .discord-widget .widget-member-avatar img { border: 2px solid #7289da; /* There's sometimes a little space between the avatar and the border, so this property fills the gap */ background-color: #7289da; } .discord-widget .widget-footer { background-color: #1e2124; box-shadow: 0 -1px 18px rgba(0, 0, 0, .2), 0 -1px 0 rgba(0, 0, 0, .2); } .discord-widget .widget-footer .widget-footer-info { color: rgba(255, 255, 255, .7); } /* Join button */ .discord-widget .widget-btn-connect { color: #e1e1e1; background-color: rgba(255, 255, 255, .05); border: 1px solid #fff; } .discord-widget .widget-btn-connect:hover { opacity: .7; } /* For template usage */ .DiscordWidget .title-container h2.has-icon svg { fill: #7289da; } /* Scrollbars */ .discord-widget ::-webkit-scrollbar-thumb { background-color: rgba(255, 255, 255, .1); } /* User modal */ .discord-widget .widget-body.body-loading::before, .discord-widget .widget-body.body-loading::after { background-color: #7289da; }   color: rgba(0, 0, 0, .6); } /* Light theme */ .discord-widget .widget-theme-light .widget-footer .widget-footer-info a { /* TODO: Still has its roots in mlp, needs discordization */ color: #7289da; } .discord-widget .widget-theme-light .widget-role-name { color: #3a3a3a; } .discord-widget .widget-theme-light ::-webkit-scrollbar-thumb { background-color: #7289da; } .discord-widget .widget-theme-light .widget-body, .discord-widget .widget-theme-light .widget-footer { background-color: #f5f5f5; } .discord-widget .widget-theme-light .widget-body { background-image: url('https://discordapp.com/assets/319c6196da7ea2876ecf145b988e73a7.png'), url('https://discordapp.com/assets/8c7c66b44b1087f6ca9edc6cc1245bec.png'); } .discord-widget .widget-theme-light .widget-footer-info { color: rgba(0, 0, 0, .7); } /* Join button */ .discord-widget .widget-theme-light .widget-btn-connect { color: #3a3a3a; background-color: transparent; border: 1px solid #3a3a3a; } .discord-widget .widget-theme-light .widget-btn-connect:hover { opacity: .7; } /* Scrollbars */ .discord-widget .widget-theme-light ::-webkit-scrollbar-thumb { background-color: rgba(0, 0, 0, .1); }
 * 1) discord-member-modal {
 * 1) discord-member-modal .avatar-container {
 * 1) discord-member-modal .avatar {
 * 1) discord-member-modal .avatar-container .avatar-link {
 * 1) discord-member-modal > h1 {
 * 1) discord-member-modal .username {
 * 1) discord-member-modal .discriminator {
 * 1) discord-member-modal .playing {
 * 1) discord-member-modal .playing strong,
 * 2) discord-member-modal .playing b {
 * 1) discord-member-modal .avatar-container.loading .avatar-link::before,
 * 2) discord-member-modal .avatar-container.loading .avatar-link::after,
 * 1) discord-member-modal .avatar-container.loading .avatar-link::after,
 * 1) discord-member-modal .avatar-container.loading .avatar-link::before,
 * 2) discord-member-modal .avatar-container.loading .avatar-link::after,
 * 1) discord-member-modal .discriminator {