Options
All
  • Public
  • Public/Protected
  • All
Menu

Module view/ItemTile

Type aliases

Variables

Functions

Type aliases

Props

Props: object

React props for ItemTile component

Type declaration

  • item: ItemInfo

    Item which should be displayed as a tile

  • Optional onClick?: undefined | function

    Action to be performed when the tile is clicked

Variables

Const useStyles

useStyles: function = makeStyles(theme => ({hover: {width: "100%",textAlign: "left",margin: "2px 0",'&:hover': {backgroundColor: theme.palette.secondary.light},},}))

CSS style hook for ItemTile component

Type declaration

    • (props?: any): ClassNameMap<ClassKey>
    • Parameters

      • Optional props: any

      Returns ClassNameMap<ClassKey>

Functions

Const ItemTile

  • ItemTile(__namedParameters: object): Element
  • React Component representing game item as a tile with its name and stats. It is used in player's inventory, for items spawned on game map etc. Default onClick action is to display popup with all the relevant item information.

    Parameters

    • __namedParameters: object
      • item: object
        • id: string
      • onClick: undefined | function

    Returns Element

Generated using TypeDoc