Skip to content

Commit 7acc564

Browse files
committed
Merge Version6.2a into master
2 parents 1f3e6a7 + 86aeb3f commit 7acc564

5 files changed

Lines changed: 268 additions & 9 deletions

File tree

DistFiles/localization/en/Bloom.xlf

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6096,6 +6096,18 @@ is mostly status, which shows on the Collection Tab -->
60966096
<source xml:lang="en">Widget Page</source>
60976097
<note>ID: TemplateBooks.PageLabel.Widget Page</note>
60986098
</trans-unit>
6099+
<trans-unit id="TemplateBooks.PageLabel.Drag Letters to Targets" sil:dynamic="true" translate="no">
6100+
<source xml:lang="en">Drag Letters to Targets</source>
6101+
<note>ID: TemplateBooks.PageLabel.Drag Letters to Targets</note>
6102+
</trans-unit>
6103+
<trans-unit id="TemplateBooks.PageLabel.DragImagesTargets" sil:dynamic="true" translate="no">
6104+
<source xml:lang="en">Drag Images to Targets</source>
6105+
<note>ID: TemplateBooks.PageLabel.DragImagesTargets</note>
6106+
</trans-unit>
6107+
<trans-unit id="TemplateBooks.PageLabel.DragImagesShadows" sil:dynamic="true" translate="no">
6108+
<source xml:lang="en">Drag Images to Shadows</source>
6109+
<note>ID: TemplateBooks.PageLabel.DragImagesShadows</note>
6110+
</trans-unit>
60996111
<trans-unit id="TemplateBooks.Wall Calendar.TitleOfSetupDialog">
61006112
<source xml:lang="en">Setup</source>
61016113
<note>ID: TemplateBooks.Wall Calendar.TitleOfSetupDialog</note>

src/BloomBrowserUI/bookEdit/js/CanvasElementContextControls.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,10 @@ const CanvasElementContextControls: React.FunctionComponent<{
187187
menuOptions.unshift({
188188
l10nId: "EditTab.Toolbox.ComicTool.Options.Duplicate",
189189
english: "Duplicate",
190-
onClick: theOneCanvasElementManager?.duplicateCanvasElement,
190+
onClick: () => {
191+
if (!props.canvasElement) return;
192+
makeDuplicateOfDragBubble();
193+
},
191194
icon: <DuplicateIcon css={getMenuIconCss()} />
192195
});
193196
}

