| {"version":3,"file":"Box.d.ts","sourceRoot":"","sources":["../src/Box.tsx"],"names":[],"mappings":";AACA,OAAO,KAAK,EACV,oCAAoC,EAEpC,uBAAuB,EACxB,MAAM,yBAAyB,CAAC;AAEjC;;GAEG;AACH,eAAO,MAAM,cAAc,QAAQ,CAAC;AAEpC;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,oBAAY,QAAQ,CAAC,CAAC,SAAS,KAAK,CAAC,WAAW,GAAG,OAAO,cAAc,IACtE,uBAAuB,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC;AAE1C;;GAEG;AACH,eAAO,MAAM,GAAG,EAAE,oCAAoC,CACpD,WAAW,EACX,OAAO,cAAc,CASrB,CAAC"} |
| {"version":3,"file":"For.d.ts","sourceRoot":"","sources":["../src/For.tsx"],"names":[],"mappings":";AAAA;;GAEG;AACH,MAAM,WAAW,QAAQ,CAAC,CAAC;IACzB,IAAI,EAAE,CAAC,EAAE,CAAC;IACV,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,KAAK,KAAK,CAAC,SAAS,CAAC;CACvD;AAED;;GAEG;AACH,wBAAgB,GAAG,CAAC,CAAC,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,QAAQ,CAAC,CAAC,CAAC,eAK/D"} |
| {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAE1B,cAAc,yBAAyB,CAAC"} |
| {"version":3,"file":"Show.d.ts","sourceRoot":"","sources":["../src/Show.tsx"],"names":[],"mappings":";AAAA;;GAEG;AACH,MAAM,WAAW,SAAS,CAAC,CAAC;IAC1B,IAAI,EAAE,CAAC,GAAG,SAAS,GAAG,IAAI,GAAG,KAAK,CAAC;IACnC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,KAAK,GAAG,CAAC,OAAO,CAAC,CAAC;CAC1D;AAED;;GAEG;AACH,wBAAgB,IAAI,CAAC,CAAC,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,CAAC,CAAC,CAAC,eAK1E"} |
| // This file is read by tools that parse documentation comments conforming to the TSDoc standard. | ||
| // It should be published with your NPM package. It should not be tracked by Git. | ||
| { | ||
| "tsdocVersion": "0.12", | ||
| "toolPackages": [ | ||
| { | ||
| "packageName": "@microsoft/api-extractor", | ||
| "packageVersion": "7.32.0" | ||
| } | ||
| ] | ||
| } |
+40
| import { forwardRef } from "react"; | ||
| import type { | ||
| PolymorphicForwardRefExoticComponent, | ||
| PolymorphicPropsWithoutRef, | ||
| PolymorphicPropsWithRef, | ||
| } from "react-polymorphic-types"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export type BoxProps<T extends React.ElementType = typeof defaultElement> = | ||
| PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export const Box: PolymorphicForwardRefExoticComponent< | ||
| BoxOwnProps, | ||
| typeof defaultElement | ||
| > = forwardRef(function Box< | ||
| T extends React.ElementType = typeof defaultElement | ||
| >( | ||
| { as, ...restProps }: PolymorphicPropsWithoutRef<BoxOwnProps, T>, | ||
| ref: React.ForwardedRef<Element> | ||
| ) { | ||
| const Element: React.ElementType = as || defaultElement; | ||
| return <Element ref={ref} {...restProps} />; | ||
| }); |
+18
| /** | ||
| * @public | ||
| */ | ||
| export interface ForProps<T> { | ||
| each: T[]; | ||
| fallback?: React.ReactNode; | ||
| children: (item: T, index: number) => React.ReactNode; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export function For<T>({ each, fallback, children }: ForProps<T>) { | ||
| if (each.length === 0) { | ||
| return <>{fallback}</>; | ||
| } | ||
| return <>{each.map(children)}</>; | ||
| } |
| export * from "./Box.js"; | ||
| export * from "./For.js"; | ||
| export * from "./Show.js"; | ||
| export * from "react-polymorphic-types"; |
+19
| /** | ||
| * @public | ||
| */ | ||
| export interface ShowProps<T> { | ||
| when: T | undefined | null | false; | ||
| fallback?: React.ReactNode; | ||
| element?: React.ReactNode; | ||
| children?: React.ReactNode | ((props: T) => JSX.Element); | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export function Show<T>({ when, fallback, element, children }: ShowProps<T>) { | ||
| if (when && typeof children === "function") { | ||
| return children(when); | ||
| } | ||
| return <>{when ? element ?? children : fallback}</>; | ||
| } |
| /// <reference types="react" /> | ||
| import type { PolymorphicForwardRefExoticComponent } from 'react-polymorphic-types'; | ||
| import type { PolymorphicPropsWithRef } from 'react-polymorphic-types'; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const Box: PolymorphicForwardRefExoticComponent<BoxOwnProps, typeof defaultElement>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare type BoxProps<T extends React.ElementType = typeof defaultElement> = PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function For<T>({ each, fallback, children }: ForProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ForProps<T> { | ||
| each: T[]; | ||
| fallback?: React.ReactNode; | ||
| children: (item: T, index: number) => React.ReactNode; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function Show<T>({ when, fallback, element, children }: ShowProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ShowProps<T> { | ||
| when: T | undefined | null | false; | ||
| fallback?: React.ReactNode; | ||
| element?: React.ReactNode; | ||
| children?: React.ReactNode | ((props: T) => JSX.Element); | ||
| } | ||
| export * from "react-polymorphic-types"; | ||
| export { } |
| /// <reference types="react" /> | ||
| import type { PolymorphicForwardRefExoticComponent } from 'react-polymorphic-types'; | ||
| import type { PolymorphicPropsWithRef } from 'react-polymorphic-types'; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const Box: PolymorphicForwardRefExoticComponent<BoxOwnProps, typeof defaultElement>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare type BoxProps<T extends React.ElementType = typeof defaultElement> = PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function For<T>({ each, fallback, children }: ForProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ForProps<T> { | ||
| each: T[]; | ||
| fallback?: React.ReactNode; | ||
| children: (item: T, index: number) => React.ReactNode; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function Show<T>({ when, fallback, element, children }: ShowProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ShowProps<T> { | ||
| when: T | undefined | null | false; | ||
| fallback?: React.ReactNode; | ||
| element?: React.ReactNode; | ||
| children?: React.ReactNode | ((props: T) => JSX.Element); | ||
| } | ||
| export * from "react-polymorphic-types"; | ||
| export { } |
| /// <reference types="react" /> | ||
| import type { PolymorphicForwardRefExoticComponent } from 'react-polymorphic-types'; | ||
| import type { PolymorphicPropsWithRef } from 'react-polymorphic-types'; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const Box: PolymorphicForwardRefExoticComponent<BoxOwnProps, typeof defaultElement>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare type BoxProps<T extends React.ElementType = typeof defaultElement> = PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function For<T>({ each, fallback, children }: ForProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ForProps<T> { | ||
| each: T[]; | ||
| fallback?: React.ReactNode; | ||
| children: (item: T, index: number) => React.ReactNode; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function Show<T>({ when, fallback, element, children }: ShowProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ShowProps<T> { | ||
| when: T | undefined | null | false; | ||
| fallback?: React.ReactNode; | ||
| element?: React.ReactNode; | ||
| children?: React.ReactNode | ((props: T) => JSX.Element); | ||
| } | ||
| export * from "react-polymorphic-types"; | ||
| export { } |
| /// <reference types="react" /> | ||
| import type { PolymorphicForwardRefExoticComponent } from 'react-polymorphic-types'; | ||
| import type { PolymorphicPropsWithRef } from 'react-polymorphic-types'; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const Box: PolymorphicForwardRefExoticComponent<BoxOwnProps, typeof defaultElement>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare type BoxProps<T extends React.ElementType = typeof defaultElement> = PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function For<T>({ each, fallback, children }: ForProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ForProps<T> { | ||
| each: T[]; | ||
| fallback?: React.ReactNode; | ||
| children: (item: T, index: number) => React.ReactNode; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function Show<T>({ when, fallback, element, children }: ShowProps<T>): JSX.Element; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare interface ShowProps<T> { | ||
| when: T | undefined | null | false; | ||
| fallback?: React.ReactNode; | ||
| element?: React.ReactNode; | ||
| children?: React.ReactNode | ((props: T) => JSX.Element); | ||
| } | ||
| export * from "react-polymorphic-types"; | ||
| export { } |
+14
-2
| /// <reference types="react" /> | ||
| import type { PolymorphicForwardRefExoticComponent, PolymorphicPropsWithRef } from "react-polymorphic-types"; | ||
| declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export interface BoxOwnProps { | ||
| className?: string; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare type BoxProps<T extends React.ElementType = typeof defaultElement> = PolymorphicPropsWithRef<BoxOwnProps, T>; | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare const Box: PolymorphicForwardRefExoticComponent<BoxOwnProps, typeof defaultElement>; | ||
| export {}; | ||
| //# sourceMappingURL=Box.d.ts.map |
+7
-1
| import { jsx as _jsx } from "react/jsx-runtime"; | ||
| import { forwardRef } from "react"; | ||
| const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export const defaultElement = "div"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export const Box = forwardRef(function Box({ as, ...restProps }, ref) { | ||
@@ -5,0 +11,0 @@ const Element = as || defaultElement; |
+1
-1
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"Box.js","sourceRoot":"","sources":["../src/Box.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAOnC,MAAM,cAAc,GAAG,KAAK,CAAC;AAS7B,MAAM,CAAC,MAAM,GAAG,GAGZ,UAAU,CAAC,SAAS,GAAG,CAGzB,EAAE,EAAE,EAAE,GAAG,SAAS,EAA8C,EAChE,GAAgC;IAEhC,MAAM,OAAO,GAAsB,EAAE,IAAI,cAAc,CAAC;IACxD,OAAO,KAAC,OAAO,IAAC,GAAG,EAAE,GAAG,KAAM,SAAS,GAAI,CAAC;AAC9C,CAAC,CAAC,CAAC"} | ||
| {"version":3,"file":"Box.js","sourceRoot":"","sources":["../src/Box.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAOnC;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,KAAK,CAAC;AAepC;;GAEG;AACH,MAAM,CAAC,MAAM,GAAG,GAGZ,UAAU,CAAC,SAAS,GAAG,CAGzB,EAAE,EAAE,EAAE,GAAG,SAAS,EAA8C,EAChE,GAAgC;IAEhC,MAAM,OAAO,GAAsB,EAAE,IAAI,cAAc,CAAC;IACxD,OAAO,KAAC,OAAO,IAAC,GAAG,EAAE,GAAG,KAAM,SAAS,GAAI,CAAC;AAC9C,CAAC,CAAC,CAAC"} |
+7
-0
| /// <reference types="react" /> | ||
| /** | ||
| * @public | ||
| */ | ||
| export interface ForProps<T> { | ||
@@ -7,2 +10,6 @@ each: T[]; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function For<T>({ each, fallback, children }: ForProps<T>): JSX.Element; | ||
| //# sourceMappingURL=For.d.ts.map |
+3
-0
| import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export function For({ each, fallback, children }) { | ||
@@ -3,0 +6,0 @@ if (each.length === 0) { |
+1
-1
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"For.js","sourceRoot":"","sources":["../src/For.tsx"],"names":[],"mappings":";AAMA,MAAM,UAAU,GAAG,CAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAe;IAC9D,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QACrB,OAAO,4BAAG,QAAQ,GAAI,CAAC;KACxB;IACD,OAAO,4BAAG,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAI,CAAC;AACnC,CAAC"} | ||
| {"version":3,"file":"For.js","sourceRoot":"","sources":["../src/For.tsx"],"names":[],"mappings":";AASA;;GAEG;AACH,MAAM,UAAU,GAAG,CAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAe;IAC9D,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QACrB,OAAO,4BAAG,QAAQ,GAAI,CAAC;KACxB;IACD,OAAO,4BAAG,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,GAAI,CAAC;AACnC,CAAC"} |
+4
-3
@@ -1,4 +0,5 @@ | ||
| export * from "./Box"; | ||
| export * from "./For"; | ||
| export * from "./Show"; | ||
| export * from "./Box.js"; | ||
| export * from "./For.js"; | ||
| export * from "./Show.js"; | ||
| export * from "react-polymorphic-types"; | ||
| //# sourceMappingURL=index.d.ts.map |
+3
-3
@@ -1,5 +0,5 @@ | ||
| export * from "./Box"; | ||
| export * from "./For"; | ||
| export * from "./Show"; | ||
| export * from "./Box.js"; | ||
| export * from "./For.js"; | ||
| export * from "./Show.js"; | ||
| export * from "react-polymorphic-types"; | ||
| //# sourceMappingURL=index.js.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAO,CAAC;AACtB,cAAc,OAAO,CAAC;AACtB,cAAc,QAAQ,CAAC;AAEvB,cAAc,yBAAyB,CAAC"} | ||
| {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAE1B,cAAc,yBAAyB,CAAC"} |
+7
-0
| /// <reference types="react" /> | ||
| /** | ||
| * @public | ||
| */ | ||
| export interface ShowProps<T> { | ||
@@ -8,2 +11,6 @@ when: T | undefined | null | false; | ||
| } | ||
| /** | ||
| * @public | ||
| */ | ||
| export declare function Show<T>({ when, fallback, element, children }: ShowProps<T>): JSX.Element; | ||
| //# sourceMappingURL=Show.d.ts.map |
+3
-0
| import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime"; | ||
| /** | ||
| * @public | ||
| */ | ||
| export function Show({ when, fallback, element, children }) { | ||
@@ -3,0 +6,0 @@ if (when && typeof children === "function") { |
+1
-1
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"Show.js","sourceRoot":"","sources":["../src/Show.tsx"],"names":[],"mappings":";AAOA,MAAM,UAAU,IAAI,CAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAgB;IACzE,IAAI,IAAI,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;QAC1C,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC;KACvB;IACD,OAAO,4BAAG,IAAI,CAAC,CAAC,CAAC,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,QAAQ,CAAC,CAAC,CAAC,QAAQ,GAAI,CAAC;AACtD,CAAC"} | ||
| {"version":3,"file":"Show.js","sourceRoot":"","sources":["../src/Show.tsx"],"names":[],"mappings":";AAUA;;GAEG;AACH,MAAM,UAAU,IAAI,CAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAgB;IACzE,IAAI,IAAI,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;QAC1C,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC;KACvB;IACD,OAAO,4BAAG,IAAI,CAAC,CAAC,CAAC,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,QAAQ,CAAC,CAAC,CAAC,QAAQ,GAAI,CAAC;AACtD,CAAC"} |
+19
-15
| { | ||
| "name": "rc-basic", | ||
| "version": "1.0.0", | ||
| "version": "1.0.1", | ||
| "description": "😎 A react basic component library.", | ||
@@ -20,4 +20,17 @@ "keywords": [ | ||
| "files": [ | ||
| "dist" | ||
| "dist", | ||
| "src", | ||
| "typings" | ||
| ], | ||
| "scripts": { | ||
| "prebuild": "pnpm clean", | ||
| "build": "del dist && tsc --project ./tsconfig.build.json && pnpm api-extractor run --local --verbose", | ||
| "dev": "tsc -w", | ||
| "preinstall": "npx only-allow pnpm -y", | ||
| "prepare": "is-ci || husky install", | ||
| "release": "release-it", | ||
| "release:ci": "release-it --ci", | ||
| "preversion": "pnpm build", | ||
| "postversion": "git push --follow-tags" | ||
| }, | ||
| "lint-staged": { | ||
@@ -33,6 +46,7 @@ "*.{ts,tsx}": "eslint", | ||
| "devDependencies": { | ||
| "@microsoft/api-extractor": "7.32.0", | ||
| "@types/react": "18.0.21", | ||
| "@types/react-dom": "18.0.6", | ||
| "@typescript-eslint/eslint-plugin": "5.38.1", | ||
| "@typescript-eslint/parser": "5.38.1", | ||
| "@typescript-eslint/eslint-plugin": "5.39.0", | ||
| "@typescript-eslint/parser": "5.39.0", | ||
| "del-cli": "5.0.0", | ||
@@ -76,13 +90,3 @@ "eslint": "8.24.0", | ||
| } | ||
| }, | ||
| "scripts": { | ||
| "prebuild": "pnpm clean", | ||
| "build": "del dist && tsc -b", | ||
| "dev": "tsc -w", | ||
| "preinstall": "npx only-allow pnpm -y", | ||
| "release": "release-it", | ||
| "release:ci": "release-it --ci", | ||
| "preversion": "pnpm build", | ||
| "postversion": "git push --follow-tags" | ||
| } | ||
| } | ||
| } |
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
19041
103.17%28
86.67%366
590.57%20
5.26%1
Infinity%