flowbite-svelte 0.25.11 → 0.25.12
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 +7 -0
- package/index.d.ts +1 -0
- package/index.js +1 -0
- package/package.json +2 -1
- package/typography/Heading.svelte +1 -1
- package/typography/Hr.svelte +29 -0
- package/typography/Hr.svelte.d.ts +27 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.25.12](https://github.com/themesberg/flowbite-svelte/compare/v0.25.11...v0.25.12) (2022-08-22)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* add Hr component and page ([f289c1e](https://github.com/themesberg/flowbite-svelte/commit/f289c1ebd6cfcbcfde87b28ce3108abaf54248ca))
|
|
11
|
+
|
|
5
12
|
### [0.25.11](https://github.com/themesberg/flowbite-svelte/compare/v0.25.10...v0.25.11) (2022-08-22)
|
|
6
13
|
|
|
7
14
|
|
package/index.d.ts
CHANGED
|
@@ -116,6 +116,7 @@ export { default as A } from './typography/A.svelte';
|
|
|
116
116
|
export { default as Blockquote } from './typography/Blockquote.svelte';
|
|
117
117
|
export { default as Heading } from './typography/Heading.svelte';
|
|
118
118
|
export { default as Highlight } from './typography/Highlight.svelte';
|
|
119
|
+
export { default as Hr } from './typography/Hr.svelte';
|
|
119
120
|
export { default as Mark } from './typography/Mark.svelte';
|
|
120
121
|
export { default as P } from './typography/P.svelte';
|
|
121
122
|
export { default as Secondary } from './typography/Secondary.svelte';
|
package/index.js
CHANGED
|
@@ -150,6 +150,7 @@ export { default as A } from './typography/A.svelte';
|
|
|
150
150
|
export { default as Blockquote } from './typography/Blockquote.svelte';
|
|
151
151
|
export { default as Heading } from './typography/Heading.svelte';
|
|
152
152
|
export { default as Highlight } from './typography/Highlight.svelte';
|
|
153
|
+
export { default as Hr } from './typography/Hr.svelte';
|
|
153
154
|
export { default as Mark } from './typography/Mark.svelte';
|
|
154
155
|
export { default as P } from './typography/P.svelte';
|
|
155
156
|
export { default as Secondary } from './typography/Secondary.svelte';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowbite-svelte",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.12",
|
|
4
4
|
"description": "Flowbite components for Svelte",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": {
|
|
@@ -227,6 +227,7 @@
|
|
|
227
227
|
"./typography/Blockquote.svelte": "./typography/Blockquote.svelte",
|
|
228
228
|
"./typography/Heading.svelte": "./typography/Heading.svelte",
|
|
229
229
|
"./typography/Highlight.svelte": "./typography/Highlight.svelte",
|
|
230
|
+
"./typography/Hr.svelte": "./typography/Hr.svelte",
|
|
230
231
|
"./typography/Mark.svelte": "./typography/Mark.svelte",
|
|
231
232
|
"./typography/P.svelte": "./typography/P.svelte",
|
|
232
233
|
"./typography/Secondary.svelte": "./typography/Secondary.svelte",
|
|
@@ -14,7 +14,7 @@ const textSizes = {
|
|
|
14
14
|
|
|
15
15
|
<svelte:element
|
|
16
16
|
this={tag}
|
|
17
|
-
class={classNames(customSize ? customSize : textSizes[tag], textColor, $$props.class)}
|
|
17
|
+
class={classNames(customSize ? customSize : textSizes[tag], textColor, 'w-full', $$props.class)}
|
|
18
18
|
>
|
|
19
19
|
<slot />
|
|
20
20
|
</svelte:element>
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<script>import classNames from 'classnames';
|
|
2
|
+
export let divClass = 'inline-flex justify-center items-center w-full';
|
|
3
|
+
export let hrClass = 'bg-gray-200 rounded border-0 dark:bg-gray-700';
|
|
4
|
+
// bg-gray-200 rounded border-0 dark:bg-gray-700
|
|
5
|
+
export let width = 'w-full';
|
|
6
|
+
export let height = 'h-px';
|
|
7
|
+
export let iconSize = 24;
|
|
8
|
+
export let iconClass = 'text-gray-700 dark:text-gray-300';
|
|
9
|
+
export let icon;
|
|
10
|
+
export let text;
|
|
11
|
+
export let iconDivClass = 'absolute left-1/2 px-4 bg-white -translate-x-1/2 dark:bg-gray-900';
|
|
12
|
+
export let textSpanClass = 'absolute left-1/2 px-3 font-medium text-gray-900 bg-white -translate-x-1/2 dark:text-white dark:bg-gray-900';
|
|
13
|
+
let horizontalClass = classNames(hrClass, width, height, $$props.class);
|
|
14
|
+
</script>
|
|
15
|
+
|
|
16
|
+
{#if icon || text}
|
|
17
|
+
<div class={classNames(divClass, $$props.classDiv)}>
|
|
18
|
+
<hr class={horizontalClass} />
|
|
19
|
+
{#if icon}
|
|
20
|
+
<div class={iconDivClass}>
|
|
21
|
+
<svelte:component this={icon} size={iconSize} class={iconClass} />
|
|
22
|
+
</div>
|
|
23
|
+
{:else}
|
|
24
|
+
<span class={textSpanClass}>or</span>
|
|
25
|
+
{/if}
|
|
26
|
+
</div>
|
|
27
|
+
{:else}
|
|
28
|
+
<hr class={horizontalClass} />
|
|
29
|
+
{/if}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import type { SvelteComponent } from 'svelte';
|
|
3
|
+
declare const __propDef: {
|
|
4
|
+
props: {
|
|
5
|
+
[x: string]: any;
|
|
6
|
+
divClass?: string;
|
|
7
|
+
hrClass?: string;
|
|
8
|
+
width?: string;
|
|
9
|
+
height?: string;
|
|
10
|
+
iconSize?: number;
|
|
11
|
+
iconClass?: string;
|
|
12
|
+
icon: typeof SvelteComponent;
|
|
13
|
+
text: string;
|
|
14
|
+
iconDivClass?: string;
|
|
15
|
+
textSpanClass?: string;
|
|
16
|
+
};
|
|
17
|
+
events: {
|
|
18
|
+
[evt: string]: CustomEvent<any>;
|
|
19
|
+
};
|
|
20
|
+
slots: {};
|
|
21
|
+
};
|
|
22
|
+
export declare type HrProps = typeof __propDef.props;
|
|
23
|
+
export declare type HrEvents = typeof __propDef.events;
|
|
24
|
+
export declare type HrSlots = typeof __propDef.slots;
|
|
25
|
+
export default class Hr extends SvelteComponentTyped<HrProps, HrEvents, HrSlots> {
|
|
26
|
+
}
|
|
27
|
+
export {};
|