Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(730): update video player component scenarios storybook #830

Merged
merged 15 commits into from
Apr 18, 2023
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions site/pages/components/video-player.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ const VideoPlayerComponent = (layoutProps: LayoutProps) => (
introduced: 'v5.0.0',
codeUrl:
'https://github.com/newscorp-ghfb/newskit/tree/main/src/video-player',
storybookId:
'components-video-player-default--story-default-video-player',
storybookId: 'components-video-player--story-video-player-default',
}}
>
<ComponentPageCell>
Expand Down Expand Up @@ -168,7 +167,7 @@ const VideoPlayerComponent = (layoutProps: LayoutProps) => (
that can be assembled using the various available subcomponents of
the Brightcove player.{' '}
<Link
href="https://storybook.newskit.co.uk/?path=/docs/components-video-player-default--story-default-video-player"
href="https://storybook.newskit.co.uk/?path=/docs/components-video-player--story-video-player-default"
target="_blank"
>
View the example in Storybook
Expand All @@ -195,7 +194,7 @@ const VideoPlayerComponent = (layoutProps: LayoutProps) => (
</Link>{' '}
to give context to the video being played.{' '}
<Link
href="https://storybook.newskit.co.uk/?path=/docs/components-video-player-default--story-default-video-player"
href="https://storybook.newskit.co.uk/?path=/docs/components-video-player--story-video-player-default"
target="_blank"
>
View the examples in Storybook
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import {
import {LinkInline} from '../../../link';
import {Tag} from '../../../tag';
import {VideoPlayer} from '../../../video-player';
import {DEFATULT_VIDEO_PLAYER_CONFIG} from '../../../video-player/__tests__/config';
import {DEFAULT_VIDEO_PLAYER_CONFIG} from '../../../video-player/__tests__/config';

const H = ({overrides, ...props}: Omit<HeadlineProps, 'children'>) => (
<Headline
Expand Down Expand Up @@ -359,7 +359,7 @@ export const StoryVariations = () => (
<P />
</CardContent>
<CardMedia>
<VideoPlayer config={DEFATULT_VIDEO_PLAYER_CONFIG} />
<VideoPlayer config={DEFAULT_VIDEO_PLAYER_CONFIG} />
</CardMedia>
<CardActions>
<Tag href={href}>Tag</Tag>
Expand Down
3 changes: 2 additions & 1 deletion src/test/storybook-comps.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react';
import {sanitize} from 'isomorphic-dompurify';
import {
DocsStoryProps,
DocsContextProps,
Expand Down Expand Up @@ -176,7 +177,7 @@ export const StoryDocsHeader = ({context}: {context: DocsContextProps}) => {
typographyPreset="utilityBody030"
stylePreset="inkBase"
>
{description}
<span dangerouslySetInnerHTML={{__html: sanitize(description)}} />
</TextBlock>
)}
<Divider />
Expand Down
4 changes: 2 additions & 2 deletions src/theme/__tests__/__snapshots__/theme.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3391,7 +3391,7 @@ Object {
"videoPlayer": Object {
"controlBar": Object {
"iconToggle": Object {
"stylePreset": "inkInverse",
"stylePreset": "inkLight010",
},
"maxHeight": Object {
"md": "sizing080",
Expand All @@ -3405,7 +3405,7 @@ Object {
"divider": Object {
"spaceInline": "space010",
},
"stylePreset": "inkInverse",
"stylePreset": "inkLight010",
"typographyPreset": "utilityMeta010",
},
"typographyPreset": Object {
Expand Down
2 changes: 1 addition & 1 deletion src/video-player/__tests__/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const PLAYLISTS_VIDEO_PLAYER_CONFIG = {
controls: true,
};

export const DEFATULT_VIDEO_PLAYER_CONFIG = {
export const DEFAULT_VIDEO_PLAYER_CONFIG = {
'data-video-id': '5290445795001',
'data-account': '1752604059001',
'data-player': 'default',
Expand Down
119 changes: 0 additions & 119 deletions src/video-player/__tests__/video-player-default.stories.tsx

This file was deleted.

Loading