https://github.com/vaadin-component-factory/vcf-svg
Web Component for manipulating and animating SVGs.
https://github.com/vaadin-component-factory/vcf-svg
Last synced: 23 days ago
JSON representation
Web Component for manipulating and animating SVGs.
- Host: GitHub
- URL: https://github.com/vaadin-component-factory/vcf-svg
- Owner: vaadin-component-factory
- License: apache-2.0
- Created: 2020-05-21T11:49:17.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2024-07-29T18:52:50.000Z (10 months ago)
- Last Synced: 2024-11-01T16:08:06.957Z (7 months ago)
- Language: JavaScript
- Homepage:
- Size: 151 KB
- Stars: 1
- Watchers: 3
- Forks: 2
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# <vcf-svg>
[](https://gitter.im/vaadin/web-components?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
[](https://www.npmjs.com/package/@vaadin-component-factory/vcf-svg)
[](https://vaadin.com/directory/component/vaadin-component-factoryvcf-svg)Web Component for manipulating and animating [SVG](https://developer.mozilla.org/en-US/docs/Web/SVG).
- Web Component wrapper for the JS library [SVG.js](https://svgjs.com/docs/3.0).
- Zoom and pan functionality implemented with [d3-zoom](https://github.com/d3/d3-zoom).
- Draggable functionality implemented with plugin [svg.draggable.js](https://github.com/svgdotjs/svg.draggable.js).
[Live demo ↗](https://vcf-svg.netlify.com)
|
[API documentation ↗](https://vcf-svg.netlify.com/api/#/elements/Vaadin.VcfSvg)## Installation
Install `vcf-svg`:
```sh
npm i @vaadin-component-factory/vcf-svg --save
```## Usage
Once installed, import it in your application:
```js
import '@vaadin-component-factory/vcf-svg';
```Add `` element to the page.
```html
```
## Running demo
1. Fork the `vcf-svg` repository and clone it locally.
1. Make sure you have [npm](https://www.npmjs.com/) installed.
1. When in the `vcf-svg` directory, run `npm install` to install dependencies.
1. Run `npm start` to open the demo.
## Server-side API
This is the client-side (Polymer 3) web component. If you are looking for this web components server-side (Java) API for the Vaadin Platform, it can be found here: [Svg Component](https://vaadin.com/directory/component/svg-component)
## License & Author
This Add-on is distributed under Apache 2.0
Component Factory svg is written by Vaadin Ltd.
### Sponsored development
Major pieces of development of this add-on has been sponsored by multiple customers of Vaadin. Read more about Expert on Demand at: [Support](https://vaadin.com/support) and [Pricing](https://vaadin.com/pricing)