Skip to content

Commit

Permalink
[TASK] use object-fit-images as a component in felayout
Browse files Browse the repository at this point in the history
  • Loading branch information
dmh committed Jun 8, 2018
1 parent 4a7bed6 commit 1b4d57a
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 8 deletions.
6 changes: 6 additions & 0 deletions felayout_t3kit/dev/js/components.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,9 @@
//==============================================================================
@import '../../node_modules/jquery-touchswipe/jquery.touchSwipe.min.js';
//==============================================================================

// Polyfill object-fit/object-position on <img>: IE9, IE10, IE11, Edge, Safari
// https://github.com/bfred-it/object-fit-images
//==============================================================================
@import '../../node_modules/object-fit-images/dist/ofi.js';
//==============================================================================
2 changes: 0 additions & 2 deletions felayout_t3kit/dev/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,4 @@

@import 'main/suggest.js';

@import 'main/ofi.js';

@import 'main/general.js';
4 changes: 4 additions & 0 deletions felayout_t3kit/dev/js/main/general.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// ########## general.js ###########
/* global jQuery */
/* global objectFitImages */

;(function ($) {
'use strict'
Expand Down Expand Up @@ -29,6 +30,9 @@
})
})
}

// call object-fit-images plugin
objectFitImages()
})(jQuery)

// ^^^^^^^^^^ general.js ^^^^^^^^^^^
10 changes: 5 additions & 5 deletions felayout_t3kit/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion felayout_t3kit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"jarallax": "1.9.3",
"jquery": "3.3.1",
"jquery-touchswipe": "1.6.18",
"object-fit-images": "^3.2.3",
"object-fit-images": "3.2.3",
"simplelightbox": "1.12.1",
"smtlk-dotdotdot": "1.8.3",
"swiper": "3.4.2"
Expand Down

0 comments on commit 1b4d57a

Please sign in to comment.