@likable-hair/svelte 0.0.61 → 0.0.63
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/buttons/Button.svelte +1 -1
- package/common/Card.svelte +1 -1
- package/common/Gesture.svelte +1 -1
- package/common/MediaQuery.svelte +1 -1
- package/common/Menu.svelte +1 -1
- package/common/SimpleTable.svelte +2 -2
- package/dates/Calendar.svelte +1 -1
- package/dates/DatePicker.svelte +1 -1
- package/dates/MonthSelector.svelte +1 -1
- package/dates/TimePickerTextField.svelte +1 -1
- package/dates/YearSelector.svelte +1 -1
- package/dialogs/Dialog.svelte +1 -1
- package/forms/Autocomplete.svelte +2 -2
- package/forms/Checkbox.svelte +1 -1
- package/forms/FileInput.svelte +1 -1
- package/forms/FileInputList.svelte +1 -1
- package/forms/Switch.svelte +1 -1
- package/forms/Textarea.svelte +1 -1
- package/forms/Textfield.svelte +2 -2
- package/forms/VerticalSwitch.svelte +1 -1
- package/forms/VerticalTextSwitch.svelte +1 -1
- package/loaders/CircularLoader.svelte +1 -1
- package/loaders/Skeleton.svelte +2 -2
- package/media/AttachmentDownloader.svelte +1 -1
- package/media/Avatar.svelte +1 -1
- package/media/Carousel.svelte +1 -1
- package/media/DescriptiveAvatar.svelte +1 -1
- package/media/Gallery.svelte +3 -5
- package/media/Icon.svelte +1 -1
- package/media/Image.svelte +1 -1
- package/media/ImageGrid.svelte +2 -2
- package/navigation/Breadcrumb.svelte +2 -2
- package/navigation/Chip.svelte +1 -1
- package/navigation/Drawer.svelte +1 -1
- package/navigation/HeaderMenu.svelte +1 -1
- package/navigation/Navigator.svelte +2 -2
- package/navigation/TabSwitcher.svelte +2 -2
- package/package.json +5 -4
- package/progress/ProgressBar.svelte +1 -1
- package/shop/ProductCard.svelte +1 -1
- package/shop/ProductsGrid.svelte +1 -1
- package/stores/mediaQuery.js +1 -1
- package/timeline/ScrollTimeLine.svelte +2 -2
- package/timeline/SimpleTimeLine.svelte +2 -2
package/buttons/Button.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let type = 'default', active = false, loading = false, icon = undefined, iconSize = 15, clazz = '', maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = undefined, height = undefined, textAlign = "center", cursor = "pointer", padding = "5px", fontSize = undefined, color = undefined, display = undefined, justifyContent = undefined, alignItems = undefined, backgroundColor = undefined, hoverBackgroundColor = '#88888847', activeBackgroundColor = hoverBackgroundColor, borderRadius = undefined, border = undefined, boxShadow = undefined, loaderHeight = undefined, loaderWidth = undefined, disabled = false;
|
|
2
2
|
export { clazz as class };
|
|
3
3
|
import { createEventDispatcher } from 'svelte';
|
|
4
4
|
const dispatch = createEventDispatcher();
|
package/common/Card.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let outlined = false, maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = 'fit-content', height = undefined, padding = "5px", borderRadius = "5px", backgroundColor = "rgb(252, 252, 252)", color = undefined, borderColor = undefined, borderWidth = undefined, marginBottom = undefined, marginTop = undefined, marginLeft = undefined, marginRight = undefined, boxShadow = "0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)";
|
|
2
2
|
</script>
|
|
3
3
|
|
|
4
4
|
<div
|
package/common/Gesture.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { createEventDispatcher } from 'svelte';
|
|
2
2
|
const dispatch = createEventDispatcher();
|
|
3
3
|
// TODO export the handler into a service to avoid mount 3 listeners for every component instance
|
|
4
4
|
export let timeThreshold = 200, diagonalThreshold = 100;
|
package/common/MediaQuery.svelte
CHANGED
package/common/Menu.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { v4 as uuidv4 } from 'uuid';
|
|
2
2
|
import { fly } from 'svelte/transition';
|
|
3
3
|
export let open = false, top = undefined, left = undefined, width, height, maxHeight = undefined, overflow = "auto", refreshPosition = false, boxShadow = undefined, borderRadius = undefined, activator = undefined, anchor = 'bottom', closeOnClickOutside = false, inAnimation = fly, inAnimationConfig = {
|
|
4
4
|
duration: 100,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script context="module"
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { dateToString } from "../dates/utils";
|
|
4
4
|
export let headers = undefined, items = undefined, backgroundColor = "rgba(255,255,255,0)", headerColor = "rgba(0,0,0,0.05)", rowSeparatorColor = headerColor, headerHeight = "30px", rowHeight = "70px", minWidth = undefined, height = "100%", width = "100%";
|
|
5
5
|
</script>
|
|
6
6
|
|
package/dates/Calendar.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { onMount } from 'svelte';
|
|
2
2
|
import { fly } from 'svelte/transition';
|
|
3
3
|
import { getDateRowsStats, getDaysNames } from './utils';
|
|
4
4
|
export let selectedDate = undefined, visibleMonth = new Date().getMonth(), visibleYear = new Date().getFullYear(), locale = 'it', showExtraMonthDays = true, showHeader = true, height = "100%", width = "100%", dayWidth = '30px', dayHeight = '30px', dayHoverColor = '#c9c8c873', daySelectedColor = '#adadad', selectedTextColor = "black", gridGap = "1px", dayBackgroundColor = undefined, animationDuration = 200;
|
package/dates/DatePicker.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { getMonthName, dateToString } from "./utils";
|
|
2
2
|
import YearSelector from "./YearSelector.svelte";
|
|
3
3
|
import MonthSelector from "./MonthSelector.svelte";
|
|
4
4
|
import Calendar from "./Calendar.svelte";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { getMonthName } from './utils';
|
|
2
2
|
export let selectedMonth = undefined, locale = 'it', height = "100%", width = "100%", monthSelectedColor = '#adadad', monthSelectedTextColor = '#21a';
|
|
3
3
|
import { createEventDispatcher } from 'svelte';
|
|
4
4
|
const dispatch = createEventDispatcher();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import Textfield from "../forms/Textfield.svelte";
|
|
2
2
|
import VerticalTextSwitch from "../forms/VerticalTextSwitch.svelte";
|
|
3
3
|
import "./DatePicker.svelte";
|
|
4
4
|
export let hourFormat = "24", dayPeriod = "am", time = undefined, text = "", fieldSeparator = ":", placeholder = "Insert time...", focusedBoxShadow = "#C0D6FF 0px 2px 10px", borderColor = "", borderWeight = "1px", fontSize = "16px", width = "100%";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { scrollAtCenter } from "../common/scroller";
|
|
2
2
|
import { createEventDispatcher, onMount } from 'svelte';
|
|
3
3
|
export let selectedYear = undefined, selectableYears = [...Array(150).keys()].map(i => i + (new Date().getFullYear() - 75)), height = "100%", width = "100%";
|
|
4
4
|
let container, targetButtons = {};
|
package/dialogs/Dialog.svelte
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script context="module"
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>export let values = [], items, searchFunction = undefined, multiple = false, disabled = false, width = "auto", height = "auto", maxWidth = undefined,
|
|
4
4
|
// textfield
|
|
5
5
|
textFieldLabel = "", textFieldPlaceholder = "", textFieldColor = null, textFieldVariant = 'boxed', textFieldMaxWidth = "min(100px, 90%)", textFieldMinWidth = undefined, textFieldHeight = "auto", textFieldTextColor = "black", textFieldBorderWeight = "2px", textFieldBorderRadius = "5px", textFieldBorderColor = null, textFieldFocusBorderColor = null, textFieldFocusedBoxShadow = undefined, textFieldBackgroundColor = null, textFieldPadding = undefined, textFieldPaddingLeft = undefined, textFieldPaddingRight = undefined, textFieldPaddingBottom = undefined, textFieldPaddingTop = undefined, textFieldFontSize = undefined,
|
|
6
6
|
// menu
|
package/forms/Checkbox.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let value = false, id = undefined, disabled = false, activeColor = "#275efe", activeInnerColor = "#fff", focusShadow = "2px rgba(39, 94, 254, 0.3)", borderColor = "#bbc1e1", borderHoverColor = "#275efe", backgroundColor = "#fff", disabledColor = "#f6f8ff", disabledInnerColor = "#e1e6f9";
|
|
2
2
|
</script>
|
|
3
3
|
|
|
4
4
|
<input
|
package/forms/FileInput.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { createEventDispatcher } from 'svelte';
|
|
2
2
|
export let files = undefined, persistOverUpload = true, height = "100%", width = "100%", backgroundColor = "rgba(255,255,255,0)", textColor = "black", rounded = true, disabled = false, focusShadow = "inset 0 0 0 1px rgb(255 255 255/0.1), 0 0 #0000, 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)";
|
|
3
3
|
let inputElement = undefined;
|
|
4
4
|
let dropAreaActive = false;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import Button from "../buttons/Button.svelte";
|
|
2
2
|
import FileInput from "./FileInput.svelte";
|
|
3
3
|
import Icon from "../media/Icon.svelte";
|
|
4
4
|
export let files = undefined, persistOverUpload = true, height = "100%", width = "100%", backgroundColor = "rgba(255,255,255,0)", textColor = "rgba(0,0,0,0.7)", rounded = true, focusShadow = undefined, dropAreaActive = true, icon = "mdi-folder", iconSize = 30, selectedRowColor = "red", selectedRowBackground = "rgba(0,0,0,0.1)";
|
package/forms/Switch.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let value = false, height = "20px", width = "40px", padding = "6px", borderRadius = "10px", toggleActiveColor = "#5c5c5c", toggleDeactiveColor = "#5c5c5c", backgroundActiveColor = "#e6e6e6", backgroundDeactiveColor = "#e6e6e6", animationDuration = "0.1s";
|
|
2
2
|
</script>
|
|
3
3
|
|
|
4
4
|
<div
|
package/forms/Textarea.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { v4 as uuidv4 } from 'uuid';
|
|
2
2
|
export let label = null, placeholder = "placeholder", textAreaId = uuidv4(), fontFamily = "inherit", value = "", resizable = true, disabled = false, readOnly = false, maxLength = undefined, textColor = "black", border = "none", borderRadius = "5px", focusedBoxShadow = undefined, backgroundColor = null, padding = undefined, paddingLeft = undefined, paddingRight = undefined, paddingBottom = undefined, paddingTop = undefined, fontSize = undefined, labelFontSize = undefined, labelColor = undefined, width = "100%", height = "100%";
|
|
3
3
|
</script>
|
|
4
4
|
|
package/forms/Textfield.svelte
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>export let label = "", placeholder = "", color = null, value = "", disabled = false, variant = 'outlined', width = "100%", height = "50px", maxWidth = undefined, minWidth = undefined, textColor = "black", borderWeight = "2px", borderRadius = "5px", borderColor = null, focusBorderColor = null, focusedBoxShadow = undefined, backgroundColor = null, padding = undefined, paddingLeft = undefined, paddingRight = undefined, paddingBottom = undefined, paddingTop = undefined, fontSize = undefined, type = 'text', readonly = false, inputElement = undefined;
|
|
4
4
|
import { v4 as uuidv4 } from 'uuid';
|
|
5
5
|
import { onMount } from 'svelte';
|
|
6
6
|
let inputId = uuidv4(), focused = false, legendWidth = 0, labelElement = undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let value = false, height = "60px", width = "30px", rounded = false, backgroundColor = "#90CAF9", selectedOptionColor = backgroundColor, sliderColor = "white", optionColor = sliderColor, fontSize = "11px", animationDuration = "0.1s";
|
|
2
2
|
</script>
|
|
3
3
|
|
|
4
4
|
<div
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { fly } from 'svelte/transition';
|
|
2
2
|
export let value = false, height = "100%", width = "100%", backgroundColor = undefined, firstColor = undefined, secondColor = firstColor, fontSize = "12px", hoverBackgroundColor = undefined, hoverBoxShadow = undefined, animationDuration = 200;
|
|
3
3
|
let optionHeight = undefined;
|
|
4
4
|
</script>
|
package/loaders/Skeleton.svelte
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>export let sections = [], maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = "100%", height = "100%", padding = '10px', dark = false;
|
|
4
4
|
$: widthLessPadding = `calc(${width} - (${padding} * 2))`;
|
|
5
5
|
$: heightLessPadding = `calc(${height} - (${padding} * 2))`;
|
|
6
6
|
$: maxWidthLessPadding = `calc(${maxWidth} - (${padding} * 2))`;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let title = undefined, description = undefined, borderColor = "#B8B8B8", iconColor = "#8D8D8D", borderWidth = '1px', maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = 'fit-content', height = undefined;
|
|
2
2
|
import Icon from './Icon.svelte';
|
|
3
3
|
import Card from '../common/Card.svelte';
|
|
4
4
|
</script>
|
package/media/Avatar.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let src, alt = "", width = "40px", maxWidth = undefined, minWidth = undefined, height = "40px", maxHeight = undefined, minHeight = undefined, lazyLoaded = false, referrerpolicy = "no-referrer", borderRadius = "50%";
|
|
2
2
|
import Image from './Image.svelte';
|
|
3
3
|
</script>
|
|
4
4
|
|
package/media/Carousel.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { onMount } from 'svelte';
|
|
2
2
|
export let images = [], maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = "100%", height = "100%";
|
|
3
3
|
let container, localWidth = '0px', localHeight = '0px';
|
|
4
4
|
onMount(() => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let src, title = undefined, description = undefined, direction = 'row', reverse = false, avatarSpacing = '10px', width = undefined, maxWidth = undefined, minWidth = undefined, height = undefined, maxHeight = undefined, minHeight = undefined, lazyLoaded = false, borderRadius = "50%", referrerpolicy = "no-referrer";
|
|
2
2
|
let textAlignment;
|
|
3
3
|
$: if (direction == 'column') {
|
|
4
4
|
textAlignment = 'center';
|
package/media/Gallery.svelte
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
<script
|
|
2
|
-
|
|
3
|
-
<script >export let images = [], columns = undefined, imageMaxWidth = undefined, imageMinWidth = undefined, imageMaxHeight = undefined, imageMinHeight = undefined, imageHeight = undefined, imageWidth = undefined, disableHover = false, dark = false;
|
|
1
|
+
<script>export let images = [], columns = undefined, imageMaxWidth = undefined, imageMinWidth = undefined, imageMaxHeight = undefined, imageMinHeight = undefined, imageHeight = undefined, imageWidth = undefined, disableHover = false, dark = false;
|
|
4
2
|
let selectedIndex = undefined, selectedImage = undefined;
|
|
5
3
|
function handleImageClick(e) {
|
|
6
4
|
selectedIndex = e.detail.index;
|
|
@@ -8,12 +6,12 @@ function handleImageClick(e) {
|
|
|
8
6
|
$: if (selectedIndex !== undefined && selectedIndex !== null) {
|
|
9
7
|
selectedImage = images[selectedIndex];
|
|
10
8
|
}
|
|
11
|
-
function
|
|
9
|
+
function switchPrevious() {
|
|
12
10
|
if (selectedIndex < (images.length - 1)) {
|
|
13
11
|
selectedIndex++;
|
|
14
12
|
}
|
|
15
13
|
}
|
|
16
|
-
function
|
|
14
|
+
function switchNext() {
|
|
17
15
|
if (selectedIndex > 0) {
|
|
18
16
|
selectedIndex--;
|
|
19
17
|
}
|
package/media/Icon.svelte
CHANGED
package/media/Image.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import { browser } from '$app/environment';
|
|
2
2
|
export let maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = undefined, height = undefined, borderRadius = undefined, src = undefined, title = undefined, description = undefined, dark = false, disableHover = false, showSkeletonLoader = true, imageCover = true, imageContain = false;
|
|
3
3
|
const load = (src) => {
|
|
4
4
|
return new Promise(async (resolve, reject) => {
|
package/media/ImageGrid.svelte
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { createEventDispatcher } from 'svelte';
|
|
4
4
|
export let images = [], columns = undefined, imageMaxWidth = undefined, imageMinWidth = undefined, imageMaxHeight = undefined, imageMinHeight = undefined, imageHeight = undefined, imageWidth = undefined, disableHover = false, dark = false;
|
|
5
5
|
const dispatch = createEventDispatcher();
|
|
6
6
|
function handleImageClick(image, index) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { createEventDispatcher } from 'svelte';
|
|
4
4
|
const dispatch = createEventDispatcher();
|
|
5
5
|
export let items = [], underliner = true, separatorIcon = 'mdi-chevron-right', separatorIconSize = 10, spacing = "20px";
|
|
6
6
|
function handleLinkClick(item) {
|
package/navigation/Chip.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import Icon from '../media/Icon.svelte';
|
|
2
2
|
import Button from '../buttons/Button.svelte';
|
|
3
3
|
import { createEventDispatcher } from 'svelte';
|
|
4
4
|
export let close = false, closeIcon = "mdi-close-circle", color = "blue", textColor = "white", disabled = false, filter = false, filterIcon = "mdi-check", label = false, outlined = false, size = 12;
|
package/navigation/Drawer.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>import Navigator from './Navigator.svelte';
|
|
2
2
|
export let open = false, position = 'left', space = '200px', openingSpeed = '0.3s', overlaySpeed = '0.2s', blockScroll = true, color = undefined, overlay = true, backgroundColor = undefined, overlayColor = '#282828', overlayOpacity = '30%', zIndex = 30, items = [];
|
|
3
3
|
let height = undefined, width = undefined, top = undefined, bottom = undefined, left = undefined, right = undefined;
|
|
4
4
|
function handleClickOverlay() {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let title = "", items = [], hideOnScroll = true, initialRemoveShadow = false, initialBackgroundColor = undefined, backgroundColor = 'white', color = undefined, mobileMenu = true, zIndex = 25;
|
|
2
2
|
let scrollY, lastScrollY, visible = true;
|
|
3
3
|
function handleScroll() {
|
|
4
4
|
if (hideOnScroll) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script context="module"
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>export let items = [], color = undefined, vertical = false, space = '20px';
|
|
4
4
|
import { createEventDispatcher } from 'svelte';
|
|
5
5
|
const dispatch = createEventDispatcher();
|
|
6
6
|
function handleItemClick(item) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { afterUpdate, onMount } from 'svelte';
|
|
4
4
|
export let tabs = [], selected = undefined, mandatory = true, width = undefined, color = "rgb(51 65 85)", bookmarkColor = undefined, horizontalGuideColor = "rgb(51 65 85)", margin = "12px";
|
|
5
5
|
let tabButtons = {};
|
|
6
6
|
onMount(() => {
|
package/package.json
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@likable-hair/svelte",
|
|
3
3
|
"description": "A Svelte component for likablehair",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.63",
|
|
5
5
|
"devDependencies": {
|
|
6
6
|
"@sveltejs/adapter-auto": "next",
|
|
7
7
|
"@sveltejs/kit": "next",
|
|
8
8
|
"@testing-library/cypress": "^8.0.3",
|
|
9
9
|
"@testing-library/jest-dom": "^5.16.4",
|
|
10
|
+
"@testing-library/svelte": "^3.1.3",
|
|
10
11
|
"@typescript-eslint/eslint-plugin": "^4.31.1",
|
|
11
12
|
"@typescript-eslint/parser": "^4.31.1",
|
|
12
13
|
"autoprefixer": "^10.4.2",
|
|
@@ -15,6 +16,7 @@
|
|
|
15
16
|
"eslint": "^7.32.0",
|
|
16
17
|
"eslint-plugin-svelte3": "^3.2.1",
|
|
17
18
|
"jest": "^28.1.2",
|
|
19
|
+
"jest-css-modules-transform": "^4.4.2",
|
|
18
20
|
"jest-environment-jsdom": "^28.1.2",
|
|
19
21
|
"svelte": "^3.44.0",
|
|
20
22
|
"svelte-check": "^2.2.6",
|
|
@@ -23,14 +25,13 @@
|
|
|
23
25
|
"svelte2tsx": "^0.4.12",
|
|
24
26
|
"ts-jest": "^28.0.5",
|
|
25
27
|
"tslib": "^2.3.1",
|
|
26
|
-
"typescript": "^4.7.4"
|
|
27
|
-
"@testing-library/svelte": "^3.1.3",
|
|
28
|
-
"jest-css-modules-transform": "^4.4.2"
|
|
28
|
+
"typescript": "^4.7.4"
|
|
29
29
|
},
|
|
30
30
|
"type": "module",
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@mdi/font": "^6.5.95",
|
|
33
33
|
"@sveltejs/adapter-node": "^1.0.0-next.79",
|
|
34
|
+
"@sveltejs/package": "^1.0.0-next.4",
|
|
34
35
|
"uuid": "^8.3.2"
|
|
35
36
|
},
|
|
36
37
|
"jest": {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let value = 0, total = 100, height = '5px', width = '100%', radius = '2px', backgroundColor = undefined, color = undefined;
|
|
2
2
|
$: hundredBasedProgress = total === 0 ? 100 : value * 100 / total;
|
|
3
3
|
$: cssVariables = Object.entries({
|
|
4
4
|
'--progress-width': hundredBasedProgress + '%',
|
package/shop/ProductCard.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let image = '', title = '', sale = false, saleText = 'SALE', price = undefined, currency = '€', discount = undefined, maxWidth = undefined, maxHeight = undefined, minWidth = undefined, minHeight = undefined, width = undefined, height = undefined;
|
|
2
2
|
$: priceLessDiscount = Number((price - discount).toFixed(2));
|
|
3
3
|
import Image from '../media/Image.svelte';
|
|
4
4
|
</script>
|
package/shop/ProductsGrid.svelte
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script>export let products = [], productMaxWidth = '90vw', productMinWidth = '200px', productMaxHeight = '90vh', productMinHeight = '300px', productHeight = '300px', productWidth = '200px', width = '100%', gap = '1rem';
|
|
2
2
|
import ProductCard from './ProductCard.svelte';
|
|
3
3
|
</script>
|
|
4
4
|
|
package/stores/mediaQuery.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
1441px and more — Extra large screens, TV
|
|
7
7
|
*/
|
|
8
8
|
import { readable } from "svelte/store";
|
|
9
|
-
import { browser } from "$app/
|
|
9
|
+
import { browser } from "$app/environment";
|
|
10
10
|
// 0px — 425px: Mobile devices
|
|
11
11
|
function handleMatchOnXsQuery(event) {
|
|
12
12
|
if (event.matches) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { onMount } from 'svelte';
|
|
4
4
|
export let value = undefined, periods = [], sideMenuVisible = true, width = "500px", maxWidth = "100vw", minWidth = "initial", height = "300px", maxHeight = "100vh", minHeight = "initial";
|
|
5
5
|
let visiblePeriodIndex = 0, oldTitle = undefined, newTitle = undefined, oldTitleTop = '0%', newTitleTop = '100%';
|
|
6
6
|
onMount(() => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<script context="module"
|
|
1
|
+
<script context="module"></script>
|
|
2
2
|
|
|
3
|
-
<script
|
|
3
|
+
<script>import { dateToString } from '../dates/utils';
|
|
4
4
|
export let items = [], singleSided = false, height = undefined, width = undefined, itemMarginTop = "15px", itemMarginBottom = "0px", firstItemMarginTop = "5px", lastItemMarginBottom = "5px", circleColor = "black", circleDiameter = "15px", timesWidth = undefined, circleAlignment = 'top';
|
|
5
5
|
$: cssVariables = Object.entries({
|
|
6
6
|
'-divider-width': '48px',
|