Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUMP] Update dependency ember-template-lint to v6 (mon-pix) #11067

Open
wants to merge 26 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
cb0f580
[BUMP] Update dependency ember-template-lint to v6 (mon-pix)
renovate[bot] Jan 10, 2025
e159d8d
refactor(mon-pix) Replace Input by PixInput
yaf Jan 14, 2025
80462b3
refactor(mon-pix): replace did-insert did-update with modifier-did-up…
lionelB Jan 14, 2025
0a1d993
refactor(mon-pix): replace will-destroy modifier with willDestroy lif…
lionelB Jan 14, 2025
57fd4f8
refactor(mon-pix): remove eslint disable comment
lionelB Jan 16, 2025
421d0ed
fix(mon-pix): remove FormFieldText from register-form
xav-car Jan 17, 2025
c604b98
fix(mon-pix): remove FormTextfield from login-form
xav-car Jan 17, 2025
48b293e
fix(mon-pix): join restricted page with DS component
xav-car Jan 17, 2025
d365b8c
fix(mon-pix): fix revovery account student information
xav-car Jan 17, 2025
c7084ab
fix(mon-pix): backup email remove FormFieldText
xav-car Jan 17, 2025
05d6fbc
fix(mon-pix): update sco record form
xav-car Jan 17, 2025
acb1887
remove unused component
xav-car Jan 17, 2025
6dde426
fix(mon-pix): a11y remove disabled keep readonly
xav-car Jan 17, 2025
d7dfc3f
fix(mon-pix): test
xav-car Jan 17, 2025
13bfb53
fix(mon-pix): fix test
xav-car Jan 17, 2025
ec957d3
fix(mon-pix): fix account-recovery tests
lionelB Jan 17, 2025
5015637
fix(mon-pix): remove test wich validate PixInput
xav-car Jan 17, 2025
5b4a53f
chore(mon-pix): fix routes/login-form test
lionelB Jan 17, 2025
7fbcad6
fix(mon-pix): test
xav-car Jan 17, 2025
4149bde
fix(mon-pix): start campaign workflow
xav-car Jan 17, 2025
8d25980
chore(mon-pix): fix e2e test on password
lionelB Jan 17, 2025
d0b387e
fix(mon-pix): fix Acceptance | Update Expired Password tests
lionelB Jan 17, 2025
c585ec2
chore(mon-pix): remove template-lint disable comment
lionelB Jan 17, 2025
96c8d09
test(mon-pix): fix Start Campaigns workflow
lionelB Jan 17, 2025
5c8bb7e
test(mon-pix): fix start-campaigns-workflow-test
lionelB Jan 17, 2025
01a6959
chore(mon-pix): remove @ember/render-modifiers
lionelB Jan 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,19 @@
{{/if}}

<form onSubmit={{this.submitBackupEmailConfirmationForm}}>
<FormTextfield
@label={{t "pages.account-recovery.find-sco-record.backup-email-confirmation.form.email"}}
@textfieldName="email"
@inputBindingValue={{this.email}}
@onValidate={{this.validateEmail}}
<PixInput
@id="email"
@value={{this.email}}
{{on "focusout" this.validateEmail}}
{{on "input" this.handleInputChange}}
@requiredLabel={{true}}
@validationStatus={{this.emailValidation.status}}
@validationMessage={{this.emailValidation.message}}
@autocomplete="off"
@require={{true}}
@hideRequired={{true}}
@aria-describedby="backup-email-confirmation-already-use-error-message backup-email-confirmation-already-associated-error-message"
/>
@errorMessage={{this.emailValidation.message}}
autocomplete="off"
type="text"
>
<:label>{{t "pages.account-recovery.find-sco-record.backup-email-confirmation.form.email"}}</:label>
</PixInput>

{{#if @showAlreadyRegisteredEmailError}}
<PixNotificationAlert
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ export default class BackupEmailConfirmationFormComponent extends Component {
this.emailValidation.message = null;
}

@action
handleInputChange(event) {
this.email = event.target.value;
}

@action
async submitBackupEmailConfirmationForm(event) {
event.preventDefault();
Expand Down
208 changes: 104 additions & 104 deletions mon-pix/app/components/account-recovery/student-information-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -15,108 +15,110 @@
{{t "pages.account-recovery.find-sco-record.student-information.mandatory-all-fields"}}
</p>

<form {{on "submit" this.submit}} class="account-recovery__content--form">
<div class="account-recovery__content--form-fields">
<div class="student-information-form__tooltip">
<PixTooltip
@position="top-left"
@isLight={{true}}
@isWide={{true}}
aria-label={{t "pages.account-recovery.find-sco-record.student-information.form.tooltip" htmlSafe=true}}
>
<:triggerElement>
<PixIcon @name="help" @plainIcon={{true}} @ariaHidden={{true}} tabindex="0" />
</:triggerElement>
<:tooltip>
{{t "pages.account-recovery.find-sco-record.student-information.form.tooltip" htmlSafe=true}}
</:tooltip>
</PixTooltip>
</div>
<FormTextfield
@label={{t "pages.account-recovery.find-sco-record.student-information.form.ine-ina"}}
@textfieldName="ineIna"
@inputBindingValue={{this.ineIna}}
@onValidate={{this.validateIneIna}}
@validationStatus={{this.ineInaValidation.status}}
@validationMessage={{this.ineInaValidation.message}}
@autocomplete="off"
@require={{true}}
@hideRequired="true"
@placeholder="123456789XX"
@aria-describedby="student-information-error-message"
/>
<form {{on "submit" this.submit}} class="account-recovery__form">
<PixInput
@id="ineIna"
type="text"
placeholder="123456789XX"
@value={{this.ineIna}}
{{on "focusout" this.validateIneIna}}
{{on "input" this.handleIneInaInput}}
@validationStatus={{this.ineInaValidation.status}}
@errorMessage={{this.ineInaValidation.message}}
autocomplete="off"
>
<:label>
{{t "pages.account-recovery.find-sco-record.student-information.form.ine-ina"}}

<div class="student-information-form__tooltip">
<PixTooltip
@position="top-left"
@isLight={{true}}
@isWide={{true}}
aria-label={{t "pages.account-recovery.find-sco-record.student-information.form.tooltip" htmlSafe=true}}
>
<:triggerElement>
<PixIcon @name="help" @plainIcon={{true}} @ariaHidden={{true}} tabindex="0" />
</:triggerElement>
<:tooltip>
{{t "pages.account-recovery.find-sco-record.student-information.form.tooltip" htmlSafe=true}}
</:tooltip>
</PixTooltip>
</div>
</:label>
</PixInput>

<FormTextfield
@label={{t "pages.account-recovery.find-sco-record.student-information.form.first-name"}}
@textfieldName="firstName"
@inputBindingValue={{this.firstName}}
@onValidate={{this.validateFirstName}}
@validationStatus={{this.firstNameValidation.status}}
@validationMessage={{this.firstNameValidation.message}}
@autocomplete="off"
@require={{true}}
@hideRequired="true"
@aria-describedby="student-information-error-message"
/>
<PixInput
@id="firstName"
@value={{this.firstName}}
{{on "focusout" this.validateFirstName}}
{{on "input" this.handleFirstNameInput}}
@validationStatus={{this.firstNameValidation.status}}
@errorMessage={{this.firstNameValidation.message}}
autocomplete="off"
type="text"
>
<:label>{{t "pages.account-recovery.find-sco-record.student-information.form.first-name"}}</:label>
</PixInput>

<FormTextfield
@label={{t "pages.account-recovery.find-sco-record.student-information.form.last-name"}}
@textfieldName="lastName"
@inputBindingValue={{this.lastName}}
@onValidate={{this.validateLastName}}
@validationStatus={{this.lastNameValidation.status}}
@validationMessage={{this.lastNameValidation.message}}
@autocomplete="off"
@require={{true}}
@hideRequired="true"
@aria-describedby="student-information-error-message"
/>
<PixInput
@id="lastName"
@value={{this.lastName}}
{{on "focusout" this.validateLastName}}
{{on "input" this.handleLastNameInput}}
@validationStatus={{this.lastNameValidation.status}}
@errorMessage={{this.lastNameValidation.message}}
autocomplete="off"
type="text"
>
<:label>{{t "pages.account-recovery.find-sco-record.student-information.form.last-name"}}</:label>
</PixInput>

<div class="form-textfield">
<p class="form-textfield__label student-information-form__birthdate-label">
{{t "pages.account-recovery.find-sco-record.student-information.form.birthdate"}}
</p>
<div class="student-information-form__birthdate-fields">
<div class="form-textfield__input-field-container">
<Input
min="1"
max="31"
@type="number"
@value={{this.dayOfBirth}}
placeholder={{t "pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-day"}}
id="dayOfBirth"
{{on "input" this.handleDayInputChange}}
aria-label={{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-day"}}
autocomplete="off"
/>
</div>
<div class="form-textfield__input-field-container">
<Input
min="1"
max="12"
@type="number"
@value={{this.monthOfBirth}}
placeholder={{t
"pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-month"
}}
id="monthOfBirth"
{{on "input" this.handleMonthInputChange}}
aria-label={{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-month"}}
autocomplete="off"
/>
</div>
<div class="form-textfield__input-field-container">
<Input
min="1900"
@type="number"
@value={{this.yearOfBirth}}
placeholder={{t "pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-year"}}
id="yearOfBirth"
aria-label={{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-year"}}
autocomplete="off"
/>
</div>
</div>
<div class="form-textfield">
<p class="form-textfield__label student-information-form__birthdate-label">
{{t "pages.account-recovery.find-sco-record.student-information.form.birthdate"}}
</p>
<div class="student-information-form__birthdate-fields">
<PixInput
min="1"
max="31"
type="number"
@value={{this.dayOfBirth}}
placeholder={{t "pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-day"}}
@id="dayOfBirth"
{{on "input" this.handleDayInput}}
autocomplete="off"
@screenReaderOnly={{true}}
>
<:label>{{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-day"}}</:label>
</PixInput>

<PixInput
min="1"
max="12"
type="number"
@value={{this.monthOfBirth}}
placeholder={{t "pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-month"}}
@id="monthOfBirth"
{{on "input" this.handleMonthInput}}
autocomplete="off"
@screenReaderOnly={{true}}
>
<:label>{{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-month"}}</:label>
</PixInput>

<PixInput
min="1900"
type="number"
@value={{this.yearOfBirth}}
placeholder={{t "pages.account-recovery.find-sco-record.student-information.form.placeholder.birth-year"}}
@id="yearOfBirth"
autocomplete="off"
{{on "input" this.handleYearInput}}
@screenReaderOnly={{true}}
>
<:label>{{t "pages.account-recovery.find-sco-record.student-information.form.label.birth-year"}}</:label>
</PixInput>
</div>
</div>

Expand All @@ -137,10 +139,8 @@
</PixNotificationAlert>
{{/if}}

<div class="account-recovery__content--actions">
<PixButton @type="submit" @isDisabled={{not this.isFormValid}}>
{{t "pages.account-recovery.find-sco-record.student-information.form.submit"}}
</PixButton>
</div>
<PixButton @type="submit" @isDisabled={{not this.isFormValid}}>
{{t "pages.account-recovery.find-sco-record.student-information.form.submit"}}
</PixButton>
</form>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -145,20 +145,41 @@ export default class StudentInformationFormComponent extends Component {
}

@action
handleDayInputChange(event) {
const { value } = event.target;
handleIneInaInput(event) {
this.ineIna = event.target.value;
}

@action
handleFirstNameInput(event) {
this.firstName = event.target.value;
}

@action
handleLastNameInput(event) {
this.lastName = event.target.value;
}

@action
handleDayInput(event) {
const { value } = event.target;
this.dayOfBirth = value;
if (value.length === 2) {
document.getElementById('monthOfBirth').focus();
}
}

@action
handleMonthInputChange(event) {
handleMonthInput(event) {
const { value } = event.target;

this.monthOfBirth = value;
if (value.length === 2) {
document.getElementById('yearOfBirth').focus();
}
}

@action
handleYearInput(event) {
const { value } = event.target;
this.yearOfBirth = value;
}
}
30 changes: 14 additions & 16 deletions mon-pix/app/components/account-recovery/update-sco-record-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,22 @@

<form onSubmit={{this.submitUpdate}} class="account-recovery__content--form">
<div class="account-recovery__content--form-fields">
<FormTextfield
@label={{t "pages.account-recovery.update-sco-record.form.email-label"}}
@textfieldName="email"
@inputBindingValue={{@email}}
@disabled={{true}}
/>
<PixInput @id="email" @value={{@email}} @disabled={{true}}>
<:label>{{t "pages.account-recovery.update-sco-record.form.email-label"}}</:label>
</PixInput>

<FormTextfield
@label={{t "pages.account-recovery.update-sco-record.form.password-label"}}
@textfieldName="password"
@inputBindingValue={{this.password}}
@onValidate={{this.validatePassword}}
<PixInputPassword
@id="password"
@value={{this.password}}
autocomplete="off"
{{on "focusout" this.validatePassword}}
{{on "input" this.handlePasswordInput}}
@validationStatus={{this.passwordValidation.status}}
@validationMessage={{this.passwordValidation.message}}
@autocomplete="off"
@require={{true}}
@hideRequired={{true}}
/>
@errorMessage={{this.passwordValidation.message}}
@requiredLabel={{true}}
>
<:label>{{t "pages.account-recovery.update-sco-record.form.password-label"}}</:label>
</PixInputPassword>

<div class="update-sco-record-form__cgu-container">
<PixCheckbox {{on "change" this.onChange}}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,11 @@ export default class UpdateScoRecordFormComponent extends Component {
this.passwordValidation.message = null;
}

@action
handlePasswordInput(event) {
this.password = event.target.value;
}

@action
async submitUpdate(event) {
event.preventDefault();
Expand Down
3 changes: 1 addition & 2 deletions mon-pix/app/components/campaign-start-block.hbs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{{! template-lint-disable no-action no-triple-curlies }}
<div class="rounded-panel campaign-landing-page__container__start">
<div class="campaign-landing-page__start__image__container">
<div class="campaign-landing-page__pix-logo">
Expand All @@ -19,7 +18,7 @@
<div class="campaign-landing-page-start">
<h1 class="campaign-landing-page-start__title">{{this.titleText}}</h1>
{{#unless this.session.isAuthenticated}}
<h2 class="campaign-landing-page-start__subtitle">{{{this.announcementText}}}</h2>
<h2 class="campaign-landing-page-start__subtitle">{{this.announcementText}}</h2>
{{/unless}}
<PixButton
@type="submit"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ export default class EvaluationResultsHero extends Component {
{{/if}}

{{#if this.displayQuestResult}}
<AttestationResult @results={{@questResults}} @onError={{(fn this.setGlobalError true)}} />
<AttestationResult @results={{@questResults}} @onError={{fn this.setGlobalError true}} />
{{/if}}

</div>
Expand Down
Loading
Loading