Fix spelling mistake

This commit is contained in:
Nariman Jelveh 2024-03-29 20:59:50 -07:00
parent 9fd32468ad
commit db245f9ba2
7 changed files with 27 additions and 27 deletions

View File

@ -131,11 +131,11 @@ async function UIWindowSettings(options){
h += `<div class="settings-content" data-settings="clock">`; h += `<div class="settings-content" data-settings="clock">`;
h += `<h1>Clock</h1>`; h += `<h1>Clock</h1>`;
h += `<div style="display: flex;align-items: center">` h += `<div style="display: flex;align-items: center">`
h += `<span>${i18n('click_visable')}:</span>` h += `<span>${i18n('click_visible')}:</span>`
h += `<Select class="change-clock-visable" style="margin-left: 10px;flex: 1">` h += `<Select class="change-clock-visible" style="margin-left: 10px;flex: 1">`
h += `<option value="auto">${i18n('click_visable_auto')}</option>` h += `<option value="auto">${i18n('click_visible_auto')}</option>`
h += `<option value="hide">${i18n('click_visable_hide')}</option>` h += `<option value="hide">${i18n('click_visible_hide')}</option>`
h += `<option value="show">${i18n('click_visable_show')}</option>` h += `<option value="show">${i18n('click_visible_show')}</option>`
h += `</Select>` h += `</Select>`
h += `</div>` h += `</div>`
h += `</div>`; h += `</div>`;
@ -357,14 +357,14 @@ async function UIWindowSettings(options){
}) })
}); });
$(el_window).on('change', 'select.change-clock-visable', function(e){ $(el_window).on('change', 'select.change-clock-visible', function(e){
const $this = $(this); const $this = $(this);
const value = $this.val(); const value = $this.val();
window.change_clock_visable(value); window.change_clock_visible(value);
}) })
window.change_clock_visable(); window.change_clock_visible();
resolve(el_window); resolve(el_window);
}); });

View File

@ -505,7 +505,7 @@ async function UIDesktop(options){
const user_preferences = { const user_preferences = {
show_hidden_files: JSON.parse(await puter.kv.get('user_preferences.show_hidden_files')), show_hidden_files: JSON.parse(await puter.kv.get('user_preferences.show_hidden_files')),
language: await puter.kv.get('user_preferences.language'), language: await puter.kv.get('user_preferences.language'),
clock_visable: await puter.kv.get('user_preferences.clock_visable'), clock_visible: await puter.kv.get('user_preferences.clock_visible'),
}; };
// update default apps // update default apps
@ -1383,11 +1383,11 @@ document.addEventListener('fullscreenchange', (event) => {
if (document.fullscreenElement) { if (document.fullscreenElement) {
$('.fullscreen-btn').css('background-image', `url(${window.icons['shrink.svg']})`); $('.fullscreen-btn').css('background-image', `url(${window.icons['shrink.svg']})`);
$('.fullscreen-btn').attr('title', 'Exit Full Screen'); $('.fullscreen-btn').attr('title', 'Exit Full Screen');
window.user_preferences.clock_visable === 'auto' && $('#clock').show(); window.user_preferences.clock_visible === 'auto' && $('#clock').show();
} else { } else {
$('.fullscreen-btn').css('background-image', `url(${window.icons['fullscreen.svg']})`); $('.fullscreen-btn').css('background-image', `url(${window.icons['fullscreen.svg']})`);
$('.fullscreen-btn').attr('title', 'Enter Full Screen'); $('.fullscreen-btn').attr('title', 'Enter Full Screen');
window.user_preferences.clock_visable === 'auto' && $('#clock').hide(); window.user_preferences.clock_visible === 'auto' && $('#clock').hide();
} }
}) })

View File

@ -46,7 +46,7 @@ async function UITaskbar(options){
$('.desktop').append(h); $('.desktop').append(h);
// init clock visibility // init clock visibility
window.change_clock_visable(); window.change_clock_visible();
//--------------------------------------------- //---------------------------------------------
// add `Start` to taskbar // add `Start` to taskbar

View File

@ -97,7 +97,7 @@ if (window.user_preferences === null) {
window.user_preferences = { window.user_preferences = {
show_hidden_files: false, show_hidden_files: false,
language: navigator.language.split("-")[0] || navigator.userLanguage || 'en', language: navigator.language.split("-")[0] || navigator.userLanguage || 'en',
clock_visable: 'auto', clock_visible: 'auto',
} }
} }

View File

@ -3680,21 +3680,21 @@ window.delete_desktop_item_positions = ()=>{
puter.kv.del('desktop_item_positions'); puter.kv.del('desktop_item_positions');
} }
window.change_clock_visable = (clock_visable) => { window.change_clock_visible = (clock_visible) => {
let newValue = clock_visable || window.user_preferences.clock_visable; let newValue = clock_visible || window.user_preferences.clock_visible;
newValue === 'show' && $('#clock').show(); newValue === 'show' && $('#clock').show();
newValue === 'hide' && $('#clock').hide(); newValue === 'hide' && $('#clock').hide();
if(clock_visable) { if(clock_visible) {
// save clock_visable to user preferences // save clock_visible to user preferences
window.mutate_user_preferences({ window.mutate_user_preferences({
clock_visable: newValue clock_visible: newValue
}); });
return; return;
} }
$('select.change-clock-visable').val(window.user_preferences.clock_visable); $('select.change-clock-visible').val(window.user_preferences.clock_visible);
} }

View File

@ -61,10 +61,10 @@ const en = {
current_password: "Current Password", current_password: "Current Password",
cut: 'Cut', cut: 'Cut',
clock: "Clock", clock: "Clock",
click_visable: 'Visible', click_visible: 'Visible',
click_visable_hide: 'Hide - Always hidden', click_visible_hide: 'Hide - Always hidden',
click_visable_show: 'Show - Always visible', click_visible_show: 'Show - Always visible',
click_visable_auto: 'Auto - Default, visible only in full-screen mode.', click_visible_auto: 'Auto - Default, visible only in full-screen mode.',
date_modified: 'Date modified', date_modified: 'Date modified',
delete: 'Delete', delete: 'Delete',
delete_account: "Delete Account", delete_account: "Delete Account",

View File

@ -51,10 +51,10 @@ const zh = {
current_password: "当前密码", current_password: "当前密码",
cut: '剪切', cut: '剪切',
clock: "时间", clock: "时间",
click_visable: '显示方式', click_visible: '显示方式',
click_visable_hide: '隐藏 - 始终隐藏', click_visible_hide: '隐藏 - 始终隐藏',
click_visable_show: '显示 - 始终显示', click_visible_show: '显示 - 始终显示',
click_visable_auto: '自动 - 默认值,全屏显示', click_visible_auto: '自动 - 默认值,全屏显示',
date_modified: '修改日期', date_modified: '修改日期',
delete: '删除', delete: '删除',
delete_permanently: "永久删除", delete_permanently: "永久删除",