@danske/sapphire-angular 1.18.0 → 1.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/text-field/public_api.mjs +1 -2
- package/esm2020/lib/text-field/src/text-field-postfix.directive.mjs +17 -4
- package/esm2020/lib/text-field/src/text-field-prefix.directive.mjs +17 -4
- package/esm2020/lib/text-field/src/text-field.component.mjs +4 -20
- package/esm2020/lib/text-field/src/text-field.module.mjs +1 -6
- package/esm2020/lib/theme/src/themes.mjs +4 -4
- package/fesm2015/danske-sapphire-angular.mjs +38 -55
- package/fesm2015/danske-sapphire-angular.mjs.map +1 -1
- package/fesm2020/danske-sapphire-angular.mjs +37 -55
- package/fesm2020/danske-sapphire-angular.mjs.map +1 -1
- package/lib/text-field/public_api.d.ts +0 -1
- package/lib/text-field/src/text-field-postfix.directive.d.ts +6 -1
- package/lib/text-field/src/text-field-prefix.directive.d.ts +6 -1
- package/lib/text-field/src/text-field.component.d.ts +1 -5
- package/lib/text-field/src/text-field.module.d.ts +9 -10
- package/package.json +3 -3
- package/esm2020/lib/text-field/src/text-field-affix.directive.mjs +0 -26
- package/lib/text-field/src/text-field-affix.directive.d.ts +0 -10
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export { TextFieldComponent } from './src/text-field.component';
|
|
2
2
|
export { TextFieldInputDirective } from './src/text-field-input.directive';
|
|
3
|
-
export { TextFieldAffixDirective } from './src/text-field-affix.directive';
|
|
4
3
|
export { TextFieldPrefixDirective } from './src/text-field-prefix.directive';
|
|
5
4
|
export { TextFieldPostfixDirective } from './src/text-field-postfix.directive';
|
|
6
5
|
export { TextFieldTextareaAutosizeDirective } from './src/text-field-textarea-autosize.directive';
|
|
@@ -1,5 +1,10 @@
|
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
1
2
|
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "../../common/sapphire-view-encapsulation";
|
|
2
4
|
export declare class TextFieldPostfixDirective {
|
|
5
|
+
private _elementRef;
|
|
6
|
+
isTextNode(): boolean;
|
|
7
|
+
constructor(_elementRef: ElementRef<HTMLElement>);
|
|
3
8
|
static ɵfac: i0.ɵɵFactoryDeclaration<TextFieldPostfixDirective, never>;
|
|
4
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<TextFieldPostfixDirective, "sp-text-field-postfix", never, {}, {}, never, never, false,
|
|
9
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<TextFieldPostfixDirective, "sp-text-field-postfix", never, {}, {}, never, never, false, [{ directive: typeof i1.UseComponentStyles; inputs: {}; outputs: {}; }]>;
|
|
5
10
|
}
|
|
@@ -1,5 +1,10 @@
|
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
1
2
|
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "../../common/sapphire-view-encapsulation";
|
|
2
4
|
export declare class TextFieldPrefixDirective {
|
|
5
|
+
private _elementRef;
|
|
6
|
+
isTextNode(): boolean;
|
|
7
|
+
constructor(_elementRef: ElementRef<HTMLElement>);
|
|
3
8
|
static ɵfac: i0.ɵɵFactoryDeclaration<TextFieldPrefixDirective, never>;
|
|
4
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<TextFieldPrefixDirective, "sp-text-field-prefix", never, {}, {}, never, never, false,
|
|
9
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<TextFieldPrefixDirective, "sp-text-field-prefix", never, {}, {}, never, never, false, [{ directive: typeof i1.UseComponentStyles; inputs: {}; outputs: {}; }]>;
|
|
5
10
|
}
|
|
@@ -10,14 +10,10 @@ export declare class TextFieldComponent implements FieldControl {
|
|
|
10
10
|
characterCounterMax?: NumberInput;
|
|
11
11
|
inputElement?: ElementRef<HTMLInputElement | HTMLTextAreaElement>;
|
|
12
12
|
_inputDirective?: TextFieldInputDirective;
|
|
13
|
-
private prefixDirective?;
|
|
14
|
-
private postfixDirective?;
|
|
15
13
|
constructor(field?: FieldComponent | undefined);
|
|
16
14
|
isCharacterCounterExceeded(): boolean;
|
|
17
|
-
hasPrefix(): boolean;
|
|
18
|
-
hasPostfix(): boolean;
|
|
19
15
|
isDisabled(): boolean;
|
|
20
16
|
getId(): string | undefined;
|
|
21
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<TextFieldComponent, [{ optional: true; }]>;
|
|
22
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<TextFieldComponent, "sp-text-field", never, { "characterCounterMax": "characterCounterMax"; }, {}, ["inputElement", "_inputDirective"
|
|
18
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TextFieldComponent, "sp-text-field", never, { "characterCounterMax": "characterCounterMax"; }, {}, ["inputElement", "_inputDirective"], ["sp-text-field-prefix", "input", "sp-text-field-postfix", "textarea"], false, [{ directive: typeof i1.ThemeCheckDirective; inputs: {}; outputs: {}; }, { directive: typeof i2.UseComponentStylesOnHost; inputs: {}; outputs: {}; }]>;
|
|
23
19
|
}
|
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
import * as i1 from "./text-field.component";
|
|
3
3
|
import * as i2 from "./text-field-input.directive";
|
|
4
|
-
import * as i3 from "./text-field-
|
|
5
|
-
import * as i4 from "./text-field-
|
|
6
|
-
import * as i5 from "./text-field-
|
|
7
|
-
import * as i6 from "
|
|
8
|
-
import * as i7 from "@angular/
|
|
9
|
-
import * as i8 from "@angular/
|
|
10
|
-
import * as i9 from "
|
|
11
|
-
import * as i10 from "../../
|
|
12
|
-
import * as i11 from "../../field/src/field.module";
|
|
4
|
+
import * as i3 from "./text-field-prefix.directive";
|
|
5
|
+
import * as i4 from "./text-field-postfix.directive";
|
|
6
|
+
import * as i5 from "./text-field-textarea-autosize.directive";
|
|
7
|
+
import * as i6 from "@angular/common";
|
|
8
|
+
import * as i7 from "@angular/forms";
|
|
9
|
+
import * as i8 from "@angular/cdk/portal";
|
|
10
|
+
import * as i9 from "../../label/src/label.component";
|
|
11
|
+
import * as i10 from "../../field/src/field.module";
|
|
13
12
|
export declare class SapphireTextFieldModule {
|
|
14
13
|
static ɵfac: i0.ɵɵFactoryDeclaration<SapphireTextFieldModule, never>;
|
|
15
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<SapphireTextFieldModule, [typeof i1.TextFieldComponent, typeof i2.TextFieldInputDirective, typeof i3.
|
|
14
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<SapphireTextFieldModule, [typeof i1.TextFieldComponent, typeof i2.TextFieldInputDirective, typeof i3.TextFieldPrefixDirective, typeof i4.TextFieldPostfixDirective, typeof i5.TextFieldTextareaAutosizeDirective], [typeof i6.CommonModule, typeof i7.FormsModule, typeof i8.PortalModule, typeof i9.LabelComponent, typeof i10.SapphireFieldModule], [typeof i1.TextFieldComponent, typeof i2.TextFieldInputDirective, typeof i10.SapphireFieldModule, typeof i3.TextFieldPrefixDirective, typeof i4.TextFieldPostfixDirective, typeof i5.TextFieldTextareaAutosizeDirective]>;
|
|
16
15
|
static ɵinj: i0.ɵɵInjectorDeclaration<SapphireTextFieldModule>;
|
|
17
16
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danske/sapphire-angular",
|
|
3
|
-
"version": "1.18.
|
|
3
|
+
"version": "1.18.1",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
5
|
"description": "The Angular implementation of the Sapphire Design System from Danske Bank A/S",
|
|
6
6
|
"module": "fesm2015/danske-sapphire-angular.mjs",
|
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
"@danske/sapphire-icons": "^1.0.2"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@danske/sapphire-css": "^
|
|
19
|
+
"@danske/sapphire-css": "^27.0.1",
|
|
20
20
|
"tslib": "^2.3.0"
|
|
21
21
|
},
|
|
22
|
-
"gitHead": "
|
|
22
|
+
"gitHead": "ed8a61f0521fe4e7601d6b962e677cd9e151a401",
|
|
23
23
|
"es2020": "fesm2020/danske-sapphire-angular.mjs",
|
|
24
24
|
"esm2020": "esm2020/danske-sapphire-angular.mjs",
|
|
25
25
|
"fesm2020": "fesm2020/danske-sapphire-angular.mjs",
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { Directive } from '@angular/core';
|
|
2
|
-
import { UseComponentStyles } from '../../common/sapphire-view-encapsulation';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
import * as i1 from "../../common/sapphire-view-encapsulation";
|
|
5
|
-
export class TextFieldAffixDirective {
|
|
6
|
-
isTextNode() {
|
|
7
|
-
return (this._elementRef?.nativeElement.firstChild?.nodeType === Node.TEXT_NODE);
|
|
8
|
-
}
|
|
9
|
-
constructor(_elementRef) {
|
|
10
|
-
this._elementRef = _elementRef;
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
TextFieldAffixDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0", ngImport: i0, type: TextFieldAffixDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
|
|
14
|
-
TextFieldAffixDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.0", type: TextFieldAffixDirective, selector: "sp-text-field-prefix, sp-text-field-postfix", host: { properties: { "class.sapphire-text-field__affix--icon": "!isTextNode()" }, classAttribute: "sapphire-text-field__affix" }, hostDirectives: [{ directive: i1.UseComponentStyles }], ngImport: i0 });
|
|
15
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0", ngImport: i0, type: TextFieldAffixDirective, decorators: [{
|
|
16
|
-
type: Directive,
|
|
17
|
-
args: [{
|
|
18
|
-
selector: 'sp-text-field-prefix, sp-text-field-postfix',
|
|
19
|
-
host: {
|
|
20
|
-
class: 'sapphire-text-field__affix',
|
|
21
|
-
'[class.sapphire-text-field__affix--icon]': '!isTextNode()',
|
|
22
|
-
},
|
|
23
|
-
hostDirectives: [UseComponentStyles],
|
|
24
|
-
}]
|
|
25
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }]; } });
|
|
26
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGV4dC1maWVsZC1hZmZpeC5kaXJlY3RpdmUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9zcmMvbGliL3RleHQtZmllbGQvc3JjL3RleHQtZmllbGQtYWZmaXguZGlyZWN0aXZlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQWMsTUFBTSxlQUFlLENBQUM7QUFDdEQsT0FBTyxFQUFFLGtCQUFrQixFQUFFLE1BQU0sMENBQTBDLENBQUM7OztBQVU5RSxNQUFNLE9BQU8sdUJBQXVCO0lBQ2xDLFVBQVU7UUFDUixPQUFPLENBQ0wsSUFBSSxDQUFDLFdBQVcsRUFBRSxhQUFhLENBQUMsVUFBVSxFQUFFLFFBQVEsS0FBSyxJQUFJLENBQUMsU0FBUyxDQUN4RSxDQUFDO0lBQ0osQ0FBQztJQUVELFlBQW9CLFdBQW9DO1FBQXBDLGdCQUFXLEdBQVgsV0FBVyxDQUF5QjtJQUFHLENBQUM7O29IQVBqRCx1QkFBdUI7d0dBQXZCLHVCQUF1QjsyRkFBdkIsdUJBQXVCO2tCQVJuQyxTQUFTO21CQUFDO29CQUNULFFBQVEsRUFBRSw2Q0FBNkM7b0JBQ3ZELElBQUksRUFBRTt3QkFDSixLQUFLLEVBQUUsNEJBQTRCO3dCQUNuQywwQ0FBMEMsRUFBRSxlQUFlO3FCQUM1RDtvQkFDRCxjQUFjLEVBQUUsQ0FBQyxrQkFBa0IsQ0FBQztpQkFDckMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBEaXJlY3RpdmUsIEVsZW1lbnRSZWYgfSBmcm9tICdAYW5ndWxhci9jb3JlJztcbmltcG9ydCB7IFVzZUNvbXBvbmVudFN0eWxlcyB9IGZyb20gJy4uLy4uL2NvbW1vbi9zYXBwaGlyZS12aWV3LWVuY2Fwc3VsYXRpb24nO1xuXG5ARGlyZWN0aXZlKHtcbiAgc2VsZWN0b3I6ICdzcC10ZXh0LWZpZWxkLXByZWZpeCwgc3AtdGV4dC1maWVsZC1wb3N0Zml4JyxcbiAgaG9zdDoge1xuICAgIGNsYXNzOiAnc2FwcGhpcmUtdGV4dC1maWVsZF9fYWZmaXgnLFxuICAgICdbY2xhc3Muc2FwcGhpcmUtdGV4dC1maWVsZF9fYWZmaXgtLWljb25dJzogJyFpc1RleHROb2RlKCknLFxuICB9LFxuICBob3N0RGlyZWN0aXZlczogW1VzZUNvbXBvbmVudFN0eWxlc10sXG59KVxuZXhwb3J0IGNsYXNzIFRleHRGaWVsZEFmZml4RGlyZWN0aXZlIHtcbiAgaXNUZXh0Tm9kZSgpIHtcbiAgICByZXR1cm4gKFxuICAgICAgdGhpcy5fZWxlbWVudFJlZj8ubmF0aXZlRWxlbWVudC5maXJzdENoaWxkPy5ub2RlVHlwZSA9PT0gTm9kZS5URVhUX05PREVcbiAgICApO1xuICB9XG5cbiAgY29uc3RydWN0b3IocHJpdmF0ZSBfZWxlbWVudFJlZjogRWxlbWVudFJlZjxIVE1MRWxlbWVudD4pIHt9XG59XG4iXX0=
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { ElementRef } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
import * as i1 from "../../common/sapphire-view-encapsulation";
|
|
4
|
-
export declare class TextFieldAffixDirective {
|
|
5
|
-
private _elementRef;
|
|
6
|
-
isTextNode(): boolean;
|
|
7
|
-
constructor(_elementRef: ElementRef<HTMLElement>);
|
|
8
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<TextFieldAffixDirective, never>;
|
|
9
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<TextFieldAffixDirective, "sp-text-field-prefix, sp-text-field-postfix", never, {}, {}, never, never, false, [{ directive: typeof i1.UseComponentStyles; inputs: {}; outputs: {}; }]>;
|
|
10
|
-
}
|