|
129 | 129 | pushed_at = self.parsePushedDate( repo.pushed_at ),
|
130 | 130 | repo_url = self.parseRepositoryURL( repo.url );
|
131 | 131 |
|
132 |
| - return $( $.parseHTML(" \ |
133 |
| - <div class='github-box'> \ |
134 |
| - <div class='github-box-header'> \ |
135 |
| - <h3> \ |
136 |
| - <a href='" + repo_url + "'>" + repo.name + "</a> \ |
137 |
| - </h3> \ |
138 |
| - <div class='github-stats'> \ |
139 |
| - <a class='repo-stars' title='Stars' data-icon='7' href='" + repo_url + "/watchers'>" + repo.watchers + "</a> \ |
140 |
| - <a class='repo-forks' title='Forks' data-icon='f' href='" + repo_url + "/network'>" + repo.forks + "</a> \ |
141 |
| - <a class='repo-issues' title='Issues' data-icon='i' href='" + repo_url + "/issues'>" + repo.open_issues + "</a> \ |
142 |
| - </div> \ |
143 |
| - </div> \ |
144 |
| - <div class='github-box-content'> \ |
145 |
| - <p>" + repo.description + " — <a href='" + repo_url + "#readme'>Read More</a></p> \ |
146 |
| - </div> \ |
147 |
| - <div class='github-box-download'> \ |
148 |
| - <p class='repo-update'>Latest commit to <strong>master</strong> on " + pushed_at + "</p> \ |
149 |
| - <a class='repo-download' title='Download as zip' data-icon='w' href='" + repo_url + "/zipball/master'></a> \ |
150 |
| - </div> \ |
151 |
| - </div> \ |
152 |
| - ") ); |
| 132 | + return $( |
| 133 | + "<div class='github-box'>" + |
| 134 | + "<div class='github-box-header'>" + |
| 135 | + "<h3>" + |
| 136 | + "<a href='" + repo_url + "'>" + repo.name + "</a>" + |
| 137 | + "</h3>" + |
| 138 | + "<div class='github-stats'>" + |
| 139 | + "<a class='repo-stars' title='Stars' data-icon='7' href='" + repo_url + "/watchers'>" + repo.watchers + "</a>" + |
| 140 | + "<a class='repo-forks' title='Forks' data-icon='f' href='" + repo_url + "/network'>" + repo.forks + "</a>" + |
| 141 | + "<a class='repo-issues' title='Issues' data-icon='i' href='" + repo_url + "/issues'>" + repo.open_issues + "</a>" + |
| 142 | + "</div>" + |
| 143 | + "</div>" + |
| 144 | + "<div class='github-box-content'>" + |
| 145 | + "<p>" + repo.description + " — <a href='" + repo_url + "#readme'>Read More</a></p>" + |
| 146 | + "</div>" + |
| 147 | + "<div class='github-box-download'>" + |
| 148 | + "<p class='repo-update'>Latest commit to <strong>master</strong> on " + pushed_at + "</p>" + |
| 149 | + "<a class='repo-download' title='Download as zip' data-icon='w' href='" + repo_url + "/zipball/master'></a>" + |
| 150 | + "</div>" + |
| 151 | + "</div>"); |
153 | 152 | };
|
154 | 153 |
|
155 | 154 | // Request repositories from Github
|
|
173 | 172 | });
|
174 | 173 | };
|
175 | 174 |
|
176 |
| - $.fn[ pluginName ] = function ( options ) { |
| 175 | + $.fn[pluginName] = function ( options ) { |
177 | 176 | return this.each(function () {
|
178 |
| - if ( !$.data( this, "plugin_" + pluginName ) ) { |
179 |
| - $.data( this, "plugin_" + pluginName, new Plugin( this, options ) ); |
| 177 | + if ( !$( this ).data( "plugin_" + pluginName ) ) { |
| 178 | + $( this ).data( "plugin_" + pluginName, new Plugin( this, options ) ); |
180 | 179 | }
|
181 | 180 | });
|
182 | 181 | };
|
183 | 182 |
|
184 |
| -}( jQuery, window ) ); |
| 183 | +}( window.jQuery || window.Zepto, window )); |
0 commit comments