Steps
タスクのステップを通じてユーザーを案内するナビゲーションバー。
いつ使うか
- 与えられたタスクが複雑であるか、一連のサブタスクに特定の順序がある場合、物事を簡単にするためにいくつかのステップに分解できます。
使用例
完了 これは説明です。
進行中 これは説明です。
待機中 これは説明です。
astro
---
import Steps from '@/components/navigation/Steps.astro';
import Step from '@/components/navigation/Step.astro';
---
<Steps current={1}>
<Step title="Finished" description="This is a description." />
<Step title="In Progress" description="This is a description." />
<Step title="Waiting" description="This is a description." />
</Steps> 垂直方向
ステップは、`orientation="vertical"`プロパティを使用して垂直方向にレンダリングすることもできます。
完了 これは説明です。
進行中 これは説明です。
待機中 これは説明です。
astro
<Steps current={1} orientation="vertical">
<Step title="Finished" description="This is a description." />
<Step title="In Progress" description="This is a description." />
<Step title="Waiting" description="This is a description." />
</Steps> API Reference
Steps
| プロパティ | 説明 | タイプ | デフォルト |
|---|---|---|---|
| current | The current step, starting from 0. | number | 0 |
| orientation | The orientation of the steps layout. | 'horizontal' | 'vertical' | 'horizontal' |
| class | Additional CSS classes to apply to the Steps container. | string | - |
Step
| プロパティ | 説明 | タイプ | デフォルト |
|---|---|---|---|
| title | The main title of the step. | string | - |
| description | Additional detailed description of the step. | string | - |
| status | Explicit status of the step. Normally inferred from the `current` prop on the parent `<Steps>`. | 'wait' | 'process' | 'finish' | 'error' | - |
| class | Additional CSS classes for custom styling. | string | - |