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

Fix: Gallery Block: Append images alt in aria-label attribute. #17102

Closed
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
14b57c7
Fix: Gallery Block: Append images alt in aria-label attribute.
donmhico Aug 20, 2019
e5e571e
Fix: InnerBlocks template sync only on direct locked all (#16973)
jorgefilipecosta Aug 20, 2019
ca4c21c
Check to ensure focus has intentionally left the wrapped component in…
getdave Aug 20, 2019
c413f03
Fix: Required block appender styles are set on edit post (#16943)
jorgefilipecosta Aug 20, 2019
32819b8
Document server functions in block style variations section (#16997)
jorgefilipecosta Aug 20, 2019
3bcf6aa
[RNMobile] update mobile to not use ListEdit (#17070)
mchowning Aug 20, 2019
91b9104
Typewriter experience (#16460)
ellatrix Aug 20, 2019
af23ee6
[RNMobile] Hide replaceable block when adding block (#16931)
mchowning Aug 20, 2019
a2688c0
Update video player style on mobile
maxme Jul 25, 2019
3b74d9c
Add: Disabled block count in the block manager (#17103)
jorgefilipecosta Aug 21, 2019
1b05159
Use `400` as a valid `font-weight`
ntwb Aug 15, 2019
ac95cf6
Writing Flow/Quote: allow splitting (#17121)
ellatrix Aug 21, 2019
a2d0609
Build: remove global install of latest npm since we want to use the p…
gwwar Aug 22, 2019
b89271b
Project automation: Rewrite actions using JavaScript (#17080)
noisysocks Aug 22, 2019
b77291b
Writing Flow: allow undo of patterns with BACKSPACE and ESC (#14776)
ellatrix Aug 22, 2019
e832a89
Apply box-sizing border-box properly to the notices components (#17066)
youknowriad Aug 22, 2019
6146930
Fix: Converting an image using an external source to a gallery does n…
jorgefilipecosta Aug 22, 2019
ccea4f2
Editor: Update the store to use Core Data entities. (#16932)
epiqueras Aug 22, 2019
be881a3
Add callbacks to ServerSideRenderer to handle failures with custom re…
mikejolley Aug 22, 2019
393e01e
[RNMobile] Insure tapping at end of post inserts at end
mchowning Aug 6, 2019
5d21cd0
Project management automation: Fix 'add first time contributor label'…
noisysocks Aug 23, 2019
05b173c
Scripts: Improve recommended settings included in the package (#17027)
gziolo Aug 23, 2019
3386f46
Project management automation: Fix 'add milestone' (#17157)
noisysocks Aug 23, 2019
b5a6978
chore: Remove unused css from ColorPalette component (#17152)
jorgefilipecosta Aug 23, 2019
e1ef1c9
Add the block example API and use it for inserter and switcher previe…
youknowriad Aug 23, 2019
555f726
Fix: Block toolbar appears above sidebar on medium viewports (#17108)
jorgefilipecosta Aug 23, 2019
1f6c3b4
eslint BaseControl fix for TypeError: Cannot read property 'name' of …
bfintal Aug 24, 2019
253eaa3
Docs: Fix creating-dynamic-blocks typo (#17172)
jrchamp Aug 24, 2019
1011b19
remove selection toggle on image (#17175)
senadir Aug 25, 2019
42e2f0c
Add circle-crop variation to Image block. (#16475)
Aug 25, 2019
a356b79
Add: Option to select the style that is automatically applied (#16465)
jorgefilipecosta Aug 26, 2019
c2188c0
Enable an optional namespace parameter for hasAction & hasFilter (#15…
Aug 26, 2019
190de96
Add get_item_schema function to WP_REST_Widget_Areas_Controller (#15981)
jorgefilipecosta Aug 26, 2019
666cbd7
fix(scripts): Use the SCSS shared stylelint-config-wordpress config (…
ntwb Aug 26, 2019
5319aea
Add option to resize Cover Block (#17143)
senadir Aug 26, 2019
539ec35
Fix: Empty Classic Editor inside innerBlock fatal error (#17164)
donmhico Aug 26, 2019
d562340
Allow directly setting a background to Cover (#17041)
senadir Aug 26, 2019
a0d228b
Bump plugin version to 6.4.0-rc.1
jorgefilipecosta Aug 26, 2019
422d812
Update the post schedule label to correctly reflect the date and (#15…
brentswisher Aug 26, 2019
503a804
Use the image alt logic in image block to determine the aria-labels i…
donmhico Aug 27, 2019
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
Prev Previous commit
Next Next commit
[RNMobile] Insure tapping at end of post inserts at end
Previously, tapping at the end of the post would insert a block
immediately after the currently selected block. In addition, this commit
is cleaning out a few unusued props in the block-list file.
  • Loading branch information
mchowning authored and donmhico committed Aug 27, 2019
commit 393e01e455e8b53336be79a5ddc886921277dd50
32 changes: 4 additions & 28 deletions packages/block-editor/src/components/block-list/index.native.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,31 +33,12 @@ export class BlockList extends Component {
this.renderDefaultBlockAppender = this.renderDefaultBlockAppender.bind( this );
this.onCaretVerticalPositionChange = this.onCaretVerticalPositionChange.bind( this );
this.scrollViewInnerRef = this.scrollViewInnerRef.bind( this );
this.getNewBlockInsertionIndex = this.getNewBlockInsertionIndex.bind( this );
this.addBlockToEndOfPost = this.addBlockToEndOfPost.bind( this );
this.shouldFlatListPreventAutomaticScroll = this.shouldFlatListPreventAutomaticScroll.bind( this );
}

finishBlockAppendingOrReplacing( newBlock ) {
// now determine whether we need to replace the currently selected block (if it's empty)
// or just add a new block as usual
if ( this.isReplaceable( this.props.selectedBlock ) ) {
// do replace here
this.props.replaceBlock( this.props.selectedBlockClientId, newBlock );
} else {
this.props.insertBlock( newBlock, this.getNewBlockInsertionIndex() );
}
}

getNewBlockInsertionIndex() {
if ( this.props.isPostTitleSelected ) {
// if post title selected, insert at top of post
return 0;
} else if ( this.props.selectedBlockIndex === -1 ) {
// if no block selected, insert at end of post
return this.props.blockCount;
}
// insert after selected block
return this.props.selectedBlockIndex + 1;
addBlockToEndOfPost( newBlock ) {
this.props.insertBlock( newBlock, this.props.blockCount );
}

blockHolderBorderStyle() {
Expand Down Expand Up @@ -158,7 +139,7 @@ export class BlockList extends Component {
const paragraphBlock = createBlock( 'core/paragraph' );
return (
<TouchableWithoutFeedback onPress={ () => {
this.finishBlockAppendingOrReplacing( paragraphBlock );
this.addBlockToEndOfPost( paragraphBlock );
} } >
<View style={ styles.blockListFooter } />
</TouchableWithoutFeedback>
Expand All @@ -170,10 +151,8 @@ export default compose( [
withSelect( ( select, { rootClientId } ) => {
const {
getBlockCount,
getBlockName,
getBlockIndex,
getBlockOrder,
getSelectedBlock,
getSelectedBlockClientId,
getBlockInsertionPoint,
isBlockInsertionPointVisible,
Expand Down Expand Up @@ -206,13 +185,10 @@ export default compose( [
return {
blockClientIds,
blockCount: getBlockCount( rootClientId ),
getBlockName,
isBlockInsertionPointVisible: isBlockInsertionPointVisible(),
shouldShowBlockAtIndex,
shouldShowInsertionPoint,
selectedBlock: getSelectedBlock(),
selectedBlockClientId,
selectedBlockIndex,
};
} ),
withDispatch( ( dispatch ) => {
Expand Down