Skip to content

Commit

Permalink
Merge pull request #34 from dnd-side-project/chore/#33
Browse files Browse the repository at this point in the history
chore: Storybook 배포 테스트
  • Loading branch information
lsy20140 authored Aug 16, 2024
2 parents 8a8fa2e + d1d10fe commit 350a545
Show file tree
Hide file tree
Showing 5 changed files with 63 additions and 113 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/storybook.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: 'Chromatic Deployment'

on:
pull_request:
branches: ['main']
paths:
- '**.stories.tsx'
- '**.stories.mdx'
push:
branches: ['main']
paths:
- '**.stories.tsx'
- '**.stories.mdx'

jobs:
chromatic:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Install dependencies
run: npm ci

- name: Publish to Chromatic
id: publish_chromatic
uses: chromaui/action@latest
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
buildScriptName: build-storybook
onlyChanged: true
- name: comment PR
uses: thollander/actions-comment-pull-request@v1
if: ${{ github.event_name == 'pull_request' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
message: '🚀 **storybook**: ${{ steps.publish_chromatic.outputs.storybookUrl }}'
23 changes: 23 additions & 0 deletions src/components/common/BottomSheet/BottomSheet.stories.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import type { Meta, StoryObj } from '@storybook/react'
import BottomSheet from '.'

const meta: Meta<typeof BottomSheet> = {
title: 'components/common/BottomSheet',
component: BottomSheet,
tags: ['autodocs'],
argTypes: {
children: {
description: 'BottomSheet type에 맞는 형태의 내용을 전달합니다',
},
},
}

export default meta

type Story = StoryObj<typeof BottomSheet>

export const Default: Story = {
args: {
children: 'BottomSheet',
},
}
32 changes: 0 additions & 32 deletions src/stories/Page.stories.ts

This file was deleted.

12 changes: 0 additions & 12 deletions src/stories/Page.tsx

This file was deleted.

69 changes: 0 additions & 69 deletions src/stories/page.css

This file was deleted.

0 comments on commit 350a545

Please sign in to comment.