flowbite-svelte 0.27.3 → 0.27.5

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 CHANGED
@@ -2,6 +2,36 @@
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.27.5](https://github.com/themesberg/flowbite-svelte/compare/v0.27.4...v0.27.5) (2022-10-01)
6
+
7
+
8
+ ### Features
9
+
10
+ * add fetchMarkdownPosts in utils/index ([#333](https://github.com/themesberg/flowbite-svelte/issues/333)) ([b604c0c](https://github.com/themesberg/flowbite-svelte/commit/b604c0c31c99b743817d814b3b043c42ccfaf14c))
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * accordion slots + docs ([#349](https://github.com/themesberg/flowbite-svelte/issues/349)) ([78a2542](https://github.com/themesberg/flowbite-svelte/commit/78a25427e31f61ba86ce825d9127515326448afa))
16
+ * props using vite named import ([#347](https://github.com/themesberg/flowbite-svelte/issues/347)) ([7072e03](https://github.com/themesberg/flowbite-svelte/commit/7072e03b7ec8bac2e3d74d53f87c54dab772e159))
17
+ * use vite to import a file as text ([#342](https://github.com/themesberg/flowbite-svelte/issues/342)) ([07ac592](https://github.com/themesberg/flowbite-svelte/commit/07ac592b0a06cda8afd71d918145693a0834b4f3))
18
+
19
+ ### [0.27.4](https://github.com/themesberg/flowbite-svelte/compare/v0.27.3...v0.27.4) (2022-09-26)
20
+
21
+
22
+ ### Features
23
+
24
+ * toast fine tune ([f3ee6f3](https://github.com/themesberg/flowbite-svelte/commit/f3ee6f382aa3a004a8efdbed75f215b9dfe59b4e))
25
+
26
+
27
+ ### Bug Fixes
28
+
29
+ * app.css restored ([e40bc80](https://github.com/themesberg/flowbite-svelte/commit/e40bc80cace759b434bc889c1d143533de032345))
30
+ * change a to A component ([dc92c3f](https://github.com/themesberg/flowbite-svelte/commit/dc92c3f699986f6679805350f3a88effc0e2a0c8))
31
+ * remove type CrumbType ([4269359](https://github.com/themesberg/flowbite-svelte/commit/4269359c1bddb37fea064cab4dc31b3ea30772ee))
32
+ * toc stickiness ([#330](https://github.com/themesberg/flowbite-svelte/issues/330)) ([21a0409](https://github.com/themesberg/flowbite-svelte/commit/21a0409bd34323b2858f43952ef6de45982b262d))
33
+ * update props and types page ([#331](https://github.com/themesberg/flowbite-svelte/issues/331)) ([0be5900](https://github.com/themesberg/flowbite-svelte/commit/0be59006c6bf79df210838b21a17d3dfd18213ac))
34
+
5
35
  ### [0.27.3](https://github.com/themesberg/flowbite-svelte/compare/v0.27.2...v0.27.3) (2022-09-26)
6
36
 
7
37
 
@@ -0,0 +1,24 @@
1
+ <script context="module">import { writable } from 'svelte/store';
2
+ </script>
3
+
4
+ <script>import Frame from '../utils/Frame.svelte';
5
+ import classNames from 'classnames';
6
+ import { setContext } from 'svelte';
7
+ export let single = true;
8
+ export let flush = false;
9
+ export let activeClasses = 'bg-gray-100 dark:bg-gray-800 text-gray-900 dark:text-white focus:ring-4 focus:ring-gray-200 dark:focus:ring-gray-800';
10
+ export let inactiveClasses = 'text-gray-500 dark:text-gray-400 hover:bg-gray-100 hover:dark:bg-gray-800';
11
+ export let defaultClass = 'text-gray-500 dark:text-gray-400';
12
+ const ctx = {
13
+ flush,
14
+ activeClasses,
15
+ inactiveClasses,
16
+ selected: single ? writable() : undefined
17
+ };
18
+ setContext('ctx', ctx);
19
+ let frameClass = classNames(defaultClass, 'divide-y divide-gray-200 dark:divide-gray-700', 'border-gray-200 dark:border-gray-700', 'rounded-t-xl', $$props.class);
20
+ </script>
21
+
22
+ <Frame class={frameClass} color="none" border={!flush}>
23
+ <slot />
24
+ </Frame>
@@ -0,0 +1,30 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ import { type Writable } from 'svelte/store';
3
+ export interface AccordionCtxType {
4
+ flush: boolean;
5
+ activeClasses: string;
6
+ inactiveClasses: string;
7
+ selected?: Writable<object>;
8
+ }
9
+ declare const __propDef: {
10
+ props: {
11
+ [x: string]: any;
12
+ single?: boolean | undefined;
13
+ flush?: boolean | undefined;
14
+ activeClasses?: string | undefined;
15
+ inactiveClasses?: string | undefined;
16
+ defaultClass?: string | undefined;
17
+ };
18
+ events: {
19
+ [evt: string]: CustomEvent<any>;
20
+ };
21
+ slots: {
22
+ default: {};
23
+ };
24
+ };
25
+ export declare type AccordionProps = typeof __propDef.props;
26
+ export declare type AccordionEvents = typeof __propDef.events;
27
+ export declare type AccordionSlots = typeof __propDef.slots;
28
+ export default class Accordion extends SvelteComponentTyped<AccordionProps, AccordionEvents, AccordionSlots> {
29
+ }
30
+ export {};
@@ -1,76 +1,42 @@
1
- <script>import classNames from 'classnames';
1
+ <script>import ChevronDown from '../utils/ChevronDown.svelte';
2
+ import ChevronUp from '../utils/ChevronUp.svelte';
3
+ import classNames from 'classnames';
4
+ import { getContext, onMount } from 'svelte';
5
+ import { writable } from 'svelte/store';
2
6
  import { slide } from 'svelte/transition';
3
- export let flush = false;
4
- export let id = '';
5
- export let slotClass = 'border-gray-200 dark:border-gray-700';
6
- let classSlot = classNames(slotClass, flush ? 'py-5 border-b' : 'p-5 border border-t-0');
7
- export let isOpen = false;
8
- export let color = false;
9
- export let btnClass = 'flex items-center justify-between w-full font-medium text-left text-gray-500 border-gray-200 dark:border-gray-700 dark:text-gray-400';
10
- let classBtn = classNames(btnClass, flush
11
- ? 'py-5 border-b'
12
- : 'focus:ring-4 focus:ring-gray-200 dark:focus:ring-gray-800 p-5 border hover:bg-gray-100 dark:hover:bg-gray-800');
13
- export let colorClass = 'focus:ring-blue-200 dark:focus:ring-blue-800 hover:bg-blue-100 text-blue-500 bg-blue-200 text-blue-700';
14
- const handleToggle = (id) => {
15
- isOpen = !isOpen;
16
- };
7
+ export let open = false;
8
+ export let activeClasses = undefined;
9
+ export let inactiveClasses = undefined;
10
+ export let defaultClass = 'flex items-center justify-between w-full font-medium text-left group-first:rounded-t-xl';
11
+ const ctx = getContext('ctx') ?? {};
12
+ // single selection
13
+ const self = {};
14
+ const selected = ctx.selected ?? writable();
15
+ onMount(() => {
16
+ if (open)
17
+ $selected = self;
18
+ // this will trigger unsubscribe on destroy
19
+ return selected.subscribe((x) => (open = x === self));
20
+ });
21
+ const handleToggle = (e) => selected.set(open ? {} : self);
17
22
  let buttonClass;
18
- $: if (color && isOpen) {
19
- buttonClass = classBtn + colorClass;
20
- }
21
- else {
22
- buttonClass = classBtn;
23
- }
23
+ $: buttonClass = classNames(defaultClass, ctx.flush ? 'py-5' : 'p-5', open && (ctx.flush ? 'text-gray-900 dark:text-white' : activeClasses || ctx.activeClasses), !open && (ctx.flush ? 'text-gray-500 dark:text-gray-400' : inactiveClasses || ctx.inactiveClasses), $$props.class);
24
24
  </script>
25
25
 
26
- <h2 aria-expanded={isOpen}>
27
- <button
28
- on:click={() => handleToggle(id)}
29
- type="button"
30
- class:rounded-t-xl={id === '1'}
31
- class:border-t-0={id !== '1'}
32
- class={classNames(buttonClass, $$props.class)}
33
- >
34
- <slot name="header" />
35
- {#if isOpen}
36
- {#if $$slots.arrowup}
37
- <slot name="arrowup" />
38
- {:else}
39
- <svg
40
- data-accordion-icon
41
- class="w-6 h-6 rotate-180 shrink-0"
42
- fill="currentColor"
43
- viewBox="0 0 20 20"
44
- xmlns="http://www.w3.org/2000/svg"
45
- ><path
46
- fill-rule="evenodd"
47
- d="M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z"
48
- clip-rule="evenodd"
49
- /></svg
50
- >
51
- {/if}
52
- {:else if $$slots.arrowdown}
53
- <slot name="arrowdown" />
54
- {:else}
55
- <svg
56
- data-accordion-icon
57
- class="w-6 h-6 shrink-0"
58
- fill="currentColor"
59
- viewBox="0 0 20 20"
60
- xmlns="http://www.w3.org/2000/svg"
61
- ><path
62
- fill-rule="evenodd"
63
- d="M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z"
64
- clip-rule="evenodd"
65
- /></svg
66
- >
67
- {/if}
68
- </button>
26
+ <h2 aria-expanded={open} class="group">
27
+ <button on:click={handleToggle} type="button" class={buttonClass}>
28
+ <slot name="header" />
29
+ {#if open}
30
+ <slot name="arrowup"><ChevronUp /></slot>
31
+ {:else}
32
+ <slot name="arrowdown"><ChevronDown /></slot>
33
+ {/if}
34
+ </button>
69
35
  </h2>
70
- {#if isOpen}
71
- <div transition:slide={{ duration: 500 }}>
72
- <div class={classSlot}>
73
- <slot name="body" />
74
- </div>
75
- </div>
36
+ {#if open}
37
+ <div transition:slide={{ duration: 500 }}>
38
+ <div class={ctx.flush ? 'py-5' : 'p-5'}>
39
+ <slot />
40
+ </div>
41
+ </div>
76
42
  {/if}
@@ -2,13 +2,10 @@ import { SvelteComponentTyped } from "svelte";
2
2
  declare const __propDef: {
3
3
  props: {
4
4
  [x: string]: any;
5
- flush?: boolean | undefined;
6
- id?: string | undefined;
7
- slotClass?: string | undefined;
8
- isOpen?: boolean | undefined;
9
- color?: boolean | undefined;
10
- btnClass?: string | undefined;
11
- colorClass?: string | undefined;
5
+ open?: boolean | undefined;
6
+ activeClasses?: string | undefined;
7
+ inactiveClasses?: string | undefined;
8
+ defaultClass?: string | undefined;
12
9
  };
13
10
  events: {
14
11
  [evt: string]: CustomEvent<any>;
@@ -17,7 +14,7 @@ declare const __propDef: {
17
14
  header: {};
18
15
  arrowup: {};
19
16
  arrowdown: {};
20
- body: {};
17
+ default: {};
21
18
  };
22
19
  };
23
20
  export declare type AccordionItemProps = typeof __propDef.props;
@@ -1,10 +1,10 @@
1
1
  <script>import { setContext } from 'svelte';
2
2
  import classNames from 'classnames';
3
- export let divClass = 'inline-flex rounded-lg shadow-sm w-fit';
4
- setContext('group', true);
5
- setContext('background', true);
3
+ export let size = 'md';
4
+ export let divClass = 'inline-flex rounded-lg shadow-sm';
5
+ setContext('group', { size });
6
6
  </script>
7
7
 
8
8
  <div {...$$restProps} class={classNames(divClass, $$props.class)} role="group">
9
- <slot />
9
+ <slot />
10
10
  </div>
@@ -1,7 +1,9 @@
1
1
  import { SvelteComponentTyped } from "svelte";
2
+ import type { SizeType } from '../types';
2
3
  declare const __propDef: {
3
4
  props: {
4
5
  [x: string]: any;
6
+ size?: SizeType | undefined;
5
7
  divClass?: string | undefined;
6
8
  };
7
9
  events: {
@@ -10,7 +10,6 @@ export let btnClass = undefined;
10
10
  export let type = 'button';
11
11
  export let color = group ? (outline ? 'dark' : 'alternative') : 'blue';
12
12
  export let shadow = null;
13
- const background = getContext('background');
14
13
  const colorClasses = {
15
14
  blue: 'text-white 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',
16
15
  dark: 'text-white bg-gray-800 hover:bg-gray-900 focus:ring-gray-300 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-700',
@@ -80,11 +79,11 @@ $: buttonClass = btnClass
80
79
  : classNames('text-center font-medium', group ? 'focus:ring-2' : 'focus:ring-4', group && 'focus:z-10', !group || color === 'alternative' || (outline && color === 'dark') || 'focus:outline-none', outline && gradient
81
80
  ? 'p-0.5'
82
81
  : 'inline-flex items-center justify-center ' + sizeClasses[size], gradient ? gradientClasses[color] : outline ? outlineClasses[color] : colorClasses[color], color === 'alternative' &&
83
- (background
82
+ (group
84
83
  ? 'dark:bg-gray-700 dark:text-white dark:border-gray-700 dark:hover:border-gray-600 dark:hover:bg-gray-600'
85
84
  : 'dark:bg-transparent dark:border-gray-800 dark:hover:border-gray-700'), outline &&
86
85
  color === 'dark' &&
87
- (background
86
+ (group
88
87
  ? 'dark:text-white dark:border-white'
89
88
  : 'dark:text-gray-400 dark:border-gray-700'), hasBorder() && group && 'border-l-0 first:border-l', rounded(false), shadow && coloredShadowClasses[shadow], $$props.disabled && 'cursor-not-allowed opacity-50', $$props.class);
90
89
  let gradientOutlineClass;
@@ -1,50 +1,80 @@
1
- <script>import classNames from 'classnames';
1
+ <script context="module">export function clampSize(s) {
2
+ return s && s === 'xs' ? 'sm' : s === 'xl' ? 'lg' : s;
3
+ }
4
+ </script>
5
+
6
+ <script>import Wrapper from '../utils/Wrapper.svelte';
7
+ import classNames from 'classnames';
2
8
  import { getContext } from 'svelte';
3
9
  export let type = 'text';
4
10
  export let value = '';
5
- export let size = 'md';
6
- export let inputClass = 'block w-full border disabled:cursor-not-allowed disabled:opacity-50 rounded-lg';
11
+ export let size = undefined;
12
+ export let defaultClass = 'block w-full disabled:cursor-not-allowed disabled:opacity-50';
7
13
  export let color = 'base';
14
+ const borderClasses = {
15
+ base: 'border-gray-300 dark:border-gray-600',
16
+ tinted: 'border-gray-300 dark:border-gray-500',
17
+ green: 'border-green-500 dark:border-green-400',
18
+ red: 'border-red-500 dark:border-red-400'
19
+ };
20
+ const ringClasses = {
21
+ base: 'focus:border-blue-500 focus:ring-blue-500 dark:focus:border-blue-500 dark:focus:ring-blue-500',
22
+ green: 'focus:ring-green-500 focus:border-green-500 dark:focus:border-green-500 dark:focus:ring-green-500',
23
+ red: 'focus:ring-red-500 focus:border-red-500 dark:focus:ring-red-500 dark:focus:border-red-500'
24
+ };
8
25
  const colorClasses = {
9
- base: 'bg-gray-50 border-gray-300 text-gray-900 focus:border-blue-500 focus:ring-blue-500 dark:text-white dark:placeholder-gray-400 dark:focus:border-blue-500 dark:focus:ring-blue-500',
10
- green: 'border-green-500 bg-green-50 text-green-900 placeholder-green-700 focus:border-green-500 focus:ring-green-500 dark:border-green-400 dark:bg-green-100 dark:focus:border-green-500 dark:focus:ring-green-500',
11
- red: 'border-red-500 bg-red-50 text-red-900 placeholder-red-700 focus:border-red-500 focus:ring-red-500 dark:border-red-400 dark:bg-red-100 dark:focus:border-red-500 dark:focus:ring-red-500'
26
+ base: 'bg-gray-50 text-gray-900 dark:bg-gray-700 dark:text-white dark:placeholder-gray-400',
27
+ tinted: 'bg-gray-50 text-gray-900 dark:bg-gray-600 dark:text-white dark:placeholder-gray-400',
28
+ green: 'bg-green-50 text-green-900 placeholder-green-700 dark:bg-gray-700',
29
+ red: 'bg-red-50 text-red-900 placeholder-red-700 dark:bg-gray-700'
12
30
  };
13
31
  // tinted if put in component having its own background
14
32
  let background = getContext('background');
33
+ let group = getContext('group');
15
34
  // you need to this to avoid 2-way binding
16
- const setType = (node) => {
17
- node.type = type;
35
+ const setType = (node, _type) => {
36
+ node.type = _type;
37
+ return {
38
+ update(_type) {
39
+ node.type = _type;
40
+ }
41
+ };
18
42
  };
43
+ const textSizes = { sm: 'sm:text-xs', md: 'text-sm', lg: 'sm:text-base' };
44
+ const leftPadding = { sm: 'pl-9', md: 'pl-10', lg: 'pl-11' };
45
+ const rightPadding = { sm: 'pr-9', md: 'pr-10', lg: 'pr-11' };
46
+ const inputPadding = { sm: 'p-2', md: 'p-2.5', lg: 'p-4' };
47
+ $: _size = size || clampSize(group?.size) || 'md';
48
+ let inputClass;
49
+ $: {
50
+ const _color = color === 'base' && background ? 'tinted' : color;
51
+ inputClass = classNames(defaultClass, $$slots.left && leftPadding[_size], $$slots.right && rightPadding[_size], ringClasses[color], colorClasses[_color], borderClasses[_color], inputPadding[_size], textSizes[_size], group || 'rounded-lg', group && 'first:rounded-l-lg last:rounded-r-lg', group && 'border-l-0 first:border-l last:border-r', $$props.class);
52
+ }
53
+ let floatClass = 'flex absolute inset-y-0 left-0 items-center pointer-events-none text-gray-500 dark:text-gray-400';
19
54
  </script>
20
55
 
21
- <input
22
- {...$$restProps}
23
- bind:value
24
- on:blur
25
- on:change
26
- on:click
27
- on:focus
28
- on:keydown
29
- on:keypress
30
- on:keyup
31
- on:mouseover
32
- on:mouseenter
33
- on:mouseleave
34
- on:paste
35
- on:input
36
- use:setType
37
- class={classNames(
38
- inputClass,
39
- colorClasses[color],
40
- color === 'base' &&
41
- (background
42
- ? 'dark:bg-gray-600 dark:border-gray-500'
43
- : 'dark:bg-gray-700 dark:border-gray-600'),
44
- {
45
- 'p-2 sm:text-xs': size === 'sm',
46
- 'p-2.5 text-sm': size === 'md',
47
- 'sm:text-md p-4': size === 'lg'
48
- },
49
- $$props.class
50
- )} />
56
+ <Wrapper class="relative w-full" show={$$slots.left || $$slots.right}>
57
+ {#if $$slots.left}
58
+ <div class="{floatClass} pl-3"><slot name="left" /></div>
59
+ {/if}
60
+ <input
61
+ {...$$restProps}
62
+ bind:value
63
+ on:blur
64
+ on:change
65
+ on:click
66
+ on:focus
67
+ on:keydown
68
+ on:keypress
69
+ on:keyup
70
+ on:mouseover
71
+ on:mouseenter
72
+ on:mouseleave
73
+ on:paste
74
+ on:input
75
+ use:setType={type}
76
+ class={inputClass} />
77
+ {#if $$slots.right}
78
+ <div class="{floatClass} pr-3"><slot name="right" /></div>
79
+ {/if}
80
+ </Wrapper>
@@ -1,12 +1,14 @@
1
1
  import { SvelteComponentTyped } from "svelte";
2
+ import type { SizeType, FormSizeType } from '../types';
3
+ export declare function clampSize(s: SizeType): "sm" | "md" | "lg";
2
4
  import type { InputType } from '../types';
3
5
  declare const __propDef: {
4
6
  props: {
5
7
  [x: string]: any;
6
8
  type?: InputType | undefined;
7
9
  value?: string | undefined;
8
- size?: "sm" | "md" | "lg" | undefined;
9
- inputClass?: string | undefined;
10
+ size?: FormSizeType | undefined;
11
+ defaultClass?: string | undefined;
10
12
  color?: "green" | "red" | "base" | undefined;
11
13
  };
12
14
  events: {
@@ -25,7 +27,10 @@ declare const __propDef: {
25
27
  } & {
26
28
  [evt: string]: CustomEvent<any>;
27
29
  };
28
- slots: {};
30
+ slots: {
31
+ left: {};
32
+ right: {};
33
+ };
29
34
  };
30
35
  export declare type InputProps = typeof __propDef.props;
31
36
  export declare type InputEvents = typeof __propDef.events;
@@ -0,0 +1,29 @@
1
+ <script>import classNames from 'classnames';
2
+ import { getContext } from 'svelte';
3
+ import { clampSize } from './Input.svelte';
4
+ export let size = undefined;
5
+ // tinted if put in component having its own background
6
+ let background = getContext('background');
7
+ let group = getContext('group');
8
+ const borderClasses = {
9
+ base: 'border-gray-300 dark:border-gray-600',
10
+ tinted: 'border-gray-300 dark:border-gray-500'
11
+ };
12
+ const darkBgClasses = {
13
+ base: 'dark:bg-gray-600 dark:text-gray-400',
14
+ tinted: 'dark:bg-gray-500 dark:text-gray-300'
15
+ };
16
+ const divider = {
17
+ base: 'dark:border-r-gray-700 dark:last:border-r-gray-600',
18
+ tinted: 'dark:border-r-gray-600 dark:last:border-r-gray-500'
19
+ };
20
+ const textSizes = { sm: 'sm:text-xs', md: 'text-sm', lg: 'sm:text-base' };
21
+ const prefixPadding = { sm: 'px-2', md: 'px-3', lg: 'px-4' };
22
+ // size: explicit, inherited, default
23
+ $: _size = size || clampSize(group?.size) || 'md';
24
+ $: divClass = classNames(textSizes[_size], prefixPadding[_size], background ? borderClasses['tinted'] : borderClasses['base'], 'text-gray-500 bg-gray-200', background ? darkBgClasses.tinted : darkBgClasses.base, background ? divider.tinted : divider.base, 'inline-flex items-center border-t border-b first:border-l border-r', 'first:rounded-l-lg last:rounded-r-lg', $$props.class);
25
+ </script>
26
+
27
+ <div {...$$restProps} class={divClass}>
28
+ <slot />
29
+ </div>
@@ -0,0 +1,19 @@
1
+ import { SvelteComponentTyped } from "svelte";
2
+ declare const __propDef: {
3
+ props: {
4
+ [x: string]: any;
5
+ size?: 'sm' | 'md' | 'lg' | undefined;
6
+ };
7
+ events: {
8
+ [evt: string]: CustomEvent<any>;
9
+ };
10
+ slots: {
11
+ default: {};
12
+ };
13
+ };
14
+ export declare type InputAddonProps = typeof __propDef.props;
15
+ export declare type InputAddonEvents = typeof __propDef.events;
16
+ export declare type InputAddonSlots = typeof __propDef.slots;
17
+ export default class InputAddon extends SvelteComponentTyped<InputAddonProps, InputAddonEvents, InputAddonSlots> {
18
+ }
19
+ export {};
@@ -1,29 +1,16 @@
1
- <script context="module">
2
- // this part is shared between Radio and Checkbox
3
- import classNames from 'classnames';
4
-
5
- const colorClasses = {
6
- red: 'text-red-600 focus:ring-red-500 dark:focus:ring-red-600',
7
- green: 'text-green-600 focus:ring-green-500 dark:focus:ring-green-600',
8
- purple: 'text-purple-600 focus:ring-purple-500 dark:focus:ring-purple-600',
9
- teal: 'text-teal-600 focus:ring-teal-500 dark:focus:ring-teal-600',
10
- yellow: 'text-yellow-400 focus:ring-yellow-500 dark:focus:ring-yellow-600',
11
- orange: 'text-orange-500 focus:ring-orange-500 dark:focus:ring-orange-600',
12
- blue: 'text-blue-600 focus:ring-blue-500 dark:focus:ring-blue-600'
13
- };
14
-
15
- export const labelClass = (inline, extraClass) =>
16
- classNames(inline ? 'inline-flex' : 'flex', 'items-center', extraClass);
17
-
18
- export const inputClass = (custom, color, rounded, tinted, extraClass) =>
19
- classNames(
20
- 'w-4 h-4 bg-gray-100 border-gray-300 dark:ring-offset-gray-800 focus:ring-2 mr-2',
21
- tinted ? 'dark:bg-gray-600 dark:border-gray-500' : 'dark:bg-gray-700 dark:border-gray-600',
22
- custom && 'sr-only peer',
23
- rounded && 'rounded',
24
- colorClasses[color],
25
- extraClass
26
- );
1
+ <script context="module">// this part is shared between Radio and Checkbox
2
+ import classNames from 'classnames';
3
+ const colorClasses = {
4
+ red: 'text-red-600 focus:ring-red-500 dark:focus:ring-red-600',
5
+ green: 'text-green-600 focus:ring-green-500 dark:focus:ring-green-600',
6
+ purple: 'text-purple-600 focus:ring-purple-500 dark:focus:ring-purple-600',
7
+ teal: 'text-teal-600 focus:ring-teal-500 dark:focus:ring-teal-600',
8
+ yellow: 'text-yellow-400 focus:ring-yellow-500 dark:focus:ring-yellow-600',
9
+ orange: 'text-orange-500 focus:ring-orange-500 dark:focus:ring-orange-600',
10
+ blue: 'text-blue-600 focus:ring-blue-500 dark:focus:ring-blue-600'
11
+ };
12
+ export const labelClass = (inline, extraClass) => classNames(inline ? 'inline-flex' : 'flex', 'items-center', extraClass);
13
+ export const inputClass = (custom, color, rounded, tinted, extraClass) => classNames('w-4 h-4 bg-gray-100 border-gray-300 dark:ring-offset-gray-800 focus:ring-2', extraClass === true && 'mr-2', tinted ? 'dark:bg-gray-600 dark:border-gray-500' : 'dark:bg-gray-700 dark:border-gray-600', custom && 'sr-only peer', rounded && 'rounded', colorClasses[color], extraClass);
27
14
  </script>
28
15
 
29
16
  <script>import { getContext } from 'svelte';
@@ -38,21 +25,21 @@ let background = getContext('background');
38
25
  </script>
39
26
 
40
27
  <Label class={labelClass(inline, $$props.class)} show={$$slots.default}>
41
- <input
42
- type="radio"
43
- bind:group
44
- on:blur
45
- on:change
46
- on:click
47
- on:focus
48
- on:keydown
49
- on:keypress
50
- on:keyup
51
- on:mouseenter
52
- on:mouseleave
53
- on:mouseover
54
- on:paste
55
- {value}
56
- {...$$restProps}
57
- class={inputClass(custom, color, false, background, $$slots.default || $$props.class)} /><slot />
28
+ <input
29
+ type="radio"
30
+ bind:group
31
+ on:blur
32
+ on:change
33
+ on:click
34
+ on:focus
35
+ on:keydown
36
+ on:keypress
37
+ on:keyup
38
+ on:mouseenter
39
+ on:mouseleave
40
+ on:mouseover
41
+ on:paste
42
+ {value}
43
+ {...$$restProps}
44
+ class={inputClass(custom, color, false, background, $$slots.default || $$props.class)} /><slot />
58
45
  </Label>
@@ -1,6 +1,6 @@
1
1
  import { SvelteComponentTyped } from "svelte";
2
- export declare const labelClass: (inline: any, extraClass: any) => string;
3
- export declare const inputClass: (custom: any, color: any, rounded: any, tinted: any, extraClass: any) => string;
2
+ export declare const labelClass: (inline: boolean, extraClass: string) => string;
3
+ export declare const inputClass: (custom: boolean, color: FormColorType, rounded: boolean, tinted: boolean, extraClass: string | boolean) => string;
4
4
  import type { FormColorType } from '../types';
5
5
  declare const __propDef: {
6
6
  props: {
@@ -1,46 +1,54 @@
1
- <script>export let id = '';
2
- export let labelClass = 'mb-2 text-sm font-medium text-gray-900 sr-only dark:text-gray-300';
3
- export let inputClass = 'block p-4 pl-10 w-full text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 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';
4
- export let btnClass = 'text-white absolute right-2.5 bottom-2.5 bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm px-4 py-2 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
1
+ <script>import Wrapper from '../utils/Wrapper.svelte';
2
+ import Input from './Input.svelte';
3
+ export let size = 'lg';
5
4
  export let placeholder = 'Search';
5
+ const sizes = {
6
+ sm: 'w-3.5 h-3.5',
7
+ md: 'w-5 h-5',
8
+ lg: 'w-6 h-6'
9
+ };
6
10
  </script>
7
11
 
8
- <form on:submit>
9
- <label for={id} class={labelClass}>Search</label>
10
- <div class="relative">
11
- <div class="flex absolute inset-y-0 left-0 items-center pl-3 pointer-events-none">
12
- <svg
13
- class="w-5 h-5 text-gray-500 dark:text-gray-400"
14
- fill="none"
15
- stroke="currentColor"
16
- viewBox="0 0 24 24"
17
- xmlns="http://www.w3.org/2000/svg"
18
- ><path
19
- stroke-linecap="round"
20
- stroke-linejoin="round"
21
- stroke-width="2"
22
- d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"
23
- /></svg
24
- >
25
- </div>
26
- <input
27
- {...$$restProps}
28
- on:blur
29
- on:change
30
- on:click
31
- on:focus
32
- on:keydown
33
- on:keypress
34
- on:keyup
35
- on:mouseenter
36
- on:mouseleave
37
- on:mouseover
38
- on:paste
39
- type="search"
40
- {id}
41
- class={inputClass}
42
- {placeholder}
43
- />
44
- <button type="submit" class={btnClass}>Search</button>
45
- </div>
46
- </form>
12
+ <Wrapper class="relative w-full" show={$$slots.default}>
13
+ <Input
14
+ on:blur
15
+ on:change
16
+ on:click
17
+ on:focus
18
+ on:keydown
19
+ on:keypress
20
+ on:keyup
21
+ on:mouseenter
22
+ on:mouseleave
23
+ on:mouseover
24
+ on:paste
25
+ type="search"
26
+ {placeholder}
27
+ {size}
28
+ {...$$restProps}
29
+ class={$$props.class}>
30
+ <svg
31
+ slot="left"
32
+ class={sizes[size]}
33
+ fill="currentColor"
34
+ viewBox="0 0 20 20"
35
+ xmlns="http://www.w3.org/2000/svg">
36
+ <path
37
+ fill-rule="evenodd"
38
+ d="M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z"
39
+ clip-rule="evenodd" />
40
+ </svg>
41
+ <!-- We can use it here. See below. This will trigger right padding
42
+ <slot slot="right" />
43
+ -->
44
+ </Input>
45
+ <!-- This slot should be within Input as a slot='right'
46
+ Svelete has an issue with forwarded slots and even empty slot here will appear as existing slot in Input.
47
+ Due to that we need the below slot and Wrapper around
48
+ -->
49
+ {#if $$slots.default}
50
+ <div class="flex absolute inset-y-0 right-0 items-center pr-3 text-gray-500 dark:text-gray-400">
51
+ <slot />
52
+ </div>
53
+ {/if}
54
+ </Wrapper>
@@ -1,15 +1,12 @@
1
1
  import { SvelteComponentTyped } from "svelte";
2
+ import type { FormSizeType } from '../types';
2
3
  declare const __propDef: {
3
4
  props: {
4
5
  [x: string]: any;
5
- id?: string | undefined;
6
- labelClass?: string | undefined;
7
- inputClass?: string | undefined;
8
- btnClass?: string | undefined;
6
+ size?: FormSizeType | undefined;
9
7
  placeholder?: string | undefined;
10
8
  };
11
9
  events: {
12
- submit: SubmitEvent;
13
10
  blur: FocusEvent;
14
11
  change: Event;
15
12
  click: MouseEvent;
@@ -24,7 +21,9 @@ declare const __propDef: {
24
21
  } & {
25
22
  [evt: string]: CustomEvent<any>;
26
23
  };
27
- slots: {};
24
+ slots: {
25
+ default: {};
26
+ };
28
27
  };
29
28
  export declare type SearchProps = typeof __propDef.props;
30
29
  export declare type SearchEvents = typeof __propDef.events;
@@ -1,65 +1,20 @@
1
- <script>import { getContext } from 'svelte';
2
- export let id = '';
3
- export let labelClass = 'sr-only';
4
- export let iconClass = 'w-5 h-5 text-gray-500 dark:text-gray-400';
5
- export let iconDivClass = 'flex absolute inset-y-0 left-0 items-center pl-3 pointer-events-none';
6
- export let inputClass = '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:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500';
7
- export let btnClass = 'p-2.5 ml-2 text-sm font-medium text-white bg-blue-700 rounded-lg border border-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
8
- export let placeholder = 'Search';
9
- // tainted if put in component having its own background
10
- let background = getContext('background');
1
+ <script>import Search from './Search.svelte';
2
+ import Button from '../buttons/Button.svelte';
11
3
  </script>
12
4
 
13
- <form class="flex items-center" on:submit>
14
- <label for={id} class={labelClass}>Search</label>
15
- <div class="relative w-full">
16
- <div class={iconDivClass}>
17
- <svg
18
- class={iconClass}
19
- fill="currentColor"
20
- viewBox="0 0 20 20"
21
- xmlns="http://www.w3.org/2000/svg"
22
- ><path
23
- fill-rule="evenodd"
24
- d="M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z"
25
- clip-rule="evenodd"
26
- /></svg
27
- >
28
- </div>
29
- <input
30
- on:blur
31
- on:change
32
- on:click
33
- on:focus
34
- on:keydown
35
- on:keypress
36
- on:keyup
37
- on:mouseenter
38
- on:mouseleave
39
- on:mouseover
40
- on:paste
41
- {...$$restProps}
42
- type="text"
43
- {id}
44
- class="{background
45
- ? 'dark:bg-gray-600 dark:border-gray-500'
46
- : ' dark:bg-gray-700 dark:border-gray-600'} {inputClass}"
47
- {placeholder}
48
- />
49
- </div>
50
- <button type="submit" class={btnClass}
51
- ><svg
52
- class="w-5 h-5"
53
- fill="none"
54
- stroke="currentColor"
55
- viewBox="0 0 24 24"
56
- xmlns="http://www.w3.org/2000/svg"
57
- ><path
58
- stroke-linecap="round"
59
- stroke-linejoin="round"
60
- stroke-width="2"
61
- d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z"
62
- /></svg
63
- ></button
64
- >
5
+ <form class="flex gap-2" on:submit>
6
+ <Search size="md" {...$$restProps} />
7
+ <Button class="!p-2.5">
8
+ <svg
9
+ class="w-5 h-5"
10
+ fill="none"
11
+ stroke="currentColor"
12
+ viewBox="0 0 24 24"
13
+ xmlns="http://www.w3.org/2000/svg"
14
+ ><path
15
+ stroke-linecap="round"
16
+ stroke-linejoin="round"
17
+ stroke-width="2"
18
+ d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" /></svg>
19
+ </Button>
65
20
  </form>
@@ -2,27 +2,9 @@ import { SvelteComponentTyped } from "svelte";
2
2
  declare const __propDef: {
3
3
  props: {
4
4
  [x: string]: any;
5
- id?: string | undefined;
6
- labelClass?: string | undefined;
7
- iconClass?: string | undefined;
8
- iconDivClass?: string | undefined;
9
- inputClass?: string | undefined;
10
- btnClass?: string | undefined;
11
- placeholder?: string | undefined;
12
5
  };
13
6
  events: {
14
7
  submit: SubmitEvent;
15
- blur: FocusEvent;
16
- change: Event;
17
- click: MouseEvent;
18
- focus: FocusEvent;
19
- keydown: KeyboardEvent;
20
- keypress: KeyboardEvent;
21
- keyup: KeyboardEvent;
22
- mouseenter: MouseEvent;
23
- mouseleave: MouseEvent;
24
- mouseover: MouseEvent;
25
- paste: ClipboardEvent;
26
8
  } & {
27
9
  [evt: string]: CustomEvent<any>;
28
10
  };
package/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ export { default as Accordion } from './accordions/Accordion.svelte';
1
2
  export { default as AccordionItem } from './accordions/AccordionItem.svelte';
2
3
  export { default as Alert } from './alerts/Alert.svelte';
3
4
  export { default as Avatar } from './avatar/Avatar.svelte';
@@ -29,6 +30,7 @@ export { default as FloatingLabelInput } from './forms/FloatingLabelInput.svelte
29
30
  export { default as Helper } from './forms/Helper.svelte';
30
31
  export { default as Iconinput } from './forms/Iconinput.svelte';
31
32
  export { default as Input } from './forms/Input.svelte';
33
+ export { default as InputAddon } from './forms/InputAddon.svelte';
32
34
  export { default as Label } from './forms/Label.svelte';
33
35
  export { default as RadioInline } from './forms/RadioInline.svelte';
34
36
  export { default as Radio } from './forms/Radio.svelte';
package/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  // Accordion
2
+ export { default as Accordion } from './accordions/Accordion.svelte';
2
3
  export { default as AccordionItem } from './accordions/AccordionItem.svelte';
3
4
  // Alerts
4
5
  export { default as Alert } from './alerts/Alert.svelte';
@@ -44,6 +45,7 @@ export { default as FloatingLabelInput } from './forms/FloatingLabelInput.svelte
44
45
  export { default as Helper } from './forms/Helper.svelte';
45
46
  export { default as Iconinput } from './forms/Iconinput.svelte';
46
47
  export { default as Input } from './forms/Input.svelte';
48
+ export { default as InputAddon } from './forms/InputAddon.svelte';
47
49
  export { default as Label } from './forms/Label.svelte';
48
50
  export { default as RadioInline } from './forms/RadioInline.svelte';
49
51
  export { default as Radio } from './forms/Radio.svelte';
@@ -1,11 +1,10 @@
1
1
  import { SvelteComponentTyped } from "svelte";
2
- import type { Size } from '../types';
3
2
  declare const __propDef: {
4
3
  props: {
5
4
  [x: string]: any;
6
5
  open?: boolean | undefined;
7
6
  title?: string | undefined;
8
- size?: Size | undefined;
7
+ size?: any;
9
8
  placement?: "top-left" | "top-center" | "top-right" | "center-left" | "center" | "center-right" | "bottom-left" | "bottom-center" | "bottom-right" | undefined;
10
9
  autoclose?: boolean | undefined;
11
10
  permanent?: boolean | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flowbite-svelte",
3
- "version": "0.27.3",
3
+ "version": "0.27.5",
4
4
  "description": "Flowbite components for Svelte",
5
5
  "main": "index.js",
6
6
  "author": {
@@ -101,6 +101,7 @@
101
101
  ],
102
102
  "exports": {
103
103
  "./package.json": "./package.json",
104
+ "./accordions/Accordion.svelte": "./accordions/Accordion.svelte",
104
105
  "./accordions/AccordionItem.svelte": "./accordions/AccordionItem.svelte",
105
106
  "./alerts/Alert.svelte": "./alerts/Alert.svelte",
106
107
  "./avatar/Avatar.svelte": "./avatar/Avatar.svelte",
@@ -139,6 +140,7 @@
139
140
  "./forms/Helper.svelte": "./forms/Helper.svelte",
140
141
  "./forms/Iconinput.svelte": "./forms/Iconinput.svelte",
141
142
  "./forms/Input.svelte": "./forms/Input.svelte",
143
+ "./forms/InputAddon.svelte": "./forms/InputAddon.svelte",
142
144
  "./forms/Label.svelte": "./forms/Label.svelte",
143
145
  "./forms/Radio.svelte": "./forms/Radio.svelte",
144
146
  "./forms/RadioInline.svelte": "./forms/RadioInline.svelte",
@@ -4,21 +4,23 @@ import CloseButton from '../utils/CloseButton.svelte';
4
4
  import { fade } from 'svelte/transition';
5
5
  export let color = 'blue';
6
6
  export let simple = false;
7
- // Absolute position
8
- export let position = undefined; // default not set
9
- export let visible = true;
7
+ export let position = 'none'; // default not set
8
+ export let open = true;
10
9
  export let divClass = 'w-full max-w-xs p-4';
11
- $: classDiv = classNames(divClass, {
12
- 'absolute top-5 left-5': position == 'tl',
13
- 'absolute top-5 right-5': position == 'tr',
14
- 'absolute bottom-5 left-5': position == 'bl',
15
- 'absolute bottom-5 right-5': position == 'br'
16
- }, $$props.class);
10
+ const positions = {
11
+ 'top-left': 'absolute top-5 left-5',
12
+ 'top-right': 'absolute top-5 right-5',
13
+ 'bottom-left': 'absolute bottom-5 left-5',
14
+ 'bottom-right': 'absolute bottom-5 right-5',
15
+ none: ''
16
+ };
17
+ let classDiv;
18
+ $: classDiv = classNames(divClass, positions[position], $$props.class);
17
19
  let iconClass;
18
20
  $: iconClass = classNames('inline-flex items-center justify-center flex-shrink-0 w-8 h-8 mr-3');
19
21
  </script>
20
22
 
21
- {#if visible}
23
+ {#if open}
22
24
  <Frame rounded border transition={fade} {...$$restProps} class={classDiv} role="alert">
23
25
  <div class="flex {$$slots.extra ? 'items-start' : 'items-center'}">
24
26
  {#if $$slots.icon}
@@ -30,7 +32,7 @@ $: iconClass = classNames('inline-flex items-center justify-center flex-shrink-0
30
32
  <slot name="extra" />
31
33
  </div>
32
34
  {#if !simple}
33
- <CloseButton on:click={() => (visible = false)} />
35
+ <CloseButton on:click={() => (open = false)} />
34
36
  {/if}
35
37
  </div>
36
38
  </Frame>
@@ -5,8 +5,8 @@ declare const __propDef: {
5
5
  [x: string]: any;
6
6
  color?: Colors | undefined;
7
7
  simple?: boolean | undefined;
8
- position?: "br" | "tr" | "tl" | "bl" | undefined;
9
- visible?: boolean | undefined;
8
+ position?: "none" | "top-left" | "top-right" | "bottom-left" | "bottom-right" | undefined;
9
+ open?: boolean | undefined;
10
10
  divClass?: string | undefined;
11
11
  };
12
12
  events: {
@@ -10,7 +10,6 @@ const styles = {
10
10
  };
11
11
  let toolTipClass;
12
12
  $: {
13
- $$restProps.color || (style = 'custom');
14
13
  if ($$restProps.color)
15
14
  style = 'custom';
16
15
  else
package/types.d.ts CHANGED
@@ -1,8 +1,4 @@
1
1
  import type { SvelteComponent } from 'svelte';
2
- export declare type AccordionIconType = {
3
- up: typeof SvelteComponent;
4
- down: typeof SvelteComponent;
5
- };
6
2
  export interface ActivityType {
7
3
  title: HTMLElement | string;
8
4
  date: Date | string;
@@ -18,34 +14,9 @@ export interface AuthFieldType {
18
14
  placeholder?: string;
19
15
  }
20
16
  export declare type AuthFunctionType = () => Promise<void>;
21
- export interface AvatarType {
22
- src?: string;
23
- alt?: string;
24
- size?: number;
25
- border?: boolean;
26
- round?: boolean;
27
- header?: string;
28
- text?: string;
29
- }
30
- export interface ButtonGroupType {
31
- name: string;
32
- href?: string;
33
- rel?: string;
34
- icon?: typeof SvelteComponent;
35
- iconSize?: number;
36
- iconClass?: string;
37
- }
38
17
  export declare type ButtonType = 'button' | 'submit' | 'reset';
39
18
  export declare type Buttontypes = 'blue' | 'blue-outline' | 'dark' | 'dark-outline' | 'light' | 'green' | 'green-outline' | 'red' | 'red-outline' | 'yellow' | 'yellow-outline' | 'purple' | 'purple-outline';
40
19
  export declare type Buttonshadows = 'blue' | 'green' | 'cyan' | 'teal' | 'lime' | 'red' | 'pink' | 'purple';
41
- export declare type CardButtonType = {
42
- textSize?: Textsize;
43
- name: string;
44
- type?: Buttontypes;
45
- href?: string;
46
- rel?: string;
47
- rounded?: boolean;
48
- };
49
20
  export declare type CarouselIconType = {
50
21
  next: typeof SvelteComponent;
51
22
  prev: typeof SvelteComponent;
@@ -58,10 +29,6 @@ export interface CheckboxType {
58
29
  helper?: string;
59
30
  }
60
31
  export declare type Colors = 'blue' | 'gray' | 'red' | 'yellow' | 'purple' | 'green' | 'indigo' | 'pink' | 'white' | 'custom';
61
- export declare type CrumbType = {
62
- label: string;
63
- href: string;
64
- };
65
32
  export interface DotType {
66
33
  top?: boolean;
67
34
  color?: string;
@@ -76,7 +43,6 @@ export interface drawerTransitionParamTypes {
76
43
  y?: number;
77
44
  }
78
45
  export declare type drawerTransitionTypes = 'fade' | 'fly' | 'slide' | 'blur' | 'in:fly' | 'out:fly' | 'in:slide' | 'out:slide' | 'in:fade' | 'out:fade' | 'in:blur' | 'out:blur' | undefined;
79
- export declare type DropdownColorType = 'blue' | 'blue-outline' | 'dark' | 'dark-outline' | 'light' | 'green' | 'green-outline' | 'red' | 'red-outline' | 'yellow' | 'yellow-outline' | 'purple' | 'purple-outline';
80
46
  export interface DropdownType {
81
47
  name: string;
82
48
  href: string;
@@ -110,7 +76,7 @@ export declare type ImgType = {
110
76
  src: string;
111
77
  alt?: string;
112
78
  };
113
- export declare type InputType = 'color' | 'date' | 'datetime-local' | 'email' | 'file' | 'hidden' | 'image' | 'month' | 'number' | 'password' | 'reset' | 'submit' | 'tel' | 'text' | 'time' | 'url' | 'week';
79
+ export declare type InputType = 'color' | 'date' | 'datetime-local' | 'email' | 'file' | 'hidden' | 'image' | 'month' | 'number' | 'password' | 'reset' | 'submit' | 'tel' | 'text' | 'time' | 'url' | 'week' | 'search';
114
80
  export interface InteractiveTabType {
115
81
  name: string;
116
82
  id: number;
@@ -152,7 +118,8 @@ export declare const sm = "sm";
152
118
  export declare const md = "md";
153
119
  export declare const lg = "lg";
154
120
  export declare const xl = "xl";
155
- export declare type Size = typeof xs | typeof sm | typeof md | typeof lg | typeof xl;
121
+ export declare type SizeType = typeof xs | typeof sm | typeof md | typeof lg | typeof xl;
122
+ export declare type FormSizeType = typeof sm | typeof md | typeof lg;
156
123
  export interface PillTabType {
157
124
  name: string;
158
125
  selected: boolean;