Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
joshine
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
joshine
Commits
0ab913ab
Commit
0ab913ab
authored
Apr 17, 2023
by
liumengfei
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' into production
parents
d51ddbf5
6bc1fdf7
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
4 deletions
+15
-4
app/code/Joshine/InstagramFeed/Block/MediaFeed.php
+10
-0
app/code/Joshine/InstagramFeed/view/frontend/templates/mediafeed.phtml
+5
-4
No files found.
app/code/Joshine/InstagramFeed/Block/MediaFeed.php
View file @
0ab913ab
...
@@ -172,4 +172,13 @@ class MediaFeed extends Template {
...
@@ -172,4 +172,13 @@ class MediaFeed extends Template {
return
$feed
;
return
$feed
;
}
}
public
function
isOpen
()
{
return
$this
->
_objectManager
->
get
(
ScopeConfigInterface
::
class
)
->
getValue
(
'joshine_instagram_feed/general/enabled'
,
ScopeInterface
::
SCOPE_STORE
);
}
}
}
\ No newline at end of file
app/code/Joshine/InstagramFeed/view/frontend/templates/mediafeed.phtml
View file @
0ab913ab
<?php
<?php
/** @var $block \Joshine\InstagramFeed\Block\MediaFeed */
/** @var $block \Joshine\InstagramFeed\Block\MediaFeed */
$media
=
$block
->
getMedia
()[
'data'
];
?>
?>
<?php
if
(
$block
->
isOpen
())
:
?>
<style>
<style>
.instagram-feed-container
.instagram-feed-title
{
.instagram-feed-container
.instagram-feed-title
{
background
:
#fff
;
background
:
#fff
;
...
@@ -13,7 +13,6 @@ $media = $block->getMedia()['data'];
...
@@ -13,7 +13,6 @@ $media = $block->getMedia()['data'];
padding
:
40px
;
padding
:
40px
;
text-align
:
center
;
text-align
:
center
;
}
}
.instagram-feed-container
{
.instagram-feed-container
{
margin
:
0
auto
;
margin
:
0
auto
;
-webkit-user-select
:
none
;
-webkit-user-select
:
none
;
...
@@ -201,7 +200,7 @@ $media = $block->getMedia()['data'];
...
@@ -201,7 +200,7 @@ $media = $block->getMedia()['data'];
padding
:
10px
;
padding
:
10px
;
}
}
</style>
</style>
<?php
$media
=
$block
->
getMedia
()[
'data'
];
?>
<?php
if
(
!
empty
(
$media
))
:
?>
<?php
if
(
!
empty
(
$media
))
:
?>
<div
id=
"joshine-section-app-block-instagram"
class=
"joshine-section spaced-section"
>
<div
id=
"joshine-section-app-block-instagram"
class=
"joshine-section spaced-section"
>
<div
class=
"instagram-container"
>
<div
class=
"instagram-container"
>
...
@@ -301,3 +300,4 @@ $media = $block->getMedia()['data'];
...
@@ -301,3 +300,4 @@ $media = $block->getMedia()['data'];
});
});
</script>
</script>
<?
endif
;
?>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment