Storefront Sticky Add to Cart - Version 1.1.0

Version Description

Download this release

Release Info

Developer jameskoster
Plugin Icon 128x128 Storefront Sticky Add to Cart
Version 1.1.0
Comparing to
See all releases

Code changes from version 1.0.0 to 1.1.0

assets/css/style.css CHANGED
@@ -38,15 +38,29 @@
38
  max-height: 3.631em;
39
  width: auto;
40
  float: left;
41
- margin: 0 1em 0 0; }
 
 
42
  .ssatc-sticky-add-to-cart .ssatc-content {
43
- position: relative; }
 
 
 
 
 
 
 
 
 
 
44
  .ssatc-sticky-add-to-cart .price,
45
  .ssatc-sticky-add-to-cart .stock {
46
  font-size: .857em;
47
- opacity: 0.75; }
48
- .ssatc-sticky-add-to-cart .button {
49
- margin-top: .53em; }
 
 
50
  .ssatc-sticky-add-to-cart .price {
51
  margin-right: 1em; }
52
 
38
  max-height: 3.631em;
39
  width: auto;
40
  float: left;
41
+ margin: 0 2em 0 0;
42
+ padding: 3px;
43
+ border: 1px solid rgba(0, 0, 0, 0.1); }
44
  .ssatc-sticky-add-to-cart .ssatc-content {
45
+ position: relative;
46
+ line-height: 1.387; }
47
+ .ssatc-sticky-add-to-cart .star-rating {
48
+ display: inline-block;
49
+ font-size: .75em;
50
+ margin-right: 1em;
51
+ -webkit-transform: translateY(1px);
52
+ -moz-transform: translateY(1px);
53
+ -ms-transform: translateY(1px);
54
+ -o-transform: translateY(1px);
55
+ transform: translateY(1px); }
56
  .ssatc-sticky-add-to-cart .price,
57
  .ssatc-sticky-add-to-cart .stock {
58
  font-size: .857em;
59
+ opacity: 0.5; }
60
+ .ssatc-sticky-add-to-cart .button.variable:after {
61
+ content: "\f106";
62
+ font-family: "FontAwesome";
63
+ margin-left: .53em; }
64
  .ssatc-sticky-add-to-cart .price {
65
  margin-right: 1em; }
66
 
assets/css/style.scss CHANGED
@@ -57,21 +57,35 @@
57
  max-height: 3.631em;
58
  width: auto;
59
  float: left;
60
- margin: 0 1em 0 0;
 
 
61
  }
62
 
63
  .ssatc-content {
64
  position: relative;
 
 
 
 
 
 
 
 
65
  }
66
 
67
  .price,
68
  .stock {
69
  font-size: .857em;
70
- opacity: 0.75;
71
  }
72
 
73
- .button {
74
- margin-top: .53em;
 
 
 
 
75
  }
76
 
77
  .price {
57
  max-height: 3.631em;
58
  width: auto;
59
  float: left;
60
+ margin: 0 2em 0 0;
61
+ padding: 3px;
62
+ border: 1px solid rgba(#000,.1);
63
  }
64
 
65
  .ssatc-content {
66
  position: relative;
67
+ line-height: 1.387;
68
+ }
69
+
70
+ .star-rating {
71
+ display: inline-block;
72
+ font-size: .75em;
73
+ margin-right: 1em;
74
+ @include transform(translateY(1px));
75
  }
76
 
77
  .price,
78
  .stock {
79
  font-size: .857em;
80
+ opacity: 0.5;
81
  }
82
 
83
+ .button.variable {
84
+ &:after {
85
+ content: "\f106";
86
+ font-family: "FontAwesome";
87
+ margin-left: .53em;
88
+ }
89
  }
90
 
91
  .price {
assets/js/variable.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function($){
2
+
3
+ jQuery( '.ssatc-content .button.variable' ).click( function() {
4
+ jQuery( 'html, body' ).animate({
5
+ scrollTop: jQuery( 'div.product' ).offset().top - 32
6
+ }, 750 );
7
+ });
8
+
9
+ });
assets/js/variable.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function($){jQuery(".ssatc-content .button.variable").click(function(){jQuery("html, body").animate({scrollTop:jQuery("div.product").offset().top-32},750)})});
changelog.txt CHANGED
@@ -1,4 +1,10 @@
1
  *** Storefront Sticky Add to Cart Changelog ***
2
 
 
 
 
 
 
 
3
  2015.10.29 - version 1.0.0
4
  * Initial release
1
  *** Storefront Sticky Add to Cart Changelog ***
2
 
3
+ 2015.11.06 - version 1.1.0
4
+ * New - Now displays the product rating as well. Kudos @BurlesonBrad.
5
+ * New - Now works for variable products.
6
+ * Tweak - Button now uses the `.alt` class to stand out more.
7
+ * Tweak - Minor style adjustments.
8
+
9
  2015.10.29 - version 1.0.0
10
  * Initial release
config.codekit ADDED
@@ -0,0 +1,908 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "CodeKitInfo": "This is a CodeKit 2.x project configuration file. It is designed to sync project settings across multiple machines. MODIFYING THE CONTENTS OF THIS FILE IS A POOR LIFE DECISION. If you do so, you will likely cause CodeKit to crash. This file is not useful unless accompanied by the project that created it in CodeKit 2. This file is not backwards-compatible with CodeKit 1.x. For more information, see: http:\/\/incident57.com\/codekit",
3
+ "creatorBuild": "19076",
4
+ "files": {
5
+ "\/assets\/css\/style.css": {
6
+ "fileType": 16,
7
+ "ignore": 1,
8
+ "ignoreWasSetByUser": 0,
9
+ "inputAbbreviatedPath": "\/assets\/css\/style.css",
10
+ "outputAbbreviatedPath": "No Output Path",
11
+ "outputPathIsOutsideProject": 0,
12
+ "outputPathIsSetByUser": 0
13
+ },
14
+ "\/assets\/css\/style.scss": {
15
+ "createSourceMap": 0,
16
+ "debugStyle": 0,
17
+ "decimalPrecision": 10,
18
+ "fileType": 4,
19
+ "ignore": 0,
20
+ "ignoreWasSetByUser": 0,
21
+ "inputAbbreviatedPath": "\/assets\/css\/style.scss",
22
+ "outputAbbreviatedPath": "\/assets\/css\/style.css",
23
+ "outputPathIsOutsideProject": 0,
24
+ "outputPathIsSetByUser": 0,
25
+ "outputStyle": 0,
26
+ "shouldRunAutoprefixer": 0,
27
+ "shouldRunBless": 0,
28
+ "useLibsass": 0
29
+ },
30
+ "\/assets\/js\/jquery.waypoints.min.js": {
31
+ "fileType": 64,
32
+ "ignore": 1,
33
+ "ignoreWasSetByUser": 1,
34
+ "inputAbbreviatedPath": "\/assets\/js\/jquery.waypoints.min.js",
35
+ "outputAbbreviatedPath": "\/assets\/js\/min\/jquery.waypoints.min-min.js",
36
+ "outputPathIsOutsideProject": 0,
37
+ "outputPathIsSetByUser": 0,
38
+ "outputStyle": 1,
39
+ "syntaxCheckerStyle": 1
40
+ },
41
+ "\/assets\/js\/variable.js": {
42
+ "fileType": 64,
43
+ "ignore": 0,
44
+ "ignoreWasSetByUser": 0,
45
+ "inputAbbreviatedPath": "\/assets\/js\/variable.js",
46
+ "outputAbbreviatedPath": "\/assets\/js\/variable.min.js",
47
+ "outputPathIsOutsideProject": 0,
48
+ "outputPathIsSetByUser": 1,
49
+ "outputStyle": 1,
50
+ "syntaxCheckerStyle": 1
51
+ },
52
+ "\/assets\/js\/variable.min.js": {
53
+ "fileType": 64,
54
+ "ignore": 1,
55
+ "ignoreWasSetByUser": 0,
56
+ "inputAbbreviatedPath": "\/assets\/js\/variable.min.js",
57
+ "outputAbbreviatedPath": "\/assets\/js\/min\/variable.min-min.js",
58
+ "outputPathIsOutsideProject": 0,
59
+ "outputPathIsSetByUser": 0,
60
+ "outputStyle": 1,
61
+ "syntaxCheckerStyle": 1
62
+ },
63
+ "\/assets\/js\/waypoints.init.js": {
64
+ "fileType": 64,
65
+ "ignore": 0,
66
+ "ignoreWasSetByUser": 0,
67
+ "inputAbbreviatedPath": "\/assets\/js\/waypoints.init.js",
68
+ "outputAbbreviatedPath": "\/assets\/js\/waypoints.init.min.js",
69
+ "outputPathIsOutsideProject": 0,
70
+ "outputPathIsSetByUser": 1,
71
+ "outputStyle": 1,
72
+ "syntaxCheckerStyle": 1
73
+ },
74
+ "\/assets\/js\/waypoints.init.min.js": {
75
+ "fileType": 64,
76
+ "ignore": 1,
77
+ "ignoreWasSetByUser": 0,
78
+ "inputAbbreviatedPath": "\/assets\/js\/waypoints.init.min.js",
79
+ "outputAbbreviatedPath": "\/assets\/js\/min\/waypoints.init.min-min.js",
80
+ "outputPathIsOutsideProject": 0,
81
+ "outputPathIsSetByUser": 0,
82
+ "outputStyle": 1,
83
+ "syntaxCheckerStyle": 1
84
+ },
85
+ "\/index.php": {
86
+ "fileType": 8192,
87
+ "ignore": 0,
88
+ "ignoreWasSetByUser": 0,
89
+ "inputAbbreviatedPath": "\/index.php",
90
+ "outputAbbreviatedPath": "No Output Path",
91
+ "outputPathIsOutsideProject": 0,
92
+ "outputPathIsSetByUser": 0
93
+ },
94
+ "\/storefront-sticky-add-to-cart.php": {
95
+ "fileType": 8192,
96
+ "ignore": 0,
97
+ "ignoreWasSetByUser": 0,
98
+ "inputAbbreviatedPath": "\/storefront-sticky-add-to-cart.php",
99
+ "outputAbbreviatedPath": "No Output Path",
100
+ "outputPathIsOutsideProject": 0,
101
+ "outputPathIsSetByUser": 0
102
+ }
103
+ },
104
+ "hooks": [
105
+ ],
106
+ "lastSavedByUser": "James Koster",
107
+ "manualImportLinks": {
108
+ },
109
+ "projectAttributes": {
110
+ "bowerAbbreviatedPath": "",
111
+ "displayValue": "storefront-sticky-add-to-cart",
112
+ "displayValueWasSetByUser": 0,
113
+ "iconImageName": "compass_blue"
114
+ },
115
+ "projectSettings": {
116
+ "alwaysUseExternalServer": 0,
117
+ "animateCSSInjections": 1,
118
+ "autoApplyPSLanguageSettingsStyle": 0,
119
+ "autoprefixerBrowserString": "> 1%, last 2 versions, Firefox ESR, Opera 12.1",
120
+ "autoSyncProjectSettingsFile": 1,
121
+ "browserRefreshDelay": 0,
122
+ "coffeeAutoOutputPathEnabled": 1,
123
+ "coffeeAutoOutputPathFilenamePattern": "*.js",
124
+ "coffeeAutoOutputPathRelativePath": "",
125
+ "coffeeAutoOutputPathReplace1": "",
126
+ "coffeeAutoOutputPathReplace2": "",
127
+ "coffeeAutoOutputPathStyle": 0,
128
+ "coffeeCreateSourceMap": 0,
129
+ "coffeeLintFlags2": {
130
+ "arrow_spacing": {
131
+ "active": 0,
132
+ "flagValue": -1
133
+ },
134
+ "camel_case_classes": {
135
+ "active": 1,
136
+ "flagValue": -1
137
+ },
138
+ "colon_assignment_spacing": {
139
+ "active": 0,
140
+ "flagValue": 1
141
+ },
142
+ "cyclomatic_complexity": {
143
+ "active": 0,
144
+ "flagValue": 10
145
+ },
146
+ "duplicate_key": {
147
+ "active": 1,
148
+ "flagValue": -1
149
+ },
150
+ "empty_constructor_needs_parens": {
151
+ "active": 0,
152
+ "flagValue": -1
153
+ },
154
+ "ensure_comprehensions": {
155
+ "active": 1,
156
+ "flagValue": -1
157
+ },
158
+ "indentation": {
159
+ "active": 1,
160
+ "flagValue": 2
161
+ },
162
+ "line_endings": {
163
+ "active": 0,
164
+ "flagValue": 0
165
+ },
166
+ "max_line_length": {
167
+ "active": 0,
168
+ "flagValue": 150
169
+ },
170
+ "missing_fat_arrows": {
171
+ "active": 0,
172
+ "flagValue": -1
173
+ },
174
+ "newlines_after_classes": {
175
+ "active": 0,
176
+ "flagValue": 3
177
+ },
178
+ "no_backticks": {
179
+ "active": 1,
180
+ "flagValue": -1
181
+ },
182
+ "no_debugger": {
183
+ "active": 1,
184
+ "flagValue": -1
185
+ },
186
+ "no_empty_functions": {
187
+ "active": 0,
188
+ "flagValue": -1
189
+ },
190
+ "no_empty_param_list": {
191
+ "active": 0,
192
+ "flagValue": -1
193
+ },
194
+ "no_implicit_braces": {
195
+ "active": 1,
196
+ "flagValue": -1
197
+ },
198
+ "no_implicit_parens": {
199
+ "active": 0,
200
+ "flagValue": -1
201
+ },
202
+ "no_interpolation_in_single_quotes": {
203
+ "active": 0,
204
+ "flagValue": -1
205
+ },
206
+ "no_plusplus": {
207
+ "active": 0,
208
+ "flagValue": -1
209
+ },
210
+ "no_stand_alone_at": {
211
+ "active": 1,
212
+ "flagValue": -1
213
+ },
214
+ "no_tabs": {
215
+ "active": 1,
216
+ "flagValue": -1
217
+ },
218
+ "no_throwing_strings": {
219
+ "active": 1,
220
+ "flagValue": -1
221
+ },
222
+ "no_trailing_semicolons": {
223
+ "active": 1,
224
+ "flagValue": -1
225
+ },
226
+ "no_trailing_whitespace": {
227
+ "active": 1,
228
+ "flagValue": -1
229
+ },
230
+ "no_unnecessary_double_quotes": {
231
+ "active": 0,
232
+ "flagValue": -1
233
+ },
234
+ "no_unnecessary_fat_arrows": {
235
+ "active": 1,
236
+ "flagValue": -1
237
+ },
238
+ "non_empty_constructor_needs_parens": {
239
+ "active": 0,
240
+ "flagValue": -1
241
+ },
242
+ "prefer_english_operator": {
243
+ "active": 0,
244
+ "flagValue": -1
245
+ },
246
+ "space_operators": {
247
+ "active": 0,
248
+ "flagValue": -1
249
+ },
250
+ "spacing_after_comma": {
251
+ "active": 1,
252
+ "flagValue": -1
253
+ }
254
+ },
255
+ "coffeeMinifyOutput": 1,
256
+ "coffeeOutputStyle": 0,
257
+ "coffeeSyntaxCheckerStyle": 1,
258
+ "externalServerAddress": "http:\/\/localhost:8888",
259
+ "externalServerPreviewPathAddition": "",
260
+ "genericWebpageFileExtensionsString": "html, htm, shtml, shtm, xhtml, php, jsp, asp, aspx, erb, ctp",
261
+ "hamlAutoOutputPathEnabled": 1,
262
+ "hamlAutoOutputPathFilenamePattern": "*.html",
263
+ "hamlAutoOutputPathRelativePath": "",
264
+ "hamlAutoOutputPathReplace1": "",
265
+ "hamlAutoOutputPathReplace2": "",
266
+ "hamlAutoOutputPathStyle": 0,
267
+ "hamlEscapeHTMLCharacters": 0,
268
+ "hamlNoEscapeInAttributes": 0,
269
+ "hamlOutputFormat": 2,
270
+ "hamlOutputStyle": 0,
271
+ "hamlUseCDATA": 0,
272
+ "hamlUseDoubleQuotes": 0,
273
+ "hamlUseUnixNewlines": 0,
274
+ "jadeAutoOutputPathEnabled": 1,
275
+ "jadeAutoOutputPathFilenamePattern": "*.html",
276
+ "jadeAutoOutputPathRelativePath": "",
277
+ "jadeAutoOutputPathReplace1": "",
278
+ "jadeAutoOutputPathReplace2": "",
279
+ "jadeAutoOutputPathStyle": 0,
280
+ "jadeCompileDebug": 1,
281
+ "jadeOutputStyle": 0,
282
+ "javascriptAutoOutputPathEnabled": 1,
283
+ "javascriptAutoOutputPathFilenamePattern": "*-min.js",
284
+ "javascriptAutoOutputPathRelativePath": "\/min",
285
+ "javascriptAutoOutputPathReplace1": "",
286
+ "javascriptAutoOutputPathReplace2": "",
287
+ "javascriptAutoOutputPathStyle": 2,
288
+ "javascriptCreateSourceMap": 1,
289
+ "javascriptOutputStyle": 1,
290
+ "javascriptSyntaxCheckerStyle": 1,
291
+ "jsCheckerReservedNamesString": "",
292
+ "jsHintFlags2": {
293
+ "asi": {
294
+ "active": 0,
295
+ "flagValue": -1
296
+ },
297
+ "bitwise": {
298
+ "active": 1,
299
+ "flagValue": -1
300
+ },
301
+ "boss": {
302
+ "active": 0,
303
+ "flagValue": -1
304
+ },
305
+ "browser": {
306
+ "active": 1,
307
+ "flagValue": -1
308
+ },
309
+ "browserify": {
310
+ "active": 0,
311
+ "flagValue": -1
312
+ },
313
+ "camelcase": {
314
+ "active": 0,
315
+ "flagValue": -1
316
+ },
317
+ "couch": {
318
+ "active": 0,
319
+ "flagValue": -1
320
+ },
321
+ "curly": {
322
+ "active": 1,
323
+ "flagValue": -1
324
+ },
325
+ "debug": {
326
+ "active": 0,
327
+ "flagValue": -1
328
+ },
329
+ "devel": {
330
+ "active": 0,
331
+ "flagValue": -1
332
+ },
333
+ "dojo": {
334
+ "active": 0,
335
+ "flagValue": -1
336
+ },
337
+ "elision": {
338
+ "active": 1,
339
+ "flagValue": -1
340
+ },
341
+ "eqeqeq": {
342
+ "active": 1,
343
+ "flagValue": -1
344
+ },
345
+ "eqnull": {
346
+ "active": 0,
347
+ "flagValue": -1
348
+ },
349
+ "es3": {
350
+ "active": 0,
351
+ "flagValue": -1
352
+ },
353
+ "esnext": {
354
+ "active": 0,
355
+ "flagValue": -1
356
+ },
357
+ "evil": {
358
+ "active": 0,
359
+ "flagValue": -1
360
+ },
361
+ "expr": {
362
+ "active": 0,
363
+ "flagValue": -1
364
+ },
365
+ "forin": {
366
+ "active": 0,
367
+ "flagValue": -1
368
+ },
369
+ "freeze": {
370
+ "active": 1,
371
+ "flagValue": -1
372
+ },
373
+ "funcscope": {
374
+ "active": 0,
375
+ "flagValue": -1
376
+ },
377
+ "futurehostile": {
378
+ "active": 0,
379
+ "flagValue": -1
380
+ },
381
+ "globalstrict": {
382
+ "active": 0,
383
+ "flagValue": -1
384
+ },
385
+ "immed": {
386
+ "active": 0,
387
+ "flagValue": -1
388
+ },
389
+ "indent": {
390
+ "active": 0,
391
+ "flagValue": 4
392
+ },
393
+ "iterator": {
394
+ "active": 0,
395
+ "flagValue": -1
396
+ },
397
+ "jasmine": {
398
+ "active": 0,
399
+ "flagValue": -1
400
+ },
401
+ "jquery": {
402
+ "active": 1,
403
+ "flagValue": -1
404
+ },
405
+ "lastsemic": {
406
+ "active": 0,
407
+ "flagValue": -1
408
+ },
409
+ "latedef": {
410
+ "active": 1,
411
+ "flagValue": -1
412
+ },
413
+ "laxbreak": {
414
+ "active": 0,
415
+ "flagValue": -1
416
+ },
417
+ "laxcomma": {
418
+ "active": 0,
419
+ "flagValue": -1
420
+ },
421
+ "loopfunc": {
422
+ "active": 0,
423
+ "flagValue": -1
424
+ },
425
+ "maxcomplexity": {
426
+ "active": 0,
427
+ "flagValue": 10
428
+ },
429
+ "maxdepth": {
430
+ "active": 0,
431
+ "flagValue": 3
432
+ },
433
+ "maxlen": {
434
+ "active": 0,
435
+ "flagValue": 150
436
+ },
437
+ "maxparams": {
438
+ "active": 0,
439
+ "flagValue": 3
440
+ },
441
+ "maxstatements": {
442
+ "active": 0,
443
+ "flagValue": 4
444
+ },
445
+ "mocha": {
446
+ "active": 0,
447
+ "flagValue": -1
448
+ },
449
+ "mootools": {
450
+ "active": 0,
451
+ "flagValue": -1
452
+ },
453
+ "moz": {
454
+ "active": 0,
455
+ "flagValue": -1
456
+ },
457
+ "multistr": {
458
+ "active": 0,
459
+ "flagValue": -1
460
+ },
461
+ "newcap": {
462
+ "active": 1,
463
+ "flagValue": -1
464
+ },
465
+ "noarg": {
466
+ "active": 1,
467
+ "flagValue": -1
468
+ },
469
+ "nocomma": {
470
+ "active": 0,
471
+ "flagValue": -1
472
+ },
473
+ "node": {
474
+ "active": 0,
475
+ "flagValue": -1
476
+ },
477
+ "noempty": {
478
+ "active": 0,
479
+ "flagValue": -1
480
+ },
481
+ "nonbsp": {
482
+ "active": 0,
483
+ "flagValue": -1
484
+ },
485
+ "nonew": {
486
+ "active": 1,
487
+ "flagValue": -1
488
+ },
489
+ "nonstandard": {
490
+ "active": 0,
491
+ "flagValue": -1
492
+ },
493
+ "notypeof": {
494
+ "active": 1,
495
+ "flagValue": -1
496
+ },
497
+ "noyield": {
498
+ "active": 0,
499
+ "flagValue": -1
500
+ },
501
+ "onecase": {
502
+ "active": 0,
503
+ "flagValue": -1
504
+ },
505
+ "phantom": {
506
+ "active": 0,
507
+ "flagValue": -1
508
+ },
509
+ "plusplus": {
510
+ "active": 0,
511
+ "flagValue": -1
512
+ },
513
+ "proto": {
514
+ "active": 0,
515
+ "flagValue": -1
516
+ },
517
+ "prototypejs": {
518
+ "active": 0,
519
+ "flagValue": -1
520
+ },
521
+ "qunit": {
522
+ "active": 0,
523
+ "flagValue": -1
524
+ },
525
+ "regexp": {
526
+ "active": 1,
527
+ "flagValue": -1
528
+ },
529
+ "rhino": {
530
+ "active": 0,
531
+ "flagValue": -1
532
+ },
533
+ "scripturl": {
534
+ "active": 0,
535
+ "flagValue": -1
536
+ },
537
+ "shadow": {
538
+ "active": 0,
539
+ "flagValue": -1
540
+ },
541
+ "shelljs": {
542
+ "active": 0,
543
+ "flagValue": -1
544
+ },
545
+ "singleGroups": {
546
+ "active": 0,
547
+ "flagValue": -1
548
+ },
549
+ "strict": {
550
+ "active": 0,
551
+ "flagValue": -1
552
+ },
553
+ "sub": {
554
+ "active": 0,
555
+ "flagValue": -1
556
+ },
557
+ "supernew": {
558
+ "active": 0,
559
+ "flagValue": -1
560
+ },
561
+ "typed": {
562
+ "active": 0,
563
+ "flagValue": -1
564
+ },
565
+ "undef": {
566
+ "active": 1,
567
+ "flagValue": -1
568
+ },
569
+ "unused": {
570
+ "active": 1,
571
+ "flagValue": -1
572
+ },
573
+ "varstmt": {
574
+ "active": 0,
575
+ "flagValue": -1
576
+ },
577
+ "withstmt": {
578
+ "active": 0,
579
+ "flagValue": -1
580
+ },
581
+ "worker": {
582
+ "active": 0,
583
+ "flagValue": -1
584
+ },
585
+ "wsh": {
586
+ "active": 0,
587
+ "flagValue": -1
588
+ },
589
+ "yui": {
590
+ "active": 0,
591
+ "flagValue": -1
592
+ }
593
+ },
594
+ "jsLintFlags2": {
595
+ "bitwise": {
596
+ "active": 0,
597
+ "flagValue": -1
598
+ },
599
+ "browser": {
600
+ "active": 1,
601
+ "flagValue": -1
602
+ },
603
+ "couch": {
604
+ "active": 0,
605
+ "flagValue": -1
606
+ },
607
+ "devel": {
608
+ "active": 0,
609
+ "flagValue": -1
610
+ },
611
+ "es6": {
612
+ "active": 0,
613
+ "flagValue": -1
614
+ },
615
+ "eval": {
616
+ "active": 0,
617
+ "flagValue": -1
618
+ },
619
+ "for": {
620
+ "active": 0,
621
+ "flagValue": -1
622
+ },
623
+ "maxlen": {
624
+ "active": 0,
625
+ "flagValue": 150
626
+ },
627
+ "node": {
628
+ "active": 0,
629
+ "flagValue": -1
630
+ },
631
+ "this": {
632
+ "active": 0,
633
+ "flagValue": -1
634
+ },
635
+ "white": {
636
+ "active": 0,
637
+ "flagValue": -1
638
+ }
639
+ },
640
+ "jsonAutoOutputPathEnabled": 0,
641
+ "jsonAutoOutputPathFilenamePattern": "*-min.json",
642
+ "jsonAutoOutputPathRelativePath": "",
643
+ "jsonAutoOutputPathReplace1": "",
644
+ "jsonAutoOutputPathReplace2": "",
645
+ "jsonAutoOutputPathStyle": 0,
646
+ "jsonOrderOutput": 0,
647
+ "jsonOutputStyle": 1,
648
+ "kitAutoOutputPathEnabled": 1,
649
+ "kitAutoOutputPathFilenamePattern": "*.html",
650
+ "kitAutoOutputPathRelativePath": "",
651
+ "kitAutoOutputPathReplace1": "",
652
+ "kitAutoOutputPathReplace2": "",
653
+ "kitAutoOutputPathStyle": 0,
654
+ "lessAllowInsecureImports": 0,
655
+ "lessAutoOutputPathEnabled": 1,
656
+ "lessAutoOutputPathFilenamePattern": "*.css",
657
+ "lessAutoOutputPathRelativePath": "..\/css",
658
+ "lessAutoOutputPathReplace1": "less",
659
+ "lessAutoOutputPathReplace2": "css",
660
+ "lessAutoOutputPathStyle": 2,
661
+ "lessCreateSourceMap": 0,
662
+ "lessDisableJavascript": 0,
663
+ "lessIeCompatibility": 1,
664
+ "lessOutputStyle": 0,
665
+ "lessRelativeURLS": 0,
666
+ "lessStrictImports": 0,
667
+ "lessStrictMath": 0,
668
+ "lessStrictUnits": 0,
669
+ "markdownAutoOutputPathEnabled": 1,
670
+ "markdownAutoOutputPathFilenamePattern": "*.html",
671
+ "markdownAutoOutputPathRelativePath": "",
672
+ "markdownAutoOutputPathReplace1": "",
673
+ "markdownAutoOutputPathReplace2": "",
674
+ "markdownAutoOutputPathStyle": 0,
675
+ "markdownCriticStyle": 0,
676
+ "markdownEnableFootnotes": 1,
677
+ "markdownEnableLabels": 1,
678
+ "markdownEnableSmartQuotes": 1,
679
+ "markdownEscapeLineBreaks": 0,
680
+ "markdownMaskEmailAddresses": 1,
681
+ "markdownOutputFormat": 0,
682
+ "markdownOutputStyle": 0,
683
+ "markdownParseMetadata": 1,
684
+ "markdownProcessHTML": 0,
685
+ "markdownRandomFootnoteNumbers": 0,
686
+ "markdownUseCompatibilityMode": 0,
687
+ "reloadFileURLs": 0,
688
+ "sassAutoOutputPathEnabled": 1,
689
+ "sassAutoOutputPathFilenamePattern": "*.css",
690
+ "sassAutoOutputPathRelativePath": "..\/css",
691
+ "sassAutoOutputPathReplace1": "sass",
692
+ "sassAutoOutputPathReplace2": "css",
693
+ "sassAutoOutputPathStyle": 2,
694
+ "sassCreateSourceMap": 0,
695
+ "sassDebugStyle": 0,
696
+ "sassDecimalPrecision": 10,
697
+ "sassOutputStyle": 0,
698
+ "sassUseLibsass": 0,
699
+ "shouldRunAutoprefixer": 0,
700
+ "shouldRunBless": 0,
701
+ "skippedItemsString": ".svn, .git, .hg, log, _logs, _cache, cache, logs, node_modules",
702
+ "slimAutoOutputPathEnabled": 1,
703
+ "slimAutoOutputPathFilenamePattern": "*.html",
704
+ "slimAutoOutputPathRelativePath": "",
705
+ "slimAutoOutputPathReplace1": "",
706
+ "slimAutoOutputPathReplace2": "",
707
+ "slimAutoOutputPathStyle": 0,
708
+ "slimCompileOnly": 0,
709
+ "slimLogicless": 0,
710
+ "slimOutputFormat": 0,
711
+ "slimOutputStyle": 1,
712
+ "slimRailsCompatible": 0,
713
+ "stylusAutoOutputPathEnabled": 1,
714
+ "stylusAutoOutputPathFilenamePattern": "*.css",
715
+ "stylusAutoOutputPathRelativePath": "..\/css",
716
+ "stylusAutoOutputPathReplace1": "stylus",
717
+ "stylusAutoOutputPathReplace2": "css",
718
+ "stylusAutoOutputPathStyle": 2,
719
+ "stylusCreateSourceMap": 0,
720
+ "stylusDebugStyle": 0,
721
+ "stylusImportCSS": 0,
722
+ "stylusOutputStyle": 0,
723
+ "stylusResolveRelativeURLS": 0,
724
+ "typescriptAutoOutputPathEnabled": 1,
725
+ "typescriptAutoOutputPathFilenamePattern": "*.js",
726
+ "typescriptAutoOutputPathRelativePath": "\/js",
727
+ "typescriptAutoOutputPathReplace1": "",
728
+ "typescriptAutoOutputPathReplace2": "",
729
+ "typescriptAutoOutputPathStyle": 2,
730
+ "typescriptCreateDeclarationFile": 0,
731
+ "typescriptCreateSourceMap": 0,
732
+ "typescriptJSXMode": 0,
733
+ "typescriptMinifyOutput": 0,
734
+ "typescriptModuleResolutionType": 0,
735
+ "typescriptModuleType": 0,
736
+ "typescriptNoImplicitAny": 0,
737
+ "typescriptPreserveConstEnums": 0,
738
+ "typescriptRemoveComments": 0,
739
+ "typescriptSuppressImplicitAnyIndexErrors": 0,
740
+ "typescriptTargetECMAVersion": 0,
741
+ "uglifyDefinesString": "",
742
+ "uglifyFlags2": {
743
+ "ascii-only": {
744
+ "active": 0,
745
+ "flagValue": -1
746
+ },
747
+ "bare-returns": {
748
+ "active": 0,
749
+ "flagValue": -1
750
+ },
751
+ "booleans": {
752
+ "active": 1,
753
+ "flagValue": -1
754
+ },
755
+ "bracketize": {
756
+ "active": 0,
757
+ "flagValue": -1
758
+ },
759
+ "cascade": {
760
+ "active": 1,
761
+ "flagValue": -1
762
+ },
763
+ "comments": {
764
+ "active": 1,
765
+ "flagValue": -1
766
+ },
767
+ "comparisons": {
768
+ "active": 1,
769
+ "flagValue": -1
770
+ },
771
+ "compress": {
772
+ "active": 1,
773
+ "flagValue": -1
774
+ },
775
+ "conditionals": {
776
+ "active": 1,
777
+ "flagValue": -1
778
+ },
779
+ "dead_code": {
780
+ "active": 0,
781
+ "flagValue": -1
782
+ },
783
+ "drop_console": {
784
+ "active": 0,
785
+ "flagValue": -1
786
+ },
787
+ "drop_debugger": {
788
+ "active": 1,
789
+ "flagValue": -1
790
+ },
791
+ "eval": {
792
+ "active": 0,
793
+ "flagValue": -1
794
+ },
795
+ "evaluate": {
796
+ "active": 1,
797
+ "flagValue": -1
798
+ },
799
+ "hoist_funs": {
800
+ "active": 1,
801
+ "flagValue": -1
802
+ },
803
+ "hoist_vars": {
804
+ "active": 0,
805
+ "flagValue": -1
806
+ },
807
+ "if_return": {
808
+ "active": 1,
809
+ "flagValue": -1
810
+ },
811
+ "indent-level": {
812
+ "active": 0,
813
+ "flagValue": 4
814
+ },
815
+ "indent-start": {
816
+ "active": 0,
817
+ "flagValue": 0
818
+ },
819
+ "inline-script": {
820
+ "active": 0,
821
+ "flagValue": -1
822
+ },
823
+ "join_vars": {
824
+ "active": 1,
825
+ "flagValue": -1
826
+ },
827
+ "keep_fargs": {
828
+ "active": 0,
829
+ "flagValue": -1
830
+ },
831
+ "keep_fnames": {
832
+ "active": 0,
833
+ "flagValue": -1
834
+ },
835
+ "loops": {
836
+ "active": 1,
837
+ "flagValue": -1
838
+ },
839
+ "mangle": {
840
+ "active": 1,
841
+ "flagValue": -1
842
+ },
843
+ "max-line-len": {
844
+ "active": 1,
845
+ "flagValue": 32000
846
+ },
847
+ "negate_iife": {
848
+ "active": 1,
849
+ "flagValue": -1
850
+ },
851
+ "properties": {
852
+ "active": 1,
853
+ "flagValue": -1
854
+ },
855
+ "pure_getters": {
856
+ "active": 0,
857
+ "flagValue": -1
858
+ },
859
+ "quote-keys": {
860
+ "active": 0,
861
+ "flagValue": -1
862
+ },
863
+ "screw-ie8": {
864
+ "active": 0,
865
+ "flagValue": -1
866
+ },
867
+ "semicolons": {
868
+ "active": 1,
869
+ "flagValue": -1
870
+ },
871
+ "sequences": {
872
+ "active": 1,
873
+ "flagValue": -1
874
+ },
875
+ "sort": {
876
+ "active": 0,
877
+ "flagValue": -1
878
+ },
879
+ "space-colon": {
880
+ "active": 1,
881
+ "flagValue": -1
882
+ },
883
+ "toplevel": {
884
+ "active": 0,
885
+ "flagValue": -1
886
+ },
887
+ "unsafe": {
888
+ "active": 0,
889
+ "flagValue": -1
890
+ },
891
+ "unused": {
892
+ "active": 0,
893
+ "flagValue": -1
894
+ },
895
+ "warnings": {
896
+ "active": 0,
897
+ "flagValue": -1
898
+ },
899
+ "width": {
900
+ "active": 1,
901
+ "flagValue": 80
902
+ }
903
+ },
904
+ "uglifyReservedNamesString": "$",
905
+ "websiteRelativeRoot": ""
906
+ },
907
+ "settingsFileVersion": "2"
908
+ }
languages/storefront-sticky-add-to-cart.pot CHANGED
@@ -2,10 +2,10 @@
2
  # This file is distributed under the same license as the Storefront Sticky Add to Cart package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Storefront Sticky Add to Cart 1.0.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/storefront-sticky-add-to-"
