2023-12-31 12:35:29 +00:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>Holiday-api | {{deferint $.Search.Year}}</title>
|
|
|
|
<meta charset="utf-8">
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
|
|
|
|
<link rel="icon" href="favicon.ico" type="image/x-icon">
|
|
|
|
<link rel="stylesheet" href="/assets/global.css">
|
|
|
|
<script src="/assets/global.js"></script>
|
|
|
|
|
|
|
|
<style>
|
|
|
|
.dropdown {
|
|
|
|
position: relative;
|
|
|
|
display: inline-block;
|
|
|
|
}
|
|
|
|
|
|
|
|
.dropdown-content {
|
|
|
|
display: none;
|
|
|
|
position: absolute;
|
2024-02-08 19:48:19 +00:00
|
|
|
background-color: var(--dropdown-background);
|
2023-12-31 12:35:29 +00:00
|
|
|
min-width: 160px;
|
2024-02-08 19:48:19 +00:00
|
|
|
box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2);
|
2023-12-31 12:35:29 +00:00
|
|
|
z-index: 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
.dropdown-content.selected {
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
.dropdown-content a {
|
|
|
|
all: unset;
|
|
|
|
display: block;
|
|
|
|
padding: 0.5em 1em;
|
|
|
|
}
|
|
|
|
.dropdown-content a:hover {
|
|
|
|
background: rgba(95, 158, 160, 0.2);
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<div class="background-image" style="position: fixed;"></div>
|
2024-01-01 11:29:59 +00:00
|
|
|
<header>
|
|
|
|
<h1><a href="/">Holiday-api</a> | {{deferint $.Search.Year}}</h1>
|
|
|
|
<div style="flex-grow: 1"></div>
|
|
|
|
<a style="all: unset;" href="/documentation">Api dokumentacija</a>
|
|
|
|
</header>
|
|
|
|
<main class="dialog results-dialog">
|
2023-12-31 12:35:29 +00:00
|
|
|
<section style="margin-bottom: 1em;">
|
|
|
|
<form style="display: flex; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 1em" action="/">
|
|
|
|
<div style="flex-grow: 1;"></div>
|
|
|
|
<div class="form-field" style="width: auto;" >
|
|
|
|
<label for="year">Za godinu:</label>
|
|
|
|
<select id="year" name="year" style="width: 150px">
|
|
|
|
{{range $entry := .Years}}
|
|
|
|
<option {{if intpeq $.Search.Year $entry}}selected{{end}} value="{{$entry}}">{{$entry}}</option>
|
|
|
|
{{end}}
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
<div class="button-actions">
|
|
|
|
<button class="primary">Pretraži</button>
|
|
|
|
</div>
|
|
|
|
<div class="button-actions" style="margin-left: auto">
|
|
|
|
<div class="dropdown">
|
|
|
|
<button type="button" class="secondary dropdown-action">Preuzmi</button>
|
|
|
|
<div class="dropdown-content">
|
|
|
|
<a target="_blank" href="/api/v1/holidays?country=HR&type=csv&year={{deferint $.Search.Year}}">Kao csv</a>
|
|
|
|
<a target="_blank" href="/api/v1/holidays?country=HR&type=json&year={{deferint $.Search.Year}}">Kao json</a>
|
|
|
|
<a target="_blank" href="/api/v1/holidays?country=HR&type=xml&year={{deferint $.Search.Year}}">Kao xml</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</section>
|
|
|
|
<table class="results">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Ime</th>
|
|
|
|
<th>Datum</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{{range $entry := .Holidays}}
|
|
|
|
<tr>
|
|
|
|
<td>{{$entry.Name}}</td>
|
|
|
|
<td>{{$entry.Date.Format "02.01.2006."}}</td>
|
|
|
|
</tr>
|
|
|
|
{{end}}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2024-01-01 11:29:59 +00:00
|
|
|
</main>
|
2023-12-31 12:35:29 +00:00
|
|
|
</body>
|
|
|
|
</html>
|