Release version 1.10.0 (#242)

This commit is contained in:
Folyd 2023-03-26 15:33:32 +08:00 committed by GitHub
parent 1fa78df454
commit 1eff07cc0f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 72 additions and 58 deletions

View file

@ -7,7 +7,7 @@
[![Chrome Web Store](https://img.shields.io/chrome-web-store/v/ennpfpdlaclocpomkiablnmbppdnlhoh.svg)](https://chrome.google.com/webstore/detail/rust-search-extension/ennpfpdlaclocpomkiablnmbppdnlhoh)
[![Mozilla Add-on](https://img.shields.io/amo/v/rust-search-extension?color=%2320123A)](https://addons.mozilla.org/firefox/addon/rust-search-extension/)
[![Microsoft Edge](https://img.shields.io/badge/microsoft--edge-v1.9.1-1D4F8C)](https://microsoftedge.microsoft.com/addons/detail/olemfibpaicdoooacpfffccidjjagmoe)
[![Microsoft Edge](https://img.shields.io/badge/microsoft--edge-v1.10.0-1D4F8C)](https://microsoftedge.microsoft.com/addons/detail/olemfibpaicdoooacpfffccidjjagmoe)
[![license-mit](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/huhu/rust-search-extension/blob/master/LICENSE-MIT)
[![license-apache](https://img.shields.io/badge/license-Apache-yellow.svg)](https://github.com/huhu/rust-search-extension/blob/master/LICENSE-APACHE)
[![Discord](https://img.shields.io/discord/711895914494558250?label=chat&logo=discord)](https://discord.gg/xucZNVd)

View file

@ -9,7 +9,7 @@
[![Chrome Web Store](https://img.shields.io/chrome-web-store/v/ennpfpdlaclocpomkiablnmbppdnlhoh.svg)](https://chrome.google.com/webstore/detail/rust-search-extension/ennpfpdlaclocpomkiablnmbppdnlhoh)
[![Mozilla Add-on](https://img.shields.io/amo/v/rust-search-extension?color=%2320123A)](https://addons.mozilla.org/firefox/addon/rust-search-extension/)
[![Microsoft Edge](https://img.shields.io/badge/microsoft--edge-v1.9.1-1D4F8C)](https://microsoftedge.microsoft.com/addons/detail/olemfibpaicdoooacpfffccidjjagmoe)
[![Microsoft Edge](https://img.shields.io/badge/microsoft--edge-v1.10.0-1D4F8C)](https://microsoftedge.microsoft.com/addons/detail/olemfibpaicdoooacpfffccidjjagmoe)
[![license-mit](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/huhu/rust-search-extension/blob/master/LICENSE-MIT)
[![license-apache](https://img.shields.io/badge/license-Apache-yellow.svg)](https://github.com/huhu/rust-search-extension/blob/master/LICENSE-APACHE)
[![Discord](https://img.shields.io/discord/711895914494558250?label=chat&logo=discord)](https://discord.gg/xucZNVd)

View file

@ -38,7 +38,7 @@ You can prefix a **/** (slash) before the keyword to search nightly docs.
You can prefix a **//** (double slash) before the keyword to search all of
crates [docs of **rustc**](https://doc.rust-lang.org/nightly/nightly-rustc/),
such as *rustc_mir*, *rustc_hir*, or *rustc_ast*, etc.
such as _rustc_mir_, _rustc_hir_, or _rustc_ast_, etc.
> It makes no sense to have a built-in search-index of **rustc** since the **rustc** is changed
> very frequently. Therefore, you need to open the **rustc** docs page in advance to sync the
@ -51,6 +51,7 @@ such as *rustc_mir*, *rustc_hir*, or *rustc_ast*, etc.
## Search with type mode
You can prefix a type to get the exclusive search result. Those type keywords including:
- **mod**
- **struct**
- **enum**
@ -135,12 +136,6 @@ You can search [caniuse.rs](https://caniuse.rs) with **?** prefix.
![IMG](/search-caniuse.png)
# Search Rust Version
Just input any Rust version (such as `1.38` or `v1.38`) to open the release page of that version.
![](/search-rust-version.png)
# Commands system
The command system brings a handy set of useful and convenient commands to you.
@ -148,7 +143,6 @@ Each command starts with a **:** (colon), followed by the name, and function dif
Those commands including but not limited to:
- **:help** - Show the help messages.
- **:blog** - Search Rust release blog posts.
- **:cargo** - Search useful third-party cargo subcommands.
- **:yet** - Search Are We Yet websites.
- **:book** - Search Rust books.
@ -188,6 +182,10 @@ Docs.rs don't display the crate's feature flags, which is inconvenient. So Rust
Also, we support optional dependencies.
## Display Security Advisory
![](/security-advisory-menu.png)
## Add your favorite crate to extension
By clicking the `+ to Rust Search Extension` button, you can add the crate to the extension, which brings the
@ -197,12 +195,6 @@ search capability for this crate on the address bar.
![IMG](/docs-rs-toc.png)
# Rust repository enhancement
## Show Table of Content in the release page
![](/github-release-toc.png)
# Searching statistics
Searching statistics page provides a set of useful charts to visualize your search history. This gives you a

View file

@ -4,6 +4,26 @@ description = "Changelog"
weight = 3
+++
# v1.10.0 -2023-03-25
- Add security advisory menu to docs.rs ({{ issue(id=239) }})
> ![](/security-advisory-menu.png)
- Support statistics by year ({{ issue(id=221) }})
- Support new error-index page ({{ issue(id=192) }})
- Support new search index format since 1.69 ({{ issue(id=233) }})
- Bugfix:
- Make "add to extension" button vertically centered ({{ issue(id=220) }})
- Fix `resourcePath()` null bug. Fix {{ issue(id=219) }}
- Fix cargo book command ({{ issue(id=231) }}) ({{ issue(id=234) }})
- Fix error code autoincreament bug
- Fix can't add crates: Redeclaration of const storage ({{ issue(id=243) }})
- Remove:
- Remove :blog command ({{ issue(id=240) }})
- Remove GitHub release page enhancement ({{ issue(id=241) }})
- Remove search rust version feature
Thanks for the contributions from [@shwin0901](https://github.com/shwin0901), [@duskmoon314](https://github.com/duskmoon314), and [@isunjn](https://github.com/isunjn).
# v1.9.0 - 2022-11-20
- Migrate to `chrome.storage.onChange` event to avoid adding docs index failure ({{ issue(id=206) }}).

View file

@ -14,15 +14,10 @@ Safari doesn't support omnibox API, which is essential to this extension. See is
### Is it possible to customize the number of suggestions shown in address bar?
The number of suggestions is limited to the browser API, currently we can't customize it. Also, each browser have [a different limit number](https://github.com/huhu/search-extension-core/blob/7629fe7a5f896abf630a2b7dc00e9e6141c36c5c/src/compat.js#L18).
### Is it possible to modify the plugin keyword trigger? For example, can I trigger with `r + tab` instead of `rs + tab`?
Unfortunately, the browser's API doesn't allow the extension to change its keyword dynamically. You can customize your keyword by changing [this line](https://github.com/huhu/rust-search-extension/blob/599b1c9a312751e3cfeef02e5f39d393aa091ba3/manifest.jsonnet#L12) to build your own version.
# Permissions
### Why does the extension require access to github.com?
Since **v1.1.0**, we add a [new enhancement feature](/#rust-repository-enhancement) for the rust-lang repository's [release page](https://github.com/rust-lang/rust/blob/master/RELEASES.md).
This needs permission to access the single release page, no other page else. See the extension permission declaration file: [line 38](https://github.com/huhu/rust-search-extension/blob/7a0aabd0eada6c615816c3f164647d3059fa4d6f/manifest.jsonnet#L38).
# Caveats

Binary file not shown.

Before

Width:  |  Height:  |  Size: 86 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

BIN
docs/static/security-advisory-menu.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 234 KiB

View file

@ -25,6 +25,7 @@
content="{{ config.extra.meta_description }}">
<meta name="twitter:image" content="https://rust.extension.sh/banner.png">
<link rel="stylesheet" href="{{ get_url(path="index.css") }}">
<script async defer src="https://buttons.github.io/buttons.js"></script>
{% endblock head %}
{% block hero %}
@ -38,10 +39,16 @@
<code>Space</code>
to get started. Just that easy!
</h3>
<div style="text-align: center;">
<a class="github-button" href="https://github.com/huhu/rust-search-extension" data-size="large" data-show-count="true"
aria-label="Star huhu/rust-search-extension on GitHub">Star</a>
<a class="github-button" href="https://github.com/huhu/rust-search-extension/fork" data-size="large"
data-show-count="true" aria-label="Fork huhu/rust-search-extension on GitHub">Fork</a>
</div>
<div style="margin-top: 50px; display: flex; flex-direction: column; align-items: center">
<a class="subtitle-text" style="text-decoration: underline; margin: 10px"
href="https://github.com/huhu/rust-search-extension/releases">
Current version 1.9.1
Current version 1.10.0
</a>
<a class="btn-download chrome"
href="https://chrome.google.com/webstore/detail/rust-search-extension/ennpfpdlaclocpomkiablnmbppdnlhoh"

View file

@ -133,7 +133,7 @@ document.addEventListener("DOMContentLoaded", async () => {
advisoryMenu.innerHTML = `<a href="https://rustsec.org/${advisories.length > 0 ? `packages/${crateName}.html` : ""}"
class="pure-menu-link" target="_blank">
<span class="fa-svg" aria-hidden="true">${SVG_SHEILD}</span>
<span class="title">Security advisory ${advisories.length}</span>
<span class="title">Security ${advisories.length}</span>
</a>
<div class="pure-menu-children rse-dropdown-content" role="menu">
${advisories.length > 0 ? `<ul>${html}</ul>` : `<div style="padding: 1rem;text-align: center;"><img style="width:100px;padding:1rem"src="https://rustsec.org/img/rustsec-logo-square.svg"/> <div>No security advisories found.</div></div>`}

View file

@ -8,7 +8,7 @@ local icons() = {
};
local name = 'Rust Search Extension';
local version = '1.9.1';
local version = '1.10.0';
local keyword = 'rs';
local description = 'Rust Search Extension - the ultimate search extension for Rust';