oasys-lib 0.0.4 → 0.0.48
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/bundles/oasys-lib.umd.js +336 -0
- package/bundles/oasys-lib.umd.js.map +1 -0
- package/esm2015/lib/components/button/button.component.js +91 -0
- package/esm2015/lib/components/button/button.js +2 -0
- package/esm2015/lib/components/icon/icon.component.js +59 -0
- package/{esm2020/lib/components/icon/icon.mjs → esm2015/lib/components/icon/icon.js} +0 -0
- package/esm2015/lib/components/layout/box/box.component.js +32 -0
- package/esm2015/lib/components/layout/inline/inline.component.js +20 -0
- package/{esm2020/lib/components/text/text.mjs → esm2015/lib/components/text/text.js} +0 -0
- package/esm2015/lib/oasys-lib.module.js +52 -0
- package/{esm2020/lib/services/token.service.mjs → esm2015/lib/services/token.service.js} +4 -4
- package/{esm2020/lib/services/window.service.mjs → esm2015/lib/services/window.service.js} +4 -4
- package/{esm2020/oasys-lib.mjs → esm2015/oasys-lib.js} +0 -0
- package/{esm2020/public-api.mjs → esm2015/public-api.js} +2 -1
- package/fesm2015/oasys-lib.js +292 -0
- package/fesm2015/oasys-lib.js.map +1 -0
- package/lib/components/button/button.component.d.ts +7 -5
- package/lib/components/button/button.component.d.ts.map +1 -1
- package/lib/components/button/button.d.ts +1 -2
- package/lib/components/button/button.d.ts.map +1 -1
- package/lib/components/icon/icon.component.d.ts.map +1 -1
- package/lib/oasys-lib.module.d.ts +1 -1
- package/lib/oasys-lib.module.d.ts.map +1 -1
- package/package.json +8 -21
- package/public-api.d.ts +1 -0
- package/public-api.d.ts.map +1 -1
- package/esm2020/lib/components/button/button.component.mjs +0 -77
- package/esm2020/lib/components/button/button.mjs +0 -2
- package/esm2020/lib/components/icon/icon.component.mjs +0 -53
- package/esm2020/lib/components/layout/box/box.component.mjs +0 -25
- package/esm2020/lib/components/layout/inline/inline.component.mjs +0 -14
- package/esm2020/lib/oasys-lib.module.mjs +0 -49
- package/fesm2015/oasys-lib.mjs +0 -257
- package/fesm2015/oasys-lib.mjs.map +0 -1
- package/fesm2020/oasys-lib.mjs +0 -257
- package/fesm2020/oasys-lib.mjs.map +0 -1
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';
|
|
2
|
+
import { Input } from '@angular/core';
|
|
3
|
+
import { Component } from '@angular/core';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export class LayoutBoxComponent {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.padding = 'default';
|
|
8
|
+
}
|
|
9
|
+
ngOnInit() {
|
|
10
|
+
this.boxLayoutClasses = [
|
|
11
|
+
`ui-layout-box-${this.padding}`
|
|
12
|
+
].join(' ');
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
LayoutBoxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutBoxComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
16
|
+
LayoutBoxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: LayoutBoxComponent, selector: "ui-box", inputs: { padding: "padding" }, host: { properties: { "class": "boxLayoutClasses" } }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, styles: [".ui-layout-box-xsmall{padding:var(--size-unit-xsmall)}.ui-layout-box-small{padding:var(--size-unit-small)}.ui-layout-box-default{padding:var(--size-unit-default)}.ui-layout-box-large{padding:var(--size-unit-large)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
17
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutBoxComponent, decorators: [{
|
|
18
|
+
type: Component,
|
|
19
|
+
args: [{
|
|
20
|
+
selector: 'ui-box',
|
|
21
|
+
template: '<ng-content></ng-content>',
|
|
22
|
+
host: {
|
|
23
|
+
'[class]': 'boxLayoutClasses'
|
|
24
|
+
},
|
|
25
|
+
styleUrls: ['./box.component.scss'],
|
|
26
|
+
encapsulation: ViewEncapsulation.None,
|
|
27
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
|
28
|
+
}]
|
|
29
|
+
}], ctorParameters: function () { return []; }, propDecorators: { padding: [{
|
|
30
|
+
type: Input
|
|
31
|
+
}] } });
|
|
32
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYm94LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL29hc3lzLWxpYi9zcmMvbGliL2NvbXBvbmVudHMvbGF5b3V0L2JveC9ib3guY29tcG9uZW50LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSx1QkFBdUIsRUFBVSxpQkFBaUIsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUNuRixPQUFPLEVBQUUsS0FBSyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ3RDLE9BQU8sRUFBRSxTQUFTLEVBQUMsTUFBTSxlQUFlLENBQUM7O0FBWXpDLE1BQU0sT0FBTyxrQkFBa0I7SUFLN0I7UUFGUyxZQUFPLEdBQWlCLFNBQVMsQ0FBQztJQUUzQixDQUFDO0lBRWpCLFFBQVE7UUFDTixJQUFJLENBQUMsZ0JBQWdCLEdBQUc7WUFDdEIsaUJBQWlCLElBQUksQ0FBQyxPQUFPLEVBQUU7U0FDaEMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLENBQUM7SUFDZCxDQUFDOztnSEFYVSxrQkFBa0I7b0dBQWxCLGtCQUFrQixxSUFSbkIsMkJBQTJCOzRGQVExQixrQkFBa0I7a0JBVjlCLFNBQVM7bUJBQUM7b0JBQ1QsUUFBUSxFQUFDLFFBQVE7b0JBQ2pCLFFBQVEsR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fVxuXG4gIG5nT25Jbml0KCk6IHZvaWQge1xuICAgIHRoaXMuYm94TGF5b3V0Q2xhc3NlcyA9IFtcbiAgICAgIGB1aS1sYXlvdXQtYm94LSR7dGhpcy5wYWRkaW5nfWBcbiAgICBdLmpvaW4oJyAnKTtcbiAgfVxuXG59XG5cbmV4cG9ydCB0eXBlIEJveFBhZGRpbmdzID0gJ3hzbWFsbCd8J3NtYWxsJ3wnbWVkaXVtJ3wnbGFyZ2UnfCdkZWZhdWx0JzsiXX0=
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export class LayoutInlineComponent {
|
|
4
|
+
constructor() { }
|
|
5
|
+
ngOnInit() {
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
LayoutInlineComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutInlineComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
9
|
+
LayoutInlineComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: LayoutInlineComponent, selector: "ui-inline", ngImport: i0, template: "<div class=\"ui-layout-inline\"><ng-content></ng-content></div>", styles: [".ui-layout-inline{display:inline-flex;position:relative}.ui-layout-inline>*{margin-left:var(--layout-inline-spacing-default);margin-right:var(--layout-inline-spacing-default)}.ui-layout-inline:first-child{margin-left:0}.ui-layout-inline:last-child{margin-right:0}.ui-layout-inline:only-child{margin-left:0;margin-right:0}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
10
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutInlineComponent, decorators: [{
|
|
11
|
+
type: Component,
|
|
12
|
+
args: [{
|
|
13
|
+
selector: 'ui-inline',
|
|
14
|
+
templateUrl: './inline.component.html',
|
|
15
|
+
styleUrls: ['./inline.component.css'],
|
|
16
|
+
encapsulation: ViewEncapsulation.None,
|
|
17
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
|
18
|
+
}]
|
|
19
|
+
}], ctorParameters: function () { return []; } });
|
|
20
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5saW5lLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL29hc3lzLWxpYi9zcmMvbGliL2NvbXBvbmVudHMvbGF5b3V0L2lubGluZS9pbmxpbmUuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvb2FzeXMtbGliL3NyYy9saWIvY29tcG9uZW50cy9sYXlvdXQvaW5saW5lL2lubGluZS5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFVLGlCQUFpQixFQUFFLE1BQU0sZUFBZSxDQUFDOztBQVM5RixNQUFNLE9BQU8scUJBQXFCO0lBRWhDLGdCQUFnQixDQUFDO0lBRWpCLFFBQVE7SUFDUixDQUFDOzttSEFMVSxxQkFBcUI7dUdBQXJCLHFCQUFxQixpRENUbEMsaUVBQTZEOzRGRFNoRCxxQkFBcUI7a0JBUGpDLFNBQVM7bUJBQUM7b0JBQ1QsUUFBUSxFQUFDLFdBQVc7b0JBQ3BCLFdBQVcsRUFBRSx5QkFBeUI7b0JBQ3RDLFNBQVMsRUFBRSxDQUFDLHdCQUF3QixDQUFDO29CQUNyQyxhQUFhLEVBQUUsaUJBQWlCLENBQUMsSUFBSTtvQkFDckMsZUFBZSxFQUFFLHVCQUF1QixDQUFDLE1BQU07aUJBQ2hEIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgQ2hhbmdlRGV0ZWN0aW9uU3RyYXRlZ3ksIENvbXBvbmVudCwgT25Jbml0LCBWaWV3RW5jYXBzdWxhdGlvbiB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5AQ29tcG9uZW50KHtcbiAgc2VsZWN0b3I6J3VpLWlubGluZScsXG4gIHRlbXBsYXRlVXJsOiAnLi9pbmxpbmUuY29tcG9uZW50Lmh0bWwnLFxuICBzdHlsZVVybHM6IFsnLi9pbmxpbmUuY29tcG9uZW50LmNzcyddLFxuICBlbmNhcHN1bGF0aW9uOiBWaWV3RW5jYXBzdWxhdGlvbi5Ob25lLFxuICBjaGFuZ2VEZXRlY3Rpb246IENoYW5nZURldGVjdGlvblN0cmF0ZWd5Lk9uUHVzaFxufSlcbmV4cG9ydCBjbGFzcyBMYXlvdXRJbmxpbmVDb21wb25lbnQgaW1wbGVtZW50cyBPbkluaXQge1xuXG4gIGNvbnN0cnVjdG9yKCkgeyB9XG5cbiAgbmdPbkluaXQoKTogdm9pZCB7XG4gIH1cblxufVxuIiwiPGRpdiBjbGFzcz1cInVpLWxheW91dC1pbmxpbmVcIj48bmctY29udGVudD48L25nLWNvbnRlbnQ+PC9kaXY+Il19
|
|
File without changes
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { APP_BASE_HREF, CommonModule } from '@angular/common';
|
|
2
|
+
import { NgModule } from '@angular/core';
|
|
3
|
+
import { RouterModule } from '@angular/router';
|
|
4
|
+
import { OasysButtonComponent } from './components/button/button.component';
|
|
5
|
+
import { LayoutInlineComponent } from './components/layout/inline/inline.component';
|
|
6
|
+
import { IconComponent } from './components/icon/icon.component';
|
|
7
|
+
import { LayoutBoxComponent } from './components/layout/box/box.component';
|
|
8
|
+
import { WindowService } from './services/window.service';
|
|
9
|
+
import { TokenService } from './services/token.service';
|
|
10
|
+
import * as i0 from "@angular/core";
|
|
11
|
+
import * as i1 from "@angular/router";
|
|
12
|
+
export class OasysLibModule {
|
|
13
|
+
}
|
|
14
|
+
OasysLibModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
15
|
+
OasysLibModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, declarations: [OasysButtonComponent,
|
|
16
|
+
LayoutInlineComponent,
|
|
17
|
+
IconComponent,
|
|
18
|
+
LayoutBoxComponent], imports: [CommonModule, i1.RouterModule], exports: [OasysButtonComponent,
|
|
19
|
+
LayoutBoxComponent] });
|
|
20
|
+
OasysLibModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, providers: [
|
|
21
|
+
WindowService,
|
|
22
|
+
TokenService,
|
|
23
|
+
{ provide: APP_BASE_HREF, useValue: '/' }
|
|
24
|
+
], imports: [[
|
|
25
|
+
CommonModule,
|
|
26
|
+
RouterModule.forChild([])
|
|
27
|
+
]] });
|
|
28
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, decorators: [{
|
|
29
|
+
type: NgModule,
|
|
30
|
+
args: [{
|
|
31
|
+
declarations: [
|
|
32
|
+
OasysButtonComponent,
|
|
33
|
+
LayoutInlineComponent,
|
|
34
|
+
IconComponent,
|
|
35
|
+
LayoutBoxComponent
|
|
36
|
+
],
|
|
37
|
+
imports: [
|
|
38
|
+
CommonModule,
|
|
39
|
+
RouterModule.forChild([])
|
|
40
|
+
],
|
|
41
|
+
exports: [
|
|
42
|
+
OasysButtonComponent,
|
|
43
|
+
LayoutBoxComponent
|
|
44
|
+
],
|
|
45
|
+
providers: [
|
|
46
|
+
WindowService,
|
|
47
|
+
TokenService,
|
|
48
|
+
{ provide: APP_BASE_HREF, useValue: '/' }
|
|
49
|
+
]
|
|
50
|
+
}]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L2NvbXBvbmVudHMvaWNvbi9pY29uLmNvbXBvbmVudCc7XG5pbXBvcnQgeyBMYXlvdXRCb3hDb21wb25lbnQgfSBmcm9tICcuL2NvbXBvbmVudHMvbGF5b3V0L2JveC9ib3guY29tcG9uZW50JztcbmltcG9ydCB7IFdpbmRvd1NlcnZpY2UgfSBmcm9tICcuL3NlcnZpY2VzL3dpbmRvdy5zZXJ2aWNlJztcbmltcG9ydCB7IFRva2VuU2VydmljZSB9IGZyb20gJy4vc2VydmljZXMvdG9rZW4uc2VydmljZSc7XG5cblxuXG5ATmdNb2R1bGUoe1xuICBkZWNsYXJhdGlvbnM6IFtcbiAgICBPYXN5c0J1dHRvbkNvbXBvbmVudCxcbiAgICBMYXlvdXRJbmxpbmVDb21wb25lbnQsXG4gICAgSWNvbkNvbXBvbmVudCxcbiAgICBMYXlvdXRCb3hDb21wb25lbnRcbiAgXSxcbiAgaW1wb3J0czogW1xuICAgIENvbW1vbk1vZHVsZSxcbiAgICBSb3V0ZXJNb2R1bGUuZm9yQ2hpbGQoW10pXG4gIF0sXG4gIGV4cG9ydHM6IFtcbiAgICBPYXN5c0J1dHRvbkNvbXBvbmVudCxcbiAgICBMYXlvdXRCb3hDb21wb25lbnRcbiAgXSxcbiAgcHJvdmlkZXJzOiBbXG4gICAgV2luZG93U2VydmljZSxcbiAgICBUb2tlblNlcnZpY2UsXG4gICAge3Byb3ZpZGU6IEFQUF9CQVNFX0hSRUYsIHVzZVZhbHVlOiAnLyd9XG4gIF1cbn0pXG5leHBvcnQgY2xhc3MgT2FzeXNMaWJNb2R1bGUgeyB9XG4iXX0=
|
|
@@ -26,12 +26,12 @@ export class TokenService {
|
|
|
26
26
|
.trim() || '';
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
TokenService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
30
|
-
TokenService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
29
|
+
TokenService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, deps: [{ token: i1.WindowService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
30
|
+
TokenService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, providedIn: 'root' });
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, decorators: [{
|
|
32
32
|
type: Injectable,
|
|
33
33
|
args: [{
|
|
34
34
|
providedIn: 'root'
|
|
35
35
|
}]
|
|
36
36
|
}], ctorParameters: function () { return [{ type: i1.WindowService }]; } });
|
|
37
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
37
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidG9rZW4uc2VydmljZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL29hc3lzLWxpYi9zcmMvbGliL3NlcnZpY2VzL3Rva2VuLnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFVBQVUsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUMzQyxPQUFPLEVBQUUsYUFBYSxFQUFFLE1BQU0sa0JBQWtCLENBQUM7OztBQUtqRCxNQUFNLE9BQU8sWUFBWTtJQUV2QixZQUFvQixTQUF3QjtRQUF4QixjQUFTLEdBQVQsU0FBUyxDQUFlO0lBQUUsQ0FBQztJQUUvQzs7Ozs7Ozs7O01BU0U7SUFDRixZQUFZLENBQUMsU0FBaUIsRUFBRSxPQUFnQjtRQUM5QyxPQUFPLElBQUksQ0FBQyxhQUFhLENBQUMsU0FBUyxFQUFFLE9BQU8sQ0FBQ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2lmaWMgY3VzdG9tIHByb3BlcnRpZXMgcHJvZ3JhbWF0aWNhbGx5XG5cbiAgSW1wb3J0YW50OiBFbnN1cmUgdGhhdCB0aGUgY29tcG9uZW50IHJlcXVpcmluZyB0aGUgYnJhbmQgbmFtZSBoYXMgbG9jYWxseSBzY29wZWQgdGhlIGN1c3RvbSBwcm9wZXJ0eTpcbiAgfCAgdWktaWNvbiB7XG4gIHwgICAgLS1pY29uLWNvbXBvbmVudC1icmFuZDogdmFyKC0tdXRpbGl0eS1icmFuZC1uYW1lKTtcbiAgfCAgfVxuICAqL1xuICBnZXRCcmFuZE5hbWUodG9rZW5OYW1lOiBzdHJpbmcsIGVsZW1lbnQ6IEVsZW1lbnQpOiBzdHJpbmcge1xuICAgIHJldHVybiB0aGlzLmdldFRva2VuVmFsdWUodG9rZW5OYW1lLCBlbGVtZW50KTtcbiAgfVxuXG4gIGdldFRva2VuVmFsdWUodG9rZW5OYW1lOiBzdHJpbmcsIGVsZW1lbnQ/OiBFbGVtZW50KTogc3RyaW5nIHtcbiAgICBjb25zdCByb290RWxlbWVudCA9IGVsZW1lbnQgfHwgdGhpcy53aW5kb3dSZWYubmF0aXZlV2luZG93LmRvY3VtZW50LmRvY3VtZW50RWxlbWVudDtcbiAgICByZXR1cm4gdGhpcy53aW5kb3dSZWYubmF0aXZlV2luZG93LmdldENvbXB1dGVkU3R5bGUocm9vdEVsZW1lbnQpXG4gICAgICAuZ2V0UHJvcGVydHlWYWx1ZSh0b2tlbk5hbWUpXG4gICAgICAudHJpbSgpIHx8ICcnO1xuICB9XG5cbn0iXX0=
|
|
@@ -8,12 +8,12 @@ export class WindowService {
|
|
|
8
8
|
return _window();
|
|
9
9
|
}
|
|
10
10
|
}
|
|
11
|
-
WindowService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
12
|
-
WindowService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
13
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
11
|
+
WindowService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
12
|
+
WindowService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, providedIn: 'root' });
|
|
13
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, decorators: [{
|
|
14
14
|
type: Injectable,
|
|
15
15
|
args: [{
|
|
16
16
|
providedIn: 'root'
|
|
17
17
|
}]
|
|
18
18
|
}] });
|
|
19
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
19
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoid2luZG93LnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9vYXN5cy1saWIvc3JjL2xpYi9zZXJ2aWNlcy93aW5kb3cuc2VydmljZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sZUFBZSxDQUFDOztBQUUzQyxTQUFTLE9BQU87SUFDZCxPQUFPLE1BQU0sQ0FBQztBQUNoQixDQUFDO0FBS0QsTUFBTSxPQUFPLGFBQWE7SUFFeEIsSUFBSSxZQUFZO1FBQ2QsT0FBTyxPQUFPLEVBQUUsQ0FBQztJQUNuQixDQUFDOzsyR0FKVSxhQUFhOytHQUFiLGFBQWEsY0FGWixNQUFNOzRGQUVQLGFBQWE7a0JBSHpCLFVBQVU7bUJBQUM7b0JBQ1YsVUFBVSxFQUFFLE1BQU07aUJBQ25CIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgSW5qZWN0YWJsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5mdW5jdGlvbiBfd2luZG93KCk6IGFueSB7XG4gIHJldHVybiB3aW5kb3c7XG59XG5cbkBJbmplY3RhYmxlKHtcbiAgcHJvdmlkZWRJbjogJ3Jvb3QnXG59KVxuZXhwb3J0IGNsYXNzIFdpbmRvd1NlcnZpY2Uge1xuICBcbiAgZ2V0IG5hdGl2ZVdpbmRvdygpOiBhbnkge1xuICAgIHJldHVybiBfd2luZG93KCk7XG4gIH1cbiAgXG59Il19
|
|
File without changes
|
|
@@ -5,4 +5,5 @@ export * from './lib/oasys-lib.module';
|
|
|
5
5
|
export * from './lib/components/button/button.component';
|
|
6
6
|
export * from './lib/components/icon/icon.component';
|
|
7
7
|
export * from './lib/components/layout/box/box.component';
|
|
8
|
-
|
|
8
|
+
export * from './lib/components/icon/icon';
|
|
9
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL29hc3lzLWxpYi9zcmMvcHVibGljLWFwaS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUdILGNBQWMsd0JBQXdCLENBQUM7QUFFdkMsY0FBYywwQ0FBMEMsQ0FBQztBQUN6RCxjQUFjLHNDQUFzQyxDQUFDO0FBQ3JELGNBQWMsMkNBQTJDLENBQUM7QUFFMUQsY0FBYyw0QkFBNEIsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qXG4gKiBQdWJsaWMgQVBJIFN1cmZhY2Ugb2Ygb2FzeXMtbGliXG4gKi9cblxuXG5leHBvcnQgKiBmcm9tICcuL2xpYi9vYXN5cy1saWIubW9kdWxlJztcblxuZXhwb3J0ICogZnJvbSAnLi9saWIvY29tcG9uZW50cy9idXR0b24vYnV0dG9uLmNvbXBvbmVudCc7XG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb21wb25lbnRzL2ljb24vaWNvbi5jb21wb25lbnQnO1xuZXhwb3J0ICogZnJvbSAnLi9saWIvY29tcG9uZW50cy9sYXlvdXQvYm94L2JveC5jb21wb25lbnQnO1xuXG5leHBvcnQgKiBmcm9tICcuL2xpYi9jb21wb25lbnRzL2ljb24vaWNvbic7XG4iXX0=
|
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
import * as i3 from '@angular/common';
|
|
2
|
+
import { CommonModule, APP_BASE_HREF } from '@angular/common';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Injectable, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, EventEmitter, ContentChild, Output, NgModule } from '@angular/core';
|
|
5
|
+
import * as i2 from '@angular/router';
|
|
6
|
+
import { RouterModule } from '@angular/router';
|
|
7
|
+
|
|
8
|
+
function _window() {
|
|
9
|
+
return window;
|
|
10
|
+
}
|
|
11
|
+
class WindowService {
|
|
12
|
+
get nativeWindow() {
|
|
13
|
+
return _window();
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
WindowService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
17
|
+
WindowService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, providedIn: 'root' });
|
|
18
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: WindowService, decorators: [{
|
|
19
|
+
type: Injectable,
|
|
20
|
+
args: [{
|
|
21
|
+
providedIn: 'root'
|
|
22
|
+
}]
|
|
23
|
+
}] });
|
|
24
|
+
|
|
25
|
+
class TokenService {
|
|
26
|
+
constructor(windowRef) {
|
|
27
|
+
this.windowRef = windowRef;
|
|
28
|
+
}
|
|
29
|
+
/*
|
|
30
|
+
Get the brand name for the currently enable custom property set (ie. /bloomon/variables.css)
|
|
31
|
+
Because variables are scoped via a selector (ie: ':root .bloomon {}')
|
|
32
|
+
we cannot get brand-specific custom properties programatically
|
|
33
|
+
|
|
34
|
+
Important: Ensure that the component requiring the brand name has locally scoped the custom property:
|
|
35
|
+
| ui-icon {
|
|
36
|
+
| --icon-component-brand: var(--utility-brand-name);
|
|
37
|
+
| }
|
|
38
|
+
*/
|
|
39
|
+
getBrandName(tokenName, element) {
|
|
40
|
+
return this.getTokenValue(tokenName, element);
|
|
41
|
+
}
|
|
42
|
+
getTokenValue(tokenName, element) {
|
|
43
|
+
const rootElement = element || this.windowRef.nativeWindow.document.documentElement;
|
|
44
|
+
return this.windowRef.nativeWindow.getComputedStyle(rootElement)
|
|
45
|
+
.getPropertyValue(tokenName)
|
|
46
|
+
.trim() || '';
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
TokenService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, deps: [{ token: WindowService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
50
|
+
TokenService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, providedIn: 'root' });
|
|
51
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: TokenService, decorators: [{
|
|
52
|
+
type: Injectable,
|
|
53
|
+
args: [{
|
|
54
|
+
providedIn: 'root'
|
|
55
|
+
}]
|
|
56
|
+
}], ctorParameters: function () { return [{ type: WindowService }]; } });
|
|
57
|
+
|
|
58
|
+
class IconComponent {
|
|
59
|
+
constructor(tokenService, windowRef, elementRef) {
|
|
60
|
+
this.tokenService = tokenService;
|
|
61
|
+
this.windowRef = windowRef;
|
|
62
|
+
this.elementRef = elementRef;
|
|
63
|
+
this.iconSize = 'large';
|
|
64
|
+
this.iconContext = 'none';
|
|
65
|
+
}
|
|
66
|
+
convertRemToPixels(remString) {
|
|
67
|
+
const remNumber = parseFloat(remString.replace('rem', ''));
|
|
68
|
+
return remNumber * parseFloat(getComputedStyle(this.windowRef.nativeWindow.document.documentElement).fontSize);
|
|
69
|
+
}
|
|
70
|
+
ngOnChanges() {
|
|
71
|
+
this.ngOnInit();
|
|
72
|
+
}
|
|
73
|
+
ngOnInit() {
|
|
74
|
+
this.iconBrandPath = `${this.tokenService.getBrandName(`--icon-component-brand`, this.elementRef.nativeElement)}`;
|
|
75
|
+
this.size = this.tokenService.getTokenValue(`--global-size-icon-${this.iconSize}`);
|
|
76
|
+
this.iconDisplayClasses = [
|
|
77
|
+
`icon-context-${this.iconContext}`,
|
|
78
|
+
`icon-size-${this.iconSize}`
|
|
79
|
+
];
|
|
80
|
+
const sizeInPixels = this.convertRemToPixels(this.size);
|
|
81
|
+
this.iconWidth = sizeInPixels;
|
|
82
|
+
this.iconHeight = sizeInPixels;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
IconComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: IconComponent, deps: [{ token: TokenService }, { token: WindowService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
86
|
+
IconComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: IconComponent, selector: "ui-icon", inputs: { iconSize: "iconSize", iconName: "iconName", iconContext: "iconContext", iconWidth: "iconWidth", iconHeight: "iconHeight", iconClass: "iconClass" }, usesOnChanges: true, ngImport: i0, template: "<div class=\"ui-icon\" [ngClass]=\"iconDisplayClasses\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" attr.width=\"{{iconWidth}}px\" attr.height=\"{{iconHeight}}px\" attr.class=\"{{iconClass}}\">\n <use attr.xlink:href=\"./{{iconBrandPath}}/assets/icons/icons.svg#icon-{{iconName}}-24\"></use>\n </svg>\n</div>\n", styles: ["ui-icon{--icon-component-brand: var(--utility-brand-name)}.ui-icon{display:inline-flex}.ui-icon.icon-size-large.icon-context-leading{margin-left:calc(var(--component-size-button-large-icon-offset-leading) * -1)}.ui-icon.icon-size-large.icon-context-trailing{margin-right:calc(var(--component-size-button-large-icon-offset-trailing) * -1)}.ui-icon.icon-size-large.icon-context-iconOnly{margin-left:calc(var(--component-size-button-large-icon-offset-icon-only) * -1);margin-right:calc(var(--component-size-button-large-icon-offset-icon-only) * -1)}.ui-icon.icon-size-small.icon-context-leading{margin-left:calc(var(--component-size-button-small-icon-offset-leading) * -1)}.ui-icon.icon-size-small.icon-context-trailing{margin-right:calc(var(--component-size-button-small-icon-offset-trailing) * -1)}.ui-icon.icon-size-small.icon-context-iconOnly{margin-left:calc(var(--component-size-button-small-icon-offset-icon-only) * -1);margin-right:calc(var(--component-size-button-small-icon-offset-icon-only) * -1)}\n"], directives: [{ type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
87
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: IconComponent, decorators: [{
|
|
88
|
+
type: Component,
|
|
89
|
+
args: [{
|
|
90
|
+
selector: 'ui-icon',
|
|
91
|
+
templateUrl: './icon.component.html',
|
|
92
|
+
styleUrls: ['./icon.component.scss'],
|
|
93
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
94
|
+
encapsulation: ViewEncapsulation.None
|
|
95
|
+
}]
|
|
96
|
+
}], ctorParameters: function () { return [{ type: TokenService }, { type: WindowService }, { type: i0.ElementRef }]; }, propDecorators: { iconSize: [{
|
|
97
|
+
type: Input
|
|
98
|
+
}], iconName: [{
|
|
99
|
+
type: Input
|
|
100
|
+
}], iconContext: [{
|
|
101
|
+
type: Input
|
|
102
|
+
}], iconWidth: [{
|
|
103
|
+
type: Input
|
|
104
|
+
}], iconHeight: [{
|
|
105
|
+
type: Input
|
|
106
|
+
}], iconClass: [{
|
|
107
|
+
type: Input
|
|
108
|
+
}] } });
|
|
109
|
+
|
|
110
|
+
class OasysButtonComponent {
|
|
111
|
+
constructor(changes) {
|
|
112
|
+
this.changes = changes;
|
|
113
|
+
this.buttonIconPlacement = 'leading';
|
|
114
|
+
// Button Stylings
|
|
115
|
+
this.buttonSize = 'large';
|
|
116
|
+
this.buttonFullWidth = false;
|
|
117
|
+
this.buttonType = 'primary';
|
|
118
|
+
this.buttonDisabled = false;
|
|
119
|
+
// Button Actions
|
|
120
|
+
this.href = '';
|
|
121
|
+
this.click = new EventEmitter();
|
|
122
|
+
this.iconContext = 'none';
|
|
123
|
+
}
|
|
124
|
+
onClick() {
|
|
125
|
+
console.log('button was clicked');
|
|
126
|
+
this.click.emit();
|
|
127
|
+
}
|
|
128
|
+
createButton() {
|
|
129
|
+
return {
|
|
130
|
+
buttonIcon: this.buttonIcon,
|
|
131
|
+
buttonIconPlacement: this.buttonIconPlacement,
|
|
132
|
+
buttonType: this.buttonType,
|
|
133
|
+
buttonSize: this.buttonSize,
|
|
134
|
+
buttonDisabled: this.buttonDisabled,
|
|
135
|
+
href: this.href,
|
|
136
|
+
target: '',
|
|
137
|
+
buttonDisplayClasses: [
|
|
138
|
+
`type-${this.buttonType}`,
|
|
139
|
+
`size-${this.buttonSize}`,
|
|
140
|
+
`${this.buttonIcon ? 'button--has-icon' : ''}`,
|
|
141
|
+
`${this.buttonFullWidth ? 'button--full-width' : ''}`,
|
|
142
|
+
`${this.buttonIcon ? 'button--icon--' + this.buttonIconPlacement : ''}`
|
|
143
|
+
].filter((d) => !!d)
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
ngAfterViewInit() {
|
|
147
|
+
var _a, _b;
|
|
148
|
+
if ((_b = (_a = this.buttonText) === null || _a === void 0 ? void 0 : _a.nativeElement) === null || _b === void 0 ? void 0 : _b.innerText) {
|
|
149
|
+
this.accessibleButtonContent = this.buttonText.nativeElement.innerText;
|
|
150
|
+
}
|
|
151
|
+
else {
|
|
152
|
+
throw new Error('Button has no inner text. All buttons should have text passed via ng-content to enable accessibility for screen readers, this includes icon-only buttons');
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
ngOnChanges() {
|
|
156
|
+
console.log(this.button);
|
|
157
|
+
this.button = this.createButton();
|
|
158
|
+
this.changes.markForCheck();
|
|
159
|
+
}
|
|
160
|
+
ngOnInit() {
|
|
161
|
+
this.button = this.createButton();
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
OasysButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysButtonComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
165
|
+
OasysButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: OasysButtonComponent, selector: "ui-button", inputs: { buttonIcon: "buttonIcon", buttonIconPlacement: "buttonIconPlacement", buttonSize: "buttonSize", buttonFullWidth: "buttonFullWidth", buttonType: "buttonType", buttonDisabled: "buttonDisabled", href: "href" }, outputs: { click: "click" }, queries: [{ propertyName: "buttonText", first: true, predicate: ["buttonText"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<button (click)=\"onClick()\"\n [routerLink]=\"button.href || null\"\n [ngClass]=\"button.buttonDisplayClasses\"\n [attr.disabled]=\"button.buttonDisabled === true || null\"\n [attr.aria-label]=\"accessibleButtonContent\"\n role=\"button\"\n >\n <div class=\"button-content\">\n <ui-icon *ngIf=\"button.buttonIcon && button.buttonIconPlacement !== 'none'\" [iconName]=\"button.buttonIcon\" [iconSize]=\"button.buttonSize\" [iconClass]=\"'buttonIcon'\" [iconContext]=\"button.buttonIconPlacement\"></ui-icon>\n <span class=\"ui-text\" *ngIf=\"button.buttonIconPlacement !== 'iconOnly'\">\n <ng-content></ng-content>\n </span>\n </div>\n <div class=\"button-overlay\"></div>\n</button>\n", styles: ["ui-button button{border:0;padding:0;position:relative;display:inline-flex;text-align:center;justify-content:center;align-items:center;border-style:solid;cursor:pointer;-webkit-user-select:none;user-select:none;-webkit-appearance:none;-webkit-font-smoothing:antialiased;border-width:var(--component-border-width-button);font-family:var(--semantic-font-family-body);border-radius:var(--component-border-radius-button)}ui-button button:focus-visible{outline:none;box-shadow:0 0 0 var(--semantic-border-width-focus) var(--component-color-button-expressive-background)}ui-button button:focus{outline:none;box-shadow:0 0 0 var(--semantic-border-width-focus) var(--component-color-button-expressive-background)}ui-button button.type-primary{background-color:var(--component-color-button-primary-background);border-color:var(--component-color-button-primary-border);color:var(--component-color-button-primary-text)}ui-button button.type-primary .button-overlay{background-color:var(--component-color-button-primary-text)}ui-button button.type-secondary{background-color:var(--component-color-button-secondary-background);border-color:var(--component-color-button-secondary-border);color:var(--component-color-button-secondary-text)}ui-button button.type-secondary .button-overlay{background-color:var(--component-color-button-secondary-text)}ui-button button.type-tertiary{background-color:var(--component-color-button-tertiary-background);border-color:var(--component-color-button-tertiary-border);color:var(--component-color-button-tertiary-text)}ui-button button.type-tertiary .button-overlay{background-color:var(--component-color-button-tertiary-text)}ui-button button.type-primary-inverse{background-color:var(--component-color-button-primary-inverse-background);border-color:var(--component-color-button-primary-inverse-border);color:var(--component-color-button-primary-inverse-text)}ui-button button.type-primary-inverse .button-overlay{background-color:var(--component-color-button-primary-inverse-text)}ui-button button.type-secondary-inverse{background-color:var(--component-color-button-secondary-inverse-background);border-color:var(--component-color-button-secondary-inverse-border);color:var(--component-color-button-secondary-inverse-text)}ui-button button.type-secondary-inverse .button-overlay{background-color:var(--component-color-button-secondary-inverse-text)}ui-button button.type-tertiary-inverse{background-color:var(--component-color-button-tertiary-inverse-background);border-color:var(--component-color-button-tertiary-inverse-border);color:var(--component-color-button-tertiary-inverse-text)}ui-button button.type-tertiary-inverse .button-overlay{background-color:var(--component-color-button-tertiary-inverse-text)}ui-button button.type-expressive{background-color:var(--component-color-button-expressive-background);border-color:var(--component-color-button-expressive-border);color:var(--component-color-button-expressive-text)}ui-button button.type-expressive .button-overlay{background-color:var(--component-color-button-expressive-text)}ui-button button.type-danger{background-color:var(--component-color-button-danger-background);border-color:var(--component-color-button-danger-border);color:var(--component-color-button-danger-text)}ui-button button.type-danger .button-overlay{background-color:var(--component-color-button-danger-text)}ui-button button.type-facebook{background-color:var(--component-color-button-facebook-background);border-color:var(--component-color-button-facebook-border);color:var(--component-color-button-facebook-text)}ui-button button.type-facebook .button-overlay{background-color:var(--component-color-button-facebook-text)}ui-button button.type-paypal{background-color:var(--component-color-button-paypal-background);border-color:var(--component-color-button-paypal-border);color:var(--component-color-button-paypal-text)}ui-button button.type-paypal .button-overlay{background-color:var(--component-color-button-paypal-text)}ui-button button.type-trustpilot{background-color:var(--component-color-button-trustpilot-background);border-color:var(--component-color-button-trustpilot-border);color:var(--component-color-button-trustpilot-text)}ui-button button.type-trustpilot .button-overlay{background-color:var(--component-color-button-trustpilot-text)}ui-button button.size-large{padding:var(--component-size-button-large-padding-y) var(--component-size-button-large-padding-x);font-size:var(--component-size-button-large-font-size)}ui-button button.size-large .button-content{grid-gap:var(--component-size-button-large-inline-spacing);gap:var(--component-size-button-large-inline-spacing)}ui-button button.size-large .ui-icon{max-height:var(--component-size-button-large-line-height)}ui-button button.size-large .ui-text{line-height:var(--component-size-button-large-line-height)}ui-button button.size-small{padding:var(--component-size-button-small-padding-y) var(--component-size-button-small-padding-x);font-size:var(--component-size-button-small-font-size)}ui-button button.size-small .button-content{grid-gap:var(--component-size-button-small-inline-spacing);gap:var(--component-size-button-small-inline-spacing)}ui-button button.size-small .ui-icon{max-height:var(--component-size-button-small-line-height)}ui-button button.size-small .ui-text{line-height:var(--component-size-button-small-line-height)}ui-button button[disabled]{background-color:var(--component-color-button-disabled-background);border-color:var(--component-color-button-disabled-border);color:var(--component-color-button-disabled-text);cursor:default}ui-button button .buttonIcon{fill:currentColor}ui-button button .button-overlay{position:absolute;top:0;right:0;bottom:0;left:0;touch-action:none;pointer-events:none;opacity:0;border-radius:var(--component-border-radius-button)}ui-button button:hover .button-overlay{opacity:var(--component-opacity-overlay-hover)}ui-button button:focus .button-overlay{opacity:var(--component-opacity-overlay-focus)}ui-button button.button--has-icon.button--icon--trailing .button-content{flex-direction:row-reverse}ui-button button .button-content{display:flex;align-items:center}ui-button button .button-content .ui-icon{display:flex;align-items:center}ui-button button .button-content .ui-text{text-transform:var(--component-text-transform-button);letter-spacing:var(--component-letter-spacing-button);font-weight:var(--component-font-weight-button)}ui-button button.button--full-width{display:flex;width:100%}\n"], components: [{ type: IconComponent, selector: "ui-icon", inputs: ["iconSize", "iconName", "iconContext", "iconWidth", "iconHeight", "iconClass"] }], directives: [{ type: i2.RouterLink, selector: ":not(a):not(area)[routerLink]", inputs: ["routerLink", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo"] }, { type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
166
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysButtonComponent, decorators: [{
|
|
167
|
+
type: Component,
|
|
168
|
+
args: [{
|
|
169
|
+
selector: 'ui-button',
|
|
170
|
+
templateUrl: './button.component.html',
|
|
171
|
+
styleUrls: ['./button.component.scss'],
|
|
172
|
+
encapsulation: ViewEncapsulation.None,
|
|
173
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
|
174
|
+
}]
|
|
175
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { buttonIcon: [{
|
|
176
|
+
type: Input
|
|
177
|
+
}], buttonIconPlacement: [{
|
|
178
|
+
type: Input
|
|
179
|
+
}], buttonText: [{
|
|
180
|
+
type: ContentChild,
|
|
181
|
+
args: ['buttonText']
|
|
182
|
+
}], buttonSize: [{
|
|
183
|
+
type: Input
|
|
184
|
+
}], buttonFullWidth: [{
|
|
185
|
+
type: Input
|
|
186
|
+
}], buttonType: [{
|
|
187
|
+
type: Input
|
|
188
|
+
}], buttonDisabled: [{
|
|
189
|
+
type: Input
|
|
190
|
+
}], href: [{
|
|
191
|
+
type: Input
|
|
192
|
+
}], click: [{
|
|
193
|
+
type: Output
|
|
194
|
+
}] } });
|
|
195
|
+
|
|
196
|
+
class LayoutInlineComponent {
|
|
197
|
+
constructor() { }
|
|
198
|
+
ngOnInit() {
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
LayoutInlineComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutInlineComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
202
|
+
LayoutInlineComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: LayoutInlineComponent, selector: "ui-inline", ngImport: i0, template: "<div class=\"ui-layout-inline\"><ng-content></ng-content></div>", styles: [".ui-layout-inline{display:inline-flex;position:relative}.ui-layout-inline>*{margin-left:var(--layout-inline-spacing-default);margin-right:var(--layout-inline-spacing-default)}.ui-layout-inline:first-child{margin-left:0}.ui-layout-inline:last-child{margin-right:0}.ui-layout-inline:only-child{margin-left:0;margin-right:0}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
203
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutInlineComponent, decorators: [{
|
|
204
|
+
type: Component,
|
|
205
|
+
args: [{
|
|
206
|
+
selector: 'ui-inline',
|
|
207
|
+
templateUrl: './inline.component.html',
|
|
208
|
+
styleUrls: ['./inline.component.css'],
|
|
209
|
+
encapsulation: ViewEncapsulation.None,
|
|
210
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
|
211
|
+
}]
|
|
212
|
+
}], ctorParameters: function () { return []; } });
|
|
213
|
+
|
|
214
|
+
class LayoutBoxComponent {
|
|
215
|
+
constructor() {
|
|
216
|
+
this.padding = 'default';
|
|
217
|
+
}
|
|
218
|
+
ngOnInit() {
|
|
219
|
+
this.boxLayoutClasses = [
|
|
220
|
+
`ui-layout-box-${this.padding}`
|
|
221
|
+
].join(' ');
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
LayoutBoxComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutBoxComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
225
|
+
LayoutBoxComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: LayoutBoxComponent, selector: "ui-box", inputs: { padding: "padding" }, host: { properties: { "class": "boxLayoutClasses" } }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, styles: [".ui-layout-box-xsmall{padding:var(--size-unit-xsmall)}.ui-layout-box-small{padding:var(--size-unit-small)}.ui-layout-box-default{padding:var(--size-unit-default)}.ui-layout-box-large{padding:var(--size-unit-large)}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
226
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LayoutBoxComponent, decorators: [{
|
|
227
|
+
type: Component,
|
|
228
|
+
args: [{
|
|
229
|
+
selector: 'ui-box',
|
|
230
|
+
template: '<ng-content></ng-content>',
|
|
231
|
+
host: {
|
|
232
|
+
'[class]': 'boxLayoutClasses'
|
|
233
|
+
},
|
|
234
|
+
styleUrls: ['./box.component.scss'],
|
|
235
|
+
encapsulation: ViewEncapsulation.None,
|
|
236
|
+
changeDetection: ChangeDetectionStrategy.OnPush
|
|
237
|
+
}]
|
|
238
|
+
}], ctorParameters: function () { return []; }, propDecorators: { padding: [{
|
|
239
|
+
type: Input
|
|
240
|
+
}] } });
|
|
241
|
+
|
|
242
|
+
class OasysLibModule {
|
|
243
|
+
}
|
|
244
|
+
OasysLibModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
245
|
+
OasysLibModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, declarations: [OasysButtonComponent,
|
|
246
|
+
LayoutInlineComponent,
|
|
247
|
+
IconComponent,
|
|
248
|
+
LayoutBoxComponent], imports: [CommonModule, i2.RouterModule], exports: [OasysButtonComponent,
|
|
249
|
+
LayoutBoxComponent] });
|
|
250
|
+
OasysLibModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, providers: [
|
|
251
|
+
WindowService,
|
|
252
|
+
TokenService,
|
|
253
|
+
{ provide: APP_BASE_HREF, useValue: '/' }
|
|
254
|
+
], imports: [[
|
|
255
|
+
CommonModule,
|
|
256
|
+
RouterModule.forChild([])
|
|
257
|
+
]] });
|
|
258
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OasysLibModule, decorators: [{
|
|
259
|
+
type: NgModule,
|
|
260
|
+
args: [{
|
|
261
|
+
declarations: [
|
|
262
|
+
OasysButtonComponent,
|
|
263
|
+
LayoutInlineComponent,
|
|
264
|
+
IconComponent,
|
|
265
|
+
LayoutBoxComponent
|
|
266
|
+
],
|
|
267
|
+
imports: [
|
|
268
|
+
CommonModule,
|
|
269
|
+
RouterModule.forChild([])
|
|
270
|
+
],
|
|
271
|
+
exports: [
|
|
272
|
+
OasysButtonComponent,
|
|
273
|
+
LayoutBoxComponent
|
|
274
|
+
],
|
|
275
|
+
providers: [
|
|
276
|
+
WindowService,
|
|
277
|
+
TokenService,
|
|
278
|
+
{ provide: APP_BASE_HREF, useValue: '/' }
|
|
279
|
+
]
|
|
280
|
+
}]
|
|
281
|
+
}] });
|
|
282
|
+
|
|
283
|
+
/*
|
|
284
|
+
* Public API Surface of oasys-lib
|
|
285
|
+
*/
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* Generated bundle index. Do not edit.
|
|
289
|
+
*/
|
|
290
|
+
|
|
291
|
+
export { IconComponent, LayoutBoxComponent, OasysButtonComponent, OasysLibModule };
|
|
292
|
+
//# sourceMappingURL=oasys-lib.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"oasys-lib.js","sources":["../../../projects/oasys-lib/src/lib/services/window.service.ts","../../../projects/oasys-lib/src/lib/services/token.service.ts","../../../projects/oasys-lib/src/lib/components/icon/icon.component.ts","../../../projects/oasys-lib/src/lib/components/icon/icon.component.html","../../../projects/oasys-lib/src/lib/components/button/button.component.ts","../../../projects/oasys-lib/src/lib/components/button/button.component.html","../../../projects/oasys-lib/src/lib/components/layout/inline/inline.component.ts","../../../projects/oasys-lib/src/lib/components/layout/inline/inline.component.html","../../../projects/oasys-lib/src/lib/components/layout/box/box.component.ts","../../../projects/oasys-lib/src/lib/oasys-lib.module.ts","../../../projects/oasys-lib/src/public-api.ts","../../../projects/oasys-lib/src/oasys-lib.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\n\nfunction _window(): any {\n return window;\n}\n\n@Injectable({\n providedIn: 'root'\n})\nexport class WindowService {\n \n get nativeWindow(): any {\n return _window();\n }\n \n}","import { Injectable } from '@angular/core';\nimport { WindowService } from './window.service';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class TokenService {\n\n constructor(private windowRef: WindowService){}\n\n /*\n Get the brand name for the currently enable custom property set (ie. /bloomon/variables.css)\n Because variables are scoped via a selector (ie: ':root .bloomon {}')\n we cannot get brand-specific custom properties programatically\n\n Important: Ensure that the component requiring the brand name has locally scoped the custom property:\n | ui-icon {\n | --icon-component-brand: var(--utility-brand-name);\n | }\n */\n getBrandName(tokenName: string, element: Element): string {\n return this.getTokenValue(tokenName, element);\n }\n\n getTokenValue(tokenName: string, element?: Element): string {\n const rootElement = element || this.windowRef.nativeWindow.document.documentElement;\n return this.windowRef.nativeWindow.getComputedStyle(rootElement)\n .getPropertyValue(tokenName)\n .trim() || '';\n }\n\n}","import { Component, Input, OnInit, ViewEncapsulation, ChangeDetectionStrategy, OnChanges, ElementRef } from '@angular/core';\nimport { TokenService } from '../../services/token.service';\nimport { WindowService } from '../../services/window.service';\nimport { IconNames, IconContext } from './icon';\n@Component({\n selector:'ui-icon',\n templateUrl: './icon.component.html',\n styleUrls: ['./icon.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None\n})\nexport class IconComponent implements OnInit, OnChanges {\n @Input() iconSize: 'small'|'large' = 'large';\n @Input() iconName!: IconNames;\n @Input() iconContext: IconContext = 'none';\n\n @Input() iconWidth?: number;\n @Input() iconHeight?: number;\n @Input() iconClass?: string;\n\n size?: string;\n iconBrandPath?: string;\n iconDisplayClasses: string[];\n\n constructor(private tokenService: TokenService, private windowRef: WindowService, private elementRef: ElementRef) { }\n\n convertRemToPixels(remString: string): number {\n const remNumber = parseFloat(remString.replace('rem', ''));\n return remNumber * parseFloat(getComputedStyle(this.windowRef.nativeWindow.document.documentElement).fontSize);\n }\n\n ngOnChanges(): void {\n this.ngOnInit();\n }\n\n ngOnInit(): void {\n this.iconBrandPath = `${this.tokenService.getBrandName(`--icon-component-brand`, this.elementRef.nativeElement)}`\n this.size = this.tokenService.getTokenValue(`--global-size-icon-${this.iconSize}`);\n\n this.iconDisplayClasses = [\n `icon-context-${this.iconContext}`,\n `icon-size-${this.iconSize}`\n ];\n\n const sizeInPixels = this.convertRemToPixels(this.size);\n this.iconWidth = sizeInPixels;\n this.iconHeight = sizeInPixels;\n }\n\n}\n","<div class=\"ui-icon\" [ngClass]=\"iconDisplayClasses\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" attr.width=\"{{iconWidth}}px\" attr.height=\"{{iconHeight}}px\" attr.class=\"{{iconClass}}\">\n <use attr.xlink:href=\"./{{iconBrandPath}}/assets/icons/icons.svg#icon-{{iconName}}-24\"></use>\n </svg>\n</div>\n","import { Component, Input, OnInit, Output, ViewEncapsulation, EventEmitter, ChangeDetectionStrategy, ChangeDetectorRef, OnChanges, ContentChild, ElementRef, AfterViewInit } from '@angular/core';\nimport { IconNames, IconContext } from '../icon/icon';\nimport { TextTransform } from '../text/text';\nimport {\n UIButton,\n UIButtonBoolean,\n UIButtonSize,\n UIButtonType\n} from './button';\n\n@Component({\n selector:'ui-button',\n templateUrl: './button.component.html',\n styleUrls: ['./button.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class OasysButtonComponent implements OnInit, OnChanges, AfterViewInit {\n\n button: UIButton;\n\n // // Button Content\n @Input() buttonIcon?: IconNames;\n @Input() buttonIconPlacement: IconContext = 'leading';\n\n // @Input() buttonText: string;\n @ContentChild('buttonText') buttonText: ElementRef;\n\n // Button Stylings\n @Input() buttonSize: UIButtonSize = 'large';\n @Input() buttonFullWidth: UIButtonBoolean = false;\n @Input() buttonType: UIButtonType = 'primary';\n @Input() buttonDisabled: boolean = false;\n\n // Button Actions\n @Input() href: string = '';\n @Output() click: EventEmitter<void> = new EventEmitter();\n\n buttonDisplayClasses: string[];\n iconContext: IconContext = 'none';\n textTransform!: TextTransform;\n accessibleButtonContent: string;\n\n constructor(private changes: ChangeDetectorRef) { }\n\n onClick(): void {\n console.log('button was clicked');\n this.click.emit();\n }\n\n createButton(): UIButton {\n\n return <UIButton>{\n buttonIcon: this.buttonIcon,\n buttonIconPlacement: this.buttonIconPlacement,\n buttonType: this.buttonType,\n buttonSize: this.buttonSize,\n buttonDisabled: this.buttonDisabled,\n href: this.href,\n target: '',\n buttonDisplayClasses: [\n `type-${this.buttonType}`,\n `size-${this.buttonSize}`,\n `${this.buttonIcon ? 'button--has-icon': ''}`,\n `${this.buttonFullWidth ? 'button--full-width': ''}`,\n `${this.buttonIcon ? 'button--icon--'+this.buttonIconPlacement : ''}`\n ].filter((d) => !!d)\n };\n }\n\n ngAfterViewInit(): void {\n if(this.buttonText?.nativeElement?.innerText) {\n this.accessibleButtonContent = this.buttonText.nativeElement.innerText;\n } else {\n throw new Error('Button has no inner text. All buttons should have text passed via ng-content to enable accessibility for screen readers, this includes icon-only buttons')\n }\n }\n\n ngOnChanges(): void {\n console.log(this.button);\n this.button = this.createButton();\n this.changes.markForCheck();\n }\n\n ngOnInit(): void {\n this.button = this.createButton();\n }\n}\n","<button (click)=\"onClick()\"\n [routerLink]=\"button.href || null\"\n [ngClass]=\"button.buttonDisplayClasses\"\n [attr.disabled]=\"button.buttonDisabled === true || null\"\n [attr.aria-label]=\"accessibleButtonContent\"\n role=\"button\"\n >\n <div class=\"button-content\">\n <ui-icon *ngIf=\"button.buttonIcon && button.buttonIconPlacement !== 'none'\" [iconName]=\"button.buttonIcon\" [iconSize]=\"button.buttonSize\" [iconClass]=\"'buttonIcon'\" [iconContext]=\"button.buttonIconPlacement\"></ui-icon>\n <span class=\"ui-text\" *ngIf=\"button.buttonIconPlacement !== 'iconOnly'\">\n <ng-content></ng-content>\n </span>\n </div>\n <div class=\"button-overlay\"></div>\n</button>\n","import { ChangeDetectionStrategy, Component, OnInit, ViewEncapsulation } from '@angular/core';\n\n@Component({\n selector:'ui-inline',\n templateUrl: './inline.component.html',\n styleUrls: ['./inline.component.css'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class LayoutInlineComponent implements OnInit {\n\n constructor() { }\n\n ngOnInit(): void {\n }\n\n}\n","<div class=\"ui-layout-inline\"><ng-content></ng-content></div>","import { ChangeDetectionStrategy, OnInit, ViewEncapsulation } from '@angular/core';\nimport { Input } from '@angular/core';\nimport { Component} from '@angular/core';\n\n@Component({\n selector:'ui-box',\n template: '<ng-content></ng-content>',\n host: {\n '[class]' : 'boxLayoutClasses'\n },\n styleUrls: ['./box.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class LayoutBoxComponent implements OnInit {\n boxLayoutClasses?: string;\n\n @Input() padding?: BoxPaddings = 'default';\n\n constructor() { }\n\n ngOnInit(): void {\n this.boxLayoutClasses = [\n `ui-layout-box-${this.padding}`\n ].join(' ');\n }\n\n}\n\nexport type BoxPaddings = 'xsmall'|'small'|'medium'|'large'|'default';","import { APP_BASE_HREF, CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { RouterModule } from '@angular/router';\nimport { OasysButtonComponent } from './components/button/button.component';\nimport { LayoutInlineComponent } from './components/layout/inline/inline.component';\nimport { IconComponent } from './components/icon/icon.component';\nimport { LayoutBoxComponent } from './components/layout/box/box.component';\nimport { WindowService } from './services/window.service';\nimport { TokenService } from './services/token.service';\n\n\n\n@NgModule({\n declarations: [\n OasysButtonComponent,\n LayoutInlineComponent,\n IconComponent,\n LayoutBoxComponent\n ],\n imports: [\n CommonModule,\n RouterModule.forChild([])\n ],\n exports: [\n OasysButtonComponent,\n LayoutBoxComponent\n ],\n providers: [\n WindowService,\n TokenService,\n {provide: APP_BASE_HREF, useValue: '/'}\n ]\n})\nexport class OasysLibModule { }\n","/*\n * Public API Surface of oasys-lib\n */\n\n\nexport * from './lib/oasys-lib.module';\n\nexport * from './lib/components/button/button.component';\nexport * from './lib/components/icon/icon.component';\nexport * from './lib/components/layout/box/box.component';\n\nexport * from './lib/components/icon/icon';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1.WindowService","i1.TokenService","i2.WindowService","i1.IconComponent","i1"],"mappings":";;;;;;;AAEA,SAAS,OAAO,GAAA;AACd,IAAA,OAAO,MAAM,CAAC;AAChB,CAAC;MAKY,aAAa,CAAA;AAExB,IAAA,IAAI,YAAY,GAAA;QACd,OAAO,OAAO,EAAE,CAAC;KAClB;;2GAJU,aAAa,EAAA,IAAA,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
-
import { OnInit, EventEmitter, ChangeDetectorRef, OnChanges } from '@angular/core';
|
|
1
|
+
import { OnInit, EventEmitter, ChangeDetectorRef, OnChanges, ElementRef, AfterViewInit } from '@angular/core';
|
|
2
2
|
import { IconNames, IconContext } from '../icon/icon';
|
|
3
3
|
import { TextTransform } from '../text/text';
|
|
4
4
|
import { UIButton, UIButtonBoolean, UIButtonSize, UIButtonType } from './button';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
|
-
export declare class
|
|
6
|
+
export declare class OasysButtonComponent implements OnInit, OnChanges, AfterViewInit {
|
|
7
7
|
private changes;
|
|
8
8
|
button: UIButton;
|
|
9
|
-
buttonText: string;
|
|
10
9
|
buttonIcon?: IconNames;
|
|
11
10
|
buttonIconPlacement: IconContext;
|
|
11
|
+
buttonText: ElementRef;
|
|
12
12
|
buttonSize: UIButtonSize;
|
|
13
13
|
buttonFullWidth: UIButtonBoolean;
|
|
14
14
|
buttonType: UIButtonType;
|
|
@@ -18,12 +18,14 @@ export declare class ButtonComponent implements OnInit, OnChanges {
|
|
|
18
18
|
buttonDisplayClasses: string[];
|
|
19
19
|
iconContext: IconContext;
|
|
20
20
|
textTransform: TextTransform;
|
|
21
|
+
accessibleButtonContent: string;
|
|
21
22
|
constructor(changes: ChangeDetectorRef);
|
|
22
23
|
onClick(): void;
|
|
23
24
|
createButton(): UIButton;
|
|
25
|
+
ngAfterViewInit(): void;
|
|
24
26
|
ngOnChanges(): void;
|
|
25
27
|
ngOnInit(): void;
|
|
26
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<
|
|
27
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<
|
|
28
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<OasysButtonComponent, never>;
|
|
29
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<OasysButtonComponent, "ui-button", never, { "buttonIcon": "buttonIcon"; "buttonIconPlacement": "buttonIconPlacement"; "buttonSize": "buttonSize"; "buttonFullWidth": "buttonFullWidth"; "buttonType": "buttonType"; "buttonDisabled": "buttonDisabled"; "href": "href"; }, { "click": "click"; }, ["buttonText"], ["*"]>;
|
|
28
30
|
}
|
|
29
31
|
//# sourceMappingURL=button.component.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.component.d.ts","sourceRoot":"","sources":["../../../../../projects/oasys-lib/src/lib/components/button/button.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,MAAM,EAA6B,YAAY,EAA2B,iBAAiB,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"button.component.d.ts","sourceRoot":"","sources":["../../../../../projects/oasys-lib/src/lib/components/button/button.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,MAAM,EAA6B,YAAY,EAA2B,iBAAiB,EAAE,SAAS,EAAgB,UAAU,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAClM,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AACtD,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EACL,QAAQ,EACR,eAAe,EACf,YAAY,EACZ,YAAY,EACb,MAAM,UAAU,CAAC;;AAElB,qBAOa,oBAAqB,YAAW,MAAM,EAAE,SAAS,EAAE,aAAa;IA0B/D,OAAO,CAAC,OAAO;IAxB3B,MAAM,EAAE,QAAQ,CAAC;IAGR,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,mBAAmB,EAAE,WAAW,CAAa;IAG1B,UAAU,EAAE,UAAU,CAAC;IAG1C,UAAU,EAAE,YAAY,CAAW;IACnC,eAAe,EAAE,eAAe,CAAS;IACzC,UAAU,EAAE,YAAY,CAAa;IACrC,cAAc,EAAE,OAAO,CAAS;IAGhC,IAAI,EAAE,MAAM,CAAM;IACjB,KAAK,EAAE,YAAY,CAAC,IAAI,CAAC,CAAsB;IAEzD,oBAAoB,EAAE,MAAM,EAAE,CAAC;IAC/B,WAAW,EAAE,WAAW,CAAU;IAClC,aAAa,EAAG,aAAa,CAAC;IAC9B,uBAAuB,EAAE,MAAM,CAAC;gBAEZ,OAAO,EAAE,iBAAiB;IAE9C,OAAO,IAAI,IAAI;IAKf,YAAY,IAAI,QAAQ;IAoBxB,eAAe,IAAI,IAAI;IAQvB,WAAW,IAAI,IAAI;IAMnB,QAAQ,IAAI,IAAI;yCAnEL,oBAAoB;2CAApB,oBAAoB;CAsEhC"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { EventEmitter } from '@angular/core';
|
|
2
|
-
import { IconNames, IconContext } from '
|
|
2
|
+
import { IconNames, IconContext } from '../icon/icon';
|
|
3
3
|
export declare type UIButtonBoolean = true | 'true' | false | 'false';
|
|
4
4
|
export declare type UIButtonSize = 'small' | 'large';
|
|
5
5
|
export declare type UIButtonType = 'primary' | 'secondary' | 'tertiary' | 'primary-inverse' | 'secondary-inverse' | 'tertiary-inverse' | 'expressive' | 'danger' | 'facebook' | 'paypal' | 'trustpilot';
|
|
6
6
|
export interface UIButton {
|
|
7
|
-
buttonText: string;
|
|
8
7
|
buttonIcon: IconNames;
|
|
9
8
|
buttonType: UIButtonType;
|
|
10
9
|
buttonIconPlacement: IconContext;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../../../projects/oasys-lib/src/lib/components/button/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../../../../projects/oasys-lib/src/lib/components/button/button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGtD,oBAAY,eAAe,GAAG,IAAI,GAAG,MAAM,GAAG,KAAK,GAAG,OAAO,CAAC;AAE9D,oBAAY,YAAY,GAAG,OAAO,GAAG,OAAO,CAAC;AAE7C,oBAAY,YAAY,GACpB,SAAS,GACT,WAAW,GACX,UAAU,GACV,iBAAiB,GACjB,mBAAmB,GACnB,kBAAkB,GAClB,YAAY,GACZ,QAAQ,GACR,UAAU,GACV,QAAQ,GACR,YAAY,CAAC;AAEjB,MAAM,WAAW,QAAQ;IAOvB,UAAU,EAAE,SAAS,CAAC;IAEtB,UAAU,EAAE,YAAY,CAAC;IAEzB,mBAAmB,EAAE,WAAW,CAAA;IAEhC,UAAU,EAAE,YAAY,CAAC;IAEzB,eAAe,EAAE,eAAe,CAAC;IAEjC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,cAAc,EAAE,eAAe,CAAC;IAGhC,oBAAoB,EAAE,MAAM,EAAE,CAAC;IAK/B,cAAc,EAAE,YAAY,CAAC,GAAG,CAAC,CAAC;CACnC"}
|