Skip to content

Commit

Permalink
Merge branch 'development' of github.com:UNICEFECAR/USupport-client-u…
Browse files Browse the repository at this point in the history
…i into fix/issue_91
  • Loading branch information
georgiganchev-7DIGIT committed Jan 12, 2024
2 parents 131d4a3 + d75a24a commit 11c70bb
Show file tree
Hide file tree
Showing 9 changed files with 46 additions and 16 deletions.
30 changes: 21 additions & 9 deletions src/blocks/ActivityHistory/ActivityHistory.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ import {
getDateView,
getTime,
systemMessageTypes,
getTimeAsString,
} from "@USupport-components-library/utils";

import {
Expand Down Expand Up @@ -326,6 +327,11 @@ const MyDocument = ({
<View style={styles.nameContainer}>
<Text style={styles.providerName}>{providerName}</Text>
</View>
<Text style={styles.dateText}>
{t("exported_at", {
time: getTimeAsString(new Date()) + ", " + getDateView(new Date()),
})}
</Text>
{messages.map((message, index) => {
const isSent = message.senderId !== providerId;
if (message.type === "system" && !showSystemMessages) return null;
Expand All @@ -334,7 +340,8 @@ const MyDocument = ({
<View
style={[
styles.message,
isSent ? styles.messageSent : styles.messageReceived,
message.type != "system" &&
(isSent ? styles.messageSent : styles.messageReceived),
message.type === "system" && styles.systemMessage,
]}
>
Expand Down Expand Up @@ -372,10 +379,15 @@ const styles = StyleSheet.create({
flexDirection: "row",
justifyContent: "center",
alignItems: "center",
marginBottom: "24px",
marginTop: "6px",
fontWeight: "normal",
},
dateText: {
alignSelf: "center",
marginTop: "6px",
fontWeight: "normal",
textAlign: "center",
},
image: {
width: "40px",
height: "40px",
Expand All @@ -393,11 +405,11 @@ const styles = StyleSheet.create({
flexDirection: "column",
},
message: {
borderRadius: "24px",
padding: "16px 24px",
borderRadius: "18px",
padding: "8px 14px",
textAlign: "left",
maxWidth: "35%",
marginTop: "16px",
marginTop: "8px",
},
systemMessage: {
alignSelf: "center",
Expand All @@ -409,19 +421,19 @@ const styles = StyleSheet.create({
},
messageText: {
color: "#20809e",
fontSize: "14px",
fontSize: "12px",
fontWeight: "bold",
},
messageSent: {
backgroundColor: "#54cfd9",
alignSelf: "flex-end",
marginRight: "5px",
marginRight: "16px",
},
messageReceived: {
backgroundColor: "#e6f1f4",
marginLeft: "5px",
marginLeft: "16px",
},
date: { color: "gray", marginTop: "6px", fontSize: "14" },
date: { color: "gray", marginTop: "6px", fontSize: "10" },
dateSent: {
color: "#66768d",
},
Expand Down
4 changes: 3 additions & 1 deletion src/blocks/ActivityHistory/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@
"provider_camera_off": "The provider has turned off the camera",
"provider_camera_on": "The provider has turned on the camera",
"provider_microphone_off": "The provider has turned off the microphone",
"provider_microphone_on": "The provider has turned on the microphone"
"provider_microphone_on": "The provider has turned on the microphone",

"exported_at": "Exported at: {{time}}"
}
4 changes: 3 additions & 1 deletion src/blocks/ActivityHistory/locales/kk.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@
"provider_camera_off": "Консультант камераны өшірді",
"provider_camera_on": "Консультант камераны қосты",
"provider_microphone_off": "Консультант микрофонды өшірді",
"provider_microphone_on": "Консультант микрофонды қосты"
"provider_microphone_on": "Консультант микрофонды қосты",

"exported_at": "Экспортталған уақыты: {{time}}"
}
4 changes: 3 additions & 1 deletion src/blocks/ActivityHistory/locales/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,7 @@
"provider_camera_off": "Консультант отключил камеру",
"provider_camera_on": "Консультант включил камеру",
"provider_microphone_off": "Консультант отключил микрофон",
"provider_microphone_on": "Консультант включил микрофон"
"provider_microphone_on": "Консультант включил микрофон",

"exported_at": "Экспортировано в: {{time}}"
}
3 changes: 3 additions & 0 deletions src/blocks/Page/Page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,8 @@ export const Page = ({
initialCountry={selectedCountry}
hasUnreadNotifications={hasUnreadNotifications}
renderIn="client"
hasThemeButton
t={t}
/>
)}
<div
Expand Down Expand Up @@ -438,6 +440,7 @@ export const Page = ({
<Footer
lists={footerLists}
contactUsText={t("contact_us")}
contactUsUrl="/contact-us"
navigate={navigateTo}
Link={Link}
showSocials={false}
Expand Down
5 changes: 4 additions & 1 deletion src/blocks/Page/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,8 @@
"password_placeholder": "Password",
"password": "Please enter your password to access the site",
"wrong_password": "Wrong password",
"submit": "Submit"
"submit": "Submit",

"dark": "Dark",
"light": "Light"
}
5 changes: 4 additions & 1 deletion src/blocks/Page/locales/kk.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,8 @@
"password_placeholder": "Құпия сөз",
"password": "Сайтқа кіру үшін құпия сөзіңізді енгізіңіз",
"wrong_password": "Құпия сөз дұрыс емес",
"submit": "Жіберу"
"submit": "Жіберу",

"dark": "Қараңғы",
"light": "Жарық"
}
5 changes: 4 additions & 1 deletion src/blocks/Page/locales/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,8 @@
"password_placeholder": "Пароль",
"password": "Пожалуйста, введите пароль для доступа к сайту",
"wrong_password": "Неверный пароль",
"submit": "Отправить"
"submit": "Отправить",

"dark": "Тёмный",
"light": "Светлый"
}

0 comments on commit 11c70bb

Please sign in to comment.