import React from "react";
import { Meta, Story } from "@storybook/react";
import { IBannerProps, MoleculeBanner } from "native/molecules/Banner";

const meta: Meta = {
  title: "React Native/molecules/Banner",
  component: MoleculeBanner,
  argTypes: {},
  parameters: {
    controls: { expanded: true },
  },
};

export default meta;

const TemplateBanner: Story<IBannerProps> = (props) => (
  <MoleculeBanner {...props} />
);

// By passing using the Args format for exported stories, you can control the props for a component for reuse in a test
// https://storybook.js.org/docs/react/workflows/unit-testing
export const Banner = TemplateBanner.bind({});

Banner.args = {
  image:
    "https://prod-drupal.abi-rewards.de/sites/g/files/wnfebl4411/files/2022-04/join1_0%20%281%29.png",
  title: "$1 spent = 10 points",
  text: "Buy beer at ANY participating establishment, scan the receipt and earn up 10 points for every dollar.",
};
