Bladeren bron

[stdf]Format some files

dufu1991 1 jaar geleden
bovenliggende
commit
83d410cdcf

+ 2 - 2
packages/stdf/components/checkbox/Checkbox.svelte

@@ -94,8 +94,8 @@
 		textPosition === 'b' || textPosition === 't'
 			? 'flex-col items-center'
 			: $STDF_checkboxLayoutStore === 'h'
-			? 'justify-center'
-			: 'items-center'
+				? 'justify-center'
+				: 'items-center'
 	}`}
 	on:click={clickRadioFun}
 >

+ 2 - 2
packages/stdf/components/picker/Picker.svelte

@@ -326,8 +326,8 @@
 								? currentLevelData[0][linkageChildrenKey]
 								: []
 							: currentLevelData[index]
-							? currentLevelData[index][linkageChildrenKey]
-							: [];
+								? currentLevelData[index][linkageChildrenKey]
+								: [];
 					if (nextLevelData.length > 0) {
 						const nextData = nextLevelData.map(item =>
 							linkageLabelKeys[col + 1] ? { label: item[linkageLabelKeys[col + 1]] } : { label: item.label },

+ 3 - 3
packages/stdf/components/rate/Rate.svelte

@@ -252,10 +252,10 @@
 						? ' scale-75'
 						: ''
 					: animation === 'current'
-					? clickIndex === index && isScale
-						? ' scale-75'
+						? clickIndex === index && isScale
+							? ' scale-75'
+							: ''
 						: ''
-					: ''
 			}`}
 			style="height:{height}px;width:{width}px;"
 			on:click={() => clickFun(index)}

+ 2 - 2
packages/stdf/components/scrollRadio/ScrollRadio.svelte

@@ -65,8 +65,8 @@
 		showRowsInner === 3
 			? [...[emptyObj], ...data, ...[emptyObj]]
 			: showRowsInner === 5
-			? [...[emptyObj, emptyObj], ...data, ...[emptyObj, emptyObj]]
-			: [...[emptyObj, emptyObj, emptyObj], ...data, ...[emptyObj, emptyObj, emptyObj]];
+				? [...[emptyObj, emptyObj], ...data, ...[emptyObj, emptyObj]]
+				: [...[emptyObj, emptyObj, emptyObj], ...data, ...[emptyObj, emptyObj, emptyObj]];
 
 	// 滚动元素
 	// Scroll element

+ 4 - 4
packages/stdf/components/stepper/Stepper.svelte

@@ -178,8 +178,8 @@
 			'rounded'} flex flex-col items-center {injClassBtn} justify-center{numberHighlight
 			? ''
 			: theme
-			? ' bg-primary/5 dark:bg-dark/10'
-			: ' bg-white dark:bg-black'}"
+				? ' bg-primary/5 dark:bg-dark/10'
+				: ' bg-white dark:bg-black'}"
 		disabled={async || value === min}
 		aria-label="decrease"
 	>
@@ -210,8 +210,8 @@
 			'rounded'} flex flex-col items-center {injClassBtn} justify-center{numberHighlight
 			? ''
 			: theme
-			? ' bg-primary/5 dark:bg-dark/10'
-			: ' bg-white dark:bg-black'}"
+				? ' bg-primary/5 dark:bg-dark/10'
+				: ' bg-white dark:bg-black'}"
 		aria-label="increase"
 		disabled={async || value === max}
 	>

+ 14 - 14
packages/stdf/components/steps/Steps.svelte

@@ -81,8 +81,8 @@
 								i < current - 1
 									? 'border-primary dark:border-dark text-primary dark:text-dark'
 									: i === current - 1
-									? 'border-primary dark:border-dark bg-primary dark:bg-dark text-white dark:text-black'
-									: 'border-black/30 dark:border-white/30 text-black/30 dark:text-white/30'
+										? 'border-primary dark:border-dark bg-primary dark:bg-dark text-white dark:text-black'
+										: 'border-black/30 dark:border-white/30 text-black/30 dark:text-white/30'
 							} ${radiusObj[radius] || radiusObj.base} ${!barBorder ? '!border-transparent' : ''}`}
 							style="top:12px"
 						>
@@ -119,8 +119,8 @@
 								i < current - 1
 									? 'border-primary dark:border-dark'
 									: i === current - 1
-									? 'border-primary dark:border-dark bg-primary dark:bg-dark'
-									: 'border-black/30 dark:border-white/30'
+										? 'border-primary dark:border-dark bg-primary dark:bg-dark'
+										: 'border-black/30 dark:border-white/30'
 							} ${radiusObj[radius] || radiusObj.base}`}
 							style="top:16px"
 						/>
@@ -132,8 +132,8 @@
 							i < current - 1
 								? 'text-black dark:text-white'
 								: i === current - 1
-								? 'text-primary dark:text-dark'
-								: 'text-black/30 dark:text-white/30'
+									? 'text-primary dark:text-dark'
+									: 'text-black/30 dark:text-white/30'
 						}`}
 					>
 						{item.finishStep && i < current - 1 ? item.finishStep.title : item.step.title}
@@ -145,8 +145,8 @@
 									? item.finishStep.desc
 									: ''
 								: item.step.desc
-								? item.step.desc
-								: ''}
+									? item.step.desc
+									: ''}
 						</div>
 					{/if}
 					{#if item.step?.injComponent || item.finishStep?.injComponent}
@@ -171,8 +171,8 @@
 								i < current - 1
 									? 'border-primary dark:border-dark text-primary dark:text-dark'
 									: i === current - 1
-									? 'border-primary dark:border-dark bg-primary dark:bg-dark text-white dark:text-black'
-									: 'border-black/30 dark:border-white/30 text-black/30 dark:text-white/30'
+										? 'border-primary dark:border-dark bg-primary dark:bg-dark text-white dark:text-black'
+										: 'border-black/30 dark:border-white/30 text-black/30 dark:text-white/30'
 							} ${radiusObj[radius] || radiusObj.base} ${!barBorder ? '!border-transparent' : ''}`}
 							style="left:calc(50% - 15px)"
 						>
@@ -209,8 +209,8 @@
 								i < current - 1
 									? 'border-primary dark:border-dark'
 									: i === current - 1
-									? 'border-primary dark:border-dark bg-primary dark:bg-dark'
-									: 'border-black/30 dark:border-white/30'
+										? 'border-primary dark:border-dark bg-primary dark:bg-dark'
+										: 'border-black/30 dark:border-white/30'
 							} ${radiusObj[radius] || radiusObj.base}`}
 							style="left:calc(50% - 5px)"
 						/>
@@ -221,8 +221,8 @@
 						i < current - 1
 							? 'text-black dark:text-white'
 							: i === current - 1
-							? 'text-primary dark:text-dark'
-							: 'text-black/30 dark:text-white/30'
+								? 'text-primary dark:text-dark'
+								: 'text-black/30 dark:text-white/30'
 					}`}
 				>
 					{item.finishStep && i < current - 1 ? item.finishStep.title : item.step.title}

+ 2 - 2
packages/stdf/components/swiper/Swiper.svelte

@@ -275,8 +275,8 @@
 		data.length > 1
 			? [data[data.length - 1], ...data, data[0], data[1]]
 			: data.length === 1
-			? [data[data.length - 1], ...data, data[0]]
-			: data; //实现无限轮播,复制一个新数组,防止改变原数组 implement infinite loop, copy a new array to prevent change original array
+				? [data[data.length - 1], ...data, data[0]]
+				: data; //实现无限轮播,复制一个新数组,防止改变原数组 implement infinite loop, copy a new array to prevent change original array
 	const indicateAlignObj = { left: 'justify-start', center: 'justify-center', right: 'justify-end' };
 	const pxObj = { '0': '', '1': 'px-1', '2': 'px-2', '4': 'px-4', '6': 'px-6', '8': 'px-8', '12': 'px-12', '16': 'px-16', '24': 'px-24' };
 	const pyObj = { '0': '', '1': 'py-1', '2': 'py-2', '4': 'py-4', '6': 'py-6', '8': 'py-8', '12': 'py-12' };