View break-word.css
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
.break-word{ | |
-ms-word-break: break-all; | |
word-break: break-all; | |
/*Non standard for webkit*/ | |
word-break: break-word; | |
-webkit-hyphens: auto; | |
-moz-hyphens: auto; | |
hyphens: auto; |
View EnumDropDownList.cs
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
namespace System.Web.Mvc | |
{ | |
#region Using | |
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.Mvc.Html; | |
using System.ComponentModel; | |
using System.Linq.Expressions; |
View pre-wrap.css
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
/* Browser specific (not valid) styles to make preformatted text wrap */ | |
pre { | |
white-space: pre-wrap; /* css-3 */ | |
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ | |
white-space: -pre-wrap; /* Opera 4-6 */ | |
white-space: -o-pre-wrap; /* Opera 7 */ | |
word-wrap: break-word; /* Internet Explorer 5.5+ */ | |
} |
View jQuery.MultiGetScript.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
(function ($) { | |
/** | |
* Multiple parallel getScript with caching. | |
* | |
* @param {Array|String} url (one or more URLs) | |
* @param callback fn (oncomplete, optional) | |
* @returns {function} | |
*/ | |
$.getCachedScript = function (url, callback) { |
View AsyncIoExtensions.cs
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
// License: CPOL at http://www.codeproject.com/info/cpol10.aspx | |
using System.Collections.Generic; | |
using System.Net; | |
using System.Threading; | |
using System.Threading.Tasks; | |
namespace System.IO | |
{ | |
public static class AsyncIoExtensions | |
{ |
View CamelCase.cs
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
namespace UmbracoBootstrap.Infrastructure.Extensions | |
{ | |
#region Using | |
using System.Diagnostics.CodeAnalysis; | |
#endregion | |
/// <summary> | |
/// Encapsulates a series of time saving extension methods to <see cref="T:System.String">String</see>s. | |
/// </summary> | |
public static class StringExtensions |
View getVendorPropertyName.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
getVendorPropertyName = function (prop) { | |
/// <summary>Gets the correct vendor property name for the current browser.</summary> | |
/// <param name="prop" type="String">The property to return the name for.</param> | |
/// <returns type="String">The correct vendor property name.</returns> | |
var el = document.createElement("div"); | |
if (prop in el.style) { | |
return prop; | |
} |
View centered-image.css
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
/* | |
* 1: Arbitrary width. | |
*/ | |
.parent { | |
position: relative; | |
height: 250px; | |
max-width: 400px; /* 1 */ | |
overflow: hidden; | |
} |
View gulpfile.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
// The aim is to get a folder of svg files and somehow package them in a single file as data uri | |
var gulp = require('gulp'); | |
var svgmin = require('gulp-svgmin'); | |
gulp.task('default', function() { | |
return gulp.src('.in/*.svg') | |
.pipe(svgmin()) | |
.pipe(gulp.dest('./out')); | |
}); |
View domchanged.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
// The idea. Ensure that widgets are initialized when they are dynamically loaded into a page. | |
// First override the core html method in the jQuery object to allow us to trigger a custom event. | |
(function($, old){ | |
$.fn.html = function(){ | |
// Execute the original HTML method using the | |
// augmented arguments collection. | |
var result = old.apply(this, arguments); | |
OlderNewer