src/BloomBrowserUI/bookEdit/toolbox/games/GameTool.tsx

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,6 +1113,8 @@ const DragActivityControls: React.FunctionComponent<{
11131113
// that shows all the options and go back to hiding it for this.
11141114
//activityType !== "drag-image-to-target";
11151115
const showImageDraggable = activityType !== "drag-letter-to-target";
1116+
const showVideoDraggable = true;
1117+
const showSoundDraggable = activityType !== "drag-letter-to-target";
11161118
return (
11171119
<ThemeProvider theme={toolboxTheme}>
11181120
{props.activeTab === startTabIndex && (
@@ -1147,18 +1149,20 @@ const DragActivityControls: React.FunctionComponent<{
11471149
strokeColor={kBloomBlue}
11481150
showOuterRectangle={true}
11491151
/>
1150-
<CanvasElementVideoItem
1151-
makeTarget={
1152-
activityType !==
1153-
"drag-word-chooser-slider"
1154-
}
1155-
showOuterRectangle={true}
1156-
/>
1152+
{showVideoDraggable && (
1153+
<CanvasElementVideoItem
1154+
makeTarget={
1155+
activityType !==
1156+
"drag-word-chooser-slider"
1157+
}
1158+
showOuterRectangle={true}
1159+
/>
1160+
)}
11571161
</Fragment>
11581162
)}
11591163
</CanvasElementItemRow>
11601164
<CanvasElementItemRow>
1161-
{showImageDraggable && (
1165+
{showSoundDraggable && (
11621166
<CanvasElementSoundItem />
11631167
)}
11641168
<CanvasElementTextItem

src/content/templates/template books/Games/Games.html

Lines changed: 227 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -837,5 +837,232 @@
837837
</button>
838838
</div>
839839
</div>
840+
841+
<div
842+
class="bloom-page customPage bloom-ignoreForReaderStats bloom-interactive-page enterprise-only no-margin-page numberedPage side-right Device16x9Landscape bloom-monolingual"
843+
id="B902D56E-8AF7-43CF-9F2A-E473D0971CC7"
844+
data-page="extra"
845+
data-analyticscategories="drag-activity"
846+
data-activity="drag-image-to-target"
847+
data-tool-id="game"
848+
data-pagelineage="3325A8B6-EA15-4FB7-9F8D-271D7B3C8D57"
849+
data-page-number="1"
850+
lang=""
851+
data-correct-sound="correct_tada-fanfare-a_pixabay.webm"
852+
data-wrong-sound="wrong_twoDownElectronic2_pixabay.webm"
853+
data-show-answers-in-targets="true"
854+
data-show-targets-during-play="false"
855+
data-show-target-as-shadow="true"
856+
>
857+
<div
858+
class="pageLabel"
859+
lang="en"
860+
data-i18n="TemplateBooks.PageLabel.DragImagesShadows"
861+
>
862+
Drag Images to Shadows
863+
</div>
864+
<div class="pageDescription" lang="en"></div>
865+
866+
<div class="marginBox">
867+
<div class="split-pane-component-inner">
868+
<div
869+
class="bloom-canvas bloom-has-canvas-element"
870+
data-title="For the current paper size: • The image container is 652 x 358 dots. • For print publications, you want between 300-600 DPI (Dots Per Inch). • An image with 2038 x 1119 dots would fill this container at 300 DPI."
871+
title="For the current paper size: • The image container is 652 x 358 dots. • For print publications, you want between 300-600 DPI (Dots Per Inch). • An image with 2038 x 1119 dots would fill this container at 300 DPI."
872+
>
873+
<img src="placeHolder.png" alt="" />
874+
875+
<div
876+
class="bloom-canvas-element bloom-gif drag-item-correct ui-resizable ui-draggable"
877+
style="
878+
height: 223.898px;
879+
left: 373.297px;
880+
top: 73.0508px;
881+
width: 233px;
882+
position: absolute;
883+
"
884+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:14,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
885+
>
886+
<div
887+
tabindex="0"
888+
class="bloom-imageContainer"
889+
title=""
890+
>
891+
<img
892+
src="smiling-flowers.gif"
893+
alt=""
894+
data-copyright="Copyright © 2024, Ilona Spaeder"
895+
data-creator="Ilona Spaeder"
896+
data-license="Custom License"
897+
/>
898+
</div>
899+
</div>
900+
901+
<div
902+
class="bloom-canvas-element ui-resizable ui-draggable"
903+
style="left: 5px; top: 5px; width: 364px; height: 50px; position: absolute;"
904+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:16,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
905+
>
906+
<div
907+
class="bloom-translationGroup bloom-leadingElement bloom-show-en-when-blank"
908+
data-default-languages="V"
909+
style="font-size: 21.3333px;"
910+
data-hasqtip="true"
911+
>
912+
<div
913+
class="bloom-editable GameHeader-style bloom-visibility-code-on bloom-content1 bloom-contentNational1"
914+
lang="en"
915+
tabindex="0"
916+
spellcheck="false"
917+
role="textbox"
918+
aria-label="false"
919+
style="min-height: 32.01px;"
920+
contenteditable="true"
921+
data-languagetipcontent="English"
922+
>
923+
<p>​Drag the pictures to their shadows</p>
924+
</div>
925+
</div>
926+
</div>
927+
<div
928+
class="bloom-canvas-element bloom-gif drag-item-wrong ui-resizable ui-draggable"
929+
style="
930+
height: 260px;
931+
left: 360.333px;
932+
top: 22px;
933+
width: 260px;
934+
position: absolute;
935+
"
936+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:18,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
937+
>
938+
<div
939+
tabindex="0"
940+
class="bloom-imageContainer"
941+
title=""
942+
>
943+
<img
944+
src="sad-face.gif"
945+
alt=""
946+
data-copyright="Copyright © 2022, Ilona Spaeder"
947+
data-creator="Ilona Spaeder"
948+
data-license="Custom License"
949+
/>
950+
</div>
951+
</div>
952+
953+
<div
954+
class="bloom-canvas-element ui-resizable ui-draggable"
955+
style="left: 147.578px; top: 109.766px; width: 61px; height: 60px;"
956+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:11,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
957+
data-draggable-id="b12rlzh"
958+
>
959+
<div
960+
tabindex="0"
961+
class="bloom-imageContainer"
962+
data-title="For the current paper size: • The image container is 220 x 193 dots. • For print publications, you want between 300-600 DPI (Dots Per Inch). • An image with 688 x 604 dots would fill this container at 300 DPI."
963+
title=""
964+
>
965+
<img
966+
src="placeHolder.png"
967+
alt=""
968+
data-copyright=""
969+
data-creator=""
970+
data-license=""
971+
/>
972+
</div>
973+
</div>
974+
<div
975+
data-target-of="b12rlzh"
976+
tabindex="0"
977+
style="left: 60px; top: 264px; width: 61px; height: 60px;"
978+
></div>
979+
980+
<div
981+
class="bloom-canvas-element ui-resizable ui-draggable"
982+
style="left: 239.313px; top: 86.75px; width: 61px; height: 60px;"
983+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:12,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
984+
data-draggable-id="muozas1"
985+
>
986+
<div
987+
tabindex="0"
988+
class="bloom-imageContainer bloom-leadingElement"
989+
data-title="For the current paper size: • The image container is 220 x 193 dots. • For print publications, you want between 300-600 DPI (Dots Per Inch). • An image with 688 x 604 dots would fill this container at 300 DPI."
990+
title=""
991+
>
992+
<img
993+
src="placeHolder.png"
994+
alt=""
995+
data-copyright=""
996+
data-creator=""
997+
data-license=""
998+
/>
999+
</div>
1000+
</div>
1001+
<div
1002+
data-target-of="muozas1"
1003+
tabindex="0"
1004+
style="left: 153.32px; top: 264px; width: 61px; height: 60px;"
1005+
></div>
1006+
1007+
<div
1008+
class="bloom-canvas-element ui-resizable ui-draggable"
1009+
style="left: 49px; top: 90.6563px; width: 61px; height: 60px; position: absolute;"
1010+
data-bubble="{`version`:`1.0`,`style`:`none`,`tails`:[],`level`:13,`backgroundColors`:[`transparent`],`shadowOffset`:0}"
1011+
data-draggable-id="lkbg233"
1012+
>
1013+
<div
1014+
tabindex="0"
1015+
class="bloom-imageContainer bloom-leadingElement"
1016+
data-title="For the current paper size: • The image container is 220 x 193 dots. • For print publications, you want between 300-600 DPI (Dots Per Inch). • An image with 688 x 604 dots would fill this container at 300 DPI."
1017+
title=""
1018+
>
1019+
<img
1020+
src="placeHolder.png"
1021+
alt=""
1022+
data-copyright=""
1023+
data-creator=""
1024+
data-license=""
1025+
/>
1026+
</div>
1027+
</div>
1028+
<div
1029+
data-target-of="lkbg233"
1030+
tabindex="0"
1031+
style="left: 246px; top: 264px; width: 61px; height: 60px;"
1032+
></div>
1033+
</div>
1034+
</div>
1035+
<button
1036+
class="check-button page-content game-button"
1037+
style="right: 10px; bottom: 10px;"
1038+
>
1039+
<img src="Check Answer Symbol.svg" />
1040+
</button>
1041+
<button
1042+
class="try-again-button page-content game-button"
1043+
style="right: 130px; bottom: 10px;"
1044+
>
1045+
<img src="Try Again Symbol.svg" />
1046+
</button>
1047+
<button
1048+
class="show-correct-button page-content game-button"
1049+
style="right: 70px; bottom: 10px;"
1050+
>
1051+
<img src="Show Answer Symbol.svg" />
1052+
</button>
1053+
<button
1054+
class="page-content page-turn-button turn-right"
1055+
style="right: 10px; top: calc(50% - 12px);"
1056+
>
1057+
<img src="Page Nav.svg" />
1058+
</button>
1059+
<button
1060+
class="page-content page-turn-button turn-left"
1061+
style="left: 10px; top: calc(50% - 12px);"
1062+
>
1063+
<img src="Page Nav.svg" />
1064+
</button>
1065+
</div>
1066+
</div>
8401067
</body>
8411068
</html>

src/content/templates/template books/Games/Games.less

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,19 @@
414414
pointer-events: none;
415415
}
416416

417+
// In the drag-image-to-target game, we want to show shadows of target images everywhere
418+
// if data-show-target-as-shadow is set to true.
419+
.bloom-page[data-activity="drag-image-to-target"][data-show-target-as-shadow="true"]
420+
[data-target-of]:has(img) {
421+
background-color: unset;
422+
423+
.bloom-targetWrapper {
424+
filter: grayscale(100%) brightness(0%);
425+
mix-blend-mode: normal;
426+
opacity: 100%;
427+
}
428+
}
429+
417430
.bloom-targetWrapper {
418431
height: 100%;
419432
width: 100%;

0 commit comments

Comments
 (0)