-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
8 changed files
with
56 additions
and
50 deletions.
There are no files selected for viewing
31 changes: 10 additions & 21 deletions
31
...nts.Web.Bootstrap.Documentation/Pages/Components/HxModalDoc/HxModal_Demo_Scrollable.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,29 +1,18 @@ | ||
<HxButton OnClick="HandleShowClick" Color="ThemeColor.Primary">Launch demo modal - Scrollable</HxButton> | ||
<HxButton OnClick="() => myModal.ShowAsync()" Color="ThemeColor.Primary">Launch demo modal - Scrollable</HxButton> | ||
|
||
<HxModal @ref="myModal" HeaderText="Modal title" Scrollable="true"> | ||
<BodyTemplate> | ||
<p style="margin-bottom: 100vh;"> | ||
This is some placeholder content to show the scrolling behavior for modals. Instead of repeating the text the modal, we use an inline style set a minimum height, thereby extending the length of the overall modal and demonstrating the overflow scrolling. When content becomes longer than the height of the viewport, scrolling will move the modal as needed. | ||
</p> | ||
<BodyTemplate> | ||
<p style="margin-bottom: 100vh;"> | ||
This is some placeholder content to show the scrolling behavior for modals. Instead of repeating the text the modal, we use an inline style set a minimum height, thereby extending the length of the overall modal and demonstrating the overflow scrolling. When content becomes longer than the height of the viewport, scrolling will move the modal as needed. | ||
</p> | ||
<p>This content should appear at the bottom after you scroll.</p> | ||
</BodyTemplate> | ||
<FooterTemplate> | ||
<HxButton Skin="ButtonSkins.Close" OnClick="HandleHideClick" Color="ThemeColor.Primary" /> | ||
</FooterTemplate> | ||
</BodyTemplate> | ||
<FooterTemplate> | ||
<HxButton OnClick="() => myModal.ShowAsync()" Color="ThemeColor.Primary">Launch demo modal - default scrolling</HxButton> | ||
</FooterTemplate> | ||
</HxModal> | ||
|
||
@code | ||
{ | ||
private HxModal myModal; | ||
|
||
private async Task HandleShowClick() | ||
{ | ||
await myModal.ShowAsync(); | ||
} | ||
|
||
private async Task HandleHideClick() | ||
{ | ||
await myModal.HideAsync(); | ||
} | ||
|
||
private HxModal myModal; | ||
} |
31 changes: 10 additions & 21 deletions
31
...Bootstrap.Documentation/Pages/Components/HxModalDoc/HxModal_Demo_VerticallyCentered.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,26 +1,15 @@ | ||
<HxButton OnClick="HandleShowClick" Color="ThemeColor.Primary">Show modal</HxButton> | ||
|
||
<HxModal @ref="myModal" HeaderText="Modal title" CssClass="modal-dialog-centered" UseStaticBackdrop="false"> | ||
<BodyTemplate> | ||
This is a vertically centered modal. | ||
</BodyTemplate> | ||
<FooterTemplate> | ||
<HxButton Skin="ButtonSkins.Close" OnClick="HandleHideClick" Color="ThemeColor.Primary" /> | ||
</FooterTemplate> | ||
<HxButton OnClick="() => myModal.ShowAsync()" Color="ThemeColor.Primary">Vertically centered modal</HxButton> | ||
|
||
<HxModal @ref="myModal" HeaderText="Modal title" Centered="true"> | ||
<BodyTemplate> | ||
This is a vertically centered modal. | ||
</BodyTemplate> | ||
<FooterTemplate> | ||
<HxButton Skin="ButtonSkins.Close" OnClick="() => myModal.HideAsync()" Color="ThemeColor.Primary" /> | ||
</FooterTemplate> | ||
</HxModal> | ||
|
||
@code | ||
{ | ||
private HxModal myModal; | ||
|
||
private async Task HandleShowClick() | ||
{ | ||
await myModal.ShowAsync(); | ||
} | ||
|
||
private async Task HandleHideClick() | ||
{ | ||
await myModal.HideAsync(); | ||
} | ||
|
||
private HxModal myModal; | ||
} |
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
10 changes: 10 additions & 0 deletions
10
....Components.Web.Bootstrap.Documentation/wwwroot/Havit.Blazor.Components.Web.Bootstrap.xml
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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