diff --git a/src/BootstrapBlazor.Server/BootstrapBlazor.Server.csproj b/src/BootstrapBlazor.Server/BootstrapBlazor.Server.csproj index aad0227c836..fb1d59c91ce 100644 --- a/src/BootstrapBlazor.Server/BootstrapBlazor.Server.csproj +++ b/src/BootstrapBlazor.Server/BootstrapBlazor.Server.csproj @@ -48,6 +48,7 @@ + diff --git a/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor b/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor new file mode 100644 index 00000000000..a30aadaf16f --- /dev/null +++ b/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor @@ -0,0 +1,27 @@ +@page "/oct-icon" +@layout MainLayout +@inject IStringLocalizer Localizer + + + + + +

@Localizer["OctIconTitle"]

+ +

@Localizer["OctIconDescription"]

+ + + + +
    +
  • @Localizer["P1"]
  • +
  • @Localizer["P2"]
  • +
+
@Localizer["P3"]
+
+ +
<link href="_content/BootstrapBlazor.OctIcon/BootstrapBlazor.OctIcon.bundle.scp.css" rel="stylesheet">
+ +
<OctIcon Name="accessibility-16"><OctIcon>
+ +
@((MarkupString)Localizer["Icons"].Value)
diff --git a/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor.cs b/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor.cs new file mode 100644 index 00000000000..4e232270f28 --- /dev/null +++ b/src/BootstrapBlazor.Server/Components/Samples/Icons/OctIcons.razor.cs @@ -0,0 +1,14 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the Apache 2.0 License +// See the LICENSE file in the project root for more information. +// Maintainer: Argo Zhang(argo@live.ca) Website: https://www.blazor.zone + +namespace BootstrapBlazor.Server.Components.Samples.Icons; + +/// +/// OctIcons 图标示例 +/// +public partial class OctIcons +{ + +} diff --git a/src/BootstrapBlazor.Server/Extensions/MenusLocalizerExtensions.cs b/src/BootstrapBlazor.Server/Extensions/MenusLocalizerExtensions.cs index cbfcbe4314a..dbe703c16ee 100644 --- a/src/BootstrapBlazor.Server/Extensions/MenusLocalizerExtensions.cs +++ b/src/BootstrapBlazor.Server/Extensions/MenusLocalizerExtensions.cs @@ -1568,6 +1568,12 @@ void AddIcons(DemoMenuItem item) { Text = Localizer["IconPark"], Url = "icon-park" + }, + new() + { + IsNew = true, + Text = Localizer["OctIcon"], + Url = "oct-icon" } }; AddBadge(item); diff --git a/src/BootstrapBlazor.Server/Locales/en-US.json b/src/BootstrapBlazor.Server/Locales/en-US.json index 273ad4ea5fd..10a17becbf1 100644 --- a/src/BootstrapBlazor.Server/Locales/en-US.json +++ b/src/BootstrapBlazor.Server/Locales/en-US.json @@ -4806,7 +4806,8 @@ "RDKit": "RDKit", "SmilesDrawer": "SmilesDrawer", "Affix": "Affix", - "Watermark": "Watermark" + "Watermark": "Watermark", + "OctIcon": "OctIcons" }, "BootstrapBlazor.Server.Components.Samples.Table.TablesHeader": { "TablesHeaderTitle": "Header grouping function", @@ -6719,6 +6720,15 @@ "P3": "Please copy the following code segement", "Icons": "For icon list, please visit [portal]" }, + "BootstrapBlazor.Server.Components.Samples.Icons.OctIcons": { + "OctIconTitle": "Oct Svg Icon Lib", + "OctIconDescription": "A scalable set of icons handcrafted with <3 by GitHub", + "CopiedTooltipText": "Copied", + "P1": "1. After referencing the extension package, add the package built-in style file to open the icon", + "P2": "2. Enable css isolation and automatically reference component styles after compilation", + "P3": "Please copy the following code segement", + "Icons": "For icon list, please visit [portal]" + }, "BootstrapBlazor.Server.Components.Samples.BootstrapBlazorIcons": { "IconsTitle": "Icon", "IconsDescription": "Supports font icons, vector SVG icons, and Image pictures", diff --git a/src/BootstrapBlazor.Server/Locales/zh-CN.json b/src/BootstrapBlazor.Server/Locales/zh-CN.json index 71d3e89e6a3..c7bb88fe88a 100644 --- a/src/BootstrapBlazor.Server/Locales/zh-CN.json +++ b/src/BootstrapBlazor.Server/Locales/zh-CN.json @@ -4806,7 +4806,8 @@ "RDKit": "分子式组件 RDKit", "SmilesDrawer": "分子式组件 SmilesDrawer", "Affix": "固钉组件 Affix", - "Watermark": "水印组件 Watermark" + "Watermark": "水印组件 Watermark", + "OctIcon": "OctIcons" }, "BootstrapBlazor.Server.Components.Samples.Table.TablesHeader": { "TablesHeaderTitle": "表头分组功能", @@ -6719,6 +6720,15 @@ "P3": "请拷贝下方样式即可", "Icons": "图标列表请通过 [传送门] 查看" }, + "BootstrapBlazor.Server.Components.Samples.Icons.OctIcons": { + "OctIconTitle": "Github 图标库", + "OctIconDescription": "Primer is a set of guidelines, principles, and patterns for designing and building UI at GitHub.", + "CopiedTooltipText": "拷贝成功", + "P1": "1. 引用扩展组件包后添加包内置样式文件开启图标", + "P2": "2. 开启样式隔离,编译后自动引用组件样式", + "P3": "请拷贝下方样式即可", + "Icons": "图标列表请通过 [传送门] 查看" + }, "BootstrapBlazor.Server.Components.Samples.BootstrapBlazorIcons": { "IconsTitle": "Icon 图标", "IconsDescription": "同时支持字体图标、矢量 Svg 图标、以及 Image 图片",