1.0.1 • Published 6 years ago

arena-plugin-reports v1.0.1

Weekly downloads
2
License
ISC
Repository
github
Last release
6 years ago

arena-plugin-reports

Installation

npm i arena-plugin-reports

Example

import Reports from 'arena-plugin-reports'

return (
  <div>
    <Reports
      bannerRows={bannerRows}
      hostCountry={hostCountry}
      reportTemplate={reportTemplate}
      tableRows={tableRows}
    />
  </div>
)

Component

arena-plugin-reports consists of one component.

<Reports />

bannerRows: array

required

Example:

[
  {
    "id": 1,
    "name": "Compensation_TotalAllowances",
    "title": "Total Allowances",
    "values": {
      "2017": 10768,
      "2018": 10768
    },
    "total": 21536,
    "currencyCode": "CAD"
  }
]

tableRows: array

required

Example:

[
  {
    "id": 1,
    "name": "Compensation_BaseSalary",
    "title": "Base Salary",
    "values": {
      "2017": 161520,
      "2018": 161520
    },
    "total": 323040,
    "currencyCode": "CAD"
  }
]

reportTemplate: object

required

Example:

{
  "summary": [
    {
      "id": "Summary",
      "name": "Summary",
      "rows": [
        {
          "rowName": "Compensation_TotalAllowances",
          "collapsed": false
        }
      ]
    }
  ],
  "detail": [
    {
      "id": "Base_Compensation",
      "name": "Base Compensation",
      "rows": [
        {
          "rowName": "Compensation_BaseSalary",
          "collapsed": false
        }
      ]
    }
  ]
}

hostCountry: string

required

The ISO code used to display the country banner image at the top of the Report.

links: array

default: []

Displays links in the top right hand corner of report.

Example:

[
  {
    action: () => downloadReport('Details'),
    icon: 'download',
    text: 'Details',
  },
  {
    action: () => downloadReport('Summary'),
    icon: 'download',
    text: 'Summary',
  },
]

buttons: array

default: []

Displays buttons on the bottom of report.

Example:

[
  {
    action: () => edit(),
    text: 'Edit',
  },
  {
    action: () => startNewMove(),
    text: 'Start new move',
  },
]
1.0.1

6 years ago

1.0.0

6 years ago

0.3.7

6 years ago

0.3.6

6 years ago

3.1.1

6 years ago

3.1.0

6 years ago

0.3.5

6 years ago

0.3.3

6 years ago

0.3.2

6 years ago

0.3.1

6 years ago

0.3.0

6 years ago

0.2.8

6 years ago

0.2.7

6 years ago

0.2.6

6 years ago

0.2.5

6 years ago

0.2.4

6 years ago

0.2.3

6 years ago

0.2.2

6 years ago

0.2.1

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago