|
9 | 9 | <DemoBlock Title="@Localizer["TextAreaNormalTitle"]" |
10 | 10 | Introduction="@Localizer["TextAreaNormalIntro"]" |
11 | 11 | Name="Normal"> |
12 | | - <label class="form-label mb-3">@Localizer["TextAreaLabel"]</label> |
13 | 12 | <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" /> |
14 | 13 | </DemoBlock> |
15 | 14 |
|
16 | 15 | <DemoBlock Title="@Localizer["TextAreaDisableTitle"]" |
17 | 16 | Introduction="@Localizer["TextAreaDisableIntro"]" |
18 | 17 | Name="IsDisabled"> |
19 | | - <label class="form-label mb-3">@Localizer["TextAreaLabel"]</label> |
20 | 18 | <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" IsDisabled="true" /> |
21 | 19 | </DemoBlock> |
22 | 20 |
|
23 | 21 | <DemoBlock Title="@Localizer["TextAreaReadOnlyTitle"]" |
24 | 22 | Introduction="@Localizer["TextAreaReadOnlyIntro"]" |
25 | 23 | Name="ReadOnly"> |
26 | | - <label class="form-label mb-3">@Localizer["TextAreaLabel"]</label> |
27 | | -<Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" readonly /> |
| 24 | + <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" readonly /> |
28 | 25 | </DemoBlock> |
29 | 26 |
|
30 | 27 | <DemoBlock Title="@Localizer["TextAreaHeightTitle"]" |
31 | 28 | Introduction="@Localizer["TextAreaHeightIntro"]" |
32 | 29 | Name="Rows"> |
33 | | - <label class="form-label mb-3">@Localizer["TextAreaLabel"]</label> |
34 | | - |
35 | | -<Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" /> |
| 30 | + <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" /> |
36 | 31 | </DemoBlock> |
37 | 32 |
|
38 | 33 | <DemoBlock Title="@Localizer["TextAreaBindWayTitle"]" |
39 | 34 | Introduction="@Localizer["TextAreaBindWayIntro"]" |
40 | 35 | Name="BindValue"> |
41 | | - <div class="row g-3"> |
42 | | - <div class="col-12"> |
43 | | - <label class="form-label">@Localizer["TextAreaLabel"]</label> |
44 | | - <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" @bind-Value="@Text"></Textarea> |
45 | | - </div> |
| 36 | + <Textarea PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="4" @bind-Value="@Text"></Textarea> |
| 37 | + <section ignore class="row g-3"> |
46 | 38 | <div class="col-12"> |
47 | 39 | <label class="form-label">@Localizer["TextAreaBindWayBindValue"]</label> |
48 | 40 | <div class="form-control textarea-demo">@Text</div> |
49 | 41 | </div> |
50 | | - </div> |
| 42 | + </section> |
51 | 43 | </DemoBlock> |
52 | 44 |
|
53 | 45 | <DemoBlock Title="@Localizer["TextAreaScrollTitle"]" |
54 | 46 | Introduction="@Localizer["TextAreaScrollIntro"]" |
55 | 47 | Name="IsAutoScroll"> |
56 | 48 | <Textarea class="mb-3" PlaceHolder="@Localizer["TextAreaPlaceHolder"]" rows="10" @ref="TextareaElement" @bind-Value="@ChatText" IsAutoScroll="IsAutoScroll" /> |
| 49 | + <section ignore> |
| 50 | + <BootstrapInputGroup> |
| 51 | + <Button Text="@Localizer[ChatLocalizerName]" OnClick="MockChat" Icon="fa-fw fas fa-comments" /> |
| 52 | + <Button Text="@Localizer["TextAreaScrollToTop"]" OnClick="ScrollToTop" /> |
| 53 | + <Button Text="@Localizer["TextAreaScrollToBottom"]" OnClick="ScrollToBottom" /> |
| 54 | + <Button Text="@Localizer["TextAreaScrollTo"]" OnClick="ScrollTo20" /> |
| 55 | + <Button Text="@($"{Localizer["TextAreaAutoScroll"]}{(IsAutoScroll ? " On":" Off")}" )" OnClick="SwitchAutoScroll" /> |
| 56 | + </BootstrapInputGroup> |
| 57 | + </section> |
| 58 | +</DemoBlock> |
57 | 59 |
|
58 | | - <BootstrapInputGroup> |
59 | | - <Button Text="@Localizer[ChatLocalizerName]" OnClick="MockChat" Icon="fa-fw fas fa-comments" /> |
60 | | - <Button Text="@Localizer["TextAreaScrollToTop"]" OnClick="ScrollToTop" /> |
61 | | - <Button Text="@Localizer["TextAreaScrollToBottom"]" OnClick="ScrollToBottom" /> |
62 | | - <Button Text="@Localizer["TextAreaScrollTo"]" OnClick="ScrollTo20" /> |
63 | | - <Button Text="@($"{Localizer["TextAreaAutoScroll"]}{(IsAutoScroll ? " On":" Off")}" )" OnClick="SwitchAutoScroll" /> |
64 | | - </BootstrapInputGroup> |
| 60 | +<DemoBlock Title="@Localizer["TextAreaKeyUpTitle"]" |
| 61 | + Introduction="@Localizer["TextAreaKeyUpIntro"]" |
| 62 | + Name="KeyUp"> |
| 63 | + <Textarea rows="4" autocomplete="off" autocorrect="off" spellcheck="false" |
| 64 | + UseInputEvent="true" UseShiftEnter="true" PlaceHolder="@Localizer["TextAreaKeyUpPlaceHolder"]" |
| 65 | + @bind-Value="@KeyText"></Textarea> |
| 66 | + <section ignore> |
| 67 | + <ConsoleLogger @ref="Logger" IsHtml="true" /> |
| 68 | + </section> |
65 | 69 | </DemoBlock> |
66 | 70 |
|
67 | 71 | <AttributeTable Items="@GetAttributes()" /> |
0 commit comments