tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

fullscreen-and-pointerlock.css (2537B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this
      3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      4 
      5 :root[inDOMFullscreen] #navigator-toolbox,
      6 :root[inDOMFullscreen] #fullscr-toggler,
      7 :root[inDOMFullscreen] #sidebar-box,
      8 :root[inDOMFullscreen] #sidebar-main,
      9 :root[inDOMFullscreen] #sidebar-splitter,
     10 :root[inDOMFullscreen] #sidebar-launcher-splitter,
     11 :root[inFullscreen]:not([macOSNativeFullscreen]) toolbar:not([fullscreentoolbar="true"]) {
     12  visibility: collapse;
     13 }
     14 
     15 #fullscr-toggler {
     16  top: 0;
     17  left: 0;
     18  right: 0;
     19  height: 1px;
     20  position: fixed;
     21  z-index: 2147483647;
     22 }
     23 
     24 .pointerlockfswarning {
     25  will-change: translate;
     26  transition: translate 300ms ease-in;
     27  translate: 0 -100px;
     28 
     29  pointer-events: none;
     30  position: fixed;
     31  top: 0;
     32  bottom: auto;
     33 
     34  box-sizing: border-box;
     35  width: max-content;
     36  max-width: 95%;
     37 
     38  font: message-box;
     39 
     40  align-items: center;
     41  color-scheme: dark;
     42  background-color: rgba(45, 62, 72, 0.9);
     43  color: #fafafa;
     44  box-shadow: 0 0 5px 2px rgba(0, 0, 0, 0.5);
     45  border-radius: var(--border-radius-medium);
     46  border: 2px solid currentColor;
     47  padding: 24px 16px;
     48 
     49  @starting-style {
     50    translate: 0 -100px;
     51  }
     52 
     53  &:popover-open {
     54    display: flex;
     55  }
     56 
     57  &[onscreen] {
     58    translate: 0 50px;
     59  }
     60 
     61  &[ontop] {
     62    /* Use -10px to hide the border and border-radius on the top */
     63    translate: 0 -10px;
     64  }
     65 
     66  :root[macOSNativeFullscreen] &[ontop] {
     67    translate: 0 80px;
     68  }
     69 
     70  &:is([data-identity="verifiedDomain"], [data-identity="unknownIdentity"])::before {
     71    content: "";
     72    background-size: cover;
     73    margin: 0;
     74    width: 24px;
     75    height: 24px;
     76    -moz-context-properties: fill;
     77    fill: currentColor;
     78  }
     79 
     80  &[data-identity="verifiedDomain"]::before {
     81    background-image: url("chrome://global/skin/icons/security.svg");
     82  }
     83 
     84  &[data-identity="unknownIdentity"]::before {
     85    background-image: url("chrome://global/skin/icons/security-broken.svg");
     86  }
     87 }
     88 
     89 .pointerlockfswarning-domain-text,
     90 .pointerlockfswarning-generic-text {
     91  font-size: 21px;
     92  margin: 0 16px;
     93  word-wrap: break-word;
     94  /* We must specify a min-width, otherwise word-wrap:break-word doesn't work. Bug 630864. */
     95  min-width: 1px;
     96 }
     97 
     98 .pointerlockfswarning-domain-text:not([hidden]) + .pointerlockfswarning-generic-text {
     99  display: none;
    100 }
    101 
    102 .pointerlockfswarning-domain {
    103  font-weight: var(--font-weight-bold);
    104  margin: 0;
    105 }
    106 
    107 #fullscreen-exit-button {
    108  pointer-events: auto;
    109  margin: 0;
    110 }