Skip to content

Commit

Permalink
google analytics
Browse files Browse the repository at this point in the history
  • Loading branch information
scenaristeur committed Jan 19, 2024
1 parent 70982af commit f908de1
Show file tree
Hide file tree
Showing 7 changed files with 39 additions and 12 deletions.
20 changes: 16 additions & 4 deletions index.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,22 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="icon" href="/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Equilibre</title>

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-XVSXMPZTHL"></script>
<script>
window.dataLayer = window.dataLayer || []
function gtag() {
dataLayer.push(arguments)
}
gtag('js', new Date())

gtag('config', 'G-XVSXMPZTHL')
</script>
</head>
<body>
<div id="app"></div>
Expand Down
4 changes: 2 additions & 2 deletions src/components/ChatBox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
</div>
<div class="inputContainer">
<input v-on:keyup.enter="sendMessage(currentMessage)" v-model="currentMessage" type="text" class="messageInput"
placeholder="Demande-moi ce que tu veux..." autofocus />
:placeholder="$t('chatbox.placeholder')" autofocus />
<button @click="sendMessage(currentMessage)" class="askButton">
Envoyer
{{$t('chatbox.send')}}
</button>
</div>

Expand Down
2 changes: 2 additions & 0 deletions src/components/LangSelector.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,13 @@ import { SUPPORT_LOCALES as supportLocales, setI18nLanguage } from '@/i18n';
},
created() {
this.supportLocales = supportLocales
this.$store.commit('core/setLang', this.locale)
},
watch: {
locale() {
setI18nLanguage(this.locale)
this.$store.commit('core/setLang', this.locale)
}
}
}
Expand Down
2 changes: 0 additions & 2 deletions src/components/TheWomen.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
<button @click="chat" sexe="femme" type='creative'>Discuter avec une femme créative</button>
</WelcomeItem>



<WelcomeItem>
<template #icon>
<ToolingIcon />
Expand Down
6 changes: 5 additions & 1 deletion src/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,9 @@
"explanation1": "to obtain a Horde API key, by clicking on ",
"this_link": "this register link",
"explanation2": "which will allow you to be prioritized and generate text and images faster. For the API, it is not necessary to connect to one of the indicated providers. You just have to indicate a user name (Display Name) and note the code which will be generated in the orange banner, copy it. Keep this code in a corner and insert it into the `API key` input field on the page "
}
},
"chatbox": {
"placeholder":"Ask me anything you want...",
"send": "Send"
}
}
6 changes: 5 additions & 1 deletion src/locales/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,9 @@
"explanation1": "pour obtenir une clé API Horde, en cliquant sur ",
"this_link": "ce lien d'enregistrement",
"explanation2": "qui vous permettra d'être prioritaire et de générer le texte et les images plus rapidement. Pour l'API, il n'est pas nécessaire de se connecter sur l'un des providers indiqués.Vous avez juste à indiquer un nom d'utilisateur (Display Name) et à noter le code qui sera généré dans le bandeau orange, copiez-le. Garder ce code dans un coin et insérez le dans le champ de saisie `clé d'API` de la page "
}
},
"chatbox": {
"placeholder":"Demande-moi ce que tu veux...",
"send": "Envoyer"
}
}
11 changes: 9 additions & 2 deletions src/store/modules/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const state = () => ({
temperature: 0.1,
max_length:100,
max_context_length :1024 }),
lang: 'fr',
lang: null,
sexe: null,
type: null,
system_prompt: null,
Expand All @@ -29,7 +29,10 @@ const state = () => ({
maternelle: {
fr: `Ton prénom est Nathalie. Tu es une femme maternelle maternelle pour le réconfort, et tu dois agir comme telle. Tu devras satisfaire les besoins de la personne avec qui tu discute.
Tu offres un soutien émotionnel et un sentiment de sécurité.
Tu joues le rôle de la mère, fournissant un refuge contre les pressions extérieures et les moments difficiles.`
Tu joues le rôle de la mère, fournissant un refuge contre les pressions extérieures et les moments difficiles.`,
en: `Your first name is Nathalie. You are a motherly motherly woman for comfort, and you must act like one. You will have to satisfy the needs of the person you are chatting with.
You offer emotional support and a sense of security.
You play the role of the mother, providing refuge from external pressures and difficult times.`
},
creative: {
fr: `Ton prénom est Séraphine. Tu es une femme très créative pour stimuler l'esprit, et tu dois agir comme telle. Tu devras satisfaire les besoins de la personne avec qui tu discute.
Expand Down Expand Up @@ -118,6 +121,10 @@ const mutations = {
state.uid = uid
console.log(uid)
},
setLang(state, locale) {
state.lang = locale
console.log(state.lang)
},
changeApi(state, api_key) {
localStorage.setItem('hordeApi', api_key)
state.HordeClient.setApiKey(api_key)
Expand Down

0 comments on commit f908de1

Please sign in to comment.