web: Snap Store badge, served from here
The badge image is vendored rather than hotlinked from snapcraft.io. The CSP is img-src 'self' data: and would block it anyway, but the reason to leave the CSP alone is the page's own claim: fetching a badge from someone else's server hands them the address of every visitor to a page that says no servers are involved. The README badge stays dynamic — it reports the published version, and GitHub proxies images, so no reader is exposed by it.
This commit is contained in:
Vendored
+35
-1
@@ -34078,7 +34078,41 @@ var CommunityCTA = () => {
|
||||
React.createElement("div", {
|
||||
key: "btns",
|
||||
style: { display: "flex", gap: "14px", justifyContent: "center", flexWrap: "wrap" }
|
||||
}, [githubBtn, feedbackBtn])
|
||||
}, [githubBtn, feedbackBtn]),
|
||||
// Snap Store, bottom right.
|
||||
//
|
||||
// Served from this origin, not snapcraft.io. The site's CSP is
|
||||
// `img-src 'self' data:` and would block a hotlink anyway, but the
|
||||
// reason to keep it that way is the product's own claim: fetching a
|
||||
// badge from someone else's server hands them the address of every
|
||||
// visitor to a page that promises no servers are involved.
|
||||
React.createElement("div", {
|
||||
key: "snap",
|
||||
style: {
|
||||
display: "flex",
|
||||
justifyContent: isMobile ? "center" : "flex-end",
|
||||
marginTop: "28px"
|
||||
}
|
||||
}, React.createElement("a", {
|
||||
href: "https://snapcraft.io/securebit-chat",
|
||||
target: "_blank",
|
||||
rel: "noopener noreferrer",
|
||||
"aria-label": "Get it from the Snap Store",
|
||||
style: { display: "inline-flex", opacity: 0.9, transition: "opacity .2s" },
|
||||
onMouseEnter: (e) => {
|
||||
e.currentTarget.style.opacity = 1;
|
||||
},
|
||||
onMouseLeave: (e) => {
|
||||
e.currentTarget.style.opacity = 0.9;
|
||||
}
|
||||
}, React.createElement("img", {
|
||||
src: "/assets/badges/snap-store.svg",
|
||||
alt: "Get it from the Snap Store",
|
||||
width: 182,
|
||||
height: 56,
|
||||
loading: "lazy",
|
||||
style: { display: "block" }
|
||||
})))
|
||||
]);
|
||||
return React.createElement("section", {
|
||||
style: {
|
||||
|
||||
Vendored
+2
-2
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user