Initial commit
Création de tous les dossiers et fichiers avec mise à part des constantes
This commit is contained in:
commit
4c71fb59b4
42 changed files with 2544 additions and 0 deletions
13
scripts/fonctions.js
Normal file
13
scripts/fonctions.js
Normal file
|
@ -0,0 +1,13 @@
|
|||
export var setEventSample = function(iRechercheIngredients, ldIngredients){
|
||||
iRechercheIngredients.addEventListener('input', function (el, index, table){
|
||||
Array.from(ldIngredients).forEach(function(el, index, ldIngredients){
|
||||
|
||||
if(RegExp("div-.*" + this.value, 'i').test(el.getAttribute('nom'))){
|
||||
el.classList.remove('sample');
|
||||
}
|
||||
else{
|
||||
el.classList.add("sample");
|
||||
}
|
||||
}, iRechercheIngredients);
|
||||
});
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue