Arcoloc autocompletion
This commit is contained in:
parent
ca73ef8b11
commit
80134962bc
2 changed files with 9 additions and 0 deletions
|
@ -6,6 +6,7 @@
|
||||||
"contentType": "firstname",
|
"contentType": "firstname",
|
||||||
"label": "Prénom",
|
"label": "Prénom",
|
||||||
"autocomplete": "given-name",
|
"autocomplete": "given-name",
|
||||||
|
"value": "",
|
||||||
"placeholder": "Camille"
|
"placeholder": "Camille"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -14,6 +15,7 @@
|
||||||
"contentType": "lastname",
|
"contentType": "lastname",
|
||||||
"label": "Nom",
|
"label": "Nom",
|
||||||
"autocomplete": "family-name",
|
"autocomplete": "family-name",
|
||||||
|
"value": "",
|
||||||
"placeholder": "Dupont"
|
"placeholder": "Dupont"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -24,6 +26,7 @@
|
||||||
"autocomplete": "birthday",
|
"autocomplete": "birthday",
|
||||||
"pattern": "^([0][1-9]|[1-2][0-9]|30|31)\/([0][1-9]|10|11|12)\/(19[0-9][0-9]|20[0-1][0-9]|2020)",
|
"pattern": "^([0][1-9]|[1-2][0-9]|30|31)\/([0][1-9]|10|11|12)\/(19[0-9][0-9]|20[0-1][0-9]|2020)",
|
||||||
"maxlength": 10,
|
"maxlength": 10,
|
||||||
|
"value": "",
|
||||||
"placeholder": "01/01/1970"
|
"placeholder": "01/01/1970"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -34,6 +37,7 @@
|
||||||
"contentType": "cityofbirth",
|
"contentType": "cityofbirth",
|
||||||
"label": "Lieu de naissance",
|
"label": "Lieu de naissance",
|
||||||
"autocomplete": "off",
|
"autocomplete": "off",
|
||||||
|
"value": "",
|
||||||
"placeholder": "Paris"
|
"placeholder": "Paris"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -42,6 +46,7 @@
|
||||||
"contentType": "address",
|
"contentType": "address",
|
||||||
"label": "Adresse",
|
"label": "Adresse",
|
||||||
"autocomplete": "adress-line1",
|
"autocomplete": "adress-line1",
|
||||||
|
"value": "41 rue Pierre Curie",
|
||||||
"placeholder": "999 avenue de France"
|
"placeholder": "999 avenue de France"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -50,6 +55,7 @@
|
||||||
"contentType": "city",
|
"contentType": "city",
|
||||||
"label": "Ville",
|
"label": "Ville",
|
||||||
"autocomplete": "address-level2",
|
"autocomplete": "address-level2",
|
||||||
|
"value": "Arcueil",
|
||||||
"placeholder": "Paris"
|
"placeholder": "Paris"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -58,6 +64,7 @@
|
||||||
"contentType": "zipcode",
|
"contentType": "zipcode",
|
||||||
"label": "Code Postal",
|
"label": "Code Postal",
|
||||||
"autocomplete": "postal-code",
|
"autocomplete": "postal-code",
|
||||||
|
"value": "94110",
|
||||||
"placeholder": "75001",
|
"placeholder": "75001",
|
||||||
"inputmode": "numeric",
|
"inputmode": "numeric",
|
||||||
"pattern": "[0-9]{5}",
|
"pattern": "[0-9]{5}",
|
||||||
|
|
|
@ -31,6 +31,7 @@ const createFormGroup = ({
|
||||||
pattern,
|
pattern,
|
||||||
placeholder = '',
|
placeholder = '',
|
||||||
type = 'text',
|
type = 'text',
|
||||||
|
value = '',
|
||||||
}) => {
|
}) => {
|
||||||
const formGroup = createElement('div', { className: 'form-group' })
|
const formGroup = createElement('div', { className: 'form-group' })
|
||||||
const labelAttrs = {
|
const labelAttrs = {
|
||||||
|
@ -56,6 +57,7 @@ const createFormGroup = ({
|
||||||
placeholder,
|
placeholder,
|
||||||
required: true,
|
required: true,
|
||||||
type,
|
type,
|
||||||
|
value,
|
||||||
}
|
}
|
||||||
|
|
||||||
const input = createElement('input', inputAttrs)
|
const input = createElement('input', inputAttrs)
|
||||||
|
|
Loading…
Reference in a new issue