Skip to content

Commit e31fa54

Browse files
committed
edit configuration and remove getSquarePhoto function content
1 parent 9a572b4 commit e31fa54

File tree

3 files changed

+12
-7
lines changed

3 files changed

+12
-7
lines changed

Helper/Config.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
class Config extends AbstractHelper
99
{
1010

11-
const BASE_CONFIG_XML_PREFIX = 'instagram/settings/%s';
11+
const BASE_CONFIG_XML_PREFIX = 'bitbull_instagramwidget/settings/%s';
1212
const INSTAGRAM_TOKEN = 'instagram_token';
1313
const INSTAGRAM_USERID = 'instagram_user_id';
1414
const INSTAGRAM_CHANNEL = 'instagram_channel';
@@ -40,4 +40,3 @@ public function getConfigParam($configField)
4040
}
4141

4242
}
43-

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
Magento module 2 that displays last photos from an Instagram account. More information here https://www.bitbull.it/blog/sviluppare-un-widget-con-magento2-e-requirejs/
44

5+
![](https://raw.githubusercontent.com/bitbull-team/magento2-module-instagramwidget/develop/docs/frontend.png)
6+
57
Installation Instructions
68
--------------------------
79
Add these lines to the composer.json of your project
@@ -31,7 +33,8 @@ After install go to Magento2 admin in **Stores -> Configuration -> Bitbull -> In
3133
* Instagram Userid Credentials
3234
* Channel title to display on frontend
3335
* Number of photos
34-
36+
37+
![](https://raw.githubusercontent.com/bitbull-team/magento2-module-instagramwidget/develop/docs/admin-panel.png)
3538

3639
To retrieve the data of your channel follow the official Instagram doc: https://www.instagram.com/developer/authentication/
3740

view/frontend/web/js/InstagramWidget.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ define([
3232
url = this.link;
3333

3434
html += '<li>' +
35-
'<a TARGET="_blank" href="' + url +'">' +
36-
'<img src=" '+ img +'"/>'+
35+
'<a target="_blank" href="' + url +'">' +
36+
'<img src="'+ img +'"/>'+
3737
'</a>'+
3838
'</li>';
3939
});
@@ -87,8 +87,11 @@ define([
8787

8888

8989
_getSquaredPhoto: function (thumbnail) {
90-
var thumb = thumbnail.replace('s150x150/', 's320x320/');
91-
return thumb.replace(/vp\/[^\/]*/, 'hphotos-xfp1');
90+
// var thumb = thumbnail.replace('s150x150/', 's320x320/');
91+
// return thumb.replace(/vp\/[^\/]*/, 'hphotos-xfp1');
92+
93+
// this needs to be fixed, no longer working
94+
return thumbnail;
9295
},
9396

9497
/**

0 commit comments

Comments
 (0)