Просмотр исходного кода

Deploying to readthedocs from @ chillerlan/php-qrcode@f65d9d2815b4362fde0cac18205ca7b711692a8c 🚀

codemasher 1 год назад
Родитель
Сommit
dd138758e7
4 измененных файлов с 6 добавлено и 5 удалено
  1. 1 1
      .buildinfo
  2. 4 3
      _static/searchtools.js
  3. 1 1
      index.html
  4. 0 0
      searchindex.js

+ 1 - 1
.buildinfo

@@ -1,4 +1,4 @@
 # Sphinx build info version 1
 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
-config: f9f40f23ccac1393824d3db875733056
+config: 82d85fb5ef942d84bd36bb007532169a
 tags: 645f666f9bcd5a90fca523b33c5a78b7

+ 4 - 3
_static/searchtools.js

@@ -178,7 +178,7 @@ const Search = {
 
   htmlToText: (htmlString, anchor) => {
     const htmlElement = new DOMParser().parseFromString(htmlString, 'text/html');
-    for (const removalQuery of [".headerlinks", "script", "style"]) {
+    for (const removalQuery of [".headerlink", "script", "style"]) {
       htmlElement.querySelectorAll(removalQuery).forEach((el) => { el.remove() });
     }
     if (anchor) {
@@ -328,13 +328,14 @@ const Search = {
     for (const [title, foundTitles] of Object.entries(allTitles)) {
       if (title.toLowerCase().trim().includes(queryLower) && (queryLower.length >= title.length/2)) {
         for (const [file, id] of foundTitles) {
-          let score = Math.round(100 * queryLower.length / title.length)
+          const score = Math.round(Scorer.title * queryLower.length / title.length);
+          const boost = titles[file] === title ? 1 : 0;  // add a boost for document titles
           normalResults.push([
             docNames[file],
             titles[file] !== title ? `${titles[file]} > ${title}` : title,
             id !== null ? "#" + id : "",
             null,
-            score,
+            score + boost,
             filenames[file],
           ]);
         }

+ 1 - 1
index.html

@@ -361,7 +361,7 @@
              
   <section id="chillerlan-php-qrcode-manual">
 <h1>chillerlan PHP-QRCode Manual<a class="headerlink" href="#chillerlan-php-qrcode-manual" title="Link to this heading"></a></h1>
-<p>User manual for <a class="reference external" href="https://github.com/chillerlan/php-qrcode/">chillerlan/php-qrcode</a>  [main]. Updated on Jul 10, 2024.</p>
+<p>User manual for <a class="reference external" href="https://github.com/chillerlan/php-qrcode/">chillerlan/php-qrcode</a>  [main]. Updated on Jul 17, 2024.</p>
 <p>The phpDocumentor API documentation can be found at <a class="reference external" href="https://chillerlan.github.io/php-qrcode/">chillerlan.github.io/php-qrcode</a>.</p>
 <p>This work is licensed under the Creative Commons Attribution 4.0 International (CC BY 4.0) License.</p>
 <div class="toctree-wrapper compound">

Разница между файлами не показана из-за своего большого размера
+ 0 - 0
searchindex.js


Некоторые файлы не были показаны из-за большого количества измененных файлов