k-v_result.html 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <!DOCTYPE html>
  2. <html lang="zh">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>键值对OCR结果展示</title>
  6. <style>
  7. html, body {
  8. width: 100%;
  9. padding: 0;
  10. margin: 0;
  11. }
  12. .img-line {
  13. width: 100%;
  14. box-sizing: border-box;
  15. display: flex;
  16. justify-content: center;
  17. margin-top: 50px;
  18. }
  19. img {
  20. width: 600px;
  21. height: auto;
  22. box-sizing: border-box;
  23. padding: 5px;
  24. border: 1px solid #000;
  25. }
  26. .data-table {
  27. width: 100%;
  28. justify-content: center;
  29. box-sizing: border-box;
  30. margin: 50px 0;
  31. padding: 0 20px;
  32. }
  33. table {
  34. width: 100%;
  35. border: none;
  36. background-color: aqua;
  37. }
  38. .col-key {
  39. width: 20%;
  40. }
  41. .col-value {
  42. width: 80%;
  43. }
  44. td, th {
  45. background-color: white;
  46. }
  47. .center {
  48. text-align: center;
  49. }
  50. </style>
  51. </head>
  52. <body>
  53. <div class="img-line">
  54. <a target="_blank" href="/{{ raw }}">
  55. <img src="/{{ raw }}" alt="raw">
  56. </a>
  57. </div>
  58. <div class="data-table">
  59. <table>
  60. <thead>
  61. <tr>
  62. <th class="col-key">JSON键</th>
  63. <th class="col-value">数据值</th>
  64. </tr>
  65. </thead>
  66. <tbody>
  67. {% for key, value in data.items() %}
  68. <tr>
  69. <td class="center">{{ key }}</td>
  70. <td>{{ value|safe }}</td>
  71. </tr>
  72. {% endfor %}
  73. </tbody>
  74. </table>
  75. </div>
  76. </body>
  77. </html>