Compare commits
No commits in common. "045a42c250ed421e84f774f8619d7625934dcce1" and "f7e6810edaf744f6dcc7c502fe22cdd264e444b2" have entirely different histories.
045a42c250
...
f7e6810eda
4 changed files with 8 additions and 22 deletions
|
@ -58,8 +58,6 @@ return [
|
||||||
|
|
||||||
'asset_url' => env('ASSET_URL'),
|
'asset_url' => env('ASSET_URL'),
|
||||||
|
|
||||||
'trip' => env('TRIP'),
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Application Timezone
|
| Application Timezone
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
#map {
|
#map {
|
||||||
height: 400px;
|
min-height: 800px;
|
||||||
grid-column-start: 1;
|
grid-column-start: 1;
|
||||||
grid-column-end: 3;
|
grid-column-end: 3;
|
||||||
}
|
}
|
||||||
|
@ -44,8 +44,6 @@ details h2 {
|
||||||
}
|
}
|
||||||
|
|
||||||
#map {
|
#map {
|
||||||
height: auto;
|
|
||||||
min-height: 800px;
|
|
||||||
grid-column-end: 2;
|
grid-column-end: 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -12,10 +12,10 @@
|
||||||
<script src="https://unpkg.com/leaflet@1.8.0/dist/leaflet.js"
|
<script src="https://unpkg.com/leaflet@1.8.0/dist/leaflet.js"
|
||||||
integrity="sha512-BB3hKbKWOc9Ez/TAwyWxNXeoV9c1v6FIeYiBieIWkpLjauysF18NzgR1MBNBXf8/KABdlkX68nAhlwcDFLGPCQ=="
|
integrity="sha512-BB3hKbKWOc9Ez/TAwyWxNXeoV9c1v6FIeYiBieIWkpLjauysF18NzgR1MBNBXf8/KABdlkX68nAhlwcDFLGPCQ=="
|
||||||
crossorigin=""></script>
|
crossorigin=""></script>
|
||||||
<link rel="stylesheet" href="/css/app.css" />
|
<link rel="stylesheet" href="{{ url('/css/app.css') }}" />
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body class="antialiased">
|
||||||
|
|
||||||
<header>
|
<header>
|
||||||
<h1>Where in the World is Ben?</h1>
|
<h1>Where in the World is Ben?</h1>
|
||||||
|
@ -32,8 +32,8 @@
|
||||||
<section id="checkinList">
|
<section id="checkinList">
|
||||||
<ol>
|
<ol>
|
||||||
@foreach($trip->checkins as $checkin)
|
@foreach($trip->checkins as $checkin)
|
||||||
<li>
|
<li id="{{ $checkin->id }}" onClick="openCheckin(this.id)">
|
||||||
<details id="{{ $checkin->id }}" ontoggle="toggleCheckin(this.open, this.id)">
|
<details>
|
||||||
<summary><h2>{{ $checkin->title ?? "[No title]" }}</h2> <span>{{ $checkin->date }}</span></summary>
|
<summary><h2>{{ $checkin->title ?? "[No title]" }}</h2> <span>{{ $checkin->date }}</span></summary>
|
||||||
{{ $checkin->note ?? "[No note]" }}
|
{{ $checkin->note ?? "[No note]" }}
|
||||||
</details>
|
</details>
|
||||||
|
@ -71,18 +71,8 @@
|
||||||
checkinMarkers[{{ $checkin->id }}] = marker;
|
checkinMarkers[{{ $checkin->id }}] = marker;
|
||||||
@endforeach
|
@endforeach
|
||||||
|
|
||||||
function toggleCheckin(isOpen, checkinId) {
|
function openCheckin(checkinId) {
|
||||||
if (isOpen) {
|
checkinMarkers[checkinId].openPopup();
|
||||||
var checkins = document.querySelectorAll('details');
|
|
||||||
|
|
||||||
checkinMarkers[checkinId].openPopup();
|
|
||||||
|
|
||||||
checkins.forEach(checkin => {
|
|
||||||
if (checkin.id != checkinId && checkin.open) checkin.open = false;
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
checkinMarkers[checkinId].closePopup();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
</footer>
|
</footer>
|
||||||
|
|
|
@ -20,7 +20,7 @@ Route::get('/', function () {
|
||||||
'timeout' => 3.0
|
'timeout' => 3.0
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$response = $client->get('trip/'.config('app.trip').'/user/zmld8ko6qy7d9j3xvq10/json');
|
$response = $client->get('trip/q0mwldvenxq09p2x18nj/user/zmld8ko6qy7d9j3xvq10/json');
|
||||||
|
|
||||||
if ($response->getStatusCode() == 200) {
|
if ($response->getStatusCode() == 200) {
|
||||||
$data = json_decode($response->getBody());
|
$data = json_decode($response->getBody());
|
||||||
|
|
Loading…
Reference in a new issue