-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: use i18n instance from uikit (#179) * feat: reafctor transformPost interface (#180) * feat: update storybook (#182) * feat: remove metrika goals (#177) --------- Co-authored-by: Nik Tverd <[email protected]>
- Loading branch information
Showing
61 changed files
with
4,980 additions
and
3,252 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,3 @@ node_modules | |
/build | ||
/storybook-static | ||
/server | ||
/configure |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,6 @@ node_modules | |
/build | ||
/storybook-static | ||
/server | ||
/configure | ||
|
||
*.tgz | ||
.env | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,6 @@ | |
# Build | ||
build/ | ||
server/ | ||
configure/ | ||
storybook-static/ | ||
/styles/*.css | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,14 @@ | ||
import React from 'react'; | ||
|
||
import {MobileProvider} from '@gravity-ui/uikit'; | ||
import {StoryFn, StoryContext} from '@storybook/react'; | ||
import {useMobile} from '@gravity-ui/uikit'; | ||
|
||
export function withMobile(Story: StoryFn, context: StoryContext) { | ||
const mobileValue = context.globals.platform === 'mobile'; | ||
|
||
const [mobile, setMobile] = useMobile(); // eslint-disable-line react-hooks/rules-of-hooks | ||
|
||
if (mobile !== mobileValue) { | ||
setMobile(mobileValue); | ||
} | ||
const platform = context.globals.platform; | ||
|
||
return <Story {...context} />; | ||
return ( | ||
<MobileProvider mobile={platform === 'mobile'} platform={platform}> | ||
<Story {...context} /> | ||
</MobileProvider> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.