Browse Source

🛠️ Implemented random data generation functions

📸 Added functions for generating random images, titles, and names
🔖 Included functions for random tag and avatar selection
🌟 Enhanced project with dynamic data sources
🚀 Ready to start building with dynamic content!
main
John Doe 1 year ago
parent
commit
c4f04ae2fc
  1. 125
      src/contains/fakeData.ts

125
src/contains/fakeData.ts

@ -0,0 +1,125 @@
export const avatarImgs = [
"https://randomuser.me/api/portraits/men/32.jpg",
"https://randomuser.me/api/portraits/women/44.jpg",
"https://randomuser.me/api/portraits/men/46.jpg",
"https://randomuser.me/api/portraits/men/97.jpg",
"https://uifaces.co/our-content/donated/1H_7AxP0.jpg",
"https://randomuser.me/api/portraits/women/9.jpg",
"https://images-na.ssl-images-amazon.com/images/M/MV5BYzg2NDY4MjAtZDBjNS00MGRhLWJkZDMtYWJkZDM1NWZiMzgyXkEyXkFqcGdeQXVyMTE1MzA3MTI@._V1_UX172_CR0,0,172,256_AL_.jpg",
"https://uifaces.co/our-content/donated/VUMBKh1U.jpg",
];
const personNames = [
"Kailey Greer",
"Karli Costa",
"Camren Barnes",
"Belinda Ritter",
"Jameson Dickerson",
"Giada Mann",
"Evie Osborn",
"Juliet Mcpherson",
"Charlize Raymond",
"Amaris Pittman",
"Arnav Morris",
"Malakai Casey",
"Nevaeh Henry",
"Mireya Roman",
"Anthony Wyatt",
"Mike Orr",
"Azul Hull",
"Derick Hubbard",
];
const tagNames = [
"Life",
"Travel",
"Music",
"Beauty",
"Beach",
"Hotdog",
"Car",
"Bike",
"Wordpress",
"Php",
"Javascript",
"Vue",
"Reactjs",
"Androind",
];
const featuredImgs = [
"https://images.pexels.com/photos/1337753/pexels-photo-1337753.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/761963/pexels-photo-761963.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/374876/pexels-photo-374876.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/3225531/pexels-photo-3225531.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/1020016/pexels-photo-1020016.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/1154638/pexels-photo-1154638.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/2827374/pexels-photo-2827374.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/1640777/pexels-photo-1640777.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/842571/pexels-photo-842571.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/315755/pexels-photo-315755.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/1391487/pexels-photo-1391487.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/704971/pexels-photo-704971.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/248547/pexels-photo-248547.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/209977/pexels-photo-209977.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
"https://images.pexels.com/photos/848618/pexels-photo-848618.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500",
];
const imgHigtQualitys = [
"https://images.pexels.com/photos/6168061/pexels-photo-6168061.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/5913391/pexels-photo-5913391.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/5913170/pexels-photo-5913170.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/4617820/pexels-photo-4617820.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/6136086/pexels-photo-6136086.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/4443477/pexels-photo-4443477.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/4273989/pexels-photo-4273989.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/4806731/pexels-photo-4806731.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
"https://images.pexels.com/photos/5499131/pexels-photo-5499131.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
];
const aTitles = [
"adipiscing bibendum est ultricies integer quis auctor elit sed vulputate",
"in arcu cursus euismod quis viverra nibh cras pulvinar mattis",
"natoque penatibus et magnis dis parturient montes nascetur ridiculus mus",
"et leo duis ut diam quam nulla porttitor massa id",
"turpis cursus in hac habitasse platea dictumst quisque sagittis purus",
"ut faucibus pulvinar elementum integer enim neque volutpat ac tincidunt",
"interdum velit euismod in pellentesque massa placerat duis ultricies lacus",
"fringilla ut morbi tincidunt augue interdum velit euismod in pellentesque",
"sagittis vitae et leo duis ut diam quam nulla porttitor",
"in mollis nunc sed id semper risus in hendrerit gravida",
"tellus integer feugiat scelerisque varius morbi enim nunc faucibus a",
"eleifend mi in nulla posuere sollicitudin aliquam ultrices sagittis orci",
"non sodales neque sodales ut etiam sit amet nisl purus",
];
function _getTitleRd() {
return aTitles[Math.floor(Math.random() * aTitles.length)];
}
function _getPersonNameRd() {
return personNames[Math.floor(Math.random() * personNames.length)];
}
function _getImgRd() {
return featuredImgs[Math.floor(Math.random() * featuredImgs.length)];
}
function _getImgHightQualityRd() {
return imgHigtQualitys[Math.floor(Math.random() * imgHigtQualitys.length)];
}
function _getTagNameRd() {
return tagNames[Math.floor(Math.random() * tagNames.length)];
}
function _getAvatarRd() {
return avatarImgs[Math.floor(Math.random() * avatarImgs.length)];
}
export {
_getImgRd,
_getTagNameRd,
_getAvatarRd,
_getImgHightQualityRd,
_getTitleRd,
_getPersonNameRd,
};
Loading…
Cancel
Save