flowbite-svelte 0.15.22 → 0.15.23
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 +14 -0
- package/alerts/Alert.svelte +72 -99
- package/alerts/Alert.svelte.d.ts +8 -4
- package/badges/Badge.svelte +10 -13
- package/badges/BadgeIcon.svelte +10 -13
- package/badges/BadgeLink.svelte +10 -13
- package/buttongroups/ButtonGroup.svelte +7 -6
- package/buttongroups/ButtonGroupOutline.svelte +7 -6
- package/buttons/ColorShadowButton.svelte +10 -13
- package/buttons/GradientDuotoneButton.svelte +9 -12
- package/buttons/GradientMonochromeButton.svelte +10 -13
- package/buttons/GradientOutlineButton.svelte +10 -21
- package/cards/Card.svelte +10 -13
- package/cards/CtaCard.svelte +9 -12
- package/cards/EcommerceCard.svelte +19 -23
- package/cards/InteractiveCard.svelte +10 -13
- package/cards/SignInCard.svelte +10 -10
- package/dropdowns/DropdownDefault.svelte +15 -19
- package/forms/Checkbox.svelte +8 -8
- package/forms/RadioItem.svelte +8 -8
- package/forms/Range.svelte +4 -4
- package/index.d.ts +0 -2
- package/index.js +0 -2
- package/package.json +1 -3
- package/alerts/BorderAlert.svelte +0 -79
- package/alerts/BorderAlert.svelte.d.ts +0 -21
- package/alerts/InfoAlert.svelte +0 -120
- package/alerts/InfoAlert.svelte.d.ts +0 -23
|
@@ -2,39 +2,28 @@
|
|
|
2
2
|
export let color = 'purple2blue';
|
|
3
3
|
export let name = 'Read more';
|
|
4
4
|
export let type = 'button';
|
|
5
|
-
let btnClass
|
|
6
|
-
let spanClass;
|
|
7
|
-
if (color === '
|
|
8
|
-
btnClass
|
|
9
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
10
|
-
}
|
|
11
|
-
else if (color === 'cyan2blue') {
|
|
12
|
-
btnClass = `relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden ${textSize} font-medium text-gray-900 rounded-lg group bg-gradient-to-br from-cyan-500 to-blue-500 group-hover:from-cyan-500 group-hover:to-blue-500 hover:text-white dark:text-white focus:ring-4 focus:outline-none focus:ring-cyan-200 dark:focus:ring-cyan-800`;
|
|
13
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
5
|
+
let btnClass = `relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden ${textSize} font-medium text-gray-900 rounded-lg group bg-gradient-to-br focus:ring-4 `;
|
|
6
|
+
let spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
7
|
+
if (color === 'cyan2blue') {
|
|
8
|
+
btnClass += `from-cyan-500 to-blue-500 group-hover:from-cyan-500 group-hover:to-blue-500 hover:text-white dark:text-white focus:outline-none focus:ring-cyan-200 dark:focus:ring-cyan-800`;
|
|
14
9
|
}
|
|
15
10
|
else if (color === 'green2blue') {
|
|
16
|
-
btnClass
|
|
17
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
11
|
+
btnClass += `from-green-400 to-blue-600 group-hover:from-green-400 group-hover:to-blue-600 hover:text-white dark:text-white focus:ring-green-200 dark:focus:ring-green-800`;
|
|
18
12
|
}
|
|
19
13
|
else if (color === 'purple2pink') {
|
|
20
|
-
btnClass
|
|
21
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
14
|
+
btnClass += `from-purple-500 to-pink-500 group-hover:from-purple-500 group-hover:to-pink-500 hover:text-white dark:text-white focus:ring-purple-200 dark:focus:ring-purple-800`;
|
|
22
15
|
}
|
|
23
16
|
else if (color === 'pink2orange') {
|
|
24
|
-
btnClass
|
|
25
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
17
|
+
btnClass += `from-pink-500 to-orange-400 group-hover:from-pink-500 group-hover:to-orange-400 hover:text-white dark:text-white focus:ring-pink-200 dark:focus:ring-pink-800`;
|
|
26
18
|
}
|
|
27
19
|
else if (color === 'teal2lime') {
|
|
28
|
-
btnClass
|
|
29
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
20
|
+
btnClass += `from-teal-300 to-lime-300 group-hover:from-teal-300 group-hover:to-lime-300 dark:text-white dark:hover:text-gray-900 focus:ring-lime-200 dark:focus:ring-lime-800`;
|
|
30
21
|
}
|
|
31
22
|
else if (color === 'red2yellow') {
|
|
32
|
-
btnClass
|
|
33
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
23
|
+
btnClass += `from-red-200 via-red-300 to-yellow-200 group-hover:from-red-200 group-hover:via-red-300 group-hover:to-yellow-200 dark:text-white dark:hover:text-gray-900 focus:ring-red-100 dark:focus:ring-red-400`;
|
|
34
24
|
}
|
|
35
25
|
else {
|
|
36
|
-
btnClass
|
|
37
|
-
spanClass = 'relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0';
|
|
26
|
+
btnClass += `from-purple-600 to-blue-500 group-hover:from-purple-600 group-hover:to-blue-500 hover:text-white dark:text-white focus:ring-blue-300 dark:focus:ring-blue-800`;
|
|
38
27
|
}
|
|
39
28
|
</script>
|
|
40
29
|
|
package/cards/Card.svelte
CHANGED
|
@@ -8,33 +8,30 @@ export let textdivClass = 'p-5';
|
|
|
8
8
|
export let headerClass = 'mb-2 text-2xl font-bold tracking-tight text-gray-900 dark:text-white';
|
|
9
9
|
export let header = '';
|
|
10
10
|
export let divClass = 'max-w-sm bg-white rounded-lg border border-gray-200 shadow-md dark:bg-gray-800 dark:border-gray-700';
|
|
11
|
-
let buttonClass;
|
|
12
|
-
if (btnColor === '
|
|
13
|
-
buttonClass
|
|
14
|
-
}
|
|
15
|
-
else if (btnColor === 'gray') {
|
|
16
|
-
buttonClass = 'inline-flex items-center py-2 px-3 text-sm font-medium text-center text-white bg-gray-700 rounded-lg hover:bg-gray-800 focus:ring-4 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
11
|
+
let buttonClass = 'inline-flex items-center py-2 px-3 text-sm font-medium text-center text-white focus:ring-4 ';
|
|
12
|
+
if (btnColor === 'gray') {
|
|
13
|
+
buttonClass += 'bg-gray-700 rounded-lg hover:bg-gray-800 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
17
14
|
}
|
|
18
15
|
else if (btnColor === 'red') {
|
|
19
|
-
buttonClass
|
|
16
|
+
buttonClass += 'bg-red-700 rounded-lg hover:bg-red-800 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800';
|
|
20
17
|
}
|
|
21
18
|
else if (btnColor === 'yellow') {
|
|
22
|
-
buttonClass
|
|
19
|
+
buttonClass += 'bg-yellow-700 rounded-lg hover:bg-yellow-800 focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800';
|
|
23
20
|
}
|
|
24
21
|
else if (btnColor === 'green') {
|
|
25
|
-
buttonClass
|
|
22
|
+
buttonClass += 'bg-green-700 rounded-lg hover:bg-green-800 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800';
|
|
26
23
|
}
|
|
27
24
|
else if (btnColor === 'indigo') {
|
|
28
|
-
buttonClass
|
|
25
|
+
buttonClass += 'bg-indigo-700 rounded-lg hover:bg-indigo-800 focus:ring-indigo-300 dark:bg-indigo-600 dark:hover:bg-indigo-700 dark:focus:ring-indigo-800';
|
|
29
26
|
}
|
|
30
27
|
else if (btnColor === 'purple') {
|
|
31
|
-
buttonClass
|
|
28
|
+
buttonClass += 'bg-purple-700 rounded-lg hover:bg-purple-800 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-800';
|
|
32
29
|
}
|
|
33
30
|
else if (btnColor === 'pink') {
|
|
34
|
-
buttonClass
|
|
31
|
+
buttonClass += 'bg-pink-700 rounded-lg hover:bg-pink-800 focus:ring-pink-300 dark:bg-pink-600 dark:hover:bg-pink-700 dark:focus:ring-pink-800';
|
|
35
32
|
}
|
|
36
33
|
else {
|
|
37
|
-
buttonClass
|
|
34
|
+
buttonClass += 'bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
38
35
|
}
|
|
39
36
|
</script>
|
|
40
37
|
|
package/cards/CtaCard.svelte
CHANGED
|
@@ -3,33 +3,30 @@ export let title = 'Work fast from anywhere';
|
|
|
3
3
|
export let headColor = 'gray';
|
|
4
4
|
export let btns;
|
|
5
5
|
export let divClass = 'p-4 w-full text-center bg-white rounded-lg border shadow-md sm:p-8 dark:bg-gray-800 dark:border-gray-700';
|
|
6
|
-
let headClass;
|
|
6
|
+
let headClass = 'mb-2 text-3xl font-bold dark:text-white ';
|
|
7
7
|
if (headColor === 'blue') {
|
|
8
|
-
headClass
|
|
8
|
+
headClass += 'text-blue-900';
|
|
9
9
|
}
|
|
10
10
|
else if (headColor === 'gray') {
|
|
11
|
-
headClass
|
|
11
|
+
headClass += 'text-gray-900';
|
|
12
12
|
}
|
|
13
13
|
else if (headColor === 'red') {
|
|
14
|
-
headClass
|
|
14
|
+
headClass += 'text-red-900';
|
|
15
15
|
}
|
|
16
16
|
else if (headColor === 'yellow') {
|
|
17
|
-
headClass
|
|
17
|
+
headClass += 'text-yellow-900';
|
|
18
18
|
}
|
|
19
19
|
else if (headColor === 'green') {
|
|
20
|
-
headClass
|
|
20
|
+
headClass += 'text-green-900';
|
|
21
21
|
}
|
|
22
22
|
else if (headColor === 'indigo') {
|
|
23
|
-
headClass
|
|
23
|
+
headClass += 'text-indigo-900';
|
|
24
24
|
}
|
|
25
25
|
else if (headColor === 'purple') {
|
|
26
|
-
headClass
|
|
26
|
+
headClass += 'text-purple-900';
|
|
27
27
|
}
|
|
28
28
|
else if (headColor === 'pink') {
|
|
29
|
-
headClass
|
|
30
|
-
}
|
|
31
|
-
else {
|
|
32
|
-
headClass = 'mb-2 text-3xl font-bold text-blue-900 dark:text-white';
|
|
29
|
+
headClass += 'text-pink-900';
|
|
33
30
|
}
|
|
34
31
|
</script>
|
|
35
32
|
|
|
@@ -7,43 +7,39 @@ export let stars = 5;
|
|
|
7
7
|
export let price = '$555';
|
|
8
8
|
export let headerClass = 'text-xl font-semibold tracking-tight text-gray-900 dark:text-white';
|
|
9
9
|
export let divClass = 'max-w-sm bg-white rounded-lg shadow-md dark:bg-gray-800 dark:border-gray-700';
|
|
10
|
-
let spanClass;
|
|
11
|
-
let linkClass;
|
|
12
|
-
if (btnColor === '
|
|
13
|
-
spanClass
|
|
14
|
-
linkClass
|
|
15
|
-
}
|
|
16
|
-
else if (btnColor === 'gray') {
|
|
17
|
-
spanClass = 'bg-gray-100 text-gray-800 text-xs font-semibold mr-2 px-2.5 py-0.5 rounded dark:bg-gray-200 dark:text-gray-800 ml-3';
|
|
18
|
-
linkClass = 'text-white bg-gray-700 hover:bg-gray-800 focus:ring-4 focus:ring-gray-300 font-medium rounded-lg text-sm px-5 py-2.5 text-center dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
10
|
+
let spanClass = 'text-xs font-semibold mr-2 px-2.5 py-0.5 rounded ml-3 ';
|
|
11
|
+
let linkClass = 'text-white focus:ring-4 font-medium rounded-lg text-sm px-5 py-2.5 text-center ';
|
|
12
|
+
if (btnColor === 'gray') {
|
|
13
|
+
spanClass += 'bg-gray-100 text-gray-800 dark:bg-gray-200 dark:text-gray-800';
|
|
14
|
+
linkClass += 'bg-gray-700 hover:bg-gray-800 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
19
15
|
}
|
|
20
16
|
else if (btnColor === 'red') {
|
|
21
|
-
spanClass
|
|
22
|
-
linkClass
|
|
17
|
+
spanClass += 'bg-red-100 text-red-800 dark:bg-red-200 dark:text-red-800';
|
|
18
|
+
linkClass += 'bg-red-700 hover:bg-red-800 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800';
|
|
23
19
|
}
|
|
24
20
|
else if (btnColor === 'yellow') {
|
|
25
|
-
spanClass
|
|
26
|
-
linkClass
|
|
21
|
+
spanClass += 'bg-yellow-100 text-yellow-800 dark:bg-yellow-200 dark:text-yellow-800';
|
|
22
|
+
linkClass += 'bg-yellow-700 hover:bg-yellow-800 focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800';
|
|
27
23
|
}
|
|
28
24
|
else if (btnColor === 'green') {
|
|
29
|
-
spanClass
|
|
30
|
-
linkClass
|
|
25
|
+
spanClass += 'bg-green-100 text-green-800 dark:bg-green-200 dark:text-green-800';
|
|
26
|
+
linkClass += 'bg-green-700 hover:bg-green-800 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800';
|
|
31
27
|
}
|
|
32
28
|
else if (btnColor === 'indigo') {
|
|
33
|
-
spanClass
|
|
34
|
-
linkClass
|
|
29
|
+
spanClass += 'bg-indigo-100 text-indigo-800 dark:bg-indigo-200 dark:text-indigo-800';
|
|
30
|
+
linkClass += 'bg-indigo-700 hover:bg-indigo-800 focus:ring-indigo-300 dark:bg-indigo-600 dark:hover:bg-indigo-700 dark:focus:ring-indigo-800';
|
|
35
31
|
}
|
|
36
32
|
else if (btnColor === 'purple') {
|
|
37
|
-
spanClass
|
|
38
|
-
linkClass
|
|
33
|
+
spanClass += 'bg-purple-100 text-purple-800 dark:bg-purple-200 dark:text-purple-800';
|
|
34
|
+
linkClass += 'bg-purple-700 hover:bg-purple-800 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-800';
|
|
39
35
|
}
|
|
40
36
|
else if (btnColor === 'pink') {
|
|
41
|
-
spanClass
|
|
42
|
-
linkClass
|
|
37
|
+
spanClass += 'bg-pink-100 text-pink-800 dark:bg-pink-200 dark:text-pink-800';
|
|
38
|
+
linkClass += 'bg-pink-700 hover:bg-pink-800 focus:ring-pink-300 dark:bg-pink-600 dark:hover:bg-pink-700 dark:focus:ring-pink-800';
|
|
43
39
|
}
|
|
44
40
|
else {
|
|
45
|
-
spanClass
|
|
46
|
-
linkClass
|
|
41
|
+
spanClass += 'bg-blue-100 text-blue-800 dark:bg-blue-200 dark:text-blue-800';
|
|
42
|
+
linkClass += 'bg-blue-700 hover:bg-blue-800 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
47
43
|
}
|
|
48
44
|
</script>
|
|
49
45
|
|
|
@@ -11,33 +11,30 @@ export let link1;
|
|
|
11
11
|
export let link2;
|
|
12
12
|
export let headerClass = 'mb-1 text-xl font-medium text-gray-900 dark:text-white';
|
|
13
13
|
export let divClass = 'max-w-sm bg-white rounded-lg border border-gray-200 shadow-md dark:bg-gray-800 dark:border-gray-700';
|
|
14
|
-
let linkClass;
|
|
15
|
-
if (buttonColor === '
|
|
16
|
-
linkClass
|
|
17
|
-
}
|
|
18
|
-
else if (buttonColor === 'gray') {
|
|
19
|
-
linkClass = 'inline-flex items-center py-2 px-4 text-sm font-medium text-center text-white bg-gray-700 rounded-lg hover:bg-gray-800 focus:ring-4 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
14
|
+
let linkClass = 'inline-flex items-center py-2 px-4 text-sm font-medium text-center text-white focus:ring-4 ';
|
|
15
|
+
if (buttonColor === 'gray') {
|
|
16
|
+
linkClass += 'bg-gray-700 rounded-lg hover:bg-gray-800 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
20
17
|
}
|
|
21
18
|
else if (buttonColor === 'red') {
|
|
22
|
-
linkClass
|
|
19
|
+
linkClass += 'bg-red-700 rounded-lg hover:bg-red-800 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800';
|
|
23
20
|
}
|
|
24
21
|
else if (buttonColor === 'yellow') {
|
|
25
|
-
linkClass
|
|
22
|
+
linkClass += 'bg-yellow-700 rounded-lg hover:bg-yellow-800 focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800';
|
|
26
23
|
}
|
|
27
24
|
else if (buttonColor === 'green') {
|
|
28
|
-
linkClass
|
|
25
|
+
linkClass += 'bg-green-700 rounded-lg hover:bg-green-800 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800';
|
|
29
26
|
}
|
|
30
27
|
else if (buttonColor === 'indigo') {
|
|
31
|
-
linkClass
|
|
28
|
+
linkClass += 'bg-indigo-700 rounded-lg hover:bg-indigo-800 focus:ring-indigo-300 dark:bg-indigo-600 dark:hover:bg-indigo-700 dark:focus:ring-indigo-800';
|
|
32
29
|
}
|
|
33
30
|
else if (buttonColor === 'purple') {
|
|
34
|
-
linkClass
|
|
31
|
+
linkClass += 'bg-purple-700 rounded-lg hover:bg-purple-800 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-800';
|
|
35
32
|
}
|
|
36
33
|
else if (buttonColor === 'pink') {
|
|
37
|
-
linkClass
|
|
34
|
+
linkClass += 'bg-pink-700 rounded-lg hover:bg-pink-800 focus:ring-pink-300 dark:bg-pink-600 dark:hover:bg-pink-700 dark:focus:ring-pink-800';
|
|
38
35
|
}
|
|
39
36
|
else {
|
|
40
|
-
linkClass
|
|
37
|
+
linkClass += 'bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
41
38
|
}
|
|
42
39
|
</script>
|
|
43
40
|
|
package/cards/SignInCard.svelte
CHANGED
|
@@ -8,33 +8,33 @@ export let lostPassword;
|
|
|
8
8
|
let email;
|
|
9
9
|
let password;
|
|
10
10
|
let error;
|
|
11
|
-
let submitClass;
|
|
11
|
+
let submitClass = 'w-full text-white focus:ring-4 font-medium rounded-lg text-sm px-5 py-2.5 text-center ';
|
|
12
12
|
if (btnSignInColor === 'blue') {
|
|
13
|
-
submitClass
|
|
13
|
+
submitClass += 'bg-blue-700 hover:bg-blue-800 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
14
14
|
}
|
|
15
15
|
else if (btnSignInColor === 'gray') {
|
|
16
|
-
submitClass
|
|
16
|
+
submitClass += 'bg-gray-700 hover:bg-gray-800 focus:ring-gray-300 dark:bg-gray-600 dark:hover:bg-gray-700 dark:focus:ring-gray-800';
|
|
17
17
|
}
|
|
18
18
|
else if (btnSignInColor === 'red') {
|
|
19
|
-
submitClass
|
|
19
|
+
submitClass += 'bg-red-700 hover:bg-red-800 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-800';
|
|
20
20
|
}
|
|
21
21
|
else if (btnSignInColor === 'yellow') {
|
|
22
|
-
submitClass
|
|
22
|
+
submitClass += 'bg-yellow-700 hover:bg-yellow-800 focus:ring-yellow-300 dark:bg-yellow-600 dark:hover:bg-yellow-700 dark:focus:ring-yellow-800';
|
|
23
23
|
}
|
|
24
24
|
else if (btnSignInColor === 'green') {
|
|
25
|
-
submitClass
|
|
25
|
+
submitClass += 'bg-green-700 hover:bg-green-800 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800';
|
|
26
26
|
}
|
|
27
27
|
else if (btnSignInColor === 'indigo') {
|
|
28
|
-
submitClass
|
|
28
|
+
submitClass += 'bg-indigo-700 hover:bg-indigo-800 focus:ring-indigo-300 dark:bg-indigo-600 dark:hover:bg-indigo-700 dark:focus:ring-indigo-800';
|
|
29
29
|
}
|
|
30
30
|
else if (btnSignInColor === 'purple') {
|
|
31
|
-
submitClass
|
|
31
|
+
submitClass += 'bg-purple-700 hover:bg-purple-800 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-800';
|
|
32
32
|
}
|
|
33
33
|
else if (btnSignInColor === 'pink') {
|
|
34
|
-
submitClass
|
|
34
|
+
submitClass += 'bg-pink-700 hover:bg-pink-800 focus:ring-pink-300 dark:bg-pink-600 dark:hover:bg-pink-700 dark:focus:ring-pink-800';
|
|
35
35
|
}
|
|
36
36
|
else {
|
|
37
|
-
submitClass
|
|
37
|
+
submitClass += 'bg-blue-700 hover:bg-blue-800 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
38
38
|
}
|
|
39
39
|
</script>
|
|
40
40
|
|
|
@@ -22,8 +22,8 @@ else if (textSize === 'text-base') {
|
|
|
22
22
|
else {
|
|
23
23
|
paddings = 'py-2.5 px-5';
|
|
24
24
|
}
|
|
25
|
-
let buttonClass;
|
|
26
25
|
let round = rounded ? 'rounded-full' : 'rounded-lg';
|
|
26
|
+
let buttonClass = `inline-flex z-10 items-center font-medium ${round} ${textSize} ${paddings} text-center `;
|
|
27
27
|
export const openFn = (id) => {
|
|
28
28
|
if (showDropdownId === id) {
|
|
29
29
|
dropdownIdStore.update((n) => (n = null));
|
|
@@ -39,48 +39,44 @@ export let items;
|
|
|
39
39
|
export let dropdownClass = 'absolute left-0 top-1 z-10 w-44 text-base list-none bg-white rounded divide-y divide-gray-100 shadow dark:bg-gray-700';
|
|
40
40
|
export let headerClass = 'py-3 px-4 text-gray-900 dark:text-white';
|
|
41
41
|
export let linkClass = 'block py-2 px-4 text-sm text-gray-700 hover:bg-gray-100 dark:hover:bg-gray-600 dark:text-gray-200 dark:hover:text-white';
|
|
42
|
-
if (color === 'blue') {
|
|
43
|
-
buttonClass
|
|
44
|
-
}
|
|
45
|
-
else if (color === 'blue-outline') {
|
|
46
|
-
buttonClass = `inline-flex z-10 items-center text-blue-700 hover:text-white border border-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 font-medium rounded-lg ${textSize} ${paddings} text-center dark:border-blue-500 dark:text-blue-500 dark:hover:text-white dark:hover:bg-blue-600 dark:focus:ring-blue-800`;
|
|
42
|
+
if (color === 'blue-outline') {
|
|
43
|
+
buttonClass += `text-blue-700 hover:text-white border border-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 dark:border-blue-500 dark:text-blue-500 dark:hover:text-white dark:hover:bg-blue-600 dark:focus:ring-blue-800`;
|
|
47
44
|
}
|
|
48
45
|
else if (color === 'dark') {
|
|
49
|
-
buttonClass
|
|
46
|
+
buttonClass += `text-white bg-gray-800 hover:bg-gray-900 focus:ring-4 focus:ring-gray-300 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-800 dark:border-gray-700`;
|
|
50
47
|
}
|
|
51
48
|
else if (color === 'dark-outline') {
|
|
52
|
-
buttonClass
|
|
49
|
+
buttonClass += `text-gray-900 hover:text-white border border-gray-800 hover:bg-gray-900 focus:ring-4 focus:ring-gray-300 dark:border-gray-600 dark:text-gray-400 dark:hover:text-white dark:hover:bg-gray-600 dark:focus:ring-gray-800`;
|
|
53
50
|
}
|
|
54
51
|
else if (color === 'light') {
|
|
55
|
-
buttonClass
|
|
52
|
+
buttonClass += `text-gray-900 bg-white border border-gray-300 hover:bg-gray-100 focus:ring-4 focus:ring-blue-300 dark:bg-gray-600 dark:text-white dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-700 dark:focus:ring-gray-800`;
|
|
56
53
|
}
|
|
57
54
|
else if (color === 'green') {
|
|
58
|
-
buttonClass
|
|
55
|
+
buttonClass += `text-white bg-green-700 hover:bg-green-800 focus:ring-4 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800`;
|
|
59
56
|
}
|
|
60
57
|
else if (color === 'green-outline') {
|
|
61
|
-
buttonClass
|
|
58
|
+
buttonClass += `text-green-700 hover:text-white border border-green-700 hover:bg-green-800 focus:ring-4 focus:ring-green-300 dark:border-green-500 dark:text-green-500 dark:hover:text-white dark:hover:bg-green-600 dark:focus:ring-green-800`;
|
|
62
59
|
}
|
|
63
60
|
else if (color === 'red') {
|
|
64
|
-
buttonClass
|
|
61
|
+
buttonClass += `text-white bg-red-700 hover:bg-red-800 focus:ring-4 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-900`;
|
|
65
62
|
}
|
|
66
63
|
else if (color === 'red-outline') {
|
|
67
|
-
buttonClass
|
|
64
|
+
buttonClass += `text-red-700 hover:text-white border border-red-700 hover:bg-red-800 focus:ring-4 focus:ring-red-300 dark:border-red-500 dark:text-red-500 dark:hover:text-white dark:hover:bg-red-600 dark:focus:ring-red-900`;
|
|
68
65
|
}
|
|
69
66
|
else if (color === 'yellow') {
|
|
70
|
-
buttonClass
|
|
67
|
+
buttonClass += `text-white bg-yellow-400 hover:bg-yellow-500 focus:ring-4 focus:ring-yellow-300 dark:focus:ring-yellow-900`;
|
|
71
68
|
}
|
|
72
69
|
else if (color === 'yellow-outline') {
|
|
73
|
-
buttonClass
|
|
70
|
+
buttonClass += `text-yellow-400 hover:text-white border border-yellow-400 hover:bg-yellow-500 focus:ring-4 focus:ring-yellow-300 dark:border-yellow-300 dark:text-yellow-300 dark:hover:text-white dark:hover:bg-yellow-400 dark:focus:ring-yellow-900`;
|
|
74
71
|
}
|
|
75
72
|
else if (color === 'purple') {
|
|
76
|
-
buttonClass
|
|
73
|
+
buttonClass += `text-white bg-purple-700 hover:bg-purple-800 focus:ring-4 focus:ring-purple-300 mb-2 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-900`;
|
|
77
74
|
}
|
|
78
75
|
else if (color === 'purple-outline') {
|
|
79
|
-
buttonClass
|
|
76
|
+
buttonClass += `text-purple-700 hover:text-white border border-purple-700 hover:bg-purple-800 focus:ring-4 focus:ring-purple-300 dark:border-purple-400 dark:text-purple-400 dark:hover:text-white dark:hover:bg-purple-500 dark:focus:ring-purple-900`;
|
|
80
77
|
}
|
|
81
78
|
else {
|
|
82
|
-
|
|
83
|
-
buttonClass = `inline-flex z-10 items-center text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 font-medium ${round} ${textSize} ${paddings} text-center dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800`;
|
|
79
|
+
buttonClass += `text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800`;
|
|
84
80
|
}
|
|
85
81
|
</script>
|
|
86
82
|
|
package/forms/Checkbox.svelte
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script>export let divClass = 'flex items-center mr-4';
|
|
2
|
-
export let inputClass = 'w-4 h-4
|
|
2
|
+
export let inputClass = 'w-4 h-4 bg-gray-100 rounded border-gray-300 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600 ';
|
|
3
3
|
export let labelClass = 'ml-2 text-sm font-medium text-gray-900 dark:text-gray-300';
|
|
4
4
|
export let disabled = false;
|
|
5
5
|
if (disabled) {
|
|
@@ -11,25 +11,25 @@ export let labelHelperClass = 'font-medium text-gray-900 dark:text-gray-300';
|
|
|
11
11
|
export let helperClass = 'text-xs font-normal text-gray-500 dark:text-gray-300';
|
|
12
12
|
export let color = 'blue';
|
|
13
13
|
if (color === 'red') {
|
|
14
|
-
inputClass
|
|
14
|
+
inputClass += 'text-red-600 focus:ring-red-500 dark:focus:ring-red-600';
|
|
15
15
|
}
|
|
16
16
|
else if (color === 'green') {
|
|
17
|
-
inputClass
|
|
17
|
+
inputClass += 'text-green-600 focus:ring-green-500 dark:focus:ring-green-600';
|
|
18
18
|
}
|
|
19
19
|
else if (color === 'purple') {
|
|
20
|
-
inputClass
|
|
20
|
+
inputClass += 'text-purple-600 focus:ring-purple-500 dark:focus:ring-purple-600';
|
|
21
21
|
}
|
|
22
22
|
else if (color === 'teal') {
|
|
23
|
-
inputClass
|
|
23
|
+
inputClass += 'text-teal-600 focus:ring-teal-500 dark:focus:ring-teal-600';
|
|
24
24
|
}
|
|
25
25
|
else if (color === 'yellow') {
|
|
26
|
-
inputClass
|
|
26
|
+
inputClass += 'text-yellow-400 focus:ring-yellow-500 dark:focus:ring-yellow-600';
|
|
27
27
|
}
|
|
28
28
|
else if (color === 'orange') {
|
|
29
|
-
inputClass
|
|
29
|
+
inputClass += 'text-orange-500 focus:ring-orange-500 dark:focus:ring-orange-600';
|
|
30
30
|
}
|
|
31
31
|
else {
|
|
32
|
-
inputClass
|
|
32
|
+
inputClass += 'text-blue-600 focus:ring-blue-500 dark:focus:ring-blue-600';
|
|
33
33
|
}
|
|
34
34
|
export let helper;
|
|
35
35
|
export let id;
|
package/forms/RadioItem.svelte
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script>export let divClass = 'flex items-center mr-4';
|
|
2
|
-
export let inputClass = 'w-4 h-4
|
|
2
|
+
export let inputClass = 'w-4 h-4 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600 bg-gray-100 border-gray-300 ';
|
|
3
3
|
export let labelClass = 'block ml-2 text-sm font-medium text-gray-900 dark:text-gray-300';
|
|
4
4
|
export let disabled = false;
|
|
5
5
|
if (disabled) {
|
|
@@ -11,25 +11,25 @@ export let labelHelperClass = 'font-medium text-gray-900 dark:text-gray-300';
|
|
|
11
11
|
export let helperClass = 'text-xs font-normal text-gray-500 dark:text-gray-300';
|
|
12
12
|
export let color = 'blue';
|
|
13
13
|
if (color === 'red') {
|
|
14
|
-
inputClass = '
|
|
14
|
+
inputClass = 'text-red-600 focus:ring-red-500 dark:focus:ring-red-600';
|
|
15
15
|
}
|
|
16
16
|
else if (color === 'green') {
|
|
17
|
-
inputClass = '
|
|
17
|
+
inputClass = 'text-green-600 focus:ring-green-500 dark:focus:ring-green-600';
|
|
18
18
|
}
|
|
19
19
|
else if (color === 'purple') {
|
|
20
|
-
inputClass = '
|
|
20
|
+
inputClass = 'text-purple-600 focus:ring-purple-500 dark:focus:ring-purple-600';
|
|
21
21
|
}
|
|
22
22
|
else if (color === 'teal') {
|
|
23
|
-
inputClass = '
|
|
23
|
+
inputClass = 'text-teal-600 focus:ring-teal-500 dark:focus:ring-teal-600';
|
|
24
24
|
}
|
|
25
25
|
else if (color === 'yellow') {
|
|
26
|
-
inputClass = '
|
|
26
|
+
inputClass = 'text-yellow-400 focus:ring-yellow-500 dark:focus:ring-yellow-600';
|
|
27
27
|
}
|
|
28
28
|
else if (color === 'orange') {
|
|
29
|
-
inputClass = '
|
|
29
|
+
inputClass = 'text-orange-500 focus:ring-orange-500 dark:focus:ring-orange-600';
|
|
30
30
|
}
|
|
31
31
|
else {
|
|
32
|
-
inputClass = '
|
|
32
|
+
inputClass = 'text-blue-500 focus:ring-blue-500 dark:focus:ring-blue-600';
|
|
33
33
|
}
|
|
34
34
|
export let helper;
|
|
35
35
|
export let id;
|
package/forms/Range.svelte
CHANGED
|
@@ -5,15 +5,15 @@ export let max;
|
|
|
5
5
|
export let value;
|
|
6
6
|
export let step;
|
|
7
7
|
export let size;
|
|
8
|
-
let inputClass = 'w-full
|
|
8
|
+
let inputClass = 'w-full bg-gray-200 rounded-lg appearance-none cursor-pointer dark:bg-gray-700 ';
|
|
9
9
|
if (size === 'small') {
|
|
10
|
-
inputClass
|
|
10
|
+
inputClass += 'h-1 mb-6 range-sm';
|
|
11
11
|
}
|
|
12
12
|
else if (size === 'large') {
|
|
13
|
-
inputClass
|
|
13
|
+
inputClass += 'h-3 range-lg';
|
|
14
14
|
}
|
|
15
15
|
else {
|
|
16
|
-
inputClass
|
|
16
|
+
inputClass += 'h-2 mb-6';
|
|
17
17
|
}
|
|
18
18
|
</script>
|
|
19
19
|
|
package/index.d.ts
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
export { default as AccordionItem } from './accordions/AccordionItem.svelte';
|
|
2
2
|
export { default as Alert } from './alerts/Alert.svelte';
|
|
3
|
-
export { default as BorderAlert } from './alerts/BorderAlert.svelte';
|
|
4
|
-
export { default as InfoAlert } from './alerts/InfoAlert.svelte';
|
|
5
3
|
export { default as Avatar } from './avatar/Avatar.svelte';
|
|
6
4
|
export { default as Badge } from './badges/Badge.svelte';
|
|
7
5
|
export { default as BadgeIcon } from './badges/BadgeIcon.svelte';
|
package/index.js
CHANGED
|
@@ -2,8 +2,6 @@
|
|
|
2
2
|
export { default as AccordionItem } from './accordions/AccordionItem.svelte';
|
|
3
3
|
// Alerts
|
|
4
4
|
export { default as Alert } from './alerts/Alert.svelte';
|
|
5
|
-
export { default as BorderAlert } from './alerts/BorderAlert.svelte';
|
|
6
|
-
export { default as InfoAlert } from './alerts/InfoAlert.svelte';
|
|
7
5
|
// Avatar
|
|
8
6
|
export { default as Avatar } from './avatar/Avatar.svelte';
|
|
9
7
|
// Badges
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowbite-svelte",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.23",
|
|
4
4
|
"description": "Flowbite components for Svelte",
|
|
5
5
|
"main": "./package/index.js",
|
|
6
6
|
"author": {
|
|
@@ -83,8 +83,6 @@
|
|
|
83
83
|
"./.DS_Store": "./.DS_Store",
|
|
84
84
|
"./accordions/AccordionItem.svelte": "./accordions/AccordionItem.svelte",
|
|
85
85
|
"./alerts/Alert.svelte": "./alerts/Alert.svelte",
|
|
86
|
-
"./alerts/BorderAlert.svelte": "./alerts/BorderAlert.svelte",
|
|
87
|
-
"./alerts/InfoAlert.svelte": "./alerts/InfoAlert.svelte",
|
|
88
86
|
"./avatar/Avatar.svelte": "./avatar/Avatar.svelte",
|
|
89
87
|
"./badges/Badge.svelte": "./badges/Badge.svelte",
|
|
90
88
|
"./badges/BadgeIcon.svelte": "./badges/BadgeIcon.svelte",
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
<script>export let color = 'blue';
|
|
2
|
-
export let alertId = 'alert-border-1';
|
|
3
|
-
export let closeBtn = false;
|
|
4
|
-
let hidden = false;
|
|
5
|
-
const handleHide = () => {
|
|
6
|
-
hidden = !hidden;
|
|
7
|
-
};
|
|
8
|
-
let divClass;
|
|
9
|
-
let svgClass;
|
|
10
|
-
let slotClass;
|
|
11
|
-
let buttonClass;
|
|
12
|
-
if (color === 'blue') {
|
|
13
|
-
divClass = 'flex p-4 mb-4 bg-blue-100 border-t-4 border-blue-500 dark:bg-blue-200';
|
|
14
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-blue-700';
|
|
15
|
-
slotClass = 'ml-3 text-sm font-medium text-blue-700';
|
|
16
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-blue-100 text-blue-500 rounded-lg focus:ring-2 focus:ring-blue-400 p-1.5 hover:bg-blue-200 inline-flex h-8 w-8 dark:bg-blue-200 dark:text-blue-600 dark:hover:bg-blue-300';
|
|
17
|
-
}
|
|
18
|
-
else if (color === 'gray') {
|
|
19
|
-
divClass = 'flex p-4 mb-4 bg-gray-100 border-t-4 border-gray-500 dark:bg-gray-200';
|
|
20
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-gray-700';
|
|
21
|
-
slotClass = 'ml-3 text-sm font-medium text-gray-700';
|
|
22
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-gray-100 text-gray-500 rounded-lg focus:ring-2 focus:ring-gray-400 p-1.5 hover:bg-gray-200 inline-flex h-8 w-8 dark:bg-gray-200 dark:text-gray-600 dark:hover:bg-gray-300';
|
|
23
|
-
}
|
|
24
|
-
else if (color === 'red') {
|
|
25
|
-
divClass = 'flex p-4 mb-4 bg-red-100 border-t-4 border-red-500 dark:bg-red-200';
|
|
26
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-red-700';
|
|
27
|
-
slotClass = 'ml-3 text-sm font-medium text-red-700';
|
|
28
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-red-100 text-red-500 rounded-lg focus:ring-2 focus:ring-red-400 p-1.5 hover:bg-red-200 inline-flex h-8 w-8 dark:bg-red-200 dark:text-red-600 dark:hover:bg-red-300';
|
|
29
|
-
}
|
|
30
|
-
else if (color === 'yellow') {
|
|
31
|
-
divClass = 'flex p-4 mb-4 bg-yellow-100 border-t-4 border-yellow-500 dark:bg-yellow-200';
|
|
32
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-yellow-700';
|
|
33
|
-
slotClass = 'ml-3 text-sm font-medium text-yellow-700';
|
|
34
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-yellow-100 text-yellow-500 rounded-lg focus:ring-2 focus:ring-yellow-400 p-1.5 hover:bg-yellow-200 inline-flex h-8 w-8 dark:bg-yellow-200 dark:text-yellow-600 dark:hover:bg-yellow-300';
|
|
35
|
-
}
|
|
36
|
-
else if (color === 'green') {
|
|
37
|
-
divClass = 'flex p-4 mb-4 bg-green-100 border-t-4 border-green-500 dark:bg-green-200';
|
|
38
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-green-700';
|
|
39
|
-
slotClass = 'ml-3 text-sm font-medium text-green-700';
|
|
40
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-green-100 text-green-500 rounded-lg focus:ring-2 focus:ring-green-400 p-1.5 hover:bg-green-200 inline-flex h-8 w-8 dark:bg-green-200 dark:text-green-600 dark:hover:bg-green-300';
|
|
41
|
-
}
|
|
42
|
-
else if (color === 'indigo') {
|
|
43
|
-
divClass = 'flex p-4 mb-4 bg-indigo-100 border-t-4 border-indigo-500 dark:bg-indigo-200';
|
|
44
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-indigo-700';
|
|
45
|
-
slotClass = 'ml-3 text-sm font-medium text-indigo-700';
|
|
46
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-indigo-100 text-indigo-500 rounded-lg focus:ring-2 focus:ring-indigo-400 p-1.5 hover:bg-indigo-200 inline-flex h-8 w-8 dark:bg-indigo-200 dark:text-indigo-600 dark:hover:bg-indigo-300';
|
|
47
|
-
}
|
|
48
|
-
else if (color === 'purple') {
|
|
49
|
-
divClass = 'flex p-4 mb-4 bg-purple-100 border-t-4 border-purple-500 dark:bg-purple-200';
|
|
50
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-purple-700';
|
|
51
|
-
slotClass = 'ml-3 text-sm font-medium text-purple-700';
|
|
52
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-purple-100 text-purple-500 rounded-lg focus:ring-2 focus:ring-purple-400 p-1.5 hover:bg-purple-200 inline-flex h-8 w-8 dark:bg-purple-200 dark:text-purple-600 dark:hover:bg-purple-300';
|
|
53
|
-
}
|
|
54
|
-
else if (color === 'pink') {
|
|
55
|
-
divClass = 'flex p-4 mb-4 bg-pink-100 border-t-4 border-pink-500 dark:bg-pink-200';
|
|
56
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-pink-700';
|
|
57
|
-
slotClass = 'ml-3 text-sm font-medium text-pink-700';
|
|
58
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-pink-100 text-pink-500 rounded-lg focus:ring-2 focus:ring-pink-400 p-1.5 hover:bg-pink-200 inline-flex h-8 w-8 dark:bg-pink-200 dark:text-pink-600 dark:hover:bg-pink-300';
|
|
59
|
-
}
|
|
60
|
-
else {
|
|
61
|
-
divClass = 'flex p-4 mb-4 bg-blue-100 border-t-4 border-blue-500 dark:bg-blue-200';
|
|
62
|
-
svgClass = 'flex-shrink-0 w-5 h-5 text-blue-700';
|
|
63
|
-
slotClass = 'ml-3 text-sm font-medium text-blue-700';
|
|
64
|
-
buttonClass = 'ml-auto -mx-1.5 -my-1.5 bg-gray-100 text-gray-500 rounded-lg focus:ring-2 focus:ring-gray-400 p-1.5 hover:bg-gray-200 inline-flex h-8 w-8 dark:bg-gray-200 dark:text-gray-600 dark:hover:bg-gray-300';
|
|
65
|
-
}
|
|
66
|
-
</script>
|
|
67
|
-
|
|
68
|
-
<div id={alertId} class:hidden class={divClass} role="alert">
|
|
69
|
-
<svg class={svgClass} fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z" clip-rule="evenodd" /></svg>
|
|
70
|
-
<div class={slotClass}>
|
|
71
|
-
<slot />
|
|
72
|
-
</div>
|
|
73
|
-
{#if closeBtn}
|
|
74
|
-
<button on:click={handleHide} type="button" class={buttonClass} aria-label="Close">
|
|
75
|
-
<span class="sr-only">Dismiss</span>
|
|
76
|
-
<svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd" /></svg>
|
|
77
|
-
</button>
|
|
78
|
-
{/if}
|
|
79
|
-
</div>
|