@rijkshuisstijl-community/components-angular 1.0.0 → 1.2.0
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/README.md +55 -0
- package/dist/README.md +55 -0
- package/dist/button/button.component.d.ts +1 -2
- package/dist/column-layout/column-layout.component.d.ts +6 -0
- package/dist/data-summary/data-summary.component.d.ts +6 -0
- package/dist/data-summary-item/data-summary-item.component.d.ts +10 -0
- package/dist/fesm2022/rijkshuisstijl-community-components-angular.mjs +534 -11
- package/dist/fesm2022/rijkshuisstijl-community-components-angular.mjs.map +1 -1
- package/dist/figure/figure.component.d.ts +9 -0
- package/dist/figure-caption/figure-caption.component.d.ts +5 -0
- package/dist/footer/footer.component.d.ts +27 -0
- package/dist/form-field/form-field.component.d.ts +12 -0
- package/dist/form-field-description/form-field-description.component.d.ts +9 -0
- package/dist/form-field-error-message/form-field-error-message.component.d.ts +5 -0
- package/dist/form-field-text-input/form-field-text-input.component.d.ts +37 -0
- package/dist/form-label/form-label.component.d.ts +8 -0
- package/dist/image/image.component.d.ts +5 -0
- package/dist/link/link.component.d.ts +2 -1
- package/dist/link-list/link-list.component.d.ts +5 -0
- package/dist/link-list-item/link-list-item.component.d.ts +5 -0
- package/dist/link-list-link/link-list-link.component.d.ts +6 -0
- package/dist/logo/logo.component.d.ts +7 -0
- package/dist/navbar/navbar.component.d.ts +6 -0
- package/dist/navbar-item/end-item.directive.d.ts +9 -0
- package/dist/navbar-item/heading-item.directive.d.ts +6 -0
- package/dist/navbar-item/navbar-item.component.d.ts +6 -0
- package/dist/public-api.d.ts +23 -0
- package/dist/text-input/text-input.component.d.ts +9 -0
- package/dist/unordered-list/unordered-list.component.d.ts +6 -0
- package/dist/unordered-list-item/unordered-list-item.component.d.ts +5 -0
- package/package.json +23 -15
- package/.eslintrc.json +0 -5
- package/CHANGELOG.md +0 -15
- package/angular.json +0 -37
- package/jest.config.js +0 -5
- package/ng-package.json +0 -7
- package/setup-jest.ts +0 -3
- package/src/action-group/action-group.component.html +0 -9
- package/src/action-group/action-group.component.spec.ts +0 -46
- package/src/action-group/action-group.component.ts +0 -10
- package/src/button/button.component.html +0 -3
- package/src/button/button.component.spec.ts +0 -41
- package/src/button/button.component.ts +0 -14
- package/src/heading/heading.component.css +0 -1
- package/src/heading/heading.component.html +0 -31
- package/src/heading/heading.component.spec.ts +0 -54
- package/src/heading/heading.component.ts +0 -19
- package/src/icon/RHCIconIDs.ts +0 -1182
- package/src/icon/dutch-map-icon/dutch-map-icon.component.html +0 -6
- package/src/icon/dutch-map-icon/dutch-map-icon.component.ts +0 -8
- package/src/icon/flag-icons/bg-flag/bg-flag.component.html +0 -5
- package/src/icon/flag-icons/bg-flag/bg-flag.component.ts +0 -8
- package/src/icon/flag-icons/de-flag/de-flag.component.html +0 -6
- package/src/icon/flag-icons/de-flag/de-flag.component.ts +0 -8
- package/src/icon/flag-icons/es-flag/es-flag.component.html +0 -2233
- package/src/icon/flag-icons/es-flag/es-flag.component.ts +0 -8
- package/src/icon/flag-icons/fr-flag/fr-flag.component.html +0 -5
- package/src/icon/flag-icons/fr-flag/fr-flag.component.ts +0 -8
- package/src/icon/flag-icons/gr-flag/gr-flag.component.html +0 -4
- package/src/icon/flag-icons/gr-flag/gr-flag.component.ts +0 -8
- package/src/icon/flag-icons/hu-flag/hu-flag.component.html +0 -5
- package/src/icon/flag-icons/hu-flag/hu-flag.component.ts +0 -8
- package/src/icon/flag-icons/it-flag/it-flag.component.html +0 -5
- package/src/icon/flag-icons/it-flag/it-flag.component.ts +0 -8
- package/src/icon/flag-icons/lv-flag/lv-flag.component.html +0 -4
- package/src/icon/flag-icons/lv-flag/lv-flag.component.ts +0 -8
- package/src/icon/flag-icons/nl-flag/nl-flag.component.html +0 -5
- package/src/icon/flag-icons/nl-flag/nl-flag.component.ts +0 -8
- package/src/icon/flag-icons/pl-flag/pl-flag.component.html +0 -4
- package/src/icon/flag-icons/pl-flag/pl-flag.component.ts +0 -8
- package/src/icon/flag-icons/pt-flag/pt-flag.component.html +0 -156
- package/src/icon/flag-icons/pt-flag/pt-flag.component.ts +0 -8
- package/src/icon/flag-icons/ro-flag/ro-flag.component.html +0 -5
- package/src/icon/flag-icons/ro-flag/ro-flag.component.ts +0 -8
- package/src/icon/flag-icons/sk-flag/sk-flag.component.html +0 -34
- package/src/icon/flag-icons/sk-flag/sk-flag.component.ts +0 -8
- package/src/icon/flag-icons/uk-flag/uk-flag.component.html +0 -15
- package/src/icon/flag-icons/uk-flag/uk-flag.component.ts +0 -8
- package/src/icon/icon.component.css +0 -3
- package/src/icon/icon.component.html +0 -6
- package/src/icon/icon.component.spec.ts +0 -61
- package/src/icon/icon.component.ts +0 -105
- package/src/icon/public-api.ts +0 -16
- package/src/link/link.component.css +0 -1
- package/src/link/link.component.html +0 -3
- package/src/link/link.component.spec.ts +0 -33
- package/src/link/link.component.ts +0 -11
- package/src/paragraph/paragraph.component.css +0 -1
- package/src/paragraph/paragraph.component.html +0 -3
- package/src/paragraph/paragraph.component.spec.ts +0 -45
- package/src/paragraph/paragraph.component.ts +0 -23
- package/src/public-api.ts +0 -9
- package/tsconfig.json +0 -28
- package/tsconfig.lib.json +0 -11
- package/tsconfig.lib.prod.json +0 -9
- package/tsconfig.spec.json +0 -11
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FigureComponent {
|
|
3
|
+
borderEndEndRadius?: number;
|
|
4
|
+
borderEndStartRadius?: number;
|
|
5
|
+
borderStartEndRadius?: number;
|
|
6
|
+
borderStartStartRadius?: number;
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FigureComponent, never>;
|
|
8
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FigureComponent, "figure[rhc-figure]", never, { "borderEndEndRadius": { "alias": "borderEndEndRadius"; "required": false; }; "borderEndStartRadius": { "alias": "borderEndStartRadius"; "required": false; }; "borderStartEndRadius": { "alias": "borderStartEndRadius"; "required": false; }; "borderStartStartRadius": { "alias": "borderStartStartRadius"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FigureCaptionComponent {
|
|
3
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FigureCaptionComponent, never>;
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FigureCaptionComponent, "figcaption[rhc-figure-caption]", never, {}, {}, never, ["*"], true, never>;
|
|
5
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type HeadingLevel } from '../heading/heading.component';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export interface ColumnItem {
|
|
4
|
+
label: string;
|
|
5
|
+
href: string;
|
|
6
|
+
}
|
|
7
|
+
export interface Column {
|
|
8
|
+
heading: string;
|
|
9
|
+
appearanceLevel: HeadingLevel;
|
|
10
|
+
items: ColumnItem[];
|
|
11
|
+
}
|
|
12
|
+
export interface subFooter {
|
|
13
|
+
items: ColumnItem[];
|
|
14
|
+
}
|
|
15
|
+
export declare class FooterComponent {
|
|
16
|
+
background?: string;
|
|
17
|
+
preFooter?: boolean;
|
|
18
|
+
preFooterMessage?: string;
|
|
19
|
+
heading?: string;
|
|
20
|
+
appearanceLevel: HeadingLevel;
|
|
21
|
+
columns?: Column[];
|
|
22
|
+
backtotop?: boolean;
|
|
23
|
+
subFooter?: subFooter;
|
|
24
|
+
scrollBackToTop: (event: MouseEvent) => void;
|
|
25
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FooterComponent, never>;
|
|
26
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FooterComponent, "footer[rhc-footer]", never, { "background": { "alias": "background"; "required": false; }; "preFooter": { "alias": "preFooter"; "required": false; }; "preFooterMessage": { "alias": "preFooterMessage"; "required": false; }; "heading": { "alias": "heading"; "required": false; }; "appearanceLevel": { "alias": "appearanceLevel"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "backtotop": { "alias": "backtotop"; "required": false; }; "subFooter": { "alias": "subFooter"; "required": false; }; }, {}, never, never, true, never>;
|
|
27
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FormFieldComponent {
|
|
3
|
+
type?: 'checkbox' | 'radio' | 'text';
|
|
4
|
+
class?: string;
|
|
5
|
+
invalid?: boolean;
|
|
6
|
+
showInput?: boolean;
|
|
7
|
+
showLabel?: boolean;
|
|
8
|
+
showDescription?: boolean;
|
|
9
|
+
constructor();
|
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormFieldComponent, never>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldComponent, "rhc-form-field", never, { "type": { "alias": "type"; "required": false; }; "class": { "alias": "class"; "required": false; }; "invalid": { "alias": "invalid"; "required": false; }; "showInput": { "alias": "showInput"; "required": false; }; "showLabel": { "alias": "showLabel"; "required": false; }; "showDescription": { "alias": "showDescription"; "required": false; }; }, {}, never, ["[rhc-form-label]", "rhc-form-field-description", "rhc-form-field-error-message", "[rhc-text-input]", "*"], true, never>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FormFieldDescriptionComponent {
|
|
3
|
+
invalid?: boolean;
|
|
4
|
+
valid?: boolean;
|
|
5
|
+
warning?: boolean;
|
|
6
|
+
class?: string;
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormFieldDescriptionComponent, never>;
|
|
8
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldDescriptionComponent, "rhc-form-field-description", never, { "invalid": { "alias": "invalid"; "required": false; }; "valid": { "alias": "valid"; "required": false; }; "warning": { "alias": "warning"; "required": false; }; "class": { "alias": "class"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FormFieldErrorMessageComponent {
|
|
3
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormFieldErrorMessageComponent, never>;
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldErrorMessageComponent, "rhc-form-field-error-message", never, {}, {}, never, ["*"], true, never>;
|
|
5
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export type TextInputTypes = 'date' | 'datetime-local' | 'email' | 'month' | 'number' | 'password' | 'search' | 'tel' | 'text' | 'time' | 'url' | 'week';
|
|
4
|
+
export declare class FormFieldTextInputComponent implements ControlValueAccessor {
|
|
5
|
+
invalid?: boolean;
|
|
6
|
+
showDescription?: boolean;
|
|
7
|
+
label?: string;
|
|
8
|
+
errorMessage?: string;
|
|
9
|
+
description?: string;
|
|
10
|
+
status?: string;
|
|
11
|
+
required?: boolean;
|
|
12
|
+
readonly?: boolean;
|
|
13
|
+
dir?: 'auto' | 'ltr' | 'rtl';
|
|
14
|
+
name?: string;
|
|
15
|
+
autocomplete?: string;
|
|
16
|
+
placeholder?: string;
|
|
17
|
+
size?: number;
|
|
18
|
+
minLength?: number;
|
|
19
|
+
maxLength?: number;
|
|
20
|
+
min?: number;
|
|
21
|
+
max?: number;
|
|
22
|
+
step?: number;
|
|
23
|
+
type?: TextInputTypes;
|
|
24
|
+
inputId: string;
|
|
25
|
+
value: string;
|
|
26
|
+
disabled: boolean;
|
|
27
|
+
private onChange;
|
|
28
|
+
private onTouched;
|
|
29
|
+
onValueChange(event: Event): void;
|
|
30
|
+
markAsTouched(): void;
|
|
31
|
+
writeValue(value: string): void;
|
|
32
|
+
registerOnChange(fn: (value: string) => void): void;
|
|
33
|
+
registerOnTouched(fn: () => void): void;
|
|
34
|
+
setDisabledState(isDisabled: boolean): void;
|
|
35
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormFieldTextInputComponent, never>;
|
|
36
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormFieldTextInputComponent, "rhc-form-field-text-input", never, { "invalid": { "alias": "invalid"; "required": false; }; "showDescription": { "alias": "showDescription"; "required": false; }; "label": { "alias": "label"; "required": false; }; "errorMessage": { "alias": "errorMessage"; "required": false; }; "description": { "alias": "description"; "required": false; }; "status": { "alias": "status"; "required": false; }; "required": { "alias": "required"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "dir": { "alias": "dir"; "required": false; }; "name": { "alias": "name"; "required": false; }; "autocomplete": { "alias": "autocomplete"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "size": { "alias": "size"; "required": false; }; "minLength": { "alias": "minLength"; "required": false; }; "maxLength": { "alias": "maxLength"; "required": false; }; "min": { "alias": "min"; "required": false; }; "max": { "alias": "max"; "required": false; }; "step": { "alias": "step"; "required": false; }; "type": { "alias": "type"; "required": false; }; "inputId": { "alias": "inputId"; "required": true; }; }, {}, never, never, true, never>;
|
|
37
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class FormLabelComponent {
|
|
3
|
+
disabled?: boolean;
|
|
4
|
+
checked?: boolean;
|
|
5
|
+
type?: 'checkbox' | 'radio';
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FormLabelComponent, never>;
|
|
7
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FormLabelComponent, "label[rhc-form-label]", never, { "disabled": { "alias": "disabled"; "required": false; }; "checked": { "alias": "checked"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
8
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class LinkComponent {
|
|
3
3
|
href: string;
|
|
4
|
+
target?: '_self' | '_blank' | '_parent' | '_top' | '_unfencedTop';
|
|
4
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<LinkComponent, never>;
|
|
5
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<LinkComponent, "rhc-link", never, { "href": { "alias": "href"; "required": true; }; }, {}, never, ["*"], true, never>;
|
|
6
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LinkComponent, "rhc-link", never, { "href": { "alias": "href"; "required": true; }; "target": { "alias": "target"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
6
7
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class LinkListItemComponent {
|
|
3
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LinkListItemComponent, never>;
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LinkListItemComponent, "li[rhc-link-list-item]", never, {}, {}, never, ["*"], true, never>;
|
|
5
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class LinkListLinkComponent {
|
|
3
|
+
href: string;
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LinkListLinkComponent, never>;
|
|
5
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LinkListLinkComponent, "a[rhc-link-list-link]", never, { "href": { "alias": "href"; "required": true; }; }, {}, never, ["[icon]", "*"], true, never>;
|
|
6
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class LogoComponent {
|
|
3
|
+
organisation: string;
|
|
4
|
+
subtitle?: string | null;
|
|
5
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<LogoComponent, never>;
|
|
6
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<LogoComponent, "figure[rhc-logo]", never, { "organisation": { "alias": "organisation"; "required": true; }; "subtitle": { "alias": "subtitle"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class NavbarComponent {
|
|
3
|
+
showEndItems?: boolean;
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NavbarComponent, never>;
|
|
5
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NavbarComponent, "rhc-navbar", never, { "showEndItems": { "alias": "showEndItems"; "required": false; }; }, {}, never, ["[rhc-navbar-item][rhcHeadingItem]", "[rhc-navbar-item]:not([rhcEndItem])", "[rhc-navbar-item][rhcEndItem]", "*"], true, never>;
|
|
6
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
/**
|
|
3
|
+
* Deze directive wordt gebruikt als "marker". Hiermee kunnen <li>'s gemarkeerd worden als endItem.
|
|
4
|
+
* Een endItem wordt aan het einde van de navbar geplaatst.
|
|
5
|
+
*/
|
|
6
|
+
export declare class EndItemDirective {
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<EndItemDirective, never>;
|
|
8
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<EndItemDirective, "[rhcEndItem]", never, {}, {}, never, never, true, never>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class HeadingItemDirective {
|
|
3
|
+
className: string;
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<HeadingItemDirective, never>;
|
|
5
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<HeadingItemDirective, "[rhcHeadingItem]", never, {}, {}, never, never, true, never>;
|
|
6
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class NavbarItemComponent {
|
|
3
|
+
href: string;
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NavbarItemComponent, never>;
|
|
5
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NavbarItemComponent, "li[rhc-navbar-item]", never, { "href": { "alias": "href"; "required": true; }; }, {}, never, ["[icon]", "*"], true, never>;
|
|
6
|
+
}
|
package/dist/public-api.d.ts
CHANGED
|
@@ -3,4 +3,27 @@ export * from './paragraph/paragraph.component';
|
|
|
3
3
|
export * from './link/link.component';
|
|
4
4
|
export * from './button/button.component';
|
|
5
5
|
export * from './action-group/action-group.component';
|
|
6
|
+
export * from './image/image.component';
|
|
7
|
+
export * from './figure/figure.component';
|
|
8
|
+
export * from './figure-caption/figure-caption.component';
|
|
6
9
|
export * from './icon/public-api';
|
|
10
|
+
export * from './unordered-list/unordered-list.component';
|
|
11
|
+
export * from './unordered-list-item/unordered-list-item.component';
|
|
12
|
+
export * from './column-layout/column-layout.component';
|
|
13
|
+
export * from './logo/logo.component';
|
|
14
|
+
export * from './form-field/form-field.component';
|
|
15
|
+
export * from './form-field-description/form-field-description.component';
|
|
16
|
+
export * from './form-field-error-message/form-field-error-message.component';
|
|
17
|
+
export * from './form-field-text-input/form-field-text-input.component';
|
|
18
|
+
export * from './form-label/form-label.component';
|
|
19
|
+
export * from './text-input/text-input.component';
|
|
20
|
+
export * from './link-list-link/link-list-link.component';
|
|
21
|
+
export * from './link-list/link-list.component';
|
|
22
|
+
export * from './link-list-item/link-list-item.component';
|
|
23
|
+
export * from './navbar/navbar.component';
|
|
24
|
+
export * from './navbar-item/navbar-item.component';
|
|
25
|
+
export * from './navbar-item/heading-item.directive';
|
|
26
|
+
export * from './navbar-item/end-item.directive';
|
|
27
|
+
export * from './footer/footer.component';
|
|
28
|
+
export * from './data-summary/data-summary.component';
|
|
29
|
+
export * from './data-summary-item/data-summary-item.component';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class TextInputComponent {
|
|
3
|
+
disabled?: boolean | undefined;
|
|
4
|
+
invalid?: boolean | undefined;
|
|
5
|
+
required?: boolean | undefined;
|
|
6
|
+
readonly?: boolean | undefined;
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TextInputComponent, never>;
|
|
8
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TextInputComponent, "input[rhc-text-input]", never, { "disabled": { "alias": "disabled"; "required": false; }; "invalid": { "alias": "invalid"; "required": false; }; "required": { "alias": "required"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class UnorderedListComponent {
|
|
3
|
+
nested?: boolean;
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UnorderedListComponent, never>;
|
|
5
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UnorderedListComponent, "ul[rhc-unordered-list]", never, { "nested": { "alias": "nested"; "required": false; }; }, {}, never, ["*"], true, never>;
|
|
6
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class UnorderedListItemComponent {
|
|
3
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UnorderedListItemComponent, never>;
|
|
4
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UnorderedListItemComponent, "li[rhc-unordered-list-item]", never, {}, {}, never, ["*"], true, never>;
|
|
5
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rijkshuisstijl-community/components-angular",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0",
|
|
4
4
|
"author": "Community for NL Design System",
|
|
5
5
|
"description": "Angular component library for the Rijkshuisstijl Community repository, based on the NL Design System architecture",
|
|
6
6
|
"license": "EUPL-1.2",
|
|
@@ -19,34 +19,42 @@
|
|
|
19
19
|
"directory": "packages/components-angular"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"tslib": "2.3.0"
|
|
22
|
+
"tslib": "2.3.0",
|
|
23
|
+
"angular-tabler-icons": "3.26.0"
|
|
24
|
+
},
|
|
25
|
+
"peerDependencies": {
|
|
26
|
+
"@angular-devkit/build-angular": "~19.2.0",
|
|
27
|
+
"@angular/cli": "~19.2.0",
|
|
28
|
+
"@angular/common": "~19.2.0",
|
|
29
|
+
"@angular/compiler": "~19.2.0",
|
|
30
|
+
"@angular/compiler-cli": "~19.2.0",
|
|
31
|
+
"@angular/core": "~19.2.0",
|
|
32
|
+
"@angular/forms": "~19.2.0",
|
|
33
|
+
"@angular/platform-browser": "~19.2.0",
|
|
34
|
+
"@angular/platform-browser-dynamic": "~19.2.0",
|
|
35
|
+
"@angular/router": "~19.2.0"
|
|
23
36
|
},
|
|
24
37
|
"devDependencies": {
|
|
25
|
-
"@angular-devkit/build-angular": "19.2.0",
|
|
26
|
-
"@angular/cli": "19.2.3",
|
|
27
|
-
"@angular/common": "19.2.0",
|
|
28
|
-
"@angular/compiler": "19.2.0",
|
|
29
|
-
"@angular/compiler-cli": "19.2.0",
|
|
30
|
-
"@angular/core": "19.2.0",
|
|
31
|
-
"@angular/forms": "19.2.0",
|
|
32
|
-
"@angular/platform-browser": "19.2.0",
|
|
33
|
-
"@angular/platform-browser-dynamic": "19.2.0",
|
|
34
|
-
"@angular/router": "19.2.0",
|
|
35
38
|
"@nl-design-system-candidate/heading-css": "1.0.0",
|
|
36
39
|
"@nl-design-system-candidate/link-css": "1.0.1",
|
|
37
40
|
"@nl-design-system-candidate/paragraph-css": "2.0.1",
|
|
38
41
|
"@testing-library/jest-dom": "5.17.0",
|
|
39
42
|
"@types/jest": "29.5.14",
|
|
40
43
|
"@types/testing-library__jest-dom": "5.14.9",
|
|
41
|
-
"angular-tabler-icons": "3.26.0",
|
|
42
44
|
"jest": "29.7.0",
|
|
43
45
|
"jest-preset-angular": "14.5.4",
|
|
44
|
-
"ng-packagr": "19.2.
|
|
46
|
+
"ng-packagr": "19.2.2",
|
|
45
47
|
"rxjs": "7.8.0",
|
|
46
48
|
"typescript": "5.7.2",
|
|
47
49
|
"zone.js": "0.15.0",
|
|
48
|
-
"@rijkshuisstijl-community/components-css": "
|
|
50
|
+
"@rijkshuisstijl-community/components-css": "2.0.0"
|
|
49
51
|
},
|
|
52
|
+
"files": [
|
|
53
|
+
"dist/"
|
|
54
|
+
],
|
|
55
|
+
"main": "./dist/fesm2022/rijkshuisstijl-community-components-angular.mjs",
|
|
56
|
+
"module": "./dist/fesm2022/rijkshuisstijl-community-components-angular.mjs",
|
|
57
|
+
"types": "./dist/index.d.ts",
|
|
50
58
|
"scripts": {
|
|
51
59
|
"ng": "ng",
|
|
52
60
|
"build": "ng build",
|
package/CHANGELOG.md
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# @rijkshuisstijl-community/components-angular
|
|
2
|
-
|
|
3
|
-
## 1.0.0
|
|
4
|
-
|
|
5
|
-
### Major Changes
|
|
6
|
-
|
|
7
|
-
- 6deb00e: Initial release
|
|
8
|
-
|
|
9
|
-
### Minor Changes
|
|
10
|
-
|
|
11
|
-
- 5d9ff09: Added paragraph component
|
|
12
|
-
- d6ef9eb: Added Link component
|
|
13
|
-
- ffb7e8e: Added Angular Button component and installed the icons package
|
|
14
|
-
- a961845: Added action-group Angular component
|
|
15
|
-
- d369cf5: Added icon components in Angular
|
package/angular.json
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
|
|
3
|
-
"version": 1,
|
|
4
|
-
"newProjectRoot": "projects",
|
|
5
|
-
"projects": {
|
|
6
|
-
"components-angular": {
|
|
7
|
-
"projectType": "library",
|
|
8
|
-
"root": "",
|
|
9
|
-
"sourceRoot": "/src",
|
|
10
|
-
"prefix": "lib",
|
|
11
|
-
"architect": {
|
|
12
|
-
"build": {
|
|
13
|
-
"builder": "@angular-devkit/build-angular:ng-packagr",
|
|
14
|
-
"options": {
|
|
15
|
-
"project": "./ng-package.json"
|
|
16
|
-
},
|
|
17
|
-
"configurations": {
|
|
18
|
-
"production": {
|
|
19
|
-
"tsConfig": "./tsconfig.lib.prod.json"
|
|
20
|
-
},
|
|
21
|
-
"development": {
|
|
22
|
-
"tsConfig": "./tsconfig.lib.json"
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
"defaultConfiguration": "production"
|
|
26
|
-
},
|
|
27
|
-
"test": {
|
|
28
|
-
"builder": "@angular-devkit/build-angular:karma",
|
|
29
|
-
"options": {
|
|
30
|
-
"tsConfig": "./tsconfig.spec.json",
|
|
31
|
-
"polyfills": ["zone.js", "zone.js/testing"]
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
}
|
package/jest.config.js
DELETED
package/ng-package.json
DELETED
package/setup-jest.ts
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
import { By } from '@angular/platform-browser';
|
|
3
|
-
import { ActionGroupComponent } from './action-group.component';
|
|
4
|
-
|
|
5
|
-
describe('ActionGroupComponent', () => {
|
|
6
|
-
let component: ActionGroupComponent;
|
|
7
|
-
let fixture: ComponentFixture<ActionGroupComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
imports: [ActionGroupComponent],
|
|
12
|
-
}).compileComponents();
|
|
13
|
-
|
|
14
|
-
fixture = TestBed.createComponent(ActionGroupComponent);
|
|
15
|
-
component = fixture.componentInstance;
|
|
16
|
-
fixture.detectChanges();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it('should create', () => {
|
|
20
|
-
expect(component).toBeTruthy();
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('should have "utrecht-button-group--row" class by default', () => {
|
|
24
|
-
const divEl = fixture.debugElement.query(By.css('div')).nativeElement;
|
|
25
|
-
expect(divEl.classList).toContain('utrecht-button-group--row');
|
|
26
|
-
expect(divEl.classList).not.toContain('utrecht-button-group--column');
|
|
27
|
-
});
|
|
28
|
-
|
|
29
|
-
it('should apply "column" direction class when input is column', () => {
|
|
30
|
-
component.direction = 'column';
|
|
31
|
-
fixture.detectChanges();
|
|
32
|
-
|
|
33
|
-
const divEl = fixture.debugElement.query(By.css('div')).nativeElement;
|
|
34
|
-
expect(divEl.classList).toContain('utrecht-button-group--column');
|
|
35
|
-
expect(divEl.classList).not.toContain('utrecht-button-group--row');
|
|
36
|
-
});
|
|
37
|
-
|
|
38
|
-
it('should apply "row" direction class when input is row', () => {
|
|
39
|
-
component.direction = 'row';
|
|
40
|
-
fixture.detectChanges();
|
|
41
|
-
|
|
42
|
-
const divEl = fixture.debugElement.query(By.css('div')).nativeElement;
|
|
43
|
-
expect(divEl.classList).toContain('utrecht-button-group--row');
|
|
44
|
-
expect(divEl.classList).not.toContain('utrecht-button-group--column');
|
|
45
|
-
});
|
|
46
|
-
});
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
import { ButtonComponent } from './button.component';
|
|
3
|
-
|
|
4
|
-
describe('ButtonComponent', () => {
|
|
5
|
-
let component: ButtonComponent;
|
|
6
|
-
let fixture: ComponentFixture<ButtonComponent>;
|
|
7
|
-
|
|
8
|
-
beforeEach(async () => {
|
|
9
|
-
await TestBed.configureTestingModule({
|
|
10
|
-
imports: [ButtonComponent],
|
|
11
|
-
}).compileComponents();
|
|
12
|
-
|
|
13
|
-
fixture = TestBed.createComponent(ButtonComponent);
|
|
14
|
-
component = fixture.componentInstance;
|
|
15
|
-
fixture.detectChanges();
|
|
16
|
-
});
|
|
17
|
-
|
|
18
|
-
it('should create', () => {
|
|
19
|
-
expect(component).toBeTruthy();
|
|
20
|
-
});
|
|
21
|
-
|
|
22
|
-
it('should render a native <button>', () => {
|
|
23
|
-
const button = fixture.nativeElement.querySelector('button');
|
|
24
|
-
expect(button).toBeTruthy();
|
|
25
|
-
expect(button.tagName.toLowerCase()).toBe('button');
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
it('should apply the primary-action class', () => {
|
|
29
|
-
component.appearance = 'primary-action';
|
|
30
|
-
fixture.detectChanges();
|
|
31
|
-
const button = fixture.nativeElement.querySelector('button');
|
|
32
|
-
expect(button.classList).toContain('utrecht-button--primary-action');
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
it('should be disabled when the disabled input is true', () => {
|
|
36
|
-
component.disabled = true;
|
|
37
|
-
fixture.detectChanges();
|
|
38
|
-
const button = fixture.nativeElement.querySelector('button');
|
|
39
|
-
expect(button.disabled).toBe(true);
|
|
40
|
-
});
|
|
41
|
-
});
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { CommonModule } from '@angular/common';
|
|
2
|
-
import { Component, Input } from '@angular/core';
|
|
3
|
-
|
|
4
|
-
@Component({
|
|
5
|
-
selector: 'rhc-button',
|
|
6
|
-
imports: [CommonModule],
|
|
7
|
-
templateUrl: './button.component.html',
|
|
8
|
-
})
|
|
9
|
-
export class ButtonComponent {
|
|
10
|
-
@Input() appearance?: '' | 'primary-action' | 'secondary-action' | 'subtle' = '';
|
|
11
|
-
@Input() disabled?: boolean = false;
|
|
12
|
-
|
|
13
|
-
computedClasses = () => `utrecht-button utrecht-button--${this.appearance}`;
|
|
14
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
@import "@nl-design-system-candidate/heading-css/heading.css";
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
@switch (level) {
|
|
2
|
-
@case (1) {
|
|
3
|
-
<h1 class="{{ computedClasses() }}">
|
|
4
|
-
<ng-container [ngTemplateOutlet]="content"></ng-container>
|
|
5
|
-
</h1>
|
|
6
|
-
}
|
|
7
|
-
@case (2) {
|
|
8
|
-
<h2 class="{{ computedClasses() }}">
|
|
9
|
-
<ng-container [ngTemplateOutlet]="content"></ng-container>
|
|
10
|
-
</h2>
|
|
11
|
-
}
|
|
12
|
-
@case (3) {
|
|
13
|
-
<h3 class="{{ computedClasses() }}">
|
|
14
|
-
<ng-container [ngTemplateOutlet]="content"></ng-container>
|
|
15
|
-
</h3>
|
|
16
|
-
}
|
|
17
|
-
@case (4) {
|
|
18
|
-
<h4 class="{{ computedClasses() }}">
|
|
19
|
-
<ng-container [ngTemplateOutlet]="content"></ng-container>
|
|
20
|
-
</h4>
|
|
21
|
-
}
|
|
22
|
-
@case (5) {
|
|
23
|
-
<h5 class="{{ computedClasses() }}">
|
|
24
|
-
<ng-container [ngTemplateOutlet]="content"></ng-container>
|
|
25
|
-
</h5>
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
<ng-template #content>
|
|
30
|
-
<ng-content></ng-content>
|
|
31
|
-
</ng-template>
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
import { By } from '@angular/platform-browser';
|
|
3
|
-
import { HeadingComponent, HeadingLevel } from './heading.component';
|
|
4
|
-
|
|
5
|
-
describe('HeadingComponent', () => {
|
|
6
|
-
let component: HeadingComponent;
|
|
7
|
-
let fixture: ComponentFixture<HeadingComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
imports: [HeadingComponent],
|
|
12
|
-
}).compileComponents();
|
|
13
|
-
|
|
14
|
-
fixture = TestBed.createComponent(HeadingComponent);
|
|
15
|
-
component = fixture.componentInstance;
|
|
16
|
-
fixture.detectChanges();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it('should create', () => {
|
|
20
|
-
expect(component).toBeTruthy();
|
|
21
|
-
});
|
|
22
|
-
|
|
23
|
-
it('should use the correct heading level', () => {
|
|
24
|
-
for (let level of [1, 2, 3, 4, 5] as HeadingLevel[]) {
|
|
25
|
-
component.level = level;
|
|
26
|
-
fixture.detectChanges();
|
|
27
|
-
const element = fixture.nativeElement.querySelector(`h${level}`);
|
|
28
|
-
expect(element).toBeTruthy();
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
|
|
32
|
-
it('should apply the css class according to appearance level', () => {
|
|
33
|
-
component.level = 5;
|
|
34
|
-
component.appearanceLevel = 2;
|
|
35
|
-
fixture.detectChanges();
|
|
36
|
-
const element = fixture.debugElement.query(By.css('.nl-heading--level-2'));
|
|
37
|
-
expect(element).toBeTruthy();
|
|
38
|
-
});
|
|
39
|
-
|
|
40
|
-
it('should contain the nl-heading class', () => {
|
|
41
|
-
component.level = 3;
|
|
42
|
-
fixture.detectChanges();
|
|
43
|
-
const element = fixture.debugElement.query(By.css('.nl-heading'));
|
|
44
|
-
expect(element).toBeTruthy();
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
it('should render rich text content', () => {
|
|
48
|
-
component.level = 1;
|
|
49
|
-
fixture.detectChanges();
|
|
50
|
-
const headingDebugElement = fixture.debugElement.query(By.css('.nl-heading--level-1'));
|
|
51
|
-
headingDebugElement.nativeElement.innerHTML = '<strong>Breaking</strong> news';
|
|
52
|
-
expect(fixture.nativeElement).toContainHTML('strong');
|
|
53
|
-
});
|
|
54
|
-
});
|