New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@genesislcap/foundation-utils

Package Overview
Dependencies
Maintainers
1
Versions
1142
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@genesislcap/foundation-utils - npm Package Compare versions

Comparing version 14.3.1-alpha-d0e4402.0 to 14.4.0

16

dist/dts/mixins/lifecycle/lifecycle.d.ts
import { Constructable, FASTElement } from '@microsoft/fast-element';
export type ConstructableLifecycleHandler = Constructable<FASTElement & HTMLElement>;
type Draggable = {
type FoundationLayoutContainer = {
dragging: boolean;
hasFirstLoaded: boolean;
_key: 'foundation-layout';
};
type LayoutCacheContainer = {
_key: 'foundation-layout-cache';
};
type DOMContainer = {
_key: 'dom';
};
type Container = FoundationLayoutContainer | LayoutCacheContainer | DOMContainer;
export declare const LifecycleMixin: <T extends ConstructableLifecycleHandler>(Base: T) => {
new (...args: any[]): {
"__#1@#_containingLayout": Draggable | null;
"__#1@#_container": Container;
cloneNode(deep?: boolean): Node;

@@ -13,3 +22,3 @@ deepClone(): Node;

readonly shouldRunConnect: boolean;
"__#1@#_tryFindContainingLayout"(e: Element): Draggable | null;
"__#1@#_tryFindContainingLayout"(e: Element): Container;
connectedCallback(): void;

@@ -329,3 +338,4 @@ readonly $fastController: import("@microsoft/fast-element").Controller;

} & T;
export declare const layoutCacheDocument: unique symbol;
export {};
//# sourceMappingURL=lifecycle.d.ts.map

30

dist/esm/mixins/lifecycle/lifecycle.js
import { __classPrivateFieldGet, __classPrivateFieldSet } from "tslib";
export const LifecycleMixin = (Base) => { var _instances, __containingLayout, __tryFindContainingLayout, _a; return _a = class extends Base {
export const LifecycleMixin = (Base) => { var _instances, __container, __tryFindContainingLayout, _a; return _a = class extends Base {
constructor(...args) {
super(args);
_instances.add(this);
__containingLayout.set(this, null);
__container.set(this, { _key: 'dom' });
}

@@ -23,5 +23,9 @@ cloneNode(deep) {

get shouldRunDisconnect() {
if (__classPrivateFieldGet(this, __containingLayout, "f") === null)
if (__classPrivateFieldGet(this, __container, "f")._key === 'dom') {
return true;
return !__classPrivateFieldGet(this, __containingLayout, "f").dragging;
}
if (__classPrivateFieldGet(this, __container, "f")._key === 'foundation-layout-cache') {
return false;
}
return !(__classPrivateFieldGet(this, __container, "f").dragging || !__classPrivateFieldGet(this, __container, "f").hasFirstLoaded);
}

@@ -33,16 +37,21 @@ get shouldRunConnect() {

super.connectedCallback();
if (__classPrivateFieldGet(this, __containingLayout, "f") === null) {
__classPrivateFieldSet(this, __containingLayout, __classPrivateFieldGet(this, _instances, "m", __tryFindContainingLayout).call(this, this), "f");
if (__classPrivateFieldGet(this, __container, "f")._key !== 'foundation-layout') {
__classPrivateFieldSet(this, __container, __classPrivateFieldGet(this, _instances, "m", __tryFindContainingLayout).call(this, this), "f");
}
}
},
__containingLayout = new WeakMap(),
__container = new WeakMap(),
_instances = new WeakSet(),
__tryFindContainingLayout = function __tryFindContainingLayout(e) {
if (e.getRootNode() instanceof Document || e.getRootNode() instanceof DocumentFragment) {
return null;
if (e.getRootNode()[layoutCacheDocument] === true) {
return { _key: 'foundation-layout-cache' };
}
if (e.getRootNode() instanceof Document) {
return { _key: 'dom' };
}
const shadowHost = e.getRootNode().host;
if (shadowHost.constructor.name === 'FoundationLayout') {
return shadowHost;
const layoutHost = shadowHost;
layoutHost._key = 'foundation-layout';
return layoutHost;
}

@@ -52,1 +61,2 @@ return __classPrivateFieldGet(this, _instances, "m", __tryFindContainingLayout).call(this, shadowHost);

_a; };
export const layoutCacheDocument = Symbol('layout-cache-document');
{
"name": "@genesislcap/foundation-utils",
"description": "Genesis Foundation Utils",
"version": "14.3.1-alpha-d0e4402.0",
"version": "14.4.0",
"sideEffects": false,

@@ -91,3 +91,3 @@ "license": "SEE LICENSE IN license.txt",

},
"gitHead": "4321a5bdc42370bb1d5731a0fba999fdedc0e8bb"
"gitHead": "faee66c559ee8763ae7bd4cc448b768d86391a41"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc