1.0.11 • Published 3 years ago

react-iraq-component v1.0.11

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

react-iraq-component

Alt Text

react-iraq-component Provides you with an SVG of Iraq map with the ability to highlight different provinces in different colors.

Installation

NPM

npm install react-iraq-component

Yarn

yarn add react-iraq-component

Usage

import { IraqMap } from "react-iraq-component";

const MyComponent = () => {
  return (
    <IraqMap
      data={[
        {
          name: "baghdad", // baghdad will be highlighted in red.
          color: "red",
        },
      ]}
    />
  );
};

export default MyComponent;

Props

PropDefaultDescription
DataRequiredAn array of objects { name: IProvincesNames, color: string } to highlight a province.
height100%The height of the map component.
width100%The width of the map component.
backgroundColor#88a4bcThe color of provinces which are not highlighted.
classNameOptional
1.0.11

3 years ago

1.0.10

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago