Skip to content

Commit

Permalink
MOBILE-4464 siteplugins: Add class to module-index and content
Browse files Browse the repository at this point in the history
  • Loading branch information
alfonso-salces committed Nov 9, 2023
1 parent 370c12d commit 894c946
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// limitations under the License.

import { CoreConstants } from '@/core/constants';
import { Component, OnInit, OnDestroy, Input, ViewChild } from '@angular/core';
import { Component, OnInit, OnDestroy, Input, ViewChild, HostBinding } from '@angular/core';
import { CoreIonLoadingElement } from '@classes/ion-loading';

import { CoreSiteWSPreSets } from '@classes/site';
Expand Down Expand Up @@ -54,7 +54,7 @@ export class CoreSitePluginsModuleIndexComponent implements OnInit, OnDestroy, C

@ViewChild(CoreSitePluginsPluginContentComponent) content?: CoreSitePluginsPluginContentComponent;

component?: string;
@HostBinding('class') component?: string;
method?: string;
args?: Record<string, unknown>;
initResult?: CoreSitePluginsContent | null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,18 @@
// See the License for the specific language governing permissions and
// limitations under the License.

import { Component, OnInit, Input, Output, EventEmitter, DoCheck, KeyValueDiffers, ViewChild, KeyValueDiffer } from '@angular/core';
import {
Component,
OnInit,
Input,
Output,
EventEmitter,
DoCheck,
KeyValueDiffers,
ViewChild,
KeyValueDiffer,
HostBinding,
} from '@angular/core';
import { Subject } from 'rxjs';
import { Md5 } from 'ts-md5';

Expand All @@ -37,7 +48,7 @@ export class CoreSitePluginsPluginContentComponent implements OnInit, DoCheck {
// Get the compile element. Don't set the right type to prevent circular dependencies.
@ViewChild('compile') compileComponent?: CoreCompileHtmlComponent;

@Input() component!: string;
@HostBinding('class') @Input() component!: string;
@Input() method!: string;
@Input() args?: Record<string, unknown>;
@Input() initResult?: CoreSitePluginsContent | null; // Result of the init WS call of the handler.
Expand Down

0 comments on commit 894c946

Please sign in to comment.