@functionalcms/svelte-components 2.12.12 → 2.12.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.
|
@@ -1,38 +1,25 @@
|
|
|
1
1
|
<style>
|
|
2
|
-
:global(.box) {
|
|
3
|
-
text-align: center;
|
|
4
|
-
justify-content: center !important;
|
|
5
|
-
}
|
|
6
|
-
img {
|
|
7
|
-
width: 100%;
|
|
8
|
-
}
|
|
9
2
|
</style>
|
|
10
3
|
|
|
11
|
-
<script>import {} from "
|
|
4
|
+
<script>import { AlignItmes, Justify, Orientation, ShowItem } from "@functionalcms/svelte-components";
|
|
12
5
|
import { Card } from "agnostic-svelte";
|
|
13
6
|
export let items = [];
|
|
14
7
|
export let galleryCss = "";
|
|
15
|
-
export let
|
|
8
|
+
export let justify = Justify.Between;
|
|
9
|
+
export let alignItems = AlignItmes.Center;
|
|
10
|
+
export let orientation = Orientation.Row;
|
|
16
11
|
$:
|
|
17
12
|
galleryKlasses = [
|
|
18
13
|
"flex",
|
|
19
14
|
"flex-row-dynamic",
|
|
20
|
-
galleryCss
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
"box",
|
|
25
|
-
cardCss
|
|
15
|
+
galleryCss,
|
|
16
|
+
`${orientation}`,
|
|
17
|
+
`${justify}`,
|
|
18
|
+
`${alignItems}`
|
|
26
19
|
].filter((c) => c).join(" ");
|
|
27
20
|
</script>
|
|
28
21
|
<Card css={galleryKlasses}>
|
|
29
22
|
{#each items as item}
|
|
30
|
-
<
|
|
31
|
-
<a href={item?.path}>
|
|
32
|
-
<img src={item?.image} alt={item.title} />
|
|
33
|
-
<h2>{item.title}</h2>
|
|
34
|
-
<p>{item.short}</p>
|
|
35
|
-
</a>
|
|
36
|
-
</Card>
|
|
23
|
+
<slot item={item}></slot>
|
|
37
24
|
{/each}
|
|
38
25
|
</Card>
|
|
@@ -1,15 +1,20 @@
|
|
|
1
1
|
import { SvelteComponent } from "svelte";
|
|
2
|
-
import { type ShowItem } from './ShowItem';
|
|
3
2
|
declare const __propDef: {
|
|
4
3
|
props: {
|
|
5
4
|
items?: ShowItem[] | undefined;
|
|
6
5
|
galleryCss?: string | undefined;
|
|
7
|
-
|
|
6
|
+
justify?: any;
|
|
7
|
+
alignItems?: any;
|
|
8
|
+
orientation?: any;
|
|
8
9
|
};
|
|
9
10
|
events: {
|
|
10
11
|
[evt: string]: CustomEvent<any>;
|
|
11
12
|
};
|
|
12
|
-
slots: {
|
|
13
|
+
slots: {
|
|
14
|
+
default: {
|
|
15
|
+
item: ShowItem;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
13
18
|
};
|
|
14
19
|
export type GalleryProps = typeof __propDef.props;
|
|
15
20
|
export type GalleryEvents = typeof __propDef.events;
|