Make WordPress Core

Ticket #25903: wp-tinymce-scheme.semicolons.diff

File wp-tinymce-scheme.semicolons.diff, 2.4 KB (added by jorbin, 12 years ago)
  • src/wp-includes/js/tinymce/wp-tinymce-schema.js

     
    1515
    1616        function split(str, delim) {
    1717                return str.split(delim || ',');
    18         };
     18        }
    1919
    2020        /**
    2121         * Unpacks the specified lookup and string data it will also parse it into an object
     
    2828                        return value.replace(/[A-Z]+/g, function(key) {
    2929                                return replace(lookup[key]);
    3030                        });
    31                 };
     31                }
    3232
    3333                // Unpack lookup
    3434                for (key in lookup) {
     
    4444                                attributes : makeMap(attributes),
    4545                                attributesOrder : attributes,
    4646                                children : makeMap(children, '|', {'#comment' : {}})
    47                         }
     47                        };
    4848                });
    4949
    5050                return elements;
    51         };
     51        }
    5252
    5353        /**
    5454         * Returns the HTML5 schema and caches it in the mapCache.
     
    177177                }
    178178
    179179                return html5;
    180         };
     180        }
    181181
    182182        /**
    183183         * Returns the HTML4 schema and caches it in the mapCache.
     
    308308                }
    309309
    310310                return html4;
    311         };
     311        }
    312312
    313313        /**
    314314         * WordPress Core
     
    409409                        }
    410410
    411411                        return value;
    412                 };
     412                }
    413413
    414414                settings = settings || {};
    415415
     
    446446                // Converts a wildcard expression string to a regexp for example *a will become /.*a/.
    447447                function patternToRegExp(str) {
    448448                        return new RegExp('^' + str.replace(/([?+*])/g, '.$1') + '$');
    449                 };
     449                }
    450450
    451451                // Parses the specified valid_elements string and adds to the current rules
    452452                // This function is a bit hard to read since it's heavily optimized for speed
     
    587587                                        }
    588588                                }
    589589                        }
    590                 };
     590                }
    591591
    592592                function setValidElements(valid_elements) {
    593593                        elements = {};
     
    598598                        each(schemaItems, function(element, name) {
    599599                                children[name] = element.children;
    600600                        });
    601                 };
     601                }
    602602
    603603                // Adds custom non HTML elements to the schema
    604604                function addCustomElements(custom_elements) {
     
    632632                                        });
    633633                                });
    634634                        }
    635                 };
     635                }
    636636
    637637                // Adds valid children to the schema object
    638638                function addValidChildren(valid_children) {
     
    662662                                        }
    663663                                });
    664664                        }
    665                 };
     665                }
    666666
    667667                function getElementRule(name) {
    668668                        var element = elements[name], i;
     
    679679                                if (element.pattern.test(name))
    680680                                        return element;
    681681                        }
    682                 };
     682                }
    683683
    684684                if (!settings.valid_elements) {
    685685                        // No valid elements defined then clone the elements from the schema spec