Skip to content

Releases: open-pioneer/trails-core-packages

@open-pioneer/[email protected]

22 Dec 10:00
a6f054e
Compare
Choose a tag to compare

Patch Changes

  • 11b1428: Export rethrowAbortError from core package and use it correctly in HttpService.

@open-pioneer/[email protected]

22 Dec 08:13
d7da0a1
Compare
Choose a tag to compare

Minor Changes

  • a18d227: New helper function rethrowAbortError.

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Patch Changes

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Major Changes

  • ce9e060: Remove support for closed shadow roots.
    Shadow roots used by trails applications are now always "open".
    See #19.

  • 6f954e3: Breaking Change: change how services integrate into TypeScript (fixes #22).
    The old TypeScript integration had unexpected edge cases, see the linked issue.

    NOTE: The changes below have no impact on runtime behavior, but they may trigger TypeScript errors in your code.

    • To register a service's type with TypeScript, one previously used a block such as this:

      // OLD! Can be removed
      import "@open-pioneer/runtime";
      declare module "@open-pioneer/runtime" {
          interface ServiceRegistry {
              "http.HttpService": HttpService;
          }
      }

      The new method requires the developer to change the service's declaration.
      Simply add extends DeclaredService<"SERVICE_ID"> to your service interface, where SERVICE_ID should match the service's interface name ("provides" in build.config.mjs).

      + import { DeclaredService } from "@open-pioneer/runtime";
      
      - export interface HttpService {
      + export interface HttpService extends DeclaredService<"http.HttpService"> {
      
      - import "@open-pioneer/runtime";
      - declare module "@open-pioneer/runtime" {
      -     interface ServiceRegistry {
      -         "http.HttpService": HttpService;
      -     }
      - }
    • To use a service from React code (i.e. useService and useServices), you must now use the explicit service type in the hook's generic parameter list. Otherwise the hook will simply return unknown:

      + import { HttpService } from "@open-pioneer/http";
      - const httpService = useService("http.HttpService");
      + const httpService = useService<HttpService>("http.HttpService");

      This change was necessary to fix an issue where the global registration of the service interface (and its association with the string constant) was not available.

      The system will still check that the provided string matches the string constant used in the service's declaration (DeclaredService<...>), so type safety is preserved.

    • The types InterfaceName and ServiceType<I> have been removed. Use explicit service interfaces instead.

    • The interfaces ServiceRegistry and PropertiesRegistry have been removed as global registration is no longer possible.

    • The type RawApplicationProperties has been removed. Use ApplicationProperties instead.

Patch Changes

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Major Changes

  • 6f954e3: Compatibility with @open-pioneer/runtime@^2

Patch Changes

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Major Changes

  • 6f954e3: Compatibility with @open-pioneer/runtime@^2

Patch Changes

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Patch Changes

  • f5c0e31: Bump chakra-related dependency versions

@open-pioneer/[email protected]

01 Dec 12:09
6619777
Compare
Choose a tag to compare

Minor Changes

  • 6f954e3: Compatibility with @open-pioneer/runtime@^2

Patch Changes

@open-pioneer/[email protected]

26 Sep 10:49
b2a79f9
Compare
Choose a tag to compare

Patch Changes

@open-pioneer/[email protected]

26 Sep 10:49
b2a79f9
Compare
Choose a tag to compare

Minor Changes

  • 6632892: Implement support for custom chakra themes via the theme parameter in createCustomElement().
    theme from @open-pioneer/base-theme is used as default when no other theme is configured.

Patch Changes