Files
pleno-vue/src/components/displays/superuser/configuration/ConfigurationSwitch.vue
T
Jepp9350 18dc8fb40f Add Department POS module and related views
Introduced Department POS functionality with navigation, orders, and order detail views. Set up routing and middleware for POS operations. Added base styles, assets, and updated package dependencies to support these changes.
2025-02-25 08:20:04 +01:00

36 lines
740 B
Vue

<script setup>
import { defineProps } from 'vue';
const props = defineProps({
onSwitch: Function,
value: Boolean,
title: String,
disabled: Boolean,
description: String,
icon: String,
color: String,
});
const uniqueId = Math.random().toString(36).substring(7);
</script>
<template>
<div class="field">
<label class="label">{{ title }}</label>
<input
:id="uniqueId"
type="checkbox"
:name="uniqueId"
class="switch is-rounded is-outlined is-success"
:checked="value"
@change="onSwitch($event.target.checked)"
:disabled="disabled"
/>
<label :for="uniqueId" class="label"></label>
<p class="help">{{ description }}</p>
</div>
</template>
<style scoped>
</style>