From 2ae708ec5f10b5444cae15121be7d0175c32b800 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 11:23:02 +0100 Subject: [PATCH 01/23] Add new template flag --- .../BlazorWeb-CSharp/.template.config/dotnetcli.host.json | 4 ++++ .../BlazorWeb-CSharp/.template.config/ide.host.json | 6 ++++++ .../.template.config/localize/templatestrings.cs.json | 2 ++ .../.template.config/localize/templatestrings.de.json | 2 ++ .../.template.config/localize/templatestrings.en.json | 2 ++ .../.template.config/localize/templatestrings.es.json | 2 ++ .../.template.config/localize/templatestrings.fr.json | 2 ++ .../.template.config/localize/templatestrings.it.json | 2 ++ .../.template.config/localize/templatestrings.ja.json | 2 ++ .../.template.config/localize/templatestrings.ko.json | 2 ++ .../.template.config/localize/templatestrings.pl.json | 2 ++ .../.template.config/localize/templatestrings.pt-BR.json | 2 ++ .../.template.config/localize/templatestrings.ru.json | 2 ++ .../.template.config/localize/templatestrings.tr.json | 2 ++ .../.template.config/localize/templatestrings.zh-Hans.json | 2 ++ .../.template.config/localize/templatestrings.zh-Hant.json | 2 ++ .../BlazorWeb-CSharp/.template.config/template.json | 7 +++++++ 17 files changed, 45 insertions(+) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json index f421cba00a17..8b01997181f7 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json @@ -17,6 +17,10 @@ "IncludeSampleContent": { "isHidden": true }, + "InteractiveAtRoot": { + "longName": "all-interactive", + "shortName": "int" + }, "Framework": { "longName": "framework" }, diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json index d6c7811ef21e..67aa231f0a1d 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json @@ -25,6 +25,12 @@ "isVisible": true, "persistenceScope": "shared", "persistenceScopeName": "Microsoft" + }, + { + "id": "InteractiveAtRoot", + "isVisible": true, + "persistenceScope": "shared", + "persistenceScopeName": "Microsoft" } ] } diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json index 143e28afd0ff..8203142a8910 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Zahrnout ukázkové stránky", "symbols/IncludeSampleContent/description": "Nastavuje, jestli se mají přidávat ukázkové stránky a styly pro demonstraci základních vzorů použití.", "symbols/Empty/description": "Nastavuje, jestli se mají vynechat ukázkové stránky a styly, které demonstrují základní vzory použití.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Určuje, jestli se má protokol HTTPS vypnout. Tato možnost platí jenom v případě, že se pro --auth nepoužívají Individual, IndividualB2C, SingleOrg ani MultiOrg.", "symbols/UseProgramMain/displayName": "Nepoužívat _příkazy nejvyšší úrovně", "symbols/UseProgramMain/description": "Určuje, jestli se má místo příkazů nejvyšší úrovně generovat explicitní třída Program a metoda Main.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json index f099955a9e1a..268e2b803474 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Include Beispielseiten", "symbols/IncludeSampleContent/description": "Konfiguriert, ob Beispielseiten und Stile hinzugefügt werden, um grundlegende Verwendungsmuster zu veranschaulichen.", "symbols/Empty/description": "Konfiguriert, ob Beispielseiten und Formatierungen weggelassen werden sollen, die grundlegende Verwendungsmuster veranschaulichen.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Ob HTTPS deaktiviert werden soll. Diese Option gilt nur, wenn Individual, IndividualB2C, SingleOrg oder MultiOrg nicht für --auth verwendet werden.", "symbols/UseProgramMain/displayName": "Keine Anweisungen_der obersten Ebene verwenden", "symbols/UseProgramMain/description": "Gibt an, ob anstelle von Anweisungen der obersten Ebene eine explizite Programmklasse und eine Main-Methode generiert werden soll.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json index 728e68ee72da..ed7cd6ce50ee 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Include sample pages", "symbols/IncludeSampleContent/description": "Configures whether to add sample pages and styling to demonstrate basic usage patterns.", "symbols/Empty/description": "Configures whether to omit sample pages and styling that demonstrate basic usage patterns.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Whether to turn off HTTPS. This option only applies if Individual, IndividualB2C, SingleOrg, or MultiOrg aren't used for --auth.", "symbols/UseProgramMain/displayName": "Do not use _top-level statements", "symbols/UseProgramMain/description": "Whether to generate an explicit Program class and Main method instead of top-level statements.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json index 336219064d4f..001ffaae46dc 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Incluir páginas de ejemplo", "symbols/IncludeSampleContent/description": "Configura si se van a agregar páginas de ejemplo y estilos para mostrar patrones de uso básicos.", "symbols/Empty/description": "Configura si se omiten las páginas de ejemplo y los estilos que muestran patrones de uso básicos.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Si se va a desactivar HTTPS. Esta opción solo se aplica si Individual, IndividualB2C, SingleOrg o MultiOrg no se usan para --auth.", "symbols/UseProgramMain/displayName": "No usar instrucciones de _nivel superior", "symbols/UseProgramMain/description": "Indica si se debe generar una clase Program explícita y un método Main en lugar de instrucciones de nivel superior.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json index bd2e54666951..2b00dfcaa9e0 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Inclure des exemples de pages", "symbols/IncludeSampleContent/description": "Configure s'il faut ajouter des exemples de pages et de style pour illustrer les modèles d'utilisation de base.", "symbols/Empty/description": "Configure s'il faut omettre les exemples de pages et le style qui illustrent les modèles d'utilisation de base.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Indique s’il faut désactiver HTTPS. Cette option s’applique uniquement si Individual, IndividualB2C, SingleOrg ou MultiOrg ne sont pas utilisés pour --auth.", "symbols/UseProgramMain/displayName": "N’utilisez pas _d’instructions de niveau supérieur.", "symbols/UseProgramMain/description": "Indique s’il faut générer une classe Programme explicite et une méthode Main au lieu d’instructions de niveau supérieur.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json index 82869d295cd4..6ea633231a09 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Include pagine di esempio", "symbols/IncludeSampleContent/description": "Consente di configurare se aggiungere pagine di esempio e stile per mostrare modelli di utilizzo di base.", "symbols/Empty/description": "Consente di configurare se omettere pagine di esempio e stile che mostrano modelli di utilizzo di base.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Indica se disattivare HTTPS. Questa opzione si applica solo se Individual, IndividualB2C, SingleOrg o MultiOrg non vengono usati per --auth.", "symbols/UseProgramMain/displayName": "Non usare_istruzioni di primo livello", "symbols/UseProgramMain/description": "Indica se generare una classe Program esplicita e un metodo Main anziché istruzioni di primo livello.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json index 32284bf324ad..5cd2468aaa8a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "サンプル ページを含める(_I)", "symbols/IncludeSampleContent/description": "基本的な使用パターンを示すサンプル ページとスタイルを追加するかどうかを構成します。", "symbols/Empty/description": "基本的な使用パターンを示すサンプル ページとスタイルを省略するかどうかを構成します。", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS をオフにするかどうか。このオプションは、Individual、IndividualB2C、SingleOrg、または MultiOrg が --auth に使用されていない場合にのみ適用されます。", "symbols/UseProgramMain/displayName": "最上位レベルのステートメントを使用しない(_T)", "symbols/UseProgramMain/description": "最上位レベルのステートメントではなく、明示的な Program クラスと Main メソッドを生成するかどうか。", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json index c52472a563b4..4b1c09bf07ac 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "샘플 페이지 포함(_I)", "symbols/IncludeSampleContent/description": "기본 사용 패턴을 보여주기 위해 샘플 페이지 및 스타일을 추가할지 여부를 구성합니다.", "symbols/Empty/description": "기본 사용 패턴을 보여주는 샘플 페이지 및 스타일을 생략할지 여부를 구성합니다.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS를 끌지 여부입니다. 이 옵션은 Individual, IndividualB2C, SingleOrg 또는 MultiOrg가 --auth에 사용되지 않는 경우에만 적용됩니다.", "symbols/UseProgramMain/displayName": "최상위 문 사용 안 함(_T)", "symbols/UseProgramMain/description": "최상위 문 대신 명시적 Program 클래스 및 Main 메서드를 생성할지 여부입니다.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json index 2a0221d2c07b..53e8ff71ddb1 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Dołącz przykładowe strony", "symbols/IncludeSampleContent/description": "Konfiguruje, czy dodać przykładowe strony i style w celu zademonstrowania podstawowych wzorców użycia.", "symbols/Empty/description": "Konfiguruje, czy pomijać przykładowe strony i style demonstrujące podstawowe wzorce użycia.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Określa, czy wyłączyć protokół HTTPS. Ta opcja ma zastosowanie tylko wtedy, gdy dla uwierzytelniania --auth nie są używane elementy Individual, IndividualB2C, SingleOrg lub MultiOrg.", "symbols/UseProgramMain/displayName": "Nie używaj ins_trukcji najwyższego poziomu", "symbols/UseProgramMain/description": "Określa, czy wygenerować jawną klasę Program i metodę Main zamiast instrukcji najwyższego poziomu.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json index 2bc9cd151495..74438cd13f1d 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Incluir páginas de amostra", "symbols/IncludeSampleContent/description": "Configura se deseja adicionar páginas de amostra e estilo para demonstrar padrões de uso básicos.", "symbols/Empty/description": "Configura a omissão de páginas de amostra e estilo que demonstram padrões básicos de uso.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Se o HTTPS deve ser desativado. Essa opção se aplica somente se Individual, IndividualB2C, SingleOrg ou MultiOrg não forem usados para --auth.", "symbols/UseProgramMain/displayName": "Não use ins_truções de nível superior", "symbols/UseProgramMain/description": "Se deve gerar uma classe de Programa explícita e um método principal em vez de instruções de nível superior.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json index e9d8da89ccfb..e92cac8c811a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "_Включить примеры страниц", "symbols/IncludeSampleContent/description": "Настраивает, следует ли добавлять примеры страниц и стили для демонстрации базовых шаблонов использования.", "symbols/Empty/description": "Настраивает, следует ли пропускать примеры страниц и стили, демонстрирующие базовые шаблоны использования.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Следует ли отключить HTTPS. Этот параметр применяется, только если для --auth не используются Individual, IndividualB2C, SingleOrg или MultiOrg.", "symbols/UseProgramMain/displayName": "Не использовать _операторы верхнего уровня", "symbols/UseProgramMain/description": "Следует ли создавать явный класс Program и метод Main вместо операторов верхнего уровня.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json index 1f39d5a08c4b..e7b635879781 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "Örnek _sayfalar ekle", "symbols/IncludeSampleContent/description": "Temel kullanım düzenlerini göstermek için örnek sayfaların ve stil oluşturma özelliklerinin eklenip eklenmeyeceğini yapılandırır.", "symbols/Empty/description": "Temel kullanım düzenlerini gösteren örnek sayfaların ve stil oluşturma özelliklerinin atlanıp atlanmayacağını yapılandırır.", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS'nin kapatılıp kapatılmayacağı. Bu seçenek yalnızca Bireysel, IndividualB2C, SingleOrg veya MultiOrg -- auth için kullanılmazsa geçerlidir.", "symbols/UseProgramMain/displayName": "_Üst düzey deyimler kullanmayın", "symbols/UseProgramMain/description": "Üst düzey deyimler yerine açık bir Program sınıfı ve Ana yöntem oluşturup oluşturulmayacağını belirtir.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json index 08cc567842ae..8f8a96289c35 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "包含示例页(_I)", "symbols/IncludeSampleContent/description": "配置是否添加示例页和样式以演示基本使用模式。", "symbols/Empty/description": "配置是否忽略演示基本使用模式的示例页和样式。", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "是否禁用 HTTPS。仅当 Individual、IndividualB2C、SingleOrg 或 MultiOrg 不用于 --auth 时,此选项才适用。", "symbols/UseProgramMain/displayName": "不使用顶级语句(_T)", "symbols/UseProgramMain/description": "是否生成显式程序类和主方法,而不是顶级语句。", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json index aa1cd6c62274..58099a9f8bd5 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json @@ -17,6 +17,8 @@ "symbols/IncludeSampleContent/displayName": "包含範例頁面(_I)", "symbols/IncludeSampleContent/description": "設定是否要新增範例頁面和樣式,以示範基本使用模式。", "symbols/Empty/description": "設定是否要省略範例頁面和樣式,其示範基本使用模式。", + "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "是否要關閉 HTTPS。只有當 Individual、IndividualB2C、SingleOrg 或 MultiOrg 未用於 --auth 時,才適用此選項。", "symbols/UseProgramMain/displayName": "不要使用最上層陳述式(_T)", "symbols/UseProgramMain/description": "是否要產生明確的 Program 類別和 Main 方法,而非最上層語句。", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index b01a54d41b72..b909ae0f1d7a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -249,6 +249,13 @@ "type": "computed", "value": "(((IncludeSampleContent && (HostIdentifier != \"dotnetcli\" && HostIdentifier != \"dotnetcli-preview\"))) || ((!Empty && (HostIdentifier == \"dotnetcli\" || HostIdentifier == \"dotnetcli-preview\"))))" }, + "InteractiveAtRoot": { + "type": "parameter", + "datatype": "bool", + "defaultValue": "false", + "displayName": "_Enable interactive rendering globally throughout the site", + "description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis." + }, "RequiresHttps": { "type": "computed", "value": "(OrganizationalAuth || IndividualAuth)" From 95872c18926268b5c7ce7bfd8c03f6a8d8eccbe3 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 11:25:44 +0100 Subject: [PATCH 02/23] Implement interactive-at-root for server only apps --- .../BlazorWeb-CSharp/Components/App.razor | 8 ++++++++ .../BlazorWeb-CSharp/Components/Pages/Counter.razor | 2 ++ .../BlazorWeb-CSharp/Components/Pages/Weather.razor | 6 ++++++ 3 files changed, 16 insertions(+) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor index d9d36a8fb2b9..27d52eaae2b8 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor @@ -13,11 +13,19 @@ @*#if (SampleContent) --> ##endif*@ + @*#if (InteractiveAtRoot) --> + + ##else + ##endif*@ + @*#if (InteractiveAtRoot) --> + + ##else + ##endif*@ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor index 8e77f9844411..f9bebaeab5ca 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor @@ -6,7 +6,9 @@ ##else +@*#if (!InteractiveAtRoot) --> @attribute [RenderModeServer] +##endif*@ Counter diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor index 12a9986a8359..efdb38a377ff 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor @@ -1,5 +1,7 @@ @page "/weather" +@*#if (!InteractiveAtRoot) --> @attribute [StreamRendering(true)] +##endif*@ Weather @@ -41,7 +43,11 @@ else protected override async Task OnInitializedAsync() { +@*#if (InteractiveAtRoot) --> + // Simulate asynchronous loading to demonstrate a loading indicator +##else // Simulate asynchronous loading to demonstrate streaming rendering +##endif*@ await Task.Delay(500); var startDate = DateOnly.FromDateTime(DateTime.Now); From 5ad663442bd11ab2eade791c6037df356e5e3301 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 11:28:38 +0100 Subject: [PATCH 03/23] Fix h1 focus for empty apps --- .../BlazorWeb-CSharp/BlazorWeb-CSharp/wwwroot/app.css | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/wwwroot/app.css b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/wwwroot/app.css index 6e447a78f503..6aa275650f20 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/wwwroot/app.css +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/wwwroot/app.css @@ -3,10 +3,6 @@ html, body { font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; } -h1:focus { - outline: none; -} - a, .btn-link { color: #0071c1; } @@ -26,6 +22,10 @@ a, .btn-link { } /*#endif*/ +h1:focus { + outline: none; +} + .valid.modified:not([type=checkbox]) { outline: 1px solid #26b050; } From 538ca675b71601c9e4853344951afe0c0a4d141b Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 11:45:06 +0100 Subject: [PATCH 04/23] Make the new flag enabled only when an interactive mode is specified --- .../content/BlazorWeb-CSharp/.template.config/template.json | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index b909ae0f1d7a..e81e8a87db02 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -252,6 +252,7 @@ "InteractiveAtRoot": { "type": "parameter", "datatype": "bool", + "isEnabled": "(UseServer || UseWebAssembly)", "defaultValue": "false", "displayName": "_Enable interactive rendering globally throughout the site", "description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis." From 87f36539c6bc846280a62b9082f87c97f6473f24 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 12:04:17 +0100 Subject: [PATCH 05/23] Remove workaround for Counter on wasm now we have AddAdditionalAssemblies --- .../BlazorWeb-CSharp/.template.config/template.json | 2 +- .../BlazorWeb-CSharp.Client/Pages/Counter.razor | 3 ++- .../BlazorWeb-CSharp/Components/Pages/Counter.razor | 8 -------- .../content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs | 9 +++++++-- 4 files changed, 10 insertions(+), 12 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index e81e8a87db02..08c9609489ee 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -78,7 +78,7 @@ } }, { - "condition": "!(UseServer || UseWebAssembly)", + "condition": "(!(UseServer && !UseWebAssembly))", "exclude": [ "BlazorWeb-CSharp/Components/Pages/Counter.razor" ] diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor index ae7b63e32c65..d15677cacbf8 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor @@ -1,4 +1,5 @@ -@*#if (UseServer) --> +@page "/counter" +@*#if (UseServer) --> @attribute [RenderModeAuto] ##else @attribute [RenderModeWebAssembly] diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor index f9bebaeab5ca..11ee7b1a9045 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor @@ -1,11 +1,4 @@ @page "/counter" -@*#if (UseWebAssembly) --> - - - - - -##else @*#if (!InteractiveAtRoot) --> @attribute [RenderModeServer] ##endif*@ @@ -26,4 +19,3 @@ currentCount++; } } -##endif*@ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs index b292ab166695..66ccd5be22e1 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs @@ -1,3 +1,6 @@ +#if (UseWebAssembly) +using BlazorWeb_CSharp.Client.Pages; +#endif using BlazorWeb_CSharp.Components; var builder = WebApplication.CreateBuilder(args); @@ -46,13 +49,15 @@ #if (UseServer && UseWebAssembly) app.MapRazorComponents() .AddServerRenderMode() - .AddWebAssemblyRenderMode(); + .AddWebAssemblyRenderMode() + .AddAdditionalAssemblies(typeof(Counter).Assembly); #elif (UseServer) app.MapRazorComponents() .AddServerRenderMode(); #elif (UseWebAssembly) app.MapRazorComponents() - .AddWebAssemblyRenderMode(); + .AddWebAssemblyRenderMode() + .AddAdditionalAssemblies(typeof(Counter).Assembly); #else app.MapRazorComponents(); #endif From cb930148f4389e24c264bc2f229663b92e3534b9 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 15:36:16 +0100 Subject: [PATCH 06/23] Make Program.Main.cs consistent --- .../BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs index ee561e30092c..46fc42f142e6 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs @@ -1,4 +1,6 @@ - +#if (UseWebAssembly) +using BlazorWeb_CSharp.Client.Pages; +#endif using BlazorWeb_CSharp.Components; namespace BlazorWeb_CSharp; @@ -53,13 +55,15 @@ public static void Main(string[] args) #if (UseServer && UseWebAssembly) app.MapRazorComponents() .AddServerRenderMode() - .AddWebAssemblyRenderMode(); + .AddWebAssemblyRenderMode() + .AddAdditionalAssemblies(typeof(Counter).Assembly); #elif (UseServer) app.MapRazorComponents() .AddServerRenderMode(); #elif (UseWebAssembly) app.MapRazorComponents() - .AddWebAssemblyRenderMode(); + .AddWebAssemblyRenderMode() + .AddAdditionalAssemblies(typeof(Counter).Assembly); #else app.MapRazorComponents(); #endif From dccdcb9568c848534fdcde3b35c301306247ce1c Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 15:56:36 +0100 Subject: [PATCH 07/23] Make root-level interactivity work for WebAssembly and Auto too --- .../.template.config/template.json | 8 ++++++++ .../Pages/Counter.razor | 4 ++-- .../BlazorWeb-CSharp/Components/App.razor | 20 +++++++++++++------ .../Components/Pages/Weather.razor | 2 +- .../BlazorWeb-CSharp/Components/Routes.razor | 6 +++--- .../Components/_Imports.razor | 3 +++ 6 files changed, 31 insertions(+), 12 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index 08c9609489ee..bafb91b679f4 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -62,6 +62,14 @@ "BlazorWeb-CSharp/": "./" } }, + { + "condition": "(UseWebAssembly && InteractiveAtRoot)", + "rename": { + "BlazorWeb-CSharp/Components/Layout/": "./BlazorWeb-CSharp.Client/Layout/", + "BlazorWeb-CSharp/Components/Pages/": "./BlazorWeb-CSharp.Client/Pages/", + "BlazorWeb-CSharp/Components/Routes.razor": "./BlazorWeb-CSharp.Client/Routes.razor" + } + }, { "condition": "(!UseProgramMain)", "exclude": [ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor index d15677cacbf8..2a32e84d4d86 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp.Client/Pages/Counter.razor @@ -1,7 +1,7 @@ @page "/counter" -@*#if (UseServer) --> +@*#if (UseServer && !InteractiveAtRoot) @attribute [RenderModeAuto] -##else +##elseif (!InteractiveAtRoot) @attribute [RenderModeWebAssembly] ##endif*@ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor index 27d52eaae2b8..bbeea521ac05 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/App.razor @@ -5,26 +5,34 @@ - @*#if (SampleContent) --> + @*#if (SampleContent) ##endif*@ - @*#if (SampleContent) --> + @*#if (SampleContent) ##endif*@ - @*#if (InteractiveAtRoot) --> + @*#if (!InteractiveAtRoot) + + ##elseif (UseServer && UseWebAssembly) + + ##elseif (UseServer) ##else - + ##endif*@ - @*#if (InteractiveAtRoot) --> + @*#if (!InteractiveAtRoot) + + ##elseif (UseServer && UseWebAssembly) --> + + ##elseif (UseServer) ##else - + ##endif*@ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor index efdb38a377ff..ccf7be47ec3e 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Weather.razor @@ -7,7 +7,7 @@

Weather

-

This component demonstrates showing data from the server.

+

This component demonstrates showing data.

@if (forecasts == null) { diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Routes.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Routes.razor index caaf8602c6fd..25a5e5887bfe 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Routes.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Routes.razor @@ -1,7 +1,7 @@ -@*#if (UseWebAssembly) --> - +@*#if (UseWebAssembly && !InteractiveAtRoot) + ##else - + ##endif*@ diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/_Imports.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/_Imports.razor index 1d7133e50d9a..68ab14b7c1e6 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/_Imports.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/_Imports.razor @@ -6,4 +6,7 @@ @using Microsoft.AspNetCore.Components.Web.Virtualization @using Microsoft.JSInterop @using BlazorWeb_CSharp +@*#if (UseWebAssembly) --> +@using BlazorWeb_CSharp.Client +##endif*@ @using BlazorWeb_CSharp.Components From de7331dfd06927a6b7d7a3629e413e3b7c0c107a Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 16:11:04 +0100 Subject: [PATCH 08/23] Fix some typos in template baselines --- .../test/Templates.Tests/template-baselines.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json index 030ce2f80017..423e994984a5 100644 --- a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json +++ b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json @@ -556,7 +556,7 @@ "AuthOption": "None" }, "UseWebAssembly": { - "Template": "web", + "Template": "blazor", "Arguments": "new blazor --use-server false --use-wasm", "Files": [ "{ProjectName}.sln", @@ -589,7 +589,7 @@ "AuthOption": "None" }, "UseServerAndWebAssembly": { - "Template": "web", + "Template": "blazor", "Arguments": "new blazor --use-wasm", "Files": [ "{ProjectName}.sln", @@ -660,7 +660,7 @@ "AuthOption": "None" }, "EmptyUseWebAssembly": { - "Template": "web", + "Template": "blazor", "Arguments": "new blazor --use-server false --use-wasm --empty", "Files": [ "{ProjectName}.sln", @@ -683,7 +683,7 @@ "AuthOption": "None" }, "EmptyUseServerAndWebAssembly": { - "Template": "web", + "Template": "blazor", "Arguments": "new blazor --use-wasm --empty", "Files": [ "{ProjectName}.sln", From 20f0bd58758a3f312b69e4114a463ec4ea50cc9c Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Wed, 13 Sep 2023 16:52:13 +0100 Subject: [PATCH 09/23] Add new template baselines --- .../Templates.Tests/template-baselines.json | 90 +++++++++++++++++++ 1 file changed, 90 insertions(+) diff --git a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json index 423e994984a5..ee0cdf1ee650 100644 --- a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json +++ b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json @@ -621,6 +621,96 @@ ], "AuthOption": "None" }, + "UseServerInteractiveAtRoot": { + "Template": "blazor", + "Arguments": "new blazor --all-interactive", + "Files": [ + "appsettings.Development.json", + "appsettings.json", + "Components/App.razor", + "Components/Layout/MainLayout.razor", + "Components/Layout/MainLayout.razor.css", + "Components/Layout/NavMenu.razor", + "Components/Layout/NavMenu.razor.css", + "Components/Pages/Counter.razor", + "Components/Pages/Home.razor", + "Components/Pages/Weather.razor", + "Components/Routes.razor", + "Components/_Imports.razor", + "Program.cs", + "Properties/launchSettings.json", + "{ProjectName}.csproj", + "wwwroot/app.css", + "wwwroot/bootstrap/bootstrap.min.css", + "wwwroot/bootstrap/bootstrap.min.css.map", + "wwwroot/favicon.png" + ], + "AuthOption": "None" + }, + "UseWebAssemblyInteractiveAtRoot": { + "Template": "blazor", + "Arguments": "new blazor --use-server false --use-wasm --all-interactive", + "Files": [ + "{ProjectName}/appsettings.Development.json", + "{ProjectName}/appsettings.json", + "{ProjectName}/Components/App.razor", + "{ProjectName}/Components/_Imports.razor", + "{ProjectName}/Program.cs", + "{ProjectName}/Properties/launchSettings.json", + "{ProjectName}/{ProjectName}.csproj", + "{ProjectName}/wwwroot/app.css", + "{ProjectName}/wwwroot/bootstrap/bootstrap.min.css", + "{ProjectName}/wwwroot/bootstrap/bootstrap.min.css.map", + "{ProjectName}/wwwroot/favicon.png", + "{ProjectName}.Client/Layout/MainLayout.razor", + "{ProjectName}.Client/Layout/MainLayout.razor.css", + "{ProjectName}.Client/Layout/NavMenu.razor", + "{ProjectName}.Client/Layout/NavMenu.razor.css", + "{ProjectName}.Client/Pages/Counter.razor", + "{ProjectName}.Client/Pages/Home.razor", + "{ProjectName}.Client/Pages/Weather.razor", + "{ProjectName}.Client/Program.cs", + "{ProjectName}.Client/Routes.razor", + "{ProjectName}.Client/{ProjectName}.Client.csproj", + "{ProjectName}.Client/wwwroot/appsettings.Development.json", + "{ProjectName}.Client/wwwroot/appsettings.json", + "{ProjectName}.Client/_Imports.razor", + "{ProjectName}.sln" + ], + "AuthOption": "None" + }, + "UseServerAndWebAssemblyInteractiveAtRoot": { + "Template": "blazor", + "Arguments": "new blazor --use-wasm --all-interactive", + "Files": [ + "{ProjectName}/appsettings.Development.json", + "{ProjectName}/appsettings.json", + "{ProjectName}/Components/App.razor", + "{ProjectName}/Components/_Imports.razor", + "{ProjectName}/Program.cs", + "{ProjectName}/Properties/launchSettings.json", + "{ProjectName}/{ProjectName}.csproj", + "{ProjectName}/wwwroot/app.css", + "{ProjectName}/wwwroot/bootstrap/bootstrap.min.css", + "{ProjectName}/wwwroot/bootstrap/bootstrap.min.css.map", + "{ProjectName}/wwwroot/favicon.png", + "{ProjectName}.Client/Layout/MainLayout.razor", + "{ProjectName}.Client/Layout/MainLayout.razor.css", + "{ProjectName}.Client/Layout/NavMenu.razor", + "{ProjectName}.Client/Layout/NavMenu.razor.css", + "{ProjectName}.Client/Pages/Counter.razor", + "{ProjectName}.Client/Pages/Home.razor", + "{ProjectName}.Client/Pages/Weather.razor", + "{ProjectName}.Client/Program.cs", + "{ProjectName}.Client/Routes.razor", + "{ProjectName}.Client/{ProjectName}.Client.csproj", + "{ProjectName}.Client/wwwroot/appsettings.Development.json", + "{ProjectName}.Client/wwwroot/appsettings.json", + "{ProjectName}.Client/_Imports.razor", + "{ProjectName}.sln" + ], + "AuthOption": "None" + }, "EmptyNoInteractivity": { "Template": "blazor", "Arguments": "new blazor --use-server false --empty", From b47ecb1b747214cd8af686ca273291f3500c084b Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 10:04:47 +0100 Subject: [PATCH 10/23] Switch from checkboxes to dropdowns --- .../.template.config/dotnetcli.host.json | 16 ++--- .../.template.config/ide.host.json | 12 +--- .../.template.config/template.json | 67 +++++++++++++++---- 3 files changed, 66 insertions(+), 29 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json index 8b01997181f7..a8c678b039b3 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json @@ -5,11 +5,15 @@ "longName": "no-restore", "shortName": "" }, - "UseServer": { - "longName": "use-server" + "InteractivityPlatform": { + "longName": "interactivity", + "shortName": "int" + }, + "AllInteractive": { + "longName": "all-interactive" }, - "UseWebAssembly": { - "longName": "use-wasm" + "InteractivityLocation": { + "isHidden": true }, "Empty": { "longName": "empty" @@ -17,10 +21,6 @@ "IncludeSampleContent": { "isHidden": true }, - "InteractiveAtRoot": { - "longName": "all-interactive", - "shortName": "int" - }, "Framework": { "longName": "framework" }, diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json index 67aa231f0a1d..5c5a1d00b7f4 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/ide.host.json @@ -5,21 +5,15 @@ "disableHttpsSymbol": "NoHttps", "symbolInfo": [ { - "id": "UseServer", + "id": "InteractivityPlatform", "isVisible": true, "persistenceScope": "templateGroup" }, { - "id": "UseWebAssembly", + "id": "InteractivityLocation", "isVisible": true, "persistenceScope": "templateGroup" }, - { - "id": "UseProgramMain", - "isVisible": true, - "persistenceScope": "shared", - "persistenceScopeName": "Microsoft" - }, { "id": "IncludeSampleContent", "isVisible": true, @@ -27,7 +21,7 @@ "persistenceScopeName": "Microsoft" }, { - "id": "InteractiveAtRoot", + "id": "UseProgramMain", "isVisible": true, "persistenceScope": "shared", "persistenceScopeName": "Microsoft" diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index bafb91b679f4..262971fa748a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -226,19 +226,58 @@ }, "replaces": "44300" }, - "UseWebAssembly": { + "InteractivityPlatform": { "type": "parameter", - "datatype": "bool", - "defaultValue": "false", - "displayName": "_Use interactive WebAssembly components", - "description": "Configures whether to support rendering components interactively in the browser using WebAssembly. The default value is false." + "datatype": "choice", + "defaultValue": "Server", + "displayName": "_Interactivity type", + "description": "Chooses which hosting platform to use for interactive components", + "choices": [ + { + "choice": "None", + "description": "No interactivity (static server rendering only)" + }, + { + "choice": "Server", + "description": "Runs on the server" + }, + { + "choice": "WebAssembly", + "description": "Runs in the browser using WebAssembly" + }, + { + "choice": "Auto", + "description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly" + } + ] }, - "UseServer": { + "InteractivityLocation": { "type": "parameter", - "datatype": "bool", - "defaultValue": "true", - "displayName": "_Use interactive server components", - "description": "Configures whether to support rendering components interactively on the server via a SignalR WebSocket connection. The default value is true." + "datatype": "choice", + "defaultValue": "InteractivePerPage", + "displayName": "_Interactivity location", + "description": "Chooses which components will have interactive rendering enabled", + "isEnabled": "(InteractivityPlatform != \"None\")", + "choices": [ + { + "choice": "InteractivePerPage", + "displayName": "Per page/component", + "description": "Interactivity is applied on a per-page or per-component basis" + }, + { + "choice": "InteractiveGlobal", + "displayName": "Global", + "description": "Interactivity is applied at the root level" + } + ] + }, + "UseWebAssembly": { + "type": "computed", + "value": "(InteractivityPlatform == \"WebAssembly\" || InteractivityPlatform == \"Auto\")" + }, + "UseServer": { + "type": "computed", + "value": "(InteractivityPlatform == \"Server\" || InteractivityPlatform == \"Auto\")" }, "IncludeSampleContent": { "type": "parameter", @@ -257,14 +296,18 @@ "type": "computed", "value": "(((IncludeSampleContent && (HostIdentifier != \"dotnetcli\" && HostIdentifier != \"dotnetcli-preview\"))) || ((!Empty && (HostIdentifier == \"dotnetcli\" || HostIdentifier == \"dotnetcli-preview\"))))" }, - "InteractiveAtRoot": { + "AllInteractive": { "type": "parameter", "datatype": "bool", - "isEnabled": "(UseServer || UseWebAssembly)", + "isEnabled": "(InteractivityPlatform != \"None\")", "defaultValue": "false", "displayName": "_Enable interactive rendering globally throughout the site", "description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis." }, + "InteractiveAtRoot": { + "type": "computed", + "value": "(InteractivityLocation == \"InteractiveGlobal\" || AllInteractive)" + }, "RequiresHttps": { "type": "computed", "value": "(OrganizationalAuth || IndividualAuth)" From f5512f48402e9fca570fdb54952869852a03f566 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 10:05:09 +0100 Subject: [PATCH 11/23] Update templatestrings --- .../localize/templatestrings.cs.json | 20 +++++++++++++------ .../localize/templatestrings.de.json | 20 +++++++++++++------ .../localize/templatestrings.en.json | 20 +++++++++++++------ .../localize/templatestrings.es.json | 20 +++++++++++++------ .../localize/templatestrings.fr.json | 20 +++++++++++++------ .../localize/templatestrings.it.json | 20 +++++++++++++------ .../localize/templatestrings.ja.json | 20 +++++++++++++------ .../localize/templatestrings.ko.json | 20 +++++++++++++------ .../localize/templatestrings.pl.json | 20 +++++++++++++------ .../localize/templatestrings.pt-BR.json | 20 +++++++++++++------ .../localize/templatestrings.ru.json | 20 +++++++++++++------ .../localize/templatestrings.tr.json | 20 +++++++++++++------ .../localize/templatestrings.zh-Hans.json | 20 +++++++++++++------ .../localize/templatestrings.zh-Hant.json | 20 +++++++++++++------ 14 files changed, 196 insertions(+), 84 deletions(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json index 8203142a8910..f4bfb9efbddd 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Číslo portu, který se má použít pro koncový bod HTTPS v souboru launchSettings.json. Tato možnost se dá použít jenom v případě, že se nepoužije parametr no-https (no-https se bude ignorovat, pokud se použije IndividualAuth nebo OrganizationalAuth).", "symbols/iisHttpPort/description": "Číslo portu, který se má použít pro koncový bod IIS Express HTTP v souboru launchSettings.json.", "symbols/iisHttpsPort/description": "Číslo portu, který se má použít pro koncový bod IIS Express HTTPS v souboru launchSettings.json. Tato možnost se dá použít jenom v případě, že se nepoužije parametr no-https (no-https se bude ignorovat, pokud se použije IndividualAuth nebo OrganizationalAuth).", - "symbols/UseWebAssembly/displayName": "_Použít interaktivní komponenty WebAssembly", - "symbols/UseWebAssembly/description": "Konfiguruje, jestli má být podporováno interaktivní vykreslování komponent v prohlížeči pomocí WebAssembly. Výchozí hodnota je false.", - "symbols/UseServer/displayName": "_Použít interaktivní serverové komponenty", - "symbols/UseServer/description": "Konfiguruje, jestli má podporovat interaktivní vykreslování komponent na serveru prostřednictvím připojení SignalR WebSocket. Výchozí hodnota je true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Zahrnout ukázkové stránky", "symbols/IncludeSampleContent/description": "Nastavuje, jestli se mají přidávat ukázkové stránky a styly pro demonstraci základních vzorů použití.", "symbols/Empty/description": "Nastavuje, jestli se mají vynechat ukázkové stránky a styly, které demonstrují základní vzory použití.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Určuje, jestli se má protokol HTTPS vypnout. Tato možnost platí jenom v případě, že se pro --auth nepoužívají Individual, IndividualB2C, SingleOrg ani MultiOrg.", "symbols/UseProgramMain/displayName": "Nepoužívat _příkazy nejvyšší úrovně", "symbols/UseProgramMain/description": "Určuje, jestli se má místo příkazů nejvyšší úrovně generovat explicitní třída Program a metoda Main.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json index 268e2b803474..f950499f1531 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Portnummer, die für den HTTPS Endpunkt in launchSettings.json verwendet werden soll. Diese Option ist nur anwendbar, wenn der Parameter no-https nicht verwendet wird (no-https wird ignoriert, wenn entweder IndividualAuth oder OrganizationalAuth verwendet wird).", "symbols/iisHttpPort/description": "Portnummer, die für den IIS Express HTTP Endpunkt in launchSettings.json verwendet werden soll.", "symbols/iisHttpsPort/description": "Portnummer, die für den IIS Express HTTPS Endpunkt in launchSettings.json verwendet werden soll. Diese Option ist nur anwendbar, wenn der Parameter no-https nicht verwendet wird (no-https wird ignoriert, wenn entweder IndividualAuth oder OrganizationalAuth verwendet wird).", - "symbols/UseWebAssembly/displayName": "_Interaktive WebAssembly-Komponenten verwenden", - "symbols/UseWebAssembly/description": "Konfiguriert, ob das interaktive Rendern von Komponenten im Browser mithilfe von WebAssembly unterstützt werden soll. Der Standardwert ist FALSE.", - "symbols/UseServer/displayName": "_Interaktive Serverkomponenten verwenden", - "symbols/UseServer/description": "Konfiguriert, ob das interaktive Rendern von Komponenten auf dem Server über eine SignalR WebSocket-Verbindung unterstützt werden soll. Der Standardwert ist TRUE.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Include Beispielseiten", "symbols/IncludeSampleContent/description": "Konfiguriert, ob Beispielseiten und Stile hinzugefügt werden, um grundlegende Verwendungsmuster zu veranschaulichen.", "symbols/Empty/description": "Konfiguriert, ob Beispielseiten und Formatierungen weggelassen werden sollen, die grundlegende Verwendungsmuster veranschaulichen.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Ob HTTPS deaktiviert werden soll. Diese Option gilt nur, wenn Individual, IndividualB2C, SingleOrg oder MultiOrg nicht für --auth verwendet werden.", "symbols/UseProgramMain/displayName": "Keine Anweisungen_der obersten Ebene verwenden", "symbols/UseProgramMain/description": "Gibt an, ob anstelle von Anweisungen der obersten Ebene eine explizite Programmklasse und eine Main-Methode generiert werden soll.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json index ed7cd6ce50ee..8b0b7c101bd3 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Port number to use for the HTTPS endpoint in launchSettings.json. This option is only applicable when the parameter no-https is not used (no-https will be ignored if either IndividualAuth or OrganizationalAuth is used).", "symbols/iisHttpPort/description": "Port number to use for the IIS Express HTTP endpoint in launchSettings.json.", "symbols/iisHttpsPort/description": "Port number to use for the IIS Express HTTPS endpoint in launchSettings.json. This option is only applicable when the parameter no-https is not used (no-https will be ignored if either IndividualAuth or OrganizationalAuth is used).", - "symbols/UseWebAssembly/displayName": "_Use interactive WebAssembly components", - "symbols/UseWebAssembly/description": "Configures whether to support rendering components interactively in the browser using WebAssembly. The default value is false.", - "symbols/UseServer/displayName": "_Use interactive server components", - "symbols/UseServer/description": "Configures whether to support rendering components interactively on the server via a SignalR WebSocket connection. The default value is true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page/component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Include sample pages", "symbols/IncludeSampleContent/description": "Configures whether to add sample pages and styling to demonstrate basic usage patterns.", "symbols/Empty/description": "Configures whether to omit sample pages and styling that demonstrate basic usage patterns.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Whether to turn off HTTPS. This option only applies if Individual, IndividualB2C, SingleOrg, or MultiOrg aren't used for --auth.", "symbols/UseProgramMain/displayName": "Do not use _top-level statements", "symbols/UseProgramMain/description": "Whether to generate an explicit Program class and Main method instead of top-level statements.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json index 001ffaae46dc..28c49f5cb2d5 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Número de puerto que se va a usar para el punto de conexión HTTPS en launchSettings.json. Esta opción solo es aplicable cuando no se usa el parámetro no-https (no-https se omitirá si se usa IndividualAuth o OrganizationalAuth).", "symbols/iisHttpPort/description": "Número de puerto que se va a usar para el punto de conexión HTTP de IIS Express en launchSettings.json.", "symbols/iisHttpsPort/description": "Número de puerto que se va a usar para el punto de conexión HTTPS de IIS Express en launchSettings.json. Esta opción solo es aplicable cuando no se usa el parámetro no-https (no-https se omitirá si se usa IndividualAuth o OrganizationalAuth).", - "symbols/UseWebAssembly/displayName": "_Usar componentes de WebAssembly interactivos", - "symbols/UseWebAssembly/description": "Configura si se admite la representación de componentes de forma interactiva en el explorador mediante WebAssembly. El valor predeterminado es falso.", - "symbols/UseServer/displayName": "_Use componentes de servidor interactivos", - "symbols/UseServer/description": "Configura si se admite la representación de componentes de forma interactiva en el servidor a través de una conexión WebSocket de SignalR. El valor predeterminado es verdadero.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Incluir páginas de ejemplo", "symbols/IncludeSampleContent/description": "Configura si se van a agregar páginas de ejemplo y estilos para mostrar patrones de uso básicos.", "symbols/Empty/description": "Configura si se omiten las páginas de ejemplo y los estilos que muestran patrones de uso básicos.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Si se va a desactivar HTTPS. Esta opción solo se aplica si Individual, IndividualB2C, SingleOrg o MultiOrg no se usan para --auth.", "symbols/UseProgramMain/displayName": "No usar instrucciones de _nivel superior", "symbols/UseProgramMain/description": "Indica si se debe generar una clase Program explícita y un método Main en lugar de instrucciones de nivel superior.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json index 2b00dfcaa9e0..1050b1b4172b 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Numéro de port à utiliser pour le point de terminaison HTTPS dans launchSettings.json. Cette option s’applique uniquement lorsque le paramètre no-https n’est pas utilisé (no-https sera ignoré si IndividualAuth ou OrganizationalAuth est utilisé).", "symbols/iisHttpPort/description": "Numéro de port à utiliser pour le point de terminaison HTTP IIS Express dans launchSettings.json.", "symbols/iisHttpsPort/description": "Numéro de port à utiliser pour le point de terminaison HTTPS IIS Express dans launchSettings.json. Cette option s’applique uniquement lorsque le paramètre no-https n’est pas utilisé (no-https sera ignoré si IndividualAuth ou OrganizationalAuth est utilisé).", - "symbols/UseWebAssembly/displayName": "_Utiliser des composants WebAssembly interactifs", - "symbols/UseWebAssembly/description": "Configure s'il faut prendre en charge les composants de rendu de manière interactive dans le navigateur à l'aide de WebAssembly. La valeur par défaut est faux.", - "symbols/UseServer/displayName": "_Utiliser les composants serveur interactifs", - "symbols/UseServer/description": "Configure s'il faut prendre en charge les composants de rendu de manière interactive sur le serveur via une connexion SignalR WebSocket. La valeur par défaut est true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Inclure des exemples de pages", "symbols/IncludeSampleContent/description": "Configure s'il faut ajouter des exemples de pages et de style pour illustrer les modèles d'utilisation de base.", "symbols/Empty/description": "Configure s'il faut omettre les exemples de pages et le style qui illustrent les modèles d'utilisation de base.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Indique s’il faut désactiver HTTPS. Cette option s’applique uniquement si Individual, IndividualB2C, SingleOrg ou MultiOrg ne sont pas utilisés pour --auth.", "symbols/UseProgramMain/displayName": "N’utilisez pas _d’instructions de niveau supérieur.", "symbols/UseProgramMain/description": "Indique s’il faut générer une classe Programme explicite et une méthode Main au lieu d’instructions de niveau supérieur.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json index 6ea633231a09..2f9635d9669b 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Numero di porta da usare per l'endpoint HTTPS in launchSettings.json. Questa opzione è applicabile solo quando il parametro no-https non viene usato (no-https verrà ignorato se si usa IndividualAuth o OrganizationalAuth).", "symbols/iisHttpPort/description": "Numero di porta da usare per l'endpoint HTTP in launchSettings.json.", "symbols/iisHttpsPort/description": "Numero di porta da usare per l'endpoint HTTPS IIS Express in launchSettings.json. Questa opzione è applicabile solo quando il parametro no-https non viene usato (no-https verrà ignorato se si usa IndividualAuth o OrganizationalAuth).", - "symbols/UseWebAssembly/displayName": "_Usa componenti webassembly interattivi", - "symbols/UseWebAssembly/description": "Consente di configurare se supportare il rendering interattivo dei componenti nel browser tramite WebAssembly. Il valore predefinito è false.", - "symbols/UseServer/displayName": "_Usa componenti server interattivi", - "symbols/UseServer/description": "Consente di configurare se supportare il rendering interattivo dei componenti nel server tramite una connessione SignalR WebSocket. Il valore predefinito è true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Include pagine di esempio", "symbols/IncludeSampleContent/description": "Consente di configurare se aggiungere pagine di esempio e stile per mostrare modelli di utilizzo di base.", "symbols/Empty/description": "Consente di configurare se omettere pagine di esempio e stile che mostrano modelli di utilizzo di base.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Indica se disattivare HTTPS. Questa opzione si applica solo se Individual, IndividualB2C, SingleOrg o MultiOrg non vengono usati per --auth.", "symbols/UseProgramMain/displayName": "Non usare_istruzioni di primo livello", "symbols/UseProgramMain/description": "Indica se generare una classe Program esplicita e un metodo Main anziché istruzioni di primo livello.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json index 5cd2468aaa8a..2e4ad40919fb 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "launchSettings.json で HTTPS エンドポイントに使用するポート番号。このオプションは、HTTPS 以外のパラメーターが使用されていない場合にのみ適用されます (IndividualAuth または OrganizationalAuth が使用されている場合は、HTTPS 以外は無視されます)。", "symbols/iisHttpPort/description": "launchSettings.json の IIS Express HTTP エンドポイントに使用するポート番号。", "symbols/iisHttpsPort/description": "launchSettings.json で IIS Express HTTPS エンドポイントに使用するポート番号。このオプションは、HTTPS 以外のパラメーターが使用されていない場合にのみ適用されます (IndividualAuth または OrganizationalAuth が使用されている場合は、HTTPS 以外は無視されます)。", - "symbols/UseWebAssembly/displayName": "_対話型 WebAssembly コンポーネントを使用する", - "symbols/UseWebAssembly/description": "WebAssembly を使用してブラウザーでコンポーネントを対話的にレンダリングできるかどうかを構成します。既定値は false です。", - "symbols/UseServer/displayName": "_対話型サーバー コンポーネントを使用する", - "symbols/UseServer/description": "SignalR WebSocket 接続を介してサーバー上のコンポーネントを対話的にレンダリングできるかどうかを構成します。既定値は true です。", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "サンプル ページを含める(_I)", "symbols/IncludeSampleContent/description": "基本的な使用パターンを示すサンプル ページとスタイルを追加するかどうかを構成します。", "symbols/Empty/description": "基本的な使用パターンを示すサンプル ページとスタイルを省略するかどうかを構成します。", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS をオフにするかどうか。このオプションは、Individual、IndividualB2C、SingleOrg、または MultiOrg が --auth に使用されていない場合にのみ適用されます。", "symbols/UseProgramMain/displayName": "最上位レベルのステートメントを使用しない(_T)", "symbols/UseProgramMain/description": "最上位レベルのステートメントではなく、明示的な Program クラスと Main メソッドを生成するかどうか。", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json index 4b1c09bf07ac..c0c0a80acc9c 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "launchSettings.json의 HTTPS 엔드포인트에 사용할 포트 번호입니다. 이 옵션은 매개 변수 no-https가 사용되지 않은 경우에만 적용됩니다(IndividualAuth 또는 OrganizationalAuth가 사용되는 경우 no-https는 무시됨).", "symbols/iisHttpPort/description": "launchSettings.json의 IIS Express HTTP 엔드포인트에 사용할 포트 번호입니다.", "symbols/iisHttpsPort/description": "launchSettings.json의 IIS Express 엔드포인트에 사용할 포트 번호입니다. 이 옵션은 매개 변수 no-https가 사용되지 않은 경우에만 적용됩니다(IndividualAuth 또는 OrganizationalAuth가 사용되는 경우 no-https는 무시됨).", - "symbols/UseWebAssembly/displayName": "_대화형 WebAssembly 구성 요소 사용", - "symbols/UseWebAssembly/description": "WebAssembly를 사용하여 브라우저에서 렌더링 구성 요소를 대화형으로 지원할지 여부를 구성합니다. 기본값은 false입니다.", - "symbols/UseServer/displayName": "_대화형 서버 구성 요소 사용", - "symbols/UseServer/description": "SignalR WebSocket 연결을 통해 서버에서 렌더링 구성 요소를 대화형으로 지원할지 여부를 구성합니다. 기본값은 true입니다.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "샘플 페이지 포함(_I)", "symbols/IncludeSampleContent/description": "기본 사용 패턴을 보여주기 위해 샘플 페이지 및 스타일을 추가할지 여부를 구성합니다.", "symbols/Empty/description": "기본 사용 패턴을 보여주는 샘플 페이지 및 스타일을 생략할지 여부를 구성합니다.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS를 끌지 여부입니다. 이 옵션은 Individual, IndividualB2C, SingleOrg 또는 MultiOrg가 --auth에 사용되지 않는 경우에만 적용됩니다.", "symbols/UseProgramMain/displayName": "최상위 문 사용 안 함(_T)", "symbols/UseProgramMain/description": "최상위 문 대신 명시적 Program 클래스 및 Main 메서드를 생성할지 여부입니다.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json index 53e8ff71ddb1..6041f294ac98 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Numer portu do użycia dla punktu końcowego HTTPS w pliku launchSettings.json. Ta opcja ma zastosowanie tylko wtedy, gdy parametr no-https nie jest używany (parametr no-https zostanie zignorowany, jeśli zostanie użyte uwierzytelnianie IndividualAuth lub OrganizationalAuth).", "symbols/iisHttpPort/description": "Numer portu do użycia dla punktu końcowego HTTP usług IIS Express w pliku launchSettings.json.", "symbols/iisHttpsPort/description": "Numer portu do użycia dla punktu końcowego HTTPS usług IIS Express w pliku launchSettings.json. Ta opcja ma zastosowanie tylko wtedy, gdy nie jest używany parametr no-https (jeśli zostanie użyte uwierzytelnianie IndividualAuth lub OrganizationalAuth, parametr no-https zostanie zignorowana).", - "symbols/UseWebAssembly/displayName": "_Używanie interakcyjnych składników zestawu WebAssembly", - "symbols/UseWebAssembly/description": "Konfiguruje, czy składniki renderowania mają być obsługiwane interakcyjnie w przeglądarce przy użyciu zestawu WebAssembly. Wartość domyślna to false.", - "symbols/UseServer/displayName": "_Używanie interakcyjnych składników serwera", - "symbols/UseServer/description": "Konfiguruje, czy składniki renderowania mają być obsługiwane interaktywnie na serwerze za pośrednictwem połączenia usługi SignalR WebSocket. Wartość domyślna to true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Dołącz przykładowe strony", "symbols/IncludeSampleContent/description": "Konfiguruje, czy dodać przykładowe strony i style w celu zademonstrowania podstawowych wzorców użycia.", "symbols/Empty/description": "Konfiguruje, czy pomijać przykładowe strony i style demonstrujące podstawowe wzorce użycia.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Określa, czy wyłączyć protokół HTTPS. Ta opcja ma zastosowanie tylko wtedy, gdy dla uwierzytelniania --auth nie są używane elementy Individual, IndividualB2C, SingleOrg lub MultiOrg.", "symbols/UseProgramMain/displayName": "Nie używaj ins_trukcji najwyższego poziomu", "symbols/UseProgramMain/description": "Określa, czy wygenerować jawną klasę Program i metodę Main zamiast instrukcji najwyższego poziomu.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json index 74438cd13f1d..9a8b3654a8aa 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Número da porta a ser usada para o ponto de extremidade HTTPS em launchSettings.json. Essa opção só é aplicável quando o parâmetro no-https não é usado (no-https será ignorado se IndividualAuth ou OrganizationalAuth for usado).", "symbols/iisHttpPort/description": "Número da porta a ser usada para o ponto de extremidade HTTP do IIS Express em launchSettings.json.", "symbols/iisHttpsPort/description": "Número da porta a ser usada para o ponto de extremidade HTTPS do IIS Express em launchSettings.json. Essa opção só é aplicável quando o parâmetro no-https não é usado (no-https será ignorado se IndividualAuth ou OrganizationalAuth for usado).", - "symbols/UseWebAssembly/displayName": "_Use componentes interativos do WebAssembly", - "symbols/UseWebAssembly/description": "Configura se deve oferecer suporte a componentes de renderização interativamente no navegador usando WebAssembly. O valor padrão é falso.", - "symbols/UseServer/displayName": "_Use componentes de servidor interativos", - "symbols/UseServer/description": "Configura se deve oferecer suporte a componentes de renderização interativamente no servidor por meio de uma conexão SignalR WebSocket. O valor padrão é verdadeiro.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Incluir páginas de amostra", "symbols/IncludeSampleContent/description": "Configura se deseja adicionar páginas de amostra e estilo para demonstrar padrões de uso básicos.", "symbols/Empty/description": "Configura a omissão de páginas de amostra e estilo que demonstram padrões básicos de uso.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Se o HTTPS deve ser desativado. Essa opção se aplica somente se Individual, IndividualB2C, SingleOrg ou MultiOrg não forem usados para --auth.", "symbols/UseProgramMain/displayName": "Não use ins_truções de nível superior", "symbols/UseProgramMain/description": "Se deve gerar uma classe de Programa explícita e um método principal em vez de instruções de nível superior.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json index e92cac8c811a..1cc5c56e6f66 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "Номер порта, используемый для конечной точки HTTPS в launchSettings.json. Этот параметр применим только в том случае, если no-https не используется (при использовании IndividualAuth или OrganizationalAuth no-https игнорируется).", "symbols/iisHttpPort/description": "Номер порта, используемый для конечной точки HTTP IIS Express в launchSettings.json.", "symbols/iisHttpsPort/description": "Номер порта, используемый для конечной точки HTTPS IIS Express в launchSettings.json. Этот параметр применим только в том случае, если no-https не используется (при использовании IndividualAuth или OrganizationalAuth no-https игнорируется).", - "symbols/UseWebAssembly/displayName": "_Использовать интерактивные компоненты WebAssembly", - "symbols/UseWebAssembly/description": "Настраивает, следует ли поддерживать интерактивный рендеринг компонентов в браузере с помощью WebAssembly. Значение по умолчанию — false.", - "symbols/UseServer/displayName": "_Использовать интерактивные компоненты сервера", - "symbols/UseServer/description": "Настраивает, следует ли поддерживать интерактивный рендеринг компонентов на сервере через подключение SignalR WebSocket. Значение по умолчанию — true.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "_Включить примеры страниц", "symbols/IncludeSampleContent/description": "Настраивает, следует ли добавлять примеры страниц и стили для демонстрации базовых шаблонов использования.", "symbols/Empty/description": "Настраивает, следует ли пропускать примеры страниц и стили, демонстрирующие базовые шаблоны использования.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "Следует ли отключить HTTPS. Этот параметр применяется, только если для --auth не используются Individual, IndividualB2C, SingleOrg или MultiOrg.", "symbols/UseProgramMain/displayName": "Не использовать _операторы верхнего уровня", "symbols/UseProgramMain/description": "Следует ли создавать явный класс Program и метод Main вместо операторов верхнего уровня.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json index e7b635879781..3164a6321949 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "launchSettings.json içinde HTTPS uç noktası için kullanılacak bağlantı noktası numarası. Bu seçenek yalnızca no-https parametresi kullanılmazsa uygulanabilir (IndividualAuth veya OrganizationalAuth kullanılırsa no-https yoksayılır).", "symbols/iisHttpPort/description": "launchSettings.json içinde IIS Express HTTP uç noktası için kullanılacak bağlantı noktası numarası.", "symbols/iisHttpsPort/description": "launchSettings.json içinde IIS Express HTTPS uç noktası için kullanılacak bağlantı noktası numarası. Bu seçenek yalnızca no-https parametresi kullanılmazsa uygulanabilir (IndividualAuth veya OrganizationalAuth kullanılırsa no-https yoksayılır).", - "symbols/UseWebAssembly/displayName": "_Etkileşimli WebAssembly bileşenlerini kullanın", - "symbols/UseWebAssembly/description": "WebAssembly kullanarak bileşenlerin tarayıcıda etkileşimli olarak işlenmesinin desteklenip desteklenmeyeceğini yapılandırır. Varsayılan değer: yanlış.", - "symbols/UseServer/displayName": "_Etkileşimli sunucu bileşenlerini kullanın", - "symbols/UseServer/description": "SignalR WebSocket bağlantısı kullanarak bileşenlerin sunucuda etkileşimli olarak işlenmesinin desteklenip desteklenmeyeceğini yapılandırır. Varsayılan değer: doğru.", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "Örnek _sayfalar ekle", "symbols/IncludeSampleContent/description": "Temel kullanım düzenlerini göstermek için örnek sayfaların ve stil oluşturma özelliklerinin eklenip eklenmeyeceğini yapılandırır.", "symbols/Empty/description": "Temel kullanım düzenlerini gösteren örnek sayfaların ve stil oluşturma özelliklerinin atlanıp atlanmayacağını yapılandırır.", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "HTTPS'nin kapatılıp kapatılmayacağı. Bu seçenek yalnızca Bireysel, IndividualB2C, SingleOrg veya MultiOrg -- auth için kullanılmazsa geçerlidir.", "symbols/UseProgramMain/displayName": "_Üst düzey deyimler kullanmayın", "symbols/UseProgramMain/description": "Üst düzey deyimler yerine açık bir Program sınıfı ve Ana yöntem oluşturup oluşturulmayacağını belirtir.", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json index 8f8a96289c35..80313bc8f0b1 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "要用于 launchSettings.json 中 HTTPS 终结点的端口号。仅当不使用参数 no-https 时,此选项才适用(如果使用 IndividualAuth 或 OrganizationalAuth,则将忽略 no-https)。", "symbols/iisHttpPort/description": "要用于 launchSettings.json 中 IIS Express HTTP 终结点的端口号。", "symbols/iisHttpsPort/description": "要用于 launchSettings.json 中 IIS Express HTTPS 终结点的端口号。仅当不使用参数 no-https 时,此选项才适用(如果使用 IndividualAuth 或 OrganizationalAuth,则将忽略 no-https)。", - "symbols/UseWebAssembly/displayName": "使用交互式 WebAssembly 组件(_U)", - "symbols/UseWebAssembly/description": "配置是否支持使用 WebAssembly 在浏览器中以交互方式呈现组件。默认值为 false。", - "symbols/UseServer/displayName": "使用交互式服务器组件(_U)", - "symbols/UseServer/description": "配置是否支持通过 SignalR WebSocket 连接在服务器上以交互方式呈现组件。默认值为 true。", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "包含示例页(_I)", "symbols/IncludeSampleContent/description": "配置是否添加示例页和样式以演示基本使用模式。", "symbols/Empty/description": "配置是否忽略演示基本使用模式的示例页和样式。", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "是否禁用 HTTPS。仅当 Individual、IndividualB2C、SingleOrg 或 MultiOrg 不用于 --auth 时,此选项才适用。", "symbols/UseProgramMain/displayName": "不使用顶级语句(_T)", "symbols/UseProgramMain/description": "是否生成显式程序类和主方法,而不是顶级语句。", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json index 58099a9f8bd5..edd6c5e7b374 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json @@ -10,15 +10,23 @@ "symbols/kestrelHttpsPort/description": "launchSettings.json 中 HTTPS 端點要使用的連接埠號碼。只有在未使用參數 no-https 時,才適用此選項 (如果使用 IndividualAuth 或 OrganizationalAuth,則會忽略 no-https)。", "symbols/iisHttpPort/description": "launchSettings.json 中 IIS Express HTTP 端點要使用的連接埠號碼。", "symbols/iisHttpsPort/description": "launchSettings.json 中 IIS Express HTTPS 端點要使用的連接埠號碼。只有在未使用參數 no-https 時,才適用此選項 (如果使用 IndividualAuth 或 OrganizationalAuth,則會忽略 no-https)。", - "symbols/UseWebAssembly/displayName": "使用互動式 WebAssembly 元件(_U)", - "symbols/UseWebAssembly/description": "設定是否要使用 WebAssembly 在瀏覽器中以互動方式支援呈現元件。預設值為 False。", - "symbols/UseServer/displayName": "使用互動式伺服器元件(_U)", - "symbols/UseServer/description": "設定是否要透過 SignalR WebSocket 連線在伺服器上以互動方式支援呈現元件。預設值為 True。", + "symbols/InteractivityPlatform/displayName": "_Interactivity type", + "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", + "symbols/InteractivityLocation/displayName": "_Interactivity location", + "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", + "symbols/InteractivityLocation/choices/InteractivePerPage/displayName": "Per page or component", + "symbols/InteractivityLocation/choices/InteractivePerPage/description": "Interactivity is applied on a per-page or per-component basis", + "symbols/InteractivityLocation/choices/InteractiveGlobal/displayName": "Global", + "symbols/InteractivityLocation/choices/InteractiveGlobal/description": "Interactivity is applied at the root level", "symbols/IncludeSampleContent/displayName": "包含範例頁面(_I)", "symbols/IncludeSampleContent/description": "設定是否要新增範例頁面和樣式,以示範基本使用模式。", "symbols/Empty/description": "設定是否要省略範例頁面和樣式,其示範基本使用模式。", - "symbols/InteractiveAtRoot/displayName": "_Enable interactive rendering globally throughout the site", - "symbols/InteractiveAtRoot/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", + "symbols/AllInteractive/displayName": "_Enable interactive rendering globally throughout the site", + "symbols/AllInteractive/description": "Configures whether to make every page interactive by applying an interactive render mode at the top level. If false, pages will use static server rendering by default, and can be marked interactive on a per-page or per-component basis.", "symbols/NoHttps/description": "是否要關閉 HTTPS。只有當 Individual、IndividualB2C、SingleOrg 或 MultiOrg 未用於 --auth 時,才適用此選項。", "symbols/UseProgramMain/displayName": "不要使用最上層陳述式(_T)", "symbols/UseProgramMain/description": "是否要產生明確的 Program 類別和 Main 方法,而非最上層語句。", From 8fb3733b220e2b55ecadd662a05bd5ca1edd313b Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 10:13:31 +0100 Subject: [PATCH 12/23] Test updates to match --- src/ProjectTemplates/Shared/ArgConstants.cs | 2 +- .../BlazorWebTemplateTest.cs | 10 +++++----- .../test/Templates.Tests/template-baselines.json | 16 ++++++++-------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/ProjectTemplates/Shared/ArgConstants.cs b/src/ProjectTemplates/Shared/ArgConstants.cs index 18fe3a461a13..342f8ce80c48 100644 --- a/src/ProjectTemplates/Shared/ArgConstants.cs +++ b/src/ProjectTemplates/Shared/ArgConstants.cs @@ -25,6 +25,6 @@ internal static class ArgConstants public const string UseLocalDb = "-uld"; public const string NoHttps = "--no-https"; public const string PublishNativeAot = "--aot"; - public const string UseServer = "--use-server"; + public const string NoInteractivity = "--interactivity none"; public const string Empty = "--empty"; } diff --git a/src/ProjectTemplates/test/Templates.Blazor.Tests/BlazorWebTemplateTest.cs b/src/ProjectTemplates/test/Templates.Blazor.Tests/BlazorWebTemplateTest.cs index 4a33d57d93c9..31b79308c7f5 100644 --- a/src/ProjectTemplates/test/Templates.Blazor.Tests/BlazorWebTemplateTest.cs +++ b/src/ProjectTemplates/test/Templates.Blazor.Tests/BlazorWebTemplateTest.cs @@ -69,7 +69,7 @@ public async Task BlazorWebTemplate_NoAuth(string[] args) } }; - if (args.Contains(ArgConstants.UseServer)) + if (!args.Contains(ArgConstants.NoInteractivity)) { pages.Add(new Page { @@ -102,10 +102,10 @@ public async Task BlazorWebTemplate_NoAuth(string[] args) new[] { ArgConstants.UseProgramMain }, new[] { ArgConstants.NoHttps }, new[] { ArgConstants.UseProgramMain, ArgConstants.NoHttps }, - new[] { ArgConstants.UseServer }, - new[] { ArgConstants.UseServer, ArgConstants.UseProgramMain }, - new[] { ArgConstants.UseServer, ArgConstants.NoHttps }, - new[] { ArgConstants.UseServer, ArgConstants.UseProgramMain, ArgConstants.NoHttps } + new[] { ArgConstants.NoInteractivity }, + new[] { ArgConstants.NoInteractivity, ArgConstants.UseProgramMain }, + new[] { ArgConstants.NoInteractivity, ArgConstants.NoHttps }, + new[] { ArgConstants.NoInteractivity, ArgConstants.UseProgramMain, ArgConstants.NoHttps } }; private string ReadFile(string basePath, string path) diff --git a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json index ee0cdf1ee650..8833b4f7d469 100644 --- a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json +++ b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json @@ -506,7 +506,7 @@ "blazor": { "NoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --use-server false", + "Arguments": "new blazor --interactivity none", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -557,7 +557,7 @@ }, "UseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --use-server false --use-wasm", + "Arguments": "new blazor --interactivity webassembly", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -590,7 +590,7 @@ }, "UseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --use-wasm", + "Arguments": "new blazor --interactivity auto", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -649,7 +649,7 @@ }, "UseWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --use-server false --use-wasm --all-interactive", + "Arguments": "new blazor --interactivity webassembly --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -681,7 +681,7 @@ }, "UseServerAndWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --use-wasm --all-interactive", + "Arguments": "new blazor --interactivity auto --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -713,7 +713,7 @@ }, "EmptyNoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --use-server false --empty", + "Arguments": "new blazor --interactivity none --empty", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -751,7 +751,7 @@ }, "EmptyUseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --use-server false --use-wasm --empty", + "Arguments": "new blazor --interactivity webassembly --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -774,7 +774,7 @@ }, "EmptyUseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --use-wasm --empty", + "Arguments": "new blazor --interactivity auto --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", From 7a8ab5cbb642e051ce31fc766d6e0d95eac574df Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 11:41:10 +0100 Subject: [PATCH 13/23] Rename the render modes --- .../RazorComponentDataSourceOptions.cs | 8 +-- .../Endpoints/src/Discovery/ComponentInfo.cs | 18 +++---- .../Discovery/RazorComponentApplication.cs | 14 ++--- .../EndpointHtmlRenderer.PrerenderingState.cs | 12 ++--- .../src/Rendering/SSRRenderModeBoundary.cs | 24 ++++----- .../test/EndpointHtmlRendererTest.cs | 32 +++++------ .../Endpoints/test/HotReloadServiceTests.cs | 4 +- .../RazorComponentEndpointDataSourceTest.cs | 32 +++++------ .../test/SSRRenderModeBoundaryTest.cs | 12 ++--- .../InteractiveGreetingServer.razor | 2 +- ...eractiveGreetingServerNonPrerendered.razor | 2 +- .../InteractiveGreetingWebAssembly.razor | 2 +- ...iveGreetingWebAssemblyNonPrerendered.razor | 2 +- .../InteractiveWithInteractiveChild.razor | 2 +- .../src/Builder/InternalServerRenderMode.cs | 2 +- ...entsEndpointConventionBuilderExtensions.cs | 2 +- .../Server/src/Circuits/RemoteRenderer.cs | 2 +- .../ServerRazorComponentsBuilderExtensions.cs | 4 +- .../test/Circuits/RenderBatchWriterTest.cs | 2 +- .../Web/src/PublicAPI.Unshipped.txt | 54 +++++++++---------- ...erMode.cs => InteractiveAutoRenderMode.cs} | 12 ++--- ...Mode.cs => InteractiveServerRenderMode.cs} | 10 ++-- ...cs => InteractiveWebAssemblyRenderMode.cs} | 12 ++--- .../Web/src/RenderMode/RenderMode.cs | 6 +-- .../TemporaryRenderModeAttributes.cs | 36 ++++++------- ...entsEndpointConventionBuilderExtensions.cs | 2 +- .../WebAssemblyRenderModeWithOptions.cs | 2 +- ...ssemblyRazorComponentsBuilderExtensions.cs | 4 +- .../src/Rendering/WebAssemblyRenderer.cs | 2 +- ...teractiveStreamingRenderingComponent.razor | 12 ++--- .../Components/ServerInteractiveCounter.razor | 2 +- .../Auth/InteractiveAuthenticationState.razor | 2 +- .../Pages/CallSiteInteractiveComponents.razor | 4 +- ...ithInteractiveComponentsThatNavigate.razor | 4 +- ...tualizationTransitionToInteractivity.razor | 4 +- .../Pages/Rendering/LargeHtml.razor | 6 +-- .../RazorComponents/Root.razor | 2 +- .../ServerInteractiveCounter.razor | 2 +- .../WebAssemblyInteractiveCounter.razor | 2 +- .../HtmlHelperComponentExtensions.cs | 8 +-- 40 files changed, 183 insertions(+), 183 deletions(-) rename src/Components/Web/src/RenderMode/{AutoRenderMode.cs => InteractiveAutoRenderMode.cs} (64%) rename src/Components/Web/src/RenderMode/{ServerRenderMode.cs => InteractiveServerRenderMode.cs} (71%) rename src/Components/Web/src/RenderMode/{WebAssemblyRenderMode.cs => InteractiveWebAssemblyRenderMode.cs} (63%) diff --git a/src/Components/Endpoints/src/Builder/RazorComponentDataSourceOptions.cs b/src/Components/Endpoints/src/Builder/RazorComponentDataSourceOptions.cs index 953be437550b..89d9b9e4f43e 100644 --- a/src/Components/Endpoints/src/Builder/RazorComponentDataSourceOptions.cs +++ b/src/Components/Endpoints/src/Builder/RazorComponentDataSourceOptions.cs @@ -17,14 +17,14 @@ internal class RazorComponentDataSourceOptions .Create( equals: (x, y) => (x,y) switch { - (ServerRenderMode, ServerRenderMode) => true, - (WebAssemblyRenderMode, WebAssemblyRenderMode) => true, + (InteractiveServerRenderMode, InteractiveServerRenderMode) => true, + (InteractiveWebAssemblyRenderMode, InteractiveWebAssemblyRenderMode) => true, _ => false, }, getHashCode: obj => obj switch { - ServerRenderMode => 1, - WebAssemblyRenderMode => 2, + InteractiveServerRenderMode => 1, + InteractiveWebAssemblyRenderMode => 2, _ => throw new InvalidOperationException($"Unknown render mode: {obj}"), }); diff --git a/src/Components/Endpoints/src/Discovery/ComponentInfo.cs b/src/Components/Endpoints/src/Discovery/ComponentInfo.cs index 89b52d189d3d..00e74b52dae0 100644 --- a/src/Components/Endpoints/src/Discovery/ComponentInfo.cs +++ b/src/Components/Endpoints/src/Discovery/ComponentInfo.cs @@ -51,20 +51,20 @@ private string GetDebuggerDisplay() private string GetRenderMode() { - if (RenderMode is ServerRenderMode { Prerender: var server }) + if (RenderMode is InteractiveServerRenderMode { Prerender: var server }) { - var size = (nameof(ServerRenderMode).Length - "RenderModeComparer".Length); - return $"RenderModeComparer = {nameof(ServerRenderMode)[0..size]}, Prerendered = {server}"; + var size = (nameof(InteractiveServerRenderMode).Length - "RenderModeComparer".Length); + return $"RenderModeComparer = {nameof(InteractiveServerRenderMode)[0..size]}, Prerendered = {server}"; } - if (RenderMode is WebAssemblyRenderMode { Prerender: var wasm }) + if (RenderMode is InteractiveWebAssemblyRenderMode { Prerender: var wasm }) { - var size = (nameof(WebAssemblyRenderMode).Length - "RenderModeComparer".Length); - return $"RenderModeComparer = {nameof(WebAssemblyRenderMode)[0..size]}, Prerendered = {wasm}"; + var size = (nameof(InteractiveWebAssemblyRenderMode).Length - "RenderModeComparer".Length); + return $"RenderModeComparer = {nameof(InteractiveWebAssemblyRenderMode)[0..size]}, Prerendered = {wasm}"; } - if (RenderMode is AutoRenderMode { Prerender: var auto }) + if (RenderMode is InteractiveAutoRenderMode { Prerender: var auto }) { - var size = (nameof(AutoRenderMode).Length - "RenderModeComparer".Length); - return $"RenderModeComparer = {nameof(AutoRenderMode)[0..size]}, Prerendered = {auto}"; + var size = (nameof(InteractiveAutoRenderMode).Length - "RenderModeComparer".Length); + return $"RenderModeComparer = {nameof(InteractiveAutoRenderMode)[0..size]}, Prerendered = {auto}"; } return "RenderModeComparer = Unknown, Prerendered = Unknown"; diff --git a/src/Components/Endpoints/src/Discovery/RazorComponentApplication.cs b/src/Components/Endpoints/src/Discovery/RazorComponentApplication.cs index 1583c5ce8965..29f20f083e06 100644 --- a/src/Components/Endpoints/src/Discovery/RazorComponentApplication.cs +++ b/src/Components/Endpoints/src/Discovery/RazorComponentApplication.cs @@ -42,15 +42,15 @@ public ISet GetDeclaredRenderModesByDiscoveredComponents() var component = Components[i]; switch (component.RenderMode) { - case ServerRenderMode: - set.Add(RenderMode.Server); + case InteractiveServerRenderMode: + set.Add(RenderMode.InteractiveServer); break; - case WebAssemblyRenderMode: - set.Add(RenderMode.WebAssembly); + case InteractiveWebAssemblyRenderMode: + set.Add(RenderMode.InteractiveWebAssembly); break; - case AutoRenderMode: - set.Add(RenderMode.Server); - set.Add(RenderMode.WebAssembly); + case InteractiveAutoRenderMode: + set.Add(RenderMode.InteractiveServer); + set.Add(RenderMode.InteractiveWebAssembly); break; default: break; diff --git a/src/Components/Endpoints/src/Rendering/EndpointHtmlRenderer.PrerenderingState.cs b/src/Components/Endpoints/src/Rendering/EndpointHtmlRenderer.PrerenderingState.cs index baf91c157786..3b710374d38f 100644 --- a/src/Components/Endpoints/src/Rendering/EndpointHtmlRenderer.PrerenderingState.cs +++ b/src/Components/Endpoints/src/Rendering/EndpointHtmlRenderer.PrerenderingState.cs @@ -65,9 +65,9 @@ internal static void UpdateSaveStateRenderMode(HttpContext httpContext, ICompone { var currentInvocation = mode switch { - ServerRenderMode => InvokedRenderModes.Mode.Server, - WebAssemblyRenderMode => InvokedRenderModes.Mode.WebAssembly, - AutoRenderMode => throw new NotImplementedException("TODO: To be able to support AutoRenderMode, we have to serialize persisted state in both WebAssembly and Server formats, or unify the two formats."), + InteractiveServerRenderMode => InvokedRenderModes.Mode.Server, + InteractiveWebAssemblyRenderMode => InvokedRenderModes.Mode.WebAssembly, + InteractiveAutoRenderMode => throw new NotImplementedException("TODO: To be able to support InteractiveAutoRenderMode, we have to serialize persisted state in both WebAssembly and Server formats, or unify the two formats."), _ => throw new ArgumentException(Resources.FormatUnsupportedRenderMode(mode), nameof(mode)), }; @@ -88,9 +88,9 @@ internal static void UpdateSaveStateRenderMode(HttpContext httpContext, ICompone private static bool ModeEnablesPrerendering(IComponentRenderMode? mode) => mode switch { - ServerRenderMode { Prerender: true } => true, - WebAssemblyRenderMode { Prerender: true } => true, - AutoRenderMode { Prerender: true } => true, + InteractiveServerRenderMode { Prerender: true } => true, + InteractiveWebAssemblyRenderMode { Prerender: true } => true, + InteractiveAutoRenderMode { Prerender: true } => true, _ => false }; diff --git a/src/Components/Endpoints/src/Rendering/SSRRenderModeBoundary.cs b/src/Components/Endpoints/src/Rendering/SSRRenderModeBoundary.cs index f0ac9aaba6db..e560973cb0b8 100644 --- a/src/Components/Endpoints/src/Rendering/SSRRenderModeBoundary.cs +++ b/src/Components/Endpoints/src/Rendering/SSRRenderModeBoundary.cs @@ -43,9 +43,9 @@ public SSRRenderModeBoundary( _renderMode = renderMode; _prerender = renderMode switch { - ServerRenderMode mode => mode.Prerender, - WebAssemblyRenderMode mode => mode.Prerender, - AutoRenderMode mode => mode.Prerender, + InteractiveServerRenderMode mode => mode.Prerender, + InteractiveWebAssemblyRenderMode mode => mode.Prerender, + InteractiveAutoRenderMode mode => mode.Prerender, _ => throw new ArgumentException($"Server-side rendering does not support the render mode '{renderMode}'.", nameof(renderMode)) }; } @@ -65,14 +65,14 @@ private static void AssertRenderModeIsConfigured(HttpContext httpContext, Type c var configuredModes = configuredRenderModesMetadata.ConfiguredRenderModes; // We have to allow for specified rendermodes being subclases of the known types - if (renderMode is ServerRenderMode || renderMode is AutoRenderMode) + if (renderMode is InteractiveServerRenderMode || renderMode is InteractiveAutoRenderMode) { - AssertRenderModeIsConfigured(componentType, renderMode, configuredModes, "AddServerRenderMode"); + AssertRenderModeIsConfigured(componentType, renderMode, configuredModes, "AddServerRenderMode"); } - if (renderMode is WebAssemblyRenderMode || renderMode is AutoRenderMode) + if (renderMode is InteractiveWebAssemblyRenderMode || renderMode is InteractiveAutoRenderMode) { - AssertRenderModeIsConfigured(componentType, renderMode, configuredModes, "AddWebAssemblyRenderMode"); + AssertRenderModeIsConfigured(componentType, renderMode, configuredModes, "AddWebAssemblyRenderMode"); } } @@ -165,13 +165,13 @@ public ComponentMarker ToMarker(HttpContext httpContext, int sequence, object? k var marker = _renderMode switch { - ServerRenderMode server => ComponentMarker.Create(ComponentMarker.ServerMarkerType, server.Prerender, _markerKey), - WebAssemblyRenderMode webAssembly => ComponentMarker.Create(ComponentMarker.WebAssemblyMarkerType, webAssembly.Prerender, _markerKey), - AutoRenderMode auto => ComponentMarker.Create(ComponentMarker.AutoMarkerType, auto.Prerender, _markerKey), + InteractiveServerRenderMode server => ComponentMarker.Create(ComponentMarker.ServerMarkerType, server.Prerender, _markerKey), + InteractiveWebAssemblyRenderMode webAssembly => ComponentMarker.Create(ComponentMarker.WebAssemblyMarkerType, webAssembly.Prerender, _markerKey), + InteractiveAutoRenderMode auto => ComponentMarker.Create(ComponentMarker.AutoMarkerType, auto.Prerender, _markerKey), _ => throw new UnreachableException($"Unknown render mode {_renderMode.GetType().FullName}"), }; - if (_renderMode is ServerRenderMode or AutoRenderMode) + if (_renderMode is InteractiveServerRenderMode or InteractiveAutoRenderMode) { // Lazy because we don't actually want to require a whole chain of services including Data Protection // to be required unless you actually use Server render mode. @@ -181,7 +181,7 @@ public ComponentMarker ToMarker(HttpContext httpContext, int sequence, object? k serverComponentSerializer.SerializeInvocation(ref marker, invocationId, _componentType, parameters); } - if (_renderMode is WebAssemblyRenderMode or AutoRenderMode) + if (_renderMode is InteractiveWebAssemblyRenderMode or InteractiveAutoRenderMode) { WebAssemblyComponentSerializer.SerializeInvocation(ref marker, _componentType, parameters); } diff --git a/src/Components/Endpoints/test/EndpointHtmlRendererTest.cs b/src/Components/Endpoints/test/EndpointHtmlRendererTest.cs index a2c730f1f21c..65c4d0692051 100644 --- a/src/Components/Endpoints/test/EndpointHtmlRendererTest.cs +++ b/src/Components/Endpoints/test/EndpointHtmlRendererTest.cs @@ -53,7 +53,7 @@ public async Task CanRender_ParameterlessComponent_ClientMode() var writer = new StringWriter(); // Act - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new WebAssemblyRenderMode(prerender: false), ParameterView.Empty); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new InteractiveWebAssemblyRenderMode(prerender: false), ParameterView.Empty); await renderer.Dispatcher.InvokeAsync(() => result.WriteTo(writer, HtmlEncoder.Default)); var content = writer.ToString(); var match = Regex.Match(content, ComponentPattern); @@ -76,7 +76,7 @@ public async Task CanPrerender_ParameterlessComponent_ClientMode() var writer = new StringWriter(); // Act - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), RenderMode.WebAssembly, ParameterView.Empty); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), RenderMode.InteractiveWebAssembly, ParameterView.Empty); await renderer.Dispatcher.InvokeAsync(() => result.WriteTo(writer, HtmlEncoder.Default)); var content = writer.ToString(); var match = Regex.Match(content, PrerenderedComponentPattern, RegexOptions.Multiline); @@ -115,7 +115,7 @@ public async Task CanRender_ComponentWithParameters_ClientMode() // Act var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), - new WebAssemblyRenderMode(prerender: false), + new InteractiveWebAssemblyRenderMode(prerender: false), ParameterView.FromDictionary(new Dictionary { { "Name", "Daniel" } @@ -152,7 +152,7 @@ public async Task CanRender_ComponentWithNullParameters_ClientMode() // Act var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), - new WebAssemblyRenderMode(prerender: false), + new InteractiveWebAssemblyRenderMode(prerender: false), ParameterView.FromDictionary(new Dictionary { { "Name", null } @@ -187,7 +187,7 @@ public async Task CanPrerender_ComponentWithParameters_ClientMode() // Act var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), - RenderMode.WebAssembly, + RenderMode.InteractiveWebAssembly, ParameterView.FromDictionary(new Dictionary { { "Name", "Daniel" } @@ -236,7 +236,7 @@ public async Task CanPrerender_ComponentWithNullParameters_ClientMode() // Act var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), - RenderMode.WebAssembly, + RenderMode.InteractiveWebAssembly, ParameterView.FromDictionary(new Dictionary { { "Name", null } @@ -300,7 +300,7 @@ public async Task CanRender_ParameterlessComponent_ServerMode() .ToTimeLimitedDataProtector(); // Act - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new ServerRenderMode(false), ParameterView.Empty); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new InteractiveServerRenderMode(false), ParameterView.Empty); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, ComponentPattern); @@ -332,7 +332,7 @@ public async Task CanPrerender_ParameterlessComponent_ServerMode() .ToTimeLimitedDataProtector(); // Act - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), RenderMode.Server, ParameterView.Empty); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), RenderMode.InteractiveServer, ParameterView.Empty); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, PrerenderedComponentPattern, RegexOptions.Multiline); @@ -376,8 +376,8 @@ public async Task Prerender_ServerAndClientComponentUpdatesInvokedPrerenderModes // Act var parameters = ParameterView.FromDictionary(new Dictionary { { "Name", "SomeName" } }); - var server = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.Server, parameters); - var client = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.WebAssembly, parameters); + var server = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.InteractiveServer, parameters); + var client = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.InteractiveWebAssembly, parameters); // Assert var (_, mode) = Assert.Single(httpContext.Items, (kvp) => kvp.Value is InvokedRenderModes); @@ -393,11 +393,11 @@ public async Task CanRenderMultipleServerComponents() .ToTimeLimitedDataProtector(); // Act - var firstResult = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new ServerRenderMode(true), ParameterView.Empty); + var firstResult = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new InteractiveServerRenderMode(true), ParameterView.Empty); var firstComponent = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(firstResult)); var firstMatch = Regex.Match(firstComponent, PrerenderedComponentPattern, RegexOptions.Multiline); - var secondResult = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new ServerRenderMode(false), ParameterView.Empty); + var secondResult = await renderer.PrerenderComponentAsync(httpContext, typeof(SimpleComponent), new InteractiveServerRenderMode(false), ParameterView.Empty); var secondComponent = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(secondResult)); var secondMatch = Regex.Match(secondComponent, ComponentPattern); @@ -451,7 +451,7 @@ public async Task CanRender_ComponentWithParameters_ServerMode() // Act var parameters = ParameterView.FromDictionary(new Dictionary { { "Name", "SomeName" } }); - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), new ServerRenderMode(false), parameters); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), new InteractiveServerRenderMode(false), parameters); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, ComponentPattern); @@ -490,7 +490,7 @@ public async Task CanRender_ComponentWithNullParameters_ServerMode() // Act var parameters = ParameterView.FromDictionary(new Dictionary { { "Name", null } }); - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), new ServerRenderMode(false), parameters); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), new InteractiveServerRenderMode(false), parameters); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, ComponentPattern); @@ -529,7 +529,7 @@ public async Task CanPrerender_ComponentWithParameters_ServerPrerenderedMode() // Act var parameters = ParameterView.FromDictionary(new Dictionary { { "Name", "SomeName" } }); - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.Server, parameters); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.InteractiveServer, parameters); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, PrerenderedComponentPattern, RegexOptions.Multiline); @@ -580,7 +580,7 @@ public async Task CanPrerender_ComponentWithNullParameters_ServerPrerenderedMode // Act var parameters = ParameterView.FromDictionary(new Dictionary { { "Name", null } }); - var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.Server, parameters); + var result = await renderer.PrerenderComponentAsync(httpContext, typeof(GreetingComponent), RenderMode.InteractiveServer, parameters); var content = await renderer.Dispatcher.InvokeAsync(() => HtmlContentToString(result)); var match = Regex.Match(content, PrerenderedComponentPattern, RegexOptions.Multiline); diff --git a/src/Components/Endpoints/test/HotReloadServiceTests.cs b/src/Components/Endpoints/test/HotReloadServiceTests.cs index afa86e09971e..4250b6c66945 100644 --- a/src/Components/Endpoints/test/HotReloadServiceTests.cs +++ b/src/Components/Endpoints/test/HotReloadServiceTests.cs @@ -187,7 +187,7 @@ private static RazorComponentEndpointDataSource CreateDataSource CreateDataSource() }, @@ -186,7 +186,7 @@ public void NoDiscoveredModesDefaultsToStatic() // Webassembly explicitly configured and missing { - new IComponentRenderMode[] { RenderMode.WebAssembly }, + new IComponentRenderMode[] { RenderMode.InteractiveWebAssembly }, new [] { typeof(ServerEndpointProvider) }, Array.Empty() }, @@ -242,13 +242,13 @@ private RazorComponentEndpointDataSource CreateDataSource GetEndpointBuilders(IComponent 0); } - public override bool Supports(IComponentRenderMode renderMode) => renderMode is ServerRenderMode or AutoRenderMode; + public override bool Supports(IComponentRenderMode renderMode) => renderMode is InteractiveServerRenderMode or InteractiveAutoRenderMode; } private class WebassemblyEndpointProvider : RenderModeEndpointProvider @@ -274,7 +274,7 @@ public override IEnumerable GetEndpointBuilders(IComponent 0); } - public override bool Supports(IComponentRenderMode renderMode) => renderMode is WebAssemblyRenderMode or AutoRenderMode; + public override bool Supports(IComponentRenderMode renderMode) => renderMode is InteractiveWebAssemblyRenderMode or InteractiveAutoRenderMode; } } diff --git a/src/Components/Endpoints/test/SSRRenderModeBoundaryTest.cs b/src/Components/Endpoints/test/SSRRenderModeBoundaryTest.cs index 09e7ec399feb..15cc8b6e92d2 100644 --- a/src/Components/Endpoints/test/SSRRenderModeBoundaryTest.cs +++ b/src/Components/Endpoints/test/SSRRenderModeBoundaryTest.cs @@ -20,9 +20,9 @@ public void DoesNotAssertAboutConfiguredRenderModesOnUnknownEndpoints() httpContext.SetEndpoint(new Endpoint(null, new EndpointMetadataCollection(), null)); // Act/Assert: no exception means we're OK - new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new ServerRenderMode()); - new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new WebAssemblyRenderMode()); - new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new AutoRenderMode()); + new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new InteractiveServerRenderMode()); + new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new InteractiveWebAssemblyRenderMode()); + new SSRRenderModeBoundary(httpContext, typeof(TestComponent), new InteractiveAutoRenderMode()); } [Fact] @@ -96,7 +96,7 @@ public Task SetParametersAsync(ParameterView parameters) => throw new NotImplementedException(); } - class ServerRenderModeSubclass : ServerRenderMode { } - class WebAssemblyRenderModeSubclass : WebAssemblyRenderMode { } - class AutoRenderModeSubclass : AutoRenderMode { } + class ServerRenderModeSubclass : InteractiveServerRenderMode { } + class WebAssemblyRenderModeSubclass : InteractiveWebAssemblyRenderMode { } + class AutoRenderModeSubclass : InteractiveAutoRenderMode { } } diff --git a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServer.razor b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServer.razor index 513134b3fae9..aa7f084f6773 100644 --- a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServer.razor +++ b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServer.razor @@ -1,5 +1,5 @@ @using Microsoft.AspNetCore.Components.Web -@attribute [RenderModeServer] +@attribute [RenderModeInteractiveServer]

Hello @(Name ?? "(null)")!

diff --git a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServerNonPrerendered.razor b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServerNonPrerendered.razor index 76aaea3b855f..689dc5341d1f 100644 --- a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServerNonPrerendered.razor +++ b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingServerNonPrerendered.razor @@ -1,5 +1,5 @@ @using Microsoft.AspNetCore.Components.Web -@attribute [RenderModeServer(false)] +@attribute [RenderModeInteractiveServer(false)]

Hello @(Name ?? "(null)")!

diff --git a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssembly.razor b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssembly.razor index dc1573360f3b..ec1f31503186 100644 --- a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssembly.razor +++ b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssembly.razor @@ -1,5 +1,5 @@ @using Microsoft.AspNetCore.Components.Web -@attribute [RenderModeWebAssembly] +@attribute [RenderModeInteractiveWebAssembly]

Hello @(Name ?? "(null)")!

diff --git a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssemblyNonPrerendered.razor b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssemblyNonPrerendered.razor index 56293c9e76eb..e7ba8104493f 100644 --- a/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssemblyNonPrerendered.razor +++ b/src/Components/Endpoints/test/TestComponents/InteractiveGreetingWebAssemblyNonPrerendered.razor @@ -1,5 +1,5 @@ @using Microsoft.AspNetCore.Components.Web -@attribute [RenderModeWebAssembly(false)] +@attribute [RenderModeInteractiveWebAssembly(false)]

Hello @(Name ?? "(null)")!

diff --git a/src/Components/Endpoints/test/TestComponents/InteractiveWithInteractiveChild.razor b/src/Components/Endpoints/test/TestComponents/InteractiveWithInteractiveChild.razor index f16bb8ded8b0..1856ef793879 100644 --- a/src/Components/Endpoints/test/TestComponents/InteractiveWithInteractiveChild.razor +++ b/src/Components/Endpoints/test/TestComponents/InteractiveWithInteractiveChild.razor @@ -1,5 +1,5 @@ @using Microsoft.AspNetCore.Components.Web -@attribute [RenderModeWebAssembly] +@attribute [RenderModeInteractiveWebAssembly]

This is @nameof(InteractiveWithInteractiveChild)

diff --git a/src/Components/Server/src/Builder/InternalServerRenderMode.cs b/src/Components/Server/src/Builder/InternalServerRenderMode.cs index c690a8a7e25f..4bff43cca838 100644 --- a/src/Components/Server/src/Builder/InternalServerRenderMode.cs +++ b/src/Components/Server/src/Builder/InternalServerRenderMode.cs @@ -5,6 +5,6 @@ namespace Microsoft.AspNetCore.Builder; -internal class InternalServerRenderMode : ServerRenderMode +internal class InternalServerRenderMode : InteractiveServerRenderMode { } diff --git a/src/Components/Server/src/Builder/ServerRazorComponentsEndpointConventionBuilderExtensions.cs b/src/Components/Server/src/Builder/ServerRazorComponentsEndpointConventionBuilderExtensions.cs index 1930aed2448b..1cbef0114897 100644 --- a/src/Components/Server/src/Builder/ServerRazorComponentsEndpointConventionBuilderExtensions.cs +++ b/src/Components/Server/src/Builder/ServerRazorComponentsEndpointConventionBuilderExtensions.cs @@ -12,7 +12,7 @@ namespace Microsoft.AspNetCore.Builder; public static class ServerRazorComponentsEndpointConventionBuilderExtensions { /// - /// Configures the for this application. + /// Configures the application to support the render mode. /// /// The . public static RazorComponentsEndpointConventionBuilder AddServerRenderMode(this RazorComponentsEndpointConventionBuilder builder) diff --git a/src/Components/Server/src/Circuits/RemoteRenderer.cs b/src/Components/Server/src/Circuits/RemoteRenderer.cs index 991e936c1932..40f2f7a87a4c 100644 --- a/src/Components/Server/src/Circuits/RemoteRenderer.cs +++ b/src/Components/Server/src/Circuits/RemoteRenderer.cs @@ -386,7 +386,7 @@ public Task OnRenderCompletedAsync(long incomingBatchId, string? errorMessageOrN protected override IComponent ResolveComponentForRenderMode([DynamicallyAccessedMembers(Component)] Type componentType, int? parentComponentId, IComponentActivator componentActivator, IComponentRenderMode renderMode) => renderMode switch { - ServerRenderMode or AutoRenderMode => componentActivator.CreateInstance(componentType), + InteractiveServerRenderMode or InteractiveAutoRenderMode => componentActivator.CreateInstance(componentType), _ => throw new NotSupportedException($"Cannot create a component of type '{componentType}' because its render mode '{renderMode}' is not supported by interactive server-side rendering."), }; diff --git a/src/Components/Server/src/DependencyInjection/ServerRazorComponentsBuilderExtensions.cs b/src/Components/Server/src/DependencyInjection/ServerRazorComponentsBuilderExtensions.cs index 58ec3c70be01..043ea7d3dfc7 100644 --- a/src/Components/Server/src/DependencyInjection/ServerRazorComponentsBuilderExtensions.cs +++ b/src/Components/Server/src/DependencyInjection/ServerRazorComponentsBuilderExtensions.cs @@ -55,7 +55,7 @@ public override IEnumerable GetEndpointBuilders( { if (renderMode is not InternalServerRenderMode) { - if (renderMode is ServerRenderMode) + if (renderMode is InteractiveServerRenderMode) { throw new InvalidOperationException("Invalid render mode. Use AddServerRenderMode() to configure the Server render mode."); } @@ -73,7 +73,7 @@ public override bool Supports(IComponentRenderMode renderMode) { return renderMode switch { - ServerRenderMode _ or AutoRenderMode _ => true, + InteractiveServerRenderMode _ or InteractiveAutoRenderMode _ => true, _ => false, }; } diff --git a/src/Components/Server/test/Circuits/RenderBatchWriterTest.cs b/src/Components/Server/test/Circuits/RenderBatchWriterTest.cs index 274670dce00a..cb84da770fa6 100644 --- a/src/Components/Server/test/Circuits/RenderBatchWriterTest.cs +++ b/src/Components/Server/test/Circuits/RenderBatchWriterTest.cs @@ -215,7 +215,7 @@ public void CanIncludeReferenceFrames() RenderTreeFrame.Markup(132, "Some markup"), RenderTreeFrame.Text(133, "\n\t "), RenderTreeFrame.NamedEvent(135, "SomeEventType", "Some assigned name"), - RenderTreeFrame.ComponentRenderModeFrame(136, RenderMode.Auto), + RenderTreeFrame.ComponentRenderModeFrame(136, RenderMode.InteractiveAuto), // Testing deduplication RenderTreeFrame.Attribute(200, "Attribute with string value", "String value"), diff --git a/src/Components/Web/src/PublicAPI.Unshipped.txt b/src/Components/Web/src/PublicAPI.Unshipped.txt index b23d101f56fb..dddd2a2fcceb 100644 --- a/src/Components/Web/src/PublicAPI.Unshipped.txt +++ b/src/Components/Web/src/PublicAPI.Unshipped.txt @@ -69,10 +69,6 @@ Microsoft.AspNetCore.Components.SupplyParameterFromFormAttribute.Name.set -> voi Microsoft.AspNetCore.Components.SupplyParameterFromFormAttribute.FormName.get -> string? Microsoft.AspNetCore.Components.SupplyParameterFromFormAttribute.FormName.set -> void Microsoft.AspNetCore.Components.SupplyParameterFromFormAttribute.SupplyParameterFromFormAttribute() -> void -Microsoft.AspNetCore.Components.Web.AutoRenderMode -Microsoft.AspNetCore.Components.Web.AutoRenderMode.AutoRenderMode() -> void -Microsoft.AspNetCore.Components.Web.AutoRenderMode.AutoRenderMode(bool prerender) -> void -Microsoft.AspNetCore.Components.Web.AutoRenderMode.Prerender.get -> bool Microsoft.AspNetCore.Components.Web.HtmlRenderer Microsoft.AspNetCore.Components.Web.HtmlRenderer.BeginRenderingComponent(System.Type! componentType) -> Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent Microsoft.AspNetCore.Components.Web.HtmlRenderer.BeginRenderingComponent(System.Type! componentType, Microsoft.AspNetCore.Components.ParameterView parameters) -> Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent @@ -91,35 +87,39 @@ Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent.HtmlRootComp Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent.QuiescenceTask.get -> System.Threading.Tasks.Task! Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent.ToHtmlString() -> string! Microsoft.AspNetCore.Components.Web.HtmlRendering.HtmlRootComponent.WriteHtmlTo(System.IO.TextWriter! output) -> void +Microsoft.AspNetCore.Components.Web.InteractiveAutoRenderMode +Microsoft.AspNetCore.Components.Web.InteractiveAutoRenderMode.InteractiveAutoRenderMode() -> void +Microsoft.AspNetCore.Components.Web.InteractiveAutoRenderMode.InteractiveAutoRenderMode(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.InteractiveAutoRenderMode.Prerender.get -> bool +Microsoft.AspNetCore.Components.Web.InteractiveServerRenderMode +Microsoft.AspNetCore.Components.Web.InteractiveServerRenderMode.InteractiveServerRenderMode() -> void +Microsoft.AspNetCore.Components.Web.InteractiveServerRenderMode.InteractiveServerRenderMode(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.InteractiveServerRenderMode.Prerender.get -> bool +Microsoft.AspNetCore.Components.Web.InteractiveWebAssemblyRenderMode +Microsoft.AspNetCore.Components.Web.InteractiveWebAssemblyRenderMode.InteractiveWebAssemblyRenderMode() -> void +Microsoft.AspNetCore.Components.Web.InteractiveWebAssemblyRenderMode.InteractiveWebAssemblyRenderMode(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.InteractiveWebAssemblyRenderMode.Prerender.get -> bool Microsoft.AspNetCore.Components.Web.RenderMode -Microsoft.AspNetCore.Components.Web.RenderModeAutoAttribute -Microsoft.AspNetCore.Components.Web.RenderModeAutoAttribute.RenderModeAutoAttribute() -> void -Microsoft.AspNetCore.Components.Web.RenderModeAutoAttribute.RenderModeAutoAttribute(bool prerender) -> void -Microsoft.AspNetCore.Components.Web.RenderModeServerAttribute -Microsoft.AspNetCore.Components.Web.RenderModeServerAttribute.RenderModeServerAttribute() -> void -Microsoft.AspNetCore.Components.Web.RenderModeServerAttribute.RenderModeServerAttribute(bool prerender) -> void -Microsoft.AspNetCore.Components.Web.RenderModeWebAssemblyAttribute -Microsoft.AspNetCore.Components.Web.RenderModeWebAssemblyAttribute.RenderModeWebAssemblyAttribute() -> void -Microsoft.AspNetCore.Components.Web.RenderModeWebAssemblyAttribute.RenderModeWebAssemblyAttribute(bool prerender) -> void -Microsoft.AspNetCore.Components.Web.ServerRenderMode -Microsoft.AspNetCore.Components.Web.ServerRenderMode.Prerender.get -> bool -Microsoft.AspNetCore.Components.Web.ServerRenderMode.ServerRenderMode() -> void -Microsoft.AspNetCore.Components.Web.ServerRenderMode.ServerRenderMode(bool prerender) -> void -Microsoft.AspNetCore.Components.Web.WebAssemblyRenderMode -Microsoft.AspNetCore.Components.Web.WebAssemblyRenderMode.Prerender.get -> bool -Microsoft.AspNetCore.Components.Web.WebAssemblyRenderMode.WebAssemblyRenderMode() -> void -Microsoft.AspNetCore.Components.Web.WebAssemblyRenderMode.WebAssemblyRenderMode(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveAutoAttribute +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveAutoAttribute.RenderModeInteractiveAutoAttribute() -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveAutoAttribute.RenderModeInteractiveAutoAttribute(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveServerAttribute +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveServerAttribute.RenderModeInteractiveServerAttribute() -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveServerAttribute.RenderModeInteractiveServerAttribute(bool prerender) -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveWebAssemblyAttribute +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveWebAssemblyAttribute.RenderModeInteractiveWebAssemblyAttribute() -> void +Microsoft.AspNetCore.Components.Web.RenderModeInteractiveWebAssemblyAttribute.RenderModeInteractiveWebAssemblyAttribute(bool prerender) -> void override Microsoft.AspNetCore.Components.Forms.Editor.OnParametersSet() -> void override Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.Dispatcher.get -> Microsoft.AspNetCore.Components.Dispatcher! override Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.HandleException(System.Exception! exception) -> void override Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.UpdateDisplayAsync(in Microsoft.AspNetCore.Components.RenderTree.RenderBatch renderBatch) -> System.Threading.Tasks.Task! -override Microsoft.AspNetCore.Components.Web.RenderModeAutoAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! -override Microsoft.AspNetCore.Components.Web.RenderModeServerAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! -override Microsoft.AspNetCore.Components.Web.RenderModeWebAssemblyAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! +override Microsoft.AspNetCore.Components.Web.RenderModeInteractiveAutoAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! +override Microsoft.AspNetCore.Components.Web.RenderModeInteractiveServerAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! +override Microsoft.AspNetCore.Components.Web.RenderModeInteractiveWebAssemblyAttribute.Mode.get -> Microsoft.AspNetCore.Components.IComponentRenderMode! static Microsoft.AspNetCore.Components.Forms.Mapping.SupplyParameterFromFormServiceCollectionExtensions.AddSupplyValueFromFormProvider(this Microsoft.Extensions.DependencyInjection.IServiceCollection! serviceCollection) -> Microsoft.Extensions.DependencyInjection.IServiceCollection! -static Microsoft.AspNetCore.Components.Web.RenderMode.Auto.get -> Microsoft.AspNetCore.Components.Web.AutoRenderMode! -static Microsoft.AspNetCore.Components.Web.RenderMode.Server.get -> Microsoft.AspNetCore.Components.Web.ServerRenderMode! -static Microsoft.AspNetCore.Components.Web.RenderMode.WebAssembly.get -> Microsoft.AspNetCore.Components.Web.WebAssemblyRenderMode! +static Microsoft.AspNetCore.Components.Web.RenderMode.InteractiveAuto.get -> Microsoft.AspNetCore.Components.Web.InteractiveAutoRenderMode! +static Microsoft.AspNetCore.Components.Web.RenderMode.InteractiveServer.get -> Microsoft.AspNetCore.Components.Web.InteractiveServerRenderMode! +static Microsoft.AspNetCore.Components.Web.RenderMode.InteractiveWebAssembly.get -> Microsoft.AspNetCore.Components.Web.InteractiveWebAssemblyRenderMode! virtual Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.RenderChildComponent(System.IO.TextWriter! output, ref Microsoft.AspNetCore.Components.RenderTree.RenderTreeFrame componentFrame) -> void virtual Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.WriteComponentHtml(int componentId, System.IO.TextWriter! output) -> void virtual Microsoft.AspNetCore.Components.RenderTree.WebRenderer.GetWebRendererId() -> int diff --git a/src/Components/Web/src/RenderMode/AutoRenderMode.cs b/src/Components/Web/src/RenderMode/InteractiveAutoRenderMode.cs similarity index 64% rename from src/Components/Web/src/RenderMode/AutoRenderMode.cs rename to src/Components/Web/src/RenderMode/InteractiveAutoRenderMode.cs index 5ff58281cf66..4368795c01dd 100644 --- a/src/Components/Web/src/RenderMode/AutoRenderMode.cs +++ b/src/Components/Web/src/RenderMode/InteractiveAutoRenderMode.cs @@ -4,22 +4,22 @@ namespace Microsoft.AspNetCore.Components.Web; /// -/// A indicating that the component's render mode should be determined automatically based on a policy. +/// A indicating that the component should be interactive, with its hosting platform determined automatically based on a policy. /// -public class AutoRenderMode : IComponentRenderMode +public class InteractiveAutoRenderMode : IComponentRenderMode { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public AutoRenderMode() : this(true) + public InteractiveAutoRenderMode() : this(true) { } /// - /// Constructs an instance of + /// Constructs an instance of /// /// A flag indicating whether the component should first prerender on the server. The default value is true. - public AutoRenderMode(bool prerender) + public InteractiveAutoRenderMode(bool prerender) { Prerender = prerender; } diff --git a/src/Components/Web/src/RenderMode/ServerRenderMode.cs b/src/Components/Web/src/RenderMode/InteractiveServerRenderMode.cs similarity index 71% rename from src/Components/Web/src/RenderMode/ServerRenderMode.cs rename to src/Components/Web/src/RenderMode/InteractiveServerRenderMode.cs index 2928be842e26..3b3fd1cd2ff9 100644 --- a/src/Components/Web/src/RenderMode/ServerRenderMode.cs +++ b/src/Components/Web/src/RenderMode/InteractiveServerRenderMode.cs @@ -6,20 +6,20 @@ namespace Microsoft.AspNetCore.Components.Web; /// /// A indicating that the component should be rendered interactively on the server using Blazor Server hosting. /// -public class ServerRenderMode : IComponentRenderMode +public class InteractiveServerRenderMode : IComponentRenderMode { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public ServerRenderMode() : this(true) + public InteractiveServerRenderMode() : this(true) { } /// - /// Constructs an instance of + /// Constructs an instance of /// /// A flag indicating whether the component should first prerender on the server. The default value is true. - public ServerRenderMode(bool prerender) + public InteractiveServerRenderMode(bool prerender) { Prerender = prerender; } diff --git a/src/Components/Web/src/RenderMode/WebAssemblyRenderMode.cs b/src/Components/Web/src/RenderMode/InteractiveWebAssemblyRenderMode.cs similarity index 63% rename from src/Components/Web/src/RenderMode/WebAssemblyRenderMode.cs rename to src/Components/Web/src/RenderMode/InteractiveWebAssemblyRenderMode.cs index d270a39e061b..5aedf3df8995 100644 --- a/src/Components/Web/src/RenderMode/WebAssemblyRenderMode.cs +++ b/src/Components/Web/src/RenderMode/InteractiveWebAssemblyRenderMode.cs @@ -4,22 +4,22 @@ namespace Microsoft.AspNetCore.Components.Web; /// -/// A indicating that the component should be rendered on the client using WebAssembly. +/// A indicating that the component should be rendered interactively on the client using WebAssembly. /// -public class WebAssemblyRenderMode : IComponentRenderMode +public class InteractiveWebAssemblyRenderMode : IComponentRenderMode { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public WebAssemblyRenderMode() : this(true) + public InteractiveWebAssemblyRenderMode() : this(true) { } /// - /// Constructs an instance of + /// Constructs an instance of /// /// A flag indicating whether the component should first prerender on the server. The default value is true. - public WebAssemblyRenderMode(bool prerender) + public InteractiveWebAssemblyRenderMode(bool prerender) { Prerender = prerender; } diff --git a/src/Components/Web/src/RenderMode/RenderMode.cs b/src/Components/Web/src/RenderMode/RenderMode.cs index dcb53491d565..eed3219eb520 100644 --- a/src/Components/Web/src/RenderMode/RenderMode.cs +++ b/src/Components/Web/src/RenderMode/RenderMode.cs @@ -12,16 +12,16 @@ public static class RenderMode /// Gets an that represents rendering interactively on the server via Blazor Server hosting /// with server-side prerendering. /// - public static ServerRenderMode Server { get; } = new(); + public static InteractiveServerRenderMode InteractiveServer { get; } = new(); /// /// Gets an that represents rendering interactively on the client via Blazor WebAssembly hosting /// with server-side prerendering. /// - public static WebAssemblyRenderMode WebAssembly { get; } = new(); + public static InteractiveWebAssemblyRenderMode InteractiveWebAssembly { get; } = new(); /// /// Gets an that means the render mode will be determined automatically based on a policy. /// - public static AutoRenderMode Auto { get; } = new(); + public static InteractiveAutoRenderMode InteractiveAuto { get; } = new(); } diff --git a/src/Components/Web/src/RenderMode/TemporaryRenderModeAttributes.cs b/src/Components/Web/src/RenderMode/TemporaryRenderModeAttributes.cs index 2f96d74a6bbb..4ca17cd802e3 100644 --- a/src/Components/Web/src/RenderMode/TemporaryRenderModeAttributes.cs +++ b/src/Components/Web/src/RenderMode/TemporaryRenderModeAttributes.cs @@ -7,22 +7,22 @@ namespace Microsoft.AspNetCore.Components.Web; /// Temporary attribute for indicating that a component should render interactively on the server. /// This will later be replaced by a @rendermode directive. /// -public class RenderModeServerAttribute : RenderModeAttribute +public class RenderModeInteractiveServerAttribute : RenderModeAttribute { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public RenderModeServerAttribute() : this(true) + public RenderModeInteractiveServerAttribute() : this(true) { } /// - /// Constructs an instance of . + /// Constructs an instance of . /// /// A flag indicating whether to prerender the component on the server. The default value is true. - public RenderModeServerAttribute(bool prerender) + public RenderModeInteractiveServerAttribute(bool prerender) { - Mode = new ServerRenderMode(prerender); + Mode = new InteractiveServerRenderMode(prerender); } /// @@ -33,22 +33,22 @@ public RenderModeServerAttribute(bool prerender) /// Temporary attribute for indicating that a component should render interactively using WebAssembly. /// This will later be replaced by a @rendermode directive. /// -public class RenderModeWebAssemblyAttribute : RenderModeAttribute +public class RenderModeInteractiveWebAssemblyAttribute : RenderModeAttribute { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public RenderModeWebAssemblyAttribute() : this(true) + public RenderModeInteractiveWebAssemblyAttribute() : this(true) { } /// - /// Constructs an instance of . + /// Constructs an instance of . /// /// A flag indicating whether to prerender the component on the server. The default value is true. - public RenderModeWebAssemblyAttribute(bool prerender) + public RenderModeInteractiveWebAssemblyAttribute(bool prerender) { - Mode = new WebAssemblyRenderMode(prerender); + Mode = new InteractiveWebAssemblyRenderMode(prerender); } /// @@ -60,22 +60,22 @@ public RenderModeWebAssemblyAttribute(bool prerender) /// a mode automatically determined. /// This will later be replaced by a @rendermode directive. /// -public class RenderModeAutoAttribute : RenderModeAttribute +public class RenderModeInteractiveAutoAttribute : RenderModeAttribute { /// - /// Constructs an instance of . + /// Constructs an instance of . /// - public RenderModeAutoAttribute() : this(true) + public RenderModeInteractiveAutoAttribute() : this(true) { } /// - /// Constructs an instance of . + /// Constructs an instance of . /// /// A flag indicating whether to prerender the component on the server. The default value is true. - public RenderModeAutoAttribute(bool prerender) + public RenderModeInteractiveAutoAttribute(bool prerender) { - Mode = new AutoRenderMode(prerender); + Mode = new InteractiveAutoRenderMode(prerender); } /// diff --git a/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRazorComponentsEndpointConventionBuilderExtensions.cs b/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRazorComponentsEndpointConventionBuilderExtensions.cs index da9dce4b3a4c..086b6105b17a 100644 --- a/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRazorComponentsEndpointConventionBuilderExtensions.cs +++ b/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRazorComponentsEndpointConventionBuilderExtensions.cs @@ -13,7 +13,7 @@ namespace Microsoft.AspNetCore.Builder; public static class WebAssemblyRazorComponentsEndpointConventionBuilderExtensions { /// - /// Configures the for this application. + /// Configures the application to support the render mode. /// /// The . public static RazorComponentsEndpointConventionBuilder AddWebAssemblyRenderMode( diff --git a/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRenderModeWithOptions.cs b/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRenderModeWithOptions.cs index ed279b4a360f..1a6650aaa0e1 100644 --- a/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRenderModeWithOptions.cs +++ b/src/Components/WebAssembly/Server/src/Builder/WebAssemblyRenderModeWithOptions.cs @@ -6,7 +6,7 @@ namespace Microsoft.AspNetCore.Builder; -internal class WebAssemblyRenderModeWithOptions(WebAssemblyComponentsEndpointOptions? options) : WebAssemblyRenderMode +internal class WebAssemblyRenderModeWithOptions(WebAssemblyComponentsEndpointOptions? options) : InteractiveWebAssemblyRenderMode { public WebAssemblyComponentsEndpointOptions? EndpointOptions => options; } diff --git a/src/Components/WebAssembly/Server/src/WebAssemblyRazorComponentsBuilderExtensions.cs b/src/Components/WebAssembly/Server/src/WebAssemblyRazorComponentsBuilderExtensions.cs index b06a812c904f..43217dd04290 100644 --- a/src/Components/WebAssembly/Server/src/WebAssemblyRazorComponentsBuilderExtensions.cs +++ b/src/Components/WebAssembly/Server/src/WebAssemblyRazorComponentsBuilderExtensions.cs @@ -36,7 +36,7 @@ public override IEnumerable GetEndpointBuilders(IComponent { if (renderMode is not WebAssemblyRenderModeWithOptions wasmWithOptions) { - if (renderMode is WebAssemblyRenderMode) + if (renderMode is InteractiveWebAssemblyRenderMode) { throw new InvalidOperationException("Invalid render mode. Use AddWebAssemblyRenderMode(Action) to configure the WebAssembly render mode."); } @@ -62,7 +62,7 @@ public override IEnumerable GetEndpointBuilders(IComponent } public override bool Supports(IComponentRenderMode renderMode) - => renderMode is WebAssemblyRenderMode or AutoRenderMode; + => renderMode is InteractiveWebAssemblyRenderMode or InteractiveAutoRenderMode; private class EndpointRouteBuilder : IEndpointRouteBuilder { diff --git a/src/Components/WebAssembly/WebAssembly/src/Rendering/WebAssemblyRenderer.cs b/src/Components/WebAssembly/WebAssembly/src/Rendering/WebAssemblyRenderer.cs index 47565b9e07bf..29085088e69e 100644 --- a/src/Components/WebAssembly/WebAssembly/src/Rendering/WebAssemblyRenderer.cs +++ b/src/Components/WebAssembly/WebAssembly/src/Rendering/WebAssemblyRenderer.cs @@ -221,7 +221,7 @@ protected override void HandleException(Exception exception) protected override IComponent ResolveComponentForRenderMode([DynamicallyAccessedMembers(Component)] Type componentType, int? parentComponentId, IComponentActivator componentActivator, IComponentRenderMode renderMode) => renderMode switch { - WebAssemblyRenderMode or AutoRenderMode => componentActivator.CreateInstance(componentType), + InteractiveWebAssemblyRenderMode or InteractiveAutoRenderMode => componentActivator.CreateInstance(componentType), _ => throw new NotSupportedException($"Cannot create a component of type '{componentType}' because its render mode '{renderMode}' is not supported by WebAssembly rendering."), }; diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor index e9d423e78f14..a3a3fb1946fb 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor @@ -176,12 +176,12 @@ else { return renderMode switch { - RenderModeId.ServerPrerendered => RenderMode.Server, - RenderModeId.ServerNonPrerendered => new ServerRenderMode(false), - RenderModeId.WebAssemblyPrerendered => RenderMode.WebAssembly, - RenderModeId.WebAssemblyNonPrerendered => new WebAssemblyRenderMode(false), - RenderModeId.AutoPrerendered => RenderMode.Auto, - RenderModeId.AutoNonPrerendered => new AutoRenderMode(false), + RenderModeId.ServerPrerendered => RenderMode.InteractiveServer, + RenderModeId.ServerNonPrerendered => new InteractiveServerRenderMode(false), + RenderModeId.WebAssemblyPrerendered => RenderMode.InteractiveWebAssembly, + RenderModeId.WebAssemblyNonPrerendered => new InteractiveWebAssemblyRenderMode(false), + RenderModeId.AutoPrerendered => InteractiveAutoerMode.Auto, + RenderModeId.AutoNonPrerendered => new InteractiveAutoRenderMode(false), _ => throw new InvalidOperationException($"Unknown render mode: {renderMode}"), }; } diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/ServerInteractiveCounter.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/ServerInteractiveCounter.razor index 7ca2b4b0468c..3c1cc95a98a7 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/ServerInteractiveCounter.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/ServerInteractiveCounter.razor @@ -1,4 +1,4 @@ -@attribute [RenderModeServer] +@attribute [RenderModeInteractiveServer] Server counter diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Auth/InteractiveAuthenticationState.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Auth/InteractiveAuthenticationState.razor index c4383dc6eb4e..9f1f897bea92 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Auth/InteractiveAuthenticationState.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Auth/InteractiveAuthenticationState.razor @@ -1,5 +1,5 @@ @page "/auth/interactive-authentication-state" -@attribute [RenderModeServer] +@attribute [RenderModeInteractiveServer] @inject NavigationManager Nav @using BasicTestApp.AuthTest diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/CallSiteInteractiveComponents.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/CallSiteInteractiveComponents.razor index 92fe608662c3..0bf9207bdd74 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/CallSiteInteractiveComponents.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/CallSiteInteractiveComponents.razor @@ -5,13 +5,13 @@ @if (ServerIncrementAmount.HasValue) { - +
} @if (WebAssemblyIncrementAmount.HasValue) { - +
} diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/EnhancedNav/PageWithInteractiveComponentsThatNavigate.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/EnhancedNav/PageWithInteractiveComponentsThatNavigate.razor index a16e927c4231..42709b0405d8 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/EnhancedNav/PageWithInteractiveComponentsThatNavigate.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/EnhancedNav/PageWithInteractiveComponentsThatNavigate.razor @@ -32,11 +32,11 @@ else { if (string.Equals("server", RenderMode, StringComparison.OrdinalIgnoreCase)) { - _renderMode = new ServerRenderMode(prerender: false); + _renderMode = new InteractiveServerRenderMode(prerender: false); } else if (string.Equals("webassembly", RenderMode, StringComparison.OrdinalIgnoreCase)) { - _renderMode = new WebAssemblyRenderMode(prerender: false); + _renderMode = new InteractiveWebAssemblyRenderMode(prerender: false); } } } diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Interactivity/VirtualizationTransitionToInteractivity.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Interactivity/VirtualizationTransitionToInteractivity.razor index aa5ec155812a..5c750517e43c 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Interactivity/VirtualizationTransitionToInteractivity.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Interactivity/VirtualizationTransitionToInteractivity.razor @@ -3,11 +3,11 @@

Server

- +

WebAssembly

- + @code { private readonly string[] _items = Enumerable.Range(1, 50) diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Rendering/LargeHtml.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Rendering/LargeHtml.razor index 435d7d150ad5..f201c2243509 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Rendering/LargeHtml.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Pages/Rendering/LargeHtml.razor @@ -1,10 +1,10 @@ @page "/large-html-server"

WebAssembly with pre-rendering

- +

Server with pre-rendering

- +

Server without pre-rendering

- + diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Root.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Root.razor index dda0852a805a..2673a96e0858 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Root.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Root.razor @@ -9,7 +9,7 @@ - + diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor index 11ee7b1a9045..2b7d39f349f2 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Components/Pages/Counter.razor @@ -1,6 +1,6 @@ @page "/counter" @*#if (!InteractiveAtRoot) --> -@attribute [RenderModeServer] +@attribute [RenderModeInteractiveServer] ##endif*@ Counter diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs index 46fc42f142e6..c241a8dd7610 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.Main.cs @@ -17,12 +17,12 @@ public static void Main(string[] args) #else builder.Services.AddRazorComponents() #if (UseServer && UseWebAssembly) - .AddServerComponents() - .AddWebAssemblyComponents(); + .AddInteractiveServerComponents() + .AddInteractiveWebAssemblyComponents(); #elif(UseServer) - .AddServerComponents(); + .AddInteractiveServerComponents(); #elif(UseWebAssembly) - .AddWebAssemblyComponents(); + .AddInteractiveWebAssemblyComponents(); #endif #endif @@ -54,15 +54,15 @@ public static void Main(string[] args) #if (UseServer && UseWebAssembly) app.MapRazorComponents() - .AddServerRenderMode() - .AddWebAssemblyRenderMode() + .AddInteractiveServerRenderMode() + .AddInteractiveWebAssemblyRenderMode() .AddAdditionalAssemblies(typeof(Counter).Assembly); #elif (UseServer) app.MapRazorComponents() - .AddServerRenderMode(); + .AddInteractiveServerRenderMode(); #elif (UseWebAssembly) app.MapRazorComponents() - .AddWebAssemblyRenderMode() + .AddInteractiveWebAssemblyRenderMode() .AddAdditionalAssemblies(typeof(Counter).Assembly); #else app.MapRazorComponents(); diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs index 66ccd5be22e1..5470d2ce484d 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/BlazorWeb-CSharp/Program.cs @@ -11,12 +11,12 @@ #else builder.Services.AddRazorComponents() #if (UseServer && UseWebAssembly) - .AddServerComponents() - .AddWebAssemblyComponents(); + .AddInteractiveServerComponents() + .AddInteractiveWebAssemblyComponents(); #elif(UseServer) - .AddServerComponents(); + .AddInteractiveServerComponents(); #elif(UseWebAssembly) - .AddWebAssemblyComponents(); + .AddInteractiveWebAssemblyComponents(); #endif #endif @@ -48,15 +48,15 @@ #if (UseServer && UseWebAssembly) app.MapRazorComponents() - .AddServerRenderMode() - .AddWebAssemblyRenderMode() + .AddInteractiveServerRenderMode() + .AddInteractiveWebAssemblyRenderMode() .AddAdditionalAssemblies(typeof(Counter).Assembly); #elif (UseServer) app.MapRazorComponents() - .AddServerRenderMode(); + .AddInteractiveServerRenderMode(); #elif (UseWebAssembly) app.MapRazorComponents() - .AddWebAssemblyRenderMode() + .AddInteractiveWebAssemblyRenderMode() .AddAdditionalAssemblies(typeof(Counter).Assembly); #else app.MapRazorComponents(); From 91dd6282ad05910e2b1dbf9ecb08f8e6ecc858d9 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 12:11:57 +0100 Subject: [PATCH 17/23] Fix typo --- .../Components/InteractiveStreamingRenderingComponent.razor | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor index a3a3fb1946fb..28ab8cd3690a 100644 --- a/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor +++ b/src/Components/test/testassets/Components.TestServer/RazorComponents/Components/InteractiveStreamingRenderingComponent.razor @@ -180,7 +180,7 @@ else RenderModeId.ServerNonPrerendered => new InteractiveServerRenderMode(false), RenderModeId.WebAssemblyPrerendered => RenderMode.InteractiveWebAssembly, RenderModeId.WebAssemblyNonPrerendered => new InteractiveWebAssemblyRenderMode(false), - RenderModeId.AutoPrerendered => InteractiveAutoerMode.Auto, + RenderModeId.AutoPrerendered => RenderMode.InteractiveAuto, RenderModeId.AutoNonPrerendered => new InteractiveAutoRenderMode(false), _ => throw new InvalidOperationException($"Unknown render mode: {renderMode}"), }; From a3c10f30fe2a66fd63053b9d3d066c9505c7e758 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 12:29:41 +0100 Subject: [PATCH 18/23] More test updates --- .../test/PersistComponentStateTagHelperTest.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Mvc/Mvc.TagHelpers/test/PersistComponentStateTagHelperTest.cs b/src/Mvc/Mvc.TagHelpers/test/PersistComponentStateTagHelperTest.cs index 9c8e36f1d1a9..e71189162e78 100644 --- a/src/Mvc/Mvc.TagHelpers/test/PersistComponentStateTagHelperTest.cs +++ b/src/Mvc/Mvc.TagHelpers/test/PersistComponentStateTagHelperTest.cs @@ -81,7 +81,7 @@ public async Task ExecuteAsync_RendersWebAssemblyStateImplicitlyWhenAWebAssembly ViewContext = GetViewContext() }; - EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.WebAssembly); + EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.InteractiveWebAssembly); var context = GetTagHelperContext(); var output = GetTagHelperOutput(); @@ -129,7 +129,7 @@ public async Task ExecuteAsync_RendersServerStateImplicitlyWhenAServerComponentW ViewContext = GetViewContext() }; - EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.Server); + EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.InteractiveServer); var context = GetTagHelperContext(); var output = GetTagHelperOutput(); @@ -154,8 +154,8 @@ public async Task ExecuteAsync_ThrowsIfItCantInferThePersistMode() ViewContext = GetViewContext() }; - EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.Server); - EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.WebAssembly); + EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.InteractiveServer); + EndpointHtmlRenderer.UpdateSaveStateRenderMode(tagHelper.ViewContext.HttpContext, Components.Web.RenderMode.InteractiveWebAssembly); var context = GetTagHelperContext(); var output = GetTagHelperOutput(); From 416db9c85c8e500af67a3246c9c1d7968ddb472c Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 12:52:09 +0100 Subject: [PATCH 19/23] Yet more renames --- .../ComponentRenderingFunctionalTests.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Mvc/test/Mvc.FunctionalTests/ComponentRenderingFunctionalTests.cs b/src/Mvc/test/Mvc.FunctionalTests/ComponentRenderingFunctionalTests.cs index 1b0f3cb2dd83..148b3ee417ce 100644 --- a/src/Mvc/test/Mvc.FunctionalTests/ComponentRenderingFunctionalTests.cs +++ b/src/Mvc/test/Mvc.FunctionalTests/ComponentRenderingFunctionalTests.cs @@ -40,7 +40,7 @@ public async Task Renders_RoutingComponent() { // Arrange & Act var client = CreateClient(Factory.WithWebHostBuilder(builder => - builder.ConfigureServices(services => services.AddRazorComponents().AddServerComponents()))); + builder.ConfigureServices(services => services.AddRazorComponents().AddInteractiveServerComponents()))); var response = await client.GetAsync("http://localhost/components/routable"); @@ -71,7 +71,7 @@ public async Task Renders_RoutingComponent_UsingRazorComponents_Prerenderer() { // Arrange & Act var client = CreateClient(Factory.WithWebHostBuilder(builder => - builder.ConfigureServices(services => services.AddRazorComponents().AddServerComponents()))); + builder.ConfigureServices(services => services.AddRazorComponents().AddInteractiveServerComponents()))); var response = await client.GetAsync("http://localhost/components/routable"); @@ -87,7 +87,7 @@ public async Task Renders_ThrowingComponent_UsingRazorComponents_Prerenderer() { // Arrange & Act var client = CreateClient(Factory.WithWebHostBuilder(builder => - builder.ConfigureServices(services => services.AddRazorComponents().AddServerComponents()))); + builder.ConfigureServices(services => services.AddRazorComponents().AddInteractiveServerComponents()))); var response = await client.GetAsync("http://localhost/components/throws"); From 8d6dcb3375cfb04cacaaafc8f7bdee002249007a Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 13:19:32 +0100 Subject: [PATCH 20/23] Clarify meaning of Auto in VS --- .../content/BlazorWeb-CSharp/.template.config/template.json | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json index 262971fa748a..971eb62028ba 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/template.json @@ -235,18 +235,22 @@ "choices": [ { "choice": "None", + "displayName": "None", "description": "No interactivity (static server rendering only)" }, { "choice": "Server", + "displayName": "Server", "description": "Runs on the server" }, { "choice": "WebAssembly", + "displayName": "WebAssembly", "description": "Runs in the browser using WebAssembly" }, { "choice": "Auto", + "displayName": "Auto (Server and WebAssembly)", "description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly" } ] From fbd860f3d8716d467ffaf60c488c2a1363962561 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 13:19:46 +0100 Subject: [PATCH 21/23] Update templatestrings --- .../.template.config/localize/templatestrings.cs.json | 4 ++++ .../.template.config/localize/templatestrings.de.json | 4 ++++ .../.template.config/localize/templatestrings.en.json | 4 ++++ .../.template.config/localize/templatestrings.es.json | 4 ++++ .../.template.config/localize/templatestrings.fr.json | 4 ++++ .../.template.config/localize/templatestrings.it.json | 4 ++++ .../.template.config/localize/templatestrings.ja.json | 4 ++++ .../.template.config/localize/templatestrings.ko.json | 4 ++++ .../.template.config/localize/templatestrings.pl.json | 4 ++++ .../.template.config/localize/templatestrings.pt-BR.json | 4 ++++ .../.template.config/localize/templatestrings.ru.json | 4 ++++ .../.template.config/localize/templatestrings.tr.json | 4 ++++ .../.template.config/localize/templatestrings.zh-Hans.json | 4 ++++ .../.template.config/localize/templatestrings.zh-Hant.json | 4 ++++ 14 files changed, 56 insertions(+) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json index f4bfb9efbddd..069f5694009b 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.cs.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Číslo portu, který se má použít pro koncový bod IIS Express HTTPS v souboru launchSettings.json. Tato možnost se dá použít jenom v případě, že se nepoužije parametr no-https (no-https se bude ignorovat, pokud se použije IndividualAuth nebo OrganizationalAuth).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json index f950499f1531..96805c77240a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.de.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Portnummer, die für den IIS Express HTTPS Endpunkt in launchSettings.json verwendet werden soll. Diese Option ist nur anwendbar, wenn der Parameter no-https nicht verwendet wird (no-https wird ignoriert, wenn entweder IndividualAuth oder OrganizationalAuth verwendet wird).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json index 8b0b7c101bd3..60d16e15ffd9 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.en.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Port number to use for the IIS Express HTTPS endpoint in launchSettings.json. This option is only applicable when the parameter no-https is not used (no-https will be ignored if either IndividualAuth or OrganizationalAuth is used).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json index 28c49f5cb2d5..91d5403e0fbf 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.es.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Número de puerto que se va a usar para el punto de conexión HTTPS de IIS Express en launchSettings.json. Esta opción solo es aplicable cuando no se usa el parámetro no-https (no-https se omitirá si se usa IndividualAuth o OrganizationalAuth).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json index 1050b1b4172b..044f40bacc91 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.fr.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Numéro de port à utiliser pour le point de terminaison HTTPS IIS Express dans launchSettings.json. Cette option s’applique uniquement lorsque le paramètre no-https n’est pas utilisé (no-https sera ignoré si IndividualAuth ou OrganizationalAuth est utilisé).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json index 2f9635d9669b..09c3ebfff2c2 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.it.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Numero di porta da usare per l'endpoint HTTPS IIS Express in launchSettings.json. Questa opzione è applicabile solo quando il parametro no-https non viene usato (no-https verrà ignorato se si usa IndividualAuth o OrganizationalAuth).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json index 2e4ad40919fb..f48aecfb9534 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ja.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "launchSettings.json で IIS Express HTTPS エンドポイントに使用するポート番号。このオプションは、HTTPS 以外のパラメーターが使用されていない場合にのみ適用されます (IndividualAuth または OrganizationalAuth が使用されている場合は、HTTPS 以外は無視されます)。", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json index c0c0a80acc9c..020ab522da02 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ko.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "launchSettings.json의 IIS Express 엔드포인트에 사용할 포트 번호입니다. 이 옵션은 매개 변수 no-https가 사용되지 않은 경우에만 적용됩니다(IndividualAuth 또는 OrganizationalAuth가 사용되는 경우 no-https는 무시됨).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json index 6041f294ac98..43e2693e0f62 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pl.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Numer portu do użycia dla punktu końcowego HTTPS usług IIS Express w pliku launchSettings.json. Ta opcja ma zastosowanie tylko wtedy, gdy nie jest używany parametr no-https (jeśli zostanie użyte uwierzytelnianie IndividualAuth lub OrganizationalAuth, parametr no-https zostanie zignorowana).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json index 9a8b3654a8aa..dc3922339c3b 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.pt-BR.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Número da porta a ser usada para o ponto de extremidade HTTPS do IIS Express em launchSettings.json. Essa opção só é aplicável quando o parâmetro no-https não é usado (no-https será ignorado se IndividualAuth ou OrganizationalAuth for usado).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json index 1cc5c56e6f66..f9d64e65d85a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.ru.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "Номер порта, используемый для конечной точки HTTPS IIS Express в launchSettings.json. Этот параметр применим только в том случае, если no-https не используется (при использовании IndividualAuth или OrganizationalAuth no-https игнорируется).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json index 3164a6321949..5299f026392a 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.tr.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "launchSettings.json içinde IIS Express HTTPS uç noktası için kullanılacak bağlantı noktası numarası. Bu seçenek yalnızca no-https parametresi kullanılmazsa uygulanabilir (IndividualAuth veya OrganizationalAuth kullanılırsa no-https yoksayılır).", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json index 80313bc8f0b1..27bbe0d23ea5 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hans.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "要用于 launchSettings.json 中 IIS Express HTTPS 终结点的端口号。仅当不使用参数 no-https 时,此选项才适用(如果使用 IndividualAuth 或 OrganizationalAuth,则将忽略 no-https)。", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json index edd6c5e7b374..f1c7a0d88ba7 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/localize/templatestrings.zh-Hant.json @@ -12,9 +12,13 @@ "symbols/iisHttpsPort/description": "launchSettings.json 中 IIS Express HTTPS 端點要使用的連接埠號碼。只有在未使用參數 no-https 時,才適用此選項 (如果使用 IndividualAuth 或 OrganizationalAuth,則會忽略 no-https)。", "symbols/InteractivityPlatform/displayName": "_Interactivity type", "symbols/InteractivityPlatform/description": "Chooses which hosting platform to use for interactive components", + "symbols/InteractivityPlatform/choices/None/displayName": "None", "symbols/InteractivityPlatform/choices/None/description": "No interactivity (static server rendering only)", + "symbols/InteractivityPlatform/choices/Server/displayName": "Server", "symbols/InteractivityPlatform/choices/Server/description": "Runs on the server", + "symbols/InteractivityPlatform/choices/WebAssembly/displayName": "WebAssembly", "symbols/InteractivityPlatform/choices/WebAssembly/description": "Runs in the browser using WebAssembly", + "symbols/InteractivityPlatform/choices/Auto/displayName": "Auto (Server and WebAssembly)", "symbols/InteractivityPlatform/choices/Auto/description": "Uses Server while downloading WebAssembly assets, then uses WebAssembly", "symbols/InteractivityLocation/displayName": "_Interactivity location", "symbols/InteractivityLocation/description": "Chooses which components will have interactive rendering enabled", From 1b6149f9ac0e4a276a023d525d0f269fcd8870b9 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Thu, 14 Sep 2023 18:06:58 +0100 Subject: [PATCH 22/23] Rename --interactivity to --interactive --- src/ProjectTemplates/Shared/ArgConstants.cs | 2 +- .../.template.config/dotnetcli.host.json | 2 +- .../test/Templates.Tests/template-baselines.json | 16 ++++++++-------- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/ProjectTemplates/Shared/ArgConstants.cs b/src/ProjectTemplates/Shared/ArgConstants.cs index 342f8ce80c48..657c2f597a5b 100644 --- a/src/ProjectTemplates/Shared/ArgConstants.cs +++ b/src/ProjectTemplates/Shared/ArgConstants.cs @@ -25,6 +25,6 @@ internal static class ArgConstants public const string UseLocalDb = "-uld"; public const string NoHttps = "--no-https"; public const string PublishNativeAot = "--aot"; - public const string NoInteractivity = "--interactivity none"; + public const string NoInteractivity = "--interactive none"; public const string Empty = "--empty"; } diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json index a8c678b039b3..1d7de9b2ddf4 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json @@ -6,7 +6,7 @@ "shortName": "" }, "InteractivityPlatform": { - "longName": "interactivity", + "longName": "interactive", "shortName": "int" }, "AllInteractive": { diff --git a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json index 6b982d80f7b2..b11b81effbb1 100644 --- a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json +++ b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json @@ -506,7 +506,7 @@ "blazor": { "NoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --interactivity none", + "Arguments": "new blazor --interactive none", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -557,7 +557,7 @@ }, "UseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactivity webassembly", + "Arguments": "new blazor --interactive webassembly", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -589,7 +589,7 @@ }, "UseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactivity auto", + "Arguments": "new blazor --interactive auto", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -647,7 +647,7 @@ }, "UseWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --interactivity webassembly --all-interactive", + "Arguments": "new blazor --interactive webassembly --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -679,7 +679,7 @@ }, "UseServerAndWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --interactivity auto --all-interactive", + "Arguments": "new blazor --interactive auto --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -711,7 +711,7 @@ }, "EmptyNoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --interactivity none --empty", + "Arguments": "new blazor --interactive none --empty", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -749,7 +749,7 @@ }, "EmptyUseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactivity webassembly --empty", + "Arguments": "new blazor --interactive webassembly --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -772,7 +772,7 @@ }, "EmptyUseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactivity auto --empty", + "Arguments": "new blazor --interactive auto --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", From 66e26a84355a056877010803db8a09ccf48ff225 Mon Sep 17 00:00:00 2001 From: Steve Sanderson Date: Fri, 15 Sep 2023 11:17:24 +0100 Subject: [PATCH 23/23] Revert "Rename --interactivity to --interactive" This reverts commit 1b6149f9ac0e4a276a023d525d0f269fcd8870b9. --- src/ProjectTemplates/Shared/ArgConstants.cs | 2 +- .../.template.config/dotnetcli.host.json | 2 +- .../test/Templates.Tests/template-baselines.json | 16 ++++++++-------- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/ProjectTemplates/Shared/ArgConstants.cs b/src/ProjectTemplates/Shared/ArgConstants.cs index 657c2f597a5b..342f8ce80c48 100644 --- a/src/ProjectTemplates/Shared/ArgConstants.cs +++ b/src/ProjectTemplates/Shared/ArgConstants.cs @@ -25,6 +25,6 @@ internal static class ArgConstants public const string UseLocalDb = "-uld"; public const string NoHttps = "--no-https"; public const string PublishNativeAot = "--aot"; - public const string NoInteractivity = "--interactive none"; + public const string NoInteractivity = "--interactivity none"; public const string Empty = "--empty"; } diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json index 1d7de9b2ddf4..a8c678b039b3 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorWeb-CSharp/.template.config/dotnetcli.host.json @@ -6,7 +6,7 @@ "shortName": "" }, "InteractivityPlatform": { - "longName": "interactive", + "longName": "interactivity", "shortName": "int" }, "AllInteractive": { diff --git a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json index b11b81effbb1..6b982d80f7b2 100644 --- a/src/ProjectTemplates/test/Templates.Tests/template-baselines.json +++ b/src/ProjectTemplates/test/Templates.Tests/template-baselines.json @@ -506,7 +506,7 @@ "blazor": { "NoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --interactive none", + "Arguments": "new blazor --interactivity none", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -557,7 +557,7 @@ }, "UseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactive webassembly", + "Arguments": "new blazor --interactivity webassembly", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -589,7 +589,7 @@ }, "UseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactive auto", + "Arguments": "new blazor --interactivity auto", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -647,7 +647,7 @@ }, "UseWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --interactive webassembly --all-interactive", + "Arguments": "new blazor --interactivity webassembly --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -679,7 +679,7 @@ }, "UseServerAndWebAssemblyInteractiveAtRoot": { "Template": "blazor", - "Arguments": "new blazor --interactive auto --all-interactive", + "Arguments": "new blazor --interactivity auto --all-interactive", "Files": [ "{ProjectName}/appsettings.Development.json", "{ProjectName}/appsettings.json", @@ -711,7 +711,7 @@ }, "EmptyNoInteractivity": { "Template": "blazor", - "Arguments": "new blazor --interactive none --empty", + "Arguments": "new blazor --interactivity none --empty", "Files": [ "appsettings.Development.json", "appsettings.json", @@ -749,7 +749,7 @@ }, "EmptyUseWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactive webassembly --empty", + "Arguments": "new blazor --interactivity webassembly --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json", @@ -772,7 +772,7 @@ }, "EmptyUseServerAndWebAssembly": { "Template": "blazor", - "Arguments": "new blazor --interactive auto --empty", + "Arguments": "new blazor --interactivity auto --empty", "Files": [ "{ProjectName}.sln", "{ProjectName}/appsettings.Development.json",