Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
1846b03
feat(legal): implement legal page with locale support
mike-doctorina Mar 9, 2026
2f9de92
feat(server): enhance URL rewriting for asset handling and trailing s…
mike-doctorina Mar 9, 2026
5f6717e
chore: clean up empty code change sections in the changes log
mike-doctorina Mar 9, 2026
35eeb7f
Enhance legal page styling: Add header logo, adjust layout, and impro…
mike-doctorina Mar 9, 2026
6ff2a98
feat(legal): enhance locale detection for Apple devices
mike-doctorina Mar 10, 2026
09952b8
feat(legal): update cookie policy links in privacy and terms document…
mike-doctorina Mar 10, 2026
c0ca9e4
chore: bump version to 0.0.2 in package.json
mike-doctorina Mar 10, 2026
ba449ce
refactor(legal): standardize code formatting and improve readability
mike-doctorina Mar 10, 2026
9900536
Update legal
mike-doctorina Mar 10, 2026
001a196
Problems
mike-doctorina Mar 10, 2026
e5ca3b8
0.0.3
mike-doctorina Mar 10, 2026
ce50ee9
Add legal script
mike-doctorina Mar 19, 2026
1c92e61
fix(legal): update links to use hash format for version navigation
mike-doctorina Mar 19, 2026
8180860
feat(legal): add README for legal document embed script
mike-doctorina Mar 19, 2026
96cdc7b
Add localization from google docs
mike-doctorina Mar 25, 2026
e11778d
Update localizations
mike-doctorina Mar 25, 2026
b2a02b0
Add legal html test
mike-doctorina Mar 25, 2026
db477dc
Fix localizations
mike-doctorina Mar 25, 2026
fdf5f07
Add <blockquote>
mike-doctorina Mar 25, 2026
3d83ed0
Update privacy policy to clarify testing phase and data usage
mike-doctorina Mar 25, 2026
39eef7d
Remove (EN) (ES) (RU) from headers
mike-doctorina Mar 26, 2026
181196f
Replace Cookies Policy with Cookie Policy
mike-doctorina Mar 26, 2026
1fc2337
Add navigation handling to smooth scroll to document sections
mike-doctorina Mar 26, 2026
4f2fbb5
Fix smooth scroll behavior by adding null check for target element
mike-doctorina Mar 26, 2026
e74eeb6
Enhance document loading by sanitizing parameters and preventing dupl…
mike-doctorina Mar 26, 2026
eccbf62
Enhance URL parameter handling by implementing case-insensitive looku…
mike-doctorina Mar 26, 2026
4381498
Refactor cookie policy translation section for clarity and formatting
mike-doctorina Mar 26, 2026
dc3acaf
Update privacy policy links in cookie documents to include language p…
mike-doctorina Mar 26, 2026
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
48 changes: 48 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,3 +74,51 @@ jobs:

- name: ✅ Build successful
run: echo "✅ Build completed successfully"

##############################################################################
# LEGAL HTML VALIDATION (runs only when legal content changes)
##############################################################################

legal-html:
name: "📄 Legal HTML Validation"
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- name: 📦 Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: 🔎 Check for legal HTML changes
id: legal-changes
run: |
if [ "${{ github.event_name }}" = "pull_request" ]; then
BASE=${{ github.event.pull_request.base.sha }}
else
BASE=${{ github.event.before }}
fi
CHANGED=$(git diff --name-only "$BASE" HEAD -- 'public/legal/**/*.html' || true)
if [ -n "$CHANGED" ]; then
echo "changed=true" >> "$GITHUB_OUTPUT"
echo "Changed legal files:"
echo "$CHANGED"
else
echo "changed=false" >> "$GITHUB_OUTPUT"
echo "No legal HTML files changed — skipping validation"
fi

- name: 🟢 Setup Node.js
if: steps.legal-changes.outputs.changed == 'true'
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}
cache: "npm"

- name: 📥 Install dependencies
if: steps.legal-changes.outputs.changed == 'true'
run: npm ci

