mirror of
https://github.com/writeas/writefreely-swiftui-multiplatform.git
synced 2024-11-15 01:11:02 +00:00
21 lines
414 B
JavaScript
21 lines
414 B
JavaScript
var Action = function() {};
|
|
|
|
Action.prototype = {
|
|
|
|
run: function(parameters) {
|
|
parameters.completionFunction({
|
|
"URL": document.URL,
|
|
"title": document.title,
|
|
"selection": document.getSelection().toString()
|
|
});
|
|
},
|
|
|
|
finalize: function(parameters) {
|
|
var customJavaScript = parameters["customJavaScript"];
|
|
eval(customJavaScript);
|
|
}
|
|
|
|
};
|
|
|
|
var ExtensionPreprocessingJS = new Action
|