diff --git a/.gitignore b/.gitignore index e0692e79f..17e204928 100644 --- a/.gitignore +++ b/.gitignore @@ -54,4 +54,5 @@ terraform.tfstate.backup .idea #IDE Specific (VS Code) -.vscode \ No newline at end of file +.vscode +/config/credentials/development.key diff --git a/app/assets/stylesheets/application.postcss.css b/app/assets/stylesheets/application.postcss.css index c49a99dc0..bf3797046 100644 --- a/app/assets/stylesheets/application.postcss.css +++ b/app/assets/stylesheets/application.postcss.css @@ -2,17 +2,53 @@ @forward "uswds-settings.scss"; @forward "uswds-components.scss"; -.argyle-loading { +.lds-ripple, +.lds-ripple div { + box-sizing: border-box; +} +.lds-ripple { + display: inline-block; position: relative; + width: 80px; + height: 80px; } - -.argyle-loading::after { - background-color: rgba(0, 0, 0, 0.128); - content: ""; +.lds-ripple div { position: absolute; - width: 100%; - height: 100%; - top: 0; - left: 0; - z-index: 9999; + border: 4px solid currentColor; + opacity: 1; + border-radius: 50%; + animation: lds-ripple 1s cubic-bezier(0, 0.2, 0.8, 1) infinite; +} +.lds-ripple div:nth-child(2) { + animation-delay: -0.5s; +} +@keyframes lds-ripple { + 0% { + top: 36px; + left: 36px; + width: 8px; + height: 8px; + opacity: 0; + } + 4.9% { + top: 36px; + left: 36px; + width: 8px; + height: 8px; + opacity: 0; + } + 5% { + top: 36px; + left: 36px; + width: 8px; + height: 8px; + opacity: 1; + } + 100% { + top: 0; + left: 0; + width: 80px; + height: 80px; + opacity: 0; + } } diff --git a/app/assets/stylesheets/uswds-components.scss b/app/assets/stylesheets/uswds-components.scss index c699302f6..3d266e40a 100644 --- a/app/assets/stylesheets/uswds-components.scss +++ b/app/assets/stylesheets/uswds-components.scss @@ -1,10 +1,2 @@ -@forward "uswds-global"; -@forward "uswds-utilities"; -@forward "uswds-typography"; -@forward "usa-header"; -@forward "usa-banner"; -@forward "usa-section"; -@forward "usa-alert"; -@forward "usa-combo-box"; -@forward "usa-accordion"; +@forward "uswds"; // add additional packages here as you use them diff --git a/app/controllers/cbv_flows_controller.rb b/app/controllers/cbv_flows_controller.rb index 8ef262285..d7abde93e 100644 --- a/app/controllers/cbv_flows_controller.rb +++ b/app/controllers/cbv_flows_controller.rb @@ -16,6 +16,7 @@ def employer_search def summary @payments = fetch_payroll.map do |payment| { + employer: payment['employer'], amount: payment['net_pay'].to_i, start: payment['paystub_period']['start_date'], end: payment['paystub_period']['end_date'], diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index c85c800f9..41a861ee9 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -6,4 +6,13 @@ def format_active_locale(locale_string) end link_to t("shared.languages.#{locale_string}"), root_path(locale: locale_string), class: link_classes end + + def format_date(timestamp_string) + begin + Time.parse(timestamp_string).strftime("%B %d, %Y") + rescue => e + "Invalid timestamp" + timestamp_string + end + end end diff --git a/app/javascript/controllers/cbv_flows_controller.js b/app/javascript/controllers/cbv_flows_controller.js index cfa3f4003..301ca576a 100644 --- a/app/javascript/controllers/cbv_flows_controller.js +++ b/app/javascript/controllers/cbv_flows_controller.js @@ -9,8 +9,7 @@ function toOptionHTML({ value }) { } export default class extends Controller { - static targets = ["options", "continue", "userAccountId", "fullySynced", "form"]; - static classes = ["loading"] + static targets = ["options", "continue", "userAccountId", "fullySynced", "form", "modal"]; selection = null; @@ -47,7 +46,8 @@ export default class extends Controller { onSignInSuccess(event) { this.userAccountIdTarget.value = event.accountId; - this.element.classList.add(this.loadingClass); + this.argyle.close(); + this.modalTarget.click(); } onAccountError(event) { diff --git a/app/views/cbv_flows/employer_search.html.erb b/app/views/cbv_flows/employer_search.html.erb index b5a0d2752..4914bb23f 100644 --- a/app/views/cbv_flows/employer_search.html.erb +++ b/app/views/cbv_flows/employer_search.html.erb @@ -5,7 +5,7 @@
+ This may take a few minutes. Please do not close this window. +
+We'll connect to your payment records to get proof of payments to your caseworker and get benfits faster.
+We'll connect to your payment records to get proof of payments to your caseworker and get benefits faster.
Case Number: <%= @cbv_flow.case_number %>
diff --git a/app/views/cbv_flows/summary.html.erb b/app/views/cbv_flows/summary.html.erb index ce43fc2ea..ffeb8e784 100644 --- a/app/views/cbv_flows/summary.html.erb +++ b/app/views/cbv_flows/summary.html.erb @@ -2,9 +2,9 @@ <% if @payments.any? %>Below is payment information from your employer for the past 90 days.
-- <%= payment[:hours] %> hours at $<%= payment[:rate] %> per hour. + <%= payment[:hours] %> hours from <%= format_date(payment[:start]) %> to <%= format_date(payment[:end]) %>