Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add created timestamp to differentiate embeds
update translation key to lowercase
add created at translation key
  • Loading branch information
timothycarambat committed Jun 3, 2025
commit 317e59b3394bd7b56ced40d93d74b775e7202cbb
3 changes: 2 additions & 1 deletion frontend/src/locales/ar/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,8 @@ const TRANSLATIONS = {
table: {
workspace: "Ω…Ψ³Ψ§Ψ­Ψ© Ψ§Ω„ΨΉΩ…Ω„",
chats: "Ψ§Ω„Ω…Ψ­Ψ§Ψ―Ψ«Ψ§Ψͺ Ψ§Ω„Ω…Ψ±Ψ³Ω„Ψ©",
Active: "Ψ§Ω„Ω…Ψ¬Ψ§Ω„Ψ§Ψͺ Ψ§Ω„Ω†Ψ΄Ψ·Ψ©",
active: "Ψ§Ω„Ω…Ψ¬Ψ§Ω„Ψ§Ψͺ Ψ§Ω„Ω†Ψ΄Ψ·Ψ©",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/da/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,8 @@ const TRANSLATIONS = {
table: {
workspace: "ArbejdsomrΓ₯de",
chats: "Sendte chats",
Active: "Aktive domæner",
active: "Aktive domæner",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/de/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,8 @@ const TRANSLATIONS = {
table: {
workspace: "Arbeitsbereich",
chats: "Gesendete Chats",
Active: "Aktive Domains",
active: "Aktive Domains",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/en/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -652,7 +652,8 @@ const TRANSLATIONS = {
table: {
workspace: "Workspace",
chats: "Sent Chats",
Active: "Active Domains",
active: "Active Domains",
created: "Created",
},
},

Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/es/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,8 @@ const TRANSLATIONS = {
table: {
workspace: "Espacio de trabajo",
chats: "Chats enviados",
Active: "Dominios activos",
active: "Dominios activos",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/fa/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,8 @@ const TRANSLATIONS = {
table: {
workspace: "فآای کاری",
chats: "گفΨͺΪ―ΩˆΩ‡Ψ§ΫŒ Ψ§Ψ±Ψ³Ψ§Ω„ Ψ΄Ψ―Ω‡",
Active: "Ψ―Ψ§Ω…Ω†Ω‡β€ŒΩ‡Ψ§ΫŒ فعال",
active: "Ψ―Ψ§Ω…Ω†Ω‡β€ŒΩ‡Ψ§ΫŒ فعال",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/fr/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,8 @@ const TRANSLATIONS = {
table: {
workspace: "Espace de travail",
chats: "Chats envoyΓ©s",
Active: "Domaines actifs",
active: "Domaines actifs",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/he/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,8 @@ const TRANSLATIONS = {
table: {
workspace: "Χ‘Χ‘Χ™Χ‘Χͺ Χ’Χ‘Χ•Χ“Χ”",
chats: "Χ©Χ™Χ—Χ•Χͺ Χ©Χ Χ©ΧœΧ—Χ•",
Active: "ΧͺΧ—Χ•ΧžΧ™Χ Χ€Χ’Χ™ΧœΧ™Χ",
active: "ΧͺΧ—Χ•ΧžΧ™Χ Χ€Χ’Χ™ΧœΧ™Χ",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/it/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ const TRANSLATIONS = {
table: {
workspace: "Area di lavoro",
chats: "Chat inviate",
Active: "Domini attivi",
active: "Domini attivi",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/ja/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ const TRANSLATIONS = {
table: {
workspace: "γƒ―γƒΌγ‚―γ‚ΉγƒšγƒΌγ‚Ή",
chats: "ι€δΏ‘ζΈˆγΏγƒγƒ£γƒƒγƒˆ",
Active: "ζœ‰εŠΉγͺドパむン",
active: "ζœ‰εŠΉγͺドパむン",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/ko/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -419,7 +419,8 @@ const TRANSLATIONS = {
table: {
workspace: "μ›Œν¬μŠ€νŽ˜μ΄μŠ€",
chats: "보낸 μ±„νŒ…",
Active: "ν™œμ„± 도메인",
active: "ν™œμ„± 도메인",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/lv/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,8 @@ const TRANSLATIONS = {
table: {
workspace: "Darba vieta",
chats: "Nosūtītie čati",
Active: "AktΔ«vie domΔ“ni",
active: "AktΔ«vie domΔ“ni",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/nl/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,8 @@ const TRANSLATIONS = {
table: {
workspace: "Werkruimte",
chats: "Verzonden Chats",
Active: "Actieve Domeinen",
active: "Actieve Domeinen",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/pt_BR/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,8 @@ const TRANSLATIONS = {
table: {
workspace: "Workspace",
chats: "Chats Enviados",
Active: "DomΓ­nios Ativos",
active: "DomΓ­nios Ativos",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/ru/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,8 @@ const TRANSLATIONS = {
table: {
workspace: "Π Π°Π±ΠΎΡ‡Π΅Π΅ пространство",
chats: "ΠžΡ‚ΠΏΡ€Π°Π²Π»Π΅Π½Π½Ρ‹Π΅ Ρ‡Π°Ρ‚Ρ‹",
Active: "АктивныС Π΄ΠΎΠΌΠ΅Π½Ρ‹",
active: "АктивныС Π΄ΠΎΠΌΠ΅Π½Ρ‹",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/tr/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,8 @@ const TRANSLATIONS = {
table: {
workspace: "Γ‡alışma AlanΔ±",
chats: "GΓΆnderilen Sohbetler",
Active: "Aktif Alan AdlarΔ±",
active: "Aktif Alan AdlarΔ±",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/vn/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,8 @@ const TRANSLATIONS = {
table: {
workspace: "Workspace",
chats: "Sent Chats",
Active: "Active Domains",
active: "Active Domains",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/zh/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,8 @@ const TRANSLATIONS = {
table: {
workspace: "ε·₯作区",
chats: "ε·²ε‘ι€θŠε€©",
Active: "活动域",
active: "活动域",
created: null,
},
},
"embed-chats": {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/locales/zh_TW/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,8 @@ const TRANSLATIONS = {
table: {
workspace: "ε·₯δ½œε€",
chats: "已傳送對話",
Active: "ε·²ε•Ÿη”¨ηΆ²εŸŸ",
active: "ε·²ε•Ÿη”¨ηΆ²εŸŸ",
created: null,
},
},
"embed-chats": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { useRef, useState } from "react";
import { DotsThreeOutline, LinkSimple, Trash } from "@phosphor-icons/react";
import { DotsThreeOutline } from "@phosphor-icons/react";
import showToast from "@/utils/toast";
import { useModal } from "@/hooks/useModal";
import ModalWrapper from "@/components/ModalWrapper";
Expand All @@ -8,6 +8,7 @@ import paths from "@/utils/paths";
import { nFormatter } from "@/utils/numbers";
import EditEmbedModal from "./EditEmbedModal";
import CodeSnippetModal from "./CodeSnippetModal";
import moment from "moment";

export default function EmbedRow({ embed }) {
const rowRef = useRef(null);
Expand Down Expand Up @@ -84,6 +85,14 @@ export default function EmbedRow({ embed }) {
<th scope="row" className="px-6 whitespace-nowrap">
<ActiveDomains domainList={embed.allowlist_domains} />
</th>
<th scope="row" className="px-6 whitespace-nowrap">
{
// If the embed was created more than a day ago, show the date, otherwise show the time ago
moment(embed.createdAt).diff(moment(), "days") > 0
? moment(embed.createdAt).format("MMM D, YYYY")
: moment(embed.createdAt).fromNow()
}
</th>
<td className="px-6 flex items-center gap-x-6 h-full mt-1">
<button
onClick={openSnippetModal}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,10 @@ export default function EmbedConfigsView() {
{t("embeddable.table.chats")}
</th>
<th scope="col" className="px-6 py-3">
{t("embeddable.table.Active")}
{t("embeddable.table.active")}
</th>
<th scope="col" className="px-6 py-3">
{t("embeddable.table.created")}
</th>
<th scope="col" className="px-6 py-3">
{" "}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"generate:cloudformation": "node cloud-deployments/aws/cloudformation/generate.mjs",
"generate::gcp_deployment": "node cloud-deployments/gcp/deployment/generate.mjs",
"verify:translations": "cd frontend/src/locales && node verifyTranslations.mjs",
"normalize:translations": "cd frontend/src/locales && node normalizeEn.mjs"
"normalize:translations": "cd frontend/src/locales && node normalizeEn.mjs && cd ../../.. && yarn lint && yarn verify:translations"
},
"private": false,
"devDependencies": {
Expand Down