From 174182bc284193fc1aa7a9b5c2302dcea424c5a2 Mon Sep 17 00:00:00 2001 From: Vesa Luusua Date: Fri, 7 Apr 2017 03:00:04 +0300 Subject: [PATCH] Remove old usages of BookingInfo (old wireframes have wrong data) --- src/components/DateInput/DateInput.js | 2 +- .../DateInput/__snapshots__/DateInput.test.js.snap | 2 +- src/components/OrderDetailsPanel/OrderDetailsPanel.js | 6 ++---- .../__snapshots__/OrderDetailsPanel.test.js.snap | 5 ----- src/containers/OrderPage/OrderPage.js | 6 ------ .../OrderPage/__snapshots__/OrderPage.test.js.snap | 8 -------- 6 files changed, 4 insertions(+), 25 deletions(-) diff --git a/src/components/DateInput/DateInput.js b/src/components/DateInput/DateInput.js index ec4bdc7b..df73c4ee 100644 --- a/src/components/DateInput/DateInput.js +++ b/src/components/DateInput/DateInput.js @@ -19,7 +19,7 @@ const defaultProps = { id: 'date', placeholder: 'Date', disabled: false, - required: true, + required: false, screenReaderInputMessage: '', showClearDate: false, diff --git a/src/components/DateInput/__snapshots__/DateInput.test.js.snap b/src/components/DateInput/__snapshots__/DateInput.test.js.snap index 35012ac8..85b5e879 100644 --- a/src/components/DateInput/__snapshots__/DateInput.test.js.snap +++ b/src/components/DateInput/__snapshots__/DateInput.test.js.snap @@ -20,7 +20,7 @@ exports[`DateInput matches snapshot 1`] = ` onKeyDown={[Function]} placeholder="Date" readOnly={false} - required={true} + required={false} type="text" value="" /> diff --git a/src/components/OrderDetailsPanel/OrderDetailsPanel.js b/src/components/OrderDetailsPanel/OrderDetailsPanel.js index 8c1fcdde..1823babb 100644 --- a/src/components/OrderDetailsPanel/OrderDetailsPanel.js +++ b/src/components/OrderDetailsPanel/OrderDetailsPanel.js @@ -1,5 +1,5 @@ import React, { PropTypes } from 'react'; -import { BookingInfo, NamedLink } from '../../components'; +import { NamedLink } from '../../components'; import css from './OrderDetailsPanel.css'; @@ -24,14 +24,13 @@ ContactInfo.propTypes = { }; const OrderDetailsPanel = props => { - const { className, orderId, title, imageUrl, info, contact, confirmationCode } = props; + const { className, orderId, title, imageUrl, contact, confirmationCode } = props; return (
{title}

{title}

Confirmation code {confirmationCode}

-

Cancel booking

You have a new message! @@ -47,7 +46,6 @@ OrderDetailsPanel.propTypes = { orderId: oneOfType([string, number]).isRequired, title: string.isRequired, imageUrl: string.isRequired, - info: object.isRequired, contact: object.isRequired, confirmationCode: string.isRequired, }; diff --git a/src/components/OrderDetailsPanel/__snapshots__/OrderDetailsPanel.test.js.snap b/src/components/OrderDetailsPanel/__snapshots__/OrderDetailsPanel.test.js.snap index 46780dd4..ccbf920c 100644 --- a/src/components/OrderDetailsPanel/__snapshots__/OrderDetailsPanel.test.js.snap +++ b/src/components/OrderDetailsPanel/__snapshots__/OrderDetailsPanel.test.js.snap @@ -20,11 +20,6 @@ exports[`OrderDetailsPanel matches snapshot 1`] = ` Confirmation code some-test-confirmation-code

-

Cancel booking

diff --git a/src/containers/OrderPage/OrderPage.js b/src/containers/OrderPage/OrderPage.js index 198aa5a5..36123ff0 100644 --- a/src/containers/OrderPage/OrderPage.js +++ b/src/containers/OrderPage/OrderPage.js @@ -14,12 +14,6 @@ const OrderPage = props => { title, orderId, imageUrl: 'http://placehold.it/750x470', - info: { - pricePerDay: '55\u20AC', - bookingPeriod: 'Jan 2nd - Jan 4th', - bookingDuration: '3 days', - total: '165\u20AC', - }, contact: { addressLine1: '350 5th Avenue', addressLine2: 'New York, NY 10118', diff --git a/src/containers/OrderPage/__snapshots__/OrderPage.test.js.snap b/src/containers/OrderPage/__snapshots__/OrderPage.test.js.snap index fb8c4b88..2c05edda 100644 --- a/src/containers/OrderPage/__snapshots__/OrderPage.test.js.snap +++ b/src/containers/OrderPage/__snapshots__/OrderPage.test.js.snap @@ -35,14 +35,6 @@ exports[`OrderPage matches snapshot 1`] = ` } } imageUrl="http://placehold.it/750x470" - info={ - Object { - "bookingDuration": "3 days", - "bookingPeriod": "Jan 2nd - Jan 4th", - "pricePerDay": "55€", - "total": "165€", - } - } orderId={1234} title="Banyan Studios" />