Skip to content

Commit

Permalink
Phase 2 - potential fix for form preview
Browse files Browse the repository at this point in the history
  • Loading branch information
natashapl committed Dec 28, 2024
1 parent 953faa6 commit 3e3f544
Show file tree
Hide file tree
Showing 9 changed files with 2,056 additions and 991 deletions.
3 changes: 2 additions & 1 deletion .eleventy.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,13 @@ module.exports = function (config) {
"./node_modules/pizzip/dist/": "assets/pizzip/dist/",
});
config.addPassthroughCopy({
"./node_modules/pdf-lib/dist/": "assets/pdf-lib/dist/",
"./node_modules/docx2pdf-converter/": "assets/docx2pdf-converter/",
});
config.addPassthroughCopy({ "_includes/theme/images": "assets/images" });
config.addPassthroughCopy({ "_includes/theme/js": "assets/js" });
config.addPassthroughCopy({ "_includes/theme/documents": "assets/documents" });
config.addPassthroughCopy({ "_includes/theme/templates": "assets/templates" });
config.addPassthroughCopy({ "uploads": "uploads" });

// Add plugins
config.addPlugin(pluginRss);
Expand Down
61 changes: 59 additions & 2 deletions _data/assetPaths.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,67 @@
"search.svg": "/assets/assets/search-2D3FZK3P.svg",
"unfold_more.svg": "/assets/assets/unfold_more-WL443JWS.svg",
"warning.svg": "/assets/assets/warning-5OR6W6GJ.svg",
"ICR-Template_A11-Section-280-Clearance-v5-13-24.docx": "/assets/documents/ICR-Template_A11-Section-280-Clearance-v5-13-24-original.docx",
"CHANGELO.md": "/assets/docxtemplater/CHANGELOG.md",
"LICENS.md": "/assets/docxtemplater/LICENSE.md",
"READM.md": "/assets/docxtemplater/README.md",
"SECURIT.md": "/assets/docxtemplater/SECURITY.md",
"buil": "/assets/docxtemplater/build",
"docxtemplater..ts": "/assets/docxtemplater/docxtemplater.d.ts",
"docxtemplater.test.ts": "/assets/docxtemplater/docxtemplater.test-d.ts",
"expressions.ts": "/assets/docxtemplater/expressions-ie11.d.ts",
"expressions.js": "/assets/docxtemplater/expressions-ie11.js",
"expressions..ts": "/assets/docxtemplater/expressions.d.ts",
"expression.js": "/assets/docxtemplater/expressions.js",
"inspect.ts": "/assets/docxtemplater/inspect-module.d.ts",
"j": "/assets/docxtemplater/js",
"node_module": "/assets/docxtemplater/node_modules",
"packag.json": "/assets/docxtemplater/package.json",
"text..ts": "/assets/docxtemplater/text.d.ts",
"tex.js": "/assets/docxtemplater/text.js",
"webpack.confi.js": "/assets/docxtemplater/webpack.config.js",
"card-sorting.webp": "/assets/images/card-sorting-icon.webp",
"cognitive.webp": "/assets/images/cognitive-icon.webp",
"contextual.webp": "/assets/images/contextual-icon.webp",
"explore-pra-banner.webp": "/assets/images/explore-pra-banner-wide.webp",
"explore-pra.png": "/assets/images/explore-pra-banner.png",
"fast-track.webp": "/assets/images/fast-track-process.webp",
"gsa.svg": "/assets/images/gsa-logo.svg",
"her.png": "/assets/images/hero.png",
"hire.jpg": "/assets/images/hire-us.jpg",
"logo.png": "/assets/images/logo-img.png",
"multi-testing.webp": "/assets/images/multi-testing-icon.webp",
"new-to-pra.png": "/assets/images/new-to-pra-icon.png",
"new-to-pra.webp": "/assets/images/new-to-pra-icon.webp",
"not-sure-pra.png": "/assets/images/not-sure-pra-icon.png",
"not-sure-pra.webp": "/assets/images/not-sure-pra-icon.webp",
"not-sure-yet.webp": "/assets/images/not-sure-yet-icon.webp",
"other-methods.webp": "/assets/images/other-methods-icon.webp",
"pra-process-people.png": "/assets/images/pra-process-people-involved.png",
"pra-process-people.webp": "/assets/images/pra-process-people-involved.webp",
"ready-for-pra.png": "/assets/images/ready-for-pra-icon.png",
"ready-for-pra.webp": "/assets/images/ready-for-pra-icon.webp",
"recruitment.webp": "/assets/images/recruitment-icon.webp",
"research.webp": "/assets/images/research-icon.webp",
"upload": "/assets/images/uploads",
"usability-testing.webp": "/assets/images/usability-testing-icon.webp",
"user-interviews.webp": "/assets/images/user-interviews-icon.webp",
"visual-pref-testing.webp": "/assets/images/visual-pref-testing-icon.webp",
"admin.js": "/assets/js/admin-TRAB3TNM.js",
"admin.map": "/assets/js/admin-TRAB3TNM.js.map",
"admi.js": "/assets/js/admin.js",
"app.js": "/assets/js/app-4QJFXAPF.js",
"app.map": "/assets/js/app-4QJFXAPF.js.map",
"index.css": "/assets/styles/index-LYY4MPZF.css",
"index.map": "/assets/styles/index-LYY4MPZF.css.map"
"ap.js": "/assets/js/app.js",
"base.js": "/assets/js/base-url.js",
"icr-form.js": "/assets/js/icr-form-wizard.js",
"modalFi.js": "/assets/js/modalFix.js",
"pra.js": "/assets/js/pra-form.js",
"slide.js": "/assets/js/slider.js",
"uswds.js": "/assets/js/uswds-init.js",
"dis": "/assets/pizzip/dist",
"index.css": "/assets/styles/index-GHJ64BFU.css",
"index.map": "/assets/styles/index-GHJ64BFU.css.map",
"ICR-Template_A11-Section-280-Clearance-v5-13.docx": "/assets/templates/ICR-Template_A11-Section-280-Clearance-v5-13-24.docx",
"im": "/assets/uswds/img"
}
87 changes: 71 additions & 16 deletions _includes/layouts/get-pra-clearance.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
---
<script src="{{ '/assets/pizzip/dist/pizzip.min.js' | url }}"></script>
<script src="{{ '/assets/docxtemplater/build/docxtemplater.min.js' | url }}"></script>
<script src="{{ '/assets/pdf-lib/dist/pdf-lib.min.js' | url }}"></script>

