Skip to content

Releases: Patternslib/Patterns

Release 9.8.2

24 Feb 09:14
Compare
Choose a tag to compare

9.8.2 (2023-02-24)

Release 9.8.2-alpha.0

14 Feb 16:09
Compare
Choose a tag to compare
Release 9.8.2-alpha.0 Pre-release
Pre-release

9.8.2-alpha.0 (2023-02-14)

Maintenance

Release 9.8.1

02 Feb 00:46
Compare
Choose a tag to compare

9.8.1 (2023-02-02)

Features

  • build: Update patternslib.com with each non-pre release. (143031d)

Bug Fixes

  • Build: Fix luxon (again) to 2.4.0 to avoid webpack MF error due to non standard package.json setup. (9661ae7)

  • pat checklist: Also set the "checked" and "unchecked" classes on the toggle checkbox. (8154775)

Release 9.8.1-alpha.0

25 Jan 20:01
Compare
Choose a tag to compare
Release 9.8.1-alpha.0 Pre-release
Pre-release

9.8.1-alpha.0 (2023-01-25)

Features

  • pat checklist: Toggle checkbox to toggle checked boxes true/false. (2a435fa)

Maintenance

  • Build: Upgrade dependencies. (7e7cc20)

  • pat-checklist: Document the available options. (625f7e5)

Release 9.8.0

23 Dec 16:38
Compare
Choose a tag to compare

9.8.0 (2022-12-23)

Breaking Changes

  • pat-validation: Remove error-template option. (78c544b)

    This is a breaking change.

    Due to a Content-Security-Policy problem with dom.template when unsafe-eval
    is not set - which you wouldn't set if possible - we had to remove the
    error-template parameter. Instead the template is now defined in a
    error_template method on the Patten class and can be customized by
    subclassing and extending the pat-validation pattern or by patching it via
    Pattern.prototype.

Features

  • pat-sortable: Support initialization after injection. (afaf388)

  • core events: Add dragstart and dragend event factories. (73d7fc7)

  • pat-sortable: Initialize sorting on cloned elements. (d7abbc0)

    Fix sorting behavior on cloned elements, which broke on Patternslib 9.8.0-alpha.0.

  • core basepattern: Add a destroy method. (f9ca65a)

    The destroy method removes the pattern instance from the element.
    This is necessary to re-initialize the same pattern on the same element.

  • core events: Support await_pattern_init with pattern double registration attempt. (e8640a9)

    When a pattern is tried to be initialized on the same element twice, throw
    an event and use that event in await_pattern_init to reject the promise.
    When using await_pattern_init you might want to try/catch the block to
    handle any possible double-registration errors.

  • core events: Support once-events in add_event_listener. (fc0e333)

    Add support for once-events in add_event_listener and unregister them when
    called from the event_listener_map.

  • Build: Include the build in the npm package. (544b589)

    The compiled build is now included in npm packages by including the dist
    directory in .npmignore. To not increase the package size too much the
    JavaScript map files are not included. Now you can include Patternslib by
    using unpkg or jsDelivr like so:

https://unpkg.com/@patternslib/patternslib@9.8.0-alpha.2/dist/bundle.min.js
or
https://cdn.jsdelivr.net/npm/@patternslib/patternslib@9.8.0-alpha.2/dist/bundle.min.js

  • core dom: Add is_input method. (554e32e)

    Add is_input to test if a element is of input type. This is basically the
    same as $(":input") from Sizzle/jQuery.

  • pat-markdown: Soft-depend on pat-syntax-highlight. (cf0f6e3)

    Only highlight code blocks when the pattern is available.

    Not hard-depending and importing pat-syntax-highlight fixes a problem where
    only including pat-markup also included pat-syntax-highlight and it's big
    highlight.js library.

    This can reduce the generated bundle size significantly.

  • pat-tooltip: Soft-depend on pat-markdown. (1f81238)

    Only register the markdown data type handler when the pattern is available.

    Not hard-depending and importing pat-markdown fixes a problem where only
    including pat-tooltip also included pat-markdown and pat-syntax-highlight
    with it's big highlight.js library.

    This can reduce the generated bundle size significantly.

  • core basepattern: Provide the parser as static attribute. (49db677)

    This change is backwards compatible Change the parser attribute to a static
    attribute and provide it also on the object. This change was necessary
    because pat-inject was using the parser on a registered Pattern class to
    rebase URL configurations in the rebaseHTML method. There was no access to
    the parser attribute on non-instatiated objects before, now it is.

  • pat-autosuggest: Add a configurable separator for multiple values. (21cbe8f)

Bug Fixes

  • pat-sortable: Initialize already existing sortable handles. (b3f5077)

    Also allow the sortable itself to be the handle.

  • pat-sortable: Show dragable item image while dragging. (1c9eb80)

  • pat-sortable: sortable-handle needs to be injected at last element of the sortable item. (db02541)

  • Build: Load modernizr early and non-asynchronously. (8bc9b66)

    Include the modernizr bundle by injecting a script tag. This ensures
    modernizr is loaded synchronously and executing early and sets it's feature
    detection classes before the layout is done by the browser.

    You can disable loading of modernizr by setting the following before the
    Patternslib bundle.min.js is included:

    <script>window.__patternslib_disable_modernizr = true;</script>

    Also, the "js" class is set on the HTML root tag when a "no-js" class was
    present regardless of the __patternslib_disable_modernizr setting.

    Since Patternslib 9.0.0-alpha.0 where we introduced webpack module
    federation for our bundles, Modernizr is loaded asynchronously and applying
    it's CSS classes a tick too late. For example, the change from the "no-js"
    to the "js" class was done while the tiles have already been drawn and
    visible on the screen, resulting in screen flickering. There are a number
    of projects which depend on Modernizr being applied early.

  • Build: Separate modernizr into a own bundle. (875b041)

  • Build: Also include necessary _sass directory in the npm package. (70da6b1)

  • Build: Also include the webpack configs in the npm package. (f6bf2bf)

    Previous packages depending on @patternslib/patternslib also extended
    Patternslib' webpack configs. Include these configs for backwards
    compatibility.

  • pat-bumper: Remove style import from the patterns SCSS file. (094010b)

  • pat-tooltip: Cleanup tooltip after it's destroyed. (ac27e20)

    When the tooltip is destroyed, also call the tooltip's BasePattern destroy
    method to clean up and release the tooltip from the element. After that it
    can be instantiated on the same element again. This change was necessary
    after the recent BasePattern change.

  • pat-validation: Make sure to cancel submit events on invalid forms. (e218af2)

    Make sure that submit events are canceled on invalid forms by using a
    capturing event handler which is invoked before non-capturing events.

    The previous commit exposed a problem with the submit event handling, where
    the then non-capturing submit event handler was registered later than the
    one from pat-inject because pat-validation's async init method where
    pat-inject's init method is yet non-async. That happened even the
    pat-validation's pattern initialization is enforced to run first due to
    registration reordering in the Pattern registry. Now with the capturing
    event handler this problem is fixed.

  • Build: Fix tiptap error. (6e67655)

    Fix tiptap "Unhandled Promise Rejection" error due to multiple versions of
    a tiptap dependency installed. Removing yarn.lock in re-installing solves
    this.

  • pat-clone-code: Fix a Content-Security-Policy problem. (e38f987)

    Do not use dom.template for the wrapper template to not get caught by the
    browser's Content-Security-Policy. If set, a unsafe-eval error would be
    thrown and the pattern refuse to run.

  • pat-bumper: Fix runtime error due to reference to wrong container. (893d392)

  • pat-collapsible: Class-based patterns cannot be jQuery plugins. (eedcc47)

  • pat-syntax-highlight:...

Read more

Release 9.8.0-beta.6

22 Dec 18:12
Compare
Choose a tag to compare
Release 9.8.0-beta.6 Pre-release
Pre-release

9.8.0-beta.6 (2022-12-22)

Bug Fixes

  • pat-sortable: Initialize already existing sortable handles. (b3f5077)Also allow the sortable itself to be the handle.

Release 9.8.0-beta.5

22 Dec 17:41
Compare
Choose a tag to compare
Release 9.8.0-beta.5 Pre-release
Pre-release

9.8.0-beta.5 (2022-12-22)

Features

  • pat-sortable: Support initialization after injection. (afaf388)

Release 9.8.0-beta.4

