mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
30 lines
710 B
Vue
30 lines
710 B
Vue
<template>
|
|
<ul class="record_actions" v-if="!options.onlyButton"
|
|
:class="{ 'sticky-form-buttons': isStickyForm }">
|
|
|
|
<li v-if="isStickyForm" class="cancel">
|
|
<slot name="before"></slot>
|
|
</li>
|
|
<li>
|
|
<slot name="action"></slot>
|
|
</li>
|
|
<li v-if="isStickyForm">
|
|
<slot name="after"></slot>
|
|
</li>
|
|
</ul>
|
|
<slot v-else name="action"></slot>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
name: "ActionButtons",
|
|
props: ['options', 'defaultz'],
|
|
computed: {
|
|
isStickyForm() {
|
|
return (typeof this.options.stickyActions !== 'undefined') ?
|
|
this.options.stickyActions : this.defaultz.stickyActions;
|
|
},
|
|
}
|
|
}
|
|
</script>
|