Add titles

This commit is contained in:
Eugene Burmakin 2024-06-12 21:10:53 +02:00
parent 7daac8a887
commit b7f648dc07
13 changed files with 23 additions and 5 deletions

View file

@ -1 +1 @@
0.5.3
0.6.0

View file

@ -63,6 +63,8 @@ You can see the number of countries and cities visited, the distance traveled, a
You can import your Google Maps Timeline data into Dawarich as well as Owntracks data.
⚠️ **Note**: Import of huge Google Maps Timeline files may take a long time and consume a lot of memory. It also might temporarily consume a lot of disk space due to logs. Please make sure you have enough resources before starting the import. After import is completed, you can restart your docker container and logs will be removed.
## How to start the app locally
`docker-compose up` to start the app. The app will be available at `http://localhost:3000`.

View file

@ -33,7 +33,6 @@ class ExportsController < ApplicationController
@export = current_user.exports.find(params[:id])
end
# Only allow a list of trusted parameters through.
def export_params
params.require(:export).permit(:name, :url, :status)
end

View file

@ -104,4 +104,9 @@ module ApplicationHelper
def active_class?(link_path)
'btn-active' if current_page?(link_path)
end
def full_title(page_title = '')
base_title = 'Dawarich'
page_title.empty? ? base_title : "#{page_title} | #{base_title}"
end
end

View file

@ -1,3 +1,5 @@
<% content_for :title, 'Imports' %>
<div class="w-full">
<div class="flex justify-between items-center">
<h1 class="font-bold text-4xl">Imports</h1>

View file

@ -1,3 +1,5 @@
<% content_for :title, 'New Import' %>
<div class="mx-auto md:w-2/3 w-full">
<h1 class="font-bold text-4xl">New import</h1>

View file

@ -1,3 +1,5 @@
<% content_for :title, 'Import' %>
<div class="mx-auto md:w-2/3 w-full flex">
<div class="mx-auto">
<% if notice.present? %>

View file

@ -1,7 +1,7 @@
<!DOCTYPE html>
<html data-theme="<%= app_theme %>">
<head>
<title>DaWarIch</title>
<title><%= full_title(yield(:title)) %></title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<%= csrf_meta_tags %>
<%= csp_meta_tag %>

View file

@ -1,3 +1,5 @@
<% content_for :title, 'Map' %>
<div class='w-4/5 mt-10'>
<div class="flex flex-col space-y-4 mb-4 w-full">
<%= form_with url: map_path, method: :get do |f| %>

View file

@ -1,4 +1,4 @@
<% content_for :title, "Points" %>
<% content_for :title, 'Points' %>
<div class="w-full">
<%= form_with url: points_path, method: :get do |f| %>

View file

@ -1,3 +1,5 @@
<% content_for :title, 'Statistics' %>
<div class="w-full">
<div class="stats stats-vertical lg:stats-horizontal shadow w-full bg-base-200">
<div class="stat text-center">

View file

@ -1,3 +1,5 @@
<% content_for :title, "Statistics for #{@year} year" %>
<div class="w-full">
<%= render partial: 'stats/year', locals: { year: @year, stats: @stats } %>
</div>

View file

@ -180,7 +180,7 @@ paths:
lat: 52.502397
lon: 13.356718
tid: Swagger
tst: 1718216894
tst: 1718219019
servers:
- url: http://{defaultHost}
variables: