5180 fichiers 38.5 Mo 0 téléchargements 147 vues mis à jour il y a 4 heures ui
nitro-v36-with-renderer-v36 / src / common / AutoGrid.test.tsx
AutoGrid.test.tsx 706 o Télécharger le fichier
import { render } from '@testing-library/react';
import { describe, expect, it } from 'vitest';
import { AutoGrid } from './AutoGrid';

describe('AutoGrid responsive columns', () => {
    it('preserves the template tile width while distributing the remaining row space', () => {
        const { getByRole } = render(
            <AutoGrid aria-label="Template offers" className="octane-catalog-grid" columnCount={6} columnMinWidth={55} role="listbox" />
        );
        const grid = getByRole('listbox');

        expect(grid.style.getPropertyValue('--octane-grid-column-min-width')).toBe('55px');
        expect(grid.style.gridTemplateColumns).toBe('repeat(auto-fill, minmax(55px, 1fr))');
    });
});
15Sujets
1Dépôts
20Membres
7En ligne
Profile
Inscrit
Dernière visite
Messages
0
Votes positifs
0
Votes négatifs
0

Nous utilisons des cookies pour assurer le bon fonctionnement du site et améliorer votre expérience. en savoir plus

Autoriser