mirror of
https://github.com/frappe/books.git
synced 2026-08-24 10:04:45 -05:00
Merge branch 'frappe:master' into master
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "frappe-books",
|
||||
"version": "0.29.0",
|
||||
"version": "0.30.0",
|
||||
"description": "Simple book-keeping app for everyone",
|
||||
"author": {
|
||||
"name": "Frappe Technologies Pvt. Ltd.",
|
||||
|
||||
@@ -0,0 +1,65 @@
|
||||
<template>
|
||||
<div
|
||||
:class="[containerClasses]"
|
||||
class="
|
||||
mt-6
|
||||
p-2
|
||||
w-full
|
||||
text-gray-900
|
||||
dark:text-gray-100
|
||||
text-base
|
||||
focus:outline-none
|
||||
"
|
||||
>
|
||||
<label class="flex items-center justify-between w-full">
|
||||
<div v-if="showLabel && !labelRight" :class="labelClasses">
|
||||
{{ df.label }}
|
||||
</div>
|
||||
<button
|
||||
:class="['flex items-center justify-center']"
|
||||
@click="onClick"
|
||||
:disabled="isReadOnly"
|
||||
type="button"
|
||||
></button>
|
||||
</label>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
import Base from './Base.vue';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'Button',
|
||||
extends: Base,
|
||||
props: {
|
||||
spaceBetween: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
labelRight: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
labelClass: {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
showLabel: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
labelClasses() {
|
||||
return this.labelClass || 'text-gray-600 text-base';
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
onClick(e: Event) {
|
||||
if (this.isReadOnly) return;
|
||||
this.triggerChange(true);
|
||||
},
|
||||
},
|
||||
});
|
||||
</script>
|
||||
@@ -4,6 +4,7 @@ import AttachImage from './AttachImage.vue';
|
||||
import Attachment from './Attachment.vue';
|
||||
import AutoComplete from './AutoComplete.vue';
|
||||
import Check from './Check.vue';
|
||||
import Button from './Button.vue';
|
||||
import Color from './Color.vue';
|
||||
import Currency from './Currency.vue';
|
||||
import Data from './Data.vue';
|
||||
@@ -20,6 +21,7 @@ const components = {
|
||||
AttachImage,
|
||||
Data,
|
||||
Check,
|
||||
Button,
|
||||
Color,
|
||||
Select,
|
||||
Link,
|
||||
|
||||
Reference in New Issue
Block a user