Added tslint file

This commit is contained in:
Jacob Larsson
2017-09-05 15:24:30 +02:00
parent 6fcd8b0458
commit 808be45e1b
3 changed files with 10 additions and 4 deletions

View File

@@ -23,7 +23,7 @@ $.fancybox.update();
$.fancybox.toggle();
$.fancybox.showLoading();
$.fancybox.hideLoading();
$(".selector").fancybox({ 'type': 'image' });
$(".selector").fancybox({ type: 'image' });
$("#single_1").fancybox({
helpers: {
title: {
@@ -114,7 +114,7 @@ $(".fancybox").fancybox({
});
$(".fancybox").fancybox({
beforeLoad: () => {
this.title = 'Image ' + (this.index + 1) + ' of ' + this.group.length + (this.title ? ' - ' + this.title : '');
this.title = this.title ? `Image ${this.index + 1} of ${this.group.length} - ${this.title}` : `Image ${this.index + 1} of ${this.group.length}`;
}
});
$.fancybox('<div><h1>Lorem Lipsum</h1><p>Lorem lipsum</p></div>', {
@@ -142,4 +142,4 @@ $.fancybox([
$(".fancybox").fancybox({
margin: [20, 60, 20, 60]
});
});

View File

@@ -4,7 +4,6 @@
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
/// <reference types="jquery" />
interface FancyboxOptions extends FancyboxCallback {

View File

@@ -0,0 +1,7 @@
{
"extends": "dtslint/dt.json",
"rules": {
"ban-types": false,
"unified-signatures": false
}
}