<div class="get-pra-clearance-wrapper static-content">
<h1 class="margin-top-0">Get PRA clearance</h1>
Expand Down Expand Up @@ -294,7 +293,7 @@ <h4 class="usa-step-indicator__heading">
<!-- Collection Methods -->
<fieldset class="usa-fieldset">
<legend class="usa-legend">How will you collect information? <span class="usa-hint">*</span></legend>
<span class="usa-hint">Helper text</span>
<span class="usa-hint">Please select all that apply.</span>
<div class="usa-checkbox">
<input class="usa-checkbox__input" id="collection-web-based" type="checkbox" name="checkboxes"
value="Web-based or social media" required>
Expand Down Expand Up @@ -388,21 +387,76 @@ <h4 class="usa-step-indicator__heading">
</p>
</div>

<!-- Step 3 -->
<div class="step" data-step-title="Burden estimate">
<p class="usa-hint">Add details for each category of respondents as needed.</p>
<div id="burdenRowsContainer">
<!-- Step 3 -->
<div class="step" data-step-title="Burden estimate">
<p class="usa-hint">Select the categories that apply and provide the required information for each.</p>
<fieldset class="usa-fieldset">
<legend class="usa-legend">Category of respondents <span class="usa-hint">*</span></legend>
<div class="usa-checkbox">
<input class="usa-checkbox__input category-checkbox" id="individuals-checkbox" type="checkbox" name="category" value="Individuals" />
<label class="usa-checkbox__label" for="individuals-checkbox">Individuals or Households</label>
</div>
<!-- Inputs for each category -->
<div id="Individuals-inputs" class="category-inputs" style="display: none;">
<p>
<label class="usa-label" for="numberOfRespondents-Individuals">Number of respondents *</label>
<input class="usa-input dynamic-input" id="numberOfRespondents-Individuals" data-category="Individuals" type="number" />
</p>
<p>
<label class="usa-label" for="participationTime-Individuals">Participation time (minutes) *</label>
<input class="usa-input dynamic-input" id="participationTime-Individuals" data-category="Individuals" type="number" />
</p>
</div>
<div class="usa-checkbox">
<input class="usa-checkbox__input category-checkbox" id="private-checkbox" type="checkbox" name="category" value="PrivateSector" />
<label class="usa-checkbox__label" for="private-checkbox">Private Sector</label>
</div>
<div id="PrivateSector-inputs" class="category-inputs" style="display: none;">
<p>
<label class="usa-label" for="numberOfRespondents-PrivateSector">Number of respondents *</label>
<input class="usa-input dynamic-input" id="numberOfRespondents-PrivateSector" data-category="PrivateSector" type="number" />
</p>
<p>
<label class="usa-label" for="participationTime-PrivateSector">Participation time (minutes) *</label>
<input class="usa-input dynamic-input" id="participationTime-PrivateSector" data-category="PrivateSector" type="number" />
</p>
</div>
<div class="usa-checkbox">
<input class="usa-checkbox__input category-checkbox" id="state-checkbox" type="checkbox" name="category" value="StateLocal" />
<label class="usa-checkbox__label" for="state-checkbox">State, local, or tribal governments</label>
</div>
<div id="StateLocal-inputs" class="category-inputs" style="display: none;">
<p>
<label class="usa-label" for="numberOfRespondents-StateLocal">Number of respondents *</label>
<input class="usa-input dynamic-input" id="numberOfRespondents-StateLocal" data-category="StateLocal" type="number" />
</p>
<p>
<label class="usa-label" for="participationTime-StateLocal">Participation time (minutes) *</label>
<input class="usa-input dynamic-input" id="participationTime-StateLocal" data-category="StateLocal" type="number" />
</p>
</div>
<div class="usa-checkbox">
<input class="usa-checkbox__input category-checkbox" id="federal-checkbox" type="checkbox" name="category" value="Federal" />
<label class="usa-checkbox__label" for="federal-checkbox">Federal Government</label>
</div>
<div id="Federal-inputs" class="category-inputs" style="display: none;">
<p>
<label class="usa-label" for="numberOfRespondents-Federal">Number of respondents *</label>
<input class="usa-input dynamic-input" id="numberOfRespondents-Federal" data-category="Federal" type="number" />
</p>
<p>
<label class="usa-label" for="participationTime-Federal">Participation time (minutes) *</label>
<input class="usa-input dynamic-input" id="participationTime-Federal" data-category="Federal" type="number" />
</p>
</div>
</fieldset>

