-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(storybook): add stories for the component
- Loading branch information
1 parent
72dfddf
commit 8b24f34
Showing
3 changed files
with
39 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import Vue from 'vue'; | ||
import VueCompositionApi from '@vue/composition-api'; | ||
|
||
Vue.use(VueCompositionApi); |
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,3 @@ | ||
module.exports = { | ||
stories: ['../src/**/*.stories.[tj]s'], | ||
}; |
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,32 @@ | ||
import VGithubIcon from './index'; | ||
|
||
export default { title: 'GitHub Icon' }; | ||
|
||
export const withUrlProp = () => ({ | ||
components: { VGithubIcon }, | ||
template: '<v-github-icon url="https://vinayakkulkarni.dev" />', | ||
}); | ||
|
||
export const withTopLeftPosition = () => ({ | ||
components: { VGithubIcon }, | ||
template: | ||
'<v-github-icon url="https://vinayakkulkarni.dev" position="top-left" />', | ||
}); | ||
|
||
export const withBgColorProp = () => ({ | ||
components: { VGithubIcon }, | ||
template: | ||
'<v-github-icon url="https://vinayakkulkarni.dev" bg-color="red" />', | ||
}); | ||
|
||
export const withFillColorProp = () => ({ | ||
components: { VGithubIcon }, | ||
template: | ||
'<v-github-icon url="https://vinayakkulkarni.dev" fill-color="red" />', | ||
}); | ||
|
||
export const withBgAndFillColorProp = () => ({ | ||
components: { VGithubIcon }, | ||
template: | ||
'<v-github-icon url="https://vinayakkulkarni.dev" bg-color="rgba(10, 150, 200)" fill-color="rgba(255, 150, 20)" />', | ||
}); |