Add local HTML download and release 0.0.3

This commit is contained in:
Schluffe committed 2026-10-09 15:25:56 +02:00
1 parent bee62a79a9
commit 62c749de73
10 files changed
+98 -12

No files matched your search

+2
View File
@@ -4,6 +4,7 @@ import SendPanel from './components/SendPanel.vue';
import ReceivePanel from './components/ReceivePanel.vue';
const mode = ref<'send' | 'receive'>('send');
const canDownloadApp = import.meta.env.PROD && location.protocol !== 'file:';
</script>
<template>
@@ -14,6 +15,7 @@ const mode = ref<'send' | 'receive'>('send');
Browser-to-browser file sharing. No account or file-hosting backend.
Direct WebRTC connections, with an optional relay you explicitly enable.
</p>
<a v-if="canDownloadApp" class="app-download" href="./hellcon-local.html" download="HellCon.html">Download app for local use</a>
<div class="tabs" role="group" aria-label="Transfer mode">
<button :class="{ active: mode === 'send' }" :aria-pressed="mode === 'send'" @click="mode = 'send'">Send</button>
+1 -1
View File
@@ -3,7 +3,7 @@ import type { IceOptions, NetworkSettings } from '../lib/webrtc.ts';
import { STUN_PROVIDERS } from '../lib/webrtc.ts';
const settings = defineModel<NetworkSettings>({ required: true });
defineProps<{ disabled?: boolean; managedCredentials?: IceOptions | null }>();
const iceEndpoint = import.meta.env.VITE_ICE_ENDPOINT || '';
const iceEndpoint = location.protocol === 'file:' ? '' : import.meta.env.VITE_ICE_ENDPOINT || '';
</script>
<template>
+2 -2
View File
@@ -31,8 +31,8 @@ const incoming = ref<FileMetadata | null>(null);
const downloadUrl = ref('');
const choosing = ref(false);
const dragover = ref(false);
const iceEndpoint = import.meta.env.VITE_ICE_ENDPOINT || '';
const defaultStun = import.meta.env.VITE_STUN_URL || '';
const iceEndpoint = location.protocol === 'file:' ? '' : import.meta.env.VITE_ICE_ENDPOINT || '';
const defaultStun = location.protocol === 'file:' ? '' : import.meta.env.VITE_STUN_URL || '';
const settings = ref<NetworkSettingsModel>({ stunChoice: defaultStun ? 'custom' : 'google', customStun: defaultStun, allowTurn: false, managedTurn: !!iceEndpoint, turnUrl: '', username: '', credential: '' });
const managedCredentials = ref<IceOptions | null>(null);
const canSaveToDisk = typeof window.showSaveFilePicker === 'function';
+6
View File
@@ -75,6 +75,12 @@ h1 {
font-size: 0.9rem;
}
.app-download {
color: var(--accent);
margin: -0.5rem 0 1.5rem;
font-size: 0.9rem;
}
.tabs {
display: flex;
gap: 0.5rem;