From 418a2cdeb9a3a06d085a6d706c3b8ef1dca53bda Mon Sep 17 00:00:00 2001 From: Romain d'Alverny Date: Sat, 19 May 2012 10:35:14 +0000 Subject: add font-awesome lib --- g/fa/docs/assets/js/index/index.js | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 g/fa/docs/assets/js/index/index.js (limited to 'g/fa/docs/assets/js/index/index.js') diff --git a/g/fa/docs/assets/js/index/index.js b/g/fa/docs/assets/js/index/index.js new file mode 100755 index 000000000..0858f0cf6 --- /dev/null +++ b/g/fa/docs/assets/js/index/index.js @@ -0,0 +1,25 @@ +$(function() { + var MainView = Backbone.View.extend({ + el: $("div.container"), + + modalTemplate: _.template($("#modal-template").html()), + + events:{ + "click ul.the-icons > li": "iconClicked" + }, + + iconClicked: function(event) { + event.preventDefault(); + + var $item = $(event.currentTarget); + var $modal = $(this.modalTemplate({"style": $item.attr("class")})); + + $modal.modal("show"); + $modal.on('hidden', function () { + $modal.remove(); + }) + } + }); + + var mainView = new MainView(); +}); -- cgit v1.2.1