@props([
    'name'     => 'view', // default to view, since it's mostly used for that
    'value'    => '',
    'class'    => '',
    'active'   => false,
    'id'       => null,
    'disabled' => false,
])

@php
    $id = $id ?: $name.'_'.$value;
@endphp

<label {{ $attributes->merge(['class' => trim($class)]) }}>
    <input
        id="{{ $id }}"
        type="radio"
        name="{{ $name }}"
        value="{{ $value }}"
        @checked($active)
        @disabled($disabled)
    >
    {{ $slot }}
</label>
