Skip to content

Commit

Permalink
fix: stylesheet 302 issue due to invalid paths (42808)
Browse files Browse the repository at this point in the history
  • Loading branch information
lukas-heinrich authored and thojou committed Dec 12, 2024
1 parent f06537f commit 4945e9d
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 4 deletions.
4 changes: 4 additions & 0 deletions components/ILIAS/TestQuestionPool/TestQuestionPool.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,9 @@ public function init(
new Component\Resource\ComponentJS($this, 'js/dist/bootstrap-tagsinput_2015_25_03.js');
$contribute[Component\Resource\PublicAsset::class] = fn() =>
new Component\Resource\ComponentJS($this, 'js/dist/typeahead_0.11.1.js');
$contribute[Component\Resource\PublicAsset::class] = fn() =>
new Component\Resource\ComponentCSS($this, 'css/lac_legend.css');
$contribute[Component\Resource\PublicAsset::class] = fn() =>
new Component\Resource\ComponentCSS($this, 'css/bootstrap-tagsinput_2015_25_03.css');
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ public function __construct(
global $DIC;
$this->ui_factory = $DIC['ui.factory'];
$this->ui_renderer = $DIC['ui.renderer'];

parent::__construct();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ public function __construct($a_title = "", $a_postvar = "")
$this->setType("tag_input");
$this->tpl->addJavaScript('assets/js/bootstrap-tagsinput_2015_25_03.js');
$this->tpl->addJavaScript('assets/js/typeahead_0.11.1.js');
$this->tpl->addCss('./components/ILIAS/TestQuestionPool/templates/default/bootstrap-tagsinput_2015_25_03.css');
$this->tpl->addCss('assets/css/bootstrap-tagsinput_2015_25_03.css');
}

/**
Expand All @@ -170,7 +170,7 @@ public function checkInput(): bool
$valid = true;

$values = array_filter($this->strArray($this->getPostVar()));
if($values === [] && $this->getRequired()) {
if ($values === [] && $this->getRequired()) {
$this->setAlert($lng->txt("msg_input_is_required"));
return false;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public function setQuestionOBJ(assQuestion $questionOBJ): void
*/
public function get(): \ILIAS\UI\Component\Modal\Modal
{
$this->pageTemplate->addCss('components/ILIAS/TestQuestionPool/templates/default/lac_legend.css');
$this->pageTemplate->addCss('assets/css/lac_legend.css');

$tpl = $this->getTemplate();

Expand Down

0 comments on commit 4945e9d

Please sign in to comment.