feat(sirius-x): hosting is a choice, not a raw s3 key
The s3 field asked people for a Sia bucket key. Under Content & hosting it is now a choice: not hosted on Sia, Sirius.X hosting (free, the name's own folder on Sia, filled by Studio or the upload API), or another folder for the few who host elsewhere. The raw key stays editable under the advanced option; the on-chain record is unchanged.
This commit is contained in:
parent
e95332e493
commit
0cb4aec5df
14 changed files with 77 additions and 17 deletions
|
|
@ -127,7 +127,7 @@
|
||||||
<script type="importmap">
|
<script type="importmap">
|
||||||
{ "imports": { "@bitauth/libauth": "https://silentmode.st/js/libauth.js" } }
|
{ "imports": { "@bitauth/libauth": "https://silentmode.st/js/libauth.js" } }
|
||||||
</script>
|
</script>
|
||||||
<script src="../js/i18n.js?v=20260920e"></script>
|
<script src="../js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Letzte Änderung rückgängig",
|
"Undo last change": "Letzte Änderung rückgängig",
|
||||||
"Stop": "Stopp",
|
"Stop": "Stopp",
|
||||||
"unconfirmed · spendable now": "unbestätigt · sofort verfügbar",
|
"unconfirmed · spendable now": "unbestätigt · sofort verfügbar",
|
||||||
"Price (BCH)": "Preis (BCH)"
|
"Price (BCH)": "Preis (BCH)",
|
||||||
|
"Hosting": "Hosting",
|
||||||
|
"where the page files live (the s3 record)": "wo die Seitendateien liegen (der s3-Eintrag)",
|
||||||
|
"Not hosted on Sia": "Nicht auf Sia gehostet",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Sirius.X-Hosting — kostenlos, auf Sia-Speicher",
|
||||||
|
"Another Sia folder (advanced)": "Anderer Sia-Ordner (erweitert)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Αναίρεση τελευταίας αλλαγής",
|
"Undo last change": "Αναίρεση τελευταίας αλλαγής",
|
||||||
"Stop": "Στοπ",
|
"Stop": "Στοπ",
|
||||||
"unconfirmed · spendable now": "ανεπιβεβαίωτα · διαθέσιμα τώρα",
|
"unconfirmed · spendable now": "ανεπιβεβαίωτα · διαθέσιμα τώρα",
|
||||||
"Price (BCH)": "Τιμή (BCH)"
|
"Price (BCH)": "Τιμή (BCH)",
|
||||||
|
"Hosting": "Φιλοξενία",
|
||||||
|
"where the page files live (the s3 record)": "πού βρίσκονται τα αρχεία της σελίδας (η εγγραφή s3)",
|
||||||
|
"Not hosted on Sia": "Δεν φιλοξενείται στο Sia",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Φιλοξενία Sirius.X — δωρεάν, στον αποθηκευτικό χώρο Sia",
|
||||||
|
"Another Sia folder (advanced)": "Άλλος φάκελος Sia (για προχωρημένους)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Deshacer el último cambio",
|
"Undo last change": "Deshacer el último cambio",
|
||||||
"Stop": "Detener",
|
"Stop": "Detener",
|
||||||
"unconfirmed · spendable now": "sin confirmar · disponibles ya",
|
"unconfirmed · spendable now": "sin confirmar · disponibles ya",
|
||||||
"Price (BCH)": "Precio (BCH)"
|
"Price (BCH)": "Precio (BCH)",
|
||||||
|
"Hosting": "Alojamiento",
|
||||||
|
"where the page files live (the s3 record)": "dónde viven los archivos de la página (el registro s3)",
|
||||||
|
"Not hosted on Sia": "No alojado en Sia",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Alojamiento Sirius.X — gratis, en almacenamiento Sia",
|
||||||
|
"Another Sia folder (advanced)": "Otra carpeta de Sia (avanzado)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Annuler la dernière modification",
|
"Undo last change": "Annuler la dernière modification",
|
||||||
"Stop": "Arrêter",
|
"Stop": "Arrêter",
|
||||||
"unconfirmed · spendable now": "non confirmés · disponibles maintenant",
|
"unconfirmed · spendable now": "non confirmés · disponibles maintenant",
|
||||||
"Price (BCH)": "Prix (BCH)"
|
"Price (BCH)": "Prix (BCH)",
|
||||||
|
"Hosting": "Hébergement",
|
||||||
|
"where the page files live (the s3 record)": "où se trouvent les fichiers de la page (l'enregistrement s3)",
|
||||||
|
"Not hosted on Sia": "Pas hébergé sur Sia",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Hébergement Sirius.X — gratuit, sur le stockage Sia",
|
||||||
|
"Another Sia folder (advanced)": "Un autre dossier Sia (avancé)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Anular a última alteração",
|
"Undo last change": "Anular a última alteração",
|
||||||
"Stop": "Parar",
|
"Stop": "Parar",
|
||||||
"unconfirmed · spendable now": "por confirmar · disponíveis já",
|
"unconfirmed · spendable now": "por confirmar · disponíveis já",
|
||||||
"Price (BCH)": "Preço (BCH)"
|
"Price (BCH)": "Preço (BCH)",
|
||||||
|
"Hosting": "Alojamento",
|
||||||
|
"where the page files live (the s3 record)": "onde ficam os ficheiros da página (o registo s3)",
|
||||||
|
"Not hosted on Sia": "Não alojado no Sia",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Alojamento Sirius.X — grátis, no armazenamento Sia",
|
||||||
|
"Another Sia folder (advanced)": "Outra pasta Sia (avançado)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -604,5 +604,10 @@
|
||||||
"Undo last change": "Отменить последнее изменение",
|
"Undo last change": "Отменить последнее изменение",
|
||||||
"Stop": "Стоп",
|
"Stop": "Стоп",
|
||||||
"unconfirmed · spendable now": "не подтверждено · доступно сейчас",
|
"unconfirmed · spendable now": "не подтверждено · доступно сейчас",
|
||||||
"Price (BCH)": "Цена (BCH)"
|
"Price (BCH)": "Цена (BCH)",
|
||||||
|
"Hosting": "Хостинг",
|
||||||
|
"where the page files live (the s3 record)": "где лежат файлы страницы (запись s3)",
|
||||||
|
"Not hosted on Sia": "Не размещено на Sia",
|
||||||
|
"Sirius.X hosting — free, on Sia storage": "Хостинг Sirius.X — бесплатно, в хранилище Sia",
|
||||||
|
"Another Sia folder (advanced)": "Другая папка Sia (для опытных)"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -165,7 +165,7 @@
|
||||||
.verify dd{margin:2px 0 0;font-family:ui-monospace,monospace;font-size:12.5px;word-break:break-all;color:var(--ink)}
|
.verify dd{margin:2px 0 0;font-family:ui-monospace,monospace;font-size:12.5px;word-break:break-all;color:var(--ink)}
|
||||||
footer{border-top:1px solid var(--line);padding:2.4rem 0 3.5rem;color:var(--dim);font-size:13px;text-align:center;margin-top:2.5rem}
|
footer{border-top:1px solid var(--line);padding:2.4rem 0 3.5rem;color:var(--dim);font-size:13px;text-align:center;margin-top:2.5rem}
|
||||||
</style>
|
</style>
|
||||||
<script src="./js/i18n.js?v=20260920e"></script>
|
<script src="./js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -563,10 +563,34 @@ $("dns-publish").addEventListener("click", async () => {
|
||||||
|
|
||||||
// ---------- content & hosting (on-chain records) ----------
|
// ---------- content & hosting (on-chain records) ----------
|
||||||
const CT_KEYS = ["h", "s3", "p", "ip", "tls"];
|
const CT_KEYS = ["h", "s3", "p", "ip", "tls"];
|
||||||
function fillContentForm(rec) { for (const k of CT_KEYS) $("ct-" + k).value = rec[k] || ""; updateBudget(); }
|
// s3 is offered as a choice: "Sirius.X hosting" is the name's own folder on
|
||||||
|
// Sia (bns/<name>/), free, filled by Studio or the upload API. The raw key
|
||||||
|
// stays reachable under "advanced" for anyone hosting from another folder.
|
||||||
|
const hostingFolder = () => `bns/${current.name}/`;
|
||||||
|
const S3_HINTS = {
|
||||||
|
off: "Nothing is served from Sia. Use inline HTML, a proxy, your own server or a redirect — or switch on Sirius.X hosting.",
|
||||||
|
sirius: "Free web hosting by Sirius.X: the files are served from your own folder on Sia storage. Build the page in Studio (Publish to Sia) or upload files yourself; only your key can write there. DNS records live in the same folder.",
|
||||||
|
custom: "Any folder key on the Sirius.X Sia bucket, with a trailing slash. Only your own folder accepts your uploads; other folders must be filled another way.",
|
||||||
|
};
|
||||||
|
function paintS3Mode() {
|
||||||
|
const mode = $("ct-s3-mode").value;
|
||||||
|
$("ct-s3").hidden = mode !== "custom";
|
||||||
|
$("ct-s3-hint").textContent = S3_HINTS[mode] + (mode === "sirius" ? ` Folder: ${hostingFolder()}` : "");
|
||||||
|
if (mode === "sirius") $("ct-s3").value = hostingFolder();
|
||||||
|
if (mode === "off") $("ct-s3").value = "";
|
||||||
|
}
|
||||||
|
function fillContentForm(rec) {
|
||||||
|
for (const k of CT_KEYS) $("ct-" + k).value = rec[k] || "";
|
||||||
|
const s3 = String(rec.s3 || "").trim();
|
||||||
|
$("ct-s3-mode").value = !s3 ? "off" : s3 === hostingFolder() ? "sirius" : "custom";
|
||||||
|
paintS3Mode(); updateBudget();
|
||||||
|
}
|
||||||
|
$("ct-s3-mode").addEventListener("change", () => { paintS3Mode(); updateBudget(); });
|
||||||
function collectContent() {
|
function collectContent() {
|
||||||
const r = {};
|
const r = {};
|
||||||
for (const k of CT_KEYS) { const v = $("ct-" + k).value.trim(); if (v) r[k] = v; }
|
for (const k of CT_KEYS) { const v = $("ct-" + k).value.trim(); if (v) r[k] = v; }
|
||||||
|
const mode = $("ct-s3-mode").value;
|
||||||
|
if (mode === "sirius") r.s3 = hostingFolder(); else if (mode === "off") delete r.s3;
|
||||||
const u = ($("rd-url").value || "").trim(); if (u) r.u = u;
|
const u = ($("rd-url").value || "").trim(); if (u) r.u = u;
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,7 @@
|
||||||
(function () {
|
(function () {
|
||||||
var STORE = "sirius-lang";
|
var STORE = "sirius-lang";
|
||||||
var CACHE = "sirius-i18n:";
|
var CACHE = "sirius-i18n:";
|
||||||
var VERSION = "20260920e"; // bump when dictionaries change
|
var VERSION = "20260920f"; // bump when dictionaries change
|
||||||
var LANGS = {
|
var LANGS = {
|
||||||
en: "English",
|
en: "English",
|
||||||
de: "Deutsch",
|
de: "Deutsch",
|
||||||
|
|
|
||||||
|
|
@ -97,7 +97,7 @@
|
||||||
footer{border-top:1px solid var(--line);padding:2rem 0 3rem;color:var(--dim);font-size:13px;text-align:center;margin-top:2.5rem}
|
footer{border-top:1px solid var(--line);padding:2rem 0 3rem;color:var(--dim);font-size:13px;text-align:center;margin-top:2.5rem}
|
||||||
@media (max-width:560px){.row{grid-template-columns:1fr auto}.row .price{grid-column:1/-1;text-align:left}}
|
@media (max-width:560px){.row{grid-template-columns:1fr auto}.row .price{grid-column:1/-1;text-align:left}}
|
||||||
</style>
|
</style>
|
||||||
<script src="../js/i18n.js?v=20260920e"></script>
|
<script src="../js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<nav class="topnav">
|
<nav class="topnav">
|
||||||
|
|
|
||||||
14
portal.html
14
portal.html
|
|
@ -259,7 +259,7 @@
|
||||||
.addrow{grid-template-columns:1fr 1fr}
|
.addrow{grid-template-columns:1fr 1fr}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<script src="./js/i18n.js?v=20260920e"></script>
|
<script src="./js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
|
@ -443,8 +443,14 @@
|
||||||
<p class="hint">On-chain records, published as one signed UPD transaction (a few cents of chain dust). Leave a field blank to drop that record. Precedence for resolvers: h, then s3, then p, then ip.</p>
|
<p class="hint">On-chain records, published as one signed UPD transaction (a few cents of chain dust). Leave a field blank to drop that record. Precedence for resolvers: h, then s3, then p, then ip.</p>
|
||||||
<label>h <span class="field-hint">inline HTML — served as-is at the site root (~150 bytes)</span></label>
|
<label>h <span class="field-hint">inline HTML — served as-is at the site root (~150 bytes)</span></label>
|
||||||
<textarea id="ct-h" placeholder="<h1>My site</h1>"></textarea>
|
<textarea id="ct-h" placeholder="<h1>My site</h1>"></textarea>
|
||||||
<label>s3 <span class="field-hint">Sia folder the site is served from, with trailing slash. Studio publishes to bns/<yourname>/ and sets this for you; DNS manifests live there too</span></label>
|
<label>Hosting <span class="field-hint">where the page files live (the s3 record)</span></label>
|
||||||
<input type="text" id="ct-s3" placeholder="bns/space.x/">
|
<select id="ct-s3-mode">
|
||||||
|
<option value="off">Not hosted on Sia</option>
|
||||||
|
<option value="sirius">Sirius.X hosting — free, on Sia storage</option>
|
||||||
|
<option value="custom">Another Sia folder (advanced)</option>
|
||||||
|
</select>
|
||||||
|
<p class="hint" id="ct-s3-hint" style="margin:6px 0 0"></p>
|
||||||
|
<input type="text" id="ct-s3" placeholder="bns/space.x/" style="margin-top:8px" hidden>
|
||||||
<label>p <span class="field-hint">reverse proxy: full upstream URL the gateway mirrors</span></label>
|
<label>p <span class="field-hint">reverse proxy: full upstream URL the gateway mirrors</span></label>
|
||||||
<input type="text" id="ct-p" placeholder="https://origin.example.com">
|
<input type="text" id="ct-p" placeholder="https://origin.example.com">
|
||||||
<label>ip <span class="field-hint">IPv4 that serves this name over Host header</span></label>
|
<label>ip <span class="field-hint">IPv4 that serves this name over Host header</span></label>
|
||||||
|
|
@ -676,7 +682,7 @@
|
||||||
<script src="./js/session.js?v=20260917dash"></script>
|
<script src="./js/session.js?v=20260917dash"></script>
|
||||||
<script src="./js/pin-escrow.js?v=20260909pin"></script>
|
<script src="./js/pin-escrow.js?v=20260909pin"></script>
|
||||||
<script src="./js/pricing.js?v=20260920bits"></script>
|
<script src="./js/pricing.js?v=20260920bits"></script>
|
||||||
<script type="module" src="./js/dashboard.js?v=20260920nav"></script>
|
<script type="module" src="./js/dashboard.js?v=20260920s3"></script>
|
||||||
<script defer src="./js/theme.js?v=20260920compact"></script>
|
<script defer src="./js/theme.js?v=20260920compact"></script>
|
||||||
<script defer src="./js/site-footer.js?v=20260917market"></script>
|
<script defer src="./js/site-footer.js?v=20260917market"></script>
|
||||||
<script type="module" src="./js/register-flow.js?v=20260920bits"></script>
|
<script type="module" src="./js/register-flow.js?v=20260920bits"></script>
|
||||||
|
|
|
||||||
|
|
@ -131,7 +131,7 @@
|
||||||
.muted{color:var(--mut);font-size:13px}
|
.muted{color:var(--mut);font-size:13px}
|
||||||
code{font-family:var(--mono);background:#0e131b;border:1px solid var(--line);border-radius:6px;padding:1px 6px;font-size:12px}
|
code{font-family:var(--mono);background:#0e131b;border:1px solid var(--line);border-radius:6px;padding:1px 6px;font-size:12px}
|
||||||
</style>
|
</style>
|
||||||
<script src="./js/i18n.js?v=20260920e"></script>
|
<script src="./js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="bar">
|
<div class="bar">
|
||||||
|
|
|
||||||
2
tld.html
2
tld.html
|
|
@ -150,7 +150,7 @@
|
||||||
<script type="importmap">
|
<script type="importmap">
|
||||||
{ "imports": { "@bitauth/libauth": "https://silentmode.st/js/libauth.js" } }
|
{ "imports": { "@bitauth/libauth": "https://silentmode.st/js/libauth.js" } }
|
||||||
</script>
|
</script>
|
||||||
<script src="./js/i18n.js?v=20260920e"></script>
|
<script src="./js/i18n.js?v=20260920f"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue