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

Prepare release 1.2 #833

Merged
merged 383 commits into from
Apr 5, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
383 commits
Select commit Hold shift + click to select a range
002678f
include missing yarn install step
JavonDavis Mar 19, 2019
a089058
include missing yarn install step
JavonDavis Mar 19, 2019
662f5ab
try running device tests with sudo access
JavonDavis Mar 19, 2019
70245d4
invlude step to brew install yarn
JavonDavis Mar 19, 2019
66a2d0c
upgrade yarn version
JavonDavis Mar 19, 2019
2d2fb69
upgrade yarn version
JavonDavis Mar 19, 2019
19c1979
set env variables inline
JavonDavis Mar 19, 2019
390ebe2
remove sudo yarn call
JavonDavis Mar 19, 2019
eeec9e1
include npm install step for yan
JavonDavis Mar 19, 2019
708585e
include npm install step for yan
JavonDavis Mar 19, 2019
dc9b881
include npm install step for yan
JavonDavis Mar 19, 2019
9e9e10c
include npm install step for yan
JavonDavis Mar 19, 2019
bcc9842
quit driver after sauce status publish
JavonDavis Mar 19, 2019
d7ea6ee
patch to how driver is dismissed
JavonDavis Mar 19, 2019
367d201
revert initial html
JavonDavis Mar 19, 2019
bf389da
try waiting a little longer for driver to initialize on iOS
JavonDavis Mar 20, 2019
f3ad2b2
include ios build steps in circleci configg
JavonDavis Mar 20, 2019
b870cdf
Rebased gutenberg branch
koke Mar 20, 2019
126a9b2
Merge branch 'develop' into feature/unsupported-core-blocks
koke Mar 20, 2019
f719c7c
Updated gutenberg reference
koke Mar 20, 2019
02fedaf
Update GB reference.
SergioEstevao Mar 20, 2019
889c955
Fix onEnter assignment.
SergioEstevao Mar 20, 2019
a3b2b13
Merge branch 'develop' into feature/lists
SergioEstevao Mar 20, 2019
c595a4f
Update Gutenberg ref
koke Mar 20, 2019
b3bed91
Add fast-average-color since Gutenberg requires it
koke Mar 20, 2019
76b175c
Rename _variables.scss to _native.scss to avoid conflicts with Gutenberg
koke Mar 20, 2019
cee5993
Update GB reference.
SergioEstevao Mar 20, 2019
d00c1ac
Add debug message in MainApplication.
Mar 20, 2019
e8d96f2
Creating ReadableMarginsView component
etoledom Mar 20, 2019
af4db53
try debug configuration
JavonDavis Mar 20, 2019
e80ac18
experiement with yarn ios
JavonDavis Mar 20, 2019
143589f
experiement with yarn ios
JavonDavis Mar 20, 2019
113ca5e
experiement with sudo yarn
JavonDavis Mar 20, 2019
03796bc
Adding styles to ReadableMarginsView
etoledom Mar 20, 2019
61b6ef7
Implementing ReadableMarginsView on block-manager
etoledom Mar 20, 2019
0a63d3c
iOS: Fix example app crash on iPad on more button press.
etoledom Mar 20, 2019
01f397d
Add ReadableMarginsView to DefaultBlockAppender.
etoledom Mar 20, 2019
1a0999e
Rename ReadableMarginsView as ReadableContentView
etoledom Mar 20, 2019
470ae0e
Converting ReadableContentView into function
etoledom Mar 20, 2019
2f1bb34
try sudo yarn install
JavonDavis Mar 20, 2019
63017ab
try without sudo again
JavonDavis Mar 20, 2019
255e2a7
Fix borders on selected blocks
etoledom Mar 20, 2019
a0a5444
try without sudo again
JavonDavis Mar 20, 2019
bb6c031
Fix lint issues
etoledom Mar 20, 2019
6dbb9e3
reorder config step
JavonDavis Mar 20, 2019
2f2dbfc
remove yarn start
JavonDavis Mar 20, 2019
8bacf67
remove build ios step
JavonDavis Mar 20, 2019
3c182ab
resolved error in zip command
JavonDavis Mar 21, 2019
744ce55
resolved error in zip command missing recursive flag
JavonDavis Mar 21, 2019
b345050
removed bundle file and included in gitignore
JavonDavis Mar 21, 2019
6915a74
reset bundle to develop
JavonDavis Mar 21, 2019
8f32b72
reset bundle to develop
JavonDavis Mar 21, 2019
c58a46a
Update dependencies after refactoring mobile blocks to fix circle dep…
Tug Mar 21, 2019
378a4ca
Update gutenberg ref
Tug Mar 21, 2019
8a75930
Remove UnsupportedBlock in favor of core/missing
koke Mar 21, 2019
0bd29b2
Merge branch 'develop' into issue/604-add-readable-margins
etoledom Mar 21, 2019
bd1fae9
Merge remote-tracking branch 'origin/develop' into fix/makepot-2
Tug Mar 21, 2019
6098548
Update strings to reuse some from gutenberg
Tug Mar 21, 2019
139ebdf
change yarn ios to preios
JavonDavis Mar 21, 2019
05d8813
Update yarn-install cache key
jtreanor Mar 21, 2019
9ee8294
Add Carthage caching
jtreanor Mar 21, 2019
9debb49
Better caching and use xcodebuild
jtreanor Mar 21, 2019
98aa40d
Fix yarn cache and don't use xcodebuild
jtreanor Mar 21, 2019
7416ffd
Build debug
jtreanor Mar 21, 2019
3e4a034
Merge branch 'develop' into issue/604-add-readable-margins
etoledom Mar 21, 2019
b3cf21d
Fix lint issues
etoledom Mar 21, 2019
6e85f23
Fix tab
etoledom Mar 21, 2019
ed8c761
Update gutenberg ref to same than develop
etoledom Mar 21, 2019
c83c5ad
revert to the Release configuration
JavonDavis Mar 21, 2019
beb523b
resolve typo in app file location for CI
JavonDavis Mar 21, 2019
a53cea8
check for accessibility label updates
JavonDavis Mar 21, 2019
c4f45c1
wait a little longer on driver
JavonDavis Mar 21, 2019
4f6e701
Enable split view on iPad to make testing easier.
SergioEstevao Mar 22, 2019
d05c33e
Merge branch 'develop' into issue/604-add-readable-margins
etoledom Mar 22, 2019
864e5f2
Merge pull request #769 from wordpress-mobile/issue/604-add-readable-…
etoledom Mar 22, 2019
356695d
Updated gutenberg reference after rebasing from master
koke Mar 22, 2019
dc115b8
Merge branch 'develop' into feature/unsupported-core-blocks
koke Mar 22, 2019
c967e28
Merge pull request #777 from wordpress-mobile/master
loremattei Mar 22, 2019
1ecaa54
use block index instead of client ID for easier construction of block…
JavonDavis Mar 22, 2019
e04acce
Update gutenberg ref to point to master again (#778)
pinarol Mar 22, 2019
83fd054
Merge branch 'develop' into try/unit-test
pinarol Mar 25, 2019
e3c894c
Add missing style mocks
pinarol Mar 25, 2019
1a96c69
Fix lint issues
pinarol Mar 25, 2019
96a43ff
Tests: Remove the need to clear mocks for every test.
etoledom Mar 25, 2019
552c2c7
Adding `enzyme.config.js`
etoledom Mar 25, 2019
7ca12f5
Fix lint issues
etoledom Mar 25, 2019
0bd33dc
Add unit tests for html-text-input
pinarol Mar 25, 2019
578c645
Update AztecView to version 1.5.0
SergioEstevao Mar 25, 2019
b5de4f7
Remove unnecessary lines
pinarol Mar 25, 2019
832ddd6
Update gutenberg ref
Tug Mar 25, 2019
fc4d46b
Add multiline property to RCTAzteView.
SergioEstevao Mar 25, 2019
a4ea93b
Update the assert for state.value on html input tests
pinarol Mar 25, 2019
d91cd04
Fix lint issues
pinarol Mar 25, 2019
ca8c307
Update demo app to swift 4.2
SergioEstevao Mar 25, 2019
799eee9
Refactoring html-text-input to share more code between platform files
etoledom Mar 22, 2019
569fd81
Fix flow issues
etoledom Mar 25, 2019
12a8ae8
Fix lint issues
etoledom Mar 25, 2019
8102542
HTMLView: Fixed content on Android.
etoledom Mar 25, 2019
284f84d
HTMLView remove extra ios padding (added for testing)
etoledom Mar 25, 2019
a3bd9ab
resolve conflicts with master
JavonDavis Mar 25, 2019
590a98e
resolve empty initial-html causing ci check errors
JavonDavis Mar 25, 2019
986d999
remove release configuration
JavonDavis Mar 26, 2019
ce4e9bb
update bundle output path
JavonDavis Mar 26, 2019
8be80dd
update circleci images
JavonDavis Mar 26, 2019
ce8d880
update circleci images
JavonDavis Mar 26, 2019
8dda3ae
remove cache for aztech
JavonDavis Mar 26, 2019
ac716ee
reuse original bundle command
JavonDavis Mar 26, 2019
509bdfb
accept licenses
JavonDavis Mar 26, 2019
8de552d
clean install yarn
JavonDavis Mar 26, 2019
19f32e3
update zip loation based on derived data
JavonDavis Mar 26, 2019
5b67b1f
fix device tests html file
JavonDavis Mar 26, 2019
b6f7796
Remove whitespace
SergioEstevao Mar 26, 2019
b93c092
AztecView: Propagete onFocus event from Native on iOS.
etoledom Mar 26, 2019
c42f647
Toolbar: HideKeyboard button now clears the selected block.
etoledom Mar 26, 2019
f12b2ac
Merge pull request #782 from wordpress-mobile/feature/update_ios_demo…
SergioEstevao Mar 26, 2019
6d9ce4a
Fix lint issues
etoledom Mar 26, 2019
eb7c78b
Merge branch 'develop' into issue/546-add-block-icon-color
etoledom Mar 26, 2019
077309c
Remove conflicting colors.scss import
etoledom Mar 26, 2019
bd12d09
Update gutenberg ref
etoledom Mar 26, 2019
0e44285
Send Dashicon component directly on ToolbarButton to set proper color.
etoledom Mar 26, 2019
6d6fd76
Fix lint issues
etoledom Mar 26, 2019
46264f1
Test if xgettext exists before running makepot script
Tug Mar 26, 2019
8153e3f
Merge pull request #750 from wordpress-mobile/fix/makepot-2
Tug Mar 26, 2019
fb24942
BlockToolbar: Remove unnecessary iconProps prop from AddBlock Toolbar…
etoledom Mar 26, 2019
23bda2f
Update gutenberg ref
Tug Mar 26, 2019
e45a654
Update gutenberg ref
Tug Mar 26, 2019
8f81590
Update GB reference.
SergioEstevao Mar 26, 2019
d1c93b0
Merge branch 'develop' into feature/lists
SergioEstevao Mar 26, 2019
7d27850
HTMLTextInput: Simplified code share implementation
etoledom Mar 26, 2019
7d3a9c8
HTMLTextInput: Implement necessary changes on Android branch for code…
etoledom Mar 26, 2019
668fd64
Rename HTMLInputViewUI to HTMLInputContainer
etoledom Mar 26, 2019
64438d7
HTMLTextInput: Replace bottom padding view with extra `pading-bottom`…
etoledom Mar 26, 2019
86af452
Update gutenberg reference.
SergioEstevao Mar 26, 2019
b657981
Merge pull request #780 from wordpress-mobile/fix/gutenberg-develop-m…
Tug Mar 26, 2019
0149325
Update GB reference.
SergioEstevao Mar 26, 2019
5139b51
Fix lint issues
etoledom Mar 26, 2019
d496c64
Remove unnecessary code from html-text-input-ui.android.js
etoledom Mar 26, 2019
bd1ebf5
Merge pull request #781 from wordpress-mobile/try/html-view-code-share
etoledom Mar 26, 2019
a7dad58
Update GB hash
daniloercoli Mar 26, 2019
6179d5a
include cache again
JavonDavis Mar 26, 2019
0469e42
fix error to accept licenses
JavonDavis Mar 26, 2019
27426a2
wait for sdkmanager license acceptance
JavonDavis Mar 26, 2019
43449b0
resolve merge conflict with develop
JavonDavis Mar 26, 2019
197accb
ignore non zero exit status on run ios failure
JavonDavis Mar 26, 2019
0b9e18b
Update GB hash
daniloercoli Mar 27, 2019
9ebdffc
Merge branch 'develop' into issue/546-add-block-icon-color
etoledom Mar 27, 2019
48e5251
Merge pull request #628 from wordpress-mobile/issue/546-add-block-ico…
etoledom Mar 27, 2019
c0a21d2
Merge pull request #787 from wordpress-mobile/issue/734-Enter-on-Head…
daniloercoli Mar 27, 2019
2302279
localize accessibilitylabel search in editor page
JavonDavis Mar 27, 2019
750c94f
Update GB reference.
SergioEstevao Mar 27, 2019
d4480ce
Update aztec version being used in iOS.
SergioEstevao Mar 27, 2019
bb83187
Update AztecView to support break on multiline aztec views when doing…
SergioEstevao Mar 27, 2019
628bb9e
fixed linter error and merged in develop
JavonDavis Mar 27, 2019
8c72ce7
Fix to use android.util.Log for sample app.
Mar 27, 2019
a37fcf4
Add link for original RN LogLevel.
Mar 27, 2019
d52520e
Update Gutenberg (merge latest master)
koke Mar 28, 2019
78b29a4
Merge branch 'develop' into feature/unsupported-core-blocks
koke Mar 28, 2019
ad2292e
Merge branch 'develop' into merge/v.1.1.2-to-develop
etoledom Mar 28, 2019
fc293dc
Update JS Bundles
etoledom Mar 28, 2019
19a4c13
Merge pull request #792 from wordpress-mobile/merge/v.1.1.2-to-develop
etoledom Mar 28, 2019
9a5a513
Intercept image request to add access token when site is private (#788)
marecar3 Mar 28, 2019
65ee9ff
Improve Accessibility on Toolbar
etoledom Mar 28, 2019
4aa4b30
Fix lint issues
etoledom Mar 28, 2019
a0fb6a8
changes to labels and indentation in certain areas
JavonDavis Mar 28, 2019
f045042
fixed linter error with extra space
JavonDavis Mar 28, 2019
a822fed
Move helpers to the top in html text input tests
pinarol Mar 29, 2019
aed92d0
Paragraph Tests: Remove global function definitions
etoledom Mar 29, 2019
51183cf
Fix iOS review points.
Mar 29, 2019
0bc1988
Rename bridge method to editorDidEmitLog from editorDidEmitLog.
Mar 29, 2019
8f1e207
Fix bridge and callback interface method name to editorDidEmitLog fro…
Mar 29, 2019
0e6c792
Update GB reference.
SergioEstevao Mar 29, 2019
89c9be2
Merge pull request #784 from wordpress-mobile/issue/702-hide-keyboard…
etoledom Mar 29, 2019
acf89e8
Fix paragraph block tests to test properly split on Enter
etoledom Mar 29, 2019
d243e7a
Remove multiline property.
SergioEstevao Mar 29, 2019
6c99072
Merge branch 'develop' into feature/lists
SergioEstevao Mar 29, 2019
a090aaf
Merge pull request #746 from hotchemi/issues/710
hypest Mar 29, 2019
67e5621
Update GB reference.
SergioEstevao Mar 29, 2019
fc3486a
Update gutenberg ref
etoledom Apr 1, 2019
10b2258
Do not prettify the HTML when outputting to GB.
SergioEstevao Apr 1, 2019
d499d51
updated recyclerview-list reference
mzorz Apr 1, 2019
101ee91
updated yarn.lock
mzorz Apr 1, 2019
514ca67
Upgrade react-native to version 0.59.3
Tug Apr 1, 2019
d2302f6
Revert "updated yarn.lock"
mzorz Apr 1, 2019
b002ccb
updated yarn.lock with yarn 1.15.2
mzorz Apr 1, 2019
92e359b
code indentation cleanup and undo change in scheme config
JavonDavis Apr 1, 2019
837d804
Merge pull request #796 from wordpress-mobile/update/recyclerviewlist…
mzorz Apr 1, 2019
0743395
redo config change
JavonDavis Apr 1, 2019
83b28d5
Get html without any formatting.
SergioEstevao Apr 1, 2019
89dd409
fixed merge conflicts
mzorz Apr 1, 2019
302e109
updated JS bundles
mzorz Apr 1, 2019
8da08a7
remove react native install and add bundle scripts to package.json
JavonDavis Apr 1, 2019
339c207
remove unnecessary config owner update
JavonDavis Apr 1, 2019
5cb149a
Merge Appium UI tests
JavonDavis Apr 1, 2019
ce86bab
Merge branch 'develop' into merge/v1.1.3-to-develop
jtreanor Apr 2, 2019
819c18a
Hide the keyboard when moving Up/Down a block by tapping on the toolb…
daniloercoli Apr 2, 2019
7a463e9
Merge pull request #801 from wordpress-mobile/merge/v1.1.3-to-develop
jtreanor Apr 2, 2019
010e519
Update React third party specs to point to React 0.59.3
SergioEstevao Apr 2, 2019
a297eec
Revert "Include UI tests for blocks with Appium"
jtreanor Apr 2, 2019
e01cc75
Merge pull request #803 from wordpress-mobile/revert-676-try/e2e-test…
jtreanor Apr 2, 2019
2f145bf
Merge pull request #797 from wordpress-mobile/upgrade/react-native-0-…
Tug Apr 2, 2019
ad9eb10
Merge branch 'develop' into feature/lists
SergioEstevao Apr 2, 2019
0816ca5
Update GB reference.
SergioEstevao Apr 2, 2019
382925d
Update gutenberg ref to master
etoledom Apr 3, 2019
ee696ff
Merge branch 'issue/accessibility-mark-i' of https://github.com/wordp…
etoledom Apr 3, 2019
bbe03f8
Merge pull request #793 from wordpress-mobile/issue/accessibility-mark-i
etoledom Apr 3, 2019
50093c3
Update GB-reference.
SergioEstevao Apr 3, 2019
b0352d3
Send images from pasteboard to onPaste event.
SergioEstevao Apr 3, 2019
20a2d52
Update GB reference.
SergioEstevao Apr 3, 2019
21c8d02
Update GB reference.
SergioEstevao Apr 3, 2019
e2629d1
Update gutenberg to master
koke Apr 3, 2019
6cfaa89
Implement media import.
SergioEstevao Apr 3, 2019
cc56eb4
Merge branch 'develop' into feature/unsupported-core-blocks
koke Apr 3, 2019
6632e51
Update GB reference.
SergioEstevao Apr 3, 2019
c391c55
Merge pull request #643 from wordpress-mobile/feature/unsupported-cor…
koke Apr 3, 2019
8f274bd
Merge branch 'develop' into issue/730_copy_paste
SergioEstevao Apr 3, 2019
abc5d15
added manifest merge to enable use of React Native's DevSettings screen
mzorz Apr 3, 2019
77d33cd
Remove deprecated controls plugin
koke Apr 3, 2019
596163e
Merge branch 'develop' into feature/lists
SergioEstevao Apr 3, 2019
3eb3ae1
Merge pull request #814 from wordpress-mobile/fix-core-data-warning
koke Apr 4, 2019
7e971c3
Merge pull request #813 from wordpress-mobile/try/debug-add-rn-dev-se…
hypest Apr 4, 2019
6665935
Fix image upload progress not being displayed on the second time (#811)
pinarol Apr 4, 2019
25a4e7f
Merge branch 'develop' into feature/lists
SergioEstevao Apr 4, 2019
7f43ee0
Update GB reference.
SergioEstevao Apr 4, 2019
db329d9
Merge branch 'develop' into issue/730_copy_paste
SergioEstevao Apr 4, 2019
5cd6df8
Make utility function a tiny bit clearer
Tug Apr 4, 2019
b7a3f57
Convert to whitespaces.
SergioEstevao Apr 4, 2019
84755cc
Remove unecessary variable.
SergioEstevao Apr 4, 2019
21dce2a
Merge pull request #752 from wordpress-mobile/try/unit-test
etoledom Apr 4, 2019
43da5ba
Update GB ref
hypest Apr 4, 2019
fe71487
Merge branch 'develop' into feature/lists
SergioEstevao Apr 4, 2019
7447c0c
Update GB reference.
SergioEstevao Apr 4, 2019
26f021e
Update GB reference.
SergioEstevao Apr 5, 2019
595f8ee
Update Aztec version.
SergioEstevao Apr 5, 2019
b3c03e6
Update GB reference.
SergioEstevao Apr 5, 2019
478bad3
Update GB reference.
SergioEstevao Apr 5, 2019
dd5b38d
Update bundles.
SergioEstevao Apr 5, 2019
c6f1589
Update GB reference.
SergioEstevao Apr 5, 2019
3bd518a
Merge pull request #810 from wordpress-mobile/issue/730_copy_paste
SergioEstevao Apr 5, 2019
ca04558
Merge branch 'develop' into feature/lists
SergioEstevao Apr 5, 2019
f02ba73
Update GB reference.
SergioEstevao Apr 5, 2019
1729d5d
Merge pull request #802 from wordpress-mobile/issue/311-Moving-block-…
daniloercoli Apr 5, 2019
c4636d7
Update Aztec for v1.2.0 release
jtreanor Apr 5, 2019
2c0104b
Update bundles.
SergioEstevao Apr 5, 2019
d3d67ce
Merge pull request #704 from wordpress-mobile/feature/lists
SergioEstevao Apr 5, 2019
af73702
Update package version.
SergioEstevao Apr 5, 2019
63bd3c1
Merge pull request #831 from wordpress-mobile/update-aztec
jtreanor Apr 5, 2019
57b2e58
Merge branch 'develop' into release/1.2
SergioEstevao Apr 5, 2019
f551dc6
Update JS bundles for 1.2 release
jtreanor Apr 5, 2019
71ca308
Update GB reference.
SergioEstevao Apr 5, 2019
527ad9a
Update bundles.
SergioEstevao Apr 5, 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
1 change: 1 addition & 0 deletions .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
<PROJECT_ROOT>/gutenberg/node_modules/cypress/.*
<PROJECT_ROOT>/gutenberg/node_modules/config-chain/.*
<PROJECT_ROOT>/gutenberg/node_modules/editions/es2015/.*
<PROJECT_ROOT>/gutenberg/node_modules/@parcel/.*

; Mirror some ignores from Gutenberg tools
<PROJECT_ROOT>/node_modules/config-chain/.*
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -95,3 +95,4 @@ buck-out/
!.vscode/extensions.json

*.pot
bin/wp-cli.phar
9 changes: 9 additions & 0 deletions __mocks__/styleMock.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,19 @@ module.exports = {
'block-editor-plain-text': {
fontFamily: 'serif',
},
addBlockButton: {
color: '',
},
blockHolderFocused: {
borderColor: 'gray',
},
'wp-block-heading': {
minHeight: 60,
},
'editor-rich-text': {
minHeight: 50,
},
'editor-plain-text': {
fontFamily: 'serif',
},
};
24 changes: 22 additions & 2 deletions android/app/src/main/java/com/gutenberg/MainApplication.java
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.gutenberg;

import android.app.Application;
import android.util.Log;

import com.facebook.react.ReactApplication;
import com.horcrux.svg.SvgPackage;

import org.wordpress.mobile.ReactNativeAztec.ReactAztecPackage;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaSelectedCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.GutenbergBridgeJS2Parent.MediaUploadCallback;
import org.wordpress.mobile.ReactNativeGutenbergBridge.RNReactNativeGutenbergBridgePackage;
import com.github.godness84.RNRecyclerViewList.RNRecyclerviewListPackage;
import com.facebook.react.ReactNativeHost;
Expand All @@ -20,6 +20,8 @@

public class MainApplication extends Application implements ReactApplication {

private static final String TAG = "MainApplication";

private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
@Override
public boolean getUseDeveloperSupport() {
Expand Down Expand Up @@ -60,6 +62,24 @@ public void requestImageUploadCancel(int mediaId) {}

@Override
public void editorDidMount(boolean hasUnsupportedBlocks) {}

@Override
public void editorDidEmitLog(String message, LogLevel logLevel) {
switch (logLevel) {
case TRACE:
Log.d(TAG, message);
break;
case INFO:
Log.i(TAG, message);
break;
case WARN:
Log.w(TAG, message);
break;
case ERROR:
Log.e(TAG, message);
break;
}
}
})
);
}
Expand Down
2,875 changes: 1,512 additions & 1,363 deletions bundle/android/App.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion bundle/android/App.js.map

Large diffs are not rendered by default.

2,885 changes: 1,517 additions & 1,368 deletions bundle/ios/App.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion bundle/ios/App.js.map

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions enzyme.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/**
* External dependencies
*/
import { configure } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
configure( { adapter: new Adapter() } );
2 changes: 1 addition & 1 deletion gutenberg
Submodule gutenberg updated 501 files
4 changes: 2 additions & 2 deletions ios/gutenberg.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1530,7 +1530,7 @@
PRODUCT_NAME = gutenberg;
SWIFT_OBJC_BRIDGING_HEADER = "gutenberg-Bridging-Header.h";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 3.0;
SWIFT_VERSION = 4.2;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
Expand Down Expand Up @@ -1565,7 +1565,7 @@
);
PRODUCT_NAME = gutenberg;
SWIFT_OBJC_BRIDGING_HEADER = "gutenberg-Bridging-Header.h";
SWIFT_VERSION = 3.0;
SWIFT_VERSION = 4.2;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
Expand Down
2 changes: 1 addition & 1 deletion ios/gutenberg/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {

var window: UIWindow?

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {

window = UIWindow(frame: UIScreen.main.bounds)

Expand Down
21 changes: 20 additions & 1 deletion ios/gutenberg/GutenbergViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,11 @@ extension GutenbergViewController: GutenbergBridgeDelegate {
}
}

func gutenbergDidRequestImport(from url: URL, with callback: @escaping MediaPickerDidPickMediaCallback) {
let id = mediaUploadCoordinator.upload(url: url)
callback(id, url.absoluteString)
}

func pickAndUpload(from source: UIImagePickerController.SourceType, callback: @escaping MediaPickerDidPickMediaCallback) {
mediaPickCoordinator = MediaPickCoordinator(presenter: self, callback: { (url) in
guard let url = url, let mediaID = self.mediaUploadCoordinator.upload(url: url) else {
Expand Down Expand Up @@ -122,6 +127,19 @@ extension GutenbergViewController: GutenbergBridgeDelegate {
}
progress.cancel()
}

func gutenbergDidEmitLog(message: String, logLevel: LogLevel) {
switch logLevel {
case .trace:
print("Debug: \(message)")
case .info:
print("Info: \(message)")
case .warn:
print("Warn: \(message)")
case .error:
print("Error: \(message)")
}
}
}

extension GutenbergViewController: GutenbergBridgeDataSource {
Expand Down Expand Up @@ -176,7 +194,8 @@ extension GutenbergViewController {

func showMoreSheet() {
let alert = UIAlertController(title: nil, message: nil, preferredStyle: .actionSheet)

alert.popoverPresentationController?.barButtonItem = navigationItem.rightBarButtonItem

let cancelAction = UIAlertAction(title: "Keep Editing", style: .cancel)
alert.addAction(toggleHTMLModeAction)
alert.addAction(updateHtmlAction)
Expand Down
67 changes: 37 additions & 30 deletions ios/gutenberg/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,6 @@
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>UIAppFonts</key>
<array>
<string>NotoSerif-BoldItalic.ttf</string>
<string>NotoSerif-Regular.ttf</string>
<string>NotoSerif-Italic.ttf</string>
<string>NotoSerif-Bold.ttf</string>
</array>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
Expand All @@ -31,6 +24,36 @@
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>localhost</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
</dict>
</dict>
</dict>
<key>NSCameraUsageDescription</key>
<string>To take photos or videos to use in your posts.</string>
<key>NSLocationUsageDescription</key>
<string>The app would like to add your location to posts on sites where you have enabled geotagging.</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string>The app would like to add your location to posts on sites where you have enabled geotagging.</string>
<key>NSMicrophoneUsageDescription</key>
<string>Enable microphone access to record sound in your videos.</string>
<key>NSPhotoLibraryAddUsageDescription</key>
<string>To add photos or videos to your posts.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>To add photos or videos to your posts.</string>
<key>UIAppFonts</key>
<array>
<string>NotoSerif-BoldItalic.ttf</string>
<string>NotoSerif-Regular.ttf</string>
<string>NotoSerif-Italic.ttf</string>
<string>NotoSerif-Bold.ttf</string>
</array>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
Expand All @@ -43,30 +66,14 @@
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
<key>NSLocationWhenInUseUsageDescription</key>
<string>The app would like to add your location to posts on sites where you have enabled geotagging.</string>
<key>NSCameraUsageDescription</key>
<string>To take photos or videos to use in your posts.</string>
<key>NSLocationUsageDescription</key>
<string>The app would like to add your location to posts on sites where you have enabled geotagging.</string>
<key>NSMicrophoneUsageDescription</key>
<string>Enable microphone access to record sound in your videos.</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>To add photos or videos to your posts.</string>
<key>NSPhotoLibraryAddUsageDescription</key>
<string>To add photos or videos to your posts.</string>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>localhost</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
</dict>
</dict>
</dict>
</dict>
</plist>
6 changes: 3 additions & 3 deletions ios/gutenberg/MediaPickCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class MediaPickCoordinator: NSObject, UIImagePickerControllerDelegate, UINavigat

func save(image: UIImage, toTemporaryDirectoryUsingName name: String) -> URL? {
let url = URL(fileURLWithPath: NSTemporaryDirectory() + name + ".jpg")
guard let data = UIImageJPEGRepresentation(image, 1.0) else {
guard let data = image.jpegData(compressionQuality: 1.0) else {
return nil
}
do {
Expand All @@ -44,11 +44,11 @@ class MediaPickCoordinator: NSObject, UIImagePickerControllerDelegate, UINavigat
}
}

func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [String : Any]) {
func imagePickerController(_ picker: UIImagePickerController, didFinishPickingMediaWithInfo info: [UIImagePickerController.InfoKey : Any]) {
presenter.dismiss(animated: true, completion: nil)
let mediaID = UUID().uuidString
guard
let image = info[UIImagePickerControllerOriginalImage] as? UIImage,
let image = info[UIImagePickerController.InfoKey.originalImage] as? UIImage,
let url = save(image: image, toTemporaryDirectoryUsingName: mediaID)
else {
callback(nil)
Expand Down
10 changes: 9 additions & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,13 @@ if ( process.env.TEST_RN_PLATFORM ) {

module.exports = {
verbose: true,
// Automatically clear mock calls and instances between every test
clearMocks: true,
preset: 'react-native',
setupFiles: [ './jest/setup.js' ],
setupFiles: [
'./jest/setup.js',
'<rootDir>/enzyme.config.js',
],
testEnvironment: 'jsdom',
testPathIgnorePatterns: [
'/node_modules/',
Expand Down Expand Up @@ -49,4 +54,7 @@ module.exports = {
// https://github.com/facebook/react-native/blob/master/jest-preset.json#L20
'node_modules/(?!(simple-html-tokenizer|(jest-)?react-native|react-clone-referenced-element))',
],
snapshotSerializers: [
'enzyme-to-json/serializer',
],
};
9 changes: 9 additions & 0 deletions jest/setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jest.mock( '../react-native-gutenberg-bridge', () => {
subscribeUpdateHtml: jest.fn(),
subscribeMediaAppend: jest.fn(),
editorDidMount: jest.fn(),
subscribeMediaUpload: jest.fn(),
};
} );

Expand All @@ -27,3 +28,11 @@ jest.mock( 'react-native-safe-area', () => {
} );

jest.mock( 'react-native-recyclerview-list' );

if ( ! global.window.matchMedia ) {
global.window.matchMedia = () => ( {
matches: false,
addListener: () => {},
removeListener: () => {},
} );
}
21 changes: 16 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gutenberg-mobile",
"version": "1.1.2",
"version": "1.2.0",
"private": true,
"config": {
"jsfiles": "./*.js src/*.js src/**/*.js src/**/**/*.js",
Expand All @@ -22,6 +22,9 @@
"babel-plugin-react-native-platform-specific-extensions": "^1.1.1",
"cross-env": "^5.1.4",
"empty": "^0.10.1",
"enzyme": "^3.9.0",
"enzyme-adapter-react-16": "^1.11.2",
"enzyme-to-json": "^3.3.5",
"equivalent-key-map": "^0.2.0",
"eslint": "^5.12.1",
"eslint-plugin-flowtype": "^3.4.2",
Expand Down Expand Up @@ -56,22 +59,28 @@
"bundle:ios": "mkdir -p bundle/ios && yarn react-native bundle --platform ios --dev false --entry-file index.js --assets-dest bundle/ios --bundle-output bundle/ios/App.js --sourcemap-output bundle/ios/App.js.map",
"i18n-cache": "node i18n-cache/index.js",
"postinstall": "yarn i18n-cache",
"makepot": "xgettext -f <( find . \\( -path './gutenberg/*/src/*.native.js' -or -path './src/*.js' \\) ! -path 'node_modules' -print ) --from-code=UTF-8 -k__ -k_n -k_x -k_nx -x ./gutenberg/languages/gutenberg.pot -o ./gutenberg-mobile.pot",
"install:wpcli": "(test -x bin/wp-cli.phar || curl -Ls https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar -o bin/wp-cli.phar && chmod +x bin/wp-cli.phar) && bin/wp-cli.phar --info",
"prewp": "yarn install:wpcli",
"wp": "php -d memory_limit=512M bin/wp-cli.phar",
"premakepot": "( command -v xgettext >/dev/null 2>&1 || { echo \"ERROR: xgettext is required to parse our Flow code.\" >&2; exit 1; } ) && yarn makepot:gutenberg",
"makepot": "bash -c \"xgettext -f <( find . -path './src/*.js' ! -path 'node_modules' -print ) --from-code=UTF-8 -k__ -k_n -k_x -k_nx -x ./gutenberg.pot -o ./gutenberg-mobile.pot\"",
"makepot:gutenberg": "yarn clean:gutenberg && yarn wp i18n make-pot ./gutenberg --ignore-domain gutenberg.pot",
"android": "react-native run-android",
"prewpandroid": "rm -Rf $TMPDIR/gbmobile-wpandroidfakernroot && mkdir $TMPDIR/gbmobile-wpandroidfakernroot && ln -s $(cd \"$(dirname \"../../../\")\"; pwd) $TMPDIR/gbmobile-wpandroidfakernroot/android",
"wpandroid": "yarn android --root $TMPDIR/gbmobile-wpandroidfakernroot --variant wasabiDebug --appIdSuffix beta --appFolder WordPress --main-activity=ui.WPLaunchActivity",
"preios": "yarn preios:xcode10 && yarn preios:carthage",
"preios:carthage": "cd react-native-aztec && yarn install-aztec-ios",
"preios:xcode10": "cd node_modules/react-native && ./scripts/ios-install-third-party.sh && cd third-party/glog-0.3.5 && [ -f libglog.pc ] || ../../scripts/ios-configure-glog.sh",
"ios": "react-native run-ios",
"test": "cross-env NODE_ENV=test node node_modules/jest/bin/jest.js --verbose --config jest.config.js",
"test": "cross-env NODE_ENV=test node node_modules/jest/bin/jest.js --verbose false --config jest.config.js",
"test:inside-gb": "cross-env NODE_ENV=test node node_modules/jest/bin/jest.js --verbose --config jest_gb.config.js",
"test:debug": "cross-env NODE_ENV=test node --inspect-brk node_modules/jest/bin/jest.js --runInBand --verbose --config jest.config.js",
"flow": "flow",
"prettier": "prettier-eslint --write $npm_package_config_jsfiles $npm_package_config_scssfiles",
"clean": "yarn clean:aztec; yarn cache clean; yarn clean:haste; yarn clean:jest; yarn clean:metro; yarn clean:react; yarn clean:watchman; yarn clean:node;",
"clean:runtime": "yarn clean:haste; yarn clean:react; yarn clean:metro; yarn clean:jest; yarn clean:watchman; yarn clean:babel-cache",
"clean:aztec": "cd react-native-aztec && yarn clean && cd example && yarn clean",
"clean:gutenberg": "cd gutenberg && npm run clean:packages && rm -rf build",
"clean:haste": "rm -rf /tmp/haste-map-react-native-packager-*",
"clean:install": "yarn clean; yarn",
"clean:jest": "yarn jest --clearCache --config jest.config.js; rm -rf $TMPDIR/jest_*",
Expand All @@ -91,8 +100,10 @@
"classnames": "^2.2.5",
"dom-react": "^2.2.1",
"domutils": "^1.7.0",
"fast-average-color": "^4.3.0",
"hpq": "^1.2.0",
"jed": "^1.1.1",
"jest-serializer-enzyme": "^1.0.0",
"js-beautify": "^1.7.5",
"jsc-android": "236355.x.x",
"jsdom-jscore": "git+https://github.com/iamcco/jsdom-jscore-rn.git#a562f3d57c27c13e5bfc8cf82d496e69a3ba2800",
Expand All @@ -104,11 +115,11 @@
"node-libs-react-native": "^1.0.2",
"node-sass": "^4.8.3",
"react": "16.8.3",
"react-native": "0.59.0",
"react-native": "0.59.3",
"react-native-hr": "git+https://github.com/Riglerr/react-native-hr.git#2d01a5cf77212d100e8b99e0310cce5234f977b3",
"react-native-keyboard-aware-scroll-view": "git+https://github.com/wordpress-mobile/react-native-keyboard-aware-scroll-view.git#gb-v0.8.7",
"react-native-modal": "^6.5.0",
"react-native-recyclerview-list": "git+https://github.com/wordpress-mobile/react-native-recyclerview-list.git#v1.0.0",
"react-native-recyclerview-list": "git+https://github.com/wordpress-mobile/react-native-recyclerview-list.git#v1.0.1",
"react-native-safe-area": "^0.5.0",
"react-native-svg": "git+https://github.com/wordpress-mobile/react-native-svg.git#55244dc79ab876550599c82dca763c3eba0153c5",
"react-redux": "^5.0.7",
Expand Down
Loading