diff --git a/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.stories.js b/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.stories.js new file mode 100644 index 000000000..2aedbcd15 --- /dev/null +++ b/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.stories.js @@ -0,0 +1,45 @@ +import { action } from '@storybook/addon-actions'; +import TimelineCard from './TimelineCard'; + +export default { + title: 'Components/Events/Timeline', + component: TimelineCard, + argTypes: { + eventType: { + defaultValue: 'Commented', + control: { + type: 'text', + }, + }, + eventPath: { + defaultValue: 'chatwoot/chatwoot', + control: { + type: 'text', + }, + }, + eventBody: { + defaultValue: + 'Commentedmany variations of passages of Lorem Ipsum available, but the majority have suffered alteration in some form, by injected humour', + control: { + type: 'text', + }, + }, + timeStamp: { + defaultValue: '1618046084', + control: { + type: 'number', + }, + }, + }, +}; + +const Template = (args, { argTypes }) => ({ + props: Object.keys(argTypes), + components: { TimelineCard }, + template: '', +}); + +export const Timeline = Template.bind({}); +Timeline.args = { + onClick: action('more'), +}; diff --git a/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.vue b/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.vue new file mode 100644 index 000000000..a7f74fe58 --- /dev/null +++ b/app/javascript/dashboard/routes/dashboard/contacts/components/TimelineCard.vue @@ -0,0 +1,133 @@ + + + + +