Skip to content

Commit

Permalink
docs: ✏️ images
Browse files Browse the repository at this point in the history
  • Loading branch information
ianzone committed Nov 16, 2024
1 parent a6ded88 commit 59bdd2f
Show file tree
Hide file tree
Showing 28 changed files with 217 additions and 38 deletions.
197 changes: 165 additions & 32 deletions pnpm-lock.yaml

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

21 changes: 21 additions & 0 deletions src/components/images/CountryFlag/CountryFlag.stories.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import type { Meta, StoryObj } from '@storybook/react';
import { CountryFlag } from './CountryFlag';

const meta = {
title: 'Images/CountryFlag',
component: CountryFlag,
parameters: {
layout: 'centered',
},
tags: ['autodocs'],
} satisfies Meta<typeof CountryFlag>;

export default meta;
type Story = StoryObj<typeof meta>;

export const Default: Story = {
args: {
countryCode: 'CN',
width: 24,
},
};
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { emojiFlag } from '@rapideditor/country-coder';
import type { CountryCode } from 'libphonenumber-js';
import { EmojiSVG } from './EmojiSVG';
import { EmojiSVG } from '../EmojiSVG/EmojiSVG';

type CountryFlagProps = {
width?: string | number;
Expand Down
1 change: 1 addition & 0 deletions src/components/images/CountryFlag/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './CountryFlag';
21 changes: 21 additions & 0 deletions src/components/images/EmojiSVG/EmojiSVG.stories.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import type { Meta, StoryObj } from '@storybook/react';
import { EmojiSVG } from './EmojiSVG';

const meta = {
title: 'Images/EmojiSVG',
component: EmojiSVG,
parameters: {
layout: 'centered',
},
tags: ['autodocs'],
} satisfies Meta<typeof EmojiSVG>;

export default meta;
type Story = StoryObj<typeof meta>;

export const Default: Story = {
args: {
emoji: '🌐',
width: 24,
},
};
File renamed without changes.
1 change: 1 addition & 0 deletions src/components/images/EmojiSVG/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './EmojiSVG';
2 changes: 2 additions & 0 deletions src/components/images/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './EmojiSVG';
export * from './CountryFlag';
6 changes: 2 additions & 4 deletions src/components/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
export * from './EmojiSVG';
export * from './CountryFlag';
export * from './InputIntlPhone';
export * from './InputPhone';
export * from './images';
export * from './inputs';
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 2 additions & 0 deletions src/components/inputs/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
export * from './InputPhone';
export * from './InputIntlPhone';
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export * from 'src/components';
export * from './components';

0 comments on commit 59bdd2f

Please sign in to comment.