fix(native): show individual Cloud plan features

This commit is contained in:
Maurice
2026-11-30 22:48:50 +01:00
parent 6c45d16cba
commit fa23f94ee8
29 changed files with 161 additions and 29 deletions
+21 -1
View File
@@ -152,6 +152,7 @@ const I = {
image:
'M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2zM8.5 10a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM21 15l-5-5L5 21',
spark: 'M12 3l1.8 5.2L19 10l-5.2 1.8L12 17l-1.8-5.2L5 10l5.2-1.8z',
mail: 'M4 5h16a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2zM3 7l9 6 9-6',
people:
'M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2M9 11a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM22 21v-2a4 4 0 0 0-3-3.87M16 3.13a4 4 0 0 1 0 7.75',
shield: 'M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10',
@@ -664,6 +665,8 @@ interface CloudPlan {
currency?: 'EUR' | 'USD';
aiDocuments: number;
aiDocumentLimit?: 0 | null;
aiAssistant?: 'planned' | 'included' | 'unavailable';
bookingMailImport?: boolean;
storageGb: number;
}
@@ -693,6 +696,8 @@ const SAMPLE_PLANS: CloudPlan[] = [
currency: 'USD',
aiDocuments: 100,
aiDocumentLimit: null,
aiAssistant: 'planned',
bookingMailImport: true,
storageGb: 200,
},
];
@@ -959,6 +964,9 @@ function showPlans(opts: { back?: boolean } = {}): void {
: '';
const gb = plan.storageGb >= 1000 ? `${count(plan.storageGb / 1000)} TB` : `${count(plan.storageGb)} GB`;
const notIncluded = t('native.plans.aiNone');
const included = t('native.plans.included');
const assistant = plan.aiAssistant === 'included';
const tile = (glyph: string, big: string, small: string, off = false) =>
el(
'span',
@@ -976,7 +984,19 @@ function showPlans(opts: { back?: boolean } = {}): void {
: t('native.plans.aiPerMonth', { n: count(plan.aiDocuments) }),
t('native.plans.aiLabel')
)
: tile(I.spark, t('native.plans.aiNone'), t('native.plans.aiLabel'), true),
: tile(I.spark, notIncluded, t('native.plans.aiLabel'), true),
tile(
I.spark,
assistant ? included : plan.aiAssistant === 'planned' ? t('native.plans.planned') : notIncluded,
t('native.plans.assistant'),
!assistant
),
tile(
I.mail,
plan.bookingMailImport ? included : notIncluded,
t('native.plans.mailImport'),
!plan.bookingMailImport
),
el(
'span',
{ className: 'spec wide' },
+5 -1
View File
@@ -203,7 +203,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'أي {price} شهريًا',
'native.plans.storageFairUse': 'تخزين وفق الاستخدام العادل',
'native.plans.aiPerMonth': '{n} / شهر',
'native.plans.aiNone': 'لا شيء',
'native.plans.aiNone': 'غير مشمول',
'native.plans.included': 'مشمول',
'native.plans.planned': 'مخطط له',
'native.plans.assistant': 'مساعد الذكاء الاصطناعي',
'native.plans.mailImport': 'استيراد البريد تلقائيًا',
'native.plans.aiLabel': 'مستندات الذكاء الاصطناعي',
'native.plans.choose': 'اختر {trip}',
'native.plans.termsShort': 'شروط الاستخدام (EULA)',
+5 -1
View File
@@ -208,7 +208,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Bu, ayda {price} edir',
'native.plans.storageFairUse': 'Ədalətli istifadə yaddaşı',
'native.plans.aiPerMonth': '{n} / ay',
'native.plans.aiNone': 'Yoxdur',
'native.plans.aiNone': 'Daxil deyil',
'native.plans.included': 'Daxildir',
'native.plans.planned': 'Planlaşdırılır',
'native.plans.assistant': 'Sİ köməkçisi',
'native.plans.mailImport': 'Avtomatik e-poçt idxalı',
'native.plans.aiLabel': 'Sİ sənədləri',
'native.plans.choose': '{trip} seçin',
'native.plans.termsShort': 'İstifadə şərtləri (EULA)',
+5 -1
View File
@@ -210,7 +210,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'São {price} por mês',
'native.plans.storageFairUse': 'Armazenamento de uso justo',
'native.plans.aiPerMonth': '{n} / mês',
'native.plans.aiNone': 'Nenhum',
'native.plans.aiNone': 'Não incluído',
'native.plans.included': 'Incluído',
'native.plans.planned': 'Planejado',
'native.plans.assistant': 'Assistente de IA',
'native.plans.mailImport': 'Importação automática de e-mails',
'native.plans.aiLabel': 'Documentos de IA',
'native.plans.choose': 'Escolher {trip}',
'native.plans.termsShort': 'Termos de uso (EULA)',
+5 -1
View File
@@ -211,7 +211,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Són {price} al mes',
'native.plans.storageFairUse': 'Emmagatzematge d’ús raonable',
'native.plans.aiPerMonth': '{n} / mes',
'native.plans.aiNone': 'Cap',
'native.plans.aiNone': 'No inclòs',
'native.plans.included': 'Inclòs',
'native.plans.planned': 'Previst',
'native.plans.assistant': 'Assistent d’IA',
'native.plans.mailImport': 'Importació automàtica de correus',
'native.plans.aiLabel': 'Documents IA',
'native.plans.choose': 'Tria {trip}',
'native.plans.termsShort': 'Condicions d’ús (EULA)',
+5 -1
View File
@@ -204,7 +204,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'To je {price} měsíčně',
'native.plans.storageFairUse': 'Úložiště v režimu férového využití',
'native.plans.aiPerMonth': '{n} / měsíc',
'native.plans.aiNone': 'Žádné',
'native.plans.aiNone': 'Není součástí',
'native.plans.included': 'Součástí',
'native.plans.planned': 'Plánováno',
'native.plans.assistant': 'Asistent AI',
'native.plans.mailImport': 'Automatický import e-mailů',
'native.plans.aiLabel': 'Dokumenty AI',
'native.plans.choose': 'Vybrat: {trip}',
'native.plans.termsShort': 'Podmínky použití (EULA)',
+5 -1
View File
@@ -214,7 +214,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Das sind {price} im Monat',
'native.plans.storageFairUse': 'Speicher unter Fair Use',
'native.plans.aiPerMonth': '{n} / Monat',
'native.plans.aiNone': 'Keine',
'native.plans.aiNone': 'Nicht enthalten',
'native.plans.included': 'Enthalten',
'native.plans.planned': 'Geplant',
'native.plans.assistant': 'KI-Assistent',
'native.plans.mailImport': 'Automatischer E-Mail-Import',
'native.plans.aiLabel': 'KI-Dokumente',
'native.plans.choose': '{trip} wählen',
'native.plans.termsShort': 'Nutzungsbedingungen (EULA)',
+5 -1
View File
@@ -209,7 +209,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'That is {price} a month',
'native.plans.storageFairUse': 'Storage fair use',
'native.plans.aiPerMonth': '{n} / month',
'native.plans.aiNone': 'None',
'native.plans.aiNone': 'Not included',
'native.plans.included': 'Included',
'native.plans.planned': 'Planned',
'native.plans.assistant': 'AI Assistant',
'native.plans.mailImport': 'Automated Mail Import',
'native.plans.aiLabel': 'AI documents',
'native.plans.choose': 'Choose {trip}',
'native.plans.termsShort': 'Terms of Use (EULA)',
+5 -1
View File
@@ -209,7 +209,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Son {price} al mes',
'native.plans.storageFairUse': 'Almacenamiento de uso razonable',
'native.plans.aiPerMonth': '{n} / mes',
'native.plans.aiNone': 'Ninguno',
'native.plans.aiNone': 'No incluido',
'native.plans.included': 'Incluido',
'native.plans.planned': 'Previsto',
'native.plans.assistant': 'Asistente de IA',
'native.plans.mailImport': 'Importación automática de correo',
'native.plans.aiLabel': 'Documentos IA',
'native.plans.choose': 'Elegir {trip}',
'native.plans.termsShort': 'Condiciones de uso (EULA)',
+5 -1
View File
@@ -206,7 +206,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'See on {price} kuus',
'native.plans.storageFairUse': 'Õiglase kasutuse salvestusruum',
'native.plans.aiPerMonth': '{n} / kuus',
'native.plans.aiNone': 'Puudub',
'native.plans.aiNone': 'Ei sisaldu',
'native.plans.included': 'Sisaldub',
'native.plans.planned': 'Plaanis',
'native.plans.assistant': 'AI-assistent',
'native.plans.mailImport': 'Automaatne e-kirjade import',
'native.plans.aiLabel': 'TI-dokumendid',
'native.plans.choose': 'Vali {trip}',
'native.plans.termsShort': 'Kasutustingimused (EULA)',
+5 -1
View File
@@ -213,7 +213,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Soit {price} par mois',
'native.plans.storageFairUse': 'Stockage en usage raisonnable',
'native.plans.aiPerMonth': '{n} / mois',
'native.plans.aiNone': 'Aucun',
'native.plans.aiNone': 'Non inclus',
'native.plans.included': 'Inclus',
'native.plans.planned': 'Prévu',
'native.plans.assistant': 'Assistant IA',
'native.plans.mailImport': 'Import automatique des e-mails',
'native.plans.aiLabel': 'Documents IA',
'native.plans.choose': 'Choisir {trip}',
'native.plans.termsShort': 'Conditions d’utilisation (EULA)',
+5 -1
View File
@@ -216,7 +216,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Δηλαδή {price} τον μήνα',
'native.plans.storageFairUse': 'Αποθήκευση με εύλογη χρήση',
'native.plans.aiPerMonth': '{n} / μήνα',
'native.plans.aiNone': 'Κανένα',
'native.plans.aiNone': 'Δεν περιλαμβάνεται',
'native.plans.included': 'Περιλαμβάνεται',
'native.plans.planned': 'Προγραμματίζεται',
'native.plans.assistant': 'Βοηθός AI',
'native.plans.mailImport': 'Αυτόματη εισαγωγή email',
'native.plans.aiLabel': 'Έγγραφα AI',
'native.plans.choose': 'Επιλογή: {trip}',
'native.plans.termsShort': 'Όροι χρήσης (EULA)',
+5 -1
View File
@@ -202,7 +202,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'כלומר {price} לחודש',
'native.plans.storageFairUse': 'אחסון בשימוש הוגן',
'native.plans.aiPerMonth': '{n} / חודש',
'native.plans.aiNone': 'אין',
'native.plans.aiNone': 'לא כלול',
'native.plans.included': 'כלול',
'native.plans.planned': 'מתוכנן',
'native.plans.assistant': 'עוזר AI',
'native.plans.mailImport': 'ייבוא דוא״ל אוטומטי',
'native.plans.aiLabel': 'מסמכי AI',
'native.plans.choose': 'בחירת {trip}',
'native.plans.termsShort': 'תנאי שימוש (EULA)',
+5 -1
View File
@@ -212,7 +212,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Ez havonta {price}',
'native.plans.storageFairUse': 'Tárhely méltányos használatra',
'native.plans.aiPerMonth': '{n} / hó',
'native.plans.aiNone': 'Nincs',
'native.plans.aiNone': 'Nem tartalmazza',
'native.plans.included': 'Tartalmazza',
'native.plans.planned': 'Tervezett',
'native.plans.assistant': 'MI-asszisztens',
'native.plans.mailImport': 'Automatikus e-mail-importálás',
'native.plans.aiLabel': 'MI-dokumentumok',
'native.plans.choose': '{trip} választása',
'native.plans.termsShort': 'Felhasználási feltételek (EULA)',
+5 -1
View File
@@ -211,7 +211,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Itu {price} per bulan',
'native.plans.storageFairUse': 'Penyimpanan penggunaan wajar',
'native.plans.aiPerMonth': '{n} / bulan',
'native.plans.aiNone': 'Tidak ada',
'native.plans.aiNone': 'Tidak disertakan',
'native.plans.included': 'Disertakan',
'native.plans.planned': 'Direncanakan',
'native.plans.assistant': 'Asisten AI',
'native.plans.mailImport': 'Impor email otomatis',
'native.plans.aiLabel': 'Dokumen AI',
'native.plans.choose': 'Pilih {trip}',
'native.plans.termsShort': 'Ketentuan Penggunaan (EULA)',
+5 -1
View File
@@ -213,7 +213,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Sono {price} al mese',
'native.plans.storageFairUse': 'Spazio con uso ragionevole',
'native.plans.aiPerMonth': '{n} / mese',
'native.plans.aiNone': 'Nessuno',
'native.plans.aiNone': 'Non incluso',
'native.plans.included': 'Incluso',
'native.plans.planned': 'Previsto',
'native.plans.assistant': 'Assistente IA',
'native.plans.mailImport': 'Importazione automatica delle e-mail',
'native.plans.aiLabel': 'Documenti IA',
'native.plans.choose': 'Scegli {trip}',
'native.plans.termsShort': 'Condizioni d’uso (EULA)',
+5 -1
View File
@@ -208,7 +208,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': '月あたり {price}',
'native.plans.storageFairUse': 'ストレージの公平利用枠',
'native.plans.aiPerMonth': '{n} / 月',
'native.plans.aiNone': 'なし',
'native.plans.aiNone': '対象外',
'native.plans.included': '利用可能',
'native.plans.planned': '提供予定',
'native.plans.assistant': 'AI アシスタント',
'native.plans.mailImport': 'メールの自動取り込み',
'native.plans.aiLabel': 'AI ドキュメント',
'native.plans.choose': '{trip}を選ぶ',
'native.plans.termsShort': '利用規約 (EULA)',
+5 -1
View File
@@ -205,7 +205,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': '월 {price}에 해당',
'native.plans.storageFairUse': '공정 사용 저장 공간',
'native.plans.aiPerMonth': '{n} / 월',
'native.plans.aiNone': '없음',
'native.plans.aiNone': '미포함',
'native.plans.included': '포함',
'native.plans.planned': '예정',
'native.plans.assistant': 'AI 어시스턴트',
'native.plans.mailImport': '자동 이메일 가져오기',
'native.plans.aiLabel': 'AI 문서',
'native.plans.choose': '{trip} 선택',
'native.plans.termsShort': '이용 약관 (EULA)',
+5 -1
View File
@@ -211,7 +211,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Dat is {price} per maand',
'native.plans.storageFairUse': 'Opslag bij redelijk gebruik',
'native.plans.aiPerMonth': '{n} / maand',
'native.plans.aiNone': 'Geen',
'native.plans.aiNone': 'Niet inbegrepen',
'native.plans.included': 'Inbegrepen',
'native.plans.planned': 'Gepland',
'native.plans.assistant': 'AI-assistent',
'native.plans.mailImport': 'Automatische e-mailimport',
'native.plans.aiLabel': 'AI-documenten',
'native.plans.choose': '{trip} kiezen',
'native.plans.termsShort': 'Gebruiksvoorwaarden (EULA)',
+5 -1
View File
@@ -208,7 +208,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'To {price} miesięcznie',
'native.plans.storageFairUse': 'Miejsce w ramach uczciwego użytkowania',
'native.plans.aiPerMonth': '{n} / miesiąc',
'native.plans.aiNone': 'Brak',
'native.plans.aiNone': 'Niedostępne',
'native.plans.included': 'W pakiecie',
'native.plans.planned': 'Planowane',
'native.plans.assistant': 'Asystent AI',
'native.plans.mailImport': 'Automatyczny import poczty',
'native.plans.aiLabel': 'Dokumenty AI',
'native.plans.choose': 'Wybierz: {trip}',
'native.plans.termsShort': 'Warunki korzystania (EULA)',
+5 -1
View File
@@ -211,7 +211,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Это {price} в месяц',
'native.plans.storageFairUse': 'Хранилище по правилам добросовестного использования',
'native.plans.aiPerMonth': '{n} / мес.',
'native.plans.aiNone': 'Нет',
'native.plans.aiNone': 'Не включено',
'native.plans.included': 'Включено',
'native.plans.planned': 'Планируется',
'native.plans.assistant': 'ИИ-помощник',
'native.plans.mailImport': 'Автоматический импорт писем',
'native.plans.aiLabel': 'Документы ИИ',
'native.plans.choose': 'Выбрать: {trip}',
'native.plans.termsShort': 'Условия использования (EULA)',
+5 -1
View File
@@ -206,7 +206,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'To je {price} mesačne',
'native.plans.storageFairUse': 'Úložisko v režime primeraného využitia',
'native.plans.aiPerMonth': '{n} / mesiac',
'native.plans.aiNone': 'Žiadne',
'native.plans.aiNone': 'Nie je zahrnuté',
'native.plans.included': 'Zahrnuté',
'native.plans.planned': 'Plánované',
'native.plans.assistant': 'Asistent AI',
'native.plans.mailImport': 'Automatický import e-mailov',
'native.plans.aiLabel': 'Dokumenty AI',
'native.plans.choose': 'Vybrať: {trip}',
'native.plans.termsShort': 'Podmienky používania (EULA)',
+5 -1
View File
@@ -207,7 +207,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Det blir {price} i månaden',
'native.plans.storageFairUse': 'Lagring vid skälig användning',
'native.plans.aiPerMonth': '{n} / månad',
'native.plans.aiNone': 'Inga',
'native.plans.aiNone': 'Ingår inte',
'native.plans.included': 'Ingår',
'native.plans.planned': 'Planerat',
'native.plans.assistant': 'AI-assistent',
'native.plans.mailImport': 'Automatisk e-postimport',
'native.plans.aiLabel': 'AI-dokument',
'native.plans.choose': 'Välj {trip}',
'native.plans.termsShort': 'Användarvillkor (EULA)',
+5 -1
View File
@@ -196,7 +196,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'เท่ากับเดือนละ {price}',
'native.plans.storageFairUse': 'พื้นที่เก็บข้อมูลภายใต้การใช้งานอย่างเหมาะสม',
'native.plans.aiPerMonth': '{n} / เดือน',
'native.plans.aiNone': 'ไม่มี',
'native.plans.aiNone': 'ไม่รวม',
'native.plans.included': 'รวมแล้ว',
'native.plans.planned': 'อยู่ในแผน',
'native.plans.assistant': 'ผู้ช่วย AI',
'native.plans.mailImport': 'นำเข้าอีเมลอัตโนมัติ',
'native.plans.aiLabel': 'เอกสาร AI',
'native.plans.choose': 'เลือก{trip}',
'native.plans.termsShort': 'ข้อกำหนดการใช้งาน (EULA)',
+5 -1
View File
@@ -207,7 +207,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Ayda {price} eder',
'native.plans.storageFairUse': 'Adil kullanım depolama alanı',
'native.plans.aiPerMonth': '{n} / ay',
'native.plans.aiNone': 'Yok',
'native.plans.aiNone': 'Dahil değil',
'native.plans.included': 'Dahil',
'native.plans.planned': 'Planlanıyor',
'native.plans.assistant': 'Yapay zekâ asistanı',
'native.plans.mailImport': 'Otomatik e-posta içe aktarma',
'native.plans.aiLabel': 'Yapay zekâ belgeleri',
'native.plans.choose': '{trip} seç',
'native.plans.termsShort': 'Kullanım Koşulları (EULA)',
+5 -1
View File
@@ -208,7 +208,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Це {price} на місяць',
'native.plans.storageFairUse': 'Сховище за правилами добросовісного використання',
'native.plans.aiPerMonth': '{n} / міс.',
'native.plans.aiNone': 'Немає',
'native.plans.aiNone': 'Не включено',
'native.plans.included': 'Включено',
'native.plans.planned': 'Заплановано',
'native.plans.assistant': 'Асистент ШІ',
'native.plans.mailImport': 'Автоматичний імпорт листів',
'native.plans.aiLabel': 'Документи ШІ',
'native.plans.choose': 'Обрати: {trip}',
'native.plans.termsShort': 'Умови використання (EULA)',
+5 -1
View File
@@ -208,7 +208,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': 'Tức là {price} mỗi tháng',
'native.plans.storageFairUse': 'Dung lượng theo chính sách sử dụng hợp lý',
'native.plans.aiPerMonth': '{n} / tháng',
'native.plans.aiNone': 'Không có',
'native.plans.aiNone': 'Không bao gồm',
'native.plans.included': 'Đã bao gồm',
'native.plans.planned': 'Dự kiến',
'native.plans.assistant': 'Trợ lý AI',
'native.plans.mailImport': 'Tự động nhập email',
'native.plans.aiLabel': 'Tài liệu AI',
'native.plans.choose': 'Chọn {trip}',
'native.plans.termsShort': 'Điều khoản sử dụng (EULA)',
+5 -1
View File
@@ -196,7 +196,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': '相當於每月 {price}',
'native.plans.storageFairUse': '公平使用儲存空間',
'native.plans.aiPerMonth': '{n} / 月',
'native.plans.aiNone': '無',
'native.plans.aiNone': '不包含',
'native.plans.included': '已包含',
'native.plans.planned': '計畫推出',
'native.plans.assistant': 'AI 助理',
'native.plans.mailImport': '自動郵件匯入',
'native.plans.aiLabel': 'AI 文件',
'native.plans.choose': '選擇{trip}',
'native.plans.termsShort': '使用條款 (EULA)',
+5 -1
View File
@@ -195,7 +195,11 @@ const native: TranslationStrings = {
'native.plans.monthlyIs': '相当于每月 {price}',
'native.plans.storageFairUse': '公平使用存储空间',
'native.plans.aiPerMonth': '{n} / 月',
'native.plans.aiNone': '无',
'native.plans.aiNone': '不包含',
'native.plans.included': '已包含',
'native.plans.planned': '计划推出',
'native.plans.assistant': 'AI 助手',
'native.plans.mailImport': '自动邮件导入',
'native.plans.aiLabel': 'AI 文档',
'native.plans.choose': '选择{trip}',
'native.plans.termsShort': '使用条款 (EULA)',