react-globe.gl 2.34.0 → 2.36.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -47,6 +47,7 @@ A React component to represent data visualization layers on a 3-dimensional glob
47
47
  * [Tiled Map Engine](https://vasturiano.github.io/react-globe.gl/example/tile-engine/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/tile-engine/index.html))
48
48
  * [Custom Globe Styling](https://vasturiano.github.io/react-globe.gl/example/custom-globe-styling/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/custom-globe-styling/index.html))
49
49
  * [Custom Layer](https://vasturiano.github.io/react-globe.gl/example/custom-layer/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/custom-layer/index.html))
50
+ * [Glitch Post-Processing Effect](https://vasturiano.github.io/react-globe.gl/example/post-processing-fx/index.html) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/post-processing-fx/index.html))
50
51
  * [World Population](https://vasturiano.github.io/react-globe.gl/example/world-population/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/world-population/index.html))
51
52
  * [Population Heatmap](https://vasturiano.github.io/react-globe.gl/example/population-heatmap/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/population-heatmap/index.html))
52
53
  * [Recent Earthquakes](https://vasturiano.github.io/react-globe.gl/example/earthquakes/) ([source](https://github.com/vasturiano/react-globe.gl/blob/master/example/earthquakes/index.html))
@@ -171,8 +172,10 @@ ReactDOM.render(
171
172
  | <b>arcLabel</b> | <i>string</i> or <i>func</i> | `name` | Arc object accessor function or attribute for label (shown as tooltip). Supports plain text or HTML content. |
172
173
  | <b>arcStartLat</b> | <i>number</i>, <i>string</i> or <i>func</i> | `startLat` | Arc object accessor function, attribute or a numeric constant for the line's start latitude coordinate. |
173
174
  | <b>arcStartLng</b> | <i>number</i>, <i>string</i> or <i>func</i> | `startLng` | Arc object accessor function, attribute or a numeric constant for the line's start longitude coordinate. |
175
+ | <b>arcStartAltitude</b> | <i>number</i>, <i>string</i> or <i>func</i> | 0 | Arc object accessor function, attribute or a numeric constant for the line's start altitude. |
174
176
  | <b>arcEndLat</b> | <i>number</i>, <i>string</i> or <i>func</i> | `endLat` | Arc object accessor function, attribute or a numeric constant for the line's end latitude coordinate. |
175
177
  | <b>arcEndLng</b> | <i>number</i>, <i>string</i> or <i>func</i> | `endLng` | Arc object accessor function, attribute or a numeric constant for the line's end longitude coordinate. |
178
+ | <b>arcEndAltitude</b> | <i>number</i>, <i>string</i> or <i>func</i> | 0 | Arc object accessor function, attribute or a numeric constant for the line's end altitude. |
176
179
  | <b>arcColor</b> | <i>string</i>, <i>[string, ...]</i> or <i>func</i> | `() => '#ffffaa'` | Arc object accessor function or attribute for the line's color. Also supports color gradients by passing an array of colors, or a color interpolator function. |
177
180
  | <b>arcAltitude</b> | <i>number</i>, <i>string</i> or <i>func</i>| `null` |Arc object accessor function, attribute or a numeric constant for the arc's maximum altitude (ocurring at the half-way distance between the two points) in terms of globe radius units (`0` = 0 altitude (ground line), `1` = globe radius). If a value of `null` or `undefined` is used, the altitude is automatically set proportionally to the distance between the two points, according to the scale set in `arcAltitudeAutoScale`. |
178
181
  | <b>arcAltitudeAutoScale</b> | <i>number</i>, <i>string</i> or <i>func</i> | 0.5 | Arc object accessor function, attribute or a numeric constant for the scale of the arc's automatic altitude, in terms of units of the great-arc distance between the two points. A value of `1` indicates the arc should be as high as its length on the ground. Only applicable if `arcAltitude` is not set. |
@@ -454,6 +457,7 @@ ReactDOM.render(
454
457
  | <b>enablePointerInteraction</b> | <i>bool</i> | `true` | Whether to enable the mouse tracking events. This activates an internal tracker of the canvas mouse position and enables the functionality of object hover/click and tooltip labels, at the cost of performance. If you're looking for maximum gain in your globe performance it's recommended to switch off this property. |
455
458
  | <b>pointerEventsFilter</b> | <i>func</i> | `() => true` | Filter function which defines whether a particular object can be the target of pointer interactions. In general, objects that are closer to the camera get precedence in capturing pointer events. This function allows having ignored object layers so that pointer events can be passed through to deeper objects in the various globe layers. The ThreeJS object and its associated data (if any) are passed as arguments: `pointerEventsFilter(obj, data)`. The function should return a boolean value. |
456
459
  | <b>lineHoverPrecision</b> | <i>number</i> | 0.2 | Precision to use when detecting hover events over [Line](https://threejs.org/docs/#api/objects/Line) and [Points](https://threejs.org/docs/#api/objects/Points) objects, such as arcs, paths or particles. |
460
+ | <b>showPointerCursor</b> | <i>bool</i> or <i>func</i> | `true` | Whether to show a pointer cursor when hovering over clickable portions of the globe. Accepts either a `boolean` constant or a callback function which receives the object (type and data) currently under the cursor and is expected to return a `boolean` value. |
457
461
 
458
462
  | Method | Arguments | Description |
459
463
  | --- | :--: | --- |
@@ -84,8 +84,10 @@ interface GlobeProps extends ConfigOptions {
84
84
  arcsData?: object[];
85
85
  arcStartLat?: ObjAccessor<number>;
86
86
  arcStartLng?: ObjAccessor<number>;
87
+ arcStartAltitude?: ObjAccessor<number>;
87
88
  arcEndLat?: ObjAccessor<number>;
88
89
  arcEndLng?: ObjAccessor<number>;
90
+ arcEndAltitude?: ObjAccessor<number>;
89
91
  arcColor?: ObjAccessor<string | string[] | ((t: number) => string)>;
90
92
  arcAltitude?: ObjAccessor<number | null>;
91
93
  arcAltitudeAutoScale?: ObjAccessor<number>;
@@ -284,6 +286,7 @@ interface GlobeProps extends ConfigOptions {
284
286
  enablePointerInteraction?: boolean;
285
287
  pointerEventsFilter?: (object: Object3D, data?: object) => boolean;
286
288
  lineHoverPrecision?: number;
289
+ showPointerCursor?: boolean | ((objType: string, objData: object) => boolean);
287
290
  onZoom?: (pov: GeoCoords) => void;
288
291
  }
289
292