Skip to content

Commit 8e50391

Browse files
committed
Change input field to a switch, reposition it
1 parent 7638a91 commit 8e50391

File tree

1 file changed

+20
-10
lines changed

1 file changed

+20
-10
lines changed

examples/index.html

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,22 +26,32 @@ <h1>KVS WebRTC Test Page</h1>
2626
<div id="main" class="d-none">
2727
<form id="form" onsubmit="return false">
2828
<h4 id="subheader">KVS Endpoint</h4>
29+
<div class="d-flex align-items-center">
30+
<!-- Left label -->
31+
<label class="mr-2" for="useDualStackEndpoints">IPv4</label>
32+
33+
<!-- Switch -->
34+
<div class="custom-control custom-switch" style="margin-top: -6px;">
35+
<input class="custom-control-input" type="checkbox" id="useDualStackEndpoints" value="useDualStackEndpoints">
36+
<label class="custom-control-label" for="useDualStackEndpoints"></label>
37+
</div>
38+
39+
<!-- Right label -->
40+
<label class="ml-0" for="useDualStackEndpoints">Dual-stack</label>
41+
42+
<!-- Tooltip icon -->
43+
<span data-delay="{ &quot;hide&quot;: 1500 }" data-position="auto" tabindex="0" class="text-info ml-1" data-toggle="tooltip" data-html="true"
44+
title="<p>Use dual-stack KVS endpoints, else will use legacy IPv4-only endpoints.</p>
45+
<a href=&quot;https://docs.aws.amazon.com/sdkref/latest/guide/feature-endpoints.html&quot;>Additional information</a>">
46+
<sup>&#9432;</sup>
47+
</span>
48+
</div>
2949
<div class="form-group has-validation" style="position: relative;">
3050
<label for="region">Region</label>
3151
<input type="text" class="form-control valid" id="region" placeholder="Region" value="us-west-2" autocomplete="off" required>
3252
<datalist id="regionList"></datalist>
3353
<div id="region-invalid-feedback" class="invalid-feedback"></div>
3454
</div>
35-
<div class="form-check-inline">
36-
<input class="form-check-input" type="checkbox" id="useDualStackEndpoints" value="useDualStackEndpoints">
37-
<label for="useDualStackEndpoints" class="form-check-label">Use dual-stack endpoints</label>
38-
<span data-delay="{ &quot;hide&quot;: 1500 }" data-position="auto" tabindex="0" class="text-info ml-1" data-toggle="tooltip" data-html="true"
39-
title="<p>Use dual-stack AWS endpoints, else will use legacy IPv4-only endpoints.</p>
40-
<a href=&quot;https://docs.aws.amazon.com/sdkref/latest/guide/feature-endpoints.html&quot;>Additional information</a>
41-
42-
"><sup>&#9432;</sup>
43-
</span>
44-
</div>
4555
<h4 id="subheader">AWS Credentials</h4>
4656
<div class="form-group">
4757
<label for="accessKeyId">Access Key ID</label>

0 commit comments

Comments
 (0)