Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
472f530
feat: fix a small-ish nitpick where extensions would reload after login
iOvergaard Jun 4, 2025
147bf98
feat: align login UI extension load with backoffice, i.e. wait for ex…
iOvergaard Jun 4, 2025
e053af1
build(deps): bump @hey-api to newest and re-generate client
iOvergaard Jun 4, 2025
4f660a6
chore: adds extra error logging
iOvergaard Jun 4, 2025
57a57a4
feat: adds retry logic to the api interceptor
iOvergaard Jun 4, 2025
6292ffa
feat: warn about incomplete actions
iOvergaard Jun 5, 2025
2101bf5
fix: the body was already plain text, but we need to ensure the heade…
iOvergaard Jun 5, 2025
a23be07
feat: warns the user when actions could not be completed
iOvergaard Jun 5, 2025
26edd73
build(deps): update @hey-api/client-fetch
iOvergaard Jun 5, 2025
1030ff8
chore: generate new api
iOvergaard Jun 5, 2025
94da54c
feat: simplify error handling to just UmbApiError and UmbCancelError
iOvergaard Jun 5, 2025
a8f9e51
feat: moves error notifications from interceptors into tryExecute, so…
iOvergaard Jun 5, 2025
6e254c4
Merge branch 'main' into v16/feature/retry-requests
iOvergaard Jun 5, 2025
0bbd074
feat: recreate responses with correct 'status' and 'statusText'
iOvergaard Jun 5, 2025
0e6a885
build: stop dotnet processes after debug session
iOvergaard Jun 5, 2025
32d1a46
feat: extrapolate common logic into helper method to create responses
iOvergaard Jun 5, 2025
14f3176
feat: returns a UmbProblemDetails like object on interceptors to be h…
iOvergaard Jun 5, 2025
e943a3c
chore: deprecates duplicate, outdated UmbProblemDetails interface and…
iOvergaard Jun 5, 2025
f3a90c8
feat: uses the 'title' of the problem details object to convey the ma…
iOvergaard Jun 5, 2025
9d133bd
chore: 401 and 403 uses their own interceptors
iOvergaard Jun 5, 2025
8eae4c3
feat: show no notification if 401
iOvergaard Jun 5, 2025
48306f6
feat: uses the real request method and url (instead of the template p…
iOvergaard Jun 5, 2025
a03fa89
feat: retry requests with no timeout/race
iOvergaard Jun 6, 2025
7a74f6d
feat: throttle and delay signals and disallow them from being updated…
iOvergaard Jun 6, 2025
d014145
chore: adds more logging to timeouts
iOvergaard Jun 6, 2025
a629fe7
Merge branch 'main' into v16/feature/retry-requests
iOvergaard Jun 6, 2025
45b5d29
chore: optimise imports
iOvergaard Jun 6, 2025
75c8b42
test: ignores any test files left in node_modules folder
iOvergaard Jun 6, 2025
ddae4ff
Merge branch 'main' into v16/feature/retry-requests
iOvergaard Jun 6, 2025
b858cb3
feat: uses auditTime to wait a bit before showing the timeout screen
iOvergaard Jun 6, 2025
1852177
Merge branch 'main' into v16/feature/retry-requests
iOvergaard Jun 6, 2025
ea273fa
Merge branch 'main' into v16/feature/retry-requests
iOvergaard Jun 10, 2025
fd9574f
feat: adds 404 handling to error interceptor
iOvergaard Jun 10, 2025
0f91dc3
chore: cleans up after response modification
iOvergaard Jun 10, 2025
314d6b1
feat: preserve only a few headers
iOvergaard Jun 10, 2025
1064cbd
feat: lets the UI handle 404 errors instead of notifying directly
iOvergaard Jun 10, 2025
e59743f
test: uses create action menu option instead to find the correct loca…
iOvergaard Jun 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
"cwd": "${workspaceFolder}/src/Umbraco.Web.UI",
"stopAtEntry": false,
"requireExactSource": false,
"postDebugTask": "kill-umbraco-web-ui",
// Enable launching a web browser when ASP.NET Core starts. For more information: https://aka.ms/VSCode-CS-LaunchJson-WebBrowser
"serverReadyAction": {
"action": "openExternally",
Expand Down Expand Up @@ -96,6 +97,7 @@
"stopAtEntry": false,
"requireExactSource": false,
"checkForDevCert": true,
"postDebugTask": "kill-umbraco-web-ui",
"env": {
"ASPNETCORE_ENVIRONMENT": "Development",
"ASPNETCORE_URLS": "https://localhost:44339",
Expand Down
159 changes: 85 additions & 74 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -1,76 +1,87 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "Build",
"detail": "Builds the client and SLN",
"promptOnClose": true,
"group": "build",
"dependsOn": [
"Client Build",
"Dotnet build"
],
"problemMatcher": []
},
{
"label": "Client Install",
"detail": "install npm for Umbraco.Web.UI.Client",
"promptOnClose": true,
"type": "npm",
"script": "install",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Client Build",
"detail": "runs npm run build for Umbraco.Web.UI.Client",
"promptOnClose": true,
"group": "build",
"type": "npm",
"script": "build:for:cms",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Client Watch",
"detail": "runs npm run dev for Umbraco.Web.UI.Client",
"promptOnClose": true,
"group": "build",
"type": "npm",
"script": "dev",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Dotnet build",
"detail": "Dotnet build of SLN",
"promptOnClose": true,
"group": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/umbraco.sln",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "Dotnet watch",
"detail": "Dotnet run and watch of Web.UI",
"promptOnClose": true,
"command": "dotnet",
"type": "process",
"args": [
"watch",
"run",
"--project",
"${workspaceFolder}/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
}
]
"version": "2.0.0",
"tasks": [
{
"label": "Build",
"detail": "Builds the client and SLN",
"promptOnClose": true,
"group": "build",
"dependsOn": ["Client Build", "Dotnet build"],
"problemMatcher": []
},
{
"label": "Client Install",
"detail": "install npm for Umbraco.Web.UI.Client",
"promptOnClose": true,
"type": "npm",
"script": "install",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Client Build",
"detail": "runs npm run build for Umbraco.Web.UI.Client",
"promptOnClose": true,
"group": "build",
"type": "npm",
"script": "build:for:cms",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Client Watch",
"detail": "runs npm run dev for Umbraco.Web.UI.Client",
"promptOnClose": true,
"group": "build",
"type": "npm",
"script": "dev",
"path": "src/Umbraco.Web.UI.Client/",
"problemMatcher": []
},
{
"label": "Dotnet build",
"detail": "Dotnet build of SLN",
"promptOnClose": true,
"group": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/umbraco.sln",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "Dotnet watch",
"detail": "Dotnet run and watch of Web.UI",
"promptOnClose": true,
"command": "dotnet",
"type": "process",
"args": [
"watch",
"run",
"--project",
"${workspaceFolder}/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "kill-umbraco-web-ui",
"type": "shell",
"problemMatcher": [],
"osx": {
"command": "pkill -f Umbraco.Web.UI"
},
"linux": {
"command": "pkill -f Umbraco.Web.UI"
},
"windows": {
"command": "taskkill /IM Umbraco.Web.UI.exe /F"
}
}
]
}
64 changes: 43 additions & 21 deletions src/Umbraco.Web.UI.Client/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export class UmbAppAuthController extends UmbControllerBase {
this.observe(
context?.timeoutSignal,
() => {
console.log('[UmbAppAuthController] Authorization timed out, starting authorization flow');
this.makeAuthorizationRequest('timedOut');
},
'_authState',
Expand Down
23 changes: 13 additions & 10 deletions src/Umbraco.Web.UI.Client/src/apps/backoffice/backoffice.element.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,22 +66,25 @@ export class UmbBackofficeElement extends UmbLitElement {

new UmbBackofficeEntryPointExtensionInitializer(this, umbExtensionsRegistry);
new UmbEntryPointExtensionInitializer(this, umbExtensionsRegistry);
}

override async firstUpdated() {
await this.#extensionsAfterAuth();

// So far local packages are this simple to registerer, so no need for a manager to do that:
// So far local packages are this simple to register, so no need for a manager to do that:
CORE_PACKAGES.forEach(async (packageImport) => {
const packageModule = await packageImport;
umbExtensionsRegistry.registerMany(packageModule.extensions);
});
}

const serverExtensions = new UmbServerExtensionRegistrator(this, umbExtensionsRegistry);

// TODO: We need to ensure this request is called every time the user logs in, but this should be done somewhere across the app and not here [JOV]
this.consumeContext(UMB_AUTH_CONTEXT, (authContext) => {
this.observe(authContext?.isAuthorized, (isAuthorized) => {
if (!isAuthorized) return;
serverExtensions.registerPrivateExtensions();
});
});
async #extensionsAfterAuth() {
const authContext = await this.getContext(UMB_AUTH_CONTEXT, { preventTimeout: true });
if (!authContext) {
throw new Error('UmbBackofficeElement requires the UMB_AUTH_CONTEXT to be set.');
}
await this.observe(authContext.isAuthorized).asPromise();
await new UmbServerExtensionRegistrator(this, umbExtensionsRegistry).registerPrivateExtensions();
}

override render() {
Expand Down
3 changes: 3 additions & 0 deletions src/Umbraco.Web.UI.Client/src/external/rxjs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,7 @@ export {
switchMap,
takeUntil,
tap,
delay,
throttleTime,
auditTime,
} from 'rxjs';
Loading
Loading