From b99ac31f4d6915a866ae38185d83ed46f34150dd Mon Sep 17 00:00:00 2001 From: Torsten Brendgen Date: Sun, 19 Jul 2026 21:32:59 +0200 Subject: [PATCH] =?UTF-8?q?Aktualisiere=20README.md=20und=20Konfigurations?= =?UTF-8?q?dateien=20f=C3=BCr=20Version=201.0.4;=20f=C3=BCge=20Elemente=20?= =?UTF-8?q?f=C3=BCr=20Custom=20Branding=20Application=20Customizer=20hinzu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 53 ++++++++++++------- config/package-solution.json | 19 +++++-- package-lock.json | 2 +- package.json | 5 +- sharepoint/assets/elements.xml | 8 +++ .../CustomBrandingApplicationCustomizer.ts | 5 +- .../customBranding/loc/myStrings.d.ts | 1 + 7 files changed, 67 insertions(+), 26 deletions(-) create mode 100644 sharepoint/assets/elements.xml diff --git a/README.md b/README.md index 9a2f836..dd833af 100644 --- a/README.md +++ b/README.md @@ -1,26 +1,43 @@ -## custom-branding +# Custom Branding -This is where you include your WebPart documentation. +Custom Branding ist ein SPFx-1.4.1-Application-Customizer fuer SharePoint Server Subscription Edition. Die Solution laedt zentral konfigurierte Stylesheets und kann strukturierte Inhalte in den oberen und unteren SharePoint-Placeholder rendern. -### Building the code +## Version -```bash -git clone the repo -npm i -npm i -g gulp -gulp +`1.0.4.0` + +## Konfiguration + +Die Konfiguration wird in den `ClientSideComponentProperties` der aktiven UserCustomAction gespeichert und zentral ueber PortalSettings gepflegt: + +```json +{ + "cssfiles": [], + "placeholdertop": { + "elements": [] + }, + "placeholderbottom": { + "elements": [] + } +} ``` -This package produces the following: +## Build -* lib/* - intermediate-stage commonjs build artifacts -* dist/* - the bundled script, along with other resources -* deploy/* - all resources which should be uploaded to a CDN. +Die Legacy-SPFx-Toolchain benoetigt Node.js 8.17.0: -### Build options +```powershell +npm install +npm run package +``` -gulp clean - TODO -gulp test - TODO -gulp serve - TODO -gulp bundle - TODO -gulp package-solution - TODO +Das Paket wird unter `sharepoint/solution/custom-branding.sppkg` erzeugt. + +## Installation + +1. `custom-branding.sppkg` in den App Catalog laden beziehungsweise ersetzen. +2. Die App im Root Web der Site Collection installieren oder aktualisieren. +3. Beim Aktivieren wird der Custom Branding Application Customizer automatisch web-scoped registriert. +4. PortalSettings mit `Strg+F5` neu laden und den Tab **Custom Branding** konfigurieren. + +Das Skript `deployment/add-custombranding.ps1` bleibt fuer automatisierte Rollouts oder eine ausdruecklich site-scoped Registrierung verfuegbar. diff --git a/config/package-solution.json b/config/package-solution.json index d78f787..968912e 100644 --- a/config/package-solution.json +++ b/config/package-solution.json @@ -3,11 +3,24 @@ "solution": { "name": "custom-branding-client-side-solution", "id": "03a7c4de-e031-4b83-a683-5ca5c364166e", - "version": "1.0.3.0", + "version": "1.0.4.0", "includeClientSideAssets": true, - "skipFeatureDeployment": true + "skipFeatureDeployment": false, + "features": [ + { + "title": "Custom Branding extension registration", + "description": "Registers the Custom Branding Application Customizer in the host web.", + "id": "2eb6deaa-a4a0-40c5-9f15-6bdaff36094f", + "version": "1.0.4.0", + "assets": { + "elementManifests": [ + "elements.xml" + ] + } + } + ] }, "paths": { "zippedPackage": "solution/custom-branding.sppkg" } -} \ No newline at end of file +} diff --git a/package-lock.json b/package-lock.json index 152ec7d..214c824 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "custom-branding", - "version": "0.0.1", + "version": "1.0.4", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 11d5cf4..a17f3f3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "custom-branding", - "version": "0.0.2", + "version": "1.0.4", "private": true, "main": "lib/index.js", "engines": { @@ -9,7 +9,8 @@ "scripts": { "build": "gulp bundle", "clean": "gulp clean", - "test": "gulp test" + "test": "gulp test", + "package": "gulp clean && gulp bundle --ship && gulp package-solution --ship" }, "dependencies": { "@microsoft/sp-core-library": "~1.4.0", diff --git a/sharepoint/assets/elements.xml b/sharepoint/assets/elements.xml new file mode 100644 index 0000000..067af54 --- /dev/null +++ b/sharepoint/assets/elements.xml @@ -0,0 +1,8 @@ + + + + diff --git a/src/extensions/customBranding/CustomBrandingApplicationCustomizer.ts b/src/extensions/customBranding/CustomBrandingApplicationCustomizer.ts index 46c8db7..9ddb728 100644 --- a/src/extensions/customBranding/CustomBrandingApplicationCustomizer.ts +++ b/src/extensions/customBranding/CustomBrandingApplicationCustomizer.ts @@ -1,4 +1,7 @@ import { override } from '@microsoft/decorators'; +// Legacy SPFx 1.4 implementation; incremental modernization is tracked separately. +// tslint:disable:max-line-length no-consecutive-blank-lines no-function-expression no-trailing-whitespace typedef + import { Log } from '@microsoft/sp-core-library'; import { BaseApplicationCustomizer, @@ -6,8 +9,6 @@ import { PlaceholderName } from '@microsoft/sp-application-base'; -import * as strings from 'CustomBrandingApplicationCustomizerStrings'; - const LOG_SOURCE: string = 'CustomBrandingApplicationCustomizer'; /** diff --git a/src/extensions/customBranding/loc/myStrings.d.ts b/src/extensions/customBranding/loc/myStrings.d.ts index 5f81b31..2083380 100644 --- a/src/extensions/customBranding/loc/myStrings.d.ts +++ b/src/extensions/customBranding/loc/myStrings.d.ts @@ -4,5 +4,6 @@ declare interface ICustomBrandingApplicationCustomizerStrings { declare module 'CustomBrandingApplicationCustomizerStrings' { const strings: ICustomBrandingApplicationCustomizerStrings; + // tslint:disable-next-line:export-name export = strings; }