Static radio for usage outside forms as visual indicator without focusing and clicking
All available props see in PrimitiveRadio.props.ts
<template>
<primitive-radio :value="value">
<input type="radio" :checked="value" @change="onChange" />
</primitive-radio>
</template>
<script setup lang="ts">
import { PrimitiveRadio } from '@tok/ui/components/PrimitiveRadio';
import { ref } from 'vue';
const value = ref(false);
const onChange = (event: Event) => {
const target = event.target as HTMLInputElement;
const _value = target.value;
// manipulate with _value
};
</script>