Skip to content

Commit 81da14c

Browse files
committed
Update demo page: add dataTypeCase and functionCase
1 parent 371c091 commit 81da14c

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

static/index.html

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,22 @@ <h3 style="margin: 0.5rem 0">Options</h3>
8383
<option value="lower">Lower</option>
8484
</select>
8585
</article>
86+
<article class="config">
87+
<label for="dataTypeCase">Data type case:</label>
88+
<select id="dataTypeCase">
89+
<option value="preserve">Preserve</option>
90+
<option value="upper">Upper</option>
91+
<option value="lower">Lower</option>
92+
</select>
93+
</article>
94+
<article class="config">
95+
<label for="functionCase">Function case:</label>
96+
<select id="functionCase">
97+
<option value="preserve">Preserve</option>
98+
<option value="upper">Upper</option>
99+
<option value="lower">Lower</option>
100+
</select>
101+
</article>
86102
<article class="config">
87103
<label for="identifierCase">Identifier case:</label>
88104
<select id="identifierCase">

static/index.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ const attachFormat = () => {
77
const tabWidth = document.getElementById('tabWidth');
88
const useTabs = document.getElementById('useTabs');
99
const keywordCase = document.getElementById('keywordCase');
10+
const dataTypeCase = document.getElementById('dataTypeCase');
11+
const functionCase = document.getElementById('functionCase');
1012
const identifierCase = document.getElementById('identifierCase');
1113
const indentStyle = document.getElementById('indentStyle');
1214
const logicalOperatorNewline = document.getElementById('logicalOperatorNewline');
@@ -34,6 +36,8 @@ const attachFormat = () => {
3436
tabWidth: tabWidth.value,
3537
useTabs: useTabs.checked,
3638
keywordCase: keywordCase.options[keywordCase.selectedIndex].value,
39+
dataTypeCase: dataTypeCase.options[dataTypeCase.selectedIndex].value,
40+
functionCase: functionCase.options[functionCase.selectedIndex].value,
3741
identifierCase: identifierCase.options[identifierCase.selectedIndex].value,
3842
indentStyle: indentStyle.options[indentStyle.selectedIndex].value,
3943
logicalOperatorNewline:
@@ -70,6 +74,8 @@ const attachFormat = () => {
7074
tabWidth,
7175
useTabs,
7276
keywordCase,
77+
dataTypeCase,
78+
functionCase,
7379
identifierCase,
7480
indentStyle,
7581
logicalOperatorNewline,

0 commit comments

Comments
 (0)