Merge pull request 'Add a speaker view with a next-slide preview and keep the live slide in view' (#93) from feature/presenter-notes into main
Reviewed-on: #93
This commit was merged in pull request #93.
This commit is contained in:
commit
0c97f61763
11 files changed
+264
-5
No files matched your search
@@ -37,6 +37,8 @@ $hasInternal = array_filter($slides, fn($slide) => !$slide->is_hidden && $slide-
|
||||
<div class="admin-head__actions">
|
||||
<a class="button button--primary" target="_blank" rel="noopener"
|
||||
href="<?= $this->Url->build($url('admin:present')) ?>">▶ <?= __('Präsentieren') ?></a>
|
||||
<a class="button" target="_blank" rel="noopener" href="<?= $this->Url->build($url('admin:speaker')) ?>"
|
||||
title="<?= h(__('Eigenes Fenster für den Präsentierenden: aktuelle und nächste Folie, ohne die Präsentation zu starten')) ?>">⧉ <?= __('Referentenansicht') ?></a>
|
||||
<?php if ($poll->current_slide_id !== null) : ?>
|
||||
<?= $this->Form->postButton('⏸ ' . __('Pause'), $url('admin:control'), [
|
||||
'data' => ['action' => 'stop'],
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
* (Plenario.presenter) from /admin/{token}/state.
|
||||
*
|
||||
* Keyboard: ←/→ slides, P pause/resume (→ resumes too), V voting on/off, H hide results, F fullscreen, Q QR code, T light/dark.
|
||||
* The speaker view (admin:speaker) is this page plus a preview of the next slide, meant for the presenter's own screen.
|
||||
* Q&A slides: V switches to the next stage; while discussing ←/→ step through the questions first.
|
||||
*
|
||||
* @var \App\View\AppView $this
|
||||
@@ -12,11 +13,13 @@
|
||||
* @var string $joinUrl
|
||||
* @var string $joinBaseUrl
|
||||
* @var int $pollIntervalMs
|
||||
* @var bool|null $speaker Speaker view (second window): adds the preview of the next slide
|
||||
*/
|
||||
$speaker = $speaker ?? false;
|
||||
$this->assign('title', $poll->title);
|
||||
$host = preg_replace('#^https?://#', '', $joinBaseUrl);
|
||||
?>
|
||||
<div class="stage"
|
||||
<div class="stage<?= $speaker ? ' stage--speaker' : '' ?>"
|
||||
data-presenter
|
||||
data-state-url="<?= $this->Url->build(['_name' => 'admin:state', 'token' => $adminToken]) ?>"
|
||||
data-control-url="<?= $this->Url->build(['_name' => 'admin:control', 'token' => $adminToken]) ?>"
|
||||
@@ -42,8 +45,24 @@ $host = preg_replace('#^https?://#', '', $joinBaseUrl);
|
||||
<div class="stage__results" data-results></div>
|
||||
</main>
|
||||
|
||||
<?php if ($speaker) : ?>
|
||||
<aside class="stage__next" data-next aria-label="<?= h(__('Nächste Folie')) ?>">
|
||||
<p class="stage__next-label"><?= __('Als Nächstes') ?> <span data-next-meta></span></p>
|
||||
<h2 class="stage__next-question" data-next-question></h2>
|
||||
<div class="stage__next-description formatted" data-next-description></div>
|
||||
<ul class="stage__next-options" data-next-options></ul>
|
||||
<p class="stage__next-note muted" data-next-note></p>
|
||||
</aside>
|
||||
<?php endif; ?>
|
||||
|
||||
<footer class="stage__controls">
|
||||
<a class="ctrl" href="<?= $this->Url->build(['_name' => 'admin', 'token' => $adminToken]) ?>" title="<?= __('Zur Verwaltung') ?>">✎</a>
|
||||
<?php if (!$speaker) : ?>
|
||||
<a class="ctrl" href="<?= $this->Url->build(['_name' => 'admin:speaker', 'token' => $adminToken]) ?>" target="_blank" rel="noopener"
|
||||
title="<?= __('Referentenansicht in neuem Fenster öffnen (mit Vorschau der nächsten Folie)') ?>">
|
||||
<span aria-hidden="true">⧉</span><span class="sr-only"><?= __('Referentenansicht öffnen') ?></span>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
<button type="button" class="ctrl" data-action="prev" aria-keyshortcuts="ArrowLeft PageUp" title="<?= __('Vorherige Folie (←)') ?>">
|
||||
<span aria-hidden="true">←</span><span class="sr-only"><?= __('Vorherige Folie') ?></span>
|
||||
</button>
|
||||
|
||||
Reference in new issue
Block a user