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

react-expand

Package Overview
Dependencies
Maintainers
2
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-expand - npm Package Compare versions

Comparing version 1.2.0 to 1.3.0

44

build/index.js

@@ -700,2 +700,4 @@ (function webpackUniversalModuleDefinition(root, factory) {

var _ExpandController = __webpack_require__("./src/Components/ExpandController/index.ts");
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }

@@ -740,5 +742,16 @@

tabId = _a.tabId,
childProps = __rest(_a, ["tabId"]);
return React.createElement("div", Object.assign({}, childProps, { onClick: this.handleTabActivate, "data-expand-keep": tabId }), this.props.children);
activeClassName = _a.activeClassName,
childProps = __rest(_a, ["tabId", "activeClassName"]);
return React.createElement("div", Object.assign({}, childProps, { onClick: this.handleTabActivate, className: this.className, "data-expand-keep": tabId }), this.props.children);
}
}, {
key: "className",
get: function get() {
var _props = this.props,
className = _props.className,
activeClassName = _props.activeClassName,
tabId = _props.tabId;
return "" + (className || "") + (this.context.isExpanded(tabId) ? " " + this.props.activeClassName : "");
}
}]);

@@ -749,4 +762,5 @@

Header.contextTypes = _TabsProps.TabsContextTypes;
Header.contextTypes = Object.assign({}, _ExpandController.ExpandContextTypes, _TabsProps.TabsContextTypes);
Header.propTypes = _TabsProps.TabElementPropTypes;
Header.defaultProps = _TabsProps.TabElementDefaultProps;

@@ -817,5 +831,16 @@ /***/ }),

tabId = _a.tabId,
childProps = __rest(_a, ["tabId"]);
return React.createElement("div", Object.assign({}, childProps, { "data-expand-keep": tabId }), this.context.isExpanded(tabId) && this.props.children);
activeClassName = _a.activeClassName,
childProps = __rest(_a, ["tabId", "activeClassName"]);
return React.createElement("div", Object.assign({}, childProps, { "data-expand-keep": tabId, className: this.className }), this.context.isExpanded(tabId) && this.props.children);
}
}, {
key: "className",
get: function get() {
var _props = this.props,
className = _props.className,
activeClassName = _props.activeClassName,
tabId = _props.tabId;
return "" + (className || "") + (this.context.isExpanded(tabId) ? " " + this.props.activeClassName : "");
}
}]);

@@ -828,2 +853,3 @@

Tab.propTypes = _TabsProps.TabElementPropTypes;
Tab.defaultProps = _TabsProps.TabElementDefaultProps;

@@ -921,3 +947,3 @@ /***/ }),

});
exports.TabsContextTypes = exports.TabElementPropTypes = undefined;
exports.TabsContextTypes = exports.TabElementDefaultProps = exports.TabElementPropTypes = undefined;

@@ -931,4 +957,8 @@ var _propTypes = __webpack_require__("prop-types");

var TabElementPropTypes = exports.TabElementPropTypes = {
tabId: PropTypes.string.isRequired
tabId: PropTypes.string.isRequired,
activeClassName: PropTypes.string
};
var TabElementDefaultProps = exports.TabElementDefaultProps = {
activeClassName: "active"
};
var TabsContextTypes = exports.TabsContextTypes = {

@@ -935,0 +965,0 @@ changeActiveTab: PropTypes.func.isRequired,

@@ -5,2 +5,3 @@ /// <reference types="react" />

import { TabsContext, TabElementProps } from "./TabsProps";
import { ExpandContext } from "../ExpandController";
export declare class Header extends React.Component<TabElementProps> {

@@ -11,5 +12,9 @@ static readonly contextTypes: {

registerTab: PropTypes.Validator<any>;
changeExpandState: PropTypes.Validator<any>;
isExpanded: PropTypes.Validator<any>;
getState: PropTypes.Validator<any>;
};
static readonly propTypes: {
tabId: PropTypes.Validator<any>;
activeClassName?: PropTypes.Validator<any>;
accept?: PropTypes.Validator<any>;

@@ -350,5 +355,346 @@ acceptCharset?: PropTypes.Validator<any>;

};
readonly context: TabsContext;
static readonly defaultProps: {
tabId?: string;
activeClassName?: string;
accept?: string;
acceptCharset?: string;
action?: string;
allowFullScreen?: boolean;
allowTransparency?: boolean;
alt?: string;
as?: string;
async?: boolean;
autoComplete?: string;
autoFocus?: boolean;
autoPlay?: boolean;
capture?: boolean;
cellPadding?: string | number;
cellSpacing?: string | number;
charSet?: string;
challenge?: string;
checked?: boolean;
cite?: string;
classID?: string;
cols?: number;
colSpan?: number;
content?: string;
controls?: boolean;
coords?: string;
crossOrigin?: string;
data?: string;
dateTime?: string;
default?: boolean;
defer?: boolean;
disabled?: boolean;
download?: any;
encType?: string;
form?: string;
formAction?: string;
formEncType?: string;
formMethod?: string;
formNoValidate?: boolean;
formTarget?: string;
frameBorder?: string | number;
headers?: string;
height?: string | number;
high?: number;
href?: string;
hrefLang?: string;
htmlFor?: string;
httpEquiv?: string;
integrity?: string;
keyParams?: string;
keyType?: string;
kind?: string;
label?: string;
list?: string;
loop?: boolean;
low?: number;
manifest?: string;
marginHeight?: number;
marginWidth?: number;
max?: string | number;
maxLength?: number;
media?: string;
mediaGroup?: string;
method?: string;
min?: string | number;
minLength?: number;
multiple?: boolean;
muted?: boolean;
name?: string;
nonce?: string;
noValidate?: boolean;
open?: boolean;
optimum?: number;
pattern?: string;
placeholder?: string;
playsInline?: boolean;
poster?: string;
preload?: string;
readOnly?: boolean;
rel?: string;
required?: boolean;
reversed?: boolean;
rows?: number;
rowSpan?: number;
sandbox?: string;
scope?: string;
scoped?: boolean;
scrolling?: string;
seamless?: boolean;
selected?: boolean;
shape?: string;
size?: number;
sizes?: string;
span?: number;
src?: string;
srcDoc?: string;
srcLang?: string;
srcSet?: string;
start?: number;
step?: string | number;
summary?: string;
target?: string;
type?: string;
useMap?: string;
value?: string | number | string[];
width?: string | number;
wmode?: string;
wrap?: string;
defaultChecked?: boolean;
defaultValue?: string | string[];
suppressContentEditableWarning?: boolean;
accessKey?: string;
className?: string;
contentEditable?: boolean;
contextMenu?: string;
dir?: string;
draggable?: boolean;
hidden?: boolean;
id?: string;
lang?: string;
slot?: string;
spellCheck?: boolean;
style?: React.CSSProperties;
tabIndex?: number;
title?: string;
inputMode?: string;
is?: string;
radioGroup?: string;
role?: string;
about?: string;
datatype?: string;
inlist?: any;
prefix?: string;
property?: string;
resource?: string;
typeof?: string;
vocab?: string;
autoCapitalize?: string;
autoCorrect?: string;
autoSave?: string;
color?: string;
itemProp?: string;
itemScope?: boolean;
itemType?: string;
itemID?: string;
itemRef?: string;
results?: number;
security?: string;
unselectable?: boolean;
'aria-activedescendant'?: string;
'aria-atomic'?: boolean | "false" | "true";
'aria-autocomplete'?: "list" | "none" | "inline" | "both";
'aria-busy'?: boolean | "false" | "true";
'aria-checked'?: boolean | "false" | "true" | "mixed";
'aria-colcount'?: number;
'aria-colindex'?: number;
'aria-colspan'?: number;
'aria-current'?: boolean | "step" | "false" | "true" | "page" | "location" | "date" | "time";
'aria-describedby'?: string;
'aria-details'?: string;
'aria-disabled'?: boolean | "false" | "true";
'aria-dropeffect'?: "none" | "copy" | "execute" | "link" | "move" | "popup";
'aria-errormessage'?: string;
'aria-expanded'?: boolean | "false" | "true";
'aria-flowto'?: string;
'aria-grabbed'?: boolean | "false" | "true";
'aria-haspopup'?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog";
'aria-hidden'?: boolean | "false" | "true";
'aria-invalid'?: boolean | "false" | "true" | "grammar" | "spelling";
'aria-keyshortcuts'?: string;
'aria-label'?: string;
'aria-labelledby'?: string;
'aria-level'?: number;
'aria-live'?: "off" | "assertive" | "polite";
'aria-modal'?: boolean | "false" | "true";
'aria-multiline'?: boolean | "false" | "true";
'aria-multiselectable'?: boolean | "false" | "true";
'aria-orientation'?: "horizontal" | "vertical";
'aria-owns'?: string;
'aria-placeholder'?: string;
'aria-posinset'?: number;
'aria-pressed'?: boolean | "false" | "true" | "mixed";
'aria-readonly'?: boolean | "false" | "true";
'aria-relevant'?: "additions" | "additions text" | "all" | "removals" | "text";
'aria-required'?: boolean | "false" | "true";
'aria-roledescription'?: string;
'aria-rowcount'?: number;
'aria-rowindex'?: number;
'aria-rowspan'?: number;
'aria-selected'?: boolean | "false" | "true";
'aria-setsize'?: number;
'aria-sort'?: "none" | "ascending" | "descending" | "other";
'aria-valuemax'?: number;
'aria-valuemin'?: number;
'aria-valuenow'?: number;
'aria-valuetext'?: string;
children?: React.ReactNode;
dangerouslySetInnerHTML?: {
__html: string;
};
onCopy?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCopyCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCut?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCutCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onPaste?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onPasteCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCompositionEnd?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionEndCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionStart?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionStartCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionUpdate?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionUpdateCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onFocus?: (event: React.FocusEvent<HTMLDivElement>) => void;
onFocusCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
onBlur?: (event: React.FocusEvent<HTMLDivElement>) => void;
onBlurCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
onChange?: (event: React.FormEvent<HTMLDivElement>) => void;
onChangeCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onInput?: (event: React.FormEvent<HTMLDivElement>) => void;
onInputCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onReset?: (event: React.FormEvent<HTMLDivElement>) => void;
onResetCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onSubmit?: (event: React.FormEvent<HTMLDivElement>) => void;
onSubmitCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onInvalid?: (event: React.FormEvent<HTMLDivElement>) => void;
onInvalidCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onLoad?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onError?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onErrorCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onKeyDown?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyDownCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyPress?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyPressCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyUp?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyUpCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onAbort?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onAbortCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlay?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayThrough?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayThroughCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onDurationChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onDurationChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEmptied?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEmptiedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEncrypted?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEncryptedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEnded?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEndedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedData?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedDataCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedMetadata?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedMetadataCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadStart?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadStartCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPause?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPauseCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlay?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlayCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlaying?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlayingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onProgress?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onProgressCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onRateChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onRateChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeeked?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeekedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeeking?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeekingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onStalled?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onStalledCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSuspend?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSuspendCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTimeUpdate?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTimeUpdateCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onVolumeChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onVolumeChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onWaiting?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onWaitingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onClick?: (event: React.MouseEvent<HTMLDivElement>) => void;
onClickCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onContextMenu?: (event: React.MouseEvent<HTMLDivElement>) => void;
onContextMenuCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDoubleClick?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDoubleClickCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDrag?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnd?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEndCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnter?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnterCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragExit?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragExitCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragLeave?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragLeaveCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragOver?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragOverCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragStart?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragStartCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDrop?: (event: React.DragEvent<HTMLDivElement>) => void;
onDropCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onMouseDown?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseDownCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseEnter?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseLeave?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseMove?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseMoveCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOut?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOutCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOver?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOverCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseUp?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseUpCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onSelect?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSelectCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTouchCancel?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchCancelCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchEnd?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchEndCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchMove?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchMoveCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchStart?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchStartCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onScroll?: (event: React.UIEvent<HTMLDivElement>) => void;
onScrollCapture?: (event: React.UIEvent<HTMLDivElement>) => void;
onWheel?: (event: React.WheelEvent<HTMLDivElement>) => void;
onWheelCapture?: (event: React.WheelEvent<HTMLDivElement>) => void;
onAnimationStart?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationStartCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationEnd?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationEndCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationIteration?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationIterationCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onTransitionEnd?: (event: React.TransitionEvent<HTMLDivElement>) => void;
onTransitionEndCapture?: (event: React.TransitionEvent<HTMLDivElement>) => void;
ref?: React.Ref<HTMLDivElement>;
key?: string | number;
};
readonly context: ExpandContext & TabsContext;
render(): JSX.Element;
protected handleTabActivate: (event: React.MouseEvent<HTMLDivElement>) => void;
protected readonly className: string;
}

@@ -17,2 +17,3 @@ /// <reference types="react" />

tabId: PropTypes.Validator<any>;
activeClassName?: PropTypes.Validator<any>;
accept?: PropTypes.Validator<any>;

@@ -353,2 +354,342 @@ acceptCharset?: PropTypes.Validator<any>;

};
static readonly defaultProps: {
tabId?: string;
activeClassName?: string;
accept?: string;
acceptCharset?: string;
action?: string;
allowFullScreen?: boolean;
allowTransparency?: boolean;
alt?: string;
as?: string;
async?: boolean;
autoComplete?: string;
autoFocus?: boolean;
autoPlay?: boolean;
capture?: boolean;
cellPadding?: string | number;
cellSpacing?: string | number;
charSet?: string;
challenge?: string;
checked?: boolean;
cite?: string;
classID?: string;
cols?: number;
colSpan?: number;
content?: string;
controls?: boolean;
coords?: string;
crossOrigin?: string;
data?: string;
dateTime?: string;
default?: boolean;
defer?: boolean;
disabled?: boolean;
download?: any;
encType?: string;
form?: string;
formAction?: string;
formEncType?: string;
formMethod?: string;
formNoValidate?: boolean;
formTarget?: string;
frameBorder?: string | number;
headers?: string;
height?: string | number;
high?: number;
href?: string;
hrefLang?: string;
htmlFor?: string;
httpEquiv?: string;
integrity?: string;
keyParams?: string;
keyType?: string;
kind?: string;
label?: string;
list?: string;
loop?: boolean;
low?: number;
manifest?: string;
marginHeight?: number;
marginWidth?: number;
max?: string | number;
maxLength?: number;
media?: string;
mediaGroup?: string;
method?: string;
min?: string | number;
minLength?: number;
multiple?: boolean;
muted?: boolean;
name?: string;
nonce?: string;
noValidate?: boolean;
open?: boolean;
optimum?: number;
pattern?: string;
placeholder?: string;
playsInline?: boolean;
poster?: string;
preload?: string;
readOnly?: boolean;
rel?: string;
required?: boolean;
reversed?: boolean;
rows?: number;
rowSpan?: number;
sandbox?: string;
scope?: string;
scoped?: boolean;
scrolling?: string;
seamless?: boolean;
selected?: boolean;
shape?: string;
size?: number;
sizes?: string;
span?: number;
src?: string;
srcDoc?: string;
srcLang?: string;
srcSet?: string;
start?: number;
step?: string | number;
summary?: string;
target?: string;
type?: string;
useMap?: string;
value?: string | number | string[];
width?: string | number;
wmode?: string;
wrap?: string;
defaultChecked?: boolean;
defaultValue?: string | string[];
suppressContentEditableWarning?: boolean;
accessKey?: string;
className?: string;
contentEditable?: boolean;
contextMenu?: string;
dir?: string;
draggable?: boolean;
hidden?: boolean;
id?: string;
lang?: string;
slot?: string;
spellCheck?: boolean;
style?: React.CSSProperties;
tabIndex?: number;
title?: string;
inputMode?: string;
is?: string;
radioGroup?: string;
role?: string;
about?: string;
datatype?: string;
inlist?: any;
prefix?: string;
property?: string;
resource?: string;
typeof?: string;
vocab?: string;
autoCapitalize?: string;
autoCorrect?: string;
autoSave?: string;
color?: string;
itemProp?: string;
itemScope?: boolean;
itemType?: string;
itemID?: string;
itemRef?: string;
results?: number;
security?: string;
unselectable?: boolean;
'aria-activedescendant'?: string;
'aria-atomic'?: boolean | "false" | "true";
'aria-autocomplete'?: "list" | "none" | "inline" | "both";
'aria-busy'?: boolean | "false" | "true";
'aria-checked'?: boolean | "false" | "true" | "mixed";
'aria-colcount'?: number;
'aria-colindex'?: number;
'aria-colspan'?: number;
'aria-current'?: boolean | "step" | "false" | "true" | "page" | "location" | "date" | "time";
'aria-describedby'?: string;
'aria-details'?: string;
'aria-disabled'?: boolean | "false" | "true";
'aria-dropeffect'?: "none" | "copy" | "execute" | "link" | "move" | "popup";
'aria-errormessage'?: string;
'aria-expanded'?: boolean | "false" | "true";
'aria-flowto'?: string;
'aria-grabbed'?: boolean | "false" | "true";
'aria-haspopup'?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog";
'aria-hidden'?: boolean | "false" | "true";
'aria-invalid'?: boolean | "false" | "true" | "grammar" | "spelling";
'aria-keyshortcuts'?: string;
'aria-label'?: string;
'aria-labelledby'?: string;
'aria-level'?: number;
'aria-live'?: "off" | "assertive" | "polite";
'aria-modal'?: boolean | "false" | "true";
'aria-multiline'?: boolean | "false" | "true";
'aria-multiselectable'?: boolean | "false" | "true";
'aria-orientation'?: "horizontal" | "vertical";
'aria-owns'?: string;
'aria-placeholder'?: string;
'aria-posinset'?: number;
'aria-pressed'?: boolean | "false" | "true" | "mixed";
'aria-readonly'?: boolean | "false" | "true";
'aria-relevant'?: "additions" | "additions text" | "all" | "removals" | "text";
'aria-required'?: boolean | "false" | "true";
'aria-roledescription'?: string;
'aria-rowcount'?: number;
'aria-rowindex'?: number;
'aria-rowspan'?: number;
'aria-selected'?: boolean | "false" | "true";
'aria-setsize'?: number;
'aria-sort'?: "none" | "ascending" | "descending" | "other";
'aria-valuemax'?: number;
'aria-valuemin'?: number;
'aria-valuenow'?: number;
'aria-valuetext'?: string;
children?: React.ReactNode;
dangerouslySetInnerHTML?: {
__html: string;
};
onCopy?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCopyCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCut?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCutCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onPaste?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onPasteCapture?: (event: React.ClipboardEvent<HTMLDivElement>) => void;
onCompositionEnd?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionEndCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionStart?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionStartCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionUpdate?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onCompositionUpdateCapture?: (event: React.CompositionEvent<HTMLDivElement>) => void;
onFocus?: (event: React.FocusEvent<HTMLDivElement>) => void;
onFocusCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
onBlur?: (event: React.FocusEvent<HTMLDivElement>) => void;
onBlurCapture?: (event: React.FocusEvent<HTMLDivElement>) => void;
onChange?: (event: React.FormEvent<HTMLDivElement>) => void;
onChangeCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onInput?: (event: React.FormEvent<HTMLDivElement>) => void;
onInputCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onReset?: (event: React.FormEvent<HTMLDivElement>) => void;
onResetCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onSubmit?: (event: React.FormEvent<HTMLDivElement>) => void;
onSubmitCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onInvalid?: (event: React.FormEvent<HTMLDivElement>) => void;
onInvalidCapture?: (event: React.FormEvent<HTMLDivElement>) => void;
onLoad?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onError?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onErrorCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onKeyDown?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyDownCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyPress?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyPressCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyUp?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onKeyUpCapture?: (event: React.KeyboardEvent<HTMLDivElement>) => void;
onAbort?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onAbortCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlay?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayThrough?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onCanPlayThroughCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onDurationChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onDurationChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEmptied?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEmptiedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEncrypted?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEncryptedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEnded?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onEndedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedData?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedDataCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedMetadata?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadedMetadataCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadStart?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onLoadStartCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPause?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPauseCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlay?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlayCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlaying?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onPlayingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onProgress?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onProgressCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onRateChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onRateChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeeked?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeekedCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeeking?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSeekingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onStalled?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onStalledCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSuspend?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSuspendCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTimeUpdate?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTimeUpdateCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onVolumeChange?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onVolumeChangeCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onWaiting?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onWaitingCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onClick?: (event: React.MouseEvent<HTMLDivElement>) => void;
onClickCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onContextMenu?: (event: React.MouseEvent<HTMLDivElement>) => void;
onContextMenuCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDoubleClick?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDoubleClickCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onDrag?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnd?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEndCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnter?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragEnterCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragExit?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragExitCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragLeave?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragLeaveCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragOver?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragOverCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragStart?: (event: React.DragEvent<HTMLDivElement>) => void;
onDragStartCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onDrop?: (event: React.DragEvent<HTMLDivElement>) => void;
onDropCapture?: (event: React.DragEvent<HTMLDivElement>) => void;
onMouseDown?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseDownCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseEnter?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseLeave?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseMove?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseMoveCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOut?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOutCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOver?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseOverCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseUp?: (event: React.MouseEvent<HTMLDivElement>) => void;
onMouseUpCapture?: (event: React.MouseEvent<HTMLDivElement>) => void;
onSelect?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onSelectCapture?: (event: React.SyntheticEvent<HTMLDivElement>) => void;
onTouchCancel?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchCancelCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchEnd?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchEndCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchMove?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchMoveCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchStart?: (event: React.TouchEvent<HTMLDivElement>) => void;
onTouchStartCapture?: (event: React.TouchEvent<HTMLDivElement>) => void;
onScroll?: (event: React.UIEvent<HTMLDivElement>) => void;
onScrollCapture?: (event: React.UIEvent<HTMLDivElement>) => void;
onWheel?: (event: React.WheelEvent<HTMLDivElement>) => void;
onWheelCapture?: (event: React.WheelEvent<HTMLDivElement>) => void;
onAnimationStart?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationStartCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationEnd?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationEndCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationIteration?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onAnimationIterationCapture?: (event: React.AnimationEvent<HTMLDivElement>) => void;
onTransitionEnd?: (event: React.TransitionEvent<HTMLDivElement>) => void;
onTransitionEndCapture?: (event: React.TransitionEvent<HTMLDivElement>) => void;
ref?: React.Ref<HTMLDivElement>;
key?: string | number;
};
readonly context: ExpandContext & TabsContext;

