@octane-xplat/gif 0.7.2 → 0.9.0
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 +29 -0
- package/dist/native/octane-client-build.json +1 -1
- package/dist/web/octane-client-build.json +1 -1
- package/package.json +16 -14
- package/src/index.ts +2 -2
- package/src/index.web.ts +2 -2
package/README.md
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# `@octane-xplat/gif`
|
|
2
|
+
|
|
3
|
+
Animated images (GIF, animated WebP) for Octane xplat apps: a plain
|
|
4
|
+
`<img>` on web and `@nativescript-community/ui-image`
|
|
5
|
+
(Fresco on Android / SDWebImage on iOS) on native, with a macOS entry.
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
pnpm add @octane-xplat/gif
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
```tsx
|
|
12
|
+
import { AnimatedImage } from '@octane-xplat/gif'
|
|
13
|
+
|
|
14
|
+
;<AnimatedImage
|
|
15
|
+
src="https://example.com/loader.gif"
|
|
16
|
+
alt="Loading"
|
|
17
|
+
stretch="aspectFit" // 'none' | 'fill' | 'aspectFit' | 'aspectFill'
|
|
18
|
+
width={96}
|
|
19
|
+
height={96}
|
|
20
|
+
/>
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
`stretch` shares the core `Image` grammar — web maps it to `object-fit`
|
|
24
|
+
and the plugin accepts the same values natively. For Lottie JSON
|
|
25
|
+
animations use [`@octane-xplat/lottie`](../lottie/README.md) instead.
|
|
26
|
+
|
|
27
|
+
Per-target limits are recorded in
|
|
28
|
+
[known limits](../../docs/known-limits.md). Exercised by
|
|
29
|
+
[`AnimatedImageDemo`](../demos/src/AnimatedImageDemo.tsrx).
|
package/package.json
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@octane-xplat/gif",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.0",
|
|
4
4
|
"description": "Animated images (GIF/animated webp) for Octane xplat — web <img> + @nativescript-community/ui-image",
|
|
5
5
|
"keywords": [
|
|
6
|
-
"
|
|
7
|
-
"xplat",
|
|
8
|
-
"cross-platform",
|
|
9
|
-
"gif",
|
|
6
|
+
"android",
|
|
10
7
|
"animated-image",
|
|
11
8
|
"animated-webp",
|
|
9
|
+
"cross-platform",
|
|
10
|
+
"gif",
|
|
12
11
|
"image",
|
|
13
|
-
"nativescript",
|
|
14
12
|
"ios",
|
|
15
|
-
"
|
|
16
|
-
"
|
|
13
|
+
"nativescript",
|
|
14
|
+
"octane",
|
|
15
|
+
"web",
|
|
16
|
+
"xplat"
|
|
17
17
|
],
|
|
18
|
-
"license": "MIT",
|
|
19
18
|
"homepage": "https://github.com/octane-xplat/octane-xplat/tree/main/packages/gif",
|
|
19
|
+
"license": "MIT",
|
|
20
20
|
"repository": {
|
|
21
21
|
"type": "git",
|
|
22
|
-
"url": "
|
|
22
|
+
"url": "https://github.com/octane-xplat/octane-xplat",
|
|
23
23
|
"directory": "packages/gif"
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
@@ -53,12 +53,12 @@
|
|
|
53
53
|
"@nativescript-community/ui-image": "4.6.20"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
|
-
"@nativescript-community/octane": "0.2.
|
|
56
|
+
"@nativescript-community/octane": "0.2.4",
|
|
57
57
|
"@nativescript/core": "9.1.2",
|
|
58
58
|
"@octanejs/vite-plugin": "0.1.61",
|
|
59
59
|
"@tsrx/typescript-plugin": "0.4.11",
|
|
60
60
|
"octane": "0.6.3",
|
|
61
|
-
"tsrx-typegen": "0.1
|
|
61
|
+
"tsrx-typegen": "0.2.1",
|
|
62
62
|
"typescript": "5.9.3",
|
|
63
63
|
"vite": "8.3.0"
|
|
64
64
|
},
|
|
@@ -76,7 +76,9 @@
|
|
|
76
76
|
}
|
|
77
77
|
},
|
|
78
78
|
"scripts": {
|
|
79
|
-
"build": "vite build && vite build --mode native &&
|
|
80
|
-
"test:packed": "node tests/packed-consumer.mjs"
|
|
79
|
+
"build": "vite build && vite build --mode native && pnpm typegen && node ../../scripts/check-native-dist.mjs",
|
|
80
|
+
"test:packed": "node tests/packed-consumer.mjs",
|
|
81
|
+
"typegen": "tsrx-typegen --target octane",
|
|
82
|
+
"pack:check": "tsrx-typegen --pack-check"
|
|
81
83
|
}
|
|
82
84
|
}
|
package/src/index.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// Platform barrels — explicit .tsrx leaf imports (moduleSuffixes don't
|
|
2
2
|
// reach .tsrx; same convention as @octane-xplat/ui index.*.ts).
|
|
3
|
-
export { AnimatedImage } from './AnimatedImage.tsrx'
|
|
4
|
-
export type { AnimatedImageProps } from './props'
|
|
3
|
+
export { AnimatedImage } from './AnimatedImage.tsrx'
|
|
4
|
+
export type { AnimatedImageProps } from './props'
|
package/src/index.web.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// Platform barrels — explicit .tsrx leaf imports (moduleSuffixes don't
|
|
2
2
|
// reach .tsrx; same convention as @octane-xplat/ui index.*.ts).
|
|
3
|
-
export { AnimatedImage } from './AnimatedImage.web.tsrx'
|
|
4
|
-
export type { AnimatedImageProps } from './props'
|
|
3
|
+
export { AnimatedImage } from './AnimatedImage.web.tsrx'
|
|
4
|
+
export type { AnimatedImageProps } from './props'
|