@times-components/ts-components 1.146.2-784617dc4a33959b8795da1d7f425c9929322fae.24 → 1.146.2-9d94da839cee591620d598d11e637971d7109888.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/travel-mini-cta/index.js +3 -3
- package/dist/components/travel-mini-cta/styles.d.ts +3 -1
- package/dist/components/travel-mini-cta/styles.js +4 -3
- package/dist/components/travel-mini-cta/travel-mini-cta.stories.js +2 -2
- package/dist/components/travel-mini-cta/types.d.ts +1 -0
- package/package.json +3 -3
- package/rnw.js +1 -1
- package/src/components/travel-mini-cta/index.tsx +3 -2
- package/src/components/travel-mini-cta/styles.ts +5 -3
- package/src/components/travel-mini-cta/travel-mini-cta.stories.tsx +1 -1
- package/src/components/travel-mini-cta/types.ts +1 -0
|
@@ -39,7 +39,8 @@ export const TravelMiniCTA: FC<TravelMiniCTAProps> = ({
|
|
|
39
39
|
primaryButtonText,
|
|
40
40
|
secondaryButtonText,
|
|
41
41
|
secondaryButtonUrl,
|
|
42
|
-
isApp
|
|
42
|
+
isApp,
|
|
43
|
+
isOnChannelPage = false
|
|
43
44
|
}) => {
|
|
44
45
|
const [chatReady, setChatReady] = useState(false);
|
|
45
46
|
const [chatFailed, setChatFailed] = useState(false);
|
|
@@ -158,7 +159,7 @@ export const TravelMiniCTA: FC<TravelMiniCTAProps> = ({
|
|
|
158
159
|
))}
|
|
159
160
|
</WorkingHoursContainer>
|
|
160
161
|
</ContactInfo>
|
|
161
|
-
<ButtonsContainer>
|
|
162
|
+
<ButtonsContainer $isOnChannelPage={isOnChannelPage}>
|
|
162
163
|
{chatFailed ? (
|
|
163
164
|
<PrimaryButton as="a" href={`tel:${phoneNumber}`} isApp={isApp}>
|
|
164
165
|
{buttonText}
|
|
@@ -243,12 +243,14 @@ export const WorkingHoursText = styled.div<{ isApp?: boolean }>`
|
|
|
243
243
|
)};
|
|
244
244
|
`;
|
|
245
245
|
|
|
246
|
-
export const ButtonsContainer = styled.div
|
|
246
|
+
export const ButtonsContainer = styled.div<{ $isOnChannelPage?: boolean }>`
|
|
247
247
|
display: flex;
|
|
248
|
+
flex-direction: column;
|
|
248
249
|
gap: 16px;
|
|
249
250
|
|
|
250
|
-
${getMediaQuery('
|
|
251
|
-
flex-direction:
|
|
251
|
+
${getMediaQuery('lg')} {
|
|
252
|
+
flex-direction: ${({ $isOnChannelPage }) =>
|
|
253
|
+
$isOnChannelPage ? 'row' : 'column'};
|
|
252
254
|
}
|
|
253
255
|
`;
|
|
254
256
|
|
|
@@ -13,7 +13,7 @@ storiesOf('Typescript Component/In Article/Travel Mini CTA', module).add(
|
|
|
13
13
|
phoneLabel="Call us on"
|
|
14
14
|
phoneNumber="08083049757"
|
|
15
15
|
workingHours={['Mon - Fri: 9am - 6pm', 'Sat: 10am - 5pm']}
|
|
16
|
-
primaryButtonText="Chat
|
|
16
|
+
primaryButtonText="Chat to a consultant"
|
|
17
17
|
secondaryButtonText="Enquire now"
|
|
18
18
|
secondaryButtonUrl="/enquire"
|
|
19
19
|
/>
|