Skip to content

Commit

Permalink
Merge branch 'main' into bugfix/706-extraneous-design-key
Browse files Browse the repository at this point in the history
  • Loading branch information
lucas-varela committed Apr 11, 2022
2 parents db76b65 + 316abe5 commit 909d8b1
Show file tree
Hide file tree
Showing 157 changed files with 3,076 additions and 1,144 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/ensure-semantic-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Ensure Semantic Pull Request
on:
pull_request_target:
types:
- opened
- edited
- synchronize
jobs:
main:
name: Validate PR to be semantic
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v4
with:
validateSingleCommit: true
validateSingleCommitMatchesPrTitle: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions package-lock.json

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

1 change: 1 addition & 0 deletions packages/__cxstarter__/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"react": "^17.0.2"
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"@bodiless/components": "^1.0.0-beta.2",
"@bodiless/components-ui": "^1.0.0-beta.2",
"@bodiless/core": "^1.0.0-beta.2",
Expand Down
28 changes: 28 additions & 0 deletions packages/__cxstarter__/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageTailwindConfig } from '@bodiless/fclasses';

const resolver = (pkgName) => require.resolve(pkgName);

const twConfig = {
purge: [
'./lib/**/!(*.d).{ts,js,jsx,tsx}',
],
};

export default getPackageTailwindConfig({
twConfig,
resolver,
});
20 changes: 20 additions & 0 deletions packages/bodiless-accessibility/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from '@bodiless/cli';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
1 change: 1 addition & 0 deletions packages/bodiless-accessibility/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
"audit": "node ./index.js $*"
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"arg": "^4.1.1",
"chalk": "^2.4.2",
"esm": "^3.2.25",
Expand Down
1 change: 1 addition & 0 deletions packages/bodiless-accordion/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
"clean": "rimraf \"lib/*\" && rimraf tsconfig.tsbuildinfo && rimraf \"doc/api\""
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"@bodiless/components": "^1.0.0-beta.2",
"@bodiless/core": "^1.0.0-beta.2",
"@bodiless/fclasses": "^1.0.0-beta.2",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
Expand All @@ -11,13 +12,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageTailwindConfig } from '@bodiless/fclasses';

/**
* contains package level tailwind configuration
* the package does not perform tailwind compilation
* site is responsible for merging these settings into site level settings
*/
module.exports = {
const resolver = (pkgName) => require.resolve(pkgName);

const twConfig = {
purge: [
'./lib/**/!(*.d).{ts,js,jsx,tsx}',
],
Expand All @@ -41,6 +40,11 @@ module.exports = {
},
plugins: [
// eslint-disable-next-line
require('tailwindcss-aspect-ratio'),
require('tailwindcss-aspect-ratio'),
],
};

export default getPackageTailwindConfig({
twConfig,
resolver,
});
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#
# To enable this hook, rename this file to "prepare-commit-msg".

# This hook includes three examples. The first one removes the
# This hook includes three sites. The first one removes the
# "# Please enter the commit message..." help message.
#
# The second includes the output of "git diff --name-status -r"
Expand Down
3 changes: 3 additions & 0 deletions packages/bodiless-backend/bin/bodiless-backend
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env node

require('../src/server.js');
20 changes: 20 additions & 0 deletions packages/bodiless-backend/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from '@bodiless/cli';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
4 changes: 4 additions & 0 deletions packages/bodiless-backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@
"/bodiless.docs.json",
"/src"
],
"bin": {
"bodiless-backend": "./bin/bodiless-backend"
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"body-parser": "^1.18.3",
"copyfiles": "^2.1.1",
"dotenv": "^8.2.0",
Expand Down
20 changes: 20 additions & 0 deletions packages/bodiless-bv/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from '@bodiless/cli';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
1 change: 1 addition & 0 deletions packages/bodiless-bv/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"clean": "rimraf \"lib/*\" && rimraf tsconfig.tsbuildinfo && rimraf \"doc/api\""
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"@bodiless/components": "^1.0.0-beta.2",
"@bodiless/core": "^1.0.0-beta.2",
"@bodiless/fclasses": "^1.0.0-beta.2",
Expand Down
20 changes: 20 additions & 0 deletions packages/bodiless-card/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from '@bodiless/cli';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
1 change: 1 addition & 0 deletions packages/bodiless-card/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"copy": "copyfiles -u 1 \"./src/**/*.{css,png}\" \"./lib/\""
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"@bodiless/core": "^1.0.0-beta.2",
"@bodiless/fclasses": "^1.0.0-beta.2",
"lodash": "^4.17.19",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
Expand All @@ -11,13 +12,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageTailwindConfig } from '@bodiless/fclasses';

/**
* contains package level tailwind configuration
* the package does not perform tailwind compilation
* site is responsible for merging these settings into site level settings
*/
module.exports = {
const resolver = (pkgName) => require.resolve(pkgName);

const twConfig = {
purge: [
'./lib/**/!(*.d).{ts,js,jsx,tsx}',
],
Expand All @@ -44,3 +43,8 @@ module.exports = {
require('tailwindcss-aspect-ratio'),
],
};

export default getPackageTailwindConfig({
twConfig,
resolver,
});
20 changes: 20 additions & 0 deletions packages/bodiless-carousel/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from '@bodiless/cli';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
1 change: 1 addition & 0 deletions packages/bodiless-carousel/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"clean": "rimraf \"lib/*\" && rimraf tsconfig.tsbuildinfo && rimraf \"doc/api\""
},
"dependencies": {
"@bodiless/cli": "^1.0.0-beta.2",
"@bodiless/components": "^1.0.0-beta.2",
"@bodiless/core": "^1.0.0-beta.2",
"@bodiless/fclasses": "^1.0.0-beta.2",
Expand Down
4 changes: 3 additions & 1 deletion packages/bodiless-cli/bodiless.docs.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"Tools": {
"BodilessCLI.md": "./README.md"
"CLI": {
"BodilessCLI.md": "./README.md"
}
}
}
20 changes: 20 additions & 0 deletions packages/bodiless-cli/getDocs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/* eslint-disable import/no-dynamic-require, global-require */
/**
* Copyright © 2021 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import { getPackageDocs } from './lib/helpers/getPackageDocs';

export const getDocs = (nameSpace) => getPackageDocs({
resolver: p => require.resolve(p),
nameSpace
});
6 changes: 5 additions & 1 deletion packages/bodiless-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,13 @@
"@types/fs-extra": "^8.0.0",
"@types/lodash": "^4.14.158",
"@types/lodash.flow": "^3.5.6",
"dotenv": "^8.2.0",
"find-up": "^4.1.0",
"fs-extra": "^8.1.0",
"globby": "^10",
"lodash": "^4.17.19"
"isomorphic-git": "^1.10.1",
"lodash": "^4.17.19",
"walkdir": "^0.4.1"
},
"devDependencies": {
"@oclif/dev-cli": "^1",
Expand Down
37 changes: 37 additions & 0 deletions packages/bodiless-cli/src/commands/generate-env-vars.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
/**
* Copyright © 2020 Johnson & Johnson
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

import {
Command,
} from '@oclif/command';
import init from '../helpers/generate-env-vars';

/**
* Defines the 'generate-env-vars' command.
*/
export default class GenerateEnvVars extends Command {
static description = 'Generate .env files for current site';

static examples = [
'$ bodiless generate-env-vars'
];

async run() {
try {
init();
} catch (e) {
this.error(e as Error);
}
}
}

0 comments on commit 909d8b1

Please sign in to comment.