You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
933 B
1 lines
933 B
var EXPO=EXPO||{};EXPO.place=EXPO.place||{},EXPO.place.object?console.warn("WARNING: EXPO.place.object is already defined!"):EXPO.place.object=function(){var t={},i=function(t,i){this.$annotation=$("."+t.annotationClass,i),this.$fullPart=$("."+t.fullPartClass,i),this.$readMore=$("."+t.readMoreClass,i),this.cutLength=t.cutLength,this.fullText,this.init()};return i.prototype={init:function(){var t=this,i=this.$annotation.html().slice(0,t.cutLength);this.fullText=this.$annotation.html(),this.$annotation.html(i+"..."),this.$fullPart.html(this.fullText)},showMore:function(){this.$readMore.hide(),this.$annotation.hide(),this.$fullPart.removeClass("hidden")},_cutAnnotation:function(){}},t.opt={},$(function(){}),t.init=function(t){$.extend(this.opt,t);var n=this;this.articles=[],$("."+n.opt.article.class).each(function(){var t=new i(n.opt.article,this);t.$readMore.on("click",function(){t.showMore()}),n.articles.push(t)})},t}(); |