:root { --body-margin: 8px; /* Default value in browsers */ --max-font-size-unitless: 18; /* Measurements of the width of all columns except name and description on smaller screens */ --collapsed-static-column-width-px: 400px; --collapsed-static-column-width: calc( ( 400 / var(--max-font-size-unitless) ) * 1rem ); /* Measurements of the width of all columns except name and description on wider screens */ --expanded-static-column-width-px: 800px; --expanded-static-column-width: calc( ( 800 / var(--max-font-size-unitless) ) * 1rem ); /* Space left for the name and description columns, in the collapsed and expanded cases. */ --collapsed-dynamic-columns-width: calc( 100vw - var(--collapsed-static-column-width) - 2 * var(--body-margin); ); --expanded-dynamic-columns-width: calc( 100vw - var(--expanded-static-column-width) ); /* Default for wide screens. */ --dynamic-columns-width: var(--expanded-dynamic-columns-width); } html { font-size: clamp(10px, 2vw, var(--max-font-size-unitless) * 1px); } body { margin: 0; } #toggle-theme-switch { display: none; } #theming-root { width: 100%; height: 100%; margin: 0; background-color: var(--secondary-color); color: var(--primary-color); } #toggle-theme-switch:not(:checked) ~ #theming-root { --primary-color: hsl(0, 0%, 100%); --secondary-color: hsl(0, 0%, 0%); --secondary-color-heading: hsl(0, 0%, 17%); --secondary-color-shaded: hsl(0, 0%, 9%); --anchor-color: hsl(210, 100%, 60%); --color-http: hsl(0, 0%, 17%); --color-https: hsl(195, 53%, 21%); } #toggle-theme-switch:checked ~ #theming-root { --primary-color: hsl(0, 0%, 0%); --secondary-color: hsl(0, 0%, 100%); --secondary-color-heading: hsl(0, 0%, 83%); --secondary-color-shaded: hsl(0, 0%, 91%); --anchor-color: hsl(210, 100%, 40%); --color-http: hsl(0, 0%, 83%); --color-https: hsl(195, 53%, 79%) } a, .anchorstyle { color: var(--anchor-color); text-decoration: underline; cursor: pointer; } *, *::after, *::before { transition: color 3s, background-color 2s; } html.js .noscript, .hidden { display: none; } html:not(.js) .js-only { display: none; } header { display: flex; direction: row; /* Push items as far apart as possible */ justify-content: space-between; padding-top: var(--body-margin); padding-inline: var(--body-margin); } #header-start, #header-end { display: flex; gap: 0.5em; } #headline { text-align: center; flex-grow: 1; } /* --- Table --- */ #tbl_communities { margin: 0 auto; --cell-padding-h: 0.5em; --cell-padding-v: 0.5em; --cell-padding: var(--cell-padding-h) var(--cell-padding-v); --cell-padding-small: calc( var(--cell-padding-h) / 2 ) calc( var(--cell-padding-v) / 2 ); } /* Cells in general */ #tbl_communities th { white-space: nowrap; } #tbl_communities :is(th, td) { padding: var(--cell-padding-v) var(--cell-padding-h); } #tbl_communities th.sortable { position: relative; padding-right: calc( 1.35em + var(--cell-padding-h) ); } #tbl_communities th.sortable::after { position: absolute; right: calc( var(--cell-padding-h) ); top: 50%; transform: translateY(-50%); /* content: "\25C7"; */ /* White diamond */ /* content: "\2195"; */ /* Up-down arrow */ /* content: "\25A1"; */ /* White square */ /* content: "\25B8"; */ /* Small right pointing triangle */ content: "\2B25"; /* Black medium diamond */ color: grey; font-size: 1.3em; } #tbl_communities[data-sort-asc=true] th[data-sort=true]::after { content: "\25B2"; /* Black up pointing triangle */ color: initial; font-size: 1em; } #tbl_communities[data-sort-asc=false] th[data-sort=true]::after { content: "\25BC"; /* Black up pointing triangle */ color: initial; font-size: 1em; } #toggle-show-room-ids:not(:checked) ~ #tbl_communities :is(#th_identifier, .td_identifier) { display: none; } #tbl_communities th { background-color: var(--secondary-color-heading); } #tbl_communities tr { background-color: var(--row-color); } #tbl_communities tr:nth-child(even) { background-color: var(--secondary-color); --row-color: var(--secondary-color); } #tbl_communities tr:nth-child(odd) { background-color: var(--secondary-color-shaded); --row-color: var(--secondary-color-shaded); } /* Particular columns */ .td_identifier { font-family: monospace; } #th_name, .td_name { width: calc( 0.375 * ( var(--dynamic-columns-width) ) ); max-width: calc( 0.375 * ( var(--dynamic-columns-width) ) ); overflow: hidden; text-overflow: ellipsis; } .td_language { text-align: center; font-size: 1.5em; } .td_language:empty::after { content: "\2753"; } .td_description { position: relative; overflow: hidden; text-overflow: ellipsis; /* Prevents middle alignment with table-cell. */ display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; } #th_description, .td_description { width: calc( 0.625 * ( var(--dynamic-columns-width) ) ); max-width: calc( 0.625 * ( var(--dynamic-columns-width) ) ); } .td_description::after { /* Cover overflowing description lines with internal border. */ position: absolute; bottom: 0; left: 0; width: 100%; height: var(--cell-padding-h); content: ""; background-color: var(--row-color); } .td_users { text-align: center; /* font-weight: bold; */ } .td_preview { text-align: center; } .protocol-indicator { display: inline-block; font-family: monospace; border-radius: 4px; padding: .25em .05em; width: 6ch; text-align: center; text-shadow: 0 0 0.5em #0003; } a[href^="http:"] .protocol-indicator { background-color: var(--color-http); } a[href^="https:"] .protocol-indicator { background-color: var(--color-https); } a[href^="http:"] .protocol-indicator::after { content: "HTTP"; } a[href^="https:"] .protocol-indicator::after { content: "HTTPS"; } .td_qr_code { padding: var(--cell-padding-small) !important; } .td_server_icon { text-align: center; padding: var(--cell-padding-small) !important; font-size: 1.1em; } .td_server_icon-circle { display: flex; align-items: center; justify-content: center; width: 2em; height: 2em; border-radius: 100%; font-family: sans-serif; margin: 0 auto; color: white; text-shadow: 0 0 0.25em #000a; box-shadow: 0 0 0.05em #777; } .td_server_icon-circle span { position: relative; top: 0.05em; } .td_join_url { font-family: monospace; white-space: nowrap; font-size: .8em; } .join_url { overflow: hidden; text-overflow: ellipsis; max-width: 20vw; /* Apply margin against copy button or link. */ /* URL now guaranteed to have interactive element to right when present. */ margin-right: 1em; } @media (max-width: 1050px) { /* Only current width breakpoint; */ /* Would follow w4 and precede w6. */ .show-from-w5 { display: none; } #th_preview, .td_preview { display: none; } :root { --dynamic-columns-width: var(--collapsed-dynamic-columns-width); } } @media (max-width: 500px) { :root { /* ! For when descriptions don't wrap and 100vw doesn't work. */ --dynamic-columns-width: 15rem; } } .join_url_container { display: flex; flex-direction: row; align-items: center; justify-content: space-around; } .copy_button { font-size: 1.1em; background-color: var(--secondary-color); color: var(--primary-color); padding: var(--cell-padding); border-radius: 10%; } /* --- Footer --- */ footer { display: flex; flex-direction: column; align-items: center; max-width: 100%; text-align: center; padding-bottom: var(--body-margin); padding-inline: var(--body-margin); } footer p { width: 75%; margin: .5em; text-align: center; } footer nav a { display: inline-block; margin: .25em; white-space: nowrap; } label[for=toggle-show-room-ids]::after { content: " (Off)" } #toggle-show-room-ids:checked ~ footer label[for=toggle-show-room-ids]::after { content: " (On)" } /* --- QR code modals --- */ .qr-code { display: block; margin-left: auto; margin-right: auto; width: 50%; } .qr-code-icon { cursor: pointer; } .qr-code-modal { display: none; /* Hidden by default */ position: fixed; /* Stay in place */ z-index: 1; /* Sit on top */ left: 0; top: 0; width: 100%; /* Full width */ height: 100%; /* Full height */ padding-top: 100px; /* Location of the box */ background-color: rgb(0,0,0); /* Fallback color */ background-color: rgba(0,0,0,0.4); /* Black w/ opacity */ /*overflow: auto;*/ /* Enable scroll if needed */ } .qr-code-modal-content { background-color: #ffffff; border: 1px solid #000000; width: 80%; margin: auto; padding: 20px; } .qr-code-modal-close { float: right; font-size: 35px; font-weight: bold; color: #aaaaaa; } .qr-code-modal-close:hover, .qr-code-modal-close:focus { cursor: pointer; text-decoration: none; color: #000000; } /* */ /* The snackbar - position it at the bottom and in the middle of the screen */ #copy-snackbar { visibility: hidden; /* Hidden by default. Visible on click */ background-color: #333; /* Black background color */ color: #fff; /* White text color */ text-align: center; /* Centered text */ border-radius: 2px; /* Rounded corners */ padding: 16px; position: fixed; /* Move along as viewport scrolls */ z-index: 1; /* Add a z-index if needed */ left: 50%; /* Offset the snackbar by half the viewport width */ transform: translateX(-50%); /* Push the snackbar back by half its width */ bottom: 30px; /* 30px from the bottom */ } /* Show the snackbar when clicking on a button (class added with JavaScript) */ #copy-snackbar.show { visibility: visible; /* Show the snackbar */ /* Add animation: Take 0.5 seconds to fade in and out the snackbar. However, delay the fade out process for 2.5 seconds */ -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s; animation: fadein 0.5s, fadeout 0.5s 2.5s; } /* Animations to fade the snackbar in and out */ @-webkit-keyframes fadein { from {bottom: 0; opacity: 0;} to {bottom: 30px; opacity: 1;} } @keyframes fadein { from {bottom: 0; opacity: 0;} to {bottom: 30px; opacity: 1;} } @-webkit-keyframes fadeout { from {bottom: 30px; opacity: 1;} to {bottom: 0; opacity: 0;} } @keyframes fadeout { from {bottom: 30px; opacity: 1;} to {bottom: 0; opacity: 0;} }