From 196c112243c81ead6a7c7c7013424d8c774cc8e1 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Tue, 20 Jun 2017 16:47:07 +0200 Subject: [PATCH 01/48] Start improving accessibility --- card.js | 86 +++++++++++++++++++++++++++++++++++++++++++------- memory-game.js | 39 +++++++++++++++++++++-- semantics.json | 17 +++++++++- 3 files changed, 126 insertions(+), 16 deletions(-) diff --git a/card.js b/card.js index 660a9bf..76a1c73 100644 --- a/card.js +++ b/card.js @@ -7,10 +7,11 @@ * @extends H5P.EventDispatcher * @param {Object} image * @param {number} id + * @param {string} alt * @param {string} [description] * @param {Object} [styles] */ - MemoryGame.Card = function (image, id, description, styles) { + MemoryGame.Card = function (image, id, alt, description, styles) { /** @alias H5P.MemoryGame.Card# */ var self = this; @@ -18,7 +19,7 @@ EventDispatcher.call(self); var path = H5P.getPath(image.path, id); - var width, height, margin, $card; + var width, height, margin, $card, $wrapper, removedState, flippedState; if (image.width !== undefined && image.height !== undefined) { if (image.width > image.height) { @@ -40,6 +41,7 @@ self.flip = function () { $card.addClass('h5p-flipped'); self.trigger('flip'); + flippedState = true; }; /** @@ -47,6 +49,7 @@ */ self.flipBack = function () { $card.removeClass('h5p-flipped'); + flippedState = false; }; /** @@ -54,6 +57,7 @@ */ self.remove = function () { $card.addClass('h5p-matched'); + removedState = true; }; /** @@ -88,27 +92,85 @@ */ self.appendTo = function ($container) { // TODO: Translate alt attr - $card = $('
  • ' + + $wrapper = $('
  • ' + '
    ' + (styles && styles.backImage ? '' : '') + '
    ' + '
    ' + - 'Memory Card' + + '' + (alt || 'Memory Image') + '' + '
    ' + '
  • ') .appendTo($container) - .children('.h5p-memory-card') - .children('.h5p-front') - .click(function () { - self.flip(); - }) - .end(); + .on('keydown', function (event) { + switch (event.which) { + case 13: // Enter + case 32: // Space + if (!flippedState) { + self.flip(); + event.preventDefault(); + } + return; + case 39: // Right + case 40: // Down + // Move focus forward + self.trigger('next'); + event.preventDefault(); + return; + case 37: // Left + case 38: // Up + // Move focus back + self.trigger('prev'); + event.preventDefault(); + return; + } + }); + $card = $wrapper.children('.h5p-memory-card') + .children('.h5p-front') + .click(function () { + self.flip(); + }) + .end(); }; /** * Re-append to parent container */ self.reAppend = function () { - var parent = $card[0].parentElement.parentElement; - parent.appendChild($card[0].parentElement); + var parent = $wrapper[0].parentElement; + parent.appendChild($wrapper[0]); + }; + + /** + * + */ + self.makeTabbable = function () { + if ($wrapper) { + $wrapper.attr('tabindex', '0'); + } + }; + + /** + * + */ + self.makeUntabbable = function () { + if ($wrapper) { + $wrapper.attr('tabindex', '-1'); + } + }; + + /** + * + */ + self.setFocus = function () { + self.makeTabbable(); + if ($wrapper) { + $wrapper.focus(); + } + }; + + /** + * + */ + self.isFlipped = function () { + return flippedState; }; }; diff --git a/memory-game.js b/memory-game.js index a0029f6..894f512 100644 --- a/memory-game.js +++ b/memory-game.js @@ -220,6 +220,38 @@ H5P.MemoryGame = (function (EventDispatcher, $) { counter.increment(); }); + /** + * @private + * @param {number} direction + */ + var createCardChangeFocusHandler = function (direction) { + return function () { + // Locate next card + for (var i = 0; i < cards.length; i++) { + if (cards[i] === card) { + // Found current card + + var nextCard, fails = 0; + do { + fails++; + nextCard = cards[i + (direction * fails)]; + if (!nextCard) { + return; // No more cards + } + } + while (nextCard.isFlipped()); + + card.makeUntabbable(); + nextCard.setFocus(); + + return; + } + } + }; + }; + + card.on('next', createCardChangeFocusHandler(1)); + card.on('prev', createCardChangeFocusHandler(-1)); cards.push(card); }; @@ -277,16 +309,16 @@ H5P.MemoryGame = (function (EventDispatcher, $) { var cardParams = cardsToUse[i]; if (MemoryGame.Card.isValid(cardParams)) { // Create first card - var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.description, cardStyles); + var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, cardParams.description, cardStyles); if (MemoryGame.Card.hasTwoImages(cardParams)) { // Use matching image for card two - cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.matchAlt, cardParams.description, cardStyles); cardOne.hasTwoImages = cardTwo.hasTwoImages = true; } else { // Add two cards with the same image - cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, cardParams.description, cardStyles); } // Add cards to card list for shuffeling @@ -314,6 +346,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { for (var i = 0; i < cards.length; i++) { cards[i].appendTo($list); } + cards[0].makeTabbable(); if ($list.children().length) { $list.appendTo($container); diff --git a/semantics.json b/semantics.json index fd274e2..52a1f10 100644 --- a/semantics.json +++ b/semantics.json @@ -26,6 +26,13 @@ "importance": "high", "ratio": 1 }, + { + "name": "imageAlt", + "type": "text", + "label": "Alternative text for Image", + "importance": "high", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, { "name": "match", "type": "image", @@ -35,6 +42,14 @@ "description": "An optional image to match against instead of using two cards with the same image.", "ratio": 1 }, + { + "name": "matchAlt", + "type": "text", + "label": "Alternative text for Matching Image", + "importance": "low", + "optional": true, + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, { "name": "description", "type": "text", @@ -146,7 +161,7 @@ "importance": "low", "name": "tryAgain", "type": "text", - "default": "Try again?" + "default": "Reset" }, { "label": "Close button label", From fbe10b4fe2cc6019100c810aa10764ed4a7dca18 Mon Sep 17 00:00:00 2001 From: Peter Leth Date: Wed, 13 Sep 2017 11:51:47 +0200 Subject: [PATCH 02/48] Update da.json Checked on jsonlint.com --- language/da.json | 66 ++++++++++++++++++++++++------------------------ 1 file changed, 33 insertions(+), 33 deletions(-) diff --git a/language/da.json b/language/da.json index 240360f..5a248a2 100644 --- a/language/da.json +++ b/language/da.json @@ -3,87 +3,87 @@ { "widgets":[ { - "label":"Default" + "label":"Standard" } ], - "label":"Cards", + "label":"Kort", "entity":"card", "field":{ - "label":"Card", + "label":"Kort", "fields":[ { - "label":"Image" + "label":"Billede" }, { - "label":"Matching Image", - "description":"An optional image to match against instead of using two cards with the same image." + "label":"Matchende billede", + "description":"Valgfrit billede som match i stedet for at have to kort med det samme billede." }, { - "label":"Description", - "description":"An optional short text that will pop up once the two matching cards are found." + "label":"Beskrivelse", + "description":"Valgfri tekst, som popper op, når to matchende billeder er fundet." } ] } }, { - "label":"Behavioural settings", - "description":"These options will let you control how the game behaves.", + "label":"Indstillinger", + "description":"Disse indstillinger giver dig mulighed for at bestemme, hvordan spillet fremstår.", "fields":[ { - "label":"Position the cards in a square", - "description":"Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label":"Placer kortene kvadratisk", + "description":"Vil forsøge at matche antallet af kolonner og rækker, når kortene placeres. Efterfølgende vil størrelsen på kortene blive tilpasset." }, { - "label":"Number of cards to use", - "description":"Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label":"Antal kort i opgaven", + "description":"Vælges et større tal end 2, vælges kort tilfældigt fra listen af kort." }, { - "label":"Add button for retrying when the game is over" + "label":"Tilføj knap for at prøve spillet igen, når spillet er afsluttet." } ] }, { - "label":"Look and feel", - "description":"Control the visuals of the game.", + "label":"Udseende", + "description":"Indstil spillets udseende.", "fields":[ { - "label":"Theme Color", - "description":"Choose a color to create a theme for your card game.", + "label":"Farvetema", + "description":"Vælg en farve til bagsiden af dine kort.", "default":"#909090", "spectrum":{ } }, { - "label":"Card Back", - "description":"Use a custom back for your cards." + "label":"Bagsidebillede", + "description":"Brug et billede som bagside på dine kort." } ] }, { - "label":"Localization", + "label":"Oversættelse", "fields":[ { - "label":"Card turns text", - "default":"Card turns" + "label":"Tekst når kort vendes", + "default":"Kort vendes" }, { - "label":"Time spent text", - "default":"Time spent" + "label":"Tekst for tidsforbrug", + "default":"Tidsforbrug" }, { - "label":"Feedback text", - "default":"Good work!" + "label":"Feedback tekst", + "default":"Godt klaret!" }, { - "label":"Try again button text", - "default":"Try again?" + "label":"Prøv igen knaptekst", + "default":"Prøv igen?" }, { - "label":"Close button label", - "default":"Close" + "label":"Luk knaptekst", + "default":"Luk" } ] } ] -} \ No newline at end of file +} From f17d7cb4b2887edfde590644988ceb733e9231ab Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Fri, 22 Sep 2017 16:54:08 +0200 Subject: [PATCH 03/48] HFP-1266 Add accessibility labels to controls Improve the overall behavior when using a readspeaker. Still missing localization, dialog support and a proper timer. --- card.js | 65 ++++++++++++++++++++++++++++++++++++++----------- memory-game.css | 8 ++++++ memory-game.js | 62 ++++++++++++++++++++++++++++++++++------------ 3 files changed, 105 insertions(+), 30 deletions(-) diff --git a/card.js b/card.js index 76a1c73..38d1ffe 100644 --- a/card.js +++ b/card.js @@ -21,6 +21,8 @@ var path = H5P.getPath(image.path, id); var width, height, margin, $card, $wrapper, removedState, flippedState; + alt = alt || 'Missing description'; // Default for old games + if (image.width !== undefined && image.height !== undefined) { if (image.width > image.height) { width = '100%'; @@ -35,10 +37,42 @@ width = height = '100%'; } + /** + * Update the cards label to make it accessible to users with a readspeaker + * + * @param {boolean} isMatched The card has been matched + * @param {boolean} announce Announce the current state of the card + * @param {boolean} reset Go back to the default label + */ + self.updateLabel = function (isMatched, announce, reset) { + + // Determine new label from input params + var label = (reset ? 'Unturned' : alt); + if (isMatched) { + label = 'Match found. ' + label; // TODO l10n + } + + // Update the card's label + $wrapper.attr('aria-label', 'Card ' + ($wrapper.index() + 1) + ': ' + label); // TODO l10n + + // Update disabled property + $wrapper.attr('aria-disabled', reset ? null : 'true'); + + // Announce the label change + if (announce) { + $wrapper.blur().focus(); // Announce card label + } + }; + /** * Flip card. */ self.flip = function () { + if (flippedState) { + $wrapper.blur().focus(); // Announce card label again + return; + } + $card.addClass('h5p-flipped'); self.trigger('flip'); flippedState = true; @@ -48,6 +82,7 @@ * Flip card back. */ self.flipBack = function () { + self.updateLabel(null, null, true); // Reset card label $card.removeClass('h5p-flipped'); flippedState = false; }; @@ -55,7 +90,7 @@ /** * Remove. */ - self.remove = function () { + self.remove = function (announce) { $card.addClass('h5p-matched'); removedState = true; }; @@ -64,6 +99,9 @@ * Reset card to natural state */ self.reset = function () { + self.updateLabel(null, null, true); // Reset card label + flippedState = false; + removedState = false; $card[0].classList.remove('h5p-flipped', 'h5p-matched'); }; @@ -91,11 +129,10 @@ * @param {H5P.jQuery} $container */ self.appendTo = function ($container) { - // TODO: Translate alt attr $wrapper = $('
  • ' + '
    ' + (styles && styles.backImage ? '' : '') + '
    ' + '
    ' + - '' + (alt || 'Memory Image') + '' + + '' + alt + '' + '
    ' + '
  • ') .appendTo($container) @@ -103,10 +140,8 @@ switch (event.which) { case 13: // Enter case 32: // Space - if (!flippedState) { - self.flip(); - event.preventDefault(); - } + self.flip(); + event.preventDefault(); return; case 39: // Right case 40: // Down @@ -122,6 +157,7 @@ return; } }); + $wrapper.attr('aria-label', 'Card ' + ($wrapper.index() + 1) + ': Unturned.'); // TODO l10n $card = $wrapper.children('.h5p-memory-card') .children('.h5p-front') .click(function () { @@ -131,7 +167,7 @@ }; /** - * Re-append to parent container + * Re-append to parent container. */ self.reAppend = function () { var parent = $wrapper[0].parentElement; @@ -139,7 +175,7 @@ }; /** - * + * Make the card accessible when tabbing */ self.makeTabbable = function () { if ($wrapper) { @@ -148,7 +184,7 @@ }; /** - * + * Prevent tabbing to the card */ self.makeUntabbable = function () { if ($wrapper) { @@ -157,7 +193,7 @@ }; /** - * + * Make card tabbable and move focus to it */ self.setFocus = function () { self.makeTabbable(); @@ -167,10 +203,11 @@ }; /** - * + * Check if the card has been removed from the game, i.e. if has + * been matched. */ - self.isFlipped = function () { - return flippedState; + self.isRemoved = function () { + return removedState; }; }; diff --git a/memory-game.css b/memory-game.css index 199a07b..4d61392 100644 --- a/memory-game.css +++ b/memory-game.css @@ -1,6 +1,14 @@ .h5p-memory-game { overflow: hidden; } +.h5p-memory-game .h5p-memory-hidden-read { + position: absolute; + top: -1px; + left: -1px; + width: 1px; + height: 1px; + color: transparent; +} .h5p-memory-game > ul { list-style: none !important; padding: 0.25em 0.5em !important; diff --git a/memory-game.js b/memory-game.js index 894f512..a0cb033 100644 --- a/memory-game.js +++ b/memory-game.js @@ -5,6 +5,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { var CARD_STD_SIZE = 116; // PX var STD_FONT_SIZE = 16; // PX var LIST_PADDING = 1; // EMs + var numInstances = 0; /** * Memory Game Constructor @@ -21,11 +22,12 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Initialize event inheritance EventDispatcher.call(self); - var flipped, timer, counter, popup, $feedback, $wrapper, maxWidth, numCols; + var flipped, timer, counter, popup, $bottom, $feedback, $wrapper, maxWidth, numCols; var cards = []; var flipBacks = []; // Que of cards to be flipped back var numFlipped = 0; var removed = 0; + numInstances++; /** * Check if these two cards belongs together. @@ -49,17 +51,17 @@ H5P.MemoryGame = (function (EventDispatcher, $) { return; } - // Remove them from the game. - card.remove(); - mate.remove(); - // Update counters numFlipped -= 2; removed += 2; var isFinished = (removed === cards.length); - var desc = card.getDescription(); + // Remove them from the game. + card.remove(!isFinished); + mate.remove(); + + var desc = card.getDescription(); if (desc !== undefined) { // Pause timer and show desciption. timer.pause(); @@ -70,6 +72,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { popup.show(desc, imgs, cardStyles ? cardStyles.back : undefined, function () { if (isFinished) { // Game done + card.makeUntabbable(); finished(); } else { @@ -80,6 +83,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { } else if (isFinished) { // Game done + card.makeUntabbable(); finished(); } }; @@ -90,7 +94,8 @@ H5P.MemoryGame = (function (EventDispatcher, $) { */ var finished = function () { timer.stop(); - $feedback.addClass('h5p-show'); + $feedback.addClass('h5p-show'); // Announce + $bottom.focus(); // Create and trigger xAPI event 'completed' var completedEvent = self.createXAPIEventTemplate('completed'); @@ -113,7 +118,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { }); retryButton.classList.add('h5p-memory-transin'); setTimeout(function () { - // Remove class on nextTick to get transition effect + // Remove class on nextTick to get transition effectupd retryButton.classList.remove('h5p-memory-transin'); }, 0); @@ -132,9 +137,6 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Reset cards removed = 0; - for (var i = 0; i < cards.length; i++) { - cards[i].reset(); - } // Remove feedback $feedback[0].classList.remove('h5p-show'); @@ -151,11 +153,15 @@ H5P.MemoryGame = (function (EventDispatcher, $) { for (var i = 0; i < cards.length; i++) { cards[i].reAppend(); } + for (var j = 0; j < cards.length; j++) { + cards[j].reset(); + } // Scale new layout $wrapper.children('ul').children('.h5p-row-break').removeClass('h5p-row-break'); maxWidth = -1; self.trigger('resize'); + cards[0].setFocus(); }, 600); }; @@ -197,6 +203,11 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Keep track of the number of flipped cards numFlipped++; + // Announce the card unless it's the last one and it's correct + var isMatched = (flipped === mate); + var isLast = ((removed + 2) === cards.length); + card.updateLabel(isMatched, !(isMatched && isLast)); + if (flipped !== undefined) { var matie = flipped; // Reset the flipped card. @@ -239,7 +250,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { return; // No more cards } } - while (nextCard.isFlipped()); + while (nextCard.isRemoved()); card.makeUntabbable(); nextCard.setFocus(); @@ -342,24 +353,43 @@ H5P.MemoryGame = (function (EventDispatcher, $) { } // Add cards to list - var $list = $('
      '); + var $list = $('
        ', { + role: 'application', + 'aria-labelledby': 'h5p-intro-' + numInstances + }); for (var i = 0; i < cards.length; i++) { cards[i].appendTo($list); } cards[0].makeTabbable(); if ($list.children().length) { + $('
        ', { + id: 'h5p-intro-' + numInstances, + 'class': 'h5p-memory-hidden-read', + html: 'Memory Game. Find the matching cards.', // TODO: l10n + appendTo: $container + }); $list.appendTo($container); - $feedback = $('
        ' + parameters.l10n.feedback + '
        ').appendTo($container); + $bottom = $('
        ', { + tabindex: '-1', + appendTo: $container + }); + $('
        ', { + 'class': 'h5p-memory-hidden-read', + html: 'All of the cards have been found.', // TODO: l10n + appendTo: $bottom + }); + + $feedback = $('
        ' + parameters.l10n.feedback + '
        ').appendTo($bottom); // Add status bar var $status = $('
        ' + '
        ' + parameters.l10n.timeSpent + '
        ' + - '
        0:00
        ' + + '
        0:00
        ' + // TODO: Add hidden dot ? '
        ' + parameters.l10n.cardTurns + '
        ' + '
        0
        ' + - '
        ').appendTo($container); + '').appendTo($bottom); timer = new MemoryGame.Timer($status.find('.h5p-time-spent')[0]); counter = new MemoryGame.Counter($status.find('.h5p-card-turns')); From 4ecc636ab0803de42772a81d079bd9c63c0ad58b Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Mon, 25 Sep 2017 14:38:14 +0200 Subject: [PATCH 04/48] HFP-1266 Add accessibility support to dialog and timer Improved keyboard support. Made labels translatable. --- card.js | 22 +++++++++--- language/ar.json | 74 ++++++++++++++++++++++++++------------ language/bs.json | 63 +++++++++++++++++++++----------- language/de.json | 65 ++++++++++++++++++++++----------- language/fr.json | 65 ++++++++++++++++++++++----------- language/it.json | 74 ++++++++++++++++++++++++++------------ language/nb.json | 70 ++++++++++++++++++------------------ memory-game.css | 6 ++-- memory-game.js | 94 ++++++++++++++++++++++++++++++++++++++++-------- popup.js | 14 +++++--- semantics.json | 37 ++++++++++++++++++- timer.js | 5 +++ 12 files changed, 420 insertions(+), 169 deletions(-) diff --git a/card.js b/card.js index 38d1ffe..28718f7 100644 --- a/card.js +++ b/card.js @@ -8,10 +8,11 @@ * @param {Object} image * @param {number} id * @param {string} alt + * @param {Object} l10n Localization * @param {string} [description] * @param {Object} [styles] */ - MemoryGame.Card = function (image, id, alt, description, styles) { + MemoryGame.Card = function (image, id, alt, l10n, description, styles) { /** @alias H5P.MemoryGame.Card# */ var self = this; @@ -47,13 +48,13 @@ self.updateLabel = function (isMatched, announce, reset) { // Determine new label from input params - var label = (reset ? 'Unturned' : alt); + var label = (reset ? l10n.cardUnturned : alt); if (isMatched) { - label = 'Match found. ' + label; // TODO l10n + label = l10n.cardMatched + ' ' + label; } // Update the card's label - $wrapper.attr('aria-label', 'Card ' + ($wrapper.index() + 1) + ': ' + label); // TODO l10n + $wrapper.attr('aria-label', l10n.cardPrefix.replace('%num', $wrapper.index() + 1) + ' ' + label); // Update disabled property $wrapper.attr('aria-disabled', reset ? null : 'true'); @@ -155,9 +156,20 @@ self.trigger('prev'); event.preventDefault(); return; + case 35: + // Move to last card + self.trigger('last'); + event.preventDefault(); + return; + case 36: + // Move to first card + self.trigger('first'); + event.preventDefault(); + return; } }); - $wrapper.attr('aria-label', 'Card ' + ($wrapper.index() + 1) + ': Unturned.'); // TODO l10n + + $wrapper.attr('aria-label', l10n.cardPrefix.replace('%num', $wrapper.index() + 1) + ' ' + l10n.cardUnturned); $card = $wrapper.children('.h5p-memory-card') .children('.h5p-front') .click(function () { diff --git a/language/ar.json b/language/ar.json index 0f2a1fa..b1c7fd2 100644 --- a/language/ar.json +++ b/language/ar.json @@ -1,6 +1,11 @@ { "semantics": [ { + "widgets": [ + { + "label": "Default" + } + ], "label": "البطاقات", "entity": "بطاقة", "field": { @@ -10,53 +15,53 @@ "label": "الصورة" }, { - "englishLabel": "Matching Image", "label": "Matching Image", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "الوصف", "description": "نص قصير يتم عرضه مرة واحدة علي اثنين من البطاقات متساوية" + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Behavioural settings", - "englishDescription": "These options will let you control how the game behaves.", "description": "These options will let you control how the game behaves.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Position the cards in a square", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." }, { - "englishLabel": "Number of cards to use", "label": "Number of cards to use", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Add button for retrying when the game is over" } ] }, { - "englishLabel": "Look and feel", - "englishDescription": "Control the visuals of the game.", + "label": "Look and feel", + "description": "Control the visuals of the game.", "fields": [ { - "englishLabel": "Theme Color", - "englishDescription": "Choose a color to create a theme for your card game." + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" }, { - "englishLabel": "Card Back", - "englishDescription": "Use a custom back for your cards." + "label": "Card Back", + "description": "Use a custom back for your cards." } ] }, @@ -64,23 +69,46 @@ "label": "الأقلمة", "fields": [ { - "label": "نص تدوير البطاقة" + "label": "نص تدوير البطاقة", + "default": "Card turns" }, { - "label": "نص التوقيت الزمني" + "label": "نص التوقيت الزمني", + "default": "Time spent" }, { - "label": "نص الملاحظات" + "label": "نص الملاحظات", + "default": "Good work!" }, { - "englishLabel": "Try again button text", - "englishDefault": "Try again?" + "label": "Try again button text", + "default": "Reset" }, { - "englishLabel": "Close button label", - "englishDefault": "Close" + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/language/bs.json b/language/bs.json index c97e6ca..780bbed 100644 --- a/language/bs.json +++ b/language/bs.json @@ -1,6 +1,11 @@ { "semantics": [ { + "widgets": [ + { + "label": "Default" + } + ], "label": "Karte", "entity": "karte", "field": { @@ -10,53 +15,53 @@ "label": "Slika" }, { - "englishLabel": "Matching Image", "label": "Ista slika", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "Opcionalna slika koja se koristi umjestodvije iste slike." }, { "label": "Opis", "description": "Kratak tekst koji će biti prikazan čim se pronađu dvije iste karte." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Podešavanje ponašanja", - "englishDescription": "These options will let you control how the game behaves.", "description": "These options will let you control how the game behaves.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Poredaj karte u redove ", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." }, { - "englishLabel": "Number of cards to use", "label": "Broj karata za upotrebu", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Add button for retrying when the game is over" } ] }, { - "englishLabel": "Look and feel", - "englishDescription": "Control the visuals of the game.", + "label": "Look and feel", + "description": "Control the visuals of the game.", "fields": [ { - "englishLabel": "Theme Color", - "englishDescription": "Choose a color to create a theme for your card game." + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" }, { - "englishLabel": "Poleđina karata", - "englishDescription": "Koristi standardnu pozadinu za karte." + "label": "Card Back", + "description": "Use a custom back for your cards." } ] }, @@ -76,16 +81,34 @@ "default": "BRAVO!" }, { - "englishLabel": "Try again button text", "label": "Tekst na dugmetu pokušaj ponovo", - "englishDefault": "Try again?", "default": "Pokušaj ponovo?" }, { - "englishLabel": "Close button label", - "englishDefault": "Close" + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/language/de.json b/language/de.json index 9abf453..68deed0 100644 --- a/language/de.json +++ b/language/de.json @@ -1,6 +1,11 @@ { "semantics": [ { + "widgets": [ + { + "label": "Default" + } + ], "label": "Karten", "entity": "karte", "field": { @@ -10,53 +15,53 @@ "label": "Bild" }, { - "englishLabel": "Matching Image", "label": "Matching Image", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Beschreibung", "description": "Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Behavioural settings", - "englishDescription": "These options will let you control how the game behaves.", "description": "These options will let you control how the game behaves.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Position the cards in a square", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." }, { - "englishLabel": "Number of cards to use", "label": "Number of cards to use", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Add button for retrying when the game is over" } ] }, { - "englishLabel": "Look and feel", - "englishDescription": "Control the visuals of the game.", + "label": "Look and feel", + "description": "Control the visuals of the game.", "fields": [ { - "englishLabel": "Theme Color", - "englishDescription": "Choose a color to create a theme for your card game." + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" }, { - "englishLabel": "Card Back", - "englishDescription": "Use a custom back for your cards." + "label": "Card Back", + "description": "Use a custom back for your cards." } ] }, @@ -76,14 +81,34 @@ "default": "Gute Arbeit!" }, { - "englishLabel": "Try again button text", - "englishDefault": "Try again?" + "label": "Try again button text", + "default": "Reset" }, { - "englishLabel": "Close button label", - "englishDefault": "Close" + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/language/fr.json b/language/fr.json index 204a6d9..05771c5 100644 --- a/language/fr.json +++ b/language/fr.json @@ -1,6 +1,11 @@ { "semantics": [ { + "widgets": [ + { + "label": "Default" + } + ], "label": "Cartes", "entity": "carte", "field": { @@ -10,53 +15,53 @@ "label": "Image" }, { - "englishLabel": "Matching Image", "label": "Matching Image", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Description", "description": "Petit texte affiché quand deux cartes identiques sont trouvées." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Behavioural settings", - "englishDescription": "These options will let you control how the game behaves.", "description": "These options will let you control how the game behaves.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Position the cards in a square", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." }, { - "englishLabel": "Number of cards to use", "label": "Number of cards to use", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Add button for retrying when the game is over" } ] }, { - "englishLabel": "Look and feel", - "englishDescription": "Control the visuals of the game.", + "label": "Look and feel", + "description": "Control the visuals of the game.", "fields": [ { - "englishLabel": "Theme Color", - "englishDescription": "Choose a color to create a theme for your card game." + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" }, { - "englishLabel": "Card Back", - "englishDescription": "Use a custom back for your cards." + "label": "Card Back", + "description": "Use a custom back for your cards." } ] }, @@ -76,14 +81,34 @@ "default": "Bien joué !" }, { - "englishLabel": "Try again button text", - "englishDefault": "Try again?" + "label": "Try again button text", + "default": "Reset" }, { - "englishLabel": "Close button label", - "englishDefault": "Close" + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/language/it.json b/language/it.json index 1137a03..ccdb254 100644 --- a/language/it.json +++ b/language/it.json @@ -1,6 +1,11 @@ { "semantics": [ { + "widgets": [ + { + "label": "Default" + } + ], "label": "Carte", "entity": "carta", "field": { @@ -10,53 +15,53 @@ "label": "Immagine" }, { - "englishLabel": "Matching Image", "label": "Matching Image", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Descrizione", "description": "Breve testo visualizzato quando due carte uguali vengono trovate." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Behavioural settings", - "englishDescription": "These options will let you control how the game behaves.", "description": "These options will let you control how the game behaves.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Position the cards in a square", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." }, { - "englishLabel": "Number of cards to use", "label": "Number of cards to use", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Add button for retrying when the game is over" } ] }, { - "englishLabel": "Look and feel", - "englishDescription": "Control the visuals of the game.", + "label": "Look and feel", + "description": "Control the visuals of the game.", "fields": [ { - "englishLabel": "Theme Color", - "englishDescription": "Choose a color to create a theme for your card game." + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" }, { - "englishLabel": "Card Back", - "englishDescription": "Use a custom back for your cards." + "label": "Card Back", + "description": "Use a custom back for your cards." } ] }, @@ -64,23 +69,46 @@ "label": "Localizzazione", "fields": [ { - "label": "Testo Gira carta" + "label": "Testo Gira carta", + "default": "Card turns" }, { - "label": "Testo Tempo trascorso" + "label": "Testo Tempo trascorso", + "default": "Time spent" }, { - "label": "Testo Feedback" + "label": "Testo Feedback", + "default": "Good work!" }, { - "englishLabel": "Try again button text", - "englishDefault": "Try again?" + "label": "Try again button text", + "default": "Reset" }, { - "englishLabel": "Close button label", - "englishDefault": "Close" + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/language/nb.json b/language/nb.json index 53e6ccc..29e2a49 100644 --- a/language/nb.json +++ b/language/nb.json @@ -1,112 +1,114 @@ { "semantics": [ { - "englishLabel": "Cards", + "widgets": [ + { + "label": "Default" + } + ], "label": "Kort", - "englishEntity": "card", "entity": "kort", "field": { - "englishLabel": "Card", "label": "Kort", "fields": [ { - "englishLabel": "Image", "label": "Bilde" }, { - "englishLabel": "Matching Image", "label": "Tilhørende bilde", - "englishDescription": "An optional image to match against instead of using two cards with the same image.", "description": "Et valgfritt bilde som brukes av kort nummer to istedenfor å bruke to kort med samme bilde." }, { - "englishLabel": "Description", "label": "Beskrivelse", - "englishDescription": "An optional short text that will pop up once the two matching cards are found.", "description": "En valgfri kort tekst som spretter opp når kort-paret er funnet." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } }, { - "englishLabel": "Behavioural settings", "label": "Innstillinger for oppførsel", - "englishDescription": "These options will let you control how the game behaves.", "description": "Disse instillingene lar deg bestemme hvordan spillet skal oppføre seg.", "fields": [ { - "englishLabel": "Position the cards in a square", "label": "Plasser kortene i en firkant", - "englishDescription": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container.", "description": "Vil forsøk å samsvare antall kolonner og rader når kortene legges ut. Etterpå vil kortene bli skalert til å passe beholderen." }, { - "englishLabel": "Number of cards to use", "label": "Antall kort som skal brukes", - "englishDescription": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards.", "description": "Ved å sette antallet høyere enn 2 vil spillet plukke tilfeldige kort fra listen over kort." }, { - "englishLabel": "Add button for retrying when the game is over", "label": "Legg til knapp for å prøve på nytt når spillet er over" } ] }, { - "englishLabel": "Look and feel", "label": "Tilpass utseende", - "englishDescription": "Control the visuals of the game.", "description": "Kontroller de visuelle aspektene ved spillet.", "fields": [ { - "englishLabel": "Theme Color", "label": "Temafarge", - "englishDescription": "Choose a color to create a theme for your card game.", - "description": "Velg en farge for å skape et tema over kortspillet ditt." + "description": "Velg en farge for å skape et tema over kortspillet ditt.", + "default": "#909090" }, { - "englishLabel": "Card Back", "label": "Kortbaksiden", - "englishDescription": "Use a custom back for your cards.", "description": "Bruk en tilpasset kortbakside for kortene dine." } ] }, { - "englishLabel": "Localization", "label": "Oversettelser", "fields": [ { - "englishLabel": "Card turns text", "label": "Etikett for antall vendte kort", - "englishDefault": "Card turns", "default": "Kort vendt" }, { - "englishLabel": "Time spent text", "label": "Etikett for tid brukt", - "englishDefault": "Time spent", "default": "Tid brukt" }, { - "englishLabel": "Feedback text", "label": "Tilbakemeldingstekst", - "englishDefault": "Good work!", "default": "Godt jobbet!" }, { - "englishLabel": "Try again button text", "label": "Prøv på nytt-tekst", - "englishDefault": "Try again?", "default": "Prøv på nytt?" }, { - "englishLabel": "Close button label", "label": "Lukk knapp-merkelapp", - "englishDefault": "Close", "default": "Lukk" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." } ] } ] -} +} \ No newline at end of file diff --git a/memory-game.css b/memory-game.css index 4d61392..67e4b9a 100644 --- a/memory-game.css +++ b/memory-game.css @@ -194,9 +194,6 @@ margin: 0 1em 0 0; font-weight: bold; } -.h5p-memory-game .h5p-status > dt:after { - content: ":"; -} .h5p-memory-game .h5p-status > dd { margin: 0; } @@ -314,3 +311,6 @@ transform: translate(-50%,-450%) scale(0) rotate(360deg); opacity: 0; } +.h5p-memory-complete { + display: none; +} diff --git a/memory-game.js b/memory-game.js index a0cb033..7c61076 100644 --- a/memory-game.js +++ b/memory-game.js @@ -22,13 +22,29 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Initialize event inheritance EventDispatcher.call(self); - var flipped, timer, counter, popup, $bottom, $feedback, $wrapper, maxWidth, numCols; + var flipped, timer, counter, popup, $bottom, $taskComplete, $feedback, $wrapper, maxWidth, numCols; var cards = []; var flipBacks = []; // Que of cards to be flipped back var numFlipped = 0; var removed = 0; numInstances++; + // Add defaults + parameters = $.extend(true, { + l10n: { + cardTurns: 'Card turns', + timeSpent: 'Time spent', + feedback: 'Good work!', + tryAgain: 'Reset', + closeLabel: 'Close', + label: 'Memory Game. Find the matching cards.', + done: 'All of the cards have been found.', + cardPrefix: 'Card %num: ', + cardUnturned: 'Unturned.', + cardMatched: 'Match found.' + } + }, parameters); + /** * Check if these two cards belongs together. * @@ -69,7 +85,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { if (card.hasTwoImages) { imgs.push(mate.getImage()); } - popup.show(desc, imgs, cardStyles ? cardStyles.back : undefined, function () { + popup.show(desc, imgs, cardStyles ? cardStyles.back : undefined, function (refocus) { if (isFinished) { // Game done card.makeUntabbable(); @@ -78,6 +94,10 @@ H5P.MemoryGame = (function (EventDispatcher, $) { else { // Popup is closed, continue. timer.play(); + + if (refocus) { + card.setFocus(); + } } }); } @@ -94,6 +114,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { */ var finished = function () { timer.stop(); + $taskComplete.show(); $feedback.addClass('h5p-show'); // Announce $bottom.focus(); @@ -140,6 +161,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Remove feedback $feedback[0].classList.remove('h5p-show'); + $taskComplete.hide(); // Reset timer and counter timer.reset(); @@ -196,6 +218,14 @@ H5P.MemoryGame = (function (EventDispatcher, $) { */ var addCard = function (card, mate) { card.on('flip', function () { + + // Always return focus to the card last flipped + for (var i = 0; i < cards.length; i++) { + cards[i].makeUntabbable(); + } + card.makeTabbable(); + + popup.close(); self.triggerXAPI('interacted'); // Keep track of time spent timer.play(); @@ -232,8 +262,12 @@ H5P.MemoryGame = (function (EventDispatcher, $) { }); /** + * Create event handler for moving focus to the next or the previous + * card on the table. + * * @private - * @param {number} direction + * @param {number} direction +1/-1 + * @return {function} */ var createCardChangeFocusHandler = function (direction) { return function () { @@ -261,8 +295,38 @@ H5P.MemoryGame = (function (EventDispatcher, $) { }; }; + // Register handlers for moving focus to next and previous card card.on('next', createCardChangeFocusHandler(1)); card.on('prev', createCardChangeFocusHandler(-1)); + + /** + * Create event handler for moving focus to the first or the last card + * on the table. + * + * @private + * @param {number} direction +1/-1 + * @return {function} + */ + var createEndCardFocusHandler = function (direction) { + return function () { + var focusSet = false; + for (var i = 0; i < cards.length; i++) { + var j = (direction === -1 ? cards.length - (i + 1) : i); + if (!focusSet && !cards[j].isRemoved()) { + cards[j].setFocus(); + focusSet = true; + } + else if (cards[j] === card) { + card.makeUntabbable(); + } + } + }; + }; + + // Register handlers for moving focus to first and last card + card.on('first', createEndCardFocusHandler(1)); + card.on('last', createEndCardFocusHandler(-1)); + cards.push(card); }; @@ -320,16 +384,16 @@ H5P.MemoryGame = (function (EventDispatcher, $) { var cardParams = cardsToUse[i]; if (MemoryGame.Card.isValid(cardParams)) { // Create first card - var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, cardParams.description, cardStyles); + var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles); if (MemoryGame.Card.hasTwoImages(cardParams)) { // Use matching image for card two - cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.matchAlt, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.matchAlt, parameters.l10n, cardParams.description, cardStyles); cardOne.hasTwoImages = cardTwo.hasTwoImages = true; } else { // Add two cards with the same image - cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles); } // Add cards to card list for shuffeling @@ -366,7 +430,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { $('
        ', { id: 'h5p-intro-' + numInstances, 'class': 'h5p-memory-hidden-read', - html: 'Memory Game. Find the matching cards.', // TODO: l10n + html: parameters.l10n.label, appendTo: $container }); $list.appendTo($container); @@ -375,9 +439,9 @@ H5P.MemoryGame = (function (EventDispatcher, $) { tabindex: '-1', appendTo: $container }); - $('
        ', { - 'class': 'h5p-memory-hidden-read', - html: 'All of the cards have been found.', // TODO: l10n + $taskComplete = $('
        ', { + 'class': 'h5p-memory-complete h5p-memory-hidden-read', + html: parameters.l10n.done, appendTo: $bottom }); @@ -385,13 +449,13 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Add status bar var $status = $('
        ' + - '
        ' + parameters.l10n.timeSpent + '
        ' + - '
        0:00
        ' + // TODO: Add hidden dot ? - '
        ' + parameters.l10n.cardTurns + '
        ' + - '
        0
        ' + + '
        ' + parameters.l10n.timeSpent + ':
        ' + + '
        .
        ' + + '
        ' + parameters.l10n.cardTurns + ':
        ' + + '
        0.
        ' + '
        ').appendTo($bottom); - timer = new MemoryGame.Timer($status.find('.h5p-time-spent')[0]); + timer = new MemoryGame.Timer($status.find('time')[0]); counter = new MemoryGame.Counter($status.find('.h5p-card-turns')); popup = new MemoryGame.Popup($container, parameters.l10n); diff --git a/popup.js b/popup.js index 24b2b46..3f07631 100644 --- a/popup.js +++ b/popup.js @@ -13,16 +13,16 @@ var closed; - var $popup = $('
        ').appendTo($container); + var $popup = $('').appendTo($container); var $desc = $popup.find('.h5p-memory-desc'); var $top = $popup.find('.h5p-memory-top'); // Hook up the close button $popup.find('.h5p-memory-close').on('click', function () { - self.close(); + self.close(true); }).on('keypress', function (event) { if (event.which === 13 || event.which === 32) { - self.close(); + self.close(true); event.preventDefault(); } }); @@ -41,22 +41,26 @@ $('
        ').append(imgs[i]).appendTo($top); } $popup.show(); + $desc.focus(); closed = done; }; /** * Close the popup. + * + * @param {boolean} refocus Sets focus after closing the dialog */ - self.close = function () { + self.close = function (refocus) { if (closed !== undefined) { $popup.hide(); - closed(); + closed(refocus); closed = undefined; } }; /** * Sets popup size relative to the card size + * * @param {number} fontSize */ self.setSize = function (fontSize) { diff --git a/semantics.json b/semantics.json index 52a1f10..0333ce0 100644 --- a/semantics.json +++ b/semantics.json @@ -169,7 +169,42 @@ "name": "closeLabel", "type": "text", "default": "Close" + }, + { + "label": "Game label", + "importance": "low", + "name": "label", + "type": "text", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "importance": "low", + "name": "done", + "type": "text", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "importance": "low", + "name": "cardPrefix", + "type": "text", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "importance": "low", + "name": "cardUnturned", + "type": "text", + "default": "Unturned." + }, + { + "label": "Card matched label", + "importance": "low", + "name": "cardMatched", + "type": "text", + "default": "Match found." } ] } -] +] \ No newline at end of file diff --git a/timer.js b/timer.js index 339392e..4af4caf 100644 --- a/timer.js +++ b/timer.js @@ -28,6 +28,11 @@ var minutes = Timer.extractTimeElement(time, 'minutes'); var seconds = Timer.extractTimeElement(time, 'seconds') % 60; + + // Update duration attribute + element.setAttribute('datetime', 'PT' + minutes + 'M' + seconds + 'S'); + + // Add leading zero if (seconds < 10) { seconds = '0' + seconds; } From 6f62cf9da0c73e64dd0e8767c79e7d0a49e7067a Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Tue, 26 Sep 2017 11:48:45 +0200 Subject: [PATCH 05/48] Fix broken ar.json language file --- language/ar.json | 86 +++--------------------------------------------- 1 file changed, 5 insertions(+), 81 deletions(-) diff --git a/language/ar.json b/language/ar.json index 6399171..78a9852 100644 --- a/language/ar.json +++ b/language/ar.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -12,23 +11,10 @@ "field": { "label": "البطاقة", "fields": [ -======= - "widgets":[ - { - "label":"Default" - } - ], - "label":"البطاقات", - "entity":"بطاقة", - "field":{ - "label":"البطاقة", - "fields":[ ->>>>>>> master { - "label":"الصورة" + "label": "الصورة" }, { -<<<<<<< HEAD "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." }, @@ -43,20 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "label":"Matching Image", - "description":"An optional image to match against instead of using two cards with the same image." - }, - { - "label":"الوصف", - "description":"نص قصير يتم عرضه مرة واحدة علي اثنين من البطاقات متساوية" ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Behavioural settings", "description": "These options will let you control how the game behaves.", "fields": [ @@ -70,26 +47,10 @@ }, { "label": "Add button for retrying when the game is over" -======= - "label":"Behavioural settings", - "description":"These options will let you control how the game behaves.", - "fields":[ - { - "label":"Position the cards in a square", - "description":"Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." - }, - { - "label":"Number of cards to use", - "description":"Setting this to a number greater than 2 will make the game pick random cards from the list of cards." - }, - { - "label":"Add button for retrying when the game is over" ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Look and feel", "description": "Control the visuals of the game.", "fields": [ @@ -101,30 +62,13 @@ { "label": "Card Back", "description": "Use a custom back for your cards." -======= - "label":"Look and feel", - "description":"Control the visuals of the game.", - "fields":[ - { - "label":"Theme Color", - "description":"Choose a color to create a theme for your card game.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Card Back", - "description":"Use a custom back for your cards." ->>>>>>> master } ] }, { - "label":"الأقلمة", - "fields":[ + "label": "الأقلمة", + "fields": [ { -<<<<<<< HEAD "label": "نص تدوير البطاقة", "default": "Card turns" }, @@ -163,28 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"نص تدوير البطاقة", - "default":"Card turns" - }, - { - "label":"نص التوقيت الزمني", - "default":"Time spent" - }, - { - "label":"نص الملاحظات", - "default":"Good work!" - }, - { - "label":"Try again button text", - "default":"Try again?" - }, - { - "label":"Close button label", - "default":"Close" ->>>>>>> master } ] } ] -} \ No newline at end of file +} From 46d769ef0ba21caf0f6aaf318ed8e6d2e9d0148c Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Tue, 26 Sep 2017 11:54:34 +0200 Subject: [PATCH 06/48] Fix broken translations --- language/bs.json | 86 +++++++----------------------------------------- language/de.json | 86 +++++++----------------------------------------- language/fr.json | 86 +++++++----------------------------------------- language/it.json | 86 +++--------------------------------------------- language/nb.json | 84 ++-------------------------------------------- 5 files changed, 40 insertions(+), 388 deletions(-) diff --git a/language/bs.json b/language/bs.json index 047f2cd..125eae6 100644 --- a/language/bs.json +++ b/language/bs.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -12,23 +11,10 @@ "field": { "label": "Karte", "fields": [ -======= - "widgets":[ - { - "label":"Default" - } - ], - "label":"Karte", - "entity":"karte", - "field":{ - "label":"Karte", - "fields":[ ->>>>>>> master { - "label":"Slika" + "label": "Slika" }, { -<<<<<<< HEAD "label": "Ista slika", "description": "Opcionalna slika koja se koristi umjestodvije iste slike." }, @@ -43,20 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "label":"Ista slika", - "description":"Opcionalna slika koja se koristi umjestodvije iste slike." - }, - { - "label":"Opis", - "description":"Kratak tekst koji će biti prikazan čim se pronađu dvije iste karte." ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Podešavanje ponašanja", "description": "These options will let you control how the game behaves.", "fields": [ @@ -70,26 +47,10 @@ }, { "label": "Add button for retrying when the game is over" -======= - "label":"Podešavanje ponašanja", - "description":"These options will let you control how the game behaves.", - "fields":[ - { - "label":"Poredaj karte u redove ", - "description":"Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." - }, - { - "label":"Broj karata za upotrebu", - "description":"Setting this to a number greater than 2 will make the game pick random cards from the list of cards." - }, - { - "label":"Add button for retrying when the game is over" ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Look and feel", "description": "Control the visuals of the game.", "fields": [ @@ -101,42 +62,25 @@ { "label": "Card Back", "description": "Use a custom back for your cards." -======= - "label":"Look and feel", - "description":"Control the visuals of the game.", - "fields":[ - { - "label":"Theme Color", - "description":"Choose a color to create a theme for your card game.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Card Back", - "description":"Use a custom back for your cards." ->>>>>>> master } ] }, { - "label":"Prijevod", - "fields":[ + "label": "Prijevod", + "fields": [ { - "label":"Tekst kad se okrene karta ", - "default":"Okrenuta karta" + "label": "Tekst kad se okrene karta ", + "default": "Okrenuta karta" }, { - "label":"Tekst za provedeno vrijeme", - "default":"Provedeno vrijeme" + "label": "Tekst za provedeno vrijeme", + "default": "Provedeno vrijeme" }, { - "label":"Feedback tekst", - "default":"BRAVO!" + "label": "Feedback tekst", + "default": "BRAVO!" }, { -<<<<<<< HEAD "label": "Tekst na dugmetu pokušaj ponovo", "default": "Pokušaj ponovo?" }, @@ -163,16 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"Tekst na dugmetu pokušaj ponovo", - "default":"Pokušaj ponovo?" - }, - { - "label":"Close button label", - "default":"Close" ->>>>>>> master } ] } ] -} \ No newline at end of file +} diff --git a/language/de.json b/language/de.json index 3c3d210..550d6b0 100644 --- a/language/de.json +++ b/language/de.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -12,23 +11,10 @@ "field": { "label": "Karte", "fields": [ -======= - "widgets":[ - { - "label":"Vorgaben" - } - ], - "label":"Karten", - "entity":"karte", - "field":{ - "label":"Karte", - "fields":[ ->>>>>>> master { - "label":"Bild" + "label": "Bild" }, { -<<<<<<< HEAD "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." }, @@ -43,20 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "label":"Passendes Bild", - "description":"Ein optionales anderes Bild als Gegenstück statt zwei Karten mit dem selben Bild zu nutzen" - }, - { - "label":"Beschreibung", - "description":"Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Behavioural settings", "description": "These options will let you control how the game behaves.", "fields": [ @@ -70,26 +47,10 @@ }, { "label": "Add button for retrying when the game is over" -======= - "label":"Interaktionseinstellungen", - "description":"Mit diesen Einstellungen kannst du das Verhalten des Spiels anpassen.", - "fields":[ - { - "label":"Positioniere die Karten in einem Quadrat.", - "description":"Es wird versucht, die Anzahl der Zeilen und Spalten passend zu den Karten einzustellen. Danach werden die Karten passend skaliert." - }, - { - "label":"Anzahl der zu nutzenden Karten", - "description":"Wird hier eine Zahl größer als 2 eingestellt, werden zufällig Karten aus der Kartenliste gezogen." - }, - { - "label":"Füge einen Button hinzu, um das Spiel noch einmal neu zu starten zu können, wenn es vorbei ist." ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Look and feel", "description": "Control the visuals of the game.", "fields": [ @@ -101,42 +62,25 @@ { "label": "Card Back", "description": "Use a custom back for your cards." -======= - "label":"Design-Aspekte", - "description":"Beeinflusse die Optik des Spiels", - "fields":[ - { - "label":"Themenfarbe", - "description":"Wähle eine Farbe, um ein Theme für deine Karten zu erstellen.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Kartenrückseite", - "description":"Nutze eine individuelle Rückseite für deine Karten." ->>>>>>> master } ] }, { - "label":"Übersetzung", - "fields":[ + "label": "Übersetzung", + "fields": [ { - "label":"Text für die Anzahl der Züge", - "default":"Züge" + "label": "Text für die Anzahl der Züge", + "default": "Züge" }, { - "label":"Text für die benötigte Zeit", - "default":"Benötigte Zeit" + "label": "Text für die benötigte Zeit", + "default": "Benötigte Zeit" }, { - "label":"Text als Rückmeldung", - "default":"Gute Arbeit!" + "label": "Text als Rückmeldung", + "default": "Gute Arbeit!" }, { -<<<<<<< HEAD "label": "Try again button text", "default": "Reset" }, @@ -163,16 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"Text des Wiederholen-Buttons", - "default":"Erneut versuchen?" - }, - { - "label":"Beschriftung des \"Abbrechen\"-Buttons", - "default":"Schließen" ->>>>>>> master } ] } ] -} \ No newline at end of file +} diff --git a/language/fr.json b/language/fr.json index 9b93588..32ca798 100644 --- a/language/fr.json +++ b/language/fr.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -12,23 +11,10 @@ "field": { "label": "Carte", "fields": [ -======= - "widgets":[ - { - "label":"Default" - } - ], - "label":"Cartes", - "entity":"carte", - "field":{ - "label":"Carte", - "fields":[ ->>>>>>> master { - "label":"Image" + "label": "Image" }, { -<<<<<<< HEAD "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." }, @@ -43,20 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "label":"Matching Image", - "description":"An optional image to match against instead of using two cards with the same image." - }, - { - "label":"Description", - "description":"Petit texte affiché quand deux cartes identiques sont trouvées." ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Behavioural settings", "description": "These options will let you control how the game behaves.", "fields": [ @@ -70,26 +47,10 @@ }, { "label": "Add button for retrying when the game is over" -======= - "label":"Behavioural settings", - "description":"These options will let you control how the game behaves.", - "fields":[ - { - "label":"Position the cards in a square", - "description":"Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." - }, - { - "label":"Number of cards to use", - "description":"Setting this to a number greater than 2 will make the game pick random cards from the list of cards." - }, - { - "label":"Add button for retrying when the game is over" ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Look and feel", "description": "Control the visuals of the game.", "fields": [ @@ -101,42 +62,25 @@ { "label": "Card Back", "description": "Use a custom back for your cards." -======= - "label":"Look and feel", - "description":"Control the visuals of the game.", - "fields":[ - { - "label":"Theme Color", - "description":"Choose a color to create a theme for your card game.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Card Back", - "description":"Use a custom back for your cards." ->>>>>>> master } ] }, { - "label":"Interface", - "fields":[ + "label": "Interface", + "fields": [ { - "label":"Texte pour le nombre de cartes retournées", - "default":"Cartes retournées :" + "label": "Texte pour le nombre de cartes retournées", + "default": "Cartes retournées :" }, { - "label":"Texte pour le temps passé", - "default":"Temps écoulé :" + "label": "Texte pour le temps passé", + "default": "Temps écoulé :" }, { - "label":"Texte de l'appréciation finale", - "default":"Bien joué !" + "label": "Texte de l'appréciation finale", + "default": "Bien joué !" }, { -<<<<<<< HEAD "label": "Try again button text", "default": "Reset" }, @@ -163,16 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"Try again button text", - "default":"Try again?" - }, - { - "label":"Close button label", - "default":"Close" ->>>>>>> master } ] } ] -} \ No newline at end of file +} diff --git a/language/it.json b/language/it.json index b8b9fec..6a2e4c3 100644 --- a/language/it.json +++ b/language/it.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -12,23 +11,10 @@ "field": { "label": "Carta", "fields": [ -======= - "widgets":[ - { - "label":"Default" - } - ], - "label":"Carte", - "entity":"carta", - "field":{ - "label":"Carta", - "fields":[ ->>>>>>> master { - "label":"Immagine" + "label": "Immagine" }, { -<<<<<<< HEAD "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." }, @@ -43,20 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "label":"Matching Image", - "description":"An optional image to match against instead of using two cards with the same image." - }, - { - "label":"Descrizione", - "description":"Breve testo visualizzato quando due carte uguali vengono trovate." ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Behavioural settings", "description": "These options will let you control how the game behaves.", "fields": [ @@ -70,26 +47,10 @@ }, { "label": "Add button for retrying when the game is over" -======= - "label":"Behavioural settings", - "description":"These options will let you control how the game behaves.", - "fields":[ - { - "label":"Position the cards in a square", - "description":"Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." - }, - { - "label":"Number of cards to use", - "description":"Setting this to a number greater than 2 will make the game pick random cards from the list of cards." - }, - { - "label":"Add button for retrying when the game is over" ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Look and feel", "description": "Control the visuals of the game.", "fields": [ @@ -101,30 +62,13 @@ { "label": "Card Back", "description": "Use a custom back for your cards." -======= - "label":"Look and feel", - "description":"Control the visuals of the game.", - "fields":[ - { - "label":"Theme Color", - "description":"Choose a color to create a theme for your card game.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Card Back", - "description":"Use a custom back for your cards." ->>>>>>> master } ] }, { - "label":"Localizzazione", - "fields":[ + "label": "Localizzazione", + "fields": [ { -<<<<<<< HEAD "label": "Testo Gira carta", "default": "Card turns" }, @@ -163,28 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"Testo Gira carta", - "default":"Card turns" - }, - { - "label":"Testo Tempo trascorso", - "default":"Time spent" - }, - { - "label":"Testo Feedback", - "default":"Good work!" - }, - { - "label":"Try again button text", - "default":"Try again?" - }, - { - "label":"Close button label", - "default":"Close" ->>>>>>> master } ] } ] -} \ No newline at end of file +} diff --git a/language/nb.json b/language/nb.json index ce5abb5..21218d7 100644 --- a/language/nb.json +++ b/language/nb.json @@ -1,7 +1,6 @@ { - "semantics":[ + "semantics": [ { -<<<<<<< HEAD "widgets": [ { "label": "Default" @@ -30,34 +29,11 @@ { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." -======= - "widgets":[ - { - "label":"Default" - } - ], - "label":"Kort", - "entity":"kort", - "field":{ - "label":"Kort", - "fields":[ - { - "label":"Bilde" - }, - { - "label":"Tilhørende bilde", - "description":"Et valgfritt bilde som brukes av kort nummer to istedenfor å bruke to kort med samme bilde." - }, - { - "label":"Beskrivelse", - "description":"En valgfri kort tekst som spretter opp når kort-paret er funnet." ->>>>>>> master } ] } }, { -<<<<<<< HEAD "label": "Innstillinger for oppførsel", "description": "Disse instillingene lar deg bestemme hvordan spillet skal oppføre seg.", "fields": [ @@ -71,26 +47,10 @@ }, { "label": "Legg til knapp for å prøve på nytt når spillet er over" -======= - "label":"Innstillinger for oppførsel", - "description":"Disse instillingene lar deg bestemme hvordan spillet skal oppføre seg.", - "fields":[ - { - "label":"Plasser kortene i en firkant", - "description":"Vil forsøk å samsvare antall kolonner og rader når kortene legges ut. Etterpå vil kortene bli skalert til å passe beholderen." - }, - { - "label":"Antall kort som skal brukes", - "description":"Ved å sette antallet høyere enn 2 vil spillet plukke tilfeldige kort fra listen over kort." - }, - { - "label":"Legg til knapp for å prøve på nytt når spillet er over" ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Tilpass utseende", "description": "Kontroller de visuelle aspektene ved spillet.", "fields": [ @@ -102,27 +62,10 @@ { "label": "Kortbaksiden", "description": "Bruk en tilpasset kortbakside for kortene dine." -======= - "label":"Tilpass utseende", - "description":"Kontroller de visuelle aspektene ved spillet.", - "fields":[ - { - "label":"Temafarge", - "description":"Velg en farge for å skape et tema over kortspillet ditt.", - "default":"#909090", - "spectrum":{ - - } - }, - { - "label":"Kortbaksiden", - "description":"Bruk en tilpasset kortbakside for kortene dine." ->>>>>>> master } ] }, { -<<<<<<< HEAD "label": "Oversettelser", "fields": [ { @@ -164,31 +107,8 @@ { "label": "Card matched label", "default": "Match found." -======= - "label":"Oversettelser", - "fields":[ - { - "label":"Etikett for antall vendte kort", - "default":"Kort vendt" - }, - { - "label":"Etikett for tid brukt", - "default":"Tid brukt" - }, - { - "label":"Tilbakemeldingstekst", - "default":"Godt jobbet!" - }, - { - "label":"Prøv på nytt-tekst", - "default":"Prøv på nytt?" - }, - { - "label":"Lukk knapp-merkelapp", - "default":"Lukk" ->>>>>>> master } ] } ] -} \ No newline at end of file +} From 33a73712c04498885a031bad617f5e5e4e23c85a Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Tue, 26 Sep 2017 16:34:53 +0200 Subject: [PATCH 07/48] Bump --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 2437820..312f73f 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 5, + "patchVersion": 6, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} \ No newline at end of file +} From bff82ed8c207da0453d8bec1223133b36c04794d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Janne=20S=C3=A4rkel=C3=A4?= Date: Fri, 29 Sep 2017 14:40:41 +0300 Subject: [PATCH 08/48] Checked translations (#30) --- language/fi.json | 111 ++++++++++++++++++++++------------------------- 1 file changed, 53 insertions(+), 58 deletions(-) diff --git a/language/fi.json b/language/fi.json index 7101e4c..14232b6 100644 --- a/language/fi.json +++ b/language/fi.json @@ -3,112 +3,107 @@ { "widgets": [ { - "label": "Default" + "label":"Oletus" } ], - "label": "Cards", - "entity": "card", - "field": { - "label": "Card", - "fields": [ + "label":"Kortit", + "entity":"kortti", + "field":{ + "label":"Kortti", + "fields":[ { - "label": "Image" + "label":"Kuva" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label":"Vastattava kuva", + "description":"Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." - }, - { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." - }, - { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label":"Selite", + "description":"Valinnainen lyhyt teksti, joka näytetään kun oikea pari on löydetty." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", - "fields": [ + "label":"Yleisasetukset", + "description":"Näillä valinnoilla voit muokata pelin asetuksia.", + "fields":[ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label":"Aseta kortit säännöllisesti", + "description":"Yrittää sovittaa kortit ruudukkomuotoon rivien sijaan." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label":"Korttien lukumäärä", + "description":"Kun lukumäärä on suurempi kuin kaksi, annettu määrä kortteja arvotaan kaikista korteista pelattavaksi." }, { - "label": "Add button for retrying when the game is over" + "label":"Salli Yritä uudelleen -painike pelin päätyttyä" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", - "fields": [ + "label":"Ulkoasu", + "description":"Hallinnoi pelin ulkoasua.", + "fields":[ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", - "default": "#909090" + "label":"Väriteema", + "description":"Valitse väri luodaksesi teeman pelille.", + "default":"#909090", + "spectrum":{ + + } }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label":"Kortin kääntöpuoli", + "description":"Mukauta korttien kääntöpuoli." } ] }, { - "label": "Localization", - "fields": [ + "label":"Tekstit", + "fields":[ { - "label": "Card turns text", - "default": "Card turns" + "label":"Kortteja käännetty", + "default":"Kortteja käännetty" }, { - "label": "Time spent text", - "default": "Time spent" + "label":"Aikaa kulunut", + "default":"Aikaa kulunut" }, { - "label": "Feedback text", - "default": "Good work!" + "label":"Palaute", + "default":"Hyvää työtä!" }, { - "label": "Try again button text", - "default": "Try again?" + "label":"Painikkeen Yritä uudelleen teksti", + "default":"Yritä uudelleen?" }, { - "label": "Close button label", - "default": "Close" + "label":"Painikkeen Sulje teksti", + "default":"Sulje" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Pelin kuvaus", + "default": "Muistipeli. Löydä parit." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Peli päättynyt", + "default": "Kaikki parit löydetty." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Kortin yksilöllinen järjestysnumero", + "default": "Kortti %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Kääntämätön", + "default": "Kääntämätön." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Pari löytynyt", + "default": "Pari löydetty." } ] } ] -} \ No newline at end of file +} From 9b473b035b149621895494e404206aba822b2674 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Fri, 29 Sep 2017 16:57:04 +0200 Subject: [PATCH 09/48] Bumping before release on staging --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 312f73f..9d0949b 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 6, + "patchVersion": 7, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} +} \ No newline at end of file From 000cb99912e22aa6cf99cd7a8feb55331d33ca03 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Tue, 17 Oct 2017 16:16:46 +0200 Subject: [PATCH 10/48] Make eslint happy --- card.js | 6 +++--- memory-game.js | 12 ++++++------ popup.js | 2 +- upgrades.js | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/card.js b/card.js index 28718f7..867d405 100644 --- a/card.js +++ b/card.js @@ -20,7 +20,7 @@ EventDispatcher.call(self); var path = H5P.getPath(image.path, id); - var width, height, margin, $card, $wrapper, removedState, flippedState; + var width, height, $card, $wrapper, removedState, flippedState; alt = alt || 'Missing description'; // Default for old games @@ -91,7 +91,7 @@ /** * Remove. */ - self.remove = function (announce) { + self.remove = function () { $card.addClass('h5p-matched'); removedState = true; }; @@ -137,7 +137,7 @@ '
        ' + '
        ') .appendTo($container) - .on('keydown', function (event) { + .on('keydown', function (event) { switch (event.which) { case 13: // Enter case 32: // Space diff --git a/memory-game.js b/memory-game.js index 7c61076..1557e18 100644 --- a/memory-game.js +++ b/memory-game.js @@ -154,7 +154,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { * Shuffle the cards and restart the game! * @private */ - var resetGame = function () { + var resetGame = function () { // Reset cards removed = 0; @@ -197,7 +197,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { buttonElement.innerHTML = label; buttonElement.setAttribute('role', 'button'); buttonElement.tabIndex = 0; - buttonElement.addEventListener('click', function (event) { + buttonElement.addEventListener('click', function () { action.apply(buttonElement); }, false); buttonElement.addEventListener('keypress', function (event) { @@ -437,7 +437,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { $bottom = $('
        ', { tabindex: '-1', - appendTo: $container + appendTo: $container }); $taskComplete = $('
        ', { 'class': 'h5p-memory-complete h5p-memory-hidden-read', @@ -467,10 +467,10 @@ H5P.MemoryGame = (function (EventDispatcher, $) { /** * Will try to scale the game so that it fits within its container. - * Puts the cards into a grid layout to make it as square as possible –  + * Puts the cards into a grid layout to make it as square as possible – * which improves the playability on multiple devices. * - * @private + * @private */ var scaleGameSize = function () { @@ -538,7 +538,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { /** * Determine color contrast level compared to white(#fff) * - * @private + * @private * @param {string} color hex code * @return {number} From 1 to Infinity. */ diff --git a/popup.js b/popup.js index 3f07631..07c3f64 100644 --- a/popup.js +++ b/popup.js @@ -18,7 +18,7 @@ var $top = $popup.find('.h5p-memory-top'); // Hook up the close button - $popup.find('.h5p-memory-close').on('click', function () { + $popup.find('.h5p-memory-close').on('click', function () { self.close(true); }).on('keypress', function (event) { if (event.which === 13 || event.which === 32) { diff --git a/upgrades.js b/upgrades.js index 42c39bd..ce870bc 100644 --- a/upgrades.js +++ b/upgrades.js @@ -1,6 +1,6 @@ var H5PUpgrades = H5PUpgrades || {}; -H5PUpgrades['H5P.MemoryGame'] = (function ($) { +H5PUpgrades['H5P.MemoryGame'] = (function () { return { 1: { /** @@ -42,4 +42,4 @@ H5PUpgrades['H5P.MemoryGame'] = (function ($) { } } }; -})(H5P.jQuery); +})(); From 375328cb2c64ceaf83454326d7c52158a3bdfbc9 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Tue, 24 Oct 2017 14:50:11 +0200 Subject: [PATCH 11/48] Bump patch version --- library.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library.json b/library.json index 9d0949b..64a27f7 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 7, + "patchVersion": 8, "runnable": 1, "author": "Joubel", "license": "MIT", From cf3dfe10ec09af705518f4d553246527a68175c4 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Thu, 2 Nov 2017 10:19:03 +0100 Subject: [PATCH 12/48] Remove focus outline on non-tabable elements --- memory-game.css | 7 +++++-- memory-game.js | 1 + popup.js | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/memory-game.css b/memory-game.css index cdb63cd..c188210 100644 --- a/memory-game.css +++ b/memory-game.css @@ -272,7 +272,7 @@ color: #666; } .h5p-memory-game .h5p-memory-close:focus { - outline: 2px dashed pink; + outline: 2px solid #a5c7fe; } .h5p-memory-reset { position: absolute; @@ -302,7 +302,7 @@ margin-top: -0.2em; } .h5p-memory-reset:focus { - outline: 2px dashed pink; + outline: 2px solid #a5c7fe; } .h5p-memory-transin { transform: translate(-50%,-50%) scale(0) rotate(180deg); @@ -315,3 +315,6 @@ .h5p-memory-complete { display: none; } +.h5p-memory-game .h5p-programatically-focusable { + outline: none; +} diff --git a/memory-game.js b/memory-game.js index 1557e18..38829de 100644 --- a/memory-game.js +++ b/memory-game.js @@ -436,6 +436,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { $list.appendTo($container); $bottom = $('
        ', { + 'class': 'h5p-programatically-focusable', tabindex: '-1', appendTo: $container }); diff --git a/popup.js b/popup.js index 07c3f64..9d8d63d 100644 --- a/popup.js +++ b/popup.js @@ -13,7 +13,7 @@ var closed; - var $popup = $('').appendTo($container); + var $popup = $('').appendTo($container); var $desc = $popup.find('.h5p-memory-desc'); var $top = $popup.find('.h5p-memory-top'); From 69de120fef2b4d9825e1c82f45f36c93552caa46 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Thu, 2 Nov 2017 17:18:23 +0100 Subject: [PATCH 13/48] Bump --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 64a27f7..a85da9b 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 8, + "patchVersion": 9, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} \ No newline at end of file +} From f25ab323e5754e8831bf8d0a6260fcd226c3f421 Mon Sep 17 00:00:00 2001 From: "C.W. Fann" Date: Fri, 8 Dec 2017 13:51:11 +0800 Subject: [PATCH 14/48] New Traditional Chinese translation --- language/zh-tw.json | 114 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 language/zh-tw.json diff --git a/language/zh-tw.json b/language/zh-tw.json new file mode 100644 index 0000000..5ea612b --- /dev/null +++ b/language/zh-tw.json @@ -0,0 +1,114 @@ +{ + "semantics": [ + { + "widgets": [ + { + "label": "Default" + } + ], + "label": "Cards", + "entity": "card", + "field": { + "label": "Card", + "fields": [ + { + "label": "Image" + }, + { + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." + } + ] + } + }, + { + "label": "Behavioural settings", + "description": "These options will let you control how the game behaves.", + "fields": [ + { + "label": "Position the cards in a square", + "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + }, + { + "label": "Number of cards to use", + "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + }, + { + "label": "Add button for retrying when the game is over" + } + ] + }, + { + "label": "Look and feel", + "description": "Control the visuals of the game.", + "fields": [ + { + "label": "Theme Color", + "description": "Choose a color to create a theme for your card game.", + "default": "#909090" + }, + { + "label": "Card Back", + "description": "Use a custom back for your cards." + } + ] + }, + { + "label": "Localization", + "fields": [ + { + "label": "Card turns text", + "default": "Card turns" + }, + { + "label": "Time spent text", + "default": "Time spent" + }, + { + "label": "Feedback text", + "default": "Good work!" + }, + { + "label": "Try again button text", + "default": "Try again?" + }, + { + "label": "Close button label", + "default": "Close" + }, + { + "label": "Game label", + "default": "Memory Game. Find the matching cards." + }, + { + "label": "Game finished label", + "default": "All of the cards have been found." + }, + { + "label": "Card indexing label", + "default": "Card %num:" + }, + { + "label": "Card unturned label", + "default": "Unturned." + }, + { + "label": "Card matched label", + "default": "Match found." + } + ] + } + ] +} From dc100143bc0ec7652e02b023928d8705026ee4cb Mon Sep 17 00:00:00 2001 From: "C.W. Fann" Date: Fri, 8 Dec 2017 20:20:15 +0800 Subject: [PATCH 15/48] Update zh-tw.json --- language/zh-tw.json | 94 ++++++++++++++++++++++----------------------- 1 file changed, 47 insertions(+), 47 deletions(-) diff --git a/language/zh-tw.json b/language/zh-tw.json index 5ea612b..580e0cf 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -3,110 +3,110 @@ { "widgets": [ { - "label": "Default" + "label": "預設" } ], - "label": "Cards", - "entity": "card", + "label": "紙牌", + "entity": "紙牌", "field": { - "label": "Card", + "label": "紙牌", "fields": [ { - "label": "Image" + "label": "圖片" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "相符合的圖片", + "description": "一個可選擇的符合圖片, 而不是使用兩張相同的圖片紙牌." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "描述", + "description": "一旦找到兩張符合的紙牌, 就會彈出一個可選擇的短文字." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "符合圖片的替代文字", + "description": "描述在照片中可以看到什麼. 文字是由視障者所需的文字轉語音工具讀取的." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "描述", + "description": "一旦找到兩張符合的紙牌, 就會彈出一個可選擇的短文字." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "行為設定", + "description": "這些選項可以讓你控制遊戲的行為.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "把紙牌放在正方形中", + "description": "在佈置紙牌時, 將嘗試匹配列數和行數. 之後, 紙牌將被縮放以適合容器大小." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "要使用的紙牌數量", + "description": "將其設置為大於2的數字將使遊戲從紙牌列表中選擇隨機卡片." }, { - "label": "Add button for retrying when the game is over" + "label": "新增遊戲結束時的重試按鈕" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "外觀和感覺", + "description": "控制遊戲的視覺效果.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "主題顏色", + "description": "選擇一種顏色來為你的紙牌遊戲創建一個主題.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "紙牌返回", + "description": "為您的紙牌使用自定義返回." } ] }, { - "label": "Localization", + "label": "本地化", "fields": [ { - "label": "Card turns text", - "default": "Card turns" + "label": "紙牌轉文字", + "default": "紙牌輪流" }, { - "label": "Time spent text", - "default": "Time spent" + "label": "花費時間的文字", + "default": "花費時間" }, { - "label": "Feedback text", - "default": "Good work!" + "label": "反饋文字", + "default": "做得好!" }, { - "label": "Try again button text", - "default": "Try again?" + "label": "再試一次按鈕文字", + "default": "再試一次?" }, { - "label": "Close button label", - "default": "Close" + "label": "關閉按鈕標籤", + "default": "關閉" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "遊戲標籤", + "default": "記憶遊戲. 找到匹配的卡片." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "遊戲結束標籤", + "default": "所有的紙牌都被找到了." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "紙牌索引標籤", + "default": "紙牌 %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "未翻出的紙牌標籤", + "default": "紙牌." }, { - "label": "Card matched label", - "default": "Match found." + "label": "紙牌符合的標籤", + "default": "找到符合的." } ] } From dc2a869a3bbf6f8406ab967b6401990cf5035d8b Mon Sep 17 00:00:00 2001 From: "C.W. Fann" Date: Sun, 10 Dec 2017 22:05:30 +0800 Subject: [PATCH 16/48] Update zh-tw.json --- language/zh-tw.json | 76 ++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/language/zh-tw.json b/language/zh-tw.json index 580e0cf..06691de 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -6,29 +6,29 @@ "label": "預設" } ], - "label": "紙牌", - "entity": "紙牌", + "label": "記憶牌", + "entity": "記憶牌", "field": { - "label": "紙牌", + "label": "記憶牌", "fields": [ { - "label": "圖片" + "label": "圖示" }, { - "label": "相符合的圖片", - "description": "一個可選擇的符合圖片, 而不是使用兩張相同的圖片紙牌." + "label": "相稱圖示", + "description": "可選用一張與主圖示相稱的圖示,並非使用兩張相同的圖示." }, { "label": "描述", - "description": "一旦找到兩張符合的紙牌, 就會彈出一個可選擇的短文字." + "description": "選填。當找到兩張相稱圖示時所顯示的文字." }, { - "label": "符合圖片的替代文字", - "description": "描述在照片中可以看到什麼. 文字是由視障者所需的文字轉語音工具讀取的." + "label": "相稱圖示的替代文字", + "description": "請描述此張圖示中可以看到什麼. 此段文字將做為閱讀器導讀文字,對視障使用者更為友善." }, { "label": "描述", - "description": "一旦找到兩張符合的紙牌, 就會彈出一個可選擇的短文字." + "description": "選填。當找到兩張相稱圖示時所顯示的文字." } ] } @@ -38,75 +38,75 @@ "description": "這些選項可以讓你控制遊戲的行為.", "fields": [ { - "label": "把紙牌放在正方形中", - "description": "在佈置紙牌時, 將嘗試匹配列數和行數. 之後, 紙牌將被縮放以適合容器大小." + "label": "把記憶牌顯示於正方形中", + "description": "當設定多組記憶牌時,將依組數平均分配顯示行列數及顯示大小." }, { - "label": "要使用的紙牌數量", - "description": "將其設置為大於2的數字將使遊戲從紙牌列表中選擇隨機卡片." + "label": "使用的記憶牌組數量", + "description": "當設定多組記憶牌時,將依組數平均分配顯示行列數及顯示大小." }, { - "label": "新增遊戲結束時的重試按鈕" + "label": "遊戲結束後顯示重試功能鈕" } ] }, { - "label": "外觀和感覺", + "label": "外觀視覺", "description": "控制遊戲的視覺效果.", "fields": [ { "label": "主題顏色", - "description": "選擇一種顏色來為你的紙牌遊戲創建一個主題.", + "description": "為您的翻轉記憶牌遊戲設定一種顏色主題.", "default": "#909090" }, { - "label": "紙牌返回", - "description": "為您的紙牌使用自定義返回." + "label": "記憶牌背面圖示", + "description": "為您的卡片背面設定圖示." } ] }, { - "label": "本地化", + "label": "在地化", "fields": [ { - "label": "紙牌轉文字", - "default": "紙牌輪流" + "label": "翻轉記憶牌功能鈕名稱", + "default": "翻轉記憶牌" }, { - "label": "花費時間的文字", - "default": "花費時間" + "label": "花費時間", + "default": "實際花費時間" }, { - "label": "反饋文字", + "label": "回饋文字", "default": "做得好!" }, { - "label": "再試一次按鈕文字", - "default": "再試一次?" + "label": "重試功能鈕名稱", + "default": "重試?" }, { - "label": "關閉按鈕標籤", + "label": "關閉功能鈕名稱", "default": "關閉" }, { - "label": "遊戲標籤", - "default": "記憶遊戲. 找到匹配的卡片." + "label": "遊戲名稱", + "default": "翻轉記憶牌遊戲. 請找出相稱的記憶牌." }, { - "label": "遊戲結束標籤", - "default": "所有的紙牌都被找到了." + "label": "遊戲完成名稱", + "default": "所有的記憶牌皆已找出." }, { - "label": "紙牌索引標籤", - "default": "紙牌 %num:" + "label": "記憶牌索引名稱", + "default": "記憶牌數量 %num:" }, { - "label": "未翻出的紙牌標籤", - "default": "紙牌." + "label": "未翻轉記憶牌名稱", + "default": "未翻轉." }, { - "label": "紙牌符合的標籤", - "default": "找到符合的." + "label": "相稱記憶牌名稱", + "default": "已找到相稱的記憶牌." } ] } From d1d84a2cdc7edf8ff1eb54410ddb4e6867b02005 Mon Sep 17 00:00:00 2001 From: "C.W. Fann" Date: Mon, 11 Dec 2017 17:36:50 +0800 Subject: [PATCH 17/48] Update zh-tw.json --- language/zh-tw.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/language/zh-tw.json b/language/zh-tw.json index 06691de..94aeb32 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -38,12 +38,12 @@ "description": "這些選項可以讓你控制遊戲的行為.", "fields": [ { - "label": "把記憶牌顯示於正方形中", + "label": "將記憶牌顯示於正方形中", "description": "當設定多組記憶牌時,將依組數平均分配顯示行列數及顯示大小." }, { "label": "使用的記憶牌組數量", - "description": "當設定多組記憶牌時,將依組數平均分配顯示行列數及顯示大小." + "description": "設定大於2的組數時,即可讓遊戲隨機顯示記憶牌." }, { "label": "遊戲結束後顯示重試功能鈕" From 7b6bde3d70bb0fbfda32f77fbe82fecd71a5aafe Mon Sep 17 00:00:00 2001 From: timothyylim Date: Fri, 26 Jan 2018 11:54:05 +0100 Subject: [PATCH 18/48] HFP-1831 Fix language files --- language/fi.json | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/language/fi.json b/language/fi.json index 14232b6..81cbe8d 100644 --- a/language/fi.json +++ b/language/fi.json @@ -21,6 +21,14 @@ { "label":"Selite", "description":"Valinnainen lyhyt teksti, joka näytetään kun oikea pari on löydetty." + }, + { + "label": "Alternative text for Matching Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + }, + { + "label": "Description", + "description": "An optional short text that will pop up once the two matching cards are found." } ] } @@ -49,10 +57,7 @@ { "label":"Väriteema", "description":"Valitse väri luodaksesi teeman pelille.", - "default":"#909090", - "spectrum":{ - - } + "default":"#909090" }, { "label":"Kortin kääntöpuoli", From 0efb9a6f3cacd0b9aa010ba48d3f4cc7b855a06b Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Mon, 23 Apr 2018 11:48:41 +0200 Subject: [PATCH 19/48] Patch before release --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index a85da9b..9ed87cc 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 9, + "patchVersion": 10, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} +} \ No newline at end of file From 422986b408b87ec9aa4e766df06975b5baf77edf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Breedveld?= Date: Wed, 25 Apr 2018 09:10:53 +0200 Subject: [PATCH 20/48] Update nl.json Dutch translations added --- language/nl.json | 96 ++++++++++++++++++++++++------------------------ 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/language/nl.json b/language/nl.json index 7101e4c..572d49c 100644 --- a/language/nl.json +++ b/language/nl.json @@ -3,112 +3,112 @@ { "widgets": [ { - "label": "Default" + "label": "Standaard" } ], - "label": "Cards", - "entity": "card", + "label": "Kaarten", + "entity": "kaart", "field": { - "label": "Card", + "label": "Kaart", "fields": [ { - "label": "Image" + "label": "Afbeelding" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Bijpassende afbeelding", + "description": "Een optionele afbeelding die past in plaats van 2 kaarten met dezelfde afbeelding." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Omschrijving", + "description": "Een optionele korte tekst die zal verschijnen zodra de 2 overeenkomende kaarten zijn gevonden." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "De alternatieve tekst voor de bijpassende afbeelding", + "description": "Omschrijf wat de afbeelding voorstelt. De tekst zal worden gelezen door tekst-naar-spraak tools voor slechtzienden." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Omschrijving", + "description": "Een optionele korte tekst die zal verschijnen zodra de 2 overeenkomende kaarten zijn gevonden." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Gedragsinstellingen", + "description": "Met deze opties kun je bepalen hoe het spel zich gedraagt.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Plaats de kaarten in een vierkant", + "description": "Bij het leggen van de kaarten zullen het aantal kolommen en rijen op elkaar worden afgestemd. Daarna zal de omvang van de kaarten worden aangepast om in de beschikbare omgeving te passen." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Het aantal te gebruiken kaarten", + "description": "Als je dit getal instelt op een aantal groter dan 2, dan zal het spel willekeurig kaarten kiezen uit de complete lijst met kaarten." }, { - "label": "Add button for retrying when the game is over" + "label": "Voeg de knop 'Opnieuw proberen? toe als het spel is afgelopen" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "De vormgeving", + "description": "Stel de beelden van het spel in.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Themakleur", + "description": "Kies een themakleur voor kaarten van je geheugenspel.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Achterkant kaart", + "description": "Gebruik een aangepaste achterkant voor je kaarten." } ] }, { - "label": "Localization", + "label": "Localiseer", "fields": [ { - "label": "Card turns text", - "default": "Card turns" + "label": "Label gedraaide kaarten", + "default": "Gedraaide kaarten" }, { - "label": "Time spent text", - "default": "Time spent" + "label": "Label verstreken tijd", + "default": "Verstreken tijd" }, { - "label": "Feedback text", - "default": "Good work!" + "label": "Label feedback", + "default": "Goed gedaan!" }, { - "label": "Try again button text", - "default": "Try again?" + "label": "Label opnieuw proberen knop", + "default": "Opnieuw proberen?" }, { - "label": "Close button label", - "default": "Close" + "label": "Label sluiten knop", + "default": "Sluiten" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Label spel", + "default": "Geheugenspel. Vind de overeenkomende kaarten." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": ":Label einde spel", + "default": "Alle kaarten zijn gevonden." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Label kaartenindex", + "default": "Kaart %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Label niet gedraaide kaarten", + "default": "Niet gedraaid." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Label overeenkomende kaarten", + "default": "Paar gevonden." } ] } ] -} \ No newline at end of file +} From 4223b8faf9600fa51baac17ab1c94defa57ac7d0 Mon Sep 17 00:00:00 2001 From: dnowba Date: Sat, 28 Apr 2018 20:16:53 +0800 Subject: [PATCH 21/48] Create zh.json --- language/zh.json | 114 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 language/zh.json diff --git a/language/zh.json b/language/zh.json new file mode 100644 index 0000000..21a8677 --- /dev/null +++ b/language/zh.json @@ -0,0 +1,114 @@ +{ + "semantics": [ + { + "widgets": [ + { + "label": "預設" + } + ], + "label": "所有卡片", + "entity": "卡片", + "field": { + "label": "卡片", + "fields": [ + { + "label": "圖像" + }, + { + "label": "配對圖像(非必要項)", + "description": "如果遊戲中要配對的不是同一張圖像,那麼可以在這裡添加要配對的另一張圖像。" + }, + { + "label": "配對成功文字(非必要項)", + "description": "在找到配對時會跳出的文字訊息。" + }, + { + "label": "配對圖像的替代文字", + "description": "在報讀器上用、或是配對圖像無法正常輸出時顯示的文字。" + }, + { + "label": "配對成功文字(非必要項)", + "description": "在找到配對時會跳出的文字訊息。" + } + ] + } + }, + { + "label": "行為設置", + "description": "讓你控制遊戲行為的一些設置。", + "fields": [ + { + "label": "將所有卡片顯示在方形容器", + "description": "在佈置卡片時,將嘗試匹配列數和行數。之後,卡片將被縮放以適合容器。" + }, + { + "label": "卡片的使用數量", + "description": "遊戲中配對的卡片組合數量,設定後會從卡片集中隨機挑選指定組合數,數字必須大於 2。" + }, + { + "label": "顯示「再試一次」按鈕" + } + ] + }, + { + "label": "外觀", + "description": "控制遊戲的視覺效果。", + "fields": [ + { + "label": "主題色調", + "description": "選擇遊戲環境要使用的色調。", + "default": "#909090" + }, + { + "label": "背面圖像(非必要項)", + "description": "允許自訂卡片背景要使用的圖片。" + } + ] + }, + { + "label": "本地化", + "fields": [ + { + "label": "翻牌次數的顯示文字", + "default": "翻牌次數" + }, + { + "label": "花費時間的顯示文字", + "default": "花費時間" + }, + { + "label": "遊戲過關的顯示文字", + "default": "幹得好!" + }, + { + "label": "重試按鈕的顯示文字", + "default": "再試一次" + }, + { + "label": "關閉按鈕的顯示文字", + "default": "關閉" + }, + { + "label": "遊戲說明的顯示文字", + "default": "卡片記憶遊戲,找出配對的所有卡片吧!" + }, + { + "label": "遊戲結束的的顯示文字", + "default": "已配對完所有卡片。" + }, + { + "label": "卡片索引的顯示文字", + "default": "%num: 張卡片" + }, + { + "label": "卡片未翻開的顯示文字", + "default": "還沒翻開。" + }, + { + "label": "卡片已配對的顯示文字", + "default": "配對成功。" + } + ] + } + ] +} From 7f7263c0a9ab100f6056af6794ca5de4abda6117 Mon Sep 17 00:00:00 2001 From: Oliver Tacke Date: Sun, 27 May 2018 17:00:47 +0200 Subject: [PATCH 22/48] Fix translations It seems the translations got messed up at some point in time when new properties were added. --- language/.en.json | 10 +++++----- language/af.json | 10 +++++----- language/ar.json | 12 ++++++------ language/bs.json | 12 ++++++------ language/ca.json | 10 +++++----- language/cs.json | 10 +++++----- language/da.json | 14 +++++++------- language/de.json | 12 ++++++------ language/el.json | 10 +++++----- language/es.json | 14 +++++++------- language/et.json | 10 +++++----- language/fi.json | 12 ++++++------ language/fr.json | 8 ++++---- language/he.json | 10 +++++----- language/hu.json | 10 +++++----- language/it.json | 12 ++++++------ language/ja.json | 14 +++++++------- language/ko.json | 10 +++++----- language/nb.json | 12 ++++++------ language/nl.json | 10 +++++----- language/nn.json | 10 +++++----- language/pl.json | 10 +++++----- language/pt.json | 10 +++++----- language/ro.json | 10 +++++----- language/ru.json | 10 +++++----- language/sr.json | 10 +++++----- language/sv.json | 10 +++++----- language/tr.json | 10 +++++----- language/vi.json | 10 +++++----- language/zh-tw.json | 8 ++++---- semantics.json | 2 +- 31 files changed, 161 insertions(+), 161 deletions(-) diff --git a/language/.en.json b/language/.en.json index 7101e4c..c62f4f9 100644 --- a/language/.en.json +++ b/language/.en.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/af.json b/language/af.json index 7101e4c..c62f4f9 100644 --- a/language/af.json +++ b/language/af.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/ar.json b/language/ar.json index 78a9852..359991f 100644 --- a/language/ar.json +++ b/language/ar.json @@ -15,20 +15,20 @@ "label": "الصورة" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "الوصف", - "description": "نص قصير يتم عرضه مرة واحدة علي اثنين من البطاقات متساوية" + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "الوصف", + "description": "نص قصير يتم عرضه مرة واحدة علي اثنين من البطاقات متساوية" } ] } diff --git a/language/bs.json b/language/bs.json index 125eae6..5c1bd1a 100644 --- a/language/bs.json +++ b/language/bs.json @@ -15,20 +15,20 @@ "label": "Slika" }, { - "label": "Ista slika", - "description": "Opcionalna slika koja se koristi umjestodvije iste slike." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Opis", - "description": "Kratak tekst koji će biti prikazan čim se pronađu dvije iste karte." + "label": "Ista slika", + "description": "Opcionalna slika koja se koristi umjestodvije iste slike." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Opis", + "description": "Kratak tekst koji će biti prikazan čim se pronađu dvije iste karte." } ] } diff --git a/language/ca.json b/language/ca.json index 7101e4c..c62f4f9 100644 --- a/language/ca.json +++ b/language/ca.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/cs.json b/language/cs.json index 7101e4c..c62f4f9 100644 --- a/language/cs.json +++ b/language/cs.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/da.json b/language/da.json index 2938029..0a636f3 100644 --- a/language/da.json +++ b/language/da.json @@ -15,20 +15,20 @@ "label": "Billede" }, { - "label": "Matchende billede", - "description": "Valgfrit billede som match i stedet for at have to kort med det samme billede." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Beskrivelse", - "description": "Valgfri tekst, som popper op, når to matchende billeder er fundet." + "label": "Matchende billede", + "description": "Valgfrit billede som match i stedet for at have to kort med det samme billede." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Beskrivelse", + "description": "Valgfri tekst, som popper op, når to matchende billeder er fundet." } ] } @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/de.json b/language/de.json index 550d6b0..5fb2e54 100644 --- a/language/de.json +++ b/language/de.json @@ -15,20 +15,20 @@ "label": "Bild" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Beschreibung", - "description": "Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Beschreibung", + "description": "Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." } ] } diff --git a/language/el.json b/language/el.json index 7101e4c..c62f4f9 100644 --- a/language/el.json +++ b/language/el.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/es.json b/language/es.json index ad9acad..0c1a3a2 100644 --- a/language/es.json +++ b/language/es.json @@ -15,20 +15,20 @@ "label": "Imagen" }, { - "label": "Imagen coincidente", - "description": "Una imagen opcional para emparejar, en vez de usar dos tarjetas con la misma imagen." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Descripción", - "description": "Un breve texto opcional que aparecerá una vez se encuentren las dos cartas coincidentes." + "label": "Imagen coincidente", + "description": "Una imagen opcional para emparejar, en vez de usar dos tarjetas con la misma imagen." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Descripción", + "description": "Un breve texto opcional que aparecerá una vez se encuentren las dos cartas coincidentes." } ] } @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/et.json b/language/et.json index 7101e4c..c62f4f9 100644 --- a/language/et.json +++ b/language/et.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/fi.json b/language/fi.json index 81cbe8d..0d03427 100644 --- a/language/fi.json +++ b/language/fi.json @@ -15,20 +15,20 @@ "label":"Kuva" }, { - "label":"Vastattava kuva", - "description":"Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label":"Selite", - "description":"Valinnainen lyhyt teksti, joka näytetään kun oikea pari on löydetty." + "label":"Vastattava kuva", + "description":"Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Selite", + "description": "Valinnainen lyhyt teksti, joka näytetään kun oikea pari on löydetty." } ] } diff --git a/language/fr.json b/language/fr.json index 32ca798..5ca861f 100644 --- a/language/fr.json +++ b/language/fr.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "Petit texte affiché quand deux cartes identiques sont trouvées." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", diff --git a/language/he.json b/language/he.json index 7101e4c..c62f4f9 100644 --- a/language/he.json +++ b/language/he.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/hu.json b/language/hu.json index 7101e4c..c62f4f9 100644 --- a/language/hu.json +++ b/language/hu.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/it.json b/language/it.json index 6a2e4c3..fb6b277 100644 --- a/language/it.json +++ b/language/it.json @@ -15,20 +15,20 @@ "label": "Immagine" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Descrizione", - "description": "Breve testo visualizzato quando due carte uguali vengono trovate." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Descrizione", + "description": "Breve testo visualizzato quando due carte uguali vengono trovate." } ] } diff --git a/language/ja.json b/language/ja.json index ca82581..5ca5b26 100644 --- a/language/ja.json +++ b/language/ja.json @@ -15,20 +15,20 @@ "label": "画像" }, { - "label": "一致させる画像", - "description": "同じ画像の2枚のカードを使用する代わりに、別に一致させるためのオプション画像" + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "説明", - "description": "一致する2つのカードが見つかるとポップアップするオプションの短文テキスト。" + "label": "一致させる画像", + "description": "同じ画像の2枚のカードを使用する代わりに、別に一致させるためのオプション画像" }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "説明", + "description": "一致する2つのカードが見つかるとポップアップするオプションの短文テキスト。" } ] } @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/ko.json b/language/ko.json index 7101e4c..c62f4f9 100644 --- a/language/ko.json +++ b/language/ko.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/nb.json b/language/nb.json index 21218d7..2b7df8e 100644 --- a/language/nb.json +++ b/language/nb.json @@ -15,20 +15,20 @@ "label": "Bilde" }, { - "label": "Tilhørende bilde", - "description": "Et valgfritt bilde som brukes av kort nummer to istedenfor å bruke to kort med samme bilde." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Beskrivelse", - "description": "En valgfri kort tekst som spretter opp når kort-paret er funnet." + "label": "Tilhørende bilde", + "description": "Et valgfritt bilde som brukes av kort nummer to istedenfor å bruke to kort med samme bilde." }, { "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Beskrivelse", + "description": "En valgfri kort tekst som spretter opp når kort-paret er funnet." } ] } diff --git a/language/nl.json b/language/nl.json index 7101e4c..c62f4f9 100644 --- a/language/nl.json +++ b/language/nl.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/nn.json b/language/nn.json index 7101e4c..c62f4f9 100644 --- a/language/nn.json +++ b/language/nn.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/pl.json b/language/pl.json index 7101e4c..c62f4f9 100644 --- a/language/pl.json +++ b/language/pl.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/pt.json b/language/pt.json index 7101e4c..c62f4f9 100644 --- a/language/pt.json +++ b/language/pt.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/ro.json b/language/ro.json index 7101e4c..c62f4f9 100644 --- a/language/ro.json +++ b/language/ro.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/ru.json b/language/ru.json index 7101e4c..c62f4f9 100644 --- a/language/ru.json +++ b/language/ru.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/sr.json b/language/sr.json index 7101e4c..c62f4f9 100644 --- a/language/sr.json +++ b/language/sr.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/sv.json b/language/sv.json index 7101e4c..c62f4f9 100644 --- a/language/sv.json +++ b/language/sv.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/tr.json b/language/tr.json index 7101e4c..c62f4f9 100644 --- a/language/tr.json +++ b/language/tr.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/vi.json b/language/vi.json index 7101e4c..c62f4f9 100644 --- a/language/vi.json +++ b/language/vi.json @@ -15,12 +15,12 @@ "label": "Image" }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Matching Image", + "description": "An optional image to match against instead of using two cards with the same image." }, { "label": "Alternative text for Matching Image", @@ -111,4 +111,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/language/zh-tw.json b/language/zh-tw.json index 94aeb32..95e730c 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -15,12 +15,12 @@ "label": "圖示" }, { - "label": "相稱圖示", - "description": "可選用一張與主圖示相稱的圖示,並非使用兩張相同的圖示." + "label": "Alternative text for Image", + "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label": "描述", - "description": "選填。當找到兩張相稱圖示時所顯示的文字." + "label": "相稱圖示", + "description": "可選用一張與主圖示相稱的圖示,並非使用兩張相同的圖示." }, { "label": "相稱圖示的替代文字", diff --git a/semantics.json b/semantics.json index 0333ce0..37e8008 100644 --- a/semantics.json +++ b/semantics.json @@ -207,4 +207,4 @@ } ] } -] \ No newline at end of file +] From f1f2d1e33abd322315212f3b2302f3e68d9d459f Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Mon, 28 May 2018 10:56:48 +0200 Subject: [PATCH 23/48] Bump --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 9ed87cc..38efad8 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 10, + "patchVersion": 11, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} \ No newline at end of file +} From 5538f4c35672451d41e886f4c5d5c1ef4aadff25 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Mon, 11 Jun 2018 09:48:32 +0200 Subject: [PATCH 24/48] Update French translations. Big thanks to knowledgeplaces --- language/fr.json | 77 ++++++++++++++++++++++++------------------------ 1 file changed, 38 insertions(+), 39 deletions(-) diff --git a/language/fr.json b/language/fr.json index 5ca861f..e0c53b3 100644 --- a/language/fr.json +++ b/language/fr.json @@ -3,7 +3,7 @@ { "widgets": [ { - "label": "Default" + "label": "Par défaut" } ], "label": "Cartes", @@ -15,53 +15,52 @@ "label": "Image" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." - }, - { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." - }, - { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Texte alternatif pour l'image", + "description": "Décrivez ce que représente l'image. Le texte est lu par la synthèse vocale." + }, { + "label": "Image correspondante", + "description": "Une image facultative à comparer au lieu d'utiliser deux cartes avec la même image." }, + { + "label": "Texte alternatif pour l'image correspondante", + "description": "Décrivez ce que représente l'image correspondante. Le texte est lu par la synthèse vocale." + }, { "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "description": "Un texte court optionnel qui apparaîtra une fois que les deux cartes correspondantes auront été trouvées." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Paramètres comportementaux", + "description": "Ces options vous permettent de définir le \"comportement\" du jeu de mémoire.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Positionnez les cartes en carré", + "description": "Essaiera de faire correspondre le nombre de colonnes et de rangées lors de la disposition des cartes. Ensuite, les cartes seront mises à l'échelle pour s'adapter au conteneur." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Nombre de cartes à utiliser", + "description": "Régler ce nombre sur un nombre supérieur à 2 fera que le jeu choisira des cartes aléatoires dans la liste des cartes." }, { - "label": "Add button for retrying when the game is over" + "label": "Ajoutez un bouton pour essayer à nouveau quand le jeu est terminé" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "Apparence", + "description": "Définissez l'apparence visuelle des éléments dans le jeu.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Couleur du thème", + "description": "Choisissez une couleur pour créer un thème pour votre jeu de cartes.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Dos des cartes", + "description": "Utilisez un dos personnalisé pour vos cartes." } ] }, @@ -81,32 +80,32 @@ "default": "Bien joué !" }, { - "label": "Try again button text", - "default": "Reset" + "label": "Texte pour le bouton Réessayez", + "default": "Réessayer" }, { - "label": "Close button label", - "default": "Close" + "label": "Texte du bouton Fermer", + "default": "Fermer" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Le nom du jeu", + "default": "Jeu de mémoire. Trouver les cartes qui se correspondent." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Texte pour Le jeu est terminé", + "default": "Toutes les cartes ont été trouvées." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Texte de numérotation des cartes", + "default": "Carte %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Texte pour les cartes non retournées", + "default": "Non retournées." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Texte quand les cartes correspondent", + "default": "Correspondance trouvée." } ] } From 212877f489e5fa33cacd220ea83cc5a1432260d6 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Mon, 11 Jun 2018 10:27:52 +0200 Subject: [PATCH 25/48] Update translations --- language/.en.json | 2 +- language/af.json | 2 +- language/ar.json | 2 +- language/bs.json | 2 +- language/ca.json | 2 +- language/cs.json | 2 +- language/da.json | 2 +- language/de.json | 2 +- language/el.json | 2 +- language/es.json | 2 +- language/et.json | 2 +- language/fi.json | 76 ++++++++++++++++++++++----------------------- language/fr.json | 9 +++--- language/he.json | 2 +- language/hu.json | 2 +- language/it.json | 2 +- language/ja.json | 2 +- language/ko.json | 2 +- language/nb.json | 2 +- language/nl.json | 2 +- language/nn.json | 2 +- language/pl.json | 2 +- language/pt.json | 2 +- language/ro.json | 2 +- language/ru.json | 2 +- language/sr.json | 2 +- language/sv.json | 2 +- language/tr.json | 2 +- language/vi.json | 2 +- language/zh-tw.json | 2 +- language/zh.json | 2 +- semantics.json | 2 +- 32 files changed, 73 insertions(+), 72 deletions(-) diff --git a/language/.en.json b/language/.en.json index c62f4f9..2a9e4d6 100644 --- a/language/.en.json +++ b/language/.en.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/af.json b/language/af.json index c62f4f9..2a9e4d6 100644 --- a/language/af.json +++ b/language/af.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ar.json b/language/ar.json index 359991f..073bd2c 100644 --- a/language/ar.json +++ b/language/ar.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/bs.json b/language/bs.json index 5c1bd1a..522c820 100644 --- a/language/bs.json +++ b/language/bs.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ca.json b/language/ca.json index c62f4f9..2a9e4d6 100644 --- a/language/ca.json +++ b/language/ca.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/cs.json b/language/cs.json index c62f4f9..2a9e4d6 100644 --- a/language/cs.json +++ b/language/cs.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/da.json b/language/da.json index 0a636f3..91a2e3a 100644 --- a/language/da.json +++ b/language/da.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/de.json b/language/de.json index 5fb2e54..7c5f0fe 100644 --- a/language/de.json +++ b/language/de.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/el.json b/language/el.json index c62f4f9..2a9e4d6 100644 --- a/language/el.json +++ b/language/el.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/es.json b/language/es.json index 0c1a3a2..731dcd8 100644 --- a/language/es.json +++ b/language/es.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/et.json b/language/et.json index c62f4f9..2a9e4d6 100644 --- a/language/et.json +++ b/language/et.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/fi.json b/language/fi.json index 0d03427..a692a57 100644 --- a/language/fi.json +++ b/language/fi.json @@ -3,24 +3,24 @@ { "widgets": [ { - "label":"Oletus" + "label": "Oletus" } ], - "label":"Kortit", - "entity":"kortti", - "field":{ - "label":"Kortti", - "fields":[ + "label": "Kortit", + "entity": "kortti", + "field": { + "label": "Kortti", + "fields": [ { - "label":"Kuva" + "label": "Kuva" }, { "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "label":"Vastattava kuva", - "description":"Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." + "label": "Vastattava kuva", + "description": "Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." }, { "label": "Alternative text for Matching Image", @@ -34,59 +34,59 @@ } }, { - "label":"Yleisasetukset", - "description":"Näillä valinnoilla voit muokata pelin asetuksia.", - "fields":[ + "label": "Yleisasetukset", + "description": "Näillä valinnoilla voit muokata pelin asetuksia.", + "fields": [ { - "label":"Aseta kortit säännöllisesti", - "description":"Yrittää sovittaa kortit ruudukkomuotoon rivien sijaan." + "label": "Aseta kortit säännöllisesti", + "description": "Yrittää sovittaa kortit ruudukkomuotoon rivien sijaan." }, { - "label":"Korttien lukumäärä", - "description":"Kun lukumäärä on suurempi kuin kaksi, annettu määrä kortteja arvotaan kaikista korteista pelattavaksi." + "label": "Korttien lukumäärä", + "description": "Kun lukumäärä on suurempi kuin kaksi, annettu määrä kortteja arvotaan kaikista korteista pelattavaksi." }, { - "label":"Salli Yritä uudelleen -painike pelin päätyttyä" + "label": "Salli Yritä uudelleen -painike pelin päätyttyä" } ] }, { - "label":"Ulkoasu", - "description":"Hallinnoi pelin ulkoasua.", - "fields":[ + "label": "Ulkoasu", + "description": "Hallinnoi pelin ulkoasua.", + "fields": [ { - "label":"Väriteema", - "description":"Valitse väri luodaksesi teeman pelille.", - "default":"#909090" + "label": "Väriteema", + "description": "Valitse väri luodaksesi teeman pelille.", + "default": "#909090" }, { - "label":"Kortin kääntöpuoli", - "description":"Mukauta korttien kääntöpuoli." + "label": "Kortin kääntöpuoli", + "description": "Mukauta korttien kääntöpuoli." } ] }, { - "label":"Tekstit", - "fields":[ + "label": "Tekstit", + "fields": [ { - "label":"Kortteja käännetty", - "default":"Kortteja käännetty" + "label": "Kortteja käännetty", + "default": "Kortteja käännetty" }, { - "label":"Aikaa kulunut", - "default":"Aikaa kulunut" + "label": "Aikaa kulunut", + "default": "Aikaa kulunut" }, { - "label":"Palaute", - "default":"Hyvää työtä!" + "label": "Palaute", + "default": "Hyvää työtä!" }, { - "label":"Painikkeen Yritä uudelleen teksti", - "default":"Yritä uudelleen?" + "label": "Painikkeen Yritä uudelleen teksti", + "default": "Yritä uudelleen?" }, { - "label":"Painikkeen Sulje teksti", - "default":"Sulje" + "label": "Painikkeen Sulje teksti", + "default": "Sulje" }, { "label": "Pelin kuvaus", @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/fr.json b/language/fr.json index e0c53b3..f33d0c2 100644 --- a/language/fr.json +++ b/language/fr.json @@ -17,14 +17,15 @@ { "label": "Texte alternatif pour l'image", "description": "Décrivez ce que représente l'image. Le texte est lu par la synthèse vocale." - }, { + }, + { "label": "Image correspondante", "description": "Une image facultative à comparer au lieu d'utiliser deux cartes avec la même image." }, - { + { "label": "Texte alternatif pour l'image correspondante", "description": "Décrivez ce que représente l'image correspondante. Le texte est lu par la synthèse vocale." - }, + }, { "label": "Description", "description": "Un texte court optionnel qui apparaîtra une fois que les deux cartes correspondantes auront été trouvées." @@ -110,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/he.json b/language/he.json index c62f4f9..2a9e4d6 100644 --- a/language/he.json +++ b/language/he.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/hu.json b/language/hu.json index c62f4f9..2a9e4d6 100644 --- a/language/hu.json +++ b/language/hu.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/it.json b/language/it.json index fb6b277..9e2932a 100644 --- a/language/it.json +++ b/language/it.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ja.json b/language/ja.json index 5ca5b26..d9883e8 100644 --- a/language/ja.json +++ b/language/ja.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ko.json b/language/ko.json index c62f4f9..2a9e4d6 100644 --- a/language/ko.json +++ b/language/ko.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/nb.json b/language/nb.json index 2b7df8e..d5187ef 100644 --- a/language/nb.json +++ b/language/nb.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/nl.json b/language/nl.json index 572d49c..c81981b 100644 --- a/language/nl.json +++ b/language/nl.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/nn.json b/language/nn.json index c62f4f9..2a9e4d6 100644 --- a/language/nn.json +++ b/language/nn.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/pl.json b/language/pl.json index c62f4f9..2a9e4d6 100644 --- a/language/pl.json +++ b/language/pl.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/pt.json b/language/pt.json index c62f4f9..2a9e4d6 100644 --- a/language/pt.json +++ b/language/pt.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ro.json b/language/ro.json index c62f4f9..2a9e4d6 100644 --- a/language/ro.json +++ b/language/ro.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ru.json b/language/ru.json index c62f4f9..2a9e4d6 100644 --- a/language/ru.json +++ b/language/ru.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/sr.json b/language/sr.json index c62f4f9..2a9e4d6 100644 --- a/language/sr.json +++ b/language/sr.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/sv.json b/language/sv.json index c62f4f9..2a9e4d6 100644 --- a/language/sv.json +++ b/language/sv.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/tr.json b/language/tr.json index c62f4f9..2a9e4d6 100644 --- a/language/tr.json +++ b/language/tr.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/vi.json b/language/vi.json index c62f4f9..2a9e4d6 100644 --- a/language/vi.json +++ b/language/vi.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/zh-tw.json b/language/zh-tw.json index 95e730c..3db28bf 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/zh.json b/language/zh.json index 21a8677..f7ac798 100644 --- a/language/zh.json +++ b/language/zh.json @@ -111,4 +111,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/semantics.json b/semantics.json index 37e8008..0333ce0 100644 --- a/semantics.json +++ b/semantics.json @@ -207,4 +207,4 @@ } ] } -] +] \ No newline at end of file From fac881fa0fea95618fe8c6854d2f851f8da4717a Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Fri, 29 Jun 2018 10:50:18 +0200 Subject: [PATCH 26/48] Bump patch version --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 38efad8..16b8145 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 11, + "patchVersion": 12, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} +} \ No newline at end of file From e74962230a5f83cf307253b2f1994d3129ff15f6 Mon Sep 17 00:00:00 2001 From: msegovia90 <40923608+msegovia90@users.noreply.github.com> Date: Sat, 14 Jul 2018 21:28:58 -0400 Subject: [PATCH 27/48] Update es.json --- language/es.json | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/language/es.json b/language/es.json index 731dcd8..4a2c1de 100644 --- a/language/es.json +++ b/language/es.json @@ -15,16 +15,16 @@ "label": "Imagen" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Texto alternativo para la imagen", + "description": "Describe lo que se puede ver en la foto. El texto es leído por una herramienta de conversion de texto a voz, a usuarios con discapacidad visual." }, { "label": "Imagen coincidente", "description": "Una imagen opcional para emparejar, en vez de usar dos tarjetas con la misma imagen." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Texto alternativo para imagenes coincidentes", + "description": "El texto es leído por una herramienta de conversion de texto a voz, a usuarios con discapacidad visual." }, { "label": "Descripción", @@ -81,34 +81,34 @@ "default": "¡Buen trabajo!" }, { - "label": "Intente del botón Intente de nuevo", + "label": "Texto del botón Intente de nuevo", "default": "¿Volver a intentarlo?" }, { - "label": "Etiqueta del botón Cerrar", + "label": "Texto del botón Cerrar", "default": "Cerrar" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Texto del juego", + "default": "Juego de memoria. Encuentra las cartas que hacen juego." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Texto del juego terminado", + "default": "Todas las cartas han sido encontradas." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Texto de indexación de la tarjeta", + "default": "Tarjeta %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Texto de tarjetas sin voltear", + "default": "Sin voltear." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Texto de la tarjeta coincidente", + "default": "Coincidencia encontrada." } ] } ] -} \ No newline at end of file +} From 1b9f2dc61b1511a1ae453ea27aa53fa73cff6125 Mon Sep 17 00:00:00 2001 From: Juliano Navroski Junior Date: Thu, 9 Aug 2018 15:01:38 -0300 Subject: [PATCH 28/48] Update pt.json --- language/pt.json | 94 ++++++++++++++++++++++++------------------------ 1 file changed, 47 insertions(+), 47 deletions(-) diff --git a/language/pt.json b/language/pt.json index 2a9e4d6..8133dc7 100644 --- a/language/pt.json +++ b/language/pt.json @@ -3,112 +3,112 @@ { "widgets": [ { - "label": "Default" + "label": "Padrão" } ], - "label": "Cards", + "label": "Cartões", "entity": "card", "field": { - "label": "Card", + "label": "Cartão", "fields": [ { - "label": "Image" + "label": "Imagem" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Texto alternativo para a imagem", + "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Imagem-par", + "description": "Uma imagem opcional para ser combinada ao invés de utilizar dois cartões com a mesma imagem." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Texto alternativo para a Imagem-par", + "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Descrição", + "description": "Um texto curto opcional que aparecerá quando duas cartas forem combinadas corretamente." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Configurações comportamentais", + "description": "Estas opções permitirão que você controle como o jogo funciona.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Posicionar os cartões em um quadrado", + "description": "Tentará coincidir o número de linhas e colunas quando distribuir os cartões. Após, os cartões serão dimensionados para preencher o espaço." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Número de cartas para serem usadas", + "description": "Colocando um número maior que 2 fara com que o jogo escolha cartões aleatórios da lista de cartões." }, { - "label": "Add button for retrying when the game is over" + "label": "Adicionar botão para tentar novamente quando o jogo acabar" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "Aparência e percepção", + "description": "Controla o visual do jogo.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Cor tema", + "description": "Escolha uma cor para criar um tema para seu jogo.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Verso do cartão", + "description": "Use um verso customizado para seus cartões." } ] }, { - "label": "Localization", + "label": "Localização", "fields": [ { - "label": "Card turns text", - "default": "Card turns" + "label": "Texto de virada de cartão", + "default": "Cartão virou" }, { - "label": "Time spent text", - "default": "Time spent" + "label": "Texto de tempo gasto", + "default": "Tempo gasto" }, { - "label": "Feedback text", - "default": "Good work!" + "label": "Texto de feedback", + "default": "Bom trabalho!" }, { - "label": "Try again button text", - "default": "Try again?" + "label": "Texto do botão Tentar Novamente", + "default": "Tentar novamente?" }, { - "label": "Close button label", - "default": "Close" + "label": "Rótulo do botão Fechar", + "default": "Fechar" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Rótulo do jogo", + "default": "Jogo da memória. Forme pares de cartões." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Rótulo de fim de jogo", + "default": "Todas os cartões foram encontrados." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Rótulo de índice de cartão", + "default": "Cartão %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Rótulo de cartão não virado", + "default": "Não virado." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Rótulo de combinação", + "default": "Combinação encontrada." } ] } ] -} \ No newline at end of file +} From 191326cf10396c79376d50ab1c2e306c477cd700 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Thu, 23 Aug 2018 01:44:41 +0200 Subject: [PATCH 29/48] Initial audio version --- card.js | 102 ++++++++++++++++++++++++++++++++++++++++-------- library.json | 6 +-- memory-game.css | 25 ++++++++++++ memory-game.js | 6 +-- semantics.json | 20 +++++++++- 5 files changed, 136 insertions(+), 23 deletions(-) diff --git a/card.js b/card.js index 867d405..9919018 100644 --- a/card.js +++ b/card.js @@ -12,30 +12,71 @@ * @param {string} [description] * @param {Object} [styles] */ - MemoryGame.Card = function (image, id, alt, l10n, description, styles) { + MemoryGame.Card = function (image, id, alt, l10n, description, styles, audio) { /** @alias H5P.MemoryGame.Card# */ var self = this; // Initialize event inheritance EventDispatcher.call(self); - var path = H5P.getPath(image.path, id); - var width, height, $card, $wrapper, removedState, flippedState; + var path, width, height, $card, $wrapper, removedState, flippedState, audioPlayer; alt = alt || 'Missing description'; // Default for old games - if (image.width !== undefined && image.height !== undefined) { - if (image.width > image.height) { - width = '100%'; - height = 'auto'; + if (image && image.path) { + path = H5P.getPath(image.path, id); + + if (image.width !== undefined && image.height !== undefined) { + if (image.width > image.height) { + width = '100%'; + height = 'auto'; + } + else { + height = '100%'; + width = 'auto'; + } } else { - height = '100%'; - width = 'auto'; + width = height = '100%'; } } - else { - width = height = '100%'; + + if (audio) { + // Check if browser supports audio. + audioPlayer = document.createElement('audio'); + if (audioPlayer.canPlayType !== undefined) { + // Add supported source files. + for (var i = 0; i < audio.length; i++) { + if (audioPlayer.canPlayType(audio[i].mime)) { + var source = document.createElement('source'); + source.src = H5P.getPath(audio[i].path, id); + source.type = audio[i].mime; + audioPlayer.appendChild(source); + } + } + } + + if (!audioPlayer.children.length) { + audioPlayer = null; // Not supported + } + else { + audioPlayer.controls = false; + audioPlayer.preload = 'auto'; + + var handlePlaying = function () { + if ($card) { + $card.addClass('h5p-memory-audio-playing'); + } + }; + var handleStopping = function () { + if ($card) { + $card.removeClass('h5p-memory-audio-playing'); + } + }; + audioPlayer.addEventListener('play', handlePlaying); + audioPlayer.addEventListener('ended', handleStopping); + audioPlayer.addEventListener('pause', handleStopping); + } } /** @@ -74,6 +115,10 @@ return; } + if (audioPlayer) { + audioPlayer.play(); + } + $card.addClass('h5p-flipped'); self.trigger('flip'); flippedState = true; @@ -83,6 +128,11 @@ * Flip card back. */ self.flipBack = function () { + if (audioPlayer) { + audioPlayer.pause(); + audioPlayer.currentTime = 0; + } + self.updateLabel(null, null, true); // Reset card label $card.removeClass('h5p-flipped'); flippedState = false; @@ -100,6 +150,11 @@ * Reset card to natural state */ self.reset = function () { + if (audioPlayer) { + audioPlayer.pause(); + audioPlayer.currentTime = 0; + } + self.updateLabel(null, null, true); // Reset card label flippedState = false; removedState = false; @@ -133,7 +188,7 @@ $wrapper = $('
      • ' + '
        ' + (styles && styles.backImage ? '' : '') + '
        ' + '
        ' + - '' + alt + '' + + (path ? '' + alt + '' + (audioPlayer ? '
        ' : '') : '') + '
        ' + '
      • ') .appendTo($container) @@ -176,6 +231,19 @@ self.flip(); }) .end(); + + if (audioPlayer) { + $card.children('.h5p-back') + .click(function () { + if ($card.hasClass('h5p-memory-audio-playing')) { + audioPlayer.pause(); + audioPlayer.currentTime = 0; + } + else { + audioPlayer.play(); + } + }) + } }; /** @@ -236,8 +304,9 @@ */ MemoryGame.Card.isValid = function (params) { return (params !== undefined && - params.image !== undefined && - params.image.path !== undefined); + (params.image !== undefined && + params.image.path !== undefined) || + params.audio); }; /** @@ -249,8 +318,9 @@ */ MemoryGame.Card.hasTwoImages = function (params) { return (params !== undefined && - params.match !== undefined && - params.match.path !== undefined); + (params.match !== undefined && + params.match.path !== undefined) || + params.matchAudio); }; /** diff --git a/library.json b/library.json index 16b8145..9092305 100644 --- a/library.json +++ b/library.json @@ -2,8 +2,8 @@ "title": "Memory Game", "description": "See how many cards you can remember!", "majorVersion": 1, - "minorVersion": 2, - "patchVersion": 12, + "minorVersion": 3, + "patchVersion": 0, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -54,4 +54,4 @@ "minorVersion": 3 } ] -} \ No newline at end of file +} diff --git a/memory-game.css b/memory-game.css index c188210..1b53971 100644 --- a/memory-game.css +++ b/memory-game.css @@ -318,3 +318,28 @@ .h5p-memory-game .h5p-programatically-focusable { outline: none; } +.h5p-memory-audio-instead-of-image { + font-family: 'H5PFontAwesome4'; + width: 100%; + height: 100%; + font-style: normal; + color: #404040; + font-size: 2em; +} +.h5p-memory-audio-button { + position: absolute; + top: 0; + right: 0; + font-family: 'H5PFontAwesome4'; + width: 1em; + height: 1em; + line-height: 1; +} +.h5p-memory-audio-instead-of-image:before, +.h5p-memory-audio-button:before { + content: "\f026"; +} +.h5p-memory-audio-playing .h5p-memory-audio-instead-of-image:before, +.h5p-memory-audio-playing .h5p-memory-audio-button:before { + content: "\f028"; +} diff --git a/memory-game.js b/memory-game.js index 38829de..07bbd0d 100644 --- a/memory-game.js +++ b/memory-game.js @@ -384,16 +384,16 @@ H5P.MemoryGame = (function (EventDispatcher, $) { var cardParams = cardsToUse[i]; if (MemoryGame.Card.isValid(cardParams)) { // Create first card - var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles); + var cardTwo, cardOne = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles, cardParams.audio); if (MemoryGame.Card.hasTwoImages(cardParams)) { // Use matching image for card two - cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.matchAlt, parameters.l10n, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.match, id, cardParams.matchAlt, parameters.l10n, cardParams.description, cardStyles, cardParams.matchAudio); cardOne.hasTwoImages = cardTwo.hasTwoImages = true; } else { // Add two cards with the same image - cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles); + cardTwo = new MemoryGame.Card(cardParams.image, id, cardParams.imageAlt, parameters.l10n, cardParams.description, cardStyles, cardParams.audio); } // Add cards to card list for shuffeling diff --git a/semantics.json b/semantics.json index 0333ce0..4108971 100644 --- a/semantics.json +++ b/semantics.json @@ -33,6 +33,15 @@ "importance": "high", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "state": "new", + "name": "audio", + "type": "audio", + "importance": "high", + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned.", + "optional": true + }, { "name": "match", "type": "image", @@ -50,6 +59,15 @@ "optional": true, "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "state": "new", + "name": "matchAudio", + "type": "audio", + "importance": "low", + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned.", + "optional": true + }, { "name": "description", "type": "text", @@ -207,4 +225,4 @@ } ] } -] \ No newline at end of file +] From c609bdbead2a170b0cc8cb668abb876061fd2b39 Mon Sep 17 00:00:00 2001 From: Juliano Navroski Junior Date: Thu, 23 Aug 2018 08:52:25 -0300 Subject: [PATCH 30/48] Create pt-br.json Added brazilian portuguese translation --- language/pt-br.json | 114 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 language/pt-br.json diff --git a/language/pt-br.json b/language/pt-br.json new file mode 100644 index 0000000..8133dc7 --- /dev/null +++ b/language/pt-br.json @@ -0,0 +1,114 @@ +{ + "semantics": [ + { + "widgets": [ + { + "label": "Padrão" + } + ], + "label": "Cartões", + "entity": "card", + "field": { + "label": "Cartão", + "fields": [ + { + "label": "Imagem" + }, + { + "label": "Texto alternativo para a imagem", + "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." + }, + { + "label": "Imagem-par", + "description": "Uma imagem opcional para ser combinada ao invés de utilizar dois cartões com a mesma imagem." + }, + { + "label": "Texto alternativo para a Imagem-par", + "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." + }, + { + "label": "Descrição", + "description": "Um texto curto opcional que aparecerá quando duas cartas forem combinadas corretamente." + } + ] + } + }, + { + "label": "Configurações comportamentais", + "description": "Estas opções permitirão que você controle como o jogo funciona.", + "fields": [ + { + "label": "Posicionar os cartões em um quadrado", + "description": "Tentará coincidir o número de linhas e colunas quando distribuir os cartões. Após, os cartões serão dimensionados para preencher o espaço." + }, + { + "label": "Número de cartas para serem usadas", + "description": "Colocando um número maior que 2 fara com que o jogo escolha cartões aleatórios da lista de cartões." + }, + { + "label": "Adicionar botão para tentar novamente quando o jogo acabar" + } + ] + }, + { + "label": "Aparência e percepção", + "description": "Controla o visual do jogo.", + "fields": [ + { + "label": "Cor tema", + "description": "Escolha uma cor para criar um tema para seu jogo.", + "default": "#909090" + }, + { + "label": "Verso do cartão", + "description": "Use um verso customizado para seus cartões." + } + ] + }, + { + "label": "Localização", + "fields": [ + { + "label": "Texto de virada de cartão", + "default": "Cartão virou" + }, + { + "label": "Texto de tempo gasto", + "default": "Tempo gasto" + }, + { + "label": "Texto de feedback", + "default": "Bom trabalho!" + }, + { + "label": "Texto do botão Tentar Novamente", + "default": "Tentar novamente?" + }, + { + "label": "Rótulo do botão Fechar", + "default": "Fechar" + }, + { + "label": "Rótulo do jogo", + "default": "Jogo da memória. Forme pares de cartões." + }, + { + "label": "Rótulo de fim de jogo", + "default": "Todas os cartões foram encontrados." + }, + { + "label": "Rótulo de índice de cartão", + "default": "Cartão %num:" + }, + { + "label": "Rótulo de cartão não virado", + "default": "Não virado." + }, + { + "label": "Rótulo de combinação", + "default": "Combinação encontrada." + } + ] + } + ] +} From 158698d135331029ff86265180015253bf2083a0 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Mon, 3 Sep 2018 15:00:54 +0200 Subject: [PATCH 31/48] Bump patch --- library.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library.json b/library.json index 16b8145..0c00281 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 12, + "patchVersion": 13, "runnable": 1, "author": "Joubel", "license": "MIT", From cb9b19596616ae1e8a84556497a7a6a07dbde3de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?I=C3=B1igo=20Zendegi?= Date: Sat, 27 Oct 2018 17:10:39 +0200 Subject: [PATCH 32/48] Create eu.json Translation to basque language by Librezale taldea. https://librezale.eus/ --- language/eu.json | 114 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 language/eu.json diff --git a/language/eu.json b/language/eu.json new file mode 100644 index 0000000..bd7e844 --- /dev/null +++ b/language/eu.json @@ -0,0 +1,114 @@ +{ + "semantics": [ + { + "widgets": [ + { + "label": "Lehenetsia" + } + ], + "label": "Txartelak", + "entity": "karta", + "field": { + "label": "Karta", + "fields": [ + { + "label": "Irudia" + }, + { + "label": "Irudiaren ordezko testua", + "description": "Deskribatu irudian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute." + }, + { + "label": "Pareko irudia", + "description": "Irudi bera duten bi karta ez erabiltzeko parekatzeko aukeran eskainiko den irudia." + }, + { + "label": "Pareko irudiaren ordezko irudia", + "description": "Deskribatu argazkian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute." + }, + { + "label": "Deskribapena", + "description": "Bi karta parekatzen direnean bat-batean agertu den aukerako testu laburra." + } + ] + } + }, + { + "label": "Portaera-ezarpenak", + "description": "Aukera hauen bidez kontrolatu ahal izango duzu zereginaren portaera.", + "fields": [ + { + "label": "Kokatu karta karratuan", + "description": "Txartelak banatzean lerro eta zutabe kopurua betetzen saiatuko da. Gero, kartak eskalatuko dira." + }, + { + "label": "Erabiliko den karta kopurua", + "description": "2 baino altuagoa den zenbaki bat ezarriz gero jokoak hausazko karta hartuko du karta-zerrendatik." + }, + { + "label": "Saiakera berria egiteko botoia txertatu jokoa amaitzerakoan" + } + ] + }, + { + "label": "Itxura", + "description": "Jokoaren itxura kontrolatu", + "fields": [ + { + "label": "Estiloaren kolorea", + "description": "Aukeratu kolorea zure karta jokoarentzat estiloa sortzeko.", + "default": "#909090" + }, + { + "label": "Kartaren atzeko aldea", + "description": "Erabili karta-atzeko alde pertsonalizatua." + } + ] + }, + { + "label": "Lokalizazioa", + "fields": [ + { + "label": "Txartelak buelta ematen du testua", + "default": "Txartelak buelta ematen du" + }, + { + "label": "Igarotako denboraren testua", + "default": "Igarotako denbora" + }, + { + "label": "Feedback testua", + "default": "Lan bikaina!" + }, + { + "label": "Saiatu berriro botoiaren", + "default": "Saiatu berriro?" + }, + { + "label": "Itxi botoiaren etiketa", + "default": "Itxi" + }, + { + "label": "Jokoaren etiketa", + "default": "Memoria jokoa. Aurkitu pareko kartak." + }, + { + "label": "Amaitutako jokoaren etiketa", + "default": "Karta guztiak aurkitu dira." + }, + { + "label": "Txartela zenbakiaren etiketa", + "default": "%num. txartela:" + }, + { + "label": "buelta eman gabeko txartela", + "default": "Itzuli gabe" + }, + { + "label": "Parekatutako txartelaren etiketa", + "default": "Parekoa topatuta." + } + ] + } + ] +} From 7ca312bc5ad9381d9a3de4b35d88d717fc0c97f4 Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Fri, 2 Nov 2018 08:49:56 +0100 Subject: [PATCH 33/48] Bump patch version --- library.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library.json b/library.json index 0c00281..bb52385 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 2, - "patchVersion": 13, + "patchVersion": 14, "runnable": 1, "author": "Joubel", "license": "MIT", From 27680da092af56100be5e922f15ef91b0ecc1247 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Fri, 2 Nov 2018 14:38:25 +0100 Subject: [PATCH 34/48] Update translations --- language/.en.json | 8 ++++++++ language/af.json | 8 ++++++++ language/ar.json | 8 ++++++++ language/bs.json | 8 ++++++++ language/ca.json | 8 ++++++++ language/cs.json | 8 ++++++++ language/da.json | 8 ++++++++ language/de.json | 8 ++++++++ language/el.json | 8 ++++++++ language/es.json | 10 +++++++++- language/et.json | 8 ++++++++ language/fi.json | 8 ++++++++ language/fr.json | 8 ++++++++ language/he.json | 8 ++++++++ language/hu.json | 8 ++++++++ language/it.json | 8 ++++++++ language/ja.json | 8 ++++++++ language/ko.json | 8 ++++++++ language/nb.json | 8 ++++++++ language/nl.json | 8 ++++++++ language/nn.json | 8 ++++++++ language/pl.json | 8 ++++++++ language/pt.json | 10 +++++++++- language/ro.json | 8 ++++++++ language/ru.json | 8 ++++++++ language/sr.json | 8 ++++++++ language/sv.json | 8 ++++++++ language/tr.json | 8 ++++++++ language/vi.json | 8 ++++++++ language/zh-tw.json | 8 ++++++++ language/zh.json | 8 ++++++++ semantics.json | 4 +--- 32 files changed, 251 insertions(+), 5 deletions(-) diff --git a/language/.en.json b/language/.en.json index 2a9e4d6..839d83f 100644 --- a/language/.en.json +++ b/language/.en.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/af.json b/language/af.json index 2a9e4d6..839d83f 100644 --- a/language/af.json +++ b/language/af.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/ar.json b/language/ar.json index 073bd2c..404938e 100644 --- a/language/ar.json +++ b/language/ar.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "الوصف", "description": "نص قصير يتم عرضه مرة واحدة علي اثنين من البطاقات متساوية" diff --git a/language/bs.json b/language/bs.json index 522c820..3a1cbd6 100644 --- a/language/bs.json +++ b/language/bs.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Ista slika", "description": "Opcionalna slika koja se koristi umjestodvije iste slike." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Opis", "description": "Kratak tekst koji će biti prikazan čim se pronađu dvije iste karte." diff --git a/language/ca.json b/language/ca.json index 2a9e4d6..839d83f 100644 --- a/language/ca.json +++ b/language/ca.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/cs.json b/language/cs.json index 2a9e4d6..839d83f 100644 --- a/language/cs.json +++ b/language/cs.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/da.json b/language/da.json index 91a2e3a..aaca471 100644 --- a/language/da.json +++ b/language/da.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matchende billede", "description": "Valgfrit billede som match i stedet for at have to kort med det samme billede." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Beskrivelse", "description": "Valgfri tekst, som popper op, når to matchende billeder er fundet." diff --git a/language/de.json b/language/de.json index 7c5f0fe..5d96311 100644 --- a/language/de.json +++ b/language/de.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Beschreibung", "description": "Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." diff --git a/language/el.json b/language/el.json index 2a9e4d6..839d83f 100644 --- a/language/el.json +++ b/language/el.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/es.json b/language/es.json index 4a2c1de..c1e934c 100644 --- a/language/es.json +++ b/language/es.json @@ -18,6 +18,10 @@ "label": "Texto alternativo para la imagen", "description": "Describe lo que se puede ver en la foto. El texto es leído por una herramienta de conversion de texto a voz, a usuarios con discapacidad visual." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Imagen coincidente", "description": "Una imagen opcional para emparejar, en vez de usar dos tarjetas con la misma imagen." @@ -26,6 +30,10 @@ "label": "Texto alternativo para imagenes coincidentes", "description": "El texto es leído por una herramienta de conversion de texto a voz, a usuarios con discapacidad visual." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Descripción", "description": "Un breve texto opcional que aparecerá una vez se encuentren las dos cartas coincidentes." @@ -111,4 +119,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/et.json b/language/et.json index 2a9e4d6..839d83f 100644 --- a/language/et.json +++ b/language/et.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/fi.json b/language/fi.json index a692a57..d9b8a7c 100644 --- a/language/fi.json +++ b/language/fi.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Vastattava kuva", "description": "Valinnainen kuva johon verrata korttia sen sijaan, että kortille etsitään toista samaa kuvaa pariksi." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Selite", "description": "Valinnainen lyhyt teksti, joka näytetään kun oikea pari on löydetty." diff --git a/language/fr.json b/language/fr.json index f33d0c2..ce6fc6f 100644 --- a/language/fr.json +++ b/language/fr.json @@ -18,6 +18,10 @@ "label": "Texte alternatif pour l'image", "description": "Décrivez ce que représente l'image. Le texte est lu par la synthèse vocale." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Image correspondante", "description": "Une image facultative à comparer au lieu d'utiliser deux cartes avec la même image." @@ -26,6 +30,10 @@ "label": "Texte alternatif pour l'image correspondante", "description": "Décrivez ce que représente l'image correspondante. Le texte est lu par la synthèse vocale." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "Un texte court optionnel qui apparaîtra une fois que les deux cartes correspondantes auront été trouvées." diff --git a/language/he.json b/language/he.json index 2a9e4d6..839d83f 100644 --- a/language/he.json +++ b/language/he.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/hu.json b/language/hu.json index 2a9e4d6..839d83f 100644 --- a/language/hu.json +++ b/language/hu.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/it.json b/language/it.json index 9e2932a..274d6a9 100644 --- a/language/it.json +++ b/language/it.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Descrizione", "description": "Breve testo visualizzato quando due carte uguali vengono trovate." diff --git a/language/ja.json b/language/ja.json index d9883e8..624b3bb 100644 --- a/language/ja.json +++ b/language/ja.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "一致させる画像", "description": "同じ画像の2枚のカードを使用する代わりに、別に一致させるためのオプション画像" @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "説明", "description": "一致する2つのカードが見つかるとポップアップするオプションの短文テキスト。" diff --git a/language/ko.json b/language/ko.json index 2a9e4d6..839d83f 100644 --- a/language/ko.json +++ b/language/ko.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/nb.json b/language/nb.json index d5187ef..e4aa1b2 100644 --- a/language/nb.json +++ b/language/nb.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Tilhørende bilde", "description": "Et valgfritt bilde som brukes av kort nummer to istedenfor å bruke to kort med samme bilde." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Beskrivelse", "description": "En valgfri kort tekst som spretter opp når kort-paret er funnet." diff --git a/language/nl.json b/language/nl.json index c81981b..3888504 100644 --- a/language/nl.json +++ b/language/nl.json @@ -18,6 +18,10 @@ "label": "Bijpassende afbeelding", "description": "Een optionele afbeelding die past in plaats van 2 kaarten met dezelfde afbeelding." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Omschrijving", "description": "Een optionele korte tekst die zal verschijnen zodra de 2 overeenkomende kaarten zijn gevonden." @@ -26,6 +30,10 @@ "label": "De alternatieve tekst voor de bijpassende afbeelding", "description": "Omschrijf wat de afbeelding voorstelt. De tekst zal worden gelezen door tekst-naar-spraak tools voor slechtzienden." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Omschrijving", "description": "Een optionele korte tekst die zal verschijnen zodra de 2 overeenkomende kaarten zijn gevonden." diff --git a/language/nn.json b/language/nn.json index 2a9e4d6..839d83f 100644 --- a/language/nn.json +++ b/language/nn.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/pl.json b/language/pl.json index 2a9e4d6..839d83f 100644 --- a/language/pl.json +++ b/language/pl.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/pt.json b/language/pt.json index 8133dc7..2a6b9b0 100644 --- a/language/pt.json +++ b/language/pt.json @@ -18,6 +18,10 @@ "label": "Texto alternativo para a imagem", "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Imagem-par", "description": "Uma imagem opcional para ser combinada ao invés de utilizar dois cartões com a mesma imagem." @@ -26,6 +30,10 @@ "label": "Texto alternativo para a Imagem-par", "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Descrição", "description": "Um texto curto opcional que aparecerá quando duas cartas forem combinadas corretamente." @@ -111,4 +119,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/language/ro.json b/language/ro.json index 2a9e4d6..839d83f 100644 --- a/language/ro.json +++ b/language/ro.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/ru.json b/language/ru.json index 2a9e4d6..839d83f 100644 --- a/language/ru.json +++ b/language/ru.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/sr.json b/language/sr.json index 2a9e4d6..839d83f 100644 --- a/language/sr.json +++ b/language/sr.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/sv.json b/language/sv.json index 2a9e4d6..839d83f 100644 --- a/language/sv.json +++ b/language/sv.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/tr.json b/language/tr.json index 2a9e4d6..839d83f 100644 --- a/language/tr.json +++ b/language/tr.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/vi.json b/language/vi.json index 2a9e4d6..839d83f 100644 --- a/language/vi.json +++ b/language/vi.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Matching Image", "description": "An optional image to match against instead of using two cards with the same image." @@ -26,6 +30,10 @@ "label": "Alternative text for Matching Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Description", "description": "An optional short text that will pop up once the two matching cards are found." diff --git a/language/zh-tw.json b/language/zh-tw.json index 3db28bf..bbaf222 100644 --- a/language/zh-tw.json +++ b/language/zh-tw.json @@ -18,6 +18,10 @@ "label": "Alternative text for Image", "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "相稱圖示", "description": "可選用一張與主圖示相稱的圖示,並非使用兩張相同的圖示." @@ -26,6 +30,10 @@ "label": "相稱圖示的替代文字", "description": "請描述此張圖示中可以看到什麼. 此段文字將做為閱讀器導讀文字,對視障使用者更為友善." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "描述", "description": "選填。當找到兩張相稱圖示時所顯示的文字." diff --git a/language/zh.json b/language/zh.json index f7ac798..36e889d 100644 --- a/language/zh.json +++ b/language/zh.json @@ -18,6 +18,10 @@ "label": "配對圖像(非必要項)", "description": "如果遊戲中要配對的不是同一張圖像,那麼可以在這裡添加要配對的另一張圖像。" }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "配對成功文字(非必要項)", "description": "在找到配對時會跳出的文字訊息。" @@ -26,6 +30,10 @@ "label": "配對圖像的替代文字", "description": "在報讀器上用、或是配對圖像無法正常輸出時顯示的文字。" }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "配對成功文字(非必要項)", "description": "在找到配對時會跳出的文字訊息。" diff --git a/semantics.json b/semantics.json index 4108971..77b9c3b 100644 --- a/semantics.json +++ b/semantics.json @@ -34,7 +34,6 @@ "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "state": "new", "name": "audio", "type": "audio", "importance": "high", @@ -60,7 +59,6 @@ "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." }, { - "state": "new", "name": "matchAudio", "type": "audio", "importance": "low", @@ -225,4 +223,4 @@ } ] } -] +] \ No newline at end of file From 77d07a09a5649ef98b65d0247a23b947658f7e25 Mon Sep 17 00:00:00 2001 From: Oliver Tacke Date: Mon, 26 Nov 2018 12:48:17 +0100 Subject: [PATCH 35/48] HFP-2398 Add aria-label to popup close button --- popup.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/popup.js b/popup.js index 9d8d63d..b9ec59a 100644 --- a/popup.js +++ b/popup.js @@ -13,7 +13,7 @@ var closed; - var $popup = $('').appendTo($container); + var $popup = $('').appendTo($container); var $desc = $popup.find('.h5p-memory-desc'); var $top = $popup.find('.h5p-memory-top'); From 977ce375fca5301ea0490ed39e43878814fad9c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?I=C3=B1igo=20Zendegi?= Date: Sat, 8 Dec 2018 15:40:08 +0100 Subject: [PATCH 36/48] Update basque translation --- language/eu.json | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/language/eu.json b/language/eu.json index bd7e844..6102bae 100644 --- a/language/eu.json +++ b/language/eu.json @@ -16,7 +16,11 @@ }, { "label": "Irudiaren ordezko testua", - "description": "Deskribatu irudian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute." + "description": "Deskribatu irudian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute ikusmen urritasunak dituztenentzat." + }, + { + "label": "Audio Pista", + "description": "Karta itzultzen denean erreproduzitzeko aukerazko soinua." }, { "label": "Pareko irudia", @@ -24,7 +28,11 @@ }, { "label": "Pareko irudiaren ordezko irudia", - "description": "Deskribatu argazkian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute." + "description": "Deskribatu argazkian ikusi daitekeena. Testua irakurketa tresna automatikoek irakurriko dute ikusmen urritasunak dituztenentzat." + }, + { + "label": "Pareko Audio Pista", + "description": "Bigarren karta itzultzen denean erreproduzitzeko aukerazko soinua." }, { "label": "Deskribapena", From e0d639c406ba68fe82098e1f2a804f6727dab0e1 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Thu, 20 Dec 2018 16:19:44 +0100 Subject: [PATCH 37/48] HFP-1145 Add support for Audio Recorder in Editor --- library.json | 5 +++++ semantics.json | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/library.json b/library.json index 9092305..b8f7026 100644 --- a/library.json +++ b/library.json @@ -52,6 +52,11 @@ "machineName": "H5PEditor.VerticalTabs", "majorVersion": 1, "minorVersion": 3 + }, + { + "machineName": "H5PEditor.AudioRecorder", + "majorVersion": 1, + "minorVersion": 0 } ] } diff --git a/semantics.json b/semantics.json index 77b9c3b..b09372b 100644 --- a/semantics.json +++ b/semantics.json @@ -39,7 +39,8 @@ "importance": "high", "label": "Audio Track", "description": "An optional sound that plays when the card is turned.", - "optional": true + "optional": true, + "extraTabs": ["AudioRecorder"] }, { "name": "match", @@ -64,7 +65,8 @@ "importance": "low", "label": "Matching Audio Track", "description": "An optional sound that plays when the second card is turned.", - "optional": true + "optional": true, + "extraTabs": ["AudioRecorder"] }, { "name": "description", @@ -223,4 +225,4 @@ } ] } -] \ No newline at end of file +] From ca4d37c85c62494697ce893e6333d7d7f3e9cc0e Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Wed, 2 Jan 2019 11:40:27 +0100 Subject: [PATCH 38/48] HFP-1145 Stop audio when turning another card --- card.js | 35 +++++++++++++++++++---------------- memory-game.js | 11 ++++++++++- 2 files changed, 29 insertions(+), 17 deletions(-) diff --git a/card.js b/card.js index 9919018..81e9219 100644 --- a/card.js +++ b/card.js @@ -66,11 +66,13 @@ var handlePlaying = function () { if ($card) { $card.addClass('h5p-memory-audio-playing'); + self.trigger('audioplay'); } }; var handleStopping = function () { if ($card) { $card.removeClass('h5p-memory-audio-playing'); + self.trigger('audiostop'); } }; audioPlayer.addEventListener('play', handlePlaying); @@ -115,24 +117,20 @@ return; } - if (audioPlayer) { - audioPlayer.play(); - } - $card.addClass('h5p-flipped'); self.trigger('flip'); flippedState = true; + + if (audioPlayer) { + audioPlayer.play(); + } }; /** * Flip card back. */ self.flipBack = function () { - if (audioPlayer) { - audioPlayer.pause(); - audioPlayer.currentTime = 0; - } - + self.stopAudio(); self.updateLabel(null, null, true); // Reset card label $card.removeClass('h5p-flipped'); flippedState = false; @@ -150,11 +148,7 @@ * Reset card to natural state */ self.reset = function () { - if (audioPlayer) { - audioPlayer.pause(); - audioPlayer.currentTime = 0; - } - + self.stopAudio(); self.updateLabel(null, null, true); // Reset card label flippedState = false; removedState = false; @@ -236,8 +230,7 @@ $card.children('.h5p-back') .click(function () { if ($card.hasClass('h5p-memory-audio-playing')) { - audioPlayer.pause(); - audioPlayer.currentTime = 0; + self.stopAudio(); } else { audioPlayer.play(); @@ -289,6 +282,16 @@ self.isRemoved = function () { return removedState; }; + + /** + * Stop any audio track that might be playing. + */ + self.stopAudio = function () { + if (audioPlayer) { + audioPlayer.pause(); + audioPlayer.currentTime = 0; + } + }; }; // Extends the event dispatcher diff --git a/memory-game.js b/memory-game.js index 07bbd0d..bf19a3e 100644 --- a/memory-game.js +++ b/memory-game.js @@ -22,7 +22,7 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Initialize event inheritance EventDispatcher.call(self); - var flipped, timer, counter, popup, $bottom, $taskComplete, $feedback, $wrapper, maxWidth, numCols; + var flipped, timer, counter, popup, $bottom, $taskComplete, $feedback, $wrapper, maxWidth, numCols, audioCard; var cards = []; var flipBacks = []; // Que of cards to be flipped back var numFlipped = 0; @@ -218,6 +218,9 @@ H5P.MemoryGame = (function (EventDispatcher, $) { */ var addCard = function (card, mate) { card.on('flip', function () { + if (audioCard) { + audioCard.stopAudio(); + } // Always return focus to the card last flipped for (var i = 0; i < cards.length; i++) { @@ -260,6 +263,12 @@ H5P.MemoryGame = (function (EventDispatcher, $) { // Count number of cards turned counter.increment(); }); + card.on('audioplay', function () { + audioCard = card; + }); + card.on('audiostop', function () { + audioCard = undefined; + }); /** * Create event handler for moving focus to the next or the previous From e5ce754c92240581c5415ea4b09c194ecfa4eb07 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Wed, 2 Jan 2019 11:47:35 +0100 Subject: [PATCH 39/48] HFP-1145 Fix always stop playing on play --- memory-game.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/memory-game.js b/memory-game.js index bf19a3e..4b63def 100644 --- a/memory-game.js +++ b/memory-game.js @@ -264,6 +264,9 @@ H5P.MemoryGame = (function (EventDispatcher, $) { counter.increment(); }); card.on('audioplay', function () { + if (audioCard) { + audioCard.stopAudio(); + } audioCard = card; }); card.on('audiostop', function () { From 2f44a88c45bc21b0e36f71de73e3ab6683fedb6c Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Fri, 4 Jan 2019 14:58:46 +0100 Subject: [PATCH 40/48] Update language/pt-br.json --- language/pt-br.json | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/language/pt-br.json b/language/pt-br.json index 8133dc7..c7086ed 100644 --- a/language/pt-br.json +++ b/language/pt-br.json @@ -18,6 +18,10 @@ "label": "Texto alternativo para a imagem", "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, + { + "label": "Audio Track", + "description": "An optional sound that plays when the card is turned." + }, { "label": "Imagem-par", "description": "Uma imagem opcional para ser combinada ao invés de utilizar dois cartões com a mesma imagem." @@ -26,6 +30,10 @@ "label": "Texto alternativo para a Imagem-par", "description": "Descreva o que pode ser visto na foto. O texto será lido para os usuários que necessitam utilizar leitores de tela." }, + { + "label": "Matching Audio Track", + "description": "An optional sound that plays when the second card is turned." + }, { "label": "Descrição", "description": "Um texto curto opcional que aparecerá quando duas cartas forem combinadas corretamente." From 7872731e344234b89c691f6006062b737d1ef428 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Wed, 9 Jan 2019 10:13:14 +0100 Subject: [PATCH 41/48] Rename 'extraTabs' to 'widgetExtensions' in semantics --- semantics.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/semantics.json b/semantics.json index b09372b..3e73546 100644 --- a/semantics.json +++ b/semantics.json @@ -40,7 +40,7 @@ "label": "Audio Track", "description": "An optional sound that plays when the card is turned.", "optional": true, - "extraTabs": ["AudioRecorder"] + "widgetExtensions": ["AudioRecorder"] }, { "name": "match", @@ -66,7 +66,7 @@ "label": "Matching Audio Track", "description": "An optional sound that plays when the second card is turned.", "optional": true, - "extraTabs": ["AudioRecorder"] + "widgetExtensions": ["AudioRecorder"] }, { "name": "description", From db6a3c33da608e1c2cbd6df2fd919fe71fac6ddc Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Wed, 9 Jan 2019 13:01:08 +0100 Subject: [PATCH 42/48] Bump - prepare release --- library.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library.json b/library.json index b8f7026..64a99b1 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 3, - "patchVersion": 0, + "patchVersion": 1, "runnable": 1, "author": "Joubel", "license": "MIT", From 3c361e8d6d4abbf81a2c0cf0153b606b0dbc696f Mon Sep 17 00:00:00 2001 From: JohanLTPT Date: Mon, 8 Apr 2019 19:58:29 +0300 Subject: [PATCH 43/48] Added estonian translation --- language/et.json | 102 +++++++++++++++++++++++------------------------ 1 file changed, 51 insertions(+), 51 deletions(-) diff --git a/language/et.json b/language/et.json index 839d83f..120ef99 100644 --- a/language/et.json +++ b/language/et.json @@ -3,118 +3,118 @@ { "widgets": [ { - "label": "Default" + "label": "Vaikimisi" } ], - "label": "Cards", - "entity": "card", + "label": "Kaardid", + "entity": "kaart", "field": { - "label": "Card", + "label": "Kaart", "fields": [ { - "label": "Image" + "label": "Pilt" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Pildi alternatiivtekst", + "description": "Kirjelda, mis pildil näha on. Tekst on mõeldud vaegnägijaile tekstilugeriga kuulamiseks." }, { - "label": "Audio Track", - "description": "An optional sound that plays when the card is turned." + "label": "Heliriba", + "description": "Valikheli, mida mängitakse kaardi pööramisel." }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Sobituv pilt", + "description": "Valikuline pilt võrdlemiseks, selmet kasutada kahte kaarti sama pildiga." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Sobituva pildi alternatiivtekst", + "description": "Kirjelda, mis pildil näha on. Tekst on mõeldud vaegnägijaile tekstilugeriga kuulamiseks." }, { - "label": "Matching Audio Track", - "description": "An optional sound that plays when the second card is turned." + "label": "Sobituv heliriba", + "description": "Valikheli, mida mängitakse teise kaardi pööramisel." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Kirjeldus", + "description": "Valikuline lühitekst, mida näidatakse hüpikaknas peale kahe sobituva kaardi leidmist." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Käitumisseaded", + "description": "Need valikud võimaldavad sul kontrollida mängu käitumist.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Aseta kaardid väljakule", + "description": "Proovib sobitada ridade ja veergude arvu kaartide asetamisel. Peale seda muudetakse kaartide suurust, et täita neid hoidev raam." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Kasutatav kaartide arv", + "description": "Määrates selle arvu kahest suuremaks valib mäng kaartide loetelust juhuslikud kaardid." }, { - "label": "Add button for retrying when the game is over" + "label": "Lisa Proovi uuesti nupp lõppenud mängule" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "Välimus", + "description": "Säti mängu visuaali.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Teemavärv", + "description": "Vali oma mängu teemavärv.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Kaardi taust", + "description": "Kasuta kohandatud kaarditausta." } ] }, { - "label": "Localization", + "label": "Kohandamine", "fields": [ { - "label": "Card turns text", - "default": "Card turns" + "label": "Kaardi pööramise tekst", + "default": "Kaart pöörab" }, { - "label": "Time spent text", - "default": "Time spent" + "label": "Aega kulunud tekst", + "default": "Aega kulunud" }, { - "label": "Feedback text", - "default": "Good work!" + "label": "Tagasiside tekst", + "default": "Hea töö!" }, { - "label": "Try again button text", - "default": "Try again?" + "label": "Proovi uuesti nupu tekst", + "default": "Proovida uuesti?" }, { - "label": "Close button label", - "default": "Close" + "label": "Sulge nupu tekst", + "default": "Sulge" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Mängu pealkiri", + "default": "Mälumäng. Leida sobituvad kaardid." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Mäng on lõppenud silt", + "default": "Kõik kaardid on leitud." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Kaardi indeksi silt", + "default": "Kaart %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Kaart pööramata silt", + "default": "Pööramata." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Kaart sobitub silt", + "default": "Vaste leitud." } ] } From 0cae222048f36d073ee1a545dc617fdd69aaedfc Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Tue, 9 Apr 2019 15:00:47 +0200 Subject: [PATCH 44/48] Bump (prepare language release) --- library.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/library.json b/library.json index 64a99b1..8edd68c 100644 --- a/library.json +++ b/library.json @@ -3,7 +3,7 @@ "description": "See how many cards you can remember!", "majorVersion": 1, "minorVersion": 3, - "patchVersion": 1, + "patchVersion": 2, "runnable": 1, "author": "Joubel", "license": "MIT", @@ -59,4 +59,4 @@ "minorVersion": 0 } ] -} +} \ No newline at end of file From 3a551aa21f22c86398b9417b9f60c362049edc08 Mon Sep 17 00:00:00 2001 From: Waltteri Turunen <3134372+WTurunen@users.noreply.github.com> Date: Wed, 10 Apr 2019 09:03:14 +0300 Subject: [PATCH 45/48] Create zh-hans.json --- language/zh-hans.json | 122 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 language/zh-hans.json diff --git a/language/zh-hans.json b/language/zh-hans.json new file mode 100644 index 0000000..7ddf05f --- /dev/null +++ b/language/zh-hans.json @@ -0,0 +1,122 @@ +{ + "semantics": [ + { + "widgets": [ + { + "label": "预设" + } + ], + "label": "所有卡片", + "entity": "卡片", + "field": { + "label": "卡片", + "fields": [ + { + "label": "图像" + }, + { + "label": "配对图像(非必要项)", + "description": "如果游戏中要配对的不是同一张图像,那么可以在这里添加要配对的另一张图像。" + }, + { + "label": "音轨", + "description": "翻转卡片时可选声音." + }, + { + "label": "配对成功文字(非必要项)", + "description": "在找到配对时会显示的文字讯息。" + }, + { + "label": "配对图像的替代文字", + "description": "在报读器上用、或是配对图像无法正常输出时的文字。" + }, + { + "label": "匹配音轨", + "description": "翻转第二张卡片时可选声音." + }, + { + "label": "配对成功文字(非必要项)", + "description": "在找到配对时会显示的文字讯息。" + } + ] + } + }, + { + "label": "行为设置", + "description": "让你控制游戏行为的一些设置。", + "fields": [ + { + "label": "将所有卡片显示在方形容器", + "description": "在布置卡片时,将尝试匹配列数和行数。之后,卡片将被缩放以适合容器。" + }, + { + "label": "卡片的使用数量", + "description": "游戏中配对的卡片组合数量,设定后会从卡片集中随机挑选指定组合数,数字必须大于 2。" + }, + { + "label": "显示「再试一次」按钮" + } + ] + }, + { + "label": "外观", + "description": "控制游戏的视觉效果。", + "fields": [ + { + "label": "主题色调", + "description": "选择游戏环境要使用的色调。", + "default": "#909090" + }, + { + "label": "背面图像(非必要项)", + "description": "允许自定义卡片背景要使用的图片。" + } + ] + }, + { + "label": "本地化", + "fields": [ + { + "label": "翻牌次数的显示文字", + "default": "翻牌次数" + }, + { + "label": "花费时间的显示文字", + "default": "花费时间" + }, + { + "label": "游戏过关的显示文字", + "default": "干得好!" + }, + { + "label": "重试按钮的显示文字", + "default": "再试一次" + }, + { + "label": "关闭按钮的显示文字", + "default": "关闭" + }, + { + "label": "游戏说明的显示文字", + "default": "卡片记忆游戏,找出配对的所有图片吧!" + }, + { + "label": "游戏结束的显示文字", + "default": "已配对完所有卡片。" + }, + { + "label": "卡片索引的显示文字", + "default": "%num: 张卡片" + }, + { + "label": "卡片未翻开的显示文字", + "default": "还没翻开。" + }, + { + "label": "卡片已配对的显示文字", + "default": "配对成功。" + } + ] + } + ] +} From 4d2abc1839cb89cec4dc4135dd4560f34b1cff85 Mon Sep 17 00:00:00 2001 From: Waltteri Turunen <3134372+WTurunen@users.noreply.github.com> Date: Wed, 10 Apr 2019 09:03:26 +0300 Subject: [PATCH 46/48] Rename zh.json to zh-hant.json --- language/{zh.json => zh-hant.json} | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename language/{zh.json => zh-hant.json} (99%) diff --git a/language/zh.json b/language/zh-hant.json similarity index 99% rename from language/zh.json rename to language/zh-hant.json index 36e889d..f39466e 100644 --- a/language/zh.json +++ b/language/zh-hant.json @@ -119,4 +119,4 @@ ] } ] -} \ No newline at end of file +} From 98afe4d8302b275f425268bb7eccb06279a12480 Mon Sep 17 00:00:00 2001 From: Weblate Date: Mon, 22 Apr 2019 19:25:44 +0000 Subject: [PATCH 47/48] =?UTF-8?q?Sebastian=20Rettig=20?= =?UTF-8?q?=20updated=20German=20translation=20using=20Weblate=20@=20Deuts?= =?UTF-8?q?che=20H5P-=C3=9Cbersetzungscommunity.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Translate-URL: http://deutsche-h5p-uebersetzungscommunity.tk/projects/h5p/h5p-memory-game/de/ Sebastian Rettig updated German translation using Weblate @ Deutsche H5P-Übersetzungscommunity. Translate-URL: http://deutsche-h5p-uebersetzungscommunity.tk/projects/h5p/h5p-memory-game/de/ --- language/de.json | 92 ++++++++++++++++++++++++------------------------ 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/language/de.json b/language/de.json index 5d96311..fdff016 100644 --- a/language/de.json +++ b/language/de.json @@ -3,11 +3,11 @@ { "widgets": [ { - "label": "Default" + "label": "Eingabemaske" } ], "label": "Karten", - "entity": "karte", + "entity": "Karte", "field": { "label": "Karte", "fields": [ @@ -15,108 +15,108 @@ "label": "Bild" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Alternativtext für das Bild", + "description": "Beschreibt, was im Bild zu sehen ist. Dieser Text wird von Vorlesewerkzeugen für Sehbehinderte genutzt." }, { - "label": "Audio Track", - "description": "An optional sound that plays when the card is turned." + "label": "Ton", + "description": "Optionaler Ton, der abgespielt wird, wenn die Karte umgedreht wird." }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Zugehöriges Bild", + "description": "Ein optionales zweites Bild, das mit dem ersten ein Paar bildet, anstatt zweimal das selbe Bild zu verwenden." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Alternativtext für das zweite Bild", + "description": "Beschreibt, was im Bild zu sehen ist. Dieser Text wird von Vorlesewerkzeugen für Sehbehinderte genutzt." }, { - "label": "Matching Audio Track", - "description": "An optional sound that plays when the second card is turned." + "label": "Ton zum zweiten Bild", + "description": "Optionaler Ton, der abgespielt wird, wenn die zweite Karte umgedreht wird." }, { "label": "Beschreibung", - "description": "Ein kurzer Text, der angezeigt wird, sobald zwei identische Karten gefunden werden." + "description": "Ein kurzer optionaler Text, der angezeigt wird, wenn das Kartenpaar gefunden wurde." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Verhaltenseinstellungen", + "description": "Diese Optionen legen fest, wie das Spiel im Detail funktioniert.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Karten in einem Quadrat anordnen", + "description": "Versucht die Karten in der gleichen Zahl von Reihen und Spalten zu anzuordnen. Danach wird die Kartengröße an den verfügbaren Platz angepasst." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Anzahl der zu verwendenden Karten", + "description": "Wenn die Anzahl größer als 2 ist, werden zufällige Karten aus der Liste ausgewählt." }, { - "label": "Add button for retrying when the game is over" + "label": "\"Wiederholen\"-Button anzeigen" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "Erscheinungsbild", + "description": "Legt fest, wie das Spiel aussieht.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Themenfarbe", + "description": "Wähle eine Farbe, um das Spiel zu individualisieren.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Kartenrückseite", + "description": "Verwende eine benutzerdefinierte Rückseite für die Karten." } ] }, { - "label": "Übersetzung", + "label": "Bezeichnungen und Beschriftungen", "fields": [ { - "label": "Text für die Anzahl der Züge", + "label": "Text mit der Anzahl der Züge", "default": "Züge" }, { - "label": "Text für die benötigte Zeit", + "label": "Text mit der bisher benötigten Zeit", "default": "Benötigte Zeit" }, { - "label": "Text als Rückmeldung", - "default": "Gute Arbeit!" + "label": "Rückmeldungstext", + "default": "Gut gemacht!" }, { - "label": "Try again button text", - "default": "Reset" + "label": "Beschriftung des \"Wiederholen\"-Buttons", + "default": "Nochmal spielen" }, { - "label": "Close button label", - "default": "Close" + "label": "Beschriftung des \"Schließen\"-Buttons", + "default": "Schließen" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Bezeichnung des Spiels", + "default": "Memory - Finde die Kartenpaare!" }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Meldung, wenn das Spiel abgeschlossen wurde", + "default": "Du hast alle Kartenpaare gefunden!" }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Beschriftung der Kartennummer", + "default": "Karte %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Text, wenn eine Karte wieder zugedeckt wurde", + "default": "Zugedeckt." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Text, wenn ein Paar gefunden wurde", + "default": "Paar gefunden." } ] } ] -} \ No newline at end of file +} From 8fe9642726756fede368ec3e31b46152b306c2e5 Mon Sep 17 00:00:00 2001 From: maxtetdev Date: Tue, 23 Apr 2019 10:06:34 +0300 Subject: [PATCH 48/48] Update ru.json --- language/ru.json | 104 +++++++++++++++++++++++------------------------ 1 file changed, 52 insertions(+), 52 deletions(-) diff --git a/language/ru.json b/language/ru.json index 839d83f..2e5e965 100644 --- a/language/ru.json +++ b/language/ru.json @@ -3,120 +3,120 @@ { "widgets": [ { - "label": "Default" + "label": "По умолчанию" } ], - "label": "Cards", - "entity": "card", + "label": "Карточки", + "entity": "карточка", "field": { - "label": "Card", + "label": "Карточка", "fields": [ { - "label": "Image" + "label": "Изображение" }, { - "label": "Alternative text for Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Альтернативный текст для изображения", + "description": "Опишите, что видно на фото. Текст читается с помощью инструментов преобразования текста в речь, необходимых пользователям с нарушениями зрения." }, { - "label": "Audio Track", - "description": "An optional sound that plays when the card is turned." + "label": "Звуковая дорожка", + "description": "Дополнительный звук, который воспроизводится при повороте карточки." }, { - "label": "Matching Image", - "description": "An optional image to match against instead of using two cards with the same image." + "label": "Соответствующее изображения", + "description": "Необязательное изображение для сравнения вместо использования двух карточек с одинаковым изображением." }, { - "label": "Alternative text for Matching Image", - "description": "Describe what can be seen in the photo. The text is read by text-to-speech tools needed by visually impaired users." + "label": "Альтернативный текст для соответствующего изображения", + "description": "Describe what can be seen in the photo. Текст читается с помощью инструментов преобразования текста в речь, необходимых пользователям с нарушениями зрения." }, { - "label": "Matching Audio Track", - "description": "An optional sound that plays when the second card is turned." + "label": "Соответствующая звуковая дорожка", + "description": "Дополнительный звук, который воспроизводится при повороте второй карточки." }, { - "label": "Description", - "description": "An optional short text that will pop up once the two matching cards are found." + "label": "Описание", + "description": "Дополнительный короткий текст, который появится после того, как найдены две подходящие карточки." } ] } }, { - "label": "Behavioural settings", - "description": "These options will let you control how the game behaves.", + "label": "Настройки поведения", + "description": "Эти параметры позволят вам контролировать поведение игры.", "fields": [ { - "label": "Position the cards in a square", - "description": "Will try to match the number of columns and rows when laying out the cards. Afterward, the cards will be scaled to fit the container." + "label": "Положение карточки на площадке", + "description": "Постарайтесь сопоставить количество столбцов и строк при разложении карточек. После чего карточки будут масштабироваться до размера контейнера." }, { - "label": "Number of cards to use", - "description": "Setting this to a number greater than 2 will make the game pick random cards from the list of cards." + "label": "Количество карточек для использования", + "description": "Если установить значение больше 2, игра будет выбирать случайные карточки из списка." }, { - "label": "Add button for retrying when the game is over" + "label": "Добавить кнопку для повтора, когда игра закончена" } ] }, { - "label": "Look and feel", - "description": "Control the visuals of the game.", + "label": "Смотреть и чувствовать", + "description": "Управление визуальными эффектами игры.", "fields": [ { - "label": "Theme Color", - "description": "Choose a color to create a theme for your card game.", + "label": "Цвет темы", + "description": "Выберите цвет, чтобы создать тему для своей карточной игры.", "default": "#909090" }, { - "label": "Card Back", - "description": "Use a custom back for your cards." + "label": "Обратная сторона карточки", + "description": "Использование произвольной спины для своих карточек." } ] }, { - "label": "Localization", + "label": "Локализация", "fields": [ { - "label": "Card turns text", - "default": "Card turns" + "label": "Текст перевернутой карточки", + "default": "Карточка перевернута" }, { - "label": "Time spent text", - "default": "Time spent" + "label": "Текст затраченного времени", + "default": "Затраченное время" }, { - "label": "Feedback text", - "default": "Good work!" + "label": "Текст обратной связи", + "default": "Хорошая работа!" }, { - "label": "Try again button text", - "default": "Try again?" + "label": "Текст кнопки повтора", + "default": "Попробовать еще раз?" }, { - "label": "Close button label", - "default": "Close" + "label": "Надпись кнопки закрытия", + "default": "Закрыть" }, { - "label": "Game label", - "default": "Memory Game. Find the matching cards." + "label": "Надпись игры", + "default": "Игра на запоминание. Найти подходящие карточки." }, { - "label": "Game finished label", - "default": "All of the cards have been found." + "label": "Надпись завершения игры", + "default": "Все карточки были найдены." }, { - "label": "Card indexing label", - "default": "Card %num:" + "label": "Надпись номера карточки", + "default": "Карточка %num:" }, { - "label": "Card unturned label", - "default": "Unturned." + "label": "Надпись неперевернутой карточки", + "default": "Неперевернутая." }, { - "label": "Card matched label", - "default": "Match found." + "label": "Надпись подходящей карточки", + "default": "Соответствие найдено." } ] } ] -} \ No newline at end of file +}