-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
attempting to check system host in javascript
- Loading branch information
Showing
11 changed files
with
179 additions
and
9 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
body { | ||
/*background-color: black*/ | ||
padding: 20px; | ||
padding-top: 40px; | ||
} | ||
|
||
h1, h2, h3, h4, h5, h6, p { | ||
color: white; | ||
font-family: 'Inter'; | ||
} | ||
|
||
@font-face { | ||
font-family: 'Inter'; | ||
src: url('assets/fonts/inter/Inter-Regular.ttf'); | ||
} | ||
|
||
.titlebar { | ||
background-color: #00000070; | ||
position: fixed; | ||
left: 0; | ||
top: 0; | ||
width: 100%; | ||
display: flex; | ||
flex-direction: row; | ||
align-items: center; | ||
gap: 10px; | ||
height: 40px; | ||
z-index: 10; | ||
} | ||
|
||
.close { | ||
background-color: #00000000; | ||
border: 0; | ||
width: 40px; | ||
height: 40px; | ||
} | ||
|
||
.close:hover { | ||
background-color: #00000050; | ||
scale: 1.05; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title>zdkrimson</title> | ||
<link rel="stylesheet" href="help.css"> | ||
<script src='help.js'></script> | ||
</head> | ||
<div class=titlebar> | ||
<button onclick='closeHelp()' class=close> | ||
<img width=30 src=assets/icons/arrowback.svg> | ||
</button> | ||
<p>Documentation</p> | ||
</div> | ||
<body> | ||
<p>Documentation will be worked on <i>eventually</i></p> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
function closeHelp() { | ||
// Send message from iframe to parent window | ||
window.parent.postMessage('hideDocs', '*'); | ||
} | ||
|
||
document.addEventListener('DOMContentLoaded', function() { | ||
if (window.self === window.top) { | ||
// Not inside an iframe | ||
document.body.style.backgroundColor = 'darkred'; | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import webview | ||
import modelfetch | ||
|
||
syshost=modelfetch.system.Model | ||
|
||
class Api: | ||
def get_host(self): | ||
return syshost | ||
|
||
api = Api() | ||
webview.create_window('zdkrimson', background_color="#210202", url="index.html", js_api=api) | ||
webview.start(private_mode=False, debug=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import wmi | ||
|
||
c = wmi.WMI() | ||
system = c.Win32_ComputerSystem()[0] | ||
print(system.Model) | ||
hostinfo = system.Model |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters