// Copyright 2025 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
import React, { useEffect, useState, useId } from 'react';
import type { Meta } from '@storybook/react';
import { VisuallyHidden } from 'react-aria';
import { FunGif, FunGifPreview } from './FunGif.js';
import { LoadingState } from '../../util/loadable.js';
export default {
  title: 'Components/Fun/FunGif',
} satisfies Meta;
export function Basic(): JSX.Element {
  const id = useId();
  return (
    <>
      {/* eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex */}
      
        
      
      
        A cartoon of spongebob wearing a top hat is laying on the ground
      
    >
  );
}
export function PreviewSizing(): JSX.Element {
  return (
    <>
      
      
        
      
      
        
      
    >
  );
}
export function PreviewLoading(): JSX.Element {
  const [src, setSrc] = useState(null);
  useEffect(() => {
    setTimeout(() => {
      setSrc(
        'https://media.tenor.com/tN6E5iSxeI8AAAPo/spongebob-spongebob-squarepants.mp4'
      );
    }, 2000);
  }, []);
  return (
    
  );
}
export function PreviewError(): JSX.Element {
  const [error, setError] = useState(null);
  useEffect(() => {
    setTimeout(() => {
      setError(new Error('yikes!'));
    }, 2000);
  }, []);
  return (
    
  );
}