Skip to content

Commit 62a17a6

Browse files
committed
feature: align cover svg to viewer
1 parent 1b3bb5e commit 62a17a6

File tree

4 files changed

+19131
-18
lines changed

4 files changed

+19131
-18
lines changed

docs/documentation.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,8 @@
6464
| `setValue(value)` | Through this method you can set a new value |
6565
| `getTool()` | Get current tool |
6666
| `changeTool(tool)` | Change the tool (one of `none`,`pan`,`zoom-in`,`zoom-out`,`auto`) |
67-
| `openMiniature` | Open the miniature |
68-
| `closeMiniature` | Close the miniature |
67+
| `openMiniature` | Open the miniature |
68+
| `closeMiniature` | Close the miniature |
6969

7070
## Event attributes
7171
To your event handlers will be passed an instance of `ViewerMouseEvent` or `ViewerTouchEvent` (as the case). They have some useful attributes that map event positions to SVG coords.
@@ -107,8 +107,8 @@ import {
107107
//components
108108
ReactSVGPanZoom, //Controlled component
109109
UncontrolledReactSVGPanZoom, //Uncontrolled component
110-
111-
//functions to manipulate the state. The signature is quite similar to component methods, expect for the first parameter that is the current value. These are usefull only for some advanced integrations (e.g. reducers).
110+
111+
//functions to manipulate the state. The signature is quite similar to component methods, expect for the first parameter that is the current value. These are usefull only for some advanced integrations (e.g. reducers).
112112
setPointOnViewerCenter, //setPointOnViewerCenter(value, SVGPointX, SVGPointY, zoomLevel)
113113
reset, //reset(value)
114114
pan, //pan(value, SVGDeltaX, SVGDeltaY)
@@ -118,35 +118,34 @@ import {
118118
zoomOnViewerCenter, //zoomOnViewerCenter(value, scaleFactor)
119119
openMiniature,
120120
closeMiniature,
121-
121+
122122
//constants
123123
MODE_IDLE,
124124
MODE_PANNING,
125125
MODE_ZOOMING,
126-
126+
127127
TOOL_AUTO,
128128
TOOL_NONE,
129129
TOOL_PAN,
130130
TOOL_ZOOM_IN,
131131
TOOL_ZOOM_OUT,
132-
132+
133133
POSITION_NONE,
134134
POSITION_TOP,
135135
POSITION_RIGHT,
136136
POSITION_BOTTOM,
137137
POSITION_LEFT,
138-
138+
139139
ACTION_ZOOM,
140140
ACTION_PAN,
141-
141+
142142
ALIGN_CENTER,
143143
ALIGN_LEFT,
144144
ALIGN_RIGHT,
145145
ALIGN_TOP,
146146
ALIGN_BOTTOM,
147-
147+
ALIGN_COVER
148+
148149
INITIAL_VALUE
149150
} from 'react-svg-pan-zoom'
150151
```
151-
152-

0 commit comments

Comments
 (0)