react-align
Advanced tools
Comparing version 2.0.5 to 2.1.0
@@ -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 { } |
{ | ||
"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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
2007
102857
20
27
5
1
+ Addedvite-plugin-svgr@^2.2.0
+ Added@ampproject/remapping@2.3.0(transitive)
+ Added@babel/code-frame@7.26.2(transitive)
+ Added@babel/compat-data@7.26.2(transitive)
+ Added@babel/core@7.26.0(transitive)
+ Added@babel/generator@7.26.2(transitive)
+ Added@babel/helper-compilation-targets@7.25.9(transitive)
+ Added@babel/helper-module-imports@7.25.9(transitive)
+ Added@babel/helper-module-transforms@7.26.0(transitive)
+ Added@babel/helper-string-parser@7.25.9(transitive)
+ Added@babel/helper-validator-identifier@7.25.9(transitive)
+ Added@babel/helper-validator-option@7.25.9(transitive)
+ Added@babel/helpers@7.26.0(transitive)
+ Added@babel/parser@7.26.2(transitive)
+ Added@babel/template@7.25.9(transitive)
+ Added@babel/traverse@7.25.9(transitive)
+ Added@babel/types@7.26.0(transitive)
+ Added@esbuild/android-arm@0.18.20(transitive)
+ Added@esbuild/android-arm64@0.18.20(transitive)
+ Added@esbuild/android-x64@0.18.20(transitive)
+ Added@esbuild/darwin-arm64@0.18.20(transitive)
+ Added@esbuild/darwin-x64@0.18.20(transitive)
+ Added@esbuild/freebsd-arm64@0.18.20(transitive)
+ Added@esbuild/freebsd-x64@0.18.20(transitive)
+ Added@esbuild/linux-arm@0.18.20(transitive)
+ Added@esbuild/linux-arm64@0.18.20(transitive)
+ Added@esbuild/linux-ia32@0.18.20(transitive)
+ Added@esbuild/linux-loong64@0.18.20(transitive)
+ Added@esbuild/linux-mips64el@0.18.20(transitive)
+ Added@esbuild/linux-ppc64@0.18.20(transitive)
+ Added@esbuild/linux-riscv64@0.18.20(transitive)
+ Added@esbuild/linux-s390x@0.18.20(transitive)
+ Added@esbuild/linux-x64@0.18.20(transitive)
+ Added@esbuild/netbsd-x64@0.18.20(transitive)
+ Added@esbuild/openbsd-x64@0.18.20(transitive)
+ Added@esbuild/sunos-x64@0.18.20(transitive)
+ Added@esbuild/win32-arm64@0.18.20(transitive)
+ Added@esbuild/win32-ia32@0.18.20(transitive)
+ Added@esbuild/win32-x64@0.18.20(transitive)
+ Added@jridgewell/gen-mapping@0.3.5(transitive)
+ Added@jridgewell/resolve-uri@3.1.2(transitive)
+ Added@jridgewell/set-array@1.2.1(transitive)
+ Added@jridgewell/sourcemap-codec@1.5.0(transitive)
+ Added@jridgewell/trace-mapping@0.3.25(transitive)
+ Added@rollup/pluginutils@5.1.3(transitive)
+ Added@svgr/babel-plugin-add-jsx-attribute@6.5.1(transitive)
+ Added@svgr/babel-plugin-remove-jsx-attribute@8.0.0(transitive)
+ Added@svgr/babel-plugin-remove-jsx-empty-expression@8.0.0(transitive)
+ Added@svgr/babel-plugin-replace-jsx-attribute-value@6.5.1(transitive)
+ Added@svgr/babel-plugin-svg-dynamic-title@6.5.1(transitive)
+ Added@svgr/babel-plugin-svg-em-dimensions@6.5.1(transitive)
+ Added@svgr/babel-plugin-transform-react-native-svg@6.5.1(transitive)
+ Added@svgr/babel-plugin-transform-svg-component@6.5.1(transitive)
+ Added@svgr/babel-preset@6.5.1(transitive)
+ Added@svgr/core@6.5.1(transitive)
+ Added@svgr/hast-util-to-babel-ast@6.5.1(transitive)
+ Added@svgr/plugin-jsx@6.5.1(transitive)
+ Added@types/estree@1.0.6(transitive)
+ Added@types/parse-json@4.0.2(transitive)
+ Addedbrowserslist@4.24.2(transitive)
+ Addedcallsites@3.1.0(transitive)
+ Addedcamelcase@6.3.0(transitive)
+ Addedcaniuse-lite@1.0.30001680(transitive)
+ Addedconvert-source-map@2.0.0(transitive)
+ Addedcosmiconfig@7.1.0(transitive)
+ Addeddebug@4.3.7(transitive)
+ Addedelectron-to-chromium@1.5.60(transitive)
+ Addedentities@4.5.0(transitive)
+ Addederror-ex@1.3.2(transitive)
+ Addedesbuild@0.18.20(transitive)
+ Addedescalade@3.2.0(transitive)
+ Addedestree-walker@2.0.2(transitive)
+ Addedfsevents@2.3.3(transitive)
+ Addedgensync@1.0.0-beta.2(transitive)
+ Addedglobals@11.12.0(transitive)
+ Addedimport-fresh@3.3.0(transitive)
+ Addedis-arrayish@0.2.1(transitive)
+ Addedjsesc@3.0.2(transitive)
+ Addedjson-parse-even-better-errors@2.3.1(transitive)
+ Addedjson5@2.2.3(transitive)
+ Addedlines-and-columns@1.2.4(transitive)
+ Addedlru-cache@5.1.1(transitive)
+ Addedms@2.1.3(transitive)
+ Addednanoid@3.3.7(transitive)
+ Addednode-releases@2.0.18(transitive)
+ Addedparent-module@1.0.1(transitive)
+ Addedparse-json@5.2.0(transitive)
+ Addedpath-type@4.0.0(transitive)
+ Addedpicocolors@1.1.1(transitive)
+ Addedpicomatch@4.0.2(transitive)
+ Addedpostcss@8.4.49(transitive)
+ Addedresolve-from@4.0.0(transitive)
+ Addedrollup@3.29.5(transitive)
+ Addedsemver@6.3.1(transitive)
+ Addedsource-map-js@1.2.1(transitive)
+ Addedsvg-parser@2.0.4(transitive)
+ Addedupdate-browserslist-db@1.1.1(transitive)
+ Addedvite@4.5.5(transitive)
+ Addedvite-plugin-svgr@2.4.0(transitive)
+ Addedyallist@3.1.1(transitive)
+ Addedyaml@1.10.2(transitive)
- Removedglamor@^2.20.40
- Removedreact-beautiful-dnd@^13.1.0
- Removedasap@2.0.6(transitive)
- Removedbowser@1.9.4(transitive)
- Removedcore-js@1.2.7(transitive)
- Removedcss-in-js-utils@2.0.1(transitive)
- Removedencoding@0.1.13(transitive)
- Removedfbjs@0.8.18(transitive)
- Removedglamor@2.20.40(transitive)
- Removedhyphenate-style-name@1.1.0(transitive)
- Removediconv-lite@0.6.3(transitive)
- Removedinline-style-prefixer@3.0.8(transitive)
- Removedis-stream@1.1.0(transitive)
- Removedisobject@3.0.1(transitive)
- Removedisomorphic-fetch@2.2.1(transitive)
- Removednode-fetch@1.7.3(transitive)
- Removedpromise@7.3.1(transitive)
- Removedsafer-buffer@2.1.2(transitive)
- Removedsetimmediate@1.0.5(transitive)
- Removedthrough@2.3.8(transitive)
- Removedua-parser-js@0.7.39(transitive)
- Removedwhatwg-fetch@3.6.20(transitive)