Skip to content

Commit

Permalink
[Fix] Flex elements ignore percent padding in Firefox
Browse files Browse the repository at this point in the history
  • Loading branch information
ShinyLeee committed Feb 14, 2018
1 parent 8aa09c0 commit b772788
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 5 deletions.
5 changes: 3 additions & 2 deletions imports/ui/components/NavHeader/Primary/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import Toolbar from 'material-ui/Toolbar';
import Typography from 'material-ui/Typography';
import MenuIcon from 'material-ui-icons/Menu';
import IconButton from 'material-ui/IconButton';
import scrollTo from '/imports/vendor/scrollTo';
import NavHeader from '../NavHeader';
import Drawer from './components/Drawer';
import RightContent from './components/RightContent';
Expand All @@ -30,10 +29,12 @@ class PrimaryNavHeader extends PureComponent {

_handleTitleClick = () => {
const { location, history } = this.props;
scrollTo(0, 1500);
if (location.pathname !== '/') {
history.push('/');
} else {
window.scrollTo(0, 0);
}

if (this.props.onTitleClick) {
this.props.onTitleClick();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ import styled from 'styled-components';

export const Wrapper = styled.figure`
position: relative;
display: flex;
align-items: center;
justify-content: center;
margin: 0;
overflow: hidden;
& > span { /* Aspect Ratio Filler */
Expand Down
9 changes: 9 additions & 0 deletions imports/ui/redux/store/index.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
import { Meteor } from 'meteor/meteor';
import { createStore, applyMiddleware } from 'redux';
import { routerMiddleware } from 'react-router-redux';
import thunk from 'redux-thunk';
import { createLogger } from 'redux-logger';
import history from '/imports/utils/history';
import reducers from '../reducers';
import initState from './initState';

const logger = createLogger({
predicate: () => Meteor.isDevelopment,
collapsed: true,
duration: true,
});

const router = routerMiddleware(history);

export default createStore(
Expand All @@ -13,5 +21,6 @@ export default createStore(
applyMiddleware(
thunk,
router,
logger,
),
);
15 changes: 15 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
"faker": "^4.1.0",
"react-test-renderer": "^16.0.0",
"redux-devtools": "^3.4.1",
"redux-logger": "^3.0.6",
"redux-mock-store": "^1.2.1"
}
}

0 comments on commit b772788

Please sign in to comment.