Skip to content

Commit

Permalink
feat(#18): implement initial world creation flow
Browse files Browse the repository at this point in the history
  • Loading branch information
meatwallace committed May 3, 2024
1 parent d27d31e commit eed6918
Show file tree
Hide file tree
Showing 159 changed files with 3,876 additions and 762 deletions.
47 changes: 47 additions & 0 deletions .pnp.cjs

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

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified .yarn/install-state.gz
Binary file not shown.
50 changes: 48 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# node-graphql/docker-compose.yml

version: '3.8'
services:
postgres:
Expand All @@ -12,7 +10,55 @@ services:
- PGPORT=5433
volumes:
- postgres:/var/lib/postgresql/data
expose:
- '5433'
ports:
- '5433:5433'
service-api:
build:
context: .
dockerfile: projects/service-api/Dockerfile
args:
BUILD_MODE: development
restart: always
env_file:
- projects/service-api/.env.development
environment:
- USERS_SERVICE_URL=http://service-user:3001/
- WORLDS_SERVICE_URL=http://service-world:3002/
expose:
- '3000'
ports:
- '3000:3000'
service-user:
build:
context: .
dockerfile: projects/service-user/Dockerfile
args:
BUILD_MODE: development
restart: always
env_file:
- projects/service-user/.env.development
environment:
- POSTGRES_URL=postgresql://admin:password@postgres:5433/chrononomicon
ports:
- '3001:3001'
depends_on:
- postgres
service-world:
build:
context: .
dockerfile: projects/service-world/Dockerfile
args:
BUILD_MODE: development
restart: always
env_file:
- projects/service-world/.env.development
environment:
- POSTGRES_URL=postgresql://admin:password@postgres:5433/chrononomicon
ports:
- '3002:3002'
depends_on:
- postgres
volumes:
postgres:
7 changes: 7 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,23 @@
"build:app-web": "nx build-remix app-web",
"build:service-api": "nx build service-api",
"build:service-user": "nx build service-user",
"build:service-world": "nx build service-world",
"deploy:app-web": "nx deploy app-web",
"deploy:service-api": "nx deploy service-api",
"deploy:service-user": "nx deploy service-user",
"deploy:service-world": "nx deploy service-world",
"dev:app-web": "nx serve app-web",
"dev:service-api": "dotenvx run -f projects/service-api/.env.development -- yarn run nx serve service-api",
"dev:service-user": "dotenvx run -f projects/service-user/.env.development -- yarn run nx serve service-user",
"dev:service-world": "dotenvx run -f projects/service-world/.env.development -- yarn run nx serve service-world",
"e2e:app-web": "nx e2e app-web-e2e",
"test:app-web": "nx test-watch app-web",
"test:lib-postgres-schema": "nx test-watch lib-postgres-schema",
"test:lib-service-test-utils": "nx test-watch lib-service-test-utils",
"test:lib-service-utils": "nx test-watch lib-service-utils",
"test:service-api": "nx test-watch service-api",
"test:service-user": "nx test-watch service-user",
"test:service-world": "nx test-watch service-world",
"---UTILITY": "",
"postinstall": "husky"
},
Expand Down Expand Up @@ -125,8 +129,10 @@
"@remix-run/serve": "2.9.1",
"@remix-run/server-runtime": "2.9.1",
"@vanilla-extract/css": "1.15.1",
"@vanilla-extract/recipes": "0.5.2",
"@vanilla-extract/sprinkles": "1.6.1",
"auth0": "4.3.1",
"clsx": "2.1.1",
"drizzle-orm": "0.30.9",
"envalid": "8.0.0",
"got": "14.2.1",
Expand All @@ -138,6 +144,7 @@
"isbot": "4",
"jsonwebtoken": "9.0.2",
"jwks-rsa": "3.1.0",
"open-props": "1.7.4",
"postgres": "3.4.4",
"react": "18.2.0",
"react-dom": "18.2.0",
Expand Down
55 changes: 55 additions & 0 deletions projects/app-web/app/components/brand.css.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
import { recipe } from '@vanilla-extract/recipes';

export const container = recipe({
base: {
alignSelf: 'center',
color: '#0087ff',
display: 'flex',
fontFamily: 'Josefin Sans, sans-serif',
fontWeight: 500,
lineHeight: 1,
textTransform: 'uppercase',
},
variants: {
size: {
small: {
fontSize: '24px',
},
medium: {
fontSize: '48px',
},
large: {
fontSize: '72px',
},
},
},
defaultVariants: {
size: 'medium',
},
});

export const icon = recipe({
base: {},
variants: {
size: {
small: {
height: '22px',
marginTop: '-2px',
width: '22px',
},
medium: {
height: '42px',
marginTop: '-2px',
width: '42px',
},
large: {
height: '68px',
marginTop: '-6px',
width: '68px',
},
},
},
defaultVariants: {
size: 'medium',
},
});
23 changes: 23 additions & 0 deletions projects/app-web/app/components/brand.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import clsx from 'clsx';
import { RecipeVariants } from '@vanilla-extract/recipes';
import * as styles from './brand.css.ts';

type Props = {
className?: string;
} & RecipeVariants<typeof styles.container>;

export function Brand(props: Props) {
return (
<h1
className={clsx(styles.container({ size: props.size }), props.className)}
>
Chron
<img
alt="Chrononomicon brand icon"
src="/assets/images/brand-icon-light.png"
className={styles.icon({ size: props.size })}
/>
nomicon
</h1>
);
}
85 changes: 48 additions & 37 deletions projects/app-web/app/components/button.css.ts
Original file line number Diff line number Diff line change
@@ -1,41 +1,52 @@
import { style, styleVariants } from '@vanilla-extract/css';
import { recipe } from '@vanilla-extract/recipes';

const buttonBase = style({
borderRadius: '4px',
display: 'flex',
fontFamily: 'Josefin Slab Bold, sans-serif',
fontSize: '18px',
justifyContent: 'center',
marginBottom: '8px',
minWidth: '160px',
padding: '13px 16px 8px',
textAlign: 'center',
textTransform: 'uppercase',
});

export const buttonVariants = styleVariants({
primary: [
buttonBase,
{
backgroundColor: '#0087ff',
border: 'none',
color: '#ddefff',
},
],
secondary: [
buttonBase,
{
backgroundColor: '#ffffff0d',
border: '1px solid #0087ff',
color: '#0087ff',
export const button = recipe({
base: {
borderRadius: '4px',
display: 'flex',
fontFamily: 'Josefin Slab, sans-serif',
justifyContent: 'center',
textAlign: 'center',
textTransform: 'uppercase',
},
variants: {
color: {
primary: {
backgroundColor: '#0087ff',
border: 'none',
color: '#ddefff',
},
secondary: {
backgroundColor: '#ffffff0d',
border: '1px solid #0087ff',
color: '#0087ff',
},
transparent: {
backgroundColor: '#ffffff0d',
border: '1px solid #0087ff',
color: '#0087ff',
},
},
],
transparent: [
buttonBase,
{
backgroundColor: '#ffffff0d',
border: '1px solid #0087ff',
color: '#0087ff',
size: {
small: {
fontSize: '14px',
minWidth: '120px',
padding: '12px 16px 8px',
},
medium: {
fontSize: '18px',
minWidth: '160px',
padding: '13px 16px 8px',
},
large: {
fontSize: '24px',
minWidth: '2000px',
padding: '18px 20px 12px',
},
},
],
},
defaultVariants: {
color: 'primary',
size: 'medium',
},
});
Loading

0 comments on commit eed6918

Please sign in to comment.