flowbite-svelte 0.26.11 → 0.26.14

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,28 @@
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.26.14](https://github.com/themesberg/flowbite-svelte/compare/v0.26.13...v0.26.14) (2022-09-06)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * Heading and P update ([2313e3e](https://github.com/themesberg/flowbite-svelte/commit/2313e3e5ecb38ee69839a26b12b7c41cc099f75e))
11
+ * toast transitions ([6659682](https://github.com/themesberg/flowbite-svelte/commit/6659682250ab9d2337f06c2b424431366cf9ced0))
12
+
13
+ ### [0.26.13](https://github.com/themesberg/flowbite-svelte/compare/v0.26.12...v0.26.13) (2022-09-05)
14
+
15
+
16
+ ### Bug Fixes
17
+
18
+ * add track to video component for A11y ([ef69a83](https://github.com/themesberg/flowbite-svelte/commit/ef69a83325ab11e4d3548e5e28033ae9e02bfe40))
19
+
20
+ ### [0.26.12](https://github.com/themesberg/flowbite-svelte/compare/v0.26.11...v0.26.12) (2022-09-05)
21
+
22
+
23
+ ### Features
24
+
25
+ * add labelInsideClass to progressbar component ([fe20cd7](https://github.com/themesberg/flowbite-svelte/commit/fe20cd7f693f21e052dc5adb3fd3eb4bcfa80b76))
26
+
5
27
  ### [0.26.11](https://github.com/themesberg/flowbite-svelte/compare/v0.26.10...v0.26.11) (2022-09-05)
6
28
 
7
29
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flowbite-svelte",
3
- "version": "0.26.11",
3
+ "version": "0.26.14",
4
4
  "description": "Flowbite components for Svelte",
5
5
  "main": "index.js",
6
6
  "author": {
@@ -49,11 +49,11 @@
49
49
  "accordion",
50
50
  "alert",
51
51
  "avatar",
52
- "badges",
53
- "breadcrumbs",
54
- "button-groups",
55
- "buttons",
56
- "cards",
52
+ "badge",
53
+ "breadcrumb",
54
+ "button-group",
55
+ "button",
56
+ "card",
57
57
  "carousel",
58
58
  "darkmode",
59
59
  "dropdown",
@@ -61,19 +61,22 @@
61
61
  "forms",
62
62
  "kbd",
63
63
  "list group",
64
+ "mega menu",
64
65
  "modal",
65
66
  "navbar",
66
- "paginations",
67
- "progress bars",
67
+ "pagination",
68
+ "progressbar",
68
69
  "rating",
69
- "sidebars",
70
+ "sidebar",
70
71
  "skeleton",
71
- "spinners",
72
- "tables",
73
- "tabs",
74
- "timelines",
75
- "toasts",
76
- "tooltip"
72
+ "spinner",
73
+ "table",
74
+ "tab",
75
+ "timeline",
76
+ "toast",
77
+ "tooltip",
78
+ "typography",
79
+ "video"
77
80
  ],
78
81
  "repository": {
79
82
  "type": "git",
@@ -93,7 +96,8 @@
93
96
  "Zoltán Szőgyényi <zoltan@themesberg.com>",
94
97
  "Robert Tanislav <robert@themesberg.com>",
95
98
  "Victor Cordos <victor@themesberg.com>",
96
- "Shinichi Okada <okada.shin@gmail.com>"
99
+ "Shinichi Okada <okada.shin@gmail.com>",
100
+ "Jakub Jagielka <jjagielka@gmail.com>"
97
101
  ],
98
102
  "exports": {
99
103
  "./package.json": "./package.json",
@@ -4,6 +4,7 @@ export let size = 'h-2.5';
4
4
  export let labelInside = false;
5
5
  export let labelOutside = '';
6
6
  export let color = 'blue';
7
+ export let labelInsideClass = 'text-blue-100 text-xs font-medium text-center p-0.5 leading-none rounded-full';
7
8
  // let barColor: string;
8
9
  const barColors = {
9
10
  blue: 'bg-blue-600',
@@ -17,20 +18,17 @@ const barColors = {
17
18
  </script>
18
19
 
19
20
  {#if labelOutside}
20
- <div class="flex justify-between mb-1">
21
- <span class="text-base font-medium text-blue-700 dark:text-white">{labelOutside}</span>
22
- <span class="text-sm font-medium text-blue-700 dark:text-white">{progress}%</span>
23
- </div>
21
+ <div {...$$restProps} class={classNames('flex justify-between mb-1', $$props.class)}>
22
+ <span class="text-base font-medium text-blue-700 dark:text-white">{labelOutside}</span>
23
+ <span class="text-sm font-medium text-blue-700 dark:text-white">{progress}%</span>
24
+ </div>
24
25
  {/if}
25
- <div class="w-full bg-gray-200 rounded-full {size} dark:bg-gray-700">
26
- {#if labelInside}
27
- <div
28
- class="bg-blue-600 text-xs font-medium text-blue-100 text-center p-0.5 leading-none rounded-full"
29
- style="width: {progress}%"
30
- >
31
- {progress}%
32
- </div>
33
- {:else}
34
- <div class={classNames(barColors[color], size, 'rounded-full')} style="width: {progress}%" />
35
- {/if}
26
+ <div class={classNames('w-full bg-gray-200 rounded-full dark:bg-gray-700', size, $$props.class)}>
27
+ {#if labelInside}
28
+ <div class={classNames(labelInsideClass, barColors[color])} style="width: {progress}%">
29
+ {progress}%
30
+ </div>
31
+ {:else}
32
+ <div class={classNames(barColors[color], size, 'rounded-full')} style="width: {progress}%" />
33
+ {/if}
36
34
  </div>
@@ -2,11 +2,13 @@ import { SvelteComponentTyped } from "svelte";
2
2
  import type { Colors } from '../types';
3
3
  declare const __propDef: {
4
4
  props: {
5
+ [x: string]: any;
5
6
  progress?: string;
6
7
  size?: string;
7
8
  labelInside?: boolean;
8
9
  labelOutside?: string;
9
10
  color?: Colors;
11
+ labelInsideClass?: string;
10
12
  };
11
13
  events: {
12
14
  [evt: string]: CustomEvent<any>;
@@ -1,6 +1,7 @@
1
1
  <script>import Frame from '../utils/Frame.svelte';
2
2
  import classNames from 'classnames';
3
3
  import CloseButton from '../utils/CloseButton.svelte';
4
+ import { fade } from 'svelte/transition';
4
5
  export let color = 'blue';
5
6
  export let simple = false;
6
7
  // Absolute position
@@ -18,19 +19,19 @@ $: iconClass = classNames('inline-flex items-center justify-center flex-shrink-0
18
19
  </script>
19
20
 
20
21
  {#if visible}
21
- <Frame rounded border transition="fade" {...$$restProps} class={classDiv} role="alert">
22
- <div class="flex {$$slots.extra ? 'items-start' : 'items-center'}">
23
- {#if $$slots.icon}
24
- <Frame {color} rounded class={iconClass}><slot name="icon" /></Frame>
25
- {/if}
22
+ <Frame rounded border transition={fade} {...$$restProps} class={classDiv} role="alert">
23
+ <div class="flex {$$slots.extra ? 'items-start' : 'items-center'}">
24
+ {#if $$slots.icon}
25
+ <Frame {color} rounded class={iconClass}><slot name="icon" /></Frame>
26
+ {/if}
26
27
 
27
- <div class="text-sm font-normal w-full">
28
- <slot />
29
- <slot name="extra" />
30
- </div>
31
- {#if !simple}
32
- <CloseButton on:click={() => (visible = false)} />
33
- {/if}
34
- </div>
35
- </Frame>
28
+ <div class="text-sm font-normal w-full">
29
+ <slot />
30
+ <slot name="extra" />
31
+ </div>
32
+ {#if !simple}
33
+ <CloseButton on:click={() => (visible = false)} />
34
+ {/if}
35
+ </div>
36
+ </Frame>
36
37
  {/if}
@@ -1,7 +1,7 @@
1
1
  <script>import classNames from 'classnames';
2
2
  export let tag = 'h1';
3
3
  export let color = 'text-gray-900 dark:text-white';
4
- export let customSize;
4
+ export let customSize = '';
5
5
  const textSizes = {
6
6
  h1: 'text-5xl font-extrabold',
7
7
  h2: 'text-4xl font-bold',
@@ -4,7 +4,7 @@ declare const __propDef: {
4
4
  [x: string]: any;
5
5
  tag?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
6
6
  color?: string;
7
- customSize: string;
7
+ customSize?: string;
8
8
  };
9
9
  events: {
10
10
  [evt: string]: CustomEvent<any>;
@@ -10,7 +10,7 @@ export let opacity;
10
10
  export let whitespace = 'normal';
11
11
  export let size = 'base';
12
12
  export let space;
13
- export let weight;
13
+ export let weight = 'normal';
14
14
  const sizes = {
15
15
  xs: 'text-xs',
16
16
  sm: 'text-sm',
@@ -67,8 +67,6 @@ let colorAndopacity = color
67
67
  .map((element) => element.trim())
68
68
  .map((element) => element + '/' + String(opacity))
69
69
  .join(' ');
70
- // console.log('colorArr', colorAndopacity);
71
- // console.log(typeof colorAndopacity);
72
70
  let classP = classNames(size && sizes[size], (opacity && colorAndopacity) || (color && color), height && heights[height], weight && weights[weight], space && spaces[space], align && aligns[align], justify && 'text-justify', italic && 'italic', firstupper && upperClass, whitespace && whitespaces[whitespace], $$props.class);
73
71
  </script>
74
72
 
@@ -13,7 +13,7 @@ declare const __propDef: {
13
13
  whitespace?: 'normal' | 'nowrap' | 'pre' | 'preline' | 'prewrap';
14
14
  size?: 'xs' | 'sm' | 'base' | 'lg' | 'xl' | '2xl' | '3xl' | '4xl' | '5xl' | '6xl' | '7xl' | '8xl' | '9xl';
15
15
  space: 'tighter' | 'tight' | 'normal' | 'wide' | 'wider' | 'widest';
16
- weight: 'thin' | 'extralight' | 'light' | 'normal' | 'medium' | 'semibold' | 'bold' | 'extrabold' | 'black';
16
+ weight?: 'thin' | 'extralight' | 'light' | 'normal' | 'medium' | 'semibold' | 'bold' | 'extrabold' | 'black';
17
17
  };
18
18
  events: {
19
19
  [evt: string]: CustomEvent<any>;
@@ -4,6 +4,9 @@
4
4
  // export let autoplay: boolean = false;
5
5
  export let src;
6
6
  export let type = 'video/mp4';
7
+ export let trackSrc = '';
8
+ export let srclang = 'en';
9
+ export let label = 'english_captions';
7
10
  // export let attribute = '';
8
11
  let videoClass = classNames($$props.class);
9
12
  // const setAttribute = (node, params) => {
@@ -14,5 +17,6 @@ let videoClass = classNames($$props.class);
14
17
  <video {...$$restProps} class={videoClass}>
15
18
  <source {src} {type} />
16
19
  <slot />
20
+ <track src={trackSrc} kind="captions" {srclang} {label} />
17
21
  Your browser does not support the video tag.
18
22
  </video>
@@ -4,6 +4,9 @@ declare const __propDef: {
4
4
  [x: string]: any;
5
5
  src: string;
6
6
  type?: string;
7
+ trackSrc?: string;
8
+ srclang?: string;
9
+ label?: string;
7
10
  };
8
11
  events: {
9
12
  [evt: string]: CustomEvent<any>;