Add Phase Z frame slot telemetry markers
- add frame slot markers to F29 runtime partial - collect per-cell frame slot metrics in visual runtime check - preserve existing visual status and failure routing behavior
This commit is contained in:
@@ -748,7 +748,36 @@ def run_overflow_check(html_path: Path) -> dict:
|
||||
zones.push(m);
|
||||
});
|
||||
|
||||
return { slide: slideM, slide_body: bodyM, zones };
|
||||
// B5 v0 — frame_slot_metrics (per-cell measurement of [data-frame-slot-id])
|
||||
// 현재 F29 partial 만 marker 보유 (process_column / product_column × 3 cells = 6 entries 기대).
|
||||
// 다른 frame (F13 / F16) 은 marker 미적용 → entry 0 — 정상.
|
||||
const frame_slot_metrics = [];
|
||||
slide.querySelectorAll('[data-frame-slot-id]').forEach((cell) => {
|
||||
const slotId = cell.getAttribute('data-frame-slot-id');
|
||||
const m2 = measure(cell);
|
||||
const parentZone = cell.closest('.zone');
|
||||
const zonePos = parentZone
|
||||
? (parentZone.getAttribute('data-zone-position') || 'unknown')
|
||||
: 'unknown';
|
||||
const zoneTid = parentZone
|
||||
? (parentZone.getAttribute('data-template-id') || '?')
|
||||
: '?';
|
||||
frame_slot_metrics.push({
|
||||
zone_position: zonePos,
|
||||
zone_template_id: zoneTid,
|
||||
frame_slot_id: slotId,
|
||||
class_name: cell.className,
|
||||
clientWidth: m2.clientWidth,
|
||||
clientHeight: m2.clientHeight,
|
||||
scrollWidth: m2.scrollWidth,
|
||||
scrollHeight: m2.scrollHeight,
|
||||
excess_x: m2.excess_x,
|
||||
excess_y: m2.excess_y,
|
||||
overflowed: m2.overflowed,
|
||||
});
|
||||
});
|
||||
|
||||
return { slide: slideM, slide_body: bodyM, zones, frame_slot_metrics };
|
||||
""")
|
||||
|
||||
screenshot_path = html_path.parent / "preview.png"
|
||||
|
||||
@@ -209,7 +209,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
|
||||
{# ───── Row 1: section 1 ───── #}
|
||||
{% set s1 = slot_payload.process.sections[0] %}
|
||||
<div class="f29b__cell f29b__cell--left">
|
||||
<div class="f29b__cell f29b__cell--left" data-frame-slot-id="process_column">
|
||||
{% if s1.title %}
|
||||
<div class="f29b__section-title">{{ s1.title | safe }}</div>
|
||||
{% if s1.transforms %}
|
||||
@@ -236,7 +236,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
</div>
|
||||
|
||||
{% set p1 = slot_payload.product.sections[0] %}
|
||||
<div class="f29b__cell f29b__cell--right">
|
||||
<div class="f29b__cell f29b__cell--right" data-frame-slot-id="product_column">
|
||||
{% if p1.title %}
|
||||
<div class="f29b__section-title">{{ p1.title | safe }}</div>
|
||||
{% for line in p1.text_lines %}<div class="text-line text-line--bullet{% if line.indent > 0 %} text-line--indent-{{ line.indent }}{% endif %}">{{ line.text | safe }}</div>{% endfor %}
|
||||
@@ -245,7 +245,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
|
||||
{# ───── Row 2: section 2 ───── #}
|
||||
{% set s2 = slot_payload.process.sections[1] %}
|
||||
<div class="f29b__cell f29b__cell--left">
|
||||
<div class="f29b__cell f29b__cell--left" data-frame-slot-id="process_column">
|
||||
{% if s2.title %}
|
||||
<div class="f29b__section-title">{{ s2.title | safe }}</div>
|
||||
{% for line in s2.text_lines %}<div class="text-line text-line--bullet{% if line.indent > 0 %} text-line--indent-{{ line.indent }}{% endif %}">{{ line.text | safe }}</div>{% endfor %}
|
||||
@@ -253,7 +253,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
</div>
|
||||
|
||||
{% set p2 = slot_payload.product.sections[1] %}
|
||||
<div class="f29b__cell f29b__cell--right">
|
||||
<div class="f29b__cell f29b__cell--right" data-frame-slot-id="product_column">
|
||||
{% if p2.title %}
|
||||
<div class="f29b__section-title">{{ p2.title | safe }}</div>
|
||||
{% for line in p2.text_lines %}<div class="text-line text-line--bullet{% if line.indent > 0 %} text-line--indent-{{ line.indent }}{% endif %}">{{ line.text | safe }}</div>{% endfor %}
|
||||
@@ -265,7 +265,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
|
||||
{# ───── Row 3: section 3 ───── #}
|
||||
{% set s3 = slot_payload.process.sections[2] %}
|
||||
<div class="f29b__cell f29b__cell--left">
|
||||
<div class="f29b__cell f29b__cell--left" data-frame-slot-id="process_column">
|
||||
{% if s3.title %}
|
||||
<div class="f29b__section-title">{{ s3.title | safe }}</div>
|
||||
{% for line in s3.text_lines %}<div class="text-line text-line--bullet{% if line.indent > 0 %} text-line--indent-{{ line.indent }}{% endif %}">{{ line.text | safe }}</div>{% endfor %}
|
||||
@@ -273,7 +273,7 @@ slots: title (omitted), banner_left, banner_right,
|
||||
</div>
|
||||
|
||||
{% set p3 = slot_payload.product.sections[2] %}
|
||||
<div class="f29b__cell f29b__cell--right">
|
||||
<div class="f29b__cell f29b__cell--right" data-frame-slot-id="product_column">
|
||||
{% if p3.title %}
|
||||
<div class="f29b__section-title">{{ p3.title | safe }}{% if p3.sub_title %}<span class="f29b__section-title__sub">{{ p3.sub_title | safe }}</span>{% endif %}</div>
|
||||
{% for line in p3.text_lines %}<div class="text-line text-line--bullet{% if line.indent > 0 %} text-line--indent-{{ line.indent }}{% endif %}">{{ line.text | safe }}</div>{% endfor %}
|
||||
|
||||
Reference in New Issue
Block a user