flowbite-svelte 0.14.14 → 0.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/LICENSE +22 -0
- package/README.md +84 -76
- package/accordions/AccordionDefault.svelte +1 -1
- package/accordions/AccordionItem.svelte +1 -1
- package/alerts/Alert.svelte +1 -1
- package/alerts/BorderAlert.svelte +1 -1
- package/alerts/InfoAlert.svelte +1 -1
- package/auth/Confirm.svelte +1 -1
- package/auth/ForgotPassword.svelte +1 -1
- package/auth/Login.svelte +1 -1
- package/auth/Register.svelte +1 -1
- package/auth/Reset.svelte +1 -1
- package/avatar/Avatar.svelte +1 -1
- package/badges/Badge.svelte +1 -1
- package/badges/BadgeIcon.svelte +1 -1
- package/badges/BadgeLink.svelte +1 -1
- package/breadcrumbs/Breadcrumb.svelte +1 -1
- package/buttongroups/ButtonGroup.svelte +5 -5
- package/buttongroups/ButtonGroupOutline.svelte +5 -5
- package/buttons/Button.svelte +1 -1
- package/buttons/ColorShadowButton.svelte +1 -1
- package/buttons/GradientDuotoneButton.svelte +1 -1
- package/buttons/GradientMonochromeButton.svelte +1 -1
- package/buttons/GradientOutlineButton.svelte +1 -1
- package/cards/Card.svelte +1 -1
- package/cards/CtaCard.svelte +1 -1
- package/cards/EcommerceCard.svelte +1 -1
- package/cards/HorizontalCard.svelte +1 -1
- package/cards/InteractiveCard.svelte +1 -1
- package/cards/ListCard.svelte +1 -1
- package/cards/SignInCard.svelte +1 -1
- package/carousels/Caption.svelte +1 -1
- package/carousels/Carousel.svelte +16 -60
- package/carousels/Carousel.svelte.d.ts +2 -0
- package/carousels/CarouselTransition.svelte +16 -60
- package/carousels/CarouselTransition.svelte.d.ts +2 -0
- package/carousels/Indicator.svelte +1 -1
- package/carousels/Slide.svelte +1 -1
- package/carousels/Thumbnail.svelte +1 -1
- package/darkmode/DarkMode.svelte +1 -1
- package/dropdowns/DropdownDefault.svelte +1 -1
- package/dropdowns/ImgDropdown.svelte +1 -1
- package/footer/LogoFooter.svelte +1 -1
- package/footer/SimpleFooter.svelte +1 -1
- package/footer/SitemapFooter.svelte +2 -4
- package/footer/SocialMediaFooter.svelte +2 -2
- package/forms/Checkbox.svelte +1 -1
- package/forms/Fileupload.svelte +1 -1
- package/forms/FloatingLabelInput.svelte +1 -1
- package/forms/Iconinput.svelte +4 -3
- package/forms/Iconinput.svelte.d.ts +1 -0
- package/forms/Input.svelte +1 -1
- package/forms/Radio.svelte +1 -1
- package/forms/Select.svelte +1 -1
- package/forms/SingleCheckbox.svelte +1 -1
- package/forms/Textarea.svelte +1 -1
- package/forms/Toggle.svelte +1 -1
- package/list-group/List.svelte +5 -5
- package/modals/ExtraLargeModal.svelte +1 -1
- package/modals/LargeModal.svelte +1 -1
- package/modals/MediumModal.svelte +1 -1
- package/modals/ModalButton.svelte +1 -1
- package/modals/SignInModal.svelte +1 -1
- package/modals/SmallModal.svelte +1 -1
- package/navbar/DropdownNavbar.svelte +1 -1
- package/navbar/NavDropdown.svelte +1 -1
- package/navbar/Navbar.svelte +1 -1
- package/package.json +4 -3
- package/paginations/Next.svelte +1 -1
- package/paginations/Pagination.svelte +1 -1
- package/paginations/Previous.svelte +1 -1
- package/paginations/TableData.svelte +1 -1
- package/progressbars/Progressbar.svelte +1 -1
- package/ratings/AdvancedRating.svelte +1 -1
- package/ratings/Rating.svelte +3 -3
- package/ratings/RatingComment.svelte +1 -1
- package/ratings/ScoreRating.svelte +1 -1
- package/sidebars/Sidebar.svelte +5 -14
- package/sidebars/SidebarDropdown.svelte +5 -27
- package/spinners/Spinner.svelte +1 -1
- package/spinners/SpinnerButton.svelte +1 -1
- package/tables/Table.svelte +1 -1
- package/tables/TableCheckbox.svelte +1 -1
- package/tables/TableDefaultRow.svelte +1 -1
- package/tables/TableSearch.svelte +1 -1
- package/tabs/DefaultTabs.svelte +1 -1
- package/tabs/FullWidthTabs.svelte +1 -1
- package/tabs/IconTabs.svelte +3 -3
- package/tabs/InteractiveTabHead.svelte +1 -1
- package/tabs/InteractiveTabs.svelte +1 -1
- package/tabs/PillTabs.svelte +1 -1
- package/tabs/TabContent.svelte +1 -1
- package/tabs/UnderlineTabs.svelte +1 -1
- package/timelines/Activity.svelte +1 -1
- package/timelines/ActivityItem.svelte +1 -1
- package/timelines/Group.svelte +1 -1
- package/timelines/GroupItem.svelte +1 -1
- package/timelines/Timeline.svelte +1 -1
- package/timelines/TimelineHorizontal.svelte +1 -1
- package/timelines/TimelineItem.svelte +1 -1
- package/timelines/TimelineItemHorizontal.svelte +6 -20
- package/timelines/TimelineItemVertical.svelte +8 -34
- package/toasts/Toast.svelte +1 -1
- package/tooltips/LightTooltip.svelte +1 -1
- package/tooltips/Tooltip.svelte +1 -1
- package/types.d.ts +11 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import Slide from './Slide.svelte';
|
|
2
2
|
import Thumbnail from './Thumbnail.svelte';
|
|
3
3
|
import Caption from './Caption.svelte';
|
|
4
4
|
import Indicator from './Indicator.svelte';
|
|
@@ -7,6 +7,8 @@ export let showCaptions = true;
|
|
|
7
7
|
export let showThumbs = true;
|
|
8
8
|
export let images;
|
|
9
9
|
export let slideControls = true;
|
|
10
|
+
export let loop = false;
|
|
11
|
+
export let duration = 2000;
|
|
10
12
|
// Carousel
|
|
11
13
|
export let divClass = 'overflow-hidden relative h-56 rounded-lg sm:h-64 xl:h-80 2xl:h-96';
|
|
12
14
|
export let indicatorDivClass = 'flex absolute bottom-5 left-1/2 z-30 space-x-3 -translate-x-1/2';
|
|
@@ -37,6 +39,11 @@ const prevSlide = () => {
|
|
|
37
39
|
};
|
|
38
40
|
const goToSlide = (number) => (imageShowingIndex = number);
|
|
39
41
|
let thumbWidth = 100 / images.length;
|
|
42
|
+
if (loop) {
|
|
43
|
+
setInterval(() => {
|
|
44
|
+
nextSlide();
|
|
45
|
+
}, duration);
|
|
46
|
+
}
|
|
40
47
|
</script>
|
|
41
48
|
|
|
42
49
|
<div id="default-carousel" class="relative">
|
|
@@ -47,64 +54,21 @@ let thumbWidth = 100 / images.length;
|
|
|
47
54
|
<!-- Slider indicators -->
|
|
48
55
|
<div class={indicatorDivClass}>
|
|
49
56
|
{#each images as { id, imgurl, name, attribution }}
|
|
50
|
-
<Indicator
|
|
51
|
-
{name}
|
|
52
|
-
selected={imageShowingIndex === id}
|
|
53
|
-
on:click={() => goToSlide(id)}
|
|
54
|
-
{indicatorClass}
|
|
55
|
-
/>
|
|
57
|
+
<Indicator {name} selected={imageShowingIndex === id} on:click={() => goToSlide(id)} {indicatorClass} />
|
|
56
58
|
{/each}
|
|
57
59
|
</div>
|
|
58
60
|
{/if}
|
|
59
61
|
{#if slideControls}
|
|
60
62
|
<!-- Slider controls -->
|
|
61
|
-
<button
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
class="flex absolute top-0 left-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none"
|
|
65
|
-
data-carousel-prev
|
|
66
|
-
>
|
|
67
|
-
<span
|
|
68
|
-
class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none"
|
|
69
|
-
>
|
|
70
|
-
<svg
|
|
71
|
-
class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300"
|
|
72
|
-
fill="none"
|
|
73
|
-
stroke="currentColor"
|
|
74
|
-
viewBox="0 0 24 24"
|
|
75
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
76
|
-
><path
|
|
77
|
-
stroke-linecap="round"
|
|
78
|
-
stroke-linejoin="round"
|
|
79
|
-
stroke-width="2"
|
|
80
|
-
d="M15 19l-7-7 7-7"
|
|
81
|
-
/></svg
|
|
82
|
-
>
|
|
63
|
+
<button on:click={prevSlide} type="button" class="flex absolute top-0 left-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none" data-carousel-prev>
|
|
64
|
+
<span class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none">
|
|
65
|
+
<svg class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7" /></svg>
|
|
83
66
|
<span class="hidden">Previous</span>
|
|
84
67
|
</span>
|
|
85
68
|
</button>
|
|
86
|
-
<button
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
class="flex absolute top-0 right-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none"
|
|
90
|
-
data-carousel-next
|
|
91
|
-
>
|
|
92
|
-
<span
|
|
93
|
-
class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none"
|
|
94
|
-
>
|
|
95
|
-
<svg
|
|
96
|
-
class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300"
|
|
97
|
-
fill="none"
|
|
98
|
-
stroke="currentColor"
|
|
99
|
-
viewBox="0 0 24 24"
|
|
100
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
101
|
-
><path
|
|
102
|
-
stroke-linecap="round"
|
|
103
|
-
stroke-linejoin="round"
|
|
104
|
-
stroke-width="2"
|
|
105
|
-
d="M9 5l7 7-7 7"
|
|
106
|
-
/></svg
|
|
107
|
-
>
|
|
69
|
+
<button on:click={nextSlide} type="button" class="flex absolute top-0 right-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none" data-carousel-next>
|
|
70
|
+
<span class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none">
|
|
71
|
+
<svg class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7" /></svg>
|
|
108
72
|
<span class="hidden">Next</span>
|
|
109
73
|
</span>
|
|
110
74
|
</button>
|
|
@@ -118,15 +82,7 @@ let thumbWidth = 100 / images.length;
|
|
|
118
82
|
{#if showThumbs}
|
|
119
83
|
<div class="flex flex-row justify-center bg-gray-100">
|
|
120
84
|
{#each images as { id, imgurl, name, attribution }}
|
|
121
|
-
<Thumbnail
|
|
122
|
-
{thumbWidth}
|
|
123
|
-
thumbImg={imgurl}
|
|
124
|
-
altTag={name}
|
|
125
|
-
titleLink={attribution}
|
|
126
|
-
{id}
|
|
127
|
-
selected={imageShowingIndex === id}
|
|
128
|
-
on:click={() => goToSlide(id)}
|
|
129
|
-
/>
|
|
85
|
+
<Thumbnail {thumbWidth} thumbImg={imgurl} altTag={name} titleLink={attribution} {id} selected={imageShowingIndex === id} on:click={() => goToSlide(id)} />
|
|
130
86
|
{/each}
|
|
131
87
|
</div>
|
|
132
88
|
{/if}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { fade, blur, fly, slide } from 'svelte/transition';
|
|
2
2
|
import Slide from './Slide.svelte';
|
|
3
3
|
import Thumbnail from './Thumbnail.svelte';
|
|
4
4
|
import Caption from './Caption.svelte';
|
|
@@ -10,6 +10,8 @@ export let images;
|
|
|
10
10
|
export let slideControls = true;
|
|
11
11
|
export let transitionType;
|
|
12
12
|
export let transitionParams = {};
|
|
13
|
+
export let loop = false;
|
|
14
|
+
export let duration = 2000;
|
|
13
15
|
// have a custom transition function that returns the desired transition
|
|
14
16
|
function multiple(node, params) {
|
|
15
17
|
switch (transitionType) {
|
|
@@ -53,6 +55,11 @@ const prevSlide = () => {
|
|
|
53
55
|
};
|
|
54
56
|
const goToSlide = (number) => (imageShowingIndex = number);
|
|
55
57
|
let thumbWidth = 100 / images.length;
|
|
58
|
+
if (loop) {
|
|
59
|
+
setInterval(() => {
|
|
60
|
+
nextSlide();
|
|
61
|
+
}, duration);
|
|
62
|
+
}
|
|
56
63
|
</script>
|
|
57
64
|
|
|
58
65
|
<div id="default-carousel" class="relative">
|
|
@@ -70,64 +77,21 @@ let thumbWidth = 100 / images.length;
|
|
|
70
77
|
<!-- Slider indicators -->
|
|
71
78
|
<div class={indicatorDivClass}>
|
|
72
79
|
{#each images as { id, imgurl, name, attribution }}
|
|
73
|
-
<Indicator
|
|
74
|
-
{name}
|
|
75
|
-
selected={imageShowingIndex === id}
|
|
76
|
-
on:click={() => goToSlide(id)}
|
|
77
|
-
{indicatorClass}
|
|
78
|
-
/>
|
|
80
|
+
<Indicator {name} selected={imageShowingIndex === id} on:click={() => goToSlide(id)} {indicatorClass} />
|
|
79
81
|
{/each}
|
|
80
82
|
</div>
|
|
81
83
|
{/if}
|
|
82
84
|
{#if slideControls}
|
|
83
85
|
<!-- Slider controls -->
|
|
84
|
-
<button
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
class="flex absolute top-0 left-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none"
|
|
88
|
-
data-carousel-prev
|
|
89
|
-
>
|
|
90
|
-
<span
|
|
91
|
-
class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none"
|
|
92
|
-
>
|
|
93
|
-
<svg
|
|
94
|
-
class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300"
|
|
95
|
-
fill="none"
|
|
96
|
-
stroke="currentColor"
|
|
97
|
-
viewBox="0 0 24 24"
|
|
98
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
99
|
-
><path
|
|
100
|
-
stroke-linecap="round"
|
|
101
|
-
stroke-linejoin="round"
|
|
102
|
-
stroke-width="2"
|
|
103
|
-
d="M15 19l-7-7 7-7"
|
|
104
|
-
/></svg
|
|
105
|
-
>
|
|
86
|
+
<button on:click={prevSlide} type="button" class="flex absolute top-0 left-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none" data-carousel-prev>
|
|
87
|
+
<span class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none">
|
|
88
|
+
<svg class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19l-7-7 7-7" /></svg>
|
|
106
89
|
<span class="hidden">Previous</span>
|
|
107
90
|
</span>
|
|
108
91
|
</button>
|
|
109
|
-
<button
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
class="flex absolute top-0 right-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none"
|
|
113
|
-
data-carousel-next
|
|
114
|
-
>
|
|
115
|
-
<span
|
|
116
|
-
class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none"
|
|
117
|
-
>
|
|
118
|
-
<svg
|
|
119
|
-
class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300"
|
|
120
|
-
fill="none"
|
|
121
|
-
stroke="currentColor"
|
|
122
|
-
viewBox="0 0 24 24"
|
|
123
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
124
|
-
><path
|
|
125
|
-
stroke-linecap="round"
|
|
126
|
-
stroke-linejoin="round"
|
|
127
|
-
stroke-width="2"
|
|
128
|
-
d="M9 5l7 7-7 7"
|
|
129
|
-
/></svg
|
|
130
|
-
>
|
|
92
|
+
<button on:click={nextSlide} type="button" class="flex absolute top-0 right-0 z-30 justify-center items-center px-4 h-full cursor-pointer group focus:outline-none" data-carousel-next>
|
|
93
|
+
<span class="inline-flex justify-center items-center w-8 h-8 rounded-full sm:w-10 sm:h-10 bg-white/30 dark:bg-gray-800/30 group-hover:bg-white/50 dark:group-hover:bg-gray-800/60 group-focus:ring-4 group-focus:ring-white dark:group-focus:ring-gray-800/70 group-focus:outline-none">
|
|
94
|
+
<svg class="w-5 h-5 text-white sm:w-6 sm:h-6 dark:text-gray-300" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7" /></svg>
|
|
131
95
|
<span class="hidden">Next</span>
|
|
132
96
|
</span>
|
|
133
97
|
</button>
|
|
@@ -141,15 +105,7 @@ let thumbWidth = 100 / images.length;
|
|
|
141
105
|
{#if showThumbs}
|
|
142
106
|
<div class="flex flex-row justify-center bg-gray-100">
|
|
143
107
|
{#each images as { id, imgurl, name, attribution }}
|
|
144
|
-
<Thumbnail
|
|
145
|
-
{thumbWidth}
|
|
146
|
-
thumbImg={imgurl}
|
|
147
|
-
altTag={name}
|
|
148
|
-
titleLink={attribution}
|
|
149
|
-
{id}
|
|
150
|
-
selected={imageShowingIndex === id}
|
|
151
|
-
on:click={() => goToSlide(id)}
|
|
152
|
-
/>
|
|
108
|
+
<Thumbnail {thumbWidth} thumbImg={imgurl} altTag={name} titleLink={attribution} {id} selected={imageShowingIndex === id} on:click={() => goToSlide(id)} />
|
|
153
109
|
{/each}
|
|
154
110
|
</div>
|
|
155
111
|
{/if}
|
package/carousels/Slide.svelte
CHANGED
package/darkmode/DarkMode.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { onMount } from 'svelte';
|
|
2
2
|
export let btnClass = 'text-gray-500 dark:text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-700 focus:outline-none focus:ring-4 focus:ring-gray-200 dark:focus:ring-gray-700 rounded-lg text-sm p-2.5 fixed left-0 top-8 z-50';
|
|
3
3
|
let mode;
|
|
4
4
|
const toggleTheme = () => {
|
package/footer/LogoFooter.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let site;
|
|
2
2
|
export let links;
|
|
3
3
|
export let footerClass = 'p-4 bg-white rounded-lg shadow md:flex md:items-center md:justify-between md:p-6 dark:bg-gray-800';
|
|
4
4
|
export let siteNameClass = 'text-sm text-gray-500 sm:text-center dark:text-gray-400';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let site;
|
|
2
2
|
export let links;
|
|
3
3
|
export let socialMedia;
|
|
4
4
|
export let footerClass = 'bg-white dark:bg-gray-800';
|
|
@@ -34,9 +34,7 @@ export let allRightsReserved = 'All Rights Reserved.';
|
|
|
34
34
|
{/each}
|
|
35
35
|
</div>
|
|
36
36
|
<div class={copyrightDivClass}>
|
|
37
|
-
<span class={copyrightClass}
|
|
38
|
-
>{copyrightYear} <a href={site.href}>{site.name}</a>. {allRightsReserved}
|
|
39
|
-
</span>
|
|
37
|
+
<span class={copyrightClass}>{copyrightYear} <a href={site.href}>{site.name}</a>. {allRightsReserved} </span>
|
|
40
38
|
<div class={socialMediaDivClass}>
|
|
41
39
|
{#each socialMedia as { href, icon }}
|
|
42
40
|
<a {href} class={socialMediaLinkClass}>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let site;
|
|
2
2
|
export let links;
|
|
3
3
|
export let socialMedia;
|
|
4
4
|
export let footerClass = 'p-4 bg-white sm:p-6 dark:bg-gray-800';
|
|
@@ -56,7 +56,7 @@ export let allRightsReserved = 'All Rights Reserved.';
|
|
|
56
56
|
<div class={socialMediaDivClass}>
|
|
57
57
|
{#each socialMedia as { href, icon }}
|
|
58
58
|
<a {href} class={socialMediaLinkClass}>
|
|
59
|
-
<svelte:component this={icon}
|
|
59
|
+
<svelte:component this={icon} class={iconClass} />
|
|
60
60
|
</a>
|
|
61
61
|
{/each}
|
|
62
62
|
</div>
|
package/forms/Checkbox.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let legend = 'Checkbox variants';
|
|
2
2
|
export let divClass = 'flex items-center mb-4';
|
|
3
3
|
export let inputClass = 'w-4 h-4 text-blue-600 bg-gray-100 rounded border-gray-300 focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
4
4
|
export let labelClass = 'ml-3 text-sm font-medium text-gray-900 dark:text-gray-300';
|
package/forms/Fileupload.svelte
CHANGED
package/forms/Iconinput.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import generateId from '../utils/generateId.js';
|
|
2
2
|
export let label;
|
|
3
3
|
export let id = generateId();
|
|
4
4
|
export let type;
|
|
@@ -14,6 +14,7 @@ export let helperClass = 'mt-2 text-sm text-gray-500 dark:text-gray-400';
|
|
|
14
14
|
export let noBorderInputClass = 'bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg focus:ring-blue-500 focus:border-blue-500 block w-full pl-10 p-2.5 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500';
|
|
15
15
|
export let noBorderDivClass = 'flex absolute inset-y-0 left-0 items-center pl-3 pointer-events-none';
|
|
16
16
|
export let iconClass = 'h-4 w-4 mr-2';
|
|
17
|
+
export let iconSize = 18;
|
|
17
18
|
function setType(node) {
|
|
18
19
|
node.type = type;
|
|
19
20
|
}
|
|
@@ -24,14 +25,14 @@ function setType(node) {
|
|
|
24
25
|
{#if noBorder}
|
|
25
26
|
<div class="relative">
|
|
26
27
|
<div class={noBorderDivClass}>
|
|
27
|
-
<svelte:component this={icon}
|
|
28
|
+
<svelte:component this={icon} size={iconSize} class={iconClass} />
|
|
28
29
|
</div>
|
|
29
30
|
<input bind:value use:setType {id} class={noBorderInputClass} {placeholder} />
|
|
30
31
|
</div>
|
|
31
32
|
{:else}
|
|
32
33
|
<div class="flex">
|
|
33
34
|
<span class={spanClass}>
|
|
34
|
-
<svelte:component this={icon}
|
|
35
|
+
<svelte:component this={icon} size={iconSize} class={iconClass} />
|
|
35
36
|
</span>
|
|
36
37
|
<input {type} {id} class={inputClass} {placeholder} />
|
|
37
38
|
</div>
|
package/forms/Input.svelte
CHANGED
package/forms/Radio.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let legend = '';
|
|
2
2
|
export let divClass = 'flex items-center mb-4';
|
|
3
3
|
export let inputClass = 'w-4 h-4 border-gray-300 focus:ring-2 focus:ring-blue-300 dark:focus:ring-blue-600 dark:focus:bg-blue-600 dark:bg-gray-700 dark:border-gray-600';
|
|
4
4
|
export let labelClass = 'block ml-2 text-sm font-medium text-gray-900 dark:text-gray-300';
|
package/forms/Select.svelte
CHANGED
package/forms/Textarea.svelte
CHANGED
package/forms/Toggle.svelte
CHANGED
package/list-group/List.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let lists;
|
|
2
2
|
const common = 'inline-flex relative items-center py-2 px-4 w-full text-sm font-medium hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-2 focus:ring-blue-700 focus:text-blue-700 dark:border-gray-600 dark:hover:bg-gray-600 dark:hover:text-white dark:focus:ring-gray-500 dark:focus:text-white';
|
|
3
3
|
const topClass = `${common} rounded-t-lg border-b border-gray-200`;
|
|
4
4
|
const bottomClass = `${common} rounded-b-lg`;
|
|
@@ -6,11 +6,11 @@ const middleClass = `${common} border-b border-gray-200`;
|
|
|
6
6
|
</script>
|
|
7
7
|
|
|
8
8
|
<div class="w-48 text-gray-900 bg-white rounded-lg border border-gray-200 dark:bg-gray-700 dark:border-gray-600 dark:text-white">
|
|
9
|
-
{#each lists as { name, icon, href, rel }, i}
|
|
9
|
+
{#each lists as { name, icon, href, rel, iconClass, iconSize }, i}
|
|
10
10
|
{#if i === 0}
|
|
11
11
|
<button type="button" class={topClass}>
|
|
12
12
|
{#if icon}
|
|
13
|
-
<svelte:component this={icon}
|
|
13
|
+
<svelte:component this={icon} class="mr-2 {iconClass}" size={iconSize} />
|
|
14
14
|
{/if}
|
|
15
15
|
{#if href}
|
|
16
16
|
<a {href} {rel}>{name}</a>
|
|
@@ -21,7 +21,7 @@ const middleClass = `${common} border-b border-gray-200`;
|
|
|
21
21
|
{:else if i === lists.length - 1}
|
|
22
22
|
<button type="button" class={bottomClass}>
|
|
23
23
|
{#if icon}
|
|
24
|
-
<svelte:component this={icon}
|
|
24
|
+
<svelte:component this={icon} class="mr-2 {iconClass}" size={iconSize} />
|
|
25
25
|
{/if}
|
|
26
26
|
{#if href}
|
|
27
27
|
<a {href} {rel}>{name}</a>
|
|
@@ -32,7 +32,7 @@ const middleClass = `${common} border-b border-gray-200`;
|
|
|
32
32
|
{:else}
|
|
33
33
|
<button type="button" class={middleClass}>
|
|
34
34
|
{#if icon}
|
|
35
|
-
<svelte:component this={icon}
|
|
35
|
+
<svelte:component this={icon} class="mr-2 {iconClass}" size={iconSize} />
|
|
36
36
|
{/if}
|
|
37
37
|
{#if href}
|
|
38
38
|
<a {href} {rel}>{name}</a>
|
package/modals/LargeModal.svelte
CHANGED
package/modals/SmallModal.svelte
CHANGED
package/navbar/Navbar.svelte
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowbite-svelte",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "Flowbite components for Svelte",
|
|
5
5
|
"main": "./package/index.js",
|
|
6
6
|
"author": {
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"homepage": "https://flowbite-svelte.com/",
|
|
13
13
|
"license": "MIT",
|
|
14
14
|
"devDependencies": {
|
|
15
|
+
"@codewithshin/svelte-feathericons": "^0.1.9",
|
|
15
16
|
"@codewithshin/svelte-sidebar": "^0.4.8",
|
|
16
17
|
"@codewithshin/svelte-simpleicons": "^0.2.2",
|
|
17
18
|
"@codewithshin/svelte-utterances": "^0.2.2",
|
|
@@ -31,7 +32,7 @@
|
|
|
31
32
|
"prettier": "^2.5.1",
|
|
32
33
|
"prettier-plugin-svelte": "^2.5.0",
|
|
33
34
|
"prism-themes": "^1.9.0",
|
|
34
|
-
"svelte": "^3.
|
|
35
|
+
"svelte": "^3.47.0",
|
|
35
36
|
"svelte-check": "^2.2.6",
|
|
36
37
|
"svelte-preprocess": "^4.10.5",
|
|
37
38
|
"svelte2tsx": "^0.5.9",
|
|
@@ -77,7 +78,7 @@
|
|
|
77
78
|
"url": "https://github.com/themesberg/flowbite-svelte"
|
|
78
79
|
},
|
|
79
80
|
"dependencies": {
|
|
80
|
-
"@codewithshin/svelte-heroicons": "^1.
|
|
81
|
+
"@codewithshin/svelte-heroicons": "^1.2.0",
|
|
81
82
|
"flowbite": "^1.4.2",
|
|
82
83
|
"svelte-collapse": "^0.0.4"
|
|
83
84
|
},
|
package/paginations/Next.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let ratings = [];
|
|
2
2
|
export let divClass = 'flex items-center mt-4';
|
|
3
3
|
export let labelClass = 'text-sm font-medium text-blue-600 dark:text-blue-500';
|
|
4
4
|
export let ratingDivClass = 'mx-4 w-2/4 h-5 bg-gray-200 rounded dark:bg-gray-700';
|