Skip to content

Instantly share code, notes, and snippets.

@bluemango
bluemango / gist:4089182
Created November 16, 2012 17:23
ScreenSteps Live Custom Template that matches the default template
<!DOCTYPE html>
<html>
<head>
<title>{{ page_title }}</title>
<meta content='width=1000px' name='viewport' />
<meta name='keywords' />
<meta content='{{ page_description }}' name='description' />
{{ javascripts }}
@bluemango
bluemango / gist:4080493
Created November 15, 2012 19:01
ScreenSteps Live: Zendesk Custom Template
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "//www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>{{ page_title }}</title>
{{ rss }}
{{ javascripts }}
{{ stylesheets }}
<link href="//assets.zendesk.com/assets/screen.css" media="all" rel="stylesheet" type="text/css" />
@bluemango
bluemango / gist:3308380
Last active October 8, 2015 08:48
ScreenSteps Live Salesforce Home Page Component
<script type="text/javascript">
var screenStepsLivePage = 'enter-url-here';
/*e.g. https://screenstepslive.na3.visual.force.com/apex/ScreenStepsLive_Home*/
</script>
<div id="ScreenStepsLiveHC">
<div id="ScreenStepsLiveHCLessons"></div>
<p id="ScreenStepsLiveHCShowAllContainer" style="display: none;"><a href="#" id="ScreenStepsLiveHCShowAllLessons">View More</a></p>
<h2 id="ScreenStepsLiveHCSearch">Search Tutorials</h2>
<div id="ScreenStepsLiveHCSearchBox">
<form name="srch_solution_sbar" id="ScreenStepsLiveHCSearch-form">
@bluemango
bluemango / gist:3189871
Created July 27, 2012 19:09
ScreenSteps Live CSS for Desk.com
div#screensteps-document h2, div.screensteps-document h2, #support-main div.screensteps-document h3 { margin: .83em 0; }
div#screensteps-document .image img, div.screensteps-document .image img {
padding: 5px 5px 5px 5px;
display: block;
}
div#screensteps-document div.step, div.screensteps-document div.step { clear:both; }
div#screensteps-document .image, div.screensteps-document .image {
@bluemango
bluemango / gist:2558770
Created April 30, 2012 14:25
Insert Sharing HTML
$(document).ready(function() {
if ($('#screensteps-document').length > 0) {
var add_this = $('#add-this-container');
add_this.insertAfter($('#screensteps-breadcrumb'));
add_this.removeClass('hide');
$('#screensteps-steps div.screensteps-next-prev-navigation').before(add_this.html());
}
if ($('#screensteps-content-wrapper.manual-toc').length > 0) {
var add_this = $('#add-this-container');
$('#screensteps-inner-content').append(add_this);
@bluemango
bluemango / gist:1853413
Created February 17, 2012 13:22
Zendesk ScreenSteps Live CSS for nested chapters
#screensteps-content-wrapper #screensteps-sidebar div.screensteps-sidebar-widget#sidebar-chapters .nested-chapter-lessons { margin-left: 0; margin-right:0;}
#screensteps-content-wrapper #screensteps-sidebar .nested-chapter-lessons > li { padding-left:36px; margin-left: -10px; }
#screensteps-content-wrapper #screensteps-sidebar .nested-chapter-lessons > li a { font-weight: normal; }
#screensteps-content-wrapper #screensteps-sidebar .nested-chapter-lessons li.here { background-color: #0064CD; color:white;}
#screensteps-content-wrapper #screensteps-sidebar .nested-chapter-lessons li.here a { font-weight: bold; color: white;}
#screensteps-sidebar #sidebar-chapters li a:hover span.chapter-link {background: url("/images/arrow-chapters-down.png") no-repeat left center;}
@bluemango
bluemango / gist:1540342
Created December 30, 2011 15:39
JS to replace Zendesk Search box with search docs box
jQuery("#search_box").text("Search");
if (jQuery("#suggestion_submit")) {
jQuery("#suggestion_submit").click(function(e){
var search_string = jQuery("#suggestions_query").val();
var query_string = jQuery("#suggestions_query").val().replace(/\s/g,"+");
window.location = "http://help.bluemangolearning.com/searches?text=" + query_string;
return false;
});
};
@bluemango
bluemango / gist:1385907
Created November 22, 2011 15:18
Zendesk CSS using ScreenSteps Live Sidebar
body { background-color: #1E2732; padding: 0 8px; }
div#page a.image-link:hover { text-decoration: none; }
#screensteps-content-wrapper { margin-bottom: 20px; padding-top:20px;}
#screensteps-content-wrapper #screensteps-title-area { padding: 0; border:0;}
#screensteps-content-wrapper ol, #screensteps-content-wrapper ul { margin: 1em 0px; padding-left: 40px;}
'SELECT `lessons`.`id` * 1 + 0 AS `id`,
`spaces`.`id` AS `published_space_id`
FROM lessons
LEFT JOIN readings on lessons.id = readings.lesson_id AND lessons.draft = 0
LEFT JOIN sections on readings.section_id = sections.id AND sections.hidden = 0
LEFT JOIN manuals on manuals.id = sections.manual_id AND manuals.draft = 0
LEFT JOIN assets_spaces as manual_assets ON manual_assets.asset_id = manuals.id AND manual_assets.asset_type = "Manual"
LEFT JOIN spaces ON manual_assets.space_id = spaces.id'
@bluemango
bluemango / gist:1365067
Created November 14, 2011 20:34
Dual searh button for Zendesk/ScreenSteps Live
jQuery("#search_box").text("Search");
if (jQuery("#suggestion_submit")) {
jQuery("#suggestion_submit").val("Search Forums");
var html_string = '<input type="submit" name="commit" value="Search Docs" class="button search primary" id="screensteps-search-submit"/>'
jQuery("#suggestion_submit").before(html_string);
jQuery("#suggestion_submit").removeClass('primary');
jQuery("#screensteps-search-submit").css("margin-left", "0px").before("<br /><br />");
jQuery("#screensteps-search-submit").click(function(e){