7
  "cart\n"
8
- "POT-Creation-Date: 2015-10-30 10:08:29+00:00\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
@@ -21,14 +21,18 @@ msgstr ""
21
  msgid "Support"
22
  msgstr ""
23
 
24
- #: storefront-sticky-add-to-cart.php:255
25
  msgid "Placeholder"
26
  msgstr ""
27
 
28
- #: storefront-sticky-add-to-cart.php:288
29
  msgid "You're viewing:"
30
  msgstr ""
31
 
 
 
 
 
32
  #. Plugin Name of the plugin/theme
33
  msgid "Storefront Sticky Add to Cart"
34
  msgstr ""
2
  # This file is distributed under the same license as the Storefront Sticky Add to Cart package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Storefront Sticky Add to Cart 1.1.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/storefront-sticky-add-to-"
7
  "cart\n"
8
+ "POT-Creation-Date: 2015-11-06 10:13:51+00:00\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
21
  msgid "Support"
22
  msgstr ""
23
 
24
+ #: storefront-sticky-add-to-cart.php:256
25
  msgid "Placeholder"
26
  msgstr ""
27
 
28
+ #: storefront-sticky-add-to-cart.php:289
29
  msgid "You're viewing:"
30
  msgstr ""
31
 
32
+ #: storefront-sticky-add-to-cart.php:296
33
+ msgid "Select options"
34
+ msgstr ""
35
+
36
  #. Plugin Name of the plugin/theme
37
  msgid "Storefront Sticky Add to Cart"
38
  msgstr ""
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: jameskoster, woothemes
3
  Tags: woocommerce, ecommerce, storefront, sticky
4
  Requires at least: 4.0
5
  Tested up to: 4.3.1
6
- Stable tag: 1.0.0
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -11,7 +11,7 @@ Storefront Sticky Add to Cart adds a convenient bar which sticks to the top of y
11
 
12
  == Description ==
13
 
14
- Product pages can be long. Some products have long descriptions, lots of reviews, galleries, you name it. By the time a visitor has read all of the product content and decided to commit to purchasing the product, the add to cart button is often hidden way off screen at the top of the page. Not any more! The Storefront Sticky Add to Cart plugin reveals a small content bar at the top of the browser window which includes the product name, price, stock status and the all-important add to cart button. It subtly slides into view once the standard add-to-cart button has scrolled out of view. Now when your customers decide they want to buy your product they no longer have to go hunting to add it to their cart!
15
 
16
  [youtube https://www.youtube.com/watch?v=v3daZU1kWJs]
17
 
@@ -25,10 +25,6 @@ As the name suggests this plugin has been designed to work with our [Storefront]
25
 
26
  == Frequently Asked Questions ==
27
 
28
- = I only see the add-to-cart bar on simple products, why? =
29
-
30
- Because grouped and variable products require additional input before they can be added to the cart reducing the effectiveness of this feature. I might look at including the variable product selectors in a future version.
31
-
32
  = I want to integrate with a theme other than Storefront, how do I do it? =
33
 
34
  It's very simple, most of the core styles are loaded regardless. You'll just need to apply a background color to the content bar like so; `.ssatc-sticky-add-to-cart { background-color: white; }`.
3
  Tags: woocommerce, ecommerce, storefront, sticky
4
  Requires at least: 4.0
5
  Tested up to: 4.3.1
6
+ Stable tag: 1.1.0
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
11
 
12
  == Description ==
13
 
14
+ Product pages can be long. Some products have long descriptions, lots of reviews, galleries, you name it. By the time a visitor has read all of the product content and decided to commit to purchasing the product, the add to cart button is often hidden way off screen at the top of the page. Not any more! The Storefront Sticky Add to Cart plugin reveals a small content bar at the top of the browser window which includes the product name, price, rating, stock status and the all-important add to cart button. It subtly slides into view once the standard add-to-cart button has scrolled out of view. Now when your customers decide they want to buy your product they no longer have to go hunting to add it to their cart!
15
 
16
  [youtube https://www.youtube.com/watch?v=v3daZU1kWJs]
17
 
25
 
26
  == Frequently Asked Questions ==
27
 
 
 
 
 
28
  = I want to integrate with a theme other than Storefront, how do I do it? =
29
 
30
  It's very simple, most of the core styles are loaded regardless. You'll just need to apply a background color to the content bar like so; `.ssatc-sticky-add-to-cart { background-color: white; }`.
storefront-sticky-add-to-cart.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Storefront Sticky Add to Cart
4
  * Plugin URI: https://wordpress.org/plugins/storefront-sticky-add-to-cart/
5
  * Description: Adds a sticky add-to-cart bar in single product pages that is revealed as the user scrolls down the page.
6
- * Version: 1.0.0
7
  * Author: WooThemes
8
  * Author URI: http://woothemes.com/
9
  * Requires at least: 4.0.0
@@ -84,7 +84,7 @@ final class Storefront_Sticky_Add_to_Cart {
84
  $this->token = 'storefront-sticky-add-to-cart';
85
  $this->plugin_url = plugin_dir_url( __FILE__ );
86
  $this->plugin_path = plugin_dir_path( __FILE__ );
87
- $this->version = '1.0.0';
88
 
89
  register_activation_hook( __FILE__, array( $this, 'install' ) );
90
 
@@ -194,6 +194,7 @@ final class Storefront_Sticky_Add_to_Cart {
194
  wp_enqueue_style( 'ssatc-styles', plugins_url( '/assets/css/style.css', __FILE__ ) );
195
  wp_register_script( 'waypoints', plugins_url( '/assets/js/jquery.waypoints.min.js', __FILE__ ), array( 'jquery' ), '4.0.0' );
196
  wp_register_script( 'waypoints-init', plugins_url( '/assets/js/waypoints.init.min.js', __FILE__ ), array( 'jquery' ) );
 
197
 
198
  // If Storefront is the active parent theme, add some styles
199
  if ( 'Storefront' == $theme->name || 'storefront' == $theme->template ) {
@@ -275,7 +276,7 @@ final class Storefront_Sticky_Add_to_Cart {
275
  $availability_html = empty( $availability['availability'] ) ? '' : '<span class="stock ' . esc_attr( $availability['class'] ) . '">' . esc_html( $availability['availability'] ) . '</span>';
276
 
277
  // And if the product isn't variable or grouped
278
- if ( $product->is_type( 'simple' ) ) {
279
  wp_enqueue_script( 'waypoints' );
280
  wp_enqueue_script( 'waypoints-init' );
281
 
@@ -286,15 +287,20 @@ final class Storefront_Sticky_Add_to_Cart {
286
  $ssatc->ssatc_product_image();
287
  echo '<div class="ssatc-content">';
288
  echo __( 'You\'re viewing:', 'storefront-sticky-add-to-cart' ) . ' <strong>' . get_the_title() . '</strong><br />';
289
- echo '<span class="price">' . $product->get_price_html() . '</span> ';
290
  echo apply_filters( 'woocommerce_stock_html', $availability_html, $availability['availability'], $product );
291
- echo '<br /><a href="' . $product->add_to_cart_url() . '" class="button">' . $product->single_add_to_cart_text() . '</a>';
 
 
 
 
 
 
292
  echo '</div>';
293
  ?>
294
  </div>
295
  </section>
296
  <?php
297
- }
298
  }
299
  }
300
  }
3
  * Plugin Name: Storefront Sticky Add to Cart
4
  * Plugin URI: https://wordpress.org/plugins/storefront-sticky-add-to-cart/
5
  * Description: Adds a sticky add-to-cart bar in single product pages that is revealed as the user scrolls down the page.
6
+ * Version: 1.1.0
7
  * Author: WooThemes
8
  * Author URI: http://woothemes.com/
9
  * Requires at least: 4.0.0
84
  $this->token = 'storefront-sticky-add-to-cart';
85
  $this->plugin_url = plugin_dir_url( __FILE__ );
86
  $this->plugin_path = plugin_dir_path( __FILE__ );
87
+ $this->version = '1.1.0';
88
 
89
  register_activation_hook( __FILE__, array( $this, 'install' ) );
90
 
194
  wp_enqueue_style( 'ssatc-styles', plugins_url( '/assets/css/style.css', __FILE__ ) );
195
  wp_register_script( 'waypoints', plugins_url( '/assets/js/jquery.waypoints.min.js', __FILE__ ), array( 'jquery' ), '4.0.0' );
196
  wp_register_script( 'waypoints-init', plugins_url( '/assets/js/waypoints.init.min.js', __FILE__ ), array( 'jquery' ) );
197
+ wp_register_script( 'ssatc-variable', plugins_url( '/assets/js/variable.min.js', __FILE__ ), array( 'jquery' ) );
198
 
199
  // If Storefront is the active parent theme, add some styles
200
  if ( 'Storefront' == $theme->name || 'storefront' == $theme->template ) {
276
  $availability_html = empty( $availability['availability'] ) ? '' : '<span class="stock ' . esc_attr( $availability['class'] ) . '">' . esc_html( $availability['availability'] ) . '</span>';
277
 
278
  // And if the product isn't variable or grouped
279
+
280
  wp_enqueue_script( 'waypoints' );
281
  wp_enqueue_script( 'waypoints-init' );
282
 
287
  $ssatc->ssatc_product_image();
288
  echo '<div class="ssatc-content">';
289
  echo __( 'You\'re viewing:', 'storefront-sticky-add-to-cart' ) . ' <strong>' . get_the_title() . '</strong><br />';
290
+ echo '<span class="price">' . $product->get_price_html() . '</span> ' . $product->get_rating_html();
291
  echo apply_filters( 'woocommerce_stock_html', $availability_html, $availability['availability'], $product );
292
+
293
+ if ( $product->is_type( 'simple' ) ) {
294
+ echo '<br /><a href="' . $product->add_to_cart_url() . '" class="button alt">' . $product->single_add_to_cart_text() . '</a>';
295
+ } elseif ( $product->is_type( 'variable' ) ) {
296
+ echo '<br /><a class="button alt variable">' . __( 'Select options', 'storefront-sticky-add-to-cart' ) . '</a>';
297
+ wp_enqueue_script( 'ssatc-variable' );
298
+ }
299
  echo '</div>';
300
  ?>
301
  </div>
302
  </section>
303
  <?php
 
304
  }
305
  }
306
  }