@extends('admin.layouts.app')
@section('title', 'Create Interface')
@section('content')
<div class="card" style="max-width:700px">
    <div class="card-header">Create Interface</div>
    <form action="{{ route('admin.interfaces.store') }}" method="POST" enctype="multipart/form-data">
        @csrf
        <div class="form-group">
            <label>Name *</label>
            <input type="text" name="name" class="form-control" value="{{ old('name') }}" required>
        </div>
        <div class="form-row">
            <div class="form-group">
                <label>Slug</label>
                <input type="text" name="slug" class="form-control" value="{{ old('slug') }}" placeholder="Leave empty for auto">
            </div>
            <div class="form-group">
                <label>Order</label>
                <input type="number" name="order" class="form-control" value="0" min="0">
            </div>
        </div>
        <div class="form-group">
            <label>Description</label>
            <textarea name="description" class="form-control">{{ old('description') }}</textarea>
        </div>
        <div class="form-row">
            <div class="form-group">
                <label>Image</label>
                <input type="file" name="image" class="form-control" accept="image/*">
            </div>
            <div class="form-group">
                <label class="checkbox-label" style="margin-top:25px"><input type="checkbox" name="is_active" value="1" checked> Active</label>
            </div>
        </div>
        <button type="submit" class="btn btn-primary">Create Interface</button>
    </form>
</div>
@endsection
