REAVIZ

Heat Map XL

Cards 95

About

Here is heat map xl sized

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Heat Map XL to your project and fits it to your theme.

Code

How Heat Map XL is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import React from 'react';
import IncidentHeatmapReportCard from '@/components/ui/heat-map-xl';

function IncidentHeatmapReportCardDemo() {
  const [isDarkMode, setIsDarkMode] = React.useState(false);

  const toggleDarkMode = () => {
    setIsDarkMode(prevMode => {
      const newMode = !prevMode;
      if (newMode) {
        document.documentElement.classList.add('dark');
      } else {
        document.documentElement.classList.remove('dark');
      }
      return newMode;
    });
  };

  React.useEffect(() => {
    const mediaQuery = window.matchMedia('(prefers-color-scheme: dark)');
    const handleChange = (e: MediaQueryListEvent) => {
      setIsDarkMode(e.matches);
      if (e.matches) {
        document.documentElement.classList.add('dark');
      } else {
        document.documentElement.classList.remove('dark');
      }
    };

    setIsDarkMode(mediaQuery.matches);
    if (mediaQuery.matches) {
      document.documentElement.classList.add('dark');
    }
    
    mediaQuery.addEventListener('change', handleChange);
    return () => mediaQuery.removeEventListener('change', handleChange);
  }, []);

  return (
    <div className="flex flex-col items-center justify-center min-h-screen bg-gray-100 dark:bg-gray-900 p-4 transition-colors duration-300">
      <button 
        onClick={toggleDarkMode} 
        aria-pressed={isDarkMode}
        className="mb-4 px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600 dark:bg-blue-700 dark:hover:bg-blue-800 transition-colors duration-300 focus:outline-none focus:ring-2 focus:ring-blue-400"
      >
        Toggle Dark Mode ({isDarkMode ? 'On' : 'Off'})
      </button>
      <IncidentHeatmapReportCard />
    </div>
  );
}

export default IncidentHeatmapReportCardDemo;

Dependencies

More by REAVIZ

View all
  • Funnel Chart Big

    Funnel Chart Big

    126
  • Area Chart

    Area Chart

    85
  • Stacked Diverging bar

    Stacked Diverging bar

    76
  • Layered Chart XL

    Layered Chart XL

    71
  • Hexagon map

    Hexagon map

    69
  • Area Chart

    Area Chart

    69
  • Incident Report Large

    Incident Report Large

    54
  • Incident Bar Chart

    Incident Bar Chart

    53

More in Cards

View all
  • Statistics Card 2

    Statistics Card 2

    264
  • Course Design Cards

    Course Design Cards

    1.1K
  • Card

    Card

    70
  • Stats cards with links

    Stats cards with links

    39
  • The Item one

    The Item one

    3
  • Card Studio

    Card Studio

    7
  • Statistics Card 7

    Statistics Card 7

    292
  • Item

    Item

    10