x

Active Group: Uniquez TalkBox

  • General
  • Whispers
  • Groups

Please log-in OR Register to view the Talkbox
Everyone must make a new account!


Some code tweaks for Talkbox

  • 1 Replies
  • 203 Views

0 Members and 1 Guest are viewing this topic.

*

Ak$_

  • *
  • Newbie
  • 3 0
  • Sony #1 Wanted List
Some code tweaks for Talkbox
« : June 13, 17, 05:12 PM »
Hey Star,

Noticed a couple of issues when browsing on the forum on small devices. Especially scrolling through the TB when there's a large conversation being had.
I would recommend adding the following to the "Shouts" div, this will allow that kinetic scrolling (where a flick of the finger sends the element scrolling and it keeps going until eventually slowing down and stopping as if friction is slowing it down) as currently it can take a while to scroll before reaching to the bottom of conversations.
Code: [Select]
@media screen and (max-width: 768px) {
  #shouts {
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
  }
}

For some reason when the TB loads, the #shouts container doesn't auto scroll to the bottom to show the most recent chats on mobile. So you can add this code as a callback after the TB has fetched the chats from the DB and added them as div elements to the page and that issue will be fixed too.
Code: [Select]
var d = $('#shouts');
d.scrollTop(d.prop("scrollHeight"));

Also I would recommend stacking the mediabox above the chatbox on smaller devices so that the conversations don't get squashed side by side by using the following css code
Code: [Select]
@media screen and (max-width: 768px) {
  #mbox {
    float: none;
    max-width: auto;
    margin-bottom: 1px;
  }

  #mbox iframe {
    width: 100%;
  }
}

*

oOo--STAR--oOo

  • *
  • Full Member
  • Founder
  • 140 40
  • Nostradamus feeling super marvellous.
Re: Some code tweaks for Talkbox
« Reply #1: June 23, 17, 07:26 PM »
Hey awesome suggestions, I'm going to apply them shortly. Sorry for the delay in the response been busy in life :). It's good to see fresh hands
You can't fool a sufficiently talented fool!