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

RNMobile release v1.22.0 #20062

Merged
merged 120 commits into from
Feb 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
120 commits
Select commit Hold shift + click to select a range
d4b7692
Use Select: Fix render queue. (#19286)
epiqueras Jan 20, 2020
e654dce
Project Management: Run pull request automation on closed (#19742)
aduth Jan 20, 2020
5ba3976
Try/group block custom text color (#19181)
glendaviesnz Jan 20, 2020
80824d7
Block Editor: Handle LinkControl submission via form handler (#19651)
aduth Jan 20, 2020
1ffedef
Added conditions and new translation strings for BlockMover (#19757)
momotofu Jan 21, 2020
9788231
Storybook: Add Placeholder component story (#19734)
mkaz Jan 21, 2020
942c262
Project Management: Fix pull request merge automation errors (#19768)
aduth Jan 21, 2020
056dd36
Add post requests documentation for apiFetch (#19759)
momotofu Jan 21, 2020
f6c90ed
Multi-select: don't focus first selected block (#19762)
ellatrix Jan 21, 2020
d6487f3
Update: Readme.txt Link to changelog instead of adding it inline(#19761)
jorgefilipecosta Jan 21, 2020
aad7459
Fix: Media & Text: "Crop image to fill entire column" reset on image …
jorgefilipecosta Jan 21, 2020
cd309db
Build: Include JSON files in zip archive (#19772)
ockham Jan 21, 2020
24c0e60
Makes appenders visible only for the current selection (#19598)
draganescu Jan 21, 2020
26062c8
Core-data: do not publish outdated state to subscribers during update…
alshakero Jan 21, 2020
7d59200
Add WordPress primitives package (#19781)
youknowriad Jan 21, 2020
c22b77c
navigation-link: set page id in the attrs (#18641)
retrofox Jan 21, 2020
b39e9d9
Project management: Add step that updates CHANGELOG files before npm …
gziolo Jan 21, 2020
b77d71a
Navigation Block: Add submenu chevron w/ setting (#19601)
WunderBart Jan 21, 2020
567cdb9
Embed: Fix failure placeholder alignment/sizing (#19673)
Jan 21, 2020
76304dd
Fix card component sub-component example code (#19802)
ediamin Jan 22, 2020
46fcca7
Introduce the Icons package (#17055)
senadir Jan 22, 2020
1f3ea11
Expose @wordpress/icons to react-native (#19810)
koke Jan 22, 2020
59ed771
Block popover: allow scrolling over (#19769)
ellatrix Jan 22, 2020
938fb55
Multi select: keep selection after move (#19784)
ellatrix Jan 22, 2020
2db504d
Bump plugin version to 7.3.0
ellatrix Jan 22, 2020
c079120
Navigation: Select parent navigation block on handleCreateFromExistin…
jeryj Jan 22, 2020
5a8eda1
Paragraph block: remove dead CSS (#19821)
ellatrix Jan 23, 2020
8acb023
Bundle the icons package instead of using it as an external (#19809)
youknowriad Jan 23, 2020
8f92cfe
Move a dozen of block icons to the icons package (#19808)
youknowriad Jan 23, 2020
6a1ea3c
Chore: Improve package-lock.json configuration
gziolo Jan 23, 2020
373d79a
Add mkevins and pinarol as code owners for gallery block (#19829)
mkevins Jan 23, 2020
0de9e37
Added shippedProposals (#19065)
abdel-h Jan 23, 2020
4ae2c15
Rich text: remove is-selected class (#19822)
ellatrix Jan 23, 2020
26b8015
Move more block SVGs to the icons package (#19834)
youknowriad Jan 23, 2020
89c2b44
Block: use context to provide selected element (#19782)
ellatrix Jan 23, 2020
dcb08f3
Popover: clean up requestAnimationFrame (#19771)
ellatrix Jan 23, 2020
e18e0a0
Update: Removed editor store usage from native mobile block ed… (#18794)
jorgefilipecosta Jan 23, 2020
7704da0
Navigation: Manage navigation link appender visibility based on curre…
jeryj Jan 23, 2020
681a297
Remove editor dependency from the block library (#16160)
jorgefilipecosta Jan 23, 2020
6d035d3
Add AnglePicker Component; Add useDragging hook (#19637)
jorgefilipecosta Jan 23, 2020
f5cdfca
Testing: Use deterministic selectors for incremented IDs (#19844)
aduth Jan 23, 2020
5275570
Innerblock Templates Docs Link Typo Issue Fixed (#19813)
delowardev Jan 23, 2020
17ef62d
Rich text: enable if multi selection is aborted (#19839)
ellatrix Jan 24, 2020
4cd1492
Block Directory: Refactor the reducer by breaking out the block manag…
StevenDufresne Jan 24, 2020
167d4d1
Fix panel header styles (#19842)
adekbadek Jan 24, 2020
b9b1818
Move more block icons to the icons package (#19838)
youknowriad Jan 24, 2020
d2576aa
Bump @babel/preset-env to 7.8.3 (Optional Chaining!) (#19831)
sainthkh Jan 24, 2020
21936b5
Style improvements for template previews (#19763)
koke Jan 24, 2020
605ee4d
[RNMobile] Release v1.21.0 to master (#19854)
etoledom Jan 24, 2020
bc57547
Packages: New create-block package for block scaffolding (#19773)
gziolo Jan 24, 2020
0470286
Pass the prop for selection color. (#19635)
SergioEstevao Jan 24, 2020
282687b
Do not use the deprecated package editor for InnerBlocks component (#…
Mahjouba91 Jan 24, 2020
f6eb4ec
Remove dead is-hovered selectors (#19870)
ellatrix Jan 24, 2020
23493b7
Move is-navigate-mode class to WritingFlow (#19868)
ellatrix Jan 24, 2020
361d2df
[RNmobile] Upgrade to RN 0.61.5 (#19369)
hypest Jan 24, 2020
b3b92f3
Update README.md (#19876)
mkaz Jan 25, 2020
9a364c9
Multi selection: fix intermittent e2e failure (#19865)
ellatrix Jan 25, 2020
b42cde3
Move more block icons to the icons library (#19862)
youknowriad Jan 27, 2020
1fb3c38
Paragraph block: remove min-height (#19835)
ellatrix Jan 27, 2020
e0958d7
Framework: Fix server-registered fixtures script (#19884)
aduth Jan 27, 2020
85ffc72
Shortcode Design Review (#19852)
chipsnyder Jan 27, 2020
288f8df
Update component to components in CONTRIBUTING.md (#19914)
diegohaz Jan 27, 2020
a45df0e
Apply sentence case formatting to PanelBody titles (#19901)
richtabor Jan 27, 2020
64767db
Clarify when isEligible function is called (#19899)
bfintal Jan 27, 2020
c1266a7
Block Editor: Refactor ObserveTyping as function component (#19881)
aduth Jan 27, 2020
9e3c713
Remove unnecessary import from playground (#19893)
costasovo Jan 27, 2020
ba2495f
Documentation: Organize Contributors Guide (#19853)
mkaz Jan 27, 2020
08182bf
[RNMobile] Correct isMobile condition in nested Media&Text (#19778)
lukewalczak Jan 28, 2020
bc38a3d
Blocks: Match blocks in the inserter using keywords from patterns (#1…
gziolo Jan 28, 2020
c49b051
Block editor: Alt+F10 shouldn't scroll to top (#19896)
ellatrix Jan 28, 2020
f6470e6
Multi-selection: fix clearing with side click (#19787)
ellatrix Jan 28, 2020
17f6eae
[RNMobile] fix show appender and separator in Group block (#19908)
jbinda Jan 28, 2020
a911562
Add docs for LocalAutosaveMonitor and __experimentalUpdateLocalAutosa…
mcsf Jan 28, 2020
a38b633
[RNMobile] Add media edit icon to image block (#19723)
leandroalonso Jan 28, 2020
6f97e52
Block Library: Handle Popover onClose for LinkControl (#19885)
aduth Jan 28, 2020
6aa04e8
Disable Autocomplete in shortcode block (#19848)
chipsnyder Jan 28, 2020
1d6895d
RichText API: Limit `prefix` transformations to Paragraph (#19727)
mcsf Jan 28, 2020
4c1ef94
Block Editor: LinkControl: Resolve error when undefined value, "view"…
aduth Jan 28, 2020
a394c9f
[RNMobile] Revert change to fix Action Sheet (#19934)
leandroalonso Jan 28, 2020
e64c554
Add background color support to Columns block (#17813)
richtabor Jan 28, 2020
8c3bd8e
Fix RTL styling for Media Text block (#18764)
richtabor Jan 28, 2020
6987e37
change order of composing style in svg primitive (#19927)
jbinda Jan 29, 2020
c2eece7
Add Prettier formatting script (#18048)
jsnajdr Jan 29, 2020
167bd70
Components: FontSizePicker: Adjust Select Button sizing (#19479)
Jan 29, 2020
b4efa12
Documentation: fix typo "Th" to "The" (#19833)
nekomajin Jan 29, 2020
5cb2727
[RNMobile] Long-press on inserter to show options for "add above" and…
ceyhun Jan 29, 2020
6c8d945
Docs: Add details for format-js to @wordpress/scripts package (#19946)
gziolo Jan 29, 2020
0bda7c4
Fix: Crash when creating a hierarchical post without title (#19936)
jorgefilipecosta Jan 29, 2020
7c32ac9
Fix: Color Gradients component was not able to handle only gra… (#19925)
jorgefilipecosta Jan 29, 2020
ea705dd
Add markdownlint script to lint docs markup (#19855)
mkaz Jan 30, 2020
d17bd4b
Use require.resolve() instead of <rootDir> in @wordpress/jest-preset-…
jameslnewell Jan 30, 2020
5832c30
added changelog entry (#19958)
jameslnewell Jan 30, 2020
06f02c9
Move the insert dashicon to the icons package (#19943)
youknowriad Jan 30, 2020
8497112
Replace all occurences of the yes dashicon with the check icon from t…
youknowriad Jan 30, 2020
e46d52d
Build: Include block.json files in the build output (#19786)
gziolo Jan 30, 2020
d66d53b
Block Editor: LinkControl: Prevent focus loss in edit mode toggle (#1…
aduth Jan 30, 2020
cfa9a97
Move Alignment, movers and trash icons to the icons package (#19944)
youknowriad Jan 30, 2020
c804524
Navigation Block: Move the link description panel below the SEO panel…
apeatling Jan 31, 2020
56d866f
Update hover and focus selectors for Move to Trash to ensure they're …
andrewserong Jan 31, 2020
be05701
Create block: Code quality improvements for the block scaffolding (#1…
gziolo Jan 31, 2020
1b5461c
Code quality: Enable linting for JS files starting with .
gziolo Jan 31, 2020
0194925
Popover: fix typo in removing event listener (#19978)
ellatrix Jan 31, 2020
f63053c
Eslint Plugin: Lint code formatting. (#19963)
epiqueras Jan 31, 2020
63d56f1
[RNMobile] Show the media edit icon only if the block is selected (#1…
leandroalonso Jan 31, 2020
5945e48
Fix: Admin menu collapses for 960px width but editor doesn't (#19970)
jorgefilipecosta Jan 31, 2020
767caac
Chore: Fix differences in package-lock.json file
gziolo Jan 31, 2020
539b1fc
RichText: try using hooks for wrapper component (#19095)
ellatrix Jan 31, 2020
6aa9944
Components: Apply width-based modifier classes to Placeholder only wh…
aduth Jan 31, 2020
4857ad5
Eslint: set line width to 80 (#19992)
ellatrix Jan 31, 2020
fb964cb
Editor: Remove post title escaping (#19955)
aduth Jan 31, 2020
362ab68
Add: Global styles css variables generation mechanism (#19883)
jorgefilipecosta Jan 31, 2020
06bd266
Navigation: Change UX to move focus to navigation link label and clos…
jeryj Jan 31, 2020
d362cb1
Lib: Limit `pre_render_block` extension. (#19989)
epiqueras Feb 1, 2020
80c5239
Fix, update, and sort _rc_ `hasProjectFile` filenames (#19994)
ntwb Feb 2, 2020
b6d8712
Docs: Include CHANGELOG entries from the relocated create-wordpress-b…
gziolo Feb 2, 2020
feed14a
Blocks: Rename patterns to variations in the Block API (#19966)
gziolo Feb 2, 2020
8ef615e
[Mobile] Fix gallery upload sync (#19941)
mkevins Feb 3, 2020
c57bbdb
Merge branch 'rnmobile/releases-2020' into rnmobile/release-v1.22.0-u…
hypest Feb 6, 2020
49e109c
[Mobile] Fix blank image size labels on mobile (#19800) (#20045)
mkevins Feb 6, 2020
fac5718
[RNMobile] Enable Dismiss on PlainText in Android (#20095)
chipsnyder Feb 7, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 1 addition & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,4 @@ packages/e2e-tests/plugins
playground/dist
vendor
wordpress

!.eslintrc.js
!.*.js
125 changes: 73 additions & 52 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ const { version } = require( './package' );
*
* @type {string}
*/
const majorMinorRegExp = escapeRegExp( version.replace( /\.\d+$/, '' ) ) + '(\\.\\d+)?';
const majorMinorRegExp =
escapeRegExp( version.replace( /\.\d+$/, '' ) ) + '(\\.\\d+)?';

/**
* The list of patterns matching files used only for development purposes.
Expand All @@ -33,9 +34,7 @@ module.exports = {
'plugin:@wordpress/eslint-plugin/recommended',
'plugin:eslint-comments/recommended',
],
plugins: [
'import',
],
plugins: [ 'import' ],
globals: {
wp: 'off',
},
Expand All @@ -49,63 +48,88 @@ module.exports = {
// we'll get a `SyntaxError` (Invalid regular expression: \ at end of pattern)
// here. That's why we use \\u002F in the regexes below.
{
selector: 'ImportDeclaration[source.value=/^@wordpress\\u002F.+\\u002F/]',
message: 'Path access on WordPress dependencies is not allowed.',
selector:
'ImportDeclaration[source.value=/^@wordpress\\u002F.+\\u002F/]',
message:
'Path access on WordPress dependencies is not allowed.',
},
{
selector: 'ImportDeclaration[source.value=/^react-spring(?!\\u002Fweb\.cjs)/]',
message: 'The react-spring dependency must specify CommonJS bundle: react-spring/web.cjs',
selector:
'ImportDeclaration[source.value=/^react-spring(?!\\u002Fweb.cjs)/]',
message:
'The react-spring dependency must specify CommonJS bundle: react-spring/web.cjs',
},
{
selector: 'CallExpression[callee.name="deprecated"] Property[key.name="version"][value.value=/' + majorMinorRegExp + '/]',
message: 'Deprecated functions must be removed before releasing this version.',
selector:
'CallExpression[callee.name="deprecated"] Property[key.name="version"][value.value=/' +
majorMinorRegExp +
'/]',
message:
'Deprecated functions must be removed before releasing this version.',
},
{
selector: 'CallExpression[callee.name=/^(__|_n|_nx|_x)$/]:not([arguments.0.type=/^Literal|BinaryExpression$/])',
message: 'Translate function arguments must be string literals.',
selector:
'CallExpression[callee.name=/^(__|_n|_nx|_x)$/]:not([arguments.0.type=/^Literal|BinaryExpression$/])',
message:
'Translate function arguments must be string literals.',
},
{
selector: 'CallExpression[callee.name=/^(_n|_nx|_x)$/]:not([arguments.1.type=/^Literal|BinaryExpression$/])',
message: 'Translate function arguments must be string literals.',
selector:
'CallExpression[callee.name=/^(_n|_nx|_x)$/]:not([arguments.1.type=/^Literal|BinaryExpression$/])',
message:
'Translate function arguments must be string literals.',
},
{
selector: 'CallExpression[callee.name=_nx]:not([arguments.3.type=/^Literal|BinaryExpression$/])',
message: 'Translate function arguments must be string literals.',
selector:
'CallExpression[callee.name=_nx]:not([arguments.3.type=/^Literal|BinaryExpression$/])',
message:
'Translate function arguments must be string literals.',
},
{
selector: 'CallExpression[callee.name=/^(__|_x|_n|_nx)$/] Literal[value=/\\.{3}/]',
selector:
'CallExpression[callee.name=/^(__|_x|_n|_nx)$/] Literal[value=/\\.{3}/]',
message: 'Use ellipsis character (…) in place of three dots',
},
{
selector: 'ImportDeclaration[source.value="redux"] Identifier.imported[name="combineReducers"]',
selector:
'ImportDeclaration[source.value="redux"] Identifier.imported[name="combineReducers"]',
message: 'Use `combineReducers` from `@wordpress/data`',
},
{
selector: 'ImportDeclaration[source.value="lodash"] Identifier.imported[name="memoize"]',
selector:
'ImportDeclaration[source.value="lodash"] Identifier.imported[name="memoize"]',
message: 'Use memize instead of Lodash’s memoize',
},
{
selector: 'CallExpression[callee.object.name="page"][callee.property.name="waitFor"]',
selector:
'CallExpression[callee.object.name="page"][callee.property.name="waitFor"]',
message: 'Prefer page.waitForSelector instead.',
},
{
selector: 'JSXAttribute[name.name="id"][value.type="Literal"]',
message: 'Do not use string literals for IDs; use withInstanceId instead.',
message:
'Do not use string literals for IDs; use withInstanceId instead.',
},
{
// Discourage the usage of `Math.random()` as it's a code smell
// for UUID generation, for which we already have a higher-order
// component: `withInstanceId`.
selector: 'CallExpression[callee.object.name="Math"][callee.property.name="random"]',
message: 'Do not use Math.random() to generate unique IDs; use withInstanceId instead. (If you’re not generating unique IDs: ignore this message.)',
selector:
'CallExpression[callee.object.name="Math"][callee.property.name="random"]',
message:
'Do not use Math.random() to generate unique IDs; use withInstanceId instead. (If you’re not generating unique IDs: ignore this message.)',
},
{
selector: 'CallExpression[callee.name="withDispatch"] > :function > BlockStatement > :not(VariableDeclaration,ReturnStatement)',
message: 'withDispatch must return an object with consistent keys. Avoid performing logic in `mapDispatchToProps`.',
selector:
'CallExpression[callee.name="withDispatch"] > :function > BlockStatement > :not(VariableDeclaration,ReturnStatement)',
message:
'withDispatch must return an object with consistent keys. Avoid performing logic in `mapDispatchToProps`.',
},
{
selector: 'LogicalExpression[operator="&&"][left.property.name="length"][right.type="JSXElement"]',
message: 'Avoid truthy checks on length property rendering, as zero length is rendered verbatim.',
selector:
'LogicalExpression[operator="&&"][left.property.name="length"][right.type="JSXElement"]',
message:
'Avoid truthy checks on length property rendering, as zero length is rendered verbatim.',
},
],
},
Expand All @@ -127,37 +151,34 @@ module.exports = {
...developmentFiles,
],
rules: {
'react/forbid-elements': [ 'error', {
forbid: [
[ 'button', 'Button' ],
[ 'circle', 'Circle' ],
[ 'g', 'G' ],
[ 'path', 'Path' ],
[ 'polygon', 'Polygon' ],
[ 'rect', 'Rect' ],
[ 'svg', 'SVG' ],
].map( ( [ element, componentName ] ) => {
return {
element,
message: `use cross-platform <${ componentName } /> component instead.`,
};
} ),
} ],
'react/forbid-elements': [
'error',
{
forbid: [
[ 'button', 'Button' ],
[ 'circle', 'Circle' ],
[ 'g', 'G' ],
[ 'path', 'Path' ],
[ 'polygon', 'Polygon' ],
[ 'rect', 'Rect' ],
[ 'svg', 'SVG' ],
].map( ( [ element, componentName ] ) => {
return {
element,
message: `use cross-platform <${ componentName } /> component instead.`,
};
} ),
},
],
},
},
{
files: [
'packages/jest*/**/*.js',
],
extends: [
'plugin:@wordpress/eslint-plugin/test-unit',
],
files: [ 'packages/jest*/**/*.js' ],
extends: [ 'plugin:@wordpress/eslint-plugin/test-unit' ],
},
{
files: [ 'packages/e2e-test*/**/*.js' ],
extends: [
'plugin:@wordpress/eslint-plugin/test-e2e',
],
extends: [ 'plugin:@wordpress/eslint-plugin/test-e2e' ],
},
],
};
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

# Blocks
/packages/block-library @Soean @ajitbohra @jorgefilipecosta @talldan
/packages/block-library/src/gallery @mkevins @pinarol
/packages/block-library/src/social-links @mkaz
/packages/block-library/src/social-link @mkaz

Expand All @@ -37,6 +38,7 @@
/packages/babel-plugin-makepot @ntwb @nerrad @ajitbohra
/packages/babel-preset-default @youknowriad @gziolo @ntwb @nerrad @ajitbohra
/packages/browserslist-config @gziolo @ntwb @nerrad @ajitbohra
/packages/create-block @gziolo
/packages/custom-templated-path-webpack-plugin @ntwb @nerrad @ajitbohra
/packages/docgen @nosolosw
/packages/e2e-test-utils @gziolo @ntwb @nerrad @ajitbohra
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/pull-request-automation.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
on: pull_request
on:
pull_request:
types: [opened, closed]
name: Pull request automation

jobs:
pull-request-automation:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
# Checkout defaults to using the branch which triggered the event, which
# isn't necessarily `master` (e.g. in the case of a merge).
- uses: actions/checkout@v2
with:
ref: master
# Changing into the action's directory and running `npm install` is much
# faster than a full project-wide `npm ci`.
- run: cd packages/project-management-automation && npm install
Expand Down
9 changes: 9 additions & 0 deletions .markdownlintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
bin
build
node_modules
phpunit
playground
storybook
test
vendor
wordpress
3 changes: 3 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Import the default config file and expose it in the project root.
// Useful for editor integrations.
module.exports = require( '@wordpress/scripts/config/.prettierrc.js' );
36 changes: 11 additions & 25 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,38 +1,24 @@
# Contributing
# Contributing Guidelines

Thank you for thinking about contributing to WordPress' Gutenberg project! If you're unsure of anything, know that you're 💯 welcome to submit an issue or pull request on any topic. The worst that can happen is that you'll be politely directed to the best location to ask your question or to change something in your pull request. We appreciate any sort of contribution and don't want a wall of rules to get in the way of that.
Welcome to WordPress' Gutenberg project! We hope you join us in creating the future platform for publishing; all are welcome here.

As with all WordPress projects, we want to ensure a welcoming environment for everyone. With that in mind, all contributors are expected to follow our [Code of Conduct](/CODE_OF_CONDUCT.md).
## How can I contribute?

Before contributing, we encourage you to review the [Contributor Handbook](https://developer.wordpress.org/block-editor/contributors/). If you have any questions, please ask, either in Slack or open an issue in GitHub so we can help clarify.
To learn all about contributing to the Gutenberg project, see the [Contributor Guide](/docs/contributors/readme.md). The handbook includes all the details you need to get setup and start shaping the future of web publishing.

All WordPress projects are [licensed under the GPLv2+](/LICENSE.md), and all contributions to Gutenberg will be released under the GPLv2+ license. You maintain copyright over any contribution you make, and by submitting a pull request, you are agreeing to release that contribution under the GPLv2+ license.
- Code? See the [developer section](/docs/contributors/develop.md).

This document covers the technical details around setup, and submitting your contribution to the Gutenberg project.
- Design? See the [design section](/docs/contributors/design.md).

## Developer Contributions
- Documentation? See the [documentation section](/docs/contributors/document.md).

Please see the [Developer Contributions section](/docs/contributors/develop.md) of the Contributor Handbook.
- Triage? We need help reviewing existing issues to make sure they’re relevant and actionable. Triage is an important contribution because it allows us to work on the highest priority issues. To learn more, please see the [triaging issues section](docs/contributors/repository-management.md#triaging-issues).

## How Can Designers Contribute?
## Guidelines

If you'd like to contribute to the design or front-end, feel free to contribute to tickets labelled [Needs Design](https://github.com/WordPress/gutenberg/issues?q=is%3Aissue+is%3Aopen+label%3A%22Needs+Design%22) or [Needs Design Feedback](https://github.com/WordPress/gutenberg/issues?q=is%3Aissue+is%3Aopen+label%3A"Needs+Design+Feedback%22). We could use your thoughtful replies, mockups, animatics, sketches, doodles. Proposed changes are best done as minimal and specific iterations on the work that precedes it so we can compare. The [WordPress Design team](http://make.wordpress.org/design/) uses [Figma](https://www.figma.com/) to collaborate and share work. If you'd like to contribute, join the [#design channel](http://wordpress.slack.com/messages/design/) in [Slack](https://make.wordpress.org/chat/) and ask the team to set you up with a free Figma account. This will give you access to a helpful [library of components](https://www.figma.com/file/ZtN5xslEVYgzU7Dd5CxgGZwq/WordPress-Components?node-id=0%3A1) used in WordPress.
- As with all WordPress projects, we want to ensure a welcoming environment for everyone. With that in mind, all contributors are expected to follow our [Code of Conduct](/CODE_OF_CONDUCT.md).

## Triage Contributions

*Triage* is the practice of reviewing existing issues to make sure they’re relevant, actionable, and have all the information needed to reproduce and/or solve the issue. Triaging is a very important contribution because it allows the community to focus on and prioritise issues, feature proposals, discussions, and so on.

If you want to learn more about triage, and why it it important, please see the [repository management section](docs/contributors/repository-management.md#triaging-issues) of the Contributor Handbook.

## Contribute to the Documentation

Please see the [Documentation section](/docs/contributors/document.md) of the Contributor Handbook.

Documentation is automatically synced from `master` to the [Block Editor Handbook](https://developer.wordpress.org/block-editor/) every 15 minutes.

### `@wordpress/component`

If you're contributing to the documentation of any component from the `@wordpress/component` package, take a look at its [guidelines for contributing](/packages/components/CONTRIBUTING.md).
- All WordPress projects are [licensed under the GPLv2+](/LICENSE.md), and all contributions to Gutenberg will be released under the GPLv2+ license. You maintain copyright over any contribution you make, and by submitting a pull request, you are agreeing to release that contribution under the GPLv2+ license.

## Reporting Security Issues

Expand Down
5 changes: 1 addition & 4 deletions babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ module.exports = function( api ) {

return {
presets: [ '@wordpress/babel-preset-default' ],
plugins: [
'babel-plugin-emotion',
'babel-plugin-inline-json-import',
],
plugins: [ 'babel-plugin-emotion', 'babel-plugin-inline-json-import' ],
};
};
29 changes: 19 additions & 10 deletions bin/api-docs/are-readmes-unstaged.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,26 @@ const execSync = require( 'child_process' ).execSync;
*/
const getPackages = require( './packages' );

const getUnstagedFiles = () => execSync( 'git diff --name-only', { encoding: 'utf8' } ).split( '\n' ).filter( ( element ) => '' !== element );
const readmeFiles = getPackages().map( ( [ packageName ] ) => join( 'packages', packageName, 'README.md' ) );
const unstagedReadmes = getUnstagedFiles().filter( ( element ) => readmeFiles.includes( element ) );
const getUnstagedFiles = () =>
execSync( 'git diff --name-only', { encoding: 'utf8' } )
.split( '\n' )
.filter( ( element ) => '' !== element );
const readmeFiles = getPackages().map( ( [ packageName ] ) =>
join( 'packages', packageName, 'README.md' )
);
const unstagedReadmes = getUnstagedFiles().filter( ( element ) =>
readmeFiles.includes( element )
);

if ( unstagedReadmes.length > 0 ) {
process.exitCode = 1;
process.stdout.write( chalk.red(
'\n',
'Some API docs may be out of date:',
unstagedReadmes.toString(),
'Either stage them or continue with --no-verify.',
'\n'
) );
process.stdout.write(
chalk.red(
'\n',
'Some API docs may be out of date:',
unstagedReadmes.toString(),
'Either stage them or continue with --no-verify.',
'\n'
)
);
}
11 changes: 7 additions & 4 deletions bin/api-docs/packages.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@ const packages = [
'block-serialization-default-parser',
'blocks',
'compose',
[ 'core-data', {
'Autogenerated actions': 'src/actions.js',
'Autogenerated selectors': 'src/selectors.js',
} ],
[
'core-data',
{
'Autogenerated actions': 'src/actions.js',
'Autogenerated selectors': 'src/selectors.js',
},
],
'data',
'data-controls',
'date',
Expand Down
11 changes: 9 additions & 2 deletions bin/api-docs/update-readmes.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,22 @@ getPackages().forEach( ( entry ) => {
// Each target operates over the same file, so it needs to be processed synchronously,
// as to make sure the processes don't overwrite each other.
const { status, stderr } = spawnSync(
join( __dirname, '..', '..', 'node_modules', '.bin', 'docgen' ).replace( / /g, '\\ ' ),
join(
__dirname,
'..',
'..',
'node_modules',
'.bin',
'docgen'
).replace( / /g, '\\ ' ),
[
join( 'packages', packageName, path ),
`--output packages/${ packageName }/README.md`,
'--to-token',
`--use-token "${ token }"`,
'--ignore "/unstable|experimental/i"',
],
{ shell: true },
{ shell: true }
);

if ( status !== 0 ) {
Expand Down
2 changes: 1 addition & 1 deletion bin/build-plugin-zip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ npm run build
php bin/generate-gutenberg-php.php > gutenberg.tmp.php
mv gutenberg.tmp.php gutenberg.php

build_files=$(ls build/*/*.{js,css,asset.php} build/block-library/blocks/*.php)
build_files=$(ls build/*/*.{js,css,asset.php} build/block-library/blocks/*.php build/block-library/blocks/*/block.json)

# Generate the plugin zip file.
status "Creating archive... 🎁"
Expand Down
Loading