@@ -358,2 +699,3 @@ componentDidMount(): void;

render(): JSX.Element;
protected readonly className: string;
}
import * as PropTypes from "prop-types";
export interface TabElementProps extends React.HTMLProps<HTMLDivElement> {
tabId: string;
activeClassName?: string;
}

@@ -8,2 +9,5 @@ export declare const TabElementPropTypes: {

};
export declare const TabElementDefaultProps: {
[P in keyof TabElementProps]?: TabElementProps[P];
};
export interface TabsContext {

@@ -10,0 +14,0 @@ changeActiveTab: (id: string) => void;

2

package.json
{
"name": "react-expand",
"version": "1.2.0",
"version": "1.3.0",
"description": "Simple element expand state controlling",

@@ -5,0 +5,0 @@ "main": "build/index.js",

@@ -82,3 +82,3 @@ # React Expand

<TabsController>
<Header tabId="tab_1" {...HTMLDivElementProps} > // Click on header to activate according tab
<Header activeClassName="is-active" tabId="tab_1" {...HTMLDivElementProps} > // Click on header to activate according tab
...

@@ -89,3 +89,3 @@ </Header>

</Header>
<Tab tabId="tab_1" {...HTMLDivElementProps} >
<Tab activeClassName="is-active" tabId="tab_1" {...HTMLDivElementProps} >
...

@@ -92,0 +92,0 @@ </Tab>

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