Skip to content

Commit

Permalink
Squash Brainstory frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
cassidoo committed Jul 1, 2024
0 parents commit 457b051
Show file tree
Hide file tree
Showing 199 changed files with 33,498 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# build output
dist/

# dependencies
node_modules/

# logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*


# environment variables
.env
.env.production
.env.development

# macOS-specific files
.DS_Store

.vscode/*
2 changes: 2 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Expose Astro dependencies for `pnpm` users
shamefully-hoist=true
14 changes: 14 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"arrowParens": "always",
"bracketSpacing": true,
"insertPragma": false,
"jsxBracketSameLine": false,
"printWidth": 100,
"proseWrap": "always",
"quoteProps": "as-needed",
"requirePragma": false,
"semi": true,
"tabWidth": 4,
"trailingComma": "none",
"useTabs": true
}
20 changes: 20 additions & 0 deletions @/components/ui/input.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import * as React from "react";

import { cn } from "@/lib/utils";
const Input = React.forwardRef(({ className, type, ...props }, ref) => {
return (
<input
type={type}
className={cn(
// "flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
"border text-stone-900 text-sm rounded-lg border-stone-300",
className
)}
ref={ref}
{...props}
/>
);
});
Input.displayName = "Input";

export { Input };
6 changes: 6 additions & 0 deletions @/lib/utils.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { clsx } from "clsx"
import { twMerge } from "tailwind-merge"

export function cn(...inputs) {
return twMerge(clsx(inputs))
}
30 changes: 30 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Brainstory

Think out loud! 🧠

## Getting Started

1. Clone the repo, navigate into it
2. `npm install`
3. `npm run dev`
4. Create a `.env.development` file at the top level and populate it with this:

```bash
PUBLIC_API_URL=<Your API URL>
```

> [!IMPORTANT]
> Look through the repository for all instances of the URL `brainstory.ai`. You will want to remove and/or replace those with your own URL (or, if you're hosting on your local machine, with localhost).
## Commands

All commands are run from the root of the project, from a terminal:

| Command | Action |
| :--------------------- | :----------------------------------------------- |
| `npm install` | Installs dependencies |
| `npm run dev` | Starts local dev server at `localhost:3000` |
| `npm run build` | Build your production site to `./dist/` |
| `npm run preview` | Preview your build locally, before deploying |
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` |
| `npm run astro --help` | Get help using the Astro CLI |
Empty file added app/globals.css
Empty file.
11 changes: 11 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { defineConfig } from "astro/config";
import tailwind from "@astrojs/tailwind";
import sitemap from "@astrojs/sitemap";
import react from "@astrojs/react";

// https://astro.build/config
export default defineConfig({
site: "https://app.brainstory.ai",
integrations: [tailwind(), sitemap(), react()],
server: { port: 5173 } // TODO change when not local
});
17 changes: 17 additions & 0 deletions components.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"$schema": "https://ui.shadcn.com/schema.json",
"style": "default",
"rsc": true,
"tsx": false,
"tailwind": {
"config": "tailwind.config.cjs",
"css": "app/globals.css",
"baseColor": "stone",
"cssVariables": true,
"prefix": ""
},
"aliases": {
"components": "@/components",
"utils": "@/lib/utils"
}
}
Loading

0 comments on commit 457b051

Please sign in to comment.