diff --git a/Sources/ParcelUI/Resources/TourSetup.xcstrings b/Sources/ParcelUI/Resources/TourSetup.xcstrings index b7428d84..538031cc 100644 --- a/Sources/ParcelUI/Resources/TourSetup.xcstrings +++ b/Sources/ParcelUI/Resources/TourSetup.xcstrings @@ -10,15 +10,14 @@ "Accessibility lets Parcel move and resize your windows.": {"comment": "Permission explanation. Use the established macOS permission name.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Accessibility lets Parcel move and resize your windows."}}, "es": {"stringUnit": {"state": "translated", "value": "Accesibilidad permite que Parcel mueva tus ventanas y cambie su tamaño."}}, "fr": {"stringUnit": {"state": "translated", "value": "L’autorisation Accessibilité permet à Parcel de déplacer et de redimensionner vos fenêtres."}}, "de": {"stringUnit": {"state": "translated", "value": "Die Berechtigung für Bedienungshilfen erlaubt Parcel, Ihre Fenster zu verschieben und ihre Größe zu ändern."}}, "ja": {"stringUnit": {"state": "translated", "value": "アクセシビリティの許可により、Parcelがウインドウを移動したりサイズを変更したりできます。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "辅助功能权限允许 Parcel 移动窗口并调整大小。"}}, "ko": {"stringUnit": {"state": "translated", "value": "손쉬운 사용 권한을 통해 Parcel이 윈도우를 이동하고 크기를 조절할 수 있습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "A permissão de Acessibilidade permite que o Parcel mova e redimensione suas janelas."}}}}, "Allow Parcel in System Settings → General → Login Items.": {"comment": "macOS approval required for the optional login item. Use localized pane names.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Allow Parcel in System Settings → General → Login Items."}}, "es": {"stringUnit": {"state": "translated", "value": "Permite Parcel en Ajustes del Sistema → General → Ítems de inicio."}}, "fr": {"stringUnit": {"state": "translated", "value": "Autorisez Parcel dans Réglages Système → Général → Ouverture."}}, "de": {"stringUnit": {"state": "translated", "value": "Erlauben Sie Parcel unter Systemeinstellungen → Allgemein → Anmeldeobjekte."}}, "ja": {"stringUnit": {"state": "translated", "value": "「システム設定」→「一般」→「ログイン項目」でParcelを許可してください。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "在“系统设置”→“通用”→“登录项”中允许 Parcel。"}}, "ko": {"stringUnit": {"state": "translated", "value": "시스템 설정 → 일반 → 로그인 항목에서 Parcel을 허용하세요."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Permita o Parcel em Ajustes do Sistema → Geral → Itens de Início."}}}}, "Allow Parcel to arrange windows": {"comment": "Permission screen title. Accessibility is the only required permission.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Allow Parcel to arrange windows"}}, "es": {"stringUnit": {"state": "translated", "value": "Permite que Parcel organice las ventanas"}}, "fr": {"stringUnit": {"state": "translated", "value": "Autorisez Parcel à organiser les fenêtres"}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel das Anordnen von Fenstern erlauben"}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelによるウインドウの配置を許可"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "允许 Parcel 排列窗口"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel의 윈도우 배치 허용"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Permita que o Parcel organize janelas"}}}}, - "Arrange windows": {"comment": "Label for the native Automatic/Manual radio group.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Arrange windows"}}, "es": {"stringUnit": {"state": "translated", "value": "Organizar ventanas"}}, "fr": {"stringUnit": {"state": "translated", "value": "Organiser les fenêtres"}}, "de": {"stringUnit": {"state": "translated", "value": "Fenster anordnen"}}, "ja": {"stringUnit": {"state": "translated", "value": "ウインドウの配置"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "排列窗口"}}, "ko": {"stringUnit": {"state": "translated", "value": "윈도우 배치"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Organizar janelas"}}}}, - "Arrange windows only when you ask.": {"comment": "Help associated with Manual: windows move only following an explicit request.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Arrange windows only when you ask."}}, "es": {"stringUnit": {"state": "translated", "value": "Organiza las ventanas solo cuando lo pidas."}}, "fr": {"stringUnit": {"state": "translated", "value": "Organisez les fenêtres uniquement à votre demande."}}, "de": {"stringUnit": {"state": "translated", "value": "Fenster werden nur auf Ihren Wunsch angeordnet."}}, "ja": {"stringUnit": {"state": "translated", "value": "指示したときだけウインドウを配置します。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "仅在你发出指令时排列窗口。"}}, "ko": {"stringUnit": {"state": "translated", "value": "요청할 때만 윈도우를 배치합니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Organize as janelas somente quando você pedir."}}}}, + "Always arranged.": {"comment": "Short one-line Auto Mode subtitle. Keep concise enough for an equal-width choice button.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Always arranged."}}, "es": {"stringUnit": {"state": "translated", "value": "Siempre organizadas."}}, "fr": {"stringUnit": {"state": "translated", "value": "Toujours organisées."}}, "de": {"stringUnit": {"state": "translated", "value": "Immer angeordnet."}}, "ja": {"stringUnit": {"state": "translated", "value": "いつでも整然と。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "始终井然有序。"}}, "ko": {"stringUnit": {"state": "translated", "value": "항상 정돈되게."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Sempre organizadas."}}}}, "Arranging your windows…": {"comment": "In-flight transaction after explicit Tidy consent. Cancellation awaits writer termination and verified restoration.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Arranging your windows…"}}, "es": {"stringUnit": {"state": "translated", "value": "Organizando tus ventanas…"}}, "fr": {"stringUnit": {"state": "translated", "value": "Organisation de vos fenêtres…"}}, "de": {"stringUnit": {"state": "translated", "value": "Ihre Fenster werden angeordnet …"}}, "ja": {"stringUnit": {"state": "translated", "value": "ウインドウを配置中…"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "正在排列窗口…"}}, "ko": {"stringUnit": {"state": "translated", "value": "윈도우 배치 중…"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Organizando suas janelas…"}}}}, - "Automatic (Recommended)": {"comment": "Recommended draft mode: ongoing automatic tiling. Use the same recommendation term as the login toggle.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Automatic (Recommended)"}}, "es": {"stringUnit": {"state": "translated", "value": "Automático (Recomendado)"}}, "fr": {"stringUnit": {"state": "translated", "value": "Automatique (Recommandé)"}}, "de": {"stringUnit": {"state": "translated", "value": "Automatisch (Empfohlen)"}}, "ja": {"stringUnit": {"state": "translated", "value": "自動(推奨)"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "自动(推荐)"}}, "ko": {"stringUnit": {"state": "translated", "value": "자동(권장)"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Automático (Recomendado)"}}}}, + "Auto Mode": {"comment": "Welcome primary choice: continue with automatic arrangement intent; real windows stay still until Tidy on Ready.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Auto Mode"}}, "es": {"stringUnit": {"state": "translated", "value": "Modo automático"}}, "fr": {"stringUnit": {"state": "translated", "value": "Mode automatique"}}, "de": {"stringUnit": {"state": "translated", "value": "Auto-Modus"}}, "ja": {"stringUnit": {"state": "translated", "value": "自動モード"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "自动模式"}}, "ko": {"stringUnit": {"state": "translated", "value": "자동 모드"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Modo automático"}}}}, "Automatic tiling is off.": {"comment": "Off summary for safe failure, cancellation, uncertainty and uncommitted activation.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Automatic tiling is off."}}, "es": {"stringUnit": {"state": "translated", "value": "El mosaico automático está desactivado."}}, "fr": {"stringUnit": {"state": "translated", "value": "La mosaïque automatique est désactivée."}}, "de": {"stringUnit": {"state": "translated", "value": "Das automatische Kacheln ist ausgeschaltet."}}, "ja": {"stringUnit": {"state": "translated", "value": "自動タイル配置はオフです。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "自动平铺已关闭。"}}, "ko": {"stringUnit": {"state": "translated", "value": "자동 타일 배치는 꺼져 있습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O mosaico automático está desativado."}}}}, "Automatic tiling is on for the windows Parcel can arrange.": {"comment": "Safe partial completion: successful placements retained and automatic activation committed.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Automatic tiling is on for the windows Parcel can arrange."}}, "es": {"stringUnit": {"state": "translated", "value": "El mosaico automático está activado para las ventanas que Parcel puede organizar."}}, "fr": {"stringUnit": {"state": "translated", "value": "La mosaïque automatique est activée pour les fenêtres que Parcel peut organiser."}}, "de": {"stringUnit": {"state": "translated", "value": "Das automatische Kacheln ist für die Fenster eingeschaltet, die Parcel anordnen kann."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelが配置できるウインドウでは、自動タイル配置がオンです。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 可以排列的窗口已开启自动平铺。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 배치할 수 있는 윈도우에 대해 자동 타일 배치가 켜져 있습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O mosaico automático está ativado para as janelas que o Parcel consegue organizar."}}}}, "Automatic tiling is on.": {"comment": "Observed full/zero-movement success after durable activation commitment; also surviving status announcement. Does not claim all displays were already arranged.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Automatic tiling is on."}}, "es": {"stringUnit": {"state": "translated", "value": "El mosaico automático está activado."}}, "fr": {"stringUnit": {"state": "translated", "value": "La mosaïque automatique est activée."}}, "de": {"stringUnit": {"state": "translated", "value": "Das automatische Kacheln ist eingeschaltet."}}, "ja": {"stringUnit": {"state": "translated", "value": "自動タイル配置がオンです。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "自动平铺已开启。"}}, "ko": {"stringUnit": {"state": "translated", "value": "자동 타일 배치가 켜져 있습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O mosaico automático está ativado."}}}}, "Automatic tiling still works.": {"comment": "Secondary confirmed-clash notice; shortcut conflicts do not disable automatic arrangement.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Automatic tiling still works."}}, "es": {"stringUnit": {"state": "translated", "value": "El mosaico automático sigue funcionando."}}, "fr": {"stringUnit": {"state": "translated", "value": "La mosaïque automatique fonctionne toujours."}}, "de": {"stringUnit": {"state": "translated", "value": "Das automatische Kacheln funktioniert weiterhin."}}, "ja": {"stringUnit": {"state": "translated", "value": "自動タイル配置は引き続き使えます。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "自动平铺仍可正常使用。"}}, "ko": {"stringUnit": {"state": "translated", "value": "자동 타일 배치는 계속 작동합니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O mosaico automático continua funcionando."}}}}, - "Back": {"comment": "Navigate to the previous tour screen.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Back"}}, "es": {"stringUnit": {"state": "translated", "value": "Atrás"}}, "fr": {"stringUnit": {"state": "translated", "value": "Retour"}}, "de": {"stringUnit": {"state": "translated", "value": "Zurück"}}, "ja": {"stringUnit": {"state": "translated", "value": "戻る"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "返回"}}, "ko": {"stringUnit": {"state": "translated", "value": "뒤로"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Voltar"}}}}, + "Back": {"comment": "Accessible title and help for the native circular left-chevron button. Default tour-local shortcut is Command-left bracket.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Back"}}, "es": {"stringUnit": {"state": "translated", "value": "Atrás"}}, "fr": {"stringUnit": {"state": "translated", "value": "Retour"}}, "de": {"stringUnit": {"state": "translated", "value": "Zurück"}}, "ja": {"stringUnit": {"state": "translated", "value": "戻る"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "返回"}}, "ko": {"stringUnit": {"state": "translated", "value": "뒤로"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Voltar"}}}}, "Cancel": {"comment": "Request cancellation and restoration; do not dismiss while writes continue.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Cancel"}}, "es": {"stringUnit": {"state": "translated", "value": "Cancelar"}}, "fr": {"stringUnit": {"state": "translated", "value": "Annuler"}}, "de": {"stringUnit": {"state": "translated", "value": "Abbrechen"}}, "ja": {"stringUnit": {"state": "translated", "value": "キャンセル"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "取消"}}, "ko": {"stringUnit": {"state": "translated", "value": "취소"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Cancelar"}}}}, "Change layout": {"comment": "Optional reference row for the actual configured change-layout command.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Change layout"}}, "es": {"stringUnit": {"state": "translated", "value": "Cambiar diseño"}}, "fr": {"stringUnit": {"state": "translated", "value": "Changer la disposition"}}, "de": {"stringUnit": {"state": "translated", "value": "Layout ändern"}}, "ja": {"stringUnit": {"state": "translated", "value": "レイアウトを変更"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "更改布局"}}, "ko": {"stringUnit": {"state": "translated", "value": "레이아웃 변경"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Alterar layout"}}}}, "Check again": {"comment": "Repeat a bounded preflight or access check without moving windows.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Check again"}}, "es": {"stringUnit": {"state": "translated", "value": "Comprobar de nuevo"}}, "fr": {"stringUnit": {"state": "translated", "value": "Vérifier à nouveau"}}, "de": {"stringUnit": {"state": "translated", "value": "Erneut prüfen"}}, "ja": {"stringUnit": {"state": "translated", "value": "もう一度確認"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "重新检查"}}, "ko": {"stringUnit": {"state": "translated", "value": "다시 확인"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Verificar novamente"}}}}, @@ -37,16 +36,16 @@ "Finish setup": {"comment": "Manual final action: save completion with automatic tiling off, without any window move or release of queued work.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Finish setup"}}, "es": {"stringUnit": {"state": "translated", "value": "Terminar configuración"}}, "fr": {"stringUnit": {"state": "translated", "value": "Terminer la configuration"}}, "de": {"stringUnit": {"state": "translated", "value": "Einrichtung abschließen"}}, "ja": {"stringUnit": {"state": "translated", "value": "設定を完了"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "完成设置"}}, "ko": {"stringUnit": {"state": "translated", "value": "설정 완료"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Concluir configuração"}}}}, "Float": {"comment": "Overflow choice: leave new windows outside the tiled arrangement.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Float"}}, "es": {"stringUnit": {"state": "translated", "value": "Flotar"}}, "fr": {"stringUnit": {"state": "translated", "value": "Flotter"}}, "de": {"stringUnit": {"state": "translated", "value": "Frei platzieren"}}, "ja": {"stringUnit": {"state": "translated", "value": "フローティングにする"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "浮动"}}, "ko": {"stringUnit": {"state": "translated", "value": "플로팅"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Flutuar"}}}}, "Float window": {"comment": "Optional reference row for the actual configured floating command; excludes window from tiles, not necessarily always on top.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Float window"}}, "es": {"stringUnit": {"state": "translated", "value": "Hacer flotar la ventana"}}, "fr": {"stringUnit": {"state": "translated", "value": "Faire flotter la fenêtre"}}, "de": {"stringUnit": {"state": "translated", "value": "Fenster frei platzieren"}}, "ja": {"stringUnit": {"state": "translated", "value": "ウインドウをフローティングにする"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "浮动窗口"}}, "ko": {"stringUnit": {"state": "translated", "value": "윈도우 플로팅"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Flutuar janela"}}}}, - "Get started": {"comment": "Welcome primary action: advance to permission explanation, without requesting access or moving windows.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Get started"}}, "es": {"stringUnit": {"state": "translated", "value": "Empezar"}}, "fr": {"stringUnit": {"state": "translated", "value": "Commencer"}}, "de": {"stringUnit": {"state": "translated", "value": "Los geht’s"}}, "ja": {"stringUnit": {"state": "translated", "value": "はじめる"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "开始使用"}}, "ko": {"stringUnit": {"state": "translated", "value": "시작하기"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Começar"}}}}, "Highlight style": {"comment": "Shared Settings label for the visual treatment of the focused window; not a setup draft preference.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Highlight style"}}, "es": {"stringUnit": {"state": "translated", "value": "Estilo de resaltado"}}, "fr": {"stringUnit": {"state": "translated", "value": "Style de mise en évidence"}}, "de": {"stringUnit": {"state": "translated", "value": "Hervorhebungsstil"}}, "ja": {"stringUnit": {"state": "translated", "value": "強調表示のスタイル"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "高亮样式"}}, "ko": {"stringUnit": {"state": "translated", "value": "강조 스타일"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Estilo do destaque"}}}}, - "Keep windows arranged as you work.": {"comment": "Help associated with the Automatic option.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Keep windows arranged as you work."}}, "es": {"stringUnit": {"state": "translated", "value": "Mantén las ventanas organizadas mientras trabajas."}}, "fr": {"stringUnit": {"state": "translated", "value": "Gardez vos fenêtres organisées pendant que vous travaillez."}}, "de": {"stringUnit": {"state": "translated", "value": "Ihre Fenster bleiben beim Arbeiten angeordnet."}}, "ja": {"stringUnit": {"state": "translated", "value": "作業中もウインドウを整った状態に保ちます。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "工作时,窗口始终井然有序。"}}, "ko": {"stringUnit": {"state": "translated", "value": "작업하는 동안 윈도우를 정돈된 상태로 유지합니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Mantenha as janelas organizadas enquanto trabalha."}}}}, "Keyboard": {"comment": "Shared keyboard input category label, retained for Settings and demonstration consumers; v3 setup has no input-mode tabs.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Keyboard"}}, "es": {"stringUnit": {"state": "translated", "value": "Teclado"}}, "fr": {"stringUnit": {"state": "translated", "value": "Clavier"}}, "de": {"stringUnit": {"state": "translated", "value": "Tastatur"}}, "ja": {"stringUnit": {"state": "translated", "value": "キーボード"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "键盘"}}, "ko": {"stringUnit": {"state": "translated", "value": "키보드"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Teclado"}}}}, "Layout": {"comment": "Shared label for a window layout; a layout is distinct from a workspace or native Space.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Layout"}}, "es": {"stringUnit": {"state": "translated", "value": "Diseño"}}, "fr": {"stringUnit": {"state": "translated", "value": "Disposition"}}, "de": {"stringUnit": {"state": "translated", "value": "Layout"}}, "ja": {"stringUnit": {"state": "translated", "value": "レイアウト"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "布局"}}, "ko": {"stringUnit": {"state": "translated", "value": "레이아웃"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Layout"}}}}, "Loading shortcuts…": {"comment": "Optional reference loading state. Manual Finish setup remains available.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Loading shortcuts…"}}, "es": {"stringUnit": {"state": "translated", "value": "Cargando atajos…"}}, "fr": {"stringUnit": {"state": "translated", "value": "Chargement des raccourcis…"}}, "de": {"stringUnit": {"state": "translated", "value": "Kurzbefehle werden geladen …"}}, "ja": {"stringUnit": {"state": "translated", "value": "ショートカットを読み込み中…"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "正在载入快捷键…"}}, "ko": {"stringUnit": {"state": "translated", "value": "단축키 불러오는 중…"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Carregando atalhos…"}}}}, "Manual": {"comment": "Draft mode: automatic arrangement off; menu, mouse and configured shortcuts remain available. Not keyboard-only.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Manual"}}, "es": {"stringUnit": {"state": "translated", "value": "Manual"}}, "fr": {"stringUnit": {"state": "translated", "value": "Manuel"}}, "de": {"stringUnit": {"state": "translated", "value": "Manuell"}}, "ja": {"stringUnit": {"state": "translated", "value": "手動"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "手动"}}, "ko": {"stringUnit": {"state": "translated", "value": "수동"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Manual"}}}}, + "Manual Mode": {"comment": "Equally prominent Welcome choice: continue with manual intent. Finish setup later moves nothing.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Manual Mode"}}, "es": {"stringUnit": {"state": "translated", "value": "Modo manual"}}, "fr": {"stringUnit": {"state": "translated", "value": "Mode manuel"}}, "de": {"stringUnit": {"state": "translated", "value": "Manueller Modus"}}, "ja": {"stringUnit": {"state": "translated", "value": "手動モード"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "手动模式"}}, "ko": {"stringUnit": {"state": "translated", "value": "수동 모드"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Modo manual"}}}}, "Mouse": {"comment": "Shared mouse input category label, retained for Settings and demonstration consumers; v3 setup has no input-mode tabs.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Mouse"}}, "es": {"stringUnit": {"state": "translated", "value": "Ratón"}}, "fr": {"stringUnit": {"state": "translated", "value": "Souris"}}, "de": {"stringUnit": {"state": "translated", "value": "Maus"}}, "ja": {"stringUnit": {"state": "translated", "value": "マウス"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "鼠标"}}, "ko": {"stringUnit": {"state": "translated", "value": "마우스"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Mouse"}}}}, "Needs attention": {"comment": "Spoken status for a detected compatibility issue.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Needs attention"}}, "es": {"stringUnit": {"state": "translated", "value": "Requiere atención"}}, "fr": {"stringUnit": {"state": "translated", "value": "Attention requise"}}, "de": {"stringUnit": {"state": "translated", "value": "Handlungsbedarf"}}, "ja": {"stringUnit": {"state": "translated", "value": "要確認"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "需要处理"}}, "ko": {"stringUnit": {"state": "translated", "value": "확인 필요"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Requer atenção"}}}}, "Next window": {"comment": "Optional reference row for the actual configured next-window command.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Next window"}}, "es": {"stringUnit": {"state": "translated", "value": "Siguiente ventana"}}, "fr": {"stringUnit": {"state": "translated", "value": "Fenêtre suivante"}}, "de": {"stringUnit": {"state": "translated", "value": "Nächstes Fenster"}}, "ja": {"stringUnit": {"state": "translated", "value": "次のウインドウ"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "下一个窗口"}}, "ko": {"stringUnit": {"state": "translated", "value": "다음 윈도우"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Próxima janela"}}}}, + "Only when you ask.": {"comment": "Short one-line Manual Mode subtitle. Arrangement only after an explicit request; not keyboard-only.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Only when you ask."}}, "es": {"stringUnit": {"state": "translated", "value": "Solo cuando lo pidas."}}, "fr": {"stringUnit": {"state": "translated", "value": "À votre demande."}}, "de": {"stringUnit": {"state": "translated", "value": "Nur auf Wunsch."}}, "ja": {"stringUnit": {"state": "translated", "value": "指示したときだけ。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "仅在你发出指令时。"}}, "ko": {"stringUnit": {"state": "translated", "value": "요청할 때만."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Só quando você pedir."}}}}, "Open Login Items": {"comment": "Targeted action opening the macOS login-item approval pane.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Open Login Items"}}, "es": {"stringUnit": {"state": "translated", "value": "Abrir Ítems de inicio"}}, "fr": {"stringUnit": {"state": "translated", "value": "Ouvrir Ouverture"}}, "de": {"stringUnit": {"state": "translated", "value": "Anmeldeobjekte öffnen"}}, "ja": {"stringUnit": {"state": "translated", "value": "ログイン項目を開く"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "打开登录项"}}, "ko": {"stringUnit": {"state": "translated", "value": "로그인 항목 열기"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Abrir Itens de Início"}}}}, "Open Settings": {"comment": "Shared settings action. The v3 permission action uses the separate Open System Settings key.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Open Settings"}}, "es": {"stringUnit": {"state": "translated", "value": "Abrir Ajustes"}}, "fr": {"stringUnit": {"state": "translated", "value": "Réglages Système"}}, "de": {"stringUnit": {"state": "translated", "value": "Systemeinstellungen…"}}, "ja": {"stringUnit": {"state": "translated", "value": "システム設定を開く"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "打开系统设置"}}, "ko": {"stringUnit": {"state": "translated", "value": "시스템 설정 열기"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Abrir Ajustes do Sistema"}}}}, "Open System Settings": {"comment": "Open the relevant macOS settings pane only after explicit activation.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Open System Settings"}}, "es": {"stringUnit": {"state": "translated", "value": "Abrir Ajustes del Sistema"}}, "fr": {"stringUnit": {"state": "translated", "value": "Ouvrir Réglages Système"}}, "de": {"stringUnit": {"state": "translated", "value": "Systemeinstellungen öffnen"}}, "ja": {"stringUnit": {"state": "translated", "value": "システム設定を開く"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "打开系统设置"}}, "ko": {"stringUnit": {"state": "translated", "value": "시스템 설정 열기"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Abrir Ajustes do Sistema"}}}}, @@ -62,14 +61,12 @@ "Parcel couldn’t finish setup. Your windows haven’t moved.": {"comment": "Manual completion save failed. No frame write was attempted; remain on screen and retry saving explicitly.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel couldn’t finish setup. Your windows haven’t moved."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel no pudo terminar la configuración. Tus ventanas no se han movido."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel n’a pas pu terminer la configuration. Vos fenêtres n’ont pas bougé."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel konnte die Einrichtung nicht abschließen. Ihre Fenster wurden nicht verschoben."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelの設定を完了できませんでした。ウインドウは移動していません。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 无法完成设置。窗口未移动。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 설정을 완료하지 못했습니다. 윈도우는 이동하지 않았습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel não conseguiu concluir a configuração. Suas janelas não foram movidas."}}}}, "Parcel couldn’t load your settings.": {"comment": "Configuration preflight failed. Do not substitute factory defaults.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel couldn’t load your settings."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel no pudo cargar tus ajustes."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel n’a pas pu charger vos réglages."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel konnte Ihre Einstellungen nicht laden."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelが設定を読み込めませんでした。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 无法载入你的设置。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 설정을 불러오지 못했습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel não conseguiu carregar seus ajustes."}}}}, "Parcel couldn’t read setup progress. Check setup and try again.": {"comment": "Recoverable invalid/unreadable v3 progress record. Never infer consent or reset silently.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel couldn’t read setup progress. Check setup and try again."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel no pudo leer el progreso de la configuración. Comprueba la configuración e inténtalo de nuevo."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel n’a pas pu lire la progression de la configuration. Vérifiez la configuration et réessayez."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel konnte den Einrichtungsfortschritt nicht lesen. Prüfen Sie die Einrichtung und versuchen Sie es erneut."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelが設定の進行状況を読み込めませんでした。設定を確認してから、もう一度お試しください。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 无法读取设置进度。请检查设置后重试。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 설정 진행 상황을 읽지 못했습니다. 설정을 확인하고 다시 시도하세요."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel não conseguiu ler o progresso da configuração. Verifique a configuração e tente novamente."}}}}, + "Parcel couldn’t read the Back shortcut. Use a shortcut or ‘none’.": {"comment": "Invalid stored tour-local Back preference; none disables it. Do not translate the literal preference value none.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel couldn’t read the Back shortcut. Use a shortcut or ‘none’."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel no pudo leer el atajo Atrás. Usa un atajo o «none»."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel n’a pas pu lire le raccourci Retour. Utilisez un raccourci ou « none »."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel konnte den Zurück-Kurzbefehl nicht lesen. Verwenden Sie einen Kurzbefehl oder „none“."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelが「戻る」のショートカットを読み込めませんでした。ショートカットまたは「none」を指定してください。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 无法读取“返回”快捷键。请使用快捷键或“none”。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 뒤로 단축키를 읽지 못했습니다. 단축키 또는 ‘none’을 사용하세요."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel não conseguiu ler o atalho Voltar. Use um atalho ou “none”."}}}}, "Parcel couldn’t save setup progress.": {"comment": "Durable setup checkpoint failed. Keep runtime held/off and disable Tidy; no claim of resumability or completion.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel couldn’t save setup progress."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel no pudo guardar el progreso de la configuración."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel n’a pas pu enregistrer la progression de la configuration."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel konnte den Einrichtungsfortschritt nicht speichern."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelが設定の進行状況を保存できませんでした。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 无法保存设置进度。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 설정 진행 상황을 저장하지 못했습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel não conseguiu salvar o progresso da configuração."}}}}, "Parcel moves windows only when you ask. Choose Retile in the Parcel menu to arrange them.": {"comment": "Manual Ready summary, before movement. Retile is the actual Parcel menu command; translate consistently with that command. Manual is automatic arrangement off, not keyboard-only.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel moves windows only when you ask. Choose Retile in the Parcel menu to arrange them."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel mueve las ventanas solo cuando lo pides. Elige Reorganizar en el menú de Parcel para organizarlas."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel déplace les fenêtres uniquement à votre demande. Choisissez Réorganiser dans le menu de Parcel pour les organiser."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel verschiebt Fenster nur auf Ihren Wunsch. Wählen Sie Neu anordnen im Parcel-Menü, um sie anzuordnen."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelは指示したときだけウインドウを移動します。配置するには、Parcelメニューの「再配置」を選んでください。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 仅在你发出指令时移动窗口。选择 Parcel 菜单中的“重新平铺”即可排列窗口。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel은 요청할 때만 윈도우를 이동합니다. 윈도우를 배치하려면 Parcel 메뉴에서 ‘다시 배치’를 선택하세요."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel move janelas somente quando você pede. Escolha Reorganizar no menu do Parcel para organizá-las."}}}}, "Parcel still needs access. Turn its Accessibility switch off, then on.": {"comment": "Only after a failed permission recheck, not initial instructions. Do not reset permissions automatically.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel still needs access. Turn its Accessibility switch off, then on."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel aún necesita acceso. Desactiva y vuelve a activar su interruptor de Accesibilidad."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel a toujours besoin d’un accès. Désactivez, puis réactivez son autorisation Accessibilité."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel benötigt weiterhin Zugriff. Schalten Sie seinen Zugriff auf Bedienungshilfen aus und wieder ein."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelにはまだアクセス権が必要です。Parcelのアクセシビリティのスイッチを一度オフにしてから、オンにしてください。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 仍需要权限。请将其辅助功能开关关闭后再打开。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel에 아직 접근 권한이 필요합니다. Parcel의 손쉬운 사용 스위치를 껐다가 다시 켜세요."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel ainda precisa de acesso. Desative e reative a permissão de Acessibilidade dele."}}}}, "Parcel tiles your windows automatically. No shortcuts needed.": {"comment": "Welcome summary. Automatic arrangement does not require keyboard shortcuts.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel tiles your windows automatically. No shortcuts needed."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel organiza tus ventanas en mosaico automáticamente. No necesitas atajos."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel organise automatiquement vos fenêtres en mosaïque. Aucun raccourci nécessaire."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel ordnet Ihre Fenster automatisch in Kacheln an. Keine Kurzbefehle nötig."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelがウインドウを自動でタイル配置します。ショートカットは不要です。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 自动平铺窗口,无需使用快捷键。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 윈도우를 자동으로 타일 배치합니다. 단축키는 필요 없습니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel organiza suas janelas em mosaico automaticamente. Não é preciso usar atalhos."}}}}, "Parcel will tidy your windows and keep them arranged automatically.": {"comment": "One-display Automatic Ready summary; future action, not an observed success.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Parcel will tidy your windows and keep them arranged automatically."}}, "es": {"stringUnit": {"state": "translated", "value": "Parcel ordenará tus ventanas y las mantendrá organizadas automáticamente."}}, "fr": {"stringUnit": {"state": "translated", "value": "Parcel réorganisera vos fenêtres et les gardera organisées automatiquement."}}, "de": {"stringUnit": {"state": "translated", "value": "Parcel wird Ihre Fenster anordnen und automatisch angeordnet halten."}}, "ja": {"stringUnit": {"state": "translated", "value": "Parcelがウインドウを整え、その後も自動で整った状態に保ちます。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "Parcel 将整理窗口,并自动保持窗口有序排列。"}}, "ko": {"stringUnit": {"state": "translated", "value": "Parcel이 윈도우를 정리하고 자동으로 정돈된 상태를 유지합니다."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "O Parcel organizará suas janelas e as manterá organizadas automaticamente."}}}}, - "Pause demo": {"comment": "Pause the fictional Welcome animation; no real windows move.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Pause demo"}}, "es": {"stringUnit": {"state": "translated", "value": "Pausar demostración"}}, "fr": {"stringUnit": {"state": "translated", "value": "Mettre la démo en pause"}}, "de": {"stringUnit": {"state": "translated", "value": "Demo pausieren"}}, "ja": {"stringUnit": {"state": "translated", "value": "デモを一時停止"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "暂停演示"}}, "ko": {"stringUnit": {"state": "translated", "value": "데모 일시 정지"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Pausar demonstração"}}}}, - "Play demo": {"comment": "Resume the fictional Welcome animation; no real windows move.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Play demo"}}, "es": {"stringUnit": {"state": "translated", "value": "Reproducir demostración"}}, "fr": {"stringUnit": {"state": "translated", "value": "Lire la démo"}}, "de": {"stringUnit": {"state": "translated", "value": "Demo abspielen"}}, "ja": {"stringUnit": {"state": "translated", "value": "デモを再生"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "播放演示"}}, "ko": {"stringUnit": {"state": "translated", "value": "데모 재생"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Reproduzir demonstração"}}}}, - "Prefer manual control?": {"comment": "Optional disclosure for choosing automatic arrangement off.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Prefer manual control?"}}, "es": {"stringUnit": {"state": "translated", "value": "¿Prefieres el control manual?"}}, "fr": {"stringUnit": {"state": "translated", "value": "Vous préférez un contrôle manuel ?"}}, "de": {"stringUnit": {"state": "translated", "value": "Lieber manuell steuern?"}}, "ja": {"stringUnit": {"state": "translated", "value": "手動で操作しますか?"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "更喜欢手动控制?"}}, "ko": {"stringUnit": {"state": "translated", "value": "직접 제어하고 싶으신가요?"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Prefere o controle manual?"}}}}, "Ready to start": {"comment": "Accessible meaning of the Ready checkmark: preparation complete, not proof of arranged windows.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Ready to start"}}, "es": {"stringUnit": {"state": "translated", "value": "Listo para empezar"}}, "fr": {"stringUnit": {"state": "translated", "value": "Prêt à commencer"}}, "de": {"stringUnit": {"state": "translated", "value": "Bereit zum Starten"}}, "ja": {"stringUnit": {"state": "translated", "value": "開始する準備ができました"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "准备开始"}}, "ko": {"stringUnit": {"state": "translated", "value": "시작할 준비가 됐습니다"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Pronto para começar"}}}}, "Retile": {"comment": "Optional reference row for the actual configured Retile command; no action on row activation.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Retile"}}, "es": {"stringUnit": {"state": "translated", "value": "Reorganizar"}}, "fr": {"stringUnit": {"state": "translated", "value": "Réorganiser"}}, "de": {"stringUnit": {"state": "translated", "value": "Neu anordnen"}}, "ja": {"stringUnit": {"state": "translated", "value": "再配置"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "重新平铺"}}, "ko": {"stringUnit": {"state": "translated", "value": "다시 배치"}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Reorganizar"}}}}, "Review Parcel’s notice for windows that could not settle: %@.": {"comment": "Placeholder is a localized list of window titles or IDs that failed readback.", "localizations": {"en": {"stringUnit": {"state": "translated", "value": "Review Parcel’s notice for windows that could not settle: %@."}}, "es": {"stringUnit": {"state": "translated", "value": "Revisa el aviso de Parcel sobre las ventanas que no pudieron colocarse: %@."}}, "fr": {"stringUnit": {"state": "translated", "value": "Consultez l’avis de Parcel au sujet des fenêtres qui n’ont pas pu trouver leur place : %@."}}, "de": {"stringUnit": {"state": "translated", "value": "In der Parcel-Mitteilung finden Sie die Fenster, die sich nicht platzieren ließen: %@."}}, "ja": {"stringUnit": {"state": "translated", "value": "配置できなかったウインドウについて、Parcelのお知らせを確認してください:%@。"}}, "zh-Hans": {"stringUnit": {"state": "translated", "value": "请查看 Parcel 的通知,了解无法正确就位的窗口:%@。"}}, "ko": {"stringUnit": {"state": "translated", "value": "제자리에 배치하지 못한 윈도우를 확인하려면 Parcel 알림을 살펴보세요: %@."}}, "pt-BR": {"stringUnit": {"state": "translated", "value": "Confira o aviso do Parcel sobre as janelas que não se posicionaram: %@."}}}}, diff --git a/Sources/ParcelUI/Tour/README.md b/Sources/ParcelUI/Tour/README.md index 8fded056..66544be5 100644 --- a/Sources/ParcelUI/Tour/README.md +++ b/Sources/ParcelUI/Tour/README.md @@ -1,9 +1,10 @@ # Guided tour -Welcome → Allow Parcel → Ready, for both Automatic and Manual. Automatic is the -recommended default; Manual is an optional Welcome choice. The resizable native -panel scrolls its content while keeping the footer in place. Welcome uses only -fictional windows, with playback and static reduced-motion paths. +Welcome → Allow Parcel → Ready, for both Auto Mode and Manual Mode. Welcome offers +two equal primary choices; either saves the intent and opens Allow. The native +full-size window keeps its traffic lights without an inner frame. Welcome never +scrolls: its fictional demo shrinks before text or controls, plays while active, +and becomes a static tiled frame with Reduce Motion or motion off. First run and replay hold every product write before discovery or queued motion. Grant changes, navigation, Settings links, and config reloads never release that @@ -13,6 +14,11 @@ After writers drain, the tour retires earlier shutdown-placement debt so deferri and quitting cannot replay pre-tour frames. This is bookkeeping, not a native capture. Completed v2 users are not forced through v3. +The circular Back button uses Command-left bracket. The window-local preference +`guidedTour.navigation.back` accepts the configured chord grammar or `none` to +remove the shortcut; an absent value uses the defaults table. Changes take effect +at the next launch. Invalid values fail visibly rather than restoring defaults. + Allow checks Accessibility without auto-advancing. Open at login is recommended and defaults on only for a fresh install. Its staged change is attempted once on Continue; failure is optional and never blocks Ready or retries from Tidy. Checks diff --git a/Sources/ParcelUI/Tour/TourBackButton.swift b/Sources/ParcelUI/Tour/TourBackButton.swift new file mode 100644 index 00000000..004834d4 --- /dev/null +++ b/Sources/ParcelUI/Tour/TourBackButton.swift @@ -0,0 +1,43 @@ +import AppKit +import SwiftUI + +struct TourBackButton: NSViewRepresentable { + let controller: WindowLearningController + + func makeCoordinator() -> Coordinator { Coordinator(controller: controller) } + + func makeNSView(context: Context) -> NSButton { + let button = NSButton( + title: TourText.text("Back"), target: context.coordinator, action: #selector(Coordinator.back)) + button.bezelStyle = .circular + button.controlSize = .large + button.image = NSImage(systemSymbolName: "chevron.left", accessibilityDescription: nil) + button.imagePosition = .imageOnly + button.setContentHuggingPriority(.required, for: .horizontal) + return button + } + + func updateNSView(_ button: NSButton, context: Context) { + context.coordinator.controller = controller + let title = TourText.text("Back") + button.title = title + button.toolTip = title + button.setAccessibilityLabel(title) + button.setAccessibilityIdentifier("tour.back") + button.isEnabled = !controller.setup.isBusy + let shortcut = controller.navigationShortcuts.backShortcut + button.keyEquivalent = shortcut.keyEquivalent + button.keyEquivalentModifierMask = shortcut.modifierMask + } + + @MainActor + final class Coordinator: NSObject { + var controller: WindowLearningController + + init(controller: WindowLearningController) { self.controller = controller } + + @objc func back() { + controller.runSetup { try await self.controller.setup.back() } + } + } +} diff --git a/Sources/ParcelUI/Tour/TourDemoWelcome.swift b/Sources/ParcelUI/Tour/TourDemoWelcome.swift index 7190e845..f73133e1 100644 --- a/Sources/ParcelUI/Tour/TourDemoWelcome.swift +++ b/Sources/ParcelUI/Tour/TourDemoWelcome.swift @@ -3,7 +3,6 @@ import SwiftUI struct TourDemoWelcome: View { let configuration: ParcelConfiguration - var paused = false @Environment(\.accessibilityReduceMotion) private var reduceMotion @State private var playback = TourDemoLoopPlayback() @State private var windowActive = false @@ -39,7 +38,7 @@ struct TourDemoWelcome: View { pageVisible = false stop() } - .task(id: Request(motion: motion, pageVisible: pageVisible, windowActive: windowActive, paused: paused)) { + .task(id: Request(motion: motion, pageVisible: pageVisible, windowActive: windowActive)) { await play() } } @@ -54,7 +53,7 @@ struct TourDemoWelcome: View { private func play() async { let generation = playback.update( - animated: motion.spec != nil, pageVisible: pageVisible && !paused, windowActive: windowActive, + animated: motion.spec != nil, pageVisible: pageVisible, windowActive: windowActive, cancelled: Task.isCancelled) guard let generation, let spec = motion.spec, let animation = motion.animation else { return } while !Task.isCancelled { @@ -76,6 +75,5 @@ struct TourDemoWelcome: View { let motion: TourDemoMotion let pageVisible: Bool let windowActive: Bool - let paused: Bool } } diff --git a/Sources/ParcelUI/Tour/TourNavigationPreferenceError.swift b/Sources/ParcelUI/Tour/TourNavigationPreferenceError.swift new file mode 100644 index 00000000..3a9b29ee --- /dev/null +++ b/Sources/ParcelUI/Tour/TourNavigationPreferenceError.swift @@ -0,0 +1,9 @@ +import Foundation + +enum TourNavigationPreferenceError: LocalizedError { + case invalidValue + + var errorDescription: String? { + TourText.text("Parcel couldn’t read the Back shortcut. Use a shortcut or ‘none’.") + } +} diff --git a/Sources/ParcelUI/Tour/TourNavigationShortcuts.swift b/Sources/ParcelUI/Tour/TourNavigationShortcuts.swift new file mode 100644 index 00000000..ab4315bd --- /dev/null +++ b/Sources/ParcelUI/Tour/TourNavigationShortcuts.swift @@ -0,0 +1,21 @@ +import Foundation +import ParcelConfig + +struct TourNavigationShortcuts { + static let backPreferenceKey = "guidedTour.navigation.back" + static let defaults = Self(back: KeyChord(modifiers: .cmd, key: .leftBracket)) + let back: KeyChord? + + init(back: KeyChord?) { self.back = back } + + init(defaults: UserDefaults) throws { + guard let value = defaults.object(forKey: Self.backPreferenceKey) else { + self = Self.defaults + return + } + guard let text = value as? String else { throw TourNavigationPreferenceError.invalidValue } + back = text == "none" ? nil : try KeyChord(parsing: text) + } + + var backShortcut: MenuShortcut { MenuShortcut(back) } +} diff --git a/Sources/ParcelUI/Tour/TourSetup.swift b/Sources/ParcelUI/Tour/TourSetup.swift index e7bfaa02..251f9eaa 100644 --- a/Sources/ParcelUI/Tour/TourSetup.swift +++ b/Sources/ParcelUI/Tour/TourSetup.swift @@ -292,6 +292,13 @@ public final class TourSetupController { } } + public func chooseMode(_ intent: TourStartIntent) async throws { + try Task.checkCancellation() + guard isPresented, step == .welcome, canContinue, result == nil else { throw TourSetupFailure.notReady } + try navigate(.allow, intent: intent) + try await checkCurrentStep() + } + public func next() async throws { guard canContinue else { throw TourSetupFailure.notReady } switch step { @@ -312,9 +319,10 @@ public final class TourSetupController { try await checkCurrentStep() } - private func navigate(_ step: TourSetupStep) throws { + private func navigate(_ step: TourSetupStep, intent: TourStartIntent? = nil) throws { guard progressStateValid else { throw TourProgressFailure.invalid } var next = progress + if let intent { next.intent = intent } next.step = step next.disposition = .inProgress try saveProgress(next) diff --git a/Sources/ParcelUI/Tour/TourSetupView.swift b/Sources/ParcelUI/Tour/TourSetupView.swift index c8ae3f26..4a524adb 100644 --- a/Sources/ParcelUI/Tour/TourSetupView.swift +++ b/Sources/ParcelUI/Tour/TourSetupView.swift @@ -4,7 +4,6 @@ import SwiftUI struct TourSetupView: View { let controller: WindowLearningController @Bindable private var setup: TourSetupController - @Environment(\.accessibilityReduceMotion) private var reduceMotion @AccessibilityFocusState private var titleFocused: Bool @AccessibilityFocusState private var errorFocused: Bool @FocusState private var primaryFocused: Bool @@ -15,60 +14,18 @@ struct TourSetupView: View { var body: some View { VStack(spacing: 0) { - ScrollView { - VStack(alignment: .leading, spacing: 18) { - Text(TourText.text(setup.step.title)) - .font(.title.bold()) - .accessibilityAddTraits(.isHeader) - .accessibilityIdentifier("tour.title") - .accessibilityFocused($titleFocused) - Text(summary).fixedSize(horizontal: false, vertical: true) - switch setup.step { - case .welcome: welcome - case .allow: TourAllowView(controller: controller) - case .ready: ready - } - if let result = setup.result { - VStack(alignment: .leading, spacing: 8) { - Label( - result.title, systemImage: result.completed ? "info.circle" : "exclamationmark.triangle" - ) - .fixedSize(horizontal: false, vertical: true) - .accessibilityIdentifier("tour.result") - .accessibilityFocused($errorFocused) - if let message = result.message { - Text(message).fixedSize(horizontal: false, vertical: true) - .accessibilityIdentifier("tour.tidy.summary") - } - if !result.details.isEmpty { - DisclosureGroup(TourText.text("Details"), isExpanded: $setup.detailsExpanded) { - ForEach(Array(result.details.enumerated()), id: \.offset) { _, detail in - Text(detail).textSelection(.enabled).fixedSize( - horizontal: false, vertical: true) - } - } - } - } - } else if let error = setup.errorMessage { - Label(error, systemImage: "exclamationmark.triangle") - .fixedSize(horizontal: false, vertical: true) - .accessibilityIdentifier("tour.error") - .accessibilityFocused($errorFocused) - Button(TourText.text("Try again")) { controller.retryTourProgress() } - .accessibilityIdentifier("tour.retry.progress") - } - } - .frame(maxWidth: .infinity, alignment: .leading) - .padding(32) + if setup.step == .welcome { + content + .frame(maxHeight: .infinity, alignment: .top) + } else { + ScrollView { content } + .scrollBounceBehavior(.basedOnSize) } - .scrollBounceBehavior(.basedOnSize) Divider() VStack(spacing: 8) { HStack(alignment: .center, spacing: 14) { if setup.step != .welcome, setup.result == nil { - Button(TourText.text("Back")) { controller.runSetup { try await setup.back() } } - .disabled(setup.isBusy) - .accessibilityIdentifier("tour.back") + TourBackButton(controller: controller) } Button(action: exit) { Text(exitTitle).fixedSize(horizontal: false, vertical: true) @@ -76,16 +33,18 @@ struct TourSetupView: View { .buttonStyle(.link) .accessibilityIdentifier("tour.defer") Spacer(minLength: 0) - Button(action: primary) { - Text(primaryTitle).fixedSize(horizontal: false, vertical: true) - .multilineTextAlignment(.center) + if setup.step != .welcome || setup.result != nil { + Button(action: primary) { + Text(primaryTitle).fixedSize(horizontal: false, vertical: true) + .multilineTextAlignment(.center) + } + .buttonStyle(.borderedProminent) + .keyboardShortcut(.defaultAction) + .disabled(!primaryEnabled) + .focused($primaryFocused) + .accessibilityIdentifier( + setup.step == .ready && setup.intent == .automatic ? "tour.tidy" : "tour.continue") } - .buttonStyle(.borderedProminent) - .keyboardShortcut(.defaultAction) - .disabled(!primaryEnabled) - .focused($primaryFocused) - .accessibilityIdentifier( - setup.step == .ready && setup.intent == .automatic ? "tour.tidy" : "tour.continue") } if setup.isReplay { Text(TourText.text("Closing the tour leaves automatic tiling off.")) @@ -95,11 +54,11 @@ struct TourSetupView: View { } .padding(.horizontal, 32) .padding(.vertical, 16) - .frame(height: footerHeight) + .frame(height: setup.step == .welcome && !setup.isReplay ? 64 : footerHeight) } .onChange(of: setup.step, initial: true) { titleFocused = true - primaryFocused = true + primaryFocused = setup.step != .welcome controller.setupScreenChanged() } .onChange(of: setup.result) { @@ -112,6 +71,61 @@ struct TourSetupView: View { .onExitCommand { controller.closeSetup() } } + private var content: some View { + VStack(alignment: .leading, spacing: 18) { + heading + Text(summary).fixedSize(horizontal: false, vertical: true) + switch setup.step { + case .welcome: + TourWelcomeView( + configuration: controller.configuration, intent: setup.intent, + isEnabled: setup.canContinue && setup.result == nil + ) { intent in + controller.runSetup { try await setup.chooseMode(intent) } + } + case .allow: TourAllowView(controller: controller) + case .ready: ready + } + if let result = setup.result { + VStack(alignment: .leading, spacing: 8) { + Label(result.title, systemImage: result.completed ? "info.circle" : "exclamationmark.triangle") + .fixedSize(horizontal: false, vertical: true) + .accessibilityIdentifier("tour.result") + .accessibilityFocused($errorFocused) + if let message = result.message { + Text(message).fixedSize(horizontal: false, vertical: true) + .accessibilityIdentifier("tour.tidy.summary") + } + if !result.details.isEmpty { + DisclosureGroup(TourText.text("Details"), isExpanded: $setup.detailsExpanded) { + ForEach(Array(result.details.enumerated()), id: \.offset) { _, detail in + Text(detail).textSelection(.enabled).fixedSize(horizontal: false, vertical: true) + } + } + } + } + } else if let error = setup.errorMessage { + Label(error, systemImage: "exclamationmark.triangle") + .fixedSize(horizontal: false, vertical: true) + .accessibilityIdentifier("tour.error") + .accessibilityFocused($errorFocused) + Button(TourText.text("Try again")) { controller.retryTourProgress() } + .accessibilityIdentifier("tour.retry.progress") + } + } + .frame(maxWidth: .infinity, alignment: .leading) + .padding(32) + } + + private var heading: some View { + Text(TourText.text(setup.step.title)) + .font(.title.bold()) + .fixedSize(horizontal: false, vertical: true) + .accessibilityAddTraits(.isHeader) + .accessibilityIdentifier("tour.title") + .accessibilityFocused($titleFocused) + } + private var summary: String { switch setup.step { case .welcome: TourText.text("Parcel tiles your windows automatically. No shortcuts needed.") @@ -128,39 +142,6 @@ struct TourSetupView: View { } } - private var welcome: some View { - VStack(alignment: .leading, spacing: 12) { - TourDemoWelcome(configuration: controller.configuration, paused: setup.demoPaused) - .frame(maxWidth: 400) - .frame(maxWidth: .infinity) - if controller.configuration.motion.enabled && !reduceMotion { - Button(TourText.text(setup.demoPaused ? "Play demo" : "Pause demo")) { setup.demoPaused.toggle() } - .accessibilityIdentifier("tour.demo.playback") - } - DisclosureGroup(TourText.text("Prefer manual control?"), isExpanded: $setup.modeExpanded) { - Picker(TourText.text("Arrange windows"), selection: $setup.intent) { - VStack(alignment: .leading) { - Text(TourText.text("Automatic (Recommended)")) - Text(TourText.text("Keep windows arranged as you work.")).foregroundStyle(.secondary) - }.tag(TourStartIntent.automatic) - .accessibilityIdentifier("tour.mode.automatic") - VStack(alignment: .leading) { - Text(TourText.text("Manual")) - Text(TourText.text("Arrange windows only when you ask.")).foregroundStyle(.secondary) - }.tag(TourStartIntent.manual) - .accessibilityIdentifier("tour.mode.manual") - } - .pickerStyle(.radioGroup) - .accessibilityIdentifier("tour.mode") - } - .accessibilityIdentifier("tour.mode.disclosure") - if setup.intent == .manual && !setup.modeExpanded { - Text(TourText.text("Manual")).font(.headline) - Text(TourText.text("Arrange windows only when you ask.")) - } - } - } - private var ready: some View { VStack(alignment: .leading, spacing: 16) { if setup.result == nil && !setup.isBusy { @@ -211,7 +192,6 @@ struct TourSetupView: View { Button(TourText.text("Open System Settings")) { controller.changeSetup { try setup.openAccessibilitySettings() } } - Button(TourText.text("Back")) { controller.runSetup { try await setup.back() } } case .stageManager: Button(TourText.text("Open System Settings")) { controller.changeSetup { try setup.openSettings(for: .ready) } @@ -284,7 +264,7 @@ struct TourSetupView: View { if setup.step == .ready { return TourText.text(setup.intent == .automatic ? "Tidy my workspace" : "Finish setup") } - return TourText.text("Get started") + return TourText.text("Continue") } private var primaryEnabled: Bool { if setup.isBusy { return false } diff --git a/Sources/ParcelUI/Tour/TourView.swift b/Sources/ParcelUI/Tour/TourView.swift index 7147bf82..26a0ed70 100644 --- a/Sources/ParcelUI/Tour/TourView.swift +++ b/Sources/ParcelUI/Tour/TourView.swift @@ -12,6 +12,7 @@ struct TourView: View { Group { if controller.setup.isPresented { TourSetupView(controller: controller) + .ignoresSafeArea(.container, edges: .top) .frame(minWidth: 480, maxWidth: .infinity, minHeight: 400, maxHeight: .infinity) } else { VStack(alignment: .leading, spacing: 16) { @@ -34,8 +35,7 @@ struct TourView: View { controller.resizePanel(to: $0) } .background(Color(nsColor: .windowBackgroundColor)) - .overlay(RoundedRectangle(cornerRadius: 12).stroke(.primary, lineWidth: contrast == .increased ? 2 : 1)) - .clipShape(RoundedRectangle(cornerRadius: 12)) + .modifier(TourWindowChrome(setupWindow: controller.setup.isPresented, contrast: contrast)) .animation(phaseAnimation, value: controller.tour.progress.phase) .task( id: WinRequest( diff --git a/Sources/ParcelUI/Tour/TourWelcomeView.swift b/Sources/ParcelUI/Tour/TourWelcomeView.swift new file mode 100644 index 00000000..69df9c00 --- /dev/null +++ b/Sources/ParcelUI/Tour/TourWelcomeView.swift @@ -0,0 +1,69 @@ +import ParcelConfig +import SwiftUI + +struct TourWelcomeView: View { + let configuration: ParcelConfiguration + let intent: TourStartIntent + let isEnabled: Bool + let choose: (TourStartIntent) -> Void + @Environment(\.dynamicTypeSize) private var textSize + @FocusState private var focusedIntent: TourStartIntent? + + var body: some View { + VStack(spacing: 18) { + GeometryReader { geometry in + let width = max(0, min(400, geometry.size.width, geometry.size.height * 1.6)) + TourDemoWelcome(configuration: configuration) + .frame(width: width, height: width / 1.6) + .frame(maxWidth: .infinity, maxHeight: .infinity) + } + .layoutPriority(-1) + choices + .frame(maxWidth: .infinity) + } + .onAppear { focusedIntent = intent } + } + + @ViewBuilder private var choices: some View { + if textSize.isAccessibilitySize { + VStack(spacing: 12) { + choice(.automatic) + choice(.manual) + } + } else { + ViewThatFits(in: .horizontal) { + HStack(spacing: 16) { + choice(.automatic) + choice(.manual) + } + VStack(spacing: 12) { + choice(.automatic) + choice(.manual) + } + } + } + } + + private func choice(_ mode: TourStartIntent) -> some View { + let title = TourText.text(mode == .automatic ? "Auto Mode" : "Manual Mode") + let subtitle = TourText.text(mode == .automatic ? "Always arranged." : "Only when you ask.") + return Button { + choose(mode) + } label: { + VStack(spacing: 6) { + Text(title).font(.headline) + Text(subtitle).font(.callout).fixedSize() + } + .fixedSize(horizontal: false, vertical: true) + .frame(maxWidth: .infinity, minHeight: 56) + } + .buttonStyle(.borderedProminent) + .controlSize(.large) + .disabled(!isEnabled) + .focused($focusedIntent, equals: mode) + .accessibilityLabel(title) + .accessibilityHint(subtitle) + .accessibilityInputLabels([title]) + .accessibilityIdentifier(mode == .automatic ? "tour.mode.automatic" : "tour.mode.manual") + } +} diff --git a/Sources/ParcelUI/Tour/TourWindowChrome.swift b/Sources/ParcelUI/Tour/TourWindowChrome.swift new file mode 100644 index 00000000..281ce455 --- /dev/null +++ b/Sources/ParcelUI/Tour/TourWindowChrome.swift @@ -0,0 +1,20 @@ +import SwiftUI + +struct TourWindowChrome: ViewModifier { + let setupWindow: Bool + let contrast: ColorSchemeContrast + + @ViewBuilder + func body(content: Content) -> some View { + if setupWindow { + content + } else { + content + .overlay( + RoundedRectangle(cornerRadius: 12) + .stroke(.primary, lineWidth: contrast == .increased ? 2 : 1) + ) + .clipShape(RoundedRectangle(cornerRadius: 12)) + } + } +} diff --git a/Sources/ParcelUI/Tour/WindowLearningController.swift b/Sources/ParcelUI/Tour/WindowLearningController.swift index ae9f23e2..f4efa1a5 100644 --- a/Sources/ParcelUI/Tour/WindowLearningController.swift +++ b/Sources/ParcelUI/Tour/WindowLearningController.swift @@ -121,6 +121,7 @@ public final class WindowLearningController { public private(set) var configuration = ParcelConfiguration.defaults public private(set) var active = false private let defaults: UserDefaults + let navigationShortcuts: TourNavigationShortcuts private let progressStore: TourSetupProgressStore private var previousApplication: NSRunningApplication? private var previousWindow: UInt32? @@ -156,6 +157,7 @@ public final class WindowLearningController { ) throws { self.requestKeyboardFocus = requestKeyboardFocus self.defaults = defaults + navigationShortcuts = try TourNavigationShortcuts(defaults: defaults) failure = onFailure let store = TourSetupProgressStore(defaults: defaults) progressStore = store diff --git a/Tests/ParcelUITests/PseudoLocalizationScreenshotTests.swift b/Tests/ParcelUITests/PseudoLocalizationScreenshotTests.swift index f0a14ea2..012d9f08 100644 --- a/Tests/ParcelUITests/PseudoLocalizationScreenshotTests.swift +++ b/Tests/ParcelUITests/PseudoLocalizationScreenshotTests.swift @@ -44,7 +44,7 @@ extension AppKitTestSuite { } nonisolated private static let localizationLanguages: Set = [ - "es", "fr", "de", "ja", "zh-Hans", "ko", "pt-BR", + "en", "es", "fr", "de", "ja", "zh-Hans", "ko", "pt-BR", ] nonisolated private static func captureEnabled(environment: [String: String]) -> Bool { @@ -72,7 +72,10 @@ extension AppKitTestSuite { } // Run alone with the requested locale resources copied into the host bundle. - @Test(.enabled(if: Self.captureEnabled(environment: ProcessInfo.processInfo.environment))) + @Test( + .enabled( + if: Self.captureEnabled(environment: ProcessInfo.processInfo.environment) + && ProcessInfo.processInfo.environment["PARCEL_LOCALIZATION_SCREENSHOT_SURFACE"] != "steps")) func nativeSettingsMenuAndTourScreenshots() async throws { let environment = ProcessInfo.processInfo.environment let language = try #require(Self.captureLanguage(environment: environment)) @@ -83,7 +86,7 @@ extension AppKitTestSuite { defer { UserDefaults.standard.setVolatileDomain(originalArguments, forName: UserDefaults.argumentDomain) } let isPseudo = language == "en-XA" let surface = environment["PARCEL_LOCALIZATION_SCREENSHOT_SURFACE"] ?? "all" - try #require(["all", "settings", "menu", "tour"].contains(surface)) + try #require(["all", "settings", "menu", "tour", "welcome"].contains(surface)) try requireUnlockedConsole() let path = try #require(Self.captureOutput(environment: environment)) try #require(path.hasPrefix("/"), "Screenshot output must be an absolute private directory.") @@ -115,7 +118,7 @@ extension AppKitTestSuite { try #require( sample.value.hasPrefix("⟦") && sample.value.hasSuffix("⟧"), "Pseudo lookup failed or a bundle was accessed before AppleLanguages was set: \(sample.value)") - } else { + } else if language != "en" { try #require( sample.value != sample.key, "The \(language) resource lookup returned its English source: \(sample.key)") @@ -149,7 +152,7 @@ extension AppKitTestSuite { if surface == "all" || surface == "menu" { try captureMenus(scheme: scheme, output: output) } - if surface == "tour" { + if surface == "tour" || surface == "welcome" { for track in TourTrack.allCases.prefix(1) { try await captureTour(track: track, scheme: scheme, output: output) } @@ -223,6 +226,8 @@ extension AppKitTestSuite { } private func requireUnlockedConsole() throws { + try #require( + FileManager.default.fileExists(atPath: "/tmp/parcel-m3-free"), "The QA screen must be available.") try #require( NativeHostAvailability.unavailableReason == nil, "Native screenshot work requires Scripts/screen-lock.sh and an unlocked console.") @@ -320,24 +325,28 @@ extension AppKitTestSuite { permissionStatus: { permission }) let intent: TourStartIntent = track == .keyboard ? .automatic : .manual setup.begin(progress: TourSetupProgress(intent: intent), defaultOpenAtLogin: true) - for step in TourSetupStep.screens { + let welcomeOnly = ProcessInfo.processInfo.environment["PARCEL_LOCALIZATION_SCREENSHOT_SURFACE"] == "welcome" + for step in welcomeOnly ? [.welcome] : TourSetupStep.screens { if step == .ready { permission = .granted; try await setup.refreshPermission() } if step != .welcome { try await setup.next() } try #require(setup.step == step) let name = "tour-setup-\(step.rawValue)-\(intent.rawValue)-\(appearance(scheme))" - let identifiers = [ - "tour.title", step == .ready && intent == .automatic ? "tour.tidy" : "tour.continue", - ] + let identifiers = + step == .welcome + ? ["tour.title", "tour.mode.automatic", "tour.mode.manual", "tour.defer"] + : ["tour.title", step == .ready && intent == .automatic ? "tour.tidy" : "tour.continue"] try await capture( - TourView(controller: learning).frame(width: 600, height: 520), scheme: scheme, name: name, - output: output, - requiredIdentifiers: identifiers) + TourView(controller: learning), size: CGSize(width: 600, height: 520), contentSized: false, + scheme: scheme, name: name, output: output, + requiredIdentifiers: identifiers, tourChrome: true) try await capture( - TourView(controller: learning).frame(width: 600, height: 800), scheme: scheme, - typeSize: .accessibility3, - name: name + "-ax3", output: output, requiredIdentifiers: identifiers) + TourView(controller: learning), size: CGSize(width: 600, height: step == .welcome ? 520 : 800), + contentSized: false, scheme: scheme, + typeSize: .accessibility5, + name: name + "-ax5", output: output, requiredIdentifiers: identifiers, tourChrome: true) } #expect(tidyCalls == 0) + if welcomeOnly { return } try await setup.startSetup() #expect(tidyCalls == 1, "Only the independent test action should have been called.") setup.dismiss() @@ -426,10 +435,10 @@ extension AppKitTestSuite { } } - private func capture( + func capture( _ view: Content, size: CGSize = CGSize(width: 440, height: 1), contentSized: Bool = true, scheme: ColorScheme, typeSize: DynamicTypeSize = .large, name: String, output: URL, - requiredIdentifiers: [String] = [], allowsVerticalScrolling: Bool = false + requiredIdentifiers: [String] = [], allowsVerticalScrolling: Bool = false, tourChrome: Bool = false ) async throws { try requireUnlockedConsole() let language = Self.captureLanguage(environment: ProcessInfo.processInfo.environment) ?? "en-XA" @@ -449,9 +458,16 @@ extension AppKitTestSuite { host.bounds.height < (typeSize.isAccessibilitySize ? 1600 : 1000), "\(name): expanded text makes the panel impractically tall.") } - let window = NSWindow( - contentRect: CGRect(origin: CGPoint(x: 100, y: 100), size: host.frame.size), - styleMask: [.titled], backing: .buffered, defer: false) + let window: NSWindow + if tourChrome { + window = LearningPanel(title: UIStrings.text("Guided Tour"), interactive: true, setupWindow: true) + window.setContentSize(host.frame.size) + window.setFrameOrigin(CGPoint(x: 100, y: 100)) + } else { + window = NSWindow( + contentRect: CGRect(origin: CGPoint(x: 100, y: 100), size: host.frame.size), + styleMask: [.titled], backing: .buffered, defer: false) + } window.isReleasedWhenClosed = false window.contentView = host defer { @@ -461,9 +477,15 @@ extension AppKitTestSuite { window.orderFront(nil) host.layoutSubtreeIfNeeded() window.displayIfNeeded() - await Task.yield() - host.layoutSubtreeIfNeeded() - window.displayIfNeeded() + try await waitForUI("Owned capture has rendered its required controls") { + host.layoutSubtreeIfNeeded() + window.displayIfNeeded() + let elements = SettingsAccessibilityElement(object: host).descendants() + return window.isVisible && !host.bounds.isEmpty + && requiredIdentifiers.allSatisfy { id in + elements.contains { $0.accessibilityIdentifier() == id } + } + } let image = try await windowImage(host) try save( host, name: name, output: output, requiredIdentifiers: requiredIdentifiers, diff --git a/Tests/ParcelUITests/Tour/TourNavigationShortcutsTests.swift b/Tests/ParcelUITests/Tour/TourNavigationShortcutsTests.swift new file mode 100644 index 00000000..09f95cef --- /dev/null +++ b/Tests/ParcelUITests/Tour/TourNavigationShortcutsTests.swift @@ -0,0 +1,59 @@ +import Foundation +import ParcelConfig +import Testing + +@testable import ParcelUI + +extension TourSetupTests { + @Test func backUsesTheNativeCommandBracketDefault() throws { + let suite = "tour-back.\(UUID())" + let defaults = try #require(UserDefaults(suiteName: suite)) + defer { defaults.removePersistentDomain(forName: suite) } + let shortcuts = try TourNavigationShortcuts(defaults: defaults) + #expect(shortcuts.back == KeyChord(modifiers: .cmd, key: .leftBracket)) + #expect(shortcuts.backShortcut.keyEquivalent == "[") + #expect(shortcuts.backShortcut.modifierMask == .command) + } + + @Test(arguments: ["none", "ctrl-alt-left", "shift-cmd-b", "fn-f4"]) + func backCanBeDisabledOrRemappedInTheOwnedPreferenceSuite(value: String) throws { + let suite = "tour-back-custom.\(UUID())" + let defaults = try #require(UserDefaults(suiteName: suite)) + defer { defaults.removePersistentDomain(forName: suite) } + defaults.set(value, forKey: TourNavigationShortcuts.backPreferenceKey) + let controller = try WindowLearningController(defaults: defaults, onFailure: { Issue.record($0) }) + defer { controller.stop() } + if value == "none" { + #expect(controller.navigationShortcuts.back == nil) + #expect(controller.navigationShortcuts.backShortcut.keyEquivalent.isEmpty) + #expect(controller.navigationShortcuts.backShortcut.modifierMask.isEmpty) + } else { + let chord = try KeyChord(parsing: value) + let native = MenuShortcut(chord) + let shortcuts = controller.navigationShortcuts + #expect(shortcuts.back == chord) + #expect(shortcuts.backShortcut.keyEquivalent == native.keyEquivalent) + #expect(shortcuts.backShortcut.modifierMask == native.modifierMask) + } + } + + @Test(arguments: ["not-a-shortcut", "", "cmd-cmd-["]) + func malformedBackBindingsFailRatherThanRestoringDefaults(value: String) throws { + let suite = "tour-back-invalid.\(UUID())" + let defaults = try #require(UserDefaults(suiteName: suite)) + defer { defaults.removePersistentDomain(forName: suite) } + defaults.set(value, forKey: TourNavigationShortcuts.backPreferenceKey) + #expect(throws: KeyChordParseError.self) { + try WindowLearningController(defaults: defaults, onFailure: { Issue.record($0) }) + } + #expect(defaults.string(forKey: TourNavigationShortcuts.backPreferenceKey) == value) + } + + @Test func wrongTypedBackPreferenceFailsWithoutCoercion() throws { + let suite = "tour-back-type.\(UUID())" + let defaults = try #require(UserDefaults(suiteName: suite)) + defer { defaults.removePersistentDomain(forName: suite) } + defaults.set(42, forKey: TourNavigationShortcuts.backPreferenceKey) + #expect(throws: TourNavigationPreferenceError.self) { try TourNavigationShortcuts(defaults: defaults) } + } +} diff --git a/Tests/ParcelUITests/Tour/TourSetupTests.swift b/Tests/ParcelUITests/Tour/TourSetupTests.swift index 2cea6786..07bb8dbe 100644 --- a/Tests/ParcelUITests/Tour/TourSetupTests.swift +++ b/Tests/ParcelUITests/Tour/TourSetupTests.swift @@ -121,6 +121,73 @@ struct TourSetupTests { #expect(fixture.saved.last?.step == .welcome) } + @Test(arguments: TourStartIntent.allCases) + func welcomeChoiceSavesIntentAndAllowTogetherBeforeCheckingAccess(intent: TourStartIntent) async throws { + let fixture = TourSetupFixture() + let setup = fixture.controller + setup.begin(progress: .init(intent: intent == .automatic ? .manual : .automatic, demoPaused: true)) + try await setup.chooseMode(intent) + #expect(setup.step == .allow) + #expect(setup.intent == intent) + #expect(fixture.saved.first?.step == .allow) + #expect(fixture.saved.first?.intent == intent) + #expect(fixture.permissionChecks == 1) + #expect(fixture.starts.isEmpty) + #expect(fixture.loginWrites.isEmpty) + try await setup.back() + #expect(setup.step == .welcome) + #expect(setup.intent == intent) + let opposite: TourStartIntent = intent == .automatic ? .manual : .automatic + try await setup.chooseMode(opposite) + #expect(setup.step == .allow) + #expect(setup.intent == opposite) + #expect(fixture.saved.last?.intent == opposite) + #expect(fixture.starts.isEmpty) + } + + @Test(arguments: TourStartIntent.allCases) + func welcomeChoiceCannotNavigateOrCheckAccessWhenPersistenceFails(intent: TourStartIntent) async throws { + let fixture = TourSetupFixture() + let setup = fixture.controller + setup.begin() + let original = setup.progress + fixture.failSave = true + await #expect(throws: TourProgressFailure.self) { try await setup.chooseMode(intent) } + #expect(setup.progress == original) + #expect(setup.step == .welcome) + #expect(fixture.saved.isEmpty) + #expect(fixture.permissionChecks == 0) + #expect(fixture.starts.isEmpty) + fixture.failSave = false + try await setup.chooseMode(intent) + #expect(setup.step == .allow) + #expect(setup.intent == intent) + } + + @Test func cancelledWelcomeChoiceCannotChangeTheDraft() async { + let fixture = TourSetupFixture() + fixture.controller.begin() + let operation = Task { @MainActor in + withUnsafeCurrentTask { $0?.cancel() } + try await fixture.controller.chooseMode(.manual) + } + await #expect(throws: CancellationError.self) { try await operation.value } + #expect(fixture.controller.step == .welcome) + #expect(fixture.controller.intent == .automatic) + #expect(fixture.saved.isEmpty) + #expect(fixture.permissionChecks == 0) + } + + @Test(arguments: TourStartIntent.allCases, [TourSetupStep.allow, .ready]) + func modeChoiceRejectsAnyScreenOtherThanWelcome(intent: TourStartIntent, step: TourSetupStep) async { + let fixture = TourSetupFixture() + fixture.controller.begin(progress: .init(step: step)) + await #expect(throws: TourSetupFailure.self) { try await fixture.controller.chooseMode(intent) } + #expect(fixture.controller.step == step) + #expect(fixture.saved.isEmpty) + #expect(fixture.starts.isEmpty) + } + @Test(arguments: TourStartIntent.allCases, [PermissionStatus.checking, .missing, .granted]) func permissionUpdatesInPlaceAndRequiresExplicitContinue(intent: TourStartIntent, permission: PermissionStatus) async throws diff --git a/Tests/ParcelUITests/Tour/TourWelcomeRenderingTests.swift b/Tests/ParcelUITests/Tour/TourWelcomeRenderingTests.swift new file mode 100644 index 00000000..7e88cc6f --- /dev/null +++ b/Tests/ParcelUITests/Tour/TourWelcomeRenderingTests.swift @@ -0,0 +1,112 @@ +import AppKit +import ParcelConfig +import SwiftUI +import Testing + +@testable import ParcelUI + +extension AppKitTestSuite.TourSetupRenderingTests { + @Test( + arguments: [ + (ColorScheme.light, DynamicTypeSize.large), (.dark, .large), + (.light, .accessibility5), (.dark, .accessibility5), + ], TourStartIntent.allCases) + func welcomeHasEqualVisibleChoicesWithoutScrolling( + appearance: (ColorScheme, DynamicTypeSize), intent: TourStartIntent + ) async throws { + try #require(FileManager.default.fileExists(atPath: "/tmp/parcel-m3-free")) + let suite = "tour-welcome-render.\(UUID())" + let defaults = try #require(UserDefaults(suiteName: suite)) + defer { defaults.removePersistentDomain(forName: suite) } + let controller = try WindowLearningController(defaults: defaults, onFailure: { Issue.record($0) }) + defer { controller.stop() } + var starts = 0 + controller.setup.actions = TourSetupActions( + checkShortcuts: { .init(warnings: []) }, + checkSystem: { .init(stageManager: false, nativeTiling: false) }, + loginStatus: { .disabled }, setOpenAtLogin: { $0 ? .enabled : .disabled }, + checkReady: { _ in .ready }, + start: { _, _ in + starts += 1; return .success + }, + deferSetup: {}, openShortcuts: {}, openSystemSettings: {}, openLoginSettings: {}, + permissionStatus: { .missing }) + controller.setup.begin(progress: .init(intent: intent, demoPaused: true)) + let host = NSHostingView( + rootView: TourView(controller: controller) + .environment(\.colorScheme, appearance.0).environment(\.dynamicTypeSize, appearance.1)) + let window = LearningPanel(title: "Welcome fixture", interactive: true, setupWindow: true) + window.setContentSize(CGSize(width: 600, height: 520)) + window.isRestorable = false + window.contentView = host + defer { window.contentView = nil; window.close() } + window.makeKeyAndOrderFront(nil) + try await waitForUI("Welcome renders both native choice buttons") { + host.layoutSubtreeIfNeeded() + window.displayIfNeeded() + let nodes = SettingsAccessibilityElement(object: host).descendants() + return ["tour.mode.automatic", "tour.mode.manual"].allSatisfy { id in + nodes.contains { $0.accessibilityIdentifier() == id && $0.accessibilityRole() == .button } + } + } + let root = SettingsAccessibilityElement(object: host) + let nodes = root.descendants() + #expect(!nodes.contains { $0.accessibilityRole() == .scrollArea }) + #expect( + !nodes.contains { + ["tour.demo.playback", "tour.mode.disclosure", "tour.continue"].contains( + $0.accessibilityIdentifier() ?? "") + }) + let auto = try #require(nodes.first { $0.accessibilityIdentifier() == "tour.mode.automatic" }) + let manual = try #require(nodes.first { $0.accessibilityIdentifier() == "tour.mode.manual" }) + let autoFrame = try welcomeFrame(auto) + let manualFrame = try welcomeFrame(manual) + #expect(abs(autoFrame.width - manualFrame.width) < 1) + #expect(abs(autoFrame.height - manualFrame.height) < 1) + #expect(window.frame.contains(autoFrame)) + #expect(window.frame.contains(manualFrame)) + #expect(autoFrame.height >= 56) + #expect(root.descendants(navigation: true).contains { $0.isEqual(auto) }) + #expect(root.descendants(navigation: true).contains { $0.isEqual(manual) }) + #expect(window.styleMask.contains(.fullSizeContentView)) + #expect(window.titleVisibility == .hidden) + #expect(window.standardWindowButton(.closeButton) != nil) + let bitmap = try #require(host.bitmapImageRepForCachingDisplay(in: host.bounds)) + host.cacheDisplay(in: host.bounds, to: bitmap) + #expect(bitmap.tiffRepresentation?.isEmpty == false) + let button = intent == .automatic ? auto : manual + let press = NSSelectorFromString("accessibilityPerformPress") + try #require(button.object.responds(to: press)) + _ = button.object.perform(press) + try await waitForUI("Choosing a mode advances to Allow") { controller.setup.step == .allow } + #expect(controller.setup.intent == intent) + #expect(try TourSetupProgressStore(defaults: defaults).load()?.intent == intent) + try await waitForUI("Allow exposes the circular Back control") { + host.layoutSubtreeIfNeeded() + return SettingsAccessibilityElement(object: host).descendants().contains { + $0.accessibilityIdentifier() == "tour.back" && $0.accessibilityRole() == .button + } + } + let back = try #require( + SettingsAccessibilityElement(object: host).descendants().first { + $0.accessibilityIdentifier() == "tour.back" + }) + #expect(back.accessibilityLabel() == TourText.text("Back")) + let event = try #require( + NSEvent.keyEvent( + with: .keyDown, location: .zero, modifierFlags: .command, timestamp: 0, + windowNumber: window.windowNumber, context: nil, characters: "[", charactersIgnoringModifiers: "[", + isARepeat: false, keyCode: 33)) + #expect(window.performKeyEquivalent(with: event)) + try await waitForUI("Command-bracket returns to Welcome") { controller.setup.step == .welcome } + #expect(controller.setup.intent == intent) + #expect(starts == 0) + } + + private func welcomeFrame(_ element: SettingsAccessibilityElement) throws -> CGRect { + try #require(element.object.responds(to: NSSelectorFromString("accessibilityFrame"))) + let frame = try #require(element.object.value(forKey: "accessibilityFrame") as? NSValue).rectValue + try #require(!frame.isEmpty) + return frame + } +} diff --git a/Tests/Reality/TourNativeAcceptance.swift b/Tests/Reality/TourNativeAcceptance.swift index a621ab99..08b7202f 100644 --- a/Tests/Reality/TourNativeAcceptance.swift +++ b/Tests/Reality/TourNativeAcceptance.swift @@ -32,7 +32,7 @@ private func nativeTourAction(_ session: RealitySession, _ arguments: String...) func pressNativeTour(_ session: RealitySession, _ control: DriverTourControl) async throws { let deadline = ContinuousClock.now.advanced(by: .seconds(5)) var status = try await nativeTourStatus(session) - let needsReady = control == .continue || control == .tidy + let needsReady = control == .continue || control == .tidy || control == .automatic || control == .manual while (needsReady && !status.canContinue && (status.terminal == nil || status.terminal == "none") || status.visibleTourWindowNumber == nil), ContinuousClock.now < deadline @@ -116,14 +116,14 @@ func checkNativeTourAutomatic( } } try await captureNativeTour(session, stage: "welcome") - try await pressNativeTour(session, .continue) + try await pressNativeTour(session, .automatic) try await waitNativeTour(session, step: "allow") try await requireNativeTourHold(session, owned: owned, original: original) try await captureNativeTour(session, stage: "allow") try await pressNativeTour(session, .back) try await waitNativeTour(session, step: "welcome") try await requireNativeTourHold(session, owned: owned, original: original) - try await pressNativeTour(session, .continue) + try await pressNativeTour(session, .automatic) try await waitNativeTour(session, step: "allow") try await pressNativeTour(session, .continue) try await waitNativeTour(session, step: "ready") @@ -172,18 +172,16 @@ func checkNativeTourManual(_ session: RealitySession) async throws { let hooks = try RealityRecoveryHooks(kind: .tourRollback, token: UUID().uuidString) try await session.start(recoveryHooks: hooks, firstRun: true) try await waitNativeTour(session, step: "welcome") - try await pressNativeTour(session, .modeDisclosure) - try await session.expect("Native mode disclosure preserves real frames") { - try TourFirstRunOracle.unchanged($0, owned: owned, original: original) - } + try await captureNativeTour(session, stage: "manual-welcome") try await pressNativeTour(session, .manual) + try await waitNativeTour(session, step: "allow") let mode = try await nativeTourStatus(session) - guard mode.intent == "manual" else { throw RealityError("Native radio did not select the Manual draft") } + guard mode.intent == "manual" else { throw RealityError("Native button did not select the Manual draft") } try await session.expect("Native Manual selection preserves real frames") { try TourFirstRunOracle.unchanged($0, owned: owned, original: original) } - try await captureNativeTour(session, stage: "manual-welcome") - for step in ["allow", "ready"] { + try await captureNativeTour(session, stage: "manual-allow") + for step in ["ready"] { try await pressNativeTour(session, .continue) try await waitNativeTour(session, step: step) try await requireNativeTourHold(session, owned: owned, original: original) diff --git a/Tests/RealityDriverSupport/DriverProtocol.swift b/Tests/RealityDriverSupport/DriverProtocol.swift index 4c115be6..a9a85370 100644 --- a/Tests/RealityDriverSupport/DriverProtocol.swift +++ b/Tests/RealityDriverSupport/DriverProtocol.swift @@ -87,15 +87,13 @@ public enum DriverTourControl: String, Codable, Sendable, CaseIterable { case `defer` = "tour.defer" case readyRetry = "tour.ready.retry" case shortcutsEdit = "tour.shortcuts.edit" - case modeDisclosure = "tour.mode.disclosure" case automatic = "tour.mode.automatic" case manual = "tour.mode.manual" case referenceDisclosure = "tour.reference.disclosure" public var role: String { switch self { - case .manual, .automatic: "AXRadioButton" - case .modeDisclosure, .referenceDisclosure: "AXDisclosureTriangle" + case .referenceDisclosure: "AXDisclosureTriangle" default: "AXButton" } }