diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2022-11-05 00:02:06 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-11-05 00:02:06 +0100 |
| commit | ded8d0332ed78138b5e3a273aba066e034e05751 (patch) | |
| tree | 9bc9c036986a2b55b0a0fdf4056a03f01c3ebbda /src/test | |
| parent | f6ca5aa19a567f6cb95a0c568cac148f8eb443fb (diff) | |
| parent | 4bd6748bb9b73c210558498070ae0b7ed8193ddf (diff) | |
| download | rust-ded8d0332ed78138b5e3a273aba066e034e05751.tar.gz rust-ded8d0332ed78138b5e3a273aba066e034e05751.zip | |
Rollup merge of #103980 - notriddle:notriddle/search-results, r=GuillaumeGomez
rustdoc: simplify search results CSS and DOM Preview: http://notriddle.com/notriddle-rustdoc-demos/search-results/std/index.html?search=vec There is a layout change caused by this commit, but it's subtle. You won't notice it unless you're looking for it. ## Before  ## After 
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/rustdoc-gui/search-result-color.goml | 8 | ||||
| -rw-r--r-- | src/test/rustdoc-gui/search-result-display.goml | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/test/rustdoc-gui/search-result-color.goml b/src/test/rustdoc-gui/search-result-color.goml index 37d7b03a099..0c3b1119074 100644 --- a/src/test/rustdoc-gui/search-result-color.goml +++ b/src/test/rustdoc-gui/search-result-color.goml @@ -67,7 +67,7 @@ reload: // Waiting for the search results to appear... wait-for: "#titles" assert-css: ( - "//*[@class='desc']//*[text()='Just a normal struct.']", + "//*[@class='desc'][text()='Just a normal struct.']", {"color": "rgb(197, 197, 197)"}, ) assert-css: ( @@ -159,7 +159,7 @@ assert-css: ( ) // Checking color and background on hover. -move-cursor-to: "//*[@class='desc']//*[text()='Just a normal struct.']" +move-cursor-to: "//*[@class='desc'][text()='Just a normal struct.']" assert-css: ( "//*[@class='result-name']/*[text()='test_docs::']", {"color": "rgb(255, 255, 255)"}, @@ -179,7 +179,7 @@ reload: // Waiting for the search results to appear... wait-for: "#titles" assert-css: ( - "//*[@class='desc']//*[text()='Just a normal struct.']", + "//*[@class='desc'][text()='Just a normal struct.']", {"color": "rgb(221, 221, 221)"}, ) assert-css: ( @@ -276,7 +276,7 @@ reload: // Waiting for the search results to appear... wait-for: "#titles" assert-css: ( - "//*[@class='desc']//*[text()='Just a normal struct.']", + "//*[@class='desc'][text()='Just a normal struct.']", {"color": "rgb(0, 0, 0)"}, ) assert-css: ( diff --git a/src/test/rustdoc-gui/search-result-display.goml b/src/test/rustdoc-gui/search-result-display.goml index 053bfd8c905..b8abd9f9062 100644 --- a/src/test/rustdoc-gui/search-result-display.goml +++ b/src/test/rustdoc-gui/search-result-display.goml @@ -7,7 +7,7 @@ press-key: 'Enter' wait-for: "#crate-search" // The width is returned by "getComputedStyle" which returns the exact number instead of the // CSS rule which is "50%"... -assert-css: (".search-results div.desc", {"width": "318px"}) +assert-css: (".search-results div.desc", {"width": "310px"}) size: (600, 100) // As counter-intuitive as it may seem, in this width, the width is "100%", which is why // when computed it's larger. |
