TinyMCE for Touch-Enabled and Mobile Devices
The mobile editing experience for TinyMCE is enabled by default. It differs from the desktop version in several key ways to provide a responsive and touch-optimized interface:
-
Horizontal and side-scrolling toolbars and contextual menus.
-
Context-sensitive keyboard behavior using
inputMode
. -
Predefined mobile-specific default values for selected configuration options.
-
Touch gestures for accessing the context menu, depending on platform.
TinyMCE automatically detects the platform and displays an optimal UI based on screen size and device type.
The native context menu remains accessible on mobile devices even when a custom TinyMCE context menu is configured. On iOS, this is done with a single tap; on Android, a double tap is required. If the |
iPads are treated as desktop-class devices due to Apple’s environment constraints. While the mobile configuration will not apply on iPads, touch interactions such as context toolbars and menus will still behave as expected.
|
When a TinyMCE context menu is configured, a user on a mobile device can access the TinyMCE context menu by a long press. However, when a TinyMCE context menu is not configured but a TinyMCE context toolbar is, long press will open the context toolbar instead. |
Supported Mobile Platforms
TinyMCE mobile is tested against, and is designed to run on, the default browser running on either the current or penultimate version of either Android and iOS.
Operating System | Default browser |
---|---|
Android |
Chrome |
iOS |
Safari |
By default, both Google and Apple automatically update their operating systems and their default browsers.
Android and iOS, again by default, automatically update themselves with patches, security fixes, and minor updates. However, major updates — that is updates from one major version of the operating system to the next major version — are announced but not installed without user or system administrator input.
The default browser on each operating system is similarly updated with patches, security fixes, and minor updates. Unlike with the operating system, however, major updates — that is updates from one major version of the default browser to the next major version — are also automatically installed by default.
Consequently, Tiny Technologies, Inc. only supports TinyMCE mobile on the most recent release of each of the four supported operating system and browser combinations.
That is, TinyMCE mobile is supported on
-
the most recent release of the current version of Android in combination with the most recent release of Chrome for the current version of Android;
-
the most recent release of the penultimate version of Android in combination with the most recent release of Chrome for the penultimate version of Android.
-
the most recent release of the current version of iOS in combination with the most recent release of Safari for the current version of iOS.
-
the most recent release of the penultimate version of iOS in combination with the most recent release of Safari for the the penultimate version of iOS.
However, TinyMCE mobile is not supported on any beta or other pre-production releases of either the mobile operating system or its default browser.
Mobile Plugin Limitations
Some plugins offer limited functionality or are unsupported when used on mobile devices, particularly in inline mode.
Known Plugin Limitations
Feature | Limitation |
---|---|
Image resizing is only available through the Edit Image dialog; in-editor resizing is not supported. |
|
Clipboard restrictions on mobile platforms prevent core PowerPaste functionality. |
Configuring Mobile Behavior
To ensure the TinyMCE mobile UI functions correctly, include the following meta
tag in the <head>
of your HTML:
<meta name="viewport" content="width=device-width, initial-scale=1">
To customize behavior on mobile devices, use the mobile
configuration option. For example:
tinymce.init({
selector: 'textarea', // Adjust this value to match your HTML
mobile: {
menubar: true
}
});
Mobile-Specific Defaults
The following options are automatically set to provide a better experience on mobile devices:
-
menubar
— Defaults tofalse
on mobile phones. -
toolbar_mode
— Defaults toscrolling
; enables side-scrolling toolbars. -
toolbar_sticky
— Defaults tofalse
; sticky toolbars are not supported. -
table_grid
— Defaults tofalse
; a dialog replaces the table grid. -
resize
— Defaults tofalse
; in-editor resizing is disabled. -
object_resizing
— Defaults tofalse
; object resizing is not supported.
Unsupported Configuration Options
The following configuration options are not applicable or functional on mobile devices:
The mobile
option
This option allows an alternative configuration to be specified that will override other options specifically for mobile devices. For information on customizing TinyMCE for mobile devices, see: TinyMCE mobile.
Type: Object
Example of mobile specific configuration
This example shows how to setup a mobile section to override some of the desktop settings with mobile specific settings.
tinymce.init({
selector: 'textarea', // change this value according to your HTML
plugins: 'code lists',
mobile: {
menubar: true,
plugins: 'autosave lists autolink',
toolbar: 'undo bold italic styles'
}
});