Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ZoneSixGames committed Mar 8, 2023
1 parent c56733c commit c4175d0
Show file tree
Hide file tree
Showing 19 changed files with 2,463 additions and 836 deletions.
3 changes: 3 additions & 0 deletions .vs/ProjectSettings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"CurrentProjectSetting": null
}
16 changes: 16 additions & 0 deletions .vs/VSWorkspaceState.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"ExpandedNodes": [
"",
"\\client",
"\\client\\src",
"\\client\\src\\assets",
"\\client\\src\\page",
"\\client\\src\\utils",
"\\server",
"\\server\\mongodb",
"\\server\\mongodb\\models",
"\\server\\routes"
],
"SelectedNode": "\\server\\index.js",
"PreviewInSolutionExplorer": false
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
1,016 changes: 1,016 additions & 0 deletions .vs/gabby/config/applicationhost.config

Large diffs are not rendered by default.

Binary file added .vs/gabby/v17/.suo
Binary file not shown.
Binary file added .vs/slnx.sqlite
Binary file not shown.
4 changes: 2 additions & 2 deletions client/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<link rel="icon" href="./src/assets/logo.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="https://rsms.me/inter/inter.css">
<title>DALL-E 2.0</title>
<title>Bleep Bloop AI</title>
</head>
<body>
<div id="root"></div>
Expand Down
24 changes: 12 additions & 12 deletions client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@
"@types/react": "^18.0.26",
"@types/react-dom": "^18.0.9",
"@vitejs/plugin-react": "^3.0.0",
"vite": "^4.0.0",
"autoprefixer": "^10.4.13",
"eslint": "^8.31.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-jsx-a11y": "^6.6.1",
"eslint-plugin-react": "^7.31.11",
"eslint-plugin-react-hooks": "^4.6.0",
"postcss": "^8.4.20",
"tailwindcss": "^3.2.4"
"postcss": "^8.4.21",
"tailwindcss": "^3.2.7",
"vite": "^4.0.0"
}
}
}
2 changes: 1 addition & 1 deletion client/src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const App = () => (
<img src={logo} alt="logo" className="w-28 object-contain" />
</Link>

<Link to="/create-post" className="font-inter font-medium bg-[#6469ff] text-white px-4 py-2 rounded-md">Create</Link>
<Link to="/create-post" className="font-inter font-medium bg-[#00F] text-white px-4 py-2 rounded-md">Create</Link>
</header>
<main className="sm:p-8 px-4 py-8 w-full bg-[#f9fafe] min-h-[calc(100vh-73px)]">
<Routes>
Expand Down
11 changes: 10 additions & 1 deletion client/src/assets/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 5 additions & 5 deletions client/src/page/CreatePost.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const CreatePost = () => {
if (form.prompt) {
try {
setGeneratingImg(true);
const response = await fetch('https://dalle-arbb.onrender.com/api/v1/dalle', {
const response = await fetch('http://localhost:8080/api/v1/dalle', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Expand Down Expand Up @@ -56,7 +56,7 @@ const CreatePost = () => {
if (form.prompt && form.photo) {
setLoading(true);
try {
const response = await fetch('https://dalle-arbb.onrender.com/api/v1/post', {
const response = await fetch('http://localhost:8080/api/v1/post', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Expand Down Expand Up @@ -133,17 +133,17 @@ const CreatePost = () => {
<button
type="button"
onClick={generateImage}
className=" text-white bg-green-700 font-medium rounded-md text-sm w-full sm:w-auto px-5 py-2.5 text-center"
className=" text-white bg-[#00F] font-medium rounded-md text-sm w-full sm:w-auto px-5 py-2.5 text-center"
>
{generatingImg ? 'Generating...' : 'Generate'}
</button>
</div>

<div className="mt-10">
<p className="mt-2 text-[#666e75] text-[14px]">** Once you have created the image you want, you can share it with others in the community **</p>
<p className="mt-2 text-blk text-[14px]">** Once you have created the animation you want, you can share it with others in the community **</p>
<button
type="submit"
className="mt-3 text-white bg-[#6469ff] font-medium rounded-md text-sm w-full sm:w-auto px-5 py-2.5 text-center"
className="mt-3 text-white bg-[#00F] font-medium rounded-md text-sm w-full sm:w-auto px-5 py-2.5 text-center"
>
{loading ? 'Sharing...' : 'Share with the Community'}
</button>
Expand Down
4 changes: 2 additions & 2 deletions client/src/page/Home.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const Home = () => {
setLoading(true);

try {
const response = await fetch('https://dalle-arbb.onrender.com/api/v1/post', {
const response = await fetch('http://localhost:8080/api/v1/post', {
method: 'GET',
headers: {
'Content-Type': 'application/json',
Expand Down Expand Up @@ -64,7 +64,7 @@ const Home = () => {
<section className="max-w-7xl mx-auto">
<div>
<h1 className="font-extrabold text-[#222328] text-[32px]">The Community Showcase</h1>
<p className="mt-2 text-[#666e75] text-[14px] max-w-[500px]">Browse through a collection of imaginative and visually stunning images generated by DALL-E AI</p>
<p className="mt-2 text-[#666e75] text-[14px] max-w-[500px]">Browse through the dreams of others...</p>
</div>

<div className="mt-16">
Expand Down
4 changes: 2 additions & 2 deletions server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ app.use('/api/v1/dalle', dalleRoutes);

app.get('/', async (req, res) => {
res.status(200).json({
message: 'Hello from DALL.E!',
message: 'Hello from Gabby!',
});
});

const startServer = async () => {
try {
connectDB(process.env.MONGODB_URL);
app.listen(8080, () => console.log('Server started on port 8080'));
app.listen(8080, () => console.log('Server started on port http://localhost:8080'));
} catch (error) {
console.log(error);
}
Expand Down
Loading

0 comments on commit c4175d0

Please sign in to comment.