1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/// The reason the catalog response could not be read as UTF-8.
pub const ERROR_CATALOG_ENCODING: &str = "The catalog response is not UTF-8";
/// The reason the catalog response does not have the expected shape.
pub const ERROR_CATALOG_SHAPE: &str = "The catalog response has an unexpected shape";
/// The path of the public catalog API.
pub const CATALOG_URL: &str = "/api/page-artifacts";
/// The class the catalog cards carry.
///
/// The name is the contract the documentation runtime validator asserts
/// on, so it stays stable even though the styling lives in the shared
/// `c_catalog*` classes of the framework.
pub const CATALOG_CARD_CLASS: &str = "docs-catalog-card";
/// The template of a published project page link.
pub const CATALOG_LINK_TEMPLATE: &str = "/pages/{name}/";
/// The character a safe artifact name may carry as a separator.
pub const HYPHEN: u8 = b'-';
/// The separator a safe artifact name may carry, as a character.
pub const HYPHEN_CHAR: char = '-';
/// The separator between an artifact's organization and its repository.
///
/// A published artifact is addressed either by its bare name (a legacy
/// alias) or by its qualified name, which the server writes as the
/// organization, the separator and the repository. The catalog lists the
/// qualified name, so the name rule has to accept that shape.
pub const ORG_REPO_SEPARATOR: char = '/';
/// The role of the catalog's loading and failure messages.
pub const CATALOG_ROLE_STATUS: &str = "status";
/// The type of the catalog's retry button.
pub const CATALOG_BUTTON_TYPE: &str = "button";