Skip to content

Commit

Permalink
feat(components): add tabs to daisy implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
gilf committed Dec 16, 2022
1 parent 9cb27c0 commit 37808b9
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 0 deletions.
Empty file.
17 changes: 17 additions & 0 deletions packages/daisy/src/components/tabs/tab.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import {component$, Slot} from '@builder.io/qwik';

interface TabProps {
class?: string;
className?: string;
isActive?: boolean;
isLifted?: boolean;
isBordered?: boolean;
}

export const Tab = component$(({ isActive, isBordered, isLifted, ...props } : TabProps) => {
return (
<a class={`tab ${isActive ? 'tab-active' : ''} ${isBordered ? 'tab-bordered' : ''} ${isLifted ? 'tab-lifted' : ''}`} {...props}>
<Slot />
</a>
);
});
Empty file.
15 changes: 15 additions & 0 deletions packages/daisy/src/components/tabs/tabs.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import {component$, Slot} from '@builder.io/qwik';

interface TabsProps {
class?: string;
className?: string;
boxed?: boolean;
}

export const Tabs = component$(({ boxed = false, ...props } : TabsProps) => {
return (
<div class={`tabs ${boxed ? 'tabs-boxed' : ''}`} {...props}>
<Slot />
</div>
);
});

0 comments on commit 37808b9

Please # to comment.