@ks89/angular-modal-gallery
Version:
Image gallery for Angular
45 lines (44 loc) • 1.8 kB
TypeScript
import { ElementRef, OnChanges, OnInit, Renderer2 } from '@angular/core';
import * as i0 from "@angular/core";
/**
* Directive to change margins of an element.
*/
export declare class MarginDirective implements OnInit, OnChanges {
private renderer;
private el;
/**
* String to set the margin of an element.
*/
marginLeft: string | undefined;
/**
* String to set the margin of an element.
*/
marginRight: string | undefined;
/**
* String to set the margin of an element.
*/
marginTop: string | undefined;
/**
* String to set the margin of an element.
*/
marginBottom: string | undefined;
constructor(renderer: Renderer2, el: ElementRef);
/**
* Method ´ngOnInit´ to apply the style of this directive.
* This is an angular lifecycle hook, so its called automatically by Angular itself.
* In particular, it's called only one time!!!
*/
ngOnInit(): void;
/**
* Method ´ngOnChanges´ to apply the style of this directive.
* This is an angular lifecycle hook, so its called automatically by Angular itself.
* In particular, it's called when any data-bound property of a directive changes!!!
*/
ngOnChanges(): void;
/**
* Private method to change both width and height of an element.
*/
private applyStyle;
static ɵfac: i0.ɵɵFactoryDeclaration<MarginDirective, never>;
static ɵdir: i0.ɵɵDirectiveDeclaration<MarginDirective, "[ksMargin]", never, { "marginLeft": { "alias": "marginLeft"; "required": false; }; "marginRight": { "alias": "marginRight"; "required": false; }; "marginTop": { "alias": "marginTop"; "required": false; }; "marginBottom": { "alias": "marginBottom"; "required": false; }; }, {}, never, never, false, never>;
}