Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev #41

Merged
merged 7 commits into from
Mar 16, 2024
Merged

Dev #41

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: 11 additions & 0 deletions .changeset/friendly-tomatoes-press.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"eslint-config-custom": major
"tailwind-config": major
"tsconfig": major
"utils": major
"ui": major
"cms": major
"web": major
---

Update dependencies, fix pnpm workspace settings, linting and type errors"
22 changes: 4 additions & 18 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,13 @@ jobs:
uses: actions/checkout@v3

- name: Setup Node
uses: actions/setup-node@v3
uses: pnpm/action-setup@v3
with:
node-version: '18.17.0'

# Cache node_modules for faster CI runs if the yarn.lock doesn't change change
- name: Get yarn cache directory path
id: yarn-cache-dir
run: echo "::set-output name=dir::$(yarn cache dir)"

- name: Restore yarn cache
uses: actions/cache@v3
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
version: 8

# Throw an error if the yarn.lock file doesn't match the installed dependencies (rather than updating it in-place, which it does by default locally)
- name: Install
run: yarn install --frozen-lockfile --silent
run: pnpm install --no-frozen-lockfile

- name: Lint
run: yarn lint
run: pnpm lint
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
version: 8

- name: Install Dependencies
run: pnpm install
run: pnpm install --no-frozen-lockfile

- name: Create Release Pull Request
uses: changesets/action@v1
Expand Down
1 change: 1 addition & 0 deletions apps/cms/lib/client.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { createClient } from 'next-sanity'
import { PROJECT_ID } from './env'
export type { SanityClient } from '@sanity/client'

export const client = createClient({
projectId: PROJECT_ID,
Expand Down
2 changes: 1 addition & 1 deletion apps/cms/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"@sanity/eslint-config-studio": "^3.0.0",
"@types/react": "^18.2.45",
"@types/react-dom": "^18.2.18",
"eslint-config-custom": "*",
"eslint-config-custom": "1.0.1",
"tsconfig": "1.0.1",
"typescript": "^5.3.3"
}
Expand Down
6 changes: 3 additions & 3 deletions apps/cms/queries/fragments/link.fragment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ const _link = {
.select({
"parent != 'null'": {
slug: _slug.slug,
parent: q('parent').deref().select({
default: _slug,
}),
// parent: q('parent').deref().select({
// default: _slug,
// }),
},
default: _slug,
}),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,13 @@ export function PreviewProvider({
// const { client } = suspend(() => import('cms/lib/client'), [UniqueKey])
if (!token) throw new TypeError('Missing token')
return (
<LiveQueryProvider client={client} token={token} logger={console}>
<LiveQueryProvider
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore this is fine... honest
client={client}
token={token}
logger={console}
>
{children}
</LiveQueryProvider>
)
Expand Down
2 changes: 2 additions & 0 deletions apps/web/app/(sanity)/studio/[[...tool]]/Studio.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@ import config from 'cms/sanity.config'
import { NextStudio } from 'next-sanity/studio'

export default function Studio() {
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore this is fine... honest
return <NextStudio config={config} />
}
4 changes: 2 additions & 2 deletions apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
"lint": "tsc --pretty --noEmit --project tsconfig.json && TIMING=1 eslint \"./**/*.{js,ts,tsx}\" --fix --quiet"
},
"dependencies": {
"@capsizecss/metrics": "^1.2.0",
Expand Down Expand Up @@ -44,7 +44,7 @@
"@types/react": "^18.2.45",
"@types/react-dom": "^18.2.18",
"autoprefixer": "^10.4.15",
"eslint-config-custom": "*",
"eslint-config-custom": "1.0.1",
"postcss": "^8.4.32",
"tailwindcss": "^3.3.7",
"tsconfig": "1.0.1",
Expand Down
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,19 +32,19 @@
},
"dependencies": {
"@changesets/cli": "^2.27.1",
"@commitlint/cli": "^18.4.3",
"@commitlint/config-conventional": "^18.4.3",
"@manypkg/cli": "^0.21.1",
"@commitlint/cli": "^18.6.1",
"@commitlint/config-conventional": "^18.6.3",
"@manypkg/cli": "^0.21.3",
"@total-typescript/ts-reset": "^0.5.1",
"commitlint": "^18.4.3",
"commitlint": "^18.6.1",
"eslint": "8.56.0",
"eslint-config-custom": "*",
"eslint-config-custom": "1.0.1",
"husky": "^8.0.3",
"hygen": "^6.2.11",
"lint-staged": "^15.2.0",
"prettier": "^3.1.1",
"tsconfig": "*",
"turbo": "^1.11.2",
"lint-staged": "^15.2.2",
"prettier": "^3.2.5",
"tsconfig": "1.0.1",
"turbo": "^1.12.5",
"typescript": "^5.3.3"
},
"engines": {
Expand Down
2 changes: 0 additions & 2 deletions packages/ui/index.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions packages/ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"types": "./index.tsx",
"license": "MIT",
"scripts": {
"lint": "eslint .",
"lint": "tsc --pretty --noEmit --project tsconfig.json && TIMING=1 eslint \"./**/*.{js,ts,tsx}\" --fix --quiet",
"dev": "storybook dev -p 6006",
"build-storybook": "storybook build"
},
Expand All @@ -25,7 +25,7 @@
"@types/node": "^20.10.5",
"@types/react": "^18.2.45",
"@types/react-dom": "^18.2.18",
"eslint-config-custom": "*",
"eslint-config-custom": "1.0.1",
"eslint-plugin-storybook": "^0.6.15",
"react": "18.2.0",
"react-dom": "18.2.0",
Expand Down
7 changes: 2 additions & 5 deletions packages/ui/src/primitives/AlertDialog/AlertDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,8 @@ export const Root = RadixAlert.Root

export const Trigger = RadixAlert.Trigger

export function Portal({
className,
...props
}: RadixAlert.AlertDialogPortalProps) {
return <RadixAlert.Portal className={clsx(className)} {...props} />
export function Portal({ ...props }: RadixAlert.AlertDialogPortalProps) {
return <RadixAlert.Portal {...props} />
}

export const Overlay = React.forwardRef<
Expand Down
Loading
Loading