- name: 📄 Validate legal HTML
if: steps.legal-changes.outputs.changed == 'true'
run: npx vitest run tests/legal-html.test.ts
26 changes: 26 additions & 0 deletions firebase.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,32 @@
}
],
"headers": [
{
"source": "/legal/content/**",
"headers": [
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "Cache-Control",
"value": "no-cache, no-store, must-revalidate"
}
]
},
{
"source": "/legal/legal.js",
"headers": [
{
"key": "Access-Control-Allow-Origin",
"value": "*"
},
{
"key": "Cache-Control",
"value": "public, max-age=3600"
}
]
},
{
"source": "**/*.@(html|json)",
"headers": [
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pages",
"version": "0.0.1",
"version": "0.0.3",
"description": "Doctorina Pages - Multiple lightweight HTML pages",
"type": "module",
"scripts": {
Expand Down Expand Up @@ -38,4 +38,4 @@
"vite": "7.3.0",
"vitest": "^4.0.16"
}
}
}
85 changes: 85 additions & 0 deletions pages/legal/cookies/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, viewport-fit=cover">
<title>Cookie Policy - Doctorina</title>
<meta name="description" content="Doctorina Cookie Policy">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap" rel="stylesheet">
<link rel="icon" href="/favicon.ico">
<link rel="stylesheet" href="/legal/legal.css">
</head>

