Forráskód Böngészése

[demo]Update for stdf@0.5.1

dufu1991 1 éve
szülő
commit
36291f6fdb

+ 34 - 1
demo/src/routes/en_US/button/+page.svelte

@@ -82,7 +82,7 @@
 		<Button disabled>Disable</Button>
 		<Button fill="lineTheme" disabled>Disable</Button>
 	</div>
-	<div>
+	<!-- <div>
 		<div class="p-4 font-bold">Load</div>
 		<Button>
 			<Loading inverse height="6" width="6" />
@@ -101,6 +101,39 @@
 			<Icon name="ri-mic-off-fill" size={16} top={-2} />
 			Start the surface wall plan
 		</Button>
+	</div> -->
+	<div>
+		<div class="p-4 font-bold">With icon</div>
+		<Button iconLoading={{ type: 'icon', params: { name: 'ri-share-forward-2-fill', size: 18, top: -2 } }}>Throw the two way foil</Button>
+		<Button fill="lineTheme" iconLoading={{ type: 'icon', params: { name: 'ri-mic-off-fill', size: 16, top: -2 } }}
+			>Start the surface wall plan</Button
+		>
+	</div>
+	<div>
+		<div class="p-4 font-bold">Load (disabled by default)</div>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, height: '6', width: '6' } }}>Loading</Button>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, width: '16', height: '6', type: '1_17' } }}>Loading</Button>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, height: '6', width: '6' } }} disabledLoading={false}>Loading</Button>
+	</div>
+	<div>
+		<div class="p-4 font-bold">With icon (passed through slots)</div>
+		<Button>
+			<Icon name="ri-share-forward-2-fill" size={18} top={-2} />
+			Throw the two way foil
+		</Button>
+		<Button fill="lineTheme">
+			<Icon name="ri-mic-off-fill" size={16} top={-2} />
+			Start the surface wall plan
+		</Button>
+	</div>
+	<div>
+		<div class="p-4 font-bold">Load (passed through slots)</div>
+		<Button>
+			<Loading inverse height="6" width="6" />
+		</Button>
+		<Button>
+			<Loading inverse width="16" height="6" type="1_17" />
+		</Button>
 	</div>
 	<div>
 		<div class="p-4 font-bold">Love version</div>

+ 19 - 8
demo/src/routes/zh_CN/button/+page.svelte

@@ -83,16 +83,18 @@
 		<Button fill="lineTheme" disabled>禁用</Button>
 	</div>
 	<div>
-		<div class="p-4 font-bold">加载</div>
-		<Button>
-			<Loading inverse height="6" width="6" />
-		</Button>
-		<Button>
-			<Loading inverse width="16" height="6" type="1_17" />
-		</Button>
+		<div class="p-4 font-bold">带图标</div>
+		<Button iconLoading={{ type: 'icon', params: { name: 'ri-share-forward-2-fill', size: 18, top: -2 } }}>投掷二向箔</Button>
+		<Button fill="lineTheme" iconLoading={{ type: 'icon', params: { name: 'ri-mic-off-fill', size: 16, top: -2 } }}>启动面壁计划</Button>
 	</div>
 	<div>
-		<div class="p-4 font-bold">带图标</div>
+		<div class="p-4 font-bold">带加载(默认禁用)</div>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, height: '6', width: '6' } }}>加载中</Button>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, width: '16', height: '6', type: '1_17' } }}>加载中</Button>
+		<Button iconLoading={{ type: 'loading', params: { inverse: true, height: '6', width: '6' } }} disabledLoading={false}>加载中</Button>
+	</div>
+	<div>
+		<div class="p-4 font-bold">带图标(通过插槽传入)</div>
 		<Button>
 			<Icon name="ri-share-forward-2-fill" size={18} top={-2} />
 			投掷二向箔
@@ -102,6 +104,15 @@
 			启动面壁计划
 		</Button>
 	</div>
+	<div>
+		<div class="p-4 font-bold">加载(通过插槽传入)</div>
+		<Button>
+			<Loading inverse height="6" width="6" />
+		</Button>
+		<Button>
+			<Loading inverse width="16" height="6" type="1_17" />
+		</Button>
+	</div>
 	<div>
 		<div class="p-4 font-bold">关爱版</div>
 		<Button love>关爱版按钮</Button>