UNPKG

@jmeirinkmarimed/map-selector

Version:

A web component for displaying and interacting with a US state map

48 lines (35 loc) 1.2 kB
# @jmeirinkmarimed/map-selector A web component for displaying and interacting with a US state map. Built with React and bundled as a standalone web component. ## Usage The component can be used in any HTML file. Simply import the script and use the custom element: ```html <!-- Import the web component --> <script type="module" src="https://unpkg.com/@jmeirinkmarimed/map-selector@0.0.10/dist/map-selector.js"></script> <!-- Use the component --> <map-selector></map-selector> ``` ### Example ```html <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Map Selector Example</title> </head> <body> <div style="width: 800px; height: 600px;"> <map-selector></map-selector> </div> <script type="module" src="https://unpkg.com/@jmeirinkmarimed/map-selector@0.0.10/dist/map-selector.js"></script> </body> </html> ``` ## Features - Interactive US state map - Click states to view details - Displays state-specific information in a tooltip - Fully self-contained web component (includes all dependencies) - Responsive design ## License UNLICENSED - All rights reserved