Skip to content

Commit eb7e676

Browse files
author
Ethan Jon
committed
about content
1 parent 0083020 commit eb7e676

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

react/helpers/create-page.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,8 @@ export default function (Child: Object, {propPaths = () => ({}), fullWidth = fal
9898
}
9999

100100
componentDidMount () {
101+
this.defineGlobalModalFunctions()
102+
101103
if ((typeof autoOpenFacebookModal === 'function' ? autoOpenFacebookModal(this.props) : autoOpenFacebookModal) &&
102104
this.props.siteData.facebook_modal_delay) {
103105
setTimeout(() => {
@@ -112,6 +114,12 @@ export default function (Child: Object, {propPaths = () => ({}), fullWidth = fal
112114
}
113115
}
114116

117+
// these functions are for opening modals from wordpress content
118+
defineGlobalModalFunctions = () => {
119+
window.openLikeModal = this.likeModalStore.open
120+
window.openEmailModal = this.emailModalStore.open
121+
}
122+
115123
emailModalStore: Object
116124
headerStore: Object
117125
likeModalStore: Object

react/styles/components/post/content.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
color: #0b0b0b;
33
font-size: 1.125rem;
44
line-height: 1.7;
5+
a { text-decoration: underline; }
56
img {
67
$smallMargin: 0.5rem;
78
$largeMargin: 1.5rem;

0 commit comments

Comments
 (0)