Google Search Display URL

Display page URLs under the page names (legacy feature).

  1. /* ==UserStyle==
  2. @name Google Search Display URL
  3. @name:ja Google検索 URLを表示
  4. @description Display page URLs under the page names (legacy feature).
  5. @description:ja 以前のようにページ名の下へURLを表示します。
  6. @namespace https://greatest.deepsurf.us/users/137
  7. @version 1.8.0
  8. @license MPL-2.0
  9. @contributionURL https://www.amazon.co.jp/registry/wishlist/E7PJ5C3K7AM2
  10. @compatible Edge
  11. @compatible Firefox 推奨 (Recommended)
  12. @compatible Opera
  13. @compatible Chrome
  14. @author 100の人
  15. @homepageURL https://greatest.deepsurf.us/scripts/395307
  16. ==/UserStyle== */
  17.  
  18. /*
  19. 【動作確認用】
  20. サイトリンク付き
  21. https://www.google.com/search?q=Greasy+Fork
  22. 動画再生フォーム
  23. https://www.google.com/search?q=%E5%A5%BD%E3%81%8D!%E9%9B%AA!%E6%9C%AC%E6%B0%97%E3%83%9E%E3%82%B8%E3%83%83%E3%82%AF
  24. 電卓
  25. https://www.google.com/search?q=1-1
  26. 翻訳フォーム
  27. https://www.google.com/search?q=test
  28. 乱数生成フォーム / このページを訳す
  29. https://www.google.com/search?q=random+number
  30. 宅配便の追跡リンク
  31. https://www.google.com/search?q=999999999994
  32. Twitter
  33. https://www.google.com/search?q=Twitter
  34. */
  35.  
  36. @namespace url(http://www.w3.org/1999/xhtml);
  37.  
  38. @-moz-document regexp("https?://www\\.google\\.(?:com|(?:com?\\.)?[a-z][a-z])/(?!maps(?:$|.*)).*") {
  39. .yuRUbf > div,
  40. [data-async-context^="query:"] :is(
  41. div[data-hveid][data-ved]:not([id]):not([data-md]) h3, /* 動画再生フォーム */
  42. g-section-with-header g-link /* Twitter */
  43. ) a {
  44. --sub-color: darkgreen;
  45.  
  46. display: grid;
  47. grid-template:
  48. " title title "
  49. " url option"
  50. / auto 1fr;
  51. }
  52.  
  53. [data-async-context^="query:"] :is(
  54. div[data-hveid][data-ved]:not([id]):not([data-md]):not([class*="wholepage"]),
  55. g-section-with-header /* Twitter */
  56. ) cite {
  57. display: none;
  58. }
  59.  
  60. .yuRUbf > div > span,
  61. .yuRUbf > div > span > a {
  62. display: contents;
  63. }
  64.  
  65. :is(
  66. .yuRUbf > div,
  67. [data-async-context^="query:"] g-section-with-header g-link
  68. ) h3 {
  69. grid-area: title;
  70. white-space: nowrap;
  71. }
  72.  
  73. :is(
  74. .yuRUbf > div,
  75. [data-async-context^="query:"] g-section-with-header g-link
  76. ) h3 + div > span {
  77. background: unset;
  78. border: unset;
  79. }
  80.  
  81. :is(
  82. .yuRUbf > div > a,
  83. .yuRUbf > div > span > a,
  84. [data-async-context^="query:"] :is(
  85. div[data-hveid][data-ved]:not([id]):not([data-md]) h3, /* 動画再生フォーム */
  86. g-section-with-header g-link /* Twitter */
  87. ) a
  88. )::after {
  89. grid-area: url;
  90. content: attr(href);
  91. color: var(--sub-color);
  92. white-space: nowrap;
  93. overflow: hidden;
  94. text-overflow: ellipsis;
  95. font-size: 13px; /* Twitter */
  96. }
  97.  
  98. .yuRUbf > div > div {
  99. grid-area: option;
  100. position: unset;
  101. width: 18px;
  102. }
  103.  
  104. .yuRUbf > div > div > div:first-of-type {
  105. display: none;
  106. }
  107.  
  108. .yuRUbf > div > div > div:nth-of-type(2) {
  109. margin-top: unset;
  110. }
  111. }