Skip to content

Releases: Patternslib/Patterns

Release 7.1.3

14 Mar 09:21
Compare
Choose a tag to compare

7.1.3 (2022-03-14)

Bug Fixes

  • core logging: Fix invalid use of typeof. (e2e992d)

Maintenance

Release 7.1.2

14 Mar 07:52
Compare
Choose a tag to compare

7.1.2 (2022-03-14)

Bug Fixes

  • pat validation: With depending date validation also validate the dependend date. (5060fa4), closes #970
    Fixes: #970

Maintenance

  • Build: Makefile - Resolve package version for ZIP bundle at target runtime. (2d799f8)

  • pat tabs: Fix test for error not thrown. (c4e00aa)
    Fix an UnhandledPromiseRejection error with an asynchronous test.
    The problem popped up in node version 16 and was passing in node version 14.

Release 7.1.1

16 Feb 22:02
Compare
Choose a tag to compare

7.1.1 (2022-02-16)

Features

  • core polyfills: Add polyfills module for modern browsers. (69402f6)
    Currently this holds a polyfill for SubmitEvent.submitter, which isn't available in Safari < 15.4 and jsDOM.

Bug Fixes

  • pat validation: Fix release 7.1.0. (3afb42b)
    The event-submitter-polyfill package isn't universally built.
    Let's use our new core/polyfills.js module instead and fix the previous release.

Release 7.1.0

16 Feb 20:07
Compare
Choose a tag to compare

7.1.0 (2022-02-16)

Features

  • core events: Standard JavaScript event factories - add "click" event. (8c7ce5f)

  • pat validation: Do not submit when a formnovalidate buttons was used. (35f4227)

  • pat validation: Set novalidation to pat-validation forms to prevent the browser's validation bubbles to appear. (a6a8188)

Bug Fixes

  • pat toggle: Don't let pat-toggle steal the click event and prevent double clicks. (8b75b8e)
    Do not let pat-toggle prevent the click event after it was catched.
    This makes pat-toggle work together with other Patterns, like pat-checklist.
    Also, when clicking on a label wrapping a checkbox, the checkbox also emits a click event which results in a unmodified toggle-state.
    Prevent double-clicks by debouncing and canceling events.

Maintenance

  • core events: Show behvavior of two click events emitted when clicking on a lable wrapping a checkbox. (259173f)

  • Dependencies: Upgrade dependencies. (6a7ea33)

  • pat toggle: Modernize code. (5a478a4)

  • pat validation: Demo - remove pat-validation type options. (d60e39b)

Release 7.0.2

15 Feb 10:14
Compare
Choose a tag to compare

7.0.2 (2022-02-15)

Bug Fixes

  • pat auto suggest: Fix issue with pat-auto-submit. (bbf5735)
    Also dispatch a input event after a value has changed to let auto-submit do a form submit.
    This fixes an issue introduced in Patternslib 7.0.0.
    Note: this will be revisited when reworking auto-submit and input-change-events for standard JavaScript event compatibility.

Maintenance

  • core events tests: Add jQuery vs native JavaScript events tests. (bb3a8e8)
    Add test showing that jQuery catches native events, but native listeners do not catch jQuery events.
    In the mid-term we want to switch to native-only to get rid of this difference.

  • Dependencies: Upgrade dependencies. (d5fd1ad)

  • pat auto submit: Cleanup code, improve tests. (8d289eb)

  • pat auto suggest: Improve and extend tests. (d4d2e99)

Release 7.0.1

08 Feb 16:53
Compare
Choose a tag to compare

7.0.1 (2022-02-08)

Bug Fixes

  • Build: Use public_path script while also having publicPath set to auto. (b8dfdbd)
    We still need to use the src/public_path.js script as first import in our bundles to correctly resolve the loading path for chunks.
    publicPath set to auto does not work in certain environments (e.g. the Plone resource registry).

Partially reverts 1b61431, "Use automatic publicPath determination instead of manually setting it."

Maintenance

  • build: Add and expose a "install" target alias to the Makefile as an alias to stamp-yarn. (e204037)

  • build: Remove unnecessary double-colon from targets. (070e4d9)

  • Cleanup: Remove reference to moment-timezone-with-data in .eslintrc - a file which was removed some time ago. (5de91cc)

  • Cleanup: Restructure package.json entries to move less relevant info down. (a25043b)

  • Docs: Update developer styleguide with simpler commit message scope naming guidelines. (1b391cb)

  • Change the bundle name whichis uploaded to the GitHub release page from patternslib-VERSION.zip to patternslib-bundle-VERSION.zip to better distinguish it from the automatically created Patterns-VERSION.zip source distribution. (c489a8c)

  • pat validation: Test and demo validation of datetime-local. (dc58887)

Release 7.0.0

28 Jan 14:03
Compare
Choose a tag to compare

7.0.0 (2022-01-28)

Features

  • core dom: Hide method: also set hidden attribute for better semantics. (379e4a9)

  • core events: Standard JavaScript event factories - add "scroll" event. (949b1dc)

  • core events: Standard JavaScript event factories. (951084f)
    Provide a library with standard JavaScript event factories, beginning with changed and submit events.

  • pat scroll-box: Allow detection of scroll-stop. (b226aeb)
    Add scrolling-up and scrolling-down classes which will be removed after the user has stopped scrolling.
    This allows for detection of a scrolling situation vs non-scrolling situation.

  • pat scroll-box: Optimize performance. (9caf2be)
    Optimize performance by grouping together DOM manipulation calls.
    The browser is now able to better optimize the code in regard to the reflow/repaint cycles.
    Also see: https://areknawo.com/dom-performance-case-study/

  • pat validation: Allow to define a custom error template. (986a092)

