jazz-tools 0.14.0 → 0.14.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
 
2
- > jazz-tools@0.14.0 build /home/runner/_work/jazz/jazz/packages/jazz-tools
2
+ > jazz-tools@0.14.2 build /home/runner/_work/jazz/jazz/packages/jazz-tools
3
3
  > tsup && pnpm types
4
4
 
5
5
  CLI Building entry: {"index":"src/index.ts","testing":"src/testing.ts"}
@@ -10,13 +10,13 @@
10
10
  CLI Cleaning output folder
11
11
  ESM Build start
12
12
  ESM dist/index.js 11.03 KB
13
- ESM dist/testing.js 6.27 KB
14
- ESM dist/chunk-2ASOGEYA.js 130.46 KB
13
+ ESM dist/testing.js 6.31 KB
14
+ ESM dist/chunk-WLOZKDOH.js 130.46 KB
15
15
  ESM dist/index.js.map 20.74 KB
16
- ESM dist/testing.js.map 12.31 KB
17
- ESM dist/chunk-2ASOGEYA.js.map 304.16 KB
18
- ESM ⚡️ Build success in 52ms
16
+ ESM dist/testing.js.map 12.57 KB
17
+ ESM dist/chunk-WLOZKDOH.js.map 304.21 KB
18
+ ESM ⚡️ Build success in 104ms
19
19
 
20
- > jazz-tools@0.14.0 types /home/runner/_work/jazz/jazz/packages/jazz-tools
20
+ > jazz-tools@0.14.2 types /home/runner/_work/jazz/jazz/packages/jazz-tools
21
21
  > tsc --outDir dist
22
22
 
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # jazz-tools
2
2
 
3
+ ## 0.14.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 3d1027f: Make possible to extend a group without having access to it
8
+ - c240eed: Fix custom AccountSchema support in testing utils
9
+
10
+ ## 0.14.1
11
+
12
+ ### Patch Changes
13
+
14
+ - cdfc105: Make the profile access on Group members trigger updates correctly
15
+ - Updated dependencies [c8b33ad]
16
+ - cojson@0.14.1
17
+
3
18
  ## 0.14.0
4
19
 
5
20
  ### Minor Changes
@@ -2,13 +2,11 @@
2
2
  import { ControlledAccount, RawAccount } from "cojson";
3
3
  var CoValueBase = class {
4
4
  get _owner() {
5
- const owner = coValuesCache.get(
6
- this._raw.group,
7
- () => this._raw.group instanceof RawAccount ? anySchemaToCoSchema(RegisteredSchemas["Account"]).fromRaw(
8
- this._raw.group
9
- ) : RegisteredSchemas["Group"].fromRaw(this._raw.group)
10
- );
11
- return owner;
5
+ const schema = this._raw.group instanceof RawAccount ? RegisteredSchemas["Account"] : RegisteredSchemas["Group"];
6
+ return accessChildById(this, this._raw.group.id, {
7
+ ref: schema,
8
+ optional: false
9
+ });
12
10
  }
13
11
  /** @private */
14
12
  get _loadedAs() {
@@ -47,6 +45,9 @@ var CoValueBase = class {
47
45
  }
48
46
  /** @category Type Helpers */
49
47
  castAs(cl) {
48
+ if (this.constructor === cl) {
49
+ return this;
50
+ }
50
51
  return cl.fromRaw(this._raw);
51
52
  }
52
53
  };
@@ -4535,4 +4536,4 @@ export {
4535
4536
  JazzContextManager
4536
4537
  };
4537
4538
  /* istanbul ignore file -- @preserve */
4538
- //# sourceMappingURL=chunk-2ASOGEYA.js.map
4539
+ //# sourceMappingURL=chunk-WLOZKDOH.js.map