+
all
runtime; build; native; contentfiles; analyzers; buildtransitive
diff --git a/frontend/src/app/framework/angular/forms/editors/date-time-editor.component.scss b/frontend/src/app/framework/angular/forms/editors/date-time-editor.component.scss
index db1990278..df536875c 100644
--- a/frontend/src/app/framework/angular/forms/editors/date-time-editor.component.scss
+++ b/frontend/src/app/framework/angular/forms/editors/date-time-editor.component.scss
@@ -36,12 +36,12 @@
.btn {
&-clear {
@include absolute(auto, 4px, 3px, auto);
- z-index: 100;
+ z-index: 1;
}
&-time-mode {
@include absolute(1px, auto, -1px, auto);
- z-index: 100;
+ z-index: 1;
}
&:focus {
diff --git a/frontend/src/app/shell/pages/internal/chat-menu.component.html b/frontend/src/app/shell/pages/internal/chat-menu.component.html
new file mode 100644
index 000000000..b4caee711
--- /dev/null
+++ b/frontend/src/app/shell/pages/internal/chat-menu.component.html
@@ -0,0 +1,9 @@
+@if ((appsState.selectedApp | async) && hasChatBot) {
+
+}
+
+
diff --git a/frontend/src/app/shell/pages/internal/chat-menu.component.scss b/frontend/src/app/shell/pages/internal/chat-menu.component.scss
new file mode 100644
index 000000000..c824ee2c3
--- /dev/null
+++ b/frontend/src/app/shell/pages/internal/chat-menu.component.scss
@@ -0,0 +1,7 @@
+@import 'mixins';
+@import 'vars';
+
+.nav-link {
+ font-weight: 450;
+ font-size: 1.3rem;
+}
\ No newline at end of file
diff --git a/frontend/src/app/shell/pages/internal/chat-menu.component.ts b/frontend/src/app/shell/pages/internal/chat-menu.component.ts
new file mode 100644
index 000000000..562144d84
--- /dev/null
+++ b/frontend/src/app/shell/pages/internal/chat-menu.component.ts
@@ -0,0 +1,33 @@
+/*
+ * Squidex Headless CMS
+ *
+ * @license
+ * Copyright (c) Squidex UG (haftungsbeschränkt). All rights reserved.
+ */
+
+import { AsyncPipe } from '@angular/common';
+import { ChangeDetectionStrategy, Component, inject } from '@angular/core';
+import { AppsState, ChatDialogComponent, DialogModel, ModalDirective, UIOptions } from '@app/shared';
+
+@Component({
+ standalone: true,
+ selector: 'sqx-chat-menu',
+ styleUrls: ['./chat-menu.component.scss'],
+ templateUrl: './chat-menu.component.html',
+ changeDetection: ChangeDetectionStrategy.OnPush,
+ imports: [
+ AsyncPipe,
+ ChatDialogComponent,
+ ModalDirective
+ ],
+})
+export class ChatMenuComponent {
+ public readonly chatDialog = new DialogModel();
+
+ public readonly hasChatBot = inject(UIOptions).value.canUseChatBot;
+
+ constructor(
+ public readonly appsState: AppsState
+ ) {
+ }
+}
diff --git a/frontend/src/app/shell/pages/internal/internal-area.component.html b/frontend/src/app/shell/pages/internal/internal-area.component.html
index f6db2f9ec..e9ce5450d 100644
--- a/frontend/src/app/shell/pages/internal/internal-area.component.html
+++ b/frontend/src/app/shell/pages/internal/internal-area.component.html
@@ -8,6 +8,7 @@
+
diff --git a/frontend/src/app/shell/pages/internal/internal-area.component.ts b/frontend/src/app/shell/pages/internal/internal-area.component.ts
index 729aec1f5..9e803e8c8 100644
--- a/frontend/src/app/shell/pages/internal/internal-area.component.ts
+++ b/frontend/src/app/shell/pages/internal/internal-area.component.ts
@@ -16,6 +16,7 @@ import { LogoComponent } from './logo.component';
import { NotificationsMenuComponent } from './notifications-menu.component';
import { ProfileMenuComponent } from './profile-menu.component';
import { SearchMenuComponent } from './search-menu.component';
+import { ChatMenuComponent } from './chat-menu.component';
@Component({
standalone: true,
@@ -26,6 +27,7 @@ import { SearchMenuComponent } from './search-menu.component';
AppsMenuComponent,
AssetUploaderComponent,
AsyncPipe,
+ ChatMenuComponent,
FeedbackMenuComponent,
LogoComponent,
NotificationsMenuComponent,
diff --git a/tools/TestSuite/TestSuite.ApiTests/ContentUpdateTests.cs b/tools/TestSuite/TestSuite.ApiTests/ContentUpdateTests.cs
index d9a3efb25..8260372ea 100644
--- a/tools/TestSuite/TestSuite.ApiTests/ContentUpdateTests.cs
+++ b/tools/TestSuite/TestSuite.ApiTests/ContentUpdateTests.cs
@@ -413,6 +413,63 @@ public class ContentUpdateTests : IClassFixture
Assert.Null(updated.Data.String);
}
+ [Fact]
+ public async Task Should_unset_field_with_patch()
+ {
+ // STEP 1: Create a new item.
+ var content = await _.Contents.CreateAsync(new TestEntityData
+ {
+ String = "Hello",
+ // Not relevant for the test, but required in the schema.
+ Number = 100
+ }, ContentCreateOptions.AsPublish);
+
+
+ // STEP 2: Update content with script.
+ await _.Client.DynamicContents(_.SchemaName).PatchAsync(content.Id,
+ new DynamicData
+ {
+ [TestEntityData.StringField] = new JObject
+ {
+ ["$unset"] = true
+ }
+ });
+
+ var updated = await _.Contents.GetAsync(content.Id);
+
+ Assert.Null(updated.Data.String);
+ }
+
+ [Fact]
+ public async Task Should_unset_field_value_with_patch()
+ {
+ // STEP 1: Create a new item.
+ var content = await _.Contents.CreateAsync(new TestEntityData
+ {
+ String = "Hello",
+ // Not relevant for the test, but required in the schema.
+ Number = 100
+ }, ContentCreateOptions.AsPublish);
+
+
+ // STEP 2: Update content with script.
+ await _.Client.DynamicContents(_.SchemaName).PatchAsync(content.Id,
+ new DynamicData
+ {
+ [TestEntityData.StringField] = new JObject
+ {
+ ["iv"] = new JObject
+ {
+ ["$unset"] = true
+ }
+ }
+ });
+
+ var updated = await _.Contents.GetAsync(content.Id);
+
+ Assert.Null(updated.Data.String);
+ }
+
[Theory]
[InlineData(ContentStrategies.Update.Normal)]
[InlineData(ContentStrategies.Update.Upsert)]