Release Vulpes OS 2.7 Preview 25 for Desktop, Android and Pixel 3a

This commit is contained in:
OverSu 2026-11-28 12:20:19 +01:00
commit 3a1fba4efe

View file

@ -43,6 +43,16 @@
'This feature is not available on this platform yet.');
window.VulpesGaiaUI = {notice};
async function ready() {
if (window.VulpesPlatform === 'tundra') {
window.addEventListener('click', event => {
if (!event.isTrusted || event.defaultPrevented || event.button !== 0) return;
const link = event.target.closest?.('a[href]');
if (!link || link.hasAttribute('download') || !/^https?:$/.test(link.protocol)) return;
if (link.hostname === 'localhost' || link.hostname.endsWith('.localhost')) return;
event.preventDefault();
new MozActivity({name:'view', data:{type:'url', url:link.href}});
});
}
if (app === 'system') {
// Android reserves the edge swipe for its own shade. A tap on Gaia's
// status bar provides access without competing with that system gesture.
@ -97,6 +107,35 @@
document.addEventListener('click', event => {
if (!event.target.closest('#import-sd-option')) return;
event.preventDefault(); event.stopImmediatePropagation();
if (window.VulpesPlatform === 'tundra') {
VulpesCompat.call('platform.contact',{action:'list'}).then(names=>{
if (!names.length) {
notice(label('Placez un fichier vCard (.vcf) dans Téléchargements, puis réessayez.',
'Place a vCard (.vcf) file in Downloads, then try again.'));
return;
}
notice(label('Choisissez un fichier de contacts dans Téléchargements.',
'Choose a contact file from Downloads.'));
const form=document.getElementById('vulpes-gaia-notice');
const select=document.createElement('select');
select.setAttribute('aria-label',label('Fichier de contacts','Contact file'));
for(const name of names)select.add(new Option(name,name));
form.querySelector('section').append(select);
const submit=document.createElement('button');
submit.type='button';submit.className='recommend';submit.textContent=label('Importer','Import');
form.querySelector('menu').append(submit);
submit.onclick=async()=>{
submit.disabled=true;
try {
await VulpesCompat.call('platform.contact',{action:'import',name:select.value});
notice(label('Import terminé.','Import complete.'));
} catch (error) {
notice(label('Impossible de lire cette vCard.', 'Could not read this vCard.'));
}
};
}).catch(()=>notice(unavailable()));
return;
}
VulpesCompat.call('platform.contact', {}).catch(error => {
if (error.name !== 'AbortError' && error.message !== 'AbortError') notice(unavailable());
});