Skip to content

Commit 456e6f1

Browse files
committed
Remove WiFi clients overlay usage examples from README
Deleted configuration and example usage sections for the WiFi clients overlay from the README to streamline documentation. Updated section heading for GeoJSON handling. Also updated netjsonmap-multipleTiles.gif in docs/gifs.
1 parent 54fa78d commit 456e6f1

File tree

2 files changed

+1
-53
lines changed

2 files changed

+1
-53
lines changed

README.md

Lines changed: 1 addition & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -488,31 +488,6 @@ Looking for configuration details? See the inline docs and type hints in the sou
488488

489489
It's possible to render small colored circles around each node to represent the amount of connected WiFi clients. The overlay counts WiFi clients as a single total. This helper draws on the same ZRender layer as the graph, so the markers follow pan/zoom/force layout without extra work and do not call `setOption` during the main render.
490490

491-
### Configuration
492-
493-
- **Example**: See `public/example_templates/netjsongraph-wifi-clients.html` with dataset `public/assets/data/netjsongraph-wifi-clients.json`
494-
495-
#### Example Usage
496-
497-
```javascript
498-
const graph = new NetJSONGraph("../assets/data/netjsongraph-wifi-clients.json", {
499-
render: "graph",
500-
onReady() {
501-
// Attach the client overlay once the graph is ready
502-
this.attachClientsOverlay({
503-
// --- Optional configuration ---
504-
radius: 5, // Radius of each client dot in pixels
505-
gap: 3, // Distance from the node's edge to the first ring of dots
506-
colors: {
507-
wifi: "#d35454",
508-
},
509-
minZoomLevel: 1, // Only show dots when zoom level is at or above this value
510-
});
511-
},
512-
});
513-
graph.render();
514-
```
515-
516491
For a live demo, see the [WiFi Clients Graph example](https://openwisp.github.io/netjsongraph.js/examples/netjsongraph-wifi-clients.html).
517492

518493
#### Data Format
@@ -523,34 +498,7 @@ The number of dots rendered around a node is determined by the `clients` field i
523498
- If it's an Array, its length is used as the client count (and the sidebar lists Client [i] entries, e.g., MAC addresses).
524499
- If it's a Number, the value is used directly as the count.
525500

526-
**Example Node Data**:
527-
528-
```javascript
529-
{
530-
"nodes": [
531-
{
532-
"id": "A",
533-
"label": "Node A",
534-
// Shows 1 primary client dot. Displays details in the sidebar.
535-
"clients": [{"mac": "d8:5d:4c:f1:aa:62"}]
536-
},
537-
{
538-
"id": "B",
539-
"label": "Node B",
540-
// Shows 2 primary client dots.
541-
"clients": [{"mac": "..."}, {"mac": "..."}]
542-
},
543-
{
544-
"id": "C",
545-
"label": "Node C",
546-
// Shows 1 primary client dot.
547-
"clients": 1
548-
}
549-
]
550-
}
551-
```
552-
553-
### GeoJSON handling
501+
## GeoJSON handling
554502

555503
netjsongraph.js will now **always** convert GeoJSON input into an internal
556504
NetJSON‐like structure (`nodes` / `links`). The original GeoJSON object is kept
495 KB
Loading

0 commit comments

Comments
 (0)