{# Shared chrome. Every label, href and colour below is transcribed from the Playwright evidence snapshots listed in materials/leetcode/SOURCE_EVIDENCE.md. #} {% macro logo_mark(size=24) %} {% endmacro %} {% macro logo(word=true, href='/') %} {{ logo_mark() }} {% if word %}LeetCode{% endif %} {% endmacro %} {# Marketing header: transparent over the dark hero, no search, no member controls. Hidden below the source's own navigation breakpoint. #} {% macro marketing_header(member) %}
{{ logo_mark(30) }} LeetCode
{% if member %} {{ member.username }}
{% else %} Sign in {% endif %}
{% endmacro %} {# Application header used by /problemset, the account pages and every local boundary page. 50px tall, white, bottom hairline. #} {% macro app_header(member, active='', word=true) %}
{{ logo(word) }}
{% if member %} {{ member.username }}
{% else %} Register Log in {% endif %} Premium
{% endmacro %} {% macro us_flag() %} {% endmacro %} {# Marketing footer, from home-desktop / home-mobile. #} {% macro marketing_footer() %} {% endmacro %} {# Application footer, from login-desktop / password-reset-desktop. #} {% macro app_footer(tone='grey') %} {% endmacro %} {% macro difficulty_pill(difficulty) %} {{ difficulty|difficulty_label }} {% endmacro %} {% macro status_icon(status) %} {% if status == 'solved' %} {% elif status == 'attempted' %} {% else %} {% endif %} {% endmacro %} {# The source renders the frequency column behind a Premium lock and printed no values, so the clone renders the lock rather than inventing a bar. #} {% macro frequency_lock() %} {% endmacro %} {% macro social_row(extra=false) %}
{% if extra %}
{% endif %}
{% endmacro %} {# The source card carries a Cloudflare Turnstile widget. A third-party challenge cannot run offline, so the slot holds a local, server-verified check with the same shape and position; nothing is sent anywhere. #} {% macro verification_widget(token, checked=false) %}
LOCAL CHECK Verified in this process
{% endmacro %} {% macro field_error(errors, name) %} {% if errors and errors.get(name) %} {% endif %} {% endmacro %}