Skip to content
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.

Releases: google/closure-library

Closure Library v20200927

29 Oct 22:01
Compare
Choose a tag to compare

New Additions

  • Added a goog.provide for goog.log.LogBuffer. (c4e1260)

Backwards Incompatible Changes

  • Calls to goog.now now use the current value of Date.now (4af6950)
  • Remove obsolete browser selection code from AbstractRange now that getSelection is supported across all Closure Library supported browsers. (b41ef3c)
  • goog.format.EmailAddress.parse now ignores unicode bidi markers (ac1c88d)
  • Mark AbstractRange#getBrowserSelectionForWindow as deprecated, as it is now identical to Window#getSelection. (d1b8bfd)
  • Make goog.functions.partialRight return a strict mode partial function. (ba03d72)
  • goog.isFunction has been deleted. Use goog.functions.isFunction or typeof x === 'function' instead. (6342251)
  • RecordFunction now runs in strict mode. (ccd76bd)
  • Tighten strictness in Closure Library functions in various goog.provide files.
  • Modernized various Closure Library classes.

Other Changes

  • Fixed goog.style.bidi.usesNegativeScrollLeftInRtl_ to include Chrome 85+. (e168856)
  • Fix lint errors in calcdeps.py (34c45b9)
  • add unescapeHtmlEntities option to goog.getMsg(). (9a1733d)
  • Remove forwardDeclare from goog.editor.PluginImpl (c10c2b4)
  • Remove forwardDeclare from testing.fs.FileSystem and testing.fs.FileWriter. (1b215a8)
  • Make removeAllListeners also accept EventId. (1c5aabc)

Closure Library v20200830

03 Sep 07:14
Compare
Choose a tag to compare

New Additions

  • goog.log.getRootLogger has been added
  • Add MockClock.tickAsync()
  • goog.loader.NoopModuleManager: Add new no-op default module manager implementation
  • Add goog.functions.isFunction
  • Add new method goog.testing.singleton.reset()

Backwards Incompatible Changes

  • goog.delay has been removed
  • Remove support for text/csv in SafeUrl.{fromBlob,fromDataUrl,tryFromDataUrl}. Safe uses should migrate to unchecked conversions
  • Tighten strictness in Closure Library functions in goog.provide files
  • goog.loader.activeModuleManager: Rename maybeInitialize to initialize
  • Remove deprecated method goog.fs.blobAsString

Other Changes

  • Resolved issue with rendering child tabs incorrectly when they moved right
  • Make goog.events libraries compatible with clutz (JS to TS converter)
  • Allow using setInnerHtml with ShadowRoot
  • Check for TypedArray in goog.object.unsafeClone and clone them appropriately
  • Fix edge-case in TestCase autodiscovery
  • Add aria-owns to permitted list of attributes with IDENTIFIER contract
  • Update isSafariDesktopOnMobile check to account for non-Safari browsers that have recently adopted the same behavior
  • Typo fix in goog.url#createUrl
  • Adds unhandled error handler for Deferreds for transitional purposes

Closure Library v20200719

21 Jul 22:39
Compare
Choose a tag to compare

New Additions

  • goog.collections.iters graduated from goog.labs.*
  • goog.loader.activeModuleManager optional arguments have been added to maybeInitialize method
  • goog.loader.activeModuleManager maybeInitialize method has been added

Other Changes

  • Changes ImageLoader event dispatch order to support re-queuing duplicate image IDS
  • Add more static methods to goog.log.
  • Remove usage of vendor-prefixed versions of Blob#slice.
  • goog.log.LogBuffer is now an alias of goog.debug.LogBuffer.
  • Update goog\.dom\.TagName to be an uninstantiable record type.
  • Rename goog.testing.singleton.reset to goog.testing.singleton.resetAll
  • Resolved issue with rendering child tabs incorrectly when they moved right.

Closure Library v20200628

06 Jul 21:15
Compare
Choose a tag to compare

New Additions

  • Add commit method to goog.db.Transaction.
  • Add trySanitize and tryFromDataUrl to goog.html.SafeUrl
  • Add goog.dom.copyContents.

