2021-12-14 22:48:37 +00:00
2021-10-15 14:08:27 +00:00
<!DOCTYPE html>
< html lang = "en" >
< head >
2021-12-29 08:40:06 +00:00
< meta name = "description" content = "{{'DESCRIPTION' | app_config}}" >
2021-12-14 22:48:37 +00:00
< meta http-equiv = "Content-Security-Policy" content = "script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';" >
2021-12-24 23:00:09 +00:00
< script src = "/static/assets/js/bootstrap.js?a=3" > < / script >
2021-12-14 22:48:37 +00:00
2021-10-15 14:08:27 +00:00
< meta charset = "utf-8" >
< meta name = "viewport" content = "width=device-width, initial-scale=1, shrink-to-fit=no" >
2021-12-27 05:07:19 +00:00
2021-10-15 14:08:27 +00:00
< meta name = "author" content = "" >
2022-01-09 17:19:33 +00:00
< link rel = "icon" type = "image/png" href = "/static/assets/images/{{'SITE_NAME' | app_config}}/icon.webp?a=8" >
2021-10-15 14:08:27 +00:00
< title > {% block pagetitle %}Settings - {{'SITE_NAME' | app_config}}{% endblock %}< / title >
2021-12-14 22:48:37 +00:00
< meta property = "og:type" content = "article" >
< meta property = "og:title" content = "{{'SITE_NAME' | app_config}}" >
< meta property = "og:site_name" content = "{{request.host}}" >
2022-01-13 21:15:36 +00:00
< meta property = "og:image" content = "{{'SITE_NAME' | app_config}}/static/assets/images/{{'SITE_NAME' | app_config}}/site_preview.webp?a=1" >
2021-12-14 22:48:37 +00:00
< meta property = "og:url" content = "{{request.host}}" >
< meta property = "og:description" name = "description" content = "{{'SITE_NAME' | app_config}} - {{'SLOGAN' | app_config}}" >
< meta property = "og:author" name = "author" content = "@{{request.host_url}}" >
< meta property = "og:site_name" content = "{{request.host}}" >
< meta name = "twitter:card" content = "summary_large_image" >
< meta name = "twitter:site" content = "@{{request.host_url}}" >
< meta name = "twitter:title" content = "{{'SITE_NAME' | app_config}}" >
< meta name = "twitter:creator" content = "@{{request.host_url}}" >
< meta name = "twitter:description" content = "{{'SITE_NAME' | app_config}} - {{'SLOGAN' | app_config}}" >
2022-01-13 21:15:36 +00:00
< meta name = "twitter:image" content = "{{'SITE_NAME' | app_config}}/static/assets/images/{{'SITE_NAME' | app_config}}/site_preview.webp?a=1" >
2021-12-14 22:48:37 +00:00
< meta name = "twitter:url" content = "{{request.host}}" >
< style > : root { --primary : # { { v . themecolor } } } < / style >
2022-01-13 23:29:15 +00:00
< link rel = "stylesheet" href = "/static/assets/css/main.css?a=73" > < link rel = "stylesheet" href = "/static/assets/css/{{v.theme}}.css?a=11" >
2021-12-28 19:42:05 +00:00
{% if v.agendaposter %}
< style >
html {
cursor:url('https://i.ibb.co/4VZB08S/Image.webp'), auto;
}
.nav-item .text-small.font-weight-bold::before {
content: "((("
}
.nav-item .text-small.font-weight-bold::after {
content: ")))"
}
.nav-item .text-small-extra.text-primary {
font-size: 0 !important
}
.nav-item .text-small-extra.text-primary i {
font-size: 11px !important
}
< / style >
2021-12-31 12:46:32 +00:00
{% elif v.css and not request.path.startswith('/settings/css') %}
2021-12-28 19:42:05 +00:00
< link rel = "stylesheet" href = "/@{{v.username}}/css" >
{% endif %}
2021-12-14 22:48:37 +00:00
< / head >
2021-12-06 19:21:28 +00:00
2021-12-24 23:00:09 +00:00
< body id = "settings" style = "overflow-x: hidden; {% if v and v.background %} background:url(/static/assets/images/backgrounds/{{v.background}}) no-repeat center center fixed !important; background-size: cover!important; background-color: #000!important;{% endif %}" >
2021-12-06 19:21:28 +00:00
2021-12-14 22:48:37 +00:00
{% include "header.html" %}
< div class = "container" >
2021-12-06 19:21:28 +00:00
2021-12-14 22:48:37 +00:00
< div class = "row justify-content-around" >
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
< div class = "col h-100" >
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
{% if error %}
< div class = "alert alert-danger alert-dismissible fade show my-3" role = "alert" >
< i class = "fas fa-exclamation-circle my-auto" > < / i >
< span >
{{error}}
< / span >
2021-12-30 05:27:22 +00:00
< button role = "button" class = "close" data-bs-dismiss = "alert" aria-label = "Close" >
2021-12-14 22:48:37 +00:00
< span aria-hidden = "true" > < i class = "far fa-times" > < / i > < / span >
< / button >
< / div >
{% endif %}
{% if msg %}
< div class = "alert alert-success alert-dismissible fade show my-3" role = "alert" >
< i class = "fas fa-check-circle my-auto" aria-hidden = "true" > < / i >
< span >
{{msg}}
< / span >
2021-12-30 05:27:22 +00:00
< button role = "button" class = "close" data-bs-dismiss = "alert" aria-label = "Close" >
2021-12-14 22:48:37 +00:00
< span aria-hidden = "true" > < i class = "far fa-times" > < / i > < / span >
< / button >
< / div >
{% endif %}
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
< div class = "mt-3" >
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
< h1 class = "d-none d-md-block" > Settings< / h1 >
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
< h2 class = "h3 mt-5 d-md-none" > Settings< / h2 >
2021-11-24 21:03:11 +00:00
2021-10-15 14:08:27 +00:00
< / div >
2021-12-14 22:48:37 +00:00
< div class = "flex-row bg-white box-shadow-bottom sticky d-none d-sm-flex mt-3 mb-3 mb-sm-5" >
< ul class = "nav settings-nav" >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/profile' %} active{% endif %}" href = "/settings/profile" > Profile< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/content' %} active{% endif %}" href = "/settings/content" > Content< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/css' %} active{% endif %}" href = "/settings/css" > Custom CSS< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/profilecss' %} active{% endif %}" href = "/settings/profilecss" > Profile CSS< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/security' %} active{% endif %}" href = "/settings/security" > Security< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/blocks' %} active{% endif %}" href = "/settings/blocks" > Block users< / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/apps' %} active{% endif %}" href = "/settings/apps" > Apps< / a >
< / li >
< / ul >
2021-11-24 21:03:11 +00:00
< / div >
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
< div class = "flex-row bg-white box-shadow-bottom sticky justify-content-center d-flex d-sm-none mt-3 mb-3 mb-sm-5" >
< ul class = "nav settings-nav" >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/profile' %} active{% endif %} navsettings" href = "/settings/profile" > < i class = "fas fa-cog text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/content' %} active{% endif %} navsettings" href = "/settings/content" > < i class = "fas fa-filter text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/css' %} active{% endif %} navsettings" href = "/settings/css" > < i class = "fas fa-palette text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/profilecss' %} active{% endif %} navsettings" href = "/settings/profilecss" > < i class = "fas fa-palette text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/security' %} active{% endif %} navsettings" href = "/settings/security" > < i class = "fas fa-lock-alt text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/blocks' %} active{% endif %} navsettings" href = "/settings/blocks" > < i class = "fas fa-user-minus text-base mr-0" > < / i > < / a >
< / li >
< li class = "nav-item" >
< a class = "nav-link{% if request.path=='/settings/apps' %} active{% endif %} navsettings" href = "/settings/apps" > < i class = "fas fa-code text-base mr-0" > < / i > < / a >
< / li >
< / ul >
2021-11-24 21:03:11 +00:00
< / div >
2021-12-14 22:48:37 +00:00
{% block content %}
{% endblock %}
2021-10-15 14:08:27 +00:00
< / div >
2021-12-14 22:48:37 +00:00
< / div >
< / div >
{% if v %}
< div class = "modal fade" id = "2faModal" tabindex = "-1" role = "dialog" aria-labelledby = "2faModalTitle" aria-hidden = "true" >
< div class = "modal-dialog modal-dialog-centered" role = "document" >
< div class = "modal-content" >
< div class = "modal-header" >
< h5 class = "modal-title" > {% if mfa_secret %}Setup two-step login{% elif mfa_secret and not v.email %}Email required for two-step login{% else %}Disable two-step login{% endif %}< / h5 >
2021-12-30 05:27:22 +00:00
< button role = "button" class = "close" data-bs-dismiss = "modal" aria-label = "Close" >
2021-12-14 22:48:37 +00:00
< span aria-hidden = "true" > < i class = "far fa-times" > < / i > < / span >
< / button >
< / div >
{% if mfa_secret %}
< div >
< form action = "/settings/security" method = "post" >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "hidden" name = "formkey" value = "{{v.formkey}}" >
< input autocomplete = "off" type = "hidden" name = "2fa_secret" value = "{{mfa_secret}}" >
2021-12-14 22:48:37 +00:00
< div class = "modal-body" >
< p >
< span class = "font-weight-bold" > Step 1:< / span > Scan this barcode (or enter the code) using a two-factor authentication app such as Google Authenticator or Authy.
< / p >
< div class = "text-center mb-3" >
2021-12-27 05:07:19 +00:00
< img alt = "two-factor QR code" loading = "lazy" class = "img-fluid" width = 175 src = "/2faqr/{{mfa_secret}}" >
2021-12-14 22:48:37 +00:00
< pre > < / pre >
< div class = "text-small text-muted" > Or enter this code: {{mfa_secret}}< / div >
< / div >
< p >
< span class = "font-weight-bold" > Step 2:< / span > Enter the six-digit code generated in the authenticator app and your {{'SITE_NAME' | app_config}} account password.
< / p >
< label for = "2fa_input" > 6-digit code< / label >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "text" class = "form-control mb-2" id = "2fa_input" name = "2fa_token" placeholder = "# # # # # #" required >
2021-12-14 22:48:37 +00:00
< label for = "2fa_input_password" > Password< / label >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "password" class = "form-control mb-2" id = "2fa_input_password" name = "password" oninput = "document.getElementById('enable2faButton').disabled=false" required >
2021-12-14 22:48:37 +00:00
< / div >
< div class = "modal-footer" >
2021-12-30 05:27:22 +00:00
< button role = "button" class = "btn btn-link text-muted" data-bs-dismiss = "modal" > Cancel< / button >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" id = "enable2faButton" class = "btn btn-primary" type = "submit" value = "Enable 2-step login" disabled >
2021-12-14 22:48:37 +00:00
< / div >
< / form >
< / div >
{% else %}
< div >
< form action = "/settings/security" method = "post" >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "hidden" name = "formkey" value = "{{v.formkey}}" >
< input autocomplete = "off" type = "hidden" name = "2fa_secret" value = "{{mfa_secret}}" >
2021-12-14 22:48:37 +00:00
< div class = "modal-body" >
< div class = "alert alert-warning" role = "alert" >
< i class = "fas fa-info-circle" > < / i >
To disable two-step login, please enter your {{'SITE_NAME' | app_config}} account password and the 6-digit code generated in your authentication app. If you no longer have your two-step device, < a href = "/lost_2fa" > click here< / a > .
< / div >
< label for = "2fa_input_password" > Password< / label >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "password" class = "form-control mb-2" id = "2fa_input_password" name = "password" required >
2021-12-14 22:48:37 +00:00
< label for = "2fa_input" > 6-digit code< / label >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" type = "text" class = "form-control mb-2" id = "2fa_input" name = "2fa_remove" placeholder = "# # # # # #" oninput = "document.getElementById('disable2faButton').disabled=false" required >
2021-12-14 22:48:37 +00:00
< / div >
< div class = "modal-footer" >
2021-12-30 05:27:22 +00:00
< button role = "button" class = "btn btn-link text-muted" data-bs-dismiss = "modal" > Cancel< / button >
2021-12-28 12:41:26 +00:00
< input autocomplete = "off" id = "disable2faButton" class = "btn btn-primary" type = "submit" value = "Disable 2-step login" disabled >
2021-12-14 22:48:37 +00:00
< / div >
< / form >
< / div >
{% endif %}
< / div >
2021-11-24 21:03:11 +00:00
< / div >
2021-10-15 14:08:27 +00:00
< / div >
2021-12-14 22:48:37 +00:00
{% endif %}
2021-10-15 14:08:27 +00:00
2021-12-14 22:48:37 +00:00
{% block clipboard %}
< div class = "toast clipboard" id = "toast-success" role = "alert" aria-live = "assertive" aria-atomic = "true" data-bs-animation = "true" data-bs-autohide = "true" data-bs-delay = "5000" >
< div class = "toast-body text-center" >
< i class = "fas fa-check-circle text-success mr-2" > < / i > Link copied to clipboard
< / div >
< / div >
{% endblock %}
2021-10-15 14:08:27 +00:00
2021-11-24 21:03:11 +00:00
2021-12-14 22:48:37 +00:00
< div class = "toast" id = "toast-post-success" style = "position: fixed; bottom: 1.5rem; margin: 0 auto; left: 0; right: 0; width: 275px; z-index: 1000" role = "alert" aria-live = "assertive" aria-atomic = "true" data-bs-animation = "true" data-bs-autohide = "true" data-bs-delay = "5000" >
< div class = "toast-body bg-success text-center text-white" >
2021-12-17 04:44:25 +00:00
< i class = "fas fa-comment-alt-smile mr-2" > < / i > < span id = "toast-post-success-text" > Action successful!< / span >
2021-12-14 22:48:37 +00:00
< / div >
< / div >
< div class = "toast" id = "toast-post-error" style = "position: fixed; bottom: 1.5rem; margin: 0 auto; left: 0; right: 0; width: 275px; z-index: 1000" role = "alert" aria-live = "assertive" aria-atomic = "true" data-bs-animation = "true" data-bs-autohide = "true" data-bs-delay = "5000" >
< div class = "toast-body bg-danger text-center text-white" >
< i class = "fas fa-exclamation-circle mr-2" > < / i > < span id = "toast-post-error-text" > Error, please try again later.< / span >
< / div >
< / div >
2021-12-12 15:06:13 +00:00
2021-12-03 02:40:07 +00:00
2021-12-14 22:48:37 +00:00
{% block onload %}{% endblock %}
2021-12-03 02:40:07 +00:00
2021-12-24 23:00:09 +00:00
< script src = "/static/assets/js/clipboard.js?a=3" > < / script >
2021-12-12 15:06:13 +00:00
2021-12-14 22:48:37 +00:00
< style >
.navsettings {
padding-left: 0.9rem !important;
padding-right: 0.9rem !important;
}
< / style >
2021-12-12 15:06:13 +00:00
2021-11-24 21:03:11 +00:00
< / body >
2021-12-14 22:48:37 +00:00
2021-08-22 17:00:07 +00:00
< / html >