forked from Sunbird-inQuiry/editor
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue Sunbird-inQuiry#42 feat: New Match Type Question Implementation
- Loading branch information
Arpan Gupta
committed
Aug 7, 2023
1 parent
c19a96e
commit f82c884
Showing
9 changed files
with
495 additions
and
264 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
.b-0{ | ||
border: 0 !important; | ||
} | ||
|
||
.bg-none{ | ||
background-color: transparent !important; | ||
|
||
&:hover, | ||
&:focus { | ||
background-color: transparent !important; | ||
} | ||
} | ||
|
||
.w-49{ | ||
width: 49%; | ||
max-width: 49%; | ||
} | ||
|
||
.sb-line-height-24 { | ||
line-height: 24px; | ||
} | ||
|
||
.right{ | ||
float: right; | ||
} |
114 changes: 114 additions & 0 deletions
114
projects/questionset-editor-library/src/lib/components/match/match.component.spec.data.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,114 @@ | ||
export const mockOptionData = { | ||
editorOptionData: { | ||
question: "<p>Match the following with appropriate answer?</p>", | ||
options: [ | ||
{ | ||
left: "<p>Lotus</p>", | ||
right: "<p>Flower</p>", | ||
}, | ||
{ | ||
left: "<p>Mango</p>", | ||
right: "<p>Fruit</p>", | ||
}, | ||
], | ||
templateId: "mtf-vertical", | ||
correctMatchPair: [{ "0": 0 }, { "1": 1 }], | ||
numberOfOptions: 4, | ||
}, | ||
prepareMtfBody: { | ||
templateId: "default", | ||
name: "Match The Following Question", | ||
responseDeclaration: { | ||
response1: { | ||
cardinality: "multiple", | ||
type: "map", | ||
correctResponse: { | ||
value: [ | ||
{ | ||
"0": 0, | ||
}, | ||
{ | ||
"1": 1, | ||
}, | ||
], | ||
}, | ||
mapping: [ | ||
{ | ||
value: { | ||
"0": 0, | ||
}, | ||
score: 2, | ||
}, | ||
{ | ||
value: { | ||
"1": 1, | ||
}, | ||
score: 2, | ||
}, | ||
], | ||
}, | ||
}, | ||
interactionTypes: ["match"], | ||
interactions: { | ||
response1: { | ||
type: "match", | ||
options: { | ||
left: [ | ||
{ | ||
label: "<p>Lotus</p>", | ||
value: 0, | ||
}, | ||
{ | ||
label: "<p>Mango</p>", | ||
value: 1, | ||
}, | ||
], | ||
right: [ | ||
{ | ||
label: "<p>Flower</p>", | ||
value: 0, | ||
}, | ||
{ | ||
label: "<p>Fruit</p>", | ||
value: 1, | ||
}, | ||
], | ||
}, | ||
}, | ||
}, | ||
editorState: { | ||
options: { | ||
left: [ | ||
{ | ||
value: { | ||
body: "<p>Lotus</p>", | ||
value: 0, | ||
}, | ||
}, | ||
{ | ||
value: { | ||
body: "<p>Mango</p>", | ||
value: 1, | ||
}, | ||
}, | ||
], | ||
right: [ | ||
{ | ||
value: { | ||
body: "<p>Flower</p>", | ||
value: 0, | ||
}, | ||
}, | ||
{ | ||
value: { | ||
body: "<p>Fruit</p>", | ||
value: 1, | ||
}, | ||
}, | ||
], | ||
}, | ||
}, | ||
qType: "MTF", | ||
primaryCategory: "Match The Following Question", | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.