Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
/coverage

# production
/build
**/build
**/dist
**/.sanity

# misc
.DS_Store
Expand All @@ -18,13 +20,20 @@
.env.development.local
.env.test.local
.env.production.local
*.local

# Logs
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.DS_Store
package-lock.json
.vscode/settings.json
/logs
*.log

# TypeScript
*.tsbuildinfo

.idea/
.vscode/
2 changes: 1 addition & 1 deletion .oxfmtrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"singleQuote": true,
"trailingComma": "es5",
"arrowParens": "avoid",
"ignorePatterns": [".github/**", "tools/oxlint/anti-slop/**"],
"ignorePatterns": [".github/**", "tools/oxlint/anti-slop/**", "src/sanity/types.ts"],
"experimentalSortImports": {
"groups": ["builtin", "external", "internal", ["parent", "sibling", "index"]]
},
Expand Down
2,832 changes: 2,577 additions & 255 deletions bun.lock

Large diffs are not rendered by default.

14 changes: 11 additions & 3 deletions knip.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,20 @@
"$schema": "https://unpkg.com/knip@6/schema.json",
"workspaces": {
".": {
"entry": ["src/index.{js,ts}"],
"entry": ["src/index.{js,jsx,ts,tsx}"],
"project": ["src/**/*.{js,jsx,ts,tsx}"]
},
"sanity": {
"app/studio": {
"entry": ["sanity.config.{js,ts}", "sanity.cli.{js,ts}"],
"project": ["**/*.{js,ts}"]
"project": ["**/*.{js,ts}"],
"ignoreDependencies": [
"react",
"react-dom",
"styled-components",
"@sanity/eslint-config-studio",
"@types/react",
"eslint"
]
}
},
"treatTagHintsAsErrors": true,
Expand Down
18 changes: 15 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,19 +14,30 @@
"lint:fix": "oxlint --fix",
"fmt:check": "oxfmt --check",
"fmt": "oxfmt",
"prepare": "husky"
"prepare": "husky",
"sanity:dev": "sanity dev",
"sanity:preview": "sanity preview",
"sanity:build": "sanity build",
"sanity:deploy": "sanity deploy",
"sanity:deploy-graphql": "sanity graphql deploy"
},
"dependencies": {
"@headlessui/react": "^2.2.10",
"@sanity/client": "^8.2.0",
"@portabletext/react": "^8.0.1",
"@sanity/cli": "^8.2.1",
"@sanity/client": "^8.5.0",
"@sanity/color-input": "^6.1.4",
"@sanity/image-url": "^2.1.1",
"react": "^19.2.8",
"react-bootstrap": "^2.10.10",
"react-dom": "^19.2.8",
"react-router-dom": "^7.18.2"
"react-router-dom": "^7.18.2",
"styled-components": "^6.5.3"
},
"devDependencies": {
"@oxlint/plugins": "1.79.0",
"@sanity/eslint-config-studio": "^6.0.0",
"@sanity/types": "^6.12.0",
"@types/node": "^26.2.0",
"@vitejs/plugin-react": "^6.1.1",
"eslint-plugin-react-you-might-not-need-an-effect": "^1.0.2",
Expand All @@ -36,6 +47,7 @@
"oxfmt": "^0.64.0",
"oxlint": "^1.79.0",
"oxlint-tsgolint": "^7.0.2001",
"sanity": "^6.12.0",
"typescript": "^7.0.2",
"vite": "^8.2.2",
"vite-plugin-svgr": "^5.2.0",
Expand Down
15 changes: 15 additions & 0 deletions sanity.cli.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import { defineCliConfig } from 'sanity/cli';

export default defineCliConfig({
api: {
projectId: '4whxapdc',
dataset: 'generate-schema',
},

typegen: {
path: 'src/sanity/schemaTypes/*.{ts,tsx,js,jsx}',
schema: 'src/sanity/schema.json',
generates: 'src/sanity/types.ts',
formatGeneratedCode: false,
},
});
19 changes: 19 additions & 0 deletions sanity.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { colorInput } from '@sanity/color-input';
import { visionTool } from '@sanity/vision';
import { defineConfig } from 'sanity';
import { structureTool } from 'sanity/structure';

import { schemaTypes } from './src/sanity/schemaTypes';

export default defineConfig({
name: 'default',
title: 'generate-sanity',
projectId: '4whxapdc',
dataset: 'generate-schema',

plugins: [structureTool(), visionTool(), colorInput()],

schema: {
types: schemaTypes,
},
});
29 changes: 0 additions & 29 deletions sanity/.gitignore

This file was deleted.

2,717 changes: 0 additions & 2,717 deletions sanity/bun.lock

This file was deleted.

38 changes: 0 additions & 38 deletions sanity/package.json

This file was deleted.

8 changes: 0 additions & 8 deletions sanity/sanity.cli.js

This file was deleted.

19 changes: 0 additions & 19 deletions sanity/sanity.config.js

This file was deleted.

31 changes: 0 additions & 31 deletions sanity/schemas/copy.js

This file was deleted.

19 changes: 0 additions & 19 deletions sanity/schemas/index.jsx

This file was deleted.

2 changes: 1 addition & 1 deletion src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import CulturePage from './component/CulturePage'
import TeamsPage from './pages/TeamsPage'
import ExpandedTeamsPage from './pages/TeamsPage/ExpandedTeams'
import ProjectsPage from './component/ProjectsPage'
import { useSanity } from './services/useSanity'
import { useSanity } from './sanity/useSanity'

function AppRoutes({ sanityRoutes }) {
const routes = [
Expand Down
16 changes: 0 additions & 16 deletions src/client.js

This file was deleted.

2 changes: 1 addition & 1 deletion src/pages/ApplyPageV2/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react'
import NavBar from '../../component/NavBar'
import TeamApplicationCard from './TeamApplicationCard'
import Footer from '../LandingPageV3/Footer'
import { useSanity } from '../../services/useSanity'
import { useSanity } from '../../sanity/useSanity'
import useWebsite from '../../shared/useWebsite'
import './style.css'

Expand Down
4 changes: 2 additions & 2 deletions src/pages/LandingPageV3/CelebrateOurWins/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import LargeStars from '../../../assets/images/landingpage-v3/LargeShowcaseStars
import SmallStars from '../../../assets/images/landingpage-v3/SmallShowcaseStars.svg?react'
import PrevArrow from '../../../assets/icons/arrows/prevArrowLeft.svg?react'
import NextArrow from '../../../assets/icons/arrows/nextArrowRight.svg?react'
import { useSanity } from '../../../services/useSanity'
import { urlFor } from '../../../client'
import { useSanity } from '../../../sanity/useSanity'
import { urlFor } from '../../../sanity/client'

export default function CelebrateOurWins() {
const copyQuery = `*[_type == "copy" && key == "celebrate-our-wins"]{header, content}`
Expand Down
4 changes: 2 additions & 2 deletions src/pages/LandingPageV3/ChooseYourCharacter/index.jsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import React, { useEffect, useState } from 'react'
import ArcadeText from '../../../assets/images/landingpage-v3/DynamicArcadeText.jsx'
import ArcadeMachine from '../../../assets/images/landingpage-v3/DynamicArcadeMachine.jsx'
import { urlFor } from '../../../client.js'
import { useSanity } from '../../../services/useSanity.js'
import { urlFor } from '../../../sanity/client'
import { useSanity } from '../../../sanity/useSanity'
import Mascot from './Mascot.jsx'

const MascotRadioButton = ({
Expand Down
4 changes: 2 additions & 2 deletions src/pages/LandingPageV3/HowWereStructured/index.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useEffect, useState } from 'react'
import { useSanity } from '../../../services/useSanity'
import { urlFor } from '../../../client'
import { useSanity } from '../../../sanity/useSanity'
import { urlFor } from '../../../sanity/client'
import './style.css'

const ARC_STEPS = 16
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LandingPageV3/WeAre/index.jsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import weare from '../../../assets/images/landingpage/weare/weare.jpg'
import { useSanity } from '../../../services/useSanity'
import { useSanity } from '../../../sanity/useSanity'

export default function WeAre() {
const query = `*[_type == "value"] {value, index} | order(index asc)`
Expand Down
2 changes: 1 addition & 1 deletion src/pages/LandingPageV3/WhatIsGenerate/index.jsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react'
import { useSanity } from '../../../services/useSanity'
import { useSanity } from '../../../sanity/useSanity'
import workshop from '../../../assets/images/landingpage/weare/workshop.jpg'
import showcase from '../../../assets/images/landingpage/weare/showcase.jpg'

Expand Down
2 changes: 1 addition & 1 deletion src/pages/LandingPageV3/WhyGenerate/index.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import members from '../../../assets/images/landingpage/weare/members.JPG'
import clients from '../../../assets/images/landingpage/weare/cstar.jpg'
import partners from '../../../assets/images/landingpage/weare/overhead.jpg'
import { useSanity } from '../../../services/useSanity'
import { useSanity } from '../../../sanity/useSanity'

export default function WhyGenerate() {
const query1 = `*[_type == "copy" && key == "why-generate-1"]{header, content}`
Expand Down
File renamed without changes.
13 changes: 13 additions & 0 deletions src/sanity/client.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { createClient } from '@sanity/client';
import { createImageUrlBuilder, ImageUrlBuilder } from '@sanity/image-url';
import type { Image } from '@sanity/types';

export const client = createClient({
projectId: import.meta.env.VITE_SANITY_PROJECT_ID,
dataset: import.meta.env.VITE_SANITY_DATASET,
apiVersion: '2026-09-05',
useCdn: true,
});

const builder = createImageUrlBuilder(client);
export const urlFor = (source: Image): ImageUrlBuilder => builder.image(source);
Loading