@totalsoft/rules-algebra-react 5.0.21 → 5.0.24

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,2 +1,4 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
1
3
  export * from './useRules';
2
4
  export * from './useRulesLens';
@@ -1,3 +1,5 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
1
3
  import { useState, useCallback, useMemo } from 'react';
2
4
  import { create, detectChanges, ensureArrayUIDsDeep, setInnerProp } from '@totalsoft/change-tracking';
3
5
  import { logTo, applyRule } from '@totalsoft/rules-algebra';
@@ -1,3 +1,5 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
1
3
  import { useStateLens, rmap, over } from '@totalsoft/react-state-lens';
2
4
  import { useMemo, useCallback, useState } from 'react';
3
5
  import { applyRule, logTo } from '@totalsoft/rules-algebra';
package/esm/index.js CHANGED
@@ -1,2 +1,4 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
1
3
  export * from './hooks';
2
4
  export * from "@totalsoft/react-state-lens/lensProxy";
package/hooks/index.d.ts CHANGED
@@ -1,3 +1,6 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
3
+
1
4
  import { Rule, Logger } from "@totalsoft/rules-algebra";
2
5
  import { DirtyInfo } from "@totalsoft/change-tracking";
3
6
  import { LensProxy } from "@totalsoft/react-state-lens";
package/hooks/index.js CHANGED
@@ -8,6 +8,7 @@ var _useRules = require("./useRules");
8
8
 
9
9
  Object.keys(_useRules).forEach(function (key) {
10
10
  if (key === "default" || key === "__esModule") return;
11
+ if (key in exports && exports[key] === _useRules[key]) return;
11
12
  Object.defineProperty(exports, key, {
12
13
  enumerable: true,
13
14
  get: function get() {
@@ -20,6 +21,7 @@ var _useRulesLens = require("./useRulesLens");
20
21
 
21
22
  Object.keys(_useRulesLens).forEach(function (key) {
22
23
  if (key === "default" || key === "__esModule") return;
24
+ if (key in exports && exports[key] === _useRulesLens[key]) return;
23
25
  Object.defineProperty(exports, key, {
24
26
  enumerable: true,
25
27
  get: function get() {
package/hooks/useRules.js CHANGED
@@ -17,6 +17,8 @@ var _changeTracking = require("@totalsoft/change-tracking");
17
17
 
18
18
  var _rulesAlgebra = require("@totalsoft/rules-algebra");
19
19
 
20
+ // Copyright (c) TotalSoft.
21
+ // This source code is licensed under the MIT license.
20
22
  function useRules(rules, initialModel) {
21
23
  var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},
22
24
  _ref$isLogEnabled = _ref.isLogEnabled,
@@ -19,6 +19,8 @@ var _rulesAlgebra = require("@totalsoft/rules-algebra");
19
19
 
20
20
  var _changeTracking = require("@totalsoft/change-tracking");
21
21
 
22
+ // Copyright (c) TotalSoft.
23
+ // This source code is licensed under the MIT license.
22
24
  function useRulesLens(rules, initialModel) {
23
25
  var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},
24
26
  _ref$isLogEnabled = _ref.isLogEnabled,
package/index.d.ts CHANGED
@@ -1,2 +1,5 @@
1
+ // Copyright (c) TotalSoft.
2
+ // This source code is licensed under the MIT license.
3
+
1
4
  export * from './hooks';
2
5
  export * from "@totalsoft/react-state-lens/lensProxy";
package/index.js CHANGED
@@ -8,6 +8,7 @@ var _hooks = require("./hooks");
8
8
 
9
9
  Object.keys(_hooks).forEach(function (key) {
10
10
  if (key === "default" || key === "__esModule") return;
11
+ if (key in exports && exports[key] === _hooks[key]) return;
11
12
  Object.defineProperty(exports, key, {
12
13
  enumerable: true,
13
14
  get: function get() {
@@ -20,6 +21,7 @@ var _lensProxy = require("@totalsoft/react-state-lens/lensProxy");
20
21
 
21
22
  Object.keys(_lensProxy).forEach(function (key) {
22
23
  if (key === "default" || key === "__esModule") return;
24
+ if (key in exports && exports[key] === _lensProxy[key]) return;
23
25
  Object.defineProperty(exports, key, {
24
26
  enumerable: true,
25
27
  get: function get() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@totalsoft/rules-algebra-react",
3
- "version": "5.0.21",
3
+ "version": "5.0.24",
4
4
  "description": "React extensions for the \"rules-algebra\" business rules api",
5
5
  "main": "./index.js",
6
6
  "author": "TotalSoft",
@@ -15,13 +15,13 @@
15
15
  "access": "public"
16
16
  },
17
17
  "dependencies": {
18
- "@totalsoft/change-tracking-react": "^5.0.21",
19
- "@totalsoft/rules-algebra": "^5.0.20"
18
+ "@totalsoft/change-tracking-react": "^5.0.24",
19
+ "@totalsoft/rules-algebra": "^5.0.22"
20
20
  },
21
21
  "peerDependencies": {
22
22
  "react": ">= 16.9.0"
23
23
  },
24
- "gitHead": "e12c3ffbc88f77b054e413cb1ae317438c9592dc",
24
+ "gitHead": "0c439bd88ad2698cf88d205c3d97bd8711cf31f0",
25
25
  "private": false,
26
26
  "module": "./esm/index.js",
27
27
  "typings": "./index.d.ts"