Optional primary/default button style in taskSubmitter
This commit is contained in:
parent
d3998b7678
commit
55a68738a7
4 changed files with 31 additions and 21 deletions
|
|
@ -232,20 +232,22 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<div v-if="scanCapture" class="uk-margin uk-margin-remove-top ">
|
||||||
<taskSubmitter
|
<taskSubmitter
|
||||||
v-if="scanCapture"
|
|
||||||
:submit-url="scanUri"
|
:submit-url="scanUri"
|
||||||
:submit-data="scanPayload"
|
:submit-data="scanPayload"
|
||||||
:submit-label="'Start Scan'"
|
:submit-label="'Start Scan'"
|
||||||
|
:button-primary="true"
|
||||||
@submit="onScanSubmit"
|
@submit="onScanSubmit"
|
||||||
@response="onScanResponse"
|
@response="onScanResponse"
|
||||||
@error="onScanError"
|
@error="onScanError"
|
||||||
>
|
>
|
||||||
</taskSubmitter>
|
</taskSubmitter>
|
||||||
|
</div>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
v-else
|
v-else
|
||||||
class="uk-button uk-button-primary uk-form-small uk-margin uk-margin-remove-top uk-float-right uk-width-1-1"
|
class="uk-button uk-button-primary uk-form-small uk-margin uk-margin-remove-top uk-width-1-1"
|
||||||
@click="handleCapture()"
|
@click="handleCapture()"
|
||||||
>
|
>
|
||||||
Capture
|
Capture
|
||||||
|
|
|
||||||
|
|
@ -95,7 +95,7 @@
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<!--Show autofocus if default plugin is enabled-->
|
<!--Show autofocus if default plugin is enabled-->
|
||||||
<li class="uk-open">
|
<li v-show="fastAutofocusUri || normalAutofocusUri" class="uk-open">
|
||||||
<a class="uk-accordion-title" href="#">Autofocus</a>
|
<a class="uk-accordion-title" href="#">Autofocus</a>
|
||||||
<div class="uk-accordion-content">
|
<div class="uk-accordion-content">
|
||||||
<div class="uk-grid-small uk-child-width-expand" uk-grid>
|
<div class="uk-grid-small uk-child-width-expand" uk-grid>
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@
|
||||||
'Start recalibration? This may take a while, and the microscope will be locked during this time.'
|
'Start recalibration? This may take a while, and the microscope will be locked during this time.'
|
||||||
"
|
"
|
||||||
:submit-url="recalibrationUri"
|
:submit-url="recalibrationUri"
|
||||||
:submit-label="'Auto-Calibrate (Task)'"
|
:submit-label="'Auto-Calibrate'"
|
||||||
@response="onRecalibrateResponse"
|
@response="onRecalibrateResponse"
|
||||||
@error="onRecalibrateError"
|
@error="onRecalibrateError"
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -20,15 +20,18 @@
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div>
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
:hidden="taskRunning"
|
:hidden="taskRunning"
|
||||||
class="uk-button uk-button-primary uk-form-small uk-margin-remove uk-float-right uk-width-1-1"
|
class="uk-button uk-form-small uk-margin-remove uk-width-1-1"
|
||||||
|
:class="[buttonPrimary ? 'uk-button-primary' : 'uk-button-default']"
|
||||||
@click="bootstrapTask()"
|
@click="bootstrapTask()"
|
||||||
>
|
>
|
||||||
{{ submitLabel }}
|
{{ submitLabel }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
|
@ -76,6 +79,11 @@ export default {
|
||||||
type: String,
|
type: String,
|
||||||
required: false,
|
required: false,
|
||||||
default: "Start task?"
|
default: "Start task?"
|
||||||
|
},
|
||||||
|
buttonPrimary: {
|
||||||
|
type: Boolean,
|
||||||
|
required: false,
|
||||||
|
default: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue