oasys-lib 1.14.6 → 1.15.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.
@@ -1227,7 +1227,7 @@
1227
1227
  */
1228
1228
  CardComponent.prototype.setStackPlacement = function () {
1229
1229
  var _a, _b;
1230
- this.stackOffset = "-" + (((_b = (_a = this.imageLabel) === null || _a === void 0 ? void 0 : _a.nativeElement) === null || _b === void 0 ? void 0 : _b.offsetHeight) / 2) + "px";
1230
+ this.stackOffset = "calc(-" + ((_b = (_a = this.imageLabel) === null || _a === void 0 ? void 0 : _a.nativeElement) === null || _b === void 0 ? void 0 : _b.offsetHeight) / 2 + "px - " + this.tokenService.getTokenValue('--semantic-spacing-box-tight');
1231
1231
  };
1232
1232
  /**
1233
1233
  * This function retrieves the appropriate design token value based on the passed imageFormat choice
@@ -1250,7 +1250,7 @@
1250
1250
  return CardComponent;
1251
1251
  }());
1252
1252
  CardComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: CardComponent, deps: [{ token: TokenService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1253
- CardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: CardComponent, selector: "ui-card", inputs: { label_text: "label_text", image: "image", alt_text: "alt_text", image_format: "image_format", small_title_left: "small_title_left", small_sub_title_right: "small_sub_title_right", standard_content: "standard_content", bold_content: "bold_content" }, host: { listeners: { "window:resize": "setStackPlacement($event)" } }, viewQueries: [{ propertyName: "imageLabel", first: true, predicate: ["imagelabel"], descendants: true, read: i0.ElementRef }], ngImport: i0__namespace, template: "<ui-box class=\"ui-card\" box_background=\"core-primary\" box_space=\"none\">\n <ui-stack stack_align=\"center\" stack_gap=\"none\">\n <ui-box\n class=\"ui-card__image\"\n [ngStyle]=\"{'aspect-ratio': aspectRatio}\"\n box_background=\"transparent\"\n box_align_x=\"center\"\n box_space=\"none\">\n <img [src]=\"image\" [attr.alt]=\"alt_text\">\n </ui-box>\n <ui-stack stack_gap=\"tight\" [ngStyle]=\"{'margin-top': stackOffset}\">\n <ui-box\n #imagelabel\n *ngIf=\"label_text\"\n class=\"card__image-label center-content\"\n box_background=\"tint-highlight\"\n box_align_x=\"center\"\n box_align_y=\"center\"\n box_space_left=\"near\"\n box_space_right=\"near\"\n box_space_bottom=\"tight\"\n box_space_top=\"tight\">\n <h5>{{label_text}}</h5>\n </ui-box>\n <ui-box *ngIf=\"small_title_left || small_sub_title_right\" [box_space_top]=\"label_text ? 'none' : 'tight'\" box_space=\"none\" box_background=\"transparent\" >\n <ui-stack stack_direction=\"x\" stack_distribute=\"space-between\" stack_gap=\"tight\">\n <span class=\"text-body--supporting text-color--supporting\">{{small_title_left}}</span>\n <span class=\"text-body--supporting text-color--supporting\">{{small_sub_title_right}}</span>\n </ui-stack>\n </ui-box>\n <p *ngIf=\"standard_content\" class=\"text-label--default center-content\">{{standard_content}}</p>\n <p *ngIf=\"bold_content\" class=\"text-label--primary text-body--emphasis\">{{bold_content}}</p>\n </ui-stack>\n </ui-stack>\n</ui-box>\n", styles: [".ui-card__image{position:relative}.ui-card__image img{position:absolute;height:100%;object-fit:cover;width:100%;left:0}.ui-card .center-content{text-align:center;align-self:center}.ui-card .card__image-label{width:auto;height:auto;border-radius:2px;margin:0 8px;text-align:center;overflow:hidden;z-index:2}\n"], components: [{ type: LayoutBoxComponent, selector: "ui-box", inputs: ["box_space", "box_space_top", "box_space_right", "box_space_bottom", "box_space_left", "box_align_x", "box_align_y", "box_fill_mode", "box_background", "box_content_fill_width"] }, { type: LayoutStackComponent, selector: "ui-stack", inputs: ["stack_gap", "stack_align", "stack_direction", "stack_distribute", "stack_wrap"] }], directives: [{ type: i6__namespace.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1253
+ CardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: CardComponent, selector: "ui-card", inputs: { label_text: "label_text", image: "image", alt_text: "alt_text", image_format: "image_format", small_title_left: "small_title_left", small_sub_title_right: "small_sub_title_right", standard_content: "standard_content", bold_content: "bold_content" }, host: { listeners: { "window:resize": "setStackPlacement($event)" } }, viewQueries: [{ propertyName: "imageLabel", first: true, predicate: ["imagelabel"], descendants: true, read: i0.ElementRef }], ngImport: i0__namespace, template: "<ui-box class=\"ui-card\" box_background=\"core-primary\" box_space=\"none\">\n <ui-stack stack_align=\"center\" stack_gap=\"tight\">\n <ui-box\n class=\"ui-card__image\"\n [ngStyle]=\"{'aspect-ratio': aspectRatio}\"\n box_background=\"transparent\"\n box_align_x=\"center\"\n box_space=\"none\">\n <img [src]=\"image\" [attr.alt]=\"alt_text\">\n </ui-box>\n <ui-stack stack_gap=\"tight\" [ngStyle]=\"{'margin-top': stackOffset}\">\n <ui-box\n #imagelabel\n *ngIf=\"label_text\"\n class=\"card__image-label center-content\"\n box_background=\"tint-highlight\"\n box_align_x=\"center\"\n box_align_y=\"center\"\n box_space_left=\"near\"\n box_space_right=\"near\"\n box_space_bottom=\"tight\"\n box_space_top=\"tight\">\n <h5>{{label_text}}</h5>\n </ui-box>\n <ui-box *ngIf=\"small_title_left || small_sub_title_right\" [box_space_top]=\"label_text ? 'none' : 'tight'\" box_space=\"none\" box_background=\"transparent\" >\n <ui-stack stack_direction=\"x\" stack_distribute=\"space-between\" stack_gap=\"tight\">\n <span class=\"text-body--supporting text-color--supporting\">{{small_title_left}}</span>\n <span class=\"text-body--supporting text-color--supporting\">{{small_sub_title_right}}</span>\n </ui-stack>\n </ui-box>\n <p *ngIf=\"standard_content\" class=\"text-label--default center-content\">{{standard_content}}</p>\n <p *ngIf=\"bold_content\" class=\"text-label--primary text-body--emphasis\">{{bold_content}}</p>\n </ui-stack>\n </ui-stack>\n</ui-box>\n", styles: [".ui-card__image{position:relative}.ui-card__image img{position:absolute;height:100%;object-fit:cover;width:100%;left:0}.ui-card .center-content{text-align:center;align-self:center}.ui-card .card__image-label{width:auto;height:auto;border-radius:2px;margin:0 8px;text-align:center;overflow:hidden;z-index:2}\n"], components: [{ type: LayoutBoxComponent, selector: "ui-box", inputs: ["box_space", "box_space_top", "box_space_right", "box_space_bottom", "box_space_left", "box_align_x", "box_align_y", "box_fill_mode", "box_background", "box_content_fill_width"] }, { type: LayoutStackComponent, selector: "ui-stack", inputs: ["stack_gap", "stack_align", "stack_direction", "stack_distribute", "stack_wrap"] }], directives: [{ type: i6__namespace.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1254
1254
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: CardComponent, decorators: [{
1255
1255
  type: i0.Component,
1256
1256
  args: [{
@@ -1938,6 +1938,55 @@
1938
1938
  }]
1939
1939
  }] });
1940
1940
 
1941
+ var BannerComponent = /** @class */ (function () {
1942
+ function BannerComponent(tokenService) {
1943
+ this.tokenService = tokenService;
1944
+ this.background_colour = 'tint-highlight';
1945
+ }
1946
+ BannerComponent.prototype.ngOnInit = function () {
1947
+ this.backgroundIsDark = this.tokenService.getTokenValue("--semantic-on-dark-" + this.background_colour);
1948
+ };
1949
+ return BannerComponent;
1950
+ }());
1951
+ BannerComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: BannerComponent, deps: [{ token: TokenService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1952
+ BannerComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: BannerComponent, selector: "ui-banner", inputs: { background_colour: "background_colour", cta_text: "cta_text", banner_title: "banner_title", banner_surtitle: "banner_surtitle", banner_subtitle: "banner_subtitle" }, ngImport: i0__namespace, template: "<ui-box\n [box_background]=\"background_colour\"\n box_space_left=\"none\"\n box_space_right=\"none\"\n box_fill_mode=\"fill\"\n box_align_x=\"center\" \n class=\"ui-banner\">\n <ui-grid grid_collapse_below=\"tablet\">\n <ui-column class=\"ui-banner__content\">\n <ui-stack class=\"content__stack\" stack_direction=\"x\" stack_distribute=\"space-between\" stack_align=\"center\" stack_gap=\"near\">\n <ui-stack class=\"content__stack\" stack_direction=\"x\" stack_align=\"center\" stack_gap=\"near\">\n <!-- This is a stack as the icon will go here above the ui-heading -->\n <ui-heading\n *ngIf=\"banner_title || banner_surtitle || banner_subtitle\"\n heading_type=\"functional-primary\"\n [heading_title]=\"banner_title\"\n [heading_surtitle]=\"banner_surtitle\"\n [heading_subtitle]=\"banner_subtitle\">\n </ui-heading>\n </ui-stack>\n <ui-button\n *ngIf=\"cta_text\"\n button_size=\"large\"\n [button_type]=\"backgroundIsDark === 'on-dark' ? 'primary-inverse' : 'primary'\">\n <span #buttontext>{{cta_text}}</span>\n </ui-button>\n </ui-stack>\n </ui-column>\n </ui-grid>\n</ui-box>\n", styles: ["@media only screen and (min-width: 768px){.ui-banner__content{grid-column:2/span 10!important}}@media only screen and (min-width: 1080px){.ui-banner__content{grid-column:3/span 8!important}}@media only screen and (max-width: 767px){.ui-banner__content{padding:0 var(--semantic-spacing-stack-default)}}.ui-banner__content .content__stack{flex-direction:column;align-items:flex-start}@media only screen and (min-width: 768px){.ui-banner__content .content__stack{flex-direction:row;align-items:center}.ui-banner__content .content__stack ui-button{white-space:nowrap}}\n"], components: [{ type: LayoutBoxComponent, selector: "ui-box", inputs: ["box_space", "box_space_top", "box_space_right", "box_space_bottom", "box_space_left", "box_align_x", "box_align_y", "box_fill_mode", "box_background", "box_content_fill_width"] }, { type: LayoutGridComponent, selector: "ui-grid", inputs: ["grid_auto", "grid_collapse_below", "grid_gap"] }, { type: LayoutGridColumnComponent, selector: "ui-column", inputs: ["columns"] }, { type: LayoutStackComponent, selector: "ui-stack", inputs: ["stack_gap", "stack_align", "stack_direction", "stack_distribute", "stack_wrap"] }, { type: OasysHeadingComponent, selector: "ui-heading", inputs: ["heading_type", "heading_on_dark", "heading_title", "heading_seo_priority", "heading_priority", "heading_alignment_override", "heading_subtitle", "heading_surtitle"] }, { type: OasysButtonComponent, selector: "ui-button", inputs: ["button_icon", "button_icon_placement", "button_size", "button_full_width", "button_type", "button_disabled", "href"], outputs: ["clicked"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
1953
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: BannerComponent, decorators: [{
1954
+ type: i0.Component,
1955
+ args: [{
1956
+ selector: 'ui-banner',
1957
+ templateUrl: './banner.component.html',
1958
+ styleUrls: ['./banner.component.scss']
1959
+ }]
1960
+ }], ctorParameters: function () { return [{ type: TokenService }]; }, propDecorators: { background_colour: [{
1961
+ type: i0.Input
1962
+ }], cta_text: [{
1963
+ type: i0.Input
1964
+ }], banner_title: [{
1965
+ type: i0.Input
1966
+ }], banner_surtitle: [{
1967
+ type: i0.Input
1968
+ }], banner_subtitle: [{
1969
+ type: i0.Input
1970
+ }] } });
1971
+
1972
+ var OasysBannerModule = /** @class */ (function () {
1973
+ function OasysBannerModule() {
1974
+ }
1975
+ return OasysBannerModule;
1976
+ }());
1977
+ OasysBannerModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: OasysBannerModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
1978
+ OasysBannerModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: OasysBannerModule, declarations: [BannerComponent], imports: [i6.CommonModule, OasysButtonModule, OasysHeadingModule, OasysLayoutModule, OasysIconModule], exports: [BannerComponent] });
1979
+ OasysBannerModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: OasysBannerModule, providers: [TokenService], imports: [[i6.CommonModule, OasysButtonModule, OasysHeadingModule, OasysLayoutModule, OasysIconModule]] });
1980
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: OasysBannerModule, decorators: [{
1981
+ type: i0.NgModule,
1982
+ args: [{
1983
+ declarations: [BannerComponent],
1984
+ imports: [i6.CommonModule, OasysButtonModule, OasysHeadingModule, OasysLayoutModule, OasysIconModule],
1985
+ exports: [BannerComponent],
1986
+ providers: [TokenService],
1987
+ }]
1988
+ }] });
1989
+
1941
1990
  /*
1942
1991
  * Public API Surface of oasys-lib
1943
1992
  */
@@ -1946,6 +1995,7 @@
1946
1995
  * Generated bundle index. Do not edit.
1947
1996
  */
1948
1997
 
1998
+ exports.BannerComponent = BannerComponent;
1949
1999
  exports.BreadcrumbsComponent = BreadcrumbsComponent;
1950
2000
  exports.CardComponent = CardComponent;
1951
2001
  exports.CarouselComponent = CarouselComponent;
@@ -1963,6 +2013,7 @@
1963
2013
  exports.OasysAlertContentDirective = OasysAlertContentDirective;
1964
2014
  exports.OasysAlertModule = OasysAlertModule;
1965
2015
  exports.OasysAlertTitleDirective = OasysAlertTitleDirective;
2016
+ exports.OasysBannerModule = OasysBannerModule;
1966
2017
  exports.OasysBreadcrumbModule = OasysBreadcrumbModule;
1967
2018
  exports.OasysButtonComponent = OasysButtonComponent;
1968
2019
  exports.OasysButtonModule = OasysButtonModule;