@homebound/beam 4.16.0 → 4.16.1

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.
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  Homebound's React component design system.
6
6
 
7
- _To see the latest designs, check out the [Figma](https://www.figma.com/file/aWUE4pPeUTgrYZ4vaTYZQU/%E2%9C%A8Beam-Design-System-Refresh?node-id=0%3A1) file._
7
+ _To see the latest designs, check out the [Figma](https://www.figma.com/design/62R8KiDklvgBBSH0mQGWHo/BEAM_27_LIBRARY?node-id=0-1&p=f&m=draw) file._
8
8
 
9
9
  ## Page layout shells
10
10
 
package/dist/index.cjs CHANGED
@@ -6789,6 +6789,22 @@ function shallowEqual(objA, objB) {
6789
6789
  if (typeof objA !== "object" || objA === null || typeof objB !== "object" || objB === null) {
6790
6790
  return false;
6791
6791
  }
6792
+ if (objA instanceof Map || objB instanceof Map) {
6793
+ if (!(objA instanceof Map && objB instanceof Map) || objA.size !== objB.size) return false;
6794
+ for (const [key, value] of objA) {
6795
+ if (!objB.has(key) || !Object.is(value, objB.get(key))) return false;
6796
+ }
6797
+ return true;
6798
+ }
6799
+ if (objA instanceof Set || objB instanceof Set) {
6800
+ if (!(objA instanceof Set && objB instanceof Set) || objA.size !== objB.size) return false;
6801
+ for (const value of objA) {
6802
+ if (!objB.has(value)) return false;
6803
+ }
6804
+ return true;
6805
+ }
6806
+ if (Array.isArray(objA) !== Array.isArray(objB)) return false;
6807
+ if (!Array.isArray(objA) && (!isPlainObject(objA) || !isPlainObject(objB))) return false;
6792
6808
  const keysA = Object.keys(objA);
6793
6809
  const keysB = Object.keys(objB);
6794
6810
  if (keysA.length !== keysB.length) {
@@ -6796,12 +6812,16 @@ function shallowEqual(objA, objB) {
6796
6812
  }
6797
6813
  for (let i = 0; i < keysA.length; i++) {
6798
6814
  const currentKey = keysA[i];
6799
- if (!objB.hasOwnProperty(currentKey) || !Object.is(objA[currentKey], objB[currentKey])) {
6815
+ if (!Object.prototype.hasOwnProperty.call(objB, currentKey) || !Object.is(objA[currentKey], objB[currentKey])) {
6800
6816
  return false;
6801
6817
  }
6802
6818
  }
6803
6819
  return true;
6804
6820
  }
6821
+ function isPlainObject(value) {
6822
+ const prototype = Object.getPrototypeOf(value);
6823
+ return prototype === Object.prototype || prototype === null;
6824
+ }
6805
6825
 
6806
6826
  // src/hooks/useComputed.ts
6807
6827
  function useComputed(fn, deps) {