Skip to content

Commit

Permalink
docs: add Loading & CircleProgressBar & Stepper
Browse files Browse the repository at this point in the history
  • Loading branch information
AuroraZiling committed Aug 11, 2024
1 parent 90be40d commit b434e4a
Show file tree
Hide file tree
Showing 11 changed files with 142 additions and 2 deletions.
26 changes: 26 additions & 0 deletions docs/docs/documentation/controls/progress/circleprogressbar.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# CircleProgressBar

Circle Progress Bar

## Show

<img src="/controls/progress/circleprogressbar.gif" height="300px" width="200px"/>

## Example

```xml
<suki:CircleProgressBar IsIndeterminate="{Binding IsIndeterminate}"
StrokeWidth="11"
Value="{Binding ProgressValue}">
<TextBlock Margin="0,2,0,0" // Show percentage
Classes="h3"
IsVisible="{Binding IsTextVisible}"
Text="{Binding ProgressValue, StringFormat={}{0:#0}%}" />
</suki:CircleProgressBar>
```

## See Also

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/CircleProgressBar.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/CircleProgressBar.axaml.cs)
19 changes: 19 additions & 0 deletions docs/docs/documentation/controls/progress/loading.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Loading

Loading Indicator

## Show

<img src="/controls/progress/loading.gif" height="300px" width="200px"/>

## Example

```xml
<suki:Loading />
```

## See Also

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/Loading.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/Loading.axaml.cs)
2 changes: 1 addition & 1 deletion docs/docs/documentation/controls/progress/progressbar.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Progress Bar

## Show

<img src="/controls/progress/progressbar.gif" height="300px" width="300px"/>
<img src="/controls/progress/progressbar.gif" height="300px" width="400px"/>

## Example

Expand Down
25 changes: 25 additions & 0 deletions docs/docs/documentation/controls/progress/stepper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Stepper

A bar that guides users through the steps of a task

## Show

<img src="/controls/progress/stepper.gif" height="300px" width="300px"/>

## Example

```xml .axaml
<suki:Stepper Index="{Binding StepIndex}" Steps="{Binding Steps}" />
```

```csharp
[ObservableProperty] private int _stepIndex = 1;
public IEnumerable<string> Steps { get; } =
["First Step", "Second Step", "Third Step"];
```

## See Also

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/Stepper.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/Stepper.axaml.cs)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/docs/public/controls/progress/loading.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/docs/public/controls/progress/stepper.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 26 additions & 0 deletions docs/docs/zh/documentation/controls/progress/circleprogressbar.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# CircleProgressBar

圆形进度条

## 展示

<img src="/controls/progress/circleprogressbar.gif" height="300px" width="200px"/>

## 示例

```xml
<suki:CircleProgressBar IsIndeterminate="{Binding IsIndeterminate}"
StrokeWidth="11"
Value="{Binding ProgressValue}">
<TextBlock Margin="0,2,0,0" // 百分比显示
Classes="h3"
IsVisible="{Binding IsTextVisible}"
Text="{Binding ProgressValue, StringFormat={}{0:#0}%}" />
</suki:CircleProgressBar>
```

## 参阅

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/CircleProgressBar.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/CircleProgressBar.axaml.cs)
19 changes: 19 additions & 0 deletions docs/docs/zh/documentation/controls/progress/loading.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Loading

加载控件

## 展示

<img src="/controls/progress/loading.gif" height="300px" width="200px"/>

## 示例

```xml
<suki:Loading />
```

## 参阅

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/Loading.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/Loading.axaml.cs)
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## 展示

<img src="/controls/progress/progressbar.gif" height="300px" width="300px"/>
<img src="/controls/progress/progressbar.gif" height="300px" width="400px"/>

## 示例

Expand Down
25 changes: 25 additions & 0 deletions docs/docs/zh/documentation/controls/progress/stepper.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Stepper

指引用户分步骤完成一项任务的控件

## 展示

<img src="/controls/progress/stepper.gif" height="300px" width="300px"/>

## 示例

```xml .axaml
<suki:Stepper Index="{Binding StepIndex}" Steps="{Binding Steps}" />
```

```csharp
[ObservableProperty] private int _stepIndex = 1;
public IEnumerable<string> Steps { get; } =
["First Step", "Second Step", "Third Step"];
```

## 参阅

[Demo: SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI.Demo/Features/ControlsLibrary/ProgressView.axaml)

[API: Controls/Stepper.axaml.cs](https://github.com/kikipoulet/SukiUI/blob/main/SukiUI/Controls/Stepper.axaml.cs)

0 comments on commit b434e4a

Please sign in to comment.