import { TileSlider, type RenderTile, type RenderControl } from '@videodock/tile-slider';
type Tile = {
  title: string;
  image: string;
};
const items: Tile[] = Array.from({ length: 10 }, (_, index) => ({
  title: `Tile ${index}`,
  image: `/img/${index}.jpg`,
}));
const renderTile: RenderTile<Tile> = ({ item, isVisible }) => (
  <div className={'exampleTile'}>
    <img src={item.image} alt={item.title} />
  </div>
);
const renderLeftControl: RenderControl = ({ onClick }) => (
  <button className="control" onClick={onClick}>
    <IconLeft />
  </button>
);
const renderRightControl: RenderControl = ({ onClick }) => (
  <button className="control" onClick={onClick}>
    <IconRight />
  </button>
);
const Slider = () => {
  return (
    <TileSlider
      tilesToShow={3}
      renderTile={renderTile}
      items={items}
      renderRightControl={renderRightControl}
      renderLeftControl={renderLeftControl}
    />
  );
};