* 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.9 KiB
PHP
140 lines
7.9 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' => 'Публикуйте изображения, карусели, истории и Reels. Для каждой платформы автоматически подбирается нужный формат.',
|
||
],
|
||
'video' => [
|
||
'title' => 'Публикация видео',
|
||
'description' => 'Загрузите видео один раз и публикуйте в TikTok, YouTube Shorts, Instagram Reels и Facebook Reels.',
|
||
],
|
||
'team' => [
|
||
'title' => 'Командные пространства',
|
||
'description' => 'Приглашайте команду, назначайте роли и управляйте несколькими брендами из отдельных рабочих пространств.',
|
||
],
|
||
'signatures' => [
|
||
'title' => 'Подписи',
|
||
'description' => 'Сохраняйте многократно используемые подписи (хэштеги, ссылки, завершающие фразы) и добавляйте их к постам в один клик.',
|
||
],
|
||
],
|
||
|
||
'or_continue_with' => 'Или продолжите через',
|
||
'or_continue_with_email' => 'Или продолжите через email',
|
||
'google_login' => 'Войти через Google',
|
||
'google_signup' => 'Зарегистрироваться через Google',
|
||
'github_login' => 'Войти через GitHub',
|
||
'github_signup' => 'Зарегистрироваться через GitHub',
|
||
'github_email_unavailable' => 'Не удалось получить ваш email из GitHub. Сделайте email в GitHub публичным или предоставьте доступ к email, затем попробуйте снова.',
|
||
|
||
'login' => [
|
||
'title' => 'Войдите в свой аккаунт',
|
||
'description' => 'Введите email и пароль, чтобы войти',
|
||
'page_title' => 'Вход',
|
||
'email' => 'Адрес email',
|
||
'password' => 'Пароль',
|
||
'show_password' => 'Показать пароль',
|
||
'hide_password' => 'Скрыть пароль',
|
||
'forgot_password' => 'Забыли пароль?',
|
||
'remember_me' => 'Запомнить меня',
|
||
'submit' => 'Войти',
|
||
'no_account' => 'Нет аккаунта?',
|
||
'sign_up' => 'Зарегистрироваться',
|
||
],
|
||
|
||
'register' => [
|
||
'title' => 'Весь ваш контент-календарь в одном месте',
|
||
'description' => 'Создайте аккаунт и начните планировать посты во всех сетях.',
|
||
'page_title' => 'Регистрация',
|
||
'signup_with_email' => 'Зарегистрироваться через email',
|
||
'name' => 'Имя',
|
||
'name_placeholder' => 'Полное имя',
|
||
'email' => 'Адрес email',
|
||
'password' => 'Пароль',
|
||
'show_password' => 'Показать пароль',
|
||
'hide_password' => 'Скрыть пароль',
|
||
'submit' => 'Создать аккаунт',
|
||
'has_account' => 'Уже есть аккаунт?',
|
||
'log_in' => 'Войти',
|
||
],
|
||
|
||
'forgot_password' => [
|
||
'title' => 'Восстановление пароля',
|
||
'description' => 'Введите email, чтобы получить ссылку для сброса пароля',
|
||
'page_title' => 'Восстановление пароля',
|
||
'email' => 'Адрес email',
|
||
'submit' => 'Отправить ссылку для сброса',
|
||
'return_to' => 'Или вернитесь ко',
|
||
'log_in' => 'входу',
|
||
],
|
||
|
||
'reset_password' => [
|
||
'title' => 'Сброс пароля',
|
||
'description' => 'Введите новый пароль ниже',
|
||
'page_title' => 'Сброс пароля',
|
||
'email' => 'Email',
|
||
'password' => 'Пароль',
|
||
'confirm_password' => 'Подтвердите пароль',
|
||
'confirm_placeholder' => 'Подтвердите пароль',
|
||
'submit' => 'Сбросить пароль',
|
||
],
|
||
|
||
'verify_email' => [
|
||
'title' => 'Подтверждение email',
|
||
'description' => 'Пожалуйста, подтвердите свой email, перейдя по ссылке, которую мы только что вам отправили.',
|
||
'page_title' => 'Подтверждение email',
|
||
'link_sent' => 'Новая ссылка для подтверждения отправлена на email, указанный при регистрации.',
|
||
'resend' => 'Отправить письмо повторно',
|
||
'log_out' => 'Выйти',
|
||
],
|
||
|
||
'accept_invite' => [
|
||
'page_title' => 'Принять приглашение',
|
||
'title' => 'Вас пригласили!',
|
||
'description' => 'Вас пригласили присоединиться к рабочему пространству :workspace.',
|
||
'workspace' => 'Рабочее пространство',
|
||
'your_role' => 'Ваша роль',
|
||
'email' => 'Email',
|
||
'accept' => 'Принять приглашение',
|
||
'decline' => 'Отклонить приглашение',
|
||
'login_prompt' => 'Войдите или создайте аккаунт, чтобы принять приглашение.',
|
||
'log_in' => 'Войти',
|
||
'create_account' => 'Создать аккаунт',
|
||
'expired_title' => 'Это приглашение больше недействительно',
|
||
'expired_description' => 'Рабочее пространство для этого приглашения было удалено. Попросите владельца аккаунта прислать новое приглашение, если доступ всё ещё нужен.',
|
||
'expired_action' => 'На главную',
|
||
],
|
||
|
||
];
|