mirror of
https://github.com/HeyPuter/puter
synced 2024-11-14 22:06:00 +00:00
Fix spelling mistake
This commit is contained in:
parent
9fd32468ad
commit
db245f9ba2
@ -131,11 +131,11 @@ async function UIWindowSettings(options){
|
||||
h += `<div class="settings-content" data-settings="clock">`;
|
||||
h += `<h1>Clock</h1>`;
|
||||
h += `<div style="display: flex;align-items: center">`
|
||||
h += `<span>${i18n('click_visable')}:</span>`
|
||||
h += `<Select class="change-clock-visable" style="margin-left: 10px;flex: 1">`
|
||||
h += `<option value="auto">${i18n('click_visable_auto')}</option>`
|
||||
h += `<option value="hide">${i18n('click_visable_hide')}</option>`
|
||||
h += `<option value="show">${i18n('click_visable_show')}</option>`
|
||||
h += `<span>${i18n('click_visible')}:</span>`
|
||||
h += `<Select class="change-clock-visible" style="margin-left: 10px;flex: 1">`
|
||||
h += `<option value="auto">${i18n('click_visible_auto')}</option>`
|
||||
h += `<option value="hide">${i18n('click_visible_hide')}</option>`
|
||||
h += `<option value="show">${i18n('click_visible_show')}</option>`
|
||||
h += `</Select>`
|
||||
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 value = $this.val();
|
||||
|
||||
window.change_clock_visable(value);
|
||||
window.change_clock_visible(value);
|
||||
})
|
||||
|
||||
window.change_clock_visable();
|
||||
window.change_clock_visible();
|
||||
|
||||
resolve(el_window);
|
||||
});
|
||||
|
@ -505,7 +505,7 @@ async function UIDesktop(options){
|
||||
const user_preferences = {
|
||||
show_hidden_files: JSON.parse(await puter.kv.get('user_preferences.show_hidden_files')),
|
||||
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
|
||||
@ -1383,11 +1383,11 @@ document.addEventListener('fullscreenchange', (event) => {
|
||||
if (document.fullscreenElement) {
|
||||
$('.fullscreen-btn').css('background-image', `url(${window.icons['shrink.svg']})`);
|
||||
$('.fullscreen-btn').attr('title', 'Exit Full Screen');
|
||||
window.user_preferences.clock_visable === 'auto' && $('#clock').show();
|
||||
window.user_preferences.clock_visible === 'auto' && $('#clock').show();
|
||||
} else {
|
||||
$('.fullscreen-btn').css('background-image', `url(${window.icons['fullscreen.svg']})`);
|
||||
$('.fullscreen-btn').attr('title', 'Enter Full Screen');
|
||||
window.user_preferences.clock_visable === 'auto' && $('#clock').hide();
|
||||
window.user_preferences.clock_visible === 'auto' && $('#clock').hide();
|
||||
}
|
||||
})
|
||||
|
||||
|
@ -46,7 +46,7 @@ async function UITaskbar(options){
|
||||
$('.desktop').append(h);
|
||||
|
||||
// init clock visibility
|
||||
window.change_clock_visable();
|
||||
window.change_clock_visible();
|
||||
|
||||
//---------------------------------------------
|
||||
// add `Start` to taskbar
|
||||
|
@ -97,7 +97,7 @@ if (window.user_preferences === null) {
|
||||
window.user_preferences = {
|
||||
show_hidden_files: false,
|
||||
language: navigator.language.split("-")[0] || navigator.userLanguage || 'en',
|
||||
clock_visable: 'auto',
|
||||
clock_visible: 'auto',
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3680,21 +3680,21 @@ window.delete_desktop_item_positions = ()=>{
|
||||
puter.kv.del('desktop_item_positions');
|
||||
}
|
||||
|
||||
window.change_clock_visable = (clock_visable) => {
|
||||
let newValue = clock_visable || window.user_preferences.clock_visable;
|
||||
window.change_clock_visible = (clock_visible) => {
|
||||
let newValue = clock_visible || window.user_preferences.clock_visible;
|
||||
|
||||
newValue === 'show' && $('#clock').show();
|
||||
newValue === 'hide' && $('#clock').hide();
|
||||
|
||||
|
||||
if(clock_visable) {
|
||||
// save clock_visable to user preferences
|
||||
if(clock_visible) {
|
||||
// save clock_visible to user preferences
|
||||
window.mutate_user_preferences({
|
||||
clock_visable: newValue
|
||||
clock_visible: newValue
|
||||
});
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
$('select.change-clock-visable').val(window.user_preferences.clock_visable);
|
||||
$('select.change-clock-visible').val(window.user_preferences.clock_visible);
|
||||
}
|
@ -61,10 +61,10 @@ const en = {
|
||||
current_password: "Current Password",
|
||||
cut: 'Cut',
|
||||
clock: "Clock",
|
||||
click_visable: 'Visible',
|
||||
click_visable_hide: 'Hide - Always hidden',
|
||||
click_visable_show: 'Show - Always visible',
|
||||
click_visable_auto: 'Auto - Default, visible only in full-screen mode.',
|
||||
click_visible: 'Visible',
|
||||
click_visible_hide: 'Hide - Always hidden',
|
||||
click_visible_show: 'Show - Always visible',
|
||||
click_visible_auto: 'Auto - Default, visible only in full-screen mode.',
|
||||
date_modified: 'Date modified',
|
||||
delete: 'Delete',
|
||||
delete_account: "Delete Account",
|
||||
|
@ -51,10 +51,10 @@ const zh = {
|
||||
current_password: "当前密码",
|
||||
cut: '剪切',
|
||||
clock: "时间",
|
||||
click_visable: '显示方式',
|
||||
click_visable_hide: '隐藏 - 始终隐藏',
|
||||
click_visable_show: '显示 - 始终显示',
|
||||
click_visable_auto: '自动 - 默认值,全屏显示',
|
||||
click_visible: '显示方式',
|
||||
click_visible_hide: '隐藏 - 始终隐藏',
|
||||
click_visible_show: '显示 - 始终显示',
|
||||
click_visible_auto: '自动 - 默认值,全屏显示',
|
||||
date_modified: '修改日期',
|
||||
delete: '删除',
|
||||
delete_permanently: "永久删除",
|
||||
|
Loading…
Reference in New Issue
Block a user