Backwards Incompatible Changes

  • declareLegacyNamespace logic has been updated to work more like goog.provide.
  • goog.isArray has been deleted. Use Array.isArray instead.

Other Changes

  • goog.net.xpc.IframePollingTransport has been removed.
  • Removed deprecated goog.object.is in favor of Object.is
  • Updated acceptable mXSS output.
  • add Event.type to error message when possible.
  • Mark goog.iter.Iterator as deprecated
  • Make goog.html APIs exclude monkeypatched enumerable properties on Object.prototype
  • goog.now now always uses Date.now

Closure Library v20200614

17 Jun 16:59
Compare
Choose a tag to compare

New Additions

  • Add commit method to goog.db.Transaction.
  • Add goog.dom.safe.setInnerHtmlFromConstant.
  • Add an adapter API to use Closure asserts with other testing frameworks (eg, Jasmine).
  • goog.module.ModuleManager addExtraEdge and removeExtraEdge methods have been added.

Backwards Incompatible Changes

  • goog.globalize has been removed
  • Remove aliases of goog.getHashCode and goog.removeHashCode from goog.js.
  • goog.typeOf no longer special cases very old browsers.
  • goog.STRICT_MODE_COMPATIBLE has been removed.
  • Remove transitionalforwarddeclarations.js
  • goog.getHashCode and goog.removeHashCode have been removed.
  • Simplify goog.globalEval in by removing pre-ES5 support.

