mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-09-11 23:36:05 +00:00
Fix copyStyles() not working in Firefox
Yet more browser incompatibilities to weep over…
This commit is contained in:
@@ -209,8 +209,8 @@ Get the computed styles applied to an element as an array of strings of individu
|
|||||||
exports.getComputedStyles = function(domNode) {
|
exports.getComputedStyles = function(domNode) {
|
||||||
var textAreaStyles = window.getComputedStyle(domNode,null),
|
var textAreaStyles = window.getComputedStyle(domNode,null),
|
||||||
styleDefs = [];
|
styleDefs = [];
|
||||||
$tw.utils.each(Object.keys(textAreaStyles),function(name) {
|
$tw.utils.each(textAreaStyles,function(name,index) {
|
||||||
styleDefs.push(name + ": " + textAreaStyles[name] + ";");
|
styleDefs.push(name + ": " + textAreaStyles.getPropertyValue(name) + ";");
|
||||||
});
|
});
|
||||||
return styleDefs;
|
return styleDefs;
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user