Add Open Graph meta tags and source repository link
- Add Open Graph and Twitter Card meta tags for better URL sharing - Simple frontend: "No" with minimalist description - Playground frontend: "No as a Service" with branded description - Add discreet "Source Code" footer link on playground page 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
e77704ba03
commit
716c5f344c
1 changed files with 38 additions and 0 deletions
38
src/main.rs
38
src/main.rs
|
|
@ -8,6 +8,14 @@ const SIMPLE_FRONTEND: &str = r#"<!DOCTYPE html>
|
|||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>No</title>
|
||||
<!-- Open Graph meta tags for URL sharing -->
|
||||
<meta property="og:title" content="No">
|
||||
<meta property="og:description" content="Just no. That's it.">
|
||||
<meta property="og:type" content="website">
|
||||
<meta property="og:image" content="https://via.placeholder.com/1200x630/000000/ffffff?text=No">
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:title" content="No">
|
||||
<meta name="twitter:description" content="Just no. That's it.">
|
||||
<style>
|
||||
* {
|
||||
margin: 0;
|
||||
|
|
@ -96,6 +104,14 @@ const PLAYGROUND_FRONTEND: &str = r#"<!DOCTYPE html>
|
|||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>No as a Service</title>
|
||||
<!-- Open Graph meta tags for URL sharing -->
|
||||
<meta property="og:title" content="No as a Service">
|
||||
<meta property="og:description" content="The API that always says no. Simple, reliable, and always negative.">
|
||||
<meta property="og:type" content="website">
|
||||
<meta property="og:image" content="https://via.placeholder.com/1200x630/1a1a2e/ff6b6b?text=NO">
|
||||
<meta name="twitter:card" content="summary_large_image">
|
||||
<meta name="twitter:title" content="No as a Service">
|
||||
<meta name="twitter:description" content="The API that always says no. Simple, reliable, and always negative.">
|
||||
<style>
|
||||
* {
|
||||
margin: 0;
|
||||
|
|
@ -210,6 +226,24 @@ const PLAYGROUND_FRONTEND: &str = r#"<!DOCTYPE html>
|
|||
margin-top: 40px;
|
||||
}
|
||||
|
||||
.footer {
|
||||
text-align: center;
|
||||
margin-top: 60px;
|
||||
padding: 20px 0;
|
||||
opacity: 0.6;
|
||||
font-size: 0.9rem;
|
||||
}
|
||||
|
||||
.footer a {
|
||||
color: rgba(255, 255, 255, 0.7);
|
||||
text-decoration: none;
|
||||
transition: color 0.2s ease;
|
||||
}
|
||||
|
||||
.footer a:hover {
|
||||
color: #ff6b6b;
|
||||
}
|
||||
|
||||
.endpoint-info h3 {
|
||||
color: #ff6b6b;
|
||||
margin-bottom: 15px;
|
||||
|
|
@ -286,6 +320,10 @@ const PLAYGROUND_FRONTEND: &str = r#"<!DOCTYPE html>
|
|||
<li><span class="code">GET /health</span> - Health check</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="footer">
|
||||
<a href="https://kode.naiv.no/olemd/naas" target="_blank">Source Code</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue