-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
62b2b15
commit 6721113
Showing
23 changed files
with
2,553 additions
and
7 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,186 @@ | ||
{ | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"label": "Update Main", | ||
"dependsOrder": "sequence", | ||
"dependsOn": [ | ||
"Git Checkout Main", | ||
"Git Pull Origin Main", | ||
"Yarn Reset Submodules", | ||
"Yarn Install Dependencies", | ||
"Yarn Compile", | ||
"Yarn Migrate" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
} | ||
}, | ||
{ | ||
"label": "Start Dev Terminals", | ||
"type": "shell", | ||
"command": "", | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
}, | ||
"dependsOn": [ | ||
"Compile Dev", | ||
"Build Dev", | ||
"Start" | ||
] | ||
}, | ||
{ | ||
"label": "Start Dev Admin Terminals", | ||
"type": "shell", | ||
"dependsOn": [ | ||
"Compile Dev", | ||
"Build Dev Admin", | ||
"Start Admin" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
}, | ||
"command": "yarn build:admin:dev && yarn start:admin --port 8082" | ||
}, | ||
{ | ||
"label": "Compile Dev", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"compile:dev" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Build Dev", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"build:dev" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Build Dev Admin", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"build:admin:dev" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Start", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"start" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Start Admin", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"start:admin", | ||
"--port", | ||
"8082" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Git Checkout Main", | ||
"type": "shell", | ||
"command": "git", | ||
"args": [ | ||
"checkout", | ||
"main" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Git Pull Origin Main", | ||
"type": "shell", | ||
"command": "git", | ||
"args": [ | ||
"pull", | ||
"origin", | ||
"main" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Yarn Reset Submodules", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"reset-submodules" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Yarn Install Dependencies", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"install" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Yarn Compile", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"compile" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
}, | ||
{ | ||
"label": "Yarn Migrate", | ||
"type": "shell", | ||
"command": "yarn", | ||
"args": [ | ||
"migrate" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": false | ||
} | ||
} | ||
] | ||
} |
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,28 @@ | ||
/* | ||
* Copyright 2024, Polytechnique Montreal and contributors | ||
* | ||
* This file is licensed under the MIT License. | ||
* License text available at https://opensource.org/licenses/MIT | ||
*/ | ||
import { TFunction } from 'i18next'; | ||
import { getI18nContext } from 'evolution-interviewer/lib/client/config/i18nextExtra.config'; | ||
import defaultConditional from 'evolution-common/lib/services/surveyGenerator/common/defaultConditional'; | ||
import * as inputTypes from 'evolution-common/lib/services/surveyGenerator/types/inputTypes'; | ||
import * as validations from './validations'; | ||
|
||
export const home_postalCode: inputTypes.InputString = { | ||
type: 'question', | ||
inputType: 'string', | ||
path: 'home.postalCode', | ||
datatype: 'string', | ||
twoColumns: false, | ||
textTransform: 'uppercase', | ||
containsHtml: true, | ||
label: (t: TFunction) => t('home:home.postalCode', { context: getI18nContext() }), | ||
validations: validations.postalCodeValidation, | ||
conditional: defaultConditional, | ||
inputFilter: (value) => { | ||
// Only accept postal code from Quebec | ||
return value.replace(/[^a-zA-Z0-9]/g, '').substring(0, 6); | ||
} | ||
}; |
Oops, something went wrong.