Add a small logo, CSS fixes

This commit is contained in:
Cyril 2019-10-29 22:46:24 +01:00
parent c5e50fe12f
commit 5da40c1c8d
7 changed files with 17 additions and 8 deletions

BIN
public/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

View File

@ -14,8 +14,8 @@ class AddressBookType extends AbstractType
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
->add('uri', TextType::class, ['disabled' => !$options['new'], 'help' => "Allowed characters are digits, lowercase letters and the dash symbol '-'."])
->add('displayName')
->add('uri', TextType::class, ['disabled' => !$options['new'], 'help' => "This is the unique identifier for this address book. Allowed characters are digits, lowercase letters and the dash symbol '-'."])
->add('displayName', TextType::class, ['help' => 'This name will be displayed in your CardDAV client'])
->add('description')
->add('save', SubmitType::class);
}

View File

@ -15,10 +15,10 @@ class CalendarInstanceType extends AbstractType
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
->add('uri', TextType::class, ['disabled' => !$options['new'], 'help' => "Allowed characters are digits, lowercase letters and the dash symbol '-'."])
->add('displayName')
->add('uri', TextType::class, ['disabled' => !$options['new'], 'help' => "THis is the unique identifier for this calendar. Allowed characters are digits, lowercase letters and the dash symbol '-'.", 'required' => true])
->add('displayName', TextType::class, ['help' => 'This name will be displayed in your CalDAV client'])
->add('description')
->add('calendarColor')
->add('calendarColor', TextType::class, ['required' => false, 'help' => "This is the color that will be displayed in your CalDAV client. It must be supplied in the format '#RRGGBBAA' (alpha channel is optional) with hexadecimal values. This value is optional."])
->add('todos', CheckboxType::class, [
'mapped' => false,
'help' => 'If checked, todos will be enabled on this calendar.',

View File

@ -8,7 +8,9 @@
</head>
<body>
<nav class="navbar fixed-top navbar-expand-lg navbar-light bg-light">
<a class="navbar-brand" href="#">Davis</a>
<a class="navbar-brand" href="#">
<img src="/images/logo.png" width="30" height="30" alt=""> Davis
</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>

View File

@ -11,7 +11,7 @@
{% for calendar in calendars %}
<div class="list-group-item list-group-item-action">
<div class="d-flex w-100 justify-content-between">
<h5 class="mb-1 mr-auto">{{ calendar.displayName }}</h5>
<h5 class="mb-1 mr-auto">{{ calendar.displayName }} <span class="badge badge-pill" style="background-color: {{ calendar.calendarColor }}">&nbsp;</span></h5>
<a href="{{ path('calendar_edit',{username: username, id: calendar.id})}}" class="btn btn-primary ml-1">✎ Edit</a>
<!-- <a href="{{ path('user_delete',{username: principal.username})}}" class="btn btn-danger ml-1">⚠ Delete</a> -->
</div>

View File

@ -10,7 +10,7 @@
<h3 class="mb-3 mt-4">Configured environment</h3>
<ul class="list-group">
<li class="list-group-item list-group-item-secondary">Version : <code>{{ version }}</code> (SabreDAV <code>{{ sabredav_version }}</code>)</li>
<li class="list-group-item list-group-item-primary">Version : <code>{{ version }}</code> (SabreDAV <code>{{ sabredav_version }}</code>)</li>
<li class="list-group-item list-group-item-secondary">Auth Realm : <code>{{ authRealm }}</code></li>
<li class="list-group-item list-group-item-secondary">Invite from address : <code>{{ invite_from_address|default('Not set') }}</code></li>
<li class="list-group-item list-group-item-secondary">Server timezone : <code>{{ timezone }}</code> <a class="small ml-2" target="_blank" href="https://www.php.net/manual/en/datetime.configuration.php#ini.date.timezone">How to change it ?</a></li>

View File

@ -36,10 +36,17 @@
.admin {
margin-top: 30px;
}
h3 {
margin-bottom: 30px;
}
img {
margin-bottom: 10px;
}
</style>
</head>
<body>
<div class="hero">
<img src="/images/logo.png" width="60px">
<h3>Davis is running.</h3>
<div>CalDAV : {% if calDAVEnabled %}<span class="badge badge-success">enabled</span>{% else %}<span class="badge badge-warning">disabled</span>{% endif %}</div>
<div>CardDAV : {% if cardDAVEnabled %}<span class="badge badge-success">enabled</span>{% else %}<span class="badge badge-warning">disabled</span>{% endif %}</div>