Skip to content

Commit

Permalink
Merge pull request #144 from oat-sa/fix/INV-707/missing-tooltip
Browse files Browse the repository at this point in the history
Fix/INV-707/Missing tooltip
  • Loading branch information
jsconan authored Nov 10, 2023
2 parents 5cd8af8 + 76c58be commit 3a066e6
Show file tree
Hide file tree
Showing 12 changed files with 64 additions and 1,448 deletions.
40 changes: 40 additions & 0 deletions migrations/Version202310251132554106_pciSamples.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<?php

declare(strict_types=1);

namespace oat\pciSamples\migrations;

use Doctrine\DBAL\Schema\Schema;
use oat\pciSamples\scripts\install\RegisterPciTextReaderIMS;
use oat\qtiItemPci\model\IMSPciModel;
use oat\tao\scripts\tools\migrations\AbstractMigration;
use Doctrine\Migrations\Exception\IrreversibleMigration;

/**
* phpcs:disable Squiz.Classes.ValidClassName
*/
final class Version202310251132554106_pciSamples extends AbstractMigration
{
public function getDescription(): string
{
return 'Fix text reader PCI tooltip in the IMS version';
}

public function up(Schema $schema): void
{
$registry = (new IMSPciModel())->getRegistry();
$this->addReport(
$this->propagate(new RegisterPciTextReaderIMS())(['1.1.2'])
);
}

public function down(Schema $schema): void
{
throw new IrreversibleMigration(
sprintf(
'In order to undo this migration, please revert the client-side changes and run %s',
RegisterPciTextReaderIMS::class
)
);
}
}

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"typeIdentifier": "textReaderInteraction",
"label": "Text reader",
"description": "The Paging widget combines a scrolling widget with additional paging controls.",
"version": "1.1.1",
"version": "1.1.2",
"author": "Aleh Hutnikau",
"email": "[email protected]",
"tags": [
Expand Down
519 changes: 1 addition & 518 deletions views/js/pciCreator/ims/textReaderInteraction/imsPciCreator.min.js

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ define(
'taoQtiItem/portableLib/lodash',
'taoQtiItem/portableLib/handlebars',
'textReaderInteraction/runtime/js/tabs',
'taoQtiItem/portableLib/OAT/util/tooltip',
'taoQtiItem/portableLib/jquery.qtip'
],
function ($, _, Handlebars, Tabs) {
function ($, _, Handlebars, Tabs, tooltipRenderer) {
'use strict';

return function (options) {
Expand Down Expand Up @@ -178,6 +179,8 @@ define(
$container = this.options.$container.find('.js-page-container')
.html(markup)
.toggleClass('light-mode', !templateData.multiPages);

tooltipRenderer.render($container);
}

//init tabs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -323,24 +323,25 @@ $buttonDisabledBgDolor: #afb4bb;
margin-left: 70px;
border-left: 1px solid #dddddd;
}
}

/* tooltips */
.qti-item {
.tooltip-active {
/* tooltips */
[data-role="tooltip-target"] {
color: $info;
text-decoration: dashed underline $info;
cursor: pointer;

&:after {
@include tao-icon-setup;
@include icon-info;

font-size: 0.9rem;
content: "";
font-size: 80%;
vertical-align: super;
margin-left: 2px;
display: inline-block;
text-decoration: none;
display: inline-block;
}
}

[data-role="tooltip-content"] {
&[aria-hidden="true"] {
display: none;
}
}
}
Loading

0 comments on commit 3a066e6

Please sign in to comment.