bmc_hub/app/shared/frontend/bug_report_modal.html
Christian 71f6372496 feat: Implement bug reporting feature with screenshot support
- Added a new modal for reporting bugs, including fields for describing the issue and attaching files.
- Implemented backend API for creating bug reports, including rate limiting and metadata logging.
- Introduced a new database table to track bug report submissions for auditing purposes.
- Enhanced the frontend to capture screenshots automatically and allow manual file uploads.
- Added error handling and user feedback for the bug reporting process.
- Updated existing templates and scripts to integrate the new bug reporting functionality.
2026-05-05 19:13:54 +02:00

48 lines
2.6 KiB
HTML

<div class="modal fade" id="bugReportModal" tabindex="-1" aria-hidden="true">
<div class="modal-dialog modal-lg modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title"><i class="bi bi-bug me-2"></i>Rapporter fejl</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Luk"></button>
</div>
<div class="modal-body">
<div class="alert alert-info py-2 small mb-3">
Screenshot tages automatisk af den aktuelle side.
</div>
<div class="mb-3">
<label for="bugActualInput" class="form-label">Hvad gik galt?</label>
<textarea id="bugActualInput" class="form-control" rows="4" maxlength="8000" placeholder="Beskriv problemet"></textarea>
</div>
<div class="mb-3">
<label for="bugExpectedInput" class="form-label">Hvad burde være sket?</label>
<textarea id="bugExpectedInput" class="form-control" rows="4" maxlength="8000" placeholder="Forventet adfærd"></textarea>
</div>
<div class="mb-3">
<label for="bugExtraFileInput" class="form-label">Ekstra fil (valgfri)</label>
<input id="bugExtraFileInput" type="file" class="form-control" />
</div>
<div class="mb-2">
<label class="form-label">Screenshot preview</label>
<div id="bugScreenshotPreviewWrap" class="border rounded p-2 bg-light text-center">
<span id="bugScreenshotPreviewPlaceholder" class="text-muted small">Ingen screenshot endnu</span>
<img id="bugScreenshotPreview" alt="Screenshot preview" style="display:none;max-width:100%;height:auto;border-radius:6px;" />
</div>
</div>
<div id="bugReportStatus" class="small text-muted mt-2"></div>
<div class="small text-muted mt-2">Screenshot forsøges automatisk ved klik på bug-ikonet. Du kan også indsætte med Cmd+V.</div>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-outline-secondary" data-bs-dismiss="modal">Annuller</button>
<button type="button" class="btn btn-primary" id="bugReportSubmitBtn">
<i class="bi bi-send me-1"></i>Send fejlrapport
</button>
</div>
</div>
</div>
</div>