Skip to content

Commit 79f74b0

Browse files
Merge pull request #444 from SwiftFiddle/styling
Styling
2 parents 232b640 + c5d06a1 commit 79f74b0

File tree

3 files changed

+16
-4
lines changed

3 files changed

+16
-4
lines changed

Public/css/common.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,9 @@
5757
#debugger-button {
5858
background-color: rgba(51, 51, 51, 0.05);
5959
border-radius: 15px;
60-
border-width: 0;
60+
border-width: 1px;
61+
border-color: #dee2e6;
62+
border-style: solid;
6163
color: #333333;
6264
cursor: pointer;
6365
display: inline-block;

Public/index.html

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,8 @@ <h1 class="h5 my-2">
144144
</div>
145145
<div class="col align-self-center">
146146
<div class="text-end mt-2">
147-
<button id="debugger-button" data-bs-toggle="modal" data-bs-target="#debugger-modal">Debug</button>
147+
<button id="debugger-button" class="px-3" data-bs-toggle="modal"
148+
data-bs-target="#debugger-modal">Debugger</button>
148149
<span id="match-count" class="text-bg-light border px-3 py-1">no match</span>
149150
</div>
150151
</div>
@@ -166,7 +167,7 @@ <h1 class="h5 my-2">
166167
<div class="modal fade" id="debugger-modal" tabindex="-1" aria-labelledby="debugger-modal-title" aria-hidden="true">
167168
<div class="modal-dialog modal-dialog-scrollable modal-xl">
168169
<div class="modal-content">
169-
<div class="modal-header">
170+
<div class="modal-header py-2">
170171
<h1 class="modal-title fs-5" id="debugger-modal-title">Regex Debugger</h1>
171172
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
172173
</div>
@@ -205,7 +206,11 @@ <h1 class="modal-title fs-5" id="debugger-modal-title">Regex Debugger</h1>
205206

206207
<div class="flex-grow-1">
207208
<label for="debugger-step-range" class="form-label" style="font-weight: 600;">Match Steps</label>
208-
<input id="debugger-step-range" type="range" class="form-range" value="1" min="1" max="100">
209+
<div class="d-flex">
210+
<input id="debugger-step-range" type="range" class="form-range flex-grow-1" value="1" min="1"
211+
max="100">
212+
<div id="debugger-step-range-max" class="ms-3">100</div>
213+
</div>
209214
<p class="mb-0" style="text-align: center">
210215
<button id="debugger-go-start" class="btn btn-sm btn-outline-secondary rounded-circle button-circle">
211216
<i class="fa-solid fa-backward-step fa-lg"></i>

Public/js/app.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -371,6 +371,11 @@ export class App {
371371
const matchStepRange = document.getElementById("debugger-step-range");
372372
matchStepRange.max = metrics.stepCount;
373373

374+
const matchStepRangeMax = document.getElementById(
375+
"debugger-step-range-max"
376+
);
377+
matchStepRangeMax.textContent = metrics.stepCount;
378+
374379
const instructions = document.getElementById("debugger-instructions");
375380
instructions.innerHTML = "";
376381

0 commit comments

Comments
 (0)