@jamadd/react-native-template-ui 0.7.15 → 0.7.16
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/lib/module/components/view/ThemedScreenWrap.js +8 -0
- package/lib/module/components/view/ThemedScreenWrap.js.map +1 -1
- package/lib/typescript/src/components/view/ThemedScreenWrap.d.ts +1 -1
- package/lib/typescript/src/components/view/ThemedScreenWrap.d.ts.map +1 -1
- package/lib/typescript/src/types/view.d.ts +6 -2
- package/lib/typescript/src/types/view.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
import { useEffect } from 'react';
|
|
3
4
|
import { useInsetsStyle } from "../../hooks/style.js";
|
|
4
5
|
import { composeStyles } from "../../utils/style/func.js";
|
|
5
6
|
import ThemedView from "./ThemedView.js";
|
|
6
7
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
8
|
const ThemedScreenWrap = ({
|
|
9
|
+
effectSetup,
|
|
10
|
+
effectCleanup,
|
|
11
|
+
effectDependencies = [],
|
|
8
12
|
style: themedScreenWrapStyle,
|
|
9
13
|
insets,
|
|
10
14
|
insetTop,
|
|
@@ -30,6 +34,10 @@ const ThemedScreenWrap = ({
|
|
|
30
34
|
insetPaddingLeft,
|
|
31
35
|
insetPaddingRight
|
|
32
36
|
});
|
|
37
|
+
useEffect(() => {
|
|
38
|
+
effectSetup?.();
|
|
39
|
+
return effectCleanup;
|
|
40
|
+
}, effectDependencies);
|
|
33
41
|
const style = composeStyles(themedScreenWrapStyle, insetsStyle);
|
|
34
42
|
return /*#__PURE__*/_jsx(ThemedView, {
|
|
35
43
|
flex: 1,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useInsetsStyle","composeStyles","ThemedView","jsx","_jsx","ThemedScreenWrap","style","themedScreenWrapStyle","insets","insetTop","insetBottom","insetLeft","insetRight","insetsPadding","insetPaddingTop","insetPaddingBottom","insetPaddingLeft","insetPaddingRight","props","insetsStyle","flex"],"sourceRoot":"../../../../src","sources":["components/view/ThemedScreenWrap.tsx"],"mappings":";;
|
|
1
|
+
{"version":3,"names":["useEffect","useInsetsStyle","composeStyles","ThemedView","jsx","_jsx","ThemedScreenWrap","effectSetup","effectCleanup","effectDependencies","style","themedScreenWrapStyle","insets","insetTop","insetBottom","insetLeft","insetRight","insetsPadding","insetPaddingTop","insetPaddingBottom","insetPaddingLeft","insetPaddingRight","props","insetsStyle","flex"],"sourceRoot":"../../../../src","sources":["components/view/ThemedScreenWrap.tsx"],"mappings":";;AAAA,SAASA,SAAS,QAAiB,OAAO;AAE1C,SAASC,cAAc,QAAQ,sBAAmB;AAElD,SAASC,aAAa,QAAQ,2BAAwB;AACtD,OAAOC,UAAU,MAAM,iBAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAEtC,MAAMC,gBAA2C,GAAGA,CAAC;EACnDC,WAAW;EACXC,aAAa;EACbC,kBAAkB,GAAG,EAAE;EACvBC,KAAK,EAAEC,qBAAqB;EAC5BC,MAAM;EACNC,QAAQ;EACRC,WAAW;EACXC,SAAS;EACTC,UAAU;EACVC,aAAa;EACbC,eAAe;EACfC,kBAAkB;EAClBC,gBAAgB;EAChBC,iBAAiB;EACjB,GAAGC;AACL,CAAC,KAAK;EACJ,MAAMC,WAAW,GAAGtB,cAAc,CAAC;IACjCW,MAAM;IACNC,QAAQ;IACRC,WAAW;IACXC,SAAS;IACTC,UAAU;IACVC,aAAa;IACbC,eAAe;IACfC,kBAAkB;IAClBC,gBAAgB;IAChBC;EACF,CAAC,CAAC;EACFrB,SAAS,CAAC,MAAM;IACdO,WAAW,GAAG,CAAC;IAEf,OAAOC,aAAa;EACtB,CAAC,EAAEC,kBAAkB,CAAC;EAEtB,MAAMC,KAAK,GAAGR,aAAa,CAAYS,qBAAqB,EAAEY,WAAW,CAAC;EAE1E,oBAAOlB,IAAA,CAACF,UAAU;IAACqB,IAAI,EAAE,CAAE;IAACd,KAAK,EAAEA,KAAM;IAAA,GAAKY;EAAK,CAAG,CAAC;AACzD,CAAC;AAED,eAAehB,gBAAgB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ThemedScreenWrap.d.ts","sourceRoot":"","sources":["../../../../../src/components/view/ThemedScreenWrap.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,
|
|
1
|
+
{"version":3,"file":"ThemedScreenWrap.d.ts","sourceRoot":"","sources":["../../../../../src/components/view/ThemedScreenWrap.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAa,KAAK,EAAE,EAAE,MAAM,OAAO,CAAC;AAG3C,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAI9D,QAAA,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CAsC/C,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BoxProps } from '@shopify/restyle';
|
|
2
|
-
import type { ReactNode, RefObject } from 'react';
|
|
2
|
+
import type { DependencyList, ReactNode, RefObject } from 'react';
|
|
3
3
|
import type { NativeScrollEvent, NativeSyntheticEvent, ScrollViewProps as RNScrollViewProps, ScrollView, View, ViewProps } from 'react-native';
|
|
4
4
|
import type { AnimatedRef } from 'react-native-reanimated';
|
|
5
5
|
import type { InsetsStyleConfig } from './style';
|
|
@@ -15,7 +15,11 @@ export type ThemedViewProps = ViewProps & BoxProps<Theme> & {
|
|
|
15
15
|
export type AnimatedThemedViewProps = Omit<ThemedViewProps, 'ref'> & {
|
|
16
16
|
ref?: AnimatedRef<View>;
|
|
17
17
|
};
|
|
18
|
-
export type ThemedScreenWrapProps = ThemedViewProps & InsetsStyleConfig
|
|
18
|
+
export type ThemedScreenWrapProps = ThemedViewProps & InsetsStyleConfig & {
|
|
19
|
+
effectSetup?: () => void;
|
|
20
|
+
effectCleanup?: () => void;
|
|
21
|
+
effectDependencies?: DependencyList;
|
|
22
|
+
};
|
|
19
23
|
export type ScrollViewProps = RNScrollViewProps & InsetsStyleConfig & {
|
|
20
24
|
ref?: ScrollViewRefObj;
|
|
21
25
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../../../src/types/view.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../../../src/types/view.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,KAAK,EACV,iBAAiB,EACjB,oBAAoB,EACpB,eAAe,IAAI,iBAAiB,EACpC,UAAU,EACV,IAAI,EACJ,SAAS,EACV,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AACjD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAErC,MAAM,MAAM,UAAU,GAAG,SAAS,CAAC,IAAI,GAAG,IAAI,CAAC,CAAC;AAEhD,MAAM,MAAM,gBAAgB,GAAG,SAAS,CAAC,UAAU,GAAG,IAAI,CAAC,CAAC;AAE5D,MAAM,MAAM,wBAAwB,GAAG,WAAW,CAAC,UAAU,CAAC,CAAC;AAE/D,MAAM,MAAM,QAAQ,GAAG,CAAC,KAAK,EAAE,oBAAoB,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;AAEhF,MAAM,MAAM,mBAAmB,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;AAE1E,MAAM,MAAM,eAAe,GAAG,SAAS,GACrC,QAAQ,CAAC,KAAK,CAAC,GAAG;IAChB,GAAG,CAAC,EAAE,UAAU,CAAC;CAClB,CAAC;AAEJ,MAAM,MAAM,uBAAuB,GAAG,IAAI,CAAC,eAAe,EAAE,KAAK,CAAC,GAAG;IACnE,GAAG,CAAC,EAAE,WAAW,CAAC,IAAI,CAAC,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,eAAe,GACjD,iBAAiB,GAAG;IAClB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,kBAAkB,CAAC,EAAE,cAAc,CAAC;CACrC,CAAC;AAEJ,MAAM,MAAM,eAAe,GAAG,iBAAiB,GAC7C,iBAAiB,GAAG;IAAE,GAAG,CAAC,EAAE,gBAAgB,CAAA;CAAE,CAAC;AAEjD,MAAM,MAAM,qBAAqB,GAAG,eAAe,GACjD,IAAI,CAAC,eAAe,EAAE,KAAK,CAAC,CAAC;AAE/B,MAAM,MAAM,yBAAyB,CAAC,CAAC,GAAG,OAAO,IAAI,CAAC,GAAG;IACvD,QAAQ,EAAE,WAAW,CAAC,SAAS,CAAC,CAAC;CAClC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jamadd/react-native-template-ui",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.16",
|
|
4
4
|
"description": "React Native Template UI is a collection of UI components designed by JaMa D&D.",
|
|
5
5
|
"main": "./lib/module/index.js",
|
|
6
6
|
"types": "./lib/typescript/src/index.d.ts",
|