Like SystemiConnectFri 15 Oct 2021, 04:50
Auto Save MessagesLGforumFri 26 Feb 2021, 13:31
New tutorial questionTheCrowMon 15 Feb 2021, 08:12
Support iOS Emojis (and other platforms)LGforumSun 14 Feb 2021, 01:25
LGforum (2806)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Mr.Easybb (1587)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Bloodbath (745)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Rukiafan (533)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Dom (513)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
puppycheese (446)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
pedro (330)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Neymar (301)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Hitsu (281)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 
Flora (275)
[PLUG-IN] Overlay outside of AWC Vote_lcap[PLUG-IN] Overlay outside of AWC Voting_bar[PLUG-IN] Overlay outside of AWC Vote_rcap 


[PLUG-IN] Overlay outside of AWC

LGforumLGforum
Status : Working to restore AWC!

Posts : 2806
Join date : 2011-10-05
Age : 30
Location : UK
Tue 04 Jun 2013, 13:58
This is a very simple plug-in which will add an overlay to your forum when AWC is opened. The overlay is a stylish tranparant white (for dark boards, I'd recommend changing it to black).
This pulls focus on the chatbox, and overall just looks pretty cool to your users. Additionally, clicking on the overlay, will close the chatbox and go back into your forum.

Here's the plug in, just a small code adding 2 event handlers to AWC, utilizing the onopen and onclose events.
[bspoiler=Versions 1.6-1.8]
Code:
[panda=js]avacweb_chat_config.add_event('onopen', function() {
   var o = document.getElementById('awc-overlay');
   if(!o) {
      o = document.createElement('div');
      o.id = 'awc-overlay';
      document.body.appendChild(o);
      $(o).click(function() { avacweb_chat.toggle(); });
   }
   o.style.display = '';
});
avacweb_chat_config.add_event('onclose', function() {
   var o = document.getElementById('awc-overlay');
   if(o) o.style.display = 'none';
});
[/bspoiler]

[bspoiler=Version 1.9+]
Code:
[panda=js]avacweb_chat_config.add_event('onopen', function() {
   var o = document.getElementById('awc-overlay');
   if(!o) {
      o = document.createElement('div');
      o.id = 'awc-overlay';
      document.body.appendChild(o);
      $(o).click(function() { avacweb_chat.settings.toggle('open'); });
   }
   o.style.display = '';
});
avacweb_chat_config.add_event('onclose', function() {
   var o = document.getElementById('awc-overlay');
   if(o) o.style.display = 'none';
});
[/bspoiler]

Then to style the overlay, use this CSS:
Code:
[panda=css]#awc-overlay {
    -moz-opacity: 0.5;
    -webkit-opacity: 0.5;
    background: #FFF; /* CHange this to #000 for darker themed boards */
    filter: alpha(opacity=50);
    min-height: 100%;
    left: 0;
    opacity: 0.5;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 999;
}
FenderFender
Status : No status yet...

Posts : 32
Join date : 2013-02-26
Tue 04 Jun 2013, 14:27
Nice! Thank You, LG!
puppycheesepuppycheese
Status : No status yet...

Posts : 446
Join date : 2013-02-12
Age : 30
Location : New Jersey
Wed 05 Jun 2013, 20:26
Thank you LG!
ApeApe
Status : loving the new site :)

Posts : 124
Join date : 2012-02-23
Location : UK
Sun 11 May 2014, 14:13
Hi Lg before the new Chat update when clicking on the dark faded overlay the chat window would close but now you have updated the chat Box to 1.9 this no longer works
you have to click the chat box button can you please fix this so we can click the overlay to shut the chat aswell.

Much thanks

Ape.
LGforumLGforum
Status : Working to restore AWC!

Posts : 2806
Join date : 2011-10-05
Age : 30
Location : UK
Sun 11 May 2014, 16:17
I have edited the first post to include a 1.9+ code. Smile
ApeApe
Status : loving the new site :)

Posts : 124
Join date : 2012-02-23
Location : UK
Sun 11 May 2014, 16:46
 cheers Thank you Works like a charm Wink

just like to add love the new chat system it rocks
Ch@lo ValdezCh@lo Valdez
Status : :)

Posts : 218
Join date : 2013-04-21
Age : 48
Location : Mexico City
Thu 05 Mar 2015, 23:02
this plugin works fine with AWC 2.0
Sponsored content