Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion backend/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion backend/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "controller-tools"
version = "0.2.0"
version = "0.2.1"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ControllerTools",
"version": "0.2.0",
"version": "0.2.1",
"description": "The missing game controller menu. Displays the current battery % and charging status",
"scripts": {
"build": "shx rm -rf dist && rollup -c",
Expand Down
8 changes: 4 additions & 4 deletions src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -115,14 +115,14 @@ const Content: VFC<{ serverAPI: ServerAPI }> = ({ }) => {
{
(controller.capacity > 0 || controller.status !== "unknown") &&
<div className={gamepadDialogClasses.FieldChildren}>
<IconContext.Provider value={{ style: { verticalAlign: 'middle', marginRight: '4px' }, size: '2em' }}>
{getBatteryIcon(controller)}
</IconContext.Provider>
{
// since we don't have battery level yet for Xbox, don't show capactiy for the MS vendor
controller.vendorId != 1118 &&
<span>{controller.capacity}%</span>
<span style={{ display: "inline-block", textAlign: "right", }}>{controller.capacity}%</span>
}
<IconContext.Provider value={{ style: { verticalAlign: 'middle', marginLeft: "6px" }, size: '2em' }}>
{getBatteryIcon(controller)}
</IconContext.Provider>
</div>
}
</div>
Expand Down