-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
95 changed files
with
9,646 additions
and
57,542 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 |
---|---|---|
|
@@ -18,4 +18,5 @@ jobs: | |
- name: npm install, run test | ||
run: | | ||
npm install | ||
npm t | ||
npm run lint | ||
npm run test:coverage |
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: publish-docs | ||
|
||
on: workflow_dispatch | ||
|
||
jobs: | ||
build-and-deploy-storybooks: | ||
runs-on: ubuntu-latest | ||
|
||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
|
||
concurrency: | ||
group: "pages" | ||
|
||
permissions: | ||
contents: read | ||
pages: write | ||
id-token: write | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup Node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '16' | ||
|
||
- name: Build docs Storybooks | ||
run: | | ||
npm install | ||
npm run storybook-web-docs | ||
- name: Upload artifact | ||
uses: actions/upload-pages-artifact@v2 | ||
with: | ||
# Upload entire repository | ||
path: './docs/' | ||
name: docs | ||
|
||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v2 | ||
with: | ||
artifact_name: 'docs' | ||
github-token: ${{ secrets.GITHUB_TOKEN }} |
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 |
---|---|---|
|
@@ -67,4 +67,5 @@ coverage | |
dist/ | ||
|
||
# Static storybook page | ||
.storybook_static | ||
.storybook_static | ||
.docs |
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,4 +1,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
npm run lint | ||
npx lint-staged && npm run lint |
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,62 +1,64 @@ | ||
/* do not change this file, it is auto generated by storybook. */ | ||
|
||
import { | ||
configure, | ||
addDecorator, | ||
addParameters, | ||
addArgsEnhancer, | ||
clearDecorators, | ||
} from "@storybook/react-native"; | ||
configure, | ||
addDecorator, | ||
addParameters, | ||
addArgsEnhancer, | ||
clearDecorators, | ||
} from '@storybook/react-native'; | ||
|
||
global.STORIES = [ | ||
{ | ||
titlePrefix: "", | ||
directory: "./storybook/stories", | ||
files: "**/*.stories.?(ts|tsx|js|jsx)", | ||
importPathMatcher: | ||
"^\\.[\\\\/](?:storybook\\/stories(?:\\/(?!\\.)(?:(?:(?!(?:^|\\/)\\.).)*?)\\/|\\/|$)(?!\\.)(?=.)[^/]*?\\.stories\\.(?:ts|tsx|js|jsx)?)$", | ||
}, | ||
{ | ||
titlePrefix: '', | ||
directory: './storybook/stories', | ||
files: '**/*.stories.?(ts|tsx|js|jsx)', | ||
importPathMatcher: | ||
'^\\.[\\\\/](?:storybook\\/stories(?:\\/(?!\\.)(?:(?:(?!(?:^|\\/)\\.).)*?)\\/|\\/|$)(?!\\.)(?=.)[^/]*?\\.stories\\.(?:ts|tsx|js|jsx)?)$', | ||
}, | ||
]; | ||
|
||
import "@storybook/addon-ondevice-actions/register"; | ||
import "@storybook/addon-ondevice-controls/register"; | ||
import '@storybook/addon-ondevice-actions/register'; | ||
import '@storybook/addon-ondevice-controls/register'; | ||
|
||
import { argsEnhancers } from "@storybook/addon-actions/dist/modern/preset/addArgs"; | ||
import {argsEnhancers} from '@storybook/addon-actions/dist/modern/preset/addArgs'; | ||
|
||
import { decorators, parameters } from "./preview"; | ||
import {decorators, parameters} from './preview'; | ||
|
||
if (decorators) { | ||
if (__DEV__) { | ||
// stops the warning from showing on every HMR | ||
require("react-native").LogBox.ignoreLogs([ | ||
"`clearDecorators` is deprecated and will be removed in Storybook 7.0", | ||
]); | ||
} | ||
// workaround for global decorators getting infinitely applied on HMR, see https://github.com/storybookjs/react-native/issues/185 | ||
clearDecorators(); | ||
decorators.forEach((decorator) => addDecorator(decorator)); | ||
if (__DEV__) { | ||
// stops the warning from showing on every HMR | ||
require('react-native').LogBox.ignoreLogs([ | ||
'`clearDecorators` is deprecated and will be removed in Storybook 7.0', | ||
]); | ||
} | ||
// workaround for global decorators getting infinitely applied on HMR, see https://github.com/storybookjs/react-native/issues/185 | ||
clearDecorators(); | ||
decorators.forEach((decorator) => addDecorator(decorator)); | ||
} | ||
|
||
if (parameters) { | ||
addParameters(parameters); | ||
addParameters(parameters); | ||
} | ||
|
||
try { | ||
argsEnhancers.forEach((enhancer) => addArgsEnhancer(enhancer)); | ||
argsEnhancers.forEach((enhancer) => addArgsEnhancer(enhancer)); | ||
} catch {} | ||
|
||
const getStories = () => { | ||
return { | ||
"./storybook/stories/Avatar/Avatar.stories.js": require("../storybook/stories/Avatar/Avatar.stories.js"), | ||
"./storybook/stories/CheckBox/CheckBox.stories.js": require("../storybook/stories/CheckBox/CheckBox.stories.js"), | ||
"./storybook/stories/Image/Image.stories.js": require("../storybook/stories/Image/Image.stories.js"), | ||
"./storybook/stories/Input/Input.stories.js": require("../storybook/stories/Input/Input.stories.js"), | ||
"./storybook/stories/Loading/Loading.stories.js": require("../storybook/stories/Loading/Loading.stories.js"), | ||
"./storybook/stories/Select/Select.stories.js": require("../storybook/stories/Select/Select.stories.js"), | ||
"./storybook/stories/StatusChip/StatusChip.stories.js": require("../storybook/stories/StatusChip/StatusChip.stories.js"), | ||
"./storybook/stories/Svg/Svg.stories.js": require("../storybook/stories/Svg/Svg.stories.js"), | ||
"./storybook/stories/Text/Text.stories.js": require("../storybook/stories/Text/Text.stories.js"), | ||
}; | ||
return { | ||
'./storybook/stories/Avatar/Avatar.stories.js': require('../storybook/stories/Avatar/Avatar.stories.js'), | ||
'./storybook/stories/CheckBox/CheckBox.stories.js': require('../storybook/stories/CheckBox/CheckBox.stories.js'), | ||
'./storybook/stories/DesignStystem/Colors.stories.js': require('../storybook/stories/DesignStystem/Colors.stories.js'), | ||
'./storybook/stories/Image/Image.stories.js': require('../storybook/stories/Image/Image.stories.js'), | ||
'./storybook/stories/Input/Input.stories.js': require('../storybook/stories/Input/Input.stories.js'), | ||
'./storybook/stories/Loading/Loading.stories.js': require('../storybook/stories/Loading/Loading.stories.js'), | ||
'./storybook/stories/Select/Select.stories.js': require('../storybook/stories/Select/Select.stories.js'), | ||
'./storybook/stories/LoadingFullScreen/LoadingFullScreen.stories.js': require('../storybook/stories/LoadingFullScreen/LoadingFullScreen.stories.js'), | ||
'./storybook/stories/StatusChip/StatusChip.stories.js': require('../storybook/stories/StatusChip/StatusChip.stories.js'), | ||
'./storybook/stories/Svg/Svg.stories.js': require('../storybook/stories/Svg/Svg.stories.js'), | ||
'./storybook/stories/Text/Text.stories.js': require('../storybook/stories/Text/Text.stories.js'), | ||
}; | ||
}; | ||
|
||
configure(getStories, module, false); |
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import {addons} from '@storybook/addons'; | ||
import yourTheme from './theme'; | ||
|
||
addons.setConfig({ | ||
theme: yourTheme, | ||
}); |
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<!-- .storybook/preview-head.html --> | ||
|
||
<!-- Pull in static files served from your Static directory or the internet --> | ||
<!-- Example: `main.js|ts` is configured with staticDirs: ['../public'] and your font is located in the `fonts` directory inside your `public` directory --> | ||
<link rel="preconnect" href="https://fonts.googleapis.com"> | ||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin> | ||
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;900&display=swap" rel="stylesheet"> | ||
|
||
<!-- Or you can load custom head-tag JavaScript: --> |
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import {create} from '@storybook/theming'; | ||
|
||
export default create({ | ||
base: 'light', | ||
brandTitle: 'Janis UI apps', | ||
brandUrl: 'https://janis.im', | ||
brandImage: 'https://app.janis.in/static/media/janis-logo-base.0cc15e53.svg', | ||
brandTarget: 'https://janis.im', | ||
fontBase: '"Roboto", sans-serif', | ||
fontCode: 'Roboto', | ||
}); |
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 was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.