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

react-align

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-align - npm Package Compare versions

Comparing version 2.0.5 to 2.1.0

dist/react-align.mjs

111

dist/index.d.ts

@@ -1,6 +0,105 @@

export { default as GridWrapper } from "./GridWrapper";
export { default as GridSection } from "./GridSection";
export { default as GridArea } from "./GridArea";
export { default as GridItem } from "./GridItem";
export { default as Icon } from "./Icon";
export type { Alignment } from "./GridArea";
import { CSSProperties } from 'react';
import { PropsWithChildren } from 'react';
import { default as React_2 } from 'react';
import { ReactNode } from 'react';
export declare type Alignment = "start" | "centered" | "end";
declare type AreaProps = {
id: string;
className?: string;
vertical?: boolean;
stretch?: boolean;
end?: boolean;
align?: Alignment;
disabled?: boolean;
/** Extra customizable parts only for the really picky */
style?: CSSProperties;
editorStyle?: CSSProperties;
iconColor?: string;
onAlignChange?: (alignment: Alignment) => void;
};
declare const _default: {
horizontalExtend: any;
horizontalNormal: any;
verticalExtend: any;
verticalNormal: any;
moveArrows: any;
alignStart: any;
alignCenter: any;
alignEnd: any;
alignStartV: any;
alignCenterV: any;
alignEndV: any;
};
export declare function GridArea({ id, className, vertical, stretch, end, disabled, align, onAlignChange, children, style, editorStyle, iconColor, }: PropsWithChildren<AreaProps>): JSX.Element | null;
export declare function GridItem({ className, children, id, index, extendable, extended, disabled, style, editorStyle, iconColor, ...props }: ItemProps): JSX.Element;
export declare const GridSection: React_2.FC<GridSectionProps>;
declare type GridSectionProps = {
className?: string;
children?: ReactNode;
horizontal?: boolean;
stretch?: boolean;
fixedWidth?: number;
fixedHeight?: number;
/** Extra customizable parts only for the really picky */
style?: CSSProperties;
editorStyle?: CSSProperties;
};
export declare const GridWrapper: React_2.FC<GridWrapperProps>;
declare type GridWrapperProps = {
className?: string;
children?: ReactNode;
editing?: boolean;
vertical?: boolean;
stretch?: boolean;
/** Extra customizable parts only for the really picky */
style?: CSSProperties;
editorStyle?: CSSProperties;
onMove?: (id: string, destAreaId: string, destIndex: number, prevAreaId: string, prevIndex: number) => void;
onAlignChange?: (areaId: string, align: Alignment) => void;
onExtend?: (id: string, extended: boolean) => void;
};
export declare const Icon: React_2.FC<IconProps>;
declare type IconKeys = keyof typeof _default;
declare type IconProps = {
className?: string;
name: string | IconKeys;
onClick?: () => void;
};
declare type ItemProps = {
className?: string;
id: string;
index: number;
extendable?: boolean;
extended?: boolean;
disabled?: boolean;
onExtend?: (extended: boolean) => void;
children?: ReactNode | ((context: {
id: string;
editing: boolean;
isDragging: boolean;
isHovered: boolean;
extended: boolean;
extendable: boolean;
disabled: boolean;
index: number;
}) => ReactNode);
/** Extra customizable parts only for the really picky */
style?: CSSProperties;
editorStyle?: CSSProperties;
iconColor?: string;
};
export { }

85

package.json
{
"name": "react-align",
"version": "2.0.5",
"version": "2.1.0",
"author": "KaWaite",
"module": "dist/react-align.esm.js",
"license": "MIT",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"main": "./dist/react-align.umd.js",
"module": "./dist/react-align.mjs",
"types": "./dist/index.d.ts",
"exports": {
".": {
"import": "./dist/react-align.mjs",
"require": "./dist/react-align.umd.js"
}
},
"scripts": {
"start": "tsdx watch",
"build": "tsdx build",
"test": "tsdx test --passWithNoTests",
"lint": "tsdx lint",
"prepare": "tsdx build",
"size": "size-limit",
"analyze": "size-limit --why",
"storybook": "start-storybook -p 6006",
"build-storybook": "build-storybook"
"build": "tsc && vite build",
"type": "tsc",
"test": "vitest",
"lint": "eslint ."
},

@@ -28,49 +29,35 @@ "files": [

"peerDependencies": {
"react": ">=16"
"react": ">=16",
"react-beautiful-dnd": "*"
},
"husky": {
"hooks": {
"pre-commit": "tsdx lint"
}
},
"prettier": {
"printWidth": 80,
"semi": true,
"singleQuote": true,
"trailingComma": "es5"
},
"size-limit": [
{
"path": "dist/react-align.cjs.production.min.js",
"limit": "10 KB"
},
{
"path": "dist/react-align.esm.js",
"limit": "10 KB"
}
],
"devDependencies": {
"@babel/core": "^7.15.8",
"@size-limit/preset-small-lib": "^6.0.3",
"@svgr/rollup": "^5.5.0",
"@types/react": "^17.0.33",
"@babel/core": "^7.18.6",
"@types/react": "^18.0.15",
"@types/react-beautiful-dnd": "^13.1.2",
"@types/react-dom": "^17.0.10",
"babel-loader": "^8.2.3",
"cssnano": "^5.0.8",
"husky": "^7.0.4",
"postcss": "^8.3.11",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-is": "^17.0.2",
"rollup-plugin-postcss": "^4.0.1",
"size-limit": "^6.0.3",
"tsdx": "^0.14.1",
"tslib": "^2.3.1",
"typescript": "^4.4.4"
"@types/react-dom": "^18.0.6",
"@vitejs/plugin-react": "^2.0.0",
"babel-loader": "^8.2.5",
"eslint": "^8.19.0",
"eslint-config-prettier": "^8.5.0",
"eslint-config-react-app": "^7.0.1",
"eslint-plugin-prettier": "^4.2.1",
"postcss": "^8.4.14",
"prettier": "^2.7.1",
"react": "^18.2.0",
"react-beautiful-dnd": "^13.1.0",
"react-dom": "^18.2.0",
"typescript": "^4.7.4",
"vite": "^3.0.0",
"vite-plugin-css-injected-by-js": "^1.5.1",
"vite-plugin-dts": "^1.3.0",
"vitest": "^0.18.0"
},
"dependencies": {
"glamor": "^2.20.40",
"react-beautiful-dnd": "^13.1.0"
"vite-plugin-svgr": "^2.2.0"
}
}

@@ -1,12 +0,12 @@

import HorizontalExtend from './Icons/horizontalExtend.svg';
import HorizontalNormal from './Icons/horizontalNormal.svg';
import VerticalExtend from './Icons/verticalExtend.svg';
import VerticalNormal from './Icons/verticalNormal.svg';
import MoveArrows from './Icons/moveArrows.svg';
import AlignStart from './Icons/alignStart.svg';
import AlignCenter from './Icons/alignCenter.svg';
import AlignEnd from './Icons/alignEnd.svg';
import AlignStartV from './Icons/alignStartV.svg';
import AlignCenterV from './Icons/alignCenterV.svg';
import AlignEndV from './Icons/alignEndV.svg';
import { ReactComponent as HorizontalExtend } from "./Icons/horizontalExtend.svg";
import { ReactComponent as HorizontalNormal } from "./Icons/horizontalNormal.svg";
import { ReactComponent as VerticalExtend } from "./Icons/verticalExtend.svg";
import { ReactComponent as VerticalNormal } from "./Icons/verticalNormal.svg";
import { ReactComponent as MoveArrows } from "./Icons/moveArrows.svg";
import { ReactComponent as AlignStart } from "./Icons/alignStart.svg";
import { ReactComponent as AlignCenter } from "./Icons/alignCenter.svg";
import { ReactComponent as AlignEnd } from "./Icons/alignEnd.svg";
import { ReactComponent as AlignStartV } from "./Icons/alignStartV.svg";
import { ReactComponent as AlignCenterV } from "./Icons/alignCenterV.svg";
import { ReactComponent as AlignEndV } from "./Icons/alignEndV.svg";

@@ -13,0 +13,0 @@ export default {

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

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