@molecule/app-ui-react-native 1.0.8 → 1.0.10
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/README.md
CHANGED
|
@@ -3,7 +3,7 @@ AUTO-GENERATED — DO NOT EDIT THIS FILE.
|
|
|
3
3
|
Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
|
|
4
4
|
Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
|
|
5
5
|
To change this document, edit the module-level JSDoc in src/index.ts.
|
|
6
|
-
Generated: 2026-11-
|
|
6
|
+
Generated: 2026-11-16T01:09:21.575Z
|
|
7
7
|
-->
|
|
8
8
|
|
|
9
9
|
# @molecule/app-ui-react-native
|
|
@@ -2112,7 +2112,7 @@ Peer dependencies:
|
|
|
2112
2112
|
- `@molecule/app-i18n` ^1.0.1
|
|
2113
2113
|
- `@molecule/app-icons` ^1.0.1
|
|
2114
2114
|
- `@molecule/app-react` ^4.4.0
|
|
2115
|
-
- `@molecule/app-ui` ^1.
|
|
2115
|
+
- `@molecule/app-ui` ^1.3.10
|
|
2116
2116
|
- `react` ^18.0.0 || ^19.0.0
|
|
2117
2117
|
- `react-native` >=0.72.0
|
|
2118
2118
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Skeleton.d.ts","sourceRoot":"","sources":["../../src/components/Skeleton.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"Skeleton.d.ts","sourceRoot":"","sources":["../../src/components/Skeleton.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAA8B,MAAM,OAAO,CAAA;AAGlD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAGrD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,QAAQ,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CAgD5C,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC;IAClC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CASA,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC;IACpC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAEA,CAAA"}
|
|
@@ -4,7 +4,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
4
4
|
*
|
|
5
5
|
* @module
|
|
6
6
|
*/
|
|
7
|
-
import { useEffect,
|
|
7
|
+
import { useEffect, useState } from 'react';
|
|
8
8
|
import { Animated, View } from 'react-native';
|
|
9
9
|
import { getClassMap } from '@molecule/app-ui';
|
|
10
10
|
/**
|
|
@@ -20,7 +20,9 @@ import { getClassMap } from '@molecule/app-ui';
|
|
|
20
20
|
*/
|
|
21
21
|
export const Skeleton = ({ width, height, circle, animation = 'pulse', className, testId, }) => {
|
|
22
22
|
const cm = getClassMap();
|
|
23
|
-
|
|
23
|
+
// The animated value is created once per mount and kept in state; a ref would
|
|
24
|
+
// have to be read while rendering.
|
|
25
|
+
const [opacity] = useState(() => new Animated.Value(1));
|
|
24
26
|
useEffect(() => {
|
|
25
27
|
if (animation === 'pulse') {
|
|
26
28
|
const pulse = Animated.loop(Animated.sequence([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../src/components/Toast.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"Toast.d.ts","sourceRoot":"","sources":["../../src/components/Toast.tsx"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAsE,MAAM,OAAO,CAAA;AAI1F,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAGlD;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,KAAK,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CAwDtC,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,cAAc,EAAE,KAAK,CAAC,EAAE,CAAC;IACpC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,QAAQ,CAAC,EAAE,KAAK,GAAG,WAAW,GAAG,UAAU,GAAG,QAAQ,GAAG,cAAc,GAAG,aAAa,CAAA;CACxF,CAGA,CAAA;AASD,UAAU,iBAAiB;IACzB,KAAK,EAAE,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,WAAW,CAAC,KAAK,MAAM,CAAA;IACvD,OAAO,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;CAC9B;AAMD;;;;;;GAMG;AACH,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC;IACnC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,QAAQ,CAAC,EAAE,KAAK,GAAG,WAAW,GAAG,UAAU,GAAG,QAAQ,GAAG,cAAc,GAAG,aAAa,CAAA;CACxF,CAuBA,CAAA;AAED;;;GAGG;AACH,wBAAgB,QAAQ,IAAI,iBAAiB,CAW5C"}
|
package/dist/components/Toast.js
CHANGED
|
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
4
4
|
*
|
|
5
5
|
* @module
|
|
6
6
|
*/
|
|
7
|
-
import { createContext, useCallback, useContext, useEffect,
|
|
7
|
+
import { createContext, useCallback, useContext, useEffect, useState } from 'react';
|
|
8
8
|
import { Animated, Pressable, Text, View } from 'react-native';
|
|
9
9
|
import { useTranslation } from '@molecule/app-react';
|
|
10
10
|
import { getClassMap } from '@molecule/app-ui';
|
|
@@ -27,7 +27,9 @@ export const Toast = ({ title, description, status, duration = 5000, dismissible
|
|
|
27
27
|
const classes = cm.cn(cm.toast({
|
|
28
28
|
variant: (status || 'default'),
|
|
29
29
|
}), className);
|
|
30
|
-
|
|
30
|
+
// The animated value is created once per mount and kept in state; a ref would
|
|
31
|
+
// have to be read while rendering.
|
|
32
|
+
const [opacity] = useState(() => new Animated.Value(1));
|
|
31
33
|
useEffect(() => {
|
|
32
34
|
if (duration > 0) {
|
|
33
35
|
const timer = setTimeout(() => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@molecule/app-ui-react-native",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.10",
|
|
4
4
|
"description": "React Native UI component implementations for molecule.dev",
|
|
5
5
|
"homepage": "https://www.molecule.dev/packages/app-ui-react-native",
|
|
6
6
|
"type": "module",
|
|
@@ -34,10 +34,10 @@
|
|
|
34
34
|
"directory": "packages/app/frameworks/react-native-ui"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@molecule/app-i18n": "1.2.
|
|
37
|
+
"@molecule/app-i18n": "1.2.2",
|
|
38
38
|
"@molecule/app-icons": "1.0.4",
|
|
39
|
-
"@molecule/app-react": "4.
|
|
40
|
-
"@molecule/app-ui": "1.
|
|
39
|
+
"@molecule/app-react": "4.8.0",
|
|
40
|
+
"@molecule/app-ui": "1.4.0",
|
|
41
41
|
"@types/node": "26.6.5",
|
|
42
42
|
"react": "19.3.1",
|
|
43
43
|
"react-dom": "19.3.1",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"@molecule/app-i18n": "^1.0.1",
|
|
49
49
|
"@molecule/app-icons": "^1.0.1",
|
|
50
50
|
"@molecule/app-react": "^4.4.0",
|
|
51
|
-
"@molecule/app-ui": "^1.
|
|
51
|
+
"@molecule/app-ui": "^1.3.10",
|
|
52
52
|
"react": "^18.0.0 || ^19.0.0",
|
|
53
53
|
"react-native": ">=0.72.0"
|
|
54
54
|
},
|