mirror of
https://github.com/andrepimenta/claude-code-chat.git
synced 2025-12-10 03:49:43 +00:00
Add Umami analytics events to install flow
Track user journey through installation: - Install modal shown - Install started - Install success/failed 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1613,6 +1613,8 @@ const getScript = (isTelemetryEnabled: boolean) => `<script>
|
|||||||
if (main) main.style.display = 'flex';
|
if (main) main.style.display = 'flex';
|
||||||
if (progress) progress.style.display = 'none';
|
if (progress) progress.style.display = 'none';
|
||||||
if (success) success.style.display = 'none';
|
if (success) success.style.display = 'none';
|
||||||
|
|
||||||
|
sendStats('Install modal shown');
|
||||||
}
|
}
|
||||||
|
|
||||||
function hideInstallModal() {
|
function hideInstallModal() {
|
||||||
@@ -1620,6 +1622,8 @@ const getScript = (isTelemetryEnabled: boolean) => `<script>
|
|||||||
}
|
}
|
||||||
|
|
||||||
function startInstallation() {
|
function startInstallation() {
|
||||||
|
sendStats('Install started');
|
||||||
|
|
||||||
// Hide main content, show progress
|
// Hide main content, show progress
|
||||||
document.getElementById('installMain').style.display = 'none';
|
document.getElementById('installMain').style.display = 'none';
|
||||||
document.getElementById('installProgress').style.display = 'flex';
|
document.getElementById('installProgress').style.display = 'flex';
|
||||||
@@ -1637,9 +1641,11 @@ const getScript = (isTelemetryEnabled: boolean) => `<script>
|
|||||||
successEl.style.display = 'flex';
|
successEl.style.display = 'flex';
|
||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
|
sendStats('Install success');
|
||||||
successEl.querySelector('.install-success-text').textContent = 'Installed';
|
successEl.querySelector('.install-success-text').textContent = 'Installed';
|
||||||
successEl.querySelector('.install-success-hint').textContent = 'Send a message to get started';
|
successEl.querySelector('.install-success-hint').textContent = 'Send a message to get started';
|
||||||
} else {
|
} else {
|
||||||
|
sendStats('Install failed');
|
||||||
// Show error state
|
// Show error state
|
||||||
successEl.querySelector('.install-check').style.display = 'none';
|
successEl.querySelector('.install-check').style.display = 'none';
|
||||||
successEl.querySelector('.install-success-text').textContent = 'Installation failed';
|
successEl.querySelector('.install-success-text').textContent = 'Installation failed';
|
||||||
|
|||||||
Reference in New Issue
Block a user