Bug Fixes

  • pat auto suggest: Do not change input field to type "hidden". (ab12b36)
    Don't change the date field to a hidden field which would prevent it from validation.
    Instead just hide it.
    Also, do this not in the transform method but on initialization.

  • pat auto suggest: Instead of searching for a reset button, listen on the form's reset event for clearing the data. (cd69e92)

  • pat auto suggest: Invoke standard JS change event. (31da974)
    Work around the situation that a jQuery "change" event, submitted by select2, isn't caught by pat-validation.
    Select2 also triggers a click event, which we will use here to trigger a standard JS change event.

  • pat date picker: Do not change input field to type "hidden". (66f4333)
    Don't change the date field to a hidden field which would prevent it from validation.
    Instead just hide it.
    Also disable click on label as this would focus/click-forward to the invisible input field and invokes some weird behavior.

  • pat scroll-box: Immediately and correctly set CSS classes. (7e7fd23)
    Fix pat-scroll-box to immediately and correctly set the CSS classes by using requestAnimationFrame instead timeouts.

Breaking Changes

  • core dom create_from_string: Change create_from_string to be able to create multiple siblings from a string. (062991c)
    Returns now a DocumentFragment instead of a single DOM node.
    This method wasn't used in Patternslib or any of the core addons.
    If you used it and it breaks your code, let me know.
  • core events: Move add_event_listener and remove_event_listener to core.events. (661b74c)
    Move add_event_listener and remove_event_listener from core.dom to core.events.
    Provide backwards compatibility imports in core.dom.
    Those imports will be removed in an upcoming version.
  • pat validation: Refactor pat-validation for full HTML5 compatibility. (9999c8f)
  • Use the Web API validation framework.

  • Define custom errors with the Web API method setCustomValidity (e.g. the custom error for the start date not being after the end date with the not not-after option).

  • Make use and set the Web API validityState according to validity of the form inputs.

  • Making use of the Web API validation framework allows to use the :invalid and :valid CSS selevtors - including for those inpyts with custom validity messages.

  • Validate the form on input, change, blur and submit events but make sure only one is run at once.

  • Remove default validation error messages from the configuration.
    If no validation message is defined the browser will show a default validation message, already translated into the language of the browser.

  • Remove configuration option type.
    Use the type attribute of the input element instead. For a date field, use date.
    For integer just use number.
    If you want to support real, floating numbers, use step="any" or a real number as step size.

  • Remove dependency on validate.js.

Maintenance

  • Remove unused core/scroll_detection.js. (19779d2)

  • core parser: Minimal code simplification. (3c28bb2)

  • dependencies: Remove now unused dependency on validate.js. (d698930)

  • dependencies: Update browserslist database / caniuse-lite. (60ac00f)

  • dependencies: Upgrade dependencies. (9f0d41f)

  • docs: Add improve JSDoc strings a bit. (5f0f6ec)

  • pat ajax: Modernize code. (3953112)

  • tests: Use global instead of window in node based tools like Jest for registering global variables. (634325c)

  • Use caching in GitHub actions. (504e342)

Release 6.4.0

24 Jan 22:34
Compare
Choose a tag to compare

6.4.0 (2022-01-24)

Features

  • webpack: Add source maps for production and development builds. (5c720a4)
    We are using a faster source map generation option with good results for
    development builds.
  • webpack: Only minimize in production mode. (a6cf125)
    Compile development and production bundles with the name bundle.min.js.
    This allows to get rid to adapt the script name in production and development - both modes use the same name.
    However, it's only minified in production mode.
    We think the name .min.js also fits the development bundle as it is still babel-transpiled and webpack compiled.

Maintenance

  • docs: Improve documentation on how to use the polyfills loader. (11339af)

  • webpack: Use automatic publicPath determination instead of manually setting it. (1b61431)

Release 6.3.2

22 Dec 15:51
Compare
Choose a tag to compare

6.3.2 (2021-12-22)

Bug Fixes

  • pat inject: autoload-visible only when in viewport. (49863b7)
    Fix autload-visible trigger to only load the injection if the element is in the viewport.
    As before, this check is done after 100ms.
    This prevents loading items when we quickly scoll across them, like with href-section-jumps.

Maintenance

  • dependencies: Upgrade dependencies. (bd1ba37)

Release 6.3.1

21 Dec 00:07
Compare
Choose a tag to compare

6.3.1 (2021-12-21)

Bug Fixes

  • pat gallery: Correctly re-use existing default templates. (5191041)

  • pat gallery: Do not reinitialize gallery image sizes too often. (1f1e4d4)

Maintenance

  • dependencies: Upgrade up to minor versions. (b0d2177)

  • pat gallery: Add demo/test case for extending the pat-gallery page with itself. (433a95a)

  • pat gallery: Factor out get_template so that it can be overwritten in subclasses. (5341141)

  • pat gallery: Remove redundant preventDefault. (8a341aa)

  • pat inject: Minor documentation fix. (3b091b8)