OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
_backup
/
tinymce
/
tinymce
/
src
/
core
/
main
/
ts
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
02/20/2020 05:40:27 AM
rwxr-xr-x
📄
DragDropOverrides.ts
7.64 KB
02/20/2020 05:40:30 AM
rw-r--r--
📄
EditorRemove.ts
2.73 KB
02/20/2020 05:40:30 AM
rw-r--r--
📄
EditorSettings.ts
7.92 KB
02/20/2020 05:40:32 AM
rw-r--r--
📄
EditorView.ts
2.47 KB
02/20/2020 05:40:32 AM
rw-r--r--
📄
ErrorReporter.ts
2.43 KB
02/20/2020 05:40:33 AM
rw-r--r--
📄
ForceBlocks.ts
3.71 KB
02/20/2020 05:40:33 AM
rw-r--r--
📄
Mode.ts
4.53 KB
02/20/2020 05:40:34 AM
rw-r--r--
📄
NodeChange.ts
5.19 KB
02/20/2020 05:40:34 AM
rw-r--r--
📄
SelectionOverrides.ts
16.08 KB
02/20/2020 05:40:35 AM
rw-r--r--
📁
annotate
-
02/20/2020 05:41:49 AM
rwxr-xr-x
📁
api
-
02/20/2020 06:12:10 AM
rwxr-xr-x
📁
bookmark
-
02/20/2020 05:42:16 AM
rwxr-xr-x
📁
caret
-
02/20/2020 05:42:30 AM
rwxr-xr-x
📁
commands
-
02/20/2020 05:42:34 AM
rwxr-xr-x
📁
content
-
02/20/2020 05:42:42 AM
rwxr-xr-x
📁
delete
-
02/20/2020 05:42:54 AM
rwxr-xr-x
📁
dom
-
02/20/2020 05:43:08 AM
rwxr-xr-x
📁
file
-
02/20/2020 05:43:14 AM
rwxr-xr-x
📁
fmt
-
02/20/2020 05:43:26 AM
rwxr-xr-x
📁
focus
-
02/20/2020 05:43:32 AM
rwxr-xr-x
📁
geom
-
02/20/2020 05:43:36 AM
rwxr-xr-x
📁
html
-
02/20/2020 05:43:38 AM
rwxr-xr-x
📁
init
-
02/20/2020 05:43:46 AM
rwxr-xr-x
📁
keyboard
-
02/20/2020 05:44:00 AM
rwxr-xr-x
📁
newline
-
02/20/2020 05:44:07 AM
rwxr-xr-x
📁
selection
-
02/20/2020 05:44:24 AM
rwxr-xr-x
📁
text
-
02/20/2020 05:44:30 AM
rwxr-xr-x
📁
ui
-
02/20/2020 05:44:34 AM
rwxr-xr-x
📁
undo
-
02/20/2020 05:44:41 AM
rwxr-xr-x
📁
util
-
02/20/2020 05:44:48 AM
rwxr-xr-x
Editing: ErrorReporter.ts
Close
/** * Copyright (c) Tiny Technologies, Inc. All rights reserved. * Licensed under the LGPL or a commercial license. * For LGPL see License.txt in the project root for license information. * For commercial licenses see https://www.tiny.cloud/ */ import AddOnManager from './api/AddOnManager'; import { window } from '@ephox/dom-globals'; import I18n from './api/util/I18n'; import Editor from 'tinymce/core/api/Editor'; /** * Various error reporting helper functions. * * @class tinymce.ErrorReporter * @private */ const PluginManager = AddOnManager.PluginManager; const resolvePluginName = function (targetUrl, suffix) { for (const name in PluginManager.urls) { const matchUrl = PluginManager.urls[name] + '/plugin' + suffix + '.js'; if (matchUrl === targetUrl) { return name; } } return null; }; const pluginUrlToMessage = function (editor: Editor, url: string) { const plugin = resolvePluginName(url, editor.suffix); return plugin ? I18n.translate(['Failed to load plugin: {0} from url {1}', plugin, url]) : I18n.translate(['Failed to load plugin url: {0}', url]); }; const displayNotification = function (editor: Editor, message: string) { editor.notificationManager.open({ type: 'error', text: message }); }; const displayError = function (editor: Editor, message: string) { if (editor._skinLoaded) { displayNotification(editor, message); } else { editor.on('SkinLoaded', function () { displayNotification(editor, message); }); } }; const uploadError = function (editor: Editor, message: string) { displayError(editor, I18n.translate(['Failed to upload image: {0}', message])); }; const pluginLoadError = function (editor: Editor, url: string) { displayError(editor, pluginUrlToMessage(editor, url)); }; const pluginInitError = function (editor: Editor, name: string, err) { const message = I18n.translate(['Failed to initialize plugin: {0}', name]); initError(message, err); displayError(editor, message); }; const initError = function (message: string, ...x: any[]) { const console = window.console; if (console) { // Skip test env if (console.error) { // tslint:disable-line:no-console console.error.apply(console, arguments); // tslint:disable-line:no-console } else { console.log.apply(console, arguments); // tslint:disable-line:no-console } } }; export default { pluginLoadError, pluginInitError, uploadError, displayError, initError };