@plasmicapp/react-web 0.2.87 → 0.2.89
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/all.d.ts +1 -1
- package/dist/react-utils.d.ts +1 -1
- package/dist/react-web.cjs.development.js +12 -6
- package/dist/react-web.cjs.development.js.map +1 -1
- package/dist/react-web.cjs.production.min.js +1 -1
- package/dist/react-web.cjs.production.min.js.map +1 -1
- package/dist/react-web.esm.js +12 -6
- package/dist/react-web.esm.js.map +1 -1
- package/package.json +1 -1
- package/skinny/dist/plume/triggered-overlay/index.js +1 -2
- package/skinny/dist/plume/triggered-overlay/index.js.map +1 -1
- package/skinny/dist/react-utils-7c01e440.js.map +1 -1
- package/skinny/dist/react-utils.d.ts +1 -1
- package/skinny/dist/render/PlasmicImg/index.js +8 -3
- package/skinny/dist/render/PlasmicImg/index.js.map +1 -1
package/dist/all.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ type ClassNamesExport = ClassNamesFn & { default: ClassNamesFn };
|
|
|
19
19
|
declare function pick<T>(obj: T, ...keys: (string | number | symbol)[]): Partial<T>;
|
|
20
20
|
declare function omit<T>(obj: T, ...keys: (keyof T)[]): Partial<T>;
|
|
21
21
|
|
|
22
|
-
declare type StrictProps<T, TExpected> = Exclude<keyof T, keyof TExpected> extends never ? {} : "Unexpected extraneous props"
|
|
22
|
+
declare type StrictProps<T, TExpected> = Exclude<keyof T, keyof TExpected> extends never ? {} : Partial<"Unexpected extraneous props">;
|
|
23
23
|
declare type HTMLElementRefOf<T extends keyof JSX.IntrinsicElements> = Exclude<React__default.ComponentProps<T>["ref"], string>;
|
|
24
24
|
|
|
25
25
|
interface Variants {
|
package/dist/react-utils.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ export declare function isReactText(child: React.ReactNode): child is React.Reac
|
|
|
13
13
|
export declare function isReactChild(child: React.ReactNode): child is React.ReactChild;
|
|
14
14
|
export declare function isReactFragment(child: React.ReactNode): child is React.ReactElement;
|
|
15
15
|
export declare function isReactNode(x: any): boolean;
|
|
16
|
-
export declare type StrictProps<T, TExpected> = Exclude<keyof T, keyof TExpected> extends never ? {} : "Unexpected extraneous props"
|
|
16
|
+
export declare type StrictProps<T, TExpected> = Exclude<keyof T, keyof TExpected> extends never ? {} : Partial<"Unexpected extraneous props">;
|
|
17
17
|
export declare type HTMLElementRefOf<T extends keyof JSX.IntrinsicElements> = Exclude<React.ComponentProps<T>["ref"], string>;
|
|
18
18
|
export declare function mergeProps(props: Record<string, any>, ...restProps: Record<string, any>[]): Record<string, any>;
|
|
19
19
|
export declare function mergeRefs<T>(...refs: (React.Ref<T> | undefined)[]): (value: T) => void;
|
|
@@ -820,7 +820,14 @@ var PlasmicImg = /*#__PURE__*/React__default.forwardRef(function PlasmicImg(prop
|
|
|
820
820
|
loader = props.loader,
|
|
821
821
|
imgRef = props.imgRef,
|
|
822
822
|
style = props.style,
|
|
823
|
-
|
|
823
|
+
loading = props.loading,
|
|
824
|
+
rest = _objectWithoutPropertiesLoose(props, ["src", "className", "displayWidth", "displayHeight", "displayMinWidth", "displayMinHeight", "displayMaxWidth", "displayMaxHeight", "quality", "loader", "imgRef", "style", "loading"]);
|
|
825
|
+
|
|
826
|
+
var imgProps = Object.assign({}, rest, {
|
|
827
|
+
// Default loading to "lazy" if not specified (which is different from the
|
|
828
|
+
// html img, which defaults to eager!)
|
|
829
|
+
loading: loading != null ? loading : "lazy"
|
|
830
|
+
});
|
|
824
831
|
|
|
825
832
|
var _ref = typeof src === "string" || !src ? {
|
|
826
833
|
fullWidth: undefined,
|
|
@@ -838,7 +845,8 @@ var PlasmicImg = /*#__PURE__*/React__default.forwardRef(function PlasmicImg(prop
|
|
|
838
845
|
src: srcStr,
|
|
839
846
|
className: className,
|
|
840
847
|
style: style
|
|
841
|
-
},
|
|
848
|
+
}, imgProps, {
|
|
849
|
+
loading: loading,
|
|
842
850
|
ref: mergeRefs(imgRef, outerRef)
|
|
843
851
|
}));
|
|
844
852
|
}
|
|
@@ -953,7 +961,7 @@ var PlasmicImg = /*#__PURE__*/React__default.forwardRef(function PlasmicImg(prop
|
|
|
953
961
|
quality: quality,
|
|
954
962
|
ref: imgRef,
|
|
955
963
|
style: style ? pick(style, "objectFit", "objectPosition") : undefined,
|
|
956
|
-
imgProps:
|
|
964
|
+
imgProps: imgProps,
|
|
957
965
|
className: "__wab_img"
|
|
958
966
|
}));
|
|
959
967
|
});
|
|
@@ -2977,9 +2985,7 @@ function useTriggeredOverlay(plasmicClass, props, config, outerRef) {
|
|
|
2977
2985
|
restoreFocus: true
|
|
2978
2986
|
}, React.createElement(reactAria.DismissButton, {
|
|
2979
2987
|
onDismiss: state.close
|
|
2980
|
-
}), children,
|
|
2981
|
-
onDismiss: state.close
|
|
2982
|
-
})), _extends2));
|
|
2988
|
+
}), children), _extends2));
|
|
2983
2989
|
|
|
2984
2990
|
var overrides = (_overrides = {}, _overrides[config.root] = {
|
|
2985
2991
|
props: mergeProps(overlayProps, getStyleProps(props), {
|