responsivedesign.inc.css 9.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356
  1. %if 0
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. %endif
  6. /* Responsive Mode */
  7. .browserContainer[responsivemode] {
  8. background-color: #222;
  9. padding: 0 20px 20px 20px;
  10. }
  11. .browserStack[responsivemode] {
  12. box-shadow: 0 0 7px black;
  13. }
  14. .devtools-responsiveui-toolbar {
  15. -moz-appearance: none;
  16. background: transparent;
  17. /* text color is textColor from dark theme, since no theme is applied to
  18. * the responsive toolbar.
  19. */
  20. color: hsl(210,30%,85%);
  21. margin: 10px 0;
  22. padding: 0;
  23. box-shadow: none;
  24. border-bottom-width: 0;
  25. }
  26. .devtools-responsiveui-textinput {
  27. -moz-appearance: none;
  28. background: #333;
  29. color: #fff;
  30. border: 1px solid #111;
  31. border-radius: 2px;
  32. padding: 0 5px;
  33. width: 200px;
  34. margin: 0;
  35. }
  36. .devtools-responsiveui-textinput[attention] {
  37. border-color: #38ace6;
  38. background: rgba(56,172,230,0.4);
  39. }
  40. .devtools-responsiveui-menulist,
  41. .devtools-responsiveui-toolbarbutton {
  42. -moz-appearance: none;
  43. -moz-box-align: center;
  44. min-width: 32px;
  45. min-height: 22px;
  46. text-shadow: 0 -1px 0 hsla(210,8%,5%,.45);
  47. border: 1px solid hsla(210,8%,5%,.45);
  48. border-radius: 0;
  49. background: linear-gradient(hsla(212,7%,57%,.35), hsla(212,7%,57%,.1)) padding-box;
  50. box-shadow: 0 1px 0 hsla(210,16%,76%,.15) inset, 0 0 0 1px hsla(210,16%,76%,.15) inset, 0 1px 0 hsla(210,16%,76%,.15);
  51. margin: 0 3px;
  52. color: inherit;
  53. }
  54. .devtools-responsiveui-menulist .menulist-editable-box {
  55. -moz-appearance: none;
  56. background-color: transparent;
  57. }
  58. .devtools-responsiveui-menulist html|*.menulist-editable-input {
  59. -moz-appearance: none;
  60. color: inherit;
  61. text-align: center;
  62. }
  63. .devtools-responsiveui-menulist html|*.menulist-editable-input::-moz-selection {
  64. background: hsla(212,7%,57%,.35);
  65. }
  66. .devtools-responsiveui-toolbarbutton > .toolbarbutton-icon {
  67. width: 16px;
  68. height: 16px;
  69. }
  70. .devtools-responsiveui-toolbarbutton > .toolbarbutton-menubutton-button {
  71. -moz-box-orient: horizontal;
  72. }
  73. .devtools-responsiveui-menulist:-moz-focusring,
  74. .devtools-responsiveui-toolbarbutton:-moz-focusring {
  75. outline: 1px dotted hsla(210,30%,85%,0.7);
  76. outline-offset: -4px;
  77. }
  78. .devtools-responsiveui-toolbarbutton:not([label]) > .toolbarbutton-text {
  79. display: none;
  80. }
  81. .devtools-responsiveui-toolbarbutton:not([checked=true]):hover:active {
  82. border-color: hsla(210,8%,5%,.6);
  83. background: linear-gradient(hsla(220,6%,10%,.3), hsla(212,7%,57%,.15) 65%, hsla(212,7%,57%,.3));
  84. box-shadow: 0 0 3px hsla(210,8%,5%,.25) inset, 0 1px 3px hsla(210,8%,5%,.25) inset, 0 1px 0 hsla(210,16%,76%,.15);
  85. }
  86. .devtools-responsiveui-menulist[open=true],
  87. .devtools-responsiveui-toolbarbutton[open=true],
  88. .devtools-responsiveui-toolbarbutton[checked=true] {
  89. border-color: hsla(210,8%,5%,.6) !important;
  90. background: linear-gradient(hsla(220,6%,10%,.6), hsla(210,11%,18%,.45) 75%, hsla(210,11%,30%,.4));
  91. box-shadow: 0 1px 3px hsla(210,8%,5%,.25) inset, 0 1px 3px hsla(210,8%,5%,.25) inset, 0 1px 0 hsla(210,16%,76%,.15);
  92. }
  93. .devtools-responsiveui-toolbarbutton[checked=true] {
  94. color: hsl(208,100%,60%);
  95. }
  96. .devtools-responsiveui-toolbarbutton[checked=true]:hover {
  97. background-color: transparent !important;
  98. }
  99. .devtools-responsiveui-toolbarbutton[checked=true]:hover:active {
  100. background-color: hsla(210,8%,5%,.2) !important;
  101. }
  102. .devtools-responsiveui-menulist > .menulist-label-box {
  103. text-align: center;
  104. }
  105. .devtools-responsiveui-menulist > .menulist-dropmarker {
  106. -moz-appearance: none;
  107. display: -moz-box;
  108. background-color: transparent;
  109. list-style-image: url("chrome://devtools/skin/images/dropmarker.svg");
  110. -moz-box-align: center;
  111. border-width: 0;
  112. min-width: 16px;
  113. }
  114. .devtools-responsiveui-toolbarbutton[type=menu-button] > .toolbarbutton-menubutton-button {
  115. -moz-appearance: none;
  116. color: inherit;
  117. border-width: 0;
  118. border-inline-end: 1px solid hsla(210,8%,5%,.45);
  119. box-shadow: -1px 0 0 hsla(210,16%,76%,.15) inset, 1px 0 0 hsla(210,16%,76%,.15);
  120. }
  121. .devtools-responsiveui-toolbarbutton[type=menu-button]:-moz-locale-dir(rtl) > .toolbarbutton-menubutton-button {
  122. box-shadow: 1px 0 0 hsla(210,16%,76%,.15) inset, -1px 0 0 hsla(210,16%,76%,.15);
  123. }
  124. .devtools-responsiveui-toolbarbutton[type=menu-button] {
  125. padding: 0 1px;
  126. -moz-box-align: stretch;
  127. }
  128. .devtools-responsiveui-toolbarbutton[type=menu] > .toolbarbutton-menu-dropmarker,
  129. .devtools-responsiveui-toolbarbutton[type=menu-button] > .toolbarbutton-menubutton-dropmarker {
  130. -moz-appearance: none !important;
  131. list-style-image: url("chrome://devtools/skin/images/dropmarker.svg");
  132. -moz-box-align: center;
  133. padding: 0 3px;
  134. }
  135. .devtools-responsiveui-toolbar:-moz-locale-dir(ltr) > *:first-child,
  136. .devtools-responsiveui-toolbar:-moz-locale-dir(rtl) > *:last-child {
  137. margin-left: 0;
  138. }
  139. .devtools-responsiveui-close {
  140. list-style-image: url("chrome://devtools/skin/images/close.svg");
  141. }
  142. .devtools-responsiveui-close > image {
  143. filter: invert(1);
  144. }
  145. .devtools-responsiveui-rotate {
  146. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-rotate.png");
  147. }
  148. @media (min-resolution: 1.1dppx) {
  149. .devtools-responsiveui-rotate {
  150. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-rotate@2x.png");
  151. }
  152. }
  153. .devtools-responsiveui-touch {
  154. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-touch.png");
  155. -moz-image-region: rect(0px,16px,16px,0px);
  156. }
  157. .devtools-responsiveui-touch[checked] {
  158. -moz-image-region: rect(0px,32px,16px,16px);
  159. }
  160. @media (min-resolution: 1.1dppx) {
  161. .devtools-responsiveui-touch {
  162. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-touch@2x.png");
  163. -moz-image-region: rect(0px,32px,32px,0px);
  164. }
  165. .devtools-responsiveui-touch[checked] {
  166. -moz-image-region: rect(0px,64px,32px,32px);
  167. }
  168. }
  169. .devtools-responsiveui-screenshot {
  170. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-screenshot.png");
  171. }
  172. @media (min-resolution: 1.1dppx) {
  173. .devtools-responsiveui-screenshot {
  174. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-screenshot@2x.png");
  175. }
  176. }
  177. .devtools-responsiveui-resizebarV {
  178. width: 7px;
  179. height: 24px;
  180. cursor: ew-resize;
  181. transform: translate(12px, -12px);
  182. background-size: cover;
  183. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-vertical-resizer.png");
  184. }
  185. .devtools-responsiveui-resizebarH {
  186. width: 24px;
  187. height: 7px;
  188. cursor: ns-resize;
  189. transform: translate(-12px, 12px);
  190. background-size: cover;
  191. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-horizontal-resizer.png");
  192. }
  193. .devtools-responsiveui-resizehandle {
  194. width: 16px;
  195. height: 16px;
  196. cursor: se-resize;
  197. transform: translate(12px, 12px);
  198. background-size: cover;
  199. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-se-resizer.png");
  200. }
  201. /* FxOS custom mode with additional buttons and phone look'n feel */
  202. /* Hide devtools manual resizer */
  203. .browserStack[responsivemode].fxos-mode .devtools-responsiveui-resizehandle,
  204. .browserStack[responsivemode].fxos-mode .devtools-responsiveui-resizebarH,
  205. .browserStack[responsivemode].fxos-mode .devtools-responsiveui-resizebarV {
  206. display: none;
  207. }
  208. /* Gives responsive mode a phone look'n feel */
  209. .browserStack[responsivemode].fxos-mode {
  210. padding: 60px 15px 0;
  211. border-radius: 25px / 20px;
  212. border-bottom-left-radius: 0;
  213. border-bottom-right-radius: 0;
  214. border: 1px solid #FFFFFF;
  215. border-bottom-width: 0;
  216. background-color: #353535;
  217. box-shadow: 0 3px 0.7px 1px #777777, 0 5px rgba(0, 0, 0, 0.4) inset;
  218. background-image: linear-gradient(to right, #111 11%, #333 56%);
  219. min-width: 320px;
  220. }
  221. .devtools-responsiveui-hardware-buttons {
  222. -moz-appearance: none;
  223. padding: 20px;
  224. border: 1px solid #FFFFFF;
  225. border-bottom-left-radius: 25px;
  226. border-bottom-right-radius: 25px;
  227. border-top-width: 0;
  228. box-shadow: 0 3px 0.7px 1px #777777, 0 -7px rgba(0, 0, 0, 0.4) inset;
  229. background-image: linear-gradient(to right, #111 11%, #333 56%);
  230. }
  231. .devtools-responsiveui-home-button {
  232. -moz-user-focus: ignore;
  233. width: 40px;
  234. height: 30px;
  235. list-style-image: url("chrome://devtools/skin/images/responsivemode/responsiveui-home.png");
  236. }
  237. .devtools-responsiveui-sleep-button {
  238. -moz-user-focus: ignore;
  239. -moz-appearance: none;
  240. /* compensate browserStack top padding */
  241. margin-top: -67px;
  242. margin-right: 10px;
  243. min-width: 10px;
  244. width: 50px;
  245. height: 5px;
  246. border: 1px solid #444;
  247. border-top-right-radius: 12px;
  248. border-top-left-radius: 12px;
  249. border-bottom-color: transparent;
  250. background-image: linear-gradient(to top, #111 11%, #333 56%);
  251. }
  252. .devtools-responsiveui-sleep-button:hover:active {
  253. background-image: linear-gradient(to top, #aaa 11%, #ddd 56%);
  254. }
  255. .devtools-responsiveui-volume-buttons {
  256. margin-left: -29px;
  257. }
  258. .devtools-responsiveui-volume-up-button,
  259. .devtools-responsiveui-volume-down-button {
  260. -moz-user-focus: ignore;
  261. -moz-appearance: none;
  262. border: 1px solid red;
  263. min-width: 8px;
  264. height: 40px;
  265. border: 1px solid #444;
  266. border-right-color: transparent;
  267. background-image: linear-gradient(to right, #111 11%, #333 56%);
  268. }
  269. .devtools-responsiveui-volume-up-button:hover:active,
  270. .devtools-responsiveui-volume-down-button:hover:active {
  271. background-image: linear-gradient(to right, #aaa 11%, #ddd 56%);
  272. }
  273. .devtools-responsiveui-volume-up-button {
  274. border-top-left-radius: 12px;
  275. }
  276. .devtools-responsiveui-volume-down-button {
  277. border-bottom-left-radius: 12px;
  278. }
  279. @media (min-resolution: 1.1dppx) {
  280. .devtools-responsiveui-resizebarV {
  281. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-vertical-resizer@2x.png");
  282. }
  283. .devtools-responsiveui-resizebarH {
  284. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-horizontal-resizer@2x.png");
  285. }
  286. .devtools-responsiveui-resizehandle {
  287. background-image: url("chrome://devtools/skin/images/responsivemode/responsive-se-resizer@2x.png");
  288. }
  289. }