@wordpress/editor 11.0.1 → 12.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/README.md +1 -1
- package/build/components/autosave-monitor/index.js +5 -0
- package/build/components/autosave-monitor/index.js.map +1 -1
- package/build/components/character-count/index.js +1 -1
- package/build/components/character-count/index.js.map +1 -1
- package/build/components/editor-help/add-blocks.native.js +6 -5
- package/build/components/editor-help/add-blocks.native.js.map +1 -1
- package/build/components/editor-help/customize-blocks.native.js +7 -6
- package/build/components/editor-help/customize-blocks.native.js.map +1 -1
- package/build/components/editor-help/help-detail-navigation-screen.native.js +29 -15
- package/build/components/editor-help/help-detail-navigation-screen.native.js.map +1 -1
- package/build/components/editor-help/help-get-support-button.native.js +46 -0
- package/build/components/editor-help/help-get-support-button.native.js.map +1 -0
- package/build/components/editor-help/help-topic-row.native.js +3 -2
- package/build/components/editor-help/help-topic-row.native.js.map +1 -1
- package/build/components/editor-help/index.native.js +87 -26
- package/build/components/editor-help/index.native.js.map +1 -1
- package/build/components/editor-help/intro-to-blocks.native.js +19 -9
- package/build/components/editor-help/intro-to-blocks.native.js.map +1 -1
- package/build/components/editor-help/move-blocks.native.js +6 -5
- package/build/components/editor-help/move-blocks.native.js.map +1 -1
- package/build/components/editor-help/remove-blocks.native.js +6 -5
- package/build/components/editor-help/remove-blocks.native.js.map +1 -1
- package/build/components/editor-help/view-sections.native.js +23 -5
- package/build/components/editor-help/view-sections.native.js.map +1 -1
- package/build/components/entities-saved-states/entity-type-list.js +22 -13
- package/build/components/entities-saved-states/entity-type-list.js.map +1 -1
- package/build/components/entities-saved-states/index.js +23 -4
- package/build/components/entities-saved-states/index.js.map +1 -1
- package/build/components/global-keyboard-shortcuts/save-shortcut.js +12 -14
- package/build/components/global-keyboard-shortcuts/save-shortcut.js.map +1 -1
- package/build/components/global-keyboard-shortcuts/visual-editor-shortcuts.js +0 -4
- package/build/components/global-keyboard-shortcuts/visual-editor-shortcuts.js.map +1 -1
- package/build/components/index.js +9 -0
- package/build/components/index.js.map +1 -1
- package/build/components/local-autosave-monitor/index.js +1 -2
- package/build/components/local-autosave-monitor/index.js.map +1 -1
- package/build/components/post-format/index.js +3 -1
- package/build/components/post-format/index.js.map +1 -1
- package/build/components/post-locked-modal/index.js +1 -1
- package/build/components/post-locked-modal/index.js.map +1 -1
- package/build/components/post-saved-state/index.js +37 -46
- package/build/components/post-saved-state/index.js.map +1 -1
- package/build/components/post-taxonomies/flat-term-selector.js +154 -211
- package/build/components/post-taxonomies/flat-term-selector.js.map +1 -1
- package/build/components/post-title/index.js +53 -25
- package/build/components/post-title/index.js.map +1 -1
- package/build/components/provider/index.native.js +18 -7
- package/build/components/provider/index.native.js.map +1 -1
- package/build/components/provider/use-block-editor-settings.js +32 -5
- package/build/components/provider/use-block-editor-settings.js.map +1 -1
- package/build/components/word-count/index.js +1 -1
- package/build/components/word-count/index.js.map +1 -1
- package/build/store/actions.js +13 -38
- package/build/store/actions.js.map +1 -1
- package/build/store/defaults.js +7 -2
- package/build/store/defaults.js.map +1 -1
- package/build/store/selectors.js +4 -93
- package/build/store/selectors.js.map +1 -1
- package/build/store/utils/notice-builder.js +15 -18
- package/build/store/utils/notice-builder.js.map +1 -1
- package/build/{store/utils → utils}/get-template-part-icon.js +1 -1
- package/build/utils/get-template-part-icon.js.map +1 -0
- package/build/utils/index.js +8 -0
- package/build/utils/index.js.map +1 -1
- package/build-module/components/autosave-monitor/index.js +5 -0
- package/build-module/components/autosave-monitor/index.js.map +1 -1
- package/build-module/components/character-count/index.js +1 -1
- package/build-module/components/character-count/index.js.map +1 -1
- package/build-module/components/editor-help/add-blocks.native.js +7 -6
- package/build-module/components/editor-help/add-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/customize-blocks.native.js +8 -7
- package/build-module/components/editor-help/customize-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/help-detail-navigation-screen.native.js +31 -18
- package/build-module/components/editor-help/help-detail-navigation-screen.native.js.map +1 -1
- package/build-module/components/editor-help/help-get-support-button.native.js +34 -0
- package/build-module/components/editor-help/help-get-support-button.native.js.map +1 -0
- package/build-module/components/editor-help/help-topic-row.native.js +3 -2
- package/build-module/components/editor-help/help-topic-row.native.js.map +1 -1
- package/build-module/components/editor-help/index.native.js +81 -28
- package/build-module/components/editor-help/index.native.js.map +1 -1
- package/build-module/components/editor-help/intro-to-blocks.native.js +19 -10
- package/build-module/components/editor-help/intro-to-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/move-blocks.native.js +7 -6
- package/build-module/components/editor-help/move-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/remove-blocks.native.js +7 -6
- package/build-module/components/editor-help/remove-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/view-sections.native.js +22 -5
- package/build-module/components/editor-help/view-sections.native.js.map +1 -1
- package/build-module/components/entities-saved-states/entity-type-list.js +24 -13
- package/build-module/components/entities-saved-states/entity-type-list.js.map +1 -1
- package/build-module/components/entities-saved-states/index.js +23 -4
- package/build-module/components/entities-saved-states/index.js.map +1 -1
- package/build-module/components/global-keyboard-shortcuts/save-shortcut.js +12 -14
- package/build-module/components/global-keyboard-shortcuts/save-shortcut.js.map +1 -1
- package/build-module/components/global-keyboard-shortcuts/visual-editor-shortcuts.js +0 -4
- package/build-module/components/global-keyboard-shortcuts/visual-editor-shortcuts.js.map +1 -1
- package/build-module/components/index.js +1 -0
- package/build-module/components/index.js.map +1 -1
- package/build-module/components/local-autosave-monitor/index.js +1 -2
- package/build-module/components/local-autosave-monitor/index.js.map +1 -1
- package/build-module/components/post-format/index.js +4 -2
- package/build-module/components/post-format/index.js.map +1 -1
- package/build-module/components/post-locked-modal/index.js +1 -1
- package/build-module/components/post-locked-modal/index.js.map +1 -1
- package/build-module/components/post-saved-state/index.js +38 -46
- package/build-module/components/post-saved-state/index.js.map +1 -1
- package/build-module/components/post-taxonomies/flat-term-selector.js +156 -214
- package/build-module/components/post-taxonomies/flat-term-selector.js.map +1 -1
- package/build-module/components/post-title/index.js +53 -22
- package/build-module/components/post-title/index.js.map +1 -1
- package/build-module/components/provider/index.native.js +18 -7
- package/build-module/components/provider/index.native.js.map +1 -1
- package/build-module/components/provider/use-block-editor-settings.js +31 -5
- package/build-module/components/provider/use-block-editor-settings.js.map +1 -1
- package/build-module/components/word-count/index.js +1 -1
- package/build-module/components/word-count/index.js.map +1 -1
- package/build-module/store/actions.js +13 -36
- package/build-module/store/actions.js.map +1 -1
- package/build-module/store/defaults.js +7 -2
- package/build-module/store/defaults.js.map +1 -1
- package/build-module/store/selectors.js +3 -85
- package/build-module/store/selectors.js.map +1 -1
- package/build-module/store/utils/notice-builder.js +15 -18
- package/build-module/store/utils/notice-builder.js.map +1 -1
- package/build-module/{store/utils → utils}/get-template-part-icon.js +2 -2
- package/build-module/utils/get-template-part-icon.js.map +1 -0
- package/build-module/utils/index.js +1 -0
- package/build-module/utils/index.js.map +1 -1
- package/build-style/style-rtl.css +9 -60
- package/build-style/style.css +9 -60
- package/package.json +28 -28
- package/src/components/autosave-monitor/index.js +5 -0
- package/src/components/autosave-monitor/test/index.js +10 -4
- package/src/components/character-count/index.js +3 -2
- package/src/components/editor-help/add-blocks.native.js +17 -12
- package/src/components/editor-help/customize-blocks.native.js +16 -13
- package/src/components/editor-help/help-detail-navigation-screen.native.js +45 -15
- package/src/components/editor-help/help-get-support-button.native.js +38 -0
- package/src/components/editor-help/help-topic-row.native.js +2 -2
- package/src/components/editor-help/images/add-dark.png +0 -0
- package/src/components/editor-help/images/add-dark@2x.png +0 -0
- package/src/components/editor-help/images/add-dark@3x.png +0 -0
- package/src/components/editor-help/images/add-light.png +0 -0
- package/src/components/editor-help/images/add-light@2x.png +0 -0
- package/src/components/editor-help/images/add-light@3x.png +0 -0
- package/src/components/editor-help/images/block-layout-collage.png +0 -0
- package/src/components/editor-help/images/block-layout-collage@2x.png +0 -0
- package/src/components/editor-help/images/block-layout-collage@3x.png +0 -0
- package/src/components/editor-help/images/build-layouts-dark.png +0 -0
- package/src/components/editor-help/images/build-layouts-dark@2x.png +0 -0
- package/src/components/editor-help/images/build-layouts-dark@3x.png +0 -0
- package/src/components/editor-help/images/build-layouts-light.png +0 -0
- package/src/components/editor-help/images/build-layouts-light@2x.png +0 -0
- package/src/components/editor-help/images/build-layouts-light@3x.png +0 -0
- package/src/components/editor-help/images/edit-media-dark.png +0 -0
- package/src/components/editor-help/images/edit-media-dark@2x.png +0 -0
- package/src/components/editor-help/images/edit-media-dark@3x.png +0 -0
- package/src/components/editor-help/images/edit-media-light.png +0 -0
- package/src/components/editor-help/images/edit-media-light@2x.png +0 -0
- package/src/components/editor-help/images/edit-media-light@3x.png +0 -0
- package/src/components/editor-help/images/embed-media-dark.png +0 -0
- package/src/components/editor-help/images/embed-media-dark@2x.png +0 -0
- package/src/components/editor-help/images/embed-media-dark@3x.png +0 -0
- package/src/components/editor-help/images/embed-media-light.png +0 -0
- package/src/components/editor-help/images/embed-media-light@2x.png +0 -0
- package/src/components/editor-help/images/embed-media-light@3x.png +0 -0
- package/src/components/editor-help/images/move-dark.png +0 -0
- package/src/components/editor-help/images/move-dark@2x.png +0 -0
- package/src/components/editor-help/images/move-dark@3x.png +0 -0
- package/src/components/editor-help/images/move-light.png +0 -0
- package/src/components/editor-help/images/move-light@2x.png +0 -0
- package/src/components/editor-help/images/move-light@3x.png +0 -0
- package/src/components/editor-help/images/options-dark.png +0 -0
- package/src/components/editor-help/images/options-dark@2x.png +0 -0
- package/src/components/editor-help/images/options-dark@3x.png +0 -0
- package/src/components/editor-help/images/options-light.png +0 -0
- package/src/components/editor-help/images/options-light@2x.png +0 -0
- package/src/components/editor-help/images/options-light@3x.png +0 -0
- package/src/components/editor-help/images/rich-text-dark.png +0 -0
- package/src/components/editor-help/images/rich-text-dark@2x.png +0 -0
- package/src/components/editor-help/images/rich-text-dark@3x.png +0 -0
- package/src/components/editor-help/images/rich-text-light.png +0 -0
- package/src/components/editor-help/images/rich-text-light@2x.png +0 -0
- package/src/components/editor-help/images/rich-text-light@3x.png +0 -0
- package/src/components/editor-help/images/settings-dark.png +0 -0
- package/src/components/editor-help/images/settings-dark@2x.png +0 -0
- package/src/components/editor-help/images/settings-dark@3x.png +0 -0
- package/src/components/editor-help/images/settings-light.png +0 -0
- package/src/components/editor-help/images/settings-light@2x.png +0 -0
- package/src/components/editor-help/images/settings-light@3x.png +0 -0
- package/src/components/editor-help/index.native.js +147 -43
- package/src/components/editor-help/intro-to-blocks.native.js +63 -43
- package/src/components/editor-help/move-blocks.native.js +12 -7
- package/src/components/editor-help/remove-blocks.native.js +11 -8
- package/src/components/editor-help/style.android.scss +6 -0
- package/src/components/editor-help/style.ios.scss +6 -0
- package/src/components/editor-help/style.scss +49 -32
- package/src/components/editor-help/test/index.native.js +80 -0
- package/src/components/editor-help/view-sections.native.js +47 -4
- package/src/components/entities-saved-states/entity-type-list.js +29 -10
- package/src/components/entities-saved-states/index.js +38 -8
- package/src/components/global-keyboard-shortcuts/save-shortcut.js +34 -42
- package/src/components/global-keyboard-shortcuts/visual-editor-shortcuts.js +8 -16
- package/src/components/index.js +1 -0
- package/src/components/local-autosave-monitor/index.js +1 -3
- package/src/components/post-format/index.js +6 -2
- package/src/components/post-format/style.scss +1 -0
- package/src/components/post-locked-modal/index.js +1 -1
- package/src/components/post-saved-state/index.js +41 -55
- package/src/components/post-saved-state/style.scss +10 -1
- package/src/components/post-saved-state/test/__snapshots__/index.js.snap +20 -0
- package/src/components/post-saved-state/test/index.js +2 -2
- package/src/components/post-taxonomies/flat-term-selector.js +220 -254
- package/src/components/post-title/index.js +47 -30
- package/src/components/post-title/style.scss +1 -70
- package/src/components/provider/index.native.js +17 -5
- package/src/components/provider/use-block-editor-settings.js +25 -2
- package/src/components/word-count/index.js +3 -2
- package/src/store/actions.js +13 -41
- package/src/store/defaults.js +7 -2
- package/src/store/selectors.js +2 -112
- package/src/store/test/actions.js +4 -2
- package/src/store/utils/notice-builder.js +17 -19
- package/src/store/utils/test/notice-builder.js +1 -1
- package/src/{store/utils → utils}/get-template-part-icon.js +2 -2
- package/src/utils/index.js +1 -0
- package/build/store/utils/get-template-part-icon.js.map +0 -1
- package/build-module/store/utils/get-template-part-icon.js.map +0 -1
- package/src/components/editor-help/images/add-blocks.png +0 -0
- package/src/components/editor-help/images/customize-blocks.png +0 -0
- package/src/components/editor-help/images/cut-copy-duplicate-blocks.png +0 -0
- package/src/components/editor-help/images/edit-or-replace-media.png +0 -0
- package/src/components/editor-help/images/intro-blocks-1.png +0 -0
- package/src/components/editor-help/images/intro-blocks-2.png +0 -0
- package/src/components/editor-help/images/intro-blocks-3.png +0 -0
- package/src/components/editor-help/images/intro-blocks-4.png +0 -0
- package/src/components/editor-help/images/move-blocks.png +0 -0
- package/src/components/editor-help/images/remove-blocks.png +0 -0
- package/src/components/editor-help/images/what-is-a-block.png +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/character-count/index.js"],"names":["useSelect","count","characterCount","store","editorStore","CharacterCount","content","select","getEditedPostAttribute"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,SAAT,QAA0B,iBAA1B;AACA,SAASC,KAAK,IAAIC,cAAlB,QAAwC,sBAAxC;AAEA;AACA;AACA;;AACA,SAASC,KAAK,IAAIC,WAAlB,QAAqC,aAArC;AAEA,eAAe,SAASC,cAAT,GAA0B;AACxC,QAAMC,OAAO,GAAGN,SAAS,
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/character-count/index.js"],"names":["useSelect","count","characterCount","store","editorStore","CharacterCount","content","select","getEditedPostAttribute"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,SAAT,QAA0B,iBAA1B;AACA,SAASC,KAAK,IAAIC,cAAlB,QAAwC,sBAAxC;AAEA;AACA;AACA;;AACA,SAASC,KAAK,IAAIC,WAAlB,QAAqC,aAArC;AAEA,eAAe,SAASC,cAAT,GAA0B;AACxC,QAAMC,OAAO,GAAGN,SAAS,CACtBO,MAAF,IAAcA,MAAM,CAAEH,WAAF,CAAN,CAAsBI,sBAAtB,CAA8C,SAA9C,CADU,EAExB,EAFwB,CAAzB;AAKA,SAAON,cAAc,CAAEI,OAAF,EAAW,6BAAX,CAArB;AACA","sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { count as characterCount } from '@wordpress/wordcount';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\nexport default function CharacterCount() {\n\tconst content = useSelect(\n\t\t( select ) => select( editorStore ).getEditedPostAttribute( 'content' ),\n\t\t[]\n\t);\n\n\treturn characterCount( content, 'characters_including_spaces' );\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createElement } from "@wordpress/element";
|
|
1
|
+
import { createElement, Fragment } from "@wordpress/element";
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* External dependencies
|
|
@@ -17,15 +17,16 @@ import styles from './style.scss';
|
|
|
17
17
|
import { HelpDetailBodyText, HelpDetailImage } from './view-sections';
|
|
18
18
|
|
|
19
19
|
const AddBlocks = () => {
|
|
20
|
-
return createElement(
|
|
20
|
+
return createElement(Fragment, null, createElement(HelpDetailImage, {
|
|
21
|
+
source: require('./images/add-light.png'),
|
|
22
|
+
sourceDarkMode: require('./images/add-dark.png')
|
|
23
|
+
}), createElement(View, {
|
|
21
24
|
style: styles.helpDetailContainer
|
|
22
|
-
}, createElement(
|
|
23
|
-
source: require('./images/add-blocks.png')
|
|
24
|
-
}), createElement(HelpDetailBodyText, {
|
|
25
|
+
}, createElement(HelpDetailBodyText, {
|
|
25
26
|
text: __('Add a new block at any time by tapping on the + icon in the toolbar on the bottom left. ')
|
|
26
27
|
}), createElement(HelpDetailBodyText, {
|
|
27
28
|
text: __('Once you become familiar with the names of different blocks, you can add a block by typing a forward slash followed by the block name — for example, /image or /heading.')
|
|
28
|
-
}));
|
|
29
|
+
})));
|
|
29
30
|
};
|
|
30
31
|
|
|
31
32
|
export default AddBlocks;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/add-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","AddBlocks","
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/add-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","AddBlocks","require","helpDetailContainer"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,cAArB;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,SAASC,kBAAT,EAA6BC,eAA7B,QAAoD,iBAApD;;AAEA,MAAMC,SAAS,GAAG,MAAM;AACvB,SACC,8BACC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGC,OAAO,CAAE,wBAAF,CADjB;AAEC,IAAA,cAAc,EAAGA,OAAO,CAAE,uBAAF;AAFzB,IADD,EAKC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGJ,MAAM,CAACK;AAArB,KACC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGN,EAAE,CACR,0FADQ;AADV,IADD,EAMC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,0KADQ;AADV,IAND,CALD,CADD;AAoBA,CArBD;;AAuBA,eAAeI,SAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport { HelpDetailBodyText, HelpDetailImage } from './view-sections';\n\nconst AddBlocks = () => {\n\treturn (\n\t\t<>\n\t\t\t<HelpDetailImage\n\t\t\t\tsource={ require( './images/add-light.png' ) }\n\t\t\t\tsourceDarkMode={ require( './images/add-dark.png' ) }\n\t\t\t/>\n\t\t\t<View style={ styles.helpDetailContainer }>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Add a new block at any time by tapping on the + icon in the toolbar on the bottom left. '\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Once you become familiar with the names of different blocks, you can add a block by typing a forward slash followed by the block name — for example, /image or /heading.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t</View>\n\t\t</>\n\t);\n};\n\nexport default AddBlocks;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createElement } from "@wordpress/element";
|
|
1
|
+
import { createElement, Fragment } from "@wordpress/element";
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* External dependencies
|
|
@@ -17,15 +17,16 @@ import styles from './style.scss';
|
|
|
17
17
|
import { HelpDetailBodyText, HelpDetailImage } from './view-sections';
|
|
18
18
|
|
|
19
19
|
const CustomizeBlocks = () => {
|
|
20
|
-
return createElement(
|
|
20
|
+
return createElement(Fragment, null, createElement(HelpDetailImage, {
|
|
21
|
+
source: require('./images/settings-light.png'),
|
|
22
|
+
sourceDarkMode: require('./images/settings-dark.png')
|
|
23
|
+
}), createElement(View, {
|
|
21
24
|
style: styles.helpDetailContainer
|
|
22
|
-
}, createElement(
|
|
23
|
-
|
|
24
|
-
}), createElement(HelpDetailBodyText, {
|
|
25
|
-
text: __('Each block has its own settings. To find them, click on a block. Its settings will appear on the toolbar at the bottom of the screen.')
|
|
25
|
+
}, createElement(HelpDetailBodyText, {
|
|
26
|
+
text: __('Each block has its own settings. To find them, tap on a block. Its settings will appear on the toolbar at the bottom of the screen.')
|
|
26
27
|
}), createElement(HelpDetailBodyText, {
|
|
27
28
|
text: __('Some blocks have additional settings. Tap the settings icon on the bottom right of the block to view more options.')
|
|
28
|
-
}));
|
|
29
|
+
})));
|
|
29
30
|
};
|
|
30
31
|
|
|
31
32
|
export default CustomizeBlocks;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/customize-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","CustomizeBlocks","
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/customize-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","CustomizeBlocks","require","helpDetailContainer"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,cAArB;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,SAASC,kBAAT,EAA6BC,eAA7B,QAAoD,iBAApD;;AAEA,MAAMC,eAAe,GAAG,MAAM;AAC7B,SACC,8BACC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGC,OAAO,CAAE,6BAAF,CADjB;AAEC,IAAA,cAAc,EAAGA,OAAO,CAAE,4BAAF;AAFzB,IADD,EAKC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGJ,MAAM,CAACK;AAArB,KACC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGN,EAAE,CACR,qIADQ;AADV,IADD,EAMC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,oHADQ;AADV,IAND,CALD,CADD;AAoBA,CArBD;;AAuBA,eAAeI,eAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport { HelpDetailBodyText, HelpDetailImage } from './view-sections';\n\nconst CustomizeBlocks = () => {\n\treturn (\n\t\t<>\n\t\t\t<HelpDetailImage\n\t\t\t\tsource={ require( './images/settings-light.png' ) }\n\t\t\t\tsourceDarkMode={ require( './images/settings-dark.png' ) }\n\t\t\t/>\n\t\t\t<View style={ styles.helpDetailContainer }>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Each block has its own settings. To find them, tap on a block. Its settings will appear on the toolbar at the bottom of the screen.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Some blocks have additional settings. Tap the settings icon on the bottom right of the block to view more options.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t</View>\n\t\t</>\n\t);\n};\n\nexport default CustomizeBlocks;\n"]}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import { createElement } from "@wordpress/element";
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* External dependencies
|
|
5
6
|
*/
|
|
6
|
-
import { View } from 'react-native';
|
|
7
|
+
import { ScrollView, StyleSheet, TouchableWithoutFeedback, View } from 'react-native';
|
|
8
|
+
import { useNavigation } from '@react-navigation/native';
|
|
7
9
|
/**
|
|
8
10
|
* WordPress dependencies
|
|
9
11
|
*/
|
|
10
12
|
|
|
11
|
-
import { BottomSheet } from '@wordpress/components';
|
|
12
|
-
import {
|
|
13
|
-
import { __ } from '@wordpress/i18n';
|
|
13
|
+
import { BottomSheet, BottomSheetContext } from '@wordpress/components';
|
|
14
|
+
import { useContext } from '@wordpress/element';
|
|
14
15
|
/**
|
|
15
16
|
* Internal dependencies
|
|
16
17
|
*/
|
|
@@ -18,23 +19,35 @@ import { __ } from '@wordpress/i18n';
|
|
|
18
19
|
import styles from './style.scss';
|
|
19
20
|
|
|
20
21
|
const HelpDetailNavigationScreen = ({
|
|
21
|
-
|
|
22
|
-
|
|
22
|
+
content,
|
|
23
|
+
label
|
|
23
24
|
}) => {
|
|
24
25
|
const navigation = useNavigation();
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
const {
|
|
27
|
+
listProps
|
|
28
|
+
} = useContext(BottomSheetContext);
|
|
29
|
+
const contentContainerStyle = StyleSheet.flatten(listProps.contentContainerStyle);
|
|
30
30
|
return createElement(BottomSheet.NavigationScreen, {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
}),
|
|
31
|
+
isScrollable: true,
|
|
32
|
+
fullScreen: true
|
|
33
|
+
}, createElement(View, {
|
|
34
|
+
style: styles.container
|
|
35
|
+
}, createElement(BottomSheet.NavBar, null, createElement(BottomSheet.NavBar.BackButton, {
|
|
36
|
+
onPress: navigation.goBack
|
|
37
|
+
}), createElement(BottomSheet.NavBar.Heading, null, label)), createElement(ScrollView, _extends({}, listProps, {
|
|
38
|
+
contentContainerStyle: { ...contentContainerStyle,
|
|
39
|
+
paddingBottom: Math.max(listProps.safeAreaBottomInset, contentContainerStyle.paddingBottom),
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Remove margin set via `hideHeader`. Combining a header
|
|
43
|
+
* and navigation in this bottom sheet is at odds with the
|
|
44
|
+
* current `BottomSheet` implementation.
|
|
45
|
+
*/
|
|
46
|
+
marginTop: 0
|
|
47
|
+
}
|
|
48
|
+
}), createElement(TouchableWithoutFeedback, {
|
|
49
|
+
accessible: false
|
|
50
|
+
}, createElement(View, null, content)))));
|
|
38
51
|
};
|
|
39
52
|
|
|
40
53
|
export default HelpDetailNavigationScreen;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/help-detail-navigation-screen.native.js"],"names":["View","BottomSheet","
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/help-detail-navigation-screen.native.js"],"names":["ScrollView","StyleSheet","TouchableWithoutFeedback","View","useNavigation","BottomSheet","BottomSheetContext","useContext","styles","HelpDetailNavigationScreen","content","label","navigation","listProps","contentContainerStyle","flatten","container","goBack","paddingBottom","Math","max","safeAreaBottomInset","marginTop"],"mappings":";;;AAAA;AACA;AACA;AACA,SACC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AeD,0BAAf","sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tScrollView,\n\tStyleSheet,\n\tTouchableWithoutFeedback,\n\tView,\n} from 'react-native';\nimport { useNavigation } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { BottomSheet, BottomSheetContext } from '@wordpress/components';\nimport { useContext } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\n\nconst HelpDetailNavigationScreen = ( { content, label } ) => {\n\tconst navigation = useNavigation();\n\n\tconst { listProps } = useContext( BottomSheetContext );\n\tconst contentContainerStyle = StyleSheet.flatten(\n\t\tlistProps.contentContainerStyle\n\t);\n\n\treturn (\n\t\t<BottomSheet.NavigationScreen isScrollable fullScreen>\n\t\t\t<View style={ styles.container }>\n\t\t\t\t<BottomSheet.NavBar>\n\t\t\t\t\t<BottomSheet.NavBar.BackButton\n\t\t\t\t\t\tonPress={ navigation.goBack }\n\t\t\t\t\t/>\n\t\t\t\t\t<BottomSheet.NavBar.Heading>\n\t\t\t\t\t\t{ label }\n\t\t\t\t\t</BottomSheet.NavBar.Heading>\n\t\t\t\t</BottomSheet.NavBar>\n\t\t\t\t<ScrollView\n\t\t\t\t\t{ ...listProps }\n\t\t\t\t\tcontentContainerStyle={ {\n\t\t\t\t\t\t...contentContainerStyle,\n\t\t\t\t\t\tpaddingBottom: Math.max(\n\t\t\t\t\t\t\tlistProps.safeAreaBottomInset,\n\t\t\t\t\t\t\tcontentContainerStyle.paddingBottom\n\t\t\t\t\t\t),\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * Remove margin set via `hideHeader`. Combining a header\n\t\t\t\t\t\t * and navigation in this bottom sheet is at odds with the\n\t\t\t\t\t\t * current `BottomSheet` implementation.\n\t\t\t\t\t\t */\n\t\t\t\t\t\tmarginTop: 0,\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<TouchableWithoutFeedback accessible={ false }>\n\t\t\t\t\t\t<View>{ content }</View>\n\t\t\t\t\t</TouchableWithoutFeedback>\n\t\t\t\t</ScrollView>\n\t\t\t</View>\n\t\t</BottomSheet.NavigationScreen>\n\t);\n};\n\nexport default HelpDetailNavigationScreen;\n"]}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { createElement } from "@wordpress/element";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* External dependencies
|
|
5
|
+
*/
|
|
6
|
+
import { Pressable, Text } from 'react-native';
|
|
7
|
+
/**
|
|
8
|
+
* WordPress dependencies
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
import { usePreferredColorSchemeStyle } from '@wordpress/compose';
|
|
12
|
+
/**
|
|
13
|
+
* Internal dependencies
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
import styles from './style.scss';
|
|
17
|
+
|
|
18
|
+
const HelpGetSupportButton = ({
|
|
19
|
+
onPress,
|
|
20
|
+
title
|
|
21
|
+
}) => {
|
|
22
|
+
const buttonStyle = usePreferredColorSchemeStyle(styles.button, styles.buttonDark);
|
|
23
|
+
const textStyle = usePreferredColorSchemeStyle(styles.buttonText, styles.buttonTextDark);
|
|
24
|
+
return createElement(Pressable, {
|
|
25
|
+
style: buttonStyle,
|
|
26
|
+
onPress: onPress,
|
|
27
|
+
accessibilityRole: 'button'
|
|
28
|
+
}, createElement(Text, {
|
|
29
|
+
style: textStyle
|
|
30
|
+
}, title));
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
export default HelpGetSupportButton;
|
|
34
|
+
//# sourceMappingURL=help-get-support-button.native.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/help-get-support-button.native.js"],"names":["Pressable","Text","usePreferredColorSchemeStyle","styles","HelpGetSupportButton","onPress","title","buttonStyle","button","buttonDark","textStyle","buttonText","buttonTextDark"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,SAAT,EAAoBC,IAApB,QAAgC,cAAhC;AAEA;AACA;AACA;;AACA,SAASC,4BAAT,QAA6C,oBAA7C;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;;AAEA,MAAMC,oBAAoB,GAAG,CAAE;AAAEC,EAAAA,OAAF;AAAWC,EAAAA;AAAX,CAAF,KAA0B;AACtD,QAAMC,WAAW,GAAGL,4BAA4B,CAC/CC,MAAM,CAACK,MADwC,EAE/CL,MAAM,CAACM,UAFwC,CAAhD;AAKA,QAAMC,SAAS,GAAGR,4BAA4B,CAC7CC,MAAM,CAACQ,UADsC,EAE7CR,MAAM,CAACS,cAFsC,CAA9C;AAKA,SACC,cAAC,SAAD;AACC,IAAA,KAAK,EAAGL,WADT;AAEC,IAAA,OAAO,EAAGF,OAFX;AAGC,IAAA,iBAAiB,EAAG;AAHrB,KAKC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGK;AAAd,KAA4BJ,KAA5B,CALD,CADD;AASA,CApBD;;AAsBA,eAAeF,oBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { Pressable, Text } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\n\nconst HelpGetSupportButton = ( { onPress, title } ) => {\n\tconst buttonStyle = usePreferredColorSchemeStyle(\n\t\tstyles.button,\n\t\tstyles.buttonDark\n\t);\n\n\tconst textStyle = usePreferredColorSchemeStyle(\n\t\tstyles.buttonText,\n\t\tstyles.buttonTextDark\n\t);\n\n\treturn (\n\t\t<Pressable\n\t\t\tstyle={ buttonStyle }\n\t\t\tonPress={ onPress }\n\t\t\taccessibilityRole={ 'button' }\n\t\t>\n\t\t\t<Text style={ textStyle }>{ title }</Text>\n\t\t</Pressable>\n\t);\n};\n\nexport default HelpGetSupportButton;\n"]}
|
|
@@ -13,12 +13,13 @@ import { chevronRight } from '@wordpress/icons';
|
|
|
13
13
|
|
|
14
14
|
const HelpTopicRow = ({
|
|
15
15
|
label,
|
|
16
|
-
icon
|
|
16
|
+
icon,
|
|
17
|
+
screenName
|
|
17
18
|
}) => {
|
|
18
19
|
const navigation = useNavigation();
|
|
19
20
|
|
|
20
21
|
const openSubSheet = () => {
|
|
21
|
-
navigation.navigate(
|
|
22
|
+
navigation.navigate(screenName);
|
|
22
23
|
};
|
|
23
24
|
|
|
24
25
|
return createElement(TextControl, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/help-topic-row.native.js"],"names":["useNavigation","TextControl","Icon","chevronRight","HelpTopicRow","label","icon","navigation","openSubSheet","navigate"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,aAAT,QAA8B,0BAA9B;AAEA;AACA;AACA;;AACA,SAASC,WAAT,EAAsBC,IAAtB,QAAkC,uBAAlC;AACA,SAASC,YAAT,QAA6B,kBAA7B;;AAEA,MAAMC,YAAY,GAAG,CAAE;AAAEC,EAAAA,KAAF;AAASC,EAAAA;
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/help-topic-row.native.js"],"names":["useNavigation","TextControl","Icon","chevronRight","HelpTopicRow","label","icon","screenName","navigation","openSubSheet","navigate"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,aAAT,QAA8B,0BAA9B;AAEA;AACA;AACA;;AACA,SAASC,WAAT,EAAsBC,IAAtB,QAAkC,uBAAlC;AACA,SAASC,YAAT,QAA6B,kBAA7B;;AAEA,MAAMC,YAAY,GAAG,CAAE;AAAEC,EAAAA,KAAF;AAASC,EAAAA,IAAT;AAAeC,EAAAA;AAAf,CAAF,KAAmC;AACvD,QAAMC,UAAU,GAAGR,aAAa,EAAhC;;AAEA,QAAMS,YAAY,GAAG,MAAM;AAC1BD,IAAAA,UAAU,CAACE,QAAX,CAAqBH,UAArB;AACA,GAFD;;AAIA,SACC,cAAC,WAAD;AACC,IAAA,aAAa,EAAC,YADf;AAEC,IAAA,kBAAkB,MAFnB;AAGC,IAAA,SAAS,MAHV;AAIC,IAAA,OAAO,EAAGE,YAJX;AAKC,IAAA,KAAK,EAAGJ,KALT;AAMC,IAAA,IAAI,EAAGC;AANR,KAQC,cAAC,IAAD;AAAM,IAAA,IAAI,EAAGH;AAAb,IARD,CADD;AAYA,CAnBD;;AAqBA,eAAeC,YAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { useNavigation } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { TextControl, Icon } from '@wordpress/components';\nimport { chevronRight } from '@wordpress/icons';\n\nconst HelpTopicRow = ( { label, icon, screenName } ) => {\n\tconst navigation = useNavigation();\n\n\tconst openSubSheet = () => {\n\t\tnavigation.navigate( screenName );\n\t};\n\n\treturn (\n\t\t<TextControl\n\t\t\tseparatorType=\"leftMargin\"\n\t\t\tcustomActionButton\n\t\t\tleftAlign\n\t\t\tonPress={ openSubSheet }\n\t\t\tlabel={ label }\n\t\t\ticon={ icon }\n\t\t>\n\t\t\t<Icon icon={ chevronRight } />\n\t\t</TextControl>\n\t);\n};\n\nexport default HelpTopicRow;\n"]}
|
|
@@ -1,17 +1,23 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import { createElement } from "@wordpress/element";
|
|
2
3
|
|
|
3
4
|
/**
|
|
4
5
|
* External dependencies
|
|
5
6
|
*/
|
|
6
|
-
import {
|
|
7
|
+
import { kebabCase } from 'lodash';
|
|
8
|
+
import { Text, SafeAreaView, ScrollView, StyleSheet, View } from 'react-native';
|
|
9
|
+
import { TransitionPresets } from '@react-navigation/stack';
|
|
7
10
|
/**
|
|
8
11
|
* WordPress dependencies
|
|
9
12
|
*/
|
|
10
13
|
|
|
11
|
-
import { BottomSheet, PanelBody } from '@wordpress/components';
|
|
14
|
+
import { BottomSheet, BottomSheetConsumer, PanelBody } from '@wordpress/components';
|
|
12
15
|
import { __ } from '@wordpress/i18n';
|
|
13
|
-
import { usePreferredColorSchemeStyle } from '@wordpress/compose';
|
|
14
16
|
import { helpFilled, plusCircleFilled, alignJustifyAlt, trashFilled, cogAlt } from '@wordpress/icons';
|
|
17
|
+
import { useSelect } from '@wordpress/data';
|
|
18
|
+
import { store as editorStore } from '@wordpress/editor';
|
|
19
|
+
import { usePreferredColorSchemeStyle } from '@wordpress/compose';
|
|
20
|
+
import { requestContactCustomerSupport, requestGotoCustomerSupportOptions } from '@wordpress/react-native-bridge';
|
|
15
21
|
/**
|
|
16
22
|
* Internal dependencies
|
|
17
23
|
*/
|
|
@@ -19,6 +25,7 @@ import { helpFilled, plusCircleFilled, alignJustifyAlt, trashFilled, cogAlt } fr
|
|
|
19
25
|
import styles from './style.scss';
|
|
20
26
|
import HelpDetailNavigationScreen from './help-detail-navigation-screen';
|
|
21
27
|
import HelpTopicRow from './help-topic-row';
|
|
28
|
+
import HelpGetSupportButton from './help-get-support-button';
|
|
22
29
|
import IntroToBlocks from './intro-to-blocks';
|
|
23
30
|
import AddBlocks from './add-blocks';
|
|
24
31
|
import MoveBlocks from './move-blocks';
|
|
@@ -47,44 +54,90 @@ const HELP_TOPICS = [{
|
|
|
47
54
|
}];
|
|
48
55
|
|
|
49
56
|
function EditorHelpTopics({
|
|
57
|
+
close,
|
|
50
58
|
isVisible,
|
|
51
59
|
onClose
|
|
52
60
|
}) {
|
|
53
|
-
const
|
|
61
|
+
const {
|
|
62
|
+
postType
|
|
63
|
+
} = useSelect(select => ({
|
|
64
|
+
postType: select(editorStore).getEditedPostAttribute('type')
|
|
65
|
+
}));
|
|
66
|
+
const sectionTitle = usePreferredColorSchemeStyle(styles.helpDetailSectionHeading, styles.helpDetailSectionHeadingDark);
|
|
67
|
+
const title = postType === 'page' ? __('How to edit your page') : __('How to edit your post');
|
|
54
68
|
return createElement(BottomSheet, {
|
|
55
69
|
isVisible: isVisible,
|
|
56
70
|
onClose: onClose,
|
|
57
71
|
hideHeader: true,
|
|
58
72
|
hasNavigation: true,
|
|
59
|
-
contentStyle: styles.contentContainer
|
|
60
|
-
|
|
73
|
+
contentStyle: styles.contentContainer,
|
|
74
|
+
testID: "editor-help-modal"
|
|
75
|
+
}, createElement(SafeAreaView, null, createElement(BottomSheet.NavigationContainer, {
|
|
61
76
|
animate: true,
|
|
62
|
-
main: true
|
|
77
|
+
main: true,
|
|
78
|
+
style: styles.navigationContainer
|
|
63
79
|
}, createElement(BottomSheet.NavigationScreen, {
|
|
64
|
-
|
|
80
|
+
isScrollable: true,
|
|
81
|
+
fullScreen: true,
|
|
82
|
+
name: "help-topics"
|
|
65
83
|
}, createElement(View, {
|
|
66
|
-
style: styles.
|
|
67
|
-
}, createElement(
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
},
|
|
71
|
-
|
|
72
|
-
})
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
84
|
+
style: styles.container
|
|
85
|
+
}, createElement(BottomSheet.NavBar, null, createElement(BottomSheet.NavBar.DismissButton, {
|
|
86
|
+
onPress: close,
|
|
87
|
+
iosText: __('Close')
|
|
88
|
+
}), createElement(BottomSheet.NavBar.Heading, null, title)), createElement(BottomSheetConsumer, null, ({
|
|
89
|
+
listProps
|
|
90
|
+
}) => {
|
|
91
|
+
const contentContainerStyle = StyleSheet.flatten(listProps.contentContainerStyle);
|
|
92
|
+
return createElement(ScrollView, _extends({}, listProps, {
|
|
93
|
+
contentContainerStyle: { ...contentContainerStyle,
|
|
94
|
+
paddingBottom: Math.max(listProps.safeAreaBottomInset, contentContainerStyle.paddingBottom),
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Remove margin set via `hideHeader`. Combining a header
|
|
98
|
+
* and navigation in this bottom sheet is at odds with the
|
|
99
|
+
* current `BottomSheet` implementation.
|
|
100
|
+
*/
|
|
101
|
+
marginTop: 0
|
|
102
|
+
}
|
|
103
|
+
}), createElement(PanelBody, null, createElement(Text, {
|
|
104
|
+
style: sectionTitle
|
|
105
|
+
}, __('The basics')), HELP_TOPICS.map(({
|
|
106
|
+
label,
|
|
107
|
+
icon
|
|
108
|
+
}) => {
|
|
109
|
+
const labelSlug = kebabCase(label);
|
|
110
|
+
return createElement(HelpTopicRow, {
|
|
111
|
+
key: labelSlug,
|
|
112
|
+
label: label,
|
|
113
|
+
icon: icon,
|
|
114
|
+
screenName: labelSlug
|
|
115
|
+
});
|
|
116
|
+
}), createElement(Text, {
|
|
117
|
+
style: sectionTitle
|
|
118
|
+
}, __('Get support')), createElement(HelpGetSupportButton, {
|
|
119
|
+
title: __('Contact support'),
|
|
120
|
+
onPress: requestContactCustomerSupport
|
|
121
|
+
}), createElement(HelpGetSupportButton, {
|
|
122
|
+
title: __('More support options'),
|
|
123
|
+
onPress: requestGotoCustomerSupportOptions
|
|
124
|
+
})));
|
|
125
|
+
}))), HELP_TOPICS.map(({
|
|
126
|
+
view,
|
|
127
|
+
label
|
|
128
|
+
}) => {
|
|
129
|
+
const labelSlug = kebabCase(label);
|
|
82
130
|
return createElement(HelpDetailNavigationScreen, {
|
|
83
|
-
key:
|
|
84
|
-
name:
|
|
85
|
-
content:
|
|
131
|
+
key: labelSlug,
|
|
132
|
+
name: labelSlug,
|
|
133
|
+
content: view,
|
|
134
|
+
label: label,
|
|
135
|
+
options: {
|
|
136
|
+
gestureEnabled: true,
|
|
137
|
+
...TransitionPresets.DefaultTransition
|
|
138
|
+
}
|
|
86
139
|
});
|
|
87
|
-
})));
|
|
140
|
+
}))));
|
|
88
141
|
}
|
|
89
142
|
|
|
90
143
|
export default EditorHelpTopics;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/index.native.js"],"names":["View","Text","BottomSheet","PanelBody","__","usePreferredColorSchemeStyle","helpFilled","plusCircleFilled","alignJustifyAlt","trashFilled","cogAlt","styles","HelpDetailNavigationScreen","HelpTopicRow","IntroToBlocks","AddBlocks","MoveBlocks","RemoveBlocks","CustomizeBlocks","HELP_TOPICS","label","icon","view","EditorHelpTopics","isVisible","onClose","bottomSheetHeaderTitleStyle","bottomSheetHeaderTitle","bottomSheetHeaderTitleDark","contentContainer","bottomSheetHeader","separator","sectionContainer","map","topic"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,IAAT,EAAeC,IAAf,QAA2B,cAA3B;AAEA;AACA;AACA;;AACA,SAASC,WAAT,EAAsBC,SAAtB,QAAuC,uBAAvC;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,4BAAT,QAA6C,oBAA7C;AACA,SACCC,UADD,EAECC,gBAFD,EAGCC,eAHD,EAICC,WAJD,EAKCC,MALD,QAMO,kBANP;AAQA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,OAAOC,0BAAP,MAAuC,iCAAvC;AACA,OAAOC,YAAP,MAAyB,kBAAzB;AACA,OAAOC,aAAP,MAA0B,mBAA1B;AACA,OAAOC,SAAP,MAAsB,cAAtB;AACA,OAAOC,UAAP,MAAuB,eAAvB;AACA,OAAOC,YAAP,MAAyB,iBAAzB;AACA,OAAOC,eAAP,MAA4B,oBAA5B;AAEA,MAAMC,WAAW,GAAG,CACnB;AACCC,EAAAA,KAAK,EAAEhB,EAAE,CAAE,kBAAF,CADV;AAECiB,EAAAA,IAAI,EAAEf,UAFP;AAGCgB,EAAAA,IAAI,EAAE,cAAC,aAAD;AAHP,CADmB,EAMnB;AACCF,EAAAA,KAAK,EAAEhB,EAAE,CAAE,YAAF,CADV;AAECiB,EAAAA,IAAI,EAAEd,gBAFP;AAGCe,EAAAA,IAAI,EAAE,cAAC,SAAD;AAHP,CANmB,EAWnB;AAAEF,EAAAA,KAAK,EAAEhB,EAAE,CAAE,aAAF,CAAX;AAA8BiB,EAAAA,IAAI,EAAEb,eAApC;AAAqDc,EAAAA,IAAI,EAAE,cAAC,UAAD;AAA3D,CAXmB,EAYnB;AAAEF,EAAAA,KAAK,EAAEhB,EAAE,CAAE,eAAF,CAAX;AAAgCiB,EAAAA,IAAI,EAAEZ,WAAtC;AAAmDa,EAA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,CAACd,KAFf;AAGC,MAAA,IAAI,EAAGc,KAAK,CAACb;AAHd,MADD;AAOA,GARC,CALH,CAVD,CADD,EA4BGF,WAAW,CAACc,GAAZ,CAAmBC,KAAF,IAAa;AAC/B,WACC,cAAC,0BAAD;AACC,MAAA,GAAG,EAAGA,KAAK,CAACd,KADb;AAEC,MAAA,IAAI,EAAGc,KAAK,CAACd,KAFd;AAGC,MAAA,OAAO,EAAGc,KAAK,CAACZ;AAHjB,MADD;AAOA,GARC,CA5BH,CAPD,CADD;AAgDA;;AAED,eAAeC,gBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View, Text } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { BottomSheet, PanelBody } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\nimport {\n\thelpFilled,\n\tplusCircleFilled,\n\talignJustifyAlt,\n\ttrashFilled,\n\tcogAlt,\n} from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport HelpDetailNavigationScreen from './help-detail-navigation-screen';\nimport HelpTopicRow from './help-topic-row';\nimport IntroToBlocks from './intro-to-blocks';\nimport AddBlocks from './add-blocks';\nimport MoveBlocks from './move-blocks';\nimport RemoveBlocks from './remove-blocks';\nimport CustomizeBlocks from './customize-blocks';\n\nconst HELP_TOPICS = [\n\t{\n\t\tlabel: __( 'What is a block?' ),\n\t\ticon: helpFilled,\n\t\tview: <IntroToBlocks />,\n\t},\n\t{\n\t\tlabel: __( 'Add blocks' ),\n\t\ticon: plusCircleFilled,\n\t\tview: <AddBlocks />,\n\t},\n\t{ label: __( 'Move blocks' ), icon: alignJustifyAlt, view: <MoveBlocks /> },\n\t{ label: __( 'Remove blocks' ), icon: trashFilled, view: <RemoveBlocks /> },\n\t{\n\t\tlabel: __( 'Customize blocks' ),\n\t\ticon: cogAlt,\n\t\tview: <CustomizeBlocks />,\n\t},\n];\n\nfunction EditorHelpTopics( { isVisible, onClose } ) {\n\tconst bottomSheetHeaderTitleStyle = usePreferredColorSchemeStyle(\n\t\tstyles.bottomSheetHeaderTitle,\n\t\tstyles.bottomSheetHeaderTitleDark\n\t);\n\n\treturn (\n\t\t<BottomSheet\n\t\t\tisVisible={ isVisible }\n\t\t\tonClose={ onClose }\n\t\t\thideHeader\n\t\t\thasNavigation\n\t\t\tcontentStyle={ styles.contentContainer }\n\t\t>\n\t\t\t<BottomSheet.NavigationContainer animate main>\n\t\t\t\t<BottomSheet.NavigationScreen name={ __( 'Topics' ) }>\n\t\t\t\t\t<View style={ styles.bottomSheetHeader }>\n\t\t\t\t\t\t<Text\n\t\t\t\t\t\t\tstyle={ bottomSheetHeaderTitleStyle }\n\t\t\t\t\t\t\tmaxFontSizeMultiplier={ 3 }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ __( 'How to edit your site' ) }\n\t\t\t\t\t\t</Text>\n\t\t\t\t\t</View>\n\t\t\t\t\t<View style={ styles.separator } />\n\t\t\t\t\t<PanelBody\n\t\t\t\t\t\ttitle={ __( 'The basics' ) }\n\t\t\t\t\t\tstyle={ styles.sectionContainer }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ /* Print out help topics */ }\n\t\t\t\t\t\t{ HELP_TOPICS.map( ( topic ) => {\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<HelpTopicRow\n\t\t\t\t\t\t\t\t\tkey={ topic.label }\n\t\t\t\t\t\t\t\t\tlabel={ topic.label }\n\t\t\t\t\t\t\t\t\ticon={ topic.icon }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t} ) }\n\t\t\t\t\t</PanelBody>\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t{ /* Print out help detail screens */ }\n\t\t\t\t{ HELP_TOPICS.map( ( topic ) => {\n\t\t\t\t\treturn (\n\t\t\t\t\t\t<HelpDetailNavigationScreen\n\t\t\t\t\t\t\tkey={ topic.label }\n\t\t\t\t\t\t\tname={ topic.label }\n\t\t\t\t\t\t\tcontent={ topic.view }\n\t\t\t\t\t\t/>\n\t\t\t\t\t);\n\t\t\t\t} ) }\n\t\t\t</BottomSheet.NavigationContainer>\n\t\t</BottomSheet>\n\t);\n}\n\nexport default EditorHelpTopics;\n"]}
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/index.native.js"],"names":["kebabCase","Text","SafeAreaView","ScrollView","StyleSheet","View","TransitionPresets","BottomSheet","BottomSheetConsumer","PanelBody","__","helpFilled","plusCircleFilled","alignJustifyAlt","trashFilled","cogAlt","useSelect","store","editorStore","usePreferredColorSchemeStyle","requestContactCustomerSupport","requestGotoCustomerSupportOptions","styles","HelpDetailNavigationScreen","HelpTopicRow","HelpGetSupportButton","IntroToBlocks","AddBlocks","MoveBlocks","RemoveBlocks","CustomizeBlocks","HELP_TOPICS","label","icon","view","EditorHelpTopics","close","isVisible","onClose","postType","select","getEditedPostAttribute","sectionTitle","helpDetailSectionHeading","helpDetailSectionHeadingDark","title","contentContainer","navigationContainer","container","listProps","contentContainerStyle","flatten","paddingBottom","Math","max","safeAreaBottomInset","marginTop","map","labelSlug","gestureEnabled","DefaultTransition"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,SAAT,QAA0B,QAA1B;AACA,SAASC,IAAT,EAAeC,YAAf,EAA6BC,UAA7B,EAAyCC,UAAzC,EAAqDC,IAArD,QAAiE,cAAjE;AACA,SAASC,iBAAT,QAAkC,yBAAlC;AAEA;AACA;AACA;;AACA,SACCC,WADD,EAECC,mBAFD,EAGCC,SAHD,QAIO,uBAJP;AAKA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SACCC,UADD,EAECC,gBAFD,EAGCC,eAHD,EAICC,WAJD,EAKCC,MALD,QAMO,kBANP;AAOA,SAASC,SAAT,QAA0B,iBAA1B;AACA,SAASC,KAAK,IAAIC,WAAlB,QAAqC,mBAArC;AACA,SAASC,4BAAT,QAA6C,oBAA7C;AACA,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ACC,cAAC,0BAAD;AACC,MAAA,GAAG,EAAG0B,SADP;AAEC,MAAA,IAAI,EAAGA,SAFR;AAGC,MAAA,OAAO,EAAGxB,IAHX;AAIC,MAAA,KAAK,EAAGF,KAJT;AAKC,MAAA,OAAO,EAAG;AACT2B,QAAAA,cAAc,EAAE,IADP;AAET,WAAGrD,iBAAiB,CAACsD;AAFZ;AALX,MADD;AAYA,GAdC,CArGH,CADD,CARD,CADD;AAkIA;;AAED,eAAezB,gBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { kebabCase } from 'lodash';\nimport { Text, SafeAreaView, ScrollView, StyleSheet, View } from 'react-native';\nimport { TransitionPresets } from '@react-navigation/stack';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tBottomSheet,\n\tBottomSheetConsumer,\n\tPanelBody,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport {\n\thelpFilled,\n\tplusCircleFilled,\n\talignJustifyAlt,\n\ttrashFilled,\n\tcogAlt,\n} from '@wordpress/icons';\nimport { useSelect } from '@wordpress/data';\nimport { store as editorStore } from '@wordpress/editor';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\nimport {\n\trequestContactCustomerSupport,\n\trequestGotoCustomerSupportOptions,\n} from '@wordpress/react-native-bridge';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport HelpDetailNavigationScreen from './help-detail-navigation-screen';\nimport HelpTopicRow from './help-topic-row';\nimport HelpGetSupportButton from './help-get-support-button';\nimport IntroToBlocks from './intro-to-blocks';\nimport AddBlocks from './add-blocks';\nimport MoveBlocks from './move-blocks';\nimport RemoveBlocks from './remove-blocks';\nimport CustomizeBlocks from './customize-blocks';\n\nconst HELP_TOPICS = [\n\t{\n\t\tlabel: __( 'What is a block?' ),\n\t\ticon: helpFilled,\n\t\tview: <IntroToBlocks />,\n\t},\n\t{\n\t\tlabel: __( 'Add blocks' ),\n\t\ticon: plusCircleFilled,\n\t\tview: <AddBlocks />,\n\t},\n\t{ label: __( 'Move blocks' ), icon: alignJustifyAlt, view: <MoveBlocks /> },\n\t{ label: __( 'Remove blocks' ), icon: trashFilled, view: <RemoveBlocks /> },\n\t{\n\t\tlabel: __( 'Customize blocks' ),\n\t\ticon: cogAlt,\n\t\tview: <CustomizeBlocks />,\n\t},\n];\n\nfunction EditorHelpTopics( { close, isVisible, onClose } ) {\n\tconst { postType } = useSelect( ( select ) => ( {\n\t\tpostType: select( editorStore ).getEditedPostAttribute( 'type' ),\n\t} ) );\n\n\tconst sectionTitle = usePreferredColorSchemeStyle(\n\t\tstyles.helpDetailSectionHeading,\n\t\tstyles.helpDetailSectionHeadingDark\n\t);\n\n\tconst title =\n\t\tpostType === 'page'\n\t\t\t? __( 'How to edit your page' )\n\t\t\t: __( 'How to edit your post' );\n\n\treturn (\n\t\t<BottomSheet\n\t\t\tisVisible={ isVisible }\n\t\t\tonClose={ onClose }\n\t\t\thideHeader\n\t\t\thasNavigation\n\t\t\tcontentStyle={ styles.contentContainer }\n\t\t\ttestID=\"editor-help-modal\"\n\t\t>\n\t\t\t<SafeAreaView>\n\t\t\t\t<BottomSheet.NavigationContainer\n\t\t\t\t\tanimate\n\t\t\t\t\tmain\n\t\t\t\t\tstyle={ styles.navigationContainer }\n\t\t\t\t>\n\t\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\t\tisScrollable\n\t\t\t\t\t\tfullScreen\n\t\t\t\t\t\tname=\"help-topics\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<View style={ styles.container }>\n\t\t\t\t\t\t\t<BottomSheet.NavBar>\n\t\t\t\t\t\t\t\t<BottomSheet.NavBar.DismissButton\n\t\t\t\t\t\t\t\t\tonPress={ close }\n\t\t\t\t\t\t\t\t\tiosText={ __( 'Close' ) }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t<BottomSheet.NavBar.Heading>\n\t\t\t\t\t\t\t\t\t{ title }\n\t\t\t\t\t\t\t\t</BottomSheet.NavBar.Heading>\n\t\t\t\t\t\t\t</BottomSheet.NavBar>\n\t\t\t\t\t\t\t<BottomSheetConsumer>\n\t\t\t\t\t\t\t\t{ ( { listProps } ) => {\n\t\t\t\t\t\t\t\t\tconst contentContainerStyle = StyleSheet.flatten(\n\t\t\t\t\t\t\t\t\t\tlistProps.contentContainerStyle\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t\t<ScrollView\n\t\t\t\t\t\t\t\t\t\t\t{ ...listProps }\n\t\t\t\t\t\t\t\t\t\t\tcontentContainerStyle={ {\n\t\t\t\t\t\t\t\t\t\t\t\t...contentContainerStyle,\n\t\t\t\t\t\t\t\t\t\t\t\tpaddingBottom: Math.max(\n\t\t\t\t\t\t\t\t\t\t\t\t\tlistProps.safeAreaBottomInset,\n\t\t\t\t\t\t\t\t\t\t\t\t\tcontentContainerStyle.paddingBottom\n\t\t\t\t\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t\t\t\t\t/**\n\t\t\t\t\t\t\t\t\t\t\t\t * Remove margin set via `hideHeader`. Combining a header\n\t\t\t\t\t\t\t\t\t\t\t\t * and navigation in this bottom sheet is at odds with the\n\t\t\t\t\t\t\t\t\t\t\t\t * current `BottomSheet` implementation.\n\t\t\t\t\t\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t\t\t\t\t\tmarginTop: 0,\n\t\t\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t<PanelBody>\n\t\t\t\t\t\t\t\t\t\t\t\t<Text style={ sectionTitle }>\n\t\t\t\t\t\t\t\t\t\t\t\t\t{ __( 'The basics' ) }\n\t\t\t\t\t\t\t\t\t\t\t\t</Text>\n\t\t\t\t\t\t\t\t\t\t\t\t{ /* Print out help topics */ }\n\t\t\t\t\t\t\t\t\t\t\t\t{ HELP_TOPICS.map(\n\t\t\t\t\t\t\t\t\t\t\t\t\t( { label, icon } ) => {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tconst labelSlug = kebabCase(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<HelpTopicRow\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tkey={\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabelSlug\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ticon={ icon }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tscreenName={\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabelSlug\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t<Text\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tstyle={ sectionTitle }\n\t\t\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{ __( 'Get support' ) }\n\t\t\t\t\t\t\t\t\t\t\t\t\t</Text>\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t<HelpGetSupportButton\n\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'Contact support'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tonPress={\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\trequestContactCustomerSupport\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t<HelpGetSupportButton\n\t\t\t\t\t\t\t\t\t\t\t\t\t\ttitle={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'More support options'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tonPress={\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\trequestGotoCustomerSupportOptions\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t</PanelBody>\n\t\t\t\t\t\t\t\t\t\t</ScrollView>\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t</BottomSheetConsumer>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t\t{ /* Print out help detail screens */ }\n\t\t\t\t\t{ HELP_TOPICS.map( ( { view, label } ) => {\n\t\t\t\t\t\tconst labelSlug = kebabCase( label );\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t<HelpDetailNavigationScreen\n\t\t\t\t\t\t\t\tkey={ labelSlug }\n\t\t\t\t\t\t\t\tname={ labelSlug }\n\t\t\t\t\t\t\t\tcontent={ view }\n\t\t\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\t\t\toptions={ {\n\t\t\t\t\t\t\t\t\tgestureEnabled: true,\n\t\t\t\t\t\t\t\t\t...TransitionPresets.DefaultTransition,\n\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t);\n\t\t\t\t\t} ) }\n\t\t\t\t</BottomSheet.NavigationContainer>\n\t\t\t</SafeAreaView>\n\t\t</BottomSheet>\n\t);\n}\n\nexport default EditorHelpTopics;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createElement } from "@wordpress/element";
|
|
1
|
+
import { createElement, Fragment } from "@wordpress/element";
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* External dependencies
|
|
@@ -9,6 +9,7 @@ import { View, Text } from 'react-native';
|
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
import { __ } from '@wordpress/i18n';
|
|
12
|
+
import { usePreferredColorSchemeStyle } from '@wordpress/compose';
|
|
12
13
|
/**
|
|
13
14
|
* Internal dependencies
|
|
14
15
|
*/
|
|
@@ -17,12 +18,15 @@ import styles from './style.scss';
|
|
|
17
18
|
import { HelpDetailBodyText, HelpDetailSectionHeadingText, HelpDetailImage } from './view-sections';
|
|
18
19
|
|
|
19
20
|
const IntroToBlocks = () => {
|
|
20
|
-
|
|
21
|
+
const titleStyle = usePreferredColorSchemeStyle(styles.helpDetailTitle, styles.helpDetailTitleDark);
|
|
22
|
+
return createElement(Fragment, null, createElement(HelpDetailImage, {
|
|
23
|
+
source: require('./images/block-layout-collage.png')
|
|
24
|
+
}), createElement(View, {
|
|
21
25
|
style: styles.helpDetailContainer
|
|
22
|
-
}, createElement(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
style:
|
|
26
|
+
}, createElement(Text, {
|
|
27
|
+
accessibilityRole: "header",
|
|
28
|
+
selectable: true,
|
|
29
|
+
style: titleStyle
|
|
26
30
|
}, __('Welcome to the world of blocks')), createElement(HelpDetailBodyText, {
|
|
27
31
|
text: __('Blocks are pieces of content that you can insert, rearrange, and style without needing to know how to code. Blocks are an easy and modern way for you to create beautiful layouts.')
|
|
28
32
|
}), createElement(HelpDetailSectionHeadingText, {
|
|
@@ -30,22 +34,27 @@ const IntroToBlocks = () => {
|
|
|
30
34
|
}), createElement(HelpDetailBodyText, {
|
|
31
35
|
text: __('Blocks allow you to focus on writing your content, knowing that all the formatting tools you need are there to help you get your message across.')
|
|
32
36
|
}), createElement(HelpDetailImage, {
|
|
33
|
-
|
|
37
|
+
accessible: true,
|
|
38
|
+
accessibilityLabel: __('Text formatting controls are located within the toolbar positioned above the keyboard while editing a text block'),
|
|
39
|
+
source: require('./images/rich-text-light.png'),
|
|
40
|
+
sourceDarkMode: require('./images/rich-text-dark.png')
|
|
34
41
|
}), createElement(HelpDetailSectionHeadingText, {
|
|
35
42
|
text: __('Embed media')
|
|
36
43
|
}), createElement(HelpDetailBodyText, {
|
|
37
44
|
text: __('Make your content stand out by adding images, gifs, videos, and embedded media to your pages.')
|
|
38
45
|
}), createElement(HelpDetailImage, {
|
|
39
|
-
source: require('./images/
|
|
46
|
+
source: require('./images/embed-media-light.png'),
|
|
47
|
+
sourceDarkMode: require('./images/embed-media-dark.png')
|
|
40
48
|
}), createElement(HelpDetailSectionHeadingText, {
|
|
41
49
|
text: __('Build layouts')
|
|
42
50
|
}), createElement(HelpDetailBodyText, {
|
|
43
51
|
text: __('Arrange your content into columns, add Call to Action buttons, and overlay images with text.')
|
|
44
52
|
}), createElement(HelpDetailImage, {
|
|
45
|
-
source: require('./images/
|
|
53
|
+
source: require('./images/build-layouts-light.png'),
|
|
54
|
+
sourceDarkMode: require('./images/build-layouts-dark.png')
|
|
46
55
|
}), createElement(HelpDetailBodyText, {
|
|
47
56
|
text: __('Give it a try by adding a few blocks to your post or page!')
|
|
48
|
-
}));
|
|
57
|
+
})));
|
|
49
58
|
};
|
|
50
59
|
|
|
51
60
|
export default IntroToBlocks;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/intro-to-blocks.native.js"],"names":["View","Text","__","styles","HelpDetailBodyText","HelpDetailSectionHeadingText","HelpDetailImage","IntroToBlocks","
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/intro-to-blocks.native.js"],"names":["View","Text","__","usePreferredColorSchemeStyle","styles","HelpDetailBodyText","HelpDetailSectionHeadingText","HelpDetailImage","IntroToBlocks","titleStyle","helpDetailTitle","helpDetailTitleDark","require","helpDetailContainer"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,IAAT,EAAeC,IAAf,QAA2B,cAA3B;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,4BAAT,QAA6C,oBAA7C;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,SACCC,kBADD,EAECC,4BAFD,EAGCC,eAHD,QAIO,iBAJP;;AAMA,MAAMC,aAAa,GAAG,MAAM;AAC3B,QAAMC,UAAU,GAAGN,4BAA4B,CAC9CC,MAAM,CAACM,eADuC,EAE9CN,MAAM,CAACO,mBAFuC,CAA/C;AAIA,SACC,8BACC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGC,OAAO,CAAE,mCAAF;AADjB,IADD,EAIC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGR,MAAM,CAACS;AAArB,KACC,cAAC,IAAD;AACC,IAAA,iBAAiB,EAAC,QADnB;AAEC,IAAA,UAAU,MAFX;AAGC,IAAA,KAAK,EAAGJ;AAHT,KAKGP,EAAE,CAAE,gCAAF,CALL,CADD,EAQC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,oLADQ;AADV,IARD,EAaC,cAAC,4BAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CAAE,mBAAF;AADV,IAbD,EAgBC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,kJADQ;AADV,IAhBD,EAqBC,cAAC,eAAD;AACC,IAAA,UAAU,EAAG,IADd;AAEC,IAAA,kBAAkB,EAAGA,EAAE,CACtB,kHADsB,CAFxB;AAKC,IAAA,MAAM,EAAGU,OAAO,CAAE,8BAAF,CALjB;AAMC,IAAA,cAAc,EAAGA,OAAO,CAAE,6BAAF;AANzB,IArBD,EA6BC,cAAC,4BAAD;AAA8B,IAAA,IAAI,EAAGV,EAAE,CAAE,aAAF;AAAvC,IA7BD,EA8BC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,+FADQ;AADV,IA9BD,EAmCC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGU,OAAO,CAAE,gCAAF,CADjB;AAEC,IAAA,cAAc,EAAGA,OAAO,CAAE,+BAAF;AAFzB,IAnCD,EAuCC,cAAC,4BAAD;AAA8B,IAAA,IAAI,EAAGV,EAAE,CAAE,eAAF;AAAvC,IAvCD,EAwCC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGA,EAAE,CACR,8FADQ;AADV,IAxCD,EA6CC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGU,OAAO,CAAE,kCAAF,CADjB;AAEC,IAAA,cAAc,EAAGA,OAAO,CAAE,iCAAF;AAFzB,IA7CD,EAiDC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGV,EAAE,CACR,4DADQ;AADV,IAjDD,CAJD,CADD;AA8DA,CAnED;;AAqEA,eAAeM,aAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View, Text } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { usePreferredColorSchemeStyle } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport {\n\tHelpDetailBodyText,\n\tHelpDetailSectionHeadingText,\n\tHelpDetailImage,\n} from './view-sections';\n\nconst IntroToBlocks = () => {\n\tconst titleStyle = usePreferredColorSchemeStyle(\n\t\tstyles.helpDetailTitle,\n\t\tstyles.helpDetailTitleDark\n\t);\n\treturn (\n\t\t<>\n\t\t\t<HelpDetailImage\n\t\t\t\tsource={ require( './images/block-layout-collage.png' ) }\n\t\t\t/>\n\t\t\t<View style={ styles.helpDetailContainer }>\n\t\t\t\t<Text\n\t\t\t\t\taccessibilityRole=\"header\"\n\t\t\t\t\tselectable\n\t\t\t\t\tstyle={ titleStyle }\n\t\t\t\t>\n\t\t\t\t\t{ __( 'Welcome to the world of blocks' ) }\n\t\t\t\t</Text>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Blocks are pieces of content that you can insert, rearrange, and style without needing to know how to code. Blocks are an easy and modern way for you to create beautiful layouts.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailSectionHeadingText\n\t\t\t\t\ttext={ __( 'Rich text editing' ) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Blocks allow you to focus on writing your content, knowing that all the formatting tools you need are there to help you get your message across.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailImage\n\t\t\t\t\taccessible={ true }\n\t\t\t\t\taccessibilityLabel={ __(\n\t\t\t\t\t\t'Text formatting controls are located within the toolbar positioned above the keyboard while editing a text block'\n\t\t\t\t\t) }\n\t\t\t\t\tsource={ require( './images/rich-text-light.png' ) }\n\t\t\t\t\tsourceDarkMode={ require( './images/rich-text-dark.png' ) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailSectionHeadingText text={ __( 'Embed media' ) } />\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Make your content stand out by adding images, gifs, videos, and embedded media to your pages.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailImage\n\t\t\t\t\tsource={ require( './images/embed-media-light.png' ) }\n\t\t\t\t\tsourceDarkMode={ require( './images/embed-media-dark.png' ) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailSectionHeadingText text={ __( 'Build layouts' ) } />\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Arrange your content into columns, add Call to Action buttons, and overlay images with text.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailImage\n\t\t\t\t\tsource={ require( './images/build-layouts-light.png' ) }\n\t\t\t\t\tsourceDarkMode={ require( './images/build-layouts-dark.png' ) }\n\t\t\t\t/>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'Give it a try by adding a few blocks to your post or page!'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t</View>\n\t\t</>\n\t);\n};\n\nexport default IntroToBlocks;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createElement } from "@wordpress/element";
|
|
1
|
+
import { createElement, Fragment } from "@wordpress/element";
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* External dependencies
|
|
@@ -17,13 +17,14 @@ import styles from './style.scss';
|
|
|
17
17
|
import { HelpDetailBodyText, HelpDetailImage } from './view-sections';
|
|
18
18
|
|
|
19
19
|
const MoveBlocks = () => {
|
|
20
|
-
return createElement(
|
|
20
|
+
return createElement(Fragment, null, createElement(HelpDetailImage, {
|
|
21
|
+
source: require('./images/move-light.png'),
|
|
22
|
+
sourceDarkMode: require('./images/move-dark.png')
|
|
23
|
+
}), createElement(View, {
|
|
21
24
|
style: styles.helpDetailContainer
|
|
22
|
-
}, createElement(
|
|
23
|
-
source: require('./images/move-blocks.png')
|
|
24
|
-
}), createElement(HelpDetailBodyText, {
|
|
25
|
+
}, createElement(HelpDetailBodyText, {
|
|
25
26
|
text: __('You can rearrange blocks by tapping a block and then tapping the up and down arrows that appear on the bottom left side of the block to move it above or below other blocks.')
|
|
26
|
-
}));
|
|
27
|
+
})));
|
|
27
28
|
};
|
|
28
29
|
|
|
29
30
|
export default MoveBlocks;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/move-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","MoveBlocks","
|
|
1
|
+
{"version":3,"sources":["@wordpress/editor/src/components/editor-help/move-blocks.native.js"],"names":["View","__","styles","HelpDetailBodyText","HelpDetailImage","MoveBlocks","require","helpDetailContainer"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,cAArB;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,SAASC,kBAAT,EAA6BC,eAA7B,QAAoD,iBAApD;;AAEA,MAAMC,UAAU,GAAG,MAAM;AACxB,SACC,8BACC,cAAC,eAAD;AACC,IAAA,MAAM,EAAGC,OAAO,CAAE,yBAAF,CADjB;AAEC,IAAA,cAAc,EAAGA,OAAO,CAAE,wBAAF;AAFzB,IADD,EAKC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGJ,MAAM,CAACK;AAArB,KACC,cAAC,kBAAD;AACC,IAAA,IAAI,EAAGN,EAAE,CACR,8KADQ;AADV,IADD,CALD,CADD;AAeA,CAhBD;;AAkBA,eAAeI,UAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\nimport { HelpDetailBodyText, HelpDetailImage } from './view-sections';\n\nconst MoveBlocks = () => {\n\treturn (\n\t\t<>\n\t\t\t<HelpDetailImage\n\t\t\t\tsource={ require( './images/move-light.png' ) }\n\t\t\t\tsourceDarkMode={ require( './images/move-dark.png' ) }\n\t\t\t/>\n\t\t\t<View style={ styles.helpDetailContainer }>\n\t\t\t\t<HelpDetailBodyText\n\t\t\t\t\ttext={ __(\n\t\t\t\t\t\t'You can rearrange blocks by tapping a block and then tapping the up and down arrows that appear on the bottom left side of the block to move it above or below other blocks.'\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t</View>\n\t\t</>\n\t);\n};\n\nexport default MoveBlocks;\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createElement } from "@wordpress/element";
|
|
1
|
+
import { createElement, Fragment } from "@wordpress/element";
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* External dependencies
|
|
@@ -17,13 +17,14 @@ import styles from './style.scss';
|
|
|
17
17
|
import { HelpDetailBodyText, HelpDetailImage } from './view-sections';
|
|
18
18
|
|
|
19
19
|
const RemoveBlocks = () => {
|
|
20
|
-
return createElement(
|
|
20
|
+
return createElement(Fragment, null, createElement(HelpDetailImage, {
|
|
21
|
+
source: require('./images/options-light.png'),
|
|
22
|
+
sourceDarkMode: require('./images/options-dark.png')
|
|
23
|
+
}), createElement(View, {
|
|
21
24
|
style: styles.helpDetailContainer
|
|
22
|
-
}, createElement(
|
|
23
|
-
source: require('./images/remove-blocks.png')
|
|
24
|
-
}), createElement(HelpDetailBodyText, {
|
|
25
|
+
}, createElement(HelpDetailBodyText, {
|
|
25
26
|
text: __('To remove a block, select the block and click the three dots in the bottom right of the block to view the settings. From there, choose the option to remove the block.')
|
|
26
|
-
}));
|
|
27
|
+
})));
|
|
27
28
|
};
|
|
28
29
|
|
|
29
30
|
export default RemoveBlocks;
|