GeoGuessr Bigger Map on Map-Maker

Enables the user to have a bigger map when using the map-maker // It also hides the Search Bar and the Sidebar when using the map-maker

当前为 2020-07-25 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name GeoGuessr Bigger Map on Map-Maker
  3. // @namespace https://bitbucket.org/MrAmericanMike/
  4. // @version 0.3.2
  5. // @description Enables the user to have a bigger map when using the map-maker // It also hides the Search Bar and the Sidebar when using the map-maker
  6. // @author MrAmericanMike
  7. // @include https://www.geoguessr.com/map-maker/*
  8. // @include https://www.geoguessr.com/map-maker
  9. // @grant none
  10. // @run-at document-end
  11. // ==/UserScript==
  12.  
  13. console.log("GeoGuessr Bigger Map on Map-Maker");
  14.  
  15. function addGlobalStyle(css) {
  16. var head, style;
  17. head = document.getElementsByTagName('head')[0];
  18. if (!head) { return; }
  19. style = document.createElement('style');
  20. style.type = 'text/css';
  21. style.innerHTML = css.replace(/;/g, ' !important;');
  22. head.appendChild(style);
  23. }
  24.  
  25. addGlobalStyle (`
  26.  
  27. .container {
  28. --width: 100%;
  29. }
  30.  
  31. .layout {
  32. --layout-content-padding-top: 0.5rem;
  33. --layout-content-padding-bottom: 2.5rem;
  34. --layout-content-horizontal-padding: 0.5rem;
  35. }
  36.  
  37. .layout--always-show-sidebar-on-large-devices {
  38. grid-template-columns: 0rem 1fr;
  39. }
  40.  
  41. aside, .title {
  42. display: none;
  43. }
  44.  
  45. .map-maker-map {
  46. width: 100%;
  47. height: 90vh;
  48. padding-bottom: 0%;
  49. position: relative;
  50. }
  51.  
  52. .streetview-panel {
  53. width: 50rem;
  54. height: 100%;
  55. max-height: 100%;
  56. right: 0;
  57. top: 0;
  58. position: absolute;
  59. }
  60.  
  61. `);
  62.