22 Dec 17:07
Compare
Choose a tag to compare
Release 9.8.0-beta.4 Pre-release
Pre-release

9.8.0-beta.4 (2022-12-22)

Bug Fixes

  • pat-sortable: Show dragable item image while dragging. (1c9eb80)

  • pat-sortable: sortable-handle needs to be injected at last element of the sortable item. (db02541)

Release 9.8.0-beta.3

22 Dec 14:18
Compare
Choose a tag to compare
Release 9.8.0-beta.3 Pre-release
Pre-release

9.8.0-beta.3 (2022-12-22)

Features

  • core events: Add dragstart and dragend event factories. (73d7fc7)

Bug Fixes

  • Build: Load modernizr early and non-asynchronously. (8bc9b66)Include the modernizr bundle by injecting a script tag. This ensures
    modernizr is loaded synchronously and executing early and sets it's
    feature detection classes before the layout is done by the browser.

This reverts the breaking change from the previous Patternslib 9.8.0-beta.2
release. The separate modernizr.min.js build file is still kept, but
modernizr is included by the main Patternslib bundle. There is no need
to add another script tag to include modernizr.

You can disable loading of modernizr by setting the following before the
Patternslib bundle.min.js is included:

<script>window.__patternslib_disable_modernizr = true;</script>

Also, the "js" class is set on the HTML root tag when a "no-js" class
was present regardless of the "__patternslib_disable_modernizr" setting.

Since Patternslib 9.0.0-alpha.0 where we introduced webpack module
federation for our bundles, Modernizr is loaded asynchronously and
applying it's CSS classes a tick too late. For example, the change from
the "no-js" to the "js" class was done while the tiles have already been
drawn and visible on the screen, resulting in screen flickering. There
are a number of projects which depend on Modernizr being applied early.

  • pat-sortable: Initialize sorting on cloned elements. (d7abbc0)Fix sorting behavior on cloned elements, which broke on Patternslib 9.8.0-alpha.0.

Maintenance

  • Build: Do not include the example minimalpattern in the build. (9712019)

  • Build: Remove now unused globals module. (8e05515)jQuery is now imported and set earlier.

  • Docs: Update some documentation. (4ccf1bd)

  • pat-sortable: Modernize tests. (bf25dc4)

Release 9.8.0-beta.2

20 Dec 00:01
Compare
Choose a tag to compare
Release 9.8.0-beta.2 Pre-release
Pre-release

9.8.0-beta.2 (2022-12-20)

Bug Fixes

  • Build: Also include necessary _sass directory in the npm package. (70da6b1)

  • Build: Also include the webpack configs in the npm package. (f6bf2bf)Previous packages depending on @patternslib/patternslib also extended
    Patternslib' webpack configs. Include these configs for backwards
    compatibility.

  • pat-bumper: Remove style import from the patterns SCSS file. (094010b)

Breaking Changes

  • Build: Separate modernizr into a own bundle. (875b041)Since Patternslib 9.0.0-alpha.0 where we introduced webpack module
    federation for our bundles, Modernizr is loaded asynchronously and
    applying it's CSS classes a tick too late. For example, the change from
    the no-js to the js class was done while the tiles have already been
    drawn and visible on the screen, resulting in screen flickering. There
    are a number of projects which depend on Modernizr being applied early.

This change now fixes the problem by separating the Modernizr build from
the Patternslib bundle.

If you depend on Modernzir, please include the new modernizr.min.js bundle in
a script tag, preferably before the Patternslib bundle bundle.min.js.

The global switch "window.__patternslib_disable_modernizr" is also removed, as
it got useless.

Maintenance

  • Add modernizr.min.js bundle to main index.js demo file for demonstration. (96a7ed2)

  • Build: Directly build the modernizr bundle. (ee2acdc)Do not use an webpack entry to build the modernizr bundle with an
    webpack runtime overhead. Instead, build it directly but abusing the
    webpack CopyPlugin transform mechanism. We could also build the
    modernizr bundle from the Makefile but that wouldn't provide the file
    when watching or when running webpack-dev-server.

  • Build: Optimize modernizr configuration. (e1fd8de)Remove unnecessary tests in .modernizrrc.js and slim down the build size.

  • Upgrade dependencies. Also Upgrade to jQuery 3.6.2. (071e084)