<p class="text-right">
<button type="button" class="usa-button usa-button--outline" onclick="previousStep()">Back</button>
<button type="button" class="usa-button" onclick="nextStep()">Continue</button>
</p>
</div>

<p class="text-right">
<button type="button" class="usa-button usa-button--base" onclick="addBurdenRow()">Add Row</button>
</p>

<p class="text-right margin-top-5">
<button type="button" class="usa-button usa-button--outline" onclick="previousStep()">Back</button>
<button type="button" class="usa-button" onclick="nextStep()">Continue</button>
</p>
</div>

<!-- Step 4 -->
<div class="step" data-step-title="Certification">
Expand Down Expand Up @@ -460,7 +514,7 @@ <h4 class="usa-step-indicator__heading">

<!-- This iframe content only loads in the cloud and not locally because it's a relative path -->
<iframe data-dynamic-src="{{ '/assets/documents/ICR-Template_A11-Section-280-Clearance-v5-13-24.docx' | url }}" width="100%" height="600"></iframe>

<p>Once you are satisfied with your ICR form, do the following:</p>

<ol class="pra-clearance-instructions">
Expand Down Expand Up @@ -510,6 +564,7 @@ <h4 class="usa-modal__heading font-family-sans" id="modal-1-heading">
</div> -->
{{ content }}
</div>

{% capture icrFormWizardJs %}
{% include "_includes/theme/js/icr-form-wizard.js" %}
{% endcapture %}
Expand Down
Loading

0 comments on commit 3e3f544

Please sign in to comment.