Steam Community - Chat Dropdown

Adds dropdown menu in steam profile pages with options to chat through web or steam client

目前為 2016-04-11 提交的版本,檢視 最新版本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Steam Community - Chat Dropdown
// @namespace    Royalgamer06
// @version      0.1
// @description  Adds dropdown menu in steam profile pages with options to chat through web or steam client
// @author       Royalgamer06
// @include      http://steamcommunity.com/profiles/*
// @include      http://steamcommunity.com/id/*
// @grant        none
// ==/UserScript==

if (jQuery('div.profile_header_actions > a > span').text() == 'Send a Message') {
    var steamid = g_rgProfileData.steamid;
    var href = jQuery('div.profile_header_actions > a').attr('href');
    var html = '<span class="btn_profile_action btn_medium" id="profile_chat_dropdown_link" onclick="ShowMenu( this, \'profile_chat_dropdown\', \'right\' );"> <span>Send a Message <img src="http://steamcommunity-a.akamaihd.net/public/images/profile/profile_action_dropdown.png"></span> </span><div class="popup_block" id="profile_chat_dropdown" style="visibility: visible; top: 168px; left: 679px; display: none; opacity: 1;"> <div class="shadow_ul"></div> <div class="shadow_top"></div> <div class="shadow_ur"></div> <div class="shadow_left"></div> <div class="shadow_right"></div> <div class="shadow_bl"></div> <div class="shadow_bottom"></div> <div class="shadow_br"></div> <div class="popup_body popup_menu shadow_content"> <a class="popup_menu_item" href="' + href + '"><img src="//steamcommunity-a.akamaihd.net/public/images/skin_1/icon_btn_comment.png">&nbsp; Web browser chat</a> <a class="popup_menu_item" href="steam://friends/message/' + steamid + '"><img src="//steamcommunity-a.akamaihd.net/public/images/skin_1/icon_btn_comment.png">&nbsp; Steam Client chat</a> </div> </div>';
    jQuery('div.profile_header_actions > a').replaceWith(html);
}