python-hwpx-automation 8.0.1__tar.gz → 8.0.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (255) hide show
  1. {python_hwpx_automation-8.0.1/src/python_hwpx_automation.egg-info → python_hwpx_automation-8.0.2}/PKG-INFO +3 -3
  2. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/README.md +1 -1
  3. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/pyproject.toml +5 -3
  4. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/content.py +19 -0
  5. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/layout_style.py +2 -12
  6. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/identity.json +4 -4
  7. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/content_layout.py +2 -7
  8. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/preview_export.py +16 -26
  9. python_hwpx_automation-8.0.2/src/hwpx_automation/preview/_chrome.py +45 -0
  10. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/preview/document_viewer.py +22 -8
  11. python_hwpx_automation-8.0.2/src/hwpx_automation/preview/layout_preview.py +4236 -0
  12. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/public-modules.json +5 -4
  13. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2/src/python_hwpx_automation.egg-info}/PKG-INFO +3 -3
  14. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/python_hwpx_automation.egg-info/SOURCES.txt +1 -0
  15. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/python_hwpx_automation.egg-info/requires.txt +1 -1
  16. python_hwpx_automation-8.0.1/src/hwpx_automation/preview/layout_preview.py +0 -757
  17. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/LICENSE +0 -0
  18. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/MANIFEST.in +0 -0
  19. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/NOTICE +0 -0
  20. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/setup.cfg +0 -0
  21. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/__init__.py +0 -0
  22. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/__init__.pyi +0 -0
  23. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/__main__.py +0 -0
  24. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/agent_document.py +0 -0
  25. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/api.py +0 -0
  26. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/blind_eval.py +0 -0
  27. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/capabilities.py +0 -0
  28. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/compat.py +0 -0
  29. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/configuration.py +0 -0
  30. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/__init__.py +0 -0
  31. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/context.py +0 -0
  32. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/diff.py +0 -0
  33. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/document.py +0 -0
  34. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/formatting.py +0 -0
  35. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/handles.py +0 -0
  36. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/locations.py +0 -0
  37. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/locator.py +0 -0
  38. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/plan.py +0 -0
  39. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/resources.py +0 -0
  40. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/search.py +0 -0
  41. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/transactions.py +0 -0
  42. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/core/txn.py +0 -0
  43. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/document_state.py +0 -0
  44. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/errors.py +0 -0
  45. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/execution_lock.py +0 -0
  46. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/fastmcp_adapter.py +0 -0
  47. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/form_fill.py +0 -0
  48. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/form_output_models.py +0 -0
  49. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/format_rules.py +0 -0
  50. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/forms/__init__.py +0 -0
  51. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/forms/choices.py +0 -0
  52. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/forms/labels.py +0 -0
  53. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/__init__.py +0 -0
  54. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/_shared.py +0 -0
  55. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/agent_document.py +0 -0
  56. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/authoring.py +0 -0
  57. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/content_edit.py +0 -0
  58. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/form_fill.py +0 -0
  59. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/quality_render.py +0 -0
  60. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/read_export.py +0 -0
  61. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/specialized.py +0 -0
  62. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/tracked_changes.py +0 -0
  63. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/handlers/workflow.py +0 -0
  64. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/hwp_converter.py +0 -0
  65. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/hwp_support.py +0 -0
  66. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/hwpx_ops.py +0 -0
  67. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/identity.py +0 -0
  68. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest/__init__.py +0 -0
  69. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest/_types.py +0 -0
  70. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest/adapters.py +0 -0
  71. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest/base.py +0 -0
  72. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest/hwpx_converter.py +0 -0
  73. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ingest_adapters.py +0 -0
  74. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/integrations/__init__.py +0 -0
  75. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/integrations/langchain.py +0 -0
  76. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/integrations/llama_index.py +0 -0
  77. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/mail_merge.py +0 -0
  78. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/markdown/__init__.py +0 -0
  79. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/markdown/_export.py +0 -0
  80. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/markdown/_import.py +0 -0
  81. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/markdown/_plain_export.py +0 -0
  82. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/markdown_plan.py +0 -0
  83. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/mcp_cli.py +0 -0
  84. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/metadata/tools_meta.py +0 -0
  85. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/minimal_profile.py +0 -0
  86. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/mixed_form.py +0 -0
  87. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/mutation_models.py +0 -0
  88. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/network_policy.py +0 -0
  89. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/__init__.py +0 -0
  90. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/__init__.py +0 -0
  91. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/_batch_publication.py +0 -0
  92. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/_batch_verification.py +0 -0
  93. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/_text_scope.py +0 -0
  94. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/__init__.py +0 -0
  95. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/bundle.py +0 -0
  96. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/catalog.py +0 -0
  97. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/dump.py +0 -0
  98. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/mapping.py +0 -0
  99. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/model.py +0 -0
  100. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/native.py +0 -0
  101. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/blueprint/replay.py +0 -0
  102. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/catalog.py +0 -0
  103. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/cli.py +0 -0
  104. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/commands.py +0 -0
  105. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/document.py +0 -0
  106. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/form_plan.py +0 -0
  107. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/model.py +0 -0
  108. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/path.py +0 -0
  109. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/query.py +0 -0
  110. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/agent/story.py +0 -0
  111. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/__init__.py +0 -0
  112. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/advanced_generators.py +0 -0
  113. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/builder/__init__.py +0 -0
  114. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/builder/core.py +0 -0
  115. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/builder/report.py +0 -0
  116. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/__init__.py +0 -0
  117. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/_support.py +0 -0
  118. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/composer.py +0 -0
  119. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/harvest.py +0 -0
  120. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/marked.py +0 -0
  121. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/plan.py +0 -0
  122. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profile.py +0 -0
  123. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/application_form/fragments.hwpx +0 -0
  124. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/application_form/profile.json +0 -0
  125. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/application_form/template.hwpx +0 -0
  126. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/home_notice/fragments.hwpx +0 -0
  127. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/home_notice/profile.json +0 -0
  128. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/home_notice/template.hwpx +0 -0
  129. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/official_notice/fragments.hwpx +0 -0
  130. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/official_notice/profile.json +0 -0
  131. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/official_notice/template.hwpx +0 -0
  132. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/report/fragments.hwpx +0 -0
  133. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/report/profile.json +0 -0
  134. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/profiles/report/template.hwpx +0 -0
  135. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/design/validator.py +0 -0
  136. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/presets/__init__.py +0 -0
  137. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/presets/proposal.py +0 -0
  138. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/report_parser.py +0 -0
  139. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/style_profile.py +0 -0
  140. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/authoring/template_analyzer.py +0 -0
  141. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/charting/__init__.py +0 -0
  142. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/compact/__init__.py +0 -0
  143. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/compliance/__init__.py +0 -0
  144. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/compliance/official_lint.py +0 -0
  145. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/compliance/pii.py +0 -0
  146. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/compliance/reference_consistency.py +0 -0
  147. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/document_ops/__init__.py +0 -0
  148. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/document_ops/comparison.py +0 -0
  149. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/document_ops/mail_merge.py +0 -0
  150. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/document_ops/redline.py +0 -0
  151. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/evalplan/__init__.py +0 -0
  152. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/evalplan/runtime.py +0 -0
  153. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/__init__.py +0 -0
  154. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/compose.py +0 -0
  155. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/ir.py +0 -0
  156. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/measure.py +0 -0
  157. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/parser.py +0 -0
  158. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/exam/profile.py +0 -0
  159. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/__init__.py +0 -0
  160. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/classification.py +0 -0
  161. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fill_residue.py +0 -0
  162. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/__init__.py +0 -0
  163. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/apply.py +0 -0
  164. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/engine.py +0 -0
  165. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/measure.py +0 -0
  166. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/policy.py +0 -0
  167. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/report.py +0 -0
  168. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/seal.py +0 -0
  169. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/fit/wordbox.py +0 -0
  170. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/guidance.py +0 -0
  171. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/quality.py +0 -0
  172. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/split_run.py +0 -0
  173. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/form_fill/template_formfit.py +0 -0
  174. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/__init__.py +0 -0
  175. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/composition.py +0 -0
  176. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/data/bank.json +0 -0
  177. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/data/genres.json +0 -0
  178. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/gianmun.py +0 -0
  179. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/house_style/org_chart.py +0 -0
  180. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/quality/__init__.py +0 -0
  181. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/quality/page_guard.py +0 -0
  182. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/__init__.py +0 -0
  183. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/__main__.py +0 -0
  184. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/_hancom_alerts_mac.applescript +0 -0
  185. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/_hancom_open_rate.ps1 +0 -0
  186. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/_refresh_hwpx_mac.applescript +0 -0
  187. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/_render_hwpx.ps1 +0 -0
  188. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/_render_hwpx_mac.applescript +0 -0
  189. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/block_splits.py +0 -0
  190. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/cli.py +0 -0
  191. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/detectors.py +0 -0
  192. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/diff.py +0 -0
  193. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/fixture_corpus.py +0 -0
  194. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/mac_session.py +0 -0
  195. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/oracle.py +0 -0
  196. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/page_qa.py +0 -0
  197. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/qa_contracts.py +0 -0
  198. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/qa_metrics.py +0 -0
  199. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/rendering/worker.py +0 -0
  200. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/utilities/__init__.py +0 -0
  201. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/utilities/report_utils.py +0 -0
  202. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/utilities/table_cleanup.py +0 -0
  203. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/office/utilities/table_compute.py +0 -0
  204. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/__init__.py +0 -0
  205. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/_border_fill.py +0 -0
  206. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/composition.py +0 -0
  207. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/context.py +0 -0
  208. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/form_fields.py +0 -0
  209. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/media.py +0 -0
  210. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/memo_style.py +0 -0
  211. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/package_validation.py +0 -0
  212. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/planning.py +0 -0
  213. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/read_query.py +0 -0
  214. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/save_policy.py +0 -0
  215. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/tables.py +0 -0
  216. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/ops_services/transactions.py +0 -0
  217. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/preview/__init__.py +0 -0
  218. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/preview/equation_render.py +0 -0
  219. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/preview/mathml.py +0 -0
  220. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/preview_output_models.py +0 -0
  221. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/py.typed +0 -0
  222. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/quality.py +0 -0
  223. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/quality_generation.py +0 -0
  224. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/resources.py +0 -0
  225. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/runtime.py +0 -0
  226. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/runtime_services.py +0 -0
  227. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/save_dates.py +0 -0
  228. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/server.py +0 -0
  229. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/storage.py +0 -0
  230. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/tool_bindings.py +0 -0
  231. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/tool_contract.py +0 -0
  232. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/upstream.py +0 -0
  233. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/utils/__init__.py +0 -0
  234. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/utils/helpers.py +0 -0
  235. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/utils/read_budget.py +0 -0
  236. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/visual_qa.py +0 -0
  237. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/__init__.py +0 -0
  238. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/adapters.py +0 -0
  239. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/dispatcher.py +0 -0
  240. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/evidence_lineage.py +0 -0
  241. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/models.py +0 -0
  242. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/policy.py +0 -0
  243. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/render_contracts.py +0 -0
  244. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/render_metrics.py +0 -0
  245. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/render_queue.py +0 -0
  246. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/render_security.py +0 -0
  247. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/render_transport.py +0 -0
  248. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/rendering.py +0 -0
  249. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/service.py +0 -0
  250. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/state_machine.py +0 -0
  251. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workflow/store.py +0 -0
  252. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/hwpx_automation/workspace.py +0 -0
  253. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/python_hwpx_automation.egg-info/dependency_links.txt +0 -0
  254. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/python_hwpx_automation.egg-info/entry_points.txt +0 -0
  255. {python_hwpx_automation-8.0.1 → python_hwpx_automation-8.0.2}/src/python_hwpx_automation.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-hwpx-automation
