|
| 1 | +{ |
| 2 | + "Storybook Story Impl File": { |
| 3 | + "scope": "typescript", |
| 4 | + "prefix": "storyimpl", |
| 5 | + "body": [ |
| 6 | + "/* eslint-disable @typescript-eslint/explicit-function-return-type */", |
| 7 | + "import { StoryObj } from '@storybook/vue3';", |
| 8 | + "import $1 from './$1.vue';", |
| 9 | + "export const Default = {", |
| 10 | + "\trender(args) {", |
| 11 | + "\t\treturn {", |
| 12 | + "\t\t\tcomponents: {", |
| 13 | + "\t\t\t\t$1,", |
| 14 | + "\t\t\t},", |
| 15 | + "\t\t\tsetup() {", |
| 16 | + "\t\t\t\treturn {", |
| 17 | + "\t\t\t\t\targs,", |
| 18 | + "\t\t\t\t};", |
| 19 | + "\t\t\t},", |
| 20 | + "\t\t\tcomputed: {", |
| 21 | + "\t\t\t\tprops() {", |
| 22 | + "\t\t\t\t\treturn {", |
| 23 | + "\t\t\t\t\t\t...this.args,", |
| 24 | + "\t\t\t\t\t};", |
| 25 | + "\t\t\t\t},", |
| 26 | + "\t\t\t},", |
| 27 | + "\t\t\ttemplate: '<$1 v-bind=\"props\" />',", |
| 28 | + "\t\t};", |
| 29 | + "\t},", |
| 30 | + "\targs: {", |
| 31 | + "\t\t$2", |
| 32 | + "\t},", |
| 33 | + "\tparameters: {", |
| 34 | + "\t\tlayout: 'centered',", |
| 35 | + "\t},", |
| 36 | + "} satisfies StoryObj<typeof $1>;", |
| 37 | + "" |
| 38 | + ] |
| 39 | + }, |
| 40 | + "Storybook Story Impl File (w/ events)": { |
| 41 | + "scope": "typescript", |
| 42 | + "prefix": "storyimplevent", |
| 43 | + "body": [ |
| 44 | + "/* eslint-disable @typescript-eslint/explicit-function-return-type */", |
| 45 | + "import { action } from '@storybook/addon-actions';", |
| 46 | + "import { StoryObj } from '@storybook/vue3';", |
| 47 | + "import $1 from './$1.vue';", |
| 48 | + "export const Default = {", |
| 49 | + "\trender(args) {", |
| 50 | + "\t\treturn {", |
| 51 | + "\t\t\tcomponents: {", |
| 52 | + "\t\t\t\t$1,", |
| 53 | + "\t\t\t},", |
| 54 | + "\t\t\tsetup() {", |
| 55 | + "\t\t\t\treturn {", |
| 56 | + "\t\t\t\t\targs,", |
| 57 | + "\t\t\t\t};", |
| 58 | + "\t\t\t},", |
| 59 | + "\t\t\tcomputed: {", |
| 60 | + "\t\t\t\tprops() {", |
| 61 | + "\t\t\t\t\treturn {", |
| 62 | + "\t\t\t\t\t\t...this.args,", |
| 63 | + "\t\t\t\t\t};", |
| 64 | + "\t\t\t\t},", |
| 65 | + "\t\t\t\tevents() {", |
| 66 | + "\t\t\t\t\treturn {", |
| 67 | + "\t\t\t\t\t\t$3", |
| 68 | + "\t\t\t\t\t};", |
| 69 | + "\t\t\t\t},", |
| 70 | + "\t\t\t},", |
| 71 | + "\t\t\ttemplate: '<$1 v-bind=\"props\" v-on=\"events\" />',", |
| 72 | + "\t\t};", |
| 73 | + "\t},", |
| 74 | + "\targs: {", |
| 75 | + "\t\t$2", |
| 76 | + "\t},", |
| 77 | + "\tparameters: {", |
| 78 | + "\t\tlayout: 'centered',", |
| 79 | + "\t},", |
| 80 | + "} satisfies StoryObj<typeof $1>;", |
| 81 | + "" |
| 82 | + ] |
| 83 | + } |
| 84 | +} |
0 commit comments