mirror of https://github.com/kevachat/webapp.git
ghost
12 months ago
10 changed files with 196 additions and 36 deletions
@ -0,0 +1,46 @@
@@ -0,0 +1,46 @@
|
||||
{% extends 'default/layout.html.twig' %} |
||||
{% block head_title_content %}{{ 'Rooms' | trans }} - {{ 'KevaChat' | trans }}{% endblock %} |
||||
{% block main_content %} |
||||
{{ |
||||
render( |
||||
controller( |
||||
'App\\Controller\\ModuleController::rooms', |
||||
{ |
||||
request: request |
||||
} |
||||
) |
||||
) |
||||
}} |
||||
{% if list | length %} |
||||
<ul> |
||||
{% for room in list %} |
||||
<li> |
||||
<div> |
||||
<strong> |
||||
<a href="{{ path('room_namespace', { namespace : room.namespace }) }}">{{ room.namespace | keva_namespace_value }}</a> |
||||
</strong> |
||||
{{ room.total }} |
||||
<a href="{{ path('room_namespace', { namespace : room.namespace, feed : 'rss' }) }}" title="{{ 'RSS' | trans }}" target="_blank"><svg xmlns="http://www.w3.org/2000/svg" width="10" height="10" viewBox="0 0 16 16"> |
||||
<path d="M2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2zm1.5 2.5c5.523 0 10 4.477 10 10a1 1 0 1 1-2 0 8 8 0 0 0-8-8 1 1 0 0 1 0-2m0 4a6 6 0 0 1 6 6 1 1 0 1 1-2 0 4 4 0 0 0-4-4 1 1 0 0 1 0-2m.5 7a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"/> |
||||
</svg></a> |
||||
{% if room.pinned %} |
||||
<i title="{{ 'pinned' | trans }}"> |
||||
<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" fill="currentColor" viewBox="0 0 16 16" title="{{ 'pinned' | trans }}" style="float:right"> |
||||
<path d="M9.828.722a.5.5 0 0 1 .354.146l4.95 4.95a.5.5 0 0 1 0 .707c-.48.48-1.072.588-1.503.588-.177 0-.335-.018-.46-.039l-3.134 3.134a5.927 5.927 0 0 1 .16 1.013c.046.702-.032 1.687-.72 2.375a.5.5 0 0 1-.707 0l-2.829-2.828-3.182 3.182c-.195.195-1.219.902-1.414.707-.195-.195.512-1.22.707-1.414l3.182-3.182-2.828-2.829a.5.5 0 0 1 0-.707c.688-.688 1.673-.767 2.375-.72a5.922 5.922 0 0 1 1.013.16l3.134-3.133a2.772 2.772 0 0 1-.04-.461c0-.43.108-1.022.589-1.503a.5.5 0 0 1 .353-.146z"/> |
||||
</svg> |
||||
</i> |
||||
{% endif %} |
||||
</div> |
||||
</li> |
||||
{% endfor %} |
||||
</ul> |
||||
{% else %} |
||||
<ul> |
||||
<li> |
||||
<div> |
||||
{{ 'rooms not found' | trans }} |
||||
</div> |
||||
</li> |
||||
</ul> |
||||
{% endif %} |
||||
{% endblock %} |
@ -0,0 +1,16 @@
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/"> |
||||
<channel> |
||||
<atom:link href="{{ url('room_list') }}" rel="self" type="application/rss+xml"></atom:link> |
||||
<title>{{ 'Rooms' | trans }} - {{ 'KevaChat' | trans }}</title> |
||||
<link>{{ url('room_list') }}</link> |
||||
{% for room in list %} |
||||
<item> |
||||
<title>{{ room.namespace | keva_namespace_value }}</title> |
||||
<guid>{{ url('room_namespace', { namespace : room.namespace }) }}</guid> |
||||
<link>{{ url('room_namespace', { namespace : room.namespace }) }}</link> |
||||
<description>{{ 'join' | trans }} {{ room.namespace | keva_namespace_value }} {{ 'room' | trans }}!</description> |
||||
</item> |
||||
{% endfor %} |
||||
</channel> |
||||
</rss> |
Loading…
Reference in new issue