@ta-interaktiv/react-feedback-message

React component that renders a message with a mail address allowing readers to give feedback.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
@ta-interaktiv/react-feedback-message
3.0.12 years ago7 years agoMinified + gzip package size for @ta-interaktiv/react-feedback-message in KB

Readme

Feedback Message
npm version
React component that renders a message with a mail address allowing readers to give feedback.

Installation

yarn add @ta-interaktiv/react-feedback-message

API

Table of Contents

React component that renders a message with a mail address allowing

readers to give feedback.

Parameters

-   `props.mailTo` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** The mail
      address to send the feedback to. Join several addresses with `,` (optional, default `interaktiv@tages-anzeiger.ch`)
-   `props.project` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** The name of the
    project. Used as the mail subject. Defaults to the window title. (optional, default `window.document.title`)
-   `props.className` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)?** Additional CSS classes that should be
    passed to both the `ui message`.
-   `props.inverted` **[boolean](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Boolean)** Whether the component should be
    displayed as inverted. (optional, default `false`)
-   `props.question` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** Header line of the feedback message box. (optional, default `'Haben sie Anmerkungen oder einen Fehler
    entdeckt?'|'Avez-vous des remarques ou avez-vous découvert une erreur?'`)
-   `props.call` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** Second part of the message, prepended to the mailTo address(es) (optional, default `'Wir freuen uns über Ihre Nachricht an'|'Nous
    nous réjouissons de votre message à'`)
-   `props.locale` **(`"de"` \| `"fr"`)** The language in which the
    component should be rendered. This only affects the default text strings (optional, default `de`)

Examples

import React from 'react'
import FeedbackMessage from '@ta-interaktiv/react-feedback-message'

class YourComponent extends React.Component {
 render() {

   return (
     <FeedbackMessage mailTo='test@example.com' className='small blue' />
   )
 }
}