{% extends 'base.html' %} {% block content %} {% from '_helpers.html' import render_field, render_checkbox_field, render_button %}

{{ _('Browser Profiles') }}

{{ _('Create named profiles to configure browser settings — viewport size, connection URL, image/font blocking, and more. Each profile is based on an available browser type.') }}

{% if browser_profiles %} {% for machine_name, profile in browser_profiles.items() %} {% endfor %}
{{ _('Default') }} {{ _('Name') }} {{ _('Type') }} {{ _('Viewport') }} {{ _('Options') }}
{{ profile.name }} {{ profile.fetch_backend }} {{ profile.get_fetcher_class_name()|fetcher_status_icons }} {{ profile.viewport_width }}×{{ profile.viewport_height }} {% if profile.block_images %}{{ _('No images') }}
{% endif %} {% if profile.block_fonts %}{{ _('No fonts') }}
{% endif %} {% if profile.ignore_https_errors %}{{ _('Ignore TLS') }}
{% endif %} {% if profile.browser_connection_url %}{{ _('Custom URL') }}{% endif %}
{% if not profile.is_builtin %} {{ _('Edit') }} {{ _('Delete') }} {% endif %}
{% else %}

{{ _('No browser profiles configured yet. Add one below.') }}

{% endif %}

{{ _('Edit browser profile') if editing_machine_name else _('Add new browser profile') }}

{% if not editing_machine_name %}

{{ _('Choose a browser type, give it a name, and configure its settings. You can create multiple profiles from the same type with different connection URLs or options.') }}

{% endif %}
{{ render_field(browser_profile_form.name) }}
{{ render_field(browser_profile_form.fetch_backend, id="profile-fetch-backend") }}
{{ render_field(browser_profile_form.browser_connection_url) }} {{ _('Optional — override the system CDP/WebSocket URL for this profile only (e.g.') }} ws://my-chrome:3000).
{{ render_field(browser_profile_form.viewport_width) }}
{{ render_field(browser_profile_form.viewport_height) }}
{{ render_checkbox_field(browser_profile_form.block_images) }} {{ _('Block image downloads — speeds up loads on image-heavy pages.') }}
{{ render_checkbox_field(browser_profile_form.block_fonts) }} {{ _('Block web font downloads.') }}
{{ render_checkbox_field(browser_profile_form.ignore_https_errors) }} {{ _('Ignore TLS/HTTPS certificate errors (useful for self-signed certs on staging sites).') }}
{{ render_field(browser_profile_form.user_agent) }} {{ _("Leave blank to use the fetcher's default User-Agent.") }}
{{ render_field(browser_profile_form.locale) }} {{ _('Sets Accept-Language and navigator.language (e.g. en-US, de-DE).') }}
{{ render_field(browser_profile_form.custom_headers) }} {{ _('Extra HTTP headers for all requests using this profile (one per line, Key: Value). Applied before per-watch headers.') }}
{% if editing_machine_name %} {{ _('Cancel') }} {% endif %} {{ _('Back to Settings') }}
{% endblock %}