mirror of
https://github.com/kingomarnajjar/flex-template-web.git
synced 2026-07-26 06:47:17 +10:00
Simple ListingCard example to styleguide
This commit is contained in:
parent
e9ba0ac855
commit
74cbd822ea
2 changed files with 19 additions and 0 deletions
17
src/components/ListingCard/ListingCard.example.js
Normal file
17
src/components/ListingCard/ListingCard.example.js
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
/* eslint-disable no-console, import/prefer-default-export */
|
||||
import React from 'react';
|
||||
import ListingCard from './ListingCard';
|
||||
import { createUser, createListing } from '../../util/test-data';
|
||||
|
||||
const author = createUser('user1');
|
||||
const listing = { ...createListing('listing1'), author };
|
||||
|
||||
const ListingCardWrapper = () => (
|
||||
<div style={{ width: '400px' }}>
|
||||
<ListingCard listing={listing} />
|
||||
</div>
|
||||
);
|
||||
|
||||
export const ListingCardWrapped = {
|
||||
component: ListingCardWrapper,
|
||||
};
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
// components
|
||||
import * as BookingInfo from './components/BookingInfo/BookingInfo.example';
|
||||
import * as ListingCard from './components/ListingCard/ListingCard.example';
|
||||
import * as NamedLink from './components/NamedLink/NamedLink.example';
|
||||
|
||||
// containers
|
||||
|
|
@ -17,6 +18,7 @@ export {
|
|||
ChangeAccountPasswordForm,
|
||||
ChangePasswordForm,
|
||||
HeroSearchForm,
|
||||
ListingCard,
|
||||
LoginForm,
|
||||
NamedLink,
|
||||
PasswordForgottenForm,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue