* feat: visible Terms/Privacy links on the auth screens Social-platform app reviews (TikTok explicitly) require both links to be reachable from the public site without logging in or opening a menu. * Cover the legal links with tests and tidy the layout The links are a compliance artifact an outside reviewer checks, but nothing asserted they exist. A refactor of this layout could drop the footer silently and the next platform submission would fail the same check that prompted the PR. A feature test asserts the shared prop reaches both guest screens and carries whatever the install configured, and a browser test asserts the two links actually render to a logged-out visitor. Declares legal on SharedData, so the props read through the interface rather than its index signature and the inline cast goes away. Adds rel="noopener noreferrer" to both anchors, matching every other target="_blank" in the codebase, and orders the imports the way eslint expects so the file lands clean rather than relying on --fix in CI. Drops the comment explaining why the links are there: that rationale belongs in the commit and the pull request, and the sibling comments in this file describe markup rather than justify decisions. * Reuse the legal sentence the register screen already had The register screen has shown "By continuing, you agree to our Terms of Service and Privacy Policy" in production for a long time, translated into all sixteen locales. Only the login screen was missing it, and the two URLs were hardcoded inside the translated string, so a self-hosted install could not point them at its own documents. So this keeps what already worked and changes only those two things. The markup moves into one component, which the login screen now renders as well. The translated sentence keeps its wording and its link labels; only the href becomes an i18n placeholder that the component fills from config. That is one line per locale, and no new translation keys. Reverting the footer out of AuthSplitLayout also stops the links from appearing on the workspace index and create screens, which reach that layout too and are seen after login rather than before it. The sentence no longer hides on a self-hosted install. It was hidden because it named TryPost's own documents; now that the URLs are configuration, an install that sets them wants it shown. A feature test covers the shared prop on both screens and the placeholder in every locale; a browser test covers the rendered sentence, since the links are a compliance artifact an outside reviewer checks and nothing guarded them. * Let the browser assertions do their own waiting The test hand-rolled a polling loop in injected JavaScript to wait for the element to mount, because the project notes say browser assertions do not wait for SPA paint. They do. visit() returns a PendingAwaitablePage backed by AwaitableWebpage, whose __call wraps every method in Execution::waitForExpectation and retries until the Playwright timeout, which defaults to five seconds. The plugin even deprecates waitForText in favour of assertSee for this reason. The loop was re-implementing the retry that already surrounded each call, less well and with a helper whose name has to be unique across the whole suite because these are global functions. Halves the file and drops the injected script. assertSeeLink also says more than the old check did: it asserts the labels are links, not just text that happens to appear. --------- Co-authored-by: Paulo Castellano <paulo@castellanos.llc>
140 lines
7.6 KiB
PHP
140 lines
7.6 KiB
PHP
<?php
|
|
|
|
return [
|
|
|
|
/*
|
|
|--------------------------------------------------------------------------
|
|
| Authentication Language Lines
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
| The following language lines are used during authentication for various
|
|
| messages that we need to display to the user. You are free to modify
|
|
| these language lines according to your application's requirements.
|
|
|
|
|
*/
|
|
|
|
'failed' => 'بيانات الاعتماد هذه لا تطابق سجلاتنا.',
|
|
'password' => 'كلمة المرور المُدخلة غير صحيحة.',
|
|
'throttle' => 'عدد كبير جدًا من محاولات تسجيل الدخول. يرجى المحاولة مرة أخرى بعد :seconds ثانية.',
|
|
|
|
'flash' => [
|
|
'welcome' => 'مرحبًا بك في TryPost!',
|
|
'welcome_trial' => 'مرحبًا بك في TryPost! لقد بدأت فترتك التجريبية.',
|
|
],
|
|
|
|
'legal' => 'بمتابعتك، فإنك توافق على <a href=":terms_url" target="_blank">شروط الخدمة</a> و<a href=":privacy_url" target="_blank">سياسة الخصوصية</a>.',
|
|
|
|
'slides' => [
|
|
'calendar' => [
|
|
'title' => 'تقويم مرئي',
|
|
'description' => 'خطّط لمحتواك وجدوِله باستخدام تقويم بديهي يعتمد على السحب والإفلات عبر جميع حساباتك الاجتماعية.',
|
|
],
|
|
'scheduling' => [
|
|
'title' => 'جدولة ذكية',
|
|
'description' => 'جدوِل المنشورات عبر LinkedIn وX وInstagram وTikTok وYouTube والمزيد — كل ذلك من مكان واحد.',
|
|
],
|
|
'media' => [
|
|
'title' => 'وسائط غنية',
|
|
'description' => 'انشر الصور والعروض الدائرية والقصص ومقاطع الريلز. تحصل كل منصة على التنسيق المناسب تلقائيًا.',
|
|
],
|
|
'video' => [
|
|
'title' => 'نشر الفيديو',
|
|
'description' => 'ارفع مقاطع الفيديو مرة واحدة وانشرها على TikTok وYouTube Shorts وInstagram Reels وFacebook Reels.',
|
|
],
|
|
'team' => [
|
|
'title' => 'مساحات عمل جماعية',
|
|
'description' => 'ادعُ فريقك، وعيّن الأدوار، وأدِر عدة علامات تجارية من مساحات عمل منفصلة.',
|
|
],
|
|
'signatures' => [
|
|
'title' => 'التوقيعات',
|
|
'description' => 'احفظ توقيعات قابلة لإعادة الاستخدام (وسوم، روابط، خواتيم) وأضِفها إلى المنشورات بنقرة واحدة.',
|
|
],
|
|
],
|
|
|
|
'or_continue_with' => 'أو تابع باستخدام',
|
|
'or_continue_with_email' => 'أو تابع باستخدام البريد الإلكتروني',
|
|
'google_login' => 'تسجيل الدخول عبر Google',
|
|
'google_signup' => 'التسجيل عبر Google',
|
|
'github_login' => 'تسجيل الدخول عبر GitHub',
|
|
'github_signup' => 'التسجيل عبر GitHub',
|
|
'github_email_unavailable' => 'تعذر جلب بريدك الإلكتروني من GitHub. اجعل بريدك على GitHub عامًا أو امنح نطاق الوصول إلى البريد، ثم حاول مرة أخرى.',
|
|
|
|
'login' => [
|
|
'title' => 'تسجيل الدخول إلى حسابك',
|
|
'description' => 'أدخل بريدك الإلكتروني وكلمة المرور أدناه لتسجيل الدخول',
|
|
'page_title' => 'تسجيل الدخول',
|
|
'email' => 'البريد الإلكتروني',
|
|
'password' => 'كلمة المرور',
|
|
'show_password' => 'إظهار كلمة المرور',
|
|
'hide_password' => 'إخفاء كلمة المرور',
|
|
'forgot_password' => 'نسيت كلمة المرور؟',
|
|
'remember_me' => 'تذكّرني',
|
|
'submit' => 'تسجيل الدخول',
|
|
'no_account' => 'ليس لديك حساب؟',
|
|
'sign_up' => 'إنشاء حساب',
|
|
],
|
|
|
|
'register' => [
|
|
'title' => 'تقويمك الاجتماعي بالكامل، في مكان واحد',
|
|
'description' => 'أنشئ حسابك وابدأ جدولة المنشورات عبر كل شبكة.',
|
|
'page_title' => 'التسجيل',
|
|
'signup_with_email' => 'التسجيل بالبريد الإلكتروني',
|
|
'name' => 'الاسم',
|
|
'name_placeholder' => 'الاسم الكامل',
|
|
'email' => 'البريد الإلكتروني',
|
|
'password' => 'كلمة المرور',
|
|
'show_password' => 'إظهار كلمة المرور',
|
|
'hide_password' => 'إخفاء كلمة المرور',
|
|
'submit' => 'إنشاء حساب',
|
|
'has_account' => 'هل لديك حساب بالفعل؟',
|
|
'log_in' => 'تسجيل الدخول',
|
|
],
|
|
|
|
'forgot_password' => [
|
|
'title' => 'نسيت كلمة المرور',
|
|
'description' => 'أدخل بريدك الإلكتروني لاستلام رابط إعادة تعيين كلمة المرور',
|
|
'page_title' => 'نسيت كلمة المرور',
|
|
'email' => 'البريد الإلكتروني',
|
|
'submit' => 'إرسال رابط إعادة تعيين كلمة المرور',
|
|
'return_to' => 'أو، العودة إلى',
|
|
'log_in' => 'تسجيل الدخول',
|
|
],
|
|
|
|
'reset_password' => [
|
|
'title' => 'إعادة تعيين كلمة المرور',
|
|
'description' => 'يرجى إدخال كلمة المرور الجديدة أدناه',
|
|
'page_title' => 'إعادة تعيين كلمة المرور',
|
|
'email' => 'البريد الإلكتروني',
|
|
'password' => 'كلمة المرور',
|
|
'confirm_password' => 'تأكيد كلمة المرور',
|
|
'confirm_placeholder' => 'تأكيد كلمة المرور',
|
|
'submit' => 'إعادة تعيين كلمة المرور',
|
|
],
|
|
|
|
'verify_email' => [
|
|
'title' => 'تأكيد البريد الإلكتروني',
|
|
'description' => 'يرجى تأكيد بريدك الإلكتروني بالنقر على الرابط الذي أرسلناه إليك للتو.',
|
|
'page_title' => 'تأكيد البريد الإلكتروني',
|
|
'link_sent' => 'تم إرسال رابط تأكيد جديد إلى البريد الإلكتروني الذي قدّمته أثناء التسجيل.',
|
|
'resend' => 'إعادة إرسال بريد التأكيد',
|
|
'log_out' => 'تسجيل الخروج',
|
|
],
|
|
|
|
'accept_invite' => [
|
|
'page_title' => 'قبول الدعوة',
|
|
'title' => 'لقد تمت دعوتك!',
|
|
'description' => 'لقد تمت دعوتك للانضمام إلى مساحة العمل :workspace.',
|
|
'workspace' => 'مساحة العمل',
|
|
'your_role' => 'دورك',
|
|
'email' => 'البريد الإلكتروني',
|
|
'accept' => 'قبول الدعوة',
|
|
'decline' => 'رفض الدعوة',
|
|
'login_prompt' => 'سجّل الدخول أو أنشئ حسابًا لقبول هذه الدعوة.',
|
|
'log_in' => 'تسجيل الدخول',
|
|
'create_account' => 'إنشاء حساب',
|
|
'expired_title' => 'هذه الدعوة لم تعد صالحة',
|
|
'expired_description' => 'تم حذف مساحة العمل المرتبطة بهذه الدعوة. اطلب دعوة جديدة من مالك الحساب إذا كنت لا تزال بحاجة إلى الوصول.',
|
|
'expired_action' => 'الانتقال إلى الصفحة الرئيسية',
|
|
],
|
|
|
|
];
|