styling updates
This commit is contained in:
+137
-11
@@ -15,20 +15,24 @@ body {
|
|||||||
--container-max: 1280px;
|
--container-max: 1280px;
|
||||||
--container-gutter: clamp(1rem, 3vw, 2rem);
|
--container-gutter: clamp(1rem, 3vw, 2rem);
|
||||||
}
|
}
|
||||||
|
|
||||||
header {
|
header {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
height: 60px;
|
height: 60px;
|
||||||
width: auto;
|
width: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mascots {
|
.mascots {
|
||||||
height: 150px;
|
height: 150px;
|
||||||
width: auto;
|
width: auto;
|
||||||
margin-left: auto;
|
margin-left: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.container {
|
.container {
|
||||||
width: min(100% - (2 * var(--container-gutter)), var(--container-max));
|
width: min(100% - (2 * var(--container-gutter)), var(--container-max));
|
||||||
margin-inline: auto;
|
margin-inline: auto;
|
||||||
@@ -48,7 +52,10 @@ header {
|
|||||||
--container-max: 1440px;
|
--container-max: 1440px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.weather-location {
|
||||||
|
display: flex;
|
||||||
|
gap: 10px;
|
||||||
|
}
|
||||||
.day-picker {
|
.day-picker {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
@@ -63,9 +70,11 @@ header {
|
|||||||
color: inherit;
|
color: inherit;
|
||||||
}
|
}
|
||||||
|
|
||||||
.day-picker > a {
|
.day-picker>a {
|
||||||
display: grid;
|
display: flex;
|
||||||
place-items: center;
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
line-height: 0;
|
||||||
width: 2.5rem;
|
width: 2.5rem;
|
||||||
height: 2.5rem;
|
height: 2.5rem;
|
||||||
font-size: 2rem;
|
font-size: 2rem;
|
||||||
@@ -78,6 +87,7 @@ header {
|
|||||||
.day-picker div a {
|
.day-picker div a {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
// dashboards/grids
|
// dashboards/grids
|
||||||
.container-flex--full {
|
.container-flex--full {
|
||||||
--container-max: none;
|
--container-max: none;
|
||||||
@@ -171,33 +181,47 @@ header {
|
|||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.weather-forecast {
|
.weather-forecast {
|
||||||
font-size: 2em;
|
font-size: 2em;
|
||||||
margin-bottom: 50px;
|
margin-bottom: 50px;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
|
display: flex;
|
||||||
|
gap: 10px;
|
||||||
|
> span {
|
||||||
|
line-height: 2;
|
||||||
|
font-size: 25px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.task-composer {
|
.task-composer {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
margin-bottom: 50px;
|
margin-bottom: 50px;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
&__submit {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
form.task-composer__form {
|
form.task-composer__form {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
max-width: unset;
|
max-width: unset;
|
||||||
box-shadow: unset;
|
box-shadow: unset;
|
||||||
|
|
||||||
label,
|
label,
|
||||||
input,
|
input,
|
||||||
textarea{
|
textarea {
|
||||||
max-width: unset;
|
max-width: unset;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&__main {
|
&__main {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
&__details {
|
&__details {
|
||||||
display: flex;
|
display: flex;
|
||||||
gap: 25px;
|
gap: 25px;
|
||||||
|
|
||||||
input[type=checkbox] {
|
input[type=checkbox] {
|
||||||
height: 30px;
|
height: 30px;
|
||||||
}
|
}
|
||||||
@@ -227,7 +251,7 @@ header {
|
|||||||
border-radius: .5rem;
|
border-radius: .5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.task-composer__repeat-input:checked ~ .task-composer__repeat-fields {
|
.task-composer__repeat-input:checked~.task-composer__repeat-fields {
|
||||||
display: grid;
|
display: grid;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -242,6 +266,7 @@ header {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
gap: .5rem;
|
gap: .5rem;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
|
|
||||||
form {
|
form {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
outline: unset;
|
outline: unset;
|
||||||
@@ -353,11 +378,27 @@ header {
|
|||||||
opacity: .65;
|
opacity: .65;
|
||||||
text-decoration: line-through;
|
text-decoration: line-through;
|
||||||
}
|
}
|
||||||
.task-result {
|
|
||||||
background-color: #fff;
|
.task-result-container {
|
||||||
color: #000;
|
|
||||||
padding: 25px;
|
.task-result {
|
||||||
|
color: #000;
|
||||||
|
padding: 25px;
|
||||||
|
margin: 25px;
|
||||||
|
|
||||||
|
h2 {
|
||||||
|
color: #fff;
|
||||||
|
font-size: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 {
|
||||||
|
color: #000;
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.htmx-indicator {
|
.htmx-indicator {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
@@ -387,3 +428,88 @@ header {
|
|||||||
.request-failed:not([hidden]) {
|
.request-failed:not([hidden]) {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.suggested-tasks {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 25px;
|
||||||
|
padding: 25px;
|
||||||
|
background-color: #fff;
|
||||||
|
|
||||||
|
>li {
|
||||||
|
outline: 1px solid black;
|
||||||
|
width: 100%;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
button {
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
font-size: 15px;
|
||||||
|
border-radius: 0;
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
right: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
>article {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
width: 100%;
|
||||||
|
padding: 25px;
|
||||||
|
|
||||||
|
.summary {}
|
||||||
|
|
||||||
|
.info {
|
||||||
|
ul {
|
||||||
|
display: flex;
|
||||||
|
gap: 20px;
|
||||||
|
|
||||||
|
li {
|
||||||
|
display: flex;
|
||||||
|
gap: 20px;
|
||||||
|
|
||||||
|
span:first-of-type {
|
||||||
|
font-weight: 700;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.braindump-form {
|
||||||
|
width: 100%;
|
||||||
|
box-shadow: unset;
|
||||||
|
max-width: unset;
|
||||||
|
position: relative;
|
||||||
|
background-color: #fff;
|
||||||
|
|
||||||
|
textarea {
|
||||||
|
max-width: unset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.thinking {
|
||||||
|
// display: block;
|
||||||
|
background-color: rgba(0, 0, 0, 0.5);
|
||||||
|
transition: 0.3s all ease-in-out;
|
||||||
|
position: absolute;
|
||||||
|
inset: 0;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 15px;
|
||||||
|
font-size: 2em;
|
||||||
|
color: #fff;
|
||||||
|
inset: 0;
|
||||||
|
z-index: -1;
|
||||||
|
opacity: 0;
|
||||||
|
|
||||||
|
&.htmx-request {
|
||||||
|
// display: block;
|
||||||
|
z-index: 10;
|
||||||
|
opacity: 1;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -34,7 +34,7 @@ final class TaskController extends AbstractController
|
|||||||
'battery_budget' => $taskRecommendationService->budgetFor($batteryLevel),
|
'battery_budget' => $taskRecommendationService->budgetFor($batteryLevel),
|
||||||
'selected_date' => $selectedDate,
|
'selected_date' => $selectedDate,
|
||||||
'form' => $this->createForm(TaskType::class, $newTask, ['include_active' => false]),
|
'form' => $this->createForm(TaskType::class, $newTask, ['include_active' => false]),
|
||||||
'weather_forecast' => $selectedDate->format('Y-m-d') === (new \DateTimeImmutable('today'))->format('Y-m-d') ? $weatherService->cachedForecastFor($settings, $selectedDate) : null,
|
'weather_forecast' => $selectedDate->format('Y-m-d') === $selectedDate->format('Y-m-d') ? $weatherService->cachedForecastFor($settings, $selectedDate) : null,
|
||||||
'has_saved_location' => $settings?->hasLocation() ?? false,
|
'has_saved_location' => $settings?->hasLocation() ?? false,
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,29 +2,37 @@
|
|||||||
<p>No tasks were suggested.</p>
|
<p>No tasks were suggested.</p>
|
||||||
{% else %}
|
{% else %}
|
||||||
<h2>Suggested tasks</h2>
|
<h2>Suggested tasks</h2>
|
||||||
|
<ul class="suggested-tasks">
|
||||||
{% for task in tasks %}
|
{% for task in tasks %}
|
||||||
<article>
|
|
||||||
<h3>{{ task.title }}</h3>
|
|
||||||
<ul>
|
|
||||||
{% if task.description %}
|
|
||||||
<li><p>{{ task.description }}</p></li>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<dt>Duration</dt>
|
{{ dump(task|json_encode) }}
|
||||||
<dd>{{ task.estimatedDurationMinutes }} minutes</dd>
|
<button><span class="material-symbols-outlined">menu</span></button>
|
||||||
|
<article>
|
||||||
<dt>Priority</dt>
|
<div class="summary">
|
||||||
<dd>{{ task.priority }}</dd>
|
<h3>{{ task.title }}</h3>
|
||||||
|
{% if task.description %}
|
||||||
<dt>Category</dt>
|
<p>{{ task.description }}</p>
|
||||||
<dd>{{ task.category }}</dd>
|
{% endif %}
|
||||||
|
</div>
|
||||||
<dt>Recurring</dt>
|
<div class="info">
|
||||||
<dd>{{ task.isRecurring ? 'Yes' : 'No' }}</dd>
|
<ul>
|
||||||
|
<li>
|
||||||
|
<span>Duration</span> <span>{{ task.estimatedDurationMinutes }} minutes</span>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<span>Priority</span><span>{{ task.priority }}</span>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<span>Category</span><span>{{ task.category }}</span>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<span>Recurring</span><span>{{ task.isRecurring ? 'Yes' : 'No' }}</span>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</article>
|
||||||
</li>
|
</li>
|
||||||
</article>
|
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ul>
|
</ul>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@@ -7,6 +7,7 @@
|
|||||||
<h1>Brain Dump</h1>
|
<h1>Brain Dump</h1>
|
||||||
|
|
||||||
<form
|
<form
|
||||||
|
class="braindump-form"
|
||||||
method="post"
|
method="post"
|
||||||
action="{{ path('app_braindump_dump') }}"
|
action="{{ path('app_braindump_dump') }}"
|
||||||
hx-post="{{ path('app_braindump_dump') }}"
|
hx-post="{{ path('app_braindump_dump') }}"
|
||||||
@@ -36,30 +37,33 @@
|
|||||||
></textarea>
|
></textarea>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button type="submit">
|
<button type="submit">
|
||||||
<span class="material-symbols-outlined">robot_2</span>
|
<span class="material-symbols-outlined">robot_2</span>
|
||||||
Suggest tasks
|
Suggest tasks
|
||||||
</button>
|
</button>
|
||||||
|
<span
|
||||||
|
id="thinking"
|
||||||
|
class="thinking"
|
||||||
|
class="htmx-indicator"
|
||||||
|
aria-live="polite"
|
||||||
|
>
|
||||||
|
<span class="material-symbols-outlined spinner">progress_activity</span>
|
||||||
|
Thinking…
|
||||||
|
</span>
|
||||||
|
<span
|
||||||
|
id="request-failed"
|
||||||
|
class="request-failed"
|
||||||
|
aria-live="assertive"
|
||||||
|
hidden>
|
||||||
|
<span class="material-symbols-outlined">error</span>
|
||||||
|
Something went wrong
|
||||||
|
</span>
|
||||||
</form>
|
</form>
|
||||||
<span
|
|
||||||
id="thinking"
|
<div class="task-result-container">
|
||||||
class="htmx-indicator"
|
<div id="tasks-result" class="task-result">
|
||||||
aria-live="polite"
|
{# HTMX will put the proposed tasks here #}
|
||||||
>
|
</div>
|
||||||
<span class="material-symbols-outlined spinner">progress_activity</span>
|
|
||||||
Thinking…
|
|
||||||
</span> <span
|
|
||||||
id="request-failed"
|
|
||||||
class="request-failed"
|
|
||||||
aria-live="assertive"
|
|
||||||
hidden
|
|
||||||
>
|
|
||||||
<span class="material-symbols-outlined">error</span>
|
|
||||||
Something went wrong
|
|
||||||
</span>
|
|
||||||
<div id="tasks-result" class="task-result">
|
|
||||||
{# HTMX will put the proposed tasks here #}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
@@ -8,14 +8,18 @@
|
|||||||
<h1>Tasks</h1>
|
<h1>Tasks</h1>
|
||||||
|
|
||||||
<nav class="day-picker" aria-label="Choose task day">
|
<nav class="day-picker" aria-label="Choose task day">
|
||||||
<a href="{{ path('app_task_index', {date: selected_date|date_modify('-1 day')|date('Y-m-d')}) }}" aria-label="Previous day">‹</a>
|
<a href="{{ path('app_task_index', {date: selected_date|date_modify('-1 day')|date('Y-m-d')}) }}" aria-label="Previous day"><span class="material-symbols-outlined">
|
||||||
|
chevron_backward
|
||||||
|
</span></a>
|
||||||
<div>
|
<div>
|
||||||
<strong>{{ selected_date|date('l, j F') }}</strong>
|
<strong>{{ selected_date|date('l, j F') }}</strong>
|
||||||
{% if selected_date|date('Y-m-d') != 'now'|date('Y-m-d') %}
|
{% if selected_date|date('Y-m-d') != 'now'|date('Y-m-d') %}
|
||||||
<a href="{{ path('app_task_index') }}">Today</a>
|
<a href="{{ path('app_task_index') }}">Today</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
<a href="{{ path('app_task_index', {date: selected_date|date_modify('+1 day')|date('Y-m-d')}) }}" aria-label="Next day">›</a>
|
<a href="{{ path('app_task_index', {date: selected_date|date_modify('+1 day')|date('Y-m-d')}) }}" aria-label="Next day"><span class="material-symbols-outlined">
|
||||||
|
chevron_forward
|
||||||
|
</span></a>
|
||||||
</nav>
|
</nav>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user