This commit is contained in:
Belen Curcio
2017-01-30 09:04:00 -03:00
parent c42fea5889
commit 805b5cb441
5 changed files with 19 additions and 10 deletions
+9 -6
View File
@@ -26,7 +26,7 @@ import ConfigureStreamContainer from 'coral-configure/containers/ConfigureStream
class Embed extends Component {
state = { activeTab: 0, showSignInDialog: false };
state = {activeTab: 0, showSignInDialog: false};
changeTab = (tab) => {
this.setState({
@@ -69,6 +69,13 @@ class Embed extends Component {
}
}, 100);
});
console.log(document.documentElement);
document.documentElement.addEventListener('scroll', this.handleScroll);
}
handleScroll = () => {
const doc = document.documentElement;
console.log((window.pageYOffset || doc.scrollTop) - (doc.clientTop || 0));
}
componentWillReceiveProps (nextProps) {
@@ -91,13 +98,9 @@ class Embed extends Component {
} : {};
if (loading) {
return <Spinner />
return <Spinner />;
}
console.log(
asset
)
return (
<div style={expandForLogin}>
<div className="commentStream">
@@ -1,3 +1,8 @@
html, body {
width:auto;
height:auto;
}
body {
font-family: 'Lato', sans-serif;
font-family: 'Open Sans', sans-serif;
@@ -76,6 +81,7 @@ hr {
.commentStream {
/* prevent absolutely positioned final permalink popover from being clipped */
padding-bottom: 50px;
/*height: 100vh;*/
}
/* Comment Box Styles */
@@ -3,6 +3,7 @@ import {SnackBar} from 'coral-ui';
const Notification = (props) => {
if (props.notification.text) {
// setTimeout(() => {
// props.clearNotification();
// }, props.notifLength);
+2 -3
View File
@@ -1,6 +1,4 @@
.SnackBar {
top: 0;
background: red;
position: fixed;
cursor: default;
background-color: #323232;
@@ -9,11 +7,12 @@
will-change: transform;
transition: transform .25s cubic-bezier(.4,0,1,1);
pointer-events: none;
transform: translate(-50%,80px);
padding: 18px 14px;
vertical-align: middle;
color: #fff;
border-radius: 3px;
text-align: center;
left: 50%;
bottom: 0;
transform: translate(-50%, 0);
}
+1 -1
View File
@@ -1,5 +1,5 @@
import React from 'react';
import styles from './SnackBar.css'
import styles from './SnackBar.css';
const SnackBar = ({children}) => (
<div className={styles.SnackBar}>{children}</div>