fix: TS syntax in define:vars IIFEs causes SyntaxError — use plain JS for authUrl
This commit is contained in:
@@ -592,7 +592,7 @@ try {
|
||||
<!-- User widget: only needed for multi-user (single-user nav links are static) -->
|
||||
{!singleHandle && (
|
||||
<script define:vars={{ baseUrl }}>
|
||||
const authUrl: string = (window as any).__bincioAuthUrl ?? '';
|
||||
const authUrl = window.__bincioAuthUrl || '';
|
||||
(async () => {
|
||||
try {
|
||||
const r = await fetch('/api/me', { credentials: 'include' });
|
||||
@@ -734,7 +734,7 @@ try {
|
||||
|
||||
{editEnabled && (
|
||||
<script define:vars={{ editUrl, baseUrl }}>
|
||||
const authUrl: string = (window as any).__bincioAuthUrl ?? '';
|
||||
const authUrl = window.__bincioAuthUrl || '';
|
||||
const modal = document.getElementById('upload-modal');
|
||||
const openBtn = document.getElementById('upload-btn');
|
||||
const closeBtn = document.getElementById('upload-close');
|
||||
|
||||
Reference in New Issue
Block a user