MOBILE-4587 core: Remove unused ion-content from core-link
parent
e922234787
commit
b2a70de9f1
|
@ -27,7 +27,6 @@ import {
|
||||||
Inject,
|
Inject,
|
||||||
ChangeDetectorRef,
|
ChangeDetectorRef,
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { IonContent } from '@ionic/angular';
|
|
||||||
|
|
||||||
import { CoreSites } from '@services/sites';
|
import { CoreSites } from '@services/sites';
|
||||||
import { CoreDomUtils } from '@services/utils/dom';
|
import { CoreDomUtils } from '@services/utils/dom';
|
||||||
|
@ -104,7 +103,6 @@ export class CoreFormatTextDirective implements OnChanges, OnDestroy, AsyncDirec
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
element: ElementRef,
|
element: ElementRef,
|
||||||
@Optional() protected content: IonContent,
|
|
||||||
protected viewContainerRef: ViewContainerRef,
|
protected viewContainerRef: ViewContainerRef,
|
||||||
@Optional() @Inject(CORE_REFRESH_CONTEXT) protected refreshContext?: CoreRefreshContext,
|
@Optional() @Inject(CORE_REFRESH_CONTEXT) protected refreshContext?: CoreRefreshContext,
|
||||||
) {
|
) {
|
||||||
|
@ -503,8 +501,8 @@ export class CoreFormatTextDirective implements OnChanges, OnDestroy, AsyncDirec
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Angular 2 doesn't let adding directives dynamically. Create the CoreLinkDirective manually.
|
// Angular doesn't let adding directives dynamically. Create the CoreLinkDirective manually.
|
||||||
const linkDir = new CoreLinkDirective(new ElementRef(anchor), this.content);
|
const linkDir = new CoreLinkDirective(new ElementRef(anchor));
|
||||||
linkDir.capture = this.captureLinks ?? true;
|
linkDir.capture = this.captureLinks ?? true;
|
||||||
linkDir.inApp = this.openLinksInApp;
|
linkDir.inApp = this.openLinksInApp;
|
||||||
linkDir.ngOnInit();
|
linkDir.ngOnInit();
|
||||||
|
|
|
@ -12,9 +12,8 @@
|
||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import { Directive, Input, OnInit, ElementRef, Optional, SecurityContext } from '@angular/core';
|
import { Directive, Input, OnInit, ElementRef, SecurityContext } from '@angular/core';
|
||||||
import { SafeUrl } from '@angular/platform-browser';
|
import { SafeUrl } from '@angular/platform-browser';
|
||||||
import { IonContent } from '@ionic/angular';
|
|
||||||
|
|
||||||
import { CoreFileHelper } from '@services/file-helper';
|
import { CoreFileHelper } from '@services/file-helper';
|
||||||
import { CoreSites } from '@services/sites';
|
import { CoreSites } from '@services/sites';
|
||||||
|
@ -47,7 +46,6 @@ export class CoreLinkDirective implements OnInit {
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
element: ElementRef,
|
element: ElementRef,
|
||||||
@Optional() protected content: IonContent,
|
|
||||||
) {
|
) {
|
||||||
this.element = element.nativeElement;
|
this.element = element.nativeElement;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue