Skip to content

Commit bb3d7e0

Browse files
authored
Merge pull request #27 from PixisVI/patch-1
feat: add vpn to the network service
2 parents 36dd4c9 + 8a38ced commit bb3d7e0

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

src/content/docs/services/network.md

+31
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ This service is somewhat incomplete, feel free to open a PR to improve it
1313
* `primary`: `"wifi" | "wired"`
1414
* `wired`: `Wired`
1515
* `wifi`: `Wifi`
16+
* `vpn`: `Vpn`
1617

1718
## methods
1819

@@ -58,6 +59,36 @@ meaning you can't bind to it or use notify::prop signal
5859
* `state`: `string`: [NM.DeviceState](https://gjs-docs.gnome.org/nm10~1.0/nm.devicestate) as lowercase string
5960
* `icon-name`: `string`
6061

62+
## Vpn
63+
64+
### signals
65+
66+
* `connection-added`: `(uuid: string)`
67+
* `connection-removed`: `(uuid: string)`
68+
69+
### properties
70+
71+
* `connections`: `VpnConnection[]`
72+
* `activated-connections`: `VpnConnection[]`
73+
74+
### methods
75+
76+
* `getConnection`: `(uuid: string) => VpnConnection`
77+
78+
## VpnConnection
79+
80+
### properties
81+
82+
* `uuid`: `string`
83+
* `id`: `string`: The unique name of the connection
84+
* `state`: `"connected" | "connecting" | "disconnecting" | "disconnected"`
85+
* `vpn-state`: `"unknown" | "prepare" | "needs_auth" | "connect" | "ip_config" | "activated" | "failed" | "disconnected"`
86+
* `icon-name`: `string`
87+
88+
### methods
89+
90+
* `setConnection`: `(connect: boolean) => void`
91+
6192
## Example Widget
6293

6394
```js

0 commit comments

Comments
 (0)