mirror of
https://github.com/duckietm/Nitro-V3.git
synced 2026-06-19 15:06:20 +00:00
Replace production domain references with examples
This commit is contained in:
@@ -16,9 +16,9 @@ This file controls everything at runtime.
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": true,
|
"secureAssetsEnabled": true,
|
||||||
"secureApiEnabled": true,
|
"secureApiEnabled": true,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -38,16 +38,16 @@ This file controls everything at runtime.
|
|||||||
|
|
||||||
- `apiBaseUrl`
|
- `apiBaseUrl`
|
||||||
- Nitro emulator / API base URL
|
- Nitro emulator / API base URL
|
||||||
- example: `https://nitro.slogga.it:2096`
|
- example: `https://nitro.example.com:2096`
|
||||||
- it is best to always set this explicitly, so you do not depend on the hardcoded fallback
|
- it is best to always set this explicitly, so you do not depend on the hardcoded fallback
|
||||||
|
|
||||||
- `plainConfigBaseUrl`
|
- `plainConfigBaseUrl`
|
||||||
- base URL for plain config files
|
- base URL for plain config files
|
||||||
- usually: `https://hotel.slogga.it/`
|
- usually: `https://hotel.example.com/`
|
||||||
|
|
||||||
- `plainGamedataBaseUrl`
|
- `plainGamedataBaseUrl`
|
||||||
- base URL for plain gamedata files
|
- base URL for plain gamedata files
|
||||||
- usually: `https://hotel.slogga.it/client/nitro/gamedata/`
|
- usually: `https://hotel.example.com/client/nitro/gamedata/`
|
||||||
|
|
||||||
## 2. `Nitro-V3/src/bootstrap.ts`
|
## 2. `Nitro-V3/src/bootstrap.ts`
|
||||||
|
|
||||||
@@ -71,7 +71,7 @@ This file controls everything at runtime.
|
|||||||
The current fallback is:
|
The current fallback is:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'http://192.168.1.52:2096/';
|
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'https://nitro.example.com:2096/';
|
||||||
```
|
```
|
||||||
|
|
||||||
So in production it is better to always set `apiBaseUrl` inside `client-mode.json`.
|
So in production it is better to always set `apiBaseUrl` inside `client-mode.json`.
|
||||||
@@ -114,7 +114,7 @@ This file still defines the paths used by the renderer.
|
|||||||
You can use:
|
You can use:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
"gamedata.url": "https://nitro.slogga.it:2096/nitro-sec/file?kind=gamedata&file="
|
"gamedata.url": "https://nitro.example.com:2096/nitro-sec/file?kind=gamedata&file="
|
||||||
```
|
```
|
||||||
|
|
||||||
and the equivalent secure URLs for the other gamedata resources.
|
and the equivalent secure URLs for the other gamedata resources.
|
||||||
@@ -124,7 +124,7 @@ and the equivalent secure URLs for the other gamedata resources.
|
|||||||
You can use plain classic paths, for example:
|
You can use plain classic paths, for example:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
"gamedata.url": "https://hotel.slogga.it/client/nitro/gamedata"
|
"gamedata.url": "https://hotel.example.com/client/nitro/gamedata"
|
||||||
```
|
```
|
||||||
|
|
||||||
or you can keep the renderer config as-is and let `secure-assets.ts` handle the fallback conversion.
|
or you can keep the renderer config as-is and let `secure-assets.ts` handle the fallback conversion.
|
||||||
@@ -214,9 +214,9 @@ nitro.secure.master_key=change-me-to-a-long-random-secret
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": true,
|
"secureAssetsEnabled": true,
|
||||||
"secureApiEnabled": true,
|
"secureApiEnabled": true,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -239,9 +239,9 @@ nitro.secure.master_key=a-long-random-secret
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": false,
|
"secureAssetsEnabled": false,
|
||||||
"secureApiEnabled": false,
|
"secureApiEnabled": false,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -261,9 +261,9 @@ nitro.secure.api.enabled=false
|
|||||||
"distObfuscationEnabled": false,
|
"distObfuscationEnabled": false,
|
||||||
"secureAssetsEnabled": false,
|
"secureAssetsEnabled": false,
|
||||||
"secureApiEnabled": false,
|
"secureApiEnabled": false,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -16,9 +16,9 @@ Questo file controlla tutto a runtime.
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": true,
|
"secureAssetsEnabled": true,
|
||||||
"secureApiEnabled": true,
|
"secureApiEnabled": true,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -38,16 +38,16 @@ Questo file controlla tutto a runtime.
|
|||||||
|
|
||||||
- `apiBaseUrl`
|
- `apiBaseUrl`
|
||||||
- base URL dell’emulatore / API Nitro
|
- base URL dell’emulatore / API Nitro
|
||||||
- esempio: `https://nitro.slogga.it:2096`
|
- esempio: `https://nitro.example.com:2096`
|
||||||
- meglio valorizzarlo sempre, così non dipendi dal fallback hardcoded
|
- meglio valorizzarlo sempre, così non dipendi dal fallback hardcoded
|
||||||
|
|
||||||
- `plainConfigBaseUrl`
|
- `plainConfigBaseUrl`
|
||||||
- base URL dei file config plain
|
- base URL dei file config plain
|
||||||
- normalmente: `https://hotel.slogga.it/`
|
- normalmente: `https://hotel.example.com/`
|
||||||
|
|
||||||
- `plainGamedataBaseUrl`
|
- `plainGamedataBaseUrl`
|
||||||
- base URL del gamedata plain
|
- base URL del gamedata plain
|
||||||
- normalmente: `https://hotel.slogga.it/client/nitro/gamedata/`
|
- normalmente: `https://hotel.example.com/client/nitro/gamedata/`
|
||||||
|
|
||||||
## 2. `Nitro-V3/src/bootstrap.ts`
|
## 2. `Nitro-V3/src/bootstrap.ts`
|
||||||
|
|
||||||
@@ -71,7 +71,7 @@ Questo file controlla tutto a runtime.
|
|||||||
Il fallback attuale è:
|
Il fallback attuale è:
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'http://192.168.1.52:2096/';
|
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'https://nitro.example.com:2096/';
|
||||||
```
|
```
|
||||||
|
|
||||||
Quindi in produzione conviene sempre valorizzare `apiBaseUrl` dentro `client-mode.json`.
|
Quindi in produzione conviene sempre valorizzare `apiBaseUrl` dentro `client-mode.json`.
|
||||||
@@ -114,7 +114,7 @@ Questo file continua a definire i path usati dal renderer.
|
|||||||
Puoi usare:
|
Puoi usare:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
"gamedata.url": "https://nitro.slogga.it:2096/nitro-sec/file?kind=gamedata&file="
|
"gamedata.url": "https://nitro.example.com:2096/nitro-sec/file?kind=gamedata&file="
|
||||||
```
|
```
|
||||||
|
|
||||||
e gli altri URL secure equivalenti.
|
e gli altri URL secure equivalenti.
|
||||||
@@ -124,7 +124,7 @@ e gli altri URL secure equivalenti.
|
|||||||
Conviene usare i path plain classici, per esempio:
|
Conviene usare i path plain classici, per esempio:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
"gamedata.url": "https://hotel.slogga.it/client/nitro/gamedata"
|
"gamedata.url": "https://hotel.example.com/client/nitro/gamedata"
|
||||||
```
|
```
|
||||||
|
|
||||||
oppure lasciare il renderer configurato com’è e demandare il fallback a `secure-assets.ts`.
|
oppure lasciare il renderer configurato com’è e demandare il fallback a `secure-assets.ts`.
|
||||||
@@ -214,9 +214,9 @@ nitro.secure.master_key=change-me-to-a-long-random-secret
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": true,
|
"secureAssetsEnabled": true,
|
||||||
"secureApiEnabled": true,
|
"secureApiEnabled": true,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -239,9 +239,9 @@ nitro.secure.master_key=una-chiave-lunga-random
|
|||||||
"distObfuscationEnabled": true,
|
"distObfuscationEnabled": true,
|
||||||
"secureAssetsEnabled": false,
|
"secureAssetsEnabled": false,
|
||||||
"secureApiEnabled": false,
|
"secureApiEnabled": false,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -261,9 +261,9 @@ nitro.secure.api.enabled=false
|
|||||||
"distObfuscationEnabled": false,
|
"distObfuscationEnabled": false,
|
||||||
"secureAssetsEnabled": false,
|
"secureAssetsEnabled": false,
|
||||||
"secureApiEnabled": false,
|
"secureApiEnabled": false,
|
||||||
"apiBaseUrl": "https://nitro.slogga.it:2096",
|
"apiBaseUrl": "https://nitro.example.com:2096",
|
||||||
"plainConfigBaseUrl": "https://hotel.slogga.it/",
|
"plainConfigBaseUrl": "https://hotel.example.com/",
|
||||||
"plainGamedataBaseUrl": "https://hotel.slogga.it/client/nitro/gamedata/"
|
"plainGamedataBaseUrl": "https://hotel.example.com/client/nitro/gamedata/"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -49,7 +49,7 @@
|
|||||||
const renderShell = () => {
|
const renderShell = () => {
|
||||||
const root = document.getElementById("root");
|
const root = document.getElementById("root");
|
||||||
if(!root || root.firstChild) return;
|
if(!root || root.firstChild) return;
|
||||||
root.innerHTML = '<div style="position:fixed;inset:0;background:#6eadc8;overflow:hidden;z-index:1"><img src="https://hotel.slogga.it/client/nitro/images/reception/background_gradient_apr25.png" style="position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center top" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/mute_reception_backdrop_left.png" style="position:absolute;left:0;bottom:0;width:100%;height:100%;object-fit:none;object-position:left bottom" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/background_right.png" style="position:absolute;right:0;bottom:0;width:400px;height:100%;object-fit:none;object-position:right bottom" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/drape.png" style="position:absolute;left:0;top:0;width:190px;height:220px;object-fit:contain;object-position:left top" alt=""><div style="position:absolute;top:50%;right:8vw;transform:translateY(-50%);display:flex;flex-direction:column;gap:18px;width:260px"><div style="height:86px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div><div style="height:190px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div></div></div>';
|
root.innerHTML = '<div style="position:fixed;inset:0;background:#6eadc8;overflow:hidden;z-index:1"><img src="https://hotel.example.com/client/nitro/images/reception/background_gradient_apr25.png" style="position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center top" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/mute_reception_backdrop_left.png" style="position:absolute;left:0;bottom:0;width:100%;height:100%;object-fit:none;object-position:left bottom" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/background_right.png" style="position:absolute;right:0;bottom:0;width:400px;height:100%;object-fit:none;object-position:right bottom" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/drape.png" style="position:absolute;left:0;top:0;width:190px;height:220px;object-fit:contain;object-position:left top" alt=""><div style="position:absolute;top:50%;right:8vw;transform:translateY(-50%);display:flex;flex-direction:column;gap:18px;width:260px"><div style="height:86px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div><div style="height:190px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div></div></div>';
|
||||||
};
|
};
|
||||||
|
|
||||||
const decodeAsset = (bytes) => {
|
const decodeAsset = (bytes) => {
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
{
|
{
|
||||||
"socket.url": "ws://192.168.1.52:2096",
|
"socket.url": "wss://nitro.example.com:2096",
|
||||||
"api.url": "http://192.168.1.52:2096",
|
"api.url": "https://nitro.example.com:2096",
|
||||||
"asset.url": "https://hotel.slogga.it/client/nitro/bundled",
|
"asset.url": "https://hotel.example.com/client/nitro/bundled",
|
||||||
"image.library.url": "https://hotel.slogga.it/client/c_images/",
|
"image.library.url": "https://hotel.example.com/client/c_images/",
|
||||||
"hof.furni.url": "https://hotel.slogga.it/client/c_images/dcr/hof_furni",
|
"hof.furni.url": "https://hotel.example.com/client/c_images/dcr/hof_furni",
|
||||||
"images.url": "https://hotel.slogga.it/client/nitro/images",
|
"images.url": "https://hotel.example.com/client/nitro/images",
|
||||||
"gamedata.url": "http://192.168.1.52:2096/nitro-sec/file?kind=gamedata&file=",
|
"gamedata.url": "https://nitro.example.com:2096/nitro-sec/file?kind=gamedata&file=",
|
||||||
"sounds.url": "${asset.url}/sounds/%sample%.mp3",
|
"sounds.url": "${asset.url}/sounds/%sample%.mp3",
|
||||||
"external.texts.url": [
|
"external.texts.url": [
|
||||||
"${gamedata.url}/ExternalTexts.json",
|
"${gamedata.url}/ExternalTexts.json",
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"image.library.notifications.url": "${image.library.url}notifications/%image%.png",
|
"image.library.notifications.url": "${image.library.url}notifications/%image%.png",
|
||||||
"achievements.images.url": "${image.library.url}Quests/%image%.png",
|
"achievements.images.url": "${image.library.url}Quests/%image%.png",
|
||||||
"camera.url": "https://hotel.slogga.it/client/camera/",
|
"camera.url": "https://hotel.example.com/client/camera/",
|
||||||
"thumbnails.url": "https://hotel.slogga.it/client/camera/thumbnail/%thumbnail%.png",
|
"thumbnails.url": "https://hotel.example.com/client/camera/thumbnail/%thumbnail%.png",
|
||||||
"url.prefix": "",
|
"url.prefix": "",
|
||||||
"habbopages.url": "/gamedata/habbopages/",
|
"habbopages.url": "/gamedata/habbopages/",
|
||||||
"group.homepage.url": "${url.prefix}/groups/%groupid%/id",
|
"group.homepage.url": "${url.prefix}/groups/%groupid%/id",
|
||||||
@@ -30,9 +30,9 @@
|
|||||||
"show.google.ads": false,
|
"show.google.ads": false,
|
||||||
"loginview": {
|
"loginview": {
|
||||||
"images": {
|
"images": {
|
||||||
"background": "https://hotel.slogga.it/client/nitro/images/reception/background_gradient_apr25.png", "drape": "https://hotel.slogga.it/client/nitro/images/reception/drape.png",
|
"background": "https://hotel.example.com/client/nitro/images/reception/background_gradient_apr25.png", "drape": "https://hotel.example.com/client/nitro/images/reception/drape.png",
|
||||||
"left": "https://hotel.slogga.it/client/nitro/images/reception/mute_reception_backdrop_left.png",
|
"left": "https://hotel.example.com/client/nitro/images/reception/mute_reception_backdrop_left.png",
|
||||||
"right": "https://hotel.slogga.it/client/nitro/images/reception/background_right.png"
|
"right": "https://hotel.example.com/client/nitro/images/reception/background_right.png"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"navigator.room.models": [
|
"navigator.room.models": [
|
||||||
@@ -1575,11 +1575,11 @@
|
|||||||
},
|
},
|
||||||
"loginview": {
|
"loginview": {
|
||||||
"images": {
|
"images": {
|
||||||
"background": "https://hotel.slogga.it/client/nitro/images/reception/background_gradient_apr25.png",
|
"background": "https://hotel.example.com/client/nitro/images/reception/background_gradient_apr25.png",
|
||||||
"background.colour": "#6eadc8",
|
"background.colour": "#6eadc8",
|
||||||
"drape": "https://hotel.slogga.it/client/nitro/images/reception/drape.png",
|
"drape": "https://hotel.example.com/client/nitro/images/reception/drape.png",
|
||||||
"left": "https://hotel.slogga.it/client/nitro/images/reception/mute_reception_backdrop_left.png",
|
"left": "https://hotel.example.com/client/nitro/images/reception/mute_reception_backdrop_left.png",
|
||||||
"right": "https://hotel.slogga.it/client/nitro/images/reception/background_right.png"
|
"right": "https://hotel.example.com/client/nitro/images/reception/background_right.png"
|
||||||
},
|
},
|
||||||
"widgets": {
|
"widgets": {
|
||||||
"slot.1.widget": "promoarticle",
|
"slot.1.widget": "promoarticle",
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ const loader = `(() => {
|
|||||||
const renderShell = () => {
|
const renderShell = () => {
|
||||||
const root = document.getElementById("root");
|
const root = document.getElementById("root");
|
||||||
if(!root || root.firstChild) return;
|
if(!root || root.firstChild) return;
|
||||||
root.innerHTML = '<div style="position:fixed;inset:0;background:#6eadc8;overflow:hidden;z-index:1"><img src="https://hotel.slogga.it/client/nitro/images/reception/background_gradient_apr25.png" style="position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center top" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/mute_reception_backdrop_left.png" style="position:absolute;left:0;bottom:0;width:100%;height:100%;object-fit:none;object-position:left bottom" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/background_right.png" style="position:absolute;right:0;bottom:0;width:400px;height:100%;object-fit:none;object-position:right bottom" alt=""><img src="https://hotel.slogga.it/client/nitro/images/reception/drape.png" style="position:absolute;left:0;top:0;width:190px;height:220px;object-fit:contain;object-position:left top" alt=""><div style="position:absolute;top:50%;right:8vw;transform:translateY(-50%);display:flex;flex-direction:column;gap:18px;width:260px"><div style="height:86px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div><div style="height:190px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div></div></div>';
|
root.innerHTML = '<div style="position:fixed;inset:0;background:#6eadc8;overflow:hidden;z-index:1"><img src="https://hotel.example.com/client/nitro/images/reception/background_gradient_apr25.png" style="position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center top" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/mute_reception_backdrop_left.png" style="position:absolute;left:0;bottom:0;width:100%;height:100%;object-fit:none;object-position:left bottom" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/background_right.png" style="position:absolute;right:0;bottom:0;width:400px;height:100%;object-fit:none;object-position:right bottom" alt=""><img src="https://hotel.example.com/client/nitro/images/reception/drape.png" style="position:absolute;left:0;top:0;width:190px;height:220px;object-fit:contain;object-position:left top" alt=""><div style="position:absolute;top:50%;right:8vw;transform:translateY(-50%);display:flex;flex-direction:column;gap:18px;width:260px"><div style="height:86px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div><div style="height:190px;background:#a2bfd1;border:2px solid #3f6a85;border-radius:8px;box-shadow:inset 0 2px rgba(255,255,255,.35),0 4px 6px rgba(0,0,0,.25)"></div></div></div>';
|
||||||
};
|
};
|
||||||
|
|
||||||
const decodeAsset = (bytes) => {
|
const decodeAsset = (bytes) => {
|
||||||
|
|||||||
+1
-1
@@ -27,7 +27,7 @@ const cacheBustUrl = (path: string): string =>
|
|||||||
return url.toString();
|
return url.toString();
|
||||||
};
|
};
|
||||||
|
|
||||||
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'http://192.168.1.52:2096/';
|
(window as any).NitroSecureApiUrl = clientMode.apiBaseUrl || 'https://nitro.example.com:2096/';
|
||||||
(window as any).NitroClientMode = clientMode;
|
(window as any).NitroClientMode = clientMode;
|
||||||
(window as any).NitroConfig = {
|
(window as any).NitroConfig = {
|
||||||
'config.urls': [
|
'config.urls': [
|
||||||
|
|||||||
@@ -61,11 +61,11 @@ const MAX_ATTEMPTS = 5;
|
|||||||
const LOCK_WINDOW_MS = 60_000;
|
const LOCK_WINDOW_MS = 60_000;
|
||||||
const LOCK_DURATION_MS = 2 * 60_000;
|
const LOCK_DURATION_MS = 2 * 60_000;
|
||||||
const DEFAULT_LOGIN_IMAGES: Record<string, string> = {
|
const DEFAULT_LOGIN_IMAGES: Record<string, string> = {
|
||||||
background: 'https://hotel.slogga.it/client/nitro/images/reception/background_gradient_apr25.png',
|
background: 'https://hotel.example.com/client/nitro/images/reception/background_gradient_apr25.png',
|
||||||
'background.colour': '#6eadc8',
|
'background.colour': '#6eadc8',
|
||||||
drape: 'https://hotel.slogga.it/client/nitro/images/reception/drape.png',
|
drape: 'https://hotel.example.com/client/nitro/images/reception/drape.png',
|
||||||
left: 'https://hotel.slogga.it/client/nitro/images/reception/mute_reception_backdrop_left.png',
|
left: 'https://hotel.example.com/client/nitro/images/reception/mute_reception_backdrop_left.png',
|
||||||
right: 'https://hotel.slogga.it/client/nitro/images/reception/background_right.png'
|
right: 'https://hotel.example.com/client/nitro/images/reception/background_right.png'
|
||||||
};
|
};
|
||||||
const LOGIN_LOCALES: LoginLocale[] = [
|
const LOGIN_LOCALES: LoginLocale[] = [
|
||||||
{ code: 'it', file: 'it', label: 'Italiano', flag: flagIt },
|
{ code: 'it', file: 'it', label: 'Italiano', flag: flagIt },
|
||||||
|
|||||||
@@ -194,7 +194,7 @@ const getApiBase = (): string =>
|
|||||||
|
|
||||||
if(typeof configured === 'string' && configured.length) return configured.replace(/\/$/, '');
|
if(typeof configured === 'string' && configured.length) return configured.replace(/\/$/, '');
|
||||||
|
|
||||||
return 'http://localhost:8443/';
|
return 'https://nitro.example.com:2096/';
|
||||||
};
|
};
|
||||||
|
|
||||||
const getPlainAssetBase = (kind: 'config' | 'gamedata'): string =>
|
const getPlainAssetBase = (kind: 'config' | 'gamedata'): string =>
|
||||||
|
|||||||
+2
-2
@@ -18,12 +18,12 @@ export default defineConfig({
|
|||||||
},
|
},
|
||||||
proxy: {
|
proxy: {
|
||||||
'/api': {
|
'/api': {
|
||||||
target: process.env.AUTH_PROXY_TARGET || 'http://192.168.1.52:2096/',
|
target: process.env.AUTH_PROXY_TARGET || 'https://nitro.example.com:2096/',
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
ws: true,
|
ws: true,
|
||||||
},
|
},
|
||||||
'/nitro-sec': {
|
'/nitro-sec': {
|
||||||
target: process.env.NITRO_PROXY_TARGET || 'http://192.168.1.52:2096/',
|
target: process.env.NITRO_PROXY_TARGET || 'https://nitro.example.com:2096/',
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
ws: true,
|
ws: true,
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user