Skip to content

Commit

Permalink
fix: change to define html public file from admin service
Browse files Browse the repository at this point in the history
  • Loading branch information
gparant committed Feb 7, 2024
1 parent 790fe95 commit 37ceb92
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
- run: npm run test
#- run: sed -i 's|""|"https://cdn.jsdelivr.net/npm/@workadventure/scripting-api-extra@${{ env.release_tag }}/dist"|g' src/Features/default_assets_url.ts
- run: sed -i 's|""|"https://unpkg.com/@workadventure/scripting-api-extra@${{ env.release_tag }}/dist"|g' src/Features/default_assets_url.ts
- run: sed -i 's|""|"https://admin.workadventu.re/iframe"|g' src/Features/workadventure_assets_url.ts
- run: sed -i 's|""|"https://admin.workadventu.re/html"|g' src/Features/workadventure_assets_url.ts
- run: npm run build --if-present

# Deployment on Github Pages
Expand Down
4 changes: 2 additions & 2 deletions src/Features/doors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import type { ITiledMapLayer, ITiledMapObject } from "@workadventure/tiled-map-t
import type { ITiledMapTileLayer } from "@workadventure/tiled-map-type-guard/dist/ITiledMapTileLayer";
import type { Popup, ActionMessage, EmbeddedWebsite } from "@workadventure/iframe-api-typings";
import { defaultAssetsUrl } from "./default_assets_url";
import { workadventureAssetsUrl } from "./workadventure_assets_url";
import { workadventureAssetsHtmlUrl } from "./workadventure_assets_url";
import { getAreaObject } from "../AreaObject";

let layersMap!: Map<string, ITiledMapLayer>;
Expand Down Expand Up @@ -363,7 +363,7 @@ function initBellLayer(
* assetsUrl is the URL to the assets directory containing the compiled "keypad.html" file (for digit code)
*/
export async function initDoors(assetsUrl?: string | undefined): Promise<void> {
assetsUrl = assetsUrl ?? (workadventureAssetsUrl || defaultAssetsUrl);
assetsUrl = assetsUrl ?? (workadventureAssetsHtmlUrl || defaultAssetsUrl);
const variables = await getVariables();
layersMap = await getLayersMap();

Expand Down
2 changes: 1 addition & 1 deletion src/Features/workadventure_assets_url.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
* The base URL for the workadventure assets.
* This file is updated dynamically during the package build process.
*/
export const workadventureAssetsUrl = "";
export const workadventureAssetsHtmlUrl = "";

0 comments on commit 37ceb92

Please sign in to comment.