|
18 | 18 | !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
19 | 19 | !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! |
20 | 20 | !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> |
21 | | -<h1 align="center">@nativescript-community/ui-zoomimage</h1> |
| 21 | +<h1 align="center">@nativescript-community/ui-image-colorfilter</h1> |
22 | 22 | <p align="center"> |
23 | | - <a href="https://npmcharts.com/compare/@nativescript-community/ui-zoomimage?minimal=true"><img alt="Downloads per month" src="https://img.shields.io/npm/dm/@nativescript-community/ui-zoomimage.svg" height="20"/></a> |
24 | | -<a href="https://www.npmjs.com/package/@nativescript-community/ui-zoomimage"><img alt="NPM Version" src="https://img.shields.io/npm/v/@nativescript-community/ui-zoomimage.svg" height="20"/></a> |
| 23 | + <a href="https://npmcharts.com/compare/@nativescript-community/ui-image-colorfilter?minimal=true"><img alt="Downloads per month" src="https://img.shields.io/npm/dm/@nativescript-community/ui-image-colorfilter.svg" height="20"/></a> |
| 24 | +<a href="https://www.npmjs.com/package/@nativescript-community/ui-image-colorfilter"><img alt="NPM Version" src="https://img.shields.io/npm/v/@nativescript-community/ui-image-colorfilter.svg" height="20"/></a> |
25 | 25 | </p> |
26 | 26 |
|
27 | 27 | <p align="center"> |
28 | | - <b>Zoomable image view based on @nativescript-community/ui-image</b></br> |
| 28 | + <b>color matrix filters for @nativescript-community/ui-image</b></br> |
29 | 29 | <sub><sub> |
30 | 30 | </p> |
31 | 31 |
|
|
56 | 56 | ## Installation |
57 | 57 | Run the following command from the root of your project: |
58 | 58 |
|
59 | | -`ns plugin add @nativescript-community/ui-zoomimage` |
| 59 | +`ns plugin add @nativescript-community/ui-image-colorfilter` |
60 | 60 |
|
61 | 61 |
|
62 | 62 | [](#setup) |
63 | 63 |
|
64 | 64 | ## setup |
65 | 65 |
|
66 | | -```javascript |
67 | | -import imageModule = require("@nativescript-community/ui-zoomimage"); |
| 66 | +```typescript |
| 67 | +import { installMixins } from "@nativescript-community/ui-image-colorfilter"; |
68 | 68 |
|
69 | 69 | //do this before creating any image view |
70 | | -imageModule.initialize({ isDownsampleEnabled: true }); |
| 70 | +installMixins(); |
71 | 71 | ``` |
72 | 72 |
|
73 | | -This component directly inherint `@nativescript-community/ui-image` so you can find the doc [here]() |
74 | 73 |
|
75 | | -It adds a few properties |
| 74 | +It adds one property `colorMatrix` which is a `number[]` |
| 75 | +You can find samples color matrix [here](https://github.com/skratchdot/color-matrix) |
76 | 76 |
|
77 | 77 |
|
78 | 78 | [](#demos) |
@@ -100,7 +100,7 @@ $ ns run ios|android |
100 | 100 | To run the demos, you must clone this repo **recursively**. |
101 | 101 |
|
102 | 102 | ``` |
103 | | -git clone https://github.com/@nativescript-community/ui-zoomimage.git --recursive |
| 103 | +git clone https://github.com/@nativescript-community/ui-image-colorfilter.git --recursive |
104 | 104 | ``` |
105 | 105 |
|
106 | 106 | **Install Dependencies:** |
|
0 commit comments