Added page for Lucy
This commit is contained in:
@@ -1,13 +1,48 @@
|
||||
openPerson = false
|
||||
|
||||
$(() => {
|
||||
// Detect page URL
|
||||
path = window.location.pathname.replace(/\//g, '')
|
||||
if (path == 'jason' || path == 'flo' || path == 'lucy') {
|
||||
// A specific path has been set. Display the profile for that person
|
||||
openPerson = path
|
||||
|
||||
// CHANGE THE DISPLAY HERE FOR JASON / FLO
|
||||
|
||||
// Display content for the relevant person, and hide other content
|
||||
$('.main.not' + openPerson).css({
|
||||
width: 0,
|
||||
height: 0,
|
||||
minHeight: 0
|
||||
})
|
||||
|
||||
$('#main-' + openPerson).css('min-height', '100vh')
|
||||
|
||||
$('#splash-' + openPerson).css({
|
||||
width: '50vw',
|
||||
height: '100vh'
|
||||
})
|
||||
|
||||
// Animate the display of links
|
||||
$('#links-' + openPerson).animate({
|
||||
height: $('#links-' + openPerson).get(0).scrollHeight
|
||||
}, {
|
||||
duration: 300,
|
||||
queue: true
|
||||
})
|
||||
}
|
||||
|
||||
// Handle clicks on profile links (by doing nothing)
|
||||
$('a.openlink').click(function(e) {
|
||||
e.preventDefault();
|
||||
})
|
||||
|
||||
// Handle clicks on the banner
|
||||
$('div.banner').click(function() {
|
||||
if (typeof $(this).attr('data-person') == 'undefined') return;
|
||||
|
||||
// If no profile is open, open one...
|
||||
if (!openPerson) {
|
||||
// If no profile is open, open one...
|
||||
openPerson = $(this).attr('data-person')
|
||||
|
||||
if (window.matchMedia('(orientation: portrait)').matches) {
|
||||
|
||||
Reference in New Issue
Block a user