forked from Shinonome/dots-hyprland
add cloudflare warp icon
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<g clip-path="url(#clip0_26_18)">
|
||||
<path d="M3 7.06015V4.74436C4.12 4.69624 4.90412 4.62466 5.35237 4.52962C6.06664 4.37804 6.64769 4.07549 7.09553 3.62195C7.40205 3.31158 7.63448 2.89754 7.7928 2.37985C7.8839 2.06947 7.92946 1.8387 7.92946 1.68752H10.9001V19H7.25588V7.06015H3ZM12.4228 5.65444V4.52962L15.0783 1H16.1879V4.64211H17V5.65444H16.1879V7.05594H15.0084V5.65444H12.4228ZM14.9823 2.53985L13.4031 4.64511H15.0102V2.53985H14.9823Z" fill="black"/>
|
||||
</g>
|
||||
<defs>
|
||||
<clipPath id="clip0_26_18">
|
||||
<rect width="20" height="20" fill="white"/>
|
||||
</clipPath>
|
||||
</defs>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 660 B |
@@ -121,14 +121,17 @@ export const ModuleCloudflareWarp = async (props = {}) => {
|
||||
enabled: false,
|
||||
},
|
||||
className: 'txt-small sidebar-iconbutton',
|
||||
tooltipText: 'WARP',
|
||||
tooltipText: 'Cloudflare WARP',
|
||||
onClicked: (self) => {
|
||||
self.attribute.enabled = !self.attribute.enabled;
|
||||
self.toggleClassName('sidebar-button-active', self.attribute.enabled);
|
||||
if (self.attribute.enabled) Utils.execAsync('warp-cli connect').catch(print)
|
||||
else Utils.execAsync('warp-cli disconnect').catch(print);
|
||||
},
|
||||
child: MaterialIcon('dns', 'norm'),
|
||||
child: Widget.Icon({
|
||||
icon: 'cloudflare-dns-symbolic',
|
||||
className: 'txt-norm',
|
||||
}),
|
||||
setup: (self) => {
|
||||
setupCursorHover(self);
|
||||
self.attribute.enabled = !exec(`bash -c 'warp-cli status | grep Disconnected'`);
|
||||
|
||||
@@ -85,7 +85,7 @@ const timeRow = Box({
|
||||
|
||||
const togglesBox = Widget.Box({
|
||||
hpack: 'center',
|
||||
className: 'sidebar-togglesbox spacing-h-10',
|
||||
className: 'sidebar-togglesbox spacing-h-5',
|
||||
children: [
|
||||
ToggleIconWifi(),
|
||||
ToggleIconBluetooth(),
|
||||
|
||||
Reference in New Issue
Block a user