Other Changes

  • Remove useless transitionforwarddeclarations.js
  • Deprecate goog.provide, goog.inherits, and goog.bind
  • Use the new asserts adapter in fail().
  • Templatize goog.array.equals comparison function.
  • Deprecate goog.isFunction
  • Delete goog\.result\.Result.
  • Clean up circular dependency in net/xpc.
  • Deprecate goog.object.is
  • Fix overflow issue for link dialog input.
  • Changed the default value of goog.TRUSTED_TYPES_POLICY_NAME to enable Trusted Types (https://github\.com/w3c/webappsec-trusted-types\) support in goog.html.{SafeHtml,SafeScript,TrustedResourceUrl} and goog.base debug loaders. Trusted Types will be used whenever available in the runtime.
  • Deprecate goog.nullFunction.
  • requestFullscreen now returns the result of the browser-specific API call.
  • Copy much of the interface of Deferred onto Result.
  • Aligned the trusted types related tests with the current goog.html.trustedtypes package naming.

Closure Library v20200517

19 May 03:22
Compare
Choose a tag to compare

New Additions

  • goog.module.AbstractModuleLoader extraEdges has been added as an optional parameter to the loadModules method.
  • Added goog.html.SafeUrl.revokeObjectUrl.

Backwards Incompatible Changes

  • Disallow old templates signatures.
  • Remove noop method goog.tagUnsealableClass
  • goog.isArray now calls Array.isArray

Other Changes

  • Update data formatting with ICU67.
  • Now handles negative patterns for compact numbers.
  • Workaround for https://crbug\.com/1081632\. In workers without a Secure Context (https://www\.w3\.org/TR/secure-contexts/\) self\.trustedHTML is defined, but has no properties. Unwrapping goog.html.SafeHtml.EMPTY_HTML in such realms caused errors.
  • Add callback in URI package to detect usage that is better supported by the new URL package.
  • Use Array.isArray instead of goog.typeOf in more places.
  • Add URL package to Closure Library.
  • Create goog.html Trusted Types policy lazily.
  • goog.result.DeferredAdaptor has been removed.
  • Update data to ICU 67 / CLDR 37. No API changes.
  • goog.html.SafeHtml and goog.html.SafeScript static properties can now be compiled out if they are not used, even when goog.TRUSTED_TYPES_POLICY_NAME is set.
  • In autocomplete demos, use JSON data instead of JS data.
  • Remove forwardDeclares from Closure dom by adding an abstraction for SavedRanges that use Carets (AbstractSavedCaretRange) and stopping the various Range implementations from directly using goog.dom.Range constructors for new sub-ranges.

Closure Library v20200504

07 May 18:16
Compare
Choose a tag to compare

New Additions

  • goog.module.AbstractModuleLoader extraEdges has been added as an optional parameter to the loadModules method.
  • goog.module.AbstractModuleLoader the type of the extraEdges parameter of the loadModules method has been updated to map to a Set
  • goog.loader.AbstractModuleManager addExtraEdge and removeExtraEdge methods have been added.
  • Whitelist additional ARIA attributes in the HtmlSanitizer.
  • Add concat method to iterables library

Backwards Incompatible Changes

  • goog.debug.deepFreeze should now be imported with destructuring.
  • goog.labs.collections.iterables renamed to goog.labs.collections.iters.
  • goog.module.AbstractModuleLoader optional parameters have been merged into a single options bag.

Other Changes

  • goog.module.AbstractModuleLoader migrate to ES6 syntax
  • Remove an old Safari behaviour workaround in goog.globalEval. This will simplify future Trusted Types integration, as eval(trustedTypes.emptyScript) might be used, and that pattern does not require creating a Trusted Types policy.
  • Add optional window object in the call to getScriptNonce.
  • Removed references to deprecated parts of the Trusted Types API (window\.TrustedTypes and TrustedTypePolicyOptions\.createURL)
  • Remove goog.defineClass's support for sealing instances
  • Add scripts to package.json for serving the tests and demos locally.
  • Defines Deferred::getLastValueForMigration.
  • Move base.js Trusted Types policy creation to the conditional block creating the debug loaders to avoid creating the policy for binaries without the debug loader.
  • Use about:blank iframe instead of an iframe with an empty source in goog.async.nextTick. Removed spurious document.write call.
  • Remove noop method goog.tagUnsealableClass

Closure Library v20200406

10 Apr 00:50
Compare
Choose a tag to compare

Backwards Incompatible Changes

  • In the QueryData constructor, as well as in QueryData.createFromKeysValues and QueryData.createFromMap, opt_uri (second-to-last argument) is removed, and opt_ignoreCase (last argument) takes its place.
  • Tests calling goog.window.open and mocking window.open now need to pass an undefined 4th parameter or mock goog.window.open.

Other Changes

  • Remove demos from checked-in deps.js file.
  • Allow string name in goog.dom.safe.openInWindow.
  • Allow font/ MIME type in SafeUrl.
  • Use setTextContent in modern browsers.

Closure Library v20200315

24 Mar 02:57
Compare
Choose a tag to compare

New Additions

  • Add SafeHtml.comment.

Security Fixes

Backwards Incompatible Changes

  • Delete inlay css styles, which are not actually used by Closure.
  • Add non-nullable modifier to return type of functions never returning null.
  • Remove forwardDeclares from Closure Events Listenable by reducing the typing of the event key's src property to just Listenable, instead of Listenable|EventTarget. Note that EventTarget is the primary implementation of Listenable.

Other Changes

  • Added SafeUrl.fromMediaSource()
  • Fix authority parsing in Closure URI parser.
  • Document mode is now based on user agent on IE if not present in document
  • Add a define to module manager so that we can control module loading behaviors.
  • Add non-nullable modifier to return type of functions never returning null.
  • goog.isArray in deprecated in favor of Array.isArray
  • Update Thenable.then rejection handler JSDoc to reflect actual functionality.

Closure Library v20200224

26 Feb 19:51
Compare
Choose a tag to compare

New Additions

  • Create goog.debug.deepFreeze.
  • Added goog.async.promises.allMapsValues utility function

Backwards Incompatible Changes

  • AbstractRange.prototype.getTextRange(s) now return AbstractRange instead of the specific TextRange subclass

Other Changes

  • Remove some forwardDeclares from closure labs net.
  • Remove forwardDeclares from closure/graphics.
  • Remove forwardDeclare from closure/fs.
  • Linkify matching {} and () in URL like https://g\.com?res\{x=3\}
  • The functions allowed by the CSS sanitizer are now case insensitive.
  • Replace uses of goog.isArray in preparation for its removal
  • Remove special case for ie6-ie10 in nexttick.
  • Remove some forwardDeclares from closure/net.
  • Remove forwardDeclares from various Closure packages.