add source code

This commit is contained in:
Jacob Overgaard
2023-08-01 14:20:44 +02:00
parent 60d8b49f5c
commit 8d4e5cd603

View File

@@ -23,6 +23,13 @@ const meta: Meta<UmbLocalizeElement> = {
</div>`;
},
],
};
export default meta;
type Story = StoryObj<UmbLocalizeElement>;
export const Default: Story = {
parameters: {
docs: {
source: {
@@ -32,17 +39,18 @@ const meta: Meta<UmbLocalizeElement> = {
},
};
export default meta;
type Story = StoryObj<UmbLocalizeElement>;
export const Overview: Story = {};
export const WithArguments: Story = {
args: {
key: 'blueprints_createdBlueprintMessage',
args: ['About us'],
},
parameters: {
docs: {
source: {
code: `<umb-localize key="blueprints_createdBlueprintMessage" args="['About us']"></umb-localize>`,
},
},
},
};
export const KeyNotFound: Story = {
@@ -50,4 +58,11 @@ export const KeyNotFound: Story = {
key: 'general_ok_not_found',
debug: true,
},
parameters: {
docs: {
source: {
code: `<umb-localize key="general_ok_not_found"></umb-localize>`,
},
},
},
};