Skip to content

Commit

Permalink
[ConvAI] Add terms and fix widget styles
Browse files Browse the repository at this point in the history
  • Loading branch information
aarthificial committed Jan 1, 2025
1 parent 5dd3ace commit 9d2ac18
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
19 changes: 19 additions & 0 deletions fern/assets/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -319,3 +319,22 @@ canvas[data-engine="three.js r171"] {
height: 350px !important;
}

elevenlabs-convai {
--el-bg-color: rgb(var(--background));
--el-text-color: rgb(24, 24, 24);
--el-border-color: var(--border);
--el-border-radius: 0.75rem;
--el-btn-color: #0050b4;
--el-btn-text-color: #fff;
--el-btn-radius: 32px;
--el-focus-color: rgba(var(--accent), 0.5);
}

.dark elevenlabs-convai {
--el-bg-color: #1e1e20;
--el-text-color: rgb(223, 223, 224);
--el-border-color: #323638;
--el-btn-color: rgba(77, 156, 255, 0.1);
--el-btn-text-color: #4d9cff;
--el-focus-color: rgba(var(--accent), 0.5);
}
13 changes: 13 additions & 0 deletions fern/assets/widget.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,19 @@ function inject() {
},
};
});

widget.innerHTML = `\
<form slot="terms" class="prose text-sm">
<h3>Terms and conditions</h3>
<p>
By clicking "Continue," and each time I interact with this AI agent, I
consent to ElevenLabs collecting and using my voice and data derived from
it to interpret my speech, and provide the support services I request, and
to the recording, storage, and sharing of my communications with
third-party service providers, and as described in the
<a href="/terms-of-use">Privacy Policy</a>. If you do not wish to have
your conversations recorded, please refrain from using this service.
</form>`;

wrapper.appendChild(widget);
document.body.appendChild(wrapper);
Expand Down

0 comments on commit 9d2ac18

Please sign in to comment.