mirror of
https://github.com/garraflavatra/rolens.git
synced 2025-07-17 05:24:06 +00:00
26 lines
390 B
Svelte
26 lines
390 B
Svelte
<script>
|
|
import { ChooseDirectory } from '$wails/go/app/App.js';
|
|
|
|
export let value = '';
|
|
export let id = '';
|
|
export let title = 'Choose a directory';
|
|
|
|
async function selectDir() {
|
|
value = await ChooseDirectory(title) || value;
|
|
}
|
|
</script>
|
|
|
|
<input
|
|
type="text"
|
|
on:pointerdown={selectDir}
|
|
readonly
|
|
{id}
|
|
{value}
|
|
/>
|
|
|
|
<style>
|
|
input {
|
|
cursor: pointer;
|
|
}
|
|
</style>
|