JSFiddle - React, Tailwind, and code Playground

by dledle2

HTML

<html>
<head>
  <meta charset="UTF-8">
  <title>Encrypted Page Generator v03</title>
  <style>
    body {
      font-family: sans-serif;
      padding: 1rem;
      background-color: #f4f4f4;
      color: #333;
      line-height: 1.6;
    }
    label {
      display: block;
      margin: 0.8rem 0 0.3rem;
      font-weight: bold;
    }
    textarea {
      width: 100%;
      box-sizing: border-box;
      font-family: monospace;
      margin-bottom: 0.8rem;
      border: 1px solid #ccc;
      padding: 0.5rem;
      border-radius: 4px;
    }
    #payloadInput {
      height: 200px;
    }
    #output {
      height: 250px;
      white-space: pre;
      overflow: auto;
      background-color: #e9e9e9;
    }
    #description {
      margin-top: 1.5rem;
      font-weight: bold;
    }
    button {
      padding: 0.6rem 1.2rem;
      margin-top: 0.5rem;
      margin-bottom: 1rem;
      cursor: pointer;
      background-color: #007bff;
      color: white;
      border: none;
      border-radius: 4px;
      font-size: 1rem;
    }
    button:hover {
      background-color: #0056b3;
    }
    .stats {
      font-size: 0.9em;
      color: #555;
      margin-bottom: 0.2rem;
      background-color: #e9e9f9;
      padding: 0.3rem 0.5rem;
      border-radius: 3px;
    }
    #processingStats ul {
      list-style-type: disc;
      padding-left: 20px; /* Indent list items */
      margin-top: 0.3rem;
      margin-bottom: 0.3rem;
    }
    #processingStats li {
      margin-bottom: 0.2rem;
      font-size: 0.85em;
    }
  </style>
</head>
<body>
  <h1>Encrypted Page Generator v03</h1>

  <label for="payloadInput">Paste full HTML page here:</label>
  <div id="inputStats" class="stats">Original HTML size: 0 bytes</div>
  <textarea id="payloadInput" placeholder="<!DOCTYPE html>\n<html>\n<head>\n  <title>My Secret Page</title>\n</head>\n<body>\n  <h1>Hello Secret World!</h1>\n  <p>This content is protected.</p>\n  <script>console.log('Original script...