<body>
<div id="app">
<header id="header">
<a href="https://doctorina.com" class="header-logo" aria-label="Doctorina"><svg width="502" height="76"
viewBox="0 0 502 76" style="height:28px;width:auto" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M131.782 75.7736C127.152 75.7736 123.134 74.7198 119.726 72.6122C116.318 70.5047 113.65 67.5409 111.721 63.7209C109.857 59.8351 108.925 55.2907 108.925 50.0876C108.925 44.8187 109.889 40.2084 111.818 36.2567C113.747 32.2392 116.479 29.1108 120.015 26.8715C123.616 24.6322 127.86 23.5125 132.746 23.5125C135.768 23.5125 138.565 24.0724 141.137 25.192C143.773 26.3116 145.798 27.7935 147.212 29.6376V0H162.065V74.4893H148.08L147.309 68.1666C146.023 70.4059 143.966 72.25 141.137 73.6989C138.372 75.082 135.253 75.7736 131.782 75.7736ZM135.35 61.8439C137.665 61.8439 139.69 61.3499 141.426 60.362C143.226 59.3082 144.608 57.8593 145.573 56.0151C146.602 54.1052 147.116 51.9317 147.116 49.4949C147.116 46.9921 146.602 44.8187 145.573 42.9746C144.608 41.1305 143.226 39.7144 141.426 38.7265C139.69 37.6727 137.665 37.1458 135.35 37.1458C133.035 37.1458 131.01 37.6727 129.274 38.7265C127.538 39.7803 126.188 41.2293 125.223 43.0734C124.323 44.9175 123.873 47.058 123.873 49.4949C123.873 51.9317 124.323 54.0722 125.223 55.9164C126.188 57.7605 127.538 59.2094 129.274 60.2632C131.01 61.317 133.035 61.8439 135.35 61.8439Z"
fill="#25D366" />
<path
d="M164.586 49.6924C164.586 44.4894 165.712 39.945 167.962 36.0591C170.277 32.1074 173.427 29.0449 177.413 26.8715C181.464 24.698 186.061 23.6113 191.205 23.6113C196.348 23.6113 200.913 24.698 204.9 26.8715C208.886 29.0449 212.004 32.1074 214.255 36.0591C216.569 39.945 217.727 44.4894 217.727 49.6924C217.727 54.8955 216.569 59.4399 214.255 63.3258C212.004 67.2116 208.886 70.2412 204.9 72.4146C200.913 74.5881 196.348 75.6748 191.205 75.6748C186.061 75.6748 181.464 74.5881 177.413 72.4146C173.427 70.2412 170.277 67.2116 167.962 63.3258C165.712 59.4399 164.586 54.8955 164.586 49.6924ZM179.535 49.5937C179.535 52.0964 180.017 54.3028 180.982 56.2127C182.011 58.0569 183.393 59.5058 185.129 60.5596C186.865 61.5475 188.89 62.0415 191.205 62.0415C193.519 62.0415 195.545 61.5475 197.281 60.5596C199.017 59.5058 200.367 58.0569 201.331 56.2127C202.296 54.3028 202.778 52.0964 202.778 49.5937C202.778 47.0909 202.296 44.9175 201.331 43.0734C200.367 41.2293 199.017 39.8132 197.281 38.8253C195.545 37.7715 193.519 37.2446 191.205 37.2446C188.89 37.2446 186.865 37.7715 185.129 38.8253C183.393 39.8132 182.011 41.2293 180.982 43.0734C180.017 44.9175 179.535 47.0909 179.535 49.5937Z"
fill="#25D366" />
<path
d="M217.706 49.5937C217.706 44.5223 218.766 40.0438 220.888 36.1579C223.01 32.2062 225.903 29.1108 229.568 26.8715C233.297 24.6322 237.573 23.5125 242.395 23.5125C249.532 23.5125 255.318 25.3896 259.755 29.1437C264.191 32.8978 266.634 38.002 267.084 44.4565H252.136C251.621 41.9537 250.593 40.1096 249.049 38.9241C247.571 37.7386 245.545 37.1458 242.974 37.1458C240.916 37.1458 239.084 37.6727 237.476 38.7265C235.933 39.7144 234.744 41.1305 233.908 42.9746C233.072 44.8187 232.654 47.0251 232.654 49.5937C232.654 52.2281 233.04 54.5003 233.811 56.4103C234.647 58.2544 235.805 59.6705 237.283 60.6584C238.827 61.6463 240.659 62.1403 242.781 62.1403C245.417 62.1403 247.506 61.5475 249.049 60.362C250.657 59.1106 251.686 57.2665 252.136 54.8296H267.084C266.763 58.9789 265.509 62.6342 263.323 65.7956C261.201 68.8911 258.372 71.3279 254.836 73.1062C251.3 74.8845 247.281 75.7736 242.781 75.7736C237.701 75.7736 233.265 74.6869 229.472 72.5134C225.742 70.34 222.849 67.3104 220.792 63.4246C218.734 59.4729 217.706 54.8626 217.706 49.5937Z"
fill="#25D366" />
<path
d="M264.657 25.0932H297.834V37.7386H264.657V25.0932ZM288.672 74.4893H273.82V9.78042H288.672V74.4893Z"
fill="#25D366" />
<path
d="M295.406 49.6924C295.406 44.4894 296.531 39.945 298.782 36.0591C301.096 32.1074 304.247 29.0449 308.233 26.8715C312.284 24.698 316.881 23.6113 322.025 23.6113C327.168 23.6113 331.733 24.698 335.719 26.8715C339.706 29.0449 342.824 32.1074 345.074 36.0591C347.389 39.945 348.546 44.4894 348.546 49.6924C348.546 54.8955 347.389 59.4399 345.074 63.3258C342.824 67.2116 339.706 70.2412 335.719 72.4146C331.733 74.5881 327.168 75.6748 322.025 75.6748C316.881 75.6748 312.284 74.5881 308.233 72.4146C304.247 70.2412 301.096 67.2116 298.782 63.3258C296.531 59.4399 295.406 54.8955 295.406 49.6924ZM310.355 49.5937C310.355 52.0964 310.837 54.3028 311.802 56.2127C312.83 58.0569 314.213 59.5058 315.949 60.5596C317.685 61.5475 319.71 62.0415 322.025 62.0415C324.339 62.0415 326.364 61.5475 328.1 60.5596C329.836 59.5058 331.187 58.0569 332.151 56.2127C333.115 54.3028 333.598 52.0964 333.598 49.5937C333.598 47.0909 333.115 44.9175 332.151 43.0734C331.187 41.2293 329.836 39.8132 328.1 38.8253C326.364 37.7715 324.339 37.2446 322.025 37.2446C319.71 37.2446 317.685 37.7715 315.949 38.8253C314.213 39.8132 312.83 41.2293 311.802 43.0734C310.837 44.9175 310.355 47.0909 310.355 49.5937Z"
fill="#25D366" />
<path
d="M384.306 25.0932V39.4181H379.58C375.336 39.4181 371.993 40.4718 369.55 42.5794C367.171 44.687 365.981 48.1776 365.981 53.0514V74.4893H351.129V25.192H365.113L366.271 35.7628H364.921C365.563 32.4697 367.01 29.7694 369.26 27.6618C371.575 25.4884 374.693 24.4017 378.615 24.4017C379.516 24.4017 380.416 24.4675 381.316 24.5992C382.28 24.6651 383.277 24.8298 384.306 25.0932Z"
fill="#25D366" />
<path
d="M385.788 74.4893V25.0932H400.641V74.4893H385.788ZM393.118 17.3874C390.739 17.3874 388.714 16.5641 387.042 14.9176C385.435 13.2052 384.631 11.1306 384.631 8.69371C384.631 6.25684 385.435 4.21513 387.042 2.56859C388.714 0.922059 390.739 0.098791 393.118 0.098791C395.433 0.098791 397.394 0.922059 399.001 2.56859C400.673 4.21513 401.509 6.25684 401.509 8.69371C401.509 11.1306 400.673 13.2052 399.001 14.9176C397.394 16.5641 395.433 17.3874 393.118 17.3874Z"
fill="#25D366" />
<path
d="M420.607 74.4893H405.755V25.0932H419.739L420.704 30.2304C422.183 28.1228 424.208 26.4763 426.78 25.2908C429.416 24.1053 432.309 23.5125 435.46 23.5125C441.182 23.5125 445.618 25.3237 448.769 28.9461C451.984 32.5026 453.591 37.5081 453.591 43.9625V74.4893H438.739V47.6178C438.739 44.5223 437.967 42.0525 436.424 40.2084C434.881 38.2984 432.823 37.3434 430.252 37.3434C427.294 37.3434 424.947 38.2655 423.211 40.1096C421.475 41.8879 420.607 44.3247 420.607 47.4202V74.4893Z"
fill="#25D366" />
<path
d="M472.778 75.7736C467.698 75.7736 463.648 74.3576 460.626 71.5255C457.668 68.6276 456.19 64.7747 456.19 59.9668C456.19 55.4224 457.701 51.8 460.722 49.0997C463.809 46.3994 468.245 44.8187 474.032 44.3577L487.534 43.271V42.4806C487.534 40.8341 487.212 39.4839 486.569 38.4301C485.926 37.3105 484.994 36.4872 483.772 35.9603C482.615 35.3676 481.136 35.0712 479.336 35.0712C476.185 35.0712 473.774 35.664 472.103 36.8495C470.495 38.035 469.692 39.7474 469.692 41.9867H457.347C457.347 38.2326 458.279 34.9724 460.144 32.2062C462.008 29.4401 464.644 27.2996 468.052 25.7848C471.524 24.2699 475.542 23.5125 480.107 23.5125C484.801 23.5125 488.755 24.3687 491.97 26.0811C495.249 27.7935 497.724 30.2963 499.396 33.5893C501.132 36.8824 502 40.9 502 45.642V74.4893H488.884L487.919 67.969C487.148 70.2083 485.315 72.0853 482.422 73.6002C479.593 75.0491 476.378 75.7736 472.778 75.7736ZM477.986 64.5113C480.815 64.5113 483.129 63.8197 484.93 62.4366C486.73 60.9877 487.63 58.8472 487.63 56.0151V53.3478L480.107 54.0393C476.893 54.3028 474.61 54.8626 473.26 55.7188C471.974 56.5091 471.331 57.6946 471.331 59.2753C471.331 61.0536 471.878 62.3708 472.971 63.227C474.064 64.0832 475.735 64.5113 477.986 64.5113Z"
fill="#25D366" />
<path fill-rule="evenodd" clip-rule="evenodd"
d="M75.7164 71.5545L70.6396 56.9303C75.2837 48.9429 76.849 39.5339 75.0411 30.4732C73.2331 21.4125 68.1766 13.3247 60.8227 7.7314C53.4688 2.13809 44.3245 -0.575207 35.11 0.101947C25.8956 0.779101 17.2461 4.80003 10.7889 11.4083C4.33168 18.0166 0.51178 26.7566 0.047829 35.9843C-0.416122 45.2119 2.50786 54.2911 8.26968 61.5137C14.0315 68.7363 22.234 73.6046 31.3341 75.2025C40.4342 76.8005 49.8045 75.0181 57.6824 70.1906L74.201 73.3163C74.4156 73.3913 74.6494 73.3913 74.864 73.3163C75.0812 73.2377 75.2742 73.1037 75.4237 72.9276C75.5732 72.7515 75.6741 72.5394 75.7164 72.3123C75.7726 72.0884 75.7726 71.8542 75.7164 71.6303V71.5545Z"
fill="#25D366" />
<path
d="M61.4267 42.506L43.8099 60.0477L43.7722 60.0859L43.7339 60.1234C42.1746 61.6563 40.0713 62.515 37.8803 62.5132C35.6893 62.5114 33.5874 61.6494 32.0306 60.114L32.0017 60.0859L31.9734 60.0571L14.3467 42.506C9.99059 38.1659 8.55355 32.0207 10.0366 26.491C10.7718 23.7495 12.2052 21.2434 14.198 19.2153C12.6817 20.7941 11.8527 22.9053 11.8913 25.0896C11.93 27.274 12.8331 29.3548 14.4043 30.8795C15.9755 32.4041 18.0877 33.2494 20.2815 33.2313C22.4752 33.2132 24.5731 32.3334 26.1187 30.783L32.0001 24.9229L37.887 19.0622C44.3875 12.5893 54.9267 12.5893 61.4267 19.0622C67.9267 25.5351 67.9272 36.0309 61.4267 42.506Z"
fill="url(#paint0_linear_167_1257)" />
<path
d="M31.9953 24.9295L26.114 30.7897C24.5736 32.364 22.4682 33.2645 20.2611 33.2931C18.054 33.3216 15.9259 32.4759 14.3449 30.9419C12.764 29.4079 11.8597 27.3113 11.8311 25.1134C11.8024 22.9155 12.6517 20.7963 14.1921 19.2219L14.2664 19.1451L14.3042 19.107L14.3802 19.0313L14.4185 18.9937L14.4956 18.9197C16.0557 17.4439 18.1292 16.6273 20.2809 16.6411C22.4326 16.6549 24.4954 17.4981 26.0363 18.9937L26.0746 19.0313L26.1506 19.107L26.1883 19.1451L31.9953 24.9295Z"
fill="url(#paint1_linear_167_1257)" />
<path
d="M60.6196 32.674C60.6165 33.7099 60.2036 34.7026 59.471 35.4351C58.7383 36.1676 57.7455 36.5805 56.7094 36.5835H51.8245C51.8138 36.5834 51.8032 36.5854 51.7933 36.5895C51.7834 36.5935 51.7744 36.5995 51.7668 36.6071C51.7593 36.6146 51.7533 36.6236 51.7493 36.6335C51.7452 36.6434 51.7432 36.654 51.7433 36.6647V41.5497C51.7407 42.5859 51.3279 43.5789 50.5952 44.3118C49.8625 45.0447 48.8695 45.4577 47.8332 45.4608C46.7971 45.4577 45.8043 45.0449 45.0716 44.3123C44.339 43.5798 43.9261 42.5872 43.923 41.5512V36.6662C43.9231 36.6555 43.9211 36.6449 43.9171 36.635C43.913 36.6251 43.907 36.6161 43.8995 36.6086C43.8919 36.601 43.8829 36.5951 43.873 36.591C43.8631 36.587 43.8525 36.5849 43.8419 36.585H38.9561C37.9197 36.582 36.9267 36.1689 36.194 35.4361C35.4614 34.7032 35.0486 33.7102 35.046 32.674C35.049 31.638 35.4619 30.6454 36.1946 29.9129C36.9272 29.1803 37.92 28.7675 38.9561 28.7644H43.8411C43.8518 28.7645 43.8624 28.7625 43.8723 28.7585C43.8822 28.7544 43.8912 28.7484 43.8987 28.7409C43.9063 28.7333 43.9122 28.7243 43.9163 28.7144C43.9203 28.7046 43.9224 28.694 43.9223 28.6833V23.7983C43.9249 22.762 44.3376 21.769 45.0703 21.0361C45.803 20.3033 46.796 19.8902 47.8324 19.8872C48.8685 19.8902 49.8613 20.3031 50.5939 21.0356C51.3266 21.7681 51.7395 22.7608 51.7425 23.7967V28.6817C51.7424 28.6924 51.7444 28.703 51.7485 28.7129C51.7525 28.7228 51.7585 28.7318 51.7661 28.7394C51.7736 28.7469 51.7826 28.7529 51.7925 28.7569C51.8024 28.761 51.813 28.763 51.8237 28.7629H56.7087C57.7452 28.7657 58.7384 29.1787 59.4712 29.9116C60.2041 30.6445 60.6169 31.6376 60.6196 32.674Z"
fill="url(#paint2_linear_167_1257)" />
<defs>
<linearGradient id="paint0_linear_167_1257" x1="9.47181" y1="38.3604" x2="66.3021" y2="38.3604"
gradientUnits="userSpaceOnUse">
<stop stop-color="white" />
<stop offset="1" stop-color="white" />
</linearGradient>
<linearGradient id="paint1_linear_167_1257" x1="13.0749" y1="22.583" x2="30.5736" y2="31.8725"
gradientUnits="userSpaceOnUse">
<stop stop-color="white" />
<stop offset="1" stop-color="white" stop-opacity="0.1" />
</linearGradient>
<linearGradient id="paint2_linear_167_1257" x1="47.8328" y1="2.38915" x2="47.8328" y2="45.4605"
gradientUnits="userSpaceOnUse">
<stop stop-color="white" stop-opacity="0.5" />
<stop offset="1" stop-color="#25D366" />
</linearGradient>
</defs>
</svg></a>
<div data-legal-locale-selector></div>
</header>
<main id="content" data-legal="cookies" data-version="latest"></main>
</div>
<script src="/legal/legal.js"></script>
</body>

</html>
Loading
Loading