Skip to content

Releases: google/playground-elements

v0.4.2

21 Jan 17:45
Compare
Choose a tag to compare

Added

  • Import maps are now supported. This allows customizing the URL that a bare
    module specifier resolves to, e.g. to a specific version, or to a different
    CDN.

    Note that import maps currently only apply to the immediate imports of
    project source files
    , not to external transitive dependencies.

    Also note scopes are not yet supported, only imports.

    See https://github.com/WICG/import-maps and
    https://wicg.github.io/import-maps/ for more information on import maps.

    Previously, all bare modules resolved to unpkg.com URLs at the latest version.
    This continues to be the fallback behavior if no import map is provided, or no
    entry in it matches.

    To specify an import map in a JSON project manifest, add an importMap
    property:

    {
      "files": {
        "index.html": {},
        "my-element.ts": {}
      },
      "importMap": {
        "imports": {
          "lit-html": "https://unpkg.com/lit-html@next-major",
          "lit-html/": "https://unpkg.com/lit-html@next-major/"
        }
      }
    }

    To specify an import map inline, add a <script type="sample/importmap">
    slotted child:

    <playground-ide>
      <script type="sample/importmap">
        {
          "imports": {
            "lit-html": "https://unpkg.com/lit-html@next-major",
            "lit-html/": "https://unpkg.com/lit-html@next-major/"
          }
        }
      </script>
      ...
    </playground-ide>

Fixed

  • Bare module imports in .js files are now resolved in the same way as .ts
    files.

v0.4.1

15 Jan 21:41
Compare
Choose a tag to compare

Fixed

  • Fixed <playground-file-editor> not always displaying initial file.
  • Fixed editable-file-system attribute name (was editableFileSystem).
  • Fixed <playground-ide> not stretching <playground-file-editor> vertically.

v0.4.0

15 Jan 21:41
Compare
Choose a tag to compare

Added

  • Added editableFileSystem property (editable-file-system attribute) to
    <playground-ide>. When true, the user will be able to create, delete, and
    rename files in the virtual filesystem.

    • To create a new file: click the "+" icon button in the tab bar.
    • To rename a file: click the three-dots menu button on its tab, and select
      "Rename".
    • To delete a file: click the three-dots menu button on its tab, and select
      "Delete".
  • Added <playground-file-system-controls> element which displays popup
    menus/dialogs for creating, deleting, and renaming files.

Changed

  • [BREAKING] The tab bar has been factored into a new standalone element
    called <playground-tab-bar>. The <playground-file-editor> element no
    longer integrates the tab bar, and the noFilePicker property has been
    removed.

  • [BREAKING] The following CSS custom properties have been renamed:

    • --playground-file-picker-background -> --playground-tab-bar-background
    • --playground-file-picker-foreground -> --playground-tab-bar-foreground
  • [BREAKING] The following CSS shadow parts have been renamed:

    • file-picker -> tab-bar

v0.3.7

08 Jan 18:54
1f5bc96
Compare
Choose a tag to compare

Added

  • Added files property to <playground-ide> and <playground-project>. Use
    this property to directly get and set the array of project files (e.g. to
    save/restore the project state).

    Note that directly setting files always takes precedence over setting
    projectSrc, and both take precedence over slotted children.

Changed

  • It is no longer necessary to load the Material Icons font. The reload button
    icon is now inlined SVG.

Fixed

  • Fix caret placement issues with some dynamic layouts.

v0.3.6

08 Dec 18:07
86c3b01
Compare
Choose a tag to compare

Fixed

  • Fix shifted/hidden code in Safari when line numbers are enabled.

v0.3.5

04 Dec 00:34
Compare
Choose a tag to compare

Fixed

  • Fix mwc-tab race condition bug (dependency version bump).

v0.3.4

03 Dec 22:14
Compare
Choose a tag to compare

Changed

  • The playground service worker now serves its own 404s when a file is not
    found, instead of forwarding the request to the server.

Fixed

  • Fix race condition where preview could load too early and 404.
  • Fix race condition where preview could sometimes never load.
  • Fix preview 404 that could occur after leaving page idle for some time.

v0.3.3

02 Dec 04:17
91a9839
Compare
Choose a tag to compare

Fixed

  • Fix Safari scrolling bug by limiting preview max-height.

v0.3.2

30 Nov 21:24
b353675
Compare
Choose a tag to compare

Fixed

  • Fix installation error relating to missing node_modules/puppeteer directory.

Changed

  • Bumped and un-pinned @material/mwc dependencies.

Removed

  • Removed some unnecessary files from NPM package.

v0.3.1

12 Nov 01:42
Compare
Choose a tag to compare

Fixed

  • Remove debugging log statement.
  • Remove unecessary file from NPM package.