aboutsummaryrefslogtreecommitdiff
path: root/app/views/file
diff options
context:
space:
mode:
authorPhilipp Schüttlöffel <schuettloeffel@zqs.uni-hannover.de>2024-09-24 10:53:31 +0200
committerPhilipp Schüttlöffel <schuettloeffel@zqs.uni-hannover.de>2024-09-24 10:53:31 +0200
commit4459dd7917f4d1c34f40bb68f0e991e9c3d53e4c (patch)
tree5c07151ae61276d334e88f6309c30d439a85c12e /app/views/file
parentda0022e5c1abbf9825ae76debaabdff7e8623bb4 (diff)
parent97a188592c679890a25c37ab78463add76a52ff7 (diff)
Merge branch 'main' into issue-3911issue-3911
Diffstat (limited to 'app/views/file')
-rw-r--r--app/views/file/_terms_of_use_select.php22
-rw-r--r--app/views/file/add_files_window.php4
-rw-r--r--app/views/file/add_url.php20
-rw-r--r--app/views/file/choose_destination.php4
-rw-r--r--app/views/file/file_details.php20
-rw-r--r--app/views/file/folder_details.php2
-rw-r--r--app/views/file/new_edit_folder_form.php17
7 files changed, 44 insertions, 45 deletions
diff --git a/app/views/file/_terms_of_use_select.php b/app/views/file/_terms_of_use_select.php
index 59cb507..c1aae00 100644
--- a/app/views/file/_terms_of_use_select.php
+++ b/app/views/file/_terms_of_use_select.php
@@ -24,20 +24,20 @@ if (!$selected_terms_of_use_id) {
aria-description="<?= htmlReady(kill_format($content_terms_of_use_entry->description)) ?>">
<label for="content_terms_of_use-<?= htmlReady($content_terms_of_use_entry->id) ?>">
- <div class="icon">
- <? if ($content_terms_of_use_entry['icon']) : ?>
- <? if (filter_var($content_terms_of_use_entry['icon'], FILTER_VALIDATE_URL)): ?>
- <img src="<?= htmlReady($content_terms_of_use_entry['icon']) ?>" width="32" height="32">
- <? else : ?>
- <?= Icon::create($content_terms_of_use_entry['icon'], Icon::ROLE_CLICKABLE)->asImg(32) ?>
- <? endif ?>
- <? endif ?>
- </div>
+ <?= Icon::create('radiobutton-unchecked')->asImg(24, ['class' => 'arrow']) ?>
+ <?= Icon::create('radiobutton-checked')->asImg(24, ['class' => 'check']) ?>
<div class="text">
<?= htmlReady($content_terms_of_use_entry->name) ?>
</div>
- <?= Icon::create('arr_1down', Icon::ROLE_CLICKABLE)->asImg(24, ['class' => 'arrow']) ?>
- <?= Icon::create('check-circle', Icon::ROLE_CLICKABLE)->asImg(32, ['class' => 'check']) ?>
+ <div class="icon">
+ <? if ($content_terms_of_use_entry['icon']) : ?>
+ <? if (filter_var($content_terms_of_use_entry['icon'], FILTER_VALIDATE_URL)): ?>
+ <img src="<?= htmlReady($content_terms_of_use_entry['icon']) ?>" width="32" height="32">
+ <? else : ?>
+ <?= Icon::create($content_terms_of_use_entry['icon'], Icon::ROLE_CLICKABLE)->asImg(32) ?>
+ <? endif ?>
+ <? endif ?>
+ </div>
</label>
<? if (trim($content_terms_of_use_entry->description)): ?>
diff --git a/app/views/file/add_files_window.php b/app/views/file/add_files_window.php
index 53a7b73..8b963e7 100644
--- a/app/views/file/add_files_window.php
+++ b/app/views/file/add_files_window.php
@@ -38,7 +38,7 @@ if ($folder_id) {
<?= Icon::create('computer')->asImg(50) ?>
<?= _('Mein Computer') ?>
</a>
- <a href="<?= $controller->link_for('file/add_url/' . $folder_id, array_merge($options, ['from_plugin' => ""])) ?>" data-dialog>
+ <a href="<?= $controller->link_for('file/add_url/' . $folder_id, array_merge($options, ['from_plugin' => ""])) ?>" data-dialog="size=medium">
<?= Icon::create('globe')->asImg(50) ?>
<?= _('Webadresse') ?>
</a>
@@ -69,7 +69,7 @@ if ($folder_id) {
<?= _('OER Campus') ?>
</a>
<? endif ?>
- <? foreach (PluginManager::getInstance()->getPlugins('FilesystemPlugin') as $plugin) : ?>
+ <? foreach (PluginManager::getInstance()->getPlugins(FilesystemPlugin::class) as $plugin) : ?>
<? if ($plugin->isSource()) : ?>
<? $nav = $plugin->getFileSelectNavigation() ?>
<? if ($nav): ?>
diff --git a/app/views/file/add_url.php b/app/views/file/add_url.php
index 1b7196b..8a172c9 100644
--- a/app/views/file/add_url.php
+++ b/app/views/file/add_url.php
@@ -13,25 +13,25 @@
value="<?= htmlReady(Request::get('name')) ?>">
</label>
- <label>
- <?= _('Zugriffsart') ?>
- </label>
+ </fieldset>
+ <fieldset>
+ <legend><?= _('Zugriffsart') ?></legend>
<label>
<input type="radio" name="access_type" value="redirect"
- <? if (Request::option('access_type') !== 'proxy') echo 'checked'; ?>>
+ <? if (Request::option('access_type') !== 'proxy') echo 'checked'; ?>>
<?= _('Direktlink')?>
</label>
<label>
<input type="radio" name="access_type" value="proxy"
- <? if (Request::option('access_type') === 'proxy') echo 'checked'; ?>>
+ <? if (Request::option('access_type') === 'proxy') echo 'checked'; ?>>
<?= _('Link über Proxy')?>
</label>
- <?= $this->render_partial('file/_terms_of_use_select.php', [
- 'content_terms_of_use_entries' => $content_terms_of_use_entries,
- 'selected_terms_of_use_id' => $content_terms_of_use_id,
- ]) ?>
- </fieldset>
+ </fieldset>
+ <?= $this->render_partial('file/_terms_of_use_select.php', [
+ 'content_terms_of_use_entries' => $content_terms_of_use_entries,
+ 'selected_terms_of_use_id' => $content_terms_of_use_id,
+ ]) ?>
<footer data-dialog-button>
<?= Studip\Button::createAccept(_('Speichern'), 'store') ?>
<?= Studip\LinkButton::createCancel(
diff --git a/app/views/file/choose_destination.php b/app/views/file/choose_destination.php
index 49afe87..c71f072 100644
--- a/app/views/file/choose_destination.php
+++ b/app/views/file/choose_destination.php
@@ -33,7 +33,7 @@ $options = array_filter([
<?= Icon::create('folder-parent', Icon::ROLE_CLICKABLE)->asInput(50, ['formaction' => $controller->action_url('choose_folder/' . $parent_folder->getId()), 'to_plugin' => $options['from_plugin'] ?? null]) ?>
<button
class="undecorated"
- formaction="<?= $controller->action_link('choose_folder/' . $parent_folder->getId()) ?>" <? if ($options['from_plugin']): ?> name="to_plugin" value="<?= htmlReady($options['from_plugin'] ?? null) ?>"<? endif; ?>
+ formaction="<?= $controller->action_link('choose_folder/' . $parent_folder->getId()) ?>" <? if (!empty($options['from_plugin'])): ?> name="to_plugin" value="<?= htmlReady($options['from_plugin']) ?>"<? endif; ?>
data-dialog="size=medium">
<?= _('Aktueller Ordner') ?>
</button>
@@ -64,7 +64,7 @@ $options = array_filter([
</button>
</div>
- <? foreach (PluginManager::getInstance()->getPlugins('FilesystemPlugin') as $plugin) : ?>
+ <? foreach (PluginManager::getInstance()->getPlugins(FilesystemPlugin::class) as $plugin) : ?>
<? if ($plugin->isPersonalFileArea()) : ?>
<? $nav = $plugin->getFileSelectNavigation() ?>
<? if ($nav) : ?>
diff --git a/app/views/file/file_details.php b/app/views/file/file_details.php
index 76f996a..ddbd7e4 100644
--- a/app/views/file/file_details.php
+++ b/app/views/file/file_details.php
@@ -1,21 +1,21 @@
<?php
/**
- * @var Flexi_Template $this
- * @var FileController $controller
- * @var Flexi_Template|null $file_info_template
- * @var array $fullpath
- * @var FileType $file
- * @var string|null $previous_file_ref_id
- * @var string|null $next_file_ref_id
- * @var string|null $from_plugin
- * @var bool $include_navigation
+ * @var Flexi\Template $this
+ * @var FileController $controller
+ * @var Flexi\Template|null $file_info_template
+ * @var array $fullpath
+ * @var FileType $file
+ * @var string|null $previous_file_ref_id
+ * @var string|null $next_file_ref_id
+ * @var string|null $from_plugin
+ * @var bool $include_navigation
*/
?>
<div id="file_details_window">
<?= $this->render_partial('file/_file_aside.php') ?>
<div id="preview_container">
- <? if ($file_info_template instanceof Flexi_Template) : ?>
+ <? if ($file_info_template instanceof Flexi\Template) : ?>
<?= $file_info_template->render() ?>
<? endif ?>
<h3><?=_('Pfad')?></h3>
diff --git a/app/views/file/folder_details.php b/app/views/file/folder_details.php
index 5bd6574..7d1fe04 100644
--- a/app/views/file/folder_details.php
+++ b/app/views/file/folder_details.php
@@ -10,7 +10,7 @@ $folder_template = $folder->getDescriptionTemplate();
<? if (!empty($folder_template)) : ?>
<h3><?= _('Beschreibung') ?></h3>
<article>
- <? if ($folder_template instanceof Flexi_Template): ?>
+ <? if ($folder_template instanceof Flexi\Template): ?>
<?= $folder_template->render() ?>
<? else: ?>
<?= $folder_template ?>
diff --git a/app/views/file/new_edit_folder_form.php b/app/views/file/new_edit_folder_form.php
index c1301d4..32b9800 100644
--- a/app/views/file/new_edit_folder_form.php
+++ b/app/views/file/new_edit_folder_form.php
@@ -27,20 +27,19 @@
id="folder-type-<?= htmlReady($folder_type['class']) ?>"
<? if ($folder_type['class'] === get_class($folder)) echo 'checked'; ?>>
<label for="folder-type-<?= htmlReady($folder_type['class']) ?>">
+ <?= Icon::create('radiobutton-unchecked')->asImg(24, ['class' => 'arrow']) ?>
+ <?= Icon::create('radiobutton-checked')->asImg(24, ['class' => 'check']) ?>
+ <div class="text">
+ <?= htmlReady($folder_type['name']) ?>
+ <? if ($template = $folder_type['instance']->getDescriptionTemplate()): ?>
+ <?= tooltipIcon($template instanceof Flexi\Template ? $template->render() : $template, false, true) ?>
+ <? endif ?>
+ </div>
<div class="icon">
<? if ($folder_type['icon']) : ?>
<?= $folder_type['icon']->asImg(32) ?>
<? endif ?>
</div>
- <div class="text">
- <?= htmlReady($folder_type['name']) ?>
- <? if ($template = $folder_type['instance']->getDescriptionTemplate()): ?>
- <?= tooltipIcon($template instanceof Flexi_Template ? $template->render() : $template, false, true) ?>
- <? endif; ?>
-
- </div>
- <?= Icon::create('arr_1down')->asImg(24, ['class' => 'arrow']) ?>
- <?= Icon::create('check-circle')->asImg(32, ['class' => 'check']) ?>
</label>
<? if ($folder_type['class'] === get_class($folder)) : ?>
<? $folder_template = $folder->getEditTemplate() ?>