UNPKG

1.5 kBTypeScriptView Raw
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8import { ElementRef, OnChanges } from '@angular/core';
9import { Directionality } from '@angular/cdk/bidi';
10import { MediaMarshaller, BaseDirective2, StyleBuilder, StyleDefinition, StyleUtils } from '@angular/flex-layout/core';
11export interface FlexOffsetParent {
12 layout: string;
13 isRtl: boolean;
14}
15export declare class FlexOffsetStyleBuilder extends StyleBuilder {
16 buildStyles(offset: string, parent: FlexOffsetParent): StyleDefinition;
17}
18/**
19 * 'flex-offset' flexbox styling directive
20 * Configures the 'margin-left' of the element in a layout container
21 */
22export declare class FlexOffsetDirective extends BaseDirective2 implements OnChanges {
23 protected directionality: Directionality;
24 protected DIRECTIVE_KEY: string;
25 constructor(elRef: ElementRef, directionality: Directionality, styleBuilder: FlexOffsetStyleBuilder, marshal: MediaMarshaller, styler: StyleUtils);
26 /**
27 * Using the current fxFlexOffset value, update the inline CSS
28 * NOTE: this will assign `margin-left` if the parent flex-direction == 'row',
29 * otherwise `margin-top` is used for the offset.
30 */
31 protected updateWithValue(value?: string | number): void;
32}
33export declare class DefaultFlexOffsetDirective extends FlexOffsetDirective {
34 protected inputs: string[];
35}