3
- Version: 8.0.1
3
+ Version: 8.0.2
4
4
  Summary: Task-oriented HWPX document automation for Python, with an optional MCP adapter.
5
5
  Author: Kohkyuhyun
6
6
  License-Expression: Apache-2.0
@@ -20,7 +20,7 @@ Requires-Python: >=3.10
20
20
  Description-Content-Type: text/markdown
21
21
  License-File: LICENSE
22
22
  License-File: NOTICE
23
- Requires-Dist: python-hwpx<8,>=7.0.2
23
+ Requires-Dist: python-hwpx<8,>=7.0.3
24
24
  Requires-Dist: pydantic<3,>=2.11
25
25
  Requires-Dist: tomli>=2.0; python_version < "3.11"
26
26
  Provides-Extra: mcp
@@ -306,7 +306,7 @@ handshake는 core/automation/plugin 버전+해시 skew를 fail-closed로 차단
306
306
 
307
307
  <!-- release-state: release-approved -->
308
308
  > [!NOTE]
309
- > 발행이 승인된 8.0.1 후보 (release-approved; 원격 발행 대기): `python-hwpx 7.0.2 → python-hwpx-automation 8.0.1 → hwpx-plugin 8.0.1` (`c895883d5f4350ae`). 이 좌표는 `src/hwpx_automation/identity.json`의 `releaseState.candidate`와 같아야 합니다(`tests/test_audit_identity_docs.py`).
309
+ > 발행이 승인된 8.0.2 후보 (release-approved; 원격 발행 대기): `python-hwpx 7.0.3 → python-hwpx-automation 8.0.2 → hwpx-plugin 8.0.2` (`c895883d5f4350ae`). 이 좌표는 `src/hwpx_automation/identity.json`의 `releaseState.candidate`와 같아야 합니다(`tests/test_audit_identity_docs.py`).
310
310
  > 공개 트레인: `python-hwpx 7.0.0 → python-hwpx-automation 8.0.0 → hwpx-plugin 8.0.0`.
311
311
  > [발행·설치 영수증](https://github.com/airmang/python-hwpx-automation/blob/main/docs/releases/2026-11-21-engine-7-automation-8.md)
312
312
  > 공개 좌표는 core·automation PyPI와 plugin GitHub
@@ -234,7 +234,7 @@ handshake는 core/automation/plugin 버전+해시 skew를 fail-closed로 차단
234
234
 
235
235
  <!-- release-state: release-approved -->
236
236
  > [!NOTE]
237
- > 발행이 승인된 8.0.1 후보 (release-approved; 원격 발행 대기): `python-hwpx 7.0.2 → python-hwpx-automation 8.0.1 → hwpx-plugin 8.0.1` (`c895883d5f4350ae`). 이 좌표는 `src/hwpx_automation/identity.json`의 `releaseState.candidate`와 같아야 합니다(`tests/test_audit_identity_docs.py`).
237
+ > 발행이 승인된 8.0.2 후보 (release-approved; 원격 발행 대기): `python-hwpx 7.0.3 → python-hwpx-automation 8.0.2 → hwpx-plugin 8.0.2` (`c895883d5f4350ae`). 이 좌표는 `src/hwpx_automation/identity.json`의 `releaseState.candidate`와 같아야 합니다(`tests/test_audit_identity_docs.py`).
238
238
  > 공개 트레인: `python-hwpx 7.0.0 → python-hwpx-automation 8.0.0 → hwpx-plugin 8.0.0`.
239
239
  > [발행·설치 영수증](https://github.com/airmang/python-hwpx-automation/blob/main/docs/releases/2026-11-21-engine-7-automation-8.md)
240
240
  > 공개 좌표는 core·automation PyPI와 plugin GitHub
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "python-hwpx-automation"
7
- version = "8.0.1"
7
+ version = "8.0.2"
8
8
  description = "Task-oriented HWPX document automation for Python, with an optional MCP adapter."
9
9
  readme = "README.md"
10
10
  authors = [{ name = "Kohkyuhyun" }]
@@ -32,10 +32,12 @@ dependencies = [
32
32
  # console name (core stopped declaring it at 5.0), which is what makes "no
33
33
  # valid install has two declarers" true rather than hopeful. The bounded
34
34
  # major (<8) keeps the next core major from silently breaking an
35
- # already-published automation line. 7.0.2 is the patch floor of 8.0.1:
35
+ # already-published automation line. 7.0.2 became the patch floor in 8.0.1:
36
36
  # the engine refuses to overwrite an existing .hwp on every write path and
37
37
  # moves section settings back on saving, which this package's tools rely on.
38
- "python-hwpx>=7.0.2,<8", # HWPX object model, OXML/OPC, format-native primitives
38
+ # 7.0.3 is the floor of 8.0.2: the HTML preview lays pages out from
39
+ # hwpx.experimental.estimate_layout, which 7.0.3 adds.
40
+ "python-hwpx>=7.0.3,<8", # HWPX object model, OXML/OPC, format-native primitives
39
41
 
40
42
  "pydantic>=2.11,<3",
41
43
  # cryptography (workflow store only) is the [workflow] extra and anyio is
@@ -796,3 +796,22 @@ def collect_full_text(doc: Any) -> str:
796
796
  if text:
797
797
  chunks.append(text)
798
798
  return "\n".join(chunks)
799
+
800
+
801
+ def page_number_count(story: Any) -> int:
802
+ """Page numbers in a header or footer, paragraphs in its cells and text boxes included.
803
+
804
+ Hancom writes a page number as an automatic number (``hp:autoNum numType="PAGE"``) alone;
805
+ python-hwpx up to 7.x also adds a page-number control (``hp:pageNum``) beside it, and some
806
+ older files hold only the control. A paragraph counts the larger of the two, so a number
807
+ written either way, or both ways, counts once.
808
+ """
809
+
810
+ count = 0
811
+ for paragraph in getattr(story, "paragraphs", None) or ():
812
+ for inner in (paragraph, *(place.paragraph for place in paragraph.iter_paragraphs())):
813
+ items = [item for run in inner.runs for item in run.content]
814
+ pages = sum(1 for item in items if item.kind == "auto_number" and item.attribute("numType") == "PAGE")
815
+ controls = sum(1 for item in items if item.kind == "page_number")
816
+ count += max(pages, controls)
817
+ return count
@@ -13,6 +13,7 @@ from ..office.authoring.style_profile import (
13
13
 
14
14
  from ..core.content import (
15
15
  add_memo_to_doc,
16
+ page_number_count,
16
17
  remove_memo_from_doc,
17
18
  )
18
19
  from ..core.document import open_doc
@@ -378,21 +379,10 @@ def _header_footer_payload(
378
379
  "pageType": page_type,
379
380
  "id": getattr(wrapper, "id", None),
380
381
  "text": getattr(wrapper, "text", ""),
381
- "pageNumberCount": _page_number_count(wrapper),
382
+ "pageNumberCount": page_number_count(wrapper),
382
383
  }
383
384
 
384
385
 
385
- def _page_number_count(story: Any) -> int:
386
- """머리말·꼬리말 안(칸·글상자 속 문단까지)의 쪽 번호 컨트롤(``run.content``의 ``page_number``) 수."""
387
-
388
- count = 0
389
- for paragraph in getattr(story, "paragraphs", None) or ():
390
- for inner in (paragraph, *(place.paragraph for place in paragraph.iter_paragraphs())):
391
- for run in inner.runs:
392
- count += sum(1 for item in run.content if item.kind == "page_number")
393
- return count
394
-
395
-
396
386
  def set_header_footer(
397
387
  filename: str,
398
388
  kind: str,
@@ -5,12 +5,12 @@
5
5
  "releaseState": {
6
6
  "status": "release-approved",
7
7
  "candidate": {
8
- "pythonHwpx": "7.0.2",
8
+ "pythonHwpx": "7.0.3",
9
9
  "canonicalDistribution": "python-hwpx-automation",
10
- "canonicalAutomation": "8.0.1",
10
+ "canonicalAutomation": "8.0.2",
11
11
  "compatibilityDistribution": "hwpx-mcp-server",
12
- "compatibility": "8.0.1",
13
- "plugin": "8.0.1",
12
+ "compatibility": "8.0.2",
13
+ "plugin": "8.0.2",
14
14
  "contractHash": "c895883d5f4350ae"
15
15
  },
16
16
  "currentPublic": {
@@ -5,6 +5,7 @@ from __future__ import annotations
5
5
  import logging
6
6
  from typing import Any, Dict, Optional, Sequence
7
7
 
8
+ from ..core.content import page_number_count
8
9
  from .context import DocumentContext
9
10
  from .save_policy import SavePolicy
10
11
  from .transactions import TransactionService
@@ -409,18 +410,12 @@ class ContentLayoutService:
409
410
  kind: str,
410
411
  page_type: str,
411
412
  ) -> Dict[str, Any]:
412
- # 쪽 번호 컨트롤 수: 머리말·꼬리말 안(칸·글상자 속 문단까지)의 run.content "page_number".
413
- page_number_count = 0
414
- for paragraph in getattr(wrapper, "paragraphs", None) or ():
415
- for inner in (paragraph, *(place.paragraph for place in paragraph.iter_paragraphs())):
416
- for run in inner.runs:
417
- page_number_count += sum(1 for item in run.content if item.kind == "page_number")
418
413
  return {
419
414
  "kind": kind,
420
415
  "pageType": page_type,
421
416
  "id": getattr(wrapper, "id", None),
422
417
  "text": getattr(wrapper, "text", ""),
423
- "pageNumberCount": page_number_count,
418
+ "pageNumberCount": page_number_count(wrapper),
424
419
  }
425
420
 
426
421
  def set_header_footer(
@@ -7,16 +7,16 @@ import json
7
7
  import logging
8
8
  import math
9
9
  import re
10
- import subprocess
11
10
  from datetime import datetime, timezone
12
11
  from pathlib import Path
13
- from typing import Any, Dict, Mapping, Optional, Sequence
12
+ from typing import Any, Collection, Dict, Mapping, Optional, Sequence
14
13
 
15
14
  from ..configuration import absolute_executable, env_value, find_executable
16
15
  from ..hwp_converter import HwpConversionError, convert_hwp_to_hwpx
17
16
  from ..preview import latex2mathml_available as _latex2mathml_available
18
17
  from ..preview import render_document_viewer as render_hwpx_document_viewer
19
18
  from ..preview import render_layout_preview as render_hwpx_layout_preview
19
+ from ..preview._chrome import capture_page as capture_chrome_page
20
20
  from ..upstream import (
21
21
  export_document,
22
22
  )
@@ -185,6 +185,7 @@ class PreviewExportService:
185
185
  *,
186
186
  page_html_paths: Sequence[Path],
187
187
  pages: Sequence[Dict[str, Any]],
188
+ flow_pages: Collection[int] = (),
188
189
  output_dir: Path,
189
190
  max_pages: int | None,
190
191
  embed_images: bool = False,
@@ -212,6 +213,10 @@ class PreviewExportService:
212
213
  device_scale_factor=1,
213
214
  )
214
215
  browser_page.goto(html_path.as_uri(), wait_until="load")
216
+ height = (
217
+ browser_page.evaluate("document.documentElement.scrollHeight")
218
+ if index in flow_pages else height
219
+ )
215
220
  browser_page.screenshot(path=str(output_path), full_page=True)
216
221
  browser_page.close()
217
222
  item = {
@@ -257,34 +262,15 @@ class PreviewExportService:
257
262
  page_info = pages[index]
258
263
  width, height = _page_viewport(page_info)
259
264
  output_path = output_dir / f"page-{index + 1:03d}.png"
260
- command = [
261
- chrome,
262
- "--headless=new",
263
- "--disable-gpu",
264
- "--hide-scrollbars",
265
- "--no-first-run",
266
- "--no-default-browser-check",
267
- f"--window-size={width},{height}",
268
- f"--screenshot={output_path}",
269
- html_path.as_uri(),
270
- ]
271
265
  try:
272
- completed = subprocess.run(
273
- command,
274
- check=False,
275
- stdout=subprocess.PIPE,
276
- stderr=subprocess.PIPE,
277
- text=True,
278
- timeout=60,
266
+ height, error = capture_chrome_page(
267
+ chrome, html_path, output_path, width, height, flow=index in flow_pages,
279
268
  )
280
269
  except Exception as exc: # pragma: no cover - environment specific
281
270
  failures.append(f"page {index + 1}: {exc}")
282
271
  continue
283
- if completed.returncode != 0 or not output_path.exists():
284
- detail = (
285
- completed.stderr or completed.stdout or "unknown error"
286
- ).strip()
287
- failures.append(f"page {index + 1}: {detail}")
272
+ if error is not None:
273
+ failures.append(f"page {index + 1}: {error}")
288
274
  continue
289
275
  item = {
290
276
  "pageIndex": index,
@@ -348,7 +334,7 @@ class PreviewExportService:
348
334
  "pageCount": viewer.page_count,
349
335
  "warnings": list(viewer.preview.warnings),
350
336
  "fidelityTier": (
351
- "text-approx-pagination; "
337
+ f"{viewer.preview.fidelity_tier}; "
352
338
  f"equations={_equation_tier(equation_rendering)}"
353
339
  ),
354
340
  "equationLibrary": "latex2mathml" if library_available else "absent",
@@ -439,6 +425,10 @@ class PreviewExportService:
439
425
  screenshots, screenshot_engine = self._capture_preview_pages(
440
426
  page_html_paths=page_html_paths,
441
427
  pages=pages,
428
+ flow_pages={
429
+ index for index, fragment in enumerate(preview.page_fragments)
430
+ if 'data-layout-mode="flow"' in fragment
431
+ },
442
432
  output_dir=output_path,
443
433
  max_pages=max_pages,
444
434
  embed_images=embed_images,
@@ -0,0 +1,45 @@
1
+ # SPDX-License-Identifier: Apache-2.0
2
+
3
+ """Capture a standalone preview page with headless Chrome."""
4
+
5
+ from __future__ import annotations
6
+
7
+ import re
8
+ import subprocess
9
+ from pathlib import Path
10
+
11
+
12
+ def capture_page(
13
+ chrome: str, html_path: Path, output_path: Path, width: int, height: int, *, flow: bool,
14
+ ) -> tuple[int, str | None]:
15
+ command = [
16
+ chrome,
17
+ "--headless=new",
18
+ "--disable-gpu",
19
+ "--hide-scrollbars",
20
+ "--no-first-run",
21
+ "--no-default-browser-check",
22
+ ]
23
+ url = html_path.as_uri()
24
+ if flow:
25
+ measured = subprocess.run(
26
+ [*command, f"--window-size={width},{height}", "--dump-dom", url],
27
+ capture_output=True,
28
+ text=True,
29
+ timeout=60,
30
+ check=True,
31
+ )
32
+ match = re.search(r'<section [^>]*\bdata-flow-height="(\d+)"', measured.stdout)
33
+ if match is None:
34
+ return height, "Chrome did not measure the flow height"
35
+ height = max(height, int(match[1]))
36
+ captured = subprocess.run(
37
+ [*command, f"--window-size={width},{height}", f"--screenshot={output_path}", url],
38
+ capture_output=True,
39
+ text=True,
40
+ timeout=60,
41
+ check=False,
42
+ )
43
+ if captured.returncode or not output_path.exists():
44
+ return height, (captured.stderr or captured.stdout or "unknown error").strip()
45
+ return height, None
@@ -15,15 +15,23 @@ inlined and equations render as native MathML. Pagination is approximate
15
15
 
16
16
  from __future__ import annotations
17
17
 
18
- from dataclasses import dataclass
19
18
  import html
19
+ from dataclasses import dataclass
20
20
  from pathlib import Path
21
21
  from typing import Any
22
22
 
23
- from .layout_preview import LayoutPreview, _base_css, render_layout_preview
23
+ from .layout_preview import (
24
+ _APPROX,
25
+ _BADGES,
26
+ _PARTIAL,
27
+ LayoutPreview,
28
+ _base_css,
29
+ _flow_overflow_script,
30
+ render_layout_preview,
31
+ )
24
32
 
25
33
  # Honest fidelity statement shown in the top bar (Constitution IX).
26
- FIDELITY_BADGE = "텍스트 근사 프리뷰 · 페이지네이션은 한컴과 다를 수 있음 · 수식 MathML 렌더"
34
+ FIDELITY_BADGE = _BADGES[_APPROX]
27
35
 
28
36
 
29
37
  @dataclass(frozen=True)
@@ -44,6 +52,8 @@ class DocumentViewer:
44
52
  "title": self.title,
45
53
  "pageCount": self.page_count,
46
54
  "warnings": list(self.preview.warnings),
55
+ "fidelityTier": self.preview.fidelity_tier,
56
+ "limitations": [item.as_dict() for item in self.preview.limitations],
47
57
  "byteSize": len(self.html.encode("utf-8")),
48
58
  }
49
59
 
@@ -128,7 +138,7 @@ def _viewer_script() -> str:
128
138
  )
129
139
 
130
140
 
131
- def _viewer_html(title: str, mode: str, pages_html: str, page_count: int) -> str:
141
+ def _viewer_html(title: str, mode: str, pages_html: str, page_count: int, badge: str, *, has_flow: bool) -> str:
132
142
  safe_title = html.escape(title)
133
143
  count = max(page_count, 1)
134
144
  return (
@@ -145,11 +155,12 @@ def _viewer_html(title: str, mode: str, pages_html: str, page_count: int) -> str
145
155
  ' <header class="hwpx-viewer-bar">\n'
146
156
  f' <div class="hwpx-viewer-title">{safe_title}</div>\n'
147
157
  f' <div class="hwpx-viewer-page" id="hwpx-viewer-page">1 / {count}</div>\n'
148
- f' <div class="hwpx-viewer-badge">{html.escape(FIDELITY_BADGE)}</div>\n'
158
+ f' <div class="hwpx-viewer-badge">{html.escape(badge)}</div>\n'
149
159
  " </header>\n"
150
160
  ' <main class="hwpx-viewer-scroll">\n'
151
161
  f"{pages_html}\n"
152
162
  " </main>\n"
163
+ f"{_flow_overflow_script() if has_flow else ''}"
153
164
  f" <script>{_viewer_script()}</script>\n"
154
165
  "</body>\n"
155
166
  "</html>\n"
@@ -168,16 +179,19 @@ def render_document_viewer(
168
179
  source: HWPX file path or raw HWPX bytes.
169
180
  title: document title shown in the top bar.
170
181
  mode: ``"pages"`` for discrete page boxes (each tracked by the page
171
- indicator) or ``"long"`` for one continuous page.
182
+ indicator) or ``"long"`` for continuous scrolling.
172
183
 
173
184
  Returns:
174
185
  A :class:`DocumentViewer` whose ``html`` is a standalone HTML
175
- document (no external resources, one inline script; equations render as native MathML).
186
+ document (no external resources; equations render as native MathML).
176
187
  """
177
188
 
178
189
  preview = render_layout_preview(source, mode=mode, title=title)
179
190
  pages_html = "".join(preview.page_fragments)
180
- document = _viewer_html(title, mode, pages_html, len(preview.pages))
191
+ document = _viewer_html(
192
+ title, mode, pages_html, len(preview.pages), preview.badge,
193
+ has_flow=preview.fidelity_tier == _PARTIAL,
194
+ )
181
195
  return DocumentViewer(html=document, preview=preview, title=title)
182
196
 
183
197