Merged new Docs and Demos

This commit is contained in:
Cagatay Civici 2023-02-28 11:29:30 +03:00
parent 296cc217fb
commit dfcc8ef4e7
1235 changed files with 130757 additions and 122640 deletions

View file

@ -1,7 +1,7 @@
export default class CarService {
brands = ['Vapid', 'Carson', 'Kitano', 'Dabver', 'Ibex', 'Morello', 'Akira', 'Titan', 'Dover', 'Norma'];
export const CarService = {
brands: ['Vapid', 'Carson', 'Kitano', 'Dabver', 'Ibex', 'Morello', 'Akira', 'Titan', 'Dover', 'Norma'],
colors = ['Black', 'White', 'Red', 'Blue', 'Silver', 'Green', 'Yellow'];
colors: ['Black', 'White', 'Red', 'Blue', 'Silver', 'Green', 'Yellow'],
generateCar(id) {
return {
@ -11,7 +11,7 @@ export default class CarService {
color: this.generateColor(),
year: this.generateYear()
};
}
},
generateVin() {
let text = '';
@ -22,17 +22,17 @@ export default class CarService {
}
return text;
}
},
generateBrand() {
return this.brands[Math.floor(Math.random() * Math.floor(10))];
}
},
generateColor() {
return this.colors[Math.floor(Math.random() * Math.floor(7))];
}
},
generateYear() {
return 2000 + Math.floor(Math.random() * Math.floor(19));
}
}
};