Skip to content

Commit b3fef7e

Browse files
committed
Converted last remaining glyphicons to bootstrap icons.
Inlined a few styles to compensate for local static file problem. Fixed info softAPMacAddress label.
1 parent 9e15bef commit b3fef7e

File tree

4 files changed

+39
-20
lines changed

4 files changed

+39
-20
lines changed

esp8266-fastled-webserver/data/index.htm

+16-6
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,19 @@
2020
<link rel="stylesheet" href="css/styles.css">
2121

2222
<link rel="icon" href="images/atom196.png">
23+
24+
<style>
25+
.col-form-label {
26+
text-align: right;
27+
}
28+
29+
.btn-color {
30+
width: 40px;
31+
}
32+
</style>
2333
</head>
2434

25-
<body>
35+
<body style="padding-bottom: 80px;">
2636

2737
<nav class="navbar navbar-expand-md navbar-light bg-light mb-4" id="top" role="banner">
2838
<div class="container-fluid">
@@ -73,15 +83,15 @@ <h2 class="accordion-header" id="headingImportExport">
7383
<div class="btn-toolbar" role="toolbar">
7484
<div class="btn-group me-2" role="group">
7585
<button type="button" class="btn btn-outline-secondary" id="btnExport">
76-
<span class="glyphicon glyphicon-arrow-down" aria-hidden="true"></span>
86+
<i class="bi bi-download"></i>
7787
Load Values
7888
</button>
7989
<button type="button" class="btn btn-outline-secondary" id="btnImport">
80-
<span class="glyphicon glyphicon-arrow-up" aria-hidden="true"></span>
90+
<i class="bi bi-upload"></i>
8191
Set Values
8292
</button>
8393
<button type="button" class="btn btn-outline-secondary" id="btnCopy">
84-
<span class="glyphicon glyphicon-copy" aria-hidden="true"></span>
94+
<i class="bi bi-clipboard"></i>
8595
Copy
8696
</button>
8797
</div>
@@ -96,14 +106,14 @@ <h2 class="accordion-header" id="headingImportExport">
96106
<div class="input-group">
97107
<input id="inputFilename" type="text" class="form-control" style="width: 180px;" value="preset1.json" />
98108
<button type="button" class="btn btn-outline-secondary" id="btnSave">
99-
<span class="glyphicon glyphicon-save" aria-hidden="true"></span>
109+
<i class="bi bi-save"></i>
100110
Save
101111
</button>
102112

103113
<input type="file" id="inputFile" style="display: none;" />
104114

105115
<button type="button" class="btn btn-outline-secondary" id="btnOpen">
106-
<span class="glyphicon glyphicon-open" aria-hidden="true"></span>
116+
<i class="bi bi-folder2-open"></i>
107117
Open
108118
</button>
109119
</div>

esp8266-fastled-webserver/data/info.htm

+7-1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@
1616
<link rel="stylesheet" href="css/styles.css">
1717

1818
<link rel="icon" href="images/atom196.png">
19+
20+
<style>
21+
.dt {
22+
text-align: right;
23+
}
24+
</style>
1925
</head>
2026

2127
<body>
@@ -52,7 +58,7 @@
5258
</dl>
5359

5460
<dl id="templates" class="row" style="display: none">
55-
<dt id="infoDtTemplate" class="col-sm-3"></dt>
61+
<dt id="infoDtTemplate" class="col-sm-3 dt"></dt>
5662
<dd id="infoDdTemplate" class="col-sm-9"></dd>
5763
</dl>
5864

esp8266-fastled-webserver/data/js/info.js

+10-7
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ const keyToName = {
3434
softAPSSID: "Soft AP SSID",
3535
softAPIP: "Soft AP IP Address",
3636
BSSID: "BSSID",
37-
softAPmacAddress: "Soft AP MAC Address",
37+
softAPMacAddress: "Soft AP MAC Address",
3838
};
3939

4040
$(document).ready(function () {
@@ -53,8 +53,8 @@ $(document).ready(function () {
5353
$("#status").html("Loading, please wait...");
5454

5555
Object.keys(data).forEach((key) => {
56-
var dtTemplate = $("#infoDtTemplate").clone();
57-
var ddTemplate = $("#infoDdTemplate").clone();
56+
var dt = $("#infoDtTemplate").clone();
57+
var dd = $("#infoDdTemplate").clone();
5858

5959
const name = keyToName[key] || key;
6060
let value = data[key];
@@ -78,11 +78,14 @@ $(document).ready(function () {
7878
break;
7979
}
8080

81-
dtTemplate.html(name);
82-
ddTemplate.html(value);
81+
dt.attr("id", `dt-${key}`);
82+
dt.html(name);
8383

84-
$("#infoDl").append(dtTemplate);
85-
$("#infoDl").append(ddTemplate);
84+
dd.attr("id", `dd-${key}`);
85+
dd.html(value);
86+
87+
$("#infoDl").append(dt);
88+
$("#infoDl").append(dd);
8689
});
8790
});
8891

esp8266-fastled-webserver/data/simple.htm

+6-6
Original file line numberDiff line numberDiff line change
@@ -22,22 +22,22 @@
2222

2323
<div id="container" class="container">
2424

25-
<div class="row">
26-
<button type="button" class="col-2 btn btn-outline-secondary" id="btnOn" style="margin: 5px;">On</button>
27-
<button type="button" class="col-2 btn btn-outline-secondary" id="btnOff" style="margin: 5px;">Off</button>
25+
<div class="row g-1" style="margin-bottom: 4px; margin-top: 4px;">
26+
<button type="button" class="col-2 btn btn-outline-secondary" id="btnOn" style="margin-right: 4px">On</button>
27+
<button type="button" class="col-2 btn btn-outline-secondary" id="btnOff">Off</button>
2828
</div>
2929

30-
<div id="patterns" class="row"></div>
30+
<div id="patterns" class="row g-1" style="margin-bottom: 4px;"></div>
3131

32-
<div id="colors" class="row"></div>
32+
<div id="colors" class="row" style="margin-left: 0px; margin-right: 0px;"></div>
3333

3434
<span class="navbar-text" id="status">Loading, please wait...</span>
3535

3636
</div>
3737

3838
<div id="templates" style="display: none">
3939

40-
<button id="patternButtonTemplate" class="col btn btn-outline-secondary pattern" style="margin: 5px;"></button>
40+
<button id="patternButtonTemplate" class="col btn btn-outline-secondary pattern" style="margin-right: 4px;"></button>
4141

4242
<button id="colorButtonTemplate" class="col-1 btn btn-outline-secondary color" style="border: none; border-radius: 0px; height: 42px;"></div>
4343

0 commit comments

Comments
 (0)