From 2f87a50273102101d820e6d8f46ec1794e1ea932 Mon Sep 17 00:00:00 2001 From: Sebastian Stehle Date: Mon, 5 Jan 2026 22:06:59 +0100 Subject: [PATCH] WIP: Form row (#1273) * Improved mongo config. * Update dependencies. * Disable test in CI for now. * Temp * Temp * More form rows. * Fix label. * Form row improvements. --- .../pages/users/user-page.component.html | 50 ++-- .../pages/users/user-page.component.scss | 3 +- .../pages/users/user-page.component.ts | 4 +- .../pages/graphql/graphql-page.component.html | 5 +- .../pages/graphql/graphql-page.component.ts | 3 +- .../pages/onboarding-dialog.component.html | 16 +- .../apps/pages/onboarding-dialog.component.ts | 3 +- .../pages/asset-tag-dialog.component.html | 8 +- .../pages/asset-tag-dialog.component.ts | 6 +- .../calendar/calendar-page.component.html | 83 +++--- .../pages/calendar/calendar-page.component.ts | 3 +- .../pages/rule/step-dialog.component.html | 157 +++++------ .../rules/pages/rule/step-dialog.component.ts | 4 +- .../actions/branches-input.component.html | 2 +- .../shared/state-step-property.component.html | 21 +- .../shared/state-step-property.component.ts | 3 +- .../asset-changed-trigger.component.html | 45 ++-- .../asset-changed-trigger.component.ts | 4 +- .../triggers/comment-trigger.component.html | 37 ++- .../triggers/comment-trigger.component.ts | 4 +- .../triggers/cron-job-trigger.component.html | 85 +++--- .../triggers/cron-job-trigger.component.ts | 4 +- .../schema-changed-trigger.component.html | 37 ++- .../schema-changed-trigger.component.ts | 4 +- .../triggers/usage-trigger.component.html | 24 +- .../triggers/usage-trigger.component.ts | 6 +- .../common/schema-edit-form.component.html | 64 ++--- .../common/schema-edit-form.component.ts | 6 +- .../schema/fields/field-wizard.component.html | 21 +- .../schema/fields/field-wizard.component.ts | 5 +- .../forms/field-form-common.component.html | 42 +-- .../forms/field-form-common.component.ts | 6 +- .../fields/forms/field-form-ui.component.html | 28 +- .../fields/forms/field-form-ui.component.ts | 5 +- .../field-form-validation.component.html | 41 +-- .../forms/field-form-validation.component.ts | 8 +- .../fields/forms/field-form.component.ts | 4 +- .../fields/types/array-ui.component.html | 17 +- .../schema/fields/types/array-ui.component.ts | 4 +- .../types/array-validation.component.html | 36 +-- .../types/array-validation.component.ts | 3 +- .../fields/types/assets-ui.component.html | 80 +++--- .../fields/types/assets-ui.component.ts | 5 +- .../types/assets-validation.component.html | 195 +++++--------- .../types/assets-validation.component.scss | 5 - .../types/assets-validation.component.ts | 8 +- .../fields/types/boolean-ui.component.html | 44 +--- .../fields/types/boolean-ui.component.ts | 5 +- .../types/boolean-validation.component.html | 30 +-- .../types/boolean-validation.component.ts | 9 +- .../types/component-validation.component.html | 18 +- .../types/component-validation.component.ts | 3 +- .../fields/types/components-ui.component.html | 17 +- .../fields/types/components-ui.component.ts | 4 +- .../components-validation.component.html | 62 ++--- .../types/components-validation.component.ts | 3 +- .../fields/types/date-time-ui.component.html | 45 +--- .../fields/types/date-time-ui.component.ts | 6 +- .../types/date-time-validation.component.html | 57 ++-- .../types/date-time-validation.component.ts | 11 +- .../types/geolocation-ui.component.html | 15 +- .../fields/types/geolocation-ui.component.ts | 4 +- .../fields/types/json-more.component.html | 6 +- .../fields/types/json-more.component.ts | 5 +- .../fields/types/number-ui.component.html | 51 ++-- .../fields/types/number-ui.component.ts | 5 +- .../types/number-validation.component.html | 65 ++--- .../types/number-validation.component.ts | 8 +- .../fields/types/references-ui.component.html | 51 ++-- .../fields/types/references-ui.component.ts | 5 +- .../references-validation.component.html | 99 +++---- .../types/references-validation.component.ts | 8 +- .../fields/types/rich-text-ui.component.html | 40 +-- .../fields/types/rich-text-ui.component.ts | 5 +- .../types/rich-text-validation.component.html | 105 ++++---- .../types/rich-text-validation.component.ts | 3 +- .../fields/types/string-ui.component.html | 148 +++++------ .../fields/types/string-ui.component.ts | 4 +- .../types/string-validation.component.html | 245 +++++++----------- .../types/string-validation.component.ts | 8 +- .../fields/types/tags-ui.component.html | 52 ++-- .../schema/fields/types/tags-ui.component.ts | 5 +- .../types/tags-validation.component.html | 46 ++-- .../fields/types/tags-validation.component.ts | 8 +- .../schema/indexes/index-form.component.html | 2 +- .../pages/schemas/schema-form.component.html | 52 ++-- .../pages/schemas/schema-form.component.ts | 4 +- .../pages/clients/client.component.html | 133 +++++----- .../pages/clients/client.component.ts | 4 +- .../pages/languages/language.component.html | 140 +++++----- .../pages/languages/language.component.ts | 4 +- .../pages/more/more-page.component.html | 18 +- .../pages/more/more-page.component.ts | 4 +- .../pages/workflows/workflow.component.html | 46 ++-- .../pages/workflows/workflow.component.ts | 4 +- .../teams/pages/auth/auth-page.component.html | 99 +++---- .../teams/pages/auth/auth-page.component.ts | 4 +- .../teams/pages/more/more-page.component.html | 8 +- .../teams/pages/more/more-page.component.ts | 4 +- .../features/teams/state/team-auth.state.ts | 2 +- .../editors/date-time-editor.component.html | 1 + .../editors/date-time-editor.component.ts | 3 + .../editors/localized-input.component.html | 8 +- .../forms/editors/tag-editor.component.html | 1 + .../forms/editors/tag-editor.component.ts | 3 + .../angular/forms/form-row.component.html | 42 +++ .../angular/forms/form-row.component.scss | 16 ++ .../angular/forms/form-row.component.ts | 136 ++++++++++ .../angular/language-selector.component.html | 2 +- .../angular/language-selector.component.ts | 3 + frontend/src/app/framework/index.ts | 1 + .../shared/components/app-form.component.html | 14 +- .../shared/components/app-form.component.ts | 4 +- .../assets/asset-dialog.component.html | 51 ++-- .../assets/asset-dialog.component.ts | 4 +- .../assets/asset-folder-dialog.component.html | 13 +- .../assets/asset-folder-dialog.component.ts | 4 +- .../search/search-form.component.html | 11 +- .../search/search-form.component.ts | 4 +- .../components/team-form.component.html | 14 +- .../shared/components/team-form.component.ts | 5 +- 121 files changed, 1440 insertions(+), 1937 deletions(-) create mode 100644 frontend/src/app/framework/angular/forms/form-row.component.html create mode 100644 frontend/src/app/framework/angular/forms/form-row.component.scss create mode 100644 frontend/src/app/framework/angular/forms/form-row.component.ts diff --git a/frontend/src/app/features/administration/pages/users/user-page.component.html b/frontend/src/app/features/administration/pages/users/user-page.component.html index 0524d61dc..64cd668bc 100644 --- a/frontend/src/app/features/administration/pages/users/user-page.component.html +++ b/frontend/src/app/features/administration/pages/users/user-page.component.html @@ -21,46 +21,34 @@ -
- - + -
+ -
- - + -
+ -
-
- - +
+ -
+ -
- - + -
+
-
- - - +
+ + +
diff --git a/frontend/src/app/features/administration/pages/users/user-page.component.scss b/frontend/src/app/features/administration/pages/users/user-page.component.scss index ad80494d1..3938d8793 100644 --- a/frontend/src/app/features/administration/pages/users/user-page.component.scss +++ b/frontend/src/app/features/administration/pages/users/user-page.component.scss @@ -1,8 +1,9 @@ @import 'mixins'; @import 'vars'; -.form-group-section { +.form-section { margin-top: 2rem; + margin-bottom: 1.25rem; } textarea { diff --git a/frontend/src/app/features/administration/pages/users/user-page.component.ts b/frontend/src/app/features/administration/pages/users/user-page.component.ts index 578e20656..c11cd7afa 100644 --- a/frontend/src/app/features/administration/pages/users/user-page.component.ts +++ b/frontend/src/app/features/administration/pages/users/user-page.component.ts @@ -9,7 +9,7 @@ import { AsyncPipe } from '@angular/common'; import { Component, OnInit } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; import { ActivatedRoute, Router } from '@angular/router'; -import { ControlErrorsComponent, FormErrorComponent, LayoutComponent, ShortcutDirective, Subscriptions, TitleComponent, TooltipDirective, TranslatePipe, UpdateUserDto } from '@app/shared'; +import { FormErrorComponent, FormRowComponent, LayoutComponent, ShortcutDirective, Subscriptions, TitleComponent, TooltipDirective, TranslatePipe, UpdateUserDto } from '@app/shared'; import { UserDto, UserForm, UsersState } from '../../internal'; @Component({ @@ -18,8 +18,8 @@ import { UserDto, UserForm, UsersState } from '../../internal'; templateUrl: './user-page.component.html', imports: [ AsyncPipe, - ControlErrorsComponent, FormErrorComponent, + FormRowComponent, FormsModule, LayoutComponent, ReactiveFormsModule, diff --git a/frontend/src/app/features/api/pages/graphql/graphql-page.component.html b/frontend/src/app/features/api/pages/graphql/graphql-page.component.html index 7337d3dbf..f52da177f 100644 --- a/frontend/src/app/features/api/pages/graphql/graphql-page.component.html +++ b/frontend/src/app/features/api/pages/graphql/graphql-page.component.html @@ -10,8 +10,7 @@ {{ "api.selectClient" | sqxTranslate }} {{ "api.selectClientDescription" | sqxTranslate }} -
- + -
+
diff --git a/frontend/src/app/features/api/pages/graphql/graphql-page.component.ts b/frontend/src/app/features/api/pages/graphql/graphql-page.component.ts index 11ec19044..3997fd54b 100644 --- a/frontend/src/app/features/api/pages/graphql/graphql-page.component.ts +++ b/frontend/src/app/features/api/pages/graphql/graphql-page.component.ts @@ -12,7 +12,7 @@ import { createGraphiQLFetcher } from '@graphiql/toolkit'; import { GraphiQL } from 'graphiql'; import * as React from 'react'; import * as ReactDOM from 'react-dom/client'; -import { ApiUrlConfig, AppsState, AuthService, ClientDto, ClientsService, ClientsState, DialogModel, FormHintComponent, LayoutComponent, MessageBus, ModalDialogComponent, ModalDirective, QueryExecuted, TitleComponent, TooltipDirective, TourStepDirective, TranslatePipe, Types } from '@app/shared'; +import { ApiUrlConfig, AppsState, AuthService, ClientDto, ClientsService, ClientsState, DialogModel, FormHintComponent, FormRowComponent, LayoutComponent, MessageBus, ModalDialogComponent, ModalDirective, QueryExecuted, TitleComponent, TooltipDirective, TourStepDirective, TranslatePipe, Types } from '@app/shared'; @Component({ selector: 'sqx-graphql-page', @@ -22,6 +22,7 @@ import { ApiUrlConfig, AppsState, AuthService, ClientDto, ClientsService, Client AsyncPipe, FormHintComponent, FormsModule, + FormRowComponent, LayoutComponent, ModalDialogComponent, ModalDirective, diff --git a/frontend/src/app/features/apps/pages/onboarding-dialog.component.html b/frontend/src/app/features/apps/pages/onboarding-dialog.component.html index 878b13cb1..c5907bc5a 100644 --- a/frontend/src/app/features/apps/pages/onboarding-dialog.component.html +++ b/frontend/src/app/features/apps/pages/onboarding-dialog.component.html @@ -30,8 +30,7 @@
-
- + -
+ -
- + -
+ -
- + -
+ +
diff --git a/frontend/src/app/features/apps/pages/onboarding-dialog.component.ts b/frontend/src/app/features/apps/pages/onboarding-dialog.component.ts index e88a74b12..2037a077d 100644 --- a/frontend/src/app/features/apps/pages/onboarding-dialog.component.ts +++ b/frontend/src/app/features/apps/pages/onboarding-dialog.component.ts @@ -8,7 +8,7 @@ import { Component, EventEmitter, Output } from '@angular/core'; import { FormBuilder, FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { fadeAnimation, MarkdownDirective, ModalDialogComponent, slideAnimation, TourState, TranslatePipe, UsersService } from '@app/shared'; +import { fadeAnimation, FormRowComponent, MarkdownDirective, ModalDialogComponent, slideAnimation, TourState, TranslatePipe, UsersService } from '@app/shared'; @Component({ selector: 'sqx-onboarding-dialog', @@ -18,6 +18,7 @@ import { fadeAnimation, MarkdownDirective, ModalDialogComponent, slideAnimation, fadeAnimation, slideAnimation, ], imports: [ + FormRowComponent, FormsModule, MarkdownDirective, ModalDialogComponent, diff --git a/frontend/src/app/features/assets/pages/asset-tag-dialog.component.html b/frontend/src/app/features/assets/pages/asset-tag-dialog.component.html index 876cca638..fd82f2f77 100644 --- a/frontend/src/app/features/assets/pages/asset-tag-dialog.component.html +++ b/frontend/src/app/features/assets/pages/asset-tag-dialog.component.html @@ -3,13 +3,9 @@ {{ "common.renameTag" | sqxTranslate }} -
- - + -
+
diff --git a/frontend/src/app/features/assets/pages/asset-tag-dialog.component.ts b/frontend/src/app/features/assets/pages/asset-tag-dialog.component.ts index 18cdeded5..ad142d711 100644 --- a/frontend/src/app/features/assets/pages/asset-tag-dialog.component.ts +++ b/frontend/src/app/features/assets/pages/asset-tag-dialog.component.ts @@ -8,8 +8,8 @@ import { AsyncPipe } from '@angular/common'; import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { ControlErrorsComponent, FocusOnInitDirective, FormErrorComponent, ModalDialogComponent, TooltipDirective, TranslatePipe } from '@app/shared'; -import { AssetsState, RenameAssetTagForm } from '@app/shared/internal'; +import { FocusOnInitDirective, FormErrorComponent, ModalDialogComponent, TooltipDirective, TranslatePipe } from '@app/shared'; +import { AssetsState, FormRowComponent, RenameAssetTagForm } from '@app/shared/internal'; @Component({ selector: 'sqx-asset-tag-dialog', @@ -17,9 +17,9 @@ import { AssetsState, RenameAssetTagForm } from '@app/shared/internal'; templateUrl: './asset-tag-dialog.component.html', imports: [ AsyncPipe, - ControlErrorsComponent, FocusOnInitDirective, FormErrorComponent, + FormRowComponent, FormsModule, ModalDialogComponent, ReactiveFormsModule, diff --git a/frontend/src/app/features/content/pages/calendar/calendar-page.component.html b/frontend/src/app/features/content/pages/calendar/calendar-page.component.html index b8b30db0b..a85fbdbbc 100644 --- a/frontend/src/app/features/content/pages/calendar/calendar-page.component.html +++ b/frontend/src/app/features/content/pages/calendar/calendar-page.component.html @@ -25,66 +25,47 @@ @if (contentSelected && contentSelected.scheduleJob) {
-
- -
-
- - -
+ +
+ +
-
+ -
- - -
+ + + {{ createContentName(contentSelected) }} + + -
- - -
+ + {{ contentSelected.schemaDisplayName }} + -
- -
- -
-
+ + +
-
- -
- -
-
+ + + -
- -
{{ contentSelected.scheduleJob.dueTime | sqxFullDateTime }}
-
+ + {{ contentSelected.scheduleJob.dueTime | sqxFullDateTime }} + -
- -
- - {{ contentSelected.scheduleJob.scheduledBy | sqxUserNameRef }} -
-
+ + + {{ contentSelected.scheduleJob.scheduledBy | sqxUserNameRef }} + @if (contentSelected.canCancelStatus) {
diff --git a/frontend/src/app/features/content/pages/calendar/calendar-page.component.ts b/frontend/src/app/features/content/pages/calendar/calendar-page.component.ts index b3f06bfac..49802dfd9 100644 --- a/frontend/src/app/features/content/pages/calendar/calendar-page.component.ts +++ b/frontend/src/app/features/content/pages/calendar/calendar-page.component.ts @@ -9,7 +9,7 @@ import { AfterViewInit, ChangeDetectorRef, Component, ElementRef, HostListener, OnDestroy, OnInit, ViewChild } from '@angular/core'; import { FormsModule } from '@angular/forms'; import { RouterLink } from '@angular/router'; -import { AppLanguageDto, AppsState, ConfirmClickDirective, ContentDto, ContentsService, ContentStatusComponent, CopyDirective, DateTime, DialogModel, FullDateTimePipe, getContentValue, LanguagesState, LayoutComponent, LocalizerService, ModalDialogComponent, ModalDirective, ResourceLoaderService, TitleComponent, TooltipDirective, TranslatePipe, UserNameRefPipe, UserPictureRefPipe } from '@app/shared'; +import { AppLanguageDto, AppsState, ConfirmClickDirective, ContentDto, ContentsService, ContentStatusComponent, CopyDirective, DateTime, DialogModel, FormRowComponent, FullDateTimePipe, getContentValue, LanguagesState, LayoutComponent, LocalizerService, ModalDialogComponent, ModalDirective, ResourceLoaderService, TitleComponent, TooltipDirective, TranslatePipe, UserNameRefPipe, UserPictureRefPipe } from '@app/shared'; declare const tui: any; @@ -23,6 +23,7 @@ type ViewMode = 'day' | 'week' | 'month'; ConfirmClickDirective, ContentStatusComponent, CopyDirective, + FormRowComponent, FormsModule, FullDateTimePipe, LayoutComponent, diff --git a/frontend/src/app/features/rules/pages/rule/step-dialog.component.html b/frontend/src/app/features/rules/pages/rule/step-dialog.component.html index 48654df8b..8de2aab03 100644 --- a/frontend/src/app/features/rules/pages/rule/step-dialog.component.html +++ b/frontend/src/app/features/rules/pages/rule/step-dialog.component.html @@ -10,111 +10,92 @@ @if (currentStep) {
-
- -
- - {{ "rules.stepNameHint" | sqxTranslate }} -
-
+ + + -
-
-
- - -
- {{ "rules.stepIgnoreErrorHint" | sqxTranslate }} -
-
+ + +
@for (property of currentStep.editableProperties; track property.name) { -
- -
- - @switch (property.editor) { - @case ("Text") { - @if (property.isFormattable) { - - } @else { - - } + + @switch (property.editor) { + @case ("Text") { + @if (property.isFormattable) { + + } @else { + } + } - @case ("TextArea") { - @if (property.isFormattable) { - - } @else { - - } + @case ("TextArea") { + @if (property.isFormattable) { + + } @else { + } + } - @case ("Javascript") { - - } + @case ("Javascript") { + + } - @case ("Checkbox") { -
- - -
- } + @case ("Checkbox") { +
+ + +
+ } - @case ("Dropdown") { - + @if (!property.isRequired) { + + } - @for (option of property.options; track option) { - - } - - } + @for (option of property.options; track option) { + + } + + } - @case ("Branches") { - - } + @case ("Branches") { + + } - @default { - - } + @default { + } - - - @if (property.isFormattable) { -
- {{ "rules.advancedFormattingHint" | sqxTranslate }}: - - {{ "common.documentation" | sqxTranslate }} - -
- } -
-
-
+ } + + + @if (property.isFormattable) { +
+ {{ "rules.advancedFormattingHint" | sqxTranslate }}: + + {{ "common.documentation" | sqxTranslate }} + +
+ } +
+ }
} @else { diff --git a/frontend/src/app/features/rules/pages/rule/step-dialog.component.ts b/frontend/src/app/features/rules/pages/rule/step-dialog.component.ts index 698bcf2de..e889e2ef7 100644 --- a/frontend/src/app/features/rules/pages/rule/step-dialog.component.ts +++ b/frontend/src/app/features/rules/pages/rule/step-dialog.component.ts @@ -8,7 +8,7 @@ import { AsyncPipe, LowerCasePipe } from '@angular/common'; import { booleanAttribute, Component, EventEmitter, Input, Output } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { AppsState, CodeEditorComponent, ControlErrorsComponent, DynamicFlowStepDefinitionDto, EntriesPipe, FormErrorComponent, FormHintComponent, MarkdownDirective, ModalDialogComponent, RuleElementDto, RulesService, ScriptCompletions, StepForm, TranslatePipe, TypedSimpleChanges } from '@app/shared'; +import { AppsState, CodeEditorComponent, DynamicFlowStepDefinitionDto, EntriesPipe, FormErrorComponent, FormHintComponent, FormRowComponent, MarkdownDirective, ModalDialogComponent, RuleElementDto, RulesService, ScriptCompletions, StepForm, TranslatePipe, TypedSimpleChanges } from '@app/shared'; import { BranchesInputComponent } from '../../shared/actions/branches-input.component'; import { FormattableInputComponent } from '../../shared/actions/formattable-input.component'; import { RuleElementComponent } from '../../shared/rule-element.component'; @@ -21,11 +21,11 @@ import { RuleElementComponent } from '../../shared/rule-element.component'; AsyncPipe, BranchesInputComponent, CodeEditorComponent, - ControlErrorsComponent, EntriesPipe, FormattableInputComponent, FormErrorComponent, FormHintComponent, + FormRowComponent, FormsModule, LowerCasePipe, MarkdownDirective, diff --git a/frontend/src/app/features/rules/shared/actions/branches-input.component.html b/frontend/src/app/features/rules/shared/actions/branches-input.component.html index 692fb8874..fa30cddde 100644 --- a/frontend/src/app/features/rules/shared/actions/branches-input.component.html +++ b/frontend/src/app/features/rules/shared/actions/branches-input.component.html @@ -1,5 +1,5 @@ @for (form of branchesControls; track form; let i = $index) { -
+
diff --git a/frontend/src/app/features/rules/shared/state-step-property.component.html b/frontend/src/app/features/rules/shared/state-step-property.component.html index c8353812e..1ad68618f 100644 --- a/frontend/src/app/features/rules/shared/state-step-property.component.html +++ b/frontend/src/app/features/rules/shared/state-step-property.component.html @@ -1,12 +1,9 @@ -
- -
- @if (valueType === "MultilineJson") { - - } @else if (valueType === "MultilineAny") { - - } @else { -
{{ valueFormatted }}
- } -
-
+ + @if (valueType === "MultilineJson") { + + } @else if (valueType === "MultilineAny") { + + } @else { +
{{ valueFormatted }}
+ } +
diff --git a/frontend/src/app/features/rules/shared/state-step-property.component.ts b/frontend/src/app/features/rules/shared/state-step-property.component.ts index 15e8486fd..6e81136d8 100644 --- a/frontend/src/app/features/rules/shared/state-step-property.component.ts +++ b/frontend/src/app/features/rules/shared/state-step-property.component.ts @@ -8,7 +8,7 @@ import { ChangeDetectionStrategy, Component, Input } from '@angular/core'; import { FormsModule } from '@angular/forms'; -import { CodeEditorComponent, RuleElementPropertyDto, Types } from '@app/shared'; +import { CodeEditorComponent, FormRowComponent, RuleElementPropertyDto, Types } from '@app/shared'; @Component({ selector: 'sqx-state-step-property', @@ -17,6 +17,7 @@ import { CodeEditorComponent, RuleElementPropertyDto, Types } from '@app/shared' changeDetection: ChangeDetectionStrategy.OnPush, imports: [ CodeEditorComponent, + FormRowComponent, FormsModule, ], }) diff --git a/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.html b/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.html index 9e6afba43..e65c75a11 100644 --- a/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.html +++ b/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.html @@ -1,31 +1,26 @@
-
- + + -
- - +
+

{{ "common.conditions" | sqxTranslate }}

+ {{ "rules.conditionHint2" | sqxTranslate }} +
    +
  • + {{ "rules.conditions.event" | sqxTranslate }}:
    + event.type == 'Created' || event.type == 'Updated' +
  • -
    -

    {{ "common.conditions" | sqxTranslate }}

    - {{ "rules.conditionHint2" | sqxTranslate }} -
      -
    • - {{ "rules.conditions.event" | sqxTranslate }}:
      - event.type == 'Created' || event.type == 'Updated' -
    • +
    • + {{ "rules.conditions.largeAssets" | sqxTranslate }}:
      + event.fileSize > 100000000 +
    • -
    • - {{ "rules.conditions.largeAssets" | sqxTranslate }}:
      - event.fileSize > 100000000 -
    • - -
    • - {{ "rules.conditions.images" | sqxTranslate }}:
      - event.isImage -
    • -
    -
    +
  • + {{ "rules.conditions.images" | sqxTranslate }}:
    + event.isImage +
  • +
-
+
diff --git a/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.ts b/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.ts index 8a8719680..ebc8d78c5 100644 --- a/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.ts +++ b/frontend/src/app/features/rules/shared/triggers/asset-changed-trigger.component.ts @@ -7,7 +7,7 @@ import { Component, Input } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe, TriggerForm } from '@app/shared'; +import { CodeComponent, FormHintComponent, FormRowComponent, TranslatePipe, TriggerForm } from '@app/shared'; @Component({ selector: 'sqx-asset-changed-trigger', @@ -15,8 +15,8 @@ import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe templateUrl: './asset-changed-trigger.component.html', imports: [ CodeComponent, - ControlErrorsComponent, FormHintComponent, + FormRowComponent, FormsModule, ReactiveFormsModule, TranslatePipe, diff --git a/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.html b/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.html index 33b013fee..e28e8e9d3 100644 --- a/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.html +++ b/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.html @@ -1,26 +1,21 @@
-
- + + -
- - +
+

{{ "common.conditions" | sqxTranslate }}

+ {{ "rules.conditionHint2" | sqxTranslate }} +
    +
  • + {{ "rules.conditions.commentUser" | sqxTranslate }}:
    + event.mentionedUser.email === 'mail2stehle@gmail.com' +
  • -
    -

    {{ "common.conditions" | sqxTranslate }}

    - {{ "rules.conditionHint2" | sqxTranslate }} -
      -
    • - {{ "rules.conditions.commentUser" | sqxTranslate }}:
      - event.mentionedUser.email === 'mail2stehle@gmail.com' -
    • - -
    • - {{ "rules.conditions.commentKeyword" | sqxTranslate }}:
      - event.text.indexOf('urgent') >= 0 -
    • -
    -
    +
  • + {{ "rules.conditions.commentKeyword" | sqxTranslate }}:
    + event.text.indexOf('urgent') >= 0 +
  • +
-
+
diff --git a/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.ts b/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.ts index 2f3cdf78a..52856685e 100644 --- a/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.ts +++ b/frontend/src/app/features/rules/shared/triggers/comment-trigger.component.ts @@ -7,7 +7,7 @@ import { Component, Input } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe, TriggerForm } from '@app/shared'; +import { CodeComponent, FormHintComponent, FormRowComponent, TranslatePipe, TriggerForm } from '@app/shared'; @Component({ selector: 'sqx-comment-trigger', @@ -15,8 +15,8 @@ import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe templateUrl: './comment-trigger.component.html', imports: [ CodeComponent, - ControlErrorsComponent, FormHintComponent, + FormRowComponent, FormsModule, ReactiveFormsModule, TranslatePipe, diff --git a/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.html b/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.html index 60df975cc..4f3134861 100644 --- a/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.html +++ b/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.html @@ -1,56 +1,45 @@
-
- + + -
- - - - - {{ "rules.conditions.cronExpressionHint" | sqxTranslate }} -
- {{ "rules.readMore" | sqxTranslate }}: - - {{ "common.documentation" | sqxTranslate }} - -
-
+ + {{ "rules.conditions.cronExpressionHint" | sqxTranslate }} +
+ {{ "rules.readMore" | sqxTranslate }}: + + {{ "common.documentation" | sqxTranslate }} + +
+
-
-

{{ "rules.conditions.cronExpressionsTitle" | sqxTranslate }}

- {{ "rules.conditions.cronExpressionsHint" | sqxTranslate }} -
    -
  • - {{ "rules.conditions.cronExpressionEvery4Hours" | sqxTranslate }}:
    - 0 */4 * * * -
  • +
    +

    {{ "rules.conditions.cronExpressionsTitle" | sqxTranslate }}

    + {{ "rules.conditions.cronExpressionsHint" | sqxTranslate }} +
      +
    • + {{ "rules.conditions.cronExpressionEvery4Hours" | sqxTranslate }}:
      + 0 */4 * * * +
    • -
    • - {{ "rules.conditions.cronExpressionEveryMorning" | sqxTranslate }}:
      - 0 6 * * * -
    • +
    • + {{ "rules.conditions.cronExpressionEveryMorning" | sqxTranslate }}:
      + 0 6 * * * +
    • -
    • - {{ "rules.conditions.cronExpressionEveryMonth" | sqxTranslate }}:
      - 0 6 1 * * -
    • -
    -
    +
  • + {{ "rules.conditions.cronExpressionEveryMonth" | sqxTranslate }}:
    + 0 6 1 * * +
  • +
-
+
-
- - -
- - - {{ "rules.conditions.cronTimezoneHint" | sqxTranslate }} -
-
+ + +
diff --git a/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.ts b/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.ts index b96c07904..49b2d4720 100644 --- a/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.ts +++ b/frontend/src/app/features/rules/shared/triggers/cron-job-trigger.component.ts @@ -8,7 +8,7 @@ import { AsyncPipe } from '@angular/common'; import { Component, Input } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { AppsState, CodeComponent, ControlErrorsComponent, FormHintComponent, RulesService, TranslatePipe, TriggerForm } from '@app/shared'; +import { AppsState, CodeComponent, FormHintComponent, FormRowComponent, RulesService, TranslatePipe, TriggerForm } from '@app/shared'; @Component({ selector: 'sqx-cron-job-trigger', @@ -17,8 +17,8 @@ import { AppsState, CodeComponent, ControlErrorsComponent, FormHintComponent, Ru imports: [ AsyncPipe, CodeComponent, - ControlErrorsComponent, FormHintComponent, + FormRowComponent, FormsModule, ReactiveFormsModule, TranslatePipe, diff --git a/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.html b/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.html index 0852fddd2..553df049c 100644 --- a/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.html +++ b/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.html @@ -1,26 +1,21 @@
-
- + + -
- - +
+

{{ "common.conditions" | sqxTranslate }}

+ {{ "rules.conditionHint2" | sqxTranslate }} +
    +
  • + {{ "rules.conditions.event" | sqxTranslate }}:
    + event.type == 'Created' || event.type == 'Updated' +
  • -
    -

    {{ "common.conditions" | sqxTranslate }}

    - {{ "rules.conditionHint2" | sqxTranslate }} -
      -
    • - {{ "rules.conditions.event" | sqxTranslate }}:
      - event.type == 'Created' || event.type == 'Updated' -
    • - -
    • - {{ "rules.conditions.schema" | sqxTranslate }}:
      - schemaId.name === 'my-schema' -
    • -
    -
    +
  • + {{ "rules.conditions.schema" | sqxTranslate }}:
    + schemaId.name === 'my-schema' +
  • +
-
+
diff --git a/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.ts b/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.ts index 3fe4bf155..43f153893 100644 --- a/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.ts +++ b/frontend/src/app/features/rules/shared/triggers/schema-changed-trigger.component.ts @@ -7,7 +7,7 @@ import { Component, Input } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe, TriggerForm } from '@app/shared'; +import { CodeComponent, FormHintComponent, FormRowComponent, TranslatePipe, TriggerForm } from '@app/shared'; @Component({ selector: 'sqx-schema-changed-trigger', @@ -15,8 +15,8 @@ import { CodeComponent, ControlErrorsComponent, FormHintComponent, TranslatePipe templateUrl: './schema-changed-trigger.component.html', imports: [ CodeComponent, - ControlErrorsComponent, FormHintComponent, + FormRowComponent, FormsModule, ReactiveFormsModule, TranslatePipe, diff --git a/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.html b/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.html index 26adad6d8..8d124359a 100644 --- a/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.html +++ b/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.html @@ -1,21 +1,9 @@
-
- + + + -
- - - {{ "rules.conditions.usageLimitHint" | sqxTranslate }} -
-
- -
- - -
- - - {{ "rules.conditions.usageDaysHint" | sqxTranslate }} -
-
+ + +
diff --git a/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.ts b/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.ts index 2a686de07..4f68fa076 100644 --- a/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.ts +++ b/frontend/src/app/features/rules/shared/triggers/usage-trigger.component.ts @@ -7,18 +7,16 @@ import { Component, Input } from '@angular/core'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { ControlErrorsComponent, FormHintComponent, TranslatePipe, TriggerForm } from '@app/shared'; +import { FormRowComponent, TriggerForm } from '@app/shared'; @Component({ selector: 'sqx-usage-trigger', styleUrls: ['./usage-trigger.component.scss'], templateUrl: './usage-trigger.component.html', imports: [ - ControlErrorsComponent, - FormHintComponent, + FormRowComponent, FormsModule, ReactiveFormsModule, - TranslatePipe, ], }) export class UsageTriggerComponent { diff --git a/frontend/src/app/features/schemas/pages/schema/common/schema-edit-form.component.html b/frontend/src/app/features/schemas/pages/schema/common/schema-edit-form.component.html index 8c0de90f7..327568261 100644 --- a/frontend/src/app/features/schemas/pages/schema/common/schema-edit-form.component.html +++ b/frontend/src/app/features/schemas/pages/schema/common/schema-edit-form.component.html @@ -3,67 +3,41 @@
-
- + -
- -
- - + + + - {{ "schemas.schemaLabelHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.schemaHintsHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.contentsSidebarUrlHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.contentSidebarUrlHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.contentEditorUrlHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.contentsListUrlHint" | sqxTranslate }} -
+ -
- - + - {{ "schemas.schemaTagsHint" | sqxTranslate }} -
+ -
-
+ - -
- {{ "schemas.validateOnPublishHint" | sqxTranslate }} -
+