forked from quasarframework/quasar
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTouchPan.json
More file actions
188 lines (173 loc) · 4.97 KB
/
TouchPan.json
File metadata and controls
188 lines (173 loc) · 4.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
{
"meta": {
"docsUrl": "https://v1.quasar.dev/vue-directives/touch-pan"
},
"value": {
"type": "Function",
"desc": "Handler for panning (use a non-function to disable)",
"params": {
"details": {
"type": "Object",
"desc": "Event details",
"definition": {
"evt": {
"type": "Object",
"desc": "Original JS event Object",
"__exemption": [ "examples" ]
},
"touch": {
"type": "Boolean",
"desc": "Triggered by a touch event"
},
"mouse": {
"type": "Boolean",
"desc": "Triggered by a mouse event"
},
"position": {
"type": "Object",
"desc": "Event Position Object",
"definition": {
"top": {
"type": "Number",
"desc": "Vertical offset from top of window",
"examples": [ 235 ]
},
"left": {
"type": "Number",
"desc": "Horizontal offset from left of window",
"examples": [ 235 ]
}
}
},
"direction": {
"type": "String",
"desc": "Direction of movement",
"values": [ "up", "right", "down", "left" ]
},
"isFirst": {
"type": "Boolean",
"desc": "Is first time the handler is called since movement started"
},
"isFinal": {
"type": "Boolean",
"desc": "Is last time the handler is called since movement ended"
},
"duration": {
"type": "Number",
"desc": "How long it took to trigger the event (in milliseconds)",
"examples": [ 612 ]
},
"distance": {
"type": "Object",
"desc": "Absolute distance (in pixels) since movement started from initial point",
"definition": {
"x": {
"type": "Number",
"desc": "Absolute distance horizontally",
"examples": [ 231 ]
},
"y": {
"type": "Number",
"desc": "Absolute distance vertically",
"examples": [ 231 ]
}
}
},
"offset": {
"type": "Object",
"desc": "Distance (in pixels) since movement started from initial point",
"definition": {
"x": {
"type": "Number",
"desc": "Distance horizontally",
"examples": [ -231, 110 ]
},
"y": {
"type": "Number",
"desc": "Distance vertically",
"examples": [ -231, 110 ]
}
}
},
"delta": {
"type": "Object",
"desc": "Delta of distance (in pixels) since handler was called last time",
"definition": {
"x": {
"type": "Number",
"desc": "Distance horizontally",
"examples": [ 2 ]
},
"y": {
"type": "Number",
"desc": "Distance vertically",
"examples": [ 1 ]
}
}
}
}
}
},
"returns": null,
"examples": [ "v-touch-pan=\"fnToCall\"", "v-touch-pan=\"void 0\"" ]
},
"modifiers": {
"stop": {
"type": "Boolean",
"desc": "Stop event propagation for touch events"
},
"prevent": {
"type": "Boolean",
"desc": "Calls event.preventDefault() for touch events"
},
"mightPrevent": {
"type": "Boolean",
"desc": "Required when you might call event.preventDefault() in your handler for touch events"
},
"capture": {
"type": "Boolean",
"desc": "Use capture for touchstart event"
},
"mouse": {
"type": "Boolean",
"desc": "Listen for mouse events too"
},
"mouseCapture": {
"type": "Boolean",
"desc": "Use capture for mousedown event"
},
"mouseAllDir": {
"type": "Boolean",
"desc": "Ignore initial mouse move direction (do not abort if the first mouse move is in an unaccepted direction)"
},
"preserveCursor": {
"type": "Boolean",
"desc": "Prevent the mouse cursor from automatically displaying as grabbing when panning",
"addedIn": "v1.13.0"
},
"horizontal": {
"type": "Boolean",
"desc": "Catch horizontal (left/right) movement"
},
"vertical": {
"type": "Boolean",
"desc": "Catch vertical (up/down) movement"
},
"up": {
"type": "Boolean",
"desc": "Catch panning to up"
},
"right": {
"type": "Boolean",
"desc": "Catch panning to right"
},
"down": {
"type": "Boolean",
"desc": "Catch panning to down"
},
"left": {
"type": "Boolean",
"desc": "Catch panning to left"
}
}
}