simple-login/app/developer/templates/developer/index.html
2021-04-06 18:12:06 +02:00

108 lines
3.6 KiB
HTML

{% extends 'default.html' %}
{% set active_page = "developer" %}
{% block title %}
Sign in with SimpleLogin
{% endblock %}
{% block default_content %}
<div class="row">
<div class="col">
<h1 class="h3">Sign in with SimpleLogin (SIWSL)
<a class="ml-3 text-info" style="font-size: 12px" data-toggle="collapse" href="#howtouse" role="button"
aria-expanded="false" aria-controls="collapseExample">
How to use <i class="fe fe-chevrons-down"></i>
</a>
</h1>
<div class="alert alert-primary collapse {% if not clients %} show {% endif %}" id="howtouse" role="alert">
If you have a website or a mobile app and want to integrate SIWSL,
this page is for you.
<br><br>
If you are using a CMS or any system that supports plugin, you can install the OpenID Connect plugin and point
it to SimpleLogin OpenID Configuration endpoint 👇
<div class="input-group mt-2">
<input type="text" disabled value="{{ URL + "/.well-known/openid-configuration" }}" class="form-control">
<span class="input-group-append">
<button
data-clipboard-text="{{ URL + "/.well-known/openid-configuration" }}"
class="clipboard btn btn-primary" type="button">
<i class="fe fe-clipboard"></i>
</button>
</span>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col">
<div class="btn-group" role="group" aria-label="Basic example">
<a href="{{ url_for('developer.new_client') }}" class="btn btn-primary">
Create new website/app
</a>
<a href="https://docs.simplelogin.io" target="_blank" class="ml-2 btn btn-secondary">
Docs <i class="fe fe-external-link"></i>
</a>
</div>
</div>
</div>
<div class="row row-cards row-deck mt-4">
{% for client in clients %}
<div class="col-md-6">
<div class="card">
<div class="card-header">
<div class="card-title d-flex align-items-center">
{% if client.icon_id %}
<span class="avatar mr-2" style="background-image: url({{ client.icon.get_url() }})"></span>
{% endif %}
<span class="">
<a href="{{ url_for('developer.client_detail', client_id=client.id) }}">
{{ client.name }}
</a>
{% if client.approved %}
<span class="cursor" data-toggle="tooltip" data-original-title="Approved"></span>
{% else %}
<span class="cursor" data-toggle="tooltip" data-original-title="In Dev mode">
<a href="{{ url_for('developer.client_detail', client_id=client.id) }}"
class="text-decoration-none">🚫
</a>
</span>
{% endif %}
</span>
</div>
<div class="card-options">
<a href="{{ url_for('developer.client_detail', client_id=client.id) }}"
class="btn btn-primary btn-sm">
Edit
</a>
</div>
</div>
<div class="card-body">
<span class="h1 m-0">{{ client.nb_user() }}</span> Users <br>
Created {{ client.created_at |dt }} <br>
{% if client.last_user_login() %}
Last User Login: {{ client.last_user_login().get_user_name() }}
{% endif %}
</div>
</div>
</div>
{% endfor %}
</div>
{% endblock %}