Skip to content

Commit

Permalink
Final couple that I missed
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Coleman committed Jan 3, 2019
1 parent 66c5c90 commit 20d14ab
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 18 deletions.
2 changes: 1 addition & 1 deletion lib/components/src/preview/preview.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const props = {
emit: () => {},
off: () => {},
},
componentId: 'string',
storyId: 'string',
path: 'string',
viewMode: 'components',
location: {},
Expand Down
16 changes: 3 additions & 13 deletions lib/ui/src/components/layout/mobile.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,17 +117,7 @@ class Mobile extends Component {
}

render() {
const {
Nav,
Preview,
Panel,
pages,
viewMode,
location,
componentId,
options,
path,
} = this.props;
const { Nav, Preview, Panel, pages, viewMode, location, storyId, options, path } = this.props;
const { active } = this.state;

return (
Expand All @@ -140,7 +130,7 @@ class Mobile extends Component {
isToolshown={options.isToolshown}
id="iframe"
path={path}
componentId={componentId}
storyId={storyId}
location={location}
viewMode={viewMode}
debug={options}
Expand Down Expand Up @@ -184,7 +174,7 @@ Mobile.propTypes = {
})
).isRequired,
viewMode: PropTypes.oneOf(['components', 'info']),
componentId: PropTypes.string.isRequired,
storyId: PropTypes.string.isRequired,
path: PropTypes.string.isRequired,
location: PropTypes.shape({}).isRequired,
options: PropTypes.shape({
Expand Down
2 changes: 1 addition & 1 deletion lib/ui/src/components/nav/explorer.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const LeafLink = React.memo(({ href, children, ...rest }) => (
const StoriesPanel = React.memo(props => <Explorer allowClick {...props} Link={LeafLink} />);
StoriesPanel.propTypes = {
stories: PropTypes.shape({}).isRequired,
componentId: PropTypes.string.isRequired,
storyId: PropTypes.string.isRequired,
};

export { StoriesPanel as StoriesExplorer };
6 changes: 3 additions & 3 deletions lib/ui/src/containers/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ import { Consumer } from '../core/context';
const createPreviewActions = memoize(1)(api => ({
toggleFullscreen: () => api.toggleFullscreen(),
}));
const createProps = (api, layout, location, path, componentId, viewMode) => ({
const createProps = (api, layout, location, path, storyId, viewMode) => ({
api,
getElements: api.getElements,
actions: createPreviewActions(api),
options: layout,
path,
componentId,
storyId,
viewMode,
});

Expand All @@ -27,7 +27,7 @@ const PreviewConnected = React.memo(props => (
state.layout,
state.location,
state.path,
state.componentId,
state.storyId,
state.viewMode
)}
/>
Expand Down

0 comments on commit 20d14ab

Please sign in to comment.