import { describe, it, expect } from 'vitest';
import { mount } from '@vue/test-utils';
import Kbd from '../../resources/js/components/ui/Kbd.vue';

describe('Kbd', () => {
    it('renders default slot content', () => {
        const w = mount(Kbd, { slots: { default: () => '⌘K' } });
        expect(w.text()).toBe('⌘K');
        expect(w.element.tagName).toBe('KBD');
    });

    it('applies dark variant when prop dark=true', () => {
        const w = mount(Kbd, {
            props: { dark: true },
            slots: { default: () => 'Esc' },
        });
        expect(w.classes()).toContain('ld-kbd--dark');
    });
});
