Skip to content

Commit

Permalink
fix some types and add collapsible stories file
Browse files Browse the repository at this point in the history
  • Loading branch information
elevatebart committed Feb 4, 2025
1 parent c9220dd commit fc61f0e
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/misc/TaskIcon.vue
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
color = cssVariable(props.variable) ?? color;
}
localIcon = localIcon.replaceAll("currentColor", color);
localIcon = localIcon.replace(/currentColor/g, color);
return window.btoa(localIcon);
})
Expand Down
32 changes: 32 additions & 0 deletions storybook/components/misc/Collapsible.stories.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import Collapsible from "../../../src/components/misc/Collapsible.vue";

export default {
title: "Components/Misc/Collapsible",
component: Collapsible,
};

const Template = (args) => ({
setup() {
return () => <Collapsible {...args}>
{{
content: () => <>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam nec purus nec nunc tincidunt ultricies. Nullam nec purus nec nunc</>
}}
</Collapsible>
}
});

export const Default = Template.bind({});
Default.args = {
href: "example",
clickableText: "Click me",
arrow: true,
initiallyExpanded: false,
};

export const InitiallyExpanded = Template.bind({});
InitiallyExpanded.args = {
href: "example-expanded",
clickableText: "Click me",
arrow: true,
initiallyExpanded: true,
};

1 comment on commit fc61f0e

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.