5 changed files with 91 additions and 92 deletions
@ -1,3 +1,22 @@ |
|||
--- |
|||
title: Code builder |
|||
layout: single |
|||
--- |
|||
|
|||
<!-- Code result of the generated form below --> |
|||
|
|||
<p> |
|||
<a href="https://www.systutorials.com/docs/linux/man/8-hciconfig/">hciconfig</a> |
|||
device identification command: |
|||
<kbd> |
|||
hciconfig 0 class <span id="bluetoothClass"></span> |
|||
</kbd> |
|||
</p> |
|||
|
|||
<!-- Input selections per BlueTooth class group --> |
|||
|
|||
{{< major-services >}} |
|||
|
|||
{{< major-devices >}} |
|||
|
|||
{{< minor-devices >}} |
|||
|
@ -1,92 +0,0 @@ |
|||
{{ define "main" }} |
|||
|
|||
<!-- Code result of the generated form below --> |
|||
|
|||
<p> |
|||
<a href="https://www.systutorials.com/docs/linux/man/8-hciconfig/">hciconfig</a> |
|||
device identification command: |
|||
<kbd> |
|||
hciconfig 0 class <span id="bluetoothClass"></span> |
|||
</kbd> |
|||
</p> |
|||
|
|||
<!-- Input selections per BlueTooth class group --> |
|||
|
|||
<h2>Major service</h2> |
|||
|
|||
<div class="uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
{{ range .Site.Data.codes.majorServices }} |
|||
{{ range $key, $value := . }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-checkbox" |
|||
id="majorService-{{ $key }}" |
|||
type="checkbox" |
|||
value={{ $key }} |
|||
> |
|||
{{ $value }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
{{ end }} |
|||
</div> |
|||
|
|||
<h3>Major device</h3> |
|||
|
|||
<div class="uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
{{ range .Site.Data.codes.majorDevices }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-radio" |
|||
id="majorDevice-{{ .code }}" |
|||
name="majorDevice" |
|||
type="radio" |
|||
value={{ .code }} |
|||
> |
|||
{{ .title }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
</div> |
|||
|
|||
<h4>Minor device</h4> |
|||
|
|||
<div class="minor-devices"> |
|||
{{ range .Site.Data.codes.majorDevices }} |
|||
|
|||
{{ $majorDevice := print "majorDevice-" .code }} |
|||
|
|||
<div class="{{ $majorDevice }} uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
|
|||
{{ range .minorDevices }} |
|||
{{ range $key, $value := . }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-radio" |
|||
id="minorDevice-{{ $majorDevice }}-{{ $key }}" |
|||
name="minorDevice-{{ $majorDevice }}" |
|||
type="radio" |
|||
value={{ $key }} |
|||
> |
|||
{{ $value }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
{{ else }} |
|||
<div class="uk-width-expand"> |
|||
<span> |
|||
No options for this combination |
|||
</span> |
|||
</div> |
|||
{{ end }} |
|||
|
|||
</div> |
|||
{{ end }} |
|||
</div> |
|||
|
|||
{{ .Content }} |
|||
|
|||
{{ end }} |
@ -0,0 +1,18 @@ |
|||
<h3>Major device</h3> |
|||
|
|||
<div class="uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
{{ range .Site.Data.codes.majorDevices }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-radio" |
|||
id="majorDevice-{{ .code }}" |
|||
name="majorDevice" |
|||
type="radio" |
|||
value={{ .code }} |
|||
> |
|||
{{ .title }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
</div> |
@ -0,0 +1,19 @@ |
|||
<h2>Major service</h2> |
|||
|
|||
<div class="uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
{{ range .Site.Data.codes.majorServices }} |
|||
{{ range $key, $value := . }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-checkbox" |
|||
id="majorService-{{ $key }}" |
|||
type="checkbox" |
|||
value={{ $key }} |
|||
> |
|||
{{ $value }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
{{ end }} |
|||
</div> |
@ -0,0 +1,35 @@ |
|||
<h4>Minor device</h4> |
|||
|
|||
<div class="minor-devices"> |
|||
{{ range .Site.Data.codes.majorDevices }} |
|||
|
|||
{{ $majorDevice := print "majorDevice-" .code }} |
|||
|
|||
<div class="{{ $majorDevice }} uk-grid uk-child-width-1-1 uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l"> |
|||
|
|||
{{ range .minorDevices }} |
|||
{{ range $key, $value := . }} |
|||
<div> |
|||
<label> |
|||
<input |
|||
class="uk-radio" |
|||
id="minorDevice-{{ $majorDevice }}-{{ $key }}" |
|||
name="minorDevice-{{ $majorDevice }}" |
|||
type="radio" |
|||
value={{ $key }} |
|||
> |
|||
{{ $value }} |
|||
</label> |
|||
</div> |
|||
{{ end }} |
|||
{{ else }} |
|||
<div class="uk-width-expand"> |
|||
<span> |
|||
No options for this combination |
|||
</span> |
|||
</div> |
|||
{{ end }} |
|||
|
|||
</div> |
|||
{{ end }} |
|||
</div> |
Loading…
Reference in new issue