Skip to content

Commit b3f5b94

Browse files
Ayoola Bimpe CDevbimpe
authored andcommitted
Fixed Supplementary Materials
testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. testing.. updated supplementary materials
1 parent 138970b commit b3f5b94

File tree

3 files changed

+47
-18
lines changed

3 files changed

+47
-18
lines changed

docs/CaseStudy.md

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,14 @@ captures a large quantitative dataset with limited context, consider the
4848
- [ ] reports the type of case study<sup>[1](#myfootnote1)</sup>
4949
- [ ] describes data sources (e.g. participants' demographics and work roles)
5050
- [ ] defines unit(s) of analysis or observation
51+
- [ ] <supplement> coding scheme (required)
52+
- [ ] <supplement> coding examples (required)
53+
- [ ] <supplement> extended chain-of-evidence table(s) (required)
54+
55+
56+
57+
58+
5159

5260
<results>
5361

@@ -60,16 +68,13 @@ captures a large quantitative dataset with limited context, consider the
6068

6169
</checklist>
6270

63-
### Supplementary Material
64-
<checklist name="Supplementary Materials">
65-
- [ ] provides supplemental materials such as interview guide(s), coding schemes, coding examples, decision rules, or extended chain-of-evidence tables
66-
- [ ] triangulates across data sources, informants or researchers
67-
</checklist>
68-
71+
6972
### Desirable Attributes
7073
<checklist name="Desirable">
7174

7275
- [ ] provides supplemental materials such as interview guide(s), coding schemes, coding examples, decision rules, or extended chain-of-evidence tables
76+
- [ ] <supplement> interview guide(s) (optional)
77+
- [ ] <supplement> decision rules (optional)
7378
- [ ] triangulates across data sources, informants or researchers
7479
- [ ] cross-checks interviewee statements (e.g. against direct observation or archival records)
7580
- [ ] uses participant observation (ethnography) or direct observation (non-ethnography) and clearly integrates these observations into results<sup>[2](#myfootnote2)</sup>

form_generator/js/read_standards.js

Lines changed: 35 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -144,18 +144,21 @@ function generate_decision_message_block() {
144144
} else if (justification_type2_checked_count > 0) {
145145
msg = "GATEKEEP";
146146
document.getElementById("deviation_reasonable").style.display = "block";
147+
document.getElementById("Supplementary Materials").style.display = "block";
147148
document.getElementById("Desirable").style.display = "block";
148149
document.getElementById("Extraordinary").style.display = "block";
149150

150151
// if number of type 1 is greater than 0
151152
} else if (justification_type1_checked_count > 0) {
152153
msg = "ACCEPT";
153154
document.getElementById("deviation_reasonable").style.display = "block";
155+
document.getElementById("Supplementary Materials").style.display = "block";
154156
document.getElementById("Desirable").style.display = "block";
155157
document.getElementById("Extraordinary").style.display = "block";
156158

157159
} else {
158160
msg = "ACCEPT";
161+
document.getElementById("Supplementary Materials").style.display = "block";
159162
document.getElementById("Desirable").style.display = "block";
160163
document.getElementById("Extraordinary").style.display = "block";
161164

@@ -679,8 +682,9 @@ function generate_two_phase_reviewer_deviation_block(checklistItem_id) {
679682
return deviation_block;
680683
}
681684

685+
682686
// convert from Markdown to HTML checklists
683-
function convert_MD_standard_checklists_to_html_standard_checklists(standardName, checklistName, checklistText, footnotes){
687+
function convert_MD_standard_checklists_to_html_standard_checklists(standardName, checklistName, checklistText, footnotes,supCheckList){
684688

685689
// ???????
686690
tester = getParameterByName('y')[0] == 'noval' ? true : false;
@@ -735,13 +739,19 @@ function convert_MD_standard_checklists_to_html_standard_checklists(standardName
735739
// !!!!!!!!!!!!!!!! we dont need this part in the checklist
736740
if(line_text.includes("complies with all applicable empirical standards"))
737741
continue;
738-
742+
739743
// if line_text includes a specific regex set to true ( line break with horizontal rule)
740744
IMRaD_line_break = line_text.includes('<br\/>_hr_') ? true : false;
741745

742746
// Replace line break and horizontal rule with empty string
743747
line_text = line_text.replace(/(<br\/>_hr_)+/g, '');
744748

749+
//comment later
750+
if(line_text.includes("{supplement}") && checklistName !== "Supplementary") {
751+
supCheckList.items += "- [ ]" + line_text;
752+
continue;
753+
}
754+
745755
// Change the text to the string held in line_text
746756
checklistItemLI.setAttribute("text", line_text);
747757

@@ -816,6 +826,7 @@ function convert_MD_standard_checklists_to_html_standard_checklists(standardName
816826
checklists.appendChild(checklistItemLI);
817827
}
818828
}
829+
819830
return checklists;
820831
}
821832

@@ -902,10 +913,10 @@ function create_role_heading(){
902913
}
903914

904915
// Prepare unordered lists
905-
function preparation_to_convert_MD_to_HTML(standardTagName, checklistTagName, checklistInnerHTML, footnotes){
916+
function preparation_to_convert_MD_to_HTML(standardTagName, checklistTagName, checklistInnerHTML, footnotes,supCheckList){
906917

907918
// superscript tags
908-
checklistInnerHTML = checklistInnerHTML.replaceAll("<sup>", "{sup}").replaceAll("</sup>", "{/sup}");
919+
checklistInnerHTML = checklistInnerHTML.replaceAll("<sup>", "{sup}").replaceAll("</sup>", "{/sup}").replaceAll("<supplement>", "{supplement}");
909920

910921
var tempDivElement = document.createElement("div");
911922
tempDivElement.innerHTML = checklistInnerHTML;
@@ -922,8 +933,9 @@ function preparation_to_convert_MD_to_HTML(standardTagName, checklistTagName, ch
922933
// Supplement Files - Change from docs to link, change from .md file to nothing
923934
checklistText = checklistText.replaceAll('https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/', '../Supplements?supplement=').replaceAll('.md', '');
924935

936+
925937
// Convert Markdown Checklists to HTML checklists
926-
checklists = convert_MD_standard_checklists_to_html_standard_checklists(standardTagName, checklistTagName, checklistText, footnotes)
938+
checklists = convert_MD_standard_checklists_to_html_standard_checklists(standardTagName, checklistTagName, checklistText, footnotes,supCheckList)
927939

928940
return checklists;
929941
}
@@ -986,6 +998,8 @@ function create_requirements_checklist(){
986998
form.id = "checklists";
987999
form.name = "checklists";
9881000

1001+
var supCheckList = {items:""};
1002+
9891003
// create Header for Essential Requirements with an unordered list
9901004
var EssentialUL = create_requirements_heading_with_UL("Essential");
9911005

@@ -1001,13 +1015,13 @@ function create_requirements_checklist(){
10011015
// hide desirable and extraordinary list of requirements for One Phase Reviewer
10021016
if(role == "\"one-phase-reviewer\""){
10031017
DesirableUL.style = "padding: 0px; display:none;";
1004-
SupplementaryUL.style = "padding: 0px; display:none;";
1018+
SupplementaryUL.style = "padding: 0px; display:block;";
10051019
ExtraordinaryUL.style = "padding: 0px; display:none;";
10061020
}
10071021
// hide desirable and extraordinary list of requirements for Two Phase Reviewer
10081022
else if(role == "\"two-phase-reviewer\""){
10091023
DesirableUL.style = "padding: 0px; display:none;";
1010-
SupplementaryUL.style = "padding: 0px; display:none;";
1024+
SupplementaryUL.style = "padding: 0px; display:block;";
10111025
ExtraordinaryUL.style = "padding: 0px; display:none;";
10121026
}
10131027

@@ -1065,18 +1079,20 @@ function create_requirements_checklist(){
10651079
EssentialUL.appendChild(Yes_No);
10661080
//EssentialUL.appendChild(checklists);
10671081
}
1082+
10681083
else if (checklistTag.getAttribute('name') == "Desirable") {
10691084
//DesirableUL.appendChild(standard_header_rule);
10701085

10711086
// Change from Markdown to HTML elements
1072-
checklists = preparation_to_convert_MD_to_HTML(standardTag.getAttribute('name'), checklistTag.getAttribute('name'), checklistHTML, footnotes);
1087+
checklists = preparation_to_convert_MD_to_HTML(standardTag.getAttribute('name'), checklistTag.getAttribute('name'), checklistHTML, footnotes,supCheckList);
10731088
DesirableUL.appendChild(checklists);
10741089
}
1090+
10751091
else if (checklistTag.getAttribute('name') == "Extraordinary") {
10761092
//ExtraordinaryUL.appendChild(standard_header_rule);
10771093

10781094
// Change from Markdown to HTML elements
1079-
checklists = preparation_to_convert_MD_to_HTML(standardTag.getAttribute('name'), checklistTag.getAttribute('name'), checklistHTML, footnotes);
1095+
checklists = preparation_to_convert_MD_to_HTML(standardTag.getAttribute('name'), checklistTag.getAttribute('name'), checklistHTML, footnotes,supCheckList);
10801096
ExtraordinaryUL.appendChild(checklists);
10811097
}
10821098
}
@@ -1089,15 +1105,22 @@ function create_requirements_checklist(){
10891105
notify_testers();
10901106

10911107
// Change from Markdown to HTML elements
1092-
checklists = preparation_to_convert_MD_to_HTML("", 'Essential', all_essential_IMRaD_items_innerHTML, footnotes);
1108+
checklists = preparation_to_convert_MD_to_HTML("", 'Essential', all_essential_IMRaD_items_innerHTML, footnotes,supCheckList);
10931109
EssentialUL.appendChild(checklists);
1094-
1110+
1111+
checklists = preparation_to_convert_MD_to_HTML(standardTag.getAttribute('name'), "Supplementary", supCheckList.items.replaceAll("{supplement}", ""), footnotes,supCheckList);
1112+
SupplementaryUL.appendChild(checklists);
1113+
1114+
10951115
// Add Essential Attributes to the form
10961116
form.appendChild(EssentialUL);
10971117

10981118
// Create download button
10991119
var download = create_download_button();
11001120

1121+
//append supplementary material list
1122+
form.appendChild(SupplementaryUL);
1123+
11011124
// (All 'Yes' -> accept manuscript)
11021125
var decision_msg = generate_message("decision_msg", "red", (role != "\"author\"" ? "The manuscript meets all essential criteria: ACCEPT." : ""), 2, 0);
11031126
form.appendChild(decision_msg);
@@ -1131,6 +1154,7 @@ function create_requirements_checklist(){
11311154
}
11321155

11331156
// Add Desirable and Extraordinary Unordered List to Form
1157+
11341158
form.appendChild(DesirableUL);
11351159
form.appendChild(ExtraordinaryUL);
11361160

tab_03_standards.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ function openStandardFromURL(evt) {
105105
<div id="CaseStudy" class="tabcontent">
106106
<p>
107107
{% capture std %}{% include_relative docs/CaseStudy.md %}{% endcapture %}
108-
{{ std | remove: '<standard name="Case Study and Ethnography">' | remove: '<checklist name="Essential">' | remove: '<checklist name="Desirable">' | remove: '<checklist name="Extraordinary">' | remove: '</checklist>' | remove: '</standard>' | remove: '<footnote>' | remove: '</footnote>' | remove: '<intro>' | remove: '<method>' | remove: '<results>' | remove: '<discussion>' | remove: '<other>' | replace: '- [ ]', '-' | replace: 'https://github.com/acmsigsoft/EmpiricalStandards/blob/master/docs/', '../docs?standard=' | replace: 'https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/', '../Supplements?supplement=' | replace: '.md', '' | markdownify }}
108+
{{ std | remove: '<standard name="Case Study and Ethnography">' | remove: '<checklist name="Essential">' | remove: '<checklist name="Desirable">' | remove: '<checklist name="Extraordinary">' | remove: '</checklist>' | remove: '</standard>' | remove: '<footnote>' | remove: '</footnote>' | remove: '<intro>' | remove: '<method>' | remove: '<results>' | remove: '<discussion>' | remove: '<other>' | remove: '<desc>' | remove: '</desc>' | remove: '<supplement>' | replace: '- [ ]', '-' | replace: 'https://github.com/acmsigsoft/EmpiricalStandards/blob/master/docs/', '../docs?standard=' | replace: 'https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/', '../Supplements?supplement=' | replace: '.md', '' | markdownify }}
109109
</p>
110110
</div>
111111

0 commit comments

Comments
 (0)