This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function goBack(){ | |
if( document.referrer.indexOf( window.location.host ) !== -1 ) { | |
history.go(-1); | |
} else { | |
window.location.href = window.location.host; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var OWCS_API = (function(){ | |
var editorToolsBody = window.parent.document.body; | |
function Main(){} | |
Main.prototype = { | |
save: function(){ | |
$( '#dijit_form_Button_44', editorToolsBody ).trigger( 'click' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Problem: When I have no control on some ajax or generated html and I need to wait for them. | |
@Solution: Set an interval to check my conditions and them execute a callback. | |
function waitFor ( options ) { | |
options = $.extend( {}, { | |
callback: function(){}, | |
condition: function(){ return true }, | |
interval: 100 | |
}, options); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
["000000", "Black"], | |
["000080", "Navy Blue"], | |
["0000C8", "Dark Blue"], | |
["0000FF", "Blue"], | |
["000741", "Stratos"], | |
["001B1C", "Swamp"], | |
["002387", "Resolution Blue"], | |
["002900", "Deep Fir"], | |
["002E20", "Burnham"], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin linear-gradient( $start: #f1f1f1, $from: 0%, $stop: #d9d9d9, $to: 100% ) { | |
background: $start; | |
background: -webkit-gradient(linear, left top, left bottom, from(ie-hex-str($start)), to(ie-hex-str($stop))); | |
background: -moz-linear-gradient(center top, $start $from, $stop $to); | |
background: -moz-gradient(center top, $start $from, $stop $to); | |
background: -webkit-linear-gradient(top, $start $from,$stop $to); | |
background: -o-linear-gradient(top, $start $from,$stop $to); | |
background: -ms-linear-gradient(top, $start $from,$stop $to); | |
background: linear-gradient(to bottom, $start $from,$stop $to); | |
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#{ie-hex-str($start)}', endColorstr='#{ie-hex-str($stop)}',GradientType=0 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Alterado para atender o Style Guide TQI | |
{ | |
// Details: https://github.com/victorporof/Sublime-HTMLPrettify#using-your-own-jsbeautifyrc-options | |
// Documentation: https://github.com/einars/js-beautify/ | |
"html": { | |
"allowed_file_extensions": ["htm", "html", "xhtml", "shtml", "xml", "svg"], | |
"brace_style": "collapse", // "expand", "end-expand", "expand-strict" | |
"indent_char": " ", | |
"indent_handlebars": false, // e.g. {{#foo}}, {{/foo}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@mixin triangle( $orientation: 'right', $size: 5px, $color: #000000 ) { | |
width: 0; | |
height: 0; | |
$listH: right, left; | |
$listV: up, down; | |
@if index( $listH, $orientation ) { | |
border-top: $size solid transparent; | |
border-bottom: $size solid transparent; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Relatório TQI | |
// @namespace tqi-gp | |
// @description Melhoria na tela de relatórios da TQI | |
// @include https://helpdesk.tqi.com.br/tqiextranet/* | |
// @version 1 | |
// @grant none | |
// @require http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.1/jquery.min.js | |
// @require http://cdnjs.cloudflare.com/ajax/libs/moment.js/2.8.2/moment.min.js | |
// @require http://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.6.0/underscore-min.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$sprite-spacing: 1px; | |
$sprite-normal-map: sprite-map( "normal/*.png", $spacing: $sprite-spacing ); | |
$sprite-normal: sprite-url( $sprite-normal-map ); | |
$sprite-retina-map: sprite-map( "retina/*.png", $spacing: $sprite-spacing ); | |
$sprite-retina: sprite-url( $sprite-retina-map ); | |
@mixin generate-sprite-class( $map, $prefix: 'sprite--' ) { | |
@each $file in sprite-names( $map ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%truncate { | |
white-space: nowrap; | |
overflow: hidden; | |
text-overflow: ellipsis; | |
} | |
@mixin truncate( $width: 100px ) { | |
@extend %truncate; | |
width: $width; | |
} |
OlderNewer