-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Add the ability to create a new page in the Site Editor #50565
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
Merged
Merged
Changes from 2 commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
b39b236
create new page
SaxonF f045425
remove pages nesting
SaxonF f3e097a
add redirectAfterSave to add page modal
SaxonF 67c222f
reset redirectAfterSave
SaxonF 216bb20
adjust copy of new page to show draft
SaxonF 6558f3f
redirect after adding page
SaxonF 5fc86cf
create page modal use local state
SaxonF 205a2a6
fix import add page
SaxonF 13c4eee
add page use onClose and remove setPage
SaxonF b4f4817
cleaning up add page
SaxonF 7f0140e
Merge branch 'trunk' into add/add-new-page
SaxonF 7ad5b2b
removed value and used placeholder for add page
SaxonF 2148ede
add page modal translations
SaxonF e46efae
e2e test new page modal
SaxonF 28d80f4
Merge branch 'trunk' into add/add-new-page
SaxonF 79d1116
move setting current canvas
SaxonF 604051c
removed unnecessary help text
SaxonF a2426d5
Revert "move setting current canvas"
SaxonF ef1c31c
Merge branch 'trunk' into add/add-new-page
SaxonF 0f168d2
update add new page placeholder
SaxonF 3edbff5
auto focus add new page input
SaxonF 49635c0
Merge branch 'add/add-new-page' of https://github.com/WordPress/guten…
SaxonF 0efe958
add no title placeholder
SaxonF File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -77,6 +77,9 @@ export default function AddNewPageModal( { onSave, onClose } ) { | |
| <form onSubmit={ createPage }> | ||
| <VStack spacing={ 3 }> | ||
| <TextControl | ||
| /* eslint-disable jsx-a11y/no-autofocus */ | ||
| autoFocus | ||
| /* eslint-enable jsx-a11y/no-autofocus */ | ||
| label={ __( 'Page title' ) } | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Not a blocker, just asking if we're not enforcing a page title for creation, maybe add |
||
| onChange={ setTitle } | ||
| placeholder={ __( 'Untitled' ) } | ||
SaxonF marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.