-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
arc download improvements; progress dialog; import protocol
- Loading branch information
Showing
12 changed files
with
201 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
<script lang="ts" setup> | ||
import { useDialogPluginComponent } from 'quasar'; | ||
import { reactive, onMounted } from 'vue'; | ||
const iProps = reactive({ | ||
value: '' | ||
}); | ||
defineEmits([ | ||
...useDialogPluginComponent.emits | ||
]); | ||
const { dialogRef, onDialogHide, onDialogOK, onDialogCancel } = useDialogPluginComponent(); | ||
const onSubmit = async () => { | ||
onDialogOK([true,iProps.value]); | ||
}; | ||
const importProtocol = async ()=>{ | ||
const files = await window.ipc.invoke('LocalFileSystemService.selectAny'); | ||
onDialogOK([false,files]); | ||
}; | ||
</script> | ||
|
||
<template> | ||
<q-form | ||
@submit="onSubmit" | ||
> | ||
<q-dialog ref="dialogRef" @hide="onDialogHide" persistent> | ||
<q-card class="q-dialog-plugin" style="min-width:45em;"> | ||
<q-card-section> | ||
<div class="text-h6">Create or Import Protocol</div> | ||
</q-card-section> | ||
|
||
<q-card-section> | ||
<q-input | ||
filled | ||
v-model="iProps.value" | ||
label="Protocol Name" | ||
:rules="[ | ||
val => !!val || `invalid ${props.property}`, | ||
]" | ||
lazy-rules | ||
/> | ||
</q-card-section> | ||
|
||
<q-card-actions align="right" style="margin:0 1.5em 1.5em;"> | ||
<q-btn color="secondary" icon='add_box' label="New Protocol" type='submit' class='text-weight-bold' /> | ||
<q-btn color="secondary" icon='open_in_new' label="Import Protocol" @click='importProtocol' class='text-weight-bold' /> | ||
<q-btn color="secondary" label="Cancel" @click="onDialogCancel" class='text-weight-bold'/> | ||
</q-card-actions> | ||
</q-card> | ||
|
||
</q-dialog> | ||
</q-form> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
<script lang="ts" setup> | ||
import { useDialogPluginComponent } from 'quasar'; | ||
import { reactive, onMounted } from 'vue'; | ||
export interface Props { | ||
items: Array, | ||
title: String, | ||
ok_title: String, | ||
cancel_title: String, | ||
error: String | ||
}; | ||
const props = defineProps<Props>(); | ||
const iProps = reactive({ | ||
value: '' | ||
}); | ||
defineEmits([ | ||
...useDialogPluginComponent.emits | ||
]); | ||
const { dialogRef, onDialogHide, onDialogOK, onDialogCancel } = useDialogPluginComponent(); | ||
</script> | ||
|
||
<template> | ||
<q-dialog ref="dialogRef" @hide="onDialogHide" persistent> | ||
<q-card class="q-dialog-plugin" style="min-width:45em;"> | ||
<q-card-section> | ||
<div class="text-h6">{{props.title}}</div> | ||
</q-card-section> | ||
|
||
<q-card-section> | ||
<q-list> | ||
<q-item v-for='item in props.items'> | ||
<q-item-section avatar style="min-width:2em;"> | ||
<q-circular-progress | ||
:indeterminate='item[1]<1' | ||
rounded | ||
size="2em" | ||
:thickness="0.7" | ||
track-color="grey-3" | ||
:color="item[1]===2 ? 'red-8' : item[1]===1 ? 'green' : 'primary'" | ||
class="q-ma-md" | ||
:value='100' | ||
/> | ||
</q-item-section> | ||
<q-item-section> | ||
<q-item-label>{{item[0]}}</q-item-label> | ||
</q-item-section> | ||
</q-item> | ||
</q-list> | ||
|
||
<q-banner rounded inline-actions class="bg-red-10 text-white" dense v-if='props.error'> | ||
<template v-slot:avatar> | ||
<q-icon name="warning"/> | ||
</template> | ||
<div v-html='props.error'></div> | ||
</q-banner> | ||
|
||
</q-card-section> | ||
|
||
<q-card-actions align="right" style="margin:0 1.5em 1.5em;"> | ||
<q-btn color="secondary" :label="props.ok_title" @click="onDialogOK" type='submit' class='text-weight-bold' :disabled='props.items[props.items.length-1][1]!==1'/> | ||
<q-btn color="secondary" :label="props.cancel_title" @click="onDialogCancel" class='text-weight-bold' :disabled='props.items[props.items.length-1][1]<1'/> | ||
</q-card-actions> | ||
</q-card> | ||
|
||
</q-dialog> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
export default ` | ||
# Git Help | ||
` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters