-
Notifications
You must be signed in to change notification settings - Fork 391
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
84 additions
and
47 deletions.
There are no files selected for viewing
27 changes: 5 additions & 22 deletions
27
...FluentUI.Demo.Client/Documentation/Components/Checkbox/Examples/CheckboxAppearances.razor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,6 @@ | ||
|
||
|
||
<div style="display: flex; gap: 12px; margin-bottom: 24px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square checked" @bind-Checked="@CheckedValue" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular checked" @bind-Checked="@CheckedValue" /> | ||
<div style="display: flex;flex-direction: column; gap: 12px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square checked" Checked="true" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular checked" Checked="true" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square unchecked" Checked="false" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular unchecked" Checked="false" /> | ||
</div> | ||
|
||
<div style="display: flex; gap: 12px; margin-bottom: 24px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square unchecked" @bind-Checked="@UncheckedValue" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular unchecked" @bind-Checked="@UncheckedValue" /> | ||
</div> | ||
|
||
<div style="display: flex; gap: 12px; margin-bottom: 24px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square indeterminate" @bind-Indeterminate="@IndeterminateValue" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular indeterminate" @bind-Indeterminate="@IndeterminateValue" /> | ||
</div> | ||
|
||
@code | ||
{ | ||
bool CheckedValue = true; | ||
bool UncheckedValue = false; | ||
bool IndeterminateValue = true; | ||
} |
7 changes: 7 additions & 0 deletions
7
...mo/FluentUI.Demo.Client/Documentation/Components/Checkbox/Examples/CheckboxDisabled.razor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<div style="display: flex;flex-direction: column; gap: 12px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square disabled checked" Disabled="true" Checked="true" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular disabled checked" Disabled="true" Checked="true" /> | ||
|
||
<FluentCheckbox Shape="@CheckboxShape.Square" Label="Square disabled unchecked" Disabled="true" Checked="false" /> | ||
<FluentCheckbox Shape="@CheckboxShape.Circular" Label="Circular disabled unchecked" Disabled="true" Checked="false" /> | ||
</div> |
31 changes: 31 additions & 0 deletions
31
...mo/FluentUI.Demo.Client/Documentation/Components/Checkbox/Examples/CheckboxRequired.razor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
|
||
<h2>With required validation</h2> | ||
<EditForm Model="new object()"> | ||
<div style="display: flex;flex-direction: column; gap: 12px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" | ||
Label="Square required" | ||
Required="true" /> | ||
|
||
<FluentCheckbox Shape="@CheckboxShape.Circular" | ||
Label="Circular required" | ||
Required="true" /> | ||
|
||
<FluentButton Type="ButtonType.Submit">Submit</FluentButton> | ||
</div> | ||
</EditForm> | ||
<h2>With defined required validation text</h2> | ||
<EditForm Model="new object()"> | ||
<div style="display: flex;flex-direction: column; gap: 12px;"> | ||
<FluentCheckbox Shape="@CheckboxShape.Square" | ||
Label="Square required with defined required validation text" | ||
RequiredLabel="This filed is required" | ||
Required="true" /> | ||
|
||
<FluentCheckbox Shape="@CheckboxShape.Circular" | ||
Label="Circular required with defined required validation text" | ||
RequiredLabel="This filed is required" | ||
Required="true" /> | ||
|
||
<FluentButton Type="ButtonType.Submit">Submit</FluentButton> | ||
</div> | ||
</EditForm> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters