mendixlabs / image-viewer

MOVED to:
https://github.com/mendix/widgets-resources/tree/master/packages-web/image-viewer
Apache License 2.0
0 stars 2 forks source link

Build Status Dependency Status Dev Dependency Status codecov

Image viewer

Display an image and optional perform an action on click: mobile friendly enlarge, open a page or call a mircoflow.

Features

Dependencies

Mendix 7.13.1

Demo project

https://imageviewer.mxapps.io/

Usage

The widget requires a context.

Data source: Dynamic image

Data source: Dynamic URL attribute

Data source: Static URL

Data source: Static image

Issues, suggestions and feature requests

We are actively maintaining this widget, please report any issues or suggestion for improvement at https://github.com/mendixlabs/image-viewer/issues.

Development

Prerequisite: Install git, node package manager, webpack CLI, grunt CLI, Karma CLI

To contribute, fork and clone.

git clone https://github.com/FlockOfBirds/image-viewer.git

The code is in typescript. Use a typescript IDE of your choice, like Visual Studio Code or WebStorm.

To set up the development environment, run:

npm install

Create a folder named dist in the project root.

Create a Mendix test project in the dist folder and rename its root folder to MxTestProject. Changes to the widget code shall be automatically pushed to this test project. Or get the test project from https://github.com/MendixLabs/image-viewer/releases/latest

dist/MxTestProject

To automatically compile, bundle and push code changes to the running test project, run:

grunt

To run the project unit tests with code coverage, results can be found at dist/testresults/coverage/index.html, run:

npm test

or run the test continuously during development:

karma start