@quintype/native-components 2.29.4-beta.1 → 2.29.4-beta.2

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.
@@ -1,15 +1,15 @@
1
1
  #!/bin/bash -e
2
2
 
3
- npm install
4
- git diff --quiet
3
+ # npm install
4
+ # git diff --quiet
5
5
 
6
- BRANCH=$(git symbolic-ref --short HEAD)
6
+ # BRANCH=$(git symbolic-ref --short HEAD)
7
7
 
8
- if [ "$BRANCH" == 'master' ]
9
- then
10
- npx standard-version
11
- else
12
- npx standard-version --prerelease "$(git symbolic-ref --short HEAD | sed s:/:-:g )" --skip.changelog=true
13
- fi
8
+ # if [ "$BRANCH" == 'master' ]
9
+ # then
10
+ # npx standard-version
11
+ # else
12
+ # npx standard-version --prerelease "$(git symbolic-ref --short HEAD | sed s:/:-:g )" --skip.changelog=true
13
+ # fi
14
14
 
15
- git push --follow-tags origin "$BRANCH"
15
+ # git push --follow-tags origin "$BRANCH"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quintype/native-components",
3
- "version": "2.29.4-beta.1",
3
+ "version": "2.29.4-beta.2",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -9,6 +9,7 @@ import Slider from "@react-native-community/slider";
9
9
  import { AppTheme } from "../../utils";
10
10
  import { useContext } from "react";
11
11
  import { Text } from '../index';
12
+ import { COMP_GENERAL_CONSTANTS } from "../../constants/component-constants";
12
13
 
13
14
  const ProgressBar = (props) => {
14
15
  const screenDimensions = useWindowDimensions();
@@ -70,7 +71,7 @@ const PlayerBase = (props) => {
70
71
  />
71
72
  );
72
73
  default:
73
- return <ControlButton iconName={"playcircleo"} onPress={onTogglePlayback} FONT_SIZE={FONT_SIZE}/>;
74
+ return <ControlButton testID={COMP_GENERAL_CONSTANTS.ttsPauseButton} iconName={"playcircleo"} onPress={onTogglePlayback} FONT_SIZE={FONT_SIZE}/>;
74
75
  }
75
76
  };
76
77
 
@@ -89,13 +90,14 @@ const PlayerBase = (props) => {
89
90
  {translate("Listen to this article")}
90
91
  </Text>
91
92
  <View style={playerControlStyle}>
92
- <TouchableOpacity style={{ marginHorizontal: 10 }} onPress={() => rewindOrForward("rewind")}>
93
- <MaterialCommunityIcons color={COLORS.BRAND_BLACK} name={"rewind-10"} size={FONT_SIZE.title} />
93
+ <TouchableOpacity testID={COMP_GENERAL_CONSTANTS.ttsRewindButton} style={{ marginHorizontal: 10 }} onPress={() => rewindOrForward("rewind")}>
94
+ <MaterialCommunityIcons color={COLORS.BRAND_BLACK} name={"rewind-10"} size={FONT_SIZE.title}/>
94
95
  </TouchableOpacity>
95
- <TouchableOpacity style={{ marginHorizontal: 10 }} onPress={() => rewindOrForward("forward")}>
96
+ <TouchableOpacity testID={COMP_GENERAL_CONSTANTS.ttsForwardButton} style={{ marginHorizontal: 10 }} onPress={() => rewindOrForward("forward")} >
96
97
  <MaterialCommunityIcons color={COLORS.BRAND_BLACK} name={"fast-forward-10"} size={FONT_SIZE.title} />
97
98
  </TouchableOpacity>
98
99
  <TouchableOpacity
100
+ testID={COMP_GENERAL_CONSTANTS.ttsPlayBackSpeed}
99
101
  style={playbackSpeedText}
100
102
  onPress={() => props.setShowModal(true)}
101
103
  >
@@ -114,6 +116,7 @@ const PlayerBase = (props) => {
114
116
  </View>
115
117
  <ProgressBar seekTo={seekTo} />
116
118
  <MaterialCommunityIcons
119
+ testID={COMP_GENERAL_CONSTANTS.ttsPlayerCloseButton}
117
120
  color={COLORS.BRAND_BLACK}
118
121
  onPress={()=>closeButtonHandler()}
119
122
  size={FONT_SIZE.title}
@@ -23,6 +23,7 @@ import FontAwesomeIcon from "react-native-vector-icons/FontAwesome";
23
23
  import { isDetox } from 'react-native-is-detox';
24
24
 
25
25
  import Modal from 'react-native-modal';
26
+ import { COMP_GENERAL_CONSTANTS } from '../../constants/component-constants';
26
27
 
27
28
  const getLiveBlogTimeStamp = (card, DATE_FORMAT, story, styles, locale) => {
28
29
  const slug = `?cardId=${card.id}`;
@@ -394,6 +395,7 @@ export const Story = ({
394
395
  setShowPlayer(true)
395
396
  await togglePlayback()
396
397
  }}
398
+ testID={COMP_GENERAL_CONSTANTS.ttsPlayButton}
397
399
  style={styles.ttsStoryButtonStyle}
398
400
  >
399
401
  <MaterialIcon name='account-voice' size={FONT_SIZE.h2} color={COLORS.BRAND_BLACK}/>
@@ -463,7 +465,7 @@ export const Story = ({
463
465
  <View style={[Modalstyles.modalContent, styles.modalBackgound]}>
464
466
  <View style={Modalstyles.header}>
465
467
  <Text style={[Modalstyles.title, styles.textStyle]}>{translate("Playback Speed")}</Text>
466
- <TouchableOpacity onPress={() => setShowModal(false)}>
468
+ <TouchableOpacity testID={COMP_GENERAL_CONSTANTS.ttsModalCloseButton} onPress={() => setShowModal(false)}>
467
469
  <MaterialIcon name="close" size={25} color={styles?.textStyle?.color} />
468
470
  </TouchableOpacity>
469
471
  </View>
@@ -21,5 +21,12 @@ export const COMP_GENERAL_CONSTANTS = {
21
21
  headerLogoTouch: 'COMP_GENERAL_HEADER_LOGO_TOUCH',
22
22
  radioButtonTouch: 'COMP_GENERAL_RADIO',
23
23
  shareButtonTouch: 'COMP_GENERAL_SHARE',
24
- closeButtonTouch : 'COMP_CLOSE_BTN_TOUCH'
24
+ closeButtonTouch : 'COMP_CLOSE_BTN_TOUCH',
25
+ ttsPlayButton: 'COMP_TTS_PLAY_BUTTON',
26
+ ttsPlayerCloseButton: 'COMP_TTS_PLAYER_CLOSE_BUTTON',
27
+ ttsRewindButton: 'COMP_TTS_REWIND_BUTTON',
28
+ ttsForwardButton: 'COMP_TTS_FORWARD_BUTTON',
29
+ ttsPlayBackSpeed: 'COMP_TTS_PLAYBACK_SPEED',
30
+ ttsModalCloseButton: 'COMP_TTS_MODAL_CLOSE_BUTTON',
31
+ ttsPauseButton: 'COMP_TTS_PAUSE_BUTTON'
25
32
  };