Workspace - Source Excerpt 04
Summary
This source excerpt preserves a bounded section of Spiralist/wp-content/plugins/spiralist-workspace/templates/workspace.php so readers can inspect the evidence without opening the full source file.
**Source path:** Spiralist/wp-content/plugins/spiralist-workspace/templates/workspace.php
<label class="spiralist-form__field">
<span>Publication Lane</span>
<select name="publication_lane">
<?php foreach (\SpiralistWorkspace\Support\PromptMetaRegistry::publication_lanes() as $value => $label) : ?>
<option value="<?php echo esc_attr($value); ?>" <?php selected((string) ($form_prompt['publication_lane'] ?? 'community_library'), $value); ?>><?php echo esc_html($label); ?></option>
<?php endforeach; ?>
</select>
</label>
<label class="spiralist-form__field">
<span>Provenance</span>
<select name="provenance">
<?php foreach (\SpiralistWorkspace\Support\PromptMetaRegistry::provenances() as $value => $label) : ?>
<option value="<?php echo esc_attr($value); ?>" <?php selected((string) ($form_prompt['provenance'] ?? 'community'), $value); ?>><?php echo esc_html($label); ?></option>
<?php endforeach; ?>
</select>
</label>
<label class="spiralist-form__field">
<span>Maturity Level</span>
<select name="maturity_level">
<?php foreach (\SpiralistWorkspace\Support\PromptMetaRegistry::maturity_levels() as $value => $label) : ?>
<option value="<?php echo esc_attr($value); ?>" <?php selected((string) ($form_prompt['maturity_level'] ?? 'structured_prompt'), $value); ?>><?php echo esc_html($label); ?></option>
<?php endforeach; ?>
</select>
</label>
</div>
<div class="spiralist-workspace-input-grid">
<label class="spiralist-form__field">
<span>Function Tags</span>
<input type="text" name="function_tags" value="<?php echo esc_attr(implode(', ', (array) ($form_prompt['function_tags'] ?? []))); ?>" placeholder="education, research, community" />
</label>
<label class="spiralist-form__field">
<span>Risk Labels</span>
<input type="text" name="risk_labels" value="<?php echo esc_attr(implode(', ', (array) ($form_prompt['risk_labels'] ?? []))); ?>" placeholder="anthropomorphism, privacy_risk" />
</label>
<label class="spiralist-form__field">
<span>License</span>
<select name="license">
<?php foreach (\SpiralistWorkspace\Support\PromptMetaRegistry::licenses() as $value => $label) : ?>
<option value="<?php echo esc_attr($value); ?>" <?php selected((string) ($form_prompt['license'] ?? 'spiralist_contributor'), $value); ?>><?php echo esc_html($label); ?></option>
<?php endforeach; ?>
</select>
</label>
</div>
<label class="spiralist-form__field">
<span>Editorial Note</span>
<textarea rows="4" name="editorial_note" placeholder="Context for publication, archive handling, or safe use."><?php echo esc_textarea((string) ($form_prompt['editorial_note'] ?? '')); ?></textarea>
</label>
<div class="spiralist-workspace-input-grid">
<label class="spiralist-form__field">
<span>Expected Output Notes</span>
<textarea rows="4" name="expected_output_notes"><?php echo esc_textarea((string) ($form_prompt['expected_output_notes'] ?? '')); ?></textarea>
</label>
<label class="spiralist-form__field">
<span>Failure Modes</span>
<textarea rows="4" name="failure_modes"><?php echo esc_textarea((string) ($form_prompt['failure_modes'] ?? '')); ?></textarea>
</label>
</div>
<div class="spiralist-workspace-input-grid">
<label class="spiralist-form__field">
<span>Related Symbols</span>
<input type="text" name="related_symbols" value="<?php echo esc_attr(implode(', ', (array) ($form_prompt['related_symbols'] ?? []))); ?>" placeholder="Continuity, Recursion" />
</label>
<label class="spiralist-form__field">
<span>Related Axioms</span>
<input type="text" name="related_axioms" value="<?php echo esc_attr(implode(', ', (array) ($form_prompt['related_axioms'] ?? []))); ?>" placeholder="Observation before doctrine" />
</label>
<label class="spiralist-form__field">
<span>Related Manuscripts</span>
<input type="text" name="related_manuscripts" value="<?php echo esc_attr(implode(', ', (array) ($form_prompt['related_manuscripts'] ?? []))); ?>" placeholder="The_History_Of_Symbols.png" />
</label>
</div>
</details>
<div class="spiralist-workspace-checkboxes">
<label><input type="checkbox" name="is_forkable" value="1" <?php checked(!empty($form_prompt['is_forkable'])); ?> /> Forkable</label>
<label><input type="checkbox" name="allow_comments" value="1" <?php checked(!empty($form_prompt['allow_comments'])); ?> /> Allow comments</label>
<label><input type="checkbox" name="allow_ratings" value="1" <?php checked(!empty($form_prompt['allow_ratings'])); ?> /> Allow ratings</label>
</div>
<div class="spiralist-workspace-placeholder-panel">
<p class="spiralist-section-tag">Variable Preview</p>
<div class="spiralist-chip-row" data-placeholder-list></div>
</div>
<div class="spiralist-cta-row spiralist-cta-row--start">
<button class="spiralist-button spiralist-button--primary" type="submit">Save Prompt</button>
<?php if (!empty($form_prompt['id'])) : ?>
<a class="spiralist-button spiralist-button--secondary" href="<?php echo esc_url($route_url('prompt/' . rawurlencode((string) ($form_prompt['slug'] ?? '')))); ?>">Open Prompt</a>
<?php endif; ?>
<a class="spiralist-button spiralist-button--tertiary" href="<?php echo esc_url($workspace_url); ?>">Reset</a>
<span class="spiralist-muted" data-form-result></span>
</div>
</form>
</article>
<article class="spiralist-panel">
<p class="spiralist-section-tag">Workspace Summary</p>
<h2 class="spiralist-section-title">Your dashboard</h2>
<div class="spiralist-stat-grid">
<div class="spiralist-stat">
<strong><?php echo esc_html((string) count($my_prompts)); ?></strong>
<span>My prompts</span>