Skip to content

Commit

Permalink
[fix] Updated Pref. view layout (closes #280)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ferllings committed Mar 10, 2023
1 parent 1f710d8 commit 1d0ed6a
Show file tree
Hide file tree
Showing 4 changed files with 2,031 additions and 2,055 deletions.
4 changes: 2 additions & 2 deletions src/browsers/preferences.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ module.exports = (dirname) => {

let createWindow = (x, y) => {
win = new BrowserWindow({
width: 300,
height: 400,
width: 400,
height: 350,
x: x,
y: y,
resizable: false,
Expand Down
13 changes: 6 additions & 7 deletions src/views/css/preferences.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@ body {
right: 1rem;
}

fieldset {
.option {
display: flex;
align-items: stretch;
flex-direction: column;
justify-content: space-between;
padding-top: 0.5rem;
}

select {
margin-left:auto;
align-self: flex-end;
}
.option select, .width-8 {
min-width: 8rem;
}
53 changes: 33 additions & 20 deletions src/views/preferences.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,26 +12,35 @@
<h1 class="sr-only">Preferences</h1>
<fieldset>
<legend>Options</legend>
<label for="option-rounding">Contrast ratio precision</label>
<select id="option-rounding">
<option value="1">1 decimal place</option>
<option value="2">2 decimal places</option>
</select>
<label for="option-checkForUpdates"><input type="checkbox" id="option-checkForUpdates"/>Enable Auto-Update</label>
<label for="option-lang">Language</label>
<select id="option-lang">
<option value="auto">Auto</option>
<option value="de" lang="de">Deutsch</option>
<option value="nl" lang="nl">Dutch</option>
<option value="en" lang="en">English</option>
<option value="es" lang="es">Español</option>>
<option value="fr" lang="fr">Français</option>
<option value="pl" lang="pl">Polski</option>
<option value="ru" lang="ru">Русский</option>
<option value="ja" lang="ja">日本語</option>
<option value="ko" lang="ko">한국어</option>
</select>
<div id="option-picker-group">
<div class="option">
<label for="option-rounding">Contrast ratio precision</label>
<select id="option-rounding">
<option value="1">1 decimal place</option>
<option value="2">2 decimal places</option>
</select>
</div>
<div class="option">
<label for="option-checkForUpdates">Enable Auto-Update</label>
<div class="width-8">
<input type="checkbox" id="option-checkForUpdates"/>
</div>
</div>
<div class="option">
<label for="option-lang">Language</label>
<select id="option-lang">
<option value="auto">Auto</option>
<option value="de" lang="de">Deutsch</option>
<option value="nl" lang="nl">Dutch</option>
<option value="en" lang="en">English</option>
<option value="es" lang="es">Español</option>>
<option value="fr" lang="fr">Français</option>
<option value="pl" lang="pl">Polski</option>
<option value="ja" lang="ja">日本語</option>
<option value="ko" lang="ko">한국어</option>
<option value="ru" lang="ru">Русский</option>
</select>
</div>
<div class="option" id="option-picker-group">
<label for="option-picker">Color Picker type</label>
<select id="option-picker">
<option value="1">Electron</option>
Expand All @@ -41,6 +50,7 @@ <h1 class="sr-only">Preferences</h1>
</fieldset>
<fieldset>
<legend>Shortcuts</legend>
<div class="option">
<label for="shortcut-foreground-picker">Picker foreground</label>
<select id="shortcut-foreground-picker">
<option value="F1">F1</option>
Expand All @@ -56,6 +66,8 @@ <h1 class="sr-only">Preferences</h1>
<option value="F11">F11</option>
<option value="F12">F12</option>
</select>
</div>
<div class="option">
<label for="shortcut-background-picker">Picker background</label>
<select id="shortcut-background-picker">
<option value="F1">F1</option>
Expand All @@ -71,6 +83,7 @@ <h1 class="sr-only">Preferences</h1>
<option value="F11">F11</option>
<option value="F12">F12</option>
</select>
</div>
</fieldset>
<div class="buttons">
<button id="save">Save</button>
Expand Down
Loading

0 comments on commit 1d0ed6a

Please sign in to comment.