Upload 2 files
Browse files- _utils/index.ts +132 -0
- _utils/prisma.ts +4 -0
_utils/index.ts
ADDED
|
@@ -0,0 +1,132 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import { PiIslandFill } from "react-icons/pi";
|
| 2 |
+
import { MdSportsVolleyball } from "react-icons/md";
|
| 3 |
+
import { RiShoppingCart2Fill } from "react-icons/ri";
|
| 4 |
+
import { MdRealEstateAgent } from "react-icons/md";
|
| 5 |
+
import { TbWorld } from "react-icons/tb";
|
| 6 |
+
import { GrTechnology } from "react-icons/gr";
|
| 7 |
+
import { BiSolidParty } from "react-icons/bi";
|
| 8 |
+
import { IoMdMedical } from "react-icons/io";
|
| 9 |
+
import { MdRestaurant } from "react-icons/md";
|
| 10 |
+
import { FaPiggyBank } from "react-icons/fa6";
|
| 11 |
+
import { MdMovieFilter } from "react-icons/md";
|
| 12 |
+
import { IoBuildSharp } from "react-icons/io5";
|
| 13 |
+
import { MdSchool } from "react-icons/md";
|
| 14 |
+
import { GiLipstick } from "react-icons/gi";
|
| 15 |
+
import { FaCar } from "react-icons/fa";
|
| 16 |
+
import { MdPets } from "react-icons/md";
|
| 17 |
+
import { FaPaintBrush } from "react-icons/fa";
|
| 18 |
+
import { IoMusicalNotes } from "react-icons/io5";
|
| 19 |
+
import { MdPhotoCamera } from "react-icons/md";
|
| 20 |
+
|
| 21 |
+
export const INDUSTRIES = [
|
| 22 |
+
{
|
| 23 |
+
name: "Travel",
|
| 24 |
+
icon: PiIslandFill,
|
| 25 |
+
},
|
| 26 |
+
{
|
| 27 |
+
name: "Sports Fitness",
|
| 28 |
+
icon: MdSportsVolleyball,
|
| 29 |
+
},
|
| 30 |
+
{
|
| 31 |
+
name: "Retail",
|
| 32 |
+
icon: RiShoppingCart2Fill,
|
| 33 |
+
},
|
| 34 |
+
{
|
| 35 |
+
name: "Real Estate",
|
| 36 |
+
icon: MdRealEstateAgent,
|
| 37 |
+
},
|
| 38 |
+
{
|
| 39 |
+
name: "Internet",
|
| 40 |
+
icon: TbWorld,
|
| 41 |
+
},
|
| 42 |
+
{
|
| 43 |
+
name: "Technology",
|
| 44 |
+
icon: GrTechnology,
|
| 45 |
+
},
|
| 46 |
+
{
|
| 47 |
+
name: "Events",
|
| 48 |
+
icon: BiSolidParty,
|
| 49 |
+
},
|
| 50 |
+
{
|
| 51 |
+
name: "Medical",
|
| 52 |
+
icon: IoMdMedical,
|
| 53 |
+
},
|
| 54 |
+
{
|
| 55 |
+
name: "Restaurant",
|
| 56 |
+
icon: MdRestaurant,
|
| 57 |
+
},
|
| 58 |
+
{
|
| 59 |
+
name: "Finance",
|
| 60 |
+
icon: FaPiggyBank,
|
| 61 |
+
},
|
| 62 |
+
{
|
| 63 |
+
name: "Entertainment",
|
| 64 |
+
icon: MdMovieFilter,
|
| 65 |
+
},
|
| 66 |
+
{
|
| 67 |
+
name: "Construction",
|
| 68 |
+
icon: IoBuildSharp,
|
| 69 |
+
},
|
| 70 |
+
{
|
| 71 |
+
name: "Education",
|
| 72 |
+
icon: MdSchool,
|
| 73 |
+
},
|
| 74 |
+
{
|
| 75 |
+
name: "Beauty",
|
| 76 |
+
icon: GiLipstick,
|
| 77 |
+
},
|
| 78 |
+
{
|
| 79 |
+
name: "Automotive",
|
| 80 |
+
icon: FaCar,
|
| 81 |
+
},
|
| 82 |
+
{
|
| 83 |
+
name: "Animal Pets",
|
| 84 |
+
icon: MdPets,
|
| 85 |
+
},
|
| 86 |
+
{
|
| 87 |
+
name: "Art",
|
| 88 |
+
icon: FaPaintBrush,
|
| 89 |
+
},
|
| 90 |
+
{
|
| 91 |
+
name: "Music",
|
| 92 |
+
icon: IoMusicalNotes,
|
| 93 |
+
},
|
| 94 |
+
{
|
| 95 |
+
name: "Photography",
|
| 96 |
+
icon: MdPhotoCamera,
|
| 97 |
+
},
|
| 98 |
+
{
|
| 99 |
+
name: "Other",
|
| 100 |
+
},
|
| 101 |
+
];
|
| 102 |
+
|
| 103 |
+
export const THEMES = [
|
| 104 |
+
{
|
| 105 |
+
name: "Warm",
|
| 106 |
+
},
|
| 107 |
+
{
|
| 108 |
+
name: "Pastel",
|
| 109 |
+
},
|
| 110 |
+
{
|
| 111 |
+
name: "Cold",
|
| 112 |
+
},
|
| 113 |
+
{
|
| 114 |
+
name: "Contrast",
|
| 115 |
+
},
|
| 116 |
+
{
|
| 117 |
+
name: "Greyscale",
|
| 118 |
+
},
|
| 119 |
+
{
|
| 120 |
+
name: "Gradient",
|
| 121 |
+
},
|
| 122 |
+
];
|
| 123 |
+
|
| 124 |
+
export const arrayBufferToBase64 = (buffer: ArrayBuffer) => {
|
| 125 |
+
let binary = "";
|
| 126 |
+
const bytes = new Uint8Array(buffer);
|
| 127 |
+
const len = bytes.byteLength;
|
| 128 |
+
for (let i = 0; i < len; i++) {
|
| 129 |
+
binary += String.fromCharCode(bytes[i]);
|
| 130 |
+
}
|
| 131 |
+
return window.btoa(binary);
|
| 132 |
+
};
|
_utils/prisma.ts
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import { PrismaClient } from "@prisma/client";
|
| 2 |
+
|
| 3 |
+
const prisma = new PrismaClient();
|
| 4 |
+
export default prisma;
|