-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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] Gallery - Native gallery component draft #18176
Merged
Merged
Conversation
This file contains 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
mkevins
added
[Status] In Progress
Tracking issues with work in progress
Mobile App - i.e. Android or iOS
Native mobile impl of the block editor. (Note: used in scripts, ping mobile folks to change)
[Block] Gallery
Affects the Gallery Block - used to display groups of images
labels
Oct 30, 2019
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 5, 2019 03:40
2edfe43
to
1801c53
Compare
This was referenced Nov 5, 2019
Closed
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 7, 2019 02:30
75d8a12
to
6b4cf2c
Compare
3 tasks
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 12, 2019 13:04
ad821a3
to
8bf5801
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 12, 2019 13:04
6b4cf2c
to
3edb3eb
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 19, 2019 13:35
8bf5801
to
6f1556f
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 19, 2019 13:35
3edb3eb
to
4190b97
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 19, 2019 13:49
6f1556f
to
095d2a0
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 19, 2019 13:58
4190b97
to
8b1e8b3
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 21, 2019 06:19
095d2a0
to
f66567b
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 21, 2019 06:19
ac55dd8
to
85b45af
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 22, 2019 05:59
f66567b
to
91368e0
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 22, 2019 06:00
85b45af
to
1e403ff
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 25, 2019 03:40
91368e0
to
2aa8448
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 25, 2019 03:41
1e403ff
to
7a3fa58
Compare
pinarol
reviewed
Nov 25, 2019
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 26, 2019 06:50
2aa8448
to
deafd68
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 26, 2019 06:51
7a3fa58
to
f030539
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
November 28, 2019 05:48
deafd68
to
e2c7e4c
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
November 28, 2019 05:48
f030539
to
3696fbf
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
December 4, 2019 08:43
0234c1a
to
4794e73
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
December 4, 2019 08:43
f27005b
to
7fb31dc
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
December 4, 2019 09:35
4794e73
to
1248af6
Compare
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
December 4, 2019 09:36
7fb31dc
to
d05dc84
Compare
mkevins
force-pushed
the
try/gallery-draft-tiles
branch
from
December 4, 2019 10:37
1248af6
to
6f2bbb9
Compare
* Add append logic to MediaPlaceholder for gallery * Fix lint errors
mkevins
force-pushed
the
try/gallery-draft-add-native-gallery
branch
from
December 4, 2019 11:29
d05dc84
to
3fcb972
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
[Block] Gallery
Affects the Gallery Block - used to display groups of images
Mobile App - i.e. Android or iOS
Native mobile impl of the block editor. (Note: used in scripts, ping mobile folks to change)
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.
Description
This PR introduces a native
Gallery
component for the semi-cross-platform Gallery block. The purpose of this component is to render a list of images passed via theimages
prop.PR Hierarchy
This PR is part of the PR hierarchy described here. This PR can be tested with the aggregate changeset and integration of components within the related PRs by checking out the branch of the "top level" PR: #18265 via the
gutenberg-mobile
PR: wordpress-mobile/gutenberg-mobile#1498.MediaPlaceholder
Changes to
MediaPlaceholder
from this PR: #18262 have been merged for review here. TheMediaPlaceholder
component has been modified to append media for the nativeGallery
implementation.On web, when new media is added to a gallery, the current selection of items in the gallery is available to the media selection interface, and can be presented as such to the user. The selector behaves more like a "gallery editor", in the sense that the selection is modified (users can add and / or remove items). On mobile, the interface for selecting media items is handled by the "parent apps", and does not "know" about what is currently selected as part of the gallery.
This PR adds the
addToGallery
prop to theMediaPlaceholder
component, and conditionally appends media items to the current selection, passing the resulting collection back throughonSelect
when theaddToGallery
flag is set. When theaddToGallery
flag is not set,onSelect
behavior is not modified.Note: In this implementation, duplicates are removed from the collection via the
id
property, since this is used as akey
in the list of elements that renders these items.The MediaPlaceholder
The changeset here is used in the related "parent" PR: #18111, which includes these changes integrated with related changes in other components necessary for the gallery block.
Block-level caption
This component uses the mobile
Caption
component to add a block-level caption for gallery.To test
Test this component by checking out the branch of the "top level" PR: #18265 via the
gutenberg-mobile
PR: wordpress-mobile/gutenberg-mobile#1498.Checklist: