Оптимизируйте свои подборки
Сохраняйте и классифицируйте контент в соответствии со своими настройками.
В некоторых ситуациях вам может быть удобнее, чтобы пользователи взаимодействовали с вашим продуктом вне iframe. Вы можете загружать вложенный контент в новую вкладку, а не в iframe надстройки Classroom, при условии, что ваша надстройка соответствует следующим правилам.
Требуемое поведение в новых вкладках или окнах
Контрольный список требований к надстройке «Класс» определяет определённые правила поведения при открытии новых вкладок или окон. В следующей таблице приведены пояснения и рекомендации по реализации каждого требования.
ИДЕНТИФИКАТОР
Требование
Как познакомиться
3.2
Если задача запускается в новой вкладке или окне из любого пути iframe, она ДОЛЖНА предоставлять удобное для пользователя сообщение о необходимости вернуться в Classroom.
На внешнем сайте разместите сообщение, баннер, тост или другое уведомление с инструкцией пользователю вернуться в Classroom после завершения задачи.
5.1
При запуске studentViewUri дополнение НЕ ДОЛЖНО выводить пользователя из iframe для выполнения задачи.
В идеале пользователи должны иметь возможность совершать все необходимые действия в iframe. Открытие новых вкладок может дезориентировать пользователей и усложнить использование дополнения. Оставьте пользовательский интерфейс в iframe, чтобы минимизировать неудобства для пользователя.
5.2
Если действие надстройки выводится из iframe, в iframe ОБЯЗАТЕЛЬНО должен быть предварительный просмотр задачи.
Не открывайте внешний сайт сразу после того, как пользователь нажмёт на карточку вложения. Вместо этого разместите в iframe простое промежуточное представление с изображением или описанием задачи, которое откроется в новой вкладке. Добавьте инструкции, которые помогут пользователям успешно сориентироваться и выполнить задание.
[null,null,["Последнее обновление: 2025-08-29 UTC."],[],[],null,["# Open content in new tabs\n\nThere may be some situations in which you would prefer users interact with your\nproduct outside of an iframe. You can load attachment content in a new tab\nrather than in a Classroom add-on iframe as long as your\nadd-on conforms to the following guidelines.\n| **Important:** You should adapt your content to work within the iframes if possible. Ease of access and reduced time and effort to reach content are two key benefits of building a Classroom add-on.\n\nRequired behaviors in new tabs or windows\n-----------------------------------------\n\nThe Classroom add-on [requirements checklist](/workspace/classroom/add-ons/requirements) specifies certain\nbehaviors when opening new tabs or windows. The following table provides\nclarifications and implementation suggestions regarding each requirement.\n\n| ID | Requirement | How to meet |\n|-----|-------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| 3.2 | If a task is launched into a new tab or window from any of the iframe journeys, it MUST provide a user-friendly message to return to Classroom. | On the external site, include a message, banner, toast, or other notification instructing the user to return to Classroom when finished with the task. |\n| 5.1 | When the `studentViewUri` is launched, the add-on SHOULD NOT pop the user out of the iframe to complete a task. | Ideally, users are able to complete all relevant journeys within the iframe. Opening new tabs can disorient users and adds to the complexity of using the add-on. Keep the user experience within the iframe to provide the least user friction. |\n| 5.2 | If the add-on activity pops out of the iframe there MUST be a preview about the task in the iframe. | Don't open the external site immediately when the user clicks the attachment card. Instead, provide a basic interstitial view in the iframe showing an image or description of the task that opens in a new tab. Include instructions to help users successfully navigate and complete the activity. |"]]