Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@lit-labs/react

Package Overview
Dependencies
Maintainers
9
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lit-labs/react - npm Package Compare versions

Comparing version 1.0.8 to 1.0.9

20

create-component.d.ts

@@ -7,16 +7,16 @@ /**

/// <reference types="react" />
declare type Constructor<T> = {
new (): T;
};
/***
* Typecast that curries an Event type through a string. The goal of the type
* cast is to match a prop name to a typed event callback.
*/
export declare type EventName<T extends Event = Event> = string & {
__event_type: T;
};
declare type Events = Record<string, EventName | string>;
declare type EventProps<R extends Events> = {
declare type EventNames = Record<string, EventName | string>;
declare type EventListeners<R extends EventNames> = {
[K in keyof R]: R[K] extends EventName ? (e: R[K]['__event_type']) => void : (e: Event) => void;
};
declare type ReactProps<I, E> = Omit<React.HTMLAttributes<I>, keyof E>;
declare type ElementWithoutPropsOrEventListeners<I, E> = Omit<I, keyof E | keyof ReactProps<I, E>>;
declare type WebComponentProps<I extends HTMLElement, E extends EventNames = {}> = Partial<ReactProps<I, E> & ElementWithoutPropsOrEventListeners<I, E> & EventListeners<E>>;
export declare type ReactWebComponent<I extends HTMLElement, E extends EventNames = {}> = React.ForwardRefExoticComponent<React.PropsWithoutRef<WebComponentProps<I, E>> & React.RefAttributes<I>>;
declare type Constructor<T> = {
new (): T;
};
/**

@@ -43,4 +43,4 @@ * Creates a React component for a custom element. Properties are distinguished

*/
export declare const createComponent: <I extends HTMLElement, E extends Events = {}>(React: typeof import("react"), tagName: string, elementClass: Constructor<I>, events?: E | undefined, displayName?: string) => import("react").ForwardRefExoticComponent<import("react").PropsWithoutRef<Partial<Omit<import("react").HTMLAttributes<I>, keyof E> & Omit<I, keyof E | Exclude<"children", keyof E> | Exclude<"style", keyof E> | Exclude<"className", keyof E> | Exclude<"slot", keyof E> | Exclude<"title", keyof E> | Exclude<"defaultChecked", keyof E> | Exclude<"defaultValue", keyof E> | Exclude<"suppressContentEditableWarning", keyof E> | Exclude<"suppressHydrationWarning", keyof E> | Exclude<"accessKey", keyof E> | Exclude<"contentEditable", keyof E> | Exclude<"contextMenu", keyof E> | Exclude<"dir", keyof E> | Exclude<"draggable", keyof E> | Exclude<"hidden", keyof E> | Exclude<"id", keyof E> | Exclude<"lang", keyof E> | Exclude<"placeholder", keyof E> | Exclude<"spellCheck", keyof E> | Exclude<"tabIndex", keyof E> | Exclude<"translate", keyof E> | Exclude<"radioGroup", keyof E> | Exclude<"role", keyof E> | Exclude<"about", keyof E> | Exclude<"datatype", keyof E> | Exclude<"inlist", keyof E> | Exclude<"prefix", keyof E> | Exclude<"property", keyof E> | Exclude<"resource", keyof E> | Exclude<"typeof", keyof E> | Exclude<"vocab", keyof E> | Exclude<"autoCapitalize", keyof E> | Exclude<"autoCorrect", keyof E> | Exclude<"autoSave", keyof E> | Exclude<"color", keyof E> | Exclude<"itemProp", keyof E> | Exclude<"itemScope", keyof E> | Exclude<"itemType", keyof E> | Exclude<"itemID", keyof E> | Exclude<"itemRef", keyof E> | Exclude<"results", keyof E> | Exclude<"security", keyof E> | Exclude<"unselectable", keyof E> | Exclude<"inputMode", keyof E> | Exclude<"is", keyof E> | Exclude<"aria-activedescendant", keyof E> | Exclude<"aria-atomic", keyof E> | Exclude<"aria-autocomplete", keyof E> | Exclude<"aria-busy", keyof E> | Exclude<"aria-checked", keyof E> | Exclude<"aria-colcount", keyof E> | Exclude<"aria-colindex", keyof E> | Exclude<"aria-colspan", keyof E> | Exclude<"aria-controls", keyof E> | Exclude<"aria-current", keyof E> | Exclude<"aria-describedby", keyof E> | Exclude<"aria-details", keyof E> | Exclude<"aria-disabled", keyof E> | Exclude<"aria-dropeffect", keyof E> | Exclude<"aria-errormessage", keyof E> | Exclude<"aria-expanded", keyof E> | Exclude<"aria-flowto", keyof E> | Exclude<"aria-grabbed", keyof E> | Exclude<"aria-haspopup", keyof E> | Exclude<"aria-hidden", keyof E> | Exclude<"aria-invalid", keyof E> | Exclude<"aria-keyshortcuts", keyof E> | Exclude<"aria-label", keyof E> | Exclude<"aria-labelledby", keyof E> | Exclude<"aria-level", keyof E> | Exclude<"aria-live", keyof E> | Exclude<"aria-modal", keyof E> | Exclude<"aria-multiline", keyof E> | Exclude<"aria-multiselectable", keyof E> | Exclude<"aria-orientation", keyof E> | Exclude<"aria-owns", keyof E> | Exclude<"aria-placeholder", keyof E> | Exclude<"aria-posinset", keyof E> | Exclude<"aria-pressed", keyof E> | Exclude<"aria-readonly", keyof E> | Exclude<"aria-relevant", keyof E> | Exclude<"aria-required", keyof E> | Exclude<"aria-roledescription", keyof E> | Exclude<"aria-rowcount", keyof E> | Exclude<"aria-rowindex", keyof E> | Exclude<"aria-rowspan", keyof E> | Exclude<"aria-selected", keyof E> | Exclude<"aria-setsize", keyof E> | Exclude<"aria-sort", keyof E> | Exclude<"aria-valuemax", keyof E> | Exclude<"aria-valuemin", keyof E> | Exclude<"aria-valuenow", keyof E> | Exclude<"aria-valuetext", keyof E> | Exclude<"dangerouslySetInnerHTML", keyof E> | Exclude<"onCopy", keyof E> | Exclude<"onCopyCapture", keyof E> | Exclude<"onCut", keyof E> | Exclude<"onCutCapture", keyof E> | Exclude<"onPaste", keyof E> | Exclude<"onPasteCapture", keyof E> | Exclude<"onCompositionEnd", keyof E> | Exclude<"onCompositionEndCapture", keyof E> | Exclude<"onCompositionStart", keyof E> | Exclude<"onCompositionStartCapture", keyof E> | Exclude<"onCompositionUpdate", keyof E> | Exclude<"onCompositionUpdateCapture", keyof E> | Exclude<"onFocus", keyof E> | Exclude<"onFocusCapture", keyof E> | Exclude<"onBlur", keyof E> | Exclude<"onBlurCapture", keyof E> | Exclude<"onChange", keyof E> | Exclude<"onChangeCapture", keyof E> | Exclude<"onBeforeInput", keyof E> | Exclude<"onBeforeInputCapture", keyof E> | Exclude<"onInput", keyof E> | Exclude<"onInputCapture", keyof E> | Exclude<"onReset", keyof E> | Exclude<"onResetCapture", keyof E> | Exclude<"onSubmit", keyof E> | Exclude<"onSubmitCapture", keyof E> | Exclude<"onInvalid", keyof E> | Exclude<"onInvalidCapture", keyof E> | Exclude<"onLoad", keyof E> | Exclude<"onLoadCapture", keyof E> | Exclude<"onError", keyof E> | Exclude<"onErrorCapture", keyof E> | Exclude<"onKeyDown", keyof E> | Exclude<"onKeyDownCapture", keyof E> | Exclude<"onKeyPress", keyof E> | Exclude<"onKeyPressCapture", keyof E> | Exclude<"onKeyUp", keyof E> | Exclude<"onKeyUpCapture", keyof E> | Exclude<"onAbort", keyof E> | Exclude<"onAbortCapture", keyof E> | Exclude<"onCanPlay", keyof E> | Exclude<"onCanPlayCapture", keyof E> | Exclude<"onCanPlayThrough", keyof E> | Exclude<"onCanPlayThroughCapture", keyof E> | Exclude<"onDurationChange", keyof E> | Exclude<"onDurationChangeCapture", keyof E> | Exclude<"onEmptied", keyof E> | Exclude<"onEmptiedCapture", keyof E> | Exclude<"onEncrypted", keyof E> | Exclude<"onEncryptedCapture", keyof E> | Exclude<"onEnded", keyof E> | Exclude<"onEndedCapture", keyof E> | Exclude<"onLoadedData", keyof E> | Exclude<"onLoadedDataCapture", keyof E> | Exclude<"onLoadedMetadata", keyof E> | Exclude<"onLoadedMetadataCapture", keyof E> | Exclude<"onLoadStart", keyof E> | Exclude<"onLoadStartCapture", keyof E> | Exclude<"onPause", keyof E> | Exclude<"onPauseCapture", keyof E> | Exclude<"onPlay", keyof E> | Exclude<"onPlayCapture", keyof E> | Exclude<"onPlaying", keyof E> | Exclude<"onPlayingCapture", keyof E> | Exclude<"onProgress", keyof E> | Exclude<"onProgressCapture", keyof E> | Exclude<"onRateChange", keyof E> | Exclude<"onRateChangeCapture", keyof E> | Exclude<"onSeeked", keyof E> | Exclude<"onSeekedCapture", keyof E> | Exclude<"onSeeking", keyof E> | Exclude<"onSeekingCapture", keyof E> | Exclude<"onStalled", keyof E> | Exclude<"onStalledCapture", keyof E> | Exclude<"onSuspend", keyof E> | Exclude<"onSuspendCapture", keyof E> | Exclude<"onTimeUpdate", keyof E> | Exclude<"onTimeUpdateCapture", keyof E> | Exclude<"onVolumeChange", keyof E> | Exclude<"onVolumeChangeCapture", keyof E> | Exclude<"onWaiting", keyof E> | Exclude<"onWaitingCapture", keyof E> | Exclude<"onAuxClick", keyof E> | Exclude<"onAuxClickCapture", keyof E> | Exclude<"onClick", keyof E> | Exclude<"onClickCapture", keyof E> | Exclude<"onContextMenu", keyof E> | Exclude<"onContextMenuCapture", keyof E> | Exclude<"onDoubleClick", keyof E> | Exclude<"onDoubleClickCapture", keyof E> | Exclude<"onDrag", keyof E> | Exclude<"onDragCapture", keyof E> | Exclude<"onDragEnd", keyof E> | Exclude<"onDragEndCapture", keyof E> | Exclude<"onDragEnter", keyof E> | Exclude<"onDragEnterCapture", keyof E> | Exclude<"onDragExit", keyof E> | Exclude<"onDragExitCapture", keyof E> | Exclude<"onDragLeave", keyof E> | Exclude<"onDragLeaveCapture", keyof E> | Exclude<"onDragOver", keyof E> | Exclude<"onDragOverCapture", keyof E> | Exclude<"onDragStart", keyof E> | Exclude<"onDragStartCapture", keyof E> | Exclude<"onDrop", keyof E> | Exclude<"onDropCapture", keyof E> | Exclude<"onMouseDown", keyof E> | Exclude<"onMouseDownCapture", keyof E> | Exclude<"onMouseEnter", keyof E> | Exclude<"onMouseLeave", keyof E> | Exclude<"onMouseMove", keyof E> | Exclude<"onMouseMoveCapture", keyof E> | Exclude<"onMouseOut", keyof E> | Exclude<"onMouseOutCapture", keyof E> | Exclude<"onMouseOver", keyof E> | Exclude<"onMouseOverCapture", keyof E> | Exclude<"onMouseUp", keyof E> | Exclude<"onMouseUpCapture", keyof E> | Exclude<"onSelect", keyof E> | Exclude<"onSelectCapture", keyof E> | Exclude<"onTouchCancel", keyof E> | Exclude<"onTouchCancelCapture", keyof E> | Exclude<"onTouchEnd", keyof E> | Exclude<"onTouchEndCapture", keyof E> | Exclude<"onTouchMove", keyof E> | Exclude<"onTouchMoveCapture", keyof E> | Exclude<"onTouchStart", keyof E> | Exclude<"onTouchStartCapture", keyof E> | Exclude<"onPointerDown", keyof E> | Exclude<"onPointerDownCapture", keyof E> | Exclude<"onPointerMove", keyof E> | Exclude<"onPointerMoveCapture", keyof E> | Exclude<"onPointerUp", keyof E> | Exclude<"onPointerUpCapture", keyof E> | Exclude<"onPointerCancel", keyof E> | Exclude<"onPointerCancelCapture", keyof E> | Exclude<"onPointerEnter", keyof E> | Exclude<"onPointerEnterCapture", keyof E> | Exclude<"onPointerLeave", keyof E> | Exclude<"onPointerLeaveCapture", keyof E> | Exclude<"onPointerOver", keyof E> | Exclude<"onPointerOverCapture", keyof E> | Exclude<"onPointerOut", keyof E> | Exclude<"onPointerOutCapture", keyof E> | Exclude<"onGotPointerCapture", keyof E> | Exclude<"onGotPointerCaptureCapture", keyof E> | Exclude<"onLostPointerCapture", keyof E> | Exclude<"onLostPointerCaptureCapture", keyof E> | Exclude<"onScroll", keyof E> | Exclude<"onScrollCapture", keyof E> | Exclude<"onWheel", keyof E> | Exclude<"onWheelCapture", keyof E> | Exclude<"onAnimationStart", keyof E> | Exclude<"onAnimationStartCapture", keyof E> | Exclude<"onAnimationEnd", keyof E> | Exclude<"onAnimationEndCapture", keyof E> | Exclude<"onAnimationIteration", keyof E> | Exclude<"onAnimationIterationCapture", keyof E> | Exclude<"onTransitionEnd", keyof E> | Exclude<"onTransitionEndCapture", keyof E>> & EventProps<E>>> & import("react").RefAttributes<unknown>>;
export declare const createComponent: <I extends HTMLElement, E extends EventNames = {}>(React: typeof import("react"), tagName: string, elementClass: Constructor<I>, events?: E | undefined, displayName?: string) => ReactWebComponent<I, E>;
export {};
//# sourceMappingURL=create-component.d.ts.map

@@ -6,3 +6,3 @@ /**

*/
const t=new Set(["children","localName","ref","style","className"]),e=new WeakMap,n=(t,n,s,i,o)=>{const l=null==o?void 0:o[n];void 0!==l?s!==i&&((t,n,s)=>{let i=e.get(t);void 0===i&&e.set(t,i=new Map);let o=i.get(n);void 0!==s?void 0===o?(i.set(n,o={handleEvent:s}),t.addEventListener(n,o)):o.handleEvent=s:void 0!==o&&(i.delete(n),t.removeEventListener(n,o))})(t,l,s):t[n]=s},s=(e,s,i,o,l)=>{const d=e.Component,c=e.createElement,h=new Set(Object.keys(null!=o?o:{}));class r extends d{constructor(){super(...arguments),this.o=null}t(t){if(null!==this.o)for(const e in this.i)n(this.o,e,this.props[e],t?t[e]:void 0,o)}componentDidMount(){this.t()}componentDidUpdate(t){this.t(t)}render(){const e=this.props._$Gl;void 0!==this.h&&this.u===e||(this.h=t=>{null===this.o&&(this.o=t),null!==e&&((t,e)=>{"function"==typeof t?t(e):t.current=e})(e,t),this.u=e});const n={ref:this.h};this.i={};for(const[e,s]of Object.entries(this.props))"__forwardedRef"!==e&&(h.has(e)||!t.has(e)&&!(e in HTMLElement.prototype)&&e in i.prototype?this.i[e]=s:n["className"===e?"class":e]=s);return c(s,n)}}r.displayName=null!=l?l:i.name;const a=e.forwardRef(((t,e)=>c(r,{...t,_$Gl:e},null==t?void 0:t.children)));return a.displayName=r.displayName,a};export{s as createComponent};
const t=new Set(["children","localName","ref","style","className"]),n=new WeakMap,e=(t,e,i,s,o)=>{const l=null==o?void 0:o[e];void 0!==l?i!==s&&((t,e,i)=>{let s=n.get(t);void 0===s&&n.set(t,s=new Map);let o=s.get(e);void 0!==i?void 0===o?(s.set(e,o={handleEvent:i}),t.addEventListener(e,o)):o.handleEvent=i:void 0!==o&&(s.delete(e),t.removeEventListener(e,o))})(t,l,i):t[e]=i},i=(n,i,s,o,l)=>{const d=n.Component,c=n.createElement,h=new Set(Object.keys(null!=o?o:{}));class r extends d{constructor(){super(...arguments),this.o=null}t(t){if(null!==this.o)for(const n in this.i)e(this.o,n,this.props[n],t?t[n]:void 0,o)}componentDidMount(){this.t()}componentDidUpdate(t){this.t(t)}render(){var n;const e=null!==(n=this.props._$Gl)&&void 0!==n?n:null;void 0!==this.h&&this.u===e||(this.h=t=>{null===this.o&&(this.o=t),null!==e&&((t,n)=>{"function"==typeof t?t(n):t.current=n})(e,t),this.u=e});const o={ref:this.h};this.i={};for(const[n,e]of Object.entries(this.props))"__forwardedRef"!==n&&(h.has(n)||!t.has(n)&&!(n in HTMLElement.prototype)&&n in s.prototype?this.i[n]=e:o["className"===n?"class":n]=e);return c(i,o)}}r.displayName=null!=l?l:s.name;const u=n.forwardRef(((t,n)=>c(r,{...t,_$Gl:n},null==t?void 0:t.children)));return u.displayName=r.displayName,u};export{i as createComponent};
//# sourceMappingURL=create-component.js.map

@@ -7,16 +7,16 @@ /**

/// <reference types="react" />
declare type Constructor<T> = {
new (): T;
};
/***
* Typecast that curries an Event type through a string. The goal of the type
* cast is to match a prop name to a typed event callback.
*/
export declare type EventName<T extends Event = Event> = string & {
__event_type: T;
};
declare type Events = Record<string, EventName | string>;
declare type EventProps<R extends Events> = {
declare type EventNames = Record<string, EventName | string>;
declare type EventListeners<R extends EventNames> = {
[K in keyof R]: R[K] extends EventName ? (e: R[K]['__event_type']) => void : (e: Event) => void;
};
declare type ReactProps<I, E> = Omit<React.HTMLAttributes<I>, keyof E>;
declare type ElementWithoutPropsOrEventListeners<I, E> = Omit<I, keyof E | keyof ReactProps<I, E>>;
declare type WebComponentProps<I extends HTMLElement, E extends EventNames = {}> = Partial<ReactProps<I, E> & ElementWithoutPropsOrEventListeners<I, E> & EventListeners<E>>;
export declare type ReactWebComponent<I extends HTMLElement, E extends EventNames = {}> = React.ForwardRefExoticComponent<React.PropsWithoutRef<WebComponentProps<I, E>> & React.RefAttributes<I>>;
declare type Constructor<T> = {
new (): T;
};
/**

@@ -43,4 +43,4 @@ * Creates a React component for a custom element. Properties are distinguished

*/
export declare const createComponent: <I extends HTMLElement, E extends Events = {}>(React: typeof import("react"), tagName: string, elementClass: Constructor<I>, events?: E | undefined, displayName?: string) => import("react").ForwardRefExoticComponent<import("react").PropsWithoutRef<Partial<Omit<import("react").HTMLAttributes<I>, keyof E> & Omit<I, keyof E | Exclude<"children", keyof E> | Exclude<"style", keyof E> | Exclude<"className", keyof E> | Exclude<"slot", keyof E> | Exclude<"title", keyof E> | Exclude<"defaultChecked", keyof E> | Exclude<"defaultValue", keyof E> | Exclude<"suppressContentEditableWarning", keyof E> | Exclude<"suppressHydrationWarning", keyof E> | Exclude<"accessKey", keyof E> | Exclude<"contentEditable", keyof E> | Exclude<"contextMenu", keyof E> | Exclude<"dir", keyof E> | Exclude<"draggable", keyof E> | Exclude<"hidden", keyof E> | Exclude<"id", keyof E> | Exclude<"lang", keyof E> | Exclude<"placeholder", keyof E> | Exclude<"spellCheck", keyof E> | Exclude<"tabIndex", keyof E> | Exclude<"translate", keyof E> | Exclude<"radioGroup", keyof E> | Exclude<"role", keyof E> | Exclude<"about", keyof E> | Exclude<"datatype", keyof E> | Exclude<"inlist", keyof E> | Exclude<"prefix", keyof E> | Exclude<"property", keyof E> | Exclude<"resource", keyof E> | Exclude<"typeof", keyof E> | Exclude<"vocab", keyof E> | Exclude<"autoCapitalize", keyof E> | Exclude<"autoCorrect", keyof E> | Exclude<"autoSave", keyof E> | Exclude<"color", keyof E> | Exclude<"itemProp", keyof E> | Exclude<"itemScope", keyof E> | Exclude<"itemType", keyof E> | Exclude<"itemID", keyof E> | Exclude<"itemRef", keyof E> | Exclude<"results", keyof E> | Exclude<"security", keyof E> | Exclude<"unselectable", keyof E> | Exclude<"inputMode", keyof E> | Exclude<"is", keyof E> | Exclude<"aria-activedescendant", keyof E> | Exclude<"aria-atomic", keyof E> | Exclude<"aria-autocomplete", keyof E> | Exclude<"aria-busy", keyof E> | Exclude<"aria-checked", keyof E> | Exclude<"aria-colcount", keyof E> | Exclude<"aria-colindex", keyof E> | Exclude<"aria-colspan", keyof E> | Exclude<"aria-controls", keyof E> | Exclude<"aria-current", keyof E> | Exclude<"aria-describedby", keyof E> | Exclude<"aria-details", keyof E> | Exclude<"aria-disabled", keyof E> | Exclude<"aria-dropeffect", keyof E> | Exclude<"aria-errormessage", keyof E> | Exclude<"aria-expanded", keyof E> | Exclude<"aria-flowto", keyof E> | Exclude<"aria-grabbed", keyof E> | Exclude<"aria-haspopup", keyof E> | Exclude<"aria-hidden", keyof E> | Exclude<"aria-invalid", keyof E> | Exclude<"aria-keyshortcuts", keyof E> | Exclude<"aria-label", keyof E> | Exclude<"aria-labelledby", keyof E> | Exclude<"aria-level", keyof E> | Exclude<"aria-live", keyof E> | Exclude<"aria-modal", keyof E> | Exclude<"aria-multiline", keyof E> | Exclude<"aria-multiselectable", keyof E> | Exclude<"aria-orientation", keyof E> | Exclude<"aria-owns", keyof E> | Exclude<"aria-placeholder", keyof E> | Exclude<"aria-posinset", keyof E> | Exclude<"aria-pressed", keyof E> | Exclude<"aria-readonly", keyof E> | Exclude<"aria-relevant", keyof E> | Exclude<"aria-required", keyof E> | Exclude<"aria-roledescription", keyof E> | Exclude<"aria-rowcount", keyof E> | Exclude<"aria-rowindex", keyof E> | Exclude<"aria-rowspan", keyof E> | Exclude<"aria-selected", keyof E> | Exclude<"aria-setsize", keyof E> | Exclude<"aria-sort", keyof E> | Exclude<"aria-valuemax", keyof E> | Exclude<"aria-valuemin", keyof E> | Exclude<"aria-valuenow", keyof E> | Exclude<"aria-valuetext", keyof E> | Exclude<"dangerouslySetInnerHTML", keyof E> | Exclude<"onCopy", keyof E> | Exclude<"onCopyCapture", keyof E> | Exclude<"onCut", keyof E> | Exclude<"onCutCapture", keyof E> | Exclude<"onPaste", keyof E> | Exclude<"onPasteCapture", keyof E> | Exclude<"onCompositionEnd", keyof E> | Exclude<"onCompositionEndCapture", keyof E> | Exclude<"onCompositionStart", keyof E> | Exclude<"onCompositionStartCapture", keyof E> | Exclude<"onCompositionUpdate", keyof E> | Exclude<"onCompositionUpdateCapture", keyof E> | Exclude<"onFocus", keyof E> | Exclude<"onFocusCapture", keyof E> | Exclude<"onBlur", keyof E> | Exclude<"onBlurCapture", keyof E> | Exclude<"onChange", keyof E> | Exclude<"onChangeCapture", keyof E> | Exclude<"onBeforeInput", keyof E> | Exclude<"onBeforeInputCapture", keyof E> | Exclude<"onInput", keyof E> | Exclude<"onInputCapture", keyof E> | Exclude<"onReset", keyof E> | Exclude<"onResetCapture", keyof E> | Exclude<"onSubmit", keyof E> | Exclude<"onSubmitCapture", keyof E> | Exclude<"onInvalid", keyof E> | Exclude<"onInvalidCapture", keyof E> | Exclude<"onLoad", keyof E> | Exclude<"onLoadCapture", keyof E> | Exclude<"onError", keyof E> | Exclude<"onErrorCapture", keyof E> | Exclude<"onKeyDown", keyof E> | Exclude<"onKeyDownCapture", keyof E> | Exclude<"onKeyPress", keyof E> | Exclude<"onKeyPressCapture", keyof E> | Exclude<"onKeyUp", keyof E> | Exclude<"onKeyUpCapture", keyof E> | Exclude<"onAbort", keyof E> | Exclude<"onAbortCapture", keyof E> | Exclude<"onCanPlay", keyof E> | Exclude<"onCanPlayCapture", keyof E> | Exclude<"onCanPlayThrough", keyof E> | Exclude<"onCanPlayThroughCapture", keyof E> | Exclude<"onDurationChange", keyof E> | Exclude<"onDurationChangeCapture", keyof E> | Exclude<"onEmptied", keyof E> | Exclude<"onEmptiedCapture", keyof E> | Exclude<"onEncrypted", keyof E> | Exclude<"onEncryptedCapture", keyof E> | Exclude<"onEnded", keyof E> | Exclude<"onEndedCapture", keyof E> | Exclude<"onLoadedData", keyof E> | Exclude<"onLoadedDataCapture", keyof E> | Exclude<"onLoadedMetadata", keyof E> | Exclude<"onLoadedMetadataCapture", keyof E> | Exclude<"onLoadStart", keyof E> | Exclude<"onLoadStartCapture", keyof E> | Exclude<"onPause", keyof E> | Exclude<"onPauseCapture", keyof E> | Exclude<"onPlay", keyof E> | Exclude<"onPlayCapture", keyof E> | Exclude<"onPlaying", keyof E> | Exclude<"onPlayingCapture", keyof E> | Exclude<"onProgress", keyof E> | Exclude<"onProgressCapture", keyof E> | Exclude<"onRateChange", keyof E> | Exclude<"onRateChangeCapture", keyof E> | Exclude<"onSeeked", keyof E> | Exclude<"onSeekedCapture", keyof E> | Exclude<"onSeeking", keyof E> | Exclude<"onSeekingCapture", keyof E> | Exclude<"onStalled", keyof E> | Exclude<"onStalledCapture", keyof E> | Exclude<"onSuspend", keyof E> | Exclude<"onSuspendCapture", keyof E> | Exclude<"onTimeUpdate", keyof E> | Exclude<"onTimeUpdateCapture", keyof E> | Exclude<"onVolumeChange", keyof E> | Exclude<"onVolumeChangeCapture", keyof E> | Exclude<"onWaiting", keyof E> | Exclude<"onWaitingCapture", keyof E> | Exclude<"onAuxClick", keyof E> | Exclude<"onAuxClickCapture", keyof E> | Exclude<"onClick", keyof E> | Exclude<"onClickCapture", keyof E> | Exclude<"onContextMenu", keyof E> | Exclude<"onContextMenuCapture", keyof E> | Exclude<"onDoubleClick", keyof E> | Exclude<"onDoubleClickCapture", keyof E> | Exclude<"onDrag", keyof E> | Exclude<"onDragCapture", keyof E> | Exclude<"onDragEnd", keyof E> | Exclude<"onDragEndCapture", keyof E> | Exclude<"onDragEnter", keyof E> | Exclude<"onDragEnterCapture", keyof E> | Exclude<"onDragExit", keyof E> | Exclude<"onDragExitCapture", keyof E> | Exclude<"onDragLeave", keyof E> | Exclude<"onDragLeaveCapture", keyof E> | Exclude<"onDragOver", keyof E> | Exclude<"onDragOverCapture", keyof E> | Exclude<"onDragStart", keyof E> | Exclude<"onDragStartCapture", keyof E> | Exclude<"onDrop", keyof E> | Exclude<"onDropCapture", keyof E> | Exclude<"onMouseDown", keyof E> | Exclude<"onMouseDownCapture", keyof E> | Exclude<"onMouseEnter", keyof E> | Exclude<"onMouseLeave", keyof E> | Exclude<"onMouseMove", keyof E> | Exclude<"onMouseMoveCapture", keyof E> | Exclude<"onMouseOut", keyof E> | Exclude<"onMouseOutCapture", keyof E> | Exclude<"onMouseOver", keyof E> | Exclude<"onMouseOverCapture", keyof E> | Exclude<"onMouseUp", keyof E> | Exclude<"onMouseUpCapture", keyof E> | Exclude<"onSelect", keyof E> | Exclude<"onSelectCapture", keyof E> | Exclude<"onTouchCancel", keyof E> | Exclude<"onTouchCancelCapture", keyof E> | Exclude<"onTouchEnd", keyof E> | Exclude<"onTouchEndCapture", keyof E> | Exclude<"onTouchMove", keyof E> | Exclude<"onTouchMoveCapture", keyof E> | Exclude<"onTouchStart", keyof E> | Exclude<"onTouchStartCapture", keyof E> | Exclude<"onPointerDown", keyof E> | Exclude<"onPointerDownCapture", keyof E> | Exclude<"onPointerMove", keyof E> | Exclude<"onPointerMoveCapture", keyof E> | Exclude<"onPointerUp", keyof E> | Exclude<"onPointerUpCapture", keyof E> | Exclude<"onPointerCancel", keyof E> | Exclude<"onPointerCancelCapture", keyof E> | Exclude<"onPointerEnter", keyof E> | Exclude<"onPointerEnterCapture", keyof E> | Exclude<"onPointerLeave", keyof E> | Exclude<"onPointerLeaveCapture", keyof E> | Exclude<"onPointerOver", keyof E> | Exclude<"onPointerOverCapture", keyof E> | Exclude<"onPointerOut", keyof E> | Exclude<"onPointerOutCapture", keyof E> | Exclude<"onGotPointerCapture", keyof E> | Exclude<"onGotPointerCaptureCapture", keyof E> | Exclude<"onLostPointerCapture", keyof E> | Exclude<"onLostPointerCaptureCapture", keyof E> | Exclude<"onScroll", keyof E> | Exclude<"onScrollCapture", keyof E> | Exclude<"onWheel", keyof E> | Exclude<"onWheelCapture", keyof E> | Exclude<"onAnimationStart", keyof E> | Exclude<"onAnimationStartCapture", keyof E> | Exclude<"onAnimationEnd", keyof E> | Exclude<"onAnimationEndCapture", keyof E> | Exclude<"onAnimationIteration", keyof E> | Exclude<"onAnimationIterationCapture", keyof E> | Exclude<"onTransitionEnd", keyof E> | Exclude<"onTransitionEndCapture", keyof E>> & EventProps<E>>> & import("react").RefAttributes<unknown>>;
export declare const createComponent: <I extends HTMLElement, E extends EventNames = {}>(React: typeof import("react"), tagName: string, elementClass: Constructor<I>, events?: E | undefined, displayName?: string) => ReactWebComponent<I, E>;
export {};
//# sourceMappingURL=create-component.d.ts.map

@@ -135,6 +135,7 @@ /**

render() {
var _a;
// Since refs only get fulfilled once, pass a new one if the user's
// ref changed. This allows refs to be fulfilled as expected, going from
// having a value to null.
const userRef = this.props.__forwardedRef;
const userRef = (_a = this.props.__forwardedRef) !== null && _a !== void 0 ? _a : null;
if (this._ref === undefined || this._userRef !== userRef) {

@@ -141,0 +142,0 @@ this._ref = (value) => {

{
"name": "@lit-labs/react",
"version": "1.0.8",
"version": "1.0.9",
"description": "A React component wrapper for web components.",

@@ -5,0 +5,0 @@ "license": "BSD-3-Clause",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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