Skip to content

Commit

Permalink
Move packages-next to packages (#6087)
Browse files Browse the repository at this point in the history
* Move packages-next to packages

* Add changeset
  • Loading branch information
JedWatson committed Jul 13, 2021
1 parent 1ed2dea commit 139d7a8
Show file tree
Hide file tree
Showing 413 changed files with 61 additions and 49 deletions.
19 changes: 19 additions & 0 deletions .changeset/early-dingos-retire.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
"@keystone-next/website": patch
"@keystone-next/example-auth": patch
"@keystone-next/example-custom-field": patch
"@keystone-next/admin-ui-utils": patch
"@keystone-next/auth": patch
"@keystone-next/cloudinary": patch
"@keystone-next/document-renderer": patch
"@keystone-next/fields": patch
"@keystone-next/fields-document": patch
"@keystone-next/keystone": patch
"@keystone-next/session-store-redis": patch
"@keystone-next/testing": patch
"@keystone-next/types": patch
"@keystone-next/utils": patch
"@keystone-next/api-tests-legacy": patch
---

Move source code from the `packages-next` to the `packages` directory.
2 changes: 1 addition & 1 deletion .codesandbox/ci.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"packages": ["packages/*", "packages-next/*"],
"packages": ["packages/*"],
"sandboxes": ["/examples/sandbox"],
"node": "14"
}
4 changes: 2 additions & 2 deletions STYLE_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ For links to work across these mediums, certain rules for URLs formulation must
- The full filename, include the extension
- Eg. `/docs/pages/guides/cli.mdx` (**not** `/docs/guides/cli`)
- Links to `README.md` files must be explicit; they cannot rely on the GitHub behaviour that uses `README.md` at a sort of "index" for a directory
- Eg. `/packages-next/keystone/README.md#CLI` (**not** `/packages-next/keystone#CLI`)
- Links to directories end in a slash (eg. `/packages-next/keystone/`)
- Eg. `/packages/keystone/README.md#CLI` (**not** `/packages/keystone#CLI`)
- Links to directories end in a slash (eg. `/packages/keystone/`)
- This as is convention for URLs (so as not to be confused with a files)

## Code and Code Blocks
Expand Down
4 changes: 2 additions & 2 deletions docs/pages/docs/guides/custom-fields.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ There are two parts to a field type:
- The **frontend** portion which defines how the field looks and behaves in the Admin UI.

The general approach to creating a custom field type is to take an existing field type and make the appropriate changes for your use case.
In this guide we're going to create a field type `myInt` which recreates the [`integer`](https://github.com/keystonejs/keystone/tree/master/packages-next/fields/src/types/integer) field type.
In this guide we're going to create a field type `myInt` which recreates the [`integer`](https://github.com/keystonejs/keystone/tree/master/packages/fields/src/types/integer) field type.

!> For inspiration, see [the source for the fields that Keystone provides](https://github.com/keystonejs/keystone/tree/master/packages-next/fields/src/types) and the [Custom Fields](https://github.com/keystonejs/keystone/tree/master/examples/custom-field) example project.
!> For inspiration, see [the source for the fields that Keystone provides](https://github.com/keystonejs/keystone/tree/master/packages/fields/src/types) and the [Custom Fields](https://github.com/keystonejs/keystone/tree/master/examples/custom-field) example project.

## Backend

Expand Down
2 changes: 1 addition & 1 deletion docs/pages/releases/2021-06-15.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ After months of work deep in the codebase, it’ll be much easier for us to ship

The core of Keystone has been re-implemented to make building fields and new features in Keystone easier. While the observable changes for most users should be minimal, there could be breakage <Emoji symbol="🤖" alt="Robot" />.

⚠️ If you implemented a custom field type, you will need to change it to the new API, see fields in the `@keystone-next/fields` [package](https://github.com/keystonejs/keystone/tree/master/packages-next/fields) for inspiration on how to do this.
⚠️ If you implemented a custom field type, you will need to change it to the new API, see fields in the `@keystone-next/fields` [package](https://github.com/keystonejs/keystone/tree/master/packages/fields) for inspiration on how to do this.

### Password tweaks <Emoji symbol="🔒" alt="Padlock" />

Expand Down
2 changes: 1 addition & 1 deletion examples-staging/auth/keystone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { lists } from './schema';

/**
* TODO: Implement validateItem. Would be invoked by the getItem() method in
* packages-next/auth/src/getExtendGraphQLSchema.ts
* packages/auth/src/getExtendGraphQLSchema.ts
*/

let sessionSecret = '-- DEV COOKIE SECRET; CHANGE ME --';
Expand Down
2 changes: 1 addition & 1 deletion examples/custom-field/stars-field/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import {
// this field is based on the integer field
// but with validation to ensure the value is within an expected range
// and a different input in the Admin UI
// https://github.com/keystonejs/keystone/tree/master/packages-next/fields/src/types/integer
// https://github.com/keystonejs/keystone/tree/master/packages/fields/src/types/integer

export type StarsFieldConfig<TGeneratedListTypes extends BaseGeneratedListTypes> =
CommonFieldConfig<TGeneratedListTypes> & {
Expand Down
27 changes: 10 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -105,32 +105,25 @@
},
"workspaces": {
"packages": [
"design-system/packages/*",
"design-system/website",
"docs",
"examples-staging/*",
"examples/*",
"packages/*",
"tests/test-projects/*",
"tests/admin-ui-tests",
"tests/api-tests",
"tests/benchmarks",
"tests/examples-smoke-tests",
"projects/*",
"examples/*",
"examples-staging/*",
"packages-next/*",
"design-system/packages/*",
"design-system/website",
"docs"
"tests/test-projects/*"
],
"nohoist": [
"**/cypress-multi-reporters"
]
},
"preconstruct": {
"packages": [
"packages/access-control",
"packages/session",
"packages/test-utils",
"packages/utils",
"packages/adapter-prisma",
"packages-next/*",
"packages/*",
"design-system/packages/*"
],
"distFilenameStrategy": "unscoped-package-name"
Expand All @@ -149,10 +142,10 @@
"\\.pnp\\.[^\\/]+$"
],
"collectCoverageFrom": [
"packages{,-next}/**/*.{js,ts,tsx}",
"packages/**/*.{js,ts,tsx}",
"!**/*.d.ts",
"!packages{,-next}/**/dist/**",
"!packages{,-next}/fields/**/test-fixtures.{js,ts}",
"!packages/**/dist/**",
"!packages/fields/**/test-fixtures.{js,ts}",
"!packages/fields/types.js"
]
},
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,5 @@
"engines": {
"node": "^12.20 || >= 14.13"
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/admin-ui-utils"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/admin-ui-utils"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,5 @@
"pages/*.tsx"
]
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/auth"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/auth"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@
"views/index.tsx"
]
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/cloudinary"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/cloudinary"
}
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ cloudinary.v2.config({
});

const prepareFile = (_filePath: string) => {
const filePath = path.resolve(`packages-next/cloudinary/src/test-files/${_filePath}`);
const filePath = path.resolve(`packages/cloudinary/src/test-files/${_filePath}`);
const upload = new Upload();
upload.resolve({
createReadStream: () => fs.createReadStream(filePath),
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@
"engines": {
"node": "^12.20 || >= 14.13"
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/document-renderer"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/document-renderer"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"slate-history": "^0.60.4",
"slate-react": "^0.60.4"
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/fields-document",
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/fields-document",
"devDependencies": {
"@testing-library/react": "^12.0.0",
"array.prototype.flat": "^1.2.4",
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -51,5 +51,5 @@
"types/relationship/views/RelationshipSelect.tsx"
]
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/fields"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/fields"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { text } from '../../text';
import { file } from '..';

const prepareFile = (_filePath: string) => {
const filePath = path.resolve(`packages-next/fields/src/types/file/test-files/${_filePath}`);
const filePath = path.resolve(`packages/fields/src/types/file/test-files/${_filePath}`);
const upload = new Upload();
upload.resolve({
createReadStream: () => fs.createReadStream(filePath),
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { text } from '../../text';
import { image } from '..';

const prepareFile = (_filePath: string) => {
const filePath = path.resolve(`packages-next/fields/src/types/image/test-files/${_filePath}`);
const filePath = path.resolve(`packages/fields/src/types/image/test-files/${_filePath}`);
const upload = new Upload();
upload.resolve({
createReadStream: () => fs.createReadStream(filePath),
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -138,5 +138,5 @@
"admin-ui/image.tsx"
]
},
"repository": "https://github.com/keystonejs/keystone/tree/master/packages-next/keystone"
"repository": "https://github.com/keystonejs/keystone/tree/master/packages/keystone"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

1 comment on commit 139d7a8

@vercel
Copy link

@vercel vercel bot commented on 139d7a8 Jul 13, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.