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

One #412

Draft
wants to merge 56 commits into
base: main
Choose a base branch
from
Draft

One #412

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
f9f7f87
fix: respect typescript null reference
RodrigoHamuy Oct 24, 2022
ff9f7a7
chore: migrate to pnpm + package updates
dbismut Nov 23, 2022
48aaf54
fix: properly handle the panel's height
dbismut Nov 23, 2022
73d2c6a
chore: upgrade zustand
dbismut Nov 23, 2022
98ca2c0
chore: remove cypress for now
dbismut Nov 23, 2022
d324808
demo: update deps for @react-three
dbismut Nov 23, 2022
55a5755
chore: upgrade mathjs
dbismut Nov 23, 2022
e0f45c9
chore: upgrade react-dropzone
dbismut Nov 23, 2022
c8cd3a0
fix: remove cypress
dbismut Nov 23, 2022
0f2851b
fix: remove useless react imports
dbismut Nov 23, 2022
1893f47
fix: add typescript parser (not sure it's necessary)
dbismut Nov 23, 2022
0325b67
chore: cleaning
dbismut Nov 23, 2022
2f89939
fix: wip update to zustand v4
dbismut Nov 24, 2022
a497ca1
chore: use fireImmediately: true in store subscriptions
dbismut Nov 24, 2022
85289cf
chore: rename option transient to reactive
dbismut Nov 24, 2022
1ed7dc8
demo: cleaning and add new react18 demo
dbismut Nov 25, 2022
36de9b2
chore: cleanup
dbismut Nov 26, 2022
dd042d4
chore: trying to use vanilla store
dbismut Nov 26, 2022
abb2978
chore: refactor StoreType into LevaStore using classes
dbismut Nov 27, 2022
28132ec
ci: upgrade github actions
dbismut Nov 27, 2022
33da4b2
stories: negate us of postcss to disable deprecation warning
dbismut Nov 27, 2022
03dbcd5
stories: remove temp fix for TS 4.3.2
dbismut Nov 27, 2022
7c4ade3
Merge remote-tracking branch 'github-desktop-RodrigoHamuy/fix/respect…
dbismut Nov 27, 2022
d7c060e
chore: upgrade deps
dbismut Nov 27, 2022
a55147f
chore: fix deps
dbismut Nov 27, 2022
389e0c2
chore: fix lock file
dbismut Nov 27, 2022
9f79dc3
chore: fix peerDeps
dbismut Nov 28, 2022
59983b4
types: fix type
dbismut Nov 28, 2022
b116bbb
chore: move wdyr dev deps to repo
dbismut Nov 28, 2022
d7d498c
fix: call resizing of the canvas right away
dbismut Nov 29, 2022
bd6eb04
lint: add import/no-relative-package rule
dbismut Nov 29, 2022
a819c37
fix: remove use-zustand
dbismut Nov 29, 2022
6644f27
chore: add import/no-extraneous-dependencies rule
dbismut Nov 29, 2022
14738f0
fix: set the ctx before resizing
dbismut Nov 29, 2022
d4135be
chore: deps updates
dbismut Nov 29, 2022
a56378c
fix: remove cypress
dbismut Nov 29, 2022
7adfc1f
stories: properly capitalize story names
dbismut Nov 29, 2022
7264efb
chore: clean package.json
dbismut Nov 29, 2022
8693037
fix: catch error when path doesn't exist in get
dbismut Nov 29, 2022
42267da
fix: package deps
dbismut Jan 2, 2023
21ecb46
lint: fix import order
dbismut Jan 2, 2023
01f95d9
feat: stringify select keys
dbismut Jan 10, 2023
66a5b30
fix: add pointerEvents auto as parent may have pointer events set to …
dbismut Jan 17, 2023
bf1c726
chore: remove useless React import
dbismut Jan 17, 2023
b872755
chore: it sucks but preconstruct doesn't build without flat deps
dbismut Jan 17, 2023
6ce2203
ci: test
dbismut Jan 17, 2023
fca4099
ci: CI: true
dbismut Jan 17, 2023
cc6c037
ci: upgrade version pnpm in github action
dbismut Jan 17, 2023
ce4da5e
ci: fix husky?
dbismut Jan 17, 2023
1d84b19
fix: remove husky for now
dbismut Jan 17, 2023
d4a83ae
ts: fix react generation?
dbismut Jan 17, 2023
9f6dc25
chore: fix babel
dbismut Jan 17, 2023
faeb005
fix: exports
dbismut Jan 17, 2023
e8f69a8
roll back use-gesture to 10.2.22
dbismut Jan 17, 2023
5bf23fa
ci: trigger
dbismut Jan 17, 2023
5e03da0
fix: fix regression
dbismut Jan 17, 2023
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
5 changes: 5 additions & 0 deletions .changeset/fuzzy-drinks-invite.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'leva': patch
---

fix: respect ts null reference
35 changes: 29 additions & 6 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,33 @@
{
"extends": "react-app",
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"extends": ["react-app"],
"rules": {
"no-console": "warn"
"import/no-duplicates": "error",
"import/order": [
"warn",
{
"newlines-between": "always",
"groups": ["builtin", "external", "internal", ["parent", "sibling"], "index", "object", "type"],
"pathGroups": [
{
"pattern": "@/**",
"group": "internal"
}
],
"pathGroupsExcludedImportTypes": ["type"]
}
],
"no-console": "warn",
"import/no-relative-packages": "error"
},
"plugins": ["cypress"],
"env": {
"cypress/globals": true
}
"overrides": [
{
"files": ["packages/**"],
"excludedFiles": "*.stories.*",
"rules": {
"import/no-extraneous-dependencies": ["error"]
}
}
]
}
92 changes: 44 additions & 48 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,65 +1,61 @@
name: CI

on:
push:
branches:
- main
paths:
- '.github/**'
- 'packages/**'
- 'package.json'
- 'yarn.lock'
- '!demo/**'
- '!docs/**'
- '!**.md'
- '!.changeset/**'
- '**/package.json'
- '.changeset/**'
- '.github/workflows/release.yml'

env:
CI: true
jobs:
build:
name: Build, lint, and test
version:
timeout-minutes: 8
runs-on: ubuntu-latest

steps:
- name: Checkout repo
- name: checkout code repository
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Use Node
uses: actions/setup-node@v2
with:
node-version: '14'
node-version: '16'

- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

- uses: actions/cache@v2
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
- name: Cache pnpm modules
uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
path: ~/.pnpm-store
key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-yarn-

- name: Install dependencies
run: yarn --silent

- name: Check types
run: yarn tsc
${{ runner.os }}-

- name: Check formatting
run: yarn prettier

- name: Lint files
run: yarn lint:full

- uses: actions/cache@v2
name: Setup Yarn build cache
id: yarn-build-cache
- uses: pnpm/[email protected]
with:
path: packages/**/dist
key: ${{ runner.os }}-yarn-build-${{ hashFiles('packages/') }}
restore-keys: |
${{ runner.os }}-yarn-build-

- name: Yarn build without cache
if: steps.yarn-build-cache.outputs.cache-hit != 'true'
run: yarn build

- name: Cypress run
run: yarn ci:test
version: 7.1.0
run_install: true

- name: Set up NPM credentials
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Create versions PR & prepare publish
id: changesets
uses: changesets/action@master
# if: github.ref == 'refs/heads/master'
with:
version: pnpm ci:version
publish: pnpm ci:publish
# Messages
commit: 'chore(deploy): Release'
title: 'chore(deploy): Release'
env:
# npm publish token required for publishing. Set this in secrets
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# automatically available in actions
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
55 changes: 31 additions & 24 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,46 +8,53 @@ on:
- '**/package.json'
- '.changeset/**'
- '.github/workflows/release.yml'

env:
HUSKY: 0 # Bypass husky commit hook for CI
jobs:
release:
name: Release
version:
timeout-minutes: 8
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
- name: checkout code repository
uses: actions/checkout@v2
with:
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
fetch-depth: 0

- name: Use Node
uses: actions/setup-node@v2
with:
node-version: '14'

- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
node-version: '16'

- uses: actions/cache@v2
id: yarn-cache
- name: Cache pnpm modules
uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
path: ~/.pnpm-store
key: ${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-yarn-
${{ runner.os }}-

- uses: pnpm/[email protected]
with:
version: 6.9.1
run_install: true

- name: Install dependencies
run: yarn install --silent
- name: Set up NPM credentials
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Create Release Pull Request or Publish to npm
- name: Create versions PR & prepare publish
id: changesets
uses: changesets/action@v1
uses: changesets/action@master
# if: github.ref == 'refs/heads/master'
with:
version: yarn ci:version
publish: yarn ci:release
commit: 'chore(release): update monorepo packages versions'
title: 'Upcoming Release Changes'
version: pnpm ci:version
publish: pnpm ci:publish
# Messages
commit: 'chore(deploy): Release'
title: 'chore(deploy): Release'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# npm publish token required for publishing. Set this in secrets
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# automatically available in actions
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6 changes: 3 additions & 3 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm run lint
npm run lint && npm run tsc
2 changes: 2 additions & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
auto-install-peers = true
node-linker = hoisted
4 changes: 2 additions & 2 deletions .storybook/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module.exports = {
// Return the altered config
return config
},
typescript: {
reactDocgen: 'none', // temp fix for TS 4.3.2
features: {
postcss: false
},
}
546 changes: 0 additions & 546 deletions .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

This file was deleted.

550 changes: 0 additions & 550 deletions .yarn/plugins/@yarnpkg/plugin-version.cjs

This file was deleted.

28 changes: 0 additions & 28 deletions .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs

This file was deleted.

768 changes: 0 additions & 768 deletions .yarn/releases/yarn-sources.cjs

This file was deleted.

7 changes: 6 additions & 1 deletion babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,12 @@ module.exports = {
},
},
],
'@babel/preset-react',
[
'@babel/preset-react',
{
runtime: 'automatic',
},
],
'@babel/preset-typescript',
],
}
5 changes: 0 additions & 5 deletions cypress.json

This file was deleted.

5 changes: 0 additions & 5 deletions cypress/fixtures/example.json

This file was deleted.

69 changes: 0 additions & 69 deletions cypress/integration/spec.js

This file was deleted.

21 changes: 0 additions & 21 deletions cypress/plugins/index.js

This file was deleted.

1 change: 0 additions & 1 deletion cypress/support/commands.js

This file was deleted.

20 changes: 0 additions & 20 deletions cypress/support/index.js